content
stringlengths
1
15.9M
\section{Introduction} \label{introduction} Modern technology has made high-quality data available in abundance. It is estimated that more than 2.5 quintillion bytes of data is generated every day and that 90\% of all data were generated in the last two years alone \cite{ibmdata}. The amount of user generated data on social media and data generated through smart sensors in the Internet of things will likely contribute to an even faster increase. A major problem of scientific and industrial interest is how to transform the data into a predictive model which can give insights on the data generating process. The data generating process in the natural sciences is often described in terms of differential equations. There is a vast amount of literature spanning over decades available for the identification of dynamical systems where the quantities of interest are measured as a function of time or some other dependent variable. See for example \cite{identificationsurvey, identificationstoica, identificationmodeling, motions, identificationbook, identificationblackbox, identificationblackboxmath}. The identification of time-dependent partial differential equations (PDEs) through data analysis is an emerging and exciting field of research which is not as explored as dynamical systems. The research has been made available through the recent progress in machine learning algorithms and their efficient implementation in open source software. PDEs are traditionally derived by considering first physical principles. For example the Navier-Stokes equations in fluid dynamics are derived by considering the conservation of mass, momentum, and energy for a control volume in a fluid. There are, however, many situations where derivations by first principles are intractable or even impossible as they become too complicated or the governing physical laws are unknown. In such situations there are typically several geostationary points where changes of a quantities of interest are measured over time. Datasets consisting of such spatio-temporal data is the interest of this paper and we aim to develop methods which can automatically identify a PDE which is generating the dataset. The emerging field of data-driven discovery of PDEs can be split into three approaches: (1) Sparse regression, (2) Gaussian processes, and (3) Artificial neural networks. Sparse regression is based on a library of candidate terms and sparse model selection to select the most important terms \cite{sparsepde, datadriven1, haydensparsepde}. Identification using Gaussian processes works by placing a Gaussian process prior on the unknown coefficients of the PDE and infer them by using maximum likelihood estimation \cite{gausspde1, gausspde2, gausspde3}. Artificial neural networks can be used as sparse regression models, act as priors on unknown coefficients, or completely determine a general differential operator \cite{inverse, neuraldiscovery1, neuraldiscovery2}. In this paper we will focus on deep neural networks to extend and complement previous work mentioned in the above references. There are two main contribution in this paper. The first is that we use a unified neural network approach for both sparse regression and the identification of general differential operators. The second is that we include complex datasets where necessary transformations of the input data manifest as coordinate transformations which yield metric coefficients in the identified PDE. \section{Method} \label{method} We are working under the assumption that we have an unordered dataset consisting of space-time coordinates and function values where the governing equation is unknown. The goal is to identify a PDE which approximately has the function values as the solution in the space-time points. The first step is to fit a function to the data which can be used to compute the derivatives with respect to the space-time coordinates. This is a separate preprocessing step and any method can be used, for example finite differences \cite{pdeidentificationfinitedifference}, polynomial interpolation \cite{pdeidentificationpolynomial}, finite elements, spectral methods, radial basis functions, or neural networks. The most recent work have been focused on polynomial interpolation \cite{datadriven1} or neural networks \cite{2017arXiv171110561R, neuraldiscovery2} due to their independence of structured data and insensitivity to noise. The identified PDE depends highly on the quality of the approximating function and a comparative study of various approximation methods would be valuable and is the topic of future research. We will use deep neural networks as approximating functions. Deep neural networks are universal smooth function approximators \cite{Hornik1991, Hornik1990551, Cybenko1989} and their derivatives are analytically available through backpropagation \cite{backprop, efficientbackprop} or automatic differentiation \cite{identificationsurvey} in open source software such as TensorFlow \cite{tensorflow} or PyTorch \cite{pytorch}. We assume that our data consists of the triplets $t$, $\mathbf{x} = [x_1, x_2, \ldots, x_N]$, and $\mathbf{u} = [u_1, u_2, \ldots, u_M]$ which is describing a vector valued mapping $\mathbf{u}: \mathbb{R}^{N+1} \to \mathbb{R}^M$, where $t$ denotes the time variable, $x_1, \ldots, x_N$ the space variables, and $u_1, \ldots u_M$ the function values. In the first step we approximate the function $u$ by a deep neural network $\hat{u} = \hat{u}(\mathbf{x}, t; \mathbf{p})$ where $\mathbf{p}$ denotes the vector of coefficients in the network. We will usually drop explicit parameter dependence, unless required, to ease the notation. We will use the hyperbolic tangent as activation function and solve the regularized minimization problem for the coefficients, \begin{equation} \mathbf{p}^* = \min_{\mathbf{p}} \frac{1}{2}||u(x, t) - \hat{u}(\mathbf{x}, t; \mathbf{p})||^2 + \frac{\alpha_p}{2}||\mathbf{p}||^2, \label{minu} \end{equation} by using the BFGS \cite{bfgs} or L-BFGS \cite{lbfgs} methods for small and large scale problems, respectively. When solving the minimization problem \eqref{minu}, we do not distinguish between the time and space coordinates. Different datasets require different neural networks designs and it would be interesting to try neural networks which are tailored for time-series prediction, for example recurrent neural networks, in this context. Such a study is, however, beyond the scope of this paper. In the second step we seek a parameterized function $\hat{L} = \hat{L}(\hat{u}, \partial \hat{u}, \ldots, \partial^m \hat{u}; \mathbf{q})$, where the notation $\partial^j \hat{u}$ means all partial derivatives of $\hat{u}$ with respect to $x_1, \ldots, x_n$ up to order $m$ such that \begin{equation} \hat{u}_t = \hat{L}(\hat{u}, \partial \hat{u}, \ldots, \partial^m \hat{u}). \end{equation} $\hat{L}$ is then the approximation of the, yet unknown, differential operator in the governing PDE. The restriction to first order time derivatives is without loss of generality as we can compute derivatives of any order from the neural network approximation $\hat{u}$. Depending on the choice of parametrization of $\hat{L}$ it is possible to discover a wide range of PDEs and encompass the methods described in \cite{datadriven1, datadriven2, haydensparsepde, sparsepde, neuraldiscovery1, neuraldiscovery2} in a single framework. The framework we have chosen here is to represent $\hat{L}$ by a feedforward neural network and to find $\hat{L}$ by gradient based optimization. We recover the sparse regression method by having a neural network without hidden layers with candidate terms as input features, in which case the neural network reduces to a linear model. We recover classical PDEs, which are polynomial in $\hat{u}$ and its partial derivatives, by computing all partial derivatives up to some order $m$, all non-linear combinations up to some order $k$, and having them as input features to a linear model. There are \begin{equation} \mathcal{M} = M\left(1 + \sum_{i=1}^m \binom{i + N - 1}{N - 1}\right) \end{equation} partial derivative terms up to order $m$ and \begin{equation} \mathcal{K} = \sum_{i=1}^k \binom{i + \mathcal{M} - 1}{\mathcal{M} - 1} \end{equation} non-linear combinations up to order $k$. For example, the time-dependent compressible Navier-Stokes equations in 3D have $N=3$ space variables, $M=5$ unknowns, non-linear terms up to order $k=2$, and partial derivatives to up order $m=2$. This gives a total of $\mathcal{M} = 50$ partial derivative terms and $\mathcal{K} = 1325$ possible input features. While the number of input features grows combinatorially with the number of partial derivatives and non-linear order, modern day machine learning with neural networks casually deal with input features in the order of million or even billions. Even the most basic standard example of hand written digit recognition using the MNIST dataset has $28 \times 28 = 784$ input features -- the number of pixels of each image in the dataset. Finally, we can let $\hat{L}$ be given by a neural network of arbitrary complexity with the $\mathcal{M}$ partial derivative terms as input features to get an arbitrarily complex differential operator. There is always a trade-off between model complexity and interpretability. A linear model with candidate terms as input features provides a simple model which can be read, analyzed, and understood. It does, however, require some physical understanding of the data generating process to ensure that the set of input features is sufficient. A general neural network model is on the other extreme. It can approximate an arbitrary complex differential operator but the resulting operator can neither be read nor understood. A linear model with polynomial input features is somewhere in between. Sparse regression with L1 regularization will remove some insignificant terms but some manual post cleaning will probably be required to get a interpretable model. In all cases, the model is unlikely to produce a well-posed PDE in the sense of Hadamard \cite{hadamard}. As the true differential operator $L$ is not known and we have no training data for it, the goal is to find a set of parameters $\mathbf{q}^*$ such that the residual of the approximate PDE is minimized, \begin{equation} \mathbf{q}^* = \min_\mathbf{q} \frac{1}{2}||\hat{u}_t - \hat{L}(\hat{u}, \partial \hat{u}, \ldots, \partial^m \hat{u}; \mathbf{q})||^2 + \frac{\alpha_q}{2}||\mathbf{q}||_1^2. \label{minpde} \end{equation} We typically add regularization in the $L^1$-norm to favor sparsity in the resulting PDE model. The optimization problems \eqref{minu} and \eqref{minpde} are very different from an optimization perspective. The former is a highly non-convex optimization problem over a large number of parameters and a limited amount of data. The latter is, in the linear model case, a convex optimization problem over a small number of parameters and a large amount of data. In the 3D Navier-Stokes example above, let us assume that we have sampled the solution 100 times on a $32 \times 32 \times 32$ grid. This gives us a dataset of size $3276800 \times 4$ in the optimization of \eqref{minu} and $3276800 \times 1325$ in the optimization of \eqref{minpde}. Data driven discovery of PDEs is thus suitable on heterogeneous systems where the optimization of \eqref{minu} is performed on GPUs with many cores and limited memory while the optimization of \eqref{minpde} is performed on CPUs with few cores and large memory. \subsection{Feature scaling} \label{scaling} It is well-known that machine learning algorithms perform poorly unless the input features are scaled correctly. In the previous work on data-driven discovery of PDEs, all data were generated by known PDEs on simple geometries which did not require any transformation of the input features. In real life applications, however, the domain of interest is in general neither simple nor close to the origin and the input features need to be transformed. The transformation then impacts the identified PDE as it is subjected to a coordinate transformation. Using a neural network to approximate the dataset as a separate preprocessing step usually follows a pipline in which feature scaling is included, for example by preprocessing using the \texttt{Pipeline} module from \texttt{scikit-learn} \cite{scikitlearn}. It is hence important to be aware of all feature scalings in the preprocessing step and that the exact same feature scaling is used in the identification of the PDE in the second step. Feature scaling amounts to the invertible coordinate transformations \begin{equation} \begin{aligned} \tau &= \tau(t), \\ \bm{\xi} &= \bm{\xi}(\bm{x}) \end{aligned} \label{transform} \end{equation} where $\tau$, $\bm{\xi} = [\xi_1, \ldots, \xi_N]$ are the new time and space coordinates, respectively. A common transformation is to shift and scale such that each input feature has zero mean and unit variance, \begin{equation} \begin{aligned} \tau &= \frac{t - \bar{t}}{\sigma(t)}, \\ \bm{\xi} &= \frac{\bm{x} - \bar{\bm{x}}}{\sigma(\bm{x})}, \\ \end{aligned} \label{shiftscale} \end{equation} where $\bar{t}$, $\bar{\bm{x}}$ and $\sigma(\cdot)$ denotes the (componentwise) average and standard deviation of the input data, respectively, and the division is performed componentwise where needed. As an example we can consider what happens to the discovery of the viscous Burger's equation under the transformation \eqref{transform}. Assume we are given a dataset generated by the viscous Burger's equation in 1D, \begin{equation} u_t + uu_x = \epsilon u_{xx}, \label{origburger} \end{equation} to which we fit a neural network under the general coordinate transformation \eqref{transform}. By the chain rule we get \begin{equation} \begin{aligned} \frac{\partial u}{\partial t} &= \frac{\partial u}{\partial \tau} \frac{\partial \tau}{\partial t}, \\ \frac{\partial u}{\partial x} &= \frac{\partial u}{\partial \xi} \frac{\partial \xi}{\partial x}, \\ \frac{\partial^2 u}{\partial x^2} &= \frac{\partial^2 u}{\partial \xi^2} \left(\frac{\partial \xi}{\partial x}\right)^2 + \frac{\partial u}{\partial \xi} \frac{\partial^2 \xi}{\partial x^2} \end{aligned} \end{equation} and hence the neural network is not an approximation to the solution of \eqref{origburger} but to the transformed equation \begin{equation} \frac{\partial \tau}{\partial t} u_{\tau} + \left(\frac{\partial \xi}{\partial x} u - \epsilon \frac{\partial^2 \xi}{\partial x^2}\right)u_{\xi} = \epsilon \left(\frac{\partial \xi}{\partial x}\right)^2 u_{\xi\xi}. \label{transformburger} \end{equation} Under the linear transformation \eqref{shiftscale}, the above equation reduces to \begin{equation} \frac{1}{\sigma(t)} u_{\tau} + \frac{1}{\sigma(x)} uu_{\xi} = \frac{\epsilon}{\sigma^2(x)}u_{\xi\xi}. \label{shiftscaleburger} \end{equation} The situation becomes more complex in higher dimensions as in general we need to compute all total derivatives in the old coordinates when computing the partial derivatives in the new coordinates as \begin{equation} \begin{aligned} \frac{\partial u}{\partial x_1} &= \frac{\partial u}{\partial \xi_1} \frac{\partial \xi_1}{\partial x_1} + \cdots + \frac{\partial u}{\partial \xi_N} \frac{\partial \xi_N}{\partial x_1}, \\ &\vdotswithin{=} \\ \frac{\partial u}{\partial x_N} &= \frac{\partial u}{\partial \xi_1} \frac{\partial \xi_1}{\partial x_N} + \cdots + \frac{\partial u}{\partial \xi_N} \frac{\partial \xi_N}{\partial x_N}. \end{aligned} \end{equation} We write the above expression in matrix form as \begin{equation} \begin{bmatrix} \dfrac{\partial u}{\partial x_1} \\ \vdots \\ \dfrac{\partial u}{\partial x_N} \end{bmatrix} = \begin{bmatrix} \dfrac{\partial \xi_1}{\partial x_1} & \cdots & \dfrac{\partial \xi_N}{\partial x_1} \\ \vdots & \ddots & \vdots \\ \dfrac{\partial \xi_1}{\partial x_N} & \cdots & \dfrac{\partial \xi_N}{\partial x_N} \end{bmatrix} \begin{bmatrix} \dfrac{\partial u}{\partial \xi_1} \\ \vdots \\ \dfrac{\partial u}{\partial \xi_N} \end{bmatrix} \end{equation} where the square matrix above is the Jacobian matrix, $J$, of the coordinate transformation. Since we are interested in the PDE in the physical coordinates, we need to transform back to the original coordinates by computing the inverse of the Jacobian, \begin{equation} J^{-1} = \begin{bmatrix} \dfrac{\partial x_1}{\partial \xi_1} & \cdots & \dfrac{\partial x_N}{\partial \xi_1} \\ \vdots & \ddots & \vdots \\ \dfrac{\partial x_1}{\partial \xi_N} & \cdots & \dfrac{\partial x_N}{\partial \xi_N} \end{bmatrix}. \end{equation} The transformation \eqref{shiftscale} is particularly useful in high dimensions as it is linear and acts only one coordinate direction at a time, independently of the other coordinates. This means that the Jacobian is reduced to the diagonal matrix \begin{equation} J = \begin{bmatrix} \dfrac{1}{\sigma(x_1)} & \cdots & 0 \\ \vdots & \ddots & \vdots \\ 0 & \cdots & \dfrac{1}{\sigma(x_N)} \end{bmatrix} \end{equation} and that higher-order derivatives are easily computed since each derivative of $u$ with respect to $x_i$ only yields an additional factor or $1/\sigma(x_i)$. That is, we get \begin{equation} \begin{aligned} \frac{\partial u}{\partial x_i} &= \frac{1}{\sigma(x_i)} \frac{\partial u}{\partial \xi_i}, \\ \frac{\partial^2 u}{\partial x_i \partial x_j} &= \frac{1}{\sigma(x_i) \sigma(x_j)} \frac{\partial u}{\partial \xi_i \partial \xi_j} \\ &\vdotswithin{=} \\ \frac{\partial^m u}{\partial x_i \cdots \partial x_j} &= \frac{1}{\sigma(x_i) \cdots \sigma(x_j)} \frac{\partial^m u}{\partial \xi_i \cdots \partial \xi_j} \end{aligned} \end{equation} for the partial derivatives up to order $m$. Transforming the partial derivatives back to the original coordinates is reduced to multiplication by a scalar which avoids the numerically unstable and computationally expensive inversion of the Jacobian matrix. \section{Examples} \label{examples} There are plenty of examples in previous papers which show impressive results in the accuracy of the identified PDE despite both sparse and noisy data \cite{datadriven1, datadriven2, haydensparsepde, sparsepde, neuraldiscovery1, neuraldiscovery2}. These results are all based on known PDEs on simple geometries. We will show a few examples on what happens to the identified PDE under coordinate transformations, and some potential applications in weather/climate modeling where the governing equations are unknown. \subsection{The viscous Burger's equation in 1D} \label{burgers} We consider the viscous Burger's equation for $(x, t)$ $\in [0, 1] \times [0, 1]$ here given by \begin{equation} \begin{aligned} u_t + uu_x &= 10^{-2} u_{xx}, \\ u(0, t) &= 0, \\ u(1, t) &= 0, \\ u(x, 0) &= \sin(2 \pi x). \end{aligned} \label{burgerpde}% \end{equation} The solution to \eqref{burgerpde} is well-known and forms a decaying stationary viscous shock after a finite time, see Figure~\ref{figburgersnaps}. \begin{figure}[H] \centering \includegraphics[width=0.75\textwidth]{figures/burgersnaps.pdf} \caption{The solution of the viscous Burger's equation forming a stationary viscous shock.} \label{figburgersnaps} \end{figure} The solution of \eqref{burgerpde} was computed with the finite element method using $128$ second-order elements in space and $1000$ steps using the backward Euler method in time. To reconstruct the differential operator in \eqref{burgerpde}, we sample the solution in all interior degrees of freedom at each non-zero time step to get a dataset of the form $(t, x, u)$ consisting of a total of $255000$ entries. The first step is to fit a neural network to the dataset which allows us to compute the necessary derivatives. This is a separate preprocessing step in which we use a feedforward neural network with 5 hidden layers and 10 neurons in each layer with the hyperbolic tangent activation function. The network is trained using the BFGS method from \texttt{SciPy}'s \texttt{scipy.minimize} module with default parameters \cite{scipy}. For this model problem we consider three different parametrizations of $\hat{L}$ without regularization or scaling: 1) A linear model with the library terms $uu_x$ and $u_{xx}$ as input features, 2) A linear model with up to second order derivative and non-linear terms as input features, and 3) A two layer feedforward neural network with 2 neurons in each layer with the hyperbolic tangent activation and up to second order derivative terms as input features. When minimizing \eqref{minpde} with the different parametrizations we discover the following PDEs: \begin{equation} \begin{aligned} 1) && u_t &= -9.9792\times 10^{-1}*uu_{x} + 9.9596\times 10^{-3}*u_{xx} \\ \\ 2) && u_t &= -9.9718\times 10^{-1}*uu_{x} + 1.0134\times 10^{-2}*u_{xx} \\ &&&- 4.2757\times 10^{-8}*\left(u_{xx}\right)^2 + 1.0156\times 10^{-5}*u_{x}u_{xx} \\ &&&- 8.3758\times 10^{-5}*uu_{xx} + 2.8494\times 10^{-6}*\left(u_{x}\right)^2 \\ &&&+ 1.4114\times 10^{-4}*u_{x} - 4.4878\times 10^{-3}*\left(u\right)^2 + 2.2429\times 10^{-3}*u \\ \\ 3) && u_t &= -2.2618*\tanh(-1.0809*\tanh(5.2229\times 10^{-3}*u_{xx} \\ &&&+ 3.4171\times 10^{-1}*u_{x} + 7.0587\times 10^{-2}*t - 1.4968\times 10^{-1}*u \\ &&&- 6.2141\times 10^{-2}*x - 4.9887\times 10^{-1}) - 1.5738\times 10^{1}*\tanh(5.9850\times 10^{-3}*u_{xx} \\ &&&+ 1.1323\times 10^{-2}*u_{x} + 5.1961\times 10^{-1}*t - 3.6736\times 10^{-1}*u \\ &&&+ 6.7682\times 10^{-2}*x + 9.3685\times 10^{-1}) + 1.4128\times 10^{1}) \\ &&&- 1.4500*\tanh(-1.0331*\tanh(5.2229\times 10^{-3}*u_{xx} + 3.4171\times 10^{-1}*u_{x} \\ &&&+ 7.0587\times 10^{-2}*t - 1.4968\times 10^{-1}*u - 6.2141\times 10^{-2}*x - 4.9887\times 10^{-1}) \\ &&&+ 1.9307\times 10^{1}*\tanh(5.9850\times 10^{-3}*u_{xx} + 1.1323\times 10^{-2}*u_{x} \\ &&&+ 5.1961\times 10^{-1}*t - 3.6736\times 10^{-1}*u + 6.7682\times 10^{-2}*x + 9.3685\times 10^{-1}) \\ &&&- 1.7623\times 10^{1}) + 1.7249\times 10^{-1} \end{aligned} \end{equation} It is clear that the different models have different trade-offs. The first model is similar in apperance to the true PDE, but it is required that we know the form of the PDE a priori. The second model has small coefficients for the spurious terms and close to the true values for the true terms. The third model is general and of limited use for human interpretation. However, many PDE solvers offer automatic discretization of symbolic expressions and the output of the general model can be used as input to a software such as Comsol Multiphysics \cite{comsol} or physics informed neural networks \cite{2017arXiv171110561R}. To see the effect of a feature scaling we consider the simple library model under the standard shift and scale transformation \eqref{shiftscale}. For this particular dataset we have \begin{equation} \begin{aligned} \sigma^2(t) &= 0.0833326, & \sigma^2(x) &= 0.08268167, \\ \bar{t} &= 0.50050196, & \bar{x} &= 0.49999807, \end{aligned} \end{equation} and the identified PDE in transformed space becomes \begin{equation} u_{\tau} = -1.0010uu_{\xi} + 3.4815\times 10^{-2}u_{\xi\xi} \end{equation} which corroborates \eqref{shiftscaleburger} rewritten as \begin{equation} u_{\tau} = -\frac{\sigma(t)}{\sigma(x)}uu_{\xi} + \frac{\sigma(t)}{\sigma^2(x)} \times 10^{-2} u_{\xi\xi}. \end{equation} To get the PDE in the physical coordinates it is hence required that we invert the coordinate transformation and compute the derivatives in the physical space as \begin{equation} \begin{aligned} \frac{\partial u}{\partial \tau} &= \frac{\partial u}{\partial t} \frac{\partial t}{\partial \tau} = \sigma(t) \frac{\partial u}{\partial t} \\ \frac{\partial u}{\partial \xi} &= \frac{\partial u}{\partial x} \frac{\partial x}{\partial \xi} = \sigma(x)\frac{\partial u}{\partial x} \\ \frac{\partial^2 u}{\partial \xi^2} &= \frac{\partial^2 u}{\partial x^2} \left(\frac{\partial x}{\partial \xi}\right)^2 = \sigma^2(x)\frac{\partial^2 u}{\partial x^2}. \end{aligned} \end{equation} First after transforming back to the physical space do we recover the desired PDE \begin{equation} u_t + \frac{\sigma(x)}{\sigma(t)}uu_x = \frac{\sigma^2(x)}{\sigma(t)} u_{xx}, \end{equation} and in this particular case we get \begin{equation} u_t + 0.99708uu_x = 0.99717 \times 10^{-2}u_{xx}. \end{equation} For this model problem, coordinate transformations are not necessary as we are working on the simple domain $(x,t) \in [0, 1] \times [0, 1]$ which is in the range where machine learning algorithms performs well. \subsection{Temperature distribution in 2D} \label{temperature} The focus in this section is on potential applications of the method to real measurement data for weather/climate modeling. The outlined method should be seen as a starting point for further research. A natural application of the method is where several geostationary sensors are recording measurements over time, for example weather stations which measure quantities such as temperature, pressure, humidity, and so on on a regular basis. The Swedish Meteorological and Hydrological Institute\footnote{\url{http://www.smhi.se}} is offering a REST API where meteorological data can be downloaded for all 326 measurement stations in Sweden. Each station is recording data at time intervals ranging from every hour to every 12 hours, and the locations are given in latitude/longitude coordinates in the range $[10.96, 55.34] \times [24.17, 69.05]$ which is outside the range where machine learning algorithms perform well. We downloaded the data and made a dataset consisting of the temperature for the first week in July 2016 to see if we can find a PDE which is describing the temperature distribution. The dataset contains irregular measurements in a complicated geometry where coordinate transformations are inevitable. The dataset is imbalanced since there are too many points in time compared to the number of points in space. In this artificial example, we remedy this by performing a linear interpolation in space and time onto the convex hull of a regular grid with 168 time points, 32 latitude points, and 128 longitude points, see Figure~\ref{figsmhistations} (where all spatial data points have been transformed by the Mercator projection for visualization only). The final interpolated dataset contains 688129 data points on a regular grid. Finally, we approximate the dataset with a neural network with 5 hidden layers with 20 neurons in each layer using the L-BFGS optimization method. We tried many different networks and this, surprisingly small network, had the best generalization accuracy when evaluated on different test sets obtained by different interpolations. Larger networks had problems with overfitting and adding dropout and regularization caused the L-BFGS algorithm to perform poorly. \begin{figure}[H] \centering \begin{subfigure}[t]{0.49\textwidth} \centering \includegraphics[scale=0.45]{figures/smhi_stations_crop.pdf} \caption{The locations of the 326 weather stations in Sweden.} \end{subfigure} \begin{subfigure}[t]{0.49\textwidth} \centering \includegraphics[scale=0.45]{figures/smhi_interp_crop.pdf} \caption{Interpolation onto the convex hull of the weather station locations.} \end{subfigure} \caption{Physical and interpolated locations of the geostationary locations.} \end{figure} \begin{figure}[H] \centering \begin{subfigure}[t]{0.49\textwidth} \centering \includegraphics[scale=0.4]{figures/smhi_temp_interp_crop_res.pdf} \caption{Linear interpolation temperature snapshot.} \end{subfigure} \begin{subfigure}[t]{0.49\textwidth} \centering \includegraphics[scale=0.4]{figures/smhi_temp_net_crop_res.pdf} \caption{Neural network approximated temperature snapshot.} \end{subfigure} \caption{The linear interpolation and neural network approximated temperature snapshots. The neural network has 5 layers with 20 neurons each.} \label{figsmhistations} \end{figure} Note that since the neural network is globally defined we can plot the temperature in the whole domain and not just on the convex hull of the data points. In this case, the governing PDE is unknown and we will elaborate on results and conclusions in section~\ref{model}. \begin{remark} The linear interpolation of the dataset of course gives rise to non-physical linear relations in the neural network approximation. In a real case one should consider more advanced reconstruction methods if more data is needed. \end{remark} \section{Feature selection} \label{feature} To elaborate on feature selection we return to Section~\ref{burgers} and the polynomial PDE model for the viscous Burger's equation which has a decent trade-off between complexity and interpretability. By adding L1 regularization to the polynomial PDE model with $\alpha_q = 10^{-2}$ in \eqref{minpde}, the spurious terms are further reduced to \begin{equation} \begin{aligned} u_t &= -9.9473\times 10^{-1}*uu_{x} + 1.0105\times 10^{-2}*u_{xx} \\ &- 1.2630\times 10^{-9}*\left(u_{xx}\right)^2 + 1.0007\times 10^{-5}*u_{x}u_{xx} \\ &- 5.2975\times 10^{-5}*uu_{xx} - 3.3428\times 10^{-5}*\left(u_{x}\right)^2 \\ &+ 1.2649\times 10^{-6}*u_{x} - 1.5698\times 10^{-5}*\left(u\right)^2 - 1.6640\times 10^{-6}*u \end{aligned} \end{equation} which can be removed by some predefined cut-off value for the coefficient size. \begin{remark} As the polynomial PDE model is linear we can, of course, use the traditional least squares method with Lasso \cite{lasso} instead of adding L1 regularization to the optimization problem. In that case we obtain the even sparser model \begin{equation} \begin{aligned} u_t &= -9.9216\times 10^{-1}*uu_{x} + 1.0082\times 10^{-2}*u_{xx} \\ &- 2.3627\times 10^{-9}*\left(u_{xx}\right)^2 + 1.0129\times 10^{-5}*u_{x}u_{xx} \\ &- 5.4086e\times 10^{-5}*uu_{xx} - 3.2458\times 10^{-5}*\left(u_{x}\right)^2. \end{aligned} \end{equation} The traditional least squares model does not, however, generalize to differential operators of arbitrary complexity or very large datasets. \end{remark} It is common to analyze the input data in order to remove redundant or correlated features. In this case, it is only the terms $u$, $u_{x}$, and $u_{xx}$ which are independent. A common method is to compute the variance of the input data and remove features with low variance since they are deemed as unimportant. This method does not apply in a PDE context since high order derivatives have lower regularity and hence usually a higher variance, which is clearly shown in Table~\ref{tablefeatures}. More sophisticated methods for feature selection include stability analysis via randomized Lasso (R-Lasso) \cite{rlasso}, recursive feature elimination (RFE) \cite{rfe}, and Boruta \cite{boruta}. We include comparisons with the two former methods in Table~\ref{tablefeatures} were we have used the implementations from \texttt{scikit-learn} with default parameters. The Boruta method works on ensamble models, such as random forests, and is not suitable in this context. We did, however, try the Boruta method on our dataset with a random forest regressor and we did not obtain any good results. The Boruta method deemed all features as equally important. \def1.0{1.5} \begin{table}[H] \centering \begin{tabular}{|c|c|c|c|c|c|c|c|c|c|} \hline Feature & $u$ & $u_{x}$ & $u_{xx}$ & $u^2$ & $uu_{x}$ & $uu_{xx}$ & $u^2_{x}$ & $u_{x}u_{xx}$ & $u^2_{xx}$ \\ \hline Variance & $0.21$ & $23$ & $23000$ & $0.06$ & $3.1$ & $5700$ & $11000$ & $9.0 \times 10^{6}$ & $1.7 \times 10^{10}$ \\ R-Lasso & $0.09$ & $0$ & $1$ & $1$ & $1$ & $1$ & $1$ & $1$ & $0$ \\ RFE & $3$ & $5$ & $2$ & $4$ & $1$ & $6$ & $7$ & $8$ & $9$ \\ \hline \end{tabular} \caption{The variance, feature importance and feature ranking of our dataset for the viscous Burger's equation.} \label{tablefeatures} \end{table} \def1.0{1.0} We can see from Table~\ref{tablefeatures} that the variance of the features are the opposite of what is expected as the variance grows with the order of the derivative independent of the importance of the feature. By combining R-Lasso and RFE we can get a decent understanding of which features that are important in the dataset. \section{Model selection} \label{model} As the polynomial PDE model for the viscous Burger's equation is linear and the optimization problem \eqref{minpde} is convex, minimization using standard least squares or gradient based optimization is efficient and model selection can be performed by an exhaustive parameter search. By computing the value of the cost function for different choices of the derivative order $m$ and non-linear order $k$, it is clearly seen when a suitable model has been found. In Figure~\ref{figburgerbars} we show the logarithm of the cost function for different choices of $m$ and $k$. We can see that the cost function is instantly reduced by several orders of magnitude when a sufficient model has been found. \begin{figure}[H] \centering \includegraphics[width=\textwidth]{figures/burgerbars_crop.pdf} \caption{The logarithm of the cost function for different choices of derivative and non-linear orders $m$ and $k$ for the viscous Burger's equation. The true configuration is $m/k = 2/1$.} \label{figburgerbars} \end{figure} We can perform a similar study when the PDE is represented by a neural network with different number of layers and neurons. In Figure~\ref{figburgerbarsnetwork} we show the value of the cost function for different network designs with different partial derivative orders as input. \begin{figure}[H] \centering \includegraphics[width=\textwidth]{figures/burgerbars_network_crop.pdf} \caption{The logarithm of the cost function for different network designs and partial derivative orders ($m$) for the viscous Burger's equation.} \label{figburgerbarsnetwork} \end{figure} The case with 2 hidden layers with 50 neurons in each layer is particularly interesting. In this case we have a low cost even without any partial derivatives as input. Thus for the case $m=0$, the viscous Burger's equation is effectively transformed into an ordinary differential equation (ODE) of the form \begin{equation} \hat{u}_t = \hat{L}(\hat{u}). \label{ode} \end{equation} The ODE \eqref{ode} can easily be solved using any time integration method. In Figure~\ref{figburgerode} we used standard Runge-Kutta 4(5) from \texttt{SciPy} with default settings to integrate the ODE. We can see that the ODE operator gives accurate results for $0 \leq t \leq 1$ where we have trained the operator. We can also see, unfortunately, that the ODE operator is unable to extrapolate far beyond $t=1$ where we have no training data. It is, however, quite remarkable that the dynamics of a second order non-linear PDE can be well approximated by an ODE in the range of the training data and slightly beyond. \begin{figure}[H] \centering \begin{subfigure}[t]{0.49\textwidth} \centering \includegraphics[width=\textwidth]{figures/burger_pdeode.pdf} \caption{Line: PDE solution, Dots: ODE solution. The PDE and ODE solutions to the viscous Burger's equation at times 0.0, 0.25, 0.5, 1.0.} \end{subfigure} \begin{subfigure}[t]{0.49\textwidth} \centering \includegraphics[width=\textwidth]{figures/burger_ode_time_error.pdf} \caption{The mean square error in time of the ODE solution to the viscous Burger's equation.} \end{subfigure} \caption{Comparison between the ODE and PDE solutions of the viscous Burger's equation. The ODE solution is accurate for $0 \leq t \leq 1$ where we have trained the operator. The ODE operator is, however, unable to extrapolate for $t >> 1$.} \label{figburgerode} \end{figure} This method can in the same way be used for model invalidation. Since a PDE model for the temperature distribution is unknown we can perform an exhaustive parameter search to see if a sufficient model can be found. In Figure~\ref{figsmhibarsclassic} we show the value of the cost function for different values of $m$ and $k$, and we can clearly see that there is no sufficient model in this parameter range. \begin{figure}[H] \centering \includegraphics[width=\textwidth]{figures/smhibars_classic_crop.pdf} \caption{The value of the cost function for different choices of derivative and non-linear orders $m$ and $k$ for temperature models. No sufficient polynomial models were found.} \label{figsmhibarsclassic} \end{figure} Since no polynomial PDE models for the temperature distribution were found, we can perform the same exhaustive parameter search where we instead vary the number of layers and neurons in each layers when $\hat{L}$ is represented by a neural network. The results can be seen in Figure~\ref{figsmhibarsnetwork} where we represented $\hat{L}$ by neural networks with 1, 2, 4, 6, 8 hidden layers with 5, 10, 20, 50 neurons in each layer, respectively, and partial derivatives of order $m=0, 1, 2, 4$ as input. We can see that the cost drops several orders of magnitude for certain configurations which indicate that sufficient models have been found. We can also see that even in this complicated case, there are some ODE models which appears to capture the dynamics. \begin{figure}[H] \centering \includegraphics[width=\textwidth]{figures/smhibars_network_crop.pdf} \caption{The logarithm of the cost function for different network architectures and partial derivative orders ($m$) for temperature models. Some sufficient network models were found.} \label{figsmhibarsnetwork} \end{figure} Similarly to viscous Burger's case, we use the ODE operator with 6 layers and 50 neurons in each layer to compute the mean square error in time for the ODE solution using Runge-Kutta 4(5). In this case, the ODE operator is trained on data from the first week in July 2016 ($0 \leq t \leq 1$) and evaluated on both the first and second week ($0 \leq t \leq 2$) to test the prediction performance. As in the viscous Burger's case, we can see in Figure~\ref{figsmhiode} that the ODE operator is fairly accurate in the region where training data is available but is unable to extrapolate far beyond the training data. However, the operator is able to remain accurate up to time $t=1.25$ which amounts to quarter of a week in physical time. \begin{figure}[H] \centering \includegraphics[width=0.75\textwidth]{figures/smhi_ode_time_error.pdf} \caption{The mean square error in time of the ODE temperature model.} \label{figsmhiode} \end{figure} The simulation shown in Figure~\ref{figsmhiode} of the Swedish temperature distribution over a two week period using the ODE operator takes only a fraction of a second on a laptop. We hence believe that by incorporating more quantities in the measurements, it is possible to discover a system of ODEs which can be used to obtain both fast and accurate short-time predictions. \section{Summary and conclusions} \label{summary} We have used deep artificial neural networks to discover partial differential equations from data sets consisting of measurements of physical quantities of interest. The quantities of interest are both artificial from known model PDEs, as well as true measurement data from weather stations. In general, the physical domain is non-trivial and data transformations are necessary to bring the problem into a range where machine learning algorithms perform well. These data transformations amounts to coordinate transformations in the discovered PDEs and it is hence important that all data transformations are recorded such that the discovered PDEs can be transformed back into physical space. We have shown examples of general data transformations and the common shift and scale transformation in particular. The discovered PDE operator is not unique for any given data set. We performed parameter searches to discover a range of operators that describes a PDE which is generating our data set. We found that the dynamics of the non-linear, second order viscous Burger's equation could also be well approximated by an ODE which was automatically discovered. We also found an ODE for a 2D temperature distribution model which shows interesting properties for further research. The ODE operators we found are accurate in the region of the training data and are able to extrapolate slightly beyond the training data. The benefit of the ODE models is that they can be solved in fractions of a second on a laptop, compared to the PDE models which require substantial computational resources. \section{Acknowledgements} \label{acknowledgements} Some of the computations were performed on resources provided by The Swedish National Infrastructure for Computing (SNIC) through Uppsala Multidisciplinary Center for Advanced Computational Science (UPPMAX) under Project SNIC 2017/7-131. The authors were partially supported by a grant from the G{\"o}ran Gustafsson Foundation for Research in Natural Sciences and Medicine. \bibliographystyle{abbrv}
\section{Introduction}\label{sec:intr} Optimal Stopping (OS) is a classical topic of research in statistics and operations research going back to the pioneering work of \citet{Wald1947, Wald1949} on sequential analysis. For a thorough discussion of theoretical foundations of OS we can refer to \cite{ShiryaevStopping}, for example. The classical formulation of OS assumes availability of the probability distribution of the considered data process. Of course in real life applications the `true distribution' is never known exactly and in itself can be viewed as uncertain. This motivates to formulate a considered optimization problem in terms of a chosen family of probability distributions. In stochastic optimization this is going back to the pioneering paper of \cite{Scarf}, and is often referred to as the distributionally robust approach to stochastic programming. In a certain sense the distributional robustness can be considered as a dual counterpart of the modern approach to risk measures, cf.\ \cite{artzner1999}. Recently distributionally robust (risk averse) formulations of OS were considered in several publications, e.g., \citet[Section~6.5]{Follmer2004}, \cite{cher2006}, \cite{Karatzas2010}, \cite{Kraetschmer}, \cite{Kraetschmer2016}, \cite{Belom2017}, \cite{Goldenshluger}. However, a straightforward extension of risk neutral stochastic programs to their distributionally robust (risk averse) counterparts involves a delicate issue of time consistency. That is, decisions (optimal policies) designed at the initial time, before observing any realization of the random data process, should not be reconsidered from a perspective of later stages. This is closely related to Bellman’s principle of optimality and to eventual writing of the corresponding dynamic programming equations which is crucial for an efficient numerical solution of such problems. The question of time (in)consistency has been realized very early in economics and management science. \cite{Weller1978} (cf.\ also \cite{Hammond1989}) discusses time consistency in combination with expected utilities. Quoting \citet[p.~263]{Weller1978}: ``I~prove that under certain assumptions, consistency is equivalent to maximizing expected utility on the set of feasible plans, with a restricted set of utility functions and a tree of subjective probability distributions which satisfy the Bayesian updating rule.'' This problem setting puts risk measures in relation to stochastic optimization. In this context, however, it is to mention that \cite{Haviv1996} gives a Markov decision process with constraints, so that the optimal solution does \emph{not} satisfy Bellman's principle. More recently the discussion of consistency properties of risk measures has become popular in financial mathematics. Pioneers include \cite{Wang1999} and \cite{Jobert}, who introduce a concept of dynamic consistency of risk measures themselves. Other authors (e.g., \cite{Weber2006}, \cite{Cheridito2011}, \cite{Ruszczynski2010}) take a similar approach by discussing axioms of risk measures. These publications try to identify properties of risk measures themselves, which are relevant in a general, time consistent framework. Time consistency also respects increasing information, which can be investigated as essential feature of conditional risk measures (cf.\ \cite{Kovacevic2009}). \cite{Schachermayer2009a} show that time consistent and law invariant risk measures have a very specific, entropy like representation which depends on not more than a single parameter. Optimal stopping together with (risk neutral) policy optimization was considered in \cite{hordijk}, but was not developed further. It turns out that optimal stopping problems lead to dynamic equations in the classical (risk neutral) setting. In this paper we extend this in several directions. We combine stopping times and risk measures by introducing \emph{stopping risk measures} and demonstrate how optimal stopping times combine with optimizing over policies (decision rules). The appropriate nested risk measures corresponding to the problem structure entail transition functionals at each stage. Their specific structure is employed to specify dynamic equations and generalized risk martingales. We associated dynamic equations corresponding to optimal stopping and investigate their specific structure. Optimal policies derived from optimal stopping problems are naturally time consistent. We also develop a concept of time consistency in the distributionally robust (risk averse) setting which is naturally amenable to Bellman’s principle of optimality and to formulation of the dynamic programming equations. These equations are similar to dynamic equations in \citet[Theorem 6.52]{Follmer2004} but do not require the restrictive assumption of stability used there (see Remark~\ref{rem-stab} below). Finally we discuss computational approaches to solving such problems and give numerical examples. \paragraph{Outline.} The paper is organized as follows. In Section \ref{sec-optst} we formulate the classical (risk neutral) OS problem in discrete time. Time and dynamic consistency of a general class of multistage optimization problems is discussed in Section \ref{sec-timecon}. In Section \ref{sec:decomp} the respective dynamic programming equations, based on decomposability of the nested formulation, are derived. Time consistent formulations of the distributionally robust (risk averse) OS problems are presented in Section \ref{sec:Stopping}. Finally Section \ref{sec:numeric} is devoted to computational methods and numerical examples. \section{Optimal stopping time} \label{sec-optst} We will use the following framework. Let $(\Omega,{\cal F},P)$ be a probability space and $\mathfrak F:=({\cal F}_0,\dots,{\cal F}_T)$ be a filtration (a sequence of increasing sigma algebras, ${\cal F}_0\subset\cdots\subset{\cal F}_{T}$) with\footnote{The sigma algebra consisting of only two sets, the empty set and the whole space $\Omega$, is called trivial.} ${\cal F}_0=\{\emptyset,\,\Omega\}$ and ${\cal F}_T={\cal F}$. Let ${\cal Z}_0\subset \cdots\subset {\cal Z}_T$ be a sequence of linear spaces of functions $Z\colon\Omega\to\bbr$. We assume that ${\cal Z}_t:=L_p(\Omega,{\cal F}_t,P)$ for some $p\in [1,\infty]$, although more general settings are possible. We denote by $Z_t$ an element of the space ${\cal Z}_t$. Note that an element $Z_t\in {\cal Z}_t$ actually is a class of ${\cal F}_t$-measurable functions which can be different from each other on a set of $P$-measure zero. Since ${\cal F}_0$ is trivial, the space ${\cal Z}_0$ consists of constant functions and will be identified with $\bbr$. Since elements of ${\cal Z}_t$ are ${\cal F}_t$-measurable, a process $Z_t\in {\cal Z}_t$, $t=0,\dots,T$, is adapted to the filtration ${\mathfrak F}$. We use the notation $ {\cal Z}_{t,u}:={\cal Z}_t\times \cdots\times {\cal Z}_u,$ $0\le t<u\le T,$ in particular ${\cal Z}_{0,T}={\cal Z}_0\times \cdots\times {\cal Z}_T$. For elements $Z_{t,u}=(Z_t,\dots,Z_u)$ and $Z'_{t,u}=(Z'_t,\dots,Z'_u)$ of ${\cal Z}_{t,u}$ we write $Z_{t,u}\preceq Z'_{t,u}$ to denote that $Z_\tau(\omega)\le Z_\tau'(\omega)$ for almost every (a.e.), or in other words almost surely (a.s.), (with respect to the reference probability measure $P$) $\omega\in \Omega$, and write $Z_{t,u}\prec Z'_{t,u}$ to denote that $Z_{t,u}\preceq Z'_{t,u}$ and $Z_{t,u}\ne Z'_{t,u}$. By ${\Bbb{E}}_{|{\cal F}}$ or ${\Bbb{E}}[\,\cdot\,|{\cal F}]$ we denote the conditional expectation with respect to sigma field ${\cal F}$. By $\mathds 1} % \usepackage[sans]{dsfont_A$ we denote the indicator function of set $A$. Recall that a \emph{stopping time}, adapted to the filtration ${\mathfrak F}$, is a random variable $\tau\colon\Omega\to \{0,\dots,T\}$ such that $\{\omega\in\Omega\colon\tau(\omega)= t\}\in {\cal F}_t$ for $t=0,\dots,T$. We denote by ${\mathfrak T}$ the set of stopping times (adapted to the filtration ${\mathfrak F}$). For a process $Z_t\in {\cal Z}_t$, $t=0,\dots,T$, the (risk neutral) optimal stopping time problem can be written as \begin{equation}\label{stop-1} \minmax_{\tau\in {\mathfrak T}}{\Bbb{E}}[Z_\tau]. \end{equation} By `$\minmax$' we mean that either the minimization or maximization procedure is applied. Of course, the minimization procedure can be changed to the corresponding maximization simply by changing $Z_\tau$ to $-Z_\tau$. Later we will consider combinations of stoping times and policy optimizations where it will be essential whether a maximization or minimization procedure is considered. We will extend the above stopping time problem in two directions. First, we combine this with cost optimization. Consider objective functions $f_0\colon\bbr^{n_0}\to \bbr$, $f_t\colon\bbr^{n_t}\times \Omega\to \bbr$, and feasibility constraints defined by ${\cal X}_0\subset \bbr^{n_0}$ and multifunctions ${\cal X}_t\colon\bbr^{n_{t-1}}\times \Omega \rightrightarrows\bbr^{n_t}$, $t=1,\dots,T$. It is assumed that $f_t(x_{t-1},\cdot)$ and ${\cal X}_t(x_{t-1},\cdot)$ are ${\cal F}_t$-measurable. A sequence $\pi=\{x_0,\mbox{\boldmath$x$}_1(\cdot),\dots,\mbox{\boldmath$x$}_T(\cdot)\}$ of mappings $\mbox{\boldmath$x$}_t\colon\Omega\to \bbr^{n_t}$, $t=0,\dots,T$, adapted to the filtration\footnote{We use bold notation $\mbox{\boldmath$x$}_t$ for (measurable) mappings in order to distinguish it from deterministic vector $x_t\in \bbr^{n_t}$. Also by writing $\mbox{\boldmath$x$}_t(\cdot)$ we emphasize that this is a function of $\omega\in \Omega$, i.e., is a random variable, rather than a deterministic vector. It is said that the sequence $(x_0,\mbox{\boldmath$x$}_1,\dots,\mbox{\boldmath$x$}_T)$ is adapted to the filtration if $\mbox{\boldmath$x$}_t(\cdot)$ is ${\cal F}_t$-measurable for every $t=1,\dots,T$.} ${\mathfrak F}$ is called a \emph{policy} or a \emph{decision rule}. Since ${\cal F}_0$ is trivial, the first decision $x_0$ is deterministic. A policy $\pi=\{x_0,\mbox{\boldmath$x$}_1,\dots,\mbox{\boldmath$x$}_{T}\}$ is feasible if it satisfies the feasibility constraints, i.e., $x_0\in {\cal X}_0$ and $\mbox{\boldmath$x$}_t(\omega)\in {\cal X}_t(\mbox{\boldmath$x$}_{t-1}(\omega),\omega)$, $t=1,\dots,T$, for a.e. $\omega\in \Omega$. We denote by $\Pi$ the set of feasible policies such that $\big(f_0(x_{0}), f_1(\mbox{\boldmath$x$}_1(\cdot),\cdot), \dots , f_T(\mbox{\boldmath$x$}_{T}(\cdot),\cdot)\big)\in {\cal Z}_{0,T}$. We then consider the following problems \begin{equation} \label{stop-2} \minmax_{\pi\in \Pi}\,\minmax_{\tau\in {\mathfrak T}} {\Bbb{E}}[f_\tau(\mbox{\boldmath$x$}_\tau,\omega)]. \end{equation} The min-min, i.e., minimization with respect to $\pi\in \Pi$ and $\tau\in {\mathfrak T}$, problem~\eqref{stop-2} is a natural formulation aimed at the simultaneous minimization with respect to the decision rules and stopping time. Similarly the max-max formulation is aimed at the simultaneous maximization of $\pi\in \Pi$ and $\tau\in {\mathfrak T}$. The max-min (min-max) formulation~\eqref{stop-2} could be interpreted as a certain type of compromise, we will discuss this later. Second, we consider risk averse counterparts of risk neutral problems of the form~\eqref{stop-1}--\eqref{stop-2}. It is tempting to extend the risk neutral formulations simply by replacing the corresponding expectation operator by an appropriate risk measure (such approach was adopted in some recent publications, e.g., \citet[Section 6.5]{Follmer2004}, \cite{Belom2017}, \cite{Goldenshluger}). However, this has a delicate issue with time consistency considerations. We will discuss time consistency concepts from a somewhat general point of view in the following Sections~\ref{sec-timecon} and~\ref{sec:decomp} and will come back to discussion of optimal stopping time in Section~\ref{sec:Stopping}. Let us finish this section with the following observations. We have that $\Omega$ is the union of the disjoint sets \begin{equation}\label{setomega} \Omega_t^\tau:=\{\omega\colon\tau(\omega)=t\}, \;t=0,\dots,T, \end{equation} and hence $\mathds 1} % \usepackage[sans]{dsfont_\Omega=\sum_{t=0}^T\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}}$. Note that $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=s\}}$ are ${\cal F}_t$ measurable for $0\le s\le t\le T$ and hence $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau\le t\}}$ and $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau> t\}}=\mathds 1} % \usepackage[sans]{dsfont_\Omega-\mathds 1} % \usepackage[sans]{dsfont_{\{\tau\le t\}}$ are also ${\cal F}_t$ measurable for $t=0,\dots,T$. Moreover $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}} Z_\tau=\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}} Z_t$ and thus for $(Z_0,\dots,Z_T)\in {\cal Z}_{0,T}$ it follows that \begin{equation}\label{stopp-1} \begin{array}{lll} Z_\tau = \sum_{t=0}^T\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}}Z_\tau = \sum_{t=0}^T\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}}Z_t. \end{array} \end{equation} By replacing $Z_t$ in~\eqref{stopp-1} with $Z'_t:=Z_0+\dots+Z_t$ we obtain \begin{align} \nonumber Z_0+\dots+Z_\tau &= Z'_\tau = \sum_{t=0}^T\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}}Z'_t = \sum_{t=0}^T\sum_{i=0}^t\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}}Z_i \\ \label{stopp-1a} &= \sum_{t=0}^T\sum_{i=t}^T\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=i\}}Z_t = \sum_{t=0}^T\mathds 1} % \usepackage[sans]{dsfont_{\{\tau\ge t\}}Z_t. \end{align} The problem $\max_{\tau\in {\mathfrak T}}{\Bbb{E}}\left[\sum_{i=1}^\tau Z_i\right]$ can be considered in the framework of problem~\eqref{stop-1} simply by replacing $Z_\tau$ with $Z'_\tau=Z_0+\dots+Z_\tau$, and similarly for problems~\eqref{stop-2}. Finally note that since ${\cal F}_0=\{\emptyset,\,\Omega\}$ is trivial, we have that $\{\omega\colon\tau(\omega)=0\}$ is either $\Omega$ or $\emptyset$, and hence either $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=0\}}Z_0=Z_0$ or $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=0\}}Z_0=0$, and probability of the event $\{\tau=0\}$ is either $0$ or $1$. \medskip Because random variables are defined only up to $P$-almost sure equivalence, it is in general not meaningful to speak of an `$\omega$ by $\omega$' infimum $\inf\{X(\omega)\colon X \in{\cal X}\}$. The essential infimum substitutes for this concept. We use the following concept of essential infimum, cf.\ \citet[Appendix~A]{Karatzas}. \begin{definition}[Essential infimum] \label{def-ess} Let ${\cal X}$ be a nonempty family of random variables defined on $(\Omega,{\cal F},P)$. The essential infimum of ${\cal X}$, denoted by $ \essinf {\cal X}$, is a random variable $X^*$ satisfying: (i) if $X\in {\cal X}$, then $X\ge X^*$ a.s., and (ii) if $Y $ is a random variable satisfying $X \ge Y$ a.s. for all $X\in {\cal X}$, then $X^*\ge Y$ a.s. The essential supremum is defined in the similar way. \end{definition} \section{Time consistency} \label{sec-timecon} In this section we discuss time consistency of multistage optimization problems from a general point of view. Consider a functional $\mathcal{R}\colon{\cal Z}_{0,T}\to \bbr$ and the optimization problem \begin{equation}\label{refm-2} \min_{\pi\in \Pi}\mathcal{R}\big [f_0(x_0),\, f_1( \mbox{\boldmath$x$}_1(\cdot),\cdot),\, \dots,\, f_T(\mbox{\boldmath$x$}_T(\cdot),\cdot) \big], \end{equation} where $\Pi$ is the set of feasible policies as defined in Section \ref{sec-optst}. We refer to $\mathcal{R}$ as a \emph{preference functional} and to~\eqref{refm-2} as the \emph{reference} problem. The principle of optimality, going back to \citet{Bellman}, postulates that an optimal policy computed at the initial stage of the decision process, before any realization of the uncertainty data became available, remains optimal at the later stages. This formulation is quite vague since it is not clearly specified what optimality at the later stages does mean. In some situations this comes naturally and implicitly assumed. However, in more complex cases this could lead to a confusion and misunderstandings. Therefore, in order to proceed, we consider a class of preference relations between possible realizations of random data defined by a family of mappings \begin{equation* \mathcal{R}_{t,u}\colon{\cal Z}_{t,u}\to {\cal Z}_t,\quad 0\le t<u\le T. \end{equation*} We refer to each $\mathcal{R}_{t,u}$ as a \emph{preference mapping} and to the family ${\mathfrak R}=\{\mathcal{R}_{t,u}\}_{0\le t<u\le T}$ as a \emph{preference system}. Since ${\cal Z}_0$ is identified with $\bbr$, we view $\mathcal{R}_{0,T}(Z_0,\dots,Z_T)$ as a real number for any $(Z_0,\dots,Z_T)\in{\cal Z}_{0,T}$. We assume that $\mathcal{R}_{0,T}$ coincides with the preference functional $\mathcal{R}$ of the reference problem~\eqref{refm-2}, i.e., $\mathcal{R}=\mathcal{R}_{0,T}$. \begin{remark} \label{rem-risk} The considered preference system does not necessarily represents a risk averse approach. As we will discuss later, indeed in some settings it can be interpreted as conservative, and hence as risk averse, while in other cases it can be viewed as somewhat optimistic (see, in particular, Remark \ref{rem-max} below). \end{remark} \begin{definition}[Time consistent policies]\label{def-1a} We say that an optimal policy $\bar{\pi}=\{\bar{x}_0,\dots,\bar{\mbox{\boldmath$x$}}_T\}$, solving the reference problem~\eqref{refm-2}, is \emph{time consistent} with respect to the preference system~${\mathfrak R}$, if at stages $t=1,\dots,T-1$, the policy $\{\bar{\mbox{\boldmath$x$}}_t,\dots,\bar{\mbox{\boldmath$x$}}_T\}$ is optimal for \begin{equation} \label{refm-3} \begin{array}{cll} \essinf&\mathcal{R}_{t,T}\big [f_t( \mbox{\boldmath$x$}_t(\cdot),\cdot) , \dots , f_T(\mbox{\boldmath$x$}_T(\cdot),\cdot) \big],\\ {\rm s.t.} & \mbox{\boldmath$x$}_u(\cdot)\in {\cal X}_u(\mbox{\boldmath$x$}_{u-1}(\cdot),\cdot) \;\text{a.s.},\; u=t,\dots,T, \end{array} \end{equation} given $\mbox{\boldmath$x$}_{t-1}=\bar{\mbox{\boldmath$x$}}_{t-1}$. \end{definition} \begin{remark} At stage $t=1,\dots,T$, we already observed a realization of $\bar{\mbox{\boldmath$x$}}_{t-1}$ of the policy~$\bar{\pi}$. The next decision $\mbox{\boldmath$x$}_t$ should satisfy the feasibility constraint $ \mbox{\boldmath$x$}_t(\cdot)\in {\cal X}_t(\bar{\mbox{\boldmath$x$}}_{t-1}(\cdot),\cdot)$, and so on at the later stages. In that sense the optimization in \eqref{refm-3} is performed over policies $(\mbox{\boldmath$x$}_t,\dots,\mbox{\boldmath$x$}_T)$, satisfying the respective feasibility constraints, given $\bar{\mbox{\boldmath$x$}}_{t-1}$. For definition of the concept of essential infimum, used in \eqref{refm-3}, see Definition \ref{def-ess}. \end{remark} It could be noted that we allow for the preference mapping $\mathcal{R}_{t,T}$, $t=1,\dots,T-1$, to depend on realizations of the data process up to time $t$, i.e., we have that $\mathcal{R}_{t,T}(Z_t,\dots,Z_T)$ is ${\cal F}_t$-measurable. However, we do not allow $\mathcal{R}_{t,T}$ to depend on the decisions. Definition~\ref{def-1a} formalizes the meaning of optimality of a solution of the reference problem at the later stages of the decision process. Clearly this framework depends on a choice of the preference system ${\mathfrak R}=\{\mathcal{R}_{t,u}\}_{1\le t<u\le T}$. This suggests the following basic questions: (i)~what would be a `natural' choice of mappings $\mathcal{R}_{t,u}$, (ii)~what properties of mappings $\mathcal{R}_{t,u}$ are sufficient/\,necessary to ensure that every (at least one) optimal solution of the reference problem is time consistent, (iii)~how time consistency is related to dynamic programming equations. As we shall see the last question is closely related to decomposability of $\mathcal{R}_{t,T}$ in terms of one-step mappings $\mathcal{R}_{t,t+1}$. The minimal property that is required for the preference mappings is monotonicity.\footnote{In some publications the monotonicity property is understood in the reverse sense, i.e., $Z_{t,u}\preceq Z^\prime_{t,u}$ implies that $\mathcal{R}(Z_{t,u}){\,\succeq\,} \mathcal{R}(Z^\prime_{t,u})$. In this paper we consider the monotonicity only in the sense of Definition~\ref{def-mon}.} \begin{definition}[Monotonicity]\label{def-mon} We say that preference mapping $\mathcal{R}_{t,u}$ is \emph{monotone} if for any $Z_{t,u},Z'_{t,u}\in {\cal Z}_{t,u}$ such that $Z_{t,u}\preceq Z'_{t,u}$ it follows that $\mathcal{R}(Z_{t,u})\preceq \mathcal{R}(Z'_{t,u})$. We say that preference mapping $\mathcal{R}_{t,u}$ is \emph{strictly monotone} if for any $Z_{t,u},Z'_{t,u}\in {\cal Z}_{t,u}$ such that $Z_{t,u}\prec Z'_{t,u}$ it follows that $\mathcal{R}(Z_{t,u})\prec \mathcal{R}(Z'_{t,u})$. The preference system ${\mathfrak R}=\{\mathcal{R}_{t,u}\}_{0\le t<u\le T}$ is said to be monotone (strictly monotone) if every preference mapping $\mathcal{R}_{t,u}$ is monotone (strictly monotone). \end{definition} \subsection{Additive case} \label{rem-addit} The above framework~\eqref{refm-2}--\eqref{refm-3} is very general. The common case considered in the recent literature on risk averse stochastic optimization is when the reference problem is a function of the total cost. That is, when each $\mathcal{R}_{t,u}$ is representable as a function of $Z_t+\dots+Z_u$, i.e., \begin{equation}\label{pref-add} \mathcal{R}_{t,u}(Z_t,\dots,Z_u):=\rho_{t,T}(Z_t+\dots+Z_u),\ 0\le t<u\le T, \end{equation} for some\footnote{Note that since ${\cal Z}_u\subset {\cal Z}_T$, $u=t+1,\dots,T$, the corresponding mapping $\rho_{t,T}\colon{\cal Z}_u\to {\cal Z}_t$ is defined as restriction of $\rho_{t,T}$ to ${\cal Z}_u$.} $\rho_{t,T}\colon{\cal Z}_T\to {\cal Z}_t$, $t=0,\dots,T$. We will refer to such framework as the \emph{additive case}. We will also consider examples of natural and important preference systems which cannot be considered in the additive framework~\eqref{pref-add}. Consider the following properties of the mapping $\rho_{t,T}$: \begin{enumerate}[noitemsep] \item $\rho_{t,T}(\lambda Z+(1-\lambda)Z')\preceq \lambda\rho_{t,T}(Z) + (1-\lambda)\rho_{t,T}(Z'),\;\;Z,Z'\in {\cal Z}_T,\,\;\lambda\in [0,1]$, \item $\rho_{t,T}(Z+ Z')\preceq \rho_{t,T}(Z) + \rho_{t,T}(Z'),\;\;Z,Z'\in {\cal Z}_T$, \item $\rho_{t,T}(Z+ Z'){\,\succeq\,} \rho_{t,T}(Z) + \rho_{t,T}(Z'),\;\;Z,Z'\in {\cal Z}_T$, \item $\rho_{t,T}(\lambda Z)=\lambda \rho_{t,T}(Z),\;\; Z\in {\cal Z}_T,\;\lambda\ge 0$ and \item $\rho_{t,T}(Z +Z_t)=\rho_{t,T}(Z)+Z_t,\;\; Z \in {\cal Z}_T, Z_t\in {\cal Z}_t$. \end{enumerate} We refer to these properties as \emph{convexity, subadditivity, superadditivity, positive homogeneity and translation equivariance,} respectively. Note that if $\rho_{t,T}$ is positively homogeneous, then $\rho_{t,T}$ is convex iff it is subadditive. With convex mapping $\rho_{t,T}$ is associated its concave counterpart \begin{equation}\label{concave} \nu_{t,T}(Z):=-\rho_{t,T}(-Z). \end{equation} Note that $\nu_{t,T}(Z)$ inherits monotonicity, positive homogeneity and translation equivariance properties of $\rho_{t,T}$, and subadditivity of $\rho_{t,T}$ implies superadditivity of $\nu_{t,T}$. Following \cite{artzner1999} we refer to $\rho_{t,T}$ as (convex) \emph{coherent} if it is subadditive, monotone, positively homogeneous and translation equivariant. The preference system~\eqref{pref-add} is monotone (strictly monotone) if $\rho_{t,T}$ are monotone (strictly monotone). In particular, let $\varrho\colon L_p(\Omega,{\cal F},P)\to\bbr$ be a law invariant coherent risk measure and $\varrho_{|{\cal F}_t}$ be its conditional analogue. Then $\rho_{t,T}:=\varrho_{|{\cal F}_t}$ is the corresponding coherent mapping. When $\varrho:={\Bbb{E}}$ is the expectation operator, the corresponding preference system is given by conditional expectations \begin{equation* \mathcal{R}_{t,u}(Z_t,\dots,Z_u) = {\Bbb{E}}_{|{\cal F}_t} [Z_t+\dots+Z_u],\ 0\le t<u\le T, \end{equation*} which corresponds to the risk neutral setting. As another example take $\varrho:=\avr_\alpha$, where the Average Value-at-Risk measure can be defined as \begin{equation}\label{avr-2} \avr_\alpha (Z):=\inf_{u\in \bbr}\left\{u+(1-\alpha)^{-1}{\Bbb{E}}[Z-u]_+\right\},\; \alpha\in [0,1). \end{equation} For $\alpha=0$ the $\avr_0$ is the expectation operator and for $\alpha=1$ it becomes $\varrho ={\rm ess}\sup$, the essential supremum operator. The risk measure $\avr_\alpha$ is monotone but is not strictly monotone for $\alpha\ne 0$. The conditional analogue of the Average Value-at-Risk~\eqref{avr-2} is \begin{equation*} \avr_{\alpha_t\mid\mathcal F_t}(Z)=\essinf_{u_t\in L_\infty(\mathcal F_t)}\left\{u_t+(1-\alpha_t)^{-1}{\Bbb{E}}_{\mid\mathcal F_t}[Z-u_t]_+\right\},\; \alpha_t\in [0,1). \end{equation*} \begin{example \label{ex-2} Let ${\cal Z}_t:=L_\infty(\Omega,{\cal F}_t,P)$ and\footnote{The conditional essential supremum is the smallest ${\cal F}_t$-random variable ($X_t$, say), so that $Z_{\tau} \preceq X_t$ for all $\tau$ with $t\le \tau\le u$ (see Definition \ref{def-ess}). } \begin{equation* \mathcal{R}_{t,u}(Z_t,\dots,Z_u):=\esssup_{\mathcal F_t} \{Z_{t},\dots,Z_u\},\ 0\le t<u\le T. \end{equation*} The objective of the corresponding reference problem~\eqref{refm-2} is then given by the maximum of the essential supremum of the cost functions in the periods $t=0,\dots,T$. \end{example} In the additive case, the value $\mathcal{R}_{t,u}(Z_{t},\dots,Z_u)$ is a function of the sum $Z_{t}+\dots+Z_u$ and is the same as value of $\mathcal{R}_{t,T}$ applied to $Z_t+\dots+Z_u$ for any $u=t+1,\dots,T$. That is, in that framework there is no point of considering preference mappings $\mathcal{R}_{t,u}$ for $u$ different from $T$. On the other hand, the preference system of Example~\ref{ex-2} is not additive and it is essential there to consider preference mappings $\mathcal{R}_{t,u}$ for $u<T$. \subsection{Two stage setting} \label{sec:twost} It is informative at this point to discuss the two stage case, $T=2$, since time inconsistency could already happen there. Consider the following two stage stochastic program \begin{equation}\label{two-1} \begin{array}{cll} \min\limits_{x_0,\,\mbox{\scriptsize\boldmath$\x$}_1\in {\mathfrak X}} & \mathcal{R}\big(f_0(x_0),f_1(\mbox{\boldmath$x$}_1(\cdot),\omega)\big),\\ {\rm s.t. } & x_0\in {\cal X}_0,\;\mbox{\boldmath$x$}_1(\omega)\in {\cal X}_1(x_0,\omega), \end{array} \end{equation} where ${\mathfrak X} :=\left\{\mbox{\boldmath$x$}_1\colon\Omega\to\bbr^{n_1}\mid f_1(\mbox{\boldmath$x$}_1(\cdot),\cdot)\in {\cal Z} \right\}$ with ${\cal Z}$ being a linear space of measurable functions $Z\colon\Omega\to \bbr$. The preference functional $\mathcal{R}\colon{\cal Z}_{0,1}\to \bbr$ is defined on the space ${\cal Z}_{0,1}=\bbr\times {\cal Z}$. In order to deal with duality issues we consider the following two frameworks for defining the space ${\cal Z}$. In one framework we use, as in the previous section, ${\cal Z}:=L_p(\Omega,{\cal F},P)$, $p\in [1,\infty]$, with $P$ viewed as the reference probability measure (distribution). The space ${\cal Z}$ is paired with the space ${\cal Z}^*=L_q(\Omega,{\cal F},P)$, where $q\in [1,\infty]$ is such that $1/p+1/q=1$, with the respective bilinear form \begin{equation* \langle\zeta,Z\rangle=\int_\Omega \zeta(\omega)Z(\omega)P(d\omega),\;\zeta\in {\cal Z}^*,\;Z\in {\cal Z}. \end{equation*} This framework became standard in the theory of coherent risk measures. However, it is not applicable to the distributionally robust approach when the set of ambiguous distributions is defined by moment constraints and there is no reference probability measure. In that case we assume that $\Omega$ is a compact metric space and use the space ${\cal Z}:=C(\Omega)$ of continuous functions $Z\colon\Omega\to \bbr$. The dual ${\cal Z}^*$ of this space is the space of finite signed Borel measures with the respective bilinear form \begin{equation* \langle\mu,Z\rangle=\int_\Omega Z(\omega) \mu(d\omega),\;\mu\in {\cal Z}^*,\;Z\in {\cal Z}. \end{equation*} Note that in the first framework of ${\cal Z}=L_p(\Omega,{\cal F},P)$, an element $Z\in{\cal Z}$ actually is a class of functions which can differ from each other on a set of $P$-measure zero. The optimization in~\eqref{two-1} is performed over $x_0\in {\cal X}_0\subset \bbr^{n_0}$ and $\mbox{\boldmath$x$}_1\colon\Omega\to\bbr^{n_1}$ such that $f_1(\mbox{\boldmath$x$}_1(\cdot),\cdot)\in {\cal Z}$. The feasibility constraints $\mbox{\boldmath$x$}_1(\omega)\in {\cal X}_1(x_0,\omega)$ in problem~\eqref{two-1} should be satisfied for almost every $\omega\in \Omega$ in the first framework, and for \emph{all} $\omega\in \Omega$ in the second framework of ${\cal Z}=C(\Omega)$. For $Z,Z'\in {\cal Z}$ we use the notation $Z\preceq Z^\prime$ to denote that $Z(\omega)\le Z^\prime(\omega)$ for a.e.\ $\omega\in \Omega$ in the first framework, and for all $\omega\in \Omega$ in the second framework. As before we write $Z\prec Z'$ to denote that $Z\preceq Z'$ and $Z\ne Z'$. The common setting considered in the stochastic programming literature is to define $\mathcal{R}(Z_0,Z_1):=\rho(Z_0+Z_1)$, $(Z_0,Z_1)\in \bbr\times{\cal Z}$, where $\rho\colon{\cal Z}\to\bbr$ is a specified risk functional. This is the additive case discussed in Section \ref{rem-addit}. In particular, when $\rho$ is the expectation operator this becomes the risk neutral formulation. However, there are many other possibilities to define preference functionals $\mathcal{R}$ which are useful in various situations. For example, consider\footnote{We use notation $a\vee b=\max\{a,b\}$ and $a\wedge b=\min\{a,b\}$ for $a,b\in \bbr$.} $\mathcal{R}(Z_0,Z_1):= Z_0\vee \rho(Z_1)$. If moreover, in the framework of ${\cal Z}=C(\Omega)$, we take $\rho(Z):=\sup_{\omega\in \Omega}Z(\omega)$, then the corresponding problem~\eqref{two-1} can be viewed as a robust type problem with minimization of the worst possible outcome of the two stages. That is, if the second stage cost is bigger than the first stage cost for some scenarios, then the worst second stage cost is minimized. On the other hand, if the first stage cost is bigger for all scenarios, then the second stage problem is not considered. Similarly in the framework of ${\cal Z}=L_\infty(\Omega,{\cal F},P)$, we can take $\rho(Z):={\rm ess}\sup (Z)$. This is the case of Example~\ref{ex-2}. As we shall discuss later this is closely related to the problem of optimal stopping time. \bigskip In order to proceed we will need the following interchangeability result for a functional $\varrho\colon{\cal Z}\to\bbr$. Consider a function $\psi\colon\bbr^n\times \Omega\to \bbr\cup\{+\infty\}$. Let \[\Psi(\omega):=\inf_{y\in \bbr^n}\psi(y,\omega)\] and \[{\mathfrak Y}:=\left\{\eta\colon\Omega\to\bbr^n\, |\, \psi_\eta(\cdot)\in{\cal Z} \right\}, \] where $\psi_\eta(\cdot):=\psi\big(\eta(\cdot),\cdot\big)$. \begin{assum} \label{ass-1} In the framework of ${\cal Z}=L_p(\Omega,{\cal F},P)$, suppose that the function $\psi(y,\omega)$ is random lower semicontinous, i.e., its epigraphical mapping is closed valued and measurable (such functions are called normal integrands in \cite{WetsRockafellar97}). In the framework of ${\cal Z}=C(\Omega)$ suppose that the minimum of $\psi(y,\omega)$ over $y\in \bbr^n$ is attained for all $\omega\in \Omega$. \end{assum} We have the following result about interchangeability of the minimum and preference functionals (cf.\ \cite{shapiro2017}). \begin{proposition}[Interchangeability principle]\label{pr-inter} Suppose that Assumption~\ref{ass-1} holds, $\Psi\in {\cal Z}$ and $\varrho\colon{\cal Z}\to\bbr$ is monotone. Then \begin{equation}\label{intpr-1} \varrho(\Psi)=\inf_{\eta\in {\mathfrak Y}}\varrho(\psi_\eta) \end{equation} and \begin{equation}\label{intpr-2} \bar{\eta}(\cdot)\in\operatornamewithlimits{arg\,min}_{y\in \bbr^n} \psi(y,\cdot) \text{ implies }\bar{\eta}\in \operatornamewithlimits{arg\,min}_{\eta\in {\mathfrak Y}}\varrho(\psi_\eta). \end{equation} If moreover $\varrho$ is strictly monotone, then the converse of~\eqref{intpr-2} holds true as well, i.e., \begin{equation}\label{intpr-3} \bar{\eta}\in \operatornamewithlimits{arg\,min}_{\eta\in {\mathfrak Y}}\varrho(\psi_\eta) \text{ implies }\bar{\eta}(\cdot)\in\operatornamewithlimits{arg\,min}_{y\in \bbr^n} \psi(y,\cdot). \end{equation} \end{proposition} In the framework of ${\cal Z}=L_p(\Omega,{\cal F},P)$, it is assumed that $\psi(y,\omega)$ is random lower semicontinous. It follows that the optimal value function $\Psi(\cdot)$ and the multifunction ${\mathfrak G}(\cdot):=\operatornamewithlimits{arg\,min}_{y\in \bbr^n} \psi(y,\cdot)$ are measurable \cite[Chapter 14]{WetsRockafellar97}. In that framework, the meaning of the left hand side of~\eqref{intpr-2} and right hand side of~\eqref{intpr-3} is that $\bar{\eta}(\cdot)$ is a measurable selection of ${\mathfrak G}(\cdot)$. Equation~\eqref{intpr-1} means that the minimization and preference functionals can be interchanged, provided that the preference functional is monotone. Moreover, the pointwise minimizer in the left hand side of~\eqref{intpr-2}, if it exists, solves the corresponding minimization problem in the right hand side. In order to conclude the inverse implication~\eqref{intpr-3}, that the corresponding optimal functional solution is also the pointwise minimizer, the stronger condition of strict monotonicity is needed. Consider now the problem~\eqref{two-1}, that depends on $\omega$, and let \begin{equation*}\label{secst-1} V(x_0,\cdot):=\inf_{x_1\in {\cal X}_1(x_0,\cdot)}\mathcal{R}\big(f_0(x_0),f_1(x_1,\cdot)\big), \end{equation*} which can be viewed as value of the second stage problem. By Proposition~\ref{pr-inter} we have the following. \begin{theorem}\label{th-twost} Suppose that: {\rm (i)} the functional $\varrho(\cdot):=\mathcal{R}(Z_0,\cdot)$ is monotone for any $Z_0\in \bbr$, {\rm (ii)} $V(x_0,\cdot)\in {\cal Z}$ for all $Z_0\in \bbr$, and {\rm (iii)} Assumption~\ref{ass-1} holds for \[\psi(x_1,\omega):=\begin{cases} f_2(x_1,\omega) &{\rm if }\; x_1\in {\cal X}_1(x_0,\omega),\\ +\infty & {\rm if }\; x_1\not\in {\cal X}_1(x_0,\omega). \end{cases}\] Then the optimal value of the problem~\eqref{two-1} is the same as the optimal value of \begin{equation}\label{two-3} \mathop{\rm Min}_{x_0\in {\cal X}_0} \mathcal{R}\big(f_1(x_0),V(x_0,\cdot)\big). \end{equation} Further, $(\bar{x}_0,\bar{\mbox{\boldmath$x$}}_1)$ is an optimal solution of the two stage problem~\eqref{two-1} if $\bar{x}_0$ is an optimal solution of the first stage problem~\eqref{two-3} and\,\footnote{By writing `$\bar{\mbox{\boldmath$x$}}_1(\cdot)\in\dots$' we mean that $\bar{\mbox{\boldmath$x$}}_1(\cdot)$ is a measurable selection and such inclusion holds for a.e.\ $\omega\in \Omega$ in the setting of ${\cal Z}=L_p(\Omega,{\cal F},P)$, and for all $\omega\in \Omega$ in the setting of ${\cal Z}=C(\Omega)$.} \begin{equation}\label{secst-3} \bar{\mbox{\boldmath$x$}}_1(\cdot)\in\operatornamewithlimits{arg\,min}_{x_1\in {\cal X}_1(\bar{x}_0,\cdot)}\mathcal{R}\big(f_0(\bar{x}_0),f_1(x_1(\cdot),\cdot)\big). \end{equation} Moreover, if $\mathcal{R}(Z_0,\cdot)$ is \emph{strictly} monotone, then $(\bar{x}_0,\bar{\mbox{\boldmath$x$}}_1)$ is an optimal solution of problem~\eqref{two-1} if and only if $\bar{x}_0$ is an optimal solution of the first stage problem and~\eqref{secst-3} holds. \end{theorem} Here, time consistency of a policy $(\bar{x}_0,\bar{\mbox{\boldmath$x$}}_1)$, solving the two stage problem~\eqref{two-1}, means that $\bar{\mbox{\boldmath$x$}}_1$ solves the respective second stage problem given $x_0=\bar{x}_0$, i.e., condition~\eqref{secst-3} holds. That is, if $(\bar{x}_0,\bar{\mbox{\boldmath$x$}}_1)$ is not time consistent, then there exists another feasible solution $\tilde{\mbox{\boldmath$x$}}_1$ such that $ f_2(\tilde{\mbox{\boldmath$x$}}_1(\cdot),\cdot)\prec f_2(\bar{\mbox{\boldmath$x$}}_1(\cdot),\cdot)$. Without \emph{strict} monotonicity of $\mathcal{R}$ it could happen that problem~\eqref{two-1} has optimal solutions which do not satisfy condition~\eqref{secst-3} and hence are not time consistent. That is, condition~\eqref{secst-3} is a sufficient but without strict monotonicity is not necessary for optimality. Such examples can be found, e.g., in \cite{shapiro2017} and for robust optimization were given in \cite{DelageIancu}. For example, for $\mathcal{R}(Z_0,Z_1)=Z_0\vee \rho(Z_1)$ we have that if $Z^\prime_1\prec Z_1$ are such that $\rho(Z^\prime_1)<\rho(Z_1)<Z_0$, then $\mathcal{R}(Z_0,Z_1)= \mathcal{R}(Z_0,Z^\prime_1)$. That is, $\mathcal{R}(Z_0,\cdot)$ is not strictly monotone. It could happen then that a second stage decision does not satisfy~\eqref{secst-3} and is not time consistent. \subsection*{Dual representation} The space ${\cal Z}_{0,1}=\bbr\times {\cal Z}$ can be equipped, for example, with the norm $\|(Z_0,Z_1)\|_{0,1}:=|Z_0|+\|Z_1\|$, where $\|\cdot\|$ is the respective norm of the space ${\cal Z}$, and can be paired with the space ${\cal Z}^*_{0,1}=\bbr\times {\cal Z}^*$ with the bilinear form \[ \langle (\zeta_0,\zeta_1),(Z_0,Z_1)\rangle:=\zeta_0\, Z_0+\langle \zeta_1, Z_1 \rangle,\; (\zeta_0,\zeta_1)\in {\cal Z}^*_{0,1},\;(Z_0,Z_1)\in {\cal Z}_{0,1}. \] Suppose that the functional $\mathcal{R}\colon{\cal Z}_{0,1}\to \bbr$ is \emph{convex} and \emph{monotone}. Then by the Klee-Nachbin-Namioka Theorem the functional $\mathcal{R}$ is continuous in the norm topology of ${\cal Z}_{0,1}$ (cf.\ \citet[Proposition 3.1]{Ruszczynski2006}). Suppose further that $\mathcal{R}$ is \emph{positively homogeneous}, i.e., $\mathcal{R}(t\, Z_{0,1})=t\, \mathcal{R}(Z_{0,1})$ for any $t\ge 0$ and $Z_{0,1}\in {\cal Z}_{0,1}$. Then by the Fenchel-Moreau Theorem, $\mathcal{R}$ has the dual representation \begin{equation}\label{dualtwo} \mathcal{R}(Z_0,Z_1)=\sup_{(\zeta_0,\zeta_1)\in {\mathfrak A}_{0,1}}\langle (\zeta_0,\zeta_1),(Z_0,Z_1)\rangle \end{equation} for some convex, bounded and weakly$^*$ closed set \[{\mathfrak A}_{0,1}\subset \{(\zeta_0,\zeta_1)\in {\cal Z}^*_{0,1}\colon \zeta_0\ge 0,\ \zeta_1{\,\succeq\,} 0\}\] (cf.\ \citet[Theorem~2.2]{Ruszczynski2006}). The subdifferential of $\mathcal{R}$ is then given by \begin{equation}\label{dualsub} \partial \mathcal{R}(Z_0,Z_1)=\argmax_{(\zeta_0,\zeta_1)\in {\mathfrak A}_{0,1}}\langle (\zeta_0,\zeta_1),(Z_0,Z_1)\rangle. \end{equation} In particular $\partial \mathcal{R}(0,0)= {\mathfrak A}_{0,1}$. \begin{example} \label{ex-gen} Consider preference functional of the form $\mathcal{R}(Z_0,Z_1):=\varphi(Z_0,\rho(Z_1))$, where $\rho\colon{\cal Z}\to \bbr$ is a coherent risk measure and $\varphi\colon\bbr\times \bbr\to \bbr$ is a convex monotone positively homogeneous function. It follows then that $\mathcal{R}(\cdot,\cdot)$ is convex monotone and positively homogeneous. Let $\rho(Z)=\sup_{\zeta\in {\mathfrak A}}\langle\zeta,Z\rangle$ be the dual representation of $\rho$, where ${\mathfrak A}$ is a convex bounded weakly$^*$ closed subset of ${\cal Z}^*$. Then $\partial\varphi(x_0,x_1)$ consists of vectors (subgradients) $(\gamma_0,\gamma_1)$ such that \[ \varphi(y_0,y_1)-\varphi(x_0,x_1)\ge \gamma_0(y_0-x_0)+\gamma_1(y_1-x_1) \] for all $(y_0,y_1)\in \bbr^2$. Since $\varphi$ is monotone, it follows that $\partial\varphi(x_0,x_1)\subset \bbr_+^2$. Consequently the representation~\eqref{dualtwo} holds with \begin{equation*}\label{dualsub-2} {\mathfrak A}_{0,1}=\partial \mathcal{R}(0,0)=\left \{(\zeta_0,\zeta_1)\in \bbr\times {\cal Z}^*\colon\zeta_1=\gamma_1 \zeta,\;\zeta\in {\mathfrak A},\;(\zeta_0,\gamma_1)\in \partial\varphi(0,0)\right\}. \end{equation*} For example let $\varphi(x_0,x_1):=x_0\vee x_1$, and hence $\mathcal{R}(Z_0,Z_1)=Z_0\vee \rho(Z_1)$. Then $\partial\varphi(0,0)=\{(t,1-t)\colon t\in [0,1]\}$ and \[ {\mathfrak A}_{0,1}=\{(t,(1-t)\zeta)\colon t\in [0,1],\; \zeta\in {\mathfrak A}\}. \] \end{example} \subsection{Dynamic consistency of preference systems}\label{sec:TC} Many authors investigate time consistency by addressing special properties on the preference system itself. This section recalls these concepts and relates these properties to time consistency of optimal policies. The following concept of dynamic consistency (also called time consistency by some authors), applied to the preference systems rather than considered policies, in slightly different forms was used by several authors (cf., \cite{Kreps1978,Wang1999,Epstein2003,Riedel2004, cher2006, Artzner2007, Ruszczynski2010}). \begin{definition}[Dynamical consistency]\label{def-dc} The preference system $\{\mathcal{R}_{t,u}\}_{1\le t<u\le T}$ is said to be \emph{dynamically consistent} if for $1\le s<t<u \le T$ and $(Z_s,\dots,Z_u),(Z'_s,\dots,Z'_u)\in {\cal Z}_{t,u}$ such that $Z_\tau=Z'_\tau,\;\tau=s,\dots,t-1$, the following `forward' implication holds: \begin{equation}\label{appr-3} \text{if }\mathcal{R}_{t,u}(Z_t,\dots,Z_u)\preceq \mathcal{R}_{t,u}(Z'_t,\dots,Z'_u) \text{ then }\mathcal{R}_{s,u}(Z_s,\dots,Z_u)\preceq \mathcal{R}_{s,u}(Z'_s,\dots,Z'_u). \end{equation} \end{definition} It turns out that the above `forward' property of dynamic consistency is not always sufficient to ensure that every optimal policy is time consistent. For that we need a stronger notion of dynamic consistency (cf.\ \citet[Section~6.8.5]{RuszczynskiShapiro2009-2}). \begin{definition}[Strict dynamical consistency]\label{def-4} A dynamically consistent preference system $\{\mathcal{R}_{t,u}\}_{1\le t<u\le T}$ is said to be \emph{strictly dynamically consistent} if in addition to~\eqref{appr-3} the following implication holds: \begin{equation}\label{appr-4} \text{if }\mathcal{R}_{t,u}(Z_t,\dots,Z_u)\prec \mathcal{R}_{t,u}(Z'_t,\dots,Z'_u) \text{ then }\mathcal{R}_{s,u}(Z_s,\dots,Z_u)\prec \mathcal{R}_{s,u}(Z'_s,\dots,Z'_u) \end{equation} for all $1\le s<t<u \le T$. \end{definition} Note that it follows from~\eqref{appr-3} that \begin{equation*}\label{appr-eqv} \mathcal{R}_{t,u}(Z_t,\dots,Z_u)= \mathcal{R}_{t,u}(Z'_t,\dots,Z'_u) \text{ implies }\mathcal{R}_{s,u}(Z_s,\dots,Z_u)= \mathcal{R}_{s,u}(Z'_s,\dots,Z'_u). \end{equation*} Recall that in the additive case, $\mathcal{R}_{t,T}(Z_t,\dots,Z_T)$ is given by $\rho_{t,T}(Z_t+\dots+Z_T)$. In that case condition~\eqref{appr-3} implies that \begin{equation}\label{mul-a} \text{if }Z,Z'\in {\cal Z}_T\; {\rm and } \;\rho_{t,T}(Z)\preceq \rho_{t,T}(Z') \text{ then }\rho_{s,T}(Z)\preceq \rho_{s,T}(Z'),\;\;1\le s<t\le T-1. \end{equation} Conversely, if moreover $\rho_{s,T}$ is translation equivariant, then we can write for $1\le s<t\le T$, \[ \rho_{t,T}(Z_s+\dots+Z_T)=Z_s+\dots+Z_{t-1}+ \rho_{t,T}(Z_t+\dots+Z_T), \] and hence condition~\eqref{mul-a} implies~\eqref{appr-3} for $u=T$. If $\rho_{t,T}:={\Bbb{E}}_{|{\cal F}_t}$, then for $s<t$ we have that $\rho_{s,T}(Z)={\Bbb{E}}_{|{\cal F}_s}[\,{\Bbb{E}}_{|{\cal F}_t}(Z)]$ and hence this preference system is dynamically consistent. In fact it is not difficult to see that this preference system is strictly dynamically consistent. Similar to the additive case we have the following result (cf.\ \citet[Propositions~6.80]{RuszczynskiShapiro2009-2}). \begin{proposition}\label{pr-din1} The following holds true: {\rm (i)} If the preference system is dynamically consistent and $\bar{\pi}\in \Pi$ is the unique optimal solution of the reference problem~\eqref{refm-2}, then $\bar{\pi}$ is time consistent. {\rm (ii)} If the preference system is strictly dynamically consistent, then every optimal solution of the reference problem is time consistent. \end{proposition} \section{Decomposability and dynamic equations} \label{sec:decomp} Let us start with definition of the following basic decomposability concept. \begin{definition}[Recursivity]\label{def:rec-a} The preference system $\{\mathcal{R}_{t,u}\}_{0\le t<u\le T}$ is said to be \emph{recursive}, if \begin{equation}\label{eq:Rec} \mathcal{R}_{t,u} (Z_{t},\dots, Z_u )= \mathcal{R}_{t,v}\big(Z_t,\dots, Z_{v-1}, \mathcal{R}_{v,u}(Z_{v},\dots, Z_u)\big) \end{equation} for any $0\le t<v<u\le T$ and $(Z_t,\dots, Z_u)\in {\cal Z}_{t,u}$. \end{definition} We have the following relation between recursivity and dynamic consistency (discussed in Section~\ref{sec:TC}). \begin{proposition} \label{pr-decom} Suppose that preference mappings $\mathcal{R}_{t,u}$, $1\le t<u\le T$, are monotone (strictly monotone) and recursive. Then $\{\mathcal{R}_{t,u}\}_{1\le t<u\le T}$ is dynamically consistent (strictly dynamically consistent). \end{proposition} \begin{proof} We need to verify the implication~\eqref{appr-3}. By recursivity, for $1\le s<t<u\le T$, we have \begin{align*} \mathcal{R}_{s,u}(Z_s,\dots,Z_u) &= \mathcal{R}_{s,t}\big(Z_s,\dots, Z_{t-1}, \mathcal{R}_{t,u}(Z_{t},\dots, Z_u)\big)\text{ and}\\ \mathcal{R}_{s,u}(Z'_s,\dots,Z'_u)&= \mathcal{R}_{s,t}\big(Z'_s,\dots, Z'_{t-1}, \mathcal{R}_{t,u}(Z'_{t},\dots, Z'_u)\big). \end{align*} Assuming $Z_\tau=Z'_\tau$, $\tau=s,\dots,t-1$ the implication~\eqref{appr-3} (the implication~\eqref{appr-4}) follows by monotonicity (strict monotonicity) of $\mathcal{R}_{s,t}$. \end{proof} It follows then by Proposition \ref{pr-din1}(ii) that if the system is recursive and the preference mappings are strictly monotone, then every optimal solution of the reference problem is time consistent. As already mentioned, without \emph{strict} monotonicity the recursivity property does not necessarily imply time consistency of \emph{every} optimal solution. \\ In the additive case (discussed in Section~\ref{rem-addit}), when $\mathcal{R}_{t,T}(Z_t,\dots,Z_T)=\rho_{t,T}(Z_{t}+\dots+Z_T)$, $t=0,\dots,T-1$, the recursive property can be written as \begin{equation}\label{addrec} \rho_{t,T}(\rho_{v,T}(Z))=\rho_{t,T}(Z),\;Z\in {\cal Z}_T,\ 0\le t<v\le T-1. \end{equation} Note that since $\rho_{v,T}(Z)\in {\cal Z}_v$, we have that $\rho_{t,T}(\rho_{v,T}(Z))=\rho_{t,v}(\rho_{v,T}(Z)).$ By applying~\eqref{addrec} recursively for $v=t+1,\dots,T-1$, this means that $\rho_{t,T}$ can be decomposed as \begin{equation}\label{sum-1} \rho_{t,T}(Z)= \rho_{t,T}\big(\rho_{t+1,T}\left (\cdots\rho_{T-1,T}(Z)\right )\big),\;Z\in {\cal Z}_T. \end{equation} If moreover $\rho_{t,T}$ is translation equivariant, this becomes \begin{equation}\label{sum-2} \rho_{t,T}(Z_t+\dots+Z_T)= Z_t+\rho_{t,T}\big(Z_{t+1}+ \rho_{t+1,T}(Z_{t+2})+\cdots+ \rho_{T-1,T}(Z_T)\big). \end{equation} For a law invariant convex coherent measure $\varrho$ and $\rho_{t,T}:=\varrho_{|{\cal F}_t}$, the recursive property~\eqref{addrec} can hold only in two cases -- for the `expectation' and the $`{\rm ess}\sup$' operators (cf.\ \cite{Schachermayer2009a}). For example the Average Value-at-Risk preference system, $\rho_{t,T}:=\avr_{\alpha|{\cal F}_t}$, is not recursive for $\alpha\in (0,1)$. Recursive preference system, in the additive case, can be constructed in the nested form \begin{equation}\label{sum-3} \rho_{t,T}(Z):= \phi_t\big(\phi_{t+1}\left (\cdots\phi_{T-1}(Z)\right )\big),\;Z\in {\cal Z}_T, \end{equation} where $\phi_s\colon{\cal Z}_{s+1}\to {\cal Z}_s$, $s=1,\dots,T-1$, are one-step mappings. For example, taking $\varrho:=\avr_\alpha$ this becomes \begin{equation*}\label{eq:nAVaR2} \rho_{t,T}(\cdot) =\avr_{\alpha|{\cal F}_{t}}\big (\avr_{\alpha|{\cal F}_{t+1}}(\cdots \avr_{\alpha|{\cal F}_{T-1}}(\cdot))\big), \end{equation*} the so-called \emph{nested Average Value-at-Risk} mappings. As it was pointed out above, for $\alpha\in (0,1)$ these nested Average Value-at-Risk mappings are different from the $\avr_{\alpha|{\cal F}_{t}}$. Consider now the general case of the preference system $\{\mathcal{R}_{t,u}\}_{1\le t<u\le T}$. The recursive property~\eqref{eq:Rec} implies that $\mathcal{R}_{t,u}$ can be decomposed in terms of one step mappings $\mathcal{R}_{s,s+1}$, $s=t,\dots,u-1$, as \begin{equation}\label{decom-1} \mathcal{R}_{t,u} (Z_t,\dots, Z_u )= \mathcal{R}_{t,t+1}\Big(Z_t, \mathcal{R}_{t+1,t+2}\big(Z_{t+1},\cdots, \mathcal{R}_{u-1,u}(Z_{u-1}, Z_u)\big)\Big). \end{equation} Conversely recursive preference mappings can be constructed in the form~\eqref{decom-1} by choosing one step mappings $\mathcal{R}_{s,s+1}\colon{\cal Z}_s\times {\cal Z}_{s+1}\to{\cal Z}_s$, $s=1,\dots,T-1$. \subsection{Dynamic programming equations} The recursive property~\eqref{eq:Rec} and monotonicity of the preference system allow to write the following dynamic programming equations for the reference problem~\eqref{refm-2}, derivations are similar to the two stage case discussed in Section~\ref{sec:twost}. At the terminal stage~$T$ the cost-to-go function is defined as \begin{equation}\label{dynmar-1} V_T(x_{T-1},\omega):=\essinf_{x_T\in {\cal X}_T(x_{T-1},\omega)} f_T(x_T,\omega). \end{equation} Suppose that $x_0,\dots,\mbox{\boldmath$x$}_{T-1}$ are given. Since $\mathcal{R}=\mathcal{R}_{0,T}$ we have by the interchangeability principle (Proposition~\ref{pr-inter}) and recursivity that \begin{align}\label{eq:17} \inf_{\mbox{\boldmath\scriptsize$x$}_T \in {\cal X}_T(\mbox{\boldmath\scriptsize$x$}_{T-1},\cdot)}&\mathcal{R}\big[f_0(x_0) , \dots , f_T(\mbox{\boldmath$x$}_{T}(\cdot),\cdot)\big]\\ &= \mathcal{R}\big[f_0(x_0), \dots , f_{T-1}(\mbox{\boldmath$x$}_{T-1},\omega), \inf_{\mbox{\boldmath\scriptsize$x$}_T \in {\cal X}_T(\mbox{\boldmath\scriptsize$x$}_{T-1},\omega)} f_T(\mbox{\boldmath$x$}_{T},\omega)\big]\nonumber\\ & = \mathcal{R}_{0,T}\big[f_0(x_0), \dots, f_{T-2}(\mbox{\boldmath$x$}_{T-2},\omega), f_{T-1}(\mbox{\boldmath$x$}_{T-1},\omega),\, V_T(x_{T-1},\omega)\big]\nonumber\\ &=\mathcal{R}_{0,T} \big[f_0(x_0), \dots,f_{T-2}(\mbox{\boldmath$x$}_{T-2},\omega), \mathcal{R}_{T-1,T}[f_{T-1}(\mbox{\boldmath$x$}_{T-1},\omega),\, V_T(x_{T-1},\omega)]\big],\nonumber \end{align} assuming that $V_T(\mbox{\boldmath$x$}_{T-1},\cdot)\in {\cal Z}_T$. Continuing this backward in time we obtain at stages $t=T-1,\dots,1$, the cost-to-go functions \begin{equation}\label{dynmar-2} V_t(x_{t-1},\omega):= \essinf_{x_t\in {\cal X}_t(x_{t-1},\omega)}\mathcal{R}_{t,t+1} \big(f_t(x_t,\omega),\ V_{t+1}(x_t,\omega)\big), \end{equation} representing the corresponding dynamic programming equations. Finally, at the first stage, the problem \begin{equation* \min_{x_0\in{\cal X}_0}\mathcal{R}_{0,1}\big(f_0(x_0),\ V_1(x_0,\cdot)\big) \end{equation*} should be solved. We conclude with~\eqref{eq:17} that \begin{equation}\label{dynmar-3} V_0:=\min_{\pi\in \Pi}\mathcal{R}\big [f_0(x_0),\, f_1(\mbox{\boldmath$x$}_1(\cdot),\cdot),\, \dots,\, f_T(\mbox{\boldmath$x$}_T(\cdot),\cdot) \big] \end{equation} for the recursive preference system $\mathcal{R}$. In a rudimentary form such approach to writing dynamic equations with relation to time consistency was outlined in \cite{Shapiro2009}. \begin{definition}[Dynamic programming equations] We say that a policy $\pi=(x_0,\mbox{\boldmath$x$}_1,\dots,\mbox{\boldmath$x$}_T)$ satisfies the \emph{dynamic programming equations}~\eqref{dynmar-1}, \eqref{dynmar-2} and~\eqref{dynmar-3} if \begin{align} \mbox{\boldmath$x$}_T(\cdot)&\in \operatornamewithlimits{arg\,min}\limits_{x_T\in {\cal X}_T(\mbox{\scriptsize\boldmath$\x$}_{T-1},\,\cdot)} f_T(x_T,\cdot),\label{suff0}\\ \mbox{\boldmath$x$}_{t}(\cdot)&\in \operatornamewithlimits{arg\,min}\limits_{x_t\in {\cal X}_t(x_{t-1},\cdot)}\mathcal{R}_{t,t+1} \big(f_t(x_t,\cdot),\,V_{t+1}(x_t,\cdot)\big), \;t=1,\dots,T-1,\label{suff}\\ x_0&\in \operatornamewithlimits{arg\,min}\limits_{x_0\in{\cal X}_0} \mathcal{R}_{0,1} (f_0(x_0),\,V_1(x_0,\cdot) ).\label{suffT} \end{align} \end{definition} If a policy satisfies the dynamic programming equations, then it is optimal for the reference multistage problem~\eqref{refm-2} and is time consistent. Without strict monotonicity it could happen that a policy, which is optimal for the reference problem~\eqref{refm-2}, does not satisfy the dynamic programming equations and is not time consistent. As it was discussed in Section~\ref{sec:twost} this could happen even in the two stage case and a finite number of scenarios. \begin{remark} Consider the additive case where $\mathcal{R}_{t,t+1}(Z_t,Z_{t+1})=\rho_{t,T}(Z_t+Z_{t+1})$. If moreover mappings $\rho_{t}$ are translation equivariant, this becomes \begin{equation}\label{ones-0} \mathcal{R}_{t,t+1}(Z_t,Z_{t+1})=Z_t+ \rho_{t,T}(Z_{t+1}). \end{equation} Suppose further that mappings $\rho_{t,T}$ are decomposable via a family of one-step coherent mappings $\phi_t$, as in~\eqref{sum-3}. In that case equations~\eqref{dynmar-1}--\eqref{dynmar-3} coincide with the respective equations of the additive case (cf.\ \cite{Ruszczynski}). \end{remark} \begin{example} \label{ex-d1} Let us define one step mappings as \begin{equation}\label{onestep-1} \mathcal{R}_{s,s+1}(Z_s,Z_{s+1}):= Z_s\vee \varrho_{|{\cal F}_s}(Z_{s+1}), \quad s=0,\dots,T-1, \end{equation} and the corresponding preference mappings of the form~\eqref{decom-1}, where $\varrho$ is a law invariant coherent measure. In particular for $\varrho:={\rm ess}\sup$ we obtain the preference system of Example~\ref{ex-2}. Here the dynamic equations~\eqref{dynmar-2} take the form \begin{equation}\label{dyn-stop1} V_t(x_{t-1},\omega)= \essinf_{x_t\in {\cal X}_t(x_{t-1},\omega)} \left\{ f_t(x_t,\omega)\vee \varrho_{|{\cal F}_t}\left(V_{t+1}(x_t,\omega)\right)\right\}, \end{equation} and the reference problem can be viewed as minimization of the worst possible outcome over the considered period of time measured in terms of the measure $\varrho$. As we shall see in Section \ref{sec-mos}, this example is closely related to the stopping time risk averse formulation of multistage programs. \end{example} \section{Time consistent optimal stopping} \label{sec:Stopping} In this section we discuss a combination of the optimal stopping time and time consistent formulations of multiperiod preference measures. \begin{definition} Let $\varrho_{t|{\cal F}_t}\colon{\cal Z}_{t+1}\to{\cal Z}_{t}$, $t=0,\dots,T-1$, be monotone, translation equivariant mappings and consider the corresponding mappings $\rho_{s,t}\colon{\cal Z}_t\to{\cal Z}_s$ represented in the nested form \begin{equation}\label{stopp-2} \rho_{s,t}(\cdot):=\varrho_{s|{\cal F}_s} \big(\varrho_{s+1|{\cal F}_{s+1}}\left (\cdots\varrho_{t-1|{\cal F}_{t-1}}(\cdot)\right )\big),\;0\le s<t\le T. \end{equation} The \emph{stopping risk measure} is \begin{equation}\label{stopp-3} \rho_{0,T}(Z_\tau)= \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=0\}}Z_0 + \varrho_{0|{\cal F}_0}\left(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=1\}}Z_1 +\cdots +\varrho_{T-1|{\cal F}_{T-1}}(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}Z_T) \right). \end{equation} \end{definition} The stopping risk measure is well-defined by virtue of~\eqref{stopp-1} and the translation equivariance of the mappings $\varrho_{t|{\cal F}_{t}}$. Since ${\cal F}_0$ is trivial, the corresponding functional $\ \rho_{0,T}\colon{\cal Z}_T\to \bbr$ is real valued. In the risk neutral case when $\varrho_{t|{\cal F}_t}:={\Bbb{E}}_{|{\cal F}_t}$, we have that $\rho_{s,t}={\Bbb{E}}_{|{\cal F}_s}$ for $0\le s<t\le T$, in particular $\rho_{0,T}= {\Bbb{E}}_{|{\cal F}_0}={\Bbb{E}}$, hence \begin{equation} \label{stopp-4} {\Bbb{E}}(Z_\tau)= {\Bbb{E}}\left[\sum_{t=0}^T\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\}}Z_t\right]= \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=0\}}Z_0 + {\Bbb{E}}_{|{\cal F}_0}\left(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=1\}}Z_1 +\cdots +{\Bbb{E}}_{|{\cal F}_{T-1}}(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}Z_T) \right). \end{equation} The stopping time risk measure suggests the following counterpart of the risk neutral stopping time problem~\eqref{stop-1} (recall that by `$\minmax$' we mean that either the minimization or maximization procedure is applied): \begin{equation}\label{stop-risk} \minmax_{\tau\in {\mathfrak T}}\rho_{0,T}(Z_\tau). \end{equation} As it was argued in the previous sections, the above formulation~\eqref{stop-risk} can be viewed as time consistent and is amenable to writing the dynamic programming equations. \subsection{Distributionally robust approach} It is possible to view the stopping time formulation~\eqref{stop-risk} from the following distributionally robust point of view. Consider a \emph{convex} coherent functional $\varrho\colon L_p(\Omega,{\cal F},P)\to\bbr$. It can be represented in the dual form \begin{equation}\label{riskdual} \varrho (Z)=\sup_{Q\in {\mathfrak M}}{\Bbb{E}}_Q[Z], \end{equation} where ${\mathfrak M}$ is a set of probability measures absolutely continuous with respect to the reference probability measure $P$ and such that the densities $dQ/dP$, $Q\in {\mathfrak M}$, form a bounded convex weakly$^*$ closed set ${\mathfrak A}\subset L_q(\Omega,{\cal F},P)$ in the dual space $L_q(\Omega,{\cal F},P)=L_p(\Omega,{\cal F},P)^*$. For the concave counterpart $-\varrho(-Z)$ of $\varrho$ (see~\eqref{concave}), the corresponding dual representation is obtained by replacing `sup' in~\eqref{riskdual} with `inf', that is \[ -\varrho(-Z)=\inf_{Q\in {\mathfrak M}}{\Bbb{E}}_Q[Z]. \] Conversely, given a set ${\mathfrak M}$ of probability measures absolutely continuous with respect to the reference probability measure $P$ and such that the densities $dQ/dP$, $Q\in {\mathfrak M}$, form a bounded convex weakly$^*$ closed set ${\mathfrak A}\subset L_q(\Omega,{\cal F},P)$, one can use the righthand side of~\eqref{riskdual} as a definition of the corresponding functional $\varrho$. The so defined functional $\varrho$ is convex coherent. It is law invariant iff the set ${\mathfrak A}$ is law invariant in the sense that if $\zeta\in {\mathfrak A}$ and $\zeta'$ is a density distributionally equivalent\footnote{It is said that $\zeta$ and $\zeta'$ are distributionally equivalent if $P(\zeta\le z)=P(\zeta'\le z)$ for all $z\in \bbr$.} to $\zeta$, then $\zeta'\in {\mathfrak A}$. This holds even if the reference probability measure $P$ has atoms (cf.\ \citet[Theorem~2.3]{shapiro2017}). Since ${\Bbb{E}}_Q[\,\cdot\,]= {\Bbb{E}}_Q\big[{\Bbb{E}}_Q [\,\cdot\,|{\cal F}_t]\big]$, for $Q\in {\mathfrak M}$, we have that \begin{equation}\label{recsup} \sup_{Q\in {\mathfrak M}}{\Bbb{E}}_Q[\,\cdot\,]=\sup_{Q\in {\mathfrak M}}{\Bbb{E}}_Q\big[{\Bbb{E}}_Q [\,\cdot\,|{\cal F}_t]\big ]\le \sup_{Q\in {\mathfrak M}}{\Bbb{E}}_Q\big[\,\esssup_{Q\in {\mathfrak M}}{\Bbb{E}}_Q [\,\cdot\,|{\cal F}_t]\big ]. \end{equation} The functional $\varrho_{|{\cal F}_t}(\cdot):=\esssup_{Q\in {\mathfrak M}}{\Bbb{E}}_Q [\,\cdot\,|{\cal F}_t]$ can be viewed as the conditional counterpart of the corresponding functional $\varrho$. Equality in~\eqref{recsup} would mean the recursive property $\varrho(\cdot)= \varrho(\varrho_{|{\cal F}_t}(\cdot))$. In the law invariant case and when the reference probability measure is nonatomic, the functional $\varrho$ has such recursive property only when the set ${\mathfrak M}$ is a singleton or consists of all probability measures absolutely continuous with respect to the reference measure (cf.\ \cite{Schachermayer2009a}). The nested functional $\rho_{0,T}$, defined in~\eqref{stopp-2}, is decomposable, i.e., has the recursive property~\eqref{addrec}. For not decomposable (law invariant) risk measure $\varrho$ the corresponding \emph{nested} stopping objective $\rho_{0,T}(Z_\tau)$, of the form~\eqref{stopp-3}, is different from $\varrho(Z_\tau)$. As we shall see below the \emph{nested} formulation of stopping time is amenable for writing dynamic programming equations, and in the sense of nested decomposition is time consistent. \begin{remark} \label{rem-stab} In some recent publications it was suggested to consider the following formulation of distributionally robust (risk averse) optimal stopping time problems \begin{equation}\label{form} \max_{\tau\in {\mathfrak T}}\left\{\varrho(Z_\tau):=\inf_{Q\in {\mathfrak M}} {\Bbb{E}}_Q[Z_\tau]\right\}. \end{equation} As it is pointed above, unless the set ${\mathfrak M}$ is a singleton or consists of all probability measures, this is not the same as the corresponding nested formulation. In order to deal with this, and eventually to write the associated dynamic equations, it was assumed in \citet[Section 6.5]{Follmer2004} that the set ${\mathfrak M}$ possesses a certain property, called stability. By the above discussion it appears that such stability property will hold only in rather exceptional cases. \end{remark} \begin{remark} \label{rem-max} Consider the maximization variant of problem~\eqref{stop-risk}. By the dual representation~\eqref{riskdual}, such formulation with \emph{convex} preference functional can be viewed as somewhat optimistic; hoping that the uncertainty of the probability distribution, represented by the respective set ${\mathfrak M}$, works in our favor potentially giving a larger value of the return $Z_\tau$. From the risk averse (pessimistic) point of view it makes more sense either to use the corresponding concave counterpart $\nu_{0,T}$ (defined in~\eqref{concave}), or to work with the minimization variant while employing the convex preference functional. As we shall see later these considerations raise delicate issues of preserving convexity of considered problems which is crucial for efficient numerical procedures. \end{remark} \subsection{Multistage risk averse optimal stopping time} \label{sec-mos} By employing nested functionals\footnote{Recall that the considered nested functionals are assumed to be monotone and translation equivariant, while can be convex or concave.} $\rho_{0,T}$ of the form~\eqref{stopp-2}, and by using~\eqref{stopp-1}, the corresponding optimal stopping time counterparts of problems~\eqref{stop-2} can be written as \begin{equation} \label{stp-max} \minmax_{\pi\in \Pi}\,\minmax_{\tau\in {\mathfrak T}}\rho_{0,T}\left(f_\tau(\mbox{\boldmath$x$}_\tau,\omega)\right), \end{equation} with \begin{equation} \label{refm-Stop2} \begin{array}{lll} \rho_{0,T}( f_\tau(\mbox{\boldmath$x$}_{\tau},\omega)) =& \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=0\}} f_0(x_0) + \varrho_{0|{\cal F}_0}\big(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=1\}}f_1(\mbox{\boldmath$x$}_{1},\omega)+ \\ & \cdots +\varrho_{T-1|{\cal F}_{T-1}}(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}} f_T(\mbox{\boldmath$x$}_{T},\omega) \big). \end{array} \end{equation} \begin{remark} It is also possible to consider optimization of $\rho_{0,T}\big(f_0(x_0) +\dots+ f_\tau(\mbox{\boldmath$x$}_{\tau},\omega)\big)$ by using~\eqref{stopp-1a} rather than~\eqref{stopp-1}, i.e., by replacing the cost function $f_\tau(\mbox{\boldmath$x$}_{\tau},\omega)$ with the cumulative cost $f_0(x_0) +\dots+ f_\tau(\mbox{\boldmath$x$}_{\tau},\omega)$ (for the risk neutral case and fixed stopping time $\tau$ this type of problems were considered recently in \cite{Guigues2018}). These formulations are equivalent and we concentrate below on the formulations~\eqref{stp-max}. \end{remark} The problems~\eqref{stp-max} are twofold, they consist in finding simultaneously an optimal policy $\pi^*=(x_0^*,\mbox{\boldmath$x$}_1^*\dots,\mbox{\boldmath$x$}^*_T)$ and an optimal stopping time $\tau^*\in{\mathfrak T}$. In the risk neutral case when $\varrho_{t|{\cal F}_{t}}={\Bbb{E}}_{|{\cal F}_{t}}$, for a given (fixed) policy $\pi\in \Pi$, these problems become the classical problem~\eqref{stop-1} of stopping time for the process \begin{equation} \label{process} Z_t(\omega):=f_t\big(\mbox{\boldmath$x$}_t(\omega),\omega\big). \end{equation} For a given stopping time $\tau\in {\mathfrak T}$ we can write the corresponding dynamic programming equations, of the form~\eqref{dynmar-2}, for the minimization (with respect to $\pi\in \Pi$) problem~\eqref{stp-max} (cf.\ \cite{Ruszczynski}) \begin{align} V^\tau_T({ x}_{T-1},\omega)&:=\essinf_{x_T\in{\cal X}_t(x_{T-1},\omega)} \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\} } f_T(x_T,\omega), \label{eq:1}\\ V^\tau_t(x_{t-1},\omega)&:=\essinf_{x_t\in{\cal X}_t(x_{t-1},\omega)} \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=t\} } f_t(x_t,\omega)+ \varrho_{t|{\cal F}_t}\big(V^\tau_{t+1}(x_t,\omega)\big), \label{eq:2} \end{align} $ t=1,\dots,T-1$, and the first stage problem at $t=0$ is (note that $\varrho_{0|{\cal F}_0}=\varrho_0$) \begin{equation*}\label{first} \min_{x_0\in {\cal X}_0} f_0(x_0)+\varrho_0 \big(V^\tau_{1}(x_0,\omega)\big). \end{equation*} \subsubsection{The min-max problem} \label{sec-min-max} Let us consider the min-max (minimization with respect to $\pi\in \Pi$~-- maximization with respect to $\tau\in {\mathfrak T}$) variant of problem~\eqref{stp-max}. For a fixed policy $\pi=(x_0,\mbox{\boldmath$x$}_1,\dots,\mbox{\boldmath$x$}_T)\in \Pi$ we need to solve the optimal stopping time problem \begin{equation}\label{minopt} \max_{\tau\in {\mathfrak T}} \left\{\rho_{0,T}(Z_\tau)= \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=0\}}Z_0+\varrho_{0|{\cal F}_0}\big(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=1\}}Z_1+ \cdots +\varrho_{T-1|{\cal F}_{T-1}}(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}} Z_T) \big)\right\}, \end{equation} with $Z_t$ given in~\eqref{process}. The following is a natural extension of the classical results in the risk neutral case to the considered risk averse setting~\eqref{minopt}, e.g., \citet[Section 2.2]{ShiryaevStopping}. \begin{definition}[Snell envelope] Let $(Z_0,\dots,Z_T)\in {\cal Z}_{0,T}$ be a stochastic process. The Snell envelope (associated with functional $\rho_{0,T}$) is the stochastic process \begin{align} E_T&:= Z_T,\nonumber\\ E_t&:= Z_t\vee \varrho_{t|{\cal F}_t}(E_{t+1}),\quad t=0,\dots,T-1, \label{eq:SnellZ} \end{align} defined in backwards recursive way. \end{definition} For $m=0,\dots,T$, consider ${\mathfrak T}_m:=\{\tau\in {\mathfrak T}\colon\tau\ge m\}$, the optimization problem \begin{equation}\label{optvalue} \max_{\tau\in {\mathfrak T}_m} \rho_{0,T}(Z_\tau), \end{equation} and \begin{equation}\label{optsol} \tau^*_m(\omega):=\min\{t\colon E_t(\omega)=Z_t(\omega),\;m\le t\le T\},\;\omega\in \Omega. \end{equation} Denote by ${\mathfrak v}_m$ the optimal value of the problem~\eqref{optvalue}. Of course, for $m=0$, the problem~\eqref{optvalue} coincides with problem~\eqref{minopt} and ${\mathfrak v}_0$ is the optimal value of problem~\eqref{minopt}. Note that by the recursive property~\eqref{addrec} we have that\footnote{By the definition $\rho_{T,T}(Z_T)\equiv Z_T$.} $\rho_{0,T}(Z_\tau)=\rho_{0,m}(\rho_{m,T}(Z_\tau))$, $m=1,\dots,T$. The following assumption was used by several authors under different names (see, for example, \cite{Cheridito2009}, where it is called \emph{local property} and references therein): \begin{equation}\label{local} \varrho_{t|{\cal F}_t}(\mathds 1} % \usepackage[sans]{dsfont_A\cdot Z)=\mathds 1} % \usepackage[sans]{dsfont_A\cdot\varrho_{t|{\cal F}_t}(Z),\quad\text{ for all }A\in{\cal F}_t,\;t=0,\dots,T-1. \end{equation} For coherent mappings $\varrho_{t|{\cal F}_t}$ it always holds (cf.\ \citet[Theorem~6.70]{RuszczynskiShapiro2009-2}). The following can be compared with classical results in the risk neutral case (e.g.,\ \citet[Theorem 1]{BinPes2008}). \begin{theorem \label{thm:VerificationZ} Let $\varrho_{t|{\cal F}_t}\colon{\cal Z}_{t+1}\to{\cal Z}_{t}$, $t=0,\dots,T-1$, be monotone translation equivariant mappings possessing property~\eqref{local} and $\rho_{s,t}$, $0\le s<t\le T$, be the corresponding nested functionals defined in~\eqref{stopp-2}. Then for $(Z_0,\dots,Z_T)\in {\cal Z}_{0,T}$ the following holds: \begin{enumerate}[nolistsep, noitemsep] \item [{\rm (i)}] for $m=0,\dots,T$, and $\tau^*_m$ defined in~\eqref{optsol}, \begin{align* E_m&\succeq \rho_{m,T}(Z_\tau),\;\forall \tau\in{\mathfrak T}_m,\\ E_m&= \rho_{m,T}(Z_{\tau^*_m}) \end{align*} \item [{\rm (ii)}] the stopping time $\tau^*_m$ is optimal for the problem~\eqref{optvalue}, \item [{\rm (iii)}] \label{enu:ii} if $\hat{\tau}_m$ is an optimal stopping time for the problem~\eqref{optvalue}, then $\hat{\tau}_m\succeq \tau^*_m$, \item [{\rm (iv)}] ${\mathfrak v}_m=\varrho_{0,m}(E_m)$, $m=1,\dots,T$, and ${\mathfrak v}_0=E_0$. \end{enumerate} \end{theorem} \begin{proof} We use induction in $m$ going backwards in time. Recall that $E_T=Z_T$ and hence the assertions follow for $m=T$. Now let $m=T-1$ and $\tau\in {\mathfrak T}_{T-1}$. Since $ \rho_{T-1,T} =\varrho_{T-1|{\cal F}_{T-1}}$, by using the translation equivariance and property~\eqref{local}, we can write \begin{align* \rho_{T-1,T}(Z_\tau) &= \varrho_{T-1|{\cal F}_{T-1}}\left(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-1\}}Z_{T-1}+\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}Z_{T}\right)\\ &=\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-1\}}Z_{T-1}+\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}} \varrho_{T-1|{\cal F}_{T-1}}(Z_{T}). \end{align*} We have that $\Omega$ is the union of the disjoint sets $\Omega^\tau_{T-1}$ and $ \Omega^\tau_T$ (defined in~\eqref{setomega}), and hence (recall that $E_T=Z_T$) \begin{equation} \label{eqder-2} \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-1\}}Z_{T-1}+\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}\varrho_{T-1|{\cal F}_{T-1}}(Z_{T}) \preceq \max\{Z_{T-1}, \varrho_{T-1|{\cal F}_{T-1}}(E_T)\}= E_{T-1}. \end{equation} It follows that $\rho_{T-1,T}(Z_\tau) \preceq E_{T-1}.$ Conditional on the event $\{Z_{T-1} \ge \varrho_{T-1|{\cal F}_{T-1}}(E_T)\}$ we have: $E_{T-1} =Z_{T-1} $ and $\tau^*_{T-1} =T-1$, and \[ \rho_{T-1,T}(Z_{\tau^*_{T-1}})=\varrho_{T-1|{\cal F}_{T-1}}(Z_{T-1})=Z_{T-1}=E_{T-1}, \] and $\tau^*_{T-1}$ is optimal for the corresponding problem~\eqref{optvalue}. Otherwise conditional on the event $\{Z_{T-1} < \varrho_{T-1|{\cal F}_{T-1}}(Z_T)\}$, we have that $E_{T-1}=\varrho_{T-1|{\cal F}_{T-1}}(Z_T)$, and $\tau^*_{T-1}=T$ is optimal for the corresponding problem~\eqref{optvalue}. In both cases the assertion (iii) also holds. Now let $m=T-2$ and $\tau\in {\mathfrak T}_{T-2}$. We have that $\rho_{T-2,T}(\cdot)=\varrho_{T-2|{\cal F}_{T-2}}\big(\varrho_{T-1|{\cal F}_{T-1}}(\cdot)\big)$ and \begin{align}\nonumber \rho_{T-2,T}(Z_\tau)&= \varrho_{T-2|{\cal F}_{T-2}}\left(\varrho_{T-1|{\cal F}_{T-1}}(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-2\}}Z_{T-2}+ \mathds 1} % \usepackage[sans]{dsfont_{\{\tau\ge T-1\}}Z_{\tau})\right)\\ \nonumber &= \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-2\}}Z_{T-2}+\varrho_{T-2|{\cal F}_{T-2}}(\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-1\}}Z_{T-1}+ \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}\varrho_{T-1|{\cal F}_{T-1}}(Z_{T}))\\ \nonumber &= \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-2\}}Z_{T-2}+\mathds 1} % \usepackage[sans]{dsfont_{\{\tau>T-2\}}\varrho_{T-2|{\cal F}_{T-2}} (\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-1\}}Z_{T-1}+ \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}\varrho_{T-1|{\cal F}_{T-1}}(Z_{T})), \end{align} where the last equation holds since $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau>T-2\}}\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-1\}}=\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-1\}}$ and $\mathds 1} % \usepackage[sans]{dsfont_{\{\tau>T-2\}}\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}=\mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T\}}$ and by~\eqref{local}. Then by~\eqref{eqder-2} and monotonicity of $\varrho_{T-2|{\cal F}_{T-2}}$ we obtain \begin{align*} \rho_{T-2,T}(Z_\tau)& \preceq \mathds 1} % \usepackage[sans]{dsfont_{\{\tau=T-2\}}Z_{T-2}+\mathds 1} % \usepackage[sans]{dsfont_{\{\tau>T-2\}} \varrho_{T-2|{\cal F}_{T-2}}(E_{T-1})\\ & \preceq \max\{Z_{T-2}, \varrho_{T-2|{\cal F}_{T-2}}(E_{T-1})\} = E_{T-2}. \end{align*} Conditional on $\{Z_{T-2} \ge \varrho_{T-2|{\cal F}_{T-2}}(E_{T-1})\}$, we have that $E_{T-2} =Z_{T-2} $ and $\tau^*_{T-2} =T-2$, and \[ \rho_{T-2,T}(Z_{\tau^*_{T-2}})=\varrho_{T-2|{\cal F}_{T-2}} (\varrho_{T-1|{\cal F}_{T-1}}(Z_{T-2}))=Z_{T-2}=E_{T-2}, \] and $\tau^*_{T-2}$ is optimal for the corresponding problem~\eqref{optvalue}. Otherwise conditional on the event $\{Z_{T-2} < \varrho_{T-2|{\cal F}_{T-2}}(E_{T-1})\}$, we have $E_{T-2} =\varrho_{T-2|{\cal F}_{T-2}}(E_{T-1})$ and $\tau^*_{T-2}\ge T-1$. Conditioning further on $\{Z_{T-1} < \varrho_{T-1|{\cal F}_{T-1}}(E_T)\}$ we have that $E_{T-1}=\varrho_{T-1|{\cal F}_{T-1}}(Z_T)$, and $\tau^*_{T-2}=T$ is optimal for the corresponding problem~\eqref{optvalue}. Otherwise conditional further on $\{Z_{T-1} \ge \varrho_{T-1|{\cal F}_{T-1}}(E_T)\}$ we have that $\tau^*_{T-2}=T-1$ and the assertions are verified. The assertion follows by going backwards in time for $m=T-3,\dots$. \end{proof} Note that it follows by~\eqref{eq:SnellZ} that $Z_t(\omega)\le E_t(\omega)$ for all $t=0,\dots,T$ and a.e. $\omega\in \Omega$. We have that \begin{equation}\label{optstop} \tau^*_0(\omega)=\min\{t\colon Z_t(\omega)\ge E_t(\omega), \;t=0,\dots,T\} \end{equation} is an optimal solution of problem~\eqref{minopt}, and the optimal value of problem~\eqref{minopt} is equal to $E_0$. That is, going forward the optimal stopping time $\tau^*_0$ stops at the first time $Z_t=E_t$. In particular it stops at $t=0$ if $Z_0\ge E_0$ (recall that $Z_0$ and $E_0$ are deterministic), i.e., iff $Z_0\ge \varrho_{0|{\cal F}_0}(E_1)$; and it stops at $t=T$ iff $Z_t< E_t$ for $t=0,\dots,T-1$. As in the risk neutral case the time consistency (Bellman's principle) is ensured here by the decomposable structure of the considered nested risk measure. That is, if it was not optimal to stop within the time set $\{0,\dots,m-1\}$, then starting the observation at time $t=m$ and being based on the information ${\cal F}_m$ (i.e., conditional on ${\cal F}_m$), the same stopping rule is still optimal for the problem~\eqref{optvalue}. Consider (compare with~\eqref{onestep-1}) \begin{equation}\label{onestep-rec} \mathcal{R}_{s,s+1}(Z_s,Z_{s+1}):= Z_s\vee\varrho_{s|{\cal F}_s}(Z_{s+1}), \quad s=0,\dots,T-1. \end{equation} Then we can write $E_t$ in the following recursive form (compare with~\eqref{decom-1}) \begin{equation*}\label{sne-3} E_t=\mathcal{R}_{t,t+1}\Big(Z_t, \mathcal{R}_{t+1,t+2}\big(Z_{t+1},\cdots, \mathcal{R}_{T-1,T}(Z_{T-1}, Z_T)\big)\Big),\quad t=0,\dots T-1. \end{equation*} Consequently (recall that ${\mathfrak v}_0=E_0$) problem~\eqref{stp-max} can be written in the form~\eqref{refm-2} with $\mathcal{R}:=\mathcal{R}_{0,T}$, where $\mathcal{R}_{0,T}$ is given in the nested form discussed in Section \ref{sec:decomp}, $\mathcal{R}_{s,s+1}$ defined in~\eqref{onestep-rec}, and with the respective dynamic programming equations of the form~\eqref{dyn-stop1}. For an optimal policy $\bar{\pi}=\{\bar{x}_0,\bar{\mbox{\boldmath$x$}}_1,\dots,\bar{\mbox{\boldmath$x$}}_{T}\} $, the Snell envelop of the corresponding stopping time problem is $E_t(\omega)= V_t(\bar{\mbox{\boldmath$x$}}_{t-1},\omega)$, $t=1,\dots,T$, where $V_t(\cdot,\omega)$ is the value function defined by the dynamic equations~\eqref{dyn-stop1}. \begin{remark} \label{rem-conv} As it was already mentioned in Remark \ref{rem-max}, there is a delicate issue of preserving convexity of the considered optimization problems. Suppose that the functionals $\varrho_{t|{\cal F}_t}$ are convex. Together with the assumed monotonicity of $\varrho_{t|{\cal F}_t}$ and since maximum of two convex functions is convex, convexity of the respective value functions $V_t(\cdot,\omega)$ is implied by convexity of the objective functions $f_t(\cdot,\omega)$ if, for example, the feasibility constraints are linear of the form \begin{equation}\label{lincon} {\cal X}_t(x_{t-1},\omega):=\{x_t\ge 0\colon B_t(\omega)x_{t-1}+A_t(\omega)x_t=b_t(\omega)\}. \end{equation} On the other hand if $\varrho_{t|{\cal F}_t}$ are concave, then convexity of $V_t(\cdot,\omega)$ is not guaranteed. \end{remark} \subsubsection{The min-min problem} \label{sec-min-min} Consider the min-min (minimization with respect to $\pi\in \Pi$ and $\tau\in {\mathfrak T}$) variant of problem~\eqref{stp-max}. In that case for a fixed policy $\pi\in \Pi$ we need to solve the optimal stopping time problem \begin{equation}\label{minopt-2} \min_{\tau\in {\mathfrak T}} \rho_{0,T}(Z_\tau). \end{equation} Here the one step mappings $\mathcal{R}_{s,s+1}$, used in construction of the corresponding preference system (discussed in Section \ref{sec:decomp}), take the form \begin{equation}\label{minr} \mathcal{R}_{s,s+1}(Z_s,Z_{s+1}):= Z_s\wedge \varrho_{s|{\cal F}_s}(Z_{s+1}),\; s=0,\dots T-1. \end{equation} In contrast to~\eqref{onestep-rec} considered above, the mappings $\mathcal{R}_{s,s+1}$ defined in~\eqref{minr} do not preserve convexity of $\varrho_{s|{\cal F}_s}$. The corresponding dynamic programming equations~\eqref{dynmar-2}--\eqref{dynmar-3} (and \eqref{suff0}--\eqref{suffT}) apply here as well and are somewhat simpler as the essential infimum and the minimum can be interchanged. \subsubsection{Supermartingales and delayed stopping} Recall that a sequence of random variables $\{X_t\}_{0\le t\le T}$ is said to be \emph{supermartingale} relative to the filtration ${\mathfrak F}$, if $X_t\succeq {\Bbb{E}}_{|{\cal F}_t}(X_{t+1})$, $t=0,\dots,T-1$. By analogy we say that the sequence $X_t\in {\cal Z}_t$ is ${\mathfrak P}$-supermartingale, with respect to the collection of mappings ${\mathfrak P}=\{ \varrho_{t|{\cal F}_t}\}_{t=0,\dots,T-1}$, if \begin{equation}\label{mart-1} X_t\succeq \varrho_{t|{\cal F}_t}(X_{t+1}),\;t=0,\dots,T-1. \end{equation} It follows by the definition~\eqref{eq:SnellZ} that the Snell envelope sequence $\{E_t\}_{0\le t\le T}$ is ${\mathfrak P}$-super\-martingale. It also follows from \eqref{eq:SnellZ} that $E_t\succeq Z_t$, i.e., $E_t$ dominates $Z_t$. We have that $\{E_t\}_{0\le t\le T}$ is the smallest ${\mathfrak P}$-supermartingale which dominates the corresponding sequence $\{Z_t\}_{0\le t\le T}$. \begin{remark} \label{rem-order} Consider two collections $\varrho_{t|{\cal F}_t}\colon{\cal Z}_{t+1}\to{\cal Z}_{t}$ and $\varrho'_{t|{\cal F}_t}\colon{\cal Z}_{t+1}\to{\cal Z}_{t}$, $t=0,\dots,T-1$, of monotone translation equivariant mappings possessing property~\eqref{local}, with the respective Snell envelope sequences $E_t$ and $E'_t$ and stopping times $\tau'_0=\inf\{t\colon E'_t=Z_t\}$ and $\tau^*_0=\inf\{t\colon E_t=Z_t\}$, defined for $(Z_0,\dots,Z_T)\in {\cal Z}_{0,T}$. Suppose that $\varrho_{t|{\cal F}_t}(\cdot)\preceq \varrho'_{t|{\cal F}_t}(\cdot)$, $t=0,\dots,T-1$. It follows then that $ E_t\preceq E^\prime_t$ for $t=0,\dots,T$, and hence $\tau^*_0\le\tau^\prime_0$. That is, for larger risk mappings the optimal (maximization) stopping time, defined in~\eqref{optsol}, is delayed. For convex law invariant risk functionals it holds that ${\Bbb{E}} [X]\le \rho(X)$ (e.g., \citet[Corollary~6.52]{RuszczynskiShapiro2009-2}). In that case it follows together with~\eqref{mart-1} that every ${\mathfrak P}$-supermartingale $X_t$, $t=0,\dots,T-1$, is also a martingale in the usual sense, i.e., with respect to the expectation. For the concave counterpart $\nu(X)=-\rho(-X)$ the converse inequality $\nu(X)\le {\Bbb{E}} [X]$ follows of course. \end{remark} \section{Numerical illustration}\label{sec:numeric} This section discusses computational approaches to solving stopping time problems with preference systems of the general form~\eqref{stp-max}. We illustrate two different approaches based on the pricing of American put options. This stopping time problem is well-known in mathematical finance. We start by solving the dynamical equations explicitly in the following section and then elaborate on Stochastic Dual Dynamic Programming (SDDP) type algorithm in Section~\ref{sec:SDDP}. We give numerical examples for optimal stopping in univariate, as well as for multivariate problems (basket options). Further, the examples cover both, the convex and the concave nested (stopping) preference systems. \subsection{Optimal stopping by solving the dynamic equations}\label{sec:pric} Like a simple stock, the option is an investment which comes with risk. The risk averse investor is not willing to pay the fair price for risk-prone investments, instead, the potential buyer expects a discount corresponding to his general decline of risk. As the American put option with strike price $K>0$ can be exercised any time the investor considers the optimal stopping problem \begin{equation}\label{pr-1} \sup_{\tau \in {\mathfrak T}}\rho_{0,T}\big(e^{-r\,\tau}\cdot[K-S_\tau]_+ \big), \end{equation} where $r>0$ is a fixed discount rate and $S_t$ is the price of the underlying at time $t$. The risk neutral investor chooses the expectation, $\rho_{0,T}=\mathbb E$, in~\eqref{pr-1}, this problem is the well-known optimal stopping problem in mathematical finance. The risk averse investor, in contrast, chooses a preference measure $\rho_{0,T}$ reflecting his personal risk profile. Note that the situation reverses for the \emph{owner} of a risky asset. This market participant is willing to accept a fee (a commission, like a premium in insurance) to get rid of his risky asset, i.e., to sell the risk. As well, he will choose a preference functional when computing his personal price of the option, but his personal preference functional reveals opposite preferences than the buyer's functional. Following the Black-Scholes scheme we consider the geometric random walk process \begin{equation}\label{pr-2} S_t=S_{t-1}\cdot\exp\big(r-\sigma^2/2+\varepsilon_t\big), \;t=1,\dots,T, \end{equation} in discrete time with $\varepsilon_t$ being an i.i.d.\ Gaussian white noise process, $\varepsilon_t\sim\mathcal N(0,\sigma^2)$. By considering $S_t$ as the state variable the corresponding dynamic equations can be written recursively as \begin{equation}\label{pr-3} {\cal V}_T(S_T):=[K-S_T]_+ \end{equation} and \begin{equation}\label{pr-4} {\cal V}_t(S_t)= [K-S_t]_+\vee e^{-r}\cdot\varrho_{t|S_t}\big({\cal V}_{t+1}(S_{t+1})\big), \end{equation} for $t=T-1,\dots,1$, where $\varrho$ is a chosen law invariant coherent risk measure. In particular we can use the Entropic Value-at-Risk, $\varrho:= {\sf EV@R}^\beta$, where for $\beta>0$, \begin{equation}\label{pr-6} {\sf EV@R}^\beta(Z):=\inf_{u>0}\left\{u^{-1}\left(\beta+\log {\Bbb{E}}[e^{uZ}]\right)\right\}. \end{equation} Note that this is a \emph{convex} law invariant coherent risk measure, it is the homogeneous version of the risk measure studied in \citet{Schachermayer2009a}. We refer to \cite{AhmadiPichler} for details on this particular risk measure, which allows explicit evaluations for Gaussian random variables. \begin{figure} \subfloat[Regions for the risk averse option holder] {\includegraphics[width=0.5\textwidth]{convex.pdf} \label{fig:11}} \hfill \subfloat[Regions for the risk averse option buyer] {\includegraphics[width=0.5\textwidth]{concave.pdf} \label{fig:12}} \caption{\label{fig:1}Stopping and continuation regions for risk averse option traders} \label{fig:Prices} \end{figure} Figure~\ref{fig:1} displays the decision rules for $\varrho=\EVaR^\beta$ and varying levels $\beta$ of risk aversion. The option is not exercised, as long as the price of the stock stays in the continuation region. Once the price of the stock drops out of the continuation region into the stopping region, then it is optimal to exercise the put option. The optimal stopping time thus is \[\tau=\inf\big\{i\in\{0,\dots,n\}\colon (t_i,S_{t_i})\not\in \text{ continuation region}\big\}.\] In view of~\eqref{pr-4} the stopping rule can be restated as \begin{equation}\label{eq:7} S_t + {\cal V}_t(S_t)\le K, \end{equation} where $S_t$ is the current price of the stock and ${\cal V}_t(S_t)$ the actual and updated price of the corresponding put option. The rule~\eqref{eq:7} is known as \emph{fugit} in mathematical finance. It holds as well that $-\varrho(-Y)\le \varrho(Y)$\footnote{Indeed, $0=\varrho(0)\le\varrho(Y)+\varrho(-Y)$.} and Figure~\ref{fig:12} displays the continuation and stopping region for the respective concave functional $\nu(Y):=-\EVaR^\beta(-Y)$, the solution of the problem \[\sup_{\tau\in{\mathfrak T}} \nu_{0,T}\big(e^{-r\,\tau}\cdot[K-S_\tau]_+\big);\] this plot describes the trading regions for the risk averse option buyer. In the risk neutral case, $\beta=0$, the regions are notably identical as the expectation is linear and thus $\mathbb E [Y]=-\mathbb E[-Y]$. \subsection{Stochastic Dual Dynamic Programming}\label{sec:SDDP} The SDDP algorithm was introduced in \cite{per1991} and extended to a risk averse setting in \cite{shap2011a}. For a discussion of the SDDP method we can refer to \citet[Section~5.10] {RuszczynskiShapiro2009-2} and references therein. \subsubsection{Univariate SDDP} To study the performance of the SDDP approach to solving optimal stopping problems, we remove nonlinear influences and consider the arithmetic version of the reference problem~\eqref{pr-1}, which is \[ \sup_{\tau \in {\mathfrak T}}\rho_{0,T}\big([K-S_\tau]_+ -r\tau\big) \] (\cite{SchachermayerBachelier} discuss the differences of these models). We use risk measure $\varrho := (1 - \lambda) \mathbb{E} + \lambda \avr_\alpha$ for some $\lambda\in [0, 1]$ and $\alpha\in (0, 1)$ and consider $T = 25$ stages. The SDDP algorithm first discretizes the random variables $\varepsilon_t$. If $\varepsilon_t$ takes the values $\pm \sigma\,S_0$ with probability~$\nicefrac12$ each, then the dynamic programming equations reduce to the binomial option pricing model. Nevertheless, the SDDP algorithm can handle the general situation where $\varepsilon_t$ follows an arbitrary distribution, as long as it is possible to obtain samples from such distribution. In the following experiments we let $\varepsilon_t\sim {\cal N}(0, \sigma^2S_0^2)$. In order to solve the problem numerically we discretize the (continuous) distribution by randomly generating $N$ realizations at every stage. We refer to the obtained approximation as the \emph{discretized problem}. The following numerical experiments use $N=100$ discretized points for each time period. We assess the quality of the SDDP algorithm on two aspects, namely the statistical properties of the approximations of dynamic programming equations formed under discretization, and the efficiency of the algorithm in solving the discretized problem. Since the problem is univariate (i.e., a single stock price $S_t$), it is possible to solve the discretized problem quite accurately simply by discretization of the state variables. So the main purpose of the following exercise is to verify efficiency of the SDDP algorithm. After that we investigate a multivariate setting where simple discretization of state variables is not possible. We first run the algorithm, applied to the discretized problem, for 1000 iterations and record the lower bounds generated in each iteration. The upper bound of the optimal value is constructed by piecewise linear approximations of the value functions $V_t(\cdot)$ (this could be inefficient in the multivariate setting). Note that the SDDP algorithm, applied to the discretized problem, also generates a policy for the original problem with continuous distributions of $\varepsilon_t$. Its value for the original problem can be estimated by generating random sample paths (scenarios) from the original distributions and averaging the obtained values. We sample 2000 scenarios from the distributions of $\varepsilon_t$ (either the original or the discretized one) and plot the distributions of the corresponding stopping time and the interest discounted profit. To assess how well the discretization approximates the true dynamic programming equations, we run the SDDP algorithm 30 times and compare the distributions of stopping time and interest discounted profit. \paragraph{Formulation 1: $\lambda = 0$ (the risk neutral case).} Figure \ref{fig1} exhibits a typical convergence of lower bounds generated by the SDDP algorithm. In particular, the gap between the upper and the lower bounds is already small after, say, 500 iterations. The algorithm solves the discretized problem quite well. Moreover values of the constructed policies for the discretized and original problems are very similar. \begin{figure}[H] \centering \includegraphics[scale=0.50]{rn-ublb} \caption{Upper and lower bounds of the optimal objective values (of formulation 1) generated by the SDDP algorithm in 1000 iterations.} \label{fig1} \end{figure} We run 30 trials of the SDDP algorithm for randomly generated discretizations of the original continuous distributions of $\varepsilon_t$. We sample 2000 scenarios from both the true and the discretized distributions of $\varepsilon_t$ and plot the distributions of the corresponding stopping time and the interest discounted profit. We refer to the discretized distribution as the empirical distribution. Figures~\ref{fig2} and~\ref{fig3} contain plots for typical distributions of interest discounted profits and stopping times generated by the discretized problems in 30 trials, respectively. In particular, the subplot on the left of each plot corresponds to the scenarios sampled from the discretized distribution of $\varepsilon_t$, whereas the subplot on the right corresponds to the original normal distribution. Although figure \ref{fig3} indicates that the distributions of the stopping times generated in different trials could be different, the distribution of the profits share a common shape as shown in Figure \ref{fig2}. This indicates that the optimal objective value of \eqref{pr-1} generated by the discretization is reasonably accurate when $N = 100$, while optimal stopping times are unstable. \begin{figure}[H] \centering \includegraphics[scale=0.55]{rn-p1} \includegraphics[scale=0.55]{rn-p2} \caption{Typical distributions of interest discounted profit (of formulation 1) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig2} \end{figure} \begin{figure}[H] \centering \includegraphics[scale=0.55]{rn-s1} \includegraphics[scale=0.55]{rn-s2} \caption{Typical distributions of stopping time (of formulation 1) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig3} \end{figure} \paragraph{Formulation~2: $\lambda = 0.2$ and $\alpha = 0.05$.} We present similar analysis as in the risk neutral case. Figure~\ref{fig5} shows the gap between the upper and the lower bounds which is already small after 500 iterations. Moreover, all distributions of stopping times and profits have the same shape (see Figure~\ref{fig6}). As predicted in Remark~\ref{rem-max}, such formulation hopes that the uncertainty of the probability distribution works in our favor potentially giving a larger value of the return, thereby delays the stopping time to late stages. \begin{figure}[H] \centering \includegraphics[scale=0.50]{rd-ublb} \caption{Upper and lower bounds of the optimal objective values (of formulation 2) generated by the SDDP algorithm in 1000 iterations.} \label{fig5} \end{figure} \begin{figure}[H] \centering \includegraphics[scale=0.55]{rd-s1} \includegraphics[scale=0.55]{rd-p1} \caption{Typical distributions of stopping time and interest discounted profit (of formulation 2) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig6} \end{figure} \subsubsection{Basket options} We also analyze the SDDP algorithm applied to the (multivariate) American basket option pricing problem \begin{equation} \label{bop} \begin{array}{ll} \sup\limits_{\tau \in {\mathfrak T}}\rho_{0,T}\left(\left[\sum_{j\in J} w_j S^j_\tau - K\right]_+ -r\tau\right). \end{array} \end{equation} Here $J$ is an index set of assets with $|J|=5$, and $T = 25$. Also $\varrho = (1 - \lambda) \mathbb{E} + \lambda \avr_\alpha$ for some $\lambda\in [0, 1]$ and $\alpha\in (0, 1)$, $w_j\in \mathbb{R}$ are weights, $K$ is the strike price, $S^j_t$ is the price of asset $j$ at time $t$. In particular, suppose $\mu^j = rS^j_0$ and iid $\epsilon_t\sim N(\mathbf{0}, \Sigma)$ for some covariance matrix $\Sigma$ of order $|J|\times |J|$, then $S^j_t$ is a random walk process for each $j\in J$ such that \begin{equation} \label{udr} S^j_t = \mu^j + S^j_{t-1} + (\epsilon_t)_j, \;t = 1, \ldots, T. \end{equation} The SDDP algorithm for \eqref{bop} proceeds the same way as the one for \eqref{pr-1}, and our analysis of the algorithm is the same as before, i.e., we assess how well the discretization approximates the true dynamic programming equations and how efficient the algorithm in solving the original problem. As mentioned before, the construction of a deterministic upper bound could be inefficient in the multivariate setting, hence we simply let the algorithm run 1000 iterations. \paragraph{Formulation 3: basket option with $\lambda = 0$ (the risk neutral case).} Figure~\ref{fig8} shows that the lower bounds generated by the SDDP algorithm stabilize after about 500 iterations. It appears that the SDDP algorithm solves the discretized problem quite accurately, and we evaluate its performance for the original problem by generating scenarios from the original distribution. As shown in Figures~\ref{fig9} and~\ref{fig10}, the distributions of policies, namely interest discounted profits and stopping times, vary across trials. To further understand the relation between the quality of the discretization and the number of discretized points, we run 30 additional trials with $N = 300$ for each time period, and the results are summarized in Figures~\ref{fig11} and~\ref{fig12}. In short, the distributions of profits now look similar, though the distributions of stopping times still have a moderate variation. \begin{figure}[H] \centering \includegraphics[scale=0.50]{mrn-lb} \caption{Lower bounds of the optimal objective values (of formulation 3) generated by the SDDP algorithm in 1000 iterations.} \label{fig8} \end{figure} \begin{figure}[H] \centering \includegraphics[scale=0.55]{mrn-p1} \includegraphics[scale=0.55]{mrn-p2} \caption{Typical distributions of interest discounted profit (of formulation 3 with $N = 100$) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig9} \end{figure} \begin{figure}[H] \centering \includegraphics[scale=0.55]{mrn-s1} \includegraphics[scale=0.55]{mrn-s2} \caption{Typical distributions of stopping time (of formulation 3 with $N = 100$) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig10} \end{figure} \begin{figure}[H] \centering \includegraphics[scale=0.55]{mrn-p3} \includegraphics[scale=0.55]{mrn-p4} \caption{Typical distributions of interest discounted profit (of formulation 3 with $N = 300$) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig11} \end{figure} \begin{figure}[H] \centering \includegraphics[scale=0.55]{mrn-s3} \includegraphics[scale=0.55]{mrn-s4} \caption{Typical distributions of stopping time (of formulation 3 with $N = 300$) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig12} \end{figure} \paragraph{Formulation 4: basket option with $\lambda = 0.2$ and $\alpha = 0.05$.} Like the other formulations, the lower bounds generated by the SDDP algorithm in this case stabilize after about 500 iterations, hence we omit the plot. Similar to formulation 2, all distributions of stopping times and profits have the same shape (see Figure~\ref{fig13}), and the stopping time concentrates on late stages. This indicates that the discretization gives is a good approximation of the original problem even when $N = 100$ for each time period. \begin{figure}[H] \centering \includegraphics[scale=0.55]{mrd-s1} \includegraphics[scale=0.55]{mrd-p1} \caption{Typical distributions of stopping time and interest discounted profit (of formulation 4) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig13} \end{figure} We next consider the American basket option pricing problem \eqref{bop} with concave risk measure, with $T = 25$ and $\varrho(Z) = (1 - \lambda) \mathbb{E}(Z) - \lambda \avr_\alpha(-Z)$ for some $\lambda\in [0, 1]$ and $\alpha\in (0, 1)$. This is a risk averse formulation since the concave risk measure shifts more weights to scenarios that reduce the profits. As mentioned in Remark~\ref{rem-max}, the convexity is not preserved when a concave risk measure is used. Without convexity, the SDDP algorithm cannot be applied directly. We circumvent this by approximating the risk averse formulation by solving a sequence of risk neutral problems. The basic idea is to treat every stage of the risk averse formulation as a saddle point problem like \eqref{rem-stab}. Starting with the discretized distribution that assigns equal probability to each scenario at every stage, we iteratively solve the risk neutral problem and construct a new discretized distribution by shifting more weights to the ``bad" scenarios for the current risk neutral problem. Specifically, in each iteration, we first let the SDDP algorithm solve the discretized risk neutral problem. Then we sample scenarios from the discretized distribution; each scenario corresponds to a sequence of stock prices $\{S_0^j\}_{j\in J}, \{S_1^j\}_{j\in J}, \ldots, \{S_T^j\}_{j\in J}$ according to the equation \eqref{udr}. For each $t = 1, \ldots, T$, we consider $V_t(\{S^j_{t - 1}\}_{j\in J}, \hat{\epsilon}_t)$ constructed by the discretized problem, where $\hat{\epsilon}_t$ are the possible realizations of $\epsilon_t$ in the discretized distribution. Consequently we arrange these values in the ascending order. For each $\hat{\epsilon}_t$, we then count the frequency (i.e., the number of scenarios) that $\underline{V}_t(S_{t - 1}, \hat{\epsilon}_t)$ has one of the $\lceil \alpha N \rceil$-lowest values. The new distribution is constructed based on the frequency such that the realization $\hat{\epsilon}_t$ is assigned the probability \begin{itemize} \item $\frac{1 - \lambda}{N} + \frac{\lambda}{\alpha N}$, if its frequency is among the top $\lfloor \alpha N \rfloor$ frequencies for stage $t$. \item $\frac{1 - \lambda}{N} + \frac{\lambda (\alpha N - \lfloor\alpha N\rfloor)}{\alpha N}$, if its frequency is the $(\lfloor \alpha N \rfloor + 1)$-highest frequency for stage $t$. \item $\frac{1 - \lambda}{N}$, otherwise. \end{itemize} Note that those probability weights are exactly the ones assigned by $\varrho$ to different outcomes of the random variable $Z$ when $Z$ has only finitely many outcomes. The sequence of risk neutral problems is not guaranteed to converge to the original problem in general. Nonetheless, this approach works well on the basket option pricing problem we tested. First of all, the sequence of constructed distributions converges. Besides, the policies generated by the discretization, obtained in the last iteration, exhibit risk aversion. Indeed, compared to Figures~\ref{fig10} and~\ref{fig12}, the stopping time shown in Figure~\ref{fig14} has more weights in the early stages, and the distribution of the interest discounted profit (see Figure~\ref{fig14}) has a shorter range, because the higher potential returns are turned down in exchange for less risk. \begin{figure}[H] \centering \includegraphics[scale=0.55]{mra-s1} \includegraphics[scale=0.55]{mra-p1} \caption{Typical distributions of stopping time and interest discounted profit (of formulation 4) where the scenarios are sampled from both the empirical and the original normal distribution.} \label{fig14} \end{figure} \bibliographystyle{abbrvnat}
\section*{Introduction} Quantum sensing relies on the manipulation of internal or external degrees of freedom in atoms, molecules, opto-mechanical devices, photonic or solid-state systems, and covers various applications such as magnetometry \cite{Sheng2013,Gross2017,Jimenez-Martinez2018}, the definition of frequency standards \cite{Takamoto2005,LeTargat2013}, short-range force measurements \cite{Tarallo2014} or electromagnetic measurements \cite{Bagci2014,Facon2016}. Inertial sensors based on the coherent manipulation of superpositions of momentum states in atom interferometers have been developed for more than 25 years \cite{Borde1989,KasevichChu1991,Riehle1991}, with the goal to address various applications. Examples of remarkable achievements are tests of fundamental physics \cite{Bouchendira2011,Lepoutre2012,Zhou2015,Jaffe2017,Asenbaum2017}, metrology \cite{Rosi2014}, or absolute gravimetry \cite{Peters2001,Freier2016,Bidel2018,Karcher2018}. Such precision measurements of gravito-inertial effects directly take benefit from the inherent accuracy and long-term stability of cold-atom sensors. These two properties can eventually be combined with the high-bandwidth of relative sensors, which is at the basis of sensor fusion \cite{Lautier2014}. This approach is reminiscent of atomic clocks, where probing the stable atomic energy structure is used for stabilizing a microwave or optical oscillator \cite{Takamoto2005,LeTargat2013}, or for tests of fundamental physics. The extension of the applications of cold-atom inertial sensors to the measurement of time-varying signals has been confronted to their reduced sampling rate, which originates from their sequential operation and from the long interrogation time of the atoms that is required to achieve high inertial sensitivity. This limitation is, for example, an obstacle for applications to inertial navigation \cite{Jekeli2005} or to fundamental research related to dark matter detection \cite{Graham2016} or gravitational wave astronomy \cite{Chaibi2016,Graham2016a}. In this work, we report on the interleaved operation of a cold-atom inertial sensor, which operates with a sampling frequency of $3.75$~Hz and features a high inertial sensitivity, as given by the 801~ms interrogation time of the atoms in the interferometer. The method of interleaving, which we demonstrate for both static and dynamic rotation rate measurements, can be generalized to other atom interferometer architectures, and therefore paves the way to the development of high-bandwidth and high-sensitivity cold-atom inertial sensors. Besides an increase in sensor bandwidth, we show that interleaving allows to efficiently average vibration noise (as $1/\tau$, with $\tau$ the integration time), which represents the most important noise source in cold-atom inertial sensors. As a consequence, we demonstrate a record rotation rate sensitivity of $3\times 10^{-8}$~rad.s$^{-1}$.Hz$^{-1/2}$. Such a high sensitivity level allows us to characterize the systematic effects of a cold-atom gyroscope in a so-far unexplored range \cite{Gauguet2009,Berg2015}, and to stabilize them at the few $10^{-10}$~rad.s$^{-1}$ level. Previous works on atomic beam gyroscopes already demonstrated excellent sensitivities \cite{Gustavson2000} and long term stabilities close to the state-of-the-art of optical gyroscopes \cite{Durfee2006}. As the long-term instability of gyroscopes is a limiting factor in inertial navigation systems, achieving the performance of the best fiber-optics gyroscopes \cite{Lefevre2014} was a long-standing goal, which we attain for the first time with a cold-atom sensor. \section*{Results} \subsection*{Experimental setup} \begin{figure}[!h] \includegraphics[width=\linewidth]{Fig1.pdf} \caption{\label{fig:detailSequence3IJ} \textbf{Principle of the experiment}. \textbf{A}: sketch of the experiment, where the atoms are laser cooled (blue cloud) and launched vertically, interrogated by two Raman beams (brought from the gray collimators and retro-reflected on the blue mirrors), and detected on their way down (green box). The distance between the Raman beams is $L=\frac{3}{8}gT^2\simeq 59$~cm. \textbf{B}: diagram of the atom interferometer in the $(xz)$ plane (not to scale), with the blue and red lines respectively labeling the $|\vec{0}\rangle$ and $\hbar\vec{k}_\mathrm{eff}$ momentum states. The dashed and plain lines show the two paths of the matter-waves in the interferometer, which enclose an area of 11~cm$^2$. \textbf{C}: trajectories of the successively launched atom clouds in interleaved operation. Each interferometer has an interrogation time $2T=801$~ms and the cycle time is $T_c = 2T/3=267$~ms. The $\pi/2$ pulses are shared between the atom clouds entering and exiting the interferometer. } \end{figure} \textit{Experimental sequence and principle of the gyroscope.} The core of the experimental setup used in this work has been described in \cite{Dutta2016}, and is sketched in Fig.~\ref{fig:detailSequence3IJ}. The essential techniques are given in the Materials and Methods section, with further details in the \SM. In short, we laser-cool Cesium atoms to a temperature of $1.2 \ \mu$K and launch them vertically at a velocity of $5.0$~m.s$^{-1}$. After a selection step of the $m_F=0$ magnetic sublevel, we interrogate the atoms in the interferometer, and finally detect their state at the output of the interferometer, on their way down, using fluorescence detection. We realize the light-pulse atom interferometer using two-photon stimulated Raman transitions with counter-propagating laser beams which couple the $|F=3,m_F=0\rangle$ and $|F=4,m_F=0\rangle$ clock states of the Cesium atom. According to the Sagnac effect, the rotation sensitivity is proportional to the area between the 2 arms of the interferometer. Our gyroscope is based on a fountain configuration with 4 light pulses to create a folded geometry thanks to gravity \cite{Canuel2006}. The symmetric 4 pulse fountain configuration allows to achieve a large area ($11$~cm$^2$ in this work) and leads to a vanishing sensitivity to constant linear accelerations. The interferometer phase shift, $\Phi$, can be calculated from the relative phase between the two Raman lasers, $\Delta\varphi_{\text{laser}}(t)=\vec{k}_{\mathrm{eff}}\cdot \vec{r}_{b,t}(t) + \Delta\varphi(t)$, which is imprinted on the diffracted part of the matter-wave at the time $t$ of the pulse. It reads: \begin{equation} \label{eqn:rotphase4p} \Phi= \vec{k}_{\mathrm{eff}}\cdot \left[ \vec{r}_b \left(0\right) - 2\vec{r}_t \left(\frac{T}{2}\right) + 2\vec{r}_t \left( \frac{3T}{2}\right) - \vec{r}_b \left( 2T\right) \right] + \Delta\Phi^0, \end{equation} where $\vec{k}_{\mathrm{eff}}$ is the two-photon wavevector, $\vec{r}_{b,t}(t)$ is the position of the mirror retro-reflecting the Raman lasers with respect to the center-of-mass of the free falling atoms (subscripts $\{b,t\}$ for bottom and top mirror, see Fig.~\ref{fig:detailSequence3IJ}), and $2T$ is the total interrogation time. The last term $\Delta\Phi^0$ is a controllable laser phase shift independent of inertial effects. The phase shift associated to the stationary Earth rotation rate $\vec{\Omega}_E$ is given by \begin{equation}\ \Phi_\Omega= \frac{1}{2}\vec{k}_{\mathrm{eff}}\cdot \left(\vec{g}\times\vec{\Omega}_E\right) T^3, \label{eq:constant_rot} \end{equation} where $\vec{g}$ is the acceleration of gravity \cite{Stockton2011}. \textit{Interleaved operation.} We employ a sequence of joint interrogation of successive interferometers, which is obtained by using the same $\pi/2$ Raman pulse for the atom clouds entering and exiting the interferometer zone \cite{Dutta2016}. Consequently, the sensor can operate without dead times. The interleaved operation, which is reminiscent from the atom juggling technique of Ref.~\cite{Legere1998}, is then implemented by extending this joint sequence to a multiple-joint sequence, as proposed in \cite{Meunier2014}. The sequence of Raman pulses is given in Fig.~\ref{fig:detailSequence3IJ}. If we denote $2T=801$~ms the total duration of the interferometer, we launch an atom cloud every $T_c=2T/3=267$~ms, which supposes that a cloud is laser-cooled while 3 previously launched clouds are interrogated in the interferometer. Due to timing constraints, the loading time of the magneto-optical trap (MOT) is limited. The atoms are loaded in the MOT during 55~ms, and we detect $2\times$10$^5$ atoms at the end of the interferometer. The light scattered from the MOT atoms causes incoherent photon absorption and emission from the interrogated atoms and therefore a loss of contrast \cite{Meunier2014}. The contrast of the interferometer is 7.4$\%$, limited by the expansion of the cloud during the free fall in the Raman beams of gaussian profile, and by the light scattered from the MOT. \textit{Technical upgrades.} We implemented several key upgrades of our setup compared to Ref.~\cite{Dutta2016}. First, we improved the detection noise which was limiting the sensitivity in \cite{Dutta2016}. The equivalent one-shot phase noise is now 71~mrad, corresponding to a rotation noise of 8 nrad.s$^{-1}$.Hz$^{-1/2}$. Second, we implemented a real-time compensation of linear acceleration noise \cite{Lautier2014}, and a servo-loop to operate the interferometer at mid-fringe, i.e. in its linear range. These techniques are described in the Materials and Methods section. These upgrades result in a sensor which effectively operates without dead times, as statistically very few points sit on the top or bottom of a fringe, where the sensitivity vanishes. \begin{figure}[!h] \includegraphics[width=\linewidth]{Fig2.pdf} \caption{\label{fig:long_acq}\textbf{ Rotation rate measurement during 32.5 hours. } In the blue (orange) trace, each data point is the average over segments of 26.7~s (267~s) of raw inertial phase measurements. The right axis translates inertial phase to rotation rate using the scale factor of the gyroscope to stationary Earth rotation (from Eq.~\eqref{eq:constant_rot}). } \end{figure} \textit{Rotation rate acquisition.} Fig.~\ref{fig:long_acq} shows a 32.5 hours acquisition of rotation rate measurements obtained between September 23rd and 25th, 2017. To obtain this series of data, we alternated the direction of the Raman wavevector ($\pm \vec{k}_\mathrm{eff}$) and computed the half-difference of two successive measurements to reject non-inertial ($\vec{k}_\mathrm{eff}$-independent) effects, such as AC Stark shifts (see Methods and \SM - section S1 for the details of the sequence, and section S2 for the raw data). In the following, we will analyze the sensitivity and the stability of the gyroscope from this acquisition. \subsection*{Efficient averaging of vibration noise and record sensitivity} Vibration noise is the most important source of sensitivity degradation in cold-atom inertial sensors of large area (i.e. using long interrogation time and/or large momentum transfer techniques \cite{Dickerson2013}). Efficient vibration isolation at low frequencies (below few Hz) is technically challenging (e.g. \cite{Hensley1999}) and not suited for field applications. We will show that interleaving allows to reduce the impact of this key noise source. In our sensor, the impact of inertial noise can be analyzed by considering a center of rotation located at the top Raman beam: inertial noise then appears as linear acceleration noise of both mirrors, plus rotation noise of the bottom mirror. The rotation noise translates into random variations of the angle $\theta_B(t)$ of the Raman beam with respect to a geostationary reference frame \cite{Stockton2011}, and impacts the interferometer phase as $\left [\theta_B(2T)-\theta_B(0)\right]$ (Eq.~\eqref{eqn:rotphase4p}). In joint measurements, in which $\pi/2$ pulses are shared (occurring at times $0$ and $2T$), the contribution of rotation noise cancels out when averaging $N$ successive measurements (see Material and Methods for a derivation). Therefore, the gyroscope sensitivity should improve as $\tau^{-1}$, where $\tau=2 N T$ is the integration time, instead of $\tau^{-1/2}$ in the case of uncorrelated measurements impacted by rotation noise. Besides averaging rotation noise, the interleaved operation of our sensor allows us to reduce the impact of residual linear acceleration noise: because our sampling frequency ($1/T_c=3.75$~Hz) is higher than the frequencies at which the acceleration noise mostly contributes (around 0.5~Hz, see Table S1 in \SM), correlations appear between successive measurements, yielding a scaling of the sensitivity that approaches $\tau^{-1}$ (rather than $\tau^{-1/2}$). \begin{figure}[!h] \includegraphics[width=\linewidth]{Fig3.pdf} \caption{\label{fig:short_term} \textbf{Gyroscope sensitivity.} Stability analysis of a 11.3 hour portion of the rotation rate measurements of Fig.~\ref{fig:long_acq}, between 1:22 and 12:47 on September 24th, 2017. The error bars represent the 68~$\%$ confidence intervals on the estimation of the Allan deviation. Dashed black line: $3.3\times 10^{-8}$~rad.s$^{-1}\times \tau^{-1/2}$. Green dashed line: $\tau^{-1/2}$ scaling from the one shot Allan deviation. Red dotted-dashed line: $\tau^{-1}$ scaling from the one shot Allan deviation. Orange dotted line: detection noise limit corresponding to $8\times 10^{-9}$~rad.s$^{-1}\times \tau^{-1/2}$. } \end{figure} Fig.~\ref{fig:short_term} shows the Allan deviation of the gyroscope stability for a 11.3 hour portion of night data of Fig.~\ref{fig:long_acq}. The improvement of the sensitivity as $\tau^{-1}$ for integration times up to $\simeq 7$~s is clear. The stability then gradually enters the $\tau^{-1/2}$ regime characteristic of uncorrelated white noise, corresponding to a sensitivity of $3\times 10^{-8}$~rad.s$^{-1}$.Hz$^{-1/2}$. This sensitivity, which improves by more than a factor of 3 on our previous result \cite{Dutta2016}, establishes the new record for cold atom gyroscopes. As a comparison, our short term sensitivity competes favorably with that of the best fiber-optics gyroscopes \cite{Lefevre2014}. Such sensitivity enables to study several systematic effects affecting a cold atom gyroscope, for the first time in the range of low $10^{-9}$~rad.s$^{-1}$. \subsection*{Systematic effects and gyroscope long term stability} A systematic shift specific to the interleaved interrogation originates from the light scattered from the MOT towards the atoms interrogated in the interferometer \cite{Meunier2014}. The MOT scattered light is close to resonance and induces a loss of contrast and a differential light shift (AC Stark shift). The influence of induced light shifts is reduced by the spin-echo-like four-pulse sequence, and by the use of $\vec{k}_\mathrm{eff}$ reversal: alternating $\pm\hbar\vec{k}_\mathrm{eff}$ momentum transfers changes the sign of the inertial phase shift but not the one of the clock-terms (e.g. differential light shift), which are rejected when taking the half-difference of two measurements (as done in Fig.~\ref{fig:long_acq}). We measured the residual effect, and showed that it corresponds to an instability below $7\times 10^{-11}$~rad.s$^{-1}$ \ (see \SM). Although currently negligible, this effect is purely technical, and could be resolved by having the MOT and the detection region out of view from the atom interferometer region in future designs. The most important systematic effects in atom interferometers with separated Raman beams originate from relative wavefront mismatch coupled to deviations of the atom trajectories with respect to the ideal one \cite{Gauguet2009,Tackmann2012}. In our system, a relative angular misalignement $\vec{\delta\theta}$ between the top and bottom mirrors used to retro-reflect the Raman beams (Fig.~\ref{fig:detailSequence3IJ}), coupled with an error of launch velocity $\vec{\delta v}$ (with respect to a velocity of $-\vec{g} \ T$ at the first Raman pulse) in the $(y,z)$ plane results in a phase shift \begin{equation} \Delta\Phi = 2Tk_\mathrm{eff} \left(\delta v_y \delta \theta_y + \delta v_z \delta \theta_z \right) = 12 \ \text{mrad}\times \left (\frac{\delta v_{y,z}}{1 \ \text{mm.s}^{-1}}\right) \times \left(\frac{\delta\theta_{y,z}}{1 \ \mu\text{rad}}\right ). \label{eq:shift_relative_tilt} \end{equation} We explain in the Materials and Methods section how we set the parallelism between the two Raman beams and the velocity of the atoms to approach the ideal trajectory, in order to achieve an uncertainty on the residual systematic shift of 21~mrad (i.e. $4.6$~nrad.s$^{-1}$, from Eq.~\eqref{eq:constant_rot})). After this systematic analysis and the corresponding fine-tuning of the apparatus, we recorded the rotation rate acquisition displayed on Fig.~\ref{fig:long_acq}. The stability of the gyroscope over the entire acquisition is analyzed in the \SM \ (Fig.~S5), and is in agreement with that read from Fig.~\ref{fig:short_term} for shorter integration times. \subsection*{Dynamic rotation rate measurements.} We use the unprecedented sampling rate and inertial sensitivity of our gyroscope to perform measurements of weak dynamic rotation rates. To this end, we modulate the orientation of the experiment around the $y$ axis. This was performed by applying a force on the bottom plate linking the experimental frame to the vibration isolation platform, via the voice-coil actuator controlling the tilt $\theta_x$ of the apparatus. We apply sinusoidal modulations of the form $\theta_x(t)=\theta_{0}\sin(\omega t)$ with a period $2\pi/\omega$ and with an amplitude $\theta_{0}$ of few $10^{-7}$~rad. The resulting rotation rate is of the form $\vec{\Omega}(t)=\Omega_0\cos(\omega t) \hat{u}_y$, with $\Omega_0=\omega\theta_{0}$. The measurements are reported in Fig.~\ref{fig:modulation} for modulation periods of 5~s and 10~s. The respective modulation amplitudes are $2.3\times 10^{-7}$~rad and $3.4\times 10^{-7}$~rad. Panels A and B show the atomic phase extracted from the transition probability, $P(t)$, which follows the sinusoidal modulation. The total rotation signal from the atom interferometer is the sum of this atomic phase and the phase compensated in real time. A Fourier analysis of the total signal is shown in panel C. Within our frequency resolution, we find that the amplitude of the reconstructed rotation rate signal agrees with the expectation of $\Omega_0$ with a relative precision of $5\%$. A more detailed analysis is presented in the \SM \ (section~S5). Our proof-of-principle experiment, performed in a so-far unexplored range of time resolution and inertial sensitivity for a cold-atom sensor, demonstrates the impact of interleaved atom interferometry for dynamic measurements. \begin{figure}[!h] \includegraphics[width=\linewidth]{Fig4.pdf} \caption{\label{fig:modulation} \textbf{Measurement of dynamic rotation rates.} Atom interferometer phase deduced from the transition probability, for rotation rate modulations of 5~s period (A) and 10~s period (B). Plain line: sinusoidal fit to guide the eye. C): Fourier analysis of the total rotation rate signal, with a frequency resolution is 0.37~mHz. } \end{figure} \section*{Discussion} \label{discussion} We demonstrated the method of interleaving in a large-area atom interferometer, as a way to reach high sampling frequencies and high inertial sensitivities together. Interleaving enables to efficiently average vibration noise (the largest noise source in cold-atom inertial sensors), and is thus a promising way of reaching the quantum projection noise limit, a necessary condition before increasing the atom flux or implementing schemes to approach the Heisenberg limit. As a result, we demonstrated record short term sensitivities for a cold-atom gyroscope, and could thus characterize systematic effects in a so-far unexplored range. The rotation rate sensitivity and stability which we achieved competes with that of the best strategic-grade fiber-optics gyroscopes (long-term stability in the range of $5 \times 10^{-10}$~rad.s$^{-1}$ \cite{Lefevre2014}). Our results thus pave the way for a change of technology in future high-precision inertial navigation systems. In our setup, the maximum number of interleaved measurements is technically limited to 3 because of the arrangement of our detection system with respect to the MOT region (see Materials and Methods). In a dedicated design, e.g. where the detection region would be out of view from the upcoming clouds, sampling frequencies of 20~Hz or higher could be reached. As an alternative, the use of atoms characterized by different transition wavelengths for the cooling/detection/atom interferometer would be beneficial, in order to circumvent the effects associated with the scattered light from the source or the detected atoms. Our technique is thus well-suited to ongoing developments of atom interferometers with alkaline-Earth atoms \cite{Hu2017}. Interleaving ties well with laser-cooling techniques, which are able to rapidly (in less than $100$~ms) produce cold samples with more than $10^7$ atoms. Laser cooling beyond optical molasses such as degenerate Raman sideband cooling appear as a suitable solution for an increased brightness without compromising the cycling frequency. Interleaving is, in principle, also compatible with the production of ultracold, collimated, atom sources \cite{Asenbaum2017}, provided they can be produced \cite{Rudolph2015} or extracted at sufficiently high (several Hz) repetition rates. The method of interleaved atom interferometry can be applied to different sensor architectures, such as multi-axes accelerometers (by alternating measurements along different axes at a high repetition rate), gavimeters or gradiometers. For example, interleaving can be exploited to realize a gravimeter of both high accuracy and high sensitivity in a single instrument, potentially allowing to surpass superconducting gravimeters that currently feature record sensitivities but require regular calibrations. As such, interleaving is representative of the flexibility of cold atoms for realizing versatile inertial sensors, as compared to architectures involving macroscopic masses and electro-mechanical systems. Regarding fundamental physics applications, reaching high sampling rates is a prerequisite for future studies on dark-matter with atomic accelerometers \cite{Graham2016}, as well as for gravitational wave detection with atom interferometers \cite{Chaibi2016,Graham2016a}. Interleaving is therefore a key concept for future applications of cold-atom inertial sensors. \section*{Materials and Methods} \subsection*{Details of the experiment} Cesium atoms loaded from a 2D Magneto-Optical Trap (MOT) are trapped and laser-cooled in a 3D-MOT. We launch the atoms vertically at a velocity of $5.0 \ \text{m.s}^{-1}$ using moving molasses with a (3D) cloud temperature of $1.2 \ \mu\text{K}$. After the MOT and prior to the interrogation, the atoms are prepared in the $|F=4,m_F=0\rangle$ state using a selection scheme based on the Stern-Gerlach effect (magnetic deflection of the atoms in $m_F\neq 0$ states). Light pulse interferometry is realized using two phase-locked Raman lasers which couple the Cesium clock states (hyperfine splitting of $9.192 \ \text{GHz}$). The Raman lasers have a wavelength close to the $D_2$ line (wavelength $\lambda \simeq 852$~nm) and are detuned by $470$~MHz from the excited state to reduce incoherent scattering. The impact of residual relative Raman laser phase noise has been estimated to 50~mrad per shot of atom interferometer phase. The Raman lasers are sent to the atoms through two optical windows separated by $L=\frac{3}{8}gT^2\simeq 59$~cm, with an interrogation time $2T=801 \ \text{ms}$. We use gaussian Raman beams with $1/e^2$ diameter equal to $40 \ \text{mm}$ and about 120 mW of total power. The interferometer output signal is determined by the probability of transition, $P$, from the $F=4$ to the $F=3$ state, which is read out via fluorescence detection of the two levels' populations after the atom interferometer light-pulse sequence. The probability of transition is modulated according to $P=P_0+A\sin\Phi$, where $C=2A$ is the interferometer contrast and $\Phi$ the interferometer phase. Our experiment uses retro-reflected Raman beams, such as to form two pairs of Raman beams inducing two transitions: one in the $+\vec{k}_\mathrm{eff}$ direction, and another in the $-\vec{k}_\mathrm{eff}$ direction. Selectivity of the $\pm \vec{k}_\mathrm{eff}$ transitions is provided by tilting the Raman beams by an angle $\theta\simeq 3.80$ degrees with respect to the horizontal, in order to introduce a Doppler shift ($\pm k_\mathrm{eff} g T \sin\theta /2\pi \simeq \pm 611$~kHz at the first and last $\pi/2$ pulses) which is much larger than the width of the atom Doppler distribution ($\sim 40$~kHz). To follow the resonance condition at each Raman pulse, we step-wise change the relative frequency between the two Raman lasers during the sequence, such as to match the values given by the underlying frequency chirp pattern (see details in Fig.~S2 of \SM). To apply the frequency steps, we use a direct digital synthesizer (DDS) driven by an FPGA. \textit{Real-time compensation of vibration noise and mid-fringe lock.} We measure the vibrations of the setup with two broadband seismometers (model \textit{Trillium Compact 120~s }from \textit{Nanometrics}) located at the bottom and top of the experimental frame (see Fig.~\ref{fig:detailSequence3IJ}). From the measured signal, we estimate the interferometer phase shift due to vibrations and apply a corresponding phase jump to the relative phase of the Raman lasers 15~ms before the last pulse. This allows us to reduce the standard deviation of the interferometer phase from about 3.2~rad to 0.5~rad. To work within the linear regime where the sensitivity is maximal, we alternate measurements on both sides of a fringe, and compute an error signal from two successive measurements of the transition probability. This error signal is integrated and used to servo-lock the interferometer at mid-fringe, via a feedback on the Raman laser relative phase. More details are given in the \SM, section S1. \subsection*{Efficient averaging of vibration noise} Following Eq.~\eqref{eqn:rotphase4p}, and assuming that the Raman lasers are oriented purely in the $x$ direction, the 4-light-pulse atom interferometer phase shift is given by (we neglect the duration of the Raman pulse): \begin{equation} \Phi = k_\mathrm{eff} \left[ x_b(0)-2x_t(T/2)+2x_t(3T/2)-x_b(2T)\right], \end{equation} with $x_{b,t}(t)$ the position of the bottom and top retro-mirrors with respect to the free-falling atom cloud. The phase shift can be re-written as \begin{eqnarray} \Phi & = &k_\mathrm{eff}\left[x_t(0)-2x_t(T/2)+2x_t(3T/2)-x_t(2T)\right] + k_\mathrm{eff} \Big( [x_b(0)-x_t(0)] - [x_b(2T)-x_t(2T)] \Big) \nonumber \\ & = & \Phi^{\text{acc}}_t + k_\mathrm{eff} L \left( \theta_b(0)-\theta_b(2T) \right ), \label{eq:acc_rot} \end{eqnarray} with $L=\frac{3}{8}gT^2$ the distance between the bottom and top mirrors, and $\Phi^{\text{acc}}_t$ the term associated to the linear acceleration of the top mirror. The second term represents pure rotation of the bottom mirror about the position of the top one. Recalling that $T_c=2T/3$ and writting as $\Phi_i=\Phi(iT_c)$ the atom interferometer phase at cycle $i$, the mean phase after $N$ measurement reads \begin{equation} \bar{\Phi}_N = \frac{1}{N}\sum_{i=0} ^{N-1} \Phi_i = \frac{1}{N} \sum_{i=0} ^{N-1} \left( k_{\text{eff}}L \left[\theta_b(iT_c)-\theta_b((i+3)T_c) \right] + \delta\tilde{\phi}_i \right ). \label{eq:mean_phase} \end{equation} The term $\delta\tilde{\phi}_i$ encompasses contributions of detection noise, uncompensated linear acceleration noise and laser phase noise. When expanding the sum in Eq.~\eqref{eq:mean_phase}, most of the $\theta_b$ terms mutually cancel, such that the mean phase reads \begin{equation} \bar{\Phi}_N=k_{\text{eff}}L\frac{\theta_b\left(0\right)-\theta_b\left( (N+2)T_c\right)}{N} + \frac{1}{N} \sum_{i=0} ^{N-1} \delta\tilde{\phi}_i. \label{eq:avg_phase} \end{equation} This equation shows that the random rotation noise averages as $N^{-1}$ (first term). The second term represents the uncorrelated noise contributions of standard deviation $\sigma_{\delta\phi}$. Their sum equals $\sqrt{N}\times\sigma_{\delta\phi}$, which corresponds to a scaling of the phase sensitivity as as $N^{-1/2}$. Besides rotation noise, uncompensated linear accelerations in the frequency range $[0.1 - 1]$~Hz contribute to a large part the interferometer phase noise (see the \SM \ section S3 for details). This contribution, estimated to typically about 500~mrad per shot, dominates the noise budget and may prevent from observing a clear $\tau^{-1}$ scaling of the gyroscope sensitivity. Interleaving, however, allows to over-sample these fluctuations, thus introducing correlations between successive measurements, which also contributes to the $\tau^{-1}$ dependence of the instrument sensitivity. \subsection*{Alignment of the two Raman beams and atom trajectory} We set the parallelism between the top and bottom Raman beams by means of a two-axis piezo-motorized mirror mount with $0.7 \ \mu$rad resolution. By optimizing the contrast of the interferometer, we approach the parallelism with an uncertainty of about $3 \ \mu$rad, which is required for the matter-waves to recombine at the output of the interferometer. For the fine adjustment, we measure the dependence of the phase shift of Eq.~\eqref{eq:shift_relative_tilt}, $\Delta\Phi=2Tk_{\text{eff}} (\delta v_y\delta\theta_y+\delta v_z\delta \theta_z)$, on $\delta \theta_{y,z}$ and $\delta v_{y,z}$ (as defined in the main text). To this end, we set the atom trajectory in the $(y,z)$ directions by varying the tilt of the experiment ($y$ direction) and the launch velocity during the moving molasses phase ($z$ direction). In the $z$ direction, we could zero the systematic effect with an uncertainty of $5$~mrad. This amounts to set the velocity of the atoms at the first Raman pulse to the ideal velocity ($v_z=gT$) with an uncertainty of $0.6$~mm.s$^{-1}$, and to set the parallelism between two mirrors in the $z$ direction with an uncertainty of $0.7 \ \mu$rad. The minimization of the systematic shift in the $y$ direction was technically more difficult to achieve than in the $z$ direction: recording the dependence of the phase shift on $\delta\theta_y$ for various velocities required to tilt the entire apparatus by several mrad in order to vary $\delta v_y$ by several mm.s$^{-1}$. This procedure required to manually move masses on the base plate of the experiment sitting on a floating vibration isolation platform, which introduced instabilities. We managed to set the $y$-velocity close to the ideal velocity ($v_y=0$) with an uncertainty of 1.8~mm.s$^{-1}$. The residual shift corresponds to a phase variation of $21$~mrad per $\mu$rad of $\delta \theta_y$ variation. \subsection*{Limitation to the number of interleaved interferometers} When trying 5 interleaved cycles, we observed a dramatic loss of contrast of the interferometer. The reason is that when a (descending) atom cloud at the output of the interferometer enters the detection region, a part of the light scattered by the atoms is directed towards the (ascending) cloud, which optically pumps atoms to unwanted magnetic states and heats them before they enter the interferometer. \section*{Supplementary Materials} Supplementary material for this article is available and contains:\\ Supplementary text, Sections S1 to S6\\ Figures S1 to S5\\ Table S1\\ References \cite{Lautier2014,Cheinet2008,Stockton2011} \label{biblio} \bibliographystyle{ScienceAdvances}
\section{Introduction} Type I thermonuclear X-ray bursts have been used to obtain neutron star (NS) parameters. In particular, bursts happening during the hard persistent states of the systems can be used for such analysis \citep[see discussions in][]{SPRW11,Kajava.etal:14,Poutanen.etal:14,Suleimanov.etal:16}.\footnote{We note here that the bursts occurring in the soft, high-accretion-rate state never show spectral evolution consistent with theoretical prediction \citep{Kajava.etal:14}. Therefore, this kind of burst cannot be used to determine NS parameters at all. } In order to use full information on the variations of the burst spectrum temperature and normalization, the so called cooling tail method or its modification \citep{SPRW11,Poutanen.etal:14,Suleimanov.etal:17} have been used. More accurate results can be obtained by directly fitting the burst spectra at different flux levels with NS atmosphere models \citep{Nattila.etal:17}. However, these hard-state bursts show a spectral evolution that deviates from the theoretically predicted behaviour for passively cooling NSs when the burst luminosity drops below a certain level. Furthermore, the higher the persistent flux, the more significant are the deviations. For instance, deviations start to be visible at burst luminosities below 20\% of the Eddington value $L_{\rm Edd}$ for the bursts taking place at persistent luminosities of about $0.01\,L_{\rm Edd}$ \citep{Nattila.etal:16}. On the other hand, the X-ray bursts of the helium accreting NS in 4U\,1820$-$30 happen at the relatively high persistent luminosity of about $0.07\,L_{\rm Edd}$, and such deviations begin at significantly higher burst luminosity of $\approx 0.7\,L_{\rm Edd}$ \citep{Sul.etal:17}. This leads us to the conclusion that additional heating by the accreted gas is the cause of the deviations. Therefore we need to develop NS atmosphere models with an additional energy dissipation in the surface layers. Such models would be applicable to the hard-state bursts. On the other hand, in the soft state the accreted matter likely spreads over the NS surface { forming} a spreading/boundary layer \citep{IS99,SulP06}. Its interaction with the NS atmosphere cannot be described by a formalism involving interaction of single particles, but a hydrodynamical treatment would be needed. Thus the modelling of bursts happening in the soft state will not be considered here. X-ray spectra of accreting compact objects such as NSs and black holes in their hard persistent states form in a hot rarefied medium. In black holes, the most likely source of this radiation is the inner geometrically thick and optically thin hot accretion flow \citep[see e.g. reviews by][]{DGK07,PV14,YN14}. In accreting NSs this radiation maybe produced also at the NS surface \citep{DDS01}, which even can dominate the total power. In this paper we consider old weakly magnetized NSs in low-mass X-ray binaries (LMXBs). \citet{ZS69} were among the first to discuss the emission from a NS surface heated by accreted matter. They considered two physical processes that lead to deceleration of protons in NS atmospheres. The simplest one is Coulomb interaction with electrons. In this case, the main part of the proton kinetic energy is released deep in the optically thick atmospheric layers resulting in the rather thermal emergent spectra. Another possibility is excitation of collective plasma processes by the protons. Here the proton energy is dissipated within an optically thin atmospheric layer and the emergent spectrum may have a shape far { different} from the blackbody. \citet{AW73} confirmed these conclusions using first numerical models of accretion heated NS atmospheres. They considered hydrogen NS atmospheres heated by protons falling radially with free-fall velocity. The proton deceleration was considered in a self-consistent way. Two input parameters of the model were considered, namely the NS mass and the accretion luminosity. The most important properties of the accretion heated atmospheres, such as an overheated Compton-cooled outer layers and spectral hardening with the increase of the accretion luminosity were found in this work. Later the problem was considered in detail by \citet{BSW92}. They provided useful relations for describing the proton velocity profiles and the vertical distribution of the accretion heating, which were used by other authors for modeling accretion heated atmospheres \citep{Turolla.etal:94, Zampieri.etal:95, Zane.etal:98}. They also considered hydrogen atmospheres heated by accreting protons. They confirmed the basic properties of the heated model atmospheres found by \citet{AW73}, and additionally declared existing of the so called hot solutions, where the temperature can reach almost 10$^{12}$\,K \citep{Turolla.etal:94}. The properties of such "hot" solutions were investigated by \citet{Zane.etal:98}, who, in particular, demonstrated the importance of electron-positron pair creation. \citet{Zampieri.etal:95} concentrated on the low-luminosity accretion heated atmospheres. They assumed the energy release mainly in the optically thick layers of the atmosphere. Therefore, the temperature structures of these models at the spectrum formation depths were close to that of the undisturbed model atmospheres with the same luminosities. As a result, they obtained spectra harder than the blackbody and very similar to those of undisturbed NS atmospheres \citep[see, e.g.][]{Romani:87, Zavlin.etal:96}. The main reason is the dependence of the free-free opacity on the photon energy $k_{\rm ff} \sim E^{-3}$. Photons prefer to escape from an atmosphere in the most transparent energy bands. \citet{Zampieri.etal:95} also found a clear division between the outer heated atmospheric layers cooled by Compton scattering from the almost isothermal inner part cooled by free-free processes. \citet{DDS01} computed the accretion heated NS atmospheres and proton deceleration self-consistently and used the results for interpretation of the hard persistent spectra of some LMXBs. For the first time they showed the importance of the temperature of accreted protons on the atmosphere properties. They also considered the bulk velocity as a free parameter. The results obtained by \citet{Zampieri.etal:95} and \citet{DDS01} were widely used for interpretation of the NS spectra in LMXBs during low mass-accretion-rate states \citep[see e.g.][]{Homan.etal:14, Wijnands.etal:15}. Also deceleration of the protons in magnetized NS atmospheres was considered before \citep[see e.g.][]{NSW93}, and the results were used for the modeling of such atmospheres by \citet{Zane.etal:00}. In this paper we develop a method to compute models of NS atmosphere heated by accreted matter. It is based on the approach developed by \citet{DDS01}, which we slightly modified. In contrast to previous papers devoted to pure hydrogen atmospheres heated by protons, here we consider arbitrary chemical composition of the atmospheres and an arbitrary mix of protons and $\alpha$-particles for the accreted particles. We present the basic properties of the accretion-heated NS atmospheres and their dependence on the input parameters such as the velocity of accreted particles and their direction, the accretion- and the intrinsic NS luminosities. We also compare the developed models to the observed spectral evolution of hard-state X-ray bursts. \section{The model} \label{sec:method} \subsection{Main equations} We consider steady-state hot NS atmospheres in plane-parallel approximation with additional heating in the surface layers caused by supra-thermal accreted particles. The basic principles of the modeling of hot, undisturbed NS atmospheres were presented in our earlier works \citep{SPW11,SPW12}. This work is based on the formalism described in the latter paper. We consider a uniform non-rotating NS with mass $M$, radius $R$ and intrinsic luminosity $L$. The input parameters for the NS atmosphere model are the surface gravity $g$, the effective temperature $T_{\rm eff}$, and the chemical composition. The effective temperature here is a parameter describing the intrinsic bolometric surface flux \begin{equation} \sigma_{\rm SB}T_{\rm eff}^4 = \int_0^\infty F_{0,\nu} (0) \, d\nu = F_0 , \end{equation} where $ \sigma_{\rm SB}$ is the Stefan-Boltzmann constant. Here the argument of $F_{0,\nu}(0)$ means that the flux is measured at the surface, while the lower index $0$ corresponds to the intrinsic flux. Another parameter, the relative intrinsic NS luminosity $\ell = L/L_{\rm Edd}$, could be used instead of $T_{\rm eff}$. Here and below a relative luminosity means some luminosity normalized to the Eddington luminosity. Both the surface gravity $g$ and the Eddington luminosity $L_{\rm Edd}$ are computed for Schwarzschild metric \citep[see details in][]{Suleimanov.etal:16, DS18}. The Eddington luminosity depends also on the hydrogen mass fraction $X$. In the previous works \citep{SPW11, SPW12,Nattila.etal:15}, we computed models of atmospheres consisting of pure hydrogen, pure helium, solar hydrogen/helium mixture enriched by various fractions of heavy elements, from the solar abundance down to an one-hundredth of that, as well as heavy metals. Here we consider pure helium and solar composition NS atmospheres only. We express the additional luminosity arising due to external heating by fast particles through the relative accretion luminosity $\ell_{\rm a} = L_{\rm a}/L_{\rm Edd}$. We assume that the kinetic energy of the fast particles is thermalized inside the atmosphere and is radiated away through the surface. As a result, the emergent bolometric flux is higher by this relative fraction: \begin{equation} F= \int_0^\infty F_\nu(0)\,d\nu = F_0 (1+\ell_{\rm a}/\ell). \end{equation} Let us consider for simplicity identical particles with mass $m_{\rm i}$ moving along the normal to the NS surface with the same velocity $\veloc_0$ before penetrating into the atmosphere (more general cases will be described later). The total accretion luminosity is \begin{equation} \label{accrL} L_{\rm a} = 4\pi R^2 \,\dot m c^2\,(\gamma-1), \end{equation} where \begin{equation} \gamma=\frac{1}{\sqrt{1-\veloc_0^2/c^2}} \end{equation} is the Lorentz factor. Here $ \dot m$ is the local mass accretion rate (per unit area), which can be related to $\ell_{\rm a}$ and the NS surface gravity $g$ as \begin{equation} \label{dotm} \dot m = \ell_{\rm a}\frac{g}{\kappa_{\rm e}\,c\,(\gamma-1)}. \end{equation} The value of $\dot m$ is conserved in the atmosphere, but the number density $n$ of the accreted particles and their velocity $\veloc$ can change according to the mass conservation law \begin{equation} \dot m = n m_{\rm i} \veloc. \end{equation} The flux of the accreting particles creates the ram pressure $P_{\rm ram} = \dot m\, \gamma \veloc$, which manifests itself as an additional acceleration pressing the atmosphere down \begin{equation} \label{eq:gram} g_{\rm ram} = \frac{1}{\rho}\frac{dP_{\rm ram}}{dr} = -\dot m \frac{d}{dm}(\gamma \veloc), \end{equation} where $\rho$ is the plasma density of the atmosphere and $m$ is a Lagrangian independent variable--column density, defined as $dm=-\rho dr$. We note that the velocity $\veloc$ is positive in the direction of increasing $m$. The ram pressure force has to be included into the hydrostatic equilibrium equation, the first equation determining the structure of the atmosphere \begin{equation} \frac{1}{\rho}\frac{dP}{dr} = -g-g_{\rm ram}+g_{\rm rad}, \end{equation} where $P$ is the gas pressure and $g_{\rm rad}$ is the radiative acceleration (as defined in \citealt{SPW12} for non-isotropic Compton scattering). The accreted particles do not directly affect the equation of radiative transfer for the specific intensity $I(x,\mu)$, and it is the same as for the undisturbed atmosphere \citep[see details in][]{SPW12}. Here $\mu = \cos \theta$ is the cosine of the angle between the surface normal and the direction of radiation propagation, $x=h\nu/\melectron c^2$ is the photon energy in units of electron rest mass. We note that the fully relativistic, angular dependent redistribution function is used to describe Compton scattering \citep[see][]{NP93, PS96}. The accretion of fast particles heats the NS surface producing additional radiation flux $\dot m c^2 (\gamma-1)$. The kinetic energy of fast particles is released in the NS atmosphere gradually and the local energy dissipation rate has to be proportional to the deceleration rate of the particles considered in the next section. The general form of the local energy dissipation rate, which is important for modeling of the heated atmospheres, takes the following form: \begin{equation} \label{eq:Qplus} Q^+ = -\frac{d}{dm} \left(\dot m c^2 (\gamma-1)\right) =- \dot m \gamma^3 \veloc \frac{d\veloc}{dm}. \end{equation} We assume that all the local dissipated energy is transformed to radiation, therefore, we can present the change in the radiation flux as \begin{equation} Q^+ = -\frac{d}{dm} \int_0^\infty F_x(m)\,dx . \end{equation} The energy balance equation now takes the form \begin{equation} \label{eq:econs} 2\pi\! \int^{\infty}_{0}\!\!\! \! dx\, \!\int^{+1}_{-1} \!\! \!\left[\sigma(x,\mu) + k(x)\right] \left[I(x,\mu)-S(x,\mu)\right] \, d\mu = -Q^+, \end{equation} and has to be fulfilled at the every depth in the atmosphere (for the undisturbed atmosphere $Q^+=0$). Here $k(x)$ is the ``true'' absorption opacity, and $\sigma(x,\mu)$ is the electron scattering opacity \citep[see definitions in][]{SPW12}. Thus the hydrostatic equilibrium and the energy balance equations describing the NS atmosphere, can be modified easily to account for accretion of fast particles with equal mass and velocity along the normal. It is clear that the dependence { of the particle deceleration $d\veloc/dm$ on depth} fully determines the atmosphere model (in addition to the standard parameters defining the undisturbed atmosphere). Below we derive the deceleration function and generalize the treatment to a distribution of particles obliquely accreting to the NS surface. \subsection{Stopping of fast particles in the atmosphere} Let us consider a fast particle having velocity $\veloc$ directed into the atmosphere, mass $m_{\rm i}$ and charge $Ze$ moving through the plasma with temperature $T$ and electron number density $n_{\rm e}$. { Here and further $e$ is the charge of electron and $\melectron$ is the mass of electron.} The particle loses energy via Coulomb interactions with the plasma electrons. The basic physics of deceleration of such particles is well established (see e.g. \citealt{AW73, DDS01}, and chapter 3 in \citealt{FKR02}). The main parameter describing deceleration rate is the slowing-down timescale \begin{equation} \label{tsd} t_{\rm s} = -\frac{\veloc}{d\veloc/dt} \approx \frac{m_{\rm i}^2 \veloc^3}{4\pi n_{\rm e}(Ze)^2e^2\,\ln \Lambda} \frac{\melectron}{m_{\rm i}+\melectron}, \end{equation} which { can be solved for} the deceleration \begin{equation} \label{dfc} \frac{d\veloc}{dt}= -\frac{\veloc}{t_{\rm s}} \approx -f(x_{\rm e})\,\frac{4\pi n_{\rm e}(Ze)^2e^2}{m_{\rm i} \melectron \veloc^2}\,\ln \Lambda. \end{equation} The corresponding energy loss is \begin{equation} \label{eq:dedt} \frac{dE}{dt} \approx -f(x_{\rm e})\,\frac{4\pi n_{\rm e}Z^2 e^4}{\melectron \veloc}\,\ln \Lambda. \end{equation} Here $\ln \Lambda$ is the Coulomb logarithm: \begin{equation} \label{qlog} \ln \Lambda \approx \ln \frac{2m_{\rm i} \melectron^{3/2} \veloc^2}{\hbar (m_{\rm i}+\melectron)\sqrt{4\pi n_{\rm e} e^2}} \end{equation} for the case $\veloc > \alpha\,c \approx c/137$ \citep{Larkin60} ($\alpha$ is the fine-structure constant). At low particle velocities ($\veloc \ll \alpha\,c$), Eq.\,(\ref{qlog}) gives too small values and we use instead the standard Coulomb logarithm for a thermal plasma \begin{equation} \ln \Lambda_{\rm T} \approx \ln \frac{3}{2e^3}\frac{(kT)^{3/2}}{(\pi\,n_{\rm e})^{1/2}}, \end{equation} where $k$ is Stefan-Boltzmann constant. In computations we choose the { larger value of} $\ln \Lambda$ and $\ln \Lambda_{\rm T}$. The function $f(x_{\rm e})$ takes into account the reduction of the deceleration force at low particle velocities and is expressed as \begin{equation} f(x_{\rm e}) \approx \phi(x_{\rm e})-x_{\rm e} \phi'(x_{\rm e}), \end{equation} where $\phi(x)$ is the error function, and $x_{\rm e} = (\melectron \veloc^2/kT)^{1/2}$ is the ratio of the particle velocity to the averaged thermal electron velocity. For the computations we use the approximation \begin{equation} f(x_{\rm e}) \approx \frac{4x_{\rm e}^3}{3\sqrt{\pi}+4x_{\rm e}^3} \end{equation} suggested by \citet{AW73}. \subsection{Heating by { thermally} distributed fast particles} The X-ray spectra of LMXBs in their hard persistent states are well described with the spectrum of radiation Comptonized in a hot electron slab with optical depth $\tau_{\rm e} \sim 1$ and temperature $kT_{\rm e} \sim 15-50$\,keV \citep{Barret00,BGS17}. This radiation may be produced in the optically thin and geometrically thick accretion flow which could be described with the advection-dominated accretion flow (ADAF) model \citep[see e.g.][]{YN14}. The ADAF model differs from the standard accretion disc model \citep{SS73} at least in two respects. The gravity of the central object is balanced not only by the rotation, but the radial gas pressure gradient as well. It is also important that the ion temperature in ADAF model is close to the virial one at a given radius $r$ \begin{equation} T_{\rm vir}(r) \approx \frac{GMm_{\rm i}}{3k\,r} \approx 5.4\times 10^{10}\,{\rm K}\,\left(\frac{M}{M_\odot}\right)\, \left(\frac{r}{10^7\,{\rm cm}}\right)^{-1}\,\left(\frac{m_{\rm i}}{\mproton}\right) \end{equation} and can reach $10^{12}$\,K in the vicinity of the NS. Such high ion temperature provides a significant accretion flow thickness $h$, comparable with the radial distance, $h/r \sim 1$, and a high radial velocity of the matter, comparable with the free-fall velocity $V_{\rm ff}(r) = c\sqrt{R_{\rm S}/r}$. These properties imply a quite large impact angle of the { accreting} ions to the NS surface normal, and we consider this angle $\Psi$ as a parameter. Another parameter is the ratio of the bulk velocity of the particles to the free-fall velocity at the NS surface $\eta= V_0 / V_{\rm ff}(R)$ \citep[we follow here][]{DDS01}. Because the mean ion velocity at the virial temperature is close to $V_{\rm ff}$, the distribution of the ions over velocities has to be taken into account \citep{DDS01}. The ADAF could be so hot and rarefied that the Coulomb interactions are not efficient enough to establish the Maxwellian distribution \citep{MQ97}. Thus potentially the ion velocity distribution may significantly deviate from the Maxwellian. In this work, however, we assume that ions follow the relativistic Maxwellian distribution and we describe the ion temperature through its ratio to the virial temperature, $\chi=T_{\rm i}/T_{\rm vir}(R)$. It is necessary to note that in addition to the bulk kinetic energy, thermally distributed accreted particles contribute their thermal energy (enthalpy) to the atmosphere. Therefore, the accretion luminosity is larger than that given by Eq.\,(\ref{accrL}): \begin{equation} \label{therm_contr} L_{\rm a} \approx 4\pi R^2\, \dot m \,\left(c^2(\Gamma-1)+\frac{5}{2}\frac{kT_{\rm i}}{m_{\rm i}}\right), \end{equation} where \begin{equation} \Gamma=1/{\sqrt{1-V_0^2/c^2}} \end{equation} is the bulk Lorentz factor. The contribution of thermal energy is important at $\chi > 0.1$. We note that the input parameter in our model is a relative accretion luminosity $\ell_{\rm a}$, and therefore in our numerical computations we correct the local mass accretion rate obtained using Eq.\,(\ref{dotm}) to keep $\ell_{\rm a}$ fixed. The second important thing is that the parameters $\eta$ and $\chi$ are not completely free. The total gravitational potential energy of the accreted matter related to the free-fall Lorentz factor $\Gamma_{\rm ff}$ as $\dot m c^2(\Gamma_{\rm ff}-1)$ is released by three means. It is partially radiated away by the hot accretion flow, with the corresponding flux $F_{\rm flow}$. The rest is split up between the enthalpy of the hot matter and the energy of the bulk motion. In non-relativistic approximation, { the latter} can be presented by the equation $\dot m V^2_{\rm ff}/2 \approx F_{\rm flow}+\eta^2\dot m V^2_{\rm ff}/2 +\chi \dot m V^2_{\rm ff}/2$. Thus we have an additional constraint on the parameters $\eta^2+\chi < 1$. Furthermore, for the isotropic particle distribution in the co-moving frame there is a significant number of particles penetrating into the atmosphere and contributing their energy even when the bulk velocity is parallel to the surface, when the contribution of the bulk kinetic energy formally is absent. This effect is especially significant for the ram pressure. We account for this effect in our calculations. The relativistic generalization of the Maxwellian distribution is the Maxwell-J\"uttner distribution in the co-moving frame \begin{equation} \label{MJd} f'(p') =\frac{\Theta}{4\pi\,K_2(\Theta)}\,\exp{\left(-\Theta\gamma' \right)}, \end{equation} where $\gamma'$ is the particle Lorentz factor \begin{equation} \gamma'=\frac{1}{\sqrt{1-\veloc'^2/c^2}} = \sqrt{1+\mbox{\boldmath $p$}'^2}, \end{equation} $\veloc'$ is the particle velocity, $\mbox{\boldmath $p$}'= \gamma' \mbox{\boldmath $\varv$}'/c$ is the dimensionless momentum, $p'=|\mbox{\boldmath $p$}'|$, $\Theta$ is the normalized Gibbs parameter $\Theta = m_{\rm a}c^2/kT_{\rm i}$, and $K_2(\Theta)$ is the Macdonald function (the modified Bessel function of the second kind). The distribution is normalized to unity: \begin{equation} \label{norm} \iiint\limits_{-\infty}^{+\infty} \,f'(p'_{x},p'_{y},p'_{z}) \,dp'_{x}\,dp'_{y}\,dp'_{z} = 4\pi\int\limits_{0}^{\infty}p'^2f'(p')\,dp' = 1 . \end{equation} When the gas moves with some bulk velocity defined by the dimensionless average momentum $\mbox{\boldmath $P$}$ and corresponding Lorentz factor $\Gamma=\sqrt{1+\mbox{\boldmath $P$}^2}=(1-V_0^2/c^2)^{-1/2}$, the Maxwell-J\"uttner distribution takes the form \citep{BB56,NP94a} \begin{equation} \label{fdsh} f(\mbox{\boldmath $p$}) = \frac{\Theta}{4\pi\,K_2(\Theta)\Gamma} \exp{\left[-\Theta\left(\gamma\Gamma -\mbox{\boldmath $p$} \cdot \mbox{\boldmath $P$}\right)\right]}. \end{equation} \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig1.pdf} \caption{\label{fig1} The coordinate systems used in the paper. We also show the momentum of a single particle and its components with the corresponding angles. } \end{figure} Let us introduce two Cartesian coordinate systems with $z$ axis directed along the bulk velocity of the fast particles (see Fig.\,\ref{fig1}). The first one moves with the bulk velocity (the co-moving frame), and the second one (laboratory) is connected with the atmosphere. In the co-moving frame, the particle distribution follows the Maxwellian-J\"uttner distribution (\ref{MJd}). In the laboratory frame, two components of the momentum, $p_{x}=p'_{x}$ and $p_{y}=p'_{y}$, retain their values, but the third one is transformed as \begin{equation} \label{pz} p_{\rm z} = \Gamma \left(p'_{z}+\frac{V_0}{c}\gamma'\right). \end{equation} We note that the normalization of the distribution (\ref{fdsh}) remains unchanged \begin{equation} \iiint\limits_{-\infty}^{+\infty}\,f(p_{x},p_{y},p_{z}) \,dp_{x}\,dp_{y}\,dp_{z} = 1 . \end{equation} We note that the Lorentz factor $\Gamma$ in the denominator of (\ref{fdsh}) appears due to the Lorentz contraction of the elementary volume ($dz=dz'/\Gamma$). To estimate the energy deposition rate, we consider the impact of the particles distributed over the momentum components according to Eq.~(\ref{fdsh}), and assume that they move independently inside the atmosphere. Let us consider a particle with the momentum $\mbox{\boldmath $p$}=(p_{x},p_{y},p_{z})$. It has the {initial} velocity \begin{equation} \veloc_0=c\frac{p}{\sqrt{1+p^2}} \end{equation} and moves along the line that makes angle $\psi$ with the surface normal (directed toward the surface): \begin{equation} \cos\psi = -\frac{p_{r}}{p}, \end{equation} where $p_{r} = -(p_{z}\cos\Psi+p_{x}\sin\Psi)$, see Fig.\,\ref{fig1}. For the steady state flux of accreting particles we can replace the total time derivative in Eq.~(\ref{eq:dedt}) with the space derivative along the displacement direction $s$, and compute the deceleration \begin{equation} \frac{dE}{dt} = \veloc\frac{dE}{ds}=m_{\rm i}\veloc \cos\psi\frac{d}{dr}\left(\gamma c^2\right) =-\rho \,\gamma^3\cos\psi\,m_{\rm i}\veloc^2 \frac{d\veloc}{dm}. \end{equation} Here we used a relativistic representation for the kinetic energy of the particle $\gamma m_{\rm i} c^2$ and replaced the derivative from Euler ($r$) to Lagrangian ($m$) coordinates. Finally, using the energy dissipation rate due to Coulomb interaction given by Eq.~(\ref{eq:dedt}) we get \begin{equation} \label{dvdz} \frac{d\veloc}{dm} \approx -f(x_{\rm e})\frac{4\pi n_{\rm e}Z^2e^4}{\rho\,\gamma^3\cos\psi\,m_{\rm i} \melectron \veloc^3}\, \ln \Lambda. \end{equation} For a given atmosphere model (with given $T(m)$, $\rho(m)$ and $n_{\rm e}(m)$), we solve this equation to find $\veloc(m)$. The solution is then used to determine the specific energy deposition rate per unit mass (see also Eq.\,\ref{eq:Qplus}): \begin{equation} q^+(p_{x},p_{y},p_{z})= -\gamma^3 \veloc \frac{d\veloc}{dm} \approx f(x_{\rm e})\frac{4\pi n_{\rm e}Z^2 e^4} {\rho \cos\psi\,m_{\rm i} \melectron \veloc^2}\,\ln \Lambda. \end{equation} Integrating this equation over the possible initial momenta (with $p_{r}<0$), we get the total energy deposition rate by accretion: \begin{equation} \label{eq:Qplusfin} Q^+_{\rm a}= \dot m \iiint\limits_{-\infty}^{+\infty}\, \,f(p_{x},p_{y},p_{z})\,q^+ dp_{x}\,dp_{y}\,dp_{z}. \end{equation} The total energy released in the atmosphere is found by the integration over the depth \begin{equation} F_{\rm a} = \int_0^\infty Q^+_{\rm a}(m)\,dm. \end{equation} Similarly, we compute the contribution per unit mass to the ram pressure force along $r$ (see Eq.\,\ref{eq:gram}): \begin{equation} \cos\psi \frac{d}{dm}(\gamma\veloc) =- \cos\psi\, \gamma^3 \frac{d\veloc}{dm}\approx f(x_{\rm e})\frac{4\pi n_{\rm e}Z^2e^4}{\rho\,m_{\rm i} \melectron \veloc^3}\, \ln \Lambda. \end{equation} We note that only the normal component of the force is important. Thus the total ram pressure acceleration is obtained by integrating over all momenta (with $p_r<0$) \begin{equation} \label{gram} g_{\rm ram} = - \dot m \iiint\limits_{-\infty}^{+\infty} \,f(p_{x},p_{y},p_{z})\,\cos\psi\, \gamma^3 \frac{d\veloc}{dm} \,dp_{x}\,dp_{y} \,dp_{z}. \end{equation} Here and before we determine the contributions to the energy dissipation rate and ram pressure of fast particles per unit mass in order to separate the mass accretion rate $\dot m$ in the final equations (\ref{eq:Qplusfin}) and (\ref{gram}). \subsection{Thermal conduction} Previous works \citep{AW73,DDS01} demonstrated that the temperature gradient in the accretion-heated atmospheres can be significant, and the energy transport via thermal conduction may be not negligible. The thermal conduction flux is \begin{equation}\label{eq:fluxc} F_{\rm c}= \rho \kappa_{\rm c} \frac{dT}{dm}, \end{equation} where \begin{equation} \label{eq:kappac} \kappa_{\rm c} = 1.85\times 10^{-5}\frac{T^{5/2}}{\ln \Lambda_{\rm T}} \end{equation} is the heat transfer coefficient. The heating/cooling rate of the matter due to thermal conduction is given by \begin{equation} \label{Qc} Q_{\rm c} = \frac{dF_{\rm c}}{dm}. \end{equation} The total heating rate in Eq.\,(\ref{eq:Qplus}) then becomes \begin{equation} \label{allQ} Q^+ = Q^+_{\rm a} + Q_{\rm c}. \end{equation} \subsection{Computation of atmosphere structure} The general method of computation of the atmosphere structure is the iterative temperature correction approach. It was described in our previous paper \citep[see Sect.~2 of][]{SPW12}. Here we report only the differences caused by the inclusion of additional energy dissipation in the atmosphere. As in \citet{SPW12}, we start iterations with the gray atmosphere model defined on a grid of Rosseland optical depths. Other physical quantities such as gas pressure, density, number densities of the ions and atoms included into the model, opacities, and the column density grid $m$ are computed for the given temperature distribution on the Rosseland optical depth grid. Further computations are performed on the column density grid $m$. Using the current model atmosphere we compute the accretion and the conductivity heating using the method described above. We also derive the { vertical} radiation flux distribution { through} the atmosphere. As we have not accounted for the contribution of the thermal energy of the accretion flow (see Eq.\,\ref{therm_contr}) when we evaluated the local mass accretion rate (Eq.\,\ref{dotm}), the obtained additional emergent flux $F_{\rm a}$ differs from the value determined by the input parameter $\ell_{\rm a}$, namely $\ell_{\rm a}F_0/\ell$. Therefore, we correct the mass accretion rate using the correction factor $C$ determined by \begin{equation} \label{corr_fct} \dot m_{\rm c} = C \,\dot m = \frac{\ell_{\rm a}F _0}{\ell F_{\rm a}}\,\dot m. \end{equation} The ram pressure acceleration (\ref{gram}) as well as the energy generation rate (\ref{eq:Qplusfin}) are corrected using $\dot m_{\rm c}$ instead of $\dot m$. Then we solve the radiation transfer equation with Compton scattering taken into account \citep[see details in][]{SPW12} for the current model atmosphere. The equation is solved on the chosen photon energy grid covering all the range where the atmosphere radiates. In a self-consistent atmosphere the integral radiation flux at every depth \begin{equation} F(m)=\int\limits_0^\infty F_x(m)\,dx \end{equation} has to be equal to the values determined before known from the physics of the atmosphere. For instance, the integral flux has to be constant over the depth in an undisturbed atmosphere. In our case the integral total flux (a sum of the radiation flux and the flux due to thermal conductivity ($F(m)+F_{\rm c}(m)$) at every depth is determined by two terms: the intrinsic radiation flux and the flux generated by accretion at depths deeper than the considered depth. Therefore, the final radiation flux distribution over the depth is determined by the following equation \begin{equation} \label{int_energy} F(m) = F_0+ C\left(F_{\rm a} - \int\limits_0^m Q^+_{\rm a} (m')\,dm' \right) - F_{\rm c}(m). \end{equation} Here we also take into account the correction to the mass accretion rate. In fact, this flux distribution is the integral form of the energy balance equation. It has to be fulfilled together with the differential form of the energy balance equation (\ref{eq:econs}). \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig2.pdf} \caption{\label{fig2} The emergent energy spectra (top panel) and the temperature structures (bottom panel) for four low-luminosity ($\ell=0.001$) helium model atmospheres heated by $\alpha$-particles with the accretion luminosity $\ell_{\rm a}=0.05$ and parameters $\eta$=0.75 and $\chi=0.2$. The models correspond to different incoming angles $\Psi=0\degr, 30\degr, 60\degr$, and 85\degr. The emergent spectrum of the most inclined ($\Psi=85\degr$) particle flow is well fitted at photon energies higher than 5 keV with an exponential cutoff power-law model with photon index $\Gamma=2.45$ and cutoff energy $E_{\rm cut}=85$ keV (dashed curve). The blackbody spectrum of temperature $kT=1.1$ keV is also shown by the dotted curve. } \end{figure} \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig3.pdf} \caption{\label{fig3} The bolometric flux (top panel) and the heating rate (bottom panel) as functions of the column density for the models presented in Fig.\,\ref{fig2}. } \end{figure} Both forms of the energy balance equation are not satisfied after the first and many following iterations. The imbalance values for both forms at every column density are used for computation of the correction to the temperature at every depth \citep[see details in][]{SPW12}. All the computations are repeated for the new temperature distribution, and such iterations are repeated to satisfy the energy balance at every atmospheric point with the relative flux accuracy better than 1\%. \subsection{Comparison with previous works} The main difference between the model presented above and the models used by other authors is the inner boundary condition. We considered atmospheres with a given intrinsic radiative flux $F_0$, while \citet{DDS01} and \citet{Turolla.etal:94} assumed that it is absent, $F_0=0$. Formally, \citet{Zampieri.etal:95} introduced the intrinsic luminosity as a parameter, but in fact, they put the inner boundary slightly above the penetration depth of fast particles and did not give the value for the intrinsic luminosity. We believe it means that the intrinsic luminosity is small in comparison with the accretion luminosity. Therefore, we can compare the previously computed models only with our models at low intrinsic luminosity. \section{Results} \label{sec:results} The physical approach presented in Sect.~\ref{sec:method} was incorporated into the existing stellar atmosphere code described in \citet{SPW12}. Using this code we computed a set of models for non-magnetized NS atmospheres heated by accretion. The NS mass and radius were fixed at $M$=1.663\,$M_\odot$ and $R$=12\,km, corresponding to the gravitational redshift $1+z = 1.27$, the surface gravity $\log g = 14.3$, the free fall velocity $V_{\rm ff} = (2GM/R)^{1/2}=1.92\times 10^{10}$\,cm\,s$^{-1} = 0.64\,c$ and the virial temperature $T_{\rm vir} \approx \bar A\,\times7.48\times10^{11}$\,K $\approx \bar A\, 67$\, MeV at the NS surface. Here $\bar A$ is the average ion mass in units of the proton mass; $\bar A = 1$ for pure hydrogen matter, $\bar A = 4$ for pure helium matter, and $\bar A \approx 1.3$ for a solar H/He mix. The Eddington luminosity also depends on the chemical composition and can be determined once the hydrogen mass fraction $X$ is fixed, $L_{\rm Edd} \approx 3.8\times10^{38}\,(1+X)^{-1}$\,erg\,s$^{-1}$; $X= 0.7374$ for the solar H/He mixture. The varied parameters are the relative internal luminosity $\ell = L/L_{\rm Edd}$, the relative accretion luminosity $\ell_{\rm a} = L_{\rm a}/L_{\rm Edd}$, the angle between the bulk velocity vector of the accreted ions and the surface normal $\Psi$, the bulk velocity of the accreted ions with respect to the free fall velocity $\eta= V_0/V_{\rm ff}$, and the relative temperature of the accreted ions $\chi = T_{\rm i}/T_{\rm vir}$. \subsection{Atmospheres of low intrinsic luminosity} Let us first consider a model atmosphere with the low intrinsic luminosity, $\ell=0.001$, and with a relatively low accretion luminosity, $\ell_{\rm a} = 0.05$, which is, however, fifty times larger than the intrinsic luminosity. For simplicity, we { consider a} pure helium atmosphere heated by accreted $\alpha$-particles. As the fiducial set of parameters, we chose the temperature of the inflowing ions, $\chi=0.2$, and their bulk velocity $\eta=0.75$. As the first example, we consider models with { different} angles of the incoming flow $\Psi$= 0\degr, 30\degr, 60\degr, and 85\degr. The emergent spectra and the temperature structures for these four models are shown in Fig.\,\ref{fig2}. Almost all the energy is released at the column density of a few g\,cm$^{-2}$ (Fig.\,\ref{fig3}, bottom panel) and the total radiative flux grows rapidly at those depths (Fig.\,\ref{fig3}, top panel). The column density of the maximum energy release depends on the angle $\Psi$: the smaller the angle the deeper the energy release maximum. The atmosphere heated by the fast particles can be divided into an optically thick { inner part} ($m \geq 1 -10$\,g\,cm$^2$) and an optically thin outer part. The plasma temperature in the optically thick, almost isothermal part is slightly higher in comparison with that of the undisturbed atmosphere and the radiation flux is controlled by the temperature gradient. We can see that this part of the atmosphere is hotter for smaller angles $\Psi$. At small column densities, the atmosphere becomes optically thin and the energy generation here cannot be balanced with thermal radiation by plasma with $kT \approx kT_{\rm eff}$ and these layers are overheated. As a result their energy balance is determined by Compton scattering. \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig4.pdf} \caption{\label{fig4} The emergent specific intensity spectra of low-luminosity ($\ell=0.001$) helium atmosphere model heated by $\alpha$-particles with accretion luminosity $\ell_{\rm a}=0.05$ at three zenith angles of 27\fdg5 (dotted curve), 60\degr (solid curve), and 83\fdg5 (dashed curve). The parameters of the model are $\Psi=85\degr$, $\eta=0.75$ and $\chi=0.2$. } \end{figure} \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig5.pdf} \caption{\label{fig5} The relative ram pressure acceleration (top panel) and the relative ram pressure (bottom panel) as functions of the column density for the models presented in Fig.\,\ref{fig2}. } \end{figure} The heating rate of the upper atmospheric layers by the accreted particles increases with increasing angle $\Psi$. Therefore, models with the larger angle $\Psi$ have higher temperatures of the upper layers and they transit to overheated states at larger $m$. The upper layers of the atmosphere with $\Psi=85\degr$ are heated up to 10$^9$\,K, and the emergent spectrum is close to the Comptonized spectrum of a hot electron slab with Thomson { optical} depth of about unity. The emergent flux can be fitted by a power law with exponential cutoff, $F_E \propto E^{ -(\Gamma-1)}\exp(-E/E_{\rm cut})$, at photon energies larger than 5 keV (Fig.\,\ref{fig2}, top panel). The photon energy cutoff $E_{\rm cut}= 85$\,keV { is} approximately equal to the surface temperatures $kT$. On the other hand, the blackbody component with a temperature close to the temperature of the heated optically thick part of the atmosphere dominates the spectra of the models with small $\Psi$, and the optically thin layers add some high energy tails to the spectra. The spectrum of the model with $\Psi=60\degr$ has some intermediate shape with a clear blackbody component and a significant hard tail. Such division of the emergent spectra into two components is obvious in the low-luminosity models computed by \citet{AW73} and \citet{DDS01}. The temperature structure of these models as well as of those computed by \citet{Zampieri.etal:95} show an almost isothermal inner heated slab and the overheated Compton-cooled upper layers with surface temperatures between 10$^8$ and 10$^9$\,K. We note also, that the emergent spectra have significant excess at low photon energies in comparison with the blackbody. The atmospheres are very opaque at low energies due to the free-free opacity and the emergent radiation at these energies therefore forms in the overheated upper layers with the escaping monochromatic fluxes close to the blackbody flux with temperatures of those layer. This effect was mentioned by \citet{DDS01} as the ``inverse photosphere effect''. The angular distribution of the emergent spectra is also very unusual for stellar spectra (see Fig.\,\ref{fig4}). The normal limb darkening at the energies below 10 keV alternates with the limb brightening at higher energies, as it was suggested earlier by \citet{PG03} for the accreting millisecond pulsars. If the bulk velocity vector of the inflowing particles is highly inclined to the atmosphere normal, their contribution to the ram pressure gradient and to the ram pressure itself is small in comparison with that for the particle inflowing along the normal (see Fig.\,\ref{fig5}). \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig6.pdf} \caption{\label{fig6} The relative heat conduction flux (top panel) and the heat conduction flux derivative (bottom panel) as functions of the column density for the models presented in Fig.\,\ref{fig2}. } \end{figure} We took into account the thermal conductivity flux in the models, but it is not significant. The relative heat flux does not exceed a few tenth of percent in comparison with the intrinsic radiative flux even for the atmosphere with the hottest upper layers (see Fig.\,\ref{fig6}, top panel). The contribution of the heat conduction flux derivative into the differential form of the energy conservation law (see Eqs.\,\ref{eq:econs}, \ref{Qc}, \ref{allQ}) is also insignificant (see bottom panel of Fig.\,\ref{fig6}). However, the energy generation rate by accretion in the upper layers is small and comparable with the corresponding rate provided by conduction (compare bottom panel of Fig.\,\ref{fig6} to that of Fig.\,\ref{fig3}). In spite of the fact that the atmosphere is nearly isothermal, the heat flux by conduction becomes here significant, because of the strong temperature dependence (see Eqs. (\ref{eq:fluxc}) and (\ref{eq:kappac})). In this case, small numerical fluctuations in temperature of random signs lead to large derivatives of the conduction flux, comparable to the accretion heating. This leads to numerical and, possibly, physical instability of the upper layers where $m < 10^{-4}$\,g\,cm$^{-2}$. We suppressed this instability in our computations, but it has to be studied in future investigations. \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig7.pdf} \caption{\label{fig7} The atmosphere density dependence on the geometrical height for the models presented in Fig.\,\ref{fig2}. } \end{figure} \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig8.pdf} \caption{\label{fig8} The emergent energy spectra (top panel) and the temperature structures (bottom panel) of four low luminosity ($\ell=0.001$) helium model atmospheres heated by $\alpha$-particles with luminosity $\ell_{\rm a}=0.05$ and parameters $\eta$=0.25 and $\Psi=60\degr$. The presented models have different temperature parameter $\chi=$0.1, 0.2, 0.5, and 0.7. The fit to the spectrum above 5 keV with an exponential cutoff power law with $\Gamma=2.15$, $E_{\rm cut}=85$ keV is shown for $\chi=$0.1. The dotted curve shows the blackbody with temperature $kT=1$ keV. } \end{figure} Despite the high temperatures of the upper layers, the computed atmospheres are geometrically thin, as it was mentioned by other authors before \citep[see, e.g.][]{Turolla.etal:94}, with a thickness of a few tens of meters at most (see Fig.\,\ref{fig7}). It is not surprising because the highest model temperature ($\approx 10^9$\,K) is significantly lower than the virial temperature for the protons. However, the physical picture can potentially change if the electron-positron pair production is taken into account \citep{Zane.etal:98}. The virial temperature for the electron-positron pairs is close to $10^9$\,K, therefore, we can expect an outflow of pairs at some model parameters. The effects of pairs on the atmosphere models will be considered in a separate paper. \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig9.pdf} \caption{\label{fig9} The emergent spectrum (top panel) and the temperature structure (bottom panel) of the fiducial model (with $\eta=0.75$) in comparison with those of the models with smaller bulk velocities of the accreting particles ($\eta = 0.50$ and 0.25). The fit to the spectrum above 5 keV with an exponential cutoff power law with $\Gamma=2.25$, $E_{\rm cut}=80$ keV is shown for $\eta$ = 0.25. The dotted curve shows the blackbody with temperature $kT=1.1$ keV. } \end{figure} \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig10.pdf} \caption{\label{fig10} The emergent spectra (top panel) and the temperature structures (bottom panel) of the models with different accretion luminosities ($\ell_{\rm a} = 0.01$, 0.03, 0.05, 0.1, 0.3, and 0.5). The fit to the spectrum above 15 keV with an exponential cutoff power law with $\Gamma=2.25$, $E_{\rm cut}=42$ keV is shown for $\ell_{\rm a}$ = 0.5. } \end{figure} \subsection{Accretion heated atmospheres with various input parameters} We have considered above how the physical properties of the heated atmospheres depend on the incoming angle of the accretion flow. We now concentrate on the influence of other parameters on the emergent spectrum and the temperature structure. We consider pure helium models with two intrinsic luminosities $\ell=0.001$ and $0.5$, having accretion luminosity $\ell_{\rm a}=0.05$, and other parameters $\Psi=60\degr$, $\eta=0.75$ and $\chi=0.2$ as in the fiducial model. We study then how variations in every input parameter affect the emergent spectrum and the temperature structure. The obtained results for the intrinsic luminosity $\ell=0.001$ are shown in Figs.\,\ref{fig8}--\ref{fig10}. Varying the temperature and the bulk velocity affects the temperature structures and the emergent spectra of the models in the qualitatively similar way as the inclination angle of the bulk velocity vector made (Figs.\,\ref{fig8} and \ref{fig9}). Such a similarity arises because fast particles penetrate into different atmospheric depths when we vary their temperature or the bulk velocity. And, therefore, the ratio between the energy, which is released in the optically thick, heated slab and in the surface overheated layer also changes. Indeed, for higher temperature, the fraction of the particles with high individual velocities increases as well. They penetrate into deeper layers, and the relative contribution of the optically thick heated layer also increases. It becomes hotter, whereas the temperature of the upper overheated layers decreases. The relative contributions of the blackbody and the Comptonized components also change accordingly (Fig.\,\ref{fig8}). In a similar way the particles with the larger bulk velocities penetrate deeper (Fig.\,\ref{fig9}) and heat the optically thick part of the atmosphere to higher temperatures. On the other hand, the accretion heating rate of the very surface layers is larger for the smaller bulk velocities. We note that the dependence of the accretion heated model atmospheres on the temperature of the fast particles was investigated before by \citet{DDS01}. They showed that fast protons of lower temperature heat the overheated upper layers to the higher temperatures, whereas the temperature of the isothermal inner slab is lower than for the corresponding case of high-temperature protons (see their Fig.\,3). As a result the emergent spectra of the models heated by low-temperature protons are harder. Our models (see Fig.\,\ref{fig8}) confirm these results. The models with varying mass accretion rate have identical dependence of the heating rate over the depth, with the normalizations directly proportional to $\dot m$. The depth of the transition to the overheated parts of the atmosphere and its temperature are determined by the accretion luminosity $\ell_{\rm a}$. Higher accretion luminosity leads to higher temperatures of the heated layers, both of the overheated upper layers and of the isothermal region, and to a smoother transition from the isothermal region to the overheated layers. The strength of the hard Comptonized component also depends on $\ell_{\rm a}$. At small accretion luminosities, the blackbody component dominates and the hard tail in the emergent spectra is relatively weak. At high accretion luminosities, $L_{\rm a} \gg L$, the emergent spectra are dominated by the hard Comptonized component. These results confirm those obtained before by \citet{AW73} and \citet{DDS01}. They demonstrated that a rise of the accretion luminosity leads to a harder emergent spectrum and a higher temperature of the overheated layers and the isothermal slabs. This fact is especially clear from Fig.\,4 in \citet{DDS01}. \begin{figure} \centering \includegraphics[angle=0,scale=0.95]{33581_fig11.pdf} \caption{\label{fig11} The emergent spectra (top panel) and the temperature structures (bottom panel) of the models with different intrinsic luminosities ($\ell = 0.5$, 0.1, and 0.001), but the same accretion luminosity $\ell_{\rm a}=0.05$. The corresponding models for the undisturbed atmosphere are shown by the dashed curves. } \end{figure} The influence of the accretion heating decreases when the intrinsic stellar luminosity increases (Fig.\,\ref{fig11}). The spectrum of the model with the lowest intrinsic luminosity $\ell=0.001$ is completely determined by the heated part of the atmosphere whereas the spectrum of the model with the highest intrinsic luminosity $\ell=0.5$ differs from the spectrum of the undisturbed model very little. We also investigated the influence of the parameters for the case with the high intrinsic luminosity $\ell=0.5$. The qualitative dependences for the temperature structures are the same as they were described for the models with the low intrinsic luminosity $\ell=0.001$. However, the spectra are less sensitive to the variations of the parameters (see Fig.\,\ref{fig12}). \begin{figure} \centering \includegraphics[angle=0,scale=0.95]{33581_fig12.pdf} \caption{\label{fig12} Same as Fig.~\ref{fig9} but for higher intrinsic luminosity $\ell = 0.5$. At the bottom panel, the curves are labeled with the corresponding values of parameter $\eta$. The spectrum and the temperature structure of the undisturbed model are also shown by the dashed curves. } \end{figure} \subsection{Atmospheres with the solar composition} The accreting matter in LMXBs has helium rich composition only in the ultracompact systems (for instance, in 4U\,1820$-$30). Most of the systems have solar chemical composition of the accreting matter. Therefore, we have to consider how a change in the chemical composition affects the results. As can be seen from Eq.\,(\ref{dvdz}), protons and $\alpha$-particles decelerate the same way \citep{BSW92}, because the velocity derivative depends on the combination $Z^2/A$ only. Here we consider only these two types of fast particles and ignore the nuclei of heavy elements. The solar abundance model atmospheres heated by the solar mix of the protons and $\alpha$-particles are similar to the pure helium models (Fig.\,\ref{fig13}). \begin{figure} \centering \includegraphics[angle=0,scale=0.95]{33581_fig13.pdf} \caption{\label{fig13} The emergent spectra (top panel) and the temperature structures (bottom panel) of the models with solar chemical abundance and three intrinsic luminosities, $\ell = 0.5$, 0.1 and 0.001, but with the same parameters of the accreting particles ($\ell_{\rm a} = 0.05$, $\eta$=0.75, $\chi=0.2$, $\Psi$=60\degr). The spectrum and the temperature structure of the undisturbed models are also shown by the dashed curves. } \end{figure} \begin{figure} \centering \includegraphics[angle=0,scale=1.0]{33581_fig14.pdf} \caption{\label{fig14} Magnification of Fig.\,\ref{fig13} but for one intrinsic luminosity $\ell = 0.1$ only. The { formation} depths of the photons with energies of 8 and 10 keV { are indicated} by thin vertical lines for the heated and the undisturbed atmospheres. } \end{figure} However, there is some qualitative difference in the emergent spectra. The spectra of the low-luminosity undisturbed model atmospheres show absorption edges. The photoionisation edge of hydrogen-like iron is the most prominent among them (see model spectra with $\ell=0.001$ and 0.1 in Fig.\,\ref{fig13}). The opacity at photon energies above the photoionisation threshold is larger than that below the threshold. Therefore photons above the threshold escape from smaller column densities, where the temperature is lower. This is the reason why absorption edges exist. In the heated atmospheres, iron is more ionized and the jump in the opacity across the photoionisation threshold is smaller. Furthermore, the atmosphere is nearly isothermal in the region where the photons around the edge are formed (see bottom panel of Fig.\,\ref{fig14}). As a result, the spectra of the accretion-heated atmospheres are almost featureless (see top panel of Fig.\,\ref{fig14}). \begin{figure} \centering \includegraphics[angle=0,scale=1.]{33581_fig15a.pdf} \includegraphics[angle=0,scale=1.]{33581_fig15b.pdf} \caption{\label{fig15} The residual spectra (solid curves) of the heated model atmospheres with parameters $\ell=0.1, \ell_{\rm a}=0.05$, $\chi=0.2$, $\eta=0.75$, and $\Psi=60\degr$ for two chemical compositions, pure helium (top panel) and solar abundance (bottom panel). The spectra of undisturbed atmospheres are shown by dashed curves. The best-fit diluted blackbody spectra to the residual spectra are shown by the dotted curves, and the blackbodies of the effective temperatures are shown by the pink dash-dotted curves. } \end{figure} \subsection{Application to X-ray bursting neutron stars} Often the persistent spectra of X-ray bursting NSs are subtracted from the spectra detected during X-ray bursts for obtaining ``pure'' burst spectra \citep[see, however, ][]{Worpel13,Worpel15,Degenaar16,Kajava17_4U1728}. These spectra are well fitted \citep{Galloway08} with a blackbody \begin{equation} \label{fit_obs} f_{E'} \approx K \pi B_{E'}(T_{\rm BB}), \end{equation} where the normalization $K$ and the color temperature $T_{\rm BB}$ are the fitting parameters. On the other hand, the observed flux is determined by the model atmosphere flux $F_{E}(T_{\rm eff})$ \begin{equation} f_{E'} = \frac{F_{E}(T_{\rm eff})}{(1+z)^3}\frac{R^2(1+z)^2}{D^2}, \end{equation} where $D$ is the distance to the source, and $z$ is the gravitational redshift, \begin{equation} \label{eq:redshift_def} 1+z=(1-R_{\rm S}/R)^{-1/2}. \end{equation} Here $R_{\rm S} = 2GM/c^2$ is the Schwarzschild radius. We note also that $E=E'(1+z)$. The model spectra of hot NS atmospheres are close to diluted blackbodies because of the effective interaction between plasma and radiation by Compton scattering \citep{London86,Lapidusetal:86}. They can be fitted as \begin{equation} \label{fit_mod} F_{E} \approx w \pi B_{E} (f_{\rm c} T_{\rm eff}) \end{equation} with two fitting parameters, the color correction factor $f_{\rm c}$ and the dilution factor $w\approx f_{\rm c}^{-4}$. Both fitting parameters depend on the relative luminosity of the NS $\ell=L/L_{\rm Edd}$. Therefore, the observed spectrum will be defined as follows \begin{equation} f_{E'} \approx w \pi \frac{B_{E}(f_{\rm c} T_{\rm eff})}{(1+z)^3}\frac{R^2(1+z)^2}{D^2} \end{equation} or \begin{equation} \label{fit_tot} f_{E'} \approx w\pi B_{E'}\left[f_{\rm c} T_{\rm eff}(1+z)^{-1}\right]\ \frac{R^2(1+z)^2}{D^2}. \end{equation} Now we can determine the parameters $K$ and $T_{\rm BB}$ from comparison of Eqs.~(\ref{fit_obs}) and (\ref{fit_tot}): \begin{equation} K \approx w \frac{R^2(1+z)^2}{D^2}, \end{equation} and \begin{equation} T_{\rm BB} = f_{\rm c} T_{\rm eff}(1+z)^{-1}. \end{equation} It is clear that the observed normalization $K$ can change with the observed bolometric flux at the cooling burst phases only because of the changes in the dilution factor $w$. Therefore, $K$ has to change in a similar fashion as the dilution factor $w$ varies with the relative luminosity $\ell$. If we account for deviation of the bolometric flux from the observed blackbody flux $F_{\rm BB}$, the observed relation $K-F_{\rm BB}$ should be fitted with the theoretical curve $w - wf_{\rm c}^4 \ell$. Here $(wf_{\rm c}^4)^{-1}$ is the bolometric correction, as was shown by \citet{Suleimanov.etal:17}. From such fitting two parameters, the observed Eddington flux $F_{\rm Edd,\infty}$ and the NS observed solid angle $(R(1+z)/D)^2$ can be found, and NS mass and radius can be limited. This approach is known as the cooling tail method, see details in \citet{SPW11}, \citet{Poutanen.etal:14}, and \citet{Suleimanov.etal:17}. This method would be correct if a passively cooling NS were a correct model for the evolution of the burst spectra in the cooling phase. Indeed, the normalization of the spectra of bursts taking place during the hard persistent states evolve according to this model at a relatively high luminosity $\ell > 0.2-0.7$. This allowed us to obtain constraints on the NS masses and radii \citep{SPRW11,Poutanen.etal:14,Nattila.etal:16,Suleimanov.etal:17}. \begin{figure} \centering \includegraphics[angle=0,scale=1.]{33581_fig16.pdf} \caption{\label{fig16} The residual spectra (solid curves) of the heated helium atmosphere model with parameters $\ell=0.5, \ell_{\rm a}=0.05$, $\chi=0.2$, and $\Psi=60\degr$ for three different values of $\eta=$ 0.75, 0.50, and 0.25 (see Fig.\,\ref{fig12}). The spectrum of an undisturbed atmosphere is shown by the blue dashed curve and the blackbody of the effective temperature is shown by the pink dash-dotted curve.} \end{figure} \begin{figure} \centering \includegraphics[angle=0,scale=1.]{33581_fig17.pdf} \caption{\label{fig17} Color correction (top panel) and dilution (bottom panel) factors as functions of the corrected relative luminosity. They are computed using residual spectra of the heated helium model atmospheres for three accretion rates, $\ell_{\rm a}=$0.05 (dark blue), 0.03 (red), and 0.01 (light blue). Other parameters are $\chi=0.2$, $\eta=0.75$, and $\Psi=60\degr$. The corresponding factors computed using spectra of undisturbed atmospheres are also shown by black curves.} \end{figure} \begin{figure} \centering \includegraphics[angle=0,scale=1.]{33581_fig18.pdf} \caption{\label{fig18} The same as in Fig.\,\ref{fig17}, but for atmospheres of solar composition. Here the accretion flow temperature parameter is $\chi=0.3$.} \end{figure} However, the observed dependences $K - F_{\rm BB}$ deviate from the model curves $w - wf_{\rm c}^4 \ell$ at low $\ell$. The amplitude of the deviations depends on the relative persistent luminosity of the system before the X-ray burst. Compare, for instance, small deviations of the model curves from the observed ones for the systems with low persistent emission, $L_{\rm per} \approx 0.01 L_{\rm Edd}$ \citep{Nattila.etal:16}, and the large deviations for the system 4U\,1820$-$30 \citep{Suleimanov.etal:17} with a relatively high persistent luminosity, $L_{\rm per} \approx 0.04-0.07 L_{\rm Edd}$. We suggest that these deviations are determined by additional heating of the NS atmospheres by the accretion flow. Let us evaluate the effect of such a heating on the theoretical dependences $w - wf_{\rm c}^4 \ell$ to study this hypothesis. To obtain the model spectra we use the same approach as used for the analysis of the observed spectra of X-ray bursting NSs \citep[see, e.g.][]{Galloway08}. We assume that the spectrum of the heated model atmosphere with the lowest intrinsic luminosity $\ell=0.001$ represents the spectrum of the persistent emission from an accreting NS. We then subtract this spectrum from the spectra corresponding to the higher intrinsic luminosities to mimic pure burst model spectra. The examples of such residual spectra are presented in Fig.\,\ref{fig15}. The residual spectra can be fitted by diluted blackbodies even better than the spectra of undisturbed model atmospheres and their color temperatures are higher than the corresponding color temperatures of the spectra of undisturbed model atmospheres. We also note, that the absorption edge clearly seen in the model spectrum of the solar-abundance undisturbed atmosphere completely disappears in the residual spectrum (Fig.\,\ref{fig15}, bottom panel). In the first approximation the reduced spectra are slightly dependent on the parameters of the accretion flow (Fig.\,\ref{fig16}). Using the grid of residual model spectra in the intrinsic luminosity range $\ell$ from 0.001 to 0.5 we computed the color correction and dilution factors for pure He and solar abundance atmospheres (see Figs.\,\ref{fig17} and \ref{fig18}). { We} do not consider luminosities above $\ell=0.5$, because at those luminosities the radiation pressure should affect significantly the dynamics of the accreted fast particles. It is also possible that during X-ray bursts the accretion luminosity smoothly increases when the burst luminosity decreases. We leave the models with high intrinsic luminosities for future investigations. We considered three values of the relative accretion luminosities, $\ell_{\rm a}$=0.05, 0.03 and 0.01. We took the accretion flow parameters to be $\eta=0.75$, $\Psi=60\degr$, and $\chi=0.2$ for pure helium models, and $\chi=0.3$ for the solar abundance models. The residual spectra were fitted with the diluted blackbody spectra in the blue-shifted observational energy range of the {\it RXTE} observatory, $(3-20)(1+z)$ keV. Here the gravitational redshift is $1+z=1.27$ for the accepted NS parameters and $\log g = 14.3$, see Sect.\,\ref{sec:results}. According to expectations, the color correction factors are larger for the heated model atmospheres, and their values depend on the mass accretion rate. We note that the prominent dip at $\ell \approx 0.1$ in the theoretical $f_{\rm c} - wf_{\rm c}^4 \ell$ curve computed for the undisturbed solar-abundance atmospheres becomes weaker for slightly heated model atmospheres ($\ell_{\rm a}=0.01$) and completely disappears in the curves computed for higher accretion luminosities. \begin{figure} \centering \includegraphics[angle=0,scale=0.7]{33581_fig19a.pdf} \includegraphics[angle=0,scale=0.7]{33581_fig19b.pdf} \caption{\label{fig19} Comparison of the observed dependences $K - F_{\rm BB}$ obtained for selected X-ray bursts of 4U\,1820$-$30 \citep[see][]{Sul.etal:17} with the model curves $w - wf_{\rm c}^4 \ell$ computed for undisturbed (blue curves) and heated (red curves) pure helium atmospheres. The axes of the fluxes are shown in linear (top panel) and logarithmic (bottom panel) scales. The fitting parameters $F_{\rm Edd, \infty}= 0.6\times 10^{-7}$~erg\,s$^{-1}$\,cm$^{-2}$ and $\Omega=500$\,(km/10\,kpc)$^{-2}$ are the same for both model curves. } \end{figure} In the previous work \citep{Sul.etal:17} we considered X-ray bursts occurring in a hard state of the ultracompact system 4U\,1820$-$30 which likely accretes helium from a white dwarf companion. We applied the direct cooling tail method of \citet{Suleimanov.etal:17} to obtain constraints on the NS mass and radius. The persistent luminosities before the considered bursts were high enough (0.047--0.063 $L_{\rm Edd}$) and the observed dependences $K - F_{\rm BB}$ deviated from the model curves at $\ell < 0.6$ (see Fig.\,\ref{fig19}). Therefore, we analyzed only the high-luminosity part of the observed data. We suggested that deviations of the theoretical curve from the data are likely caused by accretion during the later stages of the cooling tail. Taking the accretion luminosity of 5\% of the Eddington value ($\ell_{\rm a}=0.05$), the model curves $w - wf_{\rm c}^4 \ell$ for the heated pure helium atmospheres shift down sufficiently to pass through the data points at $\ell < 0.5$. At the relative luminosities higher than $\ell \approx$\,0.3, i.e. $F_{\rm BB} \approx$\,0.2$\times 10^{-7}$\, erg\,s$^{-1}$\,cm$^{-2}$, the data lie slightly above the model curve. We suggest that when the burst luminosity drops from $\ell \approx0.6$ to $\approx0.3$, the accretion rate increases causing a smooth shift of the blackbody normalization $K$ from a theoretical curve with no accretion $\ell_{\rm a}=0$ to a curve corresponding to $\ell_{\rm a}=0.05$. There are a few possible reasons why the accretion restarts again after some time. First, the inner parts of the accretion flow can be destroyed during the photospheric radius expansion phase. The typical time of the photosphere to settle down to the NS surface can be much shorter than the viscous time for the inner accretion flow. Therefore, the accretion restarts again gradually with some time gap. Second, is the influence of radiation pressure. The radiation field has two effects on the particle dynamics near the NS \citep{ML93}. At high luminosity, the direct radial radiation force may reduce the radial velocity decreasing mass accretion rate, while at low luminosity the radial velocity may increase as a result of the angular momentum loss due to the Poynting-Robertson drag. Finally, the burst radiation may cool the accretion flow making it thinner. As a result, only a relatively small part of the NS surface is affected by accretion. It may well be possible that all three reasons play a role. \section{Summary} In this paper we presented a computational method to construct NS { model} atmospheres heated by accreted particles. Our results confirm previous findings \citep[e.g.][]{AW73, Zampieri.etal:95, DDS01} that fast heavy particles (protons, $\alpha$-particles, or their mix) penetrate down to some depth in the atmosphere and release most of their kinetic energy in a relatively narrow layer due to Coulomb interaction with electrons. The heating by accretion is balanced by the cooling due to mainly free-free emission and Comptonization. The relatively dense optically thick region, where the cooling is dominated by free-free emission, is only slightly hotter than the corresponding layer of an undisturbed atmosphere. It forms a quasi-isothermal transition region between the inner atmosphere unaffected by accretion heating and the hot ($\sim 10^8 - 10^9$\,K) rarefied upper layer. The upper hot layers cool mainly by Compton scattering. The width of the transition region and the temperature of the upper layer depend mainly on the accretion luminosity $L_{\rm a}$ and the intrinsic NS luminosity $L$. The emergent spectrum of an accretion-heated NS atmosphere is wider than the spectrum of the corresponding undisturbed atmosphere and can be roughly represented as a sum of two components: a blackbody-like radiation from the transition region and Comptonized (cutoff power-law-like) spectrum of the hot upper layers. The relative contribution of the components is determined by the ratio of the intrinsic luminosity $L$ to the accretion luminosity $L_{\rm a}$. If $L_{\rm a} \gg L$, the total spectrum is dominated by the Comptonized spectrum of the upper, hot rarefied layers. This kind of spectra are similar to the observed spectra of LMXBs in their low hard spectral states, as mentioned by \citet{DDS01}, and their slope depends on the input parameters of the accreted particles: velocity, temperature, and the penetration angle. We note, however, that all computed spectra have photon indexes $\Gamma > 2$. The observed spectra of LMXBs in their low hard spectral states often have harder spectra with $\Gamma < 2$. It means that the contribution of the accretion flow emission to the total observed spectra may not be negligible. In the opposite case, when $L_{\rm a} \ll L$, the total spectra are very similar to the spectra of the undisturbed models with harder Wien tails and increased flux at low photon energies. In that case, the final spectra depend very little on the properties of accreted particles. The atmospheres heated by material of solar abundance have an important qualitative feature in comparison to pure helium atmospheres heated by $\alpha$-particles only. The spectra of the relatively low-luminosity ($L \ll L_{\rm Edd}$) undisturbed model atmospheres show significant absorption edges due to photoionisation of hydrogen-like iron. These edges disappear in the spectra of the accretion-heated atmospheres because of a significant change in the temperature structure. We also investigated the influence of the accretion heating on the model curves $w - wf_{\rm c}^4 \ell$ and $f_{\rm c} - wf_{\rm c}^4 \ell$, which are used in the (direct) cooling tail method. As it was expected the color-correction factors $f_{\rm c}$ are larger for the heated atmospheres in comparison with the undisturbed atmospheres, and the dilution factors $w$ are smaller. The model curve computed for heated helium atmospheres (with $\ell_{\rm a}=0.05$) is well fitted to the low-luminosity part of the observed data $K-F_{\rm BB}$ obtained for X-ray bursts taken place during the hard state of the helium-accreting system 4U\,1820$-$30 \citep[see][]{Sul.etal:17}. The model curves $f_{\rm c} - wf_{\rm c}^4 \ell$ computed for the heated solar-abundance atmospheres do not have a dip at $\ell \approx 0.1$, which is clearly seen in the model curves computed for the undisturbed solar-abundance atmospheres. This fact may have important implications for interpretation of the X-ray data on bursting NSs that accrete gas of solar abundance, for example, the Clocked Burster GS\,1826$-$24 \citep[see discussion in][]{ZCG12}. We plan to apply the method described here for interpretation of the spectral evolution of that and other bursters in a follow-up paper. \begin{acknowledgements} The authors acknowledge A.\,M. Beloborodov for useful discussions and an anonymous referee for the very insightful comments. This research has been supported by the grant 14.W03.31.0021 of the Ministry of Education and Science of the Russian Federation. V.F.S. also thanks Deutsche Forschungsgemeinschaft (DFG) for financial support (grant WE 1312/51-1). We thank the German Academic Exchange Service (DAAD, project 57405000) and the Academy of Finland (project 317552) for travel grants. This work benefited from discussions at the BERN18 Workshop supported by the National Science Foundation under Grant No. PHY-1430152 (JINA Center for the Evolution of the Elements). \end{acknowledgements}
\section{Introduction} Present acceleration of the universe is confirmed by many astrophysical observations, such as Supernova type Ia (SN Ia) \cite{Perlmutter:1997zf, Riess:1998cb, Astier:2005qq}, Cosmic Microwave Background (CMB) Anisotropies \cite{Ade:2015lrj}, large-scale structure surveys, and X-ray luminosities from galaxy clusters \cite{Rapetti:2005a}. The dark energy is believed to be responsible for the acceleration. Dark energy could be in the form of dynamical fields, therefore many scalar field models are proposed in order to explain the present accelerated expansion (see e.g. \cite{Copeland:2006a} and references therein) as well as inflation in the early universe \cite{Guth, RP1988}. Modifications of the gravitational theory can be performed by changing geometrical sector in the Einstein-Hilbert action of which the acceleration can be attained in many ways at both early and late times \cite{Carroll2004, SCVF}. Coupling between scalar sector and geometry can be found in classes of scalar-tensor theories \cite{maeda}. These contain non-minimal coupling (NMC) term between the Ricci scalar and a scalar field (see e.g. \cite{Amendola1993}). The NMC model can be extended to coupling of the Einstein tensor to derivative of the scalar field dubbed a non-minimal derivative coupling (NMDC) theory \cite{Capozziello:1999xt, Granda:2010hb, Sushkov:2009, Saridakis:2010mf, Germani:2010gm, Sushkov:2012, Tsujikawa:2012mk, Sadjadi:2010bz, Gumjudpai:2015vio, Gumjudpai:2016frh}. The NMC and NMDC are found as a subclass of Horndeski’s theory \cite{Horn} which is the most generalized case of the action with at most second-order derivative of the metric and of the scalar field. Metric NMDC theory allows inflation by enhanching friction even in steep potentials with theoretically natural models parameters and helps supressing the tensor-to-scalar ratio \cite{Tsujikawa:2012mk}. A version of NMDC theory as proposed by \cite{Sushkov:2012} was investigated in metric formalism which regards the metric as a dynamical field. Alternative ideas lies on symmetrical properties of the manifold space. Riemannian manifold possesses isometry property and the metrical field is consistent with it. A space that possesses the diffeomorphism symmetry, allows connection and the metric to be separated dynamical fields so that these fields are varied independently. This approach is called Palatini formalism which gives different equations of motion from the metric approach unless considering GR \cite{Olmo:2011uz}. The Palatini NMDC action is given by \begin{equation} \tilde{S}[g, \Gamma, \phi] = \frac{M_{\rm P}^2 c^4}{2} \int {\rm d}^4 x \sqrt{-g} \left[\tilde{R}-\left(\varepsilon g_{\mu\nu}+\kappa\tilde{G}_{\mu\nu}\right)\phi^{,\mu}\phi^{,\nu} - 2V \right]\,, \label{PalatiniAct} \end{equation} where $c \equiv 1$, $\tilde{G}_{\mu\nu}(\Gamma) = \tilde{R}_{\mu\nu}(\Gamma)-\frac{1}{2} g_{\mu\nu} \tilde{R}(\Gamma)$; $\tilde{R}(\Gamma) = g^{\mu\nu}\tilde{R}_{\mu\nu}(\Gamma)$ and $\tilde{R}_{\mu\nu}(\Gamma) = R^{\lambda}_{\mu\lambda\nu}(\Gamma) = \partial_{\lambda}\Gamma^{\lambda}_{\mu\nu}-\partial_{\nu}\Gamma^{\lambda}_{\mu\lambda} + \Gamma^{\lambda}_{\sigma\lambda}\Gamma^{\sigma}_{\mu\nu} - \Gamma^{\lambda}_{\sigma\nu}\Gamma^{\sigma}_{\mu\lambda}$ with detailed as referred in \cite{Gumjudpai:2016ioy}\footnote{A different version of Palatini NMDC was investigated before in \cite{palaNMDC}.}. The matter fields are negligible here. Previous works \cite{Gumjudpai:2016ioy, Saichaemchan:2017psl} showed that positive $\kappa$ results in superluminal graviton speed. Albeit the $V \propto \phi^4$ potential with $\kappa > 0$ could pass the CMB constraint \cite{Ade:2015lrj}, it is with only by large amount of fined-tuning. Moreover, the negative $\kappa$ case with $V \propto \phi^2$ fails the CMB constraint. Hence both $V \propto \phi^2 $ and $ V \propto \phi^4$ are not likely to be viable. With this reason, we consider $\kappa < 0$ and use $V = V_0 e^{-\lambda \phi / M_{\rm P}}$ instead of the power-law (chaotic) potential. \section{Equations of motion in the slow-roll regime} Giving the scenario of the NMDC gravities, it is interesting to view comparative graphical presentations of the dynamics. In doing such, we consider sets of the autonomous system in GR, metric NMDC and Palatini NMDC gravities in slow-roll regime so that the slow-roll approximations $0 \ll |\phi^2 | \ll 1; \ |\ddot{H}/H| \ll |\dot{H}| \ll |H^{2}|; \ |4\dot{H}\kappa| \ll 1,$ can be applied \cite{Gumjudpai:2016ioy}. \subsection{Metric NMDC Gravity} Considering scalar field as the only species in inflationary epoch, $\rho_{\rm tot} \equiv \rho_{\phi} = \varepsilon\dot{\phi}^2/2 + V ; \ p_{\rm tot} \equiv p_{\phi} = \varepsilon\dot{\phi}^2/2 - V $. Friedmann and the Klein-Gordon equations are \cite{Gumjudpai:2015vio} \begin{equation} H^2 = \frac{1}{3 M_{\rm P}^2}\left[ \frac{\dot{\phi}^2}{2}\left(\varepsilon - 9 \kappa H^2 \right) + V(\phi) \right]\,, \label{FRMetric} \end{equation} \begin{equation} \ddot{\phi}\left(\varepsilon - 3 \kappa H^2 \right) + 3 H \dot{\phi}\left( \varepsilon - 3 \kappa H^2 \right) + V_{\phi} \simeq 0\,. \label{KGMetric} \end{equation} One can set an autonomous system: \begin{eqnarray} \dot{\phi} = \psi \,,\;\;\; \dot{\psi} \simeq \frac{-V_{\phi} - 3 H \psi (\varepsilon - 3 \kappa H^2) }{\varepsilon - 3 \kappa H^2} \,,\;\;\; \dot{H} \simeq \frac{V_{\phi} \psi }{6 M_{\rm_P}^2 H}\,. \label{autoMetric} \end{eqnarray} \subsection{Palatini NMDC Gravity} From the Palatini action (\ref{PalatiniAct}), the Friedmann and the Klein-Gordon equations are given by \begin{equation} H^2 \simeq \frac{1}{3 M_{\rm P}^2}\left[ \frac{1}{2}\varepsilon\dot{\phi}^2 + V(\phi) \right]\,, \label{FRPala} \end{equation} \begin{equation} \ddot{\phi}\left[ \varepsilon - {\frac{15}{2} \kappa}H^2 \right] + 3H \dot{\phi} \varepsilon + V_{\phi} \; \simeq \; 0\,. \label{KGPala} \end{equation} An autonomous system can be derived as follows : \begin{eqnarray} \dot{\phi} = \psi\,,\;\;\; \dot{\psi} \simeq \frac{-V_{\phi} - 3 H \psi \varepsilon }{\varepsilon - (15/2) \kappa H^2}\,,\;\;\; \dot{H} \simeq \frac{V_{\phi} \psi }{6 M_{\rm_P}^2 H}\,. \label{autoPala} \end{eqnarray} \section{Acceleration condition for exponential potential} Exponential potential has similar motivation as the NMDC models, i.e. it is motivated by low-energy effective theories of quantum gravities \cite{Copeland:1997et}. Therefore in this study, we consider exponential potential, $ V = V_{0}\exp(-\lambda\phi/M_{\rm P})\,. $ Acceleration condition is obtained by taking $\ddot{a}/a \equiv \dot{H} + H^2 > 0$. \subsection{Metric NMDC Gravity} In the metric case, we use approximation $H \approx \sqrt{V}/\left(\sqrt{3}M_{\rm P}\right)$ and $|\kappa| \ll |M_{\rm P}^2/V|$ to obtain the acceleration condition, \begin{eqnarray} \dot{\phi}^2 \; < \; V_{0}\exp\left(-\frac{\lambda\phi}{M_{\rm P}}\right)\left\{1-\frac{\kappa \varepsilon\lambda^2 V_{0} \exp\left(-\frac{\lambda\phi}{M_{\rm P}}\right)}{M_{\rm P}^2\left[\varepsilon - \frac{\kappa}{M_{\rm P}^2}V_{0}\exp\left(-\frac{\lambda\phi}{M_{\rm P}}\right)\right]}\right\}\left[\varepsilon-3\kappa\frac{V_{0}\exp\left(-\frac{\lambda\phi}{M_{\rm P}}\right)}{M_{\rm P}^2}\right]^{-1}\,. \label{accelmetric} \end{eqnarray} \subsection{Palatini NMDC Gravity} Considering binomial approximation for $|\kappa| \ll |M_{\rm P}^2 /V|$ and late time $\dot{\phi} \approx -M_{\rm P}V_{\phi}/\sqrt{3}\epsilon\sqrt{V}$, acceleration condition is given by \begin{equation} \varepsilon\dot{\phi}^2 \;< \; V_{0}\exp\left(-\frac{\lambda\phi}{M_{\rm P}}\right)\left\{ 1 + \frac{\kappa\lambda^4}{\varepsilon M_{\rm P}^2}V_{0}\exp\left(-\frac{\lambda\phi}{M_{\rm P}}\right)\left[ 1+\frac{15\varepsilon\kappa}{8M_{P}^2}V_{0}\exp\left(-\frac{\lambda\phi}{M_{\rm P}}\right)\right]\right\}\,. \label{accelPala} \end{equation} \section{Results} We plot the phase portraits of the 3-dimensional autonomous systems both of the metric (Eq.(\ref{autoMetric})) and the Palatini (Eq. (\ref{autoPala})) cases. The GR case is portraited by taking $\kappa = 0$. Fig. \ref{fig1} shows the phase portrait for the three cases and the acceleration region (as described by Eqs. (\ref{accelmetric}) and (\ref{accelPala})) are presented. Fig. \ref{fig2} shows evolution of $H$ as e-folding number $N$ grows in the three cases. \begin{figure}[h] \centering \includegraphics[width=41pc]{A_ThreeCaseExpoPortraitsEditDraft.eps}\vspace{0.5pc} \put(-420,0){(a)} \put(-260,0){(b)} \put(-100,0){(c)} \caption{\label{fig1}Phase portrait for an NMDC scalar field under exponential potential, with parameter $V_{0} = 1; \ \kappa = -0.5; \varepsilon = 1; \ M_{\rm P} = 1.0; \ \lambda = 1.0 $ for three cases: (a) GR (b) metric NMDC and (c) Palatini NMDC cases; red curves are trajectories from some chosen initial conditions. } \end{figure} \begin{figure}[h] \centering \includegraphics[width=26pc]{A_HubbleRate.eps}\vspace{0.5pc} \caption{\label{fig2} $H$ plotted over e-folding number $N$ in GR, metric NMDC and Palatini NMDC cases.} \end{figure} \section{Conclusion} We present phase portraits of non-minimal derivative coupling scalar field under exponential potential, $V = V_{0}\exp(-\lambda\phi/M_{\rm P})$ in metric and Palatini formalism. Previous works \cite{Gumjudpai:2016ioy, Saichaemchan:2017psl} showed difficulty of the theory to be viable with chaotic inflation potentials, motivating consideration of exponential potential with the negative $\kappa$ case of the theory. In the slow-rolling regime, Acceleration conditions are derived in three cases. As seen in Fig. \ref{fig1}, there is only one attractor in all cases. However, Palatini NMDC gives smaller acceleration region and restricts the attractor into that smaller region. It is seen from Fig. \ref{fig2} that Palatini NMDC effect suppresses expansion rate than that of the GR case while the metric NMDC effect enhances the expansion rate from that of the GR case. \section*{Acknowledgements} This work is supported by Naresuan University Research Grant-R2557C121. \section*{References}
\section{Introduction} \IEEEPARstart{P}{arkinson's} disease (PD) is the second most common neurodegenerative disease after Alzheimer's disease, largely associated with various forms of movement-related symptoms~\cite{Robertson1990}. As many as~60,000 new cases are diagnosed every year in North America~\cite{DeLau2006}, and according to a recent analysis from~\cite{Enders2017}, the prevalence of PD is estimated to be 217.22/100,000 in Germany. Typically, people with PD (PwP) show several characteristic movement deficits, such as brady-hypokinesia, rigidity, tremor, postural instability, and movement initiation disorder (``freezing'')~\cite{Hoehn1967,Fahn1995,Hughes1992}. Brady-hypokinesia is the most salient symptom and is characterized by slowness and reduction of movements~\cite{Berardelli2001}. Rigidity is a stiffening of the body parts~\cite{Hallett2003}. Tremor typically occurs as a rest tremor, and is defined as an involuntary rhythmical muscle contraction of 4-6~Hz frequency~\cite{DeuschlGuntherFietzek2003}, which is a common initial PD symptom~\cite{Hoehn1967}. As the aetiology of PD lies in dopamine deficiency due to the degeneration of substantia nigra, these PD symptoms are controlled primarily by dopaminergic treatments~\cite{Surmeier2017}. However, as a side effect, many patients may exhibit dyskinesia, characterized by involuntary muscle movements~\cite{Jankovic2005}. \\ PD exhibits symptom heterogeneity between patients, especially in the advanced stages of the disease~\cite{McColl2002}. In addition, the short-term influence of medication, and the dependency on a variety of internal and external factors leads to highly complex and variable displays of the PD symptoms. For these reasons, even for highly trained clinicians, there is considerable inter-rater and intra-rater variability in judging the severity of the cardinal symptoms~(e.g.,~\cite{Heldman2011,Post2005}), which compromises both diagnosis and monitoring of PD. Thus, frequent and objective clinical assessments are important for deriving a suitable health management plan (e.g., adapting drug dosage). Nevertheless, PD assessments in a patient's home environment are often impractical due to time and economic constraints. An alternative is self-disclosure by the patients in a diary which is reported on a regular basis throughout the day. However, the reliability of those diaries is often questionable as these reports are subjective and it requires substantial commitment by the patients~\cite{Antonini2011}. Therefore, we propose a supervised machine learning method for autonomously estimating and monitoring PD-specific movement abnormalities using a commercial wrist-worn wearable sensor to track the patients' motion. These wearable devices can be used to continuously monitor the movement of the users with minimum intrusion on their daily activities. In free living settings, however, tracked movements are often comprised of motor expressions of PD as well as unknown movements related to daily activities. Thus, the learning algorithm must be able to attend to the features of PD symptoms in the face of highly variable inputs.\\ In the present study, therefore, we estimate the severity of PD-specific movement abnormalities in the presence of arbitrary and unknown voluntary motions by learning the movement features including those in the time-frequency domain. Specifically, we use a multi-layered Gaussian process (GP) model, in which each of the hierarchically stacked GP models estimates severity of different PD-related movement abnormality classes, namely \emph{tremor} (bradykinetic or dyskinetic), non-tremulous \emph{bradykinesia} and non-tremulous \emph{dyskineasia}. \subsection{Related Work} Machine learning has been employed in many studies to model the relationships between movements of PwP and severity of PD~\cite{angeles_automated_2017, eskofier_recent_2016, ghassemi_combined_2016, cancela_comprehensive_2010, roy_resolving_2011}. Commonly, the movements are recorded using wearable sensors such as accelerometer, gyroscope, electromyography and video-based tracking devices. In the majority of studies (e.g.~\cite{eskofier_recent_2016, angeles_automated_2017, cancela_comprehensive_2010, zwartjes_ambulatory_2010}), wearable inertial measurement units (IMUs) are used with applications in remote home environments in mind, whereas marker-based motion tracking systems are often used in a controlled environment or when they provide a ground truth for other sensors~\cite{kubota_machine_2016, filippeschi_survey_2017}. Existing studies largely focus on one or two PD-specific behavior classes including tremor, bradykinesia, dyskinesia, and gait disturbance, where the presence of abnormality in these classes is estimated by machine learning~\cite{kubota_machine_2016}. As labeled training data is necessary for supervised machine learning, a movement disorder specialist commonly monitors the patients and labels clinical observations according to the Movement Disorder Society sponsored Unified PD Rating Scale (MDS-UPDRS) with which motor symptoms are assessed on a 5-level rating scale~\cite{Goetz2007,Goetz2008}. For instance, Eskofier et al.~\cite{eskofier_recent_2016} compare several supervised machine learning pipelines and a deep learning algorithm to detect bradykinesia. Several specific motor tasks of 10 patients with idiopathic PD were recorded using IMU sensors. Every task was rated by a movement disorder specialist according to the MDS-UPDRS rating scale. Using these data, a classification accuracy of up to 85\% was achieved with standard machine learning techniques such as support vector machine (SVM) while deep learning demonstrated 90\% accuracy in predicting the presence and absence of bradykinesia. Angeles et al.~\cite{angeles_automated_2017} were also able to classify PD symptoms such as kinetic tremor according to the MDS-UPDRS score given by clinicians with an accuracy of up to 87\% using simple tree, linear SVM and fine k-nearest neighbor (kNN) algorithms. An accuracy of up to 92\% was achieved in predicting bradykinesia using Fine kNN. As an alternative to wearable sensors, video-based methods have been used to investigate the PD motor symptoms. Butt et al.~\cite{butt_leap_2017, wahid_classification_2015}, for example, used the hand motion data collected using an RGB-D camera to distinguish PD patients from healthy individuals at an accuracy of up to 85\% using SVM. Alternatively, a semi-supervised classification algorithm based on k-means and self-organizing tree map clustering was applied in~\cite{Hssayeni2016}, obtaining accuracies in the range of 42-99\% for patients with different levels of dyskinesia severity. In a hybrid approach,~\cite{tzallas_perform:_2014} tailors a different set of classifiers including the hidden Markov model, decision tree, SVM, and random forest to estimate the tremor, dyskinesia, bradykinesia and freezing of gait, respectively. Using the IMU signals collected from four locations on the body and the patient's own diary rating as class labels, the authors predicted the severity of PD symptoms with above 70\% accuracy during short-term scripted activities. The experiments for modeling motor aspects of PD described so far took place in laboratory environments, where the patients performed scripted activities. Few examples are available on symptom modeling during free living in the literature. In~\cite{Hoff2004} binary classification of bradykinesia and tremor attained 60-71\% sensitivity using a receiver operating characteristic curve on single kinematic variables. In contrast, using a neural network with 23 kinematic variables from 6 IMU sensors, Keijsers et al.~\cite{Keijsers2006} achieved an average sensitivity and specificity of 97\% for binary classification. Supervised machine learning is used in~\cite{cancela_comprehensive_2010} to classify bradykinesia during free movement and daily living. The authors contrasted a set of classifiers such as SVN and k-means and reported 70\% to 86\% classification accuracy for predicting the bradykinesia severity. Existing studies largely focus on modeling PD symptoms either in a controlled environment and/or using a binary classification algorithms due to the limited PD data set and a highly variable display of PD symptoms. Thus, the estimation of the symptom severity has been challenging task, and previous works have not sufficiently explored the benefits of advanced machine learning techniques such as Gaussian mixture modeling and Gaussian process regression with which non-linear functions can be robustly approximated with relatively small datasets. \subsection{Contributions and Article Structure} Our contributions in improving severity estimation of behavioral abnormalities of PwP during unscripted daily activities are supported by two key methodological achievements: (1) identification of appropriate data features for our PD classes~(\ref{sec:feature}) and (2) the hierarchical structured machine learning models which handle each PD class~(\ref{sec:MGP}). We propose an approach to autonomously estimate severities in three classes of PD-related motor abnormalities (i.e., PD classes); namely tremor, and non-tremulous episodes of bradykinesia and dyskinesia. As the tremor motion is highly characteristic and easily differentiable from other motions, the model estimates the tremor presence and its severity in the first layer, based on the frequency ratio of the tremor motion versus voluntary actions. Subsequently, in the second layer, the remaining data are used to analyze the severity of bradykinesia and dyskinesia. For each of the three class estimates, we apply GP regression and prediction and thus obtain a multi-layer GP model. Our approach focuses on collections of unscripted motion data, thus the PD estimation can take place during unconstrained free living activities. We purposefully use a single commercially available wrist-worn low-cost wearable sensor to demonstrate robustness and applicability of our approach to real-life scenarios. The remainder of the paper is structured as follows. We first introduce our methods for data acquisition. Second, we present our modeling approach, consisting of feature identification, hierarchical symptom estimation and the application setup. Then, we present our experimental results. Finally, we discuss the results and conclude the paper. \section{Data Collection} In this section we describe how the patient data was collected, introducing the patient cohort of our study, the sensor device and the setting for data capture. Subsequently, the procedure of data acquisition is explained Thirty individuals who took part in the study were diagnosed with PD by a neurologist according to the UK Brain Bank Diagnostic Criteria~\cite{Gibb1989} at the Sch\"on Klinik M\"unchen Schwabing, Germany. The average age of the participants was 67$\mathbin{\mathpalette\@mypm\relax}$10, and 20 were male and 10 were female. The mean disease duration was 11$\mathbin{\mathpalette\@mypm\relax}$5 years. The median of the patients' disease progress according to the Hoehn and Yahr scale~\cite{Hoehn1967} is 3.5 with an interquartile range of 1. The recruitment of the patient cohort and the data acquisition were performed at the Sch\"on Klinik M\"unchen Schwabing (Munich, Germany). This study was approved by the ethical board of the Technical University of Munich~(Ref. No. 234/16S). In order to learn and predict the display of movement abnormalities using GP, the movements of the participants were recorded, together with corresponding PD annotations including their class and severity. The linear acceleration and angular velocity of the wrist were measured using the Microsoft Band~2 (Microsoft). Inside the band is a 6-axis gyroscope/accelerometer module~(LSM6D series by STMicroelectronics) and a bluetooth communication module~(Bluetooth~4.0) for transmitting the data to a peripheral device. The accelerometer registers motion up to $\mathbin{\mathpalette\@mypm\relax} 8~G$~($G = 9.81~m/s^{2}$) with sensitivity of 0.244~$mG/LSB$~(least significant byte). The data range of the gyroscope is $\mathbin{\mathpalette\@mypm\relax}$1000~$dps$ (degree per second) with sensitivity of 35~$mdps/LSB$. An Android application, "MS band data collector (pro)" was used to stream and store the data on a Samsung Galaxy A5~(Android 6.0.1). Observations of the PD classes and their severities were concurrently performed every minute during the data collection period by a trained expert (D.P.) who accompanied PwP and passively monitored them. The symptom labels for bradykinesia and tremor were performed according to the MDS-UPDRS in a standard 5-level rating scale, where they correspond to item III.14 and III.17, respectively. Dyskinesia was assessed using the abnormal involuntary movement scale (AIMS, item A2.5). For all these three types of motor signs, the absence of abnormality is rated as 0 and the severity levels correspond to 1 = slight, 2 = mild, 3 = moderate and 4 = severe. When none of the abnormalities were present, the motor state of the patients was considered to be eukinetic, and classed as \emph{balanced}. Furthermore, voluntary activities (e.g., walking, standing, lying/resting and sitting) were reported in the same one-minute time window. When multiple types of the motor signs and activities were present within the same time window, the predominant motor sign and activity were reported. The data collection was performed in a free-living environment during the regular in-patient stay at the hospital for medication adaptation. On average, the data were collected for 331.2$\mathbin{\mathpalette\@mypm\relax}$192.6 minutes per participant, totaling 9937.0 minutes across the participants. After being briefed on the procedure, the participants wore the band on the wrist of the more affected side. Once the bluetooth connection was established between the band and smartphone which locally stored the data, the participants were free to engage in any daily routine including activities outside of the hospital. The recording ended when the patients desired, or before going to bed at the latest. Furthermore, the sensing device was disabled when the patients were in the toilet/bath or when requested. \section{Hierarchical PD Symptom Recognition} In this section, the approach for autonomous PD detection and estimation are presented. We start by characterizing the collected data and their relevance for estimating PD classes, thereby motivating a selection of motion features. The PD classes are then assessed by a multi-layer GP model. In the first layer, a GP estimates the presence of tremor and its severity. In case tremor is absent, the second layer is triggered, where two estimations are performed in parallel; one for dyskinesia and the other for bradykinesia. Hence, the severity level of both movement symptoms is predicted for all incoming data in the second layer. Then, we select the symptom class with the larger predicted value, as we intend to estimate the predominant motor symptom. The absence of movement disorders (i.e., balanced state) is assumed when no sign of these three PD classes is present. \subsection{Data Analysis} \label{data} In the following, we provide an overview of the collected patient data. The descriptive analysis of the PD annotations shows that 35.95\% belongs to the balanced class, while the bradykinesia and dyskinesia were observed in 38.70\% and 21.13\% of the data, respectively. The percentages are normalized between participants as the data size differs between them. The annotations also indicate patients spent a large proportion of their time sitting on a chair (41.58\%), see Fig.~\ref{symp_fig} for details. The activities gathered in the category \textit{other} comprise specific tasks, for instance eating, climbing stairs and brushing teeth or activities that externally confound inertia measurements such as taking a train or being in an elevator. \begin{figure}[!t] \centering \includegraphics[width=\columnwidth]{pie_chart} \caption{{\bf Distribution of PD class severities and activities of the participants.} The label distributions were calculated from the collected dataset for each participant and then averaged. The arrows in the PD class chart (left) indicate increasing severity of dyskinesia (DK) and bradykinesia (BK) scores in 4 levels each. The tremor class (TM) also has four severity levels, but is visualized here as a single section (purple).} \label{symp_fig} \end{figure} As interaction of PD and activity annotations result in a wide bandwidth of motion intensities, we investigate the power spectral density (PSD) of the corresponding accelerometer data. The analysis shows that sitting and standing labels have PSD spread between 1-10~Hz and a clearly differentiated tremor at around 4-6~Hz. For the walking label, the characteristic tremor activity is partially absorbed by the walking frequency which has harmonics of $\approx$2.5~Hz, as walking itself generates a strong peak in PSD. Lying is generally described by low power across the spectrum, meaning that arm motion occurs infrequently. The shift of the tremor PSD peak towards 7~Hz during lying might be caused by the change in the resonance frequency of the wrist due to a movement constrained by a lying surface~\cite{Lakie2012}. \begin{figure}[!t] \centering \includegraphics[width=0.9\columnwidth]{psd} \caption{{\bf Power spectral density (PSD) of the accelerometer data.} The PSD is visualized for bradykinesia (BK), tremor (TM), dyskinesia (DK) and the balanced state (none). It shows generally high densities during walking, where the dotted line depicts the scale limit of the other three plots, and very low PSD values during lying.} \label{psd} \end{figure} Moreover, further analysis reveals on average increasing PSD in the PD classes from bradykinesia through the balanced state to dyskinesia, as visualized in Fig.~\ref{activity}, even though the individual activities introduce a high noise level. The tremor class is omitted in this figure, as the PSD of tremor data tends to overshadow the other PD classes. \begin{figure}[!t] \centering \subfloat{% \begin{tikzpicture}[font=\sffamily\scriptsize] \begin{axis} width=0.55\columnwidth, height=5cm, xlabel style={align=center}, x label style={at={(axis description cs:0.5,-0.1)},anchor=north}, xtick={1,2,3,4,5}, xticklabels = {0,1,2,3,4}, xlabel = {class severity\\ bradykinesia}, grid=major, xmin = 1, xmax = 5, bar shift=0pt, bar width=0.4cm, enlarge x limits=0.1, ymin = -5, ymax = 47, ylabel = average PSD, y label style={at={(axis description cs:-0.2,0.8)},anchor=east}, ytick = {0,5,10,15,20,30,40}, yticklabels={0,,10,,20,30,40},] \draw[-, draw] (0,0) to (6,0); \addplot+[mark=none,color = blue!80, fill = blue!20, ybar, solid, error bars/.cd, y dir=both, y explicit, error bar style={line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(5,0.0631) +- (0,0.273595706904474)}; \addplot+[mark=none,color = blue!80, fill = blue!40 ybar, solid,error bars/.cd, y dir=both, y explicit, error bar style={line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(4,3.073362068250275) +- (0,5.516763444889589)}; \addplot+[mark=none,color = blue!80, fill = blue!60 ybar, solid,error bars/.cd, y dir=both, y explicit, error bar style={line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(3,3.958840302585484) +- (0,5.047889116290308)}; \addplot+[mark=none,color = blue!80, fill = blue!80 ybar, solid,error bars/.cd, y dir=both, y explicit, error bar style={line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(2,4.266250140432615) +- (0,5.233076594048313)}; \addplot+[mark=none,color = lr, fill = lr, ybar, solid,error bars/.cd, y dir=both, y explicit, error bar style={line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(1,6.461217535556324) +- (0,8.231480028356337)}; \end{axis} \end{tikzpicture}} \subfloat{% \begin{tikzpicture}[font=\sffamily\scriptsize \begin{axis} width=0.55\columnwidth, height=5cm, xlabel style={align=center}, x label style={at={(axis description cs:0.5,-0.1)},anchor=north}, xtick={1,2,3,4,5}, xticklabels = {0,1,2,3,4}, xlabel = {class severity \\ dyskinesia}, grid=major, xmin = 1, xmax = 5, bar shift=0pt, bar width=0.4cm, enlarge x limits=0.1, ymin = -5, ymax = 47, ylabel = average PSD, y label style={at={(axis description cs:-0.2,0.8)},anchor=east}, ytick = {0,5,10,15,20,30,40}, yticklabels={0,,10,,20,30,40},] \draw[-, draw] (0,0) to (6,0); \addplot+[mark=none,color = lr, fill = lr, ybar, solid,error bars/.cd, y dir=both, y explicit, error bar style={line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(1,6.461217535556324) +- (0,8.231480028356337)}; \addplot+[mark=none,color = black!20!red, fill = red!80, ybar, solid,error bars/.cd, y dir=both, y explicit, error bar style={solid, line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(2,11.463456247185030) +- (0,12.205822018768758)}; \addplot+[mark=none,color = black!20!red, fill = red!65, ybar, solid,error bars/.cd, y dir=both, y explicit, error bar style={solid, line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(3,21.792863393697388) +- (0,19.346772525995650)}; \addplot+[mark=none,color = black!20!red, fill = red!50, ybar, solid, error bars/.cd, y dir=both, y explicit, error bar style={solid, line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(4,23.004734240549325) +- (0,19.139123340159873)}; \addplot+[mark=none,color = black!20!red, fill = red!35, ybar, solid, error bars/.cd, y dir=both, y explicit, error bar style={solid, line width=1.5pt, gray, xshift=0cm}, error mark options = {rotate = 90, line width=1.5pt, mark size = 3pt, gray,}] coordinates{(5,28.137935307698860) +- (0,17.283268430286572)}; \end{axis} \end{tikzpicture}} \caption{{\bf Average PSD of the non-tremulous accelerometer data per PD class severity.} The mean (visualized by bar height) of each PSD per class severity level with its standard deviation (gray error bar) is sorted from balanced to severe. In both figures the yellow bar depicts the average PSD level in the balanced state. On the left side the severity levels of bradykineasia (without tremor) are visualized in blue shades, on the right side the levels of dyskinesia in red shades. } \label{activity} \end{figure} \subsection{Data Processing and Feature Generation} \label{sec:feature} The collected inertial data are processed to quantify relevant motion features which are then synchronized with PD and activity annotations, as schematically visualized in Fig.~\ref{feat_gen}. The resulting data set is used for modeling the PD annotations in the hierarchical approach. \begin{figure}[!t] \centering \includegraphics[width=\columnwidth]{feature_generation} \caption{{\bf Inertial data and expert ratings processing.} The sensor data is pre-processed before PD features are extracted. The resulting data are then synchronized with the PD and activity annotations performed by the expert rater.} \label{feat_gen} \end{figure} As the raw inertial data includes sensor noise, we smooth the accelerometer and gyroscope data with a two-directional Butterworth band-pass filter \begin{equation} \begin{split} \left( \tilde{a}_x, \tilde{a}_y, \tilde{a}_z\right)^\top &= f_\text{Bw} \left( a_x, a_y,a_z, lb, ub \right),\\ \left( \tilde{\omega}_x, \tilde{\omega}_y,\tilde{\omega}_z\right)^\top &= f_\text{Bw} \left( \omega_x, \omega_y,\omega_z, lb, ub \right). \end{split} \end{equation} The lower bound~$lb$ of the cut-off frequency was set to 0.1~Hz to filter out sensor drift, and the upper bound~$ub$ was set to 20~Hz to filter out high frequency noise. Furthermore, to avoid dependency of the signal on the wrist band placement (left versus right wrist) and orientation (lateral versus distal and upright versus inverted), the vector norm~$\|\cdot\|$ of both filtered inertial units is calculated, \begin{equation} \begin{split} \delta_\text{acc} &= \|\left( \tilde{a}_x, \tilde{a}_y, \tilde{a}_z\right)^\top\| \\ \delta_\text{gyr} &= \|\left( \tilde{\omega}_x, \tilde{\omega}_y,\tilde{\omega}_z\right)^\top\|, \end{split} \label{sigfilt} \end{equation} and thus scalar signals~$\delta_\text{acc}$ and~$\delta_\text{gyr}$ are obtained. All subsequent feature generation is performed on the processed signals. As demonstrated in Fig.~\ref{activity}, the PD classes have different spectral characteristics. Therefore, we base the feature generation on a time-frequency transformation, namely on wavelet decomposition of the processed sensor data. The signals~$\delta_\text{acc}$ and~$\delta_\text{gyr}$ are transformed using Daubechies wavelets~$\psi_3$ of order 3. The odd-numbered decomposition levels 1, 3, 5, 7 and 9 are employed, as those layers cover the bandwidth of activity levels present in daily living activities according to our observation~(\ref{data}). In Fig.~\ref{feature} a raw accelerometer signal and the third wavelet decomposed level of the corresponding filtered signal vector norm are depicted. The lower part of the figure shows that wavelet decomposition is capable of differentiating voluntary motion (white background) from the tremor-induced motion~(green shaded area). We remove the even-numbered layers from the model to minimize redundancy in the feature space. Then, for each decomposed level~$\tilde{\delta}_{\text{acc},i} = \psi_{3}(\delta_\text{acc},i)$ and~$\tilde{\delta}_{\text{gyr},i} = \psi_{3}(\delta_\text{gyr},i)$, where $i \in \{1,3,5,7,9\}$, characteristic features are calculated. The features consist of standard deviation, norm, maximum, root mean square, kurtosis and skewness, as they encode motion properties of the displayed PD class and activity. In addition, the signals~$\tilde{\delta}_{\text{acc},i}$ and~$\tilde{\delta}_{\text{gyr},i}$ are differentiated for all $i \in \{1,3,5,7,9\}$ and the standard deviation, norm and root mean square are reapplied to the differentiated signals. A logarithmic scaling is used on a selection of features to improve the activity level separation, as the logarithmizing stretches small positive signals. More specifically, the logarithm is taken of all features obtained from the gyroscope and of the differentiated accelerometer features. \begin{figure}[!t] \centering \includegraphics[width=\columnwidth]{signal} \caption{{\bf Wavelet transformation of the accelerometer data.} The discrete wavelet decomposition is performed on the vector norm of 3D accelerometer (and gyroscope) measurements to calculate features that describe characteristics of the 60 seconds time window. Only the third level of the accelerometer signal decomposition is depicted. The green shaded area indicates presence of the tremor according to the PD annotation.} \label{feature} \end{figure} Every feature is computed for each one minute time window~$t$, if the size of the sample set~$\mathcal{J}_t$ that is captured during window~$t$, contains at least 10\% of the number of data samples that should be captured during one minute, i.e. $\# \mathcal{J}_t \geq 360$ sensor measurements (60~Hz sampling rate times 60~seconds corresponds to 100$\%$). Hence, we only omit data windows that suffer from severe data loss. We allow this small percentage of data samples per captured time window, because the Bluetooth data transmission between the smartwatch and the storage device (smartphone) was occasionally interrupted. The features introduced so far characterize the power in the inertial data and are thus best suitable for describing the tremor and dyskinesia. As bradykinesia is characterized by very slow motion and complete absence of motion, rest phases in the patients' sensor data additionally need to be quantified. Therefore, features encoding the length of rest phases within the time window are investigated. We define rest as the proportion of data where the processed inertial signals~(\ref{sigfilt}) are below a given threshold~$c$, \begin{equation} \text{rest}_\text{acc/gyr} = \sum_{j\in\mathcal{J}_t} \frac{\mathbb{B}\left({\delta}_\text{acc/gyr}(j) < c \right)}{ \# \mathcal{J}_t }, \end{equation} where~$\mathbb{B}(\cdot)$ denotes the boolean operator that assigns the numbers $\{0,1\}$ depending on whether the relation on the inside is false or true. Multiple thresholds are introduced to compensate for inter-patient and inter-activity variability and to cover all severity levels of the PD classes. We use 0.1, 0.15, 0.2, 0.25 and 0.3~$G$ as thresholds $c$ for accelerometer and 1, 1.25, 1.5, 1.75 and 2~$dps$ for gyroscope, respectively. As during severe bradykinesia it can happen that the patient does not move during the whole one minute window, additionally the rest proportion over a 5 minute window~$\bigcup_{\tau \in T}\mathcal{J}_{\tau}$ is calculated, consisting of the two minutes before and after the current time window, $T = \{t-2,t-1,t,t+1,t+2\}$. Additionally to the previously mentioned features, we include features that are inspired by the Parkinson's KinetiGraph system~\cite{Griffiths2012}. The two raw inertial signals are filtered, using a stronger bandpass filter (with limits 0.2~Hz and 4~Hz) to keep voluntary motion only. Then, the maximum and the mean spectral power at the maximum are calculated, as those features have been reported to provide promising results for severity estimation of PD classes~\cite{Ossig2016}. The total number of features obtained is 132 for both inertial sensors (the accelerometer and gyroscope). They are concatenated into the feature vector~$\lambda\in \R^{132}$. We use this vector to model and predict the PD classes. \subsection{Multi-layer Gaussian Process} \label{sec:MGP} In the following, we present our technique to estimate PD class severity $\xi$ from the feature vector $\lambda$. We propose to use multiple successive GPs to estimate the unknown function \begin{equation} \varphi(\lambda)=\xi. \end{equation} GPs are well suited for modeling human movement behavior due to their property to generate smooth motion predictions for nonlinear dynamics. The training input set~$\{\,\mathbf x_i\}_{i =1}^\nu$ to the multi-layer GP is the feature vector~$\{\lambda_i\}_{i = 1}^\nu$. Specifically, at first a \textbf{tremor GP} is trained to recognize the severity of the tremor from the training input ~$\left\{\lambda_i\right\}_{k = 1}^{\nu}$. The training output set~$\{y_{\text{TM},i}\}_{i = 1}^{\nu}$ is optimized to approximate the severity, \begin{equation} y_{\text{TM},i} \approx \begin{cases} \xi_i & \text{if } i\in \mathcal{J}_\text{TM}, \\ 0 & \text{otherwise}, \end{cases} \end{equation} where the set~$\mathcal{J}_\text{TM} := \{j\in \{1,\ldots,\nu\} \wedge \xi_j \text{ contains tremor} \} $. The next hierarchical level is triggered for the non-tremor data only~$\left\{\lambda_i\right\}_{i = 1, i\notin \mathcal{J}_\text{TM}}^{\nu}$. This second layer comprises two GP estimations; the \textbf{dyskinesia GP} for modeling dyskinesia, and the \textbf{bradykinesia GP} for modeling bradykinesia. Each of the models is trained to approximate the PD class and severity with its output \begin{equation} \begin{split} y_{\text{DK},i} &\approx \begin{cases} \xi_i & \text{if } i\in \mathcal{J}_\text{DK}\wedge i\notin \mathcal{J}_\text{TM},\\ 0 & \text{else,} \end{cases}\\ y_{\text{BK},i} &\approx \begin{cases} \xi_i & \text{if } i\in \mathcal{J}_\text{BK}\wedge i\notin \mathcal{J}_\text{TM},\\ 0 & \text{else,} \end{cases} \end{split} \end{equation} where the index sets~$\mathcal{J}_\text{DK}$ and~$\mathcal{J}_\text{BK}$ are defined as~$\{j\in \{1,\ldots,\nu\} \wedge \xi_j \text{ dyskinetic}\}$ and~$\{j\in \{1,\ldots,\nu\} \wedge \xi_j \text{ bradykinetic}\}$, respectively. In the third layer the decision among the balanced, dyskinesia and bradykinesia classes is made based on the results from layer two: When both GP models provide outputs~$y_{\text{DK},i}<\tilde c$ and~$y_{\text{BK},i}<\tilde c$ below a certain threshold $\tilde c$, we consider the correct classification to be balanced. Otherwise the PD class of the GP model providing the higher predicted value is selected. After the model training is finished in the multi-layer GP, we aim to provide PD class and severity estimates for unseen input data. Given a new feature vector~$\lambda_{\nu+1}$, the process output describes a Gaussian distribution, which has the GP mean prediction as the expected value. The function~$\lfloor \cdot \rceil$ rounds the GP mean prediction~$\hat{y}_{\nu+1} \in \R$, which is obtained in continuous space, to the nearest integer, and in the unlikely case of predictions outside the scale limits~$[-0.5,4.5)$, maps the negative and positive values to 0 and 4, respectively. It is performed to match the interval variable~$\{0,1,2,3,4\}$ of the PD annotations. An illustration of the hierarchical approach is provided in Fig.~\ref{hier_model}. Detailed background information on GP modeling is provided in the Appendix. \begin{figure}[!t] \centering \includegraphics[width=\columnwidth]{hierarchical_model} \caption{{\bf Hierarchical algorithm scheme. } The feature vector $\lambda$ is the input to the hierarchical approach. After testing for tremor in the first model layer ($y_\textsf{TM} <0.5$ or $y_\textsf{TM} \geq 0.5$), the remaining non-tremor data is tested in the second layer for dyskinesia and bradykinesia severity. Each of the models provides an estimate of the severity in the continuous space $\mathbb{R}$, where, however, values outside the interval $[-0.5, 4.49]$ are extremely rare. In the third layer of the hierarchical approach we decide among the three remaining classes bradykinesia, dyskinesia or neither (balanced) depending on the estimated severities across the PD classes. If both predictions obtained from the dyskinesia GP and the bradykinesia GP, respectively, are below a certain threshold ($c = 0.5$), the balanced condition is nominated. If any of the predicted values exceed the threshold, the PD class of the larger value is appointed. To determine one of the interval severity levels 1-4 in the PD annotations, the GP prediction is rounded to an integer value.} \label{hier_model} \end{figure} \subsection{GP Hyperparameter Characteristics} To ensure that the GPs generalize well to unseen data, the GPs should learn the characteristics of the movement features rather than the frequency of the PD class observations in the input data. Therefore, the estimation of false positives (\textit{FP}, i.e. predicting a target when there is none) and false negatives (\textit{FN}, i.e. missing the target) are considered as equally undesired, as this induces impediment of over- and underestimation of a PD class at the same time. This means the GP models in Fig.~\ref{hier_model} are required to satisfy the property $FN/FP= 1$, which is achieved by selecting the initial hyperparameters of each of the GP models to approximate this ratio. As a GP model that roughly meets the $FN/FP= 1$ property in the initial optimization step is already close to a local optimum and the GP model training employs a gradient descent algorithm, it is unlikely that during training the model deviates from producing estimates where $FN/FP\approx 1$. Furthermore, a relatively large signal noise~$\vartheta_n$ hinders the overfitting of the GP models to the training data sets and thus, reduces the model's training accuracy, but during testing supports the generalization property. \section{Statistical Analysis} In this section we detail the practical application of the hierarchical approach to the data set. First, we introduce a feature vector reduction, to ensure efficient performance of the multi-layer GP. Then, we present how the whole data set is split into disjoint training and test sets, to analyze the model's ability to generalize to unseen data and unknown patients. Furthermore, we explain how we deal with the non-uniform PD class distribution in the whole data set. Finally, we provide the initial training hyperparamters and independent training accuracies of the tremor GP, the dyskinesia GP and the bradykinesia GP. \subsection{Feature Vector Reduction} To reduce the computational complexity of the multi-layer GP, each internal GP model is trained and tested on a subset of the 132 dimensional feature vector only. To determine the informative wavelet decomposition levels a detailed interpretation of the behavioral motion spectrum of the patient data is required: Decomposition level 1 contains motions with very low frequency ($<$0.2~Hz) which is slower than usual human behavior and thus can be assumed to mainly contain sensor drift. Decomposition levels 3 and 5 cover the frequency range of most intended motions and are thus important to distinguish voluntary motion from PD-specific motor abnormalities. Decomposition level 7 includes frequencies that correspond to fast movements, rarely found in the voluntary motion spectrum of daily living activities of elderly PD patients, but frequently occurring during dyskinetic phases. Decomposition level 9 contains motions of the characteristic tremor frequencies \mbox{(4-6}~Hz). Therefore, we reduce the feature vector~$\lambda\in \mathbb{R}^{132}$; for the dyskinesia GP we delete the wavelet decomposition levels 1 and 9 for both signals (accelerometer and gyroscope), and for the bradykinesia GP we delete the levels 1 and 7 for both signals. Hence, in each of the GP models the dimensionality of the input vector is reduced by $36 = 2\times 2 \times 9$ dimensions (9 is the number of features calculated in one wavelet decomposition level). In the tremor GP the full feature vector~$\lambda\in \mathbb{R}^{132}$ is employed to facilitate separation of the PD class from all other incoming signals. \subsection{Disjointed Patient Sets} We split the participant cohort, consisting of 30 participants, into two disjoint sets; one group consists of the training dataset and the other group is the test dataset which is used to test the trained model's accuracy. With this approach, we not only quantify the ability of our model for perform regression and prediction, but also demonstrate the model's ability to generalize to datasets of unknown patients. Hence, we introduce an approach that does not require fine tuning on the target patient, but is globally applicable to PD patients. Specifically, we perform a leave-one-subject-out (LOSO) approach, where we repeat the training and testing procedure 30 times. In each of the independent runs, the test group consists of one participant and the training is performed on the remaining 29 participants in the cohort. We iterate through the participant cohort so that after the 30 trials the dataset of every participant was once the test set. \subsection{Non-uniform Symptom Distribution} With respect to the three independent rating scales for the PD classes, the whole data set is extremely non-uniformly distributed. In Fig.~\ref{train_set}, top row, the data distributions according to the independent scales are visualized. For instance, according to the tremor rating scale, 96\% of the data does not belong to this class and thus, each of the 30 tremor GPs has an underlying class distribution similar to the pie chart in the upper right corner of Fig.~\ref{train_set}. We say similar, because in each LOSO experiment run a different participant dataset is left out, which slightly effects the class distribution of the training data set of the remaining 29 participants, whereas Fig.~\ref{train_set} shows the PD class distribution of the whole data set. Finding suitable GP model hyperparameters that represent the PD class characteristics, not their frequencies, becomes more difficult the more non-uniformly the PD classes are distributed in the training data set. Therefore, we do not train the three GP models on the whole data set, but on data subsets that only comprise the balanced data and the data where the respective class (bradykinesia, dyskinesia or tremor) is present, see Fig.~\ref{train_set}, bottom row. Furthermore, we do not reduce the amount of balanced data, as the balanced class covers the most widespread activities in free living and thus, contains a large diversity of intended motion patterns that need to be distinguished from the unintended motions caused by the movement abnormality. \begin{figure}[!t] \centering \includegraphics[width=\columnwidth]{TM_BK_DK_fig} \caption{{\bf Distribution of PD class severities according to the different rating scales.} According to the independent scales all data where a specific PD class is not apparent is assigned to the balanced class. To reduce the non-uniformity of the class distribution during the GP model training, the dyskinesia GP, the bradykinesia GP and the tremor GP are trained on the data subsets illustrated in the bottom row left, middle and right, respectively. For all three GPs the model testing, however, is performed on the full data sets (top row).} \label{train_set} \end{figure} The model testing, however, is performed on the whole data set, i.e. the GP predictions of each of the GP models in Fig.~\ref{hier_model} are tested against the PD annotations of the respective test dataset regardless of the PD class. \subsection{Initial Hyperparameters} All 30 training runs per GP model class (tremor, dyskinesia and bradykinesia) are initialized with the same vector of starting hyperparameters~$\theta = (\vartheta_f,\vartheta_l,\vartheta_n)^\top$, in particular for any tremor GP the initial hyperparamter values are~$\theta_\textsf{TM} = (96.83,0.23,0.50)$, for any bradykinesia GP they are~$\theta_\textsf{BK} = (96302550,826659,0.65)$ and for any dyskinesia GP they are~$\theta_\textsf{DK} = (128741,2.26,0.83)$. Those hyperparameter vectors, found by heuristics, fulfill the $FN/FP\approx 1$ property. \subsection{Training Accuracy of Symptom Severity} The three GP model classes in the hierarchical approach are trained independently using the described setup for GP model training. We denote with \emph{training accuracy} the percentage of data, where (after the model training has finished) the re-estimated PD severity matches the expert label, and provide the achieved model training accuracies in Table~\ref{training}. Row-wise, the training accuracy of the tremor GP, dyskinesia GP and bradykinesia GP are provided in terms of the mean and the standard deviation of the 30 independent experiment runs in the LOSO approach. The severity estimation accuracy percentages are given for each of the main activity categories (\textit{sitting, walking, standing, lying} and \textit{other}), and for the total amount of data under \textit{all}. The presented accuracies in all GP models are normalized by the amount of data available in each run, to prevent biased results due to the distortion of repetitions, where the data set for a certain PD class differs strongly in size. During the model training a tradeoff needs to be met between the model adaptation to the training dataset and the model generalizability to new patients. To avoid overfitting of the GP models, the accuracy results of the training are rather low compared to highest achievable training accuracies as we attach importance to the generalizability of the trained models. \begin{table*}[!t] \renewcommand{\arraystretch}{1.3} \caption{Training Accuracy of the Symptom Severity for each Activity.} \label{training} \centering \begin{tabular}{r|c c c c c c} Accuracy mean (std) in \% & other & sitting & walking & standing & lying & all\\ \hline\hline tremor GP & 89.06 (1.24) & 79.75 (1.58) & 82.81 (2.05) & 78.11 (2.83) & 86.03 (1.66) & 83.15 (1.87)\\ bradykinesia GP & 62.56 (3.843) & 60.73 (4.52) & 60.29 (4.26) & 59.80 (3.95) & 60.90 (4.79) & 60.86 (4.28)\\ dyskinesia GP & 49.32 (3.50) & 52.69 (2.16) & 44.55 (1.88) & 46.14 (4.98) & 73.68 (1.24) & 53.28 (1.79)\\ \end{tabular} \end{table*} \section{Results} In this section we report the experimental results of our approach. The test accuracies are first independently evaluated for each layer of the multi-layer GP, and then the contingent accuracies over the layers are reported as the total accuracy of the model performance. All GP model accuracy results are provided in terms of the mean and standard deviation per main activity category (\textit{sitting, lying, standing, walking} and \textit{other}) to study whether the model prediction was affected by specific activity types. In addition to the \textit{standard accuracy}, the percentage of predictions where the PD annotations 0-4 match the model output, we report the \textit{$\mathbin{\mathpalette\@mypm\relax} 1$ accuracy}, defining the percentage when the predicted PD severity is at most one level off the severity assessed by the expert rater. Previous studies highlight the agreement rate of PD severity estimation between movement-disorder specialists suffers from the complexity in a display of motor abnormalities and an application of observation-based assessment tools such as UPDRF~(e.g.,~\cite{Heldman2011,Post2005}). As we employed a single rater design to manage the extensive monitoring of PD patients in unscripted activities, the PD severity annotations used in the machine learning expects to have some degree of measurement uncertainty. In the present study, therefore, we also report $\mathbin{\mathpalette\@mypm\relax} 1$ accuracy as guiding information to show the tendency towards the correct estimation in the face of the inherent input data uncertainty. The prediction accuracy of the full test data is provided in column \textit{all}, while the accuracies for each of the activity categories \textit{sitting, walking, standing, lying} and \textit{other} are presented in the corresponding column. The results are presented in terms of mean and standard deviation (std) of the accuracies in each of the conducted 30 test runs when iterating through the test patients. The accuracy results are normalized by the amount of data available for each patient and activity to avoid any bias in calculating the mean and standard deviation due to the different data size across the participants. \subsection{Individual GP Model Accuracies} We start by analyzing the accuracies of each hierarchical layer independently. Hence, the accuracies in the second layer are obtained assuming 100\% correct tremor detection in the first layer. In Table~\ref{table_all} the independent in-layer results are presented. The severity estimations exceed 75\% accuracy in each activity for the tremor GP and in fewer than 5\% of cases is the predicted severity more than one level off the expert ratings for each activity. Hence, the tremor estimation in layer one is soundly separating the patient data into tremor and non-tremor data, and provides quite accurate predictions of the tremor severity independent of the performed activity. The captured movements' composition of intended motion and the unintended motor abnormality of dyskinesia and bradykinesia varies from patient to patient, and usually requires individual model tuning to the test patient. Our approach of training the GP models with unified initial hyperparameters, however, is designed to generalize among patients and therefore shows in cases a high standard deviation in the prediction accuracy, indicating a decreased suitability of the GP models for individual patients with atypical movement composition in comparison to the training patient set. However, the accuracy of the severity estimations in layer two clearly exceeds 50\% on average for bradykinesia and dyskinesia. The $\mathbin{\mathpalette\@mypm\relax} 1$ accuracy of the severity estimation for bradykinesia and dyskinesia classes exceeds 80\% across all activities. The motor abnormalities are exhibited more in some activities than others; the dyskinesia GP performs particularly well in estimating the PD classes and severities during lying, while this is the most difficult activity for the bradykinesia GP. The severity predictions of the dyskinesia GP during lying are more than 98\% correct or by at most 1 level off. For the testing results we obtain averaged $FN/FP$ ratios of 1.16, 0.98 and 0.87 for the tremor GP, the bradykinesia GP and the dyskinesia GP, respectively. \begin{table*}[!t] \renewcommand{\arraystretch}{1.3} \caption{Individual Layer Testing Accuracy of the Symptom Severity for each Activity.} \label{table_all} \centering \begin{tabular}{c l | c c c c c c} GP type & accuracy $(\%)$ & other & sitting & walking & standing & lying & all\\ \hline\hline \multirow{2}{*}{tremor} & mean (std) & 88.77 (15.72) & 79.13 (24.37) & 81.56 (20.58) & 78.50 (26.53) & 84.97 (15.64) & 82.58 (20.57)\\ & $\mathbin{\mathpalette\@mypm\relax} 1$ mean ($\mathbin{\mathpalette\@mypm\relax} 1$ std) & 98.92 (5.17) & 95.53 (9.22) & 97.77 (7.57) & 95.74 (11.93) & 97.52 (6.55) & 97.09 (8.09)\\ \rowcolor{gray!20} & mean (std) & 70.44 (22.17) & 71.89 (22.29) & 67.24 (25.15) & 49.75 (33.15) & 47.54 (30.81) & 61.37 (23.16)\\ \rowcolor{gray!20}\multirow{-2}{*}{bradykinesia} & $\mathbin{\mathpalette\@mypm\relax} 1$ mean ($\mathbin{\mathpalette\@mypm\relax} 1$ std) & 89.28 (16.40) & 89.54 (20.67) & 91.25 (20.18) & 93.63 (12.56) & 82.69 (26.03) & 89.28 (18.18)\\ & mean (std) & 46.99 (18.91)& 53.52 (20.36)& 50.11 (22.47) & 52.21 (24.77) & 85.84 (12.89) & 57.15 (19.87) \\ \multirow{-2}{*}{dyskinesia} & $\mathbin{\mathpalette\@mypm\relax} 1$ mean ($\mathbin{\mathpalette\@mypm\relax} 1$ std) & 88.49 (20.63) & 88.61 (16.43) & 89.53 (14.23) & 87.50 (16.09) & 98.31 (3.22) & 90.23 (13.33) \\ \end{tabular} \end{table*} \subsection{Total GP Model Accuracies} Next, we investigate the \textit{total accuracy} of the GP models, i.e. the probability of both layers (the first and the second) being predicted correctly at the same time. Specifically, the total accuracies are the percentage of accurate predictions of the bradykinesia GP and the dyskinesia GP, respectively, intersected with the accuracy of the tremor GP. For simplicity of presentation we provide the accuracy and the $\mathbin{\mathpalette\@mypm\relax} 1$ accuracy in terms of the percentage of correct predictions of the hierarchical approach for all patients taken together. In total, in 1318 instances of GP predictions tremor is estimated. The remaining 8619 data samples are processed in the second layer of the hierarchical approach. Inside the second layer, the bradykinesia GP and the dyskinesia GP never falsely predicted the presence of both PD classes in parallel for data of the same one minute time window. Hence, the discrimination worked precisely with the proposed motion features. Table~\ref{class_accuracy} notes the total test accuracy for the tremor, bradykinesia and dyskinesia and for the balanced condition, where movement disorders are absent. The accuracies of the severity estimations (0-4) are provided for the activity categories sitting, walking, standing, lying, other and all. For the full data set the tremor severity is estimated precisely in more than 80\%, the bradykinesia severity in more than 60\% and dyskinesia severity in almost 50\% and the balanced condition is detected correctly in more than 36\%. For all PD classes the $\mathbin{\mathpalette\@mypm\relax} 1$ severity estimation accuracy exceeds 80\% on the whole data, demonstrating a reliable detection of movement abnormalities in PD patients. \begin{table*}[!ht] \renewcommand{\arraystretch}{1.3} \centering \caption{Total Testing Accuracy of the Symptom Severity for each Activity.} \begin{tabular}{c l |c c c c c c} PD class & severity $(\%)$ & other & sitting & walking & standing & lying & all\\ \hline\hline \multirow{2}{*}{tremor} & accuracy & 88.77& 79.13& 81.56&78.50& 84.97& 82.58\\ & $\mathbin{\mathpalette\@mypm\relax} 1$ accuracy & 98.92& 95.53& 97.77& 95.74& 97.52& 97.09\\ \rowcolor{gray!20} & accuracy & 66.09 & 67.44 & 58.64 & 43.38 & 45.05 & 61.15\\ \rowcolor{gray!20}\multirow{-2}{*}{bradykinesia} & $\mathbin{\mathpalette\@mypm\relax} 1$ accuracy & 83.52 & 83.54 & 79.50 & 85.54 & 77.33 & 81.99\\ \multirow{2}{*}{dyskinesia} & accuracy & 40.80 & 47.41 & 37.13 & 43.38 & 77.48 & 49.24\\ & $\mathbin{\mathpalette\@mypm\relax} 1$ accuracy & 81.95 & 81.67 & 76.27 & 78.68 & 89.80 & 81.98\\ \rowcolor{gray!20} & accuracy & 34.46 & 39.91 & 19.76 & 23.98 & 48.28 & 36.70\\ \rowcolor{gray!20}\multirow{-2}{*}{balanced} & $\mathbin{\mathpalette\@mypm\relax} 1$ accuracy & 84.74 & 81.24 & 67.38 & 78.32 & 90.85 & 81.06\\ \end{tabular} \label{class_accuracy} \end{table*} \section{Discussion} The results from the previous section show that our hierarchical approach is capable of estimating PD classes with a good accuracy. We maintain quite precise estimation of the class severity across the presence of various activities including \textit{sitting, walking, standing, lying} and \textit{other}, indicating that our approach is robust against task-oriented arbitrary motions that are non-specific to PD. In more detail, our model found the activities labeled as standing and lying most difficult for estimating the severity of bradykinesia. This might be due to the absence of large motions in these cases and apparent similarities in behavior between the activity and the motor symptom, including the eyes of the observers who denotes PD annotations. Furthermore, lying frequently is reported for the participants with severe bradykinesia. The severity predictions of the dyskinesia GP during lying, in contrast, are extremely precise. It seems that the much reduced presence of voluntary motions in these activities results in a higher signal-to-noise ratio during dyskinesia estimation. Detecting the balanced class correctly was particularly difficult during walking, since this activity has an extraordinarily high PSD compared with the other activities~(see Fig.~\ref{psd}) and thus, is likely to be mistaken as tremor or dyskinesia. Note that due to the difference in the training and testing datasets the testing accuracies partly exceed the corresponding training accuracies. The GP models learned the characteristics of the various PD classes and thus, detected data with high accuracy that belongs to a different class than the individual GP model. The $\mathbin{\mathpalette\@mypm\relax} 1$ accuracies, which we consider more significant than the accuracies themselves, demonstrate particularly reliable tendency estimations; they exceed 80\% for all activities in the individual layer testing and often are above 90\%. Likewise, in the total accuracy testing the $\mathbin{\mathpalette\@mypm\relax} 1$ accuracies mostly are above 80\% and only once fall below 75\% (for predicting the balanced class during walking). These results support the importance of predicting PD manifestation with a hierarchical approach using advanced machine learning techniques. In comparison to the state of the art in autonomous PD class recognition for PD, we cover a wider range of PD states than most related work by considering tremor, bradykinesia and dyskinesia. Further, our approach allows for state estimation during unscripted daily living activities only with one inertial sensor, and without imposing specific tasks or motion patterns. A weakness of the approach concerns the data separation in the first hierarchical layer. Currently, a single GP model is trained for all tremor cases, thus this class does not differentiate whether the patients are co-exhibiting dyskinetic or bradykinetic symptoms. As the tremor is reported as a major initial symptom of PD~\cite{Hoehn1967}, finer classification of the tremor movements will make an important improvement upon the current results. The major hurdle in achieving this with the present study was an observation of a very few cases of tremor with dyskinetic tendency in our patient group. With a sufficient amount of data, estimating of tremor model with a finer class resolution might become possible. In the current approach we assume false positive (\textit{FP}) and false negative (\textit{FN}) predictions to be equally undesired. In other medical applications, however, other prediction characteristics could be prioritized, which require the adaptation of the initial GP hyperparameters. To give an example of another \textit{FN/FP}-ratio: if detecting all non-balanced PD classes is three times more important than predicting \textit{FP}s, this induces a GP model prediction ratio of $FN/FP \approx 0.33$. An alternative prediction characteristic is for instance: a PD class should be missed in at most 5\% of the estimations. In the present approach, appropriate hyperparameters for such prediction characteristics are found by heuristics. \section{Conclusion} In this article, we introduced a hierarchical approach for autonomous severity estimation of PD states from inertial sensor data, namely for non-tremulous bradykinesia, non-tremulous dyskinesia, and tremor. We motivate the hierarchical structure of the GP over these classes of PD symptoms by analyzing their class characteristics and propose expressive inertial data features, including those in the time-frequency domain. The results showed reliable estimation of symptom severities, and suggest that the proposed approach can differentiate the patient's symptoms with good precision during daily living, without imposing specific activities on patients.
\section{The diary of a journey.}\label{sec:01} To find an old mathematics notebook, protected from total deterioration by a plastic cover, was like an encounter with the diary of a distant journey. The contact with its yellowish pages triggered an avalanche of recollections of the years $1962 - 64,$ when I was a doctoral student in Brazil. Its sequential structure prompted the reconstruction of the chronology of my initiation into mathematical research. The essential landmarks -- the stations -- of a mathematical peregrination, starting from a bookish approach, heading toward an attempt to tackle research problems, pulsed latent in the rough writing and scribbled drawings. Some pages were missing, a few of them had faded away. \section {An afternoon in September 1962. } In a seminar room of the Institute of Pure and Applied Mathematics (IMPA), in the Botafogo quarter of the city of Rio de Janeiro, gathered a group of around ten people: mathematicians, research fellows of disparate backgrounds, candidates to become mathematicians, and one or two {\it voyeurs.} \begin{figure}[!ht] \begin{center} \includegraphics[scale=0.37]{LISTA_FOTO_IMPA_62} \caption{\small Present view of the facade of the two store house, located at the corner of the streets S\~ao Clemente and Sorocaba, hosting IMPA in $1962 - 64.$ \label{fig:sorocaba}} \end{center} \end{figure} The occasion was the Seminar on the Qualitative Theory of Differential Equations (QTDE), directed by Prof. Mauricio M. Peixoto (hereafter Prof. Peixoto, or simply Peixoto) who had announced the following title for his lecture: ``Open Problems on The Qualitative Theory of Differential Equations". The seminar activity had been interrupted for a few sessions. It was restarting after the return of Prof. Peixoto who had travelled to attend the International Congress of Mathematicians at Stockholm, August 15 - 22. \vglue .1in At that time Prof. Peixoto was the only Research Director resident at IMPA. Prof. Leopoldo Nachbin (1922 - 1993), also a research Director, was on leave of absence. Peixoto had very explicit views concerning Mathematics learning in graduate level. They where well known to most participants: ``This science is assimilated through solving problems and thinking", he had clearly stated, contesting insinuations of those who favored the preponderance of more intensive lecture courses and bookish learning. This contrasted with the naive and easy going vision I had partially acquired in my undergraduate predominantly reading contact with mathematics. Excitement and a tense expectation could be noticed in the audience. For the most experienced participants of the Seminar, the time to {\it face true research problems} had arrived. As a newcomer into advanced studies, and the youngest of all, I could be implicitly regarded outside such group. \section{ A flash of mathematics at IMPA in 1962 - 63.} \vglue .1in Among the experienced researchers, besides Prof. Peixoto who stayed at IMPA the whole period from 1962 to 1964, were Elon Lima (1930 - 2017), Djairo de Figueiredo (1934 - \; ) and Otto Endler (1929 - 1988) who sojourned for shorter periods. Elon stayed the whole first semester and Djairo only a couple of months. Otto stayed along 1962 and part of 1963. Few lecturers visited the Institute. Among them I mention below those which captured my interest. Charles Pugh (1940 - \; ). Subject: Closing Lemma, crucial in the work of Peixoto. Gilberto Loibel (1932 - 2013). Subject: Stratified Sets, introduced by Ren\'e Thom (1923 - 2004), founder, together with Hassler Whitney, of the Theory of Singularities of Mappings. Wilhelm Klingenberg (1924 - 2010). Subject: Closed Geodesics, located in the intersection of Differential Geometry, Differential Equations and Calculus of Variations. At that time, IMPA did not have a minimal program of courses to be offered along the year. This activity depended on the research fellows present, in a quickly changing regime. However, there was a permanent basis providing scientific stability to the Institute along those years, around Prof. Peixoto research project. Furthermore, due to an agreement with the University of Brazil, later denominated UFRJ (Federal University of Rio de Janeiro), a doctoral program started at IMPA in 1963. \vskip 0.5 cm {\bf This pioneer research project, under the leadership of Peixoto, is the landmark of the systematic interest in Dynamical Systems (DS) in Brazil. } {\bf This was the first explicit effort to stimulate the initiation into research in this area of mathematics in Brazil. I had the unique chance and privilege to be part of the first group of doctoral candidates, under the supervision of Prof. Peixoto.} \vskip 0.5 cm After the influential works of the American mathematician Stephen Smale (sixties and seventies) the denomination DS nominally assimilated a significant part of the QTDE from which the separating border is not well defined. See Smale's 1967 landmark article \cite{BAMS}. DS is also the name of a famous book of George Birkhoff, printed in 1927. \vskip .3 cm Ordered by the preponderance they had in my initiation into research, below I list some of the courses and seminars held at IMPA in 1962\footnote{This abridged version concerns activities on the QTDE. A wider description can be found in \cite{l}.}: 1. Seminar on the Qualitative Theory of Differential Equations; 2. Seminar on Differentiable Manifolds following the inspiring Porto Alegre Elon Lima book \cite{IVD}; 3. Seminar based on the reading of the, now classic, book of J. Dieudonn\' e: Foundations of Modern Analysis \cite{dieudonne}; 4. Course on Algebraic Topology, taught by Peixoto, based on the books of Cairns and Hocking - Young; 5. Course on Multilinear Algebra and Exterior Differential Calculus, based on Bourbaki and Flanders, taught by Elon Lima; 6. Seminar on the reading of the book ``Lectures on Ordinary Differential Equations'' by W. Hurewicz \cite{hurewicz}. I list bellow, with no ordering, some of the research fellows and {\it habitu\'ees} of IMPA, related to Prof. Peixoto Project, in 1962 - 63: Ivan Kupka (1938 - \; ), Maria L\' ucia Alvarenga (1937 - \; ), Jacob Palis (1940 - \; ), Lindolpho C. Dias (1930 - \; ), Alcil\' ea Augusto, (1937 - \; ), Aristides C. Barreto, (1935 - 2000). Much of the contents of the activities $1$ to $5$ listed above was new to me. I devoted to them special attention, with library search and extensive complementary readings. In this endeavor the friendly interaction with Ivan Kupka, by far the most knowledgeable in the group, was auspicious. \vspace{-0.0cm} \begin{figure}[h] \subfigure ] { \includegraphics[scale=0.42]{IMPA_62_FOTO_003.pdf}} \subfigure ] { \includegraphics[scale=0.42]{IMPA_62_FOTO_002.pdf}} \vspace{-0.0cm} \caption{{\bf At the entrance of IMPA, August 1962.} \newline {\small (a) Top row, left to right: Lindolpho Dias, M. Peixoto, Ivan Kupka, E. Isla, Aristides Barreto, Jacob Palis, Eliana Rocha, Alcil\'ea Augusto; descending the right margin and continuing clockwise on the bottom margin: C. Marquez, M. L. Alvarenga, M. H. Cerqueira, J. Sotomayor, Lia Velloso and Adarcy P. Costa. Three gentlemen sitting at the center, descending counter clockwise: L. Nachbin, H. Machado and J. A. Barroso. \newline (b) Top row from left to right: M. Peixoto, E. Isla, Celina Marquez, Lindolpho Dias and Jacob Palis. L. Nachbin at center, with necktie. Bottom right corner: Alcil\'ea Augusto, M. L. Alvarenga, Adarcy P. Costa. }}\label{Fig:02} \end{figure} \section {Peixoto's Seminar on QTDE, 1962.} \label{seminar} Along my sojourn at IMPA, 1962-64, the most remarkable of all the activities in which I engaged was the Seminar on the Qualitative Theory of Ordinary Differential Equations. Following the epistolary reading directions sent to me by Peixoto in 1961, recounted in the evocative essay ``Mathematical Encounters" \cite{encounters}, with the inspiring master presentations of Coddington and Levinson \cite{cod_lev} and Hurewicz \cite{hurewicz}, I had already been initiated into the first steps of the Qualitative Theory. The phase portrait, limit cycles and singular points local structures: saddles, nodes, foci and centers, were fiound there. A bright synthesis of these elements in the Poincar\' e - Bendixson Theorem complemented the introductory contact. While the subjects presented and discussed in the Seminar did not require a heavy background knowledge, their in depth appreciation depended on a level of maturity and on an inquisitive disposition, beyond the initiation outlined above, to which I had not yet been exposed. \subsection {Non singular ODEs on the Klein Bottle and the Torus.} The first lecture at the Seminar TQEDO, was delivered by Peixoto at the beginning of April. The subject was {\it The Theorem of Kneser, } whose conclusion is that ``Every vector field with no singular points in the Klein Bottle has a periodic orbit''. See \cite{kneser}. At the two next meetings of the seminar, Peixoto presented the basic theory of the {\it rotation number} following the last chapter of Coddington and Levinson. The second presentation included also a geometric construction of the {\it example of Denoy} of a $C^1$ non singular vector field for which all its orbits cluster in a closed invariant set, which transversally is a Cantor set, with no proper subset sharing these properties. Such a set is denominated ``minimal non-trivial''. The ``trivial minimal'' sets are the singular points --equlilibria-- and periodic orbits. \subsection {Invariant Manifolds.} Elon Lima continued the Seminar. He presented part of Chap. 13 of Coddington and Levinson \cite{cod_lev} which contains the Theory of Invariant Manifolds. It deals with the n-dimensional generalizations of ``saddles'' for singular points --equilibria-- and periodic orbits. Actually, these dynamical objects are called ``hyperbolic'', a name coined by Smale. This is one of the most technical matters of the book, which follows the approach of the German mathematician Oskar Perron (1880 --1975). In 1970, C. Pugh, whose name will appear later in this essay, and M. Hirsh made a substantial extension of the Invariant Manifold Theory elaborating ideas in the works of the French mathematician Jacques Hadamard (1865 - 1963). See \cite{hirsh_pugh}. Years later, I had a better assimilation of \cite{hirsh_pugh} and, in 1979, included it in \cite{licoes}. In 1973, I had used it to give a conceptual proof of the smoothness of the flow of a vector field \cite{soto_bsbm_1973}. Meanwhile, the approach of Perron, also in \cite{cod_lev}, was elaborated by C. Irwen using the Implicit Function Theorem in Banach Spaces. In \cite{cod_lev} is used the method of successive approximations. A version of this idea can be found also in Melo and Palis \cite{pal_mel}. \subsection {A detailed presentation of three papers of Peixoto on Structural Stability.} \label{AA_62} Along part of May and June, Alcil\' ea Augusto delivered a series of presentations, very detailed and carefully prepared, covering Peixoto's papers: \cite{peixoto_a}, \cite{peixoto_b} and \cite{peixoto_t}. The last paper, however, involved difficulties, particularly on non-orientable surfaces. This matter evolved into the so called {\it The Closing Lemma Problem,} of present research interest, extrapolating the domain of Classical Analysis. Rather than outlining the individual contents of these papers, I include below a personal appreciation on the subject, with non - exhaustive references. \section{ A Glimpse into Structural Stability.} The concept of Structural Stability was established during the collaboration of the Russian mathematicians A. Andronov ( 1901 - 1952) and L. Pontryagin (1908 -1988) that started in 1932 \cite{pontryagin}. It first appeared in their research note published in 1937. Andronov (who was also a physicist) founded the very important Gorkii School of Dynamical Systems. He left a remarkable mathematical heritage, highly respected both in Russia and in the West, \cite{gorelik}. By 1932 Pontryagin was an already famous Topologist who had started to teach differential equations and had voiced his interest in studying applied problems. Structural Stability is a consequence of the encounter of two mathematical cultures, See discussion in Sec.\ref{con_com}. For a dynamic model --that is, a differential equation or system $x^{\prime}=f(x)$-- to faithfully represent a phenomenon of the physical world, it must have a certain degree of stability. Small perturbations, unavoidable in the recording of data and experimentation, should not affect its essential features. Mathematically this is expressed by the requirement that the \emph{phase portrait} of the model, which is the geometric synthesis of the system, must be topologically unchanged by small perturbations. In other words, the phase portraits of $f$ and $f+\Delta f$ must agree up to a homeomorphism of the form $I+\Delta I$, where $I$ is the identity transformation of the phase space of the system and $||\Delta I||$ is small. A homeomorphism of the form $I+\Delta I$ is called an $\epsilon$-{\emph homeomorphism} if $||\Delta I||<\epsilon$; that is, it moves points at most $\epsilon$ units from their original positions. Andronov and Pontryagin stated a characterization of structurally stable systems on a disk in the plane. This work was supported by the analysis of numerous concrete models of mechanical systems and electrical circuits, performed by Andronov and his associates \cite{a_L}, \cite{a}. The concept of structural stability, initially called \emph{robustness}, represents a remarkable evolution of the continuation method of Poincar\'{e}. When the American mathematician S. Lefschetz translated the writings of Andronov and his collaborators from Russian to English \cite{a_L}, he changed the name of the concept to the more descriptive one it has today \cite{a_L}. He also stimulated H. B. de Baggis to work on a proof of the main result as stated by Andronov and Pontryagin. Peixoto improved the results of the Russian pioneers in several directions. For example, he introduced the space $\mathcal{X}^r$ of all vector fields of class $C^r$ , and established the openness and genericity of structurally stable vector fields on the plane and on orientable surfaces. He also removed the $\epsilon$-homeomorphism requirement from the original definition, proving that it is equivalent to the existence of any homeomorphism. This was a substantial improvement of the Andronov-Pontryagin planar theory. The transition from the plane to surfaces, as in Peixoto's work, takes us from classical ODEs to the modern theory of Dynamical Systems, from Andronov and Pontryagin to D. V. Anosov and S. Smale. It has also raised delicate problems --for instance, the \emph{closing lemma}-- that have challenged mathematicians for decades \cite{gutierrez_closing}. In \cite{sm} S. Smale regards Pei\-xo\-to's structural stability theorem as the prototypical example and fundamental model to follow for global analysis. \section Open Problems in ODEs, September 1962. \label{list_english}} \vspace{-0.0cm} \begin{figure}[!ht] \begin{center} \includegraphics[scale=0.99]{IMPA_62_FOTO_004.pdf} \vspace{-0.0cm} \caption{{\bf At the entrance of IMPA, August 1962.} \newline {\small Standing, left to right facing camera: Lindolpho C. Dias, Mauricio Peixoto, Jorge Sotomayor, Leopoldo Nachbin, Alcil\'ea Augusto and C. Marquez. Bottom row, left to right: Adarcy. P. Costa, Roberto R. Baldino, M. H. Cerqueira and Lia Velloso (librarian). }}\label{Fig:01} \end{center} \end{figure} After a concise, though very emphatic, introduction about the importance of attacking research problems, Prof. Peixoto began to enumerate and discuss five of them. \subsection{First order structurally stable systems.} \label{p1} \emph{Consider the complement $\mathcal{X}^r _1$ of the set $\Sigma^r$ of \ $C^{r}$-structurally stable vector fields, relative to the set $\mathcal{X}^r$ of all vector fields on a compact two-dimensional manifold. Let $\mathcal{X}^r _1$ be endowed with the induced $C^{r}$ topology. Characterize the set $\Sigma^r_1$ of those vector fields that are structurally stable with respect to arbitrarily small perturbations inside $\mathcal{X}^r _1$. } \smallskip This problem goes back to a 1938 research announcement of A. A. Andronov and E. A. Leontovich \cite{al_38}, \cite{al}. They formulated a characterization of $\Sigma^r _1$ for a compact region in the plane. This step points toward a systematic study of the bifurcations (qualitative changes) that occur in families of vector fields as they cross $\mathcal{X}^r _1$. In the research announcement --contained in a dense four pages note-- they stated that the most stable bifurcations occur in $\Sigma^r_{1}$, \cite{s}, \cite{cbm_81}. \subsection{The problem of the arc.} \label{p2} \emph{ Prove or disprove that a continuous curve (an arc) in the space $\mathcal{X}^r$ of vector fields of class $C^{r}$ on the sphere can be arbitrarily well-approximated by a continuous curve that meets only finitely many \emph{bifurcation points}; that is, points outside the set of structurally stable vector fields, at which qualitative changes occur.} Later research established that $\mathcal{X}^r_1$ enjoys great transversal complexity, which grows quickly with the dimension of the phase domain. This knowledge became apparent after the work of S. Smale \cite{BAMS} and also Newhouse \cite{n} and Palis -Takens \cite{p_t}, among others. The understanding of the phenomenon of persistent accumulation of bifurcations implies that the problem of the arc as stated above has a negative answer, \cite{IMUNI}. However, after removing the requirement of the approximation, Peixoto and S. Newhouse proved that every pair of structurally stable vector fields is connected by an arc that meets only finitely many bifurcation points. See \cite{p_n}. \subsection{The classification problem.} \label{p3} \emph{Use combinatorial invariants to classify the connected components of the open set of structurally stable vector fields. } \smallskip The essential difficulty of this problem is to determine when two structurally stable vector fields agree up to a homeomorphism that preserves their orbits and is isotopic to the identity. Some years later, Peixoto himself worked on this problem, \cite{peixoto_c}. \subsection{The existence of nontrivial minimal sets.} \label{p4} \emph{Do invariant perfect sets (that is, sets that are nonempty, compact, and transversally totally discontinuous) exist for differential equations of class $C^{2}$ on orientable two-dimensional manifolds?} \smallskip This problem goes back to H. Poincar\'{e} and A. Denjoy and was known to experts. It was solved in the negative direction by A. J. Schwartz \cite{sch_d}. Peixoto presented this result from a preprint that he received in November 1962. \subsection{Structurally stable second order differential equations.}\label{p5} \emph{For equations of the form $x^{\prime\prime}=f(x,x^{\prime})$ (more precisely, for systems of the form $x^{\prime}=y,\,\,y^{\prime}=f(x,y)$), characterize structural stability, and prove the genericity of structural stability, in the spirit of Peixoto's results for vector fields on two-dimensional manifolds.} \vspace{0.3cm} Problems \ref{p2} to \ref{p4} were assigned, in one-to-one correspondence, to the senior participants of the seminar. The first and last problems were held in reserve for a few months. In Sec. \ref{thesis}, I will recount how I was conduced to obtain Peixoto's support to attack problem \ref{p1} on his list. \vskip 0.3 cm {\bf When, years later, I read the proposal of the famous $1900$ Hilbert Problems, the words in the epigraph made me evoke the above mentioned introit of Peixoto's list of problems in September 1962, which then, keeping in mind the enormous difference in proportions, struck me as a distant echo of Hilbert's words in Paris 1900, that reverberated along decades before reaching the tropics. } \section {Peixoto's seminar, last 1962 sessions.} \label{seminar_nov_62} The last lecture in the Seminar was delivered by Peixoto. It was based on a preprint of A. J. Schwartz \cite{sch_d}, which solved in the negative problem \ref{p4}. Before this, toward the end of October, Ivan Kupka delivered a series of very technical lectures about Invariant Manifolds along arbitrary orbits, not necessarily periodic. He mentioned the work of Oskar Perron as the main reference for the hyperboliciy hypotheses adopted. To mitigate the concern of most participants in face with abundant analytical technicalities involved in the rough presentations, Peixoto started a parallel series of very informal tutorial discussions on Kupka's lectures. Everybody freely expressed their disparate attempts to explain geometrically the ideas as well as the long chains of inequalities involved. Maybe this convivial contact and my participation in the discussions, freely formulating hunches, established a more direct channel of communication between me and Peixoto, which so far had been a very formal one. \section{A good research problem.\label{good_problem}} After the presentations of Peixoto's work, timely commented by himself, complemented with considerable struggle with the bibliography, it was possible to have a panoramic view of a fascinating piece of knowledge. It was a sample of the evolution of mathematical ideas with an intriguing historical background, mathematically deep but essentially accessible, whose consolidation had seen the light in the last four years, concomitantly with my learning at university level, of the principles of Mathematical Analysis, Geometry and Differential Equations. Complementing the seminar lectures I had made substantial readings related to the QTDE and the Calculus and Geometry on Banach Spaces. I devoted considerable attention to Sard Theorem, which I first read in the presentation, \cite{EDJ}, of Prof. Edson J\' udice of the University of Minas Gerais (U.F.M.G), donated to me by the author by a recommendation of Aristides Barreto, with whom I became close friend. I also studied the book by S. Lang on Differentiable Manifolds, modeled on Banach spaces \cite{lang}. Along this endeavor I had rewarding discussions on mathematical subjects with Ivan Kupka. With great profit I read the enlightening lecture notes Introdu\c c\~ ao \` a Topologia Diferencial, \cite{ITD} by Elon Lima, which anticipated in several years Milnor's ``Topology from a differentiable viewpoint" \cite{MILNOR}. After this, I studied substantial parts of L. S. Pontrjagin, \cite{pontryagin_55}, ``Smooth Manifolds and its Applications to Homotopy Theory'', which I consider the original source for the application of Differential Analysis to the study problems in Topology. Some undefined intuitive and esthetic considerations, and a certain overestimation of my readings about Sard's Theorem, led me to the hunch that, if not all, part of Peixoto's genericity Theorem of Structurally Stable Systems could be obtained from an appropriate infinite dimensional version of this theorem. Being undefined the involved domain and range spaces. In discussions with Kupka, I had learned of an extension in this direction due to Smale. I approached Peixoto and shared with him my naive expectations. He made no comments. However, toward the end of november he handed me a copy of the Andronov - Leontovich four page note \cite{al_38}. \\ He said: ``Do not loose this. It is important. It is a good problem". Despite the technical difficulties, enhanced by, at that time, lack of bibliography on bifurcations, the sensation of possessing a research problem, produced in me the mixed feelings of a naive fulfillment and of overwhelming responsibility. I left Rio de Janeiro for the extended summer break of 1963. In my mind I carried a new sense of mathematical awareness. In my bag, packed in a plastic cover, travelled the note of Andronov - Leontovich. \begin{rem} Concerning the desideratum of providing a proof of Structural Stability Theorem genericity theorem with Sard's Theorem, I mention that in the decade of 1970, when I began to lecture on the subject for wide audiences, I felt the need, and found, a direct, self-contained, transparent proof that worked for the plane and for polynomial vector fields. The course in the 1981, $13^{th}$ Brazilian Mathematics Colloquium, \cite{cbm_81}, was an opportunity to communicate the new proof that used only an elementary form of the one-dimensional Sard's Theorem. An abridged version was also published in \cite{cras_1981}. \end{rem} \section{ Back to IMPA in 1963.} \label{back_63} In December 1962 I took the final examinations of a few courses I had pending to fulfill the number of academic credits required to get the Mathematics Bachelor degree from the National University of San Marcos, Lima, Peru. Along January and February I worked as teaching assistant in a Summer Mathematics School for the training of high school teachers. In my spare time, and full time on March, I scribbled piles of pages of calculations and drawings attempting to decipher the statements in Andronov- Leontovich note. Arriving to IMPA at the end of March, I had some time to discuss with Ivan Kupka the outcome of my summer struggle with the note of Andronov - Leontovich. Prof. Peixoto had scheduled me to present a report on the subject in May. The possibility of adapting the methods of his works to get some form of density of ${\Sigma}_1^r$ in ${\mathcal X}_1^r$, as proposed in problem \ref{p1}, was raised along the preparation and in discussions after the seminar sessions. This point is not mentioned in \cite{al_38} and \cite{al}. At the expense of considerable work, it seemed possible to adapt the methods in the works of Peixoto to the formulation extracted from the note of Andronov - Leontovich, extending it form the plane to surfaces. However, while attempting to complement my personal studies by reading whatever work containing some material on bifurcations that fell in my hands, among which ware \cite{minorski} and \cite{sansone-conti}, I was being led to the suspicion that problems \ref{p1} and \ref{p2} were intimately interconnected. This intuition received a mathematical formulation during July, catalized by events that took place at the IV Brazilian Mathematical Colloquium. \section{The IV Brazilian Mathematical Colloquium, 1963. \label{cbm}} At the Fourth Brazilian Mathematics Colloquium, in July 1963, \cite{cbm_63}, \cite{l}, everyone working under Peixoto's supervision made reports in a session of short communications. Only Ivan Kupka delivered a plenary lecture. Below, in free translation, the titles of the communications: Maria L\' ucia Alvarenga: ``Planar Structural Stability". Alcil\' ea Augusto: ``Parametric Structural Stability", Aristides Barreto: ``Structural Stability of Equations of the form $ x^{\prime\prime}= f(x, x ')$". ``Higher order Structural Stability", my communication, closed the list. The part of the work I did at IMPA that I consider innovative, concerning the structure of smooth Banach sub-manifold of the class of Andronov - Leontovich vector fields, had not yet been conceived. However its main ideas emerged during the Colloquium. I explain this point now. In the first semester of 1963, Kupka had spent a couple of months at the University of Columbia, N.Y., where Smale worked. He brought the, now classic, paper of Palais and Smale ``A Morse Theory for Infinite dimensional manifolds". Encouraged by Peixoto, he presented a Plenary Lecture about it. The title in \cite{cbm_63} is ``Counter example of Morse - Sard Theorem for the case of Infinite Dimensional Manifolds", though he spent most of his time explaining the Palais-Smale Theory. After an enlightening presentation, he concluded: ``The introduction of a new Theory must be accompanied by a solid justification. The one I presented today has applications to Calculus of Variations, Control Theory and Differential Geometry, among other subjects." In her short presentation Alcil\' ea Augusto exposed the generic finitude for the encounter of an arc of vector fields with the class of those whose equilibria have vanishing Jacobian. She used an elementary version of Thom Transversality Theorem analogous to the one used to prove the invariance of the Euler - Poincar\'e - Hopf characteristic of a smooth manifold, expressed as the sum of the indexes of the singularities of a vector field with non-vanishing Jacobians. At that time I had seen this procedure clearly explained in Lima's lecture notes \cite{ ITD}. Added to the examples of one parameter bifurcations I had scribbled from books on non-linear mechanics and oscillations, such as \cite{minorski} \cite{a}, and the re-reading of \cite{al_38}, the ensemble of the lectures of A. Augusto and I. Kupka, impacted my vision of problem \ref{p1}. The following intuition, or desideratum, struck me: The First and Second Problems were intimate parts of the same problem. The suitable synthesis of this association should be presented in terms of infinite dimensional sub-manifolds and transversality to sub-manifolds in the Banach space of all vector fields tangent to a surface. In fact, the part of the class ${\mathcal X}_1^r$ to be crossed by an arc, or curve of vector fields, needed to have a smooth structure, as that of a hypersurface, to express the crossing, or bifurcation, as a transversal intersection, thus unifying in one concept --the codimension-- all the diverse dynamical phenomena, including the global ones, such as the non-hyperbolic periodic orbits, homoclinic and heteroclinic orbits, and not only the punctual ones, such as the singularities. The suitable approach to express this structure had to include the mathematical objects such as those appearing in Kupka's lecture: infinite dimensional manifolds with tangent spaces that could be used to express infinitesimally the transversal crossing with ${\mathcal X}_1^r$. The expression in paper form of this intuition had to wait some years to see the light \cite{s}. I will mention only two other lectures: \newline - M. Peixoto, An elementary proof of the Euler-Poincar\' e formula on Surfaces (``Uma prova elementar da formula de Euler-Poincar\' e em Superf\'\i cies''). \newline - Charles Pugh, ``The Closing Lemma''. This Lemma is in fact an open problem whose statement for class $C^s$ and dimension $n$ is as follows: \newline {\it ``Every $C^r$ vector field on a compact n-dimensional manifold $M$ having a non trivial recurrent through $p \in M$ orbit can be arbitrarily approximated in the $C^s , s \leq r, $ topology by one which has through $p$ a periodic orbit."} In his lecture for the 1963 Colloquium Pugh presented a particular case for $n=2$ and $s=1$. Later he extended his analysis for arbitrary $n$. Carlos Gutierrez made remarkable contributions to the case of $n=2, \, s>1$, where, it is still open, in most non- orientable surfaces \cite{gutierrez_closing}. \\ The Closing Lemma Problem is a question that stems form Peixoto's works. {\bf Proportionally, regarding by subjects, the presence of Structural Stability and related topics --the school founded by Peixoto-- in the ensemble of presentations in the IV Brazilian Mathematical Colloquium was overwhelming.} \section{A thesis project based on the good problem in \ref{good_problem}.} \label{thesis} By the end of November 1963, the fellow that, on March 1962 had arrived to IMPA with a bookish mathematical knowledge \cite{encounters}, seemed somewhat distant. Prompted by the unfolding of Peixoto's Seminar, specially by the ODE Open Problems Session, outlined in Sec. \ref{list_english}, he had experienced an upgrade on the amplitude of his mathematical imagery and on the profundity and extension of his knowledge. The readings performed and the mathematical events at the IV Bras. Math. Colloq., outlined in Sect. \ref{cbm} had a radical influence on his view of the problems of Peixoto presented in Sec. \ref{list_english}. \vspace{0.3cm} It was clear then that Problems $1$ and $2$ of Peixoto's List were linked by the differentiable structure of the extended class of Andronov - Leontovich that I denoted ${\Sigma}_1^r$. The detailed analysis of this structure, however, depended on making it explicit in several instances. Peixoto agreed with my doctoral dissertation project consisting on the extension to surfaces of the class ${\Sigma}_1^r$, its smooth structure and its density inside ${\mathcal X}_1^r$. An explicit counter example for the generic finitude of planar bifurcations was easy to find, reconsidering in terms of transversality and further elaborating the results concisely expressed by the Russian pioneers. See Sotomayor \cite{IMUNI}. \section { The 1964 mathematical works.} \label{works_64} In the written composition of my doctoral thesis (DT) was deposited most of what I had learned along 1962 - 63: \\ The Calculus in Banach spaces and manifolds,\\ The invariant manifolds {\it a la} Coddington-Levinson,\\ The Structural Stability papers of Peixoto,\\ The personal digest I had scribbled on the understanding of Andronov - Leontovich (AL) announcement note \cite{al}. Keeping in mind the analogy with the previous works of Andronov and Pontrjagin, as improved by Peixoto, the note of AL, \cite{al_38}, can be outlined as consisting of: 1.- An axiomatic definition for the class ${\Sigma }_1^r$ as the part of ${\mathcal X}_1^r$ = ${\mathcal X}^r$${\backslash}$${\Sigma}^r$ that violate minimally the conditions of Andronov- Pontrjagin and Peixoto that define ${\Sigma}^r$. 2.- A definition of the class ${\mathcal S}_1^r$ of the systems in ${\mathcal X}_1^r$ that are structurally stable under small perturbations inside ${\mathcal X}_1^r$. 3.- The statement identifying ${\Sigma }_1^r$ with ${\mathcal S}_1^r$. I transliterated the terminology for the systems in \cite{al_38} as being ``first order structurally stable". However Russian translators use the name : ``first order structurally unstable''. In fact, they are the ``most stable among the unstable ones". See Andronov-Leontovich et al \cite{al}, where the proofs of the planar theorems of (AP) and (AL) were published in 1971. The programatic analogy between Andronov - Leontovich and Andronov - Pontryagin, in planar domains, is clear. It strikes as natural to extend it to Peixoto's surface domains. However, DT takes this analogy further and prepares the way for a geometric synthesis of the Generic Bifurcations. In fact, it establishes the openness and density of ${\mathcal S}_1 ^r$ relative to the sub-space ${\mathcal X}_1^r$. It also endows it with the structure of smooth co-dimension one sub-manifold of the Banach space ${\mathcal X}^r$. This last, analytic and geometric, aspect of DT has no parallel in the Russian works on the subject. It makes possible to regard geometrically the simple bifurcations as the points of transversal intersection of a curve of systems with the sub-manifold ${\Sigma}_1^r$. In DT are calculated the tangent spaces to each piece of ${\Sigma}_1^r$. For the cases of the homoclinic and heteroclinic connections of saddle points, the functional whose kernel defines the pertinent tangent space, is expressed in terms of an improper convergent integral, which corresponds to the Melnikov Integral when restricted to vector fields, i.e. autonomous systems. In 1964 no reference was known to me. Sotomayor \cite{S} contains a study of the characterization of First Order Structural Stability in terms of Regularity of ${\mathcal X}_1^r$. \vskip 0.3cm The work of Ivan Kupka achieved celebrity after Peixoto published \cite{peixoto_k}, which unified the versions of Smale, for diffeomorphisms, and that of Kupka, for flows, and coined the name {\it Kupka-Smale Systems} for those systems whose singularities and periodic orbits are all hyperbolic and all pairs of associated stable and unstable manifolds meet transversally. This work of Peixoto provided me with the language and methods that I had missed in 1964, for the extension of the class of Andronov Leontovich to a strictly larger immersed manifold, containing properly the imbedded one, whose structure was established in DT. Concerning this immersed manifold, the transversality to it gives the generic position of an arc with a dense, in ${\mathcal X}_1 ^r$, smooth part. See Sotomayor \cite{s}. \vskip 0.3cm The work of Aristides Barreto studied the systems of the form $x' = y, y' = f(x,y)$, with $f$ periodic in $x$. There, he characterized those which are structurally stable. As far as I know this is the first work on Structural Stability on non compact manifolds, the cylinder in this case. In \cite{s2} I presented a compact version of the solution problem \ref{p5} in Peixoto's list. \section{Concluding Comments. \label{con_com} } \subsection{ Timeline focused in this essay, with some extrapolation.} Looking in retrospect one may be tempted to think that some of the subjects presented in the seminar, Sec. \ref{seminar}, had, already in 1962-63, some {\it scent of a distant past.} However, it cannot be denied that they also glimpsed into the future. In fact, for the next three or more decades, they had current interest for an active line for research training to work in Dynamical Systems, touching its kernel. Fundamental work on these subjects was done along the forthcoming years, reaching relatively recent ones. On this matter allow me to evoke the following universal words: \begin{verse} {\it If we wish to foresee the future of mathematics, \\our proper course is to study the history and\\ present condition of the science. For us mathematicians, \\is not this procedure to some extent professional? \\We are accustomed to extrapolation, which is a method \\of deducing the future from the past and the present; \\and since we are well aware of its limitations, we run no risk \\of deluding ourselves as to the scope of the results it gives us.} \\H. Poincar\' e, in The Future of Mathematics, \\read by G. Darboux in Rome, ICM, 1908. \end{verse} \vspace{0.5cm} \begin{figure}[!ht] \begin{center} \vspace{-0.5cm} \includegraphics[scale=0.50]{timeline_lista_1.pdf} \caption{{\bf Timeline with colored landmarks, weighted by the size of stars, with organizing center on the years $1962 - 64$.} \newline {\small Brazil (red): Peixoto' s works, Seminar and Symposium;\newline France (black): Poincar\'e QTDE;\newline Russia (blue): The Gorkii School Landmark; \newline USA (green): Lefschetz, 1949-52, and Smale, Visit to IMPA, 1961, Seminar in Berkeley: 1966-67, and his landmark papers Differentiable Dynamical System, 1967, and What is Global Analysis?, 1969. }} \label{Fig:02_1} \end{center} \end{figure} \vspace{ -0.0cm} \subsection{ Some Inquisitive comments.} The mathematical concept of Structural Stability could hardly have stemmed, in isolation, in the offices of Mathematicians, pure or applied, or in the laboratories of Physicists or at the workshops of Engineers. Something deeper and innovative happened in the collaboration of Andronov and Pontrjagin. An effective collaboration involves the intellectual affinity of sprits. In this case, involving Andronov, Physicist, with exceptional mathematical knowledge, engaged in the research of the modeling of mechanisms, \cite{ gorelik}, and Pontrjagin, distinguished Mathematician, with remarkable contributions in Topology, interested in engaging himself in applied problems, \cite{pontryagin}. How do the transition from concrete examples and technological needs are processed into seminal mathematical concepts and, afterwards, to pertinent theorems? This is a central question of the Psychology of the Creative Process, whose basis and analysis have been addressed by \cite{hadamard} and \cite{koestler}, among others. \begin{verse} ``$\cdots$ {\it The creative act, by connecting previously unrelated dimensions of experience, enables the authors to attain a higher level of mental evolution. It is an act of liberation -- the defeat of habit by originality."} \\ {\small A. Koestler, (1964). The Act of Creation, (p. 96). London: Hutchinson and Co.} \end{verse} However, once formulated in the domain of Mathematics, the concepts and theorems are amenable to generalizations, extensions and refinements, in style and essence. Thus, they allow their elaboration by Mathematicians, with their phantasies and the creative flight of their imagination. There are several stages in this transition in the realm of the evolution of mathematical ideas around Structural Stability, its extensions and generalizations. Maybe the first one, after the Russian pioneers, is that of Solomon Lefschetz, responsible for its diffusion in the West and for coining its expressive name, re-baptizing, the original Robust Systems given by the pioneers \cite{a_L}. On this line of presentation, besides Peixoto, already cited, the names os Smale, Anosov, Arnold, Thom and Mather, among others, should be mentioned, thus extrapolating the realm of Differential Equations and Dynamical Systems. What, in an attempt of expository simplification, I referred to above as the outcome of the encounter of two distinct mathematical cultures: knowledgable expertise and mathematical talent, \cite{gorelik}, \cite {pontryagin}, may, perhaps, be better explained in the delicate threshold between Mathematics and Art. \begin{verse} {\it Mathematics, rightly viewed, possesses not only truth,\\ but supreme beauty, a beauty cold and austere, \\ like that of sculpture, without appeal to any part of our weaker nature, \\without the gorgeous trappings of painting or music, yet sublimely pure, \\ and capable of a stern perfection such as only the greatest art can show.}\\ B. Russell, (1919) "The Study of Mathematics", Mysticism and Logic \\ and Other Essays. Longman. p. 60. \end{verse} The mathematical and philosophical implications of Structural Stability, can be appreciated in its extensions to higher dimensional Dynamical Systems and to other domains of the Analysis on Manifolds, such as the Singularities of Differentiable Mappings and the Theory of Catastrophes, \cite{thom} \cite{sing_76}, and Multiparametric Bifurcations, \cite{DRSe} \cite{DRSz} \cite{cusp_loops}, as well as to Classical Differential Geometry, such as the configurations of principal curvature lines and umbilic points on surfaces \cite{sg}, \cite{monge}, \cite{ga_so}, \cite{A_M}. \vskip 0.5cm \noindent {\bf Aknowledgement. } Thanks are due to Lev Lerman for sending me a copy of \cite{gorelik}, to Misha Dokuchaev for helping in its translation and to Maria Lucia Alvarenga for kindly lending the photos in Figs. \ref{Fig:02} and \ref{Fig:01}.
\section{Introduction} Speech synthesis makes machines generate speech signals, and text-to-speech (TTS) conditions speech generation on input linguistic contents. Current TTS systems use statistical models like deep neural networks to map linguistic/prosodic features extracted from text to an acoustic representation. This acoustic representation typically comes from a vocoding process of the speech waveforms, and it is decoded into waveforms again at the output of the statistical model~\cite{zen2015acoustic}. To build the linguistic to acoustic mapping, deep network TTS models make use of a two-stage structure~\cite{ze2013statistical}. The first stage predicts the number of frames (duration) of a phoneme to be synthesized with a duration model, whose inputs are linguistic and prosodic features extracted from text. In the second stage, the acoustic parameters of every frame are estimated by the so-called acoustic model. Here, linguistic input features are added to the phoneme duration predicted in the first stage. Different works use this design, outperforming previously existing statistical parametric speech synthesis systems with different variants in prosodic and linguistic features, as well as perceptual losses of different kinds in the acoustic mapping~\cite{lu2013combining, qian2014training, hu2015fusion, hu2014investigation, kang2013multi}. Since speech synthesis is a sequence generation problem, recurrent neural networks (RNNs) are a natural fit to this task. They have thus been used as deep architectures that effectively predict either prosodic features~\cite{pascual2016prosodic, chen1998rnn} or duration and acoustic features~\cite{achanta2015investigation,wuinvestigating,fernandez2014prosody,zen2015unidirectional,pascual2016multi}. Some of these works also investigate possible performance differences using different RNN cell types, like long short-term memory (LSTM)~\cite{hochreiter1997long} or gated recurrent unit~\cite{chung2014empirical} modules. In this work, we propose a new acoustic model, based on part of the Transformer network~\cite{vaswani2017attention}. The original Transformer was designed as a sequence-to-sequence model for machine translation. Typically, in sequence-to-sequence problems, RNNs of some sort were applied to deal with the conversion between the two sequences~\cite{sutskever2014sequence,bahdanau2014neural}. The Transformer substitutes these recurrent components by attention models and positioning codes that act like time stamps. In~\cite{vaswani2017attention}, they specifically introduce the self-attention mechanism, which can relate elements within a single sequence without an ordered processing (like RNNs) by using a compatibility function, and then the order is imposed by the positioning code. The main part we import from that work is the encoder, as we are dealing with a mapping between two sequences that have the same time resolution. We however call this part the decoder in our case, given that we are decoding linguistic contents into their acoustic codes. We empirically find that this Transformer network is as competitive as a recurrent architecture, but with faster inference/training times. This paper is structured as follows. In section~\ref{sec:satt}, we describe the self-attention linguistic-acoustic decoder (SALAD) we propose. Then, in section~\ref{sec:exp_setup}, we describe the followed experimental setup, specifying the data, the features, and the hyper-parameters chosen for the overall architecture. Finally, results and conclusions are shown and discussed in sections~\ref{sec:results} and~\ref{sec:conclusions}, respectively. The code for the proposed model and the baselines can be found in our public repository~\footnote{https://github.com/santi-pdp/musa\_tts}. \section{Self-Attention Linguistic-Acoustic Decoder} \label{sec:satt} To study the introduction of a Transformer network into a TTS system, we employ our previous multiple speaker adaptation (MUSA) framework~\cite{pascual2016multi, pascual2016deep, pascual2016alpha}. This is a two-stage RNN model influenced by the work of Zen~and~Sak~\cite{zen2015unidirectional}, in the sense that it uses unidirectional LSTMs to build the duration model and the acoustic model without the need of predicting dynamic acoustic features. A key difference between our works and~\cite{zen2015unidirectional} is the capacity to model many speakers and adapt the acoustic mapping among them with different output branches, as well as interpolating new voices out of their common representation. Nonetheless, for the current work, we did not use this multiple speaker capability and focused on just one speaker for the new architecture design on improving the acoustic model. The design differences between the RNN and the transformer approaches are depicted in figure~\ref{fig:rnn_vs_salad}. In the MUSA framework with RNNs, we have a pre-projection fully-connected layer with a ReLU activation that reduces the sparsity of linguistic and prosodic features. This embeds the mixture $\ve{x}_t$ of different input types into a common representation $\ve{h}_t$ in the form of one vector per time step $t$. Hence, the transformation $\mathbb{R}^{L} \rightarrow \mathbb{R}^{H}$ is applied independently at each time step $t$ as \begin{equation*} \label{eq:emb} \ve{h}_{t} = \max(0, \ve{W}\ve{x}_{t} + \ve{b}), \end{equation*} where $\ve{W} \in \mathbb{R}^{H\times L}$, $\ve{b} \in \mathbb{R}^H$, $\ve{x}_t \in \mathbb{R}^L$, and $\ve{h}_t \in \mathbb{R}^H$. After this projection, we have the recurrent core formed by an LSTM layer of size $H$ and an additional LSTM output layer. The MUSA-RNN output is recurrent, as this prompted better results than using dynamic features to smooth cepstral trajectories in time~\cite{zen2015unidirectional}. \begin{figure*}[t] \centering \includegraphics[width=0.7\linewidth]{rnn_vs_salad} \caption{\label{fig:rnn_vs_salad} Transition from RNN/LSTM acoustic model to SALAD. The embedding projections are the same. Positioning encoding introduces sequential information. The decoder block is stacked $N$ times to form the whole structure replacing the recurrent core. FFN: Feed-forward Network. MHA: Multi-Head Attention.} \end{figure*} Based on the Transformer architecture~\cite{vaswani2017attention}, we propose a pseudo-sequential processing network that can leverage distant element interactions within the input linguistic sequence to predict acoustic features. This is similar to what an RNN does, but discarding any recurrent connection. This will allow us to process all input elements in parallel at inference, hence substantially accelerating the acoustic predictions. In our setup, we do not face a sequence-to-sequence problem as stated previously, so we only use a structure like the Transformer encoder which we call a linguistic-acoustic decoder. The proposed SALAD architecture begins with the same embedding of linguistic and prosodic features, followed by a positioning encoding system. As we have no recurrent structure, and hence no processing order, this positioning encoding system will allow the upper parts of the network to locate their operating point in time, such that the network will know where it is inside the input sequence~\cite{vaswani2017attention}. This positioning code $\ve{c}\in\mathbb{R}^H$ is a combination of harmonic signals of varying frequency: \begin{equation*} \begin{aligned} \label{eq:pos_code} &c_{t, 2i} = \sin\left(t/10000^\frac{2i}{H}\right)\\ &c_{t, 2i+1} = \cos\left(t/10000^\frac{2i}{H}\right) \end{aligned} \end{equation*} where $i$ represents each dimension within $H$. At each time-step $t$, we have a unique combination of signals that serves as a time stamp, and we can expect this to generalize better to long sequences than having an incremental counter that marks the position relative to the beginning. Each time stamp $\ve{c_t}$ is summed to each embedding $\ve{h_t}$, and this is input to the decoder core. The decoder core is built with a stack of $N$ blocks, depicted within the dashed blue rectangle in figure~\ref{fig:rnn_vs_salad}. These blocks are the same as the ones proposed in the decoder of~\cite{vaswani2017attention}, but we only have self-attention modules to the input, so it looks more like the Transformer encoder. The most salient part of this type of block is the multi-head attention (MHA) layer. This applies $h$ parallel self-attention layers, which can have a more versatile feature extraction than a single attention layer with the possibility of smoothing intra-sequential interactions. After the MHA comes the feed-forward network (FFN), composed of two fully-connected layers. The first layer expands the attended features into a higher dimension $d_{\text{ff}}$, and this gets projected again to the embedding dimensionality $H$. Finally, the output layer is a fully-connected dimension adapter such that it can convert the hidden dimensions $H$ to the desired amount of acoustic outputs, which in our case is 43 as discussed in section~\ref{sec:ling_aco_feats}. As stated earlier, we may slightly degrade the quality of predictions with this output topology, as recurrence helps in the output layer capturing better the dynamics of acoustic features. Nonetheless, this can suffice our objective of having a highly parallelizable and competitive system. \section{Experimental Setup} \label{sec:exp_setup} \subsection{Dataset} For the experiments we use utterances of speakers from the TCSTAR project dataset~\cite{bonafonte2006tc}. This corpora includes sentences and paragraphs taken from transcribed parliamentary speech and transcribed broadcast news. The purpose of these text sources is twofold: enrich the vocabulary and facilitate the selection of the sentences to achieve good prosodic and phonetic coverage. For this work, we choose the same male (M1) and female (F1) speakers as in our previous works. These two speakers have the most amount of data among the available ones. Their amount of data is balanced with approximately the following durations per split for both: 100 minutes for training, 15 minutes for validation, and 15 minutes for test. \subsection{Linguistic and Acoustic Features} \label{sec:ling_aco_feats} The decoder maps linguistic and prosodic features into acoustic ones. This means that we first extract hand-crafted features out of the input textual query. These are extracted in the label format, following our previous work in~\cite{pascual2016deep}. We thus have a combination of sparse identifiers in the form of one-hot vectors, binary values, and real values. These include the identity of phonemes within a window of context, part of speech tags, distance from syllables to end of sentence, etc. For more detail we refer to~\cite{pascual2016deep} and references therein. For a textual query of $N$ words, we will obtain $M$ label vectors, $M \geq N$, each with 362 dimensions. In order to inject these into the acoustic decoder, we need an extra step though. As mentioned, the MUSA testbed follows the two-stage structure: (1) duration prediction and (2) acoustic prediction with the amount of frames specified in first stage. Here we are only working with the acoustic mapping, so we enforce the duration with labeled data. For this reason, and similarly to what we did in previous works~\cite{pascual2016multi,pascual2016alpha}, we replicate the linguistic label vector of each phoneme as many times as dictated by the ground-truth annotated duration, appending two extra dimensions to the 362 existing ones. These two extra dimensions correspond to (1) absolute duration normalized between 0 and 1, given the training data, and (2) relative position of current phoneme inside the absolute duration, also normalized between 0 and 1. We parameterize the speech with a vocoded representation using Ahocoder~\cite{erro2011improved}. Ahocoder is an harmonic-plus-noise high quality vocoder, which converts each windowed waveform frame into three types of features: (1) mel-frequency cepstral coefficients (MFCCs), (2) log-F0 contour, and (3) voicing frequency (VF). Note that F0 contours have two states: either they follow a continuous envelope for voiced sections of speech, or they are 0, for which the logarithm is undefined. Because of that, Ahocoder encodes this value with $-10^{9}$, to avoid numerical undefined values. This result would be a cumbersome output distribution to be predicted by a neural net using a quadratic regression loss. Therefore, to smooth the values out and normalize the log-F0 distribution, we linearly interpolate these contours and create an extra acoustic feature, the unvoiced-voiced flag (UV), which is the binary flag indicating the voiced or unvoiced state of the current frame. We will then have an acoustic vector with 40~MFCCs, 1~log-F0, 1~VF, and 1~UV. This equals a total number of 43~features per frame, where each frame window has a stride of 80 samples over the waveform. Real-numbered linguistic features are Z-normalized by computing statistics on the training data. In the acoustic feature outputs, all of them are normalized to fall within $[0, 1]$. \subsection{Model Details and Training Setup} \label{sec:model_details} We have two main structures: the baseline MUSA-RNN and SALAD. The RNN takes the form of an LSTM network for their known advantages of avoiding typical vanilla RNN pitfalls in terms of vanishing memory and bad gradient flows. Each of the two different models has two configurations, small (Small RNN/Small SALAD) and big (Big RNN/Big SALAD). This intends to show the performance difference with regard to speed and distortion between the proposed model and the baseline, but also their variability with respect to their capacity (RNN and SALAD models of the same capacity have an equivalent number of parameters although they have different connexion topologies). Figure~\ref{fig:rnn_vs_salad} depicts both models' structure, where only the size of their layers (LSTM, embedding, MHA, and FFN) changes with the mentioned magnitude. Table~\ref{tab:models_magnitudes} summarizes the different layer sizes for both types of models and magnitudes. \begin{table}[t] \caption{Different layer sizes of the different models. Emb: linear embedding layer, and hidden size $H$ for SALAD models in all layers but FFN ones. HidRNN: Hidden LSTM layer size. $d_{\text{ff}}$: Dimension of the feed-forward hidden layer inside the FFN.} \label{tab:models_magnitudes} \centering \setlength{\tabcolsep}{5pt} \begin{tabular}{lcccc} \toprule \textbf{Model} & \textbf{Emb} & \textbf{HidRNN} & $\textbf{d}_{\text{ff}}$ \\ \midrule Small RNN & 128 & 450 & - \\ Small SALAD & 128 & - & 1024 \\ Big RNN & 512 & 1300 & - \\ Big SALAD & 512 & - & 2048 \\ \bottomrule \end{tabular} \end{table} Both models have dropout~\cite{srivastava2014dropout} in certain parts of their structure. The RNN models have it after the hidden LSTM layer, whereas the SALAD model has many dropouts in different parts of its submodules, replicating the ones proposed in the original Transformer encoder~\cite{vaswani2017attention}. The RNN dropout is 0.5, and SALAD has a dropout of 0.1 in its attention components and 0.5 in FFN and after the positioning codes. Concerning the training setup, all models are trained with batches of 32 sequences of 120 symbols. The training is in a so-called stateful arrangement, such that we carry the sequential state between batches over time (that is, the memory state in the RNN and the position code index in SALAD). To achieve this, we concatenate all the sequences into a very long one and chop it into 32 long pieces. We then use a non-overlapped sliding window of size 120, so that each batch contains a piece per sequence, continuous with the previous batch. This makes the models learn how to deal with sequences longer than 120 outside of train, learning to use a conditioning state different than zero in training. Both models are trained for a maximum of 300 epochs, but they trigger a break by early-stopping with the validation data. The validation criteria for which they stop is the mel cepstral distortion (MCD; discussed in section~\ref{sec:results}) with a patience of 20 epochs. Regarding the optimizers, we use Adam~\cite{kingma2014adam} for the RNN models, with the default parameters in PyTorch ($\text{lr}=0.001$, $\beta_1=0.9$, $\beta_2=0.999$, and $\epsilon=10^{-8}$). For SALAD we use a variant of Adam with adaptive learning rate, already proposed in the Transformer work, called Noam~\cite{vaswani2017attention}. This optimizer is based on Adam with $\beta_1=0.9$, $\beta_2=0.98$, $\epsilon=10^{-9}$ and a learning rate scheduled with \begin{equation*} \text{lr} = H^{-0.5} \cdot \min(s^{-0.5}, s \cdot w^{-1.5}) \end{equation*} where we have an increasing learning rate for $w$ warmup training batches, and it decreases afterwards, proportionally to the inverse square root of the step number $s$ (number of batches). We use $w=4000$ in all experiments. The parameter $H$ is the inner embedding size of SALAD, which is $128$ or $512$ depending on whether it is the small or big model as noted in table~\ref{tab:models_magnitudes}. We also tested Adam on the big version of SALAD, but we did not observe any improvement in the results, so we stick to Noam following the original Transformer setup. \section{Results} \label{sec:results} In order to assess the distortion introduced by both models, we took three different objective evaluation metrics. First, we have the MCD measured in decibels, which tells us the amount of distortion in the prediction of the spectral envelope. Then we have the root mean squared error (RMSE) of the F0 prediction in Hertz. And finally, as we introduced the binary flag that specifies which frames are voiced or unvoiced, we measure the accuracy (number of correct hits over total outcomes) of this binary classification prediction, where classes are balanced by nature. These metrics follow the same formulations as in our previous works~\cite{pascual2016multi,pascual2016deep,pascual2016alpha}. Table~\ref{tab:obj_results} shows the objective results for the systems detailed in section~\ref{sec:model_details} over the two mentioned speakers, M and F. For both speakers, RNN models perform better than the SALAD ones in terms of accuracy and error. Even though the smallest gap, occurring with the SALAD biggest model, is 0.3\,dB in the case of the male speaker and 0.1\,dB in the case of the female speaker, showing the competitive performance of these non-recurrent structures. On the other hand, Figure~\ref{fig:cpu_speed} depicts the inference speed on CPU for the 4 different models synthesizing different utterance lengths. Each dot in the plot indicates a test file synthesis. After we collected the dots, we used the RANSAC~\cite{fischler1981random} algorithm (Scikit-learn implementation) to fit a linear regression robust to outliers. Each model line shows the latency uprise trend with the generated utterance length, and RNN models have a way higher slope than the SALAD models. In fact, SALAD models remain pretty flat even for files of up to 35\,s, having a maximum latency in their linear fit of 5.45\,s for the biggest SALAD, whereas even small RNN is over 60\,s. We have to note that these measurements are taken with PyTorch~\cite{paszke2017automatic} implementations of LSTM and other layers running over a CPU. If we run them on GPU we notice that both systems can work in real time. It is true that SALAD is still faster even in GPU, however the big gap happens on CPUs, which motivates the use of SALAD when we have more limited resources. \begin{table}[t] \caption{Male (top) and female (bottom) objective results. A:~voiced/unvoiced accuracy.} \label{tab:obj_results} \centering \setlength{\tabcolsep}{4pt} \begin{tabular}{lcccc} \toprule \textbf{Model} & \textbf{\#Params} & \textbf{MCD [dB]} & \textbf{F0 [Hz]} & \textbf{A [\%]} \\ \midrule Small RNN & 1.17\,M & 5.18 & 13.64 & 94.9 \\ Small SALAD & 1.04\,M & 5.92 & 16.33 & 93.8 \\ Big RNN & 9.85\,M & 5.15 & 13.58 & 94.9 \\ Big SALAD & 9.66\,M & 5.43 & 14.56 & 94.5 \\ \midrule Small RNN & 1.17\,M & 4.63 & 15.11 & 96.8 \\ Small SALAD & 1.04\,M & 5.25 & 20.15 & 96.4 \\ Big RNN & 9.85\,M & 4.73 & 15.44 & 96.9 \\ Big SALAD & 9.66\,M & 4.84 & 19.36 & 96.6 \\ \bottomrule \end{tabular} \end{table} We can also check the pitch prediction deviation, as it is the most affected metric with the model change. We show the test pitch histograms for ground truth, big RNN and big SALAD in figure~\ref{fig:f0_hist}. There we can see that SALAD's failure is about focusing on the mean and ignoring the variance of the real distribution more than the RNN does. It could be interesting to try some sort of short-memory non-recurrent modules close to the output to alleviate this peaky behavior that makes pitch flatter (and thus less expressive), checking if this is directly related to the removal of the recurrent connection in the output layer. Audio samples are available online as qualitative results at http://veu.talp.cat/saladtts . \begin{figure}[t] \includegraphics[width=0.95\linewidth]{rnn_vs_salad_f0_hist} \caption{\label{fig:f0_hist} F0 contour histograms of ground-truth speech, bigRNN and bigSALAD for male speaker.} \end{figure} \begin{figure}[t] \includegraphics[width=0.95\linewidth]{cpu_speed} \caption{\label{fig:cpu_speed} Inference time for the four different models with respect to generated waveform length. Both axis are in seconds.} \end{figure} \begin{table}[t!] \caption{Maximum inference latency with RANSAC fit.} \label{tab:ransac} \centering \setlength{\tabcolsep}{5pt} \begin{tabular}{lcc} \toprule \textbf{Model} & \textbf{Max.~latency [s]} \\ \midrule Small RNN & 63.74 \\ Small SALAD & 4.715 \\ Big RNN & 64.84 \\ Big SALAD & 5.455 \\ \bottomrule \end{tabular} \end{table} \section{Conclusions} \label{sec:conclusions} In this work we present a competitive and fast acoustic model replacement for our MUSA-RNN TTS baseline. The proposal, SALAD, is based on the Transformer network, where self-attention modules build a global reasoning within the sequence of linguistic tokens to come up with the acoustic outcomes. Furthermore, positioning codes ensure the ordered processing in substitution of the ordered injection of features that RNN has intrinsic to its topology. With SALAD, we get on average over an order of magnitude of inference acceleration against the RNN baseline on CPU, so this is a potential fit for applying text-to-speech on embedded devices like mobile handsets. Further work could be devoted on pushing the boundaries of this system to alleviate the observed flatter pitch behavior. \section{Acknowledgements} This research was supported by the project TEC2015-69266-P (MINECO/FEDER, UE). \clearpage \balance \bibliographystyle{IEEEtran} \section{Experimental Setup} \label{sec:experiments} \subsection{Dataset} The experiments are performed with a professional male speaker from the TCSTAR~\cite{bonafonte2006tc} dataset, thus with recording studio quality. We have 7.5 hours of speech from this speaker, which are divided in $80\%$ for training, $10\%$ for validation and $10\%$ for test. \subsection{Neural Vocoder Architecture Setup} Several experiments with the unconditioned SampleRNN have been done to define the architecture and the optimizer parameters to be used in the remaining experiments in our TTS system. All experiments are conducted with a batch size of 128 sequences of length 1040. As shown in figure~\ref{fig:framernn}, the selected architecture has three tiers. The higher tier is composed of 2 GRU layers. The input is 80 samples (5 ms. at 16kHz) and the output is the condition to the mid tier. The conditioner is expanded into 5 conditioning vectors through a 1D convolutional layer. The mid tier is also composed of 2 GRU layers. In this case the input is formed by 16 samples in addition to the previous conditioning vector. Finally, the lowest tier contains a MLP with one hidden layer. Owing to the fact that SampleRNN predicts discrete categories corresponding to quantized sample values at 8 bits, we have an output layer of 256 units. Note that all recurrent and fully connected layers contain 1024 units. \begin{figure}[!htpb] \centering \includegraphics[width=0.5\textwidth]{figures/framernn.pdf} \caption{Structure of the first two tiers of the system, with two RNN of 1024 hidden units. , a $FS=[20 \quad 4]$ and an up-sampling ratio of $r=4$. In the first tier we have an entry of 80 real valued samples and an activated conditioner flag. Both the input and the conditioner pass through their respective 1D convolution layer, and these outputs are linearly added. This will be the entrance to the first GRU, which will store the hidden state $h(k)$ to use it in the next tier as a conditioner. Then the output goes through the transposed convolution, performing the process of upsampling. Finally these output enters to the second frame-level. The input inp($k=2$) is conditioned under the previous stored memory in the upper tier, $h(k)_{t-1}$ state. From here is followed the same process as the previous tier. } \label{fig:framernn} \end{figure} The original SampleRNN used uniform quantization, so we decided to test the possible performance increase when we apply $\mu$-law transformation to reduce the quantization noise. Listening to the newly generated samples clearly show the advantage of the $\mu$-law transformed distribution over the raw one. \newpage As a final remark, the proposed vocoder system was built on top of a publicly available implementation of sampleRNN\footnote{https://github.com/deepsound-project/samplernn-pytorch} in PyTorch~\cite{paszke2017automatic}. \subsection{TTS System: MUSA and SampleRNN} \label{sec:results:SamplewithMusa} As we are focusing on the acoustic model, all the durations are forced to be the annotated ones in the ground truth. We want to test the performance of the coupling under three different configurations: \begin{itemize} \item Independent Neural Vocoder (INV). In this case SampleRNN is trained with the acoustic parameterization from original speech samples. \item Independently-trained MUSA-based Neural Vocoder (IMNV). For each utterance in the training corpus, we infer the acoustic parameter with the MUSA prediction. These parameters are used as training samples for our neural vocoder replacing previous ground truth samples coming from the original speech samples. \item Jointly-trained MUSA-based Neural Vocoder (JMNV). Same case as previous one but adding an additional training stage where the full joint model (MUSA+SampleRNN) is tuned end-to-end. \end{itemize} \subsection{Objective Evaluation} We observe an abrupt behavior of the all losses after certain epochs. We believe that the learning rate could be too big after that epoch, thus we decide to decrease the learning rate monotonically with a scheduler. This decays the initial learning rate by a $\gamma$ factor every $E$ epochs. Specifically, we set up an initial learning rate (lr) of $0.001$ with $\gamma = 0.1$. This way we have: \begin{equation} \left\{\begin{matrix} \textrm{lr} = 10^{-3}& \text{epoch} < 15 \\ \textrm{lr} = 10^{-4}& 15 \le \text{epoch} < 35\\ \textrm{lr} = 10^{-5}& \text{epoch} > 35 \end{matrix}\right. \end{equation} In table~\ref{tbl:optim} we show the difference in test performance among three different optimizer executions. The test metric is the negative log-likelihood (NLL). These results confirm the effectiveness of the designed scheduler, being Adam the preferred option over RMSprop and so the one with which we combine the scheduler to obtain the best result. \begin{table}[ht] \caption{Comparison of the different tested optimizers in terms of the negative log-likelihood (NLL) (lower is better).} \centering \label{tbl:optim} \begin{tabular}{c@{\hspace{1cm}}c} \toprule \textbf{Optimizer} & \textbf{Average NLL Test} \\ \midrule RMSprop & 3.19 \\ Adam & 2.56 \\ Adam+Scheduler & \textbf{2.41} \\ \bottomrule \end{tabular} \end{table} \begin{table}[!hbpt] \caption{Comparison of SampleRNN test performance under different configurations in terms of the negative log-likelihood (NLL) (lower is better).} \centering \label{tbl:musasamplernn} \begin{tabular}{c@{\hspace{1cm}}c} \toprule \textbf{Model Configuration} & \textbf{Average NLL Test} \\ \midrule INV & 2.41\\ IMNV & 2.67\\ IMNV pre-trained & 2.66\\ JMNV & 2.47\\\bottomrule \end{tabular} \end{table} As shown in the table~\ref{tbl:musasamplernn}, when we substitute the ground truth features (INV) with the ones predicted by MUSA (IMNV) there is a noticeable degradation in the test performance, as expected. We can slightly improve it by facilitating the convergence in a setup were IMNV is initialized with INV weights. Last row in the table shows how we can close the gap by tuning the joint structure (MUSA and SampleRNN) end-to-end. \subsection{Subjective Evaluation} \label{sec:Subjres} Objective tests performed well to compare different architectures and to suggest how well does the TTS work. But when analyzing the complete system, that is, the conditioned SampleRNN under the MUSA characteristics, we obtained similar results in all the performed experiments. To get a more in-depth evaluation of the model a subjective test is conducted to evaluate the naturalness of the TTS developed in this work and also to make a comparison with the baseline system, that is, Ahodecoder vocoder under MUSA parameterization. A web based application was developed with the selected audio files obtained from the experiments, explained below, and volunteers were asked to rate the voices in a scale from one to five, one being bad and five being excellent. In the test each listener was asked to evaluate 5 sentences, randomly selected from the test set. In total 14 subjects took the test. The participants could listen the different recordings as many times as required to make comparisons between the different systems and select which system or systems produce the most natural speech. For every sentence, the listeners evaluated 3 different versions generated with the following 3 different systems: \begin{itemize} \item Baseline: using Ahodecoder to generate speech from the acoustic parameters predicted by MUSA~\cite{pascual2016deep} (MAHO) \item Independently-trained MUSA-based Neural Vocoder (IMNV). \item Jointly-trained MUSA-based Neural Vocoder (JMNV). \end{itemize} Table \ref{tab:subj} shows the results of the subjective test. \begin{table}[!htpb] \caption{Preference test showing the best selected system or systems (in percentage).} \centering \begin{tabular}{@{}ccccc@{}}\toprule \shortstack{MAHO\\{~}} & \shortstack{IMNV\\{~}} & \shortstack{JMNV\\{~}} & \shortstack{JMNV OR\\MAHO} & \shortstack{JMNV\\IMNV}\\\midrule 21.4 & 4.3 & 51.4 & 14.3 & 8.6\\ \bottomrule \end{tabular} \label{tab:subj} \end{table} As it can be seen, independent training of MUSA and SampleRNN (IMNV) produces much worse results that the baseline system that uses the original decoder of Ahocoder (MAHO). MAHO is one of the preferred system in 50.0\% of the 70 evaluations, while IMNV is only one of the preferred systems in 12.9\% of the cases. However, the joint training of MUSA and SampleRNN effectively integrates both systems producing the best option. As we can see, JMNV is one of the systems in 74.3\% of the cases. The results IMNV are much worse than expected. An analysis of the result showed that there was a normalization problem that produced an inconsistency between MUSA prediction and the ground truth acoustic features. However, the results show that the joint training is able to overcome such limitation and is more robust to inconsistencies.
\section{INTRODUCTION} It is remarkable that Landau Fermi-liquid theory \cite{Landau56,*Landau58} applies to heavy-fermion systems where mass enhancements due to many body effects often exceed $O(10^2)$. It is understood that the reason for the renormalizations is the Kondo effect at each of the magnetic ions. This is described by the periodic Anderson model~\cite{VarmaYafet}, in which one of the charge states of the magnetic ions (usually $4f$ or $5f$) is well below the Fermi energy and another charge state is well above, being separated from the former by the local repulsion parameter~$U$. In contrast, in intermediate valence compounds two charge states are close to the Fermi energy, so that magnetic moment and charge fluctuations are equally important. Intermediate valence is therefore an even more subtle problem than Kondo-effect-induced heavy-fermion behavior. Novel properties like quantum criticality, non-Fermi-liquid behavior, and unconventional superconductivity originate in such systems due to the strong correlation between localized and itinerant electrons. Research on heavy-fermion superconductors can also help us to understand the pairing mechanism of unconventional superconductivity. It is important, therefore, to fully characterize the many-body effects in heavy-fermion and intermediate-valence compounds. The alloy system~Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$~\cite{Shu11,Booth11} offers a very good opportunity to do this. CeCoIn$_{5}$ has one of the highest superconducting transition temperatures (2.3~K) among heavy-fermion superconductors~\cite{Petrovic01a}. Quantum criticality is observed when the system is tuned by either pressure~\cite{Sidorov02} or magnetic field~\cite{Paglione03,Bianchi03b,Tanatar07,Hu12}. Investigation of the effect of Yb substitution for Ce on the structure and physical properties of CeCoIn$_5$ has been motivated by the electron-hole analogy between the Ce$^{3+}$ ($4f^1$) and Yb$^{3+}$ (4$f^{13}$) electronic configurations, together with the unstable valence~$\nu$ of Ce ($3{+}\leqslant$ $\nu_\mathrm{Ce}$ $\leqslant 4{+}$) and Yb ($2{+} \leqslant$ $\nu_\mathrm{Yb}$ $\leqslant 3{+}$)~\cite{Shu11,Booth11}. A number of remarkable phenomena have been observed in Ce$_{1-x}$Yb$_{x}$CoIn$_5$ throughout the entire range of nominal Yb composition~$x$~\cite{Shu11, Booth11, Mizukami11, White12, Shimozawa12, Polyakov12, Dudy13, Hu13, Jang14, Kim15, Erten15, Zhang15, Xu16}. The $T$-$x$ phase diagram is unconventional for heavy-fermion superconductors, in which the superconducting transition temperature~$T_c$ and the Kondo coherence temperature~$T_\mathrm{coh}$ do not track each other~\cite{Shu11}. Both $T_c$ and the $T = 0$ electronic specific heat coefficient~$\gamma_0$ are systematically suppressed with Yb doping~\cite{Shu11,Booth11}, but the suppression of $T_c$ is much less than for other rare-earth substitutions\cite{Petrovic02,Hu08}. While the Ce valence is near $3{+}$ for all $x$, the Yb valence is ${\sim}2.3+$ for $x \geqslant 0.3$ and increases rapidly with decreasing $x \leqslant 0.2$ towards $3+$ as $x \to 0$~\cite{Booth11,Dudy13}. We report results of muon spin relaxation ($\mu$SR) and specific heat measurements in Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$ alloys for $0 \leqslant x \leqslant 0.5$, and discuss their implications for the theory of heavy-fermion and intermediate-valence systems. The $\mu$SR data yield the magnetic penetration depth~$\Lambda(T)$, from which the superfluid density $\rho_s$ is obtained. With increasing $x$, $\rho_s$ initially decreases, as expected from the transition from heavy-fermion character to intermediate valence~\cite{Varma76}, and then remains constant for $x>0.2$ where the valence of Yb does not change. In agreement with a recent theory~\cite{Miyake18}, the renormalized temperature dependence of the superfluid density is similar to that of the specific heat, indicating that the temperature-dependent Fermi-liquid Landau parameters entering these two different physical quantities are the same. Transverse-field $\mu$SR (TF-$\mu$SR)~\footnote{I.e., $\mu$SR in a field applied perpendicular to the initial muon spin direction.} has been proved to be an effective probe of the magnetic field distribution in the vortex state of type II superconductors~\cite{Sonier00,Sonier07}. In a magnetic field~$B$, a muon spin precesses at the Larmor frequency~$\omega = \gamma_\mu B$, where $\gamma_\mu = 2\pi{\times}135.5342$~MHz/T is the muon gyromagnetic ratio, before decaying with a lifetime $\approx 2.2\ \mu$s into a positron and two neutrinos. The positron is emitted preferentially along the direction of the muon spin due to parity violation. The time evolution of the muon spin polarization is determined by detecting decay positrons from an ensemble of ${\sim}2 \times 10^7$ muon events. Under certain conditions of field and temperature~\cite{Sonier00,Sonier07}, the muon spin relaxation rate in the vortex state is given by $\gamma_\mu \delta B_\mathrm{rms}$, where $\delta B_\mathrm{rms} = \langle \delta B^2\rangle^{1/2}$ is the rms width of the field distribution in the flux-line lattice (FLL)\@. In the extreme Type-II or London limit ($\Lambda \gg \text{coherence length } \xi$) \begin{equation} \label{eq:Brandt} \langle\delta B^2\rangle = 0.00371 \, \Phi_0^2/\Lambda^4\,, \end{equation} where $\Phi_0$ is the flux quantum~\cite{Brandt88}. In turn, from the London equations $\Lambda$ is related to $\rho_s$ and the carrier effective mass~$m_\mathrm{eff}$ by \begin{equation} \label{eq:lambda1} \frac{1}{\Lambda^{2}} = \frac{4\pi e^2 \rho_s}{m_\mathrm{eff}c^2}\,. \end{equation} Thus TF-$\mu$SR experiments yield information on $\rho_s(T)$. \section{EXPERIMENT} High quality single crystals of Ce$_{1-x}$Yb$_{x}$CoIn$_5$, $x = 0, 0.05, 0.125, 0.2, 0.3, 0.4$, and $0.5$, were synthesized using an indium self-flux method~\cite{Zapf01}. After centrifuging and etching in HCl solution to remove excess indium, large thin plate-like single crystals were obtained. Crystal structures were verified by x-ray diffraction. Specific heat measurements were made down to 50~mK using a Quantum Design Physical Property Measurement System platform equipped with a dilution refrigerator. Transition temperatures~$T_c$ from these data were consistent with values reported in Refs.~\onlinecite{Shu11,Booth11}, confirming the Yb doping concentrations. Single crystals with flat $ab$ planes were selected, aligned, and glued onto a silver plate holder using dilute GE varnish, covering a $10{\times}10$~mm$^2$ area. $\mu$SR experiments were carried out using the M15 beam line at TRIUMF, Vancouver, Canada, in a top-loading dilution refrigerator with a base temperature of 20~mK\@. Spin-polarized positive muons were implanted into a sample in a transverse external magnetic field $\mu_0 H = 30$~mT [$H \ll H_{c2}(0)$]. The sample was field cooled into the superconducting state from above $T_c$. Typical TF-$\mu$SR asymmetry spectra from the normal and superconducting states of Ce$_{1-x}$Yb$_{x}$CoIn$_5$ are shown in Fig.~\ref{fig:Asy} for $x = 0.05$ and 0.125. \begin{figure}[ht] \includegraphics[width = 0.45\textwidth]{Asy.pdf} \caption{(Color online) $\mu$SR asymmetry spectra $A(t)$ from Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$, $\mu_0H = 30$ mT, $H \parallel c$. (a)~$x = 0.05$. (b)~$x = 0.125$. Red squares: normal state. Blue circles: superconducting state. Solid curves: fits to the data (see text).} \label{fig:Asy} \end{figure} Each spectrum consists of two contributions: a signal from muons stopping in the sample, and a background signal from muons that miss the sample and stop in the silver sample holder. In the superconducting state the damping of the sample signal is enhanced due to the field broadening generated by the FLL\@. The enhancement is smaller for the $x = 0.125$ sample, due to the depression of $\rho_s$ by Yb ions. The spectra from both undoped CeCoIn$_5$~\cite{Shu14} and the Yb-doped alloys are well fit using the function \begin{equation} \label{eq:Asy} \begin{split} A(t) = &\ A_0\bigl[f_s\exp(-\textstyle{\frac{1}{2}}\sigma_s^2t^2)\cos(\omega_s t+\phi_s)\\ & +(1-f_s)\textstyle{\exp(-\frac{1}{2}} \sigma_b^2t^2)\cos(\omega_b t+\phi_b)\bigr] \,, \end{split} \end{equation} where the first and second terms represent sample and background signals, respectively. Here $A_0$ is the initial asymmetry and $f_s$ is the fraction of muons that stop in the sample. The Gaussian relaxation rate $\sigma_s$ from the sample is due to nuclear dipolar fields in the normal state, and is enhanced in the superconducting state by the FLL field inhomogeneity. The precession frequency $\omega_s$ is reduced due to diamagnetic screening. The background relaxation rate $\sigma_b$ is negligibly small, and the initial phases $\phi_b$ and $\phi_s$ and the background frequency $\omega_b$ are constant. The curves in Fig.~\ref{fig:Asy} are fits to Eq.~(\ref{eq:Asy}). \section{RESULTS} Figure~\ref{fig:Rlx} shows the temperature dependencies of $\sigma_s$ in Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$ for $x = 0$ (data from Ref.~\onlinecite{Shu14}), 0.05, 0.125, 0.2, 0.3, 0.4, and 0.5. The arrows indicate $T_c$ determined from transport measurements~\cite{Shu11,Booth11}. \begin{figure}[ht] \begin{center} \includegraphics[width = 0.45\textwidth]{rate.pdf} \caption{(Color online) Temperature dependencies of TF-$\mu$SR relaxation rate~$\sigma_s$ in Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$, $\mu_0H = 30$ mT $\parallel c$. Data for $x = 0$ is from Ref.~\onlinecite{Shu14}. Solid curves: power-law fits to the data (see text). Arrows: $T_c$ from transport measurements~\cite{Shu11,Booth11}. Inset: flux-line lattice relaxation rate~$\sigma_{\rm FLL}$ from Eq.~(\protect\ref{eq:sigma}) vs normalized temperature $T/T_c$.} \label{fig:Rlx} \end{center} \end{figure} The common features of these data are (1)~the temperature independence of $\sigma_s$ above $T_c$, and (2)~a clear increase of $\sigma_s$ below $T_c$ due to the formation of the FLL. The internal field distribution in the vortex state is the convolution of the field distribution due to the vortex lattice and the nuclear dipolar field distribution of the host material: \begin{equation} \label{eq:sigma} \sigma_s^2 = \sigma_{\rm FLL}^2+\sigma_{\rm dip}^2, \end{equation} where $\sigma_{\rm dip}^2$ is temperature independent. Values of $\sigma_{\rm dip}$ for all $x$ are given in Table~\ref{table-A}. With increasing $x$, $\sigma_{\rm dip}$ initially increases slightly, due to a contribution from Yb nuclear dipolar fields. The small reduction of $\sigma_{\rm dip}$ for $x > 0.2$ might be due to a decrease in the contact (RKKY) interaction, since the Fermi surface starts to change at this Yb concentration~\cite{Polyakov12}. In the inset to Fig.~\ref{fig:Rlx}, $\sigma_{\rm FLL}(T)$ from Eq.~(\ref{eq:sigma}) is plotted vs reduced temperature $T/T_c$ for all $x$. The data can be fit with the power law \begin{equation} \label{eq:sigmaFLL} \sigma_{\rm FLL}(T) = \sigma_{\rm FLL}(0)\left[1-(T/T_c)^{n_\sigma}\right]\,, \quad T < T_c\,, \end{equation} with best-fit values of $\sigma_{\rm FLL}(0)$ and $n_\sigma$ that are listed in Table~\ref{table-A}. \begin{table*}[t] \caption{Parameters from fits to TF-$\mu$SR and specific-heat data from Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$. Muon nuclear dipolar relaxation rate~$\sigma_\mathrm{dip}$, $T{=}0$ muon FLL relaxation rate~$\sigma_\mathrm{FLL}(0)$, transition temperature~$T_c$, and power-law exponent~$n_\sigma$ from fits of Eq.~(\ref{eq:sigmaFLL}) to $\sigma_{\rm FLL}(T)$. The $T_c$ values for $x\geq0.2$ were fixed at values determined from heat capacity measurements. Zero-temperature penetration depth~$\Lambda(0)$ from Eq.~(\ref{eq:Brandt}). Specific-heat exponent~$n_\gamma$: from fits of power law~$C_{e} /T = \gamma_0 +aT^{\,n_\gamma}$ to specific heat data.}\label{table-A} \begin{ruledtabular} \begin{tabular}{lccccccc} $x$ & 0\footnote{\,$\mu$SR data from Ref.~\protect\onlinecite{Shu14}.} & 0.05 & 0.125 & 0.2 & 0.3 & 0.4 & 0.5\\ \hline $\sigma_{\rm dip}\ (\mu\text{s}^{-1})$ & 0.316(1) & 0.346(4) & 0.415(3) & 0.426(3) & 0.407(3) & 0.390(3) & 0.449(5)\\ $\sigma_{\rm FLL}(0)\ (\mu\text{s}^{-1})$ & 0.67(1) & 0.55(1)& 0.46(1)& 0.28(2) & 0.27(1) & 0.24(2)& 0.28(2)\\ $T_c$ (K) & 2.27(2) & 2.18(3) & 2.14(4) & 1.90 & 1.59 & 1.50 & 1.3\\ $n_\sigma$ & 2.4(2) & 3.1(2) & 2.6(3) & 2.3(6) & 2.8(4) & 1.7(4) & 2.8(6)\\ $\Lambda (0)$ ($\mu$m) & 0.386(3) & 0.441(4) & 0.483(5) & 0.62(2) & 0.63(1) & 0.67(3) & 0.61(2) \\ $n_{\gamma}$\footnote{Specific heat data from Ref.~\onlinecite{Shu11} and the present measurements.} & 2.20(5) & 2.54(1) & 2.69(2) & &2.49(5) & & \\ \end{tabular} \end{ruledtabular} \end{table*} The values of $T_c$ are consistent with results of transport measurements~\cite{Shu11,Booth11}. The zero-temperature penetration depths~$\Lambda(0)$ obtained from Eq.~(\ref{eq:Brandt}) are also listed in Table~\ref{table-A}. Previous results~\cite{DeBeer-Schmitt06,Xu16} yield coherence lengths in Ce$_{1-x}$Yb$_{x}$CoIn$_5$ shorter than 82~\AA\@. Comparison with penetration depths from Table~\ref{table-A} shows that the entire alloy system is in the extreme Type-II region, as is necessary for the applicability of Eq.~(\ref{eq:Brandt}). The normalized zero-temperature superfluid densities~$\rho_0(x)/\rho_0(0) = \Lambda_0^2(0)/\Lambda_0^2(x)$ in Ce$_{1-x}$Yb$_{x}$CoIn$_5$ are plotted vs $x$ in Fig.~\ref{fig:rho} (the subscript ``0'' signifies zero temperature). \begin{figure}[ht] \begin{center} \includegraphics[width = 0.45\textwidth]{rho.pdf} \caption{Dependence of normalized $T{=}0$ superfluid densities~$\rho_0(x)/\rho_0(0)$ and Yb valence~\cite{Booth11,Dudy13} on nominal Yb concentration~$x$ in Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$. The curve is a guide to the eye. Inset: Uemura plot of $T_c$ vs $\Lambda^{-2}$ for various superconductors~\cite{Broholm90,Luetkens08,MacLaughlin02,% Hashimoto12,Zhang16,Lamura13} including Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$.} \label{fig:rho} \end{center} \end{figure} It can be seen that $\rho_0(x)$ decreases continuously with increasing $x$; the decrease is rapid up to $x = 0.2$, and saturates for higher $x$. As noted above, the Yb valence~$\nu_\mathrm{Yb}$ also decreases rapidly with increasing $x$, from nearly $3+$ near $x = 0$ to ${\sim} 2.3+$ above $x \approx 0.2$~\cite{Booth11,Dudy13}. The consistent change of superfluid density and Yb valence correlates well with de Haas-van Alphen results~\cite{Polyakov12} showing a smooth change of Fermi surface up to $x = 0.2$ and a drastic reconstruction above $x = 0.55$. The temperature dependence of the so-called ``normal-fluid'' density~$\rho_{N}(T) = \rho_s(0) -\rho_s(T)$ of thermal excitations from the ground state is shown in Fig.~\ref{fig:rho_C} for $x = 0$, 0.125, and 0.3. \begin{figure}[ht] \begin{center} \includegraphics[width = 0.45\textwidth]{rho_C.pdf} \caption{Temperature dependencies of normalized ``normal'' fluid density~$\rho_N(T)/\rho_s(0) = 1 - \Lambda^2(0)/\Lambda^2(T)$ and electronic specific heat coefficient~$C_\mathrm{el}/T$ in superconducting Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$. Solid blue triangles: $\rho_N$ measured by $\mu$SR experiment. Open blue triangles: $\rho_N$ measured using the TDO technique~\cite{Hashimoto13}. Red circles: $C_\mathrm{el}/T$ (Ref.~\onlinecite{Shu11} and present measurements). (a)~$x = 0$. Inset: low-temperature data. Curves: fits of Eqs.~(\ref{eq:rho_N}) and (\ref{eq:Cel}) to the data, and the fitting curve of specific heat data is plotted in light green dashed curve for comparison. (b)~$x = 0.125$. (c)~$x = 0.3$.} \label{fig:rho_C} \end{center} \end{figure} The data are normalized to $\rho_s(0)$, so that from Eq.~(\ref{eq:lambda1}) $\rho_N(T)/\rho_s(0) = 1 - \Lambda^2(0)/\Lambda^2(T)$. For $x = 0$, $\rho_N(T/T_c)$ derived from tunnel diode oscillator (TDO) penetration depth measurements~\cite{[{}] [{. In TDO measurements the change of penetration depth~$\Lambda(T) - \Lambda(0)$ is obtained from the inductance of a coil wrapped around the sample. In Fig.~\ref{fig:rho_C}(a) $\rho_N(T)/\rho_s(0) = 1 - \Lambda^2(0)/\Lambda^2(T)$ is calculated using the $\mu$SR result~$\Lambda(0)=0.386~\mu$m.}] Hashimoto13} is plotted in Fig.~\ref{fig:rho_C}(a) in addition to $\mu$SR results~\cite{[{See also }]Chia03, *Ormeno02, *Ozcan03}. The consistency between the two different techniques suggests the reliability of the measurements. The electronic specific heat~$C_\mathrm{el}(T)$ was determined by subtracting the Schottky contribution~$C_\mathrm{Sch}(T) \propto T^{-2}$ from quadrupole-split $^{115}$In nuclear spins from the measured values. The temperature dependences of the specific heat coefficient~$C_\mathrm{el}(T)/T$ for $0 < T \leqslant T_c$~\footnote{Ref.~\onlinecite{Shu11} and the present measurements.} are also shown in Fig.~\ref{fig:rho_C}. The data were fit using the power law~$C_\mathrm{el} /T = \gamma_0 +aT^{\,n_\gamma}$, yielding the corresponding exponent~$n_\gamma$ given in Table~\ref{table-A}. \section{DISCUSSION} In heavy-fermion compounds the heavy electrons arise from the renormalization of $f$ moments to itinerant electrons by the Kondo effect~\cite{Varma85}, through exchange interactions with the $s$, $p$, and $d$ conduction bands. By doping Yb in CeCoIn$_5$, the Kondo-effect-derived heavy fermions develop into intermediate-valence states, which are expected to have much less mass enhancement than in the Kondo limit. However, for $x \gtrsim 0.2$, where the Yb valence is ${\sim} 2.3+$, substantial normal-state mass enhancement is still observed in the specific heat and resistivity of Ce$_{1-x}$Yb$_{x}$CoIn$_5$ up to $x \approx 0.65$~\cite{Shu11,Booth11,Polyakov12,Dudy13}. This suggests that strong correlated-electron effects still exit in the intermediate-valence state where the superfluid density is suppressed. An Uemura plot~\cite{Uemura89} is shown as an inset in Fig.~\ref{fig:rho}, including Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$ and other unconventional superconductors such as UPt$_3$ and PrOs$_4$Sb$_{12}$. Although the behavior within the alloy series itself is not linear, all the Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$ alloys fall in the shaded region, indicating unconventional superconductivity in both heavy-fermion and intermediate-valence limits, As shown in Table~\ref{table-A}, rough agreement is found between the power-law exponents~$n_\sigma$ and $n_\gamma$, suggesting similar renormalizations of the superfluid density and the superconducting-state specific heat in Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$. A recent extension of Landau theory~\cite{Miyake18} provides an understanding of thermodynamic properties and response functions in the superconducting state of a singular Fermi liquid, and in particular accounts for this commonality. The microscopic basis of this theory is the separation of the single-particle Green's function $G(\mathbf{k}, \omega)$ into a coherent (or quasiparticle) part with poles and an incoherent analytic part. The theory yields correlation functions of conserved quantities for which the incoherent part is shown to give no contribution. For Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$, non-Fermi-liquid behavior has been observed and the system is near the quantum critical fluctuation regime~\cite{Hu13}, where $G(\mathbf{k}, \omega)$ has branch cuts. Landau theory cannot be applied to such singular Fermi liquids. However, a form of Landau theory may still be applied to the superconducting state that arises from them, because the density of low-energy excitations in the superconducting state tends to zero (in the pure limit) or is analytic. The theory yields a common renormalization of the specific heat and the superfluid density, and hence predicts the same temperature dependencies of these two properties in the superconducting state. We explore these temperature dependencies further by examining the low-temperature temperature deviations from zero-temperature values (Figure~\ref{fig:rho_C}) using expansions in powers of $T/T_c$~\footnote{This comparison is less {\it ad hoc} than the empirical assumption of power-law behavior over the entire superconducting temperature range discussed previously.}. For $x = 0$ fits of the expansions \begin{equation} \label{eq:rho_N} \rho_N(T)/\rho_s(0) = g_1^{\rho_N}(T/T_c)+g_2^{\rho_N}(T/T_c)^2 + \text{const.} \end{equation} and \begin{equation} \label{eq:Cel} C_\mathrm{el}/T = g_1^{C_\mathrm{el}}(T/T_c)+g_2^{C_\mathrm{el}}(T/T_c)^2 + \text{const.} \end{equation} to the data of Fig.~\ref{fig:rho_C}(a) for $T/T_c\,{\leqslant}\,0.4$ yield $g_1^{\rho_N} = 0.28$, $g_2^{\rho_N} = 0.44$, $g_1^{C_\mathrm{el}} = 0.46~\text{J/mol K}^2$, and $g_2^{C_\mathrm{el}} = 0.71~\text{J/mol K}^2$. The fit curves for $\rho_N(T)/\rho_s(0)$ and $C_\mathrm{el}(T)/T$ in Fig.~\ref{fig:rho_C}(a) are almost identical and, correspondingly, the ratios~$g_1/g_2$ are about the same (0.64 and 0.65, respectively). This is evidence that the same expansion for the temperature dependence of the renormalization describes both these properties in CeCoIn$_5$. No TDO data have been reported For $x = 0.125$ and 0.3, but a few $\rho_N(T)$ points are available from $\mu$SR\@. Here a rough correspondence between $\rho_N$ and $C_\mathrm{el}/T$ is also found [Figs.~\ref{fig:rho_C}(b) and (c)]. This suggests that renormalization of $C_\mathrm{el}/T$ and $\rho_N$ in the superconducting states of Ce$_{1-x}$Yb$_{x}$CoIn$_{5}$ is the same for both heavy fermion and intermediate valence states. For all concentrations the scaling factor~$[C_\mathrm{el}(T)/T]/[\rho_N(T)/\rho_s(0)]$ decreases monotonically with Yb concentration, roughly tracking the normal-state specific heat coefficient. The residual specific heat in the zero-temperature limit may be due to an impurity band that forms in line nodes in the energy gap, as suggested previously~\cite{Shu11, Movshovich01}. In conclusion, the superfluid densities of Yb-substituted alloys of the Kondo heavy-fermion compound CeCoIn$_5$ have been measured using $\mu$SR\@. We find that the superfluid density decreases continuously with increasing Yb substitution $x$. The decrease is rapid up to $x = 0.2$, and saturates for higher $x$ where intermediate valence becomes important. In both the heavy-fermion and intermediate-valence limits the temperature-dependent renormalization of $\rho_N$ is proportional to that of the specific heat. \begin{acknowledgments} We are grateful to G.~D. Morris, B. Hitti, and D. Arsenau of the TRIUMF CMMS for assistance during the experiments, and to C.~M. Varma and K. Miyake for many useful discussions. This research was supported in part by the National Key Research and Development Program of China (Nos.~2017YFA0303104 and 2016YFA0300503), the National Natural Science Foundation of China No.~11474060, the development Fund Project of Science and Technology on Surface Physics and Chemistry Laboratory (Grant No.~XKFZ201602), the U.S. National Science Foundation under grant Nos.~DMR-1105380 (CSU-Los Angeles), DMR-1506677 (CSU-Fresno), and DMR-0802478 (UCSD). The research at UCSD was also supported by the U. S. Department of Energy grant No.~DE-FG02-04ER46105. This work was performed in part at the Aspen Center for Physics, which is supported by National Science Foundation grant PHY-1607611. \end{acknowledgments} \raggedright
\section{Introduction} The modelling of multivariate time series is notoriously difficult and an increasingly common option is to use latent variable or factor models \citep[see for example][and the references therein]{Ensor2013,ChangGuoYao2018}. In this paper we will follow the \textit{blind source separation} (BSS) approach, as an intermediary step prior to modelling. In BSS the observed multivariate time series is bijectively decomposed into several univariate time series that exhibit some form of mutual independence, such as second order uncorrelatedness or even full statistical independence. After such a decomposition, the lack of interaction between the univariate series allows us to model them separately, requiring much smaller numbers of parameters. A particularly popular choice among BSS models for time series is the second order source separation (SOS) model \citep{ComonJutten2010} which assumes that the observed zero-mean $ p $-variate time series $ \textbf{x}_1, \ldots , \textbf{x}_T $ is generated as, \begin{align}\label{eq:model} \textbf{x}_t = \boldsymbol{\Omega} \textbf{z}_t, \quad t = 1, \ldots , T, \end{align} where the \textit{source} series $ \textbf{z}_1, \ldots , \textbf{z}_T$ is a latent non-degenerate, zero-mean, second-order stationary $ p $-variate time series with uncorrelated component series and $ \boldsymbol{\Omega} \in \mathbb{R}^{p \times p} $ is an unknown, invertible matrix-valued parameter. The assumption of zero mean is without loss of generality as we can always center our series. The objective in model \eqref{eq:model} is to estimate an inverse $ \hat{\boldsymbol{\Gamma}} $ for $ \boldsymbol{\Omega} $, giving us an estimate $ \hat{\textbf{z}}_t = \hat{\boldsymbol{\Gamma}} \hat{\textbf{x}}_t$ for the $ p $ sources, which can then further be modelled univariately. However, noise is often an inevitable part of any real world signal and we incorporate it in the model \eqref{eq:model} through the sources. That is, we assume that the sources consist of two parts, $ \textbf{z}_t = (\textbf{z}_{1t}^\top, \textbf{z}_{2t}^\top)^\top $, where $ \textbf{z}_{1t} \in \mathbb{R}^{d} $ contains the signals and $ \textbf{z}_{2t} \in \mathbb{R}^{p - d} $ is a white noise vector. To avoid overfitting in the modelling phase, a crucial step in BSS is to identify the noise subvector $ \textbf{z}_{2t} $ among the sources and discard it prior to the modelling. This problem, signal dimension estimation, has only recently been considered in the context of statistical blind source separation and in this paper we propose a novel estimate that relies on asymptotic hypothesis testing. But first, we review two classical SOS-methods that serve as the basis for both our method and the two existing ones. The standard way of estimating the sources in \eqref{eq:model} is via second-order temporal moments. In algorithm for multiple signals extraction (AMUSE) \citep{TongSoonHuangLiu1990}, an estimate $ \hat{\boldsymbol{\Gamma}} $ is obtained from the generalized eigendecomposition, \begin{equation*} \hat{\boldsymbol{\Gamma}} \hat{\textbf{S}}_0 \hat{\boldsymbol{\Gamma}}^\top = \textbf{I}_p \quad \mbox{and} \quad \hat{\boldsymbol{\Gamma}} \hat{\textbf{R}}_\tau \hat{\boldsymbol{\Gamma}}^\top = \hat{\textbf{D}}_\tau, \end{equation*} where $ \hat{\textbf{S}}_0 = (1/T) \sum_{t=1}^T (\textbf{x}_t - \bar{\textbf{x}}) (\textbf{x}_t - \bar{\textbf{x}})^\top$ is the marginal covariance matrix, $ \hat{\textbf{R}}_{\tau} = (\hat{\textbf{S}}_{\tau} + \hat{\textbf{S}}{}_{\tau}^\top )/2$, $ \hat{\textbf{S}}_{\tau} = [1/(T - \tau)] \sum_{t=1}^{T - \tau} (\textbf{x}_t - \bar{\textbf{x}}) (\textbf{x}_{t + \tau} - \bar{\textbf{x}})^\top$ is the $ \tau $-lag autocovariance matrix and $ \hat{\textbf{D}}_\tau $ is a diagonal matrix. If the lag-$ \tau $ autocovariances of the latent series are distinct, then $ \hat{\boldsymbol{\Gamma}} $ is consistent for $ \boldsymbol{\Omega}^{-1} $ up to permutation and signs of its rows. For the statistical properties of AMUSE, see \citet{MiettinenNordhausenOjaTaskinen2012}. A usually more efficient estimate, which does not depend so much on the selection of a single parameter $\tau$, is given by second order blind identification (SOBI) \citep{BelouchraniAbedMeraimCardosoMoulines1997}, an extension of AMUSE to multiple autocovariance matrices. In SOBI we choose a set of lags $ \mathcal{T} $ and estimate the orthogonal matrix $ \hat{\textbf{U}} $ by maximizing, \begin{align}\label{eq:sobi_diagonalization} \sum_{\tau \in \mathcal{T}} \left\| \mathrm{diag} \left( \textbf{U}^\top \hat{\textbf{S}}_{0}^{-1/2} \hat{\textbf{R}}_{\tau} \hat{\textbf{S}}_{0}^{-1/2} \textbf{U} \right) \right\|^2, \end{align} over the set of all orthogonal $ \textbf{U} \in \mathbb{R}^{p \times p} $, where $ \hat{\textbf{S}}_{0}^{-1/2} $ is the unique symmetric inverse square root of the almost surely positive definite matrix $ \hat{\textbf{S}}_{0} $. This procedure is called orthogonal (approximate) joint diagonalization and provides a natural extension of the generalized eigendecomposition to more than two matrices. Note that this makes AMUSE a special case of SOBI with $ | \mathcal{T} | = 1 $. An estimate for $ \boldsymbol{\Omega}^{-1} $ is given by $ \hat{\boldsymbol{\Gamma}} = \hat{\textbf{U}}{}^\top \hat{\textbf{S}}{}_{0}^{-1/2} $ and it is consistent (up to permutation and signs of its rows) if, for all pairs of sources, there exists a lag $ \tau \in \mathcal{T} $, such that the lag-$ \tau $ autocovariances of the two sources differ, see \citet{BelouchraniAbedMeraimCardosoMoulines1997,MiettinenNordhausenOjaTaskinen2014b,MiettinenIllnerNordhausenOjaTaskinenTheis2016}. For more details about solving the maximization problem in (\ref{eq:sobi_diagonalization}) see for example \citet{IllnerMiettinenFuchsTaskinenNordhausenOjaTheis2015} and the references therein. We now turn back to our problem at hand, the signal dimension estimation. Of the two estimates proposed in literature, both rely on SOBI (with AMUSE as a special case) and the first \citep{MatilainenNordhausenVirta2017} bases the approach on the following set of hypotheses for $ q = 0, \ldots , p - 1 $, \begin{align}\label{eq:null_hypotheses} H_{0q}: \mbox{ $\textbf{z}_t$ contains a $ p - q $-subvector of white noise.} \end{align} A suitable test statistic for $ H_{0q} $ is given, e.g., by the mean of the last $ p - q $ squared diagonal elements of $ \hat{\textbf{U}}{}^\top \hat{\textbf{S}}{}_{0}^{-1/2} \hat{\textbf{R}}_{\tau} \hat{\textbf{S}}{}_{0}^{-1/2} \hat{\textbf{U}} $ over all $ \tau \in \mathcal{T} $, where $ \hat{\textbf{U}} $ is the maximizer of \eqref{eq:sobi_diagonalization}. This is based on the fact that all autocovariances of white noise series vanish, see Section \ref{sec:main} for a more detailed motivation. \cite{MatilainenNordhausenVirta2017} use bootstrapping to obtain the null distributions of the test statistics and sequence several of the tests together to estimate the signal dimension $ d $, see the end of Section \ref{sec:main} for various strategies. Similar techniques have been used for the dimension estimation of iid data in \cite{NordhausenOjaTyler2016, NordhausenOjaTylerVirta2017}. An alternative approach is proposed by \cite{NordhausenVirta2018} who extend the \textit{ladle estimate} of \cite{LuoLi2016} to the time series framework. The estimate is based on combining the classical scree plot with the bootstrap variability \citep{YeWeiss2003} of the joint diagonalizer and has the advantage of estimating the dimension directly, without any need for hypothesis testing. We complement these approaches by devising an asymptotic test for the null hypotheses \eqref{eq:null_hypotheses}, operating under semiparametric assumptions on the source distributions. Using simulations, the test is showed to enjoy the standard properties of asymptotic tests, computational speed and efficiency under time series of moderate and large lengths. The first of these properties is especially important and desirable, considering that the only competitors of the proposed method are based on computationally costly data resampling techniques. Moreover, the mathematical form of the proposed asymptotic test is shown to be particularly simple and elegant. The paper is structured as follows. In Section \ref{sec:main} we present our main results and discuss the implications and strictness of the assumptions required for them to hold. Section \ref{sec:theory} contains the technical derivations that lead to the results in Section \ref{sec:main} and can be safely skipped by a casual reader. The proofs of the results are collected in Appendix \ref{sec:appendix}. Section \ref{sec:simulations} sees us comparing the proposed dimension estimate to the bootstrap- and ladle estimates under various settings using simulated data. In Section \ref{sec:data_example} we apply the proposed method to estimate the dimension of a sound recording data set and in Section \ref{sec:discussion}, we finally conclude with some prospective ideas for future research. \section{Main results}\label{sec:main} In this section we present our main results and the assumptions required by them. The more technical content is postponed to Section \ref{sec:theory} and can be skipped if the reader is not interested in the theory behind the results. Let the observed time series $ \textbf{x}_t $ come from the SOS-model \eqref{eq:model} and denote by $ \lambda^*_{\tau k} $ the $ \tau $-lag autocovariance of the $ k $th component of $ \textbf{z}_t $. Recall that SOBI jointly diagonalizes the set of standardized and symmetrized autocovariance matrices $ \hat{\textbf{H}}_\tau = \hat{\textbf{S}}{}_{0}^{-1/2} \hat{\textbf{R}}_{\tau} \hat{\textbf{S}}{}_{0}^{-1/2} $, $ \tau \in \mathcal{T} $, to obtain the orthogonal matrix $ \hat{\textbf{U}} $. Order the columns of $ \hat{\textbf{U}} $ such that the sums of squared pseudo-eigenvalues, $ \sum_{\tau \in \mathcal{T}} \mathrm{diag}(\hat{\textbf{U}}{}^\top \hat{\textbf{H}}_\tau \hat{\textbf{U}})^2$, are in a decreasing order and partition $ \hat{\textbf{U}} $ as $ ( \hat{\textbf{V}}_q, \hat{\textbf{W}}_q) $ where $ \hat{\textbf{V}}_q \in \mathbb{R}^{p \times q}, \hat{\textbf{W}}_q \in \mathbb{R}^{p \times (p - q) } $ for some fixed $ q $. We show in Section \ref{sec:theory} that, for large $ T $, this ordering places the noise components after the signals in the estimated sources. If the null hypothesis $ H_{0q} $ is true, the autocovariance matrices of the last $ p - q $ estimated sources, \[ \hat{\textbf{D}}_{\tau q} = \hat{\textbf{W}}_q^\top \hat{\textbf{H}}_\tau \hat{\textbf{W}}_q, \] are then expected to be close to zero matrices due to the last sources being (at least, asymptotically) white noise. To accumulate information over multiple lags, we use as our test statistic for $ H_{0q} $ the mean of the squared elements of the matrices $ \hat{\textbf{D}}_{\tau q} $ over a fixed set of lags $ \tau \in \mathcal{T} $, \[ \hat{m}_q = \frac{1}{| \mathcal{T}| (p - q)^2} \sum_{\tau \in \mathcal{T}} \| \hat{\textbf{D}}_{\tau q} \|^2, \] which likewise measures departure from the null hypothesis $ H_{0q} $. In the special case of AMUSE we have only a single matrix $ \hat{\textbf{D}}_{\tau q} $, which can in practice be obtained using the easier-to-compute generalized eigendecomposition, instead of joint diagonalization. Note that it is possible for the matrices $ \hat{\textbf{D}}_{\tau q} $ to be small in magnitude even if the number of white noise sources in the model is less than $ p - q $. This situation can arise if some of the signal series are indistinguishable from white noise based on autocovariances alone and as such we need to restrict the set of signal distributions we can consider. The next assumption guarantees that each signal component exhibits non-zero autocovariance for at least one lag $ \tau \in \mathcal{T} $, and is thus distinguishable from white noise. \begin{assumption}\label{assu:signal_from_noise} For all $ k = 1, \ldots , d $, there exists $ \tau \in \mathcal{T} $ such that $ \lambda^*_{\tau k} \neq 0$. \end{assumption} Considering that most signals encountered in practice exhibit autocorrelation, Assumption \ref{assu:signal_from_noise} is rather non-restrictive. Moreover, we can always increase the number of feasible signal processes by incorporating more lags in $ \mathcal{T} $. However, there exists time series which, while not being white noise, still have zero autocorrelation for all finite lags. For example, stochastic volatility models \citep[see for example][]{MikoschEtAl2009} belong to this class of processes, and consequently, by Assumption \ref{assu:signal_from_noise}, they are excluded from our model (see, however Section \ref{sec:discussion} for an idea on how to incorporate these distributions in the model). The second assumption we need is more technical in nature and requires that the source series come from a specific, wide class of stochastic processes. A similar assumption is utilized also in \citet{MiettinenNordhausenOjaTaskinen2012,MiettinenNordhausenOjaTaskinen2014b,MiettinenIllnerNordhausenOjaTaskinenTheis2016}. \begin{assumption}\label{assu:ma_infinity} The latent series $ \textbf{z}_t $ are linear processes having the $ \mathrm{MA}(\infty) $-representation, \[ \textbf{z}_t = \sum_{j=-\infty}^\infty \boldsymbol{\Psi}_j \boldsymbol{\epsilon}_{t - j}, \] where $ \boldsymbol{\epsilon}_t \in \mathbb{R}^p$ are second-order standardized, iid random vectors with exchangeable, marginally symmetric components having finite fourth order moments and $ \boldsymbol{\Psi}_j \in \mathbb{R}^{p \times p} $ are diagonal matrices satisfying $ \sum_{j=-\infty}^\infty \boldsymbol{\Psi}_j^2 = \textbf{I}_p $ and $ \| \sum_{j=-\infty}^\infty |\boldsymbol{\Psi}_j| \| < \infty$ where $ | \boldsymbol{\Psi}_j | \in \mathbb{R}^{p \times p}$ denotes the matrix of component-wise absolute values of $ \boldsymbol{\Psi}_j $. Moreover the lower right $ (p - d) \times (p - d) $ blocks of $ \boldsymbol{\Psi}_j $ (the noise) equal $ \boldsymbol{\Psi}_{j00} = \delta_{j0} \textbf{I}_{p - d} $, where $ \delta_{\cdot \cdot} $ is the Kronecker delta. \end{assumption} Note that all second-order stationary multivariate time series can by Wold's decomposition be given a $ \mathrm{MA}(\infty) $-representation, meaning that the most stringent part of Assumption \ref{assu:ma_infinity} is that it requires the innovations of the sources to have identical, symmetric marginal distributions. The importance of Assumption \ref{assu:ma_infinity} to the theory comes from the fact that under it the joint limiting distribution of the sample autocovariance matrices can be derived. As such, it could also be replaced with some other assumption guaranteeing the same thing. With the previous, we are now able to present our main result. \begin{proposition}\label{prop:1} Under Assumptions \ref{assu:signal_from_noise}, \ref{assu:ma_infinity} and the null hypothesis $ H_{0q} $, \[ T |\mathcal{T}| (p - q)^2 \cdot \hat{m}_q \rightsquigarrow \chi^2_{| \mathcal{T} |(p - q)(p - q + 1)/2}, \] where $ \chi^2_\nu $ denotes the chi-squared distribution with $ \nu $ degrees of freedom. \end{proposition} The limiting distribution in Proposition \ref{prop:1} is remarkably simple, does not depend on the type of white noise and requires no parameters to estimate, implying that it is also fast to use in practice. Note that the number of degrees of freedom of the limiting distribution is equal to the total number of free elements in the symmetric matrices $ \hat{\textbf{D}}_{\tau q} $, $ \tau \in \mathcal{T} $. Thus, each of the elements can be seen to asymptotically contribute a single $ \chi^2_1 $ random variable to the test statistic. To use Proposition \ref{prop:1} to estimate the signal dimension in the $ p $-dimensional BSS-model \eqref{eq:model}, we sequence together a set of asymptotic tests for the null hypotheses $ H_{00}, H_{01}, \ldots , H_{0(p - 1)} $. Denote the string of $ p $-values produced by these tests by $ (p_0, p_1, \ldots , p_{p - 1}) $ and fix a level of significance $ \alpha $. Different estimates for $ d $ are now obtained by considering the $ p $-values via various strategies. The forward estimate of $ d $ is the smallest $ q $ for which $ p_q \geq \alpha $. The backward estimate of $ d $ is $ q + 1 $ where $ q $ is the largest value for which $ p_q < \alpha $. The divide-and-conquer estimate is obtained by iteratively halving the search interval until a change point from $ < \alpha $ to $ \geq \alpha $ is found. \section{Theoretical derivations}\label{sec:theory} Throughout this section, we assume the SOS-model \eqref{eq:model} and a fixed set of lags $ \mathcal{T} = \{ \tau_1, \ldots , \tau_{|\mathcal{T}|} \}$. Moreover, we work under the assumption of identity mixing, $ \boldsymbol{\Omega} = \textbf{I}_p $, which is without loss of generality as SOBI is affine equivariant, meaning that the source estimates do not depend on the value of $ \boldsymbol{\Omega} $ \citep{MiettinenIllnerNordhausenOjaTaskinenTheis2016}. To ensure identifiability of $ \boldsymbol{\Omega} $ we may further set $ \textbf{S}_0 = \mathrm{E}(\textbf{x}_t \textbf{x}_t^\top) = \textbf{I}_p $. We assume a fixed null hypothesis $ H_{0q} $ and denote the number of white noise components by $ r = p - q $. The population autocovariance matrices are denoted by $ \textbf{S}_\tau = \mathrm{E}(\textbf{x}_t \textbf{x}_{t + \tau}^\top) $ and $ \textbf{R}_\tau = ( \textbf{S}_\tau + \textbf{S}_\tau^\top )/2$, and by the identity mixing and uncorrelatedness of the latent series we have, \[ \textbf{S}_\tau = \textbf{R}_\tau = \textbf{D}_\tau = \begin{pmatrix} \boldsymbol{\Lambda}_\tau & \textbf{0} \\ \textbf{0} & \textbf{0}, \end{pmatrix}, \] where $ \boldsymbol{\Lambda}_\tau $ is a $ q \times q $ diagonal matrix, $ \tau \in \mathcal{T} $. The lower right block of the matrix $ \textbf{D}_\tau $ vanishes for all $ \tau \in \mathcal{T} $ as autocovariances of a white noise series are zero. Without loss of generality, we assume that the signals are ordered in $ \textbf{z}_{1t} $ such that the diagonal elements of $ \sum_{\tau \in \mathcal{T}} \boldsymbol{\Lambda}^2_\tau $ are in decreasing order. Moreover, if there are ties, we fix the order by ordering the tied components in decreasing order with respect to the diagonal elements of $ \boldsymbol{\Lambda}_{\tau_1}^2 $. If we still have ties, we order the tied components in decreasing order with respect to the diagonal elements of $ \boldsymbol{\Lambda}_{\tau_2}^2 $ and so on. If after all this we still have tied components, we set them in arbitrary order and note that such sets of tied components have the same autocovariance structure for all lags $ \tau \in \mathcal{T} $, making them indistinguishable by SOBI. However, this just makes the individual signals unestimable and does not affect the estimation of the dimension in any way, as long as Assumption \ref{assu:signal_from_noise} holds. Partition then the signals into $ v $ groups such that each group consists solely of signals with matching autocovariance structures on all lags $ \tau \in \mathcal{T} $ and such that each pair of distinct groups has a differing autocovariance for at least one lag $ \tau \in \mathcal{T} $. The autocovariance of the $ j $th group for lag $ \tau $ is denoted by $ \lambda_{\tau j} $ and the size of the $ j $th group by $ p_j $, implying that $ p_1 + \cdots p_v = q$. By Assumption \ref{assu:signal_from_noise}, the white noise forms its own group not intersecting with any of the signal groups, and in the following we refer to the noise group with the index $ 0 $, as in $ p_0 = r $ and $ \lambda_{\tau 0} = 0 $ for all $ \tau \in \mathcal{T} $. If $ v = 1 $, all signal components are indistinguishable by their autocovariances and in the other extreme, $ v = q $, no ties occurred in ordering the signals and each signal pair has differing autocovariances for at least one lag $ \tau \in \mathcal{T} $. We introduce yet one more assumption which is actually implied by Assumption \ref{assu:ma_infinity} and is as such not strictly necessary. However, some of the following auxiliary results are interesting on their own and can be shown to hold under Assumption \ref{assu:consistent}, without the need for Assumption \ref{assu:ma_infinity}. \begin{assumption}\label{assu:consistent} The sample covariance matrix and the sample autocovariance matrices are root-$ T $ consistent, $ \sqrt{T} ( \hat{\textbf{S}}_\tau - \textbf{D}_\tau) = \mathcal{O}_p(1)$, for $ \tau \in \mathcal{T} \cup \{ 0 \} $, where $ \textbf{D}_0 = \textbf{I}_p $. \end{assumption} We begin with a simple linearization result for the standardized autocovariance matrices. The notation $ \hat{\textbf{H}}_{\tau00}, \hat{\textbf{R}}_{\tau00} $ in Lemma \ref{lem:0} refers to the lower right $ r \times r $ diagonal blocks of the matrices $ \hat{\textbf{H}}_{\tau} = \hat{\textbf{S}}{}_{0}^{-1/2} \hat{\textbf{R}}_{\tau} \hat{\textbf{S}}{}_{0}^{-1/2} $ and $ \hat{\textbf{R}}_{\tau} $. Under $ H_{0q} $ these sub-matrices gather the autocovariances of the noise components. \begin{lemma}\label{lem:0} Under Assumption \ref{assu:consistent} we have \[ \hat{\textbf{H}}_\tau = \hat{\textbf{R}}_\tau + \mathcal{O}_p(1/\sqrt{T}), \quad \mbox{for all } \tau \in \mathcal{T}. \] If $ H_{0q} $ further holds, then, \[ \hat{\textbf{H}}_{\tau00} = \hat{\textbf{R}}_{\tau00} + \mathcal{O}_p(1/T), \quad \mbox{for all } \tau \in \mathcal{T}. \] \end{lemma} Our second auxiliary result shows that, under Assumptions \ref{assu:signal_from_noise} and \ref{assu:consistent}, the SOBI solution is, while not identifiable, of a very specific asymptotic form (up to permutation). The block division and indexing in Lemma \ref{lem:1} are based on the division of the sources into the $ v + 1 $ groups of equal autocovariances. \begin{lemma}\label{lem:1} Under Assumptions \ref{assu:signal_from_noise}, \ref{assu:consistent} and the null hypothesis $ H_{0q} $, there exists a sequence of permutation matrices $ \hat{\textbf{P}} $ such that, \[ \hat{\textbf{U}} \hat{\textbf{P}} = \left[\begin{array}{cccc} \cellcolor{black!10}\hat{\textbf{U}}_{11} & \cdots & \hat{\textbf{U}}_{1v} & \hat{\textbf{U}}_{10} \\ \vdots & \cellcolor{black!10}\ddots & \vdots & \vdots\\ \hat{\textbf{U}}_{v1} & \cdots & \cellcolor{black!10}\hat{\textbf{U}}_{vv} & \hat{\textbf{U}}_{v0} \\ \hat{\textbf{U}}_{01} &\cdots & \hat{\textbf{U}}_{0v} & \cellcolor{black!10}\hat{\textbf{U}}_{00} \end{array}\right] , \] where the diagonal blocks (shaded) satisfy $ \hat{\textbf{U}}_{ii} = \mathcal{O}_p(1)$ and the off-diagonal blocks satisfy $ \hat{\textbf{U}}_{ij} = \mathcal{O}_p(1/\sqrt{T})$. \end{lemma} \begin{corollary}\label{cor:1} Under the assumptions of Lemma \ref{lem:1}, we have for each $ j = 0, 1, \ldots , v $ that, \[ \hat{\textbf{U}}_{jj}^\top \hat{\textbf{U}}_{jj} - \textbf{I}_{p_j} = \mathcal{O}_p(1/T) \quad \mbox{and} \quad \hat{\textbf{U}}_{jj} \hat{\textbf{U}}_{jj}^\top - \textbf{I}_{p_j} = \mathcal{O}_p(1/T). \] \end{corollary} The first $ v $ diagonal blocks in the block matrix of Lemma \ref{lem:1} correspond to the groups of signals that are mutually indistinguishable and the final diagonal block to the $ r $ noise components (which are also indistinguishable from each other). The main implication of Lemma \ref{lem:1} is that the sources within a single group can not be separated by SOBI but the signals coming from two different groups can be, the mixing vanishing at the rate of root-$ T $. In the special case of $ p_j = 1 $, for all $ j = 0, 1, \ldots , v $, Lemma \ref{lem:1} is an instant consequence of \cite[Theorem 1(ii)]{MiettinenIllnerNordhausenOjaTaskinenTheis2016}. The next lemma states that our test statistic is under the null asymptotically equivalent to a much simpler quantity, not depending on the estimation of the SOBI-solution $ \hat{\textbf{U}} $. \begin{lemma}\label{lem:2} Under Assumptions \ref{assu:signal_from_noise}, \ref{assu:consistent} and the null hypothesis $ H_{0q} $, we have, \[ T \cdot \hat{m}_q = T \cdot \hat{m}^*_q + o_p(1), \] where \[ \hat{m}^*_q = \frac{1}{ |\mathcal{T}| r^2 } \sum_{\tau \in \mathcal{T}} \| \hat{\textbf{R}}_{\tau00} \|^2, \] and $ \hat{\textbf{R}}_{\tau00} $ is the lower right $ r \times r $ block of $ \hat{\textbf{R}}_{\tau} $. \end{lemma} To compute the limiting distribution of the proxy $ \hat{m}_q^* $ we next show that the joint limiting distribution of the blocks $ \hat{\textbf{R}}_{\tau00} $ is under Assumption~\ref{assu:ma_infinity} and $ H_{0q} $ conveniently a multivariate normal distribution. The result is a slight modification of \cite[Lemma 1]{MiettinenIllnerNordhausenOjaTaskinenTheis2016}. In the statement of Lemma \ref{lem:3}, $ \textbf{J}_r $ denotes the $ r \times r $ matrix filled with ones and $ \textbf{E}_r^{i j} $ denotes the $ r \times r $ matrix filled otherwise with zeroes but with a single one as the $ (i, j) $th element. \begin{lemma}\label{lem:3} Under Assumption \ref{assu:ma_infinity} and the null hypothesis $ H_{0q} $, the blocks $ \hat{\textbf{R}}_{\tau_100}, \ldots , \hat{\textbf{R}}_{\tau_{|\mathcal{T}|}00} $ have a joint limiting normal distribution, \[ \sqrt{T} \mathrm{vec} \left( \hat{\textbf{R}}_{\tau_100}, \ldots , \hat{\textbf{R}}_{\tau_{|\mathcal{T}|}00} \right) \rightsquigarrow \mathcal{N}_{|\mathcal{T}| r^2} (\textbf{0}, \textbf{V}), \] where $ \mathrm{vec} $ is the column-vectorization operator, \[ \textbf{V} = \begin{pmatrix} \textbf{V}_0 & \textbf{0} & \cdots & \textbf{0} \\ \textbf{0} & \textbf{V}_0 & \cdots & \textbf{0} \\ \vdots & \vdots & \ddots & \vdots \\ \textbf{0} & \textbf{0} & \cdots & \textbf{V}_0 \end{pmatrix} \in \mathbb{R}^{|\mathcal{T}| r^2 \times |\mathcal{T}| r^2}, \] and $ \textbf{V}_0 = \mathrm{diag}(\mathrm{vec}(\textbf{J}_{r} + \textbf{I}_{r})/2) (\textbf{K}_{rr} - \textbf{D}_{rr} + \textbf{I}_{r^2} )$ where $ \textbf{K}_{rr} = \sum_{i=1}^r \sum_{j=1}^r \textbf{E}_r^{ij} \otimes \textbf{E}_r^{ji}$ and $ \textbf{D}_{rr} = \sum_{i=1}^r \textbf{E}_r^{ii} \otimes \textbf{E}_r^{ii} $. \end{lemma} Lemmas \ref{lem:2} and \ref{lem:3} now combine to establish the limiting distribution of the test statistic to be the remarkably simple chi-squared distribution, see Proposition \ref{prop:1} in Section \ref{sec:main}. \section{Simulations}\label{sec:simulations} The following results are all obtained in R \citep{R} using the packages JADE \citep{JADE} and tsBSS \citep{tsBSS}. \subsection{Evaluation of the hypothesis testing}\label{sec:simulations_1} In the first set of simulations we consider the performance of the hypothesis tests. As our competitor we use the recommended and most general non-parametric bootstrapping strategy from \citet{MatilainenNordhausenVirta2017}, which takes bootstrap samples from the hypothetical multivariate noise part. The number of bootstrap samples used was 200. We computed also the three other bootstrapping strategies as listed in \citet{MatilainenNordhausenVirta2017}, but as the results were basically the same, we report for simplicity only the strategy mentioned above. We considered three different settings for the latent sources: \begin{description} \item[Setting H1:] MA(3), AR(2) and ARMA(1,1) having Gaussian innovations together with two Gaussian white noise components. \item[Setting H2:] MA(10), MA(15) and M(20) processes having Gaussian innovations together with two Gaussian white noise components. \item[Setting H3:] Three MA(3) processes having Gaussian innovations and identical autocovariance functions together with two Gaussian white noise processes. \end{description} Hence, in all three settings the signal dimension is $d=3$ and the total dimension is $p=5$. Due to affine equivariance of the used methods, we take without loss of generality $\bs \Omega = \mathbf I_5$. In general, setting H1 can be considered a short range dependence model and H2 a long range dependence model. Setting H3 is special in that the methods should not be able to separate its signals, but they should still be able to separate the noise space from the signal space Based on 2000 repetitions, we give the rejection frequencies of the null hypotheses $ H_{02} $, $ H_{03} $ and $ H_{04} $ at level $\alpha=0.05$ in Tables~\ref{tab:H1d4}-\ref{tab:H3d2}. We considered three different BSS-estimators, AMUSE with $\tau=1$, SOBI with $\mathcal{T}=\{1,\ldots,6\}$ (denoted SOBI6) and SOBI with $\mathcal{T}=\{1,\ldots,12\}$ (denoted SOBI12). The optimal rejection rates at level $ \alpha = 0.05 $ are $ 1.00 $ for $ H_{02} $, $ 0.05 $ for $ H_{03} $ and $ < 0.05 $ for $ H_{04} $. \begin{longtable}[]{@{}rrrrrrr@{}} \caption{Rejection frequencies of $H_{02}$ in Setting H1 at level $\alpha=0.05$.} \label{tab:H1d4}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 1.000 & 1.000 & 1.000 & 0.999 & 0.998 & 0.998\tabularnewline 500 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000\tabularnewline 1000 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000\tabularnewline 2000 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000\tabularnewline 5000 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000 & 1.000\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing \(H_{03}\) in Setting H1 at level $\alpha=0.05$.} \label{tab:H1d3}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.059 & 0.050 & 0.078 & 0.050 & 0.102 & 0.050\tabularnewline 500 & 0.053 & 0.048 & 0.064 & 0.049 & 0.071 & 0.052\tabularnewline 1000 & 0.048 & 0.047 & 0.059 & 0.053 & 0.054 & 0.050\tabularnewline 2000 & 0.050 & 0.054 & 0.048 & 0.049 & 0.054 & 0.046\tabularnewline 5000 & 0.048 & 0.052 & 0.052 & 0.047 & 0.056 & 0.053\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing $H_{04}$ in Setting H1 at level $\alpha=0.05$.} \label{tab:H1d2}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.006 & 0.008 & 0.015 & 0.006 & 0.024 & 0.004\tabularnewline 500 & 0.006 & 0.007 & 0.009 & 0.004 & 0.016 & 0.006\tabularnewline 1000 & 0.007 & 0.010 & 0.012 & 0.005 & 0.012 & 0.006\tabularnewline 2000 & 0.003 & 0.006 & 0.008 & 0.003 & 0.009 & 0.002\tabularnewline 5000 & 0.006 & 0.006 & 0.006 & 0.002 & 0.008 & 0.004\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing \(H_{02}\) in Setting H2 at level $\alpha=0.05$.} \label{tab:H2d4}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.038 & 0.043 & 0.608 & 0.484 & 0.911 & 0.848\tabularnewline 500 & 0.090 & 0.094 & 0.988 & 0.987 & 1.000 & 1.000\tabularnewline 1000 & 0.190 & 0.189 & 1.000 & 1.000 & 1.000 & 1.000\tabularnewline 2000 & 0.252 & 0.256 & 1.000 & 1.000 & 1.000 & 1.000\tabularnewline 5000 & 0.558 & 0.550 & 1.000 & 1.000 & 1.000 & 1.000\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing \(H_{03}\) in Setting H2 at level $\alpha=0.05$.} \label{tab:H2d3}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.002 & 0.006 & 0.125 & 0.050 & 0.148 & 0.063\tabularnewline 500 & 0.008 & 0.014 & 0.075 & 0.041 & 0.074 & 0.050\tabularnewline 1000 & 0.010 & 0.014 & 0.067 & 0.046 & 0.068 & 0.047\tabularnewline 2000 & 0.020 & 0.024 & 0.056 & 0.052 & 0.066 & 0.061\tabularnewline 5000 & 0.031 & 0.039 & 0.051 & 0.048 & 0.054 & 0.047\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing \(H_{04}\) in Setting H2 at level $\alpha=0.05$.} \label{tab:H2d2}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.000 & 0.001 & 0.034 & 0.004 & 0.039 & 0.006\tabularnewline 500 & 0.002 & 0.004 & 0.010 & 0.004 & 0.016 & 0.007\tabularnewline 1000 & 0.000 & 0.004 & 0.012 & 0.004 & 0.007 & 0.001\tabularnewline 2000 & 0.002 & 0.004 & 0.010 & 0.004 & 0.010 & 0.003\tabularnewline 5000 & 0.004 & 0.008 & 0.010 & 0.005 & 0.007 & 0.003\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing \(H_{02}\) in Setting H3 at level $\alpha=0.05$.} \label{tab:H3d4}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.036 & 0.042 & 0.600 & 0.479 & 0.906 & 0.84\tabularnewline 500 & 0.084 & 0.092 & 0.986 & 0.987 & 1.000 & 1.00\tabularnewline 1000 & 0.168 & 0.175 & 1.000 & 1.000 & 1.000 & 1.00\tabularnewline 2000 & 0.279 & 0.272 & 1.000 & 1.000 & 1.000 & 1.00\tabularnewline 5000 & 0.576 & 0.568 & 1.000 & 1.000 & 1.000 & 1.00\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing \(H_{03}\) in Setting H3 at level $\alpha=0.05$.} \label{tab:H3d3}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.004 & 0.005 & 0.122 & 0.049 & 0.146 & 0.047\tabularnewline 500 & 0.006 & 0.008 & 0.075 & 0.043 & 0.074 & 0.057\tabularnewline 1000 & 0.010 & 0.018 & 0.062 & 0.050 & 0.062 & 0.055\tabularnewline 2000 & 0.016 & 0.023 & 0.058 & 0.044 & 0.046 & 0.054\tabularnewline 5000 & 0.034 & 0.042 & 0.051 & 0.050 & 0.048 & 0.045\tabularnewline \bottomrule \end{longtable} \begin{longtable}[]{@{}rcccccc@{}} \caption{Rejection frequencies when testing \(H_{04}\) in Setting H3 at level $\alpha=0.05$.} \label{tab:H3d2}\tabularnewline \toprule & \multicolumn{2}{c}{AMUSE} & \multicolumn{2}{c}{SOBI6} & \multicolumn{2}{c}{SOBI12}\tabularnewline \cmidrule(l){2-3} \cmidrule(l){4-5} \cmidrule(l){6-7} n & Asymp & Boot & Asymp & Boot & Asymp & Boot\tabularnewline \midrule \endfirsthead 200 & 0.000 & 0.002 & 0.026 & 0.005 & 0.034 & 0.006\tabularnewline 500 & 0.000 & 0.002 & 0.012 & 0.003 & 0.012 & 0.003\tabularnewline 1000 & 0.002 & 0.002 & 0.010 & 0.005 & 0.010 & 0.005\tabularnewline 2000 & 0.004 & 0.006 & 0.008 & 0.007 & 0.006 & 0.004\tabularnewline 5000 & 0.005 & 0.010 & 0.008 & 0.004 & 0.006 & 0.003\tabularnewline \bottomrule \end{longtable} The results of the simulations can be summarized as follows. (i) There is no big difference between the limiting theory and the bootstrap tests, which is a clear advantage for the asymptotic test as neither a bootstrapping strategy has to be selected nor is the asymptotic test computationally demanding. (ii) The number of matrices to be diagonalized seems to matter. If the dependence structure is of a short range AMUSE works well, but it seems to struggle in the case of long range dependence. In the considered settings SOBI with 6 matrices seems to be a good compromise. (iii) Even when the signals cannot be individually separated, the noise and signal subspaces can be separated very accurately In general, having a very good power under the alternative hypotheses of too large noise subspaces is desirable when using successive testing strategies to estimate the dimension. This was not yet evaluated in \citet{MatilainenNordhausenVirta2017} and will be done in the next section. \subsection{Evaluation of determining the dimension of the signal} In this section we evaluate in a simulation study the performance of our test when the goal is to estimate the signal dimension $d$. Several different testing strategies are possible, as described in the end of Section \ref{sec:main}. We will use in the following the divide-and-conquer strategy as it seems the most practical. For simplicity, all tests will be performed at the level $\alpha=0.05$. As competitors we use again the bootstrap tests, this time including all three nonparametric bootstraps and the parametric bootstrap. For details we refer to \citet{MatilainenNordhausenVirta2017}. As an additional contender we use the ladle estimator as described in \citet{NordhausenVirta2018}. Also for the ladle different bootstrap strategies are possible and we consider the fixed block bootstrap with the block lengths 20 and 40 and the stationary block bootstrap with the expected block lengths 20 and 40, see \citet{NordhausenVirta2018} for details. For all bootstrap-based methods the number of bootstrapping samples is again 200 and, as in the previous section, we consider the three estimators, AMUSE, SOBI6 and SOBI12. The settings considered in this simulation are: \begin{description} \item[Setting D1:] AR(2), AR(3), ARMA(1,1), ARMA(3,2) and MA(3) processes having Gaussian innovations together with 5 Gaussian white noise components. \item[Setting D2:] Same processes as in D1 but the MA(3) is changed to an MA(1) process with the parameter equal to 0.1. \item[Setting D3:] Five MA(2) processes with parameters (0.1, 0.1) having Gaussian innovations together with 5 Gaussian white noise processes. \end{description} Hence, in all settings $p=10$ and $d=5$. Setting D1 is the basic setting whereas in Setting D2 there is one very weak signal. In Setting D3 all five signals come from identical processes and exhibit weak dependence. As in the previous simulation, the mixing matrix used is $\bs \Omega = \mathbf I_{10}$ and Figures~\ref{fig:Est_k_1}-\ref{fig:Est_k_3} show, based on 2000 repetitions, the frequencies of the estimated signal dimensions. \begin{figure}[t!] \centering \includegraphics[width=0.99\textwidth]{fig_estimates_1} \caption{Estimating $k$ by divide-and-conquer in Setting D1.} \label{fig:Est_k_1} \end{figure} \begin{figure}[t!] \centering \includegraphics[width=0.99\textwidth]{fig_estimates_3} \caption{Estimating $k$ by divide-and-conquer in Setting D2.} \label{fig:Est_k_2} \end{figure} \begin{figure}[t!] \centering \includegraphics[width=0.99\textwidth]{fig_estimates_2} \caption{Estimating $k$ by divide-and-conquer in Setting D3.} \label{fig:Est_k_3} \end{figure} In Setting D1, the asymptotic test seems not to work as well as the other methods for small samples but in general the difference to the bootstrap-based testing procedures is negligible. In general, the ladle is the most preferable option. In setting D2, on the other hand, ladle consistently underestimates the signal dimension and is not able to find the weak signal. When using the hypothesis testing-based methods also the weak signal is identified with increasing sample size. However, the more scatter matrices we estimate, the more difficult the estimation gets and thus AMUSE works the best. In Setting D3 the ladle fails completely and keeps getting worse with increasing sample size. The difference between bootstrapping and asymptotic testing is at its largest in this setting, the asymptotic test seems to be the most preferable option. As two lags are needed to capture all the temporal information, AMUSE is at an disadvantage in this setting, and this is clearly visible in the plots. Also, SOBI6 seems to exploit the lag information better than SOBI12, possibly because it avoids the inclusion of several unnecessary autocovariance matrices in the estimation. \section{Data example}\label{sec:data_example} For our real data example we use the recordings of three sounds signals available in the R-package JADE and analysed, for example, in \citet{MiettinenNordhausenTaskinen2017}. To the three signal components we added 17 white noise components which all had $t_5$-distributions to study whether the methods also work in case of non-Gaussian white noise. After standardizing the 20 components to have unit variances, we used a random square matrix where each element came from the uniform distribution on $[0,1]$. The original signals had a length of 50000 and for convenience we selected the first 10000 instances. The 20 mixed components are visualized in Figure~\ref{fig:DataSoundExample} and reveal no clear structure. \begin{figure}[H] \centering \includegraphics[width=0.99\textwidth]{fig_DataSoundExample} \caption{The 20-variate sound data time series.} \label{fig:DataSoundExample} \end{figure} We used the divide-and-conquer approach to estimate the signal dimension with our asymptotic test and the bootstrapping strategy of \citet{MatilainenNordhausenVirta2017} used in Section~\ref{sec:simulations_1}. Additionally, we considered also the ladle estimator using stationary bootstrapping with the expected block length 40. Of each estimator, three versions, AMUSE, SOBI6 and SOBI12, were computed. All nine estimators estimated correctly 3 as the signal dimension and the estimated signals based on SOBI6 are shown in Figure~\ref{fig:EstimatedSignalsSoundExample}. \begin{figure}[t!] \centering \includegraphics[width=0.8\textwidth]{fig_EstimatedSignalsSoundExample} \caption{The three estimated sound signals based on SOBI6.} \label{fig:EstimatedSignalsSoundExample} \end{figure} The computation times of the nine methods were, however, quite different and are given in Table~\ref{tab:SoundExTimings}. \begin{table}[ht] \centering \footnotesize \caption{Computation times (in seconds) of the nine estimators for the sound example data.} \label{tab:SoundExTimings} \begin{tabular}{ccccccccc} \toprule \multicolumn{3}{c}{Asymptotic tests} & \multicolumn{3}{c}{Bootstrap tests} & \multicolumn{3}{c}{Ladle estimator}\tabularnewline \cmidrule(l){1-3} \cmidrule(l){4-6} \cmidrule(l){7-9} AMUSE &SOBI6 & SOBI12 & AMUSE &SOBI6 & SOBI12 & AMUSE &SOBI6 & SOBI12 \\ \midrule 0.07 & 0.19 & 0.49 & 15.08 & 47.24 & 88.08 & 2.75 & 9.85 & 18.17 \\ \bottomrule \end{tabular} \end{table} As all the approaches estimated the dimension correctly, the ones based on the asymptotic test are clearly favourable due to their computational speed. Although, we note that the ladle and the bootstrap tests can also be run parallelized while in the current comparison we used only a single core. \section{Discussion}\label{sec:discussion} We proposed an asymptotic test for estimating the signal dimension in an SOS-model where the sources include both signal series and white noise. The test does not require the estimation of any parameters and makes quite weak assumptions. This combined with the fact that both of its existing competitors are based on the use of computer-intensive resampling techniques makes the asymptotic test a very attractive option in practice. This conclusion was supported by our simulations studies and real data example exploring dimension estimation for sound recording data. A central drawback of the proposed method is its inability to recognize non-autocorrelated signals, such as those coming from stochastic volatility models, from white noise. One way to get around this limitation is to replace $ \textbf{z}_{2t} $ in \eqref{eq:model} by a vector of stochastic volatility series and to revert the roles of signal and noise. That is, we use hypothesis testing to estimate the dimension of the ``noise'' subspace (containing the stochastic volatility components) and separate them from the uninteresting ``signal'' series exhibiting autocorrelation. For this to work, a limiting result equivalent to Lemma \ref{lem:3} is needed for the above combination model. Similar idea was suggested in the context of the ladle estimator already in \cite{NordhausenVirta2018}. \vskip 14pt \noindent {\large\bf Acknowledgements} Klaus Nordhausen acknowledges support from the CRoNoS COST Action IC1408. \par
\section{Introduction} Let $G$ be a permutation group acting on finite set $\Omega$ then $G$ has an induced action on $\Omega_k$ the set of subsets of $\Omega$ of size $k$. The number of orbits has been been the subject of numerous papers, not least of these is the paper of Livingstone and Wagner~\cite{Livingstone and Wagner}. However, similar results for $G$-orbit lengths are much less common. The main contributions coming from Siemons and Wagner \cite{SandW}, \cite{SW2} and Mnukhin \cite{Munchkin}. We note that we are interested in the finite case and acknowledge much work has been done on the infinite case. In \cite{SandW} Siemons and Wagner describe a relationship between the lengths of $G$-orbits on subsets of a $G$-set $\Omega$. They proved the following; \begin{theorem}[Siemons and Wagner]\label{SW1} Let $G$ be a transitive permutation group on a finite set $\Omega$ and let $\Delta$ be a subset of $\Omega$ of cardinality $k$ such that $|\Delta^G|>|\Sigma^G|$ for every subset $\Sigma$ containing $\Delta$ of cardinality $k+1$. Then $$k+1 \ge |\Delta^{G_\Sigma}|>|\Sigma^{G_\Delta}|\ge 1.$$ Furthermore, if $k\ge 2$ then either \begin{enumerate} \item every $2$-element subset of $\Omega$ will appear in some $G$ image of $\Delta$ or \item $G$ is imprimitive with blocks of imprimitivity $\mathfrak{B}_1,...,\mathfrak{B}_r$ ($1<|\mathfrak{B}_i |<|\Omega |$) each intersecting $\Delta$ in at most $1$ point such that every $2$-element subset of the form $\{\alpha_i, \alpha_j\}$ with $\alpha_i \in \mathfrak{B}_i \ne \mathfrak{B}_j \ni \alpha_j$ is contained in some $G$ image of $\Delta$. \end{enumerate} \end{theorem} They also proved that if $G$ is primitive and $k=2$ then $G\cong L_2(5)$ with $G$ acting on $6$ points. The aim of this paper is to answer some questions regarding primitive groups with the Siemons Wagner property and more specifically the case $k=3$. The Siemons Wagner property appears to be rare amongst primitive groups, indeed we can identify all cases where $\Omega$ has cardinality $n\leq 24$. \begin{proposition}\label{PPPSW} Let $G$ be a primitive permutation group acting on a set $\Omega$ of degree $n<25$. If there exists a $k$-subset $\Delta\subset\Omega$ such that $|\Delta^G|>|\Sigma^G|$ for any $k+1$-subset $\Sigma\subset\Omega$ where $\Delta \subset \Sigma$, then $G$ is in Table~\ref{PPSW}. \begin{table}[htbp] \centering \begin{tabular}{|c|c|c|}\hline Group & Degree & k \\ \hline $ L_2(5) $ & $ 6 $ & $ 2 $ \\ $ L_2(7) $ & $ 8 $ & $ 3 $ \\ $ PGL(2,7) $ & $ 8 $ & $ 3 $ \\ $ L_2(9) $ & $ 10 $ & $ 4 $ \\ $ Sym(6) $ & $ 10 $ & $ 4 $ \\ $ L_2(11) $ & $ 12 $ & $ 5 $ \\ $ PGL(2,11) $ & $ 12 $ & $ 5 $ \\ $ L_2(13) $ & $ 14 $ & $ 6 $ \\ $ Alt(7) $ & $ 15 $ & $ 6 $ \\ $ ASL(2,4) $ & $ 16 $ & $ 6 $ \\ $ Alt(7)\ltimes (\mathbb{Z}_2)^4 $ & $ 16 $ & $ 7 $ \\ $ L_2(16) $ & $ 17 $ & $ 5 $ \\ $ L_3(4) $ & $ 21 $ & $ 6 $ \\ $ M(22) $ & $ 22 $ & $ 10 $ \\ $ M(23) $ & $ 23 $ & $ 10 $ \\ $ M(24) $ & $ 24 $ & $ 11 $ \\ \hline \end{tabular} \caption{Primitive permutation groups satisfying Siemons Wagner property} \label{PPSW} \end{table} \end{proposition} \begin{proof We can compile Table~\ref{PPSW} by direct calculation with the database of primitive groups in \textsc{Magma}. The code used to test for the Siemons Wagner property is given at the end of this paper. \end{proof} \begin{remark} We note that the database of primitive groups used in the \textsc{Magma} calculations was produced by Roney-Dougal in \cite{Colva} and Sims~\cite{SimsPrim}. \end{remark} \begin{definition} Let $G$ be a group acting on a set $\Omega$ with cardinality $n$. Denote by $\Omega_k$ the set of $k$-subsets of $\Omega$. We note that $|\Omega_k|=\binom{n}{k}$ and that $G$ has an induced action on $\Omega_k$. If $G$ is transitive on $\Omega_k$ we call $G$ $k$-homogeneous. If $G$ is a permutation group on a finite set $\Omega$ and $\Delta$ is a subset of $\Omega$ of cardinality $3$ such that $|\Delta^G|>|\Sigma^G|$ for every subset $\Sigma$ containing $\Delta$ of cardinality $4$. Then we say that $G$ satisfies condition $\star$. \end{definition} \section{General Results} Here we present a few preliminary results looking at the case when $k=3$ and take some steps towards classifying primitive groups with this property for $k=3$. In general we will make use of the following simple but effective lemma. \begin{lemma}\label{ud lemma} Let $G$ be a permutation group acting on $n$ points, let $\Sigma^G$ be an $G$-orbit of a $(k+1)$-subset, and $\Delta^G$ and $G$-orbit of a $k$-subset $\Delta$. If $\Sigma \supset \Delta$ then letting $d = |\{\alpha \in \Sigma \ | \ \Sigma\setminus\{\alpha\} \in \Delta^G\}|$ and $u=|\{\beta \in \Omega\ | \ \Delta \cup \{\beta\} \in \Sigma^G\}|$ then $$d|\Sigma^G|=u|\Delta^G|.$$ \end{lemma} \begin{proof} We form a graph with vertex set the elements of $\Sigma^G$ and $\Delta^G$, then we draw edge $(s,t)$ if and only if $t \subset s$. Then the number of edges is equal to $d|\Sigma^G|$ and $u|\Delta^G|$. \end{proof} We now are able to prove the following initial results regarding primitive permutation groups satisfying $\star$ without any further restrictions. \begin{proposition}\label{maxsize} Let $G$ be a primitive permutation group acting on a set $\Omega$ of cardinality $n\ge 8$. Let $\Delta$ be a $3$-subset of $\Omega$ such that $|\Delta^{G}|>|\Sigma^{G}|$ for all $4$-subsets $\Sigma$ containing $\Delta$. Then $\Delta^G$ is of maximal length of any orbit on $3$-subsets. \end{proposition} \begin{proof}[Proof of Proposition~\ref{maxsize}] Let $\Delta=\Delta_1$. If $G$ is $3$-homogeneous we are done, so assume there exists a $3$-subset $\Delta_2$ which is not in $\Delta_1^G.$ We wish to show that $|\Delta_1^G|\ge |\Delta_2^G|$. Theorem~\ref{SW1} tells us that every $2$-subset of $\Omega$ appears in the $G$-image of $\Delta_1,$  Hence we may assume that $|\Delta_1 \cap \Delta_2|=2.$ We may now set $\Delta_1 = \{1,2,3\}$ and $\Delta_2 = \{1,2,4\}.$ We may now choose $\Sigma =\{1,2,3,4\}$ and note that $G_\Sigma$ is not transitive on $\Sigma$ and that $|\Sigma^G|<|\Delta_1^G|.$ We now consider the possible structure of $G_\Sigma$ as a subgroup of $Sym(4).$ Theorem~\ref{SW1} tells us that $$4\ge |\Delta_1^{G_\Sigma}|>|\Sigma^{G_{\Delta_1}}| \ge 1,$$ and moreover $|\Delta_1^{G_\Sigma}|= 2$ or $3$. By applying Lemma~\ref{ud lemma} and noting that $|\Delta_1^G|>|\Sigma^G|$ we have the following equations. \begin{align*} u_1|\Delta_1^G| &= d_1|\Sigma^G|, \\ u_2|\Delta_2^G| &= d_2|\Sigma^G| .\\ \end{align*} We also note that $1\le u_1 < d_1 \le 3$ and $u_1, u_2, d_1, d_2 >0.$ If $|\Delta_1^{G_\Sigma}|=3$ then $d_1=3$ giving us $u_1|\Delta_1^G| = 3|\Sigma^G|.$ This implies that $d_2=1$. Combining these gives $$|\Delta_2^G| \le u_2|\Delta_2^G| = |\Sigma^G| =\frac{u_1|\Delta_1^G|}{3} < |\Delta_1^G|.$$ Next we consider the case when $|\Delta_1^{G_\Sigma}|=2$. Here we have $d_1=2$ and so $2|\Sigma^G|=u_1|\Delta_1^G|$. It immediately follows that $u_1=1$. Moreover $d_2|\Sigma^G|=u_2|\Delta_2^G|$ where $1\le d_2\le 2.$ Now \begin{align*} u_2|\Delta_2^G| & = d_2|\Sigma^G|,\\ u_2|\Delta_2^G| & = \frac{d_2}{2}|\Delta_1^G|,\\ \frac{2u_2}{d_2} |\Delta_2^G| & = |\Delta_1^G|. \end{align*} where $2u_2 \geq d_2$ and so $|\Delta_1^G| \ge |\Delta_2^G|$ as required. \end{proof} \begin{proposition} Let $G$ be a primitive permutation group satisfying $\star$. Let $\Delta$ be a representative of the large orbit on $\Omega_3$ and let $G_\Delta$, the set-wise stabilizer of $\Delta$ in $G,$ be transitive on $\Delta$. Then $G$ is $3$-homogeneous. \end{proposition} \begin{proof} We assume $G$ is not $3$-homogeneous, then we let $\Delta=\Delta_1$ and $\Delta_2$ be a representative from a second $G$-orbit on $\Omega_3$. By Theorem~\ref{SW1} we can assume that $\Delta_1=\{1,2,3\}$ and $\Delta_2=\{1,2,4\}$. We also let $\Sigma=\{1,2,3,4\}$. As $G_{\Delta_1}$ is transitive on $\Delta_1$ there exists $g \in G_{\Delta_1}$ such that $g=\pi_1 \pi_2 \pi_3$ where $\pi_1=(1,2,3),$ $\pi_2=(4,...,)$ (the cycle containing $4$) and $\pi_3$ is a permutation on the remaining points of $\Omega$. Now as $\Delta_1^{G_{\Sigma}}>1$ there exists a subset of $\Sigma$ of the form $\{\alpha, \beta, 4\}$ which is in $\Delta_1^G$. If $\pi_2=(4)$ then $\Delta_2 \in \Delta_1^{\left<g\right>}$ which is a contradiction. Without loss then we can assume $g$ is such that $\pi_2$ is a cycle with length some power of $3$. We then only need consider two cases. \begin{enumerate} \item $g=(1,2,3)(4,5,6)...$ or \item $g=(1)(2)(3)(4,5,6)...$ \end{enumerate} In both cases we have that $\{1,2,3,4\}, \{1,2,3,5\}, \{1,2,3,6\}$ are all in $\Sigma^{\left<g\right>}$. Using Lemma~\ref{ud lemma} we have $u|\Delta_1^G| = d|\Sigma^G|$ with $u\ge 3$ giving us that $d=4$ which is only possible if $\Delta_2 \in \Delta_1^G$ which is a contradiction. Hence $G$ is $3$-homogeneous as required. \end{proof} \section{The case that $G$ is $3$-homogeneous} The list of Primitive groups stored in \textsc{Magma} and the procedure used in Proposition~\ref{PPPSW} were used to check for any instances of the Siemons Wagner property for $k=3$ in all primitive groups of degree $n\leq 200$. The only two groups found are given in Proposition~\ref{PPPSW}. As both of these groups are $3$-homogeneous the obvious question is are there any more. \begin{theorem}\label{3hom} Let $G$ be a $3$-homogeneous permutation group acting on a $G$-set, $\Omega$, of cardinality $n\ge8$. If the $G$-orbit $\Omega_3$ has length strictly greater than the $G$-orbit of any $4$-subset of $\Omega$ then $G\cong L_2(7)$ or $G\cong PGL(2,7)$. \end{theorem} Before we prove this we mention that the following notation for $PG(q)$ is used. \begin{definition} The projective line over $\mathbb{F}_q$ contains $q+1$ points and we denote it by $PG(q)$. The composition of these points and their representatives for $\mathbb{F}_q$ is as given in Table \ref{Tab2.1}. \begin{table}[ht] \centering \begin{tabular}[h]{|l|l|} \hline Code & Span of\\ \hline $0$ & $ (1,0)$ \\ $1$ & $ (1,1)$ \\ $\vdots$ & $ \vdots$ \\ $q-1$ & $ (1,q-1) $\\ $\infty$ & $ (0,1) $\\ \hline \end{tabular} \caption{Elements of Projective Line over $\mathbb{F}_q$} \label{Tab2.1} \end{table} \end{definition} \begin{proof}[Proof of Theorem~\ref{3hom}] As $G$ is 3-homogeneous we note that any group hoping to have the property we are searching for cannot have any regular orbits on $\Omega_4$ and furthermore cannot be $4$-homogeneous. We begin by compiling a list of possible candidates using results from Kantor~\cite{Kantor} and Cameron~\cite{CamFPG}. This gives the following possibilities $M_{11}$, $M_{22}$, $AGL(1,8)$, $A\Gamma L(1,8)$, $A\Gamma L(1,32),$ $L_2(q)$ and a family of groups $L_2(q)\le G \le P\Gamma L(2,q)$, where $q \equiv\ 3$ mod $4$. Initially we can compute the groups $M_{11}$, $M_{22}$, $AGL(1,8)$, $A\Gamma L(1,8)$ and $A\Gamma L(1,32)$ and see that these do not satisfy the condition of having such a $3$-subset of their respective $G$-sets. We now eliminate the possibilities for $q$ in the remaining families of groups. We begin by noting that all the groups which remain have $L_2(q)$ as their respective socles. As the $G$-sets of these groups are the same as for their socles, we need only show that $L_2(q)$ does not satisfy the condition of having all $4$-subsets with stabilizers of order greater than $2$. This follows as the size of the orbit on $3$-subsets being as large as possible but less than $\frac{|G|}{2}$ and so any over group cannot increase the length of this $3$-orbit but could fuse two or more orbits on $\Omega_4$. Next we consider a specific subset of the projective line on which these remaining groups act. We let $\omega$ be a generator for the multiplicative field of $q$ elements, that is $\omega^{q-1}=1$. We choose $\Sigma=\{0,1,\infty,\omega^{a}\}$ where $\omega^a \not\in \{-1,2,2^{-1}\}$ and, $\omega^{2a}-\omega^{a}+1\ne 0$. We can now make use of a result in~\cite{bjl} which states that for such a set the stabilizer in $PGL(2, q)$ has order $4$. We now show that this set must have a stabilizer in $L_2(q)$ with order less than 4 by giving an element of $PGL(2,q)_\Sigma$ which is not in $L_2(q)$. $$A=\begin{bmatrix} 1 & \omega^{a} \\ -1 & -1 \ \end{bmatrix}.$$ It is clear that $A$ will act on $\Sigma$ with the cycles $(0,\omega^{a})(1,\infty)$ and so $A\in PGL(2,q)_\Sigma.$ The determinant of $A$ is equal to $\omega^{a}-1$, moreover $\omega^{a} \neq 2$ by choice and so $A\not\in L_2(q)$ as required. Hence the stabilizer of $\Sigma$ in $L_2(q)$ must have order $1$ or $2$ and so the $L_2(q)$ orbit of $\Sigma$ is greater than the total number of $3$-subsets of $PG(q)$ hence such groups cannot have a large enough $3$-subset orbit to satisfy our condition. This has now reduced our problem to finding fields for which no such element $\omega^a$ exists. We also note that we are interested in $q\ge 7$. In fact $q=7$ is the only such field in our range without such an element as a simple counting argument shows that any field with more than 8 elements must satisfy this requirement. Finally we note that $L_2(7)<PGL(2,7) = P\Gamma L(2,7)$ and that Proposition~\ref{PPPSW} shows both of these groups satisfy the condition. \end{proof} We leave this section with the following Conjecture. \begin{conjecture} Let $G$ be a primitive permutation group acting on a $G$-set, $\Omega$, of cardinality $n\ge8$. If there exists a $3$-subset $\Delta\subset\Omega$ such that $|\Delta^G|>|\Sigma^G|$ for any $4$-subset $\Sigma$ containing $\Delta$, then $G\cong PSL(2,7)$ or $G\cong PGL(2,7)$. \end{conjecture} \section{Non-primitive group examples} For the reader's consideration we now turn briefly to non-primitive but transitive examples of groups with the Siemons Wagner property when $k=3.$ These are far more common than imprimitive examples. We present here three such groups and give their generators. In all three of the following examples we keep $\Delta=\{1,2,3\}$ as a representative of the large orbit on $\Omega_3$. For a given permutation group $G$ acting on a set $\Omega$, we denote the number of $G$-orbits on $\Omega_k$ by $\sigma_k$. Example 1 is a subgroup of $Sym(8)$ where \begin{eqnarray*} G_1 & \cong & \langle(4,6),(1,2,5,3)(4,8)(6,7),(1,8)(4,6),(3,4,6),(1,7,8),(2,3)(4,6), \\ & &(2,4)(3,6),(1,5)(7,8),(1,7)(5,8)\rangle.\\ \end{eqnarray*} Here $|G_1|=1152$ and $|\Delta^{G_1}|=48$. This group satisfies the condition that every $2$-subset appears in some $G_1$-image of $\Delta$. The system of imprimitivity for $G_1$ is the set $$\left\{\{1,5,7,8\},\{2,3,4,6\}\right\}.$$ The $\sigma_k$ values are $\sigma_1=1,\ \sigma_2=2,\ \sigma_3=2$ and $\sigma_4=3$. It is also clear that there exists a $4$-subset for which no $G_1$-image contains $\Delta$ as a subset (the system of imprimitivity is a single orbit). Example 2 is a subgroup of $Sym(9)$ where \begin{eqnarray*} G_2 & \cong & \langle(4,7)(5,9)(6,1),(8,9,5)(2,7,4)(3,1,6), \\ & & (4,5,6)(7,1,9),(8,3,2)(7,1,9)\rangle. \end{eqnarray*} Here $|G_2|=54$ and $|\Delta^{G_2}|=54$. This group satisfies the condition that every $2$-subset appears in some $G_2$-image of $\Delta$. The system of imprimitivity for $G_2$ is the set $$\{\{1,7,9\},\{2,3,8\},\{4,5,6\}\}.$$ The $\sigma_k$ values are $\sigma_1=1,\ \sigma_2=2,\ \sigma_3=5$ and $\sigma_4=5$. In this case $\Delta$ appears as a subset of an element of every $G_2$-orbit on subsets of size $4.$ Example 3 is a subgroup of $Sym(16)$ where \begin{eqnarray*} G_3 & \cong & \langle (1, 12)(7, 3)(11, 8)(4, 2)(5, 10)(6, 9)(13, 15)(14, 16),\\ & &(1, 8, 6, 14)(7, 2, 5, 13)(11, 9, 16, 12)(4, 10, 15, 3),\\ & &(1, 14)(7, 13)(11, 12)(4, 3)(5, 2)(6, 8)(9, 16)(10, 15),\\ & & (1, 6)(7, 5)(11, 15)(4, 16)(2, 14)(8, 13)(9, 12)(10, 3),\\ & & (1, 16)(7, 15)(11, 6)(4, 5)(2, 3)(8, 12)(9, 14)(10, 13),\\ & & (7, 8)(9, 10)(3, 12)(13, 14),\\ & & (11, 4)(9, 10)(3, 12)(15, 16),\\ & & (1, 7)(11, 4)(5, 6)(2, 8)(9, 10)(3, 12)(13, 14)(15, 16)\rangle.\\ \end{eqnarray*} Here $|G_3|=256$ and $|\Delta^{G_3}|=256$. This group does not satisfy the condition of every $2$-subset being contained in some $G_3$-image of $\Delta$. The $\sigma_k$ values for $G_3$ are $\sigma_1=1,$ $\sigma_2=6,$ $\sigma_3=11,$ $\sigma_4=35,$ $\sigma_5=48,$ $\sigma_6=91,$ $\sigma_7=100$ and $\sigma_8=132.$ Here we have three systems of imprimitivity $$ \{ \{ 1, 5 \}, \{ 2, 14 \}, \{ 3, 9 \}, \{ 4, 16 \}, \{ 6, 7 \}, \{ 8, 13 \}, \{ 10, 12 \}, \{ 11, 15 \}\},$$ $$\{ \{ 3, 9, 10, 12 \}, \{ 1, 5, 6, 7 \}, \{ 4, 11, 15, 16 \}, \{ 2, 8, 13, 14 \} \}$$ and $$ \{ \{ 1, 3, 5, 6, 7, 9, 10, 12 \}, \{ 2, 4, 8, 11, 13, 14, 15, 16 \}\}.$$ It is also clear that there exists a $4$-subset for which no $G_3$-image contains $\Delta$ as a subset (the system of imprimitivity is a single orbit). \section{\textsc{Magma} Code for Proposition~\ref{PPPSW}} We finish by giving the \textsc{Magma} implementation for the search for Primitive groups with the Siemons Wagner property used to compile Table~\ref{PPSW} \begin{verbatim} Z:=Integers(); SizeofOrbsPRIMk:=procedure(G,k,~a); S:={}; K:={}; D:={1..Degree(G)}; kD:=Subsets(D,k);a:={}; Omega:=GSet(G,kD); O:=Orbits(G,Omega); for Orbs in O do T:=Random(Orbs); Include(~K,T); end for; V:={}; for T in K do; N:=Z!(#G/#Stabilizer(G,T)); P:=D diff T; for b in P do; Include(~V, #Stabilizer(G, T join{b})); end for; S:=Min(V);L:= Z!(#G/S); if N gt L then Include(~a,<N,T>); end if; end for; end procedure; \end{verbatim} Letting $D$ be the degree. \begin{verbatim} for k in [3..Z!(Floor(D/2)-1)] do for I:=1 to (Z!(NumberOfPrimitiveGroups(D)-2)) do SizeofOrbsPRIMk(PrimitiveGroup(D, I),k,~T); if #T ge 1 then <D,I,T>; end if; end for; end for; \end{verbatim}
\chapter*{Abstract\markboth{Abstract}{Abstract}}\label{ch:Abstract} \addcontentsline{toc}{chapter}{Abstract} The cocktail party problem comprises the challenging task of listening to and understanding a speech signal in a complex acoustic environment, where multiple speakers and background noise signals simultaneously interfere with the speech signal of interest. A signal processing algorithm that can effectively increase the speech intelligibility and quality of speech signals in such complicated acoustic situations is highly desirable. Especially for applications involving mobile communication devices and hearing assistive devices, increasing speech intelligibility and quality of noisy speech signals has been a goal for scientists and engineers for more than half a century. Due to the re-emergence of machine learning techniques, today, known as deep learning, the challenges involved with such algorithms might be overcome. In this PhD thesis, we study and develop deep learning-based techniques for two major sub-disciplines of the cocktail party problem: \emph{single-microphone speech enhancement} and \emph{single-microphone multi-talker speech separation}. Specifically, we conduct in-depth empirical analysis of the generalizability capability of modern deep learning-based single-microphone speech enhancement algorithms. We show that performance of such algorithms is closely linked to the training data, and good generalizability can be achieved with carefully designed training data. Furthermore, we propose \acf{uPIT}, a deep learning-based algorithm for single-microphone speech separation and we report state-of-the-art results on a speaker-independent multi-talker speech separation task. Additionally, we show that uPIT works well for joint speech separation and enhancement without explicit prior knowledge about the noise type or number of speakers, which, at the time of writing, is a capability only shown by uPIT. Finally, we show that deep learning-based speech enhancement algorithms designed to minimize the classical short-time spectral amplitude mean squared error leads to enhanced speech signals which are essentially optimal in terms of \acf{STOI}, a state-of-the-art speech intelligibility estimator. This is important as it suggests that no additional improvements in STOI can be achieved by a deep learning-based speech enhancement algorithm, which is designed to maximize STOI. \clearpage{\pagestyle{empty}\cleardoublepage} \chapter*{Resumé\markboth{Resumé}{Resumé}}\label{ch:Resume} \addcontentsline{toc}{chapter}{Resumé} {\selectlanguage{danish} Cocktailparty-problemet beskriver udfordringen ved at forstå et talesignal i et komplekst akustisk miljø, hvor stemmer fra adskillige personer, samtidig med baggrundsstøj, interferer med det ønskede talesignal. En signalbehandlings algoritme, som effektivt kan øge taleforståeligheden eller talekvaliteten af støjfyldte talesignaler, er yderst eftertragtet. Specielt indenfor applikationer som vedrører mobil kommunikation eller høreapparater, har øgning af taleforståelighed eller talekvalitet af støjfyldte talesignaler været et mål for videnskabsfolk og ingeniører i mere end et halvt århundrede. Grundet en genopstået interesse for maskinlærings teknikker, som i dag er kendt som dyb læring, kan nogle af de udfordringer som er forbundet med sådanne algoritmer, måske blive løst. I denne Ph.d.-afhandling studerer og udvikler vi dyb-læringsbaserede teknikker anvendeligt for to store underdiscipliner af cocktailparty-problemet: \emph{enkelt-mikrofon taleforbedring} og \emph{enkelt-mikrofon multi-taler taleseparation.} Specifikt foretager vi dybdegående empiriske analyser af generaliserings-egenskaberne af moderne dyb-læringsbaserede enkelt-mikrofons taleforbed-ringsalgoritmer. Vi viser at ydeevnen af disse algoritmer er tæt forbundet med mængden og kvaliteten af træningsdata, og gode generaliseringsegenskaber kan opnås ved omhyggeligt designet træningsdata. Derudover præsenterer vi utterance-level Permutation Invariant Training (uPIT), en dyb læringsbaseret algoritme til enkelt-mikrofon taleseparation og vi rapporterer state-of-the-art resultater for en taler-uafhængig multi-taler taleseparationsopgave. Ydermere viser vi, at uPIT fungerer godt til både taleseparation samt taleforbedring samtidigt, hvilket på tidspunktet for denne afhandling, er en egenskab, som kun uPIT har. Endelig viser vi, at dyb-læringsbaserede taleforbedrings algoritmer som er designet til at maksimere den klassiske short-time spectral amplitude mean squared error fører til forbedrede talesignaler, som essentielt er optimale med hensyn til} Short-Time Objective Intelligibility (STOI), {\selectlanguage{danish} en state-of-the-art taleforståelighedsprædiktor. Dette er vigtig, da det antyder at ingen yderligere forbedring af STOI kan opnås selv med dyb-læringsbaserede taleforbedrings algoritmer, som er designet til at maksimere STOI. } \chapter*{List of Abbreviations\markboth{List of Abbreviations}{List of Abbreviations}}\label{ch_listAcry} \pagestyle{fancy} \addcontentsline{toc}{chapter}{List of Abbreviations} \begin{acronym}[RASTA-PLPEEE]\setlength{\itemsep}{0.2ex} \acro{ADFD}{Akustiske Databaser for Dansk} \acro{AI}{Artificial Intelligence} \acro{AMS}{Amplitude Modulation Spectrogram} \acro{AM}{Amplitude Mask} \acro{ANN}{Artificial Neural Network} \acro{ASA}{Auditory Scene Analysis} \acro{ASR}{Automatic Speech Recognition} \acro{AUC}{Area Under ROC curve} \acro{BBRBM}{Bernoulli-Bernoulli RBM} \acro{BLSTM}{Bi-directional Long Short-Term Memory} \acro{BM}{Boltzmann Machine} \acro{BNN}{Biological Neural Network} \acro{BSS}{Blind-Source Separation} \acro{CASA}{Computational Auditory Scene Analysis} \acro{CC}{Closed-Condition} \acro{CDF}{Cumulative Distribution Function} \acro{CD}{Contrastive Divergence} \acro{CNN}{Convolutional Neural Network} \acro{CNTK}{Microsoft Cognitive Toolkit} \acro{CPU}{Central Processing Unit} \acro{DANet}{Deep Attractor Network} \acro{DBN}{Deep Belief Network} \acro{DBRNN}{Deep Bidirectional Recurrent Neural Network} \acro{DCT}{Discrete Cosine Transform} \acro{DFT}{Discrete Fourier Transform} \acro{DL}{Deep Learning} \acro{DNN}{Deep Neural Network} \acro{DPCL}{Deep Clustering} \acro{DRNN}{Deep Recurrent Neural Network} \acro{DTFT}{Discrete-Time Fourier Transform} \acro{EER}{Equal Error Rate} \acro{ELC}{Envelope Linear Correlation} \acro{EMSE}{Envelope Mean Squared Error} \acro{EM}{Expectation-Maximization} \acro{ERB}{Equivalent Rectangular Bandwidth} \acro{ESTOI}{Extended Short-Time Objective Intelligibility} \acro{EVD}{Eigen-Value Decomposition} \acro{FA}{False Alarm} \acro{FCT}{Fast Cosine Transform} \acro{FFT}{Fast Fourier Transform} \acro{FHMM}{Factorial Hidden Markov Model} \acro{FIR}{Finite Impulse Response} \acro{FLOPS}{Floating-point Operations Per Second} \acro{FNN}{Feed-forward Neural Network} \acro{GBRBM}{Gaussian-Bernoulli RBM} \acro{GFE}{Gammatone Filter bank Energies} \acro{GMM}{Gaussian Mixture Model} \acro{GPU}{Graphics Processor Unit} \acro{HINT}{Hearing In Noise Test} \acro{HIT-FA}{HIT minus False Alarm} \acro{HMM}{Hidden Markov Model} \acro{HPC}{High Performance Computing} \acro{IAM}{Ideal Amplitude Mask} \acro{IBM}{Ideal Binary Mask} \acro{IDCT}{Inverse Discrete Cosine Transform} \acro{IDFT}{Inverse Discrete Fourier Transform} \acro{IID}{Independent and Identically Distributed} \acro{IIR}{Infinite Impulse Response} \acro{INPSM}{Ideal Non-negative Phase Sensitive Mask} \acro{IPSF}{Ideal Phase Sensitive Filter} \acro{IPSM}{Ideal Phase Sensitive Mask} \acro{IRM}{Ideal Ratio Mask} \acro{ITS}{Inverse Transform Sampling} \acro{IUT}{Implementation Under Test} \acro{KLD}{Kullback-Leibler Divergence} \acro{KLT}{Karhunen-Loève Transform} \acro{LC}{Local Criterion} \acro{LPC}{Linear Predictive Coding} \acro{LP}{Linear Prediction} \acro{LSTM}{Long Short-Term Memory} \acro{MAP}{Maximum a Posteriori} \acro{MCMC}{Markov Chain Monte Carlo} \acro{ME}{Miss Error} \acro{MFCC}{Mel-Frequency Cepstrum Coefficient} \acro{MIMD}{Multiple Instruction Multiple Data} \acro{MLP}{Multi-Layer Perceptron} \acro{ML}{Maximum Likelihood} \acro{MMELC}{Maximum Mean Envelope Linear Correlation} \acro{MMSE}{Minimum Mean Squared Error} \acro{MOS}{Mean Opinion Score} \acro{MRF}{Markov Random Field} \acro{MSE}{Mean Squared Error} \acro{NGDRNN}{Noise General Deep Recurrent Neural Network} \acro{NMF}{Non-negative Matrix Factorization} \acro{NN}{Neural Network} \acro{NSDRNN}{Noise Specific Deep Recurrent Neural Network} \acro{OC}{Open-Condition} \acro{OIM}{Objective Intelligibility Measure} \acro{PCD}{Persistent Contrastive Divergence} \acro{PDF}{Probability Density Function} \acro{PESQ}{Perceptual Evaluation of Speech Quality} \acro{PIT}{Permutation Invariant Training} \acro{PLP}{Perceptual Linear Prediction} \acro{PMF}{Probability Mass Function} \acro{PSA}{Phase Sensitive Approximation} \acro{PSD}{Power Spectral Density} \acro{PSF}{Phase Sensitive Filter} \acro{PSM}{Phase Sensitive Mask} \acro{PT}{Parallel Tempering} \acro{RASTA-PLP}{Relative Spectral Transform - Perceptual Linear Prediction} \acro{RASTA}{Relative Spectral} \acro{RBM}{Restricted Boltzmann Machine} \acro{RMS}{Root Mean Square} \acro{RNN}{Recurrent Neural Network} \acro{ROC}{Receiver Operating Characteristics} \acro{ReLU}{Rectified Linear Unit} \acro{ReLu}{Rectified Linear unit} \acro{SAR}{Source-to-Artifact Ratio} \acro{SDR}{Source-to-Distortion Ratio} \acro{SE}{Speech Enhancement} \acro{SGD}{Stochastic Gradient Descent} \acro{SIFT}{Scale-Invariant Feature Transform} \acro{SIMD}{Single Instruction Multiple Data} \acro{SIR}{Source-to-Interference Ratio} \acro{SISD}{Single Instruction Single Data} \acro{SI}{Speech Intelligibility} \acro{SNR}{Signal-to-Noise Ratio} \acro{SPP}{Speech Presence Probability} \acro{SQ}{Speech Quality} \acro{SR}{Speaker Recognition} \acro{SSN}{Speech Shaped Noise} \acro{STFT}{Short-Time Fourier Transform} \acro{STOI}{Short-Time Objective Intelligibility} \acro{STSA}{Short-Time Spectral Amplitude} \acro{SVD}{Singular-Value Decomposition} \acro{SVM}{Support Vector Machine} \acro{SV}{Speaker Verification} \acro{T-F}{Time-Frequency} \acro{TIMIT}{Texas Instruments Massachusetts Institute of Technology} \acro{UBM}{Universal Background Model} \acro{VAD}{Voice Activity Detection} \acro{WSJ0}{Wall Street Journal} \acro{WGN}{White Gaussian Noise} \acro{WSS}{Wide Sense Stationary} \acro{uPIT}{utterance-level Permutation Invariant Training} \end{acronym} \chapter*{About the Author\markboth{About the Author}{About the Author}}\label{ch:cv} \pagestyle{fancy} \addcontentsline{toc}{chapter}{About the Author} \begin{tabularx}{\textwidth}{@{}Xr} \Large Morten Kolbæk & \raisebox{-\totalheight/2}{\includegraphics[width=2cm]{frontmatter/image_round_corn.jpg}}\\ \end{tabularx}\par \vspace{0.5cm}\noindent Morten Kolbæk received the B.Eng. degree in electronic design at Aarhus University, Business and Social Sciences, AU Herning, Denmark, and the M.Sc. degree in signal processing and computing from Aalborg University, Denmark, in 2013 and 2015, respectively. He is currently pursuing his PhD degree at the section for Signal and Information Processing at the Department of Electronic Systems, Aalborg University, Denmark, under the supervision of Professor Jesper Jensen and Professor Zheng-Hua Tan. His main research interests include single-microphone algorithms for speech enhancement and multi-talker speech separation, machine learning, deep learning in particular, and intelligibility improvement of noisy speech for hearing aids applications. \chapter*{Preface\markboth{Preface}{Preface}}\label{ch:preface} \pagestyle{fancy} \addcontentsline{toc}{chapter}{Preface} This thesis documents the scientific work carried out as part of the PhD project entitled \emph{Single-Microphone Speech Enhancement and Separation Using Deep Learning}. The thesis is submitted to the Technical Doctoral School of IT and Design at Aalborg University in partial fulfillment of the requirements for the degree of Doctor of Philosophy. The project was funded by the Oticon Foundation\footnote{\url{http://www.oticonfoundation.com}}, and the work was carried out in the period from September 2015 to August 2018 within the Signal and Information Processing Section, in the Department of Electronic Systems, at Aalborg University. Parts of the work was carried out during a four-month secondment at the Interactive Systems Design Lab at the University of Washington, Seattle USA, and at Microsoft Research, Redmond USA. The thesis is structured in two parts: a general introduction and a collection of scientific papers. The introduction review classical algorithms and deep learning-based algorithms for single-microphone speech enhancement and separation, and furthermore summarizes the scientific contributions of the PhD project. The introduction is followed by a collection of seven papers that are published in or submitted to peer-reviewed journals or conferences. I would like to express my deepest gratitude to my two supervisors Jesper Jensen and Zheng-Hua Tan for their support and guidance throughout the project. In particular, I would like to thank Jesper Jensen for his sincere dedication to the project and for his abundant, and seemingly endless, supply of constructive criticism, which, although daunting at times, unarguably has improved all aspects of my work. Furthermore, I would like to give a special thanks to Dong Yu for a very giving and pleasant collaboration for which I am very grateful. Also, I would like to thank Les Atlas, Scott Wisdom, Tommy Powers and David Dolengewicz from the Interactive Systems Design Lab for their hospitality and helpfulness during my stay at University of Washington. Last, but not least, I wish to thank my family for their unconditional support. \vfill \begin{flushright} Morten Kolbæk\\ Bjerghuse, July 17, 2018 \end{flushright} \chapter*{List of Publications\markboth{List of Publications}{List of Publications}}\label{ch_listPub} \pagestyle{fancy} \addcontentsline{toc}{chapter}{List of Publications} This main body (Part II) of this thesis consists of the following publications: \begin{enumerate} \item[{[A]}] {\small M. Kolbæk, Z. H. Tan, and J. Jensen, “Speech Intelligibility Potential of General and Specialized Deep Neural Network Based Speech Enhancement Systems”, \textit{IEEE/ACM Transactions on Audio, Speech, and Language Processing}, vol. 25, no. 1, pp. 153–167, January 2017.} % \item[{[B]}] {\small M. Kolbæk, Z.-H. Tan, and J. Jensen, “Speech Enhancement Using Long Short-Term Memory Based Recurrent Neural Networks for Noise Robust Speaker Verification”, \textit{IEEE Spoken Language Technology Workshop}, pp. 305-311, December 2016.} % \item[{[C]}] {\small D. Yu, M. Kolbæk, Z.-H. Tan, and J. Jensen, “Permutation Invariant Training of Deep Models for Speaker-Independent Multi-Talker Speech Separation”, \textit{IEEE International Conference on Acoustics, Speech, and Signal Processing}, pp 241-245, March 2017.} % \item[{[D]}] {\small M. Kolbæk, D. Yu, Z.-H. Tan, and J. Jensen, “Multi-Talker Speech Separation With Utterance-Level Permutation Invariant Training of Deep Recurrent Neural Networks”, \textit{IEEE/ACM Transactions on Audio, Speech, and Language Processing}, vol. 25, no. 10, pp. 1901-1913, October 2017.} % \item[{[E]}] {\small M. Kolbæk, D. Yu, Z.-H. Tan, and J. Jensen, “Joint Separation and Denoising of Noisy Multi-Talker Speech Using Recurrent Neural Networks and Permutation Invariant Training”, \textit{IEEE International Workshop on Machine Learning for Signal Processing}, pp. 1-6, September 2017.} % \item[{[F]}] {\small M. Kolbæk, Z.-H. Tan, and J. Jensen, “Monaural Speech Enhancement Using Deep Neural Networks by Maximizing a Short-Time Objective Intelligibility Measure”, \textit{IEEE International Conference on Acoustics, Speech, and Signal Processing}, pp 5059-5063, April 2018.} % \item[{[G]}] {\small M. Kolbæk, Z.-H. Tan, and J. Jensen, “On the Relationship Between Short-Time Objective Intelligibility and Short-Time Spectral-Amplitude Mean-Square Error for Speech Enhancement”, \textit{IEEE/ACM Transactions on Audio, Speech, and Language Processing}, vol. 27, no. 2, pp. 283-295, February 2019.} \end{enumerate} \section{Scientific Contribution}\label{sec:contrib} The main body of this thesis (Part II) consists of a collection of seven papers. These papers have contributed scientifically by analyzing state-of-the-art techniques, leading to novel insights, or improving state-of-the-art techniques, with novel algorithms, within two disciplines: Deep learning-based single-microphone speech enhancement and deep learning-based single-\linebreak microphone multi-talker speech separation. Figure \ref{fig:contrib} summarizes for each of the seven papers the type of scientific contribution and the discipline within which the contribution is made. \begin{figure*}[ht] \centering \resizebox {0.81\textwidth} {!} { \begin{tikzpicture}[baseline=(current bounding box.north)] \input{figures/contrib.tex} \end{tikzpicture}} % % {\fontsize{6.2}{7.44}\selectfont \begin{multicols}{2} \begin{enumerate} \item[{[A]}] {“Speech Intelligibility Potential of General and Specialized Deep Neural Network Based Speech Enhancement Systems”, \textit{IEEE/ACM Transactions on Audio, Speech, and Language Processing}, January 2017.} % % \item[{[B]}] {“Speech Enhancement Using Long Short-Term Memory Based Recurrent Neural Networks for Noise Robust Speaker Verification”, \textit{IEEE Spoken Language Technology Workshop}, December 2016.} % % \item[{[C]}] {“Permutation Invariant Training of Deep Models for Speaker-Independent Multi-talker Speech Separation”, \textit{IEEE International Conference on Acoustics, Speech, and Signal Processing}, March 2017.} % \item[{[D]}] {“Multi-talker Speech Separation With Utterance-Level Permutation Invariant Training of Deep Recurrent Neural Networks”, \textit{IEEE/ACM Transactions on Audio, Speech, and Language Processing}, October 2017.} \end{enumerate} \columnbreak \begin{enumerate} % \item[{[E]}] {“Joint Separation and Denoising of Noisy Multi-talker Speech Using Recurrent Neural Networks and Permutation Invariant Training”, \textit{IEEE International Workshop on Machine Learning for Signal Processing}, September 2017.} % \item[{[F]}] {“Monaural Speech Enhancement Using Deep Neural Networks by Maximizing a Short-Time Objective Intelligibility Measure”, \textit{IEEE International Conference on Acoustics, Speech, and Signal Processing}, April 2018.} % \item[{[G]}] {“On the Relationship between Short-Time Objective Intelligibility and Short-Time Spectral-Amplitude Mean Squared Error for Speech Enhancement”, \textit{under major revision in IEEE/ACM Transactions on Audio, Speech, and Language Processing}, August 2018.} % \vfill\null \end{enumerate} \end{multicols} } \caption{Scientific contribution of the papers making up this thesis: 1) Papers [A], [B], and [G] analyze state-of-the-art speech enhancement and contribute with novel insights. 2) Paper [F] improves state-of-the-art speech enhancement with a novel algorithm. 3) Paper [E] analyzes state-of-the-art multi-talker speech separation and contributes with novel insights. 4) Papers [C] and [D] improve state-of-the-art multi-talker speech separation with novel algorithms.} \label{fig:contrib} \end{figure*} \subsection{Specific Contributions} In the following, we shortly summarize the main scientific contribution of each paper in Part II. \subsubsection*{[A] Speech Intelligibility Potential of General and Specialized Deep Neural Network Based Speech Enhancement Systems} In this paper, we study the generalizability capability of deep learning-based single-microphone speech enhancement algorithms. Specifically, we investigate how speech enhancement systems based on FNNs perform in terms of PESQ and STOI when tested in acoustic scenarios that are either matched or unmatched, i.e. the noise type, speaker, or SNR used for testing are either similar or different from the noise type, speaker or SNR used for training. This is motivated by recent studies where large improvement in PESQ and STOI have been reported by DNN based speech enhancement systems that are narrowly trained. Not surprisingly, we find that one generally loses performance when a system that is trained in a narrow acoustic setting is tested in a more general and realistic acoustic scenario. We also find that matching the noise type is the most critical for acquiring good speech enhancement performance, whereas matching the SNR is less critical and good performance for unmatched speakers can be achieved if only a modest number of speakers are included in the training set. \subsubsection*{[B] Speech Enhancement Using Long Short-Term Memory Based Recurrent Neural Networks for Noise Robust Speaker Verification} In this paper, we study the generalizability capability of a deep learning-based speech enhancement algorithm with respect to noise robust speaker verification. Specifically, we propose to use a LSTM-RNN based speech enhancement algorithm as a denoising front-end for a noise robust and male-speaker-independent speaker verification system. Compared to two baseline systems based on a STSA-MMSE estimator and NMF, we find that the denoising front-end based on the LSTM-RNN performed the best in terms of equal error rate on a speaker verification task, when tested using various noise types and SNRs. Despite the fact that the LSTM-RNN was tested in unmatched male-speaker and noise type conditions, it outperformed the NMF based baseline even though this baseline utilized \emph{a priori} information about both the speaker and noise type. \subsubsection*{[C] Permutation Invariant Training of Deep Models for Speaker-Indepen-\linebreak dent Multi-talker Speech Separation} In this paper, we propose a deep learning-based technique for single-micro-phone speaker-independent multi-talker speech separation. Specifically, we propose the \ac{PIT} technique, which circumvent the label permutation problem, mentioned in Sec.\,\ref{deepsep}, and allow DNNs to be trained successfully for speaker-independent multi-talker speech separation. We evaluate PIT using FNNs and CNNs for two-talker speech separation using both matched speakers, i.e. same speakers for training and test, and unmatched speakers, i.e. different speakers for training and test. We find that FNNs and CNNs trained with PIT and tested on a speaker-independent two-talker speech separation task achieved state-of-the-art results, and outperformed techniques based on CASA and NMF in terms of SDR. We also find that CNNs trained with PIT perform on par with the deep clustering technique proposed in \cite{hershey_deep_2016}, although the PIT models are computationally less complex. Finally, we find that models trained with PIT generalize well to a Danish dataset, although the models have only been trained on English speech. \subsubsection*{[D] Multi-talker Speech Separation With Utterance-Level Permutation Invariant Training of Deep Recurrent Neural Networks} In this paper, we propose the \ac{uPIT} technique, which is an extension of the PIT technique proposed in [C]. Although PIT allowed for deep learning-based speaker-independent multi-talker speech separation, PIT only works well in practice, when large signal contexts, i.e. a large number of frames, are used. This is a limitation for applications that require low latency. The uPIT technique, on the other hand, does not have this drawback. In this paper we show that LSTM-RNNs trained using uPIT can achieve state-of-the-art results on a speaker-independent multi-talker speech separation task with both two-speaker and three-speaker mixed speech. Furthermore, we show that these models can achieve this performance using a small signal context of one frame, which is a dramatic reduction compared to the 50 or 100 frames required by PIT. Also, similarly to PIT, uPIT perform on par with deep clustering even though uPIT is algorithmically much simpler than deep clustering. Finally, we show that a single LSTM-RNN successfully separates both two-speaker and three-speaker mixed speech without \emph{a priori} knowledge about the number of speakers. \subsubsection*{[E] Joint Separation and Denoising of Noisy Multi-talker Speech Using Recurrent Neural Networks and Permutation Invariant Training} In this paper, we study aspects of the uPIT technique. Specifically, we investigate how uPIT can be used for single-microphone speaker-independent multi-talker speech separation and enhancement, simultaneously. This is different from previously speech enhancement techniques (see Sec.\,\ref{deepse}) that only consider a single target speaker and existing speech separation techniques (see Sec.\,\ref{deepsep}), that consider only noise-free multi-talker mixtures. We show that LSTM-RNNs trained using uPIT in noisy environments can improve SDR as well as ESTOI, on a speaker-independent multi-talker speech separation and enhancement task, for various noise types and SNRs. We also show that a LSTM-RNN trained using uPIT generalize well to unmatched noise types and that a single model is capable of handling multiple noise types with only a slight decrease in performance. Finally, we show that a LSTM-RNN trained using uPIT can improve both SDR and ESTOI without \emph{a priori} knowledge about the exact number of speakers. \subsubsection*{[F] Monaural Speech Enhancement Using Deep Neural Networks by Maximizing a Short-Time Objective Intelligibility Measure} In this paper, we propose to use a STOI inspired cost function for training DNNs for single-microphone speech enhancement. Since STOI has proven an accurate estimator of speech intelligibility, it is hypothesized that a DNN that is trained to estimate speech that maximizes STOI, might lead to speech with a large speech intelligibility. Specifically, compared to the standard \ac{STSA}-\ac{MSE} cost function, which does not have any obvious link to speech intelligibility, a cost function inspired by STOI might be advantageous. We show that FNNs, trained with an approximate-STOI cost function, improve STOI when tested using matched and unmatched noise types, at multiple SNRs. More surprisingly, we observe that approximate-STOI optimal FNNs perform on par with FNNs based on the standard STSA-MSE cost function. Consequently, our results suggest that DNN based speech enhancement algorithms, based on the STSA-MSE cost function, might be essentially optimal in terms of estimated speech intelligibility as measured by STOI. \subsubsection*{[G] On the Relationship between Short-Time Objective Intelligibility and Short-Time Spectral-Amplitude Mean Squared Error for Speech Enhancement} In this paper, we analyze the surprising result of paper [F], where no apparent gain in STOI can be achieved by a FNN based speech enhancement system trained to maximize an approximate-STOI cost function, as compared to a system trained to minimize the classical STSA-MSE cost function. We show theoretically that the optimal Bayesian estimator that maximizes approximate-STOI, under certain general conditions, is asymptotically equivalent to the well-known STSA minimum mean square error estimator. Furthermore, through simulation experiments, we show that equality holds for practical FNN based speech enhancement systems. The theoretical and empirical results presented in this paper support the surprising result in paper [F] and optimizing for STSA-MSE leads to enhanced speech signals which are essentially optimal in terms of STOI. \subsection{Summary of Contributions} The main scientific outcomes of this thesis may be summarized as follows: 1) In papers [A] and [B], in-depth empirical analysis of the generalizability capability of modern deep learning-based single-microphone speech enhancement algorithms have been conducted. In paper [A] it is found, not surprisingly, that performance generally decreases as the acoustic variability of the test data increases. However, it is found that good generalizability with respect to unmatched speakers can be achieved if a modest amount of speakers are included in the training set. Furthermore, in paper [B] it is shown that a DNN based speech enhancement system can generalize to unmatched speakers and achieve state-of-the-art speaker verification performance without \emph{a priori} knowledge about the speakers. The findings in papers [A] and [B], besides from contributing with novel insights, can serve as guidelines in speech-enhancement-algorithm selection or in the design process of future deep learning-based speech enhancement systems. 2) In papers [C], [D], and [E], state-of-the-art techniques for deep learning-based single-microphone speaker-independent multi-talker speech separation were proposed. Specifically, the uPIT technique was proposed, which is algorithmically simpler, yet perform on par with state-of-the-art techniques, such as deep clustering and the deep attractor network. Furthermore, uPIT easily extends to multiple speakers and works well for joint speech separation and enhancement without explicit \emph{a priori} knowledge about the noise type or number of speakers, which, at the time of writing, is a capability only shown by uPIT. 3) In papers [F] and [G], it was hypothesized that DNN based speech enhancement systems, trained with an approximate-STOI cost function, would lead to estimated speech signals with an improved STOI score, compared to speech signals estimated by systems trained with the standard STSA-MSE cost function. However, supported by experimental and theoretical results, we conclude that this is not the case. In fact, STSA-MSE leads to enhanced speech signals which are essentially optimal in terms of STOI, and additional improvements in STOI cannot be achieved by a STOI inspired cost function. \section{Deep Learning}\label{deeplearn} Section \ref{sec:classical_se} reviewed classical techniques that have been proposed to solve the single-microphone speech enhancement and single-microphone multi-talker speech separation tasks. Although, these techniques are very different, and try to solve different tasks, most of them rely heavily on one key component: \emph{domain knowledge}. For example, the Wiener filters and \ac{STSA}-\ac{MMSE} estimators reviewed in Sec.\,\ref{classe} are designed based on the assumption that speech and noise have different statistical characteristics that are governed by basic probability distributions. Similarly, techniques reviewed in Sec.\,\ref{classep} for multi-talker speech separation, such as the \ac{CASA}-based techniques, rely on detailed knowledge about the human auditory and speech production systems. Obviously, domain knowledge is extremely helpful when it is correct, and it has, and still is, used to solve many engineering problems. However, for complex tasks, utilizing domain knowledge might not be easy and it might even be destructive if the wrong assumptions are used. In other words, domain knowledge is useful for tasks that are well understood by the human engineers working on them. Instead, for complex tasks, it might lead to more successful solutions if the solution is learned, e.g. using a reinforcement strategy similarly to what is used in nature \cite{schultz_neural_1997}. This philosophy, \emph{learning} the solution instead of designing it, is one of the defining principles in the deep learning paradigm \cite{bengio_learning_2009,deng_deep_2014,lecun_deep_2015} and combined with the other defining principle, \emph{depth}, it led to the deep learning revolution we know today, which is the topic of this section. \subsection{The Deep Learning Revolution}\label{deeplearnrev} We are currently experiencing a deep learning revolution \cite{lecun_deep_2015,sejnowski_deep_2018}, and although \emph{deep learning} as an everyday term is less than a decade old, some of the fundamental principles used by deep learning algorithms today, dates back more than half a century \cite{lippmann_introduction_1987}. In fact, the first successful application of the prototypical learning model used in deep learning, the \acf{ANN} (to be introduced in Sec.\,\ref{sec:fnn}), was achieved by Frank Rosenblatt in the late 1950's with his \emph{perceptron} learning model \cite{rosenblatt_perceptron:_1958,rosenblatt_principles_1961}, and shortly after by Bernard Widrow with a model known as ADALINE \cite{widrow_adaptive_1960}. These models, heavily inspired by psychology and neuroscience \cite{mcculloch_logical_1943,hebb_organization_1949}, were designed in an attempt to model the neural networks comprising the human brain, hence the name \ac{ANN}. However, although these models were capable of solving simple pattern recognition tasks, a decade later it was proven by Marvin Minsky and Seymour Papert \cite{minsky_perceptrons:_1969,olazaran_sociological_1996} that perceptrons were, in fact, inherently limited due to their linear input-output mapping and could indeed solve only very simple tasks. Interestingly, it was already known at the time that a simple way to alleviate the limitations of the perceptron was to change the linear mapping to a more complex non-linear mapping by simply stacking multiple perceptrons into models known as \acp{MLP}. These more advanced, and deeper, \ac{ANN} models were much more capable in terms of representational capacity, and could potentially solve extremely complex problems \cite{minsky_perceptrons:_1969,lippmann_introduction_1987,olazaran_sociological_1996}. Unfortunately, at the time, training these \acp{MLP} was not feasible, partly due to lack of sufficient computational resources, but primarily due to lack of successful training algorithms. It took almost two decades before an efficient algorithm for training \acp{MLP} were developed, which was popularized as \emph{back-propagation} by Rumelhart \emph{et al.} in 1986 \cite{rumelhart_learning_1986}% \footnote{Although Rumelhart \emph{et al.} \cite{rumelhart_learning_1986} coined the term back-propagation, some argue (see e.g. \cite{schmidhuber_deep_2015-1,olazaran_sociological_1996}) that they did not invent the algorithm, they simply popularized it.}. Not long after the invention of back-propagation for training \acp{MLP}, theoretical results were published, proving that \acp{MLP} can approximate practically any function, with any desired accuracy. These theoretical results are known as the \emph{universal approximation theorem} for MLPs \cite{hornik_multilayer_1989,cybenko_approximation_1989,hornik_approximation_1991}. The results were encouraging as they settled some of the speculations about the lack of potential of \acp{MLP} put forward by Minsky and Papert \cite{minsky_perceptrons:_1969,olazaran_sociological_1996} and proved, once and for all, that \acp{MLP} indeed did have the potential to solve complex tasks. With the awareness of the back-propagation algorithm \cite{rumelhart_learning_1986} and the universal approximation theorem \cite{hornik_multilayer_1989,cybenko_approximation_1989,hornik_approximation_1991}, a natural question arises: why did it take two decades from the mid 1980s to the mid 2000s, before \acp{MLP}, or \acp{ANN} in general, became popular and practically applicable? The short answer to this question is: due to lack of labeled data and computational resources \cite{halevy_unreasonable_2009,shazeer_outrageously_2017,goodfellow_deep_2016}. It was, however, a technique known as \emph{unsupervised pre-training} that ignited the deep learning revolution in 2006 with two seminal papers by Hinton \emph{et al.} \cite{hinton_reducing_2006,hinton_fast_2006}. At the time, it was a general misconception that the optimization of \acp{MLP}, or \acp{DNN} as they are usually called today, got trapped in poor local minima, hence preventing \acp{DNN} with multiple non-linear layers to be efficiently trained \cite{bengio_greedy_2007}. In an attempt to alleviate this presumed challenge it was proposed to initialize the parameters of the \acp{DNN}, before back-propagation training, with the parameters of a generative model, known as a \ac{DBN} \cite{hinton_fast_2006,bengio_greedy_2007}. The intuition behind this was that if you consider two random variables $X$ and $Y$, and wish to learn $P(Y|X)$ it might be useful to first learn $P(X)$ using a generative model. \acp{DBN} are generative models constructed by stacking multiple \acp{RBM}, and then trained unsupervised using unlabeled data to model $P(X)$. RBMs are themselves generative models and belong to a broader class of undirected probabilistic graphical models, known as \acp{MRF} \cite{bishop_pattern_2006}. Inference in \acp{MRF}, however, is challenging as it requires the evaluation of a, generally intractable, partition function. However, Hinton \emph{et al.} showed in \cite{hinton_fast_2006} that \acp{RBM} can be combined into a \ac{DBN} and trained efficiently in a greedy layer-wise fashion using an approximate inference algorithm known as contrastive divergence \cite{hinton_training_2002}. The parameters of this \ac{DBN}, which is modeling $P(X)$ can then be used to initialize a \ac{DNN}, which is then "fine-tuned" using the traditional supervised back-propagation technique to model $P(Y|X)$. In the seminal paper \cite{hinton_fast_2006} Hinton \emph{et al.} showed that \acp{DNN} initialized with unsupervised pre-training and refined with supervised back-propagation \linebreak training, could achieve state-of-the-art results on a hand-written digits recognition task. The results attracted a huge amount of attention from the academic community and ultimately sparked the renewed interest in \acp{DNN}. It was, however, later recognized (see e.g. \cite{choromanska_loss_2014,kawaguchi_deep_2016,lecun_deep_2015,hinton_deep_2012,goodfellow_deep_2016,yu_roles_2010,nair_rectified_2010,ma_deep_2015}) that poor local minima in general was not a problem when training \acp{DNN} and similar or even better performance could be achieved without using unsupervised pre-training, especially for large labeled dataset. Consequently, today, unsupervised pre-training is a technique that is rarely used, but its influence and impact on the scientific field of \acp{DNN}, as a catalyst for \ac{DNN} research, cannot be overstated. Over the last decade, deep learning has truly revolutionized both academia and industry. For example, deep learning technology has facilitated the development of algorithms that are close to, or even exceeding, human-level performance within multiple scientific disciplines such as automatic speech recognition \cite{amodei_deep_2015,xiong_achieving_2016,yu_recent_2017,saon_english_2017}, object recognition \cite{he_delving_2015}, face recognition \cite{taigman_deepface:_2014}, lip reading \cite{chung_lip_2017}, board and computer games \cite{silver_mastering_2016,silver_mastering_2017,moravcik_deepstack:_2017,mnih_human-level_2015}, and in healthcare applications \cite{miotto_deep_2017,oakden-rayner_precision_2017} especially for cancer detection \cite{esteva_dermatologist-level_2017,wu_breast_2017,liu_detecting_2017,bychkov_deep_2018,wang_searching_2017}. Furthermore, today, deep learning is the key technology of many companies, and although the deep learning revolution was initiated by Hinton \emph{et al.}, it was, in fact, the increase in low-cost computational resources made available by the general-purpose graphics processing unit \cite{noauthor_nvidia_nodate,krizhevsky_imagenet_2012,goodfellow_deep_2016} that really facilitated the success of deep learning and allowed \acp{DNN} to be applied on an industrial scale. For example, Facebook currently uses \acp{DNN} to predict and analyze user behavior 200 trillion, i.e. $200\times10^{12}$, times each day, something that was practically impossible just a decade ago \cite{noauthor_viva_2018,hazelwood_applied_2018}. Finally, in a recent study \cite{pricewaterhousecoopers_pwcs_2017} by PricewaterhouseCoopers, it is estimated that deep learning will contribute \$15.7 trillion to the global economy in 2030, which is more than the current output of China and India combined. These contributions will be within a wide range of sectors such as health care, automotive, financial services, transportation, logistics, retail, energy, and manufacturing, which also justifies why deep learning driven technology is believed to lead to \emph{the fourth industrial revolution} \cite{schwab_fourth_2015,noauthor_andrew_2017}. \subsection{Feed-Forward Neural Networks}\label{sec:fnn} Sections \ref{deeplearn} and \ref{deeplearnrev} introduced deep learning without defining exactly what a \ac{DNN} is. In this section, and sections to come, we will introduce three of the most popular DNN models: \acp{FNN} (Sec.\,\ref{sec:fnn}), \acp{RNN} (Sec.\,\ref{sec:rnn}), and \acp{CNN} (Sec.\,\ref{sec:cnn}) \cite{goodfellow_deep_2016}. A \ac{FNN} is a machine learning model and is represented as a parameterized function given by \begin{equation} \barbelow{\hat{o}} = f(\barbelow{y},\theta), \label{eq201} \end{equation} where $\barbelow{y}$ is an input vector, $\theta$ is a set of parameters and $\barbelow{\hat{o}}$ is the \ac{FNN} output, i.e. the map of $\barbelow{y}$ by $f(\cdot,\cdot)$. The most basic \ac{FNN} is a single-layer \ac{FNN} given by \begin{equation} \barbelow{\hat{o}} = f^{ \{1\} }(\barbelow{y},\theta) = \phi ( \barbelow{\barbelow{W}} \barbelow{y} + \barbelow{b}), \;\;\; \theta = \{\barbelow{\barbelow{W}}, \barbelow{b}\}, \label{eq202} \end{equation} where $\barbelow{\barbelow{W}}$ and $\barbelow{b}$ are the parameters and $\phi (\cdot)$ is a, generally non-linear, function known as the activation function. The vector $\barbelow{b}$ is known as the bias vector and allows the \ac{FNN} to apply an affine transformation to $\barbelow{y}$. The prefix \emph{feed-forward} in \acp{FNN} comes from the fact that information only flows in one direction in the model in Eq.\,\eqref{eq202}, i.e. there are no recurrent connections. Furthermore, if $\phi (\cdot)$ is a binary thresholding function, Eq.\,\eqref{eq202} resembles the perceptron \cite{rosenblatt_perceptron:_1958} or ADALINE models \cite{widrow_adaptive_1960} and as shown by Minsky and Papert \cite{minsky_perceptrons:_1969}, these models are inherently limited as the input to the binary thresholding function is a purely linear transformation of the input $\barbelow{y}$. Instead, if these models are stacked as \begin{equation} \barbelow{\hat{o}} = f^{ \{L\} }( \dots f^{ \{2\} }(f^{ \{1\} }(\barbelow{y},\theta_1),\theta_2) \dots, \theta_L) \label{eq203} \end{equation} they form \acp{MLP} or multi-layer \acp{FNN}, which according to the universal approximation theorems (see e.g. \cite{hornik_multilayer_1989,cybenko_approximation_1989,hornik_approximation_1991}) can model practically any function. In fact, $L=2$ is sufficient for the universal approximation theorem to apply, although it might require an exponentially wide network, i.e. number of rows in $\barbelow{\barbelow{W}}$, to approximate a certain function with a given accuracy. However, as the number of layers $L$ increases, the compositional structure allow multi-layer \acp{FNN} to construct exponentially more complex decision boundaries, with the same number of parameters, than \acp{FNN} with $L=2$ \cite{rojas_networks_2003,pascanu_number_2014,montufar_number_2014}. The fact that \acp{FNN} gets exponentially more efficient, with respect to the parameters, as the number of layers increase, is exactly what drives the deep learning research community for increasingly deeper networks, and although deep networks are not trivial to train, modern deep learning models have been trained successfully with more than 1000 layers \cite{huang_deep_2016,he_deep_2016}. Similarly to the machine learning methods presented in Sec.\,\ref{sec:ml_cl_se}, the optimal parameters of a \ac{FNN} are typically given as the solution to an optimization problem on the form \begin{equation} \begin{aligned} \theta^\ast = \; & \underset{\theta}{\text{argmin}} & & \sum_{\mathcal{D}_{train}} \mathcal{J}(f^{ \{L\} }(\barbelow{y},\theta),\barbelow{o}), \;\;\; (\barbelow{y},\barbelow{o}) \in \mathcal{D}_{train}, \\ \end{aligned} \label{eq204} \end{equation} where $\mathcal{J}(\cdot,\cdot) \in \mathbb{R}$ is a non-negative cost function (e.g. mean squared error), $f^{ \{L\} }(\barbelow{y},\theta)$ represents a FNN with $L$ layers, $\theta = \{ \theta_1, \theta_2, \dots, \theta_L \}$ is the set of parameters, and $(\barbelow{y},\barbelow{o})$ is an ordered pair, of input signals $\barbelow{y}$ and corresponding targets $\barbelow{o}$, from a training dataset $\mathcal{D}_{train}$. The objective is then to find parameters $\theta$ such that $\barbelow{\hat{o}} = f^{ \{L\} }(\barbelow{y},\theta) \approx \barbelow{o}$. However, until 1986 a solution to Eq.\,\eqref{eq204} was only known for $L=1$, but when Rumelhart \emph{et al.} \cite{rumelhart_learning_1986} proposed the back-propagation algorithm, Eq.\,\eqref{eq204} could be solved, in theory, for any $L$ using the optimization method gradient descent (e.g. \cite{ruder_overview_2016,smith_dont_2017,wilson_marginal_2017}). Specifically, Rumelhart \emph{et al.} proposed to update any weight $w$ in a multi-layer FNN using gradient descent defined as \begin{equation} w^{(n+1)} = w^{(n)} - \mu \frac{\partial \mathcal{J}}{ \partial w^{(n)} }, \label{eq207} \end{equation} where $\mu$ is the learning rate, $w^{(n)}$ is a parameter in an arbitrary layer at iteration $n$, and $\frac{\partial \mathcal{J}}{ \partial w^{(n)} }$ is the partial derivative of the cost function $\mathcal{J}$ with respect to the weight. Rumelhart \emph{et al.} showed in \cite{rumelhart_learning_1986} that $\frac{\partial \mathcal{J}}{ \partial w^{(n)} }$ can be straightforwardly decomposed, using the chain rule of differentiation, into a chain of products of simple partial derivatives that, except for the activation function, only involved differentiation of linear functions. In fact, Rumelhart \emph{et al.} showed that if the activation function was given by the sigmoid function defined as \begin{equation} \phi(x) = \frac{1}{1+e^{-x}}, \;\;\; x \in \mathbb{R}, \;\;\; \phi(x) \in (0,1), \label{eq211} \end{equation} where \begin{equation} \frac{\partial \phi(x)}{\partial x} = \phi(x)(1-\phi(x)), \label{eq212} \end{equation} this chain of partial derivatives could easily and efficiently be evaluated for all parameters in a multi-layer FNN, consequently, allowing multi-layer FNNs to be trained successfully. However, although the back-propagation technique enabled multi-layer FNNs, with sigmoid activation functions, to be efficiently trained, the sigmoid function, at the same time, prohibited multi-layer FNNs with more than a few layers to be trained due to a phenomena known as the \emph{vanishing gradient problem}. The vanishing gradient problem occurs because $\frac{\partial \mathcal{J}}{ \partial w }$ is decomposed into a chain of products where $\frac{\partial \phi(x)}{\partial x}$ appears once for each layer and since $\frac{\partial \phi(x)}{\partial x} \leq 0.25$, the partial derivative $\frac{\partial \mathcal{J}}{ \partial w }$ progressively gets smaller and smaller as the number of layers increase, i.e., the gradient vanishes for FNNs with a large number of layers. A way to alleviate this problem is to use an activation function whose first derivative is close to one. Such an activation function is the rectified linear unit\,(ReLU) \cite{nair_rectified_2010}, which is simply a half-wave rectifier given as $max(x,0)$. The ReLU has the very simple first sub-derivatives given as $ \frac{\partial }{ \partial w } max(x,0) = 0$ for $x<0$ and $\frac{\partial}{ \partial w } max(x,0) = 1$ for $x>0$, which effectively reduces the vanishing gradient problem. In fact, using the ReLU instead of the sigmoid activation function is one of the key differences that enable deep FNNs, with hundreds of layers and billions of parameters, to be trained successfully with back-propagation and without unsupervised pre-training \cite{glorot_deep_2011,zeiler_rectified_2013,lecun_deep_2015,he_delving_2015,he_deep_2016,shazeer_outrageously_2017}. \subsection{Recurrent Neural Networks}\label{sec:rnn} We now turn our attention to a \ac{DNN} architecture known as a \acf{RNN}. In Sec.\,\ref{sec:fnn} we saw that a \ac{FNN} is a universal function approximator and one can ask why another architecture is needed if a FNN can approximate any function. The answer is at least twofold. First, the universal approximation theorem of \acp{FNN} says only something about the representational capacity of \acp{FNN} with an unlimited number of parameters. It does not, however, say anything about the \ac{FNN} topology, i.e. the number of layers and the number of units per layer. Secondly, optimization of \acp{FNN}, and \acp{DNN} in general, is a non-convex problem and generally no guaranties exist in terms of convergence and optimality, when the parameters are found using gradient descent and back-propagation \cite{boyd_convex_2004,goodfellow_deep_2016}. Therefore, some \ac{DNN} architectures might be more efficient in terms of parameters, or superior in terms of performance, compared to \acp{FNN} trained using gradient descent and back-propagation, and indeed, such architectures exist. Two such popular architectures are the \ac{RNN}, to be described in this section, and the \ac{CNN}, which will be the topic of the next section. Specifically, the basic single-layer \ac{RNN} architecture is given as \cite{rumelhart_learning_1986-1} \begin{equation} \begin{aligned} \barbelow{h}^{(n)} = \;& \phi (\barbelow{\barbelow{W}} \barbelow{x}^{(n)} + \barbelow{\barbelow{V}} \barbelow{h}^{(n-1)} +\barbelow{b} ), \\ \end{aligned} \label{eq213} \end{equation} where $\phi(\cdot)$ is an activation function, $\barbelow{\barbelow{W}}$, and $\barbelow{\barbelow{V}}$ are parameter matrices, $\barbelow{b}$ is a bias vector, and $\barbelow{h}^{(n)}$ is the output of the RNN at time index $n$. From Eq.\,\eqref{eq213} it is seen that the RNN architecture operates with a time index $(n)$, and differently from the FNN architecture (Eq.\,\eqref{eq202}) the RNN has a recurrent connection that is shared between time-steps, hence the name RNN. This time index and weight sharing property, is exactly what differentiates RNNs from FNNs and what allows RNNs to be efficient models of sequential data with strong temporal structure, such as speech. Also, similarly to FNN architectures, RNNs can be stacked into deep RNNs, hence increasing the model capacity \cite{pascanu_how_2013}, and it can even be shown that RNNs can model any dynamical system with any required accuracy, which is known as the universal approximation theorem for RNNs \cite{schafer_recurrent_2006}. Furthermore, as a consequence of the recurrent connection, for any finite $n$, i.e. $n=1,2,\dots,N$, a FNN architecture exists that has the exact same behavior as a RNN \cite{rumelhart_learning_1986-1}. In fact, this is exactly what is utilized when training RNNs using the back-propagation-through-time technique. First, the RNN is converted, or unrolled in time, into an $N$-layer FNN, and then, it is trained using the standard back-propagation technique as described in Sec.\,\ref{sec:fnn}. \cite{goodfellow_deep_2016}. However, similarly to the FNNs, if the network is deep, i.e. if $N$ is large, training usually fails due to the vanishing gradient problem, which, in practice, prohibits the use of RNNs for signals with long time dependencies \cite{pascanu_difficulty_2013}. Also, since the recurrent weights are shared across time, the vanishing gradient problem is even more severe for RNNs, as the weights are constant for all time steps. This is especially true in the case where $\lVert \barbelow{\barbelow{V}} \lVert < 1$, i.e. the matrix norm of $\barbelow{\barbelow{V}}$ is less than one. A phenomena known as exploding gradients also exists, which can occur in the case when $\lVert \barbelow{\barbelow{V}} \lVert > 1$, although this is usually handled simply by clipping the gradients \cite{goodfellow_deep_2016}. Several techniques have been proposed to alleviate the vanishing gradient problem. For example, by constraining the recurrent weight matrix to be orthogonal the vanishing gradient problem can be reduced (see e.g. \cite{arjovsky_unitary_2015,wisdom_full-capacity_2016,henaff_orthogonal_2016,jing_tunable_2017,vorontsov_orthogonality_2017}). A different approach to avoid the vanishing gradient problem is to change the \ac{RNN} architecture into what is known as gated-\acp{RNN} \cite{goodfellow_deep_2016,zhang_architectural_2016,zhou_minimal_2016-1,cho_properties_2014,cho_learning_2014,hochreiter_long_1997,greff_lstm:_2017}, and the most popular of these gated-\acp{RNN} is the \ac{LSTM}-RNN \cite{hochreiter_long_1997,greff_lstm:_2017} given by \begin{equation} \begin{aligned} \barbelow{i}^{(n)} = \;& \sigma \left( \barbelow{\barbelow{W}}_i \barbelow{x}^{(n)} + \barbelow{\barbelow{V}}_i \barbelow{h}^{(n-1)} + \barbelow{b}_i \right), \\ \barbelow{f}^{(n)} = \;& \sigma\left( \barbelow{\barbelow{W}}_f \barbelow{x}^{(n)} + \barbelow{\barbelow{V}}_f \barbelow{h}^{(n-1)} + \barbelow{b}_f \right), \\ \barbelow{o}^{(n)} = \;& \sigma\left( \barbelow{\barbelow{W}}_o \barbelow{x}^{(n)} + \barbelow{\barbelow{V}}_o \barbelow{h}^{(n-1)} + \barbelow{b}_o \right), \\ \barbelow{d}^{(n)} = \;& \tanh\left( \barbelow{\barbelow{W}}_c \barbelow{x}^{(n)} + \barbelow{\barbelow{V}}_c \barbelow{h}^{(n-1)} + \barbelow{b}_c \right), \\ \barbelow{c}^{(n)} = \;& \barbelow{f}^{(n)} \circ \barbelow{c}^{(n-1)} + \barbelow{i}^{(n)} \circ \barbelow{d}^{(n)}, \\ \barbelow{h}^{(n)} = \;& \barbelow{o}^{(n)} \circ \tanh\left( \barbelow{c}^{(n)} \right), \end{aligned} \label{eq214} \end{equation} where $\barbelow{x}^{(n)}$ is the input, $\sigma(\cdot)$ and $\tanh(\cdot)$ denote the sigmoid and hyperbolic tangent functions, "$\circ$" denotes element-wise multiplication, and the subscripts "$\cdot_i$", "$\cdot_f$", "$\cdot_o$", and "$\cdot_c$", with an abuse of notation, denote the parameters associated with the input gate, forget gate, output gate, and the cell state, respectively \cite{hochreiter_long_1997,greff_lstm:_2017}. The \ac{LSTM} architecture minimizes the vanishing gradient problem primarily due to the algorithm step $\barbelow{c}^{(n)} = \barbelow{f}^{(n)} \circ \barbelow{c}^{(n-1)} + \barbelow{i}^{(n)} \circ \barbelow{d}^{(n)}$, which is known as the cell state. The cell state has a recurrent connection to itself with no activation function. Furthermore, the value of the cell state is controlled by "gates" that only act multiplicative on the cell state, hence, controlling the flow of information into the cell and out of the cell. Since the cell state has no activation function and no weight directly associated with it, its value will remain constant during gradient updates hence, avoiding the vanishing gradient problem. However, although the \ac{LSTM} given by Eq.\,\eqref{eq214}, is more computational complex compared to the basic \ac{RNN} given by Eq.\,\eqref{eq213}, it is far easier to train, and works better in practice when $N$ is large \cite{chung_empirical_2014,collins_capacity_2017}. Consequently, the \ac{LSTM}-\ac{RNN} architecture is currently the most popular \ac{RNN} architecture used for speech processing applications such as speech recognition, enhancement, and separation \cite{xiong_achieving_2016,hannun_deep_2014,amodei_deep_2015,wang_supervised_2017,zhang_advanced_2017,yu_automatic_2015,qian_past_2018,weninger_single-channel_2014,weninger_speech_2015}. \subsection{Convolutional Neural Networks}\label{sec:cnn} Similarly to the \ac{RNN}, the \acf{CNN} is an architecture that utilizes weight-sharing, but compared to the \ac{RNN}, in a fundamentally different way \cite{atlas_artificial_1987,lecun_backpropagation_1989,lecun_generalization_1989}. As seen from Eqs.\,\eqref{eq213} and \eqref{eq214}, for \ac{RNN} architectures the same weight matrix is shared for each time step. This configuration is known as \emph{tied weights} as the connections between weights and inputs are constant. Although this configuration leads to powerful models due to the universal approximation theorem, it also leads to computational demanding networks due to the dense matrix vector multiplications. If, however, a large number of weights are redundant, i.e. taking similar values, due to a certain general structure in the data, it is more efficient to reuse these parameters instead of having them stored in multiple different locations in a large matrix. This is exactly the principle behind the \ac{CNN} architecture. \acp{CNN} use \emph{untied weights} that are shared for multiple inputs. Mathematically, this corresponds to the convolution between the input signal and the parameters, hence the name \ac{CNN}. For example, in the two-dimensional case, the convolution% \footnote{Although this is technically speaking the cross-correlation, since we use positive increments and not negative, we follow the convention and refer to it as convolution \cite{goodfellow_deep_2016}. } between a signal matrix $\barbelow{\barbelow{X}} \in \mathbb{R}^{J \times I}$ and a parameter matrix $\barbelow{\barbelow{W}} \in \mathbb{R}^{M \times N}$, where $M < J$ and $N < I$, is simply given as \begin{equation} \begin{aligned} s_{j,i} = \sum_{m=1}^{M} \sum_{n=1}^{N} x_{j+m,i+n} w_{m,n}, \end{aligned} \label{eq215} \end{equation} where $x_{j,i}$ and $w_{m,n}$ denote entries $j,i$, and $m,n$ of $\barbelow{\barbelow{X}}$ and $\barbelow{\barbelow{W}}$, respectively. Similarly to the \ac{FNN} and \ac{RNN} architectures, a \ac{CNN} also consists of multiple layers of non-linear mappings, where each layer is based on a non-linear activation function. Differently from the \acp{FNN} and \acp{RNN}, for \acp{CNN} the input to the activation function is the convolution between the input to the layer and the set of layer-specific parameters $\barbelow{\barbelow{W}}$, usually called filters or kernels. This is fundamentally different from the dense matrix vector product used by the \ac{FNN} and \ac{RNN} architectures. Usually each layer consists of multiple kernels that are all convolved with the same input, hence producing a larger number of outputs than inputs, known as feature maps. To reduce the memory complexity, usually a stride larger than one is used, which means that $j,i$ are incremented with step sizes larger than one. Another step usually applied is known as pooling, where each feature map is down-sampled with a certain factor. This pooling step adds translational invariance to the \ac{CNN}, which usually is a desirable quality, while at the same time reducing the memory requirement. If the \ac{CNN} is used for classification, a \ac{FNN} is usually used as the output layer. Since the number of parameters is defined by $M$ and $N$ and not by $J$ and $I$, as with \acp{FNN} and \acp{RNN}, and since $M\ll J$ and $N\ll I$ for many practical systems, \acp{CNN} can potentially require far less parameters for the same performance, i.e. \acp{CNN} can be more parameter-efficient compared to \acp{FNN} and \acp{RNN} \cite{goodfellow_deep_2016}. This is especially true for applications involving natural images where features such as edges usually contain more information about the content of the image than solid-color regions do. In such cases the kernels $\barbelow{\barbelow{W}}$ can easily extract such information with a low number of parameters using e.g. a $3 \times 3$ edge detector (e.g Sobel kernel) \cite{duda_pattern_2001}. A \ac{FNN} on the other hand, would potentially require several orders of magnitude more parameters to apply the same operation as the operation should be a matrix vector product. In fact, this is what makes \acp{CNN} a very powerful model for natural images. It has even been shown that \acp{CNN} trained on large datasets, containing natural images, learn very specific and intuitive kernels at each layer \cite{krizhevsky_imagenet_2012,zeiler_visualizing_2014}. At the first layer the kernels resemble simple edge detectors. At the next layer combinations of edge-detectors are combined into more abstract, although distinct, objects and at even higher layers these abstract objects become identifiable as the different target classes in the dataset, such as animals, persons, etc \cite{krizhevsky_imagenet_2012,zeiler_visualizing_2014}. Finally, since the convolution in Eq.\,\eqref{eq215} is differentiable, \acp{CNN} can similarly to the \ac{FNN} and \ac{RNN} architectures be trained efficiently using the back-propagation technique, and today, \acp{CNN} are by far the most successful \ac{DNN} architecture for image applications (see e.g. \cite{rawat_deep_2017,gu_recent_2018,caron_deep_2018}). \section{Deep Learning for Enhancement and Separation}\label{deepsesep} So far, classical non-deep learning-based methods for single-microphone \linebreak speech enhancement have not been able to improve speech intelligibility of noisy speech in realistic scenarios (see Sec.\;\ref{sec:classical_se}). Similarly, classical non-deep learning-based methods for single-microphone multi-talker speech separation have so far not been able to successfully separate an audio signal consisting of multiple speech signals into individual speech signals without prior knowledge about the speakers. With the emergence of deep learning some of the challenges faced by previous techniques can now be overcome. In this section, we will review some of these deep learning-based techniques for single-microphone speech enhancement and single-microphone multi-talker speech separation. \subsection{Deep Learning Based Speech Enhancement}\label{deepse} After Hinton \emph{et al.} \cite{hinton_reducing_2006,hinton_fast_2006} showed that \acp{DNN} could be trained successfully on an image-recognition task, a renewed interest in deep learning-based single-microphone speech enhancement emerged. In general, these techniques can be divided into two types: mask approximation-based techniques and signal approximation-based techniques. \subsubsection{Mask Approximation} Let $\barbelow{x}_m$ and $\barbelow{y}_m$ denote time-frame $m$ of a time-domain clean-speech signal and noisy-speech signal, respectively. Furthermore, let $\barbelow{a}_m$ and $\barbelow{r}_m$ denote the \ac{STFT} spectral magnitude vectors of $\barbelow{x}_m$ and $\barbelow{y}_m$, respectively. Also, let $h(\barbelow{y}_m)$ denote a feature transformation of $\barbelow{y}_m$. Finally, let \begin{equation} \hat{\barbelow{g}}_m = f_{DNN}(h(\barbelow{y}_m),\barbelow{\theta}), \label{eq300} \end{equation} denote a gain vector, estimated by a \ac{DNN}\footnote{Note, $\hat{\barbelow{g}}_m$ can also be a function of multiple input vectors, i.e. for multiple $m$, which usually leads to improved performance for feed-forward DNNs.}% \,$f_{DNN}(\cdot,\cdot)$ with parameters $\barbelow{\theta}$, such that $\hat{\barbelow{a}}_m = \hat{\barbelow{g}}_m \circ \barbelow{r}_m$ is an estimate of the clean speech spectral magnitude $\barbelow{a}_m$, and $\circ$ is element-wise multiplication. The enhanced time-domain speech signal $\hat{\barbelow{x}}_m$ is then acquired by \ac{IDFT} using the phase of the noisy signal. The goal of the mask approximation-based technique is then to find a set of \ac{DNN} parameters $\barbelow{\theta}^\ast$ such that \begin{equation} \begin{aligned} \theta^\ast = \; & \underset{\barbelow{\theta}}{\text{argmin}} & & \sum_{\mathcal{D}_{train}} \mathcal{J}(\hat{\barbelow{g}}_m,\barbelow{g}_m), \;\;\; (\barbelow{y}_m,\barbelow{g}_m) \in \mathcal{D}_{train}, \\ \end{aligned} \label{eq301} \end{equation} where $\mathcal{D}_{train}$ denotes a training dataset, $\mathcal{J}(\cdot,\cdot)$ denotes a cost function, $\barbelow{g}_m$ is a target gain vector, and the dependence on $\barbelow{y}_m$ and $\barbelow{\theta}$ is implicit via $\hat{\barbelow{g}}_m$. That is, the mask approximation-based technique aims to minimize the difference as measured by $\mathcal{J}(\cdot,\cdot)$ between the target gain $\barbelow{g}_m$ and the estimated gain $\hat{\barbelow{g}}_m$ (see e.g. \cite{wang_ideal_2005,hummersone_ideal_2014,williamson_complex_2016,delfarah_feature_2016,delfarah_features_2017,chen_noise_2016,chen_long_2016,chen_long_2017}). In the following, we review the work related to two of the most popular target gains: the \acf{IBM} \cite{wang_ideal_2005} and the \ac{IRM} \cite{hummersone_ideal_2014}. \paragraph{Ideal Binary Mask} \mbox{}\\ In the \ac{STFT} domain the \ac{IBM} is defined as (see e.g. \cite{wang_training_2014}) \begin{equation} \hat{g}^{IBM}(k,m) = \begin{cases} 1 & \text{if } \frac{|x(k,m)|}{|v(k,m)|} > T_{SNR}(k)\\ 0 & \text{otherwise} , \end{cases} \label{eq303} \end{equation} where $|x(k,m)|$ and $|v(k,m)|$ denote \ac{STFT} spectral magnitudes for frequency bin $k$ and time-frame $m$ of the clean speech signal and the noise signal, respectively, and $T_{SNR}(k)$ denote a frequency-dependent tuning parameter (see Eqs.\,\eqref{eq40}, and \eqref{eq41}). One of the first to use the \ac{IBM} target for \ac{DNN} based single-microphone speech enhancement was Wang \emph{et al.} \cite{wang_towards_2013}. Wang \emph{et al.} proposed to use \acp{FNN} to estimate the \ac{IBM} from a noisy speech signal. The \acp{FNN} were first trained using the unsupervised pre-training technique and then fine-tuned using back-propagation. However, instead of using the \ac{IBM} for speech enhancement, the output vector of the penultimate \ac{FNN} layer was used as a feature vector for training \acp{SVM}. Using these \ac{FNN}-generated feature vectors the \acp{SVM} were trained to estimate \acp{IBM} used for speech enhancement. This approach was very similar to the previous techniques from Sec.\,\ref{sec:classical_se}, where \acp{GMM} \cite{kim_algorithm_2009} and \acp{SVM} \cite{han_classification_2012} were used, but since \acp{FNN} were used as feature extractors, performance improved compared to previous techniques where hand-engineered features were used \cite{kim_algorithm_2009,han_classification_2012}. Motivated by Wang \emph{et al.} \cite{wang_towards_2013}, Healy \emph{et al.} \cite{healy_algorithm_2013} proposed to use a \ac{FNN}-estimated IBM for speech enhancement directly, i.e without using \acp{SVM}. This approach led to further improvements compared to previous systems \cite{kim_algorithm_2009,han_classification_2012,wang_towards_2013}, presumably due to an increased amount of training data. Healy \emph{et al.} \cite{healy_algorithm_2013} even reported large improvements in speech intelligibility for both normal hearing and hearing impaired listeners in a listening test. Similar conclusions were later reported in a subsequent study with a computationally more efficient system that did not use unsupervised pre-training \cite{healy_speech-cue_2014}. However, similarly to previous machine learning-based techniques \cite{kim_algorithm_2009,han_classification_2012}, Wang \emph{et al.} \cite{wang_towards_2013} and Healy \emph{et al.} \cite{healy_algorithm_2013} used prior knowledge generally not available in a real-life situation, as the same noise sequence was used during training and test. That is, although these systems achieved impressive performance in unrealistic conditions, they did not reveal any information about the performance to be expected in general real-life scenarios. \paragraph{Ideal Ratio Mask} \mbox{}\\ Although \ac{IBM}-based speech enhancement systems can achieve good performance (see e.g. \cite{kim_algorithm_2009,han_classification_2012}) several studies suggested (see e.g. \cite{hummersone_ideal_2014,madhu_potential_2013,jensen_spectral_2012}) that a continuous mask might perform better as the binary T-F segmentation of the \ac{IBM}, as either speech or noise dominated, might be too coarse as speech and noise is likely to be present at the same time in the same T-F unit. Obviously, since the IBM is a special case of a general continuous mask, it is expected that a continuous mask can outperform a binary mask in terms of speech enhancement evaluation metrics \cite{jensen_spectral_2012}. One such continuous mask, which highly resembles the frequency domain Wiener filter (see Eq.\,\eqref{eq12}), is the \ac{IRM} defined as \begin{equation} g^{IRM}(k,m) = \frac{|x(k,m)|^\beta}{|x(k,m)|^\beta + |v(k,m)|^\beta}, \label{eq216} \end{equation} where $|x(k,m)|$ and $|v(k,m)|$ denote the clean-speech signal magnitude and noise signal magnitude in frequency bin $k$ and time frame $m$, respectively, and $\beta$ is a tuning parameter \cite{wang_training_2014}. Note, unlike the Wiener filter which is statistically optimal, the IRM is not optimal in any obvious way and was presumably motivated heuristically. In \cite{narayanan_ideal_2013} the \ac{IRM} was proposed as a \ac{DNN} training target and it was reported that the \ac{IRM} outperformed the \ac{IBM}, when used in a speech enhancement front-end for an \ac{ASR} system. It was later shown that the \ac{IRM} also outperformed the \ac{IBM} in terms of objective evaluation metrics such as \ac{PESQ} and \ac{STOI}, when tested in various acoustic environments \cite{wang_training_2014}. Furthermore, using a similar technique, large improvements in speech intelligibility was reported in \cite{healy_algorithm_2015} for hearing impaired listeners and moderate improvements for normal hearing listeners. In fact, although the system in \cite{healy_algorithm_2015} was "narrow" in the sense that it was speaker and noise-type specific, i.e. trained and tested in matched speaker and noise type conditions, it was the first study to report significant improvements in speech intelligibility for hearing impaired and normal hearing listeners using a single-microphone speech enhancement algorithm. In a subsequent study \cite{wang_deep_2015}, generalizability with respect to unknown noise sources was investigated and it was reported in \cite{chen_large-scale_2016} that improvements in speech intelligibility could be achieved for noise types not seen during training, if a very large number of noise types were included in the training set. However, the improvement in speech intelligibility in \cite{chen_large-scale_2016} was significantly reduced compared to \cite{healy_algorithm_2015}, especially for normal hearing listeners where modest improvements were achieved for a babble noise type and practically no improvement for a cafeteria noise type. In addition to the promising results in \cite{healy_algorithm_2015,chen_large-scale_2016,bolner_speech_2016,monaghan_auditory_2017}, where the intelligibility improvements were reported for normal hearing and/or hearing impaired listeners using hearing-aids, promising results have also been reported for users of cochlear implants (see e.g. \cite{goehring_speech_2017,lai_deep_2017,lai_deep_2018}). Even though the studies in e.g. \cite{healy_algorithm_2015,chen_large-scale_2016,bolner_speech_2016,monaghan_auditory_2017,goehring_speech_2017,lai_deep_2017,lai_deep_2018} showed promising results, they generally only considered either a single noise type, a single speaker or a narrow range of SNRs. That is, these studies only revealed information about the performance to be expected by DNN based speech enhancement systems in non-general usage scenarios where either the noise type, speaker identity or SNR is known \emph{a priori}. \subsubsection{Signal Approximation} Differently from the mask approximation-based technique where the goal is to minimize the difference between an estimated gain and a target gain (see Eq.\,\eqref{eq301}), the goal of the signal approximation-based techniques is to minimize the difference between the clean speech, e.g. clean speech STFT magnitudes, and the estimated speech (see e.g. \cite{xu_experimental_2014,liu_experiments_2014,xu_regression_2015,wang_training_2014,weninger_discriminatively_2014,erdogan_phase-sensitive_2015,erdogan_deep_2017}). For example, in \cite{weninger_discriminatively_2014} it is proposed to use a cost function defined as \begin{equation} \begin{aligned} \theta^\ast = \; & \underset{\barbelow{\theta}}{\text{argmin}} & & \sum_{\mathcal{D}_{train}} \mathcal{J}(\hat{\barbelow{a}}_m ,\barbelow{a}_m), \;\;\; (\barbelow{r}_m,\barbelow{a}_m) \in \mathcal{D}_{train}, \\ \end{aligned} \label{eq302} \end{equation} where the goal is to find a gain vector $\hat{\barbelow{g}}_m$, which, when applied to the noisy magnitude $\barbelow{r}_m$ minimize the difference between the estimated speech signal magnitude $\hat{\barbelow{a}}_m = \hat{\barbelow{g}}_m \circ \barbelow{r}_m$ and the target signal magnitude $\barbelow{a}_m$. This is arguably more sensible than the mask approximation-based technique, as no target gain is explicitly defined, and the DNN is trained to estimate a gain that achieve the minimum cost with respect to the target $\barbelow{a}_m$, i.e. the clean speech magnitude. In fact, when training a DNN using Eq.\,\eqref{eq302} the gain that is indirectly estimated is given as \begin{equation} g^{AM}(k,m) = \frac{|x(k,m)|}{|y(k,m)|}, \label{eq304} \end{equation} where $|y(k,m)|$ denotes the noisy speech signal magnitude in frequency bin $k$ and time frame $m$, which ultimately allows for perfect reconstruction of the clean speech magnitude, i.e. $\barbelow{a}_m = \barbelow{g}^{AM}_m \circ \barbelow{r}_m$ \cite{weninger_discriminatively_2014}. However, since the phase of the noisy signal is typically used for reconstructing the enhanced speech signal in the time domain, perfect reconstruction of $\barbelow{a}_m$ only leads to perfect time domain signal reconstruction in the case when $|y(k,m)| = |x(k,m)| + |v(k,m)|$. This, unfortunately, is only true in the unlikely event when the clean speech and noise have identical phases, i.e. $\angle x(k,m) = \angle v(k,m)$. Since $|y(k,m)| \ne |x(k,m)| + |v(k,m)|$ in general, it was proposed in \cite{erdogan_phase-sensitive_2015,erdogan_deep_2017} to use the \ac{PSA} cost function defined as \begin{equation} \begin{aligned} \theta^\ast = \; & \underset{\barbelow{\theta}}{\text{argmin}} & & \sum_{\mathcal{D}_{train}} \mathcal{J}(\hat{\barbelow{a}}_m \; , \; \barbelow{a}_m \circ \barbelow{\phi}_m), \;\;\; (\barbelow{r}_m,\barbelow{a}_m) \in \mathcal{D}_{train}, \\ \end{aligned} \label{eq305} \end{equation} where $\barbelow{\phi}_m = [\phi(1,m), \phi(2,m), \dots, \phi(K,m)]^T$ and $\phi(k,m) = \cos(\angle x(k,m) - \angle y(k,m))$. In fact, the PSA gain that minimizes Eq.\,\eqref{eq305} is known as the \ac{PSF} and is given by \begin{equation} g^{PSF}(k,m) = Re \left[ \frac{x(k,m)}{y(k,m)} \right] = \frac{|x(k,m)|}{|y(k,m)|} \cos(\angle x(k,m) - \angle y(k,m)), \label{eq217} \end{equation} and is the optimal real-valued filter that minimizes $|g(k,m)y(k,m) - x(k,m)|$. Furthermore, except in the unlikely case when $\angle x(k,m) = \angle v(k,m)$, Eq.\,\eqref{eq217}, will lead to a higher \ac{SNR} compared to e.g. the \ac{IRM} \cite{erdogan_phase-sensitive_2015}. Finally, the \ac{PSA} cost function (Eq.\,\eqref{eq305}) is currently the training objective for DNN based speech enhancement that achieves the best performance in terms of speech enhancement evaluation metrics such as PESQ and STOI \cite{williamson_time-frequency_2017}. However, similarly to the studies evaluating the mask approximation technique for DNN based speech enhancement, the studies based on signal approximation (e.g. \cite{xu_experimental_2014,liu_experiments_2014,xu_regression_2015,wang_training_2014,weninger_discriminatively_2014,erdogan_phase-sensitive_2015,erdogan_deep_2017}) were in general trained and tested in narrow usage scenarios where either the noise type, speaker identity or SNR was known \emph{a priori}. That is, these studies also reveal limited information about how DNN based speech enhancement systems perform in general usage scenarios. \subsection{Deep Learning Based Speech Separation}\label{deepsep} Similarly to the renewed interest in single-microphone speech enhancement (Sec.\;\ref{deepse}), a renewed interest for DNN based single-microphone multi-talker speech separation emerged as well. Some of the first to apply modern \acp{DNN} to single-microphone multi-talker speech separation were Du \emph{et al.} \cite{du_speech_2014} and Huang \emph{et al.} \cite{huang_deep_2014,huang_joint_2015}. In \cite{du_speech_2014} a multi-layer \ac{FNN} was trained, using unsupervised pre-training, to estimate the log-power spectrum for a target speaker from the log-power spectrum of a mixed signal consisting of two speakers. This approach is very similar to the enhancement techniques in \cite{xu_experimental_2014,liu_experiments_2014,xu_regression_2015} and the main difference is the interference signal, which is a speech signal in \cite{du_speech_2014} and not environmental noise signals as in \cite{xu_experimental_2014,liu_experiments_2014,xu_regression_2015}. Nevertheless, Du \emph{et al.} \cite{du_speech_2014} showed good separation performance of a known speaker in terms of \ac{STOI} and output-\ac{SNR} using a signal approximation-based approach. Differently from Du \emph{et al.} \cite{du_speech_2014}, Huang \emph{et al.} \cite{huang_deep_2014,huang_joint_2015} proposed to use multi-layer \acp{RNN} to separate a two-speaker mixture signal into the original two speech signals, i.e. Huang \emph{et al.} \cite{huang_deep_2014,huang_joint_2015} proposed to separate the two speech signals in the mixture signal, whereas Du \emph{et al.} \cite{du_speech_2014} simply extracted a known "target" speaker. Huang \emph{et al.} \cite{huang_deep_2014,huang_joint_2015} separated a mixture signal using a multi-layer \ac{RNN} with two output streams, i.e. the output vector was twice the original size. For each output stream the \ac{RNN} was trained using a signal approximation-based approach to minimize the \ac{MSE} between the true source signals and the separated signals. Although the system was speaker-dependent, i.e. the same speakers were used for training and testing, Huang \emph{et al.} \cite{huang_deep_2014,huang_joint_2015} showed that this approach works well for mixture signals containing both same-gender and opposite-gender speech signals. However, even though Du \emph{et al.} \cite{du_speech_2014} and Huang \emph{et al.} \cite{huang_deep_2014,huang_joint_2015} showed that \acp{DNN} could be used for single-microphone multi-talker speech separation and that they outperformed other existing methods based on \acp{GMM} and \ac{NMF}, their methods were still rather limited as they, similarly to the factorial \ac{HMM}-based techniques presented in Sec.\,\ref{genmodse}, were speaker-dependent as they required detailed \emph{a priori} knowledge about the speakers. A few techniques \cite{weng_deep_2015,wang_unsupervised_2016} did manage to overcome this speaker dependence by introducing additional assumptions. For example, in \cite{weng_deep_2015} it was assumed that one speech signal always had an average energy level larger than the other speech signal, i.e. a mixture \ac{SNR} different from 0 dB. With this assumption, one multi-layer \ac{FNN} was trained to extract the speaker with the high average energy and another multi-layer FNN was trained to extract the speech signal with low average energy. With this approach a mixture signal containing two speakers of unknown identity could be separated somewhat successfully. In \cite{wang_unsupervised_2016} it was instead assumed that the mixture signal consisted of exactly one male and one female speaker. In this case, a multi-layer \ac{FNN} with two output streams was trained to separate the input mixture such that the female speech signal was assigned to e.g. output stream one and the male speech signal to output stream two. In turn, this enabled the \ac{FNN} to separate unknown speakers of different gender. However, even though the techniques proposed in \cite{weng_deep_2015,wang_unsupervised_2016} could separate two-speaker speech signals without \emph{a priori} knowledge about the identity of the speakers, they were still rather limited as they were not easily scaled to more than two speakers of various gender. \subsubsection{Label Permutation Problem} The limited success of \ac{DNN} based techniques for speaker-independent multi-talker speech separation, and the reason why most techniques considered only known-two-speaker separation (see e.g. \cite{du_speech_2014,huang_deep_2014,huang_joint_2015,weng_deep_2015,wang_unsupervised_2016,zhang_deep_2016,healy_algorithm_2017,tu_speaker-dependent_2017,venkataramani_end--end_2017,delfarah_recurrent_2018,bramslow_improving_2018}), is partly due to a label permutation problem. When training a \ac{DNN} for speaker-independent multi-talker speech separation the permutation of the sources at the output of the \ac{DNN} is unknown. Specifically, for a two-speaker separation task, let $\barbelow{o}_1$ denote a target vector for speaker one, and let $\barbelow{o}_2$ denote a target vector for speaker two. Furthermore, let $\barbelow{o} = \left[ \barbelow{o}^T_1 \; \barbelow{o}^T_2 \right]^T$ denote a concatenated supervector. Finally, let $\hat{\barbelow{o}}$, which is the output of a \ac{DNN}, denote the estimate of $\barbelow{o}$. Then, during training, the target vector can in principle be in one of two configurations: either as $\barbelow{o} = \left[ \barbelow{o}^T_1 \; \barbelow{o}^T_2 \right]^T$ or as $\barbelow{o} = \left[ \barbelow{o}^T_2 \; \barbelow{o}^T_1 \right]^T$. Empirically, it has been observed that if $\barbelow{o}_1$ and $\barbelow{o}_2$ always represent the same speakers, or by speakers of the same gender, training with a predefined permutation, such as $\barbelow{o} = \left[ \barbelow{o}^T_1 \; \barbelow{o}^T_2 \right]^T$ or as $\barbelow{o} = \left[ \barbelow{o}^T_2 \; \barbelow{o}^T_1 \right]^T$, is possible, and is basically the technique used in \cite{delfarah_recurrent_2018,weng_deep_2015,wang_unsupervised_2016,huang_joint_2015,huang_deep_2014}. On the other hand, due to the label permutation problem, training simply fails, if the training set consist of many utterances spoken by many speakers of both genders. \subsubsection{Deep Clustering} The first successful technique, known as deep clustering, that solved the label permutation problem was proposed by Hershey \emph{et al.} \cite{hershey_deep_2016}. In deep clustering, the speech separation problem is cast as a clustering problem instead of a classification or regression problem as previous techniques. Hershey \emph{et al.} \cite{hershey_deep_2016} used \ac{LSTM}-\acp{RNN} to learn a mapping from each T-F unit in the mixture signal to a high dimensional embedding space, where embeddings of T-F units belonging to the same speaker are close (in some sense) and form speaker-specific clusters, which can then be used to separate the speech signals. More specifically, let $\barbelow{y} \in \mathbb{R}^{N}$ denote a feature vector of a mixture signal defined according to Eq.\,\eqref{eq42} containing $s = 1,2, \dots, S$ linearly mixed speakers. The feature representation can e.g. be given by a \ac{STFT} such that $N = K \times M$ denote the total number of T-F units, where $K$ is the total number of frequency bins and $M$ is the total number of time-frames. Furthermore, let $\barbelow{\barbelow{V}} \in \mathbb{R}^{N \times S}$ denote a target matrix with a row for each index in $\barbelow{y}$, i.e. for each T-F unit, and each row in $\barbelow{\barbelow{V}}$ is given by an $S$-dimensional one-hot encoded vector that indicates what speaker a given T-F unit belongs to. For example, for $S=3$, if the first T-F unit in $\barbelow{y}$ is dominated by, say, speaker one, the first row in $\barbelow{\barbelow{V}}$ will be given as $[1\; 0\; 0]$. The second row will be $[0\; 0\; 1]$, if the second entry in $\barbelow{y}$ is dominated by speaker three, and so on. The rows in $\barbelow{\barbelow{V}}$ can be viewed as a generalization of the \ac{IBM} to multiple speakers as the assignment of a T-F unit to a speaker is simply defined as the speaker with the most energy in the given T-F unit. The matrix $\barbelow{\barbelow{V}}$ can also be seen as an $S$-dimensional embedding of each entry in $\barbelow{y}$ and from $\barbelow{\barbelow{V}}$ it is trivial to identify which T-F units in $\barbelow{y}$ belong to the same speaker, by simply applying a clustering algorithm, e.g. K-means \cite{macqueen_methods_1967}, to the rows of $\barbelow{\barbelow{V}}$. Since $\barbelow{\barbelow{V}}$ is easily constructed in laboratory conditions, where speech mixtures can be synthetically mixed according to Eq.\,\eqref{eq42}, one can imagine to use $\barbelow{\barbelow{V}}$ as a training target for supervised learning and then estimate a matrix $\barbelow{\barbelow{\hat{V}}} \in \mathbb{R}^{N \times D}$ as \begin{equation} \barbelow{\barbelow{\hat{V}}} = f(\barbelow{y},\theta), \label{eq218} \end{equation} where $f(\barbelow{y},\theta)$ denote a parameterized learning model that maps each entry of $\barbelow{y}$ into a $D$-dimensional embedding space such that they are clustered similarly to the $S$-dimensional embeddings in $\barbelow{\barbelow{V}}$. In fact, Hershey \emph{et al.} showed in \cite{hershey_deep_2016} that an estimate $\barbelow{\barbelow{\hat{V}}}$ can easily be acquired by a model $f(\barbelow{y},\theta)$ when it has been trained using a cost function given as \begin{equation} \begin{aligned} \mathcal{J}(\barbelow{\barbelow{\hat{V}}}, \barbelow{\barbelow{V}}) &= \left\lVert \barbelow{\barbelow{\hat{V}}} \barbelow{\barbelow{\hat{V}}}^T - \barbelow{\barbelow{V}} \barbelow{\barbelow{V}}^T \right\lVert_F^2, \\ \end{aligned} \label{eq219} \end{equation} where $\lVert \cdot \lVert_F^2$ is the squared Frobenius, and $\barbelow{\barbelow{\hat{V}}} \barbelow{\barbelow{\hat{V}}}^T \in \mathbb{R}^{N \times N}$ and $\barbelow{\barbelow{{V}}} \barbelow{\barbelow{{V}}}^T \in \mathbb{R}^{N \times N}$ denote affinity matrices that indicate if a pair of T-F units belong to the same speaker/cluster. If an estimate $\barbelow{\barbelow{\hat{V}}}$ is acquired from a well-trained model $f(\barbelow{y},\theta)$, the cluster assignments for all T-F units are easily found using e.g. K-means clustering, which can then be used to form a binary mask that can separate the mixture signal. Note, the matrices $\barbelow{\barbelow{\hat{V}}} \barbelow{\barbelow{\hat{V}}}^T$ and $\barbelow{\barbelow{{V}}} \barbelow{\barbelow{{V}}}^T$ are $N \times N$, which for long signals gets intractable to compute. For example, for a 10s audio signal with a 256-point \ac{STFT} using 10 ms frame hop, these matrices have more than 16 billion entries. However, as $S,D \ll N$, Hershey \emph{et al.} proposed to minimize the equivalent, but computationally tractable, cost function given by \begin{equation} \begin{aligned} \mathcal{J}(\barbelow{\barbelow{\hat{V}}}, \barbelow{\barbelow{V}}) &= \left\lVert \barbelow{\barbelow{\hat{V}}}^T \barbelow{\barbelow{\hat{V}}} \right\lVert_F^2 - 2 \left\lVert \barbelow{\barbelow{\hat{V}}}^T \barbelow{\barbelow{V}} \right\lVert_F^2 + \left\lVert \barbelow{\barbelow{V}} \barbelow{\barbelow{V}}^T \right\lVert_F^2 , \end{aligned} \label{eq220} \end{equation} which scales according to $\mathcal{O}(D^2)$, and not as $\mathcal{O}(N^2)$. As shown in Hershey \emph{et al.} \cite{hershey_deep_2016}, the label permutation problem is elegantly avoided when the speech separation problem is cast as a clustering problem. Furthermore, when $f(\barbelow{y},\theta)$ is modeled using \ac{LSTM}-\acp{RNN}, state-of-the-art results can be achieved. However, although Hershey \emph{et al.} \cite{hershey_deep_2016} reported unprecedented results on a speaker-independent single-microphone multi-talker speech separation task, the deep clustering approach had several drawbacks. For example, during inference, a clustering algorithm, e.g. K-means \cite{macqueen_methods_1967}, is required to separate the speakers and consequently the number of speakers $S$ needs to be known \emph{a priori}. Also, deep clustering as proposed by Hershey \emph{et al.} \cite{hershey_deep_2016} use a binary gain, which may not be optimal if a large number of speakers or noise sources are present in the mixture. Furthermore, in \cite{hershey_deep_2016} only clean speech is considered and it is not obvious how noise sources should be handled. Finally, as each T-F unit is represented by a D-dimensional embedding vector (in \cite{hershey_deep_2016} $D\approx40$), the output of a deep clustering model needs to be $D$-times larger than the input, which might be computationally demanding for long signals. As a final note, concurrently with the work presented in this thesis, the deep clustering technique has been improved in several aspects such as, soft-clustering \cite{isik_single-channel_2016}, regression based speech enhancement \cite{luo_deep_2017}, improved objective functions \cite{wang_alternative_2018}, and phase estimation \cite{wang_end--end_2018}, which have led to significant gains in performance when measured by \ac{SDR} (see Sec.\,\ref{secsdr}). Also, concurrently with our work, other competing techniques have been proposed such as the deep attractor network \cite{chen_deep_2017,luo_speaker-independent_2018} and source-contrastive estimation \cite{stephenson_monaural_2017-1}, which are both techniques inspired by deep clustering. \section{Directions of Future Research} During the last decade deep learning has evolved from a somewhat exotic academic discipline to a fairly mature technology that is widely accessible and is used at an industrial scale. Consequently, deep learning has received a tremendous amount of attention from both academia and industry and new deep learning theory, and applications of deep learning, are constantly being proposed. This also applies within the areas of speech enhancement and speech separation where an almost countless number of papers have been published over the last couple of years. Promising research directions in the area of deep learning based speech enhancement and separation include: \subsection*{Scale Up While Scaling Down} As apparent from Secs.\,\ref{deeplearn} and \ref{deepsesep}, DNNs must be fairly big, have multiple layers, a large amount of units, and be trained on a large amount of data before they can perform well. Obviously, one way to achieve better performance is simply to scale up and train with even more data and use even larger models \cite{halevy_unreasonable_2009,shazeer_outrageously_2017}. Indeed, this is a valid approach, and is one of the main innovations, if you will, behind many state-of-the-art deep learning based techniques. However, training such models is computationally demanding, but more importantly, the memory and computational requirements of DNNs might prohibit their use in applications where computational resources are limited, such as in small embedded devices like mobile phones or hearing aids. Therefore, a direction of future research, which is already very active, is on scaling down DNNs without compromising performance, e.g. by reducing the number of parameters in an informed way, increasing the number of layers, while decreasing the number of units, to make the model more parameter-efficient, or reducing the numerical precision of the weights (see e.g. \cite{bianchini_complexity_2014,gupta_deep_2015,tu_reducing_2016,garland_low_2016,kim_bitwise_2017,molchanov_pruning_2017,cintra_low-complexity_2018}). \subsection*{Beyond Single-Microphone Algorithms} In this thesis, we have focused purely on single-microphone algorithms. However, utilizing information from multiple microphones can be beneficial if the signal of interest is spatially separated from the interference signals. In such situations, improved performance might be achieved if this information is included. Hence, a direction of future research is to study how signals from multiple microphones can be efficiently utilized in a deep learning framework. For example, one might extend the uPIT technique to work with multi-microphone signals. Several promising techniques have already been proposed, where DNNs are used in combination with multi-microphone techniques such as beamforming (see e.g. \cite{hoshen_speech_2015,erdogan_improved_2016,heymann_neural_2016,zhang_deep_2017,drude_tight_2017,boeddeker_exploring_2018,heymann_generic_2017,heymann_beamnet:_2017,boeddeker_optimizing_2017,wang_multi-channel_2018,heymann_performance_2018}). \subsection*{Beyond Single-Modality Algorithms} It is well-known that human auditory perception is strongly influenced by visual perception \cite{mcgurk_hearing_1976} and that speech intelligibility in noisy acoustic conditions increase if the listener can observe the face of the person who speaks \cite{sumby_visual_1954}. Indeed, speech enhancement and separation algorithms can also benefit from such information (see e.g. \cite{hershey_audio-visual_2002}), and although fusing signals from multiple modalities is a challenging task, the emergence of deep learning has alleviated some of these challenges (see e.g. \cite{owens_audio-visual_2018,gabbay_seeing_2018,ephrat_looking_2018}). Therefore, studying how deep learning based techniques for speech enhancement and separation can benefit from e.g. visual data is an interesting direction for future research. \subsection*{Beyond the Mean Squared Error Cost Function} We have already shown in papers [F] and [G] (see Fig.\,\ref{fig:contrib}) that an approximate-STOI cost function is equivalent to the STSA-MSE cost function and no gain in terms of STOI can be achieved by maximizing an approximate-STOI cost function. This conclusion is supported by other very recent work \cite{zhao_perceptually_2018,zhang_training_2018,fu_end--end_2018,naithani_deep_2018}. However, it might be that improvements in speech intelligibility or quality can be achieved by optimizing other perceptually-inspired cost functions such as PESQ or Binaural STOI \cite{andersen_predicting_2016}, e.g. using deep reinforcement learning techniques (see e.g. \cite{koizumi_dnn-based_2017,fakoor_reinforcement_2017}). Therefore, an interesting direction of future research is to consider alternatives to the commonly used STSA-MSE cost function, which might lead to improved performance of DNN based speech enhancement systems. \subsection*{Towards Time-Domain End-to-End Systems} One of the main advantages of deep learning-based techniques is that they do not require highly specialized, and hand-engineered, features as previous machine learning-based technique did. Today, the most used feature, and target, for speech processing applications is the STSA or log-STSA and most speech enhancement and separation algorithms apply the phase of the noisy signal for time-domain reconstruction. Obviously, this is sub-optimal since the noisy phase can only lead to distortions. Therefore, an interesting direction of future research is to study how deep learning models can operate directly on the time-domain signa \footnote{In fact, this is exactly what Tamura \emph{et al.} \cite{tamura_noise_1988} attempted in 1988 using DNNs, although, today, we might have the model architecture, data, and computational resources to actually succeed. , which potentially can lead to improved performance over the current methods which rely on the noisy phase. In fact, a potential deep learning model for time-domain processing is the CNN, which has already shown promising results with respect to time-domain speech enhancement (see e.g. \cite{hoshen_speech_2015,park_fully_2017,fu_raw_2017,venkataramani_end--end_2017,bai_convolutional_2018,zeghidour_end--end_2018,fu_end--end_2018,lee_raw_2017}). \section{Speech Enhancement and Separation}\label{sec:classical_se} The common goal of single-microphone speech enhancement and single-microphone multi-talker speech separation algorithms is to improve some aspects, e.g. quality or intelligibility, of a single-microphone recording of one or more degraded speech signals \cite{deller_discrete-time_1993,divenyi_speech_2005,loizou_speech_2013,hendriks_dft-domain_2013}. As the name implies, single-microphone algorithms process sound signals captured by a single microphone. Such algorithms are useful in applications where microphone arrays cannot be utilized, e.g. due to space, power, or hardware-cost restrictions, e.g. for in-the-ear hearing aids. Furthermore, since single-microphone algorithms do not rely on the spatial locations of target and interference signals, single-microphone algorithms compliment multi-microphone algorithms and can be used as a post-processing step for techniques such as beamforming, as those techniques are mainly effective, when target and interference signals are spatially separated \cite{brandstein_microphone_2001}. Therefore, algorithms capable of enhancing or separating speech signals from single-microphone recordings are highly desirable. The main difference between speech enhancement and multi-talker speech separation algorithms is the number of target signals. If the target is only a single speech signal and all remaining sounds in the recording, both speech and non-speech sounds, are considered as noise, extracting that particular speech signal from the recording is considered as a speech enhancement task. On the other hand, if the recording contains multiple speech signals, and possibly multiple non-speech sounds, and two or more of these speech signals are of interest, the task is a multi-talker speech separation task. In this sense, the speech enhancement problem may be seen as a special case of the multi-talker speech separation problem. Applications for speech enhancement include mobile communication devices, e.g. mobile phones, or hearing assistive devices where usually only a single speech signal is the target. For these applications, successful algorithms have been developed, which e.g. rely on interference characteristics which are different than speech. Hence, these methods would not perform well for speech-like interference signals. Applications for multi-talker speech separation include automatic meeting transcription, multi-party human-machine interaction, e.g. for video games like Xbox or PlayStation, or automatic captioning for audio/video recordings, e.g. for YouTube or Facebook, all situations where overlapping speech is not uncommon. Since the interference signals for these applications are speech signals, single-microphone multi-talker speech separation possesses additional challenges compared to single-microphone speech enhancement. However, in theory, a perfect system for multi-talker speech separation would also be a perfect system for speech enhancement, but not the other way around. \subsection{Classical Speech Enhancement Algorithms}\label{classe} Let $x[n]$ be a sample of a clean time-domain speech signal and let a noisy observation $y[n]$ be defined as \begin{equation} y[n] = x[n] + v[n], \label{eq1} \end{equation} where $v[n]$ is an additive noise sample representing any speech and non-speech, interference signal. Then, the goal of single-microphone speech enhancement is to acquire an estimate $\hat{x}[n]$ of $x[n]$, which in some sense is "close to" $x[n]$ using $y[n]$ only. Throughout the years, a wide range of techniques have been proposed for estimating $x[n]$ and many of these techniques follow the gain-based approach shown in Fig.\;\ref{fig:se} , e.g. \cite{hendriks_dft-domain_2013,loizou_speech_2013}. \begin{figure} \centering \begin{tikzpicture}[baseline=(current bounding box.north)] \input{figures/se_sys.tex} \end{tikzpicture} \caption{Classical gain-based speech enhancement system. The noisy time-domain signal $y[n] = x[n] + v[n]$ is first segmented into overlapping frames $\barbelow{y}_m$. An analysis stage then applies a transform to arrive in a transform-domain $r(k,m)$ for time-frame $m$ and transform-coefficient $k$. A gain $\hat{g}(k,m)$ is then estimated and applied to $r(k,m)$ to arrive at an enhanced transform-coefficient $\hat{a}(k,m) = \hat{g}(k,m)r(k,m)$. Finally, a synthesis stage transforms the enhanced transform-coefficient into time domain and the final time-domain signal $\hat{x}[n]$ is obtained by overlap-add.} \label{fig:se} \end{figure} First, the noisy time-domain signal $y[n]$ is segmented into overlapping frames $\barbelow{y}_m$ using a sliding window of length $N$. An analysis stage then applies a transform, e.g. the \ac{DFT}, to the frames to arrive in a transform-domain $r(k,m)$ for time-frame $m$ and transform-coefficient $k$. An estimator, to be further defined in the next sections, estimates a gain value $\hat{g}(k,m)$ that is applied to $r(k,m)$ to arrive at an enhanced transform-coefficient $\hat{a}(k,m) = \hat{g}(k,m)r(k,m)$. A synthesis stage then applies an inverse transform to the enhanced transform-coefficients to transform the coefficients back to time domain. Finally, the time-domain signal $\hat{x}[n]$ is obtained by overlap-adding the enhanced time-domain frames $\barbelow{\hat{x}}_m$ \cite{allen_short_1977}. Although many speech enhancement algorithms follow the gain-based approach, their strategy for finding the gain value $\hat{g}(k,m)$, i.e. the design of the gain estimator, can be very different, and, in general, these techniques may be divided into four classes \cite{loizou_speech_2013}: 1) Spectral subtractive-based algorithms (Sec.\,\ref{sec:se_sub1} ), 2) Statistical model-based algorithms (Sec.\,\ref{sec:se_sub2} ), 3) Subspace based algorithms (Sec.\,\ref{sec:se_sub3} ), and 4) Machine learning-based algorithms (Sec.\,\ref{sec:ml_cl_se}). \subsubsection{Spectral Subtraction Methods}\label{sec:se_sub1} Speech enhancement algorithms based on spectral subtraction belong to the first class of algorithms proposed for speech enhancement and were developed in the late 1970s \cite{boll_suppression_1979,mcaulay_speech_1980,loizou_speech_2013}. Specifically, let $y(k,m)$, $x(k,m)$, and $v(k,m)$ be the \ac{STFT} coefficients of the noisy signal $y[n]$, clean signal $x[n]$, and noise signal $v[n]$, from Eq.\;\eqref{eq1}, respectively. The spectral subtraction algorithm in its simplest form is then defined as \begin{equation} \hat{x}(k,m) = \left[|y(k,m)| - |v(k,m)| \right] e^{j\phi_y{(k,m)}}, \label{eq2} \end{equation} where $|\cdot|$ denotes absolute value and $e^{j\phi_y{(k,m)}}$ is the phase of the noisy \ac{STFT} coefficients $y(k,m)$. From Eq.\;\eqref{eq2} it is clear why this algorithm is named "spectral subtraction" as the estimate $\hat{x}(k,m)$ is acquired simply by subtracting the noise magnitude $|v(k,m)|$ from the magnitude of the noisy signal $|y(k,m)|$ and appending the noisy phase $e^{j\phi_y{(k,m)}}$. Furthermore, by slightly rewriting Eq.\;\eqref{eq2}, we arrive at \begin{equation} \hat{x}(k,m) = g(k,m) |y(k,m)|e^{j\phi_y{(k,m)}}, \label{eq3} \end{equation} where \begin{equation} g(k,m) = 1-\frac{|v(k,m)|}{|y(k,m)|} \label{eq4} \end{equation} is the gain function, which clearly shows that spectral subtraction as defined by Eq.\;\eqref{eq2} indeed belongs to the family of gain-based speech enhancement algorithms. Finally, although spectral subtraction as defined by Eq.\;\eqref{eq2} was primarily motivated heuristically \cite{boll_suppression_1979}, it was later shown \cite{mcaulay_speech_1980} that Eq.\;\eqref{eq2} is closely related to the maximum likelihood estimate of the clean speech \ac{PSD}, when speech and noise are modeled as independent stochastic processes \cite{mcaulay_speech_1980}. An assumption that is used heavily in later successful speech enhancement algorithms \cite{ephraim_speech_1984,hendriks_dft-domain_2013}. Although speech enhancement algorithms based on the spectral subtraction principle effectively reduce the noise in noisy speech signals, it has a few disadvantages. First, it requires an accurate estimate of the noise magnitude $|v(k,m)|$, which in general is not easily available and might be time varying. As a consequence, $|v(k,m)|$ was first estimated from non-speech periods prior to speech activity, e.g. using a \ac{VAD} algorithm \cite{loizou_speech_2013}. Furthermore, due to estimation errors of $|v(k,m)|$, $|\hat{x}(k,m)|$ might be negative, which by definition is an invalid magnitude spectrum. Several techniques have been proposed to alleviate this side-effect (e.g. \cite{boll_suppression_1979,hansen_use_1989,sondhi_improving_1981,haitian_spectral_2004,loizou_speech_2013}) and the simplest is to apply a half-wave rectifier and set all negative values to zero. Another technique is to set negative values to the value of adjacent non-negative frames, but regardless of the technique, spectral subtractive-based techniques are prone to signal distortions known as \emph{musical noise} due to estimation errors in the estimate of the noise magnitude $|v(k,m)|$. \subsubsection{Statistically Optimal Methods}\label{sec:se_sub2} Although spectral subtractive-based techniques are effective speech enhancement algorithms, they are primarily based on heuristics and not derived deliberately to be mathematically optimal. If, however, the speech enhancement problem is formulated as a statistical estimation problem with a well-defined optimality criterion and strictly defined statistical assumptions, a class of \emph{optimal} speech enhancement algorithms can be developed \cite{hansen_iterative_1987,chen_new_2006,loizou_speech_2013,deller_discrete-time_1993,ephraim_statistical-model-based_1992,erkelens_minimum_2007,loizou_speech_2005,v_survey_2014,hendriks_dft-domain_2013,ephraim_speech_1984,ephraim_speech_1985,mcaulay_speech_1980}. One such class is the \ac{MMSE} estimators, for which two large sub-classes are the linear \ac{MMSE} estimators, commonly known as \emph{Wiener filters} after the mathematician Nobert Wiener \cite{wiener_extrapolation_1949}, and the non-linear \ac{STSA}-\ac{MMSE} estimators \cite{ephraim_speech_1984}. \paragraph{Basic Wiener Filters} \mbox{}\\ Wiener filters are minimum mean squared error optimal linear filters for the linear estimation problem shown in Fig.\,\ref{fig:wien}, where the observed signal $y[n]$ is given by $y[n] = x[n] + v[n]$, where $x[n]$ and $v[n]$ are assumed to be uncorrelated and stationary stochastic processes \cite{chen_new_2006,loizou_speech_2013,deller_discrete-time_1993}. \begin{figure} \centering \begin{tikzpicture}[baseline=(current bounding box.north)] \input{figures/wiener.tex} \end{tikzpicture} \caption{Linear estimation problem for which Wiener filters are optimal in a mean squared error sense.} \label{fig:wien} \end{figure} Wiener filters can have either a \ac{FIR} or an \ac{IIR} or be even non-causal. For the causal \ac{FIR} Wiener filter, the estimated signal $\hat{x}[n]$ is given by \begin{equation} \hat{x}[n] = \barbelow{h}^T_o \barbelow{y}(n), \label{eq5} \end{equation} where \begin{equation} \barbelow{h}_o = [h_1,\; h_2,\; \dots,\; h_L]^T \label{eq6} \end{equation} are the optimal filter coefficients and \begin{equation} \barbelow{y}(n) = [y[n],\; y[n-1],\; \dots,\; y[n-L+1]]^T \label{eq7} \end{equation} are the past $L$ samples of the observed signal. The optimal filter, $\barbelow{h}_o$, i.e. the Wiener filter, is then defined as \begin{equation} \barbelow{h}_o = \underset{\barbelow{h}}{\operatorname{arg\,min}} \;\; J_x(\barbelow{h}), \label{eq8} \end{equation} where $J_x(\barbelow{h})$ is the mean squared error given by \begin{equation} \begin{split} J_x(\barbelow{h}) = \mathbb{E}\{e^2[n]\} =& \mathbb{E}\{(x[n]-\hat{x}[n])^2\}, \end{split} \label{eq9} \end{equation} and $\mathbb{E}\{\cdot\}$ denote mathematical expectation. Finally, by differentiating Eq.\,\eqref{eq9} with respect to $\barbelow{h}$, equating to zero, and solving for $\barbelow{h}$, the optimal filter coefficients $\barbelow{h}_o$ are found to be \begin{equation} \begin{split} \barbelow{h}_o & = (\barbelow{\barbelow{R}}_{\barbelow{x}\barbelow{x}} +\barbelow{\barbelow{R}}_{\barbelow{v}\barbelow{v}} )^{-1} \barbelow{r}_{x\barbelow{x}}, \end{split} \label{eq10} \end{equation} which is the well-known Wiener-Hopf solution% \footnote{The Wiener-Hopf solution is usually on the form $\barbelow{\barbelow{R}}_{\barbelow{y}\barbelow{y}}^{-1} \barbelow{r}_{x\barbelow{y}}$ but since $x[n]$ and $v[n]$ are assumed uncorrelated, $\barbelow{\barbelow{R}}_{\barbelow{y}\barbelow{y}} = \barbelow{\barbelow{R}}_{\barbelow{x}\barbelow{x}} + \barbelow{\barbelow{R}}_{\barbelow{v}\barbelow{v}}$ and $\barbelow{r}_{x\barbelow{y}} = \barbelow{r}_{x\barbelow{x}}$.} \cite{loizou_speech_2013,proakis_digital_2007}, where $\barbelow{\barbelow{R}}_{\barbelow{x}\barbelow{x}}$ and $\barbelow{\barbelow{R}}_{\barbelow{v}\barbelow{v}}$ denote the autocorrelation matrices of $\barbelow{x}$ and $\barbelow{v}$, respectively, and $\barbelow{r}_{x\barbelow{x}} = \mathbb{E}\{ x[n]\barbelow{x}\}$ denote the autocorrelation vector. From Eq.\,\eqref{eq10} it is seen that the optimal filter coefficients $\barbelow{h}_o$ are based on $\barbelow{\barbelow{R}}_{\barbelow{x}\barbelow{x}}$, $\barbelow{\barbelow{R}}_{\barbelow{v}\barbelow{v}}$, and $\barbelow{r}_{x\barbelow{x}}$, which are not directly available and must be estimated, for the filter to be used in practice. Since the noise process $v[n]$ is assumed to be stationary, accurate estimates of $\barbelow{\barbelow{R}}_{\barbelow{v}\barbelow{v}}$ might be acquired during non-speech periods and used during speech-active periods \cite{deller_discrete-time_1993,loizou_speech_2013}. An alternative to the time-domain Wiener filter is the frequency-domain Wiener filter. If the filter $\barbelow{h}$ is allowed to be of infinite duration and non-causal, i.e. $\barbelow{h}' = [ \dots , h'_{-1},\; h'_{0},\;h'_{1},\; \dots ]$, the Wiener filter can be defined in the frequency domain using a similar approach as just described. Let \begin{equation} \hat{x}(\omega) = g(\omega) y(\omega), \label{eq11} \end{equation} where $\hat{x}(\omega)$, $g(\omega)$, and $y(\omega)$ denote the \ac{DTFT} of the estimated speech signal $\hat{x}[n]$, the infinite duration time-domain filter $\barbelow{h}'$, and the noisy speech signal $y[n]$, respectively. The frequency domain Wiener filter is then given as \cite{loizou_speech_2013,deller_discrete-time_1993} \begin{equation} H(\omega) = \frac{P_{x}(\omega) }{P_{x}(\omega) +P_{v}(\omega) }, \label{eq12} \end{equation} where $P_{x}(\omega)$, and $P_{v}(\omega)$ are the \ac{PSD} of the clean speech signal $x[n]$, and noise signal $v[n]$, respectively. Alternatively, the frequency domain Wiener filter can be formulated as \begin{equation} H(\omega) = \frac{\xi_\omega }{\xi_\omega + 1}, \label{eq13} \end{equation} where \begin{equation} \xi_\omega = \frac{ P_{x}(\omega) }{P_{v}(\omega) } \label{eq14} \end{equation} is known as the \emph{a priori} \ac{SNR} at frequency $\omega$. From Eqs.\;\eqref{eq12} and \eqref{eq13} it is seen that the frequency-domain Wiener filter $g(\omega)$ is real, even, and non-negative and, consequently, does not modify the phase of $y(\omega)$, hence $\hat{x}(\omega)$ will have the same phase as $y(\omega)$, similarly to the spectral subtractive-based approaches \cite{gerkmann_phase_2012}. Furthermore, from Eq.\;\eqref{eq13} it can be deduced that the Wiener filter operates by suppressing signals with low \ac{SNR} relatively more than signals with higher \ac{SNR}. Finally, similarly to the time-domain Wiener filter, the frequency-domain Wiener filter, as formulated by Eqs.\;\eqref{eq12} and \eqref{eq13}, is not directly applicable in practice as speech may only be stationary during short time periods and information about the \emph{a priori} \ac{SNR} is not available in general. Consequently, $P_{x}(\omega)$ and $P_{v}(\omega)$ must be estimated using e.g. iterative techniques for short time periods where speech and noise are approximately stationary, e.g. \cite{loizou_speech_2013,deller_discrete-time_1993}. \paragraph{Basic STSA-MMSE Estimators} \mbox{}\\ Although the Wiener filter is considered the optimal complex spectral estimator, it is not the optimal spectral amplitude estimator, and based on the common belief at-the-time that phase was much less important than amplitude for speech enhancement (see e.g. \cite{wang_unimportance_1982,paliwal_importance_2011,gerkmann_phase_2012,gerkmann_phase_2015,mowlaee_phase_2014,mowlaee_phase-aware_2016} and references therein), it led to the development of optimal spectral amplitude estimators, commonly known as \ac{STSA}-\ac{MMSE} estimators \cite{ephraim_speech_1984}. Differently from the Wiener filters, \ac{STSA}-\ac{MMSE} estimators do not assume a linear relation between the observed data and the estimator. Instead, the \ac{STSA}-\ac{MMSE} estimators are derived using a Bayesian statistical framework, where explicit assumptions are made about the probability distributions of speech and noise \ac{DFT} coefficients. Specifically, let $A(k,m)$, and $R(k,m)$, $k = 1,\,2,\,\dots,\, K$, $m=1,\,2,\,\dots,\, M $ denote random variables representing the $K$-point \ac{STFT} magnitude spectra for time frame $m$ of the clean speech signal $x[n]$, and noisy speech signal $y[n]$, respectively. Let $\hat{A}(k,m)$, and $V(k,m)$ be defined in a similar manner for the estimated speech signal $\hat{x}[n]$ and the noise signal $v[n]$, respectively. In the following the frame index $m$ will be omitted for convenience as all further steps apply for all time frames. Let \begin{equation} \barbelow{A} = \left[ A_1, A_2, \, \dots, \, A_K \right]^T, \label{eq16} \end{equation} \begin{equation} \barbelow{R} = \left[ R_1, R_2, \, \dots, \, R_K \right]^T, \label{eq17} \end{equation} and \begin{equation} \barbelow{\hat{A}} = \left[ \hat{A}_1, \hat{A}_2, \, \dots, \, \hat{A}_K \right]^T, \label{eq18} \end{equation} be the stack of these random variables into random vectors. Also, let $p(\barbelow{A},\barbelow{R})$ denote the joint \ac{PDF} of clean and noisy spectral magnitudes and $p(\barbelow{A}|\barbelow{R})$, and $p(\barbelow{R})$ denote a conditional and marginal \ac{PDF}, respectively. Finally, let the Bayesian \ac{MSE} \cite{kay_fundamentals_2010,loizou_speech_2013} between the clean speech magnitude $\barbelow{A}$ and the estimated speech magnitude $\barbelow{\hat{A}}$, be defined as \begin{equation} \begin{split} \mathcal{J}_{MSE} & = \mathbb{E}_{\barbelow{A},\barbelow{R}} \left\{ \left(\barbelow{A} - \barbelow{\hat{A}} \right)^2 \right\}. \\ \end{split} \label{eq19} \end{equation} By minimizing the Bayesian \ac{MSE} with respect to $\barbelow{\hat{A}}$ it can be shown (see e.g. \cite{kay_fundamentals_2010,loizou_speech_2013}) that the optimal \ac{STSA}-\ac{MMSE} estimator is given as \begin{equation} \begin{split} \barbelow{\hat{A}} & = \mathbb{E}_{\barbelow{A}|\barbelow{R}} \{ \barbelow{A}|\barbelow{R} \}, \\ \end{split} \label{eq20} \end{equation} which is nothing more than the expected value of the clean speech magnitude $\barbelow{A}$ given the observed noisy speech magnitude $\barbelow{R}$. From Eq.\;\eqref{eq20} a large number of estimators can be derived by considering different distributions of $p(\barbelow{A},\barbelow{R})$ \cite{hendriks_dft-domain_2013}. For example, in the seminal work of Ephraim and Malah in \cite{ephraim_speech_1984}, the \ac{STFT} coefficients of the clean speech and noise were assumed to be statistically independent, zero-mean, Gaussian distributed random variables. This assumption is motivated by the fact that \ac{STFT} coefficients become uncorrelated, and under a Gaussian assumption therefore independent, with increasing frame length. Based on these assumptions Eq.\,\eqref{eq20} simplifies \cite{ephraim_speech_1984,loizou_speech_2013} to \begin{equation} \begin{split} \hat{A}(k) & = G(\psi_k,\gamma_k) R(k), \\ \end{split} \label{eq21} \end{equation} where $G(\psi_k,\gamma_k)$ is a gain function that is applied to the noisy spectral magnitude $R(k)$, and \begin{equation} \begin{split} \psi_k & = \frac{\mathbb{E}\{|A(k)|^2\}}{\mathbb{E}\{|V(k)|^2\}},\\ \end{split} \label{eq24} \end{equation} and \begin{equation} \begin{split} \gamma_k & = \frac{R^2(k)}{\mathbb{E}\{|V(k)|^2\}}. \\ \end{split} \label{eq25} \end{equation} The term $\psi_k$ is referred to as \emph{a priori} \ac{SNR}, similarly to Eq.\,\eqref{eq14} since $\psi_k \approx \xi_\omega$% \footnote{Equality only holds if \ac{DTFT} coefficients in Eq.\,\eqref{eq24} are computed for infinite sequences of stationary processes. Since they are \ac{DFT} coefficients computed based on finite sequences, it follows that $\psi_k \approx \xi_\omega$.}% , and $\gamma_k$ is referred to as the \emph{a posteriori \ac{SNR}} as it reflects the \ac{SNR} of the observed, or noise corrupted, speech signal. As seen from Eq.\,\eqref{eq21} the \ac{STSA}-\ac{MMSE} gain is a function of \emph{a priori} and \emph{a posteriori} \ac{SNR}. However, although the Wiener gain in Eq.\,\eqref{eq13} is also a function of \emph{a priori} \ac{SNR}, the \ac{STSA}-\ac{MMSE} gain in general introduces less artifacts at low SNR than the Wiener gain, partially due to the \emph{a posteriori} \ac{SNR} \cite{loizou_speech_2013,hu_subjective_2006}. In fact, at high \acp{SNR} (\ac{SNR} > 20 dB) the gains from the Wiener filter and STSA-MMSE estimator converges to the same value \cite{ephraim_speech_1984,loizou_speech_2013,chen_new_2006}. Since the first \ac{STSA}-\ac{MMSE} estimator was proposed using a Gaussian assumption, a large range of estimators have been proposed with different statistical assumptions, and cost functions, in an attempt to improve the performance by utilizing either more accurate statistical assumptions, which are more in line with the true probability distribution of speech and noise, or cost functions more in line with human perception \cite{loizou_speech_2005,martin_speech_2005,ephraim_speech_1985,ephraim_statistical-model-based_1992,hendriks_log-spectral_2009,hendriks_dft-domain_2013,erkelens_estimation_2008,erkelens_minimum_2007,cohen_relaxed_2005,cohen_speech_2005}. Finally, note that similarly to the Wiener filters, the \emph{a priori} \ac{SNR} has to be estimated, e.g. using noise \ac{PSD} tracking (see e.g. \cite{hendriks_dft-domain_2013} and references therein), in order to use the \ac{STSA}-\ac{MMSE} estimators in practice. \subsubsection{Subspace Methods}\label{sec:se_sub3} The third class of enhancement algorithms are known as subspace-based algorithms, as they are derived primarily using principles from linear algebra and not, to the same degree, on principles from signal processing and estimation theory, as the previously discussed algorithms were \cite{loizou_speech_2013}. The general underlying assumption behind these algorithms is that $K$-dimensional vectors of speech signals do not span the entire $K$-dimensional euclidean space, but instead are confined to a smaller $M$-dimensional subspace, i.e. $M < K$ \cite{ephraim_signal_1995,benesty_speech_2005}. Specifically, let a stationary stochastic process representing a clean speech signal $\barbelow{X} = \left[ X_1,\;X_2,\; \dots, \; X_K \right]^T$ be defined as \begin{equation} \barbelow{X} = \sum_{m=1}^{M} C_m \barbelow{p}_m = \barbelow{\barbelow{P}} \barbelow{C}, \label{eq26} \end{equation} where $C_m$ are zero-mean, potentially complex, random variables and $\barbelow{p}_m$ are $K$-dimensional linearly independent, potentially complex, basis vectors, e.g. complex sinusoids \cite{ephraim_signal_1995}. Here, \begin{equation} \barbelow{C} = \left[ C_1,\, C_2, \, \dots, \, C_M \right]^T \in \mathbb{R}^{M}, \label{eq26_1} \end{equation} and \begin{equation} \barbelow{P} = \left[ \barbelow{p}_1,\, \barbelow{p}_2, \, \dots, \, \barbelow{p}_M \right] \in \mathbb{R}^{K \times M}, \label{eq26_2} \end{equation} and if $M = K$, the transformation between $\barbelow{X}$ and $\barbelow{C}$ is always possible as it corresponds to a change of coordinate system \cite{ephraim_signal_1995}. However, for speech signals, such a transformation is often possible for $M < K$ \cite{ephraim_signal_1995}, which implies that $\barbelow{X}$ lies in a $M$-dimensional subspace spanned by the $M$ columns of $\barbelow{\barbelow{P}}$ in the $K$-dimensional Euclidean space. This subspace, is commonly referred to as the signal subspace. Since the rank, denoted as $\mathcal{R}\{\cdot\}$, of $\barbelow{\barbelow{P}}$ is $\mathcal{R}\{\barbelow{\barbelow{P}}\} = M$, the covariance matrix of $\barbelow{X}$, \begin{equation} \barbelow{\barbelow{\Sigma}}_X = \mathbb{E}\{\barbelow{X}\barbelow{X}^T\} = \barbelow{\barbelow{P}} \barbelow{\barbelow{\Sigma}}_C \barbelow{\barbelow{P}}^T \in \mathbb{R}^{K \times K}, \label{eq27} \end{equation} where $\barbelow{\barbelow{\Sigma}}_C = \mathbb{E}\{\barbelow{C}\barbelow{C}^T\}$ is the covariance matrix of $\barbelow{C}$, will be rank deficient, $\mathcal{R}\{\barbelow{\barbelow{\Sigma}}_X\} = \mathcal{R}\{\barbelow{\barbelow{\Sigma}}_C\} = M < K$. Noting from the stationarity of $\barbelow{X}$ that $\barbelow{\barbelow{\Sigma}}_X \succeq 0$, it follows that $\barbelow{\barbelow{\Sigma}}_X$ only has non-negative eigenvalues. The fact that $\barbelow{\barbelow{\Sigma}}_X$ has some eigenvalues that are equal to zero is the key to subspace-based speech enhancement. For convenience, let us rewrite our signal model from Eq.\,\eqref{eq1} in vector form, \begin{equation} \barbelow{Y} = \barbelow{X} + \barbelow{V}, \label{eq28} \end{equation} where $\barbelow{Y}$, $\barbelow{X}$, and $\barbelow{V}$ are the $K$-dimensional stochastic vectors representing the time-domain noisy speech signal, the clean speech signal, and noise signal, respectively. Employing the standard assumption that speech $\barbelow{X}$ and noise signals $\barbelow{V}$ are stationary, uncorrelated, and zero-mean random processes \cite{ephraim_signal_1995,ephraim_speech_1984} it follows that \begin{equation} \barbelow{\barbelow{\Sigma}}_Y = \barbelow{\barbelow{\Sigma}}_X + \barbelow{\barbelow{\Sigma}}_V, \label{eq29} \end{equation} where $\barbelow{\barbelow{\Sigma}}_Y$, and $\barbelow{\barbelow{\Sigma}}_V$ are the covariance matrices of the noisy speech signal, and noise signal, respectively. Furthermore, with the additional assumption that the noise signal is white, with variance $\sigma_V^2$, Eq.\,\eqref{eq29} reduces to \begin{equation} \barbelow{\barbelow{\Sigma}}_Y = \barbelow{\barbelow{\Sigma}}_X + \sigma_V^2 \barbelow{\barbelow{I}}_K, \label{eq30} \end{equation} where $\barbelow{\barbelow{I}}_K$ is the $K$-dimensional identity matrix. Now, consider the \ac{EVD} of Eq.\,\eqref{eq30} given as \begin{equation} \barbelow{\barbelow{U}} \barbelow{\barbelow{\Lambda}}_Y \barbelow{\barbelow{U}}^T = \barbelow{\barbelow{U}} \barbelow{\barbelow{\Lambda}}_X \barbelow{\barbelow{U}}^T + \barbelow{\barbelow{U}} \barbelow{\barbelow{\Lambda}}_V \barbelow{\barbelow{U}}^T, \label{eq31} \end{equation} where $\barbelow{\barbelow{U}}$ is a matrix with the $K$ orthonormal eigenvectors of $\barbelow{\barbelow{\Sigma}}_Y$, and $\Lambda = \text{diag}(\lambda_{y,1}, \lambda_{y,2},\dots,\lambda_{y,K})$ is a diagonal matrix with the corresponding $K$ eigenvalues. Since it is assumed that $\mathcal{R}\{\barbelow{\barbelow{\Sigma}}_X\}$ is rank deficient (Eq.\,\eqref{eq26}) the eigenvalues of $\barbelow{\barbelow{\Sigma}}_Y$ can be partitioned in descending order based on their magnitude as \begin{equation} \lambda_{y,k} = \begin{cases} \lambda_{x,k} + \sigma_V^2 & \text{if } k=1,2,\dots, M\\ \sigma_V^2, & \text{if } k=M+1, M+2, \dots, K. \end{cases} \label{eq32} \end{equation} Then, it follows \cite{ephraim_signal_1995,loizou_speech_2013} that the subspace spanned by the eigenvectors corresponding to the $M$ largest eigenvalues of $\barbelow{\barbelow{\Sigma}}_Y$, i.e. the top line in Eq.\,\eqref{eq32}, corresponds to the subspace spanned by the eigenvectors of $\barbelow{\barbelow{\Sigma}}_X$, which is the same subspace spanned by the columns of $\barbelow{\barbelow{P}}$, i.e. the signal subspace. Specifically, let, $\barbelow{\barbelow{U}}$ be partitioned as $\barbelow{\barbelow{U}} = [\barbelow{\barbelow{U}}_1 \;\barbelow{\barbelow{U}}_2]$ such that $\barbelow{\barbelow{U}}_1$ is a $K \times M$ matrix with the eigenvectors corresponding to the $M$ largest eigenvalues of $\barbelow{\barbelow{\Sigma}}_Y$, and $\barbelow{\barbelow{U}}_2$ is a $K \times (K-M)$ with the remaining $K-M$ eigenvectors, then $\barbelow{\barbelow{U}}_1\barbelow{\barbelow{U}}^T_1$ is a projection matrix that orthogonally projects its multiplicand onto the signal subspace. Similarly, $\barbelow{\barbelow{U}}_2\barbelow{\barbelow{U}}^T_2$ will be the projection matrix that projects its multiplicand onto the complementary orthogonal subspace, known as the noise subspace. Hence, it follows that a realization of the noisy signal can be decomposed as \begin{equation} \barbelow{y} = \barbelow{\barbelow{U}}_1\barbelow{\barbelow{U}}^T_1\barbelow{y} + \barbelow{\barbelow{U}}_2\barbelow{\barbelow{U}}^T_2\barbelow{y}. \label{eq33} \end{equation} Finally, since the noise subspace spanned by the columns of $\barbelow{\barbelow{U}}_2$ contains no components of the clean speech signal, the noise subspace can be nulled to arrive at an estimate of the clean speech signal given as \begin{equation} \hat{\barbelow{x}} = \barbelow{\barbelow{U}}_1\barbelow{\barbelow{U}}^T_1\barbelow{y}. \label{eq34} \end{equation} In fact, the solution in Eq.\,\eqref{eq34} can, similarly to the previously discussed methods, be viewed as a gain-based approach (see Fig.\,\ref{fig:se}) given by \begin{equation} \hat{\barbelow{x}} = \barbelow{\barbelow{U}} \barbelow{\barbelow{G}}_M \barbelow{\barbelow{U}}^T_1\barbelow{y}, \label{eq36} \end{equation} where $\barbelow{\barbelow{G}}_M$ is simply the $M$-dimensional identity matrix. In this form, a transformation $\barbelow{\barbelow{U}}^T_1\barbelow{y}$ is applied to the noisy time-domain speech signal $\barbelow{y}$, which in this case is the linear transformation matrix $\barbelow{\barbelow{U}}^T_1$, known as the \ac{KLT}. Then, a unit-gain $\barbelow{\barbelow{G}}_M$ is applied before an inverse \ac{KLT}, $\barbelow{\barbelow{U}}$, is used to reconstruct the enhanced signal to the time-domain. In fact, what differentiate most subspace-based speech enhancement methods is the choice of transform domain $\barbelow{\barbelow{U}}_1$ and the design of the gain matrix $\barbelow{\barbelow{G}}_M$. An alternative to the approach based on the \ac{EVD} of the covariance matrix, is the \ac{SVD} of time-domain signals ordered in either Toeplitz or Hankel matrices \cite{loizou_speech_2013}. Furthermore, the gain matrix can be designed with an explicitly defined trade-off between noise reduction and signal distortion and even to handle colored noise signals \cite{hermus_review_2006,benesty_speech_2005,loizou_speech_2013,lev-ari_extension_2003}. Finally, what most subspace-based speech enhancement algorithms have in common is the need for estimating the covariance matrix of the clean speech, or noise, signal and the, generally time-varying, dimension of the signal subspace $M$. Naturally, if $M$ is overestimated, some of the noise subspace is preserved, but if $M$ is underestimated some of the signal subspace is discarded. Consequently, the quality of these estimates highly influences the performance of subspace-based speech enhancement algorithms. Nevertheless, it has been shown that these algorithms are capable of improving speech intelligibility for hearing impaired listeners wearing cochlear implants \cite{loizou_subspace_2005}. \subsubsection{Machine Learning Methods}\label{sec:ml_cl_se} Common for all the previously discussed clean-speech estimators is that they are all, to some degree, derived using mathematical principles from probability theory, digital signal processing, or linear algebra. Consequently, they are based on various assumptions such as stationarity of the signals involved, uncorrelated clean-speech and noise signals, independence of speech and noise transform coefficients across time and frequency, etc. These assumptions are all trade-offs. On one hand, they must reflect the properties of real speech and noise signals, while, at the other hand, they must be simple enough that they allow mathematical tractable solutions. Furthermore, they all require information about some, generally unknown, quantity such as the noise magnitude $|v(k,m)|$ for spectral subtractive-based techniques, \emph{a priori} \ac{SNR} for the statistically optimal algorithms such as the Wiener filters or \ac{STSA}-\ac{MMSE} estimators, or the signal subspace dimension, or covariance matrices for the clean speech or noise signals, for the subspace-based techniques. These quantities need to be estimated, and their estimates are critical for the performance of the speech enhancement algorithm. Finally, although these techniques are capable of improving the quality of a noisy speech signal, when the underlying assumptions are reasonably met \cite{hu_subjective_2006}, they generally do not improve speech intelligibility for normal hearing listeners \cite{lim_enhancement_1979,kim_gain-induced_2011,hu_comparative_2007,hu_comparative_2007-1,luts_multicenter_2010,loizou_reasons_2011,jensen_spectral_2012,madhu_potential_2013,brons_effects_2014}. A different approach to the speech enhancement task, a completely different paradigm in fact, is to consider the speech enhancement task as a supervised learning problem \cite{bishop_pattern_2006}. In this paradigm, it is believed that the speech enhancement task can be learned from observations of representative data, such as a large number of corresponding pairs of clean and noisy speech signals. Specifically, instead of designing a clean-speech estimator in closed-form using mathematical principles, statistical assumptions, and \emph{a priori} knowledge, the estimator is defined by a parameterized mathematical model, that represents a large function space, potentially with universal approximation properties such as \acp{GMM} \cite{mclachlan_mixture_1988}, \acp{ANN} \cite{hornik_multilayer_1989,cybenko_approximation_1989}, or \acp{SVM} \cite{cortes_support-vector_1995,hammer_note_2003}. The parameters of these machine learning models are then found as the solution to an optimization problem with respect to an objective function evaluated on a representative dataset. This approach is fundamentally different from the previously described techniques since no restrictions, e.g. about linearity, or explicit assumptions, e.g. about stationarity or uncorrelated signals, are imposed on the model. Instead, signal features which are relevant for solving the task at hand, e.g. retrieving a speech signal from a noisy observation, are implicitly learned during the supervised learning process. The potential big advantage of this approach is that less valid assumptions, made primarily for mathematical convenience, can be avoided and as we shall see in this section, and sections to come, such an approach might result in clean-speech estimators with a potential to exceed the performance of the non-machine learning based techniques proposed so far. \pagebreak \paragraph{Basic Principles} \mbox{}\\ The basic principle behind most machine learning based speech enhancement techniques can be formulated as \begin{equation} \hat{\barbelow{o}} = \mathcal{F}(\barbelow{h}(\barbelow{y}),\barbelow{\theta}), \label{eq37} \end{equation} where $\mathcal{F}(\cdot,\barbelow{\theta})$ denotes a parameterized model with parameters $\barbelow{\theta}$. The input signal $\barbelow{y}$ denotes the noisy speech signal and $\barbelow{h}(\cdot)$ is a vector-valued function that applies a feature transformation to the raw speech signal $\barbelow{y}$. The representation of the output $\hat{\barbelow{o}}$ depends on the application, but it could e.g. be the estimated clean-speech signal or the clean-speech \ac{STFT} magnitude. The optimal parameters $\barbelow{\theta}^\ast$ are then found, without loss of generality, as the solution to the minimization problem given as \begin{equation} \begin{aligned} \barbelow{\theta^\ast} = \; & \underset{\barbelow{\theta}}{\text{argmin}} & & \mathcal{J}(\mathcal{F}(\barbelow{h}(\barbelow{y}),\barbelow{\theta}),\barbelow{o}), \;\;\; (\barbelow{y},\barbelow{o}) \in \mathcal{D}_{train}, \\ \end{aligned} \label{eq38} \end{equation} where $\mathcal{J}(\cdot,\cdot)$ is a non-negative objective function, and $(\barbelow{y},\barbelow{o})$ is an ordered pair, of noisy speech signals $\barbelow{y}$ and corresponding targets $\barbelow{o}$, e.g. clean-speech \ac{STFT} magnitudes, from a training dataset $\mathcal{D}_{train}$. In principle, the optimal parameters $\barbelow{\theta}$ are given such that $\mathcal{J}(\mathcal{F}(\barbelow{h}(\barbelow{y}),\barbelow{\theta}^\ast),\barbelow{o}) = 0$, i.e. $\hat{\barbelow{o}} = \barbelow{o} $. However, as datasets are incomplete, model capacity is finite, and learning algorithms non-optimal, achieving $\mathcal{J}(\mathcal{F}(\barbelow{h}(\barbelow{y}),\barbelow{\theta}^\ast),\barbelow{o}) = 0$, might not be possible. In fact, it may not even be desirable as it may lead to a phenomena known as overfitting, where the model does not generalize, i.e. performs poorly, on data not experienced during training \cite{bishop_pattern_2006}. Instead, what one typically wants in practice is to find a set of near-optimal parameters $\barbelow{\theta^\dagger}$ that achieve a low objective function value on the training set $\mathcal{D}_{train}$, but also on an unknown test dataset $\mathcal{D}_{test}$, where $\mathcal{D}_{test} \not\subset \mathcal{D}_{train}$, i.e. $\mathcal{D}_{test}$ is not a subset of $\mathcal{D}_{train}$, but still assumed to share the same underlying statistical distribution. Such a model is likely to generalize better, which ultimately enable the use of the model for practical applications, where the data is generally unknown. In fact, overfitting is the Achilles' heel of machine learning, and controlling the amount of overfitting and acquiring good generalization, is key to successfully applying machine learning based speech enhancement techniques in real-life applications. \paragraph{Machine Learning for Enhancement} \mbox{}\\ Machine learning has been applied to speech enhancement for several decades \cite{tamura_noise_1988,tamura_analysis_1989,tamura_improvements_1990,white_new_1990,kim_algorithm_2009,han_classification_2012,roux_ensemble_2013}, but until recently, not very successfully in terms of practical applicability. In one of the first machine learning based speech enhancement techniques \cite{tamura_noise_1988} the authors proposed to use an \ac{ANN} (\acp{ANN} are described in detail in Sec.\,\ref{deeplearn}) to learn a mapping directly from a frame of the noisy speech signal $\barbelow{y}_m$ to the corresponding clean speech frame $\barbelow{x}_m$ as \begin{equation} \hat{\barbelow{x}}_m = \mathcal{F}_{ANN}(\barbelow{y}_m,\barbelow{\theta}), \label{eq39} \end{equation} where $\mathcal{F}_{ANN}(\cdot,\cdot)$ represents an \ac{ANN}. Although the technique proposed in \cite{tamura_noise_1988} was trained on only 216 words and with a small network, according to today's standard, their proposed technique slightly outperformed a spectral subtractive-based speech enhancement technique in terms of speech quality, but not speech intelligibility. Furthermore, the \ac{ANN} generalized poorly to speech and noise signals not part of the training set. Finally, it took three weeks to train the \ac{ANN} on a, at the time, modern super computer, which simply made it practically impossible to conduct experimental research using larger \acp{ANN} with larger datasets. This might explain why little \ac{ANN} based speech enhancement literature exists from that time, compared to the previously discussed methods, such as Wiener filters or \ac{STSA}-\ac{MMSE} estimators, which, in general, require far less computational resources. Almost two decades later, promising results were reported in \cite{kim_algorithm_2009}, where large improvements (more than 60\%) in speech intelligibility was achieved using a speech enhancement technique based on \acp{GMM}. Specifically, they followed a gain-based approach (see Fig.\,\ref{fig:se}), and estimated a \ac{T-F} gain $\hat{g}(k,m)$ for each frequency bin $k$ and time-frame $m$. The frequency decomposition of the time-domain speech signal was performed using a Gammatone filter bank with 25 channels \cite{patterson_complex_1992} and the gain was defined as \begin{equation} \hat{g}^{IBM}(k,m) = \begin{cases} 1 & \text{if } \mathcal{P}(\pi_1|r(k,m)) > \mathcal{P}(\pi_0|r(k,m))\\ 0 & \text{otherwise}, \end{cases} \label{eq40} \end{equation} where $\mathcal{P}(\pi_0|r(k,m))$ and $\mathcal{P}(\pi_1|r(k,m))$ denote the probabilities of the clean speech magnitude $|x(k,m)|$ belonging to one out of two classes. The two classes $\pi_0$, and $\pi_1$, denoted noise-dominated T-F units and speech-dominated T-F units, respectively, and were defined as \begin{equation} r(k,m) \in \begin{cases} \pi_1 & \text{if } \frac{|x(k,m)|^2}{|v(k,m)|^2} > T_{SNR}(k)\\ \pi_0 & \text{otherwise}, \end{cases} \label{eq41} \end{equation} where $\frac{|x(k,m)|^2}{|v(k,m)|^2}$ is the \ac{SNR} in frequency bin $k$ and time frame $m$ and $T_{SNR}(k)$ is an appropriately set frequency-dependent threshold. The probabilities $\mathcal{P}(\pi_0|r(k,m))$ and $\mathcal{P}(\pi_1|r(k,m))$ were estimated using two classifiers, one for each class, based on 256-mixture \acp{GMM}% \footnote{Interestingly, in retrospect, they did attempt to use \acp{ANN}, but without good results.} trained on 390 spoken utterances ($\approx 16$ min of speech) with a feature representation based on \ac{AMS} \cite{tchorz_snr_2003}. In fact, the binary gain defined by Eq.\,\eqref{eq40} is an estimate of the \ac{IBM}, which is simply defined by Eqs.\,\eqref{eq40} and \eqref{eq41} when oracle information about $|x(k,m)|^2$ and $|v(k,m)|^2$ is used. Furthermore, it has been shown that the \ac{IBM} can significantly improve intelligibility of noisy speech, even at very low \acp{SNR} \cite{wang_ideal_2005,brungart_isolating_2006,kjems_role_2009}, which makes the \ac{IBM} a highly desirable training target as speech intelligibility is likely to be increased if the mask is accurately estimated. This approach, first proposed in \cite{kim_algorithm_2009}, was reported to not only outperform classical methods such as the Wiener filter and \ac{STSA}-\ac{MMSE} estimator, it even achieved improvements in speech intelligibility at a scale not previously observed in the speech enhancement literature. Later, supporting results appeared in \cite{han_classification_2012,wang_exploring_2013} where even better performance was achieved using a binary classifier based on \acp{SVM}. However, it was later discovered \cite{may_requirements_2014} that the great performance achieved by the systems proposed in \cite{kim_algorithm_2009,han_classification_2012} was primarily due to the reuse of the noise signal in both the training data and test data. This meant the systems in \cite{kim_algorithm_2009,han_classification_2012} were tested on realizations of the noise signal that were already used for training. In theory, it allowed the models to "memorize" the noise signal and simply subtract it from the noisy speech signal during test. This, obviously is not a possibility in real-life applications, where the exact noise signal-realization is generally not known in isolation. Regardless of the unrealistically good performance of the systems in \cite{kim_algorithm_2009,han_classification_2012} they, combined with the co-occurring Deep Learning revolution (described in detail in Sec.\;\ref{deeplearn}), reignited the interest in machine learning based speech enhancement. \subsection{Classical Speech Separation Algorithms}\label{classep} We now extend the formulation of the classical speech enhancement task (see Eq.\;\eqref{eq1}) to multi-talker speech separation. Let $x_s[n]$ be a sample of a clean time-domain speech signal from speaker $s$, and let an observation of a mixture $y[n]$ be defined as \begin{equation} y[n] = \sum_{s = 1}^{S} x_s[n], \label{eq42} \end{equation} where $S$ is the total number of speakers in the mixture. Then, the goal of single-microphone multi-talker speech separation is to acquire estimates $\hat{x}_s[n]$ of $x_s[n]$, $s=1,\,2,\,\dots,\,S$, which in some sense are "close to" $x_s[n]$, $s=1,\,2,\,\dots,\,S$ using $y[n]$ only. In Sec.\,\ref{sec:classical_se} we have seen a large number of techniques proposed to solve the single-microphone speech enhancement task, and to some extent, they are fairly successful in doing so in practice. However, they all, except for the machine learning based techniques, rely heavily on specific statistical assumptions about the speech and noise signals. Specifically, in practice, the Wiener filters and \ac{STSA}-\ac{MMSE} estimators rely on accurate estimates of the noise \ac{PSD}. Similarly, the subspace based techniques assume the noise signal is statistically white, or can be whitened, which in general requires additional information about the noise signal. Consequently, if the noise signal is a speech signal, which is non-stationary and colored, the methods described in Sec.\,\ref{sec:classical_se} perform poorly, as they rely on a signal model whose parameters are hard to estimate accurately. This, in turn, might also explain why these techniques have not been successfully applied on the single-microphone multi-talker speech separation task given by Eq.\;\eqref{eq42}, as different techniques might be required to successfully handle speech-like interference signals, when the target signals themselves are speech. In this section we introduce some of the classical techniques, i.e. non-deep learning-based methods, that have been proposed for single-microphone multi-talker speech separation. \subsubsection{Harmonic-Models} Some of the early techniques for single-microphone speech separation were in fact more related to speech enhancement, than speech separation, as they aimed mainly at suppressing an interfering speaker, in a two-speaker mixture, than actually separating the speech signals (see e.g. \cite{parsons_separation_1976,hanson_speech_1983,hanson_harmonic_1984,quatieri_approach_1990}). Furthermore, compared to the speech enhancement techniques existing at the time, e.g. Wiener filters or \ac{STSA}-\ac{MMSE} estimators, the techniques proposed for speech separation were more involved compared to the simple gain-based approach used by the corresponding speech enhancement techniques. Finally, although more complicated, they were generally less successful as good performance could only be achieved by using \emph{a priori} knowledge generally not available in practice, such as information about the fundamental frequency of the interfering speaker \cite{hanson_speech_1983,hanson_harmonic_1984,quatieri_approach_1990}. For example, the techniques proposed in \cite{parsons_separation_1976,hanson_speech_1983,hanson_harmonic_1984} used the fact that voiced speech signals can be modeled by a sum of sinusoids and that two competing speakers generally have different fundamental frequency and consequently different harmonics. If knowledge about the fundamental frequency of the interfering speaker is known, one can, in theory, null that frequency and corresponding harmonics and suppress the interfering speaker. However, such an approach requires multi-pitch tracking as the individual pitch signals must be estimated from the noisy signal only, and such an approach only works if the fundamental frequencies of the speakers involved are sufficiently separated. Finally, as unvoiced speech does not possess any apparent harmonic structure \cite{hansen_speech_1991}, these techniques were only partly successful and not a general approach for single-microphone multi-talker speech separation \cite{parsons_separation_1976,hanson_speech_1983,hanson_harmonic_1984}. \subsubsection{Computational Auditory Scene Analysis} A different approach to the single-microphone multi-talker speech separation task is one based on principles from \ac{ASA} \cite{bregman_auditory_1990}. According to the \ac{ASA} paradigm, the auditory system works by decomposing acoustic signals into abstract objects known as auditory streams. For each acoustic source signal that impinge upon the eardrum, e.g. speech or environmental sounds, an auditory stream is produced, which enables the conscious or subconscious mind to focus on every one of them in isolation. These auditory streams are thought to be produced in two steps \cite{bregman_auditory_1990}. First, a segmentation step decomposes the acoustic time-domain signal into individual units in a T-F domain representation, where it is assumed that each T-F unit primarily originates from a single source. Secondly, these T-F units are grouped into auditory streams based on grouping rules known as sequential grouping or simultaneous grouping. Sequential grouping assumes T-F units that are similar across time belong to the same source and consequently are grouped into the same auditory stream, whereas simultaneous grouping merge T-F units that share similarities across frequency, e.g. harmonicity or common onsets and offsets. Designing algorithms to separate speech signals based on the principles of \ac{ASA}, is referred to as \ac{CASA} \cite{brown_computational_1994,wang_computational_2006} and multiple techniques have been proposed to solve the single-microphone multi-talker speech separation task (see e.g. \cite{brown_computational_1994,hu_monaural_2004,bach_blind_2005,hu_auditory_2007,hu_tandem_2010,hu_unsupervised_2013,cooke_monaural_2010}). For example, in \cite{hu_monaural_2004} a \ac{CASA} system is proposed for co-channel separation of voiced speech using grouping rules based on cross-correlation analysis across cochlear channels (simultaneous grouping) and modulation analysis of cochlear-filter responses across time (temporal grouping). From these grouping rules, a binary mask is generated that is applied to the T-F representation of the mixture signal to separate the target speaker from the interference signal. In \cite{hu_unsupervised_2013} a system is proposed for co-channel speech separation of both voiced and unvoiced speech. Simultaneous grouping of the voiced parts of the co-channel signal is performed using an iterative pitch tracking algorithm that identifies the dominant fundamental frequency in the mixture. Sequential grouping is then formulated as a clustering problem that uses the information from the simultaneous grouping step and cluster T-F units across time that belong to the same speaker. Using information about the voiced segments of the co-channel signal the unvoiced parts of the mixture signal are identified using onset/offset analysis and a binary mask for the entire co-channel speech signal is computed and used to separate the speech signals. Although \ac{CASA} based single-microphone multi-talker speech separation algorithms can be somewhat successful, they suffer from several drawbacks. For example, \ac{CASA} is to a large extent based on heuristics and manually-designed grouping and segmentation rules, which might not be optimal. Furthermore, these rules are primarily based on speech characteristics and, consequently, are not valid for non-speech signals. Finally, these systems typically lack the capability to learn from data. \subsubsection{Non-Negative Matrix Factorization} An alternative to the primarily heuristically based \ac{CASA} approaches are the more mathematically founded \ac{NMF} based algorithms \cite{lee_learning_1999}. The underlying assumption behind these algorithms is that a non-negative data matrix $\barbelow{\barbelow{V}} \in \mathbb{R}^{K \times M}$ can be approximately factorized as \begin{equation} \barbelow{\barbelow{V}} \approx \barbelow{\barbelow{D}} \barbelow{\barbelow{H}}, \label{eq43} \end{equation} where $\barbelow{\barbelow{D}} \in \mathbb{R}^{K \times L}$, $\barbelow{\barbelow{H}} \in \mathbb{R}^{L \times M}$, and $L \ll M$ are non-negative matrices representing a dictionary matrix and an activation matrix, respectively. The dictionary matrix $\barbelow{\barbelow{D}}$ can be seen as a set of basis vectors for the data matrix $\barbelow{\barbelow{V}}$ and the columns of the activation matrix $\barbelow{\barbelow{H}}$ represent how much of each basis vector is needed to represent each column of $\barbelow{\barbelow{V}}$. The dimension $L$ is a tuning parameter that controls the accuracy of the approximation and is specified experimentally. Obviously, if $L=M$, the solution $\barbelow{\barbelow{V}} = \barbelow{\barbelow{D}} \barbelow{\barbelow{H}}$ can always be found, although such a decomposition is of no interest as no compact representation of $\barbelow{\barbelow{V}}$ is found. Factorizing $\barbelow{\barbelow{V}}$ into $\barbelow{\barbelow{D}}$ and $\barbelow{\barbelow{H}}$, where $L \ll M$, can be achieved in an iterative fashion \cite{lee_algorithms_2000} by updating \begin{equation} \barbelow{\barbelow{H}} =\barbelow{\barbelow{H}} \circ \frac{\barbelow{\barbelow{D}}^T\barbelow{\barbelow{V}}}{\barbelow{\barbelow{D}}^T\barbelow{\barbelow{D}}\barbelow{\barbelow{H}}}, \label{eq44} \end{equation} and \begin{equation} \barbelow{\barbelow{D}} = \barbelow{\barbelow{D}} \circ \frac{\barbelow{\barbelow{V}}\barbelow{\barbelow{H}}^T}{\barbelow{\barbelow{D}}\barbelow{\barbelow{H}}\barbelow{\barbelow{H}}^T }, \label{eq45} \end{equation} where $\circ$ and $-$ denote element-wise multiplication and division, respectively. In fact, Eqs.\;\eqref{eq44} and \eqref{eq45} represent the solution to the least squares optimization problem given by \begin{equation} \begin{aligned} & \underset{\barbelow{\barbelow{D}},\barbelow{\barbelow{H}}}{\text{minimize}} & & \Vert \barbelow{\barbelow{V}} - \barbelow{\barbelow{D}}\barbelow{\barbelow{H}} \Vert ^2_F \\ & \text{subject to} & & \barbelow{\barbelow{D}},\barbelow{\barbelow{H}} \geq 0, \end{aligned} \label{eq46} \end{equation} where $\lVert \cdot \lVert^2_F$ is the squared Frobenius norm, and by iterating between Eqs.\;\eqref{eq44} and \eqref{eq45}, convergence to the optimal solution of Eq.\;\eqref{eq46} is guaranteed \cite{lee_algorithms_2000}. \ac{NMF} is a data-driven technique and signal-dependent dictionaries $\barbelow{\barbelow{D}}$ are generally required \cite{lee_learning_1999}. In the speaker separation case, a dictionary $\barbelow{\barbelow{D}}_s$, $s=1,\,2,\,\dots,\,S$ is typically used for each speaker (see e.g. \cite{behnke_discovering_2003,schmidt_single-channel_2006,schmidt_nonnegative_2006,virtanen_monaural_2007,smaragdis_convolutive_2007}) and noise source if any is present \cite{thomsen_speaker-dependent_2016}. Let $r(k,m)$ and $a_s(k,m)$ denote \ac{STFT} magnitudes for time-frame $m$ and frequency bin $k$ for the noisy speech signal $y[n]$ and clean speech signal $x_s[n]$, from speaker $s$, respectively. Furthermore, let $\barbelow{\barbelow{R}} \in \mathbb{R}^{K \times M}$ and $\barbelow{\barbelow{A}}_s \in \mathbb{R}^{K \times M}$ denote spectrogram matrices populated with $r(k,m)$ and $a_s(k,m)$, for suitable ranges of variables $k$, $m$, respectively. From a matrix $\barbelow{\barbelow{A}}_s$, a speaker specific dictionary $\barbelow{\barbelow{D}}_s$, for speaker $s$, can be obtained using Eqs.\;\eqref{eq44} and \eqref{eq45} with $\barbelow{\barbelow{V}} = \barbelow{\barbelow{A}}_s$. To acquire an estimate $\barbelow{\barbelow{\hat{A}}}_s$ from a mixture signal $\barbelow{\barbelow{R}}$ containing unknown realizations of multiple speakers, and noise sources, Eq.\;\eqref{eq44} is used with Eq.\,\eqref{eq45} being fixed, and with $\barbelow{\barbelow{V}} = \barbelow{\barbelow{R}}$ and $\barbelow{\barbelow{D}} = \barbelow{\barbelow{D}}_s$. When Eq.\;\eqref{eq44} has converged, the corresponding activation matrix $\barbelow{\barbelow{H}}_s$ is used to acquire and estimate of $\barbelow{\barbelow{A}}_s$ as \begin{equation} \barbelow{\barbelow{\hat{A}}}_s = \barbelow{\barbelow{D}}_s \barbelow{\barbelow{H}}_s \;\;\ s=1,\,2,\,\dots,\,S. \label{eq47} \end{equation} Finally, using the phase of the mixture signal $\barbelow{\barbelow{R}}$, the overlap-add technique \cite{allen_short_1977}, and the \ac{IDFT}, the time-domain signals $\hat{x}_s[n]$, $s=1,\,2,\,\dots,\,S$, are obtained for each separated speaker. \ac{NMF} is a simple but powerful technique for single-microphone multi-talker speech separation, or speech enhancement for that matter \cite{schmidt_wind_2007,roux_sparse_2015,grais_single_2011}. However, \ac{NMF} has multiple drawbacks. First, \ac{NMF} is a linear model and as such is limited in its model capacity. Second, \ac{NMF} generally requires speaker dependent dictionaries, making \ac{NMF} less suitable for speaker, or noise-type independent applications. Third, as signal-dependent activations $\barbelow{\barbelow{H}}_s$ are required in Eq.\;\eqref{eq47}, it is not straight forward to apply \ac{NMF} for real-time applications where low latency is critical. Finally, due to the computational complexity of the update equations (Eqs.\;\eqref{eq44} and \eqref{eq45}), \ac{NMF} does not scale well to large datasets. \subsubsection{Generative Models}\label{genmodse} It is well known that speech signals are highly structured with temporal dynamics on multiple levels \cite{fant_acoustic_1960,deller_discrete-time_1993,schnupp_auditory_2011}. For example, at the phone level, i.e. the physical speech sounds, structure exist due to e.g. prosody or physiological variations among humans (e.g. differences in fundamental, and formant frequencies), but also at the phoneme level, speech is structured due to e.g. grammar and language, but also due to phenomena like co-articulation. The speech separation algorithms discussed so far, such as \ac{CASA} or harmonic-model based techniques, consider this temporal structure only partially, while \ac{NMF} based algorithms do not take it into account at all. These drawbacks, of existing methods not fully utilizing the available information in speech signals, has motivated research in a different class of algorithms based on \acp{HMM}. Differently from the previously discussed methods, \acp{HMM} are generative stochastic models, and they have an internal discrete state representation that allow them to learn temporal dynamics of sequential data \cite{bishop_pattern_2006}. Specifically, a \ac{HMM} is a finite state machine that changes among a discrete number of states in a synchronous manner. For each time step, the state of the \acp{HMM}, which is a latent variable, changes from one state to another based on a set of transition probabilities. Associated with each state is a set of observed stochastic variables, known as emission probabilities, which are typically represented as a \ac{GMM}. The parameters of a \ac{HMM}, i.e. transition and emission probabilities, are typically found such that they maximize a certain likelihood function with respect to a given dataset, and although a \ac{HMM} is a generative model, it is generally not used as such for speech processing tasks. For example, for \ac{ASR}, phoneme-specific \acp{HMM} can be designed to model the distribution over speech signals containing certain phonemes. Then, to recognize an unknown phoneme from a speech signal, the conditional probability of the observed data, given a \ac{HMM}, is evaluated for each of the phoneme-specific \acp{HMM} and the phoneme associated with the \ac{HMM} of largest conditional probability, will be assigned as the phoneme in the speech signal \cite{deller_discrete-time_1993}. If, however, more than one signal of interest is present in the speech signal, such as in the multi-talker speech separation task, the standard \ac{HMM} framework can be extended into what is known as factorial \acp{HMM} \cite{ghahramani_factorial_1997}. These factorial \ac{HMM} allow for more than one latent variable, hence allowing for generative models that can model speech mixtures containing multiple simultaneous sources, which ultimately led to the development of a large number of successful algorithms for single-microphone multi-talker speech separation \cite{roweis_one_2001,ozerov_factorial_2009,ephraim_statistical-model-based_1992,virtanen_speech_2006,hershey_audio-visual_2002,stark_source-filter-based_2011,mysore_non-negative_2010,kristjansson_super-human_2006,hershey_super-human_2010,cooke_monaural_2010,qian_past_2018}. In fact, the use of factorial \ac{HMM} led to a major milestone in speech separation research, as a single-microphone two-talker speech separation system was shown to be capable, in a narrow setting, to separate two-talker speech such that a machine, i.e. an \ac{ASR} system, could transcribe the speech signal better than humans \cite{kristjansson_super-human_2006,hershey_super-human_2010}. However, although factorial \acp{HMM} showed impressive results in \cite{kristjansson_super-human_2006,hershey_super-human_2010}, they do have some drawbacks. For example, computing the conditional probabilities required during training and test, is intractable \cite{mysore_non-negative_2010} and consequently these probabilities have to be estimated, which in general has a high computational complexity and scales poorly with the number of speakers \cite{qian_past_2018}. Also, as factorial \acp{HMM} for multi-talker speech separation require speaker-dependent \acp{HMM} for each speaker in the mixture, these techniques can only be applied in a speaker dependent context, where the identities of the speakers to be separated are known \emph{a priori}. This is a limitation that makes the factorial \ac{HMM} framework non-applicable in a range of real-world applications such as automatic meeting transcription or automatic captioning for audio/video recordings, where the identity and number of speakers are generally unknown. These limitations also explain why the techniques proposed in \cite{roweis_one_2001,ozerov_factorial_2009,ephraim_statistical-model-based_1992,virtanen_speech_2006,hershey_audio-visual_2002,stark_source-filter-based_2011,mysore_non-negative_2010,kristjansson_super-human_2006,hershey_super-human_2010,qian_past_2018} primarily considered two-talker speech separation of a limited number of \emph{known} speakers. Consequently, different techniques are required to enable multi-talker speech separation algorithms to work in such general applications, where only a limited amount of \emph{a priori} knowledge about the environment is available. Potential candidates that might work in such environments are algorithms based on deep neural networks, which will be presented in detail in Sec.\,\ref{deepsep}. \subsection{Evaluation} As mentioned in Sec.\,\ref{sec:classical_se}, the common goal of many speech enhancement, and multi-talker speech separation, algorithms is to improve either speech quality or intelligibility, of a degraded speech signal. But how do you accurately evaluate if an algorithm-under-test really does improve one of these quantities? In general, the only way to truly evaluate if a speech processing algorithm in fact does improve speech quality or intelligibility, is by a listening test involving the end user, i.e. human test subjects. However, listening tests are involved as they require numerous human test subjects and the listening test itself, needs to be carefully planned based on whether the goal is to evaluate speech intelligibility or speech quality. Most people probably have an idea about what a good quality speech signal sounds like, and what would make the same signal a bad quality one, e.g. by introducing hiss or crackle sounds to the signal. Nevertheless, speech quality is highly subjective as it is primarily based on emotions and feelings. Speech intelligibility, on the other hand, is much more objective, if you will, as emotions and feelings in general do not influence your capability of understanding speech. Either you understand what is being said or you do not. Consequently, designing listening tests that truly evaluate speech quality or intelligibility, is no easy task \cite{deller_discrete-time_1993,loizou_speech_2013}. Therefore, to avoid these often tedious and time consuming listening tests, and to get a quick and somewhat accurate estimate of the listening-test result, a set of objective measures have been designed, which are based on mathematical functions that quantify the difference between clean and noisy/processed speech signals in a way that has a high correlation with listening-test results. In fact, in some cases, it is more desirable to use an objective measure, instead of a listening test involving human test subjects, as objective measures are fast, cheap, and consistently produce the same result for the same testing condition, whereas listening-test results might vary due to factors such as listener fatigue, or varying hearing ability among test subjects. In the following, three of the popular techniques for objective quality and intelligibility evaluation are briefly reviewed. \subsubsection{Perceptual Evaluation of Speech Quality} The \ac{PESQ} \cite{rix_perceptual_2001,noauthor_international_1990,noauthor_international_2003,noauthor_international_2005} measure is one of the most widely used objective measures for estimating speech quality \cite{loizou_speech_2013}. The \ac{PESQ} measure is designed to approximate the \ac{MOS}, which is a widely used listening test procedure for speech quality evaluation \cite{loizou_speech_2013,deller_discrete-time_1993,noauthor_international_1990,ieee_ieee_1969}. The \ac{MOS} is a very simple evaluation procedure, where the test subjects are asked to grade the speech signal they are hearing based on a scale with five discrete steps, with "$1$" representing a bad and very annoying sound quality, and "$5$" representing an excellent sound quality with imperceptible distortions. The final \ac{MOS} score, which is a single scalar between "$1$" and "$5$", is simply the average, or mean, of all the "opinion scores" for each test signal and for all test subjects, hence the name, mean opinion score. As mentioned, the \ac{PESQ} measure approximates \ac{MOS}, but the \ac{PESQ} algorithm is fairly complex as it consists of multiple steps involving pre-processing, time alignment, perceptual filtering, masking effects, etc. (see e.g. \cite[pp. 491-503]{loizou_speech_2013}). Nevertheless, \ac{PESQ} versions P.862.1/2 \cite{noauthor_international_2003,noauthor_international_2005} produce a number ranging from approximately $1$ to $4.5$, which allow comparisons between \ac{PESQ} and \ac{MOS}, and \ac{PESQ} has been found to be highly correlated with listening-test experiments based on \ac{MOS} \cite{rix_perceptual_2001,noauthor_international_2003}. In fact, although \ac{PESQ} was originally designed for evaluating speech coding algorithms, it was later shown that \ac{PESQ} correlated reasonably well with the quality of speech processed by commonly used speech enhancement algorithms \cite{hu_evaluation_2008}. Also, \ac{PESQ} requires both the clean speech signal as well as the noisy/processed signal to estimate the perceived quality of the noisy/processed signal. This makes \ac{PESQ} an intrusive speech quality estimator, which limits its use to situations where the clean undistorted signal is available in isolation. For most applications of \ac{PESQ}, this is not a real limitation as \ac{PESQ} is usually used in laboratory conditions, where the clean signal is often available in isolation. \subsubsection{Short-Time Objective Intelligibility} The \ac{STOI} \cite{taal_short-time_2010,taal_algorithm_2011} is, today, perhaps, the most widely used objective measure for estimating speech intelligibility. Differently from \ac{PESQ}, \ac{STOI} is not designed to approximate any specific type of listening test, but merely designed to correlate well with listening tests evaluating speech intelligibility in general. Since intelligibility is binary in the sense that, either a given speech signal, say a word, is understood or it is not, listening-test results representing speech intelligibility can, most often, be quantified as a number between $0$ and $1$ that represents the percentage of words correctly understood \cite{loizou_speech_2013}. To be comparable with such tests, \ac{STOI} is designed to produce a single scalar output in a similar range% \footnote{In theory, \ac{STOI} can produce numbers in the interval $(-1,1)$, since \ac{STOI} is based on a correlation coefficient measure. However, in practice, negative numbers are rarely observed.}, with an output of $1$ indicating fully intelligible speech. Similarly to \ac{PESQ}, \ac{STOI} is an intrusive algorithm as it requires both the clean signal and the noise/processed signal in isolation. Furthermore, \ac{STOI} is based on the assumption that modulation frequencies play an important role in speech intelligibility, and that all frequency bands in the cochlear filter are equally important. These are assumptions, which, to a certain degree, are justified empirically \cite{elliott_modulation_2009,schnupp_auditory_2011,drullman_effect_1994}. This also has the consequence that, compared to \ac{PESQ}, \ac{STOI} is a fairly simple algorithm. Despite its simple formulation, \ac{STOI} has been found to be able to quite accurately predict the intelligibility of noisy/processed speech in a wide range of acoustic scenarios \cite{taal_algorithm_2011,jorgensen_speech_2015,falk_objective_2015,jensen_speech_2014,xia_evaluation_2012}. Finally, an extension to \ac{STOI}, known as \ac{ESTOI}, has been proposed as a more accurate speech intelligibility predictor in the special cases where the noise sources are highly modulated \cite{jensen_algorithm_2016}. \subsubsection{Blind Source Separation Evaluation}\label{secsdr} When evaluating single-target signal speech processing algorithms, such as speech enhancement, \ac{PESQ} and \ac{STOI} are useful, as these measures quantify how successful the algorithm-under-test process a degraded signal in a way that is perceptually desirable. If, however, multiple target signals exist, such as in a speech separation task, additional information about the processing artifacts might be desirable compared to what \ac{PESQ} and \ac{STOI} can provide \cite{vincent_first_2007,emiya_subjective_2011}. In other words, when a mixture signal that contains multiple speech and noise signals are processed by a speech separation algorithm, the enhanced or separated speakers might contain artifacts originating from multiple different sources. For example, these artifacts could originate from the noise signal itself, from processing artifacts, or due to "cross-talk", i.e. signal components from one target speaker appearing in the separated signal of the other. One of the most popular objective measures for evaluating speech separation algorithms that take these considerations into account, is the \ac{BSS} Eval toolkit \cite{vincent_performance_2006}. In the technique proposed in \cite{vincent_performance_2006}, the separated signals are decomposed into target-speaker components and three noise components known as interference, noise, and artifact. The interference component represents cross-talk from other target speakers. Noise and artifacts, represents environmental noise sources and processing artifacts, respectively. From this decomposition, energy-ratio measures are defined known as \ac{SDR}, \ac{SIR}, \ac{SAR}, and SNR, which each relate these decomposed elements of the separated signal in a way that provide useful information about the contribution of each of them. Finally, it has been found that these objective measures correlate well with listening test evaluating quality \cite{ward_bss_2018,cano_evaluation_2016}, and, obviously, the \ac{BSS} Eval toolkit only compliments other objective measures such as \ac{STOI} and \ac{PESQ}. \chapter*{Introduction}\label{sec:intro} \addcontentsline{toc}{chapter}{Introduction} \acresetall Most of us take it for granted and use it effortless on a daily basis; our ability to speak and hear. Nevertheless, the human speech production- and auditory systems are truly unique \cite{helmholtz_sensations_1954,fant_acoustic_1960,flanagan_speech_1972,schnupp_auditory_2011,moore_introduction_2013,fitch_evolution_2000,bitterman_ultra-fine_2008}. We are probably all familiar with the challenging situation at a dinner party when you attempt to converse with the person sitting across the table. Other persons, having their own conversations, are sitting around you, and you have to concentrate to hear the voice of the person you are trying to have a conversation with. Remarkably, the more you concentrate on the voice of your conversational partner, the more you understand and the less you feel distracted by the people talking loudly around you. This ability of selective auditory attention is one of the astonishing capabilities of the human auditory system. In fact, in 1953 it was proposed as an engineering discipline in the academic literature by Colin Cherry \cite{cherry_experiments_1953} when he asked: \\ \begin{adjustwidth}{10mm}{10mm} {\centering \emph{How do we recognize what one person is saying when others are speaking at the same time (the "cocktail party problem")? On what logical basis could one design a machine ("filter") for carrying out such an operation?}} \vspace{-3mm} \begin{flushright} \emph{ -- Colin Cherry, 1953.} \end{flushright} \end{adjustwidth} Ever since Colin Cherry coined the term \emph{cocktail party problem}, it has been, and still is, a very active topic of research within multiple scientific disciplines such as psychoacoustics, auditory neuroscience, electrical engineering, and computer science \cite{bregman_auditory_1990,bronkhorst_cocktail_2000,divenyi_speech_2005,wang_computational_2006,mcdermott_cocktail_2009,schnupp_auditory_2011,mesgarani_selective_2012,ziongolumbic_mechanisms_2013,bronkhorst_cocktail-party_2015,wang_supervised_2018}, and although Colin Cherry studied speech-interference signals in his seminal work in 1953, today, the cocktail party problem encompasses both speech and non-speech-interference signals \cite{haykin_cocktail_2005,wang_deep_2017}. In this PhD thesis, we study aspects of the cocktail party problem. Specifically, motivated by a re-emergence of a branch of machine learning, today, commonly known as \emph{deep learning} \cite{lecun_deep_2015}, we investigate how deep learning techniques can be used to address some of the challenges in two major sub-disciplines of the cocktail party problem: \emph{single-microphone speech enhancement} and \emph{single-microphone multi-talker speech separation}. \input{intro/speech} \input{intro/deeplearning} \input{intro/deepspeech} \input{intro/contributions} \input{intro/future} \pagebreak {\small\bibliographystyle{bib/IEEEtran} \chapter{#1}\label{#2} \chaptermark{} \vspace{2cm} \begin{center} \large #3 \end{center} \vspace{3cm} \begin{center} \normalsize #4 \end{center} \vspace*{\fill} \newpage\thispagestyle{empty} \vspace*{\fill} #5\par \noindent{\em The layout has been revised.} \vspace*{\fill} \cleardoublepage } \newenvironment{abstract}{\section*{Abstract}\it}{} \newcommand{\IEEEPARstart}[2]{#1#2} \newcommand{\defaultbib}{% \bibliographystyle{bib/IEEEtran} \chapter[Permutation Invariant Training of Deep Models for Speaker-\\Independent Multi-Talker Speech Separation]{Permutation Invariant Training of Deep Models for Speaker-Independent Multi-Talker Speech Separation}\label{paper:paperC} \chaptermark{} \vspace{2cm} \begin{center} \large Dong Yu, Morten Kolbæk, Zheng-Hua Tan, and Jesper Jensen \end{center} \vspace{3cm} \begin{center} \normalsize The paper has been published in\\ \textit{Proceedings IEEE International Conference on Acoustics, Speech, and Signal Processing}, pp. 241-245, 2017. \end{center} \vspace*{\fill} \newpage\thispagestyle{empty} \vspace*{\fill} \noindent\copyright\ 2017 IEEE\par \noindent{\em The layout has been revised.} \vspace*{\fill} \cleardoublepage \fi \acresetall \input{papers/paperC_body.tex} {\small\bibliographystyle{bib/IEEEtran} \section{Introduction} \label{sec:intro1} \IEEEPARstart{I}{mproving} quality and intelligibility of noisy speech signals is of great interest in a vast amount of applications such as mobile communications, speech recognition systems, and hearing aids. In a single-microphone setting, improving \ac{SQ} and especially \ac{SI} is a challenging task and is an active topic of research \cite{hendriks_dft-domain_2013,c._loizou_speech_2013,wang_supervised_2015}. Traditionally, single microphone Speech Enhancement\,(SE) has been addressed by statistical model based methods such as the Wiener filter \cite{c._loizou_speech_2013} and Short-Time Spectral Amplitude Minimum Mean Square Error\,(STSA-MMSE) estimators, e.g., \cite{ephraim_speech_1985,martin_speech_2005,erkelens_minimum_2007}. However, recent advances in Computational Auditory Scene Analysis\,(CASA) and machine learning have introduced new methods, e.g. Deep Neural Network\,(DNN), Gaussian Mixture Model\,(GMM), and Support Vector Machine\,(SVM) based methods, which address single-microphone SE and speech segregation in terms of advanced statistical estimators. These estimators aim at estimating either a clean speech \ac{T-F} representation directly or a T-F mask that is applied to the T-F representation of the noisy speech to arrive at an estimate of the clean speech signal \cite{wang_training_2014,healy_algorithm_2013,healy_algorithm_2015,kim_algorithm_2009,han_classification_2012,wang_towards_2013,chen_large-scale_2016,chen_noise_2016,han_towards_2013}. For some potential future applications, e.g. DNN based SE algorithms for hearing aids or mobile communications, the range of possible acoustic situations which can realistically occur is virtually endless. It is therefore important to understand how such methods perform in different acoustic situations, and how they perform, when they are exposed to "unseen" situations, i.e. acoustic scenarios not encountered during training. Despite the obvious importance of this generalizability question, it is currently not well understood. In this study we focus on situations where a single target speaker is present in additive noise and the aim of the SE algorithm is to enhance the speech signal and attenuate the noise using a single-microphone recording. Generally, when evaluating generalizability of machine learning based SE algorithms, there are at least three dimensions in which the input signal can vary: \RNum{1}) the noise type dimension, \RNum{2}) the speaker dimension and \RNum{3}) the Signal to Noise Ratio\,(SNR) dimension. Therefore, evaluation of DNN based SE methods should cover each of these dimensions in a way similar to what is expected to be experienced in a real life scenario. For mobile communication devices and hearing aid systems, evaluation should hence encompass a wide range of noise types, a wide range of speakers and a wide range of SNRs, in order to give a realistic estimate of the expected performance of the algorithm in real life scenarios. On the other hand, for applications where the typical usage situation is much more well-defined, e.g. voice-controlled devices to be used in a car cabin situation, training and testing might involve only car cabin noises at a narrow SNR range for a single particular speaker. The exploration of these three dimensions is motivated by the fact that no matter how many noise types, SNRs, and speakers a SE system is exposed to during training, in a real life scenario, sooner or later the system will be exposed to an unseen noise type, an unseen speaker or an unseen SNR. However, if the system is well trained, one might expect that the system has captured some general acoustic characteristics from these dimensions and hence generalizes well to unseen conditions. Furthermore, if any \emph{a priori} knowledge about the noise type, speaker characteristics or SNR is available, it is important to know what performance gain can be achieved by utilizing this \emph{a priori} knowledge. Several studies have investigated aspects of generalizability of SE algorithms based on DNNs, SVMs, and GMMs, e.g. \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016,healy_algorithm_2013,kim_algorithm_2009,han_classification_2012,han_towards_2013,gonzalez_mask-based_2014,chen_long_2016,delfarah_feature_2016,kumar_speech_2016}. However, these models are fundamentally different in both training schemes and architectures \cite{bishop_pattern_2006} and since DNNs are currently state-of-the-art in a large number of applications \cite{lecun_deep_2015} and have outperformed SVMs and GMMs in SE tasks \cite{healy_algorithm_2013,healy_algorithm_2015,wang_towards_2013,kim_algorithm_2009}, SVMs and GMMs are less suited for the current study and are therefore not considered. \pagebreak Common for all the studies, based on DNNs \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016}, is that during training or testing one or more of the generalizability dimensions defined above are held fixed, while others are varied. To the authors knowledge no study exists which explores the simultaneous variation of all the three dimensions - a situation which is realistic for many real life applications. Furthermore, interpretation of existing studies is sometimes complicated by the fact that the training and test signals, for the dimensions which \emph{are} varied, are not described in all details. For example, the distribution of males and females is often not reported \cite{xu_regression_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014} and it is hence not clear if the system is mostly a gender specific or gender general system. Several studies \cite{xu_regression_2015,huang_joint_2015,wang_training_2014} use the TIMIT corpus \cite{garofolo_darpa_1993}, which is approximately 70\% male and 30\% female. Furthermore, the duration of the different training noise types is typically not considered when the training data is constructed, hence the exact distribution of the noise types is unknown. For example, in \cite{healy_algorithm_2013,xu_regression_2015,huang_joint_2015,liu_experiments_2014} noise sequences with highly varying duration are used, which makes it unclear to which extent these systems are noise specific or noise general. Another issue related to the noise dimension is concerning the construction of training and test data. In several studies \cite{healy_algorithm_2013,huang_joint_2015,han_classification_2012,liu_experiments_2014,kim_algorithm_2009,wang_towards_2013} , the exact same noise realizations were used for training and testing. In \cite{may_requirements_2014} this training/testing paradigm was analyzed, and it was found to erroneously give remarkably better performance compared to the realistic scenario, where the actual noise sequence is unknown. Furthermore, the systems presented in \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016} are based on various network architectures, training methods, testing methods, speech corpora, noise databases, feature representations, target representations etc. As a consequence of these differences, their results cannot be directly related and it is therefore unclear how a state-of-the-art DNN based SE algorithm perform when the generalizability dimensions mentioned above are considered simultaneously. Finally, it is unclear to what extent state-of-the-art DNN based SE algorithms provide improvements over existing non-DNN based SE methods. In \cite{xu_regression_2015,wang_deep_2015-1,wang_training_2014} a DNN based SE method similar to the one studied here outperforms several different non-DNN based methods such as statistical MMSE based methods \cite{cohen_noise_2003,cohen_speech_2001,erkelens_minimum_2007,erkelens_estimation_2008,hendriks_comparison_2008} and non-Negative Matrix Factorization\,(NMF) methods \cite{wang_training_2014,lee_algorithms_2000}. However, since the DNNs used in \cite{xu_regression_2015,wang_deep_2015-1,wang_training_2014} have not been trained across all three generalizability dimensions, the comparison may not yield a true picture of the actual performance difference. This is particularly true with the statistical MMSE based methods \cite{c._loizou_speech_2013,hendriks_dft-domain_2013}, which have not been trained to handle any specific noise types or speakers but merely rely on basic statistical assumptions with respect to Short-Time Fourier Transform\,(STFT) coefficients and might perform worse than a system trained on a given speaker or noise type. The goal of this paper is therefore to conduct a systematic evaluation of the generalizability capabilities of a state-of-the-art DNN based SE algorithm in terms of estimated SQ and SI. Specifically, we investigate how a state-of-the-art DNN based SE method performs when it is trained to be noise type specific vs. noise type general, speaker specific vs. speaker general, and SNR specific vs. SNR general. Furthermore, we study the performance drop, if any, for systems which are specialized in one or more of the three generalizability dimensions, compared to a completely general DNN based SE system, which relies on essentially no prior knowledge with respect to speaker characteristics, noise type, and SNR. Additionally, it is investigated how this general system performs compared to a state-of-the-art non-machine learning based method namely the STSA-MMSE estimator employing generalized gamma priors as proposed in \cite{erkelens_minimum_2007,erkelens_estimation_2008,hendriks_comparison_2008}\footnote{http://insy.ewi.tudelft.nl/content/software-and-data}. This is of interest since the STSA-MMSE method relies on very little prior knowledge compared to conventional DNN based SE methods \cite{healy_algorithm_2013,healy_algorithm_2015,chen_large-scale_2016}. Furthermore, given that the computational and memory complexity associated with DNN type of systems is typically orders of magnitude larger than that associated with simple STSA-MMSE based systems it is of obvious interest to understand the performance gain of this technology. Finally, a listening test is conducted, using both specialized and general DNN based SE systems, to investigate if such systems improve SI, when tested in different matched and unmatched conditions. It is important to note that this paper emphasizes on the generalizability properties of DNN based SE algorithms in terms of estimated and measured SI, since these properties has not yet been rigorously investigated in the current literature \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016}. To do so, we rely on a specific implementation of a feed-forward DNN, whose architecture and training procedure resemble those of a large range of existing DNN based SE methods \cite{healy_algorithm_2015,wang_training_2014,xu_regression_2015,liu_experiments_2014,xu_experimental_2014}. This allows us to expect that our findings are representative not only for our particular implementation but are generally valid for DNN based SE methods. The fact that the DNN based SE method under study is a representative member of a larger class of algorithms also implies that this particular implementation does not necessarily outperform all existing methods with respect to estimated SQ and SI. Furthermore, obviously, the three chosen generalizability dimensions are not the only dimensions for which mixing scenarios can vary. Other such dimensions include reverberation conditions, e.g. in terms of varying room impulse responses, or digital signal processing conditions, e.g. in terms of signal sampling rate, number of bits with which each sample is represented, microphone characteristics, compression/coding schemes, etc. Furthermore, for DNN based SE algorithms the DNN architecture can also be varied and considered as a dimension. We have chosen the speaker dimension, the noise type dimension and the SNR dimension for this particular work since these are dimensions most often encountered in the SE literature \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016,healy_algorithm_2013,kim_algorithm_2009,han_classification_2012,han_towards_2013,gonzalez_mask-based_2014,chen_long_2016,delfarah_feature_2016,kumar_speech_2016}. Furthermore, in most papers related to DNN based SE algorithms only a single speaker is considered, so it is of interest to study how well these algorithms generalize to unknown speakers. Finally, the performance of non-machine learning based SE algorithms such as STSA-MMSE and Wiener filtering based approaches are known to be highly dependent on the noise type, and SNR, but not the speaker. Hence, it is of interest to study how a DNN based SE algorithm performs in a large range of noise types, speakers and SNRs. The paper is organized as follows: Section \ref{sec:se} describes the DNN architecture, training procedure and speech material used for conducting the desired experiments. Section \ref{sec:result} describes and discusses the experimental setups and results. Finally, in Section \ref{sec:conA} the findings are concluded. \section{Speech Enhancement Using Neural Networks} \label{sec:se} \subsection{Speech Corpus and Noisy Mixtures} The phonetically balanced Danish speech corpus \emph{\ac{ADFD}}\footnote{https://www.nb.no/sbfil/dok/nst\_taledat\_no.pdf} is used as target speech material for training and testing all DNN based SE systems considered in this paper. This corpus consists of two sets: One set (set 1) consisting of 56 speakers with 986 spoken utterances for each speaker and another set (set 2) with 560 speakers and 311 spoken utterances, and males and females are approximately equally distributed among the two sets. The majority of the text material is based on conversational speech, but also single words, numbers and sequences of numbers are included, and each utterance has an average duration of approximately 5 seconds. The training, validation, and test sets, were constructed such that no sentence appears more than once in the combined training, validation, and test set. The sampling frequency was 16 kHz and all files were normalized to have unit \ac{RMS} power. The noisy mixtures for all experiments were constructed by adding a noise signal to a clean speech signal at a certain SNR. The noise signal was scaled to achieve the desired SNR based on the speech active region of the speech signal, i.e. the silence parts in the beginning and in the end of the speech signal were omitted in SNR computation. Omitting the silence parts for the SNR computation is crucial since the inclusion of these parts will effectively decrease the energy estimate of the clean speech, hence a lower noise power is required to achieve the same SNR, than if the silence regions were omitted. The difference in SNR between these two approaches of constructing noisy mixtures can be more than one dB and is typically not considered in the literature \cite{healy_algorithm_2015,huang_joint_2015,xu_regression_2015}, even though it is of importance if results from different studies are to be related. Alternatively, a Voice Activity Detection\,(VAD) algorithm could have been used to exclude all silent regions, which would be highly beneficial for practical applications. However, for simplicity and to be in-line with existing literature \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016,healy_algorithm_2013,kim_algorithm_2009,han_classification_2012,han_towards_2013,gonzalez_mask-based_2014,chen_long_2016,delfarah_feature_2016,kumar_speech_2016}, we excluded the VAD for all experiments. As before, the global SNR based approach were chosen from a practical perspective and to be in-line with existing literature \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016,healy_algorithm_2013,kim_algorithm_2009,han_classification_2012,han_towards_2013,gonzalez_mask-based_2014,chen_long_2016,delfarah_feature_2016,kumar_speech_2016}, where global SNR is by far the most common. \subsection{Features and Labels} The choice of training targets for supervised speech enhancement have been widely studied \cite{wang_time-frequency_2008,jensen_spectral_2012,hummersone_ideal_2014,wang_training_2014,c._loizou_speech_2013,wang_ideal_2005,madhu_potential_2013,williamson_complex_2015}. Recent studies \cite{healy_algorithm_2015,madhu_potential_2013,wang_training_2014,hummersone_ideal_2014} suggest that continuous targets such as the Ideal Ratio Mask\,(IRM) are preferable over binary targets such as the Ideal Binary Mask\,(IBM) \cite{wang_ideal_2005,madhu_potential_2013}. Therefore, the DNN studied in this paper is trained in a supervised fashion to estimate the IRM from a feature representation of a noisy speech signal. The T-F representation used to construct the IRM is based on a gammatone filter bank with 64 filters linearly spaced on a MEL frequency scale from 50 Hz to 8 kHz and with a bandwidth equal to one \ac{ERB} \cite{wang_computational_2006}\footnote{http://web.cse.ohio-state.edu/pnl/shareware/cochleagram}. The output of the filter bank is divided into 20 ms frames with 10 ms overlap and with a sampling frequency of 16 kHz, each T-F unit represents a vector of 320 samples. Let $ \mathbf{x}(n, \omega) $ denote the Time-Frequency\,(T-F) unit of the clean speech signal at frame $n$ and frequency channel $\omega$, and let $ \mathbf{d}(n, \omega) $ denote the corresponding T-F unit of the noise signal. Then the IRM is computed as \cite{wang_training_2014} \begin{equation} \nonumber \text{IRM}(n, \omega)= \left(\frac{||\mathbf{x}(n, \omega)||^2}{||\mathbf{x}(n, \omega)||^2 + ||\mathbf{d}(n, \omega)||^2} \right)^\beta, \end{equation} where $ ||\mathbf{x}(n, \omega)||^2 $ is the squared 2-norm, i.e. the clean speech energy, of T-F unit $n$ in frequency channel $\omega$. Likewise, $||\mathbf{d}(n, \omega)||^2$ is the noise energy of a T-F unit $n$ in frequency channel $\omega$. The variable $\beta$ is a tunable parameter and has for all experiments in this paper been set to $\beta = 0.5$, which in \cite{wang_training_2014} was found empirically to provide good results. To have discriminative and noise robust features, each frame is transformed into a 1845-dimensional feature vector inspired by \cite{healy_speech-cue_2014,healy_algorithm_2013,healy_algorithm_2015,wang_towards_2013,chen_feature_2014,wang_supervised_2015,wang_exploring_2013}. Although, very recent works use only magnitude spectra \cite{chen_large-scale_2016,amodei_deep_2015,wang_deep_2015} a large context of several hundred milliseconds is used, which is undesirable for real time applications. The chosen feature vector was found to outperform features of magnitude spectra when these were based on only a small context. The features used are 31 \ac{MFCC}, 15 Amplitude Modulation Spectrogram\,(AMS), 13 \ac{RASTA-PLP} and 64 \ac{GFE}. Furthermore delta and double delta features are computed and a context of 2 past and 2 future frames are utilized, hence arriving at a 1845-dimensional feature vector. All feature vectors are normalized to zero mean and unit variance. \subsection{Network Architecture and Training} The DNNs used in this paper follow a feed-forward architecture with a 1845-dimensional input layer and three hidden layers, each with 1024 hidden units, and 64 output units \cite{healy_algorithm_2015,wang_training_2014}. The activation functions for the hidden units are \acp{ReLU} \cite{nair_rectified_2010} and for the output units the sigmoid function is applied. The hidden layers are initialized using the "GlorotUniform" approach \cite{glorot_understanding_2010}. Furthermore, the DNN has approximately 4 million tunable parameters in terms of weights and biases. The values of the parameters are found using \ac{SGD} following the AdaGrad approach \cite{duchi_adaptive_2011}. The gradients are computed using backpropagation based on the Mean Square Error\,(MSE) error function using a batch size of 1024 \cite{bishop_pattern_2006}. Furthermore, 20\% dropout has been applied to all hidden layers during training to reduce overfitting \cite{hinton_improving_2012}. In order to further reduce overfitting, an early-stopping training scheme is applied, which stops the training, when the MSE of the validation set has not decreased with more than 1\% for more than 20 epochs. Although used in \cite{healy_algorithm_2013,xu_regression_2015}, unsupervised DNN pre-training using Deep Belief Networks \cite{lecun_deep_2015,mohamed_acoustic_2012,bengio_greedy_2007} was found not to significantly improve performance and has therefore not been applied in the reported results. Finally, it is well known that increasing the network size or changing the network architecture can improve performance of DNN based algorithms \cite{xu_regression_2015,wang_deep_2015,halevy_unreasonable_2009,hannun_deep_2014,amodei_deep_2015,chen_large-scale_2016}. However, it is not practically feasible to include network architecture as a dimension in our experiments. Furthermore, although absolute performance might be better with a different architecture, the conclusions drawn from using a fixed-sized feed-forward DNN are expected to be valid for a broader range of DNN architectures, since the underlying assumptions are practically the same. \subsection{Signal Enhancement} After DNN training, the IRM is estimated for a given test signal by forward propagating its feature representation, for all frames, through the DNN. The output of the DNN represents the estimated IRM, $\widehat{\text{IRM}}(n, \omega)$ for the given frame. The estimated IRM can then be applied to the T-F representation of the noisy speech signal by multiplying the given entry of the mask to all 320 noisy signal samples of a T-F unit. All T-F units in each frequency channel are then concatenated and all overlapping parts are summed. Afterwards, the 64 frequency channels can be synthesized into a time domain signal by first compensating for the different group delays in the different channels and then adding the frequency channels. The group delay compensation is performed by time reversing the signals, passing them through the gammatone filter bank and then time reversing the signals once again \cite{wang_computational_2006}. \subsection{Evaluation of Enhancement Performance} Speech signals enhanced with the DNN based SE algorithm studied in this paper were evaluated using the Short-Time Objective Intelligibility\,(STOI) \cite{taal_algorithm_2011} measure and the wideband extension of the Perceptual Evaluation of Speech Quality\,(PESQ) measure \cite{rix_perceptual_2001,_p.862.2_2005}. The STOI measure estimates SI and PESQ estimates SQ and both have been found to be highly correlated with human listening tests \cite{taal_algorithm_2011,c._loizou_speech_2013}. STOI is defined in the range $[-1,1]$ and PESQ is defined in the range $[1,4.5]$ and for both measures higher is better. We used the implementations of STOI and PESQ available from \cite{taal_algorithm_2011} and \cite{c._loizou_speech_2013}, respectively. Although other performance measures exists such as Signal to Distortion Ratio\,(SDR), Signal to Interferences Ratio\,(SIR), and Signal to Artifact Ratio\,(SAR)\cite{c._loizou_speech_2013,fevotte_bss_2011} we report only PESQ and STOI to limit the number of tables. Furthermore, PESQ and STOI are by far the most used speech quality and speech intelligibility estimators in the literature \cite{chen_large-scale_2016,xu_regression_2015,lee_single_2015,huang_joint_2015,liu_experiments_2014,wang_training_2014,healy_algorithm_2015,wang_deep_2015,wang_towards_2013,chen_noise_2016,healy_algorithm_2013,kim_algorithm_2009,han_classification_2012,han_towards_2013,gonzalez_mask-based_2014,chen_long_2016,delfarah_feature_2016,kumar_speech_2016}. \section{Experimental Results and Discussion} \label{sec:result} To investigate the generalizability capability of DNN based SE systems with relation to: \RNum{1}) the noise type dimension, \RNum{2}) the speaker dimension and \RNum{3}) the SNR dimension, three experimental setups, one for each dimension, have been designed. When a dimension is explored the remaining two dimensions are held fixed. For example, when exploring the SNR dimension, the SNR dimension is varied but only a single speaker and a single noise type is used for both training and testing. Furthermore, a fourth setup has been constructed where a general system has been designed. This system was trained using a wide range of speakers, noise types and SNRs, hence the system relies on a minimum of \emph{a priori} knowledge. This "general" system is compared against the three experiments previously described, as well as a state-of-the-art non-machine learning based SE algorithm. \subsection{SNR Dimension}\label{sec:snrdim} The purpose of the SNR experiments is to investigate the impact on the performance of DNN based SE systems, when training is performed based on a single SNR vs. a wide range of SNRs, i.e. constructing a SNR specific or a SNR general system. The SNR dimension is explored using speech material based on 986 spoken utterances from a single female speaker from the ADFD set 1. These 986 utterances were divided such that 686 were used for training, 100 for validation and 200 for testing. Two noise types have been investigated, a stationary \ac{SSN} and a non-stationary Babble\,(BBL) noise. The SSN sequence is constructed by filtering a 50 min. Gaussian white noise sequence through a $12$th-order all-pole filter with coefficients found from Linear Predictive Coding\,(LPC) analysis of 100 randomly chosen TIMIT sentences \cite{garofolo_darpa_1993}. The BBL noise is also based on TIMIT. The corpus, which consists of a total of 6300 spoken sentences, is randomly divided into 6 groups of 1050 concatenated utterances. Each group is then truncated to equal length followed by addition of the six groups. This results in a BBL noise sequence with a duration of over 50 min. The SSN and BBL sequences were both divided such that 40 min. were used for training, 5 min. were used for validation and 5 min. for testing, hence there is no overlapping samples in the noise segments used for training, validation and test. To investigate how the performance of DNN based SE systems depends on the SNR dimension, eight systems were trained with eight different SNR settings for both SSN and BBL noise. All 16 systems were tested using eight SNRs ranging from -15 dB to 20 dB with steps of 5 dB. For each noise source, the first system was trained using -5 dB since this is a commonly encountered SNR in the literature \cite{healy_algorithm_2015,healy_algorithm_2013} where SI is typically degraded and DNN based SE algorithms have been successfully applied \cite{healy_algorithm_2015,healy_algorithm_2013}. The next system was trained using SNRs from -5 dB to 0 dB with steps of 1 dB. In a similar fashion wider and wider SNR ranges were used for training the remaining systems with the widest range being from -15 dB to 20 dB. The precise intervals are given in Tables \ref{table:snr_ssn_stoi}, \ref{table:snr_ssn_pesq}, \ref{table:snr_bbl_stoi} and \ref{table:snr_bbl_pesq}. For all systems, each training utterance was mixed with different noise realizations 35 times in order to increase the amount of training data. For each noisy mixture, the SNR was drawn from a discrete uniform distribution defined within the given SNR range. Due to the large number of realizations, it is assumed that the distribution of drawn SNRs is approximately uniform. The noise signal used for each noisy mixture was extracted from the whole training noise sequence by using a starting index drawn from a discrete uniform distribution defined over the entire length of the noise sequence. If the starting index is such that there is no room for the whole utterance, the remaining samples are extracted from the beginning of the noise sequence. Following the same procedure, each validation utterance is mixed with different noise realizations 10 times. Using this form of training data augmentation, the total amount of training utterances, used for training each system, is increased to $686 \times 35=24010$, which is approximately equal to 33 hours of speech material and is approximately $65\%$ more data than used by \cite{healy_algorithm_2015}. The results of the SNR dimension experiments are presented in Tables \ref{table:snr_ssn_stoi} and \ref{table:snr_ssn_pesq} for SSN and in Tables \ref{table:snr_bbl_stoi} and \ref{table:snr_bbl_pesq} for BBL noise. From Tables \ref{table:snr_ssn_stoi} and \ref{table:snr_bbl_stoi} it is seen that the SNR specific system of SNR of -5 dB achieves relatively large STOI improvements, for test signal SNRs in the range -10 dB to 5 dB. In general, it can be observed that inclusion of SNRs in the range from -15 dB to 5 dB has a larger positive impact on the performance than inclusion of SNRs above 5 dB. This might be explained partly by the fact that intelligibility is almost 100\% (STOI $\approx 1$) for test signal SNRs above 5 dB, and partly by the limited noise energy, which makes it more difficult for the DNN to actually learn important noise characteristics. Tables \ref{table:snr_ssn_pesq} and \ref{table:snr_bbl_pesq} show a somewhat similar picture. The inclusion of training signals with SNRs around 0 dB in general improves performance, but extending the training SNR range from 5 dB to 20 dB does not further improve performance. Furthermore, it is also seen that the system in general cannot improve PESQ for test signals with SNRs below -5 dB. Based on these experiments it can be concluded that there is generally a good correspondence between SNR ranges used in training and STOI improvement seen during testing. For example, the systems trained in the SNR range from -5 dB to 0 dB perform better at 0 dB than the systems trained using only -5 dB. Furthermore, even at -15 dB, where the noise energy is approximately 40 times larger than the speech energy, STOI is still improved with 0.074 and 0.093 for SSN and BBL noise, respectively, when this particular SNR is included in the training set, and the improvement is almost constant for SSN, and even slightly increasing for BBL noise, when a wider range of positive SNRs are included in the training set. Also, the system trained using the widest SNR range from -15 dB to 20 dB achieves almost similar performance as the -5 dB SNR specialized system, when tested at an SNR of -5 dB, and generally performs better at other SNRs. This observation is in line with related studies \cite{zhang_deep_2016} and is of large practical importance, as it suggests that DNN based SE systems should simply be trained using as large a training signal SNR range as practically possible. \begin{table*}[h!] \centering \caption{STOI improvement for the SNR dimension. Eight DNN based SE systems trained on different SNR ranges as indicated in the first row. The noise type dimension is held constant using SSN only and the speaker dimension is held constant using a single female speaker. The systems are evaluated using STOI for test signals with 8 different SNRs ranging from -15dB to 20dB. The second column presents the STOI score for the unprocessed noisy mixtures. Columns 3-10 present STOI improvements.} \label{table:snr_ssn_stoi} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccccc} \midrule \midrule \textbf{} & {Noisy} & {--5dB} & {--5dB -- 0dB} & {--5dB -- 5dB} & {--10dB -- 5dB} & {--15dB -- 5dB} & {--15dB -- 10dB} & {--15dB -- 15dB} & {--15dB -- 20dB} \\ \midrule \textbf{-15dB} & 0.354 & 0.016 & 0.019 & 0.028 & 0.063 & 0.074 & 0.075 & 0.075 & 0.072 \\ \textbf{-10dB} & 0.417 & 0.170 & 0.166 & 0.165 & 0.186 & 0.186 & 0.185 & 0.183 & 0.179 \\ \textbf{-5dB} & 0.519 & \textbf{0.219} & \textbf{0.218} & \textbf{0.218} & \textbf{0.219} & \textbf{0.216} & \textbf{0.215} & \textbf{0.213} & \textbf{0.210} \\ \textbf{0dB} & 0.642 & 0.180 & 0.186 & 0.187 & 0.185 & 0.183 & 0.183 & 0.182 & 0.181 \\ \textbf{5dB} & 0.756 & 0.115 & 0.125 & 0.130 & 0.128 & 0.126 & 0.128 & 0.127 & 0.127 \\ \textbf{10dB} & 0.844 & 0.058 & 0.070 & 0.078 & 0.077 & 0.076 & 0.079 & 0.079 & 0.078 \\ \textbf{15dB} & 0.905 & 0.016 & 0.030 & 0.040 & 0.039 & 0.039 & 0.044 & 0.045 & 0.044 \\ \textbf{20dB} & 0.944 & -0.010 & 0.005 & 0.015 & 0.014 & 0.014 & 0.020 & 0.023 & 0.023 \\ \midrule \midrule \end{tabular} } \end{table*} \begin{table*}[h!] \centering \caption{As Table \ref{table:snr_ssn_stoi} but for PESQ.} \label{table:snr_ssn_pesq} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccccc} \midrule \midrule \textbf{} & {Noisy} & {--5dB} & {--5dB -- 0dB} & {--5dB -- 5dB} & {--10dB -- 5dB} & {--15dB -- 5dB} & {--15dB -- 10dB} & {--15dB -- 15dB} & {--15dB -- 20dB} \\ \midrule \textbf{-15dB} & 1.133 & -0.044 & -0.041 & -0.044 & -0.036 & -0.027 & -0.029 & -0.035 & -0.032 \\ \textbf{-10dB} & 1.115 & 0.025 & 0.024 & 0.025 & 0.038 & 0.044 & 0.042 & 0.041 & 0.041 \\ \textbf{-5dB} & 1.115 & 0.198 & 0.190 & 0.192 & 0.202 & 0.196 & 0.196 & 0.191 & 0.187 \\ \textbf{0dB} & 1.144 & 0.457 & 0.425 & 0.421 & 0.410 & 0.400 & 0.410 & 0.408 & 0.405 \\ \textbf{5dB} & 1.234 & 0.700 & 0.691 & 0.655 & 0.643 & 0.638 & 0.630 & 0.636 & 0.642 \\ \textbf{10dB} & 1.438 & \textbf{0.769} & \textbf{0.875} & 0.879 & 0.863 & 0.859 & 0.831 & 0.803 & 0.811 \\ \textbf{15dB} & 1.811 & 0.583 & 0.830 & \textbf{0.942} & \textbf{0.925} & \textbf{0.911} & \textbf{0.948} & \textbf{0.902} & \textbf{0.878} \\ \textbf{20dB} & 2.346 & 0.130 & 0.518 & 0.764 & 0.745 & 0.733 & 0.860 & 0.877 & 0.848 \\ \midrule \midrule \end{tabular} } \end{table*} \begin{table*}[h!] \centering \caption{As Table \ref{table:snr_ssn_stoi} but for BBL.} \label{table:snr_bbl_stoi} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccccc} \midrule \midrule \textbf{} & {Noisy} & {--5dB} & {--5dB -- 0dB} & {--5dB -- 5dB} & {--10dB -- 5dB} & {--15dB -- 5dB} & {--15dB -- 10dB} & {--15dB -- 15dB} & {--15dB -- 20dB} \\ \midrule \textbf{-15dB} & 0.292 & 0.048 & 0.034 & 0.033 & 0.070 & 0.093 & 0.095 & 0.094 & 0.096 \\ \textbf{-10dB} & 0.369 & 0.161 & 0.150 & 0.146 & 0.170 & 0.173 & 0.173 & 0.174 & 0.174 \\ \textbf{-5dB} & 0.480 & \textbf{0.214} & \textbf{0.218} & \textbf{0.216} & \textbf{0.214} & \textbf{0.205} & \textbf{0.205} & \textbf{0.206} & \textbf{0.206} \\ \textbf{0dB} & 0.608 & 0.187 & 0.200 & 0.202 & 0.194 & 0.188 & 0.189 & 0.191 & 0.191 \\ \textbf{5dB} & 0.728 & 0.128 & 0.147 & 0.152 & 0.146 & 0.141 & 0.144 & 0.147 & 0.146 \\ \textbf{10dB} & 0.823 & 0.070 & 0.091 & 0.098 & 0.095 & 0.091 & 0.096 & 0.098 & 0.097 \\ \textbf{15dB} & 0.890 & 0.024 & 0.045 & 0.056 & 0.053 & 0.050 & 0.057 & 0.059 & 0.059 \\ \textbf{20dB} & 0.934 & -0.008 & 0.013 & 0.026 & 0.023 & 0.021 & 0.029 & 0.032 & 0.033 \\ \midrule \midrule \end{tabular} } \end{table*} \begin{table*}[h!] \centering \caption{As Table \ref{table:snr_ssn_stoi} but for PESQ and BBL.} \label{table:snr_bbl_pesq} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccccc} \midrule \midrule \textbf{} & {Noisy} & {--5dB} & {--5dB -- 0dB} & {--5dB -- 5dB} & {--10dB -- 5dB} & {--15dB -- 5dB} & {--15dB -- 10dB} & {--15dB -- 15dB} & {--15dB -- 20dB} \\ \midrule \textbf{-15dB} & 1.201 & -0.063 & -0.066 & -0.058 & -0.070 & -0.080 & -0.066 & -0.079 & -0.075 \\ \textbf{-10dB} & 1.180 & -0.047 & -0.060 & -0.058 & -0.056 & -0.052 & -0.055 & -0.055 & -0.054 \\ \textbf{-5dB} & 1.143 & 0.086 & 0.090 & 0.089 & 0.081 & 0.074 & 0.072 & 0.079 & 0.075 \\ \textbf{0dB} & 1.162 & 0.289 & 0.312 & 0.319 & 0.294 & 0.280 & 0.279 & 0.284 & 0.293 \\ \textbf{5dB} & 1.270 & 0.493 & 0.571 & 0.580 & 0.543 & 0.511 & 0.516 & 0.527 & 0.538 \\ \textbf{10dB} & 1.478 & \textbf{0.636} & 0.772 & 0.805 & 0.770 & 0.732 & 0.740 & 0.745 & 0.741 \\ \textbf{15dB} & 1.829 & 0.621 & \textbf{0.826} & \textbf{0.914} & \textbf{0.884} & \textbf{0.844} & \textbf{0.872} & \textbf{0.872} & \textbf{0.854} \\ \textbf{20dB} & 2.312 & 0.426 & 0.691 & 0.863 & 0.835 & 0.794 & 0.863 & 0.871 & 0.851 \\ \midrule \midrule \end{tabular} } \end{table*} \subsection{Noise Dimension}\label{sec:noiseDim} The purpose of the noise dimension experiments is to investigate the performance impact when DNN based SE systems are trained on a single noise type vs. a wide range of noise types. In other words, this allows us to compare a noise specific vs. a noise general system. The noise dimension has been explored using the same 986 spoken utterances from the same single female speaker as used in the SNR experiments. Likewise, the partition of the speech material into training, validation and test set is also identical to the SNR experiments. To explore the noise dimension, six distinct noise types were used: SSN\,(N1) and BBL\,(N2) from the SNR experiments and four additional noises: street\,(N3), pedestrian\,(N4), cafe\,(N5) and bus\,(N6), from the CHiME3 dataset \cite{barker_third_2015}. Furthermore, 1260 randomly selected sound effect noises from soundbible.com\footnote{http://soundbible.com/free-sound-effects-1.html} were used to construct a seventh noise type referred to as the \emph{mix}\,(N7) noise type. These 1260 noises were first truncated to have a maximum duration of 3 seconds each and then concatenated into one large noise sequence. The sound effects include sounds from animals, singing humans, explosions, airplanes, slamming doors etc. All seven (N1 -- N7) noise types used for the noise experiments were first truncated to have a total duration of 50 min. and then divided into a 40 min. training set, a 5 min. validation set and a 5 min. test set, hence there is no overlapping samples in the noise segments used for training, validation and test. To investigate how the performance of the DNN based SE system depends on the noise dimension, eight systems were trained with eight different noise combinations all at an SNR of -5 dB. Two systems were trained with only one noise type, namely the stationary SSN\,(N1) and non-stationary BBL\,(N2). The remaining six systems were trained with an increasing number of noise types starting with N1 -- N2 and ending with N1 -- N7 as indicated in the second row in Tables \ref{table:ntstoi} and \ref{table:ntpesq}. When noise types were combined, the 40 min. noise sequences were concatenated and similar to the SNR experiment, a noise sequence was extracted based on a randomly chosen starting index within this concatenated noise sequence. Similarly to the SNR experiment, each utterance in the training set was mixed with a randomly chosen noise sequence 35 times, hence a total of $686 \times 35=24010$ noise mixtures were constructed. The large number of mixtures and the identical duration of the noise sequences ensures that the noise distribution within the training data is approximately uniform, hence a noise-general system is constructed. All eight systems have been tested with speech signals contaminated by all seven noise types, which ensures that all but the system trained with all seven noises will be tested with at least one unseen and at the most 6 unseen noise types. The results are presented in Tables \ref{table:ntstoi} and \ref{table:ntpesq} where the first column represents the noise types used for testing and the second row represents the noises used for training. Table \ref{table:ntstoi} shows that when a system is trained using SSN only (N1) it achieves a relatively large STOI improvement of 0.22, when tested on that particular noise type, but generalizes poorly on the majority of the unseen test noises. Similarly, when a system is trained on BBL (N2), the performance is good in the matched noise case, but the system generalizes poorly to other noise types. Furthermore, when both SSN and BBL noise types are included equally in the training set (N1-N2), the system performs almost as good as the individual noise specific systems. However, the system does not generalize as well to the unseen noises as N1 did alone, except for the \emph{mix} noise type, that similarly to BBL is highly non-stationary. It is also interesting to notice that the SSN and BBL specific systems achieve very similar performance for test signals contaminated by SSN and BBL, respectively. This is in contrast to STFT-based methods for which non-stationary noise is much more challenging \cite{hendriks_dft-domain_2013}. A different picture is seen when a third noise (N3) is added in the training set (N1-N3). This system performs similarly well in the matched noise type setting, but also for the unseen noises the performance has increased considerably. Similar behavior is seen when the remaining noise types are included in the training set. Furthermore, even though new noise types are included in the training set, the performance of the system is almost constant in the matched noise type setting. One can argue that \emph{str}, \emph{ped}, \emph{caf} and \emph{bus} are quite similar noise types, but it is seen that the system trained with signals contaminated by all but the mix noise type (N1-N6) generalizes relatively well to the mix noise type, which is a noise type radically different from the others. From Table \ref{table:ntpesq} a similar behavior is observed where relatively large PESQ scores are achieved for all testing noises, already after noise type N1 -- N3 have been included in the training set. Similar for both Tables \ref{table:ntstoi} and \ref{table:ntpesq} is that there is generally a good correspondence between noise types used for training and STOI and PESQ improvements seen during testing. For example, the systems performing best on SSN and BBL noise are the systems that have been trained on only these noise types. However, a system trained on both noise types show only a slightly decrease in performance. Furthermore, the noise general system (N1 -- N7), where all seven noise types are used for training, achieves on average the best performance across all seven noise types, while still being comparable in performance to the more specialized systems where only a single or a few noise types have been used for training. This is similar to the SNR experiments where no particular degradation in performance was observed by extending the SNR range used for training. \begin{table*}[h!] \centering \caption{STOI improvement for the noise type dimension. Eight DNN based SE systems have been trained with different combinations of seven different noise types (N1-N7) as given by the first row. The SNR dimension is held constant at -5dB and the speaker dimension is held constant using a single female speaker. The systems have been evaluated using STOI and test signals corrupted by all seven noise types. The second column presents the STOI score for the noisy unprocessed mixtures. Columns 3-10 present STOI improvements.} \label{table:ntstoi} \resizebox{0.85\textwidth}{!}{% \begin{tabular}{lccccccccc} \midrule \midrule \textbf{} & {Noisy} & {N1} & {N2} & {N1--N2} & {N1-N3} & {N1--N4} & {N1--N5} & {N1--N6} & {N1--N7}\\ \midrule \textbf{N1: ssn} & 0.519 & \textbf{0.220} & 0.083 & 0.207 & 0.209 & \textbf{0.208} & \textbf{0.206} & \textbf{0.206} & \textbf{0.203} \\ \textbf{N2: bbl} & 0.482 & 0.029 & \textbf{0.217} & \textbf{0.210} & \textbf{0.211} & 0.204 & 0.202 & 0.203 & 0.199 \\ \textbf{N3: str} & 0.590 & 0.122 & -0.079 & 0.080 & 0.174 & 0.172 & 0.172 & 0.173 & 0.171 \\ \textbf{N4: ped} & 0.504 & 0.095 & -0.008 & 0.078 & 0.139 & 0.157 & 0.161 & 0.160 & 0.158 \\ \textbf{N5: caf} & 0.572 & 0.072 & -0.007 & 0.065 & 0.143 & 0.155 & 0.165 & 0.167 & 0.165 \\ \textbf{N6: bus} & 0.703 & 0.071 & -0.058 & 0.003 & 0.112 & 0.114 & 0.118 & 0.130 & 0.128 \\ \textbf{N7: mix} & 0.685 & 0.015 & 0.028 & 0.038 & 0.072 & 0.078 & 0.092 & 0.093 & 0.119 \\ \midrule \midrule \end{tabular} } \end{table*} \begin{table*}[h!] \centering \caption{As Table \ref{table:ntstoi} but for PESQ.} \label{table:ntpesq} \resizebox{0.85\textwidth}{!}{% \begin{tabular}{lccccccccc} \midrule \midrule \textbf{} & {Noisy} & {N1} & {N2} & {N1--N2} & {N1-N3} & {N1--N4} & {N1--N5} & {N1--N6} & {N1--N7}\\ \midrule \textbf{N1: ssn} & 1.112 & \textbf{0.197} & -0.012 & \textbf{0.175} & 0.186 & 0.174 & 0.175 & 0.178 & 0.173 \\ \textbf{N2: bbl} & 1.174 & -0.072 & 0.060 & 0.048 & 0.054 & 0.047 & 0.039 & 0.046 & 0.032 \\ \textbf{N3: str} & 1.069 & 0.114 & -0.002 & 0.071 & 0.302 & 0.294 & 0.294 & 0.294 & 0.298 \\ \textbf{N4: ped} & 1.099 & 0.033 & -0.025 & 0.005 & 0.095 & 0.118 & 0.125 & 0.125 & 0.120 \\ \textbf{N5: caf} & 1.081 & 0.030 & -0.003 & 0.025 & 0.191 & 0.224 & 0.237 & 0.247 & 0.242 \\ \textbf{N6: bus} & 1.083 & 0.125 & 0.010 & 0.036 & \textbf{0.329} & \textbf{0.336} & \textbf{0.351} & \textbf{0.421} & \textbf{0.415} \\ \textbf{N7: mix} & 1.143 & 0.002 & \textbf{0.067} & 0.059 & 0.126 & 0.144 & 0.161 & 0.180 & 0.293 \\ \midrule \midrule \end{tabular} } \end{table*} \subsection{Speaker Dimension}\label{sec:sprkTest} The purpose of the speaker dimension experiments is to study the impact of using a single speaker vs. a wide range of speakers in the training material, i.e. constructing a speaker specific or speaker general system. The speaker dimension is explored using speech material based on 311 spoken utterances from 41 male and 41 female speakers from the ADFD set 2. The utterances from the 41 females are referenced as F-ID1 -- F-ID41 and similarly, the utterances from the 41 males are referenced as M-ID1 -- M-ID41. For each of the speakers of interest, (F/M-ID1 -- F/M-ID21) 231 utterances were used for training, 30 for validation and 50 for testing. Furthermore, 50 utterances from each of the 40 remaining speakers (F/M-ID22 -- F/M-ID41) were used as testing material for unseen speaker testing. The text material used for the 50 test utterances from each speaker was the same for all 82 speakers used for these experiments. A total of 10 systems were trained. Five systems using speech material corrupted with SSN at an SNR of $-5$ dB and five systems with speech material corrupted with BBL noise at an SNR of $-5$ dB. For each noise type, speakers F-ID1 and MID-1 were used to train two individual speaker specific systems. Furthermore, speakers F-ID2 -- 21 and M-ID2 -- 21 were used to train two individual gender specific systems and finally the speakers F-ID2 -- 21 and M-ID2 -- 21 were combined (F/M-ID2 -- 21) and used to train a single speaker general system. All systems were evaluated in both a seen speaker and an unseen speaker scenario using the test material from speaker F/M-ID1 -- F/M-ID21 and F/M-ID22 -- F/M-ID41, respectively. However, the systems trained using only one speaker is tested using 20 speakers, instead of only one speaker, to give more realistic unseen-speaker results. Since the number of distinct utterances used for training vary between the different systems, due to the varying number of speakers, a fixed total number of 18480 training utterances were used for training all systems. This is done to ensure that all systems are presented to the same amount of noise material. Using the same argument a total number of 1200 utterances were used for validation during the training of all systems. To achieve 18480 training mixtures, and 1200 validation mixtures, for each system, each distinct utterance was mixed with unique noise realizations multiple times as given by Table \ref{tab:dataAugment}. \begin{table}[h!] \centering \caption{Training and validation data augmentation scheme used for results reported in subsection \ref{sec:sprkTest} to ensure all systems use the same amount of data. The format is the following: $\#speakers \times \#utterances \times \#repetitions = \#mixtures$} \label{tab:dataAugment} \resizebox{0.7\textwidth}{!}{% \begin{tabular}{lcc} \midrule \midrule \multicolumn{1}{c}{{System}} & {\#Training Utterances} & {\#Validation Utterances} \\ \midrule Speaker Specific & $1 \times 231 \times 80 = 18480$ & $ 1 \times 30 \times 40 = 1200$ \\ Gender Specific & $20 \times 231 \times 4 = 18480$ & $20 \times 30 \times 2 = 1200$ \\ Speaker General & $40 \times 231 \times 2 = 18480$ & $40 \times 30 \times 1 = 1200$ \\ \midrule \midrule \end{tabular} } \end{table} The results with SSN are presented in Tables \ref{table:sprk_ssn_stoi} and \ref{table:sprk_ssn_pesq}, and the results with BBL noise are presented in Tables \ref{table:sprk_bbl_stoi} and \ref{table:sprk_bbl_pesq}. The first column presents the speaker IDs used for testing and the second row represents speaker IDs used for training. From Table \ref{table:sprk_ssn_stoi} it is seen that speaker specific systems trained on a single speaker achieves a STOI improvement of $0.168$ and $0.204$ for same-gender-same-speaker testing, for the female (F-ID1) and male (M-ID1) specific systems, respectively. However, if these systems are tested with new speakers of same gender, i.e. same-gender-new-speaker testing, the STOI improvements are reduced to $0.127$ and $0.114$ for the female (F-ID1) and male (M-ID1) specific systems, respectively. Furthermore, if the systems are tested on opposite gender the STOI improvement decreases to $0.067$ and $0.062$ for the female (F-ID1) and male (M-ID1) specific systems, respectively. Similar behavior, but with larger variations, is seen from Table \ref{table:sprk_bbl_stoi} where the systems have been trained using utterances corrupted with BBL noise instead of SSN. Table \ref{table:sprk_bbl_stoi} shows that systems trained using F-ID1 and M-ID2 improve STOI with $0.131$ and $0.184$ for same-gender-same-speaker testing, for the female (F-ID1) and male (M-ID1) systems, respectively. However, these improvements reduce to $0.046$ and $0.039$ for same-gender-new-speakers testing, and to $-0.093$ and $-0.107$ for new-gender testing, for the female (F-ID1) and male (M-ID1) systems, respectively. From these results it can be concluded that systems which are trained using only a single speaker generalizes very well to unseen utterances from the same speaker but not as good to unseen utterances from new speakers of same gender and even worse to opposite gender. Especially for BBL noise, the systems even degrade the signals when evaluated using opposite gender. If gender specific systems are trained with 20 speakers instead of only a single speaker it is seen from Table \ref{table:sprk_ssn_stoi} that the STOI improvements in the same-gender-same-speakers testing case are $0.175$ and $0.174$ for the female (F-ID2 -- F-ID21) and male (M-ID2 -- M-ID21) systems, respectively. Furthermore, the STOI improvements in the same-gender-new-speakers testing case are $0.170$ and $0.160$ for the female (F-ID2 -- F-ID21) and male (M-ID2 -- M-ID21) systems, respectively. Compared to the systems trained using a single speaker, the systems trained using 20 speakers of same gender generalize considerably better to the same-gender-new-speaker testing case. Also in the new-gender testing case Table \ref{table:sprk_ssn_stoi} shows STOI improvements of $0.124$ and $0.119$ for the female (F-ID2 -- F-ID21) and male (M-ID2 -- M-ID21) systems, respectively. However, Table \ref{table:sprk_bbl_stoi} shows that STOI is degraded when the female (F-ID2 -- F-ID21) and male (M-ID2 -- M-ID21) systems are tested in the new-gender testing case. Finally, if a speaker general system is trained using both males and females (F/M-ID2 -- 21) and is tested in an unseen speaker setting based on both genders (F/M-ID22 -- 41) using respectively SSN and BBL noise, the STOI improvements are $0.164$ and $0.111$, respectively. This shows that the speaker general system in terms of STOI generalizes considerably better than the speaker specific and gender specific systems to unseen speakers of both genders, for both a stationary and non-stationary noise type. Importantly, it is seen that the loss from a gender specific system to a gender general system is almost zero. One interesting observation is the decrease in performance, when compared to the experiments exploring the noise type dimension in subsection \ref{sec:noiseDim}. For example, Table \ref{table:ntstoi} shows that a system specialized to a single female speaker using BBL noise at an SNR of -5 dB achieves a STOI improvement of $0.217$. Table \ref{table:sprk_bbl_stoi} shows that a similar system (F-ID1) trained with a different female speaker using BBL noise at an SNR of -5 dB achieves a STOI improvement of $0.131$, which is a considerable difference. There is one major difference between these two systems. For the experiments used to produce Table \ref{table:ntstoi}, the speaker was represented by 686 distinct spoken utterances, whereas for the experiments used to produce Table \ref{table:sprk_bbl_stoi} only 231 distinct spoken utterances were used. This indicates that not only the number of speakers but also the variability in speech material from each speaker is crucial to achieve good generalizability. In general, it can be observed that a DNN based SE system trained using a single speaker becomes speaker specific and performs well, in terms of estimated SI, when evaluated using the same speaker. If a large number of speakers, of the same gender, are used for training, the system becomes gender specific and generalizes well to unseen speakers of same gender. Furthermore, if a large number of male and female speakers are used for training, the system becomes speaker general and generalizes well to unseen speakers of both genders. This applies for systems trained using training signals corrupted with either SSN or BBL noise. In terms of estimated SQ a similar behavior can only be observed for systems trained with training signals corrupted with SSN whereas for the systems trained using training signals corrupted with BBL noise no, or only minor, improvements were found as shown by Tables \ref{table:sprk_ssn_pesq} and \ref{table:sprk_bbl_pesq}. \begin{table*}[h!] \centering \caption{STOI improvement for the speaker dimension. Five DNN based SE systems have been trained on a varying number of speakers of both genders as given by the first row. The systems have been tested in both speaker matched and unmatched conditions. The noise type dimension is held constant using SSN for training and testing and the SNR dimension is held constant using an SNR of -5dB for training and testing. The systems have been evaluated using STOI. The second column presents the STOI score for the noisy unprocessed mixtures. Columns 3-7 present STOI improvements} \vspace{-2 mm} \label{table:sprk_ssn_stoi} \resizebox{0.8\textwidth}{!}{% \begin{tabular}{lcccccccc} \midrule \midrule {Test $\backslash$ Train} &{Noisy} &{F-ID1} & {M-ID1} & {F-ID2 -- 21} & {M-ID2 -- 21} & {F/M-ID2 -- 21} \\ \textbf{F-ID1} & 0.564 & \textbf{0.168} & -- & -- & -- & -- \\ \textbf{M-ID1} & 0.460 & -- & \textbf{0.204} & -- & -- & -- \\ \textbf{F-ID2-21} & 0.532 & -- & -- & \textbf{0.175} & -- & \textbf{0.170} \\ \textbf{F-ID22-41} & 0.530 & 0.127 & 0.062 & 0.170 & 0.119 & 0.166 \\ \textbf{M-ID2-21} & 0.543 & -- & -- & -- & \textbf{0.174} & 0.167 \\ \textbf{M-ID22-41} & 0.538 & 0.067 & 0.114 & 0.124 & 0.160 & 0.163 \\ \textbf{F/M-ID2--21} & 0.538 & -- & -- & -- & -- & 0.167 \\ \textbf{F/M-ID22--41} & 0.535 & 0.097 & 0.089 & 0.147 & 0.140 & 0.164 \\ \midrule \midrule \end{tabular} } \end{table*} \vspace{4 mm} \begin{table*}[h!] \centering \caption{As Table \ref{table:sprk_ssn_stoi} but for PESQ} \vspace{-2 mm} \label{table:sprk_ssn_pesq} \resizebox{0.8\textwidth}{!}{% \begin{tabular}{lcccccccc} \midrule \midrule \textbf{Test $\backslash$ Train} &{Noisy} &{F-ID1} & {M-ID1} & {F-ID2 -- 21} & {M-ID2 -- 21} & {F/M-ID2 -- 21} \\ \midrule \textbf{F-ID1} & 1.062 & \textbf{0.160} & -- & -- & -- & -- \\ \textbf{M-ID1} & 1.078 & -- & \textbf{0.185} & -- & -- & -- \\ \textbf{F-ID2-21} & 1.068 & -- & -- & \textbf{0.168} & -- & 0.158 \\ \textbf{F-ID22-41} & 1.065 & 0.108 & 0.043 & 0.160 & 0.058 & 0.150 \\ \textbf{M-ID2-21} & 1.110 & -- & -- & -- & \textbf{0.219} & 0.208 \\ \textbf{M-ID22-41} & 1.118 & 0.070 & 0.149 & 0.141 & 0.199 & \textbf{0.213} \\ \textbf{F/M-ID2--21} & 1.096 & -- & -- & -- & -- & 0.175 \\ \textbf{F/M-ID22--41} & 1.093 & 0.087 & 0.095 & 0.149 & 0.126 & 0.180 \\ \midrule \midrule \end{tabular} } \end{table*} \vspace{4 mm} \begin{table*}[h!] \centering \caption{As Table \ref{table:sprk_ssn_stoi} but for BBL} \vspace{-2 mm} \label{table:sprk_bbl_stoi} \resizebox{0.8\textwidth}{!}{% \begin{tabular}{lcccccccc} \midrule \midrule {Test $\backslash$ Train} &{Noisy} &{F-ID1} & {M-ID1} & {F-ID2 -- 21} & {M-ID2 -- 21} & {F/M-ID2 -- 21} \\ \midrule \textbf{F-ID1} & 0.535 & \textbf{0.131} & -- & -- & -- & -- \\ \textbf{M-ID1} & 0.433 & -- & \textbf{0.184} & -- & -- & -- \\ \textbf{F-ID2-21} & 0.498 & -- & -- & \textbf{0.121} & -- & 0.110 \\ \textbf{F-ID22-41} & 0.496 & 0.046 & -0.107 & 0.117 & -0.059 & 0.108 \\ \textbf{M-ID2-21} & 0.511 & -- & -- & -- & \textbf{0.140} & 0.112 \\ \textbf{M-ID22-41} & 0.507 & -0.093 & 0.039 & -0.007 & 0.125 & \textbf{0.115} \\ \textbf{F/M-ID2--21} & 0.505 & -- & -- & -- & -- & 0.110 \\ \textbf{F/M-ID22--41} & 0.501 & -0.025 & -0.034 & 0.054 & 0.032 & 0.111 \\ \midrule \midrule \end{tabular} } \end{table*} \begin{table*}[h!] \centering \caption{As Table \ref{table:sprk_ssn_stoi} but for PESQ and BBL} \vspace{-2 mm} \label{table:sprk_bbl_pesq} \resizebox{0.8\textwidth}{!}{% \begin{tabular}{lcccccccc} \midrule \midrule {Test $\backslash$ Train} &{Noisy} &{F-ID1} & {M-ID1} & {F-ID2 -- 21} & {M-ID2 -- 21} & {F/M-ID2 -- 21} \\ \midrule \textbf{F-ID1} & 1.094 & \textbf{0.065} & -- & -- & -- & -- \\ \textbf{M-ID1} & 1.159 & -- & \textbf{0.029} & -- & -- & -- \\ \textbf{F-ID2-21} & 1.129 & -- & -- & \textbf{0.001} & -- & -0.007 \\ \textbf{F-ID22-41} & 1.130 & -0.029 & -0.049 & -0.007 & -0.064 & -0.017 \\ \textbf{M-ID2-21} & 1.168 & -- & -- & -- & \textbf{0.024} & -0.005 \\ \textbf{M-ID22-41} & 1.181 & -0.074 & -0.040 & -0.077 & 0.002 & -0.007 \\ \textbf{F/M-ID2--21} & 1.141 & -- & -- & -- & -- & \textbf{0.001} \\ \textbf{F/M-ID22--41} & 1.164 & -0.059 & -0.051 & -0.050 & -0.037 & -0.019 \\ \midrule \midrule \end{tabular} } \end{table*} \subsection{Combined Dimensions}\label{comDim} The purpose of the combined dimension experiments is twofold. First, we wish to determine the performance decrease, if any, of a general DNN based SE system vs. the specialized systems considered in the three previous subsections, where only one dimension was varied at a time. Such experiments can be used to relate results previously reported in the literature, where at least one dimension has been fixed, to the more general case where all three dimensions are varied. Secondly, we wish to investigate how such a general DNN based SE method performs relative to a state-of-the-art non-machine learning based method, namely the STSA-MMSE method proposed in \cite{erkelens_minimum_2007}. This is done in an attempt to give a realistic picture of the performance difference between these two classes of algorithms, which utilize different kinds of prior knowledge. Alternatively, we could have compared the performance with a NMF based SE approach, which is another popular SE algorithm. However, several studies \cite{wang_supervised_2015,williamson_deep_2015,kolbaek_speech_2016,williamson_estimating_2015} show that DNN based SE algorithms outperform NMF based approaches on several tasks. Furthermore, the NMF based approach can be viewed as a single hidden layer DNN. Hence, comparing the performance of the DNN based SE algorithm investigated in this paper to a NMF based SE algorithm is less interesting than a comparison with the STSA-MMSE based SE approach, which is from a completely different class of algorithms. STSA-MMSE type of methods such as \cite{ephraim_speech_1984,erkelens_minimum_2007} are very general and make only few assumptions about the target and noise signals and are therefore often used in practice \cite{hendriks_dft-domain_2013}. Furthermore, the performance of these simple non-machine learning based algorithms in terms of speech intelligibility improvements are well studied in the literature, e.g. \cite{madhu_potential_2013,hu_comparative_2007,luts_multicenter_2010,jensen_spectral_2012}. Although deep neural network based speech enhancement algorithms have shown impressive performance, they are often trained and tested in narrow settings using either a few noise types \cite{healy_algorithm_2015,healy_speech-cue_2014} or a single speaker \cite{chen_large-scale_2016}. It is therefore of interest to identify if/when a deep neural network based speech enhancement algorithm can outperform a non-machine learning based method, when approximately the same type of general a priori information is utilized: given that the computational and memory complexity associated with deep neural network type of systems is typically orders of magnitude larger than that associated with simple STSA-MMSE based systems, it is of obvious interest to understand the performance gain one can expect from the increased memory and computational complexity. The comparison is based on a "General" DNN based SE system trained using all the noise types from the noise dimension experiments at all the SNRs from the SNR dimension experiments, and using all the speakers from the speaker dimension experiments. This means that the system is trained using 7 different and equally distributed noise types mixed with 20 female and 20 male speakers at SNRs from -15 dB to 20 dB. To encompass the increased variability of this dataset compared to the previous datasets the training set size is increased to $40 \times 231 \times 12 = 110880$ utterances. To make a fair comparison to the STSA-MMSE method, which does not strongly rely on prior speaker, SNR, or noise type knowledge, 10 unseen noises, 20 unseen females and 20 unseen males are used for evaluating the performance at SNRs from -10 dB to 20 dB. The 10 noises are taken from the DEMAND noise database\footnote{http://parole.loria.fr/DEMAND} and represent a wide range of both stationary and non-stationary noise types. The STSA-MMSE method relies on the assumption that noise free Discrete Fourier Transform\,(DFT) coefficients are distributed according to a generalized gamma distribution with parameters $\gamma = 2$ and $\nu = 0.15$ \cite{erkelens_minimum_2007,hendriks_dft-domain_2013}. The \emph{a priori} SNR estimator used by the STSA-MMSE method is the Decision-Directed approach \cite{ephraim_speech_1984} using a smoothing factor of $0.98$ and a noise Power Spectral Density\,(PSD) estimate based on the noise PSD tracker reported in \cite{hendriks_mmse_2010}\footnote{http://insy.ewi.tudelft.nl/content/software-and-data}. For each utterance, the noise tracker was initialized using a noise PSD estimate based on a noise only region prior to speech activity. The results of the experiments are presented in Tables \ref{table:noise_mmse_stoi} and \ref{table:noise_mmse_pesq} for the STSA-MMSE method and in Tables \ref{table:noise_widesys_stoi} and \ref{table:noise_widesys_pesq} for the general DNN based SE system. The performance scores for the noisy unprocessed mixtures are given in parenthesis and the average across all 10 noises at each SNR is given in the last row. From Tables \ref{table:noise_mmse_stoi} and \ref{table:noise_widesys_stoi} it is seen that for all SNRs, the DNN based SE system outperforms the STSA-MMSE method in terms of STOI. Similar behavior is seen from Tables \ref{table:noise_mmse_pesq} and \ref{table:noise_widesys_pesq}, where the systems are evaluated using PESQ. However, at high SNRs the STSA-MMSE method achieves comparable results with the DNN based SE method and for some noise types such as \emph{DM station} and \emph{DM traffic}, the STSA-MMSE even achieves slightly better PESQ scores at SNRs above 5 dB. This might be explained by the fact that the STSA-MMSE algorithm uses prior knowledge in terms of an ideal noise PSD estimate based on a noise only signal region prior to speech activity. This prior knowledge could be particularly beneficial for stationary noise types, where the initial noise PSD estimate remains correct throughout the utterance. The DNN based SE method explored in this paper does not utilize such prior knowledge. However, in \cite{seltzer_investigation_2013,xu_regression_2015} noise PSD estimates obtained prior to speech activity were used in combination with traditional features to train a DNN based SE system and it was shown that performance was improved, when such prior knowledge was utilized. It is also seen that the STSA-MMSE method on average does not improve STOI, whereas the general DNN based SE method does. For some conditions such as \emph{DM station} at an SNR of -5 dB the improvement is as high as 0.096. In general, it can be observed that a DNN based SE system trained across all three generalizability dimensions using a large number of noise types, speakers and SNRs, outperforms a state-of-the-art non-machine learning based method, even though this method utilizes prior knowledge in terms of ideal initial noise PSD estimates. However, the performance of the general DNN based SE system is on average considerably reduced compared to the specialized systems where only one generalizability dimension was varied at a time. From this, it can be concluded that if the usage situation of a SE algorithm is well-defined e.g., in terms of speaker characteristics, noise type, or SNR range, considerably performance improvements can be achieved using a DNN based SE algorithm that has been specifically trained to fit the application. On the other hand, for more general applications where the acoustic usage situation cannot be narrowed down in one or more of these dimensions, the advantage of DNN based SE methods is much smaller, while they may still offer improvements over current state-of-the-art non-machine learning based methods. \begin{table*}[h!] \centering \caption{Average STOI performance improvement scores using a state-of-the-art STSA-MMSE estimator. The score in the parenthesis is for the noisy unprocessed signals. The test material is based on 2000 utterances evenly distributed among 20 males and 20 females mixed with 10 different noise types from the DEMAND noise corpus at seven SNRs in the range from -10 dB to 20 dB.} \label{table:noise_mmse_stoi} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccc} \midrule \midrule \textbf{} & {-10dB}& {-5dB} & {0dB} & {5dB} & {10dB} & {15dB} & {20dB} \\ \midrule \textbf{DM bus} & -0.003 (0.819) & -0.003 (0.884) & -0.003 (0.927) & -0.003 (0.955) & -0.003 (0.972) & -0.003 (0.983) & -0.003 (0.991) \\ \textbf{DM cafe} & -0.026 (0.521) & -0.011 (0.643) & -0.003 (0.756) & -0.001 (0.843) & -0.002 (0.902) & -0.003 (0.939) & -0.003 (0.962) \\ \textbf{DM cafeter} & -0.043 (0.459) & -0.022 (0.58) & -0.006 (0.706) & -0.001 (0.811) & -0.002 (0.884) & -0.003 (0.928) & -0.003 (0.955) \\ \textbf{DM car} & 0.008 (0.913) & 0.005 (0.945) & 0.002 (0.966) & 0.000 (0.979) & -0.001 (0.987) & -0.002 (0.992) & -0.002 (0.996) \\ \textbf{DM metro} & 0.002 (0.62) & 0.007 (0.73) & 0.006 (0.821) & 0.002 (0.886) & 0.000 (0.929) & -0.001 (0.955) & -0.002 (0.972) \\ \textbf{DM resto} & -0.054 (0.395) & -0.031 (0.496) & -0.012 (0.623) & -0.004 (0.746) & -0.003 (0.84) & -0.004 (0.902) & -0.004 (0.939) \\ \textbf{DM river} & 0.011 (0.55) & 0.020 (0.655) & 0.020 (0.755) & 0.013 (0.838) & 0.006 (0.897) & \textbf{0.002} (0.936) & \textbf{0.000} (0.961) \\ \textbf{DM square} & -0.008 (0.651) & -0.001 (0.761) & -0.000 (0.846) & -0.002 (0.904) & -0.003 (0.94) & -0.003 (0.962) & -0.003 (0.977) \\ \textbf{DM station} & 0.008 (0.496) & \textbf{0.022} (0.614) & \textbf{0.023} (0.733) & \textbf{0.016} (0.829) & \textbf{0.008} (0.894) & \textbf{0.002} (0.934) & \textbf{0.000} (0.958) \\ \textbf{DM traffic} & \textbf{0.019} (0.611) & 0.021 (0.724) & 0.016 (0.819) & 0.009 (0.887) & 0.003 (0.93) & 0.001 (0.957) & -0.001 (0.974) \\ \textbf{Average} & -0.009 (0.604) & 0.001 (0.703) & 0.004 (0.795) & 0.003 (0.868) & 0.000 (0.917) & -0.001 (0.949) & -0.002 (0.968) \\ \midrule \midrule \end{tabular} } \end{table*} \vspace{3 mm} \begin{table*}[h!] \centering \caption{As Table \ref{table:noise_mmse_stoi} but for a state-of-the-art DNN based SE algorithm.} \label{table:noise_widesys_stoi} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccc} \midrule \midrule \textbf{} & {-10dB}& {-5dB} & {0dB} & {5dB} & {10dB} & {15dB} & {20dB} \\ \midrule \textbf{DM bus} & 0.033 (0.819) & 0.021 (0.884) & 0.011 (0.927) & 0.004 (0.955) & -0.001 (0.972) & -0.004 (0.983) & -0.006 (0.991) \\ \textbf{DM cafe} & 0.034 (0.521) & 0.058 (0.643) & 0.054 (0.756) & 0.038 (0.843) & 0.022 (0.902) & 0.010 (0.939) & 0.002 (0.962) \\ \textbf{DM cafeter} & -0.011 (0.459) & 0.038 (0.58) & 0.056 (0.706) & 0.045 (0.811) & 0.027 (0.884) & 0.014 (0.928) & 0.005 (0.955) \\ \textbf{DM car} & 0.018 (0.913) & 0.008 (0.945) & 0.002 (0.966) & -0.002 (0.979) & -0.004 (0.987) & -0.006 (0.992) & -0.007 (0.996) \\ \textbf{DM metro} & 0.040 (0.62) & 0.046 (0.73) & 0.038 (0.821) & 0.024 (0.886) & 0.012 (0.929) & 0.004 (0.955) & -0.002 (0.972) \\ \textbf{DM resto} & -0.017 (0.395) & 0.046 (0.496) & 0.078 (0.623) & \textbf{0.069} (0.746) & \textbf{0.043} (0.84) & \textbf{0.022} (0.902) & \textbf{0.009} (0.939) \\ \textbf{DM river} & 0.077 (0.55) & 0.089 (0.655) & 0.074 (0.755) & 0.048 (0.838) & 0.026 (0.897) & 0.011 (0.936) & 0.001 (0.961) \\ \textbf{DM square} & 0.064 (0.651) & 0.054 (0.761) & 0.036 (0.846) & 0.021 (0.904) & 0.010 (0.94) & 0.003 (0.962) & -0.003 (0.977) \\ \textbf{DM station} & 0.076 (0.496) & \textbf{0.096} (0.614) & \textbf{0.080} (0.733) & 0.051 (0.829) & 0.027 (0.894) & 0.013 (0.934) & 0.004 (0.958) \\ \textbf{DM traffic} & \textbf{0.085} (0.611) & 0.072 (0.724) & 0.048 (0.819) & 0.027 (0.887) & 0.013 (0.93) & 0.004 (0.957) & -0.002 (0.974) \\ \textbf{Average} & 0.040 (0.604) & 0.053 (0.703) & 0.048 (0.795) & 0.032 (0.868) & 0.018 (0.917) & 0.007 (0.949) & 0.000 (0.968) \\ \midrule \midrule \end{tabular} } \end{table*} \begin{table*}[h] \centering \caption{As Table \ref{table:noise_mmse_stoi} but for PESQ.} \label{table:noise_mmse_pesq} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccc} \midrule \midrule \textbf{} & {-10dB}& {-5dB} & {0dB} & {5dB} & {10dB} & {15dB} & {20dB} \\ \midrule \textbf{DM bus} & 0.172 (1.26) & 0.278 (1.51) & 0.325 (1.93) & 0.336 (2.46) & 0.264 (3.05) & 0.129 (3.61) & -0.001 (4.04) \\ \textbf{DM cafe} & -0.035 (1.13) & 0.013 (1.11) & 0.067 (1.20) & 0.142 (1.42) & 0.206 (1.83) & 0.222 (2.37) & 0.174 (2.97) \\ \textbf{DM cafeter} & -0.061 (1.17) & -0.001 (1.11) & 0.056 (1.16) & 0.129 (1.32) & 0.206 (1.65) & 0.228 (2.14) & 0.177 (2.73) \\ \textbf{DM car} & \textbf{0.363} (1.21) & \textbf{0.500} (1.45) & \textbf{0.682} (1.81) & \textbf{0.742} (2.35) & 0.677 (2.94) & 0.459 (3.53) & 0.192 (4.01) \\ \textbf{DM metro} & 0.019 (1.13) & 0.134 (1.17) & 0.264 (1.33) & 0.356 (1.64) & 0.370 (2.12) & 0.297 (2.70) & 0.180 (3.28) \\ \textbf{DM resto} & -0.130 (1.25) & -0.046 (1.13) & 0.029 (1.11) & 0.113 (1.20) & 0.227 (1.43) & 0.305 (1.84) & 0.295 (2.40) \\ \textbf{DM river} & 0.009 (1.07) & 0.061 (1.09) & 0.183 (1.17) & 0.410 (1.36) & 0.605 (1.75) & 0.632 (2.30) & 0.500 (2.92) \\ \textbf{DM square} & 0.039 (1.08) & 0.102 (1.14) & 0.203 (1.29) & 0.303 (1.61) & 0.344 (2.10) & 0.330 (2.68) & 0.247 (3.29) \\ \textbf{DM station} & -0.008 (1.09) & 0.093 (1.07) & 0.271 (1.13) & 0.511 (1.30) & 0.688 (1.63) & \textbf{0.705} (2.14) & \textbf{0.565} (2.75) \\ \textbf{DM traffic} & 0.054 (1.07) & 0.188 (1.09) & 0.406 (1.19) & 0.615 (1.43) & \textbf{0.706} (1.86) & 0.700 (2.43) & 0.558 (3.05) \\ \textbf{Average} & 0.042 (1.14) & 0.132 (1.19) & 0.249 (1.33) & 0.366 (1.61) & 0.429 (2.04) & 0.401 (2.57) & 0.289 (3.14) \\ \midrule \midrule \end{tabular} } \end{table*} \vspace{3 mm} \begin{table*}[h!] \centering \caption{As Table \ref{table:noise_mmse_stoi} but for PESQ with a state-of-the-art DNN based SE algorithm.} \label{table:noise_widesys_pesq} \resizebox{\textwidth}{!}{% \begin{tabular}{lccccccc} \midrule \midrule \textbf{} & {-10dB}& {-5dB} & {0dB} & {5dB} & {10dB} & {15dB} & {20dB} \\ \midrule \textbf{DM bus} & 0.414 (1.26) & 0.550 (1.51) & 0.596 (1.93) & 0.543 (2.46) & 0.401 (3.05) & 0.225 (3.61) & 0.080 (4.04) \\ \textbf{DM cafe} & 0.007 (1.13) & 0.149 (1.11) & 0.300 (1.20) & 0.425 (1.42) & 0.479 (1.83) & 0.467 (2.37) & 0.372 (2.97) \\ \textbf{DM cafeter} & -0.047 (1.17) & 0.066 (1.11) & 0.196 (1.16) & 0.350 (1.32) & 0.471 (1.65) & 0.499 (2.14) & 0.423 (2.73) \\ \textbf{DM car} & \textbf{0.811} (1.21) & \textbf{1.021} (1.45) & \textbf{1.119} (1.81) & \textbf{1.005} (2.35) & \textbf{0.763} (2.94) & 0.447 (3.53) & 0.167 (4.01) \\ \textbf{DM metro} & 0.095 (1.13) & 0.242 (1.17) & 0.373 (1.33) & 0.463 (1.65) & 0.483 (2.12) & 0.408 (2.70) & 0.274 (3.28) \\ \textbf{DM resto} & -0.140 (1.25) & -0.009 (1.13) & 0.157 (1.11) & 0.338 (1.20) & 0.499 (1.43) & 0.571 (1.84) & \textbf{0.523} (2.4) \\ \textbf{DM river} & 0.111 (1.07) & 0.268 (1.09) & 0.464 (1.17) & 0.639 (1.36) & 0.682 (1.75) & \textbf{0.615} (2.30) & 0.445 (2.92) \\ \textbf{DM square} & 0.170 (1.08) & 0.327 (1.14) & 0.484 (1.29) & 0.572 (1.61) & 0.564 (2.10) & 0.489 (2.69) & 0.343 (3.29) \\ \textbf{DM station} & 0.059 (1.08) & 0.199 (1.07) & 0.356 (1.13) & 0.513 (1.30) & 0.610 (1.63) & 0.603 (2.14) & 0.478 (2.75) \\ \textbf{DM traffic} & 0.172 (1.07) & 0.347 (1.09) & 0.513 (1.19) & 0.620 (1.43) & 0.636 (1.86) & 0.575 (2.43) & 0.427 (3.05) \\ \textbf{Average} & 0.165 (1.14) & 0.316 (1.19) & 0.456 (1.33) & 0.547 (1.61) & 0.559 (2.04) & 0.490 (2.57) & 0.353 (3.14) \\ \midrule \midrule \end{tabular} } \end{table*} \subsection{Listening Test} To investigate how the DNN based SE system performs in practice, an intelligibility test, using 10 normal-hearing Danish graduate students, has been conducted. The gender distribution among the 10 students was 3 females and 7 males with ages from 20 to 28 years and a mean age of 24. Five systems have been designed for the SI test and their training specifications are given by Table \ref{tab_sitest}. \begin{table}[] \centering \caption{DNN based SE systems used for the intelligibility test presented in Figs. \ref{fig_sitest1} and \ref{fig_sitest2}. The first colum shows the system ID and the remaining columns show the training criteria.} \label{tab_sitest} \resizebox{0.8\textwidth}{!}{% \begin{tabular}{lccc} \midrule \midrule \multicolumn{1}{c}{{System ID}} & {Noise Dim.} & {SNR Dim.} & {Speaker Dim. } \\ \midrule DNN-1 & SSN & -5 dB & 20 Female \\ DNN-2 & SSN & -15 dB -- 20 dB & 20 Female \\ DNN-3 & BBL & -5 dB & 20 Female \\ DNN-4 & BBL & -15 dB -- 20 dB & 20 Female \\ DNN-5 & N3--N7, WGN, BBL-ADFD & -15 dB -- 20 dB & 20 Female, 20 Male \\ \midrule \midrule \end{tabular} } \end{table} The systems are designed to investigate if a female specific system, in different noise and SNR conditions (DNN-1 -- DNN-4), can improve SI, when exposed to an unseen female speaker. This is an extension of the experiments in \cite{healy_algorithm_2015} where the system was tested in matched speaker and matched SNR conditions only. Furthermore, DNN-5, which is a "general" system that has been trained on a wide range of speakers, noise types and SNRs, is included in the experiments to investigate if such a general system can improve SI, when exposed to both an unseen speaker and noise type. The noise types used for training DNN-5 include \ac{WGN}, babble noise (BBL-ADFD) and N3 - N7 from the noise dimension tests described in subsection \ref{sec:noiseDim}. The BBL-ADFD noise is constructed using the procedure for BBL, as described in subsection \ref{sec:snrdim}, but with three males and three females from the unused part of the ADFD corpus. Each test subject was exposed to five repetitions of 32 test conditions (2 noise types $\times$ 4 SNRs $\times$ 4 processing conditions), hence each test subject was exposed to a total of 160 sentences. The two noise types are SSN (N1) and BBL (N2) noise and the four SNRs are -13 dB, -9 dB, -5 dB and -1 dB. This SNR range was chosen to cover SNRs where SI is close to $0\%$ (-13 dB) and close to $100\%$ (-1 dB). The four processing conditions for each noise type were unprocessed corrupted speech, and corrupted speech processed by DNN-1, DNN-2, and DNN-5, for SSN and DNN-3, DNN-4, and DNN-5, for BBL noise. Immediately prior to the listening test, each test subject performed a familiarization test using 24 noisy utterances from a left out test set. The speech material used for the SI test was based on the Danish Dantale-II speech corpus \cite{wagener_design_2003}. Each utterance, which is spoken by a female, consists of five words from five different word classes appearing in the following order: name, verb, numeral, adjective and a noun and the test subject was asked to identify the spoken words via a computer interface. There are a total of 10 different words within each word class, hence the Dantale-II corpus is based on a total of 50 different words. All sentences are constructed such that they are syntactically correct but semantically unlikely, which makes it difficult to predict one word based on another, hence the corpus is suitable for intelligibility tests. The SI test was performed in an audiometric booth using a set of beyerdynamic DT 770 headphones and a Focusrite Scarlett 2i2 sound card The results are presented in Figs. \ref{fig_sitest1} and \ref{fig_sitest2} for SSN and BBL noise, respectively. Figs. \ref{fig_sitest1} and \ref{fig_sitest2} show that DNN-5, which is the speaker, noise type, and SNR general system, is unable to improve SI at any of the four SNRs of BBL noise as well as the SNRs at -13 dB, -9 dB, and -1 dB of SSN. A paired-sample t-test shows that this SI degradation is statistical significant, i.e. $p < 0.05$, for all these results. It is also seen that DNN-5 improves SI with a small amount for SSN at an SNR of -5 dB. However, this improvement is not statistically significant $(p = 0.44)$. For DNN-2 and DNN-4, which are the female and noise type specific, but SNR general systems, a somewhat different picture is observed. In general both DNN-2 and DNN-4 perform better than DNN-5. For SSN, DNN-2 manages to improve SI over the unprocessed signals at SNR -9 dB, while DNN-4 improves SI at SNRs of -5 dB and -1 dB. However, none of these improvements are statistical significant ($p = 0.10, p = 0.10, p = 0.25$, respectively) Finally, for DNN-1 and DNN-2, which are the female, noise type, and SNR specific systems, DNN-1 improves over DNN-2, whereas DNN-3 in general performs worse than DNN-4. Especially at an SNR of -5 dB DNN-3 performs significantly ($p<0.001$) worse than DNN-4 $(p = 0.10)$ relative to the unprocessed signals. This is surprising since DNN-3 is trained at only -5 dB SNR, while DNN-4 had been trained using the SNR range from -15 dB to 20 dB. Furthermore, the observed SI improvement, especially for DNN-4 and DNN-5 using BBL, is lower than one would expect based on the STOI scores for related models in Sec. \ref{sec:result}. This discrepancy between STOI scores and observed SI, especially for highly modulated noise signals, has previously been observed \cite{healy_algorithm_2015,chen_large-scale_2016,jorgensen_effects_2015,taal_algorithm_2011}. For DNN-1 a statistically significant improvement of $10.4$ percentage points $(p=0.011)$ in SI is observed at an SNR of -5 dB, which also corresponds to the SNR at which DNN-1 is trained. To the authors knowledge, SI improvements achieved by a female specific DNN based SE system tested on an unseen female speaker has not yet been reported. Furthermore, the system outperforms a wide range of previously reported SI test results by non-machine learning based methods reported in \cite{luts_multicenter_2010,hu_comparative_2007} and is comparable with the SI results reported in \cite{jensen_spectral_2012} where a single continuous-gain MMSE method was used. \begin{figure} \centering \begin{minipage}{0.48\textwidth} \centering \includegraphics[width=1\textwidth]{figures/figA/si_ssn_embed_font.pdf} \caption{SI test results for 3 different DNN based SE systems processing SSN corrupted speech signals based on 10 Danish test subjects.} \label{fig_sitest1} \end{minipage}\hfill \begin{minipage}{0.48\textwidth} \centering \includegraphics[width=1\textwidth]{figures/figA/si_bbl_embed_font.pdf} \caption{SI test results for 3 different DNN based SE systems processing BBL corrupted speech signals based on 10 Danish test subjects.} \label{fig_sitest2} \end{minipage} \end{figure} \section{Conclusion} \label{sec:conA} In this paper the generalizability of a state-of-the-art Deep Neural Network (DNN) based Speech Enhancement\,(SE) method has been investigated. Specifically, it has been investigated how noise specific, speaker specific and Signal-to-Noise Ratio\,(SNR) specific systems perform in relation to noise general, speaker general and SNR general systems, respectively. Furthermore, it has been investigated how such systems perform in relation to a single DNN based SE system which has been designed to be speaker, noise type and SNR general. Also, a comparison between this general DNN based SE system and a state-of-the-art Short-Time Spectral Amplitude Minimum Mean Square Error\,(STSA-MMSE) based SE method has been conducted. In general, a positive correspondence between training data variability and generalization was observed. Specifically, it was found that DNN based SE systems generalize well to both unseen speakers and unseen noise types given a large number of speakers and noise types were included in the training set. Furthermore, it was found that specialized DNN based SE systems trained on only one noise type, one speaker or one SNR, outperformed DNN based SE systems trained on a wide range of noise types, speakers, and SNRs in terms of both estimated Speech Quality\,(SQ) and estimated Speech Intelligibility\,(SI). In addition, a general DNN based SE algorithm trained using a large number of speakers, a large number of noise types at a large range of SNRs, outperformed a state-of-the-art STSA-MMSE SE algorithm in terms of estimated SQ and SI. However, the performance of this general DNN based SE system, was considerably reduced compared to the specialized systems, that have been optimized to only a single noise type, a single speaker or a single SNR. Finally, it was found that a DNN based SE system trained to be female, noise type and SNR specific, was able to improve SI when tested with an unseen female speaker for particular SNR and noise type configurations, although degrading SI for others. In general, it can be concluded that DNN based SE systems do have potential to improve SI in a broader range of usage situations than investigated in \cite{healy_algorithm_2015,chen_large-scale_2016}. Furthermore, the experiments conducted in this paper, indicate that matching the noise type is critical in acquiring good performance for DNN based SE algorithms, whereas matching the SNR dimension is the least critical followed by the speaker dimension for which good generalization can be achieved with a modest amount of training speakers. Also, it can be concluded that considerable improvement in performance can be achieved if the usage situation is limited such that the DNN based SE method can be optimized towards a specific application. Even though the results reported in this paper are considered general, there is some experimental evidence \cite{xu_regression_2015,wang_deep_2015,halevy_unreasonable_2009,hannun_deep_2014,amodei_deep_2015,chen_large-scale_2016} showing that generalizability performance of DNN based SE algorithms, and DNNs in general, improves when more data and larger networks are being applied, hence SQ and SI performance of DNN based SE systems are expected to improve in the future, when more data and computational resources become available. \section*{Acknowledgment} The authors would like to thank Asger Heidemann Andersen for providing software used to conduct the SI tests, and NVIDIA Corporation for the donation of a Titan X GPU. \section{Introduction} \label{sec:intro3} Biometric technologies, such as speaker verification\,(SV), are a secure, fast and convenient alternative to traditional authentication methods such as\linebreak typed passwords. In fact, the global market for biometric technologies is rapidly growing and is expected to reach \$41.5 billion in 2020 with annual growth rates of more than 20\% \cite{cumming_adoption_2016}. However, before biometric technologies can be completely adopted and applied in practice, they must, among other things, be robust against external interferences. This implies that the SV systems are reliable in a broad range of acoustic settings including different noisy environments, competing talkers, recording devices, etc. In recent years, the branch of machine learning known as \ac{DL} has gained a tremendous amount of attention in both academia and industry. DL is a term covering a wide range of machine learning techniques such as Deep Neural Networks\,(DNN), Recurrent Neural Networks or Convolutional Neural Networks\,(CNN) \cite{goodfellow_deep_2016}. Techniques, which have revolutionized a wide range of applications. \cite{he_delving_2015,bojarski_end_2016,dahl_context-dependent_2012,amodei_deep_2015,taigman_deepface:_2014}. Especially Automatic Speech Recognition\,(ASR) has been improved using DL \cite{yu_automatic_2015,hannun_deep_2014} and, although DL has revolutionized ASR, DL based noise robust SV has not attained much attention \cite{zhao_robust_2014,medina_wavelet_2003,nugraha_single-channel_2014,du_dnn_2015}. In general, SV is the task of verifying the identity of a person based on the voice of the speaker. Specifically, a SV system records via a single or multiple microphones an utterance from a speaker, and the task of the SV system is to verify or reject the claimed identity based on this spoken utterance. If the spoken text is known \textit{a priori}, it is referred as text-dependent SV, while if the spoken text is unknown it is referred as text-independent SV. In this paper, noise robustness of a text-dependent SV system is investigated using a state-of-the-art Long Short-Term Memory\,(LSTM) based Deep Recurrent Neural Network\,(DRNN) applied as a denoising front-end using single microphone recordings. It should be mentioned that \ac{SR} and SV is very related and differ in principle only in the way the system is evaluated or applied, i.e. for either identity verification or recognition. Although, we focus on SV in this paper the proposed front-end denoising techniques could just as well be applied for SR. For the same reasons the referenced literature focuses on both SR and SV. Typically, noise robust SV systems can be achieved by modifying either the back-end or the front-end of the SV system \cite{zhao_robust_2014,wang_robust_2007,omid_sadjadi_assessment_2010,medina_wavelet_2003,nugraha_single-channel_2014,du_dnn_2015,moreno-daniel_acoustic_2007,medina_robust_2003,nolazco-flores_enhancing_2008,ming_speaker_2006,baek_thomsen_speaker-dependent_2016,garcia-romero_multicondition_2012,villalba_handling_2013,ming_robust_2007,dat_robust_2015,saeidi_interspeech_2013,shepstone_total_2016,hansen_speaker_2015,hurmalainen_noise_2015,hurmalainen_exemplar-based_2012,hurmalainen_similarity_2015}. The back-end constitutes the \ac{UBM}, i-vector extractor and scoring, whereas the front-end constitutes preprocessing steps in terms of denoising of the microphone signal, and feature extraction, prior to back-end processing. Even though noise robust SV has been intensively studied in the literature \cite{garcia-romero_multicondition_2012,villalba_handling_2013,ming_robust_2007,dat_robust_2015,saeidi_interspeech_2013,zhao_robust_2014,wang_robust_2007,omid_sadjadi_assessment_2010,medina_wavelet_2003,nugraha_single-channel_2014,du_dnn_2015,moreno-daniel_acoustic_2007,medina_robust_2003,nolazco-flores_enhancing_2008,ming_speaker_2006,baek_thomsen_speaker-dependent_2016,hansen_speaker_2015,hurmalainen_noise_2015,hurmalainen_exemplar-based_2012,hurmalainen_similarity_2015}, only a few studies \cite{zhao_robust_2014,medina_wavelet_2003,nugraha_single-channel_2014,du_dnn_2015} have applied DNNs in a denoising context. Furthermore, none of these studies apply a DRNN as a SE front-end and compare these methods with existing SE approaches. In a recent study \cite{baek_thomsen_speaker-dependent_2016} it was shown that if \emph{a priori} knowledge about the noise type is available, a Non-negative Matrix Factorization\,(NMF) based SE front-end outperforms a Wiener filtering based SE front-end \cite{c._loizou_speech_2013} as well as a Short-Time Spectral Amplitude Minimum Mean Square Error\,(STSA-MMSE) based SE front-end \cite{erkelens_minimum_2007}. However, in the SE literature, several studies \cite{wang_supervised_2015,williamson_deep_2015,williamson_estimating_2015} show that DNN based SE algorithms outperform NMF based SE methods in terms of estimated speech quality and estimated speech intelligibility. Hence, a natural question to ask is whether DNN based SE algorithms also outperform NMF based SE in a SV context. This is the question addressed in this paper. The paper is organized as follows. In Sec. \ref{sec:snm} the speech corpora and noise data used for training and testing the NMF dictionaries, the DRNN models as well as the SV system are described. In Sec. \ref{sec:dnn} the proposed DRNN based SE front-ends are presented and in Sec. \ref{sec:base} the baseline systems are presented, which are the NMF based SE front-ends, the STSA-MMSE based SE front-end as well as the SV baseline system. In Sec. \ref{sec:res} the experimental design and results are discussed and finally the paper is concluded in Sec. \ref{sec:con1}. \section{Speech and Noise Data} \label{sec:snm} The denoising task performed by the SE front-ends investigated in this paper can be described by the linear model given by \begin{equation} {y}(n) = x(n) + d(n), \label{eq:model} \end{equation} where $y(n)$, $x(n)$, and $d(n)$ are the noisy speech signal, the clean speech signal and the additive noise signal, respectively. The task of the denoising front-ends, further described in the following sections, is to estimate $x(n)$ based on observations of $y(n)$. \subsection{Speech Corpora} In all simulation experiments (reported in Sec. \ref{sec:res}) the clean speech signal $x(n)$, is based on the male part of the RSR2015 corpus \cite{larcher_text-dependent_2014} and the data is allocated among the SV speaker models, the NMF, and DRNN front-ends according to Table. \ref{tab:datalloc}. For training SV speaker models, text ID 1 and sessions 1, 4, and 7 from male speakers from m002 to m050 and m052 are selected, and for testing, sessions 2, 3, 5, 6, 8, and 9 are used. Hence, the SV system is text-dependent and is based on 50 male speakers and each speaker is enrolled in the system using 3 utterances and tested with 6 utterances. Furthermore, sessions 1, 4, and 7 have been recorded using a Samsung Nexus smartphone, whereas sessions 2, 5, and 8 and 3, 6, and 9 have been recorded using a Samsung Galaxy S and a HTC Desire smartphone, respectively. That is, the SV system is tested in an unmatched microphone/recording device setting. For training the speaker dependent dictionaries used by the NMF based SE front-ends, text ID 1 and sessions 1, 4, and 7 are used. Hence, the NMF font-ends are similarly tested in an unmatched microphone/recording setting. The DRNN based front-ends are trained using text IDs 2 -- 30 and sessions 1 -- 9 from male speakers from m053 -- m142, and validated in terms of an early stopping scheme using the same utterances and session IDs, but using speakers from m143 -- m157. Although the DRNN front-ends are tested in a matched microphone setting, since they are trained on all nine sessions, they are tested in an unmatched text and an unmatched speaker setting, which is considered a considerably more challenging task. \begin{table}[h!] \centering \caption{Allocation of RSR2015 male-speaker speech data used for training and testing the SV system, as well as the NMF and DRNN front-ends. } \label{tab:datalloc} \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lcccc} \midrule \midrule \textbf{System} & \textbf{Cond.} & \textbf{Text ID.} & \textbf{Sess. ID} & \textbf{Sprk. ID} \\ \midrule SV & Train & 1 & 1, 4, 7 & 2 -- 50 \& 52 \\ SV & Test & 1 & 2,3,5,6,8,9 & 2 -- 50 \& 52 \\ NMF & Train & 1 & 1, 4, 7 & 2 -- 50 \& 52 \\ NMF & Test & 1 & 2,3,5,6,8,9 & 2 -- 50 \& 52 \\ DRNN & Train & 2--30 & 1--9 & 53 -- 142 \\ DRNN & Val & 2--30 & 1--9 & 143 -- 157 \\ DRNN & Test & 1 & 2,3,5,6,8,9 & 2 -- 50 \& 52 \\ \midrule \midrule \end{tabular} } \end{table} \subsection{Noise Data} The noise signal $d(n)$ (as given by Eq.\;\eqref{eq:model}) is used to simulate real-life noisy environments, such that the noise robustness of the SV system can be evaluated. For this evaluation the following 6 noise types are used: bus\,(BUS), cafeteria\,(CAF), street\,(STR) and pedestrian\,(PED) from the CHiME3 dataset \cite{barker_third_2015}, as well as a babble\,(BBL) noise, and a Speech Shaped Noise\,(SSN) created by the authors. The SSN sequence is constructed by filtering a 50 min. Gaussian white noise sequence through a $12$th-order all-pole filter with coefficients found from \ac{LPC} analysis of 100 randomly chosen sentences from a Danish speech corpus known as \emph{Akustiske Databaser for Dansk} (ADFD)\footnote{https://www.nb.no/sbfil/dok/nst\_taledat\_no.pdf}. The BBL noise is similarly based on the ADFD corpus. From the ADFD test set, four male and four female speakers are randomly selected. Each speaker is represented by 986 utterances which are normalized to unit Root Mean Square\,(RMS) following the removal of any silent segments using a Voice Activity Detection\,(VAD) algorithm. Then, all 986 utterances from each speaker is concatenated into 8 signals, following truncation to equal length and addition of the eight signals into a single eight speaker babble noise signal. All six (BUS, CAF, STR, PED, BBL, SSN) noise types were first truncated to have a total duration of 50 min. and then divided into a 40 min. training set, 5 min. validation set and a 5 min. test set. Hence, there are no overlapping noise segments between the training, validation, and test noise. The noisy mixtures at different Signal to Noise Ratios\;(SNRs) were constructed using the model in Eq.\;\eqref{eq:model} by scaling the noise signal $d(n)$ accordingly. The noise signal was scaled to achieve the desired SNR based on the duration of the entire speech signal $x(n)$. Furthermore, a sampling frequency of 16 kHz is used throughout the paper and all audio files are normalized to unit RMS \section{Speech Enhancement Using Deep Recurrent Neural Networks} \label{sec:dnn} Speech enhancement algorithms based on DNNs have in recent years gained a large amount of attention and showed impressive performance in terms of improving speech quality and speech intelligibility \cite{wang_supervised_2015,williamson_deep_2015,williamson_estimating_2015,chen_large-scale_2016,huang_joint_2015}. Common for these algorithms is that they use a DNN as a regression model to estimate a ratio mask that is applied to the Time-Frequency\,(T-F) representation of the noisy speech signal to acquire an estimate of the clean speech signal. A related approach will be adopted in this paper. Specifically, a DNN is employed, but it is improved using LSTM layers \cite{hochreiter_long_1997} and a training criterion that indirectly constructs a ratio mask by minimizing the Mean Square Error\,(MSE) between the desired clean speech signal and the noise. In this way, the model learns to separate speech from noise, which is the real desired goal, rather than minimizing the MSE between an ideal mask and an estimated mask, as is typically done \cite{chen_large-scale_2016,healy_algorithm_2015,wang_training_2014}. The T-F representation used for the DRNN based SE front-end is a\linebreak $N_{STFT}=512$ point Short-Time Fourier Transform\,(STFT) using a frame width of 32 ms and a frame spacing of 16 ms \cite{c._loizou_speech_2013}. In this way, a frequency dimension of $N = N_{STFT}/2+1 = 257$, covering positive frequencies, is achieved. When the estimated ratio mask has been applied to the noisy speech signal, the time domain representation is achieved by applying an Inverse Short-Time Fourier Transform\,(ISTFT) using the phase from the noisy signal. \subsection{DRNN Architecture and Training} All DRNN based front-ends are based on an architecture constituting two LSTM layers and a single fully connected feed-forward output layer with sigmoid activation functions. The input to the DRNN is the magnitude of the STFT coefficients of the noisy mixture $y(n)$, including a context of 15 past frames and 15 future frames, hence arriving at a final input dimension of $N \times 31= 257 \times 31=7967$. The output constitutes a ratio mask for a single frame, and the dimension is therefore related to the size of the STFT, i.e. 257 (STFT order is 512). The training criterion used for training the DRNNs is defined as follows: Let $|x(n,\omega)|$, $|d(n,\omega)|$ and $|y(n,\omega)|$ denote the magnitude of the STFT of the clean speech signal, the noise signal and the noisy mixture, respectively. Furthermore let $\hat{x}(n,\omega)$ and $\hat{d}(n,\omega)$ denote the estimate of the magnitude of the clean speech signal and noise signal, respectively. Finally, let $o(n,\omega)$ denote the output of the DRNN, and let $m_x(n,\omega)$ and $m_d(n,\omega)$ denote the ratio mask representing the speech signal and noise signal, respectively. Since the DRNN has one sigmoid output layer, the speech ratio mask $m_x(n,\omega)$ for a single T-F unit is simply defined as \begin{equation} m_x(n,\omega) = o(n,\omega), \end{equation} and $m_d(n,\omega)$ as \begin{equation} m_d(n,\omega) = 1 - o(n,\omega). \label{eq:eq1} \end{equation} Furthermore, $\hat{x}(n,\omega)$ is defined as \begin{equation} \hat{x}(n,\omega) = m_x(n,\omega) \times |y(n,\omega)|, \label{eq:eq2} \end{equation} and $\hat{d}(n,\omega)$ as \begin{equation} \hat{d}(n,\omega) = m_d(n,\omega) \times |y(n,\omega)|. \label{eq:eq3} \end{equation} Finally, the DRNN MSE training criteria for a single training example $(d(n,\omega)$, $x(n,\omega))$ is defined as: \begin{equation} \begin{split} MSE(n) &= \frac{1}{N} \sum_{\omega = 1}^{N} (\hat{d}(n,\omega) - |d(n,\omega)|)^2 \\ & + \frac{1}{N} \sum_{\omega = 1}^{N} (\hat{x}(n,\omega) - |x(n,\omega)|)^2. \label{eq:eq4} \end{split} \end{equation} By using the training criteria given by Eq.\;\eqref{eq:eq4}, it is ensured that the MSE between $\hat{d}(n,\omega)$ and $|d(n,\omega)|$, as well as $\hat{x}(n,\omega)$ and $|x(n,\omega)|$ is minimized, while still ensuring that $m_d(n,\omega)$ and $m_x(n,\omega)$ represents a valid ratio mask, i.e. $m_x(n,\omega) + m_d(n,\omega) = 1$. Although $m_x(n,\omega)$ and $m_d(n,\omega)$ are not explicitly used, in this particular work, since the current DRNN directly estimates $|x(n,\omega)|$, the formulation in Eq.\;\eqref{eq:eq4} allows the output layer to be straightforwardly extended to multiple outputs by extending the dimension of the output layer and applying a softmax to ensure all outputs are correctly normalized, hence separating e.g. multiple speakers \cite{yu_permutation_2016}. The DRNNs used for all experiments in this paper are implemented in CNTK\footnote{https://www.cntk.ai} \cite{agarwal_introduction_2014} and are trained using stochastic gradient descent with truncated backpropagation through time, using 10 time steps and a momentum term of $0.9$ for all epochs. The learning rate is initially set to $0.1$, but is reduced with a factor of $2$, when the validation error has not decreased for one epoch. During training, $20\%$ dropout \cite{hinton_improving_2012} is used for the LSTM layers and the training is aborted, when the learning rate becomes less than $1^{-10}$. When the learning rate is decreased, the training continues from the previous best model. \subsection{DRNN Based SE Front-Ends} A total of seven DRNN based SE front-ends are investigated: Six Noise Specific DRNN (NSDRNN) front-ends, one for each noise type, and one Noise General DRNN (NGDRNN) front-end trained on all six noise types. The NSDRNN front-ends are each trained on a particular noise type, hence, at test time, \emph{a priori} knowledge about the noise type is required. This is similar to the NMF front-ends, which also rely on this prior knowledge. For the NGDRNN front-end, only a single model is trained using a combination of all six noise types. This front-end therefore utilizes only a minimum amount of \emph{a priori} information, since it is unaware of the actual noise type. The NGDRNN front-end is included to investigate the performance that can be achieved, if less \emph{a priori} knowledge about the noise type is available. For all DRNN front-ends, $10^5$ noisy mixtures are used for training. The mixtures are generated by drawing a SNR at random from a discrete uniform distribution defined within the SNR range from -5 dB -- 20 dB. Due to the large number of realizations, it is assumed that the distribution of drawn SNRs is approximately uniform. The noise signal used for each noisy mixture was extracted from the whole training noise sequence by using a starting index drawn from a discrete uniform distribution defined over the entire length of the noise sequence. If the starting index is such that there is no room for the whole utterance, the remaining samples are extracted from the beginning of the noise sequence. For the NGDRNN front-end, the training noise sequence is constructed by concatenating the six individual noise type sequences, hence the $10^5$ noisy mixtures contain all six noise types evenly distributed, whereas for the NSDRNN front-ends the $10^5$ noisy mixtures contain only a single noise type. A similar approach is used for generating the mixtures used for validation and test. \section{Baseline Systems} \label{sec:base} This section describes the SV baseline as well as the SE baseline front-ends, namely the NMF based SE front-ends and the STSA-MMSE based SE front-end. \subsection{NMF Baseline} The basic observation behind NMF is that a non-negative matrix $\mathbf{V} \in \mathbb{R}^{m \times n}$ can be approximately factorized into a product of two non-negative matrices $\mathbf{D} \in \mathbb{R}^{m \times k}$ and $\mathbf{H} \in \mathbb{R}^{k \times n}$ \cite{lee_algorithms_2000} as given by \begin{equation} \mathbf{V} \approx \mathbf{D} \mathbf{H}, \label{eq:nmf11} \end{equation} where $\mathbf{D}$ is known as the dictionary and $\mathbf{H}$ is the activation matrix. The activation matrix $\mathbf{H}$ is used to identify what parts of the dictionary are required to accurately approximate $\mathbf{V}$. The number of columns $k$ in the dictionary $\mathbf{D}$ is a tuning parameter used to adjust the representational power of the factorization. The dictionary $\mathbf{D}$ and the activations $\mathbf{H}$ can be found by solving the constrained and regularized least squares minimization problem given by \begin{equation} \begin{aligned} & \underset{\mathbf{D},\mathbf{H}}{\text{minimize}} & & \frac{1}{2} \Vert \mathbf{V} - \mathbf{D} \mathbf{H} \Vert ^2_F + \alpha \Vert \mathbf{H} \Vert _1 \\ & \text{subject to} & & \mathbf{D},\mathbf{H} \geq 0, \end{aligned} \label{eq:nmf} \end{equation} where $\Vert \cdot \Vert ^2_F $ is the squared Frobenius norm, $\Vert \cdot \Vert_1 $ is the $\ell1$-norm, and $\alpha > 0$ is a sparsity parameter \cite{schmidt_wind_2007}. Equation \eqref{eq:nmf} can be solved in an iterative fashion using \begin{subequations} \begin{equation} \mathbf{H} = \mathbf{H} \circ \frac{\mathbf{D}^T\mathbf{V}}{\mathbf{D}^T\mathbf{D}\mathbf{H} + \alpha}, \label{eq:nmfupdateH} \end{equation} \begin{equation} \mathbf{D} = \mathbf{D} \circ \frac{\mathbf{V}\mathbf{H}^T}{\mathbf{D}\mathbf{H}\mathbf{H}^T }, \label{eq:nmfupdateD} \end{equation} \label{eq:nmfupdate} \end{subequations} where $\circ$ is the Hadamard product, i.e. element-wise multiplication. The solution to Eq.\;\eqref{eq:nmf} is found by alternating between update rule \eqref{eq:nmfupdateH} and \eqref{eq:nmfupdateD} until the value of the cost function given by Eq.\;\eqref{eq:nmf} is below a predefined threshold \cite{schmidt_wind_2007,lee_algorithms_2000}. When NMF is applied for SE using a model given by Eq.\;\eqref{eq:model}, $\mathbf{V}$ is the STFT magnitudes of a noisy speech signal $\mathbf{V_y}$, and is on the following form: \begin{equation} \begin{split} \mathbf{V_y} & \approx \mathbf{D} \mathbf{H} = \begin{bmatrix} \mathbf{D_x} \; \mathbf{D_d} \end{bmatrix} \begin{bmatrix} \mathbf{H_x} \\ \mathbf{H_d} \\ \end{bmatrix}, \end{split} \label{eq:nmf13} \end{equation} where $\mathbf{D_x}$ and $\mathbf{D_d}$ are speech and noise dictionaries, respectively and $\mathbf{H_x}$ and $\mathbf{H_d}$ are their corresponding activations. The dictionaries $\mathbf{D_x}$ and $\mathbf{D_d}$ are found using the approach given by Eq.\;\eqref{eq:nmfupdate}, in an offline training procedure, prior to test time. At test time, using the already trained $\mathbf{D_x}$ and $\mathbf{D_d}$ and a test sample $\mathbf{V_y}$, the corresponding activations $\mathbf{H_x}$ and $\mathbf{H_d}$ are found jointly using Eqs.\;\eqref{eq:nmf13} and \eqref{eq:nmfupdateH}, and the estimate of the clean speech STFT magnitudes $\hat{\mathbf{X}}$ are acquired by \cite{baek_thomsen_speaker-dependent_2016} \begin{equation} \hat{\mathbf{X}} = \mathbf{Y} \circ \frac{\frac{\mathbf{D_x}\mathbf{H_x}}{\mathbf{D_d}\mathbf{H_d}}}{1+\frac{\mathbf{D_x}\mathbf{H_x}}{\mathbf{D_d}\mathbf{H_d}}}. \label{eq:nmfres} \end{equation} The time domain signal is finally achieved by ISTFT of $\hat{\mathbf{X}}$ using the phase of the noisy mixture. For the experiments conducted in this paper, one NMF dictionary $\mathbf{D_x}$, is trained for each speaker and each noise type, hence the NMF front-ends are speaker, text, and noise type dependent. This is similar to the study in \cite{baek_thomsen_speaker-dependent_2016}, which enables the use of a NMF based denoising front-end with only a small amount of training data. However, it requires \emph{a priori} knowledge about the noise type at test time. Furthermore, similarly to \cite{baek_thomsen_speaker-dependent_2016}, the speaker dictionaries $\mathbf{D_x}$ have a fixed size of $64$ columns, i.e. $k = 64$ and are trained using speech-only regions by removing all frames with a sample variance less than $3 \times 10^{-5}$. Finally, the NMF training is terminated when the value of the cost function given in Eq.\;\eqref{eq:nmf} is less than $10^{-4}$ or the number of iterations exceed $500$. \subsection{STSA-MMSE Baseline} The STSA-MMSE front-end is a statistical based SE method, which relies on the assumption that noise free Discrete Fourier Transform\,(DFT) coefficients are distributed according to a generalized gamma distribution with parameters $\gamma = 2$ and $\nu = 0.15$ \cite{erkelens_minimum_2007,hendriks_dft-domain_2013}. The \emph{a priori} SNR estimator used by the STSA-MMSE front-end is the Decision-Directed approach \cite{ephraim_speech_1984} using a smoothing factor of $0.98$ and a noise Power Spectral Density\,(PSD) estimate based on the noise PSD tracker reported in \cite{hendriks_mmse_2010}\footnote{http://insy.ewi.tudelft.nl/content/software-and-data}. For each utterance, the noise tracker was initialized using a noise PSD estimate based on the first 1000 samples i.e.\;62.5 ms, which is assumed to be a noise-only region. Since the STSA-MMSE front-end only relies on simple statistical assumptions, it is basically text, speaker, and noise type independent and is therefore the method that relies on the least amount of \emph{a priori} knowledge compared to the NMF, NSDRNN, and NGDRNN front-ends. \subsection{Speaker Verification Baseline} \label{sec:sv} The SV baseline is a Gaussian Mixture Model\,(GMM)-UBM i-vector based system \cite{dehak_front-end_2011} and is similar to the system investigated in \cite{baek_thomsen_speaker-dependent_2016}. The baseline is implemented using the Kaldi Speech Recognition Toolkit \cite{povey_kaldi_2011}. The 4380 male speaker utterances from the TIMIT corpus \cite{garofolo_darpa_1993} are used for obtaining the GMM-UBM as well as the total variability matrix used for i-vector extraction. The used features are 13 Mel Frequency Cepstrum Coefficients\,(MFCC) based on voice only regions of frames with a duration of 25 ms and a frequency range from 0 -- 8 kHz and with cepstral liftering disabled. The energy threshold and the energy mean scale of the Kaldi VAD function are set to their default values of $5.5$ and $0.5$, respectively. During enrollment, an i-vector of dimension $400$ is generated for each of the three enrollment utterances, for each speaker. The final speaker model is constructed as the average of these three i-vectors. During test time, the cosine distance between each speaker model i-vector and all test utterance i-vectors is computed, and since 50 speakers are enrolled in the SV system and each speaker is represented by 6 test utterances, a total number of $50 \times 6 \times 50=15000$ trials are conducted for each evaluation. When a model is chosen as the target speaker, the remaining $49$ models are used as imposters, hence the last multiplication with $50$. From the $15000$ cosine scores the \ac{ROC} curve is constructed, and the \ac{EER} is identified and used as the final evaluation score. The EER is the location on the ROC curve where the false positive rate is equal to the false rejection rate, i.e. one minus the true positive rate. For EERs, lower is better, and a flawless SV system will achieve an EER of zero. \section{Experimental Results and Discussion} \label{sec:res} The performance of the SV system with different denoising front-ends is presented in Tables \ref{tab:resbbl} -- \ref{tab:resstr}. The SV system is evaluated using noisy mixtures contaminated with the six noise types described in Sec. \ref{sec:snm} at SNRs in the range from -5 dB -- 20 dB. The system is also evaluated using the clean speech signals without any noise, in order to investigate how the denoising front-ends operate in noise-free conditions. For each noise type and SNR, the SV system is evaluated using the following five front-ends: No front-end processing (No Proc.), STSA-MMSE based front-end processing, NMF based front-end processing, NSDRNN based front-end processing, and finally NGDRNN based front-end processing. It should be mentioned that both the NSDRNN and NGDRNN front-ends are tested in unmatched text and speaker conditions, while the NMF method is tested in matched text and speaker conditions. Furthermore, since the STSA-MMSE, NSDRNN and NGDRNN front-ends are speaker independent the same front-end can be used for both target speakers and imposters. However, since the NMF based front-ends are\linebreak speaker dependent the NMF front-end with speaker ID similar to the target speaker is used to process all trials for that particular speaker, i.e. for both target speaker and imposters. This is done to account for the situation where the claimed speaker ID is false, i.e. an imposter. In these situations it should be ensured that the NMF processing cannot induce a false positive by using a front-end not matched to the speaker ID. \begin{table}[h!] \caption{EER for SV system using BBL noise corrupted speech.} \vspace{-2mm} \label{tab:resbbl} \centering \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule SNR & \begin{tabular}[c]{@{}c@{}}No Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}}STSA-\\MMSE\end{tabular} & \begin{tabular}[c]{@{}c@{}}NMF\end{tabular} & \begin{tabular}[c]{@{}c@{}}NS\\DRNN\end{tabular} & \begin{tabular}[c]{@{}c@{}}NG\\DRNN\end{tabular} \\ \midrule -5 dB & 46.0 & 44.8 & 40.1 & \textbf{28.9} & 33.6 \\ 0 dB & 37.9 & 36.6 & 32.2 & \textbf{19.6} & 21.0 \\ 5 dB & 26.6 & 27.4 & 23.8 & \textbf{14.6} & 14.8 \\ 10 dB & 17.6 & 18.3 & 17.0 & \textbf{12.0} & 13.0 \\ 15 dB & 11.6 & 12.1 & 14.0 & 10.7 & \textbf{10.5} \\ 20 dB & \textbf{9.26} & 10.3 & 11.6 & 9.39 & 9.67 \\ Clean & \textbf{6.67} & 11.7 & 14.5 & 10.7 & 11.7 \\ \midrule Average & 22.2 & 23.0 & 21.9 & \textbf{15.1} & 16.3 \\ \midrule \midrule \end{tabular} } \end{table} \begin{table}[h!] \caption{EER for SV system using BUS noise corrupted speech.} \vspace{-2mm} \label{tab:resbus} \centering \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule SNR & \begin{tabular}[c]{@{}c@{}}No Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}}STSA-\\MMSE\end{tabular} & \begin{tabular}[c]{@{}c@{}}NMF\end{tabular} & \begin{tabular}[c]{@{}c@{}}NS\\DRNN\end{tabular} & \begin{tabular}[c]{@{}c@{}}NG\\DRNN\end{tabular} \\ \midrule -5 dB & 32.0 & 28.0 & 26.1 & 17.3 & \textbf{16.9} \\ 0 dB & 27.3 & 23.5 & 17.9 & 14.2 & \textbf{12.9} \\ 5 dB & 21.7 & 21.4 & 13.4 & \textbf{11.1} & 11.6 \\ 10 dB & 16.3 & 16.7 & 10.3 & \textbf{8.67} & 11.3 \\ 15 dB & 11.3 & 12.6 & 9.07 & \textbf{8.75} & 10.0 \\ 20 dB & 8.49 & 10.9 & \textbf{7.54} & 7.75 & 9.87 \\ Clean & \textbf{6.67} & 11.7 & 8.07 & 8.94 & 11.7 \\ \midrule Average & 17.7 & 17.8 & 13.2 & \textbf{11.0} & 12.0 \\ \midrule \midrule \end{tabular} } \end{table} \begin{table}[h!] \caption{EER for SV system using CAF noise corrupted speech.} \vspace{-2mm} \label{tab:rescaf} \centering \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule SNR & \begin{tabular}[c]{@{}c@{}}No Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}}STSA-\\MMSE\end{tabular} & \begin{tabular}[c]{@{}c@{}}NMF\end{tabular} & \begin{tabular}[c]{@{}c@{}}NS\\DRNN\end{tabular} & \begin{tabular}[c]{@{}c@{}}NG\\DRNN\end{tabular} \\ \midrule -5 dB & 39.9 & 40.0 & 36.8 & \textbf{24.7} & 25.6 \\ 0 dB & 34.0 & 33.0 & 29.9 & \textbf{17.5} & 19.2 \\ 5 dB & 26.7 & 26.6 & 22.8 & \textbf{14.0} & 15.1 \\ 10 dB & 18.8 & 19.2 & 18.0 & \textbf{11.7} & 12.1 \\ 15 dB & 12.8 & 13.8 & 14.3 & \textbf{9.95} & 11.2 \\ 20 dB & \textbf{8.90} & 11.1 & 13.0 & 9.35 & 10.6 \\ Clean & \textbf{6.67} & 11.7 & 11.7 & 11.2 & 11.7 \\ \midrule Average & 21.1 & 22.2 & 20.9 & \textbf{14.1} & 15.1 \\ \midrule \midrule \end{tabular} } \end{table} \begin{table}[h!] \caption{EER for SV system using PED noise corrupted speech.} \vspace{-2mm} \label{tab:resped} \centering \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule SNR & \begin{tabular}[c]{@{}c@{}}No Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}}STSA-\\MMSE\end{tabular} & \begin{tabular}[c]{@{}c@{}}NMF\end{tabular} & \begin{tabular}[c]{@{}c@{}}NS\\DRNN\end{tabular} & \begin{tabular}[c]{@{}c@{}}NG\\DRNN\end{tabular} \\ \midrule -5 dB & 43.1 & 38.6 & 40.7 & \textbf{29.6} & 30.3 \\ 0 dB & 35.6 & 31.1 & 32.9 & 22.0 & \textbf{20.2} \\ 5 dB & 26.3 & 22.0 & 24.0 & 15.4 & \textbf{13.7} \\ 10 dB & 18.3 & 15.5 & 17.4 & 12.6 & \textbf{10.8} \\ 15 dB & 11.9 & 12.1 & 12.2 & \textbf{8.55} & 9.56 \\ 20 dB & 8.57 & 10.3 & 10.3 & \textbf{8.49} & 10.9 \\ Clean & \textbf{6.67} & 11.7 & 11.3 & 12.3 & 11.7 \\ \midrule Average & 21.5 & 20.2 & 21.3 & 15.6 & \textbf{15.3} \\ \midrule \midrule \end{tabular} } \end{table} \begin{table}[h!] \caption{EER for SV system using SSN noise corrupted speech.} \vspace{-2mm} \label{tab:resssn} \centering \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule SNR & \begin{tabular}[c]{@{}c@{}}No Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}}STSA-\\MMSE\end{tabular} & \begin{tabular}[c]{@{}c@{}}NMF\end{tabular} & \begin{tabular}[c]{@{}c@{}}NS\\DRNN\end{tabular} & \begin{tabular}[c]{@{}c@{}}NG\\DRNN\end{tabular} \\ \midrule -5 dB & 44.4 & 35.7 & 37.8 & \textbf{20.5} & 21.6 \\ 0 dB & 34.9 & 25.9 & 26.9 & \textbf{14.5} & 16.0 \\ 5 dB & 25.5 & 18.0 & 17.7 & \textbf{11.9} & 13.2 \\ 10 dB & 16.1 & 11.6 & 12.1 & \textbf{10.9} & 11.4 \\ 15 dB & 10.3 & 9.70 & \textbf{9.51} & 10.0 & \textbf{9.51} \\ 20 dB & \textbf{7.40} & 10.3 & 8.17 & 9.52 & 9.48 \\ Clean & \textbf{6.67} & 11.7 & 10.5 & 10.3 & 11.7 \\ \midrule Average & 20.8 & 17.6 & 17.5 & \textbf{12.5} & 13.3 \\ \midrule \midrule \end{tabular} } \end{table} \begin{table}[h!] \caption{EER for SV system using STR noise corrupted speech.} \vspace{-2mm} \label{tab:resstr} \centering \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule SNR & \begin{tabular}[c]{@{}c@{}}No Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}}STSA-\\MMSE\end{tabular} & \begin{tabular}[c]{@{}c@{}}NMF\end{tabular} & \begin{tabular}[c]{@{}c@{}}NS\\DRNN\end{tabular} & \begin{tabular}[c]{@{}c@{}}NG\\DRNN\end{tabular} \\ \midrule -5 dB & 41.1 & 34.6 & 35.4 & \textbf{22.3} & 24.3 \\ 0 dB & 33.7 & 26.5 & 27.3 & 17.4 & \textbf{16.8} \\ 5 dB & 26.2 & 21.5 & 19.0 & 14.6 & \textbf{13.8} \\ 10 dB & 18.3 & 15.7 & 14.1 & 12.4 & \textbf{10.9} \\ 15 dB & 12.0 & 11.9 & 12.2 & 9.61 & \textbf{9.40} \\ 20 dB & 9.01 & 11.1 & 10.0 & 9.10 & \textbf{8.61} \\ Clean & \textbf{6.67} & 11.7 & 10.5 & 10.7 & 11.7 \\ \midrule Average & 21.0 & 19.0 & 18.4 & 13.7 & \textbf{13.6} \\ \midrule \midrule \end{tabular} } \end{table} It is seen from Tables \ref{tab:resbbl} -- \ref{tab:resstr} that the NSDRNN and NGDRNN front-ends achieve the lowest EER for the majority of the test conditions and outperforms the NMF and STSA-MMSE front-ends with a large margin, especially at SNRs below 10 dB. However, no front-end achieves the EER of $6.67$ for the clean condition, hence it seems that all methods introduce some distortion at high SNRs. For practical applications it might be beneficial to incorporate an SNR estimator, such that the SE front-ends only are used when needed, i.e. for low SNRs. A somewhat surprising observation is that the NGDRNN front-end in general performs well and not only outperforms the NMF and STSA-MMSE front-ends for the majority of noise types and SNRs, but also the NSDRNN front-ends for several SNRs and noise types. This is an observation of practical importance, since it shows that using a single DRNN based front-end, which is both text, SNR, male-speaker and noise type independent eliminates the need for noise type classification and speaker dependent front-ends as would be required by the NMF front-ends. The advantage of NMF based front-ends is that they can efficiently utilize small amounts of data. In \cite{baek_thomsen_speaker-dependent_2016} it is shown that using only three utterances from a speaker, a NMF based SE front-end can be designed which outperforms a STSA-MMSE based SE front-end, a Wiener filtering based SE front-end and a spectral subtraction based SE front-end. Since DNNs typically require a large amount of data, constructing speaker specific front-ends is not practically feasible, since it would require that each SV user should record large amount of enrollment speech. The results presented in Tables \ref{tab:resbbl} -- \ref{tab:resstr} show that conventional speech corpora, such as RSR2015, can be used to design a male-speaker and text-independent SE front-end that achieves state-of-the-art performance for a number of noise types and SNRs, hence the NGDRNN front-end can be used for noise robust text-dependent and text-independent speaker verification. \section{Conclusion} \label{sec:con1} In this paper a Deep Recurrent Neural Network\,(DRNN) based Speech Enhancement\,(SE) algorithm has been studied in the context of noise-robust text-dependent Speaker Verification\,(SV). Specifically, a state-of-the-art Long-Short Term Memory\,(LSTM) based DRNN, trained to be either noise type specific or noise type general as well as text and male-speaker independent is used as denoising front-ends for an i-vector based SV system. Finally, the SV performance of the DRNN based SE front-ends are compared against speaker, text, and noise type dependent Non-negative Matrix Factorization\,(NMF) based SE front-ends as well as a Short-Time Spectral Amplitude Minimum Mean Square Error\,(STSA-MMSE) based SE front-end, which is speaker, text and noise type independent. We show that the noise type specific DRNN based SE front-ends outperform both the NMF based front-ends as well as the STSA-MMSE based front-end for an SNR range from -5 dB -- 10 dB, for six different noise types. Furthermore, we show that a text, male-speaker and noise type independent DRNN based SE front-end similarly outperforms both the NMF based SE front-ends and the STSA-MMSE based SE front-end at SNRs below 15 dB. This is a result of great practical importance, since it shows that a single DRNN based SE front-end can achieve state-of-the-art SV performance in a variety of noisy environments, hence eliminating the need for noise type classification and speaker dependent front-ends \section{Acknowledgment} \label{sec:ack} The authors would like to thank Nicolai Bæk Thomsen for assistance and software used for the speaker verification and non-negative matrix factorization baseline systems. Also, we would like to thank Dong Yu for useful discussions regarding CNTK and DNN training. Finally, we gratefully acknowledge the support of NVIDIA Corporation with the donation of the Titan X GPU used for this research. The paper reflects some results from the OCTAVE Project (\#647850),\linebreak funded by the Research European Agency (REA) of the European Commission, in its framework program Horizon 2020. The views expressed in this paper are those of the authors and do not engage any official position of the European Commission. \pagebreak \section{Introduction} Despite the significant progress made in dictating single-speaker speech in the recent years \cite{PretrainVSFineTune-Yu2010,CD-DNN-HMM-dahl2012,CD-DNN-HMM-SWB-seide2011,DNN4ASR-hinton2012}, the progress made in multi-talker mixed speech separation and recognition, often referred to as the cocktail-party problem \cite{Cherry53,AuditorySceneAnalysis-bregman1994}, has been less impressive. Although human listeners can easily perceive separate sources in an acoustic mixture, the same task seems to be extremely difficult for automatic computing systems, especially when only a single microphone recording of the mixed-speech is available \cite{MonauralSpeechSepChallenge-Cooke2010,SingleChannelSep-Weng2015}. Nevertheless, solving the cocktail-party problem is critical to enable scenarios such as automatic meeting transcription, automatic captioning for audio/video recordings (e.g., YouTube), and multi-party human-machine interactions (e.g., in the world of Internet of things (IoT)), where speech overlapping is commonly observed. Over the decades, many attempts have been made to attack this problem. Before the deep learning era, the most popular technique was \acf{CASA} \cite{CASA-cooke2005,CASA-ellis1996}. In this approach, certain segmentation rules based on perceptual grouping cues \cite{PerceptualCuesInCASA-wertheimer1938} are (often semi-manually) designed to operate on low-level features to estimate a time-frequency mask that isolates the signal components belonging to different speakers. This mask is then used to reconstruct the signal. \acf{NMF} \cite{sparseNMF-schmidt2006,NMF-SpeechSep-smaragdis2007,SparseNMF-le2015} is another popular technique which aims to learn a set of non-negative bases that can be used to estimate mixing factors during evaluation. Both CASA and NMF led to very limited success in separating sources in multi-talker mixed speech \cite{MonauralSpeechSepChallenge-Cooke2010}. The most successful technique before the deep learning era is the model based approach \cite{IBM-SuperHuman-kristjansson2006,SpeechSepWithFactorialHMM-virtanen2006,SpeechSepWithAdaptedModel-weiss2007}, such as factorial GMM-HMM \cite{FactorialHMM-ghahramani1997}, that models the interaction between the target and competing speech signals and their temporal dynamics. Unfortunately this model assumes and only works under closed-set speaker condition. Motivated by the success of deep learning techniques in single-talker \ac{ASR} \cite{PretrainVSFineTune-Yu2010,CD-DNN-HMM-dahl2012,CD-DNN-HMM-SWB-seide2011,DNN4ASR-hinton2012}, researchers have developed many deep learning techniques for speech separation in recent years. Typically, networks are trained based on parallel sets of mixtures and their constituent target sources \cite{SpeechSepTrainingTargets-wang2014,SpeechEnhanceWithDNN-xu2014,SpeechSepWithLSTM-weninger2015,JointMaskDNN-Huang2015}. The networks are optimized to predict the source belonging to the target class, usually for each time-frequency bin. Unfortunately, these works often focus on, and only work for, separating speech from (often challenging) background noise (or music) because speech has very different characteristics than noise/music. Note that there are indeed works that are aiming at separating multi-talker mixed speech (e.g. \cite{JointMaskDNN-Huang2015}). However, these works rely on speaker-dependent models by assuming that the (often few) target speakers are known during training. The difficulty in speaker-independent multi-talker speech separation\linebreak comes from the label ambiguity or permutation problem (which will be described in Section~\ref{sec:problem1}). Only two deep learning based works \cite{SingleChannelSep-Weng2015,DeepClustering-hershey2015,DeepClustering2-isik2016} have tried to address and solve this harder problem. In Weng et al. \cite{SingleChannelSep-Weng2015}, which achieved the best result on the dataset used in 2006 monaural speech separation and recognition challenge \cite{MonauralSpeechSepChallenge-Cooke2010}, the instantaneous energy was used to solve the label ambiguity problem and a two-speaker joint-decoder with speaker switching penalty was used to separate and trace speakers. This approach tightly couples with the decoder and is difficult to scale up to more than two speakers due to the way labels are determined. Hershey et al. \cite{DeepClustering-hershey2015,DeepClustering2-isik2016} made significant progress with their \acf{DPCL} technique. In their work, they trained an embedding for each time-frequency bin to optimize a segmentation (clustering) criterion. During evaluation, each time-frequency bin was first mapped into the embedding space upon which a clustering algorithm was used to generate a partition of the time-frequency bins. Impressively, their systems trained on two-talker mixed-speech perform well on three-talker mixed-speech. However, in their approach it is assumed that each time-frequency bin belongs to only one speaker (i.e., a partition) due to the clustering step. Although this is often a good approximation, it is known to be sub-optimal. Furthermore, their approach is hard to combine with other techniques such as complex-domain separation. In this paper, we propose a novel training criterion, named \acf{PIT}, for speaker independent multi-talker speech separation. Most prior arts treat speech separation as either a multi-class regression problem or a segmentation (or clustering) problem. PIT, however, considers it a \emph{separation} problem (as it should be) by minimizing the separation error. More specifically, PIT first determines the best output-target assignment and then minimizes the error given the assignment. This strategy, which is directly implemented inside the network structure, elegantly solves the long-lasting label permutation problem that has prevented progress on deep learning based techniques for speech separation. We evaluated PIT on the WSJ0 and Danish mixed-speech separation tasks. Experimental results indicate that PIT compares favorably to NMF, CASA, and DPCL and generalizes well over unseen speakers and languages. In other words, through the training process PIT learns acoustic cues for source separation, which are both speaker and language independent, similar to humans. Since PIT is simple to implement and can be easily integrated and combined with other advanced techniques we believe improvements built upon PIT can eventually solve the cocktail-party problem. \section{Monaural Speech Separation}\label{sec:problem1} The goal of monaural speech separation is to estimate the individual source signals in a linearly mixed, single-microphone signal, in which the source signals overlap in the time-frequency domain. Let us denote the \(S\) source signal sequences in the time domain as \(\mathbf{x}_s(t), s=1,\cdots,S\) and the mixed signal sequence as \(\mathbf{y}(t)=\sum_{s=1}^{S} \mathbf{x}_s(t)\). The corresponding \acf{STFT} of these signals are \(\mathbf{X}_s(t,f)\) and \(\mathbf{Y}(t,f)=\sum_{s=1}^{S} \mathbf{X}_s(t,f)\), respectively, for each time \(t\) and frequency \(f\). Given \(\mathbf{Y}(t,f)\), the goal of monaural speech separation is to recover each source \(\mathbf{X}_s(t,f)\). In a typical setup, it is assumed that only STFT magnitude spectra is available. The phase information is ignored during the separation process and is used only when recovering the time domain waveforms of the sources. Obviously, given only the magnitude of the mixed spectrum \(|\mathbf{Y}(t,f)|\), the problem of recovering \(|\mathbf{X}_s(t,f)|\) is ill-posed, as there are an infinite number of possible \(|\mathbf{X}_s(t,f)|\) combinations that lead to the same \(|\mathbf{Y}(t,f)|\). To overcome this core problem, the system has to learn from some training set \(\mathbb{S}\) that contains pairs of \(|\mathbf{Y}(t,f)|\) and \(|\mathbf{X}_s(t,f)|\) to look for regularities. More specifically, we train a deep learning model \(g(\cdot)\) such that \(g\left(f(|\mathbf{Y}|\right);\theta)={|\tilde{\mathbf{X}}_s|, s=1,\cdots,S}\), where \(\theta\) is a model parameter vector, and \(f(|\mathbf{Y}|)\) is some feature representation of \(|\mathbf{Y}|\). For simplicity and clarity we have omitted, and will continue to omit, time-frequency indexes when there is no ambiguity. It is well-known (e.g., \cite{SpeechSepTrainingTargets-wang2014}) that better results can be achieved if, instead of estimating \(|\mathbf{X}_s|\) directly, we first estimate a set of masks \(\mathbf{M}_s(t,f)\) using a deep learning model \(h\left(f(|\mathbf{Y}|);\theta \right)=\tilde{\mathbf{M}}_s(t,f)\) with the constraint that \(\tilde{\mathbf{M}}_s(t,f) \geq 0\) and \(\sum_{s=1}^S \tilde{\mathbf{M}}_s(t,f) = 1\) for all time-frequency bins \((t,f)\). This constraint can be easily satisfied with the softmax operation. We then estimate \(|\mathbf{X}_s|\) as \(|\tilde{\mathbf{X}}_s| = \tilde{\mathbf{M}}_s \circ |\mathbf{Y}| \), where \( \circ\) is the element-wise product of two operands. This strategy is adopted in this study. \pagebreak Note that since we first estimate masks, the model parameters can be optimized to minimize the \acf{MSE} between the estimated mask \(\tilde{\mathbf{M}}_s\) and the \acf{IRM} \(\mathbf{M}_s=\frac{|\mathbf{X}_s|}{|\mathbf{Y}|}\), \[J_m=\frac{1}{T \times F \times S}\sum_{s=1}^S \|\tilde{\mathbf{M}}_s - \mathbf{M}_s\|^2,\] where $T$ and $F$ denote the number of time frames and frequency bins, respectively. This approach comes with two problems. First, in silence segments, \(|\mathbf{X}_s|=0\) and \(|\mathbf{Y}|=0\), so that \(\mathbf{M}_s\) is not well defined. Second, what we really care about is the error between the estimated magnitude and the true magnitude of each source, while a smaller error on masks may not lead to a smaller error on magnitude. To overcome these limitations, recent works \cite{SpeechSepTrainingTargets-wang2014} directly minimize the \ac{MSE} \[J_x=\frac{1}{T \times F \times S}\sum_{s=1}^S \|\tilde{|\mathbf{X}}_s| - |\mathbf{X}_s|\|^2\] between the estimated magnitude and the true magnitude. Note that in silence segments \(|\mathbf{X}_s|=0\) and \(|\mathbf{Y}|=0\), and so the accuracy of mask estimation does not affect the training criterion for those segments. In this study, we estimate masks $\tilde{\mathbf{M}}_s$ which minimize \(J_x\). \section{Permutation Invariant Training}\label{sec:train} \begin{figure}[ht] \centering \includegraphics[width=1.0\linewidth]{figures/figC/Model.pdf} \caption{The two-talker speech separation model with permutation invariant training.}\label{fig:modelpit} \end{figure} Except DPCL \cite{DeepClustering-hershey2015,DeepClustering2-isik2016}, all other recent speech separation works treat the separation problem as a multi-class regression problem. In their architecture, $N$ frames of feature vectors of the mixed signal \(|\mathbf{Y}|\) are used as the input to deep learning models, such as \acfp{DNN}, \acfp{CNN}, and Long Short-Term Memory\,(LSTM) \acfp{RNN}, to generate one (often the center) frame of masks for each talker. These masks are then used to construct one frame of single-source speech \(|\tilde {\mathbf{X}}_1|\) and \(|\tilde {\mathbf{X}}_2|\), for source 1 and 2, respectively. During training we need to provide the correct reference (or target) magnitude \(|\mathbf{X}_1|\) and \(|\mathbf{X}_2|\) to the corresponding output layers for supervision. Since the model has multiple output layers, one for each mixing source, and they depend on the same input mixture, reference assigning can be tricky especially if the training set contains many utterances spoken by many speakers. This problem is referred to as the label ambiguity (or permutation) problem in \cite{SingleChannelSep-Weng2015,DeepClustering-hershey2015}. Due to this problem, prior arts perform poorly on speaker-independent multi-talker speech separation. It was believed that speaker-independent multi-talker speech separation is not feasible \cite{SpeechSepTutorial-wang2016}. The solution proposed in this work is illustrated in Figure~\ref{fig:modelpit}. There are two key inventions in this novel model: permutation invariant training and segment-based decision making. In our new model the reference source streams are given as a set instead of an ordered list. In other words, the same training result is obtained, no matter in which order these sources are listed. This behavior is achieved with PIT highlighted inside the dashed rectangular in Figure~\ref{fig:modelpit}. In order to associate references to the output layers, we first determine the (total number of \(S!\)) possible assignments between the references and the estimated sources. We then compute the total MSE for each assignment, which is defined as the combined pairwise MSE between each reference \(|\mathbf{X}_s|\) and the estimated source \(|\tilde {\mathbf{X}}_s|\). The assignment with the least total MSE is chosen and the model is optimized to reduce this particular MSE. In other words we simultaneously conduct label assignment and error evaluation. Similar to the prior arts, PIT uses as input \(N\) successive frames (i.e., an input {\em meta-frame}) of features to exploit the contextual information. Different from the prior arts, the output of the PIT is also a window of frames. With PIT, we directly minimize the separation error at the meta-frame level. Although the number of speaker assignments is factorial in the number of speakers, the pairwise MSE computation is only quadratic, and more importantly the MSE computation can be completely ignored during evaluation. During inference, the only information available is the mixed speech. Speech separation can be directly carried out for each input meta-frame, for which an output meta-frame with \(M\) frames of speech is estimated for each stream. The input meta-frame is then shifted by one or more frames. Due to the PIT training criterion, output-to-speaker assignment may change across frames. In the simplest setup, we can just assume they do not change when reconstructing sources. Better performance may be achieved if a speaker-tracing algorithm is applied on top of the output of the network. Once the relationship between the outputs and source streams are determined for each output meta-frame, the separated speech can be estimated, taking into account all meta-frames by, for example, averaging the same frame across meta-frames. \section{Experimental Results} \label{sec:exp1} \subsection{Datasets} \label{subsec:datasets1} We evaluated PIT on the WSJ0-2mix and Danish-2mix datasets. The WSJ0-2mix dataset was introduced in \cite{DeepClustering-hershey2015} and was derived from WSJ0 corpus \cite{wsj0}. The 30h training set and the 10h validation set contains two-speaker mixtures generated by randomly selecting speakers and utterances from the WSJ0 training set si\_tr\_s, and mixing them at various signal-to-noise ratios (SNRs) uniformly chosen between 0 dB and 5 dB. The 5h test set was similarly generated using utterances from 16 speakers from the WSJ0 validation set si\_dt\_05 and evaluation set si\_et\_05. The Danish-2mix dataset was constructed from the Danish corpus \cite{dkCorpus}, which consists of approximately 560 speakers each speaking 312 utterances with average utterance duration of approximately 5 sec. The dataset was constructed by randomly selecting a set of 45 male and 45 female speakers from the corpus, and then allocating 232, 40, and 40 utterances from each speaker to generate mixed speech in the training, validation and \acf{CC} (seen speaker) test set, respectively. 40 utterances from each of another 45 male and 45 female speakers were randomly selected to construct the \acf{OC} (unseen speaker) test set. Speech mixtures were constructed in the way similar to the WSJ0-2mix dataset, but all mixed with 0 dB - the hardest condition. We constructed 10k and 1k mixtures in total in the training and validation set, respectively, and 1k mixtures for each of the CC and OC test sets. The Danish-3mix (three-talker mixed speech) dataset was constructed similarly. In this study we focus on the WSJ0-2mix dataset so that we can directly compare PIT with published state-of-the-art results obtained using other techniques. \subsection{Models} Our models were implemented using the \acf{CNTK} \cite{CNTK2014}. The feed-forward DNN (denoted as DNN) has three hidden layers each with 1024 ReLU units. In (inChannel, outChannel)-(strideW, strideH) format, the CNN model has one $(1,64)-(2,2)$, four $(64,64)-(1,1)$, one $(64,128)-(2,2)$, two $(128,128)-(1,1)$, one $(128,256)-(2,2)$, and two $(256,256)-(1,1)$ convolution layers with $3 \times 3$ kernels, a pooling layer and a 1024-unit ReLU layer. The input to the models is the stack (over multiple frames) of the 257-dim STFT spectral magnitude of the speech mixture, computed using STFT with a frame size of 32ms and 16ms shift. There are $S$ output streams for $S$-talker mixed speech. Each output stream has a dimension of $257 \times M$, where $M$ is the number of frames in the output meta-frame. In our study, the validation set is only used to control the learning rate. \subsection{Training Behavior} \begin{figure}[ht] \centering \centerline{\includegraphics[width=1\linewidth]{figures/figC/mse_wsj0.pdf}} \caption{MSE over epochs on the Danish (left) and WSJ0 (right) training and validation sets with conventional training and PIT.}\label{fig:mse1} \end{figure} In Figure~\ref{fig:mse1} we plotted the DNN training progress as measured by the MSE on the training and validation set with conventional training and PIT on the mixed speech datasets described in subsection \ref{subsec:datasets1}. From the figure we can see clearly that the validation MSE hardly decreases with the conventional approach due to the label permutation problem discussed in \cite{SingleChannelSep-Weng2015,DeepClustering-hershey2015}. In contrast, training converges quickly to a much better MSE for both two- and three-talker mixed speech when PIT is used. \subsection{Signal-to-Distortion Ratio Improvement} We evaluated PIT on its potential to improve the \acf{SDR} \cite{vincent_performance_2006}, a metric widely used to evaluate speech enhancement performance. \begin{table}[t] \caption{SDR improvements (dB) for different separation methods on the WSJ0-2mix dataset.} \label{tab:WSJ0-2mix} \centering \resizebox{0.65\textwidth}{!}{% \begin{tabular}{l|c|cc|cc} \midrule \midrule Method & Input\textbackslash Output & \multicolumn{2}{c|} {Opt. Assign} & \multicolumn{2}{c} {Def. Assign}\\ & window & CC & OC & CC & OC \\ \midrule Oracle NMF \cite{DeepClustering-hershey2015} & - & - & - & 5.1 & - \\ CASA \cite{DeepClustering-hershey2015} & - & - & - & 2.9 & 3.1 \\ DPCL \cite{DeepClustering-hershey2015} & 100\textbackslash100 & 6.5 & 6.5& 5.9 & 5.8 \\ DPCL+ \cite{DeepClustering2-isik2016} & 100\textbackslash100 & - & - & - & 10.3 \\ \midrule PIT-DNN & 101\textbackslash101 & 6.2 & 6.0 & 5.3 & 5.2 \\ PIT-DNN & 51\textbackslash51 & 7.3 & 7.2 & \bf{5.7} & \bf{5.6} \\ PIT-DNN & 41\textbackslash7 & 10.1 & 10.0 & -0.3 & -0.6 \\ PIT-DNN & 41\textbackslash5 & \bf{10.5} & \bf{10.4} & -0.6 & -0.8 \\ \midrule PIT-CNN & 101\textbackslash101 & 8.4 & 8.6 & \bf{7.7} & \bf{7.8} \\ PIT-CNN & 51\textbackslash51 & 9.6 & 9.7 & 7.5 & 7.7 \\ PIT-CNN & 41\textbackslash7 & 10.7 & 10.7 & -0.6 & -0.7 \\ PIT-CNN & 41\textbackslash5 & \bf{10.9} & \bf{10.9} & -0.8 & -0.9 \\ \midrule IRM & - & 12.3 & 12.5 & 12.3 & 12.5 \\ \midrule \midrule \end{tabular} } \end{table} In Table~\ref{tab:WSJ0-2mix} we summarized the SDR improvement in dB from different separation configurations for two-talker mixed speech in CC and OC. In these experiments each frame was reconstructed by averaging over all output meta-frames that contain the same frame. In the default assignment setup it is assumed that there is no output-speaker switch across frames (which is not true). This is the improvement achievable using PIT without any speaker tracing. In the optimal assignment setup, the output-speaker assignment for each output meta-frame is determined based on mixing streams. This reflects the separation performance within each segment (meta-frame) and is the improvement achievable when the speakers are correctly traced. The gap between these two values indicates the contribution from speaker tracing. As a reference, we also provided the IRM result which is the oracle and upper bound achievable on this task. From the table we can make several observations. First, without speaker tracing (def. assign) PIT can achieve similar and better performance than the original DPCL \cite{DeepClustering-hershey2015}, respectively, with DNN and CNN, but under-performs the more complicated DPCL+ \cite{DeepClustering2-isik2016}. Note that, PIT is much simpler than even the original (simpler) DPCL and we did not fine-tune architectures and learning procedures as done in \cite{DeepClustering2-isik2016}. Second, as we reduce the output window size we can improve the separation performance within each window and achieve better SDR improvement if speakers are correctly traced (opt. assign). However, when output window size is reduced, the output-speaker assignment changes more frequently as indicated by the poor default assignment performance. Speaker tracing thus becomes more important given the larger gap between the opt. assign and def. assign. Fourth, PIT generalizes well on unseen speakers since the performances on the open and closed conditions are very close. Fifth, powerful models such as CNN consistently outperforms DNNs but the gain diminishes when the output window size is small. \begin{table}[t] \caption{SDR improvements (dB) based on optimal assignment for DNNs trained with Danish-2mix.} \label{tab:twotalker} \centering \resizebox{0.5\textwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule Method & \begin{tabular}[c]{@{}c@{}}Input\textbackslash Output\\ window\end{tabular} & CC & OC & \begin{tabular}[c]{@{}c@{}}WSJ0\\ OC\end{tabular} \\ \midrule IRM & - & 17.2 & 17.3 & 13.2 \\ \midrule PIT-DNN & 101\textbackslash101 & 9.00 & 8.61 & 4.29 \\ PIT-DNN & 61\textbackslash61 & 9.87 & 9.44 & 5.17 \\ PIT-DNN & 31\textbackslash31 & 11.1 & 10.7 & 6.18 \\ PIT-DNN & 31\textbackslash7 & 14.0 & 13.8 & 9.03 \\ PIT-DNN & 31\textbackslash5 & 14.1 & 13.9 & 9.29 \\ \midrule \midrule \end{tabular} } \end{table} In Table~\ref{tab:twotalker} we summarized the SDR improvement in dB with optimal assignment from different configurations for DNNs trained on Danish-2mix. We also report SDR improvement using a dataset constructed identical to Danish-2mix but based on the si\_tr\_s data from WSJ0. Besides the findings obtained in Table~\ref{tab:WSJ0-2mix}, an interesting observation is that although the system has never seen English speech, it performs remarkably well on this WSJ0 dataset when compared to the IRM (oracle) values. These results indicate that the separation ability learned with PIT generalizes well not only across speakers but also across languages. \section{Conclusion and Discussion}\label{sec:conclusion1} In this paper, we have described a novel permutation invariant training technique for speaker-independent multi-talker speech separation. To the best of our knowledge this is the first successful work that employs the separation view (and criterion) of the task\footnote{Hershey et al. \cite{DeepClustering-hershey2015} tried PIT (called permutation free training in their paper) but failed to make it work. They retried after reading the preprint of this work and now got positive results as well.}, instead of the multi-class regression or segmentation view that are used in prior arts. This is a big step towards solving the important cocktail-party problem in a real-world setup, where the set of speakers are unknown during the training time. Our experiments on two-talker mixed speech separation tasks demonstrate that PIT trained models generalize well to unseen speakers and languages. Although our results are mainly on two-talker separation tasks, PIT can be easily and effectively extended to the three-talker case as shown in figure \ref{fig:mse1}. In this paper we focused on PIT - the key technique that enables training for the separation of multi-talker mixed speech. PIT is much simpler yet performs better than the original DPCL \cite{DeepClustering-hershey2015} that contains separate embedding and clustering stages. Since PIT, as a training technique, can be easily integrated and combined with other advanced techniques, it has great potential for further improvement. We believe improvements can come from work in the following areas: First, due to the change of output-speaker assignment across frames, there is a big performance gap between the optimal output-speaker assignment and the default assignment, especially in the same-gender case and when the output window size is small. This gap can be reduced with separate speaker tracing algorithms that exploit the overlapping frames and speaker characteristics (e.g., similarity) in output meta-frames. It is also possible to train an end-to-end system in which speaker tracing is directly built into the model, e.g., by applying PIT at utterance level. We will report these results in other papers. Second, we only explored simple DNN/CNN structures in this work. More powerful models such as bi-directional LSTMs, CNNs with deconvolution layers, or even just larger models may further improve the performance. Hyper-parameter tuning will also help and sometimes lead to significant performance gain. Third, in this work we reconstructed source streams from spectral magnitude only. Unlike DPCL, PIT can be easily combined with reconstruction techniques that exploit complex-valued spectrum to further boost performance. Fourth, the acoustic cues learned by the model are largely speaker and language independent. It is thus possible to train a universal speech separation model using speech in various speakers, languages, and noise conditions. Finally, although we focused on monaural speech separation in this work, the same technique can be deployed in the multi-channel setup and combined with techniques such as beamforming due to its flexibility. In fact, since beamforming and PIT separate speech using different information, they complement with each other. For example, speaker tracing may be much easier when beamforming is available. \section{Acknowledgment} We thank Dr. John Hershey at MERL and Zhuo Chen at Columbia University for sharing the WSJ0-2mix data list and for valuable discussions. \section{Introduction}\label{sec:intro4} Having a conversation in a complex acoustic environment, with multiple noise sources and competing background speakers, is a task humans are remarkably good at \cite{haykin_cocktail_2005,bronkhorst_cocktail_2000}. The problem that humans solve when they focus their auditory attention towards one audio signal in a complex mixture of signals is commonly known as the cocktail party problem \cite{haykin_cocktail_2005,bronkhorst_cocktail_2000}. Despite intense research for more than half a century, a general machine based solution to the cocktail party problem is yet to be discovered \cite{cherry_experiments_1953,bronkhorst_cocktail_2000,haykin_cocktail_2005,cooke_monaural_2010}. A machine solution to the cocktail party problem is highly desirable for a vast range of applications. These include automatic meeting transcription, automatic captioning for audio/video recordings (e.g. YouTube), multi-party human-machine interaction (e.g. in the world of Internet of things (IoT)), and advanced hearing aids, where overlapping speech is commonly encountered. Since the cocktail party problem was initially formalized \cite{cherry_experiments_1953}, a large number of potential solutions have been proposed \cite{divenyi_speech_2005}, and the most popular techniques originate from the field of Computational Auditory Scene Analysis\;(CASA) \cite{ellis_prediction-driven_1996,cooke_modelling_2005,wang_computational_2006,shao_model-based_2006,hu_unsupervised_2013}. In CASA, different segmentation and grouping rules are used to group Time-Frequency\;(T-F) units that are believed to belong to the same speaker. The rules are typically hand-engineered and based on heuristics such as pitch trajectory, common onset/offset, periodicity, etc. The grouped T-F units are then used to extract a particular speaker from the mixture signal. Another popular technique for multi-talker speech separation is Non-negative Matrix Factorization\;(NMF) \cite{schmidt_single-channel_2006,smaragdis_convolutive_2007,roux_sparse_2015,lee_algorithms_2000}. The NMF technique uses non-negative dictionaries to decompose the spectrogram of the mixture signal into speaker specific activations, and from these activations an isolated target signal can be approximated using the dictionaries. For multi-talker speech separation, both CASA and NMF have led to limited success \cite{cooke_monaural_2010,divenyi_speech_2005} and the most successful techniques, before the deep learning era, are based on probabilistic models \cite{kristjansson_super-human_2006,virtanen_speech_2006,stark_source-filter-based_2011}, such as factorial GMM-HMM \cite{ghahramani_factorial_1997}, that model the temporal dynamics and the complex interactions of the target and competing speech signals. Unfortunately, these models assume and only work under closed-set speaker conditions, i.e. the identity of the speakers must be known \emph{a priori}. More recently, a large number of techniques based on deep learning \cite{goodfellow_deep_2016} have been proposed, especially for Automatic Speech Recognition\;(ASR) \cite{yu_roles_2010,dahl_context-dependent_2012,seide_conversational_2011,hinton_deep_2012,xiong_achieving_2016,saon_english_2017}, and speech enhancement \cite{wang_towards_2013,wang_training_2014,xu_experimental_2014,weninger_speech_2015,huang_joint_2015,chen_large-scale_2016,kolbaek_speech_2017,du_speech_2014,goehring_speech_2017}. Deep learning has also been applied in the context of multi-talker speech separation (e.g. \cite{huang_joint_2015}), although successful work has, similarly to NMF and CASA, mainly been reported for closed-set speaker conditions. The limited success in deep learning based speaker independent multi-talker speech separation is partly due to the label permutation problem\linebreak (which will be described in detail in Sec.~\ref{sec:PIT}). To the authors knowledge only four deep learning based works \cite{weng_deep_2015,hershey_deep_2016,chen_deep_2017,yu_permutation_2017} exist, that have tried to address and solve the harder speaker independent multi-talker speech separation task. In Weng \emph{et al.} \cite{weng_deep_2015}, which proposed the best performing system in the 2006 monaural speech separation and recognition challenge \cite{cooke_monaural_2010}, the instantaneous energy was used to determine the training label assignment, which alleviated the label permutation problem and allowed separation of unknown speakers. Although this approach works well for two-speaker mixtures, it is hard to scale up to mixtures of three or more speakers. Hershey \emph{et al.} \cite{hershey_deep_2016} have made significant progress with their Deep Clustering (DPCL) technique. In their work, a deep Recurrent Neural Network (RNN) is used to project the speech mixture into an embedding space, where T-F units belonging to the same speaker form a cluster. In this embedding space a clustering algorithm (e.g. K-means) is used to identify the clusters. Finally, T-F units belonging to the same clusters are grouped together and a binary mask is constructed and used to separate the speakers from the mixture signal. To further improve the model \cite{isik_single-channel_2016}, another RNN is stacked on top of the first DPCL RNN to estimate continuous masks for each target speaker. Although DPCL show good performance, the technique is potentially limited because the objective function is based on the affinity between the sources in the embedding space, instead of the separated signals themselves. That is, low proximity in the embedding space does not necessarily imply perfect separation of the sources in the signal space. Chen \emph{et al.} \cite{chen_deep_2017,chen_single_2017} proposed a related technique called Deep Attractor Network\;(DANet). Following DPCL, the DANet approach also learns a high-dimensional embedding of the mixture signals. Different from DPCL, however, it creates attractor points (cluster centers) in the embedding space, which attract the T-F units corresponding to each target speaker. The training is conducted in a way similar to the Expectation Maximization\;(EM) principle. The main disadvantage of DANet over DPCL is the added complexity associated with estimating attractor points during inference. Recently, we proposed the Permutation Invariant Training\;(PIT) technique% \footnote{In \cite{hershey_deep_2016}, a related permutation free technique, which is similar to PIT for exactly two-speakers, was evaluated with negative results and conclusion.} \cite{yu_permutation_2017} for attacking the speaker independent multi-talker speech separation problem and showed that PIT effectively solves the label permutation problem. However, although PIT solves the label permutation problem at training time, PIT does not effectively solve the permutation problem during inference, where the permutation of the separated signals at the frame-level is unknown. We denote the challenge of identifying this frame-level permutation, as the \emph{speaker tracing problem}. In this paper, we extend PIT and propose an utterance-level Permutation Invariant Training\;(uPIT) technique, which is a practically applicable, end-to-end, deep learning based solution for speaker independent multi-talker speech separation. Specifically, uPIT extends the frame-level PIT technique \cite{yu_permutation_2017} with an utterance-level training criterion that effectively eliminates the need for additional speaker tracing or very large input/output contexts, which is otherwise required by the original PIT \cite{yu_permutation_2017}. We achieve this using deep Long Short-Term Memory\;(LSTM) RNNs \cite{hochreiter_long_1997} that, during training, minimize the utterance-level separation error, hence forcing separated frames belonging to the same speaker to be aligned to the same output stream. This is unlike other techniques, such as DPCL and DANet, that require a distinct clustering step to separate speakers during inference. Furthermore, the computational cost associated with the uPIT training criterion is negligible compared to the computations required by the RNN during training and is zero during inference. We evaluated uPIT on the WSJ0 and Danish two- and three-talker mixed-speech separation tasks and found that uPIT outperforms techniques based on NMF and CASA, and compares favorably with DPCL and DANet. Furthermore, we show that models trained with uPIT generalize well to unseen speakers and languages, and finally, we found that a single model trained with uPIT can separate both two-speaker, and three-speaker speech mixtures. \pagebreak The rest of the paper is organized as follows. In Sec.~\ref{sec:problem} we describe the monaural speech separation problem. In Sec.~\ref{sec:mask} we extend popular optimization criteria used in separating single-talker speech from noises, to multi-talker speech separation tasks. In Sec.~\ref{sec:PIT} we discuss the label permutation problem and present the PIT framework. In Sec.~\ref{sec:integrated} we introduce uPIT and show how an utterance-level permutation criterion can be combined with PIT. We report series of experimental results in Sec.~\ref{sec:exp} and conclude the paper in Sec.~\ref{sec:conclusion}. \section{Monaural Speech Separation}\label{sec:problem} The goal of monaural speech separation is to estimate the individual source signals ${x}_s[n], \; s=1,2,\cdots,S$ in a linearly mixed single-microphone signal % \begin{equation} y[n]=\sum_{s=1}^{S} {x}_s[n], \end{equation} % based on the observed signal ${y}[n]$ only. % In real situations, the received signals may be reverberated, i.e., the underlying clean signals are filtered before being observed in the mixture. In this condition, we aim at recovering the reverberated source signals ${x}_s[n]$, i.e., we are not targeting the dereverberated signals. The separation is usually carried out in the T-F domain, in which the task can be cast as recovering the Short-Time discrete Fourier Transformation\;(STFT) of the source signals ${X}_s(t,f)$ for each time frame $t$ and frequency bin $f$, given the mixed speech % \begin{equation} \begin{split} {Y}(t,f) =\sum_{n=0}^{N-1} {y}[n+tL]w[n]\exp(-j2{\pi}nf/N), \end{split} \end{equation} where $w[n]$ is the analysis window of length $N$, the signal is shifted by an amount of $L$ samples for each time frame $t=0,1,\cdots,T-1$, and each frequency bin $f=0,1,\cdots,N-1$ is corresponding to a frequency of $(f/N)f_s$ [Hz] when the sampling rate is $f_s$ [Hz]. % From the estimated STFT ${\hat{X}}_s(t,f)$ of each source signal, an inverse Discrete Fourier Transform\;(DFT) % \begin{equation} {\hat{x}}_{s,t}[n] =\frac{1} {N} \sum_{f=0}^{N-1} \hat{X}_s(t,f)\exp(j2{\pi}nf/N) \end{equation} % can be used to construct estimated time-domain frames, and the overlap-add operation % \begin{equation} {\hat{x}_s}[n] =\sum_{t=0}^{T-1} v[n-tL] \hat{x}_{s,t}[n-tL] \end{equation} can be used to reconstruct the estimate $\hat{x}_s[n]$ of the original signal, where $v[n]$ is the synthesis window. In a typical setup, however, only the STFT magnitude spectrum $A_s(t,f) \triangleq |{X}_s(t,f)|$ is estimated from the mixture during the separation process, and the phase of the mixed speech is used directly, when recovering the time domain waveforms of the separated sources. This is because phase estimation is still an open problem in the speech separation setup \cite{williamson_complex_2016,erdogan_deep_2017}. % Obviously, given only the magnitude of the mixed spectrum, $R(t,f)\triangleq |{Y}(t,f)|$, the problem of recovering $A_s(t,f)$ is under-determined, as there are an infinite number of possible $A_s(t,f)$, $s=1, \dots ,S$ combinations that lead to the same $R(t,f)$. To overcome this problem, a supervised learning system has to learn from some training set $\mathbb{S}$ that contains corresponding observations of $R(t,f)$ and $A_s(t,f)$, $s=1, \dots ,S$. Let $\mathbf{a}_{s,i} = \left[ {{A_s}(i,1)} ,\; {{A_s}(i,2)} ,\; \dots\; {{A_s}(i,\frac{N}{2}+1)} \right]^T \in \mathbb{R}^{\frac{N}{2}+1}$ denote the single-sided magnitude spectrum for source $s$ at frame $i$. Furthermore, let $\mathbf{A}_s \in \mathbb{R}^{\left(\frac{N}{2}+1\right) \times T}$ be the single-sided magnitude spectrogram for source $s$ and all frames $i=1, \dots ,T$, defined as $\mathbf{A}_s = \left[\mathbf{a}_{s,1} ,\; \mathbf{a}_{s,2} ,\; \dots\;, \mathbf{a}_{s,T}\right]$. % % Similarly, let $\mathbf{r}_{i} = \left[ {{R}(i,1)} ,\; {{R}(i,2)} ,\; \dots\; {{R}(i,\frac{N}{2}+1)} \right]^T$ be the single-sided magnitude spectrum of the observed signal at frame $i$ and let $\mathbf{R} = \left[\mathbf{r}_{1} ,\; \mathbf{r}_{2} ,\; \dots\;, \mathbf{r}_{T}\right] \in \mathbb{R}^{\left(\frac{N}{2}+1\right) \times T}$ be the single-sided magnitude spectrogram for all frames $i=1, \dots ,T$. % Furthermore, let us denote a supervector $\mathbf{z}_{i} \hspace{-0.5mm} = \hspace{-1mm} \left[ \mathbf{a}_{1,i}^T , \mathbf{a}_{2,i}^T , \dots , \mathbf{a}_{S,i}^T \right]^T \hspace{-3mm} \in \mathbb{R}^{S\left(\frac{N}{2}+1\right)}$, consisting of the stacked source magnitude spectra for each source $s = 1, \dots, S$ at frame $i$ and let $\mathbf{Z} = \left[\mathbf{z}_{1} ,\; \mathbf{z}_{2} ,\; \dots\;, \mathbf{z}_{T}\right] \in \mathbb{R}^{S\left(\frac{N}{2}+1\right) \times T}$ denote the matrix of all $T$ supervectors. % % Finally, let $\mathbf{y}_{i} = \left[ {{Y}(i,1)} ,\; {{Y}(i,2)} ,\; \dots\; {{Y}(i,\frac{N}{2}+1)} \right]^T \in \mathbb{C}^{\frac{N}{2}+1}$ be the single-sided STFT of the observed mixture signal at frame $i$ and $\mathbf{Y} = \left[\mathbf{y}_{1} ,\; \mathbf{y}_{2} ,\; \dots\;, \mathbf{y}_{T}\right] \in \mathbb{C}^{\left(\frac{N}{2}+1\right) \times T} $ be the STFT of the mixture signal for all $T$ frames. % Our objective is then to train a deep learning model $g(\cdot)$, parameterized by a parameter set $\mathbf{\Phi}$, such that $g\left(d\left(\mathbf{Y}\right);\mathbf{\Phi}\right)=\mathbf{Z}$, where $d(\mathbf{Y})$ is some feature representation of the mixture signal: In a particularly simple situation, $d(\mathbf{Y}) = \mathbf{R}$, i.e., the feature representation is simply the magnitude spectrum of the observed mixture signal. It is possible to directly estimate the magnitude spectra $\mathbf{Z}$ of all sources using a deep learning model. However, it is well-known (e.g. \cite{wang_training_2014, erdogan_deep_2017}), that better results can be achieved if, instead of estimating $\mathbf{Z}$ directly, we first estimate a set of masks ${M_s}(t,f)$, $s=1, \dots ,S$. % % Let $\mathbf{m}_{s,i} = \left[ {{M_s}(i,1)} \;,\; {{M_s}(i,2)} \;,\; \dots\; {{M_s}(i,\frac{N}{2}+1)} \right]^T \in \mathbb{R}^{\frac{N}{2}+1}$ be the ideal mask (to be defined in detail in Sec.\;\ref{sec:mask}) for speaker $s$ at frame $i$, and let $\mathbf{M}_s = \left[\mathbf{m}_{s,1} ,\; \mathbf{m}_{s,2} ,\; \dots\;, \mathbf{m}_{s,T}\right] \in \mathbb{R}^{\left(\frac{N}{2}+1\right) \times T}$ be the ideal mask for all $T$ frames, % such that $\mathbf{A}_s = \mathbf{M}_s \circ \mathbf{R} $, where $\circ$ is the Hadamard product, i.e. element-wise product of two operands. % Furthermore, let us introduce the mask supervector $\mathbf{u}_{i} = \left[ \mathbf{m}_{1,i}^T \; \mathbf{m}_{2,i}^T \; \dots \; \mathbf{m}_{S,i}^T \right]^T \in \mathbb{R}^{S\left(\frac{N}{2}+1\right)}$ and the corresponding mask matrix $\mathbf{U} = \left[\mathbf{u}_{1} ,\; \mathbf{u}_{2} ,\; \dots\;, \mathbf{u}_{T}\right] \in \mathbb{R}^{S\left(\frac{N}{2}+1\right) \times T}$. % Our goal is then to find an estimate $\hat{\mathbf{U}}$ of $\mathbf{U}$, using a deep learning model, % $h\left(\mathbf{R};\mathbf{\Phi} \right)=\hat{\mathbf{U}}$. % Since, $\hat{\mathbf{U}} = \left[\hat{\mathbf{u}}_{1} ,\; \hat{\mathbf{u}}_{2} ,\; \dots\;, \hat{\mathbf{u}}_{T}\right]$ and $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{1,i}^T \; \hat{\mathbf{m}}_{2,i}^T \; \dots \; \hat{\mathbf{m}}_{S,i}^T \right]^T$, the model output is easily divided into output streams corresponding to the estimated masks for each speaker $\hat{\mathbf{m}}_{s,i}$, and their resulting magnitudes are estimated as $\hat{\mathbf{a}}_{s,i} = \hat{\mathbf{m}}_{s,i} \circ \mathbf{r}_{i}$. % The estimated time-domain signal for speaker $s$ is then computed as the inverse DFT of $\hat{\mathbf{a}}_{s,i}$ using the phase of the mixture signal $\mathbf{y}_i$. \section{Masks and Training Criteria}\label{sec:mask} % Since masks are to be estimated as an intermediate step towards estimating magnitude spectra of source signals, we extend in the following three popular masks defined for separating single-talker speech from noises to the multi-talker speech separation task at hand. \subsection{Ideal Ratio Mask} The Ideal Ratio Mask\;(IRM) \cite{wang_training_2014} for each source is defined as \begin{equation} {M}_s^{irm}(t,f) =\frac {|{X}_s(t,f)|} { \sum_{s=1}^{S} |{X}_s(t,f)|} . \end{equation} When the phase of $\mathbf{Y}$ is used for reconstruction, the IRM achieves the highest Signal to Distortion Ratio\;(SDR) \cite{vincent_performance_2006}, when all sources have the same phase, (which is an invalid assumption in general). % IRMs are constrained to $0 \leq {{M}}_s^{irm}(t,f) \leq 1$ and $\sum_{s=1}^S {{M}}_s^{irm}(t,f) = 1$ for all T-F units. This constraint can easily be satisfied using the softmax activation function. % Since $\mathbf{Y}$ is the only observed signal in practice and $\sum_{s=1}^{S} |{X}_s(t,f)|$ is unknown during separation, the IRM is not a desirable target for the problem at hand. Nevertheless, we report IRM results as an upper performance bound since the IRM is a commonly used training target for deep learning based monaural speech separation \cite{chen_large-scale_2016,kolbaek_speech_2017}. \subsection{Ideal Amplitude Mask} % Another applicable mask is the \ac{IAM} (known as FFT-mask in \cite{wang_training_2014}), or simply \ac{AM}, when estimated by a deep learning model. The IAM is defined as \begin{equation} {M}_s^{iam}(t,f) =\frac {|{X}_s(t,f)|} {|{Y}(t,f)|}. \end{equation} Through IAMs we can construct the exact $|{X}_s(t,f)|$ given the magnitude spectra of the mixed speech $|{Y}(t,f)|$. If the phase of each source equals the phase of the mixed speech, the IAM achieves the highest SDR. Unfortunately, as with the IRM, this assumption is not satisfied in most cases. IAMs satisfy the constraint that $0 \leq {{M}}_s^{iam}(t,f) \leq \infty$, although we found empirically that the majority of the T-F units are in the range of $0 \leq {{M}}_s^{iam}(t,f) \leq 1$. For this reason, softmax, sigmoid and ReLU are all possible output activation functions for estimating IAMs. \subsection{Ideal Phase Sensitive Mask} Both IRM and IAM do not consider phase differences between source signals and the mixture. This leads to sub-optimal results, when the phase of the mixture is used for reconstruction. % The \ac{IPSM} \cite{erdogan_phase-sensitive_2015,erdogan_deep_2017} \begin{equation} {M}_s^{ipsm}(t,f) =\frac {|{X}_s(t,f)|\cos(\theta_y(t,f)-\theta_s(t,f))} {|{Y}(t,f)|}, \end{equation} however, takes phase differences into consideration, where $\theta_y$ and $\theta_s$ are the phases of mixed speech ${Y}(t,f)$ and source ${X}_s(t,f)$, respectively. Due to the phase-correcting term, the IPSM sums to one, i.e. $\sum_{s=1}^S {{M}}_s^{ipsm}(t,f) = 1$. Note that since $|\cos(\cdot)| \leq 1$ the IPSM is smaller than the IAM, especially when the phase difference between the mixed speech and the source is large. Even-though the IPSM in theory is unbounded, we found empirically that the majority of the IPSM is in the range of $0 \leq {M}_s^{ipsm}(t,f) \leq 1$. Actually, in our study we have found that approximately $20\%$ of IPSMs are negative. However, those negative IPSMs usually are very close to zero. To account for this observation, we propose the \ac{INPSM}, which is defined as \begin{equation} {M}_s^{inpsm}(t,f) =max(0, {M}_s^{ipsm}(t,f)). \end{equation} For estimating the IPSM and INPSM, Softmax, Sigmoid, tanh, and ReLU are all possible activation functions, and similarly to the IAM, when the IPSM is estimated by a deep learning model we refer to it as \ac{PSM}. \subsection{Training Criterion} Since we first estimate masks, through which the magnitude spectrum of each source can be estimated, the model parameters can be optimized to minimize the \acf{MSE} between the estimated mask $\hat{M}_s$ and one of the target masks defined above as \begin{equation} J_m=\frac{1}{B}\sum_{s=1}^S \|\hat{\mathbf{M}}_s - \mathbf{M}_s\|_F^2, \end{equation} where $B=T \times N \times S$ is the total number of T-F units over all sources and $\|\cdot\|_F$ is the Frobenius norm. This approach comes with two problems. First, in silence segments, $|{X}_s(t,f)|=0$ and $|{Y}(t,f)|=0$, so that the target masks ${M}_s(t,f)$ are not well defined. Second, what we really care about is the error between the reconstructed source signal and the true source signal. To overcome these limitations, recent works \cite{wang_training_2014} directly minimize the MSE % \begin{equation} \begin{split} J_a & =\frac{1}{B}\sum_{s=1}^S \| \hat{\mathbf{A}}_s - \mathbf{A}_s \|_F^2 \\ & =\frac{1}{B}\sum_{s=1}^S \| \hat{\mathbf{M}}_s \circ \mathbf{R} - \mathbf{A}_s \|_F^2 \end{split} \label{eq:am} \end{equation} % % between the estimated magnitude, i.e. $\hat{\mathbf{A}}_s = \hat{\mathbf{M}}_s \circ \mathbf{R}$ and the true magnitude $\mathbf{A}_s$. Note that in silence segments $A_s(t,f)=0$ and $R(t,f)=0$, so the accuracy of mask estimation does not affect the training criterion for those segments. % Furthermore, using Eq.\;\eqref{eq:am} the IAM is estimated as an intermediate step. When the PSM is used, the cost function becomes \begin{equation} \begin{split} J_{psm} = \frac{1}{B}\sum_{s=1}^S \|\hat{\mathbf{M}}_s \circ \mathbf{R} - \mathbf{A}_s \circ \cos(\boldsymbol{\theta}_y - \boldsymbol{\theta}_s)\|_F^2. \end{split} \label{eq:psm} \end{equation} In other words, using PSMs is as easy as replacing the original training targets with the phase discounted targets. % Furthermore, when Eq.\;\eqref{eq:psm} is used as a cost function, the IPSM is the upper bound achievable on the task \cite{erdogan_deep_2017}. \section{Permutation Invariant Training}\label{sec:PIT} \subsection{Conventional Multi-Talker Separation} A natural, and commonly used, approach for deep learning based speech separation is to cast the problem as a multi-class \cite{huang_joint_2015,tu_deep_2014,weng_deep_2015} regression problem as depicted in Fig.~\ref{fig:conventional}. For this conventional two-talker separation model, $J$ frames of feature vectors of the mixed signal $\mathbf{Y}$ are used as the input to some deep learning model e.g. a feed-forward Deep Neural Network\,(DNN), Convolutional Neural Network\;(CNN), or LSTM RNN, to generate $M$ frames of masks for each talker. % Specifically, if $M=1$, the output of the model can be described by the vector $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{1,i}^T \; \hat{\mathbf{m}}_{2,i}^T \right]^T$ and the sources are separated as $\hat{\mathbf{a}}_{1,i} = \hat{\mathbf{m}}_{1,i} \circ \mathbf{r}_{i}$ and $\hat{\mathbf{a}}_{2,i} = \hat{\mathbf{m}}_{2,i} \circ \mathbf{r}_{i}$, for sources $s = 1,2$, respectively. \begin{figure}[ht] \centering \includegraphics[width=0.9\linewidth]{figures/figD/Conventional.pdf} \caption{The conventional two-talker speech separation model.}\label{fig:conventional} \end{figure} % \subsection{The Label Permutation Problem} During training, the error (e.g. using Eq.\;\eqref{eq:psm}) between the clean magnitude spectra $\mathbf{a}_{1,i}$ and $\mathbf{a}_{2,i}$ and their estimated counterparts $\hat{\mathbf{a}}_{1,i}$ and $\hat{\mathbf{a}}_{2,i}$ needs to be computed. % However, since the model estimates the masks $\hat{\mathbf{m}}_{1,i}$ and $\hat{\mathbf{m}}_{2,i}$ simultaneously, and they depend on the same input mixture, it is unknown in advance whether the resulting output vector $\hat{\mathbf{u}}_{i}$ is ordered as $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{1,i}^T \; \hat{\mathbf{m}}_{2,i}^T \right]^T$ or $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{2,i}^T \; \hat{\mathbf{m}}_{1,i}^T \right]^T$. That is, the permutation of the output masks is unknown. A na\"{i}ve approach to train a deep learning separation model, without exact knowledge about the permutation of the output masks, is to use a constant permutation as illustrated by Fig.~\ref{fig:conventional}. Although such a training approach works for simple cases e.g. female speakers mixed with male speakers, in which case \emph{a priori} convention can be made that e.g. the first output stream contains the female speaker, while the second output stream is paired with the male speaker, the training fails if the training set consists of many utterances spoken by many speakers of both genders. This problem is referred to as the label permutation (or ambiguity) problem in \cite{weng_deep_2015,hershey_deep_2016}. Due to this problem, prior arts perform poorly on speaker independent multi-talker speech separation. \subsection{Permutation Invariant Training} Our solution to the label permutation problem is illustrated in Fig.~\ref{fig:model} and is referred to as Permutation Invariant Training\;(PIT) \cite{yu_permutation_2017}. % \begin{figure}[ht] \centering \includegraphics[width=0.9\linewidth]{figures/figD/PIT.pdf} \caption{The two-talker speech separation model with permutation invariant training.}\label{fig:model} \end{figure} In the model depicted in Fig.~\ref{fig:model} (and unlike the conventional model in Fig.\;\ref{fig:conventional}) the reference signals are given as \emph{a set} instead of an ordered list. In other words, the same training result is obtained, no matter in which order these references are listed. This behavior is achieved with PIT highlighted inside the dashed rectangle in Fig.~\ref{fig:model}. Specifically, following the notation from Sec.\;\ref{sec:problem}, we associate the reference signals for speaker one and two, i.e. $\mathbf{a}_{1,i}$ and $\mathbf{a}_{2,i}$, to the output masks $\hat{\mathbf{m}}_{1,i}$ and $\hat{\mathbf{m}}_{2,i}$, by computing the (total of $S^2$) pairwise MSEs between each reference signal $\mathbf{a}_{s,i}$ and each estimated source $\hat {\mathbf{a}}_{s,i}$. We then determine the (total of $S!$) possible permutations between the references and the estimated sources, and compute the \emph{per-permutation-loss} for each permutation. % That is, for the two-speaker case in Fig.~\ref{fig:model} we compute the \emph{per-permutation-loss} for the two candidate output vectors $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{1,i}^T \; \hat{\mathbf{m}}_{2,i}^T \right]^T$ and $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{2,i}^T \; \hat{\mathbf{m}}_{1,i}^T \right]^T$. % The permutation with the lowest MSE is chosen and the model is optimized to reduce this least MSE. In other words, we simultaneously conduct label assignment and error evaluation. Similarly to prior arts, we can use $J$, and $M$ successive input, and output frames, respectively, (i.e., a {\em meta-frame}) to exploit the contextual information. % Note that only $S^2$ pairwise MSEs are required (and not $S!$) to compute the \emph{per-permutation-loss} for all $S!$ possible permutations. Since $S!$ grows much faster than $S^2$, with respect to $S$, and the computational complexity of the pairwise MSE is much larger than the \emph{per-permutation-loss} (sum of pairwise MSEs), PIT can be used with a large number of speakers, i.e. $S\gg2$. During inference, the only information available is the mixed speech, but speech separation can be directly carried out for each input meta-frame, for which an output meta-frame with $M$ frames of speech is estimated. Due to the PIT training criterion, the permutation will stay the same for frames inside the same output meta-frame, but may change across output meta-frames. % In the simplest setup, we can just assume that permutations do not change across output meta-frames, when reconstructing the target speakers. However, this usually leads to unsatisfactory results as reported in \cite{yu_permutation_2017}. To achieve better performance, speaker tracing algorithms, that identify the permutations of output meta-frames with respect to the speakers, need to be developed and integrated into the PIT framework or applied on top of the output of the network. % \section{Utterance-Level PIT}\label{sec:integrated} % Several ways exist for identifying the permutation of the output meta-frames, i.e. solving the tracing problem. % For example, in CASA a related problem referred to as the Sequential Organization Problem has been addressed using a model-based sequential grouping algorithm \cite{shao_model-based_2006}. Although moderately successful for co-channel speech separation, where prior knowledge about the speakers is available, this method is not easily extended to the speaker independent case with multiple speakers. Furthermore, it is not easily integrated into a deep learning framework. A more straight-forward approach might be to determine a change in permutation by comparing MSEs for different permutations of output masks measured on the overlapping frames of adjacent output meta-frames. However, this approach has two major problems. First, it requires a separate tracing step, which may complicate the model. Second, since the permutation of later frames depends on that of earlier frames, one incorrect assignment at an earlier frame would completely switch the permutation for all frames after it, even if the assignment decisions for the remaining frames are all correct. % In this work we propose utterance-level Permutation Invariant Training (uPIT), a simpler yet more effective approach to solve the tracing problem and the label permutation problem than original PIT. Specifically, we extend the frame-level PIT technique with the following utterance-level cost function: % % \begin{equation} J_{\phi^\ast} = \frac{1}{B}\sum_{s=1}^S \|\hat{\mathbf{M}}_s \circ \mathbf{R} - \mathbf{A}_{\phi^\ast(s)} \circ \cos( \boldsymbol{\theta}_y - \boldsymbol{\theta}_{\phi^\ast(s)})\|_F^2, \label{eqPITutt1} \end{equation} % where $\phi^\ast$ is the permutation that minimizes the utterance-level separation error defined as % \begin{equation} \phi^\ast = \underset{\phi\in \mathcal{P}}{\text{argmin}} \sum_{s=1}^S \| \hat{\mathbf{M}}_s \circ \mathbf{R} - \mathbf{A}_{\phi(s)}\circ \cos(\boldsymbol{\theta}_y - \boldsymbol{\theta}_{\phi(s)}) \|_F^2, \label{eqPITutt} \end{equation} % % and $\mathcal{P}$ is the symmetric group of degree $S$, i.e. the set of all $S!$ permutations. In original PIT, the optimal permutation (in MSE sense) is computed and applied \emph{for each} output meta-frame. This implies that consecutive meta-frames might be associated with different permutations, and although PIT solves the label permutation problem, it does not solve the speaker tracing problem. % % With uPIT, however, the permutation corresponding to the minimum utterance-level separation error is used \emph{for all} frames in the utterance. % In other words, the pair-wise scores in Fig.~\ref{fig:model} are computed for the whole utterance assuming all output frames follow the same permutation. Using the same permutation \emph{for all} frames in the utterance might imply that a non-MSE-optimal permutation is used for individual frames within the utterance. However, the intuition behind uPIT is that since the permutation resulting in the minimum utterance-level separation error is used, the number of non-optimal permutations is small and the model sees enough correctly permuted frames to learn an efficient separation model. % % % For example, the output vector $\hat{\mathbf{u}}_{i}$ of a perfectly trained two-talker speech separation model, given an input utterance, should ideally be $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{1,i}^T \; \hat{\mathbf{m}}_{2,i}^T \right]^T$, or $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{2,i}^T \; \hat{\mathbf{m}}_{1,i}^T \right]^T \forall \; i=1, \dots , T$, i.e. the output masks should follow the same permutation for all $T$ frames in the utterance. % Fortunately, using Eq.\;\eqref{eqPITutt1} as a training criterion, for deep learning based speech separation models, this seems to be the case in practice (See Sec.\;\ref{sec:exp} for examples). % Since utterances have variable length, and effective separation presumably requires exploitation of long-range signal dependencies, models such as DNNs and CNNs are no longer good fits. Instead, we use deep LSTM RNNs and \ac{BLSTM} RNNs together with uPIT to learn the masks. % Different from PIT, in which the input layer and each output layer has $N \times T$ and $N \times M$ units, respectively, in uPIT, both input and output layers have $N$ units (adding contextual frames in the input does not help for LSTMs). With deep LSTMs, the utterance is evaluated frame-by-frame exploiting the whole past history information at each layer. When BLSTMs are used, the information from the past and future (i.e., across the whole utterance) is stacked at each layer and used as the input to the subsequent layer. % With uPIT, during inference we don't need to compute pairwise MSEs and errors of each possible permutation and no additional speaker tracing step is needed. We simply assume a constant permutation and treat the same output mask to be from the same speaker for all frames. This makes uPIT a simple and attractive solution. \section{Experimental Results} \label{sec:exp} We evaluated uPIT on various setups and all models were implemented using the Microsoft Cognitive Toolkit (CNTK) \cite{yu_computational_2015,agarwal_introduction_2014}\footnote{Available at: \url{https://www.cntk.ai/}}. The models were evaluated on their potential to improve the Signal-to-Distortion Ratio\;(SDR) \cite{vincent_performance_2006} and the Perceptual Evaluation of Speech Quality\;(PESQ) \cite{rix_perceptual_2001} score, both of which are metrics widely used to evaluate speech enhancement performance for multi-talker speech separation tasks. \subsection{Datasets} \label{subsec:datasets} We evaluated uPIT on the WSJ0-2mix, WSj0-3mix\footnote{Available at: \url{http://www.merl.com/demos/deep-clustering}} and Danish-2mix datasets using 129-dimensional STFT magnitude spectra computed with a sampling frequency of 8 kHz, a frame size of 32 ms and a 16 ms frame shift. The WSJ0-2mix dataset was introduced in \cite{hershey_deep_2016} and was derived from the WSJ0 corpus \cite{garofolo_csr-i_1993}. The 30h training set and the 10h validation set contain two-speaker mixtures generated by randomly selecting from 49 male and 51 female speakers and utterances from the WSJ0 training set si\_tr\_s, and mixing them at various Signal-to-Noise Ratios\;(SNRs) uniformly chosen between 0\,dB and 5\,dB. The 5h test set was similarly generated using utterances from 16 speakers from the WSJ0 validation set si\_dt\_05 and evaluation set si\_et\_05. The WSJ0-3mix dataset was generated using a similar approach but contains mixtures of speech from three talkers. The Danish-2mix dataset is based on a corpus\footnote{Available at: {\url{http://www.nb.no/sbfil/dok/nst_taledat_dk.pdf}} } with approximately 560 speakers each speaking 312 utterances with average utterance duration of approximately 5 sec. The dataset was constructed by randomly selecting a set of 45 male and 45 female speakers from the corpus, and then allocating 232 and 40 utterances from each speaker to generate mixed speech in the training, and validation set, respectively. A number of 40 utterances from each of another 45 male and 45 female speakers were randomly selected to construct the \ac{OC} (unseen speaker) test set. Speech mixtures were constructed similarly to the WSJ0-2mix with SNRs selected uniformly between 0\,dB and 5\,dB. Similarly to the WSJ0-2mix dataset we constructed 20k and 5k mixtures in total in the training and validation set, respectively, and 3k mixtures for the OC test set. In our study, the validation set is used to find initial hyper-parameters and to evaluate \ac{CC} (seen speaker) performance, similarly to \cite{hershey_deep_2016,isik_single-channel_2016,yu_permutation_2017}. \subsection{Permutation Invariant Training} % % We first evaluated the original frame-level PIT on the two-talker separation dataset WSJ0-2mix, and differently from \cite{yu_permutation_2017}, we fixed the input dimension to 51 frames, to isolate the effect of a varying output dimension. In PIT, the input window and output window sizes are fixed. For this reason, we can use DNNs and CNNs. The DNN model has three hidden layers each with 1024 ReLU units. In (inChannel, outChannel)-(strideW, strideH) format, the CNN model has one $(1,64)-(2,2)$, four $(64,64)-(1,1)$, one $(64,128)-(2,2)$, two $(128,128)-(1,1)$, one $(128,256)-(2,2)$, and two $(256,256)-(1,1)$ convolution layers with $3 \times 3$ kernels, a $7\times17$ average pooling layer and a 1024-unit ReLU layer. The input to the models is the stack (over multiple frames) of the 129-dimensional STFT spectral magnitude of the speech mixture. % The output layer $\hat{\mathbf{u}}_{i}$ is divided into $S$ output masks/streams for $S$-talker mixed speech as $\hat{\mathbf{u}}_{i} = \left[ \hat{\mathbf{m}}_{1,i} \;;\; \hat{\mathbf{m}}_{2,i} \;;\; \dots \;;\; \hat{\mathbf{m}}_{S,i} \right]^T$. Each output mask vector $\hat{\mathbf{m}}_{s,i}$ has a dimension of $129 \times M$, where $M$ is the number of frames in the output meta-frame. \begin{figure}[ht] \centering \centerline{\includegraphics[width=0.8\linewidth]{figures/figD/mseFig2sprkPIT_RND.pdf}} \caption{MSE over epochs on the WSJ0-2mix training and validation sets with conventional training and PIT.}\label{fig:mse} \end{figure} In Fig.~\ref{fig:mse} we present the DNN training progress as measured by the MSE on the training and validation set with conventional training (CONV-DNN) and PIT on the WSJ0-2mix datasets described in subsection \ref{subsec:datasets}. We also included the training progress for another conventionally trained model but with a slightly modified version of the WSJ0-2mix dataset, where speaker labels have been randomized (CONV-DNN-RAND). The WSJ0-2mix dataset, used in \cite{hershey_deep_2016}, was designed such that speaker one was always assigned the most energy, and consequently speaker two the lowest, when scaling to a given SNR. % Previous work \cite{weng_deep_2015} has shown that such speaker energy patterns are an effective discriminative feature, which is clearly seen in Fig.~\ref{fig:mse}, where the CONV-DNN model achieves considerably lower training and validation MSE than the CONV-DNN-RAND model, which hardly decreases in either training or validation MSE due to the label permutation problem \cite{weng_deep_2015,hershey_deep_2016}. % In contrast, training converges quickly to a very low MSE when PIT is used. \begin{table}[t] \caption{SDR improvements (dB) for different separation methods on the WSJ0-2mix dataset using PIT.} \label{tab:WSJ0-2mix-PIT} \centering \resizebox{0.60\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule Method & \multirow{2}{*}{\makecell{ Input\textbackslash Output \\ window}} & \multicolumn{2}{c} {Opt. Assign.} & \multicolumn{2}{c} {Def. Assign. }\\ \cmidrule(l){3-4} \cmidrule(l){5-6} & & CC & OC & CC & OC \\ \midrule PIT-DNN & 51\textbackslash51 & 6.8 & 6.7 & \bf{5.2} & \bf{5.2} \\ PIT-DNN & 51\textbackslash5 & \bf{10.3} & \bf{10.2} & -0.8 & -0.8 \\ % PIT-CNN & 51\textbackslash51 & 9.6 & 9.6 & \bf{7.6} & \bf{7.5} \\ PIT-CNN & 51\textbackslash5 & \bf{10.9} & \bf{11.0} & -1.0 & -0.9 \\ % IRM & - & 12.4 & 12.7 & 12.4 & 12.7 \\ IPSM & - & 14.9 & 15.1 & 14.9 & 15.1 \\ \midrule \midrule \end{tabular} } \end{table} In Table~\ref{tab:WSJ0-2mix-PIT} we summarize the SDR improvement in dB from different frame-level PIT separation configurations for two-talker mixed speech in closed condition\;(CC) and open condition\;(OC). In these experiments each frame was reconstructed by averaging over all output meta-frames that contain the same frame. In the default assignment (def. assign.) setup, a constant output mask permutation is assumed across frames (which is an invalid assumption in general). % This is the maximum achievable SDR improvement using PIT without the utterance-level training criterion and without an additional tracing step. % In the optimal assignment (opt. assign.) setup, the output-mask permutation for each output meta-frame is determined based on the true target, i.e. oracle information. This reflects the separation performance within each segment (meta-frame) and is the improvement achievable when the speakers are correctly separated. The gap between these two values indicates the possible contribution from speaker tracing. As a reference, we also provided the IRM and IPSM results. From the table we can make several observations. First, PIT can already achieve 7.5 dB SDR improvement (def. assign.), even though the model is very simple. Second, as we reduce the output window size, we can improve the separation performance within each window and achieve better SDR improvement, if speakers are correctly traced (opt. assign.). However, when output window size is reduced, the output mask permutation changes more frequently as indicated by the poor default assignment performance. Speaker tracing thus becomes more important given the larger gap between the optimal assignment and default assignment. Third, PIT generalizes well to unseen speakers, since the performances on the open and closed conditions are very close. Fourth, powerful models such as CNNs consistently outperform DNNs, but the gain diminishes when the output window size is small. \subsection{Utterance-Level Permutation Invariant Training} % As indicated by Table~\ref{tab:WSJ0-2mix-PIT}, an accurate output mask permutation is critical to further improve the separation quality. In this subsection we evaluate the uPIT technique as discussed in Sec.~\ref{sec:integrated} and the results are summarized in Table~\ref{tab:WSJ0-2mix-uPIT}. \begin{table}[t] \caption{SDR improvements (dB) for different separation methods on the WSJ0-2mix dataset using uPIT.} \label{tab:WSJ0-2mix-uPIT} \centering \resizebox{0.75\textwidth}{!}{% \begin{tabular}{lcccccc} \midrule \midrule Method & Mask Type & \multirow{2}{*}{\makecell{ Activation \\ Function}} & \multicolumn{2}{c} {Opt. Assign.} & \multicolumn{2}{c} {Def. Assign.}\\ \cmidrule(l){4-5} \cmidrule(l){6-7} & & & CC & OC & CC & OC \\ \midrule uPIT-BLSTM & AM & softmax & \bf{10.4} & \bf{10.3} & \bf{9.0} & \bf{8.7} \\ uPIT-BLSTM & AM & sigmoid & 8.3 & 8.3 & 7.1 & 7.2 \\ uPIT-BLSTM & AM & ReLU & 9.9 & 9.9 & 8.7 & 8.6 \\ uPIT-BLSTM & AM & Tanh & 8.5 & 8.6 & 7.5 & 7.5 \\ uPIT-BLSTM & PSM & softmax & 10.3 & 10.2 & 9.1 & 9.0 \\ uPIT-BLSTM & PSM & sigmoid & 10.5 & 10.4 & 9.2 & 9.1 \\ uPIT-BLSTM & PSM & ReLU & \bf{10.9} & \bf{10.8} & \bf{9.4} & \bf{9.4} \\ uPIT-BLSTM & PSM & Tanh & 10.4 & 10.3 & 9.0 & 8.9 \\ uPIT-BLSTM & NPSM & softmax & 8.7 & 8.6 & 7.5 & 7.3 \\ uPIT-BLSTM & NPSM & sigmoid & \bf{10.6} & \bf{10.6} & \bf{9.4} & \bf{9.3} \\ uPIT-BLSTM & NPSM & ReLU & 8.8 & 8.8 & 7.6 & 7.6 \\ uPIT-BLSTM & NPSM & Tanh & 10.1 & 10.0 & 8.9 & 8.8 \\ uPIT-LSTM & PSM & ReLU & \bf{9.8} & \bf{9.8} & 7.0 & \bf{7.0} \\ uPIT-LSTM & PSM & sigmoid & \bf{9.8} & 9.6 & \bf{7.1} & 6.9 \\ uPIT-LSTM & NPSM & ReLU & \bf{9.8} & \bf{9.8} & \bf{7.1} & \bf{7.0} \\ uPIT-LSTM & NPSM & sigmoid & 9.2 & 9.2 & 6.8 & 6.8 \\ PIT-BLSTM & PSM & ReLU & \bf{11.7} & \bf{11.7} & \bf{-1.7} & -1.9 \\ PIT-BLSTM & PSM & sigmoid & \bf{11.7} & \bf{11.7} & \bf{-1.7} & \bf{-1.7} \\ PIT-BLSTM & NPSM & ReLU & \bf{11.7} & \bf{11.7} & \bf{-1.7} & -1.8 \\ PIT-BLSTM & NPSM & sigmoid & 11.6 & 11.6 & -1.6 & \bf{-1.7} \\ \midrule IRM & - & - & 12.4 & 12.7 & 12.4 & 12.7 \\ IPSM & - & - & 14.9 & 15.1 & 14.9 & 15.1 \\ \midrule \midrule \end{tabular} } \end{table} Due to the formulation of the uPIT cost function in Eq. \eqref{eqPITutt1} and Eq. \eqref{eqPITutt}, and to utilize long-range context, RNNs are the natural choice, and in this set of experiments, we used LSTM RNNs. All the uni-directional LSTMs (uPIT-LSTM) evaluated have 3 LSTM layers each with 1792 units and all the bi-directional LSTMs (uPIT-BLSTM) have 3 BLSTM layers each with 896 units, so that both models have similar number of parameters. All models contain random dropouts when fed from a lower layer to a higher layer and were trained with a dropout rate of 0.5. Note that, since we used Nvidia's cuDNN implementation of LSTMs, to speed up training, we were unable to apply dropout across time steps, which was adopted by the best DPCL model \cite{isik_single-channel_2016} and is known to be more effective, both theoretically and empirically, than the simple dropout strategy used in this work \cite{gal_theoretically_2015}. In all the experiments reported in Table~\ref{tab:WSJ0-2mix-uPIT} the maximum epoch is set to 200 although we noticed that further performance improvement is possible with additional training epochs. Note that the epoch size of 200 seems to be significantly larger than that in PIT as indicated in Fig.~\ref{fig:mse}. This is likely because in PIT each frame is used by $T$ ($T=51$) training samples (input meta-frames) while in uPIT each frame is used just once in each epoch. The learning rates were set to $2 \times 10^{-5}$ per sample initially and scaled down by $0.7$ when the training objective function value increases on the training set. The training was terminated when the learning rate got below $10^{-10}$. Each minibatch contains 8 randomly selected utterances. As a related baseline, we also include PIT-BLSTM results in Table~\ref{tab:WSJ0-2mix-uPIT}. These models were also trained using LSTMs with whole utterances instead of meta-frames. The only difference between these models and uPIT models is that uPIT models use the utterance-level training criterion defined in Eqs.\,\eqref{eqPITutt1} and \eqref{eqPITutt}, instead of the meta-frame based criterion used by PIT. % \subsubsection{uPIT Training Progress} In Fig. \ref{fig:mse-uPIT} we present a representative example of the BLSTM training progress, as measured by the MSE of the two-talker mixed speech training and validation set, using Eq.\;\eqref{eqPITutt1}. We see that the training and validation MSEs are both steadily decreasing as function of epochs, hence uPIT, similarly to PIT, effectively solves the label permutation problem. \begin{figure}[ht] \centering \centerline{\includegraphics[width=0.8\linewidth]{figures/figD/mseFig2sprk.pdf}} \caption{MSE over epochs on the WSJ0-2mix PSM training and validation sets wit uPIT.}\label{fig:mse-uPIT} \end{figure} \subsubsection{uPIT Performance for Different Setups} From Table~\ref{tab:WSJ0-2mix-uPIT}, we can notice several things. First, with uPIT, we can significantly improve the SDR with default assignment over original PIT. In fact, a 9.4\,dB SDR improvement on both CC and OC sets can be achieved by simply assuming a constant output mask permutation (def. assign.), which compares favorably to 7.6\,dB (CC) and 7.5\,dB (OC) achieved with deep CNNs combined with PIT. % We want to emphasize that this is achieved through Eqs.\;\eqref{eqPITutt1} and \eqref{eqPITutt}, and not by using BLSTMs because the corresponding PIT-BLSTM default assignment results are so much worse, even though the optimal assignment results are the best among all models. % The latter may be explained from the PIT objective function that attempts to obtain a constant output mask permutation at the meta-frame-level, which for small meta-frames is assumed easier compared to the uPIT objective function, that attempts to obtain a constant output mask permutation throughout the whole utterance. % Second, we can achieve better SDR improvement over the AM using PSM and NPSM training criteria. % This indicates that including phase information does improve performance, even-though it was used implicitly via the cosine term in Eq.\;\eqref{eqPITutt1}. % % Third, with uPIT the gap between optimal assignment and default assignment is always less than 1.5\,dB across different setups, hence additional improvements from speaker tracing algorithms is limited to 1.5\,dB. % % % \subsubsection{Two-Stage Models and Reduced Dropout Rate} % It is well known that cascading DNNs can improve performance for certain deep learning based applications \cite{zhang_deep_2016,nie_deep_2014,wang_recurrent_2017,isik_single-channel_2016}. % In Table~\ref{tab:WSJ0-2mix-Further} we show that a similar principle of cascading two BLSTM models into a two-stage model\linebreak (-ST models in Table~\ref{tab:WSJ0-2mix-Further}) can lead to improved performance over the models presented in Table~\ref{tab:WSJ0-2mix-uPIT}. % In Table~\ref{tab:WSJ0-2mix-Further} we also show that improved performance, with respect to the same models, can be achieved with additional training epochs combined with a reduced dropout rate (-RD models in Table~\ref{tab:WSJ0-2mix-Further}). % Specifically, if we continue the training of the two best performing models from Table~\ref{tab:WSJ0-2mix-uPIT} (i.e. uPIT-BLSTM-PSM-ReLU and uPIT-BLSTM-NPSM-Sigmoid) with 200 additional training epochs at a reduced dropout rate of 0.3, we see an improvement of $0.1$\;dB. % Even larger improvements can be achieved with the two-stage approach, where an estimated mask is computed as the average mask from two BLSTM models as % \begin{equation} \begin{split} \hat{\mathbf{M}}_s &= \frac {\hat{\mathbf{M}}_s^{(1)} + \hat{\mathbf{M}}_s^{(2)}} {2}. \end{split} \end{equation} The mask $\hat{\mathbf{M}}_s^{(1)}$ is from an -RD model that serves as a first-stage model, and $\hat{\mathbf{M}}_s^{(2)}$ is the output mask from a second-stage model. The second-stage model is trained using the original input features as well as the mask $\hat{\mathbf{M}}_s^{(1)}$ from the first-stage model. % The intuition behind this architecture is that the second-stage model will learn to correct the errors made by the first-stage model. % % Table~\ref{tab:WSJ0-2mix-Further} shows that the two-stage models (-ST models) always outperform the single-stage models (-RD models) and overall, a 10\,dB SDR improvement can be achieved on this task using a two-stage approach. % \begin{table}[t] \caption{Further improvement on the WSJ0-2mix dataset with additional training epochs with reduced dropout (-RD) or stacked models (-ST)} \vspace{-1mm} \label{tab:WSJ0-2mix-Further} \centering \resizebox{0.7\textwidth}{!}{% \begin{tabular}{lcccccc} \midrule \midrule Method & \multirow{2}{*}{\makecell{ Mask \\ Type}} & \multirow{2}{*}{\makecell{ Activation \\ Function}} & \multicolumn{2}{c} {Opt. Assign.} & \multicolumn{2}{c} {Def. Assign.}\\ \cmidrule(l){4-5} \cmidrule(l){6-7} & & & CC & OC & CC & OC \\ \midrule uPIT-BLSTM-RD & PSM & ReLU & 11.0 & 11.0 & 9.5 & 9.5 \\ uPIT-BLSTM-ST & PSM & ReLU & \bf{11.7} & \bf{11.7} & {10.0} & \bf{10.0} \\ uPIT-BLSTM-RD & NPSM & Sigmoid & 10.7 & 10.7 & 9.5 & 9.4 \\ uPIT-BLSTM-ST & NPSM & Sigmoid & {11.5} & {11.5} & \bf{10.1} & \bf{10.0} \\ \midrule IRM & - & - & 12.4 & 12.7 & 12.4 & 12.7 \\ IPSM & - & - & 14.9 & 15.1 & 14.9 & 15.1 \\ \midrule \midrule \end{tabular} } \end{table} \subsubsection{Opposite Gender vs. Same Gender.} \begin{table}[t] \caption{SDR (dB) improvements on test sets of WSJ0-2mix divided into same and opposite gender mixtures} \vspace{-1mm} \label{tab:WSJ0-2mix-gender} \centering \resizebox{0.7\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule Method & Config & \multicolumn{2}{c} {CC} & \multicolumn{2}{c} {OC}\\ \cmidrule(l){3-4} \cmidrule(l){5-6} & & Same & Opp. & Same & Opp. \\ \midrule uPIT-BLSTM-RD & PSM-ReLU & 7.5 & 11.5 & 7.1 & 11.6 \\ uPIT-BLSTM-ST & PSM-ReLU & 7.8 & \bf{12.1} & \bf{7.5} & \bf{12.2} \\ uPIT-BLSTM-RD & NPSM-Sigmoid & 7.5 & 11.5 & 7.0 & 11.5 \\ uPIT-BLSTM-ST & NPSM-Sigmoid & \bf{8.0} & \bf{12.1} & \bf{7.5} & 12.1 \\ \midrule IRM & - & 12.2 & 12.7 & 12.4 & 12.9 \\ IPSM & - & 14.6 & 15.1 & 14.9 & 15.3 \\ \midrule \midrule \end{tabular} } \end{table} Table~\ref{tab:WSJ0-2mix-gender} reports SDR (dB) improvements on test sets of WSJ0-2mix divided into opposite-gender\;(Opp.) and same-gender\;(Same). From this table we can clearly see that our approach achieves much better SDR improvements on the opposite-gender mixed speech than the same-gender mixed speech, although the gender information is not explicitly used in our model and training procedure. In fact, for the opposite-gender condition, the SDR improvement is already very close to the IRM result. These results agree with breakdowns from other works \cite{hershey_deep_2016,isik_single-channel_2016} and generally indicate that same-gender mixed speech separation is a harder task. \subsubsection{Multi-Language Models} To further understand the properties of uPIT, we evaluated the uPIT-BLSTM-PSM-ReLU model trained on WSJ0-2mix (English) on the Danish-2mix test set. The results of this is reported in Table~\ref{tab:twolanguage}. % \begin{table}[t] \caption{SDR (dB) and PESQ improvements on WSJ0-2mix and Danish-2mix with uPIT-BLSTM-PSM-ReLU trained on WSJ0-2mix and a combination of two languages.} \label{tab:twolanguage} \centering \resizebox{0.5\textwidth}{!}{% \begin{tabular}{lcccc} \midrule \midrule Trained on & \multicolumn{2}{c} {WSJ0-2mix} & \multicolumn{2}{c} {Danish-2mix}\\ \cmidrule(l){2-3} \cmidrule(l){4-5} & SDR & PESQ & SDR & PESQ \\ \midrule WSJ0-2mix & 9.4 & 0.62 & 8.1 & 0.40 \\ +Danish-2mix & 8.8 & 0.58 & 10.6 & 0.51 \\ \midrule IRM & 12.7 & 2.11 & 15.2 & 1.90 \\ IPSM & 15.1 & 2.10 & 17.7 & 1.90 \\ \midrule \midrule \end{tabular} } \end{table} % % An interesting observation, is that although the system has never seen Danish speech, it performs remarkably well in terms of SDR, when compared to the IRM (oracle) values. These results indicate, that the separation ability learned with uPIT generalizes well, not only across speakers, but also across languages. % In terms of PESQ, we see a somewhat larger performance gap with respect to the IRM. This might be explained by the fact that SDR is a waveform matching criteria and does not necessarily reflect perceived quality as well as PESQ. Furthermore, we note that the PESQ improvements are similar to what have been reported for DNN based speech enhancement systems \cite{kolbaek_speech_2017}. We also trained a model with the combination of English and Danish datasets and evaluated the models on both languages. The results of these experiments are summarized in Table~\ref{tab:twolanguage}. Table~\ref{tab:twolanguage}, indicate that by including Danish data, we can achieve better performance on the Danish dataset, at the cost of slightly worse performance on the English dataset. Note that while doubling the training set, we did not change the model size. Had we done this, performance would likely improve on both languages. \subsubsection{Summary of Multiple 2-Speaker Separation Techniques} \begin{table}[t] \caption{SDR (dB) and PESQ improvements for different separation methods on the WSJ0-2mix dataset without additional tracing (i.e., def. assign.).} \label{tab:WSJ0-2mix-summary} \centering \resizebox{0.6\textwidth}{!}{% \begin{tabular}{lccccc} \midrule \midrule Method & Config & \multicolumn{2}{c} {PESQ Imp.} & \multicolumn{2}{c} {SDR Imp.}\\ \cmidrule(l){3-4} \cmidrule(l){5-6} & & CC & OC & CC & OC \\ \midrule Oracle NMF \cite{hershey_deep_2016} & - & - & - & 5.1 & - \\ CASA \cite{hershey_deep_2016} & - & - & - & 2.9 & 3.1 \\ DPCL \cite{hershey_deep_2016} & - & - & - & 5.9 & 5.8 \\ DPCL+ \cite{chen_deep_2017} & - & - & - & - & 9.1 \\ DANet \cite{chen_deep_2017} & - & - & - & - & 9.6 \\ DANet$^\ddagger$ \cite{chen_deep_2017} & - & - & - & - & 10.5 \\ DPCL++ \cite{isik_single-channel_2016} & - & - & - & - & 9.4 \\ DPCL++$^\ddagger$ \cite{isik_single-channel_2016} & - & - & - & - & \bf{10.8} \\ \midrule PIT-DNN & 51\textbackslash51 & 0.24 & 0.23 & 5.2 & 5.2 \\ PIT-CNN & 51\textbackslash51 & 0.52 & 0.50 & 7.6 & 7.6 \\ uPIT-BLSTM & PSM-ReLU & 0.66 & 0.62 & 9.4 & 9.4 \\ uPIT-BLSTM-ST& PSM-ReLU & {\bf{0.86}} & {\bf{0.82}} & {\bf{10.0}} & {10.0} \\ \midrule IRM & - & 2.15 & 2.11 & 12.4 & 12.7 \\ IPSM & - & 2.14 & 2.10 & 14.9 & 15.1 \\ \midrule \midrule \multicolumn{6}{l} {\footnotesize $^\ddagger$ indicates curriculum training.} \end{tabular} } \end{table} Table~\ref{tab:WSJ0-2mix-summary} summarizes SDR (dB) and PESQ improvements for different separation methods on the WSJ0-2mix dataset. From the table we can observe that the models trained with PIT already achieve similar or better SDR than the original DPCL \cite{hershey_deep_2016}, respectively, with DNNs and CNNs. % Using the uPIT training criteria, we improve on PIT and achieve comparable performance with DPCL+, DPCL++ and DANet models\footnote{\cite{isik_single-channel_2016,chen_deep_2017} did not use the SDR measure from \cite{vincent_performance_2006}. Instead a related variant called scale-invariant SNR was used.} % reported in \cite{isik_single-channel_2016,chen_deep_2017}, which used curriculum training \cite{bengio_curriculum_2009}, and recurrent dropout \cite{gal_theoretically_2015}. % Note that, both uPIT and PIT models are much simpler than DANet, DPCL, DPCL+, and DPCL++, because uPIT and PIT models do not require any clustering step during inference or estimation of attractor points, as required by DANet. \subsection{Three-Talker Speech Separation} % In Fig.~\ref{fig:mse-uPIT-3sprk} we present the uPIT training progress as measured by MSE on the three-talker mixed speech training and validation sets WSJ0-3mix. We observe that similar to the two-talker scenario in Fig.~\ref{fig:mse-uPIT}, a low training MSE is achieved, although the validation MSE is slightly higher. A better balance between the training and validation MSEs may be achieved by hyperparameter tuning. We also observe that increasing the model size decreases both training and validation MSE, which is expected due to the more variability in the dataset. \begin{figure}[h] \centering \centerline{\includegraphics[trim={8mm 0mm 8mm 2mm},clip,width=0.75\linewidth]{figures/figD/mseFig3sprk.pdf}} \caption{MSE over epochs on the WSJ0-3mix NPSM training and validation sets wit uPIT.}\label{fig:mse-uPIT-3sprk} \end{figure} In Table~\ref{tab:WSJ0-3mix} we summarize the SDR improvement in dB from different uPIT separation configurations for three-talker mixed speech, in closed condition\;(CC) and open condition\;(OC). % We observe that the basic uPIT-BLSTM model (896 units) compares favorably with DPCL++. % Furthermore, with additional units, further training and two-stage models (based on uPIT-BLSTM), uPIT achieves higher SDR than DPCL++ and similar SDR as DANet, without curriculum training, on this three-talker separation task. % \begin{table}[t] \caption{SDR improvements (dB) for different separation methods on the WSJ0-3mix dataset. $^\ddagger$ indicates curriculum training. } \label{tab:WSJ0-3mix} \centering \resizebox{0.75\textwidth}{!}{% \begin{tabular}{lcccccc} \midrule \midrule Method & \multirow{2}{*}{\makecell{ Units/\\ layer}} & \multirow{2}{*}{\makecell{ Activation\\ function}} & \multicolumn{2}{c} {Opt. Assign.} & \multicolumn{2}{c} {Def. Assign.} \\ \cmidrule(l){4-5} \cmidrule(l){6-7} & & & CC & OC & CC & OC \\ \midrule Oracle NMF \cite{hershey_deep_2016} & - & - & 4.5 & - & - & - \\ DPCL++$^\ddagger$ \cite{isik_single-channel_2016} & - & - & - & - & - & 7.1 \\ DANet \cite{chen_single_2017} & - & - & - & - & - & 7.7 \\ DANet$^\ddagger$ \cite{chen_deep_2017} & - & - & - & - & - & \bf{8.8} \\ % uPIT-BLSTM & 896 & Sigmoid & 10.0 & 9.9 & 7.4 & 7.2 \\ uPIT-BLSTM & 1280 & Sigmoid & 10.1 & 10.0 & 7.5 & 7.4 \\ uPIT-BLSTM-RD & 1280 & Sigmoid & 10.2 & 10.1 & 7.6 & 7.4 \\ uPIT-BLSTM-ST & 1280 & Sigmoid & \bf{10.7} & \bf{10.6} & \bf{7.9} & 7.7 \\ \midrule IRM & - & - & 12.6 & 12.8 & 12.6 & 12.8 \\ IPSM & - & - & 15.1 & 15.3 & 15.1 & 15.3 \\ \midrule \midrule \multicolumn{6}{l} {\footnotesize $^\ddagger$ indicates curriculum training.} \end{tabular}} \end{table} \subsection{Combined Two- and Three-Talker Speech Separation} To illustrate the flexibility of uPIT, we summarize in Table~\ref{tab:WSJ0-2-3mix} the performance of the three-speaker uPIT-BLSTM, and uPIT-BLSTM-ST models (from Table~\ref{tab:WSJ0-3mix}), when they are trained and tested on both the WSJ0-2mix and WSJ0-3mix datasets, i.e. on both two- and three-speaker mixtures. To be able to train the three-speaker models with the two-speaker WSJ0-2mix dataset, we extended WSJ0-2mix with a third "silent" channel. The silent channel consists of white Gaussian noise with an energy level 70 dB below the average energy level of the remaining two speakers in the mixture. % When we evaluated the model, we identified the two speaker-active output streams as the ones corresponding to the signals with the most energy. We see from Table~\ref{tab:WSJ0-2-3mix} that uPIT-BLSTM achieves good, but slightly worse, performance compared to the corresponding two-speaker (Table~\ref{tab:WSJ0-2mix-summary}) and three-speaker (Table~\ref{tab:WSJ0-3mix}) models. % Surprisingly, the uPIT-BLSTM-ST model outperforms both the two-speaker (Table~\ref{tab:WSJ0-2mix-Further}) and three-speaker uPIT-BLSTM-ST (Table~\ref{tab:WSJ0-3mix}) models. These results indicate that a single model can handle a varying, and more importantly, unknown number of speakers, without compromising performance. % This is of great practical importance, since \emph{a priori} knowledge about the number of speakers is not needed at test time, as required by competing methods such as DPCL++ \cite{isik_single-channel_2016} and DANet \cite{chen_deep_2017,chen_single_2017}. \begin{table}[t] \caption{SDR improvements (dB) for three-speaker models trained on both the WSJ0-2mix and WSJ0-3mix PSM datasets. } \label{tab:WSJ0-2-3mix} \centering \resizebox{0.5\textwidth}{!}{% \begin{tabular}{lcccc} \midrule \midrule Method & \multicolumn{2}{c} {2 Spkr.} & \multicolumn{2}{c} {3 Spkr. } \\ \cmidrule(l){2-3} \cmidrule(l){4-5} & \multicolumn{2}{c} {Def. Assign.} & \multicolumn{2}{c} {Def. Assign.} \\ \cmidrule(l){2-3} \cmidrule(l){4-5} & CC & OC & CC & OC \\ \midrule uPIT-BLSTM & 9.4 & 9.3 & 7.2 & 7.1 \\ uPIT-BLSTM-ST & \bf{10.2} & \bf{10.1} & \bf{8.0} & \bf{7.8} \\ \midrule IRM & 12.4 & 12.7 & 12.6 & 12.8 \\ IPSM & 14.9 & 15.1 & 15.1 & 15.3 \\ \midrule \midrule \multicolumn{5}{l} {\footnotesize Both models have 1280 units per layer and ReLU outputs.} \end{tabular} } \end{table} During evaluation of the 3000 mixtures in the WSJ0-2mix test set, output stream one and two were the output streams with the most energy, i.e. the speaker-active output streams, in 2999 cases. Furthermore, output stream one and two had, on average, an energy level approximately 33 dB higher than the silent channel, indicating that the models successfully keep a constant permutation of the output masks throughout the test utterance. % % \begin{figure}[ht!] \centering \centerline{\includegraphics[trim={0mm 15mm 0mm 10mm},clip,width=0.8\linewidth]{figures/figD/multSpeaker.pdf}} \caption{Spectrograms showing how a three-speaker BLSTM model trained with uPIT can separate a two-speaker mixture while keeping a constant output-mask permutation. The energy in output stream three is $63$ dB lower than the energy in output stream one and two.}\label{fig:multSpkr} \end{figure} % % As an example, Fig.~\ref{fig:multSpkr} shows the spectrogram for a single two-speaker (male-vs-female) test case along with the spectrograms of the three output streams of the uPIT-BLSTM model, as well as the clean speech signals from each of the two speakers. % Clearly, output streams one and two contain the most energy and output stream three consists primarily of a low energy signal without any clear structure. % Furthermore, by comparing the spectrograms of the clean speech signals ("Speaker 1" and "Speaker 2" in Fig.~\ref{fig:multSpkr}) to the spectrogram of the corresponding output streams, it is observed that they share many similarities, which indicate that the model kept a constant output-mask permutation for the entire mixture and successfully separated the two speakers into two separate output streams. % This is also supported by the SDR improvements, which for output stream one ("Speaker 1") is 13.7 dB, and for output stream two ("Speaker 2") is 12.1 dB. % % \section{Conclusion and Discussion}\label{sec:conclusion} In this paper, we have introduced the utterance-level Permutation Invariant Training\;(uPIT) technique for speaker independent multi-talker speech separation. We consider uPIT an interesting step towards solving the important cocktail party problem in a real-world setup, where the set of speakers is unknown during the training time. Our experiments on two- and three-talker mixed speech separation tasks indicate that uPIT can indeed effectively deal with the label permutation problem. These experiments show that bi-directional Long Short-Term Memory\;(LSTM) Recurrent Neural Networks\;(RNNs) perform better than uni-directional LSTMs and Phase Sensitive Masks\;(PSMs) are better training criteria than Amplitude Masks\;(AM). % Our results also suggest that the acoustic cues learned by the model are largely speaker and language independent since the models generalize well to unseen speakers and languages. % More importantly, our results indicate that uPIT trained models do not require \emph{a priori} knowledge about the number of speakers in the mixture. Specifically, we show that a single model can handle both two-speaker and three-speaker mixtures. This indicates that it might be possible to train a universal speech separation model using speech in various speaker, language and noise conditions. The proposed uPIT technique is algorithmically simpler yet performs on par with DPCL \cite{hershey_deep_2016,isik_single-channel_2016} and comparable to DANets \cite{chen_deep_2017,chen_single_2017}, both of which involve separate embedding and clustering stages during inference. % Since uPIT, as a training technique, can be easily integrated and combined with other advanced techniques such as complex-domain separation and multi-channel techniques, such as beamforming, uPIT has great potential for further improvement. \section*{Acknowledgment} We would like to thank Dr. John Hershey at MERL and Zhuo Chen at Columbia University for sharing the WSJ0-2mix and WSJ0-3mix datasets and for valuable discussions. We also thank Dr. Hakan Erdogan at Microsoft Research for discussions on PSM. \pagebreak \section{Introduction}\label{sec:intro5} Focusing ones auditory attention towards a single speaker in a complex acoustic environment with multiple speakers and noise sources, is a task that humans are extremely good at \cite{bronkhorst_cocktail_2000}. However, achieving similar performance with machines has so far not been possible \cite{mcdermott_cocktail_2009}, although it would be highly desirable for a vast range of applications, such as mobile communications, robotics, hearing aids, speaker verification systems, etc. Traditionally, speech denoising \cite{kolbaek_speech_2017,chen_long_2016,weninger_single-channel_2014,weninger_discriminatively_2014,erdogan_phase-sensitive_2015,chen_large-scale_2016} and multi-talker speech separation \cite{du_speech_2014,yu_permutation_2017,hershey_deep_2016,isik_single-channel_2016,chen_deep_2017,weng_deep_2015,huang_joint_2015} have been considered as two separate tasks in the literature, although, for many applications both speech separation and denoising are desired. For example, in a human-machine interface the machine must be able to identify what is being said, and by who, before it can decide which signal to focus on, and consequently respond and act upon. The recent success of Deep Learning \cite{goodfellow_deep_2016} has revolutionized a large number of scientific fields, and is currently achieving state-of-the-art results on topics ranging from medical diagnosis \cite{gulshan_development_2016,esteva_dermatologist-level_2017} to Automatic Speech Recognition\;(ASR) \cite{xiong_achieving_2016,saon_english_2017}. Also the area of single-channel speech enhancement has seen improvement, with deep learning algorithms that have been reported to improve speech intelligibility for normal hearing, hearing impaired and cochlear implant users \cite{healy_algorithm_2015,chen_large-scale_2016,goehring_speech_2017,erdogan_deep_2017}. Speaker independent multi-talker speech separation, on the other hand, has so far not taken a similar leap forward, partly due to the long-lasting label permutation problem (further described in Section\;\ref{sec:train1}), which has prevented progress on deep learning based techniques for this task. Recently, two technical directions have been proposed for speaker independent multi-talker speech separation; a clustering based approach \cite{hershey_deep_2016,isik_single-channel_2016,chen_deep_2017}, and a regression based approach \cite{yu_permutation_2017,kolbaek_multi-talker_2017-1}. The clustering based approaches include the Deep Clustering\;(DPCL) techniques \cite{hershey_deep_2016,isik_single-channel_2016} and the DANet technique \cite{chen_deep_2017}. The regression based approaches include the Permutation Invariant Training\;(PIT) technique \cite{yu_permutation_2017} and the utterance-level PIT\;(uPIT) technique \cite{kolbaek_multi-talker_2017-1}. The general idea behind the DPCL and DANet techniques is that the mixture signal can be represented in an embedding space, e.g. using Recurrent Neural Networks\;(RNNs), where the different source signals in the mixture form clusters. These clusters are then identified using a clustering technique, such as K-means. The clustering based techniques have shown impressive performance on two-speaker and three-speaker mixtures. The regression based PIT and uPIT techniques, which are described in detail in Section\;\ref{sec:train1} utilize a cost function that jointly optimizes the label assignment and regression error end-to-end, hence effectively solving the label permutation problem. Both clustering based and regression based methods \cite{hershey_deep_2016,isik_single-channel_2016,chen_deep_2017,yu_permutation_2017,kolbaek_multi-talker_2017-1,erdogan_deep_2017} focus on ideal, noise-free training/testing conditions; i.e.\;situations where the mixtures contain clean speech only. For any practical application, background noise, e.g. due to interfering sound sources or non-ideal microphones must be expected. However, it is yet to be known how these techniques perform, when tested in noisy conditions that reflect a realistic usage scenario. In this paper we apply the recently proposed uPIT technique \cite{kolbaek_multi-talker_2017-1} for speaker independent multi-talker speech separation and denoising, simultaneously. Specifically, we train deep bi-directional Long Short-Term Memory\;(LSTM) RNNs using uPIT for speaker independent multi-talker speech separation in multiple noisy conditions, including both synthetic and real-life, known and unknown, noise signals at various Signal-to-Noise Ratios (SNRs). To the authors knowledge, this is the first attempt to perform speech separation and denoising simultaneously in a deep learning framework; hence, no competing baseline has been identified for this particular task. \section{Source Separation Using Deep Learning}\label{sec:problem2} The goal of single-channel speech separation is to separate a mixture of multiple speakers into the individual speakers using a single microphone recording. Similarly, single-channel speech denoising aims to extract a single target speech signal from a noisy single channel recording. Let $x_s[n]$, $n = 1,2, \dots, N$, $s = 1,2, \dots, S$ be the time domain source signal of length $N$ from source $s$ and let the observed mixture signal be defined as \begin{equation} y[n] = \sum_{s=1}^S x_s[n], \label{eqMixed} \end{equation} where $x_1[n]$ is a speech signal and $x_s[n]$, $s = 2, \dots , S$ can be either speech or additive noise signals. Furthermore, let ${X}_s(i,f)$ and ${Y}(i,f)$, $i = 1,\dots,K$, $f=1,2,\dots,L$ be the $L$-point Short-Time discrete Fourier Transforms (STFT) of $x_s[n]$ and $y[n]$, respectively. Also, let $\mathbf{x}_{s,i} = \left[ {{X}_s(i,1)} , {{X}_s(i,2)} , \dots, {{X}_s(i,\frac{L}{2}+1)} \right]^T$ $\in \mathbb{C}^{\frac{L}{2}+1}$ and $\mathbf{y}_{i} = \left[ {{Y}(i,1)} , {{Y}(i,2)} , \dots, {{Y}(i,\frac{L}{2}+1)} \right]^T \in \mathbb{C}^{\frac{L}{2}+1}$ denote the single-sided STFT spectrum, at frame $i$, for sources $s=1,2, \dots ,S$ and the mixture signal, respectively. We define the magnitudes of the source signals and mixture signal as $A_s(i,f) \triangleq |{X}_s(i,f)|$ and $R(i,f)\triangleq |{Y}(i,f)|$, respectively, and their corresponding single-sided magnitude spectra as $\mathbf{a}_{s,i} = \left[ {{A_s}(i,1)} , \dots, {{A_s}(i,\frac{L}{2}+1)} \right]^T \in \mathbb{R}^{\frac{L}{2}+1}$ and $\mathbf{r}_{i} = \left[ {{R}(i,1)} ,\; {{R}(i,2)} ,\; \dots,\; {{R}(i,\frac{L}{2}+1)} \right]^T \in \mathbb{R}^{\frac{L}{2}+1}$. For separating the mixture signal $\mathbf{y}_{i}$ into estimated target signal magnitudes $\mathbf{a}_{s,i}$, $s=1,2, \dots ,S$, we adopt the approach from \cite{kolbaek_multi-talker_2017-1} and estimate a set of masks ${M_s}(t,f)$, $s=1,2, \dots ,S$ using bi-directional LSTM RNNs. Let $\mathbf{m}_{s,i} = \left[ {{M_s}(i,1)} \;,\; {{M_s}(i,2)} \;,\; \dots,\; {{M_s}(i,\frac{L}{2}+1)} \right]^T \in \mathbb{R}^{\frac{L}{2}+1}$ be the ideal mask (to be defined in Sec.\;\ref{sec:mask1}) for speaker $s$ at frame $i$. The masks $\mathbf{{m}}_{s,i}$, $s=1,2, \dots ,S$ are then used to extract the target signal magnitudes as $\mathbf{{a}}_{s,i} = \mathbf{{m}}_{s,i} \circ \mathbf{r}_i$, $s=1,2, \dots ,S$, $i=1,2, \dots ,K$ where $\circ$ is the element-wise product, i.e. the Hadamard product. Similarly, when the masks are estimated by a deep learning model we arrive at the estimated signal magnitudes as $\mathbf{\hat{a}}_{s,i} = \mathbf{\hat{m}}_{s,i} \circ \mathbf{r}_i$, $s=1,2, \dots ,S$, $i=1,2, \dots ,K$. The overlap-and-add technique and the inverse discrete Fourier transform, using the phase of the mixture signal, is used for reconstructing $\mathbf{\hat{a}}_{s,i}$, $i=1,2, \dots ,K$ in the time domain. \subsection{Mask Estimation and Loss functions}\label{sec:mask1} A large number of training targets and loss functions have been proposed for masking based source separation \cite{erdogan_phase-sensitive_2015,wang_training_2014,erdogan_deep_2017}. Since the one reasonable goal is to have an accurate reconstruction, a loss function based on the reconstruction error instead of the mask estimation error is preferable \cite{erdogan_deep_2017}. In \cite{kolbaek_multi-talker_2017-1}, different such loss functions were investigated for speaker independent multi-talker speech separation and the best performing one was found to be the \ac{PSA} loss function \cite{erdogan_phase-sensitive_2015}, which for frame $i$ is given as \begin{equation} \begin{aligned} J_{i}^{PSA} = \; & \sum_{s=1}^S \| \mathbf{\hat{m}}_{s,i}\circ\mathbf{{r}}_{i} - \mathbf{a}_{s,i}\cos(\phi_{s,i}) \|_2^2 \\ =\;& \sum_{s=1}^S \| \mathbf{\hat{a}}_{s,i} - \mathbf{a}_{s,i}\cos(\phi_{s,i}) \|_2^2, \\ \end{aligned} \label{eqLoss} \end{equation} where $\phi_{s,i} = \phi_{y,i} - \phi_{s,i} $ is the element-wise phase difference between the mixture $\mathbf{y}_i$ and the source $\mathbf{x}_{s,i}$ and $||\cdot||_2$ is the $\ell^2$-norm. In contrast to the classical squared error loss function, i.e. Eq.\;\eqref{eqLoss} without the cosine term, the PSA loss function accounts for some of the errors introduced by the noisy phase used in the reconstruction. When the PSA loss function is used for mask estimation, the actual mask estimated is the \ac{IPSF} \cite{erdogan_phase-sensitive_2015}, which due to the phase correction property is preferable over other commonly used masks such as the ideal ratio mask, or the ideal amplitude mask \cite{erdogan_deep_2017}. \section{Permutation Invariant Training}\label{sec:train1} Permutation Invariant Training\;(PIT) is a generalization of the traditional approach for training Deep Neural Networks\;(DNNs) for regression based source separation problems, such as speaker separation or denoising. For training a DNN based source separation model with $S$ output masks, $\mathbf{\hat{m}}_{s,i}$, $s=1, \dots ,S$, an MSE criterion is typically used and is computed between the true sources $\mathbf{a}_{s,i}$ and the estimated sources $\mathbf{\hat{a}}_{s,i} = \mathbf{\hat{m}}_{s,i} \circ \mathbf{r}_i$, $s = 1, \dots , S$, $i=1,\dots,K$. However, with multiple outputs, it is not trivial to pair the outputs with the correct targets. The commonly used approach for pairing a given output $\mathbf{\hat{a}}_{s,i}$ to a certain target $\mathbf{a}_{s,i}$ is to predefine the targets into an ordered list, such that output one is always paired with e.g. target one, i.e. $(\mathbf{a}_{1,i},\mathbf{\hat{a}}_{1,i})$, output two with target two $(\mathbf{a}_{2,i},\mathbf{\hat{a}}_{2,i})$, etc. For tasks such as speech denoising with a single speaker in noise, or speech separation of known speakers \cite{huang_joint_2015}, simply predefining the ordering of the targets works well and the DNN can learn to correctly separate the sources and will provide the correct source at the output corresponding to the correct target. However, for mixtures containing similar signals, such as unknown equal energy male speakers, this standard training approach fails to converge \cite{yu_permutation_2017,weng_deep_2015,hershey_deep_2016}. Empirically, it is found that DNNs are likely to change permutation from one frame to another for highly similar sources. Hence, predefining the ordering of the targets, might not be the optimal solution, and clearly a bad solution for certain types of signals. This phenomenon, and the challenge of choosing the output-target permutation during training, is commonly known as the label permutation or ambiguity problem \cite{weng_deep_2015,hershey_deep_2016,chen_deep_2017,kolbaek_multi-talker_2017-1}. In \cite{yu_permutation_2017} a solution to the label permutation problem was proposed, where targets are provided as a set instead of an ordered list and the output-target permutation $\theta$, for a given frame, is defined as the permutation that minimizes the cost function in question (e.g. squared error) over all possible permutations $\mathcal{P}$. Following this approach combined with the PSA loss function, a permutation invariant training criterion and corresponding error $J_i^{PIT}$, for the $i^{th}$ frame, can be formulated as \begin{equation} \begin{aligned} J_i^{PIT} = \;& \underset{\theta\in \mathcal{P}}{\text{min}} & \sum_{s=1}^S \| \mathbf{\hat{a}}_{s,i} - \mathbf{a}_{\theta(s),i} \cos(\phi_{\theta(s),i}) \|_2^2. \\ \end{aligned} \label{eqPITseg} \end{equation} As shown in \cite{yu_permutation_2017}, Eq.\;\eqref{eqPITseg} effectively solves the label permutation problem. However, since PIT as defined in Eq.\;\eqref{eqPITseg} operates on frames, the DNN only learns to separate the input mixtures into sources at the frame level, and not the utterance level. In practice, this means that the mixture might be correctly separated, but the frames belonging to a particular speaker are not assigned the same output index throughout the utterance and without exact knowledge about the speaker-output permutation, it is very difficult to correctly reconstruct the separated sources. In order to have the sources separated at the utterance-level, so that all frames from a particular output belong to the same source, additional speaker tracing or very large input-output contexts are needed \cite{yu_permutation_2017}. \subsection{Utterance-Level Permutation Invariant Training } \label{subsec:pittrace} In \cite{kolbaek_multi-talker_2017-1} an extension to PIT, known as utterance-level PIT\;(uPIT) was proposed for solving the speaker-output permutation problem. In uPIT, the output-target permutation $\theta$ is given as the permutation that gives the minimum squared error over all possible permutations for the entire utterance, instead of only a single frame. Formally, the utterance-level permutation used for training is found as \begin{equation} \begin{aligned} \theta^\ast = \underset{\theta\in \mathcal{P}}{\text{argmin}} \sum_{s=1}^S \sum_{i=1}^K \lVert \hat{\mathbf{a}}_{s,i} - \mathbf{a}_{\theta(s),i}\cos(\phi_{\theta(s),i}) \lVert_2^2, \end{aligned} \label{eqPITutt2} \end{equation} and the permutation $\theta^\ast$ is then used \emph{for all} frames within the current utterance, hence an utterance-level loss $J_{\theta^\ast,i}^{uPIT}$ for the $i^{th}$ frame in a given utterance is defined as \begin{equation} \begin{aligned} J_{\theta^\ast,i}^{uPIT} = \;& \sum_{s=1}^S \lVert \mathbf{\hat{a}}_{s,i} - \mathbf{a}_{\theta^\ast(s),i} \cos(\phi_{\theta^\ast(s),i}) \lVert_2^2. \\ \end{aligned} \label{eqPITutt3} \end{equation} Using the same permutation \emph{for all} frames in the entire utterance has the consequence that the smallest per-frame error will not always be used for training as with original PIT. Instead the smallest \emph{per-utterance} error will be used, which enforces the estimated sources to stay at the same DNN outputs for the entire utterance. Ideally, this means that each DNN output contains a single source. Finally, since the whole utterance is needed for computing the utterance-level permutation in Eq.\;\eqref{eqPITutt2}, RNNs are a natural choice of DNN model for this loss function. \section{Experimental Design}\label{sec:expsetup} To study the noise robustness of the uPIT technique, we have conducted several experiments with noise corrupted mixtures of multiple speakers. Since uPIT uses the noise-free source signals as training targets, a denoising capability is already present in the uPIT framework. By simply adding noise to the multi-speaker input mixture, a model trained with uPIT will not only learn to separate the sources but also to remove the noise. \subsection{Noise-Free Multi-Talker Speech Mixtures} \label{subsec:speechdata} We have used the noise-free two-speaker mixture (WSJ0-2mix) and three-speaker mixture (WSJ0-3mix)\footnote{Available at: http://www.merl.com/demos/deep-clustering} datasets for all experiments conducted in this paper. These datasets have been used in \cite{hershey_deep_2016,kolbaek_multi-talker_2017-1,yu_permutation_2017,isik_single-channel_2016}, which allows us to relate the performance of uPIT in noisy conditions with the performance in noise-free conditions. The feature representation is based on 129-dimensional STFT magnitude spectra, extracted from a 256 point STFT using a sampling frequency of 8 kHz, a hanning window size of 32 ms and a 16 ms frame shift. The WSJ0-2mix dataset was derived from the WSJ0 corpus \cite{garofolo_csr-i_1993}. The WSJ0-2mix training set and validation set contain two-speaker mixtures generated by randomly selecting pairs of utterances from 49 male and 51 female speakers from the WSJ0 training set entitled si\_tr\_s. The two utterances are then mixed with a difference in active speech level \cite{noauthor_itu_1993} uniformly chosen between 0\;dB and 5\;dB. The training and validation sets consist of 20000 and 5000 mixtures, respectively, which is equivalent to approximately 30 hours of training data and 5 hours of validation data. The test set was similarly generated using utterances from 16 speakers from the WSJ0 validation set si\_dt\_05 and evaluation set si\_et\_05, and consists of 5000 mixtures or approximately 5 hours of data. That is, the speakers in the test set are different from the speakers in the training and validation sets. The WSJ0-3mix dataset was generated using a similar approach but contains mixtures of speech from three speakers. Since we want a single RNN architecture that can handle both two-speaker and three-speaker mixtures, we have chosen a model architecture with three outputs. The specific architecture is described in detail in Sec.\;\ref{subsec:modelarch}. To ensure that the model can handle both two-speaker and three-speaker mixtures, the model must be trained on both scenarios, so we have combined the WSJ0-2mix and WSJ0-3mix datasets into a larger WSJ0-2+3mix dataset. To allow this fusion, we have extended the WSJ0-2mix dataset with a third "silent" speaker, such that the combined WSJ0-2+3mix dataset consists of only three speaker mixtures, but half of the mixtures contain three speakers, and the remaining half contain two speaker mixtures (and a "silent speaker"). To minimize the risk of numerical issues, e.g. in computing ideal masks, the third "silent" speaker consists of white Gaussian noise with an average energy level 70 dB below the average energy of the other two speakers in the mixture. \subsection{Noisy Multi-Talker Speech Mixtures} \label{subsec:noisedata} To simulate noisy environments, we follow the common approach \cite{kolbaek_speech_2017} for generating noisy mixtures with additive noise and simply add the noise-free WSJ0-2+3mix mixture signal with a noise signal. To achieve a certain SNR the noise signal is scaled based on the active speech level of the noise-free mixture signal as per ITU P.56 \cite{noauthor_itu_1993}. To evaluate the robustness of the uPIT model against a stationary noise type, we use a synthetic Speech Shaped Noise\;(SSN) signal. The SSN noise signal is constructed by filtering a Gaussian white noise sequence through a $12^{th}$-order all-pole filter with coefficients found from linear predictive coding analysis of 100 randomly chosen TIMIT sentences \cite{garofolo_darpa_1993}. To evaluate the robustness against a highly non-stationary noise type we use a synthetic 6-speaker Babble\;(BBL) noise. The BBL noise signal is also based on TIMIT. The corpus, which consists of a total of 6300 spoken sentences, is randomly divided into 6 groups of 1050 concatenated utterances. Each group is then normalized to unit energy and truncated to equal length followed by addition of the six groups. This results in a BBL noise sequence with a duration of over 50 min. To evaluate the robustness against realistic noise types we use the street (STR), cafeteria\;(CAF), bus\;(BUS), and pedestrian\;(PED) noise signals from the CHiME3 dataset \cite{barker_third_2015}. These noise signals are real-life recordings in their respective environments. All six noise signals are divided into a 40 min.\;training sequence, a 5 min.\;validation sequence and a 5 min.\;test sequence. That is, the noise signals used for training and validation are different from the sequence used for testing. \subsection{Model Architectures and Training} \label{subsec:modelarch} For evaluating uPIT in noisy environments we have trained a total of seven bi-directional LSTM RNNs \cite{hochreiter_long_1997}, using the training conditions, i.e. datasets and noise types, presented in Table.\;\ref{tab:models}. \begin{table} \caption{Training conditions for different models.} \label{tab:models} \centering \setlength\tabcolsep{5pt} \resizebox{0.6\columnwidth}{!} \begin{tabular}{ccc} \midrule \midrule Model ID & \multicolumn{2}{l} {Dataset + Noise type (SNR: -5 dB -- 10 dB)} \\ \midrule LSTM1 & \multicolumn{2}{l} {WSJ0-2+3mix + SSN } \\ LSTM2 & \multicolumn{2}{l} {WSJ0-2+3mix + BBL } \\ LSTM3 & \multicolumn{2}{l} {WSJ0-2+3mix + STR } \\ LSTM4 & \multicolumn{2}{l} {WSJ0-2+3mix + CAF } \\ LSTM5 &\multicolumn{2}{l} {WSJ0-2+3mix + SSN + BBL + STR + CAF } \\ LSTM6 & \multicolumn{2}{l} {WSJ0-2mix + BBL } \\ LSTM7 & \multicolumn{2}{l} {WSJ0-3mix + BBL } \\ \midrule \midrule \end{tabular}} \end{table} LSTM1-5 were trained on the WSJ0-2+3mix dataset, which contains a mix of both two-speaker and three-speaker mixtures. LSTM1-4 are noise type specific in the sense that they were trained using only a single noise type. LSTM5 was trained on all four noise types. LSTM6 and LSTM7 were trained using WSJ0-2mix and WSJ0-3mix datasets, respectively, and only a single noise type. LSTM5 will show the performance degradation, if any, when less \emph{a priori} knowledge about the noise types is available. Similarly, LSTM6-7 will show the potential performance improvement if the number of speakers in the mixture is known \emph{a priori}. Each mixture in the dataset was corrupted with noise at a specific SNR, uniformly chosen between -5\;dB and 10\;dB. Each model has three bi-directional LSTM layers, and a fully-connected output layer with ReLU \cite{goodfellow_deep_2016} activation functions. LSTM1-5 and LSTM7 have 1280 LSTM cells in each layer and LSTM6 has 896 cells, to be compliant with \cite{kolbaek_multi-talker_2017-1}. The input dimension is 129, i.e a single frame $\mathbf{r}_i$ and the output dimension is $3\times129 = 387$, i.e. $\mathbf{\hat{a}}_{s,i}$, $s=1,2,3$. We apply 50\% dropout \cite{goodfellow_deep_2016} between the LSTM layers, and the outputs from the forward and backward LSTMs, from one layer, are concatenated before they are used as input to the subsequent layer. LSTM6 has approximately $46\cdot10^6$ trainable parameters, and LSTM1-5 and 7 have approximately $94\cdot 10^6$ trainable parameters, which are found using stochastic gradient descent with gradients found by backpropagation. In all the experiments, the maximum number of epochs was set to 200 and the learning rates were set to $2 \cdot 10^{-5}$ per sample initially, and scaled down by $0.7$ when the training cost increased on the training set. The training was terminated when the learning rate got below $10^{-10}$. Each minibatch contains 8 randomly selected utterances. All models are implemented using the Microsoft Cognitive Toolkit (CNTK) \cite{agarwal_introduction_2014}\footnote{Available at: \url{https://www.cntk.ai/}}. \section{Experimental Results}\label{sec:exp2} We evaluated the noise robustness of LSTM1-7 using the Signal to Distortion Ratio\;(SDR) \cite{vincent_performance_2006} and the Extended Short-Time Objective Intelligibility\;(ESTOI) measure \cite{jensen_algorithm_2016}. The SDR is an often used performance metric for source separation and is defined in dB. The ESTOI measure estimates speech intelligibility and has been found to be highly correlated with human listening tests \cite{jensen_algorithm_2016}, especially for modulated maskers. The ESTOI measure is defined in the range $[-1, 1]$, and higher is better. When evaluating SDR and ESTOI, we choose the output-target permutation that maximizes the given performance metric. Furthermore, when evaluating two-speaker mixtures, we identify the silent speaker as the output with the least energy and then compute the performance metric based on the remaining two outputs. \Cref{tab:sdr_ssn,tab:sdr_bbl,tab:sdr_str,tab:sdr_caf} summarize the SDR \emph{improvements} achieved by LSTM1-5 on two and three-speaker mixtures corrupted by SSN, BBL, STR, and CAF noise, respectively. The improvements are relative to the SDR of the noisy mixture without processing ("No Proc." in Tables). \Cref{tab:stoi_ssn,tab:stoi_bbl,tab:stoi_str,tab:stoi_caf} summarize ESTOI \emph{improvements} achieved by the same models in similar conditions. We evaluate the models at the challenging SNR of $-5$\;dB, as well as at $0$,\; $5$\;, and $20$\;dB. At an input SNR of $-5$\;dB, speech intelligibility, as estimated by ESTOI, is severely degraded, primarily due to the noise component, whereas speech intelligibility degradation at $20$\;dB is primarily caused by the competing talkers in the mixture itself. As a reference, we also reported the IPSF performance, which uses oracle information and therefore serves as an upper performance bound on this particular task. From \Cref{tab:sdr_ssn,tab:sdr_bbl,tab:sdr_str,tab:sdr_caf,tab:stoi_ssn,tab:stoi_bbl,tab:stoi_str,tab:stoi_caf} we see that all noise-type specific models, i.e. LSTM1-4, in general achieve large SDR and ESTOI improvements with an average improvement of $9.1$\;dB and $0.18$ for SDR and ESTOI, respectively, for two-speaker mixtures and $7.2$\;dB and $0.13$, respectively, for three-speaker mixtures. Furthermore, we see that LSTM5 performs only slightly worse than the noise type specific models, which is interesting, since LSTM5 and LSMT1-4 have all been trained with 60 hours of speech, but LSTM5 have only seen $15$ hours of each noise type, compared to $60$ hours for LSTM1-4. We also observe that the highly non-stationary BBL noise seems to be considerably harder than the three other noise types, which corresponds well with existing literature \cite{kolbaek_speech_2017,loizou_speech_2013,erkelens_minimum_2007}. \Cref{tab:sdr_bbl_spkr,tab:stoi_bbl_spkr} summarize the performance of LSTM6 and LSTM7. We observe that both models perform approximately similar to the noise-type-general LSTM5. More surprisingly, we see that LSTM2 consistently outperforms both LSTM6 and LSTM7, which corresponds well with a similar observation in the noise-free case in \cite{kolbaek_multi-talker_2017-1}. These results are of great importance, since they show that training a model on noisy three-speaker mixtures helps the model separating noisy two-speaker mixtures, and vice versa. \Cref{tab:sdr_ped,tab:stoi_ped} summarize the performance of LSTM5, when evaluated using speech mixtures corrupted with the two unknown noise types, PED and BUS, i.e. noise types not included in the training set. We see that LSTM5 achieves large SDR and ESTOI improvements for both noise types, at almost all SNRs. More importantly, we observe that the scores are comparable with, and in some cases even exceed, the performance of LSTM5, when it was evaluated using known noise types as reported in \Cref{tab:sdr_ssn,tab:sdr_bbl,tab:sdr_str,tab:sdr_caf,tab:stoi_ssn,tab:stoi_bbl,tab:stoi_str,tab:stoi_caf}. These results indicate that LSTM5 is relatively robust against variations in the noise distribution. In general, we observe SDR improvements for all models that are comparable in magnitude with the noise-free case \cite{yu_permutation_2017,kolbaek_multi-talker_2017-1,hershey_deep_2016,isik_single-channel_2016}. However, the SDR measure, as well as ESTOI, do not differentiate between distortions from other speakers (such as source to inference ratio from \cite{vincent_performance_2006}) and distortion from the noise source. This means that the trade-off between speech separation and noise-reduction is yet to be fully understood. We leave this topic for future research. \begin{table} \caption{SDR improvements for LSTM1 and 5 tested on SSN.} \vspace{-2mm} \label{tab:sdr_ssn} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM1\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM1\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm1_sdr_ssn.txt} \end{tabular}} \end{table} % \begin{table} \caption{SDR improvements for LSTM2 and 5 tested on BBL.} \vspace{-2mm} \label{tab:sdr_bbl} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM2\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM2\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm2_sdr_bbl.txt} \end{tabular}} \end{table} % \begin{table} \caption{SDR improvements for LSTM3 and 5 tested on STR.} \vspace{-2mm} \label{tab:sdr_str} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM3\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM3\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm3_sdr_str.txt} \end{tabular}} \end{table} % \begin{table} \caption{SDR improvements for LSTM4 and 5 tested on CAF.} \vspace{-2mm} \label{tab:sdr_caf} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM4\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM4\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm4_sdr_caf.txt} \end{tabular}} \end{table} % \begin{table} \caption{SDR improvements for LSTM6, 7 and 5 tested on BBL.} \vspace{-2mm} \label{tab:sdr_bbl_spkr} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM6\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM7\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm6-7_sdr_bbl.txt} \end{tabular}} \end{table} % \begin{table} \caption{SDR improvements for LSTM5 tested on BUS and PED.} \vspace{-2mm} \label{tab:sdr_ped} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccccccc} \midrule \midrule & \multicolumn{6}{c} {2-Speaker } & \multicolumn{6}{c} {3-Speaker} \\ \cmidrule(l){2-7} \cmidrule(l){8-13} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular}} & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular}} \\ \cmidrule(l){2-7} \cmidrule(l){8-13} & BUS & PED & BUS & PED & BUS & PED & BUS & PED & BUS & PED & BUS & PED \\ \midrule \input{figures/resE/lstm5_sdr_bus_ped_1.txt} \end{tabular}} \end{table} \begin{table} \caption{ESTOI improvements for LSTM1 and 5 tested on SSN.} \vspace{-2mm} \label{tab:stoi_ssn} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM1\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM1\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm1_estoi_ssn.txt} \end{tabular}} \end{table} \begin{table} \caption{ESTOI improvements for LSTM2 and 5 tested on BBL.} \vspace{-2mm} \label{tab:stoi_bbl} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM2\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM2\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm2_estoi_bbl.txt} \end{tabular}} \end{table} \begin{table} \caption{ESTOI improvements for LSTM3 and 5 tested on STR.} \vspace{-2mm} \label{tab:stoi_str} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM3\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM3\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm3_estoi_str.txt} \end{tabular}} \end{table} \begin{table} \caption{ESTOI improvements for LSTM4 and 5 tested on CAF.} \vspace{-2mm} \label{tab:stoi_caf} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM4\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM4\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm4_estoi_caf.txt} \end{tabular}} \end{table} \begin{table} \caption{ESTOI improvements for LSTM6, 7 and 5 tested on BBL.} \vspace{-2mm} \label{tab:stoi_bbl_spkr} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccc} \midrule \midrule & \multicolumn{4}{c} {2-Speaker } & \multicolumn{4}{c} {3-Speaker} \\ \cmidrule(l){2-5} \cmidrule(l){6-9} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM6\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} & \begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} & \begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM7\end{tabular} & \begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} \\ \midrule \input{figures/resE/lstm6-7_estoi_bbl.txt} \end{tabular}} \end{table} \begin{table} \caption{ESTOI improvements for LSTM5 tested on BUS and PED.} \vspace{-2mm} \label{tab:stoi_ped} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% \begin{tabular}{ccccccccccccc} \midrule \midrule & \multicolumn{6}{c} {2-Speaker } & \multicolumn{6}{c} {3-Speaker} \\ \cmidrule(l){2-7} \cmidrule(l){8-13} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}No \\ Proc.\end{tabular}} & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}} IPSF \end{tabular} } & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}LSTM5\end{tabular}} \\ \cmidrule(l){2-7} \cmidrule(l){8-13} & BUS & PED & BUS & PED & BUS & PED & BUS & PED & BUS & PED & BUS & PED \\ \midrule \input{figures/resE/lstm5_estoi_bus_ped_1.txt} \end{tabular}} \end{table} \pagebreak \section{Conclusion}\label{sec:conclusion2} In this paper we have proposed utterance-level Permutation Invariant Training\;(uPIT) for speaker independent multi-talker speech separation and denoising. Differently from prior works, that focus only on the ideal noise-free setting, we focus on the more realistic scenario of speech separation in noisy environments. Specifically, using the uPIT technique we have trained bi-directional Long Short-Term Memory\;(LSTM) Recurrent Neural Networks (RNNs), to separate two and three-speaker mixtures corrupted by multiple noise types at a wide range of Signal to Noise Ratios\;(SNRs). We show that bi-directional LSTM RNNs trained with uPIT are capable of improving both Signal to Distortion Ratio\;(SDR), as well as the Extended Short-Time Objective Intelligibility\;(ESTOI) measure for challenging noise types and SNRs. Specifically, we show that LSTM RNNs achieve large SDR and ESTOI improvements, when evaluated using noise types seen during training, and that a single model is capable of handling multiple noise types with only a slight decrease in performance. Furthermore, we show that a single LSTM RNN can handle both two-speaker and three-speaker noisy mixtures, without \emph{a priori} knowledge about the exact number of speakers. Finally, we show that LSTM RNNs trained using uPIT generalizes well to unknown noise types. \section{Introduction} \label{sec:intro6} Design and development of Speech Enhancement\,(SE) algorithms capable of improving speech quality and intelligibility has been a long-lasting goal in both academia and industry \cite{hendriks_dft-domain_2013,loizou_speech_2013}. Such algorithms are useful for a wide range of applications e.g. for mobile communications devices and hearing assistive devices \cite{hendriks_dft-domain_2013}. Despite a large research effort for more than 30 years \cite{ephraim_speech_1984,loizou_speech_2013,hendriks_dft-domain_2013} modern single-microphone SE algorithms still perform unsatisfactorily in the complex acoustic environments, which users of e.g. hearing assistive devices are exposed to on a daily basis, e.g. traffic noise, cafeteria noise, or competing speakers. Traditionally, SE algorithms have been divided into at least two groups; statistical-model based techniques and data-driven techniques. The first\linebreak group encompasses techniques such as spectral subtraction, the Wiener filter and the short-time spectral amplitude minimum mean squared error estimator \cite{ephraim_speech_1984,hendriks_dft-domain_2013,loizou_speech_2013}. These techniques make statistical assumptions about the probability distributions of the speech and noise signals, that enable them to suppress the noise dominated time-frequency regions of the noisy speech signal. In particularly, for stationary noise types this type of algorithms may perform well in terms of speech quality, but in general these techniques do not improve speech intelligibility \cite{hu_comparative_2007,luts_multicenter_2010,jensen_spectral_2012}. The second group encompasses data-driven or machine learning techniques e.g. based on non-negative matrix factorization \cite{grais_single_2011}, support vector machines \cite{wang_towards_2013}, and Deep Neural Networks\,(DNNs) \cite{xu_regression_2015,healy_algorithm_2015}. These techniques make no statistical assumptions. Instead, they learn to suppress noise by observing a large number of representative pairs of noisy and noise-free speech signals in a supervised learning process. SE algorithms based on DNNs can, to some extent, improve speech intelligibility for hearing impaired and normal hearing people, in noisy conditions, if sufficient \emph{a priori} knowledge is available e.g. the identity of the speaker or the noise type. \cite{chen_large-scale_2016,healy_algorithm_2017,kolbaek_speech_2017}. Although the techniques mentioned above are fundamentally different, they typically share at least two common properties. First, they often aim to minimize a \acf{MSE} cost function, and secondly, they operate on short frames ($\approx$ 20 -- 30 ms ) in the Short-Time discrete Fourier Transform\,(STFT) domain \cite{hendriks_dft-domain_2013,loizou_speech_2013}. However, it is well known \cite{loizou_speech_2013,moore_introduction_2013} that the human auditory system has a non-linear frequency sensitivity, which is often approximated using e.g. a Gammatone or a one-third octave filter bank \cite{loizou_speech_2013}. Furthermore, it is known that preservation of modulation frequencies below 7 Hz is critical for speech intelligibility \cite{elliott_modulation_2009,moore_introduction_2013}. This suggests that SE algorithms aimed at the human auditory system could benefit by incorporating such information. Numerous works exist, e.g. \cite{hu_perceptually_2003,ephraim_speech_1985,virag_single_1999,loizou_speech_2005,lightburn_sobm_2015,han_perceptual_2016,shivakumar_perception_2016,koizumi_dnn-based_2017,healy_algorithm_2015} and \cite[Sec. 2.2.3]{hendriks_dft-domain_2013} and the references therein, where SE algorithms have been designed with perceptual aspects in mind. However, although these algorithms do take some perceptual aspects into account, they do not directly optimize for speech intelligibility. In this paper we propose an SE system that maximizes an objective speech intelligibility estimator. Specifically, we design a DNN based SE system that maximizes an approximation of the Short-Time Objective Intelligibility\,(STOI) \cite{taal_algorithm_2011} measure. The STOI measure has been found to be highly correlated with intelligibility as measured in human listening tests \cite{taal_algorithm_2011,loizou_speech_2013}. We derive analytical expressions for the required gradients used for the DNN weight updates during training and use these closed-form expressions to identify desirable properties of the approximate-STOI cost function. Finally, we study the potential performance gain between the proposed approximate-STOI cost function with a classical MSE cost function. We note that our goal is not to achieve state-of-the-art STOI improvements per se, but rather to study and compare the proposed approximate-STOI based SE system to existing DNN based enhancement schemes. Further improvement may straightforwardly be achieved with larger datasets and complex models like long short-term memory recurrent, or convolutional, neural networks \cite{goodfellow_deep_2016}. \section{Speech Enhancement System}\label{sec:DNNSE} In the following we introduce the approximate-STOI measure and we present the DNN framework used to maximize it. Finally, we discuss techniques used to reconstruct the enhanced and approximate-STOI optimal speech signal in the time-domain. \subsection{Approximating Short-Time Objective Intelligibility}\label{sec:stoiApprox} Let $x[n]$ be the $n^{th}$ sample of the clean time-domain speech signal and let a noisy observation $y[n]$ be defined as \begin{equation} y[n] = x[n] + z[n], \label{eq61} \end{equation} where $z[n]$ is an additive noise sample. Furthermore, let ${x}(k,m)$ and ${y}(k,m)$, $k = 1,2,\dots, \frac{K}{2}+1$, $m=1,2,\dots M, $ be the single-sided magnitude spectra of the $K$-point Short-Time discrete Fourier Transforms (STFT) of $x[n]$ and $y[n]$, respectively, where $M$ is the number of STFT frames. Also, let $\hat{x}(k,m)$ be an estimate of $x(k,m)$ obtained as $\hat{x}(k,m) = \hat{g}(k,m)y(k,m)$ where $\hat{g}(k,m)$ is an estimated gain value. In this study we use a 10 kHz sample frequency and a 256 point STFT, i.e. $K=256$, with a Hann-window size of 256 samples (25.6 ms) and a 128 sample frame shift (12.8 ms). Similarly to STOI \cite{taal_algorithm_2011}, we define a short-time temporal envelope vector of the $j^{th}$ one-third octave band for the clean speech signal as \begin{equation} \mathbf{x}_{j,m} = [ X_j( m-N+1 ), \; X_j( m-N+2 ), \dots , X_j( m ) ]^T, \end{equation} where \begin{equation} X_j( m ) = \sqrt{\sum_{k=k_1(j)}^{k_2(j)} x(k,m)^2}, \label{eq62} \end{equation} and $k_1(j)$ and $k_2(j)$ denote the first and last STFT bin index of the $j^{th}$ one-third octave band, respectively. Similarly, we define $\mathbf{y}_{j,m}$ and $Y_j( m )$ for the noisy observation. Also, let $\hat{\mathbf{x}}_{j,m} = diag(\hat{\mathbf{g}}_{j,m})\mathbf{y}_{j,m}$ be the short-time temporal one-third octave band envelope vector of the enhanced speech signal, where $\hat{\mathbf{g}}_{j,m}$ is a gain vector defined in the $j^{th}$ one-third octave band and $diag(\hat{\mathbf{g}}_{j,m})$ is a diagonal matrix with the elements of $\hat{\mathbf{g}}_{j,m}$ on the main diagonal. We use $N=30$ such that the short-time temporal one-third octave band envelope vectors will span a duration of 384 ms, which ensures that important modulation frequencies are captured \cite{taal_algorithm_2011}. In total, $J=15$ one-third octave bands are used with the first band having a center frequency of 150 Hz and the last one of approximately 3.8 kHz. These frequencies are chosen such that they span the frequency range in which human speech normally lie \cite{taal_algorithm_2011}. For mathematical tractability, we discard the clipping step% \footnote{It has been observed empirically, that omitting the clipping step most often does not affect the performance of STOI, e.g. \cite{lightburn_sobm_2015,jensen_algorithm_2016,andersen_predicting_2016,taal_matching_2012}.}% , otherwise performed by STOI \cite{taal_algorithm_2011}, and define the approximated STOI measure as \begin{equation} \mathcal{L} ( \mathbf{x}_{j,m},\hat{\mathbf{x}}_{j,m}) = \frac{\left({\mathbf{x}}_{j,m} - \mu_{{\mathbf{x}}_{j,m}}\right)^T \left(\hat{\mathbf{x}}_{j,m} - \mu_{\hat{\mathbf{x}}_{j,m}}\right)}{ \left\lVert {\mathbf{x}}_{j,m} - \mu_{{\mathbf{x}}_{j,m}} \right\rVert \; \left\lVert\hat{\mathbf{x}}_{j,m} - \mu_{\hat{\mathbf{x}}_{j,m}} \right\rVert }, \label{eq:stoicost} \end{equation} where $\left\lVert \cdot \right\rVert$ is the euclidean $\ell^2$-norm and $\mu_{{\mathbf{x}}_{j,m}}$ and $\mu_{\hat{\mathbf{x}}_{j,m}}$ are the sample means of $\mathbf{x}_{j,m}$ and $\hat{\mathbf{x}}_{j,m}$, respectively. Obviously, $\mathcal{L} ( \mathbf{x}_{j,m},\hat{\mathbf{x}}_{j,m})$ is simply the \ac{ELC} between the vectors $\mathbf{x}_{j,m}$ and $\hat{\mathbf{x}}_{j,m}$. \subsection{Maximizing Approximated STOI Using DNNs}\label{sec:stoiMax} The approximated STOI measure given by Eq.\;\eqref{eq:stoicost} is defined in a one-third octave band domain and our goal is to find $\hat{\mathbf{x}}_{j,m} = diag(\hat{\mathbf{g}}_{j,m})\mathbf{y}_{j,m}$ such that Eq.\;\eqref{eq:stoicost} is maximized, i.e. finding an optimal gain vector $\hat{\mathbf{g}}_{j,m}$. In this study we estimate these optimal gains using DNNs. Specifically, we use Eq.\;\eqref{eq:stoicost} as a cost function and train multiple feed-forward DNNs, one for each one-third octave band, to estimate gain vectors $\hat{\mathbf{g}}_{j,m}$, such that the approximated STOI measure is maximized. For the remainder of this paragraph we omit the subscripts $j$ and $m$ for convenience. Most modern deep learning toolkits, e.g. \ac{CNTK} \cite{agarwal_introduction_2014}, perform automatic differentiation, which allow one to train a DNN with a custom cost function, without the need of computing the gradients of the cost function explicitly \cite{goodfellow_deep_2016}. Nevertheless, when working with cost functions that have not yet been exhaustively studied, such as the approximated STOI measure, an analytic expression of the gradient can be valuable for studying important properties, such as gradient $\ell^2$-norm. It can be shown (details omitted due to space limitations) that the gradient of Eq.\;\eqref{eq:stoicost}, with respect to the desired signal vector $\hat{\mathbf{x}}$, is given by \begin{equation} \nabla \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) = \left[ \frac{\partial \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})}{\partial \hat{{x}}_{1}}, \frac{\partial \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})}{\partial \hat{{x}}_{2}}, \dots, \frac{\partial \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})}{\partial \hat{{x}}_{N}} \right]^T, \label{eq:stoigrad} \end{equation} where \begin{flalign} \frac{\partial \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})}{\partial \hat{x}_{m}} = % \frac{\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) \left(x_m - \mu_{\mathbf{x}}\right)}{\left(\hat{\mathbf{x}} - \mu_{\hat{\mathbf{x}}} \right)^T \left( \mathbf{x} - \mu_{\mathbf{x}} \right)} - \frac{\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) \left(\hat{x}_m - \mu_{\hat{\mathbf{x}}}\right)}{\left(\hat{\mathbf{x}} - \mu_{\hat{\mathbf{x}}} \right)^T\left(\hat{\mathbf{x}} - \mu_{\hat{\mathbf{x}}} \right)} , \label{eq:stoipart} \end{flalign} is the partial derivative of $\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})$ with respect to entry $m$ of $\hat{\mathbf{x}}$. Furthermore, it can be shown that the $\ell^2$-norm of the gradient as formulated by Eqs.\;\eqref{eq:stoigrad} and \eqref{eq:stoipart}, is given by \begin{equation} \left\lVert \nabla \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) \right\rVert = \sqrt{1-\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})^2} \left\lVert \hat{\mathbf{x}} \right\rVert ^{-1}, \label{eq:stoigradnorm} \end{equation} which is shown in Fig.\;\ref{fig:stoigrad} as function of $\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})$ for the complete range $[-1,1]$, and for $\left\lVert \hat{\mathbf{x}} \right\rVert = 1$. \begin{figure}[] \centering \centerline{\includegraphics[width=0.8\linewidth]{figures/figF/stoigrad/grad_norm.pdf}} \vspace{-3mm} \caption{$\ell^2$-norm of Eq.\;\eqref{eq:stoigrad} as function of cost function value.} \label{fig:stoigrad} \vspace{-5mm} \end{figure} We see from Fig.\,\ref{fig:stoigrad} that the $\ell^2$-norm of $\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})$ is a concave function with a global maximum at $\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) = 0$ and is symmetric around zero. We also observe that $ \left\lVert\nabla \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) \right\rVert$ is monotonically decreasing when $ \mathcal{L} (\mathbf{x},\hat{\mathbf{x}}) < 0$ and $ \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) > 0$ with $ \left\lVert\nabla \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) \right\rVert = 0$ when $\mathbf{x}$ and $\hat{\mathbf{x}}$ are either perfectly correlated or perfectly anti-correlated. Since $ \left\lVert\nabla \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) \right\rVert$ is large when $\mathbf{x}$ and $\hat{\mathbf{x}}$ are uncorrelated and zero when perfectly correlated, and $ \left\lVert\nabla \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}}) \right\rVert \neq 0$ otherwise, Eq.\;\eqref{eq:stoicost} is well suited as a cost function for gradient-based optimization techniques, such as Stochastic Gradient Descent\,(SGD) \cite{goodfellow_deep_2016}, since it guarantees non-zero step lengths for all inputs during optimization except at the optimal solution. In practice, to apply SGD we minimize $- \mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})$. \subsection{Reconstructing Approximate-STOI Optimal Speech} When a gain vector $\hat{\mathbf{g}}_{j,m}$ has been estimated by a DNN, the enhanced speech envelope in the one-third octave band domain can be computed as $\hat{\mathbf{x}}_{j,m} = diag(\hat{\mathbf{g}}_{j,m})\mathbf{y}_{j,m}$. However, what we are really interested in is $\hat{x}(k,m)$, i.e. the estimated speech signal in the STFT domain, since $\hat{x}(k,m)$ can straightforwardly be transformed into the time-domain using the overlap-and-add technique \cite{loizou_speech_2013}. We therefore seek a mapping from the gain vector $\hat{\mathbf{g}}_{j,m}$ estimated in the one-third octave band domain, to the gain $\hat{g}(k,m)$, for a single STFT coefficient. To do so, let $\hat{g}_j(m)$ denote the gain value estimated by a DNN to be applied to the noisy one-third octave band amplitude in frame $m$. We can then derive the relationship between the gain value $\hat{g}_j(m) \geq 0 $ in the one-third octave band, and the corresponding gain values $\hat{g}(k,m) \geq 0$ in the STFT domain as \begin{equation} \hat{X}_j( m ) = \hat{g}_j(m) Y_j( m ) = \sqrt{\sum_{k=k_1(j)}^{k_2(j)-1} \left(\hat{g}(k,m)y(k,m) \right)^2}. \label{eq63} \end{equation} One solution to Eq\;\eqref{eq63} is \begin{equation} \hat{g}_j(m) = \hat{g}(k,m) , \; k=k_1(j), \dots k_2(j)-1. \label{eq64} \end{equation} Generally, the solution in Eq.\,\eqref{eq64} is not unique; many choices of $\hat{g}(k,m)$ exist that give rise to the same estimated one-third octave band $\hat{X}_j( m )$ (and hence the same value of $\mathcal{L} ( \mathbf{x},\hat{\mathbf{x}})$). We choose, for convenience, a uniform gain across the STFT coefficients within a one-third octave band. Since envelope estimates $\hat{X}_j( m )$ are computed for successive values of $m$, N estimates exist for each $\hat{X}_j( m )$, which are averaged during enhancement. When reconstructing the enhanced speech signal in the time domain, we use the overlap-and-add technique using the phase of the noisy STFT coefficients \cite{loizou_speech_2013}. \section{Experimental Design} \label{sec:expDesign} To evaluate the performance of the approximate-STOI optimal DNN based SE system we have conducted series of experiments involving multiple matched and unmatched noise types at various SNRs. \subsection{Noisy Speech Mixtures} The clean speech signals used for training all models are from the \acf{WSJ0} corpus \cite{garofolo_csr-i_1993}. The utterances used for training and validation are generated by randomly selecting utterances from 44 male and 47 female speakers from the WSJ0 training set entitled si\_tr\_s. The training and validation sets consist of 20000 and 2000 utterances, respectively, which is equivalent to approximately 37 hours of training data and 4 hours of validation data. The test set is similarly generated using utterances from 16 speakers from the WSJ0 validation set si\_dt\_05 and evaluation set si\_et\_05, and consists of 1000 mixtures or approximately 2 hours of data, see \cite{kolbaek_supplemental_nodate} for further details. Notice, the speakers in the test set are different from the speakers in the validation and training sets. We use six different noise types: two synthetic signals and four noise signals recorded in real-life. The synthetic noise signals encompass a stationary Speech Shaped Noise\;(SSN) signal and a highly non-stationary 6-speaker Babble\;(BBL) noise. For real-life noise signals we use the street\;(STR), cafeteria\;(CAF), bus\;(BUS), and pedestrian\;(PED) noise signals from the CHiME3 dataset \cite{barker_third_2015}. The SSN noise signal is Gaussian white noise, shaped according to the long-term spectrum of the TIMIT corpus \cite{garofolo_darpa_1993}. Similarly, the BBL noise signal is constructed by mixing utterances from TIMIT. Further details on the design of the SSN and BBL noise signals can be found in \cite{kolbaek_speech_2017}. All noise signals are split into non-overlapping sequences with a 40 min.\;training sequence, a 5 min.\;validation sequence and a 5 min.\;test sequence, i.e. there is no overlap between the noise sequences used for training, validation and test. \pagebreak The noisy speech signals used for training and testing are constructed using Eq.\;\eqref{eq61}, where a clean speech signal $x[n]$ is added to a noise sequence $z[n]$ of equal length. To achieve a certain SNR, the noise signal is scaled based on the active speech level of the clean speech signal as per ITU P.56 \cite{itu_rec._1993}. The SNRs used for the training and validation sets are chosen uniformly from $[-5 , 10 ]$ dB. The SNR range is chosen to ensure that SNRs are included where intelligibility ranges from degraded to perfectly intelligible. \subsection{Model Architecture and Training} To evaluate the performance of the proposed SE system a total of ten systems, identified as S0 -- S9, have been trained using different cost functions and noise types as presented in Table\;\ref{tab:models1}. \begin{table \caption{Training conditions for different SE systems.} \label{tab:models1} \centering \setlength\tabcolsep{4pt} \resizebox{0.75\columnwidth}{!} \begin{tabular}{lcccccccccc} \midrule \midrule ID: & S0 & S1 & S2 & S3 & S4 & S5 & S6 & S7 &S8 & S9 \\ Cost: & ELC & ELC & ELC & ELC & ELC & EMSE & EMSE & EMSE & EMSE & EMSE\\ Noise: & SSN & BBL & CAF & STR & ALL & SSN & BBL & CAF & STR & ALL \\ \midrule \midrule \end{tabular}} \end{table} Five systems (S0--S4) have been trained using the ELC loss from Eq.\;\eqref{eq:stoicost} and five systems (S5--S9) have been trained using a standard MSE loss, denoted as \ac{EMSE}, since it operates on short-time temporal one-third octave band envelope vectors. This is to investigate the potential performance difference between models trained with an approximate-STOI loss and models trained with the commonly used MSE loss. Eight systems (S0--S3 and S5--S8) are trained as noise type specific systems, i.e. they are trained using only a single noise type. Two systems (S4 and S9) are trained as noise type general systems, i.e. they are trained on all noise types (Noise: "ALL" in Table\;\ref{tab:models1}). This is to investigate the performance drop, if any, when a single system is trained to handle multiple noise types. Each DNN consists of three hidden layers with 512 units with ReLU activation functions and a sigmoid output layer. The DNNs are trained using SGD with the backpropagation technique and batch normalization \cite{goodfellow_deep_2016}. The DNNs are trained for a maximum of 200 epochs with a minibatch size of 256 randomly selected short-time temporal one-third octave band envelope vectors and the learning rates were set to $0.01$, and $5 \cdot 10^{-5}$ per sample initially, for S0--S4, and S5--S9, respectively. The learning rates were scaled down by $0.7$ when the training cost increased on the validation set. The training was terminated when the learning rate was below $10^{-10}$. The different learning rates for the systems trained with the ELC cost function and the systems trained with the EMSE cost functions were found from preliminary experiments. All models were implemented using CNTK \cite{agarwal_introduction_2014} and the script files needed to reproduce the reported results can be found in \cite{kolbaek_supplemental_nodate}. \section{Experimental Results} \label{sec:expResults} We have evaluated the performance of the ten systems based on their average ELC and STOI scores computed on the test set. The STOI score is computed using the enhanced and reconstructed time-domain speech signal, whereas the ELC score is computed using short-time one-third octave band temporal envelope vectors. \begin{table}[t] \caption{ELC results for S0 -- S9 tested with SSN, BBL, CAF, and STR} \label{tab:lincorr_combined} \centering \setlength\tabcolsep{5pt} \resizebox{0.8\columnwidth}{!}{% \begin{tabular}{ccccccccccc} \midrule \midrule & \multicolumn{5}{c} {SSN} & \multicolumn{5}{c} {BBL} \\ \cmidrule(l){2-6} \cmidrule(l){7-11} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & UP. & \begin{tabular}[c]{@{}c@{}}S0 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S5 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} & % UP. & \begin{tabular}[c]{@{}c@{}}S1 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S6 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} \\ \midrule % \input{figures/resF/dnn1000_dnn1004_dnn1010_dnn1014_combined_lincorr_1.txt} \midrule \end{tabular}} \begin{tabular}{c} \end{tabular} \end{table} \begin{table}[t] \centering \setlength\tabcolsep{5pt} \resizebox{0.8\columnwidth}{!}{% \begin{tabular}{ccccccccccc} & \multicolumn{5}{c} {CAF} & \multicolumn{5}{c} {STR} \\ \cmidrule(l){2-6} \cmidrule(l){7-11} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & UP. & \begin{tabular}[c]{@{}c@{}}S2 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S7 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} & % UP. & \begin{tabular}[c]{@{}c@{}}S3 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S8 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} \\ \midrule \input{figures/resF/dnn1000_dnn1004_dnn1010_dnn1014_combined_lincorr_2.txt} \midrule \midrule \end{tabular}} \end{table} \begin{table}[t] \caption{STOI results for S0 -- S9 tested with SSN, BBL, CAF, and STR} \label{tab:stoi_combined} \centering \setlength\tabcolsep{5pt} \resizebox{0.8\columnwidth}{!}{% \begin{tabular}{ccccccccccc} \midrule \midrule & \multicolumn{5}{c} {SSN} & \multicolumn{5}{c} {BBL} \\ \cmidrule(l){2-6} \cmidrule(l){7-11} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & UP. & \begin{tabular}[c]{@{}c@{}}S0 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S5 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} & % UP. & \begin{tabular}[c]{@{}c@{}}S1 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S6 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} \\ \midrule \input{figures/resF/dnn1000_dnn1004_dnn1010_dnn1014_combined_stoi_1.txt} \midrule \end{tabular}} \end{table} \begin{table}[t] \centering \setlength\tabcolsep{5pt} \resizebox{0.8\columnwidth}{!}{% \begin{tabular}{ccccccccccc} & \multicolumn{5}{c} {CAF} & \multicolumn{5}{c} {STR} \\ \cmidrule(l){2-6} \cmidrule(l){7-11} \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & % UP. & \begin{tabular}[c]{@{}c@{}}S2 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S7 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} & % UP. & \begin{tabular}[c]{@{}c@{}}S3 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S8 \\ {\scriptsize (EMSE)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S4 \\ {\scriptsize (ELC)}\end{tabular} & \begin{tabular}[c]{@{}c@{}}S9 \\ {\scriptsize (EMSE)}\end{tabular} \\ \midrule \input{figures/resF/dnn1000_dnn1004_dnn1010_dnn1014_combined_stoi_2.txt} \midrule \midrule \end{tabular}} \end{table} \begin{table}[t] \caption{ELC and STOI for S4 and S9 tested with BUS and PED.} \label{tab:lincorr_stoi_bus_ped} \centering \resizebox{0.8\columnwidth}{!}{% \begin{tabular}{ccccccccccccc} \midrule \midrule & \multicolumn{6}{c} {ELC} & \multicolumn{6}{c} {STOI} \\ \cmidrule(l){2-7} \cmidrule(l){8-13} & \multicolumn{3}{c} {BUS} & \multicolumn{3}{c} {PED} & \multicolumn{3}{c} {BUS} & \multicolumn{3}{c} {PED} \\ \cmidrule(l){2-4} \cmidrule(l){5-7} \cmidrule(l){8-10} \cmidrule(l){11-13} SNR & UP. & S4 & S9 & UP. & S4 & S9 & UP. & S4 & S9 & UP. & S4 & S9 \\ \midrule \input{figures/resF/dnn_dnn1004_dnn_dnn1014_bus_ped_lincorr_stoi.txt} \midrule \midrule \end{tabular}} \end{table} \subsection{Matched and Unmatched Noise Type Experiments}\label{sec:noiseRees} In \Cref{tab:lincorr_combined} we compare the ELC scores for the noise type specific systems trained using the ELC (S0--S4), and EMSE (S5--S8) cost functions, and tested in matched noise-type conditions (SSN, BBL, CAF, and STR) at an input SNR of -5, 0, and 5 dB. Results covering the SNR range from -10 to 20 dB can be found in \cite{kolbaek_supplemental_nodate}. All models achieve large improvements in ELC with an average improvement of approximately 0.15-0.20, for all SNRs and noise types, compared to the ELC score of the noisy, unprocessed signals (denoted UP. in \Cref{tab:lincorr_combined,tab:stoi_combined,tab:lincorr_stoi_bus_ped}). We also see that, as expected, models trained with the ELC cost function (S0--S4) in general achieve similar or slightly higher ELC scores compared to the models trained with EMSE (S5--S8). In \Cref{tab:stoi_combined} we report the STOI scores for the systems in \Cref{tab:lincorr_combined} tested in identical conditions. We see moderate to large improvements in STOI in all conditions with an average improvement from 0.07--0.13. We also observe that the systems trained with the EMSE cost function achieve similar improvement in STOI as the systems trained with the ELC cost function. In \Cref{tab:lincorr_stoi_bus_ped}, the ELC and STOI scores for the noise type general systems (S4 and S9) tested with the unmatched BUS and PED noise types are summarized. We see average improvement in the order of 0.1--0.18 in terms of ELC score and 0.05 -- 0.09 in terms of STOI. We also see the performance gap between the S4 system (trained with ELC cost function) is small compared to the S9 system (trained with EMSE cost function) and that noise specific systems perform slightly better than the noise general one. The results in \Cref{tab:lincorr_combined,tab:stoi_combined,tab:lincorr_stoi_bus_ped} are interesting since they show roughly identical global behavior as measured by ELC and STOI for systems trained with the ELC and EMSE cost functions. \subsection{Gain Similarities Between ELC and EMSE Based Systems} We now study to which extent ELC and EMSE based systems behave similarly on a more detailed level. Specifically, we compute correlation coefficients between the gain vectors produced by each of the two types of systems, for SSN, BBL, and STR noise types, and summarize them in \Cref{tab:lincorr}. In \Cref{tab:lincorr} we observe that high sample correlations ($>0.90$) are achieved for all noise types and both SNRs, which indicates that the gains produced by a system trained with the ELC cost function are quite similar to the gains produced by a system trained with the EMSE cost function, which supports the findings in Sec.\;\ref{sec:noiseRees}. Similar conclusions can be drawn for the remaining noise types (results omitted due to space limitations, see \cite{kolbaek_supplemental_nodate}). \subsection{Approximate-STOI Optimal DNN vs. Classical SE DNN} As a final study we compare the performance of an approximate-STOI optimal DNN based SE system with classical Short-Time Spectral Amplitude (STSA) DNN based enhancement systems that estimate $\hat{g}(k,m)$ directly for each STFT frame (see e.g. \cite{weninger_discriminatively_2014,kolbaek_speech_2016}). Similarly to S0--S9 these systems are three-layered feed-forward DNNs and use 30 STFT frames as input, but differently from S0--S9, they minimize the MSE between STFT magnitude spectra, i.e. across frequency. The DNNs estimate five STFT frames per time-step and overlapping frames are averaged to construct the final gain. We have trained two of these classical systems, with 512 units and 4096 units, respectively, in each hidden layer, using the BBL noise corrupted training set. The results are presented in \Cref{tab:stddnn}. From \Cref{tab:stddnn} we see, for example, that such classical STSA-DNN based SE systems trained and tested with BBL noise achieve a maximum STOI score of 0.66 at an input SNR of -5 dB, which is equivalent to the STOI score of 0.66 achieved by S1 in \Cref{tab:stoi_combined}. We also see that the classical system performs on par with S1 at an input SNR of 5 dB SNR with a STOI score of 0.92 compared to 0.90 achieved by S1. Although surprising, this is an interesting result since it indicates that no improvement in STOI can be gained by a DNN based SE system that is designed to maximize an approximate-STOI measure using short-time temporal one-third octave band envelope vectors. The important implication of this is that traditional STSA-DNN based SE systems may be close to optimal from an estimated speech intelligibility perspective. \begin{table} \centering \parbox[t]{.45\linewidth}{ \centering \setlength\tabcolsep{5pt} \caption{Sample linear correlation between gain vectors.} \label{tab:lincorr} \resizebox{0.25\columnwidth}{!}{% \begin{tabular}{cccc} \midrule \midrule \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}SSN \\ \end{tabular} & \begin{tabular}[c]{@{}c@{}}BBL \\ \end{tabular} & \begin{tabular}[c]{@{}c@{}}STR \\ \end{tabular} \\ \midrule -5 & 0.93 & 0.91 & 0.92 \\ 5 & 0.94 & 0.96 & 0.92 \\ \midrule \midrule \end{tabular}} } % \hspace{5mm} % \parbox[t]{.45\linewidth}{ \centering \setlength\tabcolsep{5pt} \caption{STOI score for classical DNN, tested with BBL.} \label{tab:stddnn} \resizebox{0.25\columnwidth}{!}{% \begin{tabular}{cccc} \midrule \midrule \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}UP. \\ \end{tabular} & \multicolumn{2}{c} {\begin{tabular}[c]{@{}c@{}}\# units \\ \midrule 512 \hspace{2.0mm} 4096 \hspace{-1.5mm} \end{tabular} } \\ \midrule -5 & 0.59 & 0.64 & 0.66 \\ 5 & 0.83 & 0.91 & 0.92 \\ \midrule \midrule \end{tabular}}} \end{table} \section{Conclusion} \label{sec:con2} In this paper we proposed a Speech Enhancement\,(SE) system based on Deep Neural Networks\,(DNNs) that optimizes an approximation of the Short-Time Objective Intelligibility\,(STOI) estimator. We proposed an approximate-STOI cost function and derived closed-form expressions for the required gradients. We showed that DNNs designed to maximize approximate-STOI, achieve large improvement in STOI when tested in matched and unmatched noise types at various SNRs. We also showed that approximate-STOI optimal systems do not outperform systems that minimize a mean squared error cost. Finally, we showed that approximate-STOI DNN based SE systems perform on par with classical DNN based SE systems. Our findings suggest that a potential speech intelligibility gain of approximate-STOI optimal systems over MSE based systems is modest at best. \section{Introduction} \label{sec:introG} Despite the recent success of \acf{DNN} based speech enhancement algorithms \cite{erdogan_deep_2017,wang_deep_2017,wang_supervised_2017,kim_bitwise_2017,fakoor_reinforcement_2017}, it is yet unknown if these algorithms are optimal in terms of aspects related to human auditory perception, e.g. speech intelligibility, since existing algorithms do not directly optimize criteria designed with human auditory perception in mind. Many current state-of-the-art DNN based speech enhancement algorithms use a \acf{MSE} training criterion \cite{chen_large-scale_2016,healy_algorithm_2017,kolbaek_speech_2017} on Short-Time Spectral Amplitudes\,(STSA). This, however, might not be the optimal training criterion if the target is the human auditory system, and improvement in speech intelligibility or speech quality is the desired objective. It is well known that the frequency sensitivity of the human auditory system is non-linear ( e.g. \cite{schnupp_auditory_2011,moore_introduction_2013}) and, as a consequence, is often approximated in digital signal processing algorithms using e.g. a Gammatone filter bank \cite{patterson_complex_1992} or a one-third octave band filter bank \cite{taal_algorithm_2011}. It is also well known that preservation of modulation frequencies in the range 4-20 Hz are critical for speech intelligibility \cite{elliott_modulation_2009,schnupp_auditory_2011,drullman_effect_1994}. Therefore, it is natural to believe that, if prior knowledge about the human auditory system is incorporated into a speech enhancement algorithm, improvements in speech intelligibility or speech quality can be achieved \cite{lim_enhancement_1979} Indeed, numerous works exist that attempt to incorporate such knowledge (e.g. \cite{healy_algorithm_2015,loizou_speech_2005,hendriks_dft-domain_2013,lightburn_sobm_2015,han_perceptual_2016,shivakumar_perception_2016,koizumi_dnn-based_2017,kolbaek_monaural_2018-1,zhao_perceptually_2018,zhang_training_2018,fu_end--end_2018} and references therein). In \cite{healy_algorithm_2015} a transform-domain method based on a Gammatone filter bank was used, which incorporates a non-linear frequency resolution mimicking that of the human auditory system. In \cite{loizou_speech_2005} different perceptually motivated cost functions were used to derive STSA clean speech spectrum estimators in order to emphasize spectral peak information, account for auditory masking or penalize spectral over-attenuation. In \cite{han_perceptual_2016,shivakumar_perception_2016} similar goals were pursued, but instead of using classical statistically-based models, DNNs were used. Finally, in \cite{koizumi_dnn-based_2017} a deep reinforcement learning technique was used to reward solutions that achieved a large score in terms of \ac{PESQ} \cite{rix_perceptual_2001}, a commonly used speech quality estimator. Although the works in e.g. \cite{loizou_speech_2005,healy_algorithm_2015,shivakumar_perception_2016,koizumi_dnn-based_2017} include knowledge about the human auditory system the techniques are not designed specifically to maximize speech intelligibility. While speech processing methods that improve speech intelligibility would be of vital importance for applications such as mobile communications, or hearing assistive devices, only very little research has been performed to understand if DNN-based speech enhancement systems can help improve speech intelligibility. Very recent work \cite{kolbaek_monaural_2018-1,zhao_perceptually_2018,zhang_training_2018,fu_end--end_2018} has investigated if DNNs trained to maximize a state-of-the-art speech intelligibility estimator are capable of improving speech intelligibility as measured by the estimator \cite{kolbaek_monaural_2018-1,zhao_perceptually_2018,zhang_training_2018} or human listeners \cite{fu_end--end_2018}. Specifically, DNNs were trained to maximize the \acf{STOI} \cite{taal_algorithm_2011} estimator and were then compared, in terms of STOI, with DNNs trained to minimize the classical STSA-MSE criterion. Surprisingly, although all DNNs improved STOI, the DNNs trained to maximize STOI showed none or only very modest improvements in STOI compared to the DNNs trained with the classical STSA-MSE criterion \cite{kolbaek_monaural_2018-1,zhao_perceptually_2018,zhang_training_2018,fu_end--end_2018}. The STOI speech intelligibility estimator has proven to be able to quite accurately predict the intelligibility of noisy/processed speech in a large range of acoustic scenarios, including speech processed by mobile communication devices \cite{jorgensen_speech_2015}, ideal time-frequency weighted noisy speech \cite{taal_algorithm_2011}, noisy speech enhanced by single-microphone time-frequency weighting-based speech enhancement systems \cite{jensen_algorithm_2016,taal_algorithm_2011,jensen_speech_2014}, and speech processed by hearing assistive devices such as cochlear implants \cite{falk_objective_2015}. STOI has also been shown to be robust to variations in language types, including Danish \cite{taal_algorithm_2011}, Dutch \cite{jensen_speech_2014}, and Mandarin \cite{xia_evaluation_2012}. Finally, recent studies e.g. \cite{healy_algorithm_2017,chen_large-scale_2016} also show a good correspondence between STOI predictions of noisy speech enhanced by DNN-based speech enhancement systems, and speech intelligibility. As a consequence, STOI is currently the, perhaps, most commonly used speech intelligibility estimator for objectively evaluating the performance of speech enhancement systems \cite{healy_algorithm_2015,chen_large-scale_2016,healy_algorithm_2017,kolbaek_speech_2017}. Therefore, it is natural to believe that gains in speech intelligibility, as estimated by STOI, can be achieved by utilizing an optimality criterion based on STOI as opposed to the classical criterion based on STSA-MSE. In this paper we study the potential gain in speech intelligibility that can be achieved, if a DNN is designed to perform optimally with respect to the STOI speech intelligibility estimator. We derive that, under certain general conditions, maximizing an approximate-STOI criterion is equivalent to minimizing a STSA-MSE criterion. Furthermore, we present empirical data using simulation studies with DNNs applied to noisy speech signals, that support our theoretical results. Finally, we show theoretically under which conditions the equality between the approximate-STOI criterion and the STSA-MSE criterion holds for practical systems. Our results are in line with recent empirical work and might explain the somewhat surprising result in \cite{kolbaek_monaural_2018-1,zhao_perceptually_2018,zhang_training_2018,fu_end--end_2018}, where none or only very modest improvements in STOI were achieved with STOI optimal DNNs compared to MSE optimal DNNs. \section{STFT-domain based Speech Enhancement}\label{sec:secse} Fig.\;\ref{fig:sefig} shows a block-diagram of a classical gain-based speech enhancement system \cite{hendriks_dft-domain_2013,loizou_speech_2013}. \begin{figure} \centering \vspace{2mm} \begin{tikzpicture}[baseline=(current bounding box.north)] \def0.2{0.2} \draw [thick, ->] (0,2) -- (0.6,2); \node[above] at (0.25,2) {\footnotesize $y[n]$}; \draw [thick, ->] (1.8,2) -- (2.3,2); \node[above] at (3.45,3.2) {\footnotesize $r(k,m)$}; \draw [thick, ->] (2.05,2) -- (2.05,3.2) -- (4.85,3.2) -- (4.85,2.16) ; \draw [thick, ->] (1.2,1.5) -- (1.2,0.6) -- (6.8,0.6) -- (6.8,1.5) ; \node[below] at (4,0.6) {\footnotesize $\phi_y(k,m)$}; \draw [thick, ->] (3.5,2) -- (4.69,2); \node[above] at (4.15,2.00) {\footnotesize $\hat{g}(k,m)$}; \node [draw,circle,cross,minimum width=0.2 ] at (4.85,2){}; \draw [thick, ->] (5.01,2) -- (6.2,2); \node[above] at (5.61,2.00) {\footnotesize $\hat{a}(k,m)$}; \draw [thick, ->] (7.2,2) -- (8,2); \node[above] at (7.75,2) {\footnotesize $\hat{x}[n]$}; \filldraw[fill=gray!20!white, draw=black] (0.6 , 1.5) rectangle (1.8 , 2.5) ; \node at (1.2,2) {\scriptsize {\begin{tabular}{c} T-F \\ Analysis \end{tabular}}}; \filldraw[fill=gray!20!white, draw=black] (2.3 , 1.5) rectangle (3.5 , 2.5) ; \node at (2.9,2) {\scriptsize {\begin{tabular}{c} Gain \\ Estimator \end{tabular}}}; \filldraw[fill=gray!20!white, draw=black] (6.2 , 1.5) rectangle (7.4 , 2.5) ; \node at (6.8,2) {\scriptsize {\begin{tabular}{c} T-F \\ Synthesis \end{tabular}}}; \end{tikzpicture} \caption{Classical gain-based speech enhancement system. The noisy time-domain signal $y[n] = x[n] + v[n]$ is first decomposed into a \acf{T-F} representation $r(k,m)$ for time-frame $m$ and frequency index $k$. An estimator, e.g. a DNN, estimates a gain $\hat{g}(k,m)$ that is applied to the noisy short-term magnitude spectrum $r(k,m)$ to arrive at an enhanced signal magnitude $\hat{a}(k,m) = \hat{g}(k,m)r(k,m)$. Finally, the enhanced time-domain signal $\hat{x}[n]$ is obtained from a T-F synthesis stage using the phase of the noisy signal $\phi_y(k,m)$.} \label{fig:sefig} \end{figure} Let $x[n]$ be the $n$th sample of the clean time-domain speech signal and let a noisy observation $y[n]$ be given by \begin{equation} y[n] = x[n] + v[n], \label{eq111} \end{equation} where $v[n]$ is a sample of additive noise. Furthermore, let $a(k,m)$ and $r(k,m)$, $k = 1,\dots, \frac{K}{2}+1$, $m=1,\dots M, $ denote the single-sided magnitude spectra of the $K$-point short-time discrete Fourier transform (STFT) of $x[n]$ and $y[n]$, respectively, where $M$ is the number of STFT frames. Also, let $\hat{a}(k,m)$ denote an estimate of $a(k,m)$ obtained as $\hat{a}(k,m) = \hat{g}(k,m)r(k,m)$. Here, $\hat{g}(k,m)$ is a scalar gain factor applied to the magnitude spectrum of the noisy speech $r(k,m)$ to arrive at an estimate $\hat{a}(k,m)$ of the clean speech magnitude spectrum $a(k,m)$. It is the goal of many STFT-based speech enhancement systems to find appropriate values for $\hat{g}(k,m)$ based on the available noisy signal $y[n]$. The gain factor $\hat{g}(k,m)$ is typically estimated using either statistical model-based methods such as classical STSA \acf{MMSE} estimators \cite{ephraim_speech_1984}, \cite{hendriks_dft-domain_2013,loizou_speech_2013}, or machine learning based techniques such as Gaussian mixture models \cite{kim_algorithm_2009}, support vector machines \cite{han_classification_2012}, or, more recently, DNNs \cite{healy_algorithm_2015,chen_large-scale_2016,healy_algorithm_2017,kolbaek_speech_2017}. For reconstructing the enhanced speech signal in the time domain, it is common practice to append the short-time phase spectrum of the noisy signal to the estimated short-time magnitude spectrum and then use the overlap-and-add technique \cite{allen_short_1977}, \cite{loizou_speech_2013}. \section{Short-Time Objective Intelligibility (STOI)}\label{sec:secstoi} In the following, we shortly review the STOI intelligibility estimator \cite{taal_algorithm_2011}. For further details we refer to \cite{taal_algorithm_2011}. Let the $j$th one-third octave band clean-speech amplitude, for time-frame $m$, be defined as \begin{equation} a_j( m ) = \sqrt{\sum_{k=k_1(j)}^{k_2(j)} a(k,m)^2}, \label{eq22} \end{equation} where $k_1(j)$ and $k_2(j)$ denote the first and last STFT bin index, respectively, of the $j$th one-third octave band. Furthermore, let a short-time temporal envelope vector that spans time-frames $m-N+1, \dots, m$, for the clean speech signal be defined as \begin{equation} \barbelow{{a}}_{j,m} = [ a_j( m-N+1 ), \; a_j( m-N+2 ), \dots , a_j( m ) ]^T \label{eq222} \end{equation} In a similar manner we define $\barbelow{{\hat{a}}}_{j,m}$ and $\barbelow{{r}}_{j,m}$ for the enhanced speech signal and the noisy observation, respectively. The parameter $N$ defines the length of the temporal envelope and for STOI $N=30$% \footnote{With $N=30$, STOI is sensitive to temporal modulations of $2.6$ Hz and higher, which are frequencies important for speech intelligibility \cite{taal_algorithm_2011}.}, which for the STFT settings used in this study, as well as in \cite{taal_algorithm_2011}, corresponds to approximately $384$ ms. Finally, the STOI speech intelligibility estimator for a pair of short-time temporal envelope vectors can then be approximated by the sample \acf{ELC} between the clean and enhanced envelope vectors $\barbelow{{a}}_{j,m}$ and $\barbelow{{\hat{a}}}_{j,m}$ given as \begin{equation} \mathcal{L} ( \barbelow{{a}}_{j,m},\barbelow{{\hat{a}}}_{j,m}) = \frac{\left(\barbelow{{a}}_{j,m} - \mu_{\barbelow{{a}}_{j,m}}\right)^T \left(\barbelow{{\hat{a}}}_{j,m} - \mu_{\barbelow{{\hat{a}}}_{j,m}}\right)}{ \left\lVert \barbelow{{a}}_{j,m} - \mu_{\barbelow{{a}}_{j,m}} \right\rVert \; \left\lVert\barbelow{{\hat{a}}}_{j,m} - \mu_{\barbelow{{\hat{a}}}_{j,m}} \right\rVert }, \label{eq:stoicost} \end{equation} where $\left\lVert \cdot \right\rVert$ denotes the Euclidean $\ell^2$-norm and $\mu_{\barbelow{{a}}_{j,m}}$ and $\mu_{\barbelow{{\hat{a}}}_{j,m}}$ denote the sample means of $\barbelow{{a}}_{j,m}$ and $\barbelow{{\hat{a}}}_{j,m}$, respectively. Note that Eq.\;\eqref{eq:stoicost} is an approximation, since the clipping and normalization steps otherwise used in STOI, have been omitted. This has empirically been found not to have any significant effect on intelligibility prediction performance in most cases \cite{taal_matching_2012,lightburn_sobm_2015,jensen_algorithm_2016,andersen_predicting_2016}. Furthermore, since the normalization step is applied for the entire vector $\barbelow{{\hat{a}}}_{j,m}$, the normalization procedure itself does not influence the final STOI score. Also, as clipping only occurs for time-frequency units for which the signal-to-distortion ratio (see Eq. (4) in \cite{taal_algorithm_2011}) is below $-15$ dB, clipping only occurs for a minority of the envelope vectors and approximating STOI with ELC is well valid, or even exact, in most cases, when evaluating speech signals at practical SNRs. From $\mathcal{L} ( \barbelow{{a}}_{j,m},\barbelow{{\hat{a}}}_{j,m})$, the final STOI score for an entire speech signal is then defined as \cite{taal_algorithm_2011} the scalar, $-1 \leq d \leq 1$, \begin{equation} d = \frac{1}{J(M-N+1)} \sum_{j=1}^{J} \sum_{m=N}^{M} \mathcal{L} ( \barbelow{{a}}_{j,m},\barbelow{{\hat{a}}}_{j,m}), \label{eq:stoisum} \end{equation} where $J$ is the number of one-third octave bands and $M-N+1$ is the total number of short-time temporal envelope vectors. Similarly to \cite{taal_algorithm_2011}, we use $J=15$ with a center frequency of the first one-third octave band at 150 Hz and the last at approximately 3.8 kHz to ensure a frequency range that covers the majority of the spectral information of human speech. The STOI score in general has been shown to often have high correlation with listening tests involving human test subjects, i.e. the higher numerical value of Eq.\;\eqref{eq:stoisum}, the more intelligible is the speech signal. Since STOI, as approximated by Eq.\;\eqref{eq:stoisum}, is a sum of ELC values as given by Eq.\;\eqref{eq:stoicost}, maximizing Eq.\;\eqref{eq:stoicost} will also maximize the overall STOI score in Eq.\;\eqref{eq:stoisum}. As a consequence, in order to find an estimate $\hat{x}[n]$ of $x[n]$ so that STOI is maximized, one can focus on finding optimal estimates of the individual short-time temporal envelope vectors $\barbelow{{a}}_{j,m}$. Therefore, we define $\barbelow{{\hat{a}}}_{j,m} = \text{diag}(\barbelow{{\hat{g}}}_{j,m})\barbelow{{r}}_{j,m}$ as the short-time temporal one-third octave band envelope vector of the enhanced speech signal, where $\barbelow{{\hat{g}}}_{j,m}$ is an estimated gain vector and $\text{diag}(\barbelow{{\hat{g}}}_{j,m})$ is a diagonal matrix with the elements of $\barbelow{{\hat{g}}}_{j,m}$ on the main diagonal. \section{Envelope Linear Correlation Estimator}\label{sec:melcest} We now introduce the approximate-STOI criterion in a stochastic context and derive the speech envelope estimator that maximizes it. We denote this estimator as the \ac{MMELC} estimator. Let $A_j(m)$ and $R_j(m)$ denote random variables representing a clean and a noisy, respectively, one-third octave band magnitude, for band $j$ and time frame $m$. Furthermore, let \begin{equation} \barbelow{{A}}_j(m) = \left[ A_j(m-N+1), \, \dots \, A_j(m) \right] \label{eq1} \end{equation} and \begin{equation} \barbelow{{R}}_j(m) = \left[ R_j(m-N+1), \, \dots \, R_j(m) \right] \label{eq2} \end{equation} be the stack of these random variables in random envelope vectors. Finally, in a similar manner, let \begin{equation} \barbelow{{\hat{A}}}_j(m) = \left[ \hat{A}_j(m-N+1), \, \dots \, \hat{A}_j(m) \right], \label{eq3} \end{equation} be a random envelope vector representing an estimate of $\barbelow{{A}}_j(m)$. Now, the contribution of $\barbelow{{\hat{A}}}_j(m)$ to speech intelligibility may be approximated as the ELC between the envelope vectors $\barbelow{{A}}_j(m)$ and $\barbelow{{\hat{A}}}_j(m)$. In the following, the indices $j$ and $m$ are omitted for convenience. Let $\barbelow{{1}}$ denote a vector of ones, and let $\barbelow{\mu}_{\barbelow{{A}}} = \frac{1}{N} \barbelow{{1}}^T \barbelow{{A}} \barbelow{{1}}$ be a vector, whose entries equal the sample mean of the entries in $\barbelow{{A}}$. Let $\barbelow{\mu}_{\barbelow{{\hat{A}}}}$ be defined in a similar manner. Finally, let the ELC between $\barbelow{{A}}$ and $\barbelow{{\hat{A}}}$, which is a random variable, be defined as \begin{equation} \rho \left(\A , \Ah \right) \triangleq \frac{ \Big( \barbelow{{A}} - \barbelow{\mu}_{\barbelow{{A}}} \Big)^T \Big( \barbelow{{\hat{A}}} - \barbelow{\mu}_{\barbelow{{\hat{A}}}} \Big) }{ \Big\lVert \barbelow{{A}} - \barbelow{\mu}_{\barbelow{{A}}} \Big\rVert \Big\lVert \barbelow{{\hat{A}}} - \barbelow{\mu}_{\barbelow{{\hat{A}}}} \Big\rVert }, \label{eq4} \end{equation} and the expected ELC as \begin{equation} \begin{split} \Omega_{ELC} & = \mathbb{E}_{\barbelow{{A}},\barbelow{{R}}} \left[ \rho \left(\A , \Ah \right) \right] \\ & = \int \int \rho \left(\sa , \ah \right) f_{\A , \R} \left( \sa , \sr \right) d \barbelow{{a}} \, d \barbelow{{r}} \\ & = \int \underbrace{ \int \rho \left(\sa , \ah \right) f_{\A \lvert \R} \left( \sa \lvert \sr \right) \, d \barbelow{{a}} \; }_{ \Gamma \left( \sr \right) } f_{\R} \left( \sr \right) \, d \barbelow{{r}} . \end{split} \label{eq5} \end{equation} Here, $\barbelow{{\hat{a}}}$ is related to $\barbelow{{r}}$ via a deterministic map, e.g. a DNN, and $ f_{\A , \R} \left( \sa , \sr \right)$ denotes the joint \acf{PDF} of clean and noisy/processed one-third octave band envelope vectors. Furthermore, $ f_{\A \lvert \R} \left( \sa \lvert \sr \right)$ and $ f_{\R} \left( \sr \right)$ denote a conditional and marginal PDF, respectively. An optimal estimator can be found by minimizing the Bayes risk \cite{kay_fundamentals_2010,loizou_speech_2013}, which is equivalent to maximizing Eq.\;\eqref{eq5}, hence arriving at the MMELC estimator, which we denote as $\barbelow{{\hat{a}}}_{MMELC}$. To do so, observe that for a particular noisy observation $\barbelow{{r}}$ maximizing $ \Gamma \left( \sr \right) $ maximizes Eq.\;\eqref{eq5}, since $ f_{\R} \left( \sr \right) \geq 0 \; \forall \; \barbelow{{r}}$. In other words, our goal is to maximize $ \Gamma \left( \sr \right) $ for each and every $\barbelow{{r}}$. Hence, for a particular observation, $\barbelow{{r}}$, the MMELC estimate is given by \begin{equation} \begin{split} \barbelow{{\hat{a}}}_{MMELC} & = \arg\max_{\barbelow{{\hat{a}}}} \int \rho \left(\sa , \ah \right) f_{\A \lvert \R} \left( \sa \lvert \sr \right) \, d \barbelow{{a}} \\ & = \arg\max_{\barbelow{{\hat{a}}}} \int \frac{ \big( \barbelow{{a}} - \barbelow{\mu}_{\barbelow{{a}}} \big)^T \big( \barbelow{{\hat{a}}} - \barbelow{\mu}_{\barbelow{{\hat{a}}}} \big) }{ \big\lVert \barbelow{{a}} - \barbelow{\mu}_{\barbelow{{a}}} \big\rVert \big\lVert \barbelow{{\hat{a}}} - \barbelow{\mu}_{\barbelow{{\hat{a}}}} \big\rVert } f_{\A \lvert \R} \left( \sa \lvert \sr \right) \, d \barbelow{{a}} \\ & = \arg\max_{\barbelow{{\hat{a}}}} \underbrace{ \int \frac{ \big( \barbelow{{a}} - \barbelow{\mu}_{\barbelow{{a}}} \big)^T }{ \big\lVert \barbelow{{a}} - \barbelow{\mu}_{\barbelow{{a}}} \big\rVert } f_{\A \lvert \R} \left( \sa \lvert \sr \right) \, d \barbelow{{a}} }_{\mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{e}}(\barbelow{{A}})^T \right] } \underbrace{ \frac{\big( \barbelow{{\hat{a}}} - \barbelow{\mu}_{\barbelow{{\hat{a}}}} \big)}{\big\lVert \barbelow{{\hat{a}}} - \barbelow{\mu}_{\barbelow{{\hat{a}}}} \big\rVert} }_{\barbelow{{e}}(\barbelow{{\hat{a}}})} \\ & = \arg\max_{\barbelow{{\hat{a}}}} \; \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{e}}(\barbelow{{A}})^T \right] \barbelow{{e}}(\barbelow{{\hat{a}}}), \\ \end{split} \label{eq6} \end{equation} where $\barbelow{{e}}(\cdot)$ is a function that normalizes its vector argument to zero sample mean and unit norm and where we used that for a given noisy observation $\barbelow{{r}}$, $\barbelow{{\hat{a}}}$ is deterministic. Note that the solution to Eq.\;\eqref{eq6} is non-unique. For one given solution, say $\barbelow{{\hat{a}}}^\ast$, any affine transformation, $\delta \barbelow{{\hat{a}}}^\ast + \gamma \barbelow{{1}} \; \forall \; \delta,\gamma \, \in \mathcal{R} $, is also a solution, because any such transformation is undone by $\barbelow{{e}}(\cdot)$. Hence, in the following we focus on finding one such particular solution, namely the zero sample mean, unit norm solution, i.e. the vector $\barbelow{{e}}(\barbelow{{\hat{a}}})$ that maximizes the inner product with the vector $\mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{e}}(\barbelow{{A}}| \barbelow{{r}}) \right]$. To do so, let $\barbelow{{\alpha}} = \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{e}}(\barbelow{{A}}| \barbelow{{r}}) \right]$, and let $\barbelow{{e}}(\barbelow{{\hat{a}}}^\ast)$ denote the zero sample mean, unit norm vector that maximizes Eq.\;\eqref{eq6}. Then, using the method of Lagrange multipliers, it can be shown (see Appendix\;\ref{sec:lagran}) that the MMELC estimator is given by \begin{equation} \begin{split} \barbelow{{\hat{a}}}_{MMELC} &= \barbelow{{e}}(\barbelow{{\hat{a}}}^\ast) \\ & = \frac{\big( \barbelow{{\alpha}} - \barbelow{\mu}_{\barbelow{{\alpha}}} \big)}{\big\lVert \barbelow{{\alpha}} - \barbelow{\mu}_{\barbelow{{\alpha}}} \big\rVert} \\ & = \frac{\barbelow{{\alpha}}}{\Vert \barbelow{{\alpha}} \Vert}, \end{split} \label{eq7} \end{equation} which is nothing more than the vector $\barbelow{{\alpha}}$, normalized to unit norm. The fact that $\barbelow{\mu}_{\barbelow{{\alpha}}} = \frac{1}{N} \barbelow{{1}}^T \alpha \barbelow{{1}} = \barbelow{{0}}$ follows from Eq.\;\eqref{eq6}, where it is seen that $\barbelow{{\alpha}} = \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{e}}(\barbelow{{A}}| \barbelow{{r}}) \right]$ is an expectation over vectors $ (\barbelow{{a}} - \barbelow{\mu}_{\barbelow{{a}}}) \big\lVert \barbelow{{a}} - \barbelow{\mu}_{\barbelow{{a}}} \big\rVert^{-1} $ whose sample mean is zero. By interpreting the expectation as an infinite linear combination of such vectors, it follows that $\barbelow{\mu}_{\barbelow{{\alpha}}} = \barbelow{{0}}$. \section{Relation to STSA-MMSE Estimators}\label{secrelation} We now show that the MMELC estimator, Eq.\;\eqref{eq7}, is asymptotically equivalent to the one-third octave band STSA-MMSE estimator for large envelope lengths, i.e. as $N \to \infty$. The STSA-MSE (e.g. \cite{ephraim_speech_1984}) is defined as \begin{equation} \begin{split} \Omega_{MSE} & = \mathbb{E}_{\barbelow{{A}},\barbelow{{R}}} \left[ \left(\barbelow{{A}}-\barbelow{{\hat{A}}} \right)^2 \right]. \\ \end{split} \label{eq8} \end{equation} It can be shown (e.g. \cite{ephraim_speech_1984,hendriks_dft-domain_2013,loizou_speech_2013}) that the optimal Bayesian estimator with respect to Eq.\;\eqref{eq8}, is the STSA-MMSE estimator given by the conditional mean defined as \begin{equation} \begin{split} \barbelow{{\hat{a}}}_{MMSE} & = \int \barbelow{{a}} \; f_{\A \lvert \R} \left( \sa \lvert \sr \right) \, d \barbelow{{a}} \\ & = \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{A}} | \barbelow{{r}} \right]. \\ \end{split} \label{eq9} \end{equation} To show that $\barbelow{{\hat{a}}}_{MMELC}$ is asymptotically equivalent to $\barbelow{{\hat{a}}}_{MMSE}$, let us introduce the idempotent, symmetric matrix \begin{equation} \barbelow{\barbelow{{H}}} = \barbelow{\barbelow{I}}_N - \frac{1}{N} \barbelow{{1}}\One^T, \label{eq10} \end{equation} where $\barbelow{\barbelow{I}}_N$ denotes the $N$-dimensional identity matrix. We can then rewrite the vector $\barbelow{{\alpha}}$ as \begin{equation} \begin{split} \barbelow{{\alpha}} & = \int \frac{ \big( \barbelow{{a}} - \barbelow{\mu}_{\barbelow{{a}}} \big) }{ \big\lVert \barbelow{{\hat{a}}} - \barbelow{\mu}_{\barbelow{{\hat{a}}}} \big\rVert } f_{\A \lvert \R} \left( \sa \lvert \sr \right) \, d \barbelow{{a}} \\ & = \int \frac{ \barbelow{\barbelow{{H}}} \barbelow{{a}} }{ \big\lVert \barbelow{\barbelow{{H}}} \barbelow{{a}} \big\rVert } f_{\A \lvert \R} \left( \sa \lvert \sr \right) \, d \barbelow{{a}} \\ & = \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \frac{ \barbelow{\barbelow{{H}}} \barbelow{{A}} | \barbelow{{r}} }{ \big\lVert \barbelow{\barbelow{{H}}} \barbelow{{A}} | \barbelow{{r}} \big\rVert } \right] \\ & = \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \frac{ \barbelow{{Z}} }{ \big\lVert \barbelow{{Z}} \big\rVert } \right], \\ \end{split} \label{eq11} \end{equation} where $\barbelow{{A}} | \barbelow{{r}} $ is a random vector, and we introduced the notation $\barbelow{{Z}} \triangleq \barbelow{\barbelow{{H}}} \barbelow{{A}} | \barbelow{{r}}$. We now employ the following conditional independence assumption \begin{equation} f_{\A \lvert \R} \left( \sa \lvert \sr \right) = \prod_{j=1}^{N} f_{A_j | R_j = r_j} (a_j | r_j). \label{eqz9} \end{equation} This is a standard assumption in the area of speech enhancement, when operating in the STFT domain and has been the underlying assumption of a very large number of speech enhancement methods (see e.g. \cite{ephraim_speech_1984,ephraim_speech_1985,erkelens_minimum_2007,hendriks_dft-domain_2013,loizou_speech_2013} and references therein). The conditional independence assumption is, for example, valid, when speech and noise STFT coefficients may be assumed statistically independent across time and frequency and mutually independent \cite{mcaulay_speech_1980,ephraim_speech_1984,loizou_speech_2013}. Using Kolmogorovs strong law of large numbers \cite[pp. 67-68]{sen_large_1994} and the conditional independence assumption, it can be shown (see Appendix\;\ref{sec:zindepedent}) that asymptotically, as $N \to \infty$, the expectation in Eq.\;\eqref{eq11} factorizes as \begin{equation} \begin{split} \lim_{N\to\infty} \;\; \barbelow{{\alpha}} &= \lim\limits_{N \to \infty} \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \frac{ 1 }{ \big\lVert \barbelow{{Z}} \big\rVert } \right] \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} }\left[ \barbelow{{Z}} \right]. \\ \end{split} \label{eq14} \end{equation} Combining this result with Eq.\;\eqref{eq7} leads to \begin{equation} \begin{split} \lim_{N\to\infty} \barbelow{{\hat{a}}}_{MMELC} &= \lim_{N\to\infty} \frac{ \barbelow{{\alpha}} }{\big\lVert \barbelow{{\alpha}} \big\rVert}\\ &= \lim_{N\to\infty} \frac{ \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \frac{ 1 }{ \lVert \barbelow{{Z}} \rVert } \right] \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] }{ \Big\lVert \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \frac{ 1 }{ \lVert \barbelow{{Z}} \rVert } \right] \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] \Big \rVert }\\ &= \lim_{N\to\infty} \frac{ \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \frac{ 1 }{ \lVert \barbelow{{Z}} \rVert } \right] \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] }{ \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \frac{ 1 }{ \lVert \barbelow{{Z}} \rVert } \right] \Big\lVert \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] \Big \rVert }\\ &= \lim_{N\to\infty} \frac{ \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] }{ \Big\lVert \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] \Big \rVert }.\\ \end{split} \label{eq15} \end{equation} Since Eq.\;\eqref{eq6} is invariant to affine transformations of its input arguments, we can scale $\barbelow{{\hat{a}}}_{MMELC} $ with the scalar quantity $ \lVert \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] \rVert $ in Eq.\;\eqref{eq15} to arrive at \begin{equation} \begin{split} \lim_{N\to\infty} \;\; \barbelow{{\hat{a}}}_{MMELC} &= \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right].\\ \end{split} \label{eq16} \end{equation} Finally, as $N \to \infty $, the MMELC estimator $\barbelow{{\hat{a}}}_{MMELC}$ is given by \begin{equation} \begin{split} \lim_{N\to\infty} \;\; \barbelow{{\hat{a}}}_{MMELC} &= \; \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{Z}} \right] \\ &= \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \big[ \barbelow{\barbelow{{H}}} \barbelow{{A}} | \barbelow{{r}} \big] \\ &=\mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \Bigg[ \left( \barbelow{\barbelow{\mathbf{I}}}_N - \frac{1}{N} \barbelow{{1}}\One^T \right) \barbelow{{A}} | \barbelow{{r}} \Bigg] \\ &=\mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \bigg[ \barbelow{{A}} | \barbelow{{r}} - \frac{1}{N} \barbelow{{1}}\One^T \barbelow{{A}} | \barbelow{{r}} \bigg] \\ &=\mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \big[ \barbelow{{A}} | \barbelow{{r}} \big] - \frac{1}{N} \barbelow{{1}}\One^T \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \big[ \barbelow{{A}} | \barbelow{{r}} \big] \\ &=\barbelow{{\hat{a}}}_{MMSE} - \barbelow{\mu}_{\barbelow{{\hat{a}}}_{MMSE} }.\\ \end{split} \label{eq17} \end{equation} In words, the MMELC estimator, $\barbelow{{\hat{a}}}_{MMELC}$, is (asymptotically in $N$) an affine transformation of the STSA-MMSE estimator $\barbelow{{\hat{a}}}_{MMSE}$. In practice, this means that using the STSA-MMSE estimator leads to the same approximate-STOI criterion value as the estimator, $\barbelow{{\hat{a}}}_{MMELC}$, derived to maximize this criterion. In other words, applying the traditional STSA-MMSE estimator leads to maximum speech intelligibility as reflected by the approximate STOI estimator. \section{Experimental Design}\label{sec:expdes} We now investigate empirically the relationship between the MMELC estimator in Eq.\;\eqref{eq9} and the STSA-MMSE estimator in Eq.\;\eqref{eq6} using an experimental study. As defined in Eq.\;\eqref{eq6}, the MMELC estimator is the vector that maximizes the expectation of the ELC cost function given by Eq.\;\eqref{eq5}. This expectation, Eq.\;\eqref{eq5}, is defined via an integral of $\rho \left(\sa , \ah \right)$ for various realizations of $\barbelow{{a}}$ and $\barbelow{{\hat{a}}}$, and weighted by the joint PDF $ f_{\A , \R} \left( \sa , \sr \right)$. It is however, well known, that the integral may be approximated (arbitrarily well) as a sum of $\rho \left(\sa , \ah \right)$ terms, where realizations of $\barbelow{{a}}$ and $\barbelow{{\hat{a}}}$ are drawn according to $ f_{\A , \R} \left( \sa , \sr \right)$. This is similar to what a DNN approximates during a standard training process, where a gradient based optimization technique is used to minimize the cost on a representative training set \cite{goodfellow_deep_2016}. Therefore, training a DNN, e.g. using stochastic gradient ascent, to maximize Eq.\;\eqref{eq:stoicost} may be seen as an approximation of Eq.\;\eqref{eq6}, where the approximation becomes more accurate with increasing training set size. From the theoretical results presented in Sec.\;\ref{secrelation}, we would therefore expect that, for some sufficiently large $N$, one would obtain equality in an ELC sense, between a DNN trained to maximize an ELC cost function and one that is trained to minimize the classical STSA-MSE cost function. To validate this expectation we follow the techniques formalized in Secs.\;\ref{sec:secse} and \ref{sec:secstoi} and train DNNs to estimate gain vectors, $\barbelow{{\hat{g}}}_{j,m}$, that we apply to noisy one-third octave band magnitude envelope signals $\barbelow{{r}}_{j,m}$, to arrive at enhanced signals $\barbelow{{\hat{a}}}_{j,m}$. In principle, any supervised learning model would be applicable for these experiments but considering the universal function approximation capability of DNNs \cite{hornik_multilayer_1989}, this is our model of choice. We use short-time temporal one-third octave band envelope vectors, as defined in Eq.\;\eqref{eq222}, and train multiple DNNs, one for each of the $J=15$ one-third octave bands, for various $N$, to investigate if for sufficiently large $N$, DNNs trained with a STSA-MSE cost function approach the ELC values of DNNs trained with a cost function based on ELC. We construct two types of enhancement systems, one type is trained using the STSA-MSE cost function, denoted as $\text{ES}_{MSE}$, and one that is trained using the ELC cost function denoted as $\text{ES}_{ELC}$. Each of the systems consists of $J=15$ DNNs, each estimating a gain vector $\barbelow{{\hat{g}}}_{j,m}$ for a particular one-third octave band directly from the STFT magnitudes of the noisy signal $r(k,m)$, with the input context given by $k = 1,\dots, \frac{K}{2}+1$, $m-N+1 \dots, m $. This ensures that all DNNs have access to the same information for a particular value of $N$, as they all receive the same input data. Furthermore, we follow common practice (e.g. \cite{healy_algorithm_2015,healy_algorithm_2017,chen_large-scale_2016,kolbaek_monaural_2018-1}) and average overlapping estimated gain values, within a one-third octave band, during enhancement. We found during a preliminary study that this technique consistently lead to slightly larger STOI scores for both types of systems. To compute the STFT coefficients for all signals we use a 10 kHz sample frequency and a $K=256$ point STFT with a Hann-window size of 256 samples (25.6 ms) and a 128 sample frame shift (12.8 ms). These coefficients are then used to compute one-third octave band envelopes for the clean and noisy signals using Eq.\;\eqref{eq222}. \subsection{Noise-free Speech Mixtures} We have used the Wall Street Journal\,(WSJ0) speech corpus \cite{garofolo_csr-i_1993} as the clean speech data for both the training set, validation set, and test set. Specifically, the noise-free utterances used for training and validation are generated by randomly selecting utterances from 44 male and 47 female speakers from the WSJ0 training set entitled si\_tr\_s. In total 20000 utterances are used for the training set and 2000 are used for the validation set, which adds up to approximately 37 hours of training data and 4 hours of validation data. For the test set, we have used a similar approach and sampled 1000 utterances among 16 speakers (10 males and 6 females) from the WSJ0 validation set si\_dt\_05 and evaluation set si\_et\_05, which is equivalent to approximately 2 hours of data, see \cite{kolbaek_supplemental_nodate-1} for further details. The speakers used in the training and validation sets are different than the speakers used for test, i.e. we test in a speaker independent setting. {\color{black} Finally, since WSJ0 utterances primarily include speech active regions we do not apply a VAD. This is motivated by the fact that noise-only regions are irrelevant for STOI, as these are discarded by an ideal VAD in the STOI front-end \cite{taal_algorithm_2011}.} \subsection{Noise Types}\label{sec:nt} To simulate a wide variety of sound scenes we have used six different noise types in our experiments: two synthetic noise signals and four natural noise signals, which are real-life recordings of naturally occurring sound scenes. For the two synthetic noise signals, we use a stationary \acf{SSN} signal and a highly non-stationary 6-speaker babble\;(BBL) noise. For the naturally occurring noise signals, we use the street\;(STR), cafeteria\;(CAF), bus\;(BUS), and pedestrian\;(PED) noise signals from the CHiME3 dataset \cite{barker_third_2015}. The SSN noise signal is Gaussian white noise, spectrally shaped according to the long-term spectrum of the entire TIMIT speech corpus \cite{garofolo_darpa_1993}. Similarly, the BBL noise signal is constructed by mixing utterances from both genders from TIMIT. To ensure that all noise types are equally represented and with unique realizations in the training, validation and test sets, all six noise signals are split into non-overlapping segments such that 40 min.\;is used for training, 5 min.\;is used for validation and another 5 min. is used for test. \subsection{Noisy Speech Mixtures} To construct the noisy speech signals used for training, we follow Eq.\;\eqref{eq111} and combine a noise-free training utterance $x[n]$ with a randomly selected noise sequence $v[n]$, of equal length, from the training noise signal. We scale the noise signal $v[n]$, to achieve a certain \acf{SNR}, according to the active speech level of $x[n]$ as defined by ITU P.56 \cite{itu_rec._1993}. For the training and validation sets, the SNRs are chosen uniformly from $[-5 , 10 ]$ dB to ensure that the intelligibility of the noisy speech mixtures $y[n]$ ranges from degraded to perfectly intelligible. \subsection{Model Architecture and Training} The two types of enhancement systems, $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$, each consist of 15 feed-forward DNNs. The DNNs in the $\text{ES}_{ELC}$ system are trained with the ELC cost function introduced in Eq.\;\eqref{eq:stoicost} and the DNNs in the $\text{ES}_{MSE}$ system are trained using the well-known STSA-MSE cost function given by \begin{equation} \mathcal{J} ( \barbelow{{a}},\barbelow{{\hat{a}}}) = \frac{1}{N} \left\lVert \barbelow{{a}} - \barbelow{{\hat{a}}} \right\lVert^2, \label{eq:msecost} \end{equation} where the subscripts $j$ and $m$ are omitted for convenience. We train both the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems with 20000 training utterances and 2000 validation utterances and both data sets have been mixed uniformly with the SSN, BBL, CAF, and STR noise signals, which ensures that each noise type have been mixed with $25\%$ of the utterances in the training and validation sets. During test, we evaluate each system with one noise type at a time, i.e. each system is evaluated with 1000 noisy test utterances per noise type, and since BUS and PED are not included in the training and validation sets, these two noise signals serve as unmatched noise types, whereas SSN, BBL, CAF, and STR are matched noise types. This will allow us to study how the ELC optimal DNNs and STSA-MSE optimal DNNs generalize to unmatched noise types. Each feed-forward DNN consists of three hidden layers with 512 units using ReLU activation functions. The $N$-dimensional output layer uses sigmoid functions which ensures that the output gain $\barbelow{{\hat{g}}}_{j,m}$ is confined between zero and one. The DNNs are trained using stochastic gradient de-/ascent with the backpropagation technique and batch normalization \cite{goodfellow_deep_2016}. The DNNs are trained for a maximum of 200 epochs with a minibatch size of 256 randomly selected short-time temporal one-third octave band envelope vectors. Since the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems use different cost functions, they likely have different optimal learning rates. This is easily seen from the gradient norms of the two cost functions. It can be shown (details omitted due to space limitations) that the $\ell^2$-norm of the gradient of the ELC cost function in Eq.\;\eqref{eq:stoicost}, with respect to the desired signal vector $\barbelow{{\hat{a}}}$, is given by \begin{equation} \left\lVert \nabla \mathcal{L} ( \barbelow{{a}},\barbelow{{\hat{a}}}) \right\rVert = \frac{ \sqrt{1-\mathcal{L} ( \barbelow{{a}},\barbelow{{\hat{a}}})^2} }{ \left\lVert \barbelow{{\hat{a}}} \right\rVert }, \label{eq:stoigradnorm} \end{equation} where the gradient $\nabla \mathcal{L} ( \barbelow{{a}},\barbelow{{\hat{a}}})$ is given by \begin{equation} \begin{split} &\nabla \mathcal{L} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big) = \\ & \left[ \frac{\partial \mathcal{L} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big)}{\partial \hat{{a}}_{1}}, \frac{\partial \mathcal{L} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big) }{\partial \hat{a}_{2}}, \dots, \frac{\partial \mathcal{L} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big) }{\partial \hat{a}_{N}} \right]^T, \label{eq:stoigrad} \end{split} \end{equation} and \begin{equation} \begin{split} &\frac{\partial \mathcal{L} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big)}{\partial \hat{a}_{m}} = \\ &\frac{\mathcal{L} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big) \big( \barbelow{{a}}_m - \mu_{\barbelow{{a}}} \big) }{ \big(\barbelow{{\hat{a}}} - \mu_{\barbelow{{\hat{a}}}} \big)^T \big( \barbelow{{a}} - \mu_{\barbelow{{a}}} \big) } - \frac{\mathcal{L} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big) \big( \barbelow{{\hat{a}}}_m - \mu_{\barbelow{{\hat{a}}}} \big) }{ \big(\barbelow{{\hat{a}}} - \mu_{\barbelow{{\hat{a}}}} \big)^T \big( \barbelow{{\hat{a}}} - \mu_{\barbelow{{\hat{a}}}} \big) } . \label{eq:stoipart} \end{split} \end{equation} is the partial derivative of $\mathcal{L} ( \barbelow{{a}},\barbelow{{\hat{a}}})$ with respect to entry $m$ of vector $\barbelow{{\hat{a}}}$. Similarly, the gradient of the STSA-MSE cost function in Eq.\;\eqref{eq:msecost} is given by \begin{equation} \begin{split} &\nabla \mathcal{J} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big) = \frac{2}{N} \left( \barbelow{{a}} - \barbelow{{\hat{a}}} \right), \label{eq:msegrad} \end{split} \end{equation} such that \begin{equation} \begin{split} \left\lVert \nabla \mathcal{J} \big( \barbelow{{a}},\barbelow{{\hat{a}}} \big) \right\rVert = \frac{2}{N} \left\lVert \barbelow{{a}} - \barbelow{{\hat{a}}} \right\rVert. \label{eq:msegradnorm} \end{split} \end{equation} Note, since $ \mathcal{L} ( \barbelow{{a}},\barbelow{{\hat{a}}}) $ is invariant to the magnitude of $\left\lVert \barbelow{{\hat{a}}} \right\rVert$ (see Eq.\;\eqref{eq:stoicost}), and $\barbelow{{a}}$ and $N$ are constants during training, the gradient norm of the ELC cost function, Eq.\;\eqref{eq:stoigradnorm}, with respect to $\barbelow{{\hat{a}}}$, is inversely proportional to the gradient norm of the STSA-MSE cost function, Eq.\;\eqref{eq:msegradnorm}. This suggests that the two cost functions have different optimal learning rates. This observation might partly explain why equality with respect to STOI between STOI optimal and STSA-MSE optimal DNNs were achieved in \cite{kolbaek_monaural_2018-1} but not in \cite{zhao_perceptually_2018,zhang_training_2018,fu_end--end_2018}, as \cite{kolbaek_monaural_2018-1} was the only study that explicitly stated that different learning rates for the two cost functions were used. In fact, in \cite{zhao_perceptually_2018,zhang_training_2018,fu_end--end_2018} the optimization method Adam \cite{kingma_adam:_2014} was used, and although Adam is an adaptive gradient method, it still has several critical hyper-parameters that can influence convergence \cite{wilson_marginal_2017}. During a preliminary grid-search using the validation set corrupted with SSN at an SNR of 0 dB and $N=30$, we found learning rates of $0.01$ and $5 \cdot 10^{-5}$ per sample to be optimal for the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems, respectively. During training, the cost on the validation set was evaluated for each epoch and the learning rates were scaled by $0.7$, if the cost increased compared to the cost for the previous epoch. The training was terminated, if the learning rate was below $10^{-10}$. We implemented the DNNs using CNTK \cite{agarwal_introduction_2014} and the scripts needed to reproduce the reported results can be found in \cite{kolbaek_supplemental_nodate-1}. Note, the goal of these experiments is not to achieve state-of-the-art enhancement performance. In fact, increasing the size of the dataset or DNNs might likely improve performance, although we have not reason to believe it will change the conclusion. \section{Experimental Results}\label{sec:expres} To study the relationship between $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems as function of $N$, we have trained multiple systems for various $N$. Specifically, a total of eight $\text{ES}_{ELC}$ systems and eight $\text{ES}_{MSE}$ systems have been trained with $N$ taking the values $N = \{4, 7, 15, 20, 30, 40, 50, 80\}$, which correspond to temporal envelope vectors with durations from approximately 50 to 1000 milliseconds. \begin{figure*}[ht] \centering \centerline{\includegraphics[trim={57mm 20mm 46mm 17mm},clip,width=1.0\linewidth]{figures/figG/fig1_trn_mix_ttn_bbl.pdf}} \caption{ELC values for $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems trained using various envelope durations, $N$, and tested with corresponding values of $N$ using speech corrupted with BBL noise at an SNR of 0 dB. Each figure shows one out of $J=15$ one-third octave band DNNs (center frequency\,(CF) shown in parenthesis). It is seen that as $N \to 80$ the difference between the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ DNNs, as measured by ELC, tends to zero. This is in line with the theoretical results of Sec.\;\ref{secrelation}. } \label{fig:perband} \end{figure*} \begin{figure*}[ht] \centering \begin{minipage}{.33\textwidth} \centering \centerline{\includegraphics[trim={0mm -11mm 9mm 0mm},clip,width=0.9\linewidth]{figures/figG/fig2_trn_mix_ttn_ssn_all.pdf}} \label{fig:test1} \end{minipage}% \begin{minipage}{.33\textwidth} \centering \centerline{\includegraphics[trim={0mm -11mm 9mm 0mm},clip,width=0.9\linewidth]{figures/figG/fig2_trn_mix_ttn_bbl_all.pdf}} \label{fig:test2} \end{minipage} \begin{minipage}{.33\textwidth} \centering \centerline{\includegraphics[trim={0mm -11mm 9mm 0mm},clip,width=0.9\linewidth]{figures/figG/fig2_trn_mix_ttn_caf_all.pdf}} \label{fig:test3} \end{minipage} % % % \begin{minipage}{.33\textwidth} \centering \centerline{\includegraphics[trim={0mm 0mm 9mm 0mm},clip,width=0.9\linewidth]{figures/figG/fig2_trn_mix_ttn_str_all.pdf}} \label{fig:test4} \end{minipage}% \begin{minipage}{.33\textwidth} \centering \centerline{\includegraphics[trim={0mm 0mm 9mm 0mm},clip,width=0.9\linewidth]{figures/figG/fig2_trn_mix_ttn_bus_all.pdf}} \label{fig:test5} \end{minipage} \begin{minipage}{.33\textwidth} \centering \centerline{\includegraphics[trim={0mm 0mm 9mm 0mm},clip,width=0.9\linewidth]{figures/figG/fig2_trn_mix_ttn_ped_all.pdf}} \label{fig:test6} \end{minipage} \caption{Average ELC differences, as function of envelope durations $N$, between $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems, for different noise types. We observe a monotonic decreasing relationship between the average ELC difference and the envelope length and for $N=80$, the average ELC difference between the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems is close to zero. This is in line with the theoretical results of Sec.\;\ref{secrelation}.} \label{fig:pernoisetype} \end{figure*} \subsection{Comparing One-third Octave Bands} In Fig.\;\ref{fig:perband} we present the ELC scores, as function of envelope duration $N$, for each of the $J=15$ one-third octave band DNNs in the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems. All DNNs are tested using speech corrupted with BBL noise at an SNR of 0 dB. First, we observe that both systems manage to improve the ELC score considerably, when compared to the ELC score of the noisy speech signals, i.e. both systems enhance the noisy speech, which is in line with known results \cite{kolbaek_speech_2017}. Furthermore, we can observe that the DNNs trained with the ELC cost function, i.e. the $\text{ES}_{ELC}$ systems, in general achieve higher, or similar, ELC scores than the DNNs trained with the STSA-MSE cost function, i.e. the $\text{ES}_{MSE}$ systems. This is an important observation, since it verifies that DNNs trained to maximize ELC indeed achieve the highest, or similar, ELC scores compared to DNNs trained to optimize a different cost function, STSA-MSE in this case. Finally, and most importantly, we observe that the difference in ELC score between the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ DNNs generally decrease with increasing $N$. For $N=80$ the ELC score of the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ DNNs practically coincide. \subsection{Comparing ELC across Noise Types} In Fig.\;\ref{fig:pernoisetype} we present the ELC score difference, as function of envelope duration $N$, for $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems, when tested using speech material corrupted with various noise types at an SNR of 0 dB. Specifically, we compute the difference in ELC score for each pair of one-third octave band DNNs in the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems, and then compute the average ELC difference as function of envelope duration $N$. We do this for all the 1000 test utterances and for each of the six noise types introduced in Sec\;\ref{sec:nt}: SSN, BBL, CAF, STR, BUS, and PED. Finally, we compute the $95\%$ confidence interval\,(CI) on the mean ELC difference. From Fig.\;\ref{fig:pernoisetype} we observe that the average ELC difference, i.e. $\text{ES}_{ELC} - \text{ES}_{MSE}$, appears to be monotonically decreasing with respect to the duration of the envelope $N$. Furthermore, we observe that the average ELC difference approaches zero as the duration of the envelope $N$ increases, and similarly to Fig.\;\ref{fig:perband}, for $N=80$, the difference between the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems is close to zero. Finally, we observe that the $95\%$ confidence intervals are relatively narrow for all envelope durations and noise types, which indicate that our test set is sufficiently large to provide accurate estimates of the true mean ELC difference. Similarly to Fig.\;\ref{fig:perband}, the results in Fig.\;\ref{fig:pernoisetype} support the theoretical results of Sec.\;\ref{secrelation}. Additionally, the results in Fig.\;\ref{fig:pernoisetype} show consistency across multiple noise types, which suggests that the theory in practice applies for various noise type distributions. \subsection{Comparing STOI across Noise Types} We now investigate if the global behavior observed for approximate-STOI, i.e. ELC, in Fig.\;\ref{fig:pernoisetype} also applies for real STOI. To do this, we reconstruct the test signals used for Fig.\;\ref{fig:pernoisetype} in the time domain. We follow the technique proposed in \cite{kolbaek_monaural_2018-1}, where a uniform gain across STFT coefficients within a one-third octave band is used before an inverse DFT is applied using the phase of the noisy signal. In Table\,\ref{tab:stoi_scorr1} we present the STOI scores for $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems, as a function of $N$, when tested using speech material corrupted with different noise types at an SNR of 0 dB. Note that these test signals are similar to the test signals used for Fig.\;\ref{fig:pernoisetype} except that we now evaluate them according to STOI and not ELC. From Table\,\ref{tab:stoi_scorr1} we observe that the average STOI difference between the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems is maximum for $N=4$, but quickly tends to zero as $N$ increases and for $N\ge15$, the STOI difference is practically zero, i.e. $\leq 0.01$. {\color{black} Also, we observe that the gap in STOI between the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems closes faster at a lower value of $N$ in Table\;\ref{tab:stoi_scorr1} compared to Fig.\;\ref{fig:pernoisetype}. We believe this is due to the transformation of the, potentially "invalid", sequences of (e.g. \cite{nawab_signal_1983,griffin_signal_1984}) modified magnitude spectra, when reconstructing enhanced time-domain signals, whose intelligibility is estimated by STOI in Table\;\ref{tab:stoi_scorr1}. Therefore, STOI in Table\,\ref{tab:stoi_scorr1} might be computed based on slightly different magnitude spectra compared to the magnitude spectra used for computing the ELC scores in Fig.\;\ref{fig:pernoisetype}. Furthermore, we observe that the $\text{ES}_{MSE}$ achieve slightly higher STOI scores than the $\text{ES}_{ELC}$ systems for $N=4$, which might be due to sub-optimal learning rates as the ones actually used during training of the systems at, e.g. $N=4$, were found based on a grid-search using systems with $N=30$ (see Sec. VI.D). More importantly, the maximum improvement in STOI is achieved for $N=\{15,20,30\}$, where both systems achieve similar STOI scores.} Finally, while the theoretical results of Sec.\;\ref{secrelation} show that approximate-STOI performance of $\barbelow{{\hat{a}}}_{MMELC}$ and $\barbelow{{\hat{a}}}_{MMSE}$ is identical, asymptotically, for $N \to \infty$, the empirical results in Table\,\ref{tab:stoi_scorr1} suggest that $N\ge15$ is sufficient for practical equality to hold for DNN based speech enhancement systems. \begin{table} \caption{{\color{black} STOI scores as function of $N$ for $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems tested using different noise types at an SNR of 0 dB.}} \label{tab:stoi_scorr1} \centering \setlength\tabcolsep{5pt} \resizebox{0.7\columnwidth}{!}{% {\color{black}\begin{tabular}{cccccccccc} \midrule \midrule $N:$ & & $4$ & $7$ & $15$ & $20$ & $30$ & $40$ & $50$ & $80$ \\ \midrule \multirow{ 2}{*}{SSN:} & ELC :& 0.81 & 0.85 & 0.88 & 0.88 & 0.87 & 0.86 & 0.85 & 0.84 \\ & MSE :& 0.84 & 0.87 & 0.87 & 0.87 & 0.87 & 0.86 & 0.85 & 0.84 \\ [6pt] \multirow{ 2}{*}{BBL:} & ELC :& 0.77 & 0.80 & 0.82 & 0.82 & 0.81 & 0.80 & 0.80 & 0.78 \\ & MSE :& 0.79 & 0.82 & 0.82 & 0.82 & 0.81 & 0.80 & 0.80 & 0.78 \\ [6pt] \multirow{ 2}{*}{CAF:} & ELC :& 0.82 & 0.85 & 0.87 & 0.87 & 0.86 & 0.85 & 0.84 & 0.83 \\ & MSE :& 0.85 & 0.87 & 0.87 & 0.87 & 0.86 & 0.85 & 0.85 & 0.84 \\ [6pt] \multirow{ 2}{*}{STR:} & ELC :& 0.83 & 0.86 & 0.88 & 0.89 & 0.88 & 0.87 & 0.87 & 0.85 \\ & MSE :& 0.86 & 0.88 & 0.88 & 0.88 & 0.88 & 0.87 & 0.87 & 0.85 \\ [6pt] \multirow{ 2}{*}{PED:} & ELC :& 0.77 & 0.81 & 0.83 & 0.83 & 0.83 & 0.82 & 0.81 & 0.80 \\ & MSE :& 0.80 & 0.82 & 0.83 & 0.83 & 0.82 & 0.82 & 0.81 & 0.80 \\ [6pt] \multirow{ 2}{*}{BUS:} & ELC :& 0.87 & 0.89 & 0.90 & 0.91 & 0.90 & 0.89 & 0.89 & 0.89 \\ & MSE :& 0.89 & 0.90 & 0.90 & 0.90 & 0.90 & 0.90 & 0.89 & 0.89 \\ [3pt] \midrule \midrule \end{tabular}}} \end{table} \pagebreak \subsection{Comparing Gain-Values} {\color{black} Figures\;\ref{fig:perband} and \ref{fig:pernoisetype}, and Table\,\ref{tab:stoi_scorr1} show that $\text{ES}_{ELC}$ systems achieve approximately the same ELC and STOI values as $\text{ES}_{MSE}$ systems and that the ELC and STOI difference between the two types of systems approach zero as $N$ becomes large. These empirical results are in line with the theoretical results in Sec.\;\ref{secrelation}. } However, the results in Sec.\;\ref{secrelation} predict that not only do $\text{ES}_{ELC}$, and $\text{ES}_{MSE}$ systems produce identical ELC scores, they also predict that the systems are, in fact, essentially identical, i.e. up to an affine transformation. Hence, in this section, we compare how the systems actually operate. Specifically, we compare the gains estimated by $\text{ES}_{ELC}$ systems with gains estimated by $\text{ES}_{MSE}$ systems. In Fig.\;\ref{fig:gaincorr} we present scatter plots, one for each one-third octave band for pairs of gains estimated by $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems tested with BBL noise at an SNR of 5 dB. Each scatter plot consists of 10000 pairs of gains acquired by sampling 10 gain-pairs randomly and uniformly distributed from each of the 1000 test utterances. In Fig.\;\ref{fig:gaincorr}, yellow indicates high density of gain-pairs and dark blue indicates low density. {\color{black} From Fig.\;\ref{fig:gaincorr} it is seen that a correlation no smaller than $0.88$ is achieved for all 15 one-third octave bands. The highest correlation of $r=0.98$ is achieved by bands $5$ to $7$ and the lowest is $r=0.88$ achieved by band $2$ followed by band $1$ with $r=0.89$. } It is also seen that a large number of gain values are either zero, or one, as one would expect due to the sparse nature of speech in the T-F domain. However, although a strong correlation is observed for all bands, the gain-pairs are slightly more scattered at the first few bands than for the remaining bands. This might be explained simply by the fact that low one-third octave bands correspond to single STFT bins, whereas higher one-third octave bands are sums of a large number of STFT bins. This, in turn, may have the consequence that for finite $N$ $(N=30)$, Kolmogorovs strong law of large numbers (see Appendix.\;\ref{sec:zindepedent}) is better valid at higher frequencies than at lower frequencies (so that gain vectors produced by one system is closer to an affine transformation of gain vectors produced by the other system). In fact, if we compute $r_1$ for models trained with $N=50$, we get $r_1 = 0.93$, i.e. increased correlation between the gain vectors produced by the two systems. Finally, in Table.\;\ref{tab:lincorr} we present average correlation coefficients and we observe correlation coefficients $\geq 0.87$ for all, both matched and unmatched, noise types, at multiple SNRs. \begin{figure*}[ht] \centering \centerline{\includegraphics[trim={23mm 5mm 23mm 5mm},clip,width=1.0\linewidth]{figures/figG/exp155_exp255_bbl_snr_5-5_sig_N30.pdf}} \caption{Scatter plots based on gain values from $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems with an envelope length of $N=30$. Dark blue indicate low density and bright yellow indicate high density. The systems are tested with BBL noise corrupted speech at an SNR of 5 dB. Each figure shows one of 15 ($\hat{\mathbf{g}}_1, \hat{\mathbf{g}}_2, \dots, \hat{\mathbf{g}}_{15}$) one-third octave bands. A correlation no smaller than $0.88$ is achieved for all one-third octave bands, which indicates that the $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems estimate fairly similar gain vectors. } \label{fig:gaincorr} \end{figure*} \begin{table} \caption{Sample correlations between gains from $\text{ES}_{ELC}$ and $\text{ES}_{MSE}$ systems with $N=30$. See Fig.\;\ref{fig:gaincorr} for per band correlations.} \label{tab:lincorr} \centering \setlength\tabcolsep{5pt} \resizebox{0.55\columnwidth}{!}{% \begin{tabular}{ccccccc} \toprule \begin{tabular}[c]{@{}c@{}}SNR \\ {[dB]}\end{tabular} & \begin{tabular}[c]{@{}c@{}}SSN \\\end{tabular} & \begin{tabular}[c]{@{}c@{}}BBL \\\end{tabular} & \begin{tabular}[c]{@{}c@{}}CAF \\\end{tabular} & \begin{tabular}[c]{@{}c@{}}STR \\\end{tabular} & \begin{tabular}[c]{@{}c@{}}BUS \\\end{tabular} & \begin{tabular}[c]{@{}c@{}}PED \\\end{tabular} \\ \midrule -5 & 0.94 & 0.87 & 0.89 & 0.93 & 0.87 & 0.90\\ 0 & 0.94 & 0.92 & 0.92 & 0.93 & 0.88 & 0.92\\ 5 & 0.95 & 0.95 & 0.93 & 0.93 & 0.90 & 0.92\\ 10 & 0.95 & 0.95 & 0.92 & 0.92 & 0.91 & 0.93\\ \midrule \midrule \end{tabular}} \end{table} \section{Conclusion}\label{sec:con} This study is motivated by the fact that most estimators used for speech enhancement, being either data-driven models, e.g. \acfp{DNN}, or statistical model-based techniques such as the Short-Time Spectral Amplitude Minimum Mean-Squared Error\,(STSA-MMSE) estimator, use the STSA Mean-Squared Error\,(MSE) cost function as a performance indicator. Short-Time Objective Intelligibility\,(STOI), a state-of-the-art speech intelligibility estimator, on the other hand, rely on the Envelope Linear Correlation\,(ELC) of speech temporal envelopes. Since the primary goal of many speech enhancement systems is to improve speech intelligibility, it raises the question if estimators can benefit from an ELC cost function. In this paper we derive the Maximum Mean Envelope Linear Correlation\,(MMELC) estimator and study its relationship to the well-known STSA-MMSE estimator. We show theoretically that the MMELC estimator, under a commonly used conditional independence assumption, is asymptotically equivalent to the STSA-MMSE estimator. Furthermore, we demonstrate experimentally that this relationship also holds for DNN based speech enhancement systems, when the DNNs are trained to either maximize ELC or minimize MSE and the systems are evaluated using both ELC and STOI. Finally, our experimental findings suggest, that applying the traditional STSA-MMSE estimator on noisy speech signals in practice leads to essentially maximum speech intelligibility as reflected by the STOI speech intelligibility estimator. \begin{subappendices} \pagebreak \section{Maximizing a Constrained Inner Product}\label{sec:lagran} This appendix derives an expression for the zero-mean, unit-norm vector $\barbelow{{e}}(\barbelow{{\hat{a}}})$, which maximizes the inner product with the vector $\mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{e}}(\barbelow{{A}}| \barbelow{{r}}) \right]$. For notational convenience, let $\barbelow{{\alpha}} = \mathbb{E}_{\barbelow{{A}} | \barbelow{{r}} } \left[ \barbelow{{e}}(\barbelow{{A}}| \barbelow{{r}}) \right]$, and $\barbelow{{\beta}} = \barbelow{{e}}(\barbelow{{\hat{a}}})$. The constrained optimization problem from Eq.\;\eqref{eq6} is then defined as \begin{equation} \begin{aligned} & \underset{\barbelow{{\beta}}}{\text{maximize}} & & \barbelow{{\alpha}}^T \barbelow{{\beta}} \\ & \text{subject to} & & \barbelow{{\beta}}^T \barbelow{{1}} = 0, \\ & & &\barbelow{{\beta}}^T\barbelow{{\beta}} = 1. \end{aligned} \label{eq:eqLag1} \end{equation} The vector $\barbelow{{\beta}}^\ast$ that solves Eq.\;\eqref{eq:eqLag1} can be found using the method of Lagrange multipliers \cite{boyd_convex_2004}. Introducing two scalar Lagrange multipliers, $\lambda_1$ and $\lambda_2$, for the two equality constraints, the Lagrangian is given by\footnote{We solve the equivalent problem that minimizes $-\barbelow{{\alpha}}^T \barbelow{{\beta}}$.} \begin{equation} \mathcal{L}(\barbelow{{\beta}},\lambda_1,\lambda_2) = -\barbelow{{\alpha}}^T \barbelow{{\beta}} + \lambda_1 \barbelow{{\beta}}^T \barbelow{{1}} + \lambda_2(\barbelow{{\beta}}^T\barbelow{{\beta}} - 1). \label{eqLag2} \end{equation} Setting the partial derivatives $\frac{\partial \mathcal{L}}{\partial \barbelow{{\beta}}}$ equal to zero \begin{equation} \begin{aligned} \frac{\partial \mathcal{L}}{\partial \barbelow{{\beta}}} & = -\barbelow{{\alpha}} + \lambda_1 \barbelow{{1}} + 2\lambda_2\barbelow{{\beta}} = \barbelow{0}, \\ \end{aligned} \label{eqLag30} \end{equation} and solving for $\barbelow{{\beta}}$, we arrive at \begin{equation} \begin{aligned} \barbelow{{\beta}} & = \frac{\barbelow{{\alpha}} - \lambda_1 \barbelow{{1}}}{2\lambda_2}. \end{aligned} \label{eqLag3} \end{equation} Using the same approach for $\frac{\partial \mathcal{L}}{\partial \lambda_1}$ and $\frac{\partial \mathcal{L}}{\partial \lambda_2}$, substituting in Eq.\;\eqref{eqLag3} and solving for $\lambda_1$, and $\lambda_2$ such that the two constraints are fulfilled, we find \begin{equation} \begin{aligned} \lambda_1 & = \frac{1}{N} \barbelow{{\alpha}}^T \barbelow{{1}} = {\mu}_{\barbelow{{\alpha}}},\\ \end{aligned} \label{eqLag40} \end{equation} and \begin{equation} \begin{aligned} \lambda_2 & = \frac{\lVert \barbelow{{\alpha}} - \barbelow{\mu}_{\barbelow{{\alpha}}} \barbelow{{1}} \rVert }{2}. \end{aligned} \label{eqLag4} \end{equation} Inserting $\lambda_1$ and $\lambda_2$ into Eq.\;\eqref{eqLag3} results in \begin{equation} \begin{aligned} \barbelow{{\beta}}^\ast & = \frac{ \barbelow{{\alpha}} - \barbelow{\mu}_{\barbelow{{\alpha}}} \barbelow{{1}} }{\lVert \barbelow{{\alpha}} - \barbelow{\mu}_{\barbelow{{\alpha}}} \barbelow{{1}} \rVert}, \end{aligned} \label{eqLag5} \end{equation} which is simply the vector $\barbelow{{\alpha}}$, normalized to zero sample mean and unit norm. \section{Factorization of Expectation}\label{sec:zindepedent} This appendix shows that the expectation in Eq.\;\eqref{eq11} factorizes into the product of expectations in Eq.\;\eqref{eq14}, asymptotically as $N \to \infty$. Let \begin{equation} \barbelow{{Y}} \triangleq \barbelow{{A}} | \barbelow{{r}}, \label{eqz1} \end{equation} and \begin{equation} \barbelow{\barbelow{{H}}} \triangleq \barbelow{\barbelow{I}}_N - \frac{1}{N} \barbelow{{1}}\One^T, \label{eqz2} \end{equation} so that \begin{equation} \barbelow{{Z}} = \barbelow{\barbelow{{H}}} \barbelow{{Y}}, \label{eqz3} \end{equation} where $\barbelow{\barbelow{I}}_N$ denotes the $N$-dimensional identity matrix and $\barbelow{{A}} | \barbelow{{r}} $ is a random vector distributed according to the conditional probability density function $ f_{\A \lvert \R} \left( \sa \lvert \sr \right)$. A specific element $Z_i$, of $\barbelow{{Z}}$ is then given by \begin{equation} \begin{split} Z_i &= \barbelow{{h}}_i^T \barbelow{{Y}} \\ & = S_i - \frac{1}{N} \barbelow{{1}}^T \barbelow{{Y}}, \\ \end{split} \label{eqz4} \end{equation} where $\barbelow{{h}}_i$ is the $i$th column of matrix $ \barbelow{\barbelow{{H}}}$. We now define the covariance between $Z_i$ and $1/\lVert \barbelow{{Z}} \rVert$ as \begin{equation} \begin{split} \text{cov}(Z_i , \frac{1}{\big\lVert \barbelow{{Z}} \big\rVert} ) &\triangleq \mathbb{E} \left[ \bigg( Z_i - \mathbb{E} \left[ Z_i \right] \bigg) \bigg( \frac{1}{ \big\lVert \barbelow{{Z}} \big\rVert } - \mathbb{E} \left[ \frac{1}{ \big\lVert \barbelow{{Z}} \big\rVert } \right] \bigg) \right] \\ & = \mathbb{E} \left[ \frac{ Z_i }{ \big\lVert \barbelow{{Z}} \big\rVert } \right] - \mathbb{E} \left[ Z_i \right] \mathbb{E} \left[ \frac{1}{\big\lVert \barbelow{{Z}} \big\rVert } \right]. \\ \end{split} \label{eqz5} \end{equation} We can rewrite the factors on the right-hand side of Eq.\;\eqref{eqz5} as follows \begin{equation} \begin{split} \mathbb{E} \left[ Z_i \right] &= \mathbb{E} \left[ \barbelow{\mathbf{h}}_i^T \barbelow{{Y}} \right] \\ & = \mathbb{E} \left[ S_i - \frac{1}{N} \barbelow{{1}}^T \barbelow{{Y}} \right] \\ & = \mathbb{E} \left[ S_i \right] - \frac{1}{N} \barbelow{{1}}^T \mathbb{E} \left[ \barbelow{{Y}} \right] \\ & = \mathbb{E} \left[ S_i \right] - \frac{1}{N} \sum_{j=1}^{N} \mathbb{E} \left[ S_j \right], \\ \end{split} \label{eqz6} \end{equation} \begin{equation} \begin{split} \mathbb{E} \left[ \frac{1}{\big\lVert \barbelow{{Z}} \big\rVert } \right] &= \mathbb{E} \left[ \frac{1}{ \sqrt{ \barbelow{{Y}}^T \barbelow{\barbelow{{H}}} \barbelow{\barbelow{{H}}}^T \barbelow{{Y}}} } \right] \\ & = \mathbb{E} \left[ \frac{1}{ \sqrt{ \barbelow{{Y}}^T \barbelow{\barbelow{{H}}} \barbelow{{Y}}} } \right] \\ & = \mathbb{E} \left[ \frac{1}{ \sqrt{ \barbelow{{Y}}^T\barbelow{{Y}} - \frac{1}{N} \barbelow{{Y}}^T \barbelow{{1}} \barbelow{{1}}^T \barbelow{{Y}}} } \right] \\ & = \mathbb{E} \left[ \frac{1}{ \sqrt{ \sum_{j=1}^{N}S_j^2 - \frac{1}{N} \left( \sum_{j=1}^{N}S_j \right)^2 } } \right] \\ & = \mathbb{E} \left[ \frac{\sqrt{\frac{1}{N}}}{ \sqrt{ \frac{1}{N} \sum_{j=1}^{N}S_j^2 - \left( \frac{1}{N} \sum_{j=1}^{N}S_j \right)^2 } } \right], \\ \end{split} \label{eqz7} \end{equation} and \begin{equation} \begin{split} \mathbb{E} \left[ \frac{ Z_i }{ \big\lVert \barbelow{{Z}} \big\rVert } \right] &= \mathbb{E} \left[ \frac{ \sqrt{ \frac{1}{N}} \left( S_i - \frac{1}{N} \sum_{j=1}^{N}S_j \right)}{ \sqrt{ \frac{1}{N} \sum_{j=1}^{N}S_j^2 - \left( \frac{1}{N} \sum_{j=1}^{N}S_j \right)^2 } } \right]. \\ \end{split} \label{eqz8} \end{equation} In Eqs.\;\eqref{eqz6}, \eqref{eqz7} and \eqref{eqz8} two different sums of random variables occur, \begin{equation} \begin{split} \frac{1}{N} \sum_{j=1}^{N}S_j, \\ \end{split} \label{eqz10} \end{equation} and \begin{equation} \begin{split} \frac{1}{N} \sum_{j=1}^{N}S_j^2. \\ \end{split} \label{eqz11} \end{equation} Since, by assumption, Eq.\;\eqref{eqz9}, $S_j\;\forall \;j$ are independent random variables with finite variances\footnote{Assuming a finite variance of $S_j$ is motivated by the fact that $S_j$ model speech signals, which always take finite values due to both physical and physiological limitations of sound and speech production systems, respectively.}% , according to Kolmogorovs strong law of large numbers \cite{sen_large_1994}, the sums given by Eqs.\;\eqref{eqz10} and \eqref{eqz11} will converge (almost surely, i.e. with probability\;($\Pr$) one) to their average means $\mu_S = \frac{1}{N}\sum_{j=1}^{N}\mathbb{E}[S_j]$, and $\mu_{S^2} = \frac{1}{N}\sum_{j=1}^{N}\mathbb{E}[S_j^2]$, respectively, as $N \to \infty$. Formally, we can express this as \begin{equation} \begin{split} \Pr &\left( \lim\limits_{N \to \infty} \frac{1}{N} \sum_{j=1}^{N}S_j = \mu_{S} \right) = 1, \\ \end{split} \label{eqz12} \end{equation} and \begin{equation} \begin{split}% \Pr &\left( \lim\limits_{N \to \infty} \frac{1}{N} \sum_{j=1}^{N}S_j^2 = \mu_{S^2} \right) = 1. \\ \end{split} \label{eqz13} \end{equation} By substituting Eqs.\;\eqref{eqz12}, and \eqref{eqz13} into Eqs.\;\eqref{eqz6}, \eqref{eqz7} and \eqref{eqz8}, we arrive at \begin{equation} \begin{split} \lim\limits_{N \to \infty} \mathbb{E} \left[ Z_i \right] &= \mathbb{E} \left[ S_i \right] - \mu_S, \\ \end{split} \label{eqz14} \end{equation} \begin{equation} \begin{split} \lim\limits_{N \to \infty} \mathbb{E} \left[ \frac{1}{\big\lVert \barbelow{{Z}} \big\rVert } \right] &= \frac{\lim\limits_{N \to \infty} \sqrt{\frac{1}{N}}}{ \sqrt{ \mu_{S^2} - \mu_S^2 } } , \\ \end{split} \label{eqz15} \end{equation} and \begin{equation} \begin{split} \lim\limits_{N \to \infty} \mathbb{E} \left[ \frac{ Z_i }{ \big\lVert \barbelow{{Z}} \big\rVert } \right] &= \left(\mathbb{E} \left[ S_i \right] - \mu_S \right) \frac{\lim\limits_{N \to \infty} \sqrt{\frac{1}{N}} }{ \sqrt{ \mu_{S^2} - \mu_S^2 } } \\ & = \lim\limits_{N \to \infty} \mathbb{E} \left[ Z_i \right] \mathbb{E} \left[ \frac{ 1 }{ \big\lVert \barbelow{{Z}} \big\rVert } \right] , \\ \end{split} \label{eqz16} \end{equation} where the last line follows from Eq.\;\eqref{eqz14} and \eqref{eqz15}. In words, as $N \to \infty$, the covariance between $Z_i$ and $1/\lVert \barbelow{{Z}} \rVert$ tends to zero and, consequently, the expectation in Eq.\;\eqref{eq11} factorizes into the product of expectations in Eq.\;\eqref{eq14}. \end{subappendices}
\section{Introduction} The human intestinal environment is host to a variety of microbial organisms. This community is an essential component of human health \cite{Clemente2012}. Microbiome composition has been associated with increased risk for multiple common diseases, among them type 2 diabetes~\cite{Larsen2010}, obesity~\cite{Flint2011}, and Crohn's disease~\cite{Morgan2012}. Nonetheless, the complex interactions between host, environment, and external perturbations are just beginning to be understood \cite{Caporaso2011, David2014}. Recent advances in metagenomic and targeted DNA sequencing, as well as reduced cost, have allowed researchers to investigate the microbiome in unprecedented detail \cite{Kuczynski2012}. However, the utility of this data in a clinical setting remains under-explored~\cite{Quigley2017}. Previous work has focused on developing deterministic or descriptive approaches to establish the role of the microbiome in providing resistance to infection, e.g. \cite{Stein2013}. Intestinal domination (an imbalance in community composition favoring one taxon) of Enterococcus, Streptococcus, or Proteobacteria were common complications, which further increased the risk of bacteremia in each patient. Yet, these approaches ignore randomness in the underlying system as well as measurement noise, and therefore provide limited capacity to predict patient outcomes. In contrast, probabilistic approaches provide a natural way to model uncertainty, and provide a systematic way to make predictions. Here we develop a probabilistic time-series model of microbiome community dynamics. Our goals are three-fold: i) incorporate uncertainty in the ascertainment process, ii) develop a model capable of capturing interactions within the community over time, and; iii) explicitly model external effects such as antibiotics. We test our model on a data set of 94 patients of various cancers (majority Leukemia and Lymphoma) undergoing allogenic hematopoetic stem cell transplant (allo-HSCT). Two common complications of this procedure are bacteremia, a bacterial infection of the blood, and intestinal domination, defined to be the event that relative abundance of one bacteria was greater than $30\%$. We demonstrate that by incorporating randomness into the time-series analysis of microbial community dynamics, we can more accurately predict patient outcomes such as bacteremia and intestinal domination, than using community composition alone. \section{Methods} \label{sec:methods} \subsection{A Latent Probabilistic Model Based on Kalman Filters} We observe DNA read counts from each bacterial taxon, while the true community composition --- the relative abundance of each taxon in a patient sample --- is latent. We model temporal dynamics of the community as latent factors of a linear dynamical system~\cite{Bishop2006}. The community composition at each time point depends on the previous composition, as well as external effects such as antibiotics. The observed data are noisy observations of the latent state. Formally, our Kalman-Filter-based model ${\cal M}(A, B, Q, Q_0, R, {\bf \mu_{0})}$ is \begin{eqnarray} {\bf z_0} &\sim N({\bf \mu_{0}}, Q_0) \\ {\bf z_{t+1}} \big| {\bf z_t} &\sim N(A{\bf z_t} + B{\bf u_t}, Q) \\ {\bf x_t} | {\bf z_t} &\sim N({\bf z_t}, R) \end{eqnarray} Here, time $t$ is measured in days. Tomorrow's vector representing each species' abundance, $\bf z_{t+1}$, depends on today's composition ($\bf z_t$), interactions between pairs of taxa (the matrix $A$), the antibiotic dosage ($\bf u_t$), and the effect on antibiotics on each taxon ($B$). Observations $\bf x_t$ pose several challenges. First, they are not daily, nor evenly spaced, but we still model days as latent $\bf z_t$, even if observations are available only for a subset $S$ of days. Further challenging is data only available in relative abundances, listing the frequency of each taxon at a time step, not the absolute count of cells. Thus, observation vectors are constrained to the positive $L^1$ unit sphere, making time series modeling difficult. We investigated several data transformations to infer through this constraint, and decided to use the centered log-ratio transform (clr) \cite{Kurtz2015}: the vector ${\bf y} = ({\bf y}[1], ..., {\bf y}[D])$ of relative abundances of $D$ taxa, is log-transformed and mean-shifted: \begin{equation} \text{clr}({\bf y}) = \left(\log \frac{{\bf y}[1]}{(\prod_{i=1}^D{\bf y}[i])^{1/D}}, ...,\log \frac{{\bf y}[D]}{(\prod_{i=1}^D{\bf y}[i])^{1/D}} \right) \end{equation} We map ${\bf y}$ to a modeled observation ${\bf x}\in {\mathbb R}^{D-1}$ as ${\bf x} = (\text{clr}(\textbf{y})[1],\ldots,\text{clr}(\textbf{y})[D-1])$. This mapping is invertible as \begin{equation} {\bf y} = \text{normlize}( (e^{\textbf{x}[1]},\ldots,e^{\textbf{x}[D-1]}, e^{-\sum_d \textbf{x}[d]})) \end{equation} We learn parameters $A, B, Q, Q_0, R, {\bf \mu_0}$ using an EM algorithm \cite{Dempster1977}. Given this formulation, we can still compute both marginal conditional expectations of $\bf z_t$ in the E step and closed form expressions for the optimal model parameters in the M step regardless of missing daily observations, in the transformed, unconstrained space. \subsection{Prediction of Clinical Events} To predict the clinical events of bacterial domination and bacteremia, we trained our Kalman Filter model on other samples (50X cross-validation), and fit a linear logistic classifier~\cite{Pedregosa2011}. The classifier's input was latent composition vectors predicted by the model for the time of the event. This was compared against a baseline of predictions based on the most recent observation of a composition vector. We repeated these predictions using composition vectors either in original frequency space, or as clr-transformed vectors. For domination of a particular taxon, we further explored regressing only on the abundance of that taxon. We considered several predictions of clinical events of bacterial domination and bacteremia. Predictions used logistic regression. We repeated these predictions using either the clr-transformed vectors or the abundances. For evaluating the contribution of antibiotics to clinical events, we forward simulated the model starting from each observation time point for 10 days. We reported the simulation with or without the drug under consideration and registered the reported probabilities for the clinical event. \subsection{Data and availability} 439 measurements of gut microbiome composition were collected across 94 subjects undergoing allo-HSCT~\cite{Taur2012} followed by a regimen of antibiotics. Measurements were spaced 1-21 days (median: 7), and spanned a period of 0-13 days (median: 6) before and 7-35 days (median: 18) after the transplantation. Measurements were taken by extracting DNA from fecal specimens amplifying the V1-V3 region of the 16S rRNA genes, and phylogenetic classification of each sequence performed at the genus level (see~\cite{Taur2012} for more details). \section{Results} \begin{figure} \includegraphics[width=\linewidth]{NIPSimage/PredictDominance2} \caption{\label{fig:pred_domination} Receiver-Operator Curves (ROC) demonstrating performance of our classifier on predicting intestinal domination by Enterococcus (left) Streptococcus (middle) and Proteobacteria (right).We compare the classifiers built by: (1) clf transformation (solid) vs. original frequency (dashed) vs. frequency of that bacteria alone (dotted) ; and (2) Kalman Filter prediction (green) vs. Most recent observation (red)} \end{figure} We first sought to predict which patients will develop intestinal domination of one of the above bacteria. Our Kalman Filter predictions of bacterial domination (Figure~\ref{fig:pred_domination}) consistently exceed baseline performance. Specifically, Enteroccocus domination is predicted by the Kalman Filter with Area Under Curve (AUC) of 0.78, while that of most recent observation was 0.77. Similar improvements were demonstrated for Streptococcus (0.66 vs. 0.59) and Proteobacteria domination (0.72 vs, 0.63). Reassuringly, the best Kalman Filter prediction prediction was always the one based on the dominant taxon only. \begin{figure} \includegraphics[width=\linewidth]{NIPSimage/PredictBacteremia2} \caption{\label{fig:pred_bacteremia} ROCs demonstrating performance of our classifier on predicting bacteremia due to VRE (left), gram-negative bacteria (middle), or all (right). Dashed/solid and color conventions follow Figure~\ref{fig:pred_domination}.} \end{figure} We separately fit classifiers for the outcome variable of bacteremia, either due to Vancomycin-resistant Enterococcus (VRE), or by gram-negative bacteria. Again, our model outperformed our baseline measures (Figure~\ref{fig:pred_bacteremia}). AUCs for Kalman Filter predictions were 0.83 (VRE bacteremia), 0.70 (gram-negative bacteremia) and 0.68 (any bacteremia), compared to the AUCs for best MRO classifers (0.76, 0.69 and 0.58, respectively). \begin{figure} \begin{subfigure}{0.48\textwidth}\label{fig:dom_risk} \includegraphics[width=\linewidth]{NIPSimage/DominationAntibiotics} \subcaption{} \end{subfigure} \begin{subfigure}{0.48\textwidth}\label{fig:bacteremia_risk} \includegraphics[width=\linewidth]{NIPSimage/BacteremiaAntibiotic} \subcaption{} \end{subfigure} \caption{ \label{fig:eval_risk} Effect of antibiotics on intestinal domination and bacteremia. a) Metronidazole increases the risk of Enterococcus domination, Fluoroquinolone reduces the risk of Proteobacteria domination, and Beta-lactum reduces the risk of Streptococcus domination. b) Metronidazole increases the risk of VRE bacteremia and gram-negative bacteremia.} \end{figure} We next turned evaluating the contribution of antibiotics to bacterial domination and bacteremia (see Section~\ref{sec:methods}). For each observation timepoint, we plot the evaluated probability of the clinical event occurrence with vs. without a particular antibiotic drug (Figure \ref{fig:eval_risk}). Our analysis of domination is qualitatively consistent with previous findings~\cite{Taur2012}: Metronidazole is significantly positively associated with Enterococcus domination, increasing the probability of domination by 25.7 percentage points (pp) on average and (1.6-fold); Fluoroquinolone is negatively associated with Proteobacteria domination, decreasing the probability by 19.7pp and 1.46-fold. We observe that these fold change evaluations are lower than those of~\cite{Taur2012}, whose respective point-estimates are 3-fold and 10-fold. We further discover a strong association between Beta-lactam and Streptococcus domination, whose domination probability it reduces by 23.7pp (1.41-fold). An analogous analysis of bacteremia highlights Metronidazole. As expected from its association with Enterococcus domination, it increases the risk of VRE bacteremia 1.9-fold. Our model further discovers Metronidazole to be positively associated with gram-negative bacteremia, increasing its probability 1.4 fold. This is an improvement over the previous study ~\cite{Taur2012} which used survival analysis only and did not detect the effect of the beta-lactam antibiotics on the decreasing risk of Streptococcus domination. \section{Discussion} In this paper, we have developed a probabilistic model for microbiome community dynamics that explicitly incorporates measurement error and external effects such as antibiotics. We demonstrated the utility of this approach by applying our model to data from real patients, and showed that incorporating time-series information leads to better predictions for patient outcomes. Finally, we used this framework to discover links between antibiotics and clinical outcomes, validating discoveries against published results. Kalman Filter essentially attempts to optimize estimation of the latent composition vectors, minimizing RMSE under the appropriate transformation~\cite{Kurtz2015}. It can therefore predict composition well under this transformation, but not without it (data not shown). Instead, we focused on predicting outcomes. These seem more robust to transformations, and preserve the utility of the prediction. Nonetheless, there is still room for improvement to our model. The predicted microbiome composition, though informative, is a noisy estimate at best (data not shown). This is likely due to either data sparsity in time -- our observations are several days apart, or data size --- we only have 94 patients. Either of these could be remedied using denser data with more patients, which are likely to be available soon.
\section{Introduction} In recent years, dialogue systems have received increasing attention in numerous web applications~\cite{Young2013POMDP,Ritter2011Data,Banchs2013IRIS,Ameixa2014Luke}. Existing dialogue systems can fall into two categories: non-task-oriented dialogue systems and task-oriented dialogue systems. Non-task-oriented dialogue systems aim to generate fluent and engaging responses, whereas task-oriented dialogue systems need to complete a specific task, e.g., restaurant reservation, along with a response generation process. Employing neural networks to generate natural and sound responses, the task of \emph{neural dialogue generation} is playing an important role in dialogue systems~\cite{shang,vinyals2015neural,sordoni2015,li2016a,li2016b,serban2016building,Bordes2016Learning,wen-EtAl:2017:EACLlong,pei18emnlp}. In a dialogue, a \emph{dialogue state} refers to a full and temporal representation of each participant's intention~\cite{goddeau1996form}. Thus in neural dialogue generation, dynamically tracking dialogue states is the key for generating coherent and context-sensitive responses. Numerous dialog state tracking mechanisms with a limited state space have been proposed for task-oriented dialogue systems, e.g., hand-crafted rules~\cite{goddeau1996form,wang2013simple}, conditional random fields~\cite{lee2013recipe,lee2013structured,ren2013dialog}, maximum entropy~\cite{williams2013multi}, and neural networks~\cite{henderson2013deep}. As a state-of-the-art work, \emph{explicit dialog state tracking via an interpretable text span} has been preliminarily attempted on task-oriented dialogue systems \if0to track participants' intention at each dialog step for knowledge base interaction\fi~\cite{sequicity}. Differently, in non-task-oriented dialogue systems, most of existing state tracking approaches employ a fixed-size latent vector to represent the whole dialogue history~\cite{serban2016building}. Though these solutions are capable for chit-chat conversations, they fail to distinguish similar concepts or entities(e.g., product names) which are often key information in technical and transactional domains~\cite{Bordes2016Learning}. Moreover, these latent vectors have weak interpretability\if0which results in limited performance\fi. However, existing solutions to explicit state tracking cannot be applied in non-task-oriented dialogue systems, since these supervised approaches typically require large amounts of manually annotated dialogue states. Accordingly, the neural dialogue generation faces a dilemma between reducing the expense of data annotation and improving the performance of dialogue state tracking: (1) For both task-oriented and non-task-oriented dialogue generation, existing explicit approaches requires a large amounts of manually labeled data to train the state tracker~\cite{sequicity}. Heavily relying on the expensive annotated corpus, these methods lead the state tracker extremely difficult to be transferred to new scenarios or extended to a larger state space. (2) Most of unexplainable state trackers in non-task-oriented dialogue generation are not capable of explicitly tracking long-term dialogue states, limiting their capability in complicated domains. To tackle the above challenges, our focus is on developing methods to construct an explicit dialogue state tracker with unlabeled data for neural dialogue generation. In this paper, we propose a semi-supervised neural network, named the \emph{semi-supervised explicit dialogue state tracker} (\textbf{SEDST} for short), to explicitly track dialogue states for both task-oriented and non-task oriented dialogue generation with a text span. Along with SEDST, we propose a novel encoder-decoder architecture based on copying mechanism~\cite{gu2016incorporating}, called \emph{CopyFlowNet}, to represent dialogue states with explicit word sequences. We infer these word sequences, i.e., text spans, through a probabilistic distribution over the vocabulary space. To optimize the training procedure of SEDST, we employ a posterior regularization strategy to integrate indirect supervision from unlabeled data. Thus SEDST is compatible for both supervised and unsupervised learning scenarios. In our experiments, we verify the effectiveness of our proposed method in both task-oriented dialogue generation and non-task-oriented dialog generation, respectively. We find that SEDST, under 50\% data annotated setup, outperforms state-of-the-art task-oriented dialogue generation baselines, as well as outperforms non-task-oriented baselines under no data annotated setup. Moreover, we deeply analyze and verify the effectiveness of the posterior regularization strategy in incorporating indirect supervision for the dialogue state tracking. \smallskip\noindent \noindent To sum up, our main contributions can be summarized as follows: \begin{itemize} \item We focus on tracking explicit dialogue states with semi-supervision for neural dialogue generation. \item We propose a semi-supervised neural dialogue generation framework, called \textbf{SEDST}, for both task-oriented and non-task-oriented dialogue systems. \item We propose an explicit dialogue state tracker, CopyFlowNet, with implicit copyNets and posterior regularization. \item We verify the effectiveness of SEDST in our extensive experiments on both task-oriented copora and non-task-oriented copora. \item We deeply study and analyze the performance of SEDST and other widely used two-stage decoding models in dialogue systems. \end{itemize} \noindent We introduce related work in \S\ref{section2}. We provide preliminaries in \S\ref{section3} and describe our approach in \S\ref{section4}. Then, \S\ref{section5} details our experimental setup, \S\ref{section6} presents the results, and \S\ref{section7} concludes the paper. \section{Related Work} \label{section2} We detail our related work on two lines: neural dialogue generation and dialogue state tracking. \subsection{Neural dialogue generation} Neural dialogue generation aims at generating natural-sounding replies automatically to exchange information, e.g., knowledge~\cite{Young2013POMDP,shawar2007,chen18www}. As a core component of both task-oriented and non-task-oriented dialogue systems, neural dialogue generation has received a lot attention in recent years~\cite{Young2013POMDP,Ritter2011Data,Banchs2013IRIS,Ameixa2014Luke}. Among all these approaches, sequence-to-sequence structure neural generation models~\cite{shang,vinyals2015neural,sordoni2015,li2016a,li2016b,serban2016building,cao2017,chen18www} have been proved to be capable in multiple dialogue systems with promising performance. Several approaches have been proposed to softly model language patterns such as word alignment and repeating into sequence-to-sequence structure~\cite{bahdanau2015neural,xing2016topic,gu2016incorporating,serban2017multiresolution,cao2017}. \citet{xing2016topic} employ attention mechanism~\cite{bahdanau2015neural} to dynamically incorporates contextual information into response generation. \citet{gu2016incorporating} propose a copy mechanism to consider additional copying probabilities for contextual words in forum conversations. \citet{serban2017multiresolution} decodes coarse tokens before generating the fulls response. \citet{cao2017} tackle the boring output issue of deterministic dialogue models by introducing a latent variable model for one-shot dialogue response. In \cite{dawnet}, the authors selects and predicts explicits keywords using before response generation. \citet{zhang2017acl} use a log-linear model to represent the desired distribution and inject the prior knowledge by a posterior regularization. Additionally, recent work verify that reinforcement learning is a promising paradigm when state and action spaces are carefully designed~\cite{williams-asadi-zweig:2017:Long,dhingra-EtAl:2017:Long1}. \subsection{Dialogue state tracking} Dialogue state tracking is an important ingredient of the dialogue generation. Traditional methods utilize hand-crafted rules to select the dialogue state~\cite{goddeau1996form}. Relying on the most likely results from an natural language understanding (NLU) module~\cite{Perez17}, these rule-based systems hardly models uncertainty, which is prone to frequent errors~\cite{williams2014web,Perez17}. \citet{Young2010The} propose a distributional dialogue state for statistical dialog system and maintain a distribution over multiple hypotheses facing with noisy conditions and ambiguity. Another typical form of dialogue state is in the form of a probability distribution over each slot for each turn~\cite{Williams2012A,williams2013dialog}. In task-oriented dialogue systems, end-to-end neural networks have been successfully employed for tracking dialogue states via interacting with an external knowledge base~\cite{wen-EtAl:2017:EACLlong,eric2017key,Bordes2016Learning,williams-asadi-zweig:2017:Long}. \citet{wen-EtAl:2017:EACLlong} divide the training procedure into two phases: the dialogue state tracker training, and the whole model training. \citet{mrkvsic2016neural} proposed a dialogue state tracker based on word embedding similarities. \citet{eric2017key} implicitly model a dialogue state through an attention-based retrieval mechanism to reason over a key-value representation of the underlying knowledge base. \citet{Bordes2016Learning} memories the dialogue context in a memory module and repeatedly queries and reasons about this context to select an adequate system response. Instead of employing symbolic knowledge queries, \citet{dhingra-EtAl:2017:Long1} propose an induced ``soft'' posterior distribution over the knowledge base to search matching entities. \citet{sequicity} proposed an extendable framework to track dialogue states with a text span including the constraints for a knowledge base query. In non-task-oriented dialogue systems such as forum conversations, lots of efforts have been made to keep track of the dialogue process in multi-turn settings~\cite{serban2016building,Sordoni2015hre,hvred}. \citet{serban2016building} and \citet{Sordoni2015hre} incorporates hierarchical structures in word and sentence levels to encourage cohesive multi-turn dialogue generation. \citet{hvred} utilize a latent variable at the sub-sequence level in a hierarchical setting. \citet{chen18www} add a hierarchical structure and a variational memory module into a neural encoder-decoder network. However, all these latent vectors and latent memories are unexplainable, which makes it challenging to verify the effectiveness of dialogue state tracking. Moreover, these unexplainable latent vectors fail to distinguish distinctive concepts with similar vector representation, e.g., product names. \smallskip\noindent Our work differs from previous work in the following important ways: (1) We represent dialogue states in text spans explicitly; (2) We propose the CopyFlowNet which enables semi-supervised and unsupervised training of the state tracker; (3) We propose a novel training method incorporating posterior regularization to improve the robustness. \begin{table}[!t] \caption{Glossary.} \centering \begin{tabular}{ll} \hline \textbf{Symbol} & \textbf{Description}\\ \hline $D$ & a dialogue session \\ $U$ & a user utterance \\ $R$ & a machine response \\ $S$ & a text span for dialogue state tracking\\ $X$ & an input sequence\\ $Y$ & an output sequence\\ $s$ & an element in a text span \\ $x$ & an element in a source sequence \\ $y$ & an element in a target sequence \\ $N$ & length of an utterance, text span and a machine response\\ $w_x$ & a word input in source sequence \\ $\mathbf{h}$ & a hidden vector generated in a GRU.\\ $e$ & an entity obtained in the knowledge base search\\ $\mathcal{I}$ & a user's intention in a dialogue\\ $\mathcal{V}$ & vocabulary \\ $\mathcal{K}$ & a knowledge base \\ $\mathcal{A}$ & a set of annotated training instances \\ $\mathcal{U}$ & a set of unannotated training instances \\ \hline \end{tabular} \label{tab:glossary} \vspace{-1.0em} \end{table} \section{Preliminaries} \label{section3} In this section, we first formalize task-oriented and non-task-oriented dialogue systems. Thereafter, we introduce the approach of tracking dialogue state using text spans. \subsection{Problem formulation} Before introducing our method for dialogue state tracking, we introduce our notation and key concepts. Table~\ref{tab:glossary} lists our notations in this paper. Given $T$ dialogue turns, a \emph{dialogue session} $D$ consists of a sequence of utterances, i.e., $D=\{U_{1}, R_1, U_2, R_2 .., U_{T}, R_T\}$, where $U$, $R$ refers to responses from a user and a machine respectively. At the $t$-th turn, given the current user utterance $U_t$ and historical records $U_{1}, R_1, U_2, R_2..,U_{t-1},R_{t-1}$, the dialogue system generates a response $R_t$. Probabilistically, the system generates $R_t$ via maximizing the probability $P(R_t|U_{1}, R_1, U_2, R_2..,U_{t-1},R_{t-1})$, shown in Eq.~\ref{eq:rt1}: \begin{equation} \label{eq:rt1} R_t = \mathop{\mathrm{arg}\,\max} P(R_t|U_{1}, R_1, U_2, R_2..,U_{t-1},R_{t-1}, U_t), \end{equation} \noindent \emph{Task-oriented dialogue system} includes the \emph{task completion} component which is specified by users (e.g., reserving an restaurant)~\cite{wen2017network}. To further formulate the task completion, we denote the user intention as $\mathcal{I}$. In this paper, we simplify the user's intention as a specific entity $e$, searched in knowledge bases at the end of a dialogue. \noindent \emph{Non-task oriented systems}, differently, just focus on generating engaging and coherent responses. Typically they involve broader domains and more complicated contextual information~\cite{serban2017multiresolution,dawnet}. Note that it is difficult to find a clear boundary between task oriented dialogue systems and non-task oriented dialogue systems. To clarify the difference between these two types of dialogue systems, in this paper any dialogue system including knowledge base interactions refers to a task-oriented dialogue system. Dialogue state tracking is the key component for both non-task-oriented dialogue systems and task oriented dialogue systems. In non-task oriented dialogue systems, dialogue state tracking is a key to generate context-aware and coherent responses. Whereas in task-oriented dialogue systems, dialogue state tracking is becoming mandatory since it has to capture users' request and constraints for knowledge base search. \subsection{Dialogue state tracking using text spans} Text-span based dialogue state trackers have been proposed to manifest simplicity along with better interpretability~\cite{wen2017network,sequicity}. At $t$-th turn, such state tracker employs a text span $S_t$ (i.e., a sequence of words) to track dialogue states. $S_t$ aims at summarizing past utterances and responses (i.e., $U_1$, $R_1$, $U_2$, $R_2$,...,$U_{t-1}$,$R_{t-1}$$,U_t$). We follow the notation from the Sequicity~\cite{sequicity}, which is a state-of-the-art dialogue state tracker for the task-oriented dialogue generation. Sequicity defines a text span over the full vocabulary space called \emph{bspan} (denoted as $S_t$), which records all ``requestable slots'' and ``informable slots''~\cite{wen2017network}, each separated with delimiters. Informable slots track the constraints which are used for knowledge base search while requestable slots record what users are looking for in current dialogues. With bspan, knowledge base search can be performed by taking informable slots as search constraints. As such, task completion can be converted as a problem of generating a text span $S_t$ at each turn. Generating a text span $S_t$ of keywords also improves performance of single response generation~\cite{serban2017multiresolution,dawnet}. We elaborate this strategy into dialogue state tracking within multi-turn dialogues for non-task oriented dialogues. In our work, we define a \emph{state span} as a text span that indicates a dialogue state. Shown in Eq.~\ref{eq1:st}, in this paper the problem of both task-oriented and non-task-oriented dialogue generation can be decomposed into two successive steps: (1) generating a state span $S_t$; (2) generating the response $R_t$. \if0 \begin{eqnarray} \label{eq1:st} S_t & = & \mathop{\mathrm{arg}\,\max} P(S_t|U_{1}, R_1, U_2, R_2..,U_{t-1},R_{t-1}, U_t),\\ \label{eq1:rt} R_t &=& \mathop{\mathrm{arg}\,\max} P(R_t|S_t, U_{1}, R_1, U_2, R_2..,U_{t-1},R_{t-1}, U_t). \end{eqnarray} \fi \begin{flalign} \label{eq1:st} \begin{split} & S_t = \mathop{\mathrm{arg}\,\max} P(S_t|U_{1}, R_1, U_2, R_2..,U_{t-1},R_{t-1}, U_t), \\ & R_t = \mathop{\mathrm{arg}\,\max} P(R_t|S_t, U_{1}, R_1, U_2, R_2..,U_{t-1},R_{t-1}, U_t). \end{split} \end{flalign} \section{Method} \label{section4} \begin{figure*}[!t] \centering \includegraphics[width=0.9\textwidth,height=0.4\textwidth]{fig_overview.pdf} \caption{Overview of our dialogue model with semi-supervised explicit dialogue state tracker. (A) provides an overview of dialogue response generation process. Each arrow represents a \emph{copyflow}(see ~\ref{subsec:copynet}). (B) provides details of the t-th dialogue turn. (C) represents the knowledge base interaction for task-oriented dialogues. ``Parking garage'' is the constraint for knowledge base search in the example. Ellipses are the input and output tokens and rectangles denote neural hidden vectors.} \label{fig:overview} \end{figure*} In this section, we propose our semi-supervised explicit dialogue state tracker, abbreviated as \textbf{SEDST}. We start by providing an overview of SEDST. We then describe the CopyFlowNet architecture and detail our posterior regularization for optimizing the model training. \subsection{Overview} We propose the \emph{semi-supervised explicit state tracker} (\textbf{SEDST}) to track dialogue states with explicit text spans under no or few data annotation setup. SEDST includes two main ingredients: (1) CopyFlowNet; (2) posterior regularization. Along with SEDST, we propose an encoder-decoder architecture, \emph{CopyFlowNet}, to generate explicit state spans by copying from existing sequences on top of normal generation process. Finally, we provide an optimized training procedure of SEDST, where we apply a posterior regularization strategy to improve the robustness of our model. Figure~\ref{fig:overview} provides an overview for state tracking and response generation process in SEDST. The turn-level overview presents how the text span is utilized for state tracking for multi-turn dialogues, where each arrow represents a \emph{copyflow}(see \ref{subsec:copynet}). The sentence level illustration presents encoding and decoding procedure. We also illustrate how the knowledge-base interaction is performed with state spans for task-oriented dialogues, where we follow~\cite{sequicity}. \subsection{CopyFlowNet} \label{subsec:copynet} In this section we detail the \emph{CopyFlowNet} architecture. At $t$-th dialogue turn, for simplicity we set the length of $U_t$ and $R_{t-1}$ to $N$; CopyFlowNet first encodes the concatenation of previous response $R_{t-1}$ and current user utterance $U_t$ (i.e., $R_{t-1}U_t=w_{x_1},w_{x_2},...,w_{x_{2N}}$) with gated recurrent unit (GRU) encoders~\cite{chung2014empirical}: \begin{equation} \label{encoder} \mathbf{h}^{(x)}_1,\mathbf{h}^{(x)}_2,...,\mathbf{h}^{(x)}_{2N}=GRU(\mathbf{w}_{x_1},\mathbf{w}_{x_2},...,\mathbf{w}_{x_{2N}}), \end{equation} \noindent At $t$-th turn, each token in $S_t$ and $R_t$ is decoded with both probability of direct generation and that of copying from a previous sequence. We employ an attention decoder~\cite{bahdanau2015neural} to calculate the generation probability of $S_t$ and $R_t$ individually. When decoding an output $Y \in \left\{ {S_t,R_t} \right\}$ at $t$-th turn, the decoder attends back to hidden states $\mathbf{h}^{(x)}$ of the input $X$ to compute attention vectors. We calculate attention vectors with $R_{t-1}U_t$ when generating $S_t$, and concatenate $S_t$ to $R_{t-1}U_t$ when generating $R_t$. For the generation of the $j$-th word in $Y$, $y_j$, we calculate its attention score $a_{ij}$ as follows~\footnote{We also tried dot-product attention and got similar experimental results.}: \vspace*{-.4\baselineskip} \begin{equation} \label{attn1} a_{ij}=softmax(\mathbf{v_1}^Ttanh(\mathbf{W}_1{\mathbf{h}^{(x)}_i}+\mathbf{W}_2{\mathbf{h}^{(y)}_{j-1}})) \end{equation} \noindent where ${\mathbf{h}^{(x)}_i}$ and ${\mathbf{h}^{(y)}_{j-1}}$ indicate a hidden state of $i$-th word in $X$ and a hidden state of $j-1$-th word in $Y$, respectively. $\mathbf{v}_1$, $\mathbf{W}_1$ and $\mathbf{W}_2$ are learnable parameters. Given $a_{ij}$, the decoder then generates a hidden representation $\mathbf{h}^{(y)}_j$ of the $j$-th word using GRU: \begin{flalign} \label{attnsum} \begin{split} & {\tilde{\mathbf{h}}^{(x)}}_j=\sum_{i} a_{ij}{\mathbf{h}^{(x)}_i}, \\ & h_j^{(y)}=GRU(w_{y_{j-1}}, h_{j-1}^{(y)},\tilde{\mathbf{h}}^{(x)}), \end{split} \end{flalign} \noindent where $\tilde{\mathbf{h}}^{(x)}$ refers to an attention vector by summing up all ${\mathbf{h}^{(x)}_i}$, and $w_{y_{j-1}}$ indicates the $j-1$ word in $Y$. Thereafter, we get the generation probability distribution $\mathbf{p}_j^g$ for the $j$-th output word: \begin{equation} \label{attnproj} \mathbf{p}_j^g=\frac{1}{Z}e^{({\mathbf{W_3}\mathbf{h}^{(y)}_j})}, \end{equation} \noindent where $Z$ is a shared normalization term and $\mathbf{W_3}$ is a learnable parameter. $\mathbf{p}_j^g$ can be considered as the normalized projection of $\mathbf{h}^{(y)}_j$ at the output space. We employ copyNets ~\cite{gu2016incorporating} to compute the probability of copying words from a deterministic input $X$ when decoding $y_j$. We denote the probability as $p^{c(X)}(y_j)$, and the aggregated probability distribution as $\mathbf{p}_j^{c(X)}$. This probability of generating an word output $y_j$ by copying from $X$ is calculated as: \begin{equation} p^{c(X)}(y_j)= \begin{cases} \frac{1}{Z} \sum_{i:w_{x_i}=y_j} e^{\psi(w_{x_i})} , y_j \in X \, \\ 0, otherwise \end{cases} \end{equation} \noindent where $Z$ is a shared normalization term. $\psi(x_i)$ is the weight of copying the $i$-th word in $X$, calculated in Eq.~\ref{eq:psi}: \begin{equation} \label{eq:psi} \psi(y_j=w_{x_i})=\mathbf{v_2}^T tanh(\mathbf{W_4}{\mathbf{h}^{(x)}_i}+\mathbf{W_5}{\mathbf{h}^{(y)}_j}), \end{equation} \noindent where $\mathbf{v}_2$, $\mathbf{W_4}$ and $\mathbf{W_5}$ are learnable parameters. Since $S_{t}$ could be unlabeled, we may have to copy from a nondeterministic model-generated distribution. Also to enable multiple-step copying along dialogue turns, we propose \emph{implicit copyNets} to copy words with high confidence from a sequence of nondeterministic word distribution. The copying probability is calculated as: \begin{equation} p^{c(X)}(y_j) =\frac{1}{Z} \sum_{i=1}^{|X|} p_i(w_{x_i}=y_j) e^{\psi(w_{x_i})}, \end{equation} \noindent where $p_i(w_{x_i}=y_j)$ is the probability that the $i$-th word in the nondeterministic input $X$ equals $y_j$. Note that in cases where the source sequence is deterministic such as $U_{t}$, $p_i(w_{x_i}=y_j)$ degenerates to a binary indicator where $p_i(w_{x_i})=1$ if $w_{x_i} = y_j$. At such situation, implicit CopyNets are equivalent to original copyNets. Eventually, we demonstrate organization details of CopyFlowNet. A \emph{copy flow} from $X$ to $Y$ refers to a procedure involving copying probability from $X$ at the generation of $Y$. Specifically, at a single turn $t$ in our model, there are copy flows from $R_{t-1}U_t$ to $S_t$ and from $S_t$ to $R_t$; there is another copy flow from $S_{t-1}$ to $S_t$ in adjacent dialogue turns. The name of \emph{copyflows} is illuminated by the phenomenon that the information flow of $S_1,S_2,...,S_t$ relay along the dialogue turns by copying and finally attend to the generation of $R_t$. Formally, the probability distribution of the $j$-th word in $S_t$ and $R_t$ are calculated as: \begin{flalign} \label{copyflowformula} \begin{split} & \mathbf{p}_j(S_t) = \begin{cases} \mathbf{p}_j^g(S_t) + \mathbf{p}_j^{c(S_{t-1})}(S_t) + \mathbf{p}_j^{c(R_{t-1}U_t)}(S_t) , t>0 \\ \mathbf{p}_j^g(S_t) + \mathbf{p}_j^{c(R_{t-1}U_t)}(S_t) , t=0 \end{cases} \\ & \mathbf{p}_j(R_t) = \mathbf{p}_j^g(R_t) + \mathbf{p}_j^{c(S_t)}(R_t). \end{split} \end{flalign} Every {copy flow} has an intuitive explanation. {Copy flows} from $R_{t-1}U_t$ to the state span $S_t$ and from $S_t$ to the response $R_t$ enable the model to cache ``keywords'' in $S_t$, and then copy them again to the final response $R_t$. It is inspired from the observation that the keywords indicating dialogue states are prone to co-occur among user inputs and system responses. Given an example dialogue turn: \begin{itemize} \item User: I want to book a French restaurant. \item Model: C\^{o}te Brasserie is a French restaurant with good reputation. \end{itemize} \noindent The word ``French'' is the key word between the utterances which should be copied from $U_t$ to $S_t$ and then be copied to $R_t$. The model can also generate new words from the full vocabulary with normal generation process at $S_t$ for further copying to $R_t$. Note that all these actions can be learned even in unsupervised settings. Besides, the {copy flow} from the previous state span $S_{t-1}$ to current state span $S_t$ encourages useful dialogue states to be passed through dialogue turns, which intrinsically provides a solution for long-term dependency, as well as enables copying-mechanism to learn information from co-occurrence of keywords across different dialogue turns. \subsection{Posterior regularization} \label{sectionPR} Due to the scarcity of supervised signal in state span $S_t$, the training of the state span could be unstable, especially when $S_t$ is not annotated. To tackle this problem, we apply posterior regularization on $S_t$ to train the state tracker more stably. The normal forward pass of the network in the previous discussion parameterized by $\Theta$ actually computes the prior probability distribution of $S_t$: \begin{equation} P_\Theta(S_t|R_{t-1},S_{t-1},U_t)=\Pi_i \mathbf{p}(s^{(i)}_t|s^{(<i)}_t,R_{t-1},S_{t-1},U_t), \end{equation} We then build another network, the posterior network, which learns the posterior distribution of $S_{t}$ with more informative inputs. It adopts the same structure but it is separately parameterized~\footnote{The response decoder is shared between two networks in semi-supervised learning senarios.} with $\Phi$. It takes $R_{t-1}$, $S_{t-1}$, $U_{t}$, and $R_{t}$ as input, and calculates the posterior distribution of $S_t$ as follows: \begin{equation} Q_\Phi(S_t|S_{t-1},R_{t-1},U_t,R_t) = \Pi_i \mathbf{q}(s^{(i)}_t|s^{(<i)}_t,R_{t-1},S_{t-1},U_t,R_t), \end{equation} where $R_{t}$ is concatenated to the input at the encoder. Note that only the prior network works during testing time, while the the posterior network only directs the prior network in training. The idea of posterior regularization is to force the prior distribution $P$ to approximate the posterior distribution $Q$ learned from more informative inputs. We utilize KL-divergence to regularize these two distributions. Given multinomial distributions $\mathbf{p}_i$ and $\mathbf{q}_i$ over the vocabulary space, the KL-divergence from $\mathbf{p}_i$ to $\mathbf{q}_i$ is calculated as follows: \begin{equation} \label{eq:klpq} KL(\mathbf{q}_i||\mathbf{p}_i) = \sum^{|\mathcal{V}|}_l q^{(l)}_i log(\frac{q^{(l)}_i}{p^{(l)}_i}), \end{equation} The training process of the model varies according to the amount of labeled data. In supervised or semi-supervised learning, we maximize the joint log-likelihood~\cite{wen2017latent} for response and state span generation along with posterior regularization. The learning objective thus comprises three sub-objectives. \begin{equation} \begin{aligned} & \mathcal{L}_1=-\sum^{\mathcal{A}\cup \mathcal{U}}log[P(R_t|R_{t-1}, U_t, S_t)] \\&- \sum^{\mathcal{A}} log[P_{\Theta}(S_t|R_{t-1},U_t,S_{t-1})Q_{\Phi}(S_t|R_{t-1},U_{t}, S_{t-1}, R_t)] \\&+\lambda \sum^{\mathcal{U}} \sum^{N}_{i=1} KL(\mathbf{q}_i||\mathbf{p}_i)\, , \end{aligned} \end{equation} where $\mathcal{A}$ and $\mathcal{U}$ denote annotated and unannotated training instances respectively. $N$ is the length of the state span. However, maximum likelihood estimation on the distribution $Q_{\Phi}(S_t|S_{t-1}, R_{t-1},U_{t}, R_t)$ can not be applied when $S_t$ is completely unannotated. We therefore indirectly train the posterior distribution $Q_\Phi(\hat{S}_t|S_{t-1},R_{t-1},U_t,R_t)$ with different generation objectives at the decoder of the posterior network. In detail, we feed $R_{t-1}$, $U_{t}$, $R_{t}$ at its encoder and train the model to reconstruct them at its decoder. The posterior network thereby learns to cache most informative words in both contexts and responses at $\hat{S}_t$ via a structure of auto-encoders. The prior distribution $P_\Theta(S_t|R_{t-1},S_{t-1},U_t)$ is regularized towards this posterior distribution with KL-divergence, and the learning objective can be written as \vspace*{-.5\baselineskip} \begin{equation} \label{unsuploss} \begin{aligned} \mathcal{L}_2&=-\sum^{\mathcal{U}} log[P(R_t|R_{t-1}, U_t, S_t)] \\&- \sum^{\mathcal{U}} log[Q_{\Phi}(R_{t-1},U_{t},R_{t}| \hat{S}_t)] \\&+\lambda \sum^{\mathcal{U}} \sum^{N}_{i=1} KL(\mathbf{q}_i||\mathbf{p}_i)\, . \end{aligned} \end{equation} \noindent which can be interpreted as response generation loss, reconstruction loss and regularization loss respectively . Following~\cite{higgins2016beta}, we employ a factor $\lambda$ as a trade-off factor. See~\S\ref{subsec:exp:training} for more details. \section{Experimental Setup} \label{section5} \subsection{Research questions} We list the research questions that guide the remainder of the paper: (1) \textbf{RQ1}: what is the overall performance of SEDST in task-oriented neural dialogue generation? (See \S\ref{sec61}) (2) \textbf{RQ2}: How much does unlabeled data help dialogue state tracking in task-oriented dialogues in our model? (See \S\ref{sec61}.) (2) \textbf{RQ3}: Is our explicit state tracker helpful in response generation in non-task-oriented dialogues? (See \S\ref{sec62}) (4) \textbf{RQ4}: Does posterior regularization improve the model performance? (See \S\ref{sec63}) (5) \textbf{RQ5}: Can our dialogue state tracker generate explainable and representative words? Can it tackle the long-term dependency in a dialogue generation? (See \S\ref{sec64}) \smallskip\noindent \noindent Next, we introduce the datasets in \S \ref{subsec:exp:dataset}. The baselines are listed in \S \ref{subsec:exp:baselines} and evaluation methods are depicted in \S \ref{subsec:exp:eval}. Details of the training setting are described in \S \ref{subsec:exp:training}. \subsection{Datasets} \label{subsec:exp:dataset} In order to answer our research questions, we work with two task-oriented dialogue corpora: {Cambridge Restaurant Corpus} and {Stanford In-Car Personal Assistant Corpus}; two non-task-oriented dialogue corpora: {Ubuntu Technical Corpus} and {JD.com Customer Service Corpus}. Details of our datasets are described as follows: \paratitle{Cambridge Restaurant Corpus} Cambridge Restaurant corpus is used to design a dialogue system to assist users to find a restaurant in the Cambridge, UK area ~\cite{wen-EtAl:2017:EACLlong}. Customers can use three informable slots (\textit{food, pricerange, area}) to constrain the search. This dataset contains $99$ restaurants, and $676$ clean dialogues out of $1500$ dialogue turns. There are $99$ possible informable slot values. We split the corpus by 3:1:1 as training, validation and test sets. \paratitle{Stanford In-Car Personal Assistant Corpus} The Stanford driver and car assistant corpus is a multi-turn multi-domain task-oriented dialogue dataset\footnote{https://nlp.stanford.edu/blog/a-new-multi-turn-multi-domain-task-oriented-dialogue-dataset/}. This dataset includes three distinct domains: calendar scheduling, weather information retrieval, and point-of-interest navigation. There are two modes, namely \textit{Driver} and \textit{Car Assistant}. There are $284$ informable slot values for state tracking. Each dialogue is associated with a separate knowledge base (KB) with about $7$ entries. The corpus contains $2425$ ,$302$, $302$ dialogues for training, validation and testing. \paratitle{Ubuntu Technical Corpus} Ubuntu Dialogue Corpus \cite{ubuntu} is an English multi-turn dialogue corpus containing about $487337$ dialogues extracted from the Ubuntu Internet Relayed Chat channel. A conversation begins with an Ubuntu-related technical problem, and follows by the responses to the questions. The corpus consists of $448833$, $19584$, $18920$ dialogues of training, validation, testing, respectively. Though the corpus is domain specific, the task and slot-values are not explicitly specified. \paratitle{JD.com Customer Service Corpus} JD.com customer service corpus~\cite{chen18www} is a large real-world dataset for online shopping after-sale service. The conversation is between a customer and a customer service staff. It contains $415,000$ dialogues for training, $1,5000$ dialogues for validation, and $5,005$ for testing. We exclude template dialogue turns that the staff or customers merely thanks with keyword filtering. \begin{table*}[t] \caption{RQ1\&RQ2\&RQ4: Performance on Cambridge Restaurant corpus. N/A indicates the model fails to produce valid result on this dataset. Best performance is marked bold for each supervision proportion} \centering \begin{tabular}{c|c|c|c|c} \hline &\textbf{Supervision Proportion} & \textbf{BLEU} &\textbf{Joint Goal Accuracy} &\textbf{Entity Match Rate}\\ \hline \hline \multirow{3}{*}{\emph{SEDST}} &0\% &\textbf{0.201} &\textbf{0.684} &\textbf{0.649}\\ &25\% &\textbf{0.225} &\textbf{0.867} &\textbf{0.858}\\ &50\% &\textbf{0.236} &\textbf{0.945} &\textbf{0.927}\\ \hline \multirow{3}{*}{\emph{SEDST$\backslash$PR}} & 0\% &0.199 &0.679 &0.422\\ & 25\% &0.213 &0.854 &0.848\\ & 50\% &0.192 &0.911 &0.901\\ \hline \multirow{3}{*}{\emph{SEDST(without unlabeled data)}} &0\% &- &- &-\\ &25\% &0.091 &0.827 &0.807 \\ &50\% &0.122 &0.896 &0.899\\ \hline \emph{SEDST(fully supervised)} &100\% &\textbf{0.244} &\textbf{0.962} &\textbf{0.955}\\ \hline \emph{NDM} & 100\% & 0.239 & 0.921 & 0.902 \\ \hline \emph{Neural Belief Tracker} & 100\% & - & 0.865 & - \\ \hline \emph{KVRN} & 100\% & 0.134 & - & N/A \\ \hline \end{tabular} \label{tab:mainre:camrest} \end{table*} \begin{table*}[t] \caption{RQ1\&RQ2\&RQ4: Performance on Stanford In-Car Personal Assistant Corpus. Best performance is marked bold for each supervision proportion} \centering \begin{tabular}{c|c|c|c|c} \hline &\textbf{Supervision Proportion} & \textbf{BLEU} &\textbf{Joint Goal Accuracy} &\textbf{Entity Match Rate}\\ \hline \hline \multirow{3}{*}{\emph{SEDST}} &0\% &\textbf{0.202} &\textbf{0.635} &\textbf{0.642}\\ &25\% &\textbf{0.192} &\textbf{0.758} &\textbf{0.813}\\ &50\% &\textbf{0.195} &\textbf{0.796} &\textbf{0.833}\\ \hline \multirow{3}{*}{\emph{SEDST$\backslash$PR}} & 0\% &0.193 &0.622 &0.564\\ & 25\% &0.180 &0.726 &0.770\\ & 50\% &0.178 &\textbf{0.796} &0.812\\ \hline \multirow{3}{*}{\emph{SEDST(without unlabeled data)}} &0\% & - & - & - \\ &25\% &0.102 &0.727 &0.751\\ &50\% &0.156 &0.772 &0.773\\ \hline \emph{SEDST(fully supervised)} & 100\% & \textbf{0.193} & \textbf{0.829} & \textbf{0.845} \\ \hline \emph{NDM} & 100\% & 0.186 & 0.750 & 0.716 \\ \hline \emph{Neural Belief Tracker} & 100\% & - & 0.756 & - \\ \hline \emph{KVRN} & 100\% & 0.172 & - & 0.459 \\ \hline \end{tabular} \label{tab:mainre:kvret} \end{table*} \subsection{Baselines and comparisons} \label{subsec:exp:baselines} We list the methods and baselines below. We write \textbf{SEDST} for the overall process as described in~\S\ref{section4}, which includes posterior regularization. We write \textbf{SEDST$\backslash$PR} for the model that skips the posterior regularization process. To assess the contribution of our proposed methods, our baselines include recent work on both task-oriented dialogue models and non-task-oriented dialogue models. We adopt the following baselines for task-oriented dialogue generation under fully supervision. \begin{itemize} \item \textbf{NDM}: Network based Dialogue Models \cite{wen-EtAl:2017:EACLlong} with a CNN-RNN dialogue state tracker \item \textbf{NBT}: Neural Belief Tracker \cite{mrkvsic2016neural} with a CNN feature extractor. \item \textbf{KVRN}: Key-value retrieval dialogue model \cite{eric2017key}, which does not adopt a dialogue state tracker but directly retrieves an entry from a key-value structured knowledge base with attention mechanism, and decodes a special token in <subject, relation, object> form during response generation. \end{itemize} We utilize the following representative baselines for non-task-oriented dialogue generation: \begin{itemize} \item \textbf{SEQ2SEQ}: sequence-to-sequence model, also known as recurrent encoder-decoder model \cite{shang,vinyals2015neural}. \item \textbf{HRED}: hierarchical recurrent encoder-decoder model.\cite{Sordoni2015hre} \item \textbf{VHRED}: latent variable hierarchical recurrent encoder-decoder model. \cite{hvred}. \item \textbf{HVMN}: hierarchical variational memory network. ~\cite{chen18www} \item \textbf{DAWnet}: deep and wide neural network for dialogue generation. It first generates keywords that deepen or widen topics before response generation. Ground truth of keywords are obtained with rules and unsupervised methods~\cite{dawnet} \end{itemize} \subsection{Evaluation metrics} \label{subsec:exp:eval} \paratitle{Task-oriented dialogue evaluation} To assess the language quality and the state tracking ability for the task-oriented dialogue generation, we employ \textbf{BLEU}~\cite{Papineni2002BLEU}, a word-overlapping based metric for language quality evaluation, to measure performance. To measure the state tracker performance, we employ \textbf{Joint Goal Accuracy}~\cite{mrkvsic2016neural} as our turn-level evaluation metric. Joint goal accuracy calculates the proportion of the dialogue turns where all the constraints are captured correctly, excluding those where the user merely thanks without extra information. However, this metric is not applicable for task-oriented dialogue systems without a separate state tracker, such as KVRN. Thus we employ \textbf{Entity Match Rate}~\cite{wen-EtAl:2017:EACLlong}, as an evaluation metric. Entity Match Rate calculates the proportion of the dialogues where all the constraints are correctly identified when the last placeholder (e.g., poi\_SLOT) appears. We skip dialogues without a single placeholder in ground-truth responses; we consider dialogues as failures if no placeholder is decoded for remaining dialogues. \paratitle{Non-task oriented dialogue evaluation} Evaluating dialogue systems in such a large corpus is not a trivial task. \citet{Liu2016How} showed that word-overlap automatic metrics like \textbf{BLEU}~\cite{Papineni2002BLEU} or \textbf{ROUGE}~\cite{rouge2004} are not well correlated with human evaluations regarding response quality. To evaluate the semantic relevance between the candidate response and target response, we employ three embedding-based topic similarity metrics proposed by \citet{Liu2016How}: \textbf{Embedding Average}, \textbf{Embedding Extrema} and \textbf{Embedding Greedy}~\cite{mitchell2008,forgues2014bootstrapping,rus2012comparison}. We employ publicly available \emph{word2vec}\footnote{https://code.google.com/archive/p/word2vec/} to train word embeddings for evaluation. We train English word embeddings on Google News Corpus. For Chinese, the word embeddings are trained on Chinese Giga-word corpus version 5~\cite{graff2005chinese}, segmented by \emph{zpar}\footnote{https://github.com/SUTDNLP/ZPar} ~\cite{zhang2011syntactic}. \subsection{Experimental settings} \label{subsec:exp:training} On Cambridge Restaurant corpus and Stanford In-Car Personal Assistant corpus, we trained the model with Adam~\cite{Kingma2015Adam} optimizer with a learning rate of 0.003 with early stopping. The batch-size was set to 32, and the size of the word embedding was set to 50. We used a single-layer GRU with 50 hidden units. The trade-off factor $\lambda$ was set to 0.1. For non-task-oriented dialogue models on Ubuntu Dialogue Corpus and JD.com Customer Service Corpus, we trained the model with Adam~\cite{Kingma2015Adam} optimizer, under a learning rate of 0.0005 with early stopping. The batch size was set to 24 and the size of the word embedding was set to 300. We used a single-layer GRU with 500 hidden units for these models. The trade-off factor $\lambda$ was set to 0.1 at the beginning, and uniformly decrease to 0.001 within the first epoch. We loaded pretrained fastText~\cite{bojanowski2017enriching} word vectors for all the models, and the vocabulary size on these datasets was limited to 800, 1400, 20000, and 20000, respectively. For response generation, we applied beam search decoding with a beam size of 5. As for dialogue state decoding in semi-supervised or fully-supervised scenario, we performed max-sampling on $\mathbf{p}_i$ to generate word sequences in state tracker with a special token indicating sequence termination. However, in unsupervised scenario, it is impossible for model to generate end-of-sequence tokens. Thus, our state decoder generated a sequence by a fixed time step of $T_s$ during decoding in unsupervised setting. In our experiments, $T_s$ was set to 5 on Ubuntu Technical Dialogue Corpus and 8 for all other corpora. We prevent generation of repeated words in the state span during sampling. During the evaluation of unsupervised dialogue state trackers on task-oriented corpora, we calculated the intersection of the output of state decoders and all possible slot values provided separately in the corpus. This setup is same as baselines where dialogue states are limited to a fix-sized set. \section{Experimental Results} \label{section6} In \S\ref{sec61}, we compare our methods to baselines for task-oriented dialogue generation; in \S\ref{sec62} we examine the performance of comparisons for non-task-oriented dialogue generation; \S\ref{sec63} examines the effect of posterior regularization. We discuss the explainability and representativeness of dialogue state tracking in \S\ref{sec64}. \subsection{Task-oriented dialogue systems} \label{sec61} To start, we address research question \textbf{RQ1} for task-oriented dialogue systems. Table~\ref{tab:mainre:camrest} and Table~\ref{tab:mainre:kvret} list the performance of all methods on two task-oriented dialogue corpora respectively. For all two datasets, under fully supervised settings, SEDST outperforms other baselines and achieves state-of-the-art performance. On Cambridge corpus, SEDST with fully supervision achieves a $2.09\%$, $4.45\%$, and $5.87\%$ over NDM in terms of BLEU, joint goal accuracy, and entity math rate, respectively; whereas on Stanford corpus, it achieves a $3.76\%$, $10.5\%$, and $18.0\%$, respectively. To address research question \textbf{RQ2}, we analyze the performance of our models in semi-supervised settings where only part of labeled data is available. We find that SEDST outperforms SEDST trained without unlabeled data in both corpora on all corpora. In details, when only 25\% of data is labeled, in terms of joint goal accuracy, SEDST offers a 4.0\% and 5.1\% increase on two corpora respectively; whereas it gives 3.1\% and 6.2\% increase in terms of entity match rate. When only 50\% of data is labeled, its increase become 4.9\%, 2.8\% and 2.4\%, 6.0\% respectively. It verifies that our model is capable to utilize unlabeled data well for training dialogue state trackers. Moreover, we find our model outperforms state-of-the-art baselines on two corpora for both state tracking ability and language quality when only 50\% of labeled data is available. We notice that SEDST provides fairly satisfying results even if the state tracker is trained in a complete unsupervised manner. In terms of joint goal accuracy, SEDST achieves 68.4\% and 63.5\% on two corpora respectively; whereas entity match rate performance becomes 64.9\% and 64.2\%. \vspace*{-.\baselineskip} \subsection{Non-task oriented dialogue systems} \label{sec62} Next, we turn to \textbf{RQ3}. From table~\ref{tab:metricub} and table~\ref{tab:metricjd}, We find $SEDST$ produces quite competitive results against state-of-the-art non-task-oriented dialogue models. Quite notably, on all corpora SEDST outperforms VHRED and HVMN, which uses continuous latent variables to maintain dialogue states. In addition, our state tracker produces explicit dialogue states in state trackers. We notice that the entities mentioned between context and generated responses are highly relevant, which effectively tackles a key challenge in neural dialogue generation. Table~\ref{case:nontask} provides examples of state tracker outputs and generated responses. \vspace*{-.5\baselineskip} \subsection{Effect of posterior regularization} \label{sec63} Turning to \textbf{RQ4}, shown in Table~\ref{tab:mainre:camrest} and Table~\ref{tab:mainre:kvret}, we find that our posterior regularization improves overall state tracking performance from the comparison between SEDST and SEDST$\backslash$PR. On Cambridge corpus, when only 25\% labeled data is available, SEDST offers a 1.3\% and 1.0\% increase over SEDST$\backslash$PR in terms of joint goal accuracy and entity match rate respectively; while it gives a 3.4\%, 2.6\% increase when 50\% labeled data is available. For Stanford corpus, we see a similar picture. It also improves response quality, as shown in Table~\ref{tab:metricub} and Table~\ref{tab:metricjd}. Here we discuss the effect of posterior regularization. In terms of state tracking in task-oriented dialogues, we train the posterior network with more informative input by including current turn response $R_t$; then we optimize the prior network by minimizing the distance of posterior and prior distributions (Eq.~\ref{eq:klpq}). Accordingly, SEDST performs better than SEDST$\backslash$PR when fewer labeled data is available. Posterior regularization also helps the response generation with unlabeled dialogues states. Although the prior network can explore a generation strategy of $S_t$, $S_t$ is also regularized towards the compressed representation of context and responses learned by the posterior network. The representation which we regularize towards is a probability distribution over the vocabulary space learned by auto-encoders. We notice a state-of-the-art work, DAWnet~\cite{dawnet}, \if0 that \fi extracts \if0 handful of \fi keywords with rules and unsupervised methods from unlabeled data. Key word prediction is then trained with supervised methods with maximum likely hood estimation objective in the neural network. However, posterior regularization is a generalization of the learning strategy of DAWnet~\cite{dawnet}. When the $i$-th word over the vocabulary is treated as the ground truth of the keyword, the objective of maximum likelihood estimation is equivalent to minimizing the KL-divergence between the prior distribution $\mathbf{p}$ and an one-hot distribution $\mathbf{\hat{q}}$, since we have: \vspace*{-.5\baselineskip} \begin{equation} log(p_i) = -KL(\mathbf{\hat{q}}||\mathbf{p}). \end{equation} \noindent where $\mathbf{\hat{q}}$ is a multinomial distribution with $\mathbf{\hat{q}_{i}}=1$ at its $i$-th coordinate. However, unlike DAWnet, posterior regularization provides probability distributions over the whole vocabulary space as learning signals, which are more informative than a handful of keywords and immune to extraction bias from rules. Moreover, our model is fully end-to-end trainable. We notice that the text spans in DAWnet are trained on \emph{predicted keywords}~\cite{dawnet}, which are defined as the keywords that appear in ground truth responses but not appear in contexts. As an empirical study of the contribution of $S_t$, in Table~\ref{tab:kw} we present the proportion of generated \emph{predicted keywords} that \if0actually\fi exist in ground truth responses. In contrast with DAWnet, SEDST gives an obviously larger proportion of correct \emph{predicted keywords} for both corpora. \begin{table}[!t] \caption{RQ3: Embedding-based evaluation in Ubuntu Technical Corpus. Emb. is an abbreviation for Embedding} \centering \begin{tabular}{c|c|c|c} \hline \textbf{Model} & \textbf{Emb. Average} & \textbf{Emb. Greedy} & \textbf{Emb. Extrema}\\ \hline \hline SEQ2SEQ & 0.216 & 0.169 & 0.126 \\ HRED & 0.542 & 0.412 & 0.319 \\ VHRED & 0.534 & 0.403 & 0.306 \\ HVMN & 0.558 & 0.423 & 0.322 \\ DAWnet & 0.530 & 0.390 & 0.333 \\ \hline SEDST$\backslash$PR & 0.586 & 0.438 & 0.330 \\ SEDST & \textbf{0.609} &\textbf{0.451} &\textbf{0.337} \\ \hline \end{tabular} \label{tab:metricub} \vspace{-1.0em} \end{table} \begin{table}[!t] \caption{RQ3: Embedding-based evaluation in JD Corpus. Emb. is an abbreviation for Embedding} \centering \begin{tabular}{c|c|c|c} \hline \textbf{Model} & \textbf{Emb. Average} & \textbf{Emb. Greedy} & \textbf{Emb. Extrema}\\ \hline \hline SEQ2SEQ & 0.425 & 0.479 & 0.264 \\ HRED & 0.549 & 0.587 & \textbf{0.406} \\ VHRED & 0.576 & 0.593 & 0.392 \\ HVMN & 0.564 & 0.596 & 0.405 \\ DAWnet & 0.579 & 0.574 & 0.375 \\ \hline SEDST$\backslash$PR & 0.575 & 0.602 & 0.373 \\ SEDST & \textbf{0.585} & \textbf{0.607} & 0.392 \\ \hline \end{tabular} \label{tab:metricjd} \vspace{-1.0em} \end{table} \subsection{Case study} \label{sec64} Finally, we address \textbf{RQ5}. In Table~\ref{case:task} and \ref{case:nontask} we provide example dialogues in task-oriented dialogue corpus and non-task-oriented dialogue corpus under unsupervised training. We see our model successfully captures informative words indicating dialogue states without any supervision. Especially in examples from the Ubuntu corpus, our state tracker generates explainable and representative words of dialogue process rather than generic words like ``the'' or ``is'', which co-occurs much more often in the whole corpus. Some important words are passed through dialogue turns, indicating that explicit tracking of dialogue states with copying mechanism is effective for tackling long-term dependency. The representative words are also addressed as \emph{topic continuity}~\cite{Lei2018} between turns. \begin{table}[t] \caption{RQ4: Proportion of generated \emph{predicted keywords}~\cite{dawnet} existing in ground truth responses.} \centering \begin{tabular}{c|c|c} \hline \textbf{Model} & \textbf{Ubuntu Technical} & \textbf{Jd.com Customer Service} \\ \hline \hline DAWnet & 5.5\% & 32.6\% \\ \hline SEDST & 14.7\% & 40.6\% \\ \hline \end{tabular} \label{tab:kw} \vspace{-1.0em} \end{table} \vspace*{-.3\baselineskip} \begin{table*}[!t] \caption{Examples task-oriented dialogues in unsupervised training on Standford In-Car Assistant Corpus and Cambridge Restaurant Corpus} \centering \tiny \begin{tabular}{m{4cm}|m{6cm}|m{6cm}} \hline \textbf{Contexts} &\textbf{Generated} &\textbf{Ground Truth}\\ \hline \multirow{2}{4cm}{i am looking for a german restaurant in the west part of town .} &\textbf{State}: german west & \textbf{State}: west german \\ &\textbf{Generated}: there are no german restaurants in the west part of town . would you like to try something else ? & \textbf{Response}: there are no german restaurants in the west part of town . would you like to make another query ? \\ \hline \multirow{2}{4cm}{how about italian ?} &\textbf{State}: italian west & \textbf{State}: italian west \\ &\textbf{Generated}: name\_SLOT is located in the west part of town . & \textbf{Response}: there are several italian restaurants in the west part of town . name\_SLOT is pricerange\_SLOT and name\_SLOT ispricerange\_SLOT . would you like the address of one of those ? \\ \hline \multirow{2}{4cm}{what is the phone number of one of them ?} &\textbf{State}: italian west & \textbf{State}: italian west \\ &\textbf{Generated}:name\_SLOT is located at address\_SLOT and their phone number is phone\_SLOT . & \textbf{Response}: the phone number to name\_SLOT , which is pricerange\_SLOT priced , is phone\_SLOT . is there anything else i can assist you with today ? \\ \hline \end{tabular} \label{case:task} \end{table*} \begin{table*}[!t] \caption{Examples dialogues on Ubuntu Technical corpus. The words that co-occur between generated dialogue state spans and responses are marked in italic} \centering \tiny \begin{tabular}{m{4cm}|m{6cm}|m{6cm}} \hline \textbf{Contexts} &\textbf{Generated} &\textbf{Ground Truth}\\ \hline \multirow{4}{4cm}{I just realised nothing can access my mysql database anymore , it says cannot connect , why would this be ? I did set it to be remote} &\textbf{State}: remote would anymore mysql access & \textbf{State}: - \\ &\textbf{Response}: you can use the \emph{mysql} client to connect to the server & \textbf{Response}: is it running ? \\ & & \\ & & \\ \hline \multirow{2}{4cm}{is it running ?} &\textbf{State}: running I says mysql access & \textbf{State}: - \\ &\textbf{Response}: yes , \emph{I} am \emph{running} it now & \textbf{Response}: How do \emph{I} check ? \emph{I} was able to type \emph{mysql} commands \\ \hline \multirow{2}{4cm}{How do I check ? I was able to type mysql commands} &\textbf{State}: commands mysql I running How & \textbf{State}: - \\ &\textbf{Response}: you can use sudo & \textbf{Response}: thats not mean your server was \emph{running} check with ps or top or others tool \\ \hline \multirow{2}{4cm}{thats not mean your server was running check with ps or top or others tool} &\textbf{State}: mysql top tool server check& \textbf{State}: - \\ &\textbf{Response}: thanks & \textbf{Response}: How do I \emph{check} if it 's running ? Ah , k \\ \hline \multirow{2}{4cm}{How do I check if it 's running ? Ah , k } &\textbf{State}:mysql check ps server thats & \textbf{State}: - \\ &\textbf{Response}: \emph{ps} aux | grep \emph{mysql} & \textbf{Response}:\emph{ps} aux | grep mysqld \\ \hline \hline \end{tabular} \label{case:nontask} \end{table*} \section{Conclusion} \label{section7} We have addressed the task of explicit dialogue state tracking for both task-oriented and non-task-oriented dialogue generation. We have identified challenges of dialogue state tracking: expensive nature of state labeling and weak explainability. To tackle these challenges, we have proposed a semi-supervised neural dialogue generation framework, named SEDST. Along with SEDST, we have proposed an explicit dialogue state tracking model, CopyFlowNet, including an implicit copyNet mechanism for representing explicit word sequences and a posterior regularization strategy for semi-supervised learning procedure. In our experiments, we have presented a detailed comparison and deep analysis of the performance of SEDST, and have verified its effectiveness in terms of the dialogue generation quality and the dialogue state tracking accuracy on both non-tasked oriented dialogue corpora and task-oriented dialogue corpora. As to future work, we plan to transfer our model to other tasks such as reading comprehension, filtering, and summarization~\cite{Rajpurkar2016SQuAD10,ren2016time,li2018deep}. Also, we would like to apply reinforcement learning to improve the performance of dialogue generation. \bibliographystyle{abbrvnatnourl}
\section{Introduction} Weak decays of heavy mesons play an important role in testing the standard model (SM) precisely and probing new physics effects beyond SM. In SM, the lepton interactions are universal for all three generations. Semileptonic decays of $B$ mesons induced by the $b\to c$ transition have revealed hints lepton flavor non-university~\cite{Li:2018lxi}, which may indicate the presence of possible new physics (NP). To probe the NP effects in a more systematic way, more accurate and solid predictions of branching fractions are highly demanded. Ratios of semitaunic and semimuonic $\bar{B}$ decays into $D$ or $D^*$, i.e. $R_D$ and $R_{D^*}$ have been measured by many experiments such as BABAR~\cite{Lees:2012xj}, Belle~\cite{Huschle:2015rga}, and LHCb~\cite{Aaij:2015yra}. These measurements indicate the data of $R_D$ and $R_{D^*}$ deviate from the SM predictions by about $3\sigma$. Recently, the LHCb collaboration have reported the measurement of the ratio of the semitaunic and semimuonic $B^+_c$ decays into $J/\psi$, i.e. $R_{J/\psi}$, using a sample of proton-proton collision data corresponding to $3.0fb^{-1}$ of integrated luminosity~\cite{Aaij:2017tyk}. A deviation, about $2\sigma$, from SM is found in this measurement by LHCb. On the theoretical side, a few schemes are used to study the $B_c$ decays into a charmonium, such as the perturbative QCD (PQCD) approach~\cite{Du:1988ws,Sun:2008ew,Wen-Fei:2013uea,Rui:2015iia,Rui:2014tpa,Liu:2018kuo,Xiao:2013lia,Rui:2018kqr,Rui:2017pre}, QCD sum rules (QCD SR)~\cite{Colangelo:1992cx,Kiselev:1993ea,Kiselev:1999sc,Azizi:2009ny}, light-cone sum rules (LCSR)~\cite{Huang:2007kb,Wang:2007fs}, quark model (QM)~\cite{Nobes:2000pm,Ebert:2003cn,Ivanov:2005fd,Ebert:2010zu,Hernandez:2006gt,Wang:2011jt,Tran:2018kuv}, light-front quark model (LFQM)~\cite{Wang:2008xt,Wang:2009mi,Ke:2013yka}, nonrelativistic QCD (NRQCD)~\cite{Chang:1992pt,Chang:2001vq,Chang:2001pm,Kiselev:2001zb, Bell:2005gw,Qiao:2011yz,Qiao:2012vt,Qiao:2012hp,Shen:2014msa,Zhu:2017lqu,Zhu:2017lwi} and others~\cite{Hsiao:2016pml}. Uncertainties in some of these schemes are hard to control especially in the nonperturbative region and power corrections are expected important~\cite{Wang:2017jow}. At zero recoil, many of these theoretical investigations become less solid and the extrapolations must be used in order to access the full momentum dependence of form factors. On the lattice, HPQCD collaboration have calculated form factors for decays $B_c$ into the S-wave charmonium in the entire $q^2$ range, using a highly improved lattice quark action~\cite{Colquhoun:2016osw,Lytle:2016ixw}. These works make the analysis of semileptonic $B_c$ decays sitting on a firm ground. In this paper, we will adopt a model-independent way to study the form factors of $B_c$ into the S-wave and P-wave charmonium in the entire phase space. Using the dispersion relation and crossing symmetry, we will give a new parametrization form expanded in a series of polynomials. The coefficients in the expansion can be obtained by fitting the data or the Lattice simulations. At low recoil, the heavy quark limit reduces form factors into a few Isgur-Wise functions, which can also be used to constrain the expansion. In the literature, the unitary constraint has been applied to study $B$ meson decays into light pseudoscalar and vector mesons, the charmed mesons~\cite{Singh:1977et,deRafael:1993ib,Boyd:1994tt,Neubert:1994vy,Boyd:1995cf,Boyd:1995sq,Caprini:1997mu, Bourrely:2008za, Caprini:2017ins,Caprini:2018jjm,Cohen:2018vhw,Huang:2018nnq}. Recently, this approach has been conducted in $B_c$ into the S-wave charmonium Refs.~\cite{zhu2017,Cohen:2018dgz,Murphy:2018sqg,Berns:2018vpl}. We extend this analysis to $B_c$ decays into all S-wave and P-wave charmonium in this work. Other studies on the $R_{J/\psi}$ can be found in Refs.~\cite{Dutta:2017xmj,Dutta:2017wpq,He:2017bft,Wei:2018vmk,Issadykov:2018myx,Davies:2018toj,Watanabe:2017mip}. This paper is scheduled as follows. We give the form factors of $B_c$ decays into charmonia in Sec.~\ref{II}. These form factors will be reduced in heavy quark limit in Sec.~\ref{III}. We investigate the unitary constraints on form factors in Sec.~\ref{IV}. Semitaunic and semimuonic $B_c$ decays into other $S$-wave and $P$-wave charmonia will also be studied and ratios for decay widths will be presented. In the last section, we give a summary of the paper. \section{Form factors\label{II}} Semileptonic decay amplitudes of $B_c$ meson into charmonia are characterized by transition form factors, and for the S-wave charmonia, they are defined as \begin{eqnarray} \langle \eta_{c}(p)\vert J^\mu_V\vert B_{c}(P)\rangle &=&f^{\eta_{c}}_{0}(q^{2}) \frac{m_{B_{c}}^{2}-m_{\eta_{c}}^{2}}{q^{2}}q^{\mu}+f^{\eta_{c}}_{+}(q^{2})(P^{\mu}+p^{\mu}-\frac{m_{B_{c}}^{2}- m_{\eta_{c}}^{2}}{q^{2}}q^{\mu})\,,\label{ff1} \\ \langle J/\psi(p,\varepsilon^{*})\vert J^\mu_V\vert B_{c}(P)\rangle &=&-\frac{2 V^{ J/\psi}(q^{2})}{m_{B_{c}}+m_{J/\psi}}\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\nu}^{*}p_{\rho}P_{\sigma}\,, \\ \langle J/\psi(p,\varepsilon^{*})\vert J^\mu_A\vert B_{c}(P)\rangle & =&-i[2 m_{J/\psi}A^{ J/\psi}_{0}(q^{2})\frac{\varepsilon^{*}\cdot q}{q^{2}}q^{\mu}+(m_{B_{c}}+m_{J/\psi})A^{ J/\psi}_{1}(q^{2}) (\varepsilon^{*\mu}-\frac{\varepsilon^{*}\cdot q}{q^{2}} q^{\mu}) \nonumber\\&&-A^{ J/\psi}_{2}(q^{2})\frac{\varepsilon^{*}\cdot q}{m_{B_{c}}+m_{J/\psi}}( P^{\mu}+p^{\mu}-\frac{m_{B_{c}}^{2}-m_{J/\psi}^{2}}{q^{2}}q^{\mu})] \,, \end{eqnarray} and the form factors of the $B_c$ meson to P-wave charmonia are \begin{eqnarray} \langle h_{c}(p,\varepsilon^{*})\vert J^\mu_V\vert B_{c}(P)\rangle &=&-i[2 m_{h_c}A^{h_c}_{0}(q^{2})\frac{\varepsilon^{*}\cdot q}{q^{2}}q^{\mu} +(m_{B_{c}}+m_{h_c})A^{h_c}_{1}(q^{2}) (\varepsilon^{*\mu}-\frac{\varepsilon^{*}\cdot q}{q^{2}} q^{\mu})\nonumber\\&&~~~~~-A^{h_c}_{2}(q^{2})\frac{\varepsilon^{*}\cdot q}{m_{B_{c}}+m_{h_c}}( P^{\mu}+p^{\mu}-\frac{m_{B_{c}}^{2}-m_{h_c}^{2}}{q^{2}}q^{\mu})]\,, \end{eqnarray} \begin{eqnarray} && \langle h_c(p,\varepsilon^{*})\vert J^\mu_A \vert B_{c}(P)\rangle =\frac{2 V^{h_c}(q^{2})}{m_{B_{c}}+m_{h_c}}\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\nu}^{*}p_{\rho}P_{\sigma}\,, \end{eqnarray} \begin{eqnarray} &&\langle \chi_{c0}(p)\vert J^\mu_A \vert B_{c}(P)\rangle =f^{\chi_{c0}}_{0}(q^{2}) \frac{m_{B_{c}}^{2}-m_{\chi_{c0}}^{2}}{q^{2}}q^{\mu}+f^{\chi_{c0}}_{+}(q^{2})(P^{\mu}+p^{\mu}-\frac{m_{B_{c}}^{2}- m_{\chi_{c0}}^{2}}{q^{2}}q^{\mu})\,,\nonumber\\ \end{eqnarray} \begin{eqnarray} \langle \chi_{c1}(p,\varepsilon^{*})\vert J^\mu_V\vert B_{c}(P)\rangle &=&-i[2 m_{\chi_{c1}}A^{\chi_{c1}}_{0}(q^{2})\frac{\varepsilon^{*}\cdot q}{q^{2}}q^{\mu} +(m_{B_{c}}+m_{\chi_{c1}})A^{\chi_{c1}}_{1}(q^{2}) (\varepsilon^{*\mu}-\frac{\varepsilon^{*}\cdot q}{q^{2}} q^{\mu})\nonumber\\&&-A^{\chi_{c1}}_{2}(q^{2})\frac{\varepsilon^{*}\cdot q}{m_{B_{c}}+m_{\chi_{c1}}}( P^{\mu}+p^{\mu}-\frac{m_{B_{c}}^{2}-m_{\chi_{c1}}^{2}}{q^{2}}q^{\mu})]\,, \end{eqnarray} \begin{eqnarray} && \langle \chi_{c1}(p,\varepsilon^{*})\vert J^\mu_A\vert B_{c}(P)\rangle =\frac{2 V^{\chi_{c1}}(q^{2})}{m_{B_{c}}+m_{\chi_{c1}}}\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\nu}^{*}p_{\rho}P_{\sigma}, \end{eqnarray} \begin{eqnarray} \langle \chi_{c2}(p,\varepsilon^{*})\vert J^\mu_A\vert B_{c}(P)\rangle &=&[2 m_{\chi_{c2}}A^{\chi_{c2}}_{0}(q^{2})\frac{\varepsilon^{*\alpha\beta}q_\beta}{q^{2}}q^{\mu} +(m_{B_{c}}+m_{\chi_{c2}})A^{\chi_{c2}}_{1}(q^{2}) (\varepsilon^{*\mu\alpha}-\frac{\varepsilon^{*\alpha\beta}q_\beta}{q^{2}} q^{\mu})\nonumber\\&&~-A^{\chi_{c2}}_{2}(q^{2})\frac{\varepsilon^{*\alpha\beta} q_\beta}{m_{B_{c}}+m_{\chi_{c2}}}( P^{\mu}+p^{\mu}-\frac{m_{B_{c}}^{2}-m_{\chi_{c2}}^{2}}{q^{2}}q^{\mu}) ]\frac{-i P_{\alpha}}{m_{B_c}}\,, \end{eqnarray} \begin{eqnarray} \langle \chi_{c2}(p,\varepsilon^{*})\vert J^\mu_V\vert B_{c}(P)\rangle &=&\frac{2 V^{\chi_{c2}}(q^{2})}{m_{B_c}(m_{B_{c}}+m_{\chi_{c2}})}\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\nu\alpha}^{*}p_{\rho}P_{\sigma}P_{\alpha}\,.\label{ffchic2} \end{eqnarray} The vector and axial currents are defined as $J^\mu_V=\bar c \gamma^{\mu}b$ and $J^\mu_A=\bar c \gamma^{\mu}\gamma^{5}b$. The momentum transfer is defined as $q=P-p$. If one defines $t_\pm\equiv m_{B_c}^2\pm m_{H}^2$ with the heavy quarkonium mass $m_H$, the kinematics constraint is $0\leq q^2\leq t_-$. \section{heavy quark effective theory\label{III}} The transition form factors at the large recoil with $q^2\simeq 0$ might be calculable in QCD factorization, however, when the $q^2$ approaches the $q^2_{\rm max}=t_-$, the perturbative expansion in $\alpha_s$ becomes less trustworthy. In this kinematics region, the involved degrees of freedoms are either heavy quark or soft gluons, which can be handled in perturbative QCD based on heavy quark effective theory (HQET). In heavy quark limit, the heavy quark spin and flavor symmetries hold, and thus decay constants and form factors are greatly simplified. In this section we will analyze the reduction of form factors in the heavy quark limit. The four velocities of $B_c$ and charmonia $H$ are denoted as $v^\mu=P^\mu/m_{B_c}$ and ${v'}^\mu=p^\mu/m_{H}$, respectively. The parameter $\omega\equiv v\cdot v'$ then becomes $(m_{B_c}^2+m_{H}^2-q^2)/(2m_{B_c}m_{H})$. The physic region for the parameter $ \omega$ is $1\leq\omega\leq (m_{B_c}^2+m_{H}^2)/(2m_{B_c}m_{H})$. The outgoing charm quark in the $b\to c$ transition is at rest when $q^2=t_-$. The spectator charm quark is not involved in the hard scattering in a short time at order of $1/m_W$. It is convenient to investigate the symmetry for the $b\to c$ form factors in the heavy quark limit. The S-wave and P-wave charmonia can be classified into three multiplets. For S-wave charmonia, one has~\cite{Isgur:1990kf,Isgur:1990jg} \begin{align} H_{v'} &=\frac{1+v'\!\!\!\!\slash}{2}[i{\psi}^\beta\gamma_\beta+{\eta_c}\gamma^5]\,.\label{eq:hqet1} \end{align} The P-wave charmonia can be merged into two multiplets by~\cite{Isgur:1990jf,Veseli:1995ep} \begin{align} E_{v'} &=\frac{1+v'\!\!\!\!\slash}{2}[\chi_{c0}+i{h_c}^\beta\gamma_\beta]\,,\\ F^\alpha_{v'} &=i\frac{1+v'\!\!\!\!\slash}{2}\{\chi_{c2}^{\alpha\beta}\gamma_\beta-\sqrt{\frac{3}{2}}\chi_{c1}^\beta\gamma^5[g^\alpha_\beta -\frac{1}{3}\gamma_\beta(\gamma^\alpha-{v'}^\alpha)]\} \,.\label{eq:hqet2} \end{align} Form factors in Eqs.~(\ref{ff1}-\ref{ffchic2}) are parametrized by the QCD currents. In heavy quark limit, the $b\to c$ QCD transition operator can be matched onto the effective current $J^{'\mu}_V=\bar c_{v'} \gamma^{\mu}b_v$ and $J^{'\mu}_A=\bar c_{v'} \gamma^{\mu}\gamma^{5}b_v$, with the matching coefficient calculable in QCD perturbation theory. Then the form factors are parametrized by \begin{align} \langle H^c(v')|\bar{c}_{v'}\Gamma^\mu b_v|B_c(v)\rangle &={\rm Tr}[\xi\bar{H}^{c}_{v'}\Gamma^\mu \bar{H}^b_{v}] \,,\label{eq:trace1} \end{align} where the parameter $\xi$ can be constructed using $v$ and $v'$, and $| H^c(v')\rangle$ can be one of state in Eqs.~(\ref{eq:hqet1}-\ref{eq:hqet2}). The general form for $\xi$ can be written as \begin{eqnarray} \xi=\xi_0+\xi_1 v\!\!\!\slash+\xi_2 v'\!\!\!\!\slash+\xi_3 v\!\!\!\slash v'\!\!\!\!\slash \end{eqnarray} where the $\xi_i(i=0,1,2,3)$ are functions of $\omega$. The relations $v\!\!\!\slash H^b_v=H^b_v$ and $v\!\!\!\!\slash \bar{H}^c_{v'}=-\bar{H}^c_{v'}$ indicate that all these terms are reduced into the first $\xi_i$. Thus one can write Eq.~(\ref{eq:trace1}) as \begin{align} \langle H^c(v')|\bar{c}_{v'}\Gamma^\mu b_v|B_c(v)\rangle &={\rm Tr}[\bar{H}^{c}_{v'}\Gamma^\mu \bar{H}^b_{v}]\xi_0(\omega) \,,\label{eq:trace2} \end{align} where $\xi_0(\omega)=\xi_H(\omega)$ for $B_c$ to S-wave charmonium and $\xi_0(\omega)=\xi_E(\omega),\xi_F(\omega)v_\alpha$ for $B_c$ to P-wave charmonium. At zero recoil with $q^2=t_-$, we have the normalization condition $\xi_{H}(\omega=1)=1$. Evaluating the above trace will lead to the form factors in heavy quark limit: \begin{eqnarray} \langle \eta_{c}(v')\vert \bar{c}_{v'}\gamma^\mu b_v \vert B_{c}(v)\rangle &=&\xi_H(\omega)[v^\mu+{v'}^\mu]\,,\label{ff1-hqet} \\ \langle J/\psi(v',\varepsilon^{*})\vert \bar{c}_{v'}\gamma^\mu b_v \vert B_{c}(v)\rangle &=&-\xi_H(\omega)\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\nu}^{*}{v'}_{\rho}v_{\sigma}\,, \\ \langle J/\psi(v',\varepsilon^{*})\vert \bar{c}_{v'}\gamma^\mu\gamma^5 b_v \vert B_{c}(v)\rangle & =&-i\xi_H(\omega)[(1+\omega) \varepsilon^{*\mu}-\varepsilon^{*}\cdot v {v'}^{\mu}] \,, \end{eqnarray} \begin{eqnarray} \langle h_{c}(v',\varepsilon^{*})\vert \bar{c}_{v'}\gamma^\mu b_v \vert B_{c}(v)\rangle &=&i\xi_E(\omega)[(\omega-1)\varepsilon^{*\mu}-\varepsilon^{*}\cdot v {v'}^{\mu}]\,,\\ \langle h_c(v',\varepsilon^{*})\vert \bar{c}_{v'}\gamma^\mu\gamma^5 b_v \vert B_{c}(v)\rangle & =&\xi_E(\omega)\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\nu}^{*}{v'}_{\rho}v_{\sigma}\,,\\ \langle \chi_{c0}(v')\vert \bar{c}_{v'}\gamma^\mu \gamma^5 b_v \vert B_{c}(v)\rangle &=&-\xi_E(\omega)[v^\mu-{v'}^\mu]\,, \end{eqnarray} \begin{eqnarray} \langle \chi_{c1}(v',\varepsilon^{*})\vert \bar{c}_{v'}\gamma^\mu b_v\vert B_{c}(v)\rangle &=&\frac{i\xi_F(\omega)}{\sqrt{6}}[(\omega^2-1)\varepsilon^{*\mu}-\varepsilon^{*}\cdot v (3v^\mu-(\omega-2){v'}^{\mu})]\,,\\ \langle \chi_{c1}(v',\varepsilon^{*}) \bar{c}_{v'}\gamma^\mu\gamma^5 b_v\vert B_{c}(v)\rangle &=&\frac{(\omega+1)\xi_F(\omega)}{\sqrt{6}}\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\nu}^{*}{v'}_{\rho}v_{\sigma},\\ \langle \chi_{c2}(v',\varepsilon^{*})\vert \bar{c}_{v'}\gamma^\mu\gamma^5 b_v \vert B_{c}(v)\rangle &=&-i\xi_F(\omega)v_\alpha[(1+\omega)\varepsilon^{*\alpha\mu}-\varepsilon^{*\alpha\beta}v_\beta {v'}^{\mu}]\,,\\ \langle \chi_{c2}(v',\varepsilon^{*})\vert \bar{c}_{v'}\gamma^\mu b_v\vert B_{c}(v)\rangle &=&\xi_F(\omega)\epsilon^{\mu\nu\rho\sigma} \varepsilon_{\alpha\nu}^{*}v^\alpha{v'}_{\rho}v_{\sigma}\,.\label{ffchic2-hqet} \end{eqnarray} Note that the hadronic states in QCD and the effective theory differ by a factor $\sqrt{m_H}$ in leading order. Thus the form factors defined in Eqs.~(\ref{ff1}-\ref{ffchic2}) can be obtained in the heavy quark limit: \begin{eqnarray}\label{HQET1} f^{\eta_{c}}_{0}(\omega) &=&\frac{(\omega +1) \xi _H(\omega) \sqrt{m_{B_c}} \sqrt{m_{\eta _c}}}{m_{B_c}+m_{\eta _c}}\,,\\ f^{\eta_{c}}_{+}(\omega) &=&\frac{\xi _H(\omega) \left(m_{B_c}+m_{\eta _c}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{\eta _c}}}\,,\\ V^{J/\psi}(\omega) &=&\frac{\xi _H(\omega) \left(m_{B_c}+m_{J/\psi}\right)}{2 \sqrt{m_{J/\psi}} \sqrt{m_{B_c}}}\,,\\ A^{J/\psi}_{0}(\omega) &=&\frac{\xi _H(\omega) \left(m_{B_c}+m_{J/\psi}\right)}{2 \sqrt{m_{J/\psi}} \sqrt{m_{B_c}}}\,,\\ A^{J/\psi}_{1}(\omega) &=&\frac{(\omega+1) \xi _H(\omega) \sqrt{m_{J/\psi}} \sqrt{m_{B_c}}}{m_{B_c}+m_{J/\psi}}\,,\\ A^{J/\psi}_{2}(\omega) &=&\frac{\xi _H(\omega) \left(m_{B_c}+m_{J/\psi}\right)}{2 \sqrt{m_{J/\psi}} \sqrt{m_{B_c}}}\,. \end{eqnarray} \begin{eqnarray} f^{\chi_{c0}}_{0}(\omega) &=&\frac{(\omega -1) \xi _E(\omega) \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c0}}}}}{m_{B_c}-m_{\chi _{\text{c0}}}}\,,\\ f^{\chi_{c0}}_{+}(\omega) &=&\frac{\xi _E(\omega) \left(m_{B_c}-m_{\chi _{\text{c0}}}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c0}}}}}\,,\\ V^{h_c}(\omega) &=&\frac{\xi _E(\omega)\left(m_{B_c}+m_{h_c}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{h_c}}}\,,\\ A^{h_c}_{0}(\omega) &=&\frac{\xi _E(\omega) \left(m_{B_c}-m_{h_c}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{h_c}}}\,,\\ A^{h_c}_{1}(\omega) &=&-\frac{(\omega -1) \xi _E(\omega) \sqrt{m_{B_c}} \sqrt{m_{h_c}}}{m_{B_c}+m_{h_c}}\,,\\ A^{h_c}_{2}(\omega) &=&-\frac{\xi _E(\omega) \left(m_{B_c}+m_{h_c}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{h_c}}}\,. \end{eqnarray} \begin{eqnarray} V^{\chi_{c1}}(\omega) &=&\frac{(\omega +1) \xi _F(\omega) \left(m_{B_c}+m_{\chi _{\text{c1}}}\right)}{2 \sqrt{6} \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c1}}}}}\,,\\ A^{\chi_{c1}}_{0}(\omega) &=&-\frac{\xi _F(\omega) \left(m_{B_c}-m_{\chi _{\text{c1}}}\right) \left(3 m_{B_c}-(\omega -2) m_{\chi _{\text{c1}}}\right)}{2 \sqrt{6} \sqrt{m_{B_c}} m_{\chi _{\text{c1}}}^{3/2}}\,,\\ A^{\chi_{c1}}_{1}(\omega) &=&-\frac{\left(\omega ^2-1\right) \xi _F(\omega) \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c1}}}}}{\sqrt{6} \left(m_{B_c}+m_{\chi _{\text{c1}}}\right)}\,,\\ A^{\chi_{c1}}_{2}(\omega) &=&-\frac{(\omega -5) \xi _F(\omega) \left(m_{B_c}+m_{\chi _{\text{c1}}}\right)}{2 \sqrt{6} \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c1}}}}}\,,\\ V^{\chi_{c2}}(\omega) &=&\frac{\xi _F (\omega)\left(m_{B_c}+m_{\chi _{\text{c2}}}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c2}}}}}\,,\\ A^{\chi_{c2}}_{0}(\omega) &=&\frac{\xi _F(\omega) \left(m_{B_c}+m_{\chi _{\text{c2}}}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c2}}}}}\,,\\ A^{\chi_{c2}}_{1}(\omega) &=&\frac{(\omega +1) \xi _F (\omega)\sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c2}}}}}{m_{B_c}+m_{\chi _{\text{c2}}}}\,,\\ A^{\chi_{c2}}_{2}(\omega) &=&\frac{\xi _F(\omega) \left(m_{B_c}+m_{\chi _{\text{c2}}}\right)}{2 \sqrt{m_{B_c}} \sqrt{m_{\chi _{\text{c2}}}}}\,.\label{HQETn} \end{eqnarray} From the above formulae, one can see that these sixteen form factors for the $B_c$ into S-wave and P-wave charmonia can be obtained by three universal Isgur-Wise functions~\cite{Isgur:1990kf}, i.e. $\xi _H(\omega)$, $\xi _E(\omega)$ and $\xi _F(\omega)$. \section{Unitatity constraints\label{IV}} \subsection{Dispersion relation} In the following, we will consider the constraints on form factors from unitarity, completeness and causality. The unitarity bound of form factors via dispersion relation and quark-hadron duality will be obtained. Let us first consider the relevant flavour-changing vector and axial-vector currents \begin{align} j^{\mu}_V &= \bar c\gamma ^\mu b \,, & j^{\mu}_A &= \bar c\gamma ^\mu \gamma^5 b \,.\label{eq:current} \end{align} In QCD the two-point correlation function of two currents is defined as \begin{eqnarray} \Pi^{\mu \nu}(q^2) & = & i \, \int d^4 x \, e^{i \, q \cdot x} \left\langle 0 \right|{\rm T} \, j^{\mu}(x) \, j^{\dag\,\nu}(0)\left| 0 \right\rangle \nonumber\\ &=&(\frac{q^\mu q^\nu}{q^2}-g^{\mu \nu })\Pi_{T}(q^2)+\frac{q^\mu q^\nu}{q^2}\Pi_{L}(q^2) \,, \label{eq:correlator} \end{eqnarray} which can be evaluated by the operator product expansion (OPE) approach. The corresponding longitudinal Lorenz scalar $\Pi_{L}(q^2)$ and transverse Lorenz scalar $\Pi_{T}(q^2)$ can be obtained by \begin{equation} \Pi_{I}(q^2) = P_{\mu \nu ,I}(q^2) \, \Pi^{\mu \nu }(q^2)\,, \qquad \mbox{\small ($I=L,T$),} \end{equation} with the longitudinal and transverse helicity projectors, \begin{equation} P _{\mu \nu,L }(q^2) = \frac{{q{}_\mu q_\nu }}{{q^2}} \,, \qquad P _{\mu \nu ,T}(q^2) = \frac{1}{(D-1)}\left( \frac{q_\mu q_\nu}{q^2 }-g_{\mu \nu } \right) \,. \end{equation} $\Pi _{I}(q^2)$ is an analytic function and it satisfies the dispersion relation \begin{equation} \label{eq:chidef} \Pi_{I}(q^2)= \frac{1}{\pi } \, \int\limits_0^\infty dt \, \frac{\mathrm{Im} \, \Pi_I (t)}{ {t - q^2 } }\,. \end{equation} The n-th subtracted dispersion relation is \begin{equation} \label{eq:chindef} \chi_I(n,Q_0^2) =\frac{1}{n!}\left. {\frac{d^n\Pi_{I}(q^2)}{{{dq^2}^n}}} \right|_{q^2 = -Q_0^2}= \frac{1}{\pi } \, \int\limits_0^\infty dt \, \frac{\mathrm{Im} \, \Pi_I (t)}{\left( {t +Q_0^2 } \right)^{n+1} }\,. \end{equation} \subsection{Resonance contributions} Using the dispersion relation in Eqs.~(\ref{eq:chidef}-\ref{eq:chindef}), we need to calculate the imaginary part of the correlators. The imaginary part $\mathrm{Im}\, \Pi_{I}(q^2)$ can be obtained through inserting complete basis with all hadronic states with allowed quantum numbers. The complete set of hadronic states $X$ have the identical quantum numbers as the vector or axial-vector current $j_\mu$. For a particular choice of intermediate state $X= B V$, where $BV$ may be either $BD^*$ or $B_c J/\psi$, we define \begin{equation} \mathrm{Im} \, \Pi _{I}^{BV}(q^2) =\frac{1}{2}\, \int {\frac{d^3 p_B}{(2\pi)^32E_B} \, \frac{d^3 p_V}{(2\pi)^32E_V} \, (2\pi)^4\delta^4(q - p_B - p_V)} \, P_{\mu \nu,I } \, \left\langle 0 \right|j^\mu \left| B V \right\rangle \left\langle B V \right|j^{\nu\dag} \left|0 \right\rangle\,, \end{equation} where $q^2\geq m_B^2-m_V^2$. Because the inserted hadronic states are not complete, it results in the inequality \begin{equation}\label{eq:unit} {\mathop{\rm Im}\nolimits} \Pi^{B V}_{I} (t) \leq {\mathop{\rm Im}\nolimits} \Pi_{I} (t) \,. \end{equation} In principle, we need to consider enough hadronic states to close to the bound. However, there is no conflict to write the expression as in Eq.~(\ref{eq:unit}). One can use the crossing symmetry to relate the matrix elements $\left\langle 0 \right|j^\mu \left| BV \right\rangle$ to $\left\langle B \right|j^\mu \left| V \right\rangle$, replacing $p_V$ in $\left\langle B \right|j^\mu \left| V \right\rangle$ to $-p_V$. Then we obtain the following identity \begin{eqnarray} \nonumber P _{\mu \nu,T } \, \langle 0| j^\mu_V | BV\rangle \langle B V|j_V ^{\nu\dag}|0\rangle &=&\frac{\lambda}{3 q^2}\, \left|\mathcal{B}_{V}\right|^2 \,, \\ \nonumber P _{\mu \nu, T } \, \langle 0| j^\mu_A | BV\rangle \langle B V|j_A ^{\nu \dag}|0\rangle &=&\frac{\lambda}{3q^2 }\,\sum_{i=1}^2 \left|\mathcal{B}_{Ai}\right|^2 \,, \\ P _{\mu \nu, L} \, \langle 0| j^\mu_A | BV\rangle \langle B V|j_A ^{\nu\dag}|0\rangle &=&\frac{\lambda}{3 q^2}\, \left|\mathcal{B}_{A0}\right|^2 \,, \label{BFF2} \end{eqnarray} where \begin{align} \mathcal{B}_{V}(q^2)&= \frac{\sqrt{2q^2} }{m_B+m_V}V(q^2) \,, \cr \mathcal{B}_{A0}(q^2) & =\sqrt{3} A_0(q^2) \,, \cr \mathcal{B}_{A1}(q^2)&= \frac{(m_B+m_V)^2 \, (m_B^2-m_V^2-q^2) \, A_1(q^2) -\lambda \, A_2(q^2)}{2 m_V \sqrt{\lambda} \, (m_B+m_V)} \,, \cr \mathcal{B}_{A2}(q^2)& =\frac{\sqrt{2 \, q^2 } \, (m_B+m_V)}{\sqrt{\lambda }} \, A_1(q^2) \,,\label{BFF3} \end{align} and \begin{align} \lambda &= \left( (m_B-m_V)^2-q^2\right) \left( (m_B+m_V)^2-q^2\right), \label{eq:lambdadef} \end{align} which satisfies the identity $\lambda\equiv (t_- - q^2)(t_+ - q^2)$ in the case of $B_c$ and $J/\psi$. One can now express $\mathrm{Im} \, \Pi^{B V} _{I,i} $ in a compact form, \begin{eqnarray} \mathrm{Im} \, \Pi^{B V} _{I,i}&=& \frac{1}{2}\, \int {\frac{d^3 p_B}{(2\pi)^32E_B} \, \frac{d^3 p_V}{(2\pi)^32E_V} \, (2\pi)^4\delta^4(q - p_B - p_V)} \, \frac{\lambda}{3q^2} \left|A_{I,i}^{V}\right|^2\nonumber\\ &=&\frac{1}{48\pi} \, \frac{\lambda^{3/2}}{q^{4}} \left|A_{I,i}^{V}\right|^2 \,,\label{eq:egBM} \end{eqnarray} where the $\left|A_{I,i}^V\right|^2$ can be extracted from Eq.~(\ref{BFF2}), \begin{align} \left|A_{T,V}^{V}\right|^2 &=\left|\mathcal{B}_{V}\right|^2 \,, \qquad \left|A_{T,A}^{V}\right|^2 = \sum_{i=1}^2 \left|\mathcal{B}_{Ai}\right|^2 \,, \qquad \left|A_{L,A}^{V}\right|^2 = \left|\mathcal{B}_{A0}\right|^2 \,. \label{eq:Afunc1} \end{align} For a particular choice of intermediate state $X= B P$ where the $BP$ may be either $BD$ or $B_c \eta_c$, we have \begin{eqnarray} \nonumber P _{\mu \nu,T } \, \langle 0| j^\mu_V | BP\rangle \langle B P|j_V ^{\nu\dag}|0\rangle &=&\frac{\lambda}{3 q^2}\, \left|\mathcal{B}_{f_+}\right|^2 \,, \\ \nonumber P _{\mu \nu,L } \, \langle 0| j^\mu_V | BP\rangle \langle B P|j_V ^{\nu \dag}|0\rangle &=&\frac{\lambda}{3q^2 }\, \left|\mathcal{B}_{f_0}\right|^2 \,, \label{BPF2} \end{eqnarray} where \begin{align} \mathcal{B}_{f_+}(q^2)&=f_+(q^2) \,, \cr \mathcal{B}_{f_0}(q^2) & =\frac{\sqrt{3}(m_B^2-m_P^2 )}{\sqrt{\lambda}}f_0(q^2) \,. \label{BPF3} \end{align} One obtains $\mathrm{Im} \, \Pi^{B P} _{I,V} $ in a compact form \begin{eqnarray} \mathrm{Im} \, \Pi^{B P} _{I,V}&=& \frac{1}{2}\, \int {\frac{d^3 p_B}{(2\pi)^32E_B} \, \frac{d^3 p_P}{(2\pi)^32E_P} \, (2\pi)^4\delta^4(q - p_B - p_P)} \, \frac{\lambda}{3q^2} \left|A_{I,V}^{P}\right|^2\nonumber\\ &=&\frac{1}{48\pi} \, \frac{\lambda^{3/2}}{q^{4}} \left|A_{I,V}^{P}\right|^2 \,,\label{eq:egBP} \end{eqnarray} where the $\left|A_{I,V}^P\right|^2$ can be extracted from Eq.~(\ref{BPF2}), \begin{align} \left|A_{T,V}^{P}\right|^2 &=\left|\mathcal{B}_{f_+}\right|^2 \,, \qquad \left|A_{L,V}^{P}\right|^2 = \left|\mathcal{B}_{f_0}\right|^2 \,. \label{eq:Afunc2} \end{align} Similarly, for the axial vector and scalar states, we have \begin{align} \left|A_{T,A}^{A}\right|^2 &=\left|\mathcal{B}_{V0}\right|^2 \,, \qquad \left|A_{T,V}^{A}\right|^2 = \sum_{i=1}^2 \left|\mathcal{B}_{Ai}\right|^2 \,, \qquad \left|A_{L,V}^{A}\right|^2 = \left|\mathcal{B}_{A0}\right|^2 \,. \label{eq:Afunc3} \end{align} and \begin{align} \left|A_{T,A}^{S}\right|^2 &=\left|\mathcal{B}_{f_+}\right|^2 \,, \qquad \left|A_{L,A}^{S}\right|^2 = \left|\mathcal{B}_{f_0}\right|^2 \,. \label{eq:Afunc4} \end{align} For the tensor state, one has \begin{eqnarray} \nonumber P _{\mu \nu,T } \, \langle 0| j^\mu_V | BT\rangle \langle B T|j_V ^{\nu\dag}|0\rangle &=&\frac{\lambda}{3 q^2}\, \left|\mathcal{B}^T_{V}\right|^2 \,, \\ \nonumber P _{\mu \nu, T } \, \langle 0| j^\mu_A | BT\rangle \langle B T|j_A ^{\nu \dag}|0\rangle &=&\frac{\lambda}{3q^2 }\,\sum_{i=1}^2 \left|\mathcal{B}^T_{Ai}\right|^2 \,, \\ P _{\mu \nu, L} \, \langle 0| j^\mu_A | BT\rangle \langle B T|j_A ^{\nu\dag}|0\rangle &=&\frac{\lambda}{3 q^2}\, \left|\mathcal{B}^T_{A0}\right|^2 \,, \label{BTF2} \end{eqnarray} where \begin{align} \mathcal{B}^T_{V}(q^2)&= \frac{\sqrt{\lambda q^2} }{2m_Bm_T(m_B+m_T)}V(q^2) \,, \cr \mathcal{B}^T_{A0}(q^2) & =\frac{\sqrt{\lambda }}{ \sqrt{2}m_B m_T } A_0(q^2) \,, \cr \mathcal{B}^T_{A1}(q^2)&= \frac{(m_B+m_T)^2 \, (m_B^2-m_T^2-q^2) \, A_1(q^2) -\lambda \, A_2(q^2)}{2 \sqrt{6 } \,m_B m_T^2 (m_B+m_T)} \,, \cr \mathcal{B}^T_{A2}(q^2)& =\frac{ (m_B+m_T)\sqrt{q^2}}{2m_B m_T} \, A_1(q^2) \,. \label{BTF3} \end{align} The $\mathrm{Im} \, \Pi^{B T} _{I,i} $ becomes \begin{eqnarray} \mathrm{Im} \, \Pi^{B T} _{I,i}&=& \frac{1}{2}\, \int {\frac{d^3 p_B}{(2\pi)^32E_B} \, \frac{d^3 p_T}{(2\pi)^32E_T} \, (2\pi)^4\delta^4(q - p_B - p_T)} \, \frac{\lambda}{3q^2} \left|A_{I,i}^{T}\right|^2\nonumber\\ &=&\frac{1}{48\pi} \, \frac{\lambda^{3/2}}{q^{4}} \left|A_{I,i}^{T}\right|^2 \,,\label{eq:egBT} \end{eqnarray} where the $\left|A_{I,i}^T\right|^2$ can be extracted from Eq.~(\ref{BTF2}), \begin{align} \left|A_{T,V}^{T}\right|^2 &=\left|\mathcal{B}^T_{V}\right|^2 \,, \qquad \left|A_{T,A}^{T}\right|^2 = \sum_{i=1}^2 \left|\mathcal{B}^T_{Ai}\right|^2 \,, \qquad \left|A_{L,A}^{T}\right|^2 = \left|\mathcal{B}^T_{A0}\right|^2 \,. \label{eq:Afunc5} \end{align} \subsection{OPE for the two-point correlation function} The two-point correlation function defined in Eq.~(\ref{eq:correlator}) can be calculated using OPE. The expression has been given as~\cite{Shifman:1978bx,Shifman:1978by,Novikov:1980uj} \begin{eqnarray} i \int dx \, e^{i \, q \cdot x} \, \left\langle 0 \right|{\rm T} \, j^{\mu}(x) \, j^{\dag\,\nu}(0)\left| 0 \right\rangle &=&(\frac{q^\mu q^\nu}{q^2}-g^{\mu \nu })\sum\limits_{n = 1}^\infty\, C_{T,n}(q) \, \left\langle 0 \right|:{\cal O}_n(0):\left| 0 \right\rangle\,\nonumber\\&&+\frac{q^\mu q^\nu}{q^2}\sum\limits_{n = 1}^\infty\, C_{L,n}(q) \, \left\langle 0 \right|:{\cal O}_n(0):\left| 0 \right\rangle \,, \end{eqnarray} where the local operators ${\cal O}_n(0)$ are constructed by quark and gluon fields. As for the flavor changing double-heavy currents defined in Eq.~(\ref{eq:current}), the first two dominant contributions come from the unit operator and the gluon vacuum condensate $\displaystyle\langle (\alpha_s/\pi) \, G^2\rangle$. Here $C_{I,n}(q)$ are the related short-distance perturbative coefficients~\cite{Jamin:1992se}. Results for n-th subtracted scalars $\chi_I(n,Q_0^2=0)$ can be found in Eqs. (4.2-4.3) and (4.8-4.9) in Ref.~\cite{Boyd:1997kz}. We have \begin{eqnarray} \chi^V_L(n=1)\bigg|_{r=0.286} &=& 4.48\times 10^{-3} \left(1+1.34 \alpha_s-6.50\times10^{-4}\left(\frac{4.9\mathrm{GeV}}{m_b}\right)^4\frac{\displaystyle\langle \alpha_s G^2/\pi\rangle}{0.02\mathrm{GeV}^4}\right),\nonumber\\ \chi^A_L(n=1)\bigg|_{r=0.286} &=& 2.09\times 10^{-2} \left(1+0.62 \alpha_s+2.87\times10^{-4}\left(\frac{4.9\mathrm{GeV}}{m_b}\right)^4\frac{\displaystyle\langle \alpha_s G^2/\pi\rangle}{0.02\mathrm{GeV}^4}\right),~~~ \end{eqnarray} and \begin{eqnarray} \chi^V_T(n=2)\bigg|_{r=0.286} &=& \frac{9.94\times 10^{-3} }{m_b^2}\left(1+1.38 \alpha_s-8.69\times10^{-6}\left(\frac{4.9\mathrm{GeV}}{m_b}\right)^4\frac{\displaystyle\langle \alpha_s G^2/\pi\rangle}{0.02\mathrm{GeV}^4}\right),\nonumber\\ \chi^A_T(n=2)\bigg|_{r=0.286} &=& \frac{6.10\times 10^{-3} }{m_b^2}\left(1+1.32 \alpha_s-8.40\times10^{-4}\left(\frac{4.9\mathrm{GeV}}{m_b}\right)^4\frac{\displaystyle\langle \alpha_s G^2/\pi\rangle}{0.02\mathrm{GeV}^4}\right),~~~~\end{eqnarray} where $r=m_c/m_b$. In the above expression, we have seen that the gluon condensate contributions are trivial in the correlator of double heavy vector and axial-vector currents. \subsection{Bounds on expansion coefficients} Using Eq.~(\ref{eq:unit}) and quark-hadron duality, one derives \begin{equation} \frac{1}{\pi } \, \int\limits_0^\infty dt \, \frac{\mathrm{Im} \, \Pi^{BH}_{I,X} (t)}{\left(t - q^2 \right)^{n+1} }\bigg|_{q^2=-Q_0^2} = \frac{1}{\pi } \, \int\limits_{t_+}^\infty dt \, \frac{\lambda^{3/2}(t)}{48\pi \, t^{2}(t+Q_0^2)^{n+1}} \left| A_{I,X}(t) \right|^2 \leq \chi^{X}_{I}(n,Q_0^2)\,, \label{eq:unit2} \end{equation} where $\chi^{X}_{X} \equiv \chi^{X}_{I,\rm OPE}$. One can choose $Q_0^2=0\ll t_+$. In Eq.~(\ref{eq:unit2}), we have $t\geq t_+$. In order to map the $t$-plane to the unit disk, one can define a parameter $z(t)$ \begin{equation} \label{eq:zdef} z(t)\equiv z(t,t_0)= \frac{ \sqrt{t_+-t}- \sqrt{t_+-t_0}}{\sqrt{t_+-t}+ \sqrt{t_+-t_0}} \,, \end{equation} where the free parameter $t_0$ satisfies $0 \leq t_0<t_-$, which can be optimised to reduce the maximum value of $|z(t)|$ in the physical form factor range~\cite{Bharucha:2010im} \begin{equation} t_0 \big|_{\rm opt.} = t_+ - \sqrt{t_+(t_+-t_-)} \,. \label{eq:t0opt} \end{equation} Then the region $0 \leq t<t_+$ can be mapped onto the unit disk $|z(t)|<1$, while the physical pair-production region $t\geq t_+$ onto the unit circle $|z(t)|=1$. Expressed by $z$, the inequality could be written in the form \begin{align} \label{eq:phidet} \frac{1}{2\pi i } \, \oint &\frac{dz}{z} \, |\phi_I^X (z)\, A _{I,X}(z)|^2 \leq 1 \quad \Leftrightarrow \quad \frac{1}{\pi} \, \int_{t_+}^\infty\frac{dt}{t-t_0} \, \sqrt{\frac{t_+-t_0}{t-t_+}} \, |\phi_I^X(t) \, A_{I,X}(t)|^2 \leq 1 \,, \end{align} here the auxiliary function $\phi_I^X(t)$ can be obtained by comparing (\ref{eq:phidet}) and (\ref{eq:unit2}), \begin{equation}\label{eq:bound2a} |\phi_{I}^X(t)|^2= \frac{1}{48 \pi \, \chi^{X}_I(n)} \, \frac{(t-t_+)^2}{(t_+ -t_0)^{1/2}} \, \frac{(t-t_-)^{3/2}}{t^{n+2}} \, \frac{t-t_0}{t} \,. \end{equation} The form factors $A_I^X(t)$ then can be generally expanded as~\cite{Bharucha:2010im} \begin{equation} A_{I,X}(t) = \frac{(\sqrt{-z(t,0)})^m (\sqrt{z(t,t_-)})^l }{B(t) \, \phi_I^X(t)} \, \sum_{n=0}^\infty \alpha_n \, z^n\,, \label{eq:ssepar} \end{equation} where the factors ${(\sqrt{-z(t,0)})^m}$ and ${(\sqrt{z(t,t_-)})^l}$ have been included to take into account the poles at $t=0$ and $t=t_-$~\cite{Hill:2006ub}, and the module of which equals to 1 in the pair-production region. The function $B(t)$ is a Blaschke factor with ${B(t) = \prod_i z(t,m_{R_i}^2)}$, representing resonances poles with masses $m^2_{R_i}\leq t_+$, and satisfying $|B(t)| = 1$ in the pair-production region. Following the same procedure to consider the poles at $t=0$ and $t=t_-$, we get \begin{equation} \phi_I^X(t)=\sqrt{\frac{1}{48\pi\chi^{X}_{I}(n)}} \, \frac{(t-t_+)}{(t_+-t_0)^{1/4}} \left(\frac{z(t,0)}{-t}\right)^{(n+3)/2} \left(\frac{z(t,t_0)}{t_0-t}\right)^{-1/2} \left(\frac{z(t,t_-)}{t_--t}\right)^{-3/4}\,. \end{equation} Using the expressions in Eqs. (\ref{eq:ssepar}) into (\ref{eq:phidet}), and the inequality $|z(t,t_0)|\leq1$, $|z(t,m_R^2)|\leq1$ and $|z(t,0)|\leq1$, we obtain the bound on the coefficients $\alpha_n$: \begin{equation} \sum_{n=0}^\infty \alpha_n^2<1 \,. \end{equation} \subsection{Parametrization } Using the series in Eq.~\eqref{eq:ssepar}, one can establish the parametrization of the form factors $f_0$, $f_+$, $V$ and $A_i$, and the generic formula is given as \begin{equation} \label{z-Se} F_i(t) = \frac{1}{B(t) \, \phi_i(t)} \, \sum_{k} \alpha^i_k \, z^k(t) \,. \end{equation} For the $B_c$ meson decays to $J/\psi$, we denote $F_1(t)=V(t)$, $F_2(t)=A_0(t)$, $F_3(t)=A_1(t)$, and we also define two new form factors \begin{eqnarray} F_4(t) = \frac{\left(t_+-t\right)\left(\frac{z(t,t_-)}{t_--t}\right)^{-1} \, A_2(t)-(m_B+m_V)^2 \, (m_B^2-m_V^2-t) \, A_1(t) }{2 m_V (m_B+m_V)^3} \,,\nonumber\\ F^\prime_4(t) = \frac{\lambda \, A_2(t)-(m_B+m_V)^2 \, (m_B^2-m_V^2-t) \, A_1(t) }{2 m_V (m_B+m_V)^3} \,. \end{eqnarray} The corresponding functions $\phi_i(t)$ are \begin{eqnarray} \phi_1(t)&=&\frac{m_B+m_V}{\sqrt{2\chi^{V}_{T}(n)}} \, \left(\frac{z(t,0)}{-t}\right)^{1/2}\phi_0(t)\,,\label{FV1}\\ \phi_2(t)&=&\frac{1}{\sqrt{3\chi^{A}_{L}(n)}} \, \phi_0(t)\,,\\ \phi_3(t)&=&\frac{\left(t_+-t\right)^{1/2}}{\sqrt{2\chi^{A}_{T}(n)}(m_B+m_V)} \, \left(\frac{z(t,0)}{-t}\right)^{1/2}\left(\frac{z(t,t_-)}{t_--t}\right)^{-1/2}\phi_0(t)\,,\\ \phi^{(\prime)}_4(t)&=&\frac{\left(t_+-t\right)^{1/2}}{\sqrt{\chi^{A}_{T}(n)}(m_B+m_V)^2} \, \left(\frac{z(t,t_-)}{t_--t}\right)^{-1/2}\phi_0(t)\,,\label{FV4} \end{eqnarray} with \begin{equation} \phi_0(t)=\sqrt{\frac{1}{48\pi}} \, \frac{(t-t_+)}{(t_+-t_0)^{1/4}} \left(\frac{z(t,0)}{-t}\right)^{(n+3)/2} \left(\frac{z(t,t_0)}{t_0-t}\right)^{-1/2} \left(\frac{z(t,t_-)}{t_--t}\right)^{-3/4}\,, \end{equation} where the relation is hold by $\phi_0(t)=\phi_I^X(t)\sqrt{\chi^{X}_{I}(n)}$. The Blaschke factor ${B(t) = \prod_i z(t,m_{R_i}^2)}$, representing poles due to sub-threshold resonances of masses $m_{R_i}$. There are not enough data to determine the structure of $B(t)$. Fortunately, for $b\to c$ transition, the masses of the relevant $B_c$-type resonances can be estimated from potential model or Lattice QCD. Using the potential model expectation~\cite{Ebert:2011jc}, we get \begin{eqnarray} B^V(t)&=&z(t,6.333^2)z(t,6.882^2)z(t,7.021^2)z(t,7.258^2)z(t,7.392^2)\nonumber\\&&z(t,7.609^2)z(t,7.733^2)z(t,7.947^2)\,,\nonumber\\ B^A(t)&=&z(t,6.743^2)z(t,6.750^2)z(t,7.134^2)z(t,7.147^2)z(t,7.500^2)\nonumber\\&&z(t,7.510^2)z(t,7.844^2)z(t,7.853^2)\,. \end{eqnarray} For the $B_c$ meson decays to $\eta_c$, we denote $F^P_1(t)=f_+(t)$ and $F^P_2(t)=f_0(t)$. The corresponding functions $\phi^P_i(t)$ are \begin{eqnarray} \phi^P_1(t)&=&\frac{1}{\sqrt{\chi^{V}_{T}(n)}} \, \phi_0(t)\,,\label{FP1}\\ \phi^P_2(t)&=&\frac{\left(t_+-t\right)^{1/2}}{\sqrt{3\chi^{V}_{L}(n)}(m^2_B-m_P^2)}\left(\frac{z(t,t_-)}{t_--t}\right)^{-1/2} \, \phi_0(t)\,,\label{FP2} \end{eqnarray} Similarly, one can easily get the formulae when the final charmonium is $h_c$, $\chi_{c1}$ or $\chi_{c0}$. For $B_c$ decays to $\chi_{c2}$, we denote $F^T_1(t)=V(t)$, $F^T_2(t)=A_0(t)$, $F^T_3(t)=A_1(t)$, and we also define two new form factors \begin{eqnarray} F^T_4(t) = \frac{\left(t_+-t\right)\left(\frac{z(t,t_-)}{t_--t}\right) \, A_2(t)-(m_B+m_T)^2 \, (m_B^2-m_T^2-t) \, A_1(t) }{2\sqrt{6} m_B m_T^2 (m_B+m_T)} \,,\nonumber\\ F^{T\prime}_4(t) = \frac{\lambda\, A_2(t)-(m_B+m_T)^2 \, (m_B^2-m_T^2-t) \, A_1(t) }{2\sqrt{6} m_B m_T^2 (m_B+m_T)} \,. \end{eqnarray} The corresponding functions $\phi^T_i(t)$ are \begin{eqnarray} \phi^T_1(t)&=&\frac{2m_B m_T(m_B+m_T)}{\sqrt{\chi^{V}_{T}(n)}} \,\left(\frac{z(t,0)}{-t}\right)^{1/2}\left(t_+-t\right)^{-1/2} \left(\frac{z(t,t_-)}{t_--t}\right)^{1/2}\phi_0(t)\,,\label{FT1}\\ \phi^T_2(t)&=&\frac{\sqrt{2}m_B m_T}{\sqrt{\chi^{A}_{L}(n)}} \, \left(\frac{z(t,t_-)}{t_--t}\right)^{-1/2}\phi_0(t)\,,\\ \phi^T_3(t)&=&\frac{1}{\sqrt{\chi^{A}_{T}(n)}} \, \phi_0(t)\,,\\ \phi^{T(\prime)}_4(t)&=&\frac{\left(t_+-t\right)^{1/2}}{\sqrt{\chi^{A}_{T}(n)}} \, \left(\frac{z(t,t_-)}{t_--t}\right)^{-1/2}\phi_0(t)\,.\label{FT4} \end{eqnarray} \section{Phenomenological discussions} With the unitary constraints, the new parametrization forms for form factors of $B_c$ into the S-wave and P-wave charmonium in the entire $q^2$ range have been derived in the last section. The z-series expansion depends on the coefficients $\alpha_k$, which can be obtained by fitting the data or theoretical results. Although it contains an infinite tower of coefficients, one may expect that this expansion converges very fast, since the maximum of $z(t)$ is only 0.02 in the physical region $0\leq t\leq t_-$. Thus it is a good approximation to conserve the first order coefficient $\alpha_1$ and set $\alpha_i=0$ for $i>1$. In the fitting, we will use the lattice QCD data by the HPQCD Collaboration in Refs.~\cite{Colquhoun:2016osw,Lytle:2016ixw} to determine the form factors $f_+^{\eta_c}$, $f_0^{\eta_c}$, $V^{J/\psi}$, and $A_1^{J/\psi}$. From the fitting, one can see the LFQM predictions are consistent with the HPQCD data. Besides, the lattice QCD results are also consistent with the HQET predictions at the minimal recoil point. Due to the lack of the lattice QCD data for other form factors, we will employ the NRQCD and the HQET results to determine the rest form factors of $B_c$ into the S-wave and P-wave charmonium. We have shown the form factors of $f_+^{\eta_c}$, $f_0^{\eta_c}$, $V^{J/\psi}$, and $A_1^{J/\psi}$ in Figs.~\ref{fig:etac} and~\ref{fig:jpsi1}. and \ref{fig:jpsi2}. The heavy quark relations for form factors in Eqs.~(\ref{HQET1}-\ref{HQETn}) use Isgur-Wise functions. At zero recoil with $\omega=1$, the heavy quark limit gives $f_+(\omega=1)=1.06$ and $f_0(\omega=1)=0.93$ for $B_c$ into $\eta_c$, and $V(\omega=1)=A_0(\omega=1)=A_2(\omega=1)=1.06$, $A_1(\omega=1)=0.94$ for $B_c$ into $J/\psi$. For $B_c$ into $\eta_c$ and $B_c$ into $J/\psi$, these predictions are consistent with the z-series expansion. \begin{figure}[t] \centering \includegraphics[width=0.48\linewidth]{etac-fp.pdf} \includegraphics[width=0.48\linewidth]{etac-f0.pdf} \caption{The form factors of $B_c$ into $\eta_c$. The data is from the HPQCD lattice simulations~\cite{Colquhoun:2016osw}; the blue line is from the z-series based on the lattice data; the dashed line is from the LFQM results~\cite{Wang:2008xt}; the dotted line is from the the z-series based on the LFQM results. } \label{fig:etac} \end{figure} \begin{figure}[t] \centering \includegraphics[width=0.48\linewidth]{jpsi-V.pdf} \includegraphics[width=0.48\linewidth]{jpsi-A1.pdf} \caption{The form factors of $B_c$ into $J/\psi$. The data is from the HPQCD lattice simulations~\cite{Colquhoun:2016osw}; the blue line is from the z-series based on the lattice data; the dashed line is from the LFQM results~\cite{Wang:2008xt}.} \label{fig:jpsi1} \end{figure} \begin{figure}[t] \centering \includegraphics[width=0.48\linewidth]{jpsi-A0.pdf} \includegraphics[width=0.48\linewidth]{jpsi-A2.pdf} \caption{The form factors of $B_c$ into $J/\psi$. The dashed line is from the LFQM results~\cite{Wang:2008xt}; the blue line is from the the z-series based on the NRQCD results. } \label{fig:jpsi2} \end{figure} \begin{figure}[t] \centering \includegraphics[width=0.48\linewidth]{chic0-fp.pdf} \includegraphics[width=0.48\linewidth]{chic0-f0.pdf} \caption{The form factors of $B_c$ into $\chi_{c0}$. The dashed line is from the LFQM results~\cite{Wang:2009mi}; the blue line is from the the z-series based on the NRQCD results. } \label{fig:chic0} \end{figure} \begin{figure}[t] \centering \includegraphics[width=0.48\linewidth]{chic1-V.pdf} \includegraphics[width=0.48\linewidth]{chic1-A0.pdf} \includegraphics[width=0.48\linewidth]{chic1-A1.pdf} \includegraphics[width=0.48\linewidth]{chic1-A2.pdf} \caption{The form factors of $B_c$ into $\chi_{c1}$. The dashed line is from the LFQM results~\cite{Wang:2009mi}; the blue line is from the the z-series based on the NRQCD results. } \label{fig:chic1} \end{figure} \begin{figure}[t] \centering \includegraphics[width=0.48\linewidth]{hc-V.pdf} \includegraphics[width=0.48\linewidth]{hc-A0.pdf} \includegraphics[width=0.48\linewidth]{hc-A1.pdf} \includegraphics[width=0.48\linewidth]{hc-A2.pdf} \caption{The form factors of $B_c$ into $h_{c}$. The dashed line is from the LFQM results~\cite{Wang:2009mi}; the blue line is from the the z-series based on the NRQCD results. } \label{fig:hc} \end{figure} \begin{figure}[t] \centering \includegraphics[width=0.48\linewidth]{chic2-V.pdf} \includegraphics[width=0.48\linewidth]{chic2-A0.pdf} \includegraphics[width=0.48\linewidth]{chic2-A1.pdf} \includegraphics[width=0.48\linewidth]{chic2-A2.pdf} \caption{The form factors of $B_c$ into $\chi_{c2}$. The dashed line is from the LFQM results~\cite{Wang:2009mi}; the blue line is from the the z-series based on the NRQCD results. } \label{fig:chic2} \end{figure} We have also plotted the form factors of $B_c$ into P-wave charmonium within z-series method in Figs.~\ref{fig:chic0}, \ref{fig:chic1}, \ref{fig:hc} and \ref{fig:chic2}. These results are helpful to perform the phenomenological analysis. Semileptonic decays $B_c\to \eta_c \ell\bar\nu_{\ell}$ have the decay widths: \begin{eqnarray} \frac{d\Gamma(B_c\to Pl\bar\nu_l)}{dq^2} &=&(\frac{q^2-m_l^2}{q^2})^2\frac{ {\sqrt{\lambda(m_{B_c}^2,m_P^2,q^2)}} G_F^2 |V_{\rm CKM}|^2} {384m_{B_c}^3\pi^3} \frac{1}{q^2} \nonumber\\ &\times& \left\{ (m_l^2+2q^2) \lambda(m_{B_c}^2,m_P^2,q^2) f_+^2(q^2) +3 m_l^2(m_{B_c}^2-m_P^2)^2f_0^2(q^2) \right\}, \end{eqnarray} where $V_{\rm CKM}=V_{cb}$ and $\lambda(m_{B_c}^2, m_{i}^2,q^2)=(m_{B_c}^2+m_{i}^2-q^2)^2-4m_{B_c}^2m_i^2$. This formula is also valid for semileptonic decays of $B_c$ into a scalar charmonium by $P\to S$. Decay widths for $B_c\to J/\psi\ell\bar\nu_{\ell}$ are given as: \begin{eqnarray} \frac{d\Gamma_L(B_c\to Vl\bar\nu)}{dq^2}&=&(\frac{q^2-m_l^2}{q^2})^2\frac{ {\sqrt{\lambda(m_{B_c}^2,m_V^2,q^2)}} G_F^2 |V_{\rm CKM}|^2} {384m_{B_c}^3\pi^3} \frac{1}{q^2} \nonumber\\ &\times& \left\{ 3 m_l^2 \lambda(m_{B_c}^2,m_V^2,q^2) A_0^2(q^2)+(m_l^2+2q^2) |\frac{1}{2m_V} \left[ (m_{B_c}^2-m_V^2-q^2)\right.\right.\nonumber\\ &\times&\left.\left. (m_{B_c}+m_V)A_1(q^2)-\frac{\lambda(m_{B_c}^2,m_V^2,q^2)}{m_{B_c}+m_V}A_2(q^2)\right]|^2 \right\},\label{eq:decaywidthlon}\\ \frac{d\Gamma^\pm(B_c\to Vl\bar\nu)}{dq^2}&=&(\frac{q^2-m_l^2}{q^2})^2\frac{ {\sqrt{\lambda(m_{B_c}^2,m_V^2,q^2)}} G_F^2 |V_{\rm CKM}|^2} {384m_{B_c}^3\pi^3} \nonumber\\ &\times& \left\{ (m_l^2+2q^2) \lambda(m_{B_c}^2,m_V^2,q^2)\left|\frac{V(q^2)}{m_{B_c}+m_V}\mp \frac{(m_{B_c}+m_V)A_1(q^2)}{\sqrt{\lambda(m_{B_c}^2,m_V^2,q^2)}}\right|^2 \right\},\; \end{eqnarray} where we use the subscript $+(-)$ to denote the right-handed (left-handed) states of vector mesons. The total and transverse differential decay widths are given by: \begin{eqnarray} \frac{d\Gamma}{dq^2}= \frac{d\Gamma_L}{dq^2}+ \frac{d\Gamma_\perp}{dq^2},\;\;\; \frac{d\Gamma_\perp}{dq^2}= \frac{d\Gamma^+}{dq^2}+ \frac{d\Gamma^-}{dq^2}. \end{eqnarray} The formulae are also valid for decays of $B_c$ into axial-vector charmonia by $V\to \chi_{c1}(h_c)$. For the tensor meson in the final state, the semileptonic $B_c$ decays have \begin{eqnarray} \frac{d\Gamma_L(B_c\to T l\bar{\nu}_l)}{dq^2}&=& \frac{2}{3}\frac{ \lambda(m_{B_c}^2,m_T^2,q^2)}{4m_T^2m_{B_c}^2}\frac{d\Gamma_L(B_c\to V l\bar{\nu}_l)}{dq^2}|_{A_i^V\to A_i^T},\nonumber\\ \frac{d\Gamma^{\pm}(B_c\to T l\bar{\nu}_l)}{dq^2}&=& \frac{1}{2}\frac{ \lambda(m_{B_c}^2,m_T^2,q^2)}{4m_T^2m_{B_c}^2}\frac{d\Gamma^{\pm}(B_c\to V l\bar{\nu}_l)}{dq^2}|_{A_i^V\to A_i^T,V^V\to V^T}. \end{eqnarray} In the numerical calculation, we adopt the inputs as: $m_{B_c}=6.276$GeV, $m_{\eta_c}=2.984$GeV, $m_{J/\psi}=3.097$GeV, $m_{h_c}=3.525$GeV, $m_{\chi_{c0}}=3.415$GeV, $m_{\chi_{c1}}=3.511$GeV, $m_{\chi_{c2}}=3.556$GeV, $\tau_{B_c}=0.503$ps~\cite{Agashe:2014kda}. We adopt the heavy quark masses as $m_c=(1.4\pm0.2)$GeV and $m_b=(4.8\pm 0.2)$GeV~\cite{Wang:2015bka,Zhu:2016udl,Zhu:2015bba,Wang:2017vnc}. We find that the ratios between $B_c\to H+\mu +\bar\nu_\mu $ and $B_c\to H+e^- +\bar\nu_e $ is rather close to 1, which is under expectation. For the semitaunic and semimuonic $B_c$ decays into a charmonium $H$, the $R_H$ and the helicity dependent ratios are defined as \begin{eqnarray} R_H&=& \frac{\Gamma(B_c\to H+\tau +\bar\nu_\tau)}{\Gamma(B_c\to H+\mu +\bar\nu_\mu)},\\ R^L_H&=& \frac{\Gamma_L(B_c\to H+\tau +\bar\nu_\tau)}{\Gamma_L(B_c\to H+\mu +\bar\nu_\mu)},\\ R^\perp_H&=& \frac{\Gamma_\perp(B_c\to H+\tau +\bar\nu_\tau)}{\Gamma_\perp(B_c\to H+\mu +\bar\nu_\mu)}. \end{eqnarray} We give the branching ratios of $B_c\to H+\mu +\bar\nu_\mu $ in Tab.~\ref{tab:results1}. The ratios of the semitaunic and semimuonic $B_c$ decays into a charmonium $H$ are predicted in Tab.~\ref{tab:results2}. From this table, we can see the uncertainties are reduced for the $R_H$ since most uncertainties in form factors cancel. The SM prediction for $R_{J/\psi}$ is far below the LHCb data. If confirmed, this may indicate the possible new physics. In this case, these NP effects should also manifest themselves in the $B_c$ decays into P-wave charmonium, where we found the SM results for the ratios are even smaller. Enhancements of these ratios on the experimental side can reveal the presence of NP further. \begin{table}[thb] \caption{\label{tab:results1} Branching ratios (\%) of $B_c\to H+\mu +\bar\nu_\mu $ using the z-series expanded and LFQM form factors. } \begin{center} \begin{tabular}{cccc} \hline \hline Channels & LFQM~\cite{Wang:2008xt,Wang:2009mi} & z-series+NRQCD \\ \hline $ B_c \to \eta_c \mu \bar\nu_\mu$ & $0.67\pm0.10$ & $0.66\pm0.02$ \\ $ B_c \to J/\psi \mu \bar\nu_\mu$ & $1.49\pm0.27$& $1.44\pm0.02$ \\ $ B_c \to \chi_{c0} \mu \bar\nu_\mu$ & $0.21\pm0.04$ & $0.33^{+0.03}_{-0.02}$ \\ $ B_c \to \chi_{c1} \mu \bar\nu_\mu$ & $0.14\pm0.02$ &$0.11\pm0.03$ \\ $ B_c \to h_c \mu \bar\nu_\mu$ & $0.31\pm0.08$ & $0.17\pm0.02$\\ $ B_c \to \chi_{c2} \mu \bar\nu_\mu$ & $0.17\pm0.06$ & $0.17\pm0.04$ \\ \hline \hline \end{tabular} \end{center} \end{table} \begin{table}[thb] \caption{\label{tab:results2} Predictions for the $R_H$ in the z-series expansion approach, where the uncertainty in the z-Series approach is from the form factors, and the the uncertainty in the new physics predictions is from the new Wilson coefficients. } \begin{center} \begin{tabular}{ccccc} \hline \hline $R_H$ & LHCb data~\cite{Aaij:2017tyk} ~~& z-Series+NRQCD& S1 &S2\\ \hline $R_{J/\psi}$ &$0.71\pm0.17(stat)\pm0.18(syst)$ & $0.26\pm0.01$ & $0.32\pm0.02$ & $0.32\pm0.01$ \\ $R^L_{J/\psi}$ & & $0.24\pm0.01$ &$0.29\pm0.01$ & $0.28\pm0.01$\\ $R^\perp_{J/\psi}$ & & $0.29\pm0.01$ &$0.36\pm0.02$ & $0.35\pm0.01$\\ $R_{\eta_c}$ & & $0.31\pm0.01$ & $0.39\pm0.02$ & $0.41\pm0.02$ \\ $R_{\chi_{c0}}$ & & $0.11\pm0.01$ & $0.11\pm0.01$ & $0.12\pm0.01$ \\ $R_{\chi_{c1}}$ & & $0.10\pm0.01$ & $0.11\pm0.01$ & $0.12\pm0.01$ \\ $R^L_{\chi_{c1}}$ & & $0.10\pm0.01$ & $0.11\pm0.02$ & $0.13\pm0.01$\\ $R^\perp_{\chi_{c1}}$ & & $0.10\pm0.01$ & $0.11\pm0.01$ & $0.12\pm0.01$\\ $R_{h_c}$ & & $0.06^{+0.03}_{-0.01}$ &$0.08^{+0.03}_{-0.01}$& $0.08^{+0.03}_{-0.01}$\\ $R^L_{h_c}$ & & $0.06^{+0.02}_{-0.02}$ &$0.08^{+0.02}_{-0.02}$& $0.07^{+0.02}_{-0.02}$\\ $R^\perp_{h_c}$ & & $0.11^{+0.00}_{-0.01}$ &$0.18^{+0.01}_{-0.01}$& $0.17^{+0.01}_{-0.01}$ \\ $R_{\chi_{c2}}$ & & $0.04^{+0.00}_{-0.01}$ &$0.05^{+0.01}_{-0.01}$& $0.05^{+0.01}_{-0.01}$ \\ $R^L_{\chi_{c2}}$ & & $0.03\pm0.01$ &$0.04\pm0.01$& $0.04\pm0.01$ \\ $R^\perp_{\chi_{c2}}$ & & $0.05^{+0.01}_{-0.00}$ &$0.06^{+0.01}_{-0.01}$&$0.07^{+0.01}_{-0.01}$ \\ \hline \hline \end{tabular} \end{center} \end{table} The NP effects in $b\to c\tau\nu$ have been explored in a model-independent way in Refs.~\cite{Huang:2018nnq,Alok:2017qsi}, in which the following effective Hamiltonian is introduced: \begin{eqnarray} {\cal H}_{\rm eff}&=& \frac{4G_F}{\sqrt{2}} V_{cb}[(1+C_{V_1})O_{V_1} +C_{V_2}O_{V_2}+ C_{S_1}O_{S_1}+C_{S_2}O_{S_2}+C_{T}O_T], \end{eqnarray} where \begin{eqnarray} O_{V_1} = (\bar c_L\gamma^\mu b_{L})(\bar \tau_{L}\gamma_\mu \nu_{L}), \;\;\; O_{V_2} = (\bar c_R\gamma^\mu b_{R})(\bar \tau_{L}\gamma_\mu \nu_{L}). \end{eqnarray} The scalar and tensor operators have similar forms except the different Lorentz structures. The authors have fitted the data and obtained the constraints on the anomalous Wilson coefficients in different scenarios. The total $\chi^2/dof$ are at the same level, and thus in the following we will use the consider two scenarios with NP effects in $O_{V_1}$ (denoted as S1) and $O_{V_2}$ (denoted as S2). The fitted $C_{V_1}$ and $C_{V_2}$ read as:~\cite{Huang:2018nnq} \begin{eqnarray} [1+{\rm Re}(V_1)]^2+ {\rm Im}(C_{V_1})^2 =1.27\pm0.06,\;\;\; C_{V_2}= (0.057+0.573i) \pm (0.050+0.072i). \end{eqnarray} For the $O_{V_2}$ contribution to differential decay widths, the form factors defined by axial-vector current must reverse the sign. With these results, we obtain give the NP contributions to the ratios in Tab.~\ref{tab:results2}. \section{conclusion} In this paper, we have investigated the form factors of $B_c$ decays into the S-wave and P-wave charmonium in a model independent way. Unitary constraints combining Lattice QCD simulations and heavy quark limit constraints allow solid theoretical predictions. The new parametrization form we derived can greatly reduce the hadronic uncertainties. The theoretical prediction for $R_{J/\psi}$ is far below the LHCb experimental data, which is challenging the understanding of the fundamental theory of SM. It is worthwhile to independently study the helicity-dependent observations such as $R^L_{J/\psi}$ and $R^\perp_{J/\psi}$ in experiments. Besides, other observations $R_H$ for $B_c$ decays into the S-wave and P-wave charmonium are also helpful to check the lepton flavor universality. Our analyses can be straightforwardly extended to other $b\to c$ transitions like the $\Lambda_b\to \Lambda_c/\Lambda_c^*$, or even the doubly bottom baryons $\Xi_{bb}/\Omega_{bb}$ decays into $\Xi_{bc}/\Omega_{bc}$. The latter category has small production rates at LHC and smaller branching fractions~\cite{Li:2017ndo,Wang:2017mqp,Wang:2017azm}, making it less impressive at this stage. \section*{Acknowledgments} We thank the discussions with Prof.~Cai-Dian L\"u, Prof.~Ying Li, and Dr.~Zhuo-Ran Huang. This work is supported in part by National Natural Science Foundation of China under Grant No.~11575110, 11655002, 11705092,11735010, by Natural Science Foundation of Jiangsu under Grant No.~BK20171471, by the Young Thousand Talents Plan, by Natural Science Foundation of Shanghai under Grant No.~15DZ2272100, by Key Laboratory for Particle Physics, Astrophysics and Cosmology, Ministry of Education.
\section{Deferred proofs} \subsection{Proof of Property~\ref{property:Pi_projection}} I draw up an inductive argument demonstrating that $\Pi$ is a projection matrix. The \textit{base case}, i.e., that $A_{c} = P_{c}^+ P_{c}$ is a projection matrix follows by the definition of the pseudo-inverse: $A_{c} A_{c} = P_{c}^+ P_{c} P_{c}^+ P_{c} = P_{c}^+ P_{c} = A_c$, where one uses the property $P_c = P_{c} P_{c}^+ P_{c}$. For the \textit{inductive step}, I argue that if $ A_{\ell+1} $ is a projection matrix the same holds for $$ A_{\ell} = P_{\ell}^+ \, A_{\ell+1} \, P_{\ell}. $$ To this end, let $P_{\ell} = U \Sigma V^\top$ be the singular-value decomposition with $\Sigma = (D; 0) \in \mathbb{R}^{N_{\ell+1} \times N_{\ell}}$ decomposed into the $N_{\ell+1} \times N_{\ell+1}$ diagonal matrix $D$ and the all zero matrix $0$. Then $$ A_{\ell} = V \Sigma^+ U^\top A_{\ell+1} \, U \Sigma V^\top. $$ Recalling that a projection matrix remains projective if it undergoes a similarity transformation, we deduce that $U^\top A_{\ell+1} \, U$ is also projective and, moreover, if $\Sigma^+ U^\top A_{\ell+1} \, U \Sigma$ is a projection matrix, so is $A_{\ell}$. However, one may write $$ \Sigma^+ U^\top A_{\ell+1} \, U \Sigma = \left(\begin{array}{@{}cc@{}} D^{-1} & 0 \\ 0 & 0 \end{array}\right) U^\top A_{\ell+1} \, U \left(\begin{array}{@{}cc@{}} D & 0 \\ 0 & 0 \end{array}\right) = \left(\begin{array}{@{}cc@{}} D^{-1} U^\top A_{\ell+1} \, U D & 0 \\ 0 & 0 \end{array}\right). $$ As a block diagonal matrix whose blocks are projective (again $D^{-1} U^\top A_{\ell+1} \, U D$ is a similarity transformation), $\Sigma^+ U^\top A_{\ell+1} \, U \Sigma$ is also a projection matrix. The proof that $\Pi$ is a projection matrix concludes by letting the induction unfold backwards from $c$ to 1 and setting $\Pi = A_1$. \subsection{Proof of Proposition~\ref{proposition:pseudo-inverse}} For notational convenience, I drop the level index supposing that $c=1$ and thus $P$ is an $n\times N$ coarsening matrix. As we will see in the following, $P$ has rank $n$ and thus to prove that $P^+ = {P}^\top D^{-2}$, it is sufficient to show that matrix $\Pi = {P}^\top D^{-2} P$ is a projection matrix of rank $n$ (and thus equal to $P^+ P$). Matrix $\tilde{P} = D^{-1} P$ has the same sparsity structure as $P$ and is thus also a coarsening matrix. W.l.o.g. let the rows of $P$ be sorted based on their support, such that for any two rows $r<r'$ and $P(r,i), P(r',i') \neq 0$ we necessarily have $i<i'$. Furthermore, denote by $p_r$ the vector containing all non-zero entries of $P(r,:)$ such that $\norm{p_r}_2 = \norm{P(r,:)}_2 = D(r,r)$. Due to the disjoint support of the rows of $P$ and under this particular sorting, matrix $\Pi$ is block-diagonal. Moreover, each block $B_r$ in its diagonal is a rank 1 projection matrix as $B_r^2 = B_r B_r = \left(p_r D(r,r)^{-2} p_r^\top\right) \left(p_r D(r,r)^{-2} p_r^\top\right) = p_r D(r,r)^{-2} p_r^\top \frac{p_r^\top p_r}{\norm{p_r}_2^2} = B_r$. We have thus arrived to the relation $\Pi^2 = \Pi$, which constitutes a necessary and sufficient condition for $\Pi$ to be a projection matrix. The block-diagonal structure of $\Pi$ also implies that its rank (as well as that of $P$) is $n$. \subsection{Proof of Proposition~\ref{proposition:proper_laplacian}} Let us first remark that, by Proposition~\ref{proposition:pseudo-inverse}, $A = P^\mp$ is also a coarsening matrix with the same sparsity structure as $P$. \textit{Necessity.} I start by considering the nullspace of $\c{L} = A L A^\top$ and aim to ensure that it is equal to the span of the constant vector $1$, which is a necessity for all combinatorial Laplacian matrices. Since matrix $A$ is full row-rank and $L$ has rank $N-1$, the nullspace of $L_c$ is one dimensional. Therefore, the nullspace is correct as long as $ 1^\top A L A^\top 1 = 0$, which happens if either $A^\top 1 = \alpha 1$ for a constant $\alpha$ or $A^\top 1 = 0$. In both cases, $(A^\top 1)(r) = \alpha 1$ for every $r$. By the definition of $A$ however, we know that its rows have disjoint support and, as such, vector $A^\top 1$ exactly contains the non-zero entries of $A$. In other words, for the nullspace of $\c{L}$ to be properly formed, the non-zero entries of $A$ should either all be equal to $\alpha$ (such that $A^\top 1 = \alpha 1$) or zero (in which case $A^\top 1 = 0$). The latter case can clearly be discarded as it would disconnect the graph. We have thus discovered that $A L A^\top$ has a properly formed nullspace if and only if the non-zero entries of $A$ are equal, rendering the latter condition necessary. \textit{Sufficiency.} Considering that every Laplacian of $M$ edges can be re-written as $L = S^\top S$, where $S$ is the $M\times N$ incidence matrix, one may confirm that the condition is also sufficient by showing that, for every $A$ with equal non-zero entries, the matrix $\c{S} = S A^\top $ is an incidence matrix of $\c{L}$ such that $\c{L} = \c{S}^\top \c{S}$. W.l.o.g., suppose that $\alpha=1$ ($\alpha^2 L$ is a valid Laplacian for all $\alpha$). By construction, each row of $\c{S}$ is $\c{S}(q,:)^\top = A S(q,:)^\top$. Name as $e_{ij}$ the corresponding edge, such that $S(q,:)^\top = \delta_i - \delta_j$, where $\delta_i$ is a dirac centered at vertex $v_i$. It follows that $\c{S}(q,:)^\top = A \delta_i - A \delta_j $. Obviously, if none of $v_i,v_j$ are coarsened then $\c{S}(q,:)^\top = \delta_i - \delta_j$, which is a valid row. Moreover, by construction of $A$, if either of $v_i,v_j$ is coarsened (but not both) or if $v_i,v_j$ are coarsened into different vertices then both relations $A \delta_i = \delta_i$ and $A \delta_j = \delta_j$ hold and thus once more $\c{S}(q,:)^\top = \delta_i - \delta_j$ is a valid row. Lastly, if $v_i,v_j$ are coarsened into the same vertex then for some $r$ it must be that $A(r,i) = A(r,j)$, whereas $A(r',i) = A(r',j) = 0$ for all $r' \neq r$ and thus $\c{S}(r,:)^\top = 0$, signifying that the edge is not present. Summarizing, in every case $\c{S}$ is a valid incidence matrix, rendering the condition also sufficient. \subsection{Proof of Property~\ref{claim:cuts}} For any two disjoint subsets $\S_1, \S_2$ of $\V$ denote by $w(\S_1, \S_2) = \sum_{v_i \in \S_1} \sum_{v_j \in \S_j} w_{ij}$ the cut weight in $G$. The claim is proven by induction on the number of levels. For the base case set $\ell = 1$ and define $C = P_1^+$ such that $c_r = C(:,r)$ is the indicator vector of the contraction set $\V_{0}^{(r)}$. It is a consequence of the Laplacian form of $L$ that, for any $v_r, v_q \in \V_1$ with $r\neq q$, we have \begin{align} W_1(r,q) = -L_1(r,q) = -c_r^\top L c_q &= \sum_{v_i \neq v_j} w_{ij} c_r(i) c_q(j) + \sum_{v_i} d_i c_r(i) c_q(i) \notag \\ &= \hspace{-4mm} \sum_{v_i \in \V_{0}^{(r)}, v_j \in \V_{0}^{(q)}} \hspace{-7mm} w_{ij} = w(\mathcal{S}_1^{(r)}, \mathcal{S}_1^{(q)}), \notag \end{align} where the penultimate step uses $c_r(i)c_q(i) = 0$ since contraction steps are disjoint, and the last step exploits the equivalence $\V_{0}^{(q)} = \mathcal{S}_{1}^{(q)}$. For the inductive step, consider level $\ell> 1$. Since $L_{\ell-1}$ is a Laplacian matrix, one may employ an identical argument as when $\ell=1$ to find that the weight between vertices $v_r,v_q \in \V_{\ell}$ with $r\neq q$ is $$ W_\ell(r,q) = \hspace{-4mm} \sum_{v_i \in \V_{\ell-1}^{(r)}, v_j \in \V_{\ell-1}^{(q)}} \hspace{-7mm} W_{\ell-1}(i,j).$$ By the induction hypothesis however, it must be $W_{\ell-1}(i,j) = w(\mathcal{S}_{\ell-1}^{(i)}, \mathcal{S}_{\ell-1}^{(j)})$, implying $$ W_\ell(r,q) = \hspace{-4mm} \sum_{v_i \in \V_{\ell-1}^{(r)}, v_j \in \V_{\ell-1}^{(q)}} \hspace{-7mm} w(\mathcal{S}_{\ell-1}^{(i)}, \mathcal{S}_{\ell-1}^{(j)}) = w(\mathcal{S}_{\ell}^{(r)}, \mathcal{S}_{\ell}^{(q)}),$$ with the final equality being true due to the recursive definition of sets $\mathcal{S}_{\ell}^{(r)}$ and $\mathcal{S}_{\ell}^{(q)}$, as well as the following property of cuts: for any two sets (call them large sets) and any partition of each into an arbitrary number of subsets, the cut between the large sets is equal to the sum of all cuts between pairs of subsets belonging to different large sets. This completes the proof. \subsection{Proof of Theorem~\ref{theorem:interlacing}} The Courant-Fischer min-max theorem for a Hermitian matrix $L$ reads \begin{align} \lambda_k = \min\limits_{\dimension{\mathbf{U}} = k} \max\limits_{x \in \mathbf{U}} \left\{ \frac{x^\top L x}{x^\top x} \, | \, x \neq 0 \right\}, \label{eq:courant_lambda_k} \end{align} whereas the same theorem for $\c{L}$ gives \begin{align} \p{\lambda}_k = \min\limits_{\dimension{\c{\mathbf{U}}} = k} \max\limits_{\c{x} \in \c{\mathbf{U}}} \ \left\{ \frac{\c{x}^\top \c{L} \c{x}}{\c{x}^\top \c{x}} \, | \, \c{x} \neq 0 \right\} &= \min\limits_{\dimension{\c{\mathbf{U}}} = k} \max\limits_{P x \in \c{\mathbf{U}}} \left\{ \frac{ x^\top \Pi L \Pi x}{x^\top P^\top P x} \, | \, x \neq 0 \right\} , \notag \end{align} where in the second equality I substitute $ \c{L} = P^\mp L P^+$ and $\c{x} = P x $. We will need the following result: \begin{lemma} For any $P$ with full-row rank, the following holds: $$ \lambda_{1}(P P^\top) \, x^\top \Pi x \leq x^\top P^\top P x \leq \lambda_{n}(P P^\top) \, x^\top \Pi x,$$ % with $\lambda_1(P P^\top)$ and $\lambda_n(P P^\top)$, respectively the smallest and largest eigenvalues of $P P^\top$. \label{lemma:projection} \end{lemma} \begin{proof} Set $D = (P P^\top)^{+}$, which is an $n\times n$ PSD matrix. By the properties of the Moore–Penrose inverse $P^+ = P^\top (P P^\top )^{+} = P^\top D $ and therefore $ P^\top P = P^\top D D^{-1} P = P^+ D^{-1} P $. Supposing that the eigenvalues of $D$ lie in $[\alpha, \beta]$ and that $P$ is full row-rank such that $\alpha> 0$, one may write $$ \frac{1}{\beta} \, x^\top \Pi x \leq x^\top P^\top P x = x^\top P^+ D^{-1} P x \leq \frac{1}{\alpha} \, x^\top \Pi x.$$ To grasp why the aforementioned inequality holds, first use the cyclic property of the trace to obtain $$x^\top P^+ D^{-1} P x = \trace{x^\top P^+ D^{-1} P x} = \trace{D^{-1} P xx^\top P^+ },$$ and further recall that for any symmetric $A$ and PSD matrix $B$ one has $\lambda_{\text{min}}(A) \trace{B} \leq \trace{A B} \leq \lambda_{\text{max}}(B) \trace{B}$, where $\lambda_{\text{min}}(A)$ denotes the smallest eigenvalue of $A$ (and $\lambda_{\text{max}}(A)$ is the largest)~\citep{fang1994inequalities}. Set $A = D^{-1}$, which is by assumption symmetric, and $B = P xx^\top P^+$, which is PSD since its rank is (at most) one with the only (potentially) non-zero eigenvalue exactly $\trace{P xx^\top P^+} = x^\top P^+ P x = x^\top \Pi x = x^\top \Pi^2 x= \|\Pi x\|_2^2 \geq 0$. The desired inequality then follows since $ \lambda_{\text{min}}(D^{-1}) = 1/\lambda_{\text{max}}(D) = \frac{1}{\beta}$, $ \lambda_{\text{max}}(D^{-1}) = 1/\lambda_{\text{min}}(D) = \frac{1}{\alpha}$ and once more $\trace{P xx^\top P^+} = x^\top \Pi x$. Finally, since $P$ is full row-rank, $D$ is invertible meaning $\alpha = \lambda_{\text{min}}(D) = 1/ \lambda_{n}(P P^\top)$ and $\beta = \lambda_{\text{max}}(D) = 1/ \lambda_{1}(P P^\top)$. \end{proof} From the above, it is deduced that \begin{align} \p{\lambda}_k &\geq \min\limits_{\dimension{\c{\mathbf{U}}} = k} \max\limits_{P x \in \c{\mathbf{U}}} \left\{ \frac{ x^\top \Pi L \Pi x}{ \lambda_{n}(P P^\top) \, x^\top \Pi x} \, | \, x \neq 0 \right\} \notag \\ &\hspace{-4mm}= \frac{1}{\lambda_{n}(P P^\top)} \min_{\dimension{\mathbf{U}} = k, \mathbf{U} \subseteq \text{im}(\Pi) } \max_{x \in \mathbf{U}} \left\{ \frac{x^\top L x}{x^\top x} \, | \, x \neq 0 \right\} , \notag \end{align} where the equality holds since $\Pi$ is a projection matrix (see Property~\ref{property:Pi_projection}). Notice how, with the exception of the constraint $x = \Pi x$ and the multiplicative term, the final optimization problem is identical to the one for $\lambda_k$, given in~\eqref{eq:courant_lambda_k}. As such, the former's solution must be strictly larger (since it is a more constrained problem) and $\p{\lambda}_k \geq \frac{\lambda_k}{\lambda_{n}(P P^\top)} $. Analogously, one obtains the lower inequality $ \p{\lambda}_{k-(N-n)} \leq \frac{\lambda_k}{\lambda_1(PP^\top)}$ by applying the same argument on matrices $-L$ and $-\c{L}$ and exploiting that the $k$-th largest eigenvalue of any matrix $M$ is also the $k$-th smallest eigenvalue of $-M$. \subsection{Proof of Theorem~\ref{theorem:eigenvalues}} The lower bound is given by Theorem~\ref{theorem:interlacing}. For the upper bound, I reason similarly to the proof of the latter to find: \begin{align} \p{\lambda}_k &= \min\limits_{\dimension{\c{\mathbf{U}}} = k} \max\limits_{\c{x} \in \c{\mathbf{U}}} \ \left\{ \frac{\c{x}^\top \c{L} \c{x}}{\c{x}^\top \c{x}} \, | \, \c{x} \neq 0 \right\} \notag &\leq \gamma_2 \min\limits_{\dimension{\mathbf{U}} = k, \textbf{U} \subseteq \image{\Pi}} \max\limits_{x \in \mathbf{U}} \left\{ \frac{x^\top \Pi L \Pi x}{x^\top \Pi x} | \, x \neq 0 \right\}. \notag \end{align} Above, the inequality is due to Lemma~\ref{lemma:projection} with $\gamma_2 = 1 / \lambda_{1}(PP^\top)$. Thus, for any matrix $V$ the following inequality holds \begin{align} \p{\lambda}_k \leq \gamma_2 \max\limits_{x \in \spanning{V}} \left\{ \frac{x^\top \Pi L \Pi x}{x^\top \Pi x} \, | \, x \neq 0 \right\}, \notag \end{align} as long as the image of $V$ is of dimension $k$ and does not intersect the nullspace of $\Pi$. Write $U_{k}$ to denote the $N \times k$ matrix with the $k$ first eigenvectors of $L$, whose image is of dimension $k$ as needed. Assume for now that the nullspace requirement is also met: \begin{align} \p{\lambda}_k &\leq \gamma_2 \max\limits_{x \in \spanning{U_k}} \left\{ \frac{x^\top \Pi L \Pi x}{x^\top \Pi x} \, | \, x \neq 0 \right\} \notag = \gamma_2 \max\limits_{x \in \spanning{U_k}} \left\{ \frac{\|S \Pi x\|_2^2}{\|\Pi x\|_2^2 } \, | \, x \neq 0 \right\}. \end{align} It will be convenient to manipulate the square-root of this quantity: \begin{align} \sqrt{\frac{\p{\lambda}_k}{\gamma_2}} \leq \max\limits_{a \in \mathbb{R}^{k}} \frac{\|S \Pi U_k a\|_2}{\| \Pi U_k a\|_2} = \frac{\|S \Pi U_k\|_2}{\|\Pi U_k\|_2} \leq \frac{\|S U_k\|_2 + \|S \Pi^\bot U_k\|_2}{\| \Pi U_k\|_2} &=\frac{\sqrt{\lambda_k} + \|S \Pi^\bot U_k\|_2}{\| \Pi U_k\|_2}, \label{eq:eigenvalue_intermediate_2} \end{align} with $S$ defined such that $L = S^\top S.$ The norm in the numerator is upper bounded by \begin{align} \|S \Pi^\bot U_k\|_2 = \|S \Pi^\bot U_k \Lambda_k^{-\sfrac{1}{2}} \Lambda_k^{\sfrac{1}{2}}\|_2 &\leq \|S \Pi^\bot U_k \Lambda_k^{+\sfrac{1}{2}} \|_2 \|\Lambda_k^{\sfrac{1}{2}}\|_2 \notag \\ &= \sqrt{\lambda_k} \, \|S \Pi^\bot U_k \Lambda_k^{+\sfrac{1}{2}} \|_2 = \sqrt{\lambda_k} \,\epsilon_k. \notag \end{align} If the last step is not immediately obvious, one can be convinced by first exploiting the unitary-invariance of the spectral norm to write $\|S \Pi^\bot U_k \Lambda_k^{+\sfrac{1}{2}} \|_2 = \|S \Pi^\bot U_k U_k^\top L^{+\sfrac{1}{2}} \|_2$, and then confirming in the proof of Proposition~\ref{proposition:restricted_similarity} that the latter quantity is exactly $\epsilon_k$ when $V = U_k$. The preceding analysis assumed that the image of $U_k$ and the nullspace of $\Pi$ did not intersect. Since $\Pi^\bot = I - \Pi$ is a complement projection matrix , the previous holds when $ \| \Pi^\bot U_k\|_2^2 < 1$. Since $\| \Pi^\bot u_1\| = 0$, one may w.l.o.g. exclude $u_1$ from the space of interest. For the remainder of $\image{U_k}$ the following holds: $$\| \Pi^\bot U_k\|_2^2 = \max_{x \in \mathbf{U}_k \text{ and } x \bot u_1} \frac{\|\Pi^\bot x\|_2^2 }{\|x\|_2^2} \leq \frac{1}{\lambda_2} \max_{x \in \mathbf{U}_k \text{ and } x \bot u_1} \frac{\| \Pi^\bot x \|_L^2}{\|x\|_2^2} = \epsilon_k^2 \frac{\lambda_k}{\lambda_2}. $$ Therefore, when $\epsilon_k^2 < \frac{\lambda_2}{\lambda_k}$, the nullspace condition is met. The proof is then concluded by substituting the bound $ \|\Pi U_k\|_2^2 = { 1- \|\Pi^\bot U_k\|_2^2} \geq { 1- \epsilon_k^2 \frac{\lambda_k}{\lambda_2}} $ in the denominator of~\eqref{eq:eigenvalue_intermediate_2}. \subsection{Proof of Theorem~\ref{theorem:sintheta}} \citet{li1994relative} showed that we can express the sin$\Theta$ as a sum of squared inner products: \begin{align} \norm{ \sintheta{U_k}{P^\top \p{U}_k} }_F^2 &= \norm{\p{U}_{k^\bot}^\top P U_k}_F^2 = \sum_{i \leq k} \sum_{j > k} (\p{u}_j^\top P u_i)^2 \label{eq:sintheta_0} \end{align} If $L_c$ and $L$ are $(\mathbf{U}_i, \epsilon_i)$-similar it follows from Corollary~\ref{corollary:restricted_isometry} that $$u_i^\top P^\top \c{L} P u_i \leq (1+\epsilon_i)^2 \lambda_i. $$ Summing these inequalities for all $i \leq k$ amounts to \begin{align} \sum_{i \leq k} (1 + \epsilon_i)^2\lambda_i \geq &\sum_{i \leq k} \sum_{j = 1}^n \p{\lambda}_j (\p{u}_j^\top P u_i)^2 \notag \\ &\geq \gamma_1 \sum_{i \leq k} \sum_{j = 1}^n \lambda_j (\p{u}_j^\top P u_i)^2 \notag \\ &= \gamma_1 \sum_{j \leq k} \lambda \sum_{i \leq k} (\p{u}_j^\top P u_i)^2 + \gamma_1 \sum_{j > k} \lambda_j \sum_{i \leq k} (\p{u}_j^\top P u_i)^2. \label{eq:sintheta_1} \end{align} where following Theorem~\ref{theorem:interlacing} I set $\gamma_1 = 1/\lambda_n(P P^\top)$, such that $\tilde{\lambda}_i \geq \gamma_1 \lambda_i $. Perform the following manipulation: \begin{align} \sum_{j \leq k} \lambda_j \sum_{i \leq k} (\p{u}_j^\top P u_i)^2 \geq \sum_{j \leq k} \lambda_j \sum_{i \leq k} (\p{u}_j^\top P u_i)^2 &= \sum_{j \leq k} \lambda_j \left( 1 - \sum_{i > k} (\p{u}_j^\top P u_i)^2 \right) \notag \\ &\hspace{-10mm}\geq \sum_{j \leq k} \lambda_j - \lambda_k \sum_{i \leq k} \left( \| \Pi^\bot u_i\|_2^2 + \sum_{j \geq k} (\p{u}_j^\top P u_i)^2 \right), \notag \end{align} which together with~\eqref{eq:sintheta_0} and~\eqref{eq:sintheta_1} yields \begin{align} \norm{ \sintheta{U_k}{P^\top \p{U}_k} }_F^2 &\leq \sum\limits_{i \leq k} \frac{ (1 + \epsilon_i)^2\lambda_i/\gamma_1 - \lambda_i + \lambda_k \| \Pi^\bot u_i \|_2^2 }{\lambda_{k+1} - \lambda_{k}} \end{align} To proceed, I note the following useful inequality: \begin{lemma} If $L$ and $L_c$ are $(\mathbf{U}_i,\epsilon_i)$-similar, then $\| \Pi^\bot u_i\|_2^2 \leq \epsilon_i$. \label{lemma:pinorm} \end{lemma} \begin{proof} For every $u_i$ one sees that \begin{align} u_i^\top P^\top \c{L} P u_i = u_i^\top \Pi L \Pi u_i &= u_i^\top (I - \Pi^\bot) L (I - \Pi^\bot) u_i \notag \\ &= u_i^\top L u_i - 2 u_i^\top L \Pi^\bot u_i + u_i^\top \Pi^\bot L \Pi^\bot u_i \notag \\ &= \lambda_i - 2 \lambda_i u_i^\top \Pi^\bot u_i + u_i^\top \Pi^\bot L \Pi^\bot u_i \notag \end{align} meaning that \begin{align*} \| \Pi^\bot u_i\|_2^2 = \frac{1}{2} \left( 1 + \frac{u_i^\top \Pi^\bot L \Pi^\bot u_i}{\lambda_i} - \frac{u_i^\top P^\top \c{L} P u_i}{\lambda_i}\right) \leq \frac{1}{2} \left( 1 + \epsilon_i^2 - (1 - \epsilon_i)^2 \right) = \epsilon_i. \end{align*} The last inequality is because, by restricted spectral approximation, we have $u_i^\top \Pi^\bot L \Pi^\bot u_i = \|\Pi^\bot u_i\|_L^2 \leq \epsilon_i^2 \|u_i\|_L^2 = \epsilon_i^2 \lambda_i$ and from Corollary~\ref{corollary:restricted_isometry}: $$u_i^\top P^\top \c{L} P u_i = \|P u_i\|_{L_c}^2 \geq (1 - \epsilon_i)^2 \|u_i\|_L^2 = (1 - \epsilon_i)^2 \lambda_i.$$ \end{proof} As a consequence, it follows that \begin{align} \norm{ \sintheta{U_k}{P^\top \p{U}_k} }_F^2 &\leq \sum\limits_{i \leq k} \frac{ (1 + \epsilon_i)^2\lambda_i/\gamma_1 - \lambda_i + \lambda_k \epsilon_i }{\lambda_{k+1} - \lambda_{k}}, \notag \end{align} which after manipulation gives the desired inequality. \subsection{Proof of Theorem~\ref{theorem:cheeger}} The lower bound is a direct consequence of consistent coarsening and holds independently of restricted spectral approximation: for any set $\mathcal{S}_c \subset \mathcal{V}_c$ define $\mathcal{S} \subset \mathcal{V}$ such that $v_i \in \mathcal{S}$ if and only if $\varphi_c \circ \varphi_{c-1} \circ \cdots \varphi_1(v_i) \in \mathcal{S}_c$. Clearly, $w(\mathcal{S}) \geq w_c(\mathcal{S}_c)$, where the subscript $c$ implies that the latter volume is w.r.t. $G_c$. In addition, by the definition of Laplacian consistent coarsening and since every contraction set belongs either in $\mathcal{S}$ or $\bar{\mathcal{S}}$ (but not in both), it follows that $w(\mathcal{S}, \bar{\mathcal{S}}) = w_c(\mathcal{S}_c, \bar{\mathcal{S}}_c)$. In other words, for every $\mathcal{S}_c$ there exists a set $\mathcal{S}$ such that $$\phi(\mathcal{S}) = \frac{ w(\mathcal{S}, \bar{\mathcal{S}}) }{ \min\{w(\mathcal{S}), w(\bar{\mathcal{S}})\} } \leq \frac{ w_c(\mathcal{S}_c, \bar{\mathcal{S}_c}) }{ \min\{w_c(\mathcal{S}_c), w_c(\bar{\mathcal{S}}_c)\} } = \phi_c(\mathcal{S}_c),$$ implying also that the $k$-conductance of $G$ and $G_c$ are related by $\phi_k(G) \leq \phi_k(G_c)$. For the upper bound, I exploit the following multi-way Cheeger inequality: \begin{theorem}[Restatement of Theorem 1.2 by~\cite{lee2014multiway}] For every graph $G$ and every $k \in \mathbb{N}$, we have $$ \frac{\mu_{k}}{2} \leq \phi_{k}(G) = O(\sqrt{\mu_{2k} \, \xi_k(G)}), $$ with $\xi_k(G) = \log{k}$. If $G$ is planar then $\xi_{k}(G) = 1.$ More generally, if $G$ excludes $K_h$ as a minor, then $\xi_{k}(G) = h^4.$ \end{theorem} Further, in the standard Cheeger inequality~\citep{alon1985lambda1,alon1986eigenvalues} ($k=2$) the upper bound is $\sqrt{2 \mu_2}$. Note that the eigenvalues mentioned here are those of the normalized Laplacian matrix $L^n = D^{-\sfrac{1}{2}} L D^{-\sfrac{1}{2}}$. To this end, suppose that $V_{2k}$ contains the first ${2k}$ eigenvectors of $L^n$ and fix $\mathbf{R} = \spanning{D^{-\sfrac{1}{2}} V_{2k}}$. Perform consistent coarsening w.r.t. to the combinatorial Laplacian $L$ (not $L^n$). Then, by definition, if $L_c$ and $L$ are $(\epsilon_{2k}, \mathbf{R})$-similar then for every $x \in \mathbf{R}$ one gets \begin{align*} \|\Pi^\bot x\|_{L} \leq \epsilon_{2k} \|x\|_L. \end{align*} The substitution $y = D^{\sfrac{1}{2}} x$, such that $y \in \spanning{V_{2k}}$, allows us to transform the semi-norms above into semi-norms concerning $L^n$ as follows: $$ \|x\|_L^2 = x^\top L x = y^\top D^{-\sfrac{1}{2}} L D^{-\sfrac{1}{2}} y = \|y\|_{L^n}^2 $$ and $$ \|\Pi^\bot x\|_{L} = \|D^{-\sfrac{1}{2}} D^{\sfrac{1}{2}} \Pi^\bot D^{-\sfrac{1}{2}} D^{\sfrac{1}{2}} x\|_{L} = \|D^{\sfrac{1}{2}} \Pi^\bot D^{-\sfrac{1}{2}} y\|_{L^{n}} = \|(I - \Pi^{n}) y\|_{L^{n}}. $$ Above, $\Pi^n = D^{\sfrac{1}{2}} \Pi D^{-\sfrac{1}{2}} $ is the projection matrix (the set of projection matrices is closed under similarity transformations) corresponding to the coarsening matrix $P^n = P D^{-\sfrac{1}{2}}$, and now $y_c = \Pi^n y$. It follows that, for every $y \in \mathbf{V}_{2k} = \spanning{V_{2k}}$, we have \begin{align*} \|y - \Pi^n y\|_{L^n} \leq \epsilon_{2k} \|y\|_{L^n} \end{align*} and thus $L_c^n$ and $L^n$ are $(\mathbf{V}_{2k}, \epsilon_{2k})$-similar. Combining the multi-way Cheeger inequality with Theorem~\ref{theorem:eigenvalues} for $L_c^n$ and $L^n$ one obtains \begin{align*} \phi_{k}^2(G_c) &= O \left( \tilde{\mu}_{2k} \, \xi_k(G)\right) \\ &= O\left( \gamma_2 (1 + \epsilon_{2k})^2 \frac{ \mu_2 }{\mu_2 - \epsilon_{2k} \mu_{2k} } \mu_{2k} \, \xi_{k}(G) \right) \\ &= O\left( \frac{ \gamma_2 \, (1 + \epsilon_{2k})^2 \xi_{k}(G) }{1 - \epsilon_{2k}^2 (\mu_{2k}/\mu_2)} \phi_k(G) \right), \end{align*} where the eigenvalues above are those of $L^n$ and the preceeding holds whenever $\epsilon_{2k}^2 < \mu_{2}/\mu_{2k}$. Further, when $k=2$ the upper bound simplifies to $ \phi_{2}^2(G_c) \leq \frac{ 4 \, \gamma_2 \, (1 + \epsilon_{2})^2 }{1 - \epsilon_{2}^2} \phi_2(G). $ \subsection{Proof of Proposition~\ref{proposition:lower_bound}} Write $\mathcal{P} = \{\S_1, \S_2, \ldots, \S_n\}$ to denote a partitioning of $\V$ into $n$ disjoint clusters. In matrix form, the $n$-means problem performed on $U_k$ corresponds to finding a map $\varphi : \V \rightarrow \mathcal{P}$ between points $x_i = U_k(i,:)$ and clusters $\S_1, \S_2, \ldots, \S_n$ that minimizes the following cost function: $$ \kmeans{n}{U_k}{\mathcal{P}} = \sum_{i = 1}^N \left( x_i - \hspace{-2mm}\sum_{v_j \in \varphi(v_i)} \frac{x_j}{|\varphi(v_i)|} \right)^2 = \| U_k - C^\top C U_k\|_F^2,$$ where the cluster indicator matrix $C \in \mathbb{R}^{n \times N}$ has as entries $$ C(r,j) = % \begin{cases} 1/\sqrt{|\S_r|} & \text{if } v_i \in \S_r \\ 0 & \text{otherwise.} \end{cases} $$ It may be confirmed that $C$ is a proper coarsening matrix corresponding to the case that clusters are exactly contraction sets. In addition, since $C^\top = C^+$ the matrix $C^\top C$ is the familiar projection matrix associated with coarsening. In fact, the latter is exactly equivalent to the projection matrix $\Pi = P^+ P$ of a single level Laplacian consistent coarsening. To see this, construct the diagonal matrix $Q$ with $Q(r,r) = \sqrt{|\S_r|}$ and write $C^\top C = C^\top Q Q^{-1} C = P^+ P = \Pi$. With this in place, we can re-write the $n$-means problem as $$ \kmeans{n}{U_k}{\mathcal{P}} = \| U_k - \Pi U_k\|_F^2 = \| \Pi^\bot U_k\|_F^2 = \sum_{i\leq k} \| \Pi^\bot u_i\|_2^2 \leq \sum_{i\leq k} \epsilon_i, $$ where $\epsilon_i$ is the smallest constant such that $L_c = P^\pm L P^+$ and $L$ are $(\mathbf{U}_i, \epsilon_i)$-similar and the inequality follows from Lemma~\ref{lemma:pinorm}. The final lower bound is then achieved by minimizing over all maps $\varphi$. \subsection{Proof of Proposition~\ref{proposition:restricted_similarity}} The following analysis is slightly more general than what is claimed in the statement of Proposition~\ref{proposition:restricted_similarity}: it holds for arbitrary PSD $L$ and $L_c$ (i.e., not necessarily Laplacian matrices) as long as the image $\image{\Pi}$ of the projection matrix $\Pi$ encloses the nullspace of $L$. The former trivially holds for Laplacian consistent coarsening, as, by design, one has $\Pi 1 = 1$ (see Section~\ref{subsec:consistent_coarsening}). Let $V \in \mathbb{R}^{N\times k}$ be a basis of $\mathbf{R}$. I start by proving that, for any integer $k\leq n$ and for all $x \in \spanning{V}$ the inequality \begin{align} \|x - \Pi x\|_{L} \leq \epsilon \, \norm{x}_L \notag \end{align} holds for all $\epsilon \geq \|\Pi^\bot B_0\|_L$, where $B_0 = V V^\top L^{+\sfrac{1}{2}}$. I remind the reader that $\|x\|_L = \|S x \|_2 = \|L^{\sfrac{1}{2}} x\|_2$ and $\Pi^\bot = I - P^+P$. Furthermore, since $\image{\Pi}$ necessarily encloses the nullspace $\mathbf{N}$ of $L$, w.l.o.g., one may assume that $ \forall x \in \mathbf{R}$ matrix $L$ is invertible. To see why, note that if $x\in \mathbf{N}$ then $\|x\|_L = 0$ and $\| x - \Pi x \|_L = 0$, meaning that the inequality above is trivially satisfied. I then derive \begin{align} \max\limits_{x \in \mathbf{R}} \frac{\|x - \Pi x\|_L}{\|x\|_L } &= \max\limits_{x \in \mathbf{R}} \frac{\| S \Pi^\bot x\|_{2}}{\|L^{\sfrac{1}{2}} x\|_2 } \notag \\ &= \max\limits_{x \in \mathbf{R}} \frac{\| S \Pi^\bot V V^\top x\|_{2}}{\|L^{\sfrac{1}{2}} x\|_2 } \label{eq:aa1} \\ &= \max\limits_{x \in \image{L V}} \frac{\| S \Pi^\bot V V^\top L^{+\sfrac{1}{2}} x\|_{2}}{\|x\|_2 } \label{eq:aa2} \\ &\leq \|S \Pi^\bot V V^\top L^{+\sfrac{1}{2}}\|_2 = \|\Pi^\bot B_0\|_L, \notag \end{align} where equality~\eqref{eq:aa1} holds because $VV^\top$ is a projection onto $\mathbf{R}$, whereas equality~\eqref{eq:aa2} is true since $L$ is invertible within $\mathbf{R}$. One should also note that, for the specific case where $V$ is an eigenspace of $L$, $\image{LV} = \textbf{R}$ and as such $\epsilon = \|\Pi^\bot x\|_{L} / \norm{x}_L = \|S \Pi^\bot V V^\top L^{+\sfrac{1}{2}}\|_2$ (once more w.l.o.g. the nullspace of $L$ can be ignored). In addition, as the following technical lemma claims, in a multi-level scheme, any $\|\Pi^\bot x\|_L$ can be broken down into the contributions of each level: \begin{lemma} Define projection matrices $\Pi_\ell = P_{\ell}^+ P_\ell$ and $\Pi_\ell^\bot = I - \Pi_\ell$. If \begin{align} \| \Pi^\bot_\ell x_{\ell-1} \|_{L_{\ell-1}} \leq \sigma_\ell \, \| x_{\ell-1} \|_{L_{\ell-1}} \quad \text{at each level } \ell \leq c, \notag \end{align} then the multi-level error is bounded by \begin{align} \|\Pi^\bot x\|_L \leq \left( \sum_{\ell= 1}^c \sigma_\ell \prod_{q = 1}^{\ell-1} ( 1 + \sigma_q) \right) \|x\|_L = \left(\prod_{\ell=1}^{c} ( 1 + \sigma_\ell) - 1\right) \|x\|_L.\notag \end{align} \label{lemma:leveling} \end{lemma} \begin{proof} Recursively apply the following inequality \begin{align} \norm{S_{\ell-1} \Pi^\bot_\ell x_{\ell-1}}_2 &\leq \sigma_\ell \norm{S_{\ell-1} x_{\ell-1}}_2 \notag \\ &= \sigma_\ell \norm{S_{\ell-2} \Pi_{\ell-1} x_{\ell-2}}_2 \notag \\ &\leq \sigma_\ell \left( \norm{S_{\ell-2} x_{\ell-2}}_2 + \norm{S_{\ell-2} \Pi_{\ell-1}^\bot x_{\ell-2}}_2\right) \notag \\ &\leq \sigma_\ell \left( \norm{S_{\ell-2} x_{\ell-2}}_2 + \sigma_{\ell-1} \norm{S_{\ell-2} x_{\ell-2}}_2\right) = \sigma_\ell \, ( 1 + \sigma_{\ell-1}) \norm{S_{\ell-2} x_{\ell-2}}_2 \notag \end{align} to deduce that \begin{align} \norm{S_{\ell-1} \Pi^\bot_{\ell} x_{\ell-1}}_2 &\leq \sigma_\ell \prod_{q = 1}^{\ell-1} ( 1 + \sigma_q) \| S_0 x_0\|_2 = \sigma_\ell \prod_{q = 1}^{\ell-1} ( 1 + \sigma_q) \|x\|_L. \notag \end{align} The end-to-end error $\| S \Pi^\bot x\|_2$ is controlled with a simple telescopic series argument. \begin{align} \| \Pi^\bot x\|_L = \| S_0 \Pi^\bot x_0\|_2 &= \| S_0 x_0 - S_{c} x_{c} \|_2 \notag \\ &\leq \| S_0 x_0 - S_{1} x_{1} \|_2 + \| S_1 x_1 - S_{2} x_{2} \|_2 + \ldots + \| S_{c-1} x_{c-1} - S_{c} x_{c} \|_2 \notag \\ &= \| S_0 \Pi_1^\bot x_{1} \|_2 + \| S_1 \Pi_1^\bot x_1 \|_2 + \ldots + \| S_{c-1} \Pi_c^\bot x_{c-1} \|_2 \notag \end{align} Together, the above two results imply the desired bound. \end{proof} Therefore, to guarantee that in a multi-level scheme \begin{align} \|\Pi^\bot B_0\|_L = \max_{b \in \mathbb{R}^N} \frac{\|S \Pi^\bot B_0 \, b \|_2}{\|b\|_2} \leq \epsilon, \notag \end{align} one needs to make sure that, for each level $\ell = 1, \ldots, c$, the following holds: \begin{align} \frac{\|S_{\ell-1} \Pi_{\ell}^\bot x_{\ell-1}\|_2}{\|S_{\ell-1} x_{\ell-1}\|_2} \leq \sigma_\ell, \quad \text{for all} \quad x_{\ell-1} = P_{\ell-1} \cdots P_{1} B_0\, b \notag \end{align} By the same argument used for the multi-level error, when $\ell=1$, we have that $\sigma_1 = \| \Pi_1^\bot B_0\|_{L_{0}}$. For all other $\ell$, set $B_{\ell-1} = P_{\ell-1} \cdots P_{1} B_0$ and further let $(B_{\ell-1}^\top L_{\ell-1} B_{\ell-1})^{+\sfrac{1}{2}}$ be the pseudo-inverse of the matrix square-root of the $N\times N$ matrix $B_{\ell-1}^\top L_{\ell-1} B_{\ell-1}$. By the substitution $b = S_{\ell-1} B_{\ell-1} a$, the above can be rewritten as \begin{align} \max_{b \in \mathbb{R}^N} \frac{\|S_{\ell-1} \Pi_{\ell}^\bot B_{\ell-1} b\|_2}{\|S_{\ell-1} B_{\ell-1} b \|_2} = \max_{b \in \mathbb{R}^N} \frac{\|S_{\ell-1} \Pi_{\ell}^\bot B_{\ell-1} (B_{\ell-1}^\top L_{\ell-1} B_{\ell-1})^{+\sfrac{1}{2}} b \|_2}{\|b \|_2}. \notag \end{align} For $\ell>1$, therefore $\sigma_{\ell} = \|\Pi_{\ell}^\bot A_{\ell-1} \|_{L_{\ell-1}} $ with $A_{\ell-1} = B_{\ell-1} (B_{\ell-1}^\top L_{\ell-1} B_{\ell-1})^{+\sfrac{1}{2}}$. \subsection{Proof of Proposition~\ref{proposition:decoupling}} For notational simplicity in the context of this proof I drop level indices and assume that only a single coarsening level is used. Nevertheless, it should be stressed that this without loss of generality, as an identical argument holds for every level of the scheme. Consider any $x$ and set $y = \Pi^\bot x$. Furthermore, define for each contraction set the (\textit{i}) \emph{internal} edge set $\E^{(r)} = \{ e_{ij} | v_i,v_j \in \V^{(r)}$ and $e_{ij} \in \E_{\ell-1} \}$ , and (\textit{ii}) the \emph{boundary} edge set $\partial\E^{(r)}$, such that if $e_{ij} \in \partial\E^{(r)}$ then $v_i \in \V^{(r)}$ and $v_j \notin \V^{(r)}$. It is true that \begin{align} \|\Pi^\bot x\|_{L}^2 &= \sum_{e_{ij} \in \E} w_{ij} (y(i) - y(j))^2 \notag \\ &= \sum_{r = 1}^{n} \Bigg( \underbrace{\sum_{e_{ij} \in \E^{(r)}} w_{ij} (y(i) - y(j))^2}_{a_r} + \frac{1}{2} \underbrace{\sum_{e_{ij} \in \partial\E^{(r)}} w_{ij} (y(i) - y(j))^2}_{b_r} \Bigg). \notag \end{align} In the following, I will express $a_r$ and $b_r$ as a function of the vector $y_r = \Pi^\bot_{\V^{(r)}} x$. Term $a_r$ is luckily independent of any other contraction set: $$ a_r = \sum_{e_{ij} \in \E^{(r)}} w_{ij} (y(i) - y(j) )^2 = \sum_{e_{ij} \in \E^{(r)}} w_{ij} (y_r(i) - y_r(j) )^2. $$ On the other hand, $b_r$ is smaller than \begin{align} b_r &= \sum_{e_{ij} \in \partial\E^{(r)}} w_{ij} (y(i) - y(j))^2 \leq 2 \hspace{-3mm}\sum_{e_{ij} \in \partial\E^{(r)}} \hspace{-2mm} w_{ij} (y(i)-0)^2 + 2 \hspace{-3mm}\sum_{e_{ij} \in \partial\E^{(r)}} \hspace{-2mm} w_{ij} (0-y(j))^2. \notag \end{align} Distributing the second quantities, respectively, amongst the contraction sets that include said vertices, one gets \begin{align} \|\Pi^\bot x\|_{L}^2 &\leq \sum_{r = 1}^{n} \Bigg( \sum_{e_{ij} \in \E^{(r)}} w_{ij} (y_r(i) - y_r(j) )^2 + 2 \sum_{e_{ij} \in \partial\E^{(r)}} w_{ij} (y(i)-0)^2 \Bigg) \notag \\ &\hspace{0mm}= \sum_{r = 1}^{n} \Bigg( \sum_{e_{ij} \in \E^{(r)}} w_{ij} (y_r(i) - y_r(j) )^2 + \sum_{e_{ij} \in \partial\E^{(r)}} (2w_{ij}) (y_r(i)-y_r(j))^2 \Bigg) \notag \\ &= \sum_{r = 1}^{n} \|y_r\|_{L_{\V^{(r)}}}^2 = \sum_{\mathcal{C} \in \mathcal{P}} \|y_r\|_{L_{\mathcal{C}}}^2 . \notag \end{align} The second step above used the fact that $[\Pi^\bot](i) = 0$ for all $v_i \notin \mathcal{C}$. A decoupled bound can then be obtained as follows: \begin{align*} \| \Pi^\bot A \|_{L}^2 = \max_{a \in \mathbb{R}^{k-1}} \frac{\| S \Pi^\bot A \, a\|_2^2}{\|a\|_2^2} &\leq \sum_{\mathcal{C} \in \mathcal{P}} \max_{a \in \mathbb{R}^{k-1}} \frac{\| \Pi^\bot_{\mathcal{C}}\, A \, a\|_{L_{\mathcal{C}}}^2 }{\|a\|_2^2} = \sum_{\mathcal{C} \in \mathcal{P}} \| \Pi^\bot_{\mathcal{C}}\, A\|_{L_{\mathcal{C}}}^2 \end{align*} The final inequality is derived by taking the square-root of the last equation. \section{Complexity analysis} \label{app:complexity} The computational complexity of Algorithm~\ref{algorithm:multi-level} depends on the number of nodes $N$ and edges $M$ of $G$, the number of levels $c$, the subspace size $k$, as well as on how the families of candidate sets are formed. To derive worst-case bounds, I denote by $\Phi_\ell = \sum_{\C \in \mathcal{F}_{\ell}} |\C|$ the number of vertices in all candidate sets and by $\delta = \max_{\ell, \C \in \mathcal{F}_{\ell}} |\C|$ the cardinality of the maximum candidate set over all levels. Furthermore, I suppose that the per-level reduction ratio $r_\ell$ is a constant. I start with some basic observations: \begin{itemize} \item \emph{Computing $A_{0}, \ldots, A_{c-1}$ is possible in $\tilde{O}(ckM + k^2 N + ck^3)$ operations when $V=U_k$.} % Each $A_{\ell-1}$ is computed once for each level. For $\ell=1$, one needs to approximate the first $k$ eigenpairs of $L$, which can be achieved in $\tilde{O}(kM)$ operations using inverse iteration as described by~\citet{vishnoi2013lx}. For consecutive levels, forming matrix $B_{\ell-1}^\top L_{\ell-1} B_{\ell-1}$ takes $O(M_{\ell-1} k + N_{\ell-1} k^2)$ operations, whereas computing the pseudo-square-root $(B_{\ell-1}^\top L_{\ell-1} B_{\ell-1})^{+\sfrac{1}{2}}$ is possible in $O(k^3)$ operations. Summed up, the costs for all levels amount to $O( k \sum_{\ell=1}^{c} M_{\ell-1} + k^2 \sum_{\ell=2}^{c} N_{\ell-1} + c k^3) = O(ckM + k^2 N + ck^3) $, where I used the observation that $\sum_{\ell=2}^{c} N_{\ell-1} = O(N)$. \item \emph{At each level, the cost function is evaluated at most $ \Phi_{\ell}$ times.} % One starts by computing the cost of each candidate set in $\mathcal{F}_{\ell}$. Moreover, every $\C$ added to $\mathcal{P}_{\ell}$ causes the pruning of at most $\sum_{v_i \in \C} (\phi_i-1)$ other sets, where $\phi_i$ is the number of candidate sets that include $v_i$. Since $\mathcal{P}_{\ell}$ is a partitioning of $\mathcal{V}_{\ell-1}$, at most $\sum_{\C \in \mathcal{P}_{\ell}}\sum_{v_i \in \C} (\phi_i-1) \leq \sum_{v_i \in \mathcal{V}_{\ell-1}} \phi_i - |\mathcal{F}_{\ell}| = \Phi_\ell - |\mathcal{F}_{\ell}|$ cost re-evaluation are needed. \item \emph{Given $A_{\ell-1}$, each call of $\text{cost}_{\ell}(\C)$ requires $O(\min\{ k^2 \delta + k \delta^2,\ k\delta^2 + \delta^3\})$ operations.} % The involved matrices themselves can be easily formed since, excluding all-zero rows and columns, both $L_{\C}$ and $\Pi_{\C}^\bot$ are $ |\C| \times |\C|$ matrices and one can safely restrict $A_{\ell-1}$ to be of size $|\C| \times k$ by deleting all rows that would have been multiplied by zero. % Now, by definition, the incidence matrix $S_{\C}$ of $L_{\C}$ has at most $\delta$ columns and $2\delta$ rows (since one can bundle all boundary weights of a vertex in $\C$ in a single row). Depending on the relative size of $ k$ and $\delta$ the computation can be performed in two ways: \begin{itemize} \item Either one forms the $k\times k$ matrix $A_{\ell-1}^\top \Pi_{\C}^\bot L_{\C} \Pi_{\C}^\bot \, A_{\ell-1}$ and approximate its spectral norm paying a total of $O(k^2 \delta + k \delta^2)$. \item Otherwise, the $2d\times 2d$ matrix $S_{\C} \Pi_{\C}^\bot \, A_{\ell-1} A_{\ell-1}^\top \Pi_{\C}^\bot S_{\C}^\top $ is formed and its norm is computed at a combined cost of $O(\delta^2 k + \delta^3)$. \end{itemize} \item \emph{Maintaining $\mathcal{F}_{\ell}$ sorted incurs $O(\Phi_\ell \log{|\mathcal{F}_{\ell}|})$ cost.} Sorting $\mathcal{F}_{\ell}$ during initialization entails $O(|\mathcal{F}_{\ell}|\log{|\mathcal{F}_{\ell}|})$ operations. Inserting each $\C'$ into $\mathcal{F}_{\ell}$ (see step~\ref{algorithm:prunning}) can be done in $O(\log{|\mathcal{F}_{\ell}|})$ and, moreover, by the same argument used to bound the number of cost evaluations, at most $\Phi_\ell - |\mathcal{F}_{\ell}|$ such insertions can happen. \item \emph{Other operations carry negligible cost.} In particular, by implementing \textsf{marked} as a binary array, checking if a vertex is marked or not can be done in constant time. \end{itemize} Overall, using Algorithm~\ref{algorithm} and for $\mathbf{R}=\mathbf{U}_k$ one can coarsen a graph in $\tilde{O}(ckM + k^2N + ck^3 + \sum_{\ell = 1}^c \Phi_{\ell} ( \min \{ k^2 \delta + k \delta^2,\ k\delta^2 + \delta^3\} + \log{|\mathcal{F}_{\ell}|}) )$ time, where the asymptotic notation hides poly-logarithmic factors. \section{Introduction} As graphs grow in size, it becomes pertinent to look for generic ways of simplifying their structure while preserving key properties. Simplified graph representations find profound use in the design of approximation algorithms, can facilitate storage and retrieval, and ultimately ease graph data analysis by separating overall trends from details. There are two main ways to simplify graphs. First, one may reduce the number of edges, a technique commonly referred to as \emph{graph sparsification}. In a series of works, it has been shown that it is possible to find sparse graphs that approximate all pairwise distances~\citep{peleg1989graph}, every cut~\citep{karger1999random}, or every eigenvalue~\citep{spielman2011spectral}---respectively referred to as {spanners}, {cut sparsifiers} and {spectral sparsifiers}. Spectral sparsification techniques in particular can yield computational benefits whenever the number of edges is the main bottleneck~\citep{Batson:2013:SSG:2492007.2492029}. Indeed, they form a fundamental component of nearly-linear time algorithms for linear systems involving symmetric diagonally dominant matrices~\citep{5671167,spielman2011graph}, and have found application to machine learning problems involving graph-structured data~\citep{calandriello2018improved}. Alternatively, one may seek to reduce directly the size of the graph, i.e., the number of its vertices $N$, by some form of vertex selection or re-combination scheme followed by re-wiring. This idea can be traced back to the mutligrid literature, that targets the acceleration of finite-element methods using cycles of multi-level coarsening, lifting and refinement. After being generalized to graphs, reduction methods have become pervasive in computer science and form a key element of modern graph processing pipelines, especially with regards to graph partitioning~\citep{hendrickson1995multi,karypis1998fast,kushnir2006fast,dhillon2007weighted,wang2014partition} and graph visualization~\citep{koren2002fast,hu2005efficient,walshaw2006multilevel}. In machine learning, reduction methods are used to create multi-scale representations of graph-structured data~\citep{lafon2006diffusion,gavish2010multiscale,shuman2016multiscale} and as a layer of graph convolutional neural networks~\citep{bruna2014spectral,defferrard2016convolutional,7974879,simonovsky2017dynamic,ardizzone2018analyzing}. In addition, being shown to solve linear systems in (empirically) linear time~\citep{koutis2011combinatorial,livne2012lean} as well as to approximate the Fiedler vector~\citep{urschel2014cascadic,gandhi2016improvement}, reduction methods have been considered as a way of accelerating graph-regularized problems~\citep{hirani2015graph,colley2017algebraic}. Some of their main benefits are the ability to deal with sparse graphs --graphs with at most $O(N\log{N})$ edges-- and to accelerate algorithms whose complexity depends on the number of vertices as well as edges. Yet, in contrast to graph sparsification, there has been only circumstantial theory supporting graph reduction~\citep{moitra2011vertex,dorfler2013kron,loukas2018spectrally}. The lack of a concrete understanding of how different reduction choices affect fundamental graph properties is an issue: the significant majority of reduction algorithms in modern graph processing and machine learning pipelines have been designed based on intuition and possess no rigorous justification or provable guarantees. \paragraph{A new perspective.} My starting point in this work is \emph{spectral similarity}---a measure that has been proven useful in sparsification for determining how well a graph approximates another one. To render spectral similarity applicable to graphs of different sizes, I generalize it and restrict it over a subspace of size that is at most equal to the size of the reduced graph. I refer to the resulting definition as \emph{restricted spectral approximation}\footnote{Though similarly named, the definition of \emph{restricted spectral similarity} previously proposed by~\citep{loukas2018spectrally} concerns a set of vectors (rather than subspaces) and is significantly weaker than the one examined here.} (or restricted approximation for short). Despite being a statement about subspaces, restricted similarity has important consequences. It is shown that when the subspace in question is a principal eigenspace (this is a data agnostic choice where one wants to preserve the global graph structure), the eigenvalues and eigenspaces of the reduced graph approximate those of the original large graph. It is then a corollary that (\emph{i}) if the large graph has a good cut so does the smaller one; and (\emph{ii}) that unsupervised learning algorithms that utilize spectral embeddings, such as spectral clustering~\citep{von2007tutorial} and Laplacian eigenmaps~\citep{belkin2003laplacian}, can also work well when run on the smaller graph and their solution is lifted. The analysis then focuses on \emph{graph coarsening}---a popular type of reduction where, in each level, reduced vertices are formed by contracting disjoint sets of connected vertices (each such set is called a \emph{contraction set}). I derive sufficient conditions for a small coarse graph to approximate a larger graph in the sense of restricted spectral approximation. Crucially, this result holds for any number of levels and is independent of how the subspace is chosen. Though the derived bound is global, a decoupling argument renders it locally separable over levels and contraction sets, facilitating computation. The final bound can be interpreted as measuring the \emph{local variation} over each contraction set, as it involves the maximum variation of vectors supported on each induced subgraph. These findings give rise to greedy nearly-linear time algorithms for graph coarsening, that I refer to as \emph{local variation algorithms}. Each such algorithm starts from a predefined family of candidate contraction sets. Even though any connected set of vertices may form a valid candidate set, I opt for small well-connected sets, formed for example by pairs of adjacent vertices or neighborhoods. The algorithm then greedily\footnote{Even after decoupling, the problem of candidate set selection is not only NP-hard but also cannot be approximated to a constant factor in polynomial time (by reduction to the maximum-weight independent set problem). For the specific case of edge-based families, where one candidate set is constructed for each pair of adjacent vertices, the greedy iterative contraction can be substituted by more sophisticated procedures accompanied by improved guarantees.} contracts those sets whose local variation is the smallest. Depending on how the candidate family is constructed, the proposed algorithms obtain different solutions, trading off computational complexity for reduction. \paragraph{Theoretical and practical implications.} Despite not providing a definitive answer on how much one may gain (in terms of reduction) for a given error, the analysis improves and generalizes upon previous works in a number of ways: \begin{itemize} \item Instead of directly focusing on specific constructions, a general graph reduction scheme is studied featuring coarsening as a special case. As a consequence, the implications of restricted similarity are proven in a fairly general setting where specifics of the reduction (such as the type of graph representation and the reduction matrices involved) are abstracted. \item Contrary to previous results on the analysis of coarsening~\citep{loukas2018spectrally}, the analysis holds for multiple levels of reduction. Given that the majority of coarsening methods reduce the number of vertices by a constant factor at each level, a multi-level approach is necessary to achieve significant reduction. Along that line, the analysis also brings an intuitive insight: rather than taking the common approach of approximating at each level the graph produced by the previous level, one should strive to preserve the properties of the original graph at every level. \item The proposed local variation algorithms are not heuristically designed, but greedily optimize (an upper bound of) the restricted spectral approximation objective. Despite the breadth of the literature that utilizes some form of graph reduction and coarsening, the overwhelming majority of known methods are heuristics---see for instance~\citep{safro2015advanced}. A notable exception is Kron reduction~\citep{dorfler2013kron}, an elegant method that aims to preserve the effective resistance distance. Compared to Kron reduction, the graph coarsening methods proposed here are accompanied by significantly stronger spectral guarantees (i.e., beyond interlacing), do not sacrifice the sparsity of the graph, and can ultimately be more scalable as they do not rely on the Schur complement of the Laplacian matrix. \end{itemize} To demonstrate the practical benefits of local variation methods, the analysis is complemented with numerical results on representative graphs ranging from scale-free graphs to meshes and road networks. Compared to both standard~\citep{karypis1998fast} and advanced reduction methods~\citep{ron2011relaxation,livne2012lean,shuman2016multiscale}, the proposed methods yield small graphs of improved spectral quality, often by a large margin, without being much slower than naive heavy-edge matching. A case in point: when examining how close are the principal eigenvalues of the coarse and original graph for a reduction of 70\%, local variation methods attain on average 2.6$\times$ smaller error; this gain becomes 3.9$\times$ if one does not include Kron reduction in the comparison. \section{Graph reduction and coarsening} \label{sec:model} The following section introduces graph reduction. The exposition starts by considering a general reduction scheme. It is then shown how graph coarsening arises naturally if one additionally imposes requirements w.r.t. the interpretability of reduced variables. \subsection{Graph reduction} Consider a positive semidefinite (PSD) matrix $L \in \mathbb{R}^{N\times N}$ whose sparsity structure captures the connectivity structure of a connected weighted symmetric graph $G = (\V, \E, W)$ of $N = |\V|$ vertices and $M = |\E|$ edges. In other words, $L(i,j) \neq 0$ only if $e_{ij}$ is a valid edge. Moreover, let $x$ be an arbitrary vector of size $N$. I study the following generic reduction scheme: \begin{titledframe}{Graph reduction}\label{frm:matrix_reduction} Commence by setting $ L_{0}=L$ and $x_{0}=x $ and proceed according to the following two recursive equations: \begin{align} L_{\ell} = P_\ell^{\mp} L_{\ell-1} P_\ell^+ \quad \text{and} \quad x_\ell = P_{\ell} \, x_{\ell-1}, \notag \end{align} where $P_\ell \in \mathbb{R}^{N_\ell \times N_{\ell-1}}$ are matrices with more columns than rows, $\ell = 1, 2, \ldots, c$ is the level of the reduction, symbol ${\mp}$ denotes the transposed pseudoinverse, and $N_\ell$ is the dimensionality at level $\ell$ such that $N_0 = N$ and $N_{c} = n \ll N$. \vspace{1.5mm} Vector $x_c$ is lifted back to $\mathbb{R}^N$ by recursion $\p{x}_{\ell-1} = P_{\ell}^+ \p{x}_{\ell}$, where $\p{x}_{c} = x_{c}.$ \end{titledframe} Graph reduction thus involves a sequence of $c+1$ graphs \begin{align} G = G_0 = (\V_0, \E_0, W_0) \quad G_1 = (\V_1, \E_1, W_1) \quad \cdots \quad G_{c} = (\V_{c}, \E_{c}, W_{c}) \end{align} of decreasing size $N = N_0 > N_{1} > \cdots > N_{c} = n$, where the sparsity structure of $L_{\ell}$ matches that of graph $G_{\ell}$, and each vertex of $G_{\ell}$ represents one of more vertices of $G_{\ell-1}$. The {multi-level} design allows us to achieve high \emph{dimensionality reduction ratio} $$r = 1 - \frac{n}{N},$$ even when at each level the {dimensionality reduction ratio} $r_\ell = 1 - \frac{N_\ell}{N_{\ell-1}}$ is small. For instance, supposing that $r_\ell \geq \varrho$ for each $\ell$, then $c = O( \log(n/N)/ \log(1-\varrho)) $ levels suffice to reduce the dimension to $n$. One may express the reduced quantities in a more compact form: \begin{align} x_{c} &= P x, \quad L_{c} = P^{\mp} L P^+ \quad \text{and} \quad \p{x} = \Pi x, % % \end{align} where $P = P_{c} \cdots P_{1}$, $P^+ = P_1^+ \cdots P_{c}^+$ and $\Pi = P^+ P$. For convenience, I drop zero indices and refer to a lifted vector as $\p{x} (= \p{x}_0)$. The rational of this scheme is that vector $\p{x}$ should be the best approximation of $x$ given $P$ in an $\ell_2$-sense, which is a consequence of the following property: \begin{property} $\Pi$ is a projection matrix. \label{property:Pi_projection} \end{property} On the other hand, matrix $L$ is reduced such that $x_c^\top L_c x_c = \p{x}^\top L \p{x}$. Though introduced here for the reduction of sparse PSD matrices representing the similarity structure of a graph, Scheme~\ref{frm:matrix_reduction} can also be applied to any PSD matrix $L$. In fact, this and similar reduction schemes belong to the class of Nystr\"om methods and, to the extend of my knowledge, they were first studied in the context of approximate low-rank matrix approximation~\citep{halko2011finding,wang2013improving}. Despite the common starting point, interpreting $L$ and $L_c$ as sparse similarity matrices, as it is done here, incorporates a graph-theoretic twist to reduction that distinguishes from previous methods\footnote{To achieve low-rank approximation, matrix $P$ is usually built by sampling columns of $L$.}: the constructions that we will study are eventually more scalable and interpretable as they maintain the graph structure of $L$ after reduction. Obtaining guarantees is also significantly more challenging in this setting, as the involved problems end up being combinatorial in nature. \subsection{Properties of reduced graphs} Even in this general context where $P$ is an arbitrary $n \times N$ matrix, certain handy properties can be proven about the relation between $L_c$ and $L$. To begin with, it is simple to see that the set of positive semidefinite matrices is closed under reduction. \begin{property} If $L$ is PSD, then so is $L_c$. \end{property} The proof is elementary: if $L$ is PSD then there exists matrix $S$ such that $L = S^\top S$, implying that $L_c = P^\mp L P^+$ can also be written as $L_c = S_c^\top S_c$ if one sets $S_c = S P^+$. I further consider the spectrum of the two matrices. Sort the eigenvalues of $L$ as $\lambda_1 \leq \lambda_2 \leq \ldots \leq \lambda_N$ and denote by $\p{\lambda}_k$ the $k$-th largest eigenvalue of $L_{c}$ and $\p{u}_k$ the associated eigenvector. It turns out that the eigenvalues $\p{\lambda}$ and $\lambda$ are interlaced. \begin{theorem} For any $P$ with full-row rank and $k = 1, \ldots, n$, we have $$ \gamma_1 \, \lambda_k \leq \tilde{\lambda}_k \leq \gamma_2 \, \lambda_{k+N-n}$$ with $\gamma_1 =\lambda_1( (P P^\top)^{-1})$ and $\gamma_2 = \lambda_n((P P^\top)^{-1})$, respectively the smallest and largest eigenvalue of $(P P^\top)^{-1}$. \label{theorem:interlacing} \end{theorem} The above result is a generalization of the Cauchy interlacing theorem for the case that $P P^\top \neq I$. It also resembles the interlacing inequalities known for the normalized Laplacian (where the re-normalization is obtained by construction). \citet{chen2004interlacing} showed in Theorem 2.7 of their paper that after contracting $N-n$ edges $ \lambda_{k - N + n} \leq \lambda_k \leq \lambda_{k + N - n} $ for $k = 1, 2, \ldots, n$ and with $\lambda_{\ell} = 0$ when $\ell \leq 0$, resembling the upper bound above. The lower bound is akin to that given in \citep[Lemma 1.15]{chung1997spectral}, again for the normalized Laplacian. Also notably, the inequalities are similar to those known for Kron reduction~\citep[Lemma 3.6]{dorfler2013kron}. Theorem~\ref{theorem:interlacing} is particularly pessimistic as it has to hold for {every} possible $P$ and $L$. Much stronger results will be obtained later on by restricting the attention to constructions that satisfy additional properties (see Theorem~\ref{theorem:eigenvalues}). One can also say something about the eigenvectors of $L_c$. \begin{property} For every vector for which $x = \Pi x$, one has \begin{align} \c{x}^\top \c{L} \c{x} = x^\top \Pi L \Pi x = x^\top L x \quad \text{and} \quad \p{x} = \Pi x = x. \notag \end{align} \end{property} In other words, reduction maintains the action of $L$ of every vector that lies in the range of $\Pi$. Naturally, after lifting the eigenvectors of $\c{L}$ are included in this class. \subsection{Coarsening as a type of graph reduction} \label{subsec:graph_coarsening} Coarsening is a type of graph reduction abiding to a set of constraints that render the graph transformation interpretable. More precisely, in coarsening one selects for each level $\ell$ a surjective (i.e., many-to-one) map $\varphi_{\ell}: \V_{\ell-1} \rightarrow \V_{\ell}$ between the original vertex set $\V_{\ell-1}$ and the smaller vertex set $\V_{\ell}$. I refer to the set of vertices $\V_{\ell-1}^{(r)} \subseteq \V_{\ell-1}$ mapped onto the same vertex $v_r'$ of $\V_{\ell}$ as a \textit{contraction set}: $$\V_{\ell-1}^{(r)} = \{v \in \V_{\ell-1} : \varphi_{\ell}(v) = v'_r \}$$ For a graphical depiction of contraction sets, see Figure~\ref{fig:example}. I also constrain $\varphi_{\ell}$ slightly by requiring that the subgraph of $G_{\ell-1}$ induced by each contraction set $\V_{\ell-1}^{(r)}$ is connected. It is easy to deduce that {contraction sets} induce a partitioning of $\V_{\ell-1}$ into $N_{\ell}$ subgraphs, each corresponding to a single vertex of $\V_{\ell}$. Every reduced variable thus corresponds to a small set of adjacent vertices in the original graph and coarsening basically amounts to a scaling operation. An appropriately constructed coarse graph aims to capture the global problem structure, whereas neglected details can be recovered in a local refinement phase. Coarsening can be placed in the context of Scheme~\ref{frm:matrix_reduction} by restricting each $P_{\ell}$ to lie in the family of coarsening matrices, defined next: \begin{definition}[Coarsening matrix] Matrix $P_{\ell} \in \mathbb{R}^{N_{\ell} \times N_{\ell-1}}$ is a coarsening matrix w.r.t. graph $G_{\ell-1}$ if and only if it satisfies the following two conditions: \begin{itemize} \item[a.] It is a \textit{surjective mapping} of the vertex set, meaning that if $P_{\ell}(r,i) \neq 0$ then $P_{\ell}(r',i) = 0$ for every $r' \neq r$. \item[b.] It is \textit{locality preserving}, equivalently, the subgraph of $G_{\ell-1}$ induced by the non-zero entries of $P_{\ell}(r,:)$ is connected for each $r$. \end{itemize} \label{def:coarsening_matrix} \end{definition} An interesting consequence of this definition is that, in contrast to graph reduction, with coarsening matrices the expensive pseudo-inverse computation can be substituted by simple transposition and re-scaling: \begin{proposition}[Easy inversion] The pseudo-inverse of a coarsening matrix $P_{\ell}$ is given by $P_\ell^+ = P_\ell^\top D_{\ell}^{-2}$, where $D_{\ell}$ is the diagonal matrix with $D_\ell(r,r) = \| P_\ell(r,:)\|_2$. \label{proposition:pseudo-inverse} \end{proposition} Proposition~\ref{proposition:pseudo-inverse} carries two consequences. First, coarsening can be done in linear time. Each coarsening level (both in the forward and backward directions) entails multiplication by a sparse matrix. Furthermore, both $P_{\ell}$ and $P_{\ell}^+$ have only $N_{\ell-1}$ non-zero entries meaning that $O(N)$ and $O(M)$ operations suffice to coarsen respectively a vector and a matrix $L$ whose sparsity structure reflects the graph adjacency. In addition, the number of graph edges also decreases at each level. Denoting by $\mu_\ell$ the average number of edges of the graphs induced by contraction sets $\mathcal{V}^{(r)}_{\ell-1}$ for every $r$, then a quick calculation reveals that the coarsest graph has $m = M - \sum_{\ell=1}^c N_\ell \mu_\ell$ edges. If, for instance, at each level all nodes are perfectly contracted into pairs then $\mu_{\ell} = 2$ and $N_{\ell} = N / 2^{\ell}$, meaning that $m = M - 2 N (1 -2^{-c})$. \subsection{Laplacian consistent coarsening} \label{subsec:consistent_coarsening} A further restriction that can be imposed is that coarsening is consistent w.r.t. the Laplacian form. Let $L$ be the combinatorial Laplacian of $G$ defined as \begin{align} L(i,j) = \begin{cases} \deg_i & \mbox{if}\ i = j \\ -w_{ij} & \mbox{if}\ e_{ij} \in \E \\ 0 & \mbox{otherwise}, \end{cases} \notag \end{align} where $w_{ij}$ is the weight associated with edge $e_{ij}$ and $\deg_i$ the weighted degree of $v_i$. The following lemma can then be proven: \begin{proposition}[Consistency] Let $P$ be a coarsening matrix w.r.t. a graph with combinatorial Laplacian $L$. Matrix $\c{L} = P^\mp L P^+$ is a combinatorial Laplacian if and only if the non-zero entries of $P^+$ are equally valued. \label{proposition:proper_laplacian} \end{proposition} It is a corollary of Propositions~\ref{proposition:pseudo-inverse} and~\ref{proposition:proper_laplacian} that in consistent coarsening, for any $v'_r \in \V_{\ell}$ and $v_i \in \V_{\ell-1}$ matrices $P_{\ell} \in \mathbb{R}^{N_{\ell} \times N_{\ell-1}}$ and $P^+_{\ell} \in \mathbb{R}^{N_{\ell-1} \times N_{\ell}}$ should be given by: \begin{align} P_{\ell}(r,i) = \begin{cases} \frac{1}{|\V_{\ell-1}^{(r)}|} & \text{if } v_i \in \V_{\ell-1}^{(r)} \\%\varphi_{\ell}(v_i) = v'_r \\ 0 & \text{otherwise} \end{cases} \quad \text{and} \quad [P_{\ell}^+](i,r) = \begin{cases} 1 \hspace{6mm} & \text{if } v_i \in \V_{\ell-1}^{(r)} \\%\varphi_{\ell}(v_i) = v'_r \\ 0 & \text{otherwise}, \end{cases} \notag \end{align} where the contraction sets $\V_{\ell-1}^{(1)}, \ldots, \V_{\ell-1}^{(N_{\ell})}$ were defined in Section~\ref{subsec:graph_coarsening}. \begin{figure}[t] \centering \subfloat[Graph $G$]{ \includegraphics[width=0.4\columnwidth,trim={0.0cm 0.38cm 0.0cm 0.5cm},clip]{fine2.pdf}\label{fig:example1} } \hfill \subfloat[Coarse graph $\c{G}$]{ \includegraphics[width=0.4\columnwidth,trim={0.0cm 0.10cm 0.0cm 0.6cm},clip]{coarse.pdf}\label{fig:example2} } \vspace{2mm} \caption{Toy coarsening example. Grey discs denote contraction sets. The first three vertices of $G$ forming contraction set $\mathcal{V}_0^{1}$ are contracted onto vertex $v_1'$. All other vertices remain unaffected. \label{fig:example}} \end{figure} The toy graph shown in Figure~\ref{fig:example1} illustrates an example where the gray vertices $\mathcal{V}_0^{(1)} = \{ v_1, v_2, v_3\}$ of $G$ are coarsened into vertex $v_1'$, as shown in Figure~\ref{fig:example2}. The main matrices I have defined are \begin{align*} P_1 = \begin{bmatrix} \sfrac{1}{3} & \sfrac{1}{3} & \sfrac{1}{3} & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 1 \end{bmatrix} \ \ P_1^+ = \begin{bmatrix} 1 & 0 & 0 \\ 1 & 0 & 0 \\ 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \end{bmatrix} \ \ \Pi = P_1^+ P_1 = \begin{bmatrix} \sfrac{1}{3} & \sfrac{1}{3} & \sfrac{1}{3} & 0 & 0 \\ \sfrac{1}{3} & \sfrac{1}{3} & \sfrac{1}{3} & 0 & 0 \\ \sfrac{1}{3} & \sfrac{1}{3} & \sfrac{1}{3} & 0 & 0 \\ 0 & 0 & 0 & 1 & 0 \\ 0 & 0 & 0 & 0 & 1 \end{bmatrix} \end{align*} and coarsening results in \begin{align} \c{L} = P_1^\mp L P_1^+ = \begin{bmatrix} 2 & -1 & -1 \\ -1 & 1 & 0 \\ -1 & 0 & 1 \end{bmatrix} \quad \c{x} = P_1 x = \begin{bmatrix} (x(1) + x(2) + x(3))/3 \\ x(4) \\ x(5) \end{bmatrix}. \notag \end{align} Finally, when lifted $\c{x}$ becomes \begin{align*} \p{x} = P_1^+ \c{x} = \begin{bmatrix} \sfrac{\left(x(1) + x(2) + x(3)\right)}{3} \\ \sfrac{\left(x(1) + x(2) + x(3)\right)}{3} \\ \sfrac{\left(x(1) + x(2) + x(3)\right)}{3} \\ x(4) \\ x(5) \end{bmatrix}. \notag \end{align*} Since vertices $v_4$ and $v_5$ are not affected, the respective contraction sets $\mathcal{V}_0^{(2)}$ and $\mathcal{V}_0^{(3)}$ are singleton sets. \subsection{Properties of Laplacian consistent coarsening} Due to its particular construction, Laplacian consistent coarsening is accompanied by a number of interesting properties. We lay out three in the following: \emph{Cuts.} To begin with, weights of edges in $G_c$ correspond to weights of cuts in $G$. \begin{property} For any level $\ell$, the weight $W_\ell(r,q)$ between vertices $v'_r , v'_q \in \V_{\ell}$ is equal to $$W_\ell(r,q) = \sum_{v_i \in \mathcal{S}_\ell^{(r)}} \sum_{v_j \in \mathcal{S}_\ell^{(q)} } w_{ij},$$ where $\S_\ell^{(r)} = \{ v_i \in \V : \varphi_\ell \circ \cdots \circ \varphi_1(v_i) = v'_r \} \subset \V$ contains all vertices of $G$ contracted onto $v'_r \in \V_\ell $. \label{claim:cuts} \end{property} In the toy example, there exists a single edge of unit weight connecting vertices in $\mathcal{V}_0^{(1)}$ and $\mathcal{V}_0^{(2)}$, and as such the weight between $v_1'$ and $v_2'$ is equal to one. \emph{Eigenvalue interlacing.} For a single level of Laplacian consistent coarsening, matrix $P P^\top = P_1 P_1^\top$ is given by $\diag{1/|\V_{0}^{(1)}|, \ldots, 1/|\V_{0}^{(N_1)}|}$, implying that the multiplicative constants in Theorem~\ref{theorem:interlacing} are: $$\gamma_1 = \min_{v_i \in \V} |\V_{0}^{ \varphi_1(v_i)}| \geq 1 \quad \text{and} \quad \gamma_2 = \max_{v_i \in \V} |\V_{0}^{\varphi_1(v_i)}|.$$ Above, $v'_r = \varphi_1(v_i) \in \V_1$ is the vertex to which $v_i$ is mapped to and the set $\V_{0}^{\varphi_1(v_i)}$ contains all vertices also contracted to $v'_r$. Thus in the toy example, $\lambda_k \leq \tilde{\lambda}_k \leq 3 \lambda_{k + 2}$ for every $k \leq 3$. If multiple levels are utilized these terms become dependent on the sequence of contractions. To obtain a general bound let $\varphi_{1}^{\ell}(v_i)= \varphi_{\ell} \circ \cdots \circ \varphi_{1} (v_i) \in \V_{\ell}$ be the vertex onto which $v_i \in \V$ is contracted to in the $\ell$-th level. \begin{property} If $L_c$ is obtained from $L$ by Laplacian consistent coarsening, then $$ \gamma_1 \geq \min_{v_i \in \V } \, \prod_{\ell=1}^c |\V_{\ell-1}^{\varphi_{1}^{\ell}(v_i)}| \geq 1 \quad \text{and} \quad \gamma_2 \leq \max_{v_i \in \V } \, \prod_{\ell=1}^c |\V_{\ell-1}^{\varphi_{1}^{\ell}(v_i)}|, $$ with the set $\V_{\ell-1}^{\varphi_{1}^{\ell}(v_i)} $ containing all vertices of $\V_{\ell-1}$ that are contracted onto $\varphi_{1}^{\ell}(v_i)$. \end{property} Though not included the proof follows from the diagonal form of $P_{\ell} \cdots P_{1} P_1^\top \cdots P_{\ell}^\top$ and the special row structure of each $P_{\ell}$ for every $\ell$. The dependency of $\tilde{\lambda}_k$ on the size of contraction sets can be removed either by enforcing at each level that all contraction sets have identical size and dividing the graph weights by that size, or by re-normalizing each $P_{\ell}$ such that $P_{\ell}^\top = P_{\ell}^+$. The latter approach was used by~\cite{loukas2018spectrally} but is not adopted here as it results in $L_c$ losing its Laplacian form. \emph{Nullspace.} Finally, as is desirable, the structure of the nullspace of $L$ is preserved both by coarsening and lifting: \begin{property} If $P$ is a (multi-level) Laplacian consistent coarsening matrix, then \begin{align} P {1}_{N} = {1}_{n} \quad \text{and} \quad P^+ {1}_{n} = {1}_{N}, \notag \end{align} where the subscript indicates the dimensionality of the constant vector. \end{property} Thus, we can casually ignore vectors parallel to the constant vector in our analysis. \section{Restricted notions of approximation} This section aims to formalize how should a graph be reduced such that the structure of the reduced and original problems should be as close as possible. Inspired by work in graph sparsification, I introduce a measure of approximation that is tailored to graph reduction. The new definition implies strong guarantees about the distance of the original and coarsened spectrum and gives conditions such that the cut structure of a graph is preserved by coarsening. \subsection{Restricted spectral approximation} \label{subsec:subspace_similarity} One way to define how close a PSD matrix $L$ is to its reduced counterpart is to establish an isometry guarantee w.r.t. the following induced semi-norms: \begin{align} \norm{x}_L = \sqrt{x^\top L x} \quad \text{and} \quad \norm{\c{x}}_{\c{L}} = \sqrt{\c{x}^\top \c{L} \c{x}} \notag \end{align} Ideally, one would hope that there exists $\epsilon > 0$ such that \begin{align} (1 - \epsilon) \, \norm{x}_L \leq \norm{\c{x}}_{\c{L}} \leq (1 + \epsilon) \, \norm{x}_L \label{eq:spectral_similarity2} \end{align} for all $ x \in \mathbb{R}^N$. If the equation holds, matrices $\c{L}$ and $L$ are called $\epsilon$-similar. The objective of constructing sparse spectrally similar graphs is the main idea of spectral graph sparsifiers, a popular method for accelerating the solution of linear systems involving the Laplacian. In addition, spectral similarity carries a number of interesting consequences that are of great help in the construction of approximation algorithms: the eigenvalues and eigenvectors of two similar graphs are close and, moreover, all vertex partitions have similar cut size. In contrast to graph sparsification however, since here the dimension of the space changes it is impossible to satisfy~\eqref{eq:spectral_similarity2} for {every} $x \in \mathbb{R}^N$ unless one trivially sets $\epsilon = 1$ (this follows by a simple rank argument). To carry out a meaningful analysis, one needs to consider a subspace of dimension $k \leq n$ and aim to approximate the behavior of $L$ solely within it. I define the following generalization of spectral similarity: \begin{definition}[Restricted spectral approximation] Let $\mathbf{R}$ be a $k$-dimensional subspace of $\mathbb{R}^N$. Matrices $L_c$ and $L$ are $(\mathbf{R}, \epsilon)$-similar if there exists an $\epsilon\geq 0$ such that % \begin{align} \norm{x - \tilde{x}}_{L} \leq \epsilon \norm{x}_L, \notag \quad \text{for all} \quad x \in \mathbf{R}, \end{align} % where $\tilde{x}= P^+ P x$. \end{definition} In addition to the restriction on $\mathbf{R}$, the above definition differs from~\eqref{eq:spectral_similarity2} in the way error is measured. In fact, it asserts a property that is slightly stronger than an approximate isometry w.r.t. a semi-norm within $\mathbf{R}$. The strengthening of the notion of approximation deviates from the restricted spectral similarity property proposed by~\cite{loukas2018spectrally} and is a key ingredient in obtaining multi-level bounds. Nevertheless, one may recover a restricted spectral similarity-type guarantee as a direct consequence: \begin{corollary} If $L_c$ and $L$ are $(\mathbf{R},\epsilon)$-similar, then % $$ (1 - \epsilon) \, \norm{x}_L \leq \norm{\c{x}}_{\c{L}} \leq (1 + \epsilon) \, \norm{x}_L, \notag \quad \text{for all} \quad x \in \mathbf{R}. $$ \label{corollary:restricted_isometry} \end{corollary} \begin{proof} Let $S$ be defined such that $L = S^\top S$. By the triangle inequality: \begin{align} |\norm{x}_L - \norm{\c{x}}_{\c{L}}| = |\norm{Sx} - \norm{S P^+ P x}_2| \leq \| Sx - S P^+ P x \|_2 = \| x - \tilde{x} \|_L \leq \epsilon \norm{x}_L, \notag \end{align} which is equivalent to the claimed relation. \end{proof} Clearly, if $L_c$ and $L$ are $(\mathbf{R}, \epsilon)$-similar then they are also $({\mathbf{R}}', \epsilon')$-similar, where ${\mathbf{R}}'$ is any subspace of $\mathbf{R}$ and $\epsilon'\geq \epsilon$. As such, results about large subspaces and small $\epsilon$ are the most desirable. It will be shown in Sections~\ref{subsec:spectrum} and~\ref{subsec:cuts} that the above definition implies restricted versions of the spectral and cut guarantees provided by spectral similarity. For instance, instead of attempting to approximate the entire spectrum as done by spectral graph sparsifiers, here one can focus on a subset of the spectrum with particular significance. \subsection{Implications for the graph spectrum} \label{subsec:spectrum} One of the key benefits of restricted spectral approximation is that it implies a relation between the spectra of matrices $L$ and $\c{L}$ that goes beyond interlacing (see Theorem~\ref{theorem:interlacing}). To this effect, consider the smallest $k$ eigenvalues and respective eigenvectors and define the following matrices: \begin{align} U_k \in \mathbb{R}^{N\times k} = [u_1, u_2, \ldots, u_k] \quad \text{and} \quad \Lambda_k = \diag{\lambda_1, \lambda_2, \ldots, \lambda_k} \notag \end{align} As I will show next, ensuring that $\epsilon$ in Proposition~\ref{proposition:restricted_similarity} is small when $\mathbf{R} = \mathbf{U}_k \overset{\Delta}{=} \spanning{U_k}$ suffices to guarantee that the first $k$ eigenvalues and eigenvectors of $L$ and $L_c$ are aligned. The first result concerns eigenvalues. \begin{theorem}[Eigenvalue approximation] If $L_c$ and $L$ are $(\mathbf{U}_k,\epsilon_k)$-similar, then \begin{align} \gamma_1 \, \lambda_k \leq \p{\lambda}_k &\leq \gamma_2 \, \frac{ \left(1 + \epsilon_k\right)^2}{1 - \epsilon_k^2 (\lambda_k/\lambda_2) } \, \lambda_k \notag, \end{align} whenever $\epsilon_k^2 < \lambda_2/\lambda_k$. \label{theorem:eigenvalues} \end{theorem} Crucially, the bound depends on $\lambda_k$ instead of $\lambda_{k+N-n}$ and thus can be significantly tighter than the one given by Theorem~\ref{theorem:interlacing}. Noticing that $\epsilon_k \leq \epsilon_{k'}$ whenever $k < k'$, one also deduces that it is stronger for smaller eigenvalues. For $k=2$ in particular, one has \begin{align} \gamma_1 \, \lambda_2 \leq \p{\lambda}_2 \leq \gamma_2 \, \frac{\left(1 + \epsilon_2\right)^2}{1 - \epsilon_2^2} \, \lambda_2, \notag \end{align} which is small when $\epsilon_2 \ll 1$. I also analyze the angle between principal eigenspaces of $L$ and $\c{L}$. I follow~\cite{li1994relative} and split the eigendecompositions of $L = U \Lambda U^\top$ and $P^\top \c{L} P = P^\top \p{U} \p{\Lambda} \p{U}^\top P$ as \begin{align*} L &= (U_k, U_{k^\bot}) \begin{pmatrix} \Lambda_k & \\ & \Lambda_{k^\bot} \end{pmatrix} \begin{pmatrix} U_k^\top \\ U_{k^\bot}^\top \end{pmatrix} % \quad % P^\top \c{L} P = (P^\top \p{U}_k, P^\top\p{U}_{k^\bot}) \begin{pmatrix} \p{\Lambda}_k & \\ & \p{\Lambda}_{k^\bot} \end{pmatrix} \begin{pmatrix} \p{U}_k^\top P \\ \p{U}_{k^\bot}^\top P \end{pmatrix}, \end{align*} where $\p{\Lambda}_k$ and $\p{U}_k$ are defined analogously to $\Lambda_k$ and $ U_k$. \citet{davis1970rotation} defined the \emph{canonical angles} between the spaces spanned by $U_k$ and $P^\top \tilde{U}_k$ as the singlular values of the matrix \begin{align} \Theta( U_k, P^\top\p{U}_k) \overset{\Delta}{=} \arccos(U_k^\top P^\top \p{U}_k \p{U}_k^\top P U_k)^{-\sfrac{1}{2}}, \notag \end{align} see also~\citep{stewart1990matrix}. The smaller the sinus of the canonical angles are the closer the two subspaces lie. The following theorem reveals a connection between the Frobenius norm of the sinus of the canonical angles and restricted spectral approximation. \begin{theorem}[Eigenspace approximation] If $L_c$ and $L$ are $(\mathbf{U}_k,\epsilon_k)$-similar then \begin{align} \norm{ \sintheta{U_k}{P^\top \p{U}_k} }_F^2 &\leq \frac{ 1 }{\lambda_{k+1} - \lambda_{k}} \left( \sum\limits_{i \leq k} \lambda_i \left(\frac{(1 + \epsilon_i)^2}{\gamma_1} - 1\right) + \lambda_k \sum_{i \leq k} \epsilon_i \right) , \notag \end{align} \label{theorem:sintheta} \end{theorem} Note that the theorem above utilizes all $\epsilon_i$ with $i \leq k $, corresponding to the restricted spectral approximation constants for $\mathbf{R} = \mathbf{U}_i$, respectively. However, all these can be trivially relaxed to $\epsilon_k$, since $\epsilon_i\leq \epsilon_k$ for all $i \leq k$. \subsection{Implications for graph partitioning} \label{subsec:cuts} One of the most popular applications of coarsening is to accelerate graph partitioning~\citep{hendrickson1995multi,karypis1998fast,kushnir2006fast,dhillon2007weighted,wang2014partition}. In the following, I provide a rigorous justification for this choice by showing that if the (Laplacian consistent) coarsening is done well and $G_c$ contains a good cut, then so will $G$. For the specific case of spectral clustering, I also provide an explicit bound on the coarse solution quality. \paragraph{Existence results.} For consistent coarsening, the spectrum approximation results presented previously imply similarities between the cut-structures of $G_c$ and $G$. To formalize this intuition, the conductance of any subset $\mathcal{S}$ of $\mathcal{V}$ is defined as \begin{align} \phi(\mathcal{S}) \overset{\Delta}{=} \frac{ w(\mathcal{S}, \bar{\mathcal{S}}) }{ \min\{w(\mathcal{S}), w(\bar{\mathcal{S}})\} }, \notag \end{align} where $\bar{\mathcal{S}} = \mathcal{V} \setminus \mathcal{S}$ is the complement set, $w(\mathcal{S}, \bar{\mathcal{S}}) = \sum_{v_i\in \mathcal{S}, v_j \in \bar{\mathcal{S}}} w_{ij}$ is the weight of the cut and $w(\mathcal{S}) = \sum_{v_i \in \S} \sum_{v_j \in \V} w_{ij} $ is the volume of $\mathcal{S}$. The \emph{$k$-conductance} of a graph measures how easy it is to cut it into $k$ disjoint subsets $\mathcal{S}_1, \ldots, \mathcal{S}_k \subset \mathcal{V}$ of balanced volume: \begin{align} \phi_k(G) = \min_{\mathcal{S}_1, \ldots, \mathcal{S}_k} \max_{i} \phi(\mathcal{S}_i) \notag \end{align} The smaller $\phi_k(G)$ is, the better the partitioning. As it turns out, restricted spectral approximation can be used to relate the conductance of the original and coarse graphs. To state the result, it will be useful to denote by $D$ the diagonal degree matrix and further to suppose that $V_{k}$ contains the first ${k}$ eigenvectors of the normalized Laplacian $L^n = D^{-\sfrac{1}{2}} L D^{-\sfrac{1}{2}}$, whose eigenvalues are $0 = \mu_1 \leq \cdots \leq \mu_k$. \begin{theorem} For any graph $G$ and integer $2\leq k\leq \left\lfloor n/2 \right\rfloor$, if $L_c$ and $L$ are $(\mathbf{R}_{2k}, \epsilon_{2k})$-similar combinatorial Laplacian matrices then $$\phi_{k}(G) \leq \phi_{k}(G_c) = O\left( \sqrt{ \frac{ \gamma_2 \, (1 + \epsilon_{2k})^2 \xi_{k}(G) }{1 - \epsilon_{2k}^2 (\mu_{2k}/\mu_2)} \phi_k(G)} \right)$$ with $\mathbf{R}_{2k} = \spanning{D^{-\sfrac{1}{2}} V_{2k}}$ and $\xi_k(G) = \log k$, whenever $\epsilon_{2k}^2 < \mu_2/\mu_{2k}$. If $G$ is planar then $\xi_{k}(G) = 1.$ More generally, if $G$ excludes $K_h$ as a minor, then $\xi_{k}(G) = h^4.$ For $k=2$, supposing that $L_c$ and $L$ are $(\mathbf{R}_2, \epsilon_{2})$-similar, we additionally have $$ \phi_{2}(G) \leq \phi_{2}(G_c) \leq 2 \sqrt{ \frac{ \gamma_2 \, (1 + \epsilon_{2})^2 }{1 - \epsilon_{2}^2} \phi_2(G) }. $$ \label{theorem:cheeger} \end{theorem} This is a non-constructive result: it does not reveal how to find the optimal partitioning, but provides conditions such that the latter is of similar quality in the two graphs. \paragraph{Spectral clustering.} It is also possible to derive approximation results about the solution quality of unsupervised learning algorithms that utilize the first $k$ eigenvectors in order to partition $G$. I focus here on spectral clustering. To perform the analysis, let $U_k$ and $P^\top \p{U}_k$ be the spectral embedding of the vertices w.r.t. $L$ and $L_c$, respectively, and define the optimal partitioning as \begin{align} \mathcal{P}^{*} = \argmin_{\mathcal{P} = \{\mathcal{S}_1, \ldots, \mathcal{S}_k\}} \kmeans{k}{U_k}{\mathcal{P}} \ \ \text{and} \ \ \p{\mathcal{P}}^{*} = \argmin_{\mathcal{P} = \{\mathcal{S}_1, \ldots, \mathcal{S}_k\}} \kmeans{k}{P^\top \p{U}_k }{\mathcal{P}}, \label{eq:kmeans} \end{align} where, for any embedding $X$, the $k$-means cost induced by partitioning $\V$ into clusters $\S_1, \ldots, \S_k$ is defined as $$ \kmeans{k}{X}{\mathcal{P}} \overset{\Delta}{=} \sum_{z = 1}^k \sum_{v_i, v_j \in \mathcal{S}_z } \frac{\| X(i,:) - X(j,:)\|_2^2}{2\, |\mathcal{S}_z|}. $$ One then measures the quality of $\p{\mathcal{P}}^{*}$ by examining how far the correct minimizer $\kmeans{k}{U_k}{\mathcal{P}^{*}}$ is to $\kmeans{k}{U_k}{\p{\mathcal{P}}^{*}}$. \citet{boutsidis2015spectral} noted that if the two quantities are close then, despite the clusters themselves possibly being different, they both feature the same quality with respect to the $k$-means objective. An end-to-end control of the $k$-means error is obtained by combining the inequality derived by~\citet{loukas2018spectrally}, based on the works of~\citep{boutsidis2015spectral,yu2014useful,martin2017fast}, $ | \kmeans{k}{U_k}{\mathcal{P}^{*}}^{\sfrac{1}{2}} - \kmeans{k}{U_k}{\p{\mathcal{P}}^{*}}^{\sfrac{1}{2}} | \leq 2 \sqrt{2} \, \norm{\sintheta{U_k}{P^\top \p{U}_k} }_F $ with Theorem~\ref{theorem:sintheta}: \begin{corollary} If $L_c$ and $L$ are $(\mathbf{U}_k,\epsilon_k)$-similar then \begin{align} \left( \kmeans{k}{U_k}{\mathcal{P}^{*}}^{\sfrac{1}{2}} - \kmeans{k}{U_k}{\p{\mathcal{P}}^{*}}^{\sfrac{1}{2}} \right)^2 \leq \frac{ 8 }{\lambda_{k+1} - \lambda_{k}} \left( \sum\limits_{i \leq k} \lambda_i \left(\frac{(1 + \epsilon_i)^2}{\gamma_1} - 1\right) + \lambda_k \sum_{i \leq k} \epsilon_i \right). \notag \end{align} \label{corollary:spectral_clustering} \end{corollary} Contrary to previous analysis~\citep{loukas2018spectrally}, the approximation result here is applicable to any number of levels and it can be adapted to hold for the eigenvectors of the normalized Laplacian\footnote{For the normalized Laplacian, one should perform (combinatorial) Laplacian consistent coarsening on a modified eigenspace, as in the proof of Theorem~\ref{theorem:cheeger}.}. Nevertheless, it should be stressed that at this point it is an open question whether the above analysis yields benefits over other approaches tailored especially to the acceleration of spectral clustering. A plethora of such specialized algorithms are known~\citep{tremblay2016compressive,boutsidis2015spectral}---arguing about the pros and cons of each extends beyond the scope of this work. One might be tempted to change the construction so as to increase $\gamma_1$. For example, this could be achieved by multiplying $P$ with a small constant (see Theorem~\ref{theorem:interlacing}). In reality however, such a modification would not yield any improvement as the increase of $\gamma_1$ would also be accompanied by an increase of $\epsilon_i$. \subsection{Some limits of restricted spectral approximation} The connection between spectral clustering and coarsening runs deeper than what was shown so far. As it turns out, the first $k$ restricted spectral approximation constants $\epsilon_1, \ldots, \epsilon_k$ associated with a Laplacian consistent coarsening are linked to the $n$-means cost $\kmeans{n}{U_k}{\mathcal{P}}$ induced by the contraction sets $\mathcal{P} = \{\V_0^{(1)}, \ldots, \V_0^{(n)}\}$. The following lower bound is a direct consequence: \begin{proposition} Let $L$ be a Laplacian matrix. For any $L_c$ obtained by a single level of Laplacian consistent coarsening, if $L_c$ and $L$ are $(\mathbf{U}_k, \epsilon_k)$-similar then it must be that \begin{align} \sum_{i \leq k} \epsilon_k \geq \kmeans{n}{U_k}{\mathcal{P}^*}, \notag \end{align} with $\kmeans{n}{U_k}{\mathcal{P}^*}$ being the optimal $n$-means cost for the points $U_k(1,:), \ldots, U_k(N,:)$. \label{proposition:lower_bound} \end{proposition} Computing the aforementioned lower bound is known to be NP-hard, so the result is mostly of theoretical interest. \section{Graph coarsening by local variation} \label{sec:algorithms} This section proposes algorithms for Laplacian consistent graph coarsening. I suppose that $L$ is a combinatorial graph Laplacian and, given subspace $\mathbf{R}$ and target graph size $n$, aim to find an $(\mathbf{R}, \epsilon)$-similar Laplacian $L_c$ of size $ n \times n$ with $\epsilon$ smaller than some threshold $\epsilon'$. Local variation algorithms differ only in the type of contraction sets that they consider. For instance, the edge-based local variation algorithm only contracts edges, whereas in the neighborhood-based variant each contraction set is a subsets of the neighborhood of a vertex. Otherwise, all local variation algorithms follow the same general methodology and aim to minimize an upper bound of $\epsilon$. To this end, two bounds are exploited: First, $\c{L}$ is shown to be $(\mathbf{R}, \epsilon)$-similar to $L$ with $\epsilon \leq \prod_{\ell} (1 + \sigma_\ell) - 1$, where the \emph{variation cost} $\sigma_{\ell}$ depends only on previous levels (see Section~\ref{subsec:sufficient}). The main difficulty with minimizing $\sigma_\ell$ is that it depends on interactions between contraction sets. For this reason, the second bound shows that these interactions can be decoupled by considering each \emph{local variation cost}, i.e., the cost of contracting solely the vertices in $\V^{(r)}_{\ell-1}$, independently on a slightly modified subgraph (see Section~\ref{subsec:decoupling}). Having achieved this, Section~\ref{subsec:families} considers ways of efficiently identifying disjoint contraction sets with small local variation cost. \subsection{Decoupling levels and the variation cost} \label{subsec:sufficient} Guaranteeing restricted spectral approximation w.r.t. subspace $\mathbf{R}$ boils down to minimizing at each level $\ell$ the \emph{variation cost} $$\sigma_{\ell} = \|\Pi_{\ell}^\bot A_{\ell-1}\|_{L_{\ell-1}} = \|S_{\ell-1} \Pi_{\ell}^\bot A_{\ell-1}\|_2,$$ where $L_{\ell-1} = S_{\ell-1}^\top S_{\ell-1}$ and $ \Pi_{\ell}^\bot = I - P_{\ell}^+ P_\ell$ is a projection matrix. Matrix $A_{\ell-1}$ captures two types of information: \vspace{-1mm} \begin{enumerate} \item Foremost, it encodes the behavior of the target matrix $L$ w.r.t. $\mathbf{R}$. This is clearly seen in the first level, for which one has that $A_{0} = V V^\top L^{+\sfrac{1}{2}}$ with $V \in \mathbb{R}^{N\times k}$ being an orthonormal basis of $\mathbf{R}$. \item When $\ell>1$ one needs to consider $A_{0}$ in view of the reduction done in previous levels. The necessary modification turns out to be $A_{\ell-1} = B_{\ell-1} (B_{\ell-1}^\top L_{\ell-1} B_{\ell-1})^{+\sfrac{1}{2}}$, with $B_{\ell-1} = P_{\ell-1} B_{\ell-2} \in \mathbb{R}^{N_{\ell-1} \times N}$ expressed in a recursive manner and $B_{0} = A_0$. \end{enumerate} The following result makes explicit the connection between $\epsilon$ and $\sigma_{\ell}$. \begin{proposition} Matrices $L_c$ and $L$ are $(\mathbf{R}, \epsilon)$-similar with $ \epsilon \leq \prod_{\ell=1}^{c} ( 1 + \sigma_\ell) -1. $ \label{proposition:restricted_similarity} \end{proposition} Crucially, the above makes it possible to design a multi-level coarsening greedily, by starting from the first level and optimizing consecutive levels one at a time: \begin{algorithm}[h!] \caption{\textsf{Multi-level coarsening}} \label{algorithm:multi-level} \begin{algorithmic}[1] \State \textbf{input}: Combinatorial Laplacian $L$, threshold $\epsilon'$, and target size $n$. \State Set $\ell \gets 0$, $L_\ell \gets L$, and $\epsilon_\ell \gets 0$. \While{$ N_{\ell} > n $ and $\epsilon_\ell < \epsilon'$} \State $\ell \gets \ell+1$ \State Coarsen $L_{\ell-1}$ using Algorithm~\ref{algorithm} with threshold $\sigma'=\frac{1 + \epsilon'}{1 + \epsilon_{\ell-1}}-1$ and target size $n$. Let $L_{\ell}$ be the resulting Laplacian of size $N_{\ell}$ with variation cost $\sigma_{\ell}$. \State $\epsilon_{\ell} \gets (1 + \epsilon_{\ell-1})(1 + \sigma_\ell) - 1$. \EndWhile \State \textbf{return} $L_{\ell}$ \end{algorithmic} \end{algorithm} It is a consequence of Proposition~\ref{proposition:restricted_similarity} that the above algorithm returns a Laplacian matrix $L_c$ that is $(\mathbf{R}, \epsilon)$-similar to $L$ with $\epsilon \leq \epsilon_c \leq \epsilon'$, where $c$ is the last level $\ell$. On the other hand, setting $\epsilon'$ to a large value ensures that the same algorithm always attains the target reduction at the expense of loose restricted approximation guarantees. \emph{Remark.} The variation cost simplifies when $\mathbf{R}$ is an eigenspace of $L$. I demonstrate this for the choice of $\mathbf{U}_k$, though an identical argument can be easily derived for any eigenspace. Denote by $\Lambda$ the diagonal $N\times N$ eigenvalue matrix placed from top-left to bottom-right in non-decreasing order and by $U$ the respective full eigenvector matrix. Furthermore, let $\Lambda_k$ be the $k\times k$ sub-matrix of $\Lambda$ with the smallest $k$ eigenvalues in its diagonal. By the unitary invariance of the spectral norm, it follows that $\sigma_0 = \|\Pi_{1}^\bot U_k U_k^\top L^{+\sfrac{1}{2}} \|_{L_{0}} = \|\Pi_{1}^\bot U_k U_k^\top L^{+\sfrac{1}{2}} U \|_{L_0} = \|\Pi_{1}^\bot U_k U_k^\top U \Lambda^{+\sfrac{1}{2}} \|_{L_0}$ . Simplifying and eliminating zero columns, one may redefine $B_{0} = U_k \Lambda_k^{+\sfrac{1}{2}} \in \mathbb{R}^{N \times k}$, such that once more $\sigma_0 = \|\Pi_1^\bot B_0\|_{L_0}$. This is computationally attractive because now at each level one needs to take the pseudo-inverse-square-root of a $k\times k$ matrix $B_{\ell-1}^\top L_{\ell-1} B_{\ell-1}$, with $k \ll N$. \subsection{Decoupling contraction sets and local variation} \label{subsec:decoupling} Suppose that $\Pi_{\mathcal{C}}^\bot$ is the (complement) projection matrix obtained by contracting solely the vertices in set $\mathcal{C}$, while leaving all other vertices in $\V_{\ell-1}$ untouched: $$ \left[ \Pi^\bot_{\mathcal{C}} \, x \right](i) = \begin{cases} x(i) - \sum_{v_j \in \mathcal{C}} \frac{x(j)}{|\mathcal{C}|} & \mbox{if}\ v_i \in \mathcal{C} \\ 0 & \mbox{otherwise}. \end{cases} $$ (Here, for convenience, the level index is suppressed.) Furthermore, let $L_\mathcal{C}$ be the $N_{\ell-1} \times N_{\ell-1}$ combinatorial Laplacian whose weight matrix is \begin{align} \left[W_\mathcal{C}\right](i,j) = \begin{cases} W_{\ell-1}(i,j) & \mbox{if}\ v_i, v_j \in \mathcal{C} \\ 2\,W_{\ell-1}(i,j) & \mbox{if}\ v_i \in \mathcal{C} \ \text{and} \ v_j \notin \mathcal{C} \\ 0 & \mbox{otherwise}. \end{cases} \end{align} That is, $W_\mathcal{C}$ is zero everywhere other than at the edges touching at least one vertex in $\mathcal{C}$. The following proposition shows us how to decouple the contribution of each contraction set to the variation cost. \begin{proposition} The variation cost is bounded by $$\sigma_\ell^2 \leq \sum_{ \mathcal{C} \in \mathcal{P}_\ell } \| \Pi_\mathcal{C}^\bot \, A_{\ell-1}\|_{L_\mathcal{C} }^2 ,$$ where $\mathcal{P}_{\ell} = \{ \V_{\ell-1}^{(1)}, \ldots, \V_{\ell-1}^{(N_{\ell})}\}$ is the family of contraction sets of level $\ell$. \label{proposition:decoupling} \end{proposition} The above argument therefore entails bounding the, difficult to optimize, variation cost as a function of locally computable and independent costs $ \| \Pi_\mathcal{C}^\bot \, A_{\ell-1}\|_{L_\mathcal{C} }^2$. The obtained expression is a relaxation, as it assumes that the interaction between contraction sets will be the worst possible. It might be interesting to notice that the quality of the relaxation depends on the weight of the cut between contraction sets. Taking the limit, the inequality converges to an equality as the weight of the cut shrinks. Also of note, the bound becomes tighter the larger the dimensionality reduction requested (the smaller $N_{\ell}= |\mathcal{P}_{\ell}|$ is, the fewer inequalities are involved in the derivation). \subsection{Local variation coarsening algorithms} \label{subsec:families} Starting from a \emph{candidate family} $\F_{\ell} = \{ \C_{1}, \C_{2}, \C_{3}, \ldots \}$, that is, an appropriately sized family of candidate contraction sets, the strategy will be to search for a small \emph{contraction family} $\mathcal{P}_{\ell} = \{ \V_{\ell-1}^{(1)}, \ldots, \V_{\ell-1}^{(N_{\ell})}\}$ with minimal variation cost $\sigma_\ell$ ($\mathcal{P}_{\ell}$ is valid if it partitions $\V_{\ell-1}$ into $N_{\ell}$ {contraction sets}). Every coarse vertex $v_r' \in \V_\ell$ is then formed by contracting the vertices in $\V_{\ell-1}^{(r)}$. As a thought experiment, suppose that set $\C \in \F_{\ell}$ is chosen to be part of $\mathcal{P}_\ell$. From the decoupling argument, its contribution to $\sigma_\ell^2$ will be at most $\| \Pi_{\C}^\bot \, A_{\ell-1}\|_{L_{\C}}^2$ independently of how the other candidate sets are chosen. Moreover, the selection will yield a reduction of $N_{\ell-1}$ by $|\C|-1$ vertices. Thus, one needs to look for the non-singleton candidate sets $\C$ with cost \begin{align} \text{cost}_{\ell}(\C) \overset{\Delta}{=} \frac{\| \Pi_{\C}^\bot \, A_{\ell-1}\|_{L_{\C}}^2}{|\C|-1} \label{eq:local_variation_cost} \end{align} that is as small as possible. I refer to~\eqref{eq:local_variation_cost} as \emph{local variation cost} because it captures the maximal variation of all signals from an appropriate subspace (implied by $A_{\ell-1}$) with support on $\C$. On the other hand, since any permissible contraction family $\mathcal{P}_{\ell}$ should be a partitioning of $\V_{\ell-1}$, choosing $\C$ precludes us from selecting any $\C'$ with which it intersects. Based on this intuition, Algorithm~\ref{algorithm} sequentially examines candidate sets from $\F_{\ell}$, starting from those with minimal cost. To decide whether a candidate set $\C$ will be added to $\P_{\ell}$ the algorithm asserts that all vertices in $\C$ are unmarked---essentially enforcing that all contraction sets are disjoint. Accordingly, as soon as $\C$ is added to $\mathcal{P}_{\ell}$, all vertices that are in $\C$ become marked. Candidate sets with marked vertices are pruned ($\C' \gets \C \setminus \textsf{marked}$) and their cost is updated. The algorithm terminates if $\F_{\ell}$ is, if the target reduction is achieved, or if a given error threshold is exceeded. Even though this remains implicit in the discussion, if at termination $\P_{\ell}$ does not cover every vertex of $\V_{\ell-1}$, then I compliment it with singleton sets, featuring one vertex each (and zero cost). \begin{algorithm}[h!] \caption{\textsf{Single-level coarsening by local variation}} \label{algorithm} \begin{algorithmic}[1] \State \textbf{input}: Combinatorial Laplacian $L_{\ell-1}$, threshold $\sigma'$, and target size $n$. \State Form the family of candidate sets $\F_{\ell} = \{ \C_{1}, \C_{2}, \C_{3}, \ldots \}$ (algorithm-specific step). \State $N_{\ell} \gets N_{\ell-1}$, $\textsf{marked} \gets \varnothing$, $\sigma_{\ell}^2 \gets 0$. \State Sort $\mathcal{F_{\ell}}$ in terms of increasing $\text{cost}_{\ell}(\C)$. \While{$|\F_{\ell}|> 0$ and $N_{\ell} > n$ and $\sigma_{\ell} \leq \sigma'$} \State Pop the candidate set $\C$ of minimal cost $s$ from $\F_{\ell}$. \If{all vertices of $\C$ are not \textsf{marked} and $\sigma' \geq \sqrt{ \sigma_{\ell}^2 + (|\C| - 1)s}$} \State $\textsf{marked} \gets \textsf{marked}\cup \C, \ \mathcal{P}_{\ell} \gets \mathcal{P}_{\ell} \cup \C$, $N_{\ell} \gets N_{\ell} - |\C| + 1$, $\sigma_\ell^2 \gets \sigma_\ell^2 + (|\C| - 1)s$ \Else{} \State $\C' \gets \C \setminus \textsf{marked}$ \If{$|\C'| > 1$} \State Compute $\text{cost}_{\ell}(\C')$ and insert $\C'$ into $\mathcal{F_{\ell}}$ while keeping the latter sorted.\label{algorithm:prunning} \EndIf \EndIf \EndWhile \State Form the $N_{\ell}\times N_{\ell-1}$ coarsening matrix $P_{\ell}$ based on $\mathcal{P}_{\ell}$. \State \textbf{return} $L_{\ell} \gets P_{\ell}^\mp L_{\ell-1} P_{\ell}^+$ and $\sigma_\ell$ \end{algorithmic} \end{algorithm} Undeniably, Algorithm~\ref{algorithm} is only one of the possible ways to select a partitioning of small variation cost. However, this algorithm stands out from other algorithms I experimented with, as it is very efficient when the subspace of interest is an eigenspace (e.g., $V=U_k$), $k$ is small, and the families $\mathcal{F}_{\ell}$ have been selected appropriately. Denote by $\Phi = \max_{\ell} \sum_{\C \in \F_{\ell}} |\C|$ the maximum number of vertices in all candidate sets and by $\delta = \max_{\ell,\ \C \in \F_{\ell}} |\C|$ the cardinality of the maximum candidate set---I refer to these measures as \emph{family weight} and \emph{width}, respectively. Choosing $\mathbf{R}=\mathbf{U}_k$, the computational complexity of Algorithm~\ref{algorithm} is $\tilde{O}(ckM + k^2N + ck^3 + c \, \Phi \left( \min \{ k^2 \delta + k \delta^2,\ k\delta^2 + \delta^3\} + \log{\max_{\ell}|\mathcal{F}_{\ell}|} \right) )$, which up to poly-log factors is linear on the number of edges, vertices, and $\Phi$ (see Appendix~\ref{app:complexity} for details). If computational complexity is of no concern, one may consider the following two more sophisticated algorithms: \textit{The optimal algorithm.} Given a candidate family, the algorithm that optimally minimizes the sum of local variation costs constructs a graph with one vertex for each subset of a candidate set and adds an edge between every two vertices whose respective sets have a non-empty intersection. It then selects $\P_{\ell}$ as the maximum independent set of minimal weight (the weight of each vertex is a local variation cost w.r.t a set). Unfortunately, even if the size of this graph is a polynomial on $N$ this problem cannot be solved efficiently, since the minimum-weight independent set problem is NP-hard. Nevertheless, for the specific case where candidate sets correspond to edges the problem simplifies to a minimum-weight matching problem, which can be computed in $O(N_{\ell-1}^3)$ time exactly, whereas a $(2+\delta)$-approximation can be found much faster~\citep{paz20172+}. \textit{The quadratic variant.} A second possibility is to proceed as with Algorithm~\ref{algorithm}, but to prune each $\C' \in \F_{\ell}$ after a set $\C$ is added to $\mathcal{P}_{\ell}$. The numerical experiments indicated that this additional step improves slightly the coarsening quality, but it is not recommended for large graphs as it introduces a quadratic dependency of the complexity on $N$. \paragraph{Candidate contraction families}. To keep coarsening efficient, I focus on families of linear weight and almost constant width. Two possibilities are considered: \emph{Edge-based.} Here $\F_{\ell}$ contains one candidate set for each edge of $G_{\ell-1}$. This is a natural choice for coarsening---indeed, most coarsening algorithms in the literature use some form of edge contraction. It is straightforward to see that in this case $\Phi = 2 M$ and $\delta = 2$, meaning that the expression of the computational complexity simplifies to $\tilde{O}(c k M + ck^3 + k^2N)$. The drawback of contracting edges is that at each level the graph size can only reduced by at most a factor of 2, meaning that a large number of levels is necessary to achieve significant reduction\footnote{In practice, depending on the graph in question, the per-level reduction ratio $r_\ell$ is usually between 0.35 and 0.45.}. \emph{Neighborhood-based.} A more attractive choice is to construct one candidate set for the neighborhood of each vertex, including the vertex itself. Denoting by $\Delta$ the largest combinatorial degree. Since $\Phi = 2 M$, the complexity here is $\tilde{O}(c M (k + \min \{ k^2 \Delta + k \Delta^2,\ k\Delta^2 + \Delta^3\}) + ck^3 + k^2N)$. Experiments show that the neighborhood-based construction generally achieves better reduction, while being marginally slower than edge-based families. As a final remark, when $G$ is dense the dependency on $M$ can be dropped by sparsifying the graph before using Algorithm~\ref{algorithm}. \section{Numerical results} The evaluation was performed on four representative graphs, each exhibiting different structural characteristics: \begin{itemize} \item \textit{Yeast}. Protein-to-protein interaction network in budding yeast, analyzed by~\citet{jeong2001lethality}. The network has $N = 1458$ vertices, $M=1948$ edges, diameter of 19, and degree between 1 and 56. \item \textit{Airfoil}. Finite-element graph obtained by airflow simulation~\cite{preis1997party}, consisting of $N=4000$ vertices, $M=11490$ edges, diameter of 65, and degree between 1 and 9. \item \textit{Minnesota}. Road network with $N=2642$ vertices, $M=3304$ edges, diameter of 99, and degree between 1 and 5~\citep{gleich2008matlabbgl}. \item \textit{Bunny}. Point cloud consisting of $N=2503$ vertices, $M=65490$ edges, diameter of 15, and degree between 13 and 97~\citep{turk1994zippered}. The point cloud has been sub-sampled from its original size. \end{itemize} I compare to the following methods for multi-level graph reduction: \begin{itemize} \item \textit{Heavy edge matching.} At each level of the scheme, the contraction family is obtained by computing a maximum-weight matching with the weight of each contraction set (i.e., $(v_i,v_j)$) calculated as $w_{ij} / \max\{\deg_i, \deg_j\}$. In this manner, heavier edges connecting vertices that are well separated from the rest of the graph are contracted first. Heavy edge matching was first introduced in the algebraic multigrid literature and, perhaps due its simplicity, it has been repeatedly used for partitioning~\citep{karypis1998fast,dhillon2007weighted} and drawing~\citep{walshaw2000multilevel,hu2005efficient} graphs, as well as more recently in graph convolutional neural networks~\citep{}. \item \textit{Algebraic distance.} This method differs from heavy edge matching in that the weight of each contraction set is calculated as $(\sum_{q=1}^Q (x_q(i) - x_q(j))^2)^{1/2}$, where $x_k$ is an $N$-dimensional test vector computed by successive sweeps of Jacobi relaxation. The complete method is described by~\citet{ron2011relaxation}, see also~\citep{chen2011algebraic}. As recommended by the authors, I performed 20 relaxation sweeps. Further, I set the number of test vectors $Q$ to equal the dimension $k$ of the space I aimed to approximate (a simple rank argument shows that $Q\geq k$ for the test vectors to span the space). \item \textit{Affinity.} This is a vertex proximity heuristic in the spirit of the algebraic distance that was proposed by~\citet{livne2012lean} in the context of their work on the lean algebraic multigrid. As per author suggestion, the $Q=k$ test vectors are here computed by a single sweep of a Gauss–Seidel iteration. \item \textit{Kron reduction.} At each level, the graph size is reduced by selecting a set of vertices of size $N/2$ (corresponding to the positive entries of the last eigenvector of $L$) and applying Kron reduction. The method, which was proposed by~\cite{shuman2016multiscale}, is not strictly a coarsening method as it completely rewires the vertices of the reduced graph, resulting in significantly denser graphs\footnote{As suggested by the authors, the sparsity of reduced graphs can be controlled by spectral sparsification. The sparsification step was not included in the numerical experiments since it often resulted in increased errors.}. Unfortunately, the rewiring step entails finding the Schur complement of a large Laplacian submatrix and thus generally exhibits $O(N^3)$ complexity, rendering it prohibitive for graphs of more than a few thousand vertices. Despite these drawbacks, the method is quite popular because of its elegant theoretical guarantees~\citep{dorfler2013kron}. \end{itemize} Depending on how the edge matching is constructed, different variants of edge contraction methods can be implemented. At the two extremes of the complexity spectrum one finds the maximum matching of minimum weight at a complexity of $O(N^3)$~\citep{galil1986efficient} or greedily constructs a matching by visiting vertices in a random order and inducing $O(M)$ overhead~\citep{dhillon2007weighted}. For consistency, I implemented all edge-based methods by combining Algorithm~\ref{algorithm} with an edge-based family and substituting the local variation cost with the (negative) method-specific edge weight. This generally yields matchings of better quality (heavier weight) than visiting vertices in a predefined order, at the expense of the marginally larger $O(M\log{M})$ complexity necessary for sorting the edge weights. The choice is also motivated by the observation that the computational bottleneck of (sophisticated) edge contraction methods lies in the edge weight computation. For all experiments, I set $\epsilon' = \infty$ aiming for a fixed reduction rather than restricted spectral approximation guarantee. The code reproducing the experiments can be accessed \href{https://www.dropbox.com/s/l8c1r605bdmmvr6/jmlr_code.zip}{\textcolor{blue}{online}}. \subsection{Restricted spectral approximation} \newcommand{0.45\columnwidth}{0.45\columnwidth} \begin{figure*}[!h] \centering \subfloat[yeast ($k=10$)]{\includegraphics[width=0.45\columnwidth,trim={0.8cm 1cm 0.8cm 1cm},clip]{experiment_comparison_yeast_K=10.pdf}\label{fig:comp_yeast_10}} ~ \subfloat[yeast ($k=40$)]{\includegraphics[width=0.45\columnwidth,trim={1.0cm 1cm 1.0cm 1cm},clip]{experiment_comparison_yeast_K=40.pdf}\label{fig:comp_yeast_40}} \vspace{-2mm}\\ \subfloat[airfoil ($k=10$)]{\includegraphics[width=0.45\columnwidth,trim={0.8cm 1cm 0.8cm 1cm},clip]{experiment_comparison_airfoil_K=10.pdf}\label{fig:comp_airfoil_10}} ~ \subfloat[airfoil ($k=40$)]{\includegraphics[width=0.45\columnwidth,trim={1.0cm 1cm 1.0cm 1cm},clip]{experiment_comparison_airfoil_K=40.pdf}\label{fig:comp_airfoil_40}} \vspace{-2mm}\\ \subfloat[bunny ($k=10$)]{\includegraphics[width=0.45\columnwidth,trim={0.8cm 1cm 0.8cm 1cm},clip]{experiment_comparison_bunny_K=10.pdf}\label{fig:comp_bunny_10}} ~ \subfloat[bunny ($k=40$)]{\includegraphics[width=0.45\columnwidth,trim={1.0cm 1cm 1.0cm 1cm},clip]{experiment_comparison_bunny_K=40.pdf}\label{fig:comp_bunny_40}} \vspace{-2mm}\\ \subfloat[minnesota ($k=10$)]{\includegraphics[width=0.45\columnwidth,trim={0.8cm 1cm 0.8cm 1cm},clip]{experiment_comparison_minnesota_K=10.pdf}\label{fig:comp_minnesota_10}} ~ \subfloat[minnesota ($k=40$)]{\includegraphics[width=0.45\columnwidth,trim={1.0cm 1cm 1.0cm 1cm},clip]{experiment_comparison_minnesota_K=40.pdf}\label{fig:comp_minnesota_40}} \vspace{2mm} \caption{Quality of approximation comparison for four representative graphs (rows) and two subspace sizes (columns). \label{fig:comparison}} \end{figure*} The first experiment tests how well $L_c$ approximates the action of $L$ with respect to the subspace $U_k$ of smallest variation. In other words, for each method I plot the smallest $\epsilon$ such that the following equation holds: \begin{align} \norm{x - \p{x}}_{L} \leq \epsilon \, \norm{x}_L \quad \text{for all} \quad x \in \mathbf{U}_k. \end{align} The results are summarized in Figure~\ref{fig:comparison} for two representative subspaces of size $k=10$ and $k=40$. % With the exception of the Kron reduction that was repeated 10 times, all methods are deterministic and thus were run only once. Overall, it can be seen that local variation methods outperform other coarsening methods in almost every problem instance. The gap is particularly prominent for large reductions, where multiple levels are employed. Neighborhood-based contraction yields the best result overall, mainly because it achieves the same reduction in fewer levels. Interestingly, local variation (and coarsening) methods in many cases also outperform Kron reduction, even though the latter is more demanding computationally. I elaborate further on four points stemming from the results: \textit{In most instances, a reduction of up to 70\% is feasible while maintaining a decent approximation.} The attained approximation clearly is a function of the graph in question and $k$. Nevertheless, in almost all experiments, the best coarsening method could reduce the graph size by at least 70\% while also ensuring that $\epsilon<1$ (horizontal black line). This is an encouraging sign, illustrating that significant dimensionality reduction is often possible, without sacrificing too much the solution quality. \textit{Following intuition, it is generally harder to approximate subspaces of larger dimension $k$, but not excessively so}. Increasing $k$ from 10 to 40 in most cases increases $\epsilon$ only slightly. The only case where the approximation becomes profoundly better with small subspaces is with small reduction ratios $r$. For instance, coarsening the yeast graph results in an impressive approximation for all $r<30\%$ when $k=10$, whereas $\epsilon$ increases almost by an order of magnitude when $k$ becomes 40. \textit{Kron reduction is an effective way to half the graph size but can result in poor approximation otherwise.} If one is willing to sacrifice in terms of efficiency, Kron reduction effectively reduces the size of the graph by a factor of two (with the exception of the yeast graph). What might be startling is that the method behaves poorly for different reduction ratios. Three main factors cause this deterioration of performance. First, the sampling set is constructed based on the polarity of $u_N$ and has cardinality close to $N/2$~\citep{shuman2016multiscale}. Therefore, if in any level one tries to reduce the graph size by less than half, the last eigenvector heuristic cannot be used exactly. Second, numerical instability issues sometimes manifest when $r$ exceeds 50\%. Though I attempted to improve the original implementation featured in the PyGSP toolbox, some problem instances could not be solved successfully (hence the missing markers). The third reason is described next. \textit{Coarse levels should aim to approximate the original graph and not the proceeding levels.} The conventional approach in multi-level schemes is to aim at each level to approximate as closely as possible the graph of the previous level. This can lead to sudden increase of error at consecutive levels (e.g. notice the minnesota error as $r$ approaches 50\%) as decisions early in the scheme can have a large impact later on. On the other hand, by Proposition~\ref{proposition:restricted_similarity} local variation methods modify the cost function minimized at each level, resulting in smoother transitions between levels and tighter approximations at large $r$. \subsection{Spectrum approximation} The second part of the experiments examines the coarsening through the lens of spectral graph theory. The premise is that, since the spectrum of the Laplacian distills information about the graph structure, one may interpret the spectral distance as a proxy for the structural similarity of the two graphs. This is by no means a new idea---the Laplacian spectrum is a common ingredient in accessing graph similarity~\citep{wilson2008study}. Tables~\ref{table:K=10} and~\ref{table:K=40} report the mean relative eigenvalue error defined as $\frac{1}{k} \sum_{i=1}^k \frac{|\p{\lambda_i} - \lambda_i|}{ \lambda_i} $ for two representative $k$, respectively 10 and 40. The results for $k=80$ were consistent with those presented here, and are not reported here for reasons of brevity. \begin{table}[h!] \footnotesize\centering \resizebox{0.75\textwidth}{!}{ \begin{tabular}{@{}rccccccc@{}} \toprule & $r$ & \begin{tabular}[c]{@{}c@{}}heavy\\ edge\end{tabular} & \begin{tabular}[c]{@{}c@{}}local var.\\ (edges)\end{tabular} & \begin{tabular}[c]{@{}c@{}}local var.\\ (neigh.)\end{tabular} & \begin{tabular}[c]{@{}c@{}}algebraic\\ distance\end{tabular} & affinity & \begin{tabular}[c]{@{}c@{}}Kron\\ reduction\end{tabular}\\ \midrule \multirow{3}{*}{yeast} & 30\% & 0.343 & 0.123 & \textbf{0.003} & 0.145 & 0.177 & 0.054 \\ & 50\% & 0.921 & 0.459 & \textbf{0.034} & 0.605 & 1.020 & 1.321 \\ & 70\% & 3.390 & 3.495 & \textbf{0.406} & 3.504 & 3.732 & 1.865 \\\cmidrule(l){2-8} \multirow{3}{*}{airfoil} & 30\% & 0.277 & \textbf{0.036} & 0.065 & 0.213 & 0.245 & 0.352 \\ & 50\% & 0.516 & 0.201 & \textbf{0.197} & 1.268 & 1.375 & 0.912 \\ & 70\% & 4.744 & 1.045 & \textbf{0.928} & 5.544 & 5.775 & 1.984 \\\cmidrule(l){2-8} \multirow{3}{*}{bunny} & 30\% & 0.019 & \textbf{0.006} & 0.061 & 0.277 & 0.068 & 0.335 \\ & 50\% & 0.064 & \textbf{0.046} & 0.190 & 0.435 & 0.135 & 0.801 \\ & 70\% & 0.126 & \textbf{0.081} & 0.323 & 0.692 & 0.295 & 1.812 \\\cmidrule(l){2-8} \multirow{3}{*}{minnesota} & 30\% & 0.332 & 0.088 & \textbf{0.078} & 0.232 & 0.280 & 0.318 \\ & 50\% & 2.018 & 0.432 & \textbf{0.310} & 2.398 & 2.426 & 0.882 \\ & 70\% & 9.299 & 4.579 & \textbf{1.866} & 9.938 & 9.177 & 1.951 \\\bottomrule \end{tabular} } \caption{Mean relative error for the first $k=10$ eigenvalues, for different graphs, reduction ratios, and coarsening methods.} \label{table:K=10} \end{table} \begin{table}[h!] \footnotesize\centering \resizebox{0.75\textwidth}{!}{ \begin{tabular}{@{}rccccccc@{}} \toprule & $r$ & \begin{tabular}[c]{@{}c@{}}heavy\\ edge\end{tabular} & \begin{tabular}[c]{@{}c@{}}local var.\\ (edges)\end{tabular} & \begin{tabular}[c]{@{}c@{}}local var.\\ (neigh.)\end{tabular} & \begin{tabular}[c]{@{}c@{}}algebraic\\ distance\end{tabular} & affinity & \begin{tabular}[c]{@{}c@{}}Kron\\ reduction\end{tabular}\\ \midrule \multirow{3}{*}{yeast} & 30\% & 0.328 & 0.113 & \textbf{0.023} & 0.094 & 0.195 & 0.120 \\ & 50\% & 0.879 & 0.430 & \textbf{0.130} & 0.517 & 0.769 & 1.196 \\ & 70\% & 2.498 & 2.182 & \textbf{0.451} & 2.560 & 2.229 & 1.946 \\\cmidrule(l){2-8} \multirow{3}{*}{airfoil} & 30\% & 0.277 & \textbf{0.095} & 0.181 & 0.189 & 0.267 & 0.368 \\ & 50\% & 0.549 & \textbf{0.325} & 0.349 & 0.698 & 0.862 & 0.960 \\ & 70\% & 2.268 & 0.872 & \textbf{0.839} & 2.373 & 2.531 & 2.078 \\\cmidrule(l){2-8} \multirow{3}{*}{bunny} & 30\% & 0.023 & \textbf{0.008} & 0.085 & 0.205 & 0.052 & 0.294 \\ & 50\% & 0.066 & \textbf{0.058} & 0.181 & 0.346 & 0.089 & 0.660 \\ & 70\% & 0.128 & \textbf{0.098} & 0.299 & 0.509 & 0.202 & 1.192 \\ \cmidrule(l){2-8} \multirow{3}{*}{minnesota} & 30\% & 0.353 & 0.118 & \textbf{0.115} & 0.209 & 0.306 & 0.337 \\ & 50\% & 1.259 & 0.468 & \textbf{0.383} & 1.342 & 1.264 & 0.933 \\ & 70\% & 4.162 & 2.111 & \textbf{1.612} & 4.145 & 4.185 & 2.090 \\ \bottomrule \end{tabular} } \caption{Mean relative error for the first $k=40$ eigenvalues, for different graphs, reduction ratios, and coarsening methods.} \label{table:K=40} \end{table} As expected, the reduction ratio plays a major role in the closeness of Laplacian spectra. Indeed, for most cases the eigenvalue error jumps by almost an order of magnitude whenever $r$ increases by 20\%. Yet, in most cases acceptable errors can be achieved even when the coarse graph is as small as one third of the size of the original graph (corresponding to $r = 70\%$). It might also be interesting to observe that there is a general agreement between the trends reported here and those described in the matrix approximation experiment. In particular, if one sorts the tested methods from best to worse, he/she will obtain an ordering that is generally consistent across the two experiments, with local variation methods giving the best approximation by a significant margin. A case in point: for the maximum ratio, the best local variation method is on average 3.9$\times$ better than the leading state-of-the-art coarsening method. The gain is 2.6$\times$ if the Kron reduction is also included in the comparison. Overall, it can be deduced from these results that local variation methods coarsen a graph in a manner that preserves its spectrum. This is in accordance with the theoretical results. As it was shown by Theorem~\ref{theorem:eigenvalues}, if $L$ and $L_c$ act similar w.r.t. all vectors in $\textbf{U}_k$, then their eigenvalues cannot be far apart. Therefore, by aiming for restricted approximation, local variation methods implicitly also guarantee spectrum approximation. \subsection{Efficiency} The last experiment tests computational efficiency. I adopt a simple approach and aim to coarsen a 10-regular graph of increasing size. I measure the execution time of the six different methods for graph reduction and report the mean over 10 iterations, while capping computation at 100 seconds. The results are displayed in Figures~\ref{fig:scalability_10} and~\ref{fig:scalability_40} for subspaces of size $10$ and 40, respectively. As with most such comparisons, the actual numbers are only indicative and depend on the programming language utilized (Python), processing paradigm (no parallelism was employed), and hardware architecture (2.2GHz CPU)\footnote{I expect that a significant speedup can be achieved by compiling the code to native machine instructions as well as by parallelizing the local variation cost computation.}. Focusing on the trends, with the exception of Kron reduction and affinity, most methods scale quasi-linearly with the number of edges. Interestingly, local variation methods are quite competitive and do not sacrifice much as compared to the straightforward heavy edge matching. One can also observe that constructing $\F_{\ell-1}$ based on neighborhoods results in slightly slower computation that with the edge-based method construction, because in the latter case the local variation cost can be computed much more efficiently. \begin{figure}[t] \centering \vspace{0mm} \subfloat[$k=10$]{\includegraphics[width=0.48\columnwidth,trim={0.8cm 1cm 0.8cm 1cm},clip]{experiment_scalability_K=10.pdf}\label{fig:scalability_10}} ~ \subfloat[$k=40$]{\includegraphics[width=0.48\columnwidth,trim={0.8cm 1cm 0.8cm 1cm},clip]{experiment_scalability_K=40.pdf}\label{fig:scalability_40}} \vspace{1mm} \caption{Execution time as a function of the number of edges of the graph.\vspace{-3mm}} \end{figure} \section{Conclusions} Graph reduction techniques are commonly used in modern graph processing and machine learning pipelines in order to facilitate the processing and analysis of large graphs. Nevertheless, more often than not these techniques have been designed based on intuition and possess no rigorous justification or provable guarantees. This work considered the graph reduction problem from the perspective of restricted spectral approximation---a modification of the measure utilized for the construction of graph sparsifiers. This measure is especially relevant when restricted to Laplacian eigenspaces of small variation, as it implies strong spectral and cut guarantees. The analysis of restricted spectral approximation has lead to new nearly-linear time algorithms for graph coarsening that provably approximate (a portion of) the graph spectrum, as well as the cut structure of a large graph. A number of important questions remain open at the point of concluding this manuscript. To begin with, I am currently unaware of a rigorous way to determine how much one may benefit from reduction---that is, how small can $\epsilon$ be for a specific subspace and target $n$? In addition, no polynomial-time algorithm for graph coarsening exists that provably approximates the minimal achievable $\epsilon$. Finally, though I lack a formal proof, I also suspect that stronger cut guarantees can be derived from restricted spectral approximation. I argue that the potential of graph reduction cannot be fully realized until these fundamental questions are satisfactorily addressed. \paragraph{Acknowledgements.} This work was kindly supported by the Swiss National Science Foundation (SNSF) in the context of the project ``\emph{Deep Learning for Graph-structured Data}'', grant number PZ00P2$\_$179981. I would also like to thank Rodrigo C. G. Pena and Nguyen Q. Tran for their useful comments.
\section{Introduction} In 1979 Balasz and Berry \cite{berry} demonstrated that the Airy function is a non-diffracting solution of the Schr\"odinger equation of a free particle in one dimension. As well as being non-spreading, this solution also has the unique property of appearing to accelerate at a constant rate, even in the absence of an external force. Following on from this result, a great deal of work has been done both theoretically and experimentally to study this type of behaviour, with a particular eye to harnessing its unusual properties for applications such as particle manipulation \cite{ballistic,particle_clearing}, optical routing \cite{routing}, and microscopy \cite{microscopy}. The first experimental observations of Airy wavepackets were made in an optical system \cite{siviloglou}, making use of the correspondence between the paraxial diffraction equation and the Schr\"odinger equation. Later work showed how Airy wavepackets of free electrons could be generated \cite{electron_airy}, and more recently, it has been suggested to use systems of Bose-Einstein condensates \cite{wolf,yuce_mod}, in order to generate self-accelerating matter waves. The majority of studies have concentrated on the continuum case. Lattice systems, however, represent a fascinating arena to investigate and make use of the dynamics of Airy wavepackets. Such systems must clearly reproduce the continuum behaviour as the lattice spacing is reduced to zero, but can be expected to show novel features arising from the interplay between the spatial discretization and the self-acceleration effect. In particular, systems of ultracold atoms held in optical lattice potentials \cite{lewenstein} are excellent candidates for studying these effects, due to their high degree of quantum coherence and their controllability \cite{jaksch}. Such systems have already been used as idealized lattice simulators to emulate the quantum dynamics of condensed matter systems, such as the Hofstadter butterfly \cite{aidelsburger,ketterle}, the direct observation of Bloch oscillations \cite{bloch_oscs}, and Veselago optics \cite{veselago_lens}. In this work, we investigate the dynamics of an Airy wavepacket moving on a tight-binding lattice. We will firstly see that the initial behaviour of this system duplicates that of the continuum case, with the wavepacket undergoing a constant acceleration. For longer times, however, this acceleration reduces towards zero and the velocity of the wavepacket saturates to a maximum value. This is a direct effect of the spatial discretization, since the speed of propagation in the lattice is bounded by the lattice dispersion relation. As a consequence the kinematics of the system is described very accurately by the formalism of special relativity, with the lattice group velocity playing the role of the ``speed of light''. Rather unexpectedly, this relativistic description emerges spontaneously from the dynamics of the standard non-relativistic Schr\"odinger equation. This contrasts, for example, with the behaviour of Gaussian wavepackets in a tilted lattice; these are also subject to a constant accelerating force, but instead undergo Bloch oscillation \cite{zener,bloch}. We then show how Floquet engineering \cite{floquet} allows us to manipulate the system's dispersion relation, and thus control the propagation of the wavepacket. This demonstrates how using Airy wavepackets in lattice potentials is a convenient and powerful method to simulate relativistic quantum systems. \section{Airy wavepacket} \subsection{Self-acceleration} We begin by considering the Schr\"odinger equation for a particle of mass $m$, moving in a one-dimensional system in the absence of any external potentials \begin{equation} i \hbar \frac{\partial \psi}{\partial t} = - \frac{\hbar^2}{2 m} \ \frac{\partial^2 \psi}{\partial x^2} \ , \label{schrod} \end{equation} where $x$ represents a dimensionless spatial coordinate and $t$ is the corresponding time coordinate. For convenience we shall now set $m$ and $\hbar$ equal to one. As was shown in Ref.\cite{berry}, a solution of Eq. \ref{schrod} is given by the Airy function \footnote{This corresponds to the solution given in Ref.\cite{berry} with the explicit parameter choice of $B / \hbar^{2/3} = 1$.} \begin{equation} \psi(x,t) = \mathrm{Ai} \left( x - (t/2)^2 \right) \exp\left( i \left( x t / 2 \right) - i t^3 / 12\right) \ , \label{airy} \end{equation} which can be readily verified by direct substitution. We plot the corresponding probability density for $t=0$ in Fig. \ref{initial_state}. For $x > 0$, the Airy function decays rapidly with the form $\mathrm{Ai}(x) \sim \exp\left[ -2 x^{3/2} / 3 \right] / x^{1/4}$, which produces the well-defined wavefront at the right of the wavepacket. Conversely, for large negative values of $x$, the Airy function has a decaying oscillatory form \cite{stegun} \begin{equation} \mathrm{Ai}\left( x \rightarrow - \infty \right) \sim \frac{1}{ \sqrt{\pi} \left| x \right|^{1/4}} \sin \left( 2 \left| x \right|^{3/2} / 3 + \pi / 4 \right) \ . \label{asymptotic} \end{equation} From Eq. \ref{airy} it is clear that the probability density, $\left| \psi(x,t) \right|^2$ preserves its shape over time, and that it follows a parabolic trajectory $x(t) = t^2/4$, that is, it appears to undergo a constant acceleration of $a = 1/2$ in the system of units we use. Although this non-intuitive result would appear to violate the Ehrenfest theorem, this is not in fact the case. As can be seen from Eq. \ref{asymptotic}, the Airy wavefunction is not $L^2$ integrable, and so its centre of mass is undefined. Consequently we cannot interpret the acceleration as the response of the system's centre of mass to a force. If instead, however, we focus our attention on some specific points of the wavefunction, such as, for example, the maxima of the probability distribution, we will indeed see the locations of these points moving along parabolic trajectories in the $x-t$ plane (see Fig. \ref{trajectory} for small values of $t$.) For the remainder of the paper we will concentrate on the motion of the first, and highest intensity, peak of the wavefunction, which at $t=0$ is centered on $x \simeq -1.019$, and use its position to calculate the wavepacket's velocity and acceleration. As this acceleration arises spontaneously, in the absence of any external potentials, we shall refer to it as ``self-acceleration''. \begin{figure} \begin{center} \includegraphics[width=0.45\textwidth,clip=true]{fig_1} \end{center} \caption{Probability density of the Airy wavepacket given in Eq. \ref{airy} at $t=0$. For positive values of $x$ the probability density drops sharply with distance, while for negative $x$ the function has a decaying oscillatory behaviour. The slowness of this decay (\ref{asymptotic}) means that the Airy function is not normalizable. Under the action of the Hamiltonian in Eq. \ref{schrod} this wavepacket will accelerate to the right at a constant rate.} \label{initial_state} \end{figure} \subsection{Normalization and diffraction \label{diffraction}} As the probability density is not normalizable, a true Airy wavepacket can clearly not be prepared in experiment. One option is to use an aperture-limited version of the function, by simply truncating the spatial coordinate to run over a large, but finite, range of values. Smoother aperture functions can also be used to render the wavefunction normalizable, for example, an exponential function, $\psi(x, t=0) = \mathrm{Ai}(x) \exp \left( \gamma x \right)$, where $\gamma$ is a small, positive constant. The Fourier transform of this function is given by \begin{equation} \tilde{\psi} (k) \propto e^{- \gamma k^2} e^{i k^3/3} \ , \label{transform} \end{equation} where the cubic phase term arises from the Fourier transform of the Airy function itself. This provides a particularly convenient way to synthesize aperture-limited Airy functions in optical systems \cite{siviloglou}, by simply imprinting a cubic phase on a Gaussian beam using a phase mask, and then making an optical Fourier transform of the result. An analogous technique is also possible for matter-wave optics \cite{electron_airy,wolf} to engineer the appropriate wavefunction in Fourier space, or alternatively amplitude and phase masks can be used to generate the wavefunction directly in real-space \cite{wolf}. Truncating the Airy function has the consequence that the wavepacket is no longer diffraction-free, and so it broadens with time. This distance, over which the truncated Airy wavepacket approximately maintains its form, is known as the Airy zone \cite{airy_zone}, and its size reduces as the degree of truncation is increased. The majority of the results we report below were obtained by simply limiting the range of the spatial coordinate, and in each case it was verified that the range of $x$ used was sufficiently large that the results were insensitive to it over the time-intervals considered. The simulations were also repeated using an exponential aperture function for various values of $\gamma$ as a further check of the stability of the observed effects. \subsection{Lattice Airy wavepacket} Instead of allowing the particle to move in free space as in Eq. \ref{schrod}, we now impose a lattice potential $V(x) = V_0 \cos^2 k x$. In ultracold atom experiments, this can be conveniently done by superposing two counter-propagating laser beams \cite{optical_lattice} to create an optical lattice potential whose depth, $V_0$, is proportional to the laser intensity. For sufficiently deep optical lattices, the atoms will localize in the potential minima, and can accordingly be described in a basis of site-localized Wannier functions. In this case the dynamics of the atoms can be accounted for well by retaining only the hopping matrix element $J$ that connects a site to its nearest neighbours \cite{jaksch}, yielding the lattice Hamiltonian \begin{equation} H_\mathrm{latt} = -J \sum_{j = -M}^{N} \left( a^\dagger_{j+1} a_j + \mathrm{H.c.} \right) \ . \label{lattice_ham} \end{equation} Here $a_j (a_j^\dagger)$ are the usual bosonic annihilation (creation) operators acting on lattice site $j$. The hopping amplitude $J$ is related to the parameters of the continuum Hamiltonian as $J = \hbar^2 / \left( 2 m \Delta x^2 \right)$, where $\Delta x$ is the lattice spacing which relates the $x$-coordinate to the lattice site, $x = j \Delta x$. Henceforth we will use $J$ as the unit of energy and frequency, and measure time in units of $J^{-1}$. \section{Results} \subsection{Motion of the lattice Airy wavepacket} In Fig. \ref{trajectory} we show the movement of a wavepacket initialized in the state $\psi(x) = \mathrm{Ai}(x)$, where $x$ is a discretised spatial coordinate with $\Delta x = 0.2$, under the time evolution provided by the lattice Hamiltonian (\ref{lattice_ham}). At $t=0$ we see the series of peaks in the probability density produced by the $x$-dependence of the Airy function, with the largest peak lying at $x \simeq -1$. For small values of $t$ ($t < 80$), the peaks in the probability density move along trajectories which to a good degree of accuracy are parabolic. We emphasise that this effect is occurring in the absence of any accelerating potentials, and so corresponds to the wavepacket undergoing a constant self-acceleration. \begin{figure} \begin{center} \includegraphics[width=0.40\textwidth,clip=true]{fig_2} \end{center} \caption{Trajectory of an Airy wavepacket on a lattice. The system is initially prepared in an Airy state, and evolves under the action of the lattice Hamiltonian (\ref{lattice_ham}). Initially the peaks in the wavepacket move along parabolic trajectories corresponding to a uniform positive acceleration, marked by the white dashed line. At longer times, however, the acceleration of the wavepacket decreases as it approaches relativistic speeds. Note that the amplitudes of the peaks decrease with time due to wavepacket spreading; this occurs because the Airy wavepacket is aperture limited (see Sec.\ref{diffraction}). Lattice discretization, $\Delta x = 0.2$.} \label{trajectory} \end{figure} For longer times, however, the movement of the peaks clearly begins to deviate from the parabolic behaviour, with their location showing a slower, linear dependence on time. This contrasts with the behaviour of the continuum Airy wavepacket, which would continue to accelerate indefinitely. To see the reason for this discrepancy we can first note that the lattice Hamiltonian (\ref{lattice_ham}) can be straightforwardly solved in momentum space \begin{equation} \tilde{H}_\mathrm{latt} = -2 J \cos k \ \sum_k a_k^\dagger a_k \ , \label{kspace_ham} \end{equation} giving the dispersion relation $E(k) = -2 J \cos k$. For small $k$ this reproduces the dispersion relation of a free particle $E_\mathrm{free} = k^2 / 2$, but unlike the free particle case, $E(k)$ is limited to a finite range. As a consequence, the group velocity, $v_g = 2 J \sin k$, has a maximum value of $2 J$, and so the system can only support excitations up to this maximum velocity $v^\mathrm{max}$. This is a specific instance of the Lieb-Robinson bound \cite{lieb}. This motivates us to employ a relativistic description of the system, with this maximum velocity playing the role of the speed of light. \subsection{Relativistic description} There is a frequent misconception that the case of a body subject to a constant acceleration cannot be treated within special relativity, but instead necessitates the use of general relativity. This, however, is not the case; special relativity is completely capable of describing such motion \cite{desloge}. We wish to relate the kinematic quantities measured by an observer at rest with respect to the laboratory (or lattice), with those measured in a uniformly accelerated frame (the instantaneous rest-frame of the Airy wavepacket). If we denote the (constant) proper acceleration by $\alpha$, then it is a standard textbook exercise \cite{french} to show that the quantities measured in the laboratory frame are given by \begin{eqnarray} a(t) &=& \alpha / \left( 1 + \left( \alpha t / c \right)^2 \right)^{3/2} \label{accel} \\ v(t) &=& \alpha t / \sqrt{ 1 + \left( \alpha t / c \right)^2 } \label{velocity} \\ x(t) &=& \left( c^2 / \alpha \right) \left( \sqrt{ 1 + \left( \alpha t / c \right)^2 } - 1 \right) \label{space} \ , \end{eqnarray} where $c$ represents the speed of light, and we have imposed the initial conditions $x(0) = v(0) = 0$. In the non-relativistic limit $\alpha t \ll c$ it can readily be seen that these expressions reduce to the familiar results of Newtonian mechanics, and in particular that $x = \mbox{\nicefrac{1}{2}} \ \alpha t^2$. In general, we can cast Eq. \ref{space} in the more revealing form \begin{equation} \left( \alpha x / c^2 + 1 \right)^2 - \left(\alpha t / c \right)^2 = 1 \ , \label{hyperbola} \end{equation} to show that the particle follows a {\em hyperbolic} trajectory in space-time \cite{rindler}. The asymptotes of this trajectory are the two straight lines $x = \pm c t$, which form the light-cone for this object. The slopes of these lines bound the velocity of the wavepacket velocity (\ref{velocity}) such that it never exceeds $c$, but approaches it asymptotically with time. In Fig. \ref{rel} we show the motion of the first peak of the Airy wavepacket, for the same parameters as in Fig. \ref{trajectory}. The data-points in Fig. \ref{rel}a are the motion of the peak obtained from the numerical time-integration of the system, while the solid line is the relativistic result for $x(t)$, where $\alpha$ and $c$ were obtained from a two-parameter fit of the numerical data to Eq. \ref{space}. The agreement between the data and the fit is excellent. The fit parameters are given in the first line of Table \ref{values}, and we can see that the obtained value of $c$ is indeed in good agreement with the theoretical value of $v^\mathrm{max} = 2 J$. We also show in this figure the parabolic behaviour that would be obtained in the non-relativistic case, which clearly emphasizes the difference between the relativistic discrete case, and the non-relativistic continuum behaviour. Below in Fig. \ref{rel}b we compare the velocity of the main peak, as calculated by the time-derivative of its location, with the relativistic prediction of Eq. \ref{velocity}. Again the agreement is seen to be excellent. The maximum lattice group velocity of $2 J$ is also plotted, and the asymptotic saturation of the peak's velocity to this value is clearly evident. Finally, in Fig. \ref{rel}c we show the acceleration of the wavepacket, as measured in the lattice rest frame. As the velocity of the wavepacket approaches a significant fraction of $c$, this acceleration reduces smoothly to zero. \begin{figure} \begin{center} \includegraphics[width=0.45\textwidth,clip=true]{fig_3} \end{center} \caption{Relativistic motion of the lattice Airy wavepacket, obtained by a numerical simulation of the lattice system. \newline (a) Symbols denote the lattice site occupied by the first peak of the wavepacket. Initially this position increases quadratically with time, shown by the dashed line, but for $t > 100$ the increase becomes slower, tending towards a linear rise. The solid line shows the relativistic prediction (\ref{space}), where the values of $c$ and $\alpha$ are obtained from a two-parameter fit to the data-points. The fit is seen to be excellent. (b) Velocity of the first peak of the lattice Airy function. Symbols show that values obtained from the numerical time-derivative of the data from the simulation, while the solid line shows the theoretical result (\ref{velocity}). Initially the velocity rises linearly, but flattens off as it begins to approach the maximum lattice velocity $v^\mathrm{max}$, shown with the dashed line. (c) Acceleration observed in the rest-frame of the lattice. For small times the acceleration is constant, but drops as the wavepacket enters the relativistic regime. The dashed line indicates the proper acceleration, $\alpha$, which remains constant.} \label{rel} \end{figure} \begin{table} \begin{center} \begin{tabular}{ |c|c|c| } \hline $\Delta x$ & $c$ & $\alpha$ \\ \hline \hline 0.20 & 1.90 & 0.0153 \ \\ 0.15 & 1.85 & 0.0065 \ \\ 0.10 & 1.81 & 0.0020 \ \\ 0.05 & -- & 0.00025 \ \\ \hline \end{tabular} \caption{Values of $\alpha$ and $c$ obtained by a two-parameter fit to Eq. \ref{space} for various values of the lattice spacing $\Delta x$. The acceleration $\alpha$ rapidly reduces as the lattice becomes finer, and for the smallest value of $\Delta x$ the wavepacket barely entered the relativistic regime in the time-span considered. As a result the two-parameter fit was unstable, and $\alpha$ was simply evaluated from a fit to a parabola. In all other cases the value obtained for $c$ is in good agreement with the theoretical value of $v^\mathrm{max} = 2 J$.} \label{values} \end{center} \end{table} \subsection{Fitting and scaling} In Table \ref{values} we show values obtained for $\alpha$ and $c$ by fitting the numerical results for different lattice spacings to Eq. \ref{space}. Clearly, as $\Delta x$ is reduced, the value of the proper acceleration decreases as well. For $\Delta x = 0.05$, the smallest lattice spacing considered, the acceleration was so small that the wavepacket did not enter the relativistic regime over the time-interval considered. The length of this time-interval was limited by the spreading of the wavepacket, produced by the aperture restriction of the wavepacket. During this simulation time, the wavepacket thus appeared to accelerate uniformly, which corroborates our intuition that the behaviour of the discrete wavepacket should approach that of the continuum case as $\Delta x \rightarrow 0$. To put this observation on a quantitative basis, we show in Fig. \ref{scaling} a logarithmic plot of the measured values of the self-acceleration as a function of the lattice discretization. The linear behaviour visible clearly implies a power-law dependence of $\alpha$ on $\Delta x$. To analyze this further, and to investigate how the continuum result emerges as the lattice spacing reduces to zero, we first recall that in the continuum case $x(t) = \mbox{\nicefrac{1}{2}} \ a t^2$, where for the Airy solution we consider, $a = 1/2$. Writing the time coordinate in the lattice units of $J^{-1}$, we find that \begin{equation} x(t) = \Delta x \ n(t) = \frac{1}{2} a \ \left( 2 \Delta x^2 t \right)^2 \ , \end{equation} where $n(t)$ is the lattice site occupied by the peak of the wavepacket. The self-acceleration of the wavepacket measured in lattice-units is thus $\alpha = 4 a \Delta x^3$, and so we should expect to see the power-law dependence $\alpha(\Delta x) = 2 \Delta x^3$. We plot this curve in Fig. \ref{scaling}, and indeed find that it describes the scaling of $\alpha$ extremely well. \begin{figure} \begin{center} \includegraphics[width=0.45\textwidth,clip=true]{fig_4} \end{center} \caption{Values of the proper self-acceleration $\alpha$, obtained by curve-fitting the numerical results to Eq. \ref{space}. The scaling of this quantity is described well by the power-law $\alpha = 2 \Delta x^3$, shown by the dashed red line.} \label{scaling} \end{figure} \subsection{Bloch oscillation} It is interesting to compare the case of the Airy wavepacket with that of a particle in a tilted lattice potential, that is, a potential which rises linearly in space, $V(x) \propto x$, \begin{equation} H_{\mathrm{BO}} = H_\mathrm{latt} + V_0 \sum_j j n_j \ , \label{hamiltonian_BO} \end{equation} where $V_0$ is the difference in potential between neighboring sites, and $n_j$ is the standard number operator. Naively, one could interpret the lattice tilt as resulting from the application of a constant force (since $F = - \partial V / \partial x$), and so one would expect the wavepacket to uniformly accelerate in the direction of the tilt. The presence of the lattice, however, complicates this simple picture; although the wavepacket will initially accelerate, it will also experience Bragg diffraction from the lattice potential. The result is that it will undergo an oscillatory motion termed Bloch oscillation \cite{bloch,zener}. If the initial state of the particle is a well-localized wavepacket, it is straightforward to show that the position of its centre of mass is given by \cite{holthaus_bloch,dynamics_bloch} \begin{equation} x(t) = 2 \left( J / V_0 \right) \ \left( 1 - \cos V_0 t \right) \ , \label{com} \end{equation} where for convenience we have set the initial condition $x(t) = 0$. In Fig. \ref{bloch}a we show the numerical simulation of a broad Gaussian wavepacket under the action of the tilted lattice Hamiltonian (\ref{hamiltonian_BO}). The oscillatory motion of the wavepacket is clear, the amplitude and frequency of the oscillation being related to the size of the tilt. For small values of $t$, we can make a Taylor expansion of Eq. \ref{com}, to reveal that it indeed begins to accelerate uniformly, with $a = 2 J / V_0$. As with the discretised Airy wavepacket, this acceleration reduces with time, but in contrast to the Airy case it does not follow a relativistic form. Rather than asymptotically approaching the maximum lattice velocity, the wavepacket instead slows and eventually turns around, and begins propagating in the opposite direction. \begin{figure} \begin{center} \includegraphics[width=0.45\textwidth,clip=true]{fig_5a} \includegraphics[width=0.45\textwidth,clip=true]{fig_5b} \end{center} \caption{Bloch oscillation of a Gaussian wavepacket in a tilted lattice. (a) Probability density of the wavepacket as a function of time. The wavepacket makes a slow oscillatory motion (Bloch oscillation) described by Eq. \ref{com}. (b) Probability density in momentum space, $ \left| \tilde{\psi}(k,t)|^2 \right|$ for the same system. The sharply-peaked distribution moves linearly with time across the first Brillouin zone, crossing the boundary at $t= 500$, corresponding to the reversal of motion of the wavepacket in space. Parameters of the system: $\Delta x = 0.2$, $V_0 = 2 J \pi / 1000$.} \label{bloch} \end{figure} The difference between this behaviour and that of the discretised Airy wavepacket is even clearer in momentum space. In Fig. \ref{bloch}b we show the Fourier transform of the Bloch oscillation; the broad Gaussian wavepacket in real space becomes a narrow Gaussian in momentum space. The effect of the lattice tilt is that the momentum distribution shifts linearly with time, $k(t) = V_0 t$, obeying the classical equation of motion $F = \partial k / \partial t$. When the momentum reaches the edge of the first Brillouin zone at $k=\pi$, it wraps around it and reenters at $k = -\pi$, corresponding to the wavepacket's motion reversing. In contrast, the momentum distribution of the Airy wavepacket does not alter with time (within the Airy zone), even though we see the peaks of the wavepacket appearing to accelerate along hyperbolic trajectories. \footnote{An alternative way of visualizing this is to see that $H_\mathrm{latt}$ commutes with $k$, and so the momentum of the Airy wavepacket cannot change. Introducing the tilt breaks this conservation law, and so the mean momentum is time-dependent in the case of Bloch oscillation.}. This underlines the importance of taking care when discussing the Airy dynamics. The Gaussian wavepacket obeys Ehrenfest's theorem, and so we can consider its centre of mass to be accelerated by the applied force. This is not the case for the Airy wavepacket. Here the self-acceleration arises from quantum interference effects, which depend on the entire form of the wavefunction. \subsection{Wavepacket manipulation} We have seen that the critical factor determining the propagation of the lattice Airy wavepacket is the maximum velocity of excitations in the lattice, $v^\mathrm{max}$. In turn this depends on the hopping parameter $J$, indicating that if we can alter $J$ coherently we will be able to finely control the trajectory of the wavepacket. A powerful method to achieve this is provided by Floquet engineering \cite{floquet}. In this approach, the lattice potential is periodically driven in time, or ``shaken'', at a frequency much higher than the other time-scales of the problem. In this high-frequency limit, the full time-dependent Hamiltonian can be described by a static effective Hamiltonian with renormalized parameters. In particular, for the hopping Hamiltonian (\ref{lattice_ham}), the tunneling is renormalized to an effective value $J_\mathrm{eff}$, and manipulating the parameters of the shaking permits the value of $J_\mathrm{eff}$ to be adjusted. We will consider the standard form of driving \begin{equation} H(t) = H_\mathrm{latt} + K \cos \omega t \ \sum_j j n_j \ , \label{driving} \end{equation} in which the potential has a sinusoidal dependence on time. The behaviour of this Hamiltonian was studied in Ref.\cite{holthaus} in the context of periodically-driven semiconductor superlattices, and for the specific case of sinusoidal driving \cite{crossings}, the effective tunneling has the dependence \begin{equation} J_\mathrm{eff} = J \ {\cal J}_0 \left( K / \omega \right) \ , \label{bessel} \end{equation} where ${\cal J}_0$ is the zeroth order Bessel function of the first kind. For convenience we will use the notation $K_0 = K / \omega$ to denote the dimensionless argument of the Bessel function. This form of driving has been used in cold atom experiments \cite{lignier}, and the Bessel function dependence of the tunneling has been directly observed \cite{creffield_pisa,guery}. The form of $J_\mathrm{eff}$ is shown in Fig. \ref{ref_index}a. We can note that at $K_0 \simeq 2.4048$, the first root of the Bessel function, the effective tunneling vanishes. This produces the effect known as CDT (``coherent destruction of tunneling'') \cite{cdt}, in which the tunneling dynamics of the system is completely quenched. This effect has been used to induce the Mott transition \cite{mott_theory,mott_expt}, and to control the motion of quantum particles on lattices \cite{creffield_control}. \begin{figure} \begin{center} \includegraphics[width=0.45\textwidth,clip=true]{fig_6} \end{center} \caption{(a) The effective tunneling, $J_\mathrm{eff}$, for a sinusoidally driven lattice has a Bessel function dependence on the driving parameter, given by Eq. \ref{bessel}. The symbols mark the values of $K_0$ used to obtain the results shown in Fig. \ref{driven}. For $K_0 = 0.5$, the amplitude of the tunneling is slightly reduced from its undriven value. At $K_0 = 1.691$, $J_\mathrm{eff} = 0.403$, while at $K_0 = 2.4048$ the effective tunneling vanishes. For $K_0 > 2.4048$, the shaded area, the effective tunneling is negative; at $K_0 = 3.80$ the negative effective tunneling takes its maximum value. (b) We denote the ratio of $v^\mathrm{max}$ in the undriven system to $v^\mathrm{max}$ in the driven system as the refractive index. As $K_0$ approaches the first zero of the Bessel function, the refractive index increases, and diverges at $K_0 = 2.4048$. In the shaded region, the refractive index is negative.} \label{ref_index} \end{figure} If we prepare the system as a lattice Airy wavepacket and allow it to evolve freely, we have seen that it will undergo a relativistic acceleration with its velocity approaching arbitrarily close to the maximum lattice velocity $v^\mathrm{max} = 2 J$, giving it a photon-like behaviour. This can also be achieved by giving the wavepacket a kick, by imprinting a phase on it of the form $\exp \left[ i \phi j \right]$, where $j$ labels the lattice site, which imposes an initial velocity of $v = 2 J \sin \phi$ on the wavepacket. By using a value of $\phi$ close to $\pi/2$ we can thus place the wavepacket deep in the relativistic regime without waiting for it to accelerate to this state from rest. Although the results reported in this section were obtained by means of this phase-imprinting technique, we have verified that the same results are obtained by allowing the wavepacket to self-accelerate to this regime. If we consider the propagation to be photon-like, with $v^\mathrm{max}$ playing the role of the speed of light, then controlling the magnitude of $J$ gives us control of a quantity analogous to the refractive index. This will be the ratio of $v^\mathrm{max}$ in the undriven system to the maximum velocity when the lattice is shaken, which is simply given by $J / J_\mathrm{eff}$. We plot this quantity in Fig. \ref{ref_index}b. For $K_0 < 2.4048$, the refractive index rises from its initial value of 1, showing how the speed of light in the lattice drops. At the zero of the Bessel function, the refractive index diverges, corresponding to the system becoming infinitely optically dense. For larger values of $K_0$ the refractive index becomes {\em negative}, indicating that in this regime (shaded grey) negative refraction \cite{veselago} occurs. In Fig. \ref{driven} we show the probability densities for Airy wavepackets under various driving conditions, obtained by the numerical simulation of the full time-dependent Hamiltonian (\ref{driving}). In all cases the initial amplitude of the driving was set to $K_0 = 0.5$, giving a refractive density of $1.07$, meaning that the Airy wavepacket moved at a slightly lower velocity than in the absence of driving. At $t=30$ the amplitude of the driving is abruptly changed to a different value, and then restored to $K_0 = 0.5$ at $t=60$. \begin{figure*} \begin{center} \includegraphics[width=0.23\textwidth,angle=-90,clip=true]{fig_7a_small} \includegraphics[width=0.23\textwidth,angle=-90,clip=true]{fig_7b_small} \includegraphics[width=0.23\textwidth,angle=-90,clip=true]{fig_7c_small} \end{center} \caption{Trajectories of an Airy wavepacket in a driven lattice, simulation parameters: $\omega = 2 \pi$, $\Delta x = 0.2$. In all cases $K_0$ is initially set to a value of $K_0 = 0.5$, for which $J_\mathrm{eff}$ is slightly reduced from its undriven value. At $t= 30$, $K_0$ is abruptly changed to another value, while at $t = 60$ it reverts to is original value; these boundaries are marked by the vertical dashed lines. (a) Between $t=30$ and $t=60$, $K_0$ is set to a value of $K_0 = 1.691$. In this time interval the velocity of the wavepacket is reduced by more than half, and the peaks appear to undergo refraction at the boundaries described by Snell's law. (b) By tuning $K_0$ to a zero of the Bessel function ($K_0 = 2.4048$), the wavepacket's motion is frozen. This corresponds to the medium's refractive index diverging, producing an analogous effect to ``stopped light''. (c) Setting $K_0 = 3.80$ causes the wavepacket to reverse its motion since the effective tunneling becomes negative. This behaviour mimics the phenomenon of negative refraction.} \label{driven} \end{figure*} Fig. \ref{driven}a shows the result of reducing $J_\mathrm{eff}$ to a smaller, but positive value. It can be seen that the trajectories of the peaks change their angle of propagation with respect to the $t$-axis, and the peaks continue moving along relativistic linear paths. The adjustment of their velocity to the lower value of $v^\mathrm{max}$ appears to occur essentially instantaneously, and does not cause any appreciable deformation of the wavepacket's profile. When $K_0$ is restored to its previous value, the original form of propagation of the wavepacket resumes, with the trajectories moving parallel to their original course. This behaviour strongly resembles the standard refraction of light by a slab of material with a positive refractive index. In Fig. \ref{driven}b we show the effect of tuning $K_0$ to a value of 2.404, close to the zero of the Bessel function. In this case the refractive index diverges, and when the lattice is driven at this value of $K_0$ the motion of the wavepacket is completely frozen. This is analogous to the phenomenon of slow or ``stopped'' light \cite{slow_light} previously seen in ultracold gases by using electromagnetically induced transparency to manipulate the refractive index. Finally, Fig. \ref{driven}c shows the behaviour of the wavepacket when the effective tunneling is renormalized to a negative value. The motion of the peaks now reverses while this condition is fulfilled, mimicking the effect of a light ray traversing a region with negative refractive index. \section{Conclusions} We have studied the dynamics of an Airy wavepacket moving in a lattice potential. Like its continuum counterpart \cite{berry}, the lattice Airy wavepacket undergoes self-acceleration, but due to the limitation on the maximum speed of propagation arising from the lattice structure, this acceleration reduces in time in accordance with relativistic kinematics. This contrasts with the case of a particle on a lattice subjected to a constant force. While the limited range of velocity also plays a role in this case, the particle instead follows an oscillatory motion -- Bloch oscillation -- in which its velocity periodically cycles between $\pm v^\mathrm{max}$. We summarize these three different forms of motion in Fig. \ref{summary}. \begin{figure}[t] \begin{center} \includegraphics[width=0.5\textwidth,clip=true]{fig_8} \end{center} \caption{Three different forms of behaviour for accelerated quantum systems. The velocity of a continuum Airy wavepacket rises linearly with time, and increases without limit. In contrast, in a discrete lattice system, the velocity initially rises linearly, but asymptotically approaches the value of $v^\mathrm{max}$, which acts as the speed of light in this system. It should be noted that in this case, the proper acceleration of the wavepacket indeed stays constant. Finally, tilting the lattice potential subjects a wavepacket to a constant uniform force. The presence of the lattice, however, means that the wavepacket does not accelerate uniformly, but instead undergoes Bloch oscillation.} \label{summary} \end{figure} Lattice Airy wavepackets thus provide a means to observe relativistic effects by lowering the effective speed of light to a level which is rather convenient for experiment. This opens avenues to simulate systems which are otherwise rather resistant to physical realization, such as the relativistic harmonic oscillator \cite{relativistic_ho}, as well as employing relativistic effects to produce more exotic effects such as enhancing the lifetimes of unstable particles via time dilation \cite{dirac_airy}. We have also shown how the trajectory of the lattice Airy wavepacket can be manipulated by driving the lattice. This high level of controllability, as opposed to the single ballistic path \cite{ballistic} of the continuum case, makes these wavepackets ideal candidates to convey matter coherently from one point in a lattice to another, with many possible applications to quantum information transfer \cite{bus}. In the deep relativistic limit, in which the wavepacket's motion is photon-like, this control over the trajectory can be used to mimic a material with negative refractive index, and could in the future be used to study perfect lensing \cite{pendry} of matter waves. Finally, we turn to possible experimental implementations of this system. The driven lattice experiments of Ref.\cite{lignier} for example, used a gas of approximately $10^5$ ultracold ${ }^{87}\mathrm{Rb}$ atoms, held in an optical lattice with a well-spacing of 426 nm and a tunneling frequency of $J \sim 100$Hz. This corresponds to an effective value of the speed of light of $v^\mathrm{max} = 85 \ \mu\mathrm{m/s}$, 12 orders of magnitude smaller than $c$ in free space. If we take a lattice spacing of $\Delta x = 0.2$, so that the first and second peaks of the Airy wavepacket are separated by 12 lattice spacings, then from Table \ref{values} we can see that $\alpha = 0.015$ in lattice units. This translates to $64 \ \mu\mathrm{m} / \mathrm{s}^2$ in physical units, using these values for $d$ and $J$. Thus over a time evolution of one second the wavepacket would move $\sim 75$ lattice spacings, which should be easily resolvable using quantum gas microscopy \cite{bloch_oscs,greiner,microscope}. In Ref.\cite{wolf} it was noted that atomic interactions did not effect the motion of the continuum wavepacket much, except in the limit of very strong interactions for which it would decay by shedding solitons. Accordingly we believe that for weak to moderate interactions, the lattice Airy wavepacket should be realizable in state-of-the-art experimental setups. Including the effects of interactions and temperature, and generalizing these results to higher dimensions, remain fascinating subjects for future research. \acknowledgments This work has been supported by Spain's MINECO through Grant Nos. FIS2013-41716-P and FIS2017-84368-P. \bibliographystyle{aipnum4-1}
\section{Introduction} A major outstanding question in fundamental physics is the origin of the cosmological matter-antimatter asymmetry. While the necessary requirements to generate a baryon asymmetry are the well known Sakharov conditions, namely (i) violation of baryon number (B), (ii) violation of C and CP symmetries (CPV) and (iii) departure from thermal equilibrium, the exact mechanism is yet to be established. Importantly, any mechanism that adequately fulfills these three requirements will require the introduction of new particles and interactions, beyond those that exist in the Standard Model. A well studied mechanism is that of electroweak baryogenesis~(EWBG)~\cite{Morrissey:2012db,Trodden:1998ym,Cline:2006ts,Riotto:1998bt} where an asymmetry is generated via CP violating interactions during a first order electroweak phase transition with the requisite B violation provided by electroweak sphalerons. The SM must be augmented with new physics to make this scenario viable. An extended scalar sector is required to produce a strongly first order phase transition, which is necessary to fulfill the out-of-equilibrium requirement. In addition, new sources of CPV must be introduced as the SM Jarlskog factor is suppressed by small CKM matrix elements and small quark masses. These challenges notwithstanding, electroweak baryogenesis has the appealing feature of being a weak-scale mechanism and thus eminently testable. This is to be contrasted with high scale baryogenesis mechanisms, such as the out-of-equilibrium decay of a heavy particle. Leptogenesis~\cite{Davidson:2008bu,Buchmuller:2005eh,Fukugita:1986hr} (type-I) is a particularly elegant example of such a scenario in which heavy singlet neutrinos - introduced to allow the seesaw mechanism - decay to lepton and antilepton final states with unequal rates. The resulting lepton asymmetry is subsequently converted to a baryon asymmetry via SM sphaleron processes. While the mechanism is very simple and requires minimal new physics, the energy scale is inaccessible to experiments, being $\agt 10^{10}$~GeV in the simplest scenarios. In this paper we consider an out-of-equilibrium decay process which occurs at an experimentally accessible energy scale. In this sense, the mechanism shares the endearing features of both leptogenesis and EWBG. Notably, the asymmetry will be generated below the electroweak phase transition such that sphalerons play no role. The specific model we consider is a generalization of the ``post-sphaleron baryogenesis'' first introduced in Ref.~\cite{Babu:2006xc}, in which the B asymmetry is directly produced by the decays of a new scalar, $\Phi_r$: $\Phi_r\rightarrow 6q$ and $\Phi_r\rightarrow 6\overline{q}$. Importantly, the new physics in this model violates baryon number by two units, $\Delta B=2$. This renders the physics safe from the proton decay constraints that plague $\Delta B=1$ baryon number violating interactions, such as those in older GUT baryogenesis models. Because testable low energy baryogenesis mechanisms are relatively rare, this post-sphaleron baryogenesis idea warrants further investigation, which is the purpose of this paper. Similar models have been studied in a non-baryogenesis context in \cite{Arnold:2012sd,Baldes:2011mh,Dev:2015uca,Bowes:1996xy}. How do we experimentally test this scenario? The existence of $\Delta B=2$ baryon number violating processes can potentially be observed in neutron-antineutron oscillation measurements, as was considered in detail in Ref.~\cite{Babu:2013yca}. A key focus in this paper will be to probe the CP violating parameters of the model. A well established low energy technique to probe CP violation is via the electric dipole moments (EDMs) of atoms, molecules, nucleons and nuclei, as these can be non-zero only in the presence of CP violation (for recent reviews, see, {\it e.g} Refs.~\cite{Chupp:2017rkp,Engel:2013lsa}) . We shall calculate EDMs together with naturalness constraints on radiative quark mass contributions, which place bounds on CP odd and CP even products, respectively, of the new coupling parameters in our model. These constraints will dictate which of the new couplings can play a role in baryogenesis. A key difference between our work and that of Refs.~\cite{Babu:2006xc,Babu:2013yca,Babu:2008rq} is the inclusion of couplings to both left handed (LH) and right handed (RH) quarks, rather than RH quarks alone. This has two significant consequences. First, because EDMs require a chirality flip, they will be generated at one loop only when couplings to LH and RH quarks are both present. Second, the size of the baryon asymmetry will depend on whether the interactions involve LH quarks, RH quarks, or both. Like all out-of-equilibrum decay scenarios, baryogenesis requires the interference of a tree level decay amplitude with the absorptive part of a one-loop amplitude. In post-sphaleron bayoogenesis, those loop diagrams involve $W^\pm$ gauge bosons and hence the distinction between couplings to LH or RH quarks is important. Indeed, we shall see that baryogenesis must be dominated by the couplings of the new scalars to LH quarks. Our work is organized as follows: In Section~\ref{sec:model} we outline the model and the post-sphaleron baryogenesis mechanism. In Section~\ref{sec:edms} we compute constraints on the new coupling constants, using quark mass and nuclear EDM limits, while in Section~\ref{sec:baryogenesis} we determine the dependence of the CP asymmetries on those coupling parameters and hence discuss the implication of the constraints. We summarize our conclusions in Section~\ref{sec:conclusions}. \section{The Model} \label{sec:model} We introduce three new colored scalar diquarks $\Delta_{dd}$, $\Delta_{uu}$, and $\Delta_{ud}$, which carry baryon number and couple to quark bilinears. Their quantum numbers and allowed couplings are outlined in Table~\ref{tab:qnscalars}. In addition, we introduce a complex scalar field $\Phi$, which is a SM singlet, carries a baryon number of $B=2$, and has quartic interactions with the colored scalars of the form: \begin{equation} V\supset\frac{\lambda}{2}\Phi \Delta_{dd} \Delta_{ud}^2 +\frac{\lambda'}{2}\Phi\Delta_{uu}\Delta_{dd}^2\, . \end{equation} If the real part of $\Phi$, to which we will refer as $\Phi_r$, obtains a vacuum expectation value $\Delta B=2$ baryon number violating interactions are induced. Further details of the scalar potential have been discussed in \cite{Babu:2006xc,Babu:2013yca} and are relevant to the $N-\bar N$ oscillation calculations therein. The interactions of SM fermions with the new colored scalars are given by \begin{equation}\label{eq:fermL} \renewcommand1.8{1.5} \begin{array}{rl} \mathcal{L}_{\rm Yukawa}=&\frac{h_{\alpha\beta}}{2}\bar K\Delta_{dd}(\bar d_R)_{\alpha}(d_R)^c_{\beta} \\ &+\frac{f_{\alpha\beta}}{2}\bar K\Delta_{uu}(\bar u_R)_{\alpha}(u_R)^c_{\beta} \\ &+g_{\alpha\beta}\bar K\Delta_{ud}(\bar u_R)_{\alpha}(d_R)^c_{\beta} \\ &+g'_{\alpha\beta}\bar K\Delta_{ud}\epsilon_{ij}(\bar Q_i)_{\alpha}(Q_j)^c_{\beta} +h.c.\, , \end{array} \renewcommand1.8{0} \end{equation} where $u_R$ and $d_R$ are the usual RH quark fields of hypercharge $Y=2/3$ and $-1/3$ respectively, while $Q$ is the LH quark doublet of hypercharge $Y=1/6$. The $\bar K$ matrices are the generators for $SU(3)_c$ in the sextet representation. Further details of the sextet representation may be found in \cite{Han:2009ya}. We have used greek characters for flavor indices and the lower case latin characters $i,j$ for indices in the fundamental representation of $SU(2)_L$. We have and will continue to suppress color indices. They can be reinstated as follows: \begin{equation} \bar K^A_{ab}\Delta^A\psi_a\chi_b\, , \end{equation} where $A$ corresponds to a sextet color index, and $a,b$ correspond to indices in the fundamental representation. Notice that while $\Delta_{uu}$ and $\Delta_{dd}$ couple only to RH quarks, $\Delta_{ud}$ couples to both LH and RH quark bilinears. Although the $\Delta_{ud} QQ$ coupling was not considered in the analyses of \cite{Babu:2006xc,Babu:2013yca}, it cannot be forbidden without imposing additional symmetries\footnote{A UV completion based on a left-right symmetric model eliminates this coupling in \cite{Babu:2006xc,Babu:2013yca}.}. We find that the inclusion of this coupling to LH quarks has an important influence on both the EDM and baryogenesis phenomenology of the model. \begin{table}[t] \begin{tabular}{| r | ccc | c |} \hline Field&$SU(3)_C$&$SU(2)_L$&$U(1)_Y$& couplings \\ \hline $\Delta_{dd}$&6&1&-2/3&$d_Rd_R$ \\ $\Delta_{uu}$&6&1&4/3&$u_Ru_R$ \\ $\Delta_{ud}$&6&1&1/3&$u_Rd_R$ \\ $\Phi$&1&1&0& $\Delta_{dd} \Delta_{ud}^2$, $\Delta_{uu} \Delta_{dd}^2$ \\ \hline \end{tabular} \caption{The quantum number of the new scalars, together with their couplings to quark bilinears and the allowed quartic scalar interactions.} \label{tab:qnscalars} \end{table} \begin{figure*} \begin{tabular}{ccccc} \begin{fmffile}{baryotree} \begin{fmfgraph*}(100,100) \fmfsurroundn{v}{12} \fmf{dots,tension=8}{v7,o1} \fmf{dashes,tension=3}{o1,o2} \fmf{dashes,tension=3}{o1,o3} \fmf{dashes,tension=3}{o1,o4} \fmf{fermion}{o2,v4} \fmf{fermion}{o2,v3} \fmf{fermion}{o3,v11} \fmf{fermion}{o3,v10} \fmf{fermion,tension=2}{o4,v12} \fmf{fermion,tension=2}{o4,v2} \fmflabel{$\Phi_r$}{v7} \fmflabel{$u$}{v2} \fmflabel{$d$}{v12} \fmflabel{$u$}{v11} \fmflabel{$d$}{v3} \fmflabel{$d$}{v4} \fmfv{l.a=0,label=$d$}{v10} \fmfv{l.a=-160,label=$\Delta_{dd}$}{o2} \fmfv{l.a=150,label=$\Delta_{ud}$}{o3} \fmfv{l.a=155,label=$\Delta_{ud}$}{o4} \end{fmfgraph*} \end{fmffile} &\ \ \ \ \ \ \ \ & \begin{fmffile}{baryoSE} \begin{fmfgraph*}(100,100) \fmfsurroundn{v}{12} \fmf{dots,tension=8}{v7,o1} \fmf{dashes,tension=3}{o1,o2} \fmf{dashes,tension=3}{o1,o3} \fmf{dashes,tension=3}{o1,o4} \fmf{fermion}{o2,v4} \fmf{fermion}{o2,v3} \fmf{fermion}{o3,v11} \fmf{fermion}{o3,v10} \fmf{plain,tension=2.7}{o4,o4a,o4b} \fmf{fermion,tension=2.7}{o4b,v2} \fmf{plain,tension=2.7}{o4,o5,o6} \fmf{fermion,tension=2.7}{o6,v12} \fmf{photon,left,tension=0,label=$W^\pm$}{o5,o6} \end{fmfgraph*} \end{fmffile} &\ \ \ \ \ \ \ \ & \begin{fmffile}{baryovertex} \begin{fmfgraph*}(100,100) \fmfsurroundn{v}{12} \fmf{dots,tension=8}{v7,o1} \fmf{dashes,tension=3}{o1,o2} \fmf{dashes,tension=3}{o1,o3} \fmf{dashes,tension=3}{o1,o4} \fmf{fermion}{o2,v4} \fmf{fermion}{o2,v3} \fmf{fermion}{o3,v11} \fmf{fermion}{o3,v10} \fmf{fermion,tension=1.5}{o5,v2} \fmf{plain,tension=1.5}{o5,o4,o6} \fmf{fermion,tension=1.5}{o6,v12} \fmf{photon,tension=0,label=$W^\pm$}{o5,o6} \end{fmfgraph*} \end{fmffile} \\ (a)&&(b)&&(c) \end{tabular} \caption{Diagrams contributing to the $\Delta B=2$ decay of the real part of the scalar field $\Phi$ into six quarks. The dotted line corresponds to $\Phi_r$, the dashed lines to the new scalars $\Delta_{dd}$, $\Delta_{uu}$, and/or $\Delta_{ud}$, the solid lines are the final state quarks, and the one loop diagrams contain an intermediate $W$ boson. Diagram (a) corresponds to the tree level decay, (b) to the one loop self energy correction and (c) to the vertex correction diagram. Baryogenesis occurs via the interference of the tree diagram with the absorptive part of the loop diagrams. This requires that the $W$ in the loop is put on shell and hence a final state $t$-quark is necessary. If $\Phi_r$ is replaced with its vacuum expectation value (a) also corresponds to the diagram allowing $n-\bar n$ oscillations at tree level.}\label{fig:baryogenesisdiagrams} \end{figure*} Baryogenesis proceeds via the decay of the real part of the $\Phi$ field to six quarks or six anti-quarks, thereby violating baryon number by two units. The Feynman diagram for the tree level decay is shown in Figure~\ref{fig:baryogenesisdiagrams} (a). In order to obtain a nonzero baryon asymmetry we require the interference of the tree level decay amplitude with the absorptive part of the one loop decay amplitudes shown in Figure~\ref{fig:baryogenesisdiagrams} (b) and (c). The first corresponds to corrections to the quark wave function via a $W$ exchange while the second corresponds to the vertex correction of the $\Delta_{ud}$ couplings $g$ or $g'$. To obtain the absorptive part required for baryogenesis, we require the $W$ in the loop to be on shell; it is thus necessary to have a final state $t$-quark. We also note that of the three sextet scalars only two are required for successful baryogenesis: either $(\Delta_{dd},\Delta_{uu})$ or $(\Delta_{dd},\Delta_{ud})$ are sufficient, the latter being the focus of the studies \cite{Babu:2006xc,Babu:2013yca,Babu:2008rq}. As we are interested in the implications of including the left handed couplings of the $\Delta_{ud}$ boson we will also focus on the $(\Delta_{dd},\Delta_{ud})$ model throughout this paper. If the dotted line in Figure~\ref{fig:baryogenesisdiagrams}(a) is replaced with the vacuum expectation value of $\Phi_r$, the resulting diagram describes a mechanism for neutron-antineutron oscillations. This both puts constraints on the relevant couplings of the model as well as motivating future studies of neutron oscillations~\cite{Babu:2013yca}. As we shall be interested in low energy observables and in baryogenesis that takes place below the electroweak scale, we choose to work in the quark mass basis. Rotating to the mass basis results in a redefinition of the couplings of Eq.~\ref{eq:fermL}, as detailed in Appendix~\ref{app:flavormass}. The resulting Lagrangian coupling up and down type quarks to $\Delta_{ud}$ is: \begin{equation} \mathcal{L}= \bar K\Delta_{ud}(\bar u'_R)G(d'_R)^c+2\bar K\Delta_{ud}(\bar u'_L)G'(d'_L)^c+\, h.c.\, . \end{equation} Capital $G$ and $G'$ are the mass basis analogues of the couplings in Eq.~\ref{eq:fermL}, and the generation indices have been suppressed for simplicity. Although we perform our calculations in the mass basis, we will still reference the properties of the couplings in the flavor basis to derive certain results in Section~\ref{sec:baryogenesis} as the flavor structure is crucial in identifying the leading contributions to the baryon asymmetry. We are now in a position to calculate constraints on the $G$ and $G'$ matrices and the implications of those constraints on the parameter space for successful baryogenesis. \section{Quark mass and EDM constraints} \label{sec:edms} As mentioned above, the introduction of the new LH coupling of the $\Delta_{ud}$ has the potential make significant new contributions to the baryon asymmetry. An important question to address, however, is whether the coexistence of LH and RH couplings will imply new low energy constraints which might render the new contributions to the baryon asymmetry negligibly small. Of particular concern are operators that break chiral symmetry: the Standard Model Yukawa interactions and dipole operators. Both will in general receive new radiative contributions with the simultaneous presence of both LH and RH $\Delta_{ud}$ couplings. In the case of Yukawa interactions, \lq\lq naturalness" considerations imply that radiative corrections to the Yukawa couplings should not be considerably larger in magnitude than their tree-level values. With regard to dipole operators, experimental limits on the EDMs of the neutron and $^{199}$Hg atom imply severe restrictions on the relative phases of the $G$ and $G'$ couplings. In what follows, we analyze both considerations in detail. In doing so, we will work with quantities and the degrees of freedom associated with the Standard Model after electroweak symmetry-breaking: quark masses and quark (chromo-)electric dipole moments\footnote{The resulting constraints are equivalent to those that one would obtain by first considering the SM in its electroweak symmetric phase and then applying the results to the broken phase quantities. }. \subsection{Radiative Quark Masses and Naturalness} The couplings of the quarks to the scalar $\Delta_{ud}$ give rise to radiative quark mass contributions, as shown in Fig.~\ref{fig:radmassdiagram}. We shall impose a naturalness constraint on the size of these mass contributions, by requiring that the radiatively generated contribution be much smaller in magnitude than the physical quark mass. Calculating the one loop generated up quark mass at the quark mass scale after running down from the new physics (NP) scale and requiring it be smaller than the tree level quark mass gives the constraint: \begin{equation} \delta m_j^u = \frac{4 N_c m_i^d}{8\pi^2} | G_{ij}^*G_{ij}'| \log\frac{m_j^u}{M_{\Delta_{ud}}^2}\ll m_j^u\, . \end{equation} The constraint for the down quark mass comes from replacing the labels $u\leftrightarrow d$ and changing the order of the indices of $G$ and $G'$. Note there is an implied sum over flavors $i$, but not $j$. We assume that phases in the quark mass matrix, equivalent to a QCD theta term, are removed by assumption of a Pecci-Quinn symmetry. Our constraints thus apply to the magnitude of the radiative mass contributions. \begin{figure} \begin{tabular}{cc} \begin{fmffile}{radmass} \begin{fmfgraph*}(175,60) \fmfsurroundn{v}{8} \fmf{plain,tension=1,label=$q_R$}{v6,o1} \fmf{plain,tension=1}{o2,o3,o1} \fmf{plain,tension=1,label=$q_L$}{o2,v8} \fmf{dashes,left=1,tension=0,label=$\Delta_{ud}$}{o1,o2} \fmfv{label=$(q'_R)^c$,l.a=-28}{o1} \fmfv{label=$(q'_L)^c$,l.a=-152}{o2} \fmfv{decor.shape=cross,decor.size=7,decoration.angle=0}{o3} \end{fmfgraph*} \end{fmffile} \end{tabular} \caption{One-loop diagrams contributing to the radiatively generated quark mass. The intermediate quark mass insertion is marked by $\boldsymbol{\times}$ and the dominant contributions come from heavy quarks in the loop. Only $\Delta_{ud}$, which couples to both LH and RH quarks, can give rise to such mass contributions; there are no analogous diagrams containing $\Delta_{uu}$ or $\Delta_{dd}$.} \label{fig:radmassdiagram} \end{figure} The strongest constraints are associated with intermediate heavy quarks ($i=3$), leading to \begin{equation} \arraycolsep=1.4pt\def1.8{1.5} \begin{array}{rcl} | G_{13}^*G_{13}' | &<&10^{-5} \,, \\ | G_{31}^*G_{31}' | &<&10^{-4} \,. \label{eq:massconstraints} \end{array} \end{equation} Next we consider the EDM constraints which, in contrast with the mass, are sensitive to the imaginary part of the same products of $G^*$ and $G'$ elements. \subsection{Electric Dipole Moments Framework} \label{sec:edmframework} In studying the constraints from EDM measurements we will closely follow the notation of \cite{Engel:2013lsa}. We quantify the NP contributions to the EDMs in terms of dimension six operators by defining the effective Lagrangian\footnote{Note that we do not explicitly include the dimension-five lepton-number violating operator.}, \begin{equation}\label{eq:efflagrangian} \mathcal{L}_{\rm eff}=\sum_i \frac{c_i}{\Lambda^2}Q_i +\mathcal{O} \left( \Lambda^{-3} \right) , \end{equation} where the operators $Q_i$ are constructed from SM fields, and $c_i$ are their Wilson coefficients. The operators admitting CP violation at dimension--six include 10 operators coupling fermions to bosons as well as five four-fermion operators which are enumerated in Tables 2 and 3 of \cite{Engel:2013lsa}. Here we list only those relevant to our analysis, \begin{eqnarray} Q_{qG}&=&(\bar Q\sigma^{\mu\nu}T^Aq_R)\ptwiddle{H}G^A_{\mu\nu}\, , \label{eq:CPviolatingd6_1} \\ Q_{qW}&=&(\bar Q\sigma^{\mu\nu}q_R)\tau^i\ptwiddle{H}W_{\mu\nu}^i\, , \label{eq:CPviolatingd6_2} \\ Q_{qB}&=&(\bar Q\sigma^{\mu\nu}q_R)\ptwiddle{H}B_{\mu\nu}\, , \label{eq:CPviolatingd6_3} \\ Q_{quqd}^{(1)}&=&(\bar Q^iu_R)\epsilon_{ij}(\bar Q^jd_R)\, , \label{eq:CPviolatingd6_4} \\ Q_{quqd}^{(8)}&=&(\bar Q^iT^Au_R)\epsilon_{ij}(\bar Q^jT^Ad_R)\, . \label{eq:CPviolatingd6_5} \end{eqnarray} where $G^{A\mu\nu}$ the gluon field strength tensor with adjoint color index $A$, $W^{i\mu\nu}$ is the $SU(2)$ field strength tensor with adjoint $SU(2)_L$ index $i$, and $B^{\mu\nu}$ is the hypercharge field strength tensor. We denote the SM Higgs doublet as $H$, and define $\tilde H=i\sigma_2H$ where $\sigma_2$ the second Pauli matrix. Here, $q_R$ represents either $u_R$ or $d_R$ and is associated with the ${\tilde H}$ or $H$, respectively. After electroweak symmetry breaking, wherein \begin{equation} H^T \rightarrow \left(0,\ v/\sqrt{2}\right)\ \ \ , \end{equation} the operators in Eqs. \ref{eq:CPviolatingd6_2} and \ref{eq:CPviolatingd6_3} generate the dipole couplings to the photon, $Z$, and $W$ bosons. For example, one obtains the effective EDM interaction \begin{equation}\label{eq:cgamop} \mathcal{L}_{q\gamma}^\mathrm{EDM}=i\frac{\sqrt{2}v}{2}\frac{\mathrm{Im}[c_{q\gamma}]}{\Lambda^2}\bar q_L\sigma^{\mu\nu} \gamma_5 q F_{\mu\nu}\, , \end{equation} where $F_{\mu\nu}$ is the field strength tensor of the photon field and we have chosen the normalization of the operator coefficient to coincide with that of \cite{Engel:2013lsa}: \begin{equation} \mathrm{Im}[c_{q\gamma}] = \mathrm{Im} [c_{qB}] + I_3^q\, \mathrm{Im} [c_{qW}] \label{eq:imcqgamma} \end{equation} with $I_3^q$ being the third component of weak isospin for quark $q$. Note that in the notation of Ref.~\cite{Engel:2013lsa} the coefficients $c_{qB}$ and $c_{qW}$ enter the effective Lagrangian with explicit factors of the U(1)$_Y$ and SU(2)$_L$ gauge couplings, respectively, so that the relation in Eq.~\ref{eq:imcqgamma} carries no explicit dependence on the weak mixing angle. After integrating out the heavy $\Delta_{ud}$ scalar, we find that the four fermion operators $Q_{quqd}^{(1)}$ and $Q_{quqd}^{(8)}$ are generated at tree-level, while the dipole operators $Q_{fW}$ and $Q_{fB}$ and the chromo-dipole operators $Q_{uG}$ and $Q_{dG}$ arise at one-loop. The four-quark and (chromo-)EDM operators, in turn, contribute to the EDM of the neutron, while only the four-quark and chromo-EDM operators generate potentially significant contributions to the $^{199}$Hg atomic EDM via the nuclear Schiff moment as outlined in \cite{Engel:2013lsa}. In the next two subsections, we first derive the relevant operator Wilson coefficients. We then outline the procedure for deriving the implications for the neutron and $^{199}$Hg EDMs and finally apply EDM constraints to the relevant combinations of the $G$ and $G'$ couplings. \begin{figure} \begin{tabular}{c} \begin{fmffile}{zradiates} \hspace*{-.5cm}\begin{fmfgraph*}(120,60) \fmfsurroundn{v}{8} \fmf{fermion,tension=4}{v6,o1} \fmf{dashes,tension=1,right=1}{o2,o1} \fmf{fermion,tension=4}{o2,v8} \fmf{fermion,tension=1.0}{o2,o1} \fmf{phantom,tension=5.0}{v7,o3} \fmf{phantom,tension=3.0}{o3,v3} \fmf{photon,tension=2.0}{o3,v2} \end{fmfgraph*} \end{fmffile} \hspace*{-.5cm}\begin{fmffile}{qradiates} \begin{fmfgraph*}(120,60) \fmfsurroundn{v}{8} \fmf{fermion,tension=4}{v6,o1} \fmf{fermion,tension=1,right=1}{o2,o1} \fmf{fermion,tension=4}{o2,v8} \fmf{dashes,tension=1.0}{o1,o2} \fmf{phantom,tension=5.0}{v7,o3} \fmf{phantom,tension=3.0}{o3,v3} \fmf{photon,tension=2.0}{o3,v2} \end{fmfgraph*} \end{fmffile} \end{tabular} \caption{One-loop diagrams contributing to the up- and down-quark EDMs. The dashed lines represent the new scalar $\Delta_{ud}$, the external solid lines represent either the up- or down-quark, while the intermediate solid line is summed over all active flavors of quarks. Left: the new heavy scalar $\Delta_{ud}$ radiates a photon or gluon, Right: the intermediate quark radiates a photon or gluon. }\label{fig:edmdiagrams} \end{figure} \subsection{EDM and chromo-EDM operators at the partonic scale}\label{subsec:treelevelops} In principle, since both the four-quark and (chromo-) EDM operators arise in our scenario, one must consider contributions from both to the EDMs of diamagnetic systems. In practice, consideration of the four-quark contribution is not presently tractable, due to particularities of the model considered here. In general, the operators $Q_{quqd}^{(1,8)}$ containing only first generation quarks admit an SU(2)$_L\times$SU(2)$_R$ chiral symmetry. Based on this feature, one is able to obtain order-of-magnitude estimates of the hadronic matrix elements relevant to EDMs using na\"ive dimensional analysis (NDA), even in the absence of explicit lattice QCD or model computations. As discussed in Appendix B, however, in the basis of weak interaction (flavor) eigenstates, the Wilson coefficients of $Q_{quqd}^{(1,8)}$ vanish for first generation quarks. This result follows from the antisymmetry of the $g'$ couplings with respect to flavor indices. Non-vanishing contributions arise when the flavor of the two RH quarks differs. After rotating to the quark mass basis, one obtains effective four-quark operators involving all first generation quarks as well as those involving other quark flavors. However, operators containing only first generation quarks no longer reflect the SU(2)$_L\times$SU(2)$_R$ chiral symmetry associated with $Q_{quqd}^{(1,8)}$ in the flavor basis, since the operators in the flavor basis also do not reflect this symmetry in our model. Consequently, we are not presently able to estimate the hadronic matrix elements using NDA and considerations of chiral symmetry, as was done in Ref.~\cite{Engel:2013lsa}. Instead, we focus on the loop-induced (chromo-)EDM contributions, using them to obtain conservative upper bounds on the relevant combinations of the mass basis $G$ and $G'$ couplings. Any significant additional contributions from the four quark CPV operators would only strengthen the bounds quoted below in the absence of finely-tuned cancellations among the various conributions. The quark (chromo-)EDMs and chromo EDMs receive one-loop contributions from the diagrams shown in Fig.~\ref{fig:edmdiagrams} (We note that similar derivation for the $d$-quark EDM alone can be found in \cite{Arnold:2012sd}). We generate the Feynman rules for our model with the FeynRules mathematica package~\cite{Alloul:2013bka}, calculate the amplitudes in FeynArts~\cite{Hahn:2000kx} and Formcalc~\cite{Hahn:1998yk}, and finally obtain analytic forms for the amplitudes along with their leading order terms in the momentum expansion using Package-X~\cite{Patel:2016fam}. We obtain \begin{eqnarray} {\rm Im}[c_{u\gamma}]&=&-\frac{m_\alpha}{12\pi^2\sqrt{2}v}{\rm Im}[G_{\alpha1}'G_{\alpha1}^*]\left[4+2\ln\left(\frac{m_\alpha^2}{M_{\Delta_{ud}}^2}\right)\right]\, ,\nonumber\\ \label{eq:edm1}\\ {\rm Im}[c_{d\gamma}]&=&\frac{m_\alpha}{6\pi^2\sqrt{2}v}{\rm Im}[G_{1\alpha}'G_{1\alpha}^*]\left[\frac{5}{2}+2\ln\left(\frac{m_\alpha^2}{M_{\Delta_{ud}}^2}\right)\right]\, ,\nonumber\\ \label{eq:edm2} \end{eqnarray} where $\alpha$ corresponds to a down-type quark in Eq.~\ref{eq:edm1} and an up-type quark in Eq~\ref{eq:edm2}. We note that for $\alpha=3$ these operators have a strong enhancement from the top and bottom quark masses. We will discuss this feature in more detail below. The computation of the chromo-EDM is similar, replacing the external photon with a gluon. We find the only difference between the up- and down-quark chromo-EDMs arises from the difference in mass for each generation and from the couplings $G$ and $G'$. Using a similar normalization as in Eq.~\ref{eq:efflagrangian} we obtain \begin{eqnarray}\label{eq:ccedm} {\rm Im}[c_{uG}]&=&\frac{m_\alpha}{8\pi^2\sqrt{2} v}{\rm Im}[G_{\alpha1}'G_{\alpha1}^*]\ln\left(\frac{m_\alpha^2}{M_{\Delta_{ud}}^2}\right)\, ,\label{eq:cedm1}\\ \nonumber\\ {\rm Im}[c_{dG}]&=&\frac{m_\alpha}{8\pi^2\sqrt{2} v}{\rm Im}[G_{1\alpha}'G_{1\alpha}^*]\ln\left(\frac{m_\alpha^2}{M_{\Delta_{ud}}^2}\right)\, ,\label{eq:cedm2} \end{eqnarray} In our analysis below we will make the simplifying assumption that all elements of $G$ and $G'$ are of the same order. Under this assumption we see that the largest contribution to the up and down quark (chromo) EDMs come from the diagrams with bottom and top quarks in the loops, respectively, due to the dependence on the $m_\alpha$. As a result, we expect the limits arising from the $d$-quark EDM to be stronger that those for the $u$-quark EDM by a factor of about ${\rm Im}[c_{dG}]/{\rm Im}[c_{uG}]\sim m_t/m_b\sim40$. This ratio will be observed in the bounds arising from neutron and $^{199}$Hg EDM constraints. \subsection{EDMs of the neutron and $^{199}$Hg} \label{sec:analysis} We now calculate the new contributions to the neutron and $^{199}$Hg EDMs using the operator coefficients determined above. In order to do so we must evolve the coefficients from the heavy scale specified by $M_{\Delta_{ud}}$ to the hadronic scale, which we take to be one GeV. We obtain the operator coefficients at this scale using the renormalization group analysis of \cite{Dekens:2013zca}, wherein one first evolves down to EW scale integrating out the $t$-quark along the way. Matching is performed while integrating out electroweak gauge bosons and they evolve down to the hadronic scale integrating out the $b$ and $c$ quarks along the way. We calculate the neutron EDM, $d_n$, following the procedure of \cite{Engel:2013lsa}: \begin{equation}\label{eq:dn} d_n=\sum_{q=u,d}\frac{v^2}{M_{\Delta_{ud}}^2}\left(\beta_{n}^{q\gamma}\, {\rm Im}[c_{q\gamma}]+\beta_{n}^{qG}\, {\rm Im}[c_{uG}]\right) \, \end{equation} where the ${\rm Im}[c_{q\gamma}]$ are evaluated at the scale $\mu = 1$ GeV and where the hadronic matrix elements are encoded in the $\beta_i^j$. We reproduce their values in Table~\ref{tab:betasgammas} for convenience. Note that the values of the $\beta_n^{q\gamma}$ have been updated to reflect the recent lattice QCD computations of Refs.~\cite{Bhattacharya:2015esa,Bhattacharya:2015wna}. Table~\ref{tab:betasgammas} also gives ranges for the $\beta_i^j$ {\it etc.} to illustrate their degree of uncertainty, however we will use only the central values in our analysis. As pointed out in \cite{Bhattacharya:2015esa,Bhattacharya:2015wna}, one may also anticipate non-negligible contributions from the strange quark EDM, though the magnitude of this contribution is rather uncertain. We have not included this uncertainty in Table~\ref{tab:betasgammas}. To calculate the EDM of $^{199}$Hg, we begin with the isoscalar and isovector coefficients of the $T$- and $P$-violating pion-nucleon Lagrangian, $\bar g_\pi^{(0)}$ and $\bar g_\pi^{(1)}$ respectively, expressed in terms of our effective operator coefficients: \begin{equation} \bar g_\pi^{(i)}=\frac{v^2}{M_{\Delta_{ud}}^2}\gamma_{(i)}^{\pm G}\left({\rm Im}[c_{uG}]\pm{\rm Im}[c_{dG}]\right) \, \end{equation} where the $\gamma_i$ are given in Table~\ref{tab:betasgammas}. The isotensor contribution, $\bar g_\pi^{(2)}$, is a subleading effect and is neglected in our analysis. The dipole moment of $^{199}$Hg is then given by \begin{equation} d_A=\rho_pd_p+\rho_nd_n+ \frac{2m_N g_A \kappa_S}{F_\pi}(a_0\bar g_\pi^{(0)}+a_1\bar g_\pi^{(1)})\, , \end{equation} where $d_p$, the proton EDM, is calculated using Eq.~\ref{eq:dn} with $(\beta^{u\gamma}_n\leftrightarrow\beta^{d\gamma}_n)$ and $(\beta^{uG}_n\leftrightarrow\beta^{dG}_n)$, i.e., by invoking isospin invariance. The last term in the expression above is the contribution from the nuclear Schiff moment. Values assumed for the the nucleon mass $m_N$, the leading order strong interaction coupling $-2g_A/F_\pi$, pion decay constant $F_\pi$, and the coefficients $a_i$ can be found in Table~\ref{tab:parameters}. \begin{table} \begin{tabular}{l | c | c} Coefficient&Best Value $[{\rm e\ fm}]$&Range $[{\rm e\ fm}]$\\ \hline \hline $\beta_n^{uG}$&$4\cdot 10^{-4}$&$(1,10)\cdot10^{-4}$\\ $\beta_n^{dG}$&$8\cdot 10^{-4}$&$(2,18)\cdot10^{-4}$\\ \hline $\beta_n^{u\gamma}$&$1.3\cdot10^{-3}$&$(1.1,1.5)\cdot10^{-3}$\\ $\beta_n^{d\gamma}$&$-4.4\cdot10^{-3}$&$-(4.1,4.7)\cdot10^{-3}$\\ \hline $\beta_n^{quqd}$&$40\cdot10^{-7}$&$(10,80)\cdot10^{-7}$\\ \hline $\gamma^{+G}_{(0)}$&$-0.01$&$(-0.03,0.03)$\\ $\gamma^{-G}_{(1)}$&$-0.02$&$-(0.07,0.01)$\\ $\gamma^{quqd}_{(1)}$&$2\cdot10^{-6}$&$(1,10)\cdot10^{-6}$\\ \end{tabular} \caption{Best values and ranges for the coefficients relevant to the neutron and $^{199}$Hg EDM calculations, all values were taken from~\cite{Engel:2013lsa} except the updated values for $\beta_n^{q\gamma}$ were taken from \cite{Bhattacharya:2015esa,Bhattacharya:2015wna}.}\label{tab:betasgammas} \end{table} \begin{table} \begin{tabular}{r | c | c} Parameter&Value&Range\\ \hline \hline $m_N$&938 MeV&--\\ $g_A$&1.33&--\\ $F_\pi$&185 MeV&--\\ $a_0$&0.01&(0.005,0.05)\\ $a_1$&$\pm$0.02&(-0.03,0.09)\\ $a_2$&0.02&(0.01,0.06)\\ $\rho_p$&$-0.56\cdot10^{-4}$&--\\ $\rho_n$&$-5.3\cdot10^{-4}$&--\\ $\kappa_S$&$-2.8\cdot10^{-4}\ {\rm fm}^{-2}$&-- \end{tabular} \caption{Parameters values used in the EDM analysis, taken from Tables 4 and 13 of \cite{Engel:2013lsa}. Note that the entry for $\kappa_S$ corrects the overall sign of this quantity from what is given in Ref.~\cite{Engel:2013lsa}.}\label{tab:parameters} \end{table} The current 95$\%$ confidence limits on the EDMs of the neutron \cite{Afach:2015sja} and $^{199}$Hg \cite{Graner:2016ses} are \begin{eqnarray} \vert d_{\rm n} \vert &\le&3.6\times 10^{-13}\ {\rm e\ fm}\, ,\\ \vert d_{\rm Hg} \vert&\le&7.4\times 10^{-17}\ {\rm e\ fm}\, . \end{eqnarray} By demanding that the new physics contributions to these parameter are smaller than the experimental bounds, we will set limits on the $G$ and $G'$ coupling constants. In order to do so, however, we will need to make some simplifying assumptions about the structure of the coupling matrices\footnote{The matrix $G$ has 9 complex parameters, in general, while and $G'$ has the three complex parameters arising from $g'$ plus the four CKM parameters (see the definition of $G'$ in Appendix~\ref{app:flavormass} ). To individually constrain all elements of these matrices would require a significant phenomenological effort, well beyond the scope of this paper. We will therefore make convenient simplifying assumptions about the structure of the matrices. More complex flavor structures are possible, such as those considered in \cite{Babu:2006xc,Babu:2013yca}.}. We shall assume that all elements of $G$ are of the same order of magnitude, and make a similar assumption about the elements of $G'$. Note, however, that we permit the overall scales of $G$ and $G'$ to differ significantly. Given this assumption and that ${\rm Im}[c_{q\gamma,g}]$ are all proportional to $m_\alpha$ (see Eqs.~\ref{eq:edm1} through \ref{eq:cedm2}) we see that the terms enhanced by the heavy quark masses will dominate the limits. Therefore, the EDM constraint directly probe the coupling combinations ${\rm Im}[G_{13}'G_{13}^*]$ and ${\rm Im}[G_{31}'G_{13}^*]$. \begin{figure} \begin{tikzpicture}\begin{axis}[ minor x tick num = 3, minor y tick num = 4, ymin = -12,ymax = 12, xmin = -.5,xmax = .5, xlabel={${\rm Im}[G'_{13}G^*_{13}]$}, xtick = {-.4,-.2,0,.2,.4}, xticklabels = {$-4\cdot10^{-7}$,$-2\cdot10^{-7}$,$0$,$2\cdot10^{-7}$,$-4\cdot10^{-7}$}, ylabel={${\rm Im}[G'_{31}G^*_{31}]$}, ytick = {-10,-5,0,5,10}, yticklabels = {$-10^{-5}$,$-5\cdot10^{-6}$,$0$,$5\cdot10^{-6}$,$10^{-5}$} ] \addplot [blue,domain=-5:5,samples=201,name path=aedmtop]{(2.05 - 23.8*x)}; \addplot [blue,domain=-5:5,samples=201,name path=aedmbottom]{(-2.05 - 23.8*x)}; \addplot [red,domain=-5:5,samples=201,name path=nedmtop]{(20.5 + 35.7*x)}; \addplot [red,domain=-5:5,samples=201,name path=nedmbottom]{(-20.5 + 35.7*x)}; \addplot[red, fill opacity=0.2] fill between [of=nedmtop and nedmbottom,soft clip={domain=-1:1},]; \addplot[blue, fill opacity=0.2] fill between [of=aedmtop and aedmbottom,soft clip={domain=-1:1},]; \end{axis}\end{tikzpicture} \caption{The blue region is allowed by the $^{199}$Hg EDM constraints, while the red region is allowed by the neutron EDM constraints. The region allowed by both constraints is shown as purple. We have taken $M_{\Delta_{ud}}=1$ TeV, for larger values of $M_{\Delta_{ud}}$ the results scale roughly as $[{\rm TeV}]^2/M_{\Delta_{ud}}^2$. }\label{fig:3rdgenonly} \end{figure} Figure~\ref{fig:3rdgenonly} shows the region in the ${\rm Im}[G_{13}'G_{13}^*]$ vs ${\rm Im}[G_{31}'G_{31}^*]$ plane in which the 95\% confidence level limits of $d_N$ and $d_{\rm Hg}$ are not exceeded. We neglect to perform a more formal likelihood analysis here as we expect our discussion of the baryon asymmetry in Section~\ref{sec:baryogenesis} only to be an order of magnitude estimate. Parameters which pass the neutron EDM constraint are shown in red, while those which pass the $^{199}$Hg constraint are shown in blue. The allowed parameter space is hence given roughly by the region where these bands intersect. We have taken a benchmark value for $M_{\Delta_{ud}}$ of 1 TeV. For larger values of $M_{\Delta_{ud}}$ the results scale approximately as $[{\rm TeV}]^2/M_{\Delta_{ud}}^2$; this naive scaling rule is broken only by the logarithms in the one loop Wilson coefficients of Eqs~\ref{eq:edm1}--\ref{eq:cedm2} and by the running of the effective couplings from the $M_{\Delta_{ud}}$ scale to $M_{\rm QCD}=1$ GeV. We find that \begin{eqnarray} |{\rm Im}[G_{13}'G_{13}^*]| & < & 4 \times 10^{-7}\,, \nonumber \\ |{\rm Im}[G_{31}'G_{31}^*]| & < & 1 \times 10^{-5} \,. \label{eq:EDMconstraints} \end{eqnarray} As mentioned above, the difference in the constraints simply reflects the ratio $m_t/m_b\sim40$. For $G_{ij}\sim G'_{ij}$, these bounds correspond to $G$ and $G'$ elements of order $10^{-3}$. The constraints coming from the EDMs and those from the radiative quark masses are complementary as they constrain the imaginary part and magnitude, respectively, of $(G^\dagger m_{u,d}G')_{ii}$. From the results presented in Eqs. \ref{eq:massconstraints} and \ref{eq:EDMconstraints}, we conclude that the imaginary parts of these quantities are small, while the real parts can be an order of magnitude or more larger. When we come to the baryogenesis analysis, however, we will simply assume that both the real and imaginary components (and hence the magnitudes) of the $GG'$ quantities satisfy the more stringent of these bounds (Eq.\ref{eq:EDMconstraints}), while the phase is unconstrained, as this will lead to the maximum baryon asymmetry\footnote{The CP-violating asymmetry in $\Phi$ decays is proportional to the imaginary part of a product of couplings, divided by a real part (arising from the tree level decay rate).}. In the next section we will use these constraints to analyze three main benchmark scenarios for baryon asymmetry generation. These benchmarks are specified by $\Delta_{ud}$ couplings to only RH quarks, only to LH quarks, or to both, namely: \begin{equation}\label{eq:benchmarks} \renewcommand1.8{1.5} \begin{array}{lcl} G\sim 1&{\rm and}& G'\sim0\, ,\\ G\sim0&{\rm and}& G'\sim1\, ,\\ G\sim 10^{-3}&{\rm and}&G'\sim10^{-3}\, . \end{array} \renewcommand1.8{0} \end{equation} The last benchmark corresponds to $GG'\sim10^{-6}$, which is commensurate with the EDM bounds derived above and easily satisfies the radiative mass bounds. \section{Baryogenesis} \label{sec:baryogenesis} \subsection{CP asymmetry of the $\Phi$ decays} \vspace{-1mm} The baryon asymmetry is generated at temperatures below the EW phase transition via the out-of-equilibrium decays of $\Phi_r\rightarrow 6q$ and $\Phi_r \rightarrow 6 \overline{q}$, shown in Figure~\ref{fig:baryogenesisdiagrams}. The requisite CP violation is provided by the complex $G$ and $G'$ coupling constants, and through the interference of the tree level decay amplitude with the absorptive part of the 1-loop amplitudes. A key requirement is the presence of $W$ gauge bosons in the loop graphs because, as we shall see below, the non-diagonal flavor structure of the CKM matrix is necessary to generate a non-zero asymmetry. For this reason, there is no analogous $Z$ boson contribution. As mentioned above, our model differs from that examined in Refs.~\cite{Babu:2006xc,Babu:2013yca,Babu:2008rq} by the addition of the $G'$ couplings of $\Delta_{ud}$ to LH quarks. We expect this to allow to larger baryon asymmetries to be generated, because the loop diagrams that permit baryogenesis all involve $W$ bosons. Specifically, if the scalar $\Phi_r$ decays to only RH quarks, then chiral flips are required to permit couplings of the quarks to the $W$, and hence we expect the rates to be suppressed by factors of quark mass. However, if $\Phi_r$ couples to LH quarks, no chiral flip is needed. We therefore expect the baryon asymmetry generated via processes involving RH quarks to be suppressed by factors of $m_{\rm light quark}/M_\Phi$ with respect to the asymmetry generated by processes involving LH quarks. A full calculation of the baryon asymmetry is beyond the scope of this work. Such a calculation would involve an evaluation of the Boltzmann equations required to track the evolution of the asymmetry, accounting for the $\Phi_r$ decays together with any relevant dilution or washout effects. We defer such a calculation, together with a detailed exploration of the parameter space, to a future publication. Instead, as in Refs.~\cite{Babu:2006xc,Babu:2013yca,Babu:2008rq}, we determine the CP asymmetry of the decay rates, defined as \begin{equation} \epsilon = \frac{\Gamma({\Phi}\to6q)-\Gamma({\Phi}\to6\bar q) }{ \Gamma({\Phi}\to6q)+\Gamma({\Phi}\to6\bar q)}\ \ \ . \end{equation} The CP asymmetry represents an upper bound on the net baryon asymmetry. In practice, the final baryon asymmetry will be reduced somewhat by dilution or washout effects. The total $\Phi_r$ decay rate at tree level is given by: \begin{equation}\label{eq:treerateggp} \arraycolsep=1.4pt\def1.8{1.8} \begin{array}{rcl} \Gamma_{\rm tree}^\mathrm{TOT}&\equiv&\Gamma({\Phi}\to6q)+\Gamma({\Phi}\to6\bar q)\Big\vert_\mathrm{tree}\\ &=&\frac{1}{\pi^9\cdot 2^{25}\cdot45}12|\lambda|^2{\rm Tr}[H^\dagger H]\frac{M_{\Phi}^{13}}{M_{\Delta_{ud}}^8M_{\Delta_{dd}}^4}\boldsymbol{X}^2\, ,\\ \phantom{hi} \end{array} \end{equation} where the phase space factor $1/(45\cdot2^{25}\pi^9)$ has been factored out of the six body phase space \cite{Bashir:2001ad}, and the factor 12 is a color factor. We have defined the quantity $\boldsymbol{X}$, which contains the dependence on the $G$ and $G'$ couplings constants, as \begin{eqnarray} \boldsymbol{X}&\equiv&{\rm Tr}[G^\dagger G+(G')^\dagger G']P_1 \ \nonumber \\ && -{\rm Tr}[(G')^\dagger \boldsymbol{m}_u G\boldsymbol{m}_d+G^\dagger \boldsymbol{m}_u G'\boldsymbol{m}_d]\frac{P_0}{M_{\Phi}^2}\, . \end{eqnarray} Here and below $\boldsymbol{m}_{u,d}$ are the $3\times3$ diagonal up/down quark mass matrices. The quantities $P_1$ and $P_0$ arise from the six body phase space integral. Terms weighted by $P_1$($P_0$) are proportional to phase space integrals of $p_i\cdot p_j$ ($m_i m_j$). Following \cite{Babu:2013yca} we simplify the momentum dependent integral by assuming the momentum is averaged over the six final state quarks yielding $p_i\cdot p_j\sim M_\Phi^2/6$ and $P_0\sim P_1/6$. We use $P_1 \sim 10^{-4}$, obtained by numerical integration of the 6-body phase space. There are two dominant contributions to the baryon asymmetry. The first from interference of the tree level decay amplitude with the $t$-quark self energy diagram of Figure~\ref{fig:baryogenesisdiagrams}b, and the second from the interference with the vertex correction of Figure~\ref{fig:baryogenesisdiagrams}c. In both cases a final state $t$-quark is required so that the $W$ boson can be put on shell, which is necessary for obtaining an absorptive part. Evaluating the wavefunction and vertex contributions to the asymmetries, we find \begin{widetext} \begin{eqnarray} \epsilon_{\rm wave}&\sim& \frac{3g_w^2}{32\pi \boldsymbol{X}M_W^2m_t^2}{\rm Im}\Big([V\boldsymbol{m}_d^2V^\dagger \boldsymbol{m}_u G G^\dagger \boldsymbol{m}_u]_{33}P_1+m_t^2[V\boldsymbol{m}_d^2V^\dagger G' G'^\dagger]_{33}P_1 \nonumber\\ && \phantom{\frac{3g^2}{32\pi \boldsymbol{X}M_W^2m_t^2}{\rm Im}\Bigg([V\boldsymbol{m}_d^2V^\dagger \boldsymbol{m}_u G G^\dagger \boldsymbol{m}_u]_{33}P_1} -m_t^2[V\boldsymbol{m}_d^2 V^\dagger(\boldsymbol{m}_u G \boldsymbol{m}_d G'^\dagger+G' \boldsymbol{m}_d G^\dagger \boldsymbol{m}_u)]_{33}\frac{P_0}{M_{\Phi}^2}\Bigg)\, , \label{eq:sefinal} \\ \epsilon_{\rm vertex}&\sim&\frac{g_w^2}{32\pi \boldsymbol{X}M_W^2}{\rm Im} \Bigg([G^*\boldsymbol{m}_dV^\dagger \boldsymbol{m}_u G \boldsymbol{m}_d V^T \boldsymbol{m}_u]_{33}\frac{P_0}{M_\Phi^2}+[G'^*V^\dagger G'\boldsymbol{m}_d^2 V^T]_{33}P_1 \nonumber\\ && \phantom{\frac{g^2}{32\pi \boldsymbol{X}M_W^2}{\rm Im}\Bigg([G^*\boldsymbol{m}_dV^\dagger \boldsymbol{m}_u G \boldsymbol{m}_d V^T \boldsymbol{m}_u]_{33}\frac{P_0}{M_\Phi^2}} +10\left[G'^* V^\dagger \boldsymbol{m}_u G \boldsymbol{m}_d V^T+G^*\boldsymbol{m}_d V^\dagger G' V^T \boldsymbol{m}_u\right]_{33}P_1\Bigg)\, . \label{eq:vertfinal} \end{eqnarray} \end{widetext} where $g_{w}$ is the weak coupling constant. In Eq. \ref{eq:vertfinal}, we have simplifed the expression by replacing logarithms that arise from the momentum integrals with their order of magnitude values, namely, a factor of 1 in the case of the $GG$ or $G'G'$ type terms, and a factor of 10 in the case of the mixed $GG'$ type terms. The full expressions have been used in the numerical analysis below. \subsection{Dependence of the asymmetry on quark masses} An important feature of the expressions for $\epsilon_{\rm wave}$ and $\epsilon_{\rm vertex}$ is their dependence on quark masses. Indeed, each of the terms of Eqs.~\ref{eq:sefinal}~and~\ref{eq:vertfinal} have a different quark masses dependence, and this determines which contribution dominates the asymmetry generation. The origin of these mass factors can be traced to either the chiral structure of the quark--$\Delta_{ud}$ couplings, or to the symmetry structure of the $G$ and $G'$ matrices, as we will outline below. The way in which the chiral nature of the couplings is related to the mass factors of $\epsilon_{\rm wave}$ and $\epsilon_{\rm vertex}$ can be easily understood. If the $G$ coupling to RH quarks is involved, chiral flips are required in order to couple the quarks to the $W$ in the loop diagrams. No such chiral flip is needed in the case of the $G'$ coupling to LH quarks. Therefore, the term proportional to $GG$ requires four mass insertions for the vertex correction\footnote{The necessity of four mass insertions appears to disagree with the expressions of \cite{Babu:2006xc,Babu:2013yca}, but does agree with the work of the same authors in \cite{Babu:2008rq}.}, as illustrated in Fig.~\ref{fig:helicityvertexcorrection}, and two for the wave function correction. The $GG'$ cross term requires only two mass insertions for both the vertex and wave function corrections, while the $G'G'$ term requires no chiral flips for either the wave or vertex topologies. Inspecting Eq.~\ref{eq:sefinal} we see that the wavefunction corrections appear to require two additional mass quark factors beyond those stipulated above. This occurs because, in the limit that the (down-type) quark in the wave function loop diagram is taken to be massless, the amplitudes all contain a factor of $(V^\dagger V)_{ij}=\delta_{ij}$. This renders the remaining product of coupling factors real. However, by retaining the next order term in a small mass expansion we obtain a $(V^\dagger m_d^2 V)_{ij} \ne \delta_{ij}$ dependence, and hence a product of couplings that, in general, will be complex\footnote{More generally, it is clear that distinct quarks masses and non trivial $V_{\rm CKM}$ mixing are important requirements for successful baryogenesis in this model.}. For a similar reason, the $G'G'$ vertex contribution also has a factor of $m_d^2$. Again, in the limit of zero quark mass, we would have \begin{equation} (G'^* V^\dagger G' V^T)_{33}=-\left|V_{\rm CKM}^*[g'^*-g'^\dagger]\right|_{3i}^2={\rm Real}\, , \end{equation} due to the antisymmetry of $g'$. (Note also that $V_{\rm CKM} \rightarrow \mathbb{1}$ in the zero quark mass limit.) Hence we are again required to keep the next order term in quark mass (arising from the cut loop integral) which yields a factor of $m_d^2$ and results in a coefficient which, in general, is complex. The quark mass factors in the various contributions to $\epsilon_{\rm wave}$ and $\epsilon_{\rm vertex}$ will determine which terms dominate the generation of the baryon asymmetry. We will now examine this in the context of the 3 benchmark coupling scenarios which satisfy our constraints from radiative quark masses and EDMs. \begin{figure} \begin{tabular}{cccl} \begin{fmffile}{vert1vca} \begin{fmfgraph*}(100,75) \fmfsurroundn{v}{6} \fmflabel{$u_L$}{v6} \fmflabel{$d_L$}{v2} \fmflabel{$\Delta_{ud}$}{v4} \fmf{dashes,tension=1}{v4,o1} \fmf{plain,tension=1}{o1,i11,i12} \fmf{plain,tension=1}{o1,i21,i22} \fmf{plain,tension=3.5}{i12,v2} \fmf{plain,tension=3.5}{i22,v6} \fmf{photon,tension=0}{i12,i22} \fmfv{label=$GP_L$,l.a=0}{o1} \fmfv{decor.shape=cross,decor.size=7,decoration.angle=45}{i11} \fmfv{decor.shape=cross,decor.size=7,decoration.angle=45}{i21} \fmfv{label=$u_R$,l.a=190}{i11} \fmfv{label=$d_R$,l.a=160}{i21} \fmfv{label=$u_L$,l.a=190}{i12} \fmfv{label=$d_L$,l.a=160}{i22} \end{fmfgraph*} \end{fmffile} && \begin{fmffile}{vert1ccaa} \begin{fmfgraph*}(75,75) \fmfsurroundn{v}{6} \fmf{dashes,tension=1}{v1,o1} \fmf{plain,tension=1}{v3,o2} \fmf{plain,tension=1}{o2,o1,o3} \fmf{plain,tension=1}{o3,v5} \fmfv{decor.shape=cross,decor.size=7,decoration.angle=45}{o2} \fmfv{decor.shape=cross,decor.size=7,decoration.angle=45}{o3} \fmflabel{$d_L$}{v3} \fmflabel{$u_L$}{v5} \fmflabel{$\Delta_{ud}$}{v1} \fmfv{label=$d_R$,l.a=-22}{o2} \fmfv{label=$u_R$,l.a=20}{o3} \fmfv{label=$G^\dagger P_R$,l.a=180}{o1} \end{fmfgraph*} \end{fmffile} \end{tabular} \caption{A diagrammatic explanation of the mass dependence of the vertex correction, in the case where the $\Delta_{ud}$ couples only to RH quarks. The necessity for four mass insertions can be understood as follows: $G$ couples a $\Delta_{ud}$ to two right-handed quarks, hence two mass insertions are required so that the quarks can exchange a $W$-boson. Then, in order for the helicities to correctly match the conjugated tree-level diagram, two more mass insertions are required. The corresponding expression for the asymmetry $\epsilon_{\rm vertex}$ is found to differ from that \cite{Babu:2006xc} and \cite{Babu:2013yca}, but to agree with that of \cite{Babu:2008rq}.}\label{fig:helicityvertexcorrection} \end{figure} \subsection{Size of the asymmetry for benchmark scenarios} \begin{table*} \begin{tabular}{| r || c | c || c | c |} \hline &$\epsilon_{\rm wave}(M_{\Phi}=200\ {\rm GeV})$ &$\epsilon_{\rm vertex}(M_{\Phi}=200\ {\rm GeV})$\\ \hline \hline $G_{\alpha\beta}\sim1$, $G'_{\alpha\beta}=0$&$10^{-9}$&$10^{-11}$\\ $G'_{\alpha\beta}\sim1$, $G_{\alpha\beta}=0$&$10^{-7}$&$10^{-6}$\\ $G_{\alpha\beta}\sim G'_{\alpha\beta}\sim10^{-3}$&$10^{-7}$&$10^{-6}$\\ \hline \end{tabular} \caption{Typical sizes of the CP asymmetry in the three benchmark scenarios. The first corresponds to the assumptions of \cite{Babu:2013yca,Babu:2006xc} in which the $\Delta_{ud}$ couples only to RH quarks, while the second corresponds to the scenario in which the $\Delta_{ud}$ couples only to LH quarks. In the final scenario, the $\Delta_{ud}$ couples to both RH and LH quarks with similar strength. In the case of $G'=0$ the asymmetries are smaller than those of \cite{Babu:2006xc,Babu:2008rq}, which adopt a different flavor structure for $G$ and is missing quark mass factors.} \label{tab:asymm} \end{table*} To determine the size of the baryon asymmetry in the presence of both the LH and RH couplings, we take the three benchmark scenarios defined by Eq. \ref{eq:benchmarks}. We generate random complex matrices which satisfy the appropriate symmetries\footnote{See Appendix~\ref{app:flavormass} for a discussion of the symmetries of $g'$.} of $G$ and $g'$, where all nonzero elements are of the order of magnitude specified by Eq.\ref{eq:benchmarks}. We then transform $g'$ to $G'$ by rotating to the mass basis, and compute the values $\epsilon_{\rm wave}$ and $\epsilon_{\rm vertex}$ according to Eqs.~\ref{eq:sefinal}-\ref{eq:vertfinal}. The typical order of magnitude obtained via this procedure is recorded in Table~\ref{tab:asymm} for each contribution to the total asymmetry. In the case of the wavefunction contribution, the term proportional to $G'G'$ (LH couplings) is weighted by $m_t^2$ while the term proportion to $GG$ (RH couplings) is weighted by $m_u m_t$. In the latter, $m_u$ may be either a $u$-quark or $c$-quark, as $m_u=m_t$ would lead to an overall real value. We therefore expect that the $GG$ contribution to be suppressed with respect to the $G'G'$ contribution by a factor of $m_c/m_t \sim 10^{-2}$. For the case of the vertex contribution, we instead expect that the $GG$ term is suppressed with respect to the $G'G'$ term by a factor of $(m_c m_t V^\dagger_{32})/(6 M_\Phi^2 V^\dagger_{21}) \sim 10^{-4}$. By comparing the first two lines of Table~\ref{tab:asymm} we see that these relative suppression factors are indeed reflected in the values of $\epsilon$ obtained. When $G \sim G'$, the $\epsilon$ are dominated by the $GG'$ cross terms and the $G'G'$ contributions. An important feature of the $\epsilon$'s is that they are insensitive to the overall magnitude of the couplings $G$ and $G'$. This is because both the numerator and denominator (via the terms denoted $\boldsymbol{X}$) carry two powers of $G$ or $G'$. However, it is not viable to make the couplings arbitrarily small because this would suppress the magnitude of the tree level decay rate, resulting in a large dilution factor and thus a final baryon asymmetry that is too small. Hence while the $G \sim G' \sim 10^{-3}$ benchmark (or, indeed, even smaller values of $G$ and $G'$) would appear to permit a CP-violating asymmetry, $\epsilon$, of sufficient size, it may be difficult to obtain a suitable tree level decay rate when all couplings are very small. From our simple analysis, we are able to conclude that the $G=0$, $G'\sim 1$, benchmark, in which the $\Delta_{ud}$ couples only to LH quarks, provides the most viable baryogenesis scenario and permits CP-violating asymmetries up to $\epsilon \sim 10^{-6}$ before any washout or dilution effects are incorporated. The $G\sim 1$, $G=0$ benchmark, in which the $\Delta_{ud}$ couples only to RH quarks, is less viable because the CP-violating asymmetries are suppressed by additional factors of light quark mass and/or small CKM matrix elements. The $G \sim G'$ benchmark, which features comparable couplings to LH and RH quarks, is disfavoured because the requirement that the magnitudes of the couplings the satisfy the EDM constraints yields too small a tree-level decay rate. It is important to note that our analysis assumes the coupling matrices have no strong flavor hierarchies. While the adoption of a specific flavor structure could relax our conclusions, a detailed exploration is beyond the scope of this paper. We also note that the CPV asymmetry in this scenario appears at second order in the B-violating coupling. Under certain assumptions, the requirements of CPT invariance and unitarity -- expressed via the so-called Nanopoulos-Weinberg theorem~\cite{Nanopoulos:1979gx,Kolb:1979qa} -- imply that the asymmetry should vanish at this order. Recently, however, it has been shown in general that this theorem may be evaded in the presence of additional interactions and decay modes~\cite{Bhattacharya:2011sy}, thereby allowing for a non-vanishing asymmetry at second order in the B-violating coupling. A specific application to a simplified version of the model considered here is given in the Appendix A of Ref~\cite{Babu:2013yca}. We defer a more detailed analysis of this issue to our future work. \section{Conclusions} \label{sec:conclusions} In this paper we have examined the ``Post Sphaleron Baryogenesis'' mechanism first introduced in \cite{Babu:2006xc}. While the original scenario featured the coupling of scalar diquarks to RH quarks, we extended the model by the addition of couplings to left-handed quarks, $\Delta_{ud}\bar QQ^c$, which results in a greatly enhanced baryon asymmetry. This occurs simply because baryogenesis proceeds via $W$ loop diagrams, for which contributions involving LH quarks in general require less quark mass insertions than those involving RH quarks. This comes at the cost, at least in the scenario in which both LH and RH couplings are present, of induced electric dipole moments of nucleons and atoms and radiative contributions to the quark masses. We find that the electric dipole moments of the neutron and $^{199}$Hg provide the most stringent constraints. Under the assumption that there is no significant hierarchy among the elements of LH coupling constant matrix $G'$ (and likewise the RH couplings $G$) and that the real and imaginary components of these couplings are comparable, the EDM constraints imply that the $GG'$ couplings constant products are in the $<10^{-5}-10^{-7}$ range. Hence either $G$, $G'$, or both must be small. We derived expressions for the self energy and vertex correction contributions to the baryon asymmetry generation, in the presence of couplings to both LH and RH quarks. This allowed up to estimate the relative size of the baryon asymmetry in three benchmark scenarios for which either the $G$, $G'$, or both couplings are non-zero. The most viable scenario was found to be that where only the $G'$ couplings to LH quarks are present. The scenario with only $G$ couplings to RH quarks is disfavoured because additional factors of light quark mass suppress the size of the baryon asymmetry generated, while the scenario in which $G$ and $G'$ are both nonzero is disfavoured by the EDM constraints. Therefore, our new couplings of the diquark scalars to LH quarks is critical for the successful generation of a baryon asymmetry in this model. \section*{Acknowledgments} NFB, TC, and MN were supported in part by the Australian Research Council. MJRM was supported in part under U.S. Department of Energy contract DE-SC0011095. This work was performed in part at the Aspen Center for Physics, which is supported by National Science Foundation grant PHY-1607611.
\section{Introduction} If $X$ and $Y$ are square integrable martingales, the martingale $$C(X,Y)_{\,t} := [X,Y]_t-\aPP{X}{Y}_t, \quad t\ge 0,$$ is called the \emph{compensated-covariation process} of $X$ and $Y$. Here $[X,Y]$ and $\aPP{X}{Y}$ denote the quadratic covariation and the predictable quadratic covariation of $X$ and $Y,$ respectively. A family $\Xscr$ of square integrable martingales is called \emph{compensated-covariation stable} if $C(X,Y) \in\Xscr$ for all $X,Y\in\Xscr$. Compensated-covariation stability was introduced by Di Tella and Engelbert in \cite{DTE15} to investigate the predictable representation property (PRP) of families of martingales. Di Tella and Engelbert further exploited this property in \cite{DTE16} to construct families of martingales possessing the chaotic representation property (CRP). Let $\Xscr:=\{\X{\al}, \, \al\in\Lm \}$ be a family of square integrable, quasi-left continuous martingales, where $\Lm$ is an arbitrary index set. In \cite{DTE15} the following recursive representation formula for products of elements from $\Xscr$ was shown, provided that $\Xscr$ is compensated-covariation stable: \begin{equation} \label{product} \begin{split} \prod_{i=1}\p N X\p{\al_{i}} =& \sum_{i=1}\p N\sum_{{1\leq j_1<\ldots<j_i\leq N}}\Bigl( \prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N X\p{\al_k}_-\Bigr)\cdot X\p{\al_{j_1},\ldots, \al_{j_i}} \\ &+ \sum_{i=2}\p N\sum_{1\leq j_1<\ldots<j_i\leq N}\Bigl(\prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N X\p{\al_k}_-\Bigr) \cdot \pb{X\p{\al_{j_1},...,\al_{j_{i-1}}}}{X\p{\al_{j_{i}}}}, \end{split} \end{equation} where $X^{\al_{j_1}, \al_{j_2}}:= C(X^{\al_{j_1}}, X^{\al_{j_2}})$ and $X\p{\al_{j_1},\ldots, \al_{j_i}}:= C(X\p{\al_{j_1},\ldots,\al_{j_{i-1}}}, X^{\al_{j_i}})$. Relation \eqref{product} was the corner stone to obtain sufficient conditions on $\Xscr$ for the PRP and the CRP. It will also be the starting point in the present paper to derive a representation formula for products of iterated integrals. In the first part of this work, we show that the compensated-covariation stability of the family $\Xscr$, which is required for \eqref{product}, transfers to the family $\Jscr_\rme$ of the elementary iterated integrals generated by $\Xscr$ (see Definition \ref{def:sp.mul.int} for $\Jscr_\rme$). This straightforwardly leads to a a version of the {\it recursive} representation formula \eqref{product} for products of elements from $\Jscr_\rme$ (see Theorem \ref{thm:prod.for.it.int} below). This recursive representation formula turns out to be crucial for deriving our product and moment formulas. Let $X$ be a L\'evy processes such that $\Ebb[|X_t|\p N]<+\infty$, $N\in\Nbb$. As a by-product of Theorem \ref{thm:prod.for.it.int}, we get in Theorem \ref{thm:mom.lev} below a recursive representation formula for $\Ebb[X_t\p N]$ in terms of lower moments of $X_t$. This formula seems also to be new and of independent interest. In the second part of the paper (which is Section 4), using the general theory for compensated-covariation stable families developed in the first part as a tool, we obtain product and moment formulas for the iterated integrals generated by families of martingales associated with a L\'evy process. The main idea is to exploit the recursive formula obtained in Theorem \ref{thm:prod.for.it.int} until we explicitly solve the recursion. Let $X$ be a L\'evy process with characteristic triplet $(\gm,\sig\p2,\nu)$ and let $\mu$ be the measure defined by $\mu:=\sig\p2\delta_0+\nu$, where $\delta_0$ is the Dirac measure concentrated in zero and $\nu$ is the L\'evy measure of $X$. With any system of functions $\Lm\subseteq L\p2(\mu)$ we associate a family $\Xscr_\Lm=\{\X{\al},\ \al\in\Lm\} $ of square integrable martingales setting \equa X\p\al_t:=\al(0) \sigma W_t +\int_{[0,t]\times \Rbb } \al(x)\tilde N(\rmd s,\rmd x), \tion where $W$ is the Brownian motion and $\tilde N$ the compensated Poisson random measure appearing in the L\'evy-It\^o decomposition of $X.$ We recall that, if $\Lm$ is a total system (i.e., the linear hull is dense), then the family $\Xscr_\Lm$ possesses the CRP (see \cite[Theorem 6.6]{DTE16}). As a first step, we show the product formula for the elementary iterated integrals $\Jscr_\rme$ generated by $\Xscr_\Lm$, provided that $\Jscr_\rme$ is compensated-covariation stable (cf.\ Theorem \ref{thm:prod.rule} below). From this product formula the moment formula \eqref{moment-formula} is obtained. In Example \ref{calculation} we illustrate formula \eqref{moment-formula} in some special cases. In Theorem \ref{thm:gen.it.in} below, which is the main result of this paper, we extend the product and the moment formula to (non-necessarily elementary) iterated integrals generated by any family $\Xscr_\Lm$ satisfying $\Lm \subseteq \bigcap_{p\geq2}L\p p(\mu).$ Especially, $\Xscr_\Lm$ does not need to be compensated-covariation stable. This extension is important because, to ensure the compensated-covariation stability of $\Xscr_\Lm$, it is necessary to require that $\Lm\subseteq L\p2(\mu)$ is stable under multiplication. However, in some important situations, as in the case of an orthonormal basis of $L\p2(\mu)$, the system $\Lm$ may fail to be stable under multiplication. Thanks to Theorem \ref{thm:gen.it.in}, for any L\'evy process $X$, we have at our disposal a rich variety of families of martingales $\Xscr_\Lm$ that, according to \cite{DTE16}, possess the CRP, and the product and moment formulas hold for the iterated integrals generated by $\Xscr_\Lm$. \smallskip We now give an overview of results about product and moment formulas which are available in the literature. Russo and Vallois generalize in \cite{RussoVallois} the well-known product formula of two iterated integrals generated by a Brownian motion (see \cite{N06}) to a version where the iterated integrals are generated by a normal martingale. To define the iterated integrals Russo and Vallois follow the approach of Meyer \cite{Me76}. In \cite{LeeShih04}, Lee and Shih introduced the \emph{multiple integrals} associated with a L\'evy process following It\^o \cite{I56} and then they obtained the product formula of two multiple integrals. We recall that, for L\'evy processes, there is a direct relation between iterated integrals, as defined in \S\ref{subs:el.it.int} below, and the multiple integrals introduced by It\^o in \cite{I56} (see \cite[Proposition 6.9]{DTE16} and \cite[Proposition 7]{SU07}). The relation between moments, cumulants, iterated integrals and orthogonal polynomials was studied by Sol\'e and Utzet in \cite{SU08} and \cite{SU081} for the case of Teugels martingales and for L\'evy processes possessing moments of arbitrary order or an exponential moment. Peccati and Taqqu gave in \cite{PT11} product formulas for iterated integrals generated by a Brownian motion. In this case, the basic tool is the \emph{hypercontractivity} of the iterated integrals. However, hypercontractivity is typical for the Brownian case and it does not hold, for instance, for iterated integrals generated by a compensated Poisson process. This is the reason why for L\'evy processes, in general, additional integrability conditions on the integrands are required if product or moment formulas are considered. In Peccati and Taqqu \cite{PT11} also moments and cumulants of products for multiple integrals generated by a Poisson random measure have been investigated. This was done on the basis of the Mecke formula (see Mecke \cite{M67}) and diagram formulas. For similar results we refer also to Surgailis \cite{S84}. In Last et al.\ \cite{LPST14}, again on the basis of the Mecke formula and of diagram formulas, more general product and moment formulas for multiple iterated integrals than those in \cite{PT11} and \cite{S84} have been obtained. We stress that all these results cannot be applied for L\'evy processes with a Gaussian part, because in this case the Mecke formula is not applicable. First results about the product and the moment formulas for L\'evy processes with non-vanishing Gaussian part, were obtained by Geiss and Labart in \cite{GL16,GL17}, where iterated integrals generated by a simple L\'evy process (i.e., the sum of a Brownian motion and of a compensated Poisson process) are considered. The moment formula in Theorem \ref{thm:gen.it.in} below generalizes \cite{GL16,GL17} to arbitrary L\'evy processes. This paper has the following structure: We summarise the necessary background in Section \ref{sec:prel}. In Section \ref{sec:mom.el.it} we study the properties of the elementary iterated integrals generated by a compensated-covariation stable family of martingales. In Section \ref{sec:Lev.pr} we obtain product and moment formulas for the iterated integrals generated by families of martingales associated with a L\'evy process. We then conclude giving concrete examples of these families, including Teugels martingales. \section{Preliminary Notions}\label{sec:prel} Let $(\Om,\Fscr,\Pbb)$ be a \emph{complete} probability space and let $\Fbb$ be a filtration satisfying the \emph{usual conditions}. We shall always consider real-valued stochastic processes on a finite time horizon $[0,T]$, $T>0,$ and assume that $\Fscr= \Fscr_T.$ Let $\Xscr$ be a family of processes. By $\Fbb\p\Xscr$ we denote the smallest filtration satisfying the usual conditions such that $\Xscr$ is an adapted family. If $\Xscr=\{X\}$ we write $\Fbb\p\Xscr=\Fbb\p X$. We say that a process $X$ has a finite moment of order $N$ if $\Ebb[|X_t|\p N]<+\infty$, $t\in[0,T]$. If this holds for every $N\in\Nbb$, we say that $X$ has finite moments of every order. For a \cadlag process $X$, we denote by $\Delta X:=X-X_-$ the \emph{jump process} of $X$, with $X_{t-}:=\lim_{s\uparrow t}X_s$ for $t>0$, and, by convention, $X_{0-}:=X_0$ so that $\Delta X_0=0$. In the present paper, $\Fbb$-martingales are always assumed to be c\`adl\`ag and starting at zero. A martingale $X$ belongs to $\Hscr\p p$ if $\|X\|_p\p p:=\Ebb[|X_T|\p p]]<+\infty$, $p\geq1$, and $(\Hscr\p p,\|\cdot\|_{\Hscr\p p})$ is a Banach space for every $p\geq1$ and a Hilbert space for $p=2$. We sometimes write $\Hscr\p p(\Fbb)$ to specify the filtration. If $X,Y\in\Hscr\p{\,2}$, then there exists a unique predictable process of integrable variation, denoted by $\pb{X}{Y}$ and called the \emph{predictable covariation} of $X$ and $Y$, such that $XY-\pb{X}{Y}\in\Hscr\p1$ and $\pb{X}{Y}_0=0$. For $X\in\Hscr\p2$, the process $\aPP{X}{X}$ has a continuous version if and only if $X$ is a quasi-left continuous martingale (cf.\ \cite[Theorem I.4.2]{JS00}), that is, $\Delta X_\tau=0$ for every \emph{predictable} stopping time $\tau$. With two semimartingales $X$ and $Y$, we associate the process $[X,Y]$, called covariation of $X$ and $Y$, defining \begin{equation*} [X,Y]_{\,t}:=\pb{X\p c}{Y\p c}_{\,t}+\sum_{0\leq s\leq t}\Delta X_{\,s}\Delta Y_{\,s},\quad t\in[0,T], \end{equation*} where $X\p c$ and $Y\p c$ denote the continuous martingale part of $X$ and $Y$ respectively. For $X,Y\in\Hscr\p{\,2}$, the process $[X,Y]$ is of integrable variation and $[X,Y]-\pb{X}{Y}\in\Hscr\p1$, that is $\pb{X}{Y}$ is the \emph{predictable compensator} of $[X,Y]$ (\cite[Proposition I.4.50 b)]{JS00}). We recall the definition of the stochastic integral with respect to a martingale $X\in\Hscr\p{\,2}$. The space of integrands for $X$ is given by $\Lrm\p{2}(X):=\{H\textnormal{ predictable}: \Ebb[H\p{\,2}\cdot\pb XX_T]<+\infty\}$, where we denote $H\p{\,2}\cdot\pb XX_T:=\int_0\p TH\p2_s\rmd \aPP{X}{X}_s$. For $X\in\Hscr\p{\,2}$ and $H\in\Lrm\p{2}(X)$ we denote by $H\cdot X$ or $\int_0\p\cdot H_s\rmd X_s$ the stochastic integral of $H$ with respect to $X$, characterized as follows: Let $Z\in\Hscr\p2$. Then $Z=H\cdot X$ if and only if $\pb ZY=H\cdot\pb XY$, for every $Y\in\Hscr\p{\,2}$. Let $\Lm$ be an arbitrary parameter set and $n\leq m$ natural numbers. By $\al_{n:m}$ we denote the ordered $(m-n+1)$-dimensional tuple $(\al_n,\ldots,\al_m)\in\Lm\p {m-n+1}$. For $\al_{n_1:m_1}\in \Lm\p {m_1-n_1+1}$ and $\bt_{n_2:m_2}\in\Lm\p {m_2-n_2+1}$, we denote by $\al_{n_1:m_1},\bt_{n_2:m_2}$ the $(m_1-n_1+1)+(m_2-n_2+1)$-dimensional tuple obtained by continuing with $\bt_{n_2:m_2}$ after $\al_{n_1:m_1}$, that is, $\al_{n_1:m_1},\bt_{n_2:m_2}:=(\al_{n_1},\ldots,\al_{m_1},\bt_{n_2},\ldots,\bt_{m_2})$. We use the following notation: For any measure $\rho$ and any function $f\in L\p1(\rho)$, we denote by $\rho(f)$ the integral of $f$ with respect to $\rho$, that is, $ \rho(f):=\int f(x)\,\rho(\rmd x)$. \section{Iterated integrals and compensated-covariation stability}\label{sec:mom.el.it} In this section we introduce compensated-covariation stable families of martingales and iterated integrals generated by such families. We show that if $\Xscr\subseteq\Hscr\p2$ is a compensated-covariation stable family, then the family of elementary iterated integrals generated by $\Xscr$ is compensated-covariation stable as well. Using this property, we deduce a formula to represent products and moments of iterated integrals. \subsection{Iterated integrals}\label{subs:el.it.int} To begin with, we define elementary iterated integrals generated by a finite family of martingales. For $\X\al\in\Hscr\p2$ with deterministic point brackets $\aPP{\X{\al}}{\X{\al}}$, we denote \equal \label{rho} \rho\p{\al} (\rmd t) := \rmd\aPP{\X{\al}}{\X{\al}}_t, \quad t\in[0,T]. \tionl Let now $m\in\Nbb$ be given and $\X{\al_1},\ldots,\X{\al_m}\in\Hscr\p2$ be such that the predictable covariation $\aPP{\X{\al_j}}{\X{\al_k}}$ is a deterministic function for $j,k=1,\ldots,m$. Then we denote by $\rho\p{\al_{1:m}}$ the product measure \equal \label{product-rho} \rho\p{\al_{1:m}} := \rho\p{\al_1}\otimes \ldots \otimes \rho\p{\al_m} \tionl on $([0,T]\p m,\Bscr([0,T])\p m)$. \begin{definition}\label{elem.it.int.} \textnormal{(i)} The space of bounded measurable functions on $[0,T]$ will be denoted by $\Bb_T$. For $m\ge 1$ we introduce the tensor product $$ \Bb_T\p {\otimes m}:=\{F_{\otimes_m}=F_1\otimes\cdots\otimes F_m: F_1,\ldots,F_m \in \Bb_T \} $$ and call the elements $F_{\otimes_m}$ \emph{elementary functions of order} $m$. For $m=0$ put $F_{\otimes_0}:=1$. \textnormal{(ii)} Let $m\geq0$ and the martingales $\X{\al_1}, \X{\al_2}, \ldots, \X{\al_m}\in\Hscr\p2$ be fixed. For all $0\leq n\leq m$, the $n$\emph{-fold elementary iterated integral} of $F_{\otimes_n} \in\Bb_T\p {\otimes n} $ with respect to the martingales $(\X{\al_1}, \X{\al_2}, \ldots, \X{\al_n})$ is defined inductively by letting $J_{0}:\Rbb \to \Rbb $ be the identical map and \begin{equation}\label{eq:def.sim.mul.int} J_{n}\p{\al_{1:n}}(F_{\otimes_n})_{\,t} :=\int_0^t J_{n-1}^{\al_{1:n-1}}(F_{\otimes_{n-1}})_{u-}\,F_{n}(u)\, \rmd {\X{\al_{n}}_u},\quad t\in [0,T]\,. \end{equation} \end{definition} \bigskip The following properties of elementary iterated integrals are shown in \cite[Lemma 3.2]{DTE16}. \begin{proposition}\label{prop:isom.sim.mul.int} \textnormal{(i)} Let $m\geq 1$, $\X{\al_1}, \ldots\ , \X{\al_m} \in \Hscr\p2$ such that $\aPP{\X{\al_j}}{\X{\al_k}}$ is a deterministic function, $j,k=1,\ldots,m$. Then we have $J_{m}\p{\al_{1:m}}(F_{\otimes_m}) \in \Hscr\p2$ for $m\geq1$. \textnormal{(ii)} Let $n\geq 1$, $\X{\bt_1}, \ldots\ , \X{\bt_n} \in \Hscr\p2$ such that $\aPP{\X{\bt_j}}{\X{\bt_k}}$ is a deterministic function, $j,k=1,\ldots,n$. Then for any $F_{\otimes_m} \in \Bb_T\p {\otimes m} $ and $G_{\otimes_n} \in \Bb_T\p {\otimes n}$ it holds $\Ebb\big[J_{m}^{\al_{1:m}}(F_{\otimes_m})_{\,t}J_{n}^{\bt_{1:n}}(G_{\otimes_n})_{\,t}\big]=0$, if $ m\neq n$, while, if $m=n$, \beq\label{eq:IRmix.el} \begin{split} \Ebb\big[J_{m}^{\al_{1:m}}(F_{\otimes_m})_{\,t}&J_{m}^{\bt_{1:m}}(G_{\otimes_m})_{\,t}\big]\\ =&\displaystyle\int_0\p t\int_0\p {t_m-}\!\!\!\!\!\!\!\!\!\cdots\int_0\p{t_2-}\!\!\!\!F_1(t_1)G_1(t_1)\ldots F_ m(t_m)G_ m(t_m)\,\rmd\aPP{\X{\al_1}}{\X{\bt_1}}_{t_1}\ldots \rmd\aPP{\X{\al_m}}{\X{\bt_m}}_{t_m}\,. \end{split} \end{equation} \end{proposition} The next lemma concerns some properties of elementary iterated integrals, which will be useful in this paper. \begin{lemma}\label{lem:mom.it.int} Let $\X{\al_j}\in \Hscr\p2$ have moments of every order for $j=1,\ldots,m$. \textnormal{(i)} For every $F_{\otimes_m} \in \Bb_T\p {\otimes m}$ and every $p>0$ we have the estimate \equal \label{sup} \Ebb\Bigg[\sup_{t\in[0,T]} \Big|J\p{\al_{1:m}}_{m}(F_{\otimes_m})_t\Big|\p{p}\Bigg]<\infty. \tionl \textnormal{(ii)} Assume that $p \geq1.$ Let $\X{\al\p n_1},\ldots,\X{\al\p n_m} \in \Hscr\p2$ be such that \smallskip \hspace{.5cm}\textnormal{(1)} $\aPP{\X{\al\p n_j}}{\X{\al\p n_k}}$ is a deterministic function for every $j,k=1,\ldots,m$ and $n\ge1$; \hspace{.5cm}\textnormal{(2)} each $\X{\al\p n_j}$ has finite moments of every order; \hspace{.5cm}\textnormal{(3)} $\X{\al\p n_j}\longrightarrow\X{\al_j}$ in $\Hscr\p{2\p m p}$, as $n\rightarrow+\infty$. \smallskip Then, for every $F_{\otimes_m} \in \Bb_T\p {\otimes m}$, we have \[ \lim_{n\rightarrow+\infty}\Ebb\left[\sup_{t\in[0,T]}\Big|J_m\p{\al_{1:m}\p n}(F_{\otimes_m})_t-J_m\p{\al_{1:m}}(F_{\otimes_m})_t\Big|\p{p}\right]=0. \] \end{lemma} \begin{proof} We prove both the statements by induction on $m$. We start proving (i). We only consider the case $p\geq1$, since the case $0<p<1$ immediately follows by the case $p=1$ and Jensen's inequality. If $m=0$ there is nothing to prove. We now assume that \eqref{sup} holds for an arbitrary $p \geq1$ and every $j\leq m,$ and we show it for $m+1$. By Burkh\"older--Davis--Gundy's inequality, from now on BDG's inequality, (see \cite[Theorem 2.34]{J79}) \equa \Ebb\Bigg[\sup_{t\in[0,T]}\Big|J\p{\al_{1:{m+1}}}_{{m+1}}(F_{\otimes_{m+1}})_t\Big|\p{p}\Bigg] &\leq& C_{p} \Ebb\Bigg[\Big[J\p{\al_{1:{m+1}}}_{{m+1}}(F_{\otimes_{m+1}}),J\p{\al_{1:{m+1}}}_{{m+1}}(F_{\otimes_{m+1}})\Big]_T\p{p/2}\Bigg] \\ &=& C_{p}\Ebb\Bigg[\Big(J\p{\al_{1:{m}}}_{{m}}(F_{\otimes_{m}})_-\p2F_{m+1}\p2\Big)\cdot\big[\X{\al_{m+1}},\X{\al_{m+1}}\big]_T\Big)\p {p/2}\Bigg] \\ &\leq& C_{p} c_{m+1}\p p \Ebb\Bigg[\sup_{t\in[0,T]} \Big|J\p{\al_{1:{m}}}_{{m}}(F_{\otimes_{m}})_t\Big|\p{2p}\Bigg]\p{1/2}\!\!\! \Ebb\Big[\big[\X{\al_{m+1}},\X{\al_{m+1}}\big]_T\p{p}\Big]\p{1/2}\,, \tion where ${c_{m+1}=\sup_{t \in[0,T]} |F_{m+1}(t)|<+\infty}$. Notice that \[\Ebb[[\X{\al_{m+1}},\X{\al_{m+1}}]_T\p{p}\Big] \le c_{(2p)} \Ebb[|\X{\al_{m+1}}_T|^{2p}] < \infty, \] where the constant $c_{(2p)}$ arises from the use of BDG's inequality and Doob's martingale inequality. Hence, the right hand side of the above estimate is finite by the induction hypothesis. The proof of (i) is complete. Concerning (ii) we observe that \equa &&\Ebb\Bigg[\sup_{t\in[0,T]}\Big|J\p{\al\p n_{1:{m}}}_{{m}}(F_{\otimes_{m}})_t-J\p{\al_{1:{m}}}_{{m}}(F_{\otimes_{m}})_t\Big|\p{p}\Bigg] \\ && \quad\leq 2\p {p-1}\Bigg\{\Ebb\Bigg[\sup_{t\in[0,T]}\bigg|\int_0\p t\Big(J\p{\al\p n_{1:{m-1}}}_{{m-1}} (F_{\otimes_{m-1}})_{u-}-J\p{\al_{1:{m-1}}}_{{m-1}}(F_{\otimes_{m-1}})_{u-}\Big)F_m(u)\rmd \X{\al\p n_m}_u\bigg|\p p\Bigg]\\ &&\hspace{3cm}+ \Ebb\Bigg[\sup_{t\in[0,T]}\bigg|\int_0\p tJ\p{\al\p n_{1:{m-1}}}_{{m-1}}(F_{\otimes_{m-1}})_{u-}F_m(u)\rmd \big(\X{\al\p n_m}_u-\X{\al_m}_u\big)\bigg|\p p\Bigg]\Bigg\} \\ &&\quad\leq2\p {p-1}C_pc_m\p p\Bigg\{\Ebb\bigg[\sup_{t\in[0,T]}\Big|\big(J\p{\al\p n_{1:{m-1}}}_{{m-1}}(F_{\otimes_{m-1}})_{t}-J\p{\al_{1:{m-1}}}_{{m-1}}(F_{\otimes_{m-1}})_{t}\big)\Big|\p {2p}\bigg]\p{1/2}\Ebb\Big[\big[\X{\al\p n_m},\X{\al\p n_m}\big]_T\p p\Big]\p{1/2} \\&&\hspace{3cm}+ \Ebb\bigg[\sup_{t\in[0,T]}\Big|J\p{\al\p n_{1:{m-1}}}_{{m-1}}(F_{\otimes_{m-1}})_{t}\Big|\p {2p}\bigg]\p{1/2}\Ebb\Big[ \big[\X{\al\p n_m}-\X{\al_m},\X{\al\p n_m}-\X{\al_m}\big]_T\p p \Big]\p{1/2}\Bigg\}, \tion where we similarly as above used BDG's inequality and H\"older's inequality. Because of the convergence assumptions, we see that $\Ebb\big[\big[\X{\al\p n_m},\X{\al\p n_m}\big]_T\p p\big]$ is bounded in $n$ and $\Ebb\big[\big[\X{\al\p n_m}-\X{\al_m},\X{\al\p n_m}-\X{\al_m}\big]_T\p p\big]$ converges to zero, as $n\rightarrow+\infty$. Furthermore, because for $m=1$ we have \[ \Ebb\Bigg[\sup_{t\in[0,T]}\Big|J_1\p{\al\p n_{{1}}}(F_1)_t-J_1\p{\al_{1}}(F_{1})_t\Big|\p{2\p mp}\Bigg]\longrightarrow 0,\quad n\rightarrow+\infty, \] we can assume, for every $k\leq m-1$, \[ \Ebb\Bigg[\sup_{t\in[0,T]}\Big|J\p{\al\p n_{1:{k}}}_{{k}}(F_{\otimes_{k}})_t-J\p{\al_{1:{k}}}_{{k}}(F_{\otimes_{k}})_t\Big|\p{2\p{m-k}p}\Bigg]\longrightarrow 0,\quad n\rightarrow+\infty. \] Hence, (ii) follows by induction and the proof of the lemma is complete. \end{proof} As a next step we introduce some linear spaces of elementary iterated integrals and the definition of the chaotic representation property. \begin{definition}\label{def:sp.mul.int} Let $\Xscr:=\{\X{\al},\, \, \al\in\Lm\}\subseteq\Hscr\p2$, where $\Lm$ is an arbitrary parameter set. We assume that $\aPP{\X{\al}}{\X{\bt}}$ is a deterministic function, for each $\al,\bt\in\Lm$. (i) Let $\Jscr_{0}:=\Rbb$ be the space of $0$-fold elementary iterated integrals. (ii) Let $m\geq1$ and $\al_1, \ldots, \al_m\in\Lm$. By $\Jscr_{m}^{\al_{1:m}}$ we denote the linear hull of all $J_{m}^{\al_{1:m}}(F_{\otimes_m})$ with respect to $(\X{\al_1}, \X{\al_2}, \ldots, \X{\al_m})$ from $\Hscr\p2$ and $F_{\otimes_m} \in \Bb_T\p {\otimes m}$. (iii) For all $m\geq1$, we introduce \begin{equation*} \quad\scr J_{m}\!\!:=\!\!\Span\Big(\bigcup_{\al_{1:m}\in \Lm^m} \scr J_{m}^{\al_{1:m}}\Big),\qquad\scr J_{\rme}\!\!:=\!\!\Span\Big(\bigcup_{m\geq 0} \scr J_{m}\Big)\,, \end{equation*} We call $\scr J_{\rme}$ the space of elementary iterated integrals \emph{generated by} $\Xscr$. (iv) If $\scr J_{\rme}$ is dense in $(\Hscr\p2(\Fbb),\|\cdot\|_2)$, we say that $\Xscr$ possesses the \emph{chaotic representation property} (CRP) with respect to $\Fbb$. \end{definition} \begin{remark}\label{rem:alt.rep.crp} We now briefly recall an alternative formulation of the CRP. For details we refer to \cite[Proposition 3.7 and Theorem 3.11]{DTE16}. (i) From Proposition \ref{prop:isom.sim.mul.int} (ii), we deduce the equivalent representation $\Jscr_\rme=\bigoplus_{m\geq0}\Jscr_m$. Denoting now by $\Jscr$ and $\tilde\Jscr_m$ respectively the closure of $\Jscr_\rme$ and $\Jscr_m$ in $(\Hscr\p2,\|\cdot\|_2)$, we see that $\Jscr=\bigoplus_{m\geq0}\tilde\Jscr_m,$ and that $\Xscr$ has the CRP if and only if $\Hscr\p2(\Fbb)=\bigoplus_{m\geq0}\tilde\Jscr_m$. (ii) If furthermore $\Xscr$ consists of countably many martingales (that is, $\Lm$ is a countable index set) which are pairwise orthogonal, we can write \[ \Jscr=\bigoplus_{m\geq0}\bigoplus_{\al_{1:m}\in \Lm^m} \tilde\Jscr_{m}^{\al_{1:m}}, \] $\tilde\Jscr_{m}^{\al_{1:m}}$ denoting the closure of $\Jscr_{m}^{\al_{1:m}}$ in $(\Hscr\p2,\|\cdot\|_2)$. \end{remark} \bigskip We conclude this section introducing \emph{the iterated integrals} as an isometric extension of the elementary iterated integrals. For $t\in[0,T]$ and $m\geq 1$, we introduce the set \begin{equation}\label{eq:def.Mn} M_{\,t}^{\, m}:=\{(t_1,\ldots,t_m): \ 0\leq t_1 <\ldots < t_m < t\}. \end{equation} We recall the definition of $\rho\p{\al}$ and $\rho\p{\al_{1:m}}$ given in \eqref{rho} and \eqref{product-rho}, respectively. For $m\geq1$, we denote by $\Escr_t^m$ the linear subspace of $L^2({M}_{\,t}^{\, m}, \rho^{\al_{1:m}})$ generated by $F_{\otimes_m} \in \Bb_T\p {\otimes m}$ restricted to ${M}_{\,t}^{\, m}$. Notice that $\Escr_t^m$ is dense in $L^2({M}_{\,t}^{m}, \rho^{\al_{1:m}})$. From \eqref{eq:IRmix.el} we have the isometry relation \begin{equation}\label{eq:isom} \|J_m\p{\al_{1:m}}(F)_t\|_{L\p2(\Pbb)}= \|F\|_{L^2({M}_{\,t}^{\, m},\, \rho^{\al_{1:m}})}\, \end{equation} between $\{ F:= F_{\otimes_m} 1_ {{M}_{\,t}^{\, m}}: F_{\otimes_m} \in \Bb_T\p {\otimes m} \}$ and $L\p2(\Pbb)$. We linearly extend $J_m\p{\al_{1:m}}(\cdot)_t$ to $\Escr_t^m$, and by continuity, to $L^2({M}_{\,t}^{m}, \rho^{\al_{1:m}})$, denoting this extension again by $J_m\p{\al_{1:m}}(\cdot)_t$. Recall that $J_0$ denotes the identity map on $\Rbb$. \begin{definition} We call the mapping $J_m\p{\al_{1:m}}(F)$, $F\in L^2({M}_{\,T}^{\,m}, \rho^{\al_{1:m}})$, defined above an \emph{iterated integral} with respect to $(X\p{\al_1},\ldots, X\p{\al_m})$. \end{definition} In the next proposition we summarize the properties of iterated integrals. \begin{proposition}\label{prop:isom.mul.int} Let $m\geq1$, $\al_1,\ldots,\al_m\in\Lm$, $F\in L^2({M}_{\,T}^{\,m}, \rho^{\al_{1:m}})$ and let $\X{\al_1}, \ldots\ , \X{\al_n} \in \Hscr\p2$ be such that $\aPP{\X{\al_j}}{\X{\al_k}}$ is a deterministic function for $j,k=1,\ldots,m$. \\ \textnormal{(i)} $J_{m}\p{\al_{1:m}}(F_{\otimes_m})$ belongs to $ \Hscr\p2$ and it is quasi-left continuous. \\ \textnormal{(ii)} Let moreover $n\geq1$, $\bt_1, \ldots, \bt_n\in \Lm$, $G\in L^2({M}_{\,T}^{\,n}, \rho^{\bt_{1:n}})$ and let $\X{\bt_1}, \ldots\ , \X{\bt_n} \in \Hscr\p2$ be such that $\aPP{\X{\bt_j}}{\X{\bt_k}}$ is a deterministic function, $j,k=1,\ldots,n$. Then, for every $t\in[0,T]$, we have: If $ m\neq n$, then $\Ebb\big[J_{m}^{\al_{1:m}}(F)_{\,t}J_{n}^{\bt_{1:n}}(G)_{\,t}\big]=0$, while, if $m=n$, \equa \E \big[J_{m}^{\al_{1:m}}(F)_{\,t}\,J_{m}^{\bt_{1:m}}(G)_{\,t}\big] = \int_0\p t\int\p {t_{m}-}_0\!\!\cdots\int_0\p{t_2-}\!\! F(t_1,\ldots,t_m)\,G(t_1,\ldots,t_m)\,\rmd\aPP{\X{\al_1}}{\X{\bt_1}}_{t_1}\ldots \,\rmd\aPP{\X{\al_m}}{\X{\bt_n}}_{t_m}\,. \tion \end{proposition} \subsection{Compensated-covariation stable families of martingales} \begin{definition} Let $\Lm$ be an arbitrary parameter set and $\Xscr:=\{X\p{\al}, \al\in\Lm\}\subseteq\Hscr\p2$. (i) For every $\al_1,\al_2\in \Lm$ we define the process \begin{equation}\label{def:compcov} X\p{\al_{1:2}}:=\cv{X\p{\al_1}}{X\p{\al_2}}-\pb{X\p{\al_1}}{X\p{\al_2}} \end{equation} which we call \emph{the compensated-covariation} process of $X\p{\al_1}$ and $X\p{\al_2}$. (ii) The family $\Xscr$ is called \emph{compensated-covariation stable} if for every $\al_1, \al_2 \in \Lm$ it holds that $X\p{\al_{1:2}} \in \Xscr$. (iii) Let $\Xscr$ be a compensated-covariation stable family and let $\al_1,\ldots,\al_m\in \Lm$ with $m\geq2$. The process $X\p{\al_{1:m}}$ is defined recursively by \begin{equation}\label{eq:it.com.cov} X\p{\al_{1:m}}:=[X\p{\al_{1:m-1}},X\p{\al_{m}}] -\pb{X\p{\al_{1:m-1}}}{X\p{\al_{m}}} \end{equation} and called $m$-fold compensated-covariation of the ordered $m$-tuple of martingales $(X\p{\al_1},\ldots,X\p{\al_m})$. We sometimes use also the notation $X\p{\al_1,\ldots,\al_m}$ instead of $X\p{\al_{1:m}}.$ \end{definition} Notice that if the family $\Xscr$ is compensated-covariation stable, then $X\p{\al_{1:m}} \in \Xscr$ holds, for every $\al_1,\ldots,\al_m$ in $\Lm$ and $m\geq2$. As a toy-example of a compensated-covariation stable family consider the family $\Xscr:=\{X\}$, where $X_t=N_t-\lm t $, $t\geq0$, and $N$ is a homogeneous Poisson process with parameter $\lm$. In this case we have $\aPP{X}{X}_t=\lm t$ and \[ [X,X]_t-\aPP{X}{X}_t=\sum_{s\leq t}(\Delta N_s)\p 2-\lm t=\sum_{s\leq t}\Delta N_s-\lm t=X_t. \] More generally, let $N$ be a simple point process, i.e., $N$ is a \cadlag adapted increasing process taking value in the set $\Nbb$ of natural numbers such that $N_0=0$ and $\Delta N\in\{0,1\}$. Let $N\p p$ be the predictable compensator of $N$ and assume that $N\p p$ is continuous (i.e., that $N$ is quasi-left continuous). Then the family$\Xscr:=\{X\}\subseteq\Hscr\p2_\mathrm{loc}$, where $X:=N-N\p p$, is compensated-covariation stable. Next we state a representation formula for products of martingales from $\Hscr\p2$. Thanks to the \emph{quasi-left continuity} which we assume here, the representation formula is a simpler version of the one shown in \cite[Proposition 3.3]{DTE15}. \begin{proposition}\label{prop:rep.pol} Let $\Xscr:=\{X\p{\al},\ \al\in\Lm\}$ be a compensated-covariation stable family of quasi-left continuous martingales in $\Hscr\p{\,2}$. For every $N\geq1$ and $\al_1,\ldots,\al_N\in \Lm$, we have \begin{equation}\label{eq:rep.pol} \begin{split} \prod_{i=1}\p N X\p{\al_{i}} =& \sum_{i=1}\p N\sum_{{1\leq j_1<\ldots<j_i\leq N}}\Bigl( \prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N X\p{\al_k}_-\Bigr)\cdot X\p{\al_{j_1:j_i}} + \sum_{i=2}\p N\sum_{1\leq j_1<\ldots<j_i\leq N}\Bigl(\prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N X\p{\al_k}_-\Bigr) \cdot \pb{X\p{\al_{j_1:j_{i-1}}}}{X\p{\al_{j_{i}}}}. \end{split} \end{equation} \end{proposition} \begin{remark} For compensated-covariation stable families with deterministic point brackets, sufficient conditions for the CRP (see Definition \ref{def:sp.mul.int} (iv)) are known. We briefly recall these results, for an extensive study of which we refer to \cite{DTE16}. The set $\Kscr$ of polynomials generated by $\Xscr$ is defined as the linear hull of products of elements of $\Xscr$ taken at different \emph{deterministic} times. Clearly, the completed $\sig$-algebra generated by $\Kscr$ coincides with $\Fscr\p\Xscr_T$. In \cite[Theorem 5.8]{DTE16}, the following result has been established: \medskip The family $\Xscr\subseteq\Hscr\p2(\Fbb\p\Xscr)$ possesses the CRP with respect to $\Fbb\p\Xscr$ provided that {\rm(i)} $\Xscr$ is compensated-covariation stable; {\rm(ii)} $\aPP{\X{\al_1}}{\X{\al_2}}$ is deterministic, for every $\al_1,\al_2\in\Lm$; {\rm(iii)} the family $\Kscr$ of polynomials generated by $\Xscr$ is dense in $L\p2(\Om,\Fscr\p\Xscr_T,\Pbb)$. \medskip We recall that to ensure (iii), it is sufficient that for every $X\in\Xscr$, the random variable $|X_t|$ possesses an (arbitrarily small) exponential moment for every $t\in[0,T]$: That is, there exist $c\p X_t>0$ such that $\Ebb[\exp(c\p X_t|X_t|)]<+\infty$, for every $t\in[0,T]$. For an elementary proof of this well-known result see, for example, \cite[Appendix A]{DTE15}. \end{remark} \subsection{Representing powers of processes}\label{subs:exa} As an application of Proposition \ref{prop:rep.pol} we show how to represent powers of a Brownian motion, of a homogeneous Poisson process and then, more generally, of a L\'evy process with finite moments of every order. \paragraph{Brownian Motion.} Let $X$ be a standard Brownian motion. Then $\Xscr=\{X\}\cup\{0\}$ is a compensated-covariation stable family. Furthermore $\aPP{X}{X}_t=t$ and $X\p{\al_{1:m}}=0$, for $m\geq2$. Therefore \eqref{eq:rep.pol} becomes \begin{equation}\label{eq:prod.for.one.mart.bm} X\p N_t=N \int_0\p tX_s\p {N-1}\rmd X_s+\frac{N(N-1)}{2}\,\int_0\p t X_s\p {N-2}\rmd s, \end{equation} which is in fact It\^o's formula applied to $X\p N$. \paragraph{Homogeneous Poisson Process.} We now denote by $N$ be a homogeneous Poisson process with parameter $\lm>0$. Then, setting $X_t:=N_t-\lm t$, $\Xscr=\{X\}$ is a compensated-covariation stable family. Furthermore, $X\p{\al_{1:m}}=X$, for every $m\geq1$. From \eqref{eq:rep.pol} we deduce \begin{equation}\label{eq:prod.for.one.mart.poi.pr} X\p N_t=\sum_{i=1}\p N \binom{N}{i} \int_0\p t X_{s-}\p {N-i}\rmd X_s+\lm\sum_{i=2}\p N \binom{N}{i}\int_0\p t X_{s-}\p {N-i}\rmd s. \end{equation} \paragraph{L\'evy Processes.} Let $\Fbb$ be a filtration satisfying the usual conditions and let $X$ be a L\'evy process relative to $\Fbb$, that is: $X$ is c\`adl\`ag, stochastically continuous, $\Fbb$-adapted, $X_{t+s}-X_s$ is independent from $\Fscr_s$ and $X_{t+s}-X_s\sim X_t$, for all $s,t\geq0$, and $X_0=0.$ The L\'evy-It\^o decomposition of $X$ is given by \begin{equation}\label{eq:leit.dec} X_t = \gamma t + W_t^\sigma + \int_{[0,t]\times\{|x|>1\} } x\, N(\rmd s,\rmd x) + \int_{[0,t]\times\{|x|\le1\} } x\,\tilde N(\rmd s,\rmd x), \end{equation} where $\gm\in\Rbb$, $\Ws$ denotes a Wiener process relative to $\Fbb$ with variance function $\Ebb[(\Ws_t)\p2]=\sig\p2 t$, and $N$ is the jump measure of $X$, which is a Poisson random measure relative to $\Fbb$. By $\tilde N:=N-\nu\otimes\lm_+$ we denote the compensated Poisson random measure associated with $N$, where $\lm_+$ denotes the Lebesgue measure on $[0,T]$ and $\nu$ the L\'evy measure of $X$ (i.e., $\nu$ is a $\sig$-finite measure on $\Rbb$ such that $\nu(\{0\})=0$ and $x\mapsto x\p2\wedge 1\in L\p1(\nu)$). We call $(\gm,\sig\p2,\nu)$ the characteristic triplet of $X$. \\ \smallskip We now assume that $X$ has finite moments of every order. This implies that, for $p_i(x):=x\p i$, we have $p_i\in L\p2(\nu)$ for all $i\geq1$ and $p_i\in L\p1(\nu)$ for all $i\geq2$. As in \cite{NS00} or \cite{SU08} we now define the power-jump processes of $X$ and the family of Teugels martingales, setting $L\p{(1)}:= X$ and \[ L\p{(i)}_t=\sum_{s\leq t}(\Delta X_s)\p i=\int_{[0,t]\times\Rbb}p_i(x)N(\rmd s,\rmd x),\quad n\geq2. \] The process $L\p{(i)}$ is called $i$-th power jump asset of $X$. It can be seen that $L\p{(i)}$ is a L\'evy process with L\'evy measure given by the image measure $\nu\p{(i)}=\nu\circ p_i\p{-1}$, $i\geq1$. Since $\nu\p{(i)}(p_j\p2)=\nu(p_{2j})<+\infty$, for $j\ge1$, $L\p{(i)}$ has finite moments of every order, for every $i\geq1$ and \begin{equation}\label{eq:mom.Li} \Ebb[L_1\p{(1)}]=\gm+\nu\big(1_{\{|p_1|>1\}}p_1\big),\qquad \Ebb[L_1\p{(i)}]=\nu(p_i),\quad i \geq2. \end{equation} Hence, $X\p{(i)}_t:=L_t\p{(i)}-\Ebb[L_1\p{(i)}]t $ is a square integrable martingale for $i\geq1$ and it is of finite variation for $i\geq2$. Furthermore, the identities $\aPP{X\p{(i)}}{X\p{(j)}}_t=(\nu(p_{i+j})+\sig\p21_{\{i=j=1\}})t$ and \begin{equation}\label{eq:teu.mar} [X\p{(i)},X\p{(j)}]-\aPP{X\p{(i)}}{X\p{(j)}}=X\p{(i+j)},\quad i,j\geq 1, \end{equation} hold. This shows that the family $\Xscr:=\{X\p{(i)}, \, i\geq1\}$ is compensated-covariation stable. It is easy to recognize that the $i$-fold compensated-covariation process of the $i$-tuple of martingales $(X\p{(1)},\ldots,X\p{(1)})$ equals $X\p{(i)}$, for every $i\geq2$. The family $\Xscr$ is the family of Teugels martingales. Notice that the family $\Xscr$ can be seen as the \emph{compensated-covariation stable hull} of the process $X\p{(1)}$. As a consequence of Proposition \ref{prop:rep.pol} applied to the family $\Xscr$, with $\al_1=\ldots=\al_N=1$, we can express the $N$-th power of $X\p{(1)}$ as follows: \begin{equation}\label{eq:prod.for.one.mart} \begin{split} (X\p{(1)}_t)\p N&=\sum_{i=1}\p N \binom{N}{i} \int_0\p t(X\p{(1)}_{s-})\p {N-i}\rmd X\p {(i)}_s+\sum_{i=2}\p N \binom{N}{i} \int_0\p t(X\p{(1)}_{s-})\p {N-i}\rmd\aPP{X\p{(i-1)}}{X\p{(1)}}_s \\&=\sum_{i=1}\p N \binom{N}{i} \int_0\p t(X\p{(1)})_{s-}\p {N-i}\rmd X\p {(i)}_s+\sum_{i=2}\p N \binom{N}{i} \int_0\p t(X\p{(1)}_{s-})\p {N-i}(\nu(p_{i})+\sig\p21_{\{i=2\}})\rmd s. \end{split} \end{equation} In the same way one can obtain formulas for the power of each Teugels martingale $X\p{(n)}$, $n\geq2$: \begin{equation*} \begin{split} (X\p{(n)}_t)\p N & =\sum_{i=1}\p N \binom{N}{i} \int_0\p t(X\p{(n)})_{s-}\p {N-i}\rmd X\p {(ni)}_s+\sum_{i=2}\p N \binom{N}{i} \int_0\p t (X\p{(n)}_{s-})\p {N-i}\nu(p_{ni})\rmd s. \end{split} \end{equation*} \subsection{Compensated-covariation stability of \texorpdfstring{$\Jscr_\rme$}{TEXT}} In this subsection we show that, if $\Xscr=\{\X{\al},\ \al\in\Lm\} \subseteq\Hscr\p2$ is compensated-covariation stable and $\aPP{X\p\al}{X\p\bt}$ is deterministic for every $\al,\bt\in\Lm$, then $\Jscr_\rme \subseteq\Hscr\p2$ and $\Jscr_\rme$ is compensated-covariation stable. In this way we can apply \eqref{eq:rep.pol} to compute products of elementary iterated integrals. Notice that, for $Y, X\in\Jscr_\rme$, the process $\aPP{Y}{X}$ is not deterministic in general. We shall often need the following assumption. \begin{assumption}\label{ass:det.com.cov} (i) The family $\Xscr:=\{\X{\al},\ \al\in\Lm\}\subseteq\Hscr\p2$ is compensated-covariation stable. (ii) $\Xscr$ consists of \emph{quasi-left continuous} martingales. (iii) $\pb{\X{\al}}{\X{\bt}}$ denotes the \emph{continuous version} of the predictable covariation between $\X{\al}$ and $\X{\bt}$ and it is a \emph{deterministic function of time} for every $\al,\bt\in\Lm$. \end{assumption} The following lemma will be used to show that $\Jscr_\rme$ is compensated-covariation stable. Recall that the notation $\Bb_T$ and $\Bb_T\p{\otimes m}$ was introduced in Definition \ref{elem.it.int.} (i). \begin{lemma}\label{lem:com.cov.it.int} Let $\Xscr$ satisfy Assumption \ref{ass:det.com.cov}. For $J_{m}^{\al_{1:m}}(F_{\otimes_m}), J_{n}^{\bt_{1:n}}(G_{\otimes_n}) \in\Jscr_\rme$ the processes $M$ and $N$ defined by \[ M_t:=\int_0\p tR\p{\,m,n}_{\,u-}H(u)\rmd \X{\gm}_{\,u},\qquad N_t:=\int_0\p t\int_0\p {s-}R\p{\,m,n}_{\,u-}K(u)\rmd\aPP{\X{\dt}}{\X{\et}}_{\,u}H(s)\rmd \X{\gm}_{\,s}\,, \quad t\in[0,T], \] with $R\p{\,m,n}:=J_{m}^{\al_{1:m}}(F_{\otimes_m})J_{n}^{\bt_{1:n}}(G_{\otimes_n}),$ belong to $\bigoplus_{k=0}\p{m+n+1}\scr J_{k}$, for all $\al_1,\ldots, \al_m;\ \bt_1,\ldots, \bt_{n};\ \gamma,\dt,\et\in\Lm$; for all $F_{\otimes_m} \in \Bb_T\p {\otimes m}$ and $G_{\otimes_n} \in \Bb_T\p {\otimes n}$; for all $H, K \in \Bb_T$ and every $m, n\in\Nbb$. \end{lemma} \begin{proof} For an arbitrary $m\in\Nbb$, we prove the lemma for every $n\in\Nbb$ by induction on $n$. If $n=0$, then $R\p{\,m,0}=J_{m}^{\al_{1:m}}(F_{\otimes_m})$ and so $M=J_{m+1}^{\al_{1:m},\gm}(F_{\otimes_m}\otimes H)$, which clearly belongs to the linear space $\bigoplus_{k=0}\p{m+1}\scr J_{k}$. We show that $N$ belongs to $\bigoplus_{k=0}\p{m+1}\scr J_{k}$ if $n=0$. The function $\wt F(t):=\int_0\p {t} K(u) \rmd\aPP{\X{\dt}}{\X{\et}}_{\,u}$ is deterministic, bounded and, by continuity of $\aPP{\X{\dt}}{\X{\et}}$, also continuous. By integration by parts and continuity of $\wt F$, we get \begin{equation}\label{eq:det.part0} \begin{split} \int_0\p t R\p{\,m,0}_{\,u-}K(u)\rmd\aPP{\X{\dt}}{\X{\et}}_{\,u}&=R\p{\,m,0}_{\,t}\wt F(t)-\int_0\p t\wt F(u)\rmd R\p{\,m,0}_{\,u}\\&=R\p{\,m,0}_{\,t}\wt F(t)-\int_0\p t J_{m-1}^{\al_{1:m-1}}(F_{\otimes_{m-1}})_{u-}\wt F(u)F_{m}(u)\rmd \X{\al_m}_{\,u} \\&=R\p{\,m,0}_{\,t}\wt F(t)-J_{n}^{\al_{1:m}}(F_{\otimes_{m-1}}\otimes F_m\wt F)_{\,t}. \end{split} \end{equation} Therefore \begin{equation}\label{eq:det.part} \begin{split} \int_0\p t\int_0\p {s-}R\p{\,m,0}_{\,u-}K(u)&\rmd\aPP{\X{\dt}}{\X{\et}}_{\,u}H(s)\rmd \X{\gm}_{\,s}\\&= \int_0\p t R\p{\,m,0}_{\,s-}\wt F(s)H(s)\rmd \X{\gm}_{\,s}-J_{m+1}^{\al_{1:m},\gm}(F_{\otimes_{m-1}}\otimes F_m\wt F\otimes H)_{\,t} \\&=J_{m+1}^{\al_{1:m},\gm}(F_{\otimes_{m}}\otimes H\wt F)_{\,t}-J_{m+1}^{\al_{1:m},\gm}(F_{\otimes_{m-1}}\otimes F_m\wt F\otimes H)_{\,t}, \end{split} \end{equation} which again belongs to $\bigoplus_{k=0}\p{m+1} \scr J_{k}$ and this proves the basis of the induction. Now we assume that \[ M_t:=\int_0\p tR\p{\,m,j}_{\,u-}H(u)\rmd \X{\gm}_{\,u},\qquad N_t:=\int_0\p t\int_0\p {s-}R\p{\,m,j}_{\,u-}K(u)\rmd\aPP{\X{\dt}}{\X{\et}}_{\,u}H(s)\rmd \X{\gm}_{\,s} \] belong to $\bigoplus_{k=0}\p{m+j+1} \scr J_{k} $, for every $j\leq n$, every $m$, every $H,K \in \Bb_T$ and every $\gm,\dt,\et\in\Lm$ and prove the statement for $n+1$. By integration by parts we have \begin{align} R_t\p{\,m,n+1}&=\int_0\p t R\p{\,m-1,n+1}_{u-}F_m(u)\rmd\X{\al_m}_{u}+\int_0\p t R\p{\,m,n}_{u-}G_{n+1}(u)\rmd\X{\bt_{n+1}}_{u} \nonumber\\&\nonumber\qquad+ \int_0\p t R\p{\,m-1,n}_{u-}F_m(u)G_{n+1}(u)\rmd[\X{\al_m},\X{\bt_{n+1}}]_{u} \\&= \label{eq:term0}\int_0\p t R\p{\,m-1,n+1}_{u-}F_m(u)\rmd\X{\al_m}_{u} \\&\label{eq:term1}\qquad+ \int_0\p t R\p{\,m,n}_{u-}G_{n+1}(u)\rmd\X{\bt_{n+1}}_{u} \\&\label{eq:term2}\qquad+ \int_0\p t R\p{\,m-1,n}_{u-}F_m(u)G_{n+1}(u)\rmd\X{\al_m,\bt_{n+1}}_{u} \\&\label{eq:term3}\qquad+ \int_0\p t R\p{\,m-1,n}_{u-}F_m(u)G_{n+1}(u)\rmd\aPP{\X{\al_m}}{\X{\bt_{n+1}}}_{u}\,, \end{align} where in \eqref{eq:term2} the compensated-covariation of $\X{\al_m}$ and $\X{\bt_{n+1}}$ appears. Because of the induction hypothesis, \eqref{eq:term1} belongs to $\bigoplus_{k=0}\p{m+n+1}\scr J_{k}$. Therefore, $\int_0\p \cdot\eqref{eq:term1}_{s-}H(s)\rmd\X{\gm}_{s}$ belongs to $\bigoplus_{k=0}\p{m+n+2}\scr J_{k}$. We now discuss \eqref{eq:term2}. The family $\Xscr$ is compensated covariation stable. Therefore, the process $\X{\al_m,\bt_{m+1}}$ belongs to $\Xscr$. Obviously $F_mG_{n+1}\in \Bb_T$. Hence, by the induction hypothesis, \eqref{eq:term2} belongs to $\bigoplus_{k=0}\p{m+n}\scr J_{k}$ and therefore $\int_0\p \cdot\eqref{eq:term2}_{s-}H(s)\rmd\X{\gm}_{s}$ belongs to $\bigoplus_{k=0}\p{m+n+1}\scr J_{k}\subseteq\bigoplus_{k=0}\p{m+n+2}\scr J_{k}$. From the induction hypothesis, it also immediately follows that $\int_0\p \cdot\eqref{eq:term3}_{s-}H(s)\rmd\X{\gm}_{s}$ belongs to $\bigoplus_{k=0}\p{m+n}\scr J_{k}\subseteq\bigoplus_{k=0}\p{m+n+2}\scr J_{k}$. We now show that $\int_0\p\cdot\eqref{eq:term0}_{s-}H(s)\rmd \X{\gm}_s$ belongs to $\bigoplus_{k=0}\p{m+n+2}\scr J_{k}$. For this it suffices to verify that \eqref{eq:term0} belongs to $\bigoplus_{k=0}\p{m+n+1}\scr J_{k}$. By integration by parts applied to $R\p{\,m-1,n+1}=J_{m-1}^{\al_{1:m-1}}(F_{\otimes_{m-1}})J_{n+1}^{\bt_{1:n+1}}(G_{\otimes_{n+1}})$ we get \begin{align} \nonumber\int_0\p t R\p{\,m-1,n+1}_{u-}F_m(u)\rmd\X{\al_m}_{u} =& \int_0\p t\int_0\p{s-} R\p{\,m-2,n+1}_{u-}F_{m-1}(u)\rmd\X{\al_{m-1}}_{u}F_m(s)\rmd\X{\al_m}_{s} \\&+\nonumber \int_0\p t\int_0\p{s-} R\p{\,m-1,n}_{u-}G_{n+1}(u)\rmd\X{\bt_{n+1}}_{u}F_m(s)\rmd\X{\al_m}_{s} \\&+\nonumber \int_0\p t\int_0\p{s-} R\p{\,m-2,n}_{u-}F_{m-1}(u)G_{n+1}(u)\rmd\X{\al_{m-1},\bt_{n+1}}_{u}F_m(s)\rmd\X{\al_m}_{s} \\&+\nonumber \int_0\p t\int_0\p{s-} R\p{\,m-2,n}_{u-}F_{m-1}(u)G_{n+1}(u)\rmd\aPP{\X{\al_{m-1}}}{\X{\bt_{n+1}}}_{u}F_m(s)\rmd\X{\al_m}_{s}\,. \end{align} In other words, because of the induction hypothesis, we can rewrite this expression as \[ \int_0\p t R\p{\,m-1,n+1}_{u-}F_m(u)\rmd\X{\al_m}_{u}=\int_0\p t\int_0\p{s-} R\p{\,m-2,n+1}_{u-}F_{m-1}(u)\rmd\X{\al_{m-1}}_{u}F_m(s)\rmd\X{\al_m}_{s}+V_t \] where $V\in\bigoplus_{k=0}\p{m+n+1}\scr J_{k}$. Iterating this procedure $m-1$ times, we get \[ \begin{split} &\int_0\p t R\p{\,m-1,n+1}_{u-}F_m(u)\rmd\X{\al_m}_{u}=\\&U_t+\int_0\p t\int_0\p{t_{m-1}-}\cdots\int_0\p{t_2-} J_{n+1}^{\bt_{1:n+1}}( G_{\otimes_{n+1}} )_{t_1-}\;F_{1}(t_1)\rmd\X{\al_{1}}_{t_1}\ldots F_{m-1}(t_{m-1})\rmd\X{\al_{m-1}}_{t_{m-1}} F_m(t_{m})\rmd\X{\al_m}_{t_{m}}, \end{split}\] where $U\in\bigoplus_{k=0}\p{m+n+1}\scr J_{k}$. Using the definition of the elementary iterated integral, we get \[ \int_0\p t R\p{\,m-1,n+1}_{u-}F_m(u)\rmd\X{\al_m}_{u}=J_{n+m+1}^{\bt_{1:n+1},\al_{1:m}}(G_{\otimes_{n+1}}\otimes F_{\otimes_{m}})_t+U_t \] which belongs to $\bigoplus_{k=0}\p{m+n+1}\scr J_{k}$ and this completes the proof for $M$. To prove the statement for $N$ we have to verify that \[ N_t:=\int_0\p t\int_0\p {s-}R\p{\,m,n+1}_{\,u-}K(u)\rmd\aPP{\X{\dt}}{\X{\et}}_{\,u}H(s)\rmd \X{\gm}_{\,s} \] belongs to $\bigoplus_{k=0}\p{m+n+2}\scr J_{k}$, for every $m$, every $H,K \in \Bb_T$ and every $\gm,\dt,\et\in\Lm$. From the previous step, $\int_0\p\cdot R_{u-}\p{\,m,n+1}H(u)\rmd X\p\gm_{u}\in\bigoplus_{k=0}\p{m+n+2}\scr J_{k}$, for every $m$, every $H \in \Bb_T$ and every $\gm\in\Lm$. Hence, with similar computations as in \eqref{eq:det.part0} and \eqref{eq:det.part}, using the representation of $R\p{m,n+1}$ obtained in \eqref{eq:term0} -- \eqref{eq:term3}, we deduce the claim from the induction hypothesis. The proof of the lemma is complete. \end{proof} We can now prove that $\Jscr_\rme$ is compensated-covariation stable. \begin{theorem}\label{thm:com.cov.st.it.int} Let $\Xscr$ satisfy Assumption \ref{ass:det.com.cov}. Then the family $\Jscr_\rme$ of the elementary iterated integrals generated by $\Xscr$ is compensated-covariation stable and any $M\in\Jscr_\rme$ is quasi-left continuous. \end{theorem} \begin{proof} Let $M,N\in\Jscr_\rme$. By linearity we can assume without loss of generality that $ M=J_{m}^{\al_{1:m}}(F_{\otimes_{m}})$ and $ N=J_{n}^{\bt_{1:n}}(G_{\otimes_{n}})$. Because of \eqref{eq:def.sim.mul.int} we have \begin{equation}\label{eq:com.cov.it.int.2} \begin{split} [M,N]_t-\aPP{M}{N}_t&= [J_{m}^{\al_{1:m}}(F_{\otimes_{m}}),J_{n}^{\bt_{1:n}}(G_{\otimes_{n}})]_t - \aPP{J_{m}^{\al_{1:m}}(F_{\otimes_{m}})}{J_{n}^{ \bt_{1:n}}(G_{\otimes_{n}})}_t \\&= \int_0\p t J_{m-1}^{\al_{1:m-1}}(F_{\otimes_{m-1}})_{u-}J_{n-1}^{\bt_{1 :n-1}}(G_{\otimes_{n-1}})_{u-}F_{m}(u)G_{n}(u)\rmd\X{\al_m,\bt_n}_u\,. \end{split} \end{equation} Since by assumption $\Xscr$ is compensated-covariation stable, we have $\X{\al_m,\bt_n}\in\Xscr$. Hence, $F_{n}G_{m}$ being bounded, the compensated-covariation stability of $\Jscr_\rme$ immediately follows from Lemma \ref{lem:com.cov.it.int}. To see the quasi-left continuity of $M$ it is enough to observe that \begin{equation}\label{eq:pb.M} \aPP{M}{M}=\big(J_{m-1}^{\al_{1:m-1}}(F_{\otimes_{m-1}})_-F_m)\p 2\cdot\aPP{X\p{\al_m}}{X\p{\al_m}} \end{equation} and hence $\aPP{M}{M}$ is continuous by the continuity of $\aPP{X\p{\al_m}}{X\p{\al_m}}$. The quasi-left continuity of $M$ is a consequence of the last statement of \cite[Theorem I.4.2]{JS00}. The proof of the theorem is now complete. \end{proof} As a next step we study the $m$-fold compensated covariation process built from elements of $\Jscr_\rme$. For $J_{m}^{\al_{1:m}}(F_{\otimes_{m}}), \, J_{n}^{\bt_{1:n}}(G_{\otimes{n}}) \in\Jscr_\rme$ we denote by \begin{equation*} \mathbf J\p{\,\mathbf\al_{1:m},\mathbf\bt_{1:n}}_{m,n}( F_{\otimes_{m}}\otimes G_{\otimes{n}}):=[J_{m}^{\al_{1:m}}(F_{\otimes_m}),J_{n}^{ \bt_{1:n}}(G_{\otimes_n})]-\aPP{J_{m}^{\al_{1:m}}(F_{\otimes_m})}{J_{n}^{ \bt_{1:n}}(G_{\otimes_n})} \end{equation*} their compensated-covariation process. For any $j\in\Nbb$ we introduce the notation \[ F\p j_{\otimes_m}:=F_1\p{j}\otimes\cdots\otimes F_m\p{j}. \] Because of Theorem \ref{thm:com.cov.st.it.int}, for $j=1,\ldots,N$, $\al_{1:m_j}\p j\in\Lm\p{m_j}$ and $J_{m_j}\p{\al_{1:m_j}\p j}(F_{\otimes_{n_j}}\p j)\in\Jscr_\rme$, we can inductively define \begin{equation}\label{eq:com.cov.it.in} \begin{split} \mathbf J\p{\,\mathbf\al_{1:m_1}\p1,\cdots,\al\p{N}_{1:m_N}}_{m_1,\ldots,m_n}&( F\p{1}_{\otimes_{m_1}}\otimes\cdots\otimes F\p{N}_{\otimes{m_N}}):= \\& \Big[\mathbf J\p{\,\al_{1:m_1}\p1,\ldots,\al\p{n}_{1:m_N-1}}_{m_1,\ldots,m_{N}-1}( F\p{1}_{\otimes_{m_1}}\otimes\cdots\otimes F\p{{N-1}}_{\otimes_{m_N-1}}),J_{m_N}^{\al\p N_{1:m_N}}(F\p N_{\otimes_{m_N}})\Big] -\\&\qquad\qquad \Big\langle\mathbf J\p{\,\al_{1:m_1}\p1,\ldots,\al\p{n}_{1:m_n-1}}_{m_1,\ldots,m_{N}-1}( F\p{1}_{\otimes_{m_1}}\otimes\cdots\otimes F\p{{N-1}}_{\otimes_{m_N-1}}),J_{m_N}^{\al\p N_{1:m_N}}(F\p N_{\otimes_{m_N}})\Big\rangle\,. \end{split} \end{equation} \begin{proposition}\label{prop:com.cov.it.int.expr} Let $\Xscr$ satisfy Assumption \ref{ass:det.com.cov}. Then \begin{equation}\label{eq:rep.comcov.it.int} \mathbf J\p{\,\mathbf\al_{1:m_1}\p1,\ldots,\mathbf\al\p{N}_{1:m_N}}_{m_1,\ldots,m_N}(F\p{1}_{\otimes_{m_1}}\otimes\cdots\otimes F\p N_{\otimes_{m_N}})=\Bigg(\prod_{j=1}\p NJ_{m_j-1}^{\al\p j_{1:m_{j}-1}}( F\p j_{\otimes_{m_{j}-1}})_{-}F_{m_j}\p{j} \Bigg)\cdot\X{\al\p1_{m_1},\ldots,\al\p N_{m_N}}\,. \end{equation} \end{proposition} \begin{proof} For $N=2$ the statement coincides with \eqref{eq:com.cov.it.int.2}. Then, the formula immediately follows by induction from \eqref{eq:com.cov.it.in} and Theorem \ref{thm:com.cov.st.it.int}. \end{proof} Notice that the integrator appearing on the right-hand side of \eqref{eq:rep.comcov.it.int} is the $m$-fold compensated-covariation process of the ordered $m$-tuple of martingales $(\X{\al_{m_1}\p1},\ldots,\X{\al_{m_N}\p N} )$. \subsection{A product formula for elementary iterated integrals} We now exploit \eqref{eq:rep.pol} for elementary iterated integrals generated by a compensated-covariation stable family of martingales. Observe that to prove Proposition \ref{prop:rep.pol} for a family of martingales $\Xscr=\{X\p\al,\ \al\in\Lm\}$, it is not needed that the predictable covariation $\aPP{X\p{\al_1}}{X\p{\al_2}}$ is deterministic but it is sufficient that the family $\Xscr$ is compensated-covariation stable and consists of quasi-left continuous martingales. This is important because for $X,Y\in\Jscr_\rme$, the process $\aPP{X}{Y}$ is continuous but not deterministic, in general (cf.\ \eqref{eq:pb.M}). \begin{theorem}\label{thm:prod.for.it.int} Let $\Xscr$ satisfy Assumption \ref{ass:det.com.cov}. Then, for $J_{m_j}^{\al\p{ j}_{1:m_j}}(F\p j_{\otimes_{m_j}}) \in\Jscr_\rme$, $j=1,\ldots,N$, $N\geq2$, we have \begin{equation}\label{eq:prod.for.it.int} \begin{split} &\prod_{j=1}\p NJ_{m_j}^{\al\p j_{1:m_j}}(F\p j_{\otimes_{m_j}})\\&=\quad \sum_{i=1}\p N\sum_{{1\leq j_1<\ldots<j_i\leq N}}\bigg(\prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N J_{m_k}^{\al\p k_{1:m_k}}(F\p k_{\otimes_{m_k}})_-\prod_{\ell=1}\p i J\p{\al\p {j_\ell}_{1:{m_{j_\ell}-1}}}_{{m_{j_\ell}-1}}( F\p{j_\ell}_{\otimes{m_{j_\ell}-1}})_-F_{m_{j_\ell}}\p{j_\ell}\bigg)\cdot X\p{\al_{m_{j_1}}\p{{j_1}},\ldots,\al\p{{j_i}}_{m_{j_i}}} \\&\quad+ \sum_{i=2}\p N\sum_{{1\leq j_1<\ldots<j_i\leq N}}\bigg(\prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N J_{m_k}^{\al\p k_{1:{m_k}}}( F\p k_{\otimes_{m_k}})_-\prod_{\ell=1}\p i J\p{\al\p {j_\ell}_{1:{m_{j_\ell}-1}}}_{{m_{j_\ell}-1}}(F\p{j_\ell}_{\otimes_{m_{j_\ell}-1}})_-F_{m_{j_\ell}} \p{j_\ell}\bigg)\cdot\aPP{X\p{\al_{m_{j_1}}\p{{j_1}},\ldots,\al\p{{j_{i-1}}}_{m_{j_{i-1}}}}}{X\p{\al\p{{j_i}}_{m_{j_i}}}}\,. \end{split} \end{equation} \end{theorem} \begin{proof} We have $\Jscr_\rme \subseteq\Hscr\p2$. Moreover, from Theorem \ref{thm:com.cov.st.it.int}, $M\in\Jscr_\rme$ is quasi-left continuous and $\Jscr_\rme$ is compensated-covariation stable. So we can introduce the compensated-covariation processes \eqref{eq:com.cov.it.in} and by Proposition \ref{prop:rep.pol} \[ \begin{split} \prod_{j=1}\p N &J_{m_j}^{\al\p j_{1:m_j}}(F\p j_{\otimes_{m_j}})=\\& \sum_{i=1}\p N\sum_{{1\leq j_1<\ldots<j_i\leq N}}\bigg(\prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N J_{m_k}^{\al\p k_{1:{m_k}}}\big(F\p k_{\otimes_{m_k}}\big)_-\bigg) \cdot\mathbf J\p{\al_{1:m_{j_1}}\p{j_1},\ldots,\mathbf\al\p{j_i}_{1:m_{j_i}}}_{m_{j_1},\ldots,m_{j_i}}\big(F_{\otimes_{m_{j_1}}}\p{j_1}\otimes\cdots\otimes F\p{j_i}_{\otimes_{m_{j_i}}}\big) \\&+ \sum_{i=2}\p N\sum_{{1\leq j_1<\ldots<j_i\leq N}}\bigg(\prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N J_{m_k}^{\al\p k_{1:{m_k}}}\big(F\p k_{\otimes_{m_k}}\big)_-\bigg)\cdot \\& \hspace{4cm}\cdot\bigg\langle\mathbf J\p{\al_{1:m_{j_1}}\p{j_1},\ldots,\al\p{j_{i-1}}_{1:m_{j_{i-1}}}}_{m_{j_1},\ldots,m_{j_{i-1}}}\big(F_{\otimes{m_{j_1}}}\p{j_1}\otimes\cdots\otimes F\p{j_{i-1}}_{\otimes_{m_{j_{i-1}}}}\big),J_{m_{j_i}}^{\al\p {j_i}_{1:{m_{j_i}}}}\big(F\p {j_i}_{\otimes_{m_{j_i}}}\big)\Big\rangle\,. \end{split} \] The statement follows from Proposition \ref{prop:com.cov.it.int.expr}. \end{proof} In the next step we obtain a recursive formula for computing moments of products from $\Jscr_\rme$. To ensure their existence we make the following assumption: \begin{assumption}\label{ass:mom.mart} Each martingale in $\Xscr$ has finite moments of every order. \end{assumption} Let $\Xscr$ satisfy Assumption \ref{ass:det.com.cov}. We observe that then, according to \cite[Corollary 4.5]{DTE16}, $\Xscr$ fulfils Assumption \ref{ass:mom.mart} if there exists $\bt\in\Lm$ such that $\aPP{\X{\bt}}{\X{\bt}}_t<\aPP{\X{\bt}}{\X{\bt}}_T$, $t<T$. Before we come to the moment formula we need the following technical result. For the proof see \cite[Lemma 5.5]{DTE16}. \begin{lemma}\label{lem:int.prod.X} Let $\Xscr:=\{X\p{\al},\ \al\in \Lm\} \subseteq\Hscr\p{\,2}$ satisfy Assumption \ref{ass:mom.mart} and let $A$ be a deterministic process of finite variation. We define the process $K$ by \begin{equation*} K:=\prod_{i=1}\p NX\p{\al_i}_{-},\quad \al_i\in \Lm,\quad i=1,\ldots,N. \end{equation*} Then the process $K\cdot A$ is of integrable variation. \end{lemma} Let $A$ and $K$ be as in Lemma \ref{lem:int.prod.X}. Then by $\Ebb[K]\cdot A$ we denote the integral with respect to $A$ of the $A$-integrable function $t\mapsto\Ebb[K_t]$. Now we are ready to state and prove a recursive moment formula for products of elementary iterated integrals. \begin{corollary}\label{cor:mom.it.int} Let $\Xscr$ satisfy Assumptions \ref{ass:det.com.cov} and \ref{ass:mom.mart}. Then, for $J_{m_j}^{\al\p{ j}_{1:m_j}}(F\p j_{\otimes_{m_j}}) \in\Jscr_\rme$, $j=1,\ldots,N$, $N\geq2$, the following formula holds: \begin{equation}\label{eq:mom.it.int} \begin{split} &\Ebb\Bigg[\prod_{j=1}\p NJ_{m_j}^{\al\p j_{1:{m_j}}}(F\p j_{\otimes_{m_j}})\Bigg]= \\& \quad\sum_{i=2}\p N\sum_{{1\leq j_1<\ldots<j_i\leq N}}\Ebb\left[\prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N J_{m_k}^{\al\p k_{1:{m_k}}}(F\p k_{\otimes_{m_k}})_-\prod_{\ell=1}\p i J\p{\al\p {j_\ell}_{1:{m_{j_\ell-1}}}}_{{m_{j_\ell-1}}} (F\p{j_\ell}_{\otimes_{{m_{j_\ell}-1}}})_-F_{m_{j_\ell}}\p{j_\ell}\right]\cdot \aPP{X\p{\al_{m_{j_1}}\p{{j_1}},\ldots,\al\p{{j_{i-1}}}_{m_{j_{i-1}}}}}{\X{\al\p{{j_i}}_{m_{j_i}}}}. \end{split} \end{equation} \end{corollary} \begin{proof} Because of Lemma \ref{lem:mom.it.int}, if $\Xscr$ satisfies Assumption \ref{ass:mom.mart}, the family $\Jscr_\rme$ of elementary iterated integrals also does. Therefore the left-hand side of \eqref{eq:prod.for.it.int} is integrable. Furthermore, because $\aPP{\X{\al}}{\X{\al}}$ is deterministic, for every $\al \in\Lm$, we conclude by Lemma \ref{lem:int.prod.X} that the integrands of the stochastic integrals in the first term on the right hand side of \eqref{eq:prod.for.it.int} belong to $\Lrm\p2(\X{\al})$, for every $\al\in\Lm$. Therefore each summand in the first term on the right-hand side of \eqref{eq:prod.for.it.int} belongs to $\Hscr\p2$. Analogously, we have by Lemma \ref{lem:int.prod.X} and Assumption \ref{ass:det.com.cov} that the second term on the right-hand side of \eqref{eq:prod.for.it.int} is integrable. We can therefore consider the expectation and apply the theorem of Fubini to conclude the proof. \end{proof} Notice that by taking $m_j=1$ and $F_1\p j=1$, $j=1,\ldots,N$ in \eqref{eq:mom.it.int} one can \emph{recursively} compute expressions like $ \Ebb[\prod_{j=1}\p N X\p{\al_j}]$. Indeed, in this special case, the second product on the right-hand side of \eqref{eq:mom.it.int} is identically equal to one, while the first product consists of a number of factors which is strictly smaller than $N$. For example, if $X$ is a Brownian motion, \eqref{eq:mom.it.int} corresponds to taking the expectation in \eqref{eq:prod.for.one.mart.bm} and we get $\Ebb[X\p {2N+1}_t]=0$, $N\geq0$, and \[ \Ebb[X_t\p {2N}]=(2N-1)!!(\sqrt{t})\p{2N},\quad N\geq2, \] where $N!!$ denotes the \emph{double factorial} of $N$. If $X$ is a compensated Poisson process with parameter $\lm$, then by taking the expectation in \eqref{eq:prod.for.one.mart.poi.pr} (or by simplifying \eqref{eq:mom.it.int}) we obtain \[ \Ebb[X_t\p N]=\lm \sum_{i=2}\p N\binom{N}{i} \int_0\p t\Ebb[(X_{s})]\p {N-i}\rmd s \] which is the formula in \cite[Proposition 3.3.4 and Example 3.3.5]{PT11}. The resulting polynomials \[\begin{split} &\Ebb[X_t\p2]=\lm t,\quad \Ebb[X_t\p3]=\lm t ,\quad \Ebb[X_t\p4]=3\lm\p2 t\p2+\lm t,\quad \Ebb[X_t\p5]=10\lm\p2 t\p2+\lm t\ldots, \end{split} \] also called \emph{centred Touchard polynomials}. If, more generally, $X$ is a L\'evy process (see Subsection \ref{subs:exa}) with finite moments of every order, we derive from Corollary \ref{cor:mom.it.int} the \emph{recursive} formula \eqref{thm:mom.lev} below for the central moments of $X$. This formula allows to compute the moments of a L\'evy process recursively without taking derivatives of its characteristic function. \begin{theorem}\label{thm:mom.lev} Let $X$ be a L\'evy process with characteristic triplet $(\gm,\sig\p2,\nu)$, such that $X$ has finite moments of every order. Let us define the centred process $X\p{(1)}$ by $X\p{(1)}_t:=X_t-\Ebb[X_t]$. Then, for every $N\geq1$, we have \begin{equation} \label{eq:mom.lev.cen} \Ebb[(X\p{(1)}_t)\p N]=\sum_{i=2}\p N \binom{N}{i} (\nu(p_{i})+\sig\p21_{\{i=2\}}) \int_0^t \Ebb[(X\p{(1)}_{s-})\p {N-i}]\rmd s. \end{equation} Consequently, for $N\geq1$, the non-central moments of $X$ are given by \begin{equation}\label{eq:mom.lev.ncen} \begin{split} \Ebb[X\p N_t] =\sum_{i=1}\p N\binom{i}{k}\big((\gm+\nu(1_{\{|p_1|>1\}}))t\big)\p{N-i}\sum_{k=1}\p i \binom{i}{k}(\nu(p_{k})+\sig\p21_{\{k=2\}}) \int_0^t \Ebb[(X\p{(1)}_{s-})\p {i-k}]\rmd s. \end{split} \end{equation} \end{theorem} \begin{proof} The family $\Xscr:=\{X\p{(i)}, \, i\geq1\}$ defined by \eqref{eq:teu.mar} is compensated-covariation stable, consists of quasi-left continuous martingales and is such that $\aPP{X\p{(i)}}{X\p{(j)}}$ is deterministic. Hence, $\Xscr$ satisfies Assumptions \ref{ass:det.com.cov}. Furthermore, because of the last paragraph in Subsection \ref{subs:exa}, $\Xscr$ satisfies also Assumption \ref{ass:mom.mart}. Hence, from the identity $(X\p{(1)}_t)\p N=\prod_{j=1}\p N J_1\p{1}(1)_t$, it follows that \eqref{eq:mom.lev.cen} is a special case of Corollary \eqref{cor:mom.it.int}. To see \eqref{eq:mom.lev.ncen}, we observe that the identity $X_t=X\p{(1)}_t+\Ebb[X_t]$ holds. Thus, $ \Ebb[X\p N]=\sum_{i=1}\p N \binom{N}{i}\Ebb[(X\p{(1)}_t)\p i]\Ebb[X_t]\p{N-i} $ and \eqref{eq:mom.lev.ncen} immediately follows from \eqref{eq:mom.lev.cen} because of \eqref{eq:mom.Li}. The proof is complete. \end{proof} \section{Iterated integrals with respect to L\'evy processes}\label{sec:Lev.pr} In this section $X$ is a L\'evy process with characteristic triplet $(\gm,\sig\p2,\nu),$ and we denote by $N$ the jump measure of $X$ and by $\tilde N:=N-\nu\otimes\lm_+$ the compensated Poisson random measure. For $\al\in L\p2(\nu)$ and $t\geq0$ we use the notation $$ 1_{ [0, t]}\al \ast \tilde N:=\int_{[0,t]\times \Rbb } \al(x)\tilde N(\rmd s,\rmd x). $$ We set $\mu := \sigma^2 \delta_0 + \nu$, where $\delta_0$ is the Dirac measure concentrated in zero. For $ \al \in L\p2(\mu)$, we define \equal \label{poisson-integral} X\p\al:=\al(0) W^\sigma +(1_{ [0, \cdot]\times (\Rbb \setminus \{ 0\}) }\al) \ast \tilde N. \tionl We recall that, if $\al\in L\p2(\mu)$, then the process $X\p\al$ has the following properties: \bigskip (i) $(X^\al,\Fbb)$ is a L\'evy process with characteristic triplet $(-\int_{\{|x|>1\}} \al(x) \nu(dx), \al(0)^2\sigma^2, \nu \circ \al^{-1} )$. (ii) $X^\al\in\Hscr\p2(\Fbb)$ and $\aPP{X\p\al}{X\p\al}_t=t\mu(\al\p2)$. (iii) $\Delta X^\al=\al(\Delta X)1_{\{\Delta X\neq0\}} $ and hence $\Delta X^\al$ is bounded, if $\al$ is bounded. (iv) Let $\bt\in L\p2(\mu)$. Then $\aPP{X\p\al}{X\p\bt}=0$ if and only if $\mu(\al\bt)=0$. \bigskip For a system $\Lm \subseteq L\p2(\mu)$, we put \equal \label{X-lambda} \Xscr_\Lm:=\{X\p \al,\,\, \al\in \Lm\}. \tionl \begin{assumption}\label{ass:good.sys} Let $\Lm$ be a set of real-valued functions with the following properties: \\ (i) $\Lm\subseteq L\p{\,1}(\mu)\cap L\p{\,2}(\mu)$; \\ (ii) $\Lm$ is total in $L\p{\,2}(\mu)$; \\ (iii) $\Lm$ is stable under multiplication, and $1_{\Rbb\setminus\{0\}}\al\in\Lm$ whenever $\al\in\Lm$; \\ (iv) $\Lm$ is a system of bounded functions. \end{assumption} We observe that a system $\Lm$ satisfying Assumption \ref{ass:good.sys} always exists: Obviously, we can choose $\Lm:=\{\al=c1_{\{0\}}+1_{(a,\,b]},\ a,b\in\Rbb:a<b,\ 0\notin[a,b];\ c\in\Rbb\}\cup\{0\}$ as an example. \begin{proposition} Let $\Lm$ satisfy Assumption \ref{ass:good.sys}. Then $\Xscr_\Lm \subseteq \Hscr\p{\,2}(\Fbb)$. For $\al_1,\ldots,\al_m \in \Lm$ the compensated-covariation process $X^{\al_{1:m}}$, $m\ge 2$, has the following form: \equal \label{co-co stable processes} X^{\al_{1:m}} = \Bigl (1_{[0, \cdot]\times(\Rbb \setminus \{ 0\})} \prod_{k=1}^m\al_k \Bigr ) \ast \tilde N. \tionl Moreover, \\ {\rm(i)} $\Fbb\p{\Xscr_\Lm}=\Fbb\p X$;\\ {\rm(ii)} $\Ebb[\exp(\lm|X_{\,t}|)]<+\infty$ for every $X\in\Xscr_\Lm$, $\lm>0$, $t\in[0,T]$, \\ {\rm (iii)} $\pb XY$ is deterministic for every $X,Y\in\Xscr_\Lm$, \\ {\rm (iv)} $\Xscr_\Lm$ possesses the CRP with respect to $\Fbb\p X$. \end{proposition} \begin{proof} For the ``Moreover'' part we refer to \cite[Proposition 6.4 and Proposition 6.5]{DTE16}. To show \eqref{co-co stable processes}, we notice that $$ [X^{\al_1}, X^{\al_2}]_t= \al_1(0) \al_2(0) \sigma^2 t + \int_{[0, t]\times\Rbb \setminus \{ 0\}} \al_1(x)\al_2(x)\,N(\rmd s,\rmd x) $$ and $$ \langle X^{\al_1}, X^{\al_2}\rangle_t= \al_1(0)\al_2(0) \sigma^2 t + \nu ( \al_1\al_2 )t. $$ Then, since $\al_1\al_2\in L\p1(\mu)\cap L\p2(\mu)$, we get $ X^{\al_{1:2}} = \Bigl (1_{[0, \cdot]\times(\Rbb \setminus \{ 0\})} \al_1\al_2 \Bigr ) \ast \tilde N , $ and \eqref{co-co stable processes} follows from \eqref{eq:it.com.cov} by induction. \end{proof} \subsection{Products of elementary iterated integrals} The aim of this subsection is to deduce a \emph{product formula} for elements from $\Jscr_\rme$, where we assume that $\Jscr_\rme$ is generated by $\Xscr_\Lm$ and $\Lm\subseteq L\p2(\mu)$ satisfies Assumption \ref{ass:good.sys}. By Definition \ref{elem.it.int.}, an elementary iterated integral generated by the martingales $ X\p{\al_1},\ldots,X\p{\al_m}$, $ {\al_1},\ldots,{\al_m}\in\Lm$, is given by \begin{equation*} J_{m}\p{\al_1,\ldots, \al_{m}}(F_{\otimes_m})_{\,t} :=\int_0^t J_{m-1}^{\al_1,\ldots, \al_{m-1}}( F_{\otimes_{m-1}})_{u-}\,F_{m}(u)\, \rmd {\X{\al_{m}}_u},\qquad t\in [0,T], \quad m\geq 1\,. \end{equation*} Our aim is to determine a product formula for \[ \prod_{j=1}^N J_{m_j}\p{\al_1\p j,\ldots, \al_{m_j}\p j}(F_{\otimes_{m_j}}\p j),\quad N\in\Nbb, \] (given in equation \eqref{product-rule} below) by iterating formula \eqref{eq:prod.for.it.int} until the inner elementary iterated integrals appearing as integrands will reduce to deterministic functions. In this way it will be also possible to determine a formula for the moment of products of elementary iterated integrals which generalizes the isometry relation \eqref{eq:IRmix.el}. For this goal we need to introduce some combinatoric rules and notations. First of all we fix $N$, that is, the number of factors of the product, and then we fix $m_1,\ldots,m_N$, that is, the order of each factor. We then order all the functions $F_{k}\p j \in \Bb_T$, $k=1,\ldots,m_j$, $j=1,\dots,N$, consecutively: Set \equa \overline m_0&:=&0, \\ \overline m_j&:=&m_1+\ldots+m_j, \quad j =1,\dots, N. \tion We then define \[ (F_{\overline m_{j-1}+1},\ldots,F_{\overline m_j}):= (F_{1}\p j,\ldots,F_{m_j}\p j),\quad j=1,\ldots,N, \] and set \[ F_{\otimes_{\overline m_{j-1}+1:\overline m_j}}:=F_{\overline m_{j-1}+1}\otimes\cdots\otimes F_{\overline m_j},\quad j=1,\ldots,N. \] Analogously, we define \[ (\al_{\overline m_{j-1}+1},\ldots,\al_{\overline m_j}):= (\al_{1}\p j,\ldots,\al_{m_j}\p j),\quad j=1,\ldots,N. \] Like in \eqref{product-rho}, we put $ \rho\p{\al_{\overline m_{j-1}+1:\overline m_j}} := \rho\p{\al_{\overline m_{j-1}+1}}\otimes \ldots \otimes \rho\p{\al_{\overline m_j}}$, where \[ \rmd\rho\p{\al_{\overline m_{j-1}+1}:\overline m_j} (t_1,\ldots,t_{m_j})=\bigg(\prod_{i=\overline m_{j-1}+1}\p{\overline m_j} \nu\big(\al_i\p2\big)\bigg)\rmd\lm( t_1,\ldots,t_{m_j}). \] With this notation we get: \equal \label{index-renaming} \prod_{j=1}^N J_{m_j}\p{\al_1\p j,\ldots, \al_{m_j}\p j}(F_{\otimes_{m_j}}\p j) = \prod_{j=1}^N J_{m_j}\p{\al_{\overline m_{j-1}+1:\overline m_j}}(F_{\otimes_{\overline m_{j-1}+1:\overline m_j}}). \tionl Notice that a stochastic integral with respect to $X^\al$ is in fact the sum of a stochastic integral with respect to $ \al(0)W^\sigma$ and one with respect to $(1_{[0, \cdot]\times(\Rbb \setminus \{ 0\})}\al) \ast \tilde N$. For convenience we shall write these two integrals instead of the integral with respect to $X^\al$ to recognize whether we are integrating with respect to the Brownian part or with respect to the jump part. To this aim, let $B \subseteq \{1,2,\ldots, \overline m_N\}$ denote the set of indices for which we integrate with respect to the Brownian part of $X^{\al_k}$, $k=1,\ldots,\overline m_N$. We define $$\al^B_k:= \left \{ \begin{array}{ll} \al_k 1_{\{0\}} & \text{ if } k \in B, \\ \al_k 1_{\Rbb \setminus \{ 0\}} &\text{ if } k \notin B. \end{array} \right .$$ Then \begin{equation}\label{eq:trans.prod.bm.int} \prod_{j=1}^N J_{m_j}\p{\al_{\overline m_{j-1}+1:\overline m_j}}(F_{\otimes_{\overline m_{j-1}+1:\overline m_j}})=\sum_{B \subseteq \{1,2,\ldots, \overline m_N\}} \prod_{j=1}^N J_{m_j}\p{\al^B_{\overline m_{j-1}+1:\overline m_j}}(F_{\otimes_{\overline m_{j-1}+1:\overline m_j}}), \end{equation} which implies that, to obtain the multiplication formula, it suffices to transform the product on the right-hand side of \eqref{eq:trans.prod.bm.int} into a sum of iterated integrals, for any $B \subseteq \{1,2,\ldots, \overline m_N\}$. We observe that the extreme cases $B=\{1,2,\ldots, \overline m_N\}$ and $B=\emptyset$ correspond to the case of integration with respect to the Brownian part only and with respect to the jump part only, respectively. Let us consider, as an illustrating example, the case $N=2$, $m_1=m_2=1$. Here we have $B \in \{\emptyset,\{1\},\{2\},\{1,2\}\}$ and \begin{gather*} \al\p{\{1\}}_1=\al_11_{\{0\}},\quad\al \p{\{1\}}_2=\al_21_{\Rbb\setminus\{0\}},\quad\al\p{\{2\}}_1=\al_11_{\Rbb\setminus\{0\}},\quad \al\p{\{2\}}_2=\al_21_{\{0\}},\\\\ \al\p{\{1,2\}}_1=\al_11_{\{0\}},\quad \al\p{\{1,2\}}_2=\al_21_{\{0\}},\quad \al\p{\{\emptyset\}}_1=\al_11_{\Rbb\setminus\{0\}},\quad \al\p{\{\emptyset\}}_2=\al_21_{\Rbb\setminus\{0\}}. \end{gather*} Notice that \eqref{eq:prod.for.it.int} holds also for $\prod_{j=1}^N J_{m_j}^{\al^B_{\overline m_{j-1}+1: \overline m_j}}(F_{\otimes_{\overline m_{j-1}+1: \overline m_j}})$ and reads as \begin{equation}\label{levy-product} \begin{split} &\prod_{j=1}^N J_{m_j}^{\al^B_{\overline m_{j-1}+1: \overline m_j}}(F_{\otimes_{\overline m_{j-1}+1: \overline m_j}})\\ &\quad=\sum_{r=1}\p N\sum_{{1\leq j_1<\ldots<j_r\leq N}}\Bigg\{\Bigg( \prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N J_{m_k}^{\al^B_{\overline m_{k-1}+1: \overline m_k}}(F_{\otimes_{\overline m_{k-1}+1: \overline m_k}})_- \Bigg ) \\ &\quad\quad\times \Bigg ( \prod_{\ell=1}\p r J_{m_{j_\ell-1}}^{\al^B_{ \overline m_{j_{\ell-1}} +1: \overline m_{j_\ell-1}}} (F_{\otimes_{\overline m_{j_\ell-1}+1: \overline m_{j_{\ell}-1}}})_- \Bigg ) \Bigg ( \prod_{q=1}\p r F_{\overline m_{j_q}} \Bigg ) \Bigg\}\cdot\X{ \al^B_{\overline m_{j_1}},\ldots,\al^B_{\overline m_{j_r}}}\\ &\quad\quad\quad\quad\quad+ \sum_{r=2}\p N\sum_{{1\leq j_1<\ldots<j_r\leq N}}\Bigg\{ \Bigg( \prod_{\begin{subarray}{c}k=1\\k\neq j_1,\ldots,j_i\end{subarray}}\p N J_{m_k}^{\al^B_{\overline m_{k-1}+1: \overline m_k}}( F_{\otimes_{\overline m_{k-1}+1: \overline m_k}})_-\Bigg )\\ &\quad\quad \times \Bigg( \prod_{\ell=1}\p r J_{m_{j_\ell-1}}^{\al^B_{ \overline m_{j_{\ell-1}} +1: \overline m_{j_\ell-1}}} (F_{\otimes_{\overline m_{j_\ell-1}+1: \overline m_{j_{\ell}-1}}})_-\Bigg ) \Bigg( \prod_{q=1}\p r F_{\overline m_{j_q}} \Bigg ) \Bigg\}\cdot\aPP{\X{\al^B_{\overline m_{j_1}},\ldots, \al^B_{\overline m_{j_{r-1}}} }}{\X{\al^B_{\overline m_{j_r}}}}\,. \end{split} \end{equation} We observe that the integrands on the right-hand of \eqref{levy-product} consist of products of elementary iterated integrals. These elementary iterated integrals are either of the same order $m_k$ as the ones appearing in the product on the left-hand side of \eqref{levy-product} or of the diminished order $m_{j_\ell-1}$. We will repeatedly apply \eqref{levy-product} to the { \it integrands} on the right-hand side of \eqref{levy-product} until we get integrands that consist of iterated integrals of order zero, that is, they are equal to one. \bigskip \\ {\bf The integrators in \eqref{levy-product}.} In order to determine the exact structure of the outcome of the procedure explained above, we want to specify which integrators $\rmd \X{ \al^B_{\overline m_{j_1}},\ldots,\al^B_{\overline m_{j_r}}}$ can occur in \eqref{levy-product}. If $r=1$, we have \equa \begin{array}{lll} \X{ \al^B_{\overline m_{j_1}}}&= \al_{\overline m_{j_1}}(0) W^\sigma, \quad & \text{ if }\quad \overline m_{j_1} \in B, \\ \X{ \al^B_{\overline m_{j_1}}}&= (1_{\Rbb \setminus \{ 0\}}1_{[0, \cdot]}\al_{\overline m_{j_1}}) \ast \tilde N, \quad & \text{ if }\quad \overline m_{j_1}\in B^c =\{1,2,\ldots,\overline m_N\} \setminus B .\end{array} \tion From \eqref{co-co stable processes} we conclude that for $r \ge 2$ $$\N{ \al^B_{\overline m_{j_1}},\ldots,\al^B_{\overline m_{j_r}}}= \N{1_{\Rbb \setminus\{0\}}\prod_{k=1}^r \al_{\overline m_{j_k}} } = \left \{ \begin{array}{ll} \Bigl (1_{[0, \cdot]\times(\Rbb \setminus \{ 0\})} \prod_{k=1}^r \al_{\overline m_{j_k} } \Bigr ) \ast \tilde N, & \text{ if }\quad \{ \overline m_{j_1},\ldots,\overline m_{j_r} \} \subseteq B^c, \\ &\\ 0, &\text{ otherwise.} \end{array} \right . $$ Furthermore, it holds $$\aPP{\N{\al^B_{\overline m_{j_1}} }}{\X{\al^B_{\overline m_{j_2}}}}_t= t \, \mu( \al^B_{\overline m_{j_1}}\al^B_{\overline m_{j_2}}) = \left \{ \begin{array}{ll} t \,\nu ( \al_{\overline m_{j_1}}\al_{\overline m_{j_2}} ), &\text{ if } \{\overline m_{j_1}, \overline m_{j_2} \} \subseteq B^c, \\\\ t \sigma^2 \al_{\overline m_{j_1}}\!\!(0) \, \al_{\overline m_{j_2}}\!\!(0), &\text{ if } \{\overline m_{j_1}, \overline m_{j_2} \} \subseteq B, \\\\ 0, & \text{ otherwise, } \end{array} \\ \right . $$ and for $r \ge 3$, $$\aPP{\N{\al^B_{\overline m_{j_1}},\ldots, \al^B_{\overline m_{j_{r-1}}} }}{\X{\al^B_{\overline m_{j_r}}}}_t = \left \{ \begin{array}{ll} t \,\nu \Bigl ( \prod_{k=1}^r \al_{\overline m_{j_k}} \Bigr ), \quad & \text{ if } \{\overline m_{j_1},\ldots, \overline m_{j_r} \} \subseteq B^c, \\ \\ $0$, & \text{otherwise}. \end{array} \right . $$ {\bf The integrators in the iteration steps.} On the right-hand side of \eqref{levy-product}, integrals with respect to martingales and with respect to {\it deterministic} point-bracket processes appear. If we apply \eqref{levy-product} to the integrands, we will get ``mixed'' iterated integrals where the integrators are both martingales and point brackets. We will use the superscript $i$ where $i=1$ stands for ``martingale'' and $i=0$ for point bracket. If $S\subseteq\{ 1, \ldots, \overline m_N\}$ we define \begin{equation*} \al_{(S)} := \prod_{\ell \in S} \al_{\ell}, \quad \widehat \al_{(S)} := 1_{\Rbb \setminus\{0\}}\al_{(S)}. \end{equation*} For $ i \in \{ 0,1\}$, we will write, summarizing the analysis of the integrators above, \equal \label{Y-in-detail} \rmd Y^{ \al_{(S),i} }_t := \left \{ \begin{array}{ll} \nu(\al_{(S)}) \rmd t & \text{ if }\quad i=0, \, \,S \subseteq B^c, \,\, |S|\ge 2, \\ \\ \sigma^2\al_{(S)}(0) \rmd t & \text{ if }\quad i=0, \,\,S \subseteq B, \,\, |S|= 2, \\\\ \al_{(S)}(0)\rmd W^\sigma_t & \text{ if }\quad i=1, \,\,S\subseteq B, \,\, |S|= 1, \\\\ \rmd X^{\widehat \al_{(S)}}_t & \text{ if }\quad i=1, \,\, S\subseteq B^c , \,\, |S| \ge 1, \\\\ 0, &\text{ otherwise}. \end{array} \right . \tionl \bigskip \\ {\bf Algorithm to build identification rules for the integrands.} In \eqref{levy-product} the function $t \mapsto \prod_{q=1}\p r F_{\overline m_{j_q}}(t) $ appears on the right hand side. Since we want to use the tensor product $\bigotimes_{i=1}^{ N} F_{\otimes \overline m_{i-1}+1:\overline m_i}$ as integrand in the final formula, we need to identify $t:= t_{\overline m_{j_1}}=\ldots= t_{\overline m_{j_r}}$ to get this ordinary product from the tensor product. These ordinary products arise from each application of \eqref{levy-product}, hence we want to derive an identification rule that describes which of the variables $t_1,\ldots,t_{\overline m_N}$ need to be identified in each step. Set $$[\overline m_N] :=\{1,2,\ldots, \overline m_N\}. $$ $\Pi^{}(m_1,\ldots,m_N)$ will denote the set of all those partitions ${\bf s}= (S_1,\ldots,S_k)$ of the set $[\overline m_N]$ which can be built using the following backward induction from $k$ till $1:$\\ \underline{First Step: $k$} \, Choose a non-empty subset $$ S_k \subseteq \{ \overline m_1, \ldots, \overline m_N\}. $$ \underline{Step: $k-l+1 \to k-l$} \, Assume that $S_k, S_{k-1}, \ldots, S_{k-l+1}$ (for some $l =1,\ldots,k-1$) have been chosen. \\ By $I_1,..., I_N$ we denote the sets which contain exactly those indices of the $F_j$'s which are used in the {\it same } elementary iterated integral on the left-hand side of \eqref{index-renaming}, that is, $$I_1 := \{1, \ldots,m_1\} \quad \text{ and } \quad I_r := \{\overline m_{r-1}+1, \ldots, \overline m_r \}, \quad r=2,\ldots,N.$$ Then $S_{k-l}$ denotes a non-empty subset of the set consisting of the largest elements of $I_1,\ldots,I_N$ {\it which have not yet been chosen for $S_k, S_{k-1}, \ldots, S_{k-l+1}$ already}: If \begin{equation*} L^{k-l}_r = \sup\{ I_r \setminus ( S_k \cup S_{k-1} \cup \ldots\cup S_{k-l+1})\}, \quad r=1,\ldots,N, \end{equation*} where we use the convention $\sup \emptyset= -\infty$, then $$S_{k-l} \subseteq \{ L^{k-l}_r: L^{k-l}_r\neq -\infty, \,\, r=1,\ldots,N \}.$$ Notice that we require that $\bigcup_{\ell=1}^k S_\ell = [\overline m_N]$. Any such ${\bf s}= (S_1,\ldots,S_k) \in \Pi^{}(m_1,\ldots,m_N)$ will be called an {\bf identification rule}. We summarize this procedure in the following definition. \begin{definition} \label{partitions} Let $\Pi^{}(m_1,\ldots,m_N)$ be the set of all partitions ${\bf s}= (S_1,\ldots,S_{|{\bf s}|})$ of $\{1,2,\ldots, \overline m_N\}$ (here $|{\bf s}|$ stands for the number of sets which belong to ${\bf s}$), where $N \le |{\bf s}| \le \overline m_N$, such that \\ {\rm(i)} each $S_\ell$ contains at most one element of $\{\overline m_{r-1}+1, \ldots, \overline m_r \}$, that is, \\ $$ |S_\ell \cap \{\overline m_{r-1}+1, \ldots, \overline m_r \}| \le 1 \quad \text{ for all} \quad \ell=1,...,|{\bf s}|, \,\, r=1,\ldots,N,$$ {\rm(ii)} the elements of each $\{\overline m_{r-1}+1, \ldots, \overline m_r \}$ appear ordered within ${\bf s}$, that is, if for $1\le \ell < k \le |{\bf s}|$ it holds $a \in S_\ell \cap \{\overline m_{r-1}+1, \ldots, \overline m_r \}$ and $b \in S_k \cap \{\overline m_{r-1}+1, \ldots, \overline m_r \}, $ then $a<b.$ \end{definition} For a function $(u_1,\ldots,u_{\overline m_N}) \mapsto H(u_1,\ldots,u_{\overline m_N})$ and ${\bf s}= (S_1,\ldots,S_k)$, we define the following identification of variables: \equal \label{s-rule} && H_{{\bf s}}(t_1,\ldots,t_k) \,\, \text{ is derived from } \,\, H(u_1,\ldots,u_{\overline m_N}) \,\, \text{ by replacing all } \,\, u_j \,\,\text{ with } \,\, j \in S_r \,\, \notag \\ && \text{ by the same } \,\, t_r \text{ for } \,\, r=1,\ldots,k. \tionl As already indicated above the identification rules ${\bf s}= (S_1,\ldots,S_k)$ will be used to describe the integrands which result from the iteration of \eqref{levy-product}: In the first step, which is \eqref{levy-product} itself, the factor $ \prod_{q=1}\p r F_{\overline m_{j_q}}$ appears. Notice that $$ \prod_{q=1}\p r F_{\overline m_{j_q}} = \prod_{\ell \in S_k} F_{\ell} \quad \text{ provided that } \quad S_k = \{\overline m_{j_1}, \ldots, \overline m_{j_r}\}.$$ At the same time, the iterated integrals with order $m_{j_1}, \ldots, m_{j_r},$ which appear on the left-hand side of \eqref{levy-product}, have its order diminished by $1$ on the right-hand side. If we apply \eqref{levy-product} to the integrands of the right-hand side, then the product $ \prod_{\ell \in S_{k-1}} F_{\ell} $ will appear, where $$S_{k-1}\subseteq (\{ \overline m_1, \ldots, \overline m_N\}\setminus S_k) \cup \{\overline m_{j_1}-1, \ldots, \overline m_{j_r}-1 \}. $$ We repeatedly apply \eqref{levy-product} and, finally, we have $ \prod_{r=1}^k \prod_{j \in S_r} F_j (t_r)$. This product we get from the tensor product $ \left ( \bigotimes_{j=1}\p N F_{\otimes \overline m_{j-1}+1:\overline m_{j+1}} \right )(u_1,\ldots, u_{\overline m_N})= F_1(u_1) \times \ldots\times F_{\overline m_N}(u_{\overline m_N}) $ applying the identification rule ${\bf s} =(S_1,\ldots, S_k)$: $$\left ( \bigotimes_{j=1}\p N F_{\otimes \overline m_{j-1}+1:\overline m_j} \right )_{\bf s}(t_1,\ldots,t_{k}) = \prod_{r=1}^k \prod_{j \in S_r} F_j (t_r) .$$ Identification rules similar to the above ones appear also in Peccati and Taqqu \cite[Chapter 7]{PT11} and Last et al. \cite{LPST14} (see also the references therein). \bigskip \\ {\bf The set $I_{{\bf s}}$.} We still need to pay attention to the fact that each application of \eqref{levy-product} produces integrals with respect to both compensated-covariation processes and point brackets. For any identification rule ${\bf s}= (S_1,\ldots,S_{|{\bf s}|}) \in \Pi^{}(m_1,\ldots,m_N) $ we define the sets $$I_{{\bf s}}= \{ {\bf i} := (i_1,\ldots, i_{|{\bf s}|}): i_\ell \in i(S_\ell), \,\, \ell=1,\ldots, |{\bf s}| \},$$ where \equa i(S_\ell) := \left \{ \begin{array}{ll} \{ 0\}, & \text{ if } |S_\ell | = 2, \,\, S_\ell \subseteq B, \\ \{ 1\}, & \text{ if } |S_\ell| = 1, \\ \{ 0, 1\} , & \text{ if } |S_\ell| \ge 2 , \,\, S_\ell \subseteq B^c, \\ \emptyset, &\text{ otherwise}. \end{array} \right . \tion So, in view of \eqref{Y-in-detail}, if for example $ |S_\ell | = 2$ and $S_\ell \subseteq B$, then we have just one integral, hence $ i(S_\ell)$ contains one element. This integral is with respect to $\rmd t$, which we indicate here by $ i(S_\ell)=\{ 0\}$. If $|S_\ell| = 1,$ then we also have just one integral but the integrator is a martingale, so we use $i(S_\ell)=\{ 1\}$, and so on. We denote by $M_t^{|{\bf s}|}$ the simplex $M_t^{\,m}$ (cf.\ \eqref{eq:def.Mn}) with $m:=|{\bf s}|$. Then we get \equal \label{sum_with_zeros} && \prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F_{ \otimes{\overline m_{j-1}+1: \overline m_j}})_t \notag\\ &=& \!\!\!\!\sum_{B \subseteq [\overline m_N]} \,\, \sum_{{\bf s} \in \Pi^{}(m_1,\ldots,m_N)} \,\,\ \sum_{ {\bf i} \in I_{{\bf s}}} \int_{M_t^{|{\bf s}|}} \left ( \bigotimes_{j=1}\p N F_{\otimes \overline m_{j-1}+1:\overline m_j} \right )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{B}_{(S_1),i_1}} \dots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}), i_{|{\bf s}|}}}_{t_{|{\bf s}|}}. \tionl {\bf Avoiding zeros in the summation.} The right-hand side of \eqref{sum_with_zeros} contains many terms which are zero: From \eqref{Y-in-detail} we see that this happens, for example, if there is a set $S_\ell$ containing elements from both, $B$ and $B^c$. Another case where the integral is zero is if there is a set $S_\ell \subseteq B$ with $|S_\ell| \ge 3$. We will exclude these cases by defining \equal \label{s-no-zero} \Pi^{}_{\le 2, \ge1 }(B, B^c; m_1,\ldots,m_N) &:=& \big \{ {\bf s} =(S_1,\ldots,S_{|{\bf s}|}) \in \Pi^{}(m_1,\ldots,m_N): \forall \ell =1,\ldots,|{\bf s}| \text{ it holds } \notag \\ &&\quad\quad\quad\quad (S_\ell \cap B =S_\ell \text{ and } |S_\ell| \le 2 ) \,\, \text{ or } \,\, S_\ell \cap B^c =S_\ell \big \}. \tionl Hence we have derived the following theorem: \begin{theorem}\label{thm:prod.rule} Let $X$ be a L\'evy process and suppose that $\Lm\subseteq L\p2(\mu)$ satisfies Assumption \ref{ass:good.sys}. For $J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F\p j) \in \Jscr_\rme$, $j=1,\ldots,N$, with $F\p j:=F_{ \otimes{\overline m_{j-1}+1: \overline m_j}} \in \Bb_T^{m_j}$, the following product formula holds: \equal \label{product-rule} \hspace*{-5em}&& \hspace*{-2em}\prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F\p j)_t \notag\\ \hspace*{-1em}&=&\!\!\!\!\sum_{B \subseteq [\overline m_N]} \,\, \sum_{{\bf s} \in \Pi_{\le 2, \ge 1}^{}(B,B^c; m_1,\ldots,m_N)} \,\,\ \sum_{ {\bf i} \in I_{{\bf s}}} \int_{M_t^{|{\bf s}|}} \bigg( \bigotimes_{j=1}^{ N} F\p j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{B}_{(S_1),i_1}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}), i_{|{\bf s}|}}}_{t_{|{\bf s}|}}. \tionl \end{theorem} Let us now denote by $\lm\p{|\bf s|}$ the $|\bf s|$-dimensional Lebesgue measure restricted to the simplex $M\p{|\bf s|}_t$ (cf.\ \eqref{eq:def.Mn}). Our aim is to compute the expectation of \eqref{product-rule}. We shall call the resulting relation \emph{moment formula}. Before we define \equal \label{pi2} \Pi^{}_{= 2, \ge2 }(B, B^c; m_1,\ldots,m_N) &:=& \big \{ {\bf s} =(S_1,\ldots,S_{|{\bf s}|}) \in \Pi^{}(m_1,\ldots,m_N): \forall \ell =1,\ldots,|{\bf s}| \text{ it holds } \notag \\ &&(S_\ell \cap B =S_\ell \text{ and } |S_\ell| = 2 ) \,\, \text{ or } \,\, S_\ell \cap B^c =S_\ell \text{ and } |S_\ell| \ge2 \big \}. \tionl \begin{corollary}\label{cor:moment.formula} Let $X$ be a L\'evy process and suppose that $\Lm\subseteq L\p2(\mu)$ satisfies Assumption \ref{ass:good.sys}. Then for $J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^j ) \in \Jscr_\rme$, $j=1,\ldots,N$, where $F^j = F_{ \otimes{\overline m_{j-1}+1: \overline m_j}} \in \Bb_T^{m_j}$, the moment formula \equal \label{moment-formula} \EE \bigg [\prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^j)_t\bigg ] &=& \!\!\!\!\sum_{B \subseteq [\overline m_N]} \,\, \sum_{{\bf s} \in \Pi_{= 2, \ge 2}^{}(B,B^c; m_1,\ldots,m_N)} \,\,\ \bigg ( \prod_{\begin{subarray}{c}\ell=1\\ S_\ell \subseteq B^c\end{subarray}}^{|{\bf s}|} \nu(\alpha_{(S_\ell)}) \bigg ) \bigg ( \prod_{\begin{subarray}{c}q=1\\ S_q \subseteq B\end{subarray}}^{|{\bf s}|} \bigg (\alpha_{(S_q)}(0) \sigma^2 \bigg ) \bigg ) \notag \\ && \quad \quad \quad \times \int_{M_t^{|{\bf s}|}} \bigg (\bigotimes_{i=1}^{N} F^j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd \lambda^{|{\bf s}|} (t_1,\ldots,t_{|{\bf s}|}) \tionl holds. \end{corollary} \begin{proof} First we observe that, according to \eqref{Y-in-detail}, the process $Y^{\al^{B}_{(S_\ell),i_\ell}}$ can be deterministic only if $|S_\ell| \ge2$ and $i_\ell=0$, and in this case, its explicit expression is \[ Y_{t}^{\al^{B}_{(S_\ell), 0}}=\begin{cases}\nu(\al_{(S_\ell)}) \, t,&\quad\textnormal{if }\ S_\ell \subseteq B^c,\\ \sigma^2\al_{(S)}(0)\, t,&\quad\textnormal{if }\ S_\ell \subseteq B\ \text{ and }\ |S_\ell |=2. \end{cases} \] If $Y^{\al^{B}_{(S_\ell),i_\ell}}$ is random, then $i_\ell=1$ and $Y^{\al^{B}_{(S_\ell),1}}\in\Hscr\p{\,2}$. We now take the expectation in \eqref{product-rule} and notice that, if at least one of the $Y^{\al^{B}_{(S_\ell),i_\ell}}$ is random, we have $$ \EE \left[\int_{M_t^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^{ N} F^j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{B}_{(S_1),i_1}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}), i_{|{\bf s}|}}}_{t_{|{\bf s}|}}\right] =0 $$ because the integrand is bounded. This implies that only integrals with ${\bf s} \in \Pi_{= 2, \ge 2}^{}(B,B^c; m_1,\ldots,m_N)$ will appear, and since $i_\ell=0$ for all $\ell$ there is no sum over ${\bf i} \in I_{{\bf s}},$ so that we get \eqref{moment-formula}. The proof is complete. \end{proof} \begin{example} \label{calculation} We illustrate the moment formula \eqref{moment-formula} with some examples. Choose $\alpha_1,\ldots ,\al_5 $ and let $X^{\alpha_1},\ldots,X^{\alpha_5}$ be given by \eqref{poisson-integral}. \begin{enumerate} \item For $N=3$ we assume that $m_1=1,$ $m_2=1$ and $m_3=2.$ We want to apply \eqref{moment-formula} to compute $$\EE \big[J_1^{\alpha_1}(F^1)_t J_1^{\alpha_2}(F^2)_t J_2^{\alpha_3,\alpha_4 }(F^3)_t\big]. $$ By Definition \ref{partitions} we get the identification rules $${\bf s_1}= (\{1,3 \},\{ 2,4 \}) \quad \text{ and }\quad {\bf s_2}=(\{1,4 \},\{2,3\}).$$ In this case $\overline m_3=4$. The subsets of $[\overline m_3]=\{1,2,3,4\}$ which are relevant for the construction of $B$ are the elements of the family $\Bscr:=\{\{1,3\},\{1,4\},\{2,3\},\{2,4\},\{1,2,3,4\},\emptyset\}$, since $\Pi_{=2,\ge2}(B,B\p c;1,1,2)=\emptyset$ for $B\notin\Bscr$. We now compute $\Pi_{=2,\ge2}(B,B\p c;1,1,2)$ for $B\in\Bscr$. For shortness, we write $\Pi_{=2,\ge2}(B,B\p c)$. We have $$\Pi_{=2,\geq2}(\{1,3\},\{2,4\})=\Pi_{=2,\geq2}(\{2,4\},\{1,3\})={\bf s_1},$$ $$\Pi_{=2,\geq2}(\{1,4\},\{2,3\})=\Pi_{=2,\geq2}(\{2,3\},\{1,4\})={\bf s_2},$$ and finally we have $$\Pi_{=2,\ge2}([\overline m_3],\emptyset)=\Pi_{=2,\ge2}(\emptyset,[\overline m_3])=\{{\bf s_1},{\bf s_2}\}.$$ We stress that $\Pi_{=2,\ge2}([\overline m_3],\emptyset)$ corresponds to the case where only integration with respect to the Brownian part is considered, while $\Pi_{=2,\ge2}(\emptyset,[\overline m_3])$ corresponds to the opposite case where only integration with respect to the jump part is considered. Hence, \equa \EE \big[J_1^{\alpha_1}(F^1)_t J_1^{\alpha_2}(F^2)_t J_2^{\alpha_3,\alpha_4 }(F^3)_t\big] &=& C_1 \int_0^t \int_0^r F^1(u) F^2(r) F^3(u,r) du dr \\&& + C_2 \int_0^t \int_0^r F^1(r) F^2(u) F^3(u,r) du dr, \tion where $$C_1= \nu(\alpha_1\alpha_3) \nu(\alpha_2\alpha_4) + \nu(\alpha_1\alpha_3) (\alpha_2\alpha_4)(0)\sigma^2+ \nu(\alpha_2\alpha_4)(\alpha_1\alpha_3)(0)\sigma^2 + (\alpha_1\alpha_2\alpha_3\alpha_4)(0)\sigma^4 $$ and $$C_2= \nu(\alpha_2\alpha_3) \nu(\alpha_1\alpha_4) + \nu(\alpha_2\alpha_3) (\alpha_1\alpha_4)(0)\sigma^2+ \nu(\alpha_1\alpha_4)(\alpha_2\alpha_3)(0)\sigma^2 + (\alpha_1\alpha_2\alpha_3\alpha_4)(0) \sigma^4 .$$ \item For $N=3$ with $m_1=1,$ $m_2=1$ and $m_3=3$ we notice that $\Pi^{}_{= 2, \ge2 }(B, B^c; m_1,m_2,m_3) =\emptyset $, for every $B\subseteq\{1,2,3,4,5\}$. This can be seen because by Definition \ref{partitions} (i) each element of $\{\overline m_{2+1}, \overline m_{2+2}, \overline m_{2+3}\}$ has to be in a different partition set. So we should have a least 3 partition sets, each with (at least) 2 elements. This is impossible as $m_1+m_2+m_3=5.$ Hence, \equa \EE \big[J_1^{\alpha_1}(F^1)_t J_1^{\alpha_2}(F^2)_t J_2^{\alpha_3,\alpha_4,\alpha_5}(F^3)_t \big]=0. \tion It is easy to see that this observation can be generalized as follows: If there exists a $m_j$ such that $m_j > m_1+...+m_{j-1}+m_{j+1} +...+m_N$ then $$ \EE \bigg [\prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^j)_t\bigg ] =0.$$ \end{enumerate} \end{example} Moment formulas similar to \eqref{moment-formula} have also been obtained by Peccati and Taqqu in \cite[Corollary 7.4.1]{PT11} and by Last et al.\ in \ \cite[Theorem 1]{LPST14} for multiple integrals (similar to the multiple integrals introduced by It\^o in \cite{I56}) generated by a compensated Poisson random measure. The proofs in \cite{PT11} and \cite{LPST14} rely on \emph{Mecke's Formula} (see \cite{M67}), which is not applicable if the L\'evy process has a Gaussian part. Here we use \eqref{levy-product} instead of \emph{Mecke's Formula}. We stress that for the case without Gaussian part the moment formula in \cite[Theorem 1]{LPST14} only requires an $L\p1$-condition. This is due to the fact that for $\sig=0$ the multiple integrals can be considered pathwise. \begin{remark}[Product and moment formula for linear combinations of elementary functions]\label{rem:ext.lin.com} Let $\Escr^{m_j}_T $ denote the linear subspace of $L\p2(M\p{m_j}_T,\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}})$ generated by $F_{\otimes_{m_j}} \in \Bb_T\p {\otimes m_j}$ restricted to ${M}_{\,T}^{\, m_j}$. The elementary iterated integrals can be uniquely linearly extended to elements of $\Escr^{m_j}_T$. Hence, if $F\p j\in\Escr^{m_j}_T$ has the representation \[ F\p j=\sum_{k=1}\p {M_j}F\p{j,k}_{\otimes\overline m_{j-1}+1:\overline m_j},\quad j=1,\ldots,N, \] then \[ \prod_{j=1}\p N J_{m_j}\p{\al_{\overline m_{j-1}+1}: \al_{\overline m_j}}(F\p j)=\prod_{j=1}\p N\Big(\sum_{k=1}\p{M_j}J_{m_j}\p{\al_{\overline m_{j-1}+1}: \al_{\overline m_j}}(F\p{j,k}_{\otimes\overline m_{j-1}+1:\overline m_j})\Big). \] Using the formula \[ \prod_{j=1}\p N\Big(\sum_{k=1}\p{M_j}a\p{j,k}\Big)=\sum_{j_1=1}\p{M_1}\ldots\sum_{j_N=1}\p{M_N}a\p{1,j_1}a\p{2,j_2}\cdots a\p{N,j_N}, \] valid for real numbers $a\p{j,k}$, $k=1,\ldots,N_j$; $j=1,\ldots,N$, the multi-linearity of the tensor product in Theorem \ref{thm:prod.rule} and the linearity of the identification rule, it is clear that \eqref{product-rule} extends to this more general case. From Corollary \ref{cor:moment.formula} it is now clear that the moment formula \eqref{moment-formula} holds also for $F\p j\in\Escr^{m_j}_T$. \end{remark} \subsection{Extensions of the product and moment formula} For practical applications Assumption \ref{ass:good.sys} might not be desirable because it requires that $\Lm$ is stable under multiplication. For example, if $\Lm$ is an orthogonal basis of $L\p 2(\mu)$, in general, it fails to be stable under multiplication. However, $\Lm$ being an orthogonal basis is especially interesting because then $\Xscr_\Lm$, defined in \eqref{X-lambda}, consists of countably many orthogonal martingales, and it possesses the CRP with respect to $\Fbb\p X$ in the simpler form given in Remark \ref{rem:alt.rep.crp}. Therefore, in the present subsection, we extend \eqref{product-rule} and \eqref{moment-formula} to products of iterated integrals generated by $\Xscr_\Lm$, where $\Lm$ is an arbitrary system in $\Lm\subseteq\bigcap_{p\geq1}L\p p(\mu)$. To begin with, we prove the following technical lemma. We denote by $\Bb_\Rbb$ the space of bounded measurable functions on $\Rbb$. \begin{lemma}\label{lem:bou.fun.app} Let $\al\in L\p2(\mu)\cap L\p p(\mu)$, $p>2$, and let $\Lm:=L\p1(\mu)\cap\Bb_\Rbb$. Then there exists $(\al\p k)_{k\geq1}\subseteq\Lm$ such that $\al\p k\longrightarrow \al$ in $L\p q(\mu)$ as $k\rightarrow+\infty$ for every $2 \le q\leq p$. \end{lemma} \begin{proof} For $\al\in L\p2(\mu)\cap L\p p(\mu)$ we define $\et:=\al1_{\{|\al|\leq1\}}$ and $\gm:=\al1_{\{|\al|>1\}}$. Then, $\al=\et+\gm,$ where $\et\in L\p2(\mu)$ and $\gm\in L\p p(\mu)$. Because $\Lm$ is dense in $L\p q(\mu)$, for every $q>1$, there exist $(\et\p k)_{k\geq1}$ and $(\gm\p k)_{k\geq1}$ in $\Lm$ such that $\et\p k\longrightarrow \et$ in $L\p2(\mu)$ and $\gm\p k\longrightarrow \gm$ in $L\p p(\mu)$ as $k\rightarrow+\infty$, respectively. Since $\mu(\{|\al|>1\})<+\infty$, we have $\gm\p k\longrightarrow \gm$ also in $L\p2(\mu)$. Notice that, because $\et$ is bounded by one, we can also assume that $(\et\p k)_{k\geq1}$ is uniformly bounded by one. But then $\et\p k\longrightarrow \et$ in $L\p p(\mu)$. A sequence $(\al\p k)_{k\geq1}\subseteq\Lm$ converging to $\al$ in $L\p2(\mu)$ and in $L\p p(\mu)$ is given, for example, by $\al\p k:=\et\p k1_{\{|\al|\leq1\}}+\gm\p k1_{\{|\al|>1\}}\in\Lm$, $k\geq1$. Finally, if $(\al\p k)_{k\geq1}$ converges to $\al$ in $L\p 2(\mu)$ and $L\p p(\mu)$, then it also converges to $\al$ in $L\p q(\mu)$ for every $2 \le q\leq p$ . \end{proof} We now come to the following proposition, which, in particular, extends \eqref{product-rule} to $\Jscr\p{\Xscr_\Lm}_\rme$, provided that $\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu)$. \begin{proposition}\label{prop:con.sys} Assume $X$ is a L\'evy process with characteristics $(\gm,\sig\p2,\nu)$. Let $\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu)$ and let $\Xscr_\Lm$ denote the associated family of martingales. Then \textnormal{(i)} $X\p \al$ possesses finite moments of every order, for every $\al\in\Lm$. \textnormal{(ii)} $\Lm$ is a total system in $L\p 2(\mu)$ if and only if $\Xscr_\Lm$ possesses the chaotic representation property with respect to $\Fbb\p X$. \textnormal{(iii)} The product formula \eqref{product-rule} and the moment formula \eqref{moment-formula} hold for the family $\Jscr\p{\Xscr_\Lm}_\rme$ of elementary iterated integrals generated by $\Xscr_\Lm$ . \textnormal{(iv)} Let $F\p j\in\Escr\p{m_j}_T$, $j=1,\ldots,N$. Then the product formula \eqref{product-rule} and the moment formula \eqref{moment-formula} hold for the product $\prod_{j=1}\p N J_{m_j}\p{\al_{\overline m_{j-1}+1}: \al_{\overline m_j}}(F\p j)$. \end{proposition} \begin{proof} First we verify (i). By \cite[Corollary 2.12]{R04}, there exists a constant $C_p>0$ such that \begin{equation}\label{eq:Lp.est} \|X\p{\al}_T\|^p_{L\p{p}(\Pbb)}\leq C_pT \big(\|\al\|_{L\p2(\mu)}\p{p}+\|\al\|_{L\p{p}(\mu)}\p{p}\big). \end{equation} Hence, $\Xscr_\Lm$ is a family of martingales with finite moments of every order if $\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu)$. To see (ii) we refer to \cite[Theorem 6.6]{DTE16}. To show (iii), let $\tilde\Lm:= L\p1(\mu)\cap\Bb_\Rbb$. Then $\tilde \Lm$ satisfies Assumption \ref{ass:good.sys} and, according to Theorem \ref{thm:prod.rule}, the multiplication formula \eqref{product-rule} holds for $\Jscr\p{\Xscr_{\tilde \Lm}}_\rme$. We now show by approximation that \eqref{product-rule} holds also for $\Jscr\p{\Xscr_{\Lm}}_\rme$ if $\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu)$. We set $q_0:=2\p{\overline m_N}N$. By Lemma \ref{lem:bou.fun.app}, for every $\al\in\Lm$ there exists a sequence $(\al\p k)_{k\geq1}\subseteq{\tilde\Lm}$ such that $\al\p k\longrightarrow \al$ in $L\p2(\mu)$ and in $L\p{q_0}(\mu)$ as $k\rightarrow+\infty$. Since \eqref{poisson-integral} implies $X\p{\al\p k}_T-X\p{\al}_T=X\p{\al\p k-\al}_T$ a.s., by \eqref{eq:Lp.est} we get \[ \|X\p{\al\p k}_T-X\p{\al}_T\|_{L\p{q_0}(\Pbb)}=\|X\p{\al\p k-\al}_T\|_{L\p{q_0}(\Pbb)}\longrightarrow0\quad \textnormal{ as }\ k\rightarrow+\infty. \] Let now $(\al\p k_i)_{k\in\Nbb}\subseteq\tilde\Lm$ and $\al\p k_i\longrightarrow \al_i$ in $L\p2(\mu)$ and $L\p{q_0} (\mu)$, for every $i=1,\ldots,\overline m_N$. Then, setting $F^j:=F_{\otimes \overline m_{j-1}+1:\overline m_j}$ for every $j=1,\ldots,N$, Lemma \ref{lem:mom.it.int} (ii) with $p=N$ implies \begin{eqnarray*} \Ebb\Bigg[\sup_{t\in[0,T]}\Big|J\p{\al\p k_{\overline m_{j-1}+1:\overline m_j}}_{m_j}(F^j)_t-J\p{\al_{\overline m_{j-1}+1:\overline m_j}}_{m_j}(F^j)_t\Big|^{N}\Bigg]\longrightarrow0\quad\textnormal{ as } \ k\rightarrow+\infty. \end{eqnarray*} This yields, as a consequence of H\"older's inequality, \begin{equation*} \prod_{j=1}\p N J\p{\al\p k_{\overline m_{j-1}+1:\overline m_j}}_{m_j}(F^j)_t\longrightarrow \prod_{j=1}\p N J\p{\al_{\overline m_{j-1}+1:\overline m_j}}_{m_j}(F^j)_t\quad \textnormal{in }\ L\p1(\Pbb)\ \textnormal{ as }\ k\rightarrow+\infty, \end{equation*} for every $t\in[0,T]$. For the right-hand side of \eqref{product-rule}, we will show that $$\int_{M_t^{|{\bf s}|}} \bigg( \bigotimes_{j=1}^N F\p j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{k,B}_{(S_1),i_1}} \ldots \rmd Y^{\al^{k,B}_{(S_{|{\bf s}|}), i_{|{\bf s}|}}}_{t_{|{\bf s}|}} $$ converges in $L\p2(\Pbb)$. For this, we first consider the convergence of the processes $Y^{\al^{k,B}_{(S_r),i_r}}$. We define $Y^{\al^{B}_{(S_r),i_r}}$ according to \eqref{Y-in-detail}. We use the representation \eqref{Y-in-detail} and discuss the convergence cases separately. Notice that, since we have chosen the sequence $\al\p k_j$ such that $\al\p k_j \longrightarrow \al_j$ in $L^q(\mu)$ for every $2 \le q \le q_0=2\p{\overline m_N}N$, $j=1,\ldots,N$, and $\mu = \sigma^2 \delta_0 + \nu$, it follows that \equa \nu\big(\al^{k}_{(S_r)}\big) = \nu\Big( \prod_{\ell \in S_r} \al^{k}_{\ell}\Big) \longrightarrow \nu\Big( \prod_{\ell \in S_r} \al_{\ell}\Big) = \nu\big(\al_{(S_r)}\big)\quad \text{ and } \quad \al^{k}_{(S_r)}(0) \longrightarrow \al_{(S_r)}(0)\quad\ \text{ as }\ k\to +\infty. \tion Therefore, we also have $ \al^k_{(S_r)}(0) W^\sigma \longrightarrow \al_{(S_r)}(0) W^\sigma$ in $\Hscr\p{\,2}$ as $k\to+\infty$. Finally, $$X^{\widehat \al^k_{(S_r)}} =\Big(1_{ [0, \cdot]\times (\Rbb \setminus \{ 0\}) } \prod_{\ell \in S_r} \al^{k}_{\ell}\Big) \ast \tilde N \longrightarrow \Big(1_{ [0, \cdot]\times (\Rbb \setminus \{ 0\}) } \prod_{\ell \in S_r} \al_{\ell}\Big) \ast \tilde N = X^{\widehat \al_{(S_r)}}\ \text{ in }\ \Hscr\p2\ \text{ as }\ k\to+\infty, $$ since our assumptions imply that $\widehat \al^k_{(S_r)} \longrightarrow \widehat \al_{(S_r)}$ in $L^2(\nu)$ as $k\to+\infty$. Using a telescopic sum we estimate \equal \label{telescop} &&\less \Ebb\bigg[\bigg(\int_{M_t^{|{\bf s}|}} \bigg( \bigotimes_{j=1}^N F\p j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{k,B}_{(S_1),i_1}} \ldots \rmd Y^{\al^{k,B}_{(S_{|{\bf s}|}) ,i_{|{\bf s}|}}}_{t_{|{\bf s}|}} \notag \\ && \quad \quad \quad - \int_{M_t^{|{\bf s}|}}\bigg( \bigotimes_{j=1}^N F\p j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{B}_{(S_1),i_1}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}), i_{|{\bf s}|}}}_{t_{|{\bf s}|}} \bigg)\p2\bigg] \notag \\ &\leq& C \sum_{r = 1}^N \Ebb\bigg[\bigg(\int_{M_t^{|{\bf s}|}} \bigg( \bigotimes_{j=1}^N F\p j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{k,B}_{(S_1),i_1}} \ldots \rmd Y_{t_1}^{\al^{k,B}_{(S_{r-1}),i_{r-1}}} \rmd (Y_{t_r}^{\al^{k,B}_{(S_1),i_r}} - Y_{t_r}^{\al^{B}_{(S_1),i_r}} ) \notag \\ &&\quad \quad \quad\quad \quad \quad \times \rmd Y_{t_1}^{\al^{B}_{(S_{r+1}),i_{r+1}}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}), i_{|{\bf s}|}}}_{t_{|{\bf s}|}} \bigg)\p2\bigg] . \tionl For the addends on the right-hand side of \eqref{telescop}, using It\^o's isometry whenever the integrator is an $\Hscr\p{\,2}$-martingale and Cauchy-Schwarz inequality for integrators absolutely continuous with respect to $\rmd t$, we find two constants \[ c\p k:=c(T,\al^{k,B}_{(S_1)i_1},\ldots,\al^{k,B}_{(S_{r-1})i_{r-1}},\al^{B}_{(S_{r+1})i_{r+1}},\ldots,\al^{B}_{(S_{|{\bf s}|}) i_{|{\bf s}|}},\sig,\nu)>0,\quad C(T,\al^{k,B}_{(S_{r})i_{r}},\al^{B}_{(S_{r})i_{r}})>0, \] such that \begin{equation}\label{eq:est.cau.seq.it.int} \begin{split} \Ebb\bigg[\bigg(\int_{M_t^{|{\bf s}|}} \bigg( \bigotimes_{j=1}^N &F\p j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{k,B}_{(S_1)i_1}} \ldots \rmd Y_{t_1}^{\al^{k,B}_{(S_{r-1})i_{r-1}}}\times\\&\times \rmd (Y_{t_r}^{\al^{k,B}_{(S_1)i_r}} - Y_{t_r}^{\al^{B}_{(S_1)i_r}} )\rmd Y_{t_1}^{\al^{B}_{(S_{r+1})i_{r+1}}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}) i_{|{\bf s}|}}}_{t_{|{\bf s}|}} \bigg)\p2\bigg] \\&\hspace{1cm}\leq c\p k\,C(T,\al^{k,B}_{(S_{r})i_{r}},\al^{B}_{(S_{r})i_{r}})\,\int_{M_t^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^N F\p j \bigg )_{\bf s}\p2(t_1,\ldots,t_{|{\bf s}|})\rmd \lambda^{|{\bf s}|} (t_1,\ldots t_{|{\bf s}|}). \end{split} \end{equation} We notice that the constant $c\p k$ remains bounded as $k\to+\infty$. Indeed, $c\p k$ can be explicitly computed and consists of products of terms of the form $\nu\big((\al^{k,B}_{(S_{j})i_{j}})\p2\big)$ or $\al^{k}_{(S_j)}(0)$, or $\nu\big(\al^{k,B}_{(S_{j})i_{j}}\big)$, as well as $T$ and $\sigma^2$ for $j=1,\ldots,r-1$, and similarly, but not dependent on $k$, for $j=r+1,\ldots,|\bf s|$. The constant $C\p k:=C(T,\al^{k,B}_{(S_{r})i_{r}},\al^{B}_{(S_{r})i_{r}})$ which arises from It\^o's isometry or Cauchy-Schwarz inequality concerning the integrator $( Y_{t_r}^{\al^{k,B}_{(S_1)i_r}} - Y_{t_r}^{\al^{B}_{(S_1)i_r}} )$, can assume the values $ C\p k= \sigma^2 (\al^{k}_{(S_r)}(0) - \al^{k}_{(S_r)}(0) )^2 $ or $ C\p k =\nu((\al^{k}_{(S_r)} -\al_{(S_r)})^2 )$ when the integrator is in $\Hscr\p2, $ while we would have $C\p k= T (\nu(\al^{k}_{(S_r)} ) - \nu(\al_{(S_r)} ))^2 $ or $C\p k=T\sigma^4(\al^{k}_{(S_r)}(0) - \al_{(S_r)}(0))^2$ for deterministic integrators. But in any case, $$ C\p k=C(T,\al^{k,B}_{(S_{r})i_{r}},\al^{B}_{(S_{r})i_{r}}) \longrightarrow0 \quad \text{as} \quad k\to+\infty. $$ The proof of the product formula for this more general case is complete. For the moment formula \eqref{moment-formula} we observe that this is a direct consequence of the product formula \eqref{product-rule} and the proof can be given as in Corollary \ref{cor:moment.formula}. Clearly (iv) is a direct consequence of (iii) because of the linearity of the iterated integrals and the multi-linearity of the tensor product. The proof of the proposition is complete. \end{proof} We now generalize \eqref{product-rule} and \eqref{moment-formula} to the case in which the functions $F^j$ need not to be bounded but, rather, satisfy some integrability condition. This is the main result of the present paper. For the definition of ${\bf s}$ recall Definition \ref{partitions} and the relations \eqref{s-no-zero} and \eqref{s-rule}. \begin{theorem}\label{thm:gen.it.in} Let $X$ be a L\'evy process with characteristic triplet $(\gm,\sig\p2,\nu)$. Let $\al_1,\ldots, \al_{\, \overline m_N}$ belong to $ \bigcap_{p\geq2}L\p p(\mu)$ and assume that $F\p j \in L\p2(M_T\p{m_j},\rho\p{\al_{\, \overline m_{j-1}+1:\overline m_j}})$, $j=1, \ldots,N$, are such that \begin{equation}\label{eq:gen.it.in.cond} \int_{M_T^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^{ N} F^j \bigg )^2_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd\lm( t_1,\ldots, t_{|{\bf s}|}) < \infty, \quad \forall\, B \subseteq [\overline m_N], \, \forall\, {\bf s} \in \Pi_{\le 2, \ge 1}^{}(B,B^c; m_1,\ldots,m_N). \end{equation} Then, the product formula \eqref{product-rule} and the moment formula \eqref{moment-formula} extend to $\prod_{j=1}\p NJ_{m_j}\p{\al_{\overline m_{j-1}+1: \overline m_j}}(F\p j)_t$ for every $t\in[0,T].$ \end{theorem} Condition \eqref{eq:gen.it.in.cond} is an $L\p2$-bound on $(\bigotimes_{j=1}^{ N} F^j)_{\bf s}$ and ensures that all the stochastic integrals appearing on the right-hand side of \eqref{product-rule} are square integrable martingales. Notice that \eqref{eq:gen.it.in.cond} is fulfilled, for example, whenever $F\p j\in L\p {2N}(M_T\p{m_j},\rho\p{\al_{\, \overline m_{j-1}+1:\overline m_j}})$ for any $j=1,\ldots,N$, (see Remark \ref{sufficient} below). \begin{proof}[Proof of Theorem \ref{thm:gen.it.in}] We choose $\Lm \subseteq\bigcap_{p\geq2}L\p p(\mu)$ such that $\al_1,\ldots, \al_{\, \overline m_N} \in \Lm$ and recall that, because of Proposition \ref{prop:con.sys} (i), the elements of $\Xscr_\Lm$ possess moments of every order. From Proposition \ref{prop:con.sys} (iv), we know that the product rule \eqref{product-rule} extends to the case $\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu)$ for $F\p j\in \Escr_T^{m_j}$, $j=1,\ldots,N$. For later use, we derive an estimate for the second moment of the iterated integrals on the right hand side of this extension of \eqref{product-rule}. Let $F\p j \in \Escr_T^{m_j}$, $j=1,\ldots,N$, and $\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu)$. Applying It\^o's isometry every time the process $Y^{\al^{B}_{(S_{j}) i_{j}}}$ is random, and H\"older's inequality whenever it is deterministic, we find a constant $c(T,\al^{B}_{(S_1)i_1},\ldots,\al^{B}_{(S_{|{\bf s}|}) i_{|{\bf s}|}},\sig,\nu)>0$, such that \begin{equation}\label{eq:est.cau.seq.it.int.fun} \begin{split} \Ebb\bigg[\bigg(\int_{M_t^{|{\bf s}|}}& \bigg( \bigotimes_{j=1}^N F\p j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{B}_{(S_1),i_1}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}), i_{|{\bf s}|}}}_{t_{|{\bf s}|}}\bigg)\p2\bigg] \\&\leq c(T,\al^{B}_{(S_1)i_1},\ldots,\al^{B}_{(S_{|{\bf s}|}) i_{|{\bf s}|}},\sig,\nu)\int_{M_t^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^N F\p j \bigg )_{\bf s}\p2(t_1,\ldots,t_{|{\bf s}|})\rmd \lambda^{|{\bf s}|} (t_1,\ldots t_{|{\bf s}|}). \end{split} \end{equation} The estimate \eqref{eq:est.cau.seq.it.int.fun} implies that we may extend by linearity and continuity the iterated integral appearing on the left-hand side of \eqref{eq:est.cau.seq.it.int.fun} to those functions $F\p j \in L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}}), \, j=1,\ldots,N$, which furthermore satisfy the integrability condition \eqref{eq:gen.it.in.cond}. We now divide the proof into three steps. \noindent \underline{ Step 1.} In this first step we are going to show that the product formula \eqref{product-rule} extends to indicator functions $F\p j =1_{A_j} \in L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}})$. By \cite[Theorem 2.40]{Foll}, given an $\varepsilon>0$ and a Borel set $A_j \in \mathcal{B}([0,T]^{m_j})$, there exists an $M \ge 1$ and disjoint rectangles $R_{j,1},\ldots R_{j,M} \subseteq M_T\p{m_j}$ whose sides are intervals such that $$ \int_{M_T^{m_j}} \Big| 1_{A_j} -\sum_{i=1}^M 1_{R_{j,i}} \Big | \rmd\lm_{m_j} = \lm_{m_j}\Big(A_j \Delta \bigcup_{i=1}^M R_{j,i}\Big) < \varepsilon,$$ where $A\Delta B:=(A\setminus B)\cup(B\setminus A)$ denotes the symmetric difference of $A$ and $B,$ and we used the identity $1_{A\Delta B}=|1_A-1_B|$. We notice that $\sum_{i=1}^M 1_{R_{j,i}} \in \Escr_T^{m_j}$ and $0\le \sum_{i=1}^M 1_{R_{j,i}} \le 1$. Hence, since $\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}}$ is absolutely continuous with respect to $\lm\p{\, m_j}$, there are sequences $(F\p j_k)_{k=1}^\infty \subseteq \Escr_T^{m_j}$ with $|F\p j_k| \le 1$ such that \equal \label{step-indicator} F\p j_k \longrightarrow 1_{A_j} \quad \text{ in } \quad L\p 2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}}),\ \text{ as }\ k\to+\infty,\quad j=1,\ldots,N. \tionl To estimate the difference below we first use a telescopic sum, apply the Cauchy-Schwartz inequality and then use the product formula \eqref{product-rule} from Proposition \ref{prop:con.sys} (iv) so that \equal \label{product-formula-used} &&\EE\bigg [ \bigg ( \prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j}_k)_t - \prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j}_\ell)_t\bigg )^2 \bigg ] \notag \\ &\le & c \sum_{r=1}^N \EE \bigg [ \bigg ( \prod_{j=1}^r J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j}_k)_t \,\, J_{m_{r+1}}^{\al^k_{\overline m_{r}+1: \overline m_{r+1}}}(F^{r+1}_k - F^{r+1}_\ell)_t \,\, \prod_{i=r+2}^N J_{m_i}^{\al_{\overline m_{i-1}+1: \overline m_i}}(F^{i}_\ell)_t\bigg )^2 \bigg ] \notag \\ &=& \!\!\!\! c \sum_{r=1}^N \EE \bigg [\bigg ( \sum_{B \subseteq [\overline m_N]} \,\, \sum_{{\bf s} \in \Pi_{\le 2, \ge 1}^{}(B,B^c; m_1,\ldots,m_N)} \,\,\ \sum_{ {\bf i} \in I_{{\bf s}}} \int_{M_t^{|{\bf s}|}} \bigg( \bigotimes_{j=1}^r F\p j_k \otimes (F^{r+1}_k - F_\ell^{r+1}) \otimes \bigotimes_{i=r+2}^N F\p i_\ell\bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \notag \\ && \hspace{8em} \times \rmd Y_{t_1}^{\al^{B}_{(S_1)i_1}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}) i_{|{\bf s}|}}}_{t_{|{\bf s}|}} \bigg )^2\bigg ], \tionl where $c>0$ is a constant. By \eqref{eq:est.cau.seq.it.int.fun} we conclude that the right-hand side of \eqref{product-formula-used} converges to zero. Indeed, since the integrand is bounded, by dominated convergence and \eqref{step-indicator} we get \equal \label{tensor-Holder} && \int_{M_t^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^r F\p j_k \otimes (F^{r+1}_k - F^{r+1}_\ell) \otimes \bigotimes_{i=r+2}^N F\p i_\ell\bigg )_{\bf s}\p2\rmd \lambda^{|{\bf s}|} (t_1,\ldots t_{|{\bf s}|}) \longrightarrow 0\ \text{ as }\ k\to+\infty. \tionl Hence, we have shown that ${ Z}\p k:= \prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j}_k)_t$ is a Cauchy sequence in $L\p2(\Pbb)$. So, there exists $Z\in L\p2(\Pbb)$ such that $Z\p k\longrightarrow Z$ in $L\p2(\Pbb)$ as $k\to\infty$. On the other side, since $J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j}_k)_t$ converges to $ J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j})_t$ in $L\p2(\Pbb)$ as $k\to\infty$, we also have that $Z\p k\longrightarrow\prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j})_t$ \emph{in probability} as $k\to+\infty$. This implies \begin{equation}\label{eq:id.lim.prod} Z=\prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j})_t\ \quad \text{ a.s.}, \end{equation} because of the uniqueness of the limit in probability. Thus, $\prod_{j=1}^N J_{m_j}^{\al_{\overline m_{j-1}+1: \overline m_j}}(F^{j})_t\in L\p2(\Pbb)$ for every $t\in[0,T]$. From Proposition \ref{prop:con.sys} (iv), we know that $Z\p k$ satisfies the product formula \eqref{product-rule} for every $k$. We now discuss the convergence of the corresponding right hand side in \eqref{product-rule} for $Z\p k$. Similarly as for \eqref{product-formula-used} but now with $F\p j$ instead of and $F\p j_\ell,$ we see that \equal \label{integral-difference} \EE \bigg [ \bigg (\int_{M_t^{|{\bf s}|}} \bigg( \bigotimes_{j=1}^N F\p j_k - \bigotimes_{j=1}^N F\p j\bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd Y_{t_1}^{\al^{B}_{(S_1)i_1}} \ldots \rmd Y^{\al^{B}_{(S_{|{\bf s}|}) i_{|{\bf s}|}}}_{t_{|{\bf s}|}} \bigg )^2 \bigg ] \longrightarrow 0\quad\text{as }\ k\to+\infty. \tionl This means that also $Z$ satisfies \eqref{product-rule}. Thus, \eqref{product-rule} holds for $ F^j= 1_{A_j} \in L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}}).$ The proof of the first step is complete. \noindent \underline{ Step 2.} We observe that, as a consequence of Step 1, by linearity, the product formula \eqref{product-rule} also holds for simple functions from $L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}})$. \noindent \underline{ Step 3.} In this step we show the product formula \eqref{product-rule} for arbitrary functions $F\p j\in L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}})$, $j=1,\ldots, N$, which furthermore satisfy the integrability condition \eqref{eq:gen.it.in.cond}. Any $F\p j\in L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}})$ can be pointwise approximated by a sequence $(F\p j_k)_{k\geq1} $ of simple functions such that $|F\p j_k| \uparrow |F\p j|$ as $k\to+\infty$ (see, for example, \cite[Theorem 2.10b]{Foll}). Because of this and \eqref{eq:gen.it.in.cond}, we get \begin{equation}\label{eq:approx.id.rule} \int_{M_T^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^{ N} F^j_k \bigg )^2_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd\lm( t_1,\ldots, t_{|{\bf s}|})\leq\int_{M_T^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^{ N} F^j \bigg )^2_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd\lm( t_1,\ldots, t_{|{\bf s}|})<+\infty. \end{equation} This implies that we may extend by linearity and continuity the iterated integrals on the right hand side of \eqref{product-rule} defined for simple functions $(F\p j_k)_{k\geq1} $ to those $F\p j \in L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}}), \, j=1,\ldots,N$, which satisfy \eqref{eq:gen.it.in.cond}. Using the second step, we can conclude like in the first step that \eqref{product-formula-used} holds also for simple functions. The difference is that now the integrand \[ \bigg( \bigotimes_{j=1}^r F\p j_k \otimes (F^{r+1}_k - F_\ell^{r+1}) \otimes \bigotimes_{i=r+2}^N F\p i_\ell\bigg )_{\bf s}\] is not bounded. However, because of \eqref{eq:approx.id.rule}, we can apply dominated convergence to get \eqref{tensor-Holder}. Clearly, we can identify the $L\p2(\Pbb)$-limit $Z$ of the corresponding Cauchy sequence $Z\p k$ as in \eqref{eq:id.lim.prod}. Because of the second step, $Z\p k$ satisfies \eqref{product-rule}. To complete the proof we verify that also for the general case we have the correct limit expression on the right hand side of \eqref{product-rule} and, hence, that the multiplication formula holds also for the limit $Z$. An estimate like \eqref{eq:est.cau.seq.it.int.fun} ensures that the addends on the right hand side of \eqref{product-rule} belong all to $L\p2(\Pbb)$ for any $F\p j\in L\p2(M_T\p{m_j},\rho\p{\al_{\overline m_{j-1}+1:\overline m_j}})$, $j=1,\dots,N$, such that \eqref{eq:gen.it.in.cond} holds. Hence, \eqref{integral-difference} follows from \eqref{eq:gen.it.in.cond} and \eqref{eq:approx.id.rule}, because of $|F\p j_k| \uparrow |F\p j|$ as $k\to\infty$, $j=1,\ldots,N$. This proves \eqref{product-rule} for the general case. To see \eqref{moment-formula}, because of \eqref{product-rule} and since each summand on the right-hand side of \eqref{product-rule} belongs to $L\p2(\Pbb)$, we can proceed as in the proof of Corollary \ref{cor:moment.formula}. The proof of the theorem is now complete. \end{proof} \begin{remark} \label{sufficient} A sufficient condition for \eqref{eq:gen.it.in.cond} is $$ F^j \in L\p{2N}(M_T\p{m_j}, \lm^{m_j}), \quad j=1,\ldots,N. $$ To see this, we recall that, from \eqref{s-rule}, to apply the identification rule ${\bf s}: H(u_1,\ldots,u_{\overline m_N}) \mapsto H_{{\bf s}}(t_1,\ldots,t_k)$, we need $H$ to depend on $u_1,\ldots,u_{\overline m_N}.$ Therefore, we extend each $F^j$ which depends on the variables $u_{\overline m_{j-1}+1},\ldots, u_{\overline m_{j}}$ constantly to all variables $u_1,\ldots,u_{\overline m_N}$ and denote the extension by $\widehat F^j(u_1,\ldots,u_{\overline m_N}).$ Since $$|S_\ell \cap \{u_{\overline m_{j-1}+1},\ldots, u_{\overline m_{j}}\}| \le 1, $$ the identification rule $$ {\bf s} : \widehat F^j(u_1,\ldots,u_{\overline m_N}) \mapsto \widehat F_{{\bf s}}^j(t_1,\ldots,t_{|{\bf s}|})$$ causes only a one-one {\it renaming} but no identification among the variables $u_{\overline m_{j-1}+1},\ldots, u_{\overline m_{j}}.$ We have $$ \bigg ( \bigotimes_{j=1}^{ N} F^j \bigg )_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) = (\widehat F^1)_{{\bf s}}(t_1,\ldots,t_{|{\bf s}|}) \times \ldots \times (\widehat F^N)_{{\bf s}} (t_1,\ldots,t_{|{\bf s}|}).$$ Consequently, by H\"older's inequality, \equa \int_{M_T^{|{\bf s}|}} \bigg ( \bigotimes_{j=1}^{ N} F^j \bigg )^2_{\bf s}(t_1,\ldots,t_{|{\bf s}|}) \rmd\lm( t_1,\ldots, t_{|{\bf s}|}) &\le & \prod_{j=1}^N \left ( \int_{M_T^{|{\bf s}|}} ( \widehat F^j )^{2N}_{\bf s} (t_1,\ldots,t_{|{\bf s}|}) \rmd\lm( t_1,\ldots, t_{|{\bf s}|}) \right )^\frac{1}{N} \\ &\le & \prod_{j=1}^N T^{|{\bf s}|-m_{j}} \left (\int_{M_T^{m_j}} ( F^j )^{2N}(t_1,\ldots, t_{m_{j}}) \rmd\lm(t_1,\ldots, t_{m_{j}}) \right )^\frac{1}{N}. \\ \tion \end{remark} \subsection{Examples for $\Xscr_\Lm$} We conclude this section giving examples of $\Xscr_\Lm$ satisfying the assumptions of Theorem \ref{thm:gen.it.in}. We observe that, if $\al\in L\p2(\mu)$, then the L\'evy measure $\nu\p \al$ of the square integrable martingale and $\Fbb$-L\'evy process $X\p \al$ is the image measure of $\nu$ under the mapping $\al$ (see \cite{Ba01}, Definition 7.6), that is, \begin{equation}\label{eq:le.m.en.mar} \nu\p \al(\rmd x)=(\nu\circ \al\p{-1})(\rmd x). \end{equation} The main point of this part is to construct families of martingales $\Xscr_\Lm$ possessing moments of every order. Because of the equivalence between the totality of a system $\Lm$ in $L\p2(\mu)$ and the CRP of the family $\Xscr_\Lm$, we will consider systems $\Lm$ which are total in $L\p2(\mu)$ or, more specifically, orthogonal bases of $L\p2(\mu)$. \paragraph*{Dyadic Intervals. } This example is very simple but it is interesting because it holds without further assumptions on the L\'evy measure. Let $X$ be a L\'evy process relative to $\Fbb$ and let $(\gm,\sig\p2,\nu)$ denote its characteristic triplet. Let $\Dscr$ denote the set of dyadic numbers and define \[ \tilde\Lm:=\big\{1_{(a,b]}1_{\{0\}}+1_{(a,b]}1_{\Rbb\setminus\{0\}},\ a,b\in\Dscr:\ 0\notin[a,b]\big\}\cup\{0\}. \] Then $\tilde\Lm$ is total in $L\p2(\mu)$, consists of countably many functions and satisfies Assumption \ref{ass:good.sys}. Clearly, we can orthonormalize $\tilde\Lm$ in $L\p2(\mu)$ and obtain an orthonormal basis $\Lm$ of $L\p2(\mu)$ consisting of bounded functions. The associated family $\Xscr_\Lm$ consists of countably many orthogonal martingales and it possesses the CRP with respect to $\Fbb\p X$ (cf.\ Proposition \ref{prop:con.sys}) in the simpler version of Remark \ref{rem:alt.rep.crp}. Furthermore, from Theorem \ref{thm:gen.it.in}, we get \eqref{product-rule} and \eqref{moment-formula} for the iterated integrals generated by $\Xscr_\Lm$. \paragraph*{Teugels martingales. } Teugels martingales were already discussed in \S\ref{subs:exa}. We notice that, to introduce Teugels martingales as square integrable martingales, it is enough that $X$ possesses moments of arbitrary order, that is, all monomials $p_n(x):=x\p n$ belong to $L\p2(\nu)$, for every $n\geq1$. We assume that there exist constants $\lm,\ep>0$ such that $x\mapsto1_{(-\ep,\ep)} \rme\p{\lm |x|/2} $ belongs to $L\p2(\nu)$ and define $h_1(x):=1_{\{0\}}+1_{\Rbb\setminus\{0\}}(x)p_1(x)$ and $h_n(x):=1_{\Rbb\setminus\{0\}}(x)p_n(x)$, $n\geq2$. The system $\tilde\Lm:=\{h_n,\ n\geq1\}$ belongs to $L\p2(\mu)$ and it is total. Furthermore, the identity $X\p{(i)}=X\p{h_i}$ holds, where $X\p{(i)}$ denotes the $i$th Teugels martingale as introduced in \S\ref{subs:exa}. The associated family $\Xscr_{\tilde\Lm}$ of Teugels martingales is compensated-covariation stable and, according to Proposition \ref{prop:con.sys} (ii), it possesses the CRP with respect to $\Fbb\p X$. However, the system $\tilde\Lm$ does not satisfy Assumption \ref{ass:good.sys} because it does not consist of bounded functions and it is not stable under multiplication. Let $\nu\p{h_n}$ be the L\'evy measure of the martingale $X\p{h_n}$. Then, from \eqref{eq:le.m.en.mar}, we get \[ \int_\Rbb |x|\p m\nu\p{h_n}(\rmd x)=\int_\Rbb |x|\p {m+n}\nu(\rmd x)<+\infty. \] Hence $\tilde\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu),$ and the family $\Xscr_{\tilde\Lm}$ is contained in $\bigcap_{p\geq2}\Hscr\p p$. From Theorem \ref{thm:gen.it.in} we get \eqref{product-rule} and \eqref{moment-formula} for the iterated integrals generated by $\Xscr_{\tilde\Lm}$. The family $\Xscr_{\tilde\Lm}$ is the family of Teugels martingales. We can orthonormalize ${\tilde\Lm}$ in $L\p2(\mu)$ to get an orthonormal system $\Lm$ consisting of polynomials. Therefore, the associated family of martingales $\Xscr_\Lm$ consists of countably many orthogonal martingales and satisfies the CRP with respect to $\Fbb\p X$ in the simpler form of Remark \ref{rem:alt.rep.crp}. Moreover, the product and the moment formula hold for the iterated integrals generated by $\Xscr_{\Lm}$. \paragraph*{Hermite polynomials. } Assume that $X$ is a L\'evy process with L\'evy measure $\nu$ which is equivalent to the Lebesgue measure on $\Rbb$, that is, \begin{equation}\label{def:eq.levy.meas} \nu(\rmd x)=h(x)\rmd x,\quad h(x)>0. \end{equation} This is, for example, the case if $X$ is an $\al$-stable L\'evy process (see \cite[Chapter 3]{S99}). In this case, if $(H_n)_{n\geq1}$ is the family of Hermite polynomials, setting $g(x):=(h(x))\p{-1/2}\rme\p{-x\p2/2}$, the family $\Lm:=\{P_n,\ n\geq1\}$, where $P_n:=1_{\{0\}}H_n(0)+1_{\Rbb\setminus\{0\}}gH_n$ is an orthogonal basis of $L\p2(\mu)$. However, in general, we cannot expect that the family $\Xscr_{\Lm}$ has moments of every order, that is, that the inclusion $\Lm\subseteq\bigcap_{p\geq2}L\p p(\mu)$ holds. From \eqref{eq:le.m.en.mar}, using the definition of $g$ and of Hermite polynomials (see \cite[\S1.1]{N06}) we see that \[ \int_{\Rbb\setminus\{0\}}|x|\p{2m}\nu\p{P_n}(\rmd x)=\frac{1}{n!}\,\int_{\Rbb\setminus\{0\}} \big(h(x)\big)\p{1-m}\rme\p{-mx\p2}|q_{2m+n}(x)|\rmd x \] where $q_n$ denotes a polynomial function of order $n$, $n\geq1$. Therefore, to ensure that $\Xscr_\Lm$ has finite moments of every order, we derive the condition on $h$ \begin{equation}\label{eq:con.h.Hp} \int_{\Rbb\setminus\{0\}} \big(h(x)\big)\p{1-m}\rme\p{-mx\p2}|x|^{2m+n}\rmd x<+\infty,\qquad \textnormal{\ for every\ } m,n\geq1. \end{equation} Hence, if $h$ satisfies \eqref{eq:con.h.Hp}, the moment formula \eqref{moment-formula} holds for the iterated integrals generated by the orthogonal family $\Xscr_\Lm$. Observe that $\al$-stable processes are an example of a family of L\'evy processes satisfying \eqref{eq:con.h.Hp}. We remark that, for an $\al$-stable L\'evy process $X$, the family $\Xscr_\Lm$ has finite moments of every order but the L\'evy process $X$ itself may possess infinite moments. This is the case, for example, if $X$ is a Cauchy process. \paragraph*{Haar basis. } We consider a L\'evy process $X$ with L\'evy measure $\nu$ as in \eqref{def:eq.levy.meas}. Let $\lm$ be the Lebesgue measure on $(\Rbb,\Bscr(\Rbb))$ and $\{\psi_{jk}:=2\p {\frac j2}\,\psi(2\p j\,x-k),\ x\in\Rbb,\ j,k\in\Zbb\}\subseteq L\p2(\lm)$ be the Haar basis. The generic element of the Haar basis can be written as \[ \textstyle\psi_{jk}(x):=2\p{\frac j2}\Bigl[1_{\left[\frac{k}{2\p{j}},\frac{2k+1}{2\p{j+1}}\right)}(x)-1_{\left[\frac{2k+1}{2\p{j+1}},\frac{k+1}{2\p{j}}\right)}(x)\Bigr] \] and its support is $\{\psi_{jk}\neq0\}=[\frac{k}{2\p{j}},\frac{k+1}{2\p{j}})$, $j,k\in\Zbb$. Note that the boundary points of these intervals are dyadic rational numbers. Defining $\Lm:=\{\psi_{jk}(0)1_{\{0\}}+1_{\Rbb\setminus\{0\}}h\p{-1/2}\psi_{jk},\ j,k\in\Zbb\}$ we obtain an orthogonal basis of $L\p2(\mu)$. The system $\Xscr_\Lm$ is a family of orthogonal martingales. In general, the martingales in $\Xscr_\Lm$ do not have finite moments of every order. Let us denote be $\nu\p{\psi_{jk}}$ the L\'evy measure of the martingales $X\p{\psi_{jk}}$. Then, from \eqref{eq:le.m.en.mar}, we get \[ \int_{\Rbb\setminus\{0\}} |x|\p{2m}\nu\p{\psi_{jk}}(\rmd x)=\int_{\Rbb\setminus\{0\}} (h(x))\p{1-m}|\psi_{jk}(x)|\p{2m}\nu(\rmd x). \] That is, we obtain the following condition on $h$ \begin{equation}\label{eq:con.h.Hw} \int_a\p b (h(x))\p{1-m}\nu(\rmd x)<+\infty,\qquad \textnormal{for all dyadic rational numbers }\ a\ \textnormal{and }\ b:\quad 0\notin[a,b]. \end{equation} Hence, if $h$ satisfies \eqref{eq:con.h.Hw}, we get \eqref{moment-formula} for the iterated integrals generated by $\Xscr_\Lm$. Notice that \eqref{eq:con.h.Hw} is satisfied, for example, if $h>0$ is bounded over all intervals whose extremes are dyadic rational numbers. We again find that if $X$ is an $\al$-stable L\'evy process, condition \eqref{eq:con.h.Hw} is satisfied. \paragraph{Acknowledgement.} PDT acknowledges Martin Keller-Ressel (TU Dresden) and funding from the German Research Foundation (DFG) under grant ZUK 64.
\section{Experiments} \subsection{Datasets} \begin{table}[!]\centering \begin{tabular}{|l|c|c|c|c|}\hline & Train & Dev. & Vocab. & Vocab. after BPE\\\hline En & 2,900 & 1,014 & 10,212 & 7,633 \\\hline De & 2,900 & 1,014 & 18,726 & 5,942 \\\hline Fr & 2,900 & 1,014 & 11,223 & 6,457 \\\hline Cs & 2,900 & 1,014 & 22,400 & 8,459 \\\hline \end{tabular} \caption{Statistics of Flickr30K Dataset} \label{tab:dataset} \end{table} We perform experiments using Flickr30K \cite{elliott:2016} which are provided by the WMT organization. Task 1 (Multimodal Machine Translation) consists of translating an image with an English caption into German, French and Czech. Task 1b (Multisource Multimodal Machine Translation) involves translating parallel English, German and French sentences with accompanying image into Czech. As shown in Table \ref{tab:dataset}, both tasks have 2900 training and 1014 validation examples. For preprocessing, we convert all of the sentences to lower case, normalize the punctuation, and tokenize. We employ byte-pair encoding (BPE) \cite{sennrich2015neural} on the whole training data including the four languages and reduce the source and target language vocabulary sizes to 20k in total. \subsection{Training details} The image feature is extracted using ResNet-101 \cite{kaiming:2016} convolutional neural network trained on the ImageNet dataset. Our implementation is adapted from Pytorch-based OpenNMT \cite{2017opennmt}. We use two layered bi-LSTM \cite{Sutskever:2014} as the encoder and share the vocabulary between the encoder and the decoder. We adopt length reward \cite{huang+:2017} on En-Cs task to find the optimal sentence length. We use a batch size of 50, SGD optimization, dropout rate as 0.1 and learning rate as 1.0. Our word embeddings are randomly initialized of dimension 500. To train the model with scheduled sampling, we first set probability $\epsilon$ as 0, and then gradually increase it 0.05 every 5 epochs until it's 0.25. The reinforcement learning models are trained based on those models pre-trained by scheduled sampling. \subsection{Results for task 1} \begin{table}[!]\centering \begin{tabular}{|l|c|c|c|}\hline & En-De & En-Fr & En-Cs \\\hline NMT & 39.64 & 58.36 & 31.27 \\\hline NMT+SS & 40.19 & 58.67 & 31.38 \\\hline NMT+SS+RL & 40.60 & 58.80 & 31.73 \\\hline MNMT & 39.27 & 57.92 & 30.84 \\\hline MNMT+SS & 39.87 & 58.80 & 31.21 \\\hline MNMT+SS+RL & 40.39 & 58.78 & 31.36 \\\hline NMT Ensemble & \bf{42.54} & 61.43 & \bf{33.15} \\\hline MIX Ensemble & 42.45 & \bf{61.45} & 33.11 \\\hline \end{tabular} \caption{BLEU scores of different approaches on the validation set. Details of the ensemble models are described in Table \ref{tab:ensemble}.} \label{tab:dev_results} \end{table} \begin{table}[b] \centering \resizebox{0.5\textwidth}{!}{ \begin{tabular}{|l|l|c|c|c|c|} \hline Task & System & NMT+SS & NMT+SS+RL & MNMT+SS & MNMT+SS+RL \\ \hline \multirow{2}{*}{En-De} & NMT & 7 & 6 & 0 & 0 \\ \cline{2-6} & MIX & 7 & 6 & 5 & 4 \\ \hline \multirow{2}{*}{En-Fr} & NMT & 9 & 5 & 0 & 0 \\ \cline{2-6} & MIX & 9 & 0 & 3 & 0 \\ \hline \multirow{2}{*}{En-Cs} & NMT & 7 & 6 & 0 & 0 \\ \cline{2-6} & MIX & 7 & 6 & 5 & 4 \\ \hline \end{tabular}} \caption{Number of different models used for ensembling.} \label{tab:ensemble} \end{table} To study the performance of different approaches, we conduct an ablation study. Table \ref{tab:dev_results} shows the BLEU scores on validation set with different models and training methods. Generally, models with scheduled sampling perform better than baseline models, and reinforcement learning further improves the performance. Ensemble models lead to substantial improvements over the best single model by about +2 to +3 BLEU scores. However, by including image information, MNMT performs better than NMT only on the En-Fr task with scheduled sampling. \begin{table}[!] \resizebox{0.5\textwidth}{!}{ \begin{tabular}{|l|c|c|c|c|}\hline & Rank & BLEU & METEOR & TER \\\hline OSU-BD-NMT & 1 & \bf{32.3} & 50.9 & 49.9 \\\hline OSU-BD-MIX & 2 & 32.1 & 50.7 & \bf{49.6} \\\hline LIUMCVC-MNMT-E& 3 & 31.4 & 51.4 & 52.1 \\\hline UMONS-DeepGru & 4 & 31.1 & \bf{51.6} & 53.4 \\\hline LIUMCVC-NMT-E & 5 & 31.1 & 51.5 & 52.6 \\\hline SHEF1-ENMT & 6 & 30.9 & 50.7 & 52.4 \\\hline Baseline & - & 27.6 & 47.4 & 55.2 \\\hline \end{tabular} } \caption{En-De results on test set. 17 systems in total. (Only including constrained models).} \label{tab:en_de_results} \end{table} \begin{table}[!] \resizebox{0.5\textwidth}{!}{ \begin{tabular}{|l|c|c|c|c|}\hline & Rank & BLEU & METEOR & TER \\\hline LIUMCVC-MNMT-E& 1 & \bf{39.5} & 59.9 & 41.7 \\\hline UMONS & 2 & 39.2 & \bf{60} & 41.8 \\\hline LIUMCVC-NMT-E & 3 & 39.1 & 59.8 & 41.9 \\\hline OSU-BD-NMT & 4 & 39.0 & 59.5 & \bf{41.2} \\\hline SHEF-MLT & 5 & 38.9 & 59.8 & 41.5 \\\hline OSU-BD-MIX & 9 & 38.6 & 59.3 & 41.5 \\\hline Baseline & - & 28.6 & 52.2 & 58.8 \\\hline \end{tabular} } \caption{En-Fr results on test set. 14 systems in total. (Only including constrained models).} \label{tab:en_fr_results} \end{table} \begin{table}[!] \resizebox{0.5\textwidth}{!}{ \begin{tabular}{|l|c|c|c|c|}\hline & Rank & BLEU & METEOR & TER \\\hline OSU-BD-NMT & 1 & \bf{30.2} & 29.5 & \bf{50.7} \\\hline OSU-BD-MIX & 2 & 30.1 & \bf{29.7} & 51.2 \\\hline SHEF1-ENMT & 3 & 29.0 & 29.4 & 51.1 \\\hline SHEF-LT & 4 & 28.3 & 29.1 & 51.7 \\\hline SHEF-MLT & 5 & 28.2 & 29.1 & 51.7 \\\hline SHEF1-MFS & 6 & 27.8 & 29.2 & 52.4 \\\hline Baseline & - & 26.5 & 27.7 & 54.4 \\\hline \end{tabular} } \caption{En-Cs results on test set. 8 systems in total. (Only including constrained models).} \label{tab:en_cs_results} \end{table} Table \ref{tab:en_de_results}, \ref{tab:en_fr_results} and \ref{tab:en_cs_results} show the test set performance of our models on En-De, En-Fr and En-Cs subtasks with other top performance models. We rank those models according to BLEU. Our submitted systems rank first in BLEU and TER on En-De and En-Cs subtasks. \subsection{Results for task 1B} \begin{table}[!]\centering \resizebox{0.5\textwidth}{!}{ \begin{tabular}{|l|c|c|c|c|}\hline & En-Cs & Fr-Cs & De-Cs & (En+Fr+De)-Cs \\\hline NMT & \bf{31.27} & 28.48 & 26.96 & 29.47 \\\hline MNMT & 30.84 & 27.02 & 25.99 & 29.23 \\\hline \end{tabular} } \caption{BLEU scores on validation set for task 1B} \label{tab:1b_results} \vspace{-5.0mm} \end{table} \begin{table}[!]\centering \resizebox{0.5\textwidth}{!}{ \begin{tabular}{|l|c|c|c|c|}\hline & Rank & BLEU & METEOR & TER \\\hline OSU-BD-NMT & 1 & \bf{26.4} & 28.0 & \bf{52.1} \\\hline OSU-BD-MIX & 1 & \bf{26.4} & \bf{28.2} & 52.7 \\\hline SHEF1-ARNN & 3 & 25.2 & 27.5 & 53.9 \\\hline SHEF-CON & 4 & 24.7 & 27.6 & \bf{52.1} \\\hline SHEF-MLTC & 5 & 24.5 & 27.5 & 52.5 \\\hline SHEF1-ARF & 6 & 24.1 & 27.1 & 54.6 \\\hline Baseline & - & 23.6 & 26.8 & 54.2 \\\hline \end{tabular} } \caption{Task 1B multi-source translation results on test set. 6 systems in total.} \label{tab:1b_test_results} \end{table} Table \ref{tab:1b_results} shows the results on validation set without sequence training. En-Cs, Fr-Cs, De-Cs are models trained from one language to another. (En+Fr+De)-Cs models are trained using multiple source data. Similar to the Shuffle method discussed in multi-reference training \cite{zheng2018multi}, we randomly shuffle the source data in all languages and train using a traditional attention based-neural machine translation model in every epoch. Since we do BPE on the whole training data, we can share the vocabulary of different languages during training. The results show that models trained using single English to Czech data perform much better than the rest. Table \ref{tab:1b_test_results} shows results on test set. The submitted systems are the same as those used in En-Cs task of task 1. Although we only consider the English source during training, our proposed systems still rank first among all the submissions. \begin{table}[tb] \centering \resizebox{0.5\textwidth}{!}{ \begin{tabular}{|l|l|c|c|c|c|c|c|c|c|} \hline \multirow{2}{*}{Task}&\multirow{2}{*}{System} & \multicolumn{4}{c|}{Model Rank} &\multicolumn{4}{c|}{Team Rank} \\ \cline{3-10} & & Num $^\dagger$ & BLEU & MET. & TER & Num $^\ddagger$ & BLEU & MET. & TER \\ \hline \multirow{2}{*}{En-De} & NMT & 11 & 1 & 4 & 2&\multirow{2}{*}{5}&\multirow{2}{*}{1}&\multirow{2}{*}{3}&\multirow{2}{*}{1}\\ \cline{2-6} & MIX & 11 & 2 & 5 & 1& & & & \\ \hline \multirow{2}{*}{En-Fr} & NMT & 11 & 4 & 9 & 1&\multirow{2}{*}{6}&\multirow{2}{*}{3}&\multirow{2}{*}{5}&\multirow{2}{*}{1} \\ \cline{2-6} & MIX & 11 & 9 & 10 & 3& & & & \\ \hline \multirow{2}{*}{En-Cs} & NMT & 6 & 1 & 1 & 1 &\multirow{2}{*}{3}&\multirow{2}{*}{1}&\multirow{2}{*}{1}&\multirow{2}{*}{1}\\ \cline{2-6} & MIX & 6 & 2 & 2 & 3 & & & & \\ \hline En-Cs&NMT&6&1& 2&1&\multirow{2}{*}{3}&\multirow{2}{*}{1}&\multirow{2}{*}{1}&\multirow{2}{*}{1}\\ \cline{2-6} (1B) & MIX &6&1& 1 & 5& & & & \\ \hline \end{tabular}} \caption{Rank of our models. $^\dagger$ represents the total number of models. $^\ddagger$ represents the total number of teams.} \label{tab:ensemble} \vspace{-5.0mm} \end{table} \section{Introduction} In recent years, neural text generation has attracted much attention due to its impressive generation accuracy and wide applicability. In addition to demonstrating compelling results for machine translation \cite{Sutskever:2014, Bahdanau:14}, by simple adaptation, similar models have also proven to be successful for summarization \cite{Rush:15,Nallapati:16}, image or video captioning \cite{Venu:15,Kelvin:15} and multimodal machine translation \cite{elliott2017findings, caglayan2017lium,calixto2017incorporating,ma2017osu}, which aims to translate the caption from one language to another with the help of the corresponding image. However, the conventional neural text generation models suffer from two major drawbacks. First, they are typically trained by predicting the next word given the previous ground-truth word. But at test time, the models recurrently feed their own predictions into it. This ``exposure bias'' \cite{ranzato2015sequence} leads to error accumulation during generation at test time. Second, the models are optimized by maximizing the probability of the next ground-truth words which is different from the desired non-differentiable evaluation metrics, e.g.~BLEU. Several approaches have been proposed to tackle the previous problems. \cite{bengio2015scheduled} propose scheduled sampling to alleviate ``exposure bias'' by feeding back the model's own predictions with a slowly increasing probability during training. Furthermore, reinforcement learning \cite{sutton1998reinforcement} is proven to be helpful to directly optimize the evaluation metrics in neural text generation models training. \cite{ranzato2015sequence} successfully use the REINFORCE algorithm to directly optimize the evaluation metric over multiple text generation tasks. \cite{rennie2017self, liu2017improved} achieve state-of-the-art on image captioning using REINFORCE with baseline to reduce training variance. Moreover, many existing works show that neural text generation models can benefit from model ensembling by simply averaging the outputs of different models \cite{elliott2017findings,rennie2017self}. \cite{garmash2016ensemble} claim that it is essential to introduce diverse models into the ensemble. To this end, we ensemble models with various architectures and training methods. This paper describes our participation in the WMT 2018 multimodal tasks. Our submitted systems include a series of models which only consider text information, as well as multimodal models which also include image information to initialize the decoders. We train these models using scheduled sampling and reinforcement learning. The final outputs are decoded by ensembling those models. To the best of our knowledge, this is the first multimodal machine translation system that achieves the state-of-the-art using sequence level learning methods. \section{Conclusions} We describe our systems submitted to the shared WMT 2018 multimodal translation tasks. We use sequence training methods which lead to substantial improvements over strong baselines. Our ensembled models achieve the best performance in BLEU score for three subtasks: En-De, En-Cs of task 1 and (En+De+Fr)-Cs task 1B. \section*{Acknowledgments} This work was supported in part by DARPA grant N66001-17-2-4030, and NSF grants IIS-1817231 and IIS-1656051. We thank the anonymous reviewers for suggestions and Juneki Hong for proofreading. \section{Methods} Our model is based on the sequence-to-sequence RNN architecture with attention \cite{Bahdanau:14}. We incorporate image features to initialize the decoder's hidden state as shown in Figure \ref{fig:model}. Originally, this hidden state is initialized using the concatenation of last encoder's forward and backward hidden states, $\overrightarrow{h_e}$ and $\overleftarrow{h_e}$ resp. We propose to use the sum of encoder's output and image features $h_{\text{img}}$ to initialize the decoder. Formally, we have the final initialization state $h_d$ as: \begin{equation} h_d = \tanh(W_{e}[\overrightarrow{h_e}; \overleftarrow{h_e}] + W_{\text{img}} h_{\text{img}} + b) . \end{equation} where $W_{e}$ and $W_{\text{img}}$ project the encoder and image feature vector into the decoder hidden state dimensionality and $b$ is the bias parameter. This approach has been previously explored by \cite{calixto2017incorporating}. \begin{figure} \includegraphics[width=0.5\textwidth]{img/model2.pdf} \caption{Multimodal Machine Translation Model} \label{fig:model} \end{figure} As discussed previously, translation systems are traditionally trained using cross entropy loss. To overcome the discrepancy between training and inference distributions, we train our models using scheduled sampling \cite{bengio2015scheduled} which mixes the ground truth with model predictions, further adopting the REINFORCE algorithm with baseline to directly optimize translation metrics. \subsection{Scheduled Sampling} When predicting a token $\hat{y}_t$, scheduled sampling uses the previous model prediction $\hat{y}_{t-1}$ with probability $\epsilon$ or the previous ground truth prediction $y_{t-1}$ with probability $1 - \epsilon$. The model prediction $\hat{y}_{t-1}$ is obtained by sampling a token according to the probability distribution by $P(y_{t-1}|h_{t-1})$. At the beginning of training, the sampled token can be very random. Thus, the probability $\epsilon$ is set very low initially and increased over time. One major limitation of scheduled sampling is that at each time step, the target sequences can be incorrect since they are randomly selected from the ground truth data or model predictions, regardless of how input was chosen \cite{ranzato2015sequence}. Thus, we use reinforcement learning techniques to further optimize models on translation metrics directly. \subsection{Reinforcement Learning} Following \cite{ranzato2015sequence} and \cite{rennie2017self}, we use REINFORCE with baseline to directly optimize the evaluation metric. According to the reinforcement learning literature \cite{sutton1998reinforcement}, the neural network, $\theta$, defines a policy $p_{\theta}$, that results in an ``action'' that is the prediction of next word. After generating the end-of-sequence term (EOS), the model will get a reward $r$, which can be the evaluation metric, e.g. BLEU score, between the golden and generated sequence. The goal of training is to minimize the negative expected reward. \begin{equation} L(\theta)= - \mathbb{E}_{w^s \sim p_{\theta}} \left[ r(w^s)\right]. \end{equation} where sentence $w^s = (w_1^s, ..., w_T^s)$. In order to compute the gradient $\nabla_{\theta}L(\theta)$, we use the REINFORCE algorithm, which is based on the observation that the expected gradient of a non-differentiable reward function can be computed as follows: \begin{equation} \nabla_{\theta}L(\theta)= - \mathbb{E}_{w^s \sim p_{\theta}} \left[ r(w^s) \nabla_{\theta} \log p_{\theta}(w^s) \right]. \end{equation} The policy gradient can be generalized to compute the reward associated with an action value \emph{relative} to a reference reward or \emph{baseline} $b$: \begin{equation} \nabla_{\theta}L(\theta)= - \mathbb{E}_{w^s \sim p_{\theta}} \left[ (r(w^s)- b ) \nabla_{\theta} \log p_{\theta}(w^s)\right]. \end{equation} The baseline does not change the expected gradient, but importantly, it can reduce the variance of the gradient estimate. We use the baseline introduced in \cite{rennie2017self} which is obtained by the current model with greedy decoding at test time. \begin{equation} b=r(\hat{w^s}) \end{equation} where $\hat{w^s}$ is generated by greedy decoding. For each training case, we approximate the expected gradient with a single sample $w^s\sim p_{\theta}$: \begin{equation} \nabla_{\theta}L(\theta)\approx- (r(w^s)-b) \nabla_{\theta} \log p_{\theta}(w^s). \label{eq:zerobiasGradientSample} \end{equation} \subsection{Ensembling} In our experiments with relatively small training dataset, the translation qualities of models with different initializations can vary notably. To make the performance much more stable and improve the translation quality, we ensemble different models during decoding to achieve better translation. To ensemble, we take the average of all model outputs: \begin{equation} \hat{y_t} = \sum_{i = 1}^N {\hat{y^i_t} \over N} \end{equation} where $\hat{y^i_t}$ denotes the output distribution of $i$th model at position $t$. Similar to \cite{zhou2017neural}, we can ensemble models trained with different architectures and training algorithms.
\section{Introduction} \label{sec:Sec1} In current theoretical physics and cosmology, some of the unsolved fundamental problems include (i) the construction of a consistent field theory without ultraviolet divergences; (ii) the identification of dark matter; (iii) revealing the origin of the cosmological constant; and (iv) the removal of the quadratic divergence of Higgs self-energy. A Poincar\'e covariant field theory without ultraviolet divergences was formulated \cite{Fuku84,Fuku14,Fuku16,Fuku17,Fuku18} by dividing the space-time continuum into irregular hyper-octahedra, hyper-octahedra with straight lines and flat surfaces that are deformed into curves and curved surfaces containing a space-like hyper-surface, or orthoplexes implying space-time quantization. At present, this theory is regarded as a fundamental principle, with the ultraviolet cut-off energy as a fundamental constant. It will depend on the stage of science development, and particularly on the experimentally achievable energy level, as to whether this principle can be derived from a more fundamental theory beyond the cut-off energy. The present formalism \cite{Fuku84,Fuku17} is based on the finite element method \cite{FemMW}, which is widely used and well-posed in the continuum limit. Each orthoplex in the Minkowski space-time continuum or its Euclidean Wick rotation is mapped to a hyper-cube in a parameter space \cite{Fuku84,Fuku17}, and this one-to-one map has a non-vanishing Jacobian due to the non-existence of point particles. Fields are expressed in terms of localized step-function-type basis functions, defined on this hyper-cube. The basis function is scalar \cite{Fuku84,Fuku17}, and is multiplied by a coefficient which is a scalar, vector or tensor depending on the corresponding field type. Each integrable step-function-type basis function is the indicator function of an orthoplex, with a value of one within in the orthoplex and zero elsewhere, and the action has the same integral continuum limit as in It has beencontinuum theory. The derivatives of these functions can be expressed in terms of the Dirac delta function. This formalism in the tangent space of the curved space-time continuum is transformed to another coordinate system without difficulty. In the present formalism with quantized space-time elements, fields propagate in the space-time continuum with restricted degrees of freedom. \par To ensure the consistency of general relativity with field theory, the subtracted mass term, with divergent ultraviolet properties in the renormalization \cite{Weiss,Weiss39,Tomo46,Tomo48,Schwin,Feyn,Dys}, is included into the cosmological constant $\Lambda$ \cite{Eins,Fried,Carr92,Carr01,Carr04,Riess,Baker,Perl,Peeb,Padman,Tegm,Lomb,Barr,Rugh,Hobs,Wein,Leut}. Since it was shown in Ref. \cite{Fuku18} that zero-point energies do not exist in the expanding universe due to a lack of periodicity at boundaries, the cosmological constant $\Lambda$ in the present quantized space-time element formalism contains only the self-energy predominantly contributed by the quadratic Higgs term. The expanding universe treated in this paper has the boundary condition that fields do not exist outside of the expanding universe. Consequently, the Higgs self-energy, containing the cut-off energy, determines the ultraviolet cut-off energy (and length). The present formalism thus gives a possible solution to the current four problems mentioned at the beginning of this section. We add that the dark matter in the problem (ii) may be the chromodynamical vacuum, as described in \cite{Fuku18}. The ultraviolet cut-off energy, which is determined theoretically from the present quantized space-time element theory by mapping the theory to the continuum theory with the corresponding cut-off energy, is in a regime around $3$ PeV. Meanwhile, the ultraviolet cut-off energy of the present theory is much higher than experimental accelerator energies, which are about $10^4$ GeV at present. \par This paper therefore aims to explore a possible relation between the present quantized space-time element theory and the features of the cosmic-ray energy spectrum. The ultraviolet cut-off energy is first examined in detail, considering the structure of the main composition of a proton with the help of current particle data for up and down quarks, as well as the corresponding cosmological data for the dark matter and vacuum energy expressed by the cosmological constant $\Lambda$. In the present analysis of the experimental data, the ultraviolet cut-off energy in Minkowski space is distinguished from that in Wick-rotated (Euclidean) space. This study subsequently precisely predicts the ultraviolet cut-off energy using the present quantized space-time element theory, and focuses on the relation between the predicted cut-off energy of about $3$ PeV and experimental data for the cosmic-ray energy spectrum. It is found from the literature that the experimentally observed energy spectrum of the cosmic-ray flux per unit energy shows a break, called a 'knee', at a corresponding energy of about 3 PeV. Thus, cosmic rays decay in the form of a power law $(E_{\rm c})^{-s}$ with $s$ being the spectral index as the cosmic-ray energy $E_{\rm c}$ increases, showing a greater decline above the knee energy. It is found that this theoretical cut-off energy coincides with the experimental value for the knee energy at which a break in the energy spectrum of cosmic rays occurs. \par The origin of the cosmic rays with energies of less than about $1 \times 10^{15}$ eV is understood from astrophysical studies. In contrast, in the case of a reduction in observable events at energies higher than the knee energy, the acceleration mechanisms and the origin of cosmic-ray composite particles are unclear. If the energy of the basis functions contributes to the energy spectrum by analogy with solid state physics, this contribution may emerge in the form of tail energies beyond the cut-off energy. The basis functions employed here reproduce the energy spectrum, with an increased slope between the ultraviolet cut-off energy at the knee and an energy of about $3 \times 10^{18}$ eV, called the ankle, and also the spectrum with a decreased slope above the ankle energy. It is found that the diffuse scattering of cosmic rays from the disordered lattice of the space-time elements can cause the knee. If other explanations have clear inconsistencies, the corresponding theories will be ruled out. In the theory proposed in this paper, space-time elements of an arbitrary-shaped orthoplex derived by dividing the space-time continuum form a somewhat disordered lattice. By analogy to the diffuse scattering of a wave function from a disordered lattice in solid state physics, cosmic rays will be scattered by the disordered lattice of the space-time elements. Then, the scattering probability of a light particle is larger than that of a heavy particle, as is shown in Section \ref{sec:Sec3}. High scattering probabilities give rise to the deviation of cosmic-ray particles from a straight trajectory towards the Earth. This diffuse scattering causes the spectrum break of cosmic rays at the ultraviolet cut-off energy (knee energy) with a fall-off of light particles. Above the knee energy, the high scattering probabilities of neutrinos and photons cause large losses of these particles as they propagate towards the Earth. The results derived from the theory of this paper are consistent with the experimental data, in neutrinos and gamma rays are not observed at energies above about the knee energy \cite{Aartsen}. It was initially expected \cite{Yoshida} that neutrinos beyond the knee energy would be detected, because neutrinos and gamma rays were thought to be produced by collisions between cosmic rays and the cosmic microwave background (CMB) at ultra-high energies around the Greisen-Zatsepin-Kazumin (GZK) limit of $5 \times 10^{19}$ eV \cite{Greisen,Zatsepin}, resulting in that neutrinos would propagate and reach the Earth due to the extremely weak interactions between neutrinos and interstellar particles. \par Furthermore, if the distribution of the cut-off energy caused by the arbitrary shape of the space-time elements is accepted, an additional contribution might be added to the energy spectrum above the cut-off energy. The energy spectrum below the ultraviolet cut-off energy at the knee is understood as the diffusive shock acceleration (DSA) by astrophysical studies in this area, with a spectral index $s=2$ for the slope due to innergalactic remnants of a supernova (star explosion) \cite{Bella,Bellb,Blandford78,Blandford,Drury} and other additional mechanisms that increase the spectral index \cite{Jokipii82,Jokipii87,Drury,Drury81,Ellison96,Bell11}. An investigation of the origin of the spectrum in this low-energy regime is not the main objective of this article. Instead, this paper adds a view from a theoretical trial study of the spectrum-slope enhancement in this regime, using Fourier deconvolution/convolution. Below the cut-off energy, a certain contribution to the increase in the spectral index from 2 may be due to the dependence of the acceleration rate on the evolution time, since the acceleration rate is a function of the mean velocity of the shock wave, which is expressed in terms of the evolution time. Other mechanisms such as the interstellar diffusion, which is different from the DSA, may also contribute to the increase in the slope. \par This article is organized as follows. Section \ref{sec:Sec2} describes the ultraviolet cut-off energy, as derived from the present quantized space-time element theory. Section \ref{sec:Sec3} then compares the theoretical ultraviolet cut-off energy with experimental cosmic ray data. The basis functions employed by the present theory that lead to diffuse scattering are shown to reproduce the energy spectrum and the loss of neutrinos and photons above the ultraviolet cut-off energy, followed by conclusions in Section \ref{sec:Sec4}. (Regarding the energy spectrum below the cut-off energy, a view from a trial study is presented in Appendix using Fourier deconvolution/convolution.) \section{Formalism of the ultraviolet cut-off energy} \label{sec:Sec2} In Refs. \cite{Fuku84,Fuku14,Fuku16,Fuku17,Fuku18}, a Poincar\'e covariant field theory without ultraviolet divergences was formulated. This formalism divides the space-time continuum into space-time elements, namely orthoplexes with individual arbitrary shapes. Fields such as $\psi(x)$ are expressed in terms of localized step-function-type basis functions of the form ${\tilde{\Omega}}^{4}_{p}(x)$, for example in four dimensions: \begin{eqnarray} \label{eqn:Fexp} \psi (x)=\sum_p \psi_{p}{\tilde{\Omega}}^{4}_{p}(x), \end{eqnarray} where the time and space coordinates are denoted as $x=(x^0,x^1,x^2,x^3)=(ct,x,y,z)$, with $c$ being the velocity of light \cite{BJDR}. Each basis function with index $p$ has a value of one (unity) within the individual space-time elements such as orthoplexes, and vanishes outside of this element. In this formalism, fields propagate in the space-time continuum with restricted degrees of freedom. Among electromagnetic, weak and strong interactions, the leading self-energy is the quadratic Higgs term. We are concerned with the relation between this self-energy and general relativity, described by the following Einstein field equations \cite{LanL} with $\mu, \nu=0,1,2,3$ \begin{eqnarray} \label{eqn:Eeq} R_{\mu\nu}-\frac{1}{2}g_{\mu\nu}R=\frac{8\pi G}{c^4} T_{\mu\nu}. \end{eqnarray} Here, $G$ is the gravitational constant; $T_{\mu\nu}$ is the energy-momentum tensor; and $g_{\mu\nu}$ is the metric tensor, whose special form for Minkowski space is given by \begin{eqnarray} \label{eqn:metr} g_{\mu \nu}= \left[\begin{array}{cccc} 1 & 0 & 0 & 0 \\ 0 & -1 & 0 & 0 \\ 0 & 0 & -1 & 0 \\ 0 & 0 & 0 & -1 \\ \end{array}\right]. \end{eqnarray} In Eq. (\ref{eqn:Eeq}), the scalar curvature $R$ is sequentially defined from the Riemann curvature tensor $R^{\rho}_{\mu \rho \nu}$ as follows: \begin{eqnarray} \label{eqn:CurT} R_{\mu \nu}=R^{\rho}_{\mu \rho \nu}, \end{eqnarray} \begin{eqnarray} \label{eqn:SCurv} R=g^{\mu \nu} R_{\mu \nu}. \end{eqnarray} \par We expressed the mass term with the ultraviolet divergence, and in the renormalization this term is subtracted from the Hamiltonian in the form \begin{eqnarray} \label{eqn:Smtm} T^{(\rm S)}_{\mu\nu}=\frac{c^4}{8\pi G}g_{\mu\nu}\Lambda^{(\rm S)}. \end{eqnarray} To ensure the consistency of general relativity with field theory, the subtracted mass term in Eq. (\ref{eqn:Smtm}) is explicitly expressed in the Einstein field equations in Eq. (\ref{eqn:Eeq}), giving \begin{eqnarray} \label{eqn:EeqR} R_{\mu\nu}-\frac{1}{2}g_{\mu\nu}R=\frac{8\pi G}{c^4} \left( T_{\mu\nu}-T^{(\rm S)}_{\mu\nu} \right). \end{eqnarray} Using Eq. (\ref{eqn:Smtm}), the above equations are rewritten as \begin{eqnarray} \label{eqn:EeqL} R_{\mu\nu}-\frac{1}{2}g_{\mu\nu}R+ g_{\mu\nu} \Lambda^{(\rm S)} =\frac{8\pi G}{c^4}T_{\mu\nu}, \end{eqnarray} which implies that $\Lambda^{(\rm S)}$ can be regarded as the cosmological (vacuum energy) constant $\Lambda$, yielding \begin{eqnarray} \label{eqn:EeqLam} R_{\mu\nu}-\frac{1}{2}g_{\mu\nu}R+ g_{\mu\nu} \Lambda=\frac{8\pi G}{c^4} T_{\mu\nu}. \end{eqnarray} \par In Ref. \cite{Fuku18}, the cosmological constant was related to the quadratic Higgs self-energy, which is larger than the other self-interactions in the electromagnetic, strong and weak interactions. In the present quantized space-time element theory, gravity is weak due to the small cut-off energy compared to the Planck energy. In \cite{Fuku18}, it was shown that zero-point energies cannot exist, due to the inconsistency with a lack of periodicity at the boundaries of the expanding universe. Since the main component of baryonic matter is protons in hydrogen, the dominant contributions to the Higgs self-energy are loops of fermions (up and down quarks) interacting with the Higgs field. The squares of the self-energy of the Higgs field in natural units with $\hbar=1, c=1$, where $\hbar$ is the reduced Planck constant and $c$ is the velocity of light, is written by \begin{eqnarray} \label{eqn:SEHg} |E_{\rm H}|^2=\frac{1}{8\pi^2} (|\lambda_{\rm u}|^2+|\lambda_{\rm u}|^2+|\lambda_{\rm d}|^2) \left( \Delta^{(\rm E)}_{\rm E} \right)^2, \end{eqnarray} where $\Delta^{(\rm E)}_{\rm E}$ is the Euclidean ultraviolet cut-off energy, and $\lambda_{\rm u}$ and $\lambda_{\rm d}$ are the coupling constants of the Higgs field with up and down quarks, respectively, given by \begin{eqnarray} \label{eqn:lambud} \lambda_{\rm u}=\frac{\sqrt{2}}{v}m_{\rm u}, \hspace{4ex} \lambda_{\rm d}=\frac{\sqrt{2}}{v}m_{\rm d}. \end{eqnarray} Here, $m_{\rm u}$ and $m_{\rm d}$ are the masses of the up and down quarks, respectively, and $v$ is the vacuum expectation value of the Higgs field after symmetry breaking. \par The vacuum energy, which is measured by the proton energy, is expressed in terms of the cosmological constant $\Lambda$ as \begin{eqnarray} \label{eqn:EVauL} E_{\Lambda}= \frac{\Omega_{\Lambda}}{\Omega_{\rm m}} m_{\rm p}, \end{eqnarray} where $m_{\rm p}$ is the proton mass energy, and $\Omega_{\rm m}$ and $\Omega_{\Lambda}$ are the fractions of matter energy and vacuum energy (expressed by the cosmological constant $\Lambda$) in the total energy of the universe, respectively. Symbols such as $\Omega_{\rm m}$ are fractions of the total energy of the universe in this paper, whereas usually they are fractions of the critical density. Since the former quantities have the same values as the latter, identical symbols are used for both in this paper. It is well known that the masses of the three quarks composing a proton with mass $m_{\rm p}$ are quite small. Using $m_{\rm u}$ and $m_{\rm d}$, the following ratio can be defined: \begin{eqnarray} \label{eqn:Pfra} \gamma_{\rm P}=\frac{ m_{\rm p} }{m_{\rm u}+m_{\rm u}+m_{\rm d}}. \end{eqnarray} Then, Eq. (\ref{eqn:EVauL}) is rewritten as \begin{eqnarray} \label{eqn:EVPfra} E_{\Lambda}= \frac{\Omega_{\Lambda}}{\Omega_{\rm m}} \gamma_{\rm P}(m_{\rm u}+m_{\rm u}+m_{\rm d}). \end{eqnarray} By equating $E_{\Lambda}$ in Eq. (\ref{eqn:EVPfra}) to $E_{\rm H}$ in Eq. (\ref{eqn:SEHg}) and using Eqs. (\ref{eqn:lambud})$-$(\ref{eqn:Pfra}), it follows that \begin{eqnarray} \label{eqn:EqEHL} \nonumber \frac{1}{2\pi v} (m_{\rm u}^2+m_{\rm u}^2+m_{\rm d}^2)^{1/2} \Delta^{(\rm E)}_{\rm E} \end{eqnarray} \begin{eqnarray} =\frac{\Omega_{\Lambda}}{\Omega_{\rm m}} \gamma_{\rm P}(m_{\rm u}+m_{\rm u}+m_{\rm d}), \end{eqnarray} and we derive the following theoretical Euclidean cut-off energy \begin{eqnarray} \label{eqn:ECO} \Delta^{(\rm E)}_{\rm E}= (2\pi v) \frac{\Omega_{\Lambda}}{\Omega_{\rm m}} \gamma_{\rm P} \frac{(m_{\rm u}+m_{\rm u}+m_{\rm d})} {(m_{\rm u}^2+m_{\rm u}^2+m_{\rm d}^2)^{1/2}}. \end{eqnarray} \par The above ultraviolet cut-off energy is generally used in Euclidean space, and is obtained from an analytic continuation with Wick rotation from Minkowski space. The energy in Minkowski space $E_{\rm M}$ is replaced by $E_{\rm E}$, and the absolute value of the cut-off energy $|\Delta^{(\rm E)}_{\rm E}|$ in Euclidean space may be equal to the cut-off energy $\Delta^{(\rm E)}_{\rm M}$ in Minkowski space. Despite this expectation value for the cut-off energy, the following possibility is deduced for the ultraviolet cut-off energy in Minkowski space. The energy in Minkowski space is written as \begin{eqnarray} \label{eqn:EMin} E_{\rm M}=[(m_0)^2+|{\bf p}|^2]^{(1/2)}, \end{eqnarray} where $m_0$ is the rest mass and ${\bf p}$ is the three-dimensional momentum, while the squared length of the four-vector composed of Euclidean energy and momentum becomes \begin{eqnarray} \label{eqn:EEuc} (E_{\rm E})^2=(E_{\rm M})^2+{|\bf p}|^2=(m_0)^2+2|{\bf p}|^2. \end{eqnarray} For large kinetic energies with corresponding large $|{\bf p}|$, this equation is approximated as \begin{eqnarray} \label{eqn:EEuMi} (E_{\rm E})^2 \approx 2(E_{\rm M})^2, \end{eqnarray} yielding \begin{eqnarray} \label{eqn:EMiEu} E_{\rm M} \approx (1/\sqrt{2})E_{\rm E}. \end{eqnarray} We then set \begin{eqnarray} \label{eqn:DEMiEu} \Delta^{(\rm E)}_{\rm M}=(1/\sqrt{2})\Delta^{(\rm E)}_{\rm E}, \end{eqnarray} for the ultraviolet cut-off energies $\Delta^{(\rm E)}_{\rm M}$ and $\Delta^{(\rm E)}_{\rm E}$ for Minkowski and Euclidean spaces, respectively. \par This section now gives an additional description of the ultraviolet cut-off length. Figure \ref{fig:fig1} shows the wave function in terms of the step-function-type basis functions for the $x$ coordinate. The one-dimensional space continuum is divided into space elements of the region $ka-(a/2) \leq x < ka+(a/2) $, where $a$ is the lattice spacing with $k=1,2,3,\cdot\cdot\cdot$, and lattice points are located at $ka$. A one-dimensional step-function-type basis function is defined by \begin{eqnarray} \nonumber \label{eqn:BasD} {\tilde{\Omega}}^{E}_{k}(x) = \left\{\begin{array}{ll} 1 & \mbox{ for $ka-(a/2) \leq x < ka+(a/2)$} \\ \mbox{ } & \mbox{ } \\ 0 & \mbox{ for $x < ka-(a/2)$ or $x \geq ka+(a/2)$} \end{array}\right. . \end{eqnarray} \begin{eqnarray} \end{eqnarray} It is noted that the above basis function is a kind of indicator function for elements of a set in the Riemann integral extended by the Lebesgue integral, and is therefore integrable. While this basis function is not differentiable in the usual sense, it is in terms of the Dirac delta function. The wave function $\psi(x)$ is expressed in terms of the basis functions in Eq. (\ref{eqn:BasD}) as follows: \begin{eqnarray} \label{eqn:BasE} \psi(x)=\sum_k \psi_k {\tilde{\Omega}}^{E}_k (x). \end{eqnarray} The wave function is constant within the region of each space element. Figure \ref{fig:fig1} shows that an elementary wave such as a sine wave in the quantized space needs at least four lattice points. \par \begin{figurehere} \begin{center} \setlength{\unitlength}{1 mm} \begin{picture}(60,60)(-10,-15) \put( 0, 0) {\vector(1, 0){48}} \put( 0, 0) {\vector(0, 1){40}} \put( 0, 10) {\line(1, 0){2}} \put( 0, 20) {\line(1, 0){2}} \put( 0, 30) {\line(1, 0){2}} \put( 8, 0) {\line(0, 1){2}} \put(16, 0) {\line(0, 1){2}} \put(24, 0) {\line(0, 1){2}} \put(32, 0) {\line(0, 1){2}} \put(40, 0) {\line(0, 1){2}} \linethickness{3pt} \put( 4, 20) {\line(1,0){8}} \put(12, 30) {\line(1,0){8}} \put(20, 20) {\line(1,0){8}} \put(28, 10) {\line(1,0){8}} \put(36, 20) {\line(1,0){8}} \put(20, -8){\large $x$-axis} \put( -4,29){ 1} \put( -4,19){ 0} \put( -4, 9){-1} \put( -2,-4){0} \put( 6,-4){ $a$} \put( 14,-4){2$a$} \put( 22,-4){3$a$} \put( 30,-4){4$a$} \put( 38,-4){5$a$} \put(-8,10){\rotatebox{90}{Wave Function}} \end{picture} \caption{ An elementary wave in the quantized space, where $a$ represents the lattice spacing in the continuum space. } \label{fig:fig1} \end{center} \end{figurehere} \par \section{ Comparison of the theoretical ultraviolet cut-off energy and cosmic ray spectrum with experimental data} \label{sec:Sec3} This section compares the properties of the present quantized space-time element theory with those of the experimentally observed cosmic ray spectrum. In particular, the ultraviolet cut-off energy was calculated by the present theory, as described in Section \ref{sec:Sec2}, using the current particle and cosmological data in \cite{Tanabashi18}, and this value was compared with experimental spectra. The data used were $\Omega_{\Lambda}$ $=0.694$, $\Omega_{\rm b}$ $=0.0483$, $m_{\rm u}=2.2$ MeV, $m_{\rm d}=4.7$ MeV, $m_{\rm p}$ $=938.272$ MeV, $v=246.22$ GeV \cite{Arason}, where $\Omega_{\rm b}$ is the energy fraction of baryons of the total universe energy. The present quantized space-time element theory was then used to derive the theoretical Minkowski cut-off energy $\Delta^{(\rm E)}_{\rm M}=(1/\sqrt{2})\Delta^{(\rm E)}_{\rm E} (=7.5 \times 10^{-8} \mbox{ fm}) =2.6\mbox{ PeV} \approx 3 \mbox{ PeV}$. \par Meanwhile, experimental cosmic rays, which are thought to be produced by remnants of a supernova (star explosion), have the following energy spectrum characteristics. At low energies, the energy spectrum of cosmic rays rises with increasing cosmic ray energy, and has a peak at the energy $E_{0} \approx 10^8$ eV followed by a decline in the form of $(E_{\rm c})^{-s}$, where $E_{\rm c}$ is the cosmic-ray energy and $s$ is the spectral index. The spectrum has the form $\approx E_{\rm c}^{-2.7}$ for $E_{\rm c} \leq 3 \times 10^{15}$ eV, and changes to the form $\approx E_{\rm c}^{-3.0}$ for $E_{\rm c} \geq 3 \times 10^{15}$ eV. Hence, a spectrum break occurs at an energy $E_{\rm c} \approx 3 \times 10^{15}$ eV, and this break is called the knee. (The spectrum for energies of less than the energy of about $10^{15}$ eV is understood based on astrophysical studies, while the origin of the spectrum above about $3 \times 10^{15}$ eV is not clear.) Thus, the theoretical ultraviolet cut-off energy of about $3$ PeV derived from the present quantized space-time element theory coincides with the experimentally observed knee energy of about 3 PeV. There is therefore a possibility that the space-time continuum is quantized at the knee energy of 3 PeV, as specified from the ultraviolet cut-off energy. \par Let us now consider the relation between the properties of the present quantized space-time element theory and those of the experimental energy spectrum. Theoretically, the cut-off energy is fixed, despite the fact that the space-time elements of the orthoplexes obtained by dividing the space-time continuum have arbitrary shapes. The present quantized space-time element theory then gives rise to the possibility that the energies of the basis functions in Eq. (\ref{eqn:Fexp}) may exhibit tail energies beyond the cut-off energy, and may correspond to the cosmic-ray energy spectrum beyond the knee at 3 PeV. The flux per unit energy of cosmic rays, which are composed of particles such as protons, is denoted by \begin{eqnarray} \label{eqn:Flux} F_{\rm c}(x,E_{\rm c}) \propto \rho(E_{\rm c})|\psi_{k_{\mu}}(x)|^2, \end{eqnarray} where $\rho(E_{\rm c})$ is the density (spectrum) as a function of the energy $E_{\rm c}$ (for example of a proton) in the usual four-momentum $k_{\mu}$. It is noted that in the present quantized space-time element scheme, the main spectrum $\rho(E_{\rm c})$ is restricted to the energy regime that is below the ultraviolet cut-off energy of about 3 PeV. \par In the present treatment of the space-time continuum with additional discrete lattice structure in the present formalism, this formalism uses the analogy of solid state physics, which involves crystal structure in the space continuum. In solid state physics \cite{Kittel56,Kittel63}, the wave function of an electron is a function of each point of the space continuum. A lattice system of grid points at atomic positions with a lattice spacing $a_{\rm s}$ is added to this space continuum. Then, the static wave function in one dimension is restricted to the following form of the Bloch function \begin{eqnarray} \label{eqn:Bloch} \psi_{{\rm s},k_{\rm s}}(x) = [\exp(ik_{s}x)] u_{{\rm s},k_{\rm s}}(x), \end{eqnarray} where $x$ is a point in the space continuum, $k_{\rm s}$ is the momentum, and $u_{{\rm s},k_{\rm s}}(x)$ is a static periodic function that for a lattice spacing $a_{\rm s}$ satisfies \begin{eqnarray} \label{eqn:perio} u_{{\rm s},k_{\rm s}}(x+a_{\rm s})=u_{{\rm s},k_{\rm s}}(x). \end{eqnarray} Using the one-dimensional vector $G_n=2\pi n (1/a_{\rm s})$, with $n=0,1,2,\cdot\cdot\cdot$, in the reciprocal lattice space, Eq. (\ref{eqn:Bloch}) yields \begin{eqnarray} \label{eqn:redu} \nonumber \psi_{{\rm s},k_{\rm s}}(x) =\exp[i(k_{s}+G_n)x]\{[\exp(-iG_n x)]u_{{\rm s},k_{\rm s}}(x)\} \end{eqnarray} \begin{eqnarray} =\{\exp[i(k_{s}+G_n)x]\}\tilde{u}_{{\rm s},k_{\rm s}}(x). \end{eqnarray} Here, the above expression $\tilde{u}_{{\rm s},k_{\rm s}}(x)$ denoted by \begin{eqnarray} \label{eqn:defut} \tilde{u}_{{\rm s},k_{\rm s}}(x)=[\exp(-iG_n x)]u_{{\rm s},k_{\rm s}}(x), \end{eqnarray} with aid of $\exp(-iG_n a_{\rm s})=1$ satisfies \begin{eqnarray} \label{eqn:petuo} \tilde{u}_{{\rm s},k_{\rm s}}(x+a_{\rm s})=\tilde{u}_{{\rm s},k_{\rm s}}(x), \end{eqnarray} meaning that $\tilde{u}_{{\rm s},k_{\rm s}}$ is also a periodic function in the same way as $u_{{\rm s},k_{\rm s}}$ in Eq. (\ref{eqn:perio}). It is noted that Eq. (\ref{eqn:Bloch}) with Eq. (\ref{eqn:perio}) has the same form as Eq. (\ref{eqn:redu}) with Eq. (\ref{eqn:petuo}), implying that the momentum $k_{\rm s}+G_n$ is essentially equivalent to $k_{\rm s}$. Therefore, $k_{\rm s}$ is reduced to $-\pi/a_{\rm s} \leq k_{\rm s} \leq \pi/a_{\rm s}$, and $\pi/a_{\rm s}$ is regarded as a cut-off momentum. Since $u_{{\rm s},k_{\rm s}}$ in Eq. (\ref{eqn:Bloch}) is a function of the vectors $G_n$ in the reciprocal lattice space, the energy spectrum of an electron is a function of the momentum $k_{s}$, which is reduced to $-\pi/a_{\rm s} \leq k_{\rm s} \leq \pi/a_{\rm s}$, and $G_n$. In the energy spectrum, the spectrum break occurs at a momentum-space point corresponding to the ultraviolet cut-off momentum, and this break becomes somewhat unclear when the lattice is somewhat disordered. The quantity $u_{{\rm s},k_{\rm s}}$ is expressed by a Fourier series with respect to the corresponding momentum $G_n$, which becomes the Fourier transform for large energy scales. A wave function with the same translation symmetry as Eq. (\ref{eqn:Bloch}) is also written in the form \begin{eqnarray} \label{eqn:TITB} \psi_{{\rm s},k_{\rm s}}(x) =\sum_{l_{m_{\rm s}}}\exp(ik_{s}l_{m_{\rm s}}) \chi(x-l_{m_{\rm s}}), \end{eqnarray} where $\chi(x)$ is a localized function, and $l_{m_{\rm s}}=m_{\rm s}a_{\rm s}$ are lattice points with $m_{\rm s}$ being integers. \par The above theory of solid state physics is now applied to the space-time continuum with the additional lattice in the present formalism. By analogy to Eqs. (\ref{eqn:Bloch}) and (\ref{eqn:TITB}), the wave function $\psi_{k_{\mu}}(x)$ of a composite charged particle, such as a proton in Eq. (\ref{eqn:Flux}), is written in an approximated form in terms of the localized basis functions ${\tilde{\Omega}}^{4}_{p}$ as follows: \begin{eqnarray} \label{eqn:InMm} \nonumber \psi_{k_{\mu}}(x) \approx \sum_p \exp(-ik_{\mu}l^{\mu}_p){\tilde{\Omega}}^{4}_{p}(x) \end{eqnarray} \begin{eqnarray} =\sum_p \exp(-ik_{\mu}l^{\mu}_p){\tilde{\Omega}}^{4}(x^{\mu^{\prime}}-l^{\mu^{\prime}}_p), \end{eqnarray} where $l^{\mu}_p$ (the notation $\mu^{\prime}$ is essentially identical to $\mu$) is the four-dimensional vector representing the center of each space-time element of the orthoplexes indexed by $p$. In the limit as the lattice spacing (the distance between nearest-neighbour orthoplexes) approaches zero, the position $l^{\mu}_p$ becomes the quantity corresponding to the coordinate $x^{\mu}$. The function ${\tilde{\Omega}}^{4}$ in ${\tilde{\Omega}}^{4}(x^{\mu}-l^{\mu}_p)={\tilde{\Omega}}^{4}_{p}(x)$ has the form of a basis function that is translated to the position corresponding to the origin of coordinates. The wave function $\psi_{k_{\mu}}(x)$ has a value proportional to $\exp(-ik_{\mu}l^{\mu}_p)$ at the position $l^{\mu}_p$. In the special case of Eqs. (\ref{eqn:Fexp}) and (\ref{eqn:BasE}), only a single basis function can be excited. In this case, the coefficient for the assigned basis function takes a value of one (unity), while the coefficients for the other basis functions vanish. The localized basis functions used here, such as those in Eq. (\ref{eqn:BasD}), have the properties ${\tilde{\Omega}}^{4}_{p}(x){\tilde{\Omega}}^{4}_{q}(x)=$ or $\approx 0$ for $p \neq q$, and $|{\tilde{\Omega}}^{4}_{p}(x){\tilde{\Omega}}^{4}_{q}(x)|=$ or $\approx$ $|{\tilde{\Omega}}^{4}_{p}(x)|^2$ for $p=q$. Then, using Eq. (\ref{eqn:InMm}), the absolute square of the wave function in Eq. (\ref{eqn:Flux}) is \begin{eqnarray} \label{eqn:SqIM} \nonumber |\psi_{k_{\mu}}(x)|^2 \end{eqnarray} \begin{eqnarray} \nonumber =|\sum_{p,q}\exp[-ik_{\mu}(l^{\mu}_p-l^{\mu}_q)] \tilde{\Omega}^4(x^{\mu^{\prime}}-x^{\mu^{\prime}}_p) \tilde{\Omega}^4(x^{\mu^{\prime}}-x^{\mu^{\prime}}_q)| \end{eqnarray} \begin{eqnarray} \approx \sum_{p}|\tilde{\Omega}^4(x^{\mu}-l^{\mu}_p)|^2, \end{eqnarray} reducing the flux per unit energy in Eq. (\ref{eqn:Flux}) to \begin{eqnarray} \label{eqn:RedF} F_{\rm c}(x,E_{\rm c}) \propto \rho(E_{\rm c}) \sum_{p}|\tilde{\Omega}^4(x^{\mu}-l^{\mu}_p)|^2. \end{eqnarray} \par The practical form of the basis functions is now presented for use in the energy regime higher than the ultraviolet cut-off energy. When the time dependence of the localized basis function ${\tilde{\Omega}}^{4}(x)$ is approximated by the Gaussian function $\exp[-(b/2)|t|^2]$, for example, the dependence of $\exp(-b|t|^2)$ (a squared Gaussian function) on the cosmic ray energy \verb+ + $E_{\rm c}$ \verb+ + is $[(1/(2b)^{1/2}]$$\exp[-(E_{\rm c})^2/(4b)]$. \verb+ + Referring to this Gaussian function as a example, the time dependence of the localized basis function ${\tilde{\Omega}}^{4}$ is approximated in practice by $B_t(t)$. In the present quantized space-time element theory scheme, the basis functions give the spectra for cosmic rays at energies higher than the cut-off energy. Then, the absolute square of the time-dependent localized basis function $B^{(2)}_t(t)=|B_t(t)|^2$ for charged particles in this case is formulated in terms of the localized functions $B_{I,t}^{(2)}(t)$ with $I=1, 2$ as \begin{eqnarray} \label{eqn:B212} B_{t}^{(2)}(t)=C_1 B_{1,t}^{(2)}(t)+C_2 B_{2,t}^{(2)}(t), \end{eqnarray} where $C_1$ and $C_2$ are normalized weighting constants, such as $C_{1}=C_{2}=1/2$. If necessary, the functions $B_{I,t}^{(2)}(t)$ with $I>3$ are added to the above expression for $B_{t}^{(2)}(t)$. The above localized functions $B_{I,t}^{(2)}(t)$ with $I=1,2$ are defined as \begin{eqnarray} \nonumber \label{eqn:B21a} B_{1,t}^{(2)}(t)= \frac{1}{C_{B}} \frac{\sqrt{2}}{\Gamma(s_1 /2)} \left| \frac{t}{2a_1} \right| ^{(s_1-1)/2} K_{(s_1-1)/2}(a_1|t|), \end{eqnarray} \begin{eqnarray} \end{eqnarray} \begin{eqnarray} \label{eqn:B1b2} \nonumber B_{2,t}^{(2)}(t)= \frac{1}{C_{B}} \frac{\sqrt{2}}{\Gamma(s_2 /2)} \left| \frac{t}{2a_2} \right| ^{(s_2-1)/2} K_{(s_2-1)/2}(a_2|t|), \end{eqnarray} \begin{eqnarray} \end{eqnarray} where $C_{B}$ is a normalization constant, and $a_1, a_2, s_1$ and $s_2$ are constants that give localization properties in the time coordinate $t$ and corresponding spectrum properties in the coordinate of the cosmic ray energy $E_{\rm c}$, as mentioned below. The function $K_{\nu}(t)$, in which the conventional notation $\nu$ in this case refers to a real number and $\nu=(s_1-1)/2=s_1/2-1/2$ or $\nu=(s_2-1)/2$, is the modified Bessel function \cite{MEHandbook}, written as \begin{eqnarray} \label{eqn:BesFn} K_{\nu}(t)=\frac{\pi}{2}\frac{I_{-\nu}(t)-I_{\nu}(t)}{\sin(\nu \pi)}, \end{eqnarray} where \begin{eqnarray} \label{eqn:INu} I_{\nu}(t)= \left( \frac{t}{2} \right) ^{\nu} \sum_{n=0}^{\infty} \frac{(t/2)^{2n}}{n!\Gamma(\nu+n+1)}, \end{eqnarray} with $\Gamma$ being the gamma function. The function $|t|^{\nu}K_{\nu}$ in Eqs. (\ref{eqn:B21a}) and (\ref{eqn:B1b2}) has the following localized properties for the basis functions. Near $t=0$, \begin{eqnarray} \label{eqn:AppI} \nonumber |t|^{\nu}K_{\nu}(t) \approx |t|^{\nu}\frac{\pi}{2}\frac{1}{\sin(\nu \pi)} \left( \frac{t}{2} \right) ^{-\nu} \frac{1}{\Gamma(-\nu+1)} \end{eqnarray} \begin{eqnarray} \label{eqn:I2App} =\mbox{constant}, \end{eqnarray} while in the limit as $t \rightarrow \infty$, the function vanishes, leading to \begin{eqnarray} \label{eqn:IIAppb} |t|^{\nu}K_{\nu}(t) \approx |t|^{\nu} \sqrt{\frac{\pi}{2t}} \exp(-t). \end{eqnarray} In Eq. (\ref{eqn:B212}), the condition $B^{(2)}_t(0)=1$ is imposed on the absolute square of the basis function $B^{(2)}_t(t)=|B_t(t)|^2$, to simplify the formulation. Using Eq. (\ref{eqn:AppI}) \begin{eqnarray} \label{eqn:BCon} \nonumber B_t^{(2)}(0)=C_1 B_{1,t}^{(2)}(0)+C_2 B_{2,t}^{(2)}(0)=1 \end{eqnarray} \begin{eqnarray} \nonumber =\frac{C_1}{C_{B}} \frac{\sqrt{2}}{\Gamma(s_1 /2)} \lim_{\epsilon\to 0} \left[ \left| \frac{\epsilon}{2a_1} \right| ^{(s_1-1)/2} K_{(s_1-1)/2}(a_1|\epsilon|) \right] \end{eqnarray} \begin{eqnarray} \nonumber +\frac{C_2}{C_{B}} \frac{\sqrt{2}}{\Gamma(s_2 /2)} \lim_{\epsilon\to 0} \left[ \left| \frac{\epsilon}{2a_2} \right| ^{(s_2-1)/2} K_{(s_2-1)/2}(a_2|\epsilon|) \right]. \end{eqnarray} \begin{eqnarray} \end{eqnarray} By setting $ C_1=C_2=1/2$, the constant $C_B$ is simply obtained from the above Eq. (\ref{eqn:BCon}). \par The functions $B_{I,t}^{(2)}(t)$ with $I=1,2$ are then Fourier-transformed as follows \begin{eqnarray} \label{eqn:FtBf} \nonumber B_{I,E}^{(2)}(E_{\rm c}) =\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty} dt\hspace{1ex} \exp(iE_{\rm c}t) B_{I,t}^{(2)}(t), \end{eqnarray} \begin{eqnarray} =\frac{2}{\sqrt{2\pi}}\int_{0}^{\infty} dt\hspace{1ex} \cos(E_{\rm c}t) B_{I,t}^{(2)}(t). \end{eqnarray} The last term of the above equation, reduced to the Fourier cosine transform, may be divided by a factor of two, depending on the required condition. The above functions $B_{I,E}^{(2)}$ with I=1,2 and the $B_{E}^{(2)}$ corresponding to $B_{t}^{(2)}$ in Eq. (\ref{eqn:B212}) can be expressed as \begin{eqnarray} \label{eqn:E1B} B_{1,E}^{(2)}(E_{\rm c})= \frac{1}{C_{B}} \frac{1}{[(a_1)^2+(E_{\rm c})^2]^{(s_1 /2)}}, \end{eqnarray} \begin{eqnarray} \label{eqn:B2E1} B_{2,E}^{(2)}(E_{\rm c})= \frac{1}{C_{B}} \frac{1}{[(a_2)^2+E_{\rm c})^2]^{(s_2 /2)}}, \end{eqnarray} \begin{eqnarray} \label{eqn:BEE12} B_{E}^{(2)}(E_{\rm c}) =C_1 B_{1,E}^{(2)}(E_{\rm c})+C_2 B_{2,E}^{(2)}(E_{\rm c}). \end{eqnarray} For the inequalities $a_{1}$ $\ll$ $a_{2}$ and $s_1 > s_1$, the functions in the above equation have the form $B_{E}^{(2)} \approx$ $B_{1,E}^{(2)} \propto (E_{\rm c})^{-s_1}$ for $a_{1} \leq E_{\rm c} \leq a_2$, while $B_{E}^{(2)} \approx$ $B_{2,E}^{(2)} \propto (E_{\rm c})^{-s_2}$ for $a_{2} \leq E_{\rm c}$. (The function $B_{2,E}^{(2)}$ is small for $E_{\rm c} \leq a_2$ since $a_1$ $\ll$ $a_2$, while for the condition $s_1 >s_2$, the function $B_{1,E}^{(2)}$ falls rapidly compared to $B_{2,E}^{(2)}$ for $a_2 \leq E_{\rm c}$.) \par Here, the constants are set as $a_1 = 3 \times 10^{15}$ eV, $a_2 = 3 \times 10^{18}$ eV, $s_1 = 3.0$ and $s_2 = 2.6$. The theoretical energy spectrum then reproduces the experimentally observed energy spectrum of the cosmic rays as $\approx (E_{\rm c})^{-3.0}$ between the knee energy at about $3 \times 10^{15}$ eV and the ankle energy at about $3 \times 10^{18}$ eV, and also reproduces the spectrum $\approx (E_{\rm c})^{-2.6}$ above the ankle energy. Thus, the experimental energy spectrum of cosmic rays is reproduced by the present quantized space-time element theory. For energies above about $5 \times 10^{19}$ eV, a drop in the energy spectrum may appear due to the Greisen-Zatsepin-Kazumin (GZK) limit \cite{Greisen,Zatsepin}, in which cosmic rays originating at places far away from the Earth cannot reach the Earth due to losses of energy via interactions with the cosmic microwave background. \par Furthermore, if the distribution of the cut-off energy due to the arbitrary shape of the space-time elements is accepted for energies higher than the ultraviolet cut-off energy of about 3 PeV, further deformation of the energy spectrum might be seen. In this case, space-time elements (orthoplexes of the space-time continuum) of distributed size might form random networks. The wave of the cosmic ray may then propagate through the random network composed of space-time elements that have distributed high-energy (or short length) cut-off energies. If the propagation along the path is similar to that in a curved fiber-optic cable, the cosmic ray might change direction, resulting in some difficulty in identifying the initial source point of emission in some cases. For the spectrum at energies lower than the ultraviolet cut-off energy (that is, the knee), a view from a trial study is given in Appendix. \par Finally, this section presents descriptions of the mass composition of cosmic rays. The experimentally observed spectrum shows some fall-off in the light particle components, such as neutrinos and photons, around the knee \cite{Aartsen}. The present theory attributes this fall-off to scattering of the cosmic-ray wave function from the somewhat disordered lattice of space-time elements, composed of arbitrarily shaped orthoplexes, around the ultraviolet cut-off length, that is, the inverse of the cut-off energy. (This attribution is based on the diffuse scattering from a disordered lattice observed in solid state physics.) In the following, we study this diffuse scattering due to the disordered lattice. In Refs. \cite{Fuku84,Fuku17}, fields are defined using the Euclidian parameter space-time, which is Wick-rotated from the Mikowski space-time, and divided into individual hyper-cubes centered at each periodic lattice point. By considering only the dependence of the $z_{\rm P}$ coordinate for quantities in the parameter space-time for simplicity, it can be shown that the wave function $\psi_{\rm c}(z_{\rm P})$ of a cosmic-ray particle, such as in the $z_{\rm P}$ axis of the parameter space-time, has the periodicity \begin{eqnarray} \label{eqn:rblo1} \psi_{\rm c}(z_{\rm P}+\Delta_{{z}_{\rm P}})=\psi_{\rm c}(z_{\rm P}), \end{eqnarray} where $\Delta_{z_{\rm P}}$ is a lattice spacing. The wave function is then expressed in the form of the following Bloch function \begin{eqnarray} \label{eqn:rbl2o} \psi_{\rm c}(z_{\rm P})=\exp(ik_{z_{\rm P}} z_{\rm P})u_{\rm c}(z_{\rm P}), \end{eqnarray} where $k_{z_{\rm P}}$ is the momentum and $u_{\rm c}$ is a periodic function satisfying \begin{eqnarray} \label{eqn:rb3lo} u_{\rm c}(z_{\rm P}+\Delta_{z_{\rm P}})=u_{\rm c}(z_{\rm P}). \end{eqnarray} This parameter space-time is mapped onto the real space-time, and if necessary, the real space-time is regarded as a tangent space in a curved space-time. In real space-time, the lattice mapped from the parameter space-time is slightly deformed from the periodic lattice in order to satisfy Lorentz covariance. The hyper-cube in the parameter space-time is mapped to an orthoplex. The wave function is then slightly deviated from the Bloch function and is scattered from the somewhat deformed lattice, and the cosmic-ray particle moves in a zigzag. This scattering is referred to as diffuse scattering in this paper. \par The theory presented in this paper offers a method of describing this diffuse scattering using Feynman diagrams, which give the change in a wave function with the aid of Green functions. We consider the process represented in Eq. (\ref{eqn:dmat1}) below for a cosmic ray particle with initial momentum $p^{\rm i}_{\rm c}$ and the associated wave function $\psi^{\rm i}_{u\rm c}(p^{\rm i}_{\rm c})$. The momentum and associated wave function become $p^{\rm f}_{\rm c}$ and $\psi^{\rm f}_{u\rm c}(p^{\rm f}_{\rm c})$, respectively. At the first vertex, the wave function changes under a perturbation with strength $(\alpha_{\rm D})^{1/2}$ in the direction of a unit vector $\epsilon$ caused by the disordered space-time lattice, and the cosmic ray particle gains a momentum $k_{\rm D}$ that is normal to $\epsilon$ in the spatial direction. The perturbation strength $(\alpha_{\rm D})^{1/2}$ is tiny when the deviation of the disordered lattice from a regular periodic lattice is small. At the second vertex, the cosmic ray particle loses momentum $k^{\prime}_{\rm D}$ due to a perturbation in the direction of a unit vector $\epsilon^{\prime}$, with $k^{\prime}_{\rm D}$ being normal to $\epsilon^{\prime}$ in the spatial direction. The Feynman diagram also contains a process in which the cosmic-ray particle loses momentum $k^{\prime}_{\rm D}$ before gaining momentum $k_{\rm D}$. To conserve the momentum, we introduce auxiliary ghost-like massless bosons with the above values of momentum, $k_{\rm D}$ and $k^{\prime}_{\rm D}$. In this process, the cosmic-ray particle absorbs a ghost-like boson with momentum $k_{\rm D}$, and emits a ghost-like boson with momentum $k^{\prime}_{\rm D}$. The cosmic-ray particle travels along a straight trajectory with a zigzag motion. We therefore assign a value of zero to the total momentum summed over all processes in which the ghost-like bosons are absorbed and emitted. The above process, represented using the Feynman diagram method, is expressed by the following amplitude of the transition matrix element containing an adjoint quantity $\bar{\psi}^{\rm f}_{u\rm c}(p^{\rm f}_{\rm c})$ \begin{eqnarray} \label{eqn:dmat1} \nonumber M^{\rm fi} \propto \alpha_{\rm D} \bar{\psi}^{\rm f}_{u\rm c} (p^{\rm f}_{\rm c}) \left[ (-i\slashed{\epsilon}^{\prime}) \frac{ i } { \slashed{p}^{\rm i}_{\rm c} +\slashed{k}_{\rm D} -m_{\rm c} } (-i\slashed{\epsilon}) \right. \end{eqnarray} \begin{eqnarray} \hspace{10ex} + \left. (-i\slashed{\epsilon}) \frac{ i } { \slashed{p}^{\rm i}_{\rm c} -\slashed{k}_{\rm D}^{\prime}-m_{\rm c} } (-i\slashed{\epsilon}^{\prime}) \right] {\psi^{\rm i}_{u\rm c}(p^{\rm i}_{\rm c})}, \end{eqnarray} where $\slashed{p}^{\rm i}_{\rm c}=\gamma^{\mu}p^{\rm i}_{\mu \rm c}$ with $\gamma^{\mu}$ being Dirac's gamma matrices, and $p^{\rm i}_{\mu \rm c}$ and $m_{\rm c}$ are the initial momentum and the mass of the cosmic ray particle, respectively. Conservation of momentum is satisfied by the ghost-like bosons in the above processes, as follows \begin{eqnarray} \label{eqn:dmom1} p^{\rm i}_{\rm c}+k _{\rm D} =p^{\rm f}_{\rm c}+k^{\prime}_{\rm D}. \end{eqnarray} By denoting the absolute values of the scattering angles for the cosmic ray particle and ghost-like boson in the laboratory system by $\theta_{\rm c}$ and $\theta_{\rm D}$, respectively, we treat the elastic processes expressed by $|p^{\rm f}_{\rm c}|=|p^{\rm i} _{\rm c}|$ and $|k _{\rm D}|=|k^{\prime}_{\rm D}|$ with an imposed relation $\theta_{\rm c}=\theta_{\rm D}$. \par The cross section of the diffuse scattering is derived from the corresponding cross section of the ghost-like boson scattered by the cosmic-ray particle as shown below. By analogy to the scattering between a free particle and a massless boson described by Bjorken and Drell \cite{BJDR}, differentiation of the scattering cross section $\sigma_{\rm D}$ of the ghost-like boson with respect to the solid angle $\Omega_{\rm D}$ is expressed as \begin{eqnarray} \label{eqn:bcro1} \frac{d\sigma_{\rm D}}{d\Omega_{\rm D}} =(\alpha_{\rm D})^2 \frac{\hbar^2}{(m_{\rm c}c)^2}(\epsilon^{\prime}\cdot\epsilon)^2, \end{eqnarray} where \begin{eqnarray} \label{eqn:bcr2o} d\Omega_{\rm D} =2\pi (\sin\theta_{\rm D}) d\theta_{\rm D}, \end{eqnarray} with $m_{\rm c}$ being the mass of the cosmic ray particle. The above cross section is proportional to $(m_{\rm c})^{-2}$. The corresponding cross section $\sigma_{\rm c}$ for diffuse scattering of the cosmic-ray particle satisfies $\sigma_{\rm c}=\sigma_{\rm D}$ and \begin{eqnarray} \label{eqn:fcro1} \frac{d\sigma_{\rm c}}{d\Omega_{\rm c}} \frac{d\Omega_{\rm c}}{d\Omega_{\rm D}} =\frac{d\sigma_{\rm D}}{d\Omega_{\rm D}}, \end{eqnarray} where \begin{eqnarray} \label{eqn:fc3ro} d\Omega_{\rm c}=2\pi (\sin\theta_{\rm c}) d\theta_{\rm c}. \end{eqnarray} \par When the cosmic ray particles are lost from the average main path at an angle above the critical scattering angle $\theta_{\rm Lc}$ and the corresponding angle $\theta_{\rm LD}$ of the ghost-like boson, we have the relation $\theta_{\rm LD}=\theta_{\rm Lc}$ from $\theta_{\rm D}=\theta_{\rm c}$. Using this relation and Eqs. (\ref{eqn:bcr2o})$-$(\ref{eqn:fc3ro}), the cross section for the loss from the averaged main path is expressed as \begin{eqnarray} \label{eqn:lcor1} \sigma_{\rm Lc}=\sigma_{\rm LD} =\int_{\theta_{\rm LD}}^{\pi} \frac{d\sigma_{\rm D}}{d\Omega_{\rm D}} 2\pi (\sin\theta_{\rm D}) d\theta_{\rm D}. \end{eqnarray} Here, Eq. (\ref{eqn:bcro1}) is rewritten as \begin{eqnarray} \label{eqn:bcrom} \frac{d\sigma_{\rm D}}{d\Omega_{\rm D}} =\frac{(\alpha_{\rm D})^2 (\hbar c)^2 }{(m_{\rm c}c^2)^2}A_{\rm D}, \end{eqnarray} where \begin{eqnarray} \label{eqn:b2crom} A_{\rm D}= (\epsilon^{\prime}\cdot\epsilon)^2. \end{eqnarray} From Eqs. (\ref{eqn:lcor1}) and (\ref{eqn:b2crom}), we get \begin{eqnarray} \label{eqn:lcorm} \sigma_{\rm Lc}= \frac{(\alpha_{\rm D})^2 (\hbar c)^2 }{(m_{\rm c}c^2)^2}\int_{\theta_{\rm LD}}^{\pi} A_{\rm D} 2\pi (\sin\theta_{\rm D}) d\theta_{\rm D}. \end{eqnarray} Furthermore, Eq. (\ref{eqn:b2crom}) is approximated as $A_{\rm D} \approx 1 $ for small-angle perturbations, reducing the above equation to \begin{eqnarray} \label{eqn:lAcorm} \sigma_{\rm Lc}=\frac{(\alpha_{\rm D})^2 (\hbar c)^2 }{(m_{\rm c}c^2)^2}B_{\rm D}, \end{eqnarray} where \begin{eqnarray} \label{eqn:lcorm} \nonumber B_{\rm D}= \int_{\theta_{\rm LD}}^{\pi} 2\pi (\sin\theta_{\rm D}) d\theta_{\rm D} \end{eqnarray} \begin{eqnarray} =2\pi( 1+\cos{\theta_{\rm LD}}). \end{eqnarray} For simplicity, the real space-time is regarded as identical with the parameter space-time composed of hyper-cubes, and the lattice spacings in the $x$ and $y$ directions are defined as $\Delta_x=\Delta_z$, $\Delta_y=\Delta_z$, respectively. When one cosmic ray particle travels along a trajectory of length $L_{\rm c}$ within a volume $\Delta_x\Delta_yL_{\rm c}$ with the particle being scattered at all lattice points contained within it, the loss fraction of the cosmic ray particle is given by \begin{eqnarray} \label{eqn:CLfr1} F_{\rm Lc}= \left( \frac{L_{\rm c}}{\Delta_z} \right) \frac{\sigma_{\rm Lc}} { \Delta_x\Delta_y }. \end{eqnarray} Combining the above equation with Eq. (\ref{eqn:lAcorm}) gives \begin{eqnarray} \label{eqn:C2Lfr} F_{\rm Lc}=\frac{L_{\rm c}}{\Delta_z} \frac{(\alpha_{\rm D})^2 (\hbar c)^2 } { \Delta_x\Delta_y (m_{\rm c}c^2)^2}B_{\rm D}. \end{eqnarray} At the critical scattering angle $\theta_{\rm Lc}$ in Eq. (\ref{eqn:lcorm}), the above loss fraction of the cosmic-ray particle is a function of the perturbation strength $\alpha_{\rm D}$. \par Here, we consider the case of lattice spacings $\Delta_x=\Delta_y=\Delta_z$, corresponding to $3\times 10^{15}$ eV and a trajectory length $L_{\rm c}=1000$ Mpc. In Eq. (\ref{eqn:lcorm}), we approximate $\cos({\theta_{\rm LD}}) \approx 1.0$ for the small critical scattering angle $\theta_{\rm Lc}=\theta_{\rm LD}$, and set the perturbation strength $\alpha_{\rm D}$ to $9.08 \times 10^{-32}$. Then, the loss fraction $F_{\rm Lc}$ of the proton for energy $10^{18}$ eV in Eq. (\ref{eqn:CLfr1}) becomes 0.5. In this case, the loss fraction $F_{\rm Lc}$ is reduced to $0.25 \times 10^{-2}$ for a trajectory length $L_{\rm c}=5$ Mpc. Since Eq. (\ref{eqn:C2Lfr}) states that the cosmic-ray loss evaluated using the scattering cross section is proportional to the inverse of the squared mass of the cosmic ray particle at an identical production rate, the loss of a muon neutrino with a rest mass of less than 0.17 MeV is larger than that of a proton. Next, we treat the diffuse scattering of photons in cosmic rays using the ghost-like particle to conserve momentum in the scattering of the photon When the ghost-like particle is a boson, the photon in the cosmic ray will create a fermion pair, which lose energy until the pair is annihilated and emit two photons with the energy of the fermion rest mass, in opposite directions. When the ghost-like particle is an electron-like particle with mass smaller than an electron, the scattering cross section is larger by at least $3.4\times 10^{6}$ than a proton, since the electron rest mass is $1/1837$ of the proton mass. \par We note that in particular, elementary particles with negligible or zero rest mass, such as neutrinos or photons, will be scattered with high scattering probabilities from the disordered lattice of the space-time elements for all energies higher than the knee energy, resulting in the theoretical possibility of no detection of neutrinos and photons above approximately this value for the knee energy. This feature of the present theory is consistent with the experimental results that neutrinos and gamma rays are not observed above approximately the knee energy \cite{Aartsen}, as mentioned in Section \ref{sec:Sec1}. As a result, the composite fraction of heavy nuclei in cosmic rays becomes larger just above the knee energy. These results are compatible with the experimentally observed composition of cosmic rays \cite{Aartsen}. In summary here, the diffuse scattering of cosmic rays by the disordered lattice of the space-time elements, which is obtained by dividing the space-time continuum, theoretically leads to the knee. This diffuse scattering gives rise to high scattering probabilities for particles with tiny/zero rest mass. Thus, the present theory is consistent with the absence of any experimental detection of neutrinos and photons for energies above about the knee energy. \section{Conclusions} \label{sec:Sec4} This article has investigated in detail the relation between the present quantized space-time element formalism of field theory, which removes ultraviolet high-energy contributions using the ultraviolet cut-off energy, and experimental data. This formalism distinguished a new cut-off energy in Minkowski space from the Euclidean cut-off energy, derived from the Higgs self-energy contribution to the cosmological constant. Using current particle and cosmological data, a comparison between the theoretical cut-off energy found in this work and the experimentally observed spectrum of cosmic rays in the literature demonstrated the possibility that the cut-off energy corresponds to the experimental spectrum break, called the knee at about 3 PeV in the case for the fixed cut-off energy. The origin of cosmic rays with energies less than about 1 PeV is understood based on astrophysical studies, while the origin of those with energies higher than about 3 PeV is not clear. If the additional energy contribution from the basis functions is considered based on an analogy with solid state physics, a tail may emerge in the energy spectrum above the ultraviolet cut-off energy. Since the energy spectrum for the present theory in this high-energy regime is due to the contribution from the basis functions, a linear combination of two basis functions reproduces the increased spectral index of the slope for energies between the knee at $3 \times 10^{15}$ eV and the ankle at $3 \times 10^{18}$ eV, and reduces the spectral index above the ankle energy. The diffuse scattering of cosmic rays by the disordered lattice of the space-time elements, obtained by dividing the space-time continuum, causes the knee. This diffuse scattering gives rise to high scattering probabilities for particles with a tiny/zero rest mass. The features of the present theory are consistent with a lack of detection of neutrinos and photons above about the knee energy. Furthermore, if the distribution of the cut-off energy due to the arbitrary shape of the space-time elements exists for energies higher than about 3 PeV, some deformation of the energy spectrum might be seen. In this case, the cosmic rays might propagate along a random network, making the initial source point of emission ambiguous in some cases. \par \setcounter{section}{0} \renewcommand{\thesection}{Appendix} \setcounter{equation}{0} \renewcommand{\theequation}{\Alph{section}.\arabic{equation}} \section{\hspace{-2ex}: Spectrum for energies lower than the ultraviolet cut-off energy (the knee) } \label{sec:AppA} This appendix presents a view from a trial study of the spectrum for energies lower than the ultraviolet cut-off energy (the knee). As mentioned above, the main objective of this paper is not to propose a new mechanism for the spectrum at energies lower than the cut-off energy. Although the energy spectrum in the form of a power law $(E_{\rm c})^{-s}$ with the cosmic-ray energy $E_{c}$ and spectral index $s$ below about $10^{15}$ eV is described by the diffusive shock acceleration (DSA) model, the obtained value of 2 for the spectral index is lower than the experimentally observed value of about $2.7$. Other mechanisms are proposed to add the spectral index $\alpha$, which is 2.7$-$2 in this case, to the index 2 of the DSA; however, the dominant mechanism has not yet been specified. The present paper examines the mechanism of the spectral index $\alpha$ added to the index 2 of the DSA model for the cosmic ray spectrum, yielding a total spectral index $s=2+\alpha$. The total spectrum is derived from the expression [(value of the spectrum with spectral index 2) $\times$ (that of the spectrum with index $\alpha$)]. The system process that produces the spectrum with spectral index 2 may be the DSA, while the physical quantity with the additional spectral index $\alpha$ is not clear. Using Fourier deconvolution/convolution, this study provides a view from a trial study of the mechanism of the additional spectral index $\alpha$. The spectrum of particles such as protons due to DSA is written as \begin{eqnarray} \label{eqn:accSp} g(E_{\rm c})=\frac{1}{(a_0)^2+(E_{\rm c})^2}, \end{eqnarray} where $a_0$ takes a small value that is less than the peak energy $E_{0}$ at low energies. This spectrum as a function of the cosmic ray energy $E_{\rm c}$ has the form $g(E_{\rm c}) \approx (E_{\rm c})^{-2}$ with spectral index $s=2$ for energies higher than the peak energy, denoted as $a_0 \leq E_{0} <E_{\rm c}$. Using Eq. (\ref{eqn:accSp}), the observed modified spectrum $\rho(E_{\rm c})$, with the spectral index $s=2+\alpha$ for $a_0 \leq E_{0} <E_{\rm c}$, has the form \begin{eqnarray} \label{eqn:SPMod} \nonumber \rho(E_{\rm c}) =\frac{1}{(a_0)^2+(E_{\rm c})^2}\frac{1}{(E_{\rm c})^{\alpha}} \end{eqnarray} \begin{eqnarray} \label{eqn:gSpe} =g(E_{\rm c})u(E_{\rm c}), \end{eqnarray} where \begin{eqnarray} \label{eqn:usp} u(E_{\rm c})=\frac{1}{(E_{\rm c})^{\alpha}}. \end{eqnarray} \par To illustrate the physical meaning, the energy-dependent functions $\rho, g, u$ describing the energy spectra in Eqs. (\ref{eqn:accSp})$-$(\ref{eqn:usp}) are expressed by the functions $\rho_t, g_t, u_t$ in the time coordinate, respectively, using the following (Fourier or essentially equivalent inverse) transform \begin{eqnarray} \label{eqn:tFTo} \rho_t(t)=\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty} dE_{\rm c}\hspace{1ex} \exp(-iE_{\rm c}t) \rho(|E_{\rm c}|), \end{eqnarray} \begin{eqnarray} \label{eqn:tGr} g_t(t)=\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty} dE_{\rm c}\hspace{1ex} \exp(-iE_{\rm c}t) g(|E_{\rm c}|), \end{eqnarray} \begin{eqnarray} \label{eqn:Fvel} \nonumber u_t(t)=\frac{1}{\sqrt{2\pi}}\int_{-\infty}^{\infty} dE_{\rm c}\hspace{1ex} \exp(-iE_{\rm c}t) u(|E_{\rm c}|) \end{eqnarray} \begin{eqnarray} \nonumber =2\frac{1}{\sqrt{2\pi}}\int_{0}^{\infty} dE_{\rm c}\hspace{1ex} \cos(E_{\rm c}t) u(E_{\rm c}) \propto \frac{1}{|t|^{1-\alpha}} \hspace{2ex}\mbox{for}\hspace{1ex} 0 < t. \end{eqnarray} \begin{eqnarray} \end{eqnarray} Following the Fourier transform, the above equations may be divided by a factor of two, depending on the conditions. Using Eqs. (\ref{eqn:accSp})$-$(\ref{eqn:Fvel}), the convolution formula for the Fourier transform provides the relation \begin{eqnarray} \label{eqn:conv} \rho_t(t)=\int_{-\infty}^{\infty} dt^{\prime}\hspace{1ex} g_t(t-t^{\prime})u_t(t^{\prime}). \end{eqnarray} As an example, in Eq. (\ref{eqn:Fvel}), the above Fourier inverse transforms may be reduced to the Fourier cosine transforms. In the above relation, $g_t$ looks like the Green function for $u_t(t^{\prime})=\delta(t^{\prime})$, with $\delta(t^{\prime})$ being the Dirac delta function. Furthermore, $u_t(t) \propto 1/(t^{1-\alpha})=1/(t^{\beta})$ in Eq. (\ref{eqn:Fvel}) has the same form as the shock-wave mean velocity given by the Sedov solution \cite{Sedov} for the explosion of a point object centered at the spherically symmetric coordinate origin at $t=0$. For the Sedov solution, $\beta=1-\alpha=3/5$, resulting in $\alpha=2/5$, which can be roughly approximated to 0.5. This Sedov solution yields a certain contribution to the spectral index $\alpha$. Other contributions to this $\alpha$ include the possible interstellar diffusion (which is different from the DSA). The experimentally observed spectral index $\alpha$ is about 0.7, which can be roughly approximated as 0.5. If $u_t$ in Eq. (\ref{eqn:Fvel}) is regarded as the mean value of the shock velocity, the number rate of material particles such as protons entering the shock is proportional to $u_t \times$ (the density of material particles swept by the shock). This rate is referred to as the acceleration rate with the additional spectral index $\alpha$. Then, Eq. (\ref{eqn:conv}) essentially indicates that $\rho_t \propto$ (number rate of particles accelerated by the shock) with the spectral index $s=2+\alpha$; $u_t \propto$ (number rate of particles that enter the shock) with the additional index $\alpha$; and $g_t$ is the system function of the DSA with the spectral index 2. Consequently, $\rho_t(t)$ provides the corresponding energy spectrum of the cosmic rays. The derived relation states that a certain value of the spectral index $\alpha$ (with other contributions from, for example, the possible interstellar diffusion different from the DSA) added to the index 2 for the DSA in Eq. (\ref{eqn:SPMod}) may be due to the acceleration rate. This rate is proportional to the mean velocity of the shock wave, $u_{t}$; this velocity is given by the Sedov solution, which depends on the time delay (interval/distance), for the acceleration from an explosion of a star that leaves remnants. \par It has also been pointed out that the energy gain of cosmic rays from innergalactic acceleration may not be sufficient to reach the knee energy. If the quantum transition of energetic particles such as protons from high to low energy levels is taken into account, the tail of the Lorentzian spectrum for the quantum transition in the form of a polynomial $(E_{\rm c})^{-2}$ may also reach the knee at the ultraviolet cut-off energy. \par In summary, since the spectrum below the ultraviolet cut-off energy is understood from astrophysical studies, in this appendix the present study derived a spectral index (which is not the main purpose of the present article) using deconvolution/convolution of the Fourier transform. At energies below the cut-off energy, a certain contribution, with other non-DSA mechanisms, increases the spectral index of the slope above a value of two for the DSA. It has been found that this increase in the spectrum index may be due to the decreasing acceleration rate by the shock as a function of the time from an explosion of a star or a supernova. If it is considered that cosmic rays from the whole universe and/or the tail of the quantum transition spectrum, the spectrum in this low-energy regime may reach the ultraviolet cut-off energy at the knee. \par Finally, we add a note concerning a small volume element of two reference frames with coordinates $(t,x,y,z)$ and $(t^{\prime},x^{\prime},y^{\prime},z^{\prime})$, where one system is moving relative to the other in the $x$ ($x^{\prime}$) direction. It is well known that despite the length contraction in the $x$ direction and time dilation in relativity, $dtdxdydz$ is invariant, that is, $dtdx$ is invariant in the present case \cite{LanL}. Independent of the ultraviolet cut-off energy of about 3 PeV or the Planck energy, the present formalism can be used in terms of the localized functions defined in an individual space-time element of an arbitrarily shaped orthoplex obtained by dividing the space-time continuum, implying space-time quantization for classical and quantum cases. \par
\section{Introduction\label{Intr}} One of the interesting problems in cosmology is seeking for modified forms of the Newtonian potential which can cover the results of the general relativity (GR) in the Newtonian framework \cite{nc6,ncprd,fes,yc1,yc2,yc4,yc5,yc6,yc7,yc8,yc9,roos,ybh,ej,yp,m1,m2,m3,m4,m5,m6,m7,m8,ref1}. A famous example, which originally returns to Newton, is \cite{m1,m2} \begin{equation} V\left( r\right) =\left( A+\frac{B}{r}\right) V_{\mathrm{N}}\left( r\right) \text{ Type A} \label{e0} \end{equation} \noindent where $V_{\mathrm{N}}\left( r\right) =-GmM/r$ denotes the Newtonian potential and $A$ and $B$ are unknown parameters found by either fitting with the observations \cite{m1,m2,m3,m4,m5,m6,m7,m8} or using other parts of physics \cite{m9}. In cosmological setup, without working in the GR framework, one can still get the Friedmann equations by using the Hubble law and the Newtonian potential in order to write the total energy of a test particle located at the edge of the Friedmann-Robertson-Walker (FRW) universe \cite{nm,nc1,nc2,nc20,nc6,nc4,nc5,ncprd,roos}. Nevertheless, the Newtonian potential cannot provide suitable description for some questions such as the backreaction, dark matter and dark energy problems \cit {ncprd,roos,nc6} and one needs alternative theories of Newtonian gravity to avoid these difficulties \cite{ncprd}. In fact, due to pointed out problems, modified versions of the Newtonian potential such as the Yukawa potential \cite{yp} have been employed. These potentials lead to interesting results in describing gravitational phenomena \cite{ncprd,fes,yc1,yc2,yc4,yc5,yc6,yc7,yc8,yc9,ybh,ej}. Amonog different kinds of modified potentials, the below ones have attracted more attentions in studying the gravitational systems \cite{fes,yc1,yp,ybh,ej,m1 \begin{equation} V\left( r\right) =\left\{ \begin{array}{ll} V_{\mathrm{N}}\left( r\right) e^{-\alpha r}, & \text{Type B} \\ & \\ \left( 1+\beta e^{-\alpha r}\right) V_{\mathrm{N}}\left( r\right) & \text Type C \end{array \right. \label{cp} \end{equation} \noindent where $\alpha $ and $\beta $ are some constants. The possible ranges for the values of $\alpha $ and $\beta $ depend on the system. These potentials can support some kinds of black holes \cite{ybh}. It is also useful to mention that the potentials such as Type C can be obtained either by looking for the Newtonian limits of some modified GR theories \cit {yc31,yc32,yc3} or taking the probable non-local features of the Newtonian gravity into account \cite{ynl}. Further corrections to the Newtonian potential such as the logarithmic modifications can be found in Refs.~\cit {ynl,log1,log2,log3,r1}. The latter correction can successfully describe the spiral galaxies rotation curves. It is also useful to mention here that the gravitational wave (GW) astronomy is a very powerful tool to find out the more comprehensive gravitational theory \cite{corda1,corda2}. The ability of the mentioned potentials to describe the current accelerated universe has not been studied yet. So, the question whether the modifications to the Newtonian potential can provide a classical description for the dark energy remains unrevealed. In addition to this query, it is also interesting to study the cosmological consequences of the above potentials to figure out if they can provide acceptable descriptions for various gravitational systems \cit {ncprd,yc1,yc2,yc4,yc5,yc6,yc7,yc8,yc9,fes,ybh,ej,m1,m2,m3,m4,m5,m6,m7,m8,m9 . In the next section, we introduce and study three sets of modified Friedmann equations corresponding to the above introduced potentials. Next, in Sec. \ref{logsec}, after addressing a Hook correction to the Newtonian potential and investigating some of its properties, the cosmological consequences of a logarithmic modified Newtonian potential will be studied. The last section is devoted to the summary and conclusion. Throughout this paper, dot denotes the derivative with respect to time and we set $c=\hbar =1$. \section{Modified Newtonian models and dark energy} Consider an expanding box with radius $R$, filled by a fluid with energy density $\rho $, while there is a test mass $m$ on its edge \cite{roos}. In this manner, the Hubble law leads to $v=HR$ ($H$ is the Hubble parameter) for the velocity of the test particle \cite{roos}. This situation is a non-relativistic counterpart of considering a FRW universe with scale factor $a(t)$ and Hubble parameter $H\equiv \frac{\dot{a}}{a}$, enclosed by its apparent horizon, and filled by a fluid with energy density $\rho $ while the test mass $m$ is located on the apparent horizon \cite{roos}. For this setup, $r_{h}=a(t)r_{c}\equiv R$ is the radius of the apparent horizon and the system aerial volume is $V=\frac{4\pi }{3}r_{h}^{3}$ where $r_{c}$ denotes the co-moving radius of the apparent horizon \cit {ijmpd,roos,jhep,jhep1}. Since WMAP data indicates a flat universe ($r_{h} \frac{1}{H}$) \cite{roos}, we only consider the flat universe for which the aerial volume is equal to the real volume \cite{jhep,jhep1}. For a test particle with mass $m$ located at the apparent horizon (or equally the edge of the expanding box), using the Hubble law, one can write the relation between the particle velocity ($v$), the particle distance ( R=r_{h}$) and the Hubble parameter as $v=Hr_{h}$ and thus \cite{roos} \begin{equation} E=\frac{1}{2}mH^{2}r_{h}^{2}+V(r_{h}), \label{e1} \end{equation} \noindent is the total energy of the test particle. Using the potentials introduced in (\ref{e0}) and (\ref{cp}) and the total mass \begin{equation} M=\int \rho dV, \label{tm} \end{equation} \noindent Eq.~(\ref{e1}) leads t \begin{equation} H^{2}=\left\{ \begin{array}{ll} -\frac{K}{a^{2}}+\frac{8\pi G}{3}\rho \left( A+\frac{B}{r_{h}}\right) & \text{Type A} \\ & \\ -\frac{K}{a^{2}}+\frac{8\pi G}{3}\rho e^{-\alpha r_{h}}, & \text{Type B} \\ & \\ -\frac{K}{a^{2}}+\frac{8\pi G}{3}\rho \left( 1+\beta e^{-\alpha r_{h}}\right) & \text{Type C \end{array \right. \label{e2} \end{equation where $K\equiv -2E/mr_{c}^{2}$ \cite{nm,nc1,nc2,nc20,nc6,nc4,nc5,ncprd,roos . One could easily confirm that in the absence of the correction terms, relations in (\ref{e2}) recovers the Friedmann equation (at least mathematically) only if the role of curvature constant of the FRW universe is attributed to $K$ \cite{nm,nc1,nc2,nc20,nc6,nc4,nc5,ncprd,roos}. Of course, for type A, we should fix $A=1$. Since we intend to consider the case similar to flat FRW universe, we have to set $K=0$ and $r_{h}=1/H$, s \begin{equation} H^{2}=\left\{ \begin{array}{ll} \frac{8\pi G}{3}\rho \left( 1+BH\right) & \text{Type A} \\ & \\ -\frac{8\pi G}{3}\rho e^{-\frac{\alpha }{H}}, & \text{Type B} \\ & \\ -\frac{8\pi G}{3}\rho \left( 1+\beta e^{-\frac{\alpha }{H}}\right) & \text Type C \end{array \right. \label{ye1} \end{equation In the remaining of this section, we will study the ability of these models to describe the dark energy effects. \subsection{Type A} By making the definition for density due to type A modification a \begin{equation} \rho _{A}=\frac{3H^{2}}{8\pi G}\left( \frac{BH}{1+BH}\right) , \end{equation} one could rewrite the first relation in (\ref{ye1}) as \begin{equation} 3H^{2}=8\pi G\left( \rho +\rho _{A}\right) . \end{equation So, the density parameter is $\Omega _{A}\equiv 8\pi G\rho _{A}/3H^{2}=BH/\left( 1+BH\right) $. Clearly, since $H\geq 0$ during the cosmic evolution, $\Omega _{A}$ is always positive only if $B>0$. Therefore, density parameter $\Omega _{A}$ decreases as $H$ decreases ($d\Omega _{A}/dH>0$). It means that $\rho _{A}$ cannot play the role of dark energy in the current universe. \subsection{Type B} We consider a background filled by a pressureless source \cite{nc4} with energy density $\rho =\rho _{0}a^{-3}=\rho _{0}(1+z)^{3}$, where $\rho _{0}$ is the current value of the dust density \cite{roos}, $a$ is scale factor and $z=a^{-1}-1$ is redshift. Now, using the second relation in~(\ref{ye1}), and by defining the density parameter $\Omega _{B}=1-e^{\frac{\alpha }{H}}$ (or equally $\rho _{B}=3H^{2}(1-e^{\frac{\alpha }{H}})/8\pi G$), one finds \begin{equation} z(\Omega _{B})=\left( \frac{\gamma (1-\Omega _{B})}{\ln ^{2}(1-\Omega _{B}) \right) ^{1/3}-1, \label{zo0} \end{equation} \noindent where $\gamma =3\alpha ^{2}/8\pi G\rho _{0}$ is an unknown parameter found by fitting the theory with observations. If the value of \rho _{0}$ is known, finding possible values for $\gamma $ leads to possible values for $\alpha $. It is also worthwhile mentioning that since $\alpha ^{2}$ and $\rho _{0}$ are positive, Eq. (\ref{zo0}) implies that $z\geq -1$ for $\Omega _{B}\leq 1$. In addition, by taking the second relation of (\re {ye1}) into account, one can easily obtain \begin{eqnarray} &&3H^{2}=8\pi G\left( \rho +\rho _{B}\right) , \label{py1} \\ && \notag \\ &&3H^{2}+2\dot{H}=-8\pi Gp_{B}, \label{py12} \end{eqnarray} \noindent where \begin{eqnarray} &&p_{B}=-(\frac{\dot{\rho}_{B}}{3H}+\rho _{B})= \notag \label{py2} \\ &&-\left[ \rho _{B}+\frac{\dot{H}}{H^{2}}\left( \rho _{B}(2-\frac{\alpha }{H )+\frac{3\alpha H}{8\pi G}\right) \right] , \end{eqnarray} \noindent which clearly shows that $p_{B}\rightarrow -\rho _{B}$ when $\dot{ }\rightarrow 0$. In this manner, it is easy to see that $\Omega _{B}=1-e^ \frac{\alpha }{H}}=8\pi G\rho _{B}/3H^{2}$ is indeed the density parameter corresponding to a fluid with energy density $\rho _{B}$. In fact, by this way, we simulated the modification to Newtonian potential as a hypothetical fluid with energy density $\rho _{B}$ and pressure $p_{B}$ which has no interaction with the pressureless energy source $\rho $. In addition, the deceleration and total state parameters of type B model are also defined as q_{B}=-1+\frac{1+z}{H(z)}\frac{dH(z)}{dz}$ and $\omega _{B}\equiv \frac{p_{B }{\rho _{B}+\rho }=\frac{2}{3}(q_{B}-\frac{1}{2})$. Differentiating Eq. (\re {py1}) with respect to $z$ and using the definitions for $q_{B}$, $\rho \left( z\right) $, $\rho _{B}$ and $\Omega _{B}$ one could obtai \begin{equation} q_{B}=\frac{3(1+z)^{3}\Upsilon ^{2}}{\gamma (\Omega _{B}-1)(\Upsilon -2)}-1. \end{equation where $\Upsilon =\ln (1-\Omega _{B})$. In Fig. (\ref{py}), $q_{B}$ and $\Omega _{B}$ have been plotted for $\gamma =12\cdot 9$. For this value of $\gamma $, we have $z_{t}\simeq 0\cdot 68$ where $z_{t}$ is transition redshift at which the universe leaves the matter dominated era and enters an accelerated era (or equally $q(z_{t})=0$). It is remarkable to mention that, for $\gamma >0$, $q_{B}\rightarrow -1$ and \Omega _{B}\rightarrow 1$ as $z\rightarrow -1$ and $q_{B}\rightarrow \frac{ }{2}$ and $\Omega _{B}\rightarrow 0$ for $z\gg 1$. Therefore, bearing the mutual relation between $\omega _{B}$ and $q_{B}$ in mind, one can easily find that $\omega _{B}(z\rightarrow -1)\rightarrow -1$ and $\omega _{B}(z\gg 1)\rightarrow 0$ that is a desired result. Moreover, our numerical calculations show that whenever $9\cdot 5\leq \gamma \leq 23$, we have 0\cdot 5\leq z_{t}\leq 1$, $0\cdot 771\leq \Omega _{B}(z=0)\leq 0\cdot 847$ and $-0\cdot 1366\leq q_{B}(z=0)\leq -0\cdot 2261$. For the current universe, observations indicate $q_{B}(z=0)\leq -\frac{1}{2}$ \cite{roos}. This result is obtainable in type B model if $\gamma >23$. However, in this case, $z_{t}>1$ and $\Omega _{B}(z=0)>0\cdot 847$. In order to study the classical stability of the obtained dark energy candidate, one should use the squared speed of sound \begin{eqnarray} v_{sB}^{2} &=&\frac{dp_{B}}{d\rho _{B}}=\frac{dp_{B}/dH}{d\rho _{B}/dH} \notag \\ &=&\frac{2\Upsilon ^{-1}\left( \Upsilon ^{-1}-1\right) \left( 1-2\Upsilon ^{-1}\right) ^{-2}}{1-\Omega _{B}\left( 1-2\Upsilon ^{-1}\right) }. \end{eqnarray $v_{sB}^{2}$ is plotted in Fig.~(\ref{py}). It shows instability for all z $ values specially at present time $z=0$. This is a common behavior for many of the models for dark energy \cite{stab,istab,istab1}. \begin{figure}[t] \centering \includegraphics[width=.45\textwidth]{omy-qy.eps} \caption{The behaviors of $\Omega _{B}$ (solid line), the deceleration parameter $q_{B}$ (dashed line) and squared speed of sound $v_{sB}^{2}$ (dotted line) in term of $z$ with $\protect\gamma =12\cdot 9$ for type B modified Newtonian model.} \label{py} \end{figure} \subsection{Type C} \begin{figure*}[t] \includegraphics[width=.46\textwidth]{pcy1.eps}\label{pcy} \includegraphics[width=.46\textwidth]{stab1.eps}\label{stab1} \caption{The behaviors of $\Omega_{C}$, $q_{C}$ and $v_{sC}^{2}$ in term of $z$ with $\protect\gamma =108\cdot 843537$ and $\protect\beta =0\cdot 007696$} \label{fig1} \end{figure*} Now, we focus on the third model obtained by using the second potential in \ref{cp}). The third relation in~(\ref{ye1}) can be rewritten as \begin{equation} 3H^{2}=8\pi G\left( \rho +\rho _{C}\right) , \label{e4} \end{equation where $\rho _{C}=3\beta H^{2}e^{-\frac{\alpha }{H}}/8\pi G\left( 1+\beta e^{ \frac{\alpha }{H}}\right) $. Indeed, we stored the effects of deviation from the Newtonian potential into $\rho _{C}$. Again, we consider a dust source \cite{nc4} satisfying ordinary energy-momentum conservation law ($\dot{\rho _{C}=-3H\rho _{C}$). Thus, if an unknown pressure $p_{C}$ is attributed to the hypothetical fluid with energy density $\rho _{C}$, then we should have \begin{equation} \dot{\rho}_{C}+3H(\rho _{C}+p_{C})=0. \label{emc1} \end{equation Now, combining the above relations with each other, one receives \begin{eqnarray} &&3H^{2}+2\dot{H}=-8\pi Gp_{C}, \label{e41} \\ && \notag \\ &&\dot{H}=-4\pi G(\rho +\rho _{C}+p_{C}), \end{eqnarray in which \begin{eqnarray} &&p_{C}=-(\frac{\dot{\rho}_{C}}{3H}+\rho _{C})= \notag \\ &&-\frac{\rho _{C}}{3}\left[ \frac{\dot{H}}{H^{2}}\left( 2+\frac{\alpha }{H \left( 1+\frac{8\pi G}{3}\rho _{C}\right) \right) +3\right]. \label{p} \end{eqnarray Eq. (\ref{p}) shows that $p_{C}\rightarrow -\rho _{C}$ whenever $\dot{H \rightarrow 0$. It is also remarkable to note that, even without assuming Eq.~(\ref{emc1}), one can obtain Eq.~(\ref{e41}) and the second line of Eq.~ \ref{p}) by combining the time derivative of Eq.~(\ref{e4}) with itself and using this fact that the $\rho $ source is pressureless. In summary, we found out that the effects of deviation from the Newtonian potential can be simulated as a hypothetical fluid with energy density $\rho _{C}$ and pressure $p_{C}$. The density parameter of this fluid can be calculated as \begin{equation} \Omega _{C}=\frac{8\pi G\rho _{C}}{3H^{2}}=\frac{\beta e^{-\frac{\alpha }{H} }{1+\beta e^{-\frac{\alpha }{H}}}. \label{dp} \end{equation} \noindent The deceleration and total state parameters of the model can also be obtained by using $q_{C}=-1+(1+z)(dH(z)/dz)/H(z)$ and $\omega _{C}\equiv p_{C}/\left( \rho _{C}+\rho \right) $, respectively. Bearing the $\rho =\rho _{0}(1+z)^{3}$ in mind and combining the above equation with the corresponding Friedmann equation~(\ref{e4}), we easily reach \begin{equation} z(\Omega _{C})=\left( \frac{\gamma \left( 1-\Omega _{C}\right) }{\ln ^{2}\left( \frac{\beta \left( 1-\Omega _{C}\right) }{\Omega _{C}}\right) \right) ^{1/3}-1. \label{zo1} \end{equation \noindent Eq.~(\ref{zo1}) implies that $z\geq -1$ for $\Omega _{C}\leq 1$. Calculations for the total state and deceleration parameters also lead to \omega _{C}=\frac{2}{3}(q_{C}-\frac{1}{2})$ and \begin{equation} q_{C}=\frac{1-\Omega _{C}\ln \left( \frac{\Omega _{C}}{\beta (1-\Omega _{C}) \right) }{2+\Omega _{C}\ln \left( \frac{\Omega _{C}}{\beta (1-\Omega _{C}) \right) }. \label{dpf2} \end{equation These results clearly show that $q_{C},\omega _{C}\rightarrow -1$ as $\Omega _{C}\rightarrow 1$ (or equally $z\rightarrow -1$) and also $q_{C}\rightarrow \frac{1}{2}$ and $\omega _{C}\rightarrow 0$ as $\Omega _{C}\rightarrow 0$ (or equally $z\gg 1$). In Fig.~(\ref{fig1}), we depict the behaviors of $\Omega _{C}$ and $q_{C}$ with respect to $z$ by choosing suitable constants so that the observation constraints are satisfied. It is worthwhile to note again that the value of \alpha $ can be found by specifying the value of $\rho _{0}$ from observation and inserting it in $\alpha =\sqrt{8\pi \rho _{0}G\gamma /3}$ (see below Eq.~(\ref{zo0})). In Fig. (\ref{fig1}), we have plotted the behavior of $v_{sC}^{2}$ given by \begin{equation} v_{sC}^{2}=\frac{dp_{C}}{d\rho _{C}}=\frac{dp_{C}/dH}{d\rho _{C}/dH}. \label{vs} \end{equation Since the expression for $v_{sC}^{2}$ is too long, we have omitted it here. As one can see from Fig. (\ref{fig1}), similar to type B and many of the dark energy models \cite{stab,istab,istab1}, Type C shows instability at present time too. \section{Logarithmic Modification (type D) and Dark Energy\label{logsec}} \begin{figure*}[t] \includegraphics[width=.31\textwidth]{qD.eps}\label{phi1} \includegraphics[width=.31\textwidth]{vsD.eps}\label{stab2} \includegraphics[width=.31\textwidth]{omD.eps}\label{phi2} \caption{The behaviors of $\Omega _{D}$, $q_{D}$ and $v_{sD}^{2}$ in term of $z$ for $\protect\eta =240$ and $\protect\delta =122.5$ with $H\left( z=0\right) =67$ $km/\left( sMpc\right) $, $G=1$ and the current matter density parameter $\Omega \left( z=0\right) =0\cdot 3$.} \label{figphi} \end{figure*} Observations indicate that the universe is homogeneous and isotropic in the scales larger than $100$-Mpc. Moreover, the energy density of the dominant cosmic fluid ($\Lambda $) is approximately constant at the mentioned scales \cite{roos}. In the Newtonian language, these results can be summarized as \begin{equation} \frac{1}{r^{2}}\left[ \frac{d}{dr}\left( r^{2}\frac{d\phi }{dr}\right) \right] =4\pi G\Lambda , \label{ho1} \end{equation which finally leads to \begin{equation} \phi (r)=\frac{2\pi G}{3}\Lambda r^{2}-\frac{C}{r}, \label{ho2} \end{equation for the modified Kepler potential of the energy source confined to the radius $r$. Here, $C$ is the integration constant, and in order to cover the Kepler potential ($-GM/r$) at the appropriate limit $\Lambda =0$, we should set $C=GM$, where $M$ is the mass content of system. Thus, the modified Newtonian potential felt by the test mass $m$ located at radius $r$ can be written as \cite{mz,h1} \begin{equation} V(r)\equiv m\phi (r)=\frac{2\pi Gm}{3}\Lambda r^{2}+V_{\mathrm{N}}(r). \label{ho30} \end{equation It means that if we modify the Newtonian potential by a Hook term at the cosmic scales larger than $100$-Mpc, then the constant energy density obtained by the observations may be justified. Such potential can also be obtained in the non-local Newtonian gravity framework \cite{ynl}. The light bending problem in the presence of the above potential has also been studied in Ref. \cite{mz}. More studies on the above potential can be found in Ref. \cite{h1} and references therein. Now, following the recipe used in this paper to find the Friedmann equations in the Newtonian framework, one can easily reach \begin{equation} H^{2}=\frac{8\pi G}{3}\left( \rho +\frac{\Lambda }{2}\right) , \label{ho3} \end{equation which has an additional coefficient $1/2$ for the $\Lambda $ term in comparison with the standard Friedmann equation in the presence of the cosmological constant. This additional coefficient will be disappeared if we modify the right hand side of Eq.~(\ref{ho1}) as $8\pi G\Lambda $. It means that the flux corresponding to the $\Lambda $ source is two times greater than those of the ordinary known sources. In this manner, the modified Kepler potential~(\ref{ho2}) finally takes the form \begin{equation} \phi (r)=\frac{4\pi G}{3}\Lambda r^{2}-\frac{GM}{r}. \label{ho3f} \end{equation Also, the corresponding Friedmann equations will be the same as those of the standard cosmology in the presence of the cosmological constant. The Kepler potential modified by a logarithmic term which can describe the spiral galaxies rotation curves \cite{log1,log2,log3} is written as \begin{equation} \Phi (r)=-\frac{GM}{r}-\delta GM\ln (\eta r), \label{g1} \end{equation} where $\delta $ and $\eta $ are some constants found by fitting the results with observations \cite{log1,log2,log3}. The potential (\ref{g1}) can be obtained by various ways (see~\cite{ynl} and references therein for details). Multiplying (\ref{g1}) by $m$, one can get the corresponding Newtonian potential felt by the test mass $m$ as \begin{equation} V(r)=V_{\mathrm{N}}(r)-\delta GmM\ln (\eta r),\text{ Type D} \end{equation} \noindent in accordance with the results of the non-local Newtonian gravity \cite{ynl}. Calculations for the cosmological equations corresponding to this potential lead to \begin{equation} 3H^{2}=8\pi G\left( \rho +\rho _{D}\right) , \label{g3} \end{equation where the energy density of the pressureless source is $\rho =\rho _{0}(1+z)^{3}$ an \begin{equation} \rho _{D}=\frac{3H^{2}}{8\pi G}\left( \frac{\delta \ln (\frac{H}{\eta })} \delta \ln (\frac{H}{\eta })-H}\right) . \end{equation One could also obtai \begin{equation*} 3H^{2}+2\dot{H}=-8\pi Gp_{D}, \end{equation* where $p_{D}=-\dot{\rho}_{D}/3H-\rho _{D}$ is a pressure originated from the logarithmic term. Hence, the density parameter is $\Omega _{D}=\delta \ln \left( \frac{H}{\eta }\right) /\left( \delta \ln \left( \frac{H}{\eta \right) -H\right) $. Clearly, whenever $\delta >0$, we have $\Omega _{D}\rightarrow 0$ ($\Omega _{D}\rightarrow 1$) for $H\rightarrow \eta $ ( H\rightarrow 0$). In Fig.~(\ref{figphi}), $\Omega _{D}$ and $q_{D}$ have been plotted with respect to $z$. We have not presented the explicit form of q_{D}=-1+(1+z)(dH(z)/dz)/H(z)$ here since it is too long. Fig. (\ref{figphi}) shows that $q_{D}\rightarrow \frac{1}{2}$ when $z\rightarrow z_{\eta }$, where $z_{\eta}$ denotes the redshift at which $H$ reaches its maximum possible value in this model, and hence, the value of $H$ at the beginning of the matter dominated era is a proper candidate for this maximum. Finally, we should note that since the total state parameter of type D is defined as $\omega_{D}\equiv p_{D}/\left( \rho +\rho_{D}\right) =\frac{2}{3}(q_{D}-\frac{1}{2})$, it is obvious that $\omega_{D}$ also exhibits satisfactory behaviors. $v_{sD}^{2}=dp_{D}/d\rho_{D}$ has been plotted in Fig.~(\ref{figphi}). It is apparent that none of the obtained models are stable for $z<0\cdot 1$. \section{Concluding remarks} Considering various modified Newtonian potentials, the Hubble law and the classical total energy of a test mass located at the edge of the universe, we could obtain some modified forms of the Friedmann equations. In this formalism, it has been obtained that some corrections to the Newtonian potential may model the current accelerated universe, and hence, dark energy. The interesting point is the ability of some of these corrected potentials in describing the spiral galaxies rotation curves. The latter fact signals that dark matter and dark energy may have some common origins and aspects \cite{dara}. In fact, since all of the obtained models address an accelerated universe, one may conclude that the dark sides of cosmos may have at least some common roots. Consequently, from this standpoint, a more complete modified Newtonian potential may model the dark sides of cosmos simultaneously. \section*{Acknowledgments} We are grateful to the anonymous reviewers for worthy comments. MKZ would like to thank Shahid Chamran University of Ahvaz, Iran for supporting this work. The work of H. Moradpour has been supported financially by Research Institute for Astronomy \& Astrophysics of Maragha (RIAAM) under research project No. $1/5440-60$.
\section{introduction} There have been already great amounts of results in the classification program of C*-algebras, which is proposed by George A. Elliott, see for example \cite{G}. As it is well known, the main ingredients for the classification program involve two parts, i.e., existence theorems and uniqueness theorems. Among the proof of existence theorems, K. Thomsen and L. Li established some approximation results of a Markov operator by an average of homomorphisms, see \cite{Th} and \cite{Li}; especially, Li's theorem achieves the improvement that the number of homomorphisms used for the approximation only depends on the given data of a finite subset and a tolerance. However, all such results are of concern with homogeneous C*-algebras $\mathrm{C}(X)$, the algebra of continuous functions on some compact metrizable space $X$. There are also many subhomogeneous C*-algebras, i.e., subalgebras of $\mathrm{C}(X)$. In the case of the unit interval, X. Jiang and H. Su studied the typical subhomogeneous algebras: splitting interval algebras and dimension drop interval algebras, see \cite{JS1} and \cite{JS2}. Moreover, there are even natural non-unital subhomogeneous algebras, for example, the building blocks considered in \cite{Rak}, they are stably projectionless. For such algebras, one cannot apply Thomsen and Li' results directly, it is desirable to establish some non-unital version of their theorems. In this paper, we will try to do so. To be precise, we investigate the approximation problem for a Markov operator on homogeneous algebras preserving certain subspace, which indicates certain subhomogeneity. We want to use an average of homomorphisms on homogeneous algebras to do an approximation, additionally we require that the average also preserves the same subspace. In this paper, first of all we present such an approximation for $\mathrm{C}[0,1]$ with a subspace to be specified from certain C*-algebras. Consider the following C*-algebra (see e.g. \cite{Rak}): $$\begin{aligned} B(a,k)=\Big\{&f\in \mathrm{C}[0,1]\otimes \textrm{M}_m\ |\ f(0)=\left( \begin{array}{cc} W\otimes id_a & \\ & 0\otimes id_{k} \\ \end{array} \right),\\ &f(1)=W\otimes id_{a+k}, W\in \textrm{M}_n\Big\}, \end{aligned} $$ where $a$ and $k$ are natural numbers, and $m$ and $n$ are proper integers. Such a C*-algebra is non-unital and stably projectionless. The space of continuous affine functions on tracial cone of $B(a,k)$ is isomorphic to the subspace $\mathrm{C}[0,1]_{(a,k)}$ of $\mathrm{C}[0,1]$ given by: $$\mathrm{C}[0,1]_{(a,k)}=\{f\in \mathrm{C}[0,1]\mid f(0)=\frac{a}{a+k}f(1)\},$$ (see Proposition 2.1 of \cite{Rak}). The first main result of this paper is the following theorem: \begin{thrm}\label{thm1} Given any finite subset $ F \subset C[0,1]_{(a,k)}$ and $\epsilon>0$, there is an integer $ N>0$ with the following property: for any unital positive linear map $\phi$ on $C[0,1]$ which preserves $C[0,1]_{(a,k)}$, there are N homomorphisms $\phi_{1},\phi_{2},...,\phi_{N}$ from $C[0,1]$ to $C[0,1]$ such that $\dfrac{1}{N}\sum\limits_{i=1}^{N}\phi_{i}(f)$ belongs to $C[0,1]_{(a,k)}$ for all $f\in C[0,1]_{(a,k)}$ and $$\|\phi(f)-\frac{1}{N}\sum\limits_{i=1}^N\phi_{i}(f)\| < \epsilon$$ for all $f\in F$. \end{thrm} For the case of different subspaces $\mathrm{C}[0,1]_{(a,k)}$ and $\mathrm{C}[0,1]_{(b,k)}$, there is no unital positive linear map on $\mathrm{C}[0,1]$ which sends $\mathrm{C}[0,1]_{(a,k)}$ to $\mathrm{C}[0,1]_{(b,k)}$ if $b<a$, see Remark \ref{b<a}. So we only need to deal with the case $b>a$. \begin{thrm}\label{thm2} Given any finite subset $ F \subset C[0,1]_{(a,k)}$ and $\epsilon>0$, any unital positive linear map $\phi$ on $C[0,1]$ which sends $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)}$ with $b>a$, then there are N homomorphisms $\phi_{1},\phi_{2},...,\phi_{N}: C[0,1]\rightarrow C[0,1]$ such that $\dfrac{1}{N}\sum\limits_{i=1}^N\phi_{i}(f)$ belongs to $C[0,1]_{(b,k)}$ for all $f\in C[0,1]_{(a,k)}$ and \[ \|\phi(f)-\frac{1}{N}\sum_{i=1}^N\phi_{i}(f)\| < \epsilon\] for all $f\in F$. \end{thrm} In general, we replace $\frac{a}{a+k}$ by $\alpha\in(0,1)$ and $[0,1]$ by path connected compact metrizable spaces $X$ and $Y$. Let $p, q$ and $z, w$ be fixed points in $X$ and $Y$ respectively, define $$\mathrm{C}(X)_{(p,q,\alpha)}=\{f\in \mathrm{C}(X) \mid f(p)=\alpha f(q)\},$$ and $$\mathrm{C}(Y)_{(z,w,\beta)}=\{f\in \mathrm{C}(X) \mid f(z)=\beta f(w)\}.$$ Then we have the following generalizations: \begin{thrm}\label{thm3} Suppose that $X$ is a path connected compact metrizable space, $Y$ is a compact metrizable space. For any finite subset $ F \subset C(X)_{(p,q,\alpha)}$ and $\varepsilon>0$. There is an integer $ N>0$ with the following property: for any unital positive linear map $\phi:C(X)\rightarrow C(Y)$ which sends $C(X)_{(p,q,\alpha)}$ to $ C(Y)_{(z,w,\alpha)}$, then there are N homomorphisms $\phi_{1},\phi_{2},...,\phi_{N}:C(X)\rightarrow C(Y)$ such that $\dfrac{1}{N}\sum\limits_{i=1}^{N}\phi_{i}(f)$ belongs to $C(Y)_{(z,w,\alpha)}$ for all $f\in C(X)_{(p,q,\alpha)}$ and $$\|\phi(f)-\frac{1}{N}\sum\limits_{i=1}^N\phi_{i}(f)\| < \epsilon$$ for all $f\in F$. \end{thrm} \begin{thrm}\label{thm4} Suppose that $X$ is a path connected compact metrizable space, $Y$ is a compact metrizable space, and $\alpha$, $\beta$ are rational numbers with $\beta>\alpha$. For any finite subset $ F \subset C(X)_{(p,q,\alpha)}$ and $\varepsilon>0$, any unital positive linear map $\phi:C(X)\rightarrow C(Y)$ which sends $C(X)_{(p,q,\alpha)}$ to $ C(Y)_{(z,w,\beta)}$, there are N homomorphisms $\phi_{1},\phi_{2},...,\phi_{N}:C(X)\rightarrow C(Y)$ such that $\dfrac{1}{N}\sum\limits_{i=1}^{N}\phi_{i}(f)$ belongs to $C(Y)_{(z,w,\beta)}$ for all $f\in C(X)_{(p,q,\alpha)}$ and $$\|\phi(f)-\frac{1}{N}\sum\limits_{i=1}^N\phi_{i}(f)\| < \epsilon$$ for all $f\in F$. \end{thrm} To achieve these results, we keep tracking the approximation process of Li's theorem in \cite{Li}, and the crucial point is that we must argue if we are able to choose proper eigenvalue maps to define homomorphisms such that their average preserves the subspace. The existence of such a choice relies on an analysis of the measures induced by evaluations of a given Markov operator at 0 and 1. The paper is organized as follows. Section 2 contains some preliminaries about Markov operators, and basic properties of the subspace $\mathrm{C}[0,1]_{(a,k)}$ of $\mathrm{C}[0,1]$. In Section 3, concrete analysis of the measures induced by evaluations of a given Markov operator at 0 and 1 are given, and based on this the proof of Theorem \ref{thm1} and \ref{thm2} are presented. Section 4 gives the general case of the approximation results of Theorem \ref{thm3}, \ref{thm4}. \section{preliminaries} \begin{definition} Given compact Hausdorff spaces $X$ and $Y$, a Markov operator $T$ from $C(X)$ to $C(Y)$ is a unital positive linear map. \end{definition} The set of Markov operators forms a convex set of bounded operators, and it is well known that the extreme points are the unital homomorphisms, see \cite{Est}. K. Thomsen and L. Li proved a Krein-Milman type theorem for Markov operators, which is frequently used in the classification program for establishing existence theorems. What we are concerned with is for the case of subhomogeneous algebras, see for example, \cite{JS1}, \cite{JS2}, etc.. In S. Razak's paper \cite{Rak}, he considered certain stably projectionless building blocks--necessarily non-unital. The space of continuous affine functions on this building block's tracial cone is a non-unital subspace of $C[0,1]$, see Proposition 2.1 in \cite{Rak}. Therefore, we consider Markov operators on homogeneous algebras which preserve this subspace. Fix a positive integer $a$ and a positive integer $k$, denote by $C[0,1]_{(a,k)}$ the subspace of $C[0,1]$: $$C[0,1]_{(a,k)}=\{f\in C[0,1]\mid f(0)=\frac{a}{a+k}f(1)\}.$$ Next we shall see some examples of Markov operators on $C[0,1]$ which preserve this subspace. \begin{itemize} \item Example 1: Choose a continuous function $\lambda: [0,1]\rightarrow [0.1]$ with $\lambda(0)=0$ and $\lambda(1)=1$, define a Markov operator $T$ from $C[0,1]$ to $C[0,1]$ by $T(f)=f\circ \lambda$, then $T$ sends functions in $C[0,1]_{(a,k)}$ to $C[0,1]_{(a,k)} $. \item Example 2: Choose two continuous functions $\lambda_1$ and $\lambda_2$ on the unit interval with $\lambda_1(0)=0, \lambda_1(1)=1$ and $\lambda_2(0)=1, \lambda_2(1)=0$, and choose proper $k_1>k_2\geq0$, then one can define a Markov operator $T$ on $C[0,1]$ as follows: $$T(f)=\frac{k_1f\circ\lambda_1+k_2f\circ\lambda_2}{k_1+k_2}.$$ Then $T$ sends functions in $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)}$, where $b=\dfrac{k_1a+k_2a+k_2k}{k_1-k_2}\geq0$. \item Example 3: In general, one has similar examples which involve more points. Choose the $\lambda_1, \lambda_2$ above, and $\lambda_3(t)=1/2$ (one can pick up any point in the middle), then one can choose proper $k_1, k_2$ to define a Markov operator $T$ as follows: $$T(f)(t)=\frac{k_1f\circ\lambda_1+k_2f\circ\lambda_2+s(t)f\circ\lambda_3}{k_1+k_2+s(t)},$$ where $s(t)=(\dfrac{k_1a}{k+a}+k_2)(1-t)+(\dfrac{k_2a}{k+a}+k_1)t$. One can verify that $T$ sends functions in $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)}$ for some $b>0$. This process can continue to involve more points in $[0,1]$. \end{itemize} The following direct sum decomposition holds. \begin{lem}\label{lem:direct} $ C[0,1]=C[0,1]_{(a,k)}\oplus \mathbb{R}.$ \end{lem} \begin{proof} Suppose $f\in C[0,1]$, let $\lambda=\frac{(a+k)f(0)-af(1)}{k},\;g(x)=f(x)-\lambda$ Then $f(x)=\lambda+g(x)$ and $g(x)\in C[0,1]_{(a,k)}$. Next we show the decomposition is unique. Assume $f(x)=g_{1}(x)+\lambda_{1}=g_{2}(x)+\lambda_{2}$. Then $ \lambda_{1}-\lambda_{2}=g_{1}(x)-g_{2}(x)$ for any $x\in[0,1]$. It follows that $ \lambda_{1}-\lambda_{2}=g_{1}(0)-g_{2}(0)=g_{1}(1)-g_{2}(1)$ for any $x\in[0,1]$. But $g_{1}(0)-g_{2}(0)=\frac{a}{a+k}(g_{1}(1)-g_{2}(1))$. Since $a\neq0$, we have $\lambda_{1}=\lambda_{2}$ and $g_{1}(x)=g_{2}(x)$. \end{proof} In the dual viewpoint, one might consider positive linear maps on these subspaces which extend to Markov operators on $C[0,1]$. Based on the direct sum decomposition, any positive linear map $\phi$ from $C[0,1]_{(a,k)}$ to $C[0,1]$ can be extended naturally to a unital linear map $\widetilde{\phi}$ from $C[0,1]$ to $C[0,1]$, given as $\widetilde{\phi}(f)=\lambda+\phi(g)$. Moreover, this algebraic extension needs to be positive. \begin{definition}\label{th:lsc} A positive linear map $\phi$ from $C[0,1]_{(a,k)}$ to $C[0,1]$ is called positively extendible if $\widetilde{\phi}$ is still positive. \end{definition} First, it is not hard to see that if $\phi$ is positively extendible, then it must be a contraction. However, we point out that the converse is not true, even in the case $\phi$ is of norm one. \begin{remark} Fix a $x_{0}\in (0,1)$, define a map $\phi$ from $C[0,1]_{(a,k)}$ to $C[0,1]$ as $\phi(g)(x)=g(x_{0})\frac{a+kx}{a+k}$ for any $g\in C[0,1]_{(a,k)}$. It is obvious that $\phi$ is positive and linear. Moreover, $\phi$ has norm one. First, for any $g\in C[0,1]_{(a,k)}$, $\|\phi(g)\|=\sup_{x\in[0,1]}|\phi(g)(x)|=\sup_{x\in[0,1]}|g(x_{0})\frac{a+kx}{a+k}|\leq\|g\|$. Next we choose a function for which the supreme reaches one. Define a function $g_1(x)$ as follows $$g_{1}(x)=\begin{cases} \frac{a}{a+k}+\frac{(1-\frac{a}{a+k})x}{x_{0}} & x\in[0,x_{0}] \\ 1 & x\in(x_{0},1], \\ \end{cases}$$ then $\|\phi(g_{1})\|=sup_{x\in[0,1]}|\phi(g_{1})(x)|=sup_{x\in[0,1]}|g_{1}(x_{0})\frac{a+kx}{a+k}|=\|g_1\|=1$. However, the natural extension $\widetilde{\phi}$ is not positive. Choose $$f(x)=\begin{cases} 0 & x\in[0,x_{0}] \\ \frac{k}{1-x_{0}}(x-1)+k & x\in(x_{0},1] ,\\ \end{cases}$$ then $f(x)\geq0$, consider its direct sum decomposition $f=\lambda+g$, where $\lambda=\frac{(a+k)f(0)-af(1)}{k}=-a$ and $$g(x)=\begin{cases} a & x\in[0,x_{0}] \\ \frac{k}{1-x_{0}}(x-1)+a+k & x\in(x_{0},1].\\ \end{cases}$$ Then $\widetilde{\phi}(f)(x)=\lambda+\phi(g)=-a+a\frac{a+kx}{a+k}=\frac{ak(x-1)}{a+k}\leq0$. \end{remark} Although the constant function 1 is not in $C[0,1]_{(a,k)}$, we still can approximate it using special functions in the subspace, which are referred as test functions. Moreover, the behavior of a positive linear map on the test functions indicate the positivity of its extension. \begin{definition} For each $1\geq\delta>0$, a lower test function $e_{\delta}\in C[0,1]_{(a,k)}$ is a continuous function which has value 1 on $[\delta,1]$ and has value $\frac{a}{k+a} $ at 0. Denote by $L$ the set of all such lower test functions. For each $1>\sigma\geq0$, a upper test function $\gamma_{\sigma}\in C[0,1]_{(a,k)}$ is a continuous function which has value 1 on $[0,1-\sigma]$ and has value $\frac{a+k}{a}$ at 1. Denote by $S$ the set of all such upper test functions. \end{definition} \begin{prop} Let there be given a positive linear map $\phi$ from $C[0,1]_{(a,k)}$ to $C[0,1]$, then $\phi$ is positively extendible if and only if the following estimation holds: $\inf\limits_{\gamma\in S}\{\phi(\gamma)\}\geq1\geq \sup\limits_{e\in L}\{\phi(e)\}$ . \end{prop} \begin{proof} First suppose $\phi$ is positively extendible, then $\widetilde{\phi}$ is positive. For any $\gamma\in S, e\in L$, $\gamma>1>e$,$\widetilde{\phi}(\gamma)\geq1\geq\widetilde{\phi}(e)$, then $\phi(\gamma)\geq1\geq\phi(e)$, and $\inf\limits_{\gamma\in S}\{\phi(\gamma)\}\geq1\geq \sup\limits_{e\in L}\{\phi(e)\}$. Conversely, suppose $\inf\limits_{\gamma\in S}\{\phi(\gamma)\}\geq1\geq \sup\limits_{e\in L}\{\phi(e)\}$, we need to show $\widetilde{\phi}: C[0,1]\rightarrow C[0,1]$ defined by $\widetilde{\phi}(f)=\lambda+\phi(g)$ is positive. For $f\in C[0,1]$ and $f\geq0$ with the decomposition $f=\lambda+g $, then we need to show $\widetilde{\phi}(f)=\lambda+\phi(g)\geq0$. Thus we need to prove $\phi(g)\geq-\lambda$ if $g\geq-\lambda$. $\mathit{Case I:}$ If $\lambda=0$, then $f\in C[0,1]_{(a,k)}$, we have $\widetilde{\phi}(f)=\phi(f)\geq0 $ since $f\geq0$ and $\phi$ is positive. $\mathit{Case II:}$ If $\lambda<0$, then $-\lambda>0$, then we can find a $\gamma_{\sigma}\in S$ such that $(-\lambda)\gamma_{\sigma}\leq g$. Since $\phi$ is positive, one has that $\phi(g)\geq \phi(-\lambda\gamma_{\sigma})=-\lambda\phi(\gamma_{\sigma})\geq -\lambda$. $\mathit{Case III:}$ If $\lambda>0$, then $-\lambda<0$, then we can find a $e_{\delta}\in L$ such that $g\geq -\lambda e_{\delta}$. Since $\sup\limits_{0<\delta\leq1}\phi(e_{\delta})\leq1$, one has $-\lambda\phi(e_{\delta})\geq -\lambda$. Therefore, $\phi(g)\geq-\lambda\phi(e_{\delta})\geq-\lambda$. Hence $\widetilde{\phi}$ is positive and $\phi$ is positively extendible. \end{proof} \section{approximation results on $[0,1]$} Given a Markov operator between $\mathrm{C}[0,1]$ which keeps subspace $\mathrm{C}[0,1]_{(a,k)}$, we want to approximate it by an average of homomorphisms on $\mathrm{C}[0,1]$ and additionally require that the average also keeps the same subspace. Since the subhomogeneity in consideration arise at 0 and 1, we need to investigate the measures induced by point evaluations of a Markov operator at endpoints 0 and 1. \begin{lem}\label{point mass} Let there be given a unital positive linear map $\phi$ on $C[0,1]$ which preserves $C[0,1]_{(a,k)}$. Then the measures induced by evaluations of $\phi$ at 0 and 1 actually concentrate on 0 and 1 respectively, in other words, $\phi(f)(0)=f(0)$ and $\phi(f)(1)=f(1)$ for all $f\in C[0,1]$. \end{lem} \begin{proof} For any fixed $y\in[0,1]$, $f\rightarrow \phi(f)(y)$ gives a positive Borel probability measure on $[0,1]$, say $\mu_{y}$, then $\phi(f)(y)=\int_{0}^{1}fd\mu_{y}$. Then for all $g\in C[0,1]_{(a,k)}$, $\phi(g)(0)=\int_{0}^{1}gd\mu_{0}$ and $\phi(g)(1)=\int_{0}^{1}gd\mu_{1}$, since $\phi(g)(0)=\frac{a}{a+k}\phi(g)(1)$, one has that $$\int_{0}^{1}gd\mu_{0}=\frac{a}{a+k}\int_{0}^{1}gd\mu_{1}.$$ For any $\delta>0$, choose a finite $\delta$-dense subset $\{x_{1},x_{2},...,x_{n}\}\subset[0,1]$ with $x_{1}=0, x_{n}=1$. Then for every $x\in[0,1]$, there is a $x_{i}$ in the finite subset above such that $dist(x,x_{i})<\delta$. Given a partition of $[0,1]$, denoted by $\{X_{1},X_{2},...,X_{n}\}$, with each $X_{i}$ being a connected Borel set, satisfying the following conditions: $$\begin{aligned} &(1) \,x_{i}\in X_{i}, i=1,2,...,n;\\ &(2)\, [0,1]=\bigcup_{i=1}^n X_{i}, X_{i}\bigcap X_{j}=\emptyset\;\text{for}\;i\neq j;\\ &(3) \,dist(x,x_{i})<\delta \;\text{if} \; x\in X_{i}.\\ \end{aligned}$$ For any fixed $\delta$ above, there exists a $\delta_{0}>0$ such that $[0,\delta_{0}]\subseteq X_{1}$. Choose a function $e_{\delta}\in C[0,1]_{(a,k)}$ as follows: $$e_{\delta_{0}}=\begin{cases} \frac{a}{a+k}+\frac{1-\frac{a}{a+k}}{\delta_{0}}x & x\in[0,\delta_{0}] \\ 1 & x\in(\delta_{0},1].\\ \end{cases} $$ Then \[\phi(e_{\delta_{0}})(0)=\int_{0}^{1}e_{\delta_{0}}d\mu_{0}=\int_{X_{1}}e_{\delta_{0}}d\mu_{0}+\mu_{0}(X_{2})+\mu_{0}(X_{3)}+...+\mu_{0}(X_{n})\] \[=\int_{X_{1}}e_{\delta_{0}}d\mu_{0}+1-\mu_{0}(X_{1)}=1+\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{0},\] \[ \phi(e_{\delta_{0}})(1)=\int_{0}^{1}e_{\delta_{0}}d\mu_{1}=\int_{X_{1}}e_{\delta_{0}}d\mu_{1}+\mu_{1}(X_{2})+\mu_{1}(X_{3)}+...+\mu_{1}(X_{n})\] \[=\int_{X_{1}}e_{\delta_{0}}d\mu_{1}+1-\mu_{1}(X_{1)}=1+\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{1}.\] Since \[ \phi(e_{\delta_{0}})(0)=\frac{a}{a+k}\phi(e_{\delta_{0}})(1),\] one gets that \[1+\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{0}=\frac{a}{a+k}(1+\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{1}).\] Then \begin{equation*}\label{sum} \frac{k}{a+k}+\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{0}=\frac{a}{a+k}\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{1}. \end{equation*} Since $\frac{a}{a+k}\leq e_{\delta_{0}}\leq1$, and $\mu_0$ and $\mu_1$ are positive measures, one has that $-\frac{k}{a+k}\leq\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{0}\leq0$ and $-\frac{k}{a+k}\leq\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{1}\leq0$. Therefore, $$0\leq\frac{k}{a+k}+\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{0}\leq\frac{k}{a+k}.$$ Then the left hand side of equation above is $\geq0$ and the right hand side is $\leq0$. Hence $$\frac{k}{a+k}+\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{0}=\frac{a}{a+k}\int_{X_{1}}(e_{\delta_{0}}-1)d\mu_{1}=0.$$ Then we have $\int_{X_{1}}(1-e_{\delta_{0}})d\mu_{0}=\frac{k}{a+k}$, and $0\leq\int_{X_{1}}(1-e_{\delta_{0}})d\mu_{0}\leq\frac{k}{a+k}\mu_{0}(X_{1})$. Hence $\mu_{0}(X_{1})\geq1$, so $\mu_{0}(X_{1})=1.$ Since $\delta$ is arbitrary, then $\mu_0(\{0\})=1$. In a similar way, for any fixed $\delta$, there exists a $\delta_{1}$ such that $[\delta_{1},1]\subseteq X_{n}$. One can choose a function $\gamma_{\delta_1}\in C[0,1]_{(a,k)}$ as follows: \[\gamma_{\delta_{1}}=\begin{cases} 1 & x\in[0,\delta_{1}) \\ 1+\frac{\frac{a+k}{a}-1}{1-\delta_{1}}(x-\delta_{1}) & x\in(\delta_{1},1].\\ \end{cases} \] Then \[\phi(\gamma_{\delta_{1}})(0)=\int_{0}^{1}\gamma_{\delta_{1}}d\mu_{0}=\int_{X_{n}}\gamma_{\delta_{1}}d\mu_{0}+\mu_{0}(X_{1})+\mu_{0}(X_{2)}+...+\mu_{0}(X_{n-1})\] \[=1-\mu_{0}(X_{n})+\int_{X_{n}}\gamma_{\delta_{1}}d\mu_{0}=1+\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{0},\] \[\phi(\gamma_{\delta_{1}})(1)=\int_{0}^{1}\gamma_{\delta_{1}}d\mu_{1}=\int_{X_{n}}\gamma_{\delta_{1}}d\mu_{1}+\mu_{1}(X_{1})+\mu_{1}(X_{2)}+...+\mu_{1}(X_{n-1})\] \[=1-\mu_{1}(X_{n})+\int_{X_{n}}\gamma_{\delta_{1}}d\mu_{1}=1+\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{1}.\] Since \[ \frac{a+k}{a}\phi(\gamma_{\delta_{1}})(0)=\phi(\gamma_{\delta_{1}})(1),\] one has that \[\frac{a+k}{a}(1+\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{0})=1+\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{1},\] \begin{equation*}\label{sum} \frac{k}{a}+\frac{a+k}{a}\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{0}=\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{1}. \end{equation*} While $0\leq\gamma_{\delta_{1}}-1\leq\frac{k}{a}$, and $0\leq\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{0}\leq\frac{k}{a},\;0\leq\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{1}\leq\frac{k}{a}$. Then the left hand side of the equation above is $\geq\frac{k}{a}$ and the right hand side is $\leq\frac{k}{a}$. Hence $$\frac{k}{a}+\frac{a+k}{a}\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{0}=\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{1}=\frac{k}{a}.$$ Then we have $$\frac{k}{a}\leq\int_{X_{n}}(\gamma_{\delta_{1}}-1)d\mu_{1}\leq\frac{k}{a}\mu_{1}(X_{n}),$$ then $\mu_{1}(X_{n})\geq1$, so $\mu_{1}(X_{n})=1$. Since $\delta$ is arbitrary, then $\mu_1(\{1\})=1$. Hence $\phi(f)(0)=f(0)$ and $\phi(f)(1)=f(1)$ for all $f\in C[0,1]$. \end{proof} \begin{cor}\label{lem:cont1} Let $\phi: C[0,1]_{(a,k)}\rightarrow C[0,1]_{(a,k)}$ be defined as $\phi(f)=f\circ\lambda$ for some continuous $\lambda:[0,1]\rightarrow[0,1]$, then $\lambda(0)=0$ and $\lambda(1)=1$. \end{cor} \begin{proof} Choose some injective function $f$ and apply the lemma above. \end{proof} \textbf{Next we proceed to prove Theorem \ref{thm1}:} \begin{proof} The proof is inspired by Li's proof in \cite{Li}, the thing is we need more accurate analysis for the endpoints. We spell it out in full detail for the convenience of readers. $\mathit{Step I}.$ For all $f\in F$ and $y\in [0,1]$, we approximate $\phi(f)(y)$ by a finite sum of evaluations of $f$ with continuous coefficients. For any $\epsilon>0$, there is a $\delta_{0}$ such that for any $x_{1},x_{2}\in[0,1]$, if $dist(x_{1},x_{2})<\delta_{0}$, then $$|f(x_{1})-f(x_{2})|<\frac{\epsilon}{4}$$ for all $f\in F.$ Choose a finite subset $\{x_{1},x_{2},...,x_{n}\}\subset[0,1]$ which is $\delta_{0}$-dense in $[0,1]$ with $x_{1}=0,x_{n}=1$. Then for every $x\in[0,1]$, there is a $x_{i}$ in the finite subset such that $dist(x,x_{i})<\delta_{0}$. Choose a partition of $[0,1]$, denoted by $\{X_{1},X_{2},...,X_{n}\}$, with each $X_{i}$ being a connected Borel set, satisfying the following conditions: $$\begin{aligned} &(1)\, x_{i}\in X_{i}, i=1,2,...,n;\\ &(2)\, [0,1]=\bigcup_{i=1}^n X_{i},X_{i}\bigcap X_{j}=\emptyset \;\text{for}\; i\neq j;\\ &(3)\, dist(x,x_{i})<\delta_{0} \;\text{if}\; x\in X_{i}.\\ \end{aligned}$$ Then for any probability measure $\mu$ on $[0,1]$, there are non-negative numbers $\lambda_{1},\lambda_{2},...,\lambda_{n}$ with $\sum_{i=1}^{n}\lambda_{i}=1$ such that \[|\mu(f)-\sum_{i=1}^{n}\lambda_{i}f(x_{i})|<\frac{\varepsilon}{4}\;\text{for all}\;f\in F.\] Actually, we have\[|\mu(f)-\sum_{i=1}^{n}\mu(X_{i})f(x_{i})|<|\sum_{i=1}^{n}\int_{X_{i}}(f(x)-f(x_{i}))d\mu|\leq\sum_{i=1}^{n}\frac{\epsilon}{4}\mu(X_{i})=\frac{\epsilon}{4}.\] So one may choose $\lambda_{i}=\mu(X_{i})$. For any fixed $y\in [0,1],\;f\rightarrow\phi(f)(y)$ is a probability measure on [0,1], thus from above, there are non-negative numbers $\lambda_{1y},\lambda_{2y},...,\lambda_{ny}$ with $\sum_{i=1}^{n}\lambda_{iy}=1$ such that \[|\phi(f)(y)-\sum_{i=1}^{n}\lambda_{iy}f(x_{i})|<\frac{\epsilon}{4}\;\text{for all}\;f\in F.\] By continuity of $\phi(f)$, this estimation holds in a neighborhood of y. Since $[0,1]$ is compact, we can find an open cover $\{V_{j}: j=1,2,...,R\}$ of $[0,1]$, such that $$\begin{aligned} &(1) 0\in V_{1}, 0\notin \bigcup^{R}_{j=2}V_{j},1\in V_{R},1\notin\bigcup^{R-1}_{j=1} V_{j},\\ &(2) y_{j}\in V_{j}, y_{1}=0,y_{R}=1, j=2,...,R-1.\\ \end{aligned}$$ Then one has that \[|\phi(f)(y)-\sum_{i=1}^{n}\lambda_{iy_{j}}f(x_{i})|<\frac{\epsilon}{4}\;\text{for all}\;y\in V_{j}\;and\;f\in F.\] Let $\{h_{j}\}_{1}^{R}$ be a partition of unity subordinate to $\{V_{j}\}_{1}^{R}$. Define $\lambda_{i}(y)=\sum_{j=1}^{R}\lambda_{iy_{j}}h_{j}(y)$, then $\lambda_{i}\in C[0,1], \lambda_{i}(0)=\lambda_{i0}=\mu_{0}(X_{i}), \lambda_{i}(1)=\lambda_{i1}=\mu_{1}(X_{i})$ and \[\sum_{i=1}^{n}\lambda_{i}(y)=\sum_{i=1}^{n}(\sum_{j=1}^{R}\lambda_{iy_{j}}h_{j}(y))=\sum_{j=1}^{R}h_{j}(y)=1.\] Hence \[|\phi(f)(y)-\sum_{i=1}^{n}\lambda_{i}(y)f(x_{i})|<\frac{\epsilon}{4}\] for all $y\in [0,1]$ and $f\in F$. $\mathit{Step II}.$ We approximate the finite sum of evaluations above by a linear map $w$ on $C[0,1]$ defined as an integral of the composition with some continuous function $h(y,t)$ from $[0,1]\times[0,1]$ to $[0,1]$. Let there be given a $\delta>0$ to be used later with $4n\delta\sup_{f\in F}\|f\|<\frac{\epsilon}{4}$. First, we define continuous maps $G_{0},G_{1},...G_{n}:[0,1]\rightarrow[0,1]$ by \[ G_{0}(y)=0,G_{j}(y)=\sum_{i=1}^j\lambda_{i}(y),\;j=1,2,...,n.\] For each $y\in [0,1]$, these points $\{G_i(y)\}_i$ give to a partition of $[0,1]$. Moreover, for each $j$, we define \[f_{j}(y)=\min\{G_{j-1}(y)+\delta;\frac{G_{j-1}(y)+G_{j}(y)}{2}\},\] and \[g_{j}(y)=\max\{G_{j}(y)-\delta;\frac{G_{j-1}(y)+G_{j}(y)}{2}\}.\] To define $h(y,t)$, we only need to define $h(y,t)$ on each $[0,1]\times[G_{j-1}(y),G_{j}(y)]$, let us denote by $h_{j}(y,t)$ this restriction. For our purpose, we choose the following $h_j(y,t)$: \[h_{j}(y,t)=\begin{cases} \frac{x_{j}(t-G_{j-1}(y))}{\delta} & t\in [G_{j-1}(y),f_{j}(y)] \\ \min(x_{j},\frac{x_{j}(G_{j}(y)-G_{j-1}(y))}{2\delta}) & t\in [f_{j}(y),g_{j}(y)] \\ \frac{x_{j}(G_{j}(y)-t)}{\delta} & t\in [g_{j}(y),G_{j}(y)]. \\ \end{cases} \] Then $h_{j}(y,t)$ satisfies that for any $y\in [0,1],$ \[|h_{j}(y,t_{1})-h_{j}(y,t_{2})|\leq\frac{x_{j}|t_{1}-t_{2}|}{\delta},\] and $h_{j}(y,t):[0,1]\times[G_{j-1}(y),G_{j}(y)]\rightarrow[0,1]$ is continuous. Hence $h(y,t):[0,1]\times[0,1]\rightarrow[0,1]$ is continuous and \[|h(y,t_{1})-h(y,t_{2})|\leq\frac{|t_{1}-t_{2}|}{\delta}.\] Define $w:C[0,1]\rightarrow C[0,1]$ by $w(f)(y)=\int_{0}^{1}f(h(y,t))dt$ for $f\in C[0,1], y\in[0,1]$. Then for all $f\in F$, one has that \[ \begin{aligned} &|\sum_{i=1}^n\lambda_{i}(y)f(x_{i})-w(f)(y)|\\ =& |\sum_{i=1}^n\int_{G_{i-1}(y)}^{G_{i}(y)}f(x_{i})dt-\int_{0}^{1}f(h(y,t))dt|\\ \leq&\sum_{i=1}^n|\int_{G_{i-1}(y)}^{G_{i}(y)}f(x_{i})-f(h(y,t))dt|\\ =&\sum_{i=1}^n|(\int_{G_{i-1}(y)}^{f_{i}(y)}+\int_{f_{i}(y)}^{g_{i}(y)}+\int_{g_{i}(y)}^{G_{i}(y)})(f(x_{i})-f(h(y,t)))dt|\\ \leq&\sum_{i=1}^n(2\delta\sup_{f\in F}\|f\|+0+2\delta\sup_{f\in F}\|f\|)\\ =&4n\delta\sup_{f\in F}\|f\|<\frac{\epsilon}{4}. \end{aligned} \] $\mathit{Step III}.$ Finally we shall choose $N$ continuous maps on $[0,1]$ to define the homomorphisms. Such maps come from $h(y,t)$ by specifying $N$ values of $t$. Moreover, we choose these maps in a way that the corresponding homomorphisms preserve the subspace $C[0,1]_{(a,k)}$. Choose an integer $N_{1}>0$ with $\frac{1}{N_{1}}<\delta\delta_{0}$, and choose specified values of $t$ as $t_{j}=\frac{j}{N_{1}}\in[0,1], j=1,2,...,N_{1}$. Then the linear map $w$ can be approximated by the average of the homomorphisms induced by $h(y,t_j), j=1,...,N_1$. This is shown as follows: set $$w(f)(y)=\sum_{j=1}^{N_{1}}\int_{t_{j-1}}^{t_{j}}f(h(y,t))dt,$$ then \[ \begin{aligned} &|w(f)(y)-\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))|\\ =&| \sum_{j=1}^{N_{1}}\int_{t_{j-1}}^{t_{j}}f(h(y,t))-f(h(y,t_{j}))dt|\\ <& \sum_{j=1}^{N_{1}}\int_{t_{j-1}}^{t_{j}}\frac{\epsilon}{4}=\frac{\epsilon}{4}. \end{aligned} \] for all $f\in F$, where $|f(h(y,t))-f(h(y,t_{j}))|<\frac{\epsilon}{4}$, since $|h(y,t)-h(y,t_{j})|<\delta_{0}$ (Note that $|t-t_{j}|\leq\frac{1}{N_{1}}<\delta\delta_{0}$). However, the average of these homomorphisms may not preserve the subspace. To fix this problem, we have to make more delicate choices. By Lemma \ref{point mass}, we know that for $\phi(f)(0)$, the coefficients are: $$\lambda_1(0)=1, \lambda_2(0)=...=\lambda_n(0)=0.$$ Similarly, for $\phi(f)(1)$, one has that $$\lambda_1(1)= \lambda_2(1)=...=\lambda_{n-1}(1)=0, \lambda_n(1)=1.$$ Therefore, one sets that $h(0,t)=0$; and $$h(1,t)=\begin{cases} \frac{t}{\delta} & t\in [0,\delta] \\ 1 & t\in [\delta,1-\delta] \\ \frac{1-t}{\delta} & t\in[1-\delta,1] .\\ \end{cases}$$ If we can choose new $t_j$ such that $h(0,t_j)=0$ and $h(1,t_j)=1$, then the corresponding homomorphisms will fit our purpose. Choose those $j$ such that $\delta\leq\frac{j}{N_1}\leq1-\delta$, i.e., $\delta N_1\leq j\leq (1-\delta)N_1$. Denote by $N$ the number of such $j$, then $N=\lfloor(1-\delta)N_1\rfloor-\lceil\delta N_1\rceil+1$. We are going to show that the average of these $N$ homomorphisms can approximate the average of the original $N_1$ homomorphisms: $$\begin{aligned} &|\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{N}\sum_{j=\lceil\delta N_1\rceil}^{\lfloor(1-\delta)N_1\rfloor}f(h(y,t_{j}))|\\ =&\frac{1}{N_{1}}|\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{N_1}{N}\sum_{j=\lceil\delta N_1\rceil}^{\lfloor(1-\delta)N_1\rfloor}f(h(y,t_j))|\\ =&\frac{1}{N_{1}}|\sum_{j=1}^{\lceil N_{1}\delta\rceil-1}f(h(y,t_{j}))+\sum_{\lfloor N_{1}(1-\delta)\rfloor+1}^{N_{1}}f(h(y,t_{j}))+(1-\frac{N_1}{N})\sum_{j=\lceil N_{1}\delta\rceil}^{\lfloor N_{1}(1-\delta)\rfloor}f(h(y,t_{j}))|\\ \leq&\frac{1}{N_{1}}(N_{1}\delta \sup_{f\in F}\|f\|+(N_{1}\delta+1) \sup_{f\in F}\|f\|+(2N_{1}\delta+1) \sup_{f\in F}\|f\|)\\ \leq&5\delta \sup_{f\in F}\|f\|\leq\frac{\epsilon}{4}.\\ \end{aligned}$$ (Note that the above estimation holds since $$\begin{aligned} &N_1-N=N_1-(\lfloor(1-\delta)N_1\rfloor-\lceil\delta N_1\rceil+1)\\ =&N_1-1-(\lfloor(1-\delta)N_1\rfloor-\lceil\delta N_1\rceil)\\ \leq &N_1-1-[(1-\delta)N_1-1-(\delta N_1+1)]\\ =&2\delta N_1+1.)\\ \end{aligned}$$ For those new $j$, let us define $\phi_{j}:C[0,1]\rightarrow C[0,1]$ by $\phi_{j}(f(y))=f(h(y,t_{j}))$. Then $$\begin{aligned} &|\phi(f)(y)-\frac{1}{N}\sum_{j=\lceil\delta N_1\rceil}^{\lfloor(1-\delta)N_1\rfloor}\phi_{j}(f)(y)|\\ =&|\phi(f)(y)-\frac{1}{N}\sum_{j=\lceil\delta N_1\rceil}^{\lfloor(1-\delta)N_1\rfloor}f(h(y,t_{j}))|\\ \leq&|\phi(f)(y)-\sum_{i=1}^{n}\lambda_{i}(y)f(x_{i})|+|\sum_{i=1}^n\lambda_{i}(y)f(x_{i})-w(f)(y)|\\ +&|w(f)(y)-\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))|+|\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{N}\sum_{j=\lceil\delta N_1\rceil}^{\lfloor(1-\delta)N_1\rfloor}f(h(y,t_{j}))|\\ \leq&\frac{\epsilon}{4}+\frac{\epsilon}{4}+\frac{\epsilon}{4}+\frac{\epsilon}{4}\leq\epsilon.\\ \end{aligned}$$ \end{proof} \begin{remark} From the proof above, one can see that for any integer $M_1\geq N_1$, there are an corresponding integer $M$ and $M$ homomorphisms such that the average of these $M$ morphisms also meets the requirements. Hence, under the assumption of Theorem \ref{thm1}, there is a sequence of positive integers $\{L_j\}_{j=1}^{\infty}$ with large enough lower bound, and there are corresponding $L_j$ morphisms for each $j$, such that the average of these $L_j$ morphisms meets the requirements. \end{remark} Consider the C*-algebras $$A=\{f\in C([0,1], M_n)\mid f(0)=\text{diag}(d\otimes id_{a}, 0\otimes id_{k}) , f(1)=d\otimes id_{a+k}\}$$ and $$B=\{f\in C([0,1], M_m)\mid f(0)=\text{diag}(e\otimes id_{a}, 0\otimes id_{k}) , f(1)=e\otimes id_{a+k}\},$$ where $d$ and $e$ are matrices of appropriate sizes. Theorem \ref{thm1} can be used to build up $*$-homomorphisms between certain C*-algebras. \begin{cor} Consider the C*-algebras $A$ as above, for any $\epsilon>0$, and any finite subset $F\subseteq AffTA=C[0,1]_{(a,k)}$, there is an integer $N>0$, such that for any C*-algebra $B$ of the form above with generic fibre size being $N$ multiples of generic fibre size of $A$, and a unital positive linear map $\xi$ on $C[0,1]$ which preserves $C[0,1]_{(a,k)}$, then there is a $*$-homomorphism $\phi$ from $A$ to $B$, such that $$\|\xi(f)-AffT\phi(f)\|<\epsilon$$ for all $f\in F$. \end{cor} \begin{proof} We take $N$ as in Theorem \ref{thm1}, and the corresponding $N$ continuous maps $h(y, t_1),..., h(y, t_N)$ on $[0,1]$. By the constructions of $h(y, t_j)$, there are unitary matrices $U_0$ and $U_1$, such that for each $g\in A$, $$U_0\text{diag}(g(h(0, t_1)),...,g(h(0, t_N)))U_0^*=\text{diag}(e\otimes id_{a}, 0\otimes id_{k}),$$ and $$U_1\text{diag}(g(h(1, t_1)),...,g(h(1, t_N)))U_1^*=e\otimes id_{a+k},$$ for some matrix $e$. By choosing a continuous path of unitaries $U(t)$ connecting $U_0$ and $U_1$, one can define $\phi: A\rightarrow B$ as $$\phi(g)(y)=U(y)\text{diag}(g\circ h(y, t_1),...,g\circ h(y, t_N))U^*(y).$$ Keeping mind the correspondence $f=(tr\otimes \delta_t)(g)$(see Proposition 2.1 in \cite{Rak}), and applying Theorem \ref{thm1}, one has that $$\|\xi(f)-AffT\phi(f)\|<\epsilon$$ for all $f\in F$. \end{proof} Now we consider the case involving different subspaces. \begin{lem}\label{small} Let $\mu$ be any Borel probability measure on [0,1], then for any $x\in[0,1]$ and $\epsilon>0$, there is a $\delta>0$, such that $\mu(B^{0}(x,\delta))<\epsilon$ (where $B^{0}(x,\delta)$ denotes the neighborhood of $x$ excluding the center). \end{lem} \begin{proof}Let $D_{k}=(B(x,\frac{1}{k})\setminus B(x,\frac{1}{1+k}))\cap[0,1]$ and $S_{n}=\sum_{k=1}^{n}\mu(D_{k})$. Then $S_{n}$ is increasing and upper bounded, so $\{S_{n}\}$ converges. Then for any $\epsilon>0$, there exists $N>0$ such that $\sum_{k=N}^{\infty}\mu(D_{k})<\epsilon$. Hence there exists $\delta=\frac{1}{N}$, such that $\mu(B^{0}(x,\delta))<\epsilon$, since $B^{0}(x,\delta)=\bigcup\limits_{k=N}^{\infty}D_k$. The proof is complete. \end{proof} Examples in Section 2 show that the measures induced by evaluations of a Markov operator at 0 and 1 actually could involve as many points as you want, so we investigate the behavior of induced measures with respect to a given partition of $[0,1]$ coming from an approximation. \begin{lem}\label{mea2} Given any unital positive linear map $\phi$ from $C[0,1]$ to $C[0,1]$ which sends $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)}$, denote by $\mu_0$ and $\mu_1$ the measures induced by evaluations of $\phi$ at 0 and 1. Let there be given a partition $\{X_{1},X_{2},...,X_{n}\}$ of $[0,1]$, where $X_{i}$ is a connected Borel set and $0\in X_{1}$, $1\in X_{n}$. Then we have the following distribution of $\mu_0$ and $\mu_1$ with respect to the partition: \begin{align} &\mu_{0}(X_{i})=\frac{b}{b+k}\mu_{1}(X_{i}), i=2,...,n-1, \\ &\frac{a}{a+k}\mu_{0}(X_{1})+\mu_{0}(X_{n})=\frac{b}{b+k}[\frac{a}{a+k}\mu_{1}(X_{1})+\mu_{1}(X_{n})]. \end{align} \end{lem} \begin{proof} First we prove the first relation. This is shown as follows. Choose a continuous function which is almost supported on $X_i$, then apply $\phi$, and compare the evaluations at 0 and 1, one can get the relation. For $i=2,...,n-1$, let us assume $a_{i}=\sup\{x: x\in X_{i}\}$, $b_{i}=\inf\{x: x\in X_{i}\}$. We deal with the problem in several cases, and we only spell it out in one case, similar proof works for other cases. If $a_{i},b_{i}\in X_{i}$, that is $X_{i}=[b_{i}, a_{i}]$. For $\forall \epsilon>0$, by Lemma \ref{small}, there exists a $\delta>0$ such that $\mu_{0}((b_{i}-\delta,b_{i}))<\epsilon, \mu_{1}((b_{i}-\delta,b_{i}))<\epsilon, \mu_{0}((a_{i},a_{i}+\delta))<\epsilon, \mu_{1}((a_{i},a_{i}+\delta))<\epsilon$. Choose a function $g_{i}(x)$ as follows: \[ g_{i}(x)=\begin{cases} 0 & x\in(b_{i}-\delta,a_{i}+\delta)^{c} \\ \frac{x-b_{i}}{\delta}+1 & x\in(b_{i}-\delta,b_{i}) \\ -\frac{x-a_{i}}{\delta}+1 & x\in(a_{i},a_{i}+\delta) \\ 1 & x\in[b_{i},a_{i}],\\ \end{cases} \] then \[\phi(g_{i})(0)=\int_{[0,1]}g_{i}d\mu_{0}=\mu_{0}(X_{i})+\int_{(b_{i}-\delta,b_{i})}g_{i}d\mu_{0}+\int_{(a_{i},a_{i}+\delta)}g_{i}d\mu_{0},\] and \[\phi(g_{i})(1)=\int_{[0,1]}g_{i}d\mu_{1}=\mu_{1}(X_{i})+\int_{(b_{i}-\delta,b_{i})}g_{i}d\mu_{1}+\int_{(a_{i},a_{i}+\delta)}g_{i}d\mu_{1}.\] Let us take $$\epsilon_{i0}=\int_{(b_{i}-\delta,b_{i})}g_{i}d\mu_{0}+\int_{(a_{i},a_{i}+\delta)}g_{i}d\mu_{0},$$ and $$ \epsilon_{i1}=\int_{(b_{i}-\delta,b_{i})}g_{i}d\mu_{1}+\int_{(a_{i},a_{i}+\delta)}g_{i}d\mu_{1},$$ then $\epsilon_{i0}<2\epsilon, \epsilon_{i1}<2\epsilon$ and \[\frac{\mu_{0}(X_{i})+\epsilon_{i0}}{\mu_{1}(X_{i})+\epsilon_{i1}}=\frac{b}{b+k} \] (since $\phi(g_{i})\in C[0,1]_{(b,k)}$). Hence $$|\mu_{0}(X_{i})-\frac{b}{b+k}\mu_{1}(X_{i})|<4\epsilon,$$ since $\epsilon$ is arbitrary, one gets that $$\mu_{0}(X_{i})=\dfrac{b}{b+k}\mu_{1}(X_{i}), i=2,...,n-1.$$ Next we prove the second relation. We use similar ideas, i.e., we choose a function which is almost supported around 0 and 1, apply $\phi$, and then compare the evaluations. For $i=1$ and $i=n$, we know that $0=inf\{x:x\in X_{1}\}$, $1=sup\{x: x\in X_{n}\}$, and suppose $a_{1}=\sup\{x: x\in X_{1}\}$, $b_{n}=\inf\{x: x\in X_{n}\}$. Suppose $a_{1}\in X_{1},b_{n}\in X_{n}$, that is $X_{1}=[0,a_{1}]$, $X_{n}=[b_{n},1]$. For $\forall\epsilon>0$, by Lemma \ref{small}, there exists a $\delta>0$ such that $$\begin{aligned} &\mu_{0}((b_{n}-\delta,b_{n}))<\epsilon,\mu_{1}((b_{n}-\delta,b_{n}))<\epsilon,\\ &\mu_{0}((a_{1},a_{1}+\delta))<\epsilon,\mu_{1}((a_{1},a_{1}+\delta))<\epsilon.\\ \end{aligned}$$ We choose a function $g(x)$ as follows: \[ g(x)=\begin{cases} \frac{a}{k+a} & x\in[0,a_{1}] \\ -\frac{a(x-a_{1})}{\delta(a+k)}+\frac{a}{a+k} & x\in(a_{1},a_{1}+\delta) \\ 0 & x\in([a_{1}+\delta,b_{n}-\delta] \\ \frac{x-b_{n}}{\delta}+1 & x\in(b_{n}-\delta,b_{n}) \\ 1 & x\in[b_{n},1] \\ \end{cases} \] Then \[\phi(g)(0)=\int_{[0,1]}gd\mu_{0}=\mu_{0}(X_{n})+\frac{a}{a+k}\mu_{0}(X_{1})+\int_{(a_{1},a_{1}+\delta)}gd\mu_{0}+\int_{(b_{n}-\delta,b_{n})}gd\mu_{0},\] and \[\phi(g)(1)=\int_{[0,1]}gd\mu_{1}=\mu_{1}(X_{n})+\frac{a}{a+k}\mu_{1}(X_{1})+\int_{(a_{1},a_{1}+\delta)}gd\mu_{1}+\int_{(b_{n}-\delta,b_{n})}gd\mu_{1}.\] Let us take $$\epsilon_{0}=\int_{(a_{1},a_{1}+\delta)}gd\mu_{0}+\int_{(b_{n}-\delta,b_{n})}gd\mu_{0},$$ and $$\epsilon_{1}=\int_{(a_{1},a_{1}+\delta)}gd\mu_{1}+\int_{(b_{n}-\delta,b_{n})}gd\mu_{1},$$ then $$\epsilon_{0}<\frac{2a+k}{a+k}\epsilon, \epsilon_{1}<\frac{2a+k}{a+k}\epsilon.$$ Moreover, one has that \[\frac{\mu_{0}(X_{n})+\dfrac{a}{a+k}\mu_{0}(X_{1})+\epsilon_{0}}{\mu_{1}(X_{n})+\dfrac{a}{a+k}\mu_{1}(X_{1})+\epsilon_{1}}=\frac{b}{b+k} \] (since $\phi(g)\in C[0,1]_{(b,k)}$). Then $$|\frac{a}{a+k}\mu_{0}(X_{1})+\mu_{0}(X_{n})-\frac{b}{b+k}(\frac{a}{a+k}\mu_{1}(X_{1})+\mu_{1}(X_{n}))|<r\epsilon$$ for some $r$, which implies that $$\frac{a}{a+k}\mu_{0}(X_{1})+\mu_{0}(X_{n})=\frac{b}{b+k}(\frac{a}{a+k}\mu_{1}(X_{1})+\mu_{1}(X_{n}))$$ since $\epsilon$ is arbitrary. Similar proofs go through for other cases. \end{proof} \begin{cor}\label{lem:mea} Given any unital positive linear map $\phi$ from $C[0,1]$ to $C[0,1]$ which sends $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)}$, denote by $\mu_0$ and $\mu_1$ the measures induced by evaluations of $\phi$ at 0 and 1. Let there be given a partition $\{X_{1},X_{2},...,X_{n}\}$ of $[0,1]$, where $X_{i}$ is a connected Borel set and $0\in X_{1}$, $1\in X_{n}$, then we have the following distribution of $\mu_0$ and $\mu_1$ with respect to the partition: \begin{align} &\mu_{0}(X_{1})=\frac{b}{b+k}\mu_{1}(X_{1})+\frac{a+k}{b+k},\\ &\mu_{0}(X_{n})=\frac{b}{b+k}\mu_{1}(X_{n})-\frac{a}{b+k}. \end{align} \end{cor} \begin{proof} By adding (3.1) from $i=2,...n-1$ and (3.2), we have $$\begin{aligned} &\sum_{i=2}^{n-1}\mu_{0}(X_{i})+\frac{a}{a+k}\mu_{0}(X_{1})+\mu_{0}(X_{n})\\ =&\sum_{i=2}^{n-1}\frac{b}{b+k}\mu_{1}(X_{i})+\frac{b}{b+k}[\frac{a}{a+k}\mu_{1}(X_{1})+\mu_{1}(X_{n})] \end{aligned}$$ Then we add $\mu_{0}(X_{1})+\dfrac{b}{b+k}\mu_{1}(X_{1})$ from both sides of the equation above, since $\mu_{0}([0,1])=1$, $\mu_{1}([0,1])=1$, we get $$1+\frac{a}{a+k}\mu_{0}(X_{1})+\frac{b}{b+k}\mu_{1}(X_{1})=\frac{b}{b+k}+\mu_{0}(X_{1})+\frac{b}{b+k}\frac{a}{a+k}\mu_{1}(X_{1}).$$ Then one can solve $\mu_0(X_1)$ from above to get the equation (3.3). By (3.2) and (3.3), we could get the equation (3.4). \end{proof} \begin{remark}\label{b<a} By (3.3), we have $$\mu_{0}(X_{1})=\frac{b}{b+k}\mu_{1}(X_{1})+\frac{a+k}{b+k}\geq\frac{a+k}{b+k},$$ then $1\geq\mu_{0}(X_{1})\geq\dfrac{a+k}{b+k}$, thus we get $b\geq a$. In other words, there is no unital positive linear maps on $C[0,1]$ which sends $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)}$ if $b<a$.\\ \end{remark} \begin{lem}\label{app} For any $\eta>0$, and for all the given $\mu_{0}(X_i)$, $\mu_{1}(X_i)(i=1,...,n)$ as above in Lemma \ref{mea2}, there exist rational numbers $0\leq r_1,...,r_n\leq1$ and $0\leq s_1,...,s_n\leq1$ which add up to 1 respectively, such that $$0\leq r_i-\mu_{0}(X_i)\leq\eta,\, 0\leq s_i-\mu_{1}(X_i)\leq\eta,\, i=1, 2,...,n;$$ moreover, the relations among $\mu_{0}(X_i)$ and $\mu_{1}(X_i)$ hold for these $r_i$ and $s_i$, i.e., \begin{align} &r_i=\frac{b}{b+k}s_i, i=2,...,n-1, \\ &\frac{a}{a+k}r_1+r_n=\frac{b}{b+k}(\frac{a}{a+k}s_1+s_n). \end{align} \end{lem} \begin{proof} We take rational approximations $s_i$ for $\mu_1(X_i)$ with $0\leq s_i-\mu_{1}(X_i)\leq\frac{\eta}{n}$, and then take $r_i=\dfrac{b}{b+k}s_i$, then they fit the desired relation because of the relation between $\mu_{0}(X_i)$ and $\mu_1(X_i) (2\leq i\leq n-1)$. Fix a rational approximation $s_n$ for $\mu_1(X_n)$ with $0\leq s_n-\mu_{1}(X_n)\leq\frac{\eta}{n}$, then $$ \begin{aligned} &1-(s_2+...+s_{n-1}-s_n)-\mu_1(X_1)\\ =&1-(s_2+...+s_{n-1}-s_n)-(1-(\mu_1(X_2)+...+\mu_1(X_{n-1}))-\mu_1(X_n))\\ =& (s_2-\mu_1(X_2))+...+(s_{n-1}-\mu_1(X_{n-1}))+(s_n-\mu_1(X_n))\leq\eta. \end{aligned} $$ We take $$s_1=1-(s_2+...+s_{n-1})-s_n, r_n=\frac{b}{b+k}s_n-\frac{a}{b+k},$$ and $$r_1=1-(r_2+...+r_{n-1})-r_n,$$ then all of the data fit in the requirements. \end{proof} \begin{cor}\label{boundary} For any positive integer $N$, for any collection of $N$ points $\{x_i \in (0,1)|1\leq i\leq N\}$, and for integers $k_1, k_n$ and $m_1, m_n$ satisfying the relation (3.6), Then we have that $$k_1f(0)+\sum\limits_{i=1}^{N}bl_if(x_i)+k_nf(1)=\frac{b}{b+k}(m_1f(0)+\sum\limits_{i=1}^{N}(b+k)l_if(x_i)+m_nf(1))$$ for all $f\in C[0,1]_{(a,k)}$, where these $l_i$ are arbitrarily chosen positive integers. \end{cor} \begin{proof} Since $f\in C[0,1]_{(a,k)}$, one has that $f(0)=\dfrac{a}{a+k}f(1)$. Then the left hand side of above equals to $(\dfrac{a}{a+k}k_1+k_n)f(1)+\sum\limits_{i=1}^{N}bl_if(x_i)$. Hence it coincides with the right hand side by the relation (3.6). \end{proof} \textbf{Now we proceed to prove Theorem \ref{thm2}:} \begin{proof} $\mathit{Step I}$, The first step is exactly the same as the first step of Theorem \ref{thm1}. To avoid redundancy, we skip it and still use the same notations there. $\mathit{Step II}$, In a similar way, we approximate the finite sum of evaluations by a linear map $w$ on $C[0,1]$ defined as an integral of the composition with some continuous function $h(y,t)$ from $[0,1]\times[0,1]$ to $[0,1]$. Let us define $$\begin{aligned} & l_{1}(y)=\lambda_{2}(y)\\ &l_{2}(y)=\max\{0,\min\{\lambda_{1}(y)-\lambda_{1}(1),\lambda_{2}(1)-\lambda_{2}(y)\}\}\\ &\cdots\\ &l_{2n-3}(y)=\lambda_{n}(y)\\ &l_{2n-2}(y)=\max\{0,\min\{\lambda_{1}(y)-\lambda_{1}(1)-l_{2}(y)-...-l_{2n-4}(y),\lambda_{n}(1)-\lambda_{n}(y)\}\}\\ &l_{2n-1}(y)=1-\sum_{j=1}^{2n-2}l_{j}(y)\\ &l_{2n}(y)=0.\\ \end{aligned}$$ By (3.1-3.4), we have $$\lambda_{i}(0)=\mu_{0}(X_{i})\leq \mu_{1}(X_{i})= \lambda_{i}(1)(i=2,...n),$$ and $$\lambda_{1}(0)=\mu_{0}(X_{1})\geq\mu_{1}(X_{1})= \lambda_{1}(1).$$ Thus$$ \begin{aligned} &l_{1}(0)=\mu_{0}(X_{2}),\qquad \qquad\qquad \;\;\;\; \; \; \; \; \; \; \;\qquad l_{1}(1)=\mu_{1}(X_{2}),\\ &l_{2}(0)=\mu_{1}(X_{2})-\mu_{0}(X_{2}),\qquad\qquad \;\;\;\; \;\;\;\;\;\;l_{2}(1)=0,\\ &\cdots\\ &l_{2n-3}(0)=\mu_{0}(X_{n}),\qquad\qquad \;\;\qquad\qquad \;\;\;l_{2n-3}(1)=\mu_{1}(X_{n}),\\ &l_{2n-2}(0)=\mu_{1}(X_{n})-\mu_{0}(X_{n}),\qquad\qquad \;\;\;l_{2n-2}(1)=0,\\ &l_{2n-1}(0)=\mu_{1}(X_{1}),\qquad\qquad \qquad\qquad \;\;\;\;\;l_{2n-1}(1)=\mu_{1}(X_{1}),\\ &l_{2n}(0)=0.\qquad\qquad\qquad\qquad \;\;\;\qquad\qquad \;l_{2n}(1)=0.\\ \end{aligned}$$ Next define $G_{0},G_{1},...G_{2n}:[0,1]\rightarrow[0,1]$ by \[ G_{0}(y)=0,G_{j}(y)=\sum_{i=1}^{j}\ l_{i}(y),\;j=1,2,...,2n.\] Then for $j=2k$ we have the consistency that $$G_{j}(0)=G_{j}(1)=\sum_{i=1}^{k}\ \mu_{1}(X_{i}).$$ Let $\delta>0$ be a rational number, for each $y\in [0,1]$, these points $\{G_i(y)\}_i$ give to a partition of $[0,1]$. Moreover, for each $j$, we define $$f_{j}(y)=\min\{G_{j-1}(y)+\delta;\frac{G_{j-1}(y)+G_{j}(y)}{2}\},$$ and $$g_{j}(y)=\max\{G_{j}(y)-\delta;\frac{G_{j-1}(y)+G_{j}(y)}{2}\}.$$ To define $h(y,t)$, we only need to define $h(y,t)$ on each $[0,1]\times[G_{j-1},G_{j}(y)]$. Let us denote by $h_{j}(y,t)$ this restriction. For our purpose, we choose the following $h_j(y,t)$: \[h_{j}(y,t)=\begin{cases} \frac{x_{j}(t-G_{j-1}(y))}{\delta} & t\in [G_{j-1}(y),f_{j}(y)] \\ \min(x_{j},\frac{x_{j}(G_{j}(y)-G_{j-1}(y))}{2\delta}) & t\in [f_{j}(y),g_{j}(y)] \\ \frac{x_{j}(G_{j}(y)-t)}{\delta} & t\in [g_{j}(y),G_{j}(y)]. \\ \end{cases} \] where $x_{j}=x_{i}$ if $j=2i-1$, $x_{j}=0$ if $j=2i$. Then $h_{j}(y,t)$ satisfies that for any $y\in [0,1]$, $$|h_{j}(y,t_{1})-h_{j}(y,t_{2})|\leq\frac{|t_{1}-t_{2}|}{\delta},$$ and $h_{j}(y,t):[0,1]\times[G_{j-1},G_{j}(y)]\rightarrow[0,1]$ is continuous. Hence $h(y,t):[0,1]\times[0,1]\rightarrow[0,1]$ is continuous and $$|h(y,t_{1})-h(y,t_{2})|\leq\frac{|t_{1}-t_{2}|}{\delta}.$$ Define $w:C[0,1]\rightarrow C[0,1]$ by $$w(f)(y)=\int_{0}^{1}f(h(y,t))dt$$ where $f\in C[0,1], y\in[0,1]$. Then for all $f\in F$, one has that $$\begin{aligned} &|\sum_{i=1}^n\lambda_{i}(y)f(x_{i})-w(f)(y)|\\ =& |\sum_{j=1}^{2n}l_{j}(y)f(x_{j})-w(f)(y)|\\ =&|\sum_{j=1}^{2n}\int_{G_{j-1}(y)}^{G_{j}(y)}f(x_{j})dt-\int_{0}^{1}f(h(y,t))dt|\\ \leq&\sum_{j=1}^{2n}|\int_{G_{j-1}(y)}^{G_{j}(y)}f(x_{i})-f(h(y,t))dt|\\ =& \sum_{j=1}^{2n}|(\int_{G_{j-1}(y)}^{f_{j}(y)}+\int_{f_{j}(y)}^{g_{j}(y)}+\int_{g_{j}(y)}^{G_{j}(y)}f(x_{j}-f(h(y,t))dt|\\ \leq& \sum_{j=1}^{2n}(2\delta\sup_{f\in F}\|f\|+0+2\delta\sup_{f\in F}\|f\|)\\ =& 8n\delta\sup_{f\in F}\|f\|<\frac{\epsilon}{4}. \end{aligned}$$ The last inequality holds because of the choice of $\delta$ later. $\mathit{Step III}$, We shall choose $N_{1}$ continuous maps on $[0,1]$ to define the homomorphisms. Such maps come from $h(y,t)$ by specifying $N_{1}$ values of $t$. let $\tau$ be the number of $X_i$ such that $\mu_{0}(X_{i})\neq0$ for $i=2,...,n-1.$ Then $\mu_{1}(X_{i})\neq0$ for the same index by (3.1). We denote these $X_{i}$ by $X_{i_{1}},,...,X_{i_{\tau}}$. Then for $X_{1},X_{i_{1}},...,X_{i_{\tau}},X_{n}$, by Lemma \ref{app}, for $\frac{\delta}{n}$, there exist rational numbers $0\leq r_1,r_{i_{1}}...,r_{i_{\tau}},r_n\leq1$ and $0\leq s_1,s_{i_{1}},...,s_{i_{\tau}},s_n\leq1$ such that $$\begin{aligned} &r_1+\sum_{i=1}^{\tau}r_{i_{\iota}}+r_n=1;\, 0\leq r_i-\mu_{0}(X_i)\leq\frac{\delta}{n},i=1,i_{1},...,i_{\tau},n\\ &s_1+\sum_{i=1}^{\tau}s_{i_{\iota}}+s_n=1;\, 0\leq s_i-\mu_{1}(X_i)\leq\frac{\delta}{n},i=1,i_{1},...,i_{\tau},n\\ &\frac{ r_{i_{\iota}}}{ s_{i_{\iota}}}=\frac{b}{b+k}, \iota=1,...\tau\\ &\frac{a}{a+k}r_1+r_n=\frac{b}{b+k}(\frac{a}{a+k}s_1+s_n).\\ \end{aligned}$$ Choose an integer $N_{1}>0$, such that $\frac{1}{N_{1}}<\delta\delta_{0}$ and $N_{1}\delta$, $N_{1}s_{i}$, $N_{1}r_{i}(i=1,i_{1},...i_{\tau},n)$ are integers, let $t_{j}=\frac{j}{N_{1}}\in[0,1]$, $j=1,2,...,N_{1}$. To save notations, rewrite $N_{1}s_{i}$, $N_{1}r_{i}$ by $s_{i}$, $r_{i}(i=1,i_{1},...i_{\tau},n)$, then \[\sum_{\iota=1}^{\tau}s_{i_{\iota}}+s_{n}+s_{1}=\sum_{\iota=1}^{\tau}r_{i_{\iota}}+r_{n}+r_{1}=N_{1},\] and \begin{align} &0\leq r_i-\mu_{0}(X_i)N_{1}\leq N_{1}\frac{\delta}{n},(i=1,i_{1},...i_{\tau},n)\\ &0\leq s_i-\mu_{1}(X_i)N_{1}\leq N_{1}\frac{\delta}{n}, (i=1,i_{1},...i_{\tau},n)\\ &\frac{ r_{i_{\iota}}}{ s_{i_{\iota}}}=\frac{b}{b+k},\;\iota=1,...\tau\\ &\frac{a}{a+k} r_{1}+r_{n}=\frac{b}{b+k}(\frac{a}{a+k} s_{1}+s_{n}). \end{align} Define $\phi_{j}:C[0,1]\rightarrow C[0,1]$ by $\phi_{j}(f)(y)=f(h(y,t_{j}))$, Then \[w(f)(y)=\int_{0}^{1}f(h(y,t))dt=\sum_{j=1}^{N_{1}}\int_{t_{j-1}}^{t_{j}}f(h(y,t))dt\] and $$\begin{aligned} &|w(f)(y)-\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}\phi_{j}(f)(y)|\\ =&|\sum_{j=1}^{N_{1}}\int_{t_{j-1}}^{t_{j}}f(h(y,t))-f(h(y,t_{j}))dt|\\ <&\sum_{j=1}^{N_{1}}\int_{t_{j-1}}^{t_{j}}\frac{\epsilon}{4}=\frac{\epsilon}{4}.\\ \end{aligned}$$ for all $f\in F$, where $|f(h(y,t))-f(h(y,t_{j}))|<\frac{\epsilon}{4}$, because $|h(y,t)-h(y,t_{j})|<\delta_{0}$ (Note that $|t-t_{j}|\leq\dfrac{1}{N_{1}}<\delta\delta_{0}$). $\mathit{Step IV}$, We need to choose some $t_j=\dfrac{j}{N_1}$ among all of them to obtain new $N$ points, such that the corresponding average $\dfrac{1}{N}\sum\limits_i\phi_{i}$ sends $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)}$, and also this new average approximates the average of the original $N_1$ homomorphisms. But in the current situation, rather than that for Theorem \ref{thm1}, it is much more complicated. Define new integers $\qquad S_{i_{0}}=0,\;\;\;S_{i_{\gamma}}=\sum_{\iota=1}^{\gamma}s_{i_{\iota}}(\gamma=1,...,\tau),\;S_{n}=S_{i_{\tau}}+s_{n}.$ $ \qquad R_{i_{1}}=r_{i_{1}},\;R_{i_{\gamma}}=S_{i_{\gamma-1}}+r_{i_{\gamma}}(\gamma=1,...,\tau),\;R_{n}=S_{i_{\tau}}+r_{n}.$\\ Then $$\begin{aligned} &0\leq |S_{i_{\gamma}}-\sum_{\iota=1}^{\gamma}\mu_{1}(X_{i_{\iota}})N_{1}|\leq N_{1}\delta,\gamma=1,...\tau,\\ &0\leq |S_{n}-[\sum_{\iota=1}^{\tau}\mu_{1}(X_{i_{\iota}})+\mu_{1}(X_{n})]N_{1}|\leq N_{1}\delta,\\ &0\leq |R_{i_{\gamma}}-[\sum_{\iota=1}^{\gamma-1}\mu_{1}(X_{i_{\iota}})+\mu_{0}(X_{i_{\gamma}})]N_{1}|\leq N_{1}\delta,\gamma=1,...\tau,\\ &0\leq| R_{n}-[\sum_{\iota=1}^{\tau}\mu_{1}(X_{i_{\iota}})+\mu_{0}(X_{n})]N_{1}|\leq N_{1}\delta.\\ \end{aligned}$$ To ensure $\dfrac{1}{N}\sum\limits_i\phi_{i}$ sends $C[0,1]_{(a,k)}$ to $C[0,1]_{(b,k)} $, we need to exclude some functions $h(y,t_{j})$, for which $h(0,t_{j})\neq x_{i_{\iota}}$ when $j\in(S_{i_{\iota-1}},R_{i_{\iota}}]$ and $h(1,t_{j})\neq x_{i_{\iota}}$ when $j\in(S_{i_{\iota-1}},S_{i_{\iota}}](\iota=1,...,\tau)$; $h(0,t_{j})\neq 1$ when $j\in(S_{i_{\tau}},R_{n}]$ and $h(1,t_{j})\neq1$ when $j\in(S_{i_{\tau}},S_{n}]$. Assume that we throw out $m_{i_{\iota}}$ functions $h(0,t_j)$ for $j\in(S_{i_{\iota-1}},R_{i_{\iota}}](\iota=1,...,\tau)$, $m_{n}$ functions $h(0,t_j)$ for $j\in(S_{i_{\tau}},R_{n}]$, and $m_{1}$ functions $h(0,t_j)$ for the remaining $j$; $z_{i_{\iota}}$ functions $h(1,t_j)$ for $j\in(S_{i_{\iota-1}},S_{i_{\iota}}](\iota=1,...,\tau)$, $z_{n}$ functions $h(1,t_j)$ for $j\in(S_{i_{\tau}},S_{n}]$, and $z_{1}$ functions $h(1,t_j)$ for $j\in(S_{n},N_{1}]$. By Corollary \ref{boundary}, to fit in our purpose, we need to throw out functions in proportion, such that the remaining ones could satisfy the relation (3.9-10). So we need to require \begin{align} &\frac{m_{i_{\iota}}}{z_{i_{\iota}}}=\frac{b}{b+k}, \iota=1,...,\tau\\ &\frac{a}{a+k}m_{1}+m_{n}=\frac{b}{b+k}(\frac{a}{a+k}z_{1}+z_{n}). \end{align} Next we proceed in two cases. Case I: $\mu_{0}(X_{n})=0$. By (3.7), we get $ r_{n}\leq N_{1}\frac{\delta}{n}$. then take $m_{n}=0$. So we suppose $$\begin{aligned} &m_{i_{\iota}}=2\delta N_{1}b,\qquad\qquad \qquad\qquad z_{i_{\iota}}=2\delta N_{1}(b+k),\iota=1,...,\tau,\\ &m_{n}=0,\qquad\qquad \qquad\qquad \qquad\; z_{n}=t,\\ &m_{1}=2\delta N_{1}k\tau+t,\qquad \qquad\;\;\;\;\;\;\;z_{1}=0.\\ \end{aligned}$$ By (3.12), since \[\frac{a}{a+k}(2\delta N_{1}k\tau+t)=\frac{b}{b+k}t,\] one has $t=\dfrac{2\delta N_{1}a\tau(b+k)}{b-a}.$ Then we take $$\begin{aligned} &m_{i_{\iota}}=2\delta N_{1}(b-a)b,\qquad\qquad z_{i_{\iota}}=2\delta N_{1}(b-a)(b+k),\iota=1,...,\tau,\\ &m_{n}=0,\qquad\qquad \qquad\qquad \;\;\;\; z_{n}=2\delta N_{1}a\tau(b+k),\\ &m_{1}=2\delta N_{1}(a+k)\tau b,\qquad\;\;\;\;\; z_{1}=0.\\ \end{aligned}$$ Let $\delta$ satisfy $$\begin{aligned} &4n\delta(b+k)b\sup_{f\in F}\|f\|\leq\frac{\epsilon}{4},\\ &3\delta b(b-a)\leq\mu_{0}(X_{i_{\iota}}),\iota=1,2,...\tau,\\ &3\delta (a+k)b\tau\leq\mu_{0}(X_{1}),\\ &3\delta(b+k)a\tau\leq\mu_{1}(X_{n}).\\ \end{aligned}$$ By (3.7-3.8), we have $$\begin{aligned} &r_{i_{\iota}}> 2\delta N_{1}(b-a)b,\iota=1,2,...,\tau,\\ &r_{1}> 2\delta N_{1}(a+k)b\tau,\\ &s_{i_{\iota}}>2\delta N_{1}(b-a)(b+k),\iota=1,2,...,\tau,\\ &s_{n}> 2\delta N_{1}(b+k)a\tau.\\ \end{aligned}$$ Consider the set $\Lambda_1$ of integers $j$ which belongs to one of the following intervals: $$\begin{aligned} &S_{i_{\gamma-1}}+\delta N_{1}(b-a)b+1\leq j\leq R_{i_{\gamma}}-\delta N_{1}(b-a)b,\gamma=1,...,\tau,\\ &R_{i_{\gamma}}+1\leq j\leq S_{i_{\gamma}}-\delta N_{1}(b-a)k,\gamma=1,...,\tau,\\ &S_{i_{\tau}}+\delta N_{1}(b+k)a\tau+1\leq j\leq S_{n}-\delta N_{1}(b+k)a\tau,\\ &S_{n}+1\leq j\leq N_{1}.\\ \end{aligned}$$ Set $D_1=\{\frac{j}{N_1}\mid j\in\Lambda_1\}$ and $N=|D_1|$, then by the construction of $h(y,t)$, point evaluations of $h$ at the points in $D_1$ has the following conclusion: $$\begin{aligned} &h(0,t_{j})\!=\!h(1,t_{j})=\!x_{i_{\gamma}}, \,\text{if}\, S_{i_{\gamma-1}}\!+\!\delta N_{1}(b-a)b\!+\!1\leq \!j\!\leq R_{i_{\gamma}}\!-\!\delta N_{1}(b-a)b\!,\gamma=1,...,\tau\\ &h(0,t_{j})=0,h(1,t_{j})=x_{i_{\gamma}}, \,\text{if}\, R_{i_{\gamma}}+1\leq j\leq S_{i_{\gamma}}-\delta N_{1}(b-a)k,\gamma=1,...,\tau\\ &h(0,t_{j})=0,h(1,t_{j})=1, \,\text{if} \,S_{i_{\tau}}+\delta N_{1}(b+k)a\tau+1\leq j\leq S_{n}-\delta N_{1}(b+k)a\tau,\\ &h(0,t_{j})=0=h(1,t_{j}), \,\text{if}\,S_{n}+1\leq j\leq N_{1}.\\ \end{aligned}$$ Note that $N=N_{1}(1-2\delta\tau(b+k)b)$, and one has that $$\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(0)=\frac{1}{N}\sum_{d=1}^{N}f(h(0,t_{d}))=\frac{1}{N}[\sum_{\iota=1}^{\tau}(r_{i_{\iota}}-m_{i_{\iota}})f(x_{i_{\iota}})+ (r_{1}-m_{1})f(0)],$$ and $$\begin{aligned} &\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(1)=\frac{1}{N}\sum_{d=1}^{N}f(h(1,t_{d}))\\ =&\frac{1}{N}[\sum_{\iota=1}^{\tau}(s_{i_{\iota}}-z_{i_{\iota}})f(x_{i_{\iota}})+(s_{n}-z_{n})f(1)+s_{1}f(0)].\\ \end{aligned}$$ Thus $$\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(0)=\frac{b}{b+k}\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(1)$$ because of (3.9-3.12) and Corollary \ref{boundary}. Next, we show that the average of these $N$ homomorphisms will approximate the average of the original $N_{1}$ homomorphisms: $$\begin{aligned} &|\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{N}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ =&|\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{N_{1}(1-2\delta\tau(b+k)b)}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ =&\frac{1}{N_{1}}|\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{(1-2\delta\tau(b+k)b)}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ =&\frac{1}{N_{1}}|\sum_{d\notin D_{1}}f(h(y,t_{d})+(1-\frac{1}{1-2\delta\tau(b+k)b})\sum_{d=1}^{N}f(h(y,t_{d}))|\\ \leq&\frac{1}{N_{1}}(N_{1}2\delta\tau(b+k)b \sup_{f\in F}\|f\|+N_{1}2\delta\tau(b+k)b\sup_{f\in F}\|f\|)\\ =&4\delta\tau(b+k)b\sup_{f\in F}\|f\|\leq\frac{\epsilon}{4}\;(since\;\tau\leq n-2).\\ \end{aligned}$$ Case II: $\mu_{0}(X_{n})\neq0$. Let $\delta$ satisfy $$\begin{aligned} &4\delta n(k+b)b\sup_{f\in F}\|f\|\leq\frac{\epsilon}{4},\\ &3\delta (b-a)b<\mu_{0}(X_{i_{\iota}}),\iota=1,2,...\tau,\\ &3\delta (b-a)b<\mu_{0}(X_{n}),\, 3\delta (a+k)(b+b\tau)<\mu_{0}(X_{1}),\\ &3\delta(b+k)(a\tau+b)<\mu_{1}(X_{n}).\\ \end{aligned}$$ By (3.7-3.8), we have $$\begin{aligned} &r_{i_{\iota}}> 2\delta N_{1}(b-a)b,\iota=1,2,...,\tau,\\ &r_{n}> 2\delta N_{1}(b-a)b,\\ &r_{1}>2\delta N_{1}(a+k)(1+\tau)b,\\ &s_{i_{\iota}}> 2\delta N_{1}(b-a)(b+k),\iota=1,2,...,\tau,\\ &s_{n}> 2\delta N_{1}(b+k)(a\tau+b).\\ \end{aligned}$$ So we suppose $$\begin{aligned} &m_{i_{\iota}}=2\delta N_{1}(b-a)b,\qquad\qquad z_{i_{\iota}}=2\delta N_{1}(b-a)(b+k),\iota=1,...,\tau,\\ &m_{n}=2\delta N_{1}(b-a)b, \qquad\qquad z_{n}=2\delta N_{1}(b-a)b+t,\\ &m_{1}=2\delta N_{1}k\tau(b-a)+t, \qquad z_{1}=0.\\ \end{aligned}$$ By (3.8), since \[\frac{a}{a+k}[2\delta N_{1}k\tau(b-a)+t]+2\delta N_{1}(b-a)b=\frac{b}{b+k}[2\delta N_{1}(b-a)b+t],\]\\ one has $t=2\delta N_{1}[a\tau(b+k)+b(a+k)]$. Then we take $$\begin{aligned} &m_{i_{\iota}}=2\delta N_{1}(b-a)b,\qquad\qquad z_{i_{\iota}}=2\delta N_{1}(b-a)(b+k),\iota=1,...,\tau,\\ &m_{n}=2\delta N_{1}(b-a)b,\qquad\qquad z_{n}=2\delta N_{1}(a\tau+b)(b+k),\\ &m_{1}=2\delta N_{1}(a+k)(a+\tau)b,\;\;\;z_{1}=0.\\ \end{aligned}$$ Consider the set $\Lambda_2$ of integers $j$ which belongs to one of the following intervals: $$\begin{aligned} &S_{i_{\gamma-1}}+\delta N_{1}(b-a)b+1\leq j\leq R_{i_{\gamma}}-2\delta N_{1}(b-a)b,\gamma=1,...,\tau,\\ &R_{i_{\gamma}}+1\leq j\leq S_{i_{\gamma}}-\delta N_{1}(b-a)k,\gamma=1,...,\tau,\\ &S_{i_{\tau}}+\delta N_{1}(b-a)b+1\leq j\leq R_{n}-\delta N_{1}(b-a)b,\\ &R_{n}+1\leq j\leq S_{n}-2\delta N_{2}(ab\tau+ak\tau+bk+ba),\\ &S_{n}+1\leq j\leq N_{1}.\\ \end{aligned}$$ Set $D_2=\{\frac{j}{N_1}\mid j\in\Lambda_2\}$ and $N=|D_2|$, then by the construction of $h(y,t)$, point evaluations of $h$ at the points in $D_2$ has the following conclusion: $$\begin{aligned} &h(0,t_{j})=h(1,t_{j})=x_{i_{\gamma}}\!, \,\text{if}\,S_{i_{\gamma-1}}\!+\!\delta N_{1}(b-a)b\!+\!1\leq \!j\!\leq R_{i_{\gamma}}\!-\!\delta N_{1}(b-a)b,\gamma=1,...,\tau\\ &h(0,t_{j})=0,h(1,t_{j})=x_{i_{\gamma}}, \,\text{if}\,R_{i_{\gamma}}+1\leq j\leq S_{i_{\gamma}}-\delta N_{1}(b-a)k,\gamma=1,...,\tau\\ &h(0,t_{j})=h(1,t_{j})=1, \,\text{if}\,S_{i_{\tau}}+\delta N_{1}(b-a)b+1\leq j\leq R_{n}-\delta N_{1}(b-a)b,\\ &h(0,t_{j})=0,h(1,t_{j})=1, \,\text{if}\,R_{i_{\tau}}++1\leq j\leq S_{n}-2\delta N_{1}(ab\tau+ak\tau+bk+ba),\\ &h(0,t_{j})=0=h(1,t_{j}), \,\text{if}\,S_{n}+1\leq j\leq N_{1}.\\ \end{aligned}$$ Note that $N=N_{1}(1-4\delta(1+\tau)(k+b)b)$, one has that $$\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(0)=\frac{1}{N}[\sum_{\iota=1}^{\tau}(r_{i_{\iota}}-m_{i_{\iota}})f(x_{i_{\iota}})+(r_{n}-m_{n})f(1)+(r_{1}-m_{1})f(0)],$$ and $$\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(1)=\frac{1}{N}[\sum_{\iota=1}^{\tau}(s_{i_{\iota}}-z_{i_{\iota}})f(x_{i_{\iota}})+(s_{n}-z_{n})f(1)+s_{1}f(0)].$$ Thus $$\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(0)=\frac{b}{b+k}\frac{1}{N}\sum_{d=1}^N\phi_{d}(f)(1)$$ because of (3.9-3.12) and Corollary \ref{boundary}. Next, we show the average of these $N$ homomorphisms will approximate the average of the original $N_{1}$ homomorphisms: $$\begin{aligned} &|\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{N}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ =&|\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{k}))-\frac{1}{N_{1}(1-2\delta(1+\tau)(k+b)b}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ =&\frac{1}{N_{1}}|\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{1-2\delta(1+\tau)(k+b)b}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ =&\frac{1}{N_{1}}|\sum_{d\notin D_{2}}f(h(y,t_{d})+(1-\frac{1}{1-2\delta(1+\tau)(k+b)b}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ \leq&\frac{1}{N_{2}}(N_{1}2\delta(1+\tau)(k+b)b\sup_{f\in F}\|f\|+N_{1}2\delta(1+\tau)(k+b)b)\sup_{f\in F}\|f\|)\\ =&4\delta(1+\tau)(k+b)b \sup_{f\in F}\|f\|\leq\frac{\epsilon}{4} \;(since\; \tau\leq n-2)\\ \end{aligned}$$ In other words, no matter in which cases we can always find $N$ functions $h(y, t_d), d=1,...,N$, as required. Finally, let us define $\phi_{d}:C[0,1]\rightarrow C[0,1]$ by $\phi_{d}(f(y))=f(h(y,t_{d}))$, for $d=1,...,N$, then $$\begin{aligned} &|\phi(f)(y)-\frac{1}{N}\sum_{d=1}^{N}\phi_{j}(f)(y)|\\ =&|\phi(f)(y)-\frac{1}{N}\sum_{d=1}^{N}f(h(y,t_{d}))|\\ \leq&|\phi(f)(y)-\sum_{i=1}^{n}\lambda_{i}(y)f(x_{i})|+|\sum_{i=1}^n\lambda_{i}(y)f(x_{i})-w(f)(y)|\\ +&|w(f)(y)-\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))|+|\frac{1}{N_{1}}\sum_{j=1}^{N_{1}}f(h(y,t_{j}))-\frac{1}{N}\sum_{d=1}^{N}f( h(y,t_{d}))|\\ \leq&\frac{\epsilon}{4}+\frac{\epsilon}{4}+\frac{\epsilon}{4}+\frac{\epsilon}{4}\leq\epsilon\\ \end{aligned}$$ \end{proof} \begin{remark} 1, In the proof of Theorem \ref{thm2}, rather than Theorem \ref{thm1}, we could only achieve that the number of homomorphisms depends on the finite subset $F$, $\epsilon$ and $\phi$. 2, In an overview of the approximation procedure above, one can see that the crucial thing is the distribution of the measures induced by evaluations of $\phi$ at 0 and 1, which determines the boundary condition at algebra level. This idea will go through in general cases. \end{remark} Next, we consider general subspaces of $C[0,1]$: $$C[0,1]_\alpha=\{f\in C[0,1] \mid f(0)=\alpha f(1)\},$$ where $0< \alpha<1$. Obviously, it is also a subspace of co-dimension one. Applying similar proofs as in Lemma \ref{point mass}, Lemma \ref{mea2}, Corollary \ref{lem:mea} and Corollary \ref{boundary}, parallel results hold in this general setting, namely, the corresponding measures induced by evaluations of a Markov operator at 0 and 1 have similar features. \begin{lem}\label{mea3} Given any unital positive linear map $\phi$ on $C[0,1]$ which sends $C[0,1]_{\alpha}$ to $C[0,1]_{\beta}$, denote by $\mu_{0}$ and $\mu_{1}$ the measures induced by evaluations of $\phi$ at 0 and 1. Let there be given a partition $\{X_{1},X_{2},...,X_{n}\}$ of $[0,1]$, where $X_{i}$ is a connected Borel set and $0\in X_{1},1\in X_{n}$. Then we have the following distribution of $\mu_{0}$ and $\mu_{1}$ with respect to the partition: $$\begin{aligned} &\mu_{0}(X_{i})=\beta\mu_{1}(X_{i}) \;for \;i=2,...,n-1,\\ &\alpha\mu_{0}(X_{1})+\mu_{0}(X_{n})=\beta[\alpha\mu_{1}(X_{1})+\mu_{1}(X_{n})].\\ \end{aligned}$$ \end{lem} \begin{cor}\label{lem:gmea1} Given any unital positive linear map $\phi$ from $C[0,1]$ to $C[0,1]$ which sends $C[0,1]_{\alpha}$ to $C[0,1]_{\beta}$, denote by $\mu_{0}$ and $\mu_{1}$ the measures induced by evaluations of $\phi$ at 0 and 1. Let there be given a partition $\{X_{1},X_{2},...,X_{n}\}$ of $[0,1]$, where $X_{i}$ is a connected Borel set and $0\in X_{1},1\in X_{n}$. Then we have the following distribution of $\mu_0$ and $\mu_1$ with respect to the partition: $$\begin{aligned} &\mu_{0}(X_{1})=\beta\mu_{1}(X_{1})+\frac{1-\beta}{1-\alpha},\\ &\mu_{0}(X_{n})=\beta\mu_{1}(X_{n})-\frac{1-\beta}{1-\alpha}\alpha.\\ \end{aligned}$$ In particularly, if $\alpha=\beta$, then $\phi(f)(0)=f(0), \phi(f)(1)=f(1)$ for all $f\in C[0,1]$. \end{cor} Once the distribution of the induced measures at 0 and 1 has similar features, then the corresponding approximation results hold. \begin{thrm}\label{same} Given any finite subset $ F \subset C[0,1]_\alpha$ and $\epsilon>0$, there is an integer $ N>0$ with the following property: for any unital positive linear map $\phi$ on $C[0,1]$ which preserves $C[0,1]_\alpha$, there are N homomorphisms $\phi_{1},\phi_{2},...,\phi_{N}$ from $C[0,1]$ to $C[0,1]$ such that $\dfrac{1}{N}\sum\limits_{i=1}^{N}\phi_{i}(f)\in C[0,1]_\alpha$ for all $f\in C[0,1]_\alpha$ and $$\|\phi(f)-\frac{1}{N}\sum_{i=1}^N\phi_{i}(f)\| < \epsilon$$ for all $f\in F$. \end{thrm} \begin{proof} Because the measures induced by evaluations of $\phi$ at 0 and 1 are still point mass measures by Corollary \ref{lem:gmea1}, similar proofs as in Theorem \ref{thm1} go through. \end{proof} \begin{thrm}\label{rational} Let $\alpha$, $\beta$ be rational numbers and $\beta>\alpha$, given any finite subset $ F \subset C[0,1]_\alpha$ and $\epsilon>0$, for any unital positive linear map $\phi$ on $C[0,1]$ which sends $C[0,1]_\alpha$ to $C[0,1]_\beta$ , there are N homomorphisms $\phi_{1},\phi_{2},...,\phi_{N}$ from $C[0,1]$ to $C[0,1]$ such that $\dfrac{1}{N}\sum_{i=1}^N\phi_{i}(f)\in C[0,1]_\beta$ for all $f\in C[0,1]_\alpha$ and $$\|\phi(f)-\frac{1}{N}\sum_{i=1}^N\phi_{i}(f)\| < \epsilon$$ for all $f\in F$. \end{thrm} \begin{proof} Based on Lemma \ref{mea3} and Corollary \ref{lem:gmea1}, parallel results as Lemma \ref{mea2}, Corollary \ref{lem:mea} and Corollary \ref{boundary} hold, then similar proofs as in Theorem \ref{thm2} go through. \end{proof} \begin{remark} Because of some technicalities in the approximation procedure, mainly about some integer issue at certain points, we restrict our attentions on the case that $\alpha, \beta$ being rational numbers in the theorem above. \end{remark} \section{generalizations} In general, we replace $[0,1]$ by compact metrizable spaces $X$ and $Y$. Let $p,q$ and $z, w$ be fixed points in $X$ and $Y$, $\alpha, \beta\in(0,1)$, and consider subspaces:$$C(X)_{(p, q, \alpha)}=\{f\in C(X) \mid f(p)=\alpha f(q)\},$$ and $$C(Y)_{(z, w, \beta)}=\{f\in C(Y) \mid f(z)=\beta f(w)\}.$$ Similarly, in this case, the corresponding measures have the same features. \begin{lem}\label{mea4} Let there be given compact metrizable spaces $X$ and $Y$. Given any unital positive linear map $\phi$ from $C(X)$ to $C(Y)$ which sends $C(X)_{(p,q,\alpha)}$ to $C(Y)_{(z,w,\beta)}$, denote by $\mu_{z}$, $\mu_{w}$ the measures induced by evaluations of $\phi$ at $z$ and $w$. Let there be given a partition $\{X_{1},X_{2},...,X_{n}\}$ of $X$, where $X_{i}$ is a connected Borel set and $p\in X_{1},q\in X_{n}$. Then we have the following distribution of $\mu_{z}$ and $\mu_{w}$ with respect to the partition: $$\begin{aligned} &\mu_{z}(X_{i})=\beta\mu_{w}(X_{i}) \;for \;i=2,...,n-1,\\ &\alpha\mu_{z}(X_{1})+\mu_{z}(X_{n})=\beta[\alpha\mu_{w}(X_{1})+\mu_{w}(X_{n})].\\ \end{aligned}$$ \end{lem} \begin{proof} First of all we prove the first relation for $i=2,...,n-1.$ By the regularity of $\mu_{z},\mu_{w}$, for any $\epsilon>0$, there exist open sets $O_{i0},O_{i1}\supseteq X_{i}$, closed sets $F_{i0},F_{i1}\subseteq X_{i}$ with $ \mu_{z}(O_{i0}\setminus F_{i0})<\epsilon $, $ \mu_{w}(O_{i1}\setminus F_{i1})<\epsilon $. Let $F_{i}=F_{i0}\cup F_{i1}\subseteq X_{i}$, then $F_{i}$ is closed and $\mu_{z}(X_{i}\setminus F_{i})<\epsilon $, $ \mu_{w}(X_{i}\setminus F_{i})<\epsilon$. Since $p\notin X_{i}, q\notin X_{i}$, then $p\notin F_{i}, q\notin F_{i}$, then there are open sets $Q_{i0},Q_{i1}\supseteq F_{i}$, such that $p\notin Q_{i0}$, $q\notin Q_{i1}$. Let $O_{i}=O_{i0}\cap O_{i1}\cap Q_{i0}\cap Q_{i1} $, then $O_{i}$ is open ,$O_{i}\supseteq F_{i}$ and $\mu_{z}(O_{i}\setminus F_{i})<\epsilon $, $ \mu_{w}(O_{i}\setminus F_{i})<\epsilon $. Since $X$ is a normal space, and $ O_{i}^{c}\cap F_{i}=\varnothing$, by Urysohn's Lemma, there is a continuous function $f_{i}:X\rightarrow[0,1]$ such that $f_{i}(x)={1}$ if $x\in F_{i}$, $f_{i}(x)={0}$ if $x\in O_{i}^{c}$; moreover, $f_{i}\in C(X)_{(p,q,\alpha)}$ since $p, q\notin O_{i}$. Then $\phi(f_{i})\in C(Y)_{(z,w,\beta)}$, while \[\phi(f_{i})(z)=\int_{X}f_{i}d\mu_{z}=\mu_{z}(F_{i})+\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{z},\] \[\phi(f_{i})(w)=\int_{X}f_{i}d\mu_{w}=\mu_{w}(F_{i})+\int_{O_{i}\setminus F_{i})}f_{i}d\mu_{w},\] so \[\beta=\frac{\phi(f_{i})(z)}{\phi(f_{i})(w)}=\frac{\mu_{z}(F_{i})+\int_{(O{i}\setminus F_{i})}f_{i}d\mu_{z}}{\mu_{w}(F_{i})+\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{w}}.\] Then $$\beta\mu_{w}(F_{i})+\beta\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{w}=\mu_{z}(F_{i})+\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{z},$$ and $$\begin{aligned} &|\beta\mu_{w}(X_{i})-\mu_{z}(X_{i})|\\ =&|\beta[\mu_{w}(X_{i})-\mu_{w}(F_{i})]-[\mu_{z}(X_{i})-\mu_{z}(F_{i})]\\ +&\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{z}-\beta\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{w}|\\ =&|\beta\mu_{w}(X_{i}\setminus F_{i})-(\mu_{z}(X_{i}\setminus F_{i})+\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{z}-\beta\int_{(O_{i}\setminus F_{i})}f_{i}d\mu_{w}|\\ \leq&4\varepsilon.\\ \end{aligned}$$ Then $ \beta\mu_{w}(X_{i})=\mu_{z}(X_{i})$ when $\varepsilon$ tends to 0, $ i=2,...,n-1$. Secondly, we prove the second relation for $i=1$ and $i=n.$ There exist open sets $O_{1},O_{n}$, closed sets $F_{1},F_{n}$, with $O_{1}\supseteq X_{1}\supseteq F_{1},O_{n}\supseteq X_{n}\supseteq F_{n}$, such that $ \mu_{z}(O_{1}\setminus F_{1})<\epsilon, \mu_{z}(O_{n}\setminus F_{n})<\epsilon, \mu_{w}(O_{1}\setminus F_{1})<\epsilon, \mu_{w}(O_{n}\setminus F_{n})<\epsilon.$ We have $F_{1}\cap F_{n}=\varnothing$ since $X_{1}\cap X_{n}=\varnothing$, then there exist open sets $ Q_{1}\supseteq F_{1}, Q_{n}\supseteq F_{n}$, such that $Q_{1}\cap Q_{n}=\varnothing$. Let us set $A_{1}=O_{1}\cap Q_{1},A_{n}=O_{n}\cap Q_{n}$, then $A_{1}\supseteq F_{1}, A_{n}\supseteq F_{n}$. By Urysohn's Lemma, there is a continuous function $f_{1}:X\rightarrow[0,1]$ such that $f_{1}(x)={\alpha}$ if $x\in F_{1}$, $f_{1}(x)={0}$ if $x\in A_{1}^{c}$; and a continuous function $f_{n}:X\rightarrow[0,1]$ such that $f_{n}(x)={1}$ if $x\in F_{n}$, $f_{n}(x)={0}$ if $x\in A_{n}^{c}$. Let $f=f_{1}+f_{n}$, then $f$ is a continuous function from $X$ to $ [0,1]$. We have $f(x)=f_{1}(x)+f_{n}(x)=\alpha+0=\alpha$ if $x\in F_{1}$, $f(x)=f_{1}(x)+f_{n}(x)=0+1=1$ if $x\in F_{n}$, $f(x)=f_{1}(x)+f_{n}(x)=0$ if $x\in A_{1}^{c}\cap A_{n}^{c}$. Suppose $p\in F_{1}, q\in F_{n}$, if not, we add $p$ into $ F_{1}$, $q$ into $F_{n}$, then $f\in C(X)_{(p,q,\alpha)}$, and $\phi(f)\in C(Y)_{(z,w,\beta)}$, while \[\phi(f)(z)=\int_{X}fd\mu_{z}=\alpha\mu_{z}(F_{1})+\mu_{z}(F_{n})+\int_{(A_{1}\setminus F_{1})}fd\mu_{z}+\int_{(A_{n}\setminus F_{n})}fd\mu_{z},\] \[\phi(f)(w)=\int_{X}fd\mu_{w}=\alpha\mu_{w}(F_{1})+\mu_{w}(F_{n})+\int_{(A_{1}\setminus F_{1})}fd\mu_{w}+\int_{(A_{n}\setminus F_{n})}fd\mu_{w},\] so \[\beta=\frac{\phi(f)(z)}{\phi(f)(w)}=\frac{\alpha\mu_{z}(F_{1})+\mu_{z}(F_{n})+\int_{(A_{1}\setminus F_{1})}fd\mu_{z}+\int_{(A_{n}\setminus F_{n})}fd\mu_{z}}{\alpha\mu_{w}(F_{1})+\mu_{w}(F_{n})+\int_{(A_{1}\setminus F_{1})}fd\mu_{w}+\int_{(A_{n}\setminus F_{n})}fd\mu_{w}}.\] Then $$\begin{aligned} &|\alpha\mu_{z}(X_{1})+\mu_{z}(X_{n})-\beta[\alpha\mu_{w}(X_{1})+\mu_{w}(X_{n})]|\\ =&|\alpha[\mu_{z}(X_{1})-\mu_{z}(F_{1})]+[\mu_{z}(X_{n})-\mu_{z}(F_{n})]\\ -&[\int_{(A_{1}\setminus F_{1})}fd\mu_{z}+\int_{(A_{n}\setminus F_{n})}fd\mu_{z}]\\ -&\beta\{\alpha[\mu_{w}(X_{1})-\mu_{w}(F_{1})]+[\mu_{w}(X_{n})-\mu_{w}(F_{n})]\\ -&[\int_{(A_{1}\setminus F_{1})}fd\mu_{w}+\int_{(A_{n}\setminus F_{n})}fd\mu_{w}]\}|\\ \leq&8\epsilon\\ \end{aligned}$$ Thus $\alpha\mu_{z}(X_{1})+\mu_{z}(X_{n})=\beta(\alpha\mu_{w}(X_{1})+\mu_{w}(X_{n}))$ when $\epsilon$ tends to 0. \end{proof} \begin{cor}\label{lem:gmea4} Let there be given compact metrizable spaces $X$ and $Y$. Given any unital positive linear map $\phi$ from $C(X)$ to $C(Y)$ which sends $C(X)_{(p,q,\alpha)}$ to $C(Y)_{(z,w,\beta)}$, denote by $\mu_{z}$, $\mu_{w}$ the measures induced by evaluations of $\phi$ at $z$ and $w$. Let there be given a partition $\{X_{1},X_{2},...,X_{n}\}$ of $X$, where $X_{i}$ is a connected Borel set and $p\in X_{1},q\in X_{n}$. Then we have the following distribution of $\mu_z$ and $\mu_w$ with respect to the partition: $$\begin{aligned} &\mu_{z}(X_{1})=\beta\mu_{w}(X_{1})+\frac{1-\beta}{1-\alpha},\\ &\mu_{z}(X_{n})=\beta\mu_{w}(X_{n})-\frac{1-\beta}{1-\alpha}\alpha.\\ \end{aligned}$$ In particularly, if $\alpha=\beta$, then $\phi(f)(z)=f(p), \phi(f)(w)=f(q)$ for all $f\in C(X)$. \end{cor} \textbf{Finally Theorem \ref{thm3} and Theorem \ref{thm4} are confirmed:} \begin{proof} Based on Lemma \ref{mea4} and Corollary \ref{lem:gmea4}, similar proofs as in Theorem \ref{thm1}, \ref{thm2} work. \end{proof} \proof[Acknowledgements] The research of the first author was supported by a grant from the Natural Sciences and Engineering Research Council of Canada. He is indebted to The Fields Institute for their generous support of the field of operator algebras. The first author is indebted to Cristian Ivanescu for substantial discussions. The second author is supported by the National Science Foundation of China with grant No. 11501060; he is also supported by the Fundamental Research Funds for the Central Universities (Project No. 2018CDXYST0024 in Chongqing University).
\section{Introduction} Due to the continuous improvement of computer-processing capacities, the demand for highly accurate numerical simulations which also account for uncertain input parameters is growing. Uncertainties might arise from limitations in measuring physical phenomena exactly or from a systematical absence of knowledge about the underlying physical processes. Uncertainty Quantification (UQ) addresses this issue and provides mathematical methods to quantify the influence of uncertain input parameters on the numerical solution itself or on derived quantities of interest. There exist two major approaches for UQ. On the one hand, non-statistical approaches like the intrusive and non-intrusive polynomial chaos expansion approximate the underlying random field by a series of polynomials and derive deterministic models for the stochastic modes. On the other hand, statistical approaches such as Monte Carlo (MC) type methods sample the random space to obtain statistical information, like mean, variance or higher order moments of the corresponding random field. Especially MC type methods are very popular as they are easy to implement and only require a deterministic black box solver. Moreover, in contrast to non-statistical approaches, the MC method does not rely on the regularity of the underlying random field, rendering it a very robust method. However, the convergence of MC methods is dictated by the law of large numbers, hence relatively slow and therefore computationally expensive. To overcome these difficulties Heinrich \cite{Heinrich2001} and later Giles \cite{Giles2008} extended the MC method to the Multilevel Monte Carlo (MLMC) method, where they considered different mesh hierarchies instead of one fixed mesh, to discretize the deterministic equation of interest. The MLMC method relies on the idea that the global behavior of the exact expectation can be approximated by the behavior of the expectation of numerical solutions with a low spatial resolution, which can be computed at low cost. The coarse expectation is then subsequently corrected by computations on finer meshes, which are computationally more expensive per sample. The number of these simulations at full resolution is significantly reduced compared to the original MC method resulting in a considerably lower overall computational cost. Since its development the MLMC method has been very successfully applied to UQ for many different partial differential equations with uncertainties, as for example in \cite{BarthMLMCHyperbolic,BarthMLMCParabolic,BarthMLMC,CliffeScheichl2011,NobileCMLMC, HoelKrumscheid2019,MishraSchwabSukysNonlinearSystems,AppeloeMOMC}. We refer to \cite{ChenMing2018,Nobile2017} for applications of the MLMC method in computational fluid dynamics, especially to aerodynamics and meteorology. A generalization of the MLMC method, named Multiindex Monte Carlo (MIMC) method, has been presented in \cite{TemponeNobile2016}. In contrast to the MLMC method, which computes mean and variance using first-order differences, the MIMC method uses high-order differences which allows for a faster decay of the corresponding level variances, resulting in significant efficiency gains compared to the standard MLMC method. In \cite{AppeloeMOMC} the authors extended the MLMC method for hyperbolic problems to a Multiorder Monte Carlo method (MOMC), using an energy-preserving Discontinuous Galerkin (DG) scheme for the elastic wave equation, which we will dub $p$-MLMC for the remainder of this article. The authors considered either mesh refinements ($h$-refinement), or increased the DG polynomial degree ($p$-refinement) to obtain a hierarchy of different levels. Furthermore, they proved that the computational complexity to reach a prescribed accuracy is of quadratic order with respect to the accuracy. However, a proof for the computational complexity for a hierarchy of $hp$-refined meshes is still open. We therefore extend the $h$- and $p$-MLMC method to an $hp$-MLMC method, where we uniformly refine the physical mesh and at the same time uniformly increase the DG polynomial degree. As the first new contribution of this work, we extend the complexity analysis from \cite{CliffeScheichl2011, AppeloeMOMC} to arbitrarily $hp$-refined meshes and show that the $hp$-MLMC method is - up to a constant - as efficient as the $h$-MLMC and the $p$-MLMC method. The $hp$ mesh hierarchy enables us to cover a very large range of resolution levels, which is crucial for the efficiency of the $hp$-MLMC method. Furthermore, from a numerical point of view, a low polynomial degree (resulting in a more dissipative numerical scheme) might be favorable in connection with coarse meshes, where an insufficient resolution can otherwise lead to unphysical oscillations, whereas a high polynomial degree yields higher accuracy when fine meshes are employed. The $hp$-MLMC method becomes an attractive alternative for mesh-based MLMC methods if uniform mesh hierarchies are not available. This might occur for complex domain geometries or when using dynamical mesh adaption. In view of the recent rise of higher-order schemes it seems likely to exploit a mixture method. In contrast to $h$-refinement, $hp$-refinement introduces more degrees of freedom in designing a suitable mesh hierarchy. For complex fluid dynamical problems, e.g. direct numerical simulations of unsteady, compressible Navier-Stokes equations, it is inevitable to use large-scale computing systems. These systems are in most cases equipped with a queuing system. When using the $hp$-MLMC method on queue-based, large-scale computing systems, due to long queuing times, it is desirable to compute as many samples as possible per iteration. On the other hand, to avoid unnecessary computations and to increase the efficiency of the $hp$-MLMC method, one is interested to not overestimate the optimal number of samples per iteration. Therefore, as the second novel contribution, we show how to construct easily a robust lower confidence bound for the number of samples per level, which avoids overshooting the optimal number of samples, but still yields a reasonably large number of additional samples per iteration. To demonstrate the efficiency of the $hp$-MLMC method combined with the novel sample estimator we apply our method to two different compressible flow problems, a benchmark problem with smooth solution and an open cavity flow problem. The latter is an important problem in computational acoustics that exhibits physical phenomena with high sensitivity with respect to the problem parameters \cite{Kuhn2018}. Moreover, we provide for both problems a thorough comparison of the $h$-, $p$- and $hp$-MLMC methods. This article is structured as follows. In \secref{sec:prelim} we introduce the necessary mathematical framework and briefly introduce the DG method. In \secref{sec:MLMC} we describe the $hp$-MLMC method and prove the stated complexity result. We also discuss the necessity of confidence intervals for the estimate of the optimal number of samples when working on queue-based large-scale computing systems. Finally, in \secref{sec:numerics} we apply our method to two different examples and verify our theoretical results. \section{Notation and Preliminaries} \label{sec:prelim} \subsection{A Primer on Probability Theory} We let $(\Omega, \F,\P)$ be a probability space, where $\Omega$ is the set of all elementary events $\omega \in \Omega$, $\F$ is a $\sigma$-algebra on $\Omega$ and $\P$ is a probability measure. We further consider a second measurable space ($E, \mathcal{B}(E))$, where $E$ is a Banach space and $\mathcal{B}(E)$ is the corresponding Borel $\sigma$-algebra. An $E$-valued random field is any mapping $X:\Omega \to E$ such that $\{\omega \in \Omega: X(\omega) \in B\}\in \F$ holds for any $B\in \mathcal{B}(E)$. For $ r \in [1,\infty) \cup \{\infty\}$ we consider the Bochner space $\leb{r}{\Omega}{E}$ of $r$-summable $E$-valued random variables $X$ equipped with the norm \begin{align*} \|X\|_{\leb{r}{\Omega}{E}} := \begin{cases} (\int_\Omega \|X(\omega)\|_E^r ~\dPOmega)^{1/r} = \E{\|X\|_E^r}^{1/r},\quad& 1\leq r<\infty \\ \operatorname{ess~sup}\limits_{\omega \in \Omega} \|X(\omega)\|_E, &r= \infty . \end{cases} \end{align*} The uncertainty is introduced via a random vector $\xi(\omega) = \big(\xi_1(\omega),\ldots, \xi_N(\omega)\big) : \Omega\to \Xi \subset \R^N$ with independent, absolutely continuous random variables as components. This means that for each random variable $\xi_i$ there exists a density function $f_{\xi_i}:\R \to \R_+$, such that $\int_{\R} f_{\xi_i}(y)~ \mathrm{d}y=1$ and $\P[ \xi_i \in A]=\int_A f_{\xi_i}(y)~ \mathrm{d}y$ for any $A \in \mathcal{B}(\R)$ and for all $i=1,\ldots, N$. Moreover, the joint density function $f_{\xi}$ of the random vector $\xi = (\xi_1,\ldots,\xi_N)$ can be written as $ f_{\xi}(y) = \prod \limits_{i=1}^N f_{\xi_i}(y_i)\quad \text{for all } ~ y= (y_1,\ldots, y_N)^\top \in \Xi.$ The random vector induces a probability measure $\tilde{\P}(B):= \P( \xi^{-1}(B))$ for all $B \in \mathcal{B}(\Xi)$ on the measurable space $(\Xi, \mathcal{B}(\Xi))$. This measure is called the law of $\xi$ and in the following we work on the image probability space $(\Xi, \mathcal{B}(\Xi), \tilde{\P})$. \subsection{The Random Navier-Stokes Equations} As the physical space we consider a bounded domain $D\subset \R^2$ and we further define the space-time-stochastic domain $D_{T,\Xi}:= (0,T) \times D\times \Xi$. We focus on the random compressible Navier-Stokes equations given by \begin{equation} \label{eq:NSE} U_t+{\nabla}_x \cdot ({G}(U)-{H}(U,{\nabla}_xU))=0, \qquad \forall ~ (t,{x},y) \in D_{T,\Xi}, \end{equation} where $U(t,{x},y)$ denotes the solution vector of the conserved quantities, i.e. we have $U=(\rho,\rho v_1, \rho v_2,\rho e)^\top$. ${G}$ and ${H}$ denote the advective and viscous fluxes, i.e. \begin{equation} {G}_{i}(U)=\begin{pmatrix}\rho\, v_i\\ \rho\, v_1 v_i +\delta_{1i}\,p\\ \rho\, v_2 v_i +\delta_{2i}\,p\\ \rho\,ev_i + p\,v_i\end{pmatrix},\; \quad {H}_{i}(U,{\nabla}_{x}U)=\begin{pmatrix}0\\ \tau_{1i}\\ \tau_{2i} \\ \tau_{ij}v_j - q_i\end{pmatrix}, \quad i=1,2. \end{equation} Here, $\delta_{ij}$ is the Kronecker delta function and the physical quantities $\rho$, ${v}=(v_1,v_2)^\top$, $p$, and $e$ represent density, the velocity vector, the pressure and the specific total energy, respectively. With Stokes' and Fourier's hypothesis, the viscous stress tensor ${\tau}$ and the heat flux ${q}$ reduce to \begin{equation} \label{def:tau} {\tau}=\mu ({\nabla} {v} + ({\nabla}{v})^\top - \frac{2}{3}({\nabla}\cdot {v}){I}), \quad {q}=-k{\nabla}\mathcal{T}. \end{equation} In \eqref{def:tau} $\mu$ is the dynamic viscosity, $k$ the thermal conductivity and $\mathcal{T}$ the local temperature. In order to solve for the unknowns, the system has to be closed by appropriate equations of state. We choose for the gas constant $R$, the adiabatic exponent $\kappa$ and the specific heat at constant volume $c_v$ the perfect gas law assumptions \begin{equation} p=\rho R \mathcal{T}=(\kappa-1)\rho(e-\frac 1 2 {v}\cdot{v}),\qquad e=\frac{1}{2}{v}\cdot{v} + c_v \mathcal{T}. \end{equation} We augment \eqref{eq:NSE} with suitable boundary and initial conditions, denoted by \begin{align*} B(U) = g \quad \forall~ (x,y) \in \partial D \times \Xi, \quad U(0,x,y)=U^0(x,y) \quad \forall ~(x,y) \in D \times \Xi. \end{align*} The boundary operator $B$, the boundary data $g$ and the initial condition $U^0$ will be specified when we detail the settings for the numerical experiments in \secref{sec:numerics}. Following \cite{SchwabMishraMLMC} we call $U\in L^2(\Xi;C^1([0,T];L^2(D)))$ a weak random solution of \eqref{eq:NSE}, if it is a weak solution $\tilde{\P}$-a.s. $y \in \Xi$ and a measurable mapping $\Big(\Xi, \mathcal{B}(\Xi)\Big) \ni y \to U(\cdot,\cdot,y) \in \Big(C^1([0,T];L^2(D)), \mathcal{B}\big(C^1([0,T];L^2(D))\big)\Big)$. \subsection{The Runge--Kutta Discontinuous Galerkin Method}\label{sec:DG} We shortly recall the Discontinuous Galerkin (DG) spatial discretization for the initial-boundary value problem \eqref{eq:NSE}, see \cite{HindenlangGassner2012} for more details. To partition the spatial domain we subdivide $D$ into $\nSpace\in \N$ quadrilateral elements $D_m$, $m=1,\ldots, \nSpace$ with $D= \bigcup \limits_{m=1}^{\nSpace} D_m$ and define the mesh size $h:= \max \limits_{m=1,\ldots,\nSpace} h_m$, where $h_m$ is the length of~$D_m$. Moreover, we define $h_{min}:= \min \limits_{m=1,\ldots,\nSpace} h_m$. Furthermore, let us introduce the space of piecewise DG polynomial ansatz and test functions: $ \mathcal{V}_{h}^q := \{ U : D \to \R^{4}~|~ U\big|_{D_m} \in \P_q(D_m; \R^{4}),~\text{for } 1\leq m \leq {\nSpace}\}, $ where $\P_q(D_m; \R^{4})$ is the space of polynomials of degree $q$ on the element $D_m$ and $U\big|_{D_m}$ denotes $U$ restricted to $D_m$. The DG solution $U_h$ is then sought in $\mathcal{V}_{h}^q$, i.e. $U_h(t,\cdot,y) \in \mathcal{V}_{h}^q$, a.e. $(t,y) \in (0,T)\times \Xi$. On each element $D_m$, $m=1,\ldots, \nSpace$ we use tensor products of local one-dimensional Lagrange interpolation polynomials of degree $q$, i.e. \begin{align} U_h(t,x, y) \big|_{D_m} = \sum \limits_{i,j=0}^q U_{i,j}^m(t,y) l_i^m (x_1) l_j^m(x_2). \end{align} The interpolation nodes are chosen to be the Gau{\ss}-Legendre nodes, cf. \cite{HindenlangGassner2012}. We then consider the (spatial) weak form of \eqref{eq:NSE} given by \begin{align}\label{eq:dg} \frac{\partial}{\partial t}\int_{D} & U(t,\cdot,y) \Phi\, ~\mathrm{d}{x} +\oint_{\partial D} (\mathcal{G}(U(t,\cdot,y))-\mathcal{H}(U(t,\cdot,y),{\nabla}_xU(t,\cdot,y)))\Phi\,~\mathrm{d}s \notag \\ & - \int_{D} ({G}(U(t,\cdot,y))-{H}(U(t,\cdot,y),{\nabla}_x U(t,\cdot,y)))\cdot{\nabla}_{x}\Phi\,~ \mathrm{d}{x} =0 \end{align} for a.e. $t \in (0,T)$ and $\tilde{\P}$-a.s. $y \in \Xi$ and for all test functions $\Phi$. Now, using the same discrete space $\mathcal{V}_{h}^q$ for ansatz and test functions in \eqref{eq:dg}, we obtain the semi-discrete DG scheme for $U_h \in L^2(\Xi; C^1([0,T);\mathcal{V}_{h}^q ))$: \begin{align}\label{eq:semiDiscrete} & \frac{\partial}{\partial t}\int_{D} U_h(t,\cdot,y) \Phi_h\,~ \mathrm{d}{x} +\oint_{\partial D} \mathcal{G}_{n}^*(U_h^-(t,\cdot,y),U_h^+(t,\cdot,y))\Phi_h\,~\mathrm{d}s \notag \\ & +\oint_{\partial D} \mathcal{H}^*_n(U_h(t,\cdot,y),{\nabla}_xU_h(t,\cdot,y))\Phi_h\,~\mathrm{d}s - \int_{D} {G}(U_h(t,\cdot,y))\cdot{\nabla}_{x}\Phi_h\,~ \mathrm{d}{x} \notag \\ &+ \int_{D} {H}(U_h(t,\cdot,y),{\nabla}_x U_h(t,\cdot,y))\cdot{\nabla}_{x}\Phi_h\,~ \mathrm{d}{x} =0 \end{align} for all $\Phi_h \in \mathcal{V}_{h}^q $. Here, $\mathcal{G}_{n}^*(U^-,U^+)$ denotes a numerical flux, which depends on values at the grid cell interface from neighboring cells. In this paper, we have chosen the approximate Roe Riemann solver with entropy fix described in \cite{Harten1983}. The viscous fluxes $\mathcal{H}^*_n$ normal to the cell interfaces are approximated by the procedure described by Bassi and Rebay in \cite{BassiRebay1997}. The DG scheme \eqref{eq:semiDiscrete} is then advanced in time by a $(q+1)$-th order Runge--Kutta method \cite{KennedyCarpenterRK} constrained by a CFL type condition of the form \begin{align} \label{def:cfl} \Delta t \leq \min \Big\{ \frac{h_{min}}{\lambda_{max}^c (2q+1)}, \Big(\frac{h_{min}}{\lambda_{max}^v (2q+1)}\Big)^2 \Big\}. \end{align} In \eqref{def:cfl} $\lambda_{max}^c:=\big((|v_1|+c)+(|v_2|+c) \big)$ is an estimate for the absolute value of the largest eigenvalue of the convective flux Jacobian with $c:=\sqrt{\kappa \frac{p}{\rho}}$ being the speed of sound. Moreover, $\lambda_{max}^v:=\Big(\max\Big(\frac{4}{3 \rho},\frac{\kappa}{p}\Big) \frac{\mu}{Pr}\Big)$ is an estimate for the largest eigenvalue of the diffusion matrix of the viscous flux, $Pr= \frac{c_p \mu}{k}$ being the Prandtl number. With this choice the consistency error of the numerical scheme is formally of order $\mathcal{O}(h^{q+1} +\Delta t^{q+1})$. We note that we indicate the numerical solution in the remaining part of this paper by the spatial parameter $h$ only. \section{The $hp$-Multilevel Monte Carlo Method} \label{sec:MLMC} \subsection{Description of the $hp$-MLMC Method} In this section we introduce the $hp$-MLMC method, based on the classical MLMC method from \cite{Giles2008}. For levels $l=0,\ldots,L$, we consider spatial meshes with $N_l\in \N$ elements and ansatz spaces of polynomial degree $q_l\in \N$. We choose the number of elements $N_l$ and the DG polynomial degrees $q_l$, such that $N_0<\cdots<N_L$ and $q_0<\cdots<q_L$ holds, i.e., we simultaneously increase the mesh size and the DG polynomial degree. With $\mathcal{V}_{h_l}^{q_l}$ we denote the DG polynomial space corresponding to level $l=0,\ldots,L$ . Moreover, by $U_l(t,\cdot,y):= U_{h_l}(t,\cdot,y) \in \mathcal{V}_{h_l}^{q_l} $ (a.e.~$(t,y)\in (0,T)\times \Xi)$ we denote the DG numerical solution associated with level $l \in \{0,\ldots,L\}$. Additionally, the deterministic numerical solution of \eqref{eq:semiDiscrete} on level $l=0,\ldots,L$ for input parameter $y_i \in \Xi$ is denoted by $U_l^i:=U_l(\cdot,\cdot,y_i)$ and will be called sample for the remaining part of this paper. Since we do not enforce a global CFL time-step restriction across different discretization levels, each sample has to obey the CFL condition \eqref{def:cfl}. Thus, coarser levels admit a bigger time-step than fine levels. We want to emphasize that, in contrast to the MIMC method from \cite{TemponeNobile2016} we index mesh-size and polynomial degree by a single parameter. It is our goal to compute statistical moments like expected value or higher order moments of a general Quantity of Interest (QoI) $Q(U)$ of the random weak solution $U$ of \eqref{eq:NSE}. Precisely, we are interested to determine \begin{align}\label{eq:exactExp} \E{Q(U(t,x,y))} = \int_{\Xi} Q(U(t,x,y)) f_{\xi}(y) \d{y} \end{align} for a.e. $(t,x) \in (0,T)\times D$. Here $Q$ can be an arbitrary nonlinear function or functional of $U$. To ease notation we suppress the dependence of the QoI on $(t,x,y)$ and write $Q(U)$. We approximate \eqref{eq:exactExp} with a Monte Carlo estimator. To this end, we let $\{U_L^i\}_{i=1}^M$ be $M \in \N$ independent, identically distributed samples. The MC estimator for \eqref{eq:exactExp} is then defined by \begin{align} \label{eq:numExp} \EMC{M}{Q(U)} := \frac{1}{M} \sum \limits_{i=1}^{M} Q(U_L^i) \approx \E{Q(U)}. \end{align} Next we advance the MC estimator $\EMC{M}{\cdot}$ to the $hp$-MLMC estimator $\EMLMC{L}{\cdot}$ by using the linearity of the expectation in combination with a telescoping sum. We then write (see \cite{Giles2008}) \begin{align}\label{eq:telescopeSum} \E{Q(U_L)} = \sum \limits_{l=0}^L \E{Q(U_l)-Q(U_{l-1})}, \end{align} where we used the definition $Q(U_{-1})=0$. Now, each term in \eqref{eq:telescopeSum} can be estimated by the MC estimator \eqref{eq:numExp}. If we let $M_l\in \N$ denote a level-dependent number of samples for each level $l=0,\ldots,L$ and assume that the samples $\{Q(U_l^i)\}_{i=1}^{M_l}$, $l=0,\ldots,L$, on different levels are independent from each other, we obtain the $hp$-MLMC estimator via \begin{align* \EMLMC{L}{Q(U_L)} &:= \sum \limits_{l=0}^L \frac{1}{M_l} \sum \limits_{i=1}^{M_l} (Q(U_l^i) - Q(U_{l-1}^i)) = \sum \limits_{l=0}^L \EMC{M_l}{Q(U_l) - Q(U_{l-1})} \\ & \approx \sum \limits_{l=0}^L \E{Q(U_l)-Q(U_{l-1})} = \E{Q(U_L)}\nonumber. \end{align*} Here, $Q(U_l^i)$ and $Q(U_{l-1}^i)$, are computed using the same sample $y_i^l \in \Xi$. The main idea of the MLMC estimator is that the global behavior of the exact expectation can be approximated by the behavior of the expectation of numerical solutions with low resolution, where each sample can be computed with low cost. Thus, $M_l$ is supposed to be large for coarse levels. The coarse-level expectation is then successively corrected by a few computations on finer levels. Each fine-level sample is computationally expensive and therefore, $M_l$ is supposed to be small on fine levels. Hence, the most important aspect for the efficiency of the $hp$-MLMC estimator is the correct choice of $M_l$. In the following section we want to derive the best choice for $M_l$ such that the total work is minimized under the constraint that the spatial and stochastic error satisfy a certain threshold. \subsection{Optimal Number of Samples} For the following analysis we set the QoI to be the solution itself at a fixed point $t\in [0,T]$ in time, i.e. \begin{align} \label{eq:qoi} Q(U)=U(t,\cdot,\cdot). \end{align} We note that our analysis can be analogously performed using any other QoI, including functional ones and suitable norms for $Q$. \begin{remark} We consider the QoI \eqref{eq:qoi} because we are mainly interested in statistical quantities of the solution $U$ itself. However, many other QoIs have a higher regularity than the solution $U$, especially if $Q$ is a functional. Therefore, using such a QoI yields a faster decrease of the variance across different levels, which increases the performance of the MLMC method compared to MC. In \cite[Fig. 10]{abgrallmishra2017} it has been numerically shown that for an uncertain Kelvin-Helmholtz problem the level variance of the solution does not decrease, because upon each mesh refinement additional smaller scale structures are detected. Thus, the MLMC method provides no computational gains compared to the MC method when the QoI is the solution itself. \end{remark} With the help of the following representation of the root mean square error (RMSE) we derive an optimal number of samples $M_l$ for all $l=0, \ldots,L$. \begin{align} \text{RMSE}&:= \| \E{U(t,\cdot,\cdot)}- \EMLMC{L}{U_L(t,\cdot,\cdot)}\|_{L^2(\Xi;\Lp{2}{D})} \leq \epsilon_{\mathrm{det}} + \epsilon_{\mathrm{stat}}. \label{eq:splittingMSE} \\ \epsilon_{\mathrm{det}}&:=\|\E{U(t,\cdot,\cdot)}- \E{U_L(t,\cdot,\cdot)}\|_{\Lp{2}{D}}, \notag \\ \epsilon_{\mathrm{stat}}&:=\|\E{U_L(t,\cdot,\cdot)}- \EMLMC{L}{U_L(t,\cdot,\cdot)}\|_{L^2(\Xi;\Lp{2}{D})}. \notag \end{align} The term $\epsilon_{\mathrm{det}}$ in \eqref{eq:splittingMSE} is the deterministic approximation error (bias). It accounts for the insufficient resolution of the deterministic system. The term $\epsilon_{\mathrm{stat}}$ corresponds to the statistical (sampling) error. Its occurs due to the finite number of samples in \eqref{eq:numExp}. We choose the optimal number of samples $M_l$ to minimize this term. For notational convenience we suppress the explicit dependence on $t\in [0,T]$. Using the independence of the samples, we rewrite the statistical error in \eqref{eq:splittingMSE} (cf. \cite{MuellerJennyMeyerTwoPhase}): \begin{align}\label{eq:statisticalError} \epsilon_{\mathrm{stat}}^2 & = \mathbb{E}\Big [\|\E{U_L}- \EMLMC{L}{U_L}\|_{\Lp{2}{D}}^2 \Big] & \nonumber \\ &= \mathbb{E}\Big [\Big \|\sum \limits_{l=0}^L \E{U_l-U_{l-1}} - \EMC{M_l}{U_l-U_{l-1}}\Big \|_{\Lp{2}{D}}^2\Big]& \nonumber \\ & = \sum \limits_{l=0}^L \frac{1}{M_l^2} \sum \limits_{i=1}^{M_l} \mathbb{E}\Big [\| \E{U_l -U_{l-1}}-(U_l^i - U_{l-1}^i)\|_{\Lp{2}{D}}^2 \Big] & \nonumber \\ & = \sum \limits_{l=0}^L \frac{1}{M_l} \mathbb{E}\Big [\| \E{U_l -U_{l-1}}-(U_l- U_{l-1})\|_{\Lp{2}{D}}^2 \Big] & \nonumber \\ & =: \sum \limits_{l=0}^L \frac{\sigma_l^2}{M_l}. & \end{align} \begin{remark} We use the $\Lp{2}{D}$-norm instead of the $\Lp{1}{D}$-norm for two reasons. First, the $\Lp{1}{D}$-norm is appropriate for inviscid flow problems in one spatial dimension, but we are interested in regular solutions of \eqref{eq:NSE}. Second, using the $\Lp{2}{D}$-norm has the side effect that \eqref{eq:statisticalError} is satisfied as equality (cf. \cite[Sec. 5.2]{MuellerJennyMeyerTwoPhase}). \end{remark} From this representation, the optimal number of samples can be obtained by an error-complexity analysis as in \cite{Giles2008, AppeloeMOMC, MuellerJennyMeyerTwoPhase}. We introduce the total work \begin{align}\label{def:computationalTime} \Wtot:=\Wtot(M_0,\ldots,M_L) := \sum \limits_{l=0}^L M_l w_l , \end{align} where $w_l$ is the work needed to create one sample $U_l^i-U_{l-1}^i$. Following \cite{Giles2008} we obtain the optimal number of samples on different levels by considering the following minimization problem. \begin{align}\label{def:mininmization} \text{For a tolerance } \epsilon>0, \underset{M_0,\ldots,M_L \in \N}{\text{minimize }} \Wtot \text{ under the constraint } \sum \limits_{l=0}^L \frac{\sigma_l^2}{M_l} \leq \frac{1}{4}\epsilon^2. \end{align} The minimization problem can be explicitly solved by (cf. \cite{Giles2008, AppeloeMOMC}) \begin{align} M_l = \bigg\lceil \Big(\frac{\epsilon}{2}\Big)^{-2} \sqrt{\frac{\sigma_l^2}{w_l}}\sum \limits_{k=0}^L \sqrt{\sigma_k^2 w_k} \bigg \rceil. \label{eq:Ml} \end{align} In this work we consider an iterative version of the $hp$-MLMC method, which means that we initialize the algorithm with a number of warm-up samples and then estimate each quantity in \eqref{eq:Ml} during each iteration of the $hp$-MLMC method. In order to keep track of the number of samples that have already been calculated during the iterations of the algorithm we denote this quantity by $M_{\mathrm{tot}_l}$ for each level $l\in \{0,\ldots,L\}$. We want to emphasize, that $M_{\mathrm{tot}_l}$ is not equal to $M_l$, which is the estimated optimal number of samples from \eqref{eq:Ml}. The level variances $\sigma_0^2,\ldots\sigma_L^2$ in \eqref{eq:statisticalError} are not known in general and we therefore estimate the level variance using the unbiased estimator as in \cite{MuellerJennyMeyerTwoPhase}: \begin{align}\label{def:sigmaEstimator} \hat{\sigma}_l^2 := \frac{1}{M_{\mathrm{tot}_l}-1} \sum \limits_{j=1}^{M_{\mathrm{tot}_l}} \int_D \bigg( \Big( \frac{1}{M_{\mathrm{tot}_l}} \sum \limits_{i=1}^{M_{\mathrm{tot}_l}} (U_l^i - U_{l-1}^i)\Big) - (U_l^j - U_{l-1}^j)\bigg)^2~d{x}. \end{align} The work required for the simulation of one sample can vary with an uncertain parameter (e.g. when uncertain viscosity influences the time-step restriction). Moreover, on high performance computing systems, random variations in work can occur between two executions of the same simulation. In order to account for this uncertainty, we estimate the work $w_l$ on level $l=0,\ldots,L$ by the average work per sample $U_l^i$, denoted by $w_l^i$, and define the average work by \begin{align} \label{def:comptimeEstimator} \hat{w_l} := \frac{1}{M_{\mathrm{tot}_l}} \sum \limits_{i=1}^{M_{\mathrm{tot}_l} } w_l^i. \end{align} As a matter of fact, $M_l$ from \eqref{eq:Ml} is also only estimated and we denote the estimator for $M_l$ by $\hat{M_l}$. We have now all ingredients together to state in \algoref{algo:hpMLMC} the classical MLMC algorithm proposed by Giles \cite{Giles2008}. Based on this algorithm we want to discuss several important aspects of the $hp$-MLMC method. First, the complexity of the algorithm will be analyzed in \thmref{thm:complexity}. The choice of the maximum level $L$ will be considered in \rmref{rem:noLevels}. The discussion of the number of warm-up samples $K_0,\ldots, K_L$ (line two in the algorithm), resp. the additional samples (lines six and seven in the algorithm) will be postponed to \secref{sec:confIntervals}, where we derive lower confidence bounds for the optimal number of samples ${M_l}$. \renewcommand{\thealgorithm}{$hp$-\normalfont{MLMC}} \begin{algorithm} \caption{} \begin{algorithmic}[1] {\small \STATE Fix a tolerance $\epsilon>0$, the maximum level $L\in\N $ and set $\cL :=\{ 0,\ldots,L\}$ \STATE Compute $K_l$ (warm-up) samples on level $l=0,\ldots,L$ and set $M_{\mathrm{tot}_l}:=K_l$ \WHILE{$\cL \neq \emptyset$} \FOR{$l\in \cL$} \STATE Estimate $w_l$ by \eqref{def:comptimeEstimator}, $\sigma_l^2$ by \eqref{def:sigmaEstimator} and then ${M_l}$ by \eqref{eq:Ml} \IF{$M_l>M_{\mathrm{tot}_l}$} \STATE{Add $(M_l-M_{\mathrm{tot}_l})$ new samples of $U_l^i- U_{l-1}^i$ and update $M_{\mathrm{tot}_l}$} \ELSE \STATE {Set $\cL:= \cL \setminus \{l\}$} \ENDIF \ENDFOR \ENDWHILE \STATE Compute $\EMLMC{L}{U_L}$ } \end{algorithmic} \label{algo:hpMLMC} \end{algorithm} \subsection{Computational Complexity of the $hp$-MLMC Method} In what follows we use the notation $\tilde{q}_l=q_l+1$ for $l\in \N$.\\ For the analysis of the computational complexity of \algoref{algo:hpMLMC} in \thmref{thm:complexity} below we impose the following assumptions. \begin{enumerate}[label=(A\arabic*),ref=A\arabic*] \item Asymptotic work: \quad $\exists ~\gamma_1 , c_1 >0$ (independent of $h_l, {q}_l$): $w_l\leq c_1 (h_l^{-1}\tilde{q}_l)^{\gamma_1}$ for all $l\in \N$.\label{ass:BoundedCost} \item Bias reduction:\quad $ \exists ~ \kappa_1, c_2 >0$ (independent of $h_l, {q}_l$): $\|\E{U}-\E{U_l}\|_{L^2(D)} \leq c_2 h_l^{\kappa_1 \tilde{q}_l}$ for all $l\in \N$. \label{ass:Biasreduction} \item Variance reduction between two levels: \quad $\exists ~c_3>0$, (independent of $h_l, {q}_l$): $ \sigma_l^2 \leq c_3 h_l^{\kappa_2 \tilde{q}_l}$ for some $\kappa_2>0$ with $\kappa_1 \tilde{q}_0 \geq {\kappa_2 \tilde{q}_0}/{2}$ and for all $l\in \N$. \label{ass:Varreduction} \end{enumerate} \begin{remark} \label{rem:assumptions} \begin{enumerate} \item \assref{ass:BoundedCost} provides a bound for the computational work in terms of the complete number of degrees of freedom on single levels. For the Runge--Kutta Discontinuous Galerkin method in $d=2$ spatial dimensions we have $h_l^{-2}\tilde q_l^{2}$ spatial degrees of freedom. This has to be multiplied with the number of time-steps, which is proportional to $h_l^{-1}\tilde q_l$, or $h_l^{-2}\tilde q_l^{2}$, depending on the minimum in the CFL condition \eqref{def:cfl}. Thus, the total computational work asymptotically equals $\mathcal{O}(h_l^{-3}\tilde q_l^{3})$, resp. $\mathcal{O}(h_l^{-4} \tilde q_l^{4})$. Therefore, we expect the parameter $\gamma_1$ to satisfy $\gamma_1=3$, or $\gamma_1=4$. \item In \assref{ass:Biasreduction} it is stated that the bias, i.e., the deterministic approximation error, converges with the order of the DG method. For smooth solutions the order of convergence is $\mathcal{O}(h_l^{q_l+1})=\mathcal{O}(h_l^{\tilde{q}_l}),$ cf. \cite{ZhangShu2004} and the numerical experiments in \cite{HindenlangGassner2012}. Therefore, we expect $\kappa_1=1$. \item In \assref{ass:Varreduction} we require that the variance decays on all levels similar to the bias term. If we consider regular solutions of a random differential equation, we expect $\kappa_2=2$, cf. the discussion in \cite[p. 25]{Nobile2017}. \end{enumerate} \end{remark} In \thmref{thm:complexity} below we present a complexity bound for the $hp$-MLMC method. This result generalizes \cite[Theorem 1]{CliffeScheichl2011} on $h$-refined and \cite[Theorem 3]{AppeloeMOMC} on $p$-refined meshes to $hp$-refined mesh hierarchies.\\ We distinguish between the two different cases $\kappa_2 \tilde{q}_0 > \gamma_1$ and $\kappa_2 \tilde{q}_0 < \gamma_1$. For the second case $\kappa_2 \tilde{q}_0 <\gamma_1$ we need to define a critical level $L^*\in \N$ such that $\kappa_2 \tilde{q}_{L^*} <\gamma_1 \leq \kappa_2 \tilde{q}_{L^*+1}$. \begin{theorem}[Complexity of the $hp$-MLMC method]\label{thm:complexity} For $\beta \in \N$, and $q_0\geq 0$ let $ \{q_l:= q_0 + \beta l \}_{l\in \N}$ be a sequence of DG polynomial degrees. Additionally, we consider a family of meshes with associated mesh size $h_l=\lambda^{-l}h_0$ for some $h_0 \in (0,1)$ and $\lambda \geq 2$. Let $\mathcal{V}_{h_l}^{q_l}$ be the corresponding DG spaces.\\ Under the assumptions \eqref{ass:BoundedCost} - \eqref{ass:Varreduction}, there exists a constant $c>0$, such that for any tolerance $0<\epsilon<\min \big(1,2c_2 h_0^{\kappa_1 \tilde{q}_0}\big)$, there exists a maximum level $L=L(\epsilon)\in \N$, $L(\epsilon) \geq 2$, and a number of samples $M_l$ on each level $l\in \{0,\ldots,L(\epsilon)\}$, such that the root mean square error from \eqref{eq:splittingMSE} satisfies $\textsc{RMSE} \leq \epsilon$ with the computational complexity \begin{align} \label{complexityestimate} \Wtot\leq \begin{cases} c \epsilon^{-2}, \qquad & \kappa_2 \tilde{q}_0 > \gamma_1, \\ c \epsilon^{\displaystyle -2-\frac{\gamma_1 - \kappa_2 \tilde{q}_0}{\min\{\kappa_1 \tilde{q}_L, \kappa_1 \tilde{q}_{L^*}\}} } , & \kappa_2 \tilde{q}_{0} < \gamma_1. \end{cases} \end{align} \end{theorem} \begin{remark} \begin{enumerate} \item The complexity bound for the case $\kappa_2 \tilde{q}_{0} < \gamma_1$ in \thmref{thm:complexity} suggests that there exists a threshold for the asymptotic complexity scaling like $\mathcal{O}(\epsilon^{-2-\frac{\gamma_1 - \kappa_2 \tilde{q}_0}{ \kappa_1\tilde{q}_{L^*}}})$. With other words, increasing the number of levels $L$ beyond the critical level $L^*$ does not pay off. \item \thmref{thm:complexity} does not include the borderline case $\kappa_2 \tilde{q}_0 = \gamma_1$. Following the analysis in \cite{CliffeScheichl2011} one can make a saturated choice for all sample numbers $M_l$ scaling with the maximum level $L(\epsilon)$. Then a slight variation of Case A in the proof of \thmref{thm:complexity} leads to the total work estimate $W_{\text{tot}} = \mathcal{O}\big(\epsilon^{-2} \log (\epsilon)^2 \big)$. Note that the sample numbers $M_l$ in \thmref{thm:complexity} are chosen for each single level $l$ independent of $L(\epsilon)$ (see e.g.~\eqref{eq:noSamples}). \end{enumerate} \end{remark} \begin{proof}[Proof of \thmref{thm:complexity}] In the proof we determine first a natural number of levels $L=L(\epsilon)\ge 2$ such that the bias term $\epsilon_{\mathrm{det}}$ in \eqref{eq:splittingMSE} is bounded by $\epsilon/2$. Based on this number $L$ we define the sample number $M_l$ for each level $l \in \{0, \ldots, L\}$, and verify that $\epsilon_{\mathrm{stat}}\le \epsilon/2$ and the complexity estimate \eqref{complexityestimate} hold.\\ Using \assref{ass:Biasreduction} on the bias term and the definition of $h_l$ and $q_l$ yields \begin{align}\label{ineq:bias} \epsilon_{\mathrm{det}} = {\|\E{U}- \E{U_L}\|}_{L^2(D)} \leq c_2 h_l^{\kappa_1 \tilde{q}_l} = c_2 (\lambda^{-l}h_0)^{\kappa_1(\tilde{q}_0+ \beta l)} \end{align} To ensure that the latter term is bounded by ${\epsilon}/{2}$ for $l=0,\ldots,L$ it suffices to determine $L$ such that $P(L) \le 0$ holds with \begin{align} \label{ineq:bias2} P(l):= \log(2c_2 \epsilon^{-1}) + \kappa_1(\tilde{q}_0+ \beta l)\big( \log(h_0) - l \log(\lambda) \big). \end{align} The quadratic polynom $P$ is bounded from above and monotone decreasing on $ [0,\infty)$. Since $\epsilon \le 2 c_2 h_0^{\kappa_1 \tilde{q}_0} $ holds we have $P(0) > 0$. Thus, $P$ vanishes for some $\bar L >0 $, and we choose the number of levels to be \begin{align} \label{eq:noLevels} L=L(\epsilon)=\max\{\left \lceil{\bar L}\right \rceil,2\}. \end{align} We proceed considering the two different cases in \eqref{complexityestimate}. \textbf{Case A: $\kappa_2 \tilde{q}_0 > \gamma_1$ }\\ We recall the definition of $S$ from Lemma \ref{lemma:sum} and set $S_0:= h_0^{-\gamma_1/2}S(h_0^{\kappa_2/2}, \lceil \gamma_1/2 \rceil,\tilde{q}_0 )$. Then we choose the number of samples on levels $l=0,\ldots,L$ to be \begin{align} \label{eq:noSamples} M_l := \Big\lceil 4 \epsilon^{-2} c_3 S_0 h_l^{(\gamma_1 + \kappa_2 \tilde{q}_l)/2} \tilde{q}_l^{-\gamma_1/2} \Big\rceil. \end{align} Using \eqref{eq:noSamples} and \assref{ass:Varreduction} we obtain for the statistical error \begin{align* \epsilon_{\mathrm{stat}}^2 = \sum \limits_{l=0}^{L} \frac{\sigma_l^2}{M_l} & \leq \frac{1}{4} \epsilon^2 S^{-1}_0 \sum \limits_{l=0}^{L} h_l^{(\kappa_2 \tilde{q}_l-\gamma_1)/2} \tilde{q}_l^{\gamma_1 /2}, \end{align*} which implies by $\kappa_2\tilde{q}_l - \gamma_1> \kappa_2\tilde{q}_0 - \gamma_1 > 0$, Lemma \ref{lemma:sum} and the definition of $S_0$ the desired estimate \begin{equation} \label{ineq:baseEstimate} \epsilon_{\mathrm{stat}}^2 \leq\frac{1}{4} \epsilon^2 S^{-1}_0 \sum \limits_{l=0}^{\infty} h_0^{(\kappa_2 \tilde{q}_l-\gamma_1)/2} \tilde{q}_l^{\gamma_1 /2} \leq \frac{1}{4}\epsilon^2. \end{equation} Next we derive a bound for the total work $\Wtot$, see \eqref{def:computationalTime}. Using \assref{ass:BoundedCost} and the ceiling definition of $M_l$ we obtain \begin{align}\label{ineq:work1} \Wtot \leq c_1 \sum \limits_{l=0}^{L} M_l h_l^{-\gamma_1} \tilde{q}_l^{\gamma_1} \notag & \leq c_1 \Big(4\epsilon^{-2} S_0 c_3 \sum \limits_{l=0}^{L} h_l^{(\kappa_2 \tilde{q}_l - \gamma_1)/2} \tilde{q}_l^{\gamma_1/2} + \sum \limits_{l=0}^{L} h_l^{-\gamma_1} \tilde{q}_l^{\gamma_1} \Big)\\ &=: c_1\big(\text{W}_{\mathrm{tot},1} + \text{W}_{\mathrm{tot},2}\big). \end{align} The term $\text{W}_{\mathrm{tot},1}$ can be shown to be of order $\epsilon^{-2}$ by the same arguments as before. It remains to consider $\text{W}_{\mathrm{tot},2}$. We have obviously \begin{align} \label{ineq:anotherbound} \text{W}_{\mathrm{tot},2} & \leq h_L^{-\gamma_1}\tilde{q}_L^{\gamma_1}(1+L) \leq h_L^{-\gamma_1}\tilde{q}_L^{\gamma_1+1}, \end{align} with the last inequality following from $1+L\leq \tilde{q}_0 + \beta L = \tilde{q}_{L}$. From \eqref{ineq:hL1} in \lemref{lem:help}, which we have moved to the end of this proof, we deduce \begin{align} \label{ineq:hL} h_{L}^{-\gamma_1} \leq (2 c_2\delta^{-1} \epsilon^{-1} )^{\gamma_1/ \kappa_1 \tilde{q}_{0}}. \end{align} On the other hand, using the order bound in \eqref{ineq:hL1} from \lemref{lem:help} and taking the logarithm yields \begin{align* \tilde{q}_{L} \leq \frac{ \log( 2 c_2 \delta^{-1} \epsilon^{-1} ) } {\log(h_0^{-\kappa_1})} = \frac{ \log( 2 c_2 \delta^{-1} ) } {\log(h_0^{-\kappa_1})} + \frac{ \log(\epsilon^{-1}) } {\log(h_0^{-\kappa_1})} =: \hat{c}_1 + \hat{c}_2 \log (\epsilon^{-1}). \end{align*} Thus, $\tilde{q}_{L}$ grows at most logarithmically in $\epsilon^{-1}$. Therefore we find a constant $\hat{c}_3>0$ which is independent of $\epsilon$ and $L$ such that the algebraic estimate \begin{align} \label{ineq:pL} \tilde{q}_{L} \leq \hat{c}_3 \epsilon^{- \frac{2 -\frac{\gamma_1}{\kappa_1 \tilde{q}_0}}{\gamma_1+1} } \end{align} holds. Note that in Case A the term $2 \kappa_1 \tilde{q}_0 -{\gamma_1}$ is positive due to \assref{ass:Varreduction}. Now, using \eqref{ineq:hL} and \eqref{ineq:pL} in \eqref{ineq:anotherbound} yields for some $c>0$ independent of $\epsilon$ the bound \begin{align}\label{eq:secondsumBounded} \text{W}_{\mathrm{tot}} & \leq c \epsilon^{- \frac{\gamma_1}{\kappa_1 \tilde{q}_0}}\epsilon^{-2 + \frac{\gamma_1}{\kappa_1 \tilde{q}_0}} = c \epsilon^{-2}. \end{align} Thus, Case A is proven. \textbf{Case B: $\kappa_2 \tilde{q}_0 < \gamma_1$}\\ Recall the definition of $L^*\in \N$ to be such that $\kappa_2 \tilde{q}_{L^*} <\gamma_1 \le\kappa_2 \tilde{q}_{L^*+1} $. Let us assume first that we have $L^*< L$ with $L$ from \eqref{eq:noLevels}.\\ We choose then the number of samples $M_l$ for $l=0,\ldots, L^*$ according to \begin{align} \label{eq:noSamplesCase2} M_l := \Big\lceil 8 \epsilon^{-2} c_3 h_l^{(\gamma_1 + \kappa_2 \tilde{q}_l)/2} h_{L^*}^{-(\gamma_1- \kappa_2\tilde{q}_0)/2} \big(1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}\big)^{-1} \Big\rceil, \end{align} and for $l=L^*+1,\ldots,L$ by \begin{align} \label{eq:noSamplesCase2_2} M_l := \Big\lceil 8 \epsilon^{-2} c_3 S_* h_l^{(\gamma_1 + \kappa_2 \tilde{q}_l)/2} \tilde{q}_l^{-\gamma_1/2} \Big\rceil. \end{align} Here we used $S_*= S( h_0^{\kappa_2/2}, \lceil \gamma_1/2 \rceil,\tilde{q}_{L^*+1}) $. Let us consider a splitting for the statistical error given by \begin{align} \label{eq:splittingstatistical} \epsilon_{\mathrm{stat}}^2 = \sum \limits_{l=0}^{L} \frac{\sigma_l^2}{M_l} & = \sum \limits_{l=0}^{L^*} \frac{\sigma_l^2}{M_l} + \sum \limits_{l=L^*+1}^{L} \frac{\sigma_l^2}{M_l} =: \epsilon_{\mathrm{stat},1}^2 + \epsilon_{\mathrm{stat},2}^2. \end{align} Using the definition \eqref{eq:noSamplesCase2} of $M_l$ for $l\in \{ 0,\ldots, L^*\}$ we have for the first term \begin{align*} \epsilon_{\mathrm{stat},1}^2 &\leq \frac{1}{8} \epsilon^2 h_{L^*}^{(\gamma_1- \kappa_2\tilde{q}_0)/2} (1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}) \sum \limits_{l=0}^{{L^*}} h_l^{(\kappa_2 \tilde{q}_l-\gamma_1)/2} \\ & \leq \frac{1}{8} \epsilon^2 h_{L^*}^{(\gamma_1- \kappa_2\tilde{q}_0)/2} (1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}) \sum \limits_{l=0}^{L^*} h_l^{(\kappa_2 \tilde{q}_0- \gamma_1)/2}. \end{align*} For the last inequality we used the fact that $h_l^{(\kappa_2 \tilde{q}_l-\gamma_1)/2} <h_l^{(\kappa_2 \tilde{q}_0-\gamma_1)/2}$ holds as long as $0> \kappa_2 \tilde{q}_l-\gamma_1 > \kappa_2 \tilde{q}_0-\gamma_1 $. Next we use $h_l=\lambda^{L^*-l} h_{L^*}$ to get by $\gamma_1-\kappa_2 \tilde{q}_0>0 $ in Case B and $\lambda \geq2$ the estimate \begin{align*} \epsilon_{\mathrm{stat},1}^2 &\leq \frac{1}{8} \epsilon^2 h_{L^*}^{(\gamma_1- \kappa_2\tilde{q}_0)/2} (1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}) \sum \limits_{l=0}^{L^*} (\lambda^{L^*-l} h_{L^*})^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2} \\ \notag & = \frac{1}{8} \epsilon^2 (1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}) \sum \limits_{l=0}^{\infty} {\big(\lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2} \big)}^l \leq \frac{1}{8} \epsilon^2. \notag \end{align*} Since $M_l$ is defined for $l \ge L^* $ (see \eqref{eq:noSamplesCase2_2}) almost as in Case A (see \eqref{eq:noSamples}) (with a level shift expressed in $S_*$) we can apply the same arguments as in Case A to show $\epsilon_{\mathrm{stat},2}^2 \leq \epsilon^2/8$. Thus the splitting \eqref{eq:splittingstatistical} leads to the desired result $\epsilon_{\mathrm{stat}}^2 \leq \epsilon^2/4$ for the complete statistical error. Similarly to the previous splitting \eqref{eq:splittingstatistical} we rewrite the total work as \begin{align} \label{eq:splitsumwork} \Wtot =\sum \limits_{l=0}^{L} M_l w_l= \sum \limits_{l=0}^{L^*} M_l w_l + \sum \limits_{l=L^*+1}^{L} M_l w_l =: \text{W}_{\mathrm{tot},1} + \text{W}_{\mathrm{tot},2}. \end{align} The definition of $M_l$ in \eqref{eq:noSamplesCase2} implies \begin{align*} \text{W}_{\mathrm{tot},1} &\leq c_1 \sum \limits_{l=0}^{L^*} \Big(8 \epsilon^{-2} c_3 h_l^{(\gamma_1 + \kappa_2 \tilde{q}_l)/2} h_{L^*}^{-(\gamma_1- \kappa_2\tilde{q}_0)/2} \Big(1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}\Big)^{-1} +1\Big) h_l^{-\gamma_1} \tilde{q}_l^{\gamma_1} \\\notag &=:c_1 ( \text{W}_{\mathrm{tot},11} + \text{W}_{\mathrm{tot},12} ). \end{align*} Starting with $ \text{W}_{\mathrm{tot},11}$ we use the definitions of $h_l, q_l$ and estimate \begin{align*} \text{W}_{\mathrm{tot},11} &\leq 8 c_3 \epsilon^{-2} h_{L^*}^{-(\gamma_1- \kappa_2\tilde{q}_0)/2} \Big(1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}\Big)^{-1} \sum \limits_{l=0}^{L^*} (\lambda^l h_{L^*})^{-(\gamma_1- \kappa_2 \tilde{q}_0)/2} \tilde{q}_l^{\gamma_1} \\ & < 8 c_3 \epsilon^{-2} h_{L^*}^{-(\gamma_1- \kappa_2 \tilde{q}_0)} \Big(1- \lambda^{-(\gamma_1-\kappa_2 \tilde{q}_0)/2)}\Big)^{-1} \sum \limits_{l=0}^{\infty} (\lambda^{-(\gamma_1- \kappa_2 \tilde{q}_0)/2})^l (\tilde{q}_0+\beta l)^{\gamma_1}. \end{align*} Being in Case B and the condition $\lambda\geq2$ ensures the existence of the infinite sum such that we are led for some $c>0$ by \eqref{ineq:hL_2} in \lemref{lem:help} to \begin{align} \label{Wtot11} \text{W}_{\mathrm{tot},11} \leq c \epsilon^{-2-\frac{\gamma_1 - \kappa_2 \tilde{q}_0}{\kappa_1 \tilde{q}_{L^*}}}. \end{align} Advancing to the total work contribution $\text{W}_{\mathrm{tot},12}$ we estimate \begin{align*} \text{W}_{\mathrm{tot},12} = \sum \limits_{l=0}^{L^*} h_l^{-\gamma_1} \tilde{q}_l^{\gamma_1} \leq h_{L^*}^{-\gamma_1}\tilde{q}_{L^*}^{\gamma_1} (1+ L^*) \leq h_{L^*}^{-\gamma_1}\tilde{q}_{L^*}^{\gamma_1+1}. \end{align*} By the same arguments employed to derive \eqref{ineq:pL} in Case A, but using \eqref{ineq:hL_2} from \lemref{lem:help} instead, we find a constant $\hat{c}_4>0$ such that \begin{align} \label{ineq:pL2} \tilde{q}_{L^*} \leq \hat{c}_4 \epsilon^{\frac{-2 + \frac{\kappa_2 \tilde{q}_0} {\kappa_1 \tilde{q}_{L^*}}}{\gamma_1+1} } \end{align} holds. In this case we need $\kappa_1 \tilde{q}_{L^*} > {\kappa_2 \tilde{q}_0}/{2}$, which follows from \assref{ass:Varreduction} because $\kappa_1 \tilde{q}_{L^*} > \kappa_1 \tilde{q}_{0} \geq {\kappa_2 \tilde{q}_0}/{2}$. Altogether we end up with \begin{align*} \text{W}_{\mathrm{tot},12} \leq h_{L^*}^{-\gamma_1}\tilde{q}_{L^*}^{\gamma_1+1} \leq c \epsilon^{-2-\frac{\gamma_1 - \kappa_2 \tilde{q}_0}{\kappa_1 \tilde{q}_{L^*}}}, \end{align*} which yields with \eqref{Wtot11} the desired bound for $\text{W}_{\mathrm{tot},1} $ in \eqref{eq:splitsumwork}.\\ For the second term $\text{W}_{\mathrm{tot},2} $ in \eqref{eq:splitsumwork} we use an index shift and apply the same arguments which we have used for Case A with $\kappa_2 \tilde{q}_0 > \gamma_1$. We then obtain \begin{align*} \text{W}_{\mathrm{tot},2} \leq c \epsilon^{-2} \leq c \epsilon^{-2-\frac{\gamma_1 - \kappa_2 \tilde{q}_0}{\kappa_1 \tilde{q}_{L^*} }}, \end{align*} which concludes the proof of the theorem for Case B and $L^*<L$.\\ It remains to consider $L\leq L^*$. Then one defines $M_l$ for $l=1,\ldots,L$ like in \eqref{eq:noSamplesCase2} and gets for the statistical error and for the total work only the first sums in \eqref{eq:splittingstatistical}, \eqref{eq:splitsumwork}, respectively. Exactly the same estimates imply the results for the statistical error and lead to \begin{align*} \text{W}_{\mathrm{tot}} \leq c \epsilon^{ -2-\frac{\gamma_1 - \kappa_2 \tilde{q}_0}{\kappa_1 \tilde{q}_L }}, \end{align*} which concludes the proof. \end{proof} Two auxiliary lemmas have been used in the proof of \thmref{thm:complexity}. The first result refers to the convergence of some series and is taken from \cite{AppeloeMOMC}. \begin{lemma}\cite[Lemma 5.1]{AppeloeMOMC} \label{lemma:sum} For integers $p,q\geq 1$, there are numbers $d_1,\ldots,d_p \in \R$ such that we have for $r\in (0,1)$ \begin{align} \label{eq:finitesum} \sum \limits_{l=0}^\infty r^{({q}+ \beta l)}({q}+ \beta l)^p = S(r,p,q) \end{align} with \begin{equation} \label{defS} S(r,p,q) = \sum \limits_{k=1}^{p} d_k r^k f^{(k)}(r), \quad f(r) = \frac{r^{{q}}}{1-r^{\beta}}. \end{equation} \end{lemma} The second lemma establishes estimates on $\epsilon$ exploiting the exact definition of $L$. \begin{lemma} \label{lem:help} Let the assumptions from \thmref{thm:complexity} be valid. Let $L\in \N$, $L\ge2$, be given as in \eqref{eq:noLevels}. Then, there exists a constant $\delta>0$ independent of $\epsilon$, such that the following inequality holds. \begin{align} \label{ineq:hL1} & \frac{\epsilon}{2} \delta \leq c_2\min \big\{ h_L^{\kappa_1 \tilde{q}_0}, h_0^{\kappa_1 \tilde{q}_L} \big\} \end{align} Moreover, for $L^* \in \N$ satisfying $ L^*< L$, we have the estimate \begin{align} \label{ineq:hL_2} & \frac{\epsilon}{2} \leq c_2 \min \big\{ h_{L^*}^{\kappa_1\tilde{q}_{0}}, h_{0}^{\kappa_1\tilde{q}_{L^*}} \big\}. \end{align} \end{lemma} \begin{proof} A straightforward calculation yields \begin{align*} h_{L}^{\kappa_1 \tilde{q}_{L}} & = (\lambda^{-1} h_{L-1})^{\kappa_1(\tilde{q}_{L-1}+\beta)} \\ & = h_{L-1}^{\kappa_1 \tilde{q}_{L-1}} h_{L-1}^{\kappa_1 \beta} \lambda^{- \kappa_1 q_L} \\ & = h_{L-1}^{\kappa_1 \tilde{q}_{L-1}} \lambda^{-(L-1)\kappa_1 \beta} h_0^{\kappa_1 \beta} \lambda^{- \kappa_1 \tilde{q}_0 } \lambda^{- \kappa_1 \beta L} \\ & = h_{L-1}^{\kappa_1 \tilde{q}_{L-1}} \lambda^{\kappa_1 (\beta-\tilde{q}_0)} h_0^{\kappa_1 \beta} \lambda^{-2 L \kappa_1 \beta} \\ & = h_{L-1}^{\kappa_1 \tilde{q}_{L-1}} \delta \lambda^{-2 L \kappa_1 \beta}, \end{align*} where we have set $\delta:=\lambda^{\kappa_1 (\beta-\tilde{q}_0)} h_0^{\kappa_1 \beta}$. Let $\bar L\in (0,\infty)$ be the zero of $P$ as defined in \eqref{ineq:bias2}. For $\bar L\geq 1$ we deduce from $L \ge \bar L \ge L-1 \ge 1$ that \begin{align}\label{eq:boundsError} \frac{\epsilon}{2}\delta \lambda^{-2 L \kappa_1 \beta} \leq c_2 h_{L-1}^{\kappa_1 \tilde{q}_{L-1}} \delta \lambda^{-2 L \kappa_1 \beta} = c_2 h_{L}^{\kappa_1 \tilde{q}_{L}}. \end{align} After rearranging \eqref{eq:boundsError} we obtain \begin{align}\label{eq:somecalc} \frac{\epsilon}{2}\delta \leq c_2 \lambda^{2 \kappa_1 \beta } h_{L}^{ \kappa_1 \tilde{q}_L} & =c_2 \lambda^{2 \kappa_1 \beta L} \lambda^{-L \kappa_1 \tilde{q}_L} h_0^{\kappa_1 \tilde{q}_L} \\ & = c_2\lambda^{2 \kappa_1 \beta L} \lambda^{-L \kappa_1 \tilde{q}_0 } \lambda^{-\kappa_1 \beta L^2 } h_0^{\kappa_1 \tilde{q}_L} \notag \\ & = c_2 \lambda^{\kappa_1 \beta (2L-L^2)} \lambda^{-L \kappa_1 \tilde{q}_0 } h_0^{\kappa_1 \tilde{q}_0} h_0^{\kappa_1 \beta L} \notag. \end{align} Because of $L\geq 2$ it holds that $(2L-L^2)\leq 0$ and thus $\lambda^{\kappa_1 \beta (2L-L^2)} \leq 1$. Furthermore, $ h_0^{\kappa_1 \beta L} \leq 1$ and $\lambda^{-L \kappa_1 \tilde{q}_0 } \leq 1$ which yields altogether \eqref{ineq:hL1}. \\ If $\bar L \in (0,1)$ holds it follows from \eqref{eq:noLevels} that $L=2$ and we calculate \begin{align*} h_{2}^{\kappa_1 \tilde{q}_{2}} & = \lambda^{-2 \kappa_1 \tilde{q}_{2}} h_0^{\kappa_1 (\tilde{q}_0 + 2 \beta)} = \delta h_0^{\kappa_1 \tilde{q}_0}, \end{align*} where we have defined $\delta:= \lambda^{-2 \kappa_1 \tilde{q}_{2}} h_0^{ 2 \kappa_1 \beta}$. Finally, \eqref{ineq:hL1} follows from the fact that $c_2 h_0^{\kappa_1 \tilde{q}_0} \geq \frac{\epsilon}{2}$. The estimate \eqref{ineq:hL_2} for $L^* < L$ follows from \begin{align*} c_2 h_{L^*}^{\kappa_1\tilde{q}_{L^*}} \geq c_2 h_{L-1}^{\kappa_1\tilde{q}_{L-1}} \geq \frac{\epsilon}{2}. \end{align*} \end{proof} \begin{remark} [Choice of the maximum level] \label{rem:noLevels} The number of levels $L$ in \algoref{algo:hpMLMC} can be computed a priori using \eqref{eq:noLevels}. It is also possible to compute $L$ on the fly. To this end we consider, similarly as in \cite{Giles2008,AppeloeMOMC}, \begin{flalign*} \|\E{U}- \E{U_L}\|_{L^2(D)} &= \Big\|\sum \limits_{l=L+1}^\infty(\E{U_l}- \E{U_{l-1}})\Big\|_{L^2(D)} \\ &\leq \|\E{U_L}- \E{U_{L-1}}\|_{L^2(D)} \sum \limits_{l=L+1}^\infty \frac{\|\E{U_l}- \E{U_{l-1}} \|_{L^2(D)}}{\|\E{U_L}- \E{U_{L-1}}\|_{L^2(D)}} \\ &\leq \|\E{U_L}- \E{U_{L-1}}\|_{L^2(D)} \sum \limits_{l=1}^\infty (\lambda^{-\kappa_1 \tilde{q}_0} h_0^{\kappa_1 \beta})^l \\ & = \|\E{U_L}- \E{U_{L-1}}\|_{L^2(D)} \frac{\lambda^{-\kappa_1 \tilde{q}_0} h_0^{\kappa_1 \beta}}{1-(\lambda^{-\kappa_1 \tilde{q}_0} h_0^{\kappa_1 \beta})}, \end{flalign*} where we have used \assref{ass:Biasreduction}. Therefore, the condition for adding new levels becomes \begin{align} \label{eq:addLevel} \max \limits_{j\in \{0,1,2\}} \frac{(\lambda^{-\kappa_1 \tilde{q}_0} h_0^{\kappa_1 \beta})^{(j+1)}}{1-(\lambda^{-\kappa_1 \tilde{q}_0} h_0^{\kappa_1 \beta})} \|\E{U_{L-j}}- \E{U_{L-j-1}}\|_{L^2(D)} \leq \frac{1}{2} \epsilon. \end{align} This criterion ensures that the deterministic error approximated by an extrapolation from the three finest meshes is within the desired range, cf. \cite{AppeloeMOMC}. \end{remark} \subsection{Confidence Intervals for the Number of Additional Samples} \label{sec:confIntervals} In this section we discuss the computation of the optimal number of samples $M_l$ based on confidence intervals, having in mind the use of queue-based HPC systems. In most modern large-scale computing systems, access to compute nodes is based on job schedulers. For the execution of a job, a certain number of nodes can be requested for a specified time slot. The job is executed after some queuing time, which can be much longer than the actual job execution time. In the context of $hp$-MLMC, it is advisable to submit a new job to the queue for each iteration of \algoref{algo:hpMLMC}, since otherwise idle times of the compute nodes are very difficult to avoid. As each iteration requires its own queuing time, it is our aim to compute as many new samples as possible during one iteration of \algoref{algo:hpMLMC}. On the other hand, we want to avoid computing more samples than optimal, as this would decrease the efficiency of the $hp$-MLMC method and from an economical point of view wasted computing time is expensive. In that sense, one is facing two competing issues, namely either to reduce queuing time by computing as many samples as possible per iteration or to reduce the number of unnecessarily computed samples, i.e. saving computing time. A straightforward approach to satisfy the first issue is to rely on the standard estimator $\hat{M}_l$. However, this approach contradicts the second aim of saving computing time. Let us recall that the quantities $w_l$ and $\sigma_l$ in \eqref{eq:statisticalError} and \eqref{def:computationalTime} are not known exactly but are estimated by $\hat{w}_l,\hat{\sigma}_l$. In most cases the number of samples in the warm-up phase and after the first iteration of the $hp$-MLMC algorithm is too small to obtain a reliable estimate $\hat{M}_l$ of the optimal number of samples $M_l$. This wrong estimate may then lead to an severe overestimation of ${M}_l$ (see for example \figref{fig:mloptmin_a}) and thus spoils the goal of avoiding the computation of unnecessary samples and saving computing time. In order to satisfy the second goal of saving computing time, we want to properly account for the fact that $M_l$ is only estimated by constructing a confidence interval for $M_l$. More specifically, we want to construct a one-sided confidence interval $\I_{{M}_l}= [\underline{{M}_l},\infty)$, such that $\P(M_l \in \I_{{M}_l})\ge 1-\alpha $. To obtain the desired confidence interval we construct corresponding one-sided confidence intervals for $\sigma_l$, $w_l$ denoted by $\I_{\underline{\sigma_l}}= [\underline{\sigma_l},\infty), \quad\I_{\underline{w_l}}=[\underline{w_l},\infty),\quad \I_{\overline{w_l}}=(-\infty,\overline{w_l}],$ respectively. As we do not have any information about the underlying distributions of $\sigma_l$ and $w_l$ we construct the confidence interval based on asymptotic confidence intervals and hence our approach is heuristic because the Central Limit Theorem implies that the number of samples needs to be sufficiently large to ensure that the estimators are asymptotically normally distributed. This seems to be a contradiction to the fact that we choose a small number of samples for the warm-up phase. However, we show in estimate \eqref{ineq:probEst} that our construction of the confidence interval is very conservative and yields a robust lower estimate on the optimal number of samples, although the number of warm-up samples scales like $\mathcal{O}(1)$. Indeed, we never overestimated the optimal number of samples in our computations, justifying our approach. For the construction of the confidence interval for $\sigma_l$ we use the method described in \cite[Formula (6)]{banik2014}, which employs an adjustment to the degrees of freedom of the $\chi^2$-distribution. More precisely, we let \begin{align*} &\hat{r}_l:=\frac{2 M_{\mathrm{tot}_l} }{\hat{\gamma}_{e_l}+ \big(\frac{2M_{\mathrm{tot}_l}}{M_{\mathrm{tot}_l}-1}\big)}, \\ &\hat{\gamma}_{e_l} = \frac{M_{\mathrm{tot}_l}(M_{\mathrm{tot}_l}+1)}{(M_{\mathrm{tot}_l}-1)(M_{\mathrm{tot}_l}-2)(M_{\mathrm{tot}_l}-3)} \frac{\hat{\mu}_l^4}{\hat{\sigma}_l^4} - \frac{3(M_{\mathrm{tot}_l}-1)^2}{(M_{\mathrm{tot}_l}-2)(M_{\mathrm{tot}_l}-3)}, \end{align*} where $ \hat{\mu}_l^4 := \| \sum \limits_{i=1}^{M_{\mathrm{tot}_l}} \Big((U_l^i-U_{l-1}^i)-\frac{1}{M_{\mathrm{tot}_l}} \sum \limits_{j=1}^{M_{\mathrm{tot}_l}} (U_l^j-U_{l-1}^j) \Big)^4\|_{L^2(D)}$. For the lower confidence interval $\I_{\underline{\sigma_l}}= [\underline{\sigma_l},\infty)$ we therefore define \begin{align} \label{eq:confSigma} \underline{\sigma_l}:=\sqrt{\frac{\hat{r}_l \hat{\sigma}_l^2}{\chi_{1-\frac{\alpha}{2},\hat{r}_l}^2}}, \end{align} where for some $\alpha \in (0,1)$, $\chi_{1-\frac{\alpha}{2},\hat{r}_l}^2$ is the $(1-\frac{\alpha}{2})$-quantile of the $\chi^2$-distribution for $\hat{r}_l$ degrees of freedom. If the random samples are normally distributed, it follows that $\hat{\gamma}_{e_l}=0$ and thus $\hat{r}_l=M_{\mathrm{tot}_l}-1$, i.e. we obtain the standard confidence interval for the variance of a normal distribution (cf. \cite{banik2014}). For $w_l$ we compute the confidence interval using the standard asymptotic confidence interval for the mean, i.e. \begin{align} \label{eq:confW} \underline{w_l}:=\hat{w}_l- z_{1-\frac{\alpha}{2}} \frac{\hat{\sigma}_{w_l}}{\sqrt{M_{\mathrm{tot}_l}}}, \quad \overline {w_l} := \hat{w}_l+ z_{1-\frac{\alpha}{2}} \frac{\hat{\sigma}_{w_l}}{\sqrt{M_{\mathrm{tot}_l}}}, \end{align} where $z_{1-\frac{\alpha}{2}}$ is the $(1-\frac{\alpha}{2})$-quantile of the normal distribution and $\hat{\sigma}_{w_l}^2$ is the unbiased estimator for the variance of $w_l$. We then define \begin{align} \label{eq:Mloptmin} \underline{{M}_l} = \frac{1}{\epsilon^2}\frac{\underline{\sigma_l}}{\sqrt{\overline{w_l}}} \left( \sum \limits_{k=0}^{L} \underline{\sigma_k}\sqrt{\underline{w_k}} \right) \end{align} and the confidence interval $\I_{\underline{M_l}}:=[\underline{{M}_l} , \infty)$. Moreover, for $l=0,\ldots,L$ we define the events \begin{align*} X_l &:=\{M_l \in \I_{\underline{M_l}} \}, \Sigma_{\epsilon,l,\text{lower}} :=\Big\{ \frac{1}{\epsilon^2}\sigma_l \in \I_{\frac{1}{\epsilon^2}\underline{\sigma_l}} \Big\}, \Sigma_{l,\text{lower}} :=\{\sigma_l \in \I_{\underline{\sigma_l}} \}, \\ W_{l,\text{lower}} &:=\{\sqrt{w_l} \in \I_{\underline{\sqrt{w_l}}} \}, W_{l,\text{upper}} :=\{\sqrt{w_l} \in \I_{\overline{\sqrt{w_l}}}\}. \end{align*} It then follows that $Y_l \subseteq X_l$, with $ Y_l := \bigcap \limits_{k=0}^{L} \Big( \Sigma_{k,\text{lower}} \cap W_{k,\text{lower}} \cap W_{l,\text{upper}} \cap \Sigma_{\epsilon,l,\text{lower}} \Big), $ for all $l=0,\ldots,L$. Using elementary probability estimates and De Morgan's rule we estimate \begin{align} \label{ineq:probEst} \P(X_l) \geq \P(Y_l) =& 1- \P(Y_l^c) \notag \\ \geq& 1- \sum \limits_{k=0}^L \Big( (\P(\Sigma_{k,\text{lower}}^c) + \P(W_{k,\text{lower}}^c ) + \P(W_{l,\text{upper}}^c) + \P(\Sigma_{\epsilon,l,\text{lower}}^c ) \Big). \end{align} We construct the confidence intervals $\I_{\underline{\sigma_k}}= [\underline{\sigma_k},\infty)$, $\I_{\underline{\sqrt{w_k}}}=[\underline{\sqrt{w_k}},\infty)$ and $\I_{\overline{\sqrt{w_l}}}=(-\infty,\overline{\sqrt{w_l}}]$ such that $$ \P(\Sigma_{\epsilon,l,\text{lower}} )=\P (\Sigma_{k,\text{lower}})= \P (W_{k,\text{lower}})=\P (W_{l,\text{upper}})= 1- \frac{\alpha}{4L}.$$ This choice yields $\P(X_l) \geq 1-\alpha,$ for all $l=0,\ldots,L$. Whereas the lower confidence bound $\underline{M_l}$ helps in saving computing time, it increases the number of queuing operations. Therefore, in order to balance the two competing issues of either reducing queuing time or saving computing time we introduce the parameter $\zeta \in [0,1]$ and let \begin{align} \label{eq:choiceMl} \tilde{M}_l := \zeta \underline{M_l} + (1-\zeta) \hat{M}_l. \end{align} By setting $\zeta=0$ we pursue the aim of reducing queuing time and by setting $\zeta=1$ we try to save computing time. Choosing $\zeta \in (0,1)$ corresponds to finding a strategy in between. We choose $\zeta$ adaptively for each iteration of \algoref{algo:hpMLMC} and for each level $l=0,\ldots,L$. Hence, for each level $l=0,\ldots,L,$ $\zeta= \zeta_l^{\mathrm{iter}_l}$ has its own iteration counter $\mathrm{iter}_l$. We choose the following strategy which tries to realize a trade-off between reducing queuing time and saving computing time: \begin{align} \label{def:caseszeta} \zeta_l^{\mathrm{iter}_l}= \begin{cases} 1, \quad &\text{ for } \mathrm{iter}_l=1, \\ 0.5, \quad &\text{ for } \mathrm{iter}_l= 2 , \\ 0, \quad & \text{ for } \mathrm{iter}_l> 2 .\\ \end{cases} \end{align} \begin{algorithm} \caption{} \begin{algorithmic}[1] {\small \STATE Fix a tolerance $\epsilon>0$, set $L=2$ and set $\cL :=\{ 0,\ldots,L\}$ \STATE Compute $K_l$ (warm-up) samples on $l=0,\ldots,L$, set $M_{\mathrm{tot}_l}:=K_l$ and $\mathrm{iter}_l=1$ \WHILE{$\cL \neq \emptyset$} \FOR{$l\in \cL$} \STATE Estimate $\hat{w}_l$ by \eqref{def:comptimeEstimator}, $\hat{\sigma}_l^2$ by \eqref{def:sigmaEstimator} and then $\hat{M}_l$ by \eqref{eq:Ml} \STATE Estimate $\underline{w_l}$, $\overline{w_l}$ by \eqref{eq:confW}, $\underline{\sigma_l^2}$ by \eqref{eq:confSigma} and then $\underline{M_l}$ by \eqref{eq:Mloptmin} \IF{$M_{\mathrm{tot}_l}<\hat{M}_l$} \STATE{Set $\zeta_l^{\mathrm{iter}_l}$ according to \eqref{def:caseszeta} and compute $\tilde{M_l}$ by \eqref{eq:choiceMl} } \STATE{Add $\big\lceil\tilde{M_l}- M_{\mathrm{tot}_l}\big\rceil$ new samples of $U_l^i- U_{l-1}^i$ } \STATE{Set $M_{\mathrm{tot}_l}:=M_{\mathrm{tot}_l} + \big\lceil\tilde{M_l}- M_{\mathrm{tot}_l}\big\rceil$} \STATE{Set $\mathrm{iter}_l:=\mathrm{iter}_l+1$ } \ELSE{} \STATE{Set $\mathrm{iter}_l:=\mathrm{iter}_l+1$ } \STATE{Skip level $l$} \ENDIF \ENDFOR \IF{ the statistical tolerance \eqref{def:mininmization} is satisfied } \IF{ the bias term satisfies \eqref{eq:addLevel} } \STATE{Set $\cL:=\emptyset$} \ELSE{} \STATE{Set $\cL:=\cL \cup \{L+1\}$} \STATE{Compute $K_{L+1}$ (warm-up) samples and set $M_{\mathrm{tot}_{L+1}}:=K_{L+1}$} \STATE Set $\mathrm{iter}_{L+1}=1$ \STATE Set $L:=L+1$ \ENDIF \ENDIF \ENDWHILE \STATE Compute $\EMLMC{L}{U_L}$ } \end{algorithmic} \label{algo:hpMLMCConfInterval} \end{algorithm} In the first iteration we rely on the lower confidence bound $\underline{M_l}$ from \eqref{eq:Mloptmin} to avoid overestimating $M_l$. In the second iteration we start to approach $\hat{M}_l$ but still consider $\underline{M_l}$ as a safe-guard for overestimating $M_l$. After the second iteration, where $M_{\mathrm{tot}_l}$ is sufficiently large, we trust the estimate $\hat{M}_l$. It might happen that during the first two iterations we have $\underline{M_l}\leq M_{\mathrm{tot}_l} < \hat{M}_l$. In that case we set $\zeta_l^{\text{iter}_l} =0$. The modified $hp$-MLMC method which adds new levels adaptively based on the bias estimate \eqref{eq:addLevel}, is summarized in \algoref{algo:hpMLMCConfInterval}. For the number of warm-up samples $K_l$ we typically choose ten to one hundred samples on the coarse levels and three samples on the fine levels. When we add a new level we set the number of warm-up samples also equal to three. \renewcommand{\thealgorithm}{$hp$-\normalfont{MLMC} with confidence intervals} \section{Numerical Experiments} \label{sec:numerics} We present numerical results for the $hp$-MLMC method as introduced in \algoref{algo:hpMLMCConfInterval}. In \secref{exp:smooth}, we apply the $h$-, $p$-, $hp$-MLMC method to a smooth benchmark problem to verify \thmref{thm:complexity}. In \secref{exp:cavity}, we apply the $h$-, $p$- and $hp$-MLMC method to an open cavity flow problem, an important flow problem from computational acoustics. We give a detailed comparison of all methods and verify that for both problems, $h$-, $p$- and $hp$-MLMC yield an optimal asymptotic work. This shows that all three methods under consideration are applicable for UQ of complex engineering problems in computational fluid dynamics. The computations for the second numerical experiment were performed on Cray XC40 at the High-Performance Computing Center Stuttgart. The numerical solver relies on the Discontinuous Galerkin Spectral Element solver FLEXI \cite{HindenlangGassner2012}. The time-stepping uses a Runge--Kutta method of order four. \subsection{Smooth Benchmark Solution} \label{exp:smooth} In this numerical example we verify \thmref{thm:complexity} by means of a smooth manufactured solution, given by \begin{align} \label{eq:smoothnse} \begin{pmatrix} \rho(t,x_1,x_2,y) \\ (\rho v_1)(t,x_1,x_2,y)\\(\rho v_2)(t,x_1,x_2,y)\\E(t,x_1,x_2,y)) \end{pmatrix}= \begin{pmatrix} 2 + A \sin(4 \pi (( x_1+x_2)- ft )) \\ 2 + A \sin(4 \pi (( x_1+x_2)- f t )) \\ 2 + A \sin(4 \pi (( x_1+x_2)- f t )) \\ \big(2 + A \sin(4 \pi (( x_1+x_2)- f t )) \big)^2 \end{pmatrix}. \end{align} The benchmark solution \eqref{eq:smoothnse} is obtained by introducing an additional source term in \eqref{eq:NSE}. We choose the amplitude and frequency of \eqref{eq:smoothnse} to be uncertain, i.e.~we let $A \sim \mathcal{U}(0.1,0.9)$ and $\ensuremath{f} \sim \mathcal{N}(1,0.05^2)$. The spatial domain is $D = (-1,1)^2$ and we consider periodic boundary conditions. The setup of the mesh hierarchies for $h$-MLMC, $p$-MLMC and $hp$-MLMC can be found in \tabref{tab:smoothSetup}. The final computational time for this example is $T=1$ and the QoI is the momentum in $x_1$-direction at final time $T$, i.e. $Q(U)= (\rho v_1)(T,\cdot,\cdot,\cdot).$ For the confidence intervals from \secref{sec:confIntervals} we set $\alpha$ to be 0.025. \begin{table} \centering \begin{tabular}{cccccccccc} % \toprule \multirow{3}{*}{ \parbox[c]{.2\linewidth}{\centering level}} & \multicolumn{2}{c}{$h$-MLMC} && \multicolumn{2}{c}{$p$-MLMC} && \multicolumn{2}{c}{$hp$-MLMC} \\ \cmidrule{2-3} \cmidrule{5-6} \cmidrule{8-9} & {\centering $N_l$} & {$q_l$} && {$N_l$} & {$q_l$} && {$N_l$} & {$q_l$} \\ \midrule 0 & 16 & 5 && 256 & 3 && 16 & 3 \\ 1 & 64 & 5 && 256 & 4 && 64 & 4 \\ 2 & 256 & 5 && 256 & 5 && 256 & 5 \\ 3 & 1024 & 5 && 256 & 6 && 1024 & 6 \\ \bottomrule \end{tabular} \caption{Level setup for $h$-, $p$- and $hp$-MLMC. Example \ref{exp:smooth}.} \label{tab:smoothSetup} \end{table} In \tikzfigref{fig:smooth_plots_a} we plot the estimated bias, i.e. the quantity $\|\E{U_l}-\E{U_{l-1}}\|_{L^2(D)}$ from \rmref{rem:noLevels}, where the quantities $\E{U_l}$ and $\E{U_{l-1}}$ have been estimated by the standard MC estimator \eqref{eq:numExp}. In \tikzfigref{fig:smooth_plots_b} we plot the bias term vs. $h_l^{\tilde{q}_l}$ in a log-log plot. This allows us to estimate $\kappa_1$ from \assref{ass:Biasreduction} using a linear fit over all data points. For $h$-MLMC, where we consider a DG polynomial degree of five, we estimate $\kappa_1 \approx 0.86$ and this is in accordance with the expected value of one, cf. \rmref{rem:assumptions} 2. On the other hand, the values of $\kappa_1$ for $p$- and $hp$-MLMC are clearly smaller than one. \tikzfigref{fig:smooth_plots_c} shows the estimated level variances $\hat{\sigma}^2_l$ and its 95\% confidence interval. To verify the assumptions of \thmref{thm:complexity} we estimate $\kappa_2$ from \assref{ass:Varreduction} in \tikzfigref{fig:smooth_plots_d} by linearly fitting the last three data points. For $h$-MLMC we estimate $\kappa_2 \approx 1.71$. According to \rmref{rem:assumptions} 3. we expect $\kappa_2 \approx 2$. Again, $p$- and $hp$-MLMC yield distinctively smaller values than two. However, all three methods satisfy $ 2\kappa_1 \geq \kappa_2$ from \assref{ass:Biasreduction}. Next, we check \assref{ass:BoundedCost} for all three methods under consideration, where we estimate the average work using the sample mean from \eqref{def:comptimeEstimator}. Since we expect $\gamma_1=3$ and because DOF$_l$:=$(h_l^{-1}\tilde{q}_l)^2$, the average work should scale as $\hat{w}_l= \mathcal{O}(\text{DOF}_l^{3/2})$ (cf. \rmref{rem:assumptions} 1). This can be observed in \tikzfigref{fig:smooth_work}. Combining the estimate of $\kappa_2$ from \figref{fig:smooth_plots_d} and the fact that $\gamma_1\approx 3$, we compute that $h$-, $p$- and $hp$-MLMC satisfy $\kappa_2 \tilde{q}_0> \gamma_1$ (see the parameters of the coarsest level given in \tabref{tab:smoothSetup}). Therefore, according to \thmref{thm:complexity} all three methods should yield an optimal asymptotic work of $\mathcal{O}(\epsilon^{-2})$, which can be observed in \tikzfigref{fig:smooth_plots_e}. It appears that for this example $h$-MLMC is more efficient than $p$- and $hp$-MLMC. This is probably due to the very good variance reduction across all levels and a similar average work compared to $hp$-MLMC. Finally, we check whether the prescribed tolerance $\epsilon$ is reached by all three methods. To this end we evaluate the statistical error $\epsilon_{\mathrm{stat}}$ by \eqref{def:sigmaEstimator} and compute the deterministic approximation error $\epsilon_{\mathrm{det}}$ using the exact solution \eqref{eq:smoothnse}. Both terms $\epsilon_{\mathrm{det}}$ and $\epsilon_{\mathrm{stat}}$ are then summed up as in \eqref{eq:splittingMSE} and plotted in \tikzfigref{fig:smooth_plots_f}. \begin{figure} \centering \input{smooth_plots.tex} \settikzlabel{fig:smooth_plots_a} \settikzlabel{fig:smooth_plots_b} \settikzlabel{fig:smooth_plots_c} \settikzlabel{fig:smooth_plots_d} \settikzlabel{fig:smooth_plots_e} \settikzlabel{fig:smooth_plots_f} \caption{Estimated bias, variance, tolerance and asymptotic runtime. For $\hat{\sigma}_l^2$ we also plot the 95\% confidence interval. Example \ref{exp:smooth}.} \label{fig:smooth_runtime} \end{figure} The computed number of samples on each level for different tolerances is shown in \figref{fig:smooth_samples}. As expected, we only need a few computations on the fine levels, the majority of the computations is performed on coarse levels. \figref{fig:ldc_mloptmin} illustrates the advantage of computing the lower confidence bound $\underline{M_l}$ from \eqref{eq:Mloptmin}. In this figure we plot the values of $\underline{M_l}$ from \eqref{eq:Mloptmin}, of $\tilde{M}_l$ from \eqref{eq:choiceMl} and of $\hat{M}_l$ from \eqref{eq:Ml}, for each level $l=0,\ldots, 3$, for the first three iterations of \algoref{algo:hpMLMCConfInterval}. For this example we use $hp$-MLMC. In \tikzfigref{fig:mloptmin_a} we observe that relying on the estimate of $\hat{M}_0$ would have led to an overestimate of the optimal number of samples by more than 8000 samples. The same holds for level two (\tikzfigref{fig:mloptmin_b}) where we would have overestimated the optimal number of samples by more than 400. On the other hand, our proposed strategy ensures that we reach the standard estimator $\hat{M}_l$ in (at most) three iterations. This shows in particular the advantage of our approach because we avoid computing unnecessary samples, hence we save computing time, while trying to keep the number of queuing operations low. \begin{figure} \centering \input{smooth_samples.tex} \settikzlabel{fig:smooth_samples_a} \settikzlabel{fig:smooth_samples_b} \settikzlabel{fig:smooth_samples_c} \settikzlabel{fig:smooth_work} \caption{Computed number of samples and average work on each level. Example \ref{exp:smooth}.} \label{fig:smooth_samples} \end{figure} \begin{figure} \centering \input{mloptmin.tex} \settikzlabel{fig:mloptmin_a} \settikzlabel{fig:mloptmin_b} \settikzlabel{fig:mloptmin_c} \settikzlabel{fig:mloptmin_d} \caption{Estimated $\underline{M_l}$, $\hat{M}_l$ and chosen number of samples $\tilde{M}_l$ from \eqref{eq:choiceMl} for different levels for the $hp$-MLMC method. The tolerance in this example is $\epsilon=\expnumber{5}{-4}$. The number of warm-up samples was (100, 10, 3) (Example \ref{exp:smooth}).} \label{fig:ldc_mloptmin} \end{figure} \subsection{Open Cavity}\label{exp:cavity} In this numerical example we investigate the influence of uncertain input parameters on the aeroacoustic feedback of cavity flows as in \cite{Kuhn2018}. The prediction of aeroacoustic noise is an important branch of research for example in the automotive industry. However, due to the large bandwidth of spatial and temporal scales, a high-order numerical scheme with low dissipation and dispersion error is necessary to preserve important small scale information and hence it poses a very challenging numerical problem for UQ. We consider the flow over a two-dimensional open cavity, cf. \figref{fig:cavity_sketch}, using $h$-, $p$- and $hp$-MLMC. For this flow problem we consider two uncertain parameters. The first uncertain parameter is the initial condition for pressure, i.e. we let $p^0 \sim \mathcal{N}(1.8,0.01^2)$ be normally distributed. With this choice the Mach number $\text{Ma}=\frac{v_1}{c}$, with $c=\sqrt{\kappa \frac{p}{\rho}}$ being the speed of sound, becomes uncertain. The initial condition in primitive variables then reads as $$\Big(\rho^0, v_1^0,v_2^0,p^0\Big)= \Big(1,1,0,p^0(y)\Big).$$ As a second uncertain parameter, we let the boundary layer thickness in front of the cavity, $\delta_{99}\sim \mathcal{U}(0.28,0.48)$, be uniformly distributed. For the boundary conditions at the inlet we employ Dirichlet boundary conditions in combination with the precomputed Blasius boundary layer profile. All wall boundaries are modeled as isothermal no-slip walls where the temperature $\mathcal{T}$ is computed from the ideal gas law $p=\rho R \mathcal{T}$, where the gas constant for air satisfies $R=287.058$. At the end of the cavity we consider a pressure outflow boundary condition, where the pressure is specified by the initial pressure. Above the cavity we also consider a pressure outflow boundary condition and we augment the boundary with a sponge zone (cf. \figref{fig:cavity_sketch}) to avoid that artificial reflections reenter the computational domain. Detailed information about the sponge zone can be found in \cite{Kuhn2018}. For our QoI we record the pressure fluctuations $p(t,x,y)$ on top of the cavity at $\bar{x}=(x_1,x_2)=(1.57,0)$ over time and then perform the discrete-time Fourier transform (DTFT) to obtain the sound pressure spectrum at $\bar{x}$, i.e. $Q(U)= \text{DTFT}\Big(p(\cdot,\bar{x},y)\Big).$ The corresponding $L^2$-norm is then taken in frequency space. The mesh hierarchies for $h$-, $p$- and $hp$-MLMC can be found in \tabref{tab:cavitySetup}. For the confidence intervals from \secref{sec:confIntervals} we set $\alpha$ to be 0.025. \begin{table} \centering \begin{tabular}{ccccccccc} % \toprule \multirow{2}{*}{ \parbox[c]{.2\linewidth}{\centering level}} & \multicolumn{2}{c}{$h$-MLMC} && \multicolumn{2}{c}{$p$-MLMC} && \multicolumn{2}{c}{$hp$-MLMC} \\ \cmidrule{2-3} \cmidrule{5-6} \cmidrule{8-9} & {\centering $N_l$} & {$q_l$} && {$N_l$} & {$q_l$} && {$N_l$} & {$q_l$} \\ \midrule 0 & 279 & 7 && 1987 & 4 && 279 & 4 \\ 1 & 423 & 7 && 1987 & 5 && 423 & 5 \\ 2 & 957 & 7 && 1987 & 6 && 957 & 6 \\ 3 & 1987 &7 && 1987 & 7 && 1987 & 7 \\ \bottomrule \end{tabular} \caption{Level setup for $h$-, $p$ and $hp$-MLMC (Example \ref{exp:cavity}).} \label{tab:cavitySetup} \end{table} \begin{figure} \centering \def6.6cm{6.6cm} \input{Cavity_Setup.pdf_tex} \includegraphics[width=5.6cm,height=4.5cm]{mesh.eps} \caption{\textit{Left:} Schematic sketch of the open cavity setup with a laminar inflow boundary layer. All geometric parameters are adopted from \cite{Kuhn2018} and are non-dimensionalized by the cavity depth. \textit{Right:} Computational mesh on the finest level. (Example \ref{exp:cavity}). } \label{fig:cavity_sketch} \end{figure} Considering the bias error we can see that in \tikzfigref{fig:cavity_plots_a} for $p$-MLMC the bias estimate $\|\E{Q(U_l)}-\E{Q(U_{l-1})}\|_{L^2}$ for $p$-MLMC is smaller than $\expnumber{2.5}{-5}$. As all three methods share the same finest level, we can assume that the bias error from \eqref{eq:splittingMSE} is satisfied for all three methods under consideration. \tikzfigref{fig:cavity_plots_b} shows the estimated level variance $\hat{\sigma}_l^2$ across different levels. All three methods yield a very good variance reduction, especially $p$-MLMC has already a very small variance on level two. However, the computation of samples on the coarse grids is extremely costly for $p$-MLMC. Taking a closer look at the variance on level zero, we see that $hp$-MLMC achieves the same variance as $p$-MLMC but with much less DOFs. This yields the computational advantage of $h$- and $hp$-MLMC compared to $p$-MLMC (see \tikzfigref{fig:cavity_plots_c}) for this open cavity problem. The asymptotic work is still optimal for all three methods, which can be seen in \tikzfigref{fig:cavity_plots_c}. Finally, in \figref{fig:cavity_samples} we plot the number of computed samples for different tolerances and the average work that is needed to compute one sample on the corresponding level. Again, for all three methods most of the computations are performed on the coarse levels as they have a low computational cost. In contrast to the benchmark problem the average work does not scale as $ \mathcal{O}(\text{DOF}_l^{3/2})$ but more like $\mathcal{O}(\text{DOF}_l^{2})$, indicating that $\gamma_1\approx 4$. The main reason for this behavior is that the uncertain Mach number influences the time-step size because the speed of sound enters the eigenvalues of the Jacobian of the advective fluxes, hence a bigger pressure leads to a smaller time-step size. \begin{figure} \centering \input{cavity_plots.tex} \settikzlabel{fig:cavity_plots_a} \settikzlabel{fig:cavity_plots_b} \settikzlabel{fig:cavity_plots_c} \settikzlabel{fig:cavity_plots_d} \caption{Estimated bias, variance and asymptotic work. For $\hat{\sigma}_l^2$ we also plot the 95\% confidence interval (Example \ref{exp:cavity}).} \label{fig:cavity_plot} \end{figure} \begin{figure} \centering \input{cavity_samples.tex} \settikzlabel{fig:cavity_samples_a} \settikzlabel{fig:cavity_samples_b} \settikzlabel{fig:cavity_samples_c} \caption{Computed number of samples and average work on each level (Example \ref{exp:cavity}).} \label{fig:cavity_samples} \end{figure} Summarizing the numerical experiments in Sections \ref{exp:smooth} and \ref{exp:cavity} we have seen that $h$-, $p$- and $hp$-MLMC yield an optimal asymptotic runtime and can be used for efficient UQ of the compressible Navier--Stokes equations. However, we also observed that the $hp$-MLMC method does not outperform the $h$-MLMC method, as long as the latter can be applied. Therefore, in order to increase the efficiency of the $hp$-MLMC method future work should aim at fully $hp$-adaptive algorithms as for example in \cite{Detommaso2019,Eigel2016,Kornhuber2018}. \section{Conclusions} In this article we have proposed the $hp$-MLMC method, a Discontinuous Galerkin based Multilevel Monte Carlo method, where different levels consist of a hierarchy of uniformly refined spatial meshes in combination with a hierarchy of uniformly increasing DG polynomial degrees. We generalized the complexity results from \cite{CliffeScheichl2011, AppeloeMOMC} to arbitrarily $hp$-refined meshes. To account for the uncertainty of the optimal number of samples on each level, we introduced a confidence interval, leading to a robust lower confidence bound for these quantities. Our theoretical results are confirmed by numerical experiments for the two-dimensional compressible Navier-Stokes equations, including an extensive comparison between $h$-, $p$- and $hp$-MLMC methods. Finally, we applied our method to a challenging engineering problem from computational acoustics, demonstrating its capability to perform UQ for complex flow problems. In order to improve the efficiency of the $hp$-MLMC method it should be advanced to an $hp$-\textrm{adaptive} method. \vspace*{-0.2cm} \section*{Acknowledgments} The authors thank the anonymous referees and the associate editor for their helpful suggestions to improve the article. \bibliographystyle{siamplain}
\section{Preliminaries}\label{SecPrelim} In order to introduce the Luttinger--Sy model with finite (repulsive) interaction (referred to as LS model in the rest of the paper) one starts with a Poisson point process $X$ on $\mathds{R}$ with intensity $\nu > 0$ on some probability space $(\Omega,\mathcal{F},\mathds{P})$. More explicitly, $\mathds{P}$-almost surely $X(\omega)=\{x_j(\omega): j \in \mathbb{Z}\}$ is a strictly increasing sequence of points (also called atoms) $x_j=x_j(\omega) \in \mathds{R}$ and zero is contained in the interval $(x_0(\omega),x_1(\omega))$. The probability that a given bounded Borel subset $\Lambda \subset \mathds{R}$ contains exactly $m$ points is \begin{align} \mathds{P}\left(\omega:\left|X(\omega)\cap \Lambda)\right|=m\right)=\frac{(\nu|\Lambda|)^m}{m!}\mathrm{e}^{-\nu |\Lambda|}\ , \quad m \in \mathds{N}_0\ . \end{align} Furthermore, for two disjoint Borel sets $\Lambda_1$ and $\Lambda_2$, the events $\{\omega:\left|X(\omega)\cap \Lambda_1)\right|=m_1\}$ and $\{\omega:\left|X(\omega)\cap \Lambda_2)\right|=m_2\}$ are stochastically independent. Note that, depending on the context, $|\cdot|$ refers to the Lebesgue measure or to the counting measure. In a next step one places at each atom $x_j(\omega)$ a $\delta$-distribution of mass $\gamma>0$, also called the interaction strength. The underlying one-particle Hamiltonian is informally given by \begin{align}\label{FullHamiltonianRealLine}\begin{split} \mathrm{h}_{\gamma}(\omega)&:=-\frac{\mathrm{d}^2}{\mathrm{d} x^2}+V_{\gamma}(\omega,\cdot)\ , \end{split} \end{align} with (external) potential \begin{align} V_{\gamma}(\omega,\cdot):=\gamma \sum_{j \in \mathds Z}\delta(\cdot-x_j(\omega))\ . \end{align} Note that a rigorous definition of~\eqref{FullHamiltonianRealLine} can be obtained via the construction of a suitable quadratic form on the Hilbert space $L^2(\mathds{R})$. However, since we are interested in studying BEC, we have to employ a thermodynamic limit which, in particular, means that we have to restrict the one-particle configuration space from $\mathds{R}$ to the bounded interval $\Lambda_N:=(-L_N/2,L_N/2)$ with $L_N:=N/\rho$; here $\rho > 0$ denotes the particle density and $N \in \mathds{N}$ is a scaling parameter (the particle number) which eventually will go to infinity. Consequently, we introduce $\mathrm{h}^{N}_{\gamma}(\omega)$ as the finite-volume version of $\mathrm{h}_{\gamma}(\omega)$, defined on the Hilbert space $L^2(\Lambda_N)$. More explicitly, for all $N$ and $\mathds{P}$-almost all $\omega \in \Omega$, one defines the (quadratic) form \begin{align} q^{N}_{\gamma}(\omega)[\varphi]:=\int\limits_{\Lambda_N}|\varphi^{\prime}(x)|^2\ \mathrm{d} x + \gamma \sum_{j: x_j(\omega) \in \Lambda_N}|\varphi(x_j(\omega))|^2 \end{align} on $L^2(\Lambda_N)$ with (Dirichlet) form domain $H^1_0(\Lambda_N) :=\{\varphi \in L^2(\Lambda_N): \varphi^{\prime} \in L^2(\Lambda_N), \varphi(-L_N/2)$ $ = \varphi(+L_N/2)=0 \}$. This form is positive, densely defined and closed. Hence, due to the representation theorem for quadratic forms, there exists a unique self-adjoint operator associated with this form. Informally, this operator is \begin{align}\label{FormalOperatorLSModel} \mathrm{h}^{N}_{\gamma}(\omega):=-\frac{\mathrm{d}^2}{\mathrm{d} x^2}+\gamma \sum_{j:x_{j}(\omega) \in \Lambda_N}\delta(\cdot-x_j(\omega))\ . \end{align} The spectrum of $\mathrm{h}^{N}_{\gamma}(\omega)$ is $\mathds{P}$-almost surely purely discrete. We write $(E^{j,\omega}_N)_{j=1}^{\infty}$ for the eigenvalues of $\mathrm{h}^{N}_{\gamma}(\omega)$, ordered in increasing order, i.e., $0 < E^{1,\omega}_N < E^{2,\omega}_N < E^{3,\omega}_N < ...$, taking into account that the eigenvalues are $\mathds{P}$-almost surely non-degenerate~\cite{kirsch1985universal}. Also, we denote the eigenfunctions corresponding to $(E^{j,\omega}_N)_{j=1}^{\infty}$ as $(\varphi^{j,\omega}_N)_{j=1}^{\infty} \subset L^2(\Lambda_N)$. We define the integrated density of states $\mathcal{N}^{\mathrm{I},\omega}_{N}:\mathds{R} \rightarrow \mathds{N}_0$ and the density of states (measure\footnote{When we speak of the density of states we always mean the corresponding measure and never the density in the sense of the Radon--Nikodym derivative of this measure with respect to the Lebesgue measure. We do not even know whether the latter exists in this model.}) $\mathcal{N}^{\omega}_{N}$ associated with $\mathrm{h}^{N}_{\gamma}(\omega)$, for $\mathds{P}$-almost all $\omega \in \Omega$ and all $N \in \mathds{N}$, via \begin{align} \label{definition finite volume integrated density of states} \mathcal N_N^{\mathrm{I},\omega}(E) := \int\limits_{(-\infty,E)} \mathcal N_N^{\omega} (\mathrm{d} \tilde{E}) := \dfrac{1}{|\Lambda_N|} \left| \left\{ j : E_N^{j,\omega} < E \right\} \right|\ , \quad E \in \mathds{R}\ . \end{align} Note that $\mathcal N_N^{\mathrm{I},\omega}(\cdot)$ is non-decreasing and left-continuous. In the grand-canonical ensemble, the (mean) number of particles $n_N^{j,\omega}$ occupying the eigenstate $\varphi^{j,\omega}_N$ at inverse temperature $\beta \in (0,\infty)$ is given by \begin{align} n_N^{j,\omega} = \left( \mathrm{e}^{\beta (E_N^{j,\omega} - \mu_N^{\omega})} - 1 \right)^{-1}\ , \end{align} for $\mathds{P}$-almost all $\omega \in \Omega$. Here, $\mu_N^{\omega} \in (-\infty,E^{1,\omega}_{N})$ denotes the chemical potential, see \cite[Section 5.2.5]{BratteliRobinson}, \cite{LanWil79}. The chemical potential $\mu_N^{\omega}$ is such that \begin{align} \label{Gleichung Bedingung mu} \sum_{j=1}^{\infty} n_N^{j,\omega} = N \end{align} holds for $\mathds{P}$-almost all $\omega \in \Omega$ and all $N \in \mathds{N}$. Note that at fixed $\rho$ and $\beta$, $\mu_N^{\omega}$ is uniquely determined. Also, \eqref{Gleichung Bedingung mu} can be written equivalently as \begin{align} \label{Gleichung Bedingung mu aequivalent} \int\limits_{\mathds{R}} \left( \mathrm{e}^{\beta (E - \mu_N^{\omega})} - 1 \right)^{-1} \mathcal N_N^{\omega} (\mathrm{d} E) =\rho\ . \end{align} To simplify notation later on we introduce the Bose function $\mathcal{B}:\mathds R \rightarrow \mathds{R}$, $$\mathcal{B}(E):=\left( \mathrm{e}^{\beta E} - 1 \right)^{-1} \Theta(E) \ , $$ where $\Theta$ is the indicator function on $(0,\infty)$. \begin{defn}[Thermodynamic limit] For fixed $\rho,\beta > 0$, the thermodynamic limit is realized as the limit $N \rightarrow \infty$ together with $L_N:=N/\rho$ and $\mu_N^{\omega}$ such that~\eqref{Gleichung Bedingung mu} holds for $\mathds{P}$-almost all $\omega \in \Omega$ and all $N \in \mathds{N}$. \end{defn} \begin{defn}[Bose--Einstein condensation]\label{Definition makroskopische Besetzung} For fixed $\rho,\beta > 0$, we say that the $j$th eigenstate is $\mathds{P}$-almost surely \textit{macroscopically occupied} (in the thermal equilibrium state characterized by $\rho$ and $\beta$) if % \begin{align} \label{Def m o} \mathds P \left(\omega: \limsup\limits_{N \to \infty} \dfrac{n_N^{j,\omega}}{N} > 0 \right) = 1 \ . \end{align} % Moreover, \textit{generalized BEC} is said to occur $\mathds{P}$-almost surely if an arbitrarily narrow energy interval at the lower edge of the spectrum is $\mathds{P}$-almost surely macroscopically occupied, i.e., if % \begin{align} \mathds P \left(\omega:\lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \dfrac{1}{N} \sum\limits_{j : E_N^{j,\omega}-E_N^{1,\omega} \le \epsilon} n_N^{j,\omega} > 0 \right) = 1 \ . \end{align} % \end{defn} \begin{remarks} \begin{enumerate} \item[(i)] In Definition \ref{Definition makroskopische Besetzung} there is not a single fixed state that is macroscopically occupied but there is a sequence of eigenstates $(\varphi^{j,\omega}_N)_{j=1}^{\infty}$ with the property \eqref{Def m o}. This is a common abuse of language, which we adopt. \item[(ii)] One could argue to call the $j$th eigenstate $\mathds{P}$-almost surely \emph{not} macroscopically occupied if $\mathds{P}$-almost surely $n_N^{j,\omega}/N$ converges to zero as $N\to\infty$ and then the $j$th eigenstate $\mathds{P}$-almost surely macroscopically occupied if $\mathds{P}$-almost surely it does not converge to zero. The latter condition is \eqref{Def m o}. Still it would be nice to replace the limit superior in~\eqref{Def m o} by the limit inferior or the limit if it existed. In any case, our result implies that $\mathds{P}$-almost surely for some subsequence of intervals the fraction of particles occupying the ground state converges to some (strictly) positive value. \item[(iii)] One may replace the $\mathds P$-almost sure property in \eqref{Def m o} by the condition that the expectation $\mathds E[n_N^{j,\omega}/N]$ is strictly positive, uniformly in $N$. See Remark \ref{remark 3.6}. \end{enumerate} \end{remarks} From Definition~\ref{Definition makroskopische Besetzung} it is clear that a $\mathds{P}$-almost sure macroscopic occupation of the one-particle ground state implies $\mathds{P}$-almost sure generalized BEC. However, the converse does not always hold, see, e.g., \cite{van1982generalized} or \cite{LenobleZagrebnovLuttingerSy}. In order to prove generalized BEC for the LS model, one makes use of the fact that the limiting integrated density of states $\mathcal N_{\infty}^{\mathrm{I}}(\cdot)=\lim_{N \rightarrow \infty}\mathcal N_N^{\mathrm{I},\omega}(\cdot)$ $\mathds{P}$-almost surely (the limit being in the vague sense) exhibits a Lifshitz-tail behavior at the bottom of the spectrum. We write $\mathcal N_{\infty}^{\mathrm{I}}(E):=\int_{(-\infty,E)} \mathcal N_{\infty} (\mathrm{d} E)$ and call $\mathcal N_{\infty}$ the limiting density of states (measure). Alternatively, see for instance \cite[(3.7)]{HupferLeschkeDensityofStates}, one can define $\mathcal N_{\infty}^{\mathrm{I}}$ directly for the infinite-volume Hamiltonian $h_\gamma(\omega)$ on $\mathds R$. To this end, let $\Theta$ be the indicator function on $(0,\infty)$ and for $x,y\in\mathds{R}$ let $\Theta(E - h_\gamma(\omega))(x,y)$ be the kernel of the spectral projection of $h_\gamma(\omega)$ onto the eigenspace with eigenvalues (strictly) less than $E$. Then, for all $E \in \mathds R$, $$ \mathcal N_\infty^{\mathrm{I}}(E) = \mathds E\big[\Theta(E-h_\gamma(\omega))(0,0)\big]\,. $$ This function on the right-hand side has the desired properties of being non-negative, left-continuous, and non-decreasing. Moreover, $\mathcal N_N^{\mathrm{I},\omega}$ converges to this function vaguely $\mathds{P}$-almost surely as $N\to\infty$. \begin{theorem} {\cite{EggarterSomeExact,GredeskulPastur75},\cite[Theorems 5.29,~6.7]{pastur1992spectra}} \label{Lifshitz Auslaufer one dimensional} % For the LS model one has % \begin{align} \mathcal N_{\infty}^{\mathrm{I}}(E) = \exp \left( - \pi \nu E^{-1/2} \big[1 + O(E^{1/2}) \big] \right) \end{align} % as $E \searrow 0$, i.e., there exists a constant $\widetilde M := \widetilde M(\gamma) > 0$ and an $\widetilde E > 0$ such that for all $0 < E \le \widetilde E$ we have % \begin{align} \mathcal N_{\infty}^{\mathrm{I}}(E) \le \widetilde M \mathrm{e}^{-\nu \pi E^{-1/2}} \ . \end{align} % In addition, there exists a constant $c > 0$ such that for all $E\ge0$ % \begin{align}\label{UpperEstimateIntegratedDensityStates} \mathcal N_{\infty}^{\mathrm{I}}(E) \leq cE^{1/2}\ . \end{align} % \end{theorem} \begin{remark} In the proof of Lemma \ref{Lemma wegen vager statt schwacher Konvergenz} we use the estimate $\mathcal N_{N}^{\mathrm{I,\omega}}(E) \leq \mathcal N_N^{\mathrm{I},(0)}(E)\leq \pi^{-1}\sqrt{E}$ for $\mathds P$-almost all $\omega \in \Omega$, all $E \ge 0$ and all $N \in \mathds N$ where $\mathcal N_N^{\mathrm{I},(0)}$ denotes the integrated density of states of the free Hamiltonian $-\mathrm{d}^2/ \mathrm{d} x^2$ on $H^1_0(\Lambda_N)$. \end{remark} Theorem~\ref{Lifshitz Auslaufer one dimensional} implies that the critical density \begin{equation \rho_{c}(\beta):=\sup_{\mu \in (-\infty,0)}\left\{\int\limits_{\mathds{R}} \mathcal{B}(E-\mu)\ \mathcal N_{\infty} (\mathrm{d} E) \right\}\label{EquationCriticalDensity} \,=\,\int_{(0,\infty)}\mathcal{B}(E)\ \mathcal N_{\infty} (\mathrm{d} E) \end{equation} is finite, i.e., $\rho_{c}(\beta) < \infty$; see Lemma~\ref{finite critical density in LSmodel}. \begin{remark}\label{RemarkSubsequenceChemicalPotentials} Whenever $\rho \geq \rho_{c}(\beta)$ then the sequence $\mu^{\omega}_N$ of chemical potentials converges $\mathds P$-almost surely to zero and to a strictly negative value whenever $\rho < \rho_c(\beta)$, see Lemma~\ref{Satz Konvergenzverhalten mu} and~\cite{lenoble2004bose}. In this context note that the infimum of the spectrum of $\mathrm{h}_{\gamma}(\omega)$ is zero. \end{remark} % % For the LS model one can then prove the following statement \begin{theorem}{\cite{lenoble2004bose}}\label{TheoremGeneralizedBEC} Generalized BEC in the LS model occurs $\mathds P$-almost surely if and only if $\rho > \rho_{c}(\beta)$. \end{theorem} \section{Main results}\label{secMainResults} Since our goal is to prove macroscopic occupation of the one-particle ground state it is necessary to control the rate of convergence of the energies of excited states which also converge to zero. \begin{remark}\label{RemarkTwoSets} We repeatedly use the following inequality: If $\Omega_1,\Omega_2 \subset \Omega$ are two events with $\mathds{P}(\Omega_j)\geq 1-\eta_j$ then % \begin{align*} \mathds{P}(\Omega_1 \cap \Omega_2) \geq 1 - \eta_1-\eta_2\ . \end{align*} \end{remark} \begin{theorem}[Energy gap] \label{satz E2} There exists a constant $M > 0$ with the following property: For any $0 < \eta < 2$ and any $c_2 > 2$ there exists an $\widetilde N = \widetilde N(\eta, c_2) \in \mathds N$ such that for all $N \ge \widetilde N$ we have $\mathds P(\Omega_2(\eta,c_2)) > 1 - 5\eta/8$ where % \begin{align*} \Omega_2(\eta,c_2) := \left\{ \omega: E_N^{1,\omega} \le \left( \dfrac{\pi\nu}{\ln (c_1 L_N)} \right)^2 \text{and}\ E_N^{c_3,\omega} \ge \left( \dfrac{\pi\nu}{\ln (c_1 L_N) - \ln(c_2/2)} \right)^2 \right\} \ , \end{align*} % $c_1 := - \nu / [4 \ln(\eta / 2)]$, and $c_3 := \lceil 4M c_2/ (\eta c_1) \rceil + 1$. \end{theorem} \begin{proof} In a first step we note that, by~\cite[Theorem~C.6]{KPS18} and the Rayleigh--Ritz variational principle, for $0 < \eta < 2$ there exists an $\widetilde N = \widetilde N(\eta) \in \mathds N$ such that % \begin{align*} \mathds P \left( \omega: E_N^{1,\omega} \le \left( \dfrac{\pi\nu}{\ln(c_1L_N) } \right)^2 \right) > 1 - \dfrac{1}{2}\eta \end{align*} % for all $N \ge \widetilde N$ with $c_1 := - \nu / [4 \ln(\eta/ 2)]$. We set % \begin{align}\label{TildeEnergie} \widetilde E_N := \left( \dfrac{\pi\nu}{\ln (c_1 L_N) - \ln(c_2/2)} \right)^2 \ . \end{align} % Then, according to Theorem~\ref{Lifshitz Auslaufer one dimensional} and Lemma~\ref{lemma E2} (identifying $\widetilde{M}=M^{1/2}$) there exists an $M > 0$ and an $\widetilde N_1 \in \mathds N$ such that, with $\mathcal E:=(\pi\nu )^{-1}\ln(M^{1/2})$, % \begin{align*} & \mathds{E} \left[ \mathcal N_N^{\mathrm{I}, \omega} \left( \widetilde E_N \right) \right] \le \mathcal N_{\infty}^{\mathrm{I}} \left( \left(\widetilde E_N^{-1/2} - \mathcal E \right)^{-2} \right) \le M \exp \left( - \nu \pi \widetilde E_N^{-1/2} \right) = M \dfrac{c_2}{2 c_1L_N} \end{align*} % and consequently % \begin{align*} \mathds{E} \left[ \left| \left\{ j : E_N^{j,\omega} \le \widetilde E_N \right\} \right| \right] = & L_N \cdot \mathds{E} \left[ \mathcal N_N^{\mathrm{I},\omega} \left( \widetilde E_N \right) \right] \le M \dfrac{c_2}{2 c_1} \end{align*} % for all $N \ge \widetilde N_1$. Therefore, % \begin{align*} k \, \mathds P \left( \omega: \left| \left\{ j : E_N^{j,\omega} \le \widetilde E_N \right\} \right| \ge k \right) & \le \mathds{E} \left[ \left| \left\{ j : E_N^{j,\omega} \le \widetilde E_N \right\} \right| \right] \le M \dfrac{c_2}{2 c_1} \end{align*} % and % \begin{align*} \mathds P \left( \omega: E_N^{k + 1,\omega} \ge \widetilde E_N \right) = \mathds P \left( \omega: \left| \left\{ j : E_N^{j,\omega} \le \widetilde E_N \right\} \right| \le k \right) & \ge 1 - M \dfrac{c_2}{2 c_1 k } \end{align*} % for all $k \in \mathds N$ and all $N \ge \widetilde N_1$. Setting $k = c_3 - 1$ now finishes this proof by taking Remark~\ref{RemarkTwoSets} into account. % \end{proof} For the following statement we introduce, for fixed $\rho,\beta$ and $\mathds{P}$-almost all $\omega \in \Omega$, \begin{align}\label{DensityRhoZero}\begin{split} \rho_0(\beta):=\lim_{\epsilon \searrow 0}\liminf_{N \rightarrow \infty}\int\limits_{(0,\epsilon]} \mathcal{B}(E - \mu_N^{\omega}) \mathcal N_N^{\omega} (\mathrm{d} E) \ . \end{split} \end{align} Note that the right-hand side is $\mathds{P}$-almost surely equal to a non-random function of $\beta$; see Lemma~\ref{Lemma beweis lim int epsilon infty und lim lim int epsilion infty rhoc vage Konvergenz} for details. Moreover, this lemma implies $\rho_0(\beta) = \rho-\rho_{c}(\beta)$ whenever $\rho > \rho_{c}(\beta)$. \begin{theorem}[Macroscopic occupation in probability] \label{LSM ns main theorem} Assume that $\rho > \rho_c(\beta)$. Then there exists an $M > 0$ with the following property: For all $0 < \eta \le 1/2$ and all $c_2 > 2$ there exists an $\widetilde N = \widetilde N(\eta, c_2) \in \mathds N$ such that for all $N \ge \widetilde N$, % \begin{align*} \mathds P \left(\omega: \dfrac{n_N^{1,\omega}}{N} \ge \dfrac{1}{c_3} \rho^{-1}(1 - \eta^{1/2})(1 - \eta) \rho_0(\beta) \right) \ge 1 - 4 \dfrac{\rho_0(\beta) + \rho + 1}{\rho_0(\beta)} \eta^{1/2} - 6\eta/8 \end{align*} % with $c_3 = c_3(\eta, c_2, M) = \lceil 4M c_2/ (\eta c_1) \rceil + 1 $ and $c_1$ as in~Theorem~\ref{satz E2}. \end{theorem} \begin{proof} For $0 < \eta \le 1/2$ % we define, for $N \in \mathds N$, % \begin{align*} \Omega_3(\eta,c_2) & := \left\{ \omega: \left(\dfrac{\pi \nu}{3 \ln (L_N)} \right)^2 \le E_N^{1,\omega} \le \left(\dfrac{\pi\nu}{\ln (c_1 L_N)}\right)^2\text{ and } E_N^{c_3,\omega} \ge \widetilde E_N \right\} \end{align*} % with $c_1,c_3$ as in Theorem~\ref{satz E2} and $\widetilde E_N$ as in \eqref{TildeEnergie}. According to Theorem~\ref{satz E2} and Lemma~\ref{lower bound ground state energy}, there exists an $\widetilde N = \widetilde N(\eta, c_2) \in \mathds N$ such that for all $N \ge \widetilde N$ we have $\mathds P(\Omega_3(\eta,c_2)) > 1 - 6\eta/8$. Furthermore, % \begin{align*} \rho & = \int\limits_{(0, \widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) + \int\limits_{(\widetilde E_N,[2 \pi \nu / \ln(L_N)]^2]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \\ & \quad + \, \int\limits_{([2 \pi \nu / \ln(L_N)]^2,\epsilon]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) + \int\limits_{(\epsilon,\infty)} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \end{align*} % for all $\epsilon > 0$ and all $N \in \mathds N$ large enough. Consequently, % \begin{align} & \mathds{E} \left[ \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \right] = \\ & \quad = \rho - \int\limits_{\Omega_3(\eta,c_2)} \left[ \, \int\limits_{(\widetilde E_N,[2 \pi \nu / \ln(L_N)]^2]} \mathcal{B}(E - \mu_N^{\omega})\, \mathcal N_N^{\omega}(\mathrm{d} E) \right] \, \mathds P(\mathrm{d} \omega) \label{proof BEC type ns LSM 1}\\ & \qquad \ \ \ - \int\limits_{\Omega_3(\eta,c_2)} \left[ \, \int\limits_{([2 \pi \nu / \ln(L_N)]^2,\epsilon]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \right] \, \mathds P(\mathrm{d} \omega) \label{proof BEC type ns LSM 2} \\ & \qquad \ \ \ - \int\limits_{\Omega \backslash \Omega_3(\eta,c_2)} \left[ \, \int\limits_{(\widetilde E_N,\epsilon]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \right] \, \mathds P(\mathrm{d} \omega) \label{proof BEC type ns LSM 3} \\ & \qquad \ \ \ - \mathds{E} \left[ \, \int\limits_{(\epsilon,\infty)} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \right] \label{proof BEC type ns LSM 4} \end{align} % for all $\epsilon > 0$ and all $N \in \mathds N$ large enough. Now, in a first step we realize that \begin{align*} \lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \mathds E \left[ \, \int\limits_{(\epsilon,\infty)} \mathcal{B}(E - \mu_N^{\omega}) \mathcal N_N^{\omega} (\mathrm{d} E) \right] \le \rho_c(\beta) \ . \end{align*} % This can be seen as follows: for $\epsilon > 0$ we have $\int_{(\epsilon,\infty)} \mathcal{B}(E - \mu_N^{\omega})\mathcal N_N^{\omega} (\mathrm{d} E) \leq \rho$. Moreover, % \begin{align*} \limsup\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal{B}(E - \mu_N^{\omega}) \mathcal N_N^{\omega} (\mathrm{d} E) \le \int\limits_{(\epsilon,\infty)} \mathcal{B}(E) \mathcal N_{\infty} (\mathrm{d} E) + \dfrac{2}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(\epsilon) \end{align*} % $\mathds{P}$-almost surely due to~\eqref{LemmaA6limsup}. Hence, by (reverse) Fatou's Lemma % \begin{align*} \limsup\limits_{N \to \infty} \mathds E \left[ \int\limits_{(\epsilon,\infty)} \mathcal{B}(E - \mu_N^{\omega}) \mathcal N_N^{\omega} (\mathrm{d} E) \right] \le \int\limits_{(\epsilon,\infty)} \mathcal{B}(E) \mathcal N_{\infty} (\mathrm{d} E) + \dfrac{2}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(\epsilon) \ . \end{align*} We conclude \begin{align*} \lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \mathds E \left[ \int\limits_{(\epsilon,\infty)} \mathcal{B}(E - \mu_N^{\omega}) \mathcal N_N^{\omega} (\mathrm{d} E) \right] & \le \lim\limits_{\epsilon \searrow 0} \int\limits_{(\epsilon,\infty)} \mathcal{B}(E) \mathcal N_{\infty} (\mathrm{d} E) \\ & = \int\limits_{(0,\infty)} \mathcal{B}(E) \mathcal N_{\infty} (\mathrm{d} E) \\ & = \rho_c(\beta) \end{align*} % due to Theorem~\ref{Lifshitz Auslaufer one dimensional} and Lemma~\ref{finite critical density in LSmodel}. % In a next step we show that the integrals in lines \eqref{proof BEC type ns LSM 1}--\eqref{proof BEC type ns LSM 3} either vanish or can be bounded from above in the considered limit: concerning~\eqref{proof BEC type ns LSM 1} we observe that for all but finitely many $N \in \mathds N$ and for all $\omega \in \Omega_3(\eta,c_2)$ we obtain % \begin{align} \label{Hinweis im beweis von theorem 3.4} \widetilde E_N - E_N^{1,\omega} \ge \pi^2 \nu^2 \dfrac{2\ln(c_1 L_N) \ln(c_2/2) - [\ln(c_2/2)]^2}{[\ln(c_1 L_N)]^4} \ge \dfrac{\pi^2 \nu^2}{[\ln(c_1 L_N)]^3} \cdot \ln(c_2/2) \end{align} % and therefore % \begin{align*} \mathcal{B}(E - \mu_N^{\omega}) \le \left( \beta (E - E_N^{1,\omega}) \right)^{-1} \le \dfrac{[\ln(c_1 L_N)]^3}{\beta \pi^2 \nu^2} \cdot \dfrac{1}{\ln(c_2/2)} \end{align*} % for all $E \ge \widetilde E_N$. Hence, % \begin{align*} A & :=\lim\limits_{N \to \infty} \int\limits_{\Omega_3(\eta,c_2)} \left[ \int\limits_{(\widetilde E_N,[2 \pi \nu/ \ln (L_N)]^2]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \\ & \le \lim\limits_{N \to \infty} \int\limits_{\Omega_3(\eta,c_2)} \left[ \int\limits_{(\widetilde E_N,[2 \pi \nu/ \ln (L_N)]^2]} \dfrac{[\ln(c_1 L_N)]^3}{\beta \pi^2 \nu^2} \cdot \dfrac{1}{\ln(c_2/2)} \, \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \\ & \le \lim\limits_{N \to \infty} \dfrac{[\ln(c_1 L_N)]^3}{\beta \pi^2 \nu^2} \cdot \dfrac{1}{\ln(c_2/2)} \int\limits_{\Omega_3(\eta,c_2)} \mathcal N_N^{\mathrm{I},\omega} \left( \dfrac{4 \pi^2 \nu^2}{ [\ln (L_N)]^{2}} \right) \mathds P(\mathrm{d} \omega) \ , \end{align*} % and since $\mathcal N_N^{\mathrm{I},\omega}(E) \ge 0$ for all $E > 0$ and all $\omega \in \Omega_3(\eta,c_2)$ we continue, employing Lemma~\ref{lemma E2} ($\mathcal E = (\pi \nu )^{-1} \ln(M^{1/2})$) and Theorem~\ref{Lifshitz Auslaufer one dimensional} ($\widetilde{M}=M^{1/2}$), \begin{align*} A \le \, & \lim\limits_{N \to \infty} \dfrac{[\ln(c_1 L_N)]^3}{\beta \pi^2 \nu^2} \cdot \dfrac{1}{\ln(c_2/2)} \mathds{E} \left[ \mathcal N_N^{\mathrm{I},\omega} \left( \dfrac{4 \pi^2 \nu^2}{ [\ln (L_N)]^{2}} \right) \right] \\ \le \, & \lim\limits_{N \to \infty} \dfrac{[\ln(c_1 L_N)]^3}{\beta \pi^2 \nu^2} \cdot \dfrac{1}{\ln(c_2/2)} \dfrac{M}{L_N^{1/2}} = 0 \ . \end{align*} We now turn to line~\eqref{proof BEC type ns LSM 2}: We firstly observe that for all $E \ge [2 \pi \nu / \ln(L_N)]^2$ and $\omega \in \Omega_3(\eta,c_2)$ we have $E \ge [2 \pi \nu / \ln(L_N)]^2 \ge 2 E_N^{1,\omega}$ and hence $E - \mu_N^{\omega} \ge E - E_N^{1,\omega} \ge (1/2) E$ for all but finitely many $N \in \mathds N$. Therefore, \begin{align*} B& :=\lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \int\limits_{\Omega_3(\eta,c_2)} \left[ \int\limits_{([2 \pi \nu/ \ln (L_N)]^2,\epsilon]}\mathcal{B}(E - \mu_N^{\omega}) \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \\ & \le\lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \int\limits_{\Omega_3(\eta,c_2)} \left[ \int\limits_{([2 \pi \nu/ \ln (L_N)]^2,\epsilon]} \mathcal B(E/2)\, \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \\ & \le \dfrac{2}{\beta} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \int\limits_{\Omega_3(\eta,c_2)} \left[ \int\limits_{([2 \pi \nu/ \ln (L_N)]^2,\epsilon]} E^{-1} \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \ . \end{align*} Then, an integration by parts (for Lebesgue--Stieltjes integrals, see, e.g., \cite[Theorem 21.67]{hewitt1965real}) and an application of the Fubini--Tonelli theorem yields \begin{align*} B & \le \dfrac{2}{\beta} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \int\limits_{\Omega_3(\eta,c_2)} \left[ \epsilon^{-1} \mathcal N_N^{\mathrm{I},\omega} (\epsilon) + \int\limits_{[2 \pi \nu / \ln(L_N)]^2}^{\epsilon} \mathcal N_N^{\mathrm{I},\omega} (E) E^{-2} \, \mathrm{d} E \right] \, \mathds P(\mathrm{d} \omega) \\ & \le \dfrac{2}{\beta} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \Bigg[ \epsilon^{-1} \int\limits_{\Omega_3(\eta,c_2)} \mathcal N_N^{\mathrm{I},\omega} ( \epsilon) \, \mathds P(\mathrm{d} \omega) \, + \\ & \qquad \qquad \qquad \qquad + \, \left. \int\limits_{[2 \pi \nu / \ln(L_N)]^2}^{\epsilon} \left( \, \int\limits_{\Omega_3(\eta,c_2)} \mathcal N_N^{\mathrm{I},\omega} (E) \, \mathds P(\mathrm{d} \omega) \right) \, E^{-2} \, \mathrm{d} E \right] \\ & \le \dfrac{2}{\beta} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \left[ \epsilon^{-1} \mathds{E} \left[ \mathcal N_N^{\mathrm{I},\omega} ( \epsilon) \right] + \int\limits_{[2 \pi \nu / \ln(L_N)]^2}^{\epsilon} \mathds{E} \left[ \mathcal N_N^{\mathrm{I},\omega} (E) \right] E^{-2} \, \mathrm{d} E \right]\ . \shortintertext{With an $M > 0$ due to Lemma~\ref{lemma E2} $(\mathcal{E}=(\pi\nu)^{-1}\ln(M^{1/2}))$ and Theorem~\ref{Lifshitz Auslaufer one dimensional} ($\widetilde M = M^{1/2}$)} & \le \dfrac{2 M}{\beta} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \left[ \epsilon^{-1} \mathrm{e}^{-\nu \pi \epsilon^{-1/2}} + \int\limits_{[2 \pi \nu / \ln(L_N)]^2}^{\epsilon} \mathrm{e}^{-\nu \pi E^{-1/2}} E^{-2} \, \mathrm{d} E \right] \\ & \le \dfrac{2 M}{\beta} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \left[ \epsilon^{-1} \dfrac{4! \, \epsilon^{2} }{ (\nu \pi)^4 } + \int\limits_{[2 \pi \nu / \ln(L_N)]^2}^{\epsilon} \dfrac{4! \, E^2}{(\nu \pi)^4} E^{-2} \, \mathrm{d} E \right] \\ & \le \dfrac{2 M}{\beta} \dfrac{4! }{ (\nu \pi)^4 } \lim\limits_{\epsilon \searrow 0} \left[ \epsilon + \epsilon \right] = 0 \end{align*} % $\mathds{P}$-almost surely. We now turn to line~\eqref{proof BEC type ns LSM 3}: we calculate, using (reverse) Fatou's Lemma, dominated convergence, and Lemma~\ref{Lemma beweis lim int epsilon infty und lim lim int epsilion infty rhoc vage Konvergenz}, % \begin{align*} & \lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \int\limits_{\Omega \backslash \Omega_3(\eta,c_2)} \left[ \int_{(0,\epsilon]} \mathcal{B}(E - \mu_N^{\omega})\, \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \\ & \quad \le \lim\limits_{\epsilon \searrow 0} \int\limits_{\Omega \backslash \Omega_3(\eta,c_2)} \limsup\limits_{N \to \infty} \left[ \int_{(0,\epsilon]}\mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \\ & \quad = \int\limits_{\Omega \backslash \Omega_3(\eta,c_2)} \lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \left[ \int_{(0,\epsilon]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \right] \mathds P(\mathrm{d} \omega) \leq \rho_0(\beta) \eta \ . \end{align*} % Altogether we have shown that % \begin{align} \label{lim E XN ge 1 eta rho0} & \liminf\limits_{N \to \infty} \mathds{E} \left[ \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \right] \ge (1 - \eta) \rho_0(\beta). \end{align} % In order to proceed, we define the random variable % \begin{align*} X_N^{\omega} := (1 - \eta) \rho_0(\beta) - \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega})\, \mathcal N_N^{\omega} (\mathrm{d} E) \ . \end{align*} % By Lemma~\ref{Lemma beweis lim int epsilon infty und lim lim int epsilion infty rhoc vage Konvergenz} and Theorem~\ref{Lifshitz Auslaufer one dimensional} we obtain, for some fixed $\epsilon' > 0$ small enough, % \begin{align*} \limsup_{N \to \infty} \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) & \le \limsup\limits_{N \to \infty} \int\limits_{(0,\epsilon']} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ & \le \left(1 + \dfrac{\eta}{2} \right) \rho_0(\beta) \ , \end{align*} % and hence, with $[ x ]_+:=\max\left(x,0\right)$, % \begin{align*} \lim\limits_{N \to \infty} \left[ \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) - \left( 1 + \dfrac{\eta}{2} \right) \rho_0(\beta) \right]_+ = 0 \end{align*} % $\mathds{P}$-almost surely. Consequently, % \begin{align*} \mathds P \left( \omega: \left[ \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) - \left(1 + \dfrac{\eta}{2} \right) \rho_0(\beta) \right]_+ \le \dfrac{\eta}{2}\rho_0(\beta) \right) \ge 1 - \eta \end{align*} % and therefore $\mathds P (\omega: X_N^{\omega} \ge - 2 \eta \rho_0(\beta)) \ge 1 - \eta$ for all but finitely many $N \in \mathds N$. Moreover, $X_N^{\omega} \ge - \rho$ for all $N \in \mathds N$ and $\mathds{P}$-almost all $\omega \in \Omega_3(\eta,c_2)$. Also,~\eqref{lim E XN ge 1 eta rho0} implies $\limsup_{N \to \infty} \mathds{E}[X_N^{\omega}] \le 0$ and therefore, for all but finitely many $N \in \mathbb{N}$, % \begin{align*}\begin{split} \eta & \geq \mathds{E} \left[ X_N^{\omega} \right] =\int\limits_{X_N^{\omega} \ge \eta^{1/2} (1 - \eta) \rho_0(\beta)} X_N^{\omega} \, \mathds P(\mathrm{d} \omega) + \int\limits_{-2 \eta \rho_0(\beta) \le X_N^{\omega} < \eta^{1/2} (1 - \eta) \rho_0(\beta)} X_N^{\omega} \, \mathds P(\mathrm{d} \omega) \\ & \qquad \qquad \qquad \qquad + \int\limits_{X_N^{\omega} < -2 \eta \rho_0(\beta)} X_N^{\omega} \, \mathds P(\mathrm{d} \omega) \\ & \geq \eta^{1/2} (1 - \eta) \rho_0(\beta) \, \mathds P\Big( X_N^{\omega} \ge \eta^{1/2} (1 - \eta) \rho_0(\beta) \Big) - 2 \eta \rho_0(\beta) - \eta \rho\ . \end{split} \end{align*} % Since $0 < \eta \le 1/2$, % \begin{align*} \mathds P \left( \omega: \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \le (1 - \eta^{1/2}) (1 - \eta) \rho_0(\beta) \right) \le 4 \dfrac{\rho_0(\beta) + \rho + 1}{\rho_0(\beta)} \eta^{1/2} \end{align*} % for all but finitely many $N \in \mathds N$. Hence, in total we have shown that for all $0 < \eta \le 1/2$ there exists an $\widetilde N = \widetilde N(\eta) \in \mathds N$ such that for all $N \ge \widetilde N$ one has % \begin{align*} & \mathds P \left( \omega: \dfrac{n_N^{1,\omega}}{N} \ge \dfrac{1}{c_3} \rho^{-1} (1 - \eta^{1/2}) (1 - \eta) \rho_0(\beta) \right) \\ & \quad \ge \mathds P \left( \left\{ \omega: \dfrac{n_N^{1,\omega}}{N} \ge \dfrac{1}{c_3} \rho^{-1} (1 - \eta^{1/2}) (1 - \eta) \rho_0(\beta) \right\} \cap \Omega_3(\eta,c_2) \right)\\ & \quad \ge \mathds P \Bigg( \Big\{ \omega: \int\limits_{(0,\widetilde E_N]} \mathcal{B}(E - \mu_N^{\omega}) \, \mathcal N_N^{\omega}(\mathrm{d} E) \ge (1 - \eta^{1/2}) (1 - \eta) \rho_0(\beta) \Big\} \cap \Omega_3(\eta,c_2) \Bigg) \\ &\ge 1 - 4 \dfrac{\rho_0(\beta) + \rho + 1}{\rho_0(\beta)} \eta^{1/2} - 6\eta/8 \ . \end{align*} % Note that we used the fact that $n_N^{j,\omega}/N$ is monotonically decreasing in $j$. \end{proof} % Theorem~\ref{LSM ns main theorem} shows that the one-particle ground state is, with strictly positive probability, macroscopically occupied. Regarding excited states we can show the following. \begin{cor}\label{CorollaryMinimal} Let $M>0$ be given as in Theorem \ref{LSM ns main theorem} and $c_1$ as in Theorem \ref{satz E2}. Then, for all $\eta' > 0$, $0 < \eta \le 1/2$, $c_2 > 2$, and $j \ge c_3:=\lceil 4 M c_2 / (\eta c_1) \rceil + 1$ there exists an $\widetilde N = \widetilde N(\eta', \eta, c_2)$ such that for all $N \ge \widetilde N$ one has % \begin{align*} \mathds P \left( \omega: \dfrac{n_N^{j,\omega}}{N} < \eta' \right) \ge \mathds P \left( \omega: \dfrac{n_N^{c_3,\omega}}{N} < \eta' \right) > 1-5\eta/8\,. \end{align*} % \end{cor} % \begin{proof} Let $\eta' > 0$, $0<\eta<2$ and $c_2>2$ be arbitrary. According to Theorem~\ref{satz E2} there exists an $\widetilde N = \widetilde N(\eta,c_2) \in \mathds N$ such that for all $N \ge \widetilde N$ we have $\mathds P(\Omega_2(\eta,c_2)) > 1 - 5 \eta/8$ with $\Omega_2(\eta,c_2) $ as in Theorem~\ref{satz E2}. Consequently, there exists a number $\widehat{N} \geq \widetilde N$ such that, for all $N \ge \widehat{N}$ and all $\omega \in \Omega_2(\eta,c_2)$ (see also \eqref{Hinweis im beweis von theorem 3.4}) % \begin{align*} \dfrac{1}{N} n_N^{c_3,\omega} & = \dfrac{1}{N} \left( \mathrm{e}^{\beta (E_N^{c_3,\omega} - \mu_N^{\omega})} - 1 \right)^{-1} \\ & \le \dfrac{1}{N} \left( \mathrm{e}^{\beta (E_N^{c_3,\omega} - E_N^{1,\omega})} - 1 \right)^{-1} \\ & \le \dfrac{1}{N} \Big[ \beta (E_N^{c_3,\omega} - E_N^{1,\omega}) \Big]^{-1} < \eta' \ . \end{align*} % \end{proof} % Most importantly, Theorem~\ref{LSM ns main theorem} implies $\mathds{P}$-almost sure Bose--Einstein condensation into the one-particle ground state as demonstrated by the following statement. % \begin{theorem}[Macroscopic occupation of the ground state]\label{MacroscopicOccupationGroundstate} The ground state is $\mathds{P}$-almost surely macroscopically occupied, that is, according to Definition \ref{Definition makroskopische Besetzung}, % \begin{align*} \mathds P \left( \omega: \limsup\limits_{N \to \infty} \dfrac{n_N^{1,\omega}}{N} > 0 \right) = 1 \ . \end{align*} % \end{theorem} % \begin{proof} Suppose to the contrary that there exists a $0 < C \le 1$ such that $\mathds P(\lim_{N \to \infty} n_N^{1,\omega} / N = 0) \ge C$. Then, for $0 < \eta \leq 1/2 $, $c_2 > 2$, and $c_3 = c_3(\eta,M)$ as in Theorem~\ref{LSM ns main theorem} we obtain % \begin{align*}\begin{split} & \limsup\limits_{N \to \infty} \mathds{P}\left(\omega: \dfrac{n_N^{1,\omega}}{N} \ge \dfrac{1}{c_3} \rho^{-1}(1 - \eta^{1/2}) (1 - \eta) \rho_0(\beta)\right) \\ & \quad \le \mathds P \left( \omega: \limsup\limits_{N \to \infty} \dfrac{n_N^{1,\omega}}{N} \ge \dfrac{1}{c_3} \rho^{-1}(1 - \eta^{1/2}) (1 - \eta) \rho_0(\beta) \right) \\ & \quad \le \mathds P \left( \omega: \neg \left( \lim\limits_{N \to \infty} \dfrac{n_N^{1,\omega}}{N} = 0 \right) \right) \le 1 - C \ . \end{split} \end{align*} % However, due to Theorem~\ref{LSM ns main theorem} there exists an $\widetilde N \in \mathds N$ such that for all $N \ge \widetilde N$ one has % \begin{align*} & \mathds P \left( \omega: \dfrac{n_N^{1,\omega}}{N} \ge \dfrac{1}{c_3} \rho^{-1}(1 - \eta^{1/2})(1 - \eta) \rho_0(\beta) \right) \\ & \quad \ge 1 - 4 \dfrac{\rho_0(\beta)+ \rho + 1}{\rho_0(\beta)} \eta^{1/2} - 6\eta/8 \\ & \quad \ge 1 - \dfrac{C}{2} \ , \end{align*} % for $\eta$ small enough. \end{proof} % \begin{remark} \label{remark 3.6} Using Theorem \ref{LSM ns main theorem} we can show that \begin{align*} \mathds E\Big[\dfrac{n_N^{1,\omega}}{N}\Big]& = \mathds E\Big[\dfrac{n_N^{1,\omega}}{N} \mathds{1}\Big(\dfrac{n_N^{1,\omega}}{N} \ge c(\eta)\Big)\Big] + \mathds E\Big[\dfrac{n_N^{1,\omega}}{N} \mathds{1}\Big(\dfrac{n_N^{1,\omega}}{N} < c(\eta)\Big)\Big]\ge c(\eta)(1-\epsilon)\,, \end{align*} where $c(\eta) = \dfrac{1}{c_3} \rho^{-1}(1 - \eta^{1/2})(1 - \eta) \rho_0(\beta)$, $\epsilon = 4 \dfrac{\rho_0(\beta) + \rho + 1}{\rho_0(\beta)} \eta^{1/2} + 6\eta/8$, and $\mathds{1}(\cdot)$ the indicator function. This proves that $\liminf_{N\to\infty} \mathds E\big[{n_N^{1,\omega}}/{N}\big] >0$, that is, there is macroscopic occupation of the ground state in expectation. \end{remark} \section{Appendix}\label{secAppendix} In this appendix we collect results for the LS model that we used to establish the results in the previous sections. We start with an estimate between the integrated density of states for finite $N$ and the infinite-volume integrated density of states. \begin{lemma}\label{lemma E2}For all $N \in \mathds N$, $E > 0$, and $0 < \mathcal E < E^{-1/2}$ we have % \begin{align} \mathds E \left[ \mathcal N_N^{\mathrm{I},\omega}(E) \right] \le \mathcal N_{\infty}^{\mathrm{I}} ([E^{-1/2} - \mathcal E]^{-2}) \ . \end{align} % Moreover, for all $N \in \mathds N$ and Lebesgue-almost all $E \ge 0$ (i.e., all $E \ge 0$ except the discontinuity points of $\mathcal N_{\infty}^{\mathrm{I}}$) one has \begin{align}\label{EquationAppendixFirstTheoremSecond} \mathds E \left[ \mathcal N_N^{\mathrm{I},\omega}(E) \right] \le \mathcal N_{\infty}^{\mathrm{I}} (E) \ . \end{align} % \end{lemma} \begin{proof} In this proof, $\mathcal N_{\Lambda}^{\mathrm{I},\omega}$ denotes the integrated density of states corresponding to the operator $h^{\Lambda}_{\gamma}(\omega)$ on $H^1_0(\Lambda)$, defined analogously to~\eqref{FormalOperatorLSModel}. In a first step, we realize that, for arbitrary disjoint intervals $\Lambda^1, \Lambda^2 \subset \mathds R$ and for any $E \ge 0$, the inequality % \begin{align} \label{akjzsdjk} |\Lambda^1|\, \mathcal N_{\Lambda^1}^{\mathrm{I}, \omega}(E) + |\Lambda^2| \, \mathcal N_{\Lambda^2}^{\mathrm{I}, \omega}(E) \le |\Lambda^1 \cup \Lambda^2| \, \mathcal N_{\Lambda^1 \cup \Lambda^2}^{\mathrm{I}, \omega}(E) \end{align} % holds for $\mathds{P}$-almost all $\omega \in \Omega$, see, e.g., \cite[5.39a]{pastur1992spectra}. For $M,N \in \mathds{N}$ and $j \in \mathds Z$ we define $\Lambda^{j}_N:=\Lambda_N + L_N \cdot j$ and $\Lambda_{M,N}:=\bigcup_{j \in \mathds Z: |j| \le M} \Lambda_N^j$. Note that $\{ \mathcal N_{\Lambda_N^j}^{\mathrm{I},\omega}(E) \}_{j \in \mathds Z}$ is a set of independent and identically distributed random variables for all $E \ge 0$. Hence, employing the strong law of large numbers, inequality \eqref{akjzsdjk}, and introducing the continuous function % \begin{align*} f_{E, \mathcal E} : \mathds R \to \mathds R,\ x \mapsto \begin{cases} 0 & \text{ if } x \le - \mathcal E \\ 1 + \mathcal E^{-1} x & \text{ if } -\mathcal E < x < 0 \\ 1 & \text{ if } 0 \le x \le E \\ 1 - \dfrac{x-E}{[E^{-1/2} - \mathcal E]^{-2} - E} & \text{ if } E < x < [E^{-1/2} - \mathcal E]^{-2} \\ 0 & \text{ if } x \ge [E^{-1/2} - \mathcal E]^{-2} \end{cases} \end{align*} % we find that, for all $E > 0$, % \begin{align*} \mathds E \Big[ \mathcal N_N^{\mathrm{I},\omega}(E) \Big] & = \lim\limits_{M \to \infty} \dfrac{1}{2M+1}\sum\limits_{j \in \mathds Z : |j| \le M} \mathcal N_{\Lambda_N^j}^{\mathrm{I},\omega}(E)\\ & = \lim\limits_{M \to \infty} \dfrac{1}{|\Lambda_M|} \sum\limits_{j \in \mathds Z : |j| \le M} |\Lambda_N^j| \, \mathcal N_{\Lambda_N^j}^{\mathrm{I},\omega}(E) \\ & \le \limsup\limits_{M \to \infty} \mathcal N_{\Lambda_{M,N}}^{\mathrm{I},\omega}(E) \le \limsup\limits_{M \to \infty} \mathcal N_{M}^{\mathrm{I},\omega}(E) \\ & \le \lim\limits_{M \to \infty} \int\limits_{\mathds R} f_{E,\mathcal E}(\widetilde E) \, \mathcal N_M^{\omega}(\mathrm{d} \widetilde E) = \int\limits_{\mathds R} f_{E,\mathcal E}(\widetilde E) \, \mathcal N_{\infty}(\mathrm{d} \widetilde E) \\ & \le \mathcal N_{\infty}^{\mathrm{I}}([E^{-1/2} - \mathcal E]^{-2}) \ . \end{align*} \eqref{EquationAppendixFirstTheoremSecond} follows from the fact that $\mathcal N_{\infty}^{\mathrm{I}}$ is monotonically increasing and hence has at most countably many points of discontinuity and by taking the limit $\mathcal{E} \searrow 0$. \end{proof} Using this result we obtain a lower bound for the ground-state energy. \begin{lemma} \label{lower bound ground state energy} For all $\kappa > 2$ and for $\mathds{P}$-almost all $\omega$ there exists an $\widetilde N = \widetilde N(\kappa, \omega) \in \mathds N$ such that for all $N \ge \widetilde N$ we have % \begin{align} E_N^{1,\omega} \ge \left( \dfrac{\pi\nu }{\kappa \ln(L_N)} \right)^{2} \ . \end{align} % \end{lemma} % \begin{proof} Let $\kappa > 2$ be given. We define $\widehat E_N := (\pi\nu / [ \kappa \ln(L_N)])^{2}$ for all $N \in \mathds N$ with $L_N> 1$, and pick some $\mathcal E > 0$. Then, with Lemma~\ref{lemma E2} and Theorem~\ref{Lifshitz Auslaufer one dimensional} we conclude that for all but finitely many $N \in \mathds N$ one has % \begin{align*} \mathds P\left(\omega: |\Lambda_N| \cdot \mathcal N_N^{\omega}(\widehat E_N) \ge 1 \right) & \le L_N \cdot \mathds{E} \left[ \mathcal N_N^{\mathrm{I}, \omega}(\widehat E_N) \right] \\ & \le L_N \cdot \mathcal N^{\mathrm{I}}_{\infty}([\widehat E_N^{-1/2} - \mathcal E]^{-2}) \\ & \le \widetilde{M}L_N \cdot \exp\left( - \pi\nu \left[ \widehat E_N^{-1/2} - \mathcal E \right] \right) \\ & \le \widetilde{M} \mathrm{e}^{\pi \nu \mathcal E}\cdot L_N^{- \kappa+1} \ . \end{align*} % Hence $\sum_{N=1}^{\infty} \mathds P\left(\omega: L_N\cdot \mathcal N_N^{\omega}(\widehat E_N) \ge 1 \right) < \infty$ and the statement follows from the Borel--Cantelli lemma. % \end{proof} \begin{remark} Lemma~\ref{lemma E2} and Lemma~\ref{lower bound ground state energy} can readily be generalized to Poisson random potentials of the form $$V(\omega, \cdot) = \sum\limits_{j\in\mathds{Z}} u(\cdot - x_j(\omega)) \ ,$$ with $u \in L^{\infty}(\mathds R)$ having compact support. What we do not have at our disposal is the $O(E^{1/2})$-error bound in the Lifshitz-tail behavior. If we did we could carry over our results to these models. \end{remark} Note that the critical density $\rho_c(\beta)$ was defined in~\eqref{EquationCriticalDensity}. \begin{lemma} \label{finite critical density in LSmodel} For all $\beta > 0$, the critical density $\rho_c(\beta)$ satisfies % \begin{align*} \rho_c(\beta) = \int\limits_{(0,\infty)} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) < \infty \ . \end{align*} % \end{lemma} \begin{proof} In a first step we show that \begin{align}\label{EquationProofRelationXXXXX} \int\limits_{\mathds R} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) = \int\limits_{(0,\infty)} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \end{align} is finite. In order to do this, we choose $\widetilde E_1: = \widetilde E$ with $\widetilde E > 0$ as in Theorem~\ref{Lifshitz Auslaufer one dimensional}. Moreover, we choose $\widetilde E_2 > \widetilde E_1$ such that for $E \ge \widetilde E_2$ one has \begin{align} \label{Ungleichung Appendix 2 kritische Dichte Energieschranke 1} \mathcal{B}(E) \le \left( 2^{-1/2} \mathrm{e}^{\beta E} \right)^{-1} \end{align} and \begin{align} \label{Ungleichung Appendix 2 kritische Dichte Energieschranke 2} \mathcal N_{\infty}^{\mathrm{I}}(E) \le c E^{1/2} \end{align} with $c > 0$ as in Theorem~\ref{Lifshitz Auslaufer one dimensional}. We write, % \begin{align} \int\limits_{(0,\infty)} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) & = \int\limits_{(0,\widetilde E_1]} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \label{Appendix proof 2 critical density align 1 1} \\ & + \int\limits_{(\widetilde E_1,\widetilde E_2]}\mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \label{Appendix proof 2 critical density align 1 2} \\ & + \int\limits_{(\widetilde E_2,\infty)} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \label{Appendix proof 2 critical density align 1 3} \end{align} % The term in line~\eqref{Appendix proof 2 critical density align 1 2} is finite since % \begin{align*} \int\limits_{(\widetilde E_1,\widetilde E_2]} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \le \mathcal B(\widetilde E_1)\, \mathcal N_{\infty}^{\mathrm{I}} (\widetilde E_2) \le c\,\mathcal B(\widetilde E_1)\, \widetilde E_2^{1/2} < \infty \ , \end{align*} see also \eqref{Ungleichung Appendix 2 kritische Dichte Energieschranke 2}. In the following, we write $\mathcal N_{\infty}^{\mathrm{I}}(E+)$ for the right-sided limit of $\mathcal N_{\infty}^{\mathrm{I}}$ at $E$; recall that $\mathcal N_{\infty}^{\mathrm{I}}$ is left-continuous. For the term in line \eqref{Appendix proof 2 critical density align 1 1} we get, using integration by parts, see, e.g., \cite[Theorem 21.67]{hewitt1965real}, and the fact that $\mathcal N_{\infty}^{\mathrm{I}}$ is non-decreasing, % \begin{align*} A &:= \lim\limits_{\epsilon_1 \searrow 0} \int\limits_{(\epsilon_1,\widetilde E_1]} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \\ & \,\le \lim\limits_{\epsilon_1 \searrow 0} \left\{ \mathcal B(\widetilde E_1) \, \mathcal N_{\infty}^{\mathrm{I}} (\widetilde E_1+) + \int\limits_{\epsilon_1}^{\widetilde E_1} \mathcal N_{\infty}^{\mathrm{I}} (E) \big[\mathcal B(E)\big]^2\, \beta \mathrm{e}^{\beta E} \, \mathrm{d} E \right\}\\ & \,\le \mathcal B(\widetilde E_1)\, \mathcal N_{\infty}^{\mathrm{I}} (2 \widetilde E_1) + \int\limits_{0}^{\widetilde E_1} \mathcal N_{\infty}^{\mathrm{I}} (E) \big[\mathcal B(E)\big]^2\, \beta \mathrm{e}^{\beta E} \, \mathrm{d} E \\ \shortintertext{and by Theorem~\ref{Lifshitz Auslaufer one dimensional},} & \le \mathcal B(\widetilde E_1)\, \mathcal N_{\infty}^{\mathrm{I}} (2 \widetilde E_1) + \int\limits_{0}^{\widetilde E_1} \widetilde M \mathrm{e}^{- \nu \pi E^{-1/2}} (\beta E)^{-2} \beta \mathrm{e}^{\beta E} \, \mathrm{d} E \\ & \le \mathcal B(\widetilde E_1)\, \mathcal N_{\infty}^{\mathrm{I}} (2 \widetilde E_1) + \widetilde M \beta^{-1} \mathrm{e}^{\beta \widetilde E_1} \int\limits_{0}^{\widetilde E_1} \dfrac{4! E^2}{(\nu \pi)^4} E^{-2} \, \mathrm{d} E < \infty \ . \end{align*} % As a last step, we show that also the term in line \eqref{Appendix proof 2 critical density align 1 3} is finite. We obtain % \begin{align*} C & := \lim\limits_{\epsilon_2 \to \infty} \int\limits_{(\widetilde E_2,\epsilon_2]} \mathcal{B}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \\ & \, \le \lim\limits_{\epsilon_2 \to \infty} \left[ \mathcal B(\epsilon_2)\, \mathcal N_{\infty}^{\mathrm{I}} (\epsilon_2+) + \int\limits_{\widetilde E_2}^{\epsilon_2} \mathcal N_{\infty}^{\mathrm{I}} (E) \big[\mathcal B(E)\big]^2\, \beta \mathrm{e}^{\beta E} \, \mathrm{d} E \right] \end{align*} by using integration by parts. Since $\mathcal N_{\infty}^{\mathrm{I}}$ is non-decreasing, \begin{align*} C& \, \le \lim\limits_{\epsilon_2 \to \infty} \left[ \mathcal B(\epsilon_2)\, \mathcal N_{\infty}^{\mathrm{I}} (2\epsilon_2) + \int\limits_{\widetilde E_2}^{\epsilon_2} \mathcal N_{\infty}^{\mathrm{I}} (E) \big[\mathcal B(E)\big]^2\, \beta \mathrm{e}^{\beta E} \, \mathrm{d} E \right] \\ \shortintertext{and using \eqref{Ungleichung Appendix 2 kritische Dichte Energieschranke 1} and \eqref{Ungleichung Appendix 2 kritische Dichte Energieschranke 2},} & \, \le \lim\limits_{\epsilon_2 \to \infty} \left[ 2 c \, \mathrm{e}^{-\beta \epsilon_2} \epsilon_2^{1/2} + 2 c \beta \, \int\limits_{\widetilde E_2}^{\epsilon_2} E^{1/2} \mathrm{e}^{-2\beta E } \mathrm{e}^{\beta E} \, \mathrm{d} E \right] < \infty \ . \end{align*} % Altogether we have by now proved~\eqref{EquationProofRelationXXXXX}. The final statement about $\rho_c(\beta)$ then follows, using again dominated convergence, by % \begin{align*} \rho_c(\beta) & = \sup\limits_{\mu \in (-\infty,0)} \left\{ \int\limits_{\mathds R} \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \right\} \\ & = \sup\limits_{\mu \in (-\infty,0)} \left\{ \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \right\} \\ & = \lim\limits_{\mu \to 0^{-}} \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \\ & = \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) < \infty\ . \end{align*} \end{proof} % The statement in the next lemma is not trivial since we have only vague convergence of the density of states and not weak convergence. \begin{lemma} \label{Lemma wegen vager statt schwacher Konvergenz} For all $\mu < 0$ we have $\mathds{P}$-almost surely \begin{align} \label{equation Lemma wegen vager statt schwacher Konvergenz} \lim\limits_{N \to \infty} \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) = \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \ . \end{align} \end{lemma} \begin{proof} Let $\mu < 0$ be given. Then, for all $E_2 > 0$ we get % \begin{align*} \begin{split} \limsup\limits_{N \to \infty} \int\limits_{(0,\infty)} &\mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \\ \le \, & \limsup\limits_{N \to \infty} \int\limits_{(0,E_2]} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) + \limsup\limits_{N \to \infty} \int\limits_{[E_2,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \ . \end{split} \end{align*} % For $0 < \mathcal E < - \mu$ we define the real function $g_{\mathcal E, E_2}$ as % \begin{align} \label{definition g mathcal E E_2 E} g_{\mathcal E, E_2} (E) := \begin{cases} 0 & \quad \text{ if } E \le - \mathcal E \\ 1 + \mathcal E^{-1} E & \quad \text{ if } - \mathcal E < E < 0 \\ 1 & \quad \text{ if } 0 \le E \le E_2 \\ 1 - \dfrac{E - E_2}{\mathcal E} & \quad \text{ if } E_2 < E < E_2 + \mathcal E \\ 0 & \quad \text{ if } E > E_2 + \mathcal E \end{cases}\ . \end{align} For the first integral we $\mathds{P}$-almost surely obtain, by $\mathds{P}$-almost sure vague convergence, % \begin{align*} % \limsup\limits_{N \to \infty} \int\limits_{(0,E_2]} &\mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \\ \le \, & \limsup\limits_{N \to \infty} \int\limits_{\mathds R} g_{\mathcal E, E_2} (E) \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \\ \le \, & \mathcal{B}(E_2 - \mu) \mathcal N_{\infty}^{\mathrm{I}}(E_2 + \mathcal E)+ \int\limits_{(0,E_2]} \mathcal{B}(E - \mu) \mathcal N_{\infty}(\mathrm{d} E) \ . % \end{align*} % Furthermore, % \begin{align*} % \limsup\limits_{N \to \infty} &\int\limits_{[E_2,\infty)}\mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \le \limsup\limits_{N \to \infty} \lim\limits_{\epsilon_2 \to \infty} \int\limits_{[E_2,\epsilon_2]} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E)\ , \\ \shortintertext{and integrating by parts gives} \le \, & \limsup\limits_{N \to \infty} \lim\limits_{\epsilon_2 \to \infty} \left[ \mathcal{B}(\epsilon_2- \mu) \mathcal N_N^{\mathrm{I},\omega}(\epsilon_2) + \beta\int\limits_{E_2}^{\epsilon_2} \mathcal N_N^{\mathrm{I},\omega}(E) \big[\mathcal B(E - \mu)\big]^2\, \mathrm{e}^{\beta (E - \mu)} \, \mathrm{d} E\right] \ . % \end{align*} % If we denote with $\mathcal N_N^{\mathrm{I},(0)}$ the integrated density of states of the free Hamiltonian $-\mathrm{d}^2/\mathrm{d} x^2$ on $H^1_0(\Lambda_N)$ then we can further bound this by % \begin{align*} \le \, & \limsup\limits_{N \to \infty} \lim\limits_{\epsilon_2 \to \infty} \left[ \mathcal{B}(\epsilon_2 - \mu) \mathcal N_N^{\mathrm{I},(0)}(\epsilon_2) + \beta\int\limits_{E_2}^{\epsilon_2} \mathcal N_N^{\mathrm{I},(0)}(E) \big[\mathcal B(E - \mu)\big]^2\, \mathrm{e}^{\beta (E - \mu)} \, \mathrm{d} E\right]\ . % \end{align*} Since $\mathcal N_N^{\mathrm{I},(0)}(E) \le \pi^{-1} E^{1/2}$ for all $E \ge 0$ and all $N \in \mathds N$ we get % \begin{align*} = \, & \lim\limits_{\epsilon_2 \to \infty} \left[ \pi^{-1} \mathcal{B}(\epsilon_2 - \mu) \epsilon_2^{1/2} + \beta\pi^{-1}\int\limits_{E_2}^{\epsilon_2} E^{1/2} \big[\mathcal B(E - \mu)\big]^2\, \mathrm{e}^{\beta (E - \mu)} \, \mathrm{d} E \right]\\ = \, & \beta \pi^{-1}\int\limits_{E_2}^{\infty} E^{1/2} \big[\mathcal B(E - \mu)\big]^2\, \mathrm{e}^{\beta (E - \mu)} \, \mathrm{d} E \ . \end{align*} Hence, in total we obtain $\mathds{P}$-almost surely \begin{align*} \limsup\limits_{N \to \infty} &\int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \\ \le \, & \lim\limits_{E_2 \to \infty} \mathcal{B}(E_2 - \mu) \mathcal N_{\infty}^{\mathrm{I}}(E_2 + \mathcal E)+\lim\limits_{E_2 \to \infty} \int\limits_{(0,E_2]} \mathcal{B}(E - \mu) \mathcal N_{\infty}(\mathrm{d} E) \\ & + \, \beta \pi^{-1} \lim\limits_{E_2 \to \infty} \int\limits_{E_2}^{\infty} E^{1/2} \big[\mathcal B(E - \mu)\big]^2\, \mathrm{e}^{\beta (E - \mu)} \, \mathrm{d} E \\ = \, & \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \mathcal N_{\infty}(\mathrm{d} E) \ , \end{align*} where we also used Theorem~\ref{Lifshitz Auslaufer one dimensional}. On the other hand, for all $E_2 > 0$ $\mathds{P}$-almost surely, % \begin{align*} \liminf\limits_{N \to \infty} \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) & \ge \liminf\limits_{N \to \infty} \int\limits_{\mathds R} g_{\mathcal E, E_2}(E) \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \\ & = \int\limits_{\mathds R} g_{\mathcal E, E_2}(E) \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \\ & \ge \int\limits_{(0,E_2]} \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \ . \end{align*} Thus, $\mathds{P}$-almost surely, \begin{align*} \liminf\limits_{N \to \infty} \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) & \ge \lim\limits_{E_2 \to \infty} \int\limits_{(0,E_2]} \mathcal{B}(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \, =\, \int\limits_{(0,\infty)} \mathcal{B}(E - \mu)\, \mathcal N_{\infty}(\mathrm{d} E) \ . \end{align*} \end{proof} The next lemma is taken from \cite{lenoble2004bose}. We follow in parts their proof. \begin{lemma} \label{Satz Konvergenzverhalten mu} If $\rho < \rho_c(\beta)$, then $\mu^{\omega}_{N}$ converges $\mathds{P}$-almost surely to a non-random limit point $\widehat \mu < 0$. On the other hand, if $\rho \geq \rho_c(\beta)$, then $\mu^{\omega}_{N}$ converges $\mathds{P}$-almost surely to $0$. \end{lemma} \begin{proof} In a first step, we show that the sequence $(\mu^{\omega}_{N})_{N=1}^{\infty}$ has $\mathds{P}$-almost surely at least one accumulation point in both cases: Note that % \begin{align} \label{assumption limsup e beta E finite} \limsup\limits_{N \to \infty} \int\limits_{(0,\infty)} \mathrm{e}^{-\beta E} \mathcal N_N^{\omega}(\mathrm{d} E) \le \limsup\limits_{N \to \infty}\frac{1}{L_N} \sum\limits_{j =1}^{\infty} \mathrm{e}^{-\beta (j\pi / L_N)^2} = (4\pi \beta)^{-1/2} < \infty \end{align} for $\mathds{P}$-almost all $\omega \in \Omega$. We define \begin{align*} \phi_N^{\omega}(\beta) := \dfrac{1}{L_N} \sum\limits_{j=1}^{\infty} \mathrm{e}^{-\beta E_N^{j,\omega}} = \int\limits_{(0,\infty)} \mathrm{e}^{-\beta E} \, \mathcal N_N^{\omega}(\mathrm{d} E)\ . \end{align*} The relation between $\phi_N^{\omega}(\beta)$ and $\rho$ is simply \begin{align*} \rho & = \dfrac{1}{L_N} \sum\limits_{j = 1}^{\infty} \left( \mathrm{e}^{\beta ( E_N^{j,{\omega}} - \mu_N^{\omega})} -1 \right)^{-1} = \dfrac{1}{L_N} \sum\limits_{j= 1}^{\infty} \mathrm{e}^{-\beta E_N^{j,\omega}} \dfrac{1} { \mathrm{e}^{- \beta \mu_N^{\omega}} - \mathrm{e}^{-\beta E_N^{j,\omega}} } \\ & \le \left( \dfrac{1}{L_N} \sum\limits_{j = 1}^{\infty} \mathrm{e}^{- \beta E_N^{j,{\omega}}} \right) \dfrac{\mathrm{e}^{\beta \mu_N^{\omega}}}{1 - \mathrm{e}^{-\beta (E_N^{1,{\omega}} - \mu_N^{\omega})}} = \phi_N^{\omega}(\beta) \dfrac{\mathrm{e}^{\beta \mu_N^{\omega}}}{1 - \mathrm{e}^{-\beta (E_N^{1,{\omega}} - \mu_N^{\omega})}} \ . \end{align*} Consequently, we conclude that \begin{align*} \rho - \rho \mathrm{e}^{-\beta E_N^{1,\omega}} \mathrm{e}^{\beta \mu_N^{\omega}} \le \phi_N^{\omega}(\beta) \mathrm{e}^{\beta \mu_N^{\omega}} \end{align*} and \begin{align} \beta^{-1} \ln \left( \dfrac{\rho}{\phi_N^{\omega}(\beta) + \rho \mathrm{e}^{-\beta E_N^{1,\omega}}} \right) & \le \mu_N^{\omega} \ . \end{align} Due to~\eqref{assumption limsup e beta E finite} we have $\limsup_{N \to \infty} \phi^{\omega}_N(\beta) < \infty$. Moreover, since $\mu_N^{\omega}< E_N^{1,\omega}$ for all $N \in \mathds N$ and since $E_N^{1,\omega}$ converges $\mathds{P}$-almost surely to $0$, we obtain $\mathds{P}$-almost surely \begin{align*} \beta^{-1} \ln \left( \dfrac{\rho}{\limsup\limits_{N \to \infty} \phi_N^{\omega}(\beta) + \rho } \right) \le \liminf\limits_{N \to \infty} \mu_N^{\omega}\le \limsup\limits_{N \to \infty} \mu_N^{\omega}\le 0 \ . \end{align*} This shows that there exists a set $\widetilde \Omega \subset \Omega$ with measure $\mathds P(\widetilde \Omega) = 1$ such that for all $\omega \in \widetilde \Omega$ equation \eqref{equation Lemma wegen vager statt schwacher Konvergenz} from Lemma~\ref{Lemma wegen vager statt schwacher Konvergenz} holds and the sequence $(\mu^{\omega}_{N})_{N=1}^{\infty}$ has at least one accumulation point $\mu_{\infty}^{\omega} \in \mathds R$. Now, for $\omega \in \widetilde \Omega$ consider the case where $\rho < \rho_c(\beta)$: Since \begin{align} \label{function mu to int e E mu} (-\infty,0) \to \mathds{R}, \quad \mu \mapsto \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_{\infty} (\mathrm{d} E) \end{align} is a strictly increasing function, there is a unique, non-random solution $\widehat \mu < 0$ to \begin{align} \label{definierende Gleichung fuer mu hat} \rho = \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_{\infty} (\mathrm{d} E) \ . \end{align} Suppose to the contrary that the accumulation point $\mu_{\infty}^{\omega}$ is zero. Then there exists a subsequence $(\mu_{N_j}^{\omega})_{j=1}^{\infty}$ which converges to $0$. It follows that \begin{align} \dfrac{\widehat \mu }{2} < \mu_{N_j}^{\omega} \end{align} for all but finitely many $j \in \mathds{N}$. Because % \begin{align} (-\infty,0) \to \mathds{R}, \quad \mu \mapsto \int\limits_{(0,\infty)} \mathcal{B}(E - \mu) \, \mathcal N_N^{\omega}(\mathrm{d} E) \end{align} % is strictly increasing, % \begin{align} \label{Ergebnis Widerspruch Konvergenz von mu} \int\limits_{(0,\infty)} \mathcal B(E-\widehat{\mu}/2)\, \mathcal N_{N_j}^{\omega}(\mathrm{d} E) < \int\limits_{(0,\infty)} \mathcal B(E-\mu_{N_j}^{\omega}) \, \mathcal N_{N_j}^{\omega}(\mathrm{d} E) = \rho \end{align} for all but finitely many $j \in \mathds N$. However, due to~\eqref{definierende Gleichung fuer mu hat} and employing Lemma~\ref{Lemma wegen vager statt schwacher Konvergenz} % \begin{align}\label{HP mu Loesung der Gleichung} \begin{split} \rho & = \int\limits_{(0,\infty)} \mathcal{B}(E - \widehat \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \\ & < \int\limits_{(0,\infty)} \mathcal B(E-\widehat{\mu}/2) \, \mathcal N_{\infty} (\mathrm{d} E) \\ & = \lim\limits_{N \to \infty} \int\limits_{(0,\infty)} \mathcal B(E-\widehat{\mu}/2)\, \mathcal N_{N}^{\omega} \, (\mathrm{d} E) \ , \end{split} \end{align} % which is a contradiction to~\eqref{Ergebnis Widerspruch Konvergenz von mu}. As a consequence, any accumulation point $\mu_{\infty}^{\omega}$ is strictly smaller than $0$. In addition, using Lemma~\ref{Lemma wegen vager statt schwacher Konvergenz}, $m \in \mathds{N}$, % \begin{align*} \limsup\limits_{j \to \infty} \int\limits_{(0,\infty)} \mathcal B(E-\mu_{N_j}^\omega) \mathcal N_{N_j}^{\omega}(\mathrm{d}E) & \le \lim\limits_{j \to \infty} \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega} + m^{-1} \mu_{\infty}^{\omega}/2) \, \mathcal N_{N_j}^{\omega}(\mathrm{d}E) \\ & = \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega} + m^{-1}\mu_{\infty}^{\omega}/2) \, \mathcal N_{\infty}(\mathrm{d}E) \end{align*} % and \begin{align*} \liminf\limits_{j \to \infty} \int\limits_{(0,\infty)} \mathcal B(E - \mu_{N_j}^{\omega}) \, \mathcal N_{N_j}^{\omega}(\mathrm{d}E) & \ge \lim\limits_{j \to \infty} \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega} - m^{-1} \mu_{\infty}^{\omega}/2) \, \mathcal N_{N_j}^{\omega}(\mathrm{d}E) \\ & = \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega} - m^{-1} \mu_{\infty}^{\omega}/2)\, \mathcal N_{\infty}(\mathrm{d}E)\ . \end{align*} Hence, since $m \in \mathds{N}$ was arbitrary, % \begin{align*} \lim\limits_{j \to \infty} \int\limits_{(0,\infty)} \mathcal B(E - \mu_{N_j}^{\omega}) \, \mathcal N_{N_j}^{\omega}(\mathrm{d}E) & = \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega}) \, \mathcal N_{\infty}(\mathrm{d}E) \ . \end{align*} We conclude that \begin{align} \label{Gleichung mu Haufungspunkt gleich mu tilde} \begin{split} \int\limits_{(0,\infty)} \mathcal B(E - \widehat \mu) \, \mathcal N_{\infty}(\mathrm{d} E) & = \rho = \lim\limits_{j \to \infty} \int\limits_{(0,\infty)} \mathcal B(E - \mu_{N_j}^{\omega}) \, \mathcal N_{N_j}^{\omega}(\mathrm{d} E) \\ &= \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega}) \, \mathcal N_{\infty}(\mathrm{d} E)\ , \end{split} \end{align} % holds $\mathds{P}$-almost surely for all convergent subsequences of $(\mu^{\omega}_{N})_{N=1}^{\infty}$ with corresponding limit point $\mu_{\infty}^{\omega}$. Hence, due to the strict monotonicity of the function~\eqref{function mu to int e E mu} and due to~\eqref{Gleichung mu Haufungspunkt gleich mu tilde}, any accumulation point $\mu_{\infty}^{\omega}$ is equal to $\widehat \mu$. In other words, the sequence $(\mu^{\omega}_{N})_{N=1}^{\infty}$ converges to the non-random limit $\widehat \mu < 0$. In the next step we assume that $\rho \ge \rho_c(\beta)$: Suppose to the contrary that the sequence $(\mu^{\omega}_{N})_{N=1}^{\infty}$ has an accumulation point $\mu_{\infty}^{\omega} < 0$ with the subsequence $(\mu_{N_j}^{\omega})_{j=1}^{\infty}$ converging to it. As in~\eqref{Gleichung mu Haufungspunkt gleich mu tilde} we get \begin{align*} \rho = \lim\limits_{j \to \infty} \int\limits_{(0,\infty)} \mathcal B(E - \mu_{N_j}^\omega) \, \mathcal N_{N_j}^{\omega}(\mathrm{d} E) = \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega}) \, \mathcal N_{\infty} (\mathrm{d} E) \ge \rho_c(\beta) \ . \end{align*} % However, one also has % \begin{align*} \int\limits_{(0,\infty)} \mathcal B(E - \mu_{\infty}^{\omega}) \, \mathcal N_{\infty}(\mathrm{d} E) < \sup\limits_{\mu \in (-\infty, 0)} \left\{ \int\limits_{(0,\infty)} \mathcal B(E - \mu) \, \mathcal N_{\infty}(\mathrm{d} E) \right\} = \rho_c(\beta) \ , \end{align*} % yielding a contradiction. Since this holds for any subsequence, we conclude the statement. \end{proof} The next lemma is essential in the proof of generalized BEC in the supercritical region $\rho > \rho_c(\beta)$. We do not know whether the limit of $\int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E)$ as $N\to\infty$ exists $\mathds{P}$-almost surely. Therefore we state bounds on the $\limsup$ and $\liminf$, which, most importantly, coincide in the limit $\epsilon\searrow 0$. \begin{lemma} \label{Lemma beweis lim int epsilon infty und lim lim int epsilion infty rhoc vage Konvergenz} If $\rho \ge \rho_c(\beta)$ and $\epsilon > 0$, then $\mathds{P}$-almost surely, % \begin{align} \limsup\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) & \le \int\limits_{(\epsilon,\infty)} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) + \dfrac{2}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(\epsilon) \ , \label{LemmaA6limsup} \\ \liminf\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) & \ge \int\limits_{(\epsilon,\infty)} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) - \dfrac{4}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(2\epsilon) \nonumber\ , \end{align} % and % \begin{align} \label{LemmaA6limsup rho_c} \begin{split} &\lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ &\quad = \, \lim\limits_{\epsilon \searrow 0} \liminf\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) = \rho_c(\beta) \ . \end{split} \end{align} % \end{lemma} \begin{proof} In a first step we note that $\mathds{P}$-almost surely and for all $E_2 > \epsilon > 0$ \begin{align} \label{lim int NN int N infty} \lim\limits_{N \to \infty} \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) = \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \end{align} where % \begin{align} g_{\epsilon}^{(E_2)}(E):= \begin{cases} 0 \quad & \text{ if } E < \epsilon/2 \\ \dfrac{E - \epsilon/2}{\epsilon/2} & \text{ if } \epsilon/2 \le E \le \epsilon \\ 1 \quad & \text{ if } \epsilon < E \le E_2 \\ 1 - \dfrac{E - E_2}{E_2} \quad & \text{ if } E_2 < E < 2 E_2 \\ 0 \quad & \text{ if } E \ge 2 E_2 \end{cases} \ . \end{align} % This can be shown as follows: One has % \begin{align} \label{Gleichung beweis verallg BEC 2} & \left|\, \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) - \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \, \right| \\ &\quad \le \, \left| \, \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \left( \mathcal B(E-\mu_N^{\omega}) - \mathcal B(E) \right) \, \mathcal N_N^{\omega}(\mathrm{d} E) \, \right| \label{Gleichung beweis verallg BEC 2 line 1} \\ & \qquad + \, \left|\, \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E) \mathbb\, \big[ \mathcal N_N^{\omega}(\mathrm{d} E) - \mathcal N_{\infty}(\mathrm{d} E) \big] \, \right| \label{Gleichung beweis verallg BEC 2 line 2} \ . \end{align} % For the term in line~\eqref{Gleichung beweis verallg BEC 2 line 1} we get $\mathds{P}$-almost surely, using that $\mathds{P}$-almost surely $\mu_N^{\omega}$ converges to $0$ and \eqref{Gleichung Bedingung mu aequivalent}, \begin{align*} & \lim\limits_{N \to \infty} \left| \, \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E)\dfrac{\mathrm{e}^{\beta E } - \mathrm{e}^{\beta ( E - \mu_N^{\omega} ) }}{\left( \mathrm{e}^{\beta ( E - \mu_N^{\omega} ) } - 1 \right) \cdot \Big( \mathrm{e}^{\beta E } - 1 \Big)} \, \mathcal N_N^{\omega}(\mathrm{d} E) \, \right| = 0 \ . \end{align*} The term in line \eqref{Gleichung beweis verallg BEC 2 line 2} $\mathds{P}$-almost surely converges to zero for $N \to \infty$ by vague convergence. Next, we obtain, for all $E_2 > \epsilon$ and all $N \in \mathds N$, \begin{align*} \int\limits_{(\epsilon,\infty)} &\mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ = \, & \int\limits_{(\epsilon,E_2]} \mathcal B(E-\mu_N^{\omega})\, \mathcal N_N^{\omega} (\mathrm{d} E) + \int\limits_{(E_2,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \ . \end{align*} % On the one hand, by \eqref{lim int NN int N infty} we have $\mathds{P}$-almost surely, % \begin{align*} \limsup\limits_{N \to \infty} \int\limits_{(\epsilon,E_2]} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) & \le \lim\limits_{N \to \infty} \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ & = \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \ . \end{align*} % As for the second integral, we obtain $\mathds{P}$-almost surely, % \begin{align*} \begin{split} \limsup\limits_{N \to \infty} \int\limits_{(E_2,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) & \le \limsup\limits_{N \to \infty} \int\limits_{[E_2,\infty)} \mathcal B(E-\epsilon/2) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ & \le \beta\pi^{-1} \int\limits_{E_2}^{\infty} E^{1/2} \big[\mathcal B(E-\epsilon/2)\big]^{2} \mathrm{e}^{\beta(E - \epsilon/2)} \, \mathrm{d} E \end{split} \end{align*} % where the last step is as in the proof of Lemma~\ref{Lemma wegen vager statt schwacher Konvergenz} (with $\mu = \epsilon/2$). We conclude that \begin{align*} \limsup\limits_{N \to \infty} &\int\limits_{(\epsilon,\infty)}\mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ &\le \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) + \beta\pi^{-1/2}\int\limits_{E_2}^{\infty} E^{1/2} \big[\mathcal B(E-\epsilon/2)\big]^2 \mathrm{e}^{\beta(E - \epsilon/2)} \, \mathrm{d} E \end{align*} for all $E_2 > 0$ and hence \begin{align*} \limsup\limits_{N \to \infty} &\int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ \le \, & \lim\limits_{E_2 \to \infty} \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \\ & + \, \lim\limits_{E_2 \to \infty} \beta\pi^{-1/2}\int\limits_{E_2}^{\infty} E^{1/2} \big[\mathcal B(E-\epsilon/2)\big]^2 \mathrm{e}^{\beta(E - \epsilon/2)} \, \mathrm{d} E \\ \le \, & \lim\limits_{E_2 \to \infty} \int\limits_{[\epsilon/2,2E_2]} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \\ \le \, & \int\limits_{(\epsilon,\infty)} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) + \dfrac{2}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(\epsilon) \ . \end{align*} On the other hand, for all $E_2 > \epsilon$ and all $N \in \mathds N$, \begin{align*} \int\limits_{(\epsilon,\infty)} &\mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ \ge \, & \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) - \int\limits_{[\epsilon/2,\epsilon]} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \ . \end{align*} % For the first integral, by \eqref{lim int NN int N infty}, $\mathds{P}$-almost surely % \begin{align*} \lim\limits_{N \to \infty} \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) & = \int\limits_{\mathds R} g_{\epsilon}^{(E_2)}(E) \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \\ & \ge \int\limits_{(\epsilon,E_2]} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \ . \end{align*} % Since $\mu_N^{\omega}$ converges $\mathds{P}$-almost surely to zero and $\, \mathcal N_N^{\omega}$ converges $\mathds{P}$-almost surely vaguely to $\mathcal N_{\infty}$, the second integral $\mathds{P}$-almost surely converges to % \begin{align*} \limsup\limits_{N \to \infty} &\int\limits_{[\epsilon/2,\epsilon]} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ \le \, & \limsup\limits_{N \to \infty} \int\limits_{[\epsilon/2,\epsilon]} g_{\epsilon}^{(E_2)}(E) \mathcal B(E-\epsilon/4) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ \le \, & \mathcal B(\epsilon/4) \int\limits_{\mathds R} g_{\epsilon}^{(\epsilon)}(E) \, \mathcal N_{\infty} \, (\mathrm{d} E) \\ \le \, & \dfrac{4}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(2 \epsilon) \ . \end{align*} % We conclude that, $\mathds{P}$-almost surely, % \begin{align*} \liminf\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \ge \int\limits_{(\epsilon,E_2]} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) - \dfrac{4}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(2 \epsilon) \end{align*} for all $E_2 > \epsilon$ and hence \begin{align*} \liminf\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega})\, \mathcal N_N^{\omega} (\mathrm{d} E) \ge \int\limits_{(\epsilon,\infty)} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) - \dfrac{4}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(2 \epsilon) \ . \end{align*} Finally, with Theorem~\ref{Lifshitz Auslaufer one dimensional}, we obtain % \begin{align*} \lim\limits_{\epsilon \searrow 0} \dfrac{4}{\beta \epsilon} \mathcal N_{\infty}^{\mathrm{I}}(2 \epsilon) \le \lim\limits_{\epsilon \searrow 0} \dfrac{4}{\beta \epsilon} \widetilde M \dfrac{4! (2 \epsilon)^2}{(\pi\nu)^4} = 0 \ , \end{align*} % which, taking Lemma~\ref{finite critical density in LSmodel} into account, shows that $\mathds{P}$-almost surely % \begin{align*} \begin{split} \lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) & = \lim\limits_{\epsilon \searrow 0} \liminf\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ & = \lim\limits_{\epsilon \searrow 0} \int\limits_{(\epsilon,\infty)} \mathcal B(E) \, \mathcal N_{\infty} (\mathrm{d} E) \\ & = \rho_c(\beta) \ . \end{split} \end{align*} % \end{proof} Finally, we present a proof of generalized BEC and we follow in parts the proof in \cite{lenoble2004bose}. \begin{proof}[Proof of Theorem \ref{TheoremGeneralizedBEC}] Assume firstly that $\rho \ge \rho_c(\beta)$: According to Lemma \ref{Satz Konvergenzverhalten mu}, the sequence $(\mu^{\omega}_{N})_{N=1}^{\infty}$ converges to $0$ $\mathds{P}$-almost surely. Also, for all $\epsilon > 0$, all $N \in \mathds N$ and $\mathds{P}$-almost all $\omega \in \Omega$ one has \begin{align*} \rho = \int\limits_{(0,\epsilon]} \mathcal B(E-\mu_N^{\omega}) \,\mathcal N_N^{\omega} (\mathrm{d} E) + \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \,\mathcal N_N^{\omega} (\mathrm{d} E) \end{align*} % and hence \begin{align} \label{Gleichung beweis verallg BEC} \begin{split} \rho_0 (\beta) & = \lim\limits_{\epsilon \searrow 0} \liminf\limits_{N \to \infty} \int\limits_{(0,\epsilon]} \mathcal B(E-\mu_N^{\omega}) \,\mathcal N_N^{\omega} (\mathrm{d} E) \\ & = \rho - \lim\limits_{\epsilon \searrow 0} \limsup\limits_{N \to \infty} \int\limits_{(\epsilon,\infty)} \mathcal B(E-\mu_N^{\omega}) \,\mathcal N_N^{\omega} (\mathrm{d} E) \ . \end{split} \end{align} % Consequently, by~\eqref{LemmaA6limsup rho_c}, % \begin{align*} \rho_0(\beta) = \rho - \rho_c(\beta) % \end{align*} % holds $\mathds{P}$-almost surely, implying the statement. In a next step assume that $\rho < \rho_c(\beta)$: According to Lemma~\ref{Satz Konvergenzverhalten mu}, the sequence $(\mu^{\omega}_{N})_{N=1}^{\infty}$ $\mathds{P}$-almost surely converges to a limit $\widehat \mu < 0$. Consequently, $\mathds{P}$-almost surely there exists a $\delta > 0$ such that $- \mu_N^{\omega} > \delta$ for all but finitely many $N \in \mathds N$. Hence, $\mathds{P}$-almost surely, with $g_{\epsilon, \epsilon}(E)$ defined as in \eqref{definition g mathcal E E_2 E}, \begin{align*} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \dfrac{1}{N} \sum\limits_{j : E_N^{j,\omega} \le \epsilon} n_N^{j,\omega} & = \rho^{-1} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \int\limits_{(0,\epsilon]} \mathcal B(E-\mu_N^{\omega}) \,\mathcal N_N^{\omega} (\mathrm{d} E) \\ & \le \rho^{-1} \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \int\limits_{(0,\epsilon]} \mathcal B(E+\delta) \,\mathcal N_N^{\omega} (\mathrm{d} E) \\ & \le \rho^{-1} \mathcal B(\delta) \lim\limits_{\epsilon \searrow 0} \lim\limits_{N \to \infty} \int\limits_{\mathds R} g_{\epsilon,\epsilon}(E) \, \mathcal N_N^{\omega} (\mathrm{d} E) \\ & = \rho^{-1} \mathcal B(\delta)\lim\limits_{\epsilon \searrow 0} \int\limits_{\mathds R} g_{\epsilon,\epsilon}(E) \, \mathcal N_{\infty} (\mathrm{d} E) \\ & \le \rho^{-1} \mathcal B(\delta) \lim\limits_{\epsilon \searrow 0} \mathcal N_{\infty}^{\mathrm{I}} (2 \epsilon) \\ & = 0 \end{align*} % employing $\mathds P$-almost sure vague convergence of $\mathcal N_N^{\omega}$ to $\mathcal N_{\infty}$ and Theorem~\ref{Lifshitz Auslaufer one dimensional}. \end{proof} \section{Introduction} In this paper, we study Bose--Einstein condensation (BEC)~\cite{PaperEinstein1,PaperEinstein2} in the Luttinger--Sy (LS) model with finite interaction strength~\cite{luttinger1973low,luttinger1973bose}. Conventional BEC refers to a macroscopic occupation of a one-particle ground state. If the particles do not interact with each other (ideal Bose gas), this one-particle state is the ground state of the one-particle Hamiltonian~\cite{PO56}. In contrast to this, generalized BEC requires a macroscopic occupation of an arbitrarily narrow energy interval of one-particle states~\cite{casimir1968bose, van1982generalized, van1983condensation, van1986general, van1986general2,ZagBru,girardeau1960relationship, jaeck2010nature}. More specifically, generalized BEC is then classified into three different types: Type-I or type-II BEC is present whenever finitely or infinitely many one-particle states in this narrow energy interval are macroscopically occupied; generalized BEC without any one-particle state in this energy interval being macroscopically occupied is defined as type-III. In an ideal Bose gas, to prove generalized BEC (which is done by showing that some critical density is finite) is much simpler than proving macroscopic occupation of the one-particle ground state since for this one has to estimate the gaps between consecutive eigenvalues of the one-particle Hamiltonian~\cite{LenobleZagrebnovLuttingerSy, zagrebnov2007bose, jaeck2010nature}. Note here that external potentials may lead to a generalized BEC by altering the density of states \cite{lenoble2004bose}. However, only very limited results regarding the type of BEC in random external potentials are available~\cite{jaeck2010nature}. Actually, to the best of our knowledge, the type of BEC has so far been determined rigorously for the LS model with infinite interaction strength only, where it is of type-I~\cite{LenobleZagrebnovLuttingerSy, zagrebnov2007bose}. The LS model is a one-dimensional, continuous model with a random Hamiltonian which is the sum of kinetic energy (described by the Laplacian) and a random point potential. Here, a Poisson process on the real line generates a sequence of points. At all these points we attach a $\delta$-function of mass $\gamma>0$. This $\gamma$ has the meaning of the interaction strength. Formally setting $\gamma=\infty$ one arrives at the LS model with infinite interaction strength, which has been investigated in~\cite{luttinger1973low,luttinger1973bose,LenobleZagrebnovLuttingerSy, zagrebnov2007bose}, see also~\cite{KPS18}. The paper is organized as follows: In Section~\ref{SecPrelim} we formulate the model in terms of its Hamiltonian which itself is obtained from an associated quadratic form. We recall well-known facts regarding the (limiting) integrated density of states, define (generalized) BEC and state the known theorem on the existence of generalized BEC. In Section~\ref{secMainResults} we then present our main result, Theorem~\ref{LSM ns main theorem}, which leads to a proof of almost sure macroscopic occupation of the one-particle ground state, see Theorem~\ref{MacroscopicOccupationGroundstate}. Auxiliary results are summarized in the appendix, to which we refer throughout the manuscript. \subsection*{Conclusion}{In this paper we proved, for the first time, that the one-particle ground state in the Luttinger--Sy model with non-infinite interaction strength is macroscopically occupied, see Theorem~\ref{MacroscopicOccupationGroundstate}. This follows from Theorem~\ref{LSM ns main theorem}, where we show that the probability of macroscopic occupation of the ground state is arbitrarily close to $1$, uniformly in the number of particles. It seems plausible but we are not able to prove that only the ground state is macroscopically occupied; this would then yield a type-I BEC. Nevertheless, in Corollary~\ref{CorollaryMinimal} we do prove that highly excited one-particle eigenstates are arbitrarily close to not being occupied with a probability arbitrarily close to $1$. \subsection*{Acknowledgement}{It is our pleasure to thank Werner Kirsch and Hajo Leschke for interesting discussions and useful remarks that led to an improvement of the manuscript.}
\section{Introduction} \label{sec:intro} Kernel methods \citep{Sch2003Learning,shawe2000support,Steinwart2008SVM} have proven to be powerful in a variety of machine learning tasks, e.g., classification \citep{Vapnik2000The}, regression \citep{drucker1997support}, clustering \citep{dhillon2004kernel}, dynamical systems \citep{boots2013hilbert}, and casual inference \citep{mitrovic2018causal}. They employ a so-called \emph{kernel} function $k(\cdot, \cdot): \mathbb{R}^d \times \mathbb{R}^d \rightarrow \mathbb{R}$ to compute the similarity between any two samples $\bm x_i$, $\bm x_j \in \mathbb{R}^d$ such that \begin{equation*} k(\bm x_i, \bm x_j) = \langle \phi(\bm x_i), \phi(\bm x_j) \rangle_{\mathcal{H}} \,, \end{equation*} where $\phi: \mathcal{X} \rightarrow \mathcal{H}$ is a non-linear feature map transforming elements of input spaces $\mathcal{X}$ into a reproducing kernel Hilbert space (RKHS) $\mathcal{H}$. In practical use, there is no need to acquire the explicit formulation of such mapping. Instead, what we should obtain is only the inner product of two vectors in the feature space by the \emph{kernel}, a.k.a ``kernel trick". Generally, the performance of kernel methods largely depends on the choice of the kernel. Traditional kernel methods often adopt a classical kernel, e.g., Gaussian kernel or sigmoid kernel for characterizing the relationship among data points. Empirical studies suggest that these traditional kernels are not sufficiently flexible to depict the domain-specific characteristics of data affinities or relationships. To address such limitation, several routes have been explored. One way is to design sophisticated kernels on specific tasks such as applying optimal assignment kernels \citep{Kriege2016On} to graph classification, developing a kernel based on triplet comparisons \citep{kleindessner2017kernel}, or even breaking the \fh{restriction} of positive definiteness on the traditional kernel \citep{Cheng2004Learning,Schleif2015Indefinite,Ga2016Learning,Huang2016Indefinite}. Apart from these well-designed kernels, \fh{a series of} research studies aim to automatically learn effective and flexible kernels from data, known as \emph{learning kernels}. Algorithms for learning kernels can be roughly grouped into two categories: parametric kernel learning and non-parametric kernel learning. \subsection{Review of Kernel Learning} \label{sec:review} In parametric kernel learning, the learned kernel $k(\cdot,\cdot)$ or the kernel matrix $\bm K = [k(\bm x_i, \bm x_j)]_{n \times n}$ on the training data is assumed to admit a specific parametric form, and then the relevant parameters are learned according to the given data. \changed{M2.4}{\link{R2.4}}{The earliest work is proposed by \cite{Lanckriet2004Learning}}, in which they consider training an SVM along with optimizing a linear combination of \changed{M1.2}{\link{R1.2}}{several pre-given positive semi-definite (PSD) matrices $\{ \underline{\bm K}_t \}_{t=1}^s$} subject to a bounded trace constraint, \changed{M2.3.1}{\link{R2.3}}{i.e., $\bm K = \sum_{t=1}^{s}\mu_t \underline{\bm K}_t$ with $\mathrm{tr}(\bm K) \leq c$. Specifically, to ensure the learned kernel matrix valid, they impose a PSD constraint on $\bm K$ in two implementation ways: one is directly using $\bm K \in \mathcal{S}^n_+$, where $\mathcal{S}^n_+$ denotes the positive semi-definite cone; the other is considering a nonnegaitve linear combination, i.e., a nonnegative constraint on $\mu_t$ with $\mu_t \geq 0$.} In the above two schemes, the kernel (matrix) learning is transformed to learn the combination weights. Accordingly, the parameters in SVM and the weights in their model can be learned by solving a semi-definite programming optimization problem in a unified framework. The above parametric kernel learning framework spawns the new field of \emph{multiple kernel learning} (MKL) \citep{bach2004multiple,Varma2009More}. It aims to learn a good combination of some predefined kernels (or kernel matrices) for rich representations. For example, the weight vector $\bm \mu =[\mu_1, \mu_2, \dots, \mu_s]^{\!\top}$ can be restricted by the conic sum (i.e., $\mu_t \geq 0$), the convex sum (i.e., $\mu_t \geq 0$ and $\sum_{t=1}^{s}\mu_t = 1$), or various regularizers such as $\ell_1$ norm, mixed norm, and entropy-based \fh{formulations}, see a survey \citep{G2011Multiple}. By doing so, MKL would generate a ``broader" kernel to enhance the representation ability for data. Based on the idea of MKL, there are several representative approaches to learn effective kernels by exploring the data information, including: i) hierarchical kernel learning (HKL) \citep{bach2008exploring,jawanpuria2015generalized} learns from a set of base kernels assumed to be embedded on a directed acyclic graph; \changed{M2.5.1}{\link{R2.5}}{ii) spectral mixture models \citep{argyriou2005learning,Wilson2013Gaussian} aim to learn the spectral density of a kernel in a parametric scheme for discovering flexible statistical representations in data;} \changed{M2.2}{\link{R2.2}}{iii) kernel target alignment \citep{cristianini2002kernel,Cortes2012Algorithms} seeks for the ``best" kernel matrix by maximizing the similarity between $\bm K$ and the ideal kernel $\bm y \bm y^{\!\top}$ with the label vector $\bm y$. Here the used ideal kernel can directly recognize the training data with 100\% accuracy, and thus can be used to guide the kernel learning task. Current works on this task often assume that the learned kernel matrix $\bm K$ is in a parametric way, e.g., an MKL or mixtures of spectral density form, see \citep{Lanckriet2004Learning,AmanNIPS2016} and references therein.} Instead of assuming specific parametric-forms for the learned kernel, the nonparametric kernel learning framework acquires a positive semi-definite (PSD) kernel matrix in a data-specific manner, which are often more flexible than parametric kernel learning. Typical examples include: \changed{M2.3.2}{\link{R2.3}}{\cite{Lanckriet2004Learning} consider $\bm K \in \mathcal{S}_+^n$ in their optimization problem without extra parametric forms on $\bm K$ in a transductive setting, which results in a nonparametric kernel learning framework.} Such nonparametric kernel learning model is further explored by learning a low-rank kernel matrix \citep{kulis2009low}, imposing the pairwise constraints \citep{Hoi2007Learning,Zhuang2011Anonk} with side/prior information, or using the local geometry information and side-information \citep{Lu2009Geometry}. \changed{M2.5.2}{\link{R2.5}}{Besides, \cite{Cheng2005Learning} introduce a hyper reproducing kernel Hilbert space (hyper-RKHS), of which each element is a kernel function. Hence, the kernel can be learned in this space from a broader class without specifying its parametric form, which allows for significant model flexibility.} \cite{Jain2012Metric} investigate the equivalence between nonparametric kernel learning and Mahalanobis metric learning, and accordingly propose a nonparametric model seeking for a PSD matrix $\bm W$ in a learned kernel $\phi(\bm x)^{\!\top} \bm W \phi(\bm x')$ via the LogDet divergence. \subsection{Contributions} From the above discussions, we observe that, most studies recognize the significance of directly learning nonparametric kernels in a broad class/space. Nevertheless, it appears intractable to seek a good trade-off between the model complexity and flexibility. Furthermore, most nonparametric kernel learning works utilize the semi-definite programming to tackle the PSD constraint. This scheme leads to a huge time complexity, which makes these approaches infeasible to real world large scale applications. In this paper, we attempt to seek a suitable solving space for nonparametric kernel learning and scale it to large scale cases. We propose a \textbf{D}ata-\textbf{A}daptive \textbf{N}onparametric \textbf{K}ernel (DANK) learning framework, in which \changed{M2.22}{\link{R2.22}}{a data adaptive matrix $\bm F \in \mathbb{R}^{n \times n}$} is imposed on a pre-given kernel matrix $\bm K$ in a point-wise strategy, i.e., $\bm F \odot \bm K$, where $\odot$ denotes the Hadamard product between two matrices. Since we do not specify the formulation of the adaptive matrix $\bm F$, each entry in $\bm F$ can be directly and flexibly learned from the data. \fh{This} \emph{formulation-free} strategy contributes to adequate model flexibility as a result. Specifically, the design for $\bm F$ is independent of the pre-given kernel matrix. So we can only restrict the flexibility of $\bm F$ to control the complexity of the whole model, which makes it possible to seek a good trade-off between model flexibility and complexity. Here we take a synthetic classification dataset \emph{clowns} to illustrate this. The initial kernel matrix $\bm K$ is given by \changed{M1.4}{\link{R1.4}}{the classical Gaussian kernel $k(\bm x_i, \bm x_j) = \exp(-\| \bm x_i - \bm x_j \|_2^2/2\sigma^2)$ with the width $\sigma$.} Figure~\ref{flexi} shows that, in the left panel, the baseline SVM with an \fh{inappropriate} $\sigma=1$ cannot precisely adapt to the data, resulting in an inaccurate classification boundary. However, based on the same $\bm K$, by optimizing the adaptive matrix $\bm F$, our DANK model shows good flexibility to fit the complex data distribution, leading to a desirable decision surface. Comparably, in the right panel, even under the condition that $\sigma$ is well tuned via cross validation, the baseline SVM fails to capture the local property of the data (see in the brown ellipses). Instead, by learning $\bm F$, our DANK model still yields a more accurate boundary than SVM to fit the data points. Regarding to the model complexity, \cite{torr2011locally} indicates that a decision surface that is too flexible would tend to overfit the data. It is better to prohibit locally linearly separable. We find that, our classification boundary is approximately linear in a small region, which effectively controls the model complexity. \begin{figure} \centering \subfigure[$\sigma=1$]{\label{sigma01} \includegraphics[width=0.352\textwidth]{Figures/flex1.pdf}} \hspace{0.5cm} \subfigure[$\sigma=0.07$ by cross validation]{\label{sigma1} \includegraphics[width=0.352\textwidth]{Figures/Visio-SOC-MO.pdf}} \caption{Classification boundaries of SVM (in blue dash line) and our DANK model (in red solid line) on the \emph{clowns} dataset: (a) using the Gaussian kernel with $\sigma = 1$; (b) using the Gaussian kernel with $\sigma=0.07$ by cross validation. }\label{flexi} \end{figure} The main contributions of this paper lie in the following three folds: i) We propose a data-adaptive nonparametric kernel learning framework termed ``DANK" to enhance the model flexibility and data adaptivity, which is then seamlessly embedded to SVM and SVR for classification and regression tasks; ii) The DANK model and the induced classification/regression model can be formulated as a max-min optimization problem in a unified framework. The related objective function is proven to be gradient-Lipschitz continuous, and thus can be directly solved by a projected gradient method with Nesterov's acceleration; iii) By decomposing the entire optimization problem into several smaller easy-to-solve subproblems, we propose an accelerated strategy to handle the scalability issue that appears in our nonparametric kernel learning framework. The effectiveness of our decomposition-based scalable approach is demonstrated by both theoretical and empirical studies. The experimental results on several classification and regression benchmark datasets demonstrate the \fh{effectiveness} of the proposed DANK framework over other representative kernel learning based methods. This paper is an extension of our previous conference work \citep{Liu2018AAAIme}. The improvements of this paper are mainly in the following four aspects. First, in model formulation, we impose an additional low rank constraint and a bounded regularizer on $\bm F$, which makes the original model \fh{feasible to} out-of-sample extensions. Apart from SVM to which our DANK model is embedded for classification, the proposed DANK model is also extended to SVR for regression tasks. Second, we develop a Nesterov's smooth method to solve the designed optimization problem, which requires the discussion on its gradient-Lipschitz continuous property. Third, in large-scale situations, we conduct a decomposition-based scalable approach on DANK with theoretical guarantees and experimental validation. Lastly, we provide more experimental results on popular benchmarks. \subsection{Notation} \label{sec:notation} We start with definitions of the notation used throughout this paper. {\bf Matrices, vectors and elements:} We take $\bm A$, $\bm a$ to be a matrix and a vector, of which elements are $A_{ij}$ and $a_i$, respectively. Denote $\bm I_n$ as the $n \times n$ identity matrix, $\bm 0$ as a zero matrix or vector with the appropriate size, and $\bm 1_n$ as the $n$-dimensional vector of all ones. {\bf Sets:} The set $\{1,2,\cdots,n\}$ is written as $[n]$. We call $\{\mathcal{V}_1, \mathcal{V}_2, \cdots, \mathcal{V}_s\}$ an $s$-partition of $[n]$ if $\mathcal{V}_1 \cup \cdots \cup \mathcal{V}_s = [n]$ and $\mathcal{V}_p \cap \mathcal{V}_q = \emptyset $ for $p \neq q$. Let $|\mathcal{V}|$ denote the cardinality of the set $\mathcal{V}$. We take the notation $\mathcal{S}^n$ as the set of $n \times n$ symmetric matrices and $\mathcal{S}^n_+$ as the $n \times n$ PSD cone. {\bf Singular value decomposition (SVD):} Let $\bm A \in \mathbb{R}^{n \times d}$ and $r = \text{rank}(\bm A)$. A (compact) singular value decomposition (SVD) is defined as $\bm{A} = {\bm U}{\bm \Sigma}{\bm V}^{\!\top} = \sum_{i=1}^{r} \sigma_{i}(\bm A) \bm u_i \bm v^{\!\top}_i$, where $\bm U$, $\bm \Sigma$, $\bm V$ are an $n \times r$ column-orthogonal matrix, an $r \times r$ diagonal matrix with its diagonal element $\sigma_{i}(\bm A)$, and a $d \times r$ column-orthogonal matrix, respectively. If $\bm A$ is PSD, then $\bm U = \bm V$. Accordingly, the singular value soft-thresholding operator is defined as $\mathcal{J}_{\tau}(\bm A)=\bm U_{\!\bm A} \mathcal{S}_{\tau}(\bm \Sigma_{\bm A}){\bm V}^{\!\top}_{\bm A}$ with the SVD: $\bm{A=U}{\bm \Sigma}{\bm V}^{\top}$ and the soft-thresholding operator is $\mathcal{S}_{\tau}(A_{ij})=\text{sign}(A_{ij})\max(0, |A_{ij} |-\tau)$. {\bf Matrix norms:} We use four matrix norms in this paper {\centering Frobenius norm: $\| \bm A \|_{\F} = \sqrt{\sum_{i,j} A_{ij}^2 } = \sqrt{\sum_{i}\sigma_i^2(\bm A)}$}\,.\\ Manhattan norm: $\| \bm A \|_{\M} = \sum_{i,j} |A_{ij}| \leq c'\sqrt{n} \| \bm A \|_{\text{F}} $, where $c'$ is some constant.\\ Spectral norm: $\| \bm A \|_2 = \max \limits_{\| \bm x \|_2 = 1} \| \bm A \bm x \|_2 = \sigma_{\max}(\bm A)$ \\ Nuclear norm: $\| \bm A \|_* = \sum_{i} \sigma_i(\bm A)$.\\ Any square matrix satisfies $\mathrm{tr}(\bm A ) \leq \| \bm A \|_*$. If $\bm A$ is PSD, then $\mathrm{tr}(\bm A ) = \| \bm A \|_*$. \subsection{Paper Organization} In Section \ref{sec:knplsvm}, we introduce the proposed DANK model embedded in SVM. The model optimization is presented in Section \ref{sec:knplopt}: Section~\ref{sec:gradl} studies the gradient-Lipschitz continuous property and Section~\ref{sec:nest} applies Nesterov's smooth optimization method to solve our model. Scalability of our nonparametric kernel model is addressed in Section \ref{sec:knplapp}. Besides, in Section \ref{sec:knplsvr}, we extend our DANK model to SVR for regression. The experimental results on popular benchmark datasets are presented in Section \ref{sec:experiment}. Section \ref{sec:conclusion} concludes the entire paper. Proofs are provided in the Appendices. \section{The DANK Model in SVM} \label{sec:knplsvm} In this section, we briefly review the SVM formulation and then incorporate the proposed DANK model into SVM for classification. We focus on binary classification problems for the ease of description and it can be extended to multi-classification tasks. We begin with the hard-margin SVM for linearly separable binary classification tasks. Denote $\mathcal{X} \subseteq \mathbb{R}^d$ as a compact metric space of features, and $\mathcal{Y}=\{ -1, 1\}$ as the label space, \changed{M2.23}{\link{R2.23}}{we assume that a sample set $\mathcal{Z} = \{ (\bm x_i, y_i) \}_{i=1}^n $ is drawn from a non-degenerate Borel probability measure $\rho$ on $\mathcal{X} \times \mathcal{Y}$.} The hard-margin SVM aims to learn a linear classifier $f(\bm x; \bm w, b) = \mbox{sign}(\bm w^{\!\top}\bm x + b) \in \{ -1, +1\}$ with $\bm w$ and $b$ that determine the decision hyperplane. This is conducted by maximizing the distance between the nearest training samples of the two classes (a.k.a the \emph{margin} $\gamma = 1/\| \bm w \|_2$), as this way reduces the model generalization error \citep{Vapnik2000The}. While the data are not linearly separable in most practical settings, the hard-margin SVM is subsequently extended to a soft-margin SVM with an implicit mapping $\phi(\cdot)$ for a non-linear decision hyperplane. Mathematically, the soft-margin SVM aims to maximize the margin $\gamma$ (or minimize $\| \bm w \|_2^2$) and minimize the slack penalty $\sum_{i=1}^{n} \xi_i$ with the following formulation \begin{equation}\label{primalsvm} \begin{split} &\min \limits_{{\bm w},b, \bm \xi} \frac{1}{2}\| {\bm w} \|_2^2 + C \sum_{i=1}^{n} \xi_i \\ &\mbox{s.t.} ~~ y_i (\bm w^{\!\top} \phi(\bm x_i)+b) \geq 1 - \xi_i,~ \xi_i \geq 0,~ i=1,2,\cdots,n \,, \end{split} \end{equation} where $\bm \xi = [\xi_1, \xi_2, \cdots, \xi_n]^{\!\top}$ is the slack variable and $C$ is the balance parameter. As illustrated by \cite{Vapnik2000The}, the dual form of problem \eqref{primalsvm} is given by \begin{equation}\label{dualSVM} \begin{split} &\mathop{\mathrm{max}}\limits_{{\bm \alpha}}~~ \bm{1}^{\!\top}{\bm \alpha} - \frac{1}{2}{\bm \alpha}^{\!\top}\bm{YKY}{\bm \alpha} \\ &\mbox{s.t.} ~~\bm 0\leq {\bm \alpha} \leq C \bm{1},~ {\bm \alpha}^{\!\top}\bm{y}=0\,, \end{split} \end{equation} where $\bm Y=\diag(\bm y)$ is the label matrix and $\bm K = [k(\bm x_i, \bm x_j)]_{n \times n}$ is the Gram matrix, satisfying $k(\bm x_i, \bm x_j) = \langle \phi(\bm x_i), \phi(\bm x_j) \rangle_{\mathcal{H}}$. Since problem~\eqref{dualSVM} is convex, strong duality holds by Slater's condition \citep{boyd2004convex}. The optimal values of the primal and dual soft-margin SVM problems will be equal. Accordingly, if we attempt to learn the kernel matrix in the dual form of SVM in problem~\eqref{dualSVM}, the objective function value of the primal problem in problem~\eqref{primalsvm} would decrease, which in turn increases the margin $\gamma$. \changed{M3.2}{\link{R3.2}}{Theoretically, for a fixed kernel, with probability at least $1-\delta$, the estimation error (namely the gap between empirical error and expected error) of a SVM classifier with the margin $\gamma$ is at most $\sqrt{\mathcal{O}(1/\gamma^2-\log \delta)/n}$ \citep{koltchinskii2002empirical}. If we consider the learned kernel in some \emph{finite}/\emph{infinite} kernel familiy $\mathcal{K}$, the estimation error can be bounded by $\sqrt{\mathcal{O}(\log |\mathcal{K}| + 1/\gamma^2-\log \delta)/n}$ \citep{srebro2006learning}, where $|\mathcal{K}|$, the cardinality, is a certain measure of the complexity of the kernel class. We find that, to achieve a tight bound, a learned SVM classifier is better to admit a large margin $\gamma$, and the hypothesis space cannot be arbitrarily enlarging.} Based on above analyses, we conduct the nonparametric kernel learning task in our DANK model by introducing an adaptive matrix $\bm F$ into problem \eqref{dualSVM}, that is \begin{equation}\label{mains} \begin{split} \min \limits_{\bm{F}\in \mathcal{F}}~ \max\limits_{\bm \alpha \in \mathcal{A}} ~\bm{1}^{\!\top}\!{\bm \alpha} -\frac{1}{2} {\bm \alpha}^{\!\top}\bm{Y}\big(\bm{F}\!\odot\!\bm{K}\big)\bm{Y}{\bm \alpha}\,, \end{split} \end{equation} where $\mathcal{F}$ is the feasible region of $\bm F \in \mathbb{R}^{n \times n}$ and the constraint for the standard SVM is expressed as $$\mathcal{A}=\{ {\bm \alpha}\in \mathbb{R}^n: {\bm \alpha}^{\top}\bm{y}=0,~\bm 0\leq {\bm \alpha} \leq C\bm{1} \}.$$ Accordingly, optimizing $\bm F$ yields a flexible kernel matrix $\bm F \odot \bm K$, which is able to increase the margin, and further allows for greater model flexibility with a tighter estimation error as well as a lower generalization error when compared to the original SVM classifier. In our DANK model, since we do not specify the formulation of $\bm F$, the solution space $\mathcal{F}$ is enlarged to boost the model flexibility and capacity of fitting diverse data patterns. However, arbitrarily enlarging the solution space $\mathcal{F}$ could bring in two potential issues. One is that the generated decision boundary that is too flexible would tend to overfit the data due to a large capacity of $\mathcal{F}$. The other problem is significant difficulty in out-of-sample extensions \citep{Bengio2004Out,fanuel2017positive,Pan2016Out}. That is, the flexible kernel matrix $\bm{F} \odot \bm K$ is learned from the training data in a nonparametric manner, while the adaptive kernel matrix for test data is unknown. Such out-of-sample extension problem is a common issue in nonparametric kernel learning. To alleviate the above two issues, the learned $\bm F$ is expected to vary steadily and smoothly between any two neighboring data points in a suitable compact space, and thus can be easily extended to the adaptive matrix $\bm F'$ for test data. Intuitively speaking, when $\bm F$ is chosen as the all-one matrix, the DANK model in Eq.~\eqref{mains} degenerates to a standard SVM problem. Such all-one matrix associated with its rank-one property guides us to design the suitable space $\mathcal{F}$ in the following two aspects. First, the adaptive matrix $\bm F$ is expected to vary around the all-one matrix in a bounded region for a trade-off between the model complexity and flexibility. Second, $\bm F$ is desired to be endowed with the low rank structure enjoyed by the all-one matrix. Mathematically, our DANK model is \begin{equation}\label{main} \begin{split} &\min \limits_{\bm{F}\in \mathcal{S}^n_+} \max\limits_{\bm \alpha \in \mathcal{A}} ~\bm{1}^{\!\top}\!{\bm \alpha} -\frac{1}{2} {\bm \alpha}^{\!\top}\bm{Y}\big(\bm{F}\!\odot\!\bm{K}\big)\bm{Y}{\bm \alpha} \\ &\mbox{s.t.} ~~ \| \bm{F} - \bm{1}\bm{1}^{\!\top} \! \|_{\text{F}}^2 \leq R^2,~\mbox{rank}(\bm F) < r\,, \end{split} \end{equation} where $R$ refers to the bounded region size, $\mbox{rank}(\bm F) $ denotes the rank of $\bm F$, and $r \leq n$ is a given integer. \changed{M2.6}{\link{R2.6}}{In our DANK model, the initial kernel matrix $\bm K$ is not limited to the Gaussian kernel matrix, and can be chosen as an arbitrary PSD one.} The constraint $\bm F \in \mathcal{S}^n_+$ is given to ensure that the learned kernel matrix $\bm{F}\odot\bm{K}$ is still a PSD one\footnote{It is admitted by Schur Product Theorem \citep{Styan1973Hadamard} which relates positive semi-definite matrices to the Hadamard product.}. Since we do not specify the parametric form of $\bm F$, we can obtain a nonparametric kernel matrix $\bm F \odot \bm K$ and thus our DNAK model is nonparametric. The bounded constraint prevents $\bm F$ from dropping to a trivial solution $\bm{F}=\bm{0}_{n\times n}$. Note that, \fh{if we attempt to find a new PSD kernel matrix $\hat{\bm K}$ in an exact way such as $\| \hat{\bm K} - \bm K \|^2_{\F}$}, it would be difficult to directly estimate $\hat{\bm K}$ for test data. This is why we consider to split the representation into $\bm F$ separating from $\bm K$. \changed{M2.7}{\link{R2.7}}{Specifically, due to the non-convexity of the used rank constraint in problem~\eqref{main}, we consider the \emph{nuclear norm} $\| \cdot \|_*$ instead, which is the best convex lower bound of the non-convex rank function \citep{recht2010guaranteed} and can be minimized efficiently.} Accordingly, we relax the constrained optimization problem in Eq.~\eqref{main} to a unconstrained problem by absorbing the two original constraints to the objective function. Moreover, following the min-max approach \citep{boyd2004convex}, problem~\eqref{main} can be reformulated as \begin{equation}\label{mainrank} \begin{split} &\max\limits_{\bm \alpha \in \mathcal{A}}\min\limits_{\bm{F}\in \mathcal{S}^n_+} \bm{1}^{\!\top}\!{\bm \alpha} -\frac{1}{2} {\bm \alpha}^{\!\top}\bm{Y}\big(\bm{F}\odot \bm{K}\big)\bm{Y} {\bm \alpha} + {\eta} \| \bm{F} - \bm{1}\bm{1}^{\!\top} \|_{\F}^2 +\tau \eta \| \bm{F} \|_* \,, \end{split} \end{equation} where $\eta$ and $\tau$ are two regularization parameters. In problem~\eqref{mainrank}, the inner minimization problem with respect to $\bm{F}$ is a convex conic programming, and the outer maximization problem is a point-wise minimum of concave quadratic functions of ${\bm \alpha}$. \changed{M2.25}{\link{R2.25}}{As a consequence, problem~\eqref{mainrank} is also convex, and it satisfies strong duality as we discussed above.} Here we denote the objective function in Eq.~\eqref{mainrank} as \begin{equation*} H({\bm \alpha},\!\bm{F})=\bm{1}^{\!\top}{\bm \alpha} -\frac{1}{2} {\bm \alpha}^{\!\top}\bm{Y}\big(\bm{F}\!\odot \!\bm{K}\big)\bm{Y} {\bm \alpha} + {\eta} \| \bm{F} \!-\! \bm{1}\bm{1}^{\!\top} \! \|_{\F}^2\! +\!\tau \eta \| \bm{F} \|_*\,, \end{equation*} of which the optimal solution $({\bm \alpha}^*,\bm{F}^*)$ is a saddle point of $H({\bm \alpha},\bm{F})$ due to the property of the max-min problem~\eqref{mainrank}. It is easy to check $H({\bm \alpha},\bm{F}^*) \leq H({\bm \alpha}^*,\bm{F}^*) \leq H({\bm \alpha}^*,\bm{F})$ for any feasible $\bm \alpha$ and $\bm F$. Further, we define the following function \begin{equation}\label{falpha} h(\bm \alpha) \triangleq H({\bm \alpha},\bm{F}^*) = \min \limits_{\bm{F}\in \mathcal{S}^n_+} H({\bm \alpha},\bm{F})\,, \end{equation} which is concave since $h$ is the minimum of a sequence of concave functions. Specifically, the optimal solution $\bm F^*$ can be restricted in a bounded set $\mathcal{F}$ as demonstrated by the following Lemma. \begin{lemma}\label{fbound} Given the training data $\{ \bm x_i, y_i \}_{i=1}^n$ with labels $y_i \in \{ +1, -1 \}$ and a pre-given kernel matrix $\bm K$, there exists an equivalence of problem \eqref{mainrank} with \begin{equation}\label{falphab} \max\limits_{\bm \alpha \in \mathcal{A}}\min\limits_{\bm{F}\in \mathcal{S}^n_+} H(\bm \alpha, \bm F) = \max\limits_{\bm \alpha \in \mathcal{A}} \underbrace{\min\limits_{\bm{F}\in \mathcal{F}} H(\bm \alpha, \bm F) }_{\triangleq h(\bm \alpha) }\,, \end{equation} where the feasible region on $\bm F$ is defined by $\mathcal{F}:=\Big\{ \bm F \in \mathcal{S}^n_+: \lambda_{\max}(\bm F) \leq n - \frac{\tau}{2}+\frac{nC^2}{4\eta}\lambda_{\max}(\bm K) \Big\}$ as a nonempty subset of $\mathcal{S}^n_+$ and $\lambda_{\max}(\bm F)$ denotes the largest eigenvalue of $\bm F$. \end{lemma} \begin{proof} \changed{M2.8}{\link{R2.8}}{The key of the proof is to obtain the optimal solution $\bm F^*$ over $\mathcal{S}^n_+$, i.e., $\bm F^* = \argmin\limits_{\bm{F}\in \mathcal{S}^n_+} H(\bm \alpha, \bm F)$ in Eq.~\eqref{mainrank}. By virtue of the following expression\footnote{We use the formula $\bm{x}^{\!\top}\bm{A}\odot\bm{By}= \mathrm{tr}(\bm{D}_x\bm{A}\bm{D}_y\bm{B}^{\top})$ with $\bm{D}_x=\diag(\bm{x})$ and $\bm{D}_y=\diag(\bm{y})$.} \begin{equation}\label{gammadef} \frac{1}{2} {\bm \alpha}^{\!\top}\bm{Y}\big(\bm{F}\!\odot \!\bm{K}\big)\bm{Y} {\bm \alpha} = \frac{1}{4\eta}\diag({\bm \alpha}^{\top}\bm{Y})\bm{K}\diag({\bm \alpha}^{\top}\bm{Y}) \triangleq \bm \Gamma(\bm \alpha) \,, \end{equation} finding $\bm F^*$ is equivalent to consider the following problem \begin{equation}\label{Smain} \bm F^* := \argmin \limits_{\bm{F}\in \mathcal{S}^n_+}~~ -\!2 \mathrm{tr}\Big(\eta \bm \Gamma(\bm \alpha) \bm{F}\Big) + \eta \| \bm{F} - \bm 1 \bm 1^{\!\top} \|_{\mathrm{F}}^2 + \tau \eta \| \bm F \|_* \,, \end{equation} where we omit the irrelevant term $\bm 1^{\!\top}\bm \alpha$ independent of the optimization variable $\bm F$ in Eq.~\eqref{mainrank}. Further, due to the independence of $\bm \Gamma(\bm \alpha)$ on $\bm F$, problem~\eqref{Smain} can be reformulated in a compact form as} \begin{equation}\label{subF} \bm F^* = \argmin \limits_{\bm{F}\in \mathcal{S}^n_+} \| \bm{F} -\bm 1 \bm{1}^{\!\top}- \bm \Gamma(\bm \alpha)\|_\text{F}^2 + \tau \| \bm F \|_*\, \end{equation} Note that the regularization parameter $\eta$ is implicitly included in $\bm \Gamma (\bm \alpha)$. \changed{M2.9}{\link{R2.9}}{Following \citep{cai2010singular}, we can directly obtain the optimal solution of problem~\eqref{subF} with \begin{equation*} \bm F^* = \mathcal{J}_{\frac{\tau}{2}}(\bm 1 \bm{1}^{\!\top}+\bm \Gamma(\bm \alpha))\,, \end{equation*} where we use the singular value thresholding operator as the proximity operator associated with the nuclear norm, refer to Theorem 2.1 in \citep{cai2010singular} for details.} After giving the analytic solution $\bm F^*$, in the next we aim to seek its upper bound \begin{equation}\label{eigenf} \begin{split} \lambda_{\max}(\bm F^*) &= \lambda_{\max}\Big(\!\mathcal{J}_{\frac{\tau}{2}}\big(\bm 1 \bm{1}^{\!\top}\!+\! \bm \Gamma(\bm \alpha)\big)\!\Big)\! = \! \lambda_{\max}\Big(\bm 1 \bm{1}^{\!\top}\!+\! \bm \Gamma(\bm \alpha) \Big) \!-\! \frac{\tau}{2} \\ &\leq \lambda_{\max}(\bm 1 \bm{1}^{\!\top}\!) \!+\! \frac{1}{4\eta}\lambda_{\max}\Big(\diag({\bm \alpha}^{\!\top}\bm{Y})\bm{K}\diag({\bm \alpha}^{\top}\bm{Y})\Big) \!-\! \frac{\tau}{2}\\ &= n + \frac{1}{4\eta} \Big\| \diag({\bm \alpha}^{\!\top}\bm{Y})\bm{K}\diag({\bm \alpha}^{\top}\bm{Y})\Big\|_2 - \frac{\tau}{2}\\ &\leq n + \frac{1}{4\eta} \big\| \diag({\bm \alpha}^{\top}\bm{Y}) \big\|^2_2 \big\| \bm K \big\|_2 - \frac{\tau}{2}\\ &\leq n - \frac{\tau}{2}+\frac{nC^2}{4\eta}\lambda_{\max}(\bm K)\,, \end{split} \end{equation} where the first inequality uses the property of maximum eigenvalues, \emph{i.e.}, $\lambda_{\max}(\bm A + \bm B) \leq \lambda_{\max}(\bm A) + \lambda_{\max}(\bm B)$ for any $\bm A, \bm B \in \mathcal{S}^n$, and the last inequality admits by $\| \bm \alpha\|_2^2 \leq nC^2$. \end{proof} Lemma~\ref{fbound} gives the upper spectral bound of $\bm F^*$, i.e., $\bm F^*$ is bounded in $\mathcal{F}$, which is a subset of the PSD cone $\mathcal{S}_+^n$. In this case, we can directly solve $\bm F$ in the subset $\mathcal{F} \subseteq \mathcal{S}_+^n$ instead of the entire PSD cone $\mathcal{S}_+^n$. The solving space is decreased, that means, we can seek for a good trade-off between the model flexibility and complexity. \changed{M2.11}{\link{R2.11}}{Besides, our DANK model requires that the adaptive matrix $\bm F \in \mathcal{F}$ is expected to vary around the all-one matrix in a small bounded region. Hence, each element in $[\bm \Gamma(\bm \alpha)]_{ij}$ cannot be significantly larger than $1$. To this end, recall Eq.~\eqref{gammadef} and problem~\eqref{subF}, we choose $\eta \in \mathcal{O}(n)$ to ensure $\mathrm{tr}[\bm \Gamma(\bm \alpha)]$ to be in the same order with $\mathrm{tr}(\bm 1 \bm 1^{\!\top}) \in \mathcal{O}(n)$.} \begin{figure} \centering \subfigure[]{\label{ranksigma1} \includegraphics[width=0.35\textwidth]{Figures/Fvalue1.pdf}} \hspace{0.5cm} \subfigure[]{\label{ranksigma2} \includegraphics[width=0.35\textwidth]{Figures/FvalueCV.pdf}} \caption{The range of $\bm F^*$ in our DANK model with the Gaussian kernel on the \emph{clowns} dataset: (a) $\sigma = 1$; (b) $\sigma=0.1$ by cross validation. }\label{flexiF} \end{figure} Here we experimentally show the effectiveness of the introduced constraints on $\bm F$ for a trade-off between the model flexibility and complexity. Figure~\ref{flexiF} shows the range of the optimal solution $\bm F^*$ generated by our DANK model in Eq.~\eqref{mainrank} on the \emph{clowns} dataset with $\sigma=1$ (left panel) and $\sigma=0.07$ (right panel), respectively. One can see that, in these two cases, the values in $\bm F^*$ range from 0.9 to 1.1, and we obtain $\mbox{rank}(\bm F^*)=7$ (left panel) and $\mbox{rank}(\bm F^*)=9$ (right panel), respectively. Thereby, such small fluctuation on $\bm F^*$ and its low rank structure effectively control the model complexity, and thus we can easily extend $\bm F$ to test data. Regarding to the out-of-sample extension issue, given the optimal $\bm F^*$ on training data, the test data $\{ \bm{x}'_i \}_{i=1}^m$, and the initial kernel matrix for test data $\bm K' = [k(\bm x_i, \bm x'_j)]_{n \times m}$, we aim to establish the adaptive matrix $\bm F'$ for test data. To this end, we use a simple but effective technique, i.e., the reciprocal nearest neighbor scheme to acquire $\bm F'$. Formally, we first construct the similarity matrix $\bm M$ between the training data and the test data based on the nearest neighbor scheme. \changed{M2.12}{\link{R2.12}}{The used distance to find the nearest neighbor is the standard $\| \bm x_i - \bm x_j \|_2$ metric in the $d$-dimensional Euclidean space.} Assuming that $\bm x'_j$ is the $r$-th nearest neighbor of $\bm x_i$ in the set of $\{ \bm x'_t \}_{t=1}^m$, denoted as $\bm x'_j = \text{NN}_r(\bm x_i,\{ \bm x'_t \}_{t=1}^m)$. Meanwhile $\bm{x}_i$ is the $s$-th nearest neighbor of $\bm{x}'_j$ in $\{ \bm x_t \}_{t=1}^n$, denoted as $\bm{x}_i =\text{NN}_s(\bm{x}'_j,\{ \bm x_t \}_{t=1}^n)$, then the similarity matrix $\bm M \in \mathbb{R}^{n \times m}$ is defined by \begin{equation}\label{mBBPdef} M_{ij} =\frac{1}{rs},\!~\text{if}~ \bm x'_j = \text{NN}_r\left(\bm x_i,\{ \bm x'_t \}_{t=1}^m\right) \wedge \bm{x}_i =\text{NN}_s\left(\bm{x}'_j,\{ \bm x_t \}_{t=1}^n\right),\quad \forall i \in [n], j \in [m] \,, \end{equation} which is a much stronger and more robust indicator of similarity than the simple and unidirectional nearest neighborhood relationship, since it takes into account the local densities of vectors around $\bm x_i$ and $\bm x'_j$. This reciprocal nearest scheme has been extensively applied to computer vision, such as image retrieval \citep{qin2011hello} and person re-identification \citep{zhong2017re,zheng2012reidentification}. Accordingly, $\bm F'$ is given by \begin{equation*} \bm{F}'_{j} \leftarrow \bm{F}^*_{j^*},\!~\mbox{if}~ {j^*} = \argmax_{i}~ \{ M_{1j}, M_{2j}, \cdots, M_{ij}, \cdots, M_{nj} \} \, \quad \forall i \in [n]\,, \end{equation*} where $\bm M_j = [M_{1j}, M_{2j}, \cdots, M_{nj}]^{\!\top} \in \mathbb{R}^n$ describes the relationship between $\bm x'_j$ and the training data $\{ \bm x_t \}_{t=1}^n$. That is to say, if $\bm{x}_{j^*}$ is the ``optimal" reciprocal nearest neighbor of $\bm{x}'_j$ among the training data set $\{ \bm x_t \}_{t=1}^n$, the $j^*$-th column of $\bm{F}^*$ is assigned to the $j$-th column of $\bm{F}'$. By doing so, $\bm F^*$ can be directly extended to $\bm F' \in \mathbb{R}^{n \times m}$, resulting in the flexible kernel matrix ${\bm F}' \odot {\bm{K}}' $ for test data. \fh{Admittedly, we would be faced with the inconsistency if we directly extend the training kernel to the test kernel in this way.} However, in Eq.~\eqref{mainrank}, $\bm F$ is designed to vary in a small range, and is expected to smoothly vary between any two neighboring data points in $\mathcal{F}$, so the extension to $\bm F'$ on test data by \fh{this} scheme is reasonable. Further, we attempt to provide some theoretical justification for this scheme as follows. Mathematically, if \fh{$\bm x$ and $\bm x'$ are the reciprocal nearest neighbor pair}, we expect that $\| \varphi^{\!\top}(\bm x) \varphi(\bm x'_j) - \varphi^{\!\top}(\bm x') \varphi(\bm x'_j) \|_2^2 $ is small on the test data $\{ \bm x'_j \}_{j=1}^m$, where $\varphi$ is the learned implicit feature mapping such that $F_{ij}K_{ij} = \langle \varphi(\bm x_i), \varphi(\bm x_j) \rangle_{\mathcal{H}}$ on the training data. \cite{balcan2006kernels} demonstrate that, in the presence of a large margin $\gamma$, a kernel function can also be viewed as a mapping from the input space $\mathcal{X}$ into an $\tilde{\mathcal{O}}(1/\gamma^2)$ space. \begin{proposition}\label{prokernelmap} \citep{balcan2006kernels} Given $0 < \epsilon \leq 1$, the margin $\gamma$ and the implicit mapping $\varphi(\cdot)$ in SVM, then with probability at least $1-\delta$, \changed{M2.13}{\link{R2.13}}{let $d'$ be a positive integer such that $d' \geq d_0 = \mathcal{O}(\frac{1}{\gamma^2} \log \frac{1}{\epsilon \delta})$}, for any $\bm x \in \{ \bm x_i \}_{i=1}^n \subset \mathbb{R}^d$ and $\bm x' \in \{ \bm x'_i \}_{j=1}^m \subset \mathbb{R}^d$ with $d \geq d'$, we have \begin{equation*} (1-\epsilon) \| \bm x - \bm x' \|_2^2 \leq \| \varphi(\bm x) - \varphi(\bm x') \|_2^2 \leq (1+\epsilon) \| \bm x - \bm x' \|_2^2\,, \end{equation*} where the mapping $\varphi$ is a random projection following with the Gaussian distribution or the uniform distribution. \end{proposition} {\bf Remark:} When $\bm K$ is a Gaussian kernel matrix and $\bm F$ is bounded, the learned kernel associated with $\bm F \odot \bm K$ is sub-Gaussian. So the above bounds can be achieved for the sub-Gaussian distribution with a tail bound condition \citep{shi2012margin}. Regarding to $d'$, we choose the lower bound $d = d' = d_0 = \mathcal{O}(\frac{1}{\gamma^2} \log \frac{1}{\epsilon \delta})$, and thus we have $d = \mathcal{O}(\frac{1}{\gamma^2} \log \frac{1}{\epsilon \delta})$. As the margin is $\gamma = \frac{1}{\| \bm w \|_2}$ and $\| \bm w \|_2^2 \in \mathcal{O}(d)$ for $\bm w \in \mathbb{R}^d$, we have $\mathcal{O}(\frac{1}{\gamma^2} \log \frac{1}{\epsilon \delta}) = \mathcal{O}(d)$ in the same order of $d$. Hence the required condition $d \geq d'$ is satisfied. Based on the above analysis, given the ``optimal" reciprocal nearest neighbor pair $(\bm x, \bm x')$, for any test data point $\bm x'_j$ with $j \in [m]$, we have \begin{equation}\label{propmap} \begin{split} \| \varphi^{\!\top}(\bm x) \varphi(\bm x'_j) - \varphi^{\!\top}(\bm x') \varphi(\bm x'_j) \|_2^2 & \leq \| \varphi(\bm x) - \varphi(\bm x') \|_2^2 \| \varphi^{\!\top}(\bm x'_j) \varphi(\bm x'_j) \|_2^2 \\ & \leq \underbrace{\| \varphi^{\!\top}(\bm x'_j) \varphi(\bm x'_j) \|_2^2}_{\mbox{effected by $\bm F \odot \bm K$ for $\bm x'_j$}} (1+\epsilon) \underbrace{\| \bm x - \bm x' \|_2^2}_{\mbox{small}} \\ & \leq \widetilde{C} (1+\epsilon) {\| \bm x - \bm x' \|_2^2}\,, \end{split} \end{equation} where $\widetilde{C}$ is a constant since the learned kernel is bounded. This is because, first, by controlling the complexity of the solution space $\mathcal{F}$, the learned $\bm F$, of which values are around $1$, is bounded. Second, the initial kernel function is often assumed to be bounded, i.e., $\sup_{\bm x \in \mathcal{X}} k(\bm x, \bm x) < \infty$ \citep{bach2017equivalence}. So the learned kernel is bounded, and we can easily extend it to a new data $\bm x'_j$ without divergence. As a result, we can obtain a small $\| \varphi^{\!\top}(\bm x) \varphi(\bm x'_j) - \varphi^{\!\top}(\bm x') \varphi(\bm x'_j) \|_2^2$ if $\| \bm x - \bm x' \|_2^2$ is small, which is beneficial to out-of-sample extensions. And specifically, in Section~\ref{sec:validate}, we experimentally evaluate the performance of different out-of-sample extension based algorithms to validate the justification of our reciprocal neatest neighbor scheme. To sum up, we formulate the proposed DANK model embedded in SVM as a max-min optimization problem including learning the adaptive matrix $\bm F$ and standard SVM parameters in problem~\eqref{mainrank}. In the next section, we develop a smooth optimization algorithm to directly solve the DANK model in SVM. \section{Algorithm for DANK model in SVM} \label{sec:knplopt} Extra-gradient based methods can be directly applied to solve the max-min problem~\eqref{mainrank} (i.e., a convex-concave min-max problem), and have been shown to exhibit an $\mathcal{O}(1/t)$ convergence rate \citep{nemirovski2004prox}, where $t$ is the iteration number. Further, to accelerate the convergence rate, this section investigates the gradient-Lipschitz continuity of \changed{M1.5}{\link{R1.5}}{$h({\bm \alpha})$ in Eq.~\eqref{falpha}.} Based on this, we introduce the Nesterov's smooth optimization method \changed{M1.7}{\link{R1.7}}{\citep{Yu2005Smooth}} that requires $\nabla h({\bm \alpha})$ Lipschitz continuous to solve problem~\eqref{mainrank}, that is shown to achieve $\mathcal{O}(1/t^2)$ convergence rate. \subsection{Gradient-Lipschitz continuity of DANK in SVM} \label{sec:gradl} To prove the gradient-Lipschitz continuity of $h({\bm \alpha})$, we need the following lemma. \begin{lemma}\label{gammabound} For any $\bm \alpha_1$, $\bm \alpha_2$ $\in \mathcal{A}$, we have \begin{equation*} \begin{split} \big\| \bm F(\bm \alpha_1) - \bm F(\bm \alpha_2)\big\|_{\F} \leq \frac{\|\bm{K}\|\big( \| {\bm \alpha_1} \| + \| {\bm \alpha_2} \| \big)}{4\eta} \big\| {\bm \alpha_1} - {\bm \alpha_2} \big\|_{2}\,, \end{split} \end{equation*} where $\bm F(\bm \alpha_1) =\mathcal{J}_{\frac{\tau}{2}}\big(\bm 1 \bm{1}^{\!\top}+\bm \Gamma(\bm \alpha_1)\big)$ and $\bm F(\bm \alpha_2) =\mathcal{J}_{\frac{\tau}{2}}\big(\bm 1 \bm{1}^{\!\top}+\bm \Gamma(\bm \alpha_2)\big)$. \end{lemma} \begin{proof} The proofs can be found in Appendix~\ref{proofgammabound}. \end{proof} Formally, based on Lemmas~\ref{fbound} and \ref{gammabound}, we present the following theorem. \begin{theorem}\label{theor} The function $h ({\bm \alpha})$ is gradient-Lipschitz continuous with a Lipschitz constant $L=n+\frac{ 3nC^2 \|\bm{K}\|^2_{\F}}{4\eta}$, i.e., for any $\bm \alpha_1$, $\bm \alpha_2$ $\in \mathcal{A}$, the inequality $\| \nabla h(\bm \alpha_1) - \nabla h(\bm \alpha_2) \|_2 \leq L\| {\bm \alpha_1} - {\bm \alpha_2} \|_2$ holds. \end{theorem} \begin{proof} The proofs can be found in \ref{prooftheor}. \end{proof} The above theoretical analyses demonstrate that $\nabla h({\bm \alpha})$ is Lipschitz continuous, which provides a justification for utilizing a smooth optimization Nesterov's acceleration method to solve problem~\eqref{mainrank} with faster convergence. \subsection{Nesterov's Smooth Optimization Method} \label{sec:nest} Here we introduce a projected gradient algorithm with Nesterov's acceleration to solve the optimization problem \eqref{mainrank}. \cite{Yu2005Smooth} proposes an optimal scheme for smooth optimization $\min_{\bm x \in \mathcal{Q}} g(\bm x)$, where $g$ is a convex gradient-Lipschitz continuous function over a closed convex set $\mathcal{Q}$. Introducing a continuous and strongly convex function denoted as \changed{M1.6}{\link{R1.6}}{\emph{proxy-function}} $d(\bm x)$ on $\mathcal{Q}$, the first-order projected gradient method with Nesterov's acceleration can then be used to solve this problem. In our model, we aim to solve the following convex problem \begin{equation}\label{hopt} \max\limits_{\bm \alpha \in \mathcal{A}} ~~h(\bm \alpha)\,, \end{equation} where $h(\bm \alpha)$ is concave and gradient-Lipschitz continuous with the Lipschitz constant $L=n+\frac{ 3nC^2 \|\bm{K}\|^2_{\F}}{4\eta}$ as demonstrated in Theorem~\ref{theor}. Here the proxy-function is defined as $ d(\bm \alpha) = \frac{1}{2} \| \bm \alpha - \bm \alpha_0 \|_2^2 $ with $\bm \alpha_0 \in \mathcal{A}$. The first-order Nesterov's smooth optimization method for solving problem \eqref{mainrank} is summarized in Algorithm~\ref{ago3}. \begin{algorithm}[t] \caption{Projected gradient method with Nesterov's acceleration for problem \eqref{mainrank}} \label{ago3} \KwIn{The kernel matrix $\bm{K}$, the label matrix $\bm{Y}$, and the Lipschitz constant $L=n+\frac{ 3nC^2 \|\bm{K}\|^2_{\F}}{4\eta}$} \KwOut{The optimal ${\bm \alpha}^*$} Set the stopping criteria $t_{\max}=2000$ and $\epsilon=10^{-4}$.\\ Initialize $t = 0$ and ${\bm \alpha^{(0)}} \in \mathcal{A} := \bm 0$.\\ \SetKwRepeat{RepeatUntil}{Repeat}{Until} \RepeatUntil{$t \geq t_{\max}$ or $ \| \bm \alpha^{(t)} - \bm \alpha^{(t-1)} \|_2 \leq \epsilon$} { Compute $\bm{F}({\bm \alpha^{(t)}})=\mathcal{J}_{\frac{\tau}{2}}\big(\bm 1 \bm{1}^{\!\top}+\bm \Gamma(\bm \alpha^{(t)}) \big)$\; Compute $\nabla h ({\bm \alpha^{(t)}}) = \bm{1} - \bm{Y}\big(\bm{F}({\bm \alpha^{(t)}})\odot\bm{K}\big)\bm{Y} {\bm \alpha^{(t)}}$ \; Compute $\bm \theta^{(t)} \!=\! \mathcal{P}_{\mathcal{A}}\Big(\bm \alpha^{(t)} + \frac{1}{L}\nabla h ({\bm \alpha^{(t)}})\Big)$ \; Compute $\bm \beta^{(t)}\!=\!\mathcal{P}_{\!\mathcal{A}}\Big( \!\bm \alpha^{(0)} \!-\! \frac{1}{2L}\!\sum_{i=0}^{t}(i+1) \nabla h ({\bm \alpha^{(i)}}) \Big)$\; Set $\bm \alpha^{(t+1)} = \frac{t+1}{t+3}\bm \theta^{(t)} + \frac{2}{t+3}\bm \beta^{(t)}$\; $t := t + 1$\;} \end{algorithm} The key steps of Nesterov's acceleration are characterized by Lines 6, 7, and 8 in Algorithm~\ref{ago3}. \changed{M2.14}{\link{R2.14}}{To be specific, according to \cite{Yu2005Smooth}, at the $t$-th iteration, we need to solve the following problem \begin{equation}\label{nest1} \bm \beta^{(t)} = \argmin_{\bm \alpha \in \mathcal{A}} \frac{L}{2} \| \bm \alpha - \bm \alpha_0 \|_2^2 + \sum_{i=0}^{t} \frac{i+1}{2} \Big[ h(\bm \alpha^{(i)}) + \big\langle \nabla h ({\bm \alpha^{(i)}}), \bm \alpha - \bm \alpha^{(i)} \big\rangle \Big]\,, \end{equation} which is equivalent to \begin{equation*} \bm \beta^{(t)} = \argmin_{\bm \alpha \in \mathcal{A}} \| \bm \alpha - \bm \alpha_0 \|_2^2 + \frac{2}{L} \sum_{i=0}^{t} \frac{i+1}{2} \nabla h^{\!\top} ({\bm \alpha^{(i)}}) \bm \alpha \,, \end{equation*} where we omit the irrelevant terms $h(\bm \alpha^{(i)})$ and $\nabla h^{\!\top} ({\bm \alpha^{(i)}}) \bm \alpha^{(i)}$ that are independent of the optimization variable $\bm \alpha$ in Eq.~\eqref{nest1}. Accordingly, the above problem can be further reformulated as} \begin{equation*} \bm \beta^{(t)} = \argmin_{\bm \alpha \in \mathcal{A}}~~ \Big\| \bm \alpha - \bm \alpha_0 + \frac{1}{2L}\!\sum_{i=0}^{t}(i+1) \nabla h ({\bm \alpha^{(i)}}) \Big\|_2^2\,, \end{equation*} of which the optimal solution is $\bm \beta^{(t)} = \mathcal{P}_{\!\mathcal{A}}\Big( \!\bm \alpha_{0} \!-\! \frac{1}{2L}\!\sum_{i=0}^{t}(i+1) \nabla h ({\bm \alpha^{(i)}}) \Big)$ as outlined in Line 7 in Algorithm~\ref{ago3}, where $\mathcal{P}_{\mathcal{A}}(\bm \alpha)$ is a projection operator that projects $\bm \alpha$ over the set $\mathcal{A}$. A quick note on projection onto the feasible set $\mathcal{A}=\{ {\bm \alpha}\in \mathbb{R}^n: {\bm \alpha}^{\top}\bm{y}=0,~\bm 0\leq {\bm \alpha} \leq C\bm{1} \}$: it typically suffices in practice to use the alternating projection algorithm \citep{von1949rings}. Since the feasible set $\mathcal{A}$ is the intersection of a hyperplane and a hypercube, both of them admit a simple projection step. To be specific, first clip $\bm \alpha$ to $[0,C]$, and then project on the hyperplane $\bm \alpha \leftarrow \bm \alpha - \frac{\bm y^{\!\top} \bm \alpha}{n}\bm y$. We use 10 such alternating projections to obtain the projected $\bm \alpha$. The convergence rate of the alternating projection algorithm is shown to be linear \citep{von1949rings} and thus it is very efficient It can be noticed that when Lines 6, 7, and 8 in Algorithm~\ref{ago3} are replaced by \begin{equation}\label{pgm} \bm \alpha^{(t+1)} \!=\! \mathcal{P}_{\mathcal{A}}\Big(\bm \alpha^{(t)} + \frac{1}{L}\nabla h ({\bm \alpha^{(t)}})\Big)\, \end{equation} with the Lipschitz constant $L=n - \frac{\tau}{2}+\frac{nC^2}{4\eta}\lambda_{\max}(\bm K)$ derived from Lemma~\ref{fbound}, the Nesterov's smooth method degenerates to a standard projected gradient method. The convergence of the Nesterov smoothing optimization algorithm is pointed out by Theorem 2 in \citep{Yu2005Smooth}, namely \begin{equation*} h(\bm \alpha^*) - h(\bm \beta^{(t)}) \leq \frac{8L\| \bm \alpha_0 -\bm \alpha^*\|^2}{(t+1)(t+2)}\,, \end{equation*} where $\bm \alpha^*$ is the optimal solution of Eq.~\eqref{hopt}. Note that, in general, Algorithm~\ref{ago3} cannot guarantee $\{ h(\bm \alpha^{(t)}): t \in \mathbb{N} \}$ and $\{ h(\bm \beta^{(t)}): t \in \mathbb{N} \}$ to be monotonely increasing during the maximization process. Nevertheless, such algorithm can be modified to obtain a monotone sequence with replacing Line 6 in Algorithm~\ref{ago3} by \begin{align*} \left\{ \begin{array}{rcl} \begin{split} & \tilde{\bm \theta}^{(t)} = \mathcal{P}_{\!\mathcal{A}}\Big(\bm \alpha^{(t)} + \frac{1}{L}\nabla h ({\bm \alpha^{(t)}})\Big)\,, \\ & \\ & \bm {\theta}^{(t)} = \argmax_{\bm \alpha} h(\bm \alpha),~\bm \alpha \in \{ \bm {\theta}^{(t-1)}, \tilde{\bm \theta}^{(t)}, \bm \alpha^{(t)} \}\,. \end{split} \end{array} \right. \end{align*} The Nesterov's smooth optimization method takes $\mathcal{O}(\sqrt{L/\epsilon})$ to find an $\epsilon$-optimal solution, which is better than the standard projected gradient method with the complexity $\mathcal{O}({L/\epsilon})$. \section{DANK in Large Scale Case} \label{sec:knplapp} Scalability in kernel methods is a vital issue which often limits their applications in large datasets \citep{maji2013efficient,rahimi2007random,wang2016spsd}, especially for nonparametric kernel learning using semi-definite programming. Hence, in this section, we investigate kernel approximation in nonparametric kernel learning, and take our DANK model embedded in SVM as an example to illustrate this scheme. The presented theoretical results in this section are also suitable to other nonparametric kernel learning based algorithms. To consider the scalability of our DANK model embedded in SVM in large-scale situations, problem~\eqref{mainrank} is reformulate as \begin{equation}\label{mainls} \begin{split} &\max\limits_{\bm \alpha}\min \limits_{\bm{F}\in \mathcal{S}^n_+} ~~ H(\bm \alpha, \bm F) = \bm{1}^{\!\top}\!{\bm \alpha}\! -\!\frac{1}{2} {\bm \alpha}^{\!\!\top}\bm{Y}\big(\bm{F}\odot\bm{K}\big)\bm{Y} {\bm \alpha} + {\eta} \| \bm{F} - \bm{1} \bm{1}^{\top} \|_{\text{F}}^2 \\ &\mbox{s.t.} ~~\bm{0}\leq {\bm \alpha} \leq C\bm{1}\,. \end{split} \end{equation} where the bias term $b$ is usually omitted in the large scale issue \citep{keerthi2006building,hsieh2014divide,lian2017divide} and we omit the low rank regularizer on $\bm F$ as well due to its inseparable property, which is reasonable based on the rapid decaying spectra of the kernel matrix \citep{smola2000sparse}. In Section~\ref{sec:explowrank}, we will verify that this low rank term can be directly dropped without sacrificing too much performance in large-scale situations. In our decomposition-based scalable approach, we divide the data into small subsets by k-means, and then solve each subset independently and efficiently. Such similar idea also exists in \citep{hsieh2014divide,zhang2013divide,si2017memory}. To be specific, we firstly partition the data into $v$ subsets $\{ \mathcal{V}_1, \mathcal{V}_2,\dots, \mathcal{V}_v \}$, and then solve the respective sub-problems independently with the following formulation \begin{equation}\label{mainlssub} \begin{split} &\max\limits_{\bm \alpha^{(c)}}\!\min \limits_{\bm{F}^{(c,c)} \in \mathcal{S}^{|\mathcal{V}_c|}_+} \bm{1}^{\!\top}\!{\bm \alpha^{(c)}}\! \!+\! {\eta} \| \bm{F}^{(c,c)} - \bm{1} \bm{1}^{\top} \|_{\text{F}}^2 -\!\frac{1}{2} {\bm \alpha^{(c)}}^{\!\!\top}\bm{Y}^{(c,c)}\big(\bm{F}^{(c,c)}\odot\bm{K}^{(c,c)}\big) \bm{Y}^{(c,c)} {\bm \alpha}^{(c)}\\ &\mbox{s.t.} ~~\bm{0}\leq {\bm \alpha}^{(c)} \leq C\bm{1},~~\forall~c=1,2,\dots,v\,, \end{split} \end{equation} where $|\mathcal{V}_c|$ denotes the number of data points in $\mathcal{V}_c$. Suppose that $(\bar{\bm \alpha}^{(c)}, \bar{\bm{F}}^{(c,c)})$ is the optimal solution of the $c$-th subproblem, the approximation solution $(\bar{\bm \alpha}, \bar{\bm F})$ to the whole problem is concatenated by $\bar{\bm \alpha}=[\bar{\bm \alpha}^{(1)}, \bar{\bm \alpha}^{(2)},\dots,\bar{\bm \alpha}^{(v)}]$ and $\bar{\bm F} = \diag(\bar{\bm{F}}^{(1,1)}, \bar{\bm{F}}^{(2,2)}, \dots, \bar{\bm{F}}^{(v,v)})$, where $\bar{\bm F}$ is a block-diagonal matrix. The above kernel approximation scheme makes the nonparametric kernel learning framework feasible to large-scale situations. In the next, we theoretically demonstrate the decomposition-based scalable approach in three aspects. First, the objective function value $H(\bar{\bm \alpha},\!\bar{\bm{F}})$ in Eq.~\eqref{mainls} is close to $H(\bm \alpha^*, \bm F^*)$. Second, the approximation solution $(\bar{\bm \alpha}, \bar{\bm F})$ is close to the optimal solution $(\bm \alpha^*, \bm F^*)$. Third, if $\bm x_i$ is not a support vector of the subproblem, it will also be a non-support vector of the whole problem under some conditions. To prove the above three propositions, we need the following lemma that links the subproblems to the whole problem. \begin{lemma}\label{lemmalink} $(\bar{\bm \alpha}, \bar{\bm F})$ is the optimal solution of the following problem \begin{equation}\label{mainlslemma} \begin{split} &\max\limits_{\bm \alpha}\!\min \limits_{\bm{F}\in \mathcal{S}^n_+}~~\bar{H}(\bm \alpha, \bm F) \triangleq \bm{1}^{\!\top}\!{\bm \alpha} -\frac{1}{2} {\bm \alpha}^{\!\!\top}\bm{Y}\big(\bm{F}\odot \bar{\bm{K}} \big)\bm{Y} {\bm \alpha} + {\eta} \| \bm{F} - \bm{1} \bm{1}^{\top} \|_{\emph{F}}^2 \\ &\emph{s.t.} ~~\bm{0}\leq {\bm \alpha} \leq C\bm{1}\,, \end{split} \end{equation} with the kernel $\bar{\bm K}$ defined by \begin{equation*} \bar{K}_{ij} = I(\pi(\bm x_i), \pi(\bm x_j)) K_{ij}\,, \end{equation*} where $\pi(\bm x_i)$ is the cluster that $\bm x_i$ belongs to, and $I(a,b)=1$ iff $a=b$, and $I(a,b)=0$ otherwise. \end{lemma} \begin{proof} The proofs can be found in Appendix~\ref{prooflemmalink}. \end{proof} Based on the above lemma, we are ready to investigate the difference between $H(\bm \alpha^*, \bm F^*)$ and $H(\bar{\bm \alpha},\!\bar{\bm{F}})$ as follows. \begin{theorem}\label{theorappf} Given the training data $\{ \bm x_i, y_i \}_{i=1}^n$ with labels $y_i \in \{ +1, -1 \}$ and a partition indicator $\{ \pi(\bm x_1), \pi(\bm x_2), \cdots, \pi(\bm x_n) \}$, denote $(\bm \alpha^*, \bm F^*)$ and $(\bar{\bm \alpha}, \bar{\bm F})$ as the optimal solutions of problem~\eqref{mainrank} and problem~\eqref{mainlslemma}, respectively. \changed{M2.16}{\link{R2.16}}{Suppose that each element in $\bm F^*$ and $\bar{\bm F}$ satisfies $0 < B_1 \leq \max\{ F^*_{ij}, \bar{F}_{ij} \} \leq B_2$, with $B=B_2 - B_1$}, we have \begin{equation*} \left| H(\bm \alpha^*, \bm F^*) - H(\bar{\bm \alpha},\!\bar{\bm{F}}) \right| \leq \frac{1}{2}BC^2 Q(\pi)\,, \end{equation*} with $Q(\pi) = \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} | k(\bm x_i, \bm x_j)|$ and the balance parameter $C$ in SVM. \end{theorem} \begin{proof} The proofs can be found in Appendix~\ref{prooftheorappf}. \end{proof} \changed{M2.17}{\link{R2.17}}{{\bf Remark: } $Q(\pi)$ actually consists of the off-diagonal values of the kernel matrix $\bm K$ if we rearrange the training data in a clustering order. It depends on the data distribution, the number of clusters $v$, and the kernel type. Intuitively, if the clusters are nicely shaped (e.g. Gaussian) and well-separated, then the kernel matrix may be approximately block-diagonal. In this case, $Q(\pi)$ would be small. Let we examine two extreme cases of $v$. If $v=1$, i.e., only one cluster, we have $Q(\pi)=0$; If $v=n$, i.e., each data point is grouped into a cluster, then $Q(\pi)$ can be upper bounded by $Q(\pi) \leq \sum_{i,j}^n |k(\bm x_i, \bm x_j)| := \| \bm K \|_{\M} \leq c'\sqrt{n} \| \bm K \|_{\F} $, where $c'$ is some constant. In practical clustering algorithms, $v$ is often chosen to be much smaller than $n$, i.e., $v \ll n$, and thus we can obtain a small $Q(\pi)$. } Next we investigate the approximation error between the approximation solution $(\bar{\bm \alpha}, \bar{\bm F})$ and the optimal solution $(\bm \alpha^*, \bm F^*)$ by the following theorem. \begin{theorem}\label{theorappv} Under the same condition of Theorem~\ref{theorappf}, the error between $(\bar{\bm \alpha}, \bar{\bm F})$ and $(\bm \alpha^*, \bm F^*)$ can be bounded by \begin{align} \left\{ \begin{array}{rcl} \begin{split} & \| \bm \alpha^* - \bar{\bm \alpha} \|^2_2 \leq \frac{B_2C^2Q(\pi)}{B_1 \| \bm K \|_{\F}} + \frac{2BC^2}{B_1} := \mathcal{O}(\sqrt{n})\,, \label{alphabod} \\ & \\ & \| \bm F^* - \bar{\bm F} \|_{\F} \leq \frac{\| \bm K \|_{\F}}{2 \eta} \sqrt{\frac{nB_2Q(\pi)}{B_1 \| \bm K \|_{\F}} + \frac{2nB}{B_1}}C^2+ \frac{C^2Q(\pi)}{4\eta} := \mathcal{O}(n^{\frac{3}{4}})\,. \end{split} \end{array} \right. \end{align} \end{theorem} \begin{proof} The proofs can be found in Appendix~\ref{prooftheorappv}. \end{proof} {\bf Remark:} The derived approximation error about $\bm \alpha$ by Theorem~\ref{theorappv} is improved from the exact bound $\mathcal{O}(n)$ to $\mathcal{O}(\sqrt{n})$ due to $Q(\pi) \leq c' \sqrt{n}\| \bm K \|_{\F}$. Compared to the intuitive bound $\| \bm F^* - \bar{\bm F} \|_{\text{F}} \leq n \max\{\sqrt{B}, B\} \in \mathcal{O}(n)$, the obtained error bound regarding to $\bm F$ by Theorem~\ref{theorappv} is improved to $\mathcal{O}(n^{\frac{3}{4}})$ due to $\| \bm K \|_{\F} \in \mathcal{O}(n)$ and $\eta \in \mathcal{O}(n)$. In Section~\ref{sec:bound}, we will experimentally check whether our derived bounds are tight. The above theoretical results demonstrate the approximation performance of the subproblems to the whole problem, regarding to the difference of their respective objective function values in Theorem~\ref{theorappf}, and the difference of their respective optimization variables in Theorem~\ref{theorappv}. Besides, in SVM, we also concern about the relationship of support/non-support vectors between the subproblems and the whole problem. Accordingly, we present the following theorem to explain this issue. \begin{theorem}\label{theorsv} Under the same condition of~Theorem~\ref{theorappf} with an additional bounded assumption $\sup_{\bm x, \bm x' \in \mathcal{X}}|k(\bm x, \bm x')| < \kappa$, suppose that $\bm x_i$ is not a support vector of the subproblem, i.e., $\bar{\alpha}_i =0$, $\bm x_i$ will also not be a support vector of the whole problem i.e., ${\alpha}_i =0$, under the following condition \begin{equation}\label{gradsvc} \Big(\! \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \!\Big)_{\!i} \!\leq\! - (B \!+\! B_2)C \left(\| \bar{\bm K}_i \|_1 \!+\! \kappa \right) \leq - (B + B_2)C \left(\| \bm K \|_1 + \kappa \right) \,, \end{equation} where $\bar{\bm K}_i$ denotes the $i$-th column of the kernel matrix $\bar{\bm K}$. \end{theorem} \begin{proof} The proofs can be found in Appendix~\ref{prooftheorsv}. \end{proof} \changed{M2.18.1}{\link{R2.18}}{{\bf Remark:} Eq.~\eqref{gradsvc} is a sufficient condition and can be expressed as \begin{equation*} \mathcal{O}(n) =: 1 - nB_2 \kappa C \leq \Big(\! \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \!\Big)_{\!i} \leq - (B + B_2)C \left(\| \bar{\bm K}_i \|_1 + \kappa \right) := \mathcal{O}(\sqrt{n})\,, \end{equation*} where the first inequality admits $\inf \Big(\! \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \!\Big)_{\!i} = \inf \left( 1 - \sum_{j=1}^{n} y_i y_j \bar{ F}_{ij} \bar{ K}_{ij} \bar{ \alpha}_j \right) = 1 - nB_2 \kappa C$. So if we assume that $\left( \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \right)_{\!i}$ of non-support vectors is uniformly distributed over the range $[1-n\kappa B_2 C, 0]$, then nearly $1 - \frac{(B + B_2)C \left(\| \bar{\bm K}_i \|_1 + \kappa \right)}{nB_2 \kappa C - 1} \approx 1 - \frac{c}{\sqrt{n}}$ of the total non-support vectors can be directly recognized, where $c$ is some constant. Hence, the screening proportion of non-support vectors is $(1 - \frac{c}{\sqrt{n}})*100\%$, increasing at a certain $\mathcal{O}(n^{-1/2})$ rate. If $\left( \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \right)_{\!i}$ follows with some heavy-tailed distributions over the range $[1-n\kappa B_2 C, 0]$, the recognized rate would decrease. And specifically, we will experimentally check that our screening condition is reasonable in Section~\ref{sec:bound}. } \section{DANK Model in SVR} \label{sec:knplsvr} In this section, we incorporate the DANK model into SVR and also develop the Nesterov's smooth optimization algorithm to solve it. Here the label space is $\mathcal{Y} \subseteq \mathbb{R}$ for regression. Similar to DANK in SVM revealed by problem~\eqref{mainrank}, we incorporate the DANK model into SVR with the $\varepsilon$-insensitive loss, namely \begin{equation}\label{mainsvr} \begin{split} & \max\limits_{\hat{\bm \alpha}, \check{\bm \alpha}}\min\limits_{{\bm F} \in \mathcal{S}^n_+} -\frac{1}{2}(\hat{\bm \alpha} - \check{\bm \alpha})^{\top} \big({\bm F} \odot \bm{K}\big)(\hat{\bm \alpha} - \check{\bm \alpha}) + (\hat{\bm \alpha} - \check{\bm \alpha})^{\top}\bm{y} \\ &\qquad \qquad ~- \varepsilon (\hat{\bm \alpha} + \check{\bm \alpha})^{\top}\bm{1} +\! {\eta} \| {\bm{F}} \!-\! \bm{1}\bm{1}^{\!\!\top} \! \|_{\text{F}}^2\! +\!\tau \eta \| {\bm{F}} \|_*\\ &\mbox{s.t.} ~0 \leq \hat{\bm \alpha}, \check{\bm \alpha} \leq C, ~(\hat{\bm \alpha} - \check{\bm \alpha})^{\top}\bm{y} = 0\,, \end{split} \end{equation} where the dual variable is $\bm \alpha = \hat{\bm \alpha} - \check{\bm \alpha}$. The objective function in problem~\eqref{mainsvr} is denoted as $H(\hat{\bm \alpha}, \check{\bm \alpha},\bm{F})$. Further, we define the following function \begin{equation}\label{falphasvr} {h}(\hat{\bm \alpha}, \check{\bm \alpha}) \triangleq H(\hat{\bm \alpha}, \check{\bm \alpha},\bm{F}^*) = \min \limits_{\bm{F}\in \mathcal{S}^n_+} {H}(\hat{\bm \alpha}, \check{\bm \alpha},\bm{F})\,, \end{equation} where ${h}(\hat{\bm \alpha}, \check{\bm \alpha})$ can be obtained by solving the following problem \begin{equation}\label{svrfa} \min \limits_{{\bm F}\in \mathcal{S}^n_+} \| {\bm F} - \bm 1 \bm{1}^{\!\top} - {\bm \Gamma}(\hat{\bm \alpha}, \check{\bm \alpha})\|_{\F}^2 + \tau \| {\bm F} \|_*\,, \end{equation} with ${\bm \Gamma}(\hat{\bm \alpha}, \check{\bm \alpha})=\frac{1}{4\eta}\diag(\hat{\bm \alpha} - \check{\bm \alpha})^{\top}\bm{K}\diag(\hat{\bm \alpha} - \check{\bm \alpha})$. The optimal solution of Eq.~\eqref{svrfa} is ${\bm F}^* = \mathcal{J}_{\frac{\tau}{2}}(\bm 1 \bm{1}^{\!\top}+{\bm \Gamma(\hat{\bm \alpha}, \check{\bm \alpha})})$. We can easily check that Lemma \ref{fbound} is also applicable to problem~\eqref{falphasvr} \begin{equation*} h(\hat{\bm \alpha}, \check{\bm \alpha}) = \min \limits_{{\bm{F}}\in \mathcal{B}} H(\hat{\bm \alpha}, \check{\bm \alpha},{\bm{F}})\,. \end{equation*} Similar to Lemma \ref{gammabound}, in our DANK model embedded in SVR, $\| {\bm \Gamma}(\hat{\bm \alpha}_1, \check{\bm \alpha}_1) - {\bm \Gamma}(\hat{\bm \alpha}_2, \check{\bm \alpha}_2)\|_2$ can be bounded by the following lemma. \begin{lemma}\label{gammaboundsvr} For any $\hat{\bm \alpha}_1, \check{\bm \alpha}_1, \hat{\bm \alpha}_2, \check{\bm \alpha}_2 \in \mathcal{A}$, we have \begin{equation*} \begin{split} &\big\| {\bm F}(\hat{\bm \alpha}_1, \check{\bm \alpha}_1) - {\bm F}(\hat{\bm \alpha}_2, \check{\bm \alpha}_2)\big\|_{\F} \leq \| {\bm \Gamma}(\hat{\bm \alpha}_1, \check{\bm \alpha}_1) - {\bm \Gamma}(\hat{\bm \alpha}_2, \check{\bm \alpha}_2)\|_{\F} \\ & \leq \frac{\|\bm{K}\|}{4\eta} \big \|\hat{\bm \alpha}_1-\check{\bm \alpha}_1+\hat{\bm \alpha}_2 - \check{\bm \alpha}_2 \big\|_2 \big\| \hat{\bm \alpha}_1 - \check{\bm \alpha}_1 - \hat{\bm \alpha}_2 + \check{\bm \alpha}_2\big\|_2\,, \end{split} \end{equation*} where $\bm{F}(\hat{\bm \alpha}_1, \check{\bm \alpha}_1)) =\mathcal{J}_{\frac{\tau}{2}}\big(\bm 1 \bm{1}^{\!\top}+ {\bm \Gamma}(\hat{\bm \alpha}_1, \check{\bm \alpha}_1)\big)$ and $\bm{F}(\hat{\bm \alpha}_2, \check{\bm \alpha}_2) =\mathcal{J}_{\frac{\tau}{2}}\big(\bm 1 \bm{1}^{\!\top}+ {\bm \Gamma}(\hat{\bm \alpha}_2, \check{\bm \alpha}_2)\big)$. \end{lemma} The proof of Lemma~\ref{gammaboundsvr} is similar to that of Lemma~\ref{gammabound}, and here we omit the detailed proof. Next we present the partial derivative of ${h}(\hat{\bm \alpha}, \check{\bm \alpha})$ regarding to $\hat{\bm \alpha}$ and $\check{\bm \alpha}$. \begin{proposition}\label{theorgradsvr} The objective function ${h}(\hat{\bm \alpha}, \check{\bm \alpha})$ with two variables defined by Eq.~\eqref{falphasvr} is differentiable and its partial derivatives are given by \begin{align}\label{gradfsvr} \left\{ \begin{array}{rcl} \begin{split} & \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha})}}}{\partial \hat{\bm \alpha}} =- \varepsilon \bm I - ( \hat{\bm \alpha} - \check{\bm \alpha}) \bm{F} \odot \bm K + \bm y\,, \\ & \\ & \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha})}}}{\partial \check{\bm \alpha}} =- \varepsilon \bm I - ( \hat{\bm \alpha} - \check{\bm \alpha}) \bm{F} \odot \bm K - \bm y\,. \end{split} \end{array} \right. \end{align} \end{proposition} Formally, ${h}(\hat{\bm \alpha}, \check{\bm \alpha})$ is proven to be gradient-Lipschitz continuous by the following theorem. \begin{theorem}\label{theorsvr} The function ${h}(\hat{\bm \alpha}, \check{\bm \alpha})$ with its partial derivatives in Eq.~\eqref{gradfsvr} is gradient-Lipschitz continuous with the Lipschitz constant $L=2\Big(n+\frac{ 9nC^2 \|\bm{K}\|^2_{\F}}{4\eta} \Big)$, i.e., for any $\hat{\bm \alpha}_1, \check{\bm \alpha}_1, \hat{\bm \alpha}_2, \check{\bm \alpha}_2 \in \mathcal{A}$, let the concentration vectors be $\tilde{\bm \alpha}_1 = [\hat{\bm \alpha}_1^{\!\top}, \check{\bm \alpha}_1^{\!\top}]^{\!\top}$ and $\tilde{\bm \alpha}_2 = [\hat{\bm \alpha}_2^{\!\top}, \check{\bm \alpha}_2^{\!\top}]^{\!\top}$, and the partial derivatives be \begin{small} \begin{equation*} \begin{split} \nabla_{\tilde{\bm \alpha}_1} h(\hat{\bm \alpha}_1, \check{\bm \alpha}_1) & \!=\!\bigg[\Big( \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha}_1)}}}{\partial \hat{\bm \alpha}}\big|_{\hat{\bm \alpha}\! =\! \hat{\bm \alpha}_1} \Big)^{\!\top}, \Big( \frac{\partial {{{h}(\hat{\bm \alpha}_1, \check{\bm \alpha})}}}{\partial \check{\bm \alpha}}\big|_{\check{\bm \alpha}\! =\! \check{\bm \alpha}_1} \Big)^{\!\top} \bigg]^{\!\top}\,, \\ \nabla_{\tilde{\bm \alpha}_2} h(\hat{\bm \alpha}_2, \check{\bm \alpha}_2) & \!=\!\bigg[\Big( \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha}_2)}}}{\partial \hat{\bm \alpha}}\big|_{\hat{\bm \alpha} \!=\! \hat{\bm \alpha}_2} \Big)^{\!\top}, \Big( \frac{\partial {{{h}(\hat{\bm \alpha}_2, \check{\bm \alpha})}}}{\partial \check{\bm \alpha}}\big|_{\check{\bm \alpha} = \check{\bm \alpha}_2} \Big)^{\!\top} \bigg]^{\!\top}\,, \\ \end{split} \end{equation*} \end{small} we have \begin{small} \begin{equation*} \begin{split} & \|\nabla_{ \!\tilde{\bm \alpha}_1} \! {h}(\hat{\bm \alpha}_1, \! \check{\bm \alpha}_1 \!) \! - \! \nabla_{ \!\tilde{\bm \alpha}_2} \! {h}( \hat{\bm \alpha}_2, \! \check{\bm \alpha}_2 ) \|_2 \!\leq \! 2L \Big( \! \| \hat{\bm \alpha}_2 \!- \! \hat{\bm \alpha}_1 \|_2 \!+ \! \| \check{\bm \alpha}_2 \!- \! \check{\bm \alpha}_1 \|_2 \! \Big)\,. \end{split} \end{equation*} \end{small} \end{theorem} \begin{proof} The proofs can be found in Appendix~\ref{prooftheorsvr}. \end{proof} Based on the gradient-Lipschitz continuity of ${h}(\hat{\bm \alpha}, \check{\bm \alpha})$ demonstrated by Theorem~\ref{theorsvr}, we are ready to present the first-order Nesterov's smooth optimization method for problem \eqref{mainsvr}. The smooth optimization algorithm is summarized in Algorithm~\ref{ago3svr}. \begin{algorithm} \caption{Projected gradient method with Nesterov's acceleration for problem \eqref{mainsvr}} \label{ago3svr} \KwIn{The kernel matrix $\bm{K}$, the label matrix $\bm{Y}$, and the Lipschitz constant $L=2\Big(n+\frac{ 9nC^2 \|\bm{K}\|^2_{\F}}{4\eta} \Big)$} \KwOut{The optimal ${\bm \alpha}^*$} Set the stopping criteria $t_{\max}=2000$ and $\epsilon=10^{-4}$.\\ Initialize $t = 0$ and ${\hat{\bm \alpha}^{(0)}}, {\check{\bm \alpha}^{(0)}} \in \mathcal{A} := \bm 0$.\\ \SetKwRepeat{RepeatUntil}{Repeat}{Until} \RepeatUntil{$t \geq t_{\max}$ or $ \| \bm \alpha^{(t)} - \bm \alpha^{(t-1)} \|_2 \leq \epsilon$} { Compute $\bm{F}({\hat{\bm \alpha}^{(t)}}, {\check{\bm \alpha}^{(t)}} )=\mathcal{J}_{\frac{\tau}{2}}\big(\bm 1 \bm{1}^{\!\top}+\bm \Gamma({\hat{\bm \alpha}^{(t)}}, {\check{\bm \alpha}^{(t)}} ) \big)$\; Compute ${\partial {{h}}}/{\partial \hat{\bm \alpha}} $ and ${\partial {{h}}}/{\partial \check{\bm \alpha}}$ by Eq.~\eqref{gradfsvr}, and concentrate them as $\nabla h ({\hat{\bm \alpha}^{(t)}}, {\check{\bm \alpha}^{(t)}} ) = [({\partial {{h}}}/{\partial \hat{\bm \alpha}})^{\!\top}, ({\partial {{h}}}/{\partial \check{\bm \alpha}})^{\!\top}]^{\!\top}$ \; Compute $\bm \theta^{(t)} \!=\! \mathcal{P}_{\mathcal{A}}\Big([{\hat{\bm \alpha}^{(t)\!\top}}, {\check{\bm \alpha}^{(t)\!\top}}]^{\!\top} + \frac{1}{2L}\nabla h ({\hat{\bm \alpha}^{(t)}}, {\check{\bm \alpha}^{(t)}} ) \Big)$ \; Compute $\bm \beta^{(t)}\!=\!\mathcal{P}_{\!\mathcal{A}}\Big( \![\hat{\bm \alpha}^{(0)\!\top}, \check{\bm \alpha}^{(0)\!\top}]^{\!\top} \!-\! \frac{1}{4L}\!\sum_{i=0}^{t}(i+1) \nabla h ({\hat{\bm \alpha}^{(i)}}, {\check{\bm \alpha}^{(i)}} ) \Big)$\; Set $[{\hat{\bm \alpha}^{(t+1)\!\top}}, {\check{\bm \alpha}^{(t+1)\!\top}}]^{\!\top} = \frac{t+1}{t+3}\bm \theta^{(t)} + \frac{2}{t+3}\bm \beta^{(t)}$\; Set $\bm \alpha^{(t+1)} = \hat{\bm \alpha}^{(t+1)} - \check{\bm \alpha}^{(t+1)}$ and $t := t + 1$\;} \end{algorithm} \section{Experimental Results} \label{sec:experiment} This section evaluates the performance of our DANK model in comparison with several representative kernel learning algorithms on classification and regression benchmark datasets. All the experiments implemented in MATLAB are conducted on a \fh{Workstation} with an Intel$^\circledR$ Xeon$^\circledR$ E5-2695 CPU (2.30 GHz) and 64GB RAM. The source code of the proposed DANK method will be publicly available. \subsection{Classification tasks} We conduct experiments on the UCI Machine Learning Repository\footnote{\url{https://archive.ics.uci.edu/ml/datasets.html}} with small scale datasets, and three large datasets including \emph{EEG}, \emph{ijcnn1} and \emph{covtype}\footnote{All datasets are available at \url{https://www.csie.ntu.edu.tw/~cjlin/libsvmtools/datasets/} }. Besides, the \emph{CIFAR-10} database\footnote{\url{https://www.cs.toronto.edu/~kriz/cifar.html}} for image classification is used to evaluate the compared algorithms. \subsubsection{Classification Results on UCI database} \label{sec:classUCI} Ten datasets from the UCI database are used to evaluate our DANK model embedded in SVM. Here we describe experimental settings and the compared algorithms as follows. \noindent{\bf Experimental Settings:} Table~\ref{UCIres} lists a brief description of these ten datasets including the number of training data $n$ and the feature dimension $d$. After normalizing the data to $[0, 1]^d$ by \changed{M1.9}{\link{R1.9}}{a min-max scaler}, we randomly pick half of the data for training and the rest for test except for \emph{monks1}, \emph{monks2}, and \emph{monks3}. In these three datasets, both training and test data have been provided. The Gaussian kernel $k(\bm x_i, \bm x_j) = \exp(-\| \bm x_i - \bm x_j \|_2^2/2\sigma^2)$ is chosen as the initial kernel in our model. The kernel width $\sigma$ and the balance parameter $C$ are tuned by 5-fold cross validation on a grid of points, i.e., $\sigma=[2^{-5}, 2^{-4},\dots,2^5]$ and $C = [2^{-5}, 2^{-4},\dots,2^5]$. We experimentally set the penalty parameter $\tau$ to 0.01. The regularization parameter $\eta$ is fixed to $\| \bm \alpha \|_2^2$ obtained by SVM. The experiments are conducted 10 times on these ten datasets. \begin{table*}[t] \centering \scriptsize \caption{Comparison results in terms of classification accuracy (mean$\pm$std. deviation \%) on the UCI datasets. The best performance is highlighted in \textbf{bold}. The classification accuracy on the training data is presented by \emph{italic}, and does not participate in ranking. Notation ``$\bullet$" indicates that the data-adaptive based algorithm (KNPL or DANK) is significantly better than other representative kernel learning methods via paired t-test at the 5\% significance level.} \begin{small} \begin{tabular}{p{0.8cm}<{\centering} p{1.5cm}<{\centering} p{1.2cm}<{\centering} p{1.2cm}<{\centering} p{1.2cm}<{\centering} p{1.2cm}<{\centering} p{1.25cm}<{\centering} p{1.25cm}<{\centering} p{1.3cm}<{\centering} p{1.2cm}<{\centering}} \toprule[2pt] \multirow{2}{*}{Dataset} &\multirow{2}{*}{($d$, $n$)} &\multicolumn{1}{c}{LogDet} &\multicolumn{1}{c}{BMKL} &\multicolumn{1}{c}{RF} &\multicolumn{2}{c}{SVM-CV} &\multicolumn{1}{c}{KNPL} &\multicolumn{2}{c}{DANK}\cr \cmidrule(lr){3-5} \cmidrule(lr){6-7} \cmidrule(lr){8-8} \cmidrule(lr){9-10} {}&{}&~~~~~~Test&~~~~~~Test&Test &Training&Test &Test &Training&Test\cr \midrule[1pt] diabetic &(19, 1151) & 78.7$\pm$1.8 & {74.9}$\pm$0.4 & 72.3$\pm$0.8 & \emph{80.7$\pm$3.9} & 73.0$\pm$1.7 & {\bf81.9}$\pm$1.7$\bullet$ & \emph{87.0$\pm$1.9}& {81.2$\pm$1.4}$\bullet$ \\ \hline heart &(13, 270) & 80.6$\pm$3.5 & 85.6$\pm$0.8 & 79.1$\pm$2.4 & \emph{88.9$\pm$3.0} & 81.9$\pm$2.4 & 87.4$\pm$3.9$\bullet$ & \emph{94.3$\pm$1.7} & {\bf87.9}$\pm$2.9$\bullet$ \\ \hline monks1 &(6, 124) & {\bf 86.6}$\pm$0.2 & 78.9$\pm$2.5 & {84.4}$\pm$0.9 & \emph{90.3$\pm$0.0} & 81.4$\pm$0.0 & 83.3$\pm$3.3 & \emph{100.0$\pm$0.0} & 83.6$\pm$1.5 \\ \hline monks2 &(6, 169) & 85.9$\pm$1.2 & 82.1$\pm$1.3 & {73.6$\pm$1.1} & \emph{100.0$\pm$0.0} & {85.8}$\pm$1.4 & 83.3$\pm$1.6& \emph{100.0$\pm$0.0} &{\bf 86.7}$\pm$0.9\\ \hline monks3 &(6, 122) & {\bf 94.0}$\pm$1.3 & {\bf94.0}$\pm$1.0 & 93.7$\pm$0.6 & \emph{96.2$\pm$1.5} & 93.0$\pm$1.2 & 88.7$\pm$1.2& \emph{97.2$\pm$1.8} & 93.0$\pm$0.9 \\ \hline sonar &(60, 208) & 84.1$\pm$2.2 & 84.8$\pm$0.6 & 80.5$\pm$3.1 & \emph{99.9$\pm$0.3} & 85.3$\pm$3.1 & 85.8$\pm$2.8 & \emph{100.0$\pm$0.0} & {\bf87.0}$\pm$2.7$\bullet$ \\ \hline spect &(21, 80) & 79.6$\pm$3.7 & {78.8}$\pm$0.8 & 76.0$\pm$2.7 & \emph{87.0$\pm$3.7} & 73.1$\pm$3.2 & {\bf 79.7}$\pm$4.8 & \emph{93.4$\pm$4.1} & {78.9$\pm$3.2} \\ \hline glass &(9, 214) & 71.2$\pm$1.0 & 68.2$\pm$4.6 & { 68.2}$\pm$2.2 & \emph{77.1$\pm$6.9} & 69.8$\pm$2.0 & 72.4$\pm$2.3 & \emph{89.7$\pm$6.1} & {\bf 74.5}$\pm$1.3$\bullet$ \\ \hline fertility &(9, 100) & 86.2$\pm$1.1 & 84.4$\pm$1.6 &84.4$\pm$4.3 & \emph{94.4$\pm$5.3} & 85.2$\pm$1.7 & 85.6$\pm$3.8 & \emph{97.3$\pm$3.3} & {\bf 87.6}$\pm$2.3$\bullet$ \\ \hline wine &(13, 178) & 96.1$\pm$1.8 & 95.0$\pm$2.8 &95.1$\pm$1.1 & \emph{99.5$\pm$1.0} & 94.7$\pm$1.5 & 96.1$\pm$2.0 & \emph{99.5$\pm$1.0} & {\bf96.4}$\pm$2.0 \\ \bottomrule[2pt] \end{tabular} \end{small} \label{UCIres} \end{table*} \noindent{\bf Compared Methods:} We include the following kernel learning based algorithms: \begin{itemize} \item BMKL \citep{Gonen2012Bayesian}: A multiple kernel learning algorithm uses Bayesian approach to ensemble the Gaussian kernels with ten different kernel widths and the polynomial kernels with three different degrees. \item LogDet \citep{Jain2012Metric}: A nonparametric kernel learning approach aims to learn a PSD matrix $\bm W$ in a learned kernel $\phi(\bm x)^{\!\top} \bm W \phi(\bm x')$ with the LogDet divergence. \item RF \citep{AmanNIPS2016}: A kernel alignment based learning framework creates randomized features, and then solves a simple optimization problem to select a subset. Finally, the kernel is learned from the optimized features by target alignment. \item KNPL \citep{Liu2018AAAIme}: This nonparametric kernel learning framework is given by our conference version, which shares the initial ideas about learning in a data-adaptive scheme via a pair-wise way. But this work does not consider the bounded constraint and the low rank structure on $\bm F$, and utilizes an alternating iterative algorithm to solve the corresponding semi-definite programming. \item SVM-CV: The SVM classifier with cross validation \fh{serves as} a baseline. \end{itemize} {\bf Experimental Results:} Table~\ref{UCIres} summarizes the test results of each compared algorithm averaged over ten trials. Furthermore, we also apply the paired t-test at the 5\% significance level to investigate whether the data-adaptive approaches (KNPL and DANK) are significantly better than other methods. Specifically, we also present the classification accuracy of our DANK model and SVM-CV on the training data to show their respective model flexibilities. Compared with the baseline SVM-CV, the proposed DANK model significantly improves its model flexibility on \emph{diabetic}, \emph{heart}, \emph{monks1}, \emph{spect}, and \emph{glass} in terms of the training accuracy. Accordingly, it is helpful for our model to achieve noticeable improvements on the test data. \fh{On the \emph{monks2}, \emph{sonar}, and \emph{wine} datasets, SVM-CV has already obtained nearly 100\% accuracy on the training data, which indicates that the model flexibility is sufficient.} \fh{In this case, it is difficult for our DANK method to achieve a huge improvement on these datasets}, and accordingly the performance margins are about 0\%$\sim$2\%. Compared with other representative kernel based algorithms including LogDet, BMKL, and RF, the proposedDANK model yields favorable performance. \fh{In general, the improvements on the classification accuracy demonstrate the effectiveness of the learned adaptive matrix, and accordingly our model has good adaptivity to the training and test data.} \subsubsection{Results on large-scale datasets} \begin{table} \centering \caption{Dataset statistics and parameter settings on several large datasets.} \label{tablarge} \begin{threeparttable} \begin{tabular}{cccccccccccccc} \toprule[1.5pt] datasets &d & \#training & \#test & $C$ & $1/2\sigma^2$ &\#clusters\\ \midrule[1pt] \emph{EEG} &14 &7,490 &7,490 &32 & 100 &5 \\ \hline \emph{ijcnn1} &22 &49,990 &91,701 &32 & 2 &50 \\ \hline \emph{covtype} &54 &464,810 &116,202 &32 & 32 &200 \\ \bottomrule[1.5pt] \end{tabular} \end{threeparttable} \vspace{-0.35cm} \end{table} \begin{table*} \centering \fontsize{9}{8}\selectfont \begin{threeparttable} \caption{Comparison of test accuracy and training time of all the compared algorithms on several large datasets. The rank of $\bm F$ in our DANK model is also given in {\bf bold}.} \label{tablarges} \begin{tabular}{cccccccccccccccccccc} \toprule[1.5pt] \multicolumn{2}{c}{Method} &SVM-SMO & \multicolumn{2}{c}{LogDet} &\multicolumn{2}{c}{BMKL} &RF &\multicolumn{2}{c}{DANK}\cr \cmidrule(lr){1-2} \cmidrule(lr){3-3} \cmidrule(lr){4-5} \cmidrule(lr){6-7} \cmidrule(lr){8-8} \cmidrule(lr){9-10} Dataset&Setting &exact &exact&scalable &exact&scalable &exact &exact(rank.) &scalable(rank.) \cr \midrule[1pt] \multirow{3}{0.5cm}{\emph{EEG}} &acc.(\%) &95.9 &95.9 &95.2 &94.5 &94.1 &80.1 &96.7({\bf 36}) &96.3({\bf 142}) \\ \cmidrule(lr){2-2} \cmidrule(lr){3-3} \cmidrule(lr){4-5} \cmidrule(lr){6-7} \cmidrule(lr){8-8} \cmidrule(lr){9-10} &time(sec.) &8.6 &211.6 &24.6 &1426.3 &124.5 &2.4 &473.6 &39.8 \cr \midrule[1pt] \multirow{3}{0.5cm}{\emph{ijcnn1}} &acc.(\%) &96.5 &97.9 &97.4 &98.5 &97.7 &93.0 &98.9({\bf 342}) &98.4({\bf 1788}) \\ \cmidrule(lr){2-2} \cmidrule(lr){3-3} \cmidrule(lr){4-5} \cmidrule(lr){6-7} \cmidrule(lr){8-8} \cmidrule(lr){9-10} &time(sec.) &112.4 &8472.3 &78.1 &109967 &1916.9 &25.0 &28548 &571.7 \cr \midrule[1pt] \multirow{3}{1cm}{\emph{covtype}} &acc.(\%) &96.1 &$\times$\tnote{1} &96.4 &$\times$ &91.2 &79.1 &$\times$ &97.1 \\ \cmidrule(lr){2-2} \cmidrule(lr){3-3} \cmidrule(lr){4-5} \cmidrule(lr){6-7} \cmidrule(lr){8-8} \cmidrule(lr){9-10} &time(sec.) &3972.5 &$\times$ &5021.4 &$\times$ &94632 &364.5 &$\times$ &7534.2 \cr \bottomrule[1.5pt] \end{tabular} \begin{tablenotes} \footnotesize \item[1] These methods try to directly solve the optimization problem on \emph{covtype} but fail due to the memory limit. \end{tablenotes} \end{threeparttable} \end{table*} To evaluate the ability of our decomposition scheme on large scale situations, we consider three large datasets including \emph{EEG}, \emph{ijcnn1}, and \emph{covtype} to evaluate the kernel approximation performance. Table~\ref{tablarge} reports the dataset statistics (i.e., the feature dimension $d$, the number of training samples, and the number of test data) and parameter settings including the balance parameter $C$, the kernel width $\sigma$, and the number of clusters. Table~\ref{tablarges} presents the test accuracy and training time of various compared algorithms including LogDet, BMKL, our DANK method, SVM-SMO \citep{Platt1999Fast} (the cache is set to 5000) and RF conducted in the following two settings. In the first setting (``exact"), we attempt to directly test these algorithms over the entire training data. \fh{Experimental results indicate that, without the decomposition-based scalable approach, our DANK method achieves the best test accuracy with 96.7\% sand 98.9\% on \emph{EEG} and \emph{ijcnn1}, respectively. However, under this setting, LogDet, BMKL, and our method are just feasible to \emph{EEG} and \emph{ijcnn1}, but fail to deal with an extreme large dataset \emph{covtype} due to the memory limit except SVM-SMO and RF.} In the second setting (``scalable"), we incorporate the kernel approximation scheme into LogDet, BMKL, and DANK evaluated on the three large datasets. Experimental results show that, by such decomposition-based scalable approach, we can speed up the above three methods. For example, when compared with the direct solution of the optimization problem in the ``exact" setting, LogDet, BMKL, and DANK equipped with kernel approximation speed up about 100x, 50x, and 50x on \emph{ijcnn1}, respectively. More importantly, on these three datasets, our DANK method using the approximation scheme still performs better than SVM-SMO on the test accuracy, which demonstrates the effectiveness of the proposed flexible kernel learning framework. From the results in above two settings, we see that our DANK method achieves promising test accuracy no matter whether the kernel approximation scheme is incorporated or not. Moreover, such approximation scheme makes BMKL, LogDet, and our DANK method feasible to large datasets with huge speedup in terms of computational efficiency. \subsubsection{Results on CIFAR-10 dataset} \begin{figure} \centering \pgfplotstableread[row sep=\\,col sep=&]{ interval & carT \\ DANK & 92.68 \\ KNPL & 91.72 \\ VGG16 & 90.87 \\ SVM-CV & 90.35 \\ RF & 87.56 \\ BMKL & 90.55 \\ LogDet & 91.47 \\ }\mydata \begin{tikzpicture}[scale=0.65] \begin{axis}[ ybar, ymajorgrids=true, bar width=.5cm, width=.9\textwidth, height=.5\textwidth, legend style={at={(0.5,1)}, anchor=north,legend columns=-1}, symbolic x coords={DANK, KNPL, VGG16, SVM-CV, RF, BMKL, LogDet}, xtick=data, nodes near coords, nodes near coords align={vertical}, ymin=80,ymax=95, ylabel={\Large Accuracy(\%)}, ] \addplot+[error bars/.cd, y dir=both,y explicit] coordinates { (DANK,92.68) +- (0.0, 0.41) (KNPL,91.72) +- (0.0, 0.52) (VGG16,90.87) +- (0.0, 0.54) (SVM-CV,90.35) +- (0.0, 0.18) (RF,87.56) +- (0.0, 0.92) (BMKL,90.55) +- (0.0, 0.58) (LogDet,91.47) +- (0.0, 0.44)}; \legend{\Large{classification accuracy}} \end{axis} \end{tikzpicture} \caption{Performance of the compared algorithms on \emph{CIFAR-10} dataset.}\label{cifar10} \vspace{-0.1cm} \end{figure} In this section, we test our model on a representative dataset \emph{CIFAR-10} \citep{Krizhevsky2009Learning} for natural image classification task. This dataset contains 60,000 color images with the size of $32 \times 32 \times 3$ in 10 categories, of which 50,000 images are used for training and the rest are for testing. \fh{In our experiment, each color image is represented by the feature extracted from a convolutional neural network, i.e., VGG16 with batch normalization \citep{ioffe2015batch} pre-trained on ImageNet \citep{Deng2009ImageNet}. Then we fine-tune this pre-trained VGG16 model on the CIFAR10 dataset with 240 epochs and a min-batch size of 64.} The learning rate starts from 0.1 and then is divided by 10 at the 120-th, 160-th, and 200-th epoch. After that, for each image, a 4096 dimensional feature vector is obtained according to the output of the first fully-connected layer in this fine-tuned neural network. Figure~\ref{cifar10} shows the test accuracy (mean$\pm$std. deviation \%) of the compared algorithms averaged in ten trials. The original VGG16 model with the softmax classifier achieves 90.87$\pm$0.54\% on the test accuracy. Using the extracted 4096-D feature vectors, kernel learning based algorithms equipped with the initial Gaussian kernel are tuned by 5-fold cross validation on a grid of points, i.e., $\sigma=[0.001,0.01,0.1,1]$ and $C = [1,10,20,30,40,50,80,100]$. In terms of classification performance, SVM-CV, BMKL, LogDet, and KNPL obtain 90.35$\pm$0.18\%, 90.55$\pm$0.58\%, 91.47$\pm$0.44\%, and 91.72$\pm$0.52\% accuracy on the test data, respectively. \changed{M1.10}{\link{R1.10}}{Comparably, our DANK model achieves promising classification accuracy with 92.68$\pm$0.41\%.} \changed{M3.5}{\link{R3.5}}{More importantly, our DANK model outperforms SVM-CV with an accuracy margin of 2.33\%, and is \emph{statistically significant} better than the other methods via paired t-test at the 5\% significance level.} The improvement over SVM-CV on the test accuracy demonstrates that our DANK method equipped with the introduced kernel adjustment strategy is able to enhance the model flexibility, and thus achieves good performance. \subsection{Analysis and Validation for Theoretical Results} \subsubsection{Convergence experiments} \begin{figure} \begin{center} \subfigure[]{\label{subobjf} \includegraphics[width=0.4\textwidth]{Figures/conv_SVM.pdf}} \hspace{1cm} \subfigure[]{\label{subala} \includegraphics[width=0.41\textwidth]{Figures/conv_svm_alpha.pdf}} \caption{Comparison between projected gradient method and our Nesterov's acceleration on \emph{heart} dataset. The \fh{horizontal-axis} is the number of iterations. The \fh{vertical-axis} is the objective function value $H(\bm \alpha, \bm F)$ in (a) and the dual variable difference $\| \bm \alpha^{(t)} - \bm \alpha^{(t-1)} \|_2$ in (b).} \label{conv} \end{center}\vspace{-0.4cm} \end{figure} To investigate the effectiveness of the used Nesterov's smooth optimization method, we conduct a convergence experiment on \fh{the} \emph{heart} dataset when compared to a baseline, i.e., the standard projected gradient method. In Figure~\ref{subobjf}, we plot the objective function value $H(\bm \alpha, \bm F)$ versus iteration by the standard projected gradient method (in blue dashed line) and its Nesterov's acceleration (in red solid line), respectively. One can see that the developed first-order Nesterov's smooth optimization method converges faster than the projected gradient method, so the feasibility of employing Nesterov's acceleration for solving problem~\eqref{mainrank} is verified. Besides, to further illustrate the convergence of $\{ \bm \alpha^{(t)} \}_{t=0}^{\infty}$, we plot $\| \bm \alpha^{(t)} - \bm \alpha^{(t-1)} \|_2$ versus iteration in Figure~\ref{subala}. We find that the sequence $\{ \bm \alpha^{(t)} \}_{t=0}^{\infty}$ yielded by the Nesterov's acceleration algorithm significantly decays in the first 500 iterations, which leads to quick convergence to an optimal solution. Hence, compared with projected gradient method, the Nesterov's smooth optimization method is able to efficiently solve the targeted convex optimization problem in this paper. \subsubsection{Validation for the low rank constraint} \label{sec:explowrank} \begin{figure} \begin{center} \includegraphics[width=0.6\textwidth]{Figures/comparerank.pdf} \caption{Influence of the low rank constraint on test classification accuracy.} \label{figrank} \end{center}\vspace{-0.2cm} \end{figure} In large datasets, we do not consider the low rank regularizer on $\bm F$ due to its inseparable property for efficient optimization. Here we experimentally specialize in the influence of $\| \bm F \|_*$ on the test classification accuracy in both small and large datasets. In terms of small sample case, we choose ten datasets from the UCI database appeared in Section \ref{sec:classUCI} to verify the effectiveness of $\| \bm F \|_*$. Figure~\ref{figrank} shows that, in terms of the test accuracy, apart from \emph{monks1}, \emph{monks2} and \emph{wine} datasets, our method without the low rank regularizer loses about 1\%$\sim$2\% accuracy on the remaining datasets. It indicates that the low rank constraint is important in small-sample datasets and here we attempt to explain this issue. Without the low rank constraint, each entry in the learned adaptive matrix $\bm F$ can arbitrarily vary in the solution space $\mathcal{F}$. As a result, our model has the $\mathcal{O}(n^2)$ capability of ``scattering" $n$ training data, which would lead to over-fitting. Besides, the learned $\bm F$ might be sophisticated, therefore, it is not easily extended to $\bm F'$ for test data by the simple nearest neighbor scheme. \changed{M3.6}{\link{R3.6}}{In terms of large sample case, according to Table~\ref{tablarges}, our DANK model with the ``exact" solution achieves 96.7\% and 98.9\% accuracy on the \emph{EEG} and \emph{ijcnn1} dataset, respectively. In contrast, after omitting the low rank regularizer $\| \bm F \|_*$, the test accuracy of our model in the ``scalable" setting decreases to 96.3\% and 98.4\%, respectively. More importantly, we find that, without the low rank constraint, the rank of $\bm F$ increases from 36 (in the ``exact" setting) to 142 (in the ``scalable" setting) on the \emph{EEG} dataset with 7,490 training samples. This tendency also exhibits on the \emph{ijcnn1} dataset with 49,900 training samples. The rank of $\bm F$ on this dataset increases from $\text{rank}(\bm F) = 342$ to $\text{rank}(\bm F) = 1788$. So the above results indicate that dropping the low rank constraint leads to a slight decrease on the test accuracy; while the rank of $\bm F$ is indeed raising but is still much smaller than $n$. Regarding to the low rank effect of $\bm F$, one hand, in our experiment, the regularization parameter $\eta$ is chosen as $\eta:= \| \bm \alpha \|_2^2 \in \mathcal{O}(n)$. This would be an extreme large value in large sample datasets, resulting in a strong regularization term $\eta \| \bm F - \bm 1 \bm 1^{\!\top} \|_{\F} $. Therefore, $\bm F$ varies around the all-one matrix in a small bounded region and thus shows a low rank effect to some extent. On the other hand, the used Gaussian kernel in large datasets often inherits the rapid decaying spectra \citep{smola2000sparse}, e.g., the exponential decay $\lambda_i \propto e^{-ci}$ with $c > 0$ as illustrated by \cite{bach2013sharp}. Accordingly, the used Gaussian kernel in our DANK model exhibits the exponential decay with finite nonzero eigenvalues, i.e., a low rank structure, which is helpful to obtain a relative low rank kernel matrix $\bm F \odot \bm K$ due to the rank inequality $\text{rank}(\bm F \odot \bm K) \leq \text{rank}(\bm F) \text{rank}(\bm K)$. Based on the above analysis, in large sample case, using the bounded constraint $\eta \| \bm F - \bm 1 \bm 1^{\!\top} \|_{\F} $ could be an alternative choice for the low rank property if we have to drop $\| \bm F \|_*$. This is also demonstrated by our experimental results on the \emph{EEG} and \emph{ijcnn1} datasets. When we discard the low rank constraint, the rank of $\bm F$ indeed increases, but the obtained approximation solution $\bar{ \bm F}$ still prohibits the low rank property when compared to the large number of training samples.} \changed{M2.20}{\link{R2.20}}{From above observations and analyses, we conclude that the low rank constraint in our model is important for small-sample cases. In large-sample datasets, due to the separability requirement, our DANK model has to drop the low rank constraint, and thus achieving a slight decrease on the final classification accuracy. Nevertheless, the employed bounded constraint, a strong regularization effect in large sample cases, restricts $\bm F$ to a small bounded region around the all-one matrix, which would be an alternative choice to seek for a low rank matrix $\bar{\bm F}$.} \subsubsection{Validation for our derived bounds} \label{sec:bound} \begin{figure} \centering \subfigure[$\| \bm \alpha^* - \bar{\bm \alpha} \|^2_2$]{\label{alphabound} \includegraphics[width=0.3\textwidth]{Figures/Visio-alphabound.pdf}} \hspace{0.3cm} \subfigure[$\| \bm F^* - \bar{\bm F} \|_{\F}$]{\label{fvaluebound} \includegraphics[width=0.3\textwidth]{Figures/Visio-fbound.pdf}} \hspace{0.3cm} \subfigure[non-support vectors]{\label{gradbound} \includegraphics[width=0.31\textwidth]{Figures/Visio-gradbound.pdf}} \caption{Experimental demonstration of the derived bounds in Theorem~\ref{theorappv} and~\ref{theorsv}. }\label{thm4bound} \end{figure} Here we show that the derived bounds in Theorem~\ref{theorappv} and~\ref{theorsv} are tight in practice. To verify the results of Theorem~\ref{theorappv}, we randomly select 2,000 samples from the \emph{ijcnn1} dataset, and consider different number of clusters $v=2,5,10$. For each $v$, the kernel kmeans outputs the data partition $\{ \mathcal{V}_1, \mathcal{V}_2,\dots, \mathcal{V}_v \}$ and then obtains the \fh{solving result} $\| \bm \alpha^* - \bar{\bm \alpha} \|^2_2$ (in blue) and the derived bound $\frac{B_2C^2Q(\pi)}{B_1 \| \bm K \|_{\F}} + \frac{2BC^2}{B_1}$ (in red) as shown in Figure~\ref{alphabound}. We can find that the derived bound is close to the solving result. And specifically, it is far smaller than the exact bound $\| \bm \alpha^* - \bar{\bm \alpha} \|^2_2 \leq nC^2 = 2.048\times 10^6$. Similarly, in Figure~\ref{fvaluebound}, we present the solving result $ \| \bm F^* - \bar{\bm F} \|_{\F}$ (in blue), our derived bound in Theorem~\ref{theorappv} (in red), and the exact bound $n\max\{\sqrt{B},B \}$ (in black), respectively. It can be found that these three results are close in an absolute sense. Thus, the two panels demonstrate that the data partition scheme can lead to good approximation to the exact solution $(\bm \alpha^*, \bm F^*)$, and our derived bounds in Theorem~\ref{theorappv} are tight in practical situations. \changed{M2.18.2}{\link{R2.18}}{In Figure~\ref{gradbound}, we validate that the derived condition in Theorem~\ref{theorsv} is useful for screening non-support vectors. In our experiment, We also randomly select 2,000 samples from the \emph{ijcnn1} dataset, set $v=10$, and obtain the approximation solution $(\bar{\bm \alpha}, \bar{\bm F})$. We compute the gradient $\Big(\! \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \!\Big)_{\!i}$ associated with each sample and plot the support vectors (in green) and non-support vectors (in blue) as shown in Figure~\ref{gradbound}. Using the condition~\eqref{gradsvc} in Theorem~\ref{theorsv}, the non-support vectors that satisfy $\Big(\! \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \!\Big)_{\!i} \leq (B \!+\! B_2)C \left(\| \bar{\bm K}_i \|_1 \!+\! \kappa \right) = 442.3$ can be directly recognized as non-support vectors (marked in red) without solving the optimization problem. We find that in the total of \#SVs=214 (the number of support vectors) and \#non-SVs=1786 (the number of non-support vectors), there are 723 non-support vectors recognized by our Theorem~\ref{theorsv}. That means, over 40\% non-support vectors can be picked out, which demonstrates the effectiveness of our derived bound/condition in Theorem~\ref{theorsv}. } \subsubsection{Validation for out-of-sample extensions} \label{sec:validate} \begin{figure} \centering \subfigure[accuracy]{\label{accknn} \includegraphics[width=0.35\textwidth]{Figures/Visio-accknn.pdf}} \hspace{0.5cm} \subfigure[time cost]{\label{timeknn} \includegraphics[width=0.365\textwidth]{Figures/Visio-timeKNN.pdf}} \caption{Classification accuracy and time cost of various out-of-sample extension based algorithms.}\label{knntenc} \end{figure} Here we attempt to validate the effectiveness of the proposed reciprocal nearest neighbor (NN) scheme. The compared algorithms include the k-NN strategy with k=1 and k=5. And specifically, the current state-of-the-art method \citep{Pan2016Out} in out-of-sample extension is taken into consideration. It is formulated as a regression problem in a hyper-RKHS spanned by a reproducing hyper-kernel \citep{Cheng2005Learning}, i.e., a regression function is learned from the nonparametric kernel matrix $\bm K$ by the developed nonnegative least-squares in this space. Since each element in hyper-RKHS is a kernel function, the learned regression function is also a kernel as expected, achieving the goal for out-of-sample extension. Figure~\ref{accknn} shows the test classification accuracy under different numbers of training data ($n=100,200,300,400,500$) from the \emph{ijcnn1} dataset. It can be observed that our reciprocal nearest neighbor scheme outperforms the standard k-NN strategy but is inferior to \citep{Pan2016Out}. We can also find that when fewer data are taken for training (e.g., 100), the nearest neighbor scheme leads to a large variance. Comparably, our reciprocal nearest neighbor scheme is more robust and thus performs stably in the sample scarcity case. In terms of time cost, Figure~\ref{timeknn} shows that these three nearest neighbor schemes achieve similar computational efficiency, but are more efficient than \citep{Pan2016Out}. Admittedly, \citep{Pan2016Out} achieves better classification accuracy to some extent, but it is time-consuming when compared to our nearest neighbor based scheme. This is because, learning in hyper-RKHS often needs $\mathcal{O}(n^4)$ complexity. Instead, the reciprocal nearest neighbor scheme only needs $\mathcal{O}(n^2)$ for out-of-sample extension. Hence, our scheme is simple but effective, achieving a good trade-off between the accuracy and the time cost. \subsubsection{Parameter sensitivity analysis} \label{sec:paramana} \changed{M3.3}{\link{R3.3}}{The objective function~\eqref{mainrank} in our DANK model contains two regularization parameters $\tau$ and $\eta$. In our experiments, we empirically set $\tau = 0.01$ and choose $\eta = \| \bm \alpha \|_2^2$, where $\bm \alpha$ is obtained by SVM. Therefore, we discuss whether the choices of them will significantly influence the performance of the proposed DANK model. Figure~\ref{taup} shows the test accuracy of our algorithm under different $\tau$ values, $0.001,0.01,0.1,0.5,1$ on the \emph{diabetic}, \emph{heart}, \emph{monks1}, \emph{monks2}, and \emph{monks3} datasets. The classification results clearly indicate that our DANK model is robust to the variations of $\tau$ in a wide range, so it can be easily tuned and we directly set it $\tau=0.01$ as for practical use. Moreover, we investigate whether the output of our DANK model is sensitive to the variations of $\eta := \{ 0.001, 0.01, 0.1, 1, 10, 100 \}C^2$ on the above five datasets. Our method with $\eta:=\| \bm \alpha \|_2^2$ serves as a baseline (in black dash line) as shown in Figure~\ref{etap}. It can be found that, the test accuracy achieves the summit at different $\eta$ on these five datasets, some of which even exceed our adaptive one with $\|\bm \alpha\|_2^2$. Nevertheless, we can set $\eta = 0.1C^2$ as an alternative choice if we have no prior on $\bm \alpha$. } \begin{figure} \centering \includegraphics[width=0.1\textwidth]{Figures/Visio-paramsenleg.pdf} \subfigure[parameter sensitivity of $\tau$]{\label{taup} \includegraphics[width=0.35\textwidth]{Figures/Visio-paramsentau.pdf}} \hspace{0.1cm} \subfigure[parameter sensitivity of $\eta:=\text{x}C^2$]{\label{etap} \includegraphics[width=0.365\textwidth]{Figures/Visio-paramseneta.pdf}} \caption{Parameter sensitivity analysis of $\tau$ and $\eta$.}\label{paramsena} \end{figure} \subsection{Regression} This section focuses on the proposed DANK model embedded in SVR for regression tasks. We firstly conduct the experiments on several synthetic datasets, to examine the performance of our method on recovering 1-D and 2-D test functions. Then, eight regression datasets\footnote{The datasets are available at \url{http://www.csie.ntu.edu.tw/~cjlin/libsvmtools/datasets/binary.html} } are used to test our model and other representative regression algorithms. The used evaluation metric here is relative mean square error (RMSE) between the learned regression function $\hat{g}(\bm x)$ and the target label $\bm y$ over $n$ data points \begin{equation*} \mbox{RMSE} = \frac{\sum_{i=1}^n\big(\hat{g}(\bm x_i) - y_i \big)^2}{\sum_{i=1}^{n} \big( y_i - \mathbb{E}(\bm y) \big)^2} \,. \end{equation*} \subsubsection{Synthetic Data} Here we test the approximation performance of our method on 1-D and 2-D test functions compared with a baseline, the SVR with Gaussian kernel. The representative 1-D step function is defined by \begin{equation*} g(s,w,a,x) = \bigg( \frac{\tanh \big( \frac{ax}{w} -a \lfloor \frac{x}{w}\rfloor - \frac{a}{2} \big) }{2 \tanh \big( \frac{a}{2} \big)} + \frac{1}{2} + \left\lfloor \frac{x}{w} \right\rfloor \bigg)s\,, \end{equation*} where $s$ is the step hight, $w$ is the period, and $a$ controls the smoothness of the function $g$. In our experiment, $s,w$ and $a$ are set to 3, 2 and 0.05, respectively. We plot the step function on $[-5,5]$ as shown in Figure~\ref{figstep}. One can see that the approximation function generated by SVR-CV (blue dashed line) yields a larger deviation than that of our DANK model (red solid line). To be specific, the RMSE of SVR is 0.013, while our DANK model achieves a promising approximation error with a value of 0.004. \begin{figure*}[!htb] \centering \subfigure[recovering a step function]{\label{figstep} \includegraphics[width=0.32\textwidth]{Figures/stepf.pdf}} \hspace{0.5cm} \subfigure[a 2-D function]{\label{fig2d} \includegraphics[width=0.32\textwidth]{Figures/polyf.pdf}} \subfigure[recovering by SVR-CV]{\label{fig2dsvr} \includegraphics[width=0.32\textwidth]{Figures/polyf_SVR.pdf}} \hspace{0.5cm} \subfigure[recovering by DANK]{\label{fig2dknpl} \includegraphics[width=0.32\textwidth]{Figures/polyf_our.pdf}} \caption{Approximation for 1-D and 2-D functions by SVR-CV and our DANK model. }\label{figtoy} \end{figure*} Apart from the 1-D function, we use a 2-D test function to test SVR-CV and the proposed DANK model. The 2-D test function \citep{cherkassky1996comparison} $g(u,v) \in [-0.5,0.5] \times [-0.5,0.5]$ is established as \begin{equation*} g(u,v) = 42.659\Big(0.1+(u - 0.5)\big( g_1(u, v) + 0.05\big) \Big)\,, \end{equation*} where $g_1(u, v)$ is defined by \begin{equation*} g_1(u, v) \!=\! (u - 0.5)^4 \!- 10(u \!- 0.5)^2 (v \!- 0.5)^2 \!+ 5 (v \!- 0.5)^4\,. \end{equation*} We uniformly sample 400 data points by $g(u,v)$ as shown in Figure~\ref{fig2d}, and then use SVR-CV and DANK to learn a regression function from the sampled data. The regression results by SVR-CV and our DANK model are shown in Figure~\ref{fig2dsvr} and Figure~\ref{fig2dknpl}, respectively. Intuitively, when we focus on the upwarp of the original function, our method is more similar to the test function than SVR-CV. In terms of RMSE, the error of our method for regressing the test function is 0.007, which is lower than that of SVR-CV with 0.042. \begin{table*} \centering \fontsize{9}{8}\selectfont \caption{Comparison results of various methods on UCI datasets in terms of RMSE (mean$\pm$std. deviation \%). The best performance is highlighted in \textbf{bold}. The RMSE on the training data is presented by \emph{italic}, and does not participate in ranking. Notation ``$\bullet$" indicates that the method is significantly better than other baseline methods via paired t-test.} \begin{tabular}{cccccccccc} \toprule[2pt] \multirow{2}{*}{Dataset} &\multirow{2}{*}{($d$, $n$)} &\multicolumn{1}{c}{BMKL } &\multicolumn{1}{c}{NW} &\multicolumn{2}{c}{SVR-CV} &\multicolumn{2}{c}{DANK}\cr \cmidrule(lr){3-4} \cmidrule(lr){5-6} \cmidrule(lr){7-8} {}&{}&Test&Test &Training&Test&Training&Test\cr \midrule[1pt] bodyfat &(14, 252) & 0.101$\pm$0.065 & 0.097$\pm$0.010 & \emph{0.007$\pm$0.000} & 0.101$\pm$0.002 & \emph{0.008$\pm$0.000} & {\bf 0.091}$\pm$0.013 \\ \hline pyrim &(27, 74) & 0.512$\pm$0.115 & 0.604$\pm$0.115 & \emph{0.013$\pm$0.010} & 0.678$\pm$0.255 & \emph{0.007$\pm$0.004} & {\bf 0.457}$\pm$0.143$\bullet$ \\ \hline space &(6, 3107) & 0.248$\pm$0.107 & 0.308$\pm$0.004 & \emph{0.226$\pm$0.144} & 0.261$\pm$0.112 & \emph{ 0.106$\pm$0.067} & {\bf 0.202}$\pm$0.114$\bullet$ \\ \hline triazines &(60, 186) & {\bf 0.725}$\pm$0.124 & 0.885$\pm$0.039 & \emph{0.113$\pm$0.084} & 0.815$\pm$0.206 & \emph{0.009$\pm$0.012} & {0.734$\pm$0.128} \\ \hline cpusmall &(12, 8912) & 0.133$\pm$0.004 & {\bf 0.037}$\pm$0.009 & \emph{0.037$\pm$0.004} & 0.104$\pm$0.002 & \emph{0.001$\pm$0.000} & {0.114}$\pm$0.003 \\ \hline housing &(13, 506) & 0.286$\pm$0.027 & {\bf 0.177}$\pm$0.015$\bullet$ & \emph{0.085$\pm$0.049} & 0.267$\pm$0.023 & \emph{0.069$\pm$0.013} & 0.218$\pm$0.013 \\ \hline mg &(6, 1385) & 0.297$\pm$0.013 & {\bf 0.294}$\pm$0.010 & \emph{0.163$\pm$0.076} & {0.407}$\pm$0.118 & \emph{0.134$\pm$0.055} &{0.303}$\pm$0.058\\ \hline mpg &(7, 392) & 0.187$\pm$0.014 & 0.182$\pm$0.012 & \emph{0.095$\pm$0.087} & 0.193$\pm$0.006 & \emph{0.061$\pm$0.010 }& {\bf 0.173}$\pm$0.008$\bullet$ \\ \bottomrule[2pt] \end{tabular} \label{UCIreg} \end{table*} \subsubsection{Regression Results on UCI datasets} For real-world situations, we compare the proposed DANK model with other representative regression algorithms on eight datasets from the UCI database. \cite{Gonen2012Bayesian} extend BMKL to regression tasks, and thus we include it for comparisons. Apart from SVR-CV and BMKL, the Nadaraya-Watson (NW) estimator with metric learning \citep{noh2017generative} is also taken into comparison. The remaining experimental settings follow with the classification tasks on the UCI database illustrated in Section~\ref{sec:classUCI}. Table~\ref{UCIreg} lists a brief statistics of these eight datasets, and reports the average prediction accuracy and standard deviation of every compared algorithm. \fh{Moreover}, we present the regression performance of our DANK model and SVR-CV on the training data to show their respective model flexibilities. We find that, the proposed DANK model exhibits more encouraging performance than SVR-CV in terms of the RMSE on the training and test data. From the results on four datasets including \emph{bodyfat}, \emph{pyrim}, \emph{space}, and \emph{mpg}, we observe that our method statistically achieves the best prediction performance. On the remaining datasets, our DANK model achieves comparable performance with BMKL and NW. \section{Conclusion} \label{sec:conclusion} In this work, we propose an effective data-adaptive strategy to enhance the model flexibility for nonparametric kernel learning based algorithms. \changed{M1.12}{\link{R1.12}}{In our DANK model, a multiplicative scale factor for each entry of the Gram matrix can be learned from the data, leading to an improved data-adaptive kernel. As a result of such data-driven scheme, the model flexibility of our DANK model embedded in SVM (for classification) and SVR (for regression) is demonstrated by the experiments on synthetic and real datasets. Specifically, this model can be learned in one-stage process with $\mathcal{O}(1/t^2)$ convergence rate due to the studied gradient-Lipschitz continuous property, where $t$ is the iteration number. That means, we can simultaneously train the SVM or SVR along with optimizing the data-adaptive matrix by a projected gradient method with Nesterov's acceleration.} In addition, we develop a decomposed-based scalable approach to make our DANK model feasible to large datasets, of which the effectiveness has been verified by both experimental results and theoretical demonstration. \appendices \section{Proofs for gradient-Lipschitz continuity} \subsection{Proofs of Lemma~\ref{gammabound}} \label{proofgammabound} \begin{proof} Since $\mathcal{J}_{\frac{\tau}{2}}$ is non-expansive \citep{Ma2011Fixed}, i.e., for any ${\bm \Omega}_1$ and ${\bm \Omega}_2$ \begin{equation*} \| \mathcal{J}_{\frac{\tau}{2}}({\bm \Omega}_1) - \mathcal{J}_{\frac{\tau}{2}}({\bm \Omega}_2) \|_{\F} \leq \| {\bm \Omega}_1 - {\bm \Omega}_2 \|_{\F}\,, \end{equation*} with $\bm \Omega_1 = {\bm 1}{\bm 1}^{\top}+{\bm \Gamma}(\bm \alpha_1)$ and $\bm \Omega_2 = {\bm 1}{\bm 1}^{\top}+{\bm \Gamma}(\bm \alpha_2)$. Thereby, we have \begin{small} \begin{equation*}\label{boundgam} \begin{split} & \big\| \bm F(\bm \alpha_1) - \bm F(\bm \alpha_2)\big\|_{\F} \leq \big\| {\bm \Gamma}(\bm \alpha_1) - {\bm \Gamma}(\bm \alpha_2) \big\|_{{\F}} \\ &\!=\! \frac{1}{4\eta} \Big\|\! \diag\!\big({\bm \alpha_1}^{\!\!\!\top}\!\bm{Y}\big) \bm{K} \! \diag\!\big({\bm \alpha_1}^{\!\!\!\top}\!\bm{Y}\big) \!-\!\diag\!\big({\bm \alpha_2}^{\!\!\!\top}\!\bm{Y}\big) \bm{K} \! \diag\!\big({\bm \alpha_2}^{\!\!\!\top}\!\bm{Y}\big) \Big\|_{\F} \\ &\!=\! \frac{1}{4\eta} \Big\| \diag\big({\bm \alpha_1}^{\!\top} \bm{Y} + {\bm \alpha_2}^{\!\top} \bm{Y}\big) \bm{K}\diag\big({\bm \alpha_1}^{\!\top}\bm{Y} - {\bm \alpha_2}^{\!\top} \bm{Y}\big) \Big\|_{\F} \\ & \!\leq\! \frac{1}{4\eta} \| \bm{K}\|_{\F} \Big\| \diag\!\big({\bm \alpha_1}^{\!\!\top} \!\bm{Y} \!+\! {\bm \alpha_2}^{\!\!\top}\! \bm{Y}\big) \Big\|_{\F} \Big\| \diag\big({\bm \alpha_1}^{\!\top} \bm{Y} \!-\! {\bm \alpha_2}^{\!\top} \bm{Y}\big) \Big\|_{\F} \\ & \!\leq\! \frac{\|\bm{K}\|_\text{F}}{4\eta} \big\| {\bm \alpha_1} + {\bm \alpha_2} \big\|_2 \big\| {\bm \alpha_1} - {\bm \alpha_2} \big\|_2\,, \end{split} \end{equation*} \end{small} which yields the desired result. \end{proof} \subsection{Proofs of Theorem~\ref{theor}} \label{prooftheor} \begin{proof} The gradient of $h ({\bm \alpha})$ in Eq.~\eqref{falpha} is computed as \begin{equation}\label{gradf} \nabla h ({\bm \alpha}) = \bm{1} - \bm{Y}\big(\bm{F}({\bm \alpha})\odot\bm{K}\big)\bm{Y} {\bm \alpha}\,. \end{equation} It is obvious that $\bm{F}({\bm \alpha})$ is unique over the compact set $\mathcal{F}$. Hence, according to the differentiable property of the optimal value function \citep{penot2004differentiability}, for any $\bm \alpha_1$, $\bm \alpha_2$ $\in \mathcal{A}$, from the representation of $\nabla h(\bm \alpha)$ in Eq.~\eqref{gradf}, the function $h ({\bm \alpha})$ is proven to be gradient-Lipschitz continuous \begin{equation}\label{proof2} \begin{split} \| \nabla h(\bm \alpha_1) \!-\! \nabla h(\bm \alpha_2) \|_2 &=\big\| \bm{Y}\big(\bm{F}_1\odot\bm{K}\big)\bm{Y} {\bm \alpha_1} - \bm{Y}\big(\bm{F}_2\odot\bm{K}\big)\bm{Y} {\bm \alpha_2} \big\|_2 \\ & = \big\| \bm{Y}\big(\bm{F}_1\! -\! \bm{F}_2 \big)\odot\bm{K}\bm{Y} {\bm \alpha_1} \!- \!\bm{Y}\big(\bm{F}_2\odot\bm{K}\big)\bm{Y} \big( {\bm \alpha_2}\!-\! {\bm \alpha_1} \big) \big\|_2 \\ & \!\leq\! \big\| \bm{Y}\big(\bm{F}_1 - \bm{F}_2 \big)\odot\bm{K}\bm{Y} {\bm \alpha_1} \big\|_2 + \big\| \bm{Y}\big(\bm{F}_2\odot\bm{K}\big)\bm{Y} \big( {\bm \alpha_2}- {\bm \alpha_1} \big) \big\|_2 \\ &\! \leq\! \big\| \big(\bm{F}_1 - \bm{F}_2 \big)\odot\bm{K} \big\|_{\F} \| {\bm \alpha_1}\|_2 + \big\| \bm{F}_2\odot\bm{K} \big\|_{\F} \| {\bm \alpha_1}- {\bm \alpha_2} \|_2~~~\\ & \!\leq\! \big\| \bm{F}_1 - \bm{F}_2 \big\|_{\F} \| \bm{K} \|_{\F} \| {\bm \alpha_1}\|_2 + \| \bm{F}_2 \|_{\F} \| \bm{K} \|_{\F} \| {\bm \alpha_1}- {\bm \alpha_2} \|_2 \\ &\! \leq \frac{ \|\bm{K}\|_{\F}^2}{4\eta} \| {\bm \alpha_1} \|_2 \big( \| {\bm \alpha_1} \|_2 + \| {\bm \alpha_2} \|_2 \!\big) \| {\bm \alpha_1}- {\bm \alpha_2} \|_2 +\lambda_{\max}(\bm F_2)\| \bm{K} \|_{\F} \| {\bm \alpha_1}- {\bm \alpha_2} \|_2 \\ &\! \leq \! \frac{ \|\bm{K}\|^2_{\F}}{4\eta} \| {\bm \alpha_1} \|_2 \big( \| {\bm \alpha_1} \|_2 + \| {\bm \alpha_2} \|_2 \big) \| {\bm \alpha_1} - {\bm \alpha_2} \|_2\!+\! \big(n+\frac{nC^2}{4\eta}\lambda_{\max}(\bm K)\big) \| \bm{K} \|_{\F} \| {\bm \alpha_1}\!-\! {\bm \alpha_2} \|_2 \\ & \!\leq\! \Big( n + \frac{ 3nC^2 \|\bm{K}\|_{\F}^2}{4\eta} \Big) \| {\bm \alpha_1}- {\bm \alpha_2} \|_2\,, \end{split} \end{equation} where the third equality holds by $\| \bm{A} \odot \bm{B}\|_{\F} \leq \text{Tr}(\bm{A}\bm{B}^{\top})\leq \| \bm{A} \|_{\F} \| \bm{B}\|_{\F}$. The fourth equality admits due to Lemma \ref{gammabound} and $\bm F_2 \in \mathcal{B}$. By Lemma~\ref{fbound}, we can derive the fifth equality. The last equality is achieved by $0 \leq {\bm \alpha} \leq C,~\|{\bm \alpha}\|^2_2\leq nC^2, \lambda_{\max}(\bm K) \leq \| \bm K \|_{\F}$. The Lipschitz constant is $L = n + \frac{ 3nC^2 \|\bm{K}\|_{\F}^2}{4\eta}$. Hence, we conclude the proof. \end{proof} \subsection{Proofs of Theorem~\ref{theorsvr}} \label{prooftheorsvr} \begin{proof} For any $\hat{\bm \alpha}_1, \check{\bm \alpha}_1, \hat{\bm \alpha}_2, \check{\bm \alpha}_2 \in \mathcal{A}$, from the representation of $\nabla_{\hat{\bm \alpha}} h(\hat{\bm \alpha}, \check{\bm \alpha})$ in Proposition \ref{theorgradsvr}, we have \begin{equation}\label{proof2svr} \begin{split} &\Big\| \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha}_1)}}}{\partial \hat{\bm \alpha}}\!\big|_{\hat{\bm \alpha} = \hat{\bm \alpha}_1} \!\!- \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha}_2)}}}{\partial \hat{\bm \alpha}}\!\big|_{\hat{\bm \alpha} \!=\! \hat{\bm \alpha}_2} \Big \|_2 \!=\! \big\| \big({\bm{F}}_1 \!-\! {\bm{F}}_2 \big)\odot\bm{K} \big({\hat{\bm \alpha}_1 \!-\! \check{\bm \alpha}_1}\big) \!-\! \big({\bm{F}}_2\odot\bm{K}\big) \big( \hat{\bm \alpha}_2 \!-\! \check{\bm \alpha}_2 \!-\! \hat{\bm \alpha}_1 \!+\! \check{\bm \alpha}_1 \big) \big\|_2 \\ &~~~~ \leq \big\| {\bm{F}}_1 - {\bm{F}}_2 \big\|_{\F} \| \bm{K} \|_{\F} \| {\hat{\bm \alpha}_1- \check{\bm \alpha}_1}\|_2 + \| \bm{F}_2 \|_{\F} \| \bm{K} \|_{\F} \| \hat{\bm \alpha}_2- \check{\bm \alpha}_2 - \hat{\bm \alpha}_1+ \check{\bm \alpha}_1 \|_2 \\ &~~~~ \leq \bigg( \frac{ \|\bm{K}\|_{\F}^2}{4\eta} \| {\hat{\bm \alpha}_1- \check{\bm \alpha}_1} \|_2 \| \hat{\bm \alpha}_2- \check{\bm \alpha}_2 + \hat{\bm \alpha}_1- \check{\bm \alpha}_1 \|_2 +\lambda_{\max}(\bm F_2)\| \bm{K} \|_{\F} \bigg) \| \hat{\bm \alpha}_2- \check{\bm \alpha}_2 - \hat{\bm \alpha}_1+ \check{\bm \alpha}_1 \|_2 \\ &~~~~ \leq \bigg( \frac{ 8nC^2\|\bm{K}\|_{\F}^2}{4\eta} +n+\frac{nC^2}{4\eta}\lambda_{\max}(\bm K)\| \bm{K} \|_{\F} \bigg) \bigg( \| \hat{\bm \alpha}_2 - \hat{\bm \alpha}_1 \|_2 +\| \check{\bm \alpha}_2 -\check{\bm \alpha}_1 \|_2 \bigg) \\ &~~~~ \leq \Big( n + \frac{ 9nC^2 \|\bm{K}\|_{\F}^2}{4\eta} \Big) \bigg( \| \hat{\bm \alpha}_2 - \hat{\bm \alpha}_1 \|_2 +\| \check{\bm \alpha}_2 - \check{\bm \alpha}_1 \|_2 \bigg)\,. \end{split} \end{equation} Similarly, $\Big\| \frac{\partial {{{h}(\hat{\bm \alpha}_1, \check{\bm \alpha})}}}{\partial \check{\bm \alpha}}\!\big|_{\check{\bm \alpha} = \check{\bm \alpha}_1} \!\!- \frac{\partial {{{h}(\hat{\bm \alpha}_2, \check{\bm \alpha})}}}{\partial \check{\bm \alpha}}\!\big|_{\check{\bm \alpha} = \check{\bm \alpha}_2} \Big \|_2 $ can also be bounded. Combining these two inequalities, we have \begin{equation}\label{gradsvrsub} \begin{split} \|\nabla_{ \!\tilde{\bm \alpha}_1} \! {h}(\hat{\bm \alpha}_1, \! \check{\bm \alpha}_1 \!) \! - \! \nabla_{ \!\tilde{\bm \alpha}_2} \! {h}( \hat{\bm \alpha}_2, \! \check{\bm \alpha}_2 ) \|_2 & \leq \Big\| \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha}_1)}}}{\partial \hat{\bm \alpha}}\!\big|_{\hat{\bm \alpha} = \hat{\bm \alpha}_1} \!\!- \frac{\partial {{{h}(\hat{\bm \alpha}, \check{\bm \alpha}_2)}}}{\partial \hat{\bm \alpha}}\!\big|_{\hat{\bm \alpha} = \hat{\bm \alpha}_2} \Big \|_2 \\ & + \Big\| \frac{\partial {{{h}(\hat{\bm \alpha}_1, \check{\bm \alpha})}}}{\partial \check{\bm \alpha}}\!\big|_{\check{\bm \alpha} = \check{\bm \alpha}_1} \!\!- \frac{\partial {{{h}(\hat{\bm \alpha}_2, \check{\bm \alpha})}}}{\partial \check{\bm \alpha}}\!\big|_{\check{\bm \alpha} = \check{\bm \alpha}_2} \Big \|_2 \\ & \leq 2L \Big( \! \| \hat{\bm \alpha}_2 \!- \! \hat{\bm \alpha}_1 \|_2 \!+ \! \| \check{\bm \alpha}_2 \!- \! \check{\bm \alpha}_1 \|_2 \! \Big)\,. \end{split} \end{equation} Thus, we complete the proof. \end{proof} \section{Proofs in large scale situations} \subsection{Proofs of Lemma~\ref{lemmalink}} \label{prooflemmalink} \begin{proof} The quadratic term with respect to $\bm \alpha$ in Eq.~\eqref{mainls} can be decomposed into \begin{equation*} \bm \alpha^{\!\!\top}\!\bm Y\! \big(\bm{F}\odot \bar{\bm{K}} \big)\bm{Y}\! {\bm \alpha} \!=\! \sum_{c=1}^{v} {\bm \alpha^{(c)}}^{\!\!\top}\bm{Y}^{(c,c)}\big(\bm{F}^{(c,c)}\odot\bm{K}^{(c,c)}\big) \bm{Y}^{(c,c)}\! {\bm \alpha}^{(c)}\,, \end{equation*} and $\| \bm{F} - \bm{1} \bm{1}^{\!\top} \|_{{\F}}^2$ can be expressed as \begin{equation*} \| \bm{F} - \bm{1} \bm{1}^{\!\top} \|_{{\F}}^2 = \sum_{i,j=1}^{n} (F_{ij}-1)^2 = \sum_{c=1}^{v} \| \bm F^{(c,c)} - \bm{1} \bm{1}^{\top} \|_{{\F}}^2 + \mbox{Const}\,, \end{equation*} where the constant is the sum of non-block-diagonal elements of $\bar{\bm F}$, and it does not affect the solution of Eq.~\eqref{mainlslemma}. Specifically, the positive semi-definiteness on $\bar{\bm F}^{(c,c)}$ with $c=1,2,\dots,v$ still guarantees that the whole matrix $\bar{\bm F}$ is PSD. Besides, the constraint in Eq.~\eqref{mainlslemma} is also decomposable, so the subproblems are separable and independent. As a result, the concatenation of their optimal solutions yields the optimal solution of Eq.~\eqref{mainlslemma}. \end{proof} \subsection{Proofs of Theorem~\ref{theorappf}} \label{prooftheorappf} \begin{proof} We use $\bar{H}(\bm \alpha, \bm F)$ to denote the objective function in Eq.~\eqref{mainlslemma} with the Gram matrix $\bar{\bm K}$. Hence, the optimal solution $(\bar{\bm \alpha},\bar{\bm{F}})$ is a saddle point for the function $\bar{H}({\bm \alpha},\bm{F})$ due to the max-min problem in Eq.~\eqref{mainlslemma}. It is easy to check $\bar{H}({\bm \alpha},\bar{\bm{F}}) \leq \bar{H}(\bar{{\bm \alpha}},\bar{\bm{F}}) \leq \bar{H}(\bar{{\bm \alpha}},\bm{F})$ for any feasible $\bm \alpha$ and $\bm F$. Defining $H(\bm \alpha^*, \bm F^*)$ and $\bar{H}(\bm \alpha^*, \bm F^*)$, we can easily obtain \begin{equation}\label{hbarstar} \bar{H}(\bm \alpha^*, \bm F^*) \!-\! H(\bm \alpha^*, \bm F^*) \!= \! \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \! \alpha_i^* \alpha_j^* y_i y_j F^*_{ij} K_{ij}\,, \end{equation} with $ F^*_{ij}\triangleq \bm F^*(\bm x_i, \bm x_j)$. Similarly, we have \begin{equation*}\label{hbarbara} \bar{H}(\bar{\bm \alpha}, \bm F^*)\! - \!H(\bar{\bm \alpha}, \bm F^*) \!=\! \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \bar{\alpha}_i \bar{\alpha}_j y_i y_j F^*_{ij} K_{ij}\,. \end{equation*} Therefore, combining above equations, the upper bound of $H(\bm \alpha^*, \bm F^*) - {H}(\bar{\bm \alpha}, \bar{\bm F})$ can be derived by \begin{equation*}\label{process1} \begin{split} H(\bm \alpha^*, \bm F^*)& \leq \bar{H}(\bar{\bm \alpha}, \bm F^*) - \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \alpha_i^* \alpha_j^* y_i y_j F^*_{ij} K_{ij} \\ &\! = \!H(\bar{\bm \alpha}, \bm F^*) \!-\! \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \Big( \alpha_i^* \alpha_j^* - \bar{\alpha}_i \bar{\alpha}_j \Big) y_i y_j F^*_{ij} K_{ij}\\ & \!\leq\! {H}(\bar{\bm \alpha}, \bar{\bm F}) - \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \Big(\alpha_i^* \alpha_j^* - \bar{\alpha}_i \bar{\alpha}_j \Big) y_i y_j F^*_{ij} K_{ij}\\ &\! \leq \! {H}(\bar{\bm \alpha}, \bar{\bm F}) + \frac{1}{2}BC^2 Q(\pi)\,, \end{split} \end{equation*} where the first inequality holds by $\bar{H}(\bm \alpha^*, \bm F^*) \leq \bar{H}(\bar{\bm \alpha}, \bm F^*)$ and Eq.~\eqref{hbarstar}. The second inequality admits by $H(\bar{\bm \alpha}, \bm F^*) \leq {H}(\bar{\bm \alpha}, \bar{\bm F})$. Similarly, $H(\bm \alpha^*, \bm F^*) - {H}(\bar{\bm \alpha}, \bar{\bm F})$ is lower bounded by \begin{equation*} \begin{split} H(\bm \alpha^*, \bm F^*) &= \bar{H}({\bm \alpha}^*, \bm F^*) \!-\! \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \alpha_i^* \alpha_j^* y_i y_j F^*_{ij} K_{ij} \\ & \geq \bar{H}({\bm \alpha}^*, \bar{\bm F}) - \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \alpha_i^* \alpha_j^* y_i y_j F^*_{ij} K_{ij} \\ & = \bar{H}({\bm \alpha}^*, \bar{\bm F}) + \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \alpha_i^* \alpha_j^* y_i y_j (\bar{ F}_{ij} - F^*_{ij} ) K_{ij} \\ & \geq {H}(\bar{\bm \alpha}, \bar{\bm F}) + \frac{1}{2} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \alpha_i^* \alpha_j^* y_i y_j (\bar{F}_{ij} - F^*_{ij} ) K_{ij} \\ & \geq {H}(\bar{\bm \alpha}, \bar{\bm F}) - \frac{1}{2}BC^2 Q(\pi)\,, \end{split} \end{equation*} which concludes the proof that $\left| H(\bm \alpha^*, \bm F^*) - H(\bar{\bm \alpha},\!\bar{\bm{F}}) \right| \leq \frac{1}{2}BC^2Q(\pi)$. \end{proof} \subsection{Proofs of Theorem~\ref{theorappv}} \label{prooftheorappv} \begin{proof} We firstly derive the error bound with respect to $\bm \alpha$, and then bound $\| \bm F^* - \bar{\bm F} \|_{\mathrm{F}}$. We denote $\bar{\bm \alpha} = \bm \alpha^* + \Delta \bm \alpha$, and $\bar{\bm{F}} = \bm F^* + \Delta \bm F$. Only considering $\bm \alpha$, we use an equivalent form of Eq.~\eqref{mainls}, that is \begin{equation}\label{mainlsapp} \begin{split} &\max\limits_{\bm \alpha}\!\min \limits_{\bm{F}\in \mathcal{S}^n_+} \bm{1}^{\!\top}\!{\bm \alpha}\! -\!\frac{1}{2} {\bm \alpha}^{\!\!\top}\bm{Y}\big(\bm{F}\odot\bm{K}\big)\bm{Y} {\bm \alpha} \\ &\mbox{s.t.} ~~\bm{0}\leq {\bm \alpha} \leq C\bm{1},~ \| \bm{F} - \bm{1} \bm{1}^{\top} \|_{\text{F}}^2 \leq R^2\,, \end{split} \end{equation} which is demonstrated by Eq.~\eqref{main}. The optimality condition of $\bm \alpha$ in Eq.~\eqref{mainlsapp} is \begin{align}\label{optf} \Big( \nabla_{\bm \alpha} H(\bm \alpha^*, \bm F^*) \Big)_i \left\{ \begin{array}{rcl} \begin{split} & = 0 \quad \mbox{if $0 < \bm \alpha_i^* <C$}, \\ & \leq 0 \quad \mbox{if $\bm \alpha_i^* = 0$}, \\ & \geq 0 \quad \mbox{if $\bm \alpha_i^* = C$}, \end{split} \end{array} \right. \end{align} where $\nabla_{\bm \alpha} H(\bm \alpha^*, \bm F^*) = \bm 1 - \bm Y(\bm F^* \odot \bm K )\bm Y \bm \alpha^*$. Since $\bar{\bm \alpha}$ is a feasible solution satisfying $0 \leq \bar{\bm \alpha}_i \leq C$, we have $(\Delta \bm \alpha)_i \geq 0$ if $\bm \alpha_i^* = 0$ and $(\Delta \bm \alpha)_i \leq 0$ if $\bm \alpha_i^* = C$. Accordingly, the following inequality holds \begin{equation}\label{optimala} (\Delta \bm \alpha)^{\!\top}\!(\bm 1 - \bm Y\!(\bm F^* \odot \bm K )\!\bm Y \bm \alpha^*) \!=\! \sum_{i=1}^{n}\! (\Delta \bm \alpha)_i \big(\nabla_{\bm \alpha} H(\bm \alpha^*\!,\! \bm F^*)\big)_i \! \leq \! 0. \end{equation} Next, according to Eq.~\eqref{optimala}, $H(\bar{\bm \alpha}, \bar{\bm F})$ in Eq.~\eqref{mainlsapp} can be decomposed into \begin{equation*} \begin{split} & H(\bar{\bm \alpha}, \bar{\bm F}) = H({\bm \alpha}^*, \bm F^*) - \frac{1}{2} (\Delta \bm \alpha)^{\top} \bm Y (\bar{\bm F} \odot \bm K) \bm Y (\Delta \bm \alpha)\\ & ~~~~+ \bm 1^{\top} (\Delta \bm \alpha) - \bm \alpha^* \bm Y(\bm F^* \odot \bm K )\bm Y (\Delta \bm \alpha)\\ &~~~~- \frac{1}{2} (\bm \alpha^*)^{\!\!\top} \!\bm Y\! (\Delta \bm F \odot \bm K) \bm Y \bm \alpha^* \!-\! (\bm \alpha^*)^{\top} \!\bm Y\! (\Delta \bm F \!\odot \!\bm K) \bm Y \Delta \bm \alpha \\ & \leq H({\bm \alpha}^*, \bm F^*) -\frac{1}{2} (\Delta \bm \alpha)^{\top} \bm Y (\bar{\bm F} \odot \bm K) \bm Y (\Delta \bm \alpha)\\ & ~~~~- (\bm \alpha^*)^{\top} \bm Y (\Delta \bm F \odot \bm K) \bm Y \Delta \bm \alpha\,. \end{split} \end{equation*} Further, the above inequality indicates that \begin{equation*} \begin{split} \frac{1}{2} (\Delta \bm \alpha)^{\top} \bm Y (\bm F^* \odot \bm K) \bm Y (\Delta \bm \alpha) & \leq H({\bm \alpha}^*, \bm F^*) - H(\bar{\bm \alpha}, \bar{\bm F}) - \frac{1}{2} (\Delta \bm \alpha)^{\top} \bm Y (\bar{\bm F} \odot \bm K) \bm Y (\Delta \bm \alpha)\\ & \leq \frac{1}{2} B_2 C^2 Q(\pi) + BC^2 \| \bm K \|_{\F} \,, \end{split} \end{equation*} which concludes the bound \begin{equation}\label{alaphboun} \| \bm \alpha^* - \bar{\bm \alpha} \|^2_2 \leq \frac{B_2C^2Q(\pi)}{B_1 \| \bm K \|_{\F}} + \frac{2BC^2}{B_1}\,. \end{equation} Next our target is to bound $\| \bm F^* - \bar{\bm F} \|_{\F}$. Defining \begin{equation*} \begin{split} {\bm F^*}(\bm \alpha^*) &\!=\! \mathcal{J}_{\frac{\tau}{2}}\Big(\bm 1 \bm{1}^{\!\!\top}+\underbrace{\frac{1}{4\eta}\diag({(\bm \alpha^*)}^{\!\!\top}\bm{Y})\bm{K}\diag({(\bm \alpha^*)}^{\!\!\top}\bm{Y})}_{\triangleq {\bm \Gamma^*}(\bm \alpha^*)} \Big)\,, \\ \bar{\bm F}(\bar{\bm \alpha}) &\!=\! \mathcal{J}_{\frac{\tau}{2}}\Big(\bm 1 \bm{1}^{\!\top}+\underbrace{\frac{1}{4\eta}\diag({\bar{\bm \alpha}}^{\top}\bm{Y})\bar{\bm{K}}\diag({\bar{\bm \alpha}}^{\top}\bm{Y})}_{\triangleq \bar{\bm \Gamma}(\bar{\bm \alpha}) } \Big)\,, \\ \end{split} \end{equation*} we have \begin{equation}\label{initGamma} \begin{split} \big\| \bm F^*(\bm \alpha^*) - \bar{\bm F}(\bar{\bm \alpha})\big\|_{\F} \leq \big\| {\bm \Gamma^*}(\bm \alpha^*) - \bar{\bm \Gamma}(\bar{\bm \alpha}) \big\|_{{\F}} \leq \big\| {\bm \Gamma^*}(\bm \alpha^*) - {\bm \Gamma^*}(\bar{\bm \alpha}) \big\|_{{\F}} + \big\| {\bm \Gamma^*}(\bar{\bm \alpha}) - \bar{\bm \Gamma}(\bar{\bm \alpha}) \big\|_{{\F}}\,, \end{split} \end{equation} with ${\bm \Gamma^*}(\bar{\bm \alpha}) = \frac{1}{4\eta}\diag({\bar{\bm \alpha}}^{\top}\bm{Y}){\bm{K}}\diag({\bar{\bm \alpha}}^{\top}\bm{Y})$. The first term in Eq.~\eqref{initGamma} can be bounded by Lemma~\ref{gammabound}. Combining it with the derived bound regarding to $ \| \bm \alpha^* - \bar{\bm \alpha} \|_2$ in Eq.~\eqref{alaphboun}, we have \begin{equation}\label{firstgamma} \begin{split} \big\| {\bm \Gamma^*}(\bm \alpha^*) - {\bm \Gamma^*}(\bar{\bm \alpha}) \big\|_{{\F}} \leq \frac{\|\bm{K}\|_{\F}}{4\eta} \big\| {\bm \alpha^*} + \bar{\bm \alpha} \big\|_2 \big\| {\bm \alpha^*} - \bar{\bm \alpha} \big\|_2 \leq \frac{\| \bm K \|_{\F}}{2 \eta} \sqrt{\frac{nB_2Q(\pi)}{B_1 \| \bm K \|_{\F}} + \frac{2nB}{B_1}}C^2\,. \end{split} \end{equation} Next we bound the second term in Eq.~\eqref{initGamma} as \begin{eqnarray} \nonumber \big\| {\bm \Gamma^*}(\bar{\bm \alpha}) - \bar{\bm \Gamma}(\bar{\bm \alpha}) \big\|_{{\F}} \!\!\!\!&\!=\!&\!\!\!\! \frac{1}{4\eta}\diag({\bar{\bm \alpha}}^{\!\top}\bm{Y})(\bm K\!-\! \bar{\bm{K}})\diag({\bar{\bm \alpha}}^{\!\top}\bm{Y}) \\ \nonumber \!\!\!\!&\!\leq\!&\!\!\!\! \frac{1}{4\eta} \sum_{i,j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \bar{\alpha}_i \bar{\alpha}_i y_i y_j \bm K_{ij} \\ \!\!\!\!&\!\leq\!&\!\!\!\! \frac{1}{4\eta} C^2Q(\pi) \label{secondgamma} \,. \end{eqnarray} Combining Eqs.~\eqref{initGamma}, \eqref{firstgamma}, and \eqref{secondgamma}, we conclude the proof. \end{proof} \subsection{Proofs of Theorem~\ref{theorsv}} \label{prooftheorsv} \begin{proof} We decompose $\nabla_{\bm \alpha} {H}({\bm \alpha}^*, \bm F^*)$ into \begin{equation*} \begin{split} \Big(\! \nabla_{\bm \alpha} {H}({\bm \alpha}^*, \bm F^*) \!\Big)_i &= \Big(\! \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \! \Big)_{\!i} - \Big(\!\bm Y(\bm F^* \odot {\bm K} )\bm Y {\Delta \bm \alpha} \!\Big)_i -\Big(\bm Y(\Delta \bm F \odot {\bm K} )\bm Y {\bm \alpha^*} \Big)_i \\ & ~~~~+ \sum_{j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \bar{\alpha}_j y_i y_j F^*_{ij} K_{ij} + \sum_{j:\pi(\bm x_i) \neq \pi(\bm x_j) }^{n} \alpha^*_j y_i y_j (\Delta \bm F)_{ij} K_{ij}\\ & \leq \Big( \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \Big)_i +B_2 \kappa C \!+\!(B_2\!-\!B_1) \kappa C + B_2 C \| \bar{\bm K}_i \|_1 \!+\! (B_2\!-\!B_1)C \| \bar{\bm K}_i \|_1 \\ & \leq \Big( \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \Big)_i \!+\! (B\!+\!B_2)C \| \bar{\bm K}_i \|_1 + (B\!+\!B_2) \kappa C \! \\ & \leq \Big( \nabla_{\bm \alpha} \bar{H}(\bar{\bm \alpha}, \bar{\bm F}) \Big)_i + (B + B_2)C (\| \bm K \|_1 + \kappa) \,, \end{split} \end{equation*} where $\bm K_i$ denotes the $i$-th column of the kernel matrix $\bm K$. We require $\big( \nabla_{\bm \alpha} {H}({\bm \alpha}^*, \bm F^*) \big)_i \leq 0$ when $\bar{\bm \alpha}_i =0$. To this end, we need the right-hand of the above inequality is smaller than zero. As a result, we can conclude that ${\bm \alpha}_i =0$ from the optimality condition of problem~\eqref{mainls} in Eq.~\eqref{optf}. \end{proof} \newpage \vskip 0.2in
\section{Introduction} \vspace{5pt} \noindent Kaluza--Klein theory attempts to unify General Relativity and electromagnetism into higher-dimensional pure gravity. Yet, the (aesthetically unpleasing) cylindrical extra dimension brings along an unwanted additional massless scalar field, \textit{i.e.~}radion or graviscalar modulus, which is not observed in nature: it would spoil the Equivalence Principle by appearing on the right-hand side of the geodesic equation. This moduli stabilization problem is essentially rooted in the fact that there is no natural scale in pure gravity which would fix or stabilize the radius of the cylinder. The problem persists in modern string compactifications, in view of the arbitrary size and shape of an internal space (mani/coni/orbifold, compact or not). Turning on fluxes or non-perturbative corrections might promise to solve the problem, but such scenarios require generically subtle analyses regarding both the validity of the effective-field-theory approximation and calculational control~\cite{Kachru:2003aw} (\textit{c.f.~}\cite{Obied:2018sgi} and references therein for related current controversies). In this paper we propose a novel Kaluza--Klein scheme to unify Stringy Gravity and Yang--Mills (including Maxwell), which postulates a non-Riemannian internal space and consequently does not suffer from any moduli problem. By Stringy Gravity, we mean the string theory effective action of the NS-NS (or purely bosonic) closed-string massless sector, conventionally represented by the three fields, $\{g_{\mu\nu},B_{\mu\nu},\phi\}$. They transform into one another under T-duality and hence form a (reducible) $\mathbf{O}(D,D)$ multiplet~\cite{Buscher:1987sk,Buscher:1987qj}. Furthermore, within the framework of Double Field Theory (DFT) initiated in \cite{Siegel:1993xq,Siegel:1993th,Hull:2009mi,Hull:2009zb,Hohm:2010jy}, $\mathbf{O}(D,D)$ T-duality becomes the manifest principal symmetry and the effective action itself is to be identified as an integral of a stringy scalar curvature beyond Riemann. The whole closed-string massless NS-NS sector may then be viewed as stringy graviton fields consisting of the DFT-dilaton, $d$, and the DFT-metric, $\cH_{AB}$~\cite{Angus:2018mep}. The latter satisfies two defining properties: \begin{equation} \begin{array}{ll} \cH_{AB}=\cH_{BA}\,,\quad&\quad \cH_{A}{}^{C}\cH_{B}{}^{D}\cJ_{CD}=\cJ_{AB}\,, \end{array} \label{defH} \end{equation} \vspace{-3pt}where $\cJ_{AB}={\resizebox{.125\hsize}{!}{${\tiny\mathbf{\Big(\begin{array}{cc} \bf{0}&\bf{1}\\\bf{1}&\bf{0}\end{array}\Big)}}$}}$ is the $\mathbf{O}(D,D)$ invariant constant metric which can freely raise and lower the $\mathbf{O}(D,D)$ vector indices, $A,B,\cdots$ (capital letters). A pair of symmetric projection matrices are then defined, \begin{equation} \begin{array}{ll} P_{AB}={{\textstyle\frac{1}{2}}}(\cJ_{AB}+\cH_{AB})\,,\quad& \bar{P}_{AB}={{\textstyle\frac{1}{2}}}(\cJ_{AB}-\cH_{AB})\,, \end{array} \end{equation} while their `square roots' give twofold DFT-vielbeins, \begin{equation} \begin{array}{ll} P_{AB}=V_{A}{}^{p}V_{B}{}^{q}\eta_{pq}\,,\quad&\quad \bar{P}_{AB}=\bar{V}_{A}{}^{{\bar{p}}}\bar{V}_{B}{}^{{\bar{q}}}\bar{\eta}_{{\bar{p}}{\bar{q}}}\,, \end{array} \end{equation} which satisfy their own defining properties, \begin{equation} \begin{array}{lll} V_{Ap}V^{A}{}_{q}=\eta_{pq}\,,\quad&~~ \bar{V}_{A{\bar{p}}}\bar{V}^{A}{}_{{\bar{q}}}=\bar{\eta}_{{\bar{p}}{\bar{q}}}\,,\quad&~~ V_{Ap}\bar{V}^{A}{}_{{\bar{q}}}=0\,, \end{array} \label{defV1} \end{equation} or equivalently~\cite{LR} \begin{equation} V_{A}{}^{p}V_{B}{}^{q}\eta_{pq}+\bar{V}_{A}{}^{{\bar{p}}}\bar{V}_{B}{}^{{\bar{q}}}\bar{\eta}_{{\bar{p}}{\bar{q}}}=\cJ_{AB}\,. \label{defV2} \end{equation} Here $\eta_{pq}$ and $\bar{\eta}_{{\bar{p}}{\bar{q}}}$ are local Lorentz invariant metrics characterizing the twofold spin groups which have dimensions $\Tr(P)$ and $\Tr(\bar{P})$ separately. They are distinguished by unbarred and barred small letter indices. The above stringy graviton fields constitute the diffeomorphic DFT-Christoffel symbols~\cite{Jeon:2010rw,Jeon:2011cn,Morand:2017fnv}, {\small{\[ \begin{array}{ll} \!\Gamma_{CAB}=&\!\!{2\left(P\partial_{C}P\bar{P}\right)_{[AB]} +2\left({{\bar{P}}_{[A}{}^{D}{\bar{P}}_{B]}{}^{E}}-{P_{[A}{}^{D}P_{B]}{}^{E}}\right)\partial_{D}P_{EC}}\\ {}&\!-4\!\left(\textstyle{\frac{P_{C[A}P_{B]}{}^{D}}{P_{F}{}^{F}-1}}+\textstyle{\frac{\bar{P}_{C[A}\bar{P}_{B]}{}^{D}}{\bar{P}_{F}{}^{F}-1}}\right)\!\left(\partial_{D}d+(P\partial^{E}P\bar{P})_{[ED]}\right), \end{array} \label{Gammao} \]}}and, consequently with $\nabla_{A}:=\partial_{A}+\Gamma_{A}$, twofold local Lorentz spin connections~\cite{Jeon:2011vx,Jeon:2011sq,Jeon:2012hp}, \begin{equation} \begin{array}{l} \Phi_{Apq}=V^{B}{}_{p}\nabla_{A}V_{Bq}=V^{B}{}_{p}\!\left(\partial_{A}V_{Bq}+\Gamma_{AB}{}^{C}V_{Cq}\right),\\ {{\bar{\Phi}}}_{A{\bar{p}}{\bar{q}}}=\bar{V}^{B}{}_{{\bar{p}}}\nabla_{A}\bar{V}_{B{\bar{q}}}=\bar{V}^{B}{}_{{\bar{p}}}\!\left(\partial_{A}\bar{V}_{B{\bar{q}}}+\Gamma_{AB}{}^{C}\bar{V}_{C{\bar{q}}}\right). \end{array} \label{PhibrPhi} \end{equation} These connections form covariant curvatures, Ricci and scalar~\cite{Jeon:2011cn,Jeon:2012hp}, of which the latter can be constructed as \begin{equation} \begin{array}{l} \So=(P^{AC}P^{BD}-\bar{P}^{AC}\bar{P}^{BD})S_{ABCD}\,,\\ \cGo=\cF_{ABpq}V^{Ap}V^{Bq}+{{\textstyle\frac{1}{2}}}\Phi_{Apq}\Phi^{Apq}\,,\\ \brcGo=\bar{\cF}_{AB{\bar{p}}{\bar{q}}}\bar{V}^{A{\bar{p}}}\bar{V}^{B{\bar{q}}}+{{\textstyle\frac{1}{2}}}{{\bar{\Phi}}}_{A{\bar{p}}{\bar{q}}}{{\bar{\Phi}}}^{A{\bar{p}}{\bar{q}}}\,, \end{array} \end{equation} where, with {\resizebox{.8\hsize}{!}{\,${R_{CDAB}=\partial_{A}\Gamma_{BCD}+\Gamma_{AC}{}^{E}\Gamma_{BED}-(A\leftrightarrow B)}$}}, \[ \begin{array}{l} \!S_{ABCD}:={{\textstyle\frac{1}{2}}}\left(R_{ABCD}+R_{CDAB}-\Gamma^{E}{}_{AB}\Gamma_{ECD}\right)\,,\\ \!\cF_{ABpq}:=\nabla_{A}\Phi_{Bpq}-\nabla_{B}\Phi_{Apq}+\Phi_{Ap}{}^{r}\Phi_{Brq}-\Phi_{Bp}{}^{r}\Phi_{Arq}\,,\\ \!\bar{\cF}_{AB{\bar{p}}{\bar{q}}}:=\nabla_{A}{{\bar{\Phi}}}_{B{\bar{p}}{\bar{q}}}-\nabla_{B}{{\bar{\Phi}}}_{A{\bar{p}}{\bar{q}}}+{{\bar{\Phi}}}_{A{\bar{p}}}{}^{{\bar{r}}}{{\bar{\Phi}}}_{B{\bar{r}}{\bar{q}}}-{{\bar{\Phi}}}_{B{\bar{p}}}{}^{{\bar{r}}}{{\bar{\Phi}}}_{A{\bar{r}}{\bar{q}}}\,. \end{array} \] While $\So$ coincides exactly with the well-known expression of scalar curvature written in terms of $d, \cH_{AB}$~\cite{Hohm:2010pp}, \[ \begin{array}{l} \!\!\So=\textstyle{\frac{1}{8}}\cH^{AB}\partial_{A}\cH_{CD}\partial_{B}\cH^{CD}+{{\textstyle\frac{1}{2}}}\cH^{AB} \partial^{C}\cH_{AD}\partial^{D}\cH_{BC}\\ \!-\partial_{A}\partial_{B}\cH^{AB} +4\cH^{AB}(\partial_{A}\partial_{B}d-\partial_{A}d\partial_{B}d)+4\partial_{A}\cH^{AB}\partial_{B}d\,, \end{array} \] the other two accommodate the vielbeins and read~\cite{Cho:2015lha} \begin{equation} \begin{array}{rl} +\cGo&\!\!={{\textstyle\frac{1}{2}}}\So+2\partial_{A}\partial^{A}d-2\partial_{A}d\partial^{A}d+{{\textstyle\frac{1}{2}}}\partial_{A}V_{Bp}\partial^{A}V^{Bp}\,,\\\ -\brcGo&\!\!={{\textstyle\frac{1}{2}}}\So-2\partial_{A}\partial^{A}d+2\partial_{A}d\partial^{A}d-{{\textstyle\frac{1}{2}}}\partial_{A}\bar{V}_{B{\bar{p}}}\partial^{A}\bar{V}^{B{\bar{p}}}\,. \end{array} \label{cGobrcGo} \end{equation} Clearly their differences would vanish upon the section condition, $\partial_{A}\partial^{A}\equiv0$, but they provide precisely the known `missing' pieces in the Scherk--Schwarz reduction of DFT while relaxing the section condition on the internal space, as previously added by hand in \cite{Geissbuhler:2011mx,Aldazabal:2011nj,Grana:2012rr,Dibitetto:2012rk}. Hence, the above vielbein formalism generates these crucial terms in a natural manner. In particular, $\cGo\!-\brcGo$ matches the action adopted in \cite{Grana:2012rr}. Below we focus on computing $+\cGo$ and $-\brcGo$ separately in higher dimensions with the Scherk--Schwarz twisted non-Riemannian Kaluza--Klein ansatz. \\ \section{\mbox{\!\!\!\!\!Moduli-free non-Riemannian Kaluza--Klein ansatz}} \vspace{5pt} \noindent With ${\hD={D^{\prime}{}}+D}$, the DFT Kaluza--Klein ansatz~\cite{Morand:2017fnv} breaks $\mathbf{O}(\hD,\hD)$ into $\mathbf{O}(\Dpr,\Dpr)\times\mathbf{O}(D,D)$ and takes the form: \begin{equation} \begin{array}{ll} \hcH={\resizebox{.5\hsize}{!}{$\exp\!\left[\hW\right]\left(\begin{array}{cc}\cHpr&0\\0&\cH\end{array}\right)\exp\!\left[\hW^{T}\right]$}}\,, \quad&~~\hcJ={\resizebox{.17\hsize}{!}{$\left(\begin{array}{cc}\cJpr&0\\0&\cJ\end{array}\right)$}}\,. \end{array} \label{ansatz} \end{equation} In our notation, hatted, primed, and unprimed symbols refer to the ambient, internal, and external spaces respectively. In particular, the ambient doubled coordinates split into the internal and external ones as \begin{equation} \begin{array}{ll} z^{\hA}=(y^{A^{\prime}},x^{A})\,,\quad&\quad \partial_{\hA}=(\partial_{A^{\prime}},\partial_{A})\,. \end{array} \label{split} \end{equation} In (\ref{ansatz}), $\hW$ is an off-block-diagonal $\mathfrak{so}(\hD,\hD)$ element which satisfies \begin{equation} \hW\hcJ+\hcJ\hW^{T}=0\,, \end{equation} and takes the form, \begin{equation} \!\hW\!=\!{\resizebox{.95\hsize}{!}{$ \left(\!\begin{array}{cc}0&-W^{{\mathbf{c}}}\\W&\!0\end{array}\!\right)\!,~ W^{{\mathbf{c}}}_{~{A^{\prime}{}}}{}^{\!A\!}:=W^{A}{}_{\!{A^{\prime}{}}}= \cJ^{AB}\cJpr_{{A^{\prime}{}}{B^{\prime}{}}}W_{B}{}^{{B^{\prime}{}}},$}} \end{equation} where the $2D\times 2{D^{\prime}{}}$ block, $W_{A}{}^{{A^{\prime}{}}}$, should meet~\cite{Choi:2015bga} \begin{equation} \begin{array}{ll} W_{A}{}^{{A^{\prime}{}}}W^{A{B^{\prime}{}}}=0\,,\qquad&\quad W^{A}{}_{{A^{\prime}{}}}\partial_{A}=0\,. \end{array} \label{Wconstraint} \end{equation} This condition sets half of the components to be trivial, truncates the exponential, \[ \exp\!\left[\hW\right]=1+\hW+{{\textstyle\frac{1}{2}}}\hW^{2}\,, \] and makes the above ansatz consistent with the ordinary Kaluza--Klein ansatz in supergravity. Moreover, crucially for the purpose of the present work, the ansatz~(\ref{ansatz}) can accommodate non-Riemannian geometry in which the Riemannian metric cannot be defined, see \cite{Morand:2017fnv} for classification and \cite{Lee:2013hma,Ko:2015rha,Park:2016sbw} for earlier examples including the attainment of the Gomis-Ooguri non-relativistic string~\cite{Gomis:2000bd,GO}. Henceforth, we focus on a specific internal space of which the DFT-metric is fully $\mathbf{O}(\Dpr,\Dpr)$ symmetric and maximally non-Riemannian, namely $({D^{\prime}{}},0)$ type as classified in \cite{Morand:2017fnv}: \begin{equation} \cHpr_{{A^{\prime}{}}{B^{\prime}{}}}\equiv\cJpr_{{A^{\prime}{}}{B^{\prime}{}}}\,. \label{internal} \end{equation} In general, from the defining relations~(\ref{defH}), the infinitesimal variation of any DFT-metric should satisfy \begin{equation} \delta \cHpr=P^{\prime}\delta\cHpr\bar{P}^{\prime}+\bar{P}^{\prime}\delta\cHpr P^{\prime}\,. \end{equation} Meanwhile, the particular choice of the internal space~(\ref{internal}) implies ${P^{\prime}=\cJpr}$ and ${\bar{P}^{\prime}=0}$. Thus, the fluctuation must be trivial: no graviscalar modulus can be generated and the non-Riemannian internal space is \textit{rigid}, \begin{equation} \delta \cHpr_{{A^{\prime}{}}\!{B^{\prime}{}}}=0\,. \label{rigid} \end{equation} In fact, (\ref{internal}) sets the ``twofold" internal spin group to be $\mathbf{O}(\Dpr,\Dpr)\times\mathbf{O}(0,0)$, such that the coset structures of the internal and the ambient DFT-metrics, $\cHpr$, $\hcH$, are `trivial' and `heterotic' respectively, if $\cH$ is Riemannian~(\ref{Riemann}), \begin{equation} {\resizebox{.95\hsize}{!}{$ \frac{\mathbf{O}(\Dpr,\Dpr)}{\mathbf{O}(\Dpr,\Dpr)\times\mathbf{O}(0,0)}=\mathbf{1}\,,\quad \frac{\mathbf{O}(\hD,\hD)}{\mathbf{O}({D^{\prime}{}}+1,\hD-1)\times\mathbf{O}(D-1,1)}\,.$}} \label{coset} \end{equation} The latter has dimension ${D^{2}+2D{D^{\prime}{}}}$, which matches the total degrees of the external DFT-metric, $\cH_{AB}$ (\ref{Riemann}), and the gravivector, $W_{A}{}^{{A^{\prime}{}}}$~(\ref{Wconstraint})~\cite{Quetient}, \textit{c.f.~}\cite{Maharana:1992my}. The corresponding DFT-vielbeins are~\cite{Morand:2017fnv} \begin{equation} \begin{array}{ll} \hV_{\hA\hp}\!=\!\exp\!\left[\hW\right]\!\left(\begin{array}{cc} V^{\prime}_{A^{\prime}p^{\prime}}&0\\ 0&V_{Ap}\end{array}\right),& \hat{\bar{V}}_{\hA\hat{{\bar{p}}}}\!=\!\exp\!\left[\hW\right]\left(\begin{array}{c} 0\\ \bar{V}_{A{\bar{p}}}\end{array}\right), \end{array} \label{ansatzV} \end{equation} where $V^{\prime}_{A^{\prime}p^{\prime}}$ is now an invertible `square' matrix, \[ V^{\prime}_{A^{\prime}p^{\prime}}V^{\prime}_{B^{\prime}}{}^{p^{\prime}}=\cJ^{\prime}_{A^{\prime}B^{\prime}}\,. \] \section{Reduction to heterotic DFT} \vspace{5pt} \noindent Before inserting the ansatz~(\ref{ansatz}), (\ref{ansatzV}) into the ambient scalar curvatures~(\ref{cGobrcGo}), or $\hcGo,\hbrcGo$ (all hatted), we perform a Scherk--Schwarz twist over the internal space. Following \cite{Cho:2015lha}, we introduce a twisting matrix, {\resizebox{.12\hsize}{!}{${U_{\dot{A}}{}^{A^{\prime}}(y)}$}}, which depends on the internal coordinates only and is an $\mathbf{O}(\Dpr,\Dpr)$ element satisfying \begin{equation} U_{\dot{A}}{}^{A^{\prime}}U_{\dot{B}}{}^{B^{\prime}}\cJpr_{A^{\prime}B^{\prime}}=\dot{\cJ}_{\dot{A}\dot{B}}\,, \end{equation} where $\dot{\cJ}_{\dot{A}\dot{B}}$ coincides with $\cJpr_{A^{\prime}B^{\prime}}$ numerically: both are $\mathbf{O}(\Dpr,\Dpr)$ invariant constant metrics. Essentially the twist converts all the primed indices to dotted ones, \begin{equation} \begin{array}{ll} \! \!\!W_{A}{}^{{A^{\prime}{}}\!}(z)=W_{A}{}^{\dot{A}}(x)U_{\dot{A}}{}^{A^{\prime}\!}(y)\,,&\! V^{\prime A^{\prime}}{}_{\! p^{\prime}}(z)=\dot{V}{}^{\dot{A}}{}_{p^{\prime}}(x)U_{\dot{A}}{}^{A^{\prime}\!}(y)\,, \end{array} \label{twist1} \end{equation} where now $\dot{V}_{\dot{A} p^{\prime}}\dot{V}_{\dot{B}}{}^{p^{\prime}}=\dot{\cJ}_{\dot{A}\dot{B}}$. We further put \begin{equation} \begin{array}{lll} \hat{d}(z)=\lambda(y)+d(x)\,,\quad&\quad V_{Ap}(x)\,,\quad&\quad \bar{V}_{A{\bar{p}}}(x)\,, \end{array} \label{trunc} \end{equation} such that the external fields are independent of the internal coordinates: $\partial_{A^{\prime}}d=0$\,, $\partial_{A^{\prime}}V_{Bp}=0$\,, $\partial_{A^{\prime}}\bar{V}_{B{\bar{p}}}=0$\,. Finally, we impose the standard section condition on the external space, $\partial_{A}\partial^{A}=0$, and the twistability conditions on the internal space separately~\cite{Grana:2012rr},\cite{Cho:2015lha}: \begin{equation} \begin{array}{ll} \partial_{{A^{\prime}{}}}\lambda-{{\textstyle\frac{1}{2}}} U^{\dot{A}}{}_{{A^{\prime}{}}}\partial_{{B^{\prime}{}}}U_{\dot{A}}{}^{{B^{\prime}{}}}=0\,,\quad&\quad f_{[\dot{A}\dot{B}}{}^{\dot{E}}f_{\dot{C}]\dot{D}\dot{E}}=0\,, \end{array} \label{twist2} \end{equation} where $f_{\dot{A}\dot{B}\dot{C}}=3\big(\partial_{{B^{\prime}{}}}U_{[\dot{A}}{}^{{A^{\prime}{}}}\big)U_{\dot{B}}{}^{{B^{\prime}{}}}U_{\dot{C}]{A^{\prime}{}}}$ which we require to be constant. After straightforward yet tedious computation -- assisted by a computer algebra system~\cite{Peeters:2007wn} and through intermediate expressions like (4.14) in \cite{Cho:2015lha} -- we obtain our main result: with the above Scherk--Schwarz twisted Kaluza--Klein ansatz substituted, the higher-dimensional scalar curvatures~(\ref{cGobrcGo}) reduce precisely to (\textit{c.f.}~\cite{Jeon:2011kp,Hohm:2011ex,Grana:2012rr,Berman:2013cli,Hohm:2014sxa,Malek:2016vsh,Aldazabal:2017jhp}) \begin{equation} \begin{array}{lll} \!\!+2\hcGo&\!=\!&-2\hbrcGo+\textstyle{\frac{1}{3}}f_{\dot{A}\dot{B}\dot{C}}f^{\dot{A}\dot{B}\dot{C}}\,,\\ \!\!-2\hbrcGo&\!=\!&\So-\textstyle{\frac{1}{4}}\cH^{AC}\cH^{BD} F_{AB}{}^{\dot{A}}F_{CD\dot{A}}\\ {}&{}&-\textstyle{\frac{1}{12}}\cH^{AD}\cH^{BE}\cH^{CF}\omega_{ABC} \omega_{DEF}\\ {}&{}&+\textstyle{\frac{1}{2}}\cH^{AD}\cH^{BE}\cH^{CF}\omega_{ABC}\cH_{[D}{}^{G}\partial_{E}\cH_{F]G}\,, \end{array} \label{MAIN} \end{equation} where we set Yang--Mills and Chern--Simons terms, \begin{equation} \begin{array}{l} F_{AB}{}^{\dot{C}}=\partial_{A}W_{B}{}^{\dot{C}}-\partial_{B}W_{A}{}^{\dot{C}}+f_{\dot{A}\dot{B}}{}^{\dot{C}}W_{A}{}^{\dot{A}}W_{B}{}^{\dot{B}}\,,\\ \omega_{ABC}=3W_{[A}{}^{\dot{A}}\partial_{B}W_{C]\dot{A}}+f_{\dot{A}\dot{B}\dot{C}}W_{A}{}^{\dot{A}}W_{B}{}^{\dot{B}}W_{C}{}^{\dot{C}}\,, \end{array} \label{Fomega} \end{equation} of which the $\mathbf{O}(D,D)$ indices are totally skew-symmetric, $F_{AB}{}^{\dot{C}}=F_{[AB]}{}^{\dot{C}}$, $ \omega_{ABC}=\omega_{[ABC]}$, and further from (\ref{Wconstraint}), \begin{equation} \begin{array}{ll} F^{AB}{}_{\dot{C}}\partial_{A}=0\,,\quad&\quad\omega^{ABC}\partial_{A}=0\,. \end{array} \end{equation} The higher $\hD$-dimensional diffeomorphisms generated by the standard DFT Lie derivative give rise, with a twisted parameter, $\hat{\xi}{}^{\hA}=(\Lambda^{\dot{A}}U_{\dot{A}}{}^{{A^{\prime}{}}},\xi^{A})$, to the $D$-dimensional diffeomorphisms plus Yang--Mills gauge symmetry, \textit{c.f.}~\cite{Grana:2012rr,Cho:2015lha}, \begin{equation} \begin{array}{rll} \delta W_{A}{}^{\dot{A}}&=&\xi^{C}\partial_{C}W_{A}{}^{\dot{A}} +\left(\partial_{A}\xi^{B}-\partial^{B}\xi_{A}\right)W_{B}{}^{\dot{A}}\\ {}&{}&+\partial_{A}\Lambda^{\dot{A}}+f^{\dot{A}}{}_{\dot{B}\dot{C}}W_{A}{}^{\dot{B}}\Lambda^{\dot{C}}\,,\\ \delta\cH_{AB}&=&\xi^{C}\partial_{C}\cH_{AB}+2\partial_{[A}\xi_{C]}\cH^{C}{}_{B}+ 2\partial_{[B}\xi_{C]}\cH_{A}{}^{C}\\ {}&{}&+\big(W_{[A}{}^{\dot{A}}\partial_{C]}\Lambda_{\dot{A}}\big)\cH^{C}{}_{B}+\big( W_{[B}{}^{\dot{A}}\partial_{C]}\Lambda_{\dot{A}}\big)\cH_{A}{}^{C}\,,\\ \delta d&=&\xi^{C}\partial_{C}d-{{\textstyle\frac{1}{2}}}\partial_{C}\xi^{C}\,. \end{array} \label{SYMMETRY} \end{equation} In each transformation above, the first line with $\xi^{A}$ is the (external) diffeomorphic DFT Lie derivative and the second with $\Lambda^{\dot{A}}$ is the (internal) Yang--Mills gauge symmetry. In fact, every single term in (\ref{MAIN}) is (external) diffeomorphism-invariant~\cite{footnoteYM}. It is worth while to note the only difference between $2\hcGo$ and $-2\hbrcGo$: the former contains a DFT-cosmological constant term~\cite{Jeon:2011cn}, $\textstyle{\frac{1}{3}}e^{-2d}f_{\dot{A}\dot{B}\dot{C}}f^{\dot{A}\dot{B}\dot{C}}$, but the latter does not. As anticipated in \cite{Hassan:1991mq,Hohm:2014sxa}, our result~(\ref{MAIN}) is manifestly symmetric for $\mathbf{O}(D,D)$ as well as any subgroup of $\mathbf{O}(\Dpr,\Dpr)$ which stabilizes the structure constant, $f_{\dot{A}\dot{B}\dot{C}}$. Finally, if we adopt the well-known Riemannian parametrization of the DFT-metric, \begin{equation} \begin{array}{ll} \cH_{AB}=\left(\begin{array}{cc}g^{-1}&-g^{-1}B\\ Bg^{-1}&g-Bg^{-1}B\end{array}\right),\quad&\quad e^{-2d}=\sqrt{-g}e^{-2\phi}\,, \end{array} \label{Riemann} \end{equation} and solve both the external section condition, $\partial_{A}\partial^{A}=0$, and (\ref{Wconstraint}), by letting $\partial_{A}=(\tilde{\partial}^{\mu},\partial_{\nu})\equiv(0,\partial_{\nu})$ and $W_{A}{}^{\dot{A}}\equiv(0,W_{\nu}{}^{\dot{A}})$, our main result~(\ref{MAIN}) reproduces the heterotic supergravity action~\cite{Bergshoeff:1981um,Chapline:1982ww}, up to total derivatives, \begin{equation} \begin{array}{l} \displaystyle{ \int -2e^{-2d}\brcGo}\\ \displaystyle{\!\! =\!\!\int\!\!\!\sqrt{-g}e^{-2\phi}\big(R+\!4\partial_{\mu}\phi\partial^{\mu}\phi-\!\textstyle{\frac{1}{12}}\tilde{H}_{\lambda\mu\nu}\tilde{H}^{\lambda\mu\nu\!}-\!{{\textstyle\frac{1}{4}}} F_{\mu\nu\dot{C}}F^{\mu\nu\dot{C}} \big)}, \end{array} \end{equation} where \begin{equation} \tilde{H}_{\lambda\mu\nu}=3\partial_{[\lambda}B_{\mu\nu]}-\omega_{\lambda\mu\nu}\,, \end{equation} which is invariant under the Yang--Mills gauge symmetry~(\ref{SYMMETRY}), or specifically in components, \[ \begin{array}{ll} \delta W_{\mu}{}^{\dot{A}}=\partial_{\mu}\Lambda^{\dot{A}}+f^{\dot{A}}{}_{\dot{B}\dot{C}}W_{\mu}{}^{\dot{B}}\Lambda^{\dot{C}}\,,\quad&\quad \delta B_{\mu\nu}=W_{[\mu}{}^{\dot{A}}\partial_{\nu]}\Lambda_{\dot{A}}\,. \end{array} \] However, we have not pinned down the gauge group to be either $\mathbf{E}_{8}\times \mathbf{E}_{8}$ or $\mathbf{SO}(32)$. Further, as the starting scalar curvatures~(\ref{cGobrcGo}) are at most two-derivative, our final result~(\ref{MAIN}) lacks the higher-derivative gravitational Chern--Simons term~\cite{Green:1984sg}, \textit{c.f.~}\cite{Bedoya:2014pma,Coimbra:2014qaa,Lee:2015kba}.\\ \section{Reduction to heterotic string} \vspace{5pt} \noindent Henceforth we discuss the worldsheet aspect of the DFT background~(\ref{ansatz}) involving the maximally non-Riemannian internal space. The analysis of the string propagating on the most general non-Riemannian background was carried out in \cite{Morand:2017fnv}, with the conclusion that string becomes generically (anti-)chiral. To review this and apply it to the current non-Riemannian background~(\ref{ansatz}), we recall the doubled-yet-gauged string action~\cite{Hull:2006va},\,\cite{Lee:2013hma} (\textit{c.f.~}\cite{Park:2016sbw,Arvanitakis:2017hwb,Arvanitakis:2018hfn}), \begin{equation} S_{\scriptstyle{\rm{string}}}={\textstyle{\frac{1}{4\pi\alpha^{\prime}}}}{\displaystyle{\int}}{\rm d}^{2}\sigma~\cL_{\scriptstyle{\rm{string}}}\,, \label{stringA} \end{equation} which contains a generic DFT-metric, \[ \cL_{\scriptstyle{\rm{string}}}=-{{\textstyle\frac{1}{2}}}\sqrt{-h}h^{\alpha\beta}{\rm D}_{\alpha}z^{\hA}{\rm D}_{\beta}z^{\hB}\hcH_{\hA\hB} -\epsilon^{\alpha\beta}{\rm D}_{\alpha}z^{\hA}\cA_{\beta\hA}\,. \label{stringaction} \] With ambient doubled coordinates, $z^{\hA}=(\tilde{z}_{\hat{\mu}},z^{\hat{\nu}})$, and an auxiliary gauge potential, $\cA_{\alpha}{}^{\hA}$, a covariant derivative is introduced, \begin{equation} \begin{array}{ll} {{\rm D}_{\alpha} z^{\hA}:=\partial_{\alpha}z^{\hA}-\cA_{\alpha}{}^{\hA}}\,,\qquad&\quad \cA_{\alpha}{}^{\hA}\partial_{\hA}=0\,. \end{array} \label{rmDz} \end{equation} While this action is completely covariant with respect to the desired symmetries like $\mathbf{O}(D,D)$ T-duality, Weyl symmetry, and worldsheet as well as target-spacetime diffeomorphisms, it also realizes concretely the assertion that doubled coordinates in DFT are actually gauged and each gauge orbit in the doubled coordinate system corresponds to a single physical point~\cite{Park:2013mpa}. Specifically, with the choice of the section, $\partial_{\hA}=(\tilde{\partial}^{\hat{\mu}},\partial_{\hat{\nu}})\equiv(0,\partial_{\hat{\nu}})$, the condition on the auxiliary gauge potential~(\ref{rmDz}) is solved by $\cA_{\alpha}{}^{\hA}=(\cA_{\alpha\hat{\mu}},0)$. Therefore, half of the doubled coordinates, namely the tilde coordinates, are gauged, \[ {{\rm D}_{\alpha} z^{\hA}=\big(\partial_{\alpha}\tilde{z}_{\hat{\mu}}-\cA_{\alpha\hat{\mu}}\,,\,\partial_{\alpha} z^{\hat{\nu}}\big)}\,. \] Upon the Riemannian background~(\ref{Riemann}), the auxiliary gauge potential appears quadratically in the action~(\ref{stringA}). Then after integrating it out, one recovers the standard undoubled string action with $g_{\mu\nu}$ and $B_{\mu\nu}$. On the other hand, upon a generic non-Riemannian DFT background which is characterized by two non-negative integers, $(n,{\bar{n}})$, the components of the auxiliary field, $\cA_{\alpha}{}^{\hA}$, appear linearly for $n$ and ${\bar{n}}$ directions, playing the role of Lagrange multipliers. Consequently, string becomes chiral and anti-chiral over the $n$ and ${\bar{n}}$ directions respectively~\cite{Morand:2017fnv}. Now, for the present non-Riemannian background~(\ref{ansatz}), in accordance with the decomposition of the ambient space~(\ref{split}), we put $y^{{A^{\prime}{}}}=(\tilde{y}_{\mu^{\prime}},y^{\nu^{\prime}})$ for the internal doubled coordinates, $x^{A}=(\tilde{x}_{\mu},x^{\nu})$ for the external ones, and $W_{\mu}{}^{{A^{\prime}{}}}=(W_{\mu\nu^{\prime}},\tilde{W}_{\mu}{}^{\nu^{\prime}})$ for the gravivector. Further, for the ambient gauge potential, $\cA_{\alpha}{}^{\hA}=(\cA_{\alpha}{}^{{A^{\prime}{}}}, \cA_{\alpha}{}^{A})$, we set the internal and the external ones as $\cA_{\alpha}{}^{{A^{\prime}{}}}=(A_{\alpha\mu^{\prime}},0)$ and $\cA_{\alpha}{}^{A}=(A_{\alpha\mu},0)$. With this preparation and (\ref{ansatz}), (\ref{Riemann}), the string action~(\ref{stringA}) becomes quadratic in the combination of the gauge potential components, $A_{\alpha\mu}-\tilde{W}_{\mu}{}^{\mu^{\prime}}A_{\alpha\mu^{\prime}}$, and linear in $A_{\alpha\mu^{\prime}}$. Hence, the former leads to a Gaussian integral and the latter plays the role of a Lagrange multiplier. After all, the doubled-yet-gauged string action~(\ref{stringA}) reduces to $\frac{1}{2\pi\alpha^{\prime}} \displaystyle{\int}{\rm d}^{2}\sigma~\cL_{\scriptstyle{\rm{Het}}}$, with \begin{equation} \begin{array}{lll} \!\cL_{\scriptstyle{\rm{Het}}}\!&\!\!=\!\!\!& -{{\textstyle\frac{1}{2}}}\sqrt{-h}h^{\alpha\beta}\partial_{\alpha}x^{\mu}\partial_{\beta}x^{\nu} g_{\mu\nu} +{{\textstyle\frac{1}{2}}}\epsilon^{\alpha\beta}\partial_{\alpha}x^{\mu} \partial_{\beta}x^{\nu}B_{\mu\nu}\\ {}&{}&+{{\textstyle\frac{1}{2}}}\epsilon^{\alpha\beta} (\partial_{\alpha}\tilde{y}_{\mu^{\prime}}+\partial_{\alpha}x^{\mu}W_{\mu\mu^{\prime}}) (\partial_{\beta}y^{\mu^{\prime}}+\partial_{\beta}x^{\lambda}\tilde{W}_{\lambda}{}^{\mu^{\prime}})\\ {}&{}&+{{\textstyle\frac{1}{2}}}\epsilon^{\alpha\beta} (\partial_{\alpha}\tilde{x}_{\mu}-W_{\mu{A^{\prime}{}}}\partial_{\alpha}y^{{A^{\prime}{}}})\partial_{\beta}x^{\mu}\,. \end{array} \label{LHet} \end{equation} Furthermore, $\partial_{\alpha}y^{\mu^{\prime}}+\partial_{\alpha}x^{\mu}\tilde{W}_{\mu}{}^{\mu^{\prime}}$ must be \textit{chiral}: \begin{equation} \left(h^{\alpha\beta}+\textstyle{\frac{1}{\sqrt{-h}}}\epsilon^{\alpha\beta}\right)\!\left(\partial_{\beta}y^{\mu^{\prime}}+\partial_{\beta}x^{\mu}\tilde{W}_{\mu}{}^{\mu^{\prime}}\right)=0\,. \label{chiral} \end{equation} Especially when the gravivector, $W_{\mu}{}^{\dot{A}}$, is trivial, the second and third lines in (\ref{LHet}) merge into a known topological term, ${{\textstyle\frac{1}{2}}}\epsilon^{\alpha\beta}\partial_{\alpha}\tilde{z}_{\hat{\mu}} \partial_{\beta}z^{\hat{\mu}}$~\cite{Giveon:1991jj,Hull:2006va}, while (\ref{chiral}) gets simplified to make the internal coordinates chiral: \begin{equation} y^{\mu^{\prime}}(\tau,\sigma)=y^{\mu^{\prime}}(0,\tau+\sigma)\,. \end{equation} This implies -- at least classically~\cite{Morand:2017fnv,Ko:2015rha} -- that a closed string subject to a periodic boundary condition cannot vibrate in the internal space. In summary, upon the DFT background~(\ref{ansatz}) with the maximally non-Riemannian internal space and trivial gravivector, the external fields, $x^{\mu}$, are described by the usual string action corresponding to the first line in (\ref{LHet}), and consist of the equal number of left-moving and right-moving sectors. On the other hand, the internal fields, $y^{\mu^{\prime}}$, become all chiral, which agrees with the rigidity~(\ref{rigid}).\\ \section{Conclusion} \vspace{5pt} \noindent The maximally non-Riemannian DFT background specified by the DFT-metric, $\cH^{\prime}_{{A^{\prime}{}}{B^{\prime}{}}}=\cJ^{\prime}_{{A^{\prime}{}}{B^{\prime}{}}}$~(\ref{internal}), is singled out to be completely $\mathbf{O}(\Dpr,\Dpr)$ symmetric and rigid: it does not admit any linear fluctuation, $\delta\cH^{\prime}_{{A^{\prime}{}}{B^{\prime}{}}}=0$~(\ref{rigid}), nor graviscalar moduli, and the coset structure is trivial~(\ref{coset}). It is the most symmetric vacuum in DFT. \\ \indent For the DFT Kaluza--Klein ansatz, (\ref{ansatz}) and (\ref{ansatzV}), we set the internal space to be maximally non-Riemannian, performed a Scherk--Schwarz twist~(\ref{twist1}),~(\ref{twist2}), and computed the ambient higher $(D^{\prime}+D)$-dimensional DFT scalar curvatures, $+\hcGo$ and $-\hbrcGo$~(\ref{cGobrcGo}), which lead to the $\mathbf{O}(D,D)$-manifest formulation of the non-Abelian heterotic supergravity~(\ref{MAIN}). Only the former, $+\hcGo$, contains a DFT-cosmological constant. In this way, \textit{supergravity and Yang-Mills theory can be unified into a higher-dimensional pure Stringy Gravity, free of moduli.} \\ \indent Plugging the \textit{same} non-Riemannian Kaluza--Klein ansatz~(\ref{ansatz}) into the doubled-yet-gauged string action~(\ref{stringA}) may reproduce the usual heterotic string action, \[{\resizebox{.97\hsize}{!}{\,${{{\textstyle\frac{1}{2}}}\int_{\Sigma}} \big({-\sqrt{-h}h^{\alpha\beta}} g_{\mu\nu}+\epsilon^{\alpha\beta}B_{\mu\nu}\big)\partial_{\alpha}x^{\mu} \partial_{\beta}x^{\nu}+\epsilon^{\alpha\beta}\partial_{\alpha}\tilde{z}_{\hat{\mu}} \partial_{\beta}z^{\hat{\mu}}\,,$}} \] with chiral internal coordinates, $\big(h^{\alpha\beta}+\frac{\epsilon^{\alpha\beta}}{\sqrt{-h}}\big)\partial_{\beta}y^{\mu^{\prime}}=0$. This is indeed the case when the Yang--Mills sector is trivial. Therefore, \textit{heterotic string theory may have a higher-dimensional origin with non-Riemannian internal space.} Our analyses have been focused on the bosonic sectors, both on the target-spacetime and on the world-sheet. Inclusion of fermions is highly desired, \textit{c.f.~}\cite{Jeon:2011sq,Jeon:2012hp,Park:2016sbw}. We also leave the exploration of the worldsheet aspect of the somewhat mysterious `relaxed' section condition designed for the Scherk--Schwarz twist~\cite{Geissbuhler:2011mx,Aldazabal:2011nj,Grana:2012rr,Dibitetto:2012rk,Cho:2015lha} for future work with nontrivial gravivector, $W_{A}{}^{{A^{\prime}{}}}\neq0$, for the action~(\ref{LHet}). Uplift of the Standard Model of particle physics coupled to DFT~\cite{Choi:2015bga} to higher dimensions (bottom-up) would be also of interest, as well as applications to string compactifications (top-down), possibly on other types of non-Riemannian internal spaces~\cite{33}.\\ \noindent\textit{Note added.} \\ Motivated by the \href{https://arxiv.org/abs/1808.10605}{first version of this work on arXiv}, Berman, Blair, and Otsuki explored non-Riemannian geometries in M-theory~\cite{Berman:2019izh}. In particular, they pointed out that the maximally non-Riemannian $E_{8}$ background naturally realizes the topological (hence `moduli-free') phase of Exceptional Field Theory~\cite{Hohm:2018ybo}. \\ \noindent\textit{Acknowledgments.}\\ {We wish to thank Stephen Angus, Kanghoon Lee for useful comments, and Wonyoung Cho for valuable help at the early stage of the project. This work was supported by the National Research Foundation of Korea through the Grants, NRF-2016R1D1A1B01015196 and NRF-2018H1D3A1A01030137~(Korea Research Fellowship Program).} \hfill
\section{Introduction} WebAssembly~\cite{Haas:2017:BWU:3062341.3062363, WasmWebsite} is a new, low-level binary instruction format for the web. Its core use case is as a compilation target for systems programming languages like C, C++, or Rust. By providing low-level control over the memory layout and by closely mapping to hardware instructions, WebAssembly provides near-native and predictable performance~\cite{herrera2018webassembly, Haas:2017:BWU:3062341.3062363}, unlike managed languages, such as JavaScript and Java. As of last year, WebAssembly support is enabled in all major browsers~\cite{WasmConsensus}, making it portable across different vendors, architectures, and devices, after prior attempts to establish low-level code on the web have failed, e.g., ActiveX~\cite{ActiveX}, (Portable) Native Client~\cite{NativeClient, Ansel:2011:LSJ:1993498.1993540}, or asm.js~\cite{asmjs}. To provide some safety guarantees when running untrusted web code, WebAssembly type checks all instructions, strictly separates code from data, verifies that accesses to the linear memory are in-bounds, and offers well-defined interfaces for interaction between modules. Despite its young age, WebAssembly has already been adopted for various applications, including games\footnote{\url{https://s3.amazonaws.com/mozilla-games/ZenGarden/EpicZenGarden.html}}, cryptography~\cite{Attrapadung:2018:ETH:3196494.3196552}, machine learning~\cite{Gottl:2018:EPT:3208806.3208815}, and medical applications~\cite{doi:10.1177/1176935118771972}. WebAssembly, it seems, will be a ubiquitous and important instruction set for years to come. Dynamic analysis tools have a long history of success for languages other than WebAssembly, e.g., to check and understand correctness, security, and performance properties~\cite{Bruening:2011:PMC:2190025.2190067,Seward:2005:UVD:1247360.1247362,UBSan,gcov,JaCoCo,Enck:2014:TIT:2642648.2619091}. The need for dynamic analysis is particularly strong for highly dynamic languages, such as JavaScript~\cite{Andreasen:2017:SDA:3145473.3106739} and for languages with a lot of low-level control, such as C and C++. As a compilation target of systems languages and with JavaScript as the host environment, WebAssembly sits exactly at the intersection of these two kinds of languages, making it a prime target for dynamic analysis. \begin{table*} \centering \small \renewcommand{\arraystretch}{1.1} \setlength{\tabcolsep}{7pt} \begin{tabular}{l@{\quad}llllll} \toprule & Pin~\cite{Luk:2005:PBC:1065010.1065034} & Valgrind~\cite{Nethercote:2007:VFH:1250734.1250746} & DiSL~\cite{Marek:2012:DDL:2162049.2162077} & RoadRunner~\cite{Flanagan:2010:RDA:1806672.1806674} & Jalangi~\cite{Sen:2013:JSR:2491411.2491447} & \emph{Wasabi}\\\midrule (Primary) platform & x86-64 & x86-64 & JVM & JVM & JavaScript & WebAssembly \\ Instrumentation of \ldots & native binaries & native binaries & byte code & byte code & source code & binary code\\ Analysis language & C/C++ & C & Java & Java & JavaScript & JavaScript\\ API style & \makecell[cl]{instrumentation\\+ callbacks/hooks} & \makecell[cl]{low-level\\instrumentation} & \makecell[cl]{aspect-\\oriented} & event stream & callbacks/hooks & callbacks/hooks\\ \bottomrule \end{tabular} \caption{Overview of existing dynamic analysis frameworks and Wasabi.} \label{tab:dynamic-analysis-frameworks} \end{table*} Creators of a dynamic analysis usually can choose between two options. One option is to implement the analysis from scratch. A common strategy is to add instrumentation code to the program, but this requires an in-depth understanding of the instruction set and tools to manipulate it. Another common strategy is to modify the runtime environment of the program, e.g., a virtual machine. Unfortunately, such modifications require detailed knowledge of the virtual machine implementation, and they tie the analysis to a particular version of the runtime environment. Since WebAssembly serves as a compilation target of other languages, source-level instrumentation of these languages might appear to be another possible strategy. However, typical web applications heavily rely on third-party code, for which source code is unavailable at the client-side. Instead of implementing a dynamic analysis from scratch, the second option is to build upon general-purpose dynamic analysis frameworks. \Cref{tab:dynamic-analysis-frameworks} lists some popular frameworks: Pin~\cite{Luk:2005:PBC:1065010.1065034} and Valgrind~\cite{Nethercote:2007:VFH:1250734.1250746} for native programs, DiSL~\cite{Marek:2012:DDL:2162049.2162077} and RoadRunner~\cite{Flanagan:2010:RDA:1806672.1806674} for JVM byte code, and Jalangi~\cite{Sen:2013:JSR:2491411.2491447} for analyzing JavaScript programs. Building on an existing framework reduces the overall effort required to build an analysis and enables the analysis author to focus on the design of the analysis itself. Unfortunately, there currently is no general-purpose dynamic analysis framework for WebAssembly. This paper presents \emph{Wasabi}, the first general-purpose framework for dynamic analysis of WebAssembly.\footnote{``Wasabi'' stands for \underline{W}eb\-\underline{As}sembly dynamic \underline{a}nalysis using \underline{b}inary \underline{i}nstrumentation.} Wasabi provides an easy-to-use, high-level API to implement heavyweight analyses that can monitor all low-level behavior. The framework is based on binary instrumentation, which inserts WebAssembly code that calls into analysis functions in between the program's original instructions. The analyses themselves are written in JavaScript and implement analysis functions, called \emph{hooks}, to perform arbitrary operations whenever a particular instruction is executed. To limit the overhead that a dynamic analysis imposes, Wasabi supports \emph{selective instrumentation}, i.e., it instruments only those instructions that are relevant for a particular analysis. \begin{figure} \begin{lstlisting}[language=JavaScript] const signature = {}; Wasabi.analysis.binary = function(loc, op) { switch (op) { case "i32.add": case "i32.and": case "i32.shl": case "i32.shr_u": case "i32.xor": signature[op] = (signature[op] || 0) + 1; }}; \end{lstlisting} \caption{Cryptominer detection through instruction profiling, as described in a recent WebAssembly analysis~\cite{SEISMIC}.} \label{fig:seismic} \end{figure} As a simple example of a Wasabi-based analysis, \Cref{fig:seismic} shows our re-implementation of the profiling part of a cryptomining detector~\cite{SEISMIC}. Unauthorized use of computing resources is detected by monitoring the WebAssembly program and gathering an instruction signature that is unique for typical mining algorithms. Implementing this analysis in Wasabi takes ten lines of JavaScript, which use the framework's \code{binary} hook to keep track of all executed binary operations. In contrast, the original implementation is based on a special-purpose instrumentation of WebAssembly that the authors of \cite{SEISMIC} implemented from scratch. This and more sophisticated analyses (\Cref{sec:eval-analyses}) show that Wasabi allows implementing analyses with little effort. Apart from being the first dynamic analysis framework for WebAssembly, Wasabi addresses several unique technical challenges. First, to provide a high-level API for tracking low-level behavior, the approach abstracts away various details of the WebAssembly instruction set. For example, Wasabi bundles groups of related instructions into a single analysis hook, resolves relative target labels of branch instructions into absolute instruction locations, and resolves indirect call targets to actual functions. Second, Wasabi transparently handles the interaction of the WebAssembly code to analyze and the JavaScript code that implements the analysis. A particular challenge is that WebAssembly functions must statically declare fixed parameter types, while some WebAssembly instructions are polymorphic, i.e., they can be executed with different numbers and types of arguments. To insert hook calls for polymorphic instructions, a different monomorphic variant of the hook must be generated for every concrete combination of argument types. Wasabi uses \emph{on-demand monomorphization} to automatically create such monomorphic hooks, but only for those type variants that are actually present in the given WebAssembly code. Third, Wasabi faithfully executes the original program and even preserves its memory behavior, which is useful to implement memory profilers. To this end, none of the inserted instructions requires access or modification of the program's original memory. Instead, analyses can track memory operations in JavaScript, i.e., in a separate heap that does not interfere with the WebAssembly heap. For our evaluation, we implement eight{} analyses on top of Wasabi, including basic block profiling, memory access tracing, call graph analysis, and taint analysis. We find that writing a new analysis is straightforward and typically takes at most a few dozens of lines of code. As expected by design, Wasabi faithfully preserves the original program behavior. The framework instruments large binaries quickly (e.g., 40\,MB in about 15 seconds), and it increases the code size between less than 1\% and 742\%, depending on the program and which instructions shall be analyzed. The runtime overhead imposed by Wasabi varies between 1.02x and 163x, again depending on the program and instructions-to-analyze, which is in line with existing frameworks for heavyweight dynamic analysis. \newpage \medskip \noindent In summary, this paper contributes the following: \begin{itemize}[leftmargin=\parindent] \item We present the first general-purpose framework for dynamically analyzing WebAssembly code, an instruction format that is becoming a cornerstone of future web applications. \item We present techniques to address unique technical challenges not present in existing dynamic analysis frameworks, including on-demand monomorphization of analysis hooks and static resolution of relative branch targets. \item We show that Wasabi is useful as the basis for a diverse set of analyses, that implementing an analysis takes very little effort, and that the framework imposes an overhead that is reasonable for heavyweight dynamic analysis. \item We make Wasabi available as open-source, enabling others to build on it: \url{http://wasabi.software-lab.org} \end{itemize} % \section {Approach} \label{sec:wasabi} This section describes our framework for dynamically analyzing WebAssembly programs. We give an overview of Wasabi and the design decisions that have led to it (\Cref{sec:overview}), introduce Mini-Wasm, a WebAssembly core language, (\Cref{sec:wasm-background}), describe the analysis API (\Cref{sec:analysis-api}), and finally present some details of the instrumentation (\Cref{sec:instrumentation}). \subsection{Overview} \label{sec:overview} \begin{figure} \includegraphics[width=\linewidth]{figures/overview-crop.pdf} \caption{Wasabi's instrumentation and analysis phases.} \label{fig:overview} \end{figure} \Cref{fig:overview} gives on overview of Wasabi. The inputs are a WebAssembly binary to analyze (top-left) and a dynamic analysis written in JavaScript (bottom-left). The rationale for choosing JavaScript as the analysis language is twofold. First, it is widely used in the web and hence well-known to people interested in dynamic analysis for the web. Second, JavaScript is the only high-level language that is directly supported by all platforms that currently execute WebAssembly. The framework has two phases: \emph{static instrumentation} and \emph{analysis at runtime}. The first phase augments the given WebAssembly binary with instructions that call into the analysis implementation. To this end, the instructions of the original program are interleaved with calls to \emph{low-level analysis hooks}. The low-level hooks are implemented in JavaScript code and generated by Wasabi. At runtime, the low-level hooks then call \emph{high-level analysis hooks}, which the analysis author implements. The Wasabi runtime provides further information, e.g., the types of functions in the program, to the analysis. Ahead-of-time binary instrumentation offers three important advantages over alternative designs. First, it is independent of the execution platform that WebAssembly runs on and robust to changes in current platforms. Suppose we would instead modify a specific implementation of WebAssembly, e.g., in Firefox, then Wasabi could not analyze programs executed elsewhere. Moreover, Wasabi would risk to become outdated when the execution platform evolves. Second, binary instrumentation enables Wasabi to support all languages that compile to WebAssembly, which currently include C/C++~\cite{Zakai:2011:ELC:2048147.2048224}, Rust~\cite{RustWasm}, Go~\cite{GoWasm}, and TypeScript~\cite{Reiser:2017:AJA:3141871.3141873}. Alternatively, we could rely on source-level instrumentation for these languages, but since the source code of WebAssembly running on websites is often unavailable, this is not an option if we want to support, e.g., security applications like reverse engineering. Third, ahead-of-time instrumentation avoids runtime overhead compared to instrumenting code during the execution~\cite{Bruening:2003:IAD:776261.776290, Luk:2005:PBC:1065010.1065034, Nethercote:2007:VFH:1250734.1250746}. Since WebAssembly, in contrast to other binary formats, does not suffer from language features that make ahead-of-time instrumentation inherently difficult, such as self-modifying code or mixed code and data, Wasabi can reliably instrument code ahead-of-time. \subsection{Mini-Wasm} \label{sec:wasm-background} \newcommand{\explanation}[1]{\tag*{\raisebox{.5pt}{\normalsize\color{gray}{#1}}}} \newcommand{\nonterm}[1]{\text{\rmfamily\itshape #1}} \newcommand{\literal}[1]{\text{\ttfamily\bfseries\footnotesize #1}} \newcommand{\idx}[1]{\nonterm{idx\textsubscript{#1}}} \newcommand{\type}[1]{\nonterm{type\textsubscript{#1}}} \newcommand{^{\kern1pt*}}{^{\kern1pt*}} \newcommand{\?}{^{\kern1pt\raisebox{-1pt}{\scriptsize?}}} \newcommand{\+}{^{\kern1pt+}} \begin{figure} \vspace{-12pt} \small \setlength{\jot}{.2pt} \begin{align*} \explanation{Module and sections}\\ \nonterm{module} ::=&\ \nonterm{function}^{\kern1pt*}\ \nonterm{global}^{\kern1pt*}\ \nonterm{start}\?\ \nonterm{table}\?\ \nonterm{memory}\?\\[\medskipamount] % \nonterm{function} ::=&\ \type{func}\enspace (\nonterm{import} \mid\nonterm{code})\enspace \nonterm{export}^{\kern1pt*}\\ \nonterm{global} ::=&\ \type{val}\enspace (\nonterm{import}\ \mid \nonterm{init})\enspace \nonterm{export}^{\kern1pt*}\\ \nonterm{start} ::=&\ \idx{func}\\ \nonterm{table} ::=&\ \nonterm{import}\?\ \idx{func}\kern-1pt^{\kern1pt*}\ \nonterm{export}^{\kern1pt*}\\ \nonterm{memory} ::=&\ \nonterm{import}\?\ \literal{\mdseries byte}\kern-1pt^{\kern1pt*}\ \nonterm{export}^{\kern1pt*}\\[\medskipamount] % \nonterm{import} ::=&\ \literal{\mdseries "name"},\quad\nonterm{export} ::= \literal{\mdseries "name"}\\ \nonterm{code} ::=&\ (\literal{local}\ \type{val})\kern-1pt^{\kern1pt*}\ \nonterm{instr}^{\kern1pt*}\\ \nonterm{init} ::=&\ \nonterm{instr}^{\kern1pt*}\\[\bigskipamount] % \explanation{Instructions} \nonterm{instr} ::=&\ \literal{nop} \mid \literal{drop} \mid \literal{select} \\ \mid&\ \type{val}\literal{.const}\ \nonterm{value} \mid \nonterm{unary} \mid \nonterm{binary} \\ \mid&\ \type{val}\literal{.load} \mid \type{val}\literal{.store} \mid \literal{memory.grow} \\ \mid&\ (\literal{set}\,|\,\literal{get}\,|\,\literal{tee})\literal{\_local}\ \idx{local} \mid (\literal{set}\,|\,\literal{get})\literal{\_global}\ \idx{global} \\ \mid&\ \literal{call}\ \idx{func} \mid \literal{call\_indirect}\ \type{func} \mid \literal{return} \\ \mid&\ \literal{block} \mid \literal{loop} \mid \literal{if} \mid \literal{else} \mid \literal{end} \\ \mid&\ \literal{br}\ \nonterm{label} \mid \literal{br\_if}\ \nonterm{label} \mid \literal{br\_table}\ \nonterm{label}\+ \\ \nonterm{unary} ::=&\ \literal{i32.eqz} \mid ... \mid \literal{f32.neg} \mid ... \mid \literal{f32.convert\_s/i32} \mid ... \\ \nonterm{binary} ::=&\ \literal{i32.add} \mid ... \mid \literal{i32.eq} \mid ... \\[\bigskipamount] % \explanation{Types, labels, indices} \type{val} ::=&\ \literal{i32} \mid \literal{i64} \mid \literal{f32} \mid \literal{f64}\\ \type{func} ::=&\ \type{val}^{\kern1pt*}\kern-1pt \rightarrow \type{val}^{\kern1pt*}\\[\smallskipamount] % \nonterm{label} \in\ &\mathbb{N},\quad\idx{func\,$\mid$\,global\,$\mid$\,local} \in \mathbb{N} \end{align*} \vspace{-15pt} \caption{Abstract syntax of Mini-Wasm.} \label{fig:mini-wasm} \vspace{-10pt} \end{figure} For a self-contained and concise presentation, we now introduce \emph{Mini-Wasm}, a simplified core of WebAssembly. The Wasabi implementation supports the entire WebAssembly language. \Cref{fig:mini-wasm} shows the grammar of Mini-Wasm modules. A \emph{module} corresponds to a single binary file and contains \emph{functions}, \emph{global} variables, an optional \emph{start} function, and at most one table and memory. Each of these have a name only when they are imported or exported, and otherwise are referenced by integer indices. The \emph{table} maps indices to functions and is used for indirect calls, e.g., to implement function pointers or virtual calls. Similar to native programs, and unlike in managed languages with garbage collection, WebAssembly \emph{memory} is a linear sequence of bytes, which can be increased at runtime with \code{memory.grow}. WebAssembly execution is a stack machine with per-function locals, similar to the JVM~\cite{JvmSpec}. One distinctive feature of WebAssembly, which is relevant for Wasabi, is how control-flow is encoded. Unlike in the JVM or native code, instructions are structured into well-nested, implicitly labeled blocks. Instead of unrestricted gotos that directly jump to an instruction offset, branch instructions can only target blocks in which they are enclosed. The destination block is referenced by a non-negative integer label, where zero indicates the immediately enclosing block. Depending on the block type, the next executed instruction is either the first one inside the block (for \code{loop} blocks, rendering the branch a backward jump) or the next instruction after the block's matching \code{end} instruction (for \code{block}, \code{if}, and \code{else} blocks, thus a forward jump). For example, in \Cref{fig:wasm-cf}, the label \code{1} at line~\ref{line:branch} references the block at line~\ref{line:block-begin}, and hence is a jump forward to line~\ref{line:next-instruction}. \Cref{sec:instrumentation} describes how Wasabi handles this control-flow encoding. WebAssembly is statically type checked and knows four primitive types for globals, locals, and stack values: 32 and 64 bit integers (\code{i32}, \code{i64}), and single and double precision floats (\code{f32}, \code{f64}). Many WebAssembly instructions are polymorphic in the sense that the input and result types vary depending on the context in which the instruction is executed. For example, \code{call} and \code{return} pop and push different types depending on the function type of the called and current function, respectively. Similarly, the instruction types for accesses to locals and globals depend on the referenced local and global variable. \begin{figure} \begin{lstlisting} block <---------, $\label{line:block-begin}$ block | get_local 0 | br_if 1 ---' ;; block reference by label$\label{line:branch}$ ;; next instruction if local #0 == false end end ;; matching end for first block ;; next instruction if local #0 == true $\label{line:next-instruction}$ \end{lstlisting} \caption{Structured control-flow in WebAssembly.} \label{fig:wasm-cf} \end{figure} For \code{drop}, which removes the current stack top, and \code{select}, which pushes one of two values depending on a condition, the types cannot be simply looked up in the module, but depend on the previously executed code. For example, a \code{drop} following an \code{i32.const} has \code{i32} as input type, whereas a \code{drop} following a call that returns an \code{f64} value has \code{f64} as input type. The many possible typed instructions pose a challenge for generating Wasabi's hooks, which we explain along with our solution in \Cref{sec:instrumentation}. \subsection{Analysis API} \label{sec:analysis-api} Wasabi offers analysis authors an API with hooks to be implemented by the analysis. The API is both powerful enough to enable arbitrary dynamic analyses and high-level enough to spare the analysis author dealing with irrelevant details. \Cref{tab:hooks} shows the hooks,\footnote{For brevity, the table leaves out five additional hooks that Wasabi supports, \code{start}, \code{nop}, \code{unreachable}, \code{if}, and \code{memory\_size}, for a total of 23 hooks.} along with their arguments and types. The hooks can be roughly clustered into six groups: Instructions related to stack manipulation (\code{const}, \code{drop}, \code{select}), operations (\code{unary}, \code{binary}), accesses and management of register and memory (\code{local}, \code{global}, \code{load}, \code{store}, \code{memory\_grow}), function calls (\code{call\_pre}, \code{call\_post}, \code{return}), control flow (\code{br}*), and blocks (\code{begin}, \code{end}). Each hook implementation receives details about the respective instruction, e.g., its inputs and outputs, as well as the code location of the instruction. The API is designed to ensure four important properties. \begin{itemize}[leftmargin=\parindent] \item \emph{Full instruction coverage}. It covers all WebAssembly instructions and provides all their inputs and results to the analysis. This property is crucial to implement arbitrary dynamic analyses that can observe all runtime behavior. We describe in \Cref{sec:instrumentation} how selective instrumentation limits the costs to be paid for this flexibility. \item \emph{Grouping of instructions}. The API groups related WebAssembly instructions into a single hook, which significantly reduces the number of hooks analyses must implement. Providing one hook per instruction to the analysis would require a huge number of hooks (e.g., there are 123 numeric instructions alone), whereas Wasabi's API provides 23 hooks only. To distinguish between instructions, if necessary, the hooks receive detailed information as arguments. For example, the \code{binary} hook receives an \code{op} argument that specifies which binary operation is executed. To hide the various variants of polymorphic instructions from analyses authors, Wasabi also maps all variants of the same kind of instruction into a single hook. For example, the \code{call} instruction can take different numbers and types of arguments, depending on the called function, which are represented in the hook as an array of varying length. \item \emph{Pre-computed information}. Wasabi provides pre-computed information along with some hooks because the runtime values on their own are not informative enough for an analysis. For example, the three branch-related hooks receive \code{target} objects that contain the statically resolved, absolute location of the next instruction that will be executed, if the branch is taken, alongside the low-level relative branch label. Similarly for indirect calls, Wasabi resolves the runtime table index to the actually called function. \item \emph{Faithful type mappings}. Finally, the API faithfully maps typed values from WebAssembly to JavaScript. \Cref{fig:type-mapping} shows the four primitive WebAssembly types and how they are represented without loss of precision in a Wasabi analysis. \code{i32}, \code{f32}, and \code{f64} are represented as a JavaScript \code{number}. Since JavaScript has no native support for 64-bit integers, Wasabi transparently maps them to \code{long.js}\footnote{\url{https://github.com/dcodeIO/long.js}} objects. Conditions, which are \code{i32}s with value 0 or 1 in WebAssembly, are mapped to JavaScript's \code{boolean}s. \end{itemize} \begin{table} \lstset{style=table,basicstyle=\small\ttfamily,morekeywords={unary,binary,load,store,memory_grow,local, global,call_pre,call_post,begin,end,br_table}} \small \begin{adjustbox}{center} \begin{tabular}{@{\hskip2pt}l@{\hskip-35pt}r@{\hskip2pt}} \toprule \normalsize Hook Name & \normalsize Arguments and Types\\ \midrule \lstinline|const|\kern1pt/\kern.5pt\lstinline|drop| & \lstinline|value|: $\type{val}$\\ \lstinline|select| & \lstinline|condition|: \lstinline|boolean|, \lstinline|first|: $\type{val}$, \lstinline|second|: $\type{val}$\medskip\\ \lstinline|unary| & \lstinline|op|, \lstinline|input|: $\type{val}$, \lstinline|result|: $\type{val}$\\ \lstinline|binary| & \lstinline|op|, \lstinline|first|: $\type{val}$, \lstinline|second|: $\type{val}$, \lstinline|result|: $\type{val}$\\ \lstinline|local|\,/\kern.5pt\lstinline|global| & \lstinline|op|, \lstinline|index|: \lstinline|number|, \lstinline|value|: $\type{val}$\\ \enspace\emph{where} & \lstinline|op|: instruction \lstinline|string|, e.g., \code{i32.add} or \code{get\_local}\medskip\\ \lstinline|memory_grow| & \lstinline|delta|: \lstinline|number|, \lstinline|previousSize|: \lstinline|number|\\ \lstinline|load|\,/\kern.5pt\lstinline|store| & \lstinline|op|, \lstinline|memarg|, \lstinline|value|: $\type{val}$\\ \enspace\emph{where} & \lstinline|memarg|: \lstinline|{addr|: \lstinline|number|, \lstinline|offset|: \lstinline|number}|\medskip\\ \lstinline|call_pre| & \lstinline|func|: \lstinline|number|, \lstinline|args|, \lstinline|tableIndex|: (\lstinline|number| | \lstinline|null|)\\ \enspace\emph{where} & \lstinline|args|: \code{[}$\type{val}$\code{]}, \lstinline|tableIndex| \lstinline|==| \lstinline|null| iff direct call\\ \lstinline|call_post|\kern1pt/\kern.5pt\lstinline|return| & \lstinline|results|: \code{[}$\type{val}$\code{]}\medskip\\ \lstinline|br| & \lstinline|target|\\ \lstinline|br_if| & \lstinline|target|, \lstinline|condition|: \lstinline|boolean|\\ \lstinline|br_table| & \lstinline|table|: \lstinline|[target]|, \lstinline|tableIndex|: \lstinline|number|\\ \enspace\emph{where} & \lstinline|target|: \lstinline|{label|: \lstinline|number|, \lstinline|location|: \lstinline|location}|\medskip\\ \lstinline|begin| & \lstinline|type|\\ \lstinline|end| & \lstinline|type|, \code{begin}: \lstinline|location|\\ \enspace\emph{where} & \lstinline|type|: \lstinline|string| $\in \lbrace\texttt{function}, \texttt{block}, \texttt{loop}, \texttt{if}, \texttt{else}\rbrace$\medskip\\ \emph{every hook} & \lstinline|location|: \lstinline|{func|: \lstinline|number|, \lstinline|instr|: \lstinline|number}|, \ldots\\ \bottomrule \end{tabular} \end{adjustbox} \caption{API of the high-level analysis hooks.} \label{tab:hooks} \end{table} \begin{figure} \centering \includegraphics[width=.38\linewidth]{figures/type-mapping-crop.pdf} \caption{Mapping of WebAssembly types to JavaScript.} \label{fig:type-mapping} \end{figure} \medskip \noindent The API gives analysis authors the power to implement sophisticated dynamic analyses with little effort. In particular, it is straightforward to implement memory shadowing~\cite{Nethercote:2007:VFH:1250734.1250746,DBLP:conf/cgo/ZhaoBA10}, a feature useful, e.g,. for tracking the origin of undesired values or for taint analysis. To associate some meta-information with a memory value, all an analysis must do is to maintain a map of memory locations to meta-information, and to update the meta-information on memory-related instructions. One of our example analyses (\Cref{sec:eval-analyses}) is a taint analysis that implements memory shadowing in this way. \subsection{Binary Instrumentation} \label{sec:instrumentation} The following presents the core of Wasabi: its binary instrumentation component, which inserts code that eventually calls the high-level analysis hooks described in the previous subsection. We first describe the instrumentation of individual WebAssembly instructions (\Cref{sec:instrInstr}) and how Wasabi reduces overhead via selective instrumentation (\Cref{sec:selectiveInstr}). Then, we highlight four instrumentation challenges that are unique to WebAssembly and describe how Wasabi addresses them (Sections~\ref{sec:mono} to~\ref{sec:i64}). \newenvironment{explaintable}{\small\setlength\extrarowheight{-.5pt}\begin{tabular}{@{}l}}{\end{tabular}} \newcommand{\tableheading}[1]{& \multicolumn{3}{@{}l@{}}{\small #1:}} \begin{table*} \thisfloatpagestyle{empty} \begin{adjustbox}{center} \lstset{style=table} \begin{tabular}{@{}rl@{}l@{\enspace}l@{\hspace*{-12pt}}} \toprule & \multicolumn{2}{l}{\hspace{2.7em} Instructions} & \multirow{2}{*}{\makecell{Explanations and other changes made to the module}}\\ & Original\hspace{1.5em}$\Rightarrow$\hspace*{1.5em}& Instrumented &\\ \specialrule{\lightrulewidth}{.4ex}{6pt} \tableheading{Constants ($\type{val}$\code{\bfseries.const}), similarly simple instructions that only produce a value}\\[-1pt] 1 & \begin{lstlisting} i32.const $\nonterm{value}$ \end{lstlisting} & \begin{lstlisting} i32.const $\nonterm{value}$ i32.const $\nonterm{value}$ call $\idx{\kern1pt\code{hooks.i32.const}}$ \end{lstlisting} & \begin{explaintable} original instruction\\ duplicate constant value for the hook\\ instrumentation hook, also needs to be added as function import to module\\ \end{explaintable} \\ \midrule \tableheading{General instructions (unary, binary, load, store)}\\[-1pt] 2 & \begin{lstlisting} f32.abs \end{lstlisting} & \begin{lstlisting} tee_local $\idx{temp input local}$ f32.abs tee_local $\idx{temp result local}$ get_local $\idx{temp input local}$ get_local $\idx{temp result local}$ call $\idx{\kern1pt\code{hooks.f32.abs}}$ \end{lstlisting} & \begin{explaintable} store instruction input(s) into freshly generated local(s)\\ \\ store instruction result into freshly generated local\\ \rdelim\}{2}{*}[\,push inputs and results on stack as hook arguments]\\ \\ one low-level hook per instruction\\ \end{explaintable} \\ \midrule \tableheading{Calls (\code{call} and \code{call\_indirect}), similarly also \code{return}s}\\[-1pt] 3 & \begin{lstlisting} call $\idx{func}$ \end{lstlisting} & \begin{lstlisting} tee_local $\idx{temp input local}$ i32.const $\idx{func}$ get_local $\idx{temp input local}$ call $\idx{\kern1pt\code{hooks.call\_pre\_}(\type{local})*}$ call $\idx{func}$ tee_local $\idx{temp result local}$ get_local $\idx{temp input local}$ call $\idx{\kern1pt\code{hooks.call\_post\_}(\type{local})*}$ \end{lstlisting} & \begin{explaintable} store call argument(s) in freshly generated local(s)\\ pass index of called function to hook\\[1pt] \rdelim\}{2}{*}[\,pass stored inputs to monomorphized \code{call\_pre} hook]\\ \\[1pt] \\ store call result(s) in freshly generated local(s)\\ \rdelim\}{2}{*}[\,pass stored results to monomorphized \code{call\_post} hook]\\ \\ \end{explaintable} \\ \midrule \tableheading{Polymorphic \code{drop} and \code{select} instructions}\\[-1pt] 4 & \begin{lstlisting} $\ldots$ $\textrm{(preceding code)}$ $\ldots$ drop \end{lstlisting} & \begin{lstlisting} $\ldots$ $\textrm{(preceding code)}$ $\ldots$ call $\idx{\kern1pt\code{hooks.drop\_}\type{val}}$ \end{lstlisting} & \begin{explaintable} type check all instructions to keep track of abstract stack\\ here: assuming preceding instructions produce a stack top value of type \type{val},\\ then the following \code{drop} has type \code{[\type{val}]} $\rightarrow$ \code{[]}\\ matching monomorphic hook call is inserted (consumes stack top in place of \code{drop}) \end{explaintable} \\[5pt] \midrule \tableheading{Blocks\kern.5pt/structured control-flow (\code{block}, \code{loop}, \code{if}, \code{else}, \code{end}) and branches (\code{br}, \code{br\_if}, \code{br\_table})}\\[-1pt] 5 & \begin{lstlisting} $\nonterm{label}\!:$ block $\nonterm{otherlabel}\!:$ loop $...$ br 1 $(\kern-.5pt\nonterm{label}\kern.5pt)$ $...$ end end \end{lstlisting} & \begin{lstlisting} $\nonterm{label}\!:$ block call $\idx{\code{hooks.begin\_block}}$ $\nonterm{otherlabel}\!:$ loop call $\idx{\code{hooks.begin\_loop}}$ $...$ i32.const 1 $(\kern-.5pt\nonterm{label}\kern.5pt)$ i32.const $\text{\rmfamily resolve}(\kern-.5pt\nonterm{label}\kern.5pt)$ call $\idx{\code{hooks.br}}$ call $\idx{\code{hooks.end\_loop}}$ call $\idx{\code{hooks.end\_block}}$ br 1 $(\kern-.5pt\nonterm{label}\kern.5pt)$ $...$ call $\idx{\code{hooks.end\_loop}}$ end call $\idx{\code{hooks.end\_block}}$ end \end{lstlisting} & \begin{explaintable} \\[-5pt] % \nonterm{label} is implicit and not encoded in the Wasm binary\\ every block type (\code{block}/\code{loop}/\code{if}/\code{else}) has own low-level \code{begin} hook\\ \\ loop \code{begin} hook is called once per iteration\\ \\ \enquote{raw} (i.e., unresolved relative) target label is passed to hook as integer\\ resolved (at instrumentation time) label to next executed instruction is also passed\\ branch hooks must come before the instruction\\ \rdelim\}{2}{*}[\,explicitly call \code{end} hooks of all \enquote{traversed} blocks, for dynamic block nesting]\\ \\[2pt] \\ (not shown:) end hooks receive location of the end and of the matching block begin\\ every block type (\code{block}/\code{loop}/\code{if}/\code{else}) has own \code{end} hook (cf. \code{begin\_*} hook)\\ \\ \\ \\ \end{explaintable} \\ \midrule \tableheading{Instructions with \code{i64} inputs or results, value is split for passing to hook}\\[-1pt] 6 & \begin{lstlisting} i64.const $\nonterm{value}$ \end{lstlisting} & \begin{lstlisting} i64.const $\nonterm{value}$ i64.const $\nonterm{value}$ i32.wrap/i64 i64.const $\nonterm{value}$ i64.const 32 i64.shr_s i32.wrap/i64 call $\idx{\kern1pt\code{hooks.i64.const}}$ \end{lstlisting} & \begin{explaintable} if instruction has side-effects, its result is duplicated via a local instead (but const here)\\[-1pt] \rdelim\}{2}{*}[\,push lower 32-bit half of \code{i64} value as \code{i32} on stack]\\ \\[2pt] \rdelim\}{4}{*}[\,shift upper 32-bit half of \code{i64} value to right, then push as \code{i32} on stack]\\ \\ \\ \\ cannot pass \code{i64} values to hooks, so they take a tuple of (\code{i32}, \code{i32}) instead\\ \end{explaintable} \\ \bottomrule \end{tabular} \end{adjustbox} \caption{Instrumentation of (a subset of all) WebAssembly instructions. Every hook also takes two \code{i32}s that represent the original instruction's location. For brevity, the corresponding \code{i32.const} instructions are omitted in the table.} \label{tab:instrumentation} \end{table*} \subsubsection{Instrumentation of Instructions} \label{sec:instrInstr} To keep track of all instructions that occur during the execution, Wasabi inserts for each instruction a call to an analysis hook. \Cref{tab:instrumentation} illustrates the instrumentation for a subset of all instructions. Row~1 shows the simplest case: a \code{const} instruction that pushes an immediate value on the stack. The instrumentation adds a call to the corresponding hook. Since the hook receives the value produced by the \code{const} instruction as an argument, the value is pushed once more on the stack prior to the call. After the call to the hook, the stack will be the same as in the original, uninstrumented program. Row~2 of \Cref{tab:instrumentation} shows an instruction that takes inputs and produces results. To pass both to the inserted hook call, we need to duplicate values on the stack. For this purpose, Wasabi generates a fresh local of the appropriate type and writes the current stack top to this local with \code{tee\_local}. Before the hook call, the inserted code retrieves the stored input and its result with \code{get\_local}. Row~3 illustrates how Wasabi instruments \code{call} instructions. In contrast to other instructions, we surround the original instruction with two calls into the analysis, so that an analysis author can execute analysis behavior before and after the call. All inserted calls go to JavaScript functions that are imported into the WebAssembly binary. These imported functions are not yet the high-level hooks from \Cref{sec:analysis-api}, but low-level hooks that are automatically generated by Wasabi. There are several reasons for this indirection. First, it allows Wasabi to map typed WebAssembly instructions to untyped JavaScript hooks in a seamless way (\Cref{sec:mono}). Second, it helps providing information that is useful in high-level hooks but not available at the current instruction (\Cref{sec:resolving}). Third, \Cref{sec:blocks} shows that Wasabi sometimes also calls other hooks at runtime, because the necessary information which hooks to call is available only then. Finally, the low-level hooks can convert values before passing them to the high-level hooks (\Cref{sec:i64}). All of these issues can be solved by automatically generated low-level hooks that are hidden from analysis authors. \subsubsection{Selective Instrumentation} \label{sec:selectiveInstr} Not every analysis uses all of the hooks provided by the API from \Cref{sec:analysis-api}. To reduce both the code size and the runtime overhead of the instrumented binary, Wasabi supports \emph{selective instrumentation}. That is, only those kinds of instructions are instrumented that have a matching high-level hook in the given analysis. Wasabi ensures that the instrumentation for different kinds of instructions are independent of each other, so that instrumenting only some instructions still correctly reflects their behavior. Sections~\ref{sec:eval-code-size} and \ref{sec:eval-runtime-overhead} show that selective instrumentation significantly reduces code size and runtime overhead. \subsubsection{On-demand Monomorphization} \label{sec:mono} An interesting challenge for the instrumentation comes from static typing in WebAssembly. While there are polymorphic instructions, WebAssembly functions, including our hooks, must always be declared with a fixed, monomorphic type. For polymorphic instructions, Wasabi cannot simply generate one hook per kind of instruction: Consider \code{drop} with the polymorphic instruction type [{\small$\alpha$}]\,$\rightarrow$\,[\,]. Inserting a call to the same hook after each \code{drop} is not possible, because the hook's function type would then be polymorphic. Instead, Wasabi generates multiple monomorphic variants of a polymorphic hook and inserts a call to the appropriate monomorphic low-level hook.\footnote{This strategy is similar to the compilation of generic functions in Rust or instantiation of function templates in C++~\cite{klabnik2018rust, Vandevoorde:2002:CT:579240}.} For many polymorphic instructions, determining which monomorphic hook variant to call is straightforward. For example, the instruction type of \code{set\_global} depends only on the type of the referenced variable. The types of \code{drop} and \code{select}, however, cannot be simply looked up. Instead, as shown in row~4 of \Cref{tab:instrumentation}, their type depends on all preceding instructions. Wasabi thus performs full type checking during instrumentation, that is, it keeps track of the types of all values on the stack~\cite{Haas:2017:BWU:3062341.3062363, Watt:2018:MVW:3176245.3167082}. When the \code{drop} in the last line of the example is encountered, its input type is equal to the top of the abstract stack and Wasabi can insert the call to the matching monomorphic low-level hook. While creating monomorphic variants of hooks yields type-correct WebAssembly code, doing so eagerly leads to an explosion of the required number of monomorphic hooks. Since functions can have an arbitrary number of arguments and results\footnote{Strictly speaking, functions in the binary format 1.0 have at most one result, but the formal semantics already support multiple return values~\cite{Haas:2017:BWU:3062341.3062363}.}, the number of monomorphic hooks for \code{call}s and \code{return}s is even unbounded. One way to address this problem would be to set a heuristic limit, e.g., by generating hooks for calls with up to ten arguments. However, the resulting $4^{10} = 1,048,576$ call-related hooks would cause unnecessary binary bloat and may still fail to support all calls. Instead, Wasabi generates monomorphic hooks on-demand only for instructions and type combinations that are actually present in the given binary. We call this approach \emph{on-demand monomorphization} of hooks. During instrumentation, Wasabi maintains a map of already generated low-level hooks. If a required hook, e.g., for a \code{call} instruction with type [\code{i32}]\,$\rightarrow$\,[\code{f32}], is present in the map, the function index of the hook is returned. Otherwise, Wasabi generates the hook and updates the map. Our evaluation shows that on-demand monomorphization significantly reduces the number of low-level hooks, and hence the code size, compared to the eager approach described above. \subsubsection{Resolving Branch Labels} \label{sec:resolving} As described in \Cref{sec:wasm-background}, WebAssembly relies on structured control-flow, a feature not present in other low-level instruction sets. An interesting challenge that arises from structured control-flow is how and when to resolve the destination of branches. Row~5 of \Cref{tab:instrumentation} illustrates the problem with a few control-flow-related instructions. The \code{br} instruction jumps to a destination referenced by a relative integer label \code{1}. However, passing this label to the high-level dynamic analysis API would be of limited use, because without additional static information (namely the surrounding blocks), the dynamic analysis cannot resolve the label to a code location. \begin{figure} \centering \includegraphics[width=.45\linewidth]{figures/control-stack-crop.pdf} \caption{Abstract control stack at the \code{br} branch instruction in row~5 of \Cref{tab:instrumentation} (assuming the example is preceded by four other instructions).} \label{fig:control-stack} \end{figure} To enable analysis authors to reason about branch destinations without implementing their own static analysis, Wasabi resolves branch labels during the instrumentation and passes the resulting absolute instruction locations to the high-level API. To resolve branch labels, Wasabi keeps track of an \emph{abstract control stack} while instrumenting WebAssembly code. Whenever the instrumentation enters a new block, an element is pushed to the control stack, consisting of the block type (\code{function}, \code{block}, \code{loop}, \code{if}, or \code{else}), the location of the block begin, and the location of the matching \code{end} instruction. Whenever the instrumentation encounters the end of a block, the topmost entry is popped of the control stack. As an example, \Cref{fig:control-stack} shows the control stack for the code in row~5 of \Cref{tab:instrumentation}. Given the abstract control stack, Wasabi can determine during instrumentation what code location a branch, if taken, will lead to. At every branch to a label $n$, Wasabi queries the control stack for its $n+1$-th entry from the top, to determine the targeted block, and then computes the location of the next instruction from the block type and the locations of the \code{begin} and \code{end} instructions. This absolute instruction location is then given as an argument to the branch hook, as shown in the example in \Cref{tab:instrumentation}. \subsubsection{Dynamic Block Nesting} \label{sec:blocks} Another control-flow-related challenge is about observing the end of the execution of a block. Some analyses may want to observe the block nesting at runtime, i.e., to perform some action when a block is entered and left. For this purpose, Wasabi offers the high-level \code{begin} and \code{end} hooks (\Cref{sec:analysis-api}). The example in row~5 of \Cref{tab:instrumentation} shows that our instrumentation adds the respective hook calls (e.g., \code{call} \idx{\code{hooks.begin\_block}} and \code{call} \idx{\code{hooks.end\_block}}) at the beginning of a block and before the matching \code{end}. Unfortunately, \code{br}anching or \code{return}ing will jump out of a block and over the inserted \code{end} hook calls. Consider the last two calls to \code{hooks.end\_loop} and \code{hooks.end\_block} in \Cref{tab:instrumentation}. They are not executed because the earlier \code{br} \code{1} directly transfers control to after the enclosing block. To account for that, Wasabi adds additional calls before each \code{br}anch and \code{return} that invoke every end hook of the blocks that will be \enquote{traversed} during the jump. That is, as the example shows, Wasabi inserts calls to the \code{end} hooks for the two enclosing blocks prior to the \code{br} \code{1} instruction. Again, the \emph{control stack} can tell us which end hooks need to be called, namely all between the current block (stack top, inclusive) and the branch target block (also inclusive). For example, in \Cref{fig:control-stack}, the instrumented code calls the \code{loop} and \code{block} end hooks. For a \code{return} it would be all blocks on the block stack up to and including the \code{function} block. For conditional branches (\code{br\_if}), we call the \code{end} hooks for traversed blocks only if the branch is actually taken. Similarly, for multi-way branches (\code{br\_table}), which branch is taken (and thus which blocks are left) is known only at runtime. Thus, the instrumentation statically extracts the list of ended blocks for every branch table entry and stores this information. Inside the low-level hook for \code{br\_table}, one of the stored branch table entries will then be selected, before calling the corresponding \code{end} hooks at runtime. \subsubsection{Handling \code{i64} Values} \label{sec:i64} As mentioned in \Cref{sec:wasm-background}, \code{i64} values cannot be passed to JavaScript functions (and thus our hooks), since JavaScript has only double precision float numbers. To nevertheless enable dynamic analyses to faithfully observe all runtime values, including \code{i64} values, Wasabi splits a 64-bit integer into two 32-bit integers to pass them to JavaScript. For every \code{i64} stack value (either produced by a \code{const} or by any other instruction), we thus insert instrumentation as shown in row~6 of \Cref{tab:instrumentation}. The inserted code duplicates the \code{i64} value twice, from the first of which only the lower 32 bits are extracted and the second of which is shifted to result in the upper 32 bits. Both \code{i32} values can then be passed to the hook in question. On the JavaScript side, the low-level hook joins the two 32-bit values into a \code{long.js} object\footnote{An alternative would be to use the recently proposed \code{BigInt} support for JavaScript (\url{https://github.com/tc39/proposal-bigint}), but this feature is currently only available in Chrome.}, enabling an analysis to faithfully reason about 64-bit integers. % \section{Implementation} \label{sec:implementation} We have implemented the Wasabi instrumenter, including the static analyses it performs, in about 5000 lines of Rust code. Rust programs themselves can be compiled to WebAssembly, which gives us the option to run Wasabi in the browser and instrument WebAssembly programs at load time in the future. To reduce the time required for instrumenting large binaries, Wasabi can instrument multiple WebAssembly functions in parallel. The only synchronization point is the map of low-level hooks created during on-demand monomorphization, which is guarded by an upgradeable multiple readers/single writer lock. Our implementation is available to the public under the permissive MIT license at \url{http://wasabi.software-lab.org}. % \section{Evaluation} \label{sec:evaluation} To evaluate Wasabi, we focus on five research questions: \begin{enumerate}[label=\itshape\bfseries RQ\,\arabic*,labelsep=1em,leftmargin=*,topsep=\smallskipamount,itemsep=\smallskipamount] \item How easy is it to write dynamic analyses with Wasabi? \item Do the instrumented WebAssembly programs remain faithful to the original execution? \item How long does it take to instrument programs? \item How much does the code size increase? \item What is the runtime overhead due to instrumentation? \end{enumerate} \subsection{Experimental Setup} We apply Wasabi to 32{} programs. 30 of them are from the PolyBench/C benchmark suite\footnote{\url{http://web.cse.ohio-state.edu/~pouchet.2/software/polybench/}}, which has been used in the paper introducing WebAssembly~\cite{Haas:2017:BWU:3062341.3062363}. In total, the PolyBench benchmark suite comprises 5,163 non-empty, non-comment lines of C code. We compile the PolyBench programs to WebAssembly with emscripten 1.38.8, resulting in 790\,KB of WebAssembly binaries. Moreover, we use two complex, real-world programs: the Unreal Engine~4 Zen Garden demo\footnote{\url{https://s3.amazonaws.com/mozilla-games/ZenGarden/EpicZenGarden.html}}, as an example of a major game engine running in the browser, and the PSPDFKit benchmark\footnote{\url{https://pspdfkit.com/webassembly-benchmark/}}, which exercises a commercial library for in-browser rendering and annotation of PDFs. Their WebAssembly binaries are 39.5\,MB and 9.5\,MB, respectively. All experiments are performed on a laptop with an Intel Core i7-7500U CPU (2 cores, hyper-threading, 2.7 to 3.5\,GHz, 4\,MB L3 cache) and 16\,GB of RAM. The operating system is Ubuntu 17.10 64-bit. To execute WebAssembly programs, we use a nightly version of Firefox 63.0a1 (2018-08-02).% \subsection{Ease of Implementing Analyses (RQ\,1)} \label{sec:eval-analyses} \begin{table} \setlength{\tabcolsep}{2pt} \begin{adjustbox}{center} \begin{tabular}{@{}l@{\hspace*{-2pt}}rr@{}} \toprule Analysis & Hooks & LOC\\ \midrule Instruction mix analysis & all & 42\\ Basic block profiling & \code{begin} & 9\\[\medskipamount] Instruction coverage & all & 11\\ Branch coverage & \code{if}, \code{br\_if}, \code{br\_table}, \code{select} & 14\\[\medskipamount] Call graph analysis & \code{call\_pre} & 18\\ Dynamic taint analysis & all & 208\\ Cryptominer detection & \code{binary} & 10\\ Memory access tracing & \code{load}, \code{store} & 11\\ \bottomrule \end{tabular} \end{adjustbox} \caption{Analyses built on top of Wasabi.} \label{tab:analyses} \end{table} We have implemented eight{} dynamic analyses on top of Wasabi. Table~\ref{tab:analyses} lists them, along with the hooks they implement and their total lines of JavaScript code. \paragraph{Instruction Mix Analysis} This analysis counts how often each kind of instruction is executed, which can serve as a basis for performance and security analyses. \paragraph{Basic Block Profiling} A classic dynamic analysis~\cite{chang1988trace} that counts how often each function, block, and loop is executed, which is useful, e.g., for finding \enquote{hot} code. \paragraph{Instruction and Branch Coverage} These analyses record for each instruction and branch, respectively, whether it is executed, which is useful to assess the quality of tests. \paragraph{Call Graph Analysis} This analysis creates a dynamic call graph, including indirect calls and calls between functions that are neither imported nor exported. Call graphs are the basis of various other analyses, e.g., to find dynamically dead code or to reverse-engineer malware. \paragraph{Taint Analysis} The analysis associates a taint with every value and tracks how taints propagate through instructions, function calls, and memory accesses, to detect illegal flows from sources to sinks. \paragraph{Memory Access Tracing} The analysis tracks all memory accesses and stores them for a later off-line analysis, e.g., to detect cache-unfriendly access patterns. \paragraph{Cryptominer Detection} As discussed in the introduction, this analysis gathers a signature based on the frequency of binary instructions to identify mining of cryptocurrencies~\cite{SEISMIC}. \begin{figure} \begin{lstlisting}[language=JavaScript] const coverage = []; function addBranch({func, instr}, branch) { coverage[func] = coverage[func] || []; coverage[func][instr] = coverage[func][instr] || []; if (!coverage[func][instr].includes(branch)) { coverage[func][instr].push(branch); } } Wasabi.analysis = { if_(loc, cond) { addBranch(loc, cond) }, br_if(loc, target, cond) { addBranch(loc, cond) }, br_table(loc, tbl, df, idx) { addBranch(loc, idx) }, select(loc, cond) { addBranch(loc, cond) }, }; \end{lstlisting} \caption{Branch coverage analysis with Wasabi.} \label{fig:branch-coverage} \end{figure} \medskip\noindent As illustrated by the low numbers of lines of code in Table~\ref{tab:analyses}, each of these analyses can be implemented with little effort. For further illustration, \Cref{fig:branch-coverage} shows the implementation of the branch coverage analysis. It implements four hooks, \code{if}, \code{br\_if}, \code{br\_table}, and \code{select} to keep track of all branches. \subsection{Faithfulness of Execution (RQ\,2)} \label{sec:eval-faithfulness} To validate that Wasabi's instrumentation does not modify the semantics of the original program, we compare the behavior of each unmodified binary with the behavior of the fully instrumented binary. For the PolyBench programs, we compile each program with an option to output intermediate results of every calculation on the console. Similarly, the Unreal Engine demo has a mode to check that the pixel values of rendered frames are the same as pre-defined reference frames. For all these programs, the behavior remains unchanged after instrumentation. The PSPDFKit benchmark does not provide any built-in correctness check; based on our manual observations the behavior of the original and instrumented code appear to be the same. As another way to validate the instrumented WebAssembly code, we use the static WebAssembly validator, which offers some well-formedness guarantees and checks that the code is type correct~\cite{WasmSpec}. Running \code{wasm-validate} from the WebAssembly Binary Toolkit\footnote{\url{https://github.com/WebAssembly/wabt}} on all 32 fully instrumented programs shows that all the instrumented code passes the validator. We also instrument and successfully validate Wasabi's output on all programs of the official WebAssembly specification test suite\footnote{\url{https://github.com/WebAssembly/spec/tree/master/test}}, which consists of 63 additional programs. \subsection{Time to Instrument (RQ\,3)} \label{sec:eval-time-instrument} \begin{table} \begin{adjustbox}{center} \begin{tabular}{l@{\hspace*{3pt}}rr@{\ }r@{\ }rr} \toprule Program & Binary Size (B) & \multicolumn{3}{r}{Runtime (ms)} & $\frac{\text{MB}}{\text{s}}$\\ \midrule PolyBench (avg.) & 26\,332 $\pm$ 299 & 23 & $\pm$ & 1.4 & 1.15 \\ PSPDFKit & 9\,615\,389 & 5\,129 & $\pm$ & 65 & 1.87 \\ Unreal Engine 4 & 39\,510\,398 & 15\,481 & $\pm$ & 293 & 2.55\\ \bottomrule \end{tabular} \end{adjustbox} \caption{Time taken to instrument programs, averaged across 20 runs (and 30 programs for PolyBench).} \label{tab:runtime} \end{table} \Cref{tab:runtime} shows how long Wasabi takes to instrument the programs. The $x \pm y$ notation means a mean value of $x$ and a standard deviation of $y$ after 20 repetitions. For readability, we have summarized the results for all 30 PolyBench programs in one row. While the PolyBench programs are of similar, small size (26.3\,KB\,$\pm$\,299\,B), the PSPDFKit and Unreal Engine binaries are considerably larger (9.6\,MB and 39.5\,MB, respectively). Instrumentation takes 23ms, on average, for the PolyBench programs, i.e., it is almost instantaneous, and still quick for the larger PSPDFKit (5s) and Unreal Engine binaries (15.5s). Wasabi's instrumentation is parallelized (\Cref{sec:implementation}), and these numbers are obtained with four threads running on two physical cores. The single-threaded instrumentation time on the large Unreal Engine binary is on average 26.5s, showing that the parallelization reduces the execution time to 15.5/26.5 $\approx$ 0.58 of the single-threaded time. The last column of \Cref{tab:runtime} reports the throughput, i.e., binary code processed per second, showing that the throughput increases with larger binary sizes. \subsection{Increase of Code Size (RQ\,4)} \label{sec:eval-code-size} \begin{figure*} \includegraphics[width=\textwidth]{figures/code-size-crop.pdf} \caption{Binary size increase in percent of the original size, when instrumenting the test programs for different analysis hooks. For readability, binary sizes for the 30 PolyBench programs are shown averaged.} \label{fig:binary-size} \includegraphics[width=\textwidth,trim=0 0 0 -10pt]{figures/runtime-analysis-crop.pdf} \caption{Runtime of the instrumented programs relative to the uninstrumented runtime, per analysis hook. Results are averaged over 20 runs (and again for readability, over the 30 PolyBench programs).} \label{fig:runtime-analysis} \end{figure*} \Cref{fig:binary-size} presents the increase in binary code size after instrumenting a program. Since many analyses need only a small subset of all hooks (e.g., block profiling needs only \texttt{begin}), we evaluate code size increase per required hook, as provided by selective instrumentation (\Cref{sec:selectiveInstr}). For each hook on the x-axis, the figure shows on the y-axis the increase in binary size as a percentage of the original program size. That is, 0\% means the instrumented binary has the same size as the original one and 100\% means the program doubled in size due to instrumentation. With selective instrumentation, more than half of the hooks increase the binary size only by a negligible amount or not at all (less than 1\% increase for \texttt{nop}, \texttt{unreachable}, \texttt{memory\_size}, \texttt{memory\_grow}, \texttt{select}, and \texttt{br\_table}; less than 10\% for \texttt{drop}, \texttt{return}, \texttt{unary}, \texttt{global}, \texttt{if}, \texttt{br}, and \texttt{br\_if}, on average). In fact, in several cases the Unreal Engine binary decreased by 1\% because Wasabi encodes indices more compactly than the original binary.\footnote{WebAssembly uses the variable length LEB128 encoding for integers, also known from the DWARF debug information format~\cite{DWARFSpec}. This allows for multiple possible encodings with different lengths of the same number.} Naturally, hooks for instructions that appear very often in the program have the largest influence on the code size, e.g., memory \texttt{load} and \texttt{store} (between 39\% and 58\% increase), \texttt{begin} and \texttt{end} of blocks (11\%\,--\,84\%), pushing to the stack with \texttt{const} (59\,--\,71\%), operations on \texttt{local}s (128\,--\,180\%), and finally \texttt{binary} instructions (83\,--\,190\%). The difference for the \texttt{binary} hook between PolyBench and the other programs can be explained by the former being mostly numerical computation (thus having more binary instructions such as \code{i32.mul}), whereas PSPDFKit and the Unreal Engine have more diverse code. When instrumenting for all hooks together, which is not required for many analyses, the size increases between 495 and 743\%. This result shows that selective instrumentation is very effective in reducing the binary size, compared to blindly instrumenting all instructions. To evaluate Wasabi's on-demand monomorphization of hooks, we count how many low-level hooks are inserted during full instrumentation. For PolyBench, between 110 (\code{floyd-warshall} program) and 122 (\code{deriche}) hooks are inserted, 302 hooks for PSPDFKit, and 783 hooks for the Unreal Engine. In the original Unreal Engine binary, i.e., a real-world WebAssembly program, the call with the largest number of arguments passes 22 \code{i32} values, which clearly shows that eagerly generating all possible monomorphic combinations of call hooks ($4^{22} \approx 1.7 \times 10^{13}$) is simply not possible. Even in the small PolyBench programs, calls to functions with 6 arguments are common. For these programs, generating no more than 122 hooks on-demand is much better than generating all $4^6 = 4,096$ hooks for \code{call} instructions plus some more for other instructions. \subsection{Runtime Overhead (RQ\,5)} \label{sec:eval-runtime-overhead} \Cref{fig:runtime-analysis} shows how much runtime overhead the instrumentation imposes. On the y-axis, we show the runtime of the instrumented program relative to the original program, that is, a value of 1.0x means the runtime does not increase due to instrumentation. As for code size, most of the hooks contribute only a small runtime overhead: \code{nop}, \code{unreachable}, \code{memory\_size}, \code{memory\_grow}, \code{select}, \code{drop}, and \code{unary} each impose less than 1.02x overhead, on average. Instrumenting for \code{return} or \code{call} hooks, which are sufficient for many interesting analyses at the function level, incurs a reasonable overhead of up to 1.3x or 2.8x, respectively. More expensive hooks are \texttt{begin} and \texttt{end} for observing blocks, which incur between 1.5x and 9.9x runtime overhead, 1.8x\,--\,20x for \texttt{load}, up to 6.5x for \texttt{store}, 2x\,--\,32x for \texttt{const}, 4x\,--\,48.5x for operations on \texttt{local}s, and 2.6x\,--\,77.5x for \texttt{binary} operations. When instrumenting for all hooks, the runtime overhead is between 49x and 163x. Note that the overheads for the PolyBench programs, which perform only numerical computations, are much higher than for the real-world workloads in PSPDFKit and the Unreal Engine. Typical WebAssembly programs call out to the host environment, e.g., to perform shading in WebGL, modify the DOM, or interact with some other Web API, so any overhead imposed by Wasabi contributes only to parts of the total execution time. Comparing the overhead results to existing heavy-weight dynamic analysis frameworks for other languages shows that Wasabi's overhead is reasonable. The widely-used JavaScript analysis framework Jalangi reports overheads with the \emph{empty} analysis in the same order of magnitude, namely 26x during record plus 30x during replay, on average \cite{Sen:2013:JSR:2491411.2491447}. Similarly, the RoadRunner analysis framework for JVM byte code reports an average slowdown of 52x without any analysis \cite{Flanagan:2010:RDA:1806672.1806674}. % \section{Related Work} \paragraph{WebAssembly} WebAssembly has been first publicly announced in 2015 and since 2017 is implemented by four major browser engines (Chrome, Edge, Firefox, and Safari). A paper by Haas et al.~\cite{Haas:2017:BWU:3062341.3062363} formalizes the language and its type system, and explains the design rationales. Watt describes the mechanized, formal verification of the WebAssembly specification \cite{Watt:2018:MVW:3176245.3167082}. Herrera et al.\ study the performance of WebAssembly, compared to JavaScript, for numerical benchmarks~\cite{herrera2018webassembly}. \paragraph{Dynamic Analysis of WebAssembly} Despite its young age, several dynamic analyses for WebAssembly have already been proposed, including two taint analyses~\cite{2018arXiv180201050F,szanto2018taint} and a cryptomining detector~\cite{SEISMIC}. These analyses have been implemented by modifying the V8 engine~\cite{2018arXiv180201050F}, by implementing a new WebAssembly virtual machine in JavaScript~\cite{szanto2018taint}, and through custom binary instrumentation~\cite{SEISMIC}, respectively. Our evaluation shows that these analyses and others can be implemented in top of Wasabi with significantly less effort. \paragraph{Binary Instrumentation Tools} Binary instrumentation has been a popular strategy to implement dynamic analyses. Often used tools for x86 binaries include DynamoRIO~\cite{Bruening:2003:IAD:776261.776290}, Pin~\cite{Luk:2005:PBC:1065010.1065034}, and Valgrind~\cite{Nethercote:2007:VFH:1250734.1250746}, which have provided inspiration for Wasabi. These tools instrument binaries at runtime by translating basic blocks just before their execution, and by storing translations in a code cache. In contrast, Wasabi instruments binaries statically, i.e., ahead-of-time, which avoids any instrumentation overhead during execution. Wasabi also differs w.r.t.\ the API it provides to analysis authors: While DynamoRIO provides an API to manipulate instructions, Wasabi provides an API to observe the execution of instructions. Analyses written for Pin can specify ``instrumentation routines'', which determine where to place calls to analysis routines. Instead, Wasabi automatically selects which kinds of instructions to instrument based on the hooks implemented by the analysis. Umbra~\cite{DBLP:conf/cgo/ZhaoBA10} is a dynamic binary instrumentation tool that focuses on efficient memory shadowing. In contrast, Wasabi provides a general-purpose framework for arbitrary dynamic analysis, including memory shadowing. A difference compared to all the above tools is that in Wasabi, the dynamic analysis is written and executed in a high-level language, JavaScript, instead of being compiled to binary code. The rationale is that JavaScript is already very popular in the web, making it easier for analysis authors to adopt Wasabi. \paragraph{Dynamic Analysis in General} Dynamic analysis~\cite{ball1999concept} has since long been recognized as an effective way to complement static analysis~\cite{ernst2003static}. Various analyses have been proposed, including dynamic slicing~\cite{Agrawal1990}, taint analyses for x86 binaries~\cite{Newsome2005} and Android~\cite{Enck:2014:TIT:2642648.2619091}, tools to find concurrency bugs~\cite{Lu2006,Park2009,Burckhardt2010a} and heap-related bugs~\cite{Chilimbi2006}, an analysis to track the origin of null and undefined values~\cite{Bond2007}, and analyses to understand performance problems~\cite{Yu2014}. Given the increasing interest in WebAssembly, we expect an increased demand for dynamic analyses for WebAssembly, for which Wasabi provides a reusable platform. \paragraph{Dynamic Analysis for the Web} Motivated by the dynamic features of JavaScript, such as runtime loading of code, various dynamic analyses for JavaScript-web applications have been presented. For example, recent approaches include analyses to find type inconsistencies~\cite{icse2015}, JIT-unfriendly code~\cite{fse2015}, bad coding practices~\cite{issta2015}, and data races~\cite{Petrov2012}. Many of these analysis are built on top of Jalangi~\cite{Sen:2013:JSR:2491411.2491447}, a general-purpose dynamic analysis framework for JavaScript. To the best of our knowledge, there is no comparable tool for WebAssembly yet, a gap this paper aims to fill. % \section{Conclusion} This paper presents Wasabi, a general-purpose dynamic analysis framework for WebAssembly, the new low-level instruction set for the web. The framework instruments binaries ahead-of-time and inserts code into the binary that calls into an analysis implemented in JavaScript. Besides being the first dynamic analysis framework for WebAssembly, Wasabi addresses several unique challenges that did not occur in dynamic analysis tools for other platforms. In particular, we handle the problem of tracing polymorphic instructions with analysis functions that have a fixed type via an on-demand monomorphization of analysis hooks, and we statically resolve relative branch labels in control-flow constructs during the instrumentation. The high-level API provided to analyses authors allows for implementing otherwise complex analyses with a few dozens of lines of code, while still providing a complete view of the execution. Our evaluation with both compute-intensive benchmark programs and real-world web applications shows 1.02x to 163x runtime overhead, depending on the program and which instructions are analyzed, which is reasonable for heavyweight dynamic analyses. We believe that Wasabi provides a solid basis for various analyses to be implemented in the future. As an interesting challenge for future work, we envision cross-language dynamic analysis, in particular, to analyze web applications that run both JavaScript and WebAssembly code. \bibliographystyle{ACM-Reference-Format} {%
\section{Introduction} Obstructive Sleep Apnea-Hypopnea Syndrome (OSAHS) is characterized by repetitive episodes of airflow reduction (hypopnea) or cessation (apnea), which are caused by upper airway collapse during sleep\cite{olson2005}. Most common symptom of OSAHS is snoring, a sleep disturbance, which results in drowsiness during day time \cite{Javaheri2017}. Furthermore, there are also effects to health qualities such as increasing the risk of Hypertension, Diabetes, Acute Myocardial Infarction, Heart attack, Stroke, Depression, etc.\cite{Javaheri2017}. Polysomnography (PSG) is a clinical measurement technique for the sleep disorder diagnosis \cite{Susheel}. However, multiple physiological signal recordings such as electroencephalogram (EEG), electrocardiogram (ECG), electromyogram (EMG), oxygen saturation of blood (SpO2), leg movement, airflow, cannula flow, respiratory rate and body position are incorporated to PSG \cite{KushidaCA2005}. In general, PSG is performed overnight inside sleep laboratory, either in the hospital or in the clinic \cite{KAKKAR20071057}. Once PSG is recorded, medical doctor with OSAHS expertise need to perform an offline analysis on the whole physiological signals from PSG. Eventually, clinic would report Apnea-Hypopnea Index (AHI) which indicates severity of people with OSAHS\cite{QURESHI2003643}. AHI is catagorized as the following states: no SAHS (Sleep Apnea-Hypopnea Syndrome) (AHI $<$ 5 events/hr), mild SAHS (5 $\leq$ AHI $<$ 15 events/hr), moderate SAHS (15 $\leq$ AHI $<$ 30 events/hr), and severe SAHS (AHI $\geq$ 30 events/hr) \cite{QURESHI2003643}. Due to complexity and high cost of PSG \cite{JABENNETT,FLEMONS20031543}, one study reported that 90\% of people who had OSAHS were undiagnosed \cite{Singh2013629}. Thus, simplifying OSAHS diagnosis remains a challenge issue. A common approach to solve mentioned issue is reducing the complexity of SAHS (using single physiological signal), cost and analysis time, which are typically required in clinical diagnosis using PSG \cite{mlynczak2017detecting}. In previous works, researchers did try using single physiological recording from PSG to predict AHI using various computational methods. Single lead ECG, SpO2 from pulse oximeter and airflow (AF) from thermistor were proposed candidates in single recoding for SAHS diagnosis \cite{de2006nasal,magalang2003prediction,penzel2002systematic,nigro2011comparison}. Referred works are based on the same computational strategy which are finding violated periods on the signals and scoring them as apnea-hypopnea related events. The scores are interpreted into AHI eventually. In this study, we aim to develop an automated algorithms to predict SAHS severity by using single time-series, AF which is sensed by the thermistor in front of nose. The comparison of physiological recordings in standard PSG indicated that AF is the most direct measure in breathing obstruction. Moreover, an amplitude of AF will change dramatically during apnea or hypopnea periods [8]\cite{berry2012rules}. In contrast to aforementioned computational strategy, we implemented our method by using statistical based features together with either classical machine learning approaches (support vector machine, SVM and Adaboost-Classification and Regression Trees, AB-CART) or a modern artificial neural networks (deep neural networks, DNNs). Proposed method begins with statistical extracting features of Apnea and Hypopnea events, and time domain from overnight AF signals. Then, we incorporated features into SVM, AB-CART and DNN for evaluations. Classification tasks had been arranged from simple scenarios which are binary classifications (cutoff indices at AHI = 5, 15 and 30 events/hr). Finally, we performed the same method on multiple classes (no-SAHS, mild-SAHS, moderate-SAHS, and severe-SAHS) afterwards. The experimental studies and performance evaluations were designed according to a previous research on SAHS severity classification using AF signals \cite{gutierrez2016utility}. Merits of our works are proposing novel feature extractions from AF signals and performance evaluations on large population. Experimental results of proposed DNNs using proposed features outperformed classical machine learning approaches with the same features. Furthermore, accuracy of proposed DNNs was beyond AB-CART, which was reported to be state-of-the-art for SAHS detection using AF \cite{gutierrez2016utility}. \section{Methods} In this section, we first introduce OSAHS datasets from men who parent Osteoporotic Fractures named MrOS \cite{A-dean2016scaling,B-blank2005overview,C-orwoll2005design,D-blackwell2011associations}. Then, we propose statistical based feature extraction from overnight AF signals. The extracted features had fed into SVM and DNN approaches for performance comparison afterwards. 10-fold cross-validation was used to evaluate the performance in both approaches. Binary classifications (three different AHI cutoff indexes) and multi-classes classifications (four severity levels including no-SAHS/control participants) were performed in this study. \subsection{Datasets} MrOS sleep data (Visit 2) was used in this study. There were 1,026 men of age 65 years or older participated in standard sleep examinations from six clinical centers. Raw polysomnography (PSG) data in European Data Format (EDF) files with XML annotation files were exported from Compumedics Profusion software. AF signals in PSG were acquired from ProTech Thermistor sensors with 32 Hz sampling rate and high-pass filter at 0.15 Hz cutoff. Each annotation file includes starting and ending times of both Apnea and Hypopnea events. We labeled the severity of SAHS using the AHI variable provided in the datasets. Here, AHI are the numbers of Apnea events in all desaturations and Hypopnea events with 4\% oxygen desaturation per hour\cite{E-chen2015automatic}. \subsection{Subsampling and Data Preparation} We did random 520 subjects from the whole \begin{table} \caption {DEMOGRAPHIC DATA FOR THE FOUR-CLASS DIVISION} \label{table: Demographic} \begin{tabularx}{\columnwidth}{@{\extracolsep{2pt}}lCCCCCC@{}} \cline{1-6} & no & mild & mod & severe & All\\ \hline Subjects & 185 & 190 & 85 & 60 &520 \\ AHI(e/h) & $ 1.82\pm 1.40 $ & $ 8.71\pm 2.97 $ & $ 21.50\pm 3.95$ & $ 41.20 \pm 9.90$ & $12.10\pm13.10$ \\ \hline\hline \end{tabularx} \end{table} datasets for our study. In regard to personal annotation file, we gathered pieces of AF signals during Apnea and Hypopnea events individually. Both AF signals from Apnea and Hypopnea were treated in the same way. In this way, each participant had different numbers and periods of AF samples. Low frequency band is usually a major band in the AF signals \cite{F1alvarez2010spectral}, so low-pass filter with 3 Hz cut-off was applied on all AF samples prior to feature extraction process. \subsection{Feature Extraction} After the subsampling and filtering processes, we extracted 17 features from overnight AF samples in the followings: \begin{itemize} \item Number of Apnea events. \item Number of Hypopnea events. \item Summation of Apnea and Hypopnea events. \item Summation of periods (in seconds) from Apnea and Hypopnea events \item Average of maximum amplitudes from all AF samples. \item Average of minimum amplitudes from all AF samples. \item Average of mean amplitudes from all AF samples. \item Average of standard deviation of amplitudes from all AF samples. \item Maximum periods from all AF samples. \item Minimum periods from all AF samples. \item Mean of periods from all AF samples. \item Standard deviation of Apnea and Hypopnea periods from all AF samples. \item Variance of periods from all AF samples. \item Weighted averaged maximum amplitude from all AF samples \item Weighted averaged minimum amplitude from all AF samples \item Weighted averaged mean amplitude from all AF samples \item Weighted averaged standard deviation of amplitudes from all AF samples \end{itemize} \hspace{\parindent} Period of each AF sample is the weight factor in weighted averaging on the last four features. \begin{figure*} \centering \includegraphics[width=0.9\linewidth]{imageModel8.pdf} \caption{Illustration of proposed SAHS severity classifier using seventeen statistical-based features and Deep Neural Networks (DNNs).} \label{IM1} \end{figure*} \subsection{Classification of Sleep Apnea-Hypopnea Syndrome (SAHS) Severity} There were two main classification tasks in our experiments. First, we aimed to construct three binary classifiers for three AHI cutoff indices, which are clinical standard SAHS cutoff classes (AHI = 5, 15 and 30 events/hr). The number of subjects in this task were shown in Table \ref{table: Demographic}. The second task was to classify subjects in to four standard SAHS classes (normal, mild, moderate and severe). To avoid imbalanced population we did subsampling again in this task, from 520 to be 270 subjects including 70 from normal, mild and moderate subjects and 60 from severe subjects. Here, we incorporated proposed features into proposed DNNs and classical machine learning (ML) approaches, which are Support Vector Machine (SVM) and Adaboost-Classification and Regression Trees (AB-CART), for comparative classifiers. To validate DNNs, we did split datasets into three subsets which were 80\% for training set, 10\% for validation set and 10\% for testing set. To validate the rest of comparative classifiers, we did use exactly the same datasets as DNNs except validation set. Classical ML does not require validation set or we can simply say that testing set is same as validation set in ML. 10-fold cross-validation had incorporated into these datasets. \subsubsection{Deep Neural Networks (DNNs)} As shown in Figure\ref{IM1}, proposed features were fed into the DNNs. DNNs was implemented using Keras API \cite{chollet2015keras} with configuration parameters as follows: \begin{itemize} \item A stack of fully-connected neural networks with layer size of 1024, 512, 256, 128, 64, 32, 16, 8, and 4 hidden nodes. \item Each DNN layer was followed by the Hyperbolic tangent (tanh) activation function. \item The optimizer was RMSprop with the learning rate of 0.001. \item The softmax function was applied for classification. \end{itemize} \subsubsection{Machine Learning (ML) Approaches} To present superiority of proposed DNNs over conventional approaches, two classical ML approaches had been used as comparative or baseline classifiers. Conventional SVM with linear kernel and balancing classed weights and AB-CART from scikit-learn API \cite{sklearn_api} had been performed in this study. While SVM is standard baseline classifier, AB-CART had been proposed to use with Airflow (AF)-related sleep Apnea severity in previous study \cite{gutierrez2016utility}. In the binary classifications, one way repeated measure analysis of variance had been implemented to compare the performance of three classifiers using three metrics: sensitivity, specificity and accuracy. While, confusion matrices had been computed for performance comparison of multiple classes task. \begin{table*} \caption {Summary of 10-fold Sensitivity, Specificity and Accuracy of binary classification in each AHI severity cutoff using SVM, AB-CART and DNN classifier. Bold numbers in the table represent the significant highest values in each cutoff.} \label{table: summary} \begin{tabularx}{\textwidth}{@{\extracolsep{1pt}}lCCCCCCCCC@{}} \hline\hline & \multicolumn{3}{c}{Sensitivity} & \multicolumn{3}{c}{Specificity} & \multicolumn{3}{c}{Accuracy}\\ \cline{2-4} \cline{5-7} \cline{8-10} & SVM & AB-CART & DNN & SVM & AB-CART & DNN & SVM & AB-CART & DNN \\ \hline Cutoff 5& $63.79\pm 2.25$ & \boldmath$83.71\pm 1.51$ & $80.47\pm 2.98$& \boldmath$91.37\pm 5.93$ & $65.24\pm 2.60$& $86.35\pm 1.25$ &$77.89\pm 1.49$ & $77.12\pm 1.42$& \boldmath$83.46\pm 1.08$ \\ Cutoff 15 &\boldmath$90.12\pm 1.44$ &$60.28\pm 2.85$ & $85.56\pm 1.57$ & $51.10\pm 3.36$& \boldmath$90.31\pm 1.33$ & $86.96\pm 3.33$ & $79.23\pm 1.59$& $78.85\pm 1.15$ & \boldmath$85.39\pm 1.25$ \\ Cutoff 30 &\boldmath $96.29\pm 0.95$ &$42.95\pm 6.29$& $93.06\pm 0.53$ & $32.29\pm 2.81$ &\boldmath$97.17\pm 0.65$& $90.23\pm 4.23$& $78.07\pm 1.54$ & $90.76\pm 0.94$& \boldmath$92.69\pm 0.55$ \\ \hline\hline \end{tabularx} \end{table*} \begin{table*} \caption {CONFUSION MATRIX OF 4 CLASSES FROM 10-FOLD CUMULATIVELY} \label{table:conf_matrix} \begin{tabularx}{\textwidth}{@{\extracolsep{2pt}}lCCCCCCCCCCCCCc@{}} \hline\hline & & \multicolumn{4}{c}{SVM} & \multicolumn{4}{c}{AB-CART} & \multicolumn{4}{c}{DNN}&\\ \cline{3-6} \cline{7-10} \cline{11-14} \multicolumn{2}{c}{Predicted$\rightarrow$} & no & mild & mod & severe & no & mild & mod & severe & no & mild & mod & severe \\ \hline Actual & no & \textbf{56} & 9 & 4 & 1 &\textbf{41} & 22 & 3 & 4 & \textbf{57} & 12 & 1 & 0\\ & mild & 20 & \textbf{26} & 17 & 7 &18 & \textbf{26} & 20 & 6& 11 & \textbf{44} & 12 & 3 \\ & mod & 11 & 21 & \textbf{18} & 20 & 12 & 18 & \textbf{24} & 16 & 10 & 17 & \textbf{35} & 8\\ &severe & 4 & 2 & 14 & \textbf{40} &4 & 6 & 17 & \textbf{33} & 3 & 9 & 12 & \textbf{36}\\ \hline\hline \end{tabularx} \end{table*} \section{Results and Discussion} After performing binary classification using 3 SAHS severity level cutoffs including AHI = 5, 10 and 15 along with the SVM classifiers, the AB-CART classifiers and our main classifier with or DNN approach, the results are shown in Table \ref{table: summary}. For cutoff at AHI = 5, the accuracy of SVM ranges from 76.4\% to 79.38\% (mean $\pm$ standard error, 77.89\% $\pm$ 1.49\%), AB-CART ranges from 75.78\% to 78.54\% (mean $\pm$ standard error, 77.12\% $\pm$ 1.42\%) and our main classifier ranges from 82.38\% to 84.54\% (mean $\pm$ standard error, 83.46\% $\pm$ 1.08\%). For cutoff at AHI = 15, the accuracy of SVM ranges from 77.64\% to 80.82\% (mean $\pm$ standard deviation error, 79.23\% ± 1.59\%), AB-CART ranged from 77.7\% to 80\% (mean $\pm$ standard error, 78.85\% $\pm$ 1.15\%) and our main classifier ranges from 84.14\% to 86.64\% (mean $w\pm$ standard error, 85.39\% $\pm$ 1.25\%). For cutoff at AHI = 30, the accuracy of SVM ranges from 76.53\% to 79.61\% (mean $\pm$ standard error, 78.07\% $\pm$ 1.54\%), AB-CART accuracy ranges from 89.82\% to 91.7\% (mean $\pm$ standard error, 90.76\% ± 0.94\%) and our main classifier ranges from 92.14\% to 93.24\% (mean $\pm$ standard error, 92.69\% $\pm$ 0.55\%). While our DNNs classifiers reached the highest accuracy from all classifiers in every cutoffs and also increased in each of the cutoff, the SVM reached the highest Specificity at AHI = 5 and Sensitivity at AHI = 15 and 30, the AB-CART reached the highest Sensitivity at AHI = 5 and Sensitivity at AHI = 15 and 30. One way repeated measures ANOVA revealed that there were significant difference of mean accuracy among results from three approaches in every cutoffs (AHI=5: \emph{F(2)=2313.822, p$<$0.05}, AHI=15: \emph{F(2)=9.850, p$<$0.05}, AHI=30: \emph{F(2)=50.771, p$<$0.05}). After pairwise comparisons were performed, we found that the accuracies of our DNNs classifiers are significantly higher than others (p$<$0.05). Consequently, we can conclude that our classifiers are able to sustain the sensitivity and specificity while still maintaining the highest accuracy in all cutoffs. Additionally, after the data was balanced in each SAHS level and classified non-linearly into 4 classes, the cumulative confusion matrix of 10 folds are computed as shown in the table for every approaches \ref{table:conf_matrix}. The results from our DNNs classifiers are promising and higher than the others, with the overall accuracy of 63.70\%, while the SVM reached only 51.85\% and the AB-CART reached only 45.93\%. It represents that our DNNs classifier provides a higher diagnostic performance than the other approaches. \section{Conclusion} In summary, we proposed statistical based feature extraction from single channel overnight airflow (AF) signals. There are seventeen features in total. Sets of features had fed into proposed DNNs and classical machine learning (ML) approaches, which are Support Vector Machine (SVM) and Adaboost-Classification and Regression Trees (AB-CART), for comparison. Binary and multiple sleep Apnea-Hypopnea severity classifications had been conducted to demonstrate the performance of our proposed features with DNNs which outperformed classical machine learning techniques. \bibliographystyle{unsrt}
\section{Introduction} \begin{table*} \begin{center} {\small \begin{tabular}{lllll} \toprule type & consistent & en & fi & et \\ \midrule (i) & yes & On + y + sz + kie + wicz & On + y + sz + kie + wicz & On + y + sz + kie + wicz \\ (ii) & yes & gett + ing & saa + mise + ksi & saa + mise + ks \\ & & work + ing & toimi + mise + ksi & toimi + mise + ks \\ (iii) & yes & work time & työ + aja + sta & töö + aja + st \\ \midrule (i) & no & On + y + sz + kie + wicz & Onys + zk + ie + wi + cz & O + nysz + ki + ewicz \\ (ii) & no & get + ting & saami + seksi & saami + seks \\ & & work + ing & toimi + mise + ksi & toimi + miseks \\ (iii) & no & work time & työ + aja + sta & tööajast \\ \bottomrule \end{tabular} } \caption{Example consistent and inconsistent segmentations. \label{tab:consistent}} \end{center} \end{table*} Cognates are words in different languages, which due to a shared etymological origin are represented as identical or nearly identical strings, and also refer to the same or similar concepts. Ideally the cognate pair is similar orthographically, semantically, and distributionally. Care must be taken with ``false friends'', i.e. words with similar string representation but different semantics. Following usage in Natural Language Processing, e.g. \cite{kondrak2001identifying}, we use this broader definition of the term cognate, without placing the same weight on etymological origin as in historical linguistics. Therefore we accept loan words as cognates. In any language pair written in the same alphabet, cognates can be found among names of persons, locations and other proper names. Cognates are more frequent in related languages, such as Finnish and Estonian. These additional cognates are words of any part-of-speech, which happen to have a shared origin. In this work we set out to improve morphological segmentation for multilingual translation systems with one source language and two related target languages. One of the target languages is assumed to be a low-resource language. The motivation for using such a system is to exploit the large resources of a related language in order to improve the quality of translation into the low-resource language. Consistency of the segmentations is important when using subword units in machine translation. We identify three types of consistency in the multilingual translation setting (see examples in Table~\ref{tab:consistent}): (i) The benefit of consistency is most evident when the translated word is an identical cognate between the source and a target language. If the source and target segmentations are consistent, such words can be translated by sequentially copying subwords from source to target. (ii) Language-internal consistency means that when a subword boundary is added, its location corresponds to a true morpheme boundary, and that if some morpheme boundaries are left unsegmented, the choices are consistent between words. This improves the productivity of the subwords and reduces the risk of introducing short, word-internal errors at the subword boundaries. In the example \examp{*saami + miseksi}, choosing the wrong second morph causes the letters \emph{mi} to be accidentally repeated. (iii) When training a multilingual model, a third form of consistency arises between the different target languages. An optimal segmentation would maximize the use of morphemes with cross-lingually similar string representations and meanings, whether they occur in cognate words or elsewhere. We hypothesize that segmentation consistency between target languages enables learning of better generalizing subword representations. This consistency allows contexts seen in the high-resource corpus to fill in for those missing from the low-resource corpus. This should lead to improved translation results, especially for the lower resourced target language. Naïve joint training of a segmentation model, e.g. by training Byte Pair Encoding (BPE) \cite{sennrich2015neural} on the concatenation of the training corpora in different languages, can only address consistency when the cognates are identical (type \emph{i}), or with some luck if the differences occur in the ends of the words. If a single letter changes in the middle of a cognate, consistent subwords that span over the location of the change are found only by chance. In order to encourage stronger consistency, we propose a segmentation model that uses automatically extracted cognates and fuzzy matching between cognate morphs. In this work we also contribute two new features to the OpenNMT translation system: Ensemble decoding, and fine-tuning a pre-trained model using a compatible data set.% \footnote{Our changes are awaiting inclusion in OpenNMT. In the mean time, they are available from \url{https://github.com/Waino/OpenNMT-py/tree/ensemble}} \subsection{Related work} Improving segmentation through multilingual learning has been studied before. \newcite{snyder2008unsupervised} propose an unsupervised, Bayesian method, which only uses parallel phrases as training data. \newcite{wicentowski2004multilingual} present a supervised method, which requires lemmatization. The method of \newcite{naradowsky2011unsupervised} is also unsupervised, utilizing a hidden semi-Markov model, but it requires rich features on the input data. The subtask of cognate extraction has seen much research effort \cite{mitkov2007methods,bloodgood2017using,ciobanu2014automatic}. Most methods are supervised, and/or require rich features. There is also work on cognate identification from historical linguistics perspective \cite{rama2016siamese,kondrak2009identification}, where the aim is to classify which cognate candidates truly share an etymological origin. We propose a language-agnostic, unsupervised method, which doesn't require annotations, lemmatizers, analyzers or parsers. Our method can exploit both monolingual and parallel data, and can use cognates of any part-of-speech. \section{Cognate Morfessor} We introduce a new variant of Morfessor for cross-lingual segmentation.% \footnote{Available from \url{https://github.com/Waino/morfessor-cognates}} It is trained using a bilingual corpus, so that both target languages are trained simultaneously. We allow each language to have its own subword lexicon. In essence, as a Morfessor model consists of a lexicon and the corpus encoded with that lexicon, we now have two separate complete Morfessor sub-models. The two models are linked through the training algorithm. We want the segmentation of non-cognates to tend towards the normal Morfessor Baseline segmentation, but place some additional constraints on how the cognates are segmented. In our first experiments, we only restricted the number of subwords on both sides of the cognate pair to be equal. This criterion was too loose, and we saw many of the longer cognates segmented with both 1-to-N and N-to-1 morpheme correspondences. For example \begin{center} \begin{tabular}{llllllll} ty &+& ö &+& aja &+& sta \\ töö &+& aja &+& s &+& t \\ \end{tabular} \end{center} To further encourage consistency, we included a third component to the model, which encodes the letter edits transforming the subwords of one cognate into the other. Cognate Morfessor is inspired by Allomorfessor \cite{kohonen09clef_lncs,virpioja2010lncs}, which is a variant of Morfessor that includes modeling of allomorphic variation. Simultaneously to learning the segmentations, Allomorfessor learns a lexicon of transformations to convert a morph into one of its allomorphs. Allomorfessor is trained on monolingual data. We implement the new version as an extension of Morfessor Baseline 2.0 \cite{virpioja2013tr}. \subsection{Model} The Morfessor Baseline cost function \cite{creutz02sigphon} \begin{align} \cost(\boldsymbol{\theta}, \boldsymbol{D}) = -\log p(\boldsymbol{\theta}) - \log p(\boldsymbol{D} \,|\, \boldsymbol{\theta}) \end{align} is extended to \begin{align} \cost(\boldsymbol{\theta}, \boldsymbol{D}) = & -\log p(\boldsymbol{\theta}_{1}) -\log p(\boldsymbol{\theta}_{2}) -\log p(\boldsymbol{\theta}_{E}) \nonumber\\ & - \log p(\boldsymbol{D}_{1} \,|\, \boldsymbol{\theta}_{1}) - \log p(\boldsymbol{D}_{2} \,|\, \boldsymbol{\theta}_{2}) \nonumber\\ & - \log p(\boldsymbol{D}_{E} \,|\, \boldsymbol{\theta}_{E}) \label{eq:cost} \end{align} dividing both lexicon and corpus coding costs into three parts: one for each language ($\boldsymbol{\theta}_{1},\boldsymbol{D}_{1}$ and $\boldsymbol{\theta}_{2},\boldsymbol{D}_{2}$) and one for the edits transforming the cognates from one language to the other ($\boldsymbol{\theta}_{E},\boldsymbol{D}_{E}$). The coding is redundant, as one language and the edits would be enough to reconstruct the second language. In the interest of symmetry between target languages, we ignore this redundancy. The intuition is that the changes in spelling between the cognates in a particular language pair is regular. Coding the differences in a way that reduces the cost of making a similar change in another word guides the model towards learning these patterns from the data. The coding of the edits is based on the \newcite{levenshtein1966} algorithm. Let $(w^{a}, w^{b})$ be a cognate pair and its current segmentation $\big((m^{a}_{1}, \mathellipsis, m^{a}_{n}), (m^{b}_{1}, \mathellipsis m^{b}_{n})\big)$. The morphs are paired up sequentially. Note that the restrictions on the search algorithm guarantee that both segmentations contain the same number of morphs, $n$. For a morph pair $(m^{a}_{i}, m^{b}_{i})$, the Levenshtein-minimal set of edits is calculated. Edits that are immediately adjacent to each other are merged. In order to improve the modeling of sound length change, we extend the edit in both languages to include the neighboring unchanged character, if one half of the edit is the empty string $\epsilon$, and the other contains another instance of character representing the sound being lengthened or shortened. This extension encodes a sound lengthening as e.g. 'a$\rightarrow$aa' instead of '$\epsilon\rightarrow$a'. As the edits are cheaper to reuse once added to the edit lexicon, avoiding edits with $\epsilon$ on either side is beneficial to reduce spurious use. Finally, position information is discarded from the edits, leaving only the substrings, separated by a boundary symbol. As an example, the edits found between \examp{yhteenkuuluvuuspolitiikkaa} and \examp{ühtekuuluvuspoliitika} are 'y$\rightarrow$ü', 'een$\rightarrow$e', 'uu$\rightarrow$u', 'ti$\rightarrow$it', and 'kka$\rightarrow$k'. The semi-supervised weighting scheme of \newcite{kohonen2010sigmorphon} can be applied to Cognate Morfessor. A new weighting parameter \emph{edit\_cost\_weight} is added, and multiplicatively applied to both the lexicon and corpus costs of the edits. The training algorithm is an iterative greedy local search very similar to the Morfessor Baseline algorithm. The algorithm finds an approximately minimizing solution to Eq \ref{eq:cost}. The recursive splitting algorithm from Morfessor Baseline is slightly modified. If a non-cognate is being reanalyzed, the normal algorithm is followed. Cognates are reanalyzed together. Recursive splitting is applied, with the restriction that if a morph in one language is split, then the corresponding cognate morph in the other language must be split as well. The Cartesian product of all combinations of valid split points for both languages is tried, and the pair of splits minimizing the cost function is selected, unless not splitting results in even lower cost. \section{Extracting cognates from parallel data} Finnish--Estonian cognates were automatically extracted from the shared task training data. As we needed a Finnish--Estonian parallel data set, we generated one by triangulation from the English--Finnish and English--Estonian parallel data. This resulted in a set of \numprint{679252} sentence pairs (ca 12 million tokens per language). FastAlign \cite{fastalign} was used for word alignment in both directions, after which the alignments were symmetrized using the \emph{grow-diag-final-and} heuristic. All aligned word pairs were extracted based on the symmetrized alignment. Words containing punctuation, and pairs aligned to each other fewer than 2 times were removed. The list of word pairs was filtered based on Levenshtein distance. If either of the words consisted of 4 or fewer characters, an exact match was required. Otherwise, a Levenshtein distance up to a third of the mean of the lengths, rounding up, was allowed. This procedure resulted in a list of \numprint{40472} cognate pairs. The list contains words participating in multiple cognate pairs. Cognate Morfessor is only able to link a word to a single cognate. We filtered the list, keeping only the pairing to the most frequent cognate, which reduces the list to \numprint{22226} pairs. The word alignment provides a check for semantic similarity in the form of translational equivalence. Even though the word alignment may produce some errors, accidentally segmenting false friends consistently should not be problematic. \section{Data} After filtering, we have 9 million multilingual sentence pairs in total. 6.3M of this is English--Finnish, of which 2.2M is parallel data, and 4.1M is synthetic backtranslated data. Of the 2.8M total English--Estonian, 1M is parallel and 1.8M backtranslated. The sentences backtranslated from Finnish were from the news.2016.fi corpus, translated with a PB-SMT model, trained with WMT16 constrained settings. The backtranslation from Estonian was freshly made with a BPE-based system similar to our baseline system, trained on the WMT18 data. The sentences were selected from the news.20\{14-17\}.et corpora, using a language model filtering technique. \subsection{Preprocessing} The preprocessing pipeline consisted of filtering by length% \footnote{1--100 tokens, 3--600 chars, $\leq$ 50 chars$/$token.} and ratio of lengths% \footnote{Requiring ratio 0.5--2.0, if either side $>$ 10 chars.}, fixing encoding problems, normalizing punctuation, removing of rare characters% \footnote{$<10$ occurrences}, deduplication, tokenizing, truecasing, rule-based filtering of noise, normalization of contractions, and filtering of noise using a language model. The language model based noise filtering was performed by training a character-based deep LSTM language model on the in-domain monolingual data, using it to score each target sentence in the parallel data, and removal of sentences with perplexity per character above a manually picked threshold. A lenient threshold% \footnote{96\% of the data was retained.} was selected in order to filter noise, rather than for aiming for domain adaptation. The same process was applied to filter the Estonian news data for backtranslation. Our cognate segmentation resulted in a target vocabulary of \numprint{42386} subwords for Estonian and \numprint{46930} subwords for Finnish, resulting in \numprint{64396} subwords when combined. For segmentation of the English source, a separate Morfessor Baseline model was trained. To ensure consistency between source and target segmentations, we used the segmentation of the Cognate Morfessor model for any English words that were also present in the target side corpora. The source vocabulary consisted of \numprint{61644} subwords. As a baseline segmentation, we train a shared 100k subword vocabulary using BPE. To produce a balanced multilingual segmentation, the following procedure was used: First, word counts were calculated individually for English and each of the target languages Finnish and Estonian. The counts were normalized to equalize the sum of the counts for each language. This avoided imbalance in the amount of data skewing the segmentation in favor of some language. BPE was trained on the balanced counts. Segmentation boundaries around hyphens were forced, overriding the BPE. Multilingual translation with target-language tag was done following \cite{johnson2016google}. A pseudo-word, e.g. {\sc<to\_et>} to mark Estonian as the target language, was prefixed to each paired English source sentence. \setlength{\tabcolsep}{0.3em} \begin{table} \begin{center} {\small \begin{tabular}{rclr rclr rclr} \toprule $\epsilon$&$\rightarrow$&n & 27919 & g &$\rightarrow$& k & 3000 & il & $\rightarrow$ & $\epsilon$ & 2077 \\ $\epsilon$&$\rightarrow$&a & 17082 & ü &$\rightarrow$& y & 2979 & m & $\rightarrow$ & mm & 2016 \\ $\epsilon$&$\rightarrow$&i & 15725 & oo &$\rightarrow$& o & 2790 & s & $\rightarrow$ & n & 2005 \\ d &$\rightarrow$&t & 12599 & t &$\rightarrow$& a & 2674 & ee & $\rightarrow$ & e & 1950 \\ l &$\rightarrow$&ll & 5236 & $\epsilon$&$\rightarrow$& k & 2583 & i & $\rightarrow$ & $\epsilon$ & 1889 \\ $\epsilon$&$\rightarrow$&ä & 4437 & aa &$\rightarrow$& a & 2536 & $\epsilon$ & $\rightarrow$ & e & 1803 \\ s &$\rightarrow$&ssa & 3907 & õ &$\rightarrow$& o & 2493 & u & $\rightarrow$ & o & 1724 \\ t &$\rightarrow$&tt & 3863 & a &$\rightarrow$& ä & 2479 & $\epsilon$ & $\rightarrow$ & d & 1496 \\ o &$\rightarrow$&u & 3768 & s &$\rightarrow$& $\epsilon$ & 2173 & il & $\rightarrow$ & t & 1486 \\ e &$\rightarrow$&i & 3182 & t &$\rightarrow$& $\epsilon$ & 2158 & d & $\rightarrow$ & $\epsilon$ & 1433 \\ \bottomrule \end{tabular} } \caption{30 most frequent edits learned by the model. The direction is Estonian$\rightarrow$Finnish. The numbers indicate how many times the edit was applied in the morph lexicon. $\epsilon$ indicates the empty string. \label{tab:edits}} \end{center} \end{table} \setlength{\tabcolsep}{0.5em} \section{NMT system} We use the OpenNMT-py \cite{opennmt} implementation of the Transformer. \subsection{Transformer} The Transformer architecture \cite{vaswani2017attention} relies fully on attention mechanisms, without need for recurrence or convolution. A Transformer is a deep stack of layers, consisting of two types of sub-layer: multi-head (MH) attention (Att) sub-layers and feed-forward (FF) sub-layers: \begin{align} \attention(Q, K, V) & = \softmax(\frac{QK^T}{\sqrt{d_{k}}})V \nonumber\\ a_{i} & = \attention(QW_{i}^{Q}, KW_{i}^{K}, VW_{i}^{V}) \nonumber\\ \multihead(Q, K, V) & = [a_{1};\mathellipsis;a_{h}]W^{O} \nonumber\\ \feedforward(x) & = \max(0, xW_{1} + b_{1})W_{2} + b_{2} \end{align} where $Q$ is the input query, $K$ is the key, and $V$ the attended values. Each sub-layer is individually wrapped in a residual connection and layer normalization. When used in translation, Transformer layers are stacked into an encoder-decoder structure. In the encoder, the layer consists of a self-attention sub-layer followed by a FF sub-layer. In self-attention, the output of the previous layer is used as queries, keys and values $Q = K = V$. In the decoder, a third context attention sub-layer is inserted between the self-attention and the FF. In context attention, $Q$ is again the output of the previous layer, but $K = V$ is the output of the encoder stack. The decoder self-attention is also masked to prevent access to future information. Sinusoidal position encoding makes word order information available. \subsection{Training} \begin{table} \begin{center} {\small \begin{tabular}{lrr} \toprule & chrF-1.0 & BLEU\% \\ \sc{en-et} & dev & dev \\ \midrule BPE & 56.52 & 17.93 \\ monolingual & 53.44 & 15.82 \\ Cognate Morfessor & 57.05 & 18.40 \\ \quad +finetuned & 57.23 & 18.45 \\ \quad\quad +ensemble-of-5 & \fontseries{b}\selectfont 57.75 & \fontseries{b}\selectfont 19.09 \\ \quad\quad +ensemble-of-3 & 57.64 & 18.96 \\ \quad +linked embeddings & 56.20 & 17.48 \\ \quad $-$LM filtering & 52.94 & 14.65 \\ \quad 6+6 layers & 57.35 & 18.84 \\ \bottomrule \end{tabular} } \caption{Development set results for English--Estonian. character-F and BLEU scores in percentages. $+$/$-$ stands for adding/removing a component. Multiple modifications are indicated by increasing the indentation. \label{tab:etresults}} \end{center} \end{table} \begin{table*} \begin{center} {\small \begin{tabular}{lrrrrrrrr} \toprule & \multicolumn{4}{c}{chrF-1.0} & \multicolumn{4}{c}{BLEU\%} \\ \cmidrule(lr){2-5} \cmidrule(lr){6-9} \sc{en-fi} & nt2015 & nt2016 & nt2017 & nt2017AB & nt2015 & nt2016 & nt2017 & nt2017AB \\ \midrule BPE & 58.59 & 59.76 & 62.00 & 63.06 & 21.09 & 21.04 & 23.49 & 26.55 \\ monolingual & 57.94 & 59.11 & 61.33 & 62.41 & 20.87 & 20.70 & 23.11 & 26.12 \\ Cognate Morfessor & 58.18 & 59.81 & 62.15 & 63.24 & 20.73 & 21.18 & 23.37 & 26.26 \\ \quad +finetuned & 58.48 & 59.89 & 62.17 & 63.28 & 21.08 & 21.41 & 23.45 & 26.52 \\ \quad\quad +ensemble-of-8 & \fontseries{b}\selectfont 59.07 & \fontseries{b}\selectfont 60.69 & \fontseries{b}\selectfont 62.94 & \fontseries{b}\selectfont 64.07 & \fontseries{b}\selectfont 21.50 & \fontseries{b}\selectfont 22.34 & \fontseries{b}\selectfont 24.59 & \fontseries{b}\selectfont 27.55 \\ \quad $-$LM filtering & 58.19 & 59.39 & 61.78 & 62.82 & 20.62 & 20.77 & 23.38 & 26.36 \\ \quad +linked embeddings & 57.79 & 59.45 & 61.52 & 62.58 & 19.95 & 20.84 & 22.70 & 25.69 \\ \quad 6+6 layers & 58.68 & 60.26 & 62.37 & 63.52 & 21.05 & 21.81 & 23.93 & 27.08 \\ \bottomrule \end{tabular} } \caption{Results for English--Finnish. character-F and BLEU scores in percentages. $+$/$-$ stands for adding/removing a component. Newstest is abbreviated nt. Both references are used in nt2017AB. \label{tab:firesults}} \end{center} \end{table*} Based on some preliminary results, we decided to reduce the number of layers to 4 in both encoder and decoder; later we found that the decision was based on too short training time. Other parameters were chosen following the OpenNMT FAQ \cite{FAQ}: 512-dimensional word embeddings and hidden states, dropout 0.1, batch size 4096 tokens, label smoothing 0.1, Adam with initial learning rate 2 and $\beta_{2}$ 0.998. Fine-tuning for each target language was performed by continuing training of a multilingual model. Only the appropriate monolingual subset of the training data was used in this phase. The data was still prefixed for target language as during multilingual training. No vocabulary pruning was performed. In our ensemble decoding procedure, the predictions of 3--8 models are combined by averaging after the softmax layer. Best results are achieved when the models have been independently trained. However, we also try combinations where a second copy of a model is further trained with a different configuration (monolingual finetuning). We experimented with partially linking the embeddings of cognate morphs. In this experiment, we used morph embeddings concatenated from two parts: a part consisting of normal embedding of the morph, and a part that was shared between both halves of the cognate morph pair. Non-cognate morphs used an unlinked embedding also for the second part. After concatenation, the linked embeddings have the same size as the baseline embeddings. We evaluate the systems with cased BLEU using the mteval-v13a.pl script, and characterF \cite{popovic2015chrf} with $\beta$ set to 1.0. The latter was used for tuning. \section{Results} Based on preliminary experiments, the Morfessor corpus cost weight $\alpha$ was set to 0.01, and the edit cost weight was set to 10. The most frequent edits are shown in Table~\ref{tab:edits}. Table~\ref{tab:etresults} shows the development set results for Estonian. Table~\ref{tab:firesults} shows results for previous year's test sets for Finnish. The tables show our main system and the two baselines: a multilingual model using joint BPE segmentation, and a monolingual model using Morfessor Baseline. Cognate Morfessor outperforms the comparable BPE system according to both measures for Estonian, and according to chrF-1.0 for Finnish. For Finnish, results measured with BLEU vary between test sets. The cross-lingual segmentation is particularly beneficial for Estonian. In the monolingual experiment, the cross-lingual segmentations are replaced with monolingual Morfessor Baseline segmentation, and only the data sets of one language pair at a time is used. These results show that even the higher resourced language, Finnish, benefits from multilingual training. The indented rows show variant configurations of our main system. Monolingual finetuning consistently improves results for both languages. For Estonian, we have two ensemble configurations: one combining 3 monolingually finetuned independent runs, and one combining 5 monolingually finetuned savepoints from 4 independent runs. Selection of savepoints for the ensemble was based on development set chrF-1. In the ensemble-of-5, one training run contributed two models: starting finetuning from epochs 14 and 21 of the multi-lingual training. The submitted system is the ensemble-of-3, as the ensemble-of-5 finished training after the deadline. For Finnish, we use an ensemble of 4 finetuned and 4 non-finetuned savepoints from 4 independent runs. To see if further cross-lingual learning could be achieved, we performed an unsuccessful experiment with linked embeddings. It appears that explicit linking does not improve the morph representations over what the translation model is already capable of learning. After the deadline, we trained a single model with 6 layers in both the encoder and decoder. This configuration consistently improves results compared to the submitted system. All the variant configurations (ensemble, finetuning, LM filtering, linked embeddings, number of layers) used with Cognate Morfessor are compatible with each other. We did not not explore the combinations in this work, except for combining finetuning with ensembleing: all of the models in the Estonian ensembles, and 4 of the models in the Finnish ensemble are finetuned. All the variant configurations except for linked embeddings could also be used with BPE. \section{Conclusions and future work} The translation system trained using the Cognate Morfessor segmentation outperforms the baselines for both languages. The benefit is larger for Estonian, the language with less data in this experiment. One downside is that, due to the model structure, Cognate Morfessor is currently not applicable to more than two target languages. Cognate Morfessor itself learns to model the frequent edits between cognate pairs. However, in the preprocessing cognate extraction step of this work, we used unweighted Levenshtein distance, which does not distinguish edits by frequency. In future work, weighted or graphonological Levenshtein distance could be applied \cite{babych2016graphonological}. \section*{Acknowledgments} This research has been supported by the European Union's Horizon 2020 Research and Innovation Programme under Grant Agreement No 780069. Computer resources within the Aalto University School of Science ``Science-IT'' project were used. We wish to thank Peter Smit for groundlaying work that led to Cognate Morfessor. \bibliographystyle{acl_natbib_nourl}
\section{Introduction} \label{sec:intro} The governing equations we use to model complex phenomena are often approximate. For example, we may not know exactly the initial and/or boundary conditions necessary to integrate these equations. Other parameters entering these equations can also be uncertain, either because we are not sure of the model itself or because these parameters may vary from situations to situations in a way that is difficult to predict in detail. The question then becomes whether we can quantify how our imperfect knowledge of the system's parameters impact its behavior. This question lends itself naturally to a probabilistic formulation. Consider for example the case of a dynamical system whose state at time~$t$ can be specified by some $u(t)$ which can be a vector or a field and satisfies \begin{equation} \label{eq:detdyn} \partial_t u = b(u,\vartheta), \qquad u(t=0) = u_0(\vartheta). \end{equation} Here $b(u,\vartheta)$ is a given vector field and $\vartheta$ denotes the set of parameters we are uncertain of. Assuming that these parameters take value in some set $\Omega$, which can again be finite or infinite dimensional, it is then natural to equip $\Omega$ with a probability measure $\mu$ to quantify our uncertainty. This makes $\vartheta$ random, and therefore the solution to~\eqref{eq:detdyn} becomes a stochastic process. Denoting it by $u(\cdot,\vartheta)$, we can ask questions about the statistics of this process. For example, if $f(u)$ is a scalar valued observable, we can define \begin{equation} \label{eq:expectations} P_T(z) \equiv \mathbb{P} \left(f(u(T,\vartheta))\ge z\right), \qquad z\in \mathbb{R}\,, \end{equation} where $\mathbb{P}$ denotes the probability over~$\mu$ and $T>0$ is some observation time. The probability \eqref{eq:expectations} is useful e.g.~in the context of certification problem where, given $z\in \mathbb{R}$ and $\epsilon>0$ (typically $z$ large and $\epsilon$ small), we wish to verify that $P_T(z)\le \epsilon$. Other quantities of interest include \begin{equation} \label{eq:3} \mathbb{P} \left(\int_0^T f(u(t,\vartheta)) dt\ge z\right), \qquad \mathbb{P} \left(\sup_{0\le t \le T} f(u(t,\vartheta)) \ge z\right), \qquad \text{etc.} \end{equation} The numerical estimation of~\eqref{eq:expectations} or~\eqref{eq:3} can be performed by Monte Carlo sampling methods: generate $N$ independent realizations of $\vartheta$, for each evaluate $f(u(T,\vartheta))$ via integration of~\eqref{eq:detdyn}, and compute the fraction of these realizations for which $f(u(T,\vartheta))\ge z$. As $N\to\infty$, this fraction will converge to $P_T(z)$. This direct approach is not effective when $P_T(z)$ is small, however, since the relative error of the estimator just described is $\sqrt{(1-P_T(z))/(NP_T(z))} \sim 1/\sqrt{NP_T(z)}$. This means that in order to get an estimate accurate to order $\delta \ll1$, we need to use $N=O\left(\delta^{-2}P^{-1}_T(z)\right)$ samples, which can become prohibitively expensive as $P_T(z)$ gets smaller. This is problematic since it excludes from consideration events that are rare but may nonetheless have dramatic consequences. Similar issues arise if we replace~\eqref{eq:detdyn} by some time independent equation like \begin{equation} \label{eq:detndyn} 0 = b(u,\vartheta), \end{equation} where $b(\cdot, \vartheta)$ is some function of $u$ and possibly its derivatives and \eqref{eq:detndyn} is supplemented with boundary conditions that may also depend on the random parameter~$\vartheta$. The solution to~\eqref{eq:detndyn} defines a complicated map $u(\vartheta)$, and given a scalar valued observable $f(u)$, the estimation of \begin{equation} \label{eq:expectationsndyn} \mathbb{P} \left(f(u(\vartheta))\ge z\right), \qquad z\in \mathbb{R} \end{equation} will again be challenging when this probability is small, i.e.~when the event $f(u(\vartheta))\ge z $ is rare. In these situations alternative methods such as those proposed e.g. in~\cite{glasserman1999multilevel,juneja2006rare,% cerou2007adaptive,giardina2011simulating,tailleur2007probing,VandenEijnden:2012ef,% farazmand-sapsis:2017,ragone2017computation} must be used to estimate~\eqref{eq:expectations},~\eqref{eq:3}, or~\eqref{eq:expectationsndyn}. The approach we introduce in this paper builds on earlier results found in~\cite{PNAS2018rogue} and uses large deviation theory (LDT)~\cite{dembo2010large,varadhan2016large} as a tool: we show that, if in~\eqref{eq:expectations} $P_T(z)\to0$ as $z\to\infty$, then under some additional assumptions we have \begin{equation} \label{eq:2} P_T(z) \asymp \exp\left( -\min_{\theta\in \Omega(z)}\, I(\theta) \right) \qquad\text{where} \qquad \Omega(z) = \left\{\theta : f(u(T,\theta))\ge z\right\} \subseteq \Omega. \end{equation} Here $\asymp$ indicates that the ratio of logarithms of both sides tends to 1 as $z\to\infty$ and we defined \begin{equation} \label{eq:6bb} I(\theta) = \max_{\eta} \left( \<\eta, \theta\> - S(\eta) \right) , \end{equation} where $\<\cdot, \cdot\>$ is a suitable inner product on $\Omega$ and $S(\eta)$ is the cumulant generating function of $\vartheta$: \begin{equation} \label{eq:5bb} S(\eta) = \log \mathbb{E}}\def\mathbb{P}{\mathbb{P} e^{\<\eta, \vartheta\>} = \log \int_\Omega e^{\<\eta, \theta\>}d\mu(\theta)\,. \end{equation} We will also show that the minimizer of $I(\theta)$ in $\Omega(z)$, i.e. \begin{equation} \label{eq:2gbb} \theta^\star(z) = \argmin_{\theta\in \Omega(z)} I(\theta)\,, \end{equation} is the point of maximum likelihood in $\Omega(z)$. The most likely way the event $\left\{f(u(T,\vartheta))\ge z\right\}$ occurs is when $\vartheta = \theta^\star(z)$. Similar estimates hold for~\eqref{eq:3} and~\eqref{eq:expectationsndyn} upon straightforward redefinition of the set $\Omega(z)$ upon which the optimization is performed. Establishing the large deviation principle (LDP) in~\eqref{eq:2} is one of the objectives of this paper. As we will see in Sec.~\ref{sec:LDTmethod}, this can be done by proving that $\theta^\star(z) $ is a dominating point in $\Omega(z)$, building on results derived e.g. in~\cite{Borozkov:1965, Ney:1983iz, broniatowski1995tauberian,Iltis:2000vp} that provide us with a framework to justify the saddle-point approximations often used in physics~\cite{jensen1995saddlepoint,frisch1997extreme}. Eq.~\eqref{eq:2} is a somewhat unusual LDP however because there is no small (or large) parameter associated to the random variable $\vartheta$: rather we play with the variable $z$ being large. More precisely, instead of scaling $\vartheta$ so that events with a finite $z$ become rare, we keep $\vartheta$ as is and look at rare events that occur in the tail of the distribution when $z\gg1$. As a result, the standard approach developed in~\cite{Borozkov:1965, Ney:1983iz, Iltis:2000vp} must be adapted. Of course, both viewpoints are equivalent up to some appropriate rescaling of the variables $\vartheta$ and $z$, but this rescaling involves the so-called speed of the LDP, which is unknown to us \textit{a~priori}. The formulation we adopt can be viewed as a way to estimate this speed. When~\eqref{eq:2} holds, we can reduce the evaluation of $P_T(z)$ to the minimization problem in~\eqref{eq:2gbb}, and a second objective here is to design numerical tools to perform this minimization. As we will see in Sec.~\ref{sec:optimization}, this can be done by adapting techniques used in optimal control~\cite{troltzsch2010optimal,borzi2011computational}. We will also illustrate these tools on two examples in Sec. ~\ref{sec:applications}: The first one is a model for an elastic rod with a random elasticity coefficient. The rod gets pulled from one end with a given forcing protocol, and the response depends nonlinearly on the elasticity coefficient. The LDP can be used here to infer the probability of atypically large extensions of the rod. The second application deals with the nonlinear Schr\"odinger equation (NLSE) in nonlinear fiber optics, in the context of what is known as integrable turbulence, and study the problem of the onset of rogue waves out of a bath of random waves taken as initial condition for NLSE. \section{Large deviation principle} \label{sec:LDTmethod} Here we establish~\eqref{eq:2}, using background material that can be e.g.~found in~\cite{Borozkov:1965,Ney:1983iz,Iltis:2000vp}. For simplicity, we will restrict ourselves to situations where $\vartheta$ is finite dimensional, i.e.~we assume that $\vartheta \in \Omega \subseteq \mathbb{R}^M$ with $M\in \mathbb{N}}\def\RR{\mathbb{R}}\def\ZZ{\mathbb{Z}$. In this case we can also assume that the inner product $\< \cdot,\cdot\>$ appearing in~\eqref{eq:6bb} and~\eqref{eq:5bb} is the standard Euclidean inner product on $\mathbb{R}^M$. Under appropriate assumptions, the results below will hold also in the infinite-dimensional set-up, when $\vartheta$ is a random field, but the arguments to establish them will require generalization (see e.g.~\cite{Einmahl:1996cg,kuelbs2000large} for results in infinite dimension). To treat the problems in~\eqref{eq:expectations},~\eqref{eq:3} and~\eqref{eq:expectationsndyn} on the same footing we also define the map $F:\Omega \to\mathbb{R}$ via \begin{equation} \label{eq:1} \begin{aligned} &F(\theta) = f(u(T,\theta)), \qquad &\text{for~\eqref{eq:expectations}} \\ & F(\theta) = \int_0^T f(u(T,\theta))\, dt, \quad\text{or}\quad F(\theta) = \sup_{0\le t\le T} f(u(T,\theta)), &\text{for~\eqref{eq:3}}\\ &F(\theta) = f(u(\theta)) &\text{for~\eqref{eq:expectationsndyn}} \end{aligned} \end{equation} so that we can recast these probabilities into \begin{equation} \label{eq:1b} P(z) = \mathbb{P}(F}%{\mathcal{F}(\vartheta) \ge z ) = \mu(\Omega(z)) \qquad \text{where} \qquad \Omega(z)= \{ \theta \, : \, F}%{\mathcal{F}(\theta)\ge z\}\,. \end{equation} To proceed, we start by making two assumptions: \begin{assumption} \label{th:as1} The map $F$ is continuously differentiable, and such that $|\nabla F(\theta)|\ge K >0$ for all $\theta\in \Omega$. \end{assumption} \begin{assumption} \label{th:as3} The measure $\mu$ is such that (this is~\eqref{eq:5bb}) \begin{equation} \label{eq:5b} S(\eta) = \log \mathbb{E}}\def\mathbb{P}{\mathbb{P} e^{\<\eta, \vartheta\>} = \log \int_\Omega e^{\<\eta, \theta\>}d\mu(\theta) \end{equation} exists for all $\eta\in \mathbb{R}^M$ and defines a differentiable function $S:\mathbb{R}^M \to \mathbb{R}$. \end{assumption} \noindent Ultimately, Assumption~\ref{th:as1} is about the specifics of the governing equation in~\eqref{eq:detdyn} or~\eqref{eq:detndyn} and the observable $f$: since the field $u$ is typically a complicated function of $\vartheta$, establishing the conditions under which this assumption holds will have to be done on a case-by-case basis. Note that it guarantees that the set $\Omega(z)$ is simply connected with a boundary that is $C^1$ for all $z\in \mathbb{R}$, with inward pointing unit normal at $\theta(z) \in \partial \Omega(z)$ given by $\hat n (z)= \nabla F(\theta(z))/|\nabla F(\theta(z))|$. We could relax the constraint $|\nabla F(\theta)|>0$, and allow e.g.~for the sets $\Omega(z)$ to have several connected components (the number of which could depend on $z$), but this requires to modify the argument below. Assumption~\ref{th:as3} allows us to introduce the tilted measure \begin{equation} \label{eq:21} d\mu_\eta(\theta) = \frac{e^{\<\eta, \theta\>} d\mu(\theta) }{\int_\Omega e^{\<\eta, \theta\>} d\mu(\theta)} = e^{\<\eta, \theta\>-S(\eta)} d\mu(\theta)\,. \end{equation} It is easy to see that the mean of $\mu_\eta$ is shifted compared to that of $\mu$. A simple calculation shows that \begin{equation} \label{eq:22} \int_\Omega \theta \, d\mu_\eta(\theta) = \nabla S(\eta)\,, \end{equation} and this will allow us to pick $\eta$ such that the mean of $\mu_\eta$ is precisely at the point minimizing $I(\theta)$ in $\Omega(z)$. Note that \begin{equation} \label{eq:28} \Omega(z+\delta) \subseteq \Omega(z) \qquad \forall z\in\mathbb{R},\delta\ge0\,, \end{equation} and to establish~\eqref{eq:2} we will find conditions such that (i) $\mu(\Omega(z))$ decreases fast with~$z$ and (ii) this probability is dominated by a small region around a single point on $\partial \Omega(z)$. This will require us to make additional assumptions on the geometry of $\Omega(z)$ that we discuss next in connection with properties of the rate function $I(\theta)$ defined in~\eqref{eq:6bb}. Letting \begin{equation} \label{eq:2gb} \theta^\star(z) = \argmin_{\theta\in \Omega(z)} I(\theta)\,, \end{equation} we first make: \begin{assumption} \label{th:as4} There exists a finite $z_0$ such that, $\forall z\ge z_0$, $\theta^\star:[z_0,\infty) \to \Omega$ is continuously differentiable and $I(\theta^\star(\cdot))$ is strictly increasing with $z$ with \begin{equation} \label{eq:32c} I(\theta^\star(z))\to \infty \quad \text{and} \quad |\nabla I(\theta^\star(z))|\ge K >0 \quad \text{as}\quad z\to\infty. \end{equation} \end{assumption} \noindent This assumption implies that $\theta^\star(z) \in \partial \Omega(z)$ for $z>z_0$, i.e.~we can replace~\eqref{eq:2gb} with \begin{equation} \label{eq:2g} \theta^\star(z) = \argmin_{\theta\in \partial\Omega(z)} I(\theta)\,. \end{equation} The Euler Lagrange equation for~\eqref{eq:2g} is \begin{equation} \label{eq:25} \nabla I(\theta^\star(z)) = \lambda \nabla F(\theta^\star(z)) \end{equation} for some Lagrange multiplier $\lambda$. Since by definition both $S$ and $I$ are convex functions, by the involution property of the Legendre transform we have \begin{equation} \label{eq:6inv} S(\eta) = \max_{\theta} \left( \<\eta, \theta\> - I(\theta) \right)\,, \end{equation} and this maximum is achieved at the solution of \begin{equation} \label{eq:5} \eta = \nabla I(\theta) \end{equation} in $\theta$. Therefore if we define $\eta^\star(z)$ via \begin{equation} \label{eq:7dual} \eta^\star(z) = \nabla I(\theta^\star(z)) \end{equation} the mean of $\mu_{\eta^\star(z)}$ is $\theta^\star(z)$. From~\eqref{eq:6inv} this also implies that \begin{equation} \label{eq:27} \<\eta^\star(z), \theta^\star(z)\> - S(\eta^\star(z)) = I(\theta^\star(z))\,, \end{equation} which gives the following exact representation formula for $\mu(\Omega(z))$ \begin{equation} \label{eq:33} \begin{aligned} \mu(\Omega(z)) & = \int _{\Omega(z) } e^{S(\eta^\star(z))- \<\eta^\star(z), \theta\> } d\mu_{\eta^\star(z)}(\theta) \\ & = e^{-I(\theta^\star(z))}\int _{\Omega(z) } e^{- \<\eta^\star(z), (\theta-\theta^\star(z))\> } d\mu_{\eta^\star(z)}(\theta)\,. \end{aligned} \end{equation} To proceed further we need to make some assumptions about $\Omega(z)$. First: \begin{assumption} \label{th:as5} For all $z\ge z_0$, the set $\Omega(z)$ is contained in the half-space whose boundary is tangent to $\Omega(z)$ at $\theta= \theta^\star(z)$, i.e. \begin{equation} \label{eq:1h} \Omega(z) \subseteq \mathcal{H}(z) = \left\{ \theta \ : \< \hat n^\star(z), \theta- \theta^\star(z)\> \ge0\right\}, \end{equation} where $\hat n^\star (z)= \nabla F(\theta^\star(z))/|\nabla F(\theta^\star(z))|$ denotes the inward pointing unit normal to $\partial \Omega(z)$ at $\theta^\star(z)$. \end{assumption} \noindent In the terminology of Ney\cite{Ney:1983iz}, it means that $\theta^{\star}(z)$ is a dominating point in $\Omega(z)$. If we combine~\eqref{eq:25} and \eqref{eq:7dual} we deduce that \begin{equation} \label{eq:30} \frac{\eta^\star (z)}{|\eta^\star(z)|} = \frac{\nabla F(\theta^\star(z))}{|\nabla F(\theta^\star(z))|} = \hat n^\star(z) \end{equation} and as a result we can use Fubini's theorem to express \eqref{eq:33} as \begin{equation} \label{eq:4b} \begin{aligned} \mu(\Omega(z)) & = e^{-I(\theta^\star(z))}\int_0^\infty e^{-|\eta^\star(z)| s} |\eta^\star(z)| G(z,s)\,ds\, \end{aligned} \end{equation} Here we defined \begin{equation} \label{eq:10b} G(z,s) = \mu_{\eta^\star(z)}\left(\Omega(z)\setminus \mathcal{H} (z,s)\right), \end{equation} with \begin{equation} \label{eq:9b} \mathcal{H} (z,s) = \left\{ \theta \ : \ \<\hat n^\star(z), (\theta - \theta^\star(z) - \hat n^\star(z) s)\> \ge 0\right\}\,. \end{equation} Note that in~\eqref{eq:4b} the lower limit of the integral is at $s=0$ by Assumption~\ref{th:as5}. Since by definition we have \begin{equation} \label{eq:6} \forall s>0 \ : \ G(z,s) \in (0,1), \qquad \forall s,s'>0, \ s'>s \ : \ G(z,s')>G(z,s), \qquad \lim_{s\to0^+} G(z,s) = 0\,, \end{equation} from \eqref{eq:4b} we obtain the upper bound \begin{equation} \label{eq:7} \mu(\Omega(z)) \le e^{-I(\theta^\star(z))}\int_0^\infty e^{-|\eta^\star(z)| s} |\eta^\star(z)| ds = e^{-I(\theta^\star(z))}\,, \end{equation} which implies \begin{equation} \label{eq:10} \frac{\log \mu(\Omega(z))}{I(\theta^\star(z))} \le -1\,. \end{equation} To get a matching lower bound notice that for all $s_1>0$ we have \begin{equation} \label{eq:9} \begin{aligned} \mu(\Omega(z)) & \ge e^{-I(\theta^\star(z))}\int_0^{s_1} e^{-|\eta^\star(z)| s} |\eta^\star(z)| G(z,s) ds\\ & \ge e^{-I(\theta^\star(z))} G(z,s_1)\left(1-e^{-|\eta^\star(z)| s_1} \right)\\ & \ge e^{-I(\theta^\star(z))} G(z,s_1)\frac{|\eta^\star(z)| s_1}{1+|\eta^\star(z)| s_1}\,. \end{aligned} \end{equation} Therefore if we make: \begin{assumption} \label{th:as6} There exists $s_1>0$ such that % \begin{equation}\label{eq:10ass} \lim_{z\to\infty} \frac{\log G(z, s_1) }{I(\theta^\star(z))} = 0, \end{equation} \end{assumption} \noindent for this $s_1$ we have (using also Assumption~\ref{th:as4} that guarantees that $|\eta^{\star}(z)|\ge K>0$) \begin{equation} \label{eq:9log} \begin{aligned} \frac{\log\mu(\Omega(z))}{I(\theta^\star(z))} & \ge -1 +\frac{\log G(z, s_1) + \log \left( |\eta^\star(z)| s_1\right) -\log \left( 1+|\eta^\star(z)| s_1\right) }{I(\theta^\star(z))}\\ & = -1 +\frac{\log G(z, s_1) -\log \left( 1+|\eta^\star(z)|^{-1} s^{-1}_1\right) }{I(\theta^\star(z))}\\ & \to -1 \qquad \text{as \ \ $z\to\infty$}\,. \end{aligned} \end{equation} Combining~\eqref{eq:10} and~\eqref{eq:9log} we finally deduce \begin{theorem}[Large deviation principle]\label{th:1} Under Assumptions~\ref{th:as1}--\ref{th:as6}, the following result holds: \begin{equation} \label{eq:13b} \lim_{z\to\infty} \frac{\log P(z) }{I(\theta^\star(z))} = \lim_{z\to\infty} \frac{\log\mu(\Omega(z)) }{I(\theta^\star(z))} = -1. \end{equation} \end{theorem} \noindent Note that \eqref{eq:13b} is just a rephrasing of~\eqref{eq:2}. It is useful to comment on the assumptions on $\Omega(z)$ that lead to Theorem~\ref{th:1}. Assumption~\ref{th:as4} states that the event $\{F(\vartheta) \ge z\}$ becomes rare as $z\to\infty$, which is clearly necessary for an LDP to apply. Assumption~\ref{th:as5} guarantees that all regions in $\Omega(z)$ remain much more unlikely than $\theta^\star(z)$: this assumption can be relaxed, but at the price of having to analyze more carefully how $I(\theta)$ behaves on $\partial \Omega(z)$ and exclude that regions with lower likelihood near this boundary accumulate and eventually dominate the probability. Finally, Assumption~\ref{th:as6} is about the shape of the set $\Omega(z)$ near $\theta^\star(z)$. Since the mean of $\mu_{\eta^\star(z)}$ is $\theta^\star(z)$, we know that this measure must have mass in a region around $\theta^\star(z) $ but we need to make sure that this region has sufficient overlap with $\Omega(z)$. For example, if for each $z\ge z_0$ we can insert in $\Omega(z)$ a set that contains $\theta^\star(z)$ on its boundary and is such that its volume remains finite as $z\to\infty$, Assumption~\ref{th:as6} will automatically hold. On the other hand, this assumption could fail for example if $\Omega(z)$ becomes increasingly thin. More discussion about this kind of geometric assumptions can be found e.g.~in~\cite{iltis1995sharp,kuelbs2000large}. It is also interesting to note that~\eqref{eq:4b} offers a way to derive asymptotic expansions for $\mu(\Omega(z))$ more refined than~\eqref{eq:13b} if we assume that: (i) $|\eta^\star (z)|$ grows with $z$, i.e.~we supplement~\eqref{eq:32c} with \begin{equation} \label{eq:32d} |\eta^\star (z)| = |\nabla I(\theta^\star(z))| \to \infty \qquad \text{as \ $z\to\infty$\,;} \end{equation} and (ii) $G(z,s)$ has a specific behavior near $s=0$ as $z\to\infty$. For example, suppose that there is a $C>0$ such that for all $u\ge0$ \begin{equation} \label{eq:12b} G(z,|\eta^\star(z)|^{-1} u)\sim C |\eta^\star(z)|^{-\alpha} u^\alpha \qquad \text{with \ $\alpha>0$\ \ as\ \ $z, |\eta^\star(z)|\to\infty$}\,, \end{equation} where $f(z)\sim g(z)$ indicates that $\lim_{z\to\infty} f(z)/g(z) = 1$. Then we have \begin{equation} \label{eq:13c} \begin{aligned} P(z) = \mu(\Omega(z)) & = e^{-I(\theta^\star(z))}\int_0^\infty e^{-u} G\left(z, |\eta^\star(z)|^{-1} u\right) du\\ &\sim e^{-I(\theta^\star(z))} C |\eta^\star(z)|^{-\alpha}\int_0^\infty e^{-u} u^{\alpha} du\\ & = C \Gamma(\alpha+1) |\eta^\star(z)|^{-\alpha} e^{-I(\theta^\star(z))}\,. \end{aligned} \end{equation} It is interesting to note that both \eqref{eq:4b} and~\eqref{eq:13c} are consistent with $\vartheta|_{\Omega(z)}$ (outcome of the event conditioned on $F(\vartheta)\ge z$) having fluctuations of order $O(|\eta^\star(z)|^{-1})$ away from $\theta^\star(z)$ in the direction parallel to $\eta^\star(z)$. Perpendicular to $\eta^\star(z)$ the fluctuations remain of order $O(1)$ even as $z\to\infty$, but integrating in these perpendicular directions only gives a sub-exponential correction to $\mu(\Omega(z))$. This correction depends on the geometry of the hypersurface $\partial\Omega(z)$ (in particular on its curvature) near $\theta^\star(z)$. This is what is accounted for in~\eqref{eq:13c}, and this picture will be confirmed in the numerical examples below. \subsubsection*{Illustration: Gaussian measure with linear observable} Let us illustrate the LDT optimization in the simple case of a Gaussian random variable $\vartheta$ with mean 0 and covariance $\text{Id}$, taking values $\theta \in \mathbb{R}^N$. If we consider a linear observable \begin{equation} \label{eq:g3} F}%{\mathcal{F}(\theta) = \< b, \theta\>, \qquad b \in \mathbb{R}^N\,, \end{equation} we have \begin{equation} \label{eq:g4} \begin{aligned} \mathbb{P}(\<b, \vartheta\> \ge z ) & = (2\pi)^{-N/2} \int_{\<b, \theta\> \ge z} \exp\left(-\tfrac12 |\theta|^2\right) d\theta\,, \end{aligned} \end{equation} and a direct calculation shows that \begin{equation}\label{eq:g4b} \mathbb{P}(\<b,\theta\>\ge z) = \tfrac12\erfc\left( \frac{z}{\sqrt2 |b|} \right) \sim (2\pi)^{-1/2} |b|z^{-1} \exp\left(-\tfrac12 |b|^{-2} z^2\right) \quad \text{as} \ \ z\to\infty\,. \end{equation} Let us check that the LDP derived above is consistent with this result. Here \begin{equation} \label{eq:11} I(\theta) = \tfrac12 |\theta|^2, \qquad S(\eta) = \tfrac12|\eta|^2. \end{equation} If we minimize $I(\theta)$ subject to $\<\theta,b\>\ge z$, we deduce \begin{equation} \label{eq:12} \theta^\star (z) = z |b|^{-2} b\qquad \text{and}\qquad I(\theta^\star(z)) = \tfrac12 |b|^{-2} z^2. \end{equation} Comparing this result with~\eqref{eq:g4b} we see that it is consistent with the prediction in~\eqref{eq:13b}. We can also test what the theory can say beyond the log-asymptotic estimate. Here, the planar condition corresponding to $\Omega(z) = \mathcal{H}(z)$ is exactly fulfilled by linearity of $F(\theta)= \< b,\theta\>$. We need to estimate $G(z,|\eta^\star(z) |^{-1})$ as $z\to\infty$. From \eqref{eq:7dual} and \eqref{eq:27} we have that \begin{equation} \label{eq:g9a} \eta^\star(z) = \nabla I(\theta^\star(z))=\theta^\star(z) = z |b|^{-2} b, \qquad S(\eta^\star(z)) = \tfrac12 z^2 |b|^{-2} \,, \end{equation} and the tilted measure~\eqref{eq:21} at $\eta=\eta^\star(z)$ reads \begin{equation} \label{eq:14} d\mu_{\eta^\star(z)}(\theta) = (2\pi)^{-N/2} \exp\left( - \tfrac12|\theta|^2 + z b|b|^{-2} \<b,\theta\> - \tfrac12 z^2|b|^{-2} \right) d\theta\,. \end{equation} Using \eqref{eq:g9a}, we obtain \begin{equation}\label{eq:g9b} \begin{aligned} G(z,s) & = \int_{z\le \<b,\theta\>\le z+s} d\mu_{\eta^\star(z)}(\theta)\\ & =(2\pi)^{-1/2} \int_0^{s} \exp\left( - \tfrac12 u^2 \right) du\\ & = \tfrac12\erf\left(\tfrac12\sqrt{2} s\right)\,. \end{aligned} \end{equation} As a result \begin{equation} \label{eq:13} G(z,|\eta^{\star}(z)|^{-1}s) \sim (2\pi)^{-1/2} |\eta^{\star}(z)|^{-1}s = (2\pi)^{-1/2} |b| s z^{-1} \qquad \text{as} \ \ z\to\infty. \end{equation} Comparing with~\eqref{eq:12b}, we see that here $C=(2\pi)^{-1/2}$ and $\alpha=1$. Therefore~\eqref{eq:13c} agrees with~\eqref{eq:g4b} as expected. \section{Numerical aspects} \label{sec:optimization} Here we review how to numerically perform the minimization in~\eqref{eq:2} and thereby estimate $P(z)$ -- the method can be straightforwardly generalized to consider also the minimization associated with the calculation of \eqref{eq:3} or~\eqref{eq:expectationsndyn}. We impose the constraint $f(u(T))\ge z$ by adding a Lagrange multiplier term to \eqref{eq:2}, so that the minimization can be rephrased in Hamiltonian formalism by \cite{troltzsch2010optimal,borzi2011computational}: \begin{equation}\label{eq:Hamilton-a} E(u,\theta) = I(\theta)-\lambda f(u(T)))\,, \end{equation} where $u(T)$ should itself be viewed as a function of $\theta$ obtained by solving~\eqref{eq:detdyn} with $\vartheta=\theta$, that is \begin{equation} \label{eq:detdyn00} \partial_t u = b(u,\theta), \qquad u(t=0) = u_0(\theta). \end{equation} The minimization of \eqref{eq:Hamilton-a} with $u(T)$ obtained from~\eqref{eq:detdyn00} can be performed via steepest descent with adaptive step (line search). This requires to compute the gradient of $E$ with respect to $\theta$, which can be achieved in two ways: by the direct and the adjoint methods~\cite{borzi2011computational,plessix2006review}. These steps are described next. \subsection{Gradient Calculation} \label{sec:gradcalc} \subsubsection{Direct method} \label{sec:Jacobian} The gradient of the cost function with respect to the control reads: \begin{equation} \label{eq:gradE} \nabla_\theta E(u(T,\theta),\theta) = \partial_\theta E + \left(\partial_\theta u(T,\theta)\right)^T \partial_u E = \nabla_\theta I - \lambda \, J^T(T,\theta) \, \partial_u f(u(T,\theta))\,, \end{equation} where $J = \partial_ \theta u$ is the Jacobian---componentwise $J_{i,j}= \partial u_i/\partial\theta_j$. An evolution equation for $J$ can be obtained by differentiating~\eqref{eq:detdyn00} with respect to $\theta$: \begin{equation} \label{eq:jacobian} \partial_t J = \partial_u b \, J + \partial_\theta b, \qquad J(0) = \nabla_\theta \,u_0. \end{equation} Summing up, given the current state of the control, $\theta^n$, we calculate the gradient of the objective function via: \begin{enumerate} \item \textit{Field estimation:} Obtain the current field $u^n$ by solving \begin{equation}\label{eq:forward} \partial_t u^n = b(u^n,\theta^n), \qquad u^n(0) = u_0(\theta^n)\,. \end{equation} \item \textit{Jacobian estimation:} Obtain the Jacobian $J^n$ by solving \begin{equation} \label{eq:Jacobian2} \partial_t J^n = \partial_u b(u^n,\theta^n) \, J^n + \partial_\theta b(u^n,\theta^n), \qquad J^n(0) = \nabla_\theta \,u_0(\theta^n). \end{equation} \item \textit{Gradient calculation:} Compute the gradient $(\nabla_\theta E)^n$ via \begin{equation} (\nabla_\theta E)^n = \nabla_\theta I(\theta^n) - \lambda \, (J^n(T))^T \, \partial_u f(u^n(T)). \end{equation} \end{enumerate} \subsubsection{Adjoint method} \label{sec:adjoint} Let us introduce the adjoint field $\mu(t)$ solution of \begin{equation} \label{eq:adjoint} \partial_t \mu = - (\partial_u b)^T\mu, \qquad \mu(T,\theta) = \lambda \partial_u f(u(T,\theta)). \end{equation} Using this equation as well as the transpose of~\eqref{eq:jacobian} we deduce \begin{equation} \label{eq:15} \begin{aligned} \partial_t (J^T \mu) & = \partial_t J^T \mu + J^T \partial_t \mu \\ &= J^T (\partial _u b)^T \mu + (\partial_\theta b)^T \mu - J^T (\partial_u b)^T\mu = (\partial_\theta b)^T \mu\,. \end{aligned} \end{equation} As a result \begin{equation} \label{eq:17} \int_0^T (\partial_\theta b)^T \mu dt = J^T(T) \mu(T) - J^T(0) \mu(0) = \lambda J^T(T,\theta) \partial_u f(u(T,\theta)) - (\nabla _\theta u_0)^T \mu(0,\theta). \end{equation} This expression offers a way to write the gradient of the objective function in~\eqref{eq:gradE} as \begin{equation} \label{eq:gradE3} \nabla_\theta E = \nabla_\theta I - (\nabla _\theta u_0)^T \mu(0,\theta) -\int_0^T (\partial_\theta b)^T \mu \, dt\,. \end{equation} Using this expression instead of~\eqref{eq:gradE} is computationally advantageous because it avoid the calculation of the Jacobian~$J$ -- note in particular that the adjoint field $\mu$ has the same dimensions as $u$, independent of the dimensions of the space $\Omega$. The price to pay is the field $ u$ must be computed and stored separately since~\eqref{eq:adjoint} for $\mu$ must be solved backward in time. Summarizing, the gradient of the objective function is now calculated via: \begin{enumerate} \item \textit{Field estimation:} Obtain the current field $u^n$ by solving \begin{equation}\label{eq:forwardbis} \partial_t u^n = b(u^n,\theta^n), \qquad u^n(0) = u_0(\theta^n).\, \end{equation} \item \textit{Adjoint field estimation:} Obtain the adjoint field $\mu^n$ by solving \begin{equation}\label{eq:backward} \partial_t \mu^n = - (\partial_u b(u^n,\theta^n))^T\mu^n, \qquad \mu^n(T) = \lambda \partial_u f(u^n(T)). \end{equation} \item \textit{Gradient calculation:} Compute the gradient $(\nabla_\theta E)^n$ via \begin{equation}\label{eq:gradE4} (\nabla_\theta E)^n = \nabla_\theta I(\theta^n) - (\nabla _\theta u_0(\theta^n))^T \mu^n(0) -\int_0^T (\partial_\theta b(u^n(t),\theta^n))^T \mu^n(t) \, dt \,. \end{equation} \end{enumerate} Note that equations \eqref{eq:forwardbis} for $u$ and \eqref{eq:backward} for $\mu$ are adjoint in both space and time. As a result the numerical simulation of these equations has to be done with care, as the integration scheme used for one equation needs to be the adjoint of the other. This is preferably done by using schemes that are self-adjoint. For recent literature on the topic we refer the reader to~\cite{wilcox2015discretely, hager2000runge, walther2007automatic}. \subsection{Descent with pre-conditioning of the gradient} \label{sec:descent} Once we have calculated the gradient of the objective function at $\theta^n$, we can make a downhill step in the cost function landscape using \begin{itemize} \item[(4)] \textit{Descent step with pre-conditioning:} \begin{equation} \label{eq:update} \theta^{n+1} = \theta^n - \alpha^n B^n (\nabla_\theta E)^n \,, \end{equation} % \end{itemize} where $B^n$ is a pre-conditioning $M\times M$ matrix (recall that $\theta \in \Omega \subseteq \mathbb{R}^M$), and $\alpha^n>0$ is the step size that is tuned optimally at each iteration via line search: this can be done using classical merit functions as discussed in~\cite{wright1999numerical}. The estimate of the matrix $B^n$ deserves some further comments. Ideally, $B^n$ should be the inverse of the Hessian of the objective function $E(\theta^n)$, but this Hessian is typically difficult to calculate. Therefore, a simpler solution is to use the Hessian of the prior $I(\theta^n)$, which in the case of a Gaussian measure is simply the inverse covariance matrix $C^{-1}$ (which is independent of $\theta$. Since this estimate coincides with the Hessian of $E(\theta^n)$ only when $\lambda=0$, it will deteriorate when $\lambda$ increases and the pre-conditioning may become inefficient. If that is the case, it may be useful to switch to ``quasi-Newton'' methods such as the BFGS algorithm, or the Limited-Memory BFGS algorithm when $M$ is very large ($>100$). In the applications treated in this paper, the naive pre-conditioning depending only on the prior $I(\theta)$ turned out to be sufficient to perform the optimization efficiently. Since we are typically interested in calculating~\eqref{eq:2} for a range of values of~$z$, instead of fixing~$z$ and trying to determine the corresponding Lagrange multiplier~$\lambda$ in~\eqref{eq:gradE}, it is easier to vary~$\lambda$ and determine \textit{a~posteriori} which value of~$z$ this leads to. Indeed this offers a parametric representation of $\theta^\star(z)$ via \begin{equation} \label{eq:4} \theta^\star(z(\lambda)) = \tilde \theta^\star(\lambda), \qquad z(\lambda) = f(u(T,\tilde\theta^\star(\lambda))\,, \end{equation} where $\tilde \theta^\star(\lambda)$ is the minimizer of $E(\theta)$ at $\lambda$ fixed. We can then also calculate $I(\theta^\star(z(\lambda))) = I(\tilde \theta^\star(\lambda))$ and estimate $P(z(\lambda))\asymp \exp(-I(\tilde \theta^\star(\lambda)))$. \section{Applications} \label{sec:applications} \subsection{Elasticity of an heterogeneous rod} \label{sec:rod} In this section we study a model for a one-dimensional rod with random elasticity coefficient subject to a prescribed external mechanical forcing (i.e. pulling at one end). Even though this model (or generalizations thereof) may be of interest in actual applications (e.g.~as a coarse-grained model of DNA stretching~\cite{bustamante1994entropic,cluzel1996dna,lankavs2000sequence}), it is primarily used here as a simple illustrative example of the tools and concepts introduced in Secs.~\ref{sec:LDTmethod} and~\ref{sec:optimization}. In particular, we use LDT to locate the most likely configurations leading to extreme responses and we show that such realizations dominate the statistics asymptotically. In the case of forcing increasing linearly in time, we are able to derive analytical results which are used to validate our numerical method. We also study the extreme events that occur under a nonlinear forcing, when no analytical solution is available. \subsubsection{Continuous model with random structure} Consider a one-dimensional elastic rod of length 1 that is being pulled at one end with a time-dependent force and whose energy is specified in terms of its displacement field $u:[0,1] \to \mathbb{R}$ via \begin{equation}\label{eq:cont-Ham-rod} V(u,t) = \frac12 \int_0^1 \mathcal{D}(x)\,|\partial_x u|^2\,dx - r(t)u(1)\,, \end{equation} where the first term is the total internal energy of the rod and the second term is the external energy (negative of the work potential); $\mathcal{D}(x)>0$ is the elasticity coefficient, assumed to be spatially dependent, and $r(t)$ is a prescribed external forcing protocol acting on the right end of the rod -- the specific form of $r(t)$ will be introduced later. The dynamics of the rod is governed by the Euler-Lagrange equation associated with~\eqref{eq:cont-Ham-rod}: \begin{equation}\label{eq:cont-rod} \partial^2_t u = \partial_x(\mathcal{D}(x)\partial_x u)\quad x \in (0,1)\,, \end{equation} with initial conditions to be prescribed later and boundary conditions \begin{equation}\label{eq:bound-rod} u(t,0)=0\,,\quad \mathcal{D}(1)\partial_x u(t,1)=r(t)\,, \quad \forall t\ge0\,. \end{equation} In order to introduce uncertainty in the model we make the elasticity random, i.e.~we take $\mathcal{D}(x) \equiv \mathcal{D}(x,\vartheta)$. Here we will assume that $\mathcal{D}(x,\vartheta)$ is piecewise constant over blocks of size $1/M$ for some $M\in \mathbb{N}}\def\RR{\mathbb{R}}\def\ZZ{\mathbb{Z}$, with independent values in each block. Specifically, we take: \begin{equation} \label{eq:coarse} \mathcal{D}(x,\vartheta) = \sum_{k=1}^M \varphi_k(x) g(\vartheta_k )\,, \end{equation} where the functions $\{\varphi_k\}_{k=1}^M$ are given by \begin{equation}\label{eq:basis} \varphi_k(x)= \left\{ \begin{aligned} &1 \qquad \text{if }\ \ M^{-1}(k-1) \le x< M^{-1} k \\ &0\qquad \text{otherwise} \end{aligned}\right.; \end{equation} $g$ is a given function; and $\{\vartheta_k\}_{k=1}^M $ are \text{i.i.d.} random variables. Below we will consider two cases: \smallskip \paragraph{\textit{Case 1.}} Here we assume that $g:(0,\infty) \to (0,\infty)$ with \begin{equation} \label{eq:37} g(u) = u^{-1} \end{equation} and we take the variable $\{\vartheta_k\}_{k=1}^M$ to be exponentially distributed, i.e. \begin{equation} \label{eq:8} \mathbb{P}(\vartheta_k \ge \theta_k) = e^{-\alpha \theta_k}, \qquad \theta_k \ge 0, \quad \alpha >0\,. \end{equation} This choice implies that \begin{equation} \label{eq:16} S(\eta) = \log \mathbb{E}}\def\mathbb{P}{\mathbb{P} e^{\<\eta,\vartheta\>} = -\sum_{k=1}^M \log (1-\alpha^{-1}\eta_k), \qquad \eta_k < \alpha \quad \forall k=1,\ldots, M, \end{equation} so that \begin{equation} \label{eq:18} I(\theta) = \sum_{k=1}^M \left(\alpha \theta_k - 1 - \log \theta_k \right) \qquad \theta_k >0 \quad \forall k=1,\ldots, M\,. \end{equation} \smallskip \paragraph{\textit{Case 2.}} Here we assume that $g:\mathbb{R}\to(0,\infty)$ with \begin{equation}\label{eq:PDFchain} g(u) = \tfrac12u + \sqrt{\tfrac14u^2+1}, \end{equation} and we take the variable $\{\vartheta_k\}_{k=1}^M$ to be normally distributed with variance $\sigma^2>0$, i.e. \begin{equation} \label{eq:38} \vartheta_k = \mathcal{N} (0,\sigma^2) \end{equation} This choice implies that \begin{equation} \label{eq:39} S(\eta) = \tfrac12 \sum_{k=1}^N \sigma^2 \eta_k^2, \qquad I(\theta) = \tfrac12 \sum_{k=1}^N \sigma^{-2} \theta_k^2\,. \end{equation} Given this random input, our aim is to investigate the statistics of the displacement of the right end of the rod at time $T$: this amount to considering the observable $f(u(T))=u(T,1)$, and studying the behavior of \begin{equation} \label{eq:29} P(z) = \mathbb{P}(u(T,1, \vartheta)\ge z) \qquad \text{for} \ \ z \gg 1. \end{equation} Below we will analyze the behavior of this quantity in two cases, when the forcing $r(t)$ in~\eqref{eq:cont-Ham-rod} is linear in $t$ and when it is not -- the first situation is amenable to analytical treatment whereas the second is not in general. Note that in both situations, the behavior of $P(z)$ for large $z$ will depend on how fast $g(u)$ decays to zero: due to the shape of $g$ this will depend on the right tail of the distribution of $\vartheta_k$ in Case 1 and on its left tail in Case 2. \subsubsection{Discrete model} \label{sec:discrete} To perform the numerics, we need to consider a spatially discretized version of the model above. We do so by introducing the discrete energy \begin{equation}\label{eq:discr-Ham-rod} V(u,t) = \frac12 \sum_{j=0}^{N-1} \mathcal{D}_{j+1}(\vartheta) \frac{(u_{j+1}-u_j)^2}{\Delta x} - r(t)\, u_N \,, \end{equation} in which $u_j = u(j\Delta x)$, $\mathcal{D}_j= \mathcal{D}(j\Delta x)$, $\Delta x =1/N$. Alternatively, \eqref{eq:discr-Ham-rod} can be thought of as the energy for a system of $N+1$ beads $u_j$ connected by $N$ springs with random spring constants $\mathcal{D}_j(\vartheta)$. The dynamics obeys the system of ODEs \begin{equation}\label{eq:rod} \partial_t^2{u_j} = \frac{\mathcal{D}_{j+1}}{\Delta x^2}(u_{j+1}-u_j) - \frac{\mathcal{D}_j}{\Delta x^2}(u_j - u_{j-1})\,,\qquad j=1,...,N-1\,, \end{equation} with fixed boundary condition $u_0=0$ at the left end and dynamic boundary condition \begin{equation}\label{eq:dynb1} \partial_t^2u_N = - \frac{\mathcal{D}_N}{\Delta x^2}(u_N - u_{N-1}) + \frac{r(t)}{\Delta x} \end{equation} at the right end. We will pick $N=P M$ for some $P\in \mathbb{N}}\def\RR{\mathbb{R}}\def\ZZ{\mathbb{Z}$, so that by our choice for $\mathcal{D}(x,\vartheta)$ in~\eqref{eq:coarse} we have \begin{equation} \label{eq:40} \mathcal{D}_j(\vartheta) = g(\vartheta_k) \qquad \text{for} \ \ \lceil j/P \rceil= k, \ \ j=1,\dots,N, \ \ k = 1\ldots,M. \end{equation} Since we focus on the statistics of the observable $f(u(T))=u_N(T)=u(T,1)$ that measures the displacement at time $T$ of the right end point with respect to its initial position, the cost function is \begin{equation}\label{eq:Ediscr} E(u,\theta) = I(\theta) - \lambda\, u_N(T) \,, \end{equation} to optimize on the parameters $\{\theta_k\}_{k=1}^M$. We will minimize~\eqref{eq:Ediscr} using the adjoint method to compute the gradient. As shown in the Appendix, the adjoint equations read \begin{equation}\label{eq:adj-discr} \partial_t^2 \mu_j = \frac{\mathcal{D}_{j+1}}{\Delta x^2}(\mu_{j+1}-\mu_j) - \frac{\mathcal{D}_j}{\Delta x^2}(\mu_j - \mu_{j-1})\,,\qquad j=1,...,N-1\,, \end{equation} with conditions at the boundaries given by \begin{equation}\label{eq:BCadj} \mu_0(t) = 0 \,, \quad \partial_t^2\mu_N = -\frac{\mathcal{D}_N}{\Delta x^2} (\mu_N-\mu_{N-1})\,, \end{equation} and final conditions \begin{equation}\label{eq:ICadj} \mu_j(T) = 0, \quad \partial_t \mu_j(T) = \lambda \delta_{j,N}\,. \end{equation} The gradient of the cost function can be expressed as \begin{equation}\label{eq:gradRod1} \nabla_\theta E(u(\theta),\theta) = \nabla I(\theta) - G^T\,\nabla \mathcal{D}(\theta)\,, \end{equation} where $\nabla \mathcal{D}(\theta)$ is the $N\times M$ tensor with entries $\partial \mathcal{D}_j(\theta)/\partial \theta_k$, $j=1,\ldots, N$, $k=1,\ldots, M$, and $G$ is a vector with entries \begin{equation}\label{eq:gradRod2} G_j = \int_0^T \frac{u_{j}-u_{j-1}}{\Delta x} \frac{\mu_{j}-\mu_{j-1}}{\Delta x}\,dt\,, \qquad j=1,\ldots, N\,. \end{equation} \subsubsection{Linear forcing} Assume that $r(t) = a t $ for some $a>0$ and as initial conditions for~\eqref{eq:in-rod} take \begin{equation}\label{eq:in-rod1} u(0,x)=0\,,\quad \partial_t u(0,x)= a \int_0^x \frac{dx'}{\mathcal D(x',\theta)} \,, \quad \forall x \in [0,1]\,. \end{equation} The solution to~\eqref{eq:cont-rod} equipped with the boundary conditions in~\eqref{eq:bound-rod} is \begin{equation} \label{eq:19} u(t,x,\vartheta) = a t \int_0^x \frac{dx'}{\mathcal{D}(x',\vartheta)}\,. \end{equation} Let us consider the implications of this formula in {\it Case 1}, which is suitable to derive analytical results. Eq.~\eqref{eq:19} implies that \begin{equation} \label{eq:20} u(T,1, \vartheta) = aT \int_0^1\frac{dx'}{\mathcal{D}(x',\vartheta)} = \frac{aT}{M} \sum_{k=1}^M \vartheta_k\,, \end{equation} where we used the specific form of $\mathcal{D}(x,\vartheta)$ given in~\eqref{eq:coarse} with $g$ given in~\eqref{eq:37}. Note that since the discrete equivalent to the initial conditions~\eqref{eq:IC} is \begin{equation}\label{eq:IC1} u_j(0) = 0, \qquad \partial_t u_j(0) = \frac{a}{M}\sum_{k=1}^j \theta_k\,, \end{equation} the result~\eqref{eq:20} also holds for the discretized model, i.e.~we have \begin{equation} \label{eq:20b} u_N(T, \vartheta) = \frac{aT}{M} \sum_{k=1}^M \vartheta_k\,. \end{equation} From~\eqref{eq:8}, this implies that $u(T,1, \vartheta)=u_N(T,\vartheta)$ follows a gamma distribution with shape parameter~$M$ and rate parameter $\alpha M (aT)^{-1}$: \begin{equation} \label{eq:23} \begin{aligned} P(z) &= \int_z^\infty \frac{(\alpha M (aT)^{-1})^M u^{M-1}}{(M-1)!} e^{-\alpha M (aT)^{-1} u} du\\ & = \frac{1}{(M-1)!}\Gamma\left(M,\alpha M(aT)^{-1}z\right)\,, \end{aligned} \end{equation} where $\Gamma(\cdot,\cdot)$ is the upper incomplete Gamma function. When $z\gg1$ with $M$ fixed, \eqref{eq:23} gives \begin{equation} \label{eq:24} P(z) \sim \frac{(\alpha M (aT)^{-1} z)^{M-1}}{(M-1)!} e^{-\alpha M (aT) ^{-1} z}\,, \end{equation} meaning that \begin{equation} \label{eq:31} \log P(z) \sim -\alpha M (aT)^{-1} z +(M-1) \log (\alpha M (aT)^{-1} z) - \log(M-1)!. \end{equation} In this last expression the second and third terms at the right hand side are subdominant over the first, $\alpha M (aT) ^{-1} z$, and disappear in the limit as $z\to\infty$. It is useful to keep this terms for comparison with the result~\eqref{eq:13b} in Theorem~\ref{th:1} and the result~\eqref{eq:13c}, which we do next. If we solve \begin{equation} \label{eq:26} \min I(\theta) = \min \sum_{k=1}^M \left(\alpha \theta_k - 1 - \log \alpha\theta_k \right) \qquad \text{subject to} \qquad u(T,1, \theta) = \frac{aT}{M} \sum_{k=1}^M \theta_k = z\,, \end{equation} we get \begin{equation} \label{eq:32} \theta^\star_k(z) = (aT)^{-1} z \qquad \text{for} \ \ k=1,\ldots, M\,. \end{equation} As a result \begin{equation} \label{eq:34} I(\theta^\star(z)) = M\left(\alpha (aT)^{-1} z -1 - \log(\alpha (aT)^{-1} z)\right)\,, \end{equation} which from~\eqref{eq:31} is consistent with $\log P(z) \sim - I(\theta^\star(z)) $ as $z\to\infty$, as predicted by~\eqref{eq:13b}. Note also that here \begin{equation} \label{eq:35} \eta^\star _k(z) = \partial_{\theta_k} I(\theta^\star(z)) = \alpha - aT z^{-1} \qquad \text{for} \ \ k=1,\ldots, M\,. \end{equation} Since this implies that $|\eta^\star _k(z)|\to \alpha $ as $z\to\infty$, this means that the condition in~\eqref{eq:32d} is not satisfied here. \begin{figure} \centering \centering \includegraphics[width=.5\linewidth]{fig-rod-1a}% \includegraphics[width=.5\linewidth]{fig-rod-1b} \caption{Linear forcing with $a=0.1$, final time $T=15$, initial conditions~\eqref{eq:IC1}, and the statistical prior of {\it Case~1}. The numerics are performed with $M=N=30$. Left panel: Comparison between the exact expression for $P(z)$ in~\eqref{eq:23}, the empirical MC estimate with $2\times10^7$ samples, the analytical LDT estimate~\eqref{eq:34}, and the LDT estimate obtained via numerical optimization. Right panel: Comparison between the analytical~\eqref{eq:32} and the numerical instantons, for $z=1.58,1.71,1.85,2.04,2.32,3.08$ from top to bottom.} \label{fig:1} \end{figure} In Fig.~\ref{fig:1} we compare the asymptotic estimate~\eqref{eq:34} with the exact expression~\eqref{eq:23}. We also check that the numerical optimization is consistent with the analytical one, which is important to validate the numerical code described below. \subsubsection{Nonlinear forcing} \begin{figure} \centering {\includegraphics[width=.6\linewidth]{fig-rod-2a}% } \caption{The forcing protocols $r_\delta(t)$ in~\eqref{eq:41}, which are decreasing functions of $t$ when $\delta<0$ and increasing functions when $\delta>0$.} \label{fig:rod1} \end{figure} \begin{figure} \centering { \includegraphics[width=.6\linewidth]{fig-rod-3-CDF-tails}} \caption{Comparison between the empirical distributions $P(z)$ obtained via MC sampling and their LDT estimate. The sampling works down to events whose probability is about the inverse of the MC sampling size, while the LDT optimization allows us to extend the tails to much smaller probabilities.} \label{fig:2} \end{figure} Next we consider nonlinear forcing protocols of the type \begin{equation} r(t)=at^\beta \qquad \text{and}\qquad r(t)=a(T-t)^\beta \qquad \text{both with} \quad a, \beta>0\,.\label{eq:41}\ \end{equation} Letting $s=+1$ if $r(t) = at^\beta $ and $s=-1$ if $r(t)=a(T-t)^\beta$, we will use $r_\delta(t)$ with $\delta=s\beta$ as shorthand to describe the family of forcing protocols. They are show in Fig.~\ref{fig:rod1}. As initial conditions for \eqref{eq:cont-rod} we take \begin{equation}\label{eq:in-rod} u(0,x)=0\,,\quad \partial_t u(0,x)=0\,, \quad \forall x \in [0,1]\,. \end{equation} At discrete level these initial conditions read \begin{equation}\label{eq:IC} u_j(0) = 0, \qquad \partial_t u_j(0) = 0\,. \end{equation} In this section we restrict ourselves to {\it Case~2} and we use $M=N=30$ and final time $T=1$. Observing that the mean elasticity $\mathbb{E}}\def\mathbb{P}{\mathbb{P} \left(\mathcal{D}(x)\right)=1$ (as for {\it Case 1}), the average velocity of propagation of the waves along the bar is also $1$. Thus, $1$ is the average time that a signal takes to propagate from the right end to the left end. This means that taking $T=1$ we are considering a short transient strongly out of equilibrium, where the random structure will contribute in a non-homogeneous way. To integrate~\eqref{eq:rod} and~\eqref{eq:dynb1} numerically, we use a velocity-Verlet integrator, which is of second order, symplectic, and time reversible, with a time step of $10^{-3}$. The optimization is performed as described in Sec.~\ref{sec:optimization}, using~\eqref{eq:gradRod1} and~\eqref{eq:gradRod2}. \begin{figure} \centering \includegraphics[width=320pt]{fig-rod-4} \caption{Top panel: Elasticity structure of the instantons for $z\ge2.7$, for the different protocols labeled by~$\delta$. Inset: the probability $P(z=2.7)$ as a function of the forcing protocol. Bottom panel: Same as in the top panel, but for $z\ge3.3$. Inset: the probability $P(z=3.3)$ as a function of $\delta$ in the forcing protocol.} \label{fig:rod5} \end{figure} Let us now describe our results. In Fig.~\ref{fig:2} the LDT estimates of $P(z)$ are compared to the empirical estimates obtained via MC with $2\times10^6$ samples, showing good agreement. Next we look at the specific elasticity structure of the optimizers, $\mathcal{D}(x,\theta^\star(z))$. These are shown in Fig.~\ref{fig:rod5}. As can be seen, the region that is relevant for having an extreme extension $u(T=1,1)$ occupies only the right half of the space domain, independent of the protocol. This makes sense since on average the signal takes a time $1$ to cross the whole domain: For a point $x_0$ to influence $u(T=1,1)$ the signal needs to have time to propagate to $x=1$. As a result, the points on the left side will not have the possibility to influence the dynamics at all, and the optimal state of $\mathcal{D}(x,\theta)$ is determined by mere minimization of $I(\theta)$ with no dynamical constraint. In contrast, on the right side of the domain, $\mathcal{D}(x,\theta)$ must take low values to allow for large values of $u(T=1,1)$ -- since these low values are unlikely, this also account for the drop in probability observed in Fig.~\ref{fig:2}. Fig.~\ref{fig:rod5} also indicates that $\mathcal{D}(x,\theta^\star(z))$ depends on the forcing protocol. This dependency can again be interpreted intuitively by realizing that the region that impacts $u(T,1)$ the most will be the one that is reached by a strong signal (i.e.~the propagation front of the most intense part of the forcing) and is able to send a strong feedback back to the right end at final time -- this feedback is what is accounted for by the backward evolution of the adjoint equation in the optimization. So, the earlier the most intense part of the forcing takes place, the further from the right end a low elasticity peak appears. This explains why going towards negative $\delta$ the low-elasticity peak moves to the left in Fig.~\ref{fig:rod5}, and the constant forcing ($\delta=0$) is the one where the low elasticity contribution is the most uniformly distributed. Note that in this framework it is possible to compare how likely the protocols are to produce extreme realizations of a given size, as shown in the insets in Fig.~\ref{fig:rod5}. In this sense, the constant protocol appears to be the optimal one. This is consistent with the fact that $\delta=0$ is the highest curve in Fig.~\ref{fig:2}. \begin{figure} \centering \includegraphics[width=.8\linewidth]{fig-rod-5} \caption{Comparison between the instanton $\theta^\star(z)$ (black solid line) and the Monte Carlo sampling on the distribution of $\vartheta$, conditioned on $u_N(1)=u(1,1)\ge z$ (color map with intensity proportional to the empirical probability density; thick white line = mean; thin white lines = 1 standard deviation range around the mean). Left panels: $z=2.10$, right panels: $z=2.40$. The top panels show the full data: the instanton agrees with the mean, but the variance does not substantially change going to more extreme events. The two central panels show the fluctuations perpendicular to $\eta^\star(z)$, confirming that their amplitude is independent of the size of the event (left and right panels have the same variance) and homogeneous in space. The bottom panels show the fluctuations in the direction parallel to $\eta^\star(z)$, indicating that their amplitude decreases as $z$ increases, as predicted by the theory in Sec.~\ref{sec:LDTmethod}.} \label{fig:3} \end{figure} \begin{figure} \centering \includegraphics[width=.6\linewidth]{fig-rod-6} \caption{Increasing $z$, the fluctuations in the direction perpendicular to $\eta^\star(z)$ stay constant, whereas in the parallel direction they scale as $O(|\eta^\star(z)|^{-1})$. Both behaviors are predicted analytically and here confirmed numerically.} \label{fig:4} \end{figure} To further clarify the role of the instantons and why they dominate the dynamics and the statistics of the extreme events, it is useful to ``filter'' the conditional events such that $u(T,1)\ge z$ in the following way: First, we fix a size $z$ and generate via MC a large set of $\vartheta$ such that $u(T,1,\vartheta)\ge z$. Second, we average over such conditional set to obtain the mean conditional event and its fluctuations around the mean, which is generally very close to the instanton $\theta^\star(z)$. Third, we decompose the fluctuations $\vartheta - \theta^\star(z)$ into the components parallel and perpendicular to $\eta^\star(z)$, i.e.~the normal to the hypersurface $\Omega(z)$. This procedure is then repeated for various~$z$. In Fig.~\ref{fig:3} we show the outcome of this analysis for the protocol with $\delta=1.5$ and for two different values of $z$ -- analogous results hold for the other kinds of forcing as well. As can be seen the average event $u(T,1)\ge z$ lies on top of the instanton $\theta^\star(z)$, with fluctuations independent of the size of the event and also of the position along the rod (upper panels). The decomposition shows that the components perpendicular to $\eta^\star(z)$ are independent of the size of the event, and basically independent of the dynamics too. Their mean and standard deviation are the mean and the standard deviation of the unconstrained random variables $\vartheta$ (central panels). In contrast, the parallel fluctuations are small and tend to zero as $z$ increases (bottom panels). The scaling of the fluctuations is analyzed in more detail in Fig.~\ref{fig:4}, which shows that they are $O(1)$ in the direction perpendicular to $\eta^\star(z)$ and $O(|\eta^\star(z)|^{-1})$ in the direction parallel to it, consistent with the theoretical predictions. \subsection{Extreme events in optical turbulence}\label{sec:NLS} \subsubsection{The 1D NLSE and the LDT formalism} The nonlinear Schr\"odinger equation (NLSE) in one dimension arises in a variety of different contexts such as surface gravity waves~\cite{zakharov:1968,onorato-residori-bortolozzo-etal:2013}, nonlinear fiber optics~\cite{akhmediev2013recent}, plasmas~\cite{bailung2011observation} and Bose-Einstein condensates~\cite{gross:1961,pitaevsky:1961}. Here we will focus on applications of NLSE in nonlinear optics, a domain that has seen exciting experimental developments in recent years~\cite{kibler2010peregrine, suret2016single, tikan2017universality}. Specifically, we study the problem of the onset of rogue waves out of a bath of random waves taken as initial condition for NLSE, which is a key question in \textit{integrable turbulence}~\cite{zakharov2009turbulence,randoux2014intermittency,% agafontsev2015integrable,cousins2016reduced,farazmand-sapsis:2017}. In non-dimensional units, the 1D NLSE for the envelope of a light beam propagating in an optical fiber reads \begin{equation} \label{eq:NLS} \partial_{\xi} \Psi = i \frac{1}{2}\Psi_{\tau\tau} + i |\Psi|^2\Psi\,, \quad \tau \in \Gamma, \end{equation} where \mbox{$\Gamma=[0,T]$}, with periodic boundary conditions $\Psi(\xi,0)=\Psi(\xi,T)$, and a suitable initial condition $\Psi(0,\tau)=\Psi_0(\tau)$, at the input end of the fiber $\xi=0$. The non-dimensional distance~$\xi$, time~$\tau$, and envelope~$\Psi$ are related to the respective physical quantities $x$, $t$, and $\psi$ via characteristic constants that depend on the specifics of the optical fiber: $x = \mathcal L_0 \xi$, $t = \mathcal T_0 \tau$ and $\psi = \sqrt{\mathcal P_0}\Psi$. For instance, if we pick $\mathcal T_0 = 5\text{ ps}$, $\mathcal L_0 = 0.5\text{ km}$, $\mathcal P_0 = 0.5\text{ mW}$, the NLSE~\eqref{eq:NLS} models an optical fiber with dispersion $|\beta_2|=\mathcal T_0^2/\mathcal L_0 = 50\text{ ps}^2 \text{km}^{-1}$ and nonlinearity $\gamma=1/(\mathcal L_0\mathcal P_0)=4 \text{ km}^{-1}\text{mW}^{-1}$. Let us denote by $\{\hat \Psi_n\}_{n\in\ZZ}$ the Fourier component of $\{\Psi(\tau)\}_{\tau\in[0,T]}$, i.e. \begin{equation} \label{eq:Fourier} \hat \Psi_n=\frac1T \int_0^T e^{-i\omega_n \tau} \Psi(\tau) d\tau,\qquad \Psi(\tau) = \sum_{n=-\infty}^{+\infty} e^{i\omega_n \tau} \hat \Psi_n\,, \end{equation} where $\omega_n=2\pi n/T$ and $n\in\mathbb{Z}$. Equation \eqref{eq:NLS} is derived under the \textit{quasi-monochromatic} assumption, meaning that the spectrum $\hat C_n$ defined as \begin{equation} \hat C_n=\frac1T \int_0^T e^{-i\omega_n \tau} C(\tau) d\tau\,,\qquad C(\tau-\tau')=\mathbb{E}}\def\mathbb{P}{\mathbb{P}(\Psi_0(\tau)\bar \Psi_0(\tau'))\,, \end{equation} must be narrow -- here and below the bar denoting complex conjugation. We will consider a Gaussian spectrum with \begin{equation} \label{eq:spectrum} \hat C_n = \mathcal{A} e^{-\omega_n^2/(2\Delta)}\,\qquad \mathcal{A} >0, \qquad \Delta >0, \qquad -M \le n \le M, \quad M>0, \end{equation} and $\hat C_n=0$ for $|n|> M$. Assuming that the initial $\Psi(0,\tau)$ is a Gaussian field with mean zero and covariance $C(\tau-\tau') $, this implies the representation \begin{equation} \label{eq:ICFourier} \Psi(0,\tau,\vartheta) = \sum_{n=-M}^M e^{i\omega_n \tau} \hat{C}_n^{1/2}\vartheta_n, \end{equation} where $\vartheta_n$ are complex Gaussian variables with mean zero and covariance $\mathbb{E}}\def\mathbb{P}{\mathbb{P}\vartheta_n\bar\vartheta_m=\delta_{m,n}$, $\mathbb{E}}\def\mathbb{P}{\mathbb{P} \vartheta_n \vartheta_m = \mathbb{E}}\def\mathbb{P}{\mathbb{P}\bar \vartheta_n \bar \vartheta_m = 0\,.$ Note that the spectral amplitude is related to the optical power $P(\xi,\tau)=|\psi(\xi,\tau)|^2$ (statistically homogeneous in $\tau$) via $\mathcal{A}=\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)/\sum_n e^{-\omega_n^2/(2\Delta)}$. The initial statistical state of the system is thus completely determined given the two parameters $\Delta$ and $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$, and the average power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$ is relevant to optical experiments -- it also enjoys the property of being invariant under the NLSE evolution in the variable $\xi$, i.e.~it can be measured at the input or at the output of the optical fiber, equivalently. In the set-up above, we will investigate extreme fluctuations of the optical power at the output of the optical fiber ($\xi=L$). Recalling that $|\Psi(L,\tau)|=\sqrt{P(L,\tau)}$, this amounts to looking at the statistics of \begin{equation} \label{eq:36} f(\Psi(\vartheta))= \max_{\tau\in\Gamma}|\Psi(L,\tau,\vartheta)| \,, \qquad L >0. \end{equation} Analyzing this observable using the framework developed in Secs.~\ref{sec:LDTmethod} and \ref{sec:optimization} amounts to minimizing the cost function (this is~\eqref{eq:Hamilton-a}) \begin{equation} \label{eq:cost-waves} E(\Psi,\theta) = I(\theta) - \lambda f(\Psi) \qquad \text{with} \qquad I(\theta)=\tfrac12 \sum_{n=-M}^M \left|\theta_n\right|^2. \end{equation} This minimization must be performed on the $2\times(2M+1)$-dimensional space $\Omega\subseteq\mathbb{C}^{2M+1}$ of the initial conditions. The gradient of the cost function~\eqref{eq:cost-waves} is given by \begin{equation} \label{eq:gradE-waves} \nabla_\theta E(\Psi(\theta),\theta) = \nabla_\theta I(\theta) + \Re (J(L,\tau_*))^T \frac{\Re (\Psi(L,\tau_*))}{|\Psi(L,\tau_*)|} + \Im (J(L,\tau_*))^T \frac{\Im (\Psi(L,\tau_*))}{|\Psi(L,\tau_*)|}\,, \end{equation} where $ \Psi(L,\tau_*)\equiv\max_{\tau\in\Gamma} |\Psi(L,\tau)|\,$. The field $\Psi$ is evolved with~\eqref{eq:NLS} and the initial condition depends on the point $\theta\in\Omega$ through the mapping $\Psi(0,\theta)$ defined in~\eqref{eq:ICFourier}, with the difference that here $\theta$ is no longer random. The matrix $J$ (also complex) evolves according to \begin{equation} \label{eq:Jmnls} \partial_{\xi} J(\xi,\tau) = \int_0^L d\xi' \, \bigg(\frac{\delta b(\Psi(\xi))}{\delta \Psi(\xi')} \, J(\xi',\tau) + \frac{\delta b(\Psi(\xi))}{\delta \bar \Psi(\xi')} \, \bar J(\xi',\tau)\bigg) \,, \end{equation} where $b(\Psi(\xi)) )$ is a shorthand for the right hand side of~\eqref{eq:NLS}: explicitly \begin{equation} \label{eq:bmnls} \int_0^L d\xi' \,\frac{\delta b(\xi)}{\delta \Psi(\xi')}\, J(\xi') = \bigg(\frac{i}{2}\partial_{\tau\tau} + 2 i |\Psi(\xi)|^2\bigg) J(\xi)\,, \end{equation} \begin{equation} \int_0^L d\xi' \,\frac{\delta b(\xi)}{\delta \bar \Psi (\xi')} \, \bar J(\xi') = i \big(\Psi(\xi)\big)^2 J(\xi)\,. \end{equation} The initial condition for \eqref{eq:Jmnls} is \begin{equation} \label{eq:incondJ} J(\xi=0,\theta) = \nabla_\theta \Psi(0,\theta)\,. \end{equation} Before turning to the results, let us explain how the numerical simulations were performed. Equations~\eqref{eq:NLS} and~\eqref{eq:Jmnls} were evolved from $\xi=0$ to $\xi=L$ (up to $L=0.2$) using the pseudo-spectral second order Runge-Kutta exponential-time-differencing method (ETDRK2)~\cite{cox:2002,kassam:2005} with step $d\xi=5\times10^{-4}$ on a periodic box $[0,T]$ discretized by $2^{12}$ equidistant grid points. The size $T=30$ is found large enough for the boundary conditions to not affect the statistics on the spatio-temporal scales considered. Each Monte Carlo simulation involves $10^6$ realizations of the random initial data constructed via~\eqref{eq:ICFourier}, with $M=45$. Adding more modes to the initial condition does not affect the results in any significant way. The minimization was performed in the space $\Omega$ (with high dimension $2\times (2M+1) = 182$). This step was carried out via steepest descent with adaptive step (line search) and preconditioning of the gradient, using the covariance of the initial condition as metric, as explained in Sec.~\ref{sec:optimization}. \subsubsection{Results} For generality, we present the results for the normalized field $A(\xi,\tau)=\Psi(\xi,\tau)/\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)}$ using non-dimensional units. One can easily obtain the physical dimensions by applying the straightforward transformations given below equation \eqref{eq:NLS}. Four sets of parameters have been chosen to explore different regimes: In Set 1, we take $\Delta=\pi$, $\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P) = 5/4$; in Set 2, $\Delta=\pi/2$, $\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P) = 5/4$; in Set 3, $\Delta=3\pi/2$, $\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P) = 5/4$; and in Set 4, $\Delta=\pi$, $\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P) = 5/9$. There have been recent claims, supported by both numerical and experimental evidence~\cite{suret2016single, tikan2017universality}, about the universality of the Peregrine Soliton (PS) as a pathway to optical rogue waves out of a random background. For this reason, we carried out a comparison between the instantons and the PS. In Fig.~\ref{fig:6}, the path of occurrence of two extreme events is shown for Set~1, selected among the events in the random sampling with maximum power amplification $|A|^2=P/\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$ exceeding a value of $40$. The instanton and the PS reaching the same power amplification are also plotted. \begin{figure} \centering \includegraphics[width=.8\linewidth]{fig7-samples-evol-NLS} \caption{Set~1: The paths of occurrence of two extreme events plotted are compared with the instanton and the Peregrine solution reaching the same maximum power at $\xi=L$. Shown is the quantity $|A(\xi,\tau)|^2$, i.e.~the power in units of average power, at three different locations ($L=0.2$). The solution are shifted away from one another for clarity, exploiting homogeneity in~$\tau$.} \label{fig:6} \end{figure} \begin{figure} \centering \includegraphics[width=.6\linewidth]{fig8-pdf-tails} \caption{Set~1: Comparison between the probability distributions of $\max_\tau |A(L,\tau)|$ in the periodic time window $[0,T]$ obtained by MC with $10^6$ samples, and their corresponding LDT estimates computed using the optimization method. The plot captures the tail fattening due to the NLSE dynamics, as the output point is taken at increasing distance $L$ from the input. The rogue-wave threshold is $|A|_{RW}\simeq 2.8$\,. The characteristic length of emergence of the coherent structures is $L_c=0.2$, compatible with the observed tail fattening.} \label{fig:7} \end{figure} \begin{figure} \centering \includegraphics[width=.8\linewidth]{fig9-filter-evol} \caption{Set~1: Results of the conditioning on the sampling for $\max_{\tau\in\Gamma} |A(L,\tau)|\ge z=6.25$, with $L=0.2$. Shown is the average of the conditional event (blue line), surrounded by the 1 std range (red area). The instanton (black line) is the optimal event reaching maximal intensity $A=z$ at the output point $\xi=L$. The PS is also represented (green line), normalized to have intensity $z$ at the point of maximal space-time focusing. From left to right, the panels are at $\xi=0$, $\xi=L/2$ and $\xi=L$.} \label{fig:8} \end{figure} In Fig.~\ref{fig:7} the probability $P(z)=\mathbb{P}(\max_\tau|A(L,\tau)|\ge z)$ is shown for various values of $L$, showing good agreement between the results from MC sampling and those from LDT optimization. A rough estimate for the onset threshold of optical rogue waves is $|A|_{RW}=4\sqrt{2/\pi}\mathbb{E}}\def\mathbb{P}{\mathbb{P}(|A|)\simeq 2.8$~\cite{el2018spontaneous}, independently of the set considered because of the use of the normalized variable $A$. As can be seen, the focusing NLSE increases the probability of large excursions of $|A(L,\tau)|$ compared to its initial Gaussian value with expectation $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(|A(L=0,\tau)|) = \sqrt{\pi/4}$. This happens gradually as the distance $L$ separating the input from the output increases. The tail fattening can be interpreted quantitatively in terms of the typical lengths of the coherent structures of NLSE. Defining the linear length as $L_{\text{lin}}=2/\Delta^2$ and the nonlinear length as $L_{\text{nlin}}=1/\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)$, the typical length of emergence of a coherent structure starting from a small hump is $L_c = \tfrac12 \sqrt{L_{\text{lin}}L_{\text{nlin}}}$. This gives $L_c=0.2$ for Set 1, in good agreement with the width of the spatial transient over which the fast tail fattening takes place. The asymptotic agreement of the probabilities shown in Fig.~\ref{fig:7} is a numerical evidence that the focusing NLSE \eqref{eq:NLS} with random initial data \eqref{eq:ICFourier} satisfies an LDP. Additional support for the LDP is found in Fig.~\ref{fig:8}, where we compare the instanton with the sampling mean. Looking at the signal to noise ratio, one sees that the events reaching a certain extreme amplification are all very similar. According to the results in Sec.~\ref{sec:LDTmethod}, these events are expected to have typical fluctuations in the direction perpendicular to the instanton in the space $\Omega$: notice how away from the focusing region (determined by the direction perpendicular to the instanton because there the instanton is vanishing) the observable $|A|$ fluctuates with standard deviation $\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)/2}\sqrt{(4-\pi)/2}/\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)}\simeq0.57$ around the expected value $\sqrt{\pi/2}\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)/2}/\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)}\simeq 0.89$, exactly as expected for typical events. Instead, the extreme size of the event is due to the component parallel to the instanton in $\Omega$, with small fluctuations in this direction: As a matter of fact, in the focusing region (determined by the component parallel to the instanton) the signal to noise ratio becomes very big, meaning that, as $z$ increases, the extreme rogue waves with $\max_\tau|A(\tau,L)|\ge z$ become closer to the instanton reaching $\max_\tau|A(\tau,L)|= z$. Interestingly, from the knowledge of the LDT tails for a particular configuration of the parameters $\Delta$ and $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$ we can derive the LDT tails for any combination of $\Delta$ and $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$, using only analytical transformations. This is possible thanks to two properties: First, the scale invariance of the NLSE; second, the way the parameter $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$ appears in the cost function \eqref{eq:cost-waves}. Indeed the term $I(\theta)$ is independent of $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$, and from~\eqref{eq:ICFourier} the term $f(\Psi(\theta))$ can be seen as a function of $\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)}\theta$. \begin{figure} \centering \includegraphics[width=.5\linewidth]{fig10-a-scale-inv-evol}% \includegraphics[width=.5\linewidth]{fig10-b-scale-inv-pdf} \caption{The two panels show how knowledge of the LDT tail at the output point $L$ for a given $\Delta$ and $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$ allows us to recover the LDT tail for an arbitrary $\Delta'$, with the properly rescaled mean power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)'$, space $L'$, and time $\tau'$. Left: Instanton reaching $\max_{\tau\in\Gamma}|A(L,\tau)|=8.5$, for sets 3 and 4. Right: $\mathbb{P}(\max_\tau|A(L,\tau|)\ge z$ from MC sampling and tail estimate for Sets 3 and 4, at an equivalent rescaled output point $L$. Note that not only the probability tail is the same for the two sets, but also the entire distribution, as the scale invariance establishes a complete equivalence between two sets having the same value of the ratio $\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)}/\Delta$.} \label{fig:9} \end{figure} \begin{itemize}[leftmargin=.1in] \item Starting from the second property, we have that given a fixed spectral width $\Delta$ and a mean power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$, giving the cost function \eqref{eq:cost-waves} $E(\theta,\lambda)$, the cost function $E'(\theta,\lambda)$ associated to a new mean power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)'$ (but same spectral width) can be written as \begin{equation} E'(\theta,\lambda) = \frac{\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)}{\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)'} E(\theta',\lambda'), \quad \theta'=\theta\sqrt{\frac{\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)'}{\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)}}, \quad \lambda'=\lambda \frac{\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)'}{\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)}\,. \end{equation} Since $\lambda'$ is nothing but a rescaling of $\lambda$, and they are both arbitrary variables, $E$ and $E'$ represent actually the same landscape, just differing by a positive factor and a rescaling of the variables. This implies that if we know an instanton $\theta^\star(z)$ and its associated probability $P(z)$ for the mean power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$, we also know that for mean power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)'$ the same event will have instanton $\theta'^\star(z)=\theta^\star(z)\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)'/\mathbb{E}}\def\mathbb{P}{\mathbb{P} (P)}$ with associated probability \begin{equation}\label{eq:LDTgen1} P'(z)= P(z)^{\frac{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)}{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)'}}\,. \end{equation} Thus, keeping $\Delta$ fixed, the LDT tails for a given $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)$ are sufficient to generate the LDT tails for any mean power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)'$, using \eqref{eq:LDTgen1}. \item Using the scale invariance of the NLSE, it is possible to make a similar argument to extend the LDT tails to arbitrary $\Delta$. Knowing that initial conditions with the same ratio $\sqrt{\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)}/\Delta$ are scale invariant for the NLSE, one can pick an arbitrary spectral width $\Delta'$. This gives a new mean power $\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)'=\mathbb{E}}\def\mathbb{P}{\mathbb{P}(P)(\Delta'/\Delta)^2$, and allows us to compute the new length $L'=(\Delta/\Delta')^2 L$ and time coordinate $\tau'=(\Delta/\Delta')\tau$. Thus, a bijection is established between the two parameter sets, where each pair is characterized by the same non-dimensional instanton and same probability. Hence, knowing the LDT tails at different $L$ for one value of the spectral width, one is able to obtain the whole spatial transient of the LDT tails for an arbitrary spectral width. In Fig.~\ref{fig:10} the invariance of the non-dimensional instanton and of the LDT tail is shown for Sets 3 and 4, which yield the same dynamics once the appropriate rescaling is performed. \end{itemize} \begin{figure} \centering \includegraphics[width=.8\linewidth]{fig11-a-inst-per-evol} \caption{Snapshots at increasing spatial coordinate from left to right ($\xi=0$, $\xi=0.1$, $\xi=0.2$) of instantons reaching the same peak intensity, for the three sets of parameters with different spectral width: Set 1 ($\Delta=\pi$) in red; Set 2 ($\Delta=\pi/2$) in green; and Set 3 ($\Delta=3\pi/2$) in blue. The PS reaching the same final height (at the point of maximal focusing) is also plotted in black. For all the profiles, striking agreement is observed around the point of maximal focusing in space-time, while significant differences are observed away from that point.} \label{fig:10} \end{figure} Figs.~\ref{fig:6} and~\ref{fig:8} confirm that the high-power pulses arising spontaneously from a random background tend to the shape of the PS around its maximum space-time concentration~\cite{tikan2017universality}. Interpreting this in light of the gradient-catastrophe regularization~\cite{bertola2013universality}, it is clear that such characteristic shape of the extreme power amplifications is independent of the solitonic content of the field, although it is shared with the local behavior of an exact solitonic solution. The random extreme realizations quickly diverge from the PS away from the maximum, however. In contrast, the instantons characterize all the essential dynamics of the extreme events in integrable turbulence. They give an approximation of the extreme excursions that is much more accurate than the PS, as can be observed in Fig.~\ref{fig:8}, and their shape adapts to the size of the event. In addition, unlike the PS, they come with probabilistic information and allows the estimation of the distribution tail, as seen in Fig.~\ref{fig:7}, with mathematical justification in the LDT result~\eqref{eq:13b}. Furthermore, the instantons depend on the statistical state of the random background, as shown in Fig.~\ref{fig:10}, while the PS is always the same. Because of these properties and their connection with the gradient catastrophe (which is their generating mechanism), the instantons can be important objects for further investigations in integrable turbulence. In this context, recent results~\cite{PNAS2018rogue} suggest that the formation of extreme coherent structures may not necessarily be linked to integrability, but may pertain to a more general class of systems with instabilities (e.g.~due to non-resonant interactions) leading to spatio-temporal concentration phenomena. \section{Conclusions} \label{sec:conclusions} We have shown that tools and concepts from large deviation theory (LDT), combined with optimization tools from optimal control, can be used to analyze rare events in the context of dynamical systems subject to random input in their parameters and/or their initial conditions. In our examples, the predictions from LDT were actually valid in a wide region of parameter space. This means that the large deviation regime is attained for events that are rare but still quite frequent, and extend down to extremely low probabilities, exploring regions unattainable through brute-force MC sampling. In addition, the instantons provide us with information about the mechanism of the events that can only be extracted from MC sampling via non-trivial filtering. Under this light, the LDT method stands as a competitive alternative, or at least a useful complement, to brute-force MC. \section*{Acknowledgment} We thank Georg Stadler for useful comments regarding the optimization method, and Gilles Francfort for suggesting the elastic rod application. We are also grateful to Lamberto Rondoni, Themis Sapsis, Freddy Bouchet, Hugo Touchette and Pierre Suret for interesting discussions.
\section{Introduction} Nuclear reactors are an intense man-made source of electron antineutrinos and were used for the first observation of the neutrino~\cite{Cowan:1992xc}. Electron antineutrinos can be detected through inverse beta decay (IBD) on target protons, where a prompt positron and a delayed neutron capture signals are measured in time coincidence. Since the early 2000s, the energy and baseline (the distance between source and detector) dependent neutrino disappearance at nuclear reactors~\cite{Eguchi:2002dm, An:2012eh, Ahn:2012nd} has provided strong evidence of neutrino oscillation~\cite{Pontecorvo:1957cp, Pontecorvo:1967fh, Maki:1962mu}. However, a recent re-evaluation of the theoretical prediction (referred to as Huber-Mueller model~\cite{Huber, Mueller}) of the reactor neutrino flux resulted in a $\sim$6\% deficit in measured flux from short-baseline experiments~\cite{Mention:2011rk} and the previous ILL-Vogel model~\cite{ILL1, ILL2, ILL3, Vogel}. The difference between the data and Huber-Mueller prediction, i.e.~the so-called ``reactor antineutrino anomaly'' (RAA), could be interpreted as active-to-sterile neutrino oscillation with a mass-squared splitting ($\Delta m^2$) around 1~eV$^2$. It is also shown in Refs.~\cite{Kopp:2011qd, Kopp:2013vaa, Giunti:2013aea} that the allowed parameter space is compatible with earlier anomalies from LSND~\cite{Athanassopoulos:1997pv, Aguilar:2001ty}, MiniBooNE~\cite{AguilarArevalo:2010wv}, GALLEX~\cite{Hampel:1997fc}, and SAGE~\cite{Abdurashitov:2009tn}. On the other hand, a number of authors~\cite{Giunti, Dentler, Giunti2, Gebre} have argued that the RAA may be due to the theoretical uncertainties in the flux calculations. Recent antineutrino flux evolution results from Daya Bay are in tension with the sterile-neutrino-only explanation of RAA~\cite{An:2017osx}. The uncertainty of the reactor antineutrino flux in our previous measurement~\cite{An:2017osx} is dominated by the uncertainty of neutron detection efficiency. The neutron detection efficiency was determined to be $\varepsilon_{n}=(81.83\pm1.38)\%$~\cite{An:2015nua, An:2016srz}, and the ratio with respect to the total uncertainty is $\sigma_{\varepsilon_{n}}^2/\sigma_{total}^2=65\%$. To further elucidate the RAA situation, this work presents an updated flux measurement from Daya Bay using the same 1230-day data set, but with a more precise determination of the neutron detection efficiency. Key improvements include an elaborated neutron calibration campaign covering a wide range of neutron energy and positions, an improved simulation with different physics models, and a data-driven correction to the neutron efficiency. This paper is organized as follows. In Sec.~\ref{sec:method}, we explain the general method to measure reactor neutrino yield, and highlight our approach here to improve its estimate. Sec.~\ref{sec:analysis} discusses the neutron calibration campaign and the analysis of calibration and simulation data. In Sec.~\ref{sec:result} we present an improved reactor antineutrino flux measurement and a comparison with the world data and theoretical models. \section{Method} \label{sec:method} \subsection{Overview of procedure} The Daya Bay experiment has four near and four far identically designed antineutrino detectors (ADs), located at different baselines (360~m--1900~m)~\cite{An:2015qga} measuring the electron antineutrino flux from six reactor cores. The structure of the detector is shown in Figure~\ref{fig:det}. Each AD consists of a cylindrical target volume with 20 tons of 0.1\% gadolinium loaded liquid scintillator (GdLS, 3.1 m in diameter and 3.1 m in height), surrounded by a layer of 42-cm thick liquid scintillator (LS) to enclose the gammas or electrons escaped from the central GdLS region. The GdLS and LS are separated by a 1-cm thick acrylic vessel. An energy deposit in the GdLS and LS regions is detected by photomultiplier tubes (PMTs). The origin of the coordinate system is set at the geometrical center of the GdLS cylinder, with the $z$-axis pointing up. IBD neutrons are detected by delayed capture either on hydrogen emitting one 2.2 MeV gamma or on gadolinium emitting several gammas with total energy of about 8 MeV. The kinetic energy of the IBD neutrons is less than 50 keV. The average capture time in the GdLS region is about 28.5~$\mu$s and 216~$\mu$s in the LS~\cite{nHlong}. \begin{figure}[] \centering \includegraphics[width=0.4\textwidth]{AD_structure.pdf} \caption{Schematic diagram of the Daya Bay antineutrino detector. On the top, three automated calibration unit (ACU-A, B, and C), are installed. The three related vertical calibration axes are shown as the dashed lines, with all the locations of the calibration points highlighted.} \label{fig:det} \end{figure} The reactor antineutrino IBD candidates are selected with the same criteria as in Ref.~\cite{An:2016ses}, which are also described here. 1) Removal of events caused by PMT light emission. 2) The time between the prompt and delayed signal is in the range of [1, 200]~$\mu$s. 3) Prompt signal must have a reconstructed energy, E, between 0.7 and 12 MeV. 4) Delayed signal must have E between 6 and 12 MeV to select gadolinium captures. 5) Muon anti-coincidence. 6) Multiplicity cut to remove events with E $>$ 0.7 MeV in the interval 200 $\mu$s before the prompt signal, 200 $\mu$s after the delayed signal, or between the prompt and delayed signals. The dominant backgrounds are accidental coincident events and cosmic-ray muon induced $^9$Li/$^8$He, which are less than 2\% of the signal IBD rate for the four near ADs. After statistical subtraction of background, the total number of IBD signals, $N_{\text{IBD}}$, is $2.201\times10^6$ for the four near detectors. To compare to the theoretical predictions, the reactor antineutrino yield $\sigma_f$, defined as the number of antineutrinos times IBD cross-section per fission, can be calculated by solving the following equation: \begin{equation} \label{eq:yieldcal} N_{\text{IBD}}(1-c^{\rm{SNF}}) = \sigma_f \sum_{d=1}^4\sum_{r=1}^6\frac{N_d^P \varepsilon_{\text{IBD}}P_{sur}^{rd} N_r^f}{4\pi L_{rd}^2}, \end{equation} where the index $d$ is for four near detectors, index $r$ is for the six reactor cores, $N_d^P$ is the number of target protons of detector $d$, $\varepsilon_{\text{IBD}}$ is the IBD detection efficiency, $P_{sur}^{rd}$ is the mean neutrino survival probability from the reactor $r$ to detector $d$, $N_r^f$ is the predicted number of fissions of the $r$th reactor core, $L_{rd}$ is the distance from reactor $r$ to detector $d$, and $c^{\text{SNF}}$ is a correction term for spent nuclear fuel. $P_{sur}^{rd}$ is calculated by integrating the cross-section-weighted oscillation survival probability over the $\bar{\nu}_e$ energy spectrum, using $\sin^22\theta_{13}$ and $|\Delta m_{ee}^2|$ determined from the same data~\cite{An:2016ses}. The average oscillation correction for near detectors is 1.5\%. The IBD detection efficiency is divided into two factors: \begin{equation} \label{eq:eff_IBD} \varepsilon_{\rm{IBD}} = \varepsilon_n \times \varepsilon_{\rm{other}}, \end{equation} where $\varepsilon_n$ is the neutron selection efficiency due to the [6, 12] MeV cut and $\varepsilon_{\rm{other}}$ is for the PMT light emission, prompt energy, and coincident time cuts. The predicted number of fissions of the $r$th reactor core is \begin{equation} \label{eq:Nfission} N_r^f = \int\frac{W_r}{\sum_{iso=1}^4 f_r^{iso} E^{iso}}{\rm{d}}t, \end{equation} where $W_r$ is the thermal power of the $r$th core, $E^{iso}$ is the mean energy released per fission for each isotope, and $f_r^{iso}$ is the average fission fraction of the $r$th core for each isotope, and the ratio is integrated over the live time of the detectors. The original thermal power and fission fuel composition data are provided by the power plant. $c^{\text{SNF}}$ was estimated to be $(0.3\pm0.3)\%$ previously~\cite{An:2016srz}. Different components of relative uncertainties for the antineutrino yield measurement from previous work~\cite{An:2015nua, An:2016srz}, including $\varepsilon_n$ and $\varepsilon_{\rm{other}}$, are summarized in Table~\ref{tab:Effi}. Clearly $\varepsilon_n$ dominates the uncertainty, and is the target of improvement in this paper. \begin{table}[] \centering \caption{Summary of relative uncertainties for the flux measurements and the measured flux to model prediction ratio measurements in our previous study~\cite{An:2016srz} and this work. Central values of the detector efficiencies, $\varepsilon_n$ and $\varepsilon_{\rm{other}}$, are also listed.} \label{tab:Effi} \begin{tabular}{lcccc} \hline\hline & \multicolumn{2}{c}{Previous} & \multicolumn{2}{c}{This work} \\ source & value & rel. err. & value & rel. err. \\ \hline statistic &- & 0.1\% & - & 0.1\% \\ oscillation &- & 0.1\% & - & 0.1\% \\ target proton &- & 0.92\% & - & 0.92\% \\ reactor \\ \hspace*{0.5cm} power &- & 0.5\% &- & 0.5\% \\ \hspace*{0.5cm} energy/fission &- & 0.2\% &- & 0.2\% \\ \hspace*{0.5cm} IBD cross section&- & 0.12\%&- & 0.12\%\\ \hspace*{0.5cm} fission fraction &- & 0.6\% &- & 0.6\% \\ \hspace*{0.5cm} spent fuel &- & 0.3\% &- & 0.3\% \\ \hspace*{0.5cm} non-equilibrium &- & 0.2\% &- & 0.2\% \\ $\varepsilon_{\rm{IBD}}$ \\ \hspace*{0.5cm} $\varepsilon_n$ & 81.83\% & 1.69\% & 81.48\% & 0.74\% \\ \hspace*{0.5cm} $\varepsilon_{\rm{other}}$ & 98.49\% & 0.16\% & 98.49\% & 0.16\% \\ \hline total & - & 2.1\% & - & 1.5\% \\ \hline\hline \end{tabular} \end{table} \subsection{Principle of improvement} The neutron detection efficiency, $\varepsilon_n$, is composed of three individual factors. \begin{itemize} \item The Gd capture fraction is the fraction of neutrons produced by IBD in the GdLS target that are captured on Gd. The capture fraction is lower at the edge of GdLS volume because neutrons may drift into un-doped LS volume (spill-out effect). \item The nGd gamma detection efficiency is the fraction of neutron Gd capture signals with detected gamma energy above 6 MeV. \item Spill-in: efficiency increase due to IBD events produced in the LS and acrylic but with neutron capture on Gd. \end{itemize} We note that the estimation of Gd capture fraction and spill-in effects are strongly correlated since they are both driven by the modeling of neutron propagation including neutron scattering in materials and the subsequent nuclear capture. The estimation of the nGd gamma detection efficiency depends on the modeling of gamma emission including the multiplicity and energy spectrum of the emitted gammas. In the previous study~\cite{An:2016srz}, we attempted to use different neutron calibration data to estimate these individual effects. The main difficulty was that no data can cleanly separate their uncertainties. In this paper, instead, we evaluate $\varepsilon_n$ and its uncertainty directly using a new neutron calibration data set and a data-simulation comparison. This approach is data driven and allows a significant reduction of the uncertainty. \section{Improved Detection Efficiency Estimation} \label{sec:analysis} \subsection{Neutron calibration campaign} An extensive neutron calibration campaign was carried out in Daya Bay at the end of 2016. Two types of custom sources were fabricated, $^{241}$Am-$^{13}$C (AmC, neutron rate $\sim$ 100 Hz)~\cite{Liu:2015cra} and $^{241}$Am-$^9$Be (AmBe, neutron rate $\sim$ 30 Hz). They produce neutrons through $^{13}$C($\alpha$, n)$^{16}$O or $^{9}$Be($\alpha$, n)$^{12}$C reactions with the final nucleus either in the ground state (GS) or excited state (ES). The kinetic energy of the neutrons from AmC (AmBe) in the GS and ES are [3, 7] MeV ([6, 10] MeV) and $<$1 MeV ([2, 6] MeV), respectively. Calibration events are formed from the prompt energy of the proton recoil and deexcitation gammas, if $^{16}$O$^*$ or $^{12}$C$^*$ is created, and the delayed neutron capture. The high neutron rate and delayed-time-coincidence present a high signal-to-background ratio for the calibration study. The sources, sealed in a small stainless steel cylinder (8 mm in both diameter and height), were enclosed in a highly reflective PTFE (Polytetrafluoroethylene) shell. These sources were deployed vertically into a near-site AD using the automated calibration units (ACUs)~\cite{Liu:2013ava} along the central axis (ACU-A), an edge axis of GdLS at a radius of 1.35~m (ACU-B), and through a middle axis of the LS layer at a radius of 1.77~m (ACU-C). During deployment, the absolute precision of the source $z$ location is 7~mm~\cite{Liu:2013ava}. All calibration positions are illustrated in Figure~\ref{fig:det}. In total, data in 59 different source (final nucleus states) and location points (SLPs), were collected. Delayed coincidence events for the calibration sample are selected with a time requirement of $1~\mu\rm{s} <\Delta t < 1200~\mu\rm{s}$ for all events with E between $[0.3, 12]~\rm{MeV}$. The $1200~\mu\rm{s}$ selection cut is set to efficiently include neutron captures in the LS and acrylic region. Two example distributions of the prompt-delay energies of AmC (ACU-B $z$=0 m) and AmBe (ACU-B $z$=0 m) samples are shown in Figure~\ref{fig:AmC} and Figure~\ref{fig:AmBe}, respectively. The data in different channels are selected using the following prompt energy cut: $[0.3, 4]~\rm{MeV}$ for AmC GS, $[5.5, 7]~\rm{MeV}$ for AmC ES, $[1, 4]~\rm{MeV}$ for AmBe GS, and $[4.2, 7]~\rm{MeV}$ for AmBe ES. The accidental background contributes 0.1--20\% of the neutron candidates depending on the SLP, and is estimated by randomly paired single events~\cite{nHlong}. The reactor antineutrino and cosmogenic backgrounds are estimated by applying the same selection cuts on the data acquired immediately before and after the calibration campaign. They contribute $<$0.1\% to the neutron source signals. All of these backgrounds are statistically subtracted. \begin{figure}[h!] \centering \includegraphics[width=0.4\textwidth]{hEpEdAcc_AmC_ACUB_Z0000v1.pdf} \caption{The prompt vs.~delayed energy distribution of one AmC sample (ACU-B $z$=0 m). The selected ground state (GS) and excited state (ES) are indicated. The clusters in the prompt energy spectrum between [4, 5.5] MeV are caused by $^{12}$C(n,n$\gamma$)$^{12}$C, and are not used. Negative bin content is due to background subtraction.} \label{fig:AmC} \includegraphics[width=0.4\textwidth]{hEpEdAcc_AmBe_ACUB_Z0000v1.pdf} \caption{The prompt vs.~delayed energy distribution of one AmBe sample (ACU-B $z$=0 m). The selected ground state (GS) and excited state (ES) are indicated. Negative bin content is due to background subtraction.} \label{fig:AmBe} \end{figure} \subsection{Neutron and gamma modeling in simulation} The neutron calibration data were compared to the model predictions obtained using the Geant4-based~\cite{Agostinelli:2002hh} (v4.9.2) Daya Bay Monte Carlo (MC) simulation framework NuWa~\cite{An:2012eh, An:2015qga} with improvements to the calibration pipe geometry, detector energy response, and neutron transport modelling~\footnote{ An error in neutron propagation was corrected. Details can be found in \url{https://bugzilla-geant4.kek.jp/show_bug.cgi?id=1856}. We replaced the G4UHadronElasticProcess with G4HadronElasticProcess to correct the error, and the IBD selection efficiency increased by 0.3\%.}. These modifications improve the agreement between the neutron calibration data~\cite{An:2016ses} and simulation. Neutrons lose energy through various scattering processes before capture on a nucleus. There are no scattering models in Geant4 for the Daya Bay scintillator (average hydrogen-to-carbon ratio CH$_{1.61\sim1.64}$) or acrylic (C$_5$O$_2$H$_8$). Above 4 eV, a generic Geant4 model, ``G4NeutronHPElastic'' can be selected for neutron simulation. Below 4 eV, three possible options from the Geant4 data libraries are an elastic scattering model without molecular bonds (``free gas''), a water model (H$_2$O), and a polyethylene model (CH$_2$, ``poly'')~\cite{Agostinelli:2002hh}. The latter two models are built based on the ENDF database~\cite{Chadwick:2011xwu} and are quite different from the free gas model. The total scattering cross-section as a function of energy for the three models is shown in Figure~\ref{fig:neutron}. To approximate the Daya Bay (scintillator, acrylic) material pair, five combinations (Table~\ref{tab:models}) of models were studied, including a) (water, free gas) b) (water, poly), c) (poly, poly), d) (poly, free gas), and e) (free gas, free gas). \begin{figure}[] \centering \includegraphics[width=0.45\textwidth]{cross_section_large.pdf} \caption{Total scattering cross-section as a function of neutron kinetic energy for three models. The data are extracted from Geant4 simulation.} \label{fig:neutron} \end{figure} For the neutron capture gamma energy and multiplicity distributions, four different models (Table~\ref{tab:models}) were selected, including 1) a native Geant4 model, 2) a Geant4 model with the photon evaporation process, 3) a model based on the Nuclear Data Sheets by L.~Groshev~{\it{et al.}}~\cite{groshev1968compendium}, and 4) a model based on the measured single gamma distribution of nGd capture at Caltech~\cite{An:2016srz}. The energy spectra of the deexcitation gammas of gadolinium-155 and 157 are shown in Figure~\ref{fig:gamma155} and Figure~\ref{fig:gamma157}, respectively, for these models. The gamma model-3 has the hardest gamma spectra. \begin{figure}[] \centering \subfigure[$^{155}$Gd] { \label{fig:gamma155} \includegraphics[width=0.47\textwidth]{Gd155_gammas.pdf} } \subfigure[$^{157}$Gd] { \label{fig:gamma157} \includegraphics[width=0.47\textwidth]{Gd157_gammas_v2.pdf} } \caption{Energy distribution of the deexcitation gammas of $^{155}$Gd (a) and $^{157}$Gd (b) for the four models as indicated in the legend.} \end{figure} The 20 available combinations provided by the five neutron scattering model combinations (a-e) and the four gamma models (1-4) are used to estimate $\varepsilon_n$. Model a-1 was used in the previous analyses~\cite{An:2016ses, An:2016srz}. \begin{table*}[] \centering \caption{Summary of five neutron scattering model combinations and four gamma models, including the efficiency for detecting inverse beta decay neutrons and the $\chi^2$ with 59 calibration source-location points. See text for details.} \label{tab:models} \begin{tabular}{lllll} \hline\hline $\varepsilon_n$,$\chi^2$ & 1. Geant4 native & 2. Geant4 Phot. Eva. & 3. Nuclear Data Sheets & 4. Caltech \\ \hline a. water, free gas & 82.23\%, 76.0 & 82.35\%, 86.4 & 80.56\%, 316 & 82.55\%, 156 \\ b. water, poly & 81.75\%, 52.1 & 81.93\%, 85.1 & 80.42\%, 350 & 82.43\%, 119 \\ c. poly, poly & 81.61\%, 56.6 & 82.00\%, 63.9 & 79.96\%, 389 & 82.00\%, 96.9 \\ d. poly, free gas & 82.01\%, 57.7 & 82.28\%, 79.9 & 80.28\%, 371 & 82.36\%, 115 \\ e. free gas, free gas & 84.76\%, 1183 & 84.65\%, 1273 & 82.70\%, 576 & 85.37\%, 1569 \\ \hline\hline \end{tabular} \end{table*} \subsection{Data and simulation comparison} For each calibration SLP, a ratio $F$ is calculated. \begin{equation} \label{eq:F_ratio} F=\frac{N([6,12]~\text{MeV})}{N([1.5,12]~\text{MeV})}\ , \end{equation} where $N([6,12]~\text{MeV})$ and $N([1.5,12]~\text{MeV})$ are the numbers of events with reconstructed delayed energy in the range of $[6,12]~\text{MeV}$ and $[1.5,12]~\text{MeV}$, respectively. 1.5~MeV is chosen to include the hydrogen capture peak. $F$ is very sensitive to the relative strength of H vs.~Gd capture peaks and the containment of the 8~MeV of gamma energy from nGd capture, and therefore provides a crucial benchmark for the neutron and gamma simulation models. For the 59 calibration SLPs, a $\chi^2$ is constructed to measure the overall difference between data and MC predictions, \begin{equation} \label{eq:chi2} \chi^2=(F_{\rm{data}}-F_{\rm{MC}})^T\cdot V^{-1}\cdot(F_{\rm{data}}-F_{\rm{MC}}), \end{equation} where $(F_{\rm{data}}-F_{\rm{MC}})$ is a vector with 59 elements of the difference of $F$ between the data and MC, and $V$ is the covariance matrix. For most of the calibration points, the statistical uncertainty is dominant, but for the points near a GdLS boundary (ACU-A top, ACU-A bottom, ACU-B top, or ACU-B bottom), the distance to the acrylic and LS volume is comparable to the neutron drift distance, so they share a large common uncertainty due to the source location $z$ uncertainty. The $\chi^2$ and $\varepsilon_n$ values for all models are shown in Table~\ref{tab:models}. The eight combinations with either neutron model-e or gamma model-3 are discrepant ($\chi^2>300$), and therefore are excluded. The remaining twelve (4$\times$3) models agree with the data reasonably well with $\chi^2$ in the range of 52.1--156 (``reasonable models''). The best model with minimum $\chi^2$ is model b-1. In Figure~\ref{fig:spectrum}, the delayed energy spectra at two boundary calibration locations from data are compared to models b-1 and e-1, where model b-1 shows a better agreement with data for $F$. \begin{figure}[] \centering \subfigure[AmBe excited state at $r$=1.35~m and $z$=-1.35~m] { \label{fig:CalibSpec1} \includegraphics[width=0.45\textwidth]{Fig6a_0_1MeV.pdf} } \subfigure[AmC ground state at $r$=1.77~m and $z$=0~m] { \label{fig:CalibSpec} \includegraphics[width=0.45\textwidth]{Fig6b_0_1MeV.pdf} } \caption{Delayed energy spectra of neutron sources at two calibration locations for data and simulation and the corresponding residual plots (MC-data). Two MC models, b-1 (best fit) and e-1 (rejected), are overlaid. Normalization is determined using the integral between 1.5 and 12 MeV. The difference of relative gadolinium/hydrogen capture ratio between sub-figure (a) and (b) is due to the relative position to the GdLS volume. In (b), a weak signal of neutron capture on carbon can be seen. In (b), a mismatch of the energy scales of data and MC at nH peak is observed, but our selection cut efficiency is not sensitive to the difference.} \label{fig:spectrum} \end{figure} The data and best MC $F$ values and their differences are shown explicitly in Figure~\ref{fig:F_comp} for all sources and locations. The systematic variations among the twelve reasonable models are overlaid, where the full spread among them, maximum minus minimum, are plotted as the gray bars. The variation in $F$ from 1 to 85\% for the 59 data points is due to the differences in the local geometry and neutron kinetic energy and is well reproduced by simulation. For most points, the best MC model, b-1, reaches an agreement with data at the sub-percent level, and the residual difference is mostly smaller than the model spread. Another quantity, $F^{\prime}=N([3,4.5]~\text{MeV})/N([3,12]~\text{MeV})$, is also constructed, which is also sensitive to the gamma model and energy leakage. The same data-model comparison procedure confirms that gamma model 3 should be rejected and that gamma model 1 is reasonable. \begin{figure}[] \centering \includegraphics[width=0.5\textwidth]{v2CompareAllForF.pdf} \caption{ Upper panel: The measured and best MC model (b-1) values of $F$ for AmC and AmBe (ground and excited states) neutrons at three calibration axes and different $z$ positions. The model spread of $F$, maximum minus minimum, for each source-location point are also shown. The results at $z$=-1.45~m and -1.6~m are plotted together as are 1.5 m and 1.6 m. Lower three panels: The difference of data and best MC in $F$ along the three vertical calibration axes, with the data and MC uncertainties combined. The gray bars indicate the spread of the twelve reasonable MC models relative to the best model.} \label{fig:F_comp} \end{figure} To further investigate potential effects due to the discreteness of the calibration sources and the energy difference between neutron sources and IBD neutrons, we exploited a large sample of IBDs from data as a special SLP to be compared to the model prediction. Due to the resolution in position reconstruction, selection of pure GdLS IBDs is impossible. Instead, a GdLS+LS IBD sample from all four near site ADs were selected using cuts identical to those used on the neutron calibration data (Sec. III-A), except that the prompt energy cut was adjusted to be greater than 3.5~MeV to suppress accidental background. About 2 million GdLS+LS IBD events in total were selected. The measured ratio $F$ is consistent AD to AD with an average of 47.1\%$\pm$0.1\%. The ratio from model b-1 is 47.0\%, and the full model spread is from 46.7\% to 47.5\%. \subsection{Neutron detection efficiency determination} Each model can give a prediction on $\varepsilon_n$ for IBDs (see Table~\ref{tab:models}). For the twelve reasonable models, $\varepsilon_n$ ranges from 81.61\% (model c-1) to 82.55\% (model a-4), and that from model b-1 is 81.75\%. Instead of taking the prediction as is, one can translate the data and MC difference in $F$ to a correction to $\varepsilon_n$, since the two are intrinsically correlated (linear to the lowest order) through the neutron and gamma models mentioned above. In mathematical form, for the $i$th SLP, we have \begin{equation} \varepsilon_{n} = c_i \cdot (F_{\rm{data},i}-F_{\rm{MC,best},i}) + \varepsilon_{\rm{MC,best}}, \label{eq:line_reg} \end{equation} where $\varepsilon_{\rm{MC,best}}$ is the neutron detection efficiency given by the best MC model. $c_i$ characterizes the linear correlation between $F_i$ and $\varepsilon_n$, and can be estimated through a linear regression (fit) using predicted values of $\varepsilon_{n}$ and $F_i$ from all 20 MC models. This procedure is illustrated in Figure~\ref{fig:lineFit}. \begin{figure}[] \centering \subfigure[AmBe excited state at $r$=1.35~m and $z$=0~m] { \label{fig:fit1} \includegraphics[width=0.45\textwidth]{NewAmBe_ACUB_0_ES_Fit-1.pdf} } \subfigure[AmBe excited state at $r$=0~m and $z$=-0.75~m] { \label{fig:fit2} \includegraphics[width=0.45\textwidth]{NewAmBe_ACUA_minus75_ES_Fit.pdf} } \caption{$F-F_{\rm{MC,best}}$ vs.~$\varepsilon_n-\varepsilon_{\rm{MC,best}}$ for the 20 MC models at two example SLPs. The vertical dashed line and the shaded band indicates the mean and uncertainty of measured $F$ with data. The vertical intercept of the linear fit passing through the best MC model (solid blue line) with the vertical dashed line gives the corrected value of $\varepsilon_n$.} \label{fig:lineFit} \end{figure} The eight rejected models were also included here by default as larger variations in $\varepsilon_n$ and $F$ are allowed. Excluding them from the fit does not change the result (See Figure~\ref{fig:lineFit} for an example). In addition to $\varepsilon_{n}$ determined from 59 individual SLPs, a multiple regression procedure was also applied to model the linear relation between $\varepsilon_n$ and $F$ from a set of SLPs. Taking all values of corrected $\varepsilon_n$ into account, a shift of $-0.27\%$ with a standard deviation of 0.47\% was obtained, relative to that from the best model (81.75\%). The standard deviation of 0.47\% is consistent with the model spread on $\varepsilon_n$. Aside from the model uncertainties, other systematic effects (e.g. gadolinium abundance, source geometry, absolute energy scale, and material density variations) have been studied in the MC and found to be negligible. Based on the above discussions, the final IBD neutron efficiency after the correction is $\varepsilon_n=((81.75-0.27)\pm0.60)\%=(81.48\pm0.60)\%$, where 0.60\% is conservatively estimated using the half-spread, 0.47\%, of $\varepsilon_n$ predicted by all reasonable models (listed in Table~\ref{tab:models}.) plus the statistical uncertainty from the MC, 0.12\% (absolute uncertainty). \section{Antineutrino yield and Comparison with Prediction} \label{sec:result} Using the new neutron detection efficiency $\varepsilon_n$ and Eq.~\ref{eq:eff_IBD}, the IBD detection efficiency $\varepsilon_{\rm{IBD}}$ is $(80.25\pm 0.61)\%$. Using the procedure as in Eq.~\ref{eq:yieldcal}, the mean IBD reaction yield per nuclear fission is \begin{equation} \sigma_f = (5.91\pm0.09)\times10^{-43}~\rm{cm}^2/\rm{fission}, \label{eq:final_yield} \end{equation} where the major uncertainties (Table~\ref{tab:Effi}) are from the target proton fraction 0.92\% (relative uncertainty), dominated by the hydrogen-to-carbon ratio due to instrumental uncertainty in the combustion measurements, and reactor-related uncertainty 0.90\% (relative uncertainty) due to reactor power and fission fractions. The ratio of the yield to the prediction of the Huber-Mueller (or ILL-Vogel) reactor model can be calculated. The effective fission fractions for four fission isotopes are defined as \begin{equation} \label{eq:EffFissFrac} f_{iso} = \sum_{d=1}^4 \sum_{r=1}^6\frac{N_d^PP_{sur}^{rd}N_r^{f,iso}}{L_{rd}^2}\ /\ \sum_{d=1}^4 \sum_{r=1}^6\frac{N_d^PP_{sur}^{rd}N_r^{f}}{L_{rd}^2}, \end{equation} where $iso$ refers to one of the four major fission isotopes, i.e.~$^{235}$U, $^{238}$U, $^{239}$Pu, and $^{241}$Pu, $N_r^{f,iso}$ is the predicted number of fissions contributed by the $iso^{\rm th}$ isotope in the $r$th reactor core, and other symbols are defined in Eq.~\ref{eq:yieldcal}. In the analyzed data, the effective fission fractions for the four fission isotopes ($^{235}$U, $^{238}$U, $^{239}$Pu, and $^{241}$Pu) are determined to be (0.564, 0.076, 0.304, and 0.056), respectively. The predicted IBD yield is the sum due to all four isotopes, including corrections due to nonequilibrium effects, \begin{equation} \label{eq:YieldPred} \sigma_f=\sum_{iso=1}^4 f_{iso}\int (S_{iso}(E_{\nu})+k_{iso}^{\text{NE}}(E_{\nu})) \sigma_{\rm{IBD}}(E_{\nu}) {\rm{d}}E_{\nu}, \end{equation} in which $S_{iso}(E_{\nu})$ is the predicted antineutrino spectrum for each isotope given by Huber-Mueller or ILL-Vogel model, $\sigma_{\rm{IBD}}(E_{\nu})$ is the IBD cross section, and $k_{iso}^{\text{NE}}(E_{\nu})$ corrects for the non-equilibrium long-lived isotopes. The calculation integrates over neutrino energy $E_{\nu}$ and the non-equilibrium effect contributes $+$0.6\%~\cite{An:2016srz}. The ratio between the measured to predicted reactor antineutrino yield $R$ is $0.952\pm0.014\pm0.023$ (Huber-Mueller) and $1.001\pm0.015\pm0.027$ (ILL-Vogel), where the first uncertainty is experimental and the second is due to the reactor models themselves. A breakdown of the experimental uncertainties can be seen in Table~\ref{tab:Effi} (see also Ref.~\cite{An:2016srz}). The uncertainties from power, spent fuel, and non-equilibrium are treated to be uncorrelated among different reactor cores in the oscillation analysis~\cite{An:2016ses}, and those from fission fraction, IBD cross section, and energy/fission are treated to be correlated. They are conservatively treated as fully correlated in this analysis, and the total reactor-related uncertainty is 0.9\%. The total experimental uncertainty has been reduced to 1.5\%, which is a relative 29\% improvement on our previous study. The new flux measurement is consistent with the ILL-Vogel model, but differs by 1.8 standard deviations with respect to the Huber-Mueller model, with the uncertainty now dominated by the theoretical uncertainty. With the new result, a comparison with the other measurements is updated using the same method presented in Ref.~\cite{An:2016srz}. A summary figure is shown in Figure~\ref{fig:Ratio-average}. The Daya Bay new result on $R$ is consistent with the world data. The new world average of $R$ is $0.945\pm 0.007\ (\rm exp.) \pm 0.023\ (\rm model)$ with respect to the Huber-Mueller model. This more precise measurement further indicates that the origin of RAA is unlikely to be due to detector effects. \begin{figure}[] \centering \includegraphics[width=0.45\textwidth]{plot_RatiovsR.pdf} \caption{The ratio of measured reactor antineutrino yield to the Huber+Mueller theoretical prediction as a function of the distance from the reactor to detector. Each ratio is corrected for the effect of neutrino oscillation. The blue shaded region represents the global average and its 1$\sigma$ uncertainty. The 2.4\% model uncertainty is shown as a band around unity. The measurements at the same baseline are combined together for clarity. The Daya Bay measurement is shown at the flux weighted baseline (578 m) of the two near halls.} \label{fig:Ratio-average} \end{figure} \section{Summary} In summary, an improved antineutrino flux measurement is reported at Daya Bay with a 1230-day data set. The precision of the measured mean IBD yield is improved by 29\% with a significantly improved neutron detection efficiency estimation. The new reactor antineutrino flux is $\sigma_f = (5.91\pm0.09)\times10^{-43}~\rm{cm}^2/\rm{fission}$. The ratio with respect to predicted reactor antineutrino yield $R$ is $0.952\pm0.014\pm0.023$ (Huber-Mueller) and $1.001\pm0.015\pm0.027$ (ILL-Vogel), where the first uncertainty is experimental and the second is due to the reactor models. This yield measurement is consistent with the world data, and further comfirms the discrepancy between the world reactor antineutrino flux and the Huber-Mueller model. \section*{Acknowledgments} The Daya Bay Experiment is supported in part by the Ministry of Science and Technology of China, the U.S. Department of Energy, the Chinese Academy of Sciences, the CAS Center for Excellence in Particle Physics, the National Natural Science Foundation of China, the Guangdong provincial government, the Shenzhen municipal government, the China General Nuclear Power Group, the Research Grants Council of the Hong Kong Special Administrative Region of China, the Ministry of Education in Taiwan, the U.S. National Science Foundation, the Ministry of Education, Youth, and Sports of the Czech Republic, the Charles University Research Centre UNCE, the Joint Institute of Nuclear Research in Dubna, Russia, the NSFC-RFBR joint research program, the National Commission of Scientific and Technological Research of Chile, We acknowledge Yellow River Engineering Consulting Co., Ltd., and China Railway 15th Bureau Group Co., Ltd., for building the underground laboratory. We are grateful for the ongoing cooperation from the China Guangdong Nuclear Power Group and China Light~\&~Power Company.
\section{\label{sec:Introduction}Introduction} \selectlanguage{american \IEEEPARstart{S}{imultaneous}\foreignlanguage{english}{ wireless information and power transfer (SWIPT) in full-\textcolor{black}{duplex (FD) relaying networks has recently attracted a great deal of research attention. For instance, the authors in \cite{swiptFD14} considered a dual-hop FD SWIPT network with both amplify-and-forward (AF) and decode-and-forward (DF) relaying protocols equipped with a single antenna. Several analytical expressions of the achievable throughput were derived. Instead of the single-antenna relay, the authors in \cite{swiptFD15MIMO} extended the work in \cite{swiptFD14} to include multiple-input multiple-output (MIMO) FD relaying. Unlike \cite{swiptFD14} and \cite{swiptFD15MIMO}, which focused on Rayleigh fading channels, the work in \cite{RabieieeeTGCN1} analyzed the performance of a FD SWIPT system in indoor environments characterized by log-normal fading. The study in \cite{GalymFD} considered the outage probability of FD SWIPT networks over $\alpha-\mu$ fading channels. Furthermore, the authors in \cite{swiptFD17} studied physical layer security in FD two-way relaying for SWIPT. More specifically, AF relaying with multiple antennas and zero-forcing was deployed in this work. Other studies exploiting jamming signals for EH have recently appeared in \cite{EH_AN1,EH_AN2}. }} \selectlanguage{english \textcolor{black}{None of the aforementioned works considered FD energy-harvesting (EH)-enabled relay networks over generalized fading channels. In contrast, and motivated by this lack of analytical analysis, we present in this letter a thorough performance evaluation of FD EH-enabled relay networks over the generalized $\kappa$-$\mu$ fading channel. Specifically, DF and time-switching relaying (TSR) protocols are deployed at the relay. The motivations of our work come from the following two factors. Firstly, the $\kappa$-$\mu$ model is a small-scale fading model and is able to characterize the scattering cluster in homogeneous communication environments including Rice $\left(\kappa=k,\,\mu=1\right)$, Nagakami-$m$ $\left(\kappa\rightarrow0,\,\mu=m\right)$ and Rayleigh $\left(\kappa\rightarrow0,\,\mu=1\right)$ \cite{KappaMu13,KappaMu15,KappaMu16}. Secondly, FD communication allows devices to operate on the same frequency, which potentially doubles the spectral efficiency, and, because of this, FD has become a viable option for next generation wireless communication networks. Thus, the network studied herein is meaningful and valuable for consideration. } \textcolor{black}{The main contribution of this letter resides in deriving a novel unified analytical expression for the ergodic outage probability of the proposed system over the generalized $\kappa$-$\mu$ fading channel. In addition, closed-form expressions for the aforementioned special cases of the $\kappa$-$\mu$ fading scenario are presented. The derived expressions were used to investigate the impact of several system and fading parameters on the performance. Results show that the performance can be enhanced considerably as the fading parameters $\kappa$ and $\mu$ are increased. It is also shown that as the }loop-back interference, associated with FD relaying, increases the outage probability performance deteriorates drastically. \section{System Model\label{sec:System-Mode}} The considered system model consists of a source (S), a relay (R) and a destination (D). The end nodes are equipped wi\textcolor{black}{th a single antenna whereas R, based on DF, has two antennas operating in FD mode. It is assumed that there is no direct link between the end nodes due to severe shadowing and path-loss effect \cite{swiptFD14,swiptFD15MIMO,RabieieeeTGCN1,swiptFD17}; hence, all communication is accomplished over two phases. The S-to-R, R-to-D and loop-back interference channel coefficients, denoted as $h_{1}$, $h_{2}$ and $h_{3}$, are assumed to be independent but not necessarily identical following the $\kappa$-$\mu$ distribution with a probability density function (PDF) \begin{eqnarray} f_{Z_{i}}\left(z\right)=\Upsilon_{i}\,z^{\frac{\mu_{i}-1}{2}}\,\textrm{exp}\left(-\frac{\phi_{i}\,z}{\Omega_{i}}\right)I_{\mu_{i}-1}\left(2\mu_{i}\sqrt{\frac{\phi_{i}\,z}{\Omega_{i}}}\right),\label{eq:pdfKappa} \end{eqnarray} } \noindent \textcolor{black}{where $i\in\left\{ 1,2,3\right\} $, $Z_{i}=h_{i}^{2},$ $\Omega_{i}=\mathbb{E}\left[Z_{i}\right]$, $\phi_{i}=\mu_{i}\left(1+\kappa_{i}\right),$ $\Upsilon_{i}=\frac{\mu_{i}\left(1+\kappa_{i}\right)^{\frac{\mu_{i}+1}{2}}}{\textrm{exp}\left(\mu_{i}\kappa_{i}\right)\kappa_{i}^{\frac{\mu_{i}-1}{2}}\Omega_{i}^{\frac{\mu_{i}+1}{2}}}$, $I_{v}\left[\cdot\right]$ is the modified Bessel function of the first kind with arbitrary order $v$ \cite[Eq. 9.6.20]{BookAbramow72}, $\mu_{i}$ represents the number of the multipath clusters and $\kappa_{i}>0$ denotes the ratio between the total powers of the domain components and the scattered waves. The path-loss exponents for the S-to-R and R-to-D links are denoted by $\xi_{1}$ and $\xi_{2}$, respectively. It is assumed that perfect channel state information (CSI) is available at all receiving nodes. R has no power supply and operates by harvesting the RF signal coming from S. The energy used for information processing at R is negligible and hence all the harvested energy will be utilized to forward the source information. } \textcolor{black}{As mentioned earlier, the TSR protocol is used for EH at R, in which the time frame }$T$ is divided into two consecutive time slots: $\alpha T$ and $\left(1-\alpha\right)T$, which are used for EH and S-to-R / R-to-D information transmissions, respectively; where $0\leq\alpha\leq1$ is the EH time factor. For the sake of brevity, we omit the mathematical modeling of the received signals at R and D and present only the corresponding signal-to-noise ratios (SNRs). Readers may refer t\textcolor{black}{o \cite{swiptFD14,RabieieeeTGCN1} for m}ore details. The SNRs at R and D nodes are expressed respectively as \begin{equation} \gamma_{r}=\frac{P_{s}h_{1}^{2}}{P_{r}d_{1}^{\xi_{1}}h_{3}^{2}}=\frac{1}{\zeta h_{3}^{2}},\,\textrm{and}\label{eq:snrR} \end{equation} \begin{equation} \gamma_{d}=\frac{P_{r}h_{2}^{2}}{d_{2}^{\xi_{2}}\sigma_{d}^{2}}=\frac{\zeta P_{s}h_{1}^{2}h_{2}^{2}}{d_{1}^{\xi_{1}}d_{2}^{\xi_{2}}\sigma_{d}^{2}},\label{eq:snrD} \end{equation} \noindent where $P_{s}$ is the source transmit power, $P_{r}=\eta\alpha P_{s}h_{1}^{2}/\left(\left(1-\alpha\right)d_{1}^{\xi_{1}}\right)$ is the relay transmit power, $\eta$ is efficiency of the energy harvester, $\sigma_{d}^{2}$ is the noise variance at D, $\zeta=\frac{\eta\alpha}{1-\alpha}$, $d_{1}$ and $d_{2}$ are the S-to-R and R-to-D distances, respectively. The instantaneous capacity of the first and second links can be given by \begin{equation} C_{i}=\left(1-\alpha\right)\textrm{log}{}_{2}\left(1+\gamma_{i}\right),\quad i\in\left\{ r,\,d\right\} .\label{eq:C} \end{equation} With this in mind, the ergodic outage probability, which is defined as the probability that the instantaneous capacity falling below a certain threshold $\left(C_{th}\right)$, can be calculated as \begin{equation} P_{out}\left(C_{th}\right)=\Pr\left(\textrm{min}\left\{ C_{r},\,C_{d}\right\} <C_{th}\right).\label{eq:Pout-1} \end{equation} \section{\label{sec:Performance analysis}Performance Analysis } \vspace{2mm} In this section, we derive analytical expressions of the ergodic outage capacity in generalized $\kappa$-$\mu$ fading and its special cases. To begin with, we substitute (\ref{eq:snrR}) and (\ref{eq:snrD}) into (\ref{eq:C}) and then into (\ref{eq:Pout-1}), with some mathematical manipulations, to obtain \begin{equation} P_{out}\left(C_{th}\right)=\Pr\left(\textrm{min}\left\{ \frac{1}{\zeta Z},\,\frac{\zeta P_{s}W}{d_{1}^{\xi_{1}}d_{2}^{\xi_{2}}\sigma_{d}^{2}}\right\} <\upsilon\right),\label{eq:Pout-1-1} \end{equation} \noindent where $X=h_{1}^{2},$ $Y=h_{2}^{2}$, $Z=h_{3}^{2}$, $W=XY$ and $\upsilon=2^{\frac{Cth}{1-\alpha}}-1$. Because t\textcolor{black}{he random variables (RVs) $W$ and $Z$ are independent, we can calculate the probability in (\ref{eq:Pout-1-1}) as} \textcolor{black}{ \begin{equation} P_{out}\left(C_{th}\right)=1-\bar{F}_{Z}\left(\frac{1}{\zeta\upsilon}\right)\bar{F}_{W}\left(\frac{d_{1}^{\xi_{1}}d_{2}^{\xi_{2}}\sigma_{d}^{2}}{\zeta P_{s}}\upsilon\right).\label{eq:Poutfinal} \end{equation} } \noindent \textcolor{black}{where $\bar{F}_{Z}\left(\cdot\right)$ is the complementary cumulative distribution function (CCDF) of $Z$, which can be obtained by integrating (\ref{eq:pdfKappa}) with appropriate notation changes. In order to arrive at a tractable expression, we use the series representation of $I_{\mu_{3}-1}\left(\cdot\right)$ \cite[eq. 8.445]{book2}; that is } \textcolor{black}{ \begin{equation} I_{\mu_{3}-1}\left(2\Lambda\right)=\stackrel[q=0]{\infty}{\sum}\frac{1}{\Gamma\left(\mu_{3}+q\right)q!}\,\Lambda^{\mu_{3}-1+2q},\label{eq:Iv_series} \end{equation} } \noindent \textcolor{black}{where $\Lambda=\mu_{3}\sqrt{\kappa_{3}\left(1+\kappa_{3}\right)z}$ and $\Gamma\left(\cdot\right)$ is the Gamma function \cite[Eq. 8.310.1]{BookGrad2000}. } \textcolor{black}{Now, replacing (\ref{eq:Iv_series}) in (\ref{eq:pdfKappa}) and then integrating, we can express the cumulative distribution function (CDF) $F_{Z}\left(\upsilon\right)$ a}s \begin{eqnarray} F_{Z}\left(\upsilon\right)=\Upsilon_{3}\stackrel[q=0]{\infty}{\sum}\frac{\left(\mu_{3}\sqrt{\kappa_{3}\left(1+\kappa_{3}\right)}\right)^{\mu_{3}-1+2q}}{\Gamma\left(\mu_{3}+q\right)q!}\,I_{0},\label{eq:FZ} \end{eqnarray} \noindent where $b=\frac{1-\alpha}{\eta\alpha}$, $\Upsilon_{3}=\frac{\mu_{3}\left(1+\kappa_{3}\right)^{\frac{\mu_{3}+1}{2}}\kappa_{3}^{-\frac{\mu_{3}-1}{2}}}{\textrm{exp}\left(\mu_{3}\kappa_{3}\right)}$ and \begin{eqnarray} I_{0} & = & \stackrel[0]{\frac{b}{\upsilon}}{\int}z^{\mu_{3}+q-1}\textrm{ exp}\left(-\phi_{3}z\right)\textrm{d}z\nonumber \\ & \stackrel{\left(a\right)}{=} & \phi_{3}^{-\mu_{3}-q}\gamma\left(\mu_{3}+q,\frac{\phi_{3}b}{\upsilon}\right),\label{eq:I0} \end{eqnarray} \textcolor{black}{where $\gamma\left(\cdot,\cdot\right)$ is the lower incomplete Gamma function \cite[Eq. 8.350.1]{BookGrad2000}. Note that $\left(a\right)$ is obtained with the help of \cite[Eq. 3.351.1]{book2}. } Substituting (\ref{eq:I0}) into (\ref{eq:FZ}), along with some straightforward manipulations, yields \begin{eqnarray} F_{Z}\left(\upsilon\right)=\frac{1}{\textrm{exp}\left(\kappa_{3}\mu_{3}\right)}\stackrel[q=0]{\infty}{\sum}\frac{\left(\mu_{3}\kappa_{3}\right)^{q}}{\Gamma\left(\mu_{3}+q\right)q!}\gamma\left(\mu_{3}+q,\frac{\phi_{3}b}{\upsilon}\right).\label{eq:FZfinal} \end{eqnarray} \begin{defn} For any two independent RVs $U$ and $V$, the CDF of the product of them is defined as $P\left(UV\leq x\right)=\int F_{V}\left(\frac{x}{u}\right)f_{U}\left(u\right)\textrm{d}u$. Using this definition, we can determine the CDF of $W$ as \begin{equation} F_{W}\left(r\right)=\stackrel[0]{\infty}{\int}F_{X}\left(\frac{r}{u}\right)f_{Y}\left(u\right)\textrm{d}u,\label{eq:FX} \end{equation} where $f_{Y}\left(u\right)$ has the distribution as in (\ref{eq:pdfKappa}) and $F_{X}\left(\frac{r}{u}\right)$ can be obtained from (\ref{eq:FZfinal}) with the appropriate change of notations. With this in mind, (\ref{eq:FX}) can be expressed as{\small{} \begin{eqnarray} F_{W}\left(\upsilon\right)=\frac{\Upsilon_{2}}{\textrm{exp}\left(\kappa_{1}\mu_{1}\right)}\stackrel[n=0]{\infty}{\sum}\frac{\left(\kappa_{1}\mu_{1}\right)^{n}}{\Gamma\left(\mu_{1}+n\right)n!}\Biggl[\Gamma\left(\mu_{1}+n\right)I_{1}-I_{2}\Biggr],\label{eq:FW} \end{eqnarray} }where $\Upsilon_{2}=\frac{\mu_{2}\left(1+\kappa_{2}\right)^{\frac{\mu_{2}+1}{2}}\kappa_{2}^{-\frac{\mu_{2}-1}{2}}}{\textrm{exp}\left(\mu_{2}\kappa_{2}\right)}$, \begin{equation} I_{1}=\stackrel[0]{\infty}{\int}z^{\frac{\mu_{2}-1}{2}}\textrm{exp}\left(-\phi_{2}z\right)\,I_{\mu_{2}-1}\left(2\Delta_{2}\sqrt{z}\right)\textrm{d}z, \end{equation} \begin{equation} I_{2}=\stackrel[0]{\infty}{\int}z^{\frac{\mu_{2}-1}{2}}\textrm{exp}\left(-\phi_{2}z\right)I_{\mu_{2}-1}\left(2\Delta_{2}\sqrt{z}\right)\Gamma\left(\mu_{1}+n,\frac{\phi_{1}\upsilon}{az}\right)\textrm{d}z, \end{equation} \end{defn} \noindent \textcolor{black}{$\Delta_{2}=\mu_{2}\sqrt{\kappa_{2}\left(1+\kappa_{2}\right)}$, $a=\frac{\eta\alpha P_{s}}{\left(1-\alpha\right)d_{1}^{m}d_{2}^{m}\sigma_{d}^{2}}$ and $\Gamma\left(\cdot,\cdot\right)$ indicates the upper incomplete Gamma function \cite[Eq. 8.350.2]{BookGrad2000}.} \textcolor{black}{To the best of the authors' knowledge, there is no analytical solution for the integral $I_{1}$. Hence, to solve this integral, we use the infinite series representation of $I_{\mu_{2}-1}\left(\cdot\right)$ \cite[Eq. 8.445]{book2}. Thus, $I_{1}$ can be rewritten as } \textcolor{black}{ \begin{eqnarray} I_{1} & = & \stackrel[m=0]{\infty}{\sum}\frac{\Delta_{2}^{\mu_{2}+2m-1}}{\Gamma\left(\mu_{2}+m\right)m!}\stackrel[0]{\infty}{\int}z^{\mu_{2}+m-1}\textrm{exp}\left(-\phi_{2}z\right)\textrm{d}z\nonumber \\ & \stackrel{\left(a\right)}{=} & \stackrel[m=0]{\infty}{\sum}\frac{\left(\mu_{2}\sqrt{\kappa_{2}\left(\kappa_{2}+1\right)}\right)^{\mu_{2}+2m-1}}{\phi_{2}^{\mu_{2}+m}\,m!},\label{eq:I1} \end{eqnarray} } \noindent \textcolor{black}{where $\left(a\right)$ is obtained with the help of \cite[Eq. 3.351.3]{book2} along with some }basic algebraic manipulations. Similarly, to solve the integral $I_{2}$, we first replace $I_{\mu_{2}-1}\left(\cdot\right)$ and $\Gamma\left(\cdot,\cdot\right)$ with their series representations using \cite[Eq. 8.445]{book2} and \cite[Eq. 8.352.2]{book2}, respectively, as follows \begin{equation} I_{\mu_{2}-1}\left(2\Delta\right)=\stackrel[l=0]{\infty}{\sum}\frac{1}{\Gamma\left(\mu_{2}+l\right)l!}\,\left(\Delta_{2}\sqrt{z}\right)^{\mu_{2}-1+2l},\label{eq:Iv_series-1} \end{equation} \begin{eqnarray} \Gamma\left(\mu_{1}+n,\frac{\phi_{1}\upsilon}{a\,z}\right)=\psi!\textrm{ exp}\left(-\frac{\phi_{1}\upsilon}{a\,z}\right)\stackrel[k=0]{\psi}{\sum}\frac{1}{k!}\left(\frac{\phi_{1}\upsilon}{a\,z}\right)^{k},\label{eq:Iv_series-1-1} \end{eqnarray} \noindent where $\psi=\mu_{1}+n-1$. Using (\ref{eq:Iv_series-1}) and (\ref{eq:Iv_series-1-1}), we can rewrite $I_{2}$ as \begin{eqnarray} \nonumber \\ I_{2}=\psi\stackrel[l=0]{\infty}{\sum}\,\stackrel[k=0]{\psi}{\sum}\left(\frac{\phi_{1}\upsilon}{a}\right)^{k}\frac{\Delta_{2}^{\mu_{2}+2l-1}}{\Gamma\left(\mu_{2}+l\right)\,l!\,k!}\,I_{3},\label{eq:I2} \end{eqnarray} \noindent where \begin{eqnarray} I_{3} & = & \stackrel[0]{\infty}{\int}z^{\mu_{2}+l-k-1}\textrm{exp}\left(-\phi_{2}\,z-\frac{\phi_{1}\upsilon}{a\,z}\right)\textrm{d}z\nonumber \\ & \stackrel{\left(a\right)}{=} & 2\left(\frac{\phi_{2}\,a}{\phi_{1}\upsilon}\right)^{\frac{1}{2}\left(k-l-\mu_{2}\right)}K_{k-l-\mu_{2}}\left(\sqrt{\frac{\upsilon}{a}\phi_{1}\phi_{2}}\right),\quad\label{eq:I3} \end{eqnarray} \noindent \begin{figure*}[t] \begin{eqnarray} F_{W}\left(\upsilon\right)=\frac{\mu_{2}\left(1+\kappa_{2}\right)^{\frac{\mu_{2+1}}{2}}}{\kappa_{2}^{\frac{\mu_{2}-1}{2}}\underset{i\in\left\{ 1,2\right\} }{\prod}\textrm{exp}\left(\kappa_{i}\mu_{i}\right)}\Biggl\{\stackrel[n=0]{\infty}{\sum}\,\stackrel[m=0]{\infty}{\sum}\frac{\left(\mu_{2}\sqrt{\kappa_{2}\left(1+\kappa_{2}\right)}\right)^{\mu_{2}+2m-1}\left(\kappa_{1}\mu_{1}\right)^{n}}{\left(\left(1+\kappa_{2}\right)\mu_{2}\right)^{\mu_{2}+m}m!\,n!}-2\stackrel[n=0]{\infty}{\sum}\,\stackrel[l=0]{\infty}{\sum}\stackrel[k=0]{\psi}{\sum}\nonumber \\ \frac{\left(\kappa_{1}\mu_{1}\right)^{n}\left(\mu_{1}+n-1\right)!}{n!\,k!\,l!}\frac{\left(\mu_{2}\sqrt{\kappa_{2}\left(1+\kappa_{2}\right)}\right)^{\mu_{2}+2l-1}}{\Gamma\left(\mu_{1}+n\right)\Gamma\left(\mu_{2}+l\right)}\left(\frac{\phi_{1}\upsilon}{a}\right)^{k}\left(\frac{a\phi_{2}}{\upsilon\phi_{1}}\right)^{-\frac{1}{2}\left(\mu_{2}+l-k\right)}\,K_{k-l-\mu_{2}}\left[\,2\sqrt{\frac{\upsilon}{a}}\sqrt{\phi_{1}\phi_{2}}\right]\Biggr\}\label{eq:FWfinal} \end{eqnarray} \selectlanguage{american \centering{}\rule[0.5ex]{2.03\columnwidth}{0.8pt}\selectlanguage{english \end{figure*} \begin{figure*}[t] \begin{eqnarray} P_{out}\left(\upsilon\right)=1-\frac{1}{\textrm{exp}\left(\kappa_{3}\mu_{3}\right)}\stackrel[q=0]{\infty}{\sum}\left\{ \frac{\left(\mu_{3}\kappa_{3}\right)^{q}}{\Gamma\left(\mu_{3}+q\right)q!}\,\gamma\left(\mu_{3}+q,\frac{\phi_{3}b}{\upsilon}\right)\right\} \Biggl(1-\frac{\mu_{2}\left(1+\kappa_{2}\right)^{\frac{\mu_{2+1}}{2}}}{\kappa_{2}^{\frac{\mu_{2}-1}{2}}\underset{i\in\left\{ 1,2\right\} }{\prod}\textrm{exp}\left(\kappa_{i}\mu_{i}\right)}\Biggl\{\stackrel[n=0]{\infty}{\sum}\stackrel[m=0]{\infty}{\sum}\frac{\Delta_{2}^{\mu_{2}+2m-1}}{\phi_{2}^{\mu_{2}+m}}\nonumber \\ \times\frac{\left(\kappa_{1}\mu_{1}\right)^{n}}{m!\,n!}-2\stackrel[n=0]{\infty}{\sum}\stackrel[l=0]{\infty}{\sum}\stackrel[k=0]{\psi}{\sum}\frac{\left(\kappa_{1}\mu_{1}\right)^{n}\Delta_{2}^{\mu_{2}+2l-1}\psi!}{\Gamma\left(\mu_{1}+n\right)\Gamma\left(\mu_{2}+l\right)n!\,k!\,l!}\left(\frac{\phi_{1}\upsilon}{a}\right)^{k}\left(\frac{\phi_{2}a}{\phi_{1}\upsilon}\right)^{-\frac{1}{2}\left(\mu_{2}+l-k\right)}K_{k-l-\mu_{2}}\left[\,2\sqrt{\frac{\upsilon}{a}\phi_{1}\phi_{2}}\right]\Biggr\}\Biggr)\label{eq:Poutfinal-1} \end{eqnarray} \selectlanguage{american \centering{}\rule[0.5ex]{2.03\columnwidth}{0.8pt}\selectlanguage{english \end{figure*} \begin{figure*}[t] \begin{eqnarray} P_{out}^{\{\textrm{Ric}\}}\left(C_{th}\right)=1-\frac{1}{\textrm{exp}\left(\kappa_{3}\right)}\,\stackrel[q=0]{\infty}{\sum}\left\{ \frac{\kappa_{3}^{q}}{\Gamma\left(q+1\right)q!}\,\gamma\left(q+1,\,\left(1+\kappa_{3}\right)\frac{b}{\upsilon}\right)\right\} \Biggl(1-\frac{1}{\textrm{exp}\left(\kappa_{1}+\kappa_{2}\right)}\Biggl\{\stackrel[n=0]{\infty}{\sum}\,\stackrel[m=0]{\infty}{\sum}\frac{\kappa_{1}^{n}\kappa_{2}^{m}}{n!\,m!}\nonumber \\ -2\stackrel[n=0]{\infty}{\sum}\,\stackrel[l=0]{\infty}{\sum}\,\stackrel[k=0]{n}{\sum}\frac{\kappa_{1}^{n}\kappa_{2}^{l}}{n!\,l!\,k!\,l!}\left(\left(\kappa_{1}+1\right)\left(\kappa_{1}+1\right)\frac{\upsilon}{a}\right)^{\frac{1}{2}\left(l+k+1\right)}\,K_{k-l-1}\left[2\sqrt{\left(1+\kappa_{1}\right)\left(1+\kappa_{2}\right)\frac{C_{th}}{a}}\right]\Biggr\}\Biggr)\label{eq:PoutR} \end{eqnarray} \selectlanguage{american \centering{}\rule[0.5ex]{2.03\columnwidth}{0.8pt}\selectlanguage{english \end{figure*} \noindent where $\left(a\right)$ is accomplished by means of \cite[Eq. 3.471.12]{book2}, along with some mathematical manipulations. Substituting (\ref{eq:I3}) into (\ref{eq:I2}) and\textcolor{black}{{} then (\ref{eq:I1}) and (\ref{eq:I2}) into (\ref{eq:FW}), we obtain an expression for $F_{W}\left(\cdot\right)$ given in (\ref{eq:FWfinal}), shown at the top of this page, where $K_{v}\left[\cdot\right]$ is the modified Bessel function of the second kind with arbitrary order $v$ \cite[Eq. 9.6.22]{BookAbramow72}. Finally, using (\ref{eq:Poutfinal}), (\ref{eq:FZfinal}) and (\ref{eq:FWfinal}), along with} basic mathematical manipulations, we obtain an accurate and unified expression for the ergodic outage probability of the dual-hop FD-DF relaying system over the g\textcolor{black}{eneralized $\kappa$-$\mu$ fading channel. This is given by (\ref{eq:Poutfinal-1}), shown at the top of this page. } \textcolor{black}{Now, substituting $\mu_{1}=\mu_{2}=\mu_{3}=1$ in (\ref{eq:Poutfinal-1}), we get an analytical} expression of the outage probability for the Rice fading sc\textcolor{black}{enario, given in (\ref{eq:PoutR}), shown at the top of the page. To obtain a mathematical expression for the Nakagami-$m$ fading case, we start from (\ref{eq:Poutfinal-1}) and substitute $\kappa_{1}=\kappa_{2}=\kappa_{3}\rightarrow0$, $\mu_{1}=m_{1}$, $\mu_{2}=m_{2}$ and $\mu_{3}=m_{3}$. Note that due to the fact that $\kappa_{1}=\kappa_{2}=\kappa_{3}\rightarrow0$, only the first terms of all infinite series will have non-zero values, expect the last summation. Thus, the resultant closed-form expression of the ergodic outage probability in Nakagami-$m$ fading can be given as } \textcolor{black}{ \begin{eqnarray} \negthickspace\negthickspace\negthickspace\negthickspace\negthickspace\negthickspace\negthickspace\negthickspace\negthickspace\negthickspace\negthickspace\negthickspace P_{out}^{\{\textrm{Nak}\}}=1-\frac{2}{\Gamma\left(m_{2}\right)\Gamma\left(m_{3}\right)}\,\gamma\left(m_{3},\,m_{3}\frac{b}{\upsilon}\right)\qquad\hfill\quad\nonumber \\ \hfill\hfill\times\stackrel[k=0]{m_{1}-1}{\sum}\frac{1}{k!}\left(\frac{m_{1}m_{2}\upsilon}{a}\right)^{\frac{m_{2}+k}{2}}K_{m_{2}-k}\left[\,2\sqrt{m_{1}m_{2}\frac{\upsilon}{a}}\right]\label{eq:PoutN} \end{eqnarray} } \textcolor{black}{When $m_{1}=m_{2}=m_{3}=1$, the expression in (\ref{eq:PoutN}) reduces to the Rayleigh fading scenario as } \textcolor{black}{ \begin{eqnarray} P_{out}^{\{\textrm{Ray}\}}=1-2\sqrt{\frac{\upsilon}{a}}\left(1-\textrm{exp}\left(-\frac{b}{\upsilon}\right)\right)K_{1}\left[\,2\sqrt{\frac{\upsilon}{a}}\right],\label{eq:PoutRay} \end{eqnarray} } \textcolor{black}{We know that $K_{1}\left(z\right)$ can be approximated by $1/z$ when $z\ll1.$ Based on this, at high SNR, (\ref{eq:PoutRay}) can be simplified to $P_{out}^{\{\textrm{Ray}\}}\approx\textrm{exp}\left(-\frac{1-\alpha}{\eta\alpha\upsilon}\right),$ which indicates that the system performance improves as we increase $\eta$ and/or decrease $\upsilon$. } \section{\label{sec:Numerical-Results}Numerical Results and Discussions } All our evaluations in this section, \textcolor{black}{unless we specify otherwise, are based on: $\xi_{1}=\xi_{2}=\xi_{3}=2.7$, $d_{1}=d_{2}=4$m, $\sigma_{r}=\sigma_{d}=0.01$W, $\eta=1$ and $C_{th}=0.2$bits/s/Hz \cite{nasir}. To begin with, we show in Fig. \ref{fig:Fig1} a 3D plot for the analytical and simulated outage probability as a function of the fading parameters $\kappa$ and $\mu$. Note that the analytical results are obtained using (\ref{eq:Poutfinal-1}) while considering the first 20 terms of all series. It is clear that the performance improves as $\kappa$ and/or $\mu$ is increase}d. This is because increasing $\kappa$ indicates an increase in the ratio between the total power of the dominant components and the total power of the scattered waves, and increasing $\mu$ implies increasing the number of multipath clusters. \begin{figure} \begin{centering} \includegraphics[scale=0.55]{3Da} \par\end{centering} \caption{\label{fig:Fig1}Ergodic outage probability versus the fading parameters $\kappa_{i}$ and $\mu_{i}$, $i\in\left\{ 1,2,3\right\} $, when $\alpha=0.06$ and $P_{s}=0.5\textrm{W}$. } \end{figure} Now, to illustrate the influence of the EH time factor we present in Fig. \ref{fig:Fig2} the ergodic outage probability with respect to $\alpha$ for the two special cases of the $\kappa$-$\mu$ fading model: Nakagami-$m$ fading in Fig. \ref{fig:Fig2}(a) for vario\textcolor{black}{us values of $\mu$ and Rice fading in Fig. \ref{fig:Fig2}(b) with different values of $\kappa$. Note that the numerical results in Figs. \ref{fig:Fig2}(a) and \ref{fig:Fig2}(b) are obtained from (\ref{eq:PoutN}) and (\ref{eq:PoutR}), respectively. It is clear that, for all fading scenarios, when $\alpha$ is either too high or too small, the performance degrades significantly; hence, this parameter must be selected carefully to minimize the outage probability. It is worthwhile pointing out that the results represented by the symbol (+) in Fig. \ref{fig:Fig2}(a) are for Rayleigh fading and are obtained from (\ref{eq:PoutRay}).} To illustrate the impact of the loop-back interference channel on the system performance, we plot in Fig. \ref{fig:Fig3} the ergodic outage probability as a function of $P_{s}$ for different values of $\mu_{3}$ when $C_{th}=0.3$bits/s/Hz, $\alpha=0.6$ and $d_{1}=2d_{2}$. Note that, in this figure, we considered a Nakagami-$m$ fading channel and kept $\mu_{1}$ and $\mu_{2}$ fixed at 5. It can be seen that as we improve the loop-back interference channel, i.e., increasing $\mu_{3}$, the performance deteriorates. It is also noticeable that the performance enhances as the transmit power is increased and worsens with increasing the end-to-end distanc\textcolor{black}{e. Furthermore, Fig. \ref{fig:Fig4} depicts some numerical results of the optimal EH time factor versus the fading parameter $m_{i}$, $i\in\left\{ 1,2\right\} ,$ with different values of $\eta$ when $P_{s}=1$W and $m_{3}=3$. Clearly, increasing $m_{i}$ and/or $\eta$ minimizes the outage probability. } \begin{figure} \begin{centering} \subfloat[Nakagami-$m$ $\left(\kappa_{1}=\kappa_{2}\rightarrow0\right)$]{\begin{centering} \includegraphics[scale=0.55]{FDmu} \par\end{centering} }\subfloat[Rice $\left(\mu_{1}=\mu_{2}=1\right)$]{\begin{centering} \includegraphics[scale=0.55]{FDkappa} \par\end{centering} } \par\end{centering} \caption{\label{fig:Fig2}Ergodic outage probability versus $\alpha$ for the FD-DF relay system for different $\kappa$ and $\mu$ values. } \end{figure} \section{\label{sec:Conclusion}Conclusion } This letter analyzed the performa\textcolor{black}{nce of a FD-DF EH-enabled relaying network over $\kappa$-$\mu$ fading channels. Accurate mathematical expressions were derived for the ergodic outage probability. Three special cases of the $\kappa$-$\mu$ fading were investigated, namely, Rice, Nakagami-$m$ and Rayleigh. Using the derived exp}ressions, the impact of several system parameters were examined such as the fading parameters, loop-back interference channel, end-to-end distance and source transmit power. \begin{figure} \centering{ \begin{minipage}[t]{0.52\columnwidth \begin{flushleft} \includegraphics[scale=0.55]{FDps} \par\end{flushleft} \caption{\label{fig:Fig3}Ergodic outage probability with respect to $P_{s}$ for different loop-back interference scenarios.} \end{minipage \begin{minipage}[t]{0.52\columnwidth \begin{flushleft} \includegraphics[scale=0.55]{FDopt_mu} \par\end{flushleft} \begin{center} \caption{\textcolor{black}{\label{fig:Fig4}Optimal EH time factor versus the fading parameter $m_{i}$ for different values of $\eta$. }} \par\end{center \end{minipage} \end{figure} \bibliographystyle{ieeetr}
\section{Introduction} Colloidal monolayers at liquid interfaces have received a significant attention in the last two decades due to their importance both industrially and scientifically. From an industrial perspective, interfacial colloids are important in areas ranging from pharmaceuticals to food and personal care products \cite{Binks2002}. From a scientific perspective, interfacial colloids serve as ideal model systems to study self-assembly in two dimensional (2D) condensed matter systems due to the strong confinement of the colloidal particles by the liquid interface \cite{Bresme2007}. A particularly important class of interactions for interfacial colloids are isotropic dipolar interactions. If we consider colloidal monolayers at an oil/water interface for example, the dipoles can arise from residual charges at the particle/oil interface together with their image charge in the water sub-phase \cite{Aveyard2000,Aveyard2002} or from the asymmetric electric double layer \cite{Stillinger1961,Hurd1985} or Stern layer \cite{Masschaele2010} at the particle/water interface. For all the aforementioned systems, the dipoles are electric dipoles. However, such dipolar interactions are also relevant for colloids in other confined geometries, e.g., super-paramagnetic particles confined by gravity to be on a flat air/water interface with a magnetic field applied perpendicular to the liquid interface, leading to magnetic dipoles which are perpendicular to the interface \cite{Zahn1999}. In recent years, there has been considerable interest in binary mixtures of dipolar colloids with different dipole moments at liquid interfaces due to the very rich self-assembly behaviour exhibited by these systems. For example, in the high temperature regime where the system exists in the fluid phase, the mixture is found to form a microphase separated structure where the smaller particles cluster around the larger particles \cite{Hoffmann2006,Hoffmann2006b}. On the other hand, in the low temperature regime, these systems form a bewildering variety of super-lattice crystal structures \cite{Stirner2005,Assoud2007,Fornleitner2009,Chremos2009,Law2011,Law2011b}. In contrast, the intermediate temperature regime where the system is close to the crystallization point is much less studied, though the limited studies that do exists suggest that the self-assembly behaviour here is equally rich \cite{Law2011b}. This gap in our understanding is largely due to the lack of suitable theoretical tools for studying the intermediate temperature regime. Specifically, while integral equation theory can be used to study the fluid state at high temperature \cite{Hoffmann2006,Hoffmann2006b} and lattice sum methods for the crystal state at zero temperature \cite{Assoud2007,Fornleitner2009,Chremos2009,Law2011,Law2011b}, neither of these methods are applicable to the region around the crystllization point. The lattice sum method has the further limitation that it can only be used to study spatially periodic structures, thus excluding the possibility of studying non-periodic ordered structures such as quasi-crystals \cite{Scheffler2004}. Particle based simulations (e.g., Monte Carlo simulations) provide us with some possibilities in addressing this problem \cite{Stirner2005,Law2011b}. However, the well known limitations of this approach, such as fluctuations in the local densities, slow dynamics when exploring the rugged free energy landscape of complex systems etc., mean that it is not always possible to use this approach to obtain a comprehensive and reliable set of stable crystal structures. The aim of this paper is to address this problem by developing a density functional theory (DFT) for the crystallization of binary dipolar colloids in two-dimensions. DFT is a powerful technique for studying the microscopic density distribution in condensed matter systems, including the crystalline state. Specifically, it asserts that the Helmholtz free energy of the system is a unique functional of the one-particle densities of the different species in the system \cite{Hansenbook, Evans1979, evans1992fundamentals}. Since DFT treats both the fluid and crystal state on the same footing, it allows us to study the freezing transition accurately. Specifically, it returns the \emph{average} local density of the different species in the system, thus providing accurate information about the crystal structure which is not obscured by noise. In addition, since DFT is based on free energy minimization rather than any underlying dynamics of the system, it is much faster and more reliable compared to particle-based simulation methods in finding stable crystal structures. The first DFT for two dimensional dipolar systems was constructed by van Teeffelen \emph{et al.} \cite{vanTeeffelen2006,vanTeeffelen2008}. These authors performed a series expansion of the Helmholtz free energy in density fluctuations around a reference liquid state, effectively treating the crystal as a spatially inhomogeneous fluid. By using very accurate free energy functionals for the system, where higher than second order terms in the series expansion were included either perturbatively or non-perturbatively, these authors were able to accurately predict the freezing point for dipolar systems. However, van Teeffelen \emph{et al.} only considered the case of one-component dipolar systems. Furthermore, to make their calculations tractable, they used predefined forms for the colloid density profiles and performed their calculations over one unit cell with a predetermined symmetry. In this paper, we use a simpler free energy functional for the system, expanding the Helmholtz free energy functional only up to second order in the density. We further employ a heuristic scaling approximation to extrapolate the direct correlation function (i.e., the coefficient of the second order term) beyond the crystallization point and induce the system to crystallize. Although truncating the free energy at second order means that we are no longer able to determine the freezing point accurately, our approach allows us to lift a number of the constraints of the approach in Ref.~\cite{vanTeeffelen2006,vanTeeffelen2008}. Firstly, we are able to consider both one and two-component dipolar monolayers. Secondly, we do not need to make any \emph{a priori} assumptions concerning the density profiles of the particles; instead the density fields of the different components are returned as an output of our calculation. Finally, we are able to perform our calculations over large areas containing many unit cells so that the system is not constrained to have a specific crystal structure but is free to choose its optimum crystal structure. Our method therefore complements the approach of van Teeffelen \emph{et al.}, providing a simple but powerful \emph{predictive} tool for studying the crystallization of one- and two-component dipolar monolayers. The rest of the paper is structured as follows. In section II we discuss the background theory, including details of system parameters, the density functional theory and the integral equation theory and Monte Carlo simulations on which the DFT is based. In section III we discuss results from our DFT for both one- and two-component dipolar systems and compare these to known results from other methods. Finally in section IV, we give our conclusions. \section{Background Theory} \subsection{The system and interaction parameters}\label{system} We first consider the one-component system consisting of $N$ colloidal particles with radius $R$ at a flat liquid interface with area $A$. Each particle possesses a dipole (electric or magnetic) of magnitude $P$ which is oriented perpendicular to the interface. We use the typical distance between particles $a \equiv \rho^{-1/2}$ as our characteristic length scale, where $\rho =N/A$ is the two-dimensional number density of colloids. For low enough colloid densities such that $a>>2R$ (a condition that is easily satisfied experimentally for many dipolar systems of interest), we can neglect the short range hard core repulsion and treat each colloid as a point-like dipole. In this case, the interaction between two particles with centre-to-centre separation $r$ is given by \begin{equation}\label{u1} \beta U(r) = \Gamma \frac{a^3}{r^3} \end{equation} where $\beta=1/k_BT$, $k_B$ is Boltzmann's constant, $T$ is the absolute temperature and $\Gamma$ is the dimensionless dipole interaction strength. Physically, $\Gamma$ measures the strength of the dipolar interaction between two particles which are at the typical separation $a$ relative to the thermal energy. As mentioned in the Introduction, such dipolar interactions naturally arise in many 2D colloidal systems. For example, for colloids adsorbed at an oil/water interface with contact angle $\theta$, the dipoles can arise from residual charges at the particle/oil interface together with their image charge in the water sub-phase \cite{Aveyard2000,Aveyard2002}. In this case $\Gamma = P^2/8 \pi \epsilon_r \epsilon_0 a^3 k_BT$, where $P = 2 q \zeta$, $q= 2 \pi R^2 \sigma (1-\cos \theta)$, $\zeta = R (3+\cos \theta)/2$, $\sigma$ is the surface charge density at the particle/oil interface, $\epsilon_r$ is the relative permittivity of the oil phase and $\epsilon_0$ is the vacuum permittivity. On the other hand, for super-paramagnetic particles on an air/water interface, an induced magnetic dipole arises when a magnetic field $B$ is applied perpendicular to the interface. In this case $\Gamma = \mu_0 P^2/4 \pi a^3 k_BT$, where $\mu_0$ is the vacuum permeability, $P= \chi B$ and $\chi$ is the magnetic susceptibility of the particle as a whole \cite{Zahn1999}. Note that the thermodynamic state of a one-component dipolar system is fully characterised by the interaction strength $\Gamma$ and does not depend separately on temperature and density. We can generalise the above to two-component dipolar systems. In this case, each component is characterised by its own density $\rho_1$, $\rho_2$, radius $R_1$, $R_2$ and dipole moment strength $P_1$, $P_2$. For definiteness, we define species $1$ as the species with the larger dipole moment and use the typical separation between these particles $a \equiv \rho_1^{-1/2}$ as the characteristic length scale for the two-component system. Since dipole moment strength generally correlates with particle size in the experimental system, we will also refer to species $1$ and $2$ as `large' and `small' respectively in what follows. For large enough separations $r$, the interaction between two particles of species $i$ and $j$ respectively ($i,j=1,2$) is given by \begin{equation}\label{u2} \beta U_{ij}(r) = \Gamma m_i m_j \frac{a^3}{r^3} \end{equation} where $m_i=P_i/P_1$ is the dipole moment for species $i$ relative to that of a large particle. In Eq.~\eqref{u2}, $\Gamma$ is the dimensionless interaction strength between large particles. For example, for charged colloids at an oil/water interface, $\Gamma = P_1^2/8 \pi \epsilon_r \epsilon_0 a^3 k_BT$. Note that the thermodynamic state of a two-component dipolar system is fully characterised by three parameters: the interaction strength $\Gamma$, the dipole moment ratio $m_2$ and the density ratio $\rho_2/\rho_1$. \subsection{Integral equation theory}\label{IET} As mentioned in the Introduction, the DFT we implement uses the fluid state as the reference state and therefore requires an accurate description of the fluid state as its starting point. The latter is provided by integral equation theory. For a one-component system, integral equation theory describes the structure of the fluid via two correlation functions, namely the radial distribution function $g(r)$ and the two-body direct correlation function $c(r)$. Physically, $\rho g(r)$ corresponds to the density of colloids at a distance $r$ from the origin given that another colloid is located at the origin. These two functions are related to each other via the Ornstein-Zernicke (OZ) relation \cite{Hansenbook} \begin{equation}\label{OZ} h(r)=c(r)+\rho \int d\mathbf{r}' c(|\mathbf{r}-\mathbf{r}'|) h(r') \end{equation} where $h(r) \equiv g(r)-1$ is called the total correlation function and the integral is carried out over 2D space for our system. For actual calculations, it is more convenient to express the OZ relation in Fourier space, \begin{equation}\label{OZ2} \ft{h}(q) = \ft{c}(q) +\rho \ft{h}(q) \ft{c}(q) \end{equation} where $\ft{h}(q)$ and $\ft{c}(q)$ are the 2D Fourier transforms of $h(r)$ and $c(r)$ respectively. The OZ relation is exact, but since it connects two unknown functions, one more relation or \emph{closure} is needed in order to determine $h(r)$ and $c(r)$. In order to obtain an accurate DFT, we require accurate expressions for $c(r)$ close to the freezing transition (see subsection \ref{DFT}). However, van Teeffelen \emph{et al.} have shown that even closures like the hypernetted chain (HNC) and Rogers-Young (RY), which are generally considered to be accurate for soft interactions such as dipolar interactions, are not accurate enough for this purpose \cite{vanTeeffelen2006,vanTeeffelen2008}. We therefore use Monte Carlo (MC) simulations instead to obtain high precision radial distribution functions $g_s(r)=h_s(r)+1$, where the subscript $s$ refers to quantities obtained from simulations (see next subsection for further details). Since the accessible range of $h_s(r)$ is limited to $r \leq L/2$, where $L$ is the simulation box size, we used the extrapolation method of Verlet \cite{Verlet1968} to extend the correlation functions to large enough $r$ so that Fourier transforms can be performed. Specifically, we used the following closure (the Verlet-HNC closure) to relate $h(r)$ and $c(r)$ \begin{eqnarray} h(r) &=& h_s(r), \; r<r_c \nonumber \\ c(r) &=& c_{HNC}(r), \; r>r_c \label{verlet} \end{eqnarray} where $r_c$ is a suitably chosen cut-off radius for the simulation data such that $r_c \leq L/2$. In Eq.~\eqref{verlet}, $c_{HNC}(r)$ is the direct correlation function obtained from the HNC closure \begin{equation}\label{HNC} c(r)=e^{-\beta U(r)+\gamma(r)}-\gamma(r)-1 \end{equation} where $\gamma(r) \equiv h(r)-c(r)$ is the indirect correlation function. In practice, it is numerically more stable to work in terms of $\gamma (r)$ and $c(r)$ rather than $h(r)$ and $c(r)$. In this case, the Verlet-HNC closure can be rewritten as \begin{equation}\label{verlet2} c(r) = \begin{cases} h_s (r)-\gamma(r), & r \leq r_c \\ c_{HNC}(r), & r>r_c \end{cases} \end{equation} The OZ relation and the Verlet-HNC closure can now be solved iteratively to obtain the correlation functions $\gamma(r)$ and $c(r)$. The above discussion can be readily generalised to two-component systems. In this case, the fluid structure is described by integral equation theory using three total correlation functions $h_{ij}(r)$ and three direct correlation functions $c_{ij}(r)$ where $i,j=1,2$; due to symmetry $h_{12}(r)=h_{21}(r)$ and $c_{12}(r)=c_{21}(r)$. In our calculations, these functions are related to each other via the two-component OZ relations and Verlet-HNC closures. Specifically, using the Einstein summation convention, the two-component OZ relation in Fourier space is given by the matrix equation \cite{Hoffmann2006b} \begin{equation}\label{OZ3} \ft{h}_{il}(q)=\ft{c}_{il}(q)+\ft{c}_{ij}(q) d_{jk} \ft{h}_{kl}(q) \end{equation} where $\ft{h}_{ij}(q)$, $\ft{c}_{ij}(q)$ are the 2D Fourier transforms of $h_{ij}(r)$, $c_{ij}(r)$ respectively, $d_{ij}$ is the diagonal matrix of partial densities \begin{equation}\label{d} d_{ij} =\rho_i \delta_{ij}, \end{equation} $\delta_{ij}$ is the Kronecker delta and no summation is implied by the repeated index $i$ above. On the other hand, the two-component Verlet-HNC closure is given by \begin{equation}\label{verlet3} c_{ij}(r) = \begin{cases} h_{s,ij} (r)-\gamma_{ij}(r), & r\leq r_c \\ c_{HNC,ij}(r), & r>r_c \end{cases} \end{equation} where $h_{s,ij} (r)$ are the total correlation functions obtained from simulation, $c_{HNC,ij}(r)$ are the direct correlation functions obtained from the HNC closure \begin{equation}\label{HNC2} c_{ij}(r)=e^{-\beta U_{ij}(r)+\gamma_{ij}(r)}-\gamma_{ij}(r)-1 \end{equation} and $\gamma_{ij} (r) \equiv h_{ij}(r)-c_{ij}(r)$ are the indirect correlation functions of the two-component system. For practical calculations, the OZ relation given by Eqs.~\eqref{OZ3} and \eqref{d} and the Verlet-HNC closure relations given by Eqs.~\eqref{verlet3} and \eqref{HNC2} are solved iteratively in terms of $\gamma_{ij} (r)$ and $c_{ij} (r)$ rather than $h_{ij}(r)$ and $c_{ij}(r)$ as before. All Fourier transforms are performed using the Discrete Hankel transform \cite{Johnson1987,Lemoine1994}. This is equivalent to a 2D fast Fourier transform method where the function to be transformed has radial symmetry, but has the benefit of being expressed as a 1D transform. The order used was $2048$, which was found to have converged, and a maximum value of $r/a=30$ was used in the transforms, which is sufficiently large that the function has decayed enough to not impact the results. Another important quantity used to describe the structure of the system is the structure factor. For a one-component system, the structure factor is given by \begin{equation}\label{sq} S(q)=1+\rho \ft{h}(q), \end{equation} while for a two-component system, the three partial structure factors are given by \cite{Hoffmann2006b} \begin{equation}\label{sq2} S_{ij}(q) = \delta_{ij}+\sqrt{\rho_i \rho_j} \ft{h}_{ij} (q). \end{equation} Here $\ft{h}(q)$ and $\ft{h}_{ij} (q)$ are the Fourier transforms of the total correlation functions $h(r)$ and $h_{ij}(r)$ respectively. \subsection{Monte Carlo simulations}\label{MC} As explained in the previous subsection, we use Monte Carlo simulations as an input to our integral equation theory in order to obtain accurate correlation functions. Verlet \cite{Verlet1968} showed that very accurate results for these functions could be obtained even using relatively small values of the cut-off radius $r_c$ in the Verlet-HNC closure (see Eqs.\ \eqref{verlet2} and \eqref{verlet3}). Practically, this means that we only need to perform simulations on relatively small systems in the fluid state, which are computationally very cheap. Specifically, for the one-component systems, we use $N=576$ particles in a $24a \times 24a$ square box with periodic boundary conditions (for different values of $\Gamma$) while for two-component systems we use $N=576$ large particles in a $24a \times 24a$ square box with periodic boundary conditions (for different values of $\Gamma$, $m_2$ and $\rho_2/\rho_1$). Unless stated otherwise, in all our simulations, the initial state (a random distribution of particles) was first equilibrated for $10^4$ MC steps per particle. After equilibration, $4\times10^4$ MC steps per particle are used for the analysis phase, with all quantities obtained by averaging over $4000$ snapshots, i.e., 1 snapshot for every 10 MC steps per particle to ensure the snapshots are independent. The maximum MC step length was adjusted to ensure an acceptance probability of around 30\% throughout the simulation. In order for the correlation functions calculated from integral equation theory to be valid, we need to ensure that the simulated system remains in the fluid phase. On the other hand, in order to obtain an accurate DFT for the crystal phase, we require accurate results for $c(r)$ very close to the freezing transition. These two constraints mean that it is imperative that we determine the freezing point of our simulated system $\Gamma_c$ accurately so that we can work with $\Gamma$ values which are close to, but still below, $\Gamma_c$. The freezing point $\Gamma_c$ was determined from our MC simulations in two ways. Firstly, it was determined by measuring the $n$-fold orientational order parameter of the system, which is defined as \begin{equation}\label{oop} \Psi_n = \left\langle \left| \frac{1}{N} \sum_{k=1}^N \psi_{n,k} \right| \right\rangle, \end{equation} where $N$ is the total number of particles, $\langle ... \rangle$ denotes an average over MC snapshots, and $\psi_{n,k}$ is the local $n$-fold orientational order parameter around the $k$-th particle defined as \begin{equation}\label{oop2} \psi_{n,k}=\frac{1}{N_k} \sum_{j=1}^{N_k} \exp(i n \theta_{kj}). \end{equation} Here the sum $j$ is over the $N_k$ nearest neighbours of particle $k$ (where nearest neighbours are those particles that share an edge in a Delauny triangulation), and $\theta_{kj}$ is the angle between $\mathbf{r}_{kj}$, the displacement vector from particle $k$ to $j$, and the $x$-axis. For two-component systems, $\Psi_n$ is defined as the orientational order parameter for the large particles only. The order parameter $\Psi_n$ depends very sensitively on the average orientational order of the system, for example $\Psi_6=0$ for a fluid while $\Psi_6=1$ for a perfect hexagonal crystal or hexatic phase (i.e., a 2D phase with orientational but not translational order). Therefore, provided the simulated system actually crystallizes, we can use this order parameter to determine $\Gamma_c$. An important technical detail that we should mention here is the fact that the crystallization of one-component dipolar systems has been experimentally demonstrated to proceed via two stages, i.e., first a fluid to hexatic transition, then a hexatic to hexagonal crystal transition \cite{Zahn1999b}, consistent with the theoretical predictions of Kosterlitz, Thouless, Halperin, Nelson and Young (KTHNY) \cite{Kosterlitz1973,Halperin1978,Nelson1979,Young1979}. Strictly speaking therefore, the orientational order parameter $\Psi_n$ measures the fluid to hexatic phase transition point rather than the crystallization point per se. However, since the $\Gamma$ value for the fluid to hexatic transition is less than 10\% lower than that for the hexatic to crystal transition for dipolar systems \cite{Zahn1999b}, it is accurate enough for our purposes to use $\Psi_n$ to measure the crystallization point. Although we can use the orientational order parameter to measure $\Gamma_c$, it is well known from experiments on binary dipolar systems \cite{Ebert2008} that for larger values of the dipole moment ratio $m_2$, the fluid phase can be arrested by a glass transition before crystallization can occur. To account for this possibility, we therefore also determine $\Gamma_c$ (in this context the point where the system ceases to be a fluid because of crystallization or a glass transition) by measuring the 2D dynamic Lindemann parameter which we define as \cite{Zheng1998,Zahn1999b,Parolini2015} \begin{equation}\label{lindemann} \gamma_L(t) = \frac{1}{2 a^2}\left\langle \left[ \Delta \mathbf{r}_k(t)-\frac{1}{N_k}\sum_{j=1}^{N_k} \Delta \mathbf{r}_j(t) \right] \right\rangle. \end{equation} Here $\Delta \mathbf{r}_i(t) = \mathbf{r}_i(t)-\mathbf{r}_i(t=0)$ is the displacement of the $i$-th particle from an arbitrary initial position after $t$ MC steps per particle. The Lindemann parameter given by Eq.~\eqref{lindemann} measures the displacement of each particle relative to the average displacement of all particles that fall within a radius of the first minimum in $g(r)$ at $t=0$. Specifically, $\gamma_L (t \rightarrow \infty)$ diverges for a fluid but is bounded for a crystal or a glass. Following Zahn \emph{et al.} \cite{Zahn1999b}, we define the simulated system to be a fluid provided $\gamma_L (t_m)>0.033$, where $t_m$ is a large value for $t$ which we chose to be $t_m = 2000$. Once again, for two-component systems, $\gamma_L(t)$ is defined with respect to the large particles only. We have checked for finite size effects in our MC simulations. We found that when we increased the number of particles from $N = 576$ to $N = 1089$ in the one component system, $\Gamma_c$ increased by less than 10\% for either the melting or freezing curves in Figure 1(a). This small shift lies within the uncertainty to which we determine $\Gamma_c$ and is therefore accurate enough for our purposes. We therefore conclude that a system size of $N = 576$ is large enough for obtaining an accurate measure of the freezing point for our dipolar systems. \subsection{Density functional theory}\label{DFT} In DFT, it is most convenient to study the system in the Grand Canonical Ensemble. For definiteness, let us consider the two-component colloidal system. In this case, the grand potential functional is given by \begin{eqnarray}\label{gce} \Omega [\rho_1(\mathbf{r}), \rho_2(\mathbf{r})] &=& k_B T \sum_{i=1}^2 \int d\mathbf{r} \rho_i (\mathbf{r}) \left( \ln (\rho_i (\mathbf{r}) \Lambda_i^2)-1 \right) \nonumber \\ &+& F_{ex}[\rho_1(\mathbf{r}), \rho_2(\mathbf{r})]+ \sum_{i=1}^2 \int d\mathbf{r} (\Phi_i(\mathbf{r})-\mu_i)\rho_i (\mathbf{r}) \end{eqnarray} where $\rho_i(\mathbf{r})$ is the one-body density profile, $\Lambda_i$ is the (irrelevant) thermal wavelength, $\mu_i$ the chemical potential and $\Phi_i(\mathbf{r})$ the external potential acting on particles of species $i$ ($i=1,2$). In all the situations described below, we consider bulk systems, where $\Phi_i(\mathbf{r})=0$. The first term in Eq.~\eqref{gce} is the ideal gas (entropic) contribution to the free energy while the second term, $F_{ex}$, is the contribution from the interactions between particles and is called the excess Helmholtz free energy \cite{Hansenbook, Evans1979, evans1992fundamentals}. The form of $F_{ex}$ is not known exactly for most systems, and the challenge in DFT is to construct accurate yet manageable approximations for this functional. Following Ramakrishnan and Yussouff \cite{Ramakrishnan1979}, we perform a series expansion of this functional about the homogeneous fluid state with uniform density $\rho_1, \rho_2$ up to second order in the density differences $\delta \rho_i(\mathbf{r})=\rho_i(\mathbf{r})-\rho_i$: \begin{eqnarray} F_{ex}[\rho_1(\mathbf{r}), \rho_2(\mathbf{r})] &=& F_{ex}(\rho_1,\rho_2) + \sum_{i=1}^2 \int d \mathbf{r} \mu_{ex,i} \delta \rho_i (\mathbf{r}) \nonumber\\ &-& \frac{k_BT}{2}\sum_{i,j} \int d\mathbf{r} \int d\mathbf{r}' \delta \rho_i (\mathbf{r}) c_{ij} (|\mathbf{r}-\mathbf{r}'|) \delta \rho_j (\mathbf{r}') \label{sot} \end{eqnarray} where $\mu_{ex,i}=\mu_i-k_BT\ln(\rho_i\Lambda_i^2)$ are the excess chemical potentials in the reference uniform liquid state and $c_{ij} (r)$ are the direct correlation functions calculated from the integral equation theory as described in subsection \ref{IET}. The key inputs that are required for our DFT are therefore the two-body direct correlation functions. Note that although formally the equilibrium density profile obtained from minimising the free energy functional corresponds to an ensemble average over all fluctuations in the system, in practice when making an approximation such as that in Eq.~\eqref{sot}, one is effectively neglecting certain fluctuation contributions. For further discussion on this issue, see e.g. ref.\cite{Evans1979, evans1992fundamentals, reguera2004role, archer2011interplay}. In particular, contributions from long-wavelength fluctuations are neglected, but for the freezing phenomena we consider here, these are less relevant. Now van Teeffelen \emph{et al.} have shown that higher than second order terms in the series expansion of the excess Helmholtz free energy functional are required to accurately predict the freezing point $\Gamma_c$ for dipolar systems \cite{vanTeeffelen2006,vanTeeffelen2008}. However, in this paper we have opted to use the simpler free energy functional given by Eq.~\eqref{sot} where only terms up to second order are included. Although this means that we are no longer able to determine the freezing point accurately (such second order theories underestimate the stability of the crystal phase and therefore lead to predictions for $\Gamma_c$ that are too high \cite{vanTeeffelen2006,vanTeeffelen2008}), this simpler functional allows us to consider more complex dipolar systems with much greater ease compared to higher order theories. Specifically, we are able to consider both one- and two-component dipolar systems. We can also calculate the density profiles for the different particles \emph{ab initio}, without needing to make any \emph{a priori} assumptions concerning the form of these density profiles. Finally, we are able to perform calculations over large areas containing many unit cells where the system is not constrained by the boundary conditions to have a specific crystal structure but is free to choose its optimum structure. One limitation of the Verlet closure that we have used in our DFT is the fact that the direct correlation functions $c_{ij}(r)$ can only be obtained for $\Gamma < \Gamma_c$. However, it is possible to extend our DFT to $\Gamma > \Gamma_c$ by using a heuristic scaling approximation for $c_{ij}(r)$ (see next section and Figure 3(a)). Although this approximation overestimates the stability of the crystal phase, it appears to generate crystal structures which are essentially the same as the equilibrium crystal structure (see Figure 3(b)) and therefore serve as good approximants for the equilibrium crystal structure. Furthermore, the resultant crystal structures remain (meta)stable for a small range of $\Gamma$ values below $\Gamma_c$, where our expressions for $c_{ij}(r)$ are accurate. The equilibrium density profiles are those which minimise the grand potential Eq.~\eqref{gce}, i.e.\ which satisfy the following pair of Euler-Lagrange equations \begin{equation}\label{EL-eq} \frac{\delta\Omega[\rho_1(\mathbf{r}), \rho_2(\mathbf{r})]}{\delta\rho_i(\mathbf{r})}=0. \end{equation} Substituting Eqs.~\eqref{gce} and \eqref{sot} into Eq.~\eqref{EL-eq} we obtain \begin{equation}\label{EL-eq2} k_BT\ln\left(\rho_i(\mathbf{r})/\rho_i\right)+\sum_{i=1}^2 \int d\mathbf{r}' c_{ij} (|\mathbf{r}-\mathbf{r}'|) \delta \rho_j (\mathbf{r}')+\Phi_i(\mathbf{r})=0. \end{equation} We solve these equations using Piccard iteration. For more details on this method see e.g.\ Refs.~\cite{roth2010fundamental, hughes2014introduction}. There exist other more sophisticated approaches to minimising the functionals arising from DFT that can be used -- see e.g. ref.\cite{stopper2017massively} and references therein. We start from various initial guesses for the density profiles, including those obtained as a solution at slightly different parameter values (i.e.\ a neighboring state point) and also from uniform density profiles with small amplitude random noise fields added. In the second case, the system only goes to a crystalline solution with density peaks if the uniform liquid is linearly unstable \cite{Archer2014} and this is achieved by scaling the pair direct correlation functions $c_{ij}(r)$ to a higher value of $\Gamma$, as mentioned above. We also say more about this scaling procedure below. \section{Results and Discussion} \subsection{One-component system} We start by considering the one-component system. Our first task is to determine the crystallization point $\Gamma_c$ for this system. As discussed in subsection \ref{MC}, $\Gamma_c$ was determined using MC simulations by measuring both the orientational order parameter and the Lindemann parameter as a function of $\Gamma$. In Figure 1(a), we plot the orientational order parameter $\Psi_6$ as a function of $\Gamma$, starting either from the fluid state (freezing curve) or from a perfect hexagonal crystal (melting curve). Both curves show a clear first order phase transition between $\Gamma = 11$ and $12$; the minimal hysteresis between the two curves suggest that this range of $\Gamma$ values is close to the equilibrium freezing point. On the other hand, in Figure 1(b), we plot the dynamical Lindemann parameter $\gamma_L(t)$ as a function of $t$ (the number of MC steps per particle) for different values of $\Gamma$. In this case, there is a clear transition in the long `time' behaviour of $\gamma_L(t)$ at a slightly higher value of $\Gamma$, between $\Gamma=12$ and $13$, with $\gamma_L(t)$ diverging for $\Gamma \leq 12$ but converging to a finite value $\lesssim 0.033$ (indicated by the horizontal dashed line) for $\Gamma \geq 13$. This dynamical transition is also clearly seen in Figure 1(c) where we plot the long time value of the Lindemann parameter $\gamma_L (t_m=2000)$ as a function of $\Gamma$. The slight difference in the freezing point obtained from $\Psi_6$ and $\gamma_L(t)$ is not surprising given that they represent qualitatively different measures of the phase transition. In order to ensure that the system is in the fluid phase at the crystallization point, we define the crystallization point of the one-component system to be at the lower bound value of $\Gamma_c \approx 11$. \begin{figure} \includegraphics[width=1.0\columnwidth]{plot1.pdf}\\ \caption{MC simulation results for determining the crystallization point of one-component dipolar monolayers: (a) Six-fold orientational order parameter $\Psi_6$ as a function of $\Gamma$, starting either from the fluid state (freezing curve) or from a perfect hexagonal crystal (melting curve); (b) Dynamical Lindemann parameter $\gamma_L(t)$ ($t$ is the number of MC steps per particle) for different values of $\Gamma$ ($\Gamma$ values labelled on each curve); (c) Long time value of the Lindemann parameter $\gamma_L (t_m=2000)$ as a function of $\Gamma$. The dashed horizontal line in (b), (c) corresponds to $\gamma_L = 0.033$, the threshold value of the Lindemann parameter in the crystal state.}\label{fig1} \end{figure} We next calculate the different correlation functions in the fluid phase (particularly $c(r)$) close to the crystallization point $\Gamma_c$ by solving the OZ relation and Verlet-HNC closure (see subsection \ref{IET}). In Figure 2(a), we plot the total correlation function $h(r)$ for $\Gamma = 11$ obtained from Verlet-HNC (solid line) compared to MC simulations (data points). The Verlet-HNC results are fairly insensitive to the choice of the cut-off length $r_c$ used in the closure \eqref{verlet3}, provided that $r_c$ is large enough. In all our calculations for both one and two-component systems, we choose $r_c = 9a$ (i.e., vertical dashed lines in Figure 2). We note that this value for $r_c$ is slightly smaller than the maximum value we could have chosen, i.e., half the MC simulation box size $L/2 = 12a$, but is larger than half the DFT calculation box (see Figure 4) and is therefore large enough for our purposes. For selected systems, we have also checked that using a larger value of $r_c$ (close to $L/2$) does not change our results for the liquid or crystal state. We see from Figure 2(a) that the agreement between Verlet-HNC and the MC simulations is very good, not just for $r \leq r_c$, but significantly also for $r > r_c$. These results show that the Verlet-HNC closure provides a very accurate description of the fluid structure across the entire range of $r$ values. \begin{figure} \includegraphics[width=0.8\columnwidth]{plot2.pdf}\\ \caption{Liquid state correlation functions for one-component dipolar monolayers at $\Gamma=\Gamma_c=11$: (a) Total correlation function $h(r)$ obtained from the Verlet-HNC closure (solid line) and MC simulations (data points). The vertical dashed line is the cut-off length $r_c$ used in the closure \eqref{verlet2}. (b) Direct correlation function $c(r)$ obtained from the Verlet-HNC closure (red curve) and the random phase approximation (RPA, gray curve). }\label{fig2} \end{figure} In Figure 2(b), we plot the direct correlation function $c(r)$ for $\Gamma = 11$ obtained from the Verlet-HNC closure (red curve). We see that $c(r)$ is relatively featureless compared to $h(r)$, a fact that is well known from liquid state theory. However, it is instructive to compare the Verlet-HNC result with the much simpler random phase approximation (RPA) result $c_{RPA}(r)=-\beta U(r) =-\Gamma a^3/r^3$ \cite{Hansenbook} (gray curve). We see that, on the scale of the figure, there is good agreement between the two except at small $r$ ($r/a \lesssim 1$) where the RPA result diverges for $r \rightarrow 0$ but the Verlet-HNC result tends towards a large but finite negative value. The good agreement between the two curves at large $r$ suggests that the Verlet-HNC direct correlation function scales linearly with $\Gamma$ at large $r$, just like the RPA. To check whether this scaling also holds at small $r$, in Figure 3(a) we plot the Verlet-HNC results for $c(r)$ for a range of $\Gamma$ values up to $\Gamma=11$, while in the inset, we plot $c(r)/\Gamma$. The excellent collapse of the different curves onto a universal curve in the inset confirms that the RPA scaling $c(r)\sim \Gamma$ also holds to a good approximation for Verlet-HNC at low $r$ (provided $\Gamma \gtrsim 5$). However, the collapse of the different curves is in fact not perfect. For example, there is a small dispersion between the different curves around $r=0$ in the inset of Figure 3(a) which is hardly visible on the scale of the graph. We conclude from Figure 3(a) that the scaling approximation $c(r)\sim \Gamma$ preserves the essential features of the fluid structure, though it misses some subtle features of the structure. \begin{figure}[th!] \includegraphics[width=0.8\columnwidth]{plot3.pdf}\\ \caption{Checking the scaling approximation $c(r)\sim \Gamma$ for one-component dipolar monolayers: (a) Verlet-HNC results for $c(r)$ and $c(r)/\Gamma$ (inset) for a range of $\Gamma$ values up to $\Gamma=11$ ($\Gamma$ values labelled on each curve in main figure). Note the excellent collapse of the different curves in the inset; (b) Structure factor $S(q)$ calculated from the Verlet-HNC closure at $\Gamma = 11$ (purple curve), at $\Gamma=10$ with scale factor $J=11/10$ (orange curve) and at $\Gamma=9$ with scale factor $J=11/9$ (green curve).}\label{fig3} \end{figure} In order to probe in more detail what effect scaling $c(r)$ has on fluid structure, in Figure 3(b) we plot the structure factor $S(q)$ of the dipolar monolayer, calculated from the Verlet-HNC closure at $\Gamma = 11$ (purple curve), but also from the Verlet-HNC closure at lower values of $\Gamma$ ($\Gamma=9,10$, green and orange curve respectively) which are scaled to $\Gamma = 11$ using scale factors of $J=11/10, 11/9$ respectively ($J=\Gamma_{\textrm{target}}/\Gamma_{\textrm{original}}$, where $\Gamma_{\textrm{target}}$, $\Gamma_{\textrm{original}}$ are the target and original $\Gamma$ values respectively). We see that scaling $c(r)$ preserves the peak positions in the structure factor, but exaggerates the primary peak height, with the peak becoming increasingly prominent as we increase $J$. Indeed for even larger values of $J$ (e.g., scaling $c(r)$ from $\Gamma = 8$ to $\Gamma=11$ using $J=11/8$), the principal peak in $S(q)$ diverges, indicating that the fluid phase becomes linearly unstable and undergoes crystallisation \cite{Archer2014}. We conclude therefore that the scaling approximation for $c(r)$ underestimates the stability of the liquid phase. The approximation is nevertheless very useful as it generates crystal structures with the same Bragg peak positions (i.e., same symmetry) as the equilibrium crystal structure (Figure 3(b)). It also serves as a useful method for inducing the system to crystallise within our DFT calculation as we shall now demonstrate. \begin{figure} \includegraphics[width=0.8\columnwidth]{plot4.pdf}\\ \caption{DFT results for the density profile of one-component dipolar colloidal monolayers at $\Gamma = 11$, showing the whole simulation box. Length scales in units of $a$ are indicated at the edges of the box.}\label{fig4} \end{figure} Having used integral equation theory to obtain accurate results for $c(r)$ close to the crystallization point, we now feed this information into our DFT to calculate the crystal structure. Using the uniform density fluid state (superposed with random noise) as our initial guess when solving the Euler-Lagrange equations \eqref{EL-eq2} at $\Gamma = \Gamma_c = 11$, we find that the fluid state is linearly stable. This is not surprising since, as discussed earlier, the effective crystallization point in our second order DFT is much higher than the equilibrium crystallization point. However, if we instead scale $c(r)$ at $\Gamma = 11$ with a scale factor of $J=1.3$ and feed this into our DFT, the uniform density state becomes linearly unstable and the system crystallizes into a hexagonal crystal. If we now use this crystal density profile as our initial guess when solving the Euler-Lagrange equations \eqref{EL-eq2} for a lower value of $J$, by gradually reducing $J$, following the crystalline solution branch until $J=1$ (i.e., no scaling), we find that we are able to obtain a hexagonal crystal state as a linearly stable solution at $\Gamma = 11$, as shown in Figure 4. Note that the grand potential for this crystal is higher than that of the fluid, indicating that the crystal is in fact metastable. The crystal remains linearly stable at $\Gamma = 10$ but melts at $\Gamma = 9$, showing that the \emph{spinodal} point for melting of the crystal structure lies between $\Gamma = 9$ and $\Gamma = 10$ in our DFT. Note that we are able to obtain the hexagonal crystal in Figure 4 without needing to make any \emph{a priori} assumptions about the form of the density profile or the symmetry of the crystal state. The DFT therefore provides a powerful \emph{predictive} tool for studying the crystal structure of dipolar monolayers. \subsection{Two-component system} We next turn our attention to the much richer case of two-component systems. We first consider the state point $\rho_2/\rho_1=2$ and $m_2=0.025$ where the dipole moment of the small particles is small enough to only slightly perturb the structure of the large particles. This state point has been studied by us previously \cite{Law2011,Law2011b} but our focus in those studies was on the crystallization of the \emph{small} particles. Here our focus is on the crystallization of the \emph{large} particles. We therefore determine the crystallization point of this two-component system $\Gamma_c$ by measuring the orientational order parameter and Lindemann parameter of the large particles only as a function of $\Gamma$ in our MC simulations. \begin{figure}[t] \includegraphics[width=1.0\columnwidth]{plot5.pdf}\\ \caption{MC simulation results for determining the crystallization point of two-component dipolar monolayers with $\rho_2/\rho_1=2$ and $m_2=0.025$: (a) Six-fold orientational order parameter of large particles $\Psi_6$ as a function of $\Gamma$, starting either from the fluid state (freezing curve) or from a perfect hexagonal AB$_2$ crystal (melting curve). The inset shows the perfect hexagonal AB$_2$ crystal used as the initial state for the melting curves; (b) Dynamical Lindemann parameter for large particles $\gamma_L(t)$ ($t$ is the number of MC steps per particle) for different values of $\Gamma$ ($\Gamma$ values labelled on each curve); (c) Long time value of the Lindemann parameter for large particles $\gamma_L (t_m=2000)$ as a function of $\Gamma$. The dashed horizontal line in (b), (c) corresponds to $\gamma_L = 0.033$, the threshold value of the Lindemann parameter in the crystal state.}\label{fig5} \end{figure} In Figure 5(a), we plot $\Psi_6$ for the large particles as a function of $\Gamma$, starting either from the fluid state (freezing curve) or from a perfect hexagonal AB$_2$ crystal (melting curve). The inset shows the perfect hexagonal AB$_2$ crystal used as the initial state for the melting curves. Both curves show a clear first order phase transition around $\Gamma \approx 17$; the minimal hysteresis between the two curves suggests that this $\Gamma$ value is close to the equilibrium freezing point of the large particles. Interestingly, the crystallization point in the two-component system occurs at a higher value of $\Gamma$ compared to that of the one-component system. This may be because the small particles in the two-component system remain disordered during the crystallization of the large particles (see Figure 8(d)), therefore introducing a higher degree of disorder in the structure of the large particles. In Figure 5(b) we plot $\gamma_L(t)$ for the large particles ($t$ is the number of MC steps per particle in the system) for different values of $\Gamma$, while in Figure 5(c) we plot $\gamma_L (t_m=2000)$ for the large particles as a function of $\Gamma$. We see that there is a clear transition in the long time dynamics around $\Gamma \approx 20$. In order to ensure that the system is in the fluid phase at the crystallization point for the liquid state structure calculations, we define the crystallization point for $\rho_2/\rho_1=2$ and $m_2=0.025$ to be at the lower bound value of $\Gamma_c \approx 17$. \begin{figure}[t] \includegraphics[width=0.8\columnwidth]{plot6.pdf}\\ \caption{Total correlation functions for two-component system with $\rho_2/\rho_1=2$ and $m_2=0.025$ obtained from the Verlet-HNC closure (solid line) and MC simulations (data points): (a) $h_{11}(r)$ (b) $h_{12}(r)$ and (c) $h_{22}(r)$. The vertical dashed lines are the cut-off length $r_c$ used in the closure \eqref{verlet3}.}\label{fig6} \end{figure} We next use the Verlet-HNC closure to calculate correlation functions in the fluid phase close to the crystallization point. In Figure 6(a)-(c) respectively, we plot the total correlation functions $h_{11}(r)$, $h_{12}(r)$ and $h_{22}(r)$ respectively for $\Gamma = 17$, $\rho_2/\rho_1=2$ and $m_2=0.025$ obtained from the Verlet-HNC closure (solid line) compared to MC simulations (data points). The vertical dashed line represents the cut-off length $r_c = 9a$ that we used in Eq.~\eqref{verlet3}. The agreement between Verlet-HNC and the MC simulations is very good for both $r \leq r_c$ and $r > r_c$, indicating that the Verlet-HNC closure provides a very accurate description of the fluid structure for the two-component system across the entire range of $r$. In order to check whether the scaling approximation for the direct correlation function still holds for the two-component system, in Figure 7(a)-(c), we plot the Verlet-HNC results for the direct correlation functions $c_{ij}(r)$ ($i,j=1,2$) while in the insets we plot $c_{ij}(r)/\Gamma$ for $\rho_2/\rho_1=2$, $m_2=0.025$ and a range of $\Gamma$ values up to $\Gamma=17$. We see that there is good collapse of the different $c_{ij}(r)$ curves onto universal curves in the insets, apart from a small dispersion between the different curves around $r=0$. Interestingly, the dispersion is greater for $c_{12}(r)$ and $c_{22}(r)$ compared to $c_{11}(r)$. However, apart from this small discrepancy around $r=0$, we conclude that the scaling $c_{ij}(r)\sim \Gamma$ holds to a good approximation for two-component systems, provided $\Gamma$ is large enough. \begin{figure}[t] \includegraphics[width=1.0\columnwidth]{plot7.pdf}\\ \caption{Direct correlation functions $c_{ij}(r)$ and $c_{ij}(r)/\Gamma$ (inset) for two-component system with $\rho_2/\rho_1=2$ and $m_2=0.025$ obtained from the Verlet-HNC closure for a range of $\Gamma$ values up to $\Gamma=17$: (a) $c_{11}(r)$; (b) $c_{12}(r)$; (c) $c_{22}(r)$.}\label{fig7} \end{figure} Having obtained accurate results for $c_{ij}(r)$ close to the crystallization point, we now feed this information into our DFT to calculate the crystal structure for the two-component system. In Figure 8(a)-(c), we show the crystal structure predicted by our DFT at $\Gamma=17$. The large and small particle density profiles shown are calculated as follows. We first scaled $c_{ij}(r)$ at $\Gamma = 17$ using a scale factor of $J=1.5$ and fed this into our DFT. This caused the large particles crystallize into a hexagonal crystal while the small particles remained delocalised in an interconnected honeycomb network around the large particles; the resultant structure is similar to the final structure shown in Figure 8(a)-(c). These profiles for $J=1.5$ are then used as the initial guess when solving the Euler-Lagrange equations for a lower value of $J$. By gradually reducing $J$ until $J=1$ (i.e., no scaling), we found that we are able to obtain the hexagonal crystal shown in Figure 8(a)-(c) as a linearly stable solution at $\Gamma=17$. We note that the grand potential for this crystal is higher than that of the fluid, indicating that the crystal is metastable. The large particle hexagonal lattice remains linearly stable at $\Gamma = 16$ but melts at $\Gamma = 15$, showing that the spinodal point for the melting of the large particle hexagonal lattice lies between $\Gamma = 15$ and $\Gamma = 16$ in our DFT. \begin{figure}[t] \includegraphics[width=0.8\columnwidth]{plot8.pdf}\\ \caption{(a)-(c) DFT results for the density profiles of two-component system with $\rho_2/\rho_1=2$, $m_2=0.025$, $\Gamma=17$ for (a) large particle density profile $\rho_1(r)$; (b) (negative) small particle density profile $-\rho_2(r)$ and (c) Difference between the two $\rho_1(r)-\rho_2(r)$. In these plots, the large and small particle density profiles are represented by red and blue respectively. Only a quarter of the simulation box is shown in each case and length scales in units of $a$ are indicated at the edges of the box. (d) Snapshot from a MC simulation starting from the fluid state for the two-component system with $\rho_2/\rho_1=2$, $m_2=0.025$, $\Gamma=20$.}\label{fig8} \end{figure} From Figure 8(b), we note that there is a slight preference for the small particles to be at the interstitial sites between three large particles. However, the prominent density channels of small particles connecting these interstitial sites show that the small particles are in fact fluid, moving within the frozen lattice of large particles. These DFT predictions are confirmed by MC simulations. For example in Figure 8(d), we show a snapshot from a MC simulation starting from the fluid state for $\rho_2/\rho_1=2$, $m_2=0.025$ and $\Gamma = 20$ (i.e., $\Gamma \gtrsim \Gamma_c$), where we see that the large particles form a hexagonal lattice while the small particles are in a disordered fluid state. These results confirm our suggestion in Ref.~\cite{Law2011b} that for relatively small values of $m_2$, the melting of super-lattice structures for two-component systems proceeds via two distinct stages, corresponding to the melting of the small particle lattice at higher $\Gamma$ and the subsequent melting of the large particle lattice at a lower $\Gamma$. Next we use our DFT to study the crystal structure for other state points. A comprehensive exploration of the parameter space of the two-component system lies beyond the scope of this paper. Here, we perform a preliminary exploration by just considering two nearby state points. Firstly, we consider the case $\rho_2/\rho_1 = 2$, $m_2 = 0.05$ in order to see what impact increasing $m_2$ has on the crystal structure. Secondly, we consider the case $\rho_2/\rho_1 = 1$, $m_2 = 0.2$ to see what impact changing the composition has on the crystal structure. Studying this state point also allows us to check if our DFT can produce crystal structures with symmetries other than the hexagonal symmetry since lattice sum calculations suggest that the zero-temperature structure of this state point is a square lattice \cite{Fornleitner2009}. \begin{figure}[t] \includegraphics[width=1.0\columnwidth]{plot9.pdf}\\ \caption{MC simulation results for determining the crystallization point of different two-component systems: (a) Six-fold orientational order parameter of large particles $\Psi_6$ for $\rho_2/\rho_1 = 2$, $m_2 = 0.05$ as a function of $\Gamma$, starting either from the fluid state (freezing curve) or from a perfect hexagonal AB$_2$ crystal (melting curve); (b) Four-fold orientational order parameter of large particles $\Psi_4$ for $\rho_2/\rho_1 = 1$, $m_2 = 0.2$ as a function of $\Gamma$, starting either from the fluid state (freezing curve) or from a perfect square AB crystal (melting curve); (c) Long time value of the Lindemann parameter for the large particles $\gamma_L (t_m=2000)$ for $\rho_2/\rho_1 = 1$, $m_2 = 0.2$ as a function of $\Gamma$. The dashed horizontal line corresponds to $\gamma_L = 0.033$.}\label{fig9} \end{figure} As before, we first determine the crystallization point $\Gamma_c$ for these state points. In Figure 9(a), we plot $\Psi_6$ for large particles for $\rho_2/\rho_1 = 2$, $m_2 = 0.05$ as a function of $\Gamma$ from MC simulations, starting either from the fluid state (freezing curve, circles) or from a perfect hexagonal AB$_2$ crystal (melting curve, triangles). The melting curve shows a clear first order phase transition around $\Gamma \approx 35$. The freezing curve exhibits a first order phase transition at a significantly higher $\Gamma$ value and the transition is also less clear cut. In addition, the value of $\Psi_6$ in the crystal state is significantly lower for the freezing curve compared to the melting curve for this state point. This is in contrast to the case $\rho_2/\rho_1=2$, $m_2=0.025$ where the discrepancy in the value of $\Psi_6$ for the crystal state between the freezing and melting curves is much smaller (see Figure 5(a)). These results suggest that increasing $m_2$ lowers the $\Gamma$ value at which the glass transition occurs, thus preventing the system from achieving full crystalline order at higher values of $\Gamma$ because the simulations are close to a glassy state. In order to ensure that the system is in the fluid phase at the crystallization point, we define the crystallization point for $m_2 = 0.05$, $\rho_2/\rho_1 = 2$ to be at the lower bound value of $\Gamma_c \approx 35$. The influence of $m_2$ on the glass transition is confirmed in Figure 9(b) where we plot $\Psi_4$ for large particles for the state point $\rho_2/\rho_1 = 1$, $m_2 = 0.2$ as a function of $\Gamma$ from MC simulations, starting either from the fluid state (freezing curve, circles) or from a perfect square AB crystal (melting curve, triangles; see Figure 10(b) for an example of the square AB lattice). The reason why we measure $\Psi_4$ and use a square lattice as the starting point for the melting curve is because the zero temperature structure for this state point is the square lattice, as mentioned earlier. Clearly, the first order crystallization transition is completely absent from the freezing curve, presumably because crystallization has been arrested by a glass transition for such a large value of $m_2$. The results in Figure 9(b) are consistent with experiments on binary dipolar systems which show that for $m_2 \approx 0.1$, the fluid phase is arrested by a glass transition before crystallization can occur \cite{Ebert2008}. The aim of this paper is to construct a \emph{predictive} model for the structure of binary dipolar systems and we therefore require a route for measuring $\Gamma_c$ that does not rely on any \emph{\emph{a priori}} knowledge of the final crystal structure. Since this is not possible using the orientational order parameter route in this case, we use the Lindemann parameter route to measure $\Gamma_c$ instead. From Figure 9(c), the Lindemann parameter method yields $\Gamma_c \approx 25$ for $\rho_2/\rho_1 = 1$, $m_2 = 0.2$ (here $\Gamma_c$ refers to the point where the system ceases to be a fluid either through crystallization or a glass transition). Interestingly, unlike the previous two-component state points studied in this paper, there is no clear transition in the long time Lindemann parameter curve at $\Gamma_c$, consistent with the fact that it is a glass transition. Having determined $\Gamma_c$ for the different cases considered above, we next use Verlet-HNC to calculate the direct correlation functions and use these in our DFT to calculate the resultant crystal structure. In Figure 10(a), we show the crystal structure predicted by our DFT for $\rho_2/\rho_1 = 2$, $m_2 = 0.05$ and $\Gamma=\Gamma_c =35$. The density profiles shown are calculated as follows: We first scaled $c_{ij}(r)$ at $\Gamma = 35$ using a scale factor of $J=1.2$ and fed this into our DFT. This caused the large particles to crystallize into a hexagonal crystal while the small particles remained delocalised in an interconnected honeycomb network around the large particles; the resultant structure is similar to the final structure shown in Figure 10(a). These profiles for $J=1.2$ are then used as the initial guess when solving the Euler-Lagrange equations for a lower value of $J$. By gradually reducing $J$ and following the crystalline solution branch until $J=1$ (i.e., no scaling), we find that we are able to obtain the hexagonal crystal state shown in Figure 10(a) as a linearly stable solution at $\Gamma=35$. We note that the grand potential for this crystal is higher than that of the fluid, indicating that the crystal is metastable. \begin{figure}[th!] \includegraphics[width=0.6\columnwidth]{plot10.pdf}\\ \caption{DFT results for the difference in the density profiles of large and small particles $\rho_1-\rho_2$ for different two-component systems: (a) $\rho_2/\rho_1 = 2$, $m_2 = 0.05$ and $\Gamma=\Gamma_c =35$; (b) $\rho_2/\rho_1 = 1$, $m_2 = 0.2$, $\Gamma=\Gamma_c =25$. In these plots, the large and small particle profiles are represented by red and blue respectively. Only a quarter of the simulation box is shown in each case and length scales in units of $a$ are indicated at the edges of the box. Note in (b) the line dislocation along the line $x\approx5$. }\label{fig10} \end{figure} The crystal structure in Figure 10(a) (for $\rho_2/\rho_1 = 2$, $m_2 = 0.05$) is similar to the one in Figure 8(c) (for $\rho_2/\rho_1 = 2$, $m_2 = 0.025$). However, we note that the small particles in Figure 10(a) are more localised at the interstitial sites between three large particles compared to Figure 8(c). This is not surprising since the larger dipole moment of the small particles in Figure 10(a) means that they effectively experience a larger confining potential from the large particles. We also note that for $\rho_2/\rho_1 = 2$, $m_2 = 0.05$, lattice sum calculations of the zero-temperature structure (i.e., $\Gamma \rightarrow \infty$) show that the dipole moment of the small particles is large enough to distort the hexagonal lattice of the large particles \cite{Fornleitner2009,Law2011b}. However, Figure 10(a) shows no such distortion. We conjecture that this is because Figure 10(a) shows the structure of the system at finite $\Gamma$ where the small particle lattice has melted while the large particle lattice remains intact. The delocalisation of the small particles leads to the small particles exerting a much smaller net force on the large particles due to averaging, such that the large particle lattice is no longer distorted. In Figure 10(b), we show the crystal structure predicted by our DFT for $\rho_2/\rho_1 = 1$, $m_2 = 0.2$, $\Gamma=\Gamma_c =25$. The calculation of the crystal structure for this state point was more involved compared to the previous ones considered in this paper. We found that it was not possible to induce the system to crystallize by scaling $c_{ij}(r)$ at $\Gamma = 25$. Instead, we needed to scale $c_{ij}(r)$ at a lower $\Gamma$ ($\Gamma=17$) using a large scale factor ($J=1.9$). This is not surprising since $\Gamma_c$ represents the glass transition point (rather than crystallization point) in this case, where the system is still very far from crystallization. Stronger scaling of the direct correlation functions is therefore required to induce crystallization, which is provided by using direct correlation functions at a lower $\Gamma$ in conjunction with a larger scale factor (see Figure 3(b)). In addition, using a uniform density profile (superposed with random noise) as our initial guess when solving the Euler-Lagrange equations produced a crystal structure with a large number of defects. To overcome this problem, we used a step function density along one edge of the simulation box (superposed with random noise) as our initial density profile instead (c.f.\ Ref.\cite{Archer2014}). This procedure greatly reduced the number of defects, though a line dislocation is still discernable in the final structure shown in Figure 10(b). Finally, the profile obtained from $\Gamma=17$, $J=1.9$ was used as the initial guess when solving the Euler-Lagrange equations for $\Gamma=25$, $J=1.9$. The scale factor $J$ was then reduced very slowly, allowing us to obtain the crystal state shown in Figure 10(b) as a linearly stable solution at $\Gamma=25$ with no scaling. From Figure 10(b) we see that our DFT predicts a square superlattice structure rather than a hexagonal structure for $\rho_2/\rho_1 = 1$, $m_2 = 0.2$, $\Gamma=25$. Our DFT also predicts that the small particles are localised, unlike the previous state points studied in this paper. The latter is not surprising given the much larger dipole moments of the small particles in this case. The square superlattice structure is in excellent agreement with lattice sum calculations of the zero temperature structure for this state point \cite{Fornleitner2009}. It is also consistent with experiments on binary dipolar systems for $m_2 \approx 0.1$ where square superlattice structures are found locally, though the experimental system is disordered globally as it is trapped in a glassy state \cite{Ebert2008}. The results in Figure 10 illustrate that our DFT is capable of producing a variety of stable crystal structures from first principles. For future work, it would be useful to perform a comprehensive exploration of the parameter space of the two-component system using our DFT. As our preceding discussion shows, the method works best when the computer simulation derived direct correlation functions are available close to the crystallization point (e.g., the case of Figure 10(a)). However, our DFT remains relevant even when the computer simulation data is limited by glass transitions to be far from the crystallization point (e.g., the case of Figure 10(b)), though more care is required in this case when solving the Euler-Lagrange equations to obtain stable crystal structures. We note that we did not observe any demixing of the two species in the two-component system for any of the parameters explored in this paper. This is consistent with previous results on two-component dipolar systems \cite{Hoffmann2006,Hoffmann2006b} and is a consequence of the fact that the non-additivity parameter for this system is negative for all dipole moment ratios \cite{Hoffmann2006,Hoffmann2006b}. Physically, a negative non-additivity parameter means that particles on average dislike the opposite species less than they dislike their own species, thus suppressing demixing of the different species. In principle, a negative non-additivity parameter does not preclude solid-solid phase separation occurring. However, we did not observe any evidence for such phase separations for the any of the system parameters we explored. Finally, we point out that our DFT approach, where we couple a second order theory (SOT) with simulation-derived direct correlation functions, is in principle applicable to other types of interactions and is not restricted to dipolar interactions alone. However, as the SOT under-predicts the freezing temperature \cite{vanTeeffelen2006,vanTeeffelen2008} while the simulation-derived direct correlation functions are only available above the freezing temperature, we need an additional relation to extend the direct correlation function below the freezing temperature in order to study crystallization phenomena. For dipolar interactions, this extension is provided by our heuristic scaling approximation. However, it is a non-trivial problem to carry out this extension for a general potential and this is the key rate-limiting step that we need to overcome in order to apply our DFT approach to other types of interactions. \section{Conclusions} We have constructed a DFT for both one and two-component dipolar monolayers. Our theory utilises a series expansion for the excess Helmholtz free energy functional, truncated at second order in the density profile. Although this simplification means that we cannot determine the freezing point accurately, our approach allows us to calculate \emph{ab initio} both the density profile and symmetry of the final crystal structure for both one- and two-component dipolar systems. For experimentally realistic interactions such as dipolar interactions, we found that very accurate results for the direct correlation functions are required as input to the DFT, as more simple approximations often used for soft potentials such as the random phase approximation (RPA), or even the hypernetted chain closure (HNC) and the Rogers-Young closure (RY), are not accurate enough. We therefore employed direct correlation functions based on computer simulations which are accurate up to the crystallization point of the system. We also used a heuristic scaling approximation which allowed us to extrapolate the simulation-derived direct correlation functions beyond the crystallization point of the computer simulations and induce the system to crystallize within our DFT. Our DFT predicts hexagonal crystal structures for one-component systems, and a variety of superlattice structures for two-component systems, including those with hexagonal and square symmetry. These predictions are in good agreement with known theoretical and experimental results for these systems. The theory also provides new insights into the structure of the two-component system in the intermediate temperature regime where the small particle lattice has melted but the large particle lattice remains intact. As such, the DFT bridges the gap between integral equation theory, which works well at high temperatures and lattice sum methods, valid at zero temperature, giving us a powerful \emph{predictive} tool for studying the crystallization of dipolar monolayers. For future work, it would be useful to perform a comprehensive exploration of the parameter space of the two-component system using our DFT. It would also be useful to extend the model by including third order terms in the free energy expansion \cite{vanTeeffelen2006,vanTeeffelen2008} in order to obtain more accurate results for both the freezing points and the free energies of the different crystal structures. \emph{Acknowledgements.} We gratefully acknowledge financial support from the EPSRC for this work (Grant number EP/L025078/1 Self assembly of two dimensional colloidal alloys for metamaterials applications). We also acknowledge the Viper High Performance Computing facility of the University of Hull and its support team.
\section{Introduction}\label{intro} Thanks to the increasing wealth of astronomical data it started to be possible to analyze the cosmos with model-independent analyses. The basic idea is to extract information from data without assuming the properties of the energy content of the universe nor, if possible, the overall spacetime structure \citep{Stebbins:2012vw}. While model-independent analyses may be less constraining as compared to standard analyses, they have the advantage that they can be used to verify basic assumptions such as homogeneity and isotropy and to analyze exotic models for which standard results could not be used. Indeed, it is becoming increasingly difficult to analyze alternative models as the standard model of cosmology is more and more at the heart of the ever more complex data reduction pipelines. Examples of cosmology-independent measurements are Supernova Ia model-independent calibrations \citep{Hauret:2018lnj}, expansion-rate determinations via redshift drift \citep{Martins:2016bbi} or the differential age evolution of cosmic chronometer \citep{Moresco:2018xdr} and their model-independent reconstructions \citep[see, e.g.,][and references therein]{Marra:2017pst}. A model-independent ``low-redshift standard ruler'' (which, within the standard model, coincides with the sound horizon at radiation drag) was obtained by \cite{Verde:2016ccp}, model-independent CMB constraints were obtained by \cite{Vonlanthen:2010cd}, and ``standard sirens'' -- gravitational wave detections with electromagnetic counterparts -- can provide cosmology-independent determinations of the luminosity-distance-redshift relation \citep{TheLIGOScientific:2017qsa}. Here, we will focus on constraints from Baryon Acoustic Oscillations (BAO). The standard analysis \citep[see][]{Alam:2016hwk} provides BAO measurements which are ``pseudo model-independent'' as they can easily be scaled to trial cosmologies using the Alcock-Paczynski distortion. For this method to be valid the trial cosmology must be ``sufficiently close'' to the fiducial model. For example, the 2-point correlation function template and the reconstruction technique may not be valid for, e.g., non-standard dark energy models. In order to overcome these limitations \cite{Anselmi:2015dha} introduced the ``linear point'', a model-independent BAO standard ruler which can be used also for cosmologies different from $\Lambda$CDM \citep[see also][]{Anselmi:2018hdn,Anselmi:2017zss}. Here, we wish to use a completely model-independent method, whose results could be used to constrain even the most exotic models such as inhomogeneous metrics. As we will see, the price will be a much lower significance and accuracy with respect to the standard and linear-point analyses. Model-independent angular BAO constraints were discussed, for example, by \cite{Sanchez:2010zg} in the context of a DES-like photometric redshift survey, and obtained using galaxy \citep{Alcaniz:2016ryy,Carvalho:2017tuu} and quasar \citep{deCarvalho:2017xye} catalogs of the the Baryon Oscillation Spectroscopic Survey (BOSS) of the Sloan Digital Sky Survey (SDSS). \cite{Sanchez:2012eh} proposed a simple recipe in order to measure the radial BAO in a model independent way. It was applied to a large Euclid-like $N$-body simulation and it was shown to be able to correctly obtain the BAO scale relative to the cosmology of the simulation. Here, we extend the methodology introduced in \cite{Sanchez:2012eh} in order to apply it to the final Data Release 12 of the BOSS survey \citep{Eisenstein:2011sa}. This paper is organized as follows. After describing the data in Section~\ref{data}, we describe the method in Section~\ref{method}, placing particular emphasis on the use of galaxy and angular pixel weights and on the estimation of the covariance matrix. In Section~\ref{results} we show our results---the determination of the BAO feature in redshift space. We conclude in Section~\ref{conclusions}. \section{Data}\label{data} \begin{figure} \centering \includegraphics[width= \columnwidth]{figs/SDSS-III-LRG-DR12_North-z_run107-histogram} \caption{Redshift distribution of the 720,113 galaxies of the Northern Galactic Cap (top) and the 273,117 galaxies of the Southern Galactic Cap (bottom) of the \texttt{CMASSLOWZTOT} catalog of the Data Release 12 of the BOSS survey of SDSS-III that have been used for this analysis ($0.3\le z \le 0.65$). See Table~\ref{zbins} for numerical details. } \label{fig:histz} \end{figure} The SDSS observed more than one quarter of the sky using the 2.5-m Sloan Telescope in Apache Point, New Mexico. We use the Data Release 12 (DR12) of the BOSS survey, which is the final data release and contains all SDSS observations through July 2014 \citep{Alam:2015mbd,Reid:2015gra}. DR12 features the LOWZ sample of luminous red galaxies ($z\lesssim 0.4$) and the CMASS sample of massive galaxies ($0.4\lesssim z\lesssim 0.7$), in both the Northern and Southern Galactic Caps (NGC and SGC), with a total footprint of about 10,400~deg$^2$. Figure~\ref{fig:histz} shows the redshift distributions of the 720,113 NGC galaxies and of the 273,117 SGC galaxies in the redshift interval $0.3\le z \le 0.65$. Regarding the random catalogs, we use the \texttt{random0} versions; the NGC and the SGC have 37,115,850 and 13,647,368 random points ($0.3\le z \le 0.65$), respectively, and are produced in a manner independent of cosmology. The random catalogs are about 50 times larger than the corresponding real ones. This means that the shot noise introduced by the random catalogs will be negligible as compared to the one due to the galaxy catalogs. In order to maximize the statistical significance of the BAO signal we will consider only one bin with $0.3\le z \le 0.65$, see Table~\ref{zbins} for details. The width of the bin is similar to ones adopted in \cite{Sanchez:2012eh}. \begin{table*} \begin{center} \begin{tabular}{|l|c|c|c|c|c|c|p{2.15cm}|c|} \hline \hline Redshift bin & $z_{\rm eff}$ & $[z_{\rm min},z_{\rm max}]$& $\delta z$ & $\delta \phi$ & $\delta \theta$ & galaxies& pixels with 50 or more galaxies & $\overline{\rm gal/pixel}$ \\ \hline \hline NGC &0.507 & $[0.30, 0.65]$ & 0.007 &$1.25^{\circ}$&$1.25^{\circ}$ & 720,113& 5829 & 124 \\ SGC & & &&&& 273,117&1875& 146 \\ Total & &&&& & 993,230 & 7704&129\\ \hline \hline \end{tabular} \caption{Properties of the redshift bin adopted in the analysis. The effective redshift $z_{\rm eff}$ is defined in equation \eqref{zeff}. } \label{zbins} \end{center} \end{table*} In general, the effective redshift is defined as the weighted mean redshift of the galaxies: \begin{equation} \label{zeff} z_{\rm eff} = \frac{\sum_{i} d_{i} z_{i}}{\sum_{i} d_{i}} \,, \end{equation} where $i$ labels the $i$-th galaxy with weight $d_{i}$. The equation above gives 0.494. However, as we are studying BAO, we will adopt the following more specialized estimator \citep{Beutler:2011hx}: \begin{equation} \label{zeff2} z_{\rm eff} = \frac{\sum_{i<j} d_{i} d_j (z_{i} + z_j)/2}{\sum_{i<j} d_{i}d_j} \simeq 0.507 \,, \end{equation} where the sum is over the galaxy pairs $\{i,j\}$ separated by $\Delta z_{\rm BAO}\pm \delta z$, where $\delta z$ is the redshift sub-bin discussed in the next Section. The advantage of this definition is that it considers the weighted average redshift of the galaxy pairs that contribute to the BAO signal and so it is expected to better characterize its effective redshift, especially for the large redshift bin that we are considering. As $\Delta z_{\rm BAO}$ it is not known in advance, we compute the $z_{\rm eff}$ of \eqref{zeff2} after having estimated $\Delta z_{\rm BAO}$. \section{Method}\label{method} We now extend the methodology introduced in \cite{Sanchez:2012eh} in order to apply it to observational data. Furthermore, we introduce a new method to compute the covariance matrix directly from the data, and compare it successfully to the covariance matrix obtained from the BOSS mocks. \subsection{Angular pixels} Following \cite{Sanchez:2012eh}, we divide the redshift bin into angular pixels which should be small enough in order to consider galaxies as collinear as possible and large enough in order to retain enough galaxies so that the computation of the correlation function will not be shot-noise dominated. A large angular pixel induces a change in the slope of the correlation function at small scales, a smoothing effect produced by the inclusion of galaxy pairs that are not exactly collinear. However, the scale at which this effect appears (fixed by the pixel size) is very far from the BAO scale, that therefore remains unaffected. \cite{Sanchez:2012eh} verified that one can safely use angular pixels up to 1 deg$^{2}$. We will adopt a slightly larger angular pixel of $(1.25 \, \text{deg})^2$ as our catalog is not as dense as the $N$-body catalog used by \cite{Sanchez:2012eh}. The correlation function is then calculated within these long and thin squared angular bins.% \footnote{These bins look very much like the ``spaghetti alla \href{https://it.wikipedia.org/wiki/Chitarra_(gastronomia)}{chitarra}.''} In other words, we are computing a 1-d (radial) correlation function. \subsection{Counting galaxies with weights}\label{counts} We will now discuss how to obtain the correlation function within the angular bin $\alpha$. Let us consider then the case of $n_d$ (data) galaxies $D_{i}$ with weights $d_i$ and $n_r$ (random) galaxies $R_{j}$ with weights $r_j$. Our aim is to find at which redshift separation $\Delta z$ will we find the BAO feature. Consequently, we need to compute the correlation function using redshift bins in the redshift-separation space. We will use $N$ redshift sub-bins of $\delta z=0.007$, labelled according to $\Delta z_{\beta}$. This value was chosen in order to have enough resolution to see the BAO bump and, at the same time, have enough galaxies in each bin in order not to increase shot noise. As we will use the optimal estimator by \cite{1993ApJ...412...64L}, we have to compute the galaxy-galaxy ($DD$), random-random ($RR$) and galaxy-random ($DR$) counts. \subsection{Galaxy weights}\label{weights} As explained in \cite{Reid:2015gra}, galaxies are weighted according to: \begin{equation} w_{i}= w_{{\rm sys},i} (w_{{\rm noz},i}+w_{{\rm cp},i}-1) \end{equation} where $w_{\rm sys}=w_{\rm star} \, w_{\rm seeing}$ is the total systematic weight, $w_{\rm noz}$ is the redshift failure weight and $w_{\rm cp}$ is the close pair weight. Usually, one then multiplies the above weights by the FKP weights as they are meant to optimally weight the survey galaxies \citep{Feldman:1993ky}. However, as the FKP weights do assume a cosmology and optimize the computation of the 3-d correlation function (we are computing a 1-d correlation function), we will carry out the analysis without these weights. Consequently, we will use: \begin{equation} d_{i} = w_{i} \qquad \text{and} \qquad r_{j}=1 \,. \end{equation} Figure~\ref{fig:g-weights} shows the distribution of galaxy weights and is a superposition of two distributions. The LOWZ catalog features a discrete distribution of weights at the values $\{1,2,3,4,5\}$, marked in Figure~\ref{fig:g-weights} with green gridlines. Integer values are usually due to fiber-collision upweightings. The CMASS catalog has instead a smooth distribution, peaked $\{1, 1.5, 2,3,4,5\}$. Besides fiber-collision weights, also weights specific to this higher-$z$ catalog were used, see \cite{Reid:2015gra,Ross:2016gvb} for details. \begin{figure} \centering \includegraphics[width= \columnwidth]{figs/SDSS-III-LRG-DR12_South-z_run107-g-weights} \caption{Distribution of the galaxy weights. } \label{fig:g-weights} \end{figure} \subsection{$DD$ or $RR$ counts}\label{DD} The $DD$ counting proceeds as follows; the $RR$ case is analogous. One sits on the $i$-th galaxy and counts the $n_d-1$ galaxies that fall into the various redshift sub-bins. The counts are given by the $N$-dimensional vector $\tilde v_{i}$:% \begin{equation} \tilde v_{i}=d_{i} \{ \dots, \sum_{k \in \beta} d_{k}, \dots \}_{i} \,, \end{equation} where the $k$ data galaxies are the ones that belong to that $\beta$ sub-bin. Clearly, the sum of the components of this vector is: \begin{equation} \tilde V_{i} \equiv \sum_{\beta=1}^{N} \tilde v_{i,\beta} =d_{i} \sum_{k\neq i} d_{k} \,. \label{sct} \end{equation} In order to estimate $DD$ one has to stack the contributions from all the pairs; that is, one has to sum the vectors $\tilde v_{i}$ and then normalize the result: \begin{align} DD_{\alpha} &= \frac{\sum_{i} \tilde v_{i}}{\sum_{l}\tilde V_{l} } =\frac{\sum_{i} \tilde v_{i}}{\sum_{l} d_{l}\sum_{k \neq l}d_{k}} \nonumber \\ &= \frac{\sum_{i} \tilde v_{i}}{(\sum_{l} d_{l})^{2}-\sum_{l} d_{l}^{2}} \,, \label{DD} \end{align} where $\alpha$ marks the particular angular bin we are considering. Note that: \begin{equation} \sum_{\beta=1}^{N} DD_{\alpha \beta}=1 \,. \end{equation} In the case of unitary weights one has: \begin{equation} DD_{\alpha} =\frac{1}{n_{d}(n_{d}-1)} \sum_{i=1}^{n_{d}} \tilde v_{i} \,, \end{equation} where $\tilde v_{i}$ becomes a vector of integer counts. If one, more efficiently, counts pairs only once (i.e.~not both $d_{1}d_{3}$ and $d_{3}d_{1}$), then the counts are given by the vector~$\hat v_{i}$:% \begin{equation} \hat v_{i}=d_{i} \{ \dots, \sum_{k \in \beta, k>i} d_{k}, \dots \}_{i} \,. \end{equation} Consequently: \begin{align} DD_{\alpha} &= \frac{\sum_{i} \hat v_{i}}{\sum_{l}\hat V_{l} } =\frac{\sum_{i} \hat v_{i}}{\sum_{l} d_{l}\sum_{k > l}d_{k}} \nonumber \\ &= \frac{\sum_{l} \hat v_{l}}{[(\sum_{l} d_{l})^{2}-\sum_{l} d_{l}^{2}]/2} \,, \label{eqdd2} \end{align} which in the case of unitary weights becomes: \begin{equation} DD_{\alpha} =\frac{1}{n_{d}(n_{d}-1)/2} \sum_{i=1}^{n_{d}} \hat v_{i} \,. \end{equation} The latter equation features the standard normalization. Equation~\eqref{eqdd2} gives the same counts as compared with equation~\eqref{DD}. For later use we define the total weight of the angular pixel $\alpha$ as: \begin{equation} \label{nuga1} dd_{\alpha}= \frac{(\sum_{l} d_{l})^{2}-\sum_{l} d_{l}^{2}}{2} \,, \end{equation} which generalizes the total number of different pairs in the angular pixel $\alpha$: \begin{equation} \label{nuga2} n_{dd,\alpha}= \frac{n_{d}(n_{d}-1)}{2} \,. \end{equation} \subsection{$DR$ counts}\label{DR} The $DR$ counting proceeds as follows; the $RD$ case gives exactly the same result.% \footnote{The $RD$ computation is numerically slower because there are more random galaxies than real ones so that one has to sit on more galaxies. The counting is performed vectorially. This behavior may depend on the way the calculation was implemented.} The index $i$ will label the data galaxies while the index $j$ the random galaxies. One sits on the $i$-th galaxy and counts the $n_r$ galaxies that fall into the various redshift sub-bins. The counts are given by the $N$-dimensional vector $\tilde u_{i}$:% \begin{equation} \tilde u_{i}=d_{i} \{ \dots, \sum_{k \in \beta} r_{k}, \dots \}_{i} \,, \end{equation} where the $k$ random galaxies are the ones that belong to that $\beta$ sub-bin. The sum of the components of $\tilde u_{i}$ is: \begin{equation} \tilde U_{i} \equiv \sum_{\beta=1}^{N} \tilde u_{i,\beta} = d_{i} \sum_{k} r_{k} \equiv d_{i} \, r_{\rm tot} \,, \end{equation} where we have defined the total weight $r_{\rm tot}$. In order to estimate $DR$, one has to stack the contributions from all the pairs; that is, one has to sum the vectors $\tilde u_{i}$ and then normalize the result: \begin{align} DR_{\alpha} &= \frac{\sum_{i} \tilde u_{i}}{\sum_{l}\tilde U_{l} } =\frac{\sum_{i} \tilde u_{i}}{\sum_{l} d_{l}\, r_{\rm tot} } =\frac{\sum_{i} \tilde u_{i}}{d_{\rm tot} \, r_{\rm tot} } \,. \label{DR} \end{align} Note that: \begin{equation} \sum_{\beta=1}^{N} DR_{\alpha \beta}=1 \,. \label{norma2} \end{equation} In the case of unitary weights one has: \begin{equation} DR_{\alpha} =\frac{1}{n_{d}\, n_{r}} \sum_{i} \tilde u_{i} \,, \label{DR0} \end{equation} where $\tilde u_{i}$ becomes a vector of integer counts. The latter equation features the standard normalization. For later use we define the total weight of the angular pixel $\alpha$ as: \begin{equation} dr_{\alpha}= \sum_{i} d_{i} \sum_{j} r_{j} = d_{\rm tot} \, r_{\rm tot} \,, \end{equation} which generalizes the total number of different pairs in the angular pixel $\alpha$: \begin{equation} n_{dr,\alpha}= n_{d} \, n_{r} \,. \end{equation} \subsection{Correlation function and covariance matrix}\label{pixel} After carrying out the procedure above we obtain the following quantities: \begin{align} & DD_{\alpha \beta} \phantom{bacani} dd_{\alpha} \phantom{bacano} n_{dd,\alpha} \,, \nonumber \\ & RR_{\alpha \beta} \phantom{bacana} rr_{\alpha} \phantom{bacana} n_{rr,\alpha} \,, \nonumber \\ & DR_{\alpha \beta} \phantom{bacano} dr_{\alpha} \phantom{bacano} n_{dr,\alpha} \,, \end{align} where $\alpha$ labels an angular pixes in the Northern or Southern Galactic Cap and $\beta$ labels the redshift sub-bins. \begin{figure} \centering \includegraphics[width= \columnwidth]{figs/SDSS-III-LRG-DR12_South-z_run107_bin1-corr} \caption{Correlation matrix relative to the covariance matrix $\Sigma_{\beta \beta'}$ of equation \eqref{covame}. See Table~\ref{zbins} for the bin specifications.} \label{fig:cova} \end{figure} We compute the correlation function directly in every pixel $\alpha$ and then calculate the mean vector and its $N\times N$ covariance matrix: \begin{align} \xi_{\alpha \beta} &\equiv \frac{DD_{\alpha \beta}-2DR_{\alpha \beta}+RR_{\alpha \beta}}{RR_{\alpha \beta}} \,, \\ \xi_{\beta} &= \left \langle \xi_{\alpha \beta} \right \rangle_{\alpha} \,, \label{xime} \\ \Sigma_{\beta \beta'} &= \frac{\text{cov} (\xi_{\alpha \beta})}{n_{\rm eff}} \,. \label{covame} \end{align} where we used for $\xi_{\alpha \beta}$ the optimal estimator by \cite{1993ApJ...412...64L}. As we are not mixing pixels before the computation of the correlation function, we merge Northern and Southern Galactic Cap pixels. The correlation matrix is shown in Figure~\ref{fig:cova}, while the mean correlation function and the diagonal of the covariance matrix are shown in Figure~\ref{fig:xi}. As the angular pixels feature a wide range of number of galaxies, they do not all have the same statistical constraining power: see Figure~\ref{fig:weights} where the effective number of galaxies per pixel $n^{\rm eff}_{dd,\alpha}\simeq \sqrt{2 dd_{\alpha}}$ is shown. Therefore, in order to obtain smaller errors and higher significance, it seems appropriate to weight the computation of the average $\xi_{\beta}$ and the covariance $\Sigma_{\beta \beta'}$ according to the number of galaxies present in the angular pixel. As angular pixel weights we adopted the weights $rr_{\alpha}$. The reason is that the random catalog closely follows the data catalog by construction and, at the same time, the weights $rr_{\alpha}$ are uncorrelated with the measurements so that this weighing scheme should not cause bias or increased variance. We leave to future work the study of an optimal weighting scheme akin to the one proposed by \cite{Feldman:1993ky} in order to balance sample variance and shot noise. The covariance matrix of equation \eqref{covame} is relative to the mean vector $\xi_{\beta}$. That is why it is divided by the effective number of pixels $n_{\rm eff}$: \begin{equation} n_{\rm eff} = \frac{\left(\sum_{\alpha} rr_{\alpha}\right)^{2}}{\sum_{\alpha} rr_{\alpha}^{2}} \simeq 6671 \,. \end{equation} \begin{figure} \centering \includegraphics[width= \columnwidth]{figs/SDSS-III-LRG-DR12_South-z_run107-neffgal} \caption{Distribution of the effective number of galaxies per pixel $n^{\rm eff}_{dd,\alpha}\simeq \sqrt{2 dd_{\alpha}}$, see equations (\ref{nuga1}-\ref{nuga2})} \label{fig:weights} \end{figure} \subsection{MultiDark-Patchy mocks covariance matrix}\label{mocks} The determination of the covariance matrix \eqref{covame} directly from the data is carried out under the approximation that $\xi_{\alpha \beta}$ and $\xi_{\alpha' \beta}$ are independent for $\alpha \neq \alpha'$. However, possible correlations could affect this estimation, possibly producing smaller errors and so artificially boosting the significance. In this specific case, since the BAO scale corresponds to $\sim 5$ deg at $z\sim 0.5$ \citep[see, e.g.,][figure 3]{vonMarttens:2018bvz}, 1.25 deg pixels are expected to be correlated by sample variance. In order to check this important issue we computed the correlation $\xi_{\beta}$ of equation \eqref{xime} for the 500 MultiDark-Patchy mocks made for the BOSS data. Specifically, we used the first 500 mocks of the sets \texttt{Patchy-Mocks-DR12NGC-COMPSAM\_V6C} and \texttt{Patchy-Mocks-DR12SGC-COMPSAM\_V6C}, and also the 50 times as big corresponding random catalog. See \citet{Kitaura:2015uqa,Rodriguez-Torres:2015vqa} for details regarding these mocks. We then computed the mock covariance matrix $\Sigma^{\rm mocks}_{\beta \beta'}$, which is shown via the correlation matrix in Figure~\ref{fig:covamo} and via its diagonal in Figure~\ref{fig:covadia}. The bottom panel shows the difference between the data correlation matrix and the one obtained from the BOSS mocks. The overall agreement is good, even if one may notice that the correlation between nearby redshift sub-bins is a little underestimated when computed from the data. In Figure~\ref{fig:covadia} we compare the errors: the mock covariance matrix features errors only 9\% larger, a very good agreement. We conclude that, for the special case of the fiducial $\Lambda$CDM cosmology, the covariance matrix estimated from the data with the novel procedure of Section~\ref{pixel} is trustworthy. Therefore, in the main analysis we will use the covariance matrix \eqref{covame} estimated directly from the data in order to keep the analysis model independent. We will adopt the mock covariance matrix in Section~\ref{mockcovare}. \begin{figure} \centering \includegraphics[width= \columnwidth]{figs/SDSS-III-LRG-DR12_South-z_run107_bin1-corrmocks1-R} \includegraphics[width= \columnwidth]{figs/SDSS-III-LRG-DR12_South-z_run107_bin1-corrmocks-R} \caption{Correlation matrix relative to the MultiDark-Patchy mocks (top) and difference with respect to the correlation matrix of Figure~\ref{fig:cova} which was estimated directly from the data (bottom).} \label{fig:covamo} \end{figure} \begin{figure} \centering \includegraphics[width= \columnwidth]{figs/Patchy-Mocks-DR12_run107_bin1-sig_mocks-R} \caption{Square root of the diagonal of the covariance matrix estimated from the data and of the diagonal of the covariance matrix from the MultiDark-Patchy mocks.} \label{fig:covadia} \end{figure} \subsection{BAO position}\label{bao} Within the homogeneous and isotropic FLRW model, the BAO bump in redshift space is given by~\citep{Hogg:1999ad}: \begin{equation} \Delta z_{\rm BAO}^{\rm theo} = \frac{r_{d} \, H(z)}{c} \,, \end{equation} where $r_{d}$ is the line-of-sight comoving sound horizon at the drag epoch, $H$ is the Hubble rate and $c$ is the speed of light. Using the fiducial cosmology of \citealt{Alam:2015mbd} ($\Omega_{m}=0.31$, $h=0.676$ and $\Omega_{b}h^{2}=0.022$) one obtains the theoretical prediction ($r_{d}=147.78$ Mpc): \begin{equation} \label{Dzfid} \Delta z^{\rm fid}_{\rm BAO}(z=0.507)\simeq0.04410 \,. \end{equation} However, as we are considering a large redshift bin ($0.3\le z \le 0.65$), one may obtain a more accurate prediction by adopting a method similar to the one used in equation~\eqref{zeff2}: \begin{equation} \label{Dzfid2} \Delta z^{\rm fid}_{\rm BAO} = \frac{\sum_{i<j} d_{i} d_j \, \Delta z_{\rm BAO}^{\rm theo}(\frac{z_i + z_j}{2})}{\sum_{i<j} d_{i}d_j} \simeq 0.04414 \,, \end{equation} where the sum is over the galaxy pairs $\{i,j\}$ separated by $\Delta z_{\rm BAO}\pm \delta z$. As $\Delta z_{\rm BAO}$ it is not known in advance, we compute the $\Delta z^{\rm fid}_{\rm BAO}$ of \eqref{Dzfid2} after having estimated $\Delta z_{\rm BAO}$. As we expect to detect the BAO feature at $\Delta z \approx 0.05$, we will restrict the analysis to a range of $0.01 \lesssim \Delta z \lesssim 0.1$ in order to reduce the impact of poorly sampled regions of the correlation function. \section{Results} \label{results} \begin{figure} \centering \includegraphics[width=\columnwidth]{figs/SDSS-III-LRG-DR12_South-z_run107_bin1-xi} \caption{Correlation function $\xi_{\beta}$ together with the fit to equation \eqref{para}. The error bars are from the diagonal elements of the covariance matrices; however, the points are correlated as visible in Figure~\ref{fig:cova}. } \label{fig:xi} \end{figure} In order to determine $\Delta z_{\rm BAO}$ we will use the phenomenological parametrization proposed by \cite{Sanchez:2012eh}: \begin{align} \label{para} \xi_{\parallel}(\Delta z) \!=\! A+ B e^{-C \Delta z} \!- D e^{-E \Delta z} \!+ F e^{-\frac{(\Delta z - \Delta z_{\rm BAO})^{2}}{2\sigma^2}}, \end{align} which was proven to be flexible enough so as to produce an unbiased estimation of $\Delta z_{\rm BAO}$. We define the following $\chi^{2}$ function: \begin{equation} \chi^{2} = \{\xi_{\parallel}(\Delta z_{\beta})-\xi_{\beta}\}\Sigma^{-1}_{\beta \beta'} \{\xi_{\parallel}(\Delta z_{\beta'})-\xi_{\beta'}\} \,, \label{chi21} \end{equation} where repeated indexes are summed over and $\xi_{\beta}$ is the one of equation~\eqref{xime} and shown in Figure~\ref{fig:xi}. The best-fit model is shown with a red line in Figure~\ref{fig:xi}. The $\Delta z_{\rm BAO}$ parameter describes the position of the BAO feature in redshift space, while the cosmological interpretation of the other parameters is limited, since equation \eqref{para} is an empirical description valid only in the neighborhood of the BAO peak. \begin{figure*} \centering \includegraphics[width=\textwidth]{figs/corner-dR} \caption{Triangular plot relative to the $\chi^{2}$ function of equation~\ref{chi21}. The contours contain 1-, 2- and 3-$\sigma$ of the total probability. } \label{fig:corner} \end{figure*} In order to determine the statistical error on $\Delta z_{\rm BAO}$ we perform an MCMC analysis using \texttt{emcee} \citep{ForemanMackey:2012ig} in the 8-dimensional parameter space spanned by $\{ A, B, C, D, E, F, \sigma, \Delta z_{\rm BAO} \}$. We adopted flat priors on all parameter and we constrained $F>0$ as the BAO signal is expected to be a peak. Also, we restrict the width of the peak to $0.004<\sigma<0.014$, because a tight peak cannot be constrained due to the limited resolution provided by the redshift sub-bins and a broad peak would exceed the width of the data. Also, we restrict the position of the peak to be within the data rage, $0.02<\Delta z_{\rm BAO}<0.075$. The result of this analysis is shown in Figure~\ref{fig:corner}. Interestingly, we can observe little correlation between $\Delta z_{\rm BAO}$ and the other parameters. The previous analysis gives the following model-independent BAO estimation: \begin{align} \Delta z_{\rm BAO}(z_{\rm eff}\!=\!0.507)= 0.0456_{-0.0038}^{+0.0045} \simeq 0.0456 \pm 0.0042 , \label{mibao} \end{align} which agrees with the value relative to the fiducial cosmology of \cite{Alam:2015mbd} given in equation \eqref{Dzfid2}. \cite{Sanchez:2012eh} estimated a total systematic error of 0.33\%, which is much smaller than the 9\% statistical error in equation \eqref{mibao} and can be neglected. In order to assess the significance of the detection of the BAO peak, we compare the $\chi^{2}_{\rm min}$ relative to equation~\eqref{chi21} (6 d.o.f.) with the $\chi^{2}_{\rm min}$ relative to the ``noBAO'' model, that is, equation~\eqref{chi21} with $F=0$ (9 d.o.f.). Comparing these two values provides a measure of our level of confidence that the BAO feature exists in the data. This analysis gives: \begin{equation} \chi^{2}_{\rm min}(\text{noBAO})-\chi^{2}_{\rm min}(\text{BAO}) = 12.4- 7.9=4.5 \,. \end{equation} As one expects $\chi^{2}_{\rm min}(\text{noBAO})$ to be 3 points higher owing to the increased d.o.f., the significance of the detection is small. Alternatively, the noBAO model is rejected with a $p$-value of only 0.2. Statistical errors are significantly higher and significance is lower as compared to the analysis that uses the 3-d correlation function because cross-pixel correlations cannot be used: this is the price of dropping completely basic assumptions in order to carry out a fully model-independent analysis. Future catalogs are expected to yield higher significance results. \subsection{Mock data analysis} \label{mockcovare} Here, in order to test the robustness of the method we repeat the analysis using the mock covariance matrix estimated in Section~\ref{mocks}. The result is: \begin{align} &\Delta z_{\rm BAO}= 0.0442 \pm 0.0044 \,,\\ &\chi^{2}_{\rm min}(\text{noBAO})-\chi^{2}_{\rm min}(\text{BAO}) = 13.7- 9.4=4.3 \,, \end{align} in good agreement with the main result that uses the covariance matrix obtained directly from the data. Finally, we performed the analysis using the mean correlation function from the mocks and the mock covariance matrix relative to the mean, defined as $\Sigma^{\rm mocks}_{\beta \beta'}/500$. The result is: \begin{align} &\Delta z_{\rm BAO}=0.04437 \pm 0.00024 \,,\\ &\chi^{2}_{\rm min}(\text{noBAO})-\chi^{2}_{\rm min}(\text{BAO}) = 562- 7=555 \,.\, \end{align} which shows that the phenomenological parametrization of equation \eqref{para} is a good model. The position of the BAO peak is less than 1$\sigma$ from the value relative to the fiducial cosmology give in equation~\eqref{Dzfid2}. This small bias is inconsequential for our analysis as it amounts to an offset of $0.06 \sigma$ in equation \eqref{mibao}. This bias is possibly due to the binning strategy and weighting scheme used. \section{Conclusions} \label{conclusions} In this work, using almost one million galaxies from the final data release of the BOSS survey (SDSS-III DR12), we have obtained, albeit with low significance, a model-independent determination of the radial BAO feature, see equation \eqref{mibao}. It features a 9\% error and can be used to constrain the background expansion of exotic models for which the assumptions adopted in the standard analysis of \cite{Alam:2016hwk} cannot be satisfied. This is the case, for example, of inhomogeneous models that are used to test homogeneity without assuming it~\citep{Valkenburg:2012td}. It is worth stressing that we have introduced a new method to compute the covariance matrix directly from the data, and validated it against the covariance matrix obtained from the BOSS mocks. Consequently, following the method presented in this paper, it is possible to obtain fully model-independent BAO constraints. Future galaxy catalogs from J-PAS~\citep{Benitez:2014ibt}, DESI~(\href{https://www.desi.lbl.gov/final-design-report/}{desi.lbl.gov}, \citealt{Martini:2018kdj}) and Euclid~\citep{Amendola:2016saw} will allow us to obtain high-significance model-independent determinations of the BAO peak at several redshift values. Using the formalism here presented it will be straightforward to obtain the position of the BAO feature in different angular regions so that isotropy of the universe could be directly tested. We conclude stressing that it is imperative to test the standard paradigm in a model-independent way in order to test its foundations, maximize the extraction of information from the data, and look for clues regarding the poorly understood dark energy and dark matter. \section*{Acknowledgements} It is a pleasure to thank Stefano Anselmi, David Camarena, Gabriela C.~Carvalho, Martin Crocce, Oliver Piattella, Ashley Ross for useful comments and discussions. A special thank to Álefe Almeida and Renan Oliveira for help on numerical aspects of this work. VM thanks CNPq and FAPES for partial financial support. ECI thanks CAPES for financial support. Funding for SDSS-III has been provided by the Alfred P.~Sloan Foundation, the Participating Institutions, the National Science Foundation, and the U.S. Department of Energy Office of Science. The SDSS-III web site is \href{http://www.sdss3.org/}{sdss3.org}. SDSS-III is managed by the Astrophysical Research Consortium for the Participating Institutions of the SDSS-III Collaboration including the University of Arizona, the Brazilian Participation Group, Brookhaven National Laboratory, Carnegie Mellon University, University of Florida, the French Participation Group, the German Participation Group, Harvard University, the Instituto de Astrofisica de Canarias, the Michigan State/Notre Dame/JINA Participation Group, Johns Hopkins University, Lawrence Berkeley National Laboratory, Max Planck Institute for Astrophysics, Max Planck Institute for Extraterrestrial Physics, New Mexico State University, New York University, Ohio State University, Pennsylvania State University, University of Portsmouth, Princeton University, the Spanish Participation Group, University of Tokyo, University of Utah, Vanderbilt University, University of Virginia, University of Washington, and Yale University. The massive production of all MultiDark-Patchy mocks for the BOSS Final Data Release has been performed at the BSC Marenostrum supercomputer, the Hydra cluster at the Instituto de Fısica Teorica UAM/CSIC, and NERSC at the Lawrence Berkeley National Laboratory. We acknowledge support from the Spanish MICINNs Consolider-Ingenio 2010 Programme under grant MultiDark CSD2009-00064, MINECO Centro de Excelencia Severo Ochoa Programme under grant SEV- 2012-0249, and grant AYA2014-60641-C2-1-P. The MultiDark-Patchy mocks was an effort led from the IFT UAM-CSIC by F.~Prada’s group (C.-H.~Chuang, S.~Rodriguez-Torres and C.~Scoccola) in collaboration with C.~Zhao (Tsinghua U.), F.-S.~Kitaura (AIP), A.~Klypin (NMSU), G.~Yepes (UAM), and the BOSS galaxy clustering working group.
\section{Introduction} Finsler spaces, a generalization of Riemannian spaces were named after a German mathematician Paul Finsler who studied the spaces with metric defined by the positive fourth root of a fourth order differential form. Every Riemannian space is Finsler space but not vice-versa. In Riemann-Finsler geometry, it is natural to ask under what conditions a Finsler manifold becomes Riemannian one. This is main problem of what is called Finsler rigidity theory. The best well known result toward this problem are given by Akbar-Zadeh \cite{HAZad1988} and Numata \cite{SNum1975}. Many authors (\cite{CWKimJWJim2000}, \cite{CWKimJWJim2003}, \cite{ZShe2005}, \cite{BYWu2010}) have worked on this problem with certain assumptions.\\ At the end of $20^{th}$ century, McCarthy and Rutz \cite{PJMCSFR1993} constructed spherically symmetric Finsler metric of $ \mathbb{R}^4 $ which is invariant under the transformation group of $SO(3)$ rotations. Further, in 2010, Zhou \cite{LZhou2010Arxv} introduced the general spherically symmetric Finsler metric on $ \mathbb{R}^n $ which is invariant under the rotations of $ \mathbb{R}^n$. He proved that a spherically symmetric Finsler metric $ F(x,y) $ in $ \mathbb{R}^n $ must be of the form $ F= \phi( \arrowvert x \arrowvert, \arrowvert y\arrowvert, \left\langle x, y \right\rangle ), $ where $ \phi $ is a positive smooth function, $ x \in \mathbb{R}^n, \ y \in T_x \mathbb{R}^n, \ \ \left\langle \ , \ \right\rangle $ is the standard inner product on $ \mathbb{R}^n.$\\ Guo et al. \cite{EGHLXM2013} proved that any spherically symmetric Finsler metric of isotropic Berwald curvature must be a Randers metric. Further, in \cite{BNajafi2015Arxv}, Najafi classified locally dually flat and locally projectively flat spherically symmetric Finsler metrics.\\ Recall \cite{ChernShenRFG} that a Finsler metric $F$ on an open subset $\mathcal{U}$ of $\mathbb{R}^n$ is called projectively flat if and only if all the geodesics are straight in $\mathcal{U}$. The real starting point of the investigations of projectively flat metrics is Hilbert's fourth problem \cite{Hilbert4prob}. During the International Congress of Mathematicians, held in Paris (1900), Hilbert asked about the spaces in which the shortest curves between any pair of points are straight lines. The first answer was given by Hilbert's student G. Hamel in 1903. In \cite{GHAM1903}, Hamel found necessary and sufficient conditions for a space satisfying a system of axioms, which is a modification of Hilbert’s system of axioms for Euclidean geometry, to be projectively flat. After Hamel, many authors (see \cite{SAB.GS.2016PFDF}, \cite{GS.SAB.2015PF}, \cite{GSK2017}, \cite{GS.RKS.RDSK.2017PFDF}, \cite{RY.GS.2013PF}) have worked on this topic. \\ The concept of dually flatness in Riemannian geometry was given by Amari and Nagaoka in \cite{S.I.Ama H.Nag} while they were studying information geometry. Information geometry provides mathematical science with a new framework for analysis. Information geometry is an investigation of differential geometric structure in probability distribution. It is also applicable in statistical physics, statistical inferences etc. Z. Shen \cite{ShenRFGAIG} extended the notion of dually flatness in Finsler spaces. After Shen's work, many authors have worked on this topic (see \cite{SAB.GS.2016PFDF}, \cite{GS.SAB.2017PFDF}, \cite{GSK2017}, \cite{GS.RKS.RDSK.2017PFDF}). Recently, in \cite{GSK2017}, we have worked on projectively flat and dually flat Finsler metrics. Here, we extend our study to spherically symmetric Finsler spaces. The main aim of this paper is to prove the following rigidity result: \begin{theorem}{\label{Main_Result}} Let $F=u\psi(r,s)$ be a projectively flat and dually flat spherically symmetric Finsler metric of isotropic $E$-curvature, where $ r = \arrowvert x \arrowvert,\ u= \arrowvert y\arrowvert,\ v= \left\langle x, y \right\rangle,\ s=\dfrac{v}{u}$. Then $F$ must be a Riemannian metric. \end{theorem} Current paper is organized as follows:\\ In section 2, we give basic definitions and results to be used in the study of projectively flat and dually flat spherically symmetric Finsler metrics of isotropic $E$-curvature. In section 3, we provide a formula for mean Berwald curvature of spherically symmetric Finsler metrics which is a modified version of the formula given in \cite{YCheWSon2015}. Further, in section 4, we establish two differential equations completely describing projectively as well as dually flat spherically symmetric Finsler metrics. Finally, we prove our main rigidity result (i.e. theorem \ref{Main_Result}). \section{Preliminaries} In this section, we discuss some basic definitions and results required to study afore said spaces. We refer \cite{BCS} and \cite{ChernShenRFG} for notations and further details. \begin{definition} An n-dimensional real vector space $V$ is called a \textbf{Minkowski space} if there exists a real valued function $F:V \longrightarrow [0,\infty)$, called Minkowski norm, satisfying the following conditions: \begin{enumerate} \item[(a)] $F$ is smooth on $V \backslash \{0\},$ \item[(b)] $F$ is positively homogeneous, i.e., $ F(\lambda v)= \lambda F(v), \ \ \forall \ \lambda > 0, $ \item[(c)] For a basis $\{v_1,\ v_2, \,..., \ v_n\}$ of $V$ and $y= y^iv_i \in V$, the Hessian matrix \\ $\left( g_{_{ij}}\right)= \left( \dfrac{1}{2} F^2_{y^i y^j} \right) $ is positive-definite at every point of $V \backslash \{0\}.$ \end{enumerate} \end{definition} \begin{definition} A connected smooth manifold $M$ is called a Finsler space if there exists a function $F: TM \longrightarrow [0, \infty)$ such that $F$ is smooth on the slit tangent bundle $TM \backslash \{0\}$ and the restriction of $F$ to any $T_pM, \ p \in M$, is a Minkowski norm. Here, $F$ is called a Finsler metric. \end{definition} The geodesic spray coefficients of a Finsler metric $F$ are given by $$ G^i \ := \dfrac{1}{4} g^{il} \left\{ \left( F^2\right)_{x^k y^l} y^k - \left( F^2\right)_{x^l} \right\}, \ \ \text{where}\ \ g^{ij}=\left( g_{ij} \right)^{-1}.$$ Next, we discuss spherically symmetric Finsler metrics in brief. \begin{definition} A spherically symmetric Finsler metric on $ \mathbb{R}^n$ is a metric that is invariant under all the rotations of $ \mathbb{R}^n.$ \end{definition} Recall \cite{LZhou2010Arxv} the following result: \begin{theorem} A spherically symmetric Finsler metric $ F(x,y) $ in $ \mathbb{R}^n $ is of the form $ F= \phi( \arrowvert x \arrowvert, \arrowvert y\arrowvert, \left\langle x, y \right\rangle ), $ where $ x \in \mathbb{R}^n, \ y \in T_x \mathbb{R}^n, \ \phi $ is a positive smooth function, and $ \ \left\langle \ , \ \right\rangle $ is the standard inner product on $ \mathbb{R}^n.$ \end{theorem} Write $ F=\phi(r, u, v), $ where $ r = \arrowvert x \arrowvert,\ u= \arrowvert y\arrowvert,\ v= \left\langle x, y \right\rangle.$\\ Since the Finsler metric $F$ satisfies $$ F(\lambda\ y)= \lambda\ F(y)\ \ \ \forall\ \ \lambda >0, $$ $\phi$ is positively homogeneous in $u$ and $v$ of degree one, i.e., $$ \phi= u\ \phi_u+ v\ \phi_v \ \ \text{and }\ \ F= \arrowvert y\arrowvert\ \psi(r,s),\ \ \text{where}\ \ s=\dfrac{v}{u}.$$ Recall \cite{XMLZ2014Arxv} that the geodesic spray coefficients of a spherically symmetric Finsler metric $F$ are given by \begin{equation}{\label{geocoeff}} G^i=uP y^i+u^2Q x^i, \end{equation} where \begin{equation}{\label{valQ}} Q=\dfrac{r \psi_{ss}+s \psi_{rs}-\psi_r}{2r(\psi-s \psi_s+(r^2-s^2) \psi_{ss})} \end{equation} and \begin{equation}{\label{valP}} P=\dfrac{s \psi_r+r \psi_s}{2r \psi}-\dfrac{s \psi+(r^2-s^2) \psi_{s}}{\psi}\ Q. \end{equation} \begin{definition} The Berwald curvature of a Finsler metric $F$ is defined, in local co-ordinates, as follows: $$ B:= B^i_{jkl}\ dx^j \otimes dx^k \otimes dx^j=l \otimes \dfrac{\partial}{\partial x^i},$$ where $B^i_{jkl}=\dfrac{\partial^3 G^i}{\partial y^j \partial y^k \partial y^l}$ and $G^i$ are the geodesic spray coefficients. \\ A Finsler metric $F$ is called a Berwald metric if its Berwald curvature is zero. \end{definition} Next, we state following lemma for later use: \begin{lemma}{\label{Lemma}}\cite{XMLZ2014Arxv} A spherically symmetric Finsler metric $F=u \psi(r,s)$ is a Berwald metric if and only if $P$ and $Q$ in its geodesic spray coefficients satisfy the following equations: \begin{equation} \begin{split} sP_s-P&=0,\\ P_{ss}&=0,\\ sQ_{ss}-Q_s&=0,\\ Q_{sss}&=0. \end{split} \end{equation} \end{lemma} In the study of spherically symmetric Finsler metrics, concepts of locally projectively flat and locally dually flat are quite important. Here, we discuss some related basic definitions and results.\\ \begin{definition} Two Finsler metrics $F$ and $\bar{F}$ on a manifold $M$ are called projectively equivalent if they have same geodesics as point sets, i.e., for any geodesic $\bar{\sigma}(\bar{t}) $ of $\bar{F},$ there is a geodesic $\sigma(t):=\bar{\sigma}(\bar{t}(t))$ of $F,$ where $\bar{t}=\bar{t}(t)$ is oriented re-parametrization, and vice-versa. \end{definition} Next, we recall (\cite{ChernShenRFG}, \cite{GHAM1903}) the following theorem: \begin{theorem}{\label{thm5.1}} Let $F$ and $\bar{F}$ be two Finsler metrics on a manifold $M.$ Then $F$ is projectively equivalent to $\bar{F}$ if and only if $$ {F}_{x^ky^\ell}y^k-{F}_{x^\ell}=0. $$ Here the spray coefficients are related by $G^i=\bar{G}^i+Py^i,$ where $ P=\dfrac{F_{x^k}y^k}{2F}$ is called projective factor of $F.$ \end{theorem} It is well known that if $\bar{F}$ is a standard Euclidean norm on $\mathbb{R}^n,$ then spray coefficients of $\bar{F}$ vanish identically, i.e., $ \bar{G}^i=0.$ As geodesics are straight lines in $\mathbb{R}^n,$ we have the following: \begin{definition} For a Finsler metric $F$ on an open subset $\mathcal{U}$ of $\mathbb{R}^n,$ the geodesics of $F$ are straight lines if and only if the spray coefficients satisfy $$G^i=Py^i, $$ where $P$ is same as defined in theorem \ref{thm5.1}. \end{definition} Thus, for a projectively flat spherically symmetric Finsler metric on an open subset $\mathcal{U}$ of $\mathbb{R}^n,$ the coefficient $ Q, $ occurring in the equation (\ref{geocoeff}) vanishes identically. \begin{definition}{\label{def5.4}}\cite{ChernShenRFG} A Finsler metric $F$ on an open subset $\mathcal{U}$ of $\mathbb{R}^n$ is called projectively flat if and only if all the geodesics are straight in $\mathcal{U},$ and a Finsler metric $F$ on a manifold $M$ is called locally projectively flat, if at any point, there is a local co-ordinate system $ (x^i) $ in which $F$ is projectively flat. \end{definition} Therefore, by theorem (\ref{thm5.1}) and definition (\ref{def5.4}), we have \begin{theorem} A Finsler metric $F$ on an open subset $\mathcal{U}$ of $\mathbb{R}^n$ is projectively flat if and only if it satisfies the following system of differential equations $$ {F}_{x^ky^\ell}y^k-{F}_{x^\ell}=0,$$ where $G^i=Py^i$ is spray coefficient and $P$ is same as defined in theorem \ref{thm5.1}. \end{theorem} \begin{definition} \cite{ShenRFGAIG} A Finsler metric $F$ on a smooth $n$-manifold $M$ is called locally dually flat if, at any point, there is a standard co-ordinate system $ (x^i, y^i) $ in $TM,$ $(x^i)$ called adapted local co-ordinate system, such that $$ L_{x^ky^\ell}y^k-2L_{x^\ell}=0,\ \text{where}\ L=F^2.$$ \end{definition} Recall \cite{XCheZSheYZho2010} the following proposition for further use. \begin{prop}{\label{Cond_Projectively_and_Dually}} Let $F = F(x, y)$ be a Finsler metric on an open subset $ \mathcal{U}$ of $ \mathbb{R}^n $. $F$ is projectively as well as dually flat on $ \mathcal{U}$ if and only if $F_{x^k} = k_1FF_{y^k},$ where $k_1$ is a constant independent of $y$. \end{prop} \section{Spherically symmetric Finsler metrics with isotropic $E$-curvature} There is a non-Riemannian quantity, $S$-curvature, used to measure the rate of change of the volume form of a Finsler space $ (M,F) $ along geodesics. Suppose $\gamma$ be a geodesic with $\gamma(0)=x, \ \dot{\gamma}(0)=y, $ where $x \in M \ \text{and}\ y \in T_xM,$ and let $ dv=\sigma(x) dx $ be a given volume form of $F$. Then $ S$-curvature is defined by $$ S(x,y)= \dfrac{d}{dt}\bigg\{\tau\bigg( \gamma(t), \dot{\gamma}(t)\bigg) \bigg\}\bigg|_{t=0},$$ where $ \tau= \tau(x,y)$ is the distortion function of Minkowski norm $F_x$ on $T_xM$ given by $$\tau(x,y)=\ln\left( \dfrac{\sqrt{det(g_{ij}(y))}}{\sigma(x)}\right) , \ \ y \ \in\ T_xM \backslash \{0\}. $$ Recall \cite{ChernShenRFG} that $S$-curvature can also be represented in the following way \begin{equation*} S(x,y)=\dfrac{\partial G^k}{\partial y^k}-y^k \dfrac{\partial}{\partial x^k}\left(\ln \sigma(x) \right). \end{equation*} There is another entity associated with $S$-curvature, called $E$-curvature or mean Berwald curvature given by the $E$-tensor $$ \mathcal{E}:=E_{ij} \ dx^i \otimes dx^j, $$ where \begin{equation}{\label{Val_E-Curv}} E_{ij}=\dfrac{1}{2} S_{y^i y^j}(x,y) =\dfrac{1}{2} \dfrac{\partial ^2}{\partial y^i \partial y^j}\left( \dfrac{\partial G^k}{\partial y^k}-y^k \dfrac{\partial}{\partial x^k}\left(\ln \sigma(x) \right)\right) =\dfrac{1}{2} \dfrac{\partial ^2}{\partial y^i \partial y^j}\left( \dfrac{\partial G^k}{\partial y^k}\right) \end{equation} The $E$-tensor $\mathcal{E}$ can be viewed as the family of symmetric forms $$E_y: T_xM \times T_xM \longrightarrow \mathbb{R} $$ defined by $$ E_y(u,v)=E_{ij}(x,y)u^i v^j,\ \ \text{where}\ \ u=u^i \dfrac{\partial}{\partial x^i},\ v=v^i \dfrac{\partial}{\partial x^i} \in T_xM,\ x \in M. $$ The collection $E=\biggl\{E_y : y \in TM \backslash \{0\} \biggr\}$ is called $E$-curvature or mean Berwald curvature.\\ During the study on spherically symmetric Finsler metrics, we find that the formula for $E$-curvature of a spherically symmetric Finsler metric given in \cite{YCheWSon2015} (Proposition $3.1$) is not correct. In the following theorem, we give the correct version of that formula. \begin{theorem}{\label{Thm3.1}} Let $F=u \psi(r,s)$ be a spherically symmetric Finsler metric on an open subset $ \mathcal{U}$ of $ \mathbb{R}^n,$ where $ r = \arrowvert x \arrowvert,\ u= \arrowvert y\arrowvert,\ v= \left\langle x, y \right\rangle,\ s=\dfrac{v}{u}$. Then $E$-curvature of $F$ is given by \begin{equation}{\label{E-Curvature}} \begin{split} E_{ij}=&\dfrac{1}{2}\biggl[\dfrac{1}{u} \biggl\{ (n+1)P_{ss} +2 Q_s +(r^2-s^2) Q_{sss} -2s Q_{ss} \biggr\} x^i x^j \\ &+\dfrac{1}{u^2}\biggl\{ -(n+1)s P_{ss} -2s Q_s -s(r^2-s^2) Q_{sss} +2s^2 Q_{ss} \biggr\}\left(x^i y^j+y^i x^j \right)\\ &+\dfrac{1}{u^3} \biggl\{ (n+1)s^2 P_{ss} +2s^2 Q_s +s^2(r^2-s^2) Q_{sss} -2s^3 Q_{ss} +(n+1)s P_{s} - (n+1) P \\ &+s(r^2-s^2) Q_{ss} -(r^2-s^2) Q_{s}\biggr\}y^i y^j\\ &+\dfrac{1}{u} \biggl\{ -(n+1)s P_{s} +(n+1) P -s(r^2-s^2) Q_{ss} +(r^2-s^2) Q_{s}\biggr\} \delta_{ij} \biggr] \end{split} \end{equation} \end{theorem} \begin{proof} The geodesic spray coefficients of a spherically symmetric Finsler metric given in equation (\ref{geocoeff}), can be re-written as \begin{equation*}{\label{Val_G^k}} G^k=uP y^k+u^2Q x^k \end{equation*} Differentiating it partially w.r.t. $y^k$ and taking the sum over $ k=1 \ \text{to}\ n, $ we get \begin{equation}{\label{Val_Derv_G^k}} \dfrac{\partial G^k}{\partial y^k}=u(n+1)P+2usQ+u(r^2-s^2)Q_s. \end{equation} Further, differentiating (\ref{Val_Derv_G^k}) partially w.r.t. $y^i$, we get \begin{equation}{\label{Val_DDerv_G^k}} \begin{split} \dfrac{\partial}{\partial y^i} \left(\dfrac{\partial G^k}{\partial y^k}\right) =&\left\{ (n+1)P_s+2Q+(r^2-s^2) Q_{ss}\right\} x^i\\ &+ \left\{ -\dfrac{(n+1)s}{u}P_{s} +\dfrac{n+1}{u}P -\dfrac{s(r^2-s^2)}{u}Q_{ss} +\dfrac{r^2-s^2}{u} Q_{s} \right\} y^i. \end{split} \end{equation} Again, differentiating (\ref{Val_DDerv_G^k}) partially w.r.t. $y^j$, we get \begin{equation}{\label{Val_TDerv_G^k}} \begin{split} \dfrac{\partial^2}{\partial y^i \partial y^j} \left(\dfrac{\partial G^k}{\partial y^k}\right) &=\biggl( (n+1)P_{ss}+2Q_s+(r^2-s^2) Q_{sss}-2sQ_s\biggr) \left(\dfrac{x^i x^j}{u} -\dfrac{s}{u^2} x^i y^j \right) \\ &+\dfrac{1}{u^3}\biggl( (n+1)s P_{s} -(n+1)P +s(r^2-s^2) Q_{ss} -(r^2-s^2) Q_{s} \biggr) y^i y^j\\ &+\dfrac{1}{u} \biggl( -(n+1)s P_{ss} -s(r^2-s^2)Q_{sss} +2s^2 Q_{ss}-2sQ_s \biggr)\left(\dfrac{x^j y^i}{u} -\dfrac{s}{u^2} y^i y^j \right)\\ &+\dfrac{1}{u}\biggl( -(n+1)s P_{s} +(n+1)P -s(r^2-s^2) Q_{ss} +(r^2-s^2) Q_{s} \biggr)\delta_{ij}. \end{split} \end{equation} From equation \ref{Val_TDerv_G^k}, one can easily obtain equation (\ref{E-Curvature}), which proves the theorem \ref{Thm3.1}. \end{proof} Using the formula \ref{E-Curvature} for $E$-curvature, we find the differential equation characterizing a spherically symmetric Finsler metric with isotropic $E$-curvature as follows: \begin{theorem}{\label{Iso_E_Cur}} A spherically symmetric Finsler metrics $F=u\psi(r,s)$ on an open subset $ \mathcal{U}$ of $ \mathbb{R}^n$ has isotropic $E$-curvature if and only if \begin{equation} (n+1)(P-sP_s)+(r^2-s^2)(Q_s-sQ_{ss})=(n+1)c(x)(\psi-s\psi_s), \end{equation} where $c=c(x)$ is a scalar function on $M$. \end{theorem} The equation \ref{Iso_E_Cur} is same as the one given in \cite{YCheWSon2015}. \section{Rigidity of spherically symmetric Finsler metrics} The main aim of this section is to prove the rigidity theorem \ref{Main_Result}, but before that we prove the following theorem. \begin{theorem}{\label{SSFM_Cond_Projectively_and_Dually}} Let $F=u \psi(r,s)$ be a spherically symmetric Finsler metric on an open subset $ \mathcal{U}$ of $ \mathbb{R}^n,$ where $ r = \arrowvert x \arrowvert,\ u= \arrowvert y\arrowvert,\ v= \left\langle x, y \right\rangle,\ s=\dfrac{v}{u}$. Then $F$ is projectively as well as dually flat on $ \mathcal{U}$ if and only if following equations are satisfied: $$ \dfrac{1}{r} \psi_r=k_1 \psi \psi_s,\ \ \psi_s= k_1\left( \psi^2-s \psi \psi_s \right), $$ where $k_1$ is a constant independent of $y$. \end{theorem} \begin{proof} We have $$F=u \psi(r,s)$$ Differentiating it partially w.r.t. $ x^k $ and $y^k$ respectively, we get $$ F_{x^k}=\dfrac{u}{r} \psi_r x^k+\psi_s y^k,$$ and $$ F_{y^k}= \psi_s x^k- \dfrac{s}{u} \psi_s y^k+ \dfrac{1}{u} \psi y^k. $$ By proposition \ref{Cond_Projectively_and_Dually}, $F$ is projectively as well as dually flat on $ \mathcal{U}$ if and only if $$F_{x^k} = k_1FF_{y^k},$$ where $k_1$ is a constant independent of $y$.\\ Therefore, $F$ is projectively as well as dually flat on $ \mathcal{U}$ if and only if $$ \dfrac{u}{r} \psi_r x^k+\psi_s y^k=k_1 u \psi\left( \psi_s x^k- \dfrac{s}{u} \psi_s y^k+ \dfrac{1}{u} \psi y^k \right).$$ From this we conclude that $F$ is projectively as well as dually flat on $ \mathcal{U}$ if and only if $$ \dfrac{1}{r} \psi_r=k_1 \psi \psi_s,\ \ \psi_s= k_1\left( \psi^2-s \psi \psi_s \right). $$ \end{proof} \begin{cor}{\label{corr}} For a spherically symmetric Finsler metric $F=u \psi(r,s)$ on an open subset $ \mathcal{U}$ of $ \mathbb{R}^n,$ where $ r = \arrowvert x \arrowvert,\ u= \arrowvert y\arrowvert,\ v= \left\langle x, y \right\rangle,\ s=\dfrac{v}{u}$, $P$ and $Q$ in its geodesic spray coefficients satisfy the following: \begin{equation}{\label{PFDF_Geo_coeff_P_Q}} P=\dfrac{k_1}{2} \psi, \ \ Q=0. \end{equation} \end{cor} \vspace*{.1cm} \noindent \textbf{\Large Proof of rigidity theorem \ref{Main_Result} }\\ \vspace*{.05cm}\\ Since $Q=0$ for projectively flat spherically symmetric Finsler metric, by the theorem \ref{Iso_E_Cur}, we see that $F$ has isotropic $E$-curvature if and only if \begin{equation}{\label{Der_P_Psi}} P-sP_s=c(x)(\psi-s\psi_s), \end{equation} where $c=c(x)$ is a scalar function on $M$.\\ From (\ref{Der_P_Psi}), we get $$\dfrac{d}{ds}\left(\dfrac{P}{s} \right) = c(x) \dfrac{d}{ds}\left(\dfrac{\psi}{s} \right) $$ which implies $$ P = c(x) \psi -s \gamma(r). $$ By corollary \ref{corr}, we have $P=\dfrac{k_1}{2} \psi.$\\ Therefore, $$ \psi= \dfrac{2s}{2c(x)-k_1} \gamma(r), $$ and consequently \begin{equation} P=k(r) s, \ \ \text{where \ } k(r)= \dfrac{k_1\ \gamma(r)}{2c(x)-k_1}. \end{equation} Putting the values of $P$ and $Q$ in equation (\ref{valP}), we get \begin{equation}{\label{Hash}} 2rsk(r) \psi -s \psi_r-r \psi_s=0. \end{equation} Differentiating (\ref{Hash}) w.r.t. $s$, we get \begin{equation}{\label{Star}} 2rk(r) \psi +2rsk(r) \psi_s-r\psi_{ss}-s\psi_{rs}-\psi_r=0. \end{equation} From equation (\ref{valQ}), we have \begin{equation}{\label{2Star}} r \psi_{ss}+s \psi_{rs}-\psi_r =0. \end{equation} Solving equations (\ref{Star}) and (\ref{2Star}), we get \begin{equation}{\label{2Hash}} rk(r) \psi +rsk(r) \psi_s-\psi_r=0. \end{equation} By the equations (\ref{Hash}) and (\ref{2Hash}), we get $$ \psi= k_2(r) \sqrt{1+s^2 k(r)}, \ \ \text{where}\ \ k_2(r)\ \text{is a function independent of s}, $$ which yields $$ F= k_2(r) \sqrt{\arrowvert y\arrowvert^2+k(r) \left\langle x, y \right\rangle^2} $$ which is a Riemannian metric.
\section{Introduction} The vast majority of the current big data, coming from, for example, high performance high fidelity numerical simulations, high resolution scientific instruments (microscopes, DNA sequencers, etc.) or Internet of Things streams and feeds, is a result of complex non-linear processes. While these non-linear processes can be characterized by low dimensional manifolds, the actual observable data they generate is high-dimensional. This high-dimensional data is inherently difficult to explore and analyze, owing to the {\em curse of dimensionality} and {\em empty space phenomenon} that render many statistical and machine learning techniques (e.g. clustering, classification, model fitting, etc.) inadequate. In this context, non-linear spectral dimensionality reduction has proved to be an indispensable tool~\cite{Lee2007}. The non-linear spectral dimensionality reduction methods rely on a spectral decomposition of a feature matrix that captures properties of the underlying manifold, and effectively bring the original data into a more human-intuitive low dimensional space that makes quantitative and qualitative analysis of non-linear processes possible (e.g., by enabling visualization). However, the leading manifold learning methods, such as considered here Isomap~\cite{Tenenbaum2000}, remain infeasible when presented with the current large-scale data. This is because of both computational and memory complexity that are at least quadratic in the number of input points. In this paper, we propose a distributed memory framework to address complexity of the end-to-end exact Isomap under Apache Spark model. We show how each critical step of the Isomap algorithm can be efficiently expressed under the basic Spark model, without the need to provision data in the secondary storage. To achieve efficient and portable software realization, we implement the entire method using PySpark, and we offload compute intensive linear algebra routines to high performance BLAS library. Through experimental results, we demonstrate that the resulting software exhibits excellent parallel scalability, and even on a small parallel cluster can be used to process datasets orders of magnitude larger than what is possible withe the current methods, without sacrificing quality. Our specific contributions include Apache Spark-based efficient direct $k$NN solver based on 1D data decomposition, scalable all-pairs shortest-path (APSP) solver leveraging ideas from communication avoiding algorithms, and practical eigendecomposition solver based on power iteration. All components are combined into end-to-end workflow realizing in-memory Isomap. The reminder of the paper is organized as follows. In Section~\ref{sec:prelim}, we formally state the problem and briefly introduce the basic Isomap algorithm. In Section~\ref{sec:sparkiso}, we provide detailed description of our proposed approach, focusing on each individual Isomap component and its realization in Apache Spark. In Section~\ref{sec:results}, we showcase the resulting software on several benchmarks, assessing accuracy and parallel scalability, and we demonstrate its practical value by analyzing over 50000 EMNIST images. Finally, in Section~\ref{sec:relwork}, we survey related work, and conclude the paper in Section~\ref{sec:end}. \section{Preliminaries}\label{sec:prelim} In manifold learning, we assume that a given dataset $X = \{x_0, x_1, ..., x_{n-1}\}$ of $n$ points, where each $x_i \in \mathbb{R}^{D}$, is sampled from some manifold $\mathcal{M}$ of latent dimension~$d$, $d \ll D$. Our goal is to find a set $Y = \{y_0, y_1, ..., y_{n-1}\}$ such that $y_i\in\mathbb{R}^{d}$ and $\forall_{i, j}$ $d_{\mathcal{M}}(x_i, x_j) \approx | y_i - y_j |_{h}$, where $d_{\mathcal{M}}(\cdot)$ measures the actual distance between pair of points on $\mathcal{M}$, and the relation $|a-b|_h$ captures some property between points $a$ and $b$. In this work, we focus on the case where $|\cdot|_h$ is $\lVert \cdot \rVert_{2}$, that is, we seek a $d$-dimensional representation,~$Y$, of~$X$ that preserves manifold distances. The state-of-the-art method for geodesic distance preserving manifold learning is Isomap~\cite{Tenenbaum2000}. The method falls under the category of non-linear spectral dimensionality reduction techniques~\cite{Lee2007}, and it requires a series of data transformations shown in Alg.~\ref{alg:isomap}. In the first step, the dataset $X$ is used to construct a neighborhood graph, $G$, where each node of the graph is connected to its $k$ nearest neighbors ($k$NN), with respect to the Euclidean metric. Here $k$NN distances capture local manifold distances in the neighborhood of each data point. This step requires $\mathcal{O}(n^{2})$ distance computations, thus having complexity $\mathcal{O}(Dn^{2})$. In the second step, the neighborhood graph $G$ is analyzed to construct a feature matrix, $A$, that captures the information to be preserved in dimensionality reduction. Because shortest paths induced by neighbor relations have been shown to be a good approximation of the actual manifold distance between points~\cite{Bernstein2000}, $A$ stores the shortest paths between all pairs of points in the neighborhood graph $G$. Consequently the cost of this step is $\mathcal{O}(n^{3})$. The penultimate step is a spectral decomposition of $A$. The resulting top $d$ eigenvectors, $Q_d$, and eigenvalues, $\Delta_d$, are required as their product yields the final output set $Y$. The spectral decomposition step has complexity $\mathcal{O}(n^{3})$. We note that before spectral decomposition, the feature matrix $A$ is usually double-centered to ensure that the origin is contained in the final output (instead of being an~affine~translation). \begin{Algorithm}[\columnwidth] \caption{\textsc{Isomap}} \begin{algorithmic}[1] \REQUIRE $X$, $d$, $k$ \ENSURE $Y$ \STATE $G$ = \textsc{kNN}($X$, $k$) \STATE $A$ = \textsc{AllPairsShortestPaths}($G$) \STATE $D$ = \textsc{DoubleCenter}($A^{\circ 2}$) \STATE $(Q_{d},\Delta_{d})$ = \textsc{EigenDecomposition}($D$) \STATE $Y$ = $Q_d \cdot \Delta_d^{\circ \frac{1}{2}}$ \RETURN{$Y$} \end{algorithmic} \label{alg:isomap} \end{Algorithm} While Isomap is the method of choice in many practical applications~\cite{Lee2007}, it is too computationally and memory intensive for even modest size datasets. For example, commonly available sequential implementations in Matlab and Python scale to datasets with $n=4000$ points. In contrast, datasets emerging in scientific applications, e.g.~\cite{Turnbaugh2007, Marchand2009,Thirion2004, Li2012}, routinely involve hundreds of thousands of points. \section{Proposed Approach}\label{sec:sparkiso} The computational complexity of Isomap arises from the cost of both construction and spectral decomposition of the feature matrix. The memory cost comes from the $\Theta$($n^2$) size of the feature matrix that has to be maintained throughout the process. To alleviate these complexities, several approximate methods have been proposed~\cite{deSilva2003,Talwalkar2008}. However, these approaches do not provide exactness guarantees, or are tailored for large-scale HPC systems~\cite{Samudrala2015}. In our proposed approach, we focus on exact solution targeting Apache Spark clusters that are easy to deploy, and are accessible to many potential~end-users. Our main idea is to cast the Isomap workflow into the Apache Spark model, such that the intermediate data is never explicitly provisioned to the persistent storage, and each step of the workflow is efficiently expressed via Spark transformations implemented in PySpark and Python, with computationally intensive algebraic routines offloaded to a dedicated BLAS engine (e.g., Intel MKL). \subsection{\texorpdfstring{$k$NN}{kNN} Search}\label{ssec:knn} The first step of Isomap is $k$ nearest neighbors search. The direct approach to $k$NN is for each point to compute the distance to each of the $n-1$ others, recording the $k$ minimum in the process. This requires $\Theta$($n^2$) comparisons and $\Theta$($nk$) space. Theoretically, this approach can be improved by the use of spatial data structures such as $k$-$d$ trees, quad-trees, R-trees, or Voronoi diagrams~\cite{Bentley1975,Kim2016}. However, due to the \emph{curse of dimensionality}, the performance of these data structures quickly deteriorates to the direct method as dimensionality $D$ increases~\cite{Weber1998}. Therefore, in our approach we propose scalable Spark realization of the direct~$k$NN~method. \begin{figure} \centering \includegraphics[scale=0.875]{X-block}~~ \includegraphics[scale=0.875]{M-block}~~ \includegraphics[scale=0.875]{KNN} \caption{Left: 1D decomposition of the input data $X$. Middle: Matrix $M$ and example row $i$. Right: $k$NN RDD and element of list $L_k$.}\label{fig:KNN} \end{figure} We first 1D-decompose the input data $X$ into $\lceil \frac{n}{b}\rceil$ logical blocks (see Fig.~\ref{fig:KNN}). We achieve this by loading the entire $X$ into RDD, such that single point is stored as one 1D NumPy array, and then executing \spark{combineByKey} transformation. The transformation assigns to a point its block identifier, and points are grouped into a 2D NumPy array corresponding to a block. Hence, at the end of this step, each point in $X$ is assigned to a unique block $X_I$, for $0 \leq I < q = \lceil \frac{n}{b} \rceil$. By decomposing $X$ in this way, we can exploit symmetry of the distance matrix over $X$, and efficiently compute only its upper-triangular portion. This is contrary to the standard and expensive approach based on Spark \spark{cartesian}, which produces RDD elements $(I, J)$ and $(J, I)$, requiring additional \spark{filter} operation to obtain the final upper-triangular form. Using \spark{flatMap} transformation, we enumerate all block pairs $(X_I, X_J)$, where each $X_I$ is paired with all $X_J$, for $J \geq I$. The resulting RDD, stores each block pair as a tuple $((I,J), (X_I,X_J))$. Although this induces data replication, it also directly exposes parallelism in computing the distance matrix that dominates the computational work of $k$NN search. We exploit this parallelism when materializing the upper-triangular distance matrix, $M$. Specifically, we apply \spark{map} transformation that for each pair $(X_I, X_J)$ carries all-pairs distance computations to yield sub-matrix $M^{(I, J)}_{i,j} = \lVert x_{i} - x_{j} \rVert_{2}$, $\forall x_{i}\in X_I, x_{j}\in X_J$. Here, computing $\lVert x_{i} - x_{j} \rVert_{2}$ is delegated to SciPy, which offloads distance computations to the efficient BLAS library (e.g., Intel MKL). At the end, the entire block $M^{(I, J)}_{i, j}$, stored as 2D NumPy array, becomes a single element of the resulting RDD with $M$. The RDD is persisted in the main memory for further~processing. The next step is to identify nearest neighbors of each $x_i \in X$ with respect to matrix $M$. When $M$ is in the block form, each row $i$ of $M$ is scattered across multiple column-blocks~$J$ (see Fig.~\ref{fig:KNN}). With each such chunk of row $i$ we can associate the same pair $(I, i_{\textrm{loc}})$, where $I$ identifies row-block containing $i$, and $i_{\textrm{loc}}$ is local identifier of row $i$ within row-block $I$ (since within a block, rows are indexed from~0, and we have that $i = I\cdot b + i_{\textrm{loc}}$). We exploit this property, and for each point $x_i$ we identify the minimum $k$ elements as follows. First, within each block $M^{(I,J)}$ for every $i_{\textrm{loc}}$ we identify a list of $k$ minimal values, $L_k$. We achieve this in parallel via \spark{flatMap} transformation that employs standard heap-based algorithm to maintain minimal values, and yields tuples $((I, i_{\textrm{loc}}), L_k)$. Here, $L_k$ stores coordinates of the selected minimal values, and the values themselves. Recall that we do not explicitly represent $M^{(I, J)}$ for $I > J$. Therefore, to obtain row minima for blocks under diagonal of $M$, our \spark{flatMap} routine considers also transpositions $(M^{(J,I)})^{T}$. Next, using \spark{combineByKey} transformation, we reduce all local minima, contained in lists $L_k$, into the global $k$NN list for each~$x_{i}$ (see Fig.~\ref{fig:KNN}). While at this point we could finalize $k$NN search, we apply one more round of transformations, to efficiently convert $k$NN into the neighborhood graph $G$, such that it is ready for processing via all-pairs shortest-paths solver. The idea is to reuse data blocks maintained by RDD storing~$M$, to store~$G$. To this end, we apply \spark{map} transformation to the $k$NN and for each~$x_i$ we produce key-value pair $((I, J), (i_{\textrm{loc}}, j_{\textrm{loc}}, d))$, where tuple $(J, j_{\textrm{loc}}, d)$ identifies nearest neighbor of $x_i$. This enables us to associate each $k$NN distance with the sub-block of $M$ to which it belongs. Thus, we use \spark{union} to combine the resulting RDD with the original block matrices of $M$, and we follow with \spark{combineByKey} transformation. The transformation fills blocks $(I,J)$ of $M$ with $\infty$, and then sets the actual neighbor distances according to $(i_{\textrm{loc}}, j_{\textrm{loc}}, d)$. The resulting neighborhood graph, $G$, is stored as RDD of blocks of size $b \times b$, in exactly the same way as $M$, benefiting from the fact that $M$ is persistent and minimizing NumPy arrays reallocation. \begin{figure}[t] \centering \includegraphics[scale=0.9]{RDD-block} \caption{Example of assignment of logical blocks to RDD partitions. Number inside a block indicates RDD partition storing the block.} \label{fig:rddblock} \end{figure} The 1D decomposition we use in our $k$NN solver, and the induced 2D decomposition of matrix $M$, are logical and separate from the physical RDD partitioning employed by the Spark runtime. Moreover, instead of relying on the default Spark partitioner, we use a custom partitioner tailored for managing upper-triangular matrices. This is motivated by the performance considerations. The partitioner assigns an integer to each block of the matrix in the row-major fashion. Hence, when the number of RDD partitions $p'$ is equal to the number of logical blocks, the assignment is exactly the upper-triangular row-major index for block $(I, J)$. When this number is less than $\frac{q\cdot (q+1)}{2}$, we store $B = \frac{Q}{p'}$ blocks per partition, where $Q = \frac{q\cdot (q+1)}{2}$. Specifically, we assign the first $B$ blocks to partition 0, the next $B$ blocks to partition 1, and so on (see Fig.~\ref{fig:rddblock}). In our experiments, we found that this strategy of assigning multiple blocks to single RDD partition provides better data locality than the default partitioner or \spark{GridPartitioner} found in the MLlib library~\cite{Meng2016} (a popular machine learning library for Apache Spark). This is because neighboring blocks are stored near one another in RDD, which leads to improved data locality and reduced data shuffling. Therefore, we employ the same custom partitioner in the APSP solver (see below). \subsection{All-pairs Shortest-paths Computation}\label{sssec:apsp} Given the neighborhood graph $G$, the next step in the Isomap workflow is to solve all-pairs shortest-paths (APSP) in $G$. Recall that shortest paths approximate manifold distances between data points~\cite{Bernstein2000}, and hence they will form the feature matrix $A$. Two commonly used algorithms for APSP are Dijkstra and Floyd-Warshall~\cite{Cormen2009}. However, both methods are ill-suited for Spark model, owing to low computation rate compared to the data movement rate. An alternative approach involves a special case of the matrix power $A^{n}$~\cite{Kepner2011}. Consider matrix multiplication over the semiring $\overline{\mathbb{R}}_{+} = \mathbb{R}_{+} \cup \{+\infty\}$ with additive and multiplicative operations, $\oplus$ and $\otimes$. The additive operation is \emph{minimum} and the multiplicative operation is \emph{scalar addition}, that is $x\oplus y \mapsto \min\{x, y\}$ and $x\otimes y \mapsto x + y$. In this way we reduce APSP to repeated matrix multiplication of $G$ by itself (we refer to this method as \emph{min-plus}). This is still not ideal: regular data movement patterns like those in matrix multiplication are unsuitable for data shuffles that occur under the Spark model. In fact, matrix multiplication is yet to see efficient realization in Spark~\cite{Bosagh2016}. Therefore, we take a middle-ground approach. We cast an iterative communication-avoiding APSP algorithm by Solomonik et al.~\cite{Solomonik2013}, which is based on the block formulation of Floyd-Warshall~\cite{Venkataraman2003}, into Spark model, and we use min-plus to batch update $b\times b$ blocks of shortest paths values. It turns out that communication-avoiding algorithms, technique well known in High Performance Computing, enable us to minimize data shuffles, leading to efficient Spark realization. We note that the correctness of this algorithm follows directly from that of computing the transitive closure, and has been discussed, e.g., in~\cite{Solomonik2013,Venkataraman2003}. In our approach, we iteratively update the entire APSP adjacency matrix, $G$, in three phases (Fig.~\ref{blockfloydphases} illustrates in which phase which block of $G$ is updated). In the first phase, we solve sequential Floyd-Warshall restricted to a single sub-block on the diagonal. This is the first diagonal block when iteration $I = 0$. Once we have solved the diagonal block we share the solution with blocks in the same row (and column). This begins Phase~2. Upon receiving the diagonal block, we perform min-plus matrix multiplication to in-place update Phase~2 blocks. In the final phase, all remaining blocks receive two matrices from Phase~2. One matrix is sent from the block in the shared row and the other from the shared column. After computing the min-plus product of the received matrices, we update Phase 3 blocks in-place. The process repeats with successive diagonal blocks. At the conclusion of all 3 phases for the final diagonal block, all matrix entries contain the corresponding shortest path length. \begin{figure}[t] \centering \includegraphics[scale=0.9]{APSP} \caption{Phases of computation for iteration $\hat{I}$ along critical path defined by the block diagonal. In Phase~1, sequential Floyd-Warshall is performed on diagonal block $(I,I)$. In Phase~2, the solution of the diagonal block is passed to, and multiplied with, all off-diagonal blocks in the $I^{th}$ row and $I^{th}$ column. In Phase~3, all remaining blocks $(\hat{I}, J)$ are updated using the product of blocks $(\hat{I}, I)$ and $(I, J)$ from Phase~2.} \label{blockfloydphases} \end{figure} We realize the above algorithm in Spark, starting from the persisted RDD $M$ representing graph $G$. We proceed iteratively over blocks, $G^{(I, I)}$, on the diagonal, which form the critical path of the algorithm. To extract diagonal block $(I,I)$, we use simple \spark{filter} transformation over the keys assigned to each block. We follow with \spark{flatMap} that executes Floyd-Warshall over sub-matrix $G^{(I,I)}$. Upon completion, the transformation yields multiple instances of the updated block with keys $(I, J)$ and $(\hat{I}, I)$, where $0 \leq \hat{I}, J < q$. The keys refer to the blocks in the same row and column where the updated diagonal block is needed for the next phase of computation. Here, similar to $k$NN search, we replicate the data to expose parallelism inherent to~Phase~2. To begin Phase~2, we again \spark{filter} $G$, this time to obtain sub-blocks with keys $(I, J)$ and $(\hat{I}, I)$. These blocks store values not yet updated for iteration $I$. Thus, we perform \spark{union} transformation to bring together these blocks and the diagonal blocks processed in the earlier Phase. When applying \spark{union} we take special care to ensure that the number of partitions in the resulting RDD is non-increasing. This could negatively impact the subsequent reduction operations, since the exchange of blocks requires shuffle between partitions. Therefore, we use \spark{partitionBy} to ensure all RDDs involved in \spark{union} have same partitioning as $G$. Next, we execute \spark{combineByKey} in order to pair each block from row (column) $I$ with the diagonal block $(I,I)$. To conclude Phase~2, we run \spark{flatMap} that performs min-plus matrix multiplication and in parallel updates the current blocks. The transformation yields additional instances of the updated blocks such that they can be passed to Phase~3. To conclude single iteration, we update Phase~3 blocks $G^{(\hat{I}, J)}$, and this involves computing the min-plus product $C = G^{(\hat{I},I)}\cdot G^{(I, J)}$. Hence, we use yet another \spark{filter} on $G$ to obtain remaining blocks $G^{(\hat{I}, J)}$, which are in neither row $I$ nor column $I$. These blocks, along with blocks we yield at the end of Phase~2, are brought to a single RDD via \spark{union}, again ensuring appropriate partitioning with \spark{partitionBy}. Next, we use \spark{combineByKey} transformation to bring together three matrices needed to update blocks $(\hat{I}, J)$. This includes the current value of $G^{(\hat{I}, J)}$ and Phase~2 blocks specified above, necessary to compute $C$. Once $C$ is ready, $G^{(\hat{I}, J)}$ is updated by computing element-wise minimum of itself with $C$. The three phases are repeated for the next diagonal block. At the conclusion of iteration $I = q - 1$, all pairwise distances represent the approximate manifold distances. To prepare the matrix for subsequent normalization, we square each element of the adjacency matrix to obtain the actual feature matrix $A=G^{\circ 2}$. In our implementation, the sequential APSP component uses the optimized and efficient SciPy implementation of Floyd-Warshall algorithm. It operates in-place on already allocated memory referenced by NumPy arrays. For min-plus matrix multiplication, we use our own Python implementation. However, our Python code is compiled and optimized to the machine code using the Numba just-in-time compiler, providing excellent performance. Finally, to further improve performance of our min-plus code, we enforce C or Fortran memory layout of matrices as appropriate to maximize cache~usage. The overall performance of our APSP hinges on the efficient use of \spark{combineByKey} transformation. While the transformation involves expensive data shuffling, we found that in practice it is more efficient than the available alternatives, like exchanging blocks via \spark{collect/broadcast}~\cite{Vacek2015}, or provisioning in shared secondary storage, e.g., write to HDFS or \spark{SparkFiles.addFile}, and \spark{SparkFiles.get}. This is due to the inefficiency of \spark{collect} or file I/O required for alternative approaches. As the problem size $n$ and block size $b$ increase, these operations become a bottleneck. Spark \spark{collect} requires that the diagonal block and an entire row of blocks be brought to the driver in Phases~1~and~2, respectively. Similarly, the use of secondary storage requires a sequence of file write and read operations to make blocks accessible by appropriate tasks. In our experiments, we found the cost of using heap memory combined with \spark{reduceByKey} for duplication of blocks to be superior to collect to driver or use of a secondary storage. The final remark is with respect to RDD lineages (i.e., RDD provenance and execution records). Observe that at each iteration over the diagonal, new RDD describing the entire distance matrix is created. The ancestors of this RDD are all RDDs prescribed by earlier transformations. Consequently, the resulting RDD lineage grows from iteration to iteration, potentially overwhelming the Spark driver. Since the driver is responsible also for scheduling, this hinders performance of the entire algorithm. To address this issue, we \spark{checkpoint} and \spark{persist} $A$ to prune the lineage of RDDs which describe its blocks. Frequency of checkpointing depends on the size of the input data and block size $b$, but in all test cases we found that checkpointing every 10 iterations performs best. \subsection{Matrix Normalization}\label{ssec:matnorm} The goal of matrix normalization is to transform $A$ so that it is both row and column centered. In other words, the mean of each row and each column is zero. Centering can be expressed as a linear transformation of the form $A = -\frac{1}{2}H^{T}AH$, where $H = \mathbb{I} - \frac{1}{n}1_{n\times n}$ is centering matrix, and $\mathbb{I}$ is identity matrix. Thus, the update of $A$ requires two matrix-matrix multiplications. As previously discussed, matrix-matrix multiplication is inefficient in Spark. For this reason, in our implementation we double center $A$ by the direct approach, exploiting the fact that $A$ is symmetric. Specifically, we compute the mean of each column of $A$, and we store all means in the row vector $\mu$, where $\mu_i$ is mean of column~$i$. As means for rows of $A$ are equivalent to $\mu^{T}$, we do not compute them explicitly, and to center $A$ we subtract $\mu$ from each row, and~$\mu^{T}$ from each column of $A$. To finalize the process, we add $\hat{\mu}$ to each entry of $A$, where $\hat{\mu}$ is the global mean computed over all elements of $A$. To express the above algorithm in Spark, we first transform RDD storing $A$ by \spark{flatMap} that for each block $A^{(I,J)}$ in parallel computes sums of its columns. The transformation yields tuple $(J , \mu_{J})$, and if $I \neq J$ additional tuple $(I, \mu_{I})$ that accounts for processing blocks under the diagonal (recall that $A$ is upper-triangular). Here, $\mu_{J}$ represents vector of $b$ means for the block, and is stored as 1D NumPy array. Next we aggregate the final column sums via \spark{reduceByKey} transformation that applies addition operator over vectors $\mu_{J}$ with shared key~$J$. The vector summation is efficiently implemented in NumPy. At this point, the resulting RDD contains complete information to compute the actual column means as well as the global mean $\hat{\mu}$. Hence, we first sum all elements of the sum vectors into a scalar using single \spark{map} transformation, and then use \spark{reduce} action to obtain the global sum at Spark driver. Additionally, we bring to the driver all column sums by executing \spark{collectAsMap} action. After dividing all the sums by $n$ to obtain the desired means, we \spark{broadcast} them back to Spark executors. Here we note that both \spark{reduce}/\spark{collectAsMap} and \spark{broadcast} actions involve relatively small messages (even for large $n$), and hence this communication pattern is the most direct and efficient to way to exchange computed means between executors. Finally, we conclude the normalization step by transforming RDD that stores $A$ via \spark{map} that in parallel applies previously broadcast means to the local blocks $A^{(I,J)}$. The resulting matrix $A$ is ready for spectral decomposition. \subsection{Spectral Decomposition}\label{ssec:eigen} Computing eigenvectors and eigenvalues of feature matrix $A$ is the final step common to all spectral dimensionality reduction methods, as eigenvectors represent the desired low-dimensional representation of $X$. However, larg-scale eigendecomposition is computationally challenging, and the existing parallel eigensolvers are primarily designed for shared memory and multi-/many-core architectures~\cite{Choi1996,Balay2017}. Because to the best of our knowledge currently there are no eigensolvers available for Apache Spark, we develop a new approach derived from the \emph{Power Iteration} method~\cite{Golub2012}. By using simultaneous power iteration over $A$ we are able efficiently extract only the top $d$ eigenpairs at the same time. This is computationally advantageous considering that other approaches require iteratively extracting each eigenpair, and in practical dimensionality reduction applications $d$ is relatively small, e.g.,~$d=3$ when data visualization is the~goal. \begin{Algorithm}[0.45\textwidth] \caption{\textsc{Simultaneous Power Iteration}} \begin{algorithmic}[1] \REQUIRE $A$, $d$, $l$, $t$ \ENSURE $(Q_d, \Delta_d)$ \STATE $V^{1} = \mathbb{I}_{n\times d}$ \STATE $(Q^{1},R)$ = \textsc{QRdecompose}($V^{1}$) \FOR{$i = 2,\ldots, l$} \STATE $V^{i} = A \times Q^{i-1}$ \STATE $(Q^{i},R)$ = \textsc{QRdecompose}($V^{i}$) \IF {$\lVert Q^i - Q^{i-1} \rVert_{2} < t$} \STATE \textbf{break}; \ENDIF \ENDFOR \STATE $Q_d = Q^{i}$ \STATE $\Delta_d = \textrm{diag}(R^{\circ\frac{1}{2}})$ \RETURN{$(Q_d, \Delta_d)$} \end{algorithmic} \label{alg:simulpowiter} \end{Algorithm} The standard power method (see Alg.~\ref{alg:simulpowiter}) begins with a set of $d$ linearly independent vectors, e.g., the first $d$ standard bases ${\bf e_1}, {\bf e_2},\ldots, {\bf e_d}$. It then considers all vectors simultaneously, and iteratively applies QR decomposition until the process converges to some acceptable level $t$, or the predefined number of iterations $l$. In practice, $l$ and $t$ are selected to achieve accuracy required by given target~application. To achieve efficient Spark realization of power method we exploit two facts. First, for large $n$ and reasonable values of~$d$, matrices $V^i$ and $Q^i$ have small memory footprint, and hence incur small sequential processing and communication overheads. Second, QR decomposition has extremely efficient BLAS realizations, available in NumPy. Therefore, it makes sense to assign managing and decomposition of matrix $V^{i}$ to the Spark driver (line 5), while offloading computationally expensive matrix product (line~4) for parallel processing by Spark executors. We note that while MLlib~\cite{Meng2016} provides Spark-based QR decomposition (using tall skinny QR algorithm~\cite{Constantine2011}), it is limited only to MLlib \spark{RowMatrix} RDD that would be inefficient during matrix product stage required by the power method. Consequently, in our implementation, the driver is responsible for keeping track of matrices $Q,R$ and $V$, and checking convergence criteria (line 6). After QR decomposition, the driver broadcasts the entire matrix $Q^i$ to all executors. In this way, we can directly multiply each $b\times b$ block of $A$ with the appropriate block of $Q^{i}$. With this approach we avoid costly replication and shuffle for pairing blocks from each matrix for multiplication. We use \spark{flatMap} to compute block products instead. The transformation yields tuples $((I, 0),C = A^{(I, J)}\cdot Q^{(J, 0)})$ for each block $A^{(I, J)}$ of $A$. For non-diagonal blocks we also yield $((J, 0),C = (A^{(I, J)})^{T}\cdot Q^{(I, 0)})$, to account for upper-triangular storage. Here $C$ is a NumPy 2D array representing one of the block products required for the product $V^{i}$. To obtain the final form of $V^{i}$ we use \spark{reduceByKey} transformation, where key $(I,0)$ is used, with element-wise addition of NumPy 2D arrays. In the final step, we bring $V^{i}$ back to the driver via \spark{collectAsMap}. To complete a single iteration, we perform QR factorization of $V^{i}$ on the driver, and test the Frobenius norm of the difference between successive $Q^{i}$ for convergence. At the completion of $l$ iterations or upon convergence, we return the current instance of $Q^{i}$ and $R$, finalizing the spectral decomposition stage, and thus the entire dimensionality reduction process. \section{Experimental Results}\label{sec:results} To understand performance characteristics of our approach, we performed a set of experiments on a standalone Apache Spark cluster with 25 nodes and GbE interconnect. Each node in the cluster is equipped with 20-core dualsocket Intel Xeon E5v3 2.3 GHz processor, 64 GB of RAM and a standard SATA hard drive. In all tests, Spark driver was run with 56GB of memory, to account for length of the lineage of RDDs in the APSP loop. For the same reason, we run the driver on a dedicated node separately from Spark executors. We allocated one executor per node using the default configuration for the number of cores, i.e., each executor was using all available cores in a node. All executors were configured to use 56GB out of the available 64GB, with the remaining memory available to the operating system and Python interpreter. We note that we tested different configurations of executor-to-core ratios, across different datasets, without noticeable difference in~performance. Our entire software is implemented in Apache Spark 2.2 and Python 2.7. Compute intensive linear algebra operations are offloaded via NumPy and SciPy to BLAS library, specifically Intel MKL~2017. Finally, we use Numba~0.35 for optimal min-plus matrix multiplication with just-in-time~compilation. In all experiments, in the $k$NN stage we used $k=10$ for the neighborhood size. For our test data (see below), such $k$ is large enough to deliver single connected component in the neighborhood graph, and small enough to avoid unnecessary {\em shortcut} edges. In the eigendecomposition stage, we used $t=10^{-9}$ and we allowed a maximum of $l=100$ iterations to achieve convergence. We note that in all experiments, many fewer iterations were required to see convergence (usually around 20-50 iterations). \subsection{Test Data and Method Correctness} The Swiss Roll benchmark is a classic test for evaluating manifold learning algorithms. Swiss Roll data is generated from some input 2D data, which is embedded into 3D using a non-linear function. In our tests, we used the \emph{Euler Isometric Swiss Roll}~\cite{Schoeneman2017}. To evaluate the correctness and demonstrate the scalability of our implementation, we created three test datasets. These are samples from the Swiss Roll of size $n=50000$, $n=75000$, and $n=100000$, which we refer to as Swiss50, Swiss75, and Swiss100. Figure \ref{IsoSpark_swiss50_correct} shows the initial data, high-dimensional embedded data, and the resulting dimensionality reduction delivered by our method for the Swiss50 dataset. A quick visual inspection reveals that Fig.~\ref{fig:swiss50_iso} appears to be a faithful representation of the original data in Fig.~\ref{fig:swiss50_gt}. To actually quantify how well our method reconstructs the original data, we use \emph{Procrustes error}, which captures the similarity of two datasets $X$ and $Y$ by determining the optimal affine transformation of $X$ that best conforms it with~$Y$~\cite{Dryden1998}. In our case, Procrustes error of our result compared to the original 2D coordinates is $0.000026741$, confirming high accuracy of the reconstruction. To test our platform on the actual high-dimensional data, we used benchmarks derived from the EMNIST~\cite{Cohen2017}, which is frequently used in machine learning research. This dataset provides $28\times 28$ images of over 200,000 handwritten digits, and hence each data point (image of a digit) is a 784-dimensional vector. For testing purposes, we randomly sampled two sets from EMNIST. They contain $n=50000$ and $n=125000$ points and we refer to them as EMNIST50 and EMNIST125, respectively. Figure \ref{emnist50k2dimg} shows 2D mapping of EMNIST50 obtained using our Isomap method. From the figure we can see that clusters of digits that look similar appear close together, e.g., `5'~and~`6'. At the same time, clusters of distinct digits that blend together also have these similarities. In Fig.~\ref{fig:emn50_2} sample images of digits are included to accentuate features captured by axes D1 and D2. The axis D2 describes the angle of slant for the handwritten digit. We observe the change in angle from top to bottom of the cluster. The primary axis, D1, accounts for curved or straight segments in the digit. For example, on the left we see `4's, which are made up entirely of straight line segments. In contrast, zeros on the right contain no straight segments. To the best of our knowledge, this is the first time such result is reported, and it confirms practical value of large-scale Isomap in processing noise image data. \begin{figure*}[htbp!] \subfigure[2D data prior to embedding in 3D.]{% \includegraphics[width=.325\linewidth,trim={0cm 0cm 0cm 0cm},clip]{ground_swiss50.png} \label{fig:swiss50_gt}\hfill } \subfigure[Data embedded in 3D.]{% \includegraphics[width=.325\linewidth,trim={0.35cm 0.35cm 0.35cm 0.35cm},clip]{highdim_swiss50.png} \label{fig:swiss50_3d}\hfill } \subfigure[2D mapping learned by our method, $k=10$.]{% \includegraphics[width=.325\linewidth,trim={0cm 0cm 0cm 0cm},clip]{pysomap_swiss50.png} \label{fig:swiss50_iso}\hfill } \caption{To demonstrate the correctness of our Spark Isomap method we sample 50,000 points from the Euler Isometric Swiss Roll, and then perform dimensionality reduction. (Please view in color). } \label{IsoSpark_swiss50_correct} \end{figure*} \begin{figure}[t] \centering \subfigure[Points cluster by digit which they represent.]{% \includegraphics[width=0.75\linewidth]{D2} \label{fig:emn50_1}\hfill } \subfigure[Sample of original images shown to highlight features captured by reduced dimensions D1 and D2.]{% \includegraphics[width=0.75\linewidth]{D2_moreimg} \label{fig:emn50_2}\hfill } \caption{To demonstrate our method on high-dimensional data we sample 50,000 points from the EMNIST dataset $(D=784)$, and then perform dimensionality reduction $(d=2, k=10)$. Original image shown for selected points. (Please view in color).} \label{emnist50k2dimg} \end{figure} \subsection{Scalability Tests} To analyze how our implementation scales with the problem size, expressed by $n$, and the compute resources used, we processed all datasets on a varying number of nodes, recording the wall time. The results of this experiment are summarized in Tables~\ref{exectimetable}-\ref{efftable}. Here we report relative speedup, computed as a fraction $S_p = \frac{T_{min}}{T_p}$, where $T_p$ is time taken to process data instance on $p$ nodes, and $T_{min}$ is the time taken by the same instance to process on the smallest feasible number of nodes. We note that even the smallest datasets we consider in our tests are impossible to process using single node, and hence $T_{min}$ is not $T_{1}$. Similarly, we compute relative efficiency as $E_p = \frac{S_p}{p} \cdot \arg{T_{min}}$. The experimental results show that our approach exhibits strong scaling within the entire range of data and cluster configuration. For smaller datasets ($n=50000$), the method scales linearly up to 12 nodes, and maintains very good efficiency up to 24 nodes. The scaling is very similar for both Swiss50 and EMNIST50, which is expected taking into account that only $k$NN stage depends (linearly) on $D$, and it constitutes only a small fraction of the entire runtime. At this point we should note that because we express all Isomap stages as linear equations or matrix multiplications, the performance of our method is not at all impacted by data distribution or density (e.g., connectivity of graph $G$). When the size of the input data increases, the method seems to exhibit super-linear performance, however, this result should be taken with care, considering that we compute relative and not actual speedup. The method maintains also weak scalability. Specifically, for the fixed ratio $\frac{n}{p}$, the execution time scales roughly as $\left( \frac{n}{p} \right)^3$, which reflects the dominating cost $\mathcal{O}(n^{3})$ of the APSP stage. \begin{table}[H] \caption{Execution time in minutes} \label{exectimetable} \centering {\footnotesize \begin{tabularx}{\columnwidth}{lXXXXXXX} \toprule & \multicolumn{7}{c}{Compute Nodes}\\ Name & 2 & 4 & 8 & 12 & 16 & 20 & 24\\ \midrule EMNIST50 & 294.92 & 117.90 & 62.41 & 48.47 & 41.44 & 35.82 & 32.92\\ Swiss50 & 261.43 & 98.88 & 53.58 & 39.41 & 33.26 & 29.47 & 26.49\\ Swiss75 & -- & 958.85 & 345.47 & 105.28 & 84.05 & 76.66 & 63.25\\ Swiss100 & -- & -- & 1122.89 & 465.30 & 275.22 & 225.89 & 157.97\\ EMNIST125 & -- & -- & -- & 985.94 & 662.92 & 599.28 & 448.42\\ \bottomrule \end{tabularx} {\footnotesize -- means that dataset was impossible to process on given resources.} } \end{table}% \begin{table}[H] \caption{Relative speedup} \label{spduptable} \centering {\footnotesize \begin{tabularx}{\columnwidth}{lXXXXXXX} \toprule & \multicolumn{7}{c}{Compute Nodes}\\ Name & 2 & 4 & 8 & 12 & 16 & 20 & 24\\ \midrule EMNIST50 & 1 & 2.50 & 4.73 & 6.09 & 7.11 & 8.23 & 8.96\\ Swiss50 & 1 & 2.64 & 4.88 & 6.63 & 7.86 & 8.87 & 9.87\\ Swiss75 & -- & 1 & 2.78 & 9.11 & 11.41 & 12.51 & 15.16\\ Swiss100 & -- & -- & 1 & 2.41 & 4.08 & 4.97 & 7.11\\ EMNIST125 & -- & -- & -- & 1 & 1.49 & 1.65 & 2.20\\ \bottomrule \end{tabularx} } \end{table}% \begin{table}[H] \caption{Relative efficiency} \label{efftable} \centering {\footnotesize \begin{tabularx}{\columnwidth}{lXXXXXXX} \toprule & \multicolumn{7}{c}{Compute Nodes}\\ Name & 2 & 4 & 8 & 12 & 16 & 20 & 24\\ \midrule EMNIST50 & 1 & 1.25 & 1.18 & 1.02 & 0.89 & 0.82 & 0.75\\ Swiss50 & 1 & 1.32 & 1.22 & 1.11 & 0.98 & 0.89 & 0.82\\ Swiss75 & -- & 1 & 1.39 & 3.04 & 2.85 & 2.50 & 2.53\\ Swiss100 & -- & -- & 1 & 1.61 & 2.04 & 1.99 & 2.37\\ EMNIST125 & -- & -- & -- & 1 & 1.12 & 0.99 & 1.10\\ \bottomrule \end{tabularx} } \end{table} The performance of our method directly depends on the logical block size $b$ (see Sec.~\ref{ssec:knn}). Recall that in $k$NN search, blocks of $b$ points are paired to compute one block of the pairwise distance matrix. The execution time of computing a single block scales as $\Theta$($b^{2}$). When computing APSP, we require sequential Floyd-Warshall for each block along the diagonal, and matrix-matrix min-plus multiplication for others. Both cases have complexity $\Theta(b^{3})$. Moreover, the APSP solver proceeds iteratively over the diagonal~of~$A$. Since each block on the diagonal must be solved in sequence, the critical path has length $q$. All these factors must be taken into consideration when selecting $b$. In our experiments, we found that $b$ in the range $1000\leq b \leq 2500$ gives ideal performance when $n \leq 100,000$. This is because the length of the critical path is not overwhelming for the Spark driver, and at the same time, the block size is small enough to leverage cache memory when executing BLAS routines for matrix products. As the problem size grows, it is advantageous to increase block size to keep control of the critical path. This however may increase the time taken to process individual block, and may lead to resource underutilization as there are fewer blocks to distribute for processing between executors. Figure~\ref{bvstime} shows impact of block size $b$ when processing Swiss75 on 24 nodes (we observe similar pattern for other datasets). The sweet spot is for $b=1500$ and both undersizing and oversizing $b$ degrades performance. Currently, we do not have model that would let us select $b$ automatically, however, the intuition we provide above is sufficient for the majority of practical applications. \begin{figure}[t] \centering \includegraphics[width=0.75\linewidth]{blockb} \caption{To identify the effect of block size on overall execution time, we run our method on Swiss75 using 24 compute nodes with varying $b$.} \label{bvstime} \end{figure} \section{Related Work}\label{sec:relwork} As previously mentioned, existing implementations of Isomap and its variants do not scale to data as large as presented here. Talkwalkar et al. successfully learned manifold for 18 million points. However, their analysis includes approximation method for APSP, and Nystrom method for approximate spectral decomposition. To date, the largest study for exact solutions for Isomap includes $n=32768$ points, and has been reported in~\cite{Samudrala2015}. The method is tailored for HPC clusters with MPI, and hence its applicability is somewhat constrained. To partially mitigate the complexity of APSP, the authors of Isomap have proposed Landmark-Isomap (L-Isomap)~\cite{deSilva2003}. The idea behind L-Isomap is that $m$ randomly selected {\em landmark points} may be selected to learn an underlying manifold. Remaining points are placed on the manifold via triangulation using their distance to landmarks. This approach greatly reduces complexity by targeting APSP, but introduces new sources of error in i) landmark selection method, ii) selecting the number of landmarks, and iii) adding the complete dataset by triangulation. We previously extended the works of de Silva and Tenenbaum~\cite{deSilva2003,Tenenbaum2000} and proposed Streaming-Isomap~\cite{Schoeneman2017}. The streaming approach requires learning a faithful representation of the underlying manifold for some initial batch of points, and then quickly maps new points arriving on a high-volume, high-throughput stream. This approach is orthogonal to the one we present here, and in fact both methods could be combined in case when the initial batch is large. \section{Conclusion}\label{sec:end} High-dimensional big data, arising in many practical applications, presents a challenge for non-linear spectral dimensionality reduction methods. This is due to the computationally intensive construction of the feature matrix and it's spectral decomposition. In this paper, we proposed a scalable distributed memory approach for manifold learning using Isomap, addressing key computational bottlenecks of the method. Through experiments we demonstrated that our resulting Apache Spark-based implementation is scalable and efficient. The method can solve exact Isomap on high-dimensional datasets, which are an order of magnitude larger than what can be processed with the existing methods. We note that individual components, like $k$NN, APSP and eigendecomposition solvers, can be used as a standalone routines. Finally, since other non-linear spectral decomposition methods, like e.g., LLE~\cite{Roweis2000}, share the same computational backbone, with a minimal effort our software could be extended to cover these methods as well. The source code of our platform is open and available from: \url{https://gitlab.com/SCoRe-Group/IsomapSpark}. \section*{Acknowledgment} The authors would like to acknowledge support provided by the Center for Computational Research at the University at Buffalo. This work has been supported in part by the Department of Veterans Affairs under grant 7D0084. \bibliographystyle{IEEEtran}
\section*{Bibliography}
\section{Introduction}\label{sec:introduction}} \IEEEPARstart{R}{equirements} error is one of the causes leading failings in software projects \cite{DBLP:journals/re/SutcliffeEM99}. Careful requirements modeling along with systematic validation helps to reduce the uncertainty about target systems \cite{Hofmann2001}\cite{sommerville2015software}. The goal of requirements validation and evolution is to construct the consistent requirements for the needs of target users \cite{Atladottir2012}. However, this process is complicated, and it can be hard to produce a correct and complete requirements specification. The complexity is due to the following interrelated attributes: 1) the complexity of application domains and business processes; 2) the uncertainty of clients and domain experts about their needs; 3) the lack of the understanding of system developers about application domains; 4) the difficulties of the understanding between system developers and clients \cite{Lichter1994}. Rapid prototyping is an effective approach to requirements validation and evolution via an executable model of a software system to demonstrate concepts, discover requirements errors and find possible fixing solutions, and discover missing requirements \cite{Kordon2002}. Besides the implementation of main system functionalities, a prototype has a User Interface (UI) \cite{userinterface} that allows the client to validate their requirements visually, make it easy to find out faults in the requirements, and then fix them \cite{Kamalrudin2011}. In practice, it is very desirable to have a tool that generates prototypes directly from requirements automatically. However, state-of-the-art research and Computer-Aided Software Engineering (CASE) tools still have long distances to reach the goal \cite{Ciccozzi2018}. Unified Modeling Language (UML) is the de facto standard for requirement modeling and system design. Current UML modeling tools, such as Rational Rose, SmartDraw, MagicDraw, Papyrus UML, can only generate skeleton code, where classes only contain attributes and signatures of operations, not their implementations \cite{Regep2000}. Even when design models (e.g., sequence diagrams) are provided, only less than 48\% correct source code can be generated \cite{Kundu2013} by AndroMDA\footnote{\url{http://andromda.sourceforge.net}} and MasterCraft \cite{kulkarni2002generating} from design models. \begin{figure*}[!htb] \centering \includegraphics[width=1\textwidth]{requirementsmodel.pdf} \caption{Requirements Model}\label{rm} \end{figure*} In this paper, we present an approach to automatically prototype generation from a requirements model in UML diagrams complemented by formal contracts of system operations. Compared with other related work, our approach does not require design models but rely on a requirements model \cite{DBLP:conf/compsac/LiLH01}\cite{zhiming2003}\cite{DBLP:journals/scp/ChenLRSZ09} in Figure \ref{rm}, which contains: \noindent\textit{$\bullet$ A use case diagram:} A use case diagram captures domain processes as use cases in terms of interactions between the system and its users. It contains a set of use cases for a system, the actors represented a type of users of the system or external systems that the system interacts with, the relations between the actors and these use cases, and the relations among the use cases. It helps customers and domain experts specify functional requirements of the target system, and it assists in generating the operation list to hold system operation in prototypes, which is shown in Figure \ref{prototypesf}. \vspace{.1cm} \noindent\textit{$\bullet$ System sequence diagrams.} A system sequence diagram describes a particular domain process of a use case. It contains the actors that interact with the system, the system and the system events that the actors generate, their order, and inter-system events. Compared with the sequence diagram, a system sequence diagram treats all systems as a black box and contains system events across the system boundary between actors and systems without object lifelines and internal interactions between objects. It helps customers to find system operations and provides the sequences to interact with the prototype for requirements validation. \noindent\textit{$\bullet$ Contracts of system operations:} The contract of a system operation \cite{liu2002object}\cite{meyer2002design} specifies the conditions that the state of the system is assumed to satisfy before the execution of the system operation, called the {\em pre-condition} and the conditions that the system state is required to satisfy after the execution (if it terminated), called the {\em post-condition} of the system operation. Typically, the pre-condition specifies the properties of the system state that need to be checked when system operation is to be executed, and the post-condition defines the possible changes that the execution of the system operation is to realize. A state of an object-oriented system is about the existing objects together with their properties/states and relations/links. The state is an object diagram defined by a conceptual class diagram plus the input and returns parameters of the operations. The changes of system states are classified into i) new objects created (together with initial values of attributes and links of associations), ii) attributes of existing objects (in the current state) modified, iii) new links among existing objects formed, and iv) existing objects and/or links are removed. The basic operations of changing the state are defined as the \textit{primitive operations} in our approach. We will see, the decomposition from system operation into primitive operations is the theoretical foundation of our approach to automatic generation of an abstract and yet executable model from a requirements model. \noindent\textit{$\bullet$ A conceptual class diagram.} A conceptual class diagram illustrates abstract and meaningful concepts and their relations in the problem domain, in which the concepts are specified as classes, the relations of the concepts are specified as the associations between the classes, and the properties of the concepts are specified as the attributes of the classes. The proposed approach can directly generate to Java classes that represent domain concepts and encapsulates the primitive operations such as getting and setting the values of attributes, adding and remove links, and finding an object through links in the prototypes. The idea of automated prototype generation from a requirements model is presented in our earlier work \cite{Li2008}\cite{Li2010}. There, the feasibility is demonstrated with a small example. In this paper, we extend original methods and propose new algorithms to 1) automated decomposition of the system operations into primitive operations, and encapsulation them into the classes based on object-oriented design patterns \cite{alexander1977pattern}\cite{vlissides1995design}\cite{richards2015software}\cite{Fowler2002}, 2) non-executable analysis of system operation contract, and wrap the non-executable parts of contract into a interface, it further can be implemented by developers and third-party APIs, 3) requirements validation and revolution based on the prototype mechanisms of object state observation and pre-condition and invariant checking. The evaluation result from four case studies shows that our approach can correctly generate 93.65\% code from requirements models, the remaining non-executable 6.35\% requirements can be recognized and wrapped as an interface, which can be manually implemented or matched with third-party APIs libraries. The remainder of this paper is organized as follows: Section 2 presents the preliminary of our approach. Section 3 introduces how to decompose a system operation into primitive operations. Section 4 presents how to generate the prototype. Section 5 provides how to use the generated prototype for requirement validation and refinement. Section 6 presents the experiments result of our approach on the four case studies of a Library Management System, CoCoME, ATM and a Loan Processing System. Section 7 and 8 discuss the related work, conclude this paper, and outline the future work. \section{Preliminary} In this section, we introduce the terminology used in the requirements model and prototypes. \subsection{Terminology} The terminology related to the proposed approach except the terminology introduced in the previous section are listed as follows: \vspace{.1cm} \noindent\textit{$\bullet$ Association and link.} An association is a relationship between two classes in a conceptual class diagram that specifies how instances of the classes can be linked to work together. A link is an instance of an association, which is a relationship between two objects in an object diagram. \vspace{.1cm} \noindent\textit{$\bullet$ Entity class and fabricated class.} To indicate the classes are from domain concepts or fabrications in the prototype, we divide classes into two type: entity classes are Java classes generated in prototypes from conceptual class diagrams, the others are fabricated classes. For example, Java class \textit{Item} is entity class generated from the conceptual class diagram in CoCoME, and Java class \textit{EntityManager} is a fabricated class that helps to find, create, and release the objects in the system. \vspace{.1cm} \noindent\textit{$\bullet$ Object reference and reference list.} In object-oriented programming such as Java, the value of a variable which has a type of a class is an object reference, which provides a way to access an object in the heap of a system. A reference list is a list of object references to access objects with the same type of a class. We will see, reference lists are used to record and access the objects of the prototype. \vspace{.1cm} \noindent\textit{$\bullet$ System operation.} System operation is an operation that the system executes in response to a system input event in system sequence diagrams. \vspace{.1cm} \noindent\textit{$\bullet$ Primitive operation.} Primitive operations are the operations introduced in our approach to covers all actions to manipulate objects, the attributes of objects, and the links of objects in Table 1. The details are shown in Section 3.1. \subsection{Object Constraint Language} Object Constraint Language\footnote{\url{http://www.omg.org/spec/OCL/}} (OCL) is a part of UML. It is used mainly for specifying constraints of UML diagrams, such as pre and post conditions of operations and invariants. In this paper, we adopt OCL in the latest version \textit{v2.4} to specify the contracts of system operations. It not only can specify the pre-condition and post-condition of system operation but also allows to specify shared specifications from pre-condition and post-condition in the \textit{definition} section. The following example shows how OCL specify the contract of the system operation \textit{enterItem} (a cashier scans products in a sale process of a supermarket) of the use case \textit{processSale}. \begin{lstlisting}[language=contract] //Signature Contract CoCoMEProcessSale::enterItem (barcode : String, quantity : Real) : Boolean { //Definition Section definition: //Find Object item:Item = Item.allInstance()->any(i:Item | i.Barcode = barcode) //Pre-condition Section precondition: currentSale.oclIsUndefined() = false and currentSale.IsComplete = false and item.oclIsUndefined() = false and item.StockNumber > 0 //Post-condition Section postcondition: //Create an Object let sli:SalesLineItem in sli.oclIsNew() and //Add Links self.currentSaleLine = sli and sli.BelongedSale = currentSale and currentSale.ContainedSalesLine->includes(sli) and sli.BelongedItem = item and //Modify Attributes sli.Quantity = quantity and sli.Subamount = item.Price * quantity and item.StockNumber = item.StockNumber@pre - quantity and //Add an Object SalesLineItem.allInstance()->includes(sli) and result = true } \end{lstlisting} \noindent\textbf{Signature:} The contract first specifies the signature of system operation \textit{enterItem()} of use case \textit{processSale}. The signature declares a \textit{String} variable \textit{barcode} and a \textit{Real} variable \textit{quantity} as input, and output variable typed \textit{Boolean}. \vspace{.2cm} \noindent\textbf{Definition Section:} In the \textit{definition} section, we find the object \textit{item} of the class \textit{Item} with the attribute \textit{Barcode} equal to the input variable \textit{barcode}. We will see that the object \textit{item} is used in both the pre- and post-conditions. \vspace{.2cm} \noindent\textbf{Pre-condition Section:} The pre-condition of \textit{enterItem} specifies that the current sale object \textit{currentSale} is \textit{existed}, and the value of attribute \textit{IsComplete} of \textit{currentSale} is equal to \textit{false}, the object \textit{item} with the scanned \textit{barcode} is \textit{existed} in the system, and the stock number is greater than zero. \vspace{.2cm} \noindent\textbf{Post-condition Section:} The post-condition of \textit{enterItem} specifies that 1) a new object \textit{sli} of class \textit{SalesLineItem} was created, 2) the \textit{currentSaleLine} was linked to the new created object \textit{sli}, 3) the links among \textit{currentSale}, \textit{sli} and \textit{item} were formed, 4) the attributes \textit{Quantity} and \textit{Subamount} of \textit{sli} were set to the value of input variable \textit{quantity} and \textit{item.Price*quantity}, 5) the attribute \textit{StockNumber} of \textit{item} was reduced by the number of \textit{quantity}, 6) the new created object \textit{sli} was added in the object list \textit{SaleLineItem}, 7) the output of system operation \textit{enterItem()} was \textit{true}. Note that system operations may manipulate the same objects in a system sequence diagram of a use case. OCL allows to access the new created object in the same use case. For example, the object \textit{currentSale} of the class \textit{Sale} is created by system operation \textit{makeNewSale()} of the use case \textit{processSale}. It can be reused in the contract of the system operation \textit{enterItem()}. \section{System Operation Decomposition} In this section, we first present a collection of primitive object-oriented operations and then introduce transformation rules and algorithms that automatically decompose a system operation to primitive operations. Finally, we present an example to show how the transformation rules and algorithms work. \subsection{Primitive Operations} Referring to atomic actions for manipulation tables in relational databases, we introduce a collection of primitive object-oriented operations of the object-oriented system for system operation decomposition in Table \ref{atomicresponsibilitiy}, \begin{table}[!htb] \centering \ra{1.5} \caption{Primitive Operations}\label{atomicresponsibilitiy} \begin{adjustbox}{max width=0.48\textwidth} \begin{tabular}{cll @{}} \toprule & Primitive Operation & Return Type \\ \midrule \multirow{5}{*}{Object} &\emph{\textbf{findObject}(ClassName$\mathord{:}$String, condition$\mathord{:}$String)} & Object \\ &\emph{\textbf{findObjects}(ClassName$\mathord{:}$String, condition$\mathord{:}$String)} & Set(Object) \\ &\emph{\textbf{createObject}(ClassName$\mathord{:}$String)} & Object \\ &\emph{\textbf{addObject}(ClassName$\mathord{:}$String, ob$\mathord{:}$Class)} & Boolean \\ &\emph{\textbf{releaseObject}(ClassName$\mathord{:}$String, ob$\mathord{:}$Class)} & Boolean \\ \midrule \multirow{2}{*}{Attribute}&\emph{\textbf{getAttribute}(ob$\mathord{:}$Class, attriName$\mathord{:}$String)} & PrimeType \\ &\emph{\textbf{setAttribute}(ob$\mathord{:}$Class, attriName$\mathord{:}$String, mathExp$\mathord{:}$String)} & Boolean\\ \midrule \multirow{6}{*}{Link}&\emph{\textbf{findLinkedObject}(o$\mathord{:}$Class, assoName$\mathord{:}$String, condition$\mathord{:}$String)} & Object \\ &\emph{\textbf{findLinkedObjects}(o$\mathord{:}$Class, assoName$\mathord{:}$String, condition$\mathord{:}$String)} & Set(Object)\\ &\emph{\textbf{addLinkOnetoMany}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, addOb$\mathord{:}$Class)} & Boolean \\ &\emph{\textbf{addLinkOnetoOne}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, addOb$\mathord{:}$Class)} & Boolean \\ &\emph{\textbf{removeLinkOnetoMany}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, removeOb$\mathord{:}$Class)} & Boolean\\ &\emph{\textbf{removeLinkOnetoOne}(ob$\mathord{:}$Class, assoName$\mathord{:}$String)} & Boolean\\ \bottomrule \end{tabular} \end{adjustbox} \end{table} which covers all manipulations to a) objects, b) the attributes of objects, and c) the links of objects. \vspace{.2cm} \noindent\textbf{Objects:} The following primitive operations are used to manipulate objects. An object or objects can be retrieved through primitive operation \textit{findObject()} or \textit{findObjects()} with a class name and a query condition. An object can be created by primitive operation \textit{createObject()} with a class name, and then the created object can be added to the system through primitive operation \textit{addObject()} with providing a class name and an object reference \textit{ob}. Primitive operation \textit{releaseObject()} can be used to delete an object from the system by providing a class name and an object reference \textit{ob}. \vspace{.2cm} \noindent\textbf{Attributes of Objects:} The next two primitive operations are used for getting and setting the value of an attribute. Primitive operation \textit{getAttribute()} can retrieve the value of an attribute of an object by providing an object reference \textit{ob} and the name of attribute. The value of an attribute of an object can be changed by the primitive operation \textit{setAttribute()} with an object reference \textit{ob}, the name \textit{attriName} of an attribute, and a math expression \textit{mathExp}. \vspace{.2cm} \noindent\textbf{Links of Objects:} The links can be used to find the linked objects. Note that we use different primitive operations to manipulate links corresponding with two different types of the association of classes (one-to-one and one-to-many relation). By providing an object reference \textit{ob}, an association name \textit{assoName}, and an condition, primitive operations \textit{findLinkedObject()} and \textit{findLinkedObjects()} can retrieve the linked object or objects. An link from object \textit{ob} to object \textit{addOb} can be formed by invoking primitive operation \textit{addLinkOnetoMany()} or \textit{addLinkOnetoOne()} with the name of the association, and the object reference \textit{ob} and \textit{addOb}. Primitive operation \textit{removeLinkOnetoMany()} or \textit{removeLinkOnetoOne()} can be used to break the link by providing an object reference \textit{ob}, and the name of the association \textit{assoName}. Primitive operation \textit{removeLinkOnetoMany()} requires providing a reference to the target object \textit{removeOb}, and the reference indicates which link will be removed from the object. \subsection{Transformation Rules} We have introduced the contract of system operation and primitive operations. In this subsection, we present how to transform an OCL contract to primitive operations. Transformation rules will be presented in this form: \[ \begin{array}{l} \textit{Rule}: \frac{\textit{OCL Expression}}{\textit{Primitive Operation in Java Code}} \end{array} \] The transformation rule contains two parts: the above section is an OCL Expression, and the bottom part is a primitive operation in Java code. The transformation rules form OCL expressions and primitive operations as pairs, and those pairs are the foundation of the transformation algorithm for automatic system operation decomposition. In short, we refine the original ten transformation rules in the previous work \cite{Li2008}\cite{Li2010} to twenty-five transformation rules that cover all the primitive operations corresponding in the contract sections of definition, pre-condition, and post-condition. The difference from our previous work is discussed in the related work section. Follow the convention of OCL contract, we present those transformation rules into three parts: a) definition transformation, b) pre-condition transformation, and c) post-condition transformation. \subsubsection{Definition Section Transformation} The definition section of the contract specifies that the objects are further used in pre-condition and post-condition. In object-oriented system, objects can be reached through the links of objects, which are defined by the associations of the classes. In our approach, we build pure fabricated class \textit{EntityManager} (EM) to record all the references of objects in the system. Therefore, objects can be found through \textit{EntityManager} with a query condition, and then other related objects can be reached through the links of the founded objects. In definition section, seven transformation rules are presented, which involve the primitive operations \textit{findObject()}, \textit{findObjects()}, \textit{findAssociationObject()}, and \textit{findAssociationObjects()} of Table \ref{atomicresponsibilitiy}. \[ \begin{array}{l} \mathbf{R_1}: \frac{\textit{obs$\mathord{:}$\textbf{Set}(ClassName)=ClassName.\textbf{allInstances}()}}{\emph{List<ClassName> obs = EM.\textbf{findObjects}(ClassName$\mathord{:}$String)}} \end{array} \] The rule $R_1$ shows finding all the objects \textit{obs} of the class named \textit{ClassName} in the system. This OCL expression is mapped to the primitive operation \textit{findObjects()}, and the found objects are assigned to a list reference \textit{obs} of the class \textit{ClassName}. \[ \footnotesize \begin{array}{l} \mathbf{R_2}: \frac{\textit{obs$\mathord{:}$\textbf{Set}(ClassName)=ClassName.\textbf{allInstances}()$\rightarrow$\textbf{select}(o $|$ \textbf{conditions}(o))}}{\emph{List<ClassName> obs = EM.\textbf{findObjects}(ClassName$\mathord{:}$String, conditions(o)$\mathord{:}$String)}} \end{array} \] \[ \footnotesize \begin{array}{l} \mathbf{R_3}: \frac{\textit{ob$\mathord{:}$ClassName = ClassName.\textbf{allInstances}()$\rightarrow$\textbf{any}(o $|$ \textbf{conditions}(o))}}{\textit{ClassName ob = EM.\textbf{findObject}(ClassName$\mathord{:}$String, conditions(o)$\mathord{:}$String)}} \end{array} \] Based on rule $R_1$, the rules $R_2$ and $R_3$ are introduced to find objects \textit{obs} or an object \textit{ob} from all the instances of the class named \textit{ClassName} with the constraints \textit{condition(o)} by using \textit{select} or \textit{any} OCL keywords. \textit{condition(o)} is a logic formula about object \textit{o}, which composites atomic formulae of pre-condition with the logical operators \textit{and} and \textit{or}. The OCL expressions of $R_2$ and $R_3$ are mapped to the primitive operation \textit{findObjects()} or \textit{findObject()}, and then assign the found objects or object to a reference list \textit{obs} or a reference \textit{ob} of class \textit{ClassName}. For example, when a cashier scans the product by invoking the system operation \textit{enterItem()}, the system will find the object \textit{item} with the specific \textit{barcode}, which has the same value retrieved from the scanner. This part functional semantics are specified in the definition section of contract \textit{enterItem()}. It will map to the primitive operation \textit{findObject()} by $R_3$ as follows: \[ \begin{array}{l} \frac{\textit{item$\mathord{:}$Item = Item.\textbf{allInstances}()$\rightarrow$\textbf{any}(o $|$ i.Barcode = barcode)}}{\textit{Item ob = EM.\textbf{findObject}("Item", "i.Barcode = barcode")}} \end{array} \] Note that the condition \textit{i.Barcode = barcode} will be further mapped by $R_{12}$. Once we find the target objects, the related objects can be found through the links of the target objects. Those transformations present in the next four rules: \[ \footnotesize \begin{array}{l} \mathbf{R_4}: \frac{\textit{o$\mathord{:}$ClassName = ob.assoName}}{\emph{ClassName o = EM.\textbf{findLinkedObject}(ob$\mathord{:}$Class, assoName$\mathord{:}$String)}} \end{array} \] \[ \footnotesize \begin{array}{l} \mathbf{R_5}: \frac{\textit{obs$\mathord{:}$Set(ClassName) = ob.assoName}}{\emph{List<ClassName> obs = EM.\textbf{findLinkedObjects}(ob$\mathord{:}$Class, assoName$\mathord{:}$String)}} \end{array} \] The rules $R_4$ and $R_5$ show finding the linked object through \textit{ob.assoName}, where the association may be one-to-one or one-to-many relationship. If \textit{assoName} is one-to-one association, \textit{ob.assoName} will return a object reference \textit{o} to the object linked with object \textit{ob}; otherwise \textit{ob.assoName} returns a reference list \textit{obs}. Therefore, the OCL expressions of $R_4$ and $R_5$ are mapped to primitive operations \textit{findLinkedObject()} and \textit{findLinkedObjects()} with the input variables: an object reference \textit{ob} and an association name \textit{assoName} of object \textit{ob}, and then assign the found object or object list to the reference \textit{o} or reference list \textit{obs} correspondingly. \[ \scriptsize \begin{array}{l} \mathbf{R_6}: \frac{\textit{obs$\mathord{:}$Set(ClassName) = ob.assoName$\rightarrow$\textbf{select}(o $|$ \textbf{conditions}(o))}}{\emph{List<ClassName> obs = EM.\textbf{findLinkedObjects}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, preconditions(o)$\mathord{:}$String)}} \end{array} \] \[ \footnotesize \begin{array}{l} \mathbf{R_7}: \frac{\textit{o$\mathord{:}$ClassName = ob.assoName$\rightarrow$\textbf{any}(o $|$ \textbf{conditions}(o))}}{\emph{ClassName ob = EM.\textbf{findLinkedObject}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, conditions(o)$\mathord{:}$String)}} \end{array} \] Based on the rule $R_5$, the rules $R_6$ and $R_7$ apply OCL expression \textit{select} and \textit{any} with a query condition \textit{condition(o)} to \textit{ob.assoName} with navigation $\rightarrow$ to filter the specific objects from the associated objects. For example, we find a \textit{SaleLineItem} object under current sale \textit{s} with quantity number great than 2. The corresponding OCL contract and $R_7$ transformation are: \[ \small \begin{array}{l} \frac{\textit{sli$\mathord{:}$SaleLineItem = s.ContainedSaleLine$\rightarrow$\textbf{any}(sl $|$ sl.Quantity > 2)}}{\emph{SaleLineItem sli = EM.\textbf{findLinkedObject}(s, "ContainedSaleLine", "sl.Quantity > 2")}} \end{array} \] The same as the previous example, the condition \textit{sl.Quantity > 2} will make a further transformation by rule $R_{12}$. \subsubsection{Pre-condition Transformation} The pre-condition section of the contract specifies the status of the objects before execution of system operation. The related objects have been specified in the definition section of the contract. The pre-condition section specifies the constraints on those objects before execution of system operation. The pre-condition transformation maps those constraints to the primitive operations, which involves \textit{getAttribute()} and a set of basic checking operations under the fabricated class \textit{StandardOPs}. In short, eight transformation rules from $R_8$ to $R_{15}$ are presented in the pre-condition section. \[ \begin{array}{l} \mathbf{R_8}: \frac{\textit{ob.oclIsUndefined() = bool}}{\emph{\textbf{StandardOPs.oclIsUndefined}(ob$\mathord{:}$Class, bool$\mathord{:}$Boolean)}} \end{array} \] \[ \begin{array}{l} \mathbf{R_9}: \frac{\textit{var.oclIsTypeOf(type)}}{ \emph{\textbf{StandardOPs.oclIsTypeOf}(\flqq var\frqq, type$\mathord{:}$String)}} \end{array} \] \[ \begin{array}{l} \mathbf{R_{10}}: \frac{\textit{obs.isEmpty() = bool}}{\emph{\textbf{StandardOPs.isEmpty}(obs$\mathord{:}$Set(Class), bool$\mathord{:}$Boolean)}} \end{array} \] The rules $R_8$, $R_9$, and $R_{10}$ map the basic OCL checking expression about object and object list to the primitive operations. The contract of $R_8$ checks that the reference \textit{ob} does not refer to an object. The OCL expression of $R_9$ is used to check that the variable \textit{var} conforms the specific \textit{type}, in which the \textit{var} is a variable of primitive type, an object reference, or a reference list. The contract of $R_{10}$ is to check the object list \textit{obs} is empty. \[ \begin{array}{l} \mathbf{R_{11}}: \frac{\textit{obs.size() op\tnote{1} \textit{ }mathExp}}{ \emph{\textbf{StandardOPs.size}(obs$\mathord{:}$Set(Class)) \flqq op\frqq \textit{ }\flqq mathExp\frqq}} \end{array} \] \[ \begin{array}{l} \mathbf{R_{12}}: \frac{\textit{ob.AttriName op varPM\tnote{6}}}{\emph{\textbf{getAttribute}(ob$\mathord{:}$Class, attriName$\mathord{:}$String) \flqq op\frqq\textit{ }\flqq varPM\frqq}} \end{array} \] The rules $R_{11}$ and $R_{12}$ map the logic expression from OCL to Java. The \textit{op} is an infix comparison operator in OCL. \flqq op\frqq\textit{ }represents the corresponding Java code of \textit{op} after compilation. Most operators of OCL and Java are the same, except equal operator \textit{=} and non-equal \textit{<>} of OCL. Those operators will be compiled to Java operators \textit{==} and \textit{!=}. Furthermore, when we compare between two variables \textit{s1} and \textit{s2} of \textit{String} type, the above operators will be compiled to Java code \textit{s1.equals(s2)} and \textit{!s1.equals(s2)} respectively. The rule $R_{11}$ gets the size of list, and then checks the constraint of the list size against a math expression \textit{mathExp}. The \textit{mathExp} may contain numbers, variables, operators, functions and brackets. The rule $R_{12}$ firstly retrieves the value of the attribute \textit{attriName} of the object \textit{ob} by transforming \textit{ob.attribute} to the primitive operation \textit{getAttribute}, and checks the constraint on the value of the attribute through the expression \textit{op} \textit{varPM}. The \textit{varPM} is a variable of primitive type or a math expression. For example, the pre-condition \textit{item.StockNunmber > 0} of contract \textit{enterItem}. ">" is the \textit{op} expression. "0" is the \textit{varPM} expression. This pre-condition will be compiled to Java code \textit{item.getStockNumber() > 0} by rule $R_{12}$: \[ \begin{array}{l} \frac{\textit{sl.Quantity > 2}}{\emph{\textbf{getAttribute}(sl, "Quantity") > \textit{ }2}} \end{array} \] The rules $R_{13}$ and $R_{14}$ use the OCL expression \textit{ClassName.allInstances()} of the definition section to find all objects of class \textit{ClassName}, and to check whether the specific object \textit{ob} is included in or excluded from the object list. Therefore, \textit{ClassName.allInstances()} is mapped to \textit{EM.findObjects(ClassName)}, and then the founded object will be passed to the operations \textit{includes()} or \textit{excludes()} of the class \textit{StandardOPs}. \[ \begin{array}{l} \mathbf{R_{13}}: \frac{\textit{ClassName.\textbf{allInstances}()$\rightarrow$\textbf{includes}(ob)}}{\emph{\textbf{StandardOPs.includes}(EM.findObjects(ClassName), ob$\mathord{:}$Class)}} \end{array} \] \[ \begin{array}{l} \mathbf{R_{14}}: \frac{\textit{ClassName.\textbf{allInstances}()$\rightarrow$\textbf{excludes}(ob)}}{\emph{\textbf{StandardOPs.excludes}(EM.findObjects(ClassName), ob$\mathord{:}$Class)}} \end{array} \] \[ \begin{array}{l} \mathbf{R_{15}}: \frac{\textit{ClassName.\textbf{allInstance}()->\textbf{isUnique}(o$\mathord{:}$ClassName | o.AttriName)}}{\emph{\textbf{StandardOPs.isUnique}(ClassName$\mathord{:}$String, AttriName$\mathord{:}$String)}} \end{array} \] The last rule $R_{15}$ of precondition section maps the unique detection expression to the operation \textit{isUnique()} of class \textit{StandardOPs}. This opeartion will get all the objects of class \textit{ClassName}, and check the specific attribute \textit{AttriName} has the unique value or not. Note that 1) OCL expressions of pre-condition section can also be used to specify the invariants of the system. Therefore, the transformation rules related pre-condition can also apply to the invariants transformation. 2) The implementation of class \textit{StandardOPs} is not presented in this paper, the details can be found on the GitHub repository\footnote{\url{https://github.com/RM2PT/CaseStudies/wiki/StandardOP}}. \subsubsection{Post-condition Transformation} The post-condition section of the contract specifies the status of objects after execution of the operation. Concretely, the post-condition specifies that the object was created, added, and released, the association was formed and broken, the state of attribute was updated. The related primitive operations are \textit{createObject()}, \textit{addObject()}, \textit{releaseObject()}, \textit{addOnetoManyAssociation()}, \textit{addOnetoOneAssociation()}, \textit{removeOnetoManyAssociation()}, \textit{removeOnetoOneAssociation()}, and \textit{setAttribute()}. Ten transformation rules of the post-condition are presented in post-condition section. The first rule $R_{16}$ is \[ \begin{array}{l} \mathbf{R_{16}}: \frac{\textit{\textbf{let} ob$\mathord{:}$ClassName \textbf{in} ob.\textbf{oclIsNew}()}}{\emph{ClassName ob = EM.\textbf{createObject}(ClassName$\mathord{:}$String)}} \end{array} \] The OCL expression \textit{let..in} of the rule $R_{16}$ describes the scope of object \textit{ob}. The \textit{ob.oclIsNew()} specifies that the object \textit{ob} was created after the execution of system operation. In order to make system into this state, the rule $R_{16}$ maps \textit{let..in} and \textit{oclIsNew()} to the primitive operation \textit{createObject()}, and then assigns the created object to the reference \textit{ob} of the class named as \textit{ClassName}. For example, the post-condition of system operation \textit{enterItem()} specifies that object \textit{sli} of class \textit{SaleLineItem} was created. By applying the rule $R_{16}$, this OCL expressions are mapped to: \[ \begin{array}{l} \frac{\textit{\textbf{let} sli$\mathord{:}$SaleLineItem \textbf{in} sli.\textbf{oclIsNew}()}}{\emph{SaleLineItem sli = EM.\textbf{createObject}("SaleLineItem")}} \end{array} \] The OCL expression of the rules $R_{17}$ and $R_{18}$ have already been used in the pre-condition to check whether the instance list of class \textit{ClassName} includes or excludes the object \textit{ob} or not. Those OCL expressions in the post-condition indicate that the object list of class \textit{ClassName} includes and excludes the object \textit{ob} after the execution of the system operation. \[ \begin{array}{l} \mathbf{R_{17}}: \frac{\textit{ClassName.\textbf{allInstances}()$\rightarrow$\textbf{includes}(ob)}}{EM.\emph{\textbf{addObject}(ClassName$\mathord{:}$String, ob$\mathord{:}$Class)}} \end{array} \] \[ \begin{array}{l} \mathbf{R_{18}}: \frac{\textit{ClassName.\textbf{allInstances}()$\rightarrow$\textbf{excludes}(ob)}}{EM.\emph{\textbf{releaseObject}(ClassName$\mathord{:}$String, ob$\mathord{:}$Class)}} \end{array} \] It is necessary to add or delete the object \textit{ob} to or from the object list to make the system status conforming the post-condition. Therefore, the \textit{includes()} and \textit{excludes()} with \textit{allInstances()} expression in the post-condition are mapped to the primitive operations \textit{addOjbect()} and \textit{releaseObject()}. \[ \begin{array}{l} \frac{\textit{SalesLineItem.\textbf{allInstances}()$\rightarrow$\textbf{includes}(sli)}}{EM.\emph{\textbf{addObject}("SalesLineItem", "sli")}} \end{array} \] For example, if we apply the rule $R_{17}$ to post-condition of system operation \textit{enterItem()}, the post-condition specifies that the created object \textit{sli} was included in object list of class \textit{SalesLineItem} will be mapped to primitive operation \textit{addObject()} with parameter class name \textit{SalesLineItem} and object name \textit{sli}. \[ \begin{array}{l} \mathbf{R_{19}}: \frac{\textit{ob.assoName$\rightarrow$\textbf{includes}(addOb)}}{\emph{\textbf{addLinkOnetoMany}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, addOb$\mathord{:}$Class)}} \end{array} \] \[ \begin{array}{l} \mathbf{R_{20}}: \frac{\textit{ob.assoName$\rightarrow$\textbf{excludes}(removeOb)}}{\emph{\textbf{removeLinkOnetoMany}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, removeOb$\mathord{:}$Class)}} \end{array} \] OCL expression \textit{includes} and \textit{excludes} can also be applied for the association \textit{ob.assoName}. That means the link has been formed or broken after executing the system operation. Therefore, the above rules $R_{19}$ and $R_{20}$ map those expressions to the primitive operations \textit{addLinkOnetoOne()} and \textit{removeLinkOnetoMany()}. \[ \begin{array}{l} \mathbf{R_{21}}: \frac{\textit{ob.assoName = addOb}}{\emph{\textbf{addLinkOnetoOne}(ob$\mathord{:}$Class, assoName$\mathord{:}$String, addOb$\mathord{:}$Class)}} \end{array} \] The one-to-one association is implemented as an attribute of the class. The rule $R_{21}$ describes if the post-condition specifies that the one-to-one association \textit{ob.assoName} has an linked object \textit{addOb}. The primitive operation \textit{addLinkOnetoOne()} will be executed to make system to satisfy this post-condition. For examples, the links between current sale and the created object \textit{SalesLineItem} object were formed in following transformations: \[ \begin{array}{l} \frac{\textit{currentSale.ContainedSalesLine$\rightarrow$\textbf{includes}(sli)}}{\emph{\textbf{addLinkOnetoMany}(currentSale, "ContainedSalesLine", sli)}} \end{array} \] \[ \begin{array}{l} \frac{\textit{sli.BelongedSale = currentSale}}{\emph{\textbf{addLinkOnetoOne}(sli, "BelongedSale", currentSale)}} \end{array} \] Note that the association from class \textit{Sale} to \textit{SalesLineItem} is multiple, and the reversed association is a one-to-one association. Therefore, the rule $R_{19}$ will be triggered for transformating OCL expression to primitive operation \textit{addLinkOneToMany()} with an object \textit{currentSale}, the association name \textit{ContainedSalesLine}, and the created object \textit{sli} of class \textit{SalesLineItem}. The rule $R_{21}$ is trigger for transformation OCL expression to primitive operation \textit{addLinkOneToOne()} with the object reference \textit{sli} of class \textit{SalesLineItem}, the association name \textit{BelongedSale}, and the reference \textit{currentSale} to current sale object. \[ \begin{array}{l} \mathbf{R_{22}}: \frac{\textit{ob.assoName = \textbf{null}}}{\emph{\textbf{removeLinkOnetoOne}(ob$\mathord{:}$Class, assoName$\mathord{:}$String)}} \end{array} \] The rule $R_{22}$ presents if the post-condition specifies that one-to-one association \textit{ob.assoName} has no associated object, the primitive operation \textit{removeLinkOnetoOne()} will be executed to broke the link that makes the system state conforming this post-condition. \[ \begin{array}{l} \mathbf{R_{23}}: \frac{\textit{ob.attriName = \textit{mathExp}}}{\emph{\textbf{setAttribute}(ob$\mathord{:}$Class, attriName$\mathord{:}$String, \flqq mathExp\frqq$\mathord{:}$PrimeType)}} \end{array} \] The rule $R_{23}$ indicates that the attribute of the object \textit{ob.attriName} is equal to the math expression \textit{mathExp} in the post-condition. The primitive operation \textit{setAttribute} should be executed to conform this condition. For example, post-condition of \textit{enterItem()} specifies the sub-amount of \textit{SalesLineItem} is computed from the price of the item and the quantity of the item. \[ \begin{array}{l} \frac{\textit{sli.Subamount = item.Price * quantity}}{\emph{\textbf{setAttribute}(sli, "Subamount", \textbf{getAttribute}(item, "Price")*quantity)}} \end{array} \] This OCL expression is mapped to primitive operations \textit{setAttribute()} and \textit{getAttribute()}. Primitive operation \textit{getAttribute()} is used to get the price of the item, then the price is multiplied with quantity. Finally, the evaluated result is set to the attribute \textit{Subamount} of object \textit{SalesLineItem} named \textit{sli}. \[ \footnotesize \begin{array}{l} \mathbf{R_{24}}: \frac{\textit{obs->\textbf{forAll}(o$\mathord{:}$ClassName | o.AttriName = mathExp)}}{\textit{\textbf{for} (ClassName o$\mathord{ : }$obs) \{\textbf{setAttribute}(o$\mathord{:}$Class, AttriName$\mathord{:}$String, \flqq mathExp\frqq$\mathord{:}$PrimeType);\}}} \end{array} \] We can use \textit{forAll} to literately specify the state of the objects in the post-condition. The rule $R_{24}$ extends the rule $R_{23}$ from specifying the state of a single object to a list of objects, that maps the OCL expression \textit{forAll} to Java \textit{for} loop expression. \[ \begin{array}{l} \mathbf{R_{25}}: \frac{\textit{\textbf{return} = var\tnote{5}}}{\textit{\textbf{return} \flqq var\frqq;}} \end{array} \] The rule $R_{25}$ specifies the state of return variables after system operation execution. The return variable \textit{var} can be a variable of prime type, a reference to a instances of class, or to a instance list of class. It will be mapped to the Java code correspondingly. \[ \begin{array}{l} \mathbf{R_{26}}: \frac{\textit{\textbf{ThirdPartyServices}.opName(vars)}} {\textit{\textbf{service}.opName(\flqq vars\frqq)}} \end{array} \] The rule $R_{26}$ is a special transformation rule that specifies the third-party APIs such as \textit{cardPayment()} and \textit{sorting()} used in the post-condition. This rule makes our approach extensible to invoking the third-party API library. It will transform the operation \textit{opName} and parameters \textit{vars} into the operation invoking in Java code. \begin{figure*}[!htb] \centering \includegraphics[width=1\textwidth]{mapping.pdf} \caption{An Transformation Example for the Contract of \textit{enterItem()}}\label{mapEnterItem} \end{figure*} \subsection{Transformation Algorithm} We have already presented all transformation rules for system operation decomposition. It is time to introduce the transformation algorithm that transforms the contract of system operation into primitive operations. Transformation algorithm is presented in Algorithm \ref{MappingAlgorithm}. It requires an OCL expression and a tag as input parameters, and return the mapped primitive operations. Note that the tag marks which section of the contract OCL expression comes from. The details of transformation algorithm are that initializing the result set \textit{rs} as empty set and index \textit{i} to zero, and then parsing input \textit{OCLExpression} as a set of sub OCL expressions \textit{sub-formulas} and a set of logic connectors \textit{connectors}, and using \textit{lastn} to record the last element of \textit{sub-formulas}, and iterating each formula \textit{s} of the \textit{sub-formulas} set. In each iteration, algorithm initializes \textit{num} to zero, which indicates whether the appropriate rule is found. According to the value of the tag, different rules are used to check whether the formula \textit{s} is matched, then assign the match rule number to \textit{num} if any rule matched the formula \textit{s}. The formula \textit{s} will be mapped to primitive operation according to the rule. The transformation result is saved in \textit{r}. Note that the OCL expression of pre-condition is mapped into primitive operations connected with Java logic expressions. Therefore, the algorithm appends the transformation result \textit{r} with the connector \textit{connectors[i]} if the tag is \textit{pre-condition} and the index \textit{i} does not point to the last element. Otherwise, the transformation result \textit{r} will be appended to the final result \textit{rs} with a broken line. \begin{algorithm} \SetKwData{SSD}{ssd} \SetKwData{UC}{uc} \SetKwInOut{Input}{Input}\SetKwInOut{Output}{Output} \Input{OCLExpression, Tag} \Output{Primitive Operations} \Begin{ \textit{rs} $\leftarrow$ $\emptyset$\; \textit{i} $\leftarrow$ 0\; \textit{sub-formulas} $\leftarrow$ \textit{parse(OCLExpression)}\; \textit{connectors} $\leftarrow$ \textit{parseConnector(OCLExpression)}\; \textit{lastn} $\leftarrow$ \textit{len(sub-formulas)} - 1\; \For{s $\in$ sub-formulas}{ \textit{num} $\leftarrow$ 0\; \Switch{Tag}{ \Case{definition}{ \textit{num} $\leftarrow$ \textit{matchRule1to7(s)}\; } \Case{pre-condition}{ \textit{num} $\leftarrow$ \textit{matchRule8to15(s)}\; } \Case{post-condition}{ \textit{num} $\leftarrow$ \textit{matchRule16to26(s)}\; } } \eIf{num != 0}{ r $\leftarrow$ \textit{transform(s, num, Tag)}\; \eIf{tag == "pre-condition" and i != lastn}{ \textit{rs.append(r, connectors[i])}\; }{ \textit{rs.append(r, "linebreaks")}\; } }{ \textit{rs.append("transformation error for sub-formula:", s)}\; } i++\; } \Return \textit{rs}\; } \caption{Transformation Algorithm} \label{MappingAlgorithm} \end{algorithm} If no rule is matched to the formula \textit{s}, an error message will be appended to the final result \textit{rs} with the formula \textit{s}. The nature of requirements model implies that, in general, a requirements model may contain non-executable elements, because it focuses on what the system should do rather than how it does it. This error message will help to validate the requirements when generating the prototype. In the end of the iteration, \textit{i} is increased to point to the next sub-formula. After the iteration, the final result \textit{rs} will be returned. \subsection{Transformation Example} We have already introduced the rules for transformation the contracts of system opeartions to the primitive operations. This subsection will present an example of \textit{enterItem()} of use case \textit{processSale} to explain how it work. Note that if a transformation rule is used more than once, we only explain the transformation at the first time. The signature of contract \textit{enterItem} is compiled to the operation signature in Java. In the definition section, the rule $R_3$ maps the OCL expression to the primitive operation \textit{findObject()} to find the object \textit{item} with the input barcode. In the pre-condition section, the rules $R_8$ and $R_{12}$ map the OCL contract to check whether the objects \textit{currentSale} and \textit{item} are undefined, the value of the attribute \textit{IsComplete} is false or not, and the attribute \textit{StockNumber} of object \textit{item} is great than zero. In the post-condition section, 1) the rule $R_{16}$ maps \textit{let..in} and \textit{oclIsnew()} to the primitive operation \textit{createObject()} to create object \textit{sli} of the class \textit{SaleLineItem} for the scanned product. 2) The rule $R_{19}$ maps \textit{includes} OCL contract to the primitive operation \textit{addOnetoManyAssociation()} by adding the link of the new created object \textit{sli} to the current sale object \textit{currentSale}. 3) The rule $R_{21}$ maps \textit{sli.BelongedItem = item} to the primitive operation \textit{addOnetoOneAssociation()} by linking the association \textit{BelongedItem} of object \textit{sli} to the object \textit{item}. 4) The rule $R_{23}$ maps \textit{sli.Subamount = item.Price*quantity} to the primitive operations \textit{setAtrribute()} and \textit{getAtrribute()} by setting the attribute \textit{Subamount} of object \textit{sli} to the sub amount value of \textit{item.getPrice() * quantity}. 5) The rule $R_{17}$ maps the \textit{includes} expression to the primitive operation \textit{addObject()} by adding the reference \textit{sli} to the records of class \textit{SalesLineItem}. 6) The rule $R_{25}$ maps the result expression to the Java return expression. All rules will be repeatedly applied for transforming until all the OCL contract are mapped to the primitive operations with Java code. This section presented the transformation rules and algorithms for system operation decomposition. Next section will introduce how to generate prototype from the requirements model. \section{Prototype} Graphical User Interface (GUI) is one of the important parts of a prototype for customers and domain experts to validate their requirements. Model-View-Controller (MVC) \cite{Krasner:1988:CUM:50757.50759} is one of the most widely used GUI architecture patterns in decades. In this paper, we apply the MVC architecture pattern to prototype, which decouples views and models to make a clear division between models and GUI elements. The prototype contains three modules: view, controller, and model as shown in Figure \ref{prototype}. \begin{figure}[!htb] \centering \includegraphics[width=0.48\textwidth]{prototype} \caption{MVC Prototype Generation from Requirements Model} \label{prototype} \end{figure} \begin{figure*}[!htb] \centering \includegraphics[width=0.95\textwidth]{GUIPrototypePart1} \caption{Prototype GUI for System Function}\label{prototypesf} \end{figure*} \begin{figure*}[!htb] \centering \includegraphics[width=0.95\textwidth]{GUIPrototypePart2} \caption{Prototype GUI for System State}\label{prototypess} \end{figure*} \vspace{.1cm} \noindent \textbf{View:} The view module of the prototype contains UI widgets for end-users to validate system operations and observe corresponding changes in the system state. It contains two UI panels: system functionality and system state. As an example, the system functionality panel of CoCoME is shown in Figure \ref{prototypesf}. It includes the widgets of \textit{system operation lists} in the left side, and the \textit{operation widgets} for passing the parameters to system operations and returning the result in the right side. \textit{System operation lists} are generated from the use case diagram and the system sequence diagram. Moreover, the \textit{operation widgets} for inputting the parameters of system operations are generated from the signatures of the contracts of system operations. The system state panel is used to observe the state of objects of a system before and after executions of system operations. Figure \ref{prototypess} shows the state panel of CoCoME. The system state panel is generated from the conceptual class diagram. The left top side widget of \textit{objects statistics} presents the name and the number of the objects for each class in the current state. The left bottom side widget of \textit{the association of objects} shows the state of associations, which includes the source object, the target object, the name of the association, the number of the associated objects, and whether this association is a one-to-one or one-to-many relationship. When users click a class entry on the left side, the state of the corresponding attribute will display on the right panel widget of \textit{the attributes of objects}. \vspace{.1cm} \noindent \textbf{Controller:} The controller module links the view and model modules, which makes UI events to trigger system operations. The controller listens to the events from UI widgets. When a specific event is captured, the controller retrieves the input parameters from the UI widget, and then deliver the parameters to the corresponding system operation in the model module of the prototype. Finally, the controller will update the UI widgets with the return result. For example, when a cashier clicks the \textit{execute} button on the operation widget of Figure \ref{prototypesf}, the controller will capture a button clicked event generated by the UI widget, and then the controller will get the input parameters and then invoke the \textit{enterItem()} operation. Finally, the controller will update the UI widgets with the return result, and then the cashier will see the result from \textit{operation return} panel of Figure \ref{prototypesf}. \vspace{.1cm} \noindent\textbf{Model:} The model module is the core of the MVC architecture pattern. This module contains 1) the classes encapsulating system operations, which can be invoked by the controller with the parameters from UI widgets, and return the result to the controller for displaying on the view widgets, and 2) the classes generated from the conceptual class model. Note that we name the classes generated from the conceptual class model as \textit{entity classes}, and the others as \textit{fabricated classes}. We will show how to generate fabricated and entity classes in the remaining of this section. \subsection{Fabricated Class Generation} \begin{figure}[!htb] \centering \includegraphics[width=0.45\textwidth]{systemoperations} \caption{Code Generation for System Operation}\label{codesystemoperation} \end{figure} Fabricated classes encapsulating system operations are generated from a use case diagram, system sequence diagrams, the contracts of system operations through system operation templates in Figure \ref{codesystemoperation}. We already discussed the system operation decomposition in the previous section. To implement the decomposed system operation, we not only need to transform the contracts of system operations into primitive operations through the transformation algorithm and rules but also need to orchestrate them to be a validated system operation like the decomposition example of \textit{enterItem()} in Figure \ref{mapEnterItem}. Moreover, the implemented system operations must be encapsulated into classes. In this subsection, we introduce system operation templates to generate the implementations of the system operations from contracts, and how to encapsulate them into classes. \subsubsection{System Operation Template} Xtend \cite{bettini2016implementing} is a flexible and expressive template language. In this paper, we adopt Xtend to define the template. The template used to generate the implementation of system operations from the contract \textit{c} is shown as follows: \begin{lstlisting}[language=mytemplate] /* operation signature */ public «c.opSign.returnType» «c.opSign.name»( «FOR para : c.opSign.parameters SEPARATOR ','» «para.type» «para.name» «ENDFOR») throws PreconditionException { /* contract definition */ «IF c.definition != null» «c.definition.mapping» «ENDIF» /* check precondition */ if («c.precondition.mapping») { /* contract post-condition*/ «c.postcondition.mapping» /* result return */ «IF c.opSign.returnType != null» return «returnName»; «ENDIF» else { throw new PreconditionException(); }} \end{lstlisting} Note that the template will be directly as the output result from the prototype generation, except interpolated expressions inside guillemets \textit{\flqq \frqq}. The expressions in \textit{\flqq \frqq} will be dynamically interpreted in terms of requirements model. Accordingly, the expressions between \textit{\flqq IF\frqq} and \textit{\flqq ENDIF\frqq} will be interpolated when the condition is evaluated as \textit{true}. The expressions between \textit{\flqq FOR\frqq} and \textit{\flqq ENDFOR\frqq} will be repeatedly interpolated through all the elements of the list. For example, if $c$ represents the contract of \textit{enterItem()}, \textit{\flqq c.opSign.name\frqq} will be interpreted as the name of the system operation \textit{enterItem}. The above template helps to implement the contract signature through generating the Java operation with keyword \textit{public}, the name of system operation \textit{\flqq c.opSign.name\frqq}, input variables \textit{\flqq para.name\frqq} with type \textit{\flqq para.type\frqq}, and return type \textit{\flqq c.opSign.returnType\frqq}. Then the template helps to generate the code \textit{\flqq c.definition.compile\frqq} for the definition section of the contract, if any. Then, the template generates the Java \textit{if-else} control flow to check the pre-condition of system operation \textit{\flqq c.precondition.compile\frqq}, and executes the logic code \textit{\flqq c.postcondition.compile\frqq} to make the system satisfying the post-condition. In detail, 1) if the evaluation result of pre-condition is true, the code of the system operation will be executed, and then return the result by Java code \textit{return \flqq returnName\frqq}, if any. 2) If the evaluation result of pre-condition is not true, an exception \textit{PreconditionIsNotSatified} will be directly emitted without executing any code of the system operation. However, this template only helps to generate the skeleton code of system operation. The \textit{\flqq c.definition.mapping\frqq}, \textit{\flqq c.precondition.mapping\frqq} and \textit{\flqq c.postcondition.mapping\frqq} are interpreted by transformation rules and algorithm in section 3. \subsubsection{System Operation Encapsulation} System operations are captured in system sequence diagrams of use cases. If we follow the suggestion of the expert pattern in GRASP, system operations should be encapsulated to the classes (experts) in the conceptual class model. For example, the class \textit{Item} contains attributes of \textit{barcode} and \textit{price}, \textit{enterItem(barcode, quantity)} should be assigned to the class \textit{Item}. However, entity classes have already held primitive operations for manipulating the attributes and associations. We expect to separate concerns into a different abstract level of class to achieve high cohesion and low coupling. \begin{figure}[!htb] \centering \includegraphics[width=0.35\textwidth]{assignment.pdf} \caption{System Operation Encapsulation}\label{assignment} \end{figure} The mediator pattern of GoF suggests an object that encapsulates a set of operations to promote loose coupling. That describes the situation the same as a use case, which includes high cohesion system operations related to one scenario of interactions between the actor and the system. Therefore, we generate a pure fabrication class for each use case and then encapsulate the system operations of the use case to the fabrication class to achieve high cohesion. \begin{algorithm} \SetKwData{SSD}{ssd} \SetKwData{UC}{uc} \SetKwInOut{Input}{Input}\SetKwInOut{Output}{Output} \Input{\textit{ucd} - Use Case Diagram, \\ \textit{ssds} - System Sequence Diagrams, \\ \textit{contracts} - Contracts} \Output{\textit{ucClasses} - fabrication classes} \tcc{Initialize ucClasses as empty set} \textit{ucClasses} $\leftarrow$ $\emptyset$ \; \For{uc $\in$ ucd}{ \tcc{generate fabrication uc class} \textit{ucClass} $\leftarrow$ \textit{generateClassSkeleton(uc, classes)}\; \tcc{find uc related system sequence diagram} \textit{ssd} $\leftarrow$ \textit{findSSD(uc, ssds)}\; \For{op $\in$ ssd}{ \tcc{find operation signature} \textit{opSign} $\leftarrow$ \textit{findSignature(op, contracts)}\; \tcc{encapsulate operation to ucClass} encapsulate \textit{opSign} to class \textit{ucClass}\; } add \textit{ucClass} to \textit{ucClasses}\; } \caption{Generation Algorithm for Fabricated Class and System Operations Encapsulation} \label{collborationsAssignment} \end{algorithm} Algorithm \ref{collborationsAssignment} generates the fabrication classes and encapsulates system operations into them. However, if a target problem contains many use cases, and most use cases only include one system operation, Algorithm \ref{collborationsAssignment} will generate many fabrication classes with just one operation. That breaks the design principle of high cohesion. The appropriate way is to define one fabrication class charging for several responsibilities to promote high cohesion. In the extreme cases, you can even specify only one pure fabrication class for all use cases. To deal with those situations, our CASE tool provides a mechanism that allows product managers and domain experts to decide how to define those fabrication classes for the use cases, and then automatically generates the implementation of those pure fabricated classes. \begin{figure}[!htb] \centering \includegraphics[width=0.45\textwidth]{assignmentexample} \caption{System Operation Encapsulation of Use Case ProcessSale}\label{assignmentexample} \end{figure} For example, the \textit{currentSale} object of class \textit{Sale} created by the system operation \textit{makeNewSale()} is reused in the system operations \textit{enterItem()} and \textit{endSale()} of the use case \textit{processSale}. Algorithm \ref{collborationsAssignment} generates a pure fabricated class \textit{CoCoMEProcessSale} to encapsulate those system operations and the shared object \textit{currentSale}. In detail, \textit{CoCoMEProcessSale} is the pure fabrication class for encapsulating system operations \textit{enterItem()}, \textit{makeNewSale()}, \textit{endSale()}, \textit{makeCashPayment()}, \textit{makeCardPayment()} and the object reference to \textit{currentSale} in Figure \ref{assignmentexample}. This subsection illustrates how to generate fabricated classes and encapsulate the system operations. The next two subsections introduce how to generate entity classes from the conceptual class diagram as well as primitive operations. \subsection{Entity Class Generation} Entity classes generation is a necessary procedure to achieve the auto-prototyping from requirements model, which is shown in Figure \ref{codegenerationatomicoperation}. It not only needs to generate the attributes and associations of the entity class but also requires to generate the implementation of primitive operations for setting and getting the attributes, finding linked objects, and adding and removing the links. We will show the details in the subsection. \begin{figure}[!htb] \centering \includegraphics[width=0.45\textwidth]{atomicoperations} \caption{Code Generation for Primitive Operations}\label{codegenerationatomicoperation} \end{figure} \subsubsection{Generation Algorithm for Entity Classes} The information expert pattern of GRASP suggests assigning responsibilities to the information expert, and the expert class knows the information necessary to fulfill the responsibilities. Therefore, entity classes encapsulate primitive operations about getting and setting the values of the their attributes, forming and breaking the their links. For example, entity class \textit{Item} has the \textit{Price} attribute, therefore, primitive operation \textit{getPrice()} is encapsulated in class \textit{Item}. Entity class \textit{SaleLineItem} has the \textit{Quantity} attribute and the association \textit{BelongedSale}, therefore, it encapsulates primitive operation \textit{updateAttributeQuantity()} and \textit{addAssociationTosale()}. The algorithm that generates the entity classes from a conceptual class diagram is shown in Algorithm \ref{atomicAttriandAsso}. \begin{algorithm} \SetKwData{Left}{left}\SetKwData{This}{this}\SetKwData{Up}{up} \SetKwFunction{Union}{Union}\SetKwFunction{FindCompress}{FindCompress} \SetKwInOut{Input}{Input}\SetKwInOut{Output}{Output} \Input{$ccd$ - Conceptual Class Diagram \\ $t_{ec}$ - Entity Class Template \\ $t_{ao}$ - Primitive Operation Templates} \Output{Entity Classes} \For{entity $\in$ $ccd$}{ generate entity class skeleton by $t_{ec}$\; \For{attribute $\in$ entity}{ genereate \textit{getAttribute()} by $t_{ao}$\; genereate \textit{setAttribute()} by $t_{ao}$\; } \For{association $\in$ entity}{ \uIf{Is-Multiple(association) == true}{ genereate \textit{findLinkedObjects($t_{ao}$)}\; genereate \textit{addLinkOnetoMany($t_{ao}$)}\; genereate \textit{removeLinkOnetoMany($t_{ao}$)}\; } \Else{ genereate \textit{findLinkedObject($t_{ao}$)}\; genereate \textit{addLinkOnetoOne($t_{ao}$)}\; genereate \textit{removeLinkOnetoOne($t_{ao}$)}\; } } } \caption{Generation Algorithm for Entity Classes} \label{atomicAttriandAsso} \end{algorithm} This algorithm takes a conceptual class model as input and generates entity classes with primitive operations. For each class in the conceptual class diagram, entity class skeleton is generated through the entity class template. Then, primitive operations about getting and setting each attribute of the entity class are generated. For each association of the class, a) if the association is a one-to-many relationship, primitive operations about finding linked objects, adding and removing link of one-to-many association are generated, b) if the association is a one-to-one relationship, primitive operations about finding the linked object, adding and removing link of one-to-one association are generated. Note that above entity skeleton and primitive operations are generated through the code templates, and we will introduce those templates in the remaining of this subsection. \subsubsection{Entity Class Template} The generation skeleton of entity classes is straightforward. Many UML tools support this feature. The template to generate an entity class \textit{c} is: \begin{lstlisting}[language=mytemplate] /* Class Skeleton */ public class «c.name» /* Class Inheritance */ «IF c.superClass != null» extends «c.superClass.Name» «ENDIF» { /* Attributes */ «FOR attribute : c.attributes» private «attribute.type» «attribute.name»; «ENDFOR» /* Associations */ «FOR assoc : c.associations» private «IF assoc.isIsmultiple» List<«assoc.class»> «assoc.name» = new LinkedList<«assoc.class»>(); «ELSE» «assoc.class.name» «assoc.name»; «ENDIF» «ENDFOR» /* primitive operations templates */ } \end{lstlisting} The template defines a public class with the keyword \textit{public} and the name \textit{c.name} inside of «». If the class has a super-class, the text of \textit{c.superClass.name} will be replaced by the name of the super-class along with the keyword \textit{extends}. The attribute is declared by the keyword \textit{private} with the type \textit{attribute.type} and the name \textit{attribute.name}. The association is also declared by the keyword \textit{private} with a) a typed list \textit{List<assoc.class>} and association name \textit{assoc.name}, if the association is a one-to-many relation, b) an attribute with the name of associated class \textit{assoc.class.name} and the type of associated class \textit{assoc.class}, if the association is a one-to-one relation. \subsubsection{Primitive Operation Templates} The templates for primitive operations \textit{getAttribute()} and \textit{setAttribute()} are: \begin{lstlisting}[language=mytemplate] //Getting Attribute public «attribute.type» get«attribute.name»() { return «attribute.name»; } //Setting Attribute public void set«attribute.name» («attribute.type» «attribute.name») { this.«attribute.name» = «attribute.name»; } \end{lstlisting} Getting an attribute can be defined as the public operation with the name \textit{get\flqq attribute.name\frqq} and the type \textit{\flqq attribute.type\frqq} of attribute, which is fulfilled by directly returning the attribute by using the keyword \textit{return}. The setting attribute can be fulfilled by setting the value of attribute \textit{this.\flqq attribute.name\frqq} with an input of typed variables. The primitive operation templates for finding linked objects, linking a new object, and removing an linked object are: \vspace{.1cm} \begin{lstlisting}[language=mytemplate] //findLinkedObjects() public List<«assoc.class»> get«assoc.name»() { return «assoc.name»; } //addLinkOnetoMany() public void add«assoc.name»(«assoc.class» ob) { this.«assoc.name».add(ob); } //removeLinkOnetoMany() public void remove«assoc.name»(«assoc.class» ob) { this.«assoc.name».remove(ob); } \end{lstlisting} We use a reference list to store object references for the one-to-many association. Therefore, finding objects through link can be directly implemented by returning the reference list of the association. Forming a link can be fulfilled by invoking the adding operation of the list as well as the deleting operation for breaking a link. \begin{lstlisting}[language=mytemplate] //findLinkedObject public «assoc.class» get«assoc.name»() { return «assoc.name»; } //addLinkOnetoOne() removeLinkOnetoOne() public void set«assoc.name»(«assoc.class» ob) { this.«assoc.name» = ob; } \end{lstlisting} The one-to-one association is implemented as an attribute with the type of associated class. Thus, the implementation of finding the object through a link of one-to-one association is the same as getting the value of an attribute. The implementation of adding and removing a link of an one-to-one association is the same as setting primitive operation of an attribute. For example, when removing a link of a one-to-one association, we can just set \textit{null} as the value of the link. \subsection{EntityManager Generation} In object-oriented system, the object can be eventually found through the links of the objects. However, we need to locate the entrance object then to start the finding procedures. The primitive operation \textit{findObject()} is used to find the first entrance object, then other objects can be reached through the primitive operation \textit{findLinkedObject()} of the links of objects. To implement \textit{findObject()}, a pure fabrication class named as \textit{EntityManager} is required, which contains all the references to the objects of entity classes as well as the primitive operations \textit{findObject()} and \textit{findLinkedObject()}. Moreover, the creator pattern of GRASP suggests assigning the creating responsibility to the class recording the instances of the created objects. \textit{EntityManager} records all instances of entity classes. Therefore, the primitive operations \textit{createObject()} and \textit{releaseObject()} are assigned to \textit{EntityManager}. In addition, \textit{EntityManager} is required a global accessing point. According to the singleton pattern of GoF, we build \textit{EntityManager} as a singleton class, which has the only one instance, and provide a global accessing point. In short, the generation algorithm of \textit{EntityManger} is shown in Algorithm \ref{entitymanager}. \begin{algorithm} \SetKwData{Left}{left}\SetKwData{This}{this}\SetKwData{Up}{up} \SetKwInOut{Input}{Input}\SetKwInOut{Output}{Output} \Input{$ccd$ - Conceptual Class Diagram \\ $t_{em}$ - EntityManager Template \\ $t_{o}$ - Primitive Operation Templates for Object} \Output{EntityManager Class} \Begin{ \tcc{Generate EntityManager Skeleton} generate \textit{EntityManager} skeleton by $ccd$, $t_{em}$\; \tcc{Generation Primitive Operations} generate \textit{findObject() by $t_{o}$}\; generate \textit{findObjects()} by $t_{o}$\; generate \textit{createObject()} by $t_{o}$\; generate \textit{addObject()} by $t_{o}$\; generate \textit{releaseObject()} by $t_{o}$\; } \caption{Generation Algorithm for EntityManager} \label{entitymanager} \end{algorithm} This algorithm takes a conceptual class model, \textit{EntityManager} template, the templates of object-related primitive operation as input, generates \textit{EntityManager} classes. We generate \textit{EntityManager} skeleton through \textit{EntityManager} template, and the implementation of primitive operations \textit{findObject()}, \textit{findObjects()}, \textit{createObject()}, \textit{addObject()} and \textit{releaseObject()} inside of \textit{EntityManager}. Note that \textit{EntityManager} records all the instances of entity classes, and \textit{addObject()} is used for adding the object into the records. We will show those templates in the remaining of this subsection. \subsubsection{EntityManager Template} The template for generating \textit{EntityManager} skeleton is shown as follows: \begin{lstlisting}[language=mytemplate] /* EntityManager Template */ public class EntityManager { /* HashMap Object Records*/ private static Map<String, List> AllInstance = new HashMap<String, List>(); /* create object reference list */ «FOR c : classes» private static List<«c.name»> «c.name»Instances = new LinkedList<«c.name»>(); «ENDFOR» /* Put object reference list into Map */ static { «FOR c : classes» AllInstance.put("«c.name»", «c.name»Instances); «ENDFOR» } /* Get all objects of the class */ public static List getAllInstancesOf (String ClassName) { return AllInstance.get(ClassName); } } \end{lstlisting} We use Java \textit{HashMap} named \textit{AllInstances} to record all the object reference lists. Each object reference list is implemented as a \textit{LinkedList} of Java with name \textit{\flqq c.name\frqq Instances}. \textit{\flqq c.name\frqq} will be replaced by the name of classes in the conceptual class model. All references list of object are added to this \textit{HashMap} \textit{AllInstance}. After that, we can find the specific object reference list directly by the name of entity class. \subsubsection{Primitive Operation Templates for Finding Objects} By using \textit{EntityManager}, we can do fine-grained search \textit{findObject()} and \textit{findObjects()} with a query condition \textit{precondition(o)} on the reference list. The template of finding object is: \begin{lstlisting}[language=mytemplate] /* find object template */ «cName» target = null; //initialize target object for («cName» o: EntityManager.getAllInstancesOf(«cName»)) { //finding the object satisfies the condition if («precondtion(o)») { target = o; return target; } } \end{lstlisting} The template initializes the object reference \textit{target} as \textit{null}, and then iterates the object list by \textit{getAllInstancesOf} to find the object \textit{o} satisfying the search condition \textit{precondition(o)} (refer the details of precondition transformation to section 3.2.2), Finally, the template assigns the finding object \textit{o} to object \textit{target}, and returns the found object. The template \textit{findObjects} is similar to \textit{findObject}, which is: \begin{lstlisting}[language=mytemplate] /* find objects template */ List<«c.name»> targets = = new LinkedList<>(); //initialize target object lists for («c.name» o: EntityManager.getAllInstancesOf(«c.name»)) { //finding the object satisfies the condition if («precondtion(o)») { targets.add(o); } } return targets; \end{lstlisting} The differences is the \textit{findObjects()} template initializes the \textit{targets} as a linked list, adds the object \textit{o} to the list \textit{targets} when the object \textit{o} satisfies the condition, and finally, returns the target list \textit{targets}. \subsubsection{Templates for Creating, Adding and Releasing Object} The factory method pattern of GoF suggests defining an interface for object creation, but let sub-classes decide which class to instantiate. Therefore, we impact all the create object responsibilities in the \textit{EntityManager}, and define a factory method that creates all objects of classes. This factory method can invoke a concrete creator that returns an instance of an entity class through the Java reflect mechanism. The primitive operation template for creating objects is: \begin{lstlisting}[language=mytemplate] /* create object template */ public static Object createObject(String cName) { Class c = Class.forName("EntityManager"); Method m = c.getDeclaredMethod("create" + cName + "Object"); return m.invoke(c); } «FOR c : classes» public static «c.name» create«c.name»Object() { «c.name» o = new «c.name»(); return o; } «ENDFOR» \end{lstlisting} The factory method \textit{createObject} provides a single-point to create object, it will invoke the concrete \textit{create«c.name»Object} method to create and return the object of class \textit{«c.name»}. We also use this pattern to build the \textit{addObject} and \textit{deleteObject} template. The template for generating primitive operation \textit{addObject()} is \begin{lstlisting}[language=mytemplate] /* add object template */ public static Object addObject (String cName, Object ob) { Class c = Class.forName("EntityManager"); Method m = c.getDeclaredMethod("add" + cName + "Object", Class.forName(cName)); return (boolean) m.invoke(c, ob); } «FOR c : classes» public static boolean add«c.name»Object(«c.name» o) { return «c.name»Instances.add(o); } «ENDFOR» \end{lstlisting} Object \textit{ob} and the name of class are passed to the factory method \textit{addObject}. Then \textit{addObject} uses Java reflect to invoke the concrete method \textit{add«c.name»Object} to add the object \textit{ob} to the object list \textit{«c.name»Instances}. We use the same pattern to build the template \textit{deleteObject}: \begin{lstlisting}[language=mytemplate] /* release object template */ public static boolean deleteObject (String cName, Object ob) { Class c = Class.forName("EntityManager"); Method m = c.getDeclaredMethod("delete" + cName + "Object", Class.forName(cName)); return (boolean) m.invoke(c, ob); } «FOR c : classes» public static boolean delete«c.name»Object («c.name» o) { return «c.name»Instances.remove(o); } «ENDFOR» \end{lstlisting} \section{Requirements Validation and Evolution} \label{sec:requirementvalidation} This section presents how to use the prototype to validate and evolve requirements. An overview is depicted in Figure \ref{refinement}. \begin{figure}[!htb] \centering \includegraphics[width=0.4\textwidth]{refinementprocess} \caption{Requirement Validation and Evolution}\label{refinement} \end{figure} It starts with requirements $R_1$, from which a prototype $P_1$ is automatically generated using implementation CASE tool \textit{RM2PT} based on the techniques presented in Section 3 and 4. Then $P_1$ is used to validate the requirements $R_1$. If the faults of requirements or the missing requirements are found in $R_1$, we evolve the requirements $R_1$ to a requirements $R_2$ by fixing the errors and elicit new requirements. Then a prototype $P_2$ is generated from requirements $R_2$, we use prototype $P_2$ to validate requirements $R_2$. This process repeats until no more faults and missing requirements are found. In the practice, requirements are often a moving target, and thus requirements validation and evolution can be triggered in any stage of software engineering if needed. Customers and project managers can quickly validate functional requirements through the generated prototype without writing any code. A prototype provides two modules for requirements validation: \vspace{.1cm} \noindent\textbf{$\bullet$ System Operation Execution with Pre-condition and Invariant Checking} \hspace{1mm} Prototype provides a window for the customers to test system operations. For example, CoCoMe prototype includes the widgets of system operation list on the left side, the system operation panel in the middle and the contracts panel on the right side in Figure \ref{systemfunctionality}. \begin{figure}[!htb] \centering \includegraphics[width=0.40\textwidth]{precondition} \caption{Pre-condition Checking}\label{precondition} \end{figure} \begin{figure}[!htb] \centering \includegraphics[width=0.5\textwidth]{invariant} \caption{Invariant Checking}\label{invariant} \end{figure} Moreover, the prototype involves pre-conditions and invariants checking. When executing a system operation, a warning message is prompted if pre-condition is not satisfied in Figure \ref{precondition}. Moreover, if the execution of the system function make system state break the related invariants, the color of the invariant bar will become red from green in Figure \ref{invariant}. That indicates the errors in the requirements. Further inspections are required to locate the errors. \vspace{.1cm} \noindent\textbf{$\bullet$ State Observation} The location of the errors may be in the pre-condition, post-condition of the contract. Invariant checking can only indicate the errors. The state observation of the objects can help to locate the faults of the requirements. Figure \ref{systemstatus} shows the state observation panel of CoCoME prototype. The left top side presents the name and the number of the objects for each class in the current system. For example, the number of the objects of the classes \textit{Store}, \textit{CashDesk}, \textit{Sale} and \textit{Item} in the CoCoME system. The left bottom side shows the status association, which includes the source object, the target object, the name of the association, the number of the associated objects, and whether this association is a one-to-one or one-to-many relationship. For example, the Figure \ref{systemstatus} shows the state of association \textit{BelongedCashDesk} of the object \textit{Sale}. The middle side of the panel shows the status of the attributes of the objects. E.g, the status of the attributes \textit{Time}, \textit{IsComplete}, \textit{Amount} of the \textit{Sale} objects. When clicking a class entry on the left side, the state of the corresponding attributes and associations will display on the middle and left bottom side of the panel. Furthermore, all the invariants of the system are listed on the right side of the panel. When any invariant does not hold, it will become as red bar like in the system function panel. The remaining parts of this subsection will show how to use the generated prototype to validate the requirements. \subsection{Start-up Objects} When the prototype is opened for the first time, it does not contain any object. That means system operations except adding objects cannot be executed because the pre-conditions of functions are not satisfied. The start-up objects must be added into the prototype before requirements validation. \begin{figure}[!htb] \centering \includegraphics[width=0.5\textwidth]{startup.png} \caption{Start-up Objects}\label{startup} \end{figure} The prototype provides two options to load start-up objects. 1) Load objects from the checkpoint file. The users can click the \textit{Load State} button in the system state panel to load the checkpoint files into the system to restore the status of system saved before. 2) Manually create start-up object by using the Create, Read, Update, and Delete (CRUD) operations provided by prototypes. RM2PT provides mechanisms to automatically generate the contracts and implementations of CRUD operations by marking conceptual classes. The administrator can use this mechanism to add the start-up objects into the prototype. For example, administrators add the \textit{Store} object with the ID \textit{1}, name \textit{UMStore}, and address \textit{Taipa} into the system by \textit{createStore()} operation in Figure \ref{startup}. \begin{figure*}[!htb] \centering \includegraphics[width=0.95\textwidth]{systemfunctionality} \caption{System Operation Validation}\label{systemfunctionality} \end{figure*} \begin{figure*}[!htb] \centering \includegraphics[width=0.95\textwidth]{systemstatus} \caption{System State Observation}\label{systemstatus} \end{figure*} \subsection{Pre-condition Validation} The execution of system operation containing pre-condition errors may lead system to an un-expected state that violates system invariants. It contains two cases: parameter constraint missing and constraint error. \vspace{.05cm} \noindent \textbf{Parameter Constraint Missing:} Parameter constraint missing means that the constraints of parameters are missing in the pre-condition, the execution of the system operation may lead system to an un-expected state that violates system invariants. For example, the customer makes a cash payment \$20 for their \$40 products in CoCoMe. If the pre-condition does not check the tendered money is greater than or equal to the total price of products, the invariant of \textit{CashPayment} that the balance must be greater than or equal to zero may be violated. The invariant bar of the prototype will become red as in Figure \ref{invariant}. Users should add the missed constraints into the pre-condition of \textit{cashPayment} to fix this error. \vspace{.05cm} \noindent\textbf{Constraint Error:} Constraint error means that the constraints are not correct in the pre-condition, the execution of the system operation may lead system to un-expected state that violates system invariants. For example, ATM has the invariant about the one-day maximum withdraw limitation (E.g., \$2000 pre-day). When a customer intends to withdraw \$500 from her account if she has already withdrawn \$1800 on the same day. This request must be rejected by the pre-condition of \textit{withdraw} operation. However, this request can be executed if the pre-condition is that the total withdrew money of one day is lesser than or equal to \$2000. In this case, the execution of \textit{withdraw} will make the system state violate the maximum limitation invariant due to the withdrew money \$2300 is higher than the maximum limitation \$2000. We need to fix this error by replacing the pre-condition to check the value of withdrawing must be lesser than or equal to the value of maximum limitation minus the total value of withdrew today ($withdrawing \le maxValue - withdrew$). \subsection{Post-condition Validation} Post-condition errors can also lead the system to an un-expected states that violate system invariants and the pre-condition of the next system operations under the same use case. For examples, 1) one invariant of CoCoME system shows the final price of the current sale process must be greater than zero. The operation \textit{endSale()} adds all the sub-amount of products together as the final price for the payment. If there is a typo when the plus sign '+' is typed as minus sign '-' in the post-condition, the final price will be less than zero. That will violate the price invariant after execution. 2) the post-condition of \textit{endSale()} should specify the flag \textit{IsReadytoPay} to \textit{true}. If missing this specification in the post-condition, the pre-condition of the system operation \textit{makePayment()} cannot be satisfied, and a warning message will prompt in Figure \ref{precondition}. The product managers can validate and fix those post-condition errors without too many efforts by checking the system state before and after the execution of system operations in the prototypes. In short, the prototype can indicate the pre-condition and invariant violations in requirements models. Although locating and fixing the errors require carefully observing and analyzing the state of objects and the contracts, the generated prototype provides an intuition way to help product managers and customer to validate their requirements. Moreover, the requirements cannot be elicited entirely at one time. After validating the requirements, the customers and product managers would fix the faults of the requirements and find new interesting functional requirements of the target system. This fixing and eliciting requirements process will make the previous requirements version from $R_{n-1}$ to next version $R_n$ in Figure \ref{refinement}. Then the evolved requirement $R_n$ will be used to generate a new prototype $P_n$. Compared with the methods to manually implementing the prototype, customers and project managers can use RM2PT to generate new prototypes and validate the requirements without waiting for the software engineers to implement the prototype. Therefore, RM2PT shortens the timeline and boosts the software development process. Moreover, RM2PT reduces the inconsistency between the requirements and the prototype by automatically transformation rules; otherwise, errors may be involved by the green hands or careless of the human nature. In the next section, we will demonstrate the validity of the RM2PT through four classical case studies using in our daily life. \section{Case Studies} In this section, we use four case studies to demonstrate the validity and capacity of the proposed approach for requirements validation and evolution. Those case studies are wildly used systems in our daily life: supermarket system (CoCoME), Library Management System (LibMS), Automated Teller Machine (ATM), and Loan Processing System (LoanPS). CoCoME mainly contains the scenarios of the cashier to process sales in supermarkets, and supermarket managers to manage the storage of products. LibMS primarily involves the student to borrow and return books. ATM concerns the customer to withdraw and credit money. LoanPS touches the use cases of submitting and evaluating loan requests, booking a new loan and making the payment. Those four case studies demonstrate the different aspects of requirements modeling and prototyping of RM2PT. ATM provides a quick-start and simple demonstration of RM2PT about requirements modeling and prototyping. CoCoME demonstrates the capacity of generation and validation complex use case such as \textit{processSale}. LibMS demonstrates the capacity of generation and validation of the complex system operations, that makes the case study of LibMS contains the highest number of primitive operations. The last one LoanPS demonstrates the ability to invoking third-party system services by including the remote operations calling from the account management system of banks and the credit management system of the governments. We will show the requirements modeling and validation results in the following parts. More details of the requirements models can be found at GitHub\footnote{\url{https://github.com/RM2PT/CaseStudies}}. \subsection{Evaluation Complexity of Requirements Model} Requirements complexity is measured by the dimensions of the number of the actors, use cases, system operations, entity classes, and associations of the entity classes in the requirements model. We present the requirements complexity of four case studies in Table \ref{complexity}. \begin{table}[!htb] \ra{1.2} \caption{The Complexity of Requirements Models} \label{complexity} \centering \begin{adjustbox}{max width=\columnwidth} \begin{threeparttable} \begin{tabular}{lccccccc} \toprule Case Study & Actor & Use Case & SO & AO & Entity Class & Association & INV \\ \midrule ATM & 2 & 6 & 15 & 103 & 3 & 4 & 5 \\ CoCoME & 3 & 16 & 43 & 273 & 13 & 20 & 10 \\ LibMS & 7 & 19 & 45 & 433 & 11 & 17 & 25 \\ LoanPS & 5 & 10 & 34 & 171 & 12 & 8 & 12 \\ \midrule Sum & 17 & 51 & 137 & 980 & 39 & 49 & 52 \\ \bottomrule \end{tabular} \begin{tablenotes}[para] \footnotesize \item[*] Above table shows the number of elements in the requirements model. SO and AO are the abbreviations of system and primitive operations responsibility respectively. INV is the abbreviation of invariant.\\ \end{tablenotes} \end{threeparttable} \end{adjustbox} \end{table} The requirements model of CoCoME contains three actors, sixteen use cases, forty-three system operations, two hundred-seven-three primitive operations, thirteen entity classes, twenty associations between those objects, and ten invariants. The requirements model of LibMS includes seven actors, nineteen use cases, forty-five system operations, four hundred-thirty-three primitive operations, eleven entity classes, seventeen associations, and twenty-five invariants. The requirements model of ATM includes two actors, six use cases, fifteen system operations, one hundred and three primitive operations, three entity classes, four associations, and five invariants. The requirements model of LoanPS includes five actors, ten use cases, thirty-four system operations, one hundred and seventy-one three primitive operations, twelve entity classes, eight associations, and twelve invariants. In short, we provides \textbf{17} actors, \textbf{51} use cases, \textbf{137} system operations, \textbf{980} primitive operation, \textbf{39} entity classes, \textbf{49} associations of entity classes, and \textbf{52} invariants. \subsection{Results of Requirements Modeling and Generation} The generation results of four case studies are shown in this subsection. The failures of requirements modeling and generation can be divided into two situations: 1) the contracts of system operations cannot be correctly specified in OCL expression without invoking third-party APIs such as sorting algorithm, sending email, and etc. 2) the contracts of system operations can be correctly specified in OCL expression, but no transformation rule is matched to generate the implementation for the system operations correctly. We count both failures of those case studies by the measurements \textit{MSuccess} and \textit{GenSuceess} in Table \ref{GenereationAndValidation}. \begin{table}[!htb] \ra{1.2} \caption{The Generation Result of System Operations} \label{GenereationAndValidation} \centering \begin{adjustbox}{max width=1\columnwidth} \begin{threeparttable} \begin{tabular}{lcccc} \toprule Case Study & NumSO & MSuccess & GenSuccess & SuccessRate (\%) \\ \midrule ATM & 15 & 15 & 15 & 100 \\ CoCoME & 43 & 41 & 40 & 93.02 \\ LibMS & 45 & 43 & 42 & 93.33\\ LoanPS & 34 & 30 & 30 & 88.23 \\ \midrule Average & 34.25 & 32.25 & 31.75 & 93.65 \\ \bottomrule \end{tabular} \begin{tablenotes}[para] \footnotesize \item[*] MSuccess is the number of SO which is modeled correctly without external event-call, GenSuccess is the number of SO which is successfully generated, SuccessRate = GenSuccess / NumSO. \end{tablenotes} \end{threeparttable} \end{adjustbox} \end{table} \noindent \textbf{ATM} is the most straightforward case study of four. It does not contain a complex workflow. All of the fifteen system operations can be successfully modeled and generated. The successful generation rate reached 100\%. \vspace{.1cm} \noindent \textbf{CoCoME} contains forty-three system operations. Forty-one can be successfully generated, in which two system operations cannot be specified correctly. The two failures of requirements modeling are 1) listing top 10 out of stock products, 2) send emailing notification to the student, who holds the book copy will be due in the next two days. Preconditions of those two system operations can be specified correctly, but the sub-expressions of post-condition, \textit{listing top 10} and \textit{sending email}, can not be specified correctly in OCL expression. Therefore, the corresponding transformation and implementation cannot be generated correctly as well. Another case is that listing almost out of stock the products with storage less than 10 in ascending order. That post-condition can be specified correctly, but the sub-expression of \textit{ascending order} cannot be generated because no transformation rule can be used to map that sub-expression to the primitive operations. Counting the failures of system operations modeling and generation, the successful rate of prototype \textit{CoCoME} is 93.02\%. \vspace{.2cm} \noindent \textbf{LibMS} contains forty-five system operations, forty-three can be correctly modeled, and forty can be correctly generated. The two modeling failures are 1) listing the top 10 the student holding the overdue book over a week. 2) sending an email notification to the student, who holds the book copy will be due in the next two days. Like CoCoMe, the failures of modeling are also due to the expression \textit{top 10} and \textit{sending email}. The failure of generation is listing the holding book records by the due day in \textit{ascending order}. Counting in those failures, the successful generation rate is 91.11\%. \vspace{.2cm} \noindent \textbf{LoanPS} contains thirty-four system operations, and thirty system operations can be correctly specified and generated. Four failures of modeling include 1) listing the top 10 loan requests with loan assistant, 2) sending a notification to the applicant when her loan request is approved, 3) printing the loan agreement, 4) sending the notification to the customer when their loan is due soon. The successful generation rate of \textit{LoanPS} is 88.23\%. In short, RM2PT can successfully generate average \textbf{93.65\%} system operations of those four case studies without any extension. There still has \textbf{6.35\% errors} of requirements modeling and prototype generation. As we mentioned, the errors mainly caused by the failures of specifying the post-conditions of the contract such as sending email, printing document, sorting and retrieving top N elements. To help users easier finding the failures of modeling and prototype generation, 1) our case tool RM2PT can automatically indicate the sub-expression error with red underlines in the post-conditions when generating the prototype from the requirement model and the code errors in the generated prototype. 2) RM2PT provides an extension mechanism to allow specifying the third-party APIs were invoking in OCL expression. Once errors were identified by RM2PT, we can replace the error expression in post-condition with the calling expression of the third-party service. This calling expression will be a transformation to the operation calling in the prototype. The developer can manually implement the operation, or invoking the operation system APIs (for sending email and printing document) and reusing the collection algorithm library (for sorting and top N elements retrieving). After specified the calling expression of third-services into the requirements model, all the system operations of four case studies can be correctly modeled and generated. This subsection exposes the results of requirements modeling, prototype generation, and how to fix the failures of modeling and generation. Based on the techniques of requirements validation and evolution in the section \ref{sec:requirementvalidation}, we will show the result of validation and evolution in next subsection. \subsection{Results of Requirements Validation and Evolution} The result of requirements validation and evolution of four case studies are shown in Table \ref{RequirementsErrors} and \ref{RequirementsMissing}, which contain the statistic of requirements errors and missing. \begin{table}[!htb] \ra{1.2} \caption{Requirements Errors} \label{RequirementsErrors} \centering \begin{adjustbox}{max width=1\columnwidth} \begin{threeparttable} \begin{tabular}{lccc} \toprule & \multicolumn{2}{c}{Requirements Errors} \\ \cmidrule(lr){2-3} Name & Pre-condition & Post-condition \\ \midrule ATM & 5 & 12 \\ CoCoME & 8 & 23 \\ LibMS & 12 & 26 \\ LoanPS & 6 & 21 \\ \midrule Total & 31 & 68 \\ \bottomrule \end{tabular} \begin{tablenotes}[para] \footnotesize \end{tablenotes} \end{threeparttable} \end{adjustbox} \end{table} During the three-round modeling, prototype generation, requirements validation, we found \textbf{99} requirements errors, which includes 31 errors in the pre-condition and 68 errors in the post-condition. In details, 5 pre-condition and 12 post-condition errors are founded in ATM. 8 pre-condition and 23 post-condition are founded in CoCoME case study. 12 pre-condition and 26 post-condition errors are founded in LibMS case study. 6 pre-condition and 21 post-condition are founded in LoanPS case study. \begin{table}[!htb] \ra{1.2} \caption{Requirements Missing} \label{RequirementsMissing} \centering \begin{adjustbox}{max width=1\columnwidth} \begin{threeparttable} \begin{tabular}{lcccccc} \toprule & \multicolumn{5}{c}{Requirements Missing} \\ \cmidrule(lr){2-7} Name & Actor & UseCase & SO & Entity Class & Association & INV\\ \midrule ATM & 1 & 3 & 9 & 1 & 2 & 3\\ CoCoME & 1 & 11 & 22 & 5 & 10 & 5 \\ LibMS & 4 & 12 & 14 & 11 & 15 & 12\\ LoanPS & 2 & 3 & 15 & 4 & 2 & 8\\ \midrule Total & 8 & 29 & 60 & 21 & 29 & 28\\ \bottomrule \end{tabular} \begin{tablenotes}[para] \footnotesize \end{tablenotes} \end{threeparttable} \end{adjustbox} \end{table} Requirement validation can help to find errors in requirements, but also can help to find missing requirements. During the requirement validations and refinements from version one the version three, \textit{ATM} add one actor, three use cases, nine system operations, one entity class, two associations of entity classes, and two invariants. CoCoME adds one actor, eleven use cases, twenty-two system operations, five entity classes, ten associations of entity classes, and five invariants. LibMS adds four actors, twelve use cases, fourteen system operations, eleven entity classes, ten associations of entity classes, and twelve invariants. LoanPS adds two actors, three use cases, fifteen system operations, four entity classes, two associations of entity classes, and eight invariants. Totally, we find \textbf{173} missing requirements during the requirements validations and refinements about \textbf{6} actors, \textbf{29} use cases, \textbf{60} system operations, \textbf{21} entity classes, \textbf{29} the associations of entity classes, and \textbf{28} invariants. \subsection{Performance of Prototype Generation} The advantages of the proposed approach to automated generate prototype are more efficient than the manual prototype implementation by the developers. We evaluate the RM2PT prototyping performance by comprising prototype time among RM2PT and the developers. The performance is measured on the dimensions: a) line of code, which is calculus by the tool \textit{cloc}\footnote{\url{https://github.com/AlDanial/cloc}}, b) prototype time of RM2PT, c) generation time for the system operations, d) average coding time of ten master students from computer science, e) average coding time of ten developers from the industry with at least three year coding experiments. All the measurement are computed on the PC with 3.5 GHz Intel Core i5, 16 GB 1600 MHz DDR3, and 500 GB Flash Storage. \begin{table}[!htb] \ra{1.2} \caption{Prototyping Performance} \label{prototypingperformance} \centering \begin{adjustbox}{max width=1\columnwidth} \begin{threeparttable} \begin{tabular}{lccccc} \toprule Name & Line of Code & Prototype Time (ms) & SO Time(ms) & Student (hour) & Developer (hour) \\ \midrule ATM & 3897 & 309.74 & 2.26 & 8.3 & 3.2\\ CoCoME & 9572 & 788.99 & 9.78 & 19.2 & 10.6\\ LibMS & 12017 & 1443.39 & 18.22 & 25.1 & 14.3\\ LoanPS & 7814 & 832.78 & 5.52 & 16.2 & 8.4\\ \midrule Average & 8325 & 843.73 & 8.95 & 17.20 & 9.14 \\ \bottomrule \end{tabular} \begin{tablenotes}[para] \footnotesize \end{tablenotes} \end{threeparttable} \end{adjustbox} \end{table} The comparison result is presented in Table \ref{prototypingperformance}. ATM contains 3897 lines of code, the generation of prototype spends 309.74 ms, in which system operations only spend 2.26 ms, the average coding time of students is 8.3 hours, but developers require 3.2 hours. CoCoME contains 9572 lines of code, generation prototype spend 788.99 ms, the average coding time of students is 19.2 hours, developers need 10.6 hours. LibMS includes 12017 lines of code, generation times of prototype is 1443.39 ms, the average coding time of students is 25.1 hours, and developers only spend 14.3 hours. LoanPS contains 7814 lines of code, the generation time of prototype is 832.78 ms, the average coding time of student is 16.2 hours, and the developers require only 8.4 hours. In average, the case studies contains 8325 lines of code, generation prototype spend \textbf{843.73 ms} less than 1 second, the system operations generations only require \textbf{8.95 ms}, students need \textbf{17.20 hours} and experienced developers require \textbf{9.14 hours}. RM2PT auto-prototyping is much more efficient than manual prototyping (\textbf{\textasciitilde 1 second vs \textasciitilde 9 hours}). Although the experienced developers take less prototyping time than the students, that is still much in-efficient than auto-prototyping approach. Moreover, the manual prototyping usually introduces inconsistency between prototype and requirements because of careless and not understanding of requirement model. That makes more than half of the whole prototyping time to debugging. Furthermore, if we only count the time for fulfillment of system operations, the spending time \textbf{\textasciitilde 9 ms)} is much less than the prototyping (\textbf{\textasciitilde 850 ms}). In short, RM2PT is an efficient and effective approach to generate prototype without introducing inconsistency between the requirements model and prototype. \subsection{Limitation} The case studies demonstrate the effective and efficient of RM2PT for requirements modeling, prototype generation, requirements validation, and evolution. However, it has some limitations. 1) The first one is that 6.91\% system operations cannot be correctly specified or successfully generated without introducing third-party services, but this limitation has been solved by specified the thrid-part service is invoking in OCL expression. That is a significant extension of our previous work. 2) The second limitation that is although the formal specification OCL has short leaning cure than other formal specification, it still needs time for learning to specify the correct contract. We will try to find the better solution to alleviate this problem. 3) The third limitation is the generation performance, and it can be further optimized in the future. \section{Related Work} The related work contains three parts: 1) automated prototype approach, 2) requirements modelers, and 3) the comparison with our previous work. \subsection{Automated Prototype Generation} The following approaches are the most closely related to our work. Umple \cite{Forward2012} can generate a prototype from a class model (conceptual class diagram) and state machine models. However, the state machine only contains abstract states and descriptions of actions (system operations). To generate fully functional prototypes, the actions must be implemented by programming languages. Moreover, invariant checking and requirements validation are not touched. ActionGUI \cite{ActionGUI2014} can generate a multi-tier application from a design model, which includes a data model (specified by ComponentUML \cite{Basin:2006:MDS:1125808.1125810}), a security model (specified by SecurityUML \cite{Basin:2006:MDS:1125808.1125810}) and a GUI model (specified by GUI Modelling Language). Compared with our approach, there are three main differences. ActionGUI a) requires to provide system operation design by using data actions (primitive operations) to specify statements for events (system operations) in GUI model. A statement (the workflow of primitive operations) is either an action, an iteration or a sequence of statements. Our approach only requires providing contracts (pre and post conditions in OCL) to system operations, then the implementation of system operation can be automated generated. b) ActionGUI requires GUI engineer to construct a GUI model through their specific tool manually. Our approach can be automated generate prototype from requirements model without providing any GUI design. c) the generated GUI of our approach is implemented by state-of-arts GUI architecture design, i.e., separated concerns into GUI content (XML) and GUI style (CSS). That makes prototype high reusable by only applying user-friendly styles to the same content. The paper \cite{Elkoutbi2006} proposed an intermediate approach to generate UI prototypes from UML models. It generates state chart diagrams from a design model specified by a class diagram and collaborations diagrams for each use case, and then generate the UI prototype from a use case diagram and the intermediate state chart diagrams. Comparison with our work, we only require a requirements model, which includes a use case diagram, conceptual class diagram (without system operations), system sequence diagrams and the contracts of system operations (only including the interaction between actors and system interface without internal interactions among objects, that required in collaborations diagrams). The generated prototype contains mechanisms for pre-conditions and invariants checking. JEM \cite{PASTOR2001507} can generate an n-tiered prototype from a conceptual model and an execution model. The conceptual model contains a) an object model specified in a class diagram, b) functional models for the attributes of the class and c) dynamic model for each class defined in state chart diagram. Then the prototype can be generated by the derived formal specification OASIS from the conceptual model and the implementation related execution model, which includes the generation templates and details mapping about OASIS to the implementation. Compared with our approach, pre- and post-conditions only contain simple attribute checking and updating (only one attribute involved) that is hard for working on the practical requirements model and prototype generation. SCORES \cite{Homrighausen2002} proposed a semi-automatically approach to generating prototypes from an enhancement of the requirements specification with user interface model in FLUID \cite{Kosters1996}. Requirements specification contains a use case diagram, activities diagrams to each use case, and a class diagram (including operations). User interface model includes a specification for view widgets, their navigation, and selection or manipulations (primitive operations) of the domain objects. It does not include the specification or contract for system operations other than simple manipulations of domain objects. Therefore, the sophisticated system operations cannot be generated such as \textit{borrowBook}, which includes collaborations of primitive operations such as find an object, form a link, update the attribute. Moreover, the class diagram in SCORES already contains the system operations in the activities diagram, stickily speaking, that is a design model. In short, the related works 1) require providing a design model, which contains a class diagram encapsulating system operations, the design or implementation of system operations specified in collaboration diagrams or a programming language. Moreover, SCORES, ActionGUI and JEM require a GUI design for generating prototype user interface. 2) They lack evaluations about the prototype generation, the mechanism to deal with the non-executable elements in the requirements model. 3) Requirements validation and evolution are not touched. The generated prototype does not provide mechanisms to invariants checking and object status observations in run-time for requirements validation and evolution. \subsection{Requirements Modelers} Most UML modeling tools support OCL-based contract and can generate skeleton code for entity classes in the conceptual class model. Moreover, Visual Paradigm (VP) \cite{Paradigm2013} not only supports entity class generation but also supports generating code for primitive operations of entity class such as creating, deleting, modifying, finding the entity object. And the generated entity classes can be automated mapped into tables of relational database thought ORM and the corresponding RESTFul-based web service wrappers could be automatically generated. Eclipse Foundation provides many open source CASE tools and frameworks. For example, Papyrus UML\cite{Lanusse2009} is well developed and widely used open source tool. EMF Forms\footnote{\url{http://www.eclipse.org/ecp/emfforms}} cannot only generate primitive operations (like in VP) but also can generate GUI for validating those operations. CDO\footnote{\url{http://www.eclipse.org/cdo/}} provides open source solutions to support ORM for EMF\footnote{\url{https://eclipse.org/modeling/emf/}} model. Commercial CASE tool Enterprise Architect\footnote{\url{http://www.sparxsystems.com}} supports generate system operations of objects from the presented design model. The study \cite{Kundu2013} proposed sequence integration graph (SIG), which acts as an intermediate to help automatically fulfill system operations from sequence diagram. Morever, if providing design model, MasterCraft \cite{kulkarni2002generating} could generate information system prototype. AndroMDA\footnote{\url{http://andromda.sourceforge.net}} could generate Java EE and .NET system prototype. However, all the current CASE tools can not generate a prototype without providing an explicit design model. USE (UML-based Specification Environment) \cite{gogolla2007use} supports analysts, designers, and developers in executing UML models and checking OCL constraints and thus enables them to employ model-driven techniques for software production. The project of Eclipse OCL\footnote{\url{https://projects.eclipse.org/projects/modeling.mdt.ocl}} provides an OCL parser and evaluator on UML models. Although USE and Eclipse OCL can evaluate the invariants and precondition of operation contracts, they can not generate the implementation of system operation to conform the post-condition. \subsection{Compared with Our Previous Work} Our previous works about Refinement of Component and Object Systems (rCOS) modeler \cite{Liu2005}\cite{Jifeng2006}\cite{Ke2012} and Automated Prototype Generation and Analysis (AutoPA) \cite{Li2008}\cite{Li2010} touch object-oriented modeling and prototype generation. The rCOS supports refinement calculus for both component-based and object-oriented models. It uses first-order logic to specify the contracts of system operations. It focuses on modeling, but can not generate the prototype. AutoPA can generate system operations from the requirements model with OCL contracts to demonstrate the feasibility of our approach. Compared with our previous works \cite{Li2008}\cite{Li2010}, the proposed approach and implemented RM2PT provides: \vspace{.1cm} \noindent 1) \textit{Extensions of transformation rules.} Our previous work only cover a small subset of OCL expression that describes creating an object, adding a link, getting the value of attribute, setting an attribute, removing a link, and deleting an object, but not includes: a) finding an object with a condition such as \textit{any()} and \textit{select()}, b) OCL standard operations such as \textit{size()} and \textit{isEmpty()}, c) the iteration expression \textit{forAll()} for iterating object from a list, d) invoking third-party operations, and e) the \textit{return} expression. In details, we introduce the rules from $R_{1}$ to $R_{3}$ to find the object with a condition through \textit{EntityManager}, which stores all the references of objects. Moreover, the rules from $R_4$ to $R_7$ support finding the objects through the links. The rules from $R_{8}$ to $R_{11}$ support OCL standard operations. The checking of an object exists (or not exists) can be fulfilled by the combination of the rules $R_{8}$ and $R_{13}$ (or $R_{14}$), and checking a link exists that is supported by the composition of the rules $R_4$, $R_5$, and $R_8$. Besides, the uniqueness of an object can be checked through the rule $R_{15}$. The getting and setting an attribute of object is the same as the rules $R_{12}$ and $R_{23}$. The rule of creating an object is refined to two rules, the rule $R_{16}$ is to create an object, and the rule $R_{17}$ is to add the created objects into the system (add the reference to the created object into \textit{EntityManager}). The rule of releasing an object is the same as the rules $R_{18}$. We refine the rules of adding a link to two rules: the first rule $R_{19}$ is adding a link of the one-to-one association, the second rule $R_{21}$ is for the one-to-many association. Likewise, the rules of removing a link is refined to the rules $R_{20}$ and $R_{22}$. More general system operation such as all the objects of a class satisfy a particular constraint are common requirements in a contract (E.g., when time passed 00:00 AM, the attributes of remain days of all the students were equaled to the previous value plus one.). We add the rule $R_{24}$ for iteration expression, the rule $R_{25}$ for the \textit{return} expression, and the rule $R_{26}$ for invoking third-party APIs library. \vspace{.1cm} \noindent 2) \textit{Supporting requirements executable analysis and wrapping the non-executable specification into an interface}. Our previous works face the problem of un-executable elements of the contract of system operation, which cannot be fulfilled by primitive operations, like sorting and filtering. RM2PT provides a mechanism to identify and un-executable parts of contract and wrapper them into an interface, which can be fulfilled by third-party APIs. \vspace{.1cm} \noindent 3) \textit{Requirements validation and evolution through the generated prototypes.} Our previous work does not touch how to use the generated prototypes to requirements validation and evolution. In this paper, we provide mechanisms to observe the state of objects, and pre-condition and invariants checking in the prototype and show how to validate and evolve requirements through the generated prototype from RM2PT. Four case studies from different aspects demonstrate effective and efficient of our proposed approach. \vspace{.1cm} \noindent 4) \textit{Self-contained requirement modeler and OCL parser}. RM2PT does not rely on third-party UML tools and OCL parser, RM2PT self-contains a requirement modeler and an OCL parser with bi-directionally synchronization between graphics and textual requirements models. The graphics model provides the easer-understood visualized notations for communication with customers. Textual requirement model makes developers easily define the contracts of responsibility. Furthermore, by integrating with version control tools such as SVN and Git, RM2PT can support the trackable iteration for evolutionary requirements elicitation. \vspace{.1cm} \noindent 5) \textit{Generated prototypes based on architecture and design patterns under GRASP guidelines and design patterns.} Unlike AutoPA encapsulates all the system operations into conceptual classes, RM2PT separates concerns into a different abstract level. After generating supporting classes related to architecture, RM2PT automatically encapsulate primitive operations into entity classes and system operations into fabricated classes for separating concerns. Furthermore, different responsibilities of holding content and representation are separated through the latest Java GUI framework JavaFX. The generated prototype takes the architecture and design patterns similar to Java EE and .NET enterprise system, which is capable of extending for a practical scenario. \section{Conclusion and Future Work} This paper presents an approach to automated prototype generation from a formal requirements model, and the requirements model can be validated and evolved by the generated prototype. It includes executable analysis of formal specification and designs a set of transformation rules for translating the executable parts of the contract into Java source code. The non-executable parts of contract can be identified and wrapped by an interface, which can be fulfilled by third-party APIs. Four cases studies, which are library management system, ATM, CoCoME and loan processing system, have been investigated, and the experiment result is satisfactory that the \textbf{93\%} of use cases can be generated successfully. The CASE tool: RM2PT and its tutorials are available for the public at GitHub\footnote{\url{http://rm2pt.mydreamy.net}}. In the future, we will improve the current transformation algorithm to cover the more substantial subset of the executable specification. Meanwhile, we will integrate current prototyping tool with our another work on automated translating use case definitions in natural language into their corresponding formal contract in OCL. That will make this work more applicable to software industrial developers. Generally, they can read formal specification, but they have difficulties in writing a formal specification. With the tool support, their task is to confirm whether the translated formal specification is conformance with the natural language requirement description. Furthermore, after a system requirements model is validated by prototyping, we can generate the prototype into its corresponding real system with another developed transformation software tool. Besides, we will investigate how to generate test cases from the OCL specification, so that we can enhance our tool for automated prototyping and testing. Finally, the tool can be used and checked with more case studies, and hopefully, it can benefit the software industry during requirements engineering. \ifCLASSOPTIONcompsoc \section*{Acknowledgments} \else \section*{Acknowledgment} \fi This work was supported by Macau Science and Technology Development Fund (FDCT) (No. 103/2015/A3) and University of Macau (No. MYRG 2017-00141-FST), 1000-Expert Program Grant (No. SWU116007), and National Natural Science Foundation of China (NSFC) (No. 61472779, 61562011, 61672435 and 61732019) \ifCLASSOPTIONcaptionsoff \newpage \fi \bibliographystyle{IEEEtran}
\section{Introduction} Quantum information science promises the realisation of impressive advances in the field of computation and communication, as well as the advent of other novel quantum technologies \cite{nielsen2010quantum}. The variety and potential usefulness of such applications have made quantum information one of the most prolific physics research areas of the last decades. One critical element in accomplishing said progress is the ability to completely and accurately characterize quantum physical processes, a task known as quantum process (or channel) tomography (QPT). In the extensive literature upon the subject, one recognises two major, extreme examples of QPT: standard quantum process tomography (SPT) and ancilla-assisted quantum process tomography (AAPT). In the general case of SPT, an unknown quantum channel $\Lambda$ acting on a $d$-level system (also called a qudit) can be reconstructed through its action on an ensemble of linearly independent input states \cite{nielsen2010quantum, chuang1997prescription, poyatos1997complete}. In particular, a probe is prepared in a fixed set of $d^2$ input states $\{\rho_i\}$, which form a basis for the space of qudit linear operators. Each of the $\rho_i$ states goes through the process $\Lambda$ to be characterized, and the outputs $\Lambda[\rho_i]$ are determined using quantum state tomography \cite{nielsen2010quantum,d2003quantum,bisio2009optimal} (see Figure~\ref{fig:SPT}). \begin{figure}[b] \[ \Qcircuit @C=1em @R=.7em @! R { & \prepareC{\{\rho_{i}\}} & \ustick{A}\qw & \gate{\Lambda}& \measureD{M} } \] \caption{Standard quantum process tomography. To reconstruct the action of a channel $\Lambda$ acting on a $d$-dimensional system $A$, $d^2$ linearly independent input states $\{\rho_i\}$ are needed, with state tomography done on the outputs by means of measurement(s) $M$. Time goes from left to right. Single lines represent quantum systems, and boxes represent operations: a square box has quantum input and quantum output, while a D-shaped (reverse-D-shaped) box has only quantum input (quantum output).} \label{fig:SPT} \end{figure} Once the outputs are known, the evolution under $\Lambda$ of any arbitrary operator can be determined uniquely by linearity , thus characterizing the channel. An alternative tomographic technique is offered by the renowned AAPT \cite{d2001quantum, altepeter2003ancilla, d2003imprinting} which, in contrast to SPT, needs only one single bipartite input state. That this is possible can be seen as a consequence of the correspondence between linear maps and linear operators established by the well-known Choi-Jamio{\l}kowski isomorphism~\cite{choi1975completely,jamiolkowski1972linear}. In general, an ancillary system $B$ is prepared in a correlated state $\rho_{AB}$ with the quantum system subject to the channel to be determined, the probe $A$. Complete information about the channel can be imprinted on the global state by the action of the process on the probe alone, and then extracted by state tomography on the bipartite output state (see Figure~\ref{fig:AAPT}). \begin{figure} \[ \Qcircuit @C=1em @R=.7em @! R { & \multiprepareC{1}{\rho_{AB}} & \ustick{A}\qw & \gate{\Lambda} & \multimeasureD{1}{M}\\ & \pureghost{\rho_{AB}} & \ustick{B}\qw & \qw & \ghost{M} } \] \caption{Ancilla-assisted quantum process tomography. One input state $\rho_{AB}$ suffices, as long as it has Operator Schmidt Rank equal to the square of the input dimension of the channel.} \label{fig:AAPT} \end{figure} An input enabling enabling AAPT is the maximally entangled state $\ket{\Phi}_{AB}=\sum_{i=1}^dd^{-1/2}\ket{i}\otimes\ket{i}$, with the output $\rho_{\Lambda}= (\Lambda\otimes\textup{id})[\proj{\Phi}_{AB}]$ simply being the Choi-Jamio{\l}kowski state isomorphic to $\Lambda$ \cite{choi1975completely,jamiolkowski1972linear,d2001quantum}. However, it was observed \cite{altepeter2003ancilla, d2003imprinting} that the key property for a bipartite input to enable AAPT is that of having maximal Operator Schmidt Rank (OSR; to be defined later), with a refining of this observation being that the channel discrimination power of a bipartite state is dictated by its smallest operator Schmidt coefficient~\cite{caiaffa2018}. It follows that, in principle, also non-entangled but correlated states can be used to perform AAPT. Bipartite states carrying a complete imprinting of a channel acting on one of the two subsystems were defined as \emph{faithful} in Ref.~\cite{d2003imprinting}. Nonetheless, non-faithful states can still be used to obtain substantial albeit partial information on the action of a channel. This observation suggests that the property of being faithful can be associated with a \emph{set} of bipartite states, the latter being faithful when any unknown channel can be fully retrieved from the tomographic reconstruction of the corresponding output states~\cite{d2003imprinting}. Indeed, SPT can be seen as an extreme case of such a situation, where the presence of an ancilla is actually irrelevant, and one just uses a faithful set of probe states. We remark that the correlations present in one or more of the bipartite states of a faithful set can be deemed as effectively assisting process tomography as long as the faithful set comprises less than $d^2$ states. The results in this paper lie between the two archetypical techniques sketched above, and focus on the exploitation of correlations to reduce the number of distinct inputs needed for what we could call in general \emph{correlation-assisted process tomography} (CAPT). More specifically, we focus on the question of whether and how a faithful set can be generated by means of local actions $\{\Gamma_i\}$ on a fixed input state (see Figure~\ref{fig:capt}). \begin{figure}[b] \[ \Qcircuit @C=1em @R=.7em @! R { & \multiprepareC{1}{\rho_{AB}} & \ustick{A}\qw & \gate{\{\Gamma_i\}} & \gate{\Lambda} & \multimeasureD{1}{M}\\ & \pureghost{\rho_{AB}} & \ustick{B}\qw & \qw & \qw & \ghost{M} } \] \caption{Correlation-assisted quantum process tomography. Any bipartite state $\rho_{AB}$ can be used in this scheme. The presence of correlations in the state may substantially reduce the number of known channels $\{\Gamma_i\}$ that need to be applied so that $\{\Gamma_{i,A}[\rho_{AB}]\}$ is a faithful set. Standard process tomography and ancilla-assisted process tomography are extreme cases of this more general scenario.} \label{fig:capt} \end{figure} In the case where there is no ancilla (or, if there is an ancilla, where there are no probe-ancilla correlations), a local action is not very different from simply considering $d^2$ inputs, but one may need strictly less than $d^2$ local operations on the input if correlations are present between probe and ancilla. That is, our results may be interpreted as an interpolation between the use of fully uncorrelated or fully correlated (that is, having maximum OSR) input states. We show in general that a faithful set can always be generated via $\left\lceil\frac{d^2}{\textup{OSR}(\rho_{AB})}\right\rceil$ local transformations on a \emph{fixed bipartite state}. Notice that this is optimal, as it is clearly impossible to generate a faithful set with less local operations. We also consider the case where such local transformations are constrained to be unitary. For pure fixed states, we find that such a constraint does not change the result: any pure bipartite state of Schmidt rank $k$ (hence with OSR equal to $k^2$) can be used to generate a faithful set with $\left\lceil\frac{d^2}{k^2}\right\rceil$ unitaries. For mixed states, the constraint can actually be limiting: we exhibit a class of qudit-qudit states with OSR equal to two but such that one still needs $d^2$ local unitaries to generate a faithful set. We conjecture that in general one may need $\left\lceil\frac{d^2}{\textup{OSR}(\rho_{AB})-1}\right\rceil$ local unitaries to generate a faithful set. On the other hand, the mixed-state case can display a highly ``efficient'' (in terms of local unitaries employed) generation of a faithful set; specifically, we exhibit a family of qudit-qudit states with OSR $\approx d^2/2$ where only two unitaries are needed to achieve faithfulness; notice that such a case is impossible in the pure-state case. Finally, by exploiting the relation between $SO(3)$ and $SU(2)$ (that is, in a sense, the Bloch ball qubit representation), we fully characterize the qubit-qudit case for qubit channels, once more highlighting the importance of discord in the issue of correlation-assisted channel tomography/discrimination: a two-qubit state gives rise to a faithful set with at most two local unitaries if an only if it exhibits discord on the probe side. \noindent \section{Notation and preliminaries}% We will focus on finite-dimensional systems. Any Hilbert space $\mathcal{H}$ will be equivalent to $\mathbb{C}^d$, for some dimension $d$. We will indicate by $\mathcal{L}(\mathcal{H})$, the set of linear operators $L$ (equivalent to matrices) on $\mathcal{H}$. The dimension of a system $X$ with Hilbert space $\mathcal{H}_X$ will be indicated by $d_X$. A quantum state on $\mathcal{H}$ is a density operator $\rho$ belonging to the convex subset $\mathcal{D}(\mathcal{H})\subset \mathcal{L}(\mathcal{H})$ of positive semidefinite operators with unit trace. The trace operation is indicated by $\Tr$, while we denote by $\Tr_X$ the partial trace on system $X$. We write $\rho_X$ for the (reduced) state of system $X$. A bipartite state $\rho_{AB}$ is unentangled (or separable) if it is the convex combination of product (or uncorrelated) states~\cite{revent}, that is, if $\rho_{AB} = \sum_i p_i \rho^A_i \otimes \rho^B_i$, with $\{p_i\}$ a probability distribution. A state is considered to be entangled if and only if it is not separable. Any physical evolution (or quantum process) affecting a quantum system is described in terms of quantum channels~\cite{nielsen2010quantum}. A quantum channel from $X$ to $Y$ is a completely-positive trace-preserving linear map $\Lambda$ from $\mathcal{L}(\mathcal{H}_X)$ to $\mathcal{L}(\mathcal{H}_Y)$. We will also make use of some specific norms on operators, in particular we will use (some of) the $p$-norms \[ \|L\|_p = (\sum_i \sigma_i(L)^p)^{1/p}, \] where the sum is over the singular values $\sigma_i(L)$ of $L$. The trace norm $\|L\|_1=\sum_i \sigma_i(L)$ corresponds to $p=1$; the Frobenius norm $\|L\|_p = \sqrt{\sum_i \sigma_i(L)^2}$ corresponds to $p=2$; finally, for $p\rightarrow \infty$, we have the operator norm $\|L\|_\infty=\max_i \sigma_i(L)$. For simplicity, we will typically consider bipartite states $\rho_{AB}$ with the two subsystems of the same dimension, and we define $d\vcentcolon= d_A=d_B$, keeping in mind that the results and terminology (e.g., ``maximal OSR'') presented in this paper are generally valid as long as $d_A\leq d_B$. \section{Operator Schmidt decomposition} The state vector $\ket{\psi}_{AB}\in \mathcal{H}_A\otimes \mathcal{H}_B$ of a bipartite system admits a Schmidt decomposition~\cite{nielsen2010quantum} $\ket{\psi}_{AB} = \sum_{i=1}^{d_\textup{min}} \sqrt{p_i}\ket{a_i}_A\otimes\ket{b_i}_B$, with $d_\textup{min}=\min\{d_A,d_B\}$ and $\{p_i\}$ positive numbers that sum up to 1, thus constituting a probability distribution. We will take $\{p_i\}$ to be ordered without loss of generality, that is, we will assume $p_1\geq p_2 \geq\ldots$. The sets of orthonormal vectors $\{\ket{a_i}\}$ and $\{\ket{b_i}\}$ are some special and $\ket{\psi}$-dependent orthonormal bases for $\mathcal{H}_A$ and $\mathcal{H}_B$, respectively. We denote by $\textup{SR}(\psi)$ the Schmidt rank of $\ket{\psi}_{AB}$; it is the number of non-zero $p_i$'s, and satisfies $\textup{SR}(\psi)\leq d_{\min}$. By considering a bipartite state $\rho_{AB}$ as a vector in $\mathcal{L}(\mathcal{H}_A\otimes\mathcal{H}_B)$, we arrive at the Operator Schmidt Decomposition (see~\cite{aniello2009relation,lupo2008bipartite} and references therein) \begin{equation} \label{eq:OSD} \rho_{AB} = \sum_{i=1}^{\textup{OSR}(\rho)}r_i A_i \otimes B_i. \end{equation} We denote by $\textup{OSR}(\rho)$ the Operator Schmidt Rank (OSR) of $\rho$; this is the number of non-zero Operator Schmidt Coefficients (OSCs) $r_i$, which are taken to be positive. The sets of operators $\{A_i\}_{i=1}^{d_A^2}$ and $\{B_i\}_{i=1}^{d_B^2}$ form ($\rho$-dependent) orthonormal bases for the spaces $\mathcal{L}(\mathcal{H}_A)$ and $\mathcal{L}(\mathcal{H}_B)$, respectively. We remark that, since $\rho_{AB}$ is Hermitian, the two orthonormal operator bases in~\eqref{eq:OSD} can be (but need not be) taken to be composed of Hermitian operators. The OSCs are the singular values of the matrix $[C_{ij}(\rho_{AB})]_{ij}$, with $C_{ij}(\rho_{AB}):=\Tr( F_i^\dagger\otimes G_j^\dagger \rho_{AB})$. Such a matrix is sometimes referred to as \emph{correlation matrix}. The operators $\{F_i\}$ and $\{G_j\}$ are arbitrary local orthonormal bases for the respective operator spaces. As in the case of the Schmidt decomposition for vector states, without loss of generality we can take the OSCs to be ordered as $r_1 \geq r_2 \geq \ldots $; Such coefficients satisfy $\sum_ir_i^2 = \Tr(\rho^2)$. One immediately convinces oneself that $\textup{OSR}(\rho_{AB})\leq d_{\min}^2$, as the vector space $\mathcal{L}(\mathcal{H}_A)$ has dimension $d_A^2$ (similarly for $\mathcal{L}(\mathcal{H}_B)$). The SD of a vector state $\ket{\psi}_{AB}$ and the OSD of the corresponding density matrix $\proj{\psi}_{AB}$ are very much related: one has $r_i=\sqrt{p_k}\sqrt{p_l}$, $A_i = \projj{a_k}{a_l}$, and $B_i = \projj{b_k}{b_l}$, for $i=(k,l)$ a multi-index, so that $\textup{OSR}(\proj{\psi}_{AB})=\textup{SR}(\psi_{AB})^2$. \section{Operator Schmidt Decomposition and ancilla-assisted process tomography} As anticipated, AAPT requires the preparation of a bipartite system in a single bipartite state $\rho_{AB}$. One subsystem (the probe) is sent through the channel $\Lambda$ to be characterized. Using \reff{eq:OSD}, the output $\rho_{\Lambda}\vcentcolon=(\Lambda\otimes\textup{id})[\rho_{AB}]$ reads \begin{equation}\label{output} \rho_{\Lambda}=\sum_{l=1}^{OSR(\rho_{AB})}r_l\Lambda[A_l]\otimes B_l. \end{equation} Then, by reconstructing $\rho_\Lambda$, one recovers the action of the channel on the basis element $A_l$ via $\Lambda[A_l]=\Tr_B((\mathbb{1}\otimes B_l^\dag)\rho_{\Lambda})/r_l$ (for $r_l>0$). It follows that inputs with maximal OSR enable complete characterization of the channel, since its action on a complete operator basis of $\mathcal{L}(\mathcal{H}_A)$ can be reconstructed \cite{d2003imprinting,altepeter2003ancilla}. It is clear that input states defined as faithful are states with maximal OSR, more precisely with OSR equal to $d_A^2$. Correspondingly, a set of (potentially unfaithful, when considered individually) bipartite states $\{\rho_{AB,i}\}$ is called faithful if the local operators $\{A_{l,i}\}_{l=1}^{\textup{OSR}(\rho_{AB,i})}$ of $\textup{OSD}(\rho_{AB,i})$, when considered together, generate the whole $\mathcal{L}(\mathcal{H}_A)$, i.e., if $\text{span}(\{A_{l,i}\}_{l,i})=\mathcal{L}(\mathcal{H}_A)$. \section{Generating a faithful set of inputs with general local channels} The core idea of this work is to show that the correlations of a fixed bipartite state, of whatever degree, can in principle be exploited to allow ``more efficient'' process tomography. Such correlations can be measured through the OSR, which obeys very general requirements that any meaningful measure of total correlations must satisfy. Indeed, the OSR is minimal for and only for non correlated (product) states, and it is monotone under local channels. Not relying on correlations, like in SPT, is the same as considering minimal OSR---that is, OSR equal to 1---for the inputs. On the other hand, fully relying on correlations, like in AAPT, means requiring maximal OSR for a single bipartite input. These considerations legitimate the intuition that intermediate values for the OSR should be consistent with the use of an intermediate number of inputs. In this section we analyze how we can achieve the condition $\text{span}(\{A_{l,i}\})=\mathcal{L}(\mathcal{H}_A)$ indicated at the end of the last section, where each set $\{A_{l,i}\}_l$ is a local orthonormal basis for $(\Gamma_i\otimes\textup{id})[\rho_{AB}]$, for $\Gamma_i$ the local operations applied on the probe before it is subject to the channel $\Lambda$ (see Figure \ref{fig:capt}). Let us first remark why channel tomography is certainly possible in this setup. The reason is simple: each channel $\Gamma_i$ may simply be taken to have constant output corresponding to one of the input states $\rho_A^i$ used in standard channel tomography (Figure \ref{fig:SPT}). With this ``trivial'' strategy, we do not make use of correlations at all, but we certainly achieve the task at hand. Having estalished this, let us move to the issue of ``optimizing'' the $\Gamma_i$'s, at least with respect to their number. Let $\{A_l\}_{l=1}^{d^2}$ be a Hermitian local orthonormal basis for the operator Schmidt decomposition for $\rho_{AB}$, comprising the $\textup{OSR}(\rho_{AB})$ elements corresponding to non-zero OSCs. It is clear that $\operatorname{span}(\{A_{l,i}\}_l) = \operatorname{span}(\{\Gamma_i[A_{l}]\}_l)$, so that $\text{span}(\{A_{l,i}\}_{l,i}) = \operatorname{span}(\{\Gamma_i[A_{l}]\}_{l,i})$. Thus, our goal is the following: given $\{A_l\}_{l=1}^{\textup{OSR}(\rho_{AB})}$, find a (minimal) way of choosing the local maps $\Gamma_i$ so that $\operatorname{span}(\{\Gamma_i[A_{l}]\}_{l,i}) = \mathcal{L}(\mathcal{H}_A)$. By minimal, we mean that we want to identify the smallest possible number of local channels $\Gamma_i$ that are needed to achieve such a condition. In the following we provide a construction to achieve this. Let us consider the following family of maps, \begin{equation}\label{eq:tp_cp} \Gamma_i[X]\vcentcolon= (1-\epsilon)\Tr(X)\frac{\mathbb{1}}{d}+\epsilon\, \tilde\Gamma_i[X], \end{equation} which are each a convex combination (for $0\leq \epsilon \leq1$) of the totally depolarizing channel $X\mapsto \Tr(X)\frac{\mathbb{1}}{d}$ and of \begin{equation} \begin{split} \tilde\Gamma_i[X]&\vcentcolon=\sum_j\Tr(A_jX)A_{\gamma_{j,i}} \\ &\quad+[\Tr(X) -\sum_{j}\Tr(A_jX)\Tr(A_{\gamma_{j,i}})]\frac{\mathbb{1}}{d}. \end{split} \label{eq:tp_ncp} \end{equation} Notice that $\tilde\Gamma_i$ is not necessarily a channel, but it is a linear map that is trace preserving by construction. Here we denote $\gamma_{j,i}\vcentcolon= j\oplus (i\cdot \textup{OSR}(\rho_{AB}))$, and the $A_i$'s form a local orthonormal basis that is a superset of the local operators of the OSD of $\rho_{AB}$, as in \reff{eq:OSD}. The symbol $\oplus$ indicates addition modulo $d^2$, and we let $i=1,2,3\ldots$. By construction, the maps $\Gamma_i[X]$ are trace preserving, and, for $0<\epsilon<1$ small enough, completely positive. This is because, within the set of linear trace-preserving maps, there is a ball of completely positive maps around the totally depolarizing channel. Notice that, in principle, we could consider any other channel with full-rank fixed output, at the ``cost'' of considering some other $\epsilon$. Such full-rank fixed output (as well as $\epsilon$) could even be made to depend on $i$. It is easy to recognize the action of $\Gamma_i$ on the generic basis element $A_n$: \begin{equation} \Gamma_i[A_n]= \big(\Tr(A_n-\epsilon A_{\gamma_{n,i}})\big)\frac{\mathbb{1}}{d}+\epsilon\, A_{\gamma_{n,i}}, \end{equation} i.e. the $i-$th map, acting upon the $n$-th element of the local basis, returns a liner combination of the basis element indexed as $n\oplus (i\cdot \textup{OSR}(\rho_{AB}))$ and of the identity. To make the action of the channels clearer, let us consider the action of, e.g., $\Gamma_1$. The latter would map the set $\{A_n\}_{n=1}^{\textup{OSR}(\rho_{AB})}$ to $\{ \big( \Tr(A_n-\epsilon A_{n\oplus \textup{OSR}(\rho_{AB})}) \big) \frac{\mathbb{1}}{d} + \epsilon\, A_{n\oplus \textup{OSR}(\rho_{AB})} \}_{n=1}^{\textup{OSR}(\rho_{AB})}. $ Thus, it should be clear that---up to the detail of whether we need to choose a fixed state different from the maximally mixed one in \eqref{eq:tp_cp} and \eqref{eq:tp_ncp} in order to certainly obtain a set whose elements are all linearly independent from the other generated sets---given an incomplete set of basis elements $\{A_n\}_{n=1}^{\textup{OSR}(\rho_{AB})}$, we are able to obtain operators spanning the same space as the remaining $d_A^2-\textup{OSR}(\rho_{AB})$ ones through the application of $\lceil\frac{d_A^2}{\textup{OSR}(\rho_{AB})}\rceil-1$ channels. This leads directly to the following theorem. \begin{Theorem} Let $\rho_{AB}$ be a bipartite state with $OSR(\rho_{AB})=k$. Then there is a set of quantum channels $\Gamma_i$, with $i=1,\ldots,\lceil\frac{d_A^2}{k}\rceil$, such that $\{(\Gamma_i\otimes\textup{id})[\rho_{AB}]\}_i$ is faithful. Without loss of generality, one of the channels can be taken to be the identity channel. \end{Theorem} \section{Generating a faithful set of inputs with unitary local channels} In this section we consider constraining the local channels $\Gamma_i$ that act on the probe in Fig.~\ref{fig:capt} to be unitary. The question we address is that of determining how many unitary rotations $U_i$ are needed in order to obtain a faithful set of input states $\{U_i\otimes\openone\rho_{AB}U_i^\dagger\otimes\openone\}_i$. As discussed in the case of general local operations, this corresponds to finding out how many unitary rotations are needed so that $\{U_iA_lU_i^\dagger\}_{i,l}$ spans the entire space $\mathcal{L}(\mathcal{H}_A)$, where $\{A_l\}_l$ is a set of orthonormal local OSD operators corresponding to non-zero operator Schmidt coefficients. We remark that in the case where we impose the constraint that the channels be unitary, the fact that process tomography is possible at all is not immediate. Indeed, it is not anymore the case that this is possible for \emph{all} input states $\rho_{AB}$. Nonetheless, we prove that it is possible for all states that are not of the form $\frac{{\openone}_A}{d}\otimes\rho_B$: notice that the latter states are not only uncorrelated, but such that the state of the probe $A$ is maximally mixed. Notice also that our result means that any form of correlations is enough to make process tomography by local unitaries possible. Let us first establish this result. \subsection{Process tomography via local unitary rotation of almost any input} It is convenient to recall the definition of frame \cite{duffin1952class}. Such a concept is generally defined for families of vectors in inner product spaces. In our framework we exploit the inner product structure of $\mathcal{L}(\mathcal{H})$ and define a frame as a collection $\{P_k\}$ of operators such that there are real numbers $0<a\leq b<\infty$ satisfying \begin{equation}\label{fc} a\|X\|_2^2\leq\sum_k|\Tr(P_k X)|^2\leq b\|X\|_2^2 \end{equation} for any $X\in \mathcal{L}(\mathcal{H})$. A frame generalizes the notion of basis. Notice in particular that, if the frame is actually an orthonormal basis, that is, if $\Tr(P_k^\dagger P_l)=\delta_{kl}$, then the frame condition \eqref{fc} is satisfied with $a=b=1$. In finite dimensions, a finite collection $\{P_k\}$ is a frame for $\mathcal{L}(\mathcal{H})$ if and only if it is a spanning set for $\mathcal{L}(\mathcal{H})$, while an infinite collection $\{P_k\}$, even when a spanning set, may not constitute a frame, as there might not be a finite $b$ that satisfies \eqref{fc}. The lower bound in \eqref{fc}, for $a>0$, ensures that $X$ can be reconstructed from the values $\Tr(P_k X)$. It should be clear that, given a frame, one can always consider a subset of the elements of the frame, so that such subset forms a basis, that is, a spanning set of linearly independent operators. What we will prove is that it is possible to choose $d^2$ unitaries $\{U_i\}_{i=1}^{d^2}$ (with $U_1=\openone$ without loss of generality) so that $\{U_i\rho U_i^\dagger\}_i$ is a frame and a basis for the space of operators of the input ancilla, initially prepared in the state $\rho$, as long as $\rho\not\propto \openone$. To prove this, we will need the notion of twirling, or twirl operation \cite{werner1989quantum}. The latter is the linear projection $\mathcal{T}$ on bipartite operators $Y\in\mathcal{L}(\mathbb{C}^d\otimes\mathbb{C}^d)$ defined as \begin{equation}\label{twirl} \mathcal{T}(Y)=\int_U (U\otimes U)Y(U^{\dagger}\otimes U^{\dagger})dU, \end{equation} where the integral is taken with respect to the Haar measure of the unitary group on $\mathbb{C}^d$. Since any operator commuting with all unitaries of the form $U\otimes U$ can be written as a linear combination of $\mathbb{1}$ and $V$ (where $V$ is the flip operator, defined implicitly by the its action $V\ket{\psi}\otimes\ket{\varphi}=\ket{\varphi}\otimes\ket{\psi}$, for all $\ket{\psi},\ket{\varphi}\in \mathbb{C}^d$), it follows that \cite{werner1989quantum} \[ \mathcal{T}(Y)=\alpha(Y)\mathbb{1}+\beta(Y) V. \] The coefficients $\alpha(X)$ and $\beta(X)$ are fixed by the conditions \begin{align} \Tr(\mathcal{T}(Y)) &= \Tr(Y) \\ \Tr(\mathcal{T}(Y)V) &= \Tr(YV), \end{align} solved by \begin{align} \label{eq:alphabeta} \alpha(Y)&=\frac{d\Tr(Y)-\Tr(YV)}{d^3-d}, \\ \beta(Y)&=\frac{d\Tr(YV)-\Tr(Y)}{d^3-d}. \end{align} We will use the fact that the twirling can be approximated by a unitary $2$-design, that is by a finite set of $n$ unitaries $\{U_i\}_{i=1}^n$ such that \begin{equation}\label{twirldesign} \mathcal{T}(Y)= \frac{1}{n}\sum_{i=1}^n U_i\otimes U_i Y U_i^{\dagger}\otimes U_i^{\dagger}. \end{equation} We will obtain our frame by taking $d^2$ of such unitaries. Let $\{U_i\}_{i=1}^n$ be a unitary $2$-design (without loss of generality, one of the unitaries can be taken to be the identity). Let us check the frame conditions \eqref{fc} of $\{U_iA U_i^\dagger\}_{i=1}^n$, for an arbitrary $A\in\mathcal{L}(\mathbb{C}^d)$. One has \begin{align} &\quad\sum_{i=1}^{n}|\Tr(U_iAU_i^\dag X)|^2 \\ &=\sum_{i=1}^{n}\Tr(U_iAU_i^\dag X)\Tr(U_iA^\dagger U_i^\dag X^\dag)\nonumber\\ &=\sum_{i=1}^{n}\Tr\Big((U_i\otimes U_i)(A\otimes A^\dag)(U_i^\dag\otimes U_i^\dag) (X\otimes X^\dag)\Big)\nonumber\\ &\propto \Tr(\mathcal{T}(A\otimes A^\dag) X\otimes X^\dag)\nonumber \\ &=\Tr((\alpha(A\otimes A^\dagger)\mathbb{1}+\beta(A\otimes A^\dagger) V) X\otimes X^\dag)\nonumber\\ &=\alpha(A\otimes A^\dagger)\Tr( X\otimes X^\dag)+\beta(A\otimes A^\dagger)\Tr(VX\otimes X^\dag)\nonumber\\ &=\alpha(A\otimes A^\dagger)|\Tr(X)|^2+\beta(A\otimes A^\dagger)\|X\|_2^2\\ \end{align} where $\alpha(A\otimes A^\dagger)$ and $\beta(A\otimes A^\dagger)$ are given by Eqs. \eqref{eq:alphabeta} applied to the case $Y=A\otimes A^\dagger$, so that \begin{align} \alpha(A\otimes A^\dagger)&=\frac{d|\Tr(A)|^2-\|A\|_2^2}{d^3-d}, \\ \beta(A\otimes A^\dagger)&=\frac{d\|A\|_2^2-|\Tr(A)|^2}{d^3-d}. \end{align} Working in finite dimensions, we see that the frame condition \eqref{fc} is achieved as long as $\alpha(A\otimes A^\dagger)>0$, $\beta(A\otimes A^\dagger)>0$, which means as long as \begin{equation} d|\Tr(A)|^2\geq\|A\|_2^2 \label{eq:cond1} \end{equation} and \begin{equation} |\Tr(A)|^2<d\|A\|_2^2. \label{eq:cond2} \end{equation} Let us assume that $A$ is a state, specifically the reduced state $\rho_A$ of the probe. Then, the first inequality is automatically satisfied. Moreover, the Cauchy-Schwarz inequality implies that $|\Tr(A)|^2\leq |\Tr(\openone)|\|A\|_2^2=d|\|A\|_2^2$, with equality if and only if $A\propto \openone$. Having assumed that that $A$ is the state $\rho_A$, this is the condition that $\rho_A$ is not maximally mixed. Thus, we have found that, independently of the presence of an ancilla, as long as the reduced state $\rho_A$ of the probe is not maximally mixed, we can find $d^2$ unitaries, one of which is the identity, such that $\{U_i\rho_A U_i^\dagger\}_{i=1}^{d^2}$ is a tomographically faithful set. We can extend this result to the case where there are non-vanishing correlations. The operator $A$ for which we want that $\{U_iA U_i^\dagger\}_{i=1}^{d^2}$ be a tomographically complete set can be taken to be any linear combination of the hermitian operator Schmidt operators $\{A_l\}_l$ corresponding to non-zero operator Schmidt coefficients (one example being the reduced state $\rho_A$). Suppose $\rho_{AB}$ is not product. Then there are at least two terms in its OSD, and at least one between one of the $A_i's$ and the reduced state $\rho_A$ is not proportional to the identity; we can then consider as $A$ in the above construction of the frame some linear combination of the latter two operators that respects conditions \eqref{eq:cond1}-\eqref{eq:cond2}. On the other hand, since a state of the form $\frac{{\openone}_A}{d}\otimes\rho_B$ is invariant under local unitary transformation on $A$, we have proven our statement: \begin{Theorem}\label{th:OSR1} For all non product bipartite states and for all product states $\rho_{AB}$ such that $\rho_{A}\neq\mathbb{1}_A/d$, there always exist $d^2$ unitary operators $U_i\in SU(d)$ such that the set $\{(U_i\otimes\textup{id})\rho_{AB}(U_i\otimes\textup{id})^\dag\}_{i=1}^{d^2}$ is faithful. \end{Theorem} \noindent \subsection{Pure probe-ancilla state} For pure states we are able to find the optimal number of local unitaries needed to construct a faithful set starting from a fixed pure state of Schmidt rank $k$: \begin{equation}\label{eq:PS} \proj{\psi}_{AB}=\sum_{i,j=1}^k\sqrt{p_ip_j}\projj{i}{j}_A\otimes\projj{i}{j}_B. \end{equation} \begin{Theorem}\label{th:PS} Let $\proj{\psi}_{AB}$ be as in \reff{eq:PS}. Then, there are $n\vcentcolon=\left\lceil\frac{d}{k}\right\rceil^2$ local unitaries $U_i$ such that the set given by $\{(U_i\otimes\openone)\proj{\psi}_{AB}(U_i\otimes\openone)^\dag\}_{i=0}^{n-1}$, with $U_0=\openone$, is faithful. \end{Theorem} \begin{proof} Let $\ket{\psi_0}=\ket{\psi}$. State tomography of the output $(\Lambda\otimes\textup{id})\proj{\psi_{0}}$ determines the channel $\Lambda$ partially, i.e., its action on $\{\projj{i}{j}\}$ only for $i,j=1,\ldots,k$. To obtain the image under $\Lambda$ of the remaining $\projj{i}{j}$ elements, it is convenient to consider the case when $k$ divides $d$. We will start by analyzing how it is possible to reconstruct the action of $\Lambda$ on all of $\{\projj{i}{j}\}$, for $i,j=1,\ldots,2k$. Let us define the set of operators \begin{align} A_{ij}&=\projj{i}{j},\\ B_{ij}&=\projj{i+k}{j+k},\\ C_{ij}&=\projj{i+k}{j},\\ D_{ij}&=\projj{i}{j+k}, \end{align} for $i,j=1,\ldots,k$, and where sums within kets should be in general understood modulus $d$. Also, let us introduce unitary operators whose action restricted to the vectors $\ket{n}$, for $n=1,\ldots,k$, is given by \begin{align*} &X\ket{n}=\ket{n+k},\\ &U\ket{n}=2^{-1/2}(\ket{n}+\ket{n+k}),\\ &V\ket{n}=2^{-1/2}(\ket{n}+i\ket{n+k}).\\ \end{align*} Acting locally on $\proj{\psi}$, such operators produce the following states \begin{align*} \proj{\psi_1}\vcentcolon=&(X\otimes\mathbb{1}) \proj{\psi} (X\otimes\mathbb{1})^\dag\\ \proj{\psi_2}\vcentcolon=&(U\otimes\mathbb{1}) \proj{\psi} (U\otimes\mathbb{1})^\dag\\ \proj{\psi_3}\vcentcolon=&(V\otimes\mathbb{1}) \proj{\psi} (V\otimes\mathbb{1})^\dag. \end{align*} Define $\Lambda[Y]=[\Lambda[Y_{ij}]]_{i,j=1}^{k}$, for $Y=A,B,C,D$. Then $\Lambda[A]$ is reconstructed through tomography of $(\Lambda\otimes\textup{id} )\proj{\psi_{0}}$ (as already noticed), while $\Lambda[B]$ is obtained from $(\Lambda\otimes\textup{id} )\proj{\psi_1}$. On the other hand, $\Lambda[C]$ and $\Lambda[D]$ can be reconstructed by measuring the four outputs (i.e. $(\Lambda\otimes\textup{id} )\proj{\psi_{l}}$ for $l=0,\ldots,3$) and then combining the results. To be more precise, since \begin{align*} C_{ij} &=UA_{ij}U^\dag+iVA_{ij}V^\dag\\ &\quad-\frac{1+i}{2}(A_{ij}+XA_{ij}X^\dag)\\ D_{ij}&=iVA_{ij}V^\dag-UA_{ij}U^\dag\\ &\quad-\frac{i-1}{2}(A_{ij}+XA_{ij}X^\dag), \end{align*} \noindent linearity implies \begin{align*} \Lambda[C_{ij}]&=\Lambda[UA_{ij}U^\dag]+i\Lambda[VA_{ij}V^\dag]\\ &\quad-\frac{1+i}{2}(\Lambda[A_{ij}]+\Lambda[XA_{ij}X^\dag])\\ \Lambda[D_{ij}]&=i\Lambda[VA_{ij}V^\dag]-\Lambda[UA_{ij}U^\dag]\\ &\quad-\frac{i-1}{2}(\Lambda[A_{ij}]+\Lambda[XA_{ij}X^\dag]). \end{align*} Thus, we see that we have reconstructed $\Lambda[\projj{i}{j}]$ for $i,j=1,\ldots,2k$ with four local unitaries. Information on the remaining $\Lambda[\projj{i}{j}]$ can be reconstructed similarly. The theorem follows by reiterating this procedure, until recovering the action of $\Lambda$ on all the blocks. More explicitly, it is possible to reconstruct $\Lambda[\projj{i}{j}]$ for $i,j\in \{1+p\cdot k,\dots, k+p\cdot k\}$ and $p=0,\ldots,d/k -1$ by considering the action of $p$-labelled $d/k$ unitaries (one being the identity) each performing one of the transformations \begin{align*} &\ket{n}\mapsto\ket{n+p\cdot k}.\\ \end{align*} Once these `on-diagonal blocks' have been reconstructed, it is then possible to further reconstruct the `off-diagonal blocks' $\Lambda[\projj{i}{j}]$, for $i\in \{1+p\cdot k,\dots, k+p\cdot k\}$ and $j\in \{1+q\cdot k,\dots, k+q\cdot k\}$, $p\neq q$ by the use of $(d/k(d/k-1))/2$ pairs of unitaries that perform the transformations \begin{align*} &\ket{n}=2^{-1/2}(\ket{n+p\cdot k}+\ket{n+q\cdot k}),\\ &\ket{n}=2^{-1/2}(\ket{n+p\cdot k}+i\ket{n+q\cdot k}).\\ \end{align*} This gives a total of $d/k + 2\cdot(d/k(d/k-1))/2 = (d/k)^2$ unitaries. If $k$ does not divide exactly $d$, then one needs to consider an additional set of unitaries, but obviously the cost (in terms of unitaries) cannot be larger than in the case where we imagine the $A$ system embedded in a $d'$-dimensional system, with $d'=\lceil \frac{d}{k} \rceil\cdot k$. \end{proof} \noindent In the light of the last theorem we see that the higher the correlations (in terms of OSR) of the fixed pure state, the less $U_i$ are required. As expected, when the fixed pure state has maximal OSR, one recovers completely the AAPT scenario. For pure state with $\textup{OSR}=1$, the number of experimental settings to perform channel tomography is again the one of SPT. As a final remark we observe, by looking at the proof of Theorem \ref{th:PS}, that one can derive the specific form of a particular set of $U_i$, besides establishing their existence. Contrary to the pure state case, for the case where the fixed state is mixed we have not derived a formula which directly links the OSR of the input to the number of unitaries needed to reach faithfulness. However, in the following we give specific examples that show that also when the fixed state is mixed, the presence of correlations dramatically reduces the number of local unitaries required to perform channel tomography. \subsection{Mixed probe-ancilla state: qubit-qudit inputs} The first example involves a qubit-qudit system, for qubit channel tomography. We show that reducing the cardinality of the faithful set created by local unitaries on the qubit depends strongly on the quantumness of correlations on the qubit side. Before going into the details it is convenient to recall that a bipartite state is called classical on $A$ if it can be expressed as $\rho_{AB} = \sum_i p_i \proj{a_i}_A\otimes \rho_i^B$, for some orthonormal basis $\{\ket{a_i}\}$. States that are not classical on $A$ are said to have non-zero quantum discord~\cite{henderson2001classical,ollivier2001quantum,RevModPhys.84.1655}. Also, we will make use of the following Lemma, in which we use the notion of Bloch vector for a generic Hermitian operator $L=L^\dagger$, given by $\vec{l}=(l_1,l_2,l_3)$, with $l_i=\Tr(\sigma_i L)$ and $\sigma_i$, $i=1,2,3$, the Pauli operators. \begin{Lemma} \label{lem:commuting} Consider Hermitian operators $A,B\in\mathcal{L}(\mathbb{C}^2)$. Then, $A$ and $B$ commute if and only if their Bloch vectors are proportional. \end{Lemma} \begin{proof} Let $\sigma_0=\mathbb{1}$ and denote $a_0=\Tr(A)$, $b_0=\Tr(B)$. Let also $\vec{a}=(a_1,a_2,a_3)$ and $\vec{b}=(b_1,b_2,b_3)$ be the Bloch vectors of $A$ and $B$, respectively, so that $A=\frac{1}{2}\sum_{i=0}^3a_i\sigma_i$ and $B=\frac{1}{2}\sum_{i=0}^3b_i\sigma_i$. Observe that \begin{align*} [A,B] &=\left[\frac{1}{2}\sum_{i=0}^3a_i\sigma_i,\frac{1}{2}\sum_{i=0}^3b_i\sigma_i\right]\\ &=\frac{1}{4}\sum_{i,j=0}^3 a_ib_j \left[\sigma_i,\sigma_j\right]\\ &=\frac{1}{4}\sum_{i,j,k=1}^3a_ib_j\, 2 i\epsilon_{ijk}\sigma_k\\ &=\frac{i}{2}\sum_{k=1}^3\left(\sum_{i,j=1}^3a_ib_j\epsilon_{ijk}\right)\sigma_k\\ &=\frac{i}{2}(\vec{a}\times\vec{b})\cdot\vec{\sigma} \end{align*} where we used the Levi-Civita symbol $\epsilon_{ijk}$, and $\times$ indicates the standard cross product between three-dimensional vectors. \noindent Since $\sigma_1,\sigma_2,\sigma_3$ are linearly independent, the expression in the last line above is zero if and only if the cross product $\vec{a}\times\vec{b}$ vanishes, which happens if and only if $\vec{a}=\lambda\vec{b}$, with $\lambda\in\mathbb{R}$. \end{proof} We are now in the position to state the following. \begin{Theorem} Let $A$ be a qubit. Then, $\rho_{AB}$ has quantum discord on $A$ if and only if $\rho_{AB}$ allows correlation-assisted process tomography on $A$ with at most two unitary rotations. \end{Theorem} \begin{proof} We recall that a qubit-qudit state has zero discord on the qubit side $A$ if and only if $\rho_{AB}=p\proj{a_1}_A\otimes\rho_1^B+(1-p)\proj{a_2}_A\otimes\rho_2^B$, with $\{\ket{a_1},\ket{a_2}\}$ some orthonormal basis for $A$. While this is not necessarily the operator Schmidt decomposition, it is clear that the state only allows to reconstruct the action of a channel $\Lambda$ on $\operatorname{span}(\{\proj{a_1},\proj{a_2}\})=\operatorname{span}(\{\openone,\proj{a_1}\})$. Overall, a single additional unitary rotation $U$ allows us to reconstruct only the action of the same map on $\operatorname{span}(\{\proj{a_1},\proj{a_2},U\proj{a_1}U^\dag,U\proj{a_2}U^\dag\})=\operatorname{span}(\{\openone,\proj{a_1},U\proj{a_1}U^\dag\})$, which is not enough to tomographically reconstruct the channel. A geometric way of thinking about this is that the resulting four Bloch vectors are necessarily coplanar, and do not span affinely $\mathbb{R}^3$ (see Fig. \ref{fig:nodiscord}). \begin{figure} \begin{subfigure}[b]{0.5\textwidth} \includegraphics[width=0.4\textwidth]{nodiscord.jpg} \caption{With no discord.} \label{fig:nodiscord} \end{subfigure} \vspace{10pt} \begin{subfigure}[b]{0.5\textwidth} \includegraphics[width=0.4\textwidth]{withdiscord.jpg} \caption{With discord.} \label{fig:withdiscord} \end{subfigure} \caption{Bloch representation of two local operators for system $A$ before (blue dots) and after (red dots) a local unitary rotation, for the case of a two-qubit state $\rho_{AB}$. (a) In the case of no discord, the blue dots correspond to the representation of two orthogonal pure states; red dots and blue dots are necessarily coplanar, independently of the unitary transformation, and hence do not span the entire three-dimensional (Bloch) space: channel tomography is not possible. (b) In the case with discord, the blue dots represent the (rescaled) Bloch component of two orthonormal (with respect to the Hilbert-Schmidt inner product) operators $A_1$ and $A_2$ that enter the OSD decomposition of $\rho_{AB}$ not trivially, and that do not commute; there is a unitary such that red dots and blue dots are not coplanar, and hence span the entire three-dimensional space: channel tomography is possible.} \end{figure} On the other hand, assume that $\rho_{AB}$ has non-zero discord on $A$. This implies that there are some correlations, that is, that $\textup{OSR}(\rho_{AB})\geq 2$. Without loss of generality, we can assume that the OSD of $\rho$ must nontrivially contain $A_1$ and $A_2$ that do not commute, since, if all the non-trivial $A_i$'s that appear in the OSD of $\rho_{AB}$ commuted pairwise, they would all commute, and there would not be any discord. From Lemma~\ref{lem:commuting}, the Bloch vectors of $A_1$ and $A_2$ are not collinear. This means that there is a rotation $R$ of such vectors such that the resulting four vectors identify affinely independent points which span $\mathbb{R}^3$ (see Fig.\ref{fig:withdiscord}). Via the homomorphism between $SO(2)$ and $SU(3)$, the rotation $R$ corresponds to unitary rotation $U$ such that $\{\rho_{AB},U_A\otimes\openone_B\rho_{AB} U_A^\dag\otimes\openone_B\}$ is faithful. \end{proof} \subsection{Mixed probe-ancilla state: examples of efficient generation of faithful sets} In this example we present a family of mixed states of two qudits which generate faithful sets with even only two local unitaries, one being the identity. In order to construct the example we will make use of the Weyl (or generalized Pauli) basis for the space of $d\times d$ linear operators, which is given by $X^kZ^l$ with $k,l=0,\ldots,d-1$, where $X=\sum_{p=0}^{d-1}\projj{p+1}{p}$, $Z=\sum_{q=0}^{d-1}\omega^q\proj{q}$ and $\omega=e^{2\pi i/d}$ is a root of unity. Both $X$ and $Z$ are unitary, so that $X^\dagger = X^{-1}$ (similarly for $Z$). Since $X^d=Z^d=\openone$, the sets $\{X^k\}_k$ and $\{Z^l\}_l$ form cyclic groups under multiplication, and we can think that the exponent is taken modulus $d$. Let $F=\frac{1}{\sqrt{d}}\sum_{k,l=0}^{d-1}w^{kl}\projj{k}{l}$ be the discrete Fourier transform unitary. One has $F X F^\dagger = Z$, $F Z F^\dagger = X^\dagger$, and the braiding relation $ZX=\omega XZ$, from which one deduces $F X^k Z^l F^\dagger=Z^kX^{-l}=\omega^{-kl}X^{-l}Z^{k}$, and that the action of $F\cdot F^\dag$ on the basis elements $X^kZ^l$ induces closed and disjoint \emph{orbits} within $\{X^kZ^l\}_{k,l}$ (up to irrelevant phases), defined as $O(k,l)=\{F^nX^kZ^lF^{\dag n}\ |\ n=0,\ldots,3\}$. Specifically, one has \begin{align} F X^k Z^l F^{\dagger} &= \omega^{-kl}X^{-l} Z^k,\\ F^2 X^k Z^l F^{\dagger 2} &= X^{-k} Z^{-l},\\ F^3 X^k Z^l F^{\dagger 3} &= \omega^{-kl} X^l Z^{-k}, \end{align} while $F^4=\openone$ so that obviously $F^4X^k Z^l F^{\dagger 4} = X^k Z^l$. Such orbits contains either one, two, or four distinct elements. The only orbits with a single element are the one including the identity, corresponding to $(k,l)=(0,0)$, for both $d$ even and odd, and the one corresponding to the element $X^{d/2}Z^{d/2}$ for $d$ even. No orbit can contain exactly three distinct elements, as this would require that one of such elements is invariant under $F\cdot F^\dagger$, which is a contradiction for an orbit that contains more than one element and that is known to close necessarily under four repeated actions of $F\cdot F^\dagger$. Consider the set $\mathcal{O}=\{O(k,l)\}$ of orbits (up to irrelevant phases). We identify $O(k,l)=O(k',l')$ if $X^kZ^l$ is in the same orbit as $X^{k'}Z^{l'}$ (up to irrelevant phases). Consider the set $\mathcal{P}^{(1)}=\{W^{(1)}(O)|O\in\mathcal{O}\}$ composed of one Weyl-operator representative $W^{(1)}(O)$ per orbit $O$ (the exact choice of representative is irrelevant in this case). It is clear that $\cup_{i=0}^3F^i\mathcal{P}^{(1)}F^{\dagger i} = \{X^kZ^l\}_{k,l}$ up to irrelevant phases, where we have have used the shorthand notation $\Lambda\{K_m\}$ for the image $\{\Lambda[K_m]\}$ of a set $\{K_m\}$ under the action of a map $\Lambda$. In particular, $\operatorname{span}(\cup_{i=0}^3F^i\mathcal{P}^{(1)}F^{\dagger i})=\operatorname{span}(\{X^kZ^l\}_{k,l})$. Furthermore, it is also clear that there is a choice of \emph{pairs} of representatives (the two representatives may be chosen to coincide, in the case of 1-element and 2-element orbits) per orbit, forming a set $\mathcal{P}^{(2)}=\{W^{(2)}_1(O),W^{(2)}_2(O)|O\in\mathcal{O}\}$, such that $\cup_{i=0}^1F^i\mathcal{P}^{(2)}F^{\dagger i} = \{X^kZ^l\}_{k,l}$ (up to irrelevant phases). Let us be more concrete, providing a specific choice for the set $\mathcal{P}^{(1)}$. We consider two cases, according to the parity of $d$. First, let $d=2m+1$ be odd. It is easy to verify that (up to irrelevant phases) we can pick \begin{equation*} \mathcal{P}^{(1)} = \{X^kZ^l\ |\ k=0,\ldots,m;l=1,\ldots,m\}\cup\{\openone\}. \end{equation*} If $d=2m$ is instead even, then we can choose (again, up to irrelevant phases) \begin{align*} \mathcal{P}^{(1)}=\{X^kZ^l\ |\ k=0,\ldots,m-1;&l=1,\ldots,m\}\\ &\cup\{\openone,X^mZ^m\}. \end{align*} Notice the the above sets $\mathcal{P}^{(1)}$ contain $(d^2+3)/4$ and $(d^2+8)/4$ elements, for odd and even dimension respectively, thus scaling approximately as $d^2/4$. One can similarly construct a set $\mathcal{P}^{(2)}\subset \{X^kZ^l\}_{k,l}$, with approximately $\approx d^2/2$ elements, such that $\mathcal{P}^{(2)}\cup F\mathcal{P}^{(2)}F^\dagger$ spans the entire operator space. For example, one can take $\mathcal{P}^{(2)}=\mathcal{P}^{(1)}\cup F\mathcal{P}^{(1)}F^\dagger$, where elements that are identical up to a phase factor are equated. The issue we still have to face is how to use the facts above to construct, e.g., a state $\sigma_{AB}\in \mathcal{D}(\mathbb{C}^d\otimes \mathbb{C}^d)$ with $\textup{OSD}(\sigma_{AB})\approx d^2/2$ such that $\{\sigma_{AB},U_A\otimes \openone_A \sigma_{AB} U_A^\dagger\otimes \openone_A\}$ is a faithful set for channel tomography on qudit $A$. This is easily done by considering the hermitian operators \begin{align} H_{k,l}&=\frac{1}{\sqrt{2}}\left(X^kZ^l+(X^kZ^l)^\dagger\right) \\ &= \frac{1}{\sqrt{2}}\left(X^kZ^l+\omega^{kl}F^2(X^kZ^l)F^{\dagger 2}\right),\\ J_{k,l}&=\frac{1}{i\sqrt{2}}\left(X^kZ^l-(X^kZ^l)^\dag\right)\\ &= \frac{1}{i\sqrt{2}}\left(X^kZ^l-\omega^{kl}F^2(X^kZ^l)F^{\dagger 2}\right \end{align} where we have used the relation $F^2 X^k Z^l F^{\dagger 2} = X^{-k} Z^{-l}$ and the braiding relation of $X$ and $Z$. The operators $H_{k,l}$ and $J_{k,l}$ obviously span the same operator subspace as $X^kZ^l$ and $F^2(X^kZ^l)F^{\dag 2}$. Furthermore, we will use the fact that, given any Hermitian operator $H$ in finite dimensions, there is $\epsilon>0$ small enough (more precisely, it is enough that $\epsilon |\lambda_{-}(H)|\leq 1$, with $\lambda_{-}(H)$ the most negative eigenvalue of $H$) such that $\openone+\epsilon H$ is positive semidefinite. Thus, for example, given our choice of $\mathcal{P}^{(1)}$ above, it is clear that, for, say, $d$ odd (the even case is handled similarly), we can take \[ \begin{split} \sigma_{AB} &\propto\frac{\openone_{A}}{d}\otimes\frac{\openone_{B}}{d} \\ &\quad+ \epsilon\sum_{k=0}^{(d-1)/2} \sum_{l=1}^{ (d-1)/2 }\left( H_{k,l}\otimes H_{k,l}+J_{k,l}\otimes J_{k,l}\right). \end{split} \] with $\epsilon>0$ small enough. Then, by construction, $\left\{\sigma_{AB}\,,\,(F_A\otimes \openone_B) \sigma_{AB} (F_A\otimes \openone_B)^\dagger\right\}$ is a faithful set. Notice that $\sigma_{AB}$ has OSR less or equal to $2\frac{d-1}{2}\left(\frac{d-1}{2}+1\right)+1 = \frac{d^2+1}{2}$. \section{Conclusions} We have introduced and analyzed some properties of a framework for process tomography assisted by correlations. Our framework interpolates between standard process tomography and ancilla-assisted process tomography, and it is based on applying local transformations on the input probe---part of an probe-ancilla bipartite system---before the probe undergoes the process to be reconstructed. In particular, we focused on determining how the correlation properties of the starting probe-ancilla state $\rho_{AB}$ affect such a number. We proved that essentially all correlations can be helpful, in the sense of reducing such a number from $d^2$ for standard process tomography to roughly $d^2/\textup{OSR}(\rho_{AB})$, with $\textup{OSR}(\rho_{AB})$ the operator Schmidt rank of $\rho_{AB}$, which is necessarily optimal. We proved that this holds true in the pure-input case even if the local transformations are restricted to be unitary. In the mixed-state case, we pointed out the role of discord in the case of qubit probes and unitary local transformations, and gave ``extreme'' examples where just one additional initial local unitary rotation suffices for process tomography, even if the initial state has operator Schmidt rank approximately $d^2/2$. It would be interesting to fully understand the mixed-state case for unitary local rotations, which appears to be related to studying and applying the adjoint representation of the unitary group, and will be investigated in future work. \begin{acknowledgments} The authors thank J. Watrous for discussions. MP acknowledges support from European Union's Horizon 2020 Research and Innovation Programme under the Marie Sk{\l}odowska-Curie Action OPERACQC (Grant Agreement No. 661338), and from the Foundational Questions Institute under the Physics of the Observer Programme (Grant No. FQXi-RFP-1601). \end{acknowledgments}
\section*{Inferring causality from manifold dimensions} Inferring causal relations using manifold dimensions is possible and follows from Takens theorem. Given a time series, we can perform time delay embedding and measure/estimate the dimensionality of the reconstructed dynamics. Takens' theorem ensures that the dimension of the embedded manifold is the same as the dimension of the attractor in the original state-space and invariant against the observation function and dimension of the embedding space (provided it is sufficiently high dimensional). Several dimensionality notions have been introduced to capture key characteristics of attractors of dynamical systems. These investigations led to the applications of different fractal type dimensionality notations such as Rényi information dimension, correlation dimension and many kinds of intrinsic dimensions\cite{renyi, mandelbrot1979fractals, grassberger83, Levina2005,Szepesvari2007}. As an example of the possible use of manifold dimensions for causal inference, let us consider two simulated, unidirectionally coupled dynamical systems and their reconstructed attractors depicted in Fig.\,\ref{fig:logmap} A. One can observe that the dimensions of the two embedded manifolds are different. The dimension of the consequence is greater than the dimension of the cause, the consequence 'contains' the degrees of freedom of the cause. The detection of the difference between the dimensionality of the cause and the consequence provides an opportunity to set a new analysis method which is able to distinguish all forms of causal relations. The key variable in our framework is the joint dimension $D_J$ of two time series. Given two simultaneous time series one can get $D_J$ by forming the direct product of the two embedded spaces and measure the (intrinsic) dimension in the resulting point-cloud (c.f. SI section 1.1). Asymmetry of manifold dimensions (measured in the subspaces) does not imply causation, but the additional information provided by $D_J$ is sufficient to determine the type of causal relation between the two systems. {\bf Causal and dimensional relations.} In the case of two independent dynamical systems, the joint dimension equals to the sum of the dimension of the two independent systems - however, any interdependence makes the manifold dimensions sub-additive. As the cause can be reconstructed from the consequence, the information content of the cause is already available in the embedded manifold of the consequence, therefore in case of unidirectional coupling the joint dimension will be equal to the dimension of the consequence. Note that the dimension of the driven dynamical system (consequence) is always greater than or equal to the dimension of the driver dynamical system (cause) and the dimension of the two manifolds unequivocally determines the direction of the possible causal effect: only the lower dimensional system can have unidirectional causal effect on the higher dimensional one. There is a special case when the joint dimension is equal to the dimension of both time series: circular causality or full determinism. According to Takens' theorem a circular case means that homeomorphisms exist in both directions, therefore the two manifolds are topologically equivalent, having equal dimensions. If the joint dimension is less than the sum of the single dimensions, but not equal to either of them, that is the sign of an existing hidden common cause without direct causal effect between the two time series. In summary, the relation between the dimensions of the two systems and the joint dimension distinguishes the four possible causal scenarios as follows: ~\\ Independent case \begin{equation} X \perp Y \iff D_X + D_Y = D_J \label{indep} \end{equation} Unidirectional cases \begin{subequations} \label{uni} \begin{gather} X \rightarrow Y \iff D_X < D_Y = D_J \\ X \leftarrow Y \iff D_Y < D_X = D_J \end{gather}% \end{subequations} Circular case \begin{equation} X \leftrightarrow Y \iff D_X = D_Y = D_J \label{cir} \end{equation} Common cause \begin{equation} X \mathrel{\scalebox{0.8}{$\curlyveeuparrow$}} Y \iff \max(D_X , D_Y) < D_J < D_X + D_Y \label{hcc} \end{equation} The implications in Eqs. (\ref{indep}) - (\ref {cir}) are straightforward from causal relations to dimensional relations, the common cause case and the reasoning in the opposite direction follows from discretizing state variables otherwise further assumptions are required (see SI section 1.1). Thus, in order to infer the causality we estimated these dimensions using the method proposed in Farahmand\cite{Szepesvari2007}. Since, we have only estimates for the manifold dimensions based on finite datasets, we can not show exact equalities in Eqs. (\ref{indep}) - (\ref {hcc}), but we assign probabilities to these causal cases. The posterior probabilities of the dimensional relationship of the r.h.s of Eqs.\,\ref{indep}-\ref{hcc} are inferred by comparing the estimates of joint dimension ($D_J$) to the dimensions of the individual embedded time series ($D_X$ and $D_Y$). The inference is demonstrated by the following scheme. Let $A$ be the causal relation, which unequivocally determines the relation between dimensions according to Eqs. \ref{indep}-\ref{hcc}, and also let $\bar{d}$ denote the observed dimension vector, formed by the $\left( \bar{d}_X, \bar{d}_Y, \bar{d}_J, \bar{d}_Z \right)$ observations. First we apply Bayes' Theorem \begin{equation*} P(A|\bar{d}) = \frac{p\left(\bar{d}|A\right)}{p(\bar{d})}P(A), \end{equation*} then assume a non-informative prior over the possible causal relations ($A$) and finally calculate the conditional likelihood of the observed dimensions as \begin{equation*} p(\bar{d}|A) % = \int p(\bar{d}|w) dP(w|A), \end{equation*} where the integrand $w$ runs over the possible dimension combinations, determined by $dP(\cdot | A)$. For details see SI section 1.2. Dimension estimates are sensitive for parameter choices (e.g. embedding dimension, see SI section 2.1) and affected by unavoidable biases. The consequence of the bias caused by the embedding dimension can be decreased if the manifolds are embedded into spaces with same embedding dimensions. Along this principle, the independent case was represented by a manifold $Z$ with same embedding dimension as $J$. $Z$ is constructed by joining $X$ and the time-permuted (independalised) $Y^*$ manifolds. In order to further increase the precision of the dimension comparisons, the embedding dimensions of $J$ and $Z$ were matched to the embedding dimensions of $X$ and $Y$ by introducing new embeddings $J'=aX+Y$ and $Z'=aX+Y^*$ (where $a$ is a properly chosen irrational number) instead of $J$ and $Z$. Note that $J'$ and $Z'$ are based on generic observation functions of the original systems, thus they are topologically equivalent to the original system as well in almost all cases (for the proof see SI section 1.1). There are some situations of system interactions that require further thoughts including the case of full determinism, the hidden common driver and the transitivity of causal relations. In case of full determinism, also called generalized synchrony, the caused time series are fully determined by the cause. In this case there is no point in considering them as different systems, we have only two copies/observations of the same system (maybe with a time delay). Thus, this particular unidirectional coupling can not be distinguished from the circularly coupled case: the reconstructed topologies are equivalent in both cases. There are particular cases, when the common driver remains hidden. If the common cause coexists with a direct connection at least in one direction, then the direct connection ensures that all the information of the cause is present in the joint, thus the direct connection(s) will be detectable, while the common driver remains hidden. Theoretically, causality is a transitive relation. Thus, indirect causal relations (through a chain of direct connections) should be identified as direct causal relation as well. However in real world applications the additive noise can result in non-transitive directed causal relations between multiple systems. \begin{figure} \centering \includegraphics[scale=1.6]{logmap_minimal_figurelq.png} \caption{\textit{The workflow and testing of the Dimensional Causality method on coupled logistic map systems (see Eq.\,\ref{eq:logist})}. (A) The state spaces of the systems are reconstructed by time delay embedding of the two time series $X_1$ (red) and $X_2$ (blue), resulting in the red and blue manifolds. Then joint of the two dataset $J'$ and their time-shuffled version $Z'$ are also embedded, resulting in a reconstruction of the joint state space of the two subsystems (black manifold) and their independent joint (yellow). On (B,C) the test of the DC method on the four simulated examples of five possible causal interactions (one of the unidirectional: $X_1 \rightarrow X_2$, circular: $X_1 \leftrightarrow X_2$, unidirectional - back: $X_1 \leftarrow X_2$, common cause: $X_1 \protect\mathrel{\scalebox{0.8}{$\curlyveeuparrow$}} X_2$, independence: $X_1 \bot X_2$) are demonstrated. (B) The intrinsic dimensionality of each manifold is estimated for different neighborhood sizes $k$. The plateau of dimension-estimates identifies where the estimates can be considered reliable (between dashed lines). Note the match between the actual causal and dimensional relationships: the dimension of the joint manifold ($J$) relative to the others. (C) Posterior probabilities of the possible causal relationships. The method correctly assigned the highest probability to the actual causal relation in each case.} \label{fig:logmap} \end{figure} \section*{Results} We validate our method on data from three simulated dynamical systems where ground truths are known. Following this verification, the method is also applied to EEG data of epileptic patients. The three simulated dynamical systems have fundamentally different dynamics and pose quite different challenges that causal analysis has to overcome: the coupled logistic maps are discrete-time chaotic dynamical systems with no significant temporal autocorrelation, in contrast the coupled Lorenz-systems are defined in continuous time and show smooth temporal autocorrelation, while the system of Hindmarsh-Rose models exhibit steep spikes and quasi periodic behavior. {\bf Logistic maps.} We simulated systems of three coupled logistic maps with various connectivity patterns: unidirectional, circular, independent and two uncoupled maps driven by a third unobserved one: \begin{equation} x_i[t+1] = r x_i[t] (1 - x_i[t]-\sum_{j\neq i} \beta_{i,j} x_j[t]), \label{eq:logist} \end{equation} where $i \in \lbrace 1, 2, 3 \rbrace$ for the three variables, $r=3.99$ and $\beta_{i,j}$ are coupling coefficients (values for the different simulated couplings are given in SI section 2.2). \begin{figure} \centering \includegraphics[scale=0.65]{logmap_noise.png} \caption{\textit{Performance and robustness of the Dimensional Causality method in the presence of noise.} (A) The maximal (theoretic) accuracy as a function of relative noise for five different data lengths. The maximal accuracy was calculated as the maximum of accuracy scores obtained for different $k$. This assumes optimal choice of parameter $k$. Up to $0.01$ relative noise $0.8$ accuracy is easily achieved if we have at least $1000$ observations. Only at $0.1$ relative noise may the classification fall to chance level. (B) The $k$ that performed best for a given noise level. Longer data allows larger $k$ and larger noise requires larger $k$. } \label{fig:robustness} \end{figure} The DC method was able to reveal the original coupling pattern between the observed logistic maps for all cases, in particular it was able to detect the existence of the hidden common cause observing only the two affected logistic maps (Fig.\,\ref{fig:logmap}). The performance of the DC method was evaluated on simulated coupled logistic maps. Each of the causal scenarios Eqs.\ \eqref{indep}--\eqref{hcc} was simulated with randomly chosen system parameters (uniformly sampled in the range $r \in [3.6, 4.0)$, $\beta \in [0.1, 0.5)$), see Fig.\ \ref{fig:robustness}. Classification is almost perfect below 1\% relative noise for typical data lengths. Moreover, the DC method performs above chance up to 10\% relative noise. (For further details see SI section 2.2.) {\bf Lorenz systems} We tested our method on differently coupled Lorenz systems \cite{Lorenz1963} (Fig. \ref{fig:lorenz}). \begin{figure} \centering \includegraphics[scale=1.8]{lorenz_resultslq.png} \caption{\textit{Testing the DC method on coupled Lorenz systems.} (A) The $X$ variables of two Lorenz systems, represented as time series. There is unidirectional coupling from the first system (the driver, red) to the second (the driven, blue). The description of the Lorenz systems is given in the supplementary information. (B) The attractor of the driven system is only slightly perturbed by the driver. (C) -(F) Model probabilities nicely match with the truth for the different couplings. (Color code matches Fig. \ref{fig:logmap} C.) } \label{fig:lorenz} \end{figure} We conclude that in each case our method detects the proper causal relationship with high confidence. For further details see SI 2.2. {\bf Hindmarsh-Rose systems} We analyze causal relationships between coupled Hindmarsh-Rose systems which were originally proposed to model spiking or bursting neuronal activity \cite{hindmarsh-rose}. In our simulations we use two electrically coupled neurons where coupling is achieved through the membrane potential, as proposed in \cite{coupled-hindmarsh-rose}. Analysis of such time series is quite difficult due to their sharp dynamical changes. \begin{figure} \centering \includegraphics[scale=2]{hr_resultslq.png} \caption{\textit{Testing the DC method on coupled Hindmarsh-Rose systems.} (A) The membrane potentials ($X_1 , X_2 $) of unidirectionally coupled Hindmarsh-Rose systems. (B-E) The inferred probabilities for the different types of couplings. (Color code matches with Fig. \ref{fig:logmap} C.) } \label{fig:hindmarsh_rose} \end{figure} Fig. \ref{fig:hindmarsh_rose} shows our results on different Hindmarsh-Rose systems. We conclude that in each case our method detects the proper causal relationship with high confidence. For further details about the Hindmarsh-Rose systems and model parameters we refer the reader to SI 2.2. {\bf Changes of inter-hemispheric connectivity during photo-stimulation} \begin{figure} \centering \includegraphics[scale=1.3]{fotostimlq.png} \caption{\textit{Inter-hemispherical interactions during photo-stimulation.} (A) CSD signal in control condition and photo-stimulation periods (light bulbs) at the six analyzed recording-channels and (B) electrode positions on the scalp. Causal relations were computed between P3-P4, C3-C4 and F3-F4 channel pairs. (C) Difference in probabilities of causal relations between stimulation and control (mean and SE). The probability of the existence of common cause is significantly higher during stimulation periods for P3-P4 ($p=0.024$) and C3-C4 ($p=0.0002$) channel-pairs but not for F3-F4 ($n=87$).} \label{fig:fotostim} \end{figure} Finally, we set out to test our approach under real-world conditions, where the true dimensionality of the systems and the properties of the noise are unknown. In general, the exact causal relationships between time series in these systems are not known. However, external drive can induce changes in the internal causal relationships that can be detected using our analysis method. In particular, the standard epilepsy-diagnostic photo-stimulation procedure (patients exposed to flashing light at different frequencies in a standardized test) is an ideal model for external common cause affecting the two brain hemispheres. The connectivity between these brain regions suggests that visual information arrives first to (O1, O2 electrodes) and spreads to the parietal (P3-P4) and central (C3-C4) area (Fig.\,\ref{fig:fotostim} B) afterwards. Hence, it is expected that the DC method is suitable to detect the visual stimulus as a common cause between the affected electrode sites. Thus, DC method was applied to Current Source Density (CSD, see SI 2.2) calculated from EEG recordings of 87 patients participating in the photo-stimulation task (Fig.\,\ref{fig:fotostim} A). The probability of common cause ($\mathrel{\scalebox{0.8}{$\curlyveeuparrow$}}$) was significantly increased during visual stimulation periods for P3-P4 and C3-C4 channel-pairs relative to the resting state but not for the frontal areas (F3-F4) (Fig.\ref{fig:fotostim} C, SI section 2.2). {\bf Causal connections during epileptic seizure} \begin{figure} \centering \includegraphics[scale=0.5]{epi_figureLQ.png} \caption{\textit{Cortical connectivity during epileptic seizure} (A) CSD signal at fronto-basal, frontal (Fl1) fronto-lateral (Fl2) and infero-parietal (iP) areas, the blue selection shows the analyzed time period of the seizure. Basically two types of connectivity were detected for seizures and a third type of connectivity for interictal conditions (B-D). (B) Maximal aposteriory probability (MAP) causal connection structure for the example seizure in A. Red arrows mark unidirectional relations and the pink dashed lines mark detected common cause relations. (seizure type 1, $n=6$) (C) MAP Causal connection structure for seizure type 2 ($n=10$) (D) MAP mean causal connection structure interictal sections ($n=16$). Blue arrows mark unidirectional relations and purple arrows denotes circular causal relations. (E) Causal relation probabilities of the seizure showed on A and B. (F) The inferred driver and driven areas represented on the brain surface for the same seizure as on A, B, E. } \label{fig:memo} \end{figure} Our next example shows how the identification of the causal connection between the investigated areas can contribute to the diagnosis and surgical treatment of epileptic patients. Our investigations led to self-consistent results, supporting our assumption that the DC method is applicable in such complex situations as well. The EEG data from a 20-year-old patient, suffering from drug resistant epilepsy with frequent seizures, was analyzed. As part of pre-surgical examination, a subdural grid and 2 strip electrodes were placed onto the surface of the brain, which allowed the identification of the brain areas participating in the seizure activity with high spatial precision. The seizures showed a variable and complex picture, where most of high frequency seizure activity were observable on the fronto-basal (Fb) and the frontal (Fl1) region (Fig. \ref{fig:memo} C). The fronto-lateral (Fl2) region was impacted only moderately by the seizures and the infero-parietal (iP) region showed irregular high amplitude spiking activity during both interictal and ictal periods (Fig.\,\ref{fig:memo} A). We investigated all the causal relations between the four brain regions and found variable connectivity. The DC analysis showed two main connectivity types during seizures (from analysis of $n=18$ seizures, Ext.\,Dat.\,Fig.\,\ref{fig:memo_seizure_microfilm}, see SI 2.2). In the first main type iP was found to be the driver ($n=6$), while the existence of a common cause between Fb, Fl1 and Fl2 got the highest probability during the pairwise analysis (Fig.\, \ref{fig:memo} B, E, F). In the second main type of seizures hidden common cause was detected between all the observed channels ($n=10$,Fig.\, \ref{fig:memo} C), which indicates the possible existence of a driver which was out of the region of investigation. In contrast, Fb was found to be dominant driver node during normal interictal activity (Fig.\,\ref{fig:memo} D, Ext.\,Dat.\,Fig.\,\ref{fig:memo_control_microfilm}, SI section 2.2). Given the difficult accessibility of the iP region, the medical panel came to the conclusion to resect the frontal and the fronto-basal region and the less active areas were left intact. The patient was seizure free for 1 year, before reinstated. The DC analysis highlighted the variability of the seizures as well as the existence of a possible hidden common cause behind the observed seizure activity, which could form a basis for the cortical reorganization and the recovery of the epileptic activity in case of the investigated patient. However, systematic analysis on large population of patients will be necessary to clarify the underlying causal structures during epileptic network activity. \section*{Conclusions} We presented the Dimensional Causality method, which is the first unified way to detect all types of causal relations in dynamical systems . In particular, it can reveal the existence of hidden common cause and quantifies the probability of each causal relationship type. The DC method was validated on synthetic data and self-consistency and practical applicability have been demonstrated on human EEG data from epileptic patients. The precision of our inference is based on the reliability of dimension estimations, which is affected by the choice of embedding parameters and a couple of signal properties such as autocorrelation, sample size, noise level and manifold geometry, especially curvature. We proposed a systematic method to find good parameter settings (SI section 2.1, and see also \cite{grassberger83,Levina2005}). The longer the signal's temporal autocorrelation, the more data points are required to correctly sample the manifold's surface (in the reconstructed state-space) in order to infer causal relations. Our simulations indicate that the proper determination of dimensions required typically at least a few thousand samples, which is more than the data CCM needs to detect directed causal relations under optimal conditions. While being operational at smaller sample sizes, CCM is less reliable in the identification of hidden common cause, and lacks assigned probabilities of causal cases. At the price of being more data intensive, DC has the capability to solidly detect hidden common cause and assigns easily interpretable probabilities to each possible causal relation. In general, the presence of observational or dynamic noise decreases the reliability of the inference as it is demonstrated in \cite{hirata2016detecting}. Additionally, the curvature of delay-reconstructed manifold causes the overestimation of local dimensionality (for a finite sample) and also sets limit on maximal noise level, which allows meaningful state space reconstruction\cite{Casdagli1991}. We should mention that correlation dimension and mutual information dimension have been applied to evaluate connection between dynamical systems, but none of them led to exhausting description of bivariate causal relationships due to their symmetric nature \cite{romano2016, Sugiyama2013}. {\bf Future directions.} In the present paper we focused on systems with deterministic dynamical components, however, we hope that our unified framework could be extended to pure stochastic systems, and systems of mixed character, having deterministic and stochastic components as well. In the present work we assumed no delay in the causal effect. Similarly to \cite{ye2015distinguishing} this assumption can be relaxed and causality can be determined with different effect delays, thus not only existence of the connection, but the delay of the effect can be determined. The pairwise determination of the causal relationships used here could be extended to multivariate comparisons to reveal more complex network structures. The Dimensional Causality method is a unified method to quantify all types of causal relationships. Based on the presented examples and tests we believe that this new method will be applicable in many different scientific areas, although it is clear that there are many open questions and further directions to work out. \bibliographystyle{naturemag.bst} \section{Supplementary Notes} \subsection{Intrinsic dimension and causality} In this section we lay down the mathematical background of the relationship between causal connections and relationships between the dimension of the state space of systems. We begin with some general remarks on the possibilities and limitations of the analysis of the connection of dynamical systems via an observation, a time series. It is standard to assume that the system is in steady state and consequently the observed time series is stationary. We will investigate the stationary distribution via its information dimension. Let us recall first the definition of the information dimension introduced by Rényi \cite{renyi}. \begin{equation*} d_{X}=\lim_{N\rightarrow \infty }\frac{1}{\log N} H([X]_N) , \end{equation*} % where $X\in \mathbb{R}^{m}$ is a continuous vector valued random variable, $[X]_N=\frac{\left\lfloor NX\right\rfloor }{N}$ is its $N$-quantization (a discrete variable) and $H(.)$ stands for the Shannon entropy. The finer the resolution $r=1/N$ the more accurate the approximation of the information content is, but the normalization in the limit eliminates the contribution of the discrete part of the distribution (if it exists). That means that the estimate the information dimension has a trade-off and also a limitation given the finiteness of the sample. It is suggested that if the variable lives in a $D$ dimensional space then a proper estimate needs at least $10^D-30^D$ sample points \cite{wolf1985}. Following Pincus' ideas \cite{pincus1991approximate,pincus1991regularity,pincus1995approximate} we introduce the approximate information dimension \begin{equation*} d_{X,1/N}=\frac{1}{\log N} H([X]_N) . \end{equation*} or in short $d_{X,r}$, for arbitrary partition with box size $r$. \begin{assumption} The investigated time series are stationary. \end{assumption} \noindent{\bf Dimensions.} % The notion of dimension has many definitions depending on the context and methods. Takens' work was confined to topological dimensionality, but the embedding theorem was extended to fractal dimensions as well \cite{Sauer1991}. In our case the attractor, the support of the stationary distribution, can be a fractal. We already recalled the Rényi information dimension. On the other hand the local intrinsic dimension is defined as follows. Let $X \in \mathbb{R}^m $ be the investigated random variable \begin{equation*} D_X(x)=\lim_{r\rightarrow 0 }\frac{1}{\log r} {\log P(X \in B(x,r) ) } \end{equation*} % where $B(x,r)$ is the hypercube in $\mathbb{R}^m $ with lower corner $x$. Then the intrinsic dimension is $D_X=E(D_X(X))$ and \begin{equation*} d_{X}=D_X \end{equation*} % (see the work of Camastra and Staiano \cite{camastra2016intrinsic}, and theorems 1 and 2 of Romano et al. \cite{romano2016}). ID estimation has a waste literature, several excellent reviews \cite{campadelli2015intrinsic, camastra2016intrinsic} help to find the best performing one. Reviews and benchmark tests indicate that the $k$-Nearest Neighbour based methods have several advantages, including the rigorous derivation of the estimate presented by Levina and Bickel \cite{Levina2005} and the very good convergence properties of a variant \cite{Szepesvari2007}. We follow the latter one, in particular we do so since it provides a hint for the choice of scaling, which is one of the crucial points in the ID estimation procedure. \begin{assumption} The embedded manifolds are homogeneous with respect to (the existing) dimension. \end{assumption} Based on the previous introduction our intrinsic dimension estimates are \[ \widehat{D}\left( x\right)_r =\frac{1}{\log r}\log \left\vert N\left(x,r\right) \right\vert \]% and% \[ \widehat{D}_{X,r} =\frac{1}{n}\sum_{i=1}^{n}\widehat{D}\left(x_{i}\right)_r , \]% where $n$ is the sample size, $\left\{ X_{i}\right\} _{i=1}^{n}$ is the set of sample points on the manifold and $N(x,r)= \left\lbrace X_i:X_i \in B\left(x,r\right) \right\rbrace$. We shall use a bit reversed logic (following Farahmand, Szepesvári and Audibert \cite{Szepesvari2007}) and calculate the dimension from the distance of $k$-th nearest neighbour $r(x,k)=d(x,X^k(x) )$ where $X^k(x)$ is the $k$-th closest point to $x$ in our sample series. In this setting the resolution is given by \begin{equation} r^D \approx \frac{k}{n} \end{equation} where $n$ is the sample size. % \newline\newline \noindent{\bf Causal relations.} Let us introduce the box partitioning of $\mathbb{R}^m$ using $r \mathbb{Z}^m$ and denote the boxes by $B(x,r)$, where $x$ is the lower left corner. Also we index the partition element $B(x,r)$ by $x$. The quantized variables are defined as follows. \begin{equation} X^r=x \text{ if } X\in B(x,r) \end{equation} \begin{definition} We say that $X$ causes/drives $Y$ at resolution $r$ (denoted by $X \rightarrow_r Y$) if there is a mapping $f$ s.t. $X_{t}^{r}= f \left( Y_{t}^{r}\right) $ for all $t$. \label{drive} \end{definition} In case of a time delayed causal relation between the systems with lag $\tau$ we have $X_{t-\tau}^{r} = f \left( Y_{t}^{r}\right)$, therefore the proper time-shift should be applied as a preprocessing step. \begin{definition} We say that $X$ and $Y$ are in circular causal relations at resolution $r$ (denoted by $X \leftrightarrow_r Y$), if both drives the other at resolution $r$. \end{definition} \begin{definition} We say that the $x_t$ and $y_t$ observations are basically identical (also called generalized synchrony) if there is a bijective mapping $f$ s.t. $x_{t}= f \left( y_{t}\right)$ for all $t$. From a dynamical systems point of view, generalized synchrony is a special case of circular causality. \end{definition} One should note that we defined causality (definition \ref{drive}) counter-intuitively in a kind of reversed direction. $X$ can be reconstructed from the information contained in $Y$ given that exactly that is what conveyed from $X$ to $Y$ in the action of driving. If just partial reconstruction is possible, say $X=(X',Y'')$ and $Y=(Y',Y'')$, where all the components are independent, then $Y''$ is a common cause of $X$ and $Y$, and $X$ does not drive $Y$ or vice versa. \begin{definition} We say that $X$ and $Y$ are independent at resolution $r$ (denoted by $X \perp_r Y$ if $X^r$ independent of $Y^r$. \end{definition} \begin{definition} We say that $\left\{ Y\right\} ,$ $\left\{ X \right\} $ have a common cause at resolution $r$ (denoted by $X$ $\mathrel{\scalebox{0.8}{$\curlyveeuparrow$}}_r$ $Y$ ) if they are, at resolution $r$, not independent and there is no driving connection between then again at resolution $r$. \end{definition} \noindent{\bf Link between causal and dimensional relations.} First we recall some elementary facts which will be useful. Let $\mathbb{J}=\left(X,Y\right)$ be the joint embedding. The intrinsic dimension $D$ coincides with the information dimension $d$ and the same applies for the quantized versions \cite{romano2016}. \begin{lemma} \label{LHH} The elementary properties of the discrete Shannon-entropy imply that for all $r$ \begin{equation} \max \left\{ H\left( X^r \right) ,H\left( Y^r \right) \right\} \leq H\left( X^r,Y^r\right) \leq H\left( X^r\right) +H\left( Y^r\right) \end{equation} and \begin{equation} \max \left\{ D_{X,r},D_{Y,r}\right\} \leq D_{\left( X,Y\right),r }\leq D_{X,r}+D_{Y,r}, \label{e2} \end{equation} where equality on the r.h.s. holds if and only if the variables are independent at resolution $r$ $\left(X \perp_r Y \right)$ . \end{lemma} \begin{corollary} \label{CDD} \label{bB}$X \perp_r Y$ iff. \begin{equation} D_{\left( X,Y\right),r }=D_{X,r}+D_{Y,r}, \end{equation} \end{corollary} \begin{proof} The statement is immediate from the additivity of the Shannon entropy of independent variables. \end{proof} \begin{corollary} If $X\rightarrow_r Y$ then \begin{equation*} D_{X,r}\leq D_{Y,r}=D_{\left( X,Y\right),r } \end{equation*} % and if $X\leftrightarrow_r Y$ then \begin{equation*} D_{Y,r}=D_{X,r}=D_{\left( X,Y\right),r }. \end{equation*} \end{corollary} \begin{proof} Both statements follow from the fact that if $% X^r=f\left( Y^r \right) $ then $H\left( X^r|Y^r\right)=H\left( f\left( Y^r\right)|Y^r \right)=0$: \begin{equation} \begin{array}{rcl} H\left( X^r,Y^r\right) & = & H\left(X^r|Y^r \right) + H\left( Y^r\right) \\ & = & H\left( f\left( Y^r\right)\right|Y^r) + H\left( Y^r\right) \\ & = & H\left( Y^r\right). \label{ee3} \end{array} \end{equation} \end{proof} \begin{theorem} \label{Tdirect}If $D_{\left( X,Y\right),r }=D_{Y,r}$ then $X$ drives $Y$ at resolution $r$. \end{theorem} \begin{proof} It is immediate from the condition that \begin{equation*} \begin{array}{rcl} H\left(X^r|Y^r\right)=0 \end{array} \end{equation*} % but that implies that there is a mapping $f$ s.t. $X^r=f(Y^r)$. \end{proof} \begin{theorem} \label{cC} $X^r$ and $Y^r$ have a common cause if and only if \begin{equation*} \max \left\{ D_{X,r},D_{Y,r}\right\} < D_{\left( X,Y\right), r } < D_{X, r}+D_{Y, r}. \end{equation*} \end{theorem} \begin{proof} The statement follows from the combination of Corollary \ref{CDD} and \bigskip Theorem \ \ref{Tdirect}. \end{proof} If we combine all our results from Lemma \ref{LHH} to Theorem \ref{cC} then we have the following full table of implications. \begin{equation*} \begin{bmatrix} X\rightarrow_r Y & \Longleftrightarrow & D_{X,r}<D_{Y,r}=D_{\left( X,Y\right),r } \\ Y\rightarrow_r X & \Longleftrightarrow & D_{Y,r}<D_{X,r}=D_{\left( X,Y\right),r } \\ X\leftrightarrow_r Y & \Longleftrightarrow & D_{X,r}=D_{Y,r}=D_{\left( X,Y\right),r } \\ X\text{ }\mathrel{\scalebox{0.8}{$\curlyveeuparrow$}}_r\text{ }Y & \Longleftrightarrow & \max \left\{ D_{X,r}D_{Y,r}\right\} <D_{\left( X,Y\right),r }<D_{X,r}+D_{Y,r} \\ X\perp_r Y & \Longleftrightarrow & D_{\left( X,Y\right),r }=D_{X,r}+D_{Y,r}% \end{bmatrix} \end{equation*} Let us note that the first implication remains true as $r \rightarrow 0 $ if it is ensured that the conditional random variable $X|Y$ has no discrete part. A bit more indirect extra condition is needed for the validity of the common cause in the limit, though. If $Z$ is the common driver, it should satisfy that $Z|X$ and $Z|Y$ have no discrete part. Finally, for independence in the limit, it is necessary that there is no discrete connection between the variables (the formal definition is omitted for brevity). Note that if these implications hold as $r \rightarrow 0$, then there is causal relationship between the systems in classical dynamical system theory sense. % \newline\newline \noindent{\bf Causality detection using additive observation of the series.} The genericity of Takens' theorem allows us to choose an observation function (mapping) almost freely. \ As demonstrated in eq. \ref{e2} the direct product of the embedding of the series has such good properties. \ On the other hand it increases the embedding dimension, which is unfortunate in practice, so we may look for other mappings. \ The simplest, linear one, is a natural choice. \ Let us imagine $W=X+Y.$ \ In general it is again a good mapping but if in particular $X=X_{1}-Y,$ for independent $X_{1}$ and $Y $ the result would be the drop of dimension. There is a simple resolution of that problem. If we choose a random number $a \in [0,1], a \neq 0 $ uniformly and consider $U=aX+Y$ than, with probability one $U$ will be a proper observation function and can replace the direct product $J$. Also if we know that $D_X,D_Y<m+1$ and we chose $a_i\in [-1,1],i=1...m+1$ random number, and set $U_i = a_iX-Y$ at least one should be proper observation function and the wrong once can be identified by the drop of the dimension. \subsection{Assigning probabilities to causal relations} In the whole sequel we omit marking the resolution $r$ where it does not cause confusion. Given the constraints $\max\left\lbrace{D_X,D_Y}\right\rbrace \leq D_J \leq D_Z \leq D_X+D_Y$ we have the next complete partition of the event space of possible causal relationships \[ \begin{array}{cccc} & \text{direct drive} & \mathrel{\scalebox{0.8}{$\curlyveeuparrow$}} & \bot \\ D_{X}<D_{Y} & A_{1,1} & A_{1,2} & A_{1,3} \\ D_{X}>D_{Y} & A_{2,1} & A_{2,2} & A_{2,3} \\ D_{X}=D_{Y} & A_{3,1} & A_{3,2} & A_{3,3}% \end{array}% \] % and $\mathcal{A} = \left\lbrace A_{i,j}:i,j=1,2,3 \right\rbrace $ (in the main text, $A \in \mathcal{A}$ in the Bayesian argument). In the main text the causal relations referred as $X \rightarrow Y$, corresponds here to $A_{1,1}$, $X \leftarrow Y$ to $A_{2,1}$, $X \leftrightarrow Y$ to $A_{3,1}$, while $X \mathrel{\scalebox{0.8}{$\curlyveeuparrow$}} Y = \sum_{i=1}^3 A_{i,2}$ and $X \bot Y = \sum_{i=1}^3 A_{i,3}$. Based on the work of Romano et al. \cite{romano2016} we consider the expected value of local dimensions to be the global dimension - therefore, the mean of the local dimension estimates yields our estimate of the global dimension. Consequently, the sampling distribution of the global dimension estimates is multivariate normal with true dimensions $D$ being its mean and covariance matrix $\Sigma$. Let $\bar{D}$ denote the observed global dimension that depends on $D$ and $\Sigma$. Note however that $D$ and $\Sigma $ are uncertain parameters themselves, since they depend on the causal model $A$. The dependence of $D$ on $A$ is trivial by the links derived in the previous sections between causality and dimensions, but $A$ also has an effect on the noise model $\Sigma$: if for example the causal relationship is $X \rightarrow Y$ ($A = A_{1,1}$), then $D_Y = D_J$ in theory, therefore $D_Y$ and $D_J$ should be correlated. Let $U$ represent the parameters of our method (e.g. $k$, $\tau$, embedding dimension $m$). Our method's parameters also affect dimension estimation, therefore influence the noise model (but not the true dimensions $D$). Finally we can conclude that $\bar{D}$ depends on $D$ and $\Sigma$, $D$ depends only on $A$, while $\Sigma$ depends on both $A$ and $U$, where $U$ can be considered hyperparameters. In this setting the realization of $\bar{D}$ is a single (4-dimensional) data point, let's denote it as $\bar{d}$. The likelihood of the data can be written as \begin{equation*} p_{\bar{D}}(\bar{d}) = \sum_{A_{ij} \in \mathcal{A}} p_{\bar{D}|A}(\bar{d}|A_{ij}) \; P_{A}(A_{ij}). \end{equation*} We are interested in the probabilities of each $A_{ij}$ given the data, therefore we apply Bayes' theorem and get \begin{equation*} P_{A|\bar{D}}(A_{ij}|\bar{d}) = \frac{p_{\bar{D}|A}(\bar{d}|A_{ij})}{p_{\bar{D}}(\bar{d})}P_{A}(A_{ij}). \end{equation*} % Note that $p_{\bar{D}}(\bar{d})$ is only a normalizing term, therefore it is enough to calculate $p_{\bar{D}|A}(\bar{d}|A_{ij})P_{A}(A_{ij})$ for all $A_{ij}$. We assume a non-informative prior over the possible causal relations, $P_A(A_{ij}) = \frac{1}{9} \; \forall i,j$. Taking the dependence structure of the random variables into consideration we can write the likelihood as \begin{equation*} p_{\bar{D}|A}(\bar{d}|A_{ij}) = \int p_{\bar{D}|D,\Sigma}(\bar{d}|w,s) \; dP_{D,\Sigma|A}(w,s|A_{ij}). \end{equation*} If we extend this with $U$ we get \begin{equation*} \begin{array}{rcl} p_{\bar{D}|A}(\bar{d}|A_{ij}) & = & \displaystyle\int p_{\bar{D}|A,U}(\bar{d}|A_{ij}, u) \; dP_{U}(u) \\ & = & \displaystyle\int \int p_{\bar{D}|D,\Sigma}(\bar{d}|w,s) \; dP_{D,\Sigma|A,U}(w,s|A_{ij},u) \; dP_U(u). \end{array} \end{equation*} We know that $\bar{d}$ comes from a 4-variate normal distribution with expected value vector $w$ and covariance matrix $s$, therefore \begin{equation*} \begin{array}{rcl} p_{\bar{D}|A}(\bar{d}|A_{ij}) & = & \displaystyle\int \int \varphi_{w,s}(\bar{d}) \; dP_{D,\Sigma|A,U}(w,s|A_{ij},u) \; dP_{U}(u) \\ & = & \displaystyle \int \int \varphi_{\bar{d},s}(w) \; dP_{D,\Sigma|A,U}(w,s|A_{ij},u) \; dP_{U}(u) \\ & = & \displaystyle \int \int \int \varphi_{\bar{d},s}(w) \; dP_{D|A,U}(w|A_{ij},u) \; dP_{\Sigma|A,U}(s|A_{ij},u) \; dP_{U}(u) \\ & = & \displaystyle\int \int \int \varphi_{\bar{d},s}(w) \; dP_{D|A}(w|A_{ij}) \; dP_{\Sigma|A,U}(s|A_{ij},u) \; dP_{U}(u), \end{array}% \end{equation*} % where $\varphi_{w,s}$ denotes the multivariate normal PDF with expected value vector $w$ and covariance matrix $s$. We used the conditional independence of $D$ and $\Sigma$, the independence of $D$ and $U$, and that in the probability density function of the normal distribution the expected value and the data can be exchanged, since $(\bar{d} - w)^T s^{-1} (\bar{d} - w) = (w - \bar{d})^T s^{-1} (w - \bar{d})$. Let us now consider $dP_{D|A}(w|A_{ij})$. Every $A_{ij}$ induces a set $S_{ij} \subset \mathbb{R}_+^4$ such that each element of $S_{ij}$ satisfies the conditions given by $A_{ij}$. For example, $S_{1,1} = \{v : v \in \mathbb{R}_{+}^{4}, v_1 < v_2 = v_3 < v_4\}$. It is easy to verify that $S_{ij}$ is a convex cone with (algebraic) dimension $q_{ij} \in \{2, 3, 4\}$, simply embedded into a $4$-dimensional Euclidean space. Let $C_{ij} \in \mathbb{R}_+^{q_{ij}}$ denote the convex cone in its original, lower dimensional space. For example $C_{1,1} = \{w : w \in \mathbb{R}_{+}^{3}, w_1 < w_2 < w_3\}$. For any $A_{ij}$ there exists a simple linear bijective mapping $M_{ij}$ such that $M_{ij}w \in S_{ij} \; \forall w \in C_{ij}$, for example \begin{equation*} M_{1,1} = \left[\begin{matrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \end{matrix}\right]. \end{equation*} % We assume a non-informative uniform prior on the true dimensions $D$. Since the prior is conditioned on $A_{ij}$, $C_{ij}$ becomes its support, resulting in an improper prior (due to the cone being infinite). It is obvious that this is not an actual distribution, but specifies a prior with correct proportions (granting equal weight to each element of the support). Putting these together we get \begin{equation*} p_{\bar{D}|A}(\bar{d}|A_{ij}) = \displaystyle\int \int \int_{C_{ij}} \varphi_{\bar{d},s}(M_{ij}w) \; dw \; dP_{\Sigma|A,U}(s|A_{ij},u) \; dP_{U}(u). \end{equation*} Let us now focus on marginalizing $\Sigma $. The $4 \times 4$ covariance matrix has 10 elements in the upper-triangular part - we would have to marginalize each of them. This comes with computational issues and lack of knowledge about the conditional distribution of $\Sigma $, both of which we wish to avoid. Instead, we calculate a sample covariance matrix $\hat{s}$, which is a maximum-likelihood estimate, and assume that the distribution is very peaked at this estimate. Note however that the neighbourhoods of our sample points are overlapping and the calculated local dimensions are not independent. Therefore, the covariance matrix must be calculated by taking the correlation of local dimension estimates into consideration. If the samples were independently drawn, then the covariance of the means is given by the covariance of the local dimensions divided by the number of samples. If the samples are correlated though, then we must divide by the effective sample size instead. Loosely speaking, the effective sample size of an estimator of the population mean is the number with the property that our estimator has the same variance as the estimator achieved by sampling the same amount of independent individuals. In our case, two local dimension estimates are independent if their $k$-neighbourhoods do not intersect. Therefore we can (approximately) sample $\frac{n}{2k}$ independent elements from them, and that is our effective sample size. While a specific $A_{ij}$ explicitly excludes certain dimension combinations, it can not exclude a covariance matrix - $\hat{s}$ has positive likelihood given any causal relationship. We assume that the distribution of $\Sigma$ is very peaked at the maximum-likelihood estimate, so much that we regard it to be a Dirac delta, $dP_{\Sigma|A,U}(s|A_{ij},u)=dH(s - \hat{s})$, where $H(\cdot)$ is a multivariate unit step function. Note that $\hat{s}$ is a function of $U$ as well. After incorporating this into the integral and marginalizing we get \begin{equation*} p_{\bar{D}|A}(\bar{d}|A_{ij}) = \int \int_{C_{ij}} \varphi_{\bar{d},\hat{s}}(M_{ij}w) \; dw \; dP_{U}(u). \end{equation*} % In the $A_{ij} = A_{1,1} = \{X < Y = J < Z\}$ case the above would result in \begin{equation*} p_{\bar{D}|A}(\bar{d}|A_{1,1}) = \displaystyle \int \left(\int_{0}^{\infty}\int_{v_1}^{\infty}\int_{v_2}^{\infty} \varphi_{\bar{d},\hat{s}}(w_1, w_2, w_2, w_3) dw_3 \, dw_2 \, dw_1\right) dP_{U}(u). \end{equation*} In the current implementation $U$ consists only of $k$ (the neighbourhood size, which is discrete uniform), therefore integrating by $U$ practically boils down to averaging. The other $A_{i,j} \in \mathcal{A} $ cases can be treated similarly. \section{Supplementary Methods} \subsection{Analysis work-flow} Our proposed causality analysis method starts with two time series. First both time series must undergo data cleaning: one has to make sure that the data is stationary (which can be checked for example with an augmented Dickey-Fuller unit root test) and that the observational noise is dealt with (for example with a filter). Transforming the series to stationary ones is non-trivial and usually depends on the scientific field, requiring much attention and field expertise - by choosing a wrong transformation precious information may be lost or artefacts are introduced, biasing the final results. For example differentiating the time series may remove too much information, using moving averages to smooth the series introduces higher autocorrelation, or calculating current source density with non-disjoint sets of signals to remove correlation (which only indicates first-order relationship) may introduce higher-order dependence. Another important phase of preprocessing is normalization: if the two time series have different scale (or magnitude), then the results of the dimension estimation will become biased. This is easy to see, for example if values of $X$ are around 1 while values of $Y$ are around 100, then the dimension estimation of $X$ and $Y$ will be correct, but since $J = (X,Y)$, or $J = aX + Y$, the k-NN distances will be the same in $J$ and $Y$, dominating the effects of $X$. There are several ways one can normalize the data, e.g. [0,1]-scaling, z-scores, quantile normalization (or rank normalization), etc. The preprocessed time series are embedded into an $m$ dimensional space with lag $\tau$, according to Takens' theorem. Both $m$ and $\tau$ are parameters of our model that have to be specified. Takens showed that $m = 2d + 1$ (where $d$ is the true dimension) is a sufficient choice for the embedding dimension in order to reconstruct dynamics, but unfortunately the true dimension is usually unknown - one may have to consult with a field expert who has sufficient knowledge about the dynamical system at hand and can give a proper estimation of the true dimension. If this is not possible, one can use several methods proposed in the literature for the selection of $m$. The correct value of $m$ can be determined by searching for a plateau (saturation effect) in invariant quantities (such as intrinsic dimensionality) or by using the false nearest neighbour method \cite{Cao1997, Rhodes1997}. We applied an iterative process, starting with a high embedding dimension and decreasing it, checking the estimated manifold dimensions after each decrease and selecting the lowest possible $m$ which did not reduce estimated $d$ value sharply. Takens says that $m = 2d +1$ is a sufficient choice, but that does not mean that smaller $m < 2d+1$ can not be acceptable, this depends on the system. In general \cite{Casdagli1991} the self-intersections do not alter the estimated manifold dimension if $m > d$. In finite samples it is common that dimension estimates increase as the embedding dimension increases, therefore in general it is better to select $m$ as low as possible. The optimal value of $\tau$ can be determined from the first zero point of the autocorrelation function or from the first minima of automutual-information function \cite{Fraser1986}. Additionally, one can optimize for $m$ and $\tau$ at once by applying differential geometric arguments or using the statistical properties of dimension estimates calculated on embedded data \cite{Nichkawde2013,Tamma2016}, or determine an optimal embedding window \cite{Small2004} $(m-1)\tau$. In order to find optimal $\tau$ we analysed the partial autocorrelation function (PACF) of the time series and selected the largest significant lag (which is how one would fit an autoregressive model). The first insignificant lag in the autocorrelation function (ACF) could be used as well, but we found PACF more effective in practice. The largest significant lag of PACF as embedding delay results in relatively independent (moderately redundant) coordinates, but still not too independent (irrelevance) to reconstruct dynamics. The ACF may diminish very slowly, resulting in very large $\tau$, or for example if it is monotonic and we select the first insignificant lag we exclude the linear and their induced non-linear relationships. On the other hand, the largest significant lag in PACF tells us which is the largest lag where there is no direct linear relationship, but non-linear relationships induced by these linear ones remain (think of the classical partial correlation example when there is direct linear relationship between $t_1$ and $t_2$, $t_2$ and $t_3$, and therefore a quadratic between $t_1$ and $t_3$). Given the two $m$ dimensional embedded manifolds of the series, $X$ and $Y$, the joint $J$ and independent $Z$ manifolds are created as well. For this purpose one can either choose direct products or additive observation function ($aX + Y$). We advise the usage of additive observation function, since (as we have shown) the two result in equivalent relationships between manifold dimensions, yet direct products produce higher dimensional product spaces where dimension estimation becomes more-and-more unreliable. Our experience showed that $a=\sqrt{\frac{29}{31}}$ is a good choice in general, because it ensures that the scale of the series do not change too much. In some cases the embedded manifolds may have to undergo further transformations. For example continuous dynamics (like a Lorenz system) evolve rather slowly and in a thread-like manner - if one does not choose a sufficiently large neighbourhood when estimating the local dimension at a point the manifold may seem one-dimensional, because the nearest points will all lie on the same thread. This effect is similar to sampling a slow process with too high frequency. This may be handled by down-sampling the manifold, which means re-sampling it with a lower frequency. The (post-processed) manifolds are used to estimate local dimensions, for which we use an estimator proposed by Farahmand, Szepesvári and Audibert \cite{Szepesvari2007}. Their estimator has one parameter, $k$, the size of the neighbourhood around a point in which the dimension will be estimated. Depending on the system this estimator may be sensitive to this parameter, therefore we try several values and aggregate the results (as described in the previous section). As stated before, dimension estimation is rather hard and local estimates may be quite far from the actual dimension. To handle this one should remove the outliers from the estimates. We advise to trim the dimension estimates, simply by dropping those that belong to the upper or lower $\alpha$-percent tail. At this point all the data is available for estimating model probabilities, as described in the previous section. We repeat this process for a range of $k$-s, then assuming a uniform prior over them we get the final model probabilities by practically averaging the probability of each model for each $k$ out. \subsection{Empirical results} \noindent{\bf Logistic maps.} For testing purposes we applied the DC method on systems of three-coupled logistic maps with various connectivity patterns. The logistic map is a simple non-linear discrete-time dynamical system, which serves as a model for various economic and ecosystems and can (re)produce chaotic behaviour even in one dimension. It is defined as \begin{equation} x_j[t+1] = r x_j[t] (1 - \sum \beta_{jl} x_l[t]), \label{eq:logmapNonLin} \end{equation} % where $r=3.99$, $j, l \in \lbrace 1, 2, 3 \rbrace$ is the index for the three variables and $\beta_{jl}$ are the elements of the coupling matrix ($\underline{\underline{B}}$) according to an actual coupling scenario: \begin{enumerate}[(a)] \item Direct coupling: \[ \underline{\underline{B}} = \begin{bmatrix} 1 & 0 & 0 \\ \beta_{21} & 1 & 0 \\ 0 & 0 & 1 \\ \end{bmatrix} \] \item Circular coupling: \[ \underline{\underline{B}} = \begin{bmatrix} 1 & \beta_{12} & 0 \\ \beta_{21} & 1 & 0 \\ 0 & 0 & 1 \\ \end{bmatrix} \] \item Common cause case: \[ \underline{\underline{B}} = \begin{bmatrix} 1 & 0 & \beta_{13} \\ 0 & 1 & \beta_{23} \\ 0 & 0 & 1 \\ \end{bmatrix} \] \item Independent case: \[ \underline{\underline{B}} = \begin{bmatrix} 1 & 0 & 0 \\ 0 & 1 & 0 \\ 0 & 0 & 1 \\ \end{bmatrix} \] \end{enumerate} where $\beta_{12}=\beta_{21}=\beta_{13}=\beta_{23}=0.5$ in the example shown in the main text. We simulated unidirectional, circularly causal, independent and hidden common cause connection patterns (Fig.\,1) with $N=10000$ time series length. Only two subsystems were observed, the activity of the third subsystem was hidden. We preprocessed time series data by applying a rank normalization. We set model-parameters and applied the DC method on logistic map datasets. We set embedding delay to $\tau=1$ and we found that embedding dimension $m=4$ was big enough in all cases. The probabilities were averaged over the neighbourhood sizes $k=[12,44]$, where the dimension-estimates were constant. DC was able to reconstruct the original coupling pattern between the observed logistic maps for all test cases, curiously it was able to detect hidden common cause between the two observed logistic maps. The performance of the DC method was evaluated on simulated coupled logistic maps. Each of the causal scenarios Eqs.\ \eqref{indep}--\eqref{hcc} was simulated 100 times with randomly chosen system parameters (uniformly sampled in the range $r \in [3.6, 4.0)$, $\beta \in [0.1, 0.5)$, coupling $\beta_{i,j}$ and $\beta_{j,i}$ allowed to differ if multiple driving present). Realizations with short cyclic behavior, i.e., poor coverage of the possible state space were replaced with new simulation. More precisely, we replaced the simulations where any value displayed using 6 decimal digits was present more than 12 times. Data scale was set so that the 16th and 84th percentiles (that means 1 std.\ dev.\ range in the case of the standard normal distribution) lie at $-1$ and $+1$ respectively. Then iid.\ Gaussian observation noise was added with variable amplitude. Due to the scaling this implies a relative noise level. These simulated noisy time series were then embedded in $m=3$ dimensions with $\tau=1$. Dimensional causality method was run with a sensible $k$ range ($k\in(2, k_{max})$ with $k_{max}=32, 42, 52, 110, 210$ for data length $100, 300, 1000, 3000, 10000$ respectively). For each realization and each $k$ the effective sample size was estimated using the maximum likelihood method. Likelihood of all five possible outcomes was calculated for $n_\mathrm{eff}$ assumed on a 20-grade log-equidistant scale between 1 and $N$. The $n_\mathrm{eff}$ yielding the largest value individual likelihood was kept. The largest likelihood could appear among any of the five predictions. Causal inference was calculated based on the chosen $n_\mathrm{eff}$. The classification performance is measured with the accuracy score: the number of correct predictions divided by the number of test cases, see Fig.\ \ref{fig:robustness} in the main text. In order to test the effect of a hidden common drive to Sugihara's CCM method, two types of coupling were applied: The case of non-linear coupling corresponds to equation (\ref{eq:logmapNonLin}), however the form for linear coupling is slightly different: \begin{equation} x_j[t+1] = r x_j[t] (1 - x_j[t]) +\sum \beta_{jl} x_l[t] \label{eq:logmapLin} \end{equation} Sugihara et al. \cite{Sugihara2012} stated that high values of CCM measure which is independent of the data length is a sign of hidden common cause. High CCM for short data series are typical for highly correlated data series. Similarly, Harnack et al.\cite{harnack2017topological} apply the existence of the correlation without detectable direct causality to reveal hidden common cause. Our simulation results show that the above described properties of CCM hold only for those cases in which the hidden common cause is linearly coupled to the observed variables, thus it implies higher linear correlation ($r=0.46$) among them (Extended Data Fig.\,1, blue and green lines). If the hidden common driver is non-linearly coupled to the observed time series, thus the implied correlation is low ($r=0.15$), the CCM increases with the increasing data length but still remains low (Extended Data Fig.\,1, black and red lines). We conclude that the data length dependence of the CCM or the presence of correlation without causality does not allow us to reveal or distinguish the existence of a hidden common cause reliably, the CCM presumably follows only the linear correlation between the two driven variable in this case. Note that the DC method was tested and works well on the non-linearly coupled coupled case as well. % \newline\newline \noindent{\bf Lorenz systems.} There are several ways to couple three Lorenz-systems - we implement the coupling through their $X$ coordinate such that \begin{equation*} \begin{array}{l} \dot{X_1} = \sigma (Y_1 - X_1) + c_{2 \rightarrow 1}(Y_1 - X_2) + c_{3 \rightarrow 1}(Y_1 - X_3), \\ \dot{Y_1} = X_1 (\rho - Z_1) -Y_1, \\ \dot{Z_1} = X_1 Y_1 - \beta Z_1, \\ \\ \dot{X_2} = \sigma (Y_2 - X_2) + c_{1 \rightarrow 2}(Y_2 - X_1) + c_{3 \rightarrow 2}(Y_2 - X_3), \\ \dot{Y_2} = X_2 (\rho - Z_2) - Y_2, \\ \dot{Z_2} = X_2 Y_2 - \beta Z_2, \\ \\ \dot{X_3} = \sigma (Y_3 - X_3), \\ \dot{Y_3} = X_3 (\rho - Z_3) - Y_3, \\ \dot{Z_3} = X_3 Y_3 - \beta Z_3, \end{array} \end{equation*} % where $(X_i, Y_i, Z_i)$ are the three coordinates of the $i^{th}$ system, $\sigma, \rho$ and $\beta$ are model parameters, and $c_{i \rightarrow j}$ denotes the strength of coupling from the $i^{th}$ system to the $j^{th}$ system. For the simulations we set $\sigma = 10$, $\rho = 28$, $\beta = 8/3$, $\Delta t = 0.01$. The initial conditions are $X_1(0) = 10$, $Y_1(0) = 15$, $Z_1(0) = 21.1$, $X_2(0) = 17$, $Y_2(0) = 12$, $Z_2(0) = 14.2$, $X_3(0) = 3$, $Y_3(0) = 8$, $Z_3(0) = 12.4$, and we take 200,000 samples. The coupling coefficients are chosen for the four cases as follows: \begin{enumerate}[(a)] \item Direct cause: $c_{1 \rightarrow 2} = 3.5$, $c_{2 \rightarrow 1} = c_{3 \rightarrow 1} = c_{3 \rightarrow 2} = 0$, \item Circular cause: $c_{1 \rightarrow 2} = c_{2 \rightarrow 1} = 3.5$, $c_{3 \rightarrow 1} = c_{3 \rightarrow 2} = 0$, \item Hidden common cause: $c_{1 \rightarrow 2} = c_{2 \rightarrow 1} = 0$, $c_{3 \rightarrow 1} = c_{3 \rightarrow 2} = 3.5$, \item Independence: $c_{1 \rightarrow 2} = c_{2 \rightarrow 1} = c_{3 \rightarrow 1} = c_{3 \rightarrow 2} = 0$. \end{enumerate} Our method requires the specification of the following parameters: the embedding dimension $m$, time-delay $\tau$ and a set of integers for different $k$-s for the $k-NN$ search. Takens found that if a manifold has dimension $D$ then $2D + 1$ is a good candidate for the embedding dimension. The dimension of the joint manifold is at most $6$ (the number of state variables). We try to minimize the embedding dimension: we start with $2D+1$ and decrease it as long as the dimension estimates are not forced down. This way we found the following embedding dimensions for the four causal cases: (a) 7, (b) 7, (c) 7 and (d) 5. We select $\tau = 25$ based on the partial autocorrelation function (PACF) of the time series and $k \in [10, 38]$. Due to the threadlike phase space we also apply down-sampling on the reconstructed manifold by keeping only every fourth point. We drop the outlying dimension estimates that belong to the lower or upper 5\% tail. % \newline\newline \noindent{\bf Hindmarsh-Rose systems.} We use three electrically coupled Hindmarsh-Rose neurons where coupling is achieved through their membrane potential ($X$), described by the differential equations \begin{equation*} \def1.5{1.5} \begin{array}{l} \dot{X_1} = Y_1 - a X_1^3 + b X_1^2 - Z_1 + I_1 + c_{2 \rightarrow 1}(X_2 - X_1), \\ \dot{Y_1} = c - d X_1^2 - Y_1, \\ \dot{Z_1} = r_1\left(s\left(X_1 - \chi\right) - Z_1\right), \\ \\ \dot{X_2} = Y_2 - a X_2^3 + b X_2^2 - Z_2 + I_2 + c_{1 \rightarrow 2}(X_1 - X_2), \\ \dot{Y_2} = c - d X_2^2 - Y_2, \\ \dot{Z_2} = r_2\left(s\left(X_2 - \chi\right) - Z_2\right), \\ \\ \dot{X_3} = Y_3 - a X_3^3 + b X_3^2 - Z_3 + I_3 + c_{1 \rightarrow 3}(X_1 - X_3), \\ \dot{Y_3} = c - d X_3^2 - Y_3, \\ \dot{Z_3} = r_3\left(s\left(X_3 - \chi\right) - Z_3\right), \end{array} \end{equation*} % where $a, b, c, d, \chi, r_j, s,$ and $I_j$ are model parameters and $c_{i \rightarrow j}$ denotes the strength of coupling from the $i^{th}$ neuron to the $j^{th}$. Note that the first neuron is coupled into the remaining two, while the second neuron is coupled into the first one, meaning that the second and third neurons are not coupled directly, only through a hidden common driver. Common choices for the parameters are $a = 1$, $b = 3$, $c = 1$, $d = 5$, $s = 4$, $\chi = -1.6$. It is also important that $r_i$ should be in the magnitude of $10^{-3}$ and $I_i \in [-10, 10]$ - we choose $r_1 = 0.001$, $r_2 = r_3 = 0.004$, $I_1 = 2.0$, $I_2 = 2.7$ and $I_3 = 2.4$. The initial conditions are $X_1(0) = 0$, $Y_1(0) = 0$, $Z_1(0) = 0$, $X_2(0) = -0.3$, $Y_2(0) = -0.3$, $Z_2(0) = -0.3$, $X_3(0) = 0.3$, $Y_3(0) = 0.3$ and $Z_3(0) = 0.3$. We take 70,000 samples with time steps $\Delta t = 0.1$ and drop the first 10,000 where the system is still in a burn-in period. The coupling coefficients are chosen for the four cases as follows: \begin{enumerate}[(a)] \item Direct cause: $c_{1 \rightarrow 2} = 0.615$, $c_{2 \rightarrow 1} = c_{1 \rightarrow 3} = 0$, \item Circular cause: $c_{1 \rightarrow 2} = c_{2 \rightarrow 1} = 0.615$, $c_{1 \rightarrow 3} = 0$, \item Hidden common cause: $c_{1 \rightarrow 2} = c_{1 \rightarrow 3} = 0.615$, $c_{2 \rightarrow 1} = 0$, \item Independence: $c_{1 \rightarrow 2} = c_{2 \rightarrow 1} = c_{1 \rightarrow 3} = 0$. \end{enumerate} % In each case we use the observations of the first two neurons, except for the hidden common cause case where we use the second and third neurons. We parametrize the method based on the ideas pointed out in the Lorenz case. We set $k \in [10, 98]$, select $\tau = 5$ based on the PACF of the time-series, and the embedding dimension to be (a) 4, (b) 5, (c) 5, and (d) 3. We drop the lower and upper 5\% of the dimension estimates. % \newline\newline \noindent{\bf Changes of inter-hemispheric connectivity during photo-stimulation.} \noindent{\textit{\textbf{EEG recordings and photo-stimulation.}}} Monopolar recordings were taken with standard electrode arrangement of the 10-20 system by a Brain Vision LLC (Morrisville, NC 27560, USA) EEG device with $500$ Hz sampling frequency from $n=87$ patients and the data was stored by the Vision Recorder software with a $0.1-1000$ Hz bandpass filter enabled (No notch filter). Flashing light stimulation were carried out in a $0.1-29$ Hz range. \noindent{\textit{\textbf{Preprocessing.}}} We computed 2D current source density (CSD) of the EEG signal at the six selected electrode positions ($P3, P4, C3, C4, F3, F4$) to filter out linear mixing between channels \cite{Trongnetrpunya2016}. CSD is roughly proportional to the negative second derivative of the electric potential, so we can represent CSD by the discrete Laplace of the original EEG signal up to a constant factor by the simplified formula: \begin{equation} CSD(x) \propto \sum_{i=1}^N n_{i}^{(x)} - N x \label{equation_csd} \end{equation} % where $x$ is the EEG signal measured at an electrode position, $n_{i}^{(x)}$ is the signal measured at a neighbouring contact point, $N$ is the number of neighbours and $CSD(x)$ is the CSD at $x$. We have to mention that equation \ref{equation_csd} overlooks the non-uniform spatial distances of neighbours. The following neighbourhoods were used for the EEG channels: \begin{enumerate}[-] \item P3: \{C3, T5, O1\} \item P4: \{C4, T6, O2\} \item C3: \{T3, F3, P3\} \item C4: \{T4, F4, P4\} \item F3: \{Fp1, F7, C3\} \item F4: \{Fp2, F8, C4\} \end{enumerate} Medial electrode points (common neighbours) were omitted from the neighbourhoods to avoid the artificial introduction of common cause relations. Moreover $1-30$ Hz band-pass filtering (4th order Butterworth filter) was applied to the CSD signal. From stimulation periods, we used only the $21, 24.5, 26, 29$ Hz) stimulation segments in the analysis, which induced the greatest evoked EEG activity on recording channels. The resulting time series segments were $46760-84907$ samples long for stimulations. Artifactless segments with matching sample sizes were taken as paired control from stimulation-free periods. \noindent{ \textit{\textbf{Model parameters.}}} We determined model parameters embedding delay and embedding dimension empirically as pointed out e.g. in the Lorenz case. Embedding delay was set according to the first insignificant value of PACF on the first dataset, and also a rough screening was made where we applied the method with unrealistically big delays and compared the results with smaller delay values. We assumed that choosing unrealistically big $\tau$ yields erroneous results, and a smaller $\tau$ which yields different result may be a valid choice of the embedding parameter. Both approaches showed that $\tau=5$ was a reasonable value for embedding delay. Embedding dimension was set according to a screening from $D=5$ to $D=14$, $D=7$ as the smallest dimension required for the embedding. The joint manifold ($J'$) was created with $a=1$. % \newline\newline \noindent{\bf Causal connections during epileptic seizure.} \noindent{\textit{\textbf{Electrode implantation and recording.}}} Patients had medically intractable seizures and were referred for epilepsy surgical evaluation. After detailed non invasive EEG, video-EEG and various imaging studies including MRI and PET, he underwent phase 2 invasive video-EEG examination. We used intracranial subdural electrodes (grids and strips) for the localization of epileptogenic zone. In the present study we used the original data obtained along the clinical investigation without any influence by the study. All the patients provided informed consent for clinical investigation and surgeries along institutional review board guidelines, according to the Declaration of Helsinki. The patient underwent subdural strip and grid electrode implantation (AD-TECH Medical Instrument Corp., Racine, WI). Subdural electrodes (10 mm intercontact spacing) were implanted with the aid of neuronavigation and fluoroscopy to maximize accuracy\cite{Eross2009} via craniotomy with targets defined by clinical grounds. Video-EEG monitoring was performed using Brain-Quick System Evolution (Micromed, Mogliano Veneto, Italy). All signals were recorded with reference to the skull or mastoid at 1024 Hz sampling rate. To identify the electrode locations, the patient received an anatomical T1-weighted MPRAGE MRI before electrode implantation as well as a full head CT scan (1mm slices) after electrode implantation. Electrode locations were identified on the postimplantation CT scan using the software BioImage Suite \cite{Duncan2004} (http://www.bioimagesuite.org ). These locations were then mapped to the preimplant MRI via an affine transformation derived from coregistering the preimplant and postimplant MRIs and postimplant MRI and CT scans using FLIRT \cite{Jenkinson2001} and the skull-stripping BET 2 algorithm \cite{Smith2002}, both part of the Oxford Centre for Functional MRI of the Brain (FMRIB) software library (FSL: www.fmrib.ox.ac.uk/fsl ). The reconstructed pial surface was computed from the preimplantation MRI using FreeSurfer \cite{Dale1999} (http://surfer.-nmr.mgh.harvard.edu/) and the electrode coordinates projected to the pial surface \cite{Dykstra2012} to correct for possible brain shift caused by electrode implantation and surgery. Intraoperative photographs and ESM were used to corroborate this registration method. This pial surface projection method has been shown to produce results that are compatible with the electrode locations in intraoperative photographs (median disagreement of approx. 3 mm, \cite{Dykstra2012}). \noindent{\textit{\textbf{Preprocessing.}}} Extracellular local field potential recordings were preprocessed: CSD was computed (at Fl1, Fl2, iP and Fb), 1-30 Hz Fourier filtering (4th order Butterworth filter) and subsequent rank normalization was carried out on the recordings. \noindent{\textit{\textbf{Model parameters.}}} Embedding delay was set to $\tau=11$ samples (according to PACF) and embedding dimension was set to $D=7$. The joint manifold ($J'$) was created with $a=1$. \noindent{\textit{\textbf{Results on multiple seizures and multiple control sections.}}} We examined the causal connectivity with the DC method between the fronto-basal (Fb), frontal(Fl1), frontolateral (Fl2) and inferior-parietal (iP) areas during seizure and interictal control conditions. Our results showed that during epileptic seizures iP was found to be a dominant driver in the network and also the existence of non-observed drivers could be inferred (Extended Data Fig. 2). Connectivities calculated on $18$ seizures showed various connection patterns: in $6$ cases iP was a driver in the network, in $1$ case Fb was a driving Fl1, in $1$ case Fb and Fl2 were circularly coupled and the remaining $10$ cases the nodes were driven by unobserved common cause. During interictal control conditions Fb was found to be the dominant node (Extended Data Fig. 3). Connectivities were calculated on $16$ control periods showed that Fb was playing a driver role in the network. Additionally in $5$ cases iP also drove the other nodes, in $2$ cases Fl1 was a driver of Fl2, and in many cases circular connections were present between the nodes.
\section{Modeling Difference Description Generation} We propose a neural model for describing visual difference based on the input pair of images that uses latent alignment variable to capture visual salience. Since most descriptions talk about higher-level differences rather than individual pixels, we first perform a visual analysis that pre-computes a set of difference clusters in order to approximate object-level differences, as described next. The output of this analysis is treated as input to a neural encoder-decoder text generation model that incorporates a latent alignment variable and is trained on our new dataset. \subsection{Exposing Object-level Differences} We first analyze the input image pair for the pixel-level differences by computing a \emph{pixel-difference mask}, followed by a local spatial analysis which segments the difference mask into clusters that approximate the set of object-level differences. Thereafter, we extract image features using convolutional neural models and use these as input to a neural text generation model, described later. \\ \noindent \textbf{Pixel-level analysis:} The lowest level of visual difference is individual differences between corresponding pixels in the input pair. Instead of requiring our description model to learn to compute pixel-level differences as a first step, we pre-compute and directly expose these to the model. Let $X=(\boldsymbol{I_1}, \boldsymbol{I_2})$ represent the image pair in a datum. For each such image pair in our dataset, we obtain a corresponding pixel-difference mask $\boldsymbol{M}$. $M$ is a \emph{binary-valued} matrix of the same dimensions (length and width) as each of the images in the corresponding image pair, wherein each element in the matrix is 1 (active) if the corresponding pixel is \emph{different} between the input pair, and 0 otherwise. To decide whether a pair of corresponding pixels in the input image pair are sufficiently \emph{different}, we calculate the $L_2$-distance between the vectors corresponding to each pixel's color value (three channels) and check whether this difference is greater than a threshold $\delta$ (set based on manual inspections). While the images are extracted from supposedly still cameras, we do find some minor shifts in the camera alignment, which is probably due to occasional wind but may also be due to manual human interventions. These shifts are rare and small, and we align the images in the pair by iterating over a small range of vertical and horizontal shifts to find the shift with minimum corresponding $L_2$-distance between the two images. \\ \begin{figure} \captionsetup{font=footnotesize} \centering \includegraphics[width=0.42\textwidth]{Figures/running/diff_clustering.png} \caption{ Exposing Object-level Differences: Before training a model to describe visual difference, we first compute pixel-level differences, as well as a segmentation of these differences into clusters, as a proxy for exposing object-level differences. The first row shows the original image pair. Bottom left depicts the pixel-difference mask, which represents extracted pixel-level differences. The segmentation of the pixel-difference mask into clusters is shown in the bottom right. } \label{fig:clustering} \end{figure} \noindent \textbf{Object-level analysis:} Most visual descriptions refer to object-level differences rather than pixel-level differences. Again, rather than requiring the model to learn to group pixel differences into objects, we attempt to expose this to the model via pre-processing. As a proxy for object-level difference, we segment the pixel-level differences in the pixel-difference mask into clusters, and pass these clusters as additional inputs to the model. Based on manual inspection, we find that with the right clustering technique, this process results in groupings that roughly correspond to objects that have moved, appeared, and disappeared between the input pair. Here, we find that density based clustering algorithms like DBScan \cite{ester1996density} work well in practice for this purpose. In our scenario, the DBScan algorithm predicts clusters of nearby active pixels, and marks outliers consisting of small groups of isolated active pixels, based on a calculation of local density. This also serves as a method for pruning any noisy pixel differences which may have passed through the pixel-level analysis. As the output of DBScan, we obtain segmentation of the pixel difference matrix $M$ into \emph{difference clusters}. Let the number of \emph{difference clusters} be represented by $K$ (DBScan is a non-parametric clustering method, and as such the number of clusters $K$ is different for each data point.). Now, let's define $\boldsymbol{C_k}$ as another binary-valued mask matrix such that the elements in matrix corresponding to the $k^{th}$ difference cluster are 1 (active) while rest of the elements are 0. \begin{figure} \captionsetup{font=footnotesize} \centering \includegraphics[width=0.48\textwidth]{Figures/running/alignment.png} \caption{ The figure shows the \emph{pixel-difference} mask for the running example, along with the two original images, with bounding boxes around clusters. Typically one or more difference clusters are used to frame one reported difference / sentence, and it is rare for a difference cluster to participate in more than one reported difference. } \label{fig:alignment} \end{figure} \subsection{Text Generation Model} We observe from annotated data that each individual sentence in a full description typically refers only to visual differences within a single cluster (see Figure~\ref{fig:alignment}). Further, on average, there are more clusters than there are sentences. While many uninteresting and \emph{noisy} pixel-level differences get screened out in preprocessing, some uninteresting clusters are still identified. These are unlikely to be described by annotators because, even though they correspond to legitimate visual differences, they are not visually salient. Thus, we can roughly model description generation as a cluster selection process. \def1{1.05} \begin{table}[t] \centering \small \begin{tabular}{|lcl|} \hline $X$$=$($I_1$,$I_2$) &: &Image pair in the datum \\[0.1em] $M$ &: &Pixel-difference mask is a binary-valued \\ && matrix depicting pixel-level changes \\[0.1em] $F_1, F_2$ &: &Image feature tensors for $I_1$ and $I_2$ \\ && respectively \\[0.1em] $K$ &: &Number of segments \\[0.1em] $C_k$ &: &Cluster mask corresponding to $k^{th}$ \\ && difference cluster \\[0.1em] $T$ &: &Number of reported differences / \\ && sentences \\[0.1em] $z_i$ &: &Discrete alignment variable for the $i^{th}$ \\ && sentence. $z_i \in \{1,2,...,K\}$ \\[0.1em] $S_1,..,S_{T}$ &: &List of T Sentences \\ \hline \end{tabular} \caption{Summary of notation used in description of the method.} \label{tab:notation} \end{table} \def1{1} In our model, which is depicted in Figure~\ref{fig:arch}, we assume that each output description, which consists of sentences $S_1, \ldots, S_T$, is generated sentence by sentence conditioned on the input image pair $X=(I_1,I_2)$. Further, we let each sentence $S_i$ be associated with a latent alignment variable, $z_i \in \{1, \ldots, K\}$, that chooses a cluster to focus on \cite{vinyals2015pointer}. The choice of $z_i$ is itself conditioned on the input image pair, and parameterized in a way that lets the model learn which types of clusters are visually salient and therefore likely to be described as sentences. Together, the probability of a description given an image pair is given by: \begin{multline} \label{eqn:marg} P(S_1,..,S_T|X) \\ = \sum_{z_1,..,z_T} \prod_{i=1}^{T} \underbrace{P(S_i|z_i,X;\theta))}_\text{decoder} \underbrace{P(z_i|X; w)}_\text{alignment prior} \end{multline} The various components of this equation are described in detail in the next few sections. Here, we briefly summarize each. The term $P(z_i|X;w)$ represents the prior over the latent variable $z_i$ and is parameterized in a way that lets the model learn which types of clusters are visually salient. The term $P(S_i|z_i,X;\theta)$ represents the likelihood of sentence $S_i$ given the input image pair and alignment $z_i$. We employ masking and attention mechanisms to encourage this decoder to focus on the cluster chosen by $z_i$. Each of these components conditions on visual features produced by a pre-trained image encoder. The alignment variable $z_i$ for each sentence is chosen independently, and thus our model is similar to IBM Model 1 \cite{brown1993mathematics} in terms of its factorization structure. This will allow tractable learning and inference as described in Section~\ref{ssec:learning}. We refer to our approach as \textsc{DDLA} (\textbf{D}ifference \textbf{D}escription with \textbf{L}atent \textbf{A}lignment). \\ \begin{figure*} \captionsetup{font=footnotesize} \centering \includegraphics[width=0.66\textwidth]{Figures/architecture.png} \caption{Model architecture for generating difference descriptions. We incorporate a discrete latent variable $z$ which selects one of the clusters as a proxy for object-level focus. Conditioned on the cluster and visual features in the corresponding region, the model generates a sentence using an LSTM decoder. During training, each sentence in the full description receives its own latent alignment variable, $z$. } \label{fig:arch} \end{figure*} \noindent \textbf{Alignment prior:} We define a learnable prior over alignment variable $z_i$. In particular, we let the multinomial distribution on $z_i$ be parameterized in a log-linear fashion using feature function $g(z_i)$. Specifically, we consider the following four features: the length, width, and area of the smallest rectangular region enclosing cluster $z_i$, and the number of active elements in mask $C_{z_i}$. Specifically, we let $P(z_i|X;w) \propto \exp(w^T g(z_i))$. \\ \noindent \textbf{Visual encoder:} We extract images features using ResNet \cite{he2016deep} pre-trained on Imagenet data. Similar to prior work \cite{xu2015show}, we extract features using a lower level convolutional layer instead of fully connected layer. In this way, we obtain image features of dimensionality $14*14*2096$, where the first two dimensions correspond to a grid of coarse, spatially localized, feature vectors. Let $F_1$ and $F_2$ represent the extracted feature tensors for $I_1$ and $I_2$ respectively. \\ \noindent \textbf{Sentence decoder:} We use an LSTM decoder \cite{hochreiter1997long} to generate the sequence of words in each output sentence, conditioned on the image pair and latent alignments. We use a matrix transformation of the extracted image features to initialize the hidden state of the LSTM decoder for each sentence, independent of the setting of $z_i$. Additionally, we use an attention mechanism over the image features at every decoding step, similar to the previous work \cite{xu2015show}. However, instead of considering attention over the entire image, we restrict attention over image features to the cluster mask determined by the alignment variable, $C_{z_i}$. Specifically, we project binary mask $C_{z_i}$ from the input image dimensionality (224*224) to the dimensionality of the visual features (14*14). To achieve this, we use pyramid reduce down-sampling on a smoothed version of cluster mask $C_{z_i}$. The resulting projection roughly corresponds to the subset of visual features with the cluster region in their receptive field. This projection is multiplied to attention weights. \subsection{Learning and Decoding \label{ssec:learning}} Learning in our model is accomplished by stochastic gradient ascent on the marginal likelihood of each description with alignment variables marginalized out. Since alignment variables are independent of one another, we can marginalize over each $z_i$ separately. This means running backpropagation through the decoder $K$ times for each sentence, where $K$ is the number of clusters. In practice $K$ is relatively small and this direct approach to training is feasible. Following equation \ref{eqn:marg}, we train both the generation and prior in an end-to-end fashion. For decoding, we consider the following two problem settings. In the first setting, we consider the task of producing a single sentence in isolation. We evaluate in this setting by treating the sentences in the ground truth description as multiple reference captions. This setting is similar to the typical image captioning setting. In the second setting, we consider the full multi-sentence generation task where the system is required to produce a full description consisting of multiple sentences describing all differences in the input. Here, the generated multi-sentence text is directly evaluated against the multi-sentence annotation in the crowd-soured data. \\ \noindent \textbf{Single-sentence decoding:} For single sentence generation, we first select the value of $z_i$ which maximizes the prior $P(z_i|X;w)$. Thereafter, we simply use greedy decoding to generate a sentence conditioned on the chosen $z_i$ and the input image pair. \\ \noindent \textbf{Multi-sentence decoding:} Here, we first select a set of clusters to include in the output description, and then generate a single sentence for each cluster using greedy decoding. Since typically there are more clusters than sentences, we condition on the ground truth number of sentences and choose the corresponding number of clusters. We rank clusters by decreasing likelihood under the alignment prior and then choose the top $T$. \section{Introduction} \begin{figure} \centering \captionsetup{font=footnotesize} \begin{subfigure}{\textwidth} \includegraphics[width=0.48\textwidth]{Figures/running/data.png} \end{subfigure} \\ \begin{subfigure}{\textwidth} \captionsetup{font=footnotesize} \includegraphics[width=0.48\textwidth]{Figures/example2.png} \end{subfigure} \caption{ Examples from Spot-the-diff dataset: We collect text descriptions of all the differences between a pair of images. Note that the annotations in our dataset are exhaustive wrt differences in the two images i.e. annotators were asked to describe all the visible differences. Thus, the annotations contain multi-sentence descriptions. } \label{fig:image_eg} \end{figure} The interface between human users and collections of data is an important application area for artificial intelligence (AI) technologies. Can we build systems that effectively interpret data and present their results concisely in natural language? One recent goal in artificial intelligence has been to build models that are able to interpret and describe visual data to assist humans in various tasks. For example, image captioning systems \cite{vinyals2015show,xu2015show,rennie2017self, zhang2017actor} and visual question answering systems \cite{antol2015vqa,lu2016hierarchical,xu2016ask} can help visually impaired people in interacting with the world. Another way in which machines can assist humans is by identifying meaningful patterns in data, selecting and combining salient patterns, and generating concise and fluent `human-consumable' descriptions. For instance, text summarization \cite{mani1999advances,gupta2010survey,rush2015neural} has been a long standing problem in natural language processing aimed at providing a concise text summary of a collection of documents. In this paper, we propose a new task and accompanying dataset that combines elements of image captioning and summarization: the goal of `spot-the-diff' is to generate a succinct text description of \emph{all} the salient differences between a pair of similar images. Apart from being a fun puzzle, solutions to this task may have applications in assisted surveillance, as well as computer assisted tracking of changes in media assets. We collect and release a novel dataset for this task, which will be potentially useful for both natural language and computer vision research communities. We used crowd-sourcing to collect text descriptions of differences between pairs of image frames from video-surveillance footage \cite{oh2011large}, asking annotators to succinctly describe \emph{all} salient differences. In total, our datasets consist of descriptions for 13,192 image pairs. Figure \ref{fig:image_eg} shows a sample data point - a pair of images along with a text description of the differences between the two images as per a human annotator. There are multiple interesting modeling challenges associated with the task of generating natural language summaries of differences between images. First, not all low-level visual differences are sufficiently salient to warrant description. The dataset presents an interesting source of supervision for methods that attempt to learn models of visual salience (we additionally conduct exploratory experiments with a baseline salience model, as described later). Second, humans use different levels of abstraction when describing visual differences. For example, when multiple nearby objects have all moved in coordination between images in a pair, an annotator may refer to the group as a single concept (e.g. `the row of cars'). Third, given a set of salient differences, planning the order of description and generating a fluent sequence of multiple sentences is itself a challenging problem. Together, these aspects of the proposed task make it a useful benchmark for several directions of research. Finally, we experiment with neural image captioning based methods. Since salient differences are usually described at an object-level rather than at a pixel-level, we condition these systems on a first-pass visual analysis that exposes clusters of differing pixels as a proxy for object-level differences. We propose a model which uses latent discrete variables in order to directly align difference clusters to output sentences. Additionally we incorporate a learned prior that models the visual salience of these difference clusters. We observe that the proposed model which uses alignment as a discrete latent variable outperforms those that use attention alone. \section{Conclusion} In this paper, we proposed the new task of describing differences between pairs of similar images and introduced a corresponding dataset. Compared to many prior image captioning datasets, text descriptions in the `Spot-the-diff' dataset are often multi-sentence, consisting of all the differences in two similar images in most of the cases. We performed exploratory analysis of the dataset and highlighted potential research challenges. We discuss how our 'Spot-the-diff' dataset is useful for tasks such as language vision alignment, referring expression comprehension, and multi-sentence generation. We performed pixel and object level preprocessing on the images to identify clusters of differing pixels. We observe that the proposed model which aligns clusters of differing pixels to output sentences performs better than the models which use attention alone. We also discuss some limitations of current methods and scope for future directions. \section*{Acknowledgements} We are thankful to anonymous EMNLP reviewers for their valuable suggestions. We thank Eric Nyberg for discussions on dataset collection. We also acknowledge Nikita Duseja and Varun Gangal for helping with the proof-reading of the paper. We thank \newcite{Luo2017} for releasing a PyTorch implementation of many popular image captioning models. This project was supported in part by a Adobe Research gift. Opinions and findings in this paper are of the authors, and do not necessarily reflect the views of Adobe. \section{`Spot-the-diff' Task and Dataset} We introduce `spot-the-diff' dataset consisting of 13,192 image pairs along with corresponding human provided text annotations stating the differences between the two images. Our goal was to create a dataset wherein there are meaningful differences between two similar images. To achieve this, we work with image frames extracted from VIRAT surveillance video dataset \cite{oh2011large}, which consists of 329 videos across 11 frames of reference totalling to about 8.5 hours of videos. \subsection{Extracting Pairs of Image Frames} To construct our dataset, we first need to identify image pairs such that some objects have changed positions or have entered or left in the second image compared to the first image. To achieve this, we first extract a certain number of randomly selected image frame pairs from a given video. Thereafter, we compute the $L_2$ distance between the two images in each pair (under RGB representation). Finally, we set a lower and a upper threshold on the $L_2$ distance values so calculated to filter out the image pairs with potentially too less or too many changes. These thresholds are selected based on manual inspection. The resulting image pairs are used for collecting the difference descriptions. \begin{table}[] \captionsetup{font=small} \small \centering \begin{tabular}{|c|c|} \hline \begin{tabular}{c} Total number of annotations \\ \end{tabular} & $13,192$ \\ \hline \begin{tabular}{c} Mean (std dev.) number \\ of sentences per annotation \end{tabular} & $1.86 (1.01)$ \\ \hline \begin{tabular}{c} Vocabulary size \end{tabular} & $2404$ \\ \hline \begin{tabular}{c} Frequent word types \\ ($>=$5 occurrences) \end{tabular} & $1000$ \\ \hline \begin{tabular}{c} Word tokens that are \\ frequent word types \end{tabular} & $97\%$ \\ \hline \begin{tabular}{c} Mean (std dev.) number \\ of words in sentence: \end{tabular} & $10.96 (4.97)$ \\ \hline \begin{tabular}{c} \% Long sentences \\ ($>20$ words) \end{tabular} & $5\%$ \\ \hline \end{tabular}\caption{Summary statistics for spot-the-diff dataset} \label{table:data} \end{table} \subsection{Human Annotation} \begin{SCfigure*}[] \captionsetup{font=small} \centering \includegraphics[width=0.76\textwidth]{Figures/amt/amt_setup.png} \caption{AMT (Amazon Mechanical Turk) HIT (Human Intelligence Task) setup for data collection. We provide the annotators with detailed instructions, along with an example showing how to perform the task. We request the annotators to write complete English sentences, with each sentence on a separate line. We collect a total of 13,192 annotations. } \label{fig:amt_setup} \end{SCfigure*} We crowd-sourced natural language differences between images using Amazon Mechanical Turk. We restrict to annotators from primarily Anglophone countries: USA, Australia, United Kingdom, and Canada, as we are working with English language annotations. We limit to those participants which have lifetime HIT $>80\%$. We award 5 cents per HIT (Human Intelligence Task) to participants. We provide the annotators with an example on how to work on the task. We request the annotators to write complete English sentences, with each sentence on a separate line. We collect a total of 13192 annotations. \begin{table}[] \centering \small \begin{tabular}{ccc} \begin{tabular}{c} \textbf{Dataset} \end{tabular} & \textbf{BLEU-1/2/3/4} & \textbf{ROUGE-L} \\ \hline \begin{tabular}{c} Spot-the-diff \\ ($A=3$) \end{tabular} & $0.41/0.25/0.15/0.08$ & $0.31$ \\ \hline \begin{tabular}{c} MS-COCO \\ ($A=3$) \end{tabular} & $0.38/0.22/0.13/0.08 $ & $0.34$ \\ \hline \begin{tabular}{c} MS-COCO \\ ($A=5$) \end{tabular} & $0.66/0.47/0.32/0.22$ & $0.48$ \\ \hline \end{tabular} \caption{ \footnotesize Human agreement for our dataset: We report measures such as BLEU and ROUGE when `evaluating' one set of human generated captions against the remaining sets. $A=k$ represents $k$ captions per data point, out of which 1 is chosen as hypothesis, while remaining $k-1$ act as references. } \label{table:agreement} \end{table} \subsection{Dataset statistics} Table \ref{table:data} shows some summary statistics about the collected dataset. Since we deal with a focused domain, we observe a small vocabulary size. On an average there are 1.86 reported differences / sentences per image pair. We also report inter-annotator agreement as measured using text overlap of multiple annotations for the same image pair. We collect three sets of annotations for a small subset of the data (467 data points) for the purpose of reporting inter-annotator agreements. We thereby calculate BLEU and ROUGE-L scores by treating one set of annotations as `hypothesis' while remaining two sets act as `references'(Table \ref{table:agreement}). We repeat the same analysis for MS-COCO dataset and report these measures for reference. The BLEU and METEOR values for our dataset seem reasonable and are comparable to the values observed for MS-COCO dataset. \section{Related Work} \noindent \textbf{Modeling pragmatics:} The dataset presents an opportunity to test methods which can model pragmatics and reason about semantic, spatial and visual similarity to generate a textual description of what has changed from one image to another. Some prior work in this direction \cite{andreas2016reasoning, vedantam2017context} contrastively describe a target scene in presence of a distractor. In another related task -- referring expression comprehension \cite{kazemzadeh2014referitgame,mao2016generation,hu2017modeling} -- the model has to identify which object in the image is being referred to by the given sentence. However, our proposed task comes with a pragmatic goal related to summarization: the goal is to identify and describe \emph{all} the differences. Since the goal is well defined, it may be used to constrain models that attempt to learn how humans describe visual difference. \\ \noindent \textbf{Natural language generation:} Natural language generation (NLG) has a rich history of previous work, including, for example, recent works on biography generation \cite{lebret2016neural}, weather report generation \cite{mei2015talk}, and recipe generation \cite{kiddon2016globally}. Our task can viewed as a potential benchmark for coherent multi-sentence text generation since it involves assembling multiple sentences to succinctly cover a set of differences. \\ \noindent \textbf{Visual grounding:} Our dataset may also provide a useful benchmark for training unsupervised and semi-supervised models that learn to align vision and language. \citet{plummer2015flickr} collected annotation for phrase-region alignment in an image captioning dataset, and follow up work has attempted to predict these alignments \cite{wang2016learning,plummer2017phrase,rohrbach2016grounding}. Our proposed dataset poses a related alignment problem: attempting to align sentences or phrases to visual differences. However, since differences are contextual and depend on visual comparison, our new task may represent a more challenging scenario as modeling techniques advance. \\ \noindent \textbf{Image change detection:} There are some works on land use pattern change detection (\cite{radke2005image}). These works are related since they try to screen out noise and mark the regions of change between two images of same area at different time stamps. \newcite{bruzzone2000automatic} propose an unsupervised change detection algorithms aim to discriminate between changed and unchanged pixels for multi-temporal remote sensing images. \newcite{zanetti2016generalized} propose a method that allows unchanged class to be more complex rather than having a single unchanged class. Though image diff detection is part of our pipeline, our end task is to generate natural language descriptors. Moreover, we observe that simple clustering seems to work well for our dataset. \\ \noindent \textbf{Other relevant works:} \newcite{maji2012discovering} aim to construct a lexicon of parts and attributes by formulating an annotation task where annotators are asked to describe differences between two images. Some other related works model phrases describing change in color \cite{winn2018lighter}, move-by-move game commentary for describing change in game state \cite{jhamtani2018learning}, and code commit message summarizing changes in code-base from one commit to another \cite{jiang2017automatically}. There exist some prior works on fine grained image classification and captioning \cite{wah2014similarity,Nilsback06,khosla2011novel}. The premise of such works is that it is difficult for machine to find discriminative features between similar objects e.g. birds of different species. Such works are relevant for us as the type of data we deal with are usually of same object or scene taken at a different time or conditions. \section{Experiments} \begin{table*}[ht] \small \begin{center} \begin{tabular}{c c c c c c c} \hline \textbf{Model} & \textbf{Bleu 1/2/3/4 }& \textbf{Meteor} & \textbf{Cider} & \textbf{Rouge-L} & \textbf{Perplexity} \\ \hline \begin{tabular}{c} \textsc{NN} \end{tabular} & 0.226 0.111 0.057 0.026 & 0.102 & 0.120 & 0.201 & - \\ \begin{tabular}{c}\textsc{CAPT} \end{tabular} & 0.304 0.194 0.126 0.073 & 0.105 & 0.263 & 0.256 & 16.78 \\ \begin{tabular}{c}\textsc{CAPT-masked} \end{tabular} & 0.301 0.200 0.131 0.078 & 0.108 & 0.285 & 0.271 & 15.12 \\ \begin{tabular}{c} \textsc{DDLA-uniform} \end{tabular} & 0.285 0.175 0.108 0.064 & 0.106 & 0.250 & 0.247 & 9.96 \\ \begin{tabular}{c} \textsc{DDLA} \end{tabular} & 0.343 0.221 0.140 0.085 & 0.120 & \textbf{0.328} & 0.286 & 9.73 \\ \hline \end{tabular} \end{center} \caption{\footnotesize \label{table:base01} \textbf{Single sentence decoding:} We report automatic evaluation scores for various models under single sentence generation setting. \textsc{DDLA} model fares better scores than various baseline methods for all the considered measures. Both the \textsc{DDLA} models get much better perplexities than baseline methods. } \end{table*} \begin{table*}[t] \small \begin{center} \begin{tabular}{c c c c c c} \hline \textbf{Model} & \textbf{Bleu 1/2/3/4 }& \textbf{Meteor} & \textbf{Cider} & \textbf{Rouge-L} & \textbf{LenRatio} \\ \hline \begin{tabular}{c}\textsc{NN-multi}\end{tabular} & 0.223 0.109 0.056 0.026 & 0.087 & 0.105 & 0.181 & 1.035 \\ \begin{tabular}{c}\textsc{CAPT-multi} \end{tabular} & 0.262 0.146 0.081 0.045 & 0.094 & 0.235 & 0.174 & 1.042 \\ \begin{tabular}{c}\textsc{DDLA-uniform} \end{tabular} & 0.243 0.143 0.085 0.051 & 0.094 & 0.217 & 0.213 & 0.778 \\ \begin{tabular}{c}\textsc{DDLA} \end{tabular} & 0.289 0.173 0.103 0.062 & 0.108 & \textbf{0.297} & 0.260 & 0.811 \\ \hline \end{tabular} \end{center} \caption{\footnotesize \label{table:para} \textbf{Multi-sentence decoding} We report automatic evaluation scores for various models under multi-sentence generation setting. \textsc{DDLA} model achieves better scores compared to the baseline methods. Note that these scores are not directly comparable with single sentence generation setting. \textbf{LenRatio} is the ratio of the average number of tokens in the prediction to the average number of tokens in the ground truth for the test set. } \end{table*} We split videos used to create the dataset into train, test, and validation in the ratio 80:10:10. This is done to ensure that all data points using images from the same video are entirely in one split. We report quantitative metrics like CIDEr \cite{vedantam2015cider}, BLEU \cite{papineni2002bleu}, METEOR \cite{denkowski2014meteor}, and ROUGE-L, as is often reported by works in image captioning. We report these measures for both sentence level setting and multi-sentence generation settings. Thereafter, we also discuss some qualitative examples. We implement our models in PyTorch \cite{paszke2017automatic}. We use mini-batches of size 8 and use Adam optimize \footnote{Our data set can be obtained through \url{https://github.com/harsh19/spot-the-diff} }. We use CIDEr scores on validation set as a criteria for early stopping. \\ \noindent \textbf{Baseline models:} We consider following baseline models: \textsc{Capt} model considers soft attention over the input pair of images (This attention mechanism is similar to that used in prior image captioning works \cite{xu2015show}, except that we have two images instead of a single image input). We do not perform any masking in case of \textsc{Capt} model, and simply ignore the cluster information. The model is trained to generate a single sentence. Thus, this model is similar to a typical captioning model but with soft attention over two images. \textsc{Capt-mask} model is similar to \textsc{Capt} model except that it incorporates the masking mechanism defined earlier using the union of all the cluster masks in the corresponding image. We also consider a version of the \textsc{Capt} model wherein the target prediction is the whole multi-sentence description -- \textsc{Capt-multi} -- for this setting, we simply concatenate the sentences in any arbitrary order \footnote{Note that we do not provide \textsc{Capt-multi} with ground truth number of sentences}. Additionally, we consider a nearest neighbor baseline (\textsc{NN-multi}), wherein we simply use the annotation of the closest matching training data point. We compute the closeness based on the extracted features of the image pair, and leverage sklearn’s \cite{pedregosa2011scikit} Nearest-Neighbor module. For single sentence setting (\textsc{NN}), we randomly pick one of the sentences in the annotation. We also consider a version of \textsc{DDLA} model with fixed uniform prior, and refer to this model as \textsc{DDLA-uniform} . For single sentence generation, we sample $z_j$ randomly from the uniform distribution and then perform decoding. For the multi-sentence generation setting, we employ simple heuristics to order the clusters at test time. One such heuristic we consider is to order the clusters as per the decreasing area of the bounding box (smallest rectangular area enclosing the cluster). \\ \begin{figure*} \captionsetup{font=footnotesize} \centering \includegraphics[width=0.87\textwidth]{Figures/qualitative/example_newboth.png} \caption{Predictions from various methods for two input image pairs.} \label{fig:output} \end{figure*} \noindent \textbf{Results:} We report various automated metrics for the different methods under single sentence generation and multi-sentence generation in Tables \ref{table:base01} and \ref{table:para} respectively. For the single sentence generation setting, we observe that the \textsc{DDLA} model outperforms various baselines as per most of the scores on the test data split. \textsc{DDLA-uniform} method performs similar to the \textsc{Capt} baseline methods. For the multi-sentence generation, the \textsc{DDLA} model again outperforms other methods. This means that having a learned prior is useful in our proposed method. Figure \ref{fig:output} shows an example data point with predicted outputs by different methods. \section{Discussion and Analysis} \noindent \textbf{Qualitative Analysis of Outputs} We perform a qualitative analysis on the outputs to understand the drawbacks in the current methods. One apparent limitation of the current methods is the failure to explicitly model the movement of same object in the two images (Figure \ref{fig:issue}) -- prior works on object tracking can be useful here. Sometimes the models get certain attributes of the objects wrong. e.g. `blue car' instead of `red car'. Some output predictions state an object to have `appeared' instead of `disappeared' and vice versa. \\ \begin{figure} \captionsetup{font=footnotesize} \centering \includegraphics[width=0.48\textwidth]{Figures/qualitative/tracking_new.png} \caption{Some drawbacks with the current models: One apparent drawback with the single cluster selection is that it misses opportunity to identify an object which has moved significantly- considering it as appeared or disappeared as the case may be. In this example, the blue truck moved, but the \textsc{DDLA} model predicts that the truck is no longer there.} \label{fig:issue} \end{figure} \noindent \textbf{Do models learn alignment between sentence and difference clusters?} We performed a study on 50 image pairs by having two humans manually annotate gold alignments between sentences and difference clusters. We then computed alignment precision for the model's predicted alignments. To obtain model's predicted alignment for a given sentence $S_i$, we compute $argmax_k P(z_i=k|X)P(S_i|z_i=k,X)$. Our proposed model achieved a precision of 54.6\%, an improvement over random chance at 27.4\%. \\ \noindent \textbf{Clustering for pre-processing} Our generation algorithm assumed one sentence uses only one cluster and as such we tune the hyper-parameters of clustering method to get large clusters so that typically a cluster will entirely contain a reported difference. On inspecting randomly selected data points, we observe that in some cases too large clusters are marked by the clustering procedure. One way to mitigate this is to tune clustering parameters to get smaller clusters and update the generation part to use a subset of clusters. As mentioned earlier, we consider clustering as a means to achieve object level pre-processing. One possible future direction is to leverage pre-trained object detection models to detect cars, trucks, people, etc. and make these predictions readily available to the generation model. \\ \noindent \textbf{Multi-sentence Training and Decoding} As mentioned previously, we query the models for a desired number of 'sentences'. In future works we would like to relax this assumption and design models which can predict the number of sentences as well. Additionally, our proposed model doesn't not explicitly ensure consistency in the latent variables for different sentences of a given data point i.e the model does not make explicit use of the fact that sentences report non-overlapping visual differences. Enforcing this knowledge while retaining the feasibility of training is a potential future direction of work.
\section{Introduction}\label{intro} Consider the following game played on $[n] = \{1,\ldots,n\}$ between two players, Namer and Claimer. In each round, Namer names a distance $d \in \mathbb N$, then Claimer claims a subset of the unclaimed vertices which is `$d$-free'; that is, does not contain two points that differ by $d$. Claimer wins once they have claimed the entirety of $[n]$. How quickly can Claimer win with optimal play from both players? It is not too difficult to prove that the length of the game has an order of growth somewhere between $\log \log n$ and $\log n$ (see Section~\ref{sec:greedy}). For several years I have been asking at workshops and open problem sessions (including~\cite{Berlin,AC}) which if either of these values is correct. It turns out that the lower bound is the truth. \begin{theorem}\label{main} The length of the Namer--Claimer game on $[n]$ is $\Theta(\log \log n)$. \end{theorem} In Section~\ref{proof} I give a direct proof of Theorem~\ref{main}. In Section~\ref{ramsey} I describe connections with the Ramsey theory of Hilbert cubes. It is convenient to rephrase the game in graph theoretic language. For $d \in D=[n-1]$, let $G_d$ be the graph on $V = [n]$ with $xy \in E(G_d)$ if and only if $|x-y|=d$. For a subset $A$ of $V$, write $G_d[A]$ for the subgraph of $G_d$ induced by $A$. The \emph{Namer--Claimer game on $\mathcal G = (G_d)_{d \in D}$} proceeds as follows. \begin{itemize} \item Set $A_0 = V$. \item In the $i$th round: \begin{itemize} \item Namer names a $d_i \in D$. \item Claimer selects an independent set $C_i$ of $G_{d_i}[A_{i-1}]$. \item Set $A_i = A_{i-1} \setminus C_i$. \item If $A_i = \emptyset$, then the game ends. Otherwise, continue to the next round. \end{itemize} \end{itemize} The outcome of this process is a partition of $[n]$ into sets $C_1, \ldots, C_k$ such that each $C_i$ is an independent set in $G_{d_i}$. As such, the Namer--Claimer game can be viewed as a finite, online version of the following variant colouring problem. The \emph{upper chromatic number} $\hat\chi(\mathcal G)$ of a family of graphs $\mathcal G = (G_d)_{d \in D}$ on $V$ is the least $k$ such that, for every $(d_1,\ldots, d_k) \in D^k$, there is a partition $V = C_1 \cup \cdots \cup C_k$ such that each $C_i$ is an independent set in $G_{d_i}$. This upper chromatic number was introduced by Greenwell and Johnson~\cite{GJ} for the family of `distance-$d$' graphs on $\mathbb R^n$: $xy$ is an edge of $G_d$ if and only if $\|x-y\|_2=d$. (The term `upper chromatic number' has also been used by Voloshin~\cite{Voloshin} and later authors for an unrelated concept.) Greenwell and Johnson proved that $\hat\chi(\mathbb R) = 3$. This remains the only known value of $\hat\chi(\mathbb R^n)$; it is not even known whether $\hat\chi(\mathbb R^2)$ is finite. See \cite{Abrams1,Archer,Abrams2} for related results. The rules above define a Namer--Claimer game for any finite vertex set $V$ and family $\mathcal G$ of graphs on $V$. One natural instantiation is to take $V$ to be a group $H$ of order $n$, $D = H\setminus\{0\}$ and $G_d = \{\{x,dx\} : x \in H\}$. The $\Omega(\log \log n)$ lower bound from Proposition~\ref{greedy} is still valid in this setting. If $H$ is either cyclic or of the form $C_t^m$ with $t$ fixed, then similar methods to those used here show that Claimer has a strategy to end the game in $O(\log \log n)$ rounds. What happens more generally? \section{Proof of Theorem~\ref{main}}\label{proof} We assume freely for convenience that $n$ is larger than some absolute but unspecified constant, but this constant is not particularly large. \subsection{Greedy bounds}\label{sec:greedy} To prove an upper bound on the length of the game we must give a strategy for Claimer. To prove a lower bound we must give a strategy for Namer. The easiest strategies to analyse are often greedy strategies. There are various ways `the greedy strategy' for each player could be made precise. We shall say that \begin{itemize} \item the \emph{greedy strategy for Claimer} is to take as many points as possible each round; \item the \emph{greedy strategy for Namer} is to name the most commonly occurring distance between the set of remaining points in each round. \end{itemize} \begin{proposition}\label{greedy} By playing their respective greedy strategies, (i) Claimer can win in at most $1 + \log_2 n$ rounds; (ii) Namer can prolong the game at least $(1+o(1))\log_2 \log_2 n$ rounds. \end{proposition} \begin{proof} (i) For any set of unclaimed points $A$ and any $d$, $G_d[A]$ is bipartite, so has an independent set with at least half of the points of $A$. Thus whenever there are $m$ points remaining, Claimer has a move that will leave at most $\lfloor m/2 \rfloor$ points unclaimed. If Claimer always makes such a move, then the game will last at most $1 + \log_2 n$ rounds. (ii) Suppose that in some round the set of unclaimed points is $A$ with $|A| \geq \alpha n \geq 100$. These points determine (with multiplicity) $\binom {\alpha n} 2$ distances. Let $d$ be the most commonly occurring distance. There are $n-1$ possible distances, so $d$ occurs at least \[ \frac {\alpha n(\alpha n-1)} {2(n-1)} = \frac {\alpha^2n \left(n-\frac 1 \alpha\right)} {2(n-1)} \geq \frac{0.99\alpha^2 n} 2 \] times. Thus $G_d[A]$ is a vertex-disjoint union of paths with at least $0.99\alpha^2 n/2$ edges in total. From each path of length $m \geq 1$, Claimer can claim at most $\lceil \frac{m+1} 2 \rceil \leq \tfrac m 2 + 1$ points, so there will be at least $0.99\alpha^2 n/4 \geq \alpha^2 n/5$ unclaimed points going into the next round. Iterating this argument, after $t$ rounds of their greedy strategy starting from $A$, either fewer than $100$ points remain unclaimed, or Namer has defended at least $5(\tfrac \alpha 5)^{2^t}n$ points from being claimed. Taking $\alpha = 1$, the game will last at least until \[ \frac {5}{5^{2^t}}n < 100, \] or $t > \log_2 (\log_5 n - \log_5 20) = (1+o(1))\log_2 \log_2 n$. \end{proof} The proof of the lower bound is almost identical to Gunderson and R\"odl's proof~\cite{GR} of an upper bound for a certain Ramsey number (see Theorem~\ref{ramsey-bounds} in Section~\ref{ramsey}). It is tempting to believe that the upper bound could be tight for powers of $2$. The first counterexample is $n=8$, for which the length of the game is $3$. (This is easy to check exhaustively on a computer.) It is instructive to consider a sequence of optimal play from each side. \newcommand{\claim}[1]{{\color{red}\cancel{#1}}} \[ \begin{array}{ccccccccc} d_1=1 : & \claim{1} & {2} & \claim{3} & {4} & \claim{5} & {6} & {7} & \claim{8} \\ d_2=2 : & & \claim{2} & & {4} & & \claim{6} & \claim{7} & \\ d_3=1 : & & & & \claim{4} & & & & \\ \end{array} \] The `natural' move for Claimer in response to Namer's $d_1=1$ is to take all of the odd (or even) numbers, but following this pattern commits to the game lasting $1 + \log_2 n = 4$ turns. By claiming the less uniform set $\{1,3,5,8\}$ Claimer ensures that there are few repeated distances available for Namer in the next round, allowing them to win sooner. This suggests that Claimer might do better by playing randomly. Indeed, if the set of unclaimed points $A$ is always a random set of density $\alpha$ then all distances appear roughly equally often and the analysis in Proposition~\ref{greedy}(ii) is tight. However, it is not at all clear that this situation can be arranged. For example, suppose that $d_1 = 1$ and that Claimer claims a random maximal independent set of $G_1$ in the first round. Then the set of unclaimed vertices $A_1$ will contain more points at distance $2$ than would be expected in a random set of its density. There are similar dependence problems whenever arithmetic relations hold among the set of named distances. This makes a truly random strategy for Claimer difficult to analyse. In the remainder of this section I'll present a hybrid strategy with a small amount of randomness that proves an upper bound matching the lower bound from Proposition~\ref{greedy} up to a multiplicative constant. \subsection{The lazy strategy} In the \emph{lazy strategy for Claimer}, if the set of unclaimed points is $A$ and Namer names $d$, then Claimer claims all those $x \in A$ such that $x + d \notin A$. Equivalently, Claimer claims the largest element of each path component of $G_d[A]$. This is not a good strategy, but it is very easy to analyse. Indeed, starting from a set of unclaimed points $A_0$ we have \begin{align} A_1 & = A_0 \cap (A_0 - d_1) \nonumber\\ A_2 & = A_1 \cap (A_1 - d_2) = A_0 \cap (A_0 - d_1) \cap (A_0 - d_2) \cap (A_0 - d_1 - d_2)\nonumber\\ & \mathrel{\makebox[\widthof{=}]{\vdots}} \nonumber\\ A_k & = \bigcap_{I \subseteq [k]} \Big(A_0 - \sum_{i \in I} d_i\Big).\label{evolution} \end{align} Hence $x \in A_k$ if and only if \[ H(x; d_1, \ldots, d_k) = \Big\{x + \sum_{i \in I} d_i : I \subseteq [k]\Big\} \subseteq A_0. \] Call such a set a \emph{(Hilbert) cube of dimension $k$}. (The `side lengths' $d_i$ of a Hilbert cube are sometimes assumed to be distinct, but we do not assume this here.) Thus $A_k \neq \emptyset$ if and only if $A_0$ contains a cube of dimension $k$. Unfortuntately, $[n]$ itself is a cube of dimension $n-1$ (with $d_1=\cdots=d_{n-1}=1$), so the lazy strategy only bounds the length of the game by $n$. The proof of the upper bound in Theorem~\ref{main} could be viewed as a series of contortions for improving the bound given by the lazy strategy. \subsection{Introducing randomness} The first idea is to introduce a small, easily controlled, amount of randomness. Claimer begins by choosing a uniformly random partition $[n] = A_0 \cup B_0$, then plays the lazy strategy starting from $A_0$ followed by the lazy strategy starting from $B_0$. The effectiveness of this strategy is determined by the size of the largest cube contained in a random subset of $[n]$. Unfortunately, a random subset of $[n]$ contains intervals of length $\Theta(\log n)$ with high probability, so this strategy proves at best a logarithmic upper bound on the length of the game. This would be an improvement on the naive lazy strategy, but not on the greedy upper bound from Proposition~\ref{greedy}. The second idea is to notice that the cubes causing problems are rather atypical: a cube of dimension $k$ could have up to $2^k$ elements, but the intervals causing problems only have size $k+1$. We would be much happier if the cubes generated by the named distances had the maximum possible size; that is, they are \emph{non-degenerate}. This would be true if the named distances were sufficiently well spaced. \begin{observation}\label{spaced} Let $d_1, \ldots, d_k \in \mathbb N$ with $d_{i+1} \geq 2d_i$ for $1 \leq i \leq k-1$. Then every cube $H(x;d_1,\ldots,d_k)$ is non-degenerate.\qed \end{observation} Non-degenerate cubes are much less likely to appear in random sets. \begin{lemma}\label{proper} Let $k = \lceil \log_2 \log_2 n + 2\log_2 \log_2 \log_2 n\rceil$. Then there is a partition $[n] = A_0 \cup B_0$ such that neither $A_0$ nor $B_0$ contain a non-degenerate cube of dimension $k$. \end{lemma} \begin{proof} Let $A$ be a subset of $[n]$ chosen uniformly at random and let $B = [n] \setminus A$. A cube of dimension $k$ is determined by a choice of $x, d_1, \ldots, d_k$, so the expected number of cubes of dimension $k$ and size $2^k$ in $A$ is at most \begin{align*} n^{k+1}\left(\tfrac 1 2\right)^{2^k} = 2^{(k+1)\log_2 n - 2^k} & \leq 2^{(2 \log_2 \log_2 n)\log_2 n - (\log_2 \log_2 n)^2\log_2 n} = o(1). \end{align*} The same bound holds for $B$, so the probability that either $A$ or $B$ fail to have the desired property is $o(1)$ by Markov's inequality. \end{proof} It follows from Observation~\ref{spaced} and Lemma~\ref{proper} that Claimer has a strategy to win in $2k = O(\log \log n)$ rounds if Namer commits to naming sufficiently well-separated distances. At the other extreme, Namer commits to only ever naming the same distance $1$, say. In this case Claimer wins in only two turns, as they could claim the odd numbers in the first round and the even numbers in the second. We would like to say that some combination of these strategies should handle the entire range of intermediate possibilities. Lemma~\ref{parallel} is one way of making this precise. \begin{lemma}\label{parallel} Let $D_1 \cup \cdots \cup D_m$ be a partition of $[n-1]$ with the following property. Suppose that Claimer has a strategy $\mathcal S$ to win in $k$ rounds if Namer can name at most one distance from each $D_i$, and, for each $i$, a strategy $\mathcal S_i$ to win in $l$ rounds if Namer can name only distances from $D_i$. Then Claimer has a strategy to win in $kl$ rounds. \end{lemma} Crucially, the bound on the performance of the combined strategy does not explicitly depend on $m$. \begin{proof} The first time Namer names a distance from $D_i$, Claimer plays according to $\mathcal S$. Each subsequent time Namer names a distance from $D_i$, Claimer plays according to $\mathcal S_i$. If the game has not yet ended then Claimer has played at most $k-1$ moves in $\mathcal S$ and at most $l-1$ moves in each of the at most $k-1$ stratgies $\mathcal S_i$ in which they have played any moves at all. So Claimer wins in at most $(k-1) + (k-1)(l-1) + 1 = (k-1)l+1$ rounds. \end{proof} It remains to present sets $D_i$ and strategies $\mathcal S, \mathcal S_i$ to which we can apply Lemma~\ref{parallel}. \begin{lemma}\label{strategylets} Let $k = \lceil \log_2 \log_2 n + 2\log_2 \log_2 \log_2 n\rceil$, let $D_1 = \{1,2\}$ and, for $i \geq 2$, let $D_i = [2^{i-1}+1,2^i]$. (i) If Namer can name at most one distance from each $D_i$, then Claimer has a strategy to win in $4k$ rounds. (ii) For each $i$, if Namer can name only distances from $D_i$, then Claimer has a strategy to win in $3$ rounds. \end{lemma} \begin{proof} (i) By Lemma~\ref{proper}, there is a partition $[n] = A_0 \cup B_0$ such that neither $A_0$ nor $B_0$ contains a non-degenerate cube of dimension $k$. For the first $2k$ rounds of the game, Claimer plays the lazy strategy starting from $A_0$. Let $d_1 < \cdots < d_{2k}$ be the named distances. Then by \eqref{evolution}, \[ A_{2k} = \bigcap_{I \subseteq [2k]} \Big(A_0 - \sum_{i \in I} d_i\Big) \subseteq \bigcap_{I \subseteq \{2,4,\ldots,2k\}} \Big(A_0 - \sum_{i \in I} d_i\Big). \] Thus if there is an $x \in A_{2k}$, then $A_0$ contains a cube $H(x;d_2,d_4,\ldots,d_{2k})$. Since the $d_i$ are from distinct $D_i$, for $1 \leq i \leq k-1$ we have $d_{2(i+1)} \geq 2d_{2i}$, whence this cube is non-degenerate by Observation~\ref{spaced}. But there are no such cubes in $A_0$, so $A_{2k}$ must be empty and Claimer claims all of $A_0$ in the first $2k$ rounds. Claimer claims all of $B_0$ in the next $2k$ rounds similarly. (ii) For each $i$, let $A^i_0 \cup A^i_1 \cup A^i_2$ be the partition of $\mathbb N$ with \[ A^i_j = \bigcup_{k=0}^\infty \big([2^{i-1}] + (3k+j)2^{i-1}\big). \] If $d \in D_i$, then no two points of $A^i_j$ differ by $d$, as all distance between points of $A^i_j$ are at most $2^{i-1}$ or at least $2^i+1$. Thus Claimer can claim $A^i_0\cap [n]$ in round $1$, $A^i_1\cap [n]$ in round $2$ and $A^i_2\cap [n]$ in round $3$. \end{proof} The desired upper bound is a direct application of Lemmas~\ref{parallel} and~\ref{strategylets}. \begin{corollary}\label{upper-bound} Claimer has a strategy to win in at most $(1+o(1))12\log_2 \log_2 n$ rounds.\qed \end{corollary} \section{Ramsey theory}\label{ramsey} We might ask whether Lemma~\ref{proper} can be strengthened to provide a partition into pieces that do not contain any Hilbert cubes, degenerate or otherwise. This is precisely a question of Ramsey theory. Write $h(k,r)$ for the least $n$ such that whenever $[n]$ is partitioned into $r$ parts, at least one of the parts contains a cube of dimension $d$. \begin{proposition} \label{use-ramsey} Let $r\geq 2$ and let $k$ be least with $h(k,r) > n$. Then Claimer has a strategy to win in at most $rk$ rounds. \end{proposition} \begin{proof} By the choice of $k$ there is a partition $[n] = A_1 \cup \cdots \cup A_r$ such that no $A_i$ contains a cube of dimension $k$. By following the lazy strategy starting from $A_1$, Claimer can claim all of $A_1$ in at most $k$ rounds. By repeating for each of $A_2, \ldots, A_r$, Claimer wins in at most $rk$ rounds. \end{proof} To apply Proposition~\ref{use-ramsey} we would require lower bounds on $h(k,r)$. The best known bounds for large $r$ are due to Gunderson and R\"odl. \begin{theorem}[{\cite[Theorem~2.5]{GR}}]\label{ramsey-bounds} For $k\geq 3$ and $r \geq 2$, \[ r^{(1+o(1))\frac {2^k-1} k} \leq h(k,r) \leq (2r)^{2^k-1}, \] with $o(1) \to 0$ as $r \to \infty$. \end{theorem} In their proof of the lower bound, Gunderson and R\"odl mostly work with non-degenerate cubes. It is easy to show that a degenerate cube contains an arithmetic progression of length $3$, so they begin by using their own partitioning variant of Behrend's~\cite{Behrend} construction to partition $[n]$ into a large number of parts that do not contain any arithmetic progressions of length $3$. As a result, $r \geq \exp(\Omega(\sqrt{\log n}))$, and the bounds obtained from Proposition~\ref{use-ramsey} are extremely poor. For small $r$, a random $r$-partition along the lines of Lemma~\ref{proper} shows that $h(k,r) \geq r^{\Omega(k)}$. Nothing better is known. For the variant problem where we only want to avoid cubes with distinct side lengths this was strenghtened to $r^{\Omega(k^2)}$ by Conlon, Fox and Sudakov, using an inverse Littlewood--Offord theorem of Tao and Vu~\cite{TaoVu} to characterise cubes with far fewer than $2^k$ elements. For all of the known Ramsey-type results, the major difficulties are presented by non-degenerate cubes. Corollary~\ref{upper-bound} is stronger than the bound following from Proposition~\ref{use-ramsey} because we were able to avoid considering degenerate cubes at the modest cost of increasing our bound on the length of the game by a factor of $6$. \newenvironment{acknowledgements} {\renewcommand\abstractname{Acknowledgements}\begin{abstract}} {\end{abstract}} \begin{acknowledgements} \noindent I would like to thank James Aaronson, Joshua Erde and Julia Wolf for helpful discussions. \end{acknowledgements}
\section{Introduction} The discrete ordered median problem (\DOMP) represents a generalization of several well-known discrete location problems, such as p-median, $p$-center or $(k_{1}+k_{2})-$trimmed mean, among many others. \DOMP provides a very flexible tool in accommodating actual aspects, as subsidized or compensation costs, in models of Logistics and Location, see \citet{Puerto1999} and \citet{Nickel2005}. \rev{The} ordered median objective function computes ordered weighted averages of vectors. \rev{In the case when that objective function is applied to location problems, those vectors correspond to distances or allocation costs from clients to service facilities.} This way many different objective functions are cast within the same framework and the same tools can be used to solve problems with apparently different structure. The problem was introduced in \citet{Nickel2001} and later studied by \cite{Kalcsics2003}, \cite{Nickel2005}, \citet{Boland2006}, \cite{Stanimirovic2005}, \cite{Marin2009} and \citet{BHP2014} among many other papers. \DOMP is an NP-hard problem as an extension of the p-median problem. \cite{Nickel2001} first presented a quadratic integer programming formulation for the \DOMP. However, no further attempt to deal directly with this formulation was ever considered. Furthermore, that approach was never exploited in trying to find alternative reformulations or bounds; instead several linearizations in different spaces of variables have been proposed to solve \DOMP some of them being rather promising, \citet{Marin2009} and \citet{Labbe2016}. Motivated by the recent advances in conic optimization and the new tools that this branch of mathematical programming has provided for developing bounds and approximation algorithms for NP-hard problems, as for instance \rev{the max-cut problem and the quadratic assignment problem (QAP)} among others \citep{Burer2015}, we would like to revisit that earlier approach to \DOMP with the aim of proposing an alternative reformulation \rev{of the problem} as a continuous, linear conic optimization problem. Our interest is mainly theoretical and tries to borrow tools from continuous optimization to be applied in some discrete problems in the field of \rev{Location Analysis (L.A.).} To the best of our knowledge reformulations of that kind have never been studied before for \DOMP nor even in the wider field of L.A. The goal of this paper is to prove that a natural binary, quadratically constrained, quadratic formulation for \DOMP \, \rev{ admits a reformulation as a continuous, linear optimization problem} over the cone of completely positive matrices $\mathcal{C}^*$. Recall that a symmetric matrix $M\in \mathbb{R}^{n\times n}$ is called completely positive if it can be written as $M=\sum_{i=1}^k x_i x_i^t$ for some finite $k\in \mathbb{N}$ and \rev{$x_i\in \mathbb{R}^n_+$} for all $i=1,\ldots,k$. The paper is organized as follows. Section \ref{ss:def} formally defines the ordered median problem and sets its elements. Section \ref{ss:sorting} is devoted to describe a folk result that formulates the problem of sorting numbers as a feasibility binary linear program. This is used later as a building block to present the binary quadratic, quadratically constrained formulation of \DOMP. Section \ref{s:codomp} contains the main result in this paper: \DOMP is equivalent to a continuous, linear conic \rev{optimization} problem. Obviously, there are no shortcuts and the problem remains $NP$-hard but it allows us to shed some light onto the combinatorics of this difficult discrete location problem. Moreover, it permits \rev{to apply also some tools from continuous optimization on} the area of discrete L.A. The last section, namely Section \ref{s:remarks} contains some conclusions and pointers to future research. \section{Definition and formulation of the problem} \subsection{Problem definition \label{ss:def}} Let $S=\{1,...,n\}$ denote the set of $n$ sites. Let $C=(c_{j\ell})_{j,\ell=1,...,n}$ be \rev{a given nonnegative $n\times n$ cost matrix,} where $c_{j\ell}$ denotes the cost of satisfying demand point (client) $j$ from a facility located at site $\ell$. We also assume the so called, \textit{free self-service} situation, namely $c_{jj}=0$ for all $j=1,\ldots,n$. Let $p<n$ be the desired number of facilities to be located at the candidate sites. A solution to the facility location problem is given by a set $\X\subseteq S$ of $p$ sites. The set of solutions to the location problem is therefore finite, although exponential in size, and it coincides with the $n \choose p$ subsets of size $p$ of $S$. We assume, that each new facility has unlimited capacity. Therefore, each client $j$ will be allocated to a facility located at site $\ell$ of $\X$ with lowest cost, i.e. $$ c_{j}=c_{j}(\X):=\min_{\ell\in \X} c_{j\ell}. $$ The costs for supplying clients, $c_{1}(\X), . . . , c_{n}(\X)$, are sorted in nondecreasing order. We define $\sigma_{\X}$ to be a permutation on $\{1, . . . , n\}$ for which the inequalities $$ c_{\sigma_{\X}(1)}(\X)\leq\cdots\leq c_{\sigma_{\X}(n)}(\X) $$ hold. Now, for any nonnegative vector $\lambda\in \mathbb{R}^n_+$, \DOMP consists of finding $\X^*\subset S$ with $|\X^*|=p$ such that: $$\sum_{k=1}^n \lambda_k c_{\sigma_{\X^*}(k)}(\X^*)=\min _{\X\subset S, |\X|=p} \sum_{k=1}^n \lambda_k c_{\sigma_{\X}(k)}(\X).$$ \subsection{Sorting as an integer program and a binary quadratic programming formulation of \DOMP\label{ss:sorting}} For the sake of readability, we describe in the following a folk result that allows us to understand better the considered binary quadratic programming formulation for \DOMP. Let us assume that we are given $n$ real numbers $r_1, \ldots, r_n$ and that we are interested in finding its sorting in nondecreasing sequence as a solution of a mathematical program. One natural way to do it is to identify the permutation that ensures such a sorting. We can introduce the following \textit{ordering} variables $$ P_{jk} =\left\{ \begin{array}{ll} 1\quad \text{ if the number $r_j$ is sorted in the $k$-th position}, \; j,k =1,\ldots,n, \\ 0\quad \text{ otherwise}. \end{array} \right. $$ Next, we can consider the following feasibility problem: \begin{align} \min \quad & 1 \nonumber \tag{\textbf{SORT}}\\ \mbox{s.t. } & \sum_{j=1}^{n} P_{jk} = 1& \forall k&=1,\dots,n \label{sort:const1}\\ & \sum_{k=1}^{n} P_{jk} = 1& \forall j&=1,\dots,n \label{sort:const2}\\ & \sum_{j=1}^n P_{jk} r_j \leq \sum_{j=1}^n P_{j,k+1} r_j& \forall k & =1,\ldots, n-1 \label{sort:const3} \\ & P_{jk} \in \{0,1\}& \forall j,k&=1,\dots,n. \nonumber \end{align} Clearly, constraints (\ref{sort:const1}) and (\ref{sort:const2}) model permutations and constraint (\ref{sort:const3}) ensures the appropriate order in any feasible solution since the number in sorted position $k$ must be smaller than or equal to the one in position $k+1$. Now, we can insert in this formulation the elements of \DOMP. Indeed, we have to replace the given real numbers $r_1,\dots,r_n$ by the allocation costs induced by the location problem. Let $X$ and $\y$ be the natural allocation and location variables in the location problem, namely $$ X_{j\ell} =\left\{ \begin{array}{ll} 1\quad \text{ if the demand point $j$ goes to the facility $\ell$}, \; j,\ell =1,\ldots,n,\\ 0\quad \text{ otherwise}, \end{array} \right. $$ \noindent and $$ \y_{\ell} =\left\{ \begin{array}{ll} 1\quad \text{ if a new facility is opened at site $\ell$,}\; \ell=1,...,n, \\ 0\quad \text{ otherwise}. \end{array} \right. $$ Based on the above variables, it follows that the cost induced by the allocation of the demand point $j$ will be given by $\sum_{\ell =1}^n c_{j\ell}X_{j\ell}$. Thus, if we want a valid formulation of \DOMP we can embed the location elements into the SORT formulation. This results in the following formulation (see \citep{Nickel2001}): \begin{align} \min & \displaystyle \sum_{k=1}^n \lambda_k \sum_{j=1}^n P_{jk}\sum_{\ell =1} ^n c_{j \ell} X_{j\ell} \label{pro:comb-ofp}\tag{MIQP-DOMP}\\ s.t. & \displaystyle\sum_{j=1}^n P_{jk}=1 & \forall k=1,\dots,n \label{pro:comb1p}\\ &\displaystyle\sum_{k=1}^n P_{jk}=1 & \forall j=1,\dots,n \label{pro:comb2p}\\ &\displaystyle\sum_{j=1}^{n}\left(\sum_{\ell=1}^{n}c_{j\ell} X_{j\ell}\right)P_{jk} \le \sum_{j=1}^{n}\left(\sum_{\ell=1}^{n}c_{j\ell} X_{j\ell}\right)P_{jk+1},& \forall k=1,\ldots,n-1, \label{pro:comb3p}\\ &\displaystyle\sum_{\ell=1}^n \y_{\ell}=p \label{pro:comb4p}\\ &\displaystyle\sum_{\ell=1}^n X_{j\ell}=1 & \forall j=1,\dots,n \label{pro:comb5p}\\ &\y_{\ell}\geq X_{j\ell} & \forall j,\ell=1,\dots,n \label{pro:comb6p}\\ &\rev{P_{jk},X_{j\ell},\y_j \in\{0,1\},} & \forall j,k,\ell=1,\dots,n \label{pro:combdp} \end{align} Clearly, the objective function accounts for the ordered weighted sum of the allocation costs so that the cost sorted in position $k$, in a given feasible solution, is multiplied by $\lambda_k$ for all $k=1,\ldots,n$. Constraint (\ref{pro:comb1p}) states that each position in the sequence from $1$ to $n$ will be occupied by one of the realized allocation costs; whereas constraint (\ref{pro:comb2p}) ensures that each allocation cost will be in one position between $1,\ldots,n$. Constraint (\ref{pro:comb3p}) states that the cost in position $k$ must be less than or equal to the one in position $k+1$. With constraint (\ref{pro:comb4p}) it is fixed that $p$ facilities are open. Constraint (\ref{pro:comb5p}) forces that each demand point is allocated to one facility and constraint (\ref{pro:comb6p}) ensures that demand points can be assigned only to open facilities. Finally, (\ref{pro:combdp}) sets the range of the variables. Based on our discussion, the above quadratically constrained, quadratic objective function is a valid formulation for \DOMP. We note in passing that one could relax the binary definition of the variables $\y_j\in \{0,1\}$ to simply nonnegativity, namely $\y_j\ge 0$, \rev{since boundedness of $\y$ is ensured by (\ref{pro:comb4p}) and its binary character is forced by (\ref{pro:comb6p}). Therefore, in what follows $\y$ variables will be considered just nonnegative.} \section{A completely positive reformulation of \DOMP\label{s:codomp}} The goal of this section is to developed a new reformulation for \DOMP as a continuous linear \rev{optimization} problem in the cone of completely positive matrices $\mathcal{C}^*$. For this reason, we consider $X$, $P$ and $\y$ as the original variables of the problem. These variables are standard in the already known formulations for \DOMP. For ease of presentation we use the following notation. By $P_{i\cdot}$ and $X_{i\cdot}$ for all $i=1,\ldots,n$, we refer, respectively, to the $i-th$ row of $P$ and $X$. That is, \rev{the row vector} $P_{i\cdot}=(P_{i1},\ldots,P_{in})$ and \rev{the row vector} $X_{i\cdot}=(X_{i1},\ldots,X_{in})$. We will also follow the following convention. We refer to original variables in capital letters. Slack variables used to transform inequalities to equations, in the formulations, will be denoted by the Greek letters $\zeta$, $\xi$, $\eta$. Finally, \rev{the elements of} matrix variables will be denoted by small letters. For instance, if $U=(u_{ij})$ is a matrix variable we refer to its elements as $u_{ij}$. In the following the \textit{vec} operator stacks in a column vector the columns of a matrix and the \textit{rvec} operator stacks in a column vector the rows of a matrix. Clearly, $rvec(A)=vec(A^T)$, i.e. \textit{rvec} acting on a matrix $A$ is equivalent to $vec$ acting on the transpose of $A$. \rev{The $Diag$ operator maps a $n-$vector to a $n\times n$ diagonal matrix and the $diag$ operator extracts in a $n$-vector the diagonal of a $n\times n$-square matrix.} We follow the convention that all \rev{single-index} variables in our formulations are column vectors. In the sequel rather than considering the standard version of \DOMP in the literature of L.A., described above, we will consider an extended version of that problem because it permits to include more realistic aspects in the model. These modeling aspects come from the interaction between the different elements in the problems. \rev{That is, this extended model} includes some extra interaction terms among the ordering variables ($P_{jk}P_{j'k'}$) and the allocation variables ($X_{j\ell}X_{pq}$). Let $D=(d_{jkj'k'})\in \mathbb{R}^{n^2\times n^2}$, where $d_{jkj'k'}$ is the interaction cost \rev{of} sorting demand point $j$ in position $k$ and demand point $j'$ in position $k'$. Moreover, let $H=(h_{j\ell pq})\in \mathbb{R}^{n^2\times n^2}$, where $h_{j\ell pq}$ is the cost incurred due to the allocation of demand points $j$ and $p$ to facilities $\ell$ and $q$, respectively, see e.g. \citet{BURKARD1984283}. The reader should observe that in the standard version of \DOMP in the literature the cost matrices $D$ and $H$ satisfy \rev{$D=H=\Theta$, where $\Theta$ is the zero matrix.} In spite of the greater complexity coming from including new quadratic terms in the objective function, the tools that we will use in the following can be accommodated to the extended version of the problem with no extra effort. The above discussion means that in what follows we will consider the following objective function for \ref{pro:comb-ofp}. \begin{align} \min & \displaystyle \sum_{k=1}^n \lambda_k \sum_{j=1}^n P_{jk}\sum_{\ell =1} ^n c_{j \ell} X_{j\ell} +1/2 \sum_{j=1}^n\sum_{k=1}^n\sum_{j'=1}^n\sum_{k'=1}^n d_{jkj'k'}P_{jk}P_{j'k'} \nonumber \\ & +1/2\sum_{j=1}^n\sum_{\ell=1}^n\sum_{p=1}^n\sum_{q=1}^n h_{j\ell pq}X_{j\ell}X_{pq} \label{pro:comb-ofp-ext} \end{align} Clearly, the objective function (\ref{pro:comb-ofp-ext}) accounts for the ordered weighted sum of the allocation costs so that the cost sorted in position $k$, in a given feasible solution, is multiplied by $\lambda_k$ for all $k=1,\ldots,n$, plus the interaction costs induced by the ordering and the allocations. This objective function replaces the usual one in \ref{pro:comb-ofp} and allows us a more general analysis of the problem. Our goal is to find new ways to represent the problem that \rev{may shed some light into the structure of the difficult combinatorics of \DOMP that combine elements from the p-median, the quadratic assignment (QAP) and the permutation polytopes}. We show in the following that it is possible to cast \DOMP within the field of linear continuous conic optimization and we derive an explicit reformulation. Furthermore, we emphasize that this result is not straightforward. \rev{Contrary to the case of quadratic objective and linear constrained problems with some binary variables, where one can apply Burer's results \citep[Theorem 2.6]{Burer09}; the above formulation is quadratic in the objective, in the constraints and also includes binary variables; and in our case the most recent, known sufficient conditions for obtaining conic reformulations do not directly apply \citep{Burer2012,BURER2012203,Pena2015,Bai2016}.} In all cases, those results require some nonnegativity condition of the considered quadratic constraints on the feasible region of the problem. \rev{This condition cannot be ensured in our problem since the constraints (\ref{pro:comb3p}), namely $\displaystyle\sum_{j=1}^{n}\left(\sum_{\ell=1}^{n}c_{j\ell} X_{j\ell}\right)P_{jk} \le \sum_{j=1}^{n}\left(\sum_{\ell=1}^{n}c_{j\ell} X_{j\ell}\right)P_{jk+1},\; \forall k=1,\ldots,n-1$, can assume any sign on the feasible solutions of the problem.} In spite of that, we prove in our main result that such a \rev{reformulation} does exist for \DOMP. Thus, it links this problem to the general theory of convex conic programming as a new instance of this broad class of problems. \rev{As a result, any new development arising in that optimization field (convex conic programming), could be readily transferred to the combinatorial problem advancing in its better understanding.} The interested reader is referred to \cite{Dur10}, \cite{Bomze12}, \cite{Burer2012} and \cite{XuBurer2016} for a list of \rev{combinatorial} problems that also fits to this framework. In our approach we first reformulate \ref{pro:comb-ofp} as another quadratically constrained, quadratic problem that is instrumental in the construction of \rev{the final copositive reformulation for \DOMP, that is the main goal of this paper.} \rev{We start by slightly modifying the formulation above to replace the set of inequalities (\ref{pro:comb6p}) by an equivalent set with smaller cardinality.} \begin{propo} \label{prop:surrogate} Let us assume that the set of inequalities (\ref{pro:comb1p})-(\ref{pro:combdp}) hold. Then, the set of inequalities (\ref{pro:comb6p}) can be replaced by \begin{equation} \rev{\sum_{j=1}^n X_{j\ell}-(n-p +1)\y_{\ell} \le 0,\; \quad \forall \ell=1,\ldots,n } \label{pro:comb6pmod} \end{equation} resulting in the same feasible set. \end{propo} \begin{proof} {\rm Indeed, let us assume that (\ref{pro:comb6p}) holds together with the remaining inequalities in the formulation \ref{pro:comb-ofp}. We shall prove that (\ref{pro:comb6pmod}) also holds. We sum $X_{j\ell}\le \y_{\ell}$ for all $j=1...,n$ which results in \begin{equation} \sum_{j=1}^n X_{j\ell}\le n\y_{\ell}. \label{expl:1} \end{equation} Next, we observe that since we assume all costs to be nonnegative and there is no capacity constraints for the allocation of demand points to facilities then for each $\y_{\hat \ell}=1$ the corresponding $X_{\hat \ell \hat \ell}=1$ as well; that is, the demand point at $\hat \ell$ will be served by the facility at the same location. Since there are $p$ open facilities, there exist $\y_{\ell_1}=1,\ldots,\y_{\ell_p}=1$. This implies that in any sum of the form $\sum_{j=1}^n X_{j\ell}\le n\y_{\ell}$ there must be at least $p-1$ variables $X_{\ell_j\ell}=0$, {\red if} $\ell_j\neq \ell$, since by (\ref{pro:comb4p}) there are, at least, $p-1$ open facilities different from $\ell$ (even if facility at $\ell$ happens to be open). The above argument implies that, whenever $\y_{\ell}=1$ in (\ref{expl:1}), we can subtract $p-1$ units from the right-hand-side of the inequality, (obviously, this also holds if $\y_\ell=0$) resulting in (\ref{pro:comb6pmod}). Conversely, let us assume that (\ref{pro:comb6pmod}) replaces (\ref{pro:comb6p}) in the above formulation. We have to prove that (\ref{pro:comb6p}) still holds. Clearly if $\y_{\ell}=0$ then it follows that $X_{j\ell}=0$ for all $j=1,\ldots,n$. Besides, if $X_{j\ell}$=1 for some $j$ then $\y_{\ell}=1$ because otherwise (\ref{pro:comb6pmod}) would not hold. Finally, if $\y_{\ell}=1$ or $X_{j\ell}=0$ for all $j=1,\ldots,n$, (\ref{pro:comb6p}) holds trivially. This proves that (\ref{pro:comb6pmod}) implies (\ref{pro:comb6p}) in the formulation above.} \hfill $\Box$ \end{proof} \rev{In our development we follow the approach by \cite{Burer09} but we need to introduce modifications to go around the problematic quadratic constraint (\ref{pro:comb3p}) that does not fit within that framework. In order to do that, } we introduce an additional set of variables $W_k$, $k=1,\dots,n$ which will represent the value of the cost that is sorted in position $k$. This means that $W_k=\sum_{j=1}^{n}\left(\sum_{\ell=1}^{n}c_{j\ell} X_{j\ell}\right)P_{jk}$ and although these variables are redundant they will simplify the presentation in our approach. \rev{Adding these equations for all $k=1,\ldots,n$, it results in another valid constraint, namely $ \sum_{k=1}^n W_k= \sum_{j=1}^n\sum_{\ell=1}^n c_{j\ell} X_{j\ell}$, that we will also include in our formulation.} The following result provides a reformulation of \ref{pro:comb-ofp} that is an important building block in the proof of the main result. \begin{lemma} \rev{Problem \ref{pro:comb-ofp2} is a reformulation of Problem \ref{pro:comb-ofp}.} \begin{align} \min & \displaystyle \sum_{k=1}^n \lambda_k W_k +1/2\sum_{j=1}^n\sum_{k=1}^n\sum_{j'=1}^n\sum_{k'=1}^n d_{jkj'k'}P_{jk}P_{j'k'} \nonumber \\ & +1/2\sum_{j=1}^n\sum_{\ell=1}^n\sum_{p=1}^n\sum_{q=1}^n h_{j\ell pq}X_{j\ell}X_{pq} \label{pro:comb-ofp2}\tag{MIQP1-DOMP}\\ s.t. & \eqref{pro:comb1p},\eqref{pro:comb2p}, \eqref{pro:comb4p}, \eqref{pro:comb5p}, \nonumber \\ & \rev{\sum_{j=1}^n X_{j\ell}-(n-p +1)\y_{\ell} +\zeta_\ell = 0,\; \quad \forall \ell=1,\ldots,n \label{pro:comb6pmodeq}}\\ & W_k- \displaystyle\sum_{\ell=1}^n c_{j\ell}\, X_{j\ell}+\displaystyle\sum_{\ell =1}^n c_{j\ell}(1-P_{jk}) - \eta_{jk}=0,\quad \forall j,k=1,\dots,n \label{pro:comb1p8}\\ & \displaystyle W_k=\sum_{j=1}^n P_{jk}\sum_{\ell =1} ^n c_{j \ell} X_{j\ell},\quad \forall k=1,\ldots,n \label{pro:comb1p2}\\ & \sum_{j=1}^n\sum_{k=1}^n (P_{jk}-P_{jk}^2)=0 \label{pro:comb2p2}\\ & \rev{\sum_{j=1}^n\sum_{\ell=1}^n (X_{j\ell}-X_{j\ell}^2)=0 \label{pro:combq2p2}}\\ & W_k - W_{k+1} +\xi_k=0,\quad \forall k=1,\dots,n-1 \label{pro:comb1p3}\\ & \rev{\displaystyle\sum_{k=1}^n W_k-\displaystyle\sum_{j=1}^n \displaystyle\sum_{\ell =1}^n c_{j\ell}\, X_{j\ell}=0, \label{pro:comb1p7}}\\ &P_{jk},X_{j\ell}\in\{0,1\}, \; \y_j, W_k, \xi_j,\eta_{jk}, \zeta_\ell \ge 0, \quad \forall j,k,\ell=1,\dots,n \label{pro:combdp1} \end{align} \end{lemma} \begin{proof} {\rm In order to get the formulation in the statement of the lemma, we begin by considering an intermediate reformulation of \ref{pro:comb-ofp} which results by substituting constraints \eqref{pro:comb6p} by the equivalent family $\sum_{j=1}^n X_{j\ell}- (n-p+1)\y_{\ell}+\zeta_l=0$, $\ell= 1,\ldots,n$, namely \eqref{pro:comb6pmodeq}, that was already proved in Proposition \ref{prop:surrogate} and augmenting the variables $W_k=\sum_{j=1}^n P_{jk}\sum_{\ell =1} ^n c_{j \ell} X_{j\ell}$, for all $k=1,\ldots,n$ \eqref{pro:comb1p2}. \rev{In addition, we add three redundant constraints. The first two are quadratic, namely $\sum_{j=1}^n\sum_{k=1}^n (P_{jk}-P_{jk}^2)=0$ \eqref{pro:comb2p2} and $\sum_{j=1}^n\sum_{\ell=1}^n (X_{j\ell}-X_{j\ell}^2)=0$ \eqref{pro:combq2p2}; and the third is linear $\sum_{k=1}^n W_k-\sum_{j=1}^n \sum_{\ell =1}^n c_{j\ell}\, X_{j\ell}=0$ \eqref{pro:comb1p7}. These three constraints will be instrumental in our developments.} All the above changes do not alter the optimal solutions of \ref{pro:comb-ofp}. We write the new problem explicitly for the sake of readability. Starting from \ref{pro:comb-ofp}, with the new objective function (\ref{pro:comb-ofp-ext}), we perform the transformation described above and the new formulation is: \begin{align} \min & \displaystyle \sum_{k=1}^n \lambda_k W_k +1/2\sum_{j=1}^n\sum_{k=1}^n\sum_{j'=1}^n\sum_{k'=1}^n d_{jkj'k'}P_{jk}P_{j'k'} \nonumber \\ & +1/2\sum_{j=1}^n\sum_{\ell=1}^n\sum_{p=1}^n\sum_{q=1}^n h_{j\ell pq}X_{j\ell}X_{pq} \label{pro:comb-ofp1}\tag{MIQP2-DOMP}\\ s.t. & \eqref{pro:comb1p},\eqref{pro:comb2p}, \eqref{pro:comb3p}, \eqref{pro:comb4p}, \eqref{pro:comb5p}, \eqref{pro:comb6pmodeq},\eqref{pro:comb1p2}, \eqref{pro:comb2p2}, \eqref{pro:combq2p2}, \eqref{pro:comb1p7}, \nonumber \\ &P_{jk},X_{j\ell},\y_j\in\{0,1\}, \; W_k,\zeta_{\ell} \ge 0 & \forall j,k,\ell=1,\dots,n \label{pro:combdp1} \end{align} \ref{pro:comb-ofp1} is a mixed-$\{0,1\}$ quadratically constrained, quadratic objective \rev{problem}. From this formulation, we can obtain the one in the statement of the lemma by: 1) reformulating constraints (\ref{pro:comb3p}) as $W_k- W_{k+1}-\xi_k=0$ for all $k=1,\ldots,n-1$, \eqref{pro:comb1p3}, and; 2) \rev{adding to the formulation the valid inequalities} (\ref{pro:comb1p8}), i.e $ W_k- \displaystyle\sum_{\ell=1}^n c_{j\ell}\, X_{j\ell}+\displaystyle\sum_{\ell =1}^n c_{j\ell}(1-P_{jk}) - \eta_{jk}=0,\quad \forall j,k=1,\dots,n$. We observe that the constraint (\ref{pro:comb1p8}) is valid by the following argument. First of all, if $P_{jk}=0$ then (\ref{pro:comb1p8}) reduces to $W_k\ge \sum_{\ell=1}^n c_{j\ell} (X_{j\ell}-1)$ which always holds since $W_k\ge 0$ and $X_{j\ell}\le 1$ for all $\ell=1,\ldots,n$. Second, if $P_{jk}=1$ then the allocation cost of demand point $j$ goes in sorted position $k$ ($P_{jk}$ are the ordering variables) and then $W_k$ must be the allocation cost of the actual allocation of demand point $j$ to the open facility $\ell$, namely $W_k\ge \sum_{\ell=1}^k c_{j\ell} X_{j\ell}$. Augmenting these constraints to \ref{pro:comb-ofp1}, it results exactly in \ref{pro:comb-ofp2} and the result follows. \hfill $\Box$ } \end{proof} Additionally and for the sake of readability we will introduce, in the sequel, the following notation. We set the entire family of variables of the problem \ref{pro:comb-ofp2} as the column vector $\phi$ given by \begin{equation} \label{def:phi} \phi^T=(rvec(P)^T,rvec(X)^T,\y^T,W^T,\xi^T,rvec(\eta)^T,\zeta^T). \end{equation} Recall that we assume that all single-index variables, namely $\y,W,\xi,\zeta$, are column vectors. Furthermore, to alleviate the notation, we will denote the vector of coefficients of a constraint numbered as $(\#)$, in the formulation \ref{pro:comb-ofp2}, by $[a_{(\#)}]$. If the reference $(\#)$ defines, for instance, a set of constraints for all $\ell=1,\ldots,n$ then we refer to the $\ell-th$ constraint in that set by $[a_{(\#)}]_\ell$. For instance, $[a_{(\ref{pro:comb1p})}]_1$ refers to the first equation of constraints (\ref{pro:comb1p}) which is $\sum_{j=1}^n P_{j1}=1$. Next, we consider the matrix form $\Phi=\phi\phi^T$ that is symmetric and its upper triangular part is given by: \begin{equation} \label{eq:Phi} \begin{tabular}{rl} & \begin{tabular}{p{8mm}p{8mm}p{8mm}p{8mm}p{6mm}p{8mm}p{6mm}} \hspace*{4mm} $n^2$ & \hspace*{1mm} $n^2$ & \hspace*{1mm} $n$ & \hspace*{-2mm} $n$ & \hspace*{-4mm} $n$ & \hspace*{-4mm} $n^2$ & \hspace*{-5mm} $n$ \end{tabular} \\ $\Phi=$ & $\left[\begin{array}{ccccccc} {\overbrace{Q}} & \overbrace{V} & \overbrace{P\y} & \overbrace{PW} & \overbrace{P\xi} & \overbrace{P\eta} & \overbrace{P\zeta} \\ & U &X\y & XW & X\xi & X\eta & X \zeta \\ & & \Sigma & \y W & \y \xi & \y \eta & \y \zeta \\ & & &\Omega & W \xi & W \eta & W \zeta \\ & & & & \Psi & \xi \eta & \xi \zeta \\ & & & & & \Pi & \eta \zeta \\ & & & & & & \mathcal{Z} \end{array}\right] \in \mathbb{R}^{(3n^2+4n)\times (3n^2+4n)}$ \end{tabular} \end{equation} Each entry in $\Phi$ is a block of variables. The different submatrices in $\Phi$ are described below: \rev{$$Q= rvec(P) rvec(P)^T=\left[ \begin{array}{c} rvect(P) P_{11}\\ \vdots \\ rvect(P) P_{nn} \end{array} \right]=(q_{ikj\ell})\in \mathbb{R}^{n^2\times n^2}.$$ There exist structural conditions on the product of variables $P_{ik}P_{j\ell}$ since $diag(Q)=rvect(P)$.} The matrix $U$ is analogous replacing $P$ by $X$. Thus, \rev{$$U= rvec(X) rvec(X)^T=\left[ \begin{array}{c} rvect(X) X_{11}\\ \vdots \\ rvect(X) X_{nn} \end{array} \right]=(u_{ikj\ell})\in \mathbb{R}^{n^2\times n^2}.$$ There also exist structural conditions on the product of variables $X_{ik}X_{j\ell}$ since $diag(U)=rvect(X)$.} Next, the matrix $V$ is \rev{$$V= rvec(P) rvec(X)^T=\left[ \begin{array}{c} rvect(X) P_{11}\\ \vdots \\ rvect(X) P_{nn} \end{array} \right]=(v_{ikj\ell})\in \mathbb{R}^{n^2\times n^2}.$$} The remaining submatrices that are required because their terms appear in some constraints are defined accordingly: $$\begin{array}{ll} \Sigma= \y\y^T=(\sigma_{ij})\in \mathbb{R}^{n\times n}, & \\ \Omega=WW^T=(\omega_{ij})\in \mathbb{R}^{n\times n}, & \Psi=\xi\xi^T=(\psi_{ij})\in \mathbb{R}^{n\times n},\\ \Pi=rvec(\eta)rvec(\eta)^T=(\pi_{ikj\ell})\in \mathbb{R}^{n^2\times n^2}, & \mathcal{Z}=\zeta\zeta^T=(z_{rs})\in \mathbb{R}^{n\times n}, \\ (P\y)=rvec(P)\y^T=((P\y)_{ij\ell})\in \mathbb{R}^{n^2\times n}, & (PW)=rvec(P)W^T=(\rho_{ikj})\in \mathbb{R}^{n^2\times n}, \\ (P\xi)=rvec(P)\xi^T=((P\xi)_{ij\ell})\in \mathbb{R}^{n^2\times n}, & (P\eta)= rvec(P)rvec(\eta)^T=(\nu_{ijrs})\in \mathbb{R}^{n^2\times n^2},\\ (P\zeta)=rvec(P)\zeta^T=((P\zeta)_{ij\ell})\in \mathbb{R}^{n^2\times n}, & \\ (X\y)=rvec(X)\y^T=(\chi_{ikj})\in \mathbb{R}^{n^2\times n},& (XW)=rvec(X)W^T=(\gamma_{ik\ell})\in \mathbb{R}^{n^2\times n},\\ (X\eta) =rvec(X)rvec(\eta)^T=(\kappa_{ijrs})\in \mathbb{R}^{n^2\times n^2}, & (X\zeta)=rvec(X)\zeta^T=(\tau_{ijr})\in \mathbb{R}^{n^2\times n},\\ (\y\zeta)= \y\zeta^T=(\beta_{ij})\in \mathbb{R}^{n\times n},& \\ (W\xi)=W\xi^T=(\delta_{ij})\in \mathbb{R}^{n\times n}, & (W\eta)= Wrvec(\eta)^T=(\epsilon_{irs})\in \mathbb{R}^{n\times n^2}. \end{array}$$ \medskip Finally, consider the coefficient matrix $G$ and the vector $g$ indexed in the same basis as $\phi$. \medskip $$ \begin{array}{ccc} G=\left[ \begin{array}{ccccccc} D & F & \Theta & \Theta & \Theta & \Theta & \Theta \\ F^T & H & \Theta & \Theta & \Theta & \Theta & \Theta \\ \Theta & \Theta & \Theta & \Theta & \Theta & \Theta & \Theta \\ \Theta & \Theta & \Theta & \Theta & \Theta & \Theta & \Theta \\ \Theta & \Theta & \Theta & \Theta & \Theta & \Theta & \Theta \\ \Theta & \Theta & \Theta & \Theta & \Theta & \Theta & \Theta \\ \Theta & \Theta & \Theta & \Theta & \Theta & \Theta & \Theta \end{array} \right] & \mbox{ where } F= & \begin{array}{c} \left[\begin{array}{cccc} \stackrel{X_{1\cdot}}{\overbrace{\lambda_1\otimes C_{1\cdot}}}& \stackrel{X_{2\cdot}}{\overbrace{\Theta}} & \ldots & \stackrel{X_{n\cdot}}{\overbrace{\Theta}}\\ \vdots & \vdots & \ddots &\vdots \\ \lambda_n\otimes C_{1\cdot} & \Theta & \ldots & \Theta \\ \Theta &\lambda_1\otimes C_{2\cdot} & \ldots & \Theta \\ \vdots & \vdots & \ddots & \vdots \\ \Theta & \lambda_n\otimes C_{2\cdot} & \ldots & \Theta \\ \Theta & \Theta & \ldots & \lambda_1\otimes C_{n\cdot} \\ \vdots & \vdots & \ddots & \vdots \\ \Theta & \Theta & \ldots & \lambda_n\otimes C_{n\cdot} \end{array} \right] \end{array} \end{array} $$ \medskip and $$ g^T=[\; \stackrel{P}{\overbrace{\Theta}},\stackrel{X}{\overbrace{\Theta}},\stackrel{\y}{\overbrace{\Theta}}, \stackrel{W}{\overbrace{\lambda^T}},\stackrel{\xi}{\overbrace{\Theta}},\stackrel{\eta}{\overbrace{\Theta}},\stackrel{\zeta}{\overbrace{\Theta}}\; ].$$ \rev{Recall that, as already introduced in Section \ref{s:codomp}, $\Theta$ stands for the matrix of the adequate size with all its entries equal to zero.} \medskip Clearly, \begin{align} 1/2 \langle G, \Phi \rangle=1/2trace(G\Phi)& =\displaystyle \sum_{k=1}^n \lambda_k \sum_{j=1}^n P_{jk}\sum_{\ell =1} ^n c_{j \ell} X_{j\ell} +1/2\sum_{j=1}^n\sum_{k=1}^n\sum_{j'=1}^n\sum_{k'=1}^n d_{jkj'k'}P_{jk}P_{j'k'} \nonumber \\ & +1/2\sum_{j=1}^n\sum_{\ell=1}^n\sum_{p=1}^n\sum_{q=1}^n h_{j\ell pq}X_{j\ell}X_{pq}, \label{eq:ofp2} \end{align} is the objective function of Problem \ref{pro:comb-ofp2}. Analogously, \begin{equation} \label{eq:of-con-g} \langle F, V\rangle=\rev{trace(FV)=} \sum_{k=1}^n \lambda_k \sum_{j=1}^n P_{jk}\sum_{\ell =1} ^n c_{j \ell} X_{j\ell}=\; g^T W, \end{equation} that results in the first term in the objective function of the same problem, namely, \ref{pro:comb-ofp2}. Let $\mathcal{L}$ be \rev{the linear constraints} of the feasible region of \ref{pro:comb-ofp2}, namely \begin{equation} \label{eq:L} \rev{\mathcal{L}=\{\phi\ge 0: \phi \mbox{ satisfies } \eqref{pro:comb1p},\eqref{pro:comb2p}, \eqref{pro:comb4p}, \eqref{pro:comb5p}, \eqref{pro:comb6pmodeq}, \eqref{pro:comb1p8}, \eqref{pro:comb1p3} \mbox{ and } \eqref{pro:comb1p7}\},} \end{equation} and let $A\phi=b$ be system of equations that describes the set $\mathcal{L}$. Now, we consider a new transformation of \ref{pro:comb-ofp2} using matrix variables $\Phi$. \rev{This transformation requires, in addition, to include:} 1) the linear constraints, $\mathcal{L}$, that come from \ref{pro:comb-ofp2}, namely $A\phi=b$, 2) the squares of those constraints in the matrix variable $\Phi$, namely $diag(A\Phi A^T)=b\circ b$, where $\circ$ is the Hadamard product of vectors, 3) the quadratic constraints of \ref{pro:comb-ofp2} written in the matrix variables $\Phi$: \begin{align} W_k-\sum_{\ell=1}^n\sum_{j=1}^n c_{j\ell} v_{jkj\ell}&=0,\; \forall k=1,\ldots,n, \label{quadratic1}\\ \sum_{j,k=1}^n (P_{jk}-q_{jkjk})&=0, \label{quadratic2}\\ \rev{\sum_{j,\ell=1}^n (X_{j\ell}-u_{j\ell j\ell})}&=0 \label{quadratic3} \end{align} and 4) \rev{the matrix $$\overline \Phi=\left( \begin{array}{cc} 1 & \phi^T \\ \phi & \Phi \end{array}\right) \in \mathcal{C}^*,$$ the cone of completely positive matrices of the appropriate dimension (see \citep[Theorem 3.1]{Burer09}).} Schematically, we can write that formulation as follows: \begin{align} \min & \; \displaystyle \sum_{j=1}^n\sum_{k=1}^n\sum_{j'=1}^n\sum_{k'=1}^n d_{jkj'k'}q_{jkj'k'} +1/2\sum_{j=1}^n\sum_{\ell=1}^n\sum_{p=1}^n\sum_{q=1}^n h_{j\ell pq}u_{j\ell pq}\nonumber \\ & +1/2\sum_{k=1}^n \lambda_k \sum_{j=1}^n\sum_{\ell=1}^n c_{j\ell}v_{jkj\ell} \label{DOMP-QUAD} \tag{CP-DOMP-0} \\ \mbox{s.t. } & \phi \in \mathcal{L} \nonumber\\ & diag(A^T\Phi A)= b\circ b, \mbox{ where $A$ is the matrix of } \mathcal{L} \nonumber\\ & W_k-\sum_{\ell=1}^n\sum_{j=1}^n c_{j\ell} v_{jkj\ell}=0,\; \forall k=1,\ldots,n,\nonumber\\ & \sum_{j,k=1}^n (P_{jk}-q_{jkjk})=0, \nonumber \\ & \rev{\sum_{j,\ell=1}^n (X_{j\ell}-u_{j\ell j\ell})=0, \nonumber} \\ &\overline \Phi = \left(\begin{array}{cc} 1 & \phi^T \\ \phi & \Phi \end{array}\right)\in \mathcal{C}^* \nonumber \end{align} It is well-known that \ref{DOMP-QUAD} is always a relaxation of \ref{pro:comb-ofp2} and therefore it is also a relaxation for \DOMP. Our next result proves that actually it is not a relaxation of \DOMP but a reformulation. \begin{thm} \label{th:3.1} \DOMP belongs to the class of continuous, convex, conic optimization problems. Problem \ref{DOMP-QUAD} is equivalent to \ref{pro:comb-ofp2}, i.e.: (i) \rev{they have equal optimal} objective value, (ii) if $(\phi^*,\Phi^*)$ is an optimal solution for Problem \ref{DOMP-QUAD} then $\phi^* $ is in the convex hull of optimal solutions of Problem \ref{pro:comb-ofp2}. \end{thm} \begin{proof} \rm Clearly, the objective function of the problem \ref{DOMP-QUAD} can be written as a linear form of $\Phi$ (see (\ref{eq:ofp2})): $$ 1/2\langle D,Q \rangle+1/2\langle H,U \rangle+ \langle F, V \rangle= 1/2 \langle G, \Phi \rangle.$$ Let $\mathcal{L}$ be the linear constraints of the feasible region of \ref{pro:comb-ofp2}, as defined in (\ref{eq:L}), and let $\mathcal{L}_{\infty}$ be its recession cone. First of all, one realizes that $P$, $\y$ and $X$ are bounded \rev{above since they satisfy \eqref{pro:comb1p}, \eqref{pro:comb4p}, \eqref{pro:comb5p}, respectively. Besides $W_k$, for all $k=1,\ldots,n$ are also bounded above since if we apply constraint (\ref{pro:comb1p7}), we get $\sum_{k=1}^n W_k=\sum_{j=1}^n\sum_{\ell=1}^n c_{j\ell} X_{j\ell}$. Hence, for each $k=1,\ldots,n$, $W_k\le n\max_{j,\ell} c_{j\ell}$. This proves that all variables $P,X,\y,W$ are nonnegative and bounded above. To prove that also the slack variables $\eta,\psi,\zeta$ are bounded we proceed as follows. We observe from \eqref{pro:comb1p8} that $\eta_{jk}\le W_k+2\sum_{j,\ell}c_{j\ell}$, for all $j,k=1,\ldots,n$ and thus variables $\eta$ are bounded. Analogously, from \eqref{pro:comb1p3}, we get that $\psi_k\le W_k+W_{k+1}$, for all $k=1,\ldots,n-1$, hence $\psi$ variables are bounded as well. Finally, using \eqref{pro:comb6pmodeq}, it follows that $\zeta_\ell \le (n-p+1)\y_\ell +\sum_{j=1}^n\sum_{\ell=1}^n X_{j\ell}$, for all $\ell=1,\ldots,n$, and thus using the boundedness of $\y$ and $X$ the slack variables $\zeta$ are also bounded.} Therefore, it follows that the recession cone of the linear part of the feasible region of \ref{pro:comb-ofp2} is the zero vector. Next, we consider the sets: \begin{align*} \mathcal{L}'=& \mathcal{L}\cap \{\phi: W_k-\sum_{\ell=1}^n\sum_{j=1}^n c_{j\ell} P_{jk}X_{j\ell}=0,\; k=1,\ldots,n, \, \sum_{j,k=1}^n (P_{jk}-P_{jk}^2)=0, \, \rev{\sum_{j,\ell=1}^n (X_{j\ell}-X_{j\ell}^2)=0} \}\\ (\mathcal{L}')^1=& \left\{ {1\choose \phi} {1\choose \phi}^T: \phi\in \mathcal{L}'\right\},\\ \mathcal{R}=& \left\{ \overline{\Phi}=\left(\begin{array}{cc} 1 & \phi^T \\ \phi & \Phi \end{array}\right)\in \mathcal{C}^*: A\phi=b,\;\; diag(A\Phi A^T)=b\circ b \right\},\\ \mathcal{R}'=& \mathcal{R}\cap \left\{ \overline{\Phi}=\left(\begin{array}{cc} 1 & \phi^T \\ \phi & \Phi \end{array}\right):W_k-\sum_{\ell=1}^n\sum_{j=1}^n v_{jk\ell j}=0,\forall k=1,\ldots,n,\, \sum_{j,k=1}^n (P_{jk}-q_{jkjk})=0, \right. \\ & \rev{\sum_{j,\ell=1}^n (X_{j\ell}-u_{j\ell j\ell})=0 \Big\}.} \end{align*} Recall the $A\phi=b$ is the set of linear constraints that describe the set $\mathcal{L}$, $\mathcal{L}'$ is the continuous relaxation of \ref{pro:comb-ofp2} and $\mathcal{R}'$ is the feasible region of \ref{DOMP-QUAD}. We prove, that $$ conv((\mathcal{L}')^1) = \mathcal{R}'.$$ The inclusion $ conv((\mathcal{L}')^1)\subseteq \mathcal{R}'$ is clear. For the reverse inclusion, since \rev{$\mathcal{R}'\subset \mathcal{R}\subset \mathcal{C}^*$ then for any matrix $\overline \Phi\in \mathcal{R}'$, it is known (see e.g. \cite{Burer09}) that there exists a representation as: $$\overline{\Phi}=\left(\begin{array}{cc} 1 & \phi^T \\ \phi & \Phi \end{array}\right)=\sum_{r\in I} \mu^r {1\choose \phi^r} {1\choose \phi^r}^T + \sum_{r \in J} {0\choose \gamma^r} {0\choose \gamma^r}^T, $$ where $I$ and $J$ are finite sets of indices, $\mu^r\ge 0$ for all $r\in I$, $\sum_{r\in I} \mu^r=1$, $\phi^r\in \mathcal{L}$ for all $r\in I$ and $\gamma^r\in \mathcal{L}_\infty$ for all $r\in J$. Therefore, since the recession cone $\mathcal{L}_\infty$ is the zero vector, the representation above reduces to: \begin{equation} \label{eq:represent} \overline{\Phi}=\left(\begin{array}{cc} 1 & \phi^T \\ \phi & \Phi \end{array}\right)=\sum_{r\in I} \mu^r {1\choose \phi^r} {1\choose \phi^r}^T, \end{equation} with $\mu^r\ge 0$ for all $r\in I$, $\sum_{r\in I} \mu^r=1$, and $\phi^r\in \mathcal{L}$ for all $r\in I$.} \medskip We claim that $\sum_{j,k=1}^n (P_{jk}-q_{jkjk})=0$, \rev{$\sum_{j,\ell=1}^n (X_{j\ell}-u_{j\ell j\ell})=0$} and $W_k-\sum_{\ell=1}^n\sum_{j=1}^n c_{j\ell} v_{jk\ell j}=0,\forall k=1,\ldots,n$ implies that each $\phi^r$ with $r\in I$ satisfies $\sum_{j,k=1}^n (P_{jk}^r-(P_{jk}^r)^2)=0$, \rev{$\sum_{j,\ell=1}^n (X_{j\ell}^r-(X_{j\ell}^r)^2)=0$} and $W_k^r -\sum_{\ell=1}^n\sum_{j=1}^n c_{j\ell} P_{jk}^rX_{j\ell}^r=0,\; \forall \; k=1,\ldots,n$. This will complete the proof. First of all, we observe that, by the representation (\ref{eq:represent}), it holds that: \rev{$P_{jk}=\sum_{r\in I} \mu^r P_{jk}^r,\; X_{j\ell}=\sum_{r\in I} \mu^r X_{j\ell}^r$,} $W_k=\sum_{r\in I} \mu^r W_k^r$,\; $q_{jkjk}=\sum_{r\in I} \mu^r (P_{jk}^r)^2$ and $v_{jk\ell j}=\sum_{r\in I} \mu^r P_{jk}^r X_{\ell j}^r$; for all $j,k=1,\ldots,n$. We begin with $\sum_{j,k=1}^n (P_{jk}-q_{jkjk})=0$ and replace the variables $P_{jk}$ and $q_{jkjk}$ by their representation in terms of (\ref{eq:represent}) which results in: \begin{equation} \label{eq:pjkr} 0=\sum_{j=1}^n\sum_{k=1}^n \left(\sum_{r\in I} \mu^r P_{jk}^r-\sum_{r\in I} \mu^r (P_{jk}^r)^2\right)=\sum_{j=1}^n\sum_{k=1}^n \left(\sum_{r\in I} \mu^r (P_{jk}^r-(P_{jk}^r)^2)\right). \end{equation} \rev{It is clear that $P_{jk}^r\le 1$ and $X_{j\ell}^r\le 1$ for all $j,k,\ell=1,\ldots,n$. Indeed, $P_{jk}=\sum_{r\in I} \mu^r P_{jk}^r$ with $P_{jk}^r\ge 0$ for all $r\in I$ and $P_{jk}\le 1$ since it satisfies \eqref{pro:comb1p} and \eqref{pro:comb2p}. Therefore $P_{jk}^r\le 1$, for all $j,k=1,\ldots,n$, then all the addends in (\ref{eq:pjkr}) are nonnegative and this implies that \begin{equation}\label{eq:cond1} P_{jk}^r-(P_{jk}^r)^2=0, \qquad \forall \; j,k=1,\ldots,n, \; r\in I. \end{equation} Next, the proof for $\sum_{j,\ell=1}^n (X_{j\ell}^r-(X_{j\ell}^r)^2)=0$ is similar, but to prove that $X_{j\ell}^r\le 1$ we use the inequality \eqref{pro:comb5p} valid for $X_{j\ell}$ instead of \eqref{pro:comb1p} and \eqref{pro:comb2p}. This proves the first part of the claim.} Next, we consider $W_k-\sum_{\ell=1}^n\sum_{j=1}^n c_{j\ell} v_{jk\ell j}=0$. Then, we replace $W_k$ and $v_{jk\ell j}$ by their representation in terms of (\ref{eq:represent}) which results in \begin{equation}\label{eq:segcon} 0=\sum_{r\in I} \mu^r W_k^r-\sum_{\ell=1}^n\sum_{j=1}^n \sum_{r\in I} \mu^r c_{j\ell} P_{jk}^r X_{jk}^r=\sum_{r\in I}\mu^r \left( W_k^r- \sum_{\ell =1}^n \sum_{j=1}^n c_{j\ell} P_{jk}^rX_{\ell j}^r\right). \end{equation} Now, since $W_k^r$, $X_{\ell j}^r$ and $P_{jk}^r$ satisfy \eqref{pro:comb1p8} for all $r\in I$ and $P_{jk}^r\ge 0$ for all $j,k$ and $r$, we multiply both sides of inequality \eqref{pro:comb1p8} \rev{by} $P_{jk}^r$. This results in: $$ W_k^r P_{jk}^r\ge \sum_{\ell =1}^n c_{j\ell} X_{j\ell}^r P_{jk}^r-\sum_{\ell=1}^n c_{j\ell}P_{jk}^r (1-P_{jk}^r), \quad \forall j,k=1,\ldots,n,\; r\in I.$$ We sum the above inequalities for all $j=1,\ldots,n$ to obtain: $$ W_k^r \displaystyle \stackrel{= 1\; (\ref{pro:comb1p}),(\ref{eq:represent})}{\overbrace{\displaystyle \sum_{j=1}^n P_{jk}^r}}\ge \sum_{j=1}^n \sum_{\ell =1}^n c_{j\ell} X_{j\ell}^r P_{jk}^r- \sum_{j=1}^n \sum_{\ell=1}^n c_{j\ell}\stackrel{=0 \, (\ref{eq:cond1})}{\overbrace{(P_{jk}^r-(P_{jk}^r)^2)}}, \quad \forall k=1,\ldots,n,\; r\in I.$$ Furthermore, in the above inequality the factor multiplying $W_k^r$ in the left-hand-side is equal to one by (\ref{pro:comb1p}) and (\ref{eq:represent}), and the second term is the right-hand-side in zero by (\ref{eq:cond1}). Hence, we obtain: \begin{equation}\label{eq:cond2} W_k^r \ge \sum_{j=1}^n \sum_{\ell =1}^n c_{j\ell} X_{j\ell}^r P_{jk}^r, \quad \forall k=1,\ldots,n,\; r\in I. \end{equation} This condition combined with (\ref{eq:segcon}) proves the second part of the claim. Therefore, $ \mathcal{R}' \subseteq conv((\mathcal{L}')^1)$ also holds, and thus, $ \mathcal{R}'= conv((\mathcal{L}')^1)$. The above property allows us to rewrite Problem \ref{pro:comb-ofp2} as an equivalent continuous, convex conic linear \rev{optimization} problem in the matrix variables ${1\quad \phi^T \choose \phi \quad \Phi}$ as described in \ref{DOMP-QUAD}. \hfill $\Box$ \end{proof} The next result states that in \ref{DOMP-QUAD} we can remove the explicit dependency on the original variables $\phi$ obtaining a new formulation that only depends on the essential matrix variables $\Phi$. \rev{ \begin{thm} \label{th:3.2} Problem \ref{DOMP-QUAD} can be reformulated removing the explicit dependency on the $\phi$ variables as: \begin{align} \min & \; \displaystyle \sum_{j=1}^n\sum_{k=1}^n\sum_{j'=1}^n\sum_{k'=1}^n d_{jkj'k'}q_{jkj'k'} +1/2\sum_{j=1}^n\sum_{\ell=1}^n\sum_{p=1}^n\sum_{q=1}^n h_{j\ell pq}u_{j\ell pq}\nonumber \\ & +1/2\sum_{k=1}^n \lambda_k \sum_{j=1}^n\sum_{\ell=1}^n c_{j\ell}v_{jkj\ell} \label{pro:comb-of} \tag{CP-DOMP} \\ \mbox{s.t. } & \Phi[a_{(4)}]_1 \in \mathcal{L} \nonumber\\ & diag(A^T\Phi A)= b\circ b, \mbox{ where $A$ is the matrix of } \mathcal{L} \nonumber\\ & \sum_{\ell = 1}^n\rho_{1\ell k} - \sum_{\ell = 1}^n\sum_{j=1}^n c_{j\ell} v_{jkj\ell}=0,\; \forall k=1,\ldots,n,\nonumber\\ & \sum_{j,k=1}^n (\sum_{\ell = 1}^n q_{jk1\ell} -q_{jkjk})=0, \nonumber \\ & \sum_{j,\ell=1}^n (\sum_{r=1}^n v_{j\ell 1r} - u_{j\ell j\ell})=0, \nonumber \\ & \Phi \in \mathcal{C}^* \nonumber \end{align} Moreover, if $\hat \Phi$ is an optimal solution for Problem \ref{pro:comb-of} then $\hat \Phi [a_{(\ref{pro:comb1p})}]_1$ is in the convex hull of optimal solutions of Problem \ref{pro:comb-ofp2}. \end{thm} } \begin{proof} {\rm \rev{The proof is based on finding an appropriate linear combination of the rows of the linear constraints in $\mathcal{L}$, \rev{namely $A\phi=b$,} that allows one a writing of $\phi$ as a linear combination of $\Phi$, following an argument similar to the one in \cite{Burer09}. We reproduce it for the sake of completeness. Take the first equation in (\ref{pro:comb1p}) i.e., $\sum_{j=1}^n P_{j1}=1$. Recall that we rewrite this constraints as $[a_{(\ref{pro:comb1p})}]^T_1 \phi=1$. Next, define the vector $\beta=(\beta_i)_{i\in I}$, as $\beta_1=1$, $\beta_i=0$, for all $i>1$. It is clear that $\sum_{i\in I} \beta_i [a_{(i)}]=[a_{(\ref{pro:comb1p})}]_1\ge 0$ and that $\sum_{i\in I} \beta_i b_i=1$. Let us denote $\alpha=\sum_{i\in I} \beta_i [a_{(i)}]$. Then, $$ \alpha^T \phi =\sum_{i\in I} \beta_i [a_{(i)}]^T \phi = \sum_{i\in I} \beta_i b_i=1.$$ Thus, since $\phi \phi^T=\Phi$, from the above we obtain \begin{equation}\label{filineal} \phi \phi^T \alpha= \Phi \alpha = \phi. \end{equation} \noindent On the other hand, $1=\alpha^T \phi \phi^T \alpha= \alpha^T \Phi \alpha$, and hence $$ \overline{\Phi}:= \left[\begin{array}{cc} 1 & \phi^T \\ \phi & \Phi \end{array} \right]= \left[\begin{array}{cc} 1 & \alpha^T \Phi \\ \Phi \alpha & \Phi \end{array} \right] = (\alpha \; I)^T \Phi (\alpha I),$$ and since $\alpha\ge 0$, if $\Phi \in \mathcal{C}^*$ then $\overline{\Phi} \in \mathcal{C}^*$. To prove the converse, it suffices to recall that the principal submatrices of completely positive matrices are completely positive. Therefore, if $\overline{\Phi} \in \mathcal{C}^*$ then $\Phi \in \mathcal{C}^*$. To obtain the formulation (\ref{pro:comb-of}) we only need to replace any occurrence of $\phi$ in \ref{DOMP-QUAD} by $\Phi [a_{(\ref{pro:comb1p})}]_1$ and observe that, in terms of $\Phi [a_{(\ref{pro:comb1p})}]_1$, $W_k=\sum_{\ell =1}^n \rho_{1\ell k}$, for all $k=1,\ldots,n$, $P_{jk}=\sum_{\ell = 1}^n q_{jk1\ell}$, for all $j,k=1,\ldots,n$ and $X_{j\ell}=\sum_{r=1}^n v_{j\ell 1r}$, for all $j,\ell =1,\ldots,n$. To complete the proof we apply the assertion (ii) of Theorem \ref{th:3.1}. Summarizing, we have obtained that formulation \ref{pro:comb-of} is exact for \DOMP and it is linear in $\Phi \in \mathcal{C}^*_{(3n^2+4n)\times (3n^2+4n)}$. } \hfill $\Box$ } \end{proof} An explicit reformulation of \ref{pro:comb-of}, namely (\ref{pro:explicit}), can be found in the Appendix. \begin{propo} \label{cor:conv-of} The objective function of \ref{pro:comb-of} can be equivalently written for any $\mu \in [0,1]$ as: \begin{equation} \label{eq:cor31} \mu \langle F,V \rangle+(1-\mu) \sum_{k=1}^n \lambda_k \sum_{\ell=1}^n \rho_{1\ell k}+1/2\langle D,Q \rangle+1/2\langle H,U \rangle. \end{equation} \end{propo} \begin{proof} \rm Recall that from (\ref{eq:ofp2}) the objective function of \ref{pro:comb-ofp2}satisfies: \begin{align*} \displaystyle \sum_{k=1}^n \lambda_k \sum_{j=1}^n P_{jk}\sum_{\ell =1} ^n c_{j \ell} X_{j\ell} +1/2\sum_{j=1}^n\sum_{k=1}^n\sum_{j'=1}^n\sum_{k'=1}^n d_{jkj'k'}P_{jk}P_{j'k'} \\ +1/2\sum_{j=1}^n\sum_{\ell=1}^n\sum_{p=1}^n\sum_{q=1}^n h_{j\ell pq}X_{j\ell}X_{pq} & =1/2 \langle G, \Phi \rangle\\ &\hspace*{-2cm} = \langle F,V\rangle+ 1/2 \langle D,Q\rangle +1/2\langle H,U\rangle. \end{align*} Next, using (\ref{eq:of-con-g}) we get $$ \langle F,V \rangle= \sum_{k=1}^n \lambda_k\sum_{j=1}^n\sum_{\ell=1}^n c_{j\ell} P_{jk}X_{j\ell}=\sum_{k=1}^n \lambda_k W_k=\langle g, \phi \rangle.$$ \rev{Then, for any $\mu\in [0,1]$, combining both expressions and using that $\Phi\alpha=\phi$ and therefore $W_k=\sum_{\ell=1}^n\rho_{1\ell k}$, for all $k=1,\ldots, n$, we get:} {\small \begin{align} \langle F, V \rangle+1/2\langle D,Q \rangle+1/2\langle H,U \rangle=& \mu \langle F, V \rangle +(1-\mu) \langle g, \phi \rangle+1/2\langle D,Q \rangle+1/2\langle H,U \rangle \nonumber \\ = & 1/2 \langle D,Q \rangle+1/2\langle H,U \rangle+\mu \langle F, V \rangle +(1-\mu) \langle \mu, W \rangle \nonumber \\ =& 1/2 \langle D,Q \rangle+1/2\langle H,U \rangle+\mu \langle F, V \rangle \nonumber \\ & +(1-\mu) \langle \mu, (PW)^T [a_{(\ref{pro:comb1p})}]_1 \rangle \nonumber \\ =& 1/2 \langle D,Q \rangle+1/2\langle H,U \rangle+\mu/2 \langle F, V \rangle \nonumber \\ &+(1-\mu) \sum_{k=1}^n \lambda_k \sum_{\ell=1}^n \rho_{1\ell k}. \label{pro:miqlc-of-ref2} \end{align} } This is exactly the expression that we had to obtain. \hfill $\Box$ \end{proof} Finally, we would like to remark that 7 out of 21 blocks of the matrix variables $\Phi$, namely $\y W\in \mathbb{R}^{n \times n}$, $\y \xi\in \mathbb{R}^{n \times n}$, $\y \eta\in \mathbb{R}^{n \times n^2}$, $ W \zeta\in \mathbb{R}^{n \times n}$, $\xi \eta \in \mathbb{R}^{n \times n^2}$, $\xi \zeta\in \mathbb{R}^{n \times n}$ and $\eta \zeta\in \mathbb{R}^{n^2 \times n}$, never appear explicitly in any constraint but in $\Phi \in \mathcal{C}^*_{(3n^2+4n)\times (3n^2+4n)}$. In addition, we observe that Corollary \ref{cor:conv-of} shows that, according to (\ref{eq:cor31}), the objective function of \ref{pro:comb-of} is also valid for $\mu=0$ and $\mu=1$ which makes it possible to avoid $V$ or $\rho$ variables in the objective function. It is not clear whether these two final remarks may help in solving the problem or not. \section{Concluding remarks\label{s:remarks}} The results in this paper state, for the first time, the equivalence of a difficult $NP$-hard discrete location problem, namely \DOMP, with a continuous, convex problem. This new approach can be used to start new avenues of research by applying tools from continuous optimization to approximate or numerically solve some other hard discrete location problems, as for instance single allocation hub location problems and ordered median hub location problems with and without capacities, see e.g. \cite{FPRCh2013,Puerto2011,PUERTO2016142}, to mention a few. The aim of this paper is not computational but it seems natural to consider some relaxations of formulation \ref{pro:comb-of} to analyze the accuracy of their related bounds. This is beyond the scope of this contribution but will be the subject of a follow up paper. \section*{Acknowledgements} This research has been partially supported by Spanish Ministry of Econom{\'\i}a and Competitividad/FEDER grants number MTM2016-74983-C02-01. The author would like to thank Prof. I. Bomze from the University of Vienna for fruitful discussions that led to conclude this project. \bibliographystyle{plainnat}
\section*{Abstract} The application of biomechanic and motor control models in the control of bidedal robots (humanoids, and exoskeletons) has revealed limitations of our understanding of human locomotion. A recently proposed model uses the potential energy for bipedal structures to model the bipedal dynamics, and it allows to predict the system dynamics from its kinematics. This work proposes a task-space planner for human-like straight locomotion that target application of in rehabilitation robotics and computational neuroscience. The proposed architecture is based on the potential energy model and employs locomotor strategies from human data as a reference for human behaviour. The model generates Centre of Mass (CoM) trajectories, foot swing trajectories and the Base of Support (BoS) over time. The data show that the proposed architecture can generate behaviour in line with human walking strategies for both the CoM and the foot swing. Despite the CoM vertical trajectory being not as smooth as a human trajectory, yet the proposed model significantly reduces the error in the estimation of the CoM vertical trajectory compared to the inverted pendulum models. The proposed model is also able to asses the stability based on the body kinematics embedding in currently used in the clinical practice. However, the model also implies a shift in the interpretation of the spatiotemporal parameters of the gait, which are now determined by the conditions for the equilibrium and not \textit{vice versa}. In other words, locomotion is a dynamic reaching where the motor primitives are also determined by gravity. \section{Introduction} Owing to the development of bipedal robots and medical technologies for locomotor disabilities, there is an exponentially growing surge of interest in the bipedal equilibrium \cite{SAUNDERS1953, Kuo2007, Torricelli2016, McGeer1990, Carpentier2016,dobkin2017}. The earlier systematic investigation on locomotion strategies identified the pelvic rotation, pelvic tilt, knee stance flexion, lateral displacement of the pelvis, foot and knee mechanisms as parameters (gait determinants) that characterise the human locomotion and differentiate pathological behaviours \cite{SAUNDERS1953}. Subsequently, the works focused on the analysis of the dynamics based on the inverted pendulum model for bipedal locomotion, while the gait determinants were gradually set aside due to their qualitative nature \cite{Torricelli2016, Kuo2007}, models derived from the inverted pendulum model are currently deployed for both the analysis of human behaviour and bipedal robots controllers \cite{Pratt2006,Torricelli2016,Kuo2007,Hof2005,Caron2016,Carpentier2016}. The inverted pendulum does not accurately model the dynamics for step-to-step transition \cite{Kuo2007}. Therefore, models like the Zero Moment Point (ZMP) and the extrapolated Centre of Mass (XCoM) are required for the extension of the inverted pendulum model to human-like locomotion (i.e., not constraint to the sagittal plane) by identifying the synchronization condition between the legs in the task-space \cite{Popovic2004, Torricelli2016, Kuo2007,Hof2007, Caron2016,englsberger2015three}. However, these models require local optimisation algorithms to plan the walking trajectory in the task space, making the process computationally expensive for highly redundant mechanisms \cite{Perrin2012, Carpentier2016, Caron2016, Laumond2015}. In this paper, we propose to apply a recently published analytical model of the potential energy generated by an anthropometric bipedal walker for the formulation of a planner in the task-space \cite{Tiseo2016, Tiseo2018a,Tiseo2018d}. The potential energy model allows to define a posture-dependent reference frame called Saddle Space that is aligned with the principal directions of the potential energy surface, as shown in Figure \ref{fig:01}. The y-axis of the Saddle Space ($y_{Saddle}$) is aligned with the principal direction between the three fixed points of the Saddle, and it includes the biped in the segment between the two feet where there is a stable dynamics \cite{Tiseo2018d}. On the other hand, the biped is always unstable along the x-axis, $x_{Saddle}$ \cite{Tiseo2016, Tiseo2018b, Tiseo2018c,Tiseo2018d}. The proposed task-space planner for straight walking can generate human-like trajectories, and it has been validated using the human motion capture data. This study aims to further the understanding of human locomotion motor control for the improvements of motor control models and rehabilitation therapies. Therefore, the choice to initially focus on a straight walking task has been based on the empirical evidence that humans have dedicated alignment strategies for locomotion, which are usually separated by a \textit{quasi}-straight walking path \cite{Sreenivasa2015}. The planner integrates commonly used parameters such as the XCoM and Base of Support (BoS) to evaluate stability from the locomotion kinematics. Furthermore, Lyapunov's stability analysis confirms that the BoS is a good cautionary estimation for the Region of Attraction. \begin{figure*}[ht] \centering \begin{subfigure}[b]{0.60\textwidth} \centering \includegraphics[width=\textwidth]{figure1.eps} \caption{\centering\centering} \label{fig:01} \end{subfigure} \hfill \begin{subfigure}[b]{0.65\textwidth} \centering \includegraphics[width=\textwidth]{figure2.eps} \caption{\centering} \label{fig:02} \end{subfigure} \begin{subfigure}[b]{0.65\textwidth} \centering \includegraphics[width=\textwidth]{figure3.eps} \caption{\centering} \label{fig:03} \end{subfigure} \caption{The Saddle Space and the generation of a recursive algorithm for bipedal locomotion planning. (a) The Saddle Space frame has the y-axis aligned with the principal direction connecting the two fulcra ($R_{CoP}$ and $L_{CoP}$) and the x-axis lying on the other saddle principal direction. (b) The proposed planner relies on the deployment of the potential energy fixed point to generate the desired trajectories for both the CoM and the swinging foot. This constrains the CoM trajectory to lie on $y_{Saddle}$ that nullifies the gravitational forces perpendicular to the CoM trajectory on the tangent plane \cite{Tiseo2016, Tiseo2018a}. (c) The proposed planner inputs are the initial feet position, the desired velocity, the body height, the mass, the desired HS angle when the foot hits the ground and the number of steps to be simulated. The planning algorithm derives all the other parameters from the inputs. For example, Phase$_0$ which is the initial gait phase, and the natural frequency of the inverted pendulum ($\omega_n$). Subsequently, the recurrent module starts and plan the selected number of steps. } \end{figure*} \section{Materials and Methods} \label{Sec:2} The planning algorithm is described in the first subsection, and includes both the generation of the Centre of Mass (CoM) and feet trajectories. It is observe from Figure \ref{fig:01} that the proposed method relies only on the Cartesian distances between the CoM and the two Centre of Pressures in the feet (COPs), which are the fulcra of the two pendula \cite{Tiseo2016,Tiseo2018d}. The methodology used in the evaluation of the planner performances is introduced at the end of the section. \subsection {Straight Walking Planning Algorithm} \label{Sec:2.1} The transverse trajectory of the CoM is obtained by modelling its motion as a harmonic oscillator that moves at a constant speed. The planning algorithm divides a $2\pi$ cycle of the oscillator into four phases based on the 3 fixed points of the potential energy surface (2 maxima and 1 saddle point \cite{Tiseo2016,Tiseo2018d}). This cycle is exemplified in Figure \ref{fig:02}, and every phase is associated with a via point, as follows: \begin{enumerate} \item \textit{Left Foot Via Point }($L_{Fvp}$): It is defined as the desired maximum amplitude of the mediolateral trajectory at the chosen walking velocity during left support, which occurs when both feet are aligned on a segment perpendicular to the walking direction. \item \textit{Left-to-Right Saddle Via Point }($L_{Svp}$): It is defined as the desired saddle position associated with the chosen walking speed. The position of the saddle point is selected under the hypothesis that both pendula have the same maximum length; thus placing it in the middle of the segment connecting the two CoPs \cite{Tiseo2016,Tiseo2018d}. \item \textit{Right Foot Via Point }($R_{Fvp}$): It is the equivalent to $L_{Fvp}$ for the right support phase. \item \textit{Right-to-Left Saddle Via Point}($R_{Svp}$): It is defined as the position of the saddle during the transition from right to left support. \end{enumerate} The recursive algorithm presented in Figure \ref{fig:03} has been derived from the equation to describe the CoM trajectory in the traverse plane in \cite{Tiseo2018d}. However, the architecture proposed requires also the identification of the required inputs and parameters, which can be obtained from the human motion capture data as explained later. \subsubsection*{Marker set, CoM, CoP and BoS:} The anthropometric parameters and the spatiotemporal parameters of the gait (e.g., the step length, $d_{SL}$, and step width, $d_{SW}$) are obtained from the KIT whole-body human motion databases (KITDB) \cite{Mandery2015}. The marker set and the method employed to calculate the CoM were derived from the four Iliac Markers. Hence, the CoM is placed in the middle of the segment connecting the frontal and the rear centres of the pelvis as defined by Iliac markers. Similarly, the CoPs are calculated as the mid-point along the segments joining the middle of the metatarsus (based on the two metatarsal markers) and the heel marker. It shall be noted that the CoP is defined as a geometrical point within the foot in our model, and it has been chosen based on its measure during standing reported in \cite{Hof2005,Tiseo2018c,Tiseo2018d}. The Base of Support (BoS) is introduced in our formulation in order to represent the range of motion of the CoP in the foot ($\simeq\pm 10 $ cm in the anteroposterior direction) \cite{Tiseo2018d}. \subsubsection{CoM Trajectory Planning:} \label{Sec:2.1.1} The desired task-space CoM trajectory generation is based on the following equations \cite{Tiseo2016,Tiseo2018d}: \begin{equation} \label{eq:01} \left\{ \begin{array}{l} x_{CoMd}(t)=v_{des}t\\\\ y_{CoMd}(t)=A_{y}\cos(\pi\omega_0 t +\phi)\\\\ z_{CoMd}(t)= \left\{ \begin{array}{lrcc} h_{CoM_L}(t), & if& Left & Support\\\\ h_{CoM_R}(t), & if& Right & Support \end{array}\right.\\\\ \end{array}\right. \end{equation} where $v_{des}$ is the desired walking speed, t is the time, and the other parameters are: \begin{enumerate} \item $\omega_0=v_{des}/d_{SL}$ is the step cadence, where $d_{SL}$ is the step length. \item $\phi$ is the gait phase at t=0, and it is derived as follows \begin{enumerate} \item $\phi=0$: The CoM moves from $L_{Fvp}$ to $L_{Svp}$. \item $\phi=\pi/2$: The CoM moves from $L_{Svp}$ to $R_{Fvp}$. \item $\phi=\pi$: The CoM moves from $R_{Fvp}$ to $R_{Svp}$. \item $\phi=3\pi/2$: The CoM moves from $R_{Svp}$ to $L_{Fvp}$ . \end{enumerate} \item $A_{y}=d_{SW}/(2\pi\omega_{0} d_{SL})$ is the mediolateral amplitude of the CoM movement, where $d_{SW}$ is the step width. This formulation for $A_y$ is obtained by imposing the trajectory of the CoM tangent to $y_{Saddle}$ during the step-to-step transition to maximise the stability \cite{Tiseo2018a,Tiseo2018b, Tiseo2018c}. This condition guides the CoM lateral trajectory along the segment connecting the two feet while passing for the saddle point during the double support. \item $z_{CoM_{d}}(t)$ depends on both the support foot of the gait phase and the length of the pendulum generated by the leg: \begin{enumerate} \item $h_{CoM_L}(t)=(h_{LP}(t)^2-(x_{CoMd}(t)-x_{LCoP}(t))^2-(y_{CoMd}(t)-y_{LCoP}(t))^2)^{0.5}$ where $x_{LCoP}(t)$ and $y_{LCoP}(t)$ are the coordinates of $L_{CoP}$. \item $h_{CoM_R}(t)=(h_{RP}(t)^2-(x_{CoMd}(t)-x_{RCoP}(t))^2-(y_{CoMd}(t)-y_{RCoP}(t))^2)^{0.5}$ where $x_{RCoP}(t)$ and $y_{RCoP}(t)$ are the coordinates of $R_{CoP}$. \end{enumerate} where both leg lengths, $h_{LP}(t)$ and $h_{RP}(t)$, depend on the ankle strategies. \end{enumerate} Lastly, the anteroposterior trajectory of the foot is derived based on the hypothesis that the CoM stays on $y_{Saddle}$ also during the swing, where the bipedal structure has a stable dynamics (Figure \ref{fig:01}) \cite{Tiseo2016,Tiseo2018d}. Therefore, its trajectory is determined based on the condition that its CoP lies on the line connecting the CoM to the CoP that provides support \cite{Tiseo2016,Tiseo2018d}, which results in the following equation: \begin{equation} \left\{\begin{array}{lll} x_{LCoP}(t)= \frac{d_{SW}}{{m_{S_{//}}(t)}}+x_{RCoP}, & Right& Stance\\\\ x_{RCoP}(t)=\frac{d_{SW}}{{m_{S_{//}}(t)}}+x_{LCoP}, & Left& Stance \end{array}\right. \end{equation} where $m_{S_{//}}$ is the slope of $y_{Saddle}$. \begin{figure*} [ht] \centering \begin{subfigure}[b]{0.49\textwidth} \centering \includegraphics[width=\textwidth]{Figure4.eps} \caption{\centering} \label{fig:04} \end{subfigure} \hfill \begin{subfigure}[b]{0.49\textwidth} \centering \includegraphics[width=\textwidth]{Figure5.eps} \caption{\centering} \label{fig:05} \end{subfigure} \caption{(a) The Step Width ($d_{SW}$) model is derived from the regression of motion capture data (MoCap Data) from KIT Data Base, and saturation in both high and low walking speeds. (b) The region of admissible Step Length ($d_{SL}$) extends along the abscissa up to the XCoM limit of stability, and its border along the y-axis is determined by the maximum reachable distance $d_{SL/2_{MAX}}$. They intersect at the peak velocity of about 3 [m/s], which is consistent with the results reported by Patnaik \textit{et al}\cite{Patnaik2015}.} \end{figure*} \subsubsection{Regression of Step Length and Step Width from the KITDB:} \label{Sec:2.1.2} The analysis of the data from the KITDB, corroborated by the literature, shows a linear relationship between the walking speed and the step length ($d_{SL}$) \cite{Orendurff2004, Hof2005, Collins2013, Kim2015}. On the other hand, the step width ($d_{SW}$) shows a more complex highly variable behaviour, which has been connected to both the lateral stabilisation and the energy optimisation of the gait strategies \cite{Collins2013, Kim2015}. The data from the KITDB employed for this work includes 58 straight walking trajectories, which are collected from 6 different subjects (4 males and 2 females) \cite{Mandery2015}. Their statistical distribution of age, mass and height are (mean $\pm$ std) $25\pm 2$ years, $63.3\pm10.3$ kg, and $1.79\pm0.10$ m. Our model for the selection of the step width is shown in Figure \ref{fig:04}, and it is described by the following equations: \begin{equation} \label{eq:03} d_{SW} (v_{des})= \left \{ \begin{array}{c} 0.22 \textit{ }(m), v_{des}<0.6 \textit{ }(m/s)\\ -0.2128 v_{des}+0.3456 \textit{ }(m), \textit{ o/w}\\ 0.10 \textit{ } (m), v_{des} > 1.1 \textit{ } (m/s)\\ \end{array}\right. \end{equation} where the $R^2$ of the KITDB data regression is 0.157. It is worth noticing that despite the linearity of the relationship between the mean step width and the velocity, the high variability of the step width in human data determines the low $R^2$ value. The step length model expressed as half of the step length represents the distance travelled by the CoM in the anteroposterior direction in each of the four phases introduced above. The result of the linear regression used for the generation of the reference behaviour as shown in Figure \ref{fig:05} can be defined as: \begin{equation} \label{eq:04} d_{SL/2} (v_{des})=\frac{d_{SL} (v_{des})}{2}=0.1802 v_{des}+0.1351 \textit{ } (m) \end{equation} where the $R^2$ of the KITDB data regression is 0.98. \subsubsection{Ankle Strategies and CoM Vertical Trajectory Planning:} \label{Sec:2.1.3} The ankle strategies are widely regarded to have a fundamental role in both balance and gait efficiency \cite{Hof2007,Kim2015,MyungheeKim2013,Ahn2012,Farris2015,McIlroy2003,Torricelli2016,Maki2007}. Therefore, we have decided to investigate the hypothesis that the CoM vertical trajectory error in the inverted pendulum can be mitigated by accounting for the ankle postures in accordance with the following equation: \begin{equation} \label{eq:05} \Delta h_{TO/HS}(t)= \left\{ \begin{array}{ll} 2d_h\sin(\theta_{TO}(t)/2),& \textit{ if Toe-Off}\\ 2d_h \sin(\theta_{HS}(t)/2),& \textit{ if Heel-Strike} \end{array}\right. \end{equation} where $d_h=0.1$ m is the distance of the CoPs from the anterior and the posterior centres of rotation of the foot during Toe-Off and Heel-Strike (HS), respectively \cite{Hof2005}. Moreover, $\theta_{TO}$ and $\theta_{HS}$ are the trajectories of the angles between the feet's soles and the ground during TO and HS respectively, and they are described at the end of this section. Hence, the length of the pendulum is modeled as follows: \begin{equation} \label{eq:06} \left\{ \begin{array}{l} h_{RP}(t)= \left\{ \begin{array}{ll} l_p+\Delta h_{R_{TO/HS}}(t),& \textit{ during TO/HS}\\ l_p,& \textit{ otherwise} \end{array}\right.\\\\ h_{LP}(t)= \left\{ \begin{array}{ll} l_p+\Delta h_{L_{TO/HS}}(t),& \textit{ during TO/HS}\\ l_p,& \textit{ otherwise} \end{array}\right. \end{array}\right. \end{equation} where $l_p=0.57h_{body}$ is the length of the pendulum based on anthropometric measures \cite{Virmavirta2014}, and $\Delta h_{L_{TO/HS}}$ is defined in equation (\ref{eq:05}). The parameters required for the generation of the ankle strategies are calculated based on the desired amplitude of the CoM vertical trajectory at the chosen walking speed. This relationship between the vertical amplitude and velocity is obtained from the KITDB, as follows: \begin{equation} \label{eq:07} \Delta Z_{CoM}(v_{des})=0.02656 v_{des} +0.002575 \textit{ }(m) \end{equation} where $R^2$ of the KITDB data regression is 0.2015. It is worth noticing that the relationship between the ankle angle and the velocity is characterised by the variability of the human data as evident from its low $R^2$ value. Furthermore, the behaviour observed is similar to the one observed in \cite{Orendurff2004}. Hence, equation (\ref{eq:07}) is used to determine the following parameters required to calculate the $\theta_{HS}(t)$ and $\theta_{TO}(t)$. \begin{equation} \label{eq:08} \left\{ \begin{array}{ll} t_{HS}&=\frac{1}{2\omega_0}-\frac{d_h(1-cos(\theta_{HS}))}{v_{des}}+t_0 \\\\ l_{p0}&=((l_p-\Delta Z_{CoM}(v_{des}))^2+\\&+(x_{CoMd}(t_{HS})-x_{CoP0})^2\\&+ (y_{CoMd}(t_{HS})-y_{CoP0})^2)^{0.5}\\\\ Max(\theta_{TO})&=2\arcsin(\frac{l_{p0}}{2d_h}) \end{array}\right. \end{equation} where $Max(\theta_{HS})$ is the Heel Strike angle provided as an input, $t_0$ is the starting time of the current phase, and $x_{CoP0}$ and $y_{CoP0}$ are the coordinates of the CoP before the starting of the TO, as shown in Figure \ref{fig:06}. The trajectories of the ankle angles have been modelled for both TO and HS strategies with the error function (erf) available in Matlab (Mathworks Inc), as follows: \begin{equation} \label{eq:A1} \left\{\begin{array}{ll} \theta_{HS}(t)&=-Max(\theta _{HS})\times erf(\frac{(t-t_{HS})}{0.11}+\\&+Max(\theta _{HS})\\\\ \theta_{TO}(t)&=Max(\theta _{TO})\times erf(\frac{(t-t_{HS})}{0.11})+\\&+Max(\theta _{TO}) \end{array}\right. \end{equation} where $t_{HS}$ is the instant where the sigmoid curve is centred at the HS, $Max(\theta _{TO})$ is the TO angle when the HS occurs and $Max(\theta _{HS})$ is the desired HS angle that is provided as the input. A sample trajectory for the TO strategy is shown in Figure \ref{fig:12}. \subsubsection{BoS Geometry} The analysis of the system stability is based on the BoS definition that guarantees the necessary condition for stability and its borders are the Margins of Stability (MoS) \cite{Tiseo2016,Tiseo2018d}. In other words, it describes the regions where the system can be stabilised in the absence of external perturbations. The BoS model used in this work has been proposed in \cite{Tiseo2016, Tiseo2018d} and validated data in \cite{Tiseo2018a}. The BoS model in saddle space coordinates: \begin{equation} \label{Eq:extra} BoS \le \left\{ \begin{array}{lllc} y_{S}^2+x_{S}^2=( Y_{sLF})^2,& if& y_{S}\ge 0\\ & \& & x_{S}\le+d_h\\\\ y_{S}^2+x_{S}^2=(Y_{sRF})^2,& if& y_{S}\le 0\\ & \& & x_{S}\ge-d_h\\\\ \textit{Otherwise:}& &\\\\ x_{S}= +d_h,& if & x_{S} \ge 0 & \\\\ x_{S}= -d_h,& if & x_{S} \le 0 &\\\\ \end{array}\right. \end{equation} where ($x_{S}$, $y_{S}$) are the coordinates in the saddle space, $Y_{sLF}$ and $Y_{sRF}$ are the coordinates of the left and right CoP in the Saddle Space. The BoS can then be projected in the TS using the following relationship: \begin{equation} \label{eq:extra2} \begin{array}{ll} \left[ \begin{array}{l}x_{TS}\\ y_{TS}\end{array}\right]&=R(\lambda)\vec{x}_{S}+\vec{x}_{S0}=\\ &=\left[\begin{array}{cc} cos(\lambda) & -sin(\lambda)\\ sin(\lambda) & cos(\lambda)\end{array}\right] \left[\begin{array}{c} x_{S}\\ y_{S}\end{array}\right]+\\\\&+\left[\begin{array}{c} x_{S0}\\ y_{S0}\end{array}\right] \end{array} \end{equation} where $\lambda$ is the angle between $x_{TS}$-axis and the $x_{S}$-axis. \subsection{Stability Supervision} \label{Sec:2.2} The stability analysis for bipeds has always been a challenging problem. Particularly, the unavailability of an appropriate dynamic model that can fully capture the complex human-like bipedal locomotion makes it difficult to define the general stability criteria, used in the trajectory planning \cite{Font-Llagunes2009,Manchester2010,Hof2008,Buschmann2015,Lei2006,Pratt2006,Torricelli2016,Kuo2007}. For example, the ZMP model evaluates the foot placement which is then used to compute the desired CoM trajectory with a stabilisable behaviour via optimisation algorithms \cite{Pratt2006, Perrin2012,Carpentier2016}. We proposed two kinematic based stability criteria in this work to evaluate if a movement is compatible with the stability. Hence, they can be used either for the definition of constraints for motion planning optimisation algorithms, or for the stability evaluation from the movement kinematics. \begin{figure*}[ht] \begin{subfigure}[b]{0.6\textwidth} \centering \includegraphics[width=\textwidth]{figure6.eps} \caption{\centering\centering} \label{fig:06} \end{subfigure} \hfill \begin{subfigure}[b]{0.4\textwidth} \centering \includegraphics[width=\textwidth]{figure12.eps} \caption{\centering} \label{fig:12} \end{subfigure} \caption{(a) The elongations of the pendulum lengths required for reaching $CoP_0$ and $CoP_1$ are derived from the length of the circumference chord, which is centred in the pivoting points with the ground and has a radius $d_h=0.1$ m. The pivot has been placed in the heel during the HS, and it is located in the articulation between the metatarsus and the phalanges during TO. (b) Sample trajectory of the TO angle.} \end{figure*} \subsubsection{XCoM and Step Stability} \label{Sec:2.2.1} The step stability during walking is evaluated using the XCoM stability criterion and the maximum reachable distance. In fact, the XCoM allows to identify the minimum step length required for walking at a certain speed \cite{Hof2005,Hof2007,Hof2008}. Therefore, it helps to define the criterion for the step stability as shown in Figure \ref{fig:05}. \begin{equation} \label{eq:09} d_{SL/2} \textit{ }\in \textit{ } (d_{SL/2_{min}}=\frac{v_des}{2w_n} \textit{ },\textit{ } d_{SL/2_{Max}} ) \end{equation} where $w_n$ is the natural frequency of the inverted pendulum; $d_{SL/2_{min}}$ is half of the minimum step defined by the natural frequency of the pendulum; $d_{SL/2_{Max}}$ is half of the maximum step that can be performed by the biped. This allows us to establish the following metrics for the step stability: \begin{equation} \label{eq:10} \left \{ \begin{array}{l} S_{SL_{Pend}}(t,v_{CoMp})=\frac{M_{d_{SL/2}}(t)-d_{SL/2_{min}}(v_{CoMp})}{d_{SL/2}(v_{CoMp})-d_{SL/2_{min}}(v_{CoMp})} \\\\ S_{SL_{Jump}}(t,v_{CoMp})=\frac{M_{d_{SL/2}}(t)-d_{SL/2_{Max}}(v_{CoMp})}{d_{SL/2}(v_{CoMp})-d_{SL/2_{Max}}(v_{CoMp})} \end{array}\right. \end{equation} where $v_{CoMp}$ is the walking velocity, $M_{d_{SL/2}}$ is the half-step length expected as from the biped and $d_{SL/2}$ is the desired behaviour. In summary, equation (\ref{eq:09}) describes how to define the stable step length strategy for a generic bipedal structure. On the other hand, equation (\ref{eq:10}) evaluates the selected strategy against an optimal strategy thus providing a quantitative evaluation of the distance from the margins of stability. \subsubsection{Mediolateral Stability} \label{Sec:2.2.2} The ML stability evaluation is commonly based on the criterion that the CoM has to be constrained between the two CoPs in the ML direction \cite{Vlutters2016,VanMeulen2016,McAndrewYoung2012,Lugade2011,Hof2007}. \begin{equation} \label{eq:11} S_{SW}(t)=1-\frac{2|y_{CoM}(t)|}{d_{SW}(v_{CoMp})} \end{equation} \subsection{Stability Analysis: Relationship between BoS and Dynamic Stability} \label{Sec:2.3} To study the stability in the general case, let us consider the system energy described by the following equation: \begin{equation} \label{eq:12} E=U+K+W+E_P \end{equation} where $U$ is the potential energy of the CoM, $K$ is the kinetic energy, $W$ is the active work, and $E_p$ are the external perturbations. Therefore, the condition for achieving stability in a desired posture is: \begin{equation} \label{eq:13} Max(W)\ge U_{MoS}-U_{CoM}-K-E_p \end{equation} where $U_{CoM}$ and $U_{MoS}$ are the potential energies at the current CoM position and expected intersection with MoS, respectively. If the condition in equation (\ref{eq:13}) cannot be satisfied, then the system cannot reach a static equilibrium in the existing feet posture, and it should be reconfigured. In other words, a biped is stable as long as it is able to actively adsorb the excess energy (equation (\ref{eq:13})) to stop in the current feet posture, or if it can implement a stable locomotor strategy as described in equations (\ref{eq:10}) and (\ref{eq:11}). In conclusion, equation (\ref{eq:13}) enables to compute the region of attraction that the bipeds can generate around its CoM for a given posture. Further, it serves as a tool for the analysis of movement stability that can be represented as a continuous transition between stable postures. \subsubsection{BoS as Region of Attraction} \label{Sec:2.3.1} The region of attraction can be defined as the set of points where the system is Lyapunov's stable \cite{Manchester2010, Majumdar2013}. If we choose equation (\ref{eq:12}) as Lyapunov' s candidate, then the system is stable if and only if the following condition is satisfied: \begin{equation} \label{eq:15} \dot{E} = \dot{U}+ \dot{K}+ \dot{W}+ \dot{E}_P \le 0 \end{equation} in the absence of the external perturbations. The condition for Lyapunov's stability of a trajectory (\textit{C}) between the points A and B is: \begin{equation} \label{eq:16} W_\textit{C} \ge U(B) -U(A)+K -K_{des} \end{equation} where $W_{\textit{C}}$ is the maximum energy that the system can actively dissipate along \textit{C}, and $K_{des}$ is the kinetic energy of the desired trajectory. \subsubsection{BoS as Regions of Finite Time Invariance} \label{Sec:2.3.2} The region of attraction theory is valid for time-invariant systems, while our model is time variant because the potential energy depends on the body configuration. However, if the system is considered as time-invariant for small time intervals, then this set of points can be defined as a Region of Finite-Time Invariance \cite{Majumdar2013}. This method is commonly used for the control of systems in highly unstructured environments, which can be accurately predicted for short periods of time \cite{Majumdar2013}. Thus, using the BoS as the set of reachable stable points at a given configuration, the gravitational forces can be regarded as time-invariant within the BoS at every instant. Consequently, the BoS considered as a Region of Finite-Time Invariance, and the instantaneous stability can be evaluated using equation (\ref{eq:16}). \subsubsection{E-BoS for Global Stability and I-BoS for Local Stability:} \label{Sec:2.3.3} The regions of attraction and finite time invariance allows to evaluate the stability of the system used in different scenarios. The region of attraction is more suited for analysing the global stability of a task because it allows the estimation of the margin of stability for the chosen end-posture. Hence, it provides the expected region of attraction (Expected BoS, E-BoS) for a future posture. Instead, the control of the trajectory requires to consider the local stability conditions that take into account both the local dynamics and the unforeseeable perturbation. Therefore the Region of Finite time-invariance (Instantaneous BoS, I-BoS) is required for carrying out such evaluation. An example of the locomotion-related scenarios that allows understanding the difference between E-BoS and I-BoS is: \begin{itemize} \item \textit{Unperturbed walking on a flat surface}: This being a deterministic walking condition, there are no unpredictable external factors; hence, the E-BoS is a sufficient condition for stability. \item \textit{Perturbed gait}: People walking in everyday living environments are subject to a multitude of perturbations that cannot be predicted during planning. If we consider an unexpected push from behind, it introduces an unforeseeable increase in the kinetic energy along the forward direction. Hence, the I-BoS provides local information required for equation (\ref{eq:16}) to evaluate the system stability and to plan a response strategy in the altered state. \end{itemize} \subsection{Simulations} The simulations have been conducted with Matlab 2016 (Mathworks inc., USA) running on a Lenovo Y50 equipped with an Intel i7-4700HQ and 16 GB of memory. The simulation time is calculated with the \textit{run and time} function included in the software. The time step used in the simulations is 80 ms, which is based on the fastest Central Nervous System (CNS) response time to balance the perturbations \cite{Maki2007,McIlroy2003}. The simulations have been performed at velocities of 0.7, 1.0, 1.2 and 1.6 (m/s). The HS angles used are 5, 10 and 15 (deg). The feet postures have been selected to have the initial gait phase ($Phase_0$) equal to 0. The mean values of the KIT data are used for the body height and the mass parameters. The simulations have been executed for 2 steps or 1 stride, which leads to a change of gait phase from 0 to $\pi$, as shown in Figure \ref{eq:10}. An additional set of simulations has been performed with the Matlab timing function to evaluate the planning time for 1 and 10 consecutive strides, which includes the stability evaluation with equations (\ref{eq:10}) and \ref{eq:11}. Furthermore, the planner also calculates the gravitational forces and the MoS calculated with the model presented in \cite{Tiseo2016,Tiseo2018d}. \begin{figure*}[ht] \centering \begin{subfigure}[b]{0.49\textwidth} \includegraphics[width=\textwidth]{Figure7.eps} \caption{\centering\centering} \label{fig:07} \end{subfigure} \begin{subfigure}[b]{0.49\textwidth} \includegraphics[width=\textwidth]{Figure8.eps} \caption{\centering} \label{fig:08} \end{subfigure} \caption{(a) The evaluation of the planner's performance along the mediolateral direction has been conducted by evaluating the minimum of the lateral stability. (b) The introduction of the ankle strategies can justify the discrepancy in the vertical CoM trajectories between the human behaviour and the inverted pendulum model.} \end{figure*} \section{Results} \label{Sec:3} The results show that our model can reproduce the desired behaviour along the AP (Antero-Posterior) direction as shown in Figure \ref{fig:05}), while the behaviour along the ML (Medio-Lateral) direction as depicted Figure \ref{fig:07}, is within the human variability.Where it is shown that our planner can produce a behaviour which is compatible with human data from both the KITDB and Orendurff' s data \cite{Orendurff2004}. Furthermore, the vertical trajectories (Figure \ref{fig:08}) are sufficiently accurate for lower speeds, but they extend beyond human variability at the higher velocities. Proving how the ankle strategies allows humans to increase both the efficiency and the stability of their locomotion. Specifically, the increased length enables the CoM to reduce the inclination of the leg required to follow the desired trajectory on the transverse plane, thus minimizing the muscular effort via a more efficient redirection of the gravitational force through skeleton. Nevertheless, the error in tracking the vertical displacement of the CoM is significantly lower than the results obtained with a rigid pendulum. Although, the ankle strategies selected significantly improve the CoM vertical trajectory as shown in Figure \ref{fig:09n}, they are still not as smooth as the human cycloidal trajectories. Furthermore, the comparison between a trajectory from the proposed planner (Figure \ref{fig:09}) and a human trajectory from KITDB (Figure \ref{fig:10}) shows that human planning is consistent with our planner output. The human data also shows that the BoS tracks the movements of the CoM allowing the trajectory to occur on a funnel of points of equilibrium, which is a necessary condition for the Lyapunov's Stability. Lastly, there is a small portion of the trajectory which occurs outside of the BoS. Nonetheless, it does not compromise with the global stability of the system, because the swinging leg can reconfigure the system fast enough to drive the state back into the region of attraction before the foot landing occurs. These results suggest that the proposed model captures human planning strategies for both straight walking. \section{Discussion} \label{Sec:4} The obtained results indicate that it is possible to produce a computationally inexpensive human-like planning for straight walking using the Saddle Space model proposed in \cite{Tiseo2018a}. They also support our hypothesis that the divergence of the inverted pendulum model from the human behaviour can be justified by the presence of the ankle strategies. Although a simplified model used for the TO and HS movements does not provide an accurate human-like vertical trajectory, it can still generate a potential energy variation coherent with human behaviour, as shown in Figure \ref{fig:08}. \begin{figure*}[ht] \begin{center} \includegraphics[width=\textwidth]{Figure9.eps} \end{center} \caption{The trajectories of the CoM vertical movements generated from the proposed planner show how the regulation of the ankle strategies during both Toe-Off and Hill-Strike can significantly alter the CoM trajectory. Although the CoM oscillation amplitude is much closer to human behaviour than traditional inverted pendulum models, an improvement in ankle strategies model is still required to obtain a cycloid shape observed in human trajectories \cite{Carpentier2017}.} \label{fig:09n} \end{figure*} \subsection{Proposed Stability Metrics} The proposed stability metrics in this manuscript prove that is possible to evaluate the gait stability from the movement kinematics. Equation (\ref{eq:10}) combines the standard metrics in the kinematic constraints determined by the maximum reach of the leg with the dynamical constraints of the inverted pendulum models. Figure \ref{fig:05} shows how the planned strategy, that it is perfectly superimposed on the human reference behavior, is constrained from these conditions. Therefore, we can confirm the possibility of achieving a stable bipedal walking with a sufficiently long step length where the step frequency (candence) is greater than the natural frequency of inverted pendulum and smaller than the maximum reach of the leg. However, the legged locomotion is still achievable beyond the maximum reach of the legs using different strategies (i.e., running and jumping ). The other strategy described in equation (\ref{eq:11}) uses the step width and lateral excursion of the CoM to evaluate the mediolateral bipedal stability. Figure \ref{fig:08} elucidates that the human data from the two different datasets show the same trend of a slightly higher stability margin at higher speed. The numerical values obtained with the proposed planner are congruent with the range of variability observed in both data sets. \subsection{Considerations on the results generality} Although our results are limited to the straight walking, the following general observation on to human locomotion can be ascertained: \begin{itemize} \item Human legs movement tends to synchronize with the CoM trajectory that shifts the CoM close to $y_{Saddle}$. TSimilarly, the step to step transition tends to be along the direction of ZMP that simultaneously controls the angular momentums. \cite{Popovic2004,Popovic2004a,Pratt2006,Vlutters2016,Pratt2006}. Furthermore, the alignment of gravitational forces with $y_{Saddle}$ maximises the efficiency of the movement. \item Adequate planning and control of the ankle strategies drastically improves both the stability and efficiency of walking because they have a significant effect on the system energy expenditure. This observation is also supported by the other studies \cite{Kim2015,Ahn2012,Maki2007,Buschmann2015,Torricelli2016}. \item Our results also suggest that humans plan locomotion based on the predetermined optimised strategies. This is in agreement with the current motor control theories based on the observations that human movements are generated from a collection of stereotyped movements called dynamic primitives, which are influenced by external attractors \cite{Hogan2012,Zelik2014,Lacquaniti2012,Ajemian2010}. Therefore, the identification of simple kinematics parameters that allow reproducing a human-like walking suggests that locomotion can be regarded as a reaching task which is based on the dynamics constraints. \end{itemize} \subsection{Integration in the Hierarchical Control Architecture} \label{Sec:4.1} Human motor-control seems to rely on a hierarchical control architecture. The higher modules take care of complex action planning in the task space, and operate at low frequencies. While descending the hierarchical structure, we encounter faster modules which plan and control less complex actions accordingly to the directives of the higher controllers \cite{Ahn2012,Brock2000}. The proposed method provides a novel approach to the higher level planning for human locomotion, which was not feasible with the previous models. Instead, our model allows to reduce the space of solution for the joint space planner via the introduction of constraints derived from the characterization of the gravitational force field. In other words, the proposed analytical model allows us to identify the desired foot movement for a given CoM trajectory or \textit{vice versa}. This imposes constraints in the joint space and limits the number of available solutions. The identification of the via points also potentially allows the integration of obstacle avoidance with the step planning via a modified version of elastic bands method proposed for autonomous robot navigation \cite{Quinlan1993,Brock2000}. Such approach should produce a more human-like behaviour in navigation, where humans often diverge from the theoretically optimal trajectory \cite{Sreenivasa2015}. Figure \ref{fig:08} also implies that the energy cost of a step is greatly affected from an inefficient ankle strategy. This leads us to hypothesise that it is better to implement a suboptimal navigation trajectory towards the final desired posture rather than computing a highly optimised navigation, which may also be invalidated by unforeseeable changes in the environment. For example, it has been recently observed how humans plan their navigation considering the final position of orientation. Therefore, they can converge gradually towards the desired trajectory without having a disrupting effect on their locomotion strategies \cite{Sreenivasa2015}. This theory is also supported by clinical data, which show the underlying relationship between balance and locomotion \cite{haruyama2017,Hof2007, shen2016, Lugade2011, hornby2016}. However, previous models identified balance as a consequence of the physiological gait parameters rather then the cause. Therefore, reconsidering the rehabilitation approach under this new insight may result in a better activation of the brain neuroplasticity. \subsection{Limitations and Future Developments} The proposed planner is the first step in the development of a task-space planner for bipedal locomotion by taking the advantage of the intrinsic dynamics of the bipedal structure. However, the current results are limited to a simple task, and they do not take into account either for joint planning or multiple locomotion strategies. Thus further investigation is required to confirm our preliminary results and to validate the extendibility of this approach to different strategies. In the next phase, we will integrate our proposed model with a joint planner as proposed in \cite{Tommasino2016,Tommasino2017} and evaluate the performance. \begin{figure*} \centering \begin{subfigure}[b]{0.49\textwidth} \centering \includegraphics[width=\textwidth]{Figure10.eps} \caption{\centering} \label{fig:09} \end{subfigure} \begin{subfigure}[b]{0.49\textwidth} \centering \includegraphics[width=\textwidth]{Figure11.eps} \caption{\centering} \label{fig:10} \end{subfigure} \caption{(a) The planner output between the right and left foot via points shows how the movement strategy allows to generate a funnel of stable points between the two legs. The generation of such funnel is necessary for the existence of a stable trajectory leading from one point to the other. (b) A human trajectory from the KITDB is shown to exemplify how the CoM moves towards a trajectory that is consistent with our planner before approaching the saddle via point. The analysis of KITDB data also suggests how humans may desynchronise the swinging leg to deploy the gravitational force to accelerate and decelerate the CoM. In conclusion, the comparison between the output of the proposed planner (a) and a human trajectory (b) supports our claim that the proposed architecture can produce human-like task-space planning for straight walking trajectories. } \end{figure*} \section{Conclusion} \label{Sec:5} The proposed bioinspired task-space planner for straight walking has been proven to produce accurate human-like trajectories. This study allow us to identify that the low variability behaviours (e.g. Step Length and CoM Transversal Trajectory) are mainly driven by the task-space planning, while the high variability is regulated by the lower controller to manage the local stability and optimisation (e.g. Step Width and vertical CoM trajectory). Furthermore, it also defines and validates methods for the stability supervision and analysis that relies only on the kinematics states. Furthermore, they allow us to explain how we can estimate the balance of other human beings from they locomotion kinematics. \section*{Acknowledgements}{This work is extracted from the PhD Thesis of Carlo Tiseo \cite{Tiseo2018a}. The authors would like to thank Mr Michele Xiloyannis and Dr Wouter Wolfslag for proofreading and reviewing the paper.This research was supported by the A*STAR-NHG-NTU Rehabilitation Research Grant: "Mobile Robotic Assistive Balance Trainer" (RRG/16018). The research work of Kalyana C. Veluvolu was supported by the National Research Foundation (NRF) of Korea funded by the Ministry of Education, Science and Technology under Grants (NRF-2017R1A2B2006032) and (NRF-2018R1A6A1A03025109).} \section*{Conflicts of Interest}{The authors declare no conflict of interest.}
\section{Introduction \label{sec:intro}} The use of machine learning architectures is a relatively new trend in computational imaging and rapidly gaining popularity. Originally it was proposed for imaging through scatter using the older neural network format of support vector machines \cite{horisaki2016learning}. Subsequently, contemporary Deep Neural Networks (DNNs) have been applied successfully to the same problem of imaging through scatter \cite{lyu2017exploit, li2018imaging}, as well as tomography \cite{jin2017deep}, lensless quantitative phase retrieval \cite{sinha2017lensless, rivenson2018phase}, microscopy \cite{rivenson2017deep}, GHOST imaging \cite{lyu2017deep}, imaging through fiber bundles \cite{Borhani:18}, and imaging at extremely low light levels \cite{goy2018low}. The main motivation for the use of machine learning is to overcome certain deficits of traditional computational imaging approaches. The latter are based on convex optimization, structured so that the optimal solution is as close as possible to the true object. The functional to be minimized is specified by the physical model $H$ of the imaging process, also referred to as forward operator; and by prior knowledge $\Phi(f)$ about the class of objects being imaged, also known as regularizer. The inverse (estimate) $\hat{f}$ of an object $f$ is obtained from a measurement $g$ as \begin{equation} \hat{f}={\text{argmin}}_{f} \left\{\rule[-1ex]{0cm}{3ex} \left|\!\left| Hf-g \right|\!\right|^2 + \alpha \Phi(f) \right\} \label{eq:minfunc} \end{equation} The regularization parameter $\alpha$ expresses the imaging system designer's relative belief in the measurement {\it vs.} belief in the available prior knowledge about the object class. Clearly, the performance of (\ref{eq:minfunc}) in terms of producing acceptable inverses is crucially dependent upon correct and explicit knowledge of both $H$ and $\Phi$, and judicious selection of the parameter $\alpha$ \cite{liao2009selection}. In situations where this knowledge is questionable or not explicitly available, deep machine learning approaches become appealing as an effort to {\em learn} the missing knowledge implicitly through examples. Instead of (\ref{eq:minfunc}), the object estimate is then obtained as \begin{equation} \hat{f} = \text{DNN}(g), \label{eq:dnn} \end{equation} where $\text{DNN}(.)$ denotes the output of the trained deep neural network. Notation (\ref{eq:dnn}) may be used for other, non-deep machine learning structures even though they are generally less effective. However, strictly applied, (\ref{eq:dnn}) is limited to the special ``end-to-end'' design where the measurement $g$ from the camera is fed directly to the DNN. In some cases $g$ first goes through a physical pre-processor, and the pre-processor's output is fed into the DNN \cite{rivenson2018phase, goy2018low}; whereas in other cases $g$ is fed multiple times into a cascade of generator DNNs \cite{mardani2017recurrent} to assess the outputs at each step. Developing notation for and carrying out a full debate on the relative merits of these different approaches is beyond the scope of the present paper, where, in any case, we used the end-to-end method (\ref{eq:dnn}) only. Just as the performance of minimization principle (\ref{eq:minfunc}) depends upon knowledge of the operators $H$ and $\Phi$, performance of the DNN principle (\ref{eq:dnn}) depends on the specific DNN architecture chosen (number of layers, connectivity, etc.) and the quality of the training examples. It is the latter aspect of DNN design that we focus on in the present paper. More specifically, we are concerned with the spatial resolution that the DNN can achieve, depending on the spatial frequency content of the examples the DNN is trained with. We chose to study this question in the specific context of quantitative phase retrieval. This is a classical problem in optical imaging, because by virtue of its challenge it evokes elegant solutions and also because it has important applications in biology, medicine, and inspection for manufacturing and security. Traditional approaches include digital holography (DH) \cite{goodman1967digital, rivenson2010compressive, milgram2002computational, brady2009compressive, williams2013digital} and the related phase shifting interferometry method \cite{creath1985phase}, propagation based methods such as the Transport of Intensity Equation (TIE) \cite{teague1983deterministic, kou2010transport, paganin1998noninterferometric, schmalz2011phase, waller2010phase, waller2011phase, tian2013compressive, pan2014contrast, zhu2014low} and iterative methods such as the Gerchberg-Saxton-Fienup algorithm \cite{gerchberg1972practical, fienup1978reconstruction, gonsalves1976phase, fienup1986phase, bauschke2002phase}. The end-to-end residual convolutional DNN solution to lens-less quantitative phase retrieval is PhENN \cite{sinha2017lensless}, shown to be robust to errors in propagation distance and fairly well able to generalize to test objects from outside the databases used for training. In the present paper, we implemented PhENN in a slightly different optical hardware configuration, described in Section~\ref{sec:archi-opt}. The computational architecture, described in Section~\ref{sec:archi-dnn}, was similar to the original PhENN except here we used the Negative Pearson Correlation Coefficient (NPCC) as training loss function. This has a small beneficial effect in the reconstructions, but necessitates a histogram calibration procedure, described in Section~\ref{sec:cali}, to remove linear amplification and bias in the reconstructed phase images. From the point of view of the original inverse problem formulation (\ref{eq:minfunc}), PhENN in effect has to learn both the forward operator $H$ and the prior $\Phi$ at the entire range of spatial frequencies of interest. The examples presented to PhENN during training establish the spatial frequency content that is stored in the network weights contributing to the retrieval operation (\ref{eq:dnn}). In principle, this should be sufficient because, if the training examples are representative enough of the object class, then retrieval of each spatial frequency should be learnt proportionally to that spatial frequency's presence in the database. In practice, however, we found that spatial frequencies with relatively low representation in the database tend to be overshadowed by the more popular spatial frequencies, perhaps due to the nonlinearities in the network training process and operation. Invariably, high spatial frequencies tend to be less popular in most available databases. ImageNet, in particular, exhibits the well-known inverse-square power spectral density of natural images, as we verify in Fig.~\ref{fig:spec}. This means that high spatial frequencies are inherently under-represented in PhENN training. Compounded by the nonlinear suppression of the less popular spatial frequencies due to PhENN nonlinearities, as mentioned above, this results in low-pass filtering of the estimates and loss of fine detail. Detailed analysis of this effect is presented in Section~\ref{sec:train}. To better recover high spatial frequencies in natural objects then, one should emphasize high spatial frequencies more during training; this may be achieved, for example, by flattening the power spectral density of the training examples {\em before} they are presented to the neural network. It would appear that this spectral intervention violates the object class priors: PhENN does not learn the priors of ImageNet itself, it rather learns an edge-enhanced version of the priors. Yet, in practice, again probably because of nonlinear PhENN behavior, we found this spectral pre-modulation strategy to work quite well. The detailed approach and results are found in Section~\ref{sec:res-enh}. It is worth mentioning here that the first, to our knowledge, explicit experimental analysis of a DNN's spatial resolution was conducted on IDiffNet in the context of imaging through diffuse media \cite{li2018imaging}. We chose to pursue the issue further in the present paper but on a different optical problem because spatial resolution in quantitative phase retrieval, in addition to also being worthwhile, is not impacted by the extreme ill-posedness of diffuse media. Even though we have not tried extensively beyond phase retrieval, pre-processing of training examples by spectral manipulation might have merit for several other challenging imaging problems. \section{Imaging system architecture \label{sec:archi}} \subsection{Optical configuration \label{sec:archi-opt}} Our optical configuration is shown in Fig. \ref{fig:setup}. Unlike \cite{sinha2017lensless}, a transmissive spatial light modulator (SLM) (Holoeye, LC2012, pixel size $36\mu\text{m}$) is used in this system as a programmable phase object $f$ representing the ground truth. The transmissive SLM is coherently illuminated by a He-Ne laser light source (Research Electro-Optics, Model 30995, $633$nm). The light is transmitted through a spatial filter consisting of a microscope objective (Newport, M-60X, $0.85$NA) and a pinhole aperture ($D = 5\mu\text{m}$) and then collimated by a lens (focal length $200\text{mm}$) before illuminating the SLM. A telescope consisting of two plano-convex lenses $L_{1}$ and $L_{2}$ is placed between the SLM and a CMOS camera (Basler, A504k, pixel size $12\mu\text{m}$). The CMOS camera captures the intensity $g$ of the diffraction pattern produced by the SLM at a defocus distance $\Delta z=50\text{mm}$. The focal lengths of $L_{1}$ and $L_{2}$ are set to $f_{1}=150\text{mm}$ and $f_{2}=50\text{mm}$, respectively. As a result, this telescope demagnifies the object by a factor of $3$, consistent with the ratio between SLM and CMOS camera pixel sizes. An iris with diameter $5\text{mm}$ is placed at the pupil plane of the telescope to keep the $0^{\text{th}}$ diffracted order of the SLM and filter out all the other orders. The modulation performance of the SLM depends on the input and output polarizations, which are controlled by the polarizer $P$ and the analyzer $A$, respectively. In order to realize phase-mostly modulation, we set the incident beam to be linearly polarized at $310^{\circ}$ with respect to the vertical direction and also set the analyzer to be oriented at $5^{\circ}$ with respect to the vertical direction. The specific calibration curves for the SLM's modulation performance can be found in \cite{li2018quantitative}. In the present paper, all the training and testing objects are of size $256\times 256$. They are zero-padded to the size $1024\times768$, before being uploaded to the SLM. For the diffraction patterns captured by the CMOS camera, we crop the central $256\times256$ region for processing. \begin{figure}[h!] \centering\includegraphics[width=0.7\linewidth]{fig1} \caption{Optical configuration. SF: spatial filter; CL: collimating lens; P: linear polarizer; A: analyzer; SLM: spatial light modulator; L1 and L2: plano-convex lenses; F: focal plane of L2} \label{fig:setup} \end{figure} \subsection{Neural network architecture and training \label{sec:archi-dnn}} Similar to \cite{sinha2017lensless}, the phase extraction neural network (PhENN) that we implement in this paper follows the U-net architecture \cite{ronneberger2015u} and utilizes residuals to facilitate learning (ResNet \cite{he2016deep}.) The detailed architecture is shown in Fig. \ref{fig:PhENN}. PhENN input is the intensity $g$, and successively passes through $4$ down-residual blocks (DRBs) for feature extraction. The extracted feature map then successively passes through $4$ up-residual blocks (URBs) and $2$ residual blocks (RBs) for pixel-wise regression and at the last layer outputs the estimate $\hat{f}$ of the object phase. Skip connections are used in the architecture to pass downstream local spatial information learnt in the initial layers. More details about the structures of the DRBs, URBs and RBs can be found in \cite{sinha2017lensless}. \begin{figure}[h!] \centering\includegraphics[width=\linewidth]{fig2} \caption{Phase extraction neural network (PhENN) architecture} \label{fig:PhENN} \end{figure} Unlike \cite{sinha2017lensless}, here we use the Negative Pearson Correlation Coefficient (NPCC) as loss function \cite{li2018imaging} to train PhENN. The NPCC loss function is defined as \begin{equation} {\cal L}=\sum_k {\cal E}_{\text{NPCC}}\left(f_k, \hat{f}_k\right), \qquad \text{where} \end{equation} \begin{equation} {\cal E}_{\text{NPCC}}\left(f_k, \hat{f}_k\right)\equiv (-1)\times\frac{\sum_{i,j}^{}\left(\rule[-1ex]{0cm}{3ex} f_k(i,j)-\left<f_k\right>\right) \left(\rule[-1ex]{0cm}{3ex} \hat{f}_k(i,j)-\left<\hat{f}_k\right>\right)} {\sqrt{\sum_{i,j}\left(\rule[-1ex]{0cm}{3ex} f(i,j)-\left<f_k\right>\right)^2} \sqrt{\sum_{i,j}\left(\rule[-1ex]{0cm}{3ex} \hat{f}(i,j)-\left<\hat{f}_k\right>\right)^2}}; \label{eq:npcc} \end{equation} $f$ and $\hat{f}$ are the true object and the object estimate according to (\ref{eq:dnn}), respectively; the summations take place over all pixels $(i,j)$ and training example labels $k$; and $\left<.\right>$ denotes spatial averaging. We have found the NPCC to generally result in better DNN training in the problems that we examined, especially for objects that are spatially sparse \cite{li2018imaging}. However, some care needs to be taken when the estimate $\hat{f}$ is not affine-invariant; we discuss this immediately below. \subsection{Calibration of PhENN output trained with NPCC} \label{sec:cali} From the definition (\ref{eq:npcc}) it follows that for any function $\psi$ and arbitrary real constants $a$ and $b$ representing linear amplification and bias, respectively, \[ {\cal E}_{\text{NPCC}}(\psi, a\psi+b)=-1. \] In other words, a DNN trained with NPCC as loss function can only produce affine transformed estimates; there is no way to enforce the requirement $a=1$, $b=0$ which would guarantee linear amplification- and bias-free reconstruction and is especially important for quantitative phase imaging. Neither does there exist a way that we know of to predetermine the values of $a$ and $b$ through specific choices in DNN training. Therefore, after DNN training a calibration step is required to determine the values of $a$ and $b$ that have resulted so that they can be compensated. This is realized by histogram matching according to the process shown in Fig.~\ref{fig:cal}. Given a set of calibration data, we compute the cumulative distribution functions (CDFs) for the ground truth values as well as the PhENN output values, as shown in Fig.~\ref{fig:cal} (a) and (b). For an arbitrary value $f$ in the ground truth, we find its corresponding PhENN output value $\hat{f}$ that is at the same CDF level; and repeat the process for several $(f, \hat{f})$ samples. Subsequently, the values of $a$ and $b$ are determined by linear fitting of the form $\hat{f}=af+b$, as shown in Fig. \ref{fig:cal}(c). \begin{figure}[h!] \centering\includegraphics[width=0.6\linewidth]{fig3} \caption{Calibration process. (a) Cumulative distribution function (CDF) of the ground truth. (b) Cumulative distribution function (CDF) of the PhENN output. (c) Linear curve fitting.} \label{fig:cal} \end{figure} \section{Resolution analysis of ImageNet-trained PhENN \label{sec:train}} In \cite{sinha2017lensless}, we trained separate PhENNs using the databases Faces-LFW \cite{huang2007labeled} and ImageNet \cite{russakovsky2015imagenet} and found that both PhENNs generalize to test objects both within and outside these two databases. In the present paper, we restrict our analysis to the ImageNet database only. In the PhENN training phase, a total of $10,000$ images selected from the ImageNet database are uploaded to the SLM and the respective diffraction patterns are captured by the CMOS. For testing, we use a total of $471$ images selected from several different databases: $50$ Characters, $40$ Faces-ATT \cite{samaria1994parameterisation}, $60$ CIFAR \cite{krizhevsky2009learning}, $100$ MNIST \cite{lecun2010mnist}, $100$ Faces-LFW, $100$ ImageNet, $20$ resolution test patterns \cite{li2018imaging}, and $1$ all-zero (dark) image. The diffraction pattern corresponding to the all-zero image is used as the background. For every test diffraction pattern that we capture, we first subtract the background and then normalize, before feeding into the neural network. \subsection{Reconstruction results} The phase reconstruction results are shown in Fig. \ref{fig:qual}. Here, we use $100$ ImageNet test images as calibration data to compensate for the unknown affine transform effected by the NPCC-trained PhENN (Section~\ref{sec:cali}). As expected, PhENN is not only able to quantitatively reconstruct the phase objects within the same category as its training database (ImageNet), but also able to retrieve the phase for those test objects from other databases. This indicates that PhENN has indeed learned a model of the underlying physics of the imaging system or at the very least a generalizable mapping of low-level textures between the phase objects and their respective diffraction patterns. \begin{figure}[h!] \centering\includegraphics[width=0.7\linewidth]{fig4} \caption{Reconstruction results of PhENN trained with ImageNet. (a) Ground truth for the phase objects. (b) Diffraction patterns captured by the CMOS (after background subtraction and normalization). (c) PhENN output. (d) PhENN reconstruction after the calibration shown in Section \ref{sec:cali}. Columns (i-vi) correspond to the dataset from which the test image is drawn: (i) Faces-LFW \cite{huang2007labeled}, (ii) ImageNet \cite{russakovsky2015imagenet}, (iii) Characters, (iv) MNIST Digits \cite{lecun2010mnist}, (v) Faces-ATT \cite{samaria1994parameterisation}, or (vi) CIFAR \cite{krizhevsky2009learning}, respectively.} \label{fig:qual} \end{figure} \subsection{Resolution test \label{sec:res}} In order to test the spatial resolution our trained PhENN, we use dot patterns as test objects \cite{li2018imaging}, shown in Fig. \ref{fig:res} (a). Altogether $20$ dot patterns are tested, with spacing $D$ between dots gradually increasing from $2$ pixels to $21$ pixels. From the resolution test results shown in Fig. \ref{fig:res} it can be observed that the PhENN trained with ImageNet is able to resolve two dots down to $D=6$ pixels but fails to distinguish two dots with spacing $D\leq5$ pixels. Thus, $D\approx 6$ pixels can be considered as the Rayleigh resolution limit of this PhENN for point-like phase objects. \begin{figure}[h!] \centering\includegraphics[width=0.7\linewidth]{fig5} \caption{Resolution test for PhENN trained with ImageNet. (a) Dot pattern for resolution test. (b) PhENN reconstructions for dot pattern with $D=3$ pixels. (c) PhENN reconstructions for dot pattern with $D=5$ pixels. (d) PhENN reconstructions for dot pattern with $D=6$ pixels. (e) 1D cross-sections along the lines indicated by red arrows in (b)-(d).} \label{fig:res} \end{figure} \section{Resolution enhancement by spectral pre-modulation \label{sec:res-enh}} In our imaging system, the SLM pixel size limits the spatial resolution of the trained PhENN since the minimum sampling distance in all the training and testing objects displayed on the SLM equals one pixel $d_{p}=36\mu\text{m}$, or maximum spatial frequency $13.9\text{mm}^{-1}$. \footnote{L1 determines the aperture stop with diameter $25.4\text{mm}$, {\it i.e.} a numerical aperture NA$=12.7/150=0.0847$. The nominal diffraction-limited resolution should be $d_{0}=\lambda/(2\text{NA})=3.74\mu\text{m}$. That calculation is irrelevant to PhENN, since objets of that spatial frequency are never presented to it during training.} However, as we saw in Section \ref{sec:res}, the resolution achieved by our PhENN trained with ImageNet database is merely $6$ pixels ($216\mu\text{m}$), much worse than the theoretical value. The additional factor limiting the spatial resolution of the trained PhENN is the spatial frequency content of the training database. Generally, databases of natural objects, such as natural images, faces, hand-written characters, etc. do not cover the entire spectrum up to $1/(2 d_{0})$. For example, below we analyze the ImageNet database and show that it is dominated by low spatial frequency components, with the prevalence of higher spatial frequencies decreasing quadratically. During training, the neural network learns the particular prevalence of spatial frequencies in the training examples as prior $\Phi$, in addition to learning the physical forward operator $H$. What this implies is that the less prevalent spatial frequencies are actually learnt {\em against}, meaning that by presenting them less frequently we may be teaching PhENN to suppress or ignore them. In the rest of this section, we present evidence to corroborate this fact, and suggest as solution a pre-processing step that edge enhances the training examples as a way to impress their importance better upon PhENN. \subsection{Spectral pre-modulation} The 2D power spectral density (PSD) $S(u,v)$ for the $10,000$ images in the ImageNet is shown in Fig. \ref{fig:spec} (a \&b) in linear and logarithmic scales, respectively; and in cross-section along the spatial frequency $u$ in Fig. \ref{fig:spec} (c\& d). Not surprisingly \cite{van1996modelling}, the cross-sectional power spectral density follows a power law of the form $\left|u\right|^p$ with $p\approx-2$. \begin{figure}[h!] \centering\includegraphics[width=0.8\linewidth]{fig6} \caption{Spectral analysis of the ImageNet database. (a\& b) 2D normalized power spectral density (PSD) of the ImageNet database in linear and logarithmic scale. (c\& d) 1D cross-sections along the spatial frequency $u$ of (a\& b), respectively.} \label{fig:spec} \end{figure} Therefore, we may approximately represent the 2D PSD of ImageNet database as \begin{equation} S(u,v)\propto\left(\sqrt{u^2+v^2}\right)^{-2}=\frac{1}{u^2+v^2}. \end{equation} This is flattened by the inverse filter \begin{equation} G(u,v)=\sqrt{u^2+v^2}. \label{eq:G-edge} \end{equation} As expected, the high spatial frequency components in the image are amplified after the modulation, as can be seen, for example, in Fig. \ref{fig:fsm}. \begin{figure}[h!] \centering\includegraphics[width=0.7\linewidth]{fig7} \caption{Spectral pre-modulation. (a) Original image \cite{russakovsky2015imagenet}. (b) Modulated image. (c) Fourier spectrum of the original image. (d) Fourier spectrum of the modulated image.} \label{fig:fsm} \end{figure} \subsection{Resolution enhancement} We trained a new PhENN using training examples that were spectrally pre-modulated according to (\ref{eq:G-edge}). That is, we replaced every training example $f(i,j)$ with $f_{\text{e}}(i,j)$, where \begin{equation} F_{\text{e}}(u,v)=G(u,v)F(u,v) \label{eq:flatten} \end{equation} and $F$, $F_{\text{e}}$ are the Fourier transforms of $f$, $f_{\text{e}}$, respectively. We also collected the corresponding diffraction patterns $g_{e}(i,j)$. The test examples were left without modulation, {\it i.e.} the same as in the original use of PhENN described in Section \ref{sec:train}. All the training parameters were also kept the same. Both dot pattern and ImageNet test images were used to demonstrate the resolution enhancement, shown in Fig. \ref{fig:res2} and \ref{fig:demo}, respectively. \begin{figure}[h!] \centering\includegraphics[width=0.7\linewidth]{fig8} \caption{Resolution test for PhENN trained with examples from the ImageNet database with spectral pre-modulation according to (\protect{\ref{eq:flatten}}). (a) Dot pattern for resolution test. (b) PhENN reconstructions for dot pattern with $D=2$ pixels. (c) PhENN reconstructions for dot pattern with $D=3$ pixels. (d) PhENN reconstructions for dot pattern with $D=6$ pixels. (e) 1D cross-sections along the lines indicated by red arrows in (b)-(d).} \label{fig:res2} \end{figure} From Fig. \ref{fig:res2}, we find that with spectral pre-modulation of the training examples according to (\ref{eq:flatten}), PhENN is able to resolve two dots with spacing $D=3$ pixels. Compared with the resolution test results shown in Fig. \ref{fig:res}, it can be said that the spatial resolution of PhENN has been enhanced by a factor of $2$ with the spectral pre-modulation technique. In Fig. \ref{fig:demo}, for the same test image selected from ImageNet database, more details are recovered by the PhENN that was trained with spectrally pre-modulated ImageNet, albeit at the cost of amplifying some noisy features of the object, near edges most notably. \begin{figure}[h!] \centering\includegraphics[width=0.7\linewidth]{fig9} \caption{Resolution enhancement demonstration. (a) Ground truth for a phase object \cite{russakovsky2015imagenet}. (b) Diffraction pattern captured by the CMOS (after background subtraction and normalization). (c) Phase reconstruction by PhENN trained with ImageNet examples. (d) Phase reconstruction by PhENN trained with ImageNet examples that were spectrally pre-modulated according to (\protect{\ref{eq:flatten}}).} \label{fig:demo} \end{figure} We also investigated the effect of spectral post-modulation in the original PhENN; that is, if we use a PhENN trained without spectral pre-modulation, and modulate the PhENN output $\hat{f}(i,j)$ according to \begin{equation} \hat{F}_{\text{e}}(u,v)=G(u,v)\hat{F}(u,v) \label{eq:post-flatten} \end{equation} and $\hat{F}$, $\hat{F}_{\text{e}}$ are the Fourier transforms of $\hat{f}$, $\hat{f}_{\text{e}}$, respectively, do we obtain a similar resolution enhancement? The answer is no, as can be clearly verified from the results of Fig. \ref{fig:comp}. This negative result illustrates that in the original training scheme (without spectral pre-modulation) the fine details are indeed lost and not recoverable by simple means, e.g. linear post-processing. It also highlights the effect of the nonlinearity in PhENN's operation and bolsters our claim that spectral pre-modulation indeed does something non-trivial: it teaches PhENN a prior, namely how to recover high spatial frequency content. \begin{figure}[h!] \centering\includegraphics[width=0.7\linewidth]{fig10} \caption{Spectral post-modulation. (a) Output of PhENN trained with ImageNet. The same as Fig. \ref{fig:demo} (c). (b) Modulated output.} \label{fig:comp} \end{figure} \section{Conclusions} The spectral flattening approach (\ref{eq:flatten}) as pre-modulation is a simple approach that we found to be effective in enhancing PhENN's resolution by a factor of $2$ when trained and tested on ImageNet examples. We have not investigated the performance of other (non-flattening) filters; indeed, it would be an interesting theoretical question to ask: given a particular form of the PSD in the training examples, what is the optimal spectral pre-modulation for improving spatial resolution? It is also worth repeating the concern about the priors that PhENN is learning from the spatially pre-modulated examples, that we pointed out in Section~\ref{sec:intro}. The amplification of certain noise artifacts, clearly seen in the result of Fig. \ref{fig:demo}(d), shows that, in addition to learning how to resolve fine details in the artifact, PhENN has learnt, somewhat undesirably, to edge enhance (since all the examples it was trained with were also edge enhanced.) These observations should present fertile ground for further improvements upon the work presented here. \section*{Funding} This research was funded by the Singapore National Research Foundation through the SMART program (Singapore-MIT Alliance for Research and Technology) and by the Intelligence Advanced Research Projects Activity (iARPA) through the RAVEN Program.
\section{Introduction} \section{Chiral Quark Soliton Model } In this report we summarize our recent works on heavy baryons \cite{Yang:2016qdz}\nocite{Kim:2017jpx,Kim:2017khv}--\cite{Praszalowicz:2018upb} where we have applied the Chiral Quark Soliton Model ($\chi$QSM) to the baryonic systems with one heavy quark. An expanded version of this report has been published in Ref.~\cite{Praszalowicz:2018uoa} where a complete list of reference can be found. There are two other contributions based on \cite{Yang:2016qdz}\nocite{Kim:2017jpx,Kim:2017khv}--\cite{Praszalowicz:2018upb} that have been already published elsewhere ~\cite{Praszalowicz:2017cwk,Praszalowicz:2018azt}. The $\chi$QSM \cite{Diakonov:1987ty} (for review see Ref.~\cite{Christov:1995vm} and references therein) is based on an old argument by Witten \cite{Witten:1979kh} that in the limit of a large number of colors ($N_{\rm c} \rightarrow \infty$), $N_{\rm val}=N_{\rm c}$ relativistic valence quarks generate chiral mean fields represented by a distortion of a Dirac sea that in turn interacts with the valence quarks themselves. The soliton configuration corresponds to the solution of a pertinent Dirac equation for the constituent quarks (with gluons integrated out) in the mean-field approximation, where the mean fields respect so called {\em hedgehog} symmetry. This means that neither spin ($\bm{S}$) nor isospin ($\bm{T}$) are {\em good} quantum numbers. Instead a {\em grand spin} $\bm{K}=\bm{S}+\bm{T}$ is a {\em good} quantum number. In Ref.~\cite{Yang:2016qdz}, following \cite{Diakonov:2010zz}, we have observed that the same argument holds for $N_{\rm val}=N_{\rm c}-1$, which allows to replace one light valence quark by a heavy quark $Q=c$ or $b$. \begin{figure}[h] \centering \includegraphics[width=9.0cm]{levels1.jpg} \vspace{-0.2cm}\caption{Schematic pattern of light quark levels in a self-consistent soliton configuration. In the left panel all sea levels are filled and $N_{c}$ (=3 in the Figure) valence quarks occupy the $K^{P}=0^{+}$ lowest positive energy level. Unoccupied positive energy levels are dpicted by dashed lines. In the middle panel one valence quark has been stripped off, and the soliton has to be supplemented by a heavy quark not shown in the Figure. In the right panel a possible excitation of a sea level quark, conjectured to be $K^{P}=1^{-}$, to the valence level is shown, and again the soliton has to couple to a heavy quark. Strange quark levels that exhibit different filling pattern are not shown.}% \label{fig:levels}% \end{figure} For light baryons the ground state soliton configuration corresponds to the occupied $K^P=0^+$ valence level, (with $N_{\rm val}=N_{\rm c}$) as shown in Fig.~\ref{fig:levels}.a. Therefore the soliton does not carry definite quantum numbers except for the baryon number resulting from the valence quarks. It is also possible that one of the valence quarks gets excited to some $K>0$ level (see {\em e.g.} \cite{Petrov:2016vvl}), which influences the quantization of the soliton spin emerging when the rotations in space and flavor are quantized. The resulting {\em collective} hamiltonian is analogous to the one of a symmetric top with the following constraints: \begin{enumerate} \item allowed SU(3) representations must contain states with hypercharge $Y^{\prime}=N_{\rm val}/3$, \item the isospin $\bm{T}^{\prime}$ of the states with $Y^{\prime}% =N_{\rm val}/3$ couples with the soliton spin $\bm{J}$ to $\bm{K}$, which is 0 for the ground state configuration but may be non-zero for an excited state: $\bm{T}^{\prime}+\bm{J}=\bm{K}$. \end{enumerate} For light baryons $N_{\rm val}=N_{c}, \; K^P=0^+$, and as a result the lowest lying positive parity baryons belong to the SU(3)$_{\rm flavor}$ octet of spin 1/2 and decuplet of spin 3/2. The first {\rm exotic} representation is $\overline{\mathbf{10}}$ of spin 1/2 with the lightest state corresponding to the putative $\Theta^{+}(1540)$~\cite{Diakonov:1997mm}. The model has been successfully tested in the light baryon sector \cite{Christov:1995vm}. \section{$\chi$QSM and heavy baryons} Recently~\cite{Yang:2016qdz} , following Ref.~\cite{Diakonov:2010zz}, we have made a proposal how to generalize the above approach to heavy baryons, by stripping off one valence quark from the $K^P=0^+$ level, as shown in Fig.~\ref{fig:levels}.b, and replacing it by a heavy quark to neutralize the color. The only difference to the previous case is the quantization condition, since $N_{\rm val}=N_{\rm c}-1$. The lowest allowed SU(3) representations are in this case $\overline{\mathbf{3}}$ of spin 0 and ${\mathbf{6}}$ of spin 1 shown in Fig.~\ref{fig:irreps}. \begin{figure}[h] \centering \includegraphics[height=5cm]{irreps_HB_0.jpg} \caption{Rotational band of a soliton with one valence quark stripped off. Soliton spin corresponds to the isospin $T^{\prime}$ of states on the quantization line $Y^{\prime}=2/3$. We show three lowest allowed representations: antitriplet of spin 0, sextet of spin 1 and the lowest exotic representation $\overline {\mathbf{15}}$ of spin 1 or 0. Heavy quark has to be added.} \label{fig:irreps}% \end{figure} As a result both ${\mathbf{6}}-\overline{\mathbf{3}}$ splitting and the $m_s$ splittings inside these multiplets are {\em predicted} using as an input the light sector spectrum \cite{Yang:2016qdz} except for a hyperfine splitting of {\bf 6} due to the spin-spin interaction of a soliton and a heavy quark that has been parametrized phenomenologically. Moreover, we have calculated the decay widths \cite{Kim:2017khv}, which are in surpriingly good agreement with the data (see Fig.~\ref{fig:charmwidths} for charm baryons decay widths). \begin{figure}[h] \centering \includegraphics[height=7cm]{Gammac.pdf} \caption{Decay widths of the charm baryons. Red full circles correspond to our theoretical predictions. Dark green triangles correspond to the experimental data~\cite{Patrignani:2016xqp}. Data for decays 4 -- 6 of $\Sigma_{c}(\mathbf{6}_{1},3/2)$ have been divided by a factor of 5 to fit within the plot area. Widths of two LHCb \cite{Aaij:2017nav} $\Omega_{c}$ states that we interpret as pentaquarks are plotted as black full squares with theoretical values shown as red full circles. }% \label{fig:charmwidths}% \end{figure} \section{Excitations of heavy baryons} The $\chi$QSM allows for two kinds of excitations ~\cite{Kim:2017jpx}. Firstly, higher SU(3) representations, similar to the antidecuplet in the light sector, appear in the rotational band of the soliton of Fig.~\ref{fig:levels}.b. The lowest possible exotic SU(3) representation is $\overline{\mathbf{15}}$ of positive parity and spin 1 ($\overline{\mathbf{15}}$ of spin 0 is heavier) shown in Fig.~\ref{fig:irreps}. Second possibility corresponds to the excitation of the sea quark from the $K^P=1^{-}$ sea level to the valence level~\cite{Diakonov:2010zz} depicted in Fig.~\ref{fig:levels}.b (or alternatively valence quark excitation to the first excited level\footnote{We thank Victor Petrov for pointing out this possibility.} of $K^P=1^{-}$). In this case the parity is negative but the rotational band is the same as in Fig.~\ref{fig:irreps} with, however, different quantization condition, since $J$ and $T'$ have to couple to $K=1$. We have shown that the model describes well the only fully known spectrum of negative parity antitriplets of spin 1/2 and 3/2~\cite{Kim:2017jpx}. There has been no experimental evidence for the sextet until recent report of five $\Omega^0_{c}$ states by the LHCb~\cite{Aaij:2017nav} and later by BELLE~\cite{Yelton:2017qxg}. In the sextet case the quantization condition requires the soliton spin to be quantized as $J=0,1$ and 2. By adding one heavy quark we end up with five possible total spin $S$ excitations for $J=0$: $S=1/2$, for $J=1 $: $S=1/2$ and 3/2, and for $J=2$: $S=3/2$ and 5/2. Although the number of states coincides with the experimental results~\cite{Aaij:2017nav,Yelton:2017qxg}, it is not possible to accommodate all five $\Omega^0_c$ states within the constraints imposed by the $\chi$QSM~\cite{Kim:2017jpx}. We have therefore {\em forced} model constraints (note that in the $\mathbf{6}$ case we cannot predict the mass splittings, since there is a new parameter in the splitting hamiltonian that corresponds to the transition of Fig.~\ref{fig:levels}.c, which is not known from the light sector), which allows to accommodate only three out of five LHCb states (see black vertical lines in Fig.~\ref{fig:Omegas}). Two heaviest $\chi$QSM states (green lines in Fig.~\ref{fig:Omegas}) lie already above the decay threshold to heavy mesons, and it is quite possible that they have very small branching ratio to the $\Xi^+_c+K^-$ final state analyzed by the LHCb. Two remaining states indicated by dark-blue arrows in Fig.~\ref{fig:Omegas}, which are hyper fine split by 70~MeV (as the ground state sextets that belong to the same rotational band), can be therefore interpreted as the members of exotic $\overline{\mathbf{15}}$ of positive parity shown as a red dot in Fig.~\ref{fig:irreps}. This interpretation is reinforced by the decay widths, which can be computed in the model. These widths are of the order of 1~MeV and agree with the LHCb measurement (see Fig.~\ref{fig:charmwidths}). Such small widths are in fact expected in the present approach, since the leading $N_{\rm c}$ terms of the relevant couplings cancel in the non-relativistic limit~\cite{Praszalowicz:2018upb}. \begin{figure}[h] \centering \includegraphics[width=9.0cm]{LHCb_Omegas.pdf} \vspace{-0.2cm} \caption{Spectrum of the $\Omega^0_c$ states \cite{Aaij:2017nav} with theoretical predictions of the present model}% \label{fig:Omegas}% \end{figure} Our identification implies the existence of the {\it isospin} partners of $\Omega^0_c$ in the $\overline{\mathbf 15}$. They can be searched for in the mass distribution of $\Xi_c^0+K^-$ or $\Xi_c^+ + \bar K^0$. Our model applies also to the bottom sector, and -- where the data is available -- it describes very well both masses and decay widths~\cite{Yang:2016qdz,Kim:2017khv}. \section*{Acknowledgments} It is a pleasure to thank my collaborators H.-C.~Kim, M.V.~Polyakov and G.S.~Yang. This work was supported by the Polish NCN grant 2017/27/B/ ST2/01314.
\section{Introduction}\label{sec:intro} Quantum tomography is the canonical procedure for diagnosing and characterizing quantum states and operations. The main goal of quantum tomography is to obtain detailed information that would allow us to improve the performance of a quantum device. However, extracting this information from experimental data is generally a hard task, even for small-sized systems. In addition, as the resources for quantum tomography scale exponentially with the number of subsystems, fully characterizing the system is experimentally impractical, even for systems with a moderate number of qubits, and under strong assumptions such as purity and unitary dynamics~\cite{gross2010quantum,kalev2015quantum,ODonnell2016,Haah2017Sample}. Therefore, rather than focusing on error diagnosis of quantum processors, we are often concerned with the simpler question of validation: e.g., checking how close is the state of the system to a {\it target} state, where usually closeness is quantified by the fidelity figure of merit. Along this thread, Flammia and Liu~\cite{Flammia2011Direct}, and da Silva~{\it et al.}~\cite{daSilva2011Practical} proposed a measurement scheme, known as \emph{direct fidelity estimation}, tailored to estimate the fidelity between the (unknown) state of the system and a target state, without the need to perform full quantum tomography. In this work, we are interested in cases where the target state is an $n$-qubit stabilizer state. Stabilizer states constitute an important class of states, used for teleportation-based~\cite{Gottesman1999Demonstrating} and measurement-based \cite{Raussendorf2001One} quantum computation, quantum error-correction codes~\cite{Gottesman1997Stabilizer}, and quantum self-testing~\cite{Breiner2018Parallel}. For such states, the result in~\cite{Flammia2011Direct} and~\cite{daSilva2011Practical} translates into a measurement of $\mathcal{O}(\epsilon^{-2}\ln(1/\delta))$ Pauli observables (picked at random from a distribution which depends on the target state), where $\epsilon$ and $\delta$ are small user-defined quantities related to the estimation error and the failure probability of the direct fidelity estimation scheme, respectively. Importantly, the number of observables is independent of $n$. In practice though, to obtain a modest, say $1\%$, estimation error with $2/3$ success probability, we would require a measurement of roughly $10^4$ Pauli observables. Here, we propose a practical scheme for validating an $n$-qubit stabilizer state by measuring exactly $n$ Pauli observables, which makes it relevant for small- to moderate-sized systems. The measurements can be realized by single-qubit gates, and the observables can be a priori chosen based on the target state. We also give an explicit, straightforward, formula for the worst-case fidelity, i.e., the minimum fidelity between the target stabilizer state and any state consistent with the measured data. Moreover, we show that the worst-case fidelity can be certified, with high probability, using ${\cal O}\left(n \epsilon^{-2} \ln(1/\delta)\right)$ copies of the state of the system for each measured observable. When the worst-case fidelity is close to one, we prove that one can use our scheme to obtain a high-fidelity estimate of the state of the system. The paper is organized as follows. In the next section we set up the notation and briefly review the notions of quantum state validation and stabilizer states. In Sec.~\ref{sec:valid}, we describe a validation scheme for stabilizer states and prove its certification guarantees. Then in Sec.~\ref{sec:exp}, we apply our scheme to validate the preparation of a three-qubit GHZ state on a trapped-ion quantum computing platform~\cite{Debnath16} and superconducting quantum computing platform~\cite{IBMQ}. Finally we close with a discussion on Sec.~\ref{sec:disc}. \section{Background and setup}\label{sec:background} To set up the notions and notation used in this work, we first briefly review the basic idea of state validation and the theory of stabilizer states. In what follows, we refer to a quantum state \emph{validation protocol} as a measurement scheme that, in the noiseless case, certifies with probability one that the state of the system is the target state, {\it if and only if} this is the case. In the presence of experimental noise, a validation scheme should provide a certification for the worst-case fidelity. Unlike quantum tomography, in a validation protocol we may choose the measurement scheme to depend on the target state. For example, given a target state $\ket{\Psi_0}$ we may consider the two-outcome positive-operator valued measure (POVM) $\left\{E_0=\ket{\Psi_0}\bra{\Psi_0},E_1=\mathbb{1}-\ket{\Psi_0}\bra{\Psi_0} \right\}$ as a validation scheme. In this case, the worst-case fidelity is the frequency of occurrence of the outcome $E_0$. If $\ket{\Psi_0}$ is an entangled state, implementing such a POVM would involve applying a non-local unitary to the state of the system. In contrast, in this work we propose a validation scheme for a target $n$-qubit stabilizer state that consists of experimentally accessible measurements of Pauli observables that can be realized using single-qubit quantum gates. In a nutshell, an $n$-qubit stabilizer state, $\ket{\Psi_0}$, is the unique eigenstate, with eigenvalue $1$, of $2^n$ commuting $n$-qubit Pauli operators $\{P_l\}_{l=1}^{2^n}$, where $P_l\in\{\pm 1,\pm i\}\cdot\{I,X,Y,Z\}^{\otimes n}$, and $I,X,Y,Z$ are the identity and the Pauli matrices on one qubit. Hereafter, we set $P_{2^n}=\mathbb{1}\equiv I^{\otimes n}$. The set $\{P_l\}_{l=1}^{2^n}$ forms the \emph{stabilizer group} $\mathcal{S}$. This group is generated by a set of $n$ Pauli operators (their choice is not unique) denoted here by $\mathcal{G}\subset\mathcal{S}$. The stabilizer state can then be written as, \begin{equation}\label{eq:stab} \rho_0\equiv\ket{\Psi_0}\bra{\Psi_0}=\frac1{2^n}\prod_{P_l\in \mathcal{G}}\Bigl(\mathbb{1}+P_l\Bigr)=\frac1{2^n}\sum_{P_l\in \mathcal{S}}P_l. \end{equation} \section{Validation of stabilizer states}\label{sec:valid} As reflected by Eq.~\eqref{eq:stab}, $\ket{\Psi_0}$ is the unique eigenstate, with eigenvalue $+1$ of the $n$ generators $P_l\in \mathcal{G}$. This, in turn, implies that the solution to the feasibility problem: \begin{equation} \begin{aligned} & \underset{\rho \in \mathbb{C}^{2^n \times 2^n}} {\text{find}} & & \rho\\ & \text{subject to} & & \text{Tr}(\rho P_l) =1,\;\forall P_l\in \mathcal{G}, \\ & & & \rho \succeq 0, \; \text{Tr}(\rho) =1, \end{aligned} \label{prog:feas} \end{equation} is a singleton, $\rho_0$. To see that, assume that there exists a density matrix $\rho_1\neq\rho_0$ which is a solution to the feasibility problem above. When writing it in its eigenbasis, $\rho_1=\sum_j\lambda_j\ket{\psi_j}\bra{\psi_j}$, the feasibility conditions $\text{Tr}(\rho_1 P_l) =1$ imply that $\sum_j\lambda_j\bra{\psi_j}P_l\ket{\psi_j}=1, $ $\forall P_l\in \mathcal{G}$. Since the $P_l$'s have eigenvalues $\pm1$ we have $-1\leq\bra{\psi_j}P_l\ket{\psi_j}\leq1$, and due to the positivity of the $\lambda_j$'s we obtain the inequality $-1=-\sum_j\lambda_j\leq\sum_j\lambda_j\bra{\psi_j}P_l\ket{\psi_j}\leq\sum_j\lambda_j=1$. The upper bound is obtained when $\bra{\psi_j}P_l\ket{\psi_j}=1, ~\forall P_l\in\mathcal{G}$ and $\forall ~\ket{\psi_j}$ in the eigenbasis of $\rho_1$. But since, by definition, $\ket{\Psi_0}$ is the unique pure state for which $\bra{\Psi_0}P_l\ket{\Psi_0}=1$, $\forall P_l\in\mathcal{G}$, we obtain $\rho_1=\rho_0$ in contradiction to our initial assumption. Note, however, that while $\rho_0$ is the unique solution to program~\eqref{prog:feas}, there are infinitely many Hermitian matrices with negative eigenvalues (i.e., that do not satisfy the constraint $\rho \succeq 0$ above) for which $\text{Tr}(\rho P_l) =1,\;\forall P_l\in \mathcal{G}$. All of which have the structure $\frac1{2^n}\sum_{P_l\in \mathcal{S}}P_l +\sum_{P_l\notin \mathcal{S}}c_l P_l$ (considering those with trace 1) for some real numbers $c_l$. Therefore, constraining on density matrices in~\eqref{prog:feas} is crucial to obtain a singleton solution. Hence, in the absence of noise, the only quantum state that is consistent with the noiseless ``data'' $\text{Tr}(\rho P_l) =1,\;\forall P_l\in \mathcal{G}$, is the stabilizer state $\ket{\Psi_0}$. Therefore, given a target $n$-qubit stabilizer state, we can consider the measurement of the expectation values of a set of $n$ generators as a validation scheme. Since the generators are mutually commuting, there is, in principle, a measurement scheme to measure them simultaneously. Consider, for example, the case where the target state is the $n$-qubit GHZ stabilizer state $\ket{\textrm{GHZ}_n}=\frac1{\sqrt 2}(\ket{0}^{\otimes n}+\ket{1}^{\otimes n})$, where $\{\ket{0},\ket{1}\}$ are the eigenbasis of the $Z$ Pauli matrix. To validate that this is indeed the state of the system, we have the freedom to choose a specific set of generators that can be measured. A convenient choice of stabilizer generators are the $n$ Pauli observables, $X^{\otimes n}$ and $Z_k \otimes Z_{k+1}$ for $k=1,\ldots,n-1$. We can measure the expectation values of these observables with two simple experimental setups, for any $n$. In the first setup, we measure all the qubits in the $X$ basis, while in the second setup we measure all the qubits in the computational basis, $Z$. The expectation values of the generators above can be calculated from the experimental results. Note that these measurements only involve single-qubit gates. We note that, since in the noiseless case the feasibility program~\eqref{prog:feas} has a unique solution, due to convexity, in the presence of small experimental noise, the argument solution to: \begin{equation} \begin{aligned} & \underset{\rho \in \mathbb{C}^{2^n \times 2^n}} {\text{minimize}} & & \mathcal{C}(\rho)\\ & \text{subject to} & & \text{Tr}(\rho P_l) =1-\varepsilon_l,\;\forall P_l\in \mathcal{G}, \\ & & & \rho \succeq 0, \; \text{Tr}(\rho) =1, \end{aligned} \label{prog:conv} \end{equation} where $\mathcal{C}(\rho)$ is a convex function of $\rho$, and $\varepsilon_l\geq0$ captures experimental errors, is guaranteed to be close, in fidelity, to $\rho_0$ (which is assumed to be close to the state of the system). This follows directly from our result, Proposition~1 below, which implies that, in the case of small $\varepsilon_l$'s, the argument solution to program~\eqref{prog:conv} have fidelity at least $1-\frac1{2}\sum_{l:P_l\in \mathcal{G}} \varepsilon_l$ with the target state of the system. Next, we show that the proposed validation scheme leads to an experimentally-useful lower bound on the worst-case fidelity to the target stabilizer state. Since $\rho_0$ is a pure state, the fidelity between $\rho_0$ and any other state $\rho$ is $F=\text{Tr}(\rho_0\rho)$. Thus, given the experimental data for the expectation values of the generators, $\tilde{\mu}_1,\ldots,\tilde{\mu}_n$, to find a lower bound on the worst-case fidelity, we can solve the convex program: \begin{equation} \begin{aligned} & \underset{\rho \in \mathbb{C}^{2^n \times 2^n}} {\text{minimize}} & & \text{Tr}(\rho_0\rho)\\ & \text{subject to} & & \text{Tr}(\rho P_l) =\tilde{\mu}_l,\;\forall P_l\in \mathcal{G}, \\ & & & \rho \succeq 0, \; \text{Tr}(\rho) =1. \end{aligned} \label{prog:fid} \end{equation} \medskip {\it Proposition 1:} If $\sum_{l:P_l\in \mathcal{G}}\frac{1-\tilde{\mu}_l}{2}\leq 1$, the solution to program~\eqref{prog:fid} is \begin{equation}\label{eq:fid_min} F_\text{min}=1-\sum_{l:P_l\in \mathcal{G}}\frac{1-\tilde{\mu}_l}{2} \end{equation} Otherwise, if $\sum_{l:P_l\in \mathcal{G}}\frac{1-\tilde{\mu}_l}{2}> 1$, the solution to program~\eqref{prog:fid} is $F_\text{min}=0$. \medskip {\it Proof:} Let us order the stabilizer operators such that $P_0,\ldots,P_{n-1}$ are the measured generators. Then, an $n$-qubit density matrix that is consistent with the data is given by \begin{equation}\label{eq:estimate1} \rho=\frac1{2^n} \left(\mathbb{1}+\sum_{l=0}^{n-1} \tilde{\mu}_l P_l +\sum_{l=n}^{2^n -1} x_l P_l\right). \end{equation} We can add more terms to $\rho$, in the subspace that lies outside the stabilizer group, and due to the orthogonality property of Pauli observables ($\text{Tr}(P_i P_j)\propto\delta_{i,j}$) the resulting state would be still consistent with the measured data. However, for the same reason, adding such terms will not change the fidelity with $\ket{\Psi_0}$. Therefore, for the purpose of the proof, without loss of generality, we can consider the density matrix of~\eqref{eq:estimate1} as the most general state consistent with the data. Since the Pauli observables in the stabilizer group are mutually commuting, $\rho_0=\ket{\Psi_0}\bra{\Psi_0}$ and $\rho$ of Eq.~\eqref{eq:estimate1} are commuting, thus can be diagonalized simultaneously. Therefore, it is convenient to re-write $\rho$ of Eq.~\eqref{eq:estimate1} as \begin{equation}\label{eq:estimate2} \rho=\lambda_0\ket{\Psi_0}\bra{\Psi_0}+\sum_{k=1}^{2^n-1}\lambda_k \ket{\Psi_k}\bra{\Psi_k}. \end{equation} where $\left\{\ket{\Psi_k} \right\}_{k=0}^{2^n-1}$ forms an orthonormal basis for the Hilbert space of $n$ qubits, such that for all $k$ and $P_l\notin\mathcal{S}$, $\bra{\Psi_k}P_l\ket{\Psi_k}=0$. In the form of Eq.~\eqref{eq:estimate2}, it is clear that program~\eqref{prog:fid} minimizes the eigenvalue $\lambda_0$, or equivalently maximizes $\sum_{k=1}^{2^n-1}\lambda_k$, while keeping all the eigenvalues non-negative. At this point, we have the freedom to choose the basis vectors $\{\ket{\Psi_k}\}_{k=1}^{2^n-1}$. A suitable choice is to define these vectors through the projection operators $\frac{\mathbb{1}\pm P_l}{2}$ associated with the stabilizer generators $P_l$, $l=0,\ldots,n-1$, that is, \begin{equation}\label{eq:basis} \ket{\Psi_k}\bra{\Psi_k} = \prod_{l=0}^{n-1}\frac1{2}\Bigl(\mathbb{1}+(-1)^{b_{l}^{(k)}}P_{l}\Bigr), \end{equation} for $k=0,1,\ldots,2^n-1$, and $b_{l}^{(k)}=\{0,1\}$ is the $l$-th bit in the binary representation of $k$, $k=\sum_{l=0}^{n-1} b_l^{(k)} 2^l$. Writing $\rho$ in this basis we obtain \begin{equation}\label{eq:estimate3} \rho=\sum_{k=0}^{2^n-1}\lambda_k \prod_{l=0}^{n-1}\frac1{2}\Bigl(\mathbb{1}+(-1)^{b_{l}^{(k)}}P_{l}\Bigr). \end{equation} The condition that $\rho$ should be consistent with the data implies that $\text{Tr}(\frac{\mathbb{1}-P_l}{2}\rho)=\frac{1-\tilde{\mu}_l}{2}$ for all generators $P_l\in \mathcal{G}$. Using the expression for $\rho$ of Eq.~\eqref{eq:estimate3} together with the relations $\frac{\mathbb{1}-P_l}{2}\frac{\mathbb{1}+P_l}{2}=0$, and $\bigr(\frac{\mathbb{1}-P_l}{2}\bigl)^2=\frac{\mathbb{1}-P_l}{2}$, yields the set of $n$ constrains \begin{equation}\label{eq:constraints1} \text{Tr}\Bigl(\frac{\mathbb{1}-P_{l}}{2}\rho\Bigr)=\frac{1-\tilde{\mu}_l}{2}=\sum_{k:b_l^{(k)}=1}\lambda_{k}, \end{equation} for $l=0,1,\ldots,n-1$. Since the eigenvalues of the Pauli observables are $\pm1$, the experimental values $\tilde{\mu}_l\in[-1,1]$ and $\frac{1-\tilde{\mu}_l}{2}\geq0$. Importantly, since for $k=0$ $b_l^{(0)}=0$ for all $l$, the set of equations~\eqref{eq:constraints1} do not contain $\lambda_0$. Moreover, the right-hand-side of the set of equations~\eqref{eq:constraints1}, for $l=0,1,\ldots,n-1$, contain all of the eigenvalues $\lambda_k$, $k=1\ldots,2^n-1$, with various multiplicities. Therefore, summing Eq.~\eqref{eq:constraints1} over $l$, we can write \begin{equation}\label{eq:constraints2} 0\leq\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}=\sum_{k=1}^{2^{n}-1}\lambda_{k}+\Lambda(\{\lambda_{k}\}), \end{equation} where $\Lambda(\{\lambda_{k}\})$ denotes the sum of all the terms not in $\sum_{k=1}^{2^{n}-1}\lambda_{k}$ (its structure is not important for the proof). Since $\forall k$ $\lambda_{k}\geq0$, $\Lambda(\{\lambda_{k}\})$ must be non-negative as well. Let us assume that $\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}\leq1$. Therefore, according to Eq.~\eqref{eq:constraints2}, the maximal value of the sum $\sum_{k=1}^{2^{n}-1}\lambda_{k}$ is obtained for $\Lambda(\{\lambda_{k}\})=0$, that is, $\sum_{k=1}^{2^{n}-1}\lambda_{k}=\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}$. In this case, the minimal value of $\lambda_0$ is \begin{equation}\label{eq:lambda0} \lambda_0=1-\sum_{k=1}^{2^n-1}\lambda_k=1-\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}\geq0. \end{equation} If, on the other hand, $\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}=1+\Delta$, for some $\Delta>0$, then from Eq.~\eqref{eq:constraints2}, it is clear that the maximal value of the sum $\sum_{k=1}^{2^{n}-1}\lambda_{k}$ is obtained when $\Lambda(\{\lambda_{k}\})=\Delta$, i.e., when $\sum_{k=1}^{2^{n}-1}\lambda_{k}=1$. In this case $\lambda_0=0$ and, thus, the worst-case fidelity with the target state is zero. \hfill \qedsymbol \medskip We note that the eigenvalue $\lambda_{2^l}$ appears only in the $l$-th equation of~\eqref{eq:constraints1}. Therefore, for the case where $\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}\leq 1$ a valid solution of Eq.~\eqref{eq:constraints2} is given by $\lambda_{2^l}=\frac{1-\tilde{\mu}_l}{2}\geq0$, and $\lambda_{k}=0$ for all other values $k\neq0$. This implies that, in this case, one density matrix that minimizes program~\eqref{prog:fid} is given by \begin{align}\label{eq:estimate4} \hat\rho&=\Bigl(1-\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}\Bigr)\ket{\Psi_0}\bra{\Psi_0}\nonumber\\&+\sum_{l=0}^{n-1}\Bigl(\frac{1-\tilde{\mu}_l}{2}\Bigr) \Bigl(\frac{\mathbb{1}-P_l}{2}\Bigr)\prod_{\substack{P_j\in \mathcal{G} \\ j\neq l}}\Bigl(\frac{\mathbb{1}+P_j}{2}\Bigr). \end{align} The state $\hat\rho$ is a good estimate for the state of the system when the fidelity is very close to 1, i.e., when $\tilde{\mu}_l=1-\varepsilon_l$ for small $\varepsilon_l$. Next, we provide a certification for the worst-case fidelity. Since this certification is of interest for large values of $F_\text{min}$, we will implicitly assume that $\sum_{l=0}^{n-1}\frac{1-\tilde{\mu}_l}{2}\leq1$. \medskip {\it Proposition 2:} Fix the parameters $\epsilon>0$ and $\delta>0$, and use $m_l=\lceil{\frac{n^2\ln(2/\delta)}{2\epsilon^2}}\rceil$ copies of the state of the system, $\varrho$, to measure the Pauli generator $P_l$, for $l=0,1,\ldots,n-1$. Then, with probability at least $1-\delta$, the fidelity $F_\text{min}$ lies in the range $[\bar{F}_\text{min}-\frac{\epsilon}{2},\bar{F}_\text{min}+\frac{\epsilon}{2}]$, where $\bar{F}_\text{min}$ is obtained by replacing $\tilde{\mu}_l$ with $\mu_l=\text{Tr}(\varrho P_l)$ in Eq.~\eqref{eq:fid_min}. \medskip {\it Proof:} Let $y_{j}^{(l)}\in\{-1,+1\}$ be the outcome of measuring the generator $P_l$ on $j$-th copy of $\varrho$. The empirical expectation value of $P_l$ is given by $\tilde{\mu}_l=\frac1{m_l}\sum_{j=1}^{m_l} y_{j}^{(l)}$. By Hoeffding's inequality applied to Bernoulli experiment, the probability that $\tilde{\mu}_l$ is $\epsilon$-close to its mean $\mu_l=\text{Tr}(\varrho P_l)$ is~\cite{shalev2014} \begin{equation}\label{eq:concen} P\left(\left\vert \tilde{\mu}_l-\mu_l\right\vert\leq\epsilon\right)\geq1-2e^{-2m_l\epsilon^2}. \end{equation} Therefore, taking $m_l=\lceil{\frac{\ln(2/\delta)}{2\epsilon^2}}\rceil$ $\forall l$, with probability at least $1-\delta$, the data $\tilde{\mu}_l$ lies in the range $[\mu_l-\epsilon, \mu_l+\epsilon]$. Thus, with probability at least $1-\delta$, we have \begin{align}\label{eq:fid_min2} \bar{F}_\text{min}-\tfrac{n\epsilon}{2} &= 1-\sum_{l=0}^{n-1}\tfrac{1-\mu_l+\epsilon}{2}\leq F_\text{min} \nonumber \\ &\leq 1-\sum_{l=0}^{n-1}\tfrac{1-\mu_l-\epsilon}{2} =\bar{F}_\text{min} + \tfrac{n\epsilon}{2}. \end{align} Taking $\epsilon\rightarrow \epsilon/n$ completes the proof. \hfill \qedsymbol \medskip Following Proposition~1 and Proposition~2 we obtain the following corollary: \medskip {\it Corollary 3:} Let $\varrho$ be the state of the system, and let $m_l=\lceil{\frac{n^2\ln(2/\delta)}{2\epsilon^2}}\rceil$ $\forall l$. Then, with probability at least $1-\delta$, the fidelity between $\varrho$ and the target stabilizer state $\ket{\Psi_0}$ is larger than $F_\text{min}-\frac{\epsilon}{2}$. \medskip {\it Proof:} $\bar{F}_\text{min}$ is the solution for program~\eqref{prog:fid}, i.e., the minimum fidelity with $\ket{\Psi_0}$, when we have access to the noiseless data $\mu_l=\text{Tr}(\varrho P_l)$. Therefore, the fidelity of the state of the system $\varrho$ and $\ket{\Psi_0}$ is necessarily larger than (or equals to) $\bar{F}_\text{min}$. On the other hand, from the right-hand-side of inequality~\eqref{eq:fid_min2}, with probability $1-\delta$ we can bound $\bar{F}_\text{min}$ from below by $F_\text{min}-n\frac{\epsilon}{2}$. Taking $\epsilon\rightarrow \epsilon/n$ completes the proof. \hfill \qedsymbol \medskip We note that since in the proposed procedure we should measure $n$ stabilizer generators, the total sample complexity of our certification protocol is $\lceil{\frac{n^3\ln(2/\delta)}{2\epsilon^2}}\rceil$. For comparison, Gottesman~\cite{Gottesman2008Identifying} and Montanaro~\cite{Montanaro2017Learning} have showed that stabilizer states can be identified using only ${\cal O}(n)$ copies of the state. However, these methods require entangled measurements, while the method proposed in this work uses single-qubit gates. Moreover, the direct fidelity estimation scheme of~\cite{Flammia2011Direct} and~\cite{daSilva2011Practical} requires ${\cal O}\left(\text{poly}\left( \epsilon^{-1}, \ln(1/\delta)\right)\right)$ copies of the states in total for certification, independent of $n$. But, as was discussed above, their scheme is favorable for very large systems, while our scheme is applicable for moderate-size systems. Hoeffding's inequality, used above, does not take into account the information about the variance of the outcome's distribution. Including this information, e.g., by using Bernstein's inequality, can further improve the sample complexity of our scheme. Bernstein's inequality states that given independent random variable $a_1,a_2,\ldots,a_m$ with mean $\mu$ and variance $\sigma^2$, the probability that $\tilde\mu=\frac1{m}\sum_j a_j$ is $\epsilon$-close to $\mu$ is: \begin{equation}\label{eq:concen2} P\left(\left\vert \tilde{\mu}-\mu\right\vert<\epsilon\right)>1-2e^{-\frac{m\epsilon^2}{2(\sigma^2+\epsilon/3)}}. \end{equation} When $\sigma^2\lesssim \epsilon$, we obtain a tighter lower bound than of Eq.~\eqref{eq:concen} which behaves like $1-2e^{-m\epsilon}$ instead of the $1-2e^{-m\epsilon^2}$, i.e., in this case, the number of samples (per observable), $m$, scale as $\frac{n\ln(2/\delta)}{\epsilon}$ rather than $\frac{n^2\ln(2/\delta)}{\epsilon^2}$. This can be useful for our purpose when the state of the system is close to the target stabilizer state, since then we expect the measurement outcomes of the $n$ Pauli observables to be narrowly distributed. (The measurement outcomes for the target stabilizer state have zero variance.) However, in our case, since the actual state of the system $\varrho$ is unknown, the variance of the distribution of each measured observable $(1-\text{Tr}(\varrho P_l)^2)^2$ is unknown, and in practice, we cannot use the Bernstein's inequality as stated above. Therefore, instead, we will use an empirical Bernstein's bound developed by~\cite{Dagum2000Optimal,Mnih2008Empirical}, which uses a variance calculated from the data, $\tilde{\sigma}^2$, instead of $\sigma^2$. The main idea of the empirical Bernstein's bound of~\cite{Dagum2000Optimal,Mnih2008Empirical} is to use an online algorithm, called \emph{EBStop}, which decides when to stop taking data, so that the $\tilde{\sigma}^2$ is, with high probability, an upper bound for $\sigma^2$. The algorithm should be executed, in our case, for each one of the $n$ measured generators. We refer the reader to~\cite{Mnih2008Empirical} for details about the algorithm. It was proven~\cite{Mnih2008Empirical,Mnih2008Efficient} that it takes $m={\cal O}(\epsilon^{-1}\ln\frac{1}{\delta})$ samples for the above algorithm to stop and to assure the desire convergence of $\tilde{\mu}$, with probability at least $1-\delta$. Therefore, by taking $\epsilon\rightarrow\epsilon/n$ we find the following result: \medskip {\it Corollary 4:} Let $\varrho$ be the state of the system, and let $m_l={\cal O}(\frac{n\ln(1/\delta)}{\epsilon})$ $\forall l=0,1,\ldots,n-1$. Then, with probability at least $1-\delta$, the fidelity between $\varrho$ and the target stabilizer state $\ket{\Psi_0}$ is larger than $F_\text{min}-\frac{\epsilon}{2}$.\\ \section{Experiments}\label{sec:exp} We apply the scheme described above to certify the preparation of a three-qubit GHZ state, $\ket{\textrm{GHZ}_3}=\frac1{\sqrt 2}(\ket{0}^{\otimes 3}+\ket{1}^{\otimes 3})$, on two different experimental platforms. The first platform is a 5-qubit quantum computing system based on trapped Ytterbium ions with individual laser beam addressing~\cite{Debnath16}. There, the state preparation consists of two native entangling XX-gates on qubits 1-2 and 2-3, followed by Hadamard gates on all three as shown in Fig.~\ref{fig:ioncircuit}. The XX-gate is experimentally realized using the M\o{}lmer-S\o{}rensen scheme~\cite{Molmer99, Solano99, Milburn00} combined with laser-pulse shaping to control the motional modes in a multi-ion chain~\cite{Choi14}. The gate operation is given in Eq.~\ref{eqn:XXGateChi}. The parameter $\chi$ can be varied continuously, $0<\chi \leq \frac{\pi}{4}$ and is set to $\frac{\pi}{4}$ in this case for a maximally-entangling gates. Single qubit gates, which are needed to create the Hadamard operations, are generated by driving resonant Rabi rotations of defined phase, amplitude, and duration. $Z$-rotations form an exception as they are applied as phase advances on the classical controllers. \begin{equation} \label{eqn:XXGateChi} XX(\chi)=\begin{pmatrix} \cos(\chi) & 0 & 0 & \hspace{-2mm}-i \sin(\chi)\\[0.3em] 0 & \hspace{-1mm}\cos(\chi) & \hspace{-3mm}-i \sin(\chi) & 0\\[0.3em] 0 & \hspace{-3mm}-i \sin(\chi) & \hspace{-1mm}\cos(\chi) & 0\\[0.3em] -i \sin(\chi) & 0 & 0 & \cos(\chi) \end{pmatrix} \end{equation} \begin{figure}[!t] \hspace{1em}\Qcircuit @C=0.7em @R=0.2em @!R { |0\rangle & & & \multigate{1}{XX(\frac{\pi}{4})} & \qw & \qw & \qw & \gate{H} & \qw \\ |0\rangle & & & \ghost{XX(\frac{\pi}{4})} &\gate{Z_{\pi/2}} & \multigate{1}{XX(\frac{\pi}{4})} &\qw & \gate{H} & \qw \\ |0\rangle & & & \qw &\qw & \ghost{XX(\frac{\pi}{4})} & \gate{Z_{\pi/2}} & \gate{H} & \qw } \caption{Circuit used to generate the 3-qubit GHZ state in the trapped ion system. The XX-gate action is given in Eq.~\ref{eqn:XXGateChi}.} \label{fig:ioncircuit} \end{figure} \begin{figure}[!t] \hspace{1em}\Qcircuit @C=0.7em @R=0.2em @!R { |0\rangle & & &\qw &\qw &\targ&\qw \\ |0\rangle & & &\qw & \targ &\qw &\qw \\ |0\rangle & & & \gate{H}& \ctrl{-1}&\ctrl{-2}&\qw } \caption{Circuit used to generate the 3-qubit GHZ state on IBM's superconducting quantum computation platform.} \label{fig:ibmcircuit} \end{figure} The experimental data consists of $11000$ samples from the distribution associated with measuring each qubit in the $Z$ basis (the computational basis), and $11000$ samples from the distribution associated with measuring each qubit in the $X$ basis (the Hadamard basis). The latter is achieved by applying another round of Hadamard gates before a measurement in the computational basis. The data is corrected for readout errors which are characterized independently by measuring the state-to-state transfer matrix in a series of reference experiments~\cite{Debnath16}. For comparison, we apply the validation scheme described above to validate a three-qubit GHZ state prepared on a IBM's superconducting quantum computation platform. We used the 5-qubit Tenerife processor~\cite{IBMQ}. The three qubits, labelled 0,1, and 2, were prepared in a GHZ state by applying the Hadamard transformation to qubit 2, followed by CNOT operations between qubits 2 and 1 and between qubits 2 and 0, see Fig.~\ref{fig:ibmcircuit}. Here as well, the experimental data consists of $8192$ samples from the distribution associated with measuring each qubit in the $Z$ basis, and $8192$ samples from the distribution associated with measuring each qubit in the $X$ basis. The latter is obtained by applying the Hadamard transformation to each qubit followed by a measurement in the computational basis. \begin{figure}[!t] \centering \includegraphics[width=0.9\columnwidth]{ion.pdf} \caption{{\bf Experimental results for trapped-ion platform.}}\label{fig:ion} \end{figure} \begin{figure}[!t] \centering \includegraphics[width=1\columnwidth]{ibm.pdf} \caption{{\bf Experimental results for IBM Q Tenerife processor.} }\label{fig:ibm} \end{figure} In Figs.~\ref{fig:ion} and~\ref{fig:ibm} we show the results of the two experiments in terms of the occurrence frequencies of the computational basis states. Based on these results, using Corollary~4, we calculate for the two experiments the lower bound on fidelity between the prepared state and the three-qubit GHZ state, $\ket{\textrm{GHZ}_3}$, for various certificate values. These are given in Table~\ref{tbl:results}. For the ion-trap (IBM) experiment we obtain these quantities by calculating the expected values of the three generators $Z_1\otimes Z_2$, $Z_2\otimes Z_3$ ($Z_1\otimes Z_3$), and $X^{\otimes3}$. For the observed data, these choice of generators maximize the lower-bound on the fidelity. \begin{table}[h] \begin{tabular}{ c| c| c |} \cline{2-3} & \multicolumn{2}{ c| }{Fidelity lower bound} \\ \cline{1-3} \multicolumn{1}{ |c| }{$p_\text{conf}$} & Ion-trap & IBM \\ \cline{1-3} \multicolumn{1}{ |c| }{0.999} & 0.905 & 0.575 \\\cline{1-3} \multicolumn{1}{ |c| }{0.99} &0.913 & 0.585 \\ \cline{1-3} \multicolumn{1}{ |c| }{0.9} & 0.923 & 0.596 \\ \cline{1-3} \end{tabular} \caption{Based on the result shown in Figs.~\ref{fig:ion} and~\ref{fig:ibm}, we conclude that in these two experiments, with probability larger than $p_\text{conf}$, the state of the system has fidelity higher than the tabulated value with the three-qubit GHZ state.} \label{tbl:results} \end{table} \section{Related work and discussion}\label{sec:disc} The results in Table \ref{tbl:results} yield a clear difference between the lower fidelity bounds of the two quantum devices investigated. Other comparisons between these platforms have shown only small differences in performance for applications where the limited connectivity of the superconducting system did not have an impact \cite{LinkePNAS2017}. Consistent with these previous findings, the measurement outcomes on both systems represent the target distributions reasonably well, as the average probability for measuring one of the desired states is only about $15\%$ lower on the IBM machine, see Figs.~\ref{fig:ion} and~\ref{fig:ibm}. What our analysis illustrates is that the certified lower-bound fidelity metric punishes these small differences as they disproportionately increase the overlap of the measurement outcomes with other potential distributions consistent with non-GHZ states, and hence resulting in much lower fidelity bounds on the IBM results. Measuring Pauli observables outside a specific set of generators, may help to narrow down the set of non-GHZ states that are consistent with the measurement data, and can increase the lower bound on the fidelity. The protocol we presented does not deal with measurement errors, and assumes that we are able to measure exactly the desired set of generators. In a real experimental setup, there could be a bias (either random or systematic) in the measured observables, which can decrease the lower bound on the fidelity. For example, consider a systematic bias in the measurement of a single qubit, where instead of measuring the projection onto $\{\ket{0}\bra{0},\ket{1}\bra{1}\}$, we are, in practice, measuring the POVM $ \{(1-\eta) \ket{0}\bra{0}+\eta\ket{1}\bra{1}, (1-\eta) \ket{1}\bra{1}+\eta\ket{0}\bra{0}\}$ (in the $x$, $y$, and $z$ directions), for small $\eta$. Then the lower bound on the fidelity decreases by $\mathcal{O}(n^2\eta)$ when the state of the system is close to the stabilizer state. It is, therefore, important to devise state-preparation validation schemes that are robust to measurement errors. We leave that for future work. Finally, we wish to mention the recent work by Rocchetto~\cite{Rocchetto2017Stabiliser}, who showed that stabilizer states are efficiently probably approximately correct (PAC)-learnable. Based on the results of Aaronson~\cite{Aaronson2007learnability}, Rocchetto showed that stabilizer states can be learned, in the computational learning theory sense, with only $\mathcal{O}(n)$ copies of the state, and proposed a learning procedure which involves an optimization problem that can be solved on classical computer in polynomial time. The PAC-learnability of stabilizer (GHZ) states was also demonstrated experimentally in~\cite{Rocchetto2017Experimental}. The goal in the PAC-learning methodology is to provide a model for the state that produces (with high probability) good predictions of future experimental results. Nevertheless, even in the case of small experimental noise, in general, the learned state may have poor fidelity with the actual state of the system (which is assumed to be closed to the target state). This is in contrast to the validation method presented here which guarantees that the estimated state has high fidelity with the state of the system in the case of small experimental noise. In fact, in the aforementioned experiment of~\cite{Rocchetto2017Experimental}, the learned state of the system was shown to have a good fidelity with the target GHZ state. The high fidelity with the target state in~\cite{Rocchetto2017Experimental} can be understood from the point of view of the validation scheme presented here. Specifically, the measurement distribution in~\cite{Rocchetto2017Experimental} was chosen to be uniform over the stabilizer group of the GHZ state, and therefore dependent on the target state. The authors reported that measuring roughly $1.2n$ stabilizer Pauli observables allowed them to obtain a high fidelity estimation of the target state by solving a convex program. Indeed, measuring slightly more than $n$ stabilizers assures that, with high probability, $n$ of them are independent, hence, form a generator group. This, as was discussed above, allows a good reconstruction of the stabilizer state. \section*{Acknowledgements} AK would like to thank Yi-Kai Liu for stimulating discussions and acknowledges the support from the US Department of Defense. \bibliographystyle{apsrev}
\section{Introduction} The random walk is a very simple model for diffusive processes with Brownian motion~\cite{Einstein1906theorie} as the prime example. Though its applications range from financial models~\cite{Fama1965Random} over online search engines~\cite{page1999PageRank} to the very sampling algorithm used in this study~\cite{newman1999monte}. Its simplest variation lives on a lattice and takes steps on random adjacent sites at each timestep, which is exceptionally well researched~\cite{hughes1996random}. With the further constraint that no site may be visited twice, such that the walk is \emph{self-avoiding}, it becomes a simple model for polymers~\cite{Madras2013}. Interestingly, depending on the exact protocol how the self-avoidance is achieved, they can also be used to study the perimeter of, e.g., critical percolation clusters~\cite{weinrib1985kinetic} or spanning trees~\cite{manna1992spanning,Majumdar1992Exact} The distance of a random walk from its starting point is the most prominent and simple measurable quantity. Nevertheless, here we go beyond this by considering the convex hull of all $T$ sites visited by the random walk, i.e., the smallest convex polygon containing all these sites. It can be seen as a measure of the general shape of the random walk, without exposing all details of the walk. Thus, the area $A$ or perimeter $L$ of the convex hull can then be used to characterize the random walk in a very simple way. This method is also used, for example, to describe the home ranges of animals~\cite{mohr1947,worton1987,boyle2009}, spread of animal epidemics~\cite{Dumonteil2013spatial} or classification of different phases using the trajectory of intermittent stochastic processes~\cite{grebenkov2017unraveling}. For standard random walks its mean perimeter~\cite{Letac1980Expected} and mean area~\cite{Letac1993explicit} in the large $T$ limit are known exactly since a long time. More recently different approaches generalized these results to multiple random walks~\cite{Majumdar2009Convex,Majumdar2010Random} and arbitrary dimensions~\cite{Eldan2014Volumetric}. Even more recently the mean perimeter and area for finite (but large) walk lengths $T$ were computed explicitly~\cite{grebenkov2017mean} if the random walk is discrete-time with jumps from an arbitrary distribution. If the distribution of the jump length is Gaussian, even an exact combinatorial formula for the mean volume in arbitrary dimensions is known~\cite{kabluchko2016intrinsic}. For higher moments however, there is only one analytic result for the special case of Brownian bridges~\cite{Goldman1996}, i.e., closed walks with Gaussian jumps. When asking for more, i.e., for the full distributions, no exact analytical results are available. This motivated the numerical study of the full distributions---or at least large parts of the support---using large-deviation sampling techniques to sample even far into the tails of standard random walks~\cite{Claussen2015Convex} and multiple random walks~\cite{Dewenter2016Convex}, also in higher dimensions~\cite{schawe2017highdim}. These numerical studies are rather expensive, since they usually require Markov chain Monte Carlo simulations, allowing one to measure the distribution in regions where the probabilities are as small as $10^{-100}$. Since self-avoiding walks are considerably more difficult to treat analytically than standard random walks, there are no analytical results about the properties of their convex hulls yet. Therefore, the authors of this contribution very recently published a numerical study of the full distribution of perimeter and area of three different types of self-avoiding random walks~\cite{schawe2018avoiding}, notably the classical \emph{self-avoiding walk} (SAW) and the \emph{smart kinetic self-avoiding walk} (SKSAW). While the SAW is combinatorial in nature and describes the set of all self-avoiding configurations with equal probability, the SKSAW is a growth process, which assigns more weight to some configurations. In~\cite{schawe2018avoiding} we also give an estimate for the functional form of the rate function $\Phi$ describing the far right tail behavior of the distribution, i.e., $P(S) \approx \ee^{-T\Phi(S)}$. It was found to depend only on the dimension $d$ and the scaling exponent $\nu$. For two-dimensional random walks these scaling exponents are often known exactly through Schramm-Loewner evolution~\cite{cardy2005sle,lawler2002scaling,Lawler2011,Kennedy2015}. In this study we test this prediction for the \emph{``true'' self-avoiding walk} (TSAW), which has a free parameter $\beta$ governing how strictly self-avoiding the walk is. Introduced in~\cite{amit1983asymptotic} the TSAW was a counter model to the SAW, especially it should demonstrate that the behavior of the combinatorial SAW is very different from more natural growing random walks which avoid themselves. Indeed, in two dimensions, where the end-to-end distance $r$ of a $T$ step SAW scales as $r \propto T^\nu$ with $\nu=3/4$, the TSAW will scale as \begin{equation} r \propto T^\nu \left(\ln T\right)^\alpha \label{eq:end-end} \end{equation} with $\nu=1/2$~\cite{Pietronero1983critical} and a correction $\alpha$, which is not known rigorously, but estimated as $\alpha = 1/4$~\cite{Grassberger2017selftrapping}. Here we show, for large-enough values of $\beta$, that in contrast to previous work \cite{schawe2018avoiding} the rate function $\Phi$ is not simply determined by the value of $\nu$, since the growth process of the TSAW in the large-area region of the tail is indistinguishable from the SKSAW growth process, although they have different values of the scaling exponent $\nu$ determined by the behavior of the high-probability part of their distributions. \section{Models and Methods\label{sec:mm}} This section will introduce the TSAW model and the sampling method in enough detail to reproduce the results of this study. For more fundamental methods, like the construction of the convex hull, we will sketch the main ideas. \subsection{Large Deviation Sampling Scheme\label{sec:metropolis}} To obtain good statistic in the far tail, it is not sufficient to perform naive simple sampling, since configurations of probability $P$ would need about $1/P$ samples to occur at all. It is therefore not feasible to explore the distributions down to the tails of $P < 10^{-100}$ with simple sampling. Instead we use an importance sampling scheme to generate more samples in the low probability tails. Thus, we generate Markov chains consisting of sequences of TSAWs and use the well known Metropolis algorithm~\cite{metropolis1953equation} with a Boltzmann sampling weight. For this purpose, we identify the quantity $S$ we are interested in---here the area $A$ but it could be any measurable quantity in principle---with the energy occurring in the Boltzmann factor and introduce an artificial ``temperature'' $\Theta$. Since the TSAW is a growth process, it is not trivial to come up with a local change move within the Markov chain, i.e., it is difficult to change a configuration by a small amount while preserving the correct statistics. Therefore our Markov chain is not directly a chain of configurations of TSAW but rather a chain of random number vectors $\vec\xi_i$. Each vector $\vec\xi_i$ determines a configuration of a TSAW by performing the growth process and using for each of the $T$ decisions a random number from $\vec\xi_i$. This approach is sketched in Fig.~\ref{fig:blackBox} and extremely general since it can be applied to any model~\cite{Hartmann2014high}. A change move is a simple change of one entry of $\vec\xi_i$. \begin{figure}[bhtp] \centering \includegraphics[scale=1]{blackBox} \caption{\label{fig:blackBox} Sketch of the Markov chain of random number vectors $\vec\xi_i$. The change move is performed on the $\vec\xi_i$ and a new TSAW is generated from scratch, its energy difference to the previous configuration is used to accept or reject the change. } \end{figure} Following the Metropolis algorithm, we propose a new $\vec\xi^\prime$ by replacing a random entry with a new random number $\xi \in U[0,1)$, generate a new TSAW configuration from scratch using the random numbers $\vec\xi^\prime$ and calculating its energy $S^\prime$, i.e., its area. The proposed configuration is then accepted, i.e., $\vec\xi_{i+1} = \vec\xi^\prime$, or rejected, i.e., $\vec\xi_{i+1} = \vec\xi_i$, depending on the temperature and energy difference with respect to the previous configuration with probability $p_\mathrm{acc} = \ee^{-\Delta S / \Theta}$, where $\Delta S = S^\prime - S_i$ is the energy difference caused by the change. Replacing a random entry by a new entry is clearly ergodic, since any possible $\vec\xi_i$ can be generated this way. Since we use the classical Metropolis acceptance probability, detailed balance is also given. This Markov process will therefore yield configurations $\vec\xi$ according to their equilibrium distribution $Q_\Theta(\vec\xi) = \frac{1}{Z(\Theta)} Q(\vec\xi) \ee^{-S(\vec\xi)/\Theta},$ where $Q(\vec\xi)$ is the natural, unbiased distribution of configurations and $Z(\Theta)$ the corresponding partition function. For small temperatures this will lead to small energies, i.e., smaller than typical perimeters or areas. For large temperatures typical configurations will be generated and for negative temperatures larger than usual energies dominate. Since this Metropolis algorithm will generate instances following a Boltzmann distribution we can easily undo this bias, i.e., we can derive the actual distribution $P(S)$ from the biased, temperature dependent distributions $P_\Theta(S)$ as \begin{align} P_\Theta(S) &= \sum_{\{\vec\xi | S(\vec\xi) = S\}} Q_\Theta(\vec\xi)\\ &= \sum_{\{\vec\xi | S(\vec\xi) = S\}} \frac{\exp (-S/\Theta)}{Z(\Theta)} Q(\vec\xi)\\ \label{eq:correction} &= \frac{\exp (-S/\Theta)}{Z(\Theta)} P(S). \end{align} The unknown $Z(\Theta)$ can be numerically determined by enforcing the continuity of the distribution. Therefore we need to simulate the system at many different temperatures $\Theta$, such that all histograms $P_\Theta(S)$ overlap with adjacent temperatures. $Z(\Theta)$ can now be calculated in overlapping regions, which should coincide for continuity, i.e., \begin{align} \ee^{S/\Theta_i} Z(\Theta_i) P_{\Theta_i}(S) &= \ee^{S/\Theta_{i+1}} Z(\Theta_{i+1}) P_{\Theta_{i+1}}(S)\\ \Rightarrow \quad \frac{Z(\Theta_i)}{Z(\Theta_{i+1})} &= \exp\left( {S/\Theta_{i+1} - S/\Theta_i} \right) \frac{P_{\Theta_{i+1}}(S)}{P_{\Theta_i}(S)}. \end{align} This relation fixes all ratios of consecutive $Z(\Theta)$. The absolute value can be fixed by the normalization of the whole distribution. This method is applicable to a wide range of models, and already successfully applied to obtain, e.g., the distributions over a large range for the score of sequence alignments~\cite{Hartmann2002Sampling,Wolfsheimer2007local,Fieth2016score}, work distributions for non-equilibrium systems~\cite{Hartmann2014high}, properties of Erd\H{o}s R\'enyi random graphs~\cite{Engel2004,Hartmann2011large,hartmann2018distribution}, and in particular to obtain statistics of the convex hulls of a wide range of types of random walks~\cite{Claussen2015Convex,Dewenter2016Convex,schawe2018avoiding}. \subsection{``True'' Self-Avoiding Walk\label{sec:tsaw}} The ``true'' self-avoiding Walk (TSAW) is a random walk model, in which the walker tries to avoid itself, but self-avoidance is not strictly imposed. \begin{figure*}[bhtp] \centering \subfigure[\label{fig:tsaw:b0} $\beta = 0$]{ \includegraphics[scale=0.7]{TSAW_B0} } \subfigure[\label{fig:tsaw:b1} $\beta = 1$]{ \includegraphics[scale=0.7]{TSAW_B1} } \subfigure[\label{fig:tsaw:b100} $\beta = 100$]{ \includegraphics[scale=0.7]{TSAW_B100} } \caption{\label{fig:tsaw} Examples of typical TSAW realizations at different values of the avoidance parameter $\beta$ with their convex hulls. Each walk has $T=200$ steps. Larger values of $\beta$ lead to larger extended walks characterized by larger areas of their convex hulls. } \end{figure*} To construct a TSAW realization one grows a standard random walk on a lattice and records the number of visits $n_i$ to each site $i$. For each step the probability to step on a neighboring site $i$ is weighted with the number of times that site was already visited \begin{align} p_i = \frac{\exp\brac{-\beta n_i}}{\sum_{j\in \mathcal{N}} \exp\brac{-\beta n_j}}, \end{align} where the sum over all current neighbors $\mathcal{N}$ is for normalization. The free parameter $\beta$ governs the strength of the avoidance. Large values of $\beta$ lead to stronger avoidance, negative values of $\beta$ lead to attraction and $\beta=0$ is the special case of the standard random walk. For a selection of $\beta$ values typical examples are visualized in Fig.~\ref{fig:tsaw}. The TSAW is not to be confused with the classical self-avoiding walk (SAW), which describes the ensemble of all configurations which do not intersect themselves each weighted the same. In Fig.~\ref{fig:prob} two partial decision trees are displayed which visualize the fundamental differences in the weights of the configurations. Even in the $\beta\to\infty$ limit ($Z_1=3$, $Z_2=2$) the weights differ. In particular its upper critical dimension is $d=2$~\cite{amit1983asymptotic}, which means that the exponent $\nu$, which characterizes the scaling of the end-to-end distance $r \propto T^\nu$, is $\nu = 1/2$ with logarithmic corrections, i.e., $r \propto T^{\nu} \brac{\ln T}^\alpha$, where $\alpha = 1/4$~\cite{Grassberger2017selftrapping} is conjectured. \begin{figure*}[bhtp] \centering \subfigure[\label{fig:prob:SAW} SAW]{ \includegraphics[width=0.47\textwidth]{saw_prob} } \subfigure[\label{fig:prob:TSAW} TSAW]{ \includegraphics[width=0.47\textwidth]{tsaw_prob} } \caption{\label{fig:prob} Partial decision trees for SAW and TSAW of walks up to length $T=5$. On the right side of each tree the weight of the configuration is displayed. While the weights for the SAW are by definition uniform for every valid configuration, the TSAW not only allows self-intersection, but also has different weights depending on the history of the walk. Note that $Z_1=3+\exp(-\beta)$ and $Z_2=2+2\exp(-\beta)$. } \end{figure*} \subsection{Convex Hulls\label{sec:convex}} The convex hull of a set of points $\mathcal{P}$ in the plane is the smallest convex polygon enclosing every point $p \in \mathcal{P}$ and hence also every line between any pair of points. Some examples of convex hulls are visualized in Fig.~\ref{fig:tsaw}. The construction of a convex hull of a planar point set is a solved problem, in the sense that an optimal algorithm exists~\cite{Kirkpatrick1986ultimate,Chan1996Optimal} with result-dependent run time $\mathcal{O}(T\log h)$, where $T$ is the number of points $|\mathcal{P}|$ and $h$ is the number of vertices of the resulting convex hull. In practice, however, suboptimal but simpler and for point sets as small as in this study ($T \approx 10^6$) faster algorithms are used. Especially for planar point sets one can exploit the fact that a polygon can be defined by the order of its vertices, instead by a list of its facets. The Graham scan~\cite{Graham1972Efficient} algorithm is based on this fact. After shifting the coordinate origin into the center of the point set, it sorts the points according to their polar coordinate. Then starting at an arbitrary point all points are filtered out which are oriented clockwise with respect to the the previous and next (not-filtered out) points. Iterating this over a full revolution, leaves only the points which constitute the vertices of the convex hull. This algorithm is dominated by the time to sort the points, which can be done in $\mathcal{O}(T\log T)$. Here, we use Andrew's monotone chain algorithm~\cite{Andrew1979Another}, which is a variation of the Graham scan sorting the points lexicographically, which is slightly faster, instead of by polar angle. Note that this type of algorithm does not generalize to $3$ or higher dimensions. For those cases a different algorithm, like quickhull~\cite{Barber1996thequickhull} has to be used. Before applying the exact algorithm, we reduce the size of the point set with Akl's elimination heuristic~\cite{Akl1978Fast}, which removes all points inside, in our implementation, a octagon of extreme points. Of a few tested polygons the octagon showed the best performance in the instances we typically encounter in this study. To calculate the area $A$ of a convex polygon, where the coordinates are sorted counterclockwise, one can sum the areas of the trapezoids extending perpendicular to the $x$-axis \begin{align} A &= \frac{1}{2}\sum_{i=0}^{h-1} (y_i+y_{i+1}) (x_i - x_{i+1}). \end{align} The perimeter $L$ is the sum of the line segments of consecutive points of the hull \begin{align} L &= \sum_{i=0}^{h-1} \sqrt{(x_i - x_{i+1})^2 + (y_i+y_{i+1})^2}, \end{align} with $x_h \equiv x_0$ and $y_h \equiv y_0$. \section{Results} We simulated the TSAW at two values of $\beta$. The limit case of a TSAW, which only steps on itself, if it has no other choice, was simulated at $\beta=100$. Since the probability to step on already visited sites is exponential in $\beta$, this corresponds to the $\beta\to\infty$ case. Further, we simulated at $\beta=1$, to capture also the case, which does sometimes voluntarily step on itself. First, we will look at the behavior of the mean of the perimeter and area. Here, we used simple sampling for walk lengths in the range $T\in\{2^k | 10 \le k \le 23\}$. Each value is averaged over $10^6$ TSAWs. Naturally, the mean of geometric volumes scale with their intrinsic dimension $d_i$ and a typical length scale $r$, e.g., the end-to-end distance, as $r^{d_i}$. Using the scaling of $r$ from Eq.~\eqref{eq:end-end}, we expect the mean values of the perimeter $\avg{L}$ ($d_i=1$ in $d=2$) and the area $\avg{A}$ ($d_i=2$) to scale as \begin{align} S \propto T^{d_i\nu} \ln(T)^{d_i\alpha} \label{eq:scale_mean} \end{align} for large values of $T$. We can even calculate the asymptotic prefactors $\mu^\infty$ by extrapolating the scaled values for finite sizes $\mu_L=\avg{L} T^{-1/2} \ln(T)^{-\alpha}$ and $\mu_A=\avg{A} T^{-1} \ln(T)^{-2\alpha}$ to their asymptotic values $\mu_L^\infty$ and $\mu_A^\infty$. For the extrapolation, which is shown in Fig.~\ref{fig:means}, we use a simple power law with offset $\mu = \mu^\infty - a T^{-b}$, which were already used for this purpose in \cite{Claussen2015Convex,Dewenter2016Convex}. The asymptotic values are listed in table~\ref{tab:mean}. As expected the values for the TSAW are larger for larger $\beta$. To our knowledge, there are no analytical calculations for these asymptotic values to which we could compare to. The given error estimates are only statistical and do not include the systematic error introduced by the ad-hoc fit function. Nevertheless the convergence of the values is very well visible, confirming $\nu=1/2$ and $\alpha=1/4$ to be very good estimates. Direct fits of the form Eq.~\eqref{eq:scale_mean} yield values in good agreement with the expected exponents for the end-to-end distance $r$ at $\beta = 1$, but most other data sets lead to fits overestimating $\alpha$ and slightly underestimating $\nu$. A possible, at least partial, explanation for this is be that the relation $L(r)$ is not perfectly linear for the sizes we obtained data for. \begin{figure*}[bhtp] \centering \subfigure[\label{fig:means} Asymptotic mean values]{ \includegraphics[scale=1]{means} } \subfigure[\label{fig:compare} Comparison of different types of random walks]{ \includegraphics[scale=1]{compareTypes2D} } \caption{\label{fig:combined} \subref{fig:means} Extrapolation of the asymptotic mean values of the perimeter and area of the convex hull. \subref{fig:compare} Distribution of all scrutinized walk types with $T=1024$ steps. The inset shows the peak region. Note that the standard random walk (RW) and the $\beta=0$ TSAW coincide. Also the far right tail of the $\beta = 100$ TSAW and SKSAW coincide, but not the main region. The vertical line shows the maximum area constructable with $1024$ steps, which has an area $A_{\max}$ about $512^2/2\approx 1.3\times 10^5$. The distributions are thus not sampled over their whole support, but a large region. } \end{figure*} \begin{table}[htb] \centering \begin{tabular}{l c c} \toprule & $\mu_L^\infty$ & $\mu_A^\infty$ \\ \midrule TSAW $\beta = 0$ (exact) & $3.5449...$ & $0.7854...$ \\ TSAW $\beta = 1$ & $3.636(2)$ & $0.820(1)$ \\ TSAW $\beta = 100$ & $4.641(3)$ & $1.339(3)$ \\ \bottomrule \end{tabular} \caption{ Asymptotic mean values of the area and perimeter scaled by Eq.~\eqref{eq:scale_mean}. The values are obtained by the fit shown in Fig.~\ref{fig:means}. The given error estimates are only statistical and do not include the systematic error introduced by the ad-hoc fit function. The exact values are from \cite{Eldan2014Volumetric} and converted to a square lattice as described in \cite{schawe2018avoiding}. } \label{tab:mean} \end{table} We now focus on the main result, on the distribution $P(A)$ of the convex-hull area. These results were obtained using the large-deviation Markov-chain simulations. We had to perform simulations for different ``temperatures'' ranges for each system size and parameter $\beta$. For example $T=128$ at $\beta=1$ needed seven temperatures for the right tail $\theta \in [-40,-9]$ and three more for the left $\theta \in [7,40]$. For larger system sizes more temperatures are usually needed. For the $\beta=1$ case at $T=2048$ we used 32 temperatures $\theta \in [-3200,-105]$ to obtain the right tail. For the $\beta=100$ cases we could use similar values for the temperatures. Equilibration was ensured as described in \cite{schawe2018avoiding}. In Figure~\ref{fig:compare} we compare distributions of different random walk types with the result for the TSAW at different values of $\beta$. By using the large-deviation algorithm, we were able to obtain this distribution over hundreds of decades in probability, down to values as small as $P(A)\sim 10^{-800}$ for the largest value of $T$. Notice that while SKSAW and TSAW with high values of $\beta$ show the same behavior in the far tail, where the walks are so stretched out such that trapping does not play a role anymore. In the main region however, they are clearly distinct, as is expected due to their different scaling exponent $\nu$. Further, the parameter $\beta$ can apparently be used to interpolate the tail behavior between the standard random walk case and the SKSAW case. Since we have obtained large parts of the distribution, it would be interesting if the whole distribution scales the same as the mean values (cf.~Eq.~\eqref{eq:scale_mean}). For other types of walks, the distribution of perimeter and area could indeed be scaled \cite{Claussen2015Convex,Dewenter2016Convex,schawe2017highdim,schawe2018avoiding} across their full support only knowing $\nu$, as \begin{align} P(S) = T^{-d\nu} \widetilde{P}\brac{ST^{-d\nu}}. \label{eq:scaling} \end{align} For the TSAW, this collapse, when considering the logarithmic corrections as visualized in Fig.~\ref{fig:scaling}, exhibits an apparent drift towards a limiting shape. Nevertheless, severe finite size effects are visible, especially in the tails but also in the main region. Despite far larger system sizes $T$ considered, here the main region collapse is worse than for other kinds of self-avoiding walks as shown in \cite{schawe2018avoiding}. The stronger finite size effect may be caused by the fact that all walks start on an empty lattice. This means for our case that the first steps of the walk behave differently from the last steps of the walk, when many sites are occupied. Although for the limit of large system sizes $T$, the latter should determine the behavior. A possible improvement to simulate TSAWs is suggested in~\cite{Grassberger2017selftrapping}, which is to simulate a much longer walk with $t \gg T$ steps and look at the last $T$ steps. \begin{figure*}[bhtp] \centering \subfigure[\label{fig:scaling:beta1} $\beta = 1$]{ \includegraphics[scale=1]{scalingB1} } \subfigure[\label{fig:scaling:beta100} $\beta = 100$]{ \includegraphics[scale=1]{scalingB100} } \caption{\label{fig:scaling} Distributions of the area of the ``true'' self-avoiding random walk scaled according to Eq.~\eqref{eq:scaling} plus logarithmic corrections for different values of $\beta$ and lengths $T$. The insets show the main region for 14 values of $T \in \{2^k | 10 \le k \le 23\}$ obtained by simple sampling. } \end{figure*} The rate function $\Phi$ is defined if the distribution obeys the \emph{large deviation principle}. This means that the distribution, for large values of $T$, should decay exponentially in the length $T$ scaled by the rate function as \begin{align} P_T(s) \approx \ee^{-T\Phi(s)}. \label{eq:def_rate} \end{align} Usually the parameter $s$ is between $0$ and $1$. We achieve this by dividing our measured area by the maximum area, i.e., by measuring $s = \frac{A}{A_\mathrm{max}}$. In two dimensions the walk configuration with maximum area is L-shaped with arms of equal length (for odd $T$) and therefore $A_\mathrm{max} = \frac{1}{2}\left(\frac{T+1}{2}\right)^2 \approx \frac{T^2}{8}$. Similar to~\cite{schawe2018avoiding} we assume the rate function to be a power law \begin{align} \Phi(s) \propto s^{\kappa}, \label{eq:power-law} \end{align} which seems to agree reasonably well with our data, since the double logarithmic plot Fig.~\ref{fig:rate} shows that the rate function appears as a straight line in the intermediate tail. The far tail is dominated by finite-size effects caused by the lattice structure, which leads to a ``bending up'' of the rate function. For small values of $s$, in the high-probability region, the rate function does not have any relevance. Assuming that the rate function is a power law Eq.~\eqref{eq:power-law} and scaling of the form Eq.~\eqref{eq:scaling} is possible, with $d_i$ being the intrinsic dimension of the observable, e.g., $d_i=2$ for the area, we can derive a value for the power law exponent of the rate function $\kappa$. Using the definition of the rate function Eq.~\eqref{eq:def_rate} \begin{align} \ee^{-T\Phi(ST^{-d_i})} \approx T^{-d_i\nu} \widetilde{P}\brac{ST^{-d_i\nu}} \end{align} should hold in the right tail. The $T^{-d_i\nu}$ term can be ignored next to the exponential, also the logarithmic correction is subdominant and would not allow to add any insight. Apparently the right hand side is a function of $ST^{-d_i\nu}$, such that the left hand side also has to be a function of $ST^{-d_i\nu}$. This is the case for~\cite{schawe2018avoiding} \begin{align} \kappa = \frac{1}{d_i(1-\nu)}. \end{align} \begin{figure*}[bhtp] \centering \subfigure[\label{fig:rate:beta1}]{ \includegraphics[scale=1]{rate_function_B1} } \subfigure[\label{fig:rate:beta100}]{ \includegraphics[scale=1]{rate_function_B100} } \caption{\label{fig:rate} Rate function $\Phi$ for the area with fits to the assumed power-law form. The fit is performed over a range, where the finite-size influence of the lattice should be small, but the large $T$ behavior can be extrapolated. Finite-size effects seem more pronounced for larger values of $\beta$. } \end{figure*} To test whether the results for the rate function in case of the TSAW obeys this relation, we estimate the value of $\kappa$ from our data. Since we have data for various values of the walk length $T$, we first extrapolate our data point-wise to large $T$. For this purpose we fit a power law with offset, where the parameters depend on the value of $s$: \begin{align} \Phi(s,T) = a(s) T^{b(s)} + \Phi_\infty(s). \label{eq:extrapolate} \end{align} This results in the value of interest $\Phi(s)\equiv \Phi_\infty(s)$, the parameters $a(s)$ and $b(s)$ are only auxiliary quantities. We perform this extrapolation in a region which is far away from the finite-size effects of the far tail. In this range of medium values of $s$ the extrapolation according to Eq.~\eqref{eq:extrapolate} works robustly. Since the bins of the logarithmic histograms we use do not have the same borders for every system size $T$, we have a-priory not access to the same value of $s$ for different values of $T$. Thus, we use cubic splines to interpolate such that we obtain results for the same value of $s$ for all walk lengths. We found cubic splines to be sufficient since the bins are rather dense such that systematic errors introduced by the interpolation should be small. The final values $\Phi(s)$ obtained from the extrapolated values to the assumed form Eq.~\eqref{eq:power-law} are shown in Fig.~\ref{fig:rate} as symbols. Next, we fit power laws to this data. The values for $\kappa$ obtained are within errorbars consistent with $\kappa = 7/6$ which is the expected value for the SKSAW ($\nu = 4/7$) and incompatible with the expected value $\kappa = 1$ of $\nu = 1/2$ walks. This behavior is nevertheless plausible since in the tail (large-area) region, structures, which enable self trapping, i.e., loops, are rare since they do lead to smaller areas of the convex hull than straight regions. Therefore the influence of trappings should diminish in the large area tail, which is the main difference in the behavior of SKSAW and TSAW. Without trappings the TSAW in the $\beta \to \infty$ limit is functionally identical to the SKSAW. Apparently already $\beta=1$ is large enough to produce this behavior. Therefore it is natural that the large-area tail behaves the same as the SKSAW. On the other hand, to possibly see a range where the rate function behaves like a power law with $\kappa=1$ according to $\nu=1/2$, one would have to go to much larger system sizes, because one would have to obtain data to the right of the peak, but for very small values of $s=A/A_{\max} \ll 10^{-2}$, where trappings still do play a role. In particular the analysis might be hampered by the presence of the logarithmic correction to the mean end-to-end distance. This means that the TSAW is more complex in comparison to some other types of self-avoiding walks for which it was possible to predict the tail behavior from the same exponent $\nu$ which predicts the mean behavior. The other types of random walk were under scrutiny in~\cite{schawe2018avoiding}, namely the self-avoiding walk, the loop-erased random walk and the smart kinetic self-avoiding walk (SKSAW). Instead for TSAW in the large deviation region a different scaling exponent seems to hold, which is very close to the scaling exponent of the SKSAW. \section{Conclusions\label{sec:conclusion}} We studied the behavior of the distribution of the area of the convex hull of the ``true'' self-avoiding walk, especially in the large deviation regime of larger than typical areas. With a sophisticated large-deviation sampling algorithm, we obtained the distribution over a large part of its support down to probabilities smaller than $10^{-800}$ for a typical avoidance parameter of $\beta = 1$ and a large avoidance $\beta = 100$. The distributions seem to approach a limiting scaling form when rescaled by the behavior of the mean, but with much stronger finite-size effects as compared to other types of random walks, which were previously studied. Using this data we calculated the rate functions. The rate function seem also to behave qualitatively similar in comparison to other types of self-avoiding walks studied earlier~\cite{schawe2018avoiding} in that they seem to be well defined and well approximated by a power law. In contrast to other types of random walks, this power law can apparently not be derived from the scaling exponent of the mean values $\nu$. Instead it seems that a second exponent governs the scaling behavior of the tail for the TSAW, which is close to $4/7$, the scaling exponent of the smart kinetic self-avoiding walk. This is plausible since the large-area region should be dominated by configurations in which no trappings are possible, which is the major difference between these types. Finally, we also provided estimates for the relevant scale factors of the mean of area and perimeter of the convex hulls of TSAWs. They might be accessible to analytic calculations in the future. For future numerical work it would be interesting to look for further types of random walks, which show similar effects of distinct scaling exponents for different parts of the distribution but do not show the strong logarithmic corrections to scaling, and would therefore be easier to analyze. On the other hand, it would be very exciting if one was able to obtain data in the range where the rate function exhibits the exponent $\kappa(\nu=1/2)=1$, with the need to simulate really large system sizes, but closer to the typical behavior. \ack This work was supported by the German Science Foundation (DFG) through the grant HA 3169/8-1. We also thank the GWDG (G\"ottingen) for providing computational resources. \section*{References} \bibliographystyle{iopart-num}
\section*{Introduction} The well connected structure of the global air transportation network and the steadily increasing volume of international travel has a vast impact on the rapid, large-scale spread of arboviral and other diseases~\cite{Bloom2017,Brockmann2013,Dorigatti2017,Guimera2005,Huang2013,Hufnagel2004,Tatem2012}. A recent example of disease introduction to a novel region is the spread of the Zika virus from Brazil to Europe, the United States and other countries, which prompted the World Health Organisation (WHO) to announce a public health emergency of international concern in early 2016. Investigations confirmed that international viraemic travellers were a major contributing factor to the rapid spread~\cite{Bogoch2016}. With an estimated 50-100 million symptomatic infections each year~\cite{Bhatt2013,Stanaway2016}, dengue is ranked the most important mosquito-borne disease~\cite{Murray2013,WorldHealthOrganization2013}. The rapid geographic spread is, to a great extent, driven by the increase in international air travel~\cite{Gardner2013,Mackenzie2004}. In addition, dengue is severely under-reported, making it extremely challenging to monitor and prevent the spread of the disease. Presumably, 92\% of symptomatic infections are not reported to health authorities~\cite{Stanaway2016}. Low reporting rates can have many reasons, including low awareness levels and misdiagnosis~\cite{Bhatt2013,Simmons2012}. Due to the rapid global spread of dengue as well as severe under-reporting, many countries are facing the threat of ongoing local transmission in the near future~\cite{Murray2013}. In non-endemic countries, local outbreaks are usually triggered by an imported case~\cite{Chang2015}, a person who acquired the disease overseas and transmitted the virus to local mosquitoes. To prevent ongoing dengue transmission in non-endemic countries, it is critical to forecast the importation of disease cases into these areas and move from responsive containment of dengue outbreaks to proactive outbreak mitigation measures. The majority of existing models forecast relative rather than absolute risk of dengue importation and are unable to predict the total number of imported disease cases~\cite{Gardner2013,Semenza2014,Gardner2015}. The few models that can predict absolute numbers are region-specific rather than global~\cite{Wilder-Smith2014,Quam2015,Massad2018}. The most recently proposed model estimates the total number of imported dengue cases for 27 European countries~\cite{Massad2018}, however, the model has several limitations: (i)~Monthly incidence rates were based on dengue cases reported to the World Health Organisation (WHO) despite dengue being under-reported and the general consensus that the actual number of cases is much higher than the figures published by the WHO~\cite{Stanaway2016,Bhatt2013}; (ii)~Only 16 countries were considered as possible sources of importation. The authors reason that these 16 countries contribute 95\% of all global dengue cases, referring to numbers published by the WHO. Since African countries do not report to the WHO, and dengue remains an under-reported disease in many other countries~\cite{Standish2010,Kakkar2012,Vong2012,Wahyono2017}, it is likely that the percentage contribution to the number of global dengue cases by the 16 selected countries is strongly biased; (iii)~Seasonal distributions of dengue cases were inferred based on information from only two source countries (Latin American countries were assumed to have similar seasonalities to Brazil, while Thailand served as a proxy for countries in South-East Asia). The assertion that all countries within a given global region experience similar seasonal fluctuations in dengue infections is likely inaccurate. For example, dengue notifications peak between April and December in Thailand, while Indonesia reports the highest number of dengue cases from November to April~\cite{IAMAT}. The contribution of this paper is twofold. First, we develop a network model that overcomes the limitations of previous models by employing global air passenger volumes, country-specific dengue incidence rates and country-specific temporal infection patterns. We construct weighted directed networks, using data collected by the International Air Transportation Association (IATA) to capture the movement of air passengers. We calculate monthly, country-specific dengue incidence rates by combining data from the Global Health Data Exchange~\cite{GlobalHealthDataExchange2017}, the most comprehensive health database, and known seasonal patterns in reported dengue infections~\cite{IAMAT}. Further, we distinguish between two categories of travellers: returning residents and visitors. The number of days people from these two categories spend in an endemic country, and therefore the risk of being infectious on arrival, vary greatly. The model predicts the number of imported dengue cases per month for any given airport and can be applied with relative ease to other vector-borne diseases of global concern, such as malaria, Zika or chikungunya. Second, we apply the model to infer time-varying, region-specific reporting rates, defined as the ratio of reported to actual infections. Dengue reporting rates vary greatly across space and time, often by several orders of magnitude, and hence are difficult to determine~\cite{Stanaway2016}. The usual approach towards estimating country-specific reporting rates is to carry out cohort or capture-recapture studies that can be costly, are time consuming and may be biased~\cite{Toan2015}. Consequently, dengue reporting-rates remain unknown for most countries~\cite{Stanaway2016}. In this paper we focus on those countries that are most at risk of dengue introduction, i.e. non-endemic countries with vector presence. These countries will have the greatest benefit from our model as knowledge about the likely arrival times and places of infected people is crucial to prevent local outbreaks. \section*{Materials and methods} CSIRO's human research ethics committee CSSHREC has approved this study (approval number: Ethics Clearance 142/16). All data were analysed anonymously and individuals cannot be identified. \subsection*{IATA Data} The International Air Transportation Association (IATA) has approximately 280 airline members who together contribute to approximately 83\% of all air traffic. Data is collected in form of travel routes, detailing the origin, destination and stopover airports. It contains over 10,000 airports in 227 different countries and dependencies. For each route the total number of passengers per month is given. We do not have any information on stopover times and whether passengers are leaving the airport during their stopover and therefore assume that all passengers continue their journey to the final destination instantly. Table~\ref{tab:abbreviations} lists the IATA 3-Letter Codes used to abbreviate airports in the main manuscript. As the recorded itineraries do not include any travel on chartered flights, we compare the IATA passenger volumes to official airport passenger statistics~\cite{AirlineNetworkNewsandAnalysis2018,CivilAviationAdministrationofChina2016,MinistryofLandInfrastructureTransportandTourism,MinistryofTransportationRepublicofIndonesia2018,AirportsCouncilInternational2015,DirectorateGeneralofCivilAviation-Kuwait2015,EANA-NavegacionAereaArgentina2016,AngkasaPuraII2015,CivilAviationAuthorityofthePhilippines2015,InstitutodeEstadisticasdePuertoRico2015,MalaysiaAirports2015,Zambia:TransportDataPortal2016,CaliforniaDepartmentofTransportation2016,AirportsAuthoriyofIndia2016,AssociazioneItalianaGestoriAeroporti2016,OfficeNationaldesAeroports2017,AirportsCompanySouthAfrica2018,EgyptianHoldingCompanyforAirportsandAirNavigation2015,AirportsCouncilInternational2018} to quantify the potential discrepancies between actual travel patterns and that reported by IATA. Table~\ref{tab:excluded_countries} lists the countries where the difference in passenger numbers is greater than 15\% (at country level) and countries where airport statistics were not available and the tourist data suggests inaccuracies in the IATA data (i.e. the number of tourists arriving in a particular country is larger than the total number of passengers arriving). We also excluded Singapore as a source of importation for Australia for the following reason: The Department of Home Affairs publishes Arrival Card data~\cite{DepartmentofHomeAffairs2017} that can be used to validate the IATA data. A comparison of the monthly travel volume from Singapore to Australia revealed that the IATA data overestimates travel volumes by approximately 112\% on average in 2011 and 2015. This may be due to individuals who travel from other countries to Singapore and then directly continue to Australia and do not book their entire trip in one itinerary (this would be recorded as two separate trips in the IATA data that cannot be linked to each other). Due to this large discrepancy in the travel data we believe that our model will significantly overestimate the number of dengue infections imported from Singapore, and therefore exclude it as a source country for Australia. \subsection*{The air transportation network} We begin by constructing twelve weighted, directed networks, using IATA data, to represent the monthly movement of air passengers during a given year. The networks are denoted $\mathcal{G}_m=(V,E)$, with $m=1,\dots,12$ indicating the month of the year. The node set $V$ comprises more than 10,000 airports recorded by IATA. To distinguish the travellers by their country of embarkation, we represent the edges of the network as ordered triples, $(i,j,\omega_{i,j}(c,k))\in E$, where $i,j\in V$ and $\omega_{i,j}(c,k)$ is a function that outputs the number of passengers who initially embarked in country $c$ with final destination airport $k$ and travel from airport $i$ to airport $j$ as part of their journey. \subsection*{Incidence rates and seasonal distributions} Calculating the number of infected passengers requires daily infection probabilities. We derive these from country-level yearly estimates of symptomatic dengue incidence rates that are published together with their 95\% confidence intervals by the Global Health Data Exchange~\cite{GlobalHealthDataExchange2017}. The estimates are obtained using the model published in~\cite{Stanaway2016} and account for under-reporting. We first deduce monthly incidence rates using information on dengue seasonality published by the International Association for Medical Assistance to Travellers~\cite{IAMAT}. To do so we associate a weight with each month that indicates the intensity of transmission. To assign the weights we use a modified cosine function with altered period that matches the length of the peak-transmission season. The function is shifted and its amplitude adjusted so that its maximum occurs midway through the peak-season with value equal to the length of the peak-season divided by $2\pi$. The months outside the peak-season receive a weight of one if dengue transmission occurs year around and a weight of zero if dengue transmission ceases outside the peak-season. The weights are then normalised and multiplied by the yearly incidence rate for the corresponding country. Normalising the weights ensures that the sum of the monthly incidence rates is equal to the yearly incidence rate. To calculate the lower and upper bounds of the monthly incidence rates, we multiply the normalised weights by the lower and upper bounds of the 95\% confidence interval given for the yearly incidence rates. The average probability, $\beta_{c,m}$, of a person becoming infected on any given day during month $m$ in country $c$ is then given by \begin{equation}\label{eqn:ratetoprob} \beta_{c,m} = 1 - e^{-\gamma_{c,m}/d_m}, \end{equation} \noindent where $\gamma_{c,m}$ is the monthly dengue incidence rate in country $c$ during month $m$ and $d_m$ is number of days in month $m$. Note that Equation~\eqref{eqn:ratetoprob} converts the daily incidence rate into the probability of a single person becoming infected with dengue on any given day during month $m$. \subsection*{Inferring the number of infected passengers} Next, we present a mathematical model that approximates the number of dengue-infected people for each edge in the network $\mathcal{G}_m(V,E)$. The time between being bitten by an infectious mosquito and the onset of symptoms is called the intrinsic incubation period (IIP). This period closely aligns with the latent period, after which dengue can be transmitted to mosquitoes~\cite{Chan2012}. The IIP lasts between 3 and 14 days (on average 5.5 days) and was shown to follow a gamma distribution of shape 53.8 and scale equal to 0.1~\cite{Chowell2007}. After completion of the IIP a person is infectious for approximately 2 to 10 days (on average 5 days)~\cite{Gubler1995,Chowell2007}. The length of the infectious period was shown to follow a gamma distribution of shape 25 and scale equal to 0.2~\cite{Chowell2007}. We denote the sum of the IIP and the infectious period by $n$, which is rounded to the nearest integer after the summation. For travellers to import the infection from country $c$ into a new location $r$ they must have been infected with dengue within the last $n-1$ days of their stay in country $c$. We now consider the following two cases: $t_{c}\geq n-1$ and $t_{c} < n-1$, where $t_{c}$ is number of days spent in country $c$ before arriving in region $r$. Since we do not know the exact date of arrival for travellers, we assume that arrival and departure dates fall within the same month and hence $\beta_{c,m}$ is the same for every day during the travel period. If $t_{c} \geq n-1$, that is the individual spent more time in country $c$ than the sum of the lengths of the IIP and the infectious period, the probability of not being infected on return is equal to $(1-\beta_{c,m})^{t_{c}}+\left[1-(1-\beta_{c,m})^{t_{c}-(n-1)}\right]$. The first term covers the possibility that the individual did not get infected whilst staying in country $c$ and the second term covers the possibility that the individual got infected and recovered before arriving at a given airport (see Fig~\ref{fig:diagram}). Hence, the probability of a person, who arrives at a given airport from country $c$ during month $m$, being infected with dengue is given by \begin{eqnarray} p_{c,m} &=& 1-\left[(1-\beta_{c,m})^{t_{c}}+1-(1-\beta_{c,m})^{t_{c}-(n-1)}\right]\nonumber\\ &=& (1-\beta_{c,m})^{t_{c}-(n-1)}-(1-\beta_{c,m})^{t_{c}}. \end{eqnarray} If $t_{c} < n-1$, that is the individual spent less time in country $c$ than the sum of the lengths of the IIP and the infectious period, the probability of not being infected on return is equal to $(1-\beta_{c,m})^{t_{c}}$, which covers the possibility that the individual did not get infected whilst staying in country $c$. Since $t_{c} < n-1$, the probability of recovery before arriving at a given airport is zero. Hence, the probability of a person, who arrives from country $c$ at a given airport during month $m$, being infected with dengue is given by \begin{equation} p_{c,m} = 1-(1-\beta_{c,m})^{t_{c}}. \end{equation} We distinguish between two different types of travellers arriving at a given airport of region $r$: returning residents and visitors. We define a returning resident as a traveller who resides in region $r$ and a visitor as a traveller who resides in country $c$ and visits region $r$. Returning residents are expected to have stayed a couple of weeks in the endemic country, while visitors may have spent their whole life in the country. Since we lack information on how long each individual spent in country $c$ before arriving at an airport of region $r$, we substitute parameter $t_{c}$ by $\langle t\rangle_{c}^{res}$ if the person is a returning resident, $\langle t\rangle_{c}^{res}$ being the average number of days a returning resident spends in country $c$ before returning home. If the person is a visitor, parameter $t_{c}$ is substituted by $\langle t\rangle_{c}^{\textrm{vis}}$, the average number of days a visitor spends in country $c$ before arriving at an airport of region $r$. We distinguish between returning residents and visitors since $\langle t\rangle_{c}^{\textrm{res}}\ll \langle t\rangle_{c}^{\textrm{vis}}$. We assume that the length of stay for returning residents follows a normal distribution with mean equal to 15 days and standard deviation of 2, i.e. $\langle t\rangle_{c}^{res} \sim \mathcal{N}(15, 2)$. A previous study has shown that employees around the world are on average entitled to approximately 15 days of annual leave~\cite{Messenger2007}. On the other hand, visitors likely spent all their lives in the endemic country. We assume that $\langle t\rangle_{c}^{vis} \sim \mathcal{N}(\mu_{vis},0.1\mu_{vis})$, where $\mu_{vis}$ is equal to $c$'s median population age. Median population ages by country are published in the World Factbook by the Central Intelligence Agency~\cite{CentralIntelligenceAgency2017}. For simplicity we do not take immunity to the different dengue strains into consideration. \subsection*{Proportion of returning residents and visitors} Lastly, we need to infer the proportions of returning residents and visitors. As this information is not contained in the IATA itineraries, we use international tourism arrival data from the World Tourism Organisation~\cite{WorldTourismOrganisation2018}. The data contains the yearly number of international tourist arrivals by air for each destination country. From the IATA data we calculate the total number of arrivals per year for each country and hence can infer the ratio of visitors to returning residents. As we lack sufficient data, we assume that the ratio of visitors to residents is the same for each month. \subsection*{Calculating the absolute number of infected passengers} Given the above, we can now determine the number of infected passengers $I_{k,m}$ arriving at airport $k$ during month $m$ as follows: \begin{equation} I_{k,m} = \sum_{i,j,c}\omega_{i,j}(c,k)\left[qp_{c,m}^{res} + (1-q)p_{c,m}^{vis}\right], \end{equation} \noindent where $q$ is the proportion of residents inferred from the international tourism arrival data, \begin{strip} \begin{equation} p_{c,m}^{res}= \begin{cases} (1-\beta_{c,m})^{\langle t\rangle_{c}^{res}-(n-1)}-(1-\beta_{c,m})^{\langle t\rangle_{c}^{res}} & \langle t\rangle_{c}^{res}\geq n-1\\ &\\ 1-(1-\beta_{c,m})^{\langle t\rangle_{c}^{res}} & \langle t\rangle_{c}^{res}< n-1, \end{cases} \end{equation} \noindent and \begin{equation} p_{c,m}^{vis}= \begin{cases} (1-\beta_{c,m})^{\langle t\rangle_{c}^{vis}-(n-1)}-(1-\beta_{c,m})^{\langle t\rangle_{c}^{vis}} & \langle t\rangle_{c}^{vis}\geq n-1\\ &\\ 1-(1-\beta_{c,m})^{\langle t\rangle_{c}^{vis}} & \langle t\rangle_{c}^{vis}< n-1. \end{cases} \end{equation} \end{strip} \subsection*{Evaluation of the model’s uncertainty} We performed a thousand runs of the model for each edge in the network, drawing the parameters from their respective distributions, to calculate the mean and standard deviation of dengue-infected passengers. In addition, we have conducted a global sensitivity analysis to identify the model parameters with the greatest influence. We used Sobol's method~\cite{Sobol2001} with 100,000 samples to carry out the sensitivity analysis. The parameter ranges are shown in Table~\ref{tab:parameters}. The analysis was done with SALib~\cite{Herman2017}, an open-source Python library. \begin{table}[!ht] \centering \begin{tabular}{ll} \toprule Parameter & Range\\ \midrule $\beta_{c,m}$&[0.000001, 0.000445]\\ $t_c$ (days)&[1, 29200]\\ $n$ (days)&[5, 24]\\ \bottomrule \end{tabular} \caption{\bf The model parameter ranges used in Sobol's method.}\label{tab:parameters} \end{table} \begin{figure*}[!h] \centering \includegraphics[width=0.8\linewidth]{Fig1} \caption{{\bf Predicted dengue importations for August 2015.} \normalfont The map shows the output of our model for August 2015.The area of a node increases with the number of dengue cases imported through the corresponding airport. Airports that are predicted to not receive any infections are not shown on the map. Endemic countries are coloured dark grey. Countries that are non-endemic and where dengue vectors \emph{Aedes aegypti} and/or \emph{Aedes albopictus} are present are coloured in light grey. The blue circles correspond to the top ten airports identified in Fig~\ref{fig:top10}. The map was created with the Python GeoPandas package and publicly available shapefiles from Natural Earth (\url{http://www.naturalearthdata.com/}).}\label{fig:map} \end{figure*} \section*{Results} We run our model for two different years to explore the robustness of the proposed methodology. Specifically, the analysis is conducted for 2011 and 2015. The results for the year 2015 are presented in the main manuscript, while the results for 2011 are presented in the supplementary material. Fig~\ref{fig:map} shows the number of predicted imported dengue infections per airport for August 2015, where the area of a node increases with the number of dengue cases imported through the corresponding airport. The map clearly shows that many non-endemic regions where the dengue-transmitting vectors \emph{Aedes aegypti} or \emph{Aedes albopictus} are present (coloured in light grey) have airports that are predicted to receive a high number of dengue infections. For a list of dengue endemic and non-endemic countries see Table~\ref{tab:endemic_vector}. As resources for the control and prevention of dengue are often limited~\cite{Morrison2008}, these countries face a high risk of future endemicity. In Fig~\ref{fig:top10} and Fig~\ref{fig:Top10_2011} we plot the number of predicted dengue importations over time for the ten airports that receive the highest number of cases, lie in non-endemic regions with vector presence and where local cases have been reported in the past (more detailed plots with confidence intervals are shown in Fig`\ref{fig:Top10_CI}). While the majority of airports listed in Fig~\ref{fig:top10} and Fig~\ref{fig:Top10_2011} are predicted to receive between 50 and 150 cases each month, Miami International Airport (MIA) is estimated to receive between 146 and 309 cases each month during both years. With Orlando International Airport (MCO) and Fort Lauderdale–Hollywood International Airport (FLL) also represented amongst the airports with the highest number of imported cases, Florida faces a high risk of local dengue outbreaks. Los Angeles International Airport (LAX) is predicted to receive the second highest number of imported cases. In 2011 its monthly predictions vary between 97 and 205 cases and in 2015 between 113 and 253 cases. The remaining airports listed in Fig~\ref{fig:top10} and Fig~\ref{fig:Top10_2011} are located in France, Germany, the Netherlands, Texas, and Queensland, Australia. A full ranking of all airports located in non-endemic countries with vector presence can be found in Table~\ref{tab:annual_imported} of the supplementary material. \begin{figure}[!h] \centering \includegraphics[width=0.9\linewidth]{Fig2} \caption{{\bf Predicted monthly dengue importations by airport for 2015.} \normalfont The number of predicted imported dengue infections for the top ten airports in non-endemic countries/states with vector presence for each month in 2015. A break in a line indicates that the corresponding airport was not amongst the top ten during the respective month. Airports are abbreviated using the corresponding IATA code. A full list of abbreviations can be found in the supplementary material (see Table~\ref{tab:abbreviations}).} \label{fig:top10} \end{figure} \begin{figure*}[!h] \centering \includegraphics[width=0.9\linewidth]{Fig3} \caption{{\bf Predicted dengue infections imported by returning residents and visitors in 2015.} \normalfont Here we show the results for non-endemic countries/states with vector presence with the highest number of predicted imported dengue cases in 2015. The bars are stacked to distinguish between returning residents (green) and visitors (blue). The blue solid line corresponds to the total number of imported cases. The error bars correspond to the model's coefficient of variation (see Material and methods). The six countries were selected because they are predicted to receive the highest number of dengue importations, are non-endemic and dengue vectors are established.} \label{fig:visRes} \end{figure*} In addition to calculating the number of imported dengue infections per airport, the model further provides the number of infected passengers travelling between any two airports, thus revealing common importation routes. Table~\ref{tab:routes} and Table~\ref{tab:routes2011} list the routes that carry the highest number of infected passengers whose final destinations lie in non-endemic countries with vector presence. Table~\ref{tab:routesS} lists the routes that carry the highest number of infected passengers whose final destinations lie in non-endemic countries irrespective of whether vectors are present. For example, the route between Denpasar and Perth is ranked third in 2011 in Table~\ref{tab:routesS}, but it is not considered in the ranking shown in Table~\ref{tab:routes2011}, as there are no vectors in Perth. Fig~\ref{fig:importation_routes_Aug_2015} shows a map of all importation routes into non-endemic countries with vector presence. \begin{table}[!ht] \centering \begin{tabular}{llll} \toprule Orig. & Dest. & Pax & Month\\ \midrule SJU (Puerto Rico)& MCO (Florida) & 51 & Jul\\ PTP (Guadeloupe) & ORY (France) & 37 & Aug \\ FDF (Martinique)& ORY (France)& 34 & Aug\\ SJU (Puerto Rico)& FLL (Florida) & 32 & Jul\\ TPE (Taiwan)& LAX (California) &31 &Aug\\ GRU (Brazil)& MIA (Florida) & 29 & Apr\\ DEL (India)& KBL (Afghanistan) & 27 & Aug\\ GDL (Mexico)& LAX (California)& 24 & Aug\\ CUN (Mexico)& MIA (Florida) & 24 & Aug\\ CUN (Mexico)& LAX (California)& 22 & Aug\\ \bottomrule \end{tabular} \caption{{\bf The ten routes with the highest predicted number of dengue-infected passengers with final destinations in non-endemic countries with vector presence.} The table lists the direct routes with the highest predicted volume of dengue-infected passengers who continue to travel to non-endemic regions with vector presence and where local outbreaks have been reported in the past. The last column records the month during which the highest number of infected passengers are predicted.}\label{tab:routes} \end{table} In both years the highest predicted number of infected passengers are recorded during the northern hemisphere's summer. The route between S\~{a}o Paulo International Airport (GRU) and Miami International Airport (MIA) is the exception, where the highest number of infected passengers is predicted during April. The routes with the highest estimated number of dengue-infected passengers terminate at airports in countries that are non-endemic and where dengue-transmitting vectors are present. \subsection*{Returning residents and visitors} Next, we aggregate airports by country/state to predict the number of imported dengue infections on a coarser level. For non-endemic countries that cover an area larger than 5,000,000 km$^2$ and where dengue vectors are present we aggregate airports by state. These countries are Russia, the United States of America and Australia. The comparison between passenger volumes recorded by IATA and official airport statistics indicated that the IATA data for Russia may be inaccurate, i.e. the difference in passenger numbers is larger than 15\% (see Material and Methods). Hence, we did not perform a state-level analysis for this country. In Australia vectors are present only in Queensland~\cite{Beebe2009}. While vectors have been observed in more than 40 different US states, autochthonous cases have been reported only in California, Florida, Hawaii and Texas~\cite{Hahn2016}. \begin{figure*}[!h] \centering \includegraphics[width=0.9\linewidth]{Fig4} \caption{{\bf Predicted percentage contribution of dengue importations by country of acquisition in 2015.} The predicted percentage contribution by source country and month in 2015. The size and colour of the circles indicate the percentage contribution of the corresponding country to the total number of imported cases. The $y$-labels indicate the yearly percentage contribution of the corresponding source country.} \label{fig:acquisition} \end{figure*} Our model separately calculates the number of dengue-infected people amongst returning residents and visitors and hence we can identify which of these groups is more likely to import the disease into a given country or state. Fig~\ref{fig:visRes} and Fig~\ref{fig:visitorsResidents2011} show the results for six non-endemic countries/states with vector presence that are predicted to receive the highest number of dengue importations each month. Results for the remaining countries and states are shown in Figs~\ref{fig:US2011} -~\ref{fig:Africa}. We observe that the contributions of returning residents and visitors to the total number of imported dengue infections is predicted to vary greatly between the different countries and states. In Florida and Queensland returning residents are predicted to be the main source of dengue importation. In France and Italy approximately one third of all dengue infections are predicted to be imported by visitors while in Spain visitors import around 75\% of all imported cases. For Switzerland we do not have any information about the ratio of returning residents to visitors. For the United States there is evidence in the form of surveillance reports that returning residents are indeed the main contributors to dengue importations~\cite{VanDodewaard2015}. For Queensland we predict that 95\% and 94\% of infections were imported by returning residents in 2011 and 2015, respectively. Our predictions are supported by Queensland's dengue notification data (provided by Queensland Health), showing that 97\% and 92\% of all dengue importations in 2011 and 2015, respectively, were imported by returning residents. \subsection*{Countries of acquisition} In addition to being able to distinguish between returning residents and visitors, the model also divides the imported cases according to their places of acquisition. Fig~\ref{fig:acquisition} and Fig~\ref{fig:percentage_acquisition_2011} show the model's estimated percentage contribution of dengue importations by source country. \begin{figure*}[!h] \centering \includegraphics[width=0.9\linewidth]{Fig5} \caption{{\bf Rank-based validation and correlation between reported and predicted imported cases for Queensland in 2015.} ({\bf A}) Countries are ranked by the total number of predicted and reported imported dengue cases. The reported ranking is then plotted against the predicted ranking. Countries that were ranked by the model, but did not appear in the dataset receive a rank of $i+1$, were $i$ is the number of unique importation sources according to the dengue case data. Similarly, countries that appeared in the data and were not ranked by the model receive a rank of $i+1$. For circles that lie on the $x=y$ line (grey solid line) the predicted and reported rankings are equal. Circles that lie between the two dashed lines correspond to countries with a difference in ranking that is less than or equal to five. The circle areas are scaled proportionally to the number of reported cases that were imported from the corresponding country. Spearman's rank correlation coefficient between the absolute numbers of reported and predicted importations is equal to 0.6. ({\bf B}) The absolute number of reported dengue importations are plotted against the absolute number of predicted importations.} \label{fig:rankValidation} \end{figure*} Florida is predicted to import most infections from the Caribbean and Latin America, with infections acquired in Puerto Rico (PRI) predicted to peak during June and July and infections acquired in Brazil predicted to peak between January and April. We hypothesise that Florida receives such a high number of imported dengue cases due to its close proximity to the Caribbean, which has been endemic since the 1970s~\cite{Amarakoon2008}. France is predicted to receive many infections from the Caribbean, in particular from Martinique and Guadeloupe which are French overseas regions and hence a high volume of air traffic from these regions to metropolitan France is expected. These predictions align with the fact that outbreaks of dengue in France coincide with outbreaks in the French West Indies, where most reported cases are acquired~\cite{Vasquez2018,LaRuche2013}. In Italy the model predicts that the most common countries of acquisition are India and Brazil. India and Brazil are also the most common countries of acquisition for Switzerland in 2011. In 2015 Switzerland is predicted to receive most of their dengue importations from India and Thailand. Spain is predicted to import the majority of infections from Latin America and the Caribbean. For Queensland the model predicts that imported cases are acquired mostly in South-East Asia with Indonesia being the largest source. This is in agreement with previous studies~\cite{Warrilow2012} and the dengue case data that was provided by Queensland Health. In addition, we performed a rank-based validation of these results. We obtained dengue case data from Queensland Health, which records the places of acquisition for each dengue case reported in Queensland. We rank the countries of acquisition by the total number of predicted and reported dengue-infected people who arrive in Queensland. We then plot the reported ranking against the predicted ranking. In addition, we plot the absolute number of reported importations against the absolute number of predicted importations and calculate Spearman's rank correlation coefficient. Fig~\ref{fig:rankValidation} and Fig~\ref{fig:rankingQLD2011} show the results. The rank-based validation of our model demonstrates that overall, the model captures the different importation sources well. It does particularly well for the countries from which Queensland receives the most infections. Spearman's rank correlation coefficient is equal to 0.6 for the year 2015 and equal to 0.58 for the year 2011. Below we explain some of the differences between the data and the model output. For the rank-based validation the two largest outliers in both years are Fiji and Taiwan. The predicted ranking for Fiji in 2011 is 2, while the reported ranking is 10. In 2015 we estimate Fiji to be ranked fifth, however no cases were reported in 2015 and hence Fiji is ranked last amongst the reported cases. According to the Fijian government tourists are less likely to contract the disease than local residents as they tend to stay in areas that are not infested by \emph{Aedes aegypti} mosquitoes~\cite{TheFijianGovernment2014} or where there is likely considerable control effort undertaken by tourism accommodation operators. Since the incidence rates incorporated into our model do not distinguish between different regions of a source country, the model is unable to account for such nuances. In 2011 and 2015 we estimate Taiwan to be ranked seventh and eighth, respectively, however no cases were reported in both years. This result is surprising as dengue occurs year-round in Taiwan~\cite{IAMAT} and approximately 44,000 and 16,000 Queensland residents travelled to Taiwan in 2011 and 2015, respectively. \begin{table*}[!h] \centering \begin{tabular}{lccccc} \toprule & Dec-Feb & Mar-May & Jun-Aug & Sep-Nov & Yearly\\ \midrule Queensland & 32.4&48.9&18.6&22.6&28.6\\ Spain& 14&14&31.7&26.3&23.5\\ Italy & 4.5&6.8&9.2&13.1&9\\ France & 3.8&6.9&9.7&7.1&7.2\\ Florida & 0.9&0.7&1.2&2.7&1.4\\ \bottomrule \end{tabular} \caption{{\bf Yearly and seasonal reporting rates of imported cases in 2015.} The table shows the estimated reporting rates of imported cases for Queensland, Spain, Italy, France and Florida. We estimate the reporting rates by using a least squares linear regression without intercept.}\label{tab:reportingRates} \end{table*} Some of the differences between the observed percentages and the predicted percentages can be explained by under-reporting. It is possible that dengue awareness among travellers to one country is greater than the awareness amongst travellers to another country. Travellers with higher awareness levels are more likely to report to a doctor if feeling unwell after their return. \subsection*{Country-specific reporting rates} The reporting rate of a disease is defined as the ratio of reported infections to actual infections. Dengue reporting rates vary greatly across space and time and are difficult to determine~\cite{Stanaway2016}. The usual approach to estimating country-specific reporting rates is to carry out cohort or capture-recapture studies that can be costly, are time consuming and may be biased~\cite{Toan2015}. We utilised our model to infer country- and state-specific reporting rates of imported cases by performing a least squares linear regression without intercept. Table~\ref{tab:reportingRates} and Table~\ref{tab:reportingRates2011} show the estimated yearly and seasonal reporting rates of imported cases for Queensland, Florida, France, Italy and Spain. To distinguish locally acquired and imported cases in Queensland, we use case-based data from Queensland Health where the country of acquisition is recorded. Travel-related dengue cases reported in Europe are published by the European Centre for Disease Prevention and Control (\url{http://ghdx.healthdata.org/gbd-results-tool}). Data for Florida is available from the Florida Department of Health (\url{http://www.floridahealth.gov/diseases-and-conditions/mosquito-borne-diseases/surveillance.html}). The results show that estimated reporting rates of imported cases are highest in Queensland, in particular during autumn. This is expected as dengue awareness campaigns are intensified between November and April~\cite{QueenslandHealth2015}. In contrast, Florida has the lowest dengue reporting rate (1.3\% in 2011 and 1.4\% in 2015). This finding is supported by a previous study which found that awareness levels in Florida are extremely low~\cite{Hayden2015}. The estimated reporting rates for the European countries are also low; however, the model predicts a substantial increase from 2011 to 2015. The question why reporting rates in Queensland are higher is challenging to answer, as we do not have any information about the true number of imported cases. However, Queensland has one of the best dengue prevention programs in the world. According to Queensland Health, other states and countries frequently ask for training and advice regarding surveillance and awareness campaigns. \subsection*{Model uncertainty} We found that the average coefficient of variation of our importation model is 19.5\% across both years. That is, the model's standard deviation is on average equal to 19.5\% of its mean. Fig~\ref{fig:cv} shows the distribution of the coefficient of variation for several destinations. The results from the global sensitivity analysis show that $t_c$ is the most important of the three model parameters with a total-order index of 0.94 (see Fig~\ref{fig:sensitivity}). The different values of the first-order and total-order indices indicate interaction between the model parameters. The second-order indices show that there is significant interaction between parameters $t_c$ and $\beta_{c,m}$ with a second-order index of 0.19, as well as between parameters $t_c$ and $n$ with a second-order index of 0.1. Since the range of parameter $t_c$ is large ([1, 29200] days), we performed the sensitivity analysis again for a shorter range of values ([1, 30] days) that is more realistic for returning residents who spend their holidays in an endemic country. In this case, parameter $\beta_{c,m}$, with a total-order index of 0.6, is more important than $t_c$, which has a total-order index of 0.35 (see Fig~\ref{fig:sensitivity}). The second-order indices show that there is still significant interaction between parameters $t_c$ and $\beta_{c,m}$ with a second-order index of 0.06, and between parameters $t_c$ and $n$ with a second-order index of 0.07. \section*{Discussion} To mitigate the risk of outbreaks from importation of dengue into non-endemic regions it is critical to predict the arrival time and location of infected individuals. We modelled the number of dengue infections arriving each month at any given airport, which enabled us to estimate the number of infections that are imported into different countries and states each month. In addition, the model determines the countries of acquisition and hence is able to uncover the routes along which dengue is most likely imported. Our results can also be used to estimate country- and state-specific reporting rates of imported cases. Such knowledge can inform surveillance, education and risk mitigation campaigns to better target travellers along high risk importation routes at the most appropriate times. It will also help authorities to more efficiently surveil those airports with the highest risk of receiving dengue-infected passengers. The model proposed here overcomes many of the shortcomings of previous models, however, it is not without limitations. Validation through comparison of reported cases to predicted cases is infeasible due to the high degree of under-reporting. However, we demonstrate that the coefficient of variation of the model with 19.5\% on average is low (see Material and Methods). A rank-based validation for Queensland confirmed that the different importation sources are accurately predicted. Incidence rates may vary considerably from region to region within the same country~\cite{TheFijianGovernment2014} and higher resolution data could improve the model's predictions, as it would better reflect the export of dengue cases from the individual regions. Region-specific incidence rates can, for instance, be combined with spatial patterns of the visiting frequency of travellers to determine the likelihood of travellers to export dengue out of endemic countries. Additional data on individuals' travel behaviour may also be beneficial, as it can be analysed to improve the estimation of the average time that a person has spent in a specific country before arriving at a given airport. Our assumption that returning residents and visitors are exposed to the same daily incidence rates is a simplification. Further details on the types of accommodation, for example, resorts vs local housing, could also be used to inform the daily incidence rates, due to variations in vector control. The global sensitivity analysis has revealed that $t_c$, the number of days a traveller has spent in country $c$, is the most important model parameter. Hence, additional data on individuals' travel behaviour may substantially improve the model. Knowledge about the exact age of visitors who reside in non-endemic countries would also improve the model. Currently, we assume that the age of a visitor is equal to the median age of the population of the country in which the visitor resides. In reality, the age of air passengers may differ from the median age, especially for developing countries. In temperate regions local conditions may not allow for dengue to be transmitted during the winter months. Thus, even a large number of imported cases during those months would not trigger local outbreaks. Variable seasonality patterns due to El Ni\~{n}o Southern Oscillation can affect the spread of dengue in tropical and subtropical regions. An interesting direction for future research is to combine the here proposed model with knowledge of local conditions and weather phenomena like El Ni\~{n}o Southern Oscillation to evaluate the risk of local outbreaks. In this work we studied dengue importation via air travel. In future, we will also consider other modes of transportation to develop a more comprehensive model. \section*{Data availability statement} The air travel data used in this study are owned by a third party and were licensed for use under contract by International Air Travel Association (IATA)- Passenger Intelligence Services (PaxIS): \url{http://www.iata.org/services/statistics/intelligence/paxis/Pages/index.aspx}. The same data can be purchased for use by any other researcher by contacting: Phil GENNAOUI Regional Manager - Aviation Solutions (Asia Pacific) Tel: +65 6499 2314 | Mob: +65 9827 0414 <EMAIL> | www.iata.org Monthly dengue incidence rates for all countries for the years 2011 and 2015 are available as supplementary information files. Median population age data is publicly available from the Central Intelligence Agency at \url{https://www.cia.gov/library/publications/resources/the-world-factbook/fields/343.html}. International tourism arrival data used in this study are owned by a third party and cannot be shared publicly. The data is available for purchase from the World Tourism Organisation at \url{https://www.eunwto.org/action/doSearch?ConceptID=2445&target=topic}. Dengue notification data from Australia is publicly available from the Australian Department of Health at \url{http://www9.health.gov.au/cda/source/rpt_1_sel.cfm}. Dengue notification data from Europe is publicly available from the European Centre for Disease Prevention and Control at \url{http://atlas.ecdc.europa.eu/public/index.aspx}. Case-based dengue notifications for Queensland cannot be shared as it contains confidential information. The authors gained access to this data in accordance with Section 284 of the Public Health Act 2005. \section*{Acknowledgments} We would like to thank Frank de Hoog and Simon Dunstall for their constructive feedback which helped us to improve the model. We would also like to thank Queensland Health for providing dengue outbreak data. This work is part of the DiNeMo project. \bibliographystyle{unsrt}
\section{Introduction} The brain-computer interface (BCI) is a neural-inspired technology with the potential to become an alternative communication channel between man and machine. Bypassing peripheral nerves and muscles, users directly send commands to the machine through information presented in the brain signals. Electroencephalography (EEG) is a common tool for measuring brain activity in BCI applications \cite{1}. One type of brain signal is called Motor imagery (MI). To generate MI related-brain signals, a user is asked to imagine motor function execution such as hands or feet movements. Event-related desynchronization/synchronization (ERD/ERS) is a variation in brain signals during MI. ERD/ERS decoding has led to the development of an MI-based BCI \cite{2}. Recent studies on brain-controlled wheelchairs \cite{3} and quadcopters \cite{4} demonstrates that the possibilities for application of MI-based BCI. There are two major research approaches for improving the MI-EEG-based BCI. The first of which draws upon knowledge from behavioural neuroscience to enhance the MI-EEG signal-to-noise ratio (SNR). Instead of a simple hand movement imagery task, switching to a more complex one, such as writing Chinese characters, has been shown to enhance MI-EEG significantly \cite{7827070}. It may be concluded that high complex imagery tasks improve the SNR of MI-EEG. The second approach is via the development of more sophisticated classification algorithms using modern neural network techniques, namely deep learning (DL). Recently, DL approaches based on convolutional neural networks (CNN) and stacked auto-encoders (SAE) have shown promising results on MI-EEG classification \cite{1741-2552-14-1-016003}. In MI-EEG, the DL approach still has much room for improvement. Even though there are various studies on MI-EEG, the experimental protocols for collecting EEG signals leave a lot to be desired in terms of practicality. Almost all datasets have been gathered from synchronised tasks, allowing researchers to know the exact onset and offset time of imagery events \cite{4359220}. This bypasses many of the difficulties in signal cleaning and normalization. However, in real applications, the MI-based BCI needs to be asynchronous. This motivates the researchers to explore MI-EEG classification tasks in more practical scenarios. This study mainly focuses on three types of brain response, namely non-imagery EEG (\textit{background EEG}), \textit{pure imagery} EEG, and EEG during the transitional period between pure imagery and background EEG (\textit{transitional imagery}). The study of transitional imagery signals should provide greater insight into real-world scenarios. It may be inferred that pure imagery and transitional EEG are high and low power imagery EEG signals, respectively. DL models employ a cascade of one-dimensional convolutional neural networks (CNNs) \cite{doi:10.1162/neco.1997.9.8.1735} and a fully-connected network (FC) or CNN-FC is used in this study. The experiments compare three classification tasks: Firstly, to classify pure imagery from background EEG, secondly, transitional imagery from background EEG, and lastly, to separate both pure and transitional imagery from background EEG using a joint training scheme, considering pure and transitional imagery signals as the same class. Experimental results demonstrate that a joint training scheme using pure and transitional imagery (high and low power imagery) can improve the performance of the model in separating both pure and transitional imagery from background EEG. The researchers believe that this exploratory work is the first step towards practical MI-EEG-based BCI applications dealing with transitional periods in the signal. \section{METHODOLOGY} This section firstly introduces a publicly available motor imagery EEG (MI-EEG) dataset, and then explains the segmentation and pre-processing of data. The proposed DL approach is a cascade of one-dimensional CNN-FC. Then we compare outcomes from CNN-FC to the conventional approach, namely common spatial pattern and support vector machine (CSP-SVM) \cite{10.3389/fnins.2013.00267}. \begin{figure}[th] \centering \includegraphics[width=1.0\linewidth]{divided_pic.pdf} \caption{The collection protocol from MI-EEG. The first period (from 0 to 2 seconds) is denoted as background EEG. The second period is the transitional imagery interval (from 3 to 5 seconds). Finally, the interval of pure imagery is from 4 to 6 seconds.} \label{period of data} \end{figure} \begin{figure*} \centering \includegraphics[width=1\linewidth]{model_max1.pdf} \caption{Implementation of the cascade CNN-FC model on pre-processed data for training: talidation: testing samples are 81:9:10 \label{structure} \end{figure*} \subsection{Dataset} In this study, the MI-EEG dataset was used \cite{4359220}. Nine healthy subjects participated in five sessions of motor imagery experiments. The first two sessions were recorded without feedback and the other three sessions had combined online feedback. Participants were instructed to imagine movement on either their left or right hand. Each of the first two sessions consisted of 120 trials and the remaining three sessions 160 trials. As stated in the experimental protocol (\autoref{period of data}), one trial consisted of a time interval of between 8.5 to 9.0 seconds. The first interval is a resting state. During the following three-second period the participants were requested to carry out motor imagery tasks. Finally, another time interval of between 1.5 and 2 seconds consisted of a resting state lasting until the end of the trial. In summary, every subject had to take part in 280 trials, making this a substantial dataset in terms of both number of trials and participants. The data was selected and pre-processed using the following steps: \begin{itemize} \item EEG data with 250 Hz sampling frequency were extracted from three electrodes around the motor function area of a human brain ($C_{z}$, $C_{3}$ and $C_{4}$). \item A Bandpass was filtered at 7.0--30.0 Hz. \item As shown in \autoref{period of data}, the EEG signal was divided from a single trial into three classes, namely background EEG, transitional imagery, and pure imagery. \end{itemize} Moreover, those trials containing artifacts which were marked in the original dataset were removed. Hence, in the experiments, only clean or accepted trials were picked for further study. It is assumed that MI-EEG from clean trials could provide higher SNR and would be better in CNN-FC training. Finally, the MI-EEG data was arranged into the 0--1 range by standardization. \subsection{Proposed Deep Learning Approach} The architecture of the DL model is illustrated in \autoref{structure}. Three classes of pre-processed data (background EEG, pure imagery, and transitional imagery) from nine participants were prepared. As described in the data section, 12,600 samples $\times$ 500 points (two seconds-length) $\times$ 3 electrodes were obtained from each EEG class. According to Section II \textit{A}, only clean trials were selected from the total data, eventually resulting in 10,534 samples $\times$ 500 points $\times$ 3 electrodes for each class. The DL model began with a six layers of CNNs. The CNNs were used to extract spatial information and for learning the activation patterns of different MI-EEG signals. Thus, the shape of activation patterns (i.e. voltage values from different times) and their location (i.e. MI-EEG channel) were learnt from the stack of CNN layers. Outputs from the CNNs were then flattened into a single one-dimensional vector and subsequently fed into a stack of FCs. Finally, a softmax function was incorporated for binary classification. \subsection{Experiments and Evaluation} The purpose of this study is to answer the research question `` \textit{Can a joint training scheme help to improve the classification of both pure and transitional imagery EEG from background EEG ?} " The researchers considered that the pure and transitional imagery segments were from the same class, and background EEG was from another class. To answer the question, five experimental tasks were conducted as shown below: \begin{itemize} \item Task 1: to distinguish pure imagery from background EEG \item Task 2: to distinguish transitional imagery from background EEG \item Task 3: to distinguish both pure and transitional imagery (treated as the same class) from background EEG using a joint training scheme with transitional imagery: pure imagery (1:1) \item Task 4: to distinguish both pure and transitional imagery (treated as the same class) from background EEG using a joint training scheme with transitional imagery: pure imagery (1:4) \item Task 5: to distinguish both pure and transitional imagery (treated as the same class) from background EEG using a joint training scheme with transitional imagery: pure imagery (4:1) \end{itemize} Among the five tasks, the same training, validation, and testing procedure was performed (as shown in \autoref{structure}). Ten-fold cross-validation was used to train and evaluate each model. 81\% of the samples were used for the training, 9\% were used for the validation and the remaining 10\% were used for the testing. \subsubsection{Deep Learning (DL) Approach} As depicted in \autoref{structure}, the architecture of the model contains eight learnt layers--six convolutional and two fully-connected (CNN-FC), implemented using Keras \cite{chollet2015keras} with parameter configurations as follows: \begin{itemize} \item Six convolutional layers (CNNs) with 32, 64, 64, 128, 256, and 512 filters, respectively. \item Kernel size of 3 for all layers. \item The ReLU non-linearity was applied to the output of every convolutional and fully-connected layer. \item Max-pooling with a pooling size of 2 was applied after each convolutional layer. \item Dropout with a probability of 0.2 was used in the first convolutional layer. \item Batch normalization was applied after the second and third convolutional layers. \item Output from the last convolutional layer was flattened before being taken as fully-connected input. \item 256 neurons were in the first fully-connected layer (FC). \item Softmax was applied for classification (FC). \item The optimizer was Adadelta with a learning rate of 1.0. \end{itemize} \subsubsection{Machine Learning (ML) Baseline} To demonstrate the superiority in the proposed DL approach, namely the CNN-FC, a conventional ML for MI-BCI, namely common spatial pattern with support vector machine (CSP-SVM), was used for a baseline. Here, the CSP was implemented using the MNE-python package \cite{10.3389/fnins.2013.00267}, and configured using default parameters to obtain three spatial components as outputs. The outputs from CSP were then fed into the SVM. The SVM was implemented using Scikit-Learn \cite{scikit-learn} and the linear kernel function set with a \textit{C} value of 1. The CSP-SVM evaluated the performance using the same ten-fold cross-validation as in the CNN-FC, except for the ignorance of validation. Training and testing sets are generally sufficient for evaluating the ML approach. Testing accuracy, sensitivity, and specificity from CNN-FC and CSP-SVM were used to compare the results of both approaches among the five experimental tasks. For statistical analysis of the experimental results, one-way repeated measures analysis of variance (ANOVA) was performed, based on the assumption of sphericity. Greenhouse-Geisser correction was used when the data violates the sphericity assumption. In post hoc analysis, Bonferroni correction and pairwise comparison was performed. \section{Results} \autoref{g222} shows an example of a single trial EEG background (top), pure imagery (middle), and transitional imagery (bottom) signals. Presented EEGs (from $C_{3}$ electrode) were pre-processed by a bandpass filter at 7.0-30.0 Hz. These signals can not be classified by human inspection, but its can be classified by the proposed DL approach and the ML baseline. The results from the five experimental tasks are shown in \autoref{g_all}. Task 1 was designed to distinguish pure imagery from background EEG. Task 2 was designed to distinguish transitional imagery from background EEG. Task 3 was designed to distinguish balanced number of training samples between both pure and transitional imagery (treated as the same class) and background EEG using a joint training scheme with a ratio of 1:1. Task 4 was designed to distinguish imbalanced number of training samples between both pure and transitional imagery (treated as the same class) and background EEG using a joint training scheme with a ratio of 1:4. Finally, Task 5 was designed to distinguish imbalanced number of training samples between both pure and transitional imagery (treated as the same class) and background EEG using a joint training scheme with a ratio of 4:1. One-way repeated measures ANOVA with Greenhouse-Geisser correction reported significant differences among the experimental tasks, classified by CNN-FC and CSP-SVM approaches, \emph{F(1.899,17.089) = 2384.927, p$<$0.01}, \emph{F(1.628,14.652) = 11994.267, p$<$0.01}, respectively. In pairwise comparison of CNN-FC, the mean accuracy from Task 1 was significantly higher than the other tasks because only one pure imagery and EEG background were contained in the classification. In the same way, Task 4 was the second highest of the five tasks. This result was caused by the ratio of pure imagery:transitional imagery being 4:1. However, for Tasks 3 and Task 5 (with a joint training scheme and pure imagery:transitional imagery the sampling ratios were 1:1 and 1:4, respectively), giving significantly higher mean accuracies than Task 2 (without a joint training scheme). This answers the research question as to whether a joint training scheme can improve classification tasks between low power imagery EEG (transitional imagery) and background EEG. In the CSP-SVM approach, pairwise comparison results on all experimental tasks were consistent with those using the CNN-FC approach. \autoref{my-label} presents a comparison between mean accuracies, sensitivities, and specificities among five experimental tasks using CNN-FC and CSP-SVM approaches. The standard t-test, assuming unequal variances, was performed to compare the results between the CNN-FC and CSP-SVM. The CNN-FC gave significantly higher accuracy in Tasks 2 to Task 5 (\emph{t(17)=2.11, p$<$0.05}, \emph{t(11)=2.2.20, p$<$0.05}, \emph{t(16)=2.12, p$<$0.05} and \emph{t(13)=2.16, p$<$0.05}, respectively). The results in bold shown in Table 1 are significantly higher than the others. In summary, the mean accuracy results from the CNN-FC are promising and significantly higher than those from the CSP-SVM in Tasks 2 to Task 5. \begin{table*}[ht] \centering \caption{Comparison of mean accuracy, sensitivity, and specificity in binary classification (mean±standard error) among five experimental tasks using two implemented approaches for classification. The numbers in bold are statistically significantly higher than the others, p$<$0.01} \label{my-label} \resizebox{1.5\columnwidth}{!}{ \begin{tabular}{@{}ccccccc@{}} \toprule \multirow{2}{*}{\textbf{Task}} & \multicolumn{2}{c}{\textbf{Accuracy {[}\%{]}}} & \multicolumn{2}{c}{\textbf{Sensitivity {[}\%{]}}} & \multicolumn{2}{c}{\textbf{Specificity {[}\%{]}}} \\ \cmidrule(lr){2-3}\cmidrule(l){4-5} \cmidrule(l){6-7} & \textbf{CNN-FC} & \textbf{CSP-SVM} & \textbf{CNN-FC} & \textbf{CSP-SVM} & \textbf{CNN-FC} & \textbf{CSP-SVM} \\ \midrule \textbf{Task 1} & 96.72 $\pm$ 0.12 & \textbf{98.65 $\pm$ 0.03} & 96.39 $\pm$ 0.38 &\textbf{98.44 $\pm$ 0.06} & 97.04 $\pm$ 0.35 &\textbf{98.86 $\pm$ 0.00} \\ \midrule \textbf{Task 2} & \textbf{62.68 $\pm$ 0.38} & 52.41 $\pm$ 0.30 &\textbf{68.03 $\pm$ 2.02} & 52.01 $\pm$ 0.34 & 57.32 $\pm$ 2.45 & 52.81 $\pm$ 0.37 \\ \midrule \textbf{Task 3} & \textbf{71.52 $\pm$ 0.29} & 70.27 $\pm$ 0.09 &\textbf{59.17 $\pm$ 2.83} & 52.50 $\pm$ 0.15 & 83.87 $\pm$ 3.04 & 88.03 $\pm$ 0.15 \\ \midrule \textbf{Task 4} & \textbf{86.27 $\pm$ 0.19} & 85.32 $\pm$ 0.13 & 76.26 $\pm$ 0.61 &\textbf{78.56 $\pm$ 0.16} &\textbf{96.28 $\pm$ 0.44} & 92.09 $\pm$ 0.21 \\ \midrule \textbf{Task 5} & \textbf{62.63 $\pm$ 0.41} & 56.56 $\pm$ 0.20 & \textbf{64.12 $\pm$ 2.19} & 45.92 $\pm$ 0.43 & 61.14 $\pm$ 2.54 & \textbf{67.19 $\pm$ 0.37} \\ \bottomrule \end{tabular} } \end{table*} \begin{figure} \centering \includegraphics[width=0.9\linewidth]{gg2222.pdf} \caption{An example of qualitative comparison among single trial EEG from EEG background (top), pure imagery (middle), and transitional imagery (bottom). The presented EEGs (from $C_{3}$ electrode) were pre-processed using a bandpass filter at 7.0-30.0 Hz.} \label{g222} \end{figure} \begin{figure} \centering \includegraphics[width=1\linewidth]{BiGraph_1.pdf} \caption{Comparison of mean accuracies (n = 10) between different tasks. The error bar is standard. * denotes that Task 1 is significantly higher than the others, p$<$0.01.} \label{g_all} \end{figure} \section{Discussion} The experimental results in \autoref{g_all} demonstrate that a joint training scheme can improve the performance of the model in the separation of pure and transitional imagery (high and low power imagery) from background EEG. The study of transitional imagery signals offers greater insight into real-world scenarios. Moreover, the mean accuracy of CNN-FC reaches 86.27\% in the best joint training scheme Task 4, and this could be a good starting point for the proposed approach. In a practical scenario, an online MI-based BCI does not have onset and offset trigger events. Thus, the computer or machine will never know the start and end point of motor imagery signals from EEG \textbf{(asynchronously)}. Moreover, the incoming EEG will also be fed to the system continuously (and randomly). This is the reason why the study of transitional imagery recognition is very important to online system development. So far, none of the research groups have investigated this issue. It is hoped that the findings in this study will inspire further BCI research. The DL approach (CNN-FC in this study) uses a joint training scheme and not only shows MI-based BCI improvement but how this fundamental concept can also lead to further applications (for example, by adopting the DL approach to medical images). Furthermore, the DL approach with a combination of joint training and transfer learning is currently active in various applied data-driven research. However, it is still a challenge to incorporate these schemes and approaches in MI-based BCI. \section{Conclusions and Future Works} In summary, the proposed DL approach (a cascade of one-dimensional CNNs and FCs) was used with a joint training scheme for classification of background EEG (resting/normal state) and motor imagery (MI) EEG. The joint training scheme would benefit the development of an asynchronous MI-based brain-computer interface (BCI) in real-world scenarios. An asynchronous MI-based BCI should have the capability to recognize both pure imagery and non-pure imagery EEG (transitional imagery in this study). According to the experiments in this study, the joint training scheme outperformed typical training. In the future, the researchers propose to focus on adjusting the DL model to improve the performance even further and incorporate the approach into online MI-based BCI applications. \bibliographystyle{unsrt}
\section{Introduction} The Korteweg-de Vries (KdV) equation \begin{align}\label{KdV_nondim} \eta_{t}+ \eta_{x} + \ve \frac{3}{2} \eta \eta_{x} + \ve \frac{1}{6} \eta_{xxx} = 0 \end{align} is one of the most widely studied equations in mathematical physics today, and it stands as a paradigm in the field of completely integrable partial differential equations. The KdV equation admits a large number of closed-form solutions such as the solitary wave, the cnoidal periodic solutions, multisolitons and rational solutions. It also features an infinite number of formally conserved integrals which is one of the hallmarks of a completely integrable system. Indeed the conservation can be made mathematically rigorous using the techniques developed in \cite{BonaSmith}. While our understanding of this model equation is generally rather complete, there appears to be one aspect which has not received much attention. Indeed it seems that the link between the invariant integrals of the equation and physical conservation laws has not been well understood. In the present note we explore the ramifications of imposing mechanical balance laws such as momentum and energy conservation in the context of the KdV equation. To explain this point further, recall that if the equation is given in the form \eqref{KdV_nondim} then the first three conserved integrals are \begin{align} \label{conslaws} \int_{- \infty}^{\infty} \eta \, dx, \qquad \int_{- \infty}^{\infty} \eta^2 \, dx, \quad \mbox{ and } \quad \int_{- \infty}^{\infty} \left( \Sfrac{1}{3} \eta_x^2 - \eta^3 \right) \, dx. \end{align} The first integral is found to be invariant with respect to time $t$ as soon as it is recognized that the KdV equation can be written in the form \begin{align}\label{kdv_mass} \dtt \left( \eta \right) + \dxx \Big( \eta + \ve \frac{3}{4} \eta^2 + \ve \frac{1}{6} \eta_{xx} \Big) = 0. \end{align} The quantity appearing under the time derivative can clearly be interpreted as the excess mass density, and as shown in \cite{AK4}, the expressions appearing under the spatial derivative is the mass flux through a cross section of unit width due to the passage of a surface wave. Invariance of the second and third integrals is obtained from the identities \begin{align}\label{kdv_II} \dtt \left( \eta^2 \right) + \dxx \left( \eta^2 + \ve \eta^3 + \frac{\ve}{3} \eta \eta_{xx} - \frac{\ve}{6} \eta_{x}^2 \right) = 0, \end{align} \begin{align}\label{kdv_III} \dtt \left( \eta^3 - \frac{1}{3} \eta_x^2 \right) + \dxx \left( \eta^3 + \ve \frac{9}{8} \eta^4 + \frac{2}{3} \eta_x \eta_t \right. \left. + \frac{1}{3} \eta_{x}^2 + \ve \frac{1}{18} \eta_{xx}^2 + \ve \frac{1}{2} \eta^2 \eta_{xx} \right) = 0. \end{align} When contemplating these formulas, the question naturally arises if the invariant integrals in \eqref{conslaws} also have a physical meaning. Of course, the first integral represents the total excess mass, but we do not know whether the second or third integral represent any pertinent mechanical quantity. A second natural question is whether the fluxes appearing in \eqref{kdv_II} and \eqref{kdv_III} have a physical meaning. As a matter if fact, it was noted by the authors of \cite{AS} that the densities and fluxes appearing in \eqref{kdv_II} and \eqref{kdv_III} do not represent any concrete physical quantities. More recent work also clearly casts doubt on the exact conservation of energy in the KdV equation \cite{KRI2015,KRIR2017}. In light of these findings, one may then ask what the appropriate densities and fluxes are if momentum and energy conservation are to be understood in the context of the KdV equation. The main result of the present letter is that one may define densities and fluxes that represent momentum and energy conservation and lead to {\it approximate}, but not exact conservation. Indeed, we will show that if these quantities are chosen correctly, then momentum and energy conservation hold to the same order as the KdV equation is valid. To be more precise, if we call the non-dimensional momentum density by $I(\eta)$, and the non-dimensional flow force (momentum flux plus pressure force) by $q_I(\eta)$, we obtain the approximate local balance law \begin{align}\label{intro_I} \frac{\partial}{\partial t} I(\eta) + \frac{\partial}{\partial x} q_{I}(\eta) = \scrO(\ve^2). \end{align} Similarly, the approximate energy balance \begin{align}\label{intro_E} \frac{\partial}{\partial t} E(\eta) + \frac{\partial}{\partial x} q_{E}(\eta) = \scrO(\ve^2) \end{align} follows if the expressions for the energy density $ E(\eta)$ and the energy flux plus work rate due to pressure force $ q_E(\eta)$ are chosen appropriately. The plan of the paper is as follows. In Section 2, we explain the physical background against which the KdV equation is used as an approximate water-wave model. The developments in Section 2 are based on firm mathematical theory which has been developed in the last two decades, and is summarized handily in \cite{LannesBOOK}. Then using this background material, the statements of momentum and energy conservation introduced above will be made mathematically precise in sections 3 and 4. \section{The KdV equation in the context of surface water waves} We study the KdV equation as a model equation for waves at the free surface of an incompressible, inviscid fluid running in a narrow open channel where transverse effects can be neglected. Let $h_0$ be the depth of the undisturbed fluid. Denoting by $\lambda$ a typical wavelength and by $a$ a typical amplitude of a wavefield to be described, the number $\ve = a/h_0$ represents the relative amplitude, and $\mu = h_0^2 / \lambda^2$ measures the inverse relative wavenumber. The geometric setup of the problem is indicated in Figure \ref{Figure1}. In suitably non-dimensionalized variables, the surface wave excursion of right-going waves can be shown to satisfy the relation \begin{align*} \eta_{t}+ \eta_{x} + \ve \frac{3}{2} \eta \eta_{x} + \mu \frac{1}{6} \eta_{xxx} = \scrO(\ve^2, \ve \mu, \mu^2). \end{align*} If the wave motion is such that both $\ve$ and $\mu$ are small and of similar size, then we can take equation \eqref{KdV_nondim} to obtain an approximate description of the dynamics of the free surface. The approximation can be made rigorous using the techniques in \cite{BCL,Craig,Israwi,LannesBOOK,SchneiderWayne} and others. Sometimes the Stokes number $\mathcal{S} = \ve / \mu$ is introduced in order to quantify the applicability of the equation to a particular regime of surface waves. Let us assume for the time being that the Stokes number is equal to unity, so that we can work with a single small parameter $\ve$. In this scaling, we may also assume that initial data $\eta_0$ are given, such that for any $k>0$, we have $\|\dx^k \eta_0\|_{L^2} \le \scrO(1)$. \begin{figure} \begin{center} \includegraphics[scale=0.8]{IsrawiKalischSetupBott.eps} \end{center} \caption{\small The schematic elucidates the geometric setup of the problem. The free surface is described by a function $\eta(x,t)$, and the $x$-axis is aligned with the flat bed. } \label{Figure1} \end{figure} Using the aforementioned techniques, it can be shown that the velocity field $(\phi_{x},\phi_{z})$ at any non-dimensional height $z$ in the fluid column can be expressed in terms of a solution of the KdV equation to second order accuracy in $\ve$ by \begin{align}\label{phi_eq_x} \phi_{x}(x,z,t) = \eta - \ve \frac{1}{4}\eta^2 + \ve \Big( \frac{1}{3}- \frac{z^2}{2} \Big) \eta_{xx}, \end{align} \begin{align}\label{phi_eq_y} \phi_{z}(x,z,t) = - \ve z \eta_{x}. \end{align} Similarly, the pressure can be expressed in terms of a solution $\eta$ of the KdV equation as follows. First define the dynamic pressure by subtracting the hydrostatic contribution: \begin{equation*} P' = P - P_{atm}+ g z. \end{equation*} Since the atmospheric pressure is of a magnitude much smaller than the significant terms in the equation, it will be assumed to be zero. As shown in \cite{AK2}, the dynamic pressure $P'$ can the be approximated to second order in $\ve$ by \begin{equation}\label{P_expression} P'= \eta - \ohf \ve (z^2-1)\eta_{xx}. \end{equation} \section{Approximate momentum balance} \begin{figure} \begin{center} \includegraphics[scale=0.8]{tmpSTSTSTSTBott.eps} \end{center} \caption{\small The flow force $q_I$ represents the sum of momentum flux and pressure force on a fluid element of unit width, reaching from the free surface to the bed.} \label{Figure2} \end{figure} Using ideas from \cite{AK1,AK2}, we can define an approximate momentum density $I$ by substituting the horizontal velocity $\phi_x$ given by \eqref{phi_eq_x} into the integral $$ \int_{0}^{1+\ve\eta(x,t)} \phi_x(x,z,t) \, dz. $$ In the same vein, the momentum flux and pressure force are constructed using the integrals \begin{equation} \int_{0}^{1+\ve \eta} \phi_x^2 \, dz \quad \mbox{ and } \quad \int_{0}^{1+\ve \eta} p \, dz. \end{equation} In this way, using the asymptotic analysis delineated in \cite{AK4}, the horizontal momentum density in the KdV context is found to be \begin{equation}\label{momDensity} I = \ve \eta + \ve^2 \Sfrac{3}{4} \eta^2 + \ve^2 \Sfrac{1}{6} \eta_{xx}, \end{equation} and the horizontal momentum flux plus pressure force is \begin{equation}\label{momFlux} q_I = \Sfrac{1}{2} + \ve \eta + \ve^2 \Sfrac{3}{2} \eta^2 + \ve^2 \Sfrac{1}{3} \eta_{xx}. \end{equation} The approximate local momentum balance can be formulated as follows. \begin{theorem} $\mathrm{(Momentum \, balance) }$ Suppose $\eta$ is a solution of \eqref{KdV_nondim} with initial data $\eta_0$ satisfying $\| \partial_x^k \eta_0 \|_{L^2} = \scrO(1)$ for some integer $k \ge 5$. Then there is a constant $C$, so that the estimate $$ \left\| \dtt \Big\{ \eta + \ve \Sfrac{3}{4} \eta^2 + \ve \Sfrac{1}{6} \eta_{xx} \Big\} + \dxx \Big\{ \Sfrac{1}{2} + \eta + \ve \Sfrac{3}{2}\eta^2 + \ve \Sfrac{1}{3}\eta_{xx} \Big\} \right\|_{L^2} \le C \ve^2 $$ holds for all $t \in [0,\infty)$. \end{theorem} \begin{proof} \noindent It was shown in Prop. 6 in \cite{BonaSmith} that given initial data $\eta_0 \in H^k$, there exists a solution $\eta(x,t)$ which is bounded in the space $C(0,\infty,H^k)$. Thus all ensuing computations hold rigorously for members of $H^k$. Using the assumption that $\eta$ satisfies the KdV equation and dividing through by $\ve$, we can write the integrand in the statement of the theorem in the following way. \begin{multline*} \Big\{ \eta + \ve \Sfrac{3}{4} \eta^2 + \ve \Sfrac{1}{6} \eta_{xx} \Big\}_t + \Big\{ \Sfrac{1}{2} + \eta + \ve \Sfrac{3}{2} \eta^2 + \ve \Sfrac{1}{3} \eta_{xx} \Big\}_x \\ = \Big( \eta_t + \eta_x + \ve \Sfrac{3}{2} \eta \eta_x + \ve \Sfrac{1}{6} \eta_{xxx} \Big) + \ve \Big( \Sfrac{3}{4} \eta^2 + \Sfrac{1}{6} \eta_{xx} \Big)_t + \ve \Big(\Sfrac{3}{4}\eta^2 + \Sfrac{1}{6}\eta_{xx} \Big)_x \\ = 0 \, + \, \ve \Sfrac{3}{4} \Big( \eta_t^2 + \eta_x^2 \Big) + \ve \Sfrac{1}{6} \Big(\eta_{xxt} + \eta_{xxx} \Big) \qquad \qquad \qquad \qquad \qquad \qquad \\ = \ve \Sfrac{3}{2} \eta \Big( - \ve \Sfrac{3}{2} \eta \eta_{x} - \ve \Sfrac{1}{6} \eta_{xxx} \Big) + \ve \Sfrac{1}{6} \partial_x^2 \Big( - \ve \Sfrac{3}{2} \eta \eta_{x} - \ve \Sfrac{1}{6} \eta_{xxx} \Big) . \qquad \qquad \end{multline*} Since $\|\eta_0\|_{H^5}$ is on the order of $1$, and $\|\eta(\cdot,t)\|_{H^k}$ is bounded for all time, we have \begin{equation*} \sup_t \left\| \dtt\left\{ \eta + \ve \Sfrac{3}{4} \eta^2 + \ve \Sfrac{1}{6} \eta_{xx} \right\} + \dxx \left\{\Sfrac{1}{2} + \eta + \ve \Sfrac{3}{2} \eta^2 + \ve \Sfrac{1}{3}\eta_{xx} \right\} \right\|_{L^2} \le C^2 \ve^2 \end{equation*} for some constant $C$ for $t \in [0,\infty)$. \\ \end{proof} \begin{remark} It should be noted that the $L^2$ norm used in the proof can be replaced by any Sobolev norm $H^k$ so long as the initial data are regular enough. Indeed it can be seen immediately from the proof that if the approximate momentum balance is to be proved in $H^k(\R)$, then the initial data should be given in $H^{k+5}(\R)$. \end{remark} Another important point is that the estimate in Theorem 1 is independent of the time $t$. In other words, the momentum balance is global in the sense that it holds as long as the solution of the KdV equation exists. This is in stark contrast to the proofs providing the approximation property of the KdV equation for the water-wave problem which are generally such that the error is bounded by $C\ve^2 (1+t)$, so that as $t$ gets larger, the approximation degenerates, and if $t \sim 1 / \ve$, the approximation is only on the order of $\ve$. Thus in this sense the momentum balance is self-consistent i.e. it is independent of the approximate nature of the KdV equation with regards to the water-wave problem. \section{Approximate energy balance} Using ideas from \cite{AK2,AK4}, we can define an approximate energy density $E$ by substituting the horizontal velocity $\phi_x$ given by \eqref{phi_eq_x} into the integral $$ \int_{0}^{1+\ve\eta} \big\{ \phi_x^2 + \phi_z^2 + z \big\} \, dz, $$ where the last term in the integrand represent the potential energy. In the same vein, the energy flux and work rate due to pressure force are constructed using the integrals \begin{equation} \int_{-0}^{1+\ve \eta} \big\{ \phi_x^2 + \phi_z^2 + z \big\} \phi_x \, dz \quad \mbox{ and } \quad \int_{-0}^{1+\ve \eta} p \phi_x \, dz. \end{equation} In this way, using again the asymptotic analysis explained in \cite{AK4}, the horizontal energy density in the KdV context is found to be \begin{equation} E = \frac{1}{2} + \ve \eta + \ve^2 \eta^2, \end{equation} and the horizontal energy flux plus work rate due to pressure force is \begin{equation} q_E = \ve \eta + \ve^2 \frac{7}{4}\eta^2 + \ve^2 \frac{1}{6}\eta_{xx}. \end{equation} For the energy balance, we have the following theorem. \begin{theorem} $\mathrm{(Energy \, balance) }$ Suppose $\eta$ is a solution of \eqref{KdV_nondim} with initial data $\eta_0$ satisfying $\| \partial_x^k \eta_0 \|_{L^2} = \scrO(1)$ for an integer $k \ge 4$. Then there is a constant $C$, so that the estimate $$ \left\| \dtt \Big\{\Sfrac{1}{2} + \eta + \ve \eta^2 \Big\} + \dxx \Big\{\eta + \ve \Sfrac{7}{4}\eta^2 + \ve \Sfrac{1}{6}\eta_{xx} \Big\} \right\|_{L^2} \le \scrO(\ve^2) $$ holds for all $t \in [0,\infty)$. \end{theorem} \begin{proof} The proof is similar, but simpler. Observe that \begin{multline} \dtt \Big\{\Sfrac{1}{2} + \ve \eta + \ve^2 \eta^2 \Big\} + \dxx \Big\{\ve \eta + \ve^2 \Sfrac{7}{4}\eta^2 + \ve^2 \Sfrac{1}{6}\eta_{xx} \Big\} \\ = \ve \eta_t + \ve \eta_x + \ve^2 \frac{3}{2} \eta \eta_x + \ve^2 \frac{1}{6} \eta_{xxx} + 2 \ve^2 \eta \eta_t + 2 \ve^2 \eta \eta_x \\ = - 3 \ve^3 \eta^2 \eta_x - \ve^3 \frac{1}{3} \eta \eta_{xxx}. \qquad \qquad \end{multline} The estimate now follows in the same way as for the momentum balance above. \end{proof} In some cases, it is convenient to normalize the potential energy differently, so that the undisturbed state has zero potential energy. The approximate energy density $E^*$ is then defined by substituting the horizontal velocity $\phi_x$ given by \eqref{phi_eq_x} into the integral $$ \int_{0}^{1+\ve\eta} \big\{ \phi_x^2 + \phi_z^2 \big\} \, dz \ + \ \int_{1}^{1+\ve\eta} z \, dz. $$ As shown in \cite{AK4}, in this case, the energy density and energy flux have the respective form $$ E^* = \ve^2 \eta^2 + \frac{1}{4} \ve^3 \eta^3 + \frac{1}{6} \ve^3 \eta \eta_{xx} + \frac{1}{6} \ve^3 \eta_{x}^2, $$ $$ q_E^* = \ve^2 \eta^2 + \frac{5}{4} \ve^3 \eta^3 + \frac{1}{2} \ve^3 \eta \eta_{xx}. $$ \begin{theorem} $\mathrm{(Energy \, balance) }$ Suppose $\eta$ is a solution of \eqref{KdV_nondim} with initial data $\eta_0$ satisfying $\| \partial_x^k \eta_0 \|_{L^2} = \scrO(1)$ for some integer $k \ge 6$. Then there is a constant $C$ such that the estimate $$ \left\| \dtt \Big\{ \eta^2 + \frac{1}{4} \ve \eta^3 + \frac{1}{6} \ve \eta \eta_{xx} + \frac{1}{6} \ve \eta_{x}^2 \Big\} + \dxx \Big\{ \eta^2 + \frac{5}{4} \ve \eta^3 + \frac{1}{2} \ve \eta \eta_{xx} \Big\} \right\|_{L^2} \le C \ve^2 $$ holds for all $t \in [0,\infty)$. \end{theorem} \begin{proof} The key computation is the following. \begin{multline*} \dtt \Big\{ \eta^2 + \ve \frac{1}{4} \eta^3 + \ve \frac{1}{6} \eta \eta_{xx} + \frac{1}{6} \ve \eta_{x}^2 \Big\} + \dxx \Big\{ \eta^2 + \ve \frac{5}{4} \eta^3 + \ve \frac{1}{2} \eta \eta_{xx} \Big\} \\ = 2 \eta (\eta_t + \eta_x) + \ve \frac{3}{4} \eta^2 \eta_t + \ve \frac{1}{6} \eta_t \eta_{xx} + \ve \frac{1}{6} \eta \eta_{xxt} + \ve \frac{1}{3} \eta_x \eta_{xt} + \ve \frac{15}{4} \eta^2 \eta_x + \ve \frac{1}{2} \eta_x \eta_{xx} + \ve \frac{1}{2} \eta \eta_{xxx} \\ = \ve \frac{3}{4} \eta^2 \eta_t + \ve \frac{1}{6} \eta_t \eta_{xx} + \ve \frac{1}{6} \eta \eta_{xxt} + \ve \frac{1}{3} \eta_x \eta_{xt} + \ve \frac{3}{4} \eta^2 \eta_x + \ve \frac{1}{2} \eta_x \eta_{xx} + \ve \frac{1}{6} \eta \eta_{xxx} \\ = \ve \frac{3}{4} \eta^2 ( \eta_t + \eta_x) + \ve \frac{1}{6} \eta \dx^2 ( \eta_t + \eta_x) + \ve \frac{1}{6} \eta_t \eta_{xx} + \ve \frac{1}{3} \eta_x \eta_{xt} + \ve \frac{1}{2} \eta_x \eta_{xx} \\ = \scrO(\ve^2) + \scrO(\ve^2) + \ve \frac{1}{2} (\eta_t + \eta_x) \eta_{xx} + \ve \frac{1}{3} ( - \eta_t \eta_{xx} + \eta_x \dx \eta_{t} )\\ = \scrO(\ve^2) + \scrO(\ve^2) + \scrO(\ve^2) + \ve \frac{1}{3} \Big( \big( \eta_x + \scrO(\ve) \big) \eta_{xx} + \eta_x \dx \big( - \eta_{x} + \scrO(\ve) \big) \Big). \end{multline*} The proof now proceeds along the same lines as above. \end{proof} It should be noted that also in the case of the energy balance, the $L^2$ norm used in the proofs can be replaced by any Sobolev norm $H^k$ as long as the initial data are regular enough. \section{Discussion} In the present letter, it was shown that momentum and energy conservation hold {\it approximately} in the context of the KdV equation. The approximate momentum and energy balances can be made rigorous solely by using well-posedness results for the KdV equation such as provided in \cite{BonaSmith} and in many other contributions. One interesting aspect of these approximate balance laws is that they hold independently of the fidelity of the KdV solution as an approximation of a solution of the water-wave problem based on the full Euler equations. To explain this further, note that it was shown in \cite{IsrawiKalischCRASS} that the momentum density $I$ defined above in \eqref{momDensity} approximates the corresponding quantity in the full Euler equations as long as the solution of the KdV equation is a close approximation of the full Euler equations. Indeed it was possible to show that the estimate \begin{equation}\label{MomApprox} \Big\| \int_{0}^{1+\ve\eta} \phi_x \, dz - I\Big\|_{H^s} \leq C \ve^2 (1+t) \end{equation} holds. Similar estimates can probably be shown for the quantities $q_I$, $E$ and $q_E$. Note however, that the estimate \eqref{MomApprox} degenerates as $t$ gets larger and approaches $t \sim 1 / \ve$. The results in Theorems 1, 2 and 3 in the present note have no such restriction. Indeed, they hold {\it globally} for all $t \ge 0$. Finally, let us point out that having the correct form of quantities such as $I$, $q_I$, $E$ and $q_E$ can be useful when applying the KdV equation in situations where knowledge of the free surface profile is insufficient. Indeed, there are situations where the internal dynamics of the flow are an important factor. An example of such an application is the study of the energy balance in undular bores \cite{AK1}. The energy flux $q_E$ was also used in a decisive way in a study of nonlinear shoaling in \cite{KK}. \\ \vskip 0.05in \noindent {\bf Acknowledgments.} This research was supported by the Research Council of Norway under grant no. 239033/F20. HK would like to thank the Isaac Newton Institute for Mathematical Sciences, Cambridge University and the Simons foundation for support and hospitality when work on this paper was undertaken. SI would like to thank University of Bergen and the Department of Mathematics for support and hospitality when work on this paper was undertaken.
\section{INTRODUCTION} Hadron spectroscopy has for many years been used to determine the interactions between the partons of the nucleon, and the degrees of freedom afforded in non-perturbative QCD. Despite the wealth of data for both the pion and photoproduction of many hadronic states, there remain many ``missing resonances'' which are predicted by Constituent Quark Models (CQM) but are not observed experimentally~\cite{klempt10}. Moreover, some of the lowest observed states are not described satisfactorily. The pattern of the mass and parity of the Roper resonance ($N$(1440)1/2$^+$) and the $N$(1535)1/2$^-$ for example, where the state above ground state would be expected to have negative parity, is hard to reconcile with a CQM of ``dressed'' quarks in a mutually generated potential, irrespective of the shape of this potential. The \newline $\Lambda$(1405) - $N^*$(1535) mass ordering (despite the $\Lambda$(1405) being a $uds$ singlet state), and the mass between the $\Lambda$(1405) and its spin-orbit partner, $\Lambda$(1520), are also difficult to interpret within a CQM framework. In the ``heavy'' charmed quark sector, the recently discovered pentaquark states, $P_c$(4450)$^+$ and $P_c$(4380)$^+$~\cite{aaij15} are the first unambiguous indications of baryons of at least five constituent quarks. Since the conception of the quark model, there has been discussion of the possibility of hadrons of more than three constituent quarks~\cite{gellmann64, jaffe77, strottmann79}, and due to the proximity of the chiral symmetry breaking scale to the nucleon mass, it is possible that light mesons may interact as elementary objects, giving rise to molecular systems and meson rescattering effects near thresholds~\cite{manohar84, glozman96}. It is still an open as to question whether the pentaquark states are bound five quark systems, or have a molecular-like composition to some extent. The model of Wu \textit{et al.}~\cite{wu10b}, for example, successfully describes these as meson-baryon dynamically generated states. Similarly in the meson sector, the $X$(3872) lies close to the $D^0\bar{D}^{0*}$ threshold and has also been described as a molecular state (see for example Ref.~\cite{tornqvist04}). In the ``light'' strange quark sector, models including molecular-like meson-baryon interactions as additional degrees of freedom have had improved success in describing observed states ~\cite{dalitz67, siegel88, kaiser97, recio04, lutz04}. The $\Lambda$(1405) appears to be dynamically generated from meson-baryon interactions to some extent~\cite{nacher03}, which is also supported by recent LQCD calculations~\cite{hall15}. Models including vector meson-baryon interactions have predicted further dynamically generated states, for example states at 2~GeV with $J^P = 1/2^-$ and $3/2^-$~\cite{gonzalez09, sarker10, oset10}, which may have been observed in $K^0\Sigma^+$ photoproduction~\cite{ralf, ewald14} at the $K^*Y$ thresholds. The BGO-OD experiment is ideally suited to study phenomena from hadronic reactions in a low momentum exchange region, where extended, molecular-like structure may manifest. The extremely forward charged particle acceptance, complemented by neutral particle reconstruction over a central region allows complicated final states to be reconstructed, enabling the study of phenomena from molecular or exotic structure in the strange quark sector. \section{EXPERIMENTAL SETUP} BGO-OD (Fig.~\ref{fig:bgood}) is a fixed target experiment using real, energy tagged photon beams at the ELSA electron accelerator facility~\cite{hillert06}. An electron beam up to 3.2~GeV is incident upon a thin metal radiator to produce bremsstrahlung photons, with linearly and circularly polarised beams both available. BGO-OD is composed of two distinct parts: a forward spectrometer ($\theta < 12^0$) for charged particle identification, and a central calorimeter region ($\theta = 25-155^0$) ideal for neutral meson reconstruction. A plastic scintillating detector (SciRi) covers the small acceptance gap between these. The target is surrounded by an MWPC for charged particle track reconstruction. Surrounding this is a segmented cylinder of plastic scintillator material for charged particle identification via $\Delta E-E$. Outside of this is the BGO ball; a segmented calorimeter of 480 BGO crystals. The BGO ball is ideal for the reconstruction of photon four-momenta via electromagnetic showers in the crystals. The separate time readout per crystal, with a resolution of approximately 3~ns, enables clean identification of neutral meson decays (Fig.~\ref{fig:2gamma}(a,b)). The forward spectrometer uses two scintillating fibre detectors (SciFi2 and MOMO) to track charged particles from the reaction vertex. Particles proceed through the open dipole magnet, operating at a maximum field strength of 0.45~T. Eight double layered drift chambers track particle trajectories after curvature in the magnetic field. The momentum, $p$, is determined by the extent of deflection in the field, with a resolution of approximately $0.04p$. Time Of Flight walls downstream from the drift chambers enable particle identification via the combination of momentum and $\beta$ (Fig.~\ref{fig:2gamma}(c-f)). \begin{figure}[t] \centerline{\includegraphics[width=0.5\linewidth]{BGO-OD-45-mit-mann-low-eps-converted-to.pdf}\includegraphics[width=0.5\linewidth]{BGOSliceView1.png}} \caption{The BGO-OD experiment at the ELSA facility, Bonn, Germany}\label{fig:bgood} \end{figure} \begin{figure}[h] \includegraphics[width=\linewidth]{BGOODAnalysis-eps-converted-to.pdf} \caption{Neutral meson reconstruction in the BGO calorimeter (a,b) and charged particle identification in the forward spectrometer (c-f). (a) The missing mass recoiling from two photons in the final state versus the invariant mass of the two photons. Peaks corresponding to $\pi^0p$ and $\eta p$ final states are visible. (b) The invariant mass of two photons for events where the missing mass is within two sigma of the proton mass. Mean and sigma of a Gaussian fit are inset for $\pi^0$ and $\eta$ mesons. (c) Forward charged particle $\beta$ (derived from time of flight) versus particle momenta. Red lines indicate the expected loci of charged pions, kaons and protons. (d) Particle mass calculated from $\beta$ and momentum. (e) Missing mass from forward protons. Peaks corresponding to single meson final states are labelled inset. (f) The same as (e) but with a different scale to observe the small peak corresponding to the $\phi p$ final state.}\label{fig:2gamma} \end{figure} Numerous hadronic final states have been identified, and cross sections calculated to act as a bench mark and to determine systematic uncertainties in analyses. Figure~\ref{fig:omega} is a preliminary example of the $\gamma p \rightarrow \omega p$ differential cross section, identified via the mixed final state; $\omega\rightarrow \pi^0\pi^+\pi^-$. From a comparitively limited dataset, there is good agreement with existing data shown in the figure. \begin{figure}[!h] \preliminary{\includegraphics[width=0.5\linewidth]{OmegaCS1-eps-converted-to.pdf}}\preliminary{\includegraphics[width=0.5\linewidth]{OmegaCS2-eps-converted-to.pdf}} \caption{$\gamma p \rightarrow \omega p$ differential cross sections for two centre of mass angle ranges, $\theta_{CM}$ (labelled inset), via the identification of the decay, $\omega\rightarrow \pi^0\pi^+\pi^-$. Preliminary BGO-OD data in black, previous data from F. Dietz \textit{ et al.} (CB-ELSA/TAPS collaboration)~\cite{dietz15} in cyan, previous data from M. Williams \textit{ et al.} (CLAS collaboration)~\cite{williams09} in magenta.}\label{fig:omega} \end{figure} \section{$\Lambda$(1405) LINE SHAPE AND DIFFERENTIAL CROSS SECTIONS, AND ACCESS TO HIGHER LYING HYPERONS} CQMs have very limited success in describing $\Lambda^*$ and $\Sigma^*$ states, with models including additional degrees of freedom from molecular-like meson-baryon interactions having far better agreement. Of the 26 $\Sigma^*$ listed in the Particle Data Group review, 16 are listed as an existance as poor to fair, with little progression for the last 30 years~\cite{pdg}. Figure \ref{fig:hyperons}(a) shows the missing mass from the detection of $K^+$ in the BGO-OD forward spectrometer. This extremely low momentum transfer region provides a unique window into the potential molecular-like structure of hyperons. Peaks corresponding to the ground state $\Lambda$ and $\Sigma^0$ are clear, and higher lying hyperons $\Lambda$(1405), $\Sigma$(1385), $\Lambda$(1520) are visible with no further selection criteria. Hyperons overlapping in mass can be separated from the detection of $\pi^0\rightarrow \gamma\gamma$ in the BGO. Figure~\ref{fig:hyperons}(b) shows the missing mass recoiling from the $K^+\pi^0$ system versus the missing mass recoiling from the $K^+$. For the decays $\Lambda$(1405)$\rightarrow \pi^0\Sigma^0$ and $\Sigma$(1385)$\rightarrow \pi^0\Lambda$, for example, the missing mass from the $K^+\pi^0$ system are $\Sigma^0$ and $\Lambda$ respectively. There is ongoing analysis using this method to determine the line shape and differential cross section for $\Lambda$(1405)$\rightarrow \pi^0\Sigma^0$ at forward angles. This low momentum-exchange region is crucial in determining the underlying dynamics of the $\Lambda$(1405) and complementary to existing data, notably, the datasets of all three decay modes from CLAS~\cite{moriya13}. \begin{figure}[t] \includegraphics[width=\linewidth]{ForSpecKPlus-eps-converted-to.pdf} \caption{$K^+Y^{*}$ identification in the forward spectrometer. (a) Missing mass from forward $K^{+}$. Hyperons (labelled inset) are observed in this low momentum exchange region up to a maximum mass of approximately 2~GeV/c$^2$. (b) The missing mass from the $\pi^0 K^+$ system is plotted against the missing mass from the $K^+$. The red and black labels indicate the expected mass missing from the $\pi^0 K^+$ system and the mass missing from the $K^+$ system respectively.}\label{fig:hyperons} \end{figure} The same decay mode can be identified over a broad angular range via the identification of all final state particles: $K^+ Y^*\rightarrow K^+\pi^0\Sigma^0\rightarrow\rightarrow K^+\gamma\gamma\gamma\pi^- p$, and the application of a kinematic fit~\cite{georg}. Figure \ref{fig:lambda1405invmass} shows the invariant mass for two different polar angle bins, where peaks corresponding to $\Lambda$(1405) and $\Lambda$(1520) are present. This ongoing work will complement a limited data set, and aid in constraining models, such as the triangle singularity proposed by Wang \textit{et al.}~\cite{wang17}. \begin{figure}[t] \preliminary{\includegraphics[trim={0cm 0cm 0 0},clip,width=\linewidth]{GeorgLambda1405Revised-eps-converted-to.pdf}} \caption{Identification of $K^+\Lambda$(1405) and $K^+\Lambda$(1520) final states via identification of all decay particles from \newline $K^+ Y^*\rightarrow K^+\pi^0\Sigma^0\rightarrow\rightarrow K^+\gamma\gamma\gamma\pi^- p$~\cite{georg}. The hyperon invariant mass is plotted for two different centre of mass bins, $\theta^{cm}_{K^+}$.}\label{fig:lambda1405invmass} \end{figure} \section{FORWARD CROSS SECTIONS FOR $K^+\Lambda$ AND $K^+\Sigma^0$ PHOTOPRODUCTION} The photoproduction of the ground state hyperons, $K^+\Lambda$ and $K^+\Sigma^0$ is poorly understood at forward angles. The paucity of data for $\cos\theta^{cm}_{K^+} > 0.9$ and discrepancies between data sets prevent the constraining of isobar models and partial wave analyses (shown, for example, in Refs.~\cite{skoupil18, bydzovsky12} and references therein). This is a vital region to understand reaction mechanisms in associated strangeness photoproduction, where forward peaked, $t$-channel mechanisms play dominant roles. This is also crucial as an input for the modelling and data fitting of hypernuclei electroproduction: the low $Q^2$ required to ensure the $\Lambda$ remains bound to the nucleus means that the exchanged virtual photon is almost on-shell. The BGO-OD forward spectrometer covers the centre of mass polar angle range of approximately 3-26$^0$, with an angular resolution better than 1$^0$. Figure \ref{fig:mm} shows the missing mass from forward $K^+$ for two centre of mass intervals. Peaks corresponding to $\Lambda$ and $\Sigma$ (only for $W$ above threshold) are clear. The background tail to lower mass originates from pair production in the beam which are deflected in the OD magnet. Careful timing criteria remove most of this, which originates from adjacent electron bunches in time to the triggered hadronic event. The remainder is fitted to by an equivalent analysis of negatively charged particles in the forward spectrometer, providing a distribution of electron/positron background. This is combined with spectra from simulated data to fit to signal and background using RooFit~\cite{roofit}, and to separate $K^+\Lambda$ and $K^+\Sigma^0$ events. \begin{figure}[t] \preliminary{\includegraphics[trim={10cm 0 0 0},clip,width=0.5\linewidth]{W_1600_1700-eps-converted-to.pdf}}\preliminary{\includegraphics[trim={10cm 0 0 0},clip,width=0.5\linewidth]{W_1700_1800-eps-converted-to.pdf}} \caption{Missing mass from forward $K^+$ for two centre of mass energy ranges. The black points are experimental data which have been fitted to using RooFit~\cite{roofit}: background from pair production in the beam (cyan line), simulated $K^+\Lambda$ (red line) and simulated $K^+\Sigma^0$ (magenta line). The blue line is the sum from the three fit components.}\label{fig:mm} \end{figure} Figure.~\ref{fig:cs} shows preliminary differential cross sections for $\gamma p \rightarrow K^+\Lambda$ and $K^+\Sigma^0$ for $\cos^{CM}_{K^+} > 0.9$. This high statistics data set shows good agreement with existing data for $K^+\Sigma^0$, and is able to resolve long standing discrepancies in the $K^+\Lambda$ data sets. It should be noted that the Bonn-Gatchina partial wave analysis~\cite{bnga} is constrained by the CLAS data sets only. The high angular resolution of the forward spectrometer permits an unprecented detailed description of the cross section at forward angles, which will be a vital constraint for hypernuclei electroproduction. There is ongoing analyses to measure both cross sections in intervals of approximately 0.02 $\cos^{CM}_{K^+}$, and it is anticipated the data will extend to a photon beam energy of 1.5~GeV, with a 1.5 increase in statistics. \begin{figure}[t] \preliminary{\includegraphics[clip,width=\linewidth]{KPlusCrossSections-eps-converted-to.pdf}} \caption{Preliminary forward differential cross sections for (a) $K^+\Sigma^{0}$ and (b) $K^+\Lambda$ photoproduction. Bold black points: preliminary BGO-OD data, vertical errors bars are the statistical error, horizontal error bars are the width of each energy interval. Red triangles: data from Glander \textit{et al.}~\cite{glander04}, inverted green triangles: data from Bradford \textit{et al.}~\cite{bradford06}, blue circles: data from Dey \textit{et al.}~\cite{dey10} and McCracken \textit{et al.}~\cite{mccracken10} for $K^+\Sigma^0$ and $K^+\Lambda$ respectively, magenta line: solution from the Bonn-Gatchina Partial Wave Analysis~\cite{bnga}.}\label{fig:cs} \end{figure} \section{NEUTRAL KAON PHOTOPRODUCTION} The BGO-OD experiment is uniquely suited for $K^0_S$ identification, as the mixed charged final state reconstruction allows identification via both $K^0_S\rightarrow \pi^0\pi^0$ (neutral decay) and $K^0_S\rightarrow\pi^+\pi^-$ (charged decay). High statistics data with a liquid hydrogen target has been taken with linearly polarised photons over the $K^*$ threshold region. Differential cross sections and beam asymmetry measurements will resolve reaction mechanims where a cusp-like structure was observed in previous data~\cite{ralf,ewald14}. As discussed in the introduction, similarly to the model of Wu \textit{et al.,}~\cite{wu10b} which described the pentaquark states, $P_c(4450)^+$ and $P_c(4380)^+$ as dynamically generated through rescattering effects, the model of Oset~\textit {et al.}~\cite{oset10}, has been fitted to the cusp in $K^0\Sigma^+$ cross section data~\cite{ralf,ewald14}, predicting dynamically generated meson-baryon states in the ``light'' strange quark sector. Figure~\ref{fig:k0}(a) shows preliminary invariant mass of the $2\pi^0$ system, with a peak at the $K^0$ mass. Simulated data was used to describe background from other multi-pion final states. Figure~\ref{fig:k0}(b) shows the $\Sigma^+$ invariant mass peak via the identification of the charged $K^0_S$ decay. Both analyses are prior to a kinematic fit, which is currently being implemented. The signal from the charged decay will also be improved by identifying the detached decay vertex using the MWPC ($c\tau_{K^0_S} \approx 2.7$~cm). \begin{figure}[h] \preliminary{\includegraphics[trim={0cm 0 0 0},clip,width=\linewidth]{K0-eps-converted-to.pdf}} \caption{$\gamma p \rightarrow K^0_S\Sigma^+$ reconstruction. (a) Identification via the charged decay, $K^0_S\rightarrow \pi^+\pi^-$. The $\Sigma^+$ invariant mass peak is shown in blue, with background contributions shown in green~\cite{bjoern}. (b) Identification via the neutral decay, $K^0_S\rightarrow \pi^0\pi^0$. A polynomial and Gaussian function have been fitted to background and $K^0_S$ invariant mass signal respectively~\cite{stefan}.}\label{fig:k0} \end{figure} \begin{figure}[h] \preliminary{\includegraphics[trim={0cm 13.1cm 0 0},clip,width=0.5\linewidth]{K0_InvMassOnly-eps-converted-to.pdf}}\preliminary{\includegraphics[trim={0cm 0 0 13cm},clip,width=0.5\linewidth]{K0_InvMassOnly-eps-converted-to.pdf}} \caption{$K^0_S\Lambda$ and $K^0_S\Sigma^0$ reconstruction using a deuterium (neutron) target. (a) Two $\pi^0$ invariant mass. A polynomial and Gaussian function are fitted to describe background and the mass peak from the $K^0_S$ respectively, with the Gaussian function parameters inset. (b) Equivalent to (a) but with an additional proton identified in the forward spectrometer from the $\Sigma^0\rightarrow p \pi^-$ decay.}\label{fig:k0neutron} \end{figure} The model of Oset \textit{et al.}~\cite{oset10} predicts that the states that interfer destructively to produce a cusp in $K^0_S\Sigma^+$ photoproduction will interfer constructively in $K^0_S\Sigma^0$ to produce a peak-like structure at the $K^*$ thresholds. The study of this channel using a deuterium target will therefore act as a ``smoking gun'' for molecular-like structure in the light quark sector. Figure~\ref{fig:k0neutron} shows preliminary $K^0_S$ identification from a small commissioning data set using a deuterium target. A peak in the $2\pi^0$ invariant mass spectrum is clearly seen above background. Figure~\ref{fig:k0neutron}(b) additionally requires a proton in the forward spectrometer from $\Sigma^0\rightarrow p\pi^-$ and for the missing mass from the $2\pi^0p$ system to be consistent with a $\pi^-$ mass. This improves the signal to background ratio, albeit at the loss of statistics. An equivalent analysis using liquid hydrogen target did not produce a signal. Analyses using both real and simulated data has demonstrated the separation of $K^0\Sigma^0$ and $K^0\Lambda$ via the identification of the photon from the $\Sigma^0\rightarrow \gamma\Lambda$ decay. A high statistics data set using a deuterium target was taken this year, and analyses is ongoing~\cite{katrin}. \section{OPPORTUNIITES TO STUDY THE YN INTERACTION AND HYPERNUCLEI} Hypernuclei, where baryons of non-zero strangeness are bound to a nucleus, provide a natural laboratory to probe hyperon-nucleon (YN) interactions. YN or YY (or three body YNN, YYN) interactions are very poorly constrained compared to NN interactions. Studying these is vital in order to develop an SU(3)$_\mathrm{flavour}$ symmetric understanding of baryon interactions. Additionally, the description of many astrophysical phenomena depend strongly on YN interactions, for example, the \textit{Hyperon Puzzle} in describing the equation of state of neutron stars (see for example, Ref. \cite{gal16} and references therein). The BGO-OD experiment, using a real photon beam, may be able to make complementary measurements to existing hypernuclei facilities. The energy resolution of the incident photon beam will not permit measurements of hypernuclei binding energies, however the high momentum resolution of $K^+$ at forward angles, and a calorimeter to identify both charged and neutral decay particles provide unique opportunities. From simple kinematics, the BGO-OD is ideal: an incident photon beam between 1400 to 1600 MeV, and a $K^+$ produced at a polar angle smaller than 10$^0$ provides a recoil momentum to a $\Lambda$ of the order of 300 - 350 MeV/c, which would be sufficient for some to remain within the Fermi surface and bind to the residual nucleus. Figure~\ref{fig:coherentpion} demonstrates a ``non-strange'' example, where coherent $\pi^0$ photoproduction was observed off a carbon target. Figure~\ref{fig:coherentpion}(a) shows the calculated $\pi^0$ energy from the polar angle and beam energy, with the measured energy subtracted. The peak at zero for forward $\pi^0$ indicates coherent production. For further verification, the 4.4~MeV decay photon from the full reaction: \newline$\gamma + ^{12}C \rightarrow \pi^0 + ^{12}C^* \rightarrow \pi^0 + ^{12}C + \gamma'$ was identified (shown in fig.~\ref{fig:coherentpion}(b)). This decay corresponds to a pure E2 transition, $J^\pi: 2^+\rightarrow 0^+$, with a $\sin^2(2\alpha)$ distribution where $\alpha$ is the angle between the recoiling nucleus and decay gamma. Figure~\ref{fig:coherentpion}(c) shows this angular distribution with a $\sin^2(2\alpha)$ fit. There is good agreement when accounting that the data is not efficiency corrected. \begin{figure}[h] \preliminary{\includegraphics[clip,width=\linewidth]{CoherentPion-eps-converted-to.pdf}} \caption{Identification of coherent $\pi^0$ photoproduction off carbon, as a demonstration of potential future opportunities in hypernuclei research. (a) Difference between calculated and measured $\pi^0$ energy with a beam energy of 297~MeV for all angles and at polar angles smaller than 40$^0$. A peak at zero indicates coherent events. (b) Identification of the 4.4~MeV decay $\gamma$ from an excited carbon nuclei. An approximate fit of a exponential to background and Gaussian function to signal yields the mean and sigma inset. (c) Angular decay distribution of the decay $\gamma$ with a $\sin^2(2\alpha)$ fit (see text for details). }\label{fig:coherentpion} \end{figure}\newpage These techniques are a first step in demonstrating that hypernuclei research may be feasible. BGO-OD may provide opportunites in measuring angular distributions of hypernuclei photoproduction~\cite{mainz}, which has some theoretical support~\cite{petrtalk}, however it is not clear how useful the data are without a separation of different states. There may also be opportunities to use targets which are spoiled by intense electron beams, or to measure hypernuclei lifetimes with the development, for example, of an active target~\cite{mainz}. \bibliographystyle{aipnum-cp}%
\section*{Introduction} \red{Coherent perfect absorption (CPA) is the complete extinction of incoming radiation by a complex potential embedded in a physical system supporting wave propagation. The phenomenon is based on destructive interference of transmitted and reflected waves.} The concept was introduced~\cite{StonePRL} and observed experimentally~\cite{StoneScience} for light interacting with absorbing scatterers. CPA was also reported on for plasmonic metasurfaces~\cite{meta}, graphene films~\cite{graphene}, and sound waves~\cite{acoustCPA}. Technologically, CPA is used to design switching devices~\cite{switching}, logic elements~\cite{OptLogic}, in interferometry~\cite{StoneScience} and in many other applications~\cite{review}. \red{All these studies deal with perfect absorption of linear waves.} Here, we extend the paradigm to \red{a CPA of {\em nonlinear} waves} and experimentally demonstrate it for matter waves with an atomic Bose-Einstein condensate (BEC). Conditions for CPA of matter waves can be satisfied easier than for its linear analogs because the strength of two-body interactions offers additional freedom for control. The observation of CPA of nonlinear matter waves paves the way towards a much broader exploitation of the phenomenon in nonlinear optics, exciton-polariton condensates, acoustics, and other areas of nonlinear physics. CPA is a delicate phenomenon requiring precise tuning of the absorber and of the relative phases of the incoming waves. When the respective conditions are met for a particular wave vector, the radiation incident from both sides is completely absorbed (Fig.~\ref{fig:working_principle}A). CPA can be viewed as a time reversed process to lasing~\cite{StonePRL,StoneScience} where the absorber is replaced by a gain medium and only outgoing radiation exists for a given wave vector. This time-reversed process is related to the mathematical notion of a spectral singularity~\cite{Neimark}, i.e. to a wave vector at which the system can emit radiation with none incoming~\cite{Mostafazadeh2009,Laser1}. Therefore, in the scattering formalism, the wavelength at which CPA occurs is called a time-reversed spectral singularity. \begin{figure} \centering \includegraphics[width=0.8\columnwidth]{Figure1_Working_principle.pdf}% \caption{ Working principle of coherent perfect absorption (A) Incident radiation enters an absorber from two sides with a wavevector $q_\star$. Provided the complex amplitudes $a^L$ and $b^R$ are chosen properly, no radiation is transmitted or reflected. (B) Experimental realization with a BEC in an optical lattice. The matter waves enter a lossy lattice site from both sides. The losses are realized with an electron beam, which removes the atoms. Due to the interactions between the atoms, the two incoming waves are nonlinear, \red{while the absorption in the lossy site is linear.} }% \label{fig:working_principle} \end{figure} Recently, the concept of {\it nonlinear} CPA was introduced \red{in optics}~\cite{Mostafa2013,Gupta2013,Mostafa2014,Achilleos2016}. \red{ Such a device represents a nonlinear absorbing slab, sometimes with nontrivial composite internal structure~\cite{Gupta2014,Argyr}, which is embedded in a linear medium and thus perfectly absorbs incident linear waves.} Since, however, the propagating medium can itself be nonlinear, as it is the case for an optical Kerr nonlinearity or an interacting BEC, the natural (and still open) question arises about the physical meaning of CPA in a {\em nonlinear medium}. In other words, what are the scattering properties of nonlinear waves interacting with a linear absorbing potential? The implementation of CPA in a nonlinear medium offers several challenges which raise doubts about whether such a phenomenon can exist and whether it is physically meaningful. Indeed, in such a setting the ``linear'' arguments do not work: there is no well defined transfer matrix connecting left- and right- incident waves (problems, where either the incident or transmitted radiation is given, have different solutions~\cite{DevSouil}); because of interactions among the modes there exists no interference in the linear sense, and results on scattering of monochromatic waves do not give any more an answer on the scattering of wave packets used in experiments. Moreover, even if CPA can exist in a nonlinear medium, its realization is still questionable. There exists no general method of computing the system parameters, like the zeros of the transfer matrix elements in the linear case. Thus, tuning system parameters {\em in situ} might be the only possibility to realize CPA in nonlinear media. Furthermore, even the realization of plane waves may be practically impossible due to instabilities ubiquitous for nonlinear systems. Here, we show that all the above challenges can be overcome: CPA for nonlinear waves does exist, can be observed experimentally, and even can be more easily achieved due to the intrinsic nonlinearity. Theoretical indication for such CPA stems from the existence of stable constant-amplitude currents in a nonlinear waveguiding circle with equal absorbing and lasing potential ~\cite{ZK}. Experimental indication comes from recent experiments on driven dissipative Josephson systems~\cite{Labouvie16}. \section*{Results} In this work, we consider \red{an atomic Bose-Einstein condensate (BEC) residing in a periodic potential, realized by an optical lattice. The superfluid nature of the Bose-Einstein condensate allows for tunneling between the wells, while interatomic collisions lead to an intrinsic nonlinearity.} One of the wells is rendered \red{absorptive} by applying an electron beam~\cite{Ott}, which removes atoms \red{from that well}. \red{The effective experimental system is sketched in Fig.~\ref{fig:working_principle}B: a well with linear absorption, embedded between two tunneling barriers, is coupled at both ends to a nonlinear waveguide.} \red{For an introduction to the experimental techniques for manipulating ultracold atoms in optical potentials, the reader is referred to Ref.\,\cite{Weidemuller}. Experimental details of the optical lattice, the preparation of the BEC and the experimental sequence are given in the Supplementary material.} The depth of the periodic potential and number of atoms $N$ in each lattice site ($N\approx 700$) \red{are chosen such that we can apply} the tight-binding approximation of mean-field dynamics, when the condensate is described in terms of the density amplitudes $\psi_n(t)$~\cite{TrombSmerzi,AKKS}: \begin{eqnarray} \label{DNLS} i\hbar\frac{d\psi_n}{dt}=-J\left(\psi_{n-1}+\psi_{n+1}\right)+U|\psi_n|^2\psi_n-i\frac{\hbar\gamma}{2}\psi_n \delta_{n0}. \end{eqnarray} Here, $n$ enumerates the lattice sites and $\gamma\geq 0$ describes the dissipation strength applied to the site $n=0$. Theoretically, such a system was first considered in~\cite{BKPO} within the framework of the Gross-Pitaevskii equation. Later on, it was treated within the Bose-Hubbard model~\cite{Barmettler2011,Witthaut2011}. Current states in BECs in the presence of dissipation and external drive were also studied theoretically in \cite{ZKBO,ZK} and experimentally in \cite{Barontini2013,Eckel2014,Labouvie16}. Since CPA is a stationary process, we look for steady-state solutions of (\ref{DNLS}) in the form $\psi_n(t)=e^{-i(\mu/\hbar) t}u_n$, where all $u_n$ are time independent and $\mu$ is the chemical potential. First, we revisit the linear case corresponding to non-interacting atoms: $\tilde{\mu} \tilde{u}_n=-J\left(\tilde{u}_{n-1}+\tilde{u}_{n+1}\right)-i(\hbar \gamma/2)\tilde{u}_n \delta_{n0}$, where in order to emphasize the limit $U=0$ we use tildes. In the absence of dissipation, i.e., at $\gamma=0$, the dispersion relation in the tight-binding approximation reads $\tilde{\mu}=-2J\cos q$, where $q\in [0,\pi]$ is the wavenumber. When dissipation is applied at $n=0$, we consider the left $\tilde{u}_n^L=a^Le^{iqn}+b^Le^{-iqn}$ for $n\leq -1$ and right $\tilde{u}_n^R=a^Re^{iqn}+b^Re^{-iqn}$ for $n\geq 1$ solutions, where $a^{L}$ and $b^{R}$ ($a^{R}$ and $b^{L}$) are the incident (reflected) waves from left ($L$) and right ($R$), respectively (see Fig.~\ref{fig:working_principle}). The transfer $2\times2$ matrix ${\bf M}$ with the elements $M_{ij}(q)$, is defined by the relation $(a^R,b^R)^T={\bf M}\,(a^L,b^L)^T$, where $T$ stands for transpose. Computing ${\bf M}$ (see Methods), one verifies that for $q=q_\star$ and $q=q_\star^1=\pi-q_\star$ where \begin{eqnarray} \label{q_star} q_\star=\arcsin\left(\frac{\hbar\gamma}{4J}\right), \end{eqnarray} the element $M_{11}$ vanishes: $M_{11}(q_\star)=0$, while the other elements become $M_{21}(q_\star)=-M_{12}(q_\star)=1$ and $M_{22}(q_\star)=2$. At these wavenumbers the problem admits a solution consisting of only incident waves, i.e. $a^L=b^R$ and $b^L=a^R=0$. Thus, two CPA-states occur for slow ($q=q_\star$) and fast ($q=q_\star^1$) matter waves. The points $q_\star$ and $q_\star^1$ are called {\em time-reversed spectral singularities}. If instead of eliminating, one coherently injects atoms into the site $n=0$, i.e. $\gamma<0$, model (\ref{DNLS}) admits {\em spectral singularities} $\bar{q}_\star=-q_\star$ and $\bar{q}_\star^1=-q_\star^1$ at which $M_{22}(\bar{q}_\star)=0$ while the other elements become $M_{12}(\bar{q}_\star)=-M_{21}(\bar{q}_\star)=1$ and $M_{11}(\bar{q}_\star)=2$. Now, the solution $a^R=b^L$ and $a^L=b^R=0$ describes coherent wave propagation outside the ``active'' site, corresponding to a matter-wave laser. Since the change $\gamma\to-\gamma$ in Eq.~(\ref{DNLS}) is achieved by applying the Wigner time reversal operator $\mathcal{T}$: $\mathcal{T}\Psi({\bf r},t)=\Psi^*({\bf r},-t)$, a coherent perfect absorber corresponds to a time-reversed laser~\cite{StonePRL}. The CPA solutions of model (\ref{DNLS}) for linear waves have the following properties: It exists only for dissipation rates with $\gamma\leq\gamma_{\rm th}=4 J/\hbar$. The amplitude of the absorbed waves is constant in all sites, including the site where atoms are eliminated, and the group velocity at $q_\star$ is directly set by the decay rate: $v_{\rm g}(q_\star)=d\tilde{\mu}/dq|_{q_\star}=2J\sin q_\star=\hbar \gamma/2$. Bearing these properties in mind, we now turn to the nonlinear problem, setting $U>0$ (repulsive interactions among the atoms). We search for a steady-state solution of (\ref{DNLS}) with a constant amplitude $\rho$ in each lattice site. The requirement for the existence of only left- and right- incident waves can be formulated as $u_n^L=\rho e^{iqn}$ for $n\leq -1$, $u_n^R=\rho e^{-iqn}$ for $n\geq 1$, and $u_0=\rho$. {This fixes $\mu=-2J\cos q+U\rho^2$,} and the matching conditions at $n=0$ imply that the steady-state solution exists only if $q=q_\star$ (and $q=q_\star^1$) given by (\ref{q_star}). Thus, we have obtained {\it CPA for nonlinear matter waves}, which still corresponds to the time-reversed laser. In addition, as in the linear case, replacing the dissipation with gain (i.e., inverting the sign of $\gamma$), one obtains the constant amplitude outgoing-wave solution: $u_n^L=\rho e^{-iq_\star n}$ for $n \leq -1$, $u_n^R=\rho e^{iq_\star n}$ for $n\geq 1$. One essential difference between linear and nonlinear CPA is particularly relevant for the experimental observation of the phenomenon: the stability of the incoming superfluid currents. The stability analysis (see Methods) shows that the nonlinearity qualitatively changes the result: only slow currents ($q=q_\star$) can be perfectly absorbed, while the fast nonlinear currents ($q=q_\star^1$) are dynamically unstable. \begin{figure \includegraphics[width=\columnwidth]{figure2.pdf} \caption{Coherent perfect absorption in a Bose-Einstein condensate residing in an optical lattice. At $t=0$, the elimination of atoms from the lattice site $n=0$ starts. (A), (A) Time evolution of the lattice filling in the CPA regime ($\gamma\approx125\,$s$^{-1}$, (A)) and above the breaking point ($\gamma\approx1000\,$s$^{-1}$, (A)). Experimental data are shown as red points, the numerical simulations are shown in blue. For clarity, we only show the first ten sites on one side of the system. In (A), the density remains uniform across the lattice, which is the signature of CPA. In (B), the density at the dissipative site drops off rapidly, and no CPA can be observed. (C),(D) Corresponding images of the atomic distribution in the lattice after the sequence. (E) Integrated atomic density of (C) and (D). (F) Unwrapped radian argument $\arg\psi_n$ at $t=40$ms for the solution shown in (A) [green curve] and (B) [blue curve]. For all panels, we have $U/\hbar=2600$\,$s^{-1}$, $J/\hbar=229$\,$s^{-1}$. The error bars in (A) and (B) indicate the statistical error, resulting from the summation over 50 experimental runs.} \label{fig:num} \end{figure} The CPA solution is mathematically valid only in the infinite lattice, because the absorption at the center must be compensated by steady particle fluxes incoming from infinity. However, the CPA phenomenon is structurally robust and can be observed as a quasi-stationary regime even in a finite lattice. To demonstrate this, we simulated numerically Eq.~(\ref{DNLS}) with about 200 sites. The initial condition corresponds to the ground state of a BEC with an additional small harmonic confinement along the lattice direction. Figures~\ref{fig:num}A and~\ref{fig:num}B show the obtained behavior for dissipation strengths $\gamma$ below (a) and above (b) the CPA-breaking point $\gamma_{\rm th}$. Fig.~\ref{fig:num}A shows that the solution rapidly enters a quasi-stationary regime where its density remains constant in space and is only weakly decaying in time due to an overall loss of atoms in the system. Above the breaking value (Fig.~\ref{fig:num}B), a strong decay sets in and the atomic density is not homogeneous in space any more. An important feature of CPA is the balanced superfluid currents towards the dissipative site, characterized by the distribution of phases, illustrated in Fig.~\ref{fig:num}C. The CPA regime manifests itself in the $\Lambda$-shaped phase profile whose slope is $q_\star$ for negative $n$ and $-q_\star$ for positive $n$. This phase pattern is completely different when the system is not in the CPA regime: it is nearly constant, showing weak nonmonotonic behavior for positive and negative $n$, with a large jump at the central site. Together with the numerical simulation, we also show in Fig.~\ref{fig:num}A the corresponding experimental results. The experimentally measured filling level of the dissipative site shows very good agreement with the numerical simulations: the atom number in the dissipated site is constant in time and equal to all neighboring sites. This steady state is the experimental manifestation of CPA of matter waves. The CPA solution is established also for other values of the dissipation strength. This highlights the fact that the nonlinearity together with the dissipation generates an effective attractor dynamics towards the CPA solution. Increasing the dissipation above a critical value leads to a qualitative change in the behaviour (Fig.~\ref{fig:num}B). In accordance with the theoretical prediction, the occupation in the dissipated site rapidly drops and stays small. Hence, CPA can indeed only be observed in a finite parameter window. The theoretical results predict the transition from CPA and the non-CPA regime at $\gamma_c=4J/\hbar$, above which no quasi steady-state is established anymore. In the experiment, a qualitatively similar situation occurs (Fig.~3). However the CPA regime breaks down at a lower dissipation rate of $\gamma_{\mathrm exp}\approx J/\hbar$. This can be explained by two factors. First, the transverse extension of each lattice site, not fully accounted for by the tight-binding approximation (\ref{DNLS}), makes the condensate vulnerable against transverse instabilities~\cite{Herring} which can develop at smaller $\gamma$ than predicted by (\ref{DNLS}). The second factor is related to the way the experiment is conducted. At $t=0$ the condensate is loaded in a lattice and is characterized by the chemical potential, which is determined by the trap geometry and by the filling of each lattice site. When the elimination of atoms starts, the system is induced in an unstable regime. Quasi-stationary behaviour is only possible if the chemical potential is not changed appreciably under the action of the dissipation. This requires the filling of the central site due to tunneling from the neigbouring ones to be fast enough to compensate the loss of atoms. Thus the tunneling time estimated as $\tau_{\rm tun}\sim \hbar/J$ should be of the order of or smaller than the inverse loss rate $\gamma^{-1}$, otherwise the induced thermodynamical equilibrium at $t=0$ cannot be compensated by the incoming superfluid currents and the collective dynamics described by Eq.~(\ref{DNLS}) cannot be established. This gives an estimate $\gamma\sim J/\hbar$ for the threshold dissipation rate. \begin{figure} \centering \includegraphics[width=0.6\columnwidth]{figure3.pdf}% \caption{Experimentally measured decay rate of the filling level. Up to a critical dissipation strength $\gamma_{exp}\approx$250\,s$^{-1}$ (black dashed line), the filling level remains constant (compare Fig.~2A), corresponding to the CPA regime. Above this value, the dissipation dominates the dynamics and the filling level decays exponentially (compare Fig.~2B). The statistical error of the decay rate is smaller than the size of the points, however, we estimate a $5\%$ systematic error due to technical imperfections like drifts of the electron beam current. The error in the dissipation rate originates from the calibration measurement (see Supplementary Materials).} \label{fig:CPA_transition} \end{figure} \section*{Conclusion} Our results present the Proof-of-Concept of the CPA paradigm \red{nonlinear waves. The experimental setting explored here} can be straightforwardly generalized to BECs of other types like spin-orbit coupled, fermionic, and quasi-particle ones, and furthermore to other branches of physics, including nonlinear optics of Kerr media and acoustics. Our system can also be exploited as a platform for studying \red{superfluid flows in a linear geometry (which is aletrnative to most commonly used annular traps), as well as for understanding} the fundamental role of Bogoliubov phonons in stabilizing quantum states. \red{Since CPA can be viewed as time-reversed lasing, the reported experimental results pave the way to implementing a laser for matter waves, for which elimination of atoms from the central site should be replaced by loading atoms. Furthermore, the observation of CPA in nonlinear media, and possible lasing of matter waves, can be viewed as an additional element for rapidly developing area of quantum technologies based on atomtronics~\cite{atomtronics}. The reported results also open a possibility of using CPA regimes in nonlinear optical circuits.} In the general context of scattering by dissipative potential~\cite{Muga}, given the fact, that the atomic interactions can be tuned by a Feshbach resonance, a linear spectral singularity can be experimentally realized by starting from the nonlinear case and subsequently reducing the interactions to zero adiabatically. Such a scenario explicitly exploits the attractor nature of the CPA solution. \red Being an attractor in essentially nonlinear system, CPA can serve as a mechanism to control parameters of superfluid flow parameters, such as the chemical potential, superfluid velocity, or sound velocity, in a particularly simple way.} \section*{Materials and Methods} \subsection*{The transfer matrix} To compute the transfer matrix ${\bf M}$, we denote the solution in the point $n=0$ by $u_0$ and consider the equation \begin{eqnarray} \tilde{\mu} \tilde{u}_n=-J\left(\tilde{u}_{n-1}+\tilde{u}_{n+1}\right)-i\frac{\hbar \gamma}{2}\tilde{u}_n \delta_{n0}, \end{eqnarray} describing stationary currents, in the points $n=0$ and $n=\pm 1$ using the explicit forms for the waves in the left $\tilde{u}_n^L=a^Le^{iqn}+b^Le^{-iqn}$ ($n\leq -1$) and the right $\tilde{u}_n^R=a^Re^{iqn}+b^Re^{-iqn}$ ($n\geq 1$) half-space. From the equation with $n=0$ and using the expression for the chemical potential $\tilde{\mu}=-2J\cos q$, we obtain $u_0$: \begin{eqnarray} u_0=\frac{2J}{4J\cos q-i\hbar\gamma}\left(a^Le^{-iq}+b^Le^{iq}+a^Re^{iq}+b^Re^{-iq}\right). \end{eqnarray} With this expression, the equations at $n=\pm1$ are transformed to a linear algebraic system, which is solved for the pair $(a^R,b^R)$, giving their expressions through $(a^L,b^L)$, thus determining the transfer matrix: \begin{equation} M_{11} = \frac{4J\sin q - \hbar\gamma}{4J\sin q}, \quad M_{12} = - \frac{ \hbar\gamma}{4J\sin q}, \quad M_{21} = \frac{ \hbar\gamma}{4J\sin q}, \quad M_{22} = \frac{4J\sin q + \hbar\gamma}{4J\sin q}. \end{equation} \subsection*{Stability analysis} We analyze the stability for a BEC within the framework of the discrete model \begin{eqnarray} \label{DNLS_SM} i\hbar\frac{d\psi_n}{dt}=-J\left(\psi_{n-1}+\psi_{n+1}\right)+U|\psi_n|^2\psi_n-i\frac{\hbar\gamma}{2}\psi_n \delta_{n0}, \end{eqnarray} and require that the left and right incident superfluid currents have to be stable. Their stability is determined by the stability of the corresponding Bogoliubov phonons on an infinite homogeneous lattice (i.e., without applied removal of atoms). The stability of the homogeneous lattice is found using the substitution \begin{eqnarray} \label{Bogoliubov1} \psi_n(t)=e^{-i(\mu/\hbar) t+i qn}\left(\rho+v_n e^{-i\omega t+ikn}+w_n^{*}e^{i\omega^* t-ikn}\right), \end{eqnarray} where $\rho>0$ characterizes the uniform density, and $|v_n|\,, |w_n|\ll \rho$ are small perturbations. Linearizing Eq.~(\ref{DNLS_SM}) (with $\gamma=0$) with respect to $v_n$ and $w_n$, we find two dispersion branches: \begin{eqnarray} \hbar \omega_\pm (q,k)=2J\sin(k)\sin(q)\pm 2\sin\left(\frac{k}{2}\right) \sqrt{2J\cos(q) \left[U\rho^2+2J\cos(q)\sin^2\left(\frac{k}{2}\right)\right]}. \end{eqnarray} Consider now a positive scattering length, $U>0$, which corresponds to the experiments reported here. One can then identify the stability domain for Bogoliubov phonons, and hence the stability of the superfluid current, requiring $\omega_\pm$ to be real for the given $q$ and all real $k$. This results in the constraint $0\leq q<\pi/2$, i.e. only slow currents are dynamically stable. \subsection*{Experimental setup} We use a Bose-Einstein condensate (BEC) of $^{87}$Rb with about $45\times10^3$ atoms in a single beam dipole trap realized by a CO$_2$-laser \red{(maximum power $10\,$W, beam waist $30\,\mu$m}). \red{The condensate is cigar-shaped and has dimensions of $80\,\mu$m $\times$ $6\,\mu$m $\times$ $6\,\mu$m.} We then load the BEC into a one-dimensional optical lattice created by two blue detuned laser beams ($\lambda=774\,$nm, \red{beam waist $500\,\mu$m}) crossed at an angle of $90{^\circ}$. \red{The linear polarization of both laser beams is along the same direction, such that the interference pattern is maximally modulated}. The resulting lattice has a period of $d=547\,$nm. The trap-frequencies in a lattice site are $\nu_r=165\,$Hz (transverse direction) and $\nu_{z}=12\,$kHz (lattice direction). Each site contains a small, pancake-shaped BEC with about 700 atoms (value in the center of the trap). The total number of lattice sites is about 200. The lattice depth $V_0$ in units of the recoil energy $E_r=\pi^2\hbar^2/(2md^2)$ ($m$ is the mass of the atom) is given by $V_0=10E_r$. \red{An electron column, which is implemented in our experimental chamber, provides a} focused electron beam, which is used to introduce a well-defined local particle loss as a dissipative process in one site of the lattice. In order to ensure a homogeneous loss process over the whole extension of the lattice site, we rapidly scan the electron beam in the transverse direction (3\,kHz scan frequency) with a sawtooth pattern. To adjust the dissipation strength $\gamma$, we vary the amplitude of the scan pattern. \red{An image of the experimental chamber together with a sketch of the optical trapping configuration is provided in the Supplementary Material (S1).} \subsection*{Why the lattice is necessary} As it is mentioned in the main text the superfluid currents under localized dissipation were studied previously in inhomogeneous BECs~\textit{(22,25)}, where no CPA was observed. Mathematical solutions of the Gross-Pitaevskii equation with localized dissipation describing such models can however be found. Such solutions are stable and have stationary amplitudes. Indeed, consider the stationary Gross-Pitaevskii equation with strongly localized dissipation modeled by the Dirac delta-function $\gamma_0\delta(x)$, where $\gamma_0$ is a positive constant, without any optical lattice \begin{eqnarray} \label{eq:cont} \mu\psi=-\psi_{xx}-i\gamma_0\delta(x)\psi+g|\psi|^2\psi. \end{eqnarray} Here $g>0$. One can verify, that the function \begin{equation} \label{eq:contCPA} \psi =\rho_0 e^{-i\gamma_0 x {\rm sign}(x) /2}, \end{equation} is a solution of Eq.~(\ref{eq:cont}) with the chemical potential $\mu = g\rho_0^2 + \gamma_0^2/4$. This raises questions about the role of the optical lattice and about its necessity for realizing CPA experimentally. The answer resides in the way of exciting the CPA regime. A strictly homogeneous background density can only exist if the dissipation is point-like (described by the Dirac delta-function $\delta$) and thus experimentally unrealistic. Any finite size, even very narrow, dissipation generates Bogoliubov phonons at the instant it is applied. In the continuous model, the phonons can propagate with arbitrary group velocity, contrary to the lattice described in the tight-binding model. Switching on dissipation therefore induces an extended domain of the condensate in a dynamical regime, and fast matter waves propagating outwards the dissipation domain cannot be stabilized by the incoming flows. Thus, the lattice, on the one hand creates conditions where the dissipation is effectively point-like (i.e. applied to a single cell) and on the other hand limits the group velocity of the phonons, allowing for establishing the equilibrium state. \subsection*{Details of numerical simulations} In the numerical simulations, we used the following model which corresponds to the Gross-Pitaevskii equation from the main text with an additional weak parabolic confinement $\alpha n^2\psi_n$ which models the optical dipole trap potential used in the experimental setup: \begin{equation} \label{eq:GPEn2} i\hbar \frac{d\psi_n}{dt}= - J (\psi_{n-1} + \psi_{n+1}) + U|\psi_n|^2 \psi_n - \frac{i\gamma\hbar}{2}\delta_{n0}\psi_n + \alpha n^2\psi_n. \end{equation} The coefficient $\alpha$ determines the strength of the parabolic trapping and amounts to \begin{equation} \alpha = \frac{m\omega^2 d^2}{2\hbar } = 0.98~\mbox{s}^{-1}, \end{equation} where $m=1.44 \cdot 10^{-25}$~g is the mass of the atom, $d=547$~nm is the lattice period, and $\omega=2\pi \cdot 11$~Hz is the axial trapping frequency of the dipole trap. As in the main text, for other parameters we have $J/\hbar = 229~\mbox{s}^{-1}$ and $ U/\hbar =2600~\mbox{s}^{-1}$. To convert the equation (\ref{eq:GPEn2}) in the form suitable for numerical calculations, we divide each term by $J$ and introduce the ``new time'' $\tau = (J/\hbar) t$ which transforms (\ref{eq:GPEn2}) to \begin{equation} \label{eq:numerical} i\frac{d\psi_n}{d\tau}= - (\psi_{n-1} + \psi_{n+1}) + \tilde{U} |\psi_n|^2 \psi_n - \frac{i\tilde{\gamma}}{2}\delta_{n0}\psi_n + \tilde{\alpha} n^2\psi_n, \end{equation} where $\tilde{U} =U/J\approx 11,$ $\tilde{\alpha} =\alpha/ J\approx 0.004$, and $\tilde{\gamma} = \gamma \hbar / J$. For $\tilde{\gamma}=0$, Eq.~(\ref{eq:numerical}) has an approximate stationary ground-state Thomas-Fermi solution \begin{eqnarray} \label{eq:TF} \psi_n = e^{-i( \tilde{U}\rho^2-2) t} w_n, \qquad w_n=\left\{\begin{array}{ll} \sqrt{\rho^2 - \tilde{\alpha} n^2/\tilde{U}}, & |n|<N_{TF}\\ 0,& |n|>N_{TF}. \end{array} \right. \end{eqnarray} where the ``discrete Thomas-Fermi radius'' $N_{TF}$ is determined by the condition $\tilde{U}\rho^2 - \tilde{\alpha} N_{TF}^2= 0$, and $\rho^2=1$ is the normalized background density, i.e., $|w_n|^2\approx 1$ in the central region. In our case $N_{TF} \approx 50$. We solve equation (\ref{eq:numerical}) for $\psi_n(\tau)$ on the grid of 201 sites $n=-100, \ldots, 100$, where $n=0$ corresponds to the site with the losses, and subject to the zero boundary conditions $\psi_{-100}(\tau) =\psi_{100}(\tau)=0$. For the initial condition, we used the ground state Thomas-Fermi distribution from (\ref{eq:TF}): $\psi_n(t=0)=w_n$. As discussed in the main text, in the parametric range corresponding to the existence of the CPA, the initial condition rapidly evolves to the quasi-stationary CPA solution characterized by the almost uniform density in the central region ($n=-10,\ldots,10$), whereas in the absence of the CPA-regime the initial condition rapidly develops strong instability in the central region.
\section{Introduction}\label{sec_intro} The prescribed Ricci curvature problem is an important area of research in geometric analysis with close ties to flows and relativity. The first detailed results in this area were obtained in the early 1980s by D.~DeTurck. We invite the reader to see~\cite{RPLAMP15,APadd,ED17b} and references therein for some recent advances and a historical overview. The present paper discusses the prescribed Ricci curvature problem in the framework of homogeneous spaces. More precisely, consider a compact connected Lie group $G$ and a closed connected Lie subgroup $H<G$. Denote by $M$ the homogeneous space~$G/H$. Suppose the dimension of $M$ is at least~3 and $\mathcal M$ is the set of $G$-invariant Riemannian metrics on~$M$. Let $S$ be the scalar curvature functional on~$\mathcal M$. The prescribed Ricci curvature problem for $G$-invariant metrics on $M$ consists in finding $g\in\mathcal M$ that satisfy the equation \begin{align}\label{eq_PRC} \mathop{\mathrm{Ric}}\nolimits g=cT, \end{align} for some $c>0$, where $T$ is a given $G$-invariant $(0,2)$-tensor field. The study of~\eqref{eq_PRC} in the framework of homogeneous spaces was initiated in~\cite{AP16} and continued in~\cite{MGAP17}; see also~\cite{RH84,EDMH01,TB16}. It is on the basis of~\cite{AP16} that the first results about the Ricci iteration in the non-K\"ahler setting were obtained in~\cite{APYRsubm}. These results provided a new approach to uniformisation on homogeneous spaces. Moreover, they led to the discovery of several dynamical properties of the Ricci curvature. Assume the $(0,2)$-tensor field $T$ lies in~$\mathcal M$. As~\cite[Lemma~2.1]{AP16} demonstrates, a metric $g\in\mathcal M$ satisfies~\eqref{eq_PRC} for some $c\in\mathbb R$ if and only if it is (up to scaling) a critical point of the functional $S$ on \begin{align*} \mathcal M_T=\{h\in\mathcal M\,|\,\tr_hT=1\}. \end{align*} This parallels the well-known variational interpretation of the Eisntein equation. Indeed, a metric $g\in\mathcal M$ satisfies \begin{align*} \mathop{\mathrm{Ric}}\nolimits g=\lambda g \end{align*} for some $\lambda\in\mathbb R$ if and only it is (up to scaling) a critical point of $S$ on \begin{align*} \mathcal M_1=\{h\in\mathcal M\,|\,M~\mbox{has volume 1 with respect to}~h\}; \end{align*} see, e.g.,~\cite[\S1]{MWWZ86}. However, the restrictions of $S$ to $\mathcal M_T$ and $\mathcal M_1$ have substantially different properties. We will elaborate on this after we provide an overview of our main results. According to~\cite[Theorem~1.1]{AP16}, if $H$ is a maximal connected Lie subgroup of~$G$, the functional $S$ attains its greatest value on~$\mathcal M_T$ at some $g\in\mathcal M_T$. It is easy to show that this $g$ satisfies~\eqref{eq_PRC} with $c>0$. In the present paper, we focus on the situation where the maximality assumption on $H$ does not hold. As~\cite[Proposition~3.1]{AP16} shows, in this situation, $S$ may fail to have a critical point on~$\mathcal M_T$. The work~\cite{MGAP17} provides a sufficient condition for $S$ to attain its greatest value on~$\mathcal M_T$. However, the usability of this result is restricted by two main factors. First, the class of homogeneous spaces on which it applies, while broad, is far from exhaustive. All the examples known to date have isotropy representations that split into \emph{pairwise inequivalent} irreducible summands. Second, the arguments in~\cite{MGAP17} impose rather strong requirements on~$T$. In Section~\ref{sec_gen_results} of the present paper, we obtain a new sufficient condition for $S$ to attain its greatest value on~$\mathcal M_T$. We state this result as Theorem~\ref{thm_gen}. While it is similar in spirit to the sufficient condition given in~\cite{MGAP17}, it applies on a substantially larger class of homogeneous spaces. For instance, it can be used to analyse~\eqref{eq_PRC} on $Sp(n+1)/Sp(n)$ for $n\in\mathbb N$; see Remark~\ref{rem_spheres}. Topologically, this space is a $(4n+3)$-dimensional sphere. Its isotropy representation splits into four irreducible summands, three of which are equivalent to each other. The requirements imposed on $T$ by Theorem~\ref{thm_gen} are different from the ones imposed by the sufficient condition of~\cite{MGAP17}. They appear to be substantially lighter in most situations. We illustrate this by considering two examples; see Remarks~\ref{rem_compar1} and~\ref{rem_compar2} below. Section~\ref{sec_Wallach} discusses the prescribed Ricci curvature problem on generalised Wallach spaces with inequivalent isotropy summands. A complete classification of such spaces is given in~\cite{ZCYKKL16,YN16}. They possess a number of interesting properties, and their geometry has been studied by several authors; see, e.g.,~\cite{AANS15,NAYN16,ZCYKKL16,AAYW17}. There are several infinite families and 10 isolated examples, excluding products, constructed out of exceptional Lie groups. In Section~\ref{sec_Wallach}, we show that Theorem~\ref{thm_gen} yields a sufficient condition for the existence of $g\in\mathcal M$ satisfying~\eqref{eq_PRC} for some $c>0$ in the case where $M$ is a generalised Wallach space with inequivalent isotropy summands. This condition is exceedingly easy to verify. Section~\ref{sec_flag} is devoted to the prescribed Ricci curvature problem on generalised flag manifolds with up to five irreducible summands in the isotropy representation. Such manifolds form an important class of homogeneous spaces with applications across a variety of fields. For detailed discussions of their geometric properties, see~\cite[Chapter~7]{AA03} and the survey~\cite{AA15}. According to the classifications given in~\cite{AAIC10,SAIC11,AAICYS13}, there are numerous infinite families and isolated examples. In Section~\ref{sec_flag}, we describe a method for verifying the assumptions of Theorem~\ref{thm_gen} on generalised flag manifolds with up to five irreducible summands in the isotropy representation. For clarity, we provide a detailed analysis of the cases where $M$ equals $G_2/U(2)$ (with $U(2)$ corresponding to the long root of $G_2$) and $F_4/SU(3)\times SU(2)\times U(1)$. The results of the present paper have no analogues in the theory of homogeneous Einstein metrics. Indeed, our main focus in on situations in which $S$ attains its greatest value on $\mathcal M_T$. However, as demonstrated by~\cite[Theorem~(2.4)]{MWWZ86} and~\cite[Theorem~1.2]{CB04}, the restriction of $S$ to the set $\mathcal M_1$ is typically unbounded above. \section{Preliminaries}\label{sec_prelim} As in Section~\ref{sec_intro}, consider a compact connected Lie group $G$ with Lie algebra $\mathfrak g$ and a closed connected subgroup $H<G$ with Lie algebra $\mathfrak h\subset\mathfrak g$. Let the homogeneous space $M=G/H$ be of dimension at least~3. Choose a scalar product $Q$ on $\mathfrak g$ induced by a bi-invariant Riemannian metric on $G$. In what follows, $\oplus$ stands for the $Q$-orthogonal sum. Clearly, \begin{align*} \mathfrak g=\mathfrak m\oplus\mathfrak h \end{align*} for some $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant space~$\mathfrak m$. The representation $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m}$ is equivalent to the isotropy representation of $G/H$. We standardly identify $\mathfrak m$ with the tangent space $T_HM$. \subsection{The structure constants}\label{subsec_str_const} Choose a $Q$-orthogonal $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant decomposition \begin{align}\label{m_decomp} \mathfrak m=\mathfrak m_1\oplus\cdots\oplus\mathfrak m_s \end{align} such that $\mathfrak m_i\ne\{0\}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_i}$ is irreducible for each $i=1,\ldots,s$. The space $\mathfrak m$ may admit more than one decomposition of this form. However, by Schur's lemma, the summands $\mathfrak m_1,\ldots,\mathfrak m_s$ are determined uniquely up to order if $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_i}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_j}$ are inequivalent whenever $i\ne j$. Let $d_i$ be the dimension of~$\mathfrak m_i$. It is easy to show that the number $s$ and the multiset $\{d_1,\ldots,d_s\}$ are independent of the chosen decomposition~\eqref{m_decomp}. Denote by $B$ the Killing form of $\mathfrak g$. For every $i=1,\ldots,s$, because $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_i}$ is irreducible, there exists $b_i\ge0$ such that \begin{align}\label{b_def} B|_{\mathfrak m_i} = -b_iQ|_{\mathfrak m_i}. \end{align} The numbers $b_1,\ldots,b_s$ will help us write down a convenient formula for the scalar curvature of a metric on~$M$. Given $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant subspaces $\mathfrak u_1$, $\mathfrak u_2$ and $\mathfrak u_3$ of $\mathfrak m$, define a tensor $\Delta(\mathfrak u_1,\mathfrak u_2,\mathfrak u_3)\in\mathfrak u_1\otimes\mathfrak u_2^*\otimes\mathfrak u_3^*$ by setting \begin{align*} \Delta(\mathfrak u_1,\mathfrak u_2,\mathfrak u_3)(X,Y)=\pi_{\mathfrak u_1}[X,Y],\qquad X\in\mathfrak u_2,~Y\in\mathfrak u_3, \end{align*} where $\pi_{\mathfrak u_1}$ stands for the $Q$-orthogonal projection onto~$\mathfrak u_1$. Let $\langle \mathfrak u_1\mathfrak u_2\mathfrak u_3\rangle$ be the squared norm of $\Delta(\mathfrak u_1,\mathfrak u_2,\mathfrak u_3)$ with respect to the scalar product on $\mathfrak u_1\otimes\mathfrak u_2^*\otimes\mathfrak u_3^*$ induced by $Q|_{\mathfrak u_1}$, $Q|_{\mathfrak u_2}$ and $Q|_{\mathfrak u_3}$. The fact that $Q$ comes from a bi-invariant metric on $G$ implies \begin{align}\label{permut} \langle\mathfrak u_1\mathfrak u_2\mathfrak u_3\rangle=\langle\mathfrak u_{\rho(1)}\mathfrak u_{\rho(2)}\mathfrak u_{\rho(3)}\rangle \end{align} for any permutation $\rho$ of the set $\{1,2,3\}$. Given $i,j,k\in\{1,\ldots,s\}$, denote \begin{align*} \langle\mathfrak m_i\mathfrak m_j\mathfrak m_k\rangle=[ijk]. \end{align*} The numbers $([ijk])_{i,j,k=1}^s$ are called the \emph{structure constants} of the homogeneous space $M$; cf.~\cite[\S1]{MWWZ86}. If $\mathcal J_{\mathfrak u_l}$ is a non-empty subset of $\{1,\ldots,s\}$ and $\mathfrak u_l$ equals $\bigoplus_{i\in \mathcal J_{\mathfrak u_l}}\mathfrak m_i$ for each $l=1,2,3$, then \begin{align}\label{<ijk>[ijk]} \langle\mathfrak u_1\mathfrak u_2\mathfrak u_3\rangle=\sum_{i\in\mathcal J_{\mathfrak u_1}}\sum_{j\in\mathcal J_{\mathfrak u_2}}\sum_{k\in\mathcal J_{\mathfrak u_3}}[ijk]. \end{align} \subsection{The scalar curvature functional and its extension}\label{subsec_sc_curv} As in Section~\ref{sec_intro}, let $\mathcal M$ be the space of all $G$-invariant Riemannian metrics on~$M$. This space has a natural smooth manifold structure; see, e.g.,~\cite[pages~6318--6319]{YNERVS07} and~\cite[Subsection~4.1]{CB04}. The scalar curvature $S(g)$ of a metric $g\in\mathcal M$ is constant on~$M$. Therefore, we may interpret $S(g)$ as the result of applying a functional $S:\mathcal M \to \mathbb R$ to~$g$. In what follows, we implicitly identify $g\in\mathcal M$ with the $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant scalar product induced by $g$ on $\mathfrak m$ via the identification of $T_HM$ and~$\mathfrak m$. To proceed, we need some notation. Namely, suppose $\mathfrak u$ and $\mathfrak v$ are subspaces of $\mathfrak m$ such that $\mathfrak v\subset\mathfrak u$. Let $\mathfrak u\ominus\mathfrak v$ be the $Q$-orthogonal complement of $\mathfrak v$ in~$\mathfrak u$. Consider bilinear forms $X$ and $Y$ on $\mathfrak u$ and $\mathfrak v$, respectively. Denote by $X|_\mathfrak v$ the restriction of $X$ to~$\mathfrak v$. If $X|_{\mathfrak v}$ is positive-definite, $\tr_XY$ stands for the trace of $Y$ with respect to~$X|_{\mathfrak v}$. The scalar curvature of $g\in\mathcal M$ is given by the equality \begin{align}\label{sc_curv_basf} S(g)=-\frac12\tr_gB|_{\mathfrak m}-\frac14 |\Delta(\mathfrak m,\mathfrak m,\mathfrak m)|_g^2, \end{align} where $|\cdot|_g$ is the norm induced by~$g$ on $\mathfrak m\otimes\mathfrak m^*\otimes\mathfrak m^*$. If the decomposition~\eqref{m_decomp} is such that \begin{align}\label{g_form} g=\sum_{i=1}^sx_i\pi_{\mathfrak m_i}^*Q \end{align} for some $x_1,\ldots,x_s>0$, then \begin{align}\label{sc_curv_formula} S(g)&=\frac12\sum_{i=1}^s\frac{d_ib_i}{x_i}-\frac14\sum_{i,j,k=1}^s[ijk]\frac{x_k}{x_ix_j}. \end{align} For the derivation of formulas~\eqref{sc_curv_basf} and~\eqref{sc_curv_formula}, see, e.g.,~\cite[Chapter~7]{AB87} and~\cite[Lemma~3.2]{APYRsubm}. Given $g\in\mathcal M$, it is always possible to choose~\eqref{m_decomp} in such a way that~\eqref{g_form} holds. For the proof of this fact, see~\cite[page~180]{MWWZ86}. Suppose $\mathfrak k$ is a Lie subalgebra of $\mathfrak g$ containing $\mathfrak h$ as a proper subset. It will be convenient for us to denote \begin{align}\label{def_funny_subsp} \mathfrak n=\mathfrak k\ominus\mathfrak h,\qquad \mathfrak l=\mathfrak g\ominus\mathfrak k. \end{align} Let $\mathcal M(\mathfrak k)$ be the space of $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant scalar products on $\mathfrak n$. In what follows, we assume $\mathcal M(\mathfrak k)$ is equipped with the topology inherited from the second tensor power of~$\mathfrak n^*$. Our further arguments require introducing an extension of the functional $S$ to~$\mathcal M(\mathfrak k)$. More precisely, define \begin{align}\label{hat_S_def} \hat S(h)=-\frac12\tr_hB|_{\mathfrak n} -\frac12|\Delta(\mathfrak l,\mathfrak n,\mathfrak l)|_{\rm{mix}}^2 -\frac14 |\Delta(\mathfrak n,\mathfrak n,\mathfrak n)|_h^2,\qquad h\in\mathcal M(\mathfrak k), \end{align} where $|\cdot|_{\rm{mix}}$ is the norm induced by $Q|_{\mathfrak l}$ and $h$ on $\mathfrak l\otimes\mathfrak n^*\otimes\mathfrak l^*$ and $|\cdot|_h$ is the norm induced by~$h$ on $\mathfrak n\otimes\mathfrak n^*\otimes\mathfrak n^*$. If $\mathfrak k$ coincides with $\mathfrak g$, we identify $\mathcal M(\mathfrak k)$ with $\mathcal M$. In this case, the second term on the right-hand side of~\eqref{hat_S_def} vanishes, and $\hat S(h)$ equals~$S(h)$. If the decomposition~\eqref{m_decomp} is such that \begin{align}\label{n_h_diag} \mathfrak k=\Big(\bigoplus_{i\in J_{\mathfrak k}}\mathfrak m_i\Big)\oplus\mathfrak h,\qquad h=\sum_{i\in J_{\mathfrak k}}y_i\pi_{\mathfrak m_i}^*Q,\qquad y_i>0, \end{align} for some $J_{\mathfrak k}\subset\{1,\ldots,s\}$, then \begin{align}\label{hat_S_formula} \hat S(h)&=\frac12\sum_{i\in J_{\mathfrak k}}\frac{d_ib_i}{y_i}-\frac12\sum_{i\in J_{\mathfrak k}}\sum_{j,k\in J_{\mathfrak k}^c}\frac{[ijk]}{y_i} -\frac14\sum_{i,j,k\in J_{\mathfrak k}}[ijk]\frac{y_k}{y_iy_j}, \end{align} where $J_{\mathfrak k}^c$ is the complement of $J_{\mathfrak k}$ in $\{1,\ldots,s\}$; see~\cite[Lemma~2.19]{MGAP17}. \subsection{Restrictions to hypersurfaces} Throughout the rest of this paper, we fix $T\in\mathcal M$. As in Section~\ref{sec_intro}, define $\mathcal M_T$ as the set of those $g\in\mathcal M$ that satisfy the equality $\tr_gT=1$. Assume $\mathcal M_T$ has the smooth structure inherited from~$\mathcal M$. The following result is a special case of~\cite[Lemma~2.1]{AP16}. It provides a variational interpretation of the prescribed Ricci curvature equation~\eqref{eq_PRC} on homogeneous spaces. We will use it in the proof of Theorem~\ref{thm_gen} below. \begin{proposition}\label{prop_var} The Ricci curvature of a metric $g\in\mathcal M_T$ equals $cT$ for some $c\in\mathbb R$ if and only if $g$ is a critical point of the restriction of the scalar curvature functional $S$ to $\mathcal M_T$. \end{proposition} As in Subsection~\ref{subsec_sc_curv}, consider a Lie subalgebra $\mathfrak k$ of $\mathfrak g$ such that $\mathfrak h\subset\mathfrak k$ and $\mathfrak h\ne\mathfrak k$. Let $\mathfrak n$ and $\mathfrak l$ be given by~\eqref{def_funny_subsp}. Denote \begin{align*} \mathcal M_T(\mathfrak k)=\{h\in\mathcal M(\mathfrak k)\,|\,\tr_hT|_{\mathfrak n}=1\}. \end{align*} We assume $\mathcal M_T(\mathfrak k)$ is equipped with the topology it inherits from~$\mathcal M(\mathfrak k)$. Our next result introduces a important parameter associated with $\mathfrak k$. \begin{proposition}\label{prop_sigma_finite} The quantity $\sigma(\mathfrak k,T)$ defined by the formula \begin{align*} \sigma(\mathfrak k,T)=\sup\{\hat S(h)\,|\,h\in\mathcal M_T(\mathfrak k)\} \end{align*} satisfies \begin{align*} 0\le\sigma(\mathfrak k,T)<\infty. \end{align*} \end{proposition} \begin{proof} The assertion follows immediately from the estimates on $\hat S$ obtained in~\cite[Lemmas~2.22 and~2.23]{MGAP17}. While these estimates are stated in~\cite{MGAP17} after Hypothesis~2.3 of that paper is imposed, their proofs do not require any assumptions other than those of Proposition~\ref{prop_sigma_finite}. \end{proof} \begin{remark}\label{rem_sigma_subalg} If $\mathfrak k^+$ is a Lie subalgebra of $\mathfrak g$ containing $\mathfrak k$, then \begin{align}\label{ineq_subs_sigma} \sigma(\mathfrak k^+,T)\ge\sigma(\mathfrak k,T). \end{align} Indeed, fix $h\in\mathcal M_T(\mathfrak k)$ such that \begin{align*} \hat S(h)\in(\sigma(\mathfrak k,T)-\delta,\sigma(\mathfrak k,T)] \end{align*} for some $\delta>0$. It is possible to construct a curve $(h^+(t))_{t>\tr_QT}$ in the space $\mathcal M_T(\mathfrak k^+)$ satisfying the formula \begin{align*} \lim_{t\to\infty}\hat S(h^+(t))=\hat S(h); \end{align*} cf.~\cite[Proof of Lemma~2.30]{MGAP17}. The existence of such a curve implies \begin{align*} \sigma(\mathfrak k^+,T)\ge\hat S(h)>\sigma(\mathfrak k,T)-\delta \end{align*} Inequality~\eqref{ineq_subs_sigma} follows by letting $\delta$ go to~0. \end{remark} Next, we state a definition. It will help us formulate Theorem~\ref{thm_gen}. \begin{definition}\label{def_T-apical} We call $\mathfrak k$ a $T$-\emph{apical} subalgebra of $\mathfrak g$ if $\mathfrak k$ meets the following requirements: \begin{enumerate} \item The inequality $\mathfrak k\ne\mathfrak g$ holds. \item There exists a scalar product $h\in\mathcal M_T(\mathfrak k)$ such that \begin{align}\label{max_attained} \hat S(h)=\sigma(\mathfrak k,T). \end{align} \item If $\mathfrak s$ is a maximal Lie subalgebra of $\mathfrak g$ containing $\mathfrak h$, then \begin{align*} \sigma(\mathfrak s,T)\le\sigma(\mathfrak k,T). \end{align*} \end{enumerate} \end{definition} We conclude this subsection with a result that provides a formula for $\sigma(\mathfrak k,T)$ when the representation $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak n}$ is irreducible. We will use this result in our study of generalised Wallach spaces and generalised flag manifolds below. \begin{proposition}\label{prop_irred} If $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak n}$ is irreducible, then $\mathcal M_T(\mathfrak k)$ consists of a single point. In this case, \begin{align}\label{sigma_irred} \sigma(\mathfrak k,T)=-\frac{2\tr_QB|_{\mathfrak n}+\langle\mathfrak n\mathfrak n\mathfrak n\rangle+2\langle\mathfrak n\mathfrak l\mathfrak l\rangle}{4\tr_QT|_{\mathfrak n}}. \end{align} \end{proposition} Before presenting the proof, let us restate~\eqref{sigma_irred} in terms of the structure constants of~$M$. This will help us with our computations in Sections~\ref{sec_Wallach} and~\ref{sec_flag}. If $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak n}$ is irreducible, it is possible to choose the decomposition~\eqref{m_decomp} so that $\mathfrak n=\mathfrak m_i$ for some $i=1,\ldots,s$. In this case, \begin{align*} T|_{\mathfrak n}=z_iQ|_{\mathfrak m_i},\qquad z_i>0. \end{align*} We use~\eqref{b_def} and~\eqref{<ijk>[ijk]} to find \begin{align*} \tr_QT|_{\mathfrak n}=d_iz_i,\qquad \tr_QB|_{\mathfrak n}=-d_ib_i,\qquad \langle\mathfrak n\mathfrak n\mathfrak n\rangle =[iii],\qquad \langle\mathfrak n\mathfrak l\mathfrak l\rangle =\sum_{j,k\in\{1,\ldots,s\}\setminus\{i\}}[ijk]. \end{align*} Thus, we can restate~\eqref{sigma_irred} as \begin{align}\label{sigma_str_irred} \sigma(\mathfrak k,T)=\frac1{d_iz_i}\bigg(\frac12d_ib_i-\frac14[iii]-\frac12\sum_{j,k\in\{1,\ldots,s\}\setminus\{i\}}[ijk]\bigg). \end{align} \begin{proof}[Proof of Proposition~\ref{prop_irred}.] Assume $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak n}$ is irreducible. Then \begin{align*} \mathcal M(\mathfrak k)=\{yQ|_{\mathfrak n}\,|\,y>0\}. \end{align*} The trace $\tr_{yQ}T|_{\mathfrak n}$ equals $\frac1y\tr_QT|_{\mathfrak n}$ for all $y>0$. Consequently, \begin{align*} \mathcal M_T(\mathfrak k)=\{y_0Q|_{\mathfrak n}\}, \end{align*} where $y_0=\tr_QT|_{\mathfrak n}$. Using~\eqref{hat_S_def} and~\eqref{permut}, we compute \begin{align*} \sigma(\mathfrak k,T)=\hat S(y_0Q|_{\mathfrak n})&=-\frac1{2y_0}\tr_QB|_{\mathfrak n} -\frac1{2y_0}\langle\mathfrak l\mathfrak n\mathfrak l\rangle -\frac1{4y_0} \langle\mathfrak n\mathfrak n\mathfrak n\rangle \\ &=-\frac{2\tr_QB|_{\mathfrak n}+\langle\mathfrak n\mathfrak n\mathfrak n\rangle+2\langle\mathfrak n\mathfrak l\mathfrak l\rangle}{4\tr_QT|_{\mathfrak n}}. \end{align*} \end{proof} \begin{remark} Suppose $K$ is the connected Lie subgroup of $G$ whose Lie algebra equals~$\mathfrak k$. The irreducibility assumption on the representation $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak n}$ in Proposition~\ref{prop_irred} means that the homogeneous space $K/H$ is isotropy irreducible. \end{remark} \section{The general results}\label{sec_gen_results} Our primary objective in this section is to state and prove an existence theorem for metrics satisfying~\eqref{eq_PRC} on the homogeneous space~$M$. \subsection{Metrics with prescribed Ricci curvature and $T$-apical subalgebras}\label{subsec_ex_thm} Theorems~\ref{thm_gen} below requires the following hypothesis. The class of homogeneous spaces for which this hypothesis holds is extensive. We discuss examples in Sections~\ref{sec_Wallach} and~\ref{sec_flag}. \begin{hypothesis}\label{hyp_flag} Every maximal Lie subalgebra $\mathfrak s$ of $\mathfrak g$ such that $\mathfrak h\subset\mathfrak s$ satisfies the following requirement: if $\mathfrak u\subset\mathfrak s\ominus\mathfrak h$ and $\mathfrak v\subset\mathfrak g\ominus\mathfrak s$ are non-zero $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant spaces, then the representations $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak u}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak v}$ are inequivalent. \end{hypothesis} \begin{remark}\label{rem_hyp1_ineq} Hypothesis~\ref{hyp_flag} holds if the isotropy representation of $M$ splits into pairwise inequivalent irreducible summands; see~\cite[Proof of Proposition~4.1]{MGAP17}. However, it may be satisfied even if $M$ does not possess this property. We provide an example in Remark~\ref{rem_spheres} below. \end{remark} As above, consider a Lie subalgebra $\mathfrak k$ of $\mathfrak g$ such that $\mathfrak h\subset\mathfrak k$ and $\mathfrak h\ne\mathfrak k$. Let $\mathfrak n$ and $\mathfrak l$ be given by~\eqref{def_funny_subsp}. We are now ready to state our theorem about the solvability of~\eqref{eq_PRC} on~$M$. In Sections~\ref{sec_Wallach} and~\ref{sec_flag}, we will use it to obtain existence results for metrics with prescribed Ricci curvature on generalised Wallach spaces and generalised flag manifolds. \begin{theorem}\label{thm_gen} Let Hypothesis~\ref{hyp_flag} hold. Suppose $\mathfrak k$ is a $T$-apical subalgebra of~$\mathfrak g$. If \begin{align}\label{ineq_main_thm} 4\sigma(\mathfrak k,T)\tr_Q T|_{\mathfrak l}<-2\tr_QB|_{\mathfrak l}-\langle\mathfrak l\mathfrak l\mathfrak l\rangle, \end{align} then there exists $g\in\mathcal M_T$ such that $S(g)\ge S(g')$ for all~$g'\in\mathcal M_T$. The Ricci curvature of~$g$ equals $cT$ for some~$c>0$. \end{theorem} \begin{remark}\label{rem_spheres} Suppose $G=Sp(k+1)$ and $H=Sp(k)$ for some $k\in\mathbb N$. In this case, $M$ is a sphere of dimension~$4k+3$. The isotropy representation of $M$ splits into four irreducible summands, three of which are equivalent to each other; see~\cite{WZ82}. Hypothesis~\ref{hyp_flag} holds, and Theorem~\ref{thm_gen} can be used to show that $S$ attains its global maximum on~$\mathcal M_T$ under certain conditions. The prescribed Ricci curvature problem on homogeneous spheres will be studied carefully in the forthcoming paper~\cite{TBAPYRWZ}. \end{remark} \begin{remark} According to~\cite[Lemma~2.15]{MGAP17}, the quantity on the right-hand side of~\eqref{ineq_main_thm} is necessarily non-negative. \end{remark} \begin{remark} As explained in~\cite[Remark~2.2]{MGAP17}, the restriction of $S$ to $\mathcal M_T$ is always bounded above but rarely bounded below. \end{remark} \begin{remark} The properness of the restriction of $S$ to $\mathcal M_T$ is discussed in~\cite[Remark~2.11]{MGAP17}. \end{remark} We will prove Theorem~\ref{thm_gen} in Subsection~\ref{subsec_proofs}. In the meantime, let us restate condition~\eqref{ineq_main_thm} in terms of the structure constants of~$M$. Suppose the decomposition~\eqref{m_decomp} is such that the first formula in~\eqref{n_h_diag} holds for some $J_{\mathfrak k}\subset\{1,\ldots,s\}$. In this case, \begin{align}\label{tr_B_b} \mathfrak l=\bigoplus_{i\in J_{\mathfrak k}^c}\mathfrak m_i,\qquad \tr_QB|_{\mathfrak l}=-\sum_{i\in J_{\mathfrak k}^c}d_ib_i. \end{align} (Recall that $J_{\mathfrak k}^c$ denotes the complement of $J_{\mathfrak k}$.) Exploiting~\eqref{<ijk>[ijk]}, we find that condition~\eqref{ineq_main_thm} holds if and only if \begin{align}\label{cond_str_const} \sigma(\mathfrak k,T)\tr_QT|_{\mathfrak l}<\frac12\sum_{i\in J_{\mathfrak k}^c}d_ib_i-\frac14\sum_{i,j,k\in J_{\mathfrak k}^c}[ijk]. \end{align} The following strengthened version of Hypothesis~\ref{hyp_flag} is closely related to~\cite[Hypothesis~2.3]{MGAP17}. It will help us obtain our next result. \begin{hypothesis}\label{hyp_strong} Every Lie subalgebra $\mathfrak s$ of $\mathfrak g$ such that $\mathfrak h\subset\mathfrak s$ satisfies the following requirement: if $\mathfrak u\subset\mathfrak s\ominus\mathfrak h$ and $\mathfrak v\subset\mathfrak g\ominus\mathfrak s$ are non-zero $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant spaces, then the representations $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak u}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak v}$ are inequivalent. \end{hypothesis} \begin{remark}\label{rem_hyp2_ineq} Hypothesis~\ref{hyp_strong} is necessarily satisfied if the isotropy representation of $M$ splits into pairwise inequivalent irreducible summands; see~\cite[Proof of Proposition~4.1]{MGAP17}. \end{remark} Theorem~\ref{thm_gen} is moot if $\mathfrak g$ does not have any $T$-apical subalgebras. Our next result shows that, under Hypothesis~\ref{hyp_strong}, at least one such subalgebra must exist. We prove this result in Subsection~\ref{subsec_pr_apic_ex}. \begin{theorem}\label{thm_apic_ex} Let Hypothesis~\ref{hyp_strong} hold. Suppose $\mathfrak h$ is not maximal in~$\mathfrak g$. Then $\mathfrak g$ has at least one $T$-apical subalgebra. \end{theorem} \subsection{Proof of Theorem~\ref{thm_gen}}\label{subsec_proofs} Throughout this subsection, we assume Hypothesis~\ref{hyp_flag} holds. Our arguments will rely on the consequence of this hypothesis given by Lemma~\ref{lem_k=m} below. It provides a description of some of the Lie subalgebras of $\mathfrak g$ in terms of the decomposition~\eqref{m_decomp} chosen in Subsection~\ref{subsec_str_const}. We emphasise that, as explained in Remarks~\ref{rem_hyp1_ineq} and~\ref{rem_spheres}, the representations $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_i}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_j}$ may be equivalent for $i\ne j$. \begin{lemma}\label{lem_k=m} If $\mathfrak s$ is a maximal Lie subalgebra of $\mathfrak g$ such that $\mathfrak h\subset\mathfrak s$ and $\mathfrak h\ne\mathfrak s$, then there exists a unique set $J_{\mathfrak s}\subset\{1,\ldots,s\}$ satisfying the formula \begin{align*} \mathfrak s=\Big(\bigoplus_{i\in J_{\mathfrak s}}{\mathfrak m}_i\Big)\oplus\mathfrak h. \end{align*} \end{lemma} \begin{proof} It suffices to repeat the reasoning from~\cite[Proof of Lemma~2.12]{MGAP17} using Hypothesis~\ref{hyp_flag} instead of~\cite[Hypothesis~2.3]{MGAP17}. \end{proof} In this subsection, we assume $\mathfrak k$ is a $T$-apical subalgebra of~$\mathfrak g$. By definition, \begin{align}\label{incl_k_proper} \mathfrak h\subset\mathfrak k,\qquad\mathfrak h\ne\mathfrak k,\qquad \mathfrak k\ne\mathfrak g. \end{align} Let $\mathfrak k_1,\ldots,\mathfrak k_r$ be all the maximal Lie subalgebras of $\mathfrak g$ containing $\mathfrak h$ as a proper subset. Lemma~\ref{lem_k=m} implies that there are only finitely many such subalgebras. The fact that at least one exists follows from~\eqref{incl_k_proper}. Given $\tau>0$, define \begin{align*} \mathcal C(\tau,T)=\{g\in\mathcal M_T\,|\,g(X,X)\le\tau~\mbox{for all}~X\in\mathfrak m~\mbox{such that}~Q(X,X)=1\}. \end{align*} It is easy to verify that this set is compact in $\mathcal M_T$; cf.~\cite[Lemma~2.24]{MGAP17}. To prove Theorem~\ref{thm_gen}, we will need the following estimate for the scalar curvature functional~$S$. \begin{lemma}\label{lem_eps+max} Given $\epsilon>0$, there exists $\kappa(\epsilon)>0$ such that \begin{align}\label{est_eps+max} S(g)\le\epsilon+\max_{m=1,\ldots,r}\sigma(\mathfrak k_m,T) \end{align} for every $g\in\mathcal M_T\setminus\mathcal C(\kappa(\epsilon),T)$. \end{lemma} \begin{proof} We repeat the arguments from~\cite[Proof of Lemma~2.28]{MGAP17} using Lemma~\ref{lem_k=m} above instead of~\cite[Lemma~2.12]{MGAP17}. As a result, we find \begin{align*} \hat S(g)\le\epsilon+\max_{m=1,\ldots,r}\sup\{\hat S(h)\,|\,h\in\mathcal M_T(\mathfrak k_m)\}, \qquad g\in\mathcal M_T\setminus \mathcal C(\kappa(\epsilon),T), \end{align*} for some $\kappa(\epsilon)>0$. With this estimate at hand,~\eqref{est_eps+max} follows from the definition of~$\sigma(\mathfrak k_m,T)$ and the fact that $\hat S$ coincides with $S$ on~$\mathcal M_T$. \end{proof} Next, we will demonstrate that $S$ attains its global maximum on $\mathcal M_T$ at some $g\in\mathcal M_T$ if condition~\eqref{ineq_main_thm} holds. Lemma~\ref{prop_var} will then imply equality~\eqref{eq_PRC} for this~$g$ with $c\in\mathbb R$. Once~\eqref{eq_PRC} is established, we will use Hypothesis~\ref{hyp_flag} to show that~$c>0$. \begin{proof}[Proof of Theorem~\ref{thm_gen}.] Since $\mathfrak k$ is a $T$-apical subalgebra of~$\mathfrak g$, there exists $h\in\mathcal M_T(\mathfrak k)$ such that~\eqref{max_attained} holds. Assume the decomposition~\eqref{m_decomp} is chosen so that $\mathfrak k$ and $h$ satisfy~\eqref{n_h_diag} for some $J_{\mathfrak k}\subset\{1,\ldots,s\}$. This assumption does not lead to loss of generality; see~\cite[page~180]{MWWZ86}. As above, let $\mathfrak l$ be given by~\eqref{def_funny_subsp}. For $t>\tr_QT|_{\mathfrak l}$, define a scalar product $h(t)\in\mathcal M_T$ by the formulas \begin{align*} h(t)=\sum_{j\in J_{\mathfrak k}}\phi(t)y_j\pi_{\mathfrak m_j}^*Q+\sum_{j\in J_{\mathfrak k}^c}t\pi_{\mathfrak m_j}^*Q, \qquad \phi(t)=\frac t{t-\tr_QT|_{\mathfrak l}}. \end{align*} Assuming~\eqref{ineq_main_thm} holds, we will show that \begin{align}\label{S>max} S(h(t_0))>\max_{m=1,\ldots,r}\sigma(\mathfrak k_m,T) \end{align} for some~$t_0$. This inequality and Lemma~\ref{lem_eps+max} will imply the existence of $g\in\mathcal M_T$ such that $S(g)\ge S(g')$ for all $g'\in\mathcal M_T$. With the aid of~\eqref{sc_curv_formula}, we find \begin{align*} S(h(t))&=\frac12\sum_{j\in J_{\mathfrak k}}\frac{d_jb_j}{\phi(t)y_j}+\frac12\sum_{j\in J_{\mathfrak k}^c}\frac{d_jb_j}t-\frac14\sum_{j,k,l\in J_{\mathfrak k}}[jkl]\frac{y_l}{\phi(t)y_jy_k} -\frac14\sum_{j,k,l\in J_{\mathfrak k}^c}\frac{[jkl]}t \\ &\hphantom{=}~-\frac12\sum_{j\in J_{\mathfrak k}}\sum_{k,l\in J_{\mathfrak k}^c}\frac{[jkl]}{\phi(t)y_j}-\frac14\sum_{j\in J_{\mathfrak k}}\sum_{k,l\in J_{\mathfrak k}^c}[jkl]\frac{\phi(t)y_j}{t^2} \\ &\hphantom{=}~-\frac12\sum_{j,k\in J_{\mathfrak k}}\sum_{l\in J_{\mathfrak k}^c}[jkl]\frac{y_k}{ty_j}-\frac14\sum_{j,k\in J_{\mathfrak k}}\sum_{l\in J_{\mathfrak k}^c}[jkl]\frac t{\phi^2(t)y_jy_k}. \end{align*} The two terms in the last line are~0. Indeed, $[jkl]$ equals~0 if $j,k\in J_{\mathfrak k}$ and $l\in J_{\mathfrak k}^c$ because $\mathfrak k$ is a subalgebra of $\mathfrak g$; see~\cite[Lemma~2.14]{MGAP17}. Exploiting~\eqref{hat_S_formula}, \eqref{tr_B_b} and~\eqref{<ijk>[ijk]}, we conclude \begin{align}\label{Sht_big_formula} S(h(t))&=\frac1{\phi(t)}\bigg(\frac12\sum_{j\in J_{\mathfrak k}}\frac{d_jb_j}{y_j}-\frac12\sum_{j\in J_{\mathfrak k}}\sum_{k,l\in J_{\mathfrak k}^c}\frac{[jkl]}{y_j}-\frac14\sum_{j,k,l\in J_{\mathfrak k}}[jkl]\frac{y_l}{y_jy_k}\bigg) \notag \\ &\hphantom{=}~+\frac1t\bigg(\frac12\sum_{j\in J_{\mathfrak k}^c}d_jb_j -\frac14\sum_{j,k,l\in J_{\mathfrak k}^c}[jkl]\bigg)-\frac{\phi(t)}{4t^2}\sum_{j\in J_{\mathfrak k}}\sum_{k,l\in J_{\mathfrak k}^c}[jkl]y_j \notag \\ &=\frac{\hat S(h)}{\phi(t)}-\frac1{4t}(2\tr_QB|_{\mathfrak l} +\langle\mathfrak l\mathfrak l\mathfrak l\rangle)-\frac{\phi(t)}{4t^2}\sum_{j\in J_{\mathfrak k}}\sum_{k,l\in J_{\mathfrak k}^c}[jkl]y_j. \end{align} Since $\mathfrak k$ is $T$-apical, \begin{align}\label{eq_lim_apic} \lim_{t\to\infty}S(h(t))=\hat S(h)\ge\max_{m=1,\ldots,r}\sigma(\mathfrak k_m,T). \end{align} Our next step is to show that $\frac d{dt}S(h(t))<0$ when~\eqref{ineq_main_thm} holds and $t$ is large. This will imply the existence of $t_0$ satisfying~\eqref{S>max}. It is clear that $\frac d{dt}S(h(t))$ has the same sign as $t^2\frac d{dt}S(h(t))$. Therefore, to prove that $\frac d{dt}S(h(t))<0$ for large~$t$, it suffices to show that \begin{align*} \lim_{t\to\infty}t^2\frac d{dt}S(h(t))<0. \end{align*} Using~\eqref{Sht_big_formula}, we obtain \begin{align*} t^2\frac d{dt}S(h(t))&=\hat S(h)\tr_QT|_{\mathfrak l}+\frac12\tr_QB|_{\mathfrak l}+\frac14\langle\mathfrak l\mathfrak l\mathfrak l\rangle+\frac{2t-\tr_QT|_{\mathfrak l}}{4(t-\tr_QT|_{\mathfrak l})^2}\sum_{j\in J_{\mathfrak k}}\sum_{k,l\in J_{\mathfrak k}^c}[jkl]y_j. \end{align*} If~\eqref{ineq_main_thm} holds, then \begin{align*} \lim_{t\to\infty}t^2\frac d{dt}S(h(t))&=\hat S(h)\tr_QT|_{\mathfrak l}+\frac12\tr_QB|_{\mathfrak l}+\frac14\langle\mathfrak l\mathfrak l\mathfrak l\rangle \\ &=\sigma(\mathfrak k,T)\tr_QT|_{\mathfrak l}+\frac{2\tr_QB|_{\mathfrak l}+\langle\mathfrak l\mathfrak l\mathfrak l\rangle}4<0. \end{align*} In this case, $\frac d{dt}S(h(t))<0$ for large~$t$, which implies the existence of $t_0$ such that \begin{align*} S(h(t_0))>\lim_{t\to\infty}S(h(t)). \end{align*} Formula~\eqref{eq_lim_apic} plainly shows that $t_0$ satisfies~\eqref{S>max}. Using Lemma~\ref{lem_eps+max} with \begin{align*} \epsilon=\frac{S(h(t_0))-\max_{m=1,\ldots,r}\sigma(\mathfrak k_m,T)}2>0, \end{align*} we conclude that \begin{align}\label{est_outside_C} S(g')<S(h(t_0)),\qquad g'\in\mathcal M_T\setminus\mathcal C(\kappa(\epsilon),T). \end{align} Since the set~$\mathcal C(\kappa(\epsilon),T)$ is compact, the functional $S$ attains its global maximum on $\mathcal C(\kappa(\epsilon),T)$ at some $g\in\mathcal C(\kappa(\epsilon),T)$. Inequality~\eqref{est_outside_C} implies that, in fact, $S(g')\le S(g)$ for all $g'\in\mathcal M_T$. By Proposition~\ref{prop_var}, $g$ satisfies~\eqref{eq_PRC} for some $c\in\mathbb R$. The proof will be complete if we show that $c>0$. According to Bochner's theorem (see~\cite[Theorem~1.84]{AB87}), there are no $G$-invariant Riemannian metrics on $M$ with negative-definite Ricci curvature. It follows that $c\ge0$. Let us show that no $G$-invariant metric on $M$ can be Ricci-flat. This will imply~$c\ne0$. We proceed by contradiction. Assume $M$ supports a Ricci-flat $G$-invariant metric. Using Bochner's theorem again, we can show that \begin{align*} [\mathfrak m,\mathfrak h]=\{0\}; \end{align*} cf.~\cite[Subsection~2.7]{MGAP17}. Consequently, given~$i=1,\ldots,s$, the representation $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_i}$ is trivial. By irreducibility, the dimension of this representation is~1. Let us prove that the maximal Lie subalgebra $\mathfrak k_1$ of $\mathfrak g$ fails to satisfy the requirement of Hypothesis~\ref{hyp_flag}. This will give us the contradiction we are seeking. By Lemma~\ref{lem_k=m}, the space $\mathfrak k_1\ominus\mathfrak h$ equals $\bigoplus_{i\in J_{\mathfrak k_1}}\mathfrak m_i$ for some $J_{\mathfrak k_1}\subset\{1,\ldots,s\}$. If $k$ and $l$ lie in $J_{\mathfrak k_1}$ and $J_{\mathfrak k_1}^c$, respectively, then \begin{align*} \mathfrak m_k\subset\mathfrak k_1\ominus\mathfrak h,\qquad \mathfrak m_l\subset\mathfrak g\ominus\mathfrak k_1. \end{align*} As we showed above, the representations $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_k}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_l}$ are trivial and 1-dimensional. Therefore, these representations are equivalent, which means $\mathfrak k_1$ does not satisfy the requirement of Hypothesis~\ref{hyp_flag}. \end{proof} \subsection{Proof of Theorem~\ref{thm_apic_ex}}\label{subsec_pr_apic_ex} In this subsection, we assume Hypothesis~\ref{hyp_strong} holds and $\mathfrak h$ is not maximal in~$\mathfrak g$. The proof of Theorem~\ref{thm_apic_ex} will rely on the following result. \begin{lemma}\label{lem_key_apic_ex} If $\mathfrak s$ is a Lie subalgebra of $\mathfrak g$ such that $\mathfrak h\subset\mathfrak s$ and $\mathfrak h\ne\mathfrak s$, then there exist a Lie subalgebra $\mathfrak k\subset\mathfrak s$ and a scalar product $h\in\mathcal M_T(\mathfrak k)$ satisfying the formulas \begin{align}\label{apic_ex_flas} \mathfrak h\subset\mathfrak k,\qquad \mathfrak h\ne\mathfrak k,\qquad \hat S(h)=\sigma(\mathfrak k,T)\ge\sigma(\mathfrak s,T). \end{align} \end{lemma} \begin{proof} Denote by $p$ the dimension of $\mathfrak s\ominus\mathfrak h$. We proceed by induction in~$p$. The space $\mathcal M_T(\mathfrak s)$ consists of a single point $h_0$ if $p=1$. Formulas~\eqref{apic_ex_flas} are evident in this case for $\mathfrak k=\mathfrak s$ and $h=h_0$. Let the assertion of the lemma hold when $p\le m$. Our goal is to prove it supposing $p=m+1$. If $\hat S$ has a global maximum on $\mathcal M_T(\mathfrak s)$ at some $h_0\in\mathcal M_T(\mathfrak s)$, then formulas~\eqref{apic_ex_flas} are easy to check for~$\mathfrak k=\mathfrak s$ and $h=h_0$. Therefore, we will focus on the case where the supremum of $\hat S$ over $\mathcal M_T(\mathfrak s)$ is not attained. In this case, $\mathfrak k$ and $\mathfrak s$ cannot coincide. Suppose $\mathfrak s_1,\ldots,\mathfrak s_q$ are all the maximal Lie subalgebras of $\mathfrak s$ containing $\mathfrak h$ as a proper subset. By~\cite[Corollary~2.13 and Remark~2.34]{MGAP17}, there are only finitely many such subalgebras. Under our assumptions, at least one must exist. Otherwise, $\mathfrak h$ would be maximal in~$\mathfrak s$, and~\cite[Lemma~2.32 and Remark~2.34]{MGAP17} would imply that $\hat S$ has a global maximum on~$\mathcal M_T(\mathfrak s)$. Choose an index $i_0$ such that \begin{align*} \sigma(\mathfrak s_{i_0},T)=\max_{i=1,\ldots,q}\sigma(\mathfrak s_i,T). \end{align*} Evidently, the dimension of $\mathfrak s_{i_0}$ is less than or equal to~$m$. By the induction hypothesis, there exist a Lie subalgebra $\mathfrak k\subset\mathfrak s_{i_0}$ and a scalar product $h\in\mathcal M_T(\mathfrak k)$ satisfying formulas~\eqref{apic_ex_flas} with $\mathfrak s$ replaced by~$\mathfrak s_{i_0}$. The proof will be complete if we show that \begin{align}\label{sigma<sigma} \sigma(\mathfrak s,T)\le\sigma(\mathfrak s_{i_0},T). \end{align} Pick $\epsilon>0$. According to~\cite[Lemma~2.28 and Remark~2.34]{MGAP17}, \begin{align}\label{h'<eps+sigma} \hat S(h')\le\epsilon+\sigma(\mathfrak s_{i_0},T) \end{align} whenever $h'\in\mathcal M_T(\mathfrak s)$ lies outside some compact subset $\mathcal C_\epsilon$ of $\mathcal M_T(\mathfrak s)$. We will demonstrate that, in fact,~\eqref{h'<eps+sigma} holds for all $h'\in\mathcal M_T(\mathfrak s)$. Estimate~\eqref{sigma<sigma} will follow by taking the supremum on the left-hand side of~\eqref{h'<eps+sigma} and letting $\epsilon$ go to~0. Since $\mathcal C_{\epsilon}$ is compact, there exists $h_0'\in\mathcal C_\epsilon$ such that \begin{align*} \hat S(h_0')\ge\hat S(h'),\qquad h'\in\mathcal C_{\epsilon}.\end{align*} Clearly, if \begin{align*} \hat S(h_0')>\epsilon+\sigma(\mathfrak s_{i_0},T), \end{align*} then $\hat S$ has a global maximum on $\mathcal M_T(\mathfrak s)$ at~$h_0'$. However, we are assuming that the supremum of $\hat S$ over $\mathcal M_T(\mathfrak s)$ is not attained. Thus,~\eqref{h'<eps+sigma} holds for all $h'\in\mathcal M_T(\mathfrak s)$. \end{proof} \begin{remark} In view of Remark~\ref{rem_sigma_subalg}, we can replace the third formula in~\eqref{apic_ex_flas} by \begin{align*} \hat S(h)=\sigma(\mathfrak k,T)=\sigma(\mathfrak s,T). \end{align*} \end{remark} As above, denote by $\mathfrak k_1,\ldots,\mathfrak k_r$ the maximal Lie subalgebras of $\mathfrak g$ containing $\mathfrak h$ as a proper subset. With Hypothesis~\ref{hyp_strong} at hand, one can invoke Lemma~\ref{lem_k=m} or~\cite[Corollary~2.13 and Remark~2.34]{MGAP17} to conclude that there are only finitely many such subalgebras. The fact that at least one exists follows from the assumption that $\mathfrak h$ is not maximal in~$\mathfrak g$. \begin{proof}[Proof of Theorem~\ref{thm_apic_ex}.] Choose $j_0$ such that \begin{align*} \sigma(\mathfrak k_{j_0},T)=\max_{j=1,\ldots,r}\sigma(\mathfrak k_j,T). \end{align*} Applying Lemma~\ref{lem_key_apic_ex} with $\mathfrak s=\mathfrak k_{j_0}$, we obtain a Lie subalgebra $\mathfrak k$ of $\mathfrak k_{j_0}$ and a scalar product $h\in\mathcal M_T(\mathfrak k)$ satisfying formulas~\eqref{apic_ex_flas} with $\mathfrak s=\mathfrak k_{j_0}$. It is obvious that $\mathfrak k\ne\mathfrak g$ and~\eqref{max_attained} holds. Furthermore, \begin{align*} \sigma(\mathfrak k_j,T)\le\sigma(\mathfrak k_{j_0},T)\le\sigma(\mathfrak k,T),\qquad j=1,\ldots,r. \end{align*} Thus, $\mathfrak k$ is $T$-apical. \end{proof} \section{Generalised Wallach spaces}\label{sec_Wallach} Throughout Section~\ref{sec_Wallach}, we assume $M$ is a generalised Wallach space, as defined in~\cite{YN16}. Theorem~\ref{thm_gen} and Proposition~\ref{prop_irred} yield an easy-to-verify sufficient condition for the solvability of~\eqref{eq_PRC} on such spaces. Our goal is to state this condition, prove it and consider an example. Since $M$ is a generalised Wallach space, the group $G$ is semisimple. Consequently, the Killing form $B$ is non-degenerate. It will be convenient for us to set $Q=-B$. The definition of a generalised Wallach space implies that $s=3$ in the decomposition~\eqref{m_decomp}. Thus, the formula \begin{align}\label{m3_dec} \mathfrak m=\mathfrak m_1\oplus\mathfrak m_2\oplus\mathfrak m_3 \end{align} holds. We assume the representations $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_1}$, $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_2}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_3}$ are pairwise inequivalent. The summands $\mathfrak m_1,\mathfrak m_2,\mathfrak m_3$ in the decomposition~\eqref{m3_dec} are determined uniquely up to order. Appealing to the definition of a generalised Wallach space again, we obtain the inclusion \begin{align}\label{incl_Wallach_mi} [\mathfrak m_i,\mathfrak m_i]\subset\mathfrak h,\qquad i=1,2,3. \end{align} As a consequence, the structure constant $[ijk]$ vanishes unless $(i,j,k)$ is a permutation of $\{1,2,3\}$. We assume $[123]$ is positive. If $[123]=0$, then all the metrics in $\mathcal M$ have the same Ricci curvature; cf.~\cite[Lemma~3.2]{APYRsubm}. In this case, the analysis of~\eqref{eq_PRC} is easy. Since $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_1}$, $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_2}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_3}$ are pairwise inequivalent, the formula \begin{align*} T=-z_1\pi_{\mathfrak m_1}^*B-z_2\pi_{\mathfrak m_2}^*B-z_3\pi_{\mathfrak m_3}^*B \end{align*} holds for some $z_1,z_2,z_3>0$. Denote by $d$ the dimension of~$M$. Clearly, $d=d_1+d_2+d_3$. We are now ready to state the main result of this section. \begin{theorem}\label{thm_Wallach} Suppose $p\in\{1,2,3\}$ is such that \begin{align}\label{cond_Wallach} \frac{d_p-2[123]}{2d_pz_p}=\max_{i=1,2,3}\frac{d_i-2[123]}{2d_iz_i}. \end{align} If \begin{align}\label{cond2_W} (d_p-2[123])\sum_{i\in\{1,2,3\}\setminus\{p\}}d_iz_i<(d-d_p)d_pz_p, \end{align} then there exists a metric $g\in\mathcal M_T$ with Ricci curvature $cT$ for some~$c>0$. \end{theorem} \begin{remark}\label{rem_W_const} The numbers $d_1$, $d_2$, $d_3$ and $[123]$ for the generalised Wallach spaces satisfying the assumptions of this section are given in~\cite[Table~1]{YN16}; see also~\cite[Tables~1 and~2]{ZCYKKL16}. \end{remark} To prove the theorem, we need the following result. \begin{lemma}\label{lem_Wallach_subal} The proper Lie subalgebras of $\mathfrak g$ containing $\mathfrak h$ as a proper subset are \begin{align*} \mathfrak k_1=\mathfrak m_1\oplus\mathfrak h,\qquad \mathfrak k_2=\mathfrak m_2\oplus\mathfrak h,\qquad \mathfrak k_3=\mathfrak m_3\oplus\mathfrak h. \end{align*} \end{lemma} \begin{proof} Formula~\eqref{incl_Wallach_mi} implies that \begin{align*} [\mathfrak k_i,\mathfrak k_i]\subset\mathfrak k_i,\qquad i=1,2,3. \end{align*} Thus, $\mathfrak k_i$ is indeed a Lie subalgebra of $\mathfrak g$ for $i=1,2,3$. As we noted above, the summands in~\eqref{m3_dec} are determined uniquely up to order. Using this observation, one can show that every $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant subspace of $\mathfrak m$ appears as $\bigoplus_{i\in\mathcal J}\mathfrak m_i$, where $\mathcal J\subset\{1,2,3\}$. Let $\mathfrak k$ be a Lie subalgebra of $\mathfrak g$ such that $\mathfrak h\subset\mathfrak k$, $\mathfrak h\ne\mathfrak k$ and $\mathfrak k\ne\mathfrak g$. We will prove that $\mathfrak k=\mathfrak k_i$ for some $i\in\{1,2,3\}$. Clearly, $\mathfrak k\ominus\mathfrak h$ is a proper non-zero $\mathop{\mathrm{Ad}}\nolimits(H)$-invariant subspace of~$\mathfrak m$. Therefore, $\mathfrak k$ equals $\mathfrak m_i\oplus\mathfrak h$ for some $i\in\{1,2,3\}$ or $\mathfrak m_j\oplus\mathfrak m_k\oplus\mathfrak h$ for some distinct $j,k\in\{1,2,3\}$. Since $[123]>0$, the space $\mathfrak m_j\oplus\mathfrak m_k\oplus\mathfrak h$ cannot be a Lie subalgebra of~$\mathfrak g$. This means $\mathfrak k=\mathfrak k_i$ for some $i\in\{1,2,3\}$. \end{proof} \begin{proof}[Proof of Theorem~\ref{thm_Wallach}.] Because $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_1}$, $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_2}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_3}$ are pairwise inequivalent, Hypothesis~\ref{hyp_flag} holds for~$M$; see Remark~\ref{rem_hyp1_ineq}. Let us show that \begin{align*} \mathfrak k_p=\mathfrak m_p\oplus\mathfrak h \end{align*} is a $T$-apical subalgebra of~$\mathfrak g$. This will enable us to apply Theorem~\ref{thm_gen}. The existence of $g$ under condition~\eqref{cond2_W} will follow immediately. It is obvious that $\mathfrak k_p$ cannot equal~$\mathfrak g$. Ergo, $\mathfrak k_p$ satisfies requirement~1 of Definition~\ref{def_T-apical}. By Proposition~\ref{prop_irred}, the space $\mathcal M_T(\mathfrak k_p)$ consists of a single point. Denoting this point by $h_0$, we see that equality~\eqref{max_attained} holds with $h=h_0$ and $\mathfrak k=\mathfrak k_p$. Consequently, $\mathfrak k_p$ satisfies requirement~2 of Definition~\ref{def_T-apical}. By Lemma~\ref{lem_Wallach_subal}, the maximal subalgebras of $\mathfrak g$ containing $\mathfrak h$ as a proper subset are $\mathfrak k_1$, $\mathfrak k_2$ and $\mathfrak k_3$. Since $Q=-B$, the numbers $b_1$, $b_2$ and $b_3$ given by~\eqref{b_def} all equal~1. Exploiting~\eqref{sigma_str_irred}, \eqref{incl_Wallach_mi} and~\eqref{cond_Wallach}, we obtain \begin{align*} \sigma(\mathfrak k_i,T)=\frac{d_i-2[123]}{2d_iz_i}\le\frac{d_p-2[123]}{2d_pz_p}=\sigma(\mathfrak k_p,T),\qquad i=1,2,3. \end{align*} This means $\mathfrak k_p$ satisfies requirement~3 of Definition~\ref{def_T-apical}. By Theorem~\ref{thm_gen} and formula~\eqref{cond_str_const}, a metric $g\in\mathcal M_T$ with Ricci curvature $cT$ for some $c>0$ exists if \begin{align*} \sigma(\mathfrak k_p,T)\tr_QT|_{\mathfrak g\ominus\mathfrak k_p}<\frac12\sum_{i\in\{1,2,3\}\setminus\{p\}}d_i-\frac14\sum_{i,j,k \in\{1,2,3\}\setminus\{p\}}[ijk]. \end{align*} Using~\eqref{sigma_str_irred} and~\eqref{incl_Wallach_mi} again, we find \begin{align*} \sigma(\mathfrak k_p,T)\tr_QT|_{\mathfrak g\ominus\mathfrak k_p}&=\frac{d_p-2[123]}{2d_pz_p}\sum_{i\in\{1,2,3\}\setminus\{p\}}d_iz_i,\\ \frac12\sum_{i\in\{1,2,3\}\setminus\{p\}}d_i&-\frac14\sum_{i,j,k \in\{1,2,3\}\setminus\{p\}}[ijk]=\frac{d-d_p}2. \end{align*} The assertion of Theorem~\ref{thm_Wallach} follows immediately. \end{proof} \begin{example} Suppose $M$ is the generalised Wallach space $E_6/Sp(3)\times Sp(1)$. Let the decomposition~\eqref{m3_dec} be as in~\cite{YN16}. We have \begin{align*} d_1=14,\qquad d_2=28,\qquad d_3=12,\qquad [123]=7/2; \end{align*} see Remark~\ref{rem_W_const} above. A simple computation shows that \begin{align*} \frac{d_1-2[123]}{2d_1z_1}=\frac1{4z_1},\qquad \frac{d_2-2[123]}{2d_2z_2}=\frac3{8z_2},\qquad \frac{d_3-2[123]}{2d_3z_3}=\frac5{24z_3}. \end{align*} If \begin{align}\label{frac1} z_1/z_2\le2/3,\qquad z_1/z_3\le6/5, \end{align} then~\eqref{cond_Wallach} holds for $p=1$. In this case, according to Theorem~\ref{thm_Wallach}, a Riemannian metric with Ricci curvature $cT$ exists for some $c>0$ provided that \begin{align*} 7z_2+3z_3<20z_1. \end{align*} If \begin{align}\label{frac2} z_1/z_2\ge2/3,\qquad z_2/z_3\le9/5, \end{align} then~\eqref{cond_Wallach} holds for $p=2$. In this case, a metric with Ricci curvature $cT$ exists for some $c>0$ as long as \begin{align*} 21z_1+18z_3<52z_2. \end{align*} Finally, if \begin{align}\label{frac3} z_1/z_3\ge6/5,\qquad z_2/z_3\ge9/5, \end{align} then~\eqref{cond_Wallach} is satisfied for $p=3$. In this situation, a metric with Ricci curvature $cT$ exists for some $c>0$ as long as \begin{align*} 5z_1+10z_2<36z_3. \end{align*} It is easy to see that~\eqref{frac1}, \eqref{frac2} or~\eqref{frac3} necessarily holds for the triple $(z_1,z_2,z_3)$. \end{example} \section{Generalised flag manifolds}\label{sec_flag} Suppose $M$ is a generalised flag manifold, as defined in~\cite{SAIC11}. Let the number $s$ in the decomposition~\eqref{m_decomp} be less than or equal to~5. The results of Sections~\ref{sec_prelim} and~\ref{sec_gen_results} yield an easy-to-verify sufficient condition for the solvability of~\eqref{eq_PRC} on~$M$. This condition involves inequalities depending on~$s$ and on whether $M$ is of type~I, II, A or~B in the terminology of~\cite{SAIC11,AAIC10,AAICYS13}. One could state it in the form of a theorem as we did in Section~\ref{sec_Wallach}; however, such a theorem would be exceedingly bulky. Instead, we will illustrate the application of the results of Sections~\ref{sec_prelim} and~\ref{sec_gen_results} by considering two examples of~$M$. Only minor changes are required to make our reasoning work for other~$M$. The definition of a generalised flag manifold implies that the group $G$ is semisimple. Therefore, the Killing form $B$ is non-degenerate. It will be convenient for us set $Q=-B$ throughout Section~\ref{sec_flag}. This means $b_i=1$ in~\eqref{b_def} for all $i=1,\ldots,s$. Because $M$ is a generalised flag manifold, the representations $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_i}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_j}$ are inequivalent when $i\ne j$; see~\cite[page~101]{AA03}. As a consequence, Hypotheses~\ref{hyp_flag} and~\ref{hyp_strong} are satisfied. To determine the dimensions $d_i$ and the structure constants for specific choices of~$M$, refer to~\cite[Chapter~7]{AB87} and~\cite{AAIC10,SAIC11,AAICYS13}. We are now ready to illustrate the application of the results of Sections~\ref{sec_prelim} and~\ref{sec_gen_results}. \begin{example}\label{example_G2U2} Suppose $M$ is the generalised flag manifold $G_2/U(2)$ in which $U(2)$ corresponds to the long root of~$G_2$. Let the decomposition~\eqref{m_decomp} be as in~\cite{SAIC11}. Then \begin{align*} s=3,\qquad d_1=d_3=4,\qquad d_2=2,\qquad [123]=1/2,\qquad [112]=2/3. \end{align*} The structure constant $[ijk]$ vanishes if there is no permutation $\rho$ of the multiset $\{i,j,k\}$ such that $[\rho(i)\rho(j)\rho(k)]$ appears above. As shown in~\cite[Section~4]{MGAP17} (cf.~Lemma~\ref{lem_Wallach_subal} above), the proper Lie subalgebras of $\mathfrak g$ containing $\mathfrak h$ properly are \begin{align*} \mathfrak s_1=\mathfrak m_2\oplus\mathfrak h,\qquad \mathfrak s_2=\mathfrak m_3\oplus\mathfrak h. \end{align*} Invoking Proposition~\ref{prop_irred} as in the proof of Theorem~\ref{thm_Wallach} leads to the conclusion that $\mathfrak s_1$ and $\mathfrak s_2$ meet the first two requirements of Definition~\ref{def_T-apical}. Because $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_1}$, $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_2}$ and $\mathop{\mathrm{Ad}}\nolimits(H)|_{\mathfrak m_3}$ are pairwise inequivalent, the metric $T$ can be expressed as \begin{align}\label{T_gen_fl_G2} -z_1\pi_{\mathfrak m_1}^*B-z_2\pi_{\mathfrak m_2}^*B-z_3\pi_{\mathfrak m_3}^*B \end{align} with $z_1,z_2,z_3>0$. Formula~\eqref{sigma_str_irred} implies that \begin{align*} \sigma(\mathfrak s_1,T)=\frac1{4z_2}(2-[112]-2[123])=\frac1{12z_2},\qquad \sigma(\mathfrak s_2,T)=\frac1{4z_3}(2-[123])=\frac3{8z_3}. \end{align*} If $z_2/z_3\le2/9$, then $\mathfrak s_1$ meets requirement~3 of Definition~\ref{def_T-apical}. In this case, $\mathfrak s_1$ is a $T$-apical subalgebra of~$\mathfrak g$. According to Theorem~\ref{thm_gen} and formula~\eqref{cond_str_const}, a Riemannian metric with Ricci curvature $cT$ exists for some $c>0$ provided that \begin{align}\label{lasttag1} z_1+z_3<12z_2. \end{align} If $z_2/z_3\ge2/9$, then $\mathfrak s_2$ meets requirement~3 of Definition~\ref{def_T-apical}. In this case, $\mathfrak s_2$ is $T$-apical. By Theorem~\ref{thm_gen} and~\eqref{cond_str_const}, a metric with Ricci curvature $cT$ exists for some $c>0$ as long as \begin{align}\label{lasttag2} 6z_1+3z_2<10z_3. \end{align} \end{example} \begin{remark}\label{rem_compar1} Let $M$ be the generalised flag manifold $G_2/U(2)$ as in Example~\ref{example_G2U2}. Assume the decomposition~\eqref{m_decomp} is as in~\cite{SAIC11}. If $T$ is given by~\eqref{T_gen_fl_G2}, the main result of~\cite{MGAP17} implies that a metric with Ricci curvature $cT$ exists for some $c>0$ provided that \begin{align}\label{cond_MGAP17} \frac{z_2}{z_1+z_3}>\frac1{12},\qquad \frac{z_3}{2z_1+z_2}>\frac3{10}; \end{align} see~\cite[Example~4.3]{MGAP17}. This condition is more restrictive than the one given by Theorem~\ref{thm_gen}. Indeed, it is obvious that both~\eqref{lasttag1} and~\eqref{lasttag2} follow from~\eqref{cond_MGAP17}. On the other hand, suppose, for instance, that $z_2=2z_3/9$. A metric with Ricci curvature $cT$ exists for some $c>0$ as long as $z_1<5z_3/3$, according to the arguments in Example~\ref{example_G2U2} above. However, inequalities~\eqref{cond_MGAP17} only hold if $z_1<14z_3/9$. \end{remark} \begin{example}\label{example_F4} Suppose $M$ is the generalised flag manifold $F_4/SU(3)\times SU(2)\times U(1)$. Let the decomposition~\eqref{m_decomp} be as in~\cite{AAIC10}. Then \begin{align*} s=4,\qquad &d_1=12,\qquad d_2=18,\qquad d_3=4,\qquad d_4=6, \notag \\ &[224]=2,\qquad [112]=2,\qquad [123]=1,\qquad [134]=2/3. \end{align*} The structure constant $[ijk]$ vanishes if there is no permutation $\rho$ of the multiset $\{i,j,k\}$ such that $[\rho(i)\rho(j)\rho(k)]$ appears above. Arguing as in the proof of Lemma~\ref{lem_Wallach_subal}, we can show that the proper Lie subalgebras of $\mathfrak g$ containing $\mathfrak h$ properly are \begin{align*} \mathfrak t_1=\mathfrak m_3\oplus\mathfrak h,\qquad \mathfrak t_2=\mathfrak m_4\oplus\mathfrak h,\qquad \mathfrak t_3=\mathfrak m_2\oplus\mathfrak m_4\oplus\mathfrak h. \end{align*} In order to apply Theorem~\ref{thm_gen}, we need to determine which of these subalgebras are $T$-apical. Obviously, they all satisfy requirement~1 of Definition~\ref{def_T-apical}. Moreover, $\mathfrak t_1$ and $\mathfrak t_3$ are maximal in $\mathfrak g$, while $\mathfrak t_2$ is not. Proposition~\ref{prop_irred} implies that $\mathfrak t_1$ and $\mathfrak t_2$ satisfy requirement~2 of Definition~\ref{def_T-apical}. The equality \begin{align}\label{T_gen_fl_F4} T=-z_1\pi_{\mathfrak m_1}^*B-z_2\pi_{\mathfrak m_2}^*B-z_3\pi_{\mathfrak m_3}^*B-z_4\pi_{\mathfrak m_4}^*B \end{align} holds for some $z_1,z_2,z_3,z_4>0$. Exploiting~\eqref{sigma_str_irred}, we find \begin{align*} \sigma(\mathfrak t_1,T)=\frac1{4z_3}(2-[123]-[134])=\frac1{12z_3},\\ \sigma(\mathfrak t_2,T)=\frac1{12z_4}(6-2[413]-[422])=\frac2{9z_4}. \end{align*} Our next step is to understand whether $\mathfrak t_3$ meets requirement~2 of Definition~\ref{def_T-apical} and to compute $\sigma(\mathfrak t_3,T)$. Given $h\in\mathcal M(\mathfrak t_3)$, the equality \begin{align*} h=-u\pi_{\mathfrak m_2}^*B-v\pi_{\mathfrak m_4}^*B \end{align*} holds for some $u,v>0$. By~\eqref{hat_S_formula}, \begin{align*} \hat S(h)=\frac{18}{2u}+\frac6{2v}-\frac{[211]}{2u}-\frac{[213]}u-\frac{[413]}v-\frac{[224]v}{4u^2}-\frac{[224]}{2v} =\frac7u+\frac4{3v}-\frac v{2u^2}. \end{align*} If $h\in\mathcal M_T(\mathfrak t_3)$, then \begin{align}\label{lasttag3} \tr_hT|_{\mathfrak t_3\ominus\mathfrak h}=\frac{18z_2}u+\frac{6z_4}v=1,\qquad u=\frac{18vz_2}{v-6z_4},\qquad v>6z_4. \end{align} In this case, $\hat S(h)=\psi_{z_2,z_4}(v)$ with the function $\psi_{z_2,z_4}:(6z_4,\infty)\to\mathbb R$ defined by \begin{align*} \psi_{z_2,z_4}(x)=\frac{7(x-6z_4)}{18xz_2}+\frac4{3x}-\frac{(x-6z_4)^2}{648xz_2^2}. \end{align*} Consequently, \begin{align}\label{lasttag4} \sigma(\mathfrak t_3,T)=\sup\{\hat S(h)\,|\,h\in\mathcal M_T(\mathfrak t_3)\}=\sup\{\psi_{z_2,z_4}(v)\,|\,v>6z_4\}. \end{align} A straightforward computation shows that \begin{align*} \frac d{dv}\psi_{z_2,z_4}(v)=\frac1{3v^2}\Big(\frac{z_4^2}{6z_2^2}+\frac{7z_4}{z_2}-4\Big)-\frac1{648z_2^2}. \end{align*} If $z_2/z_4\ge7/4$, then $\frac d{dv}\psi_{z_2,z_4}(v)<0$ for all $v>6z_4$. In this case, since the function $\psi_{z_2,z_4}$ does not have a global maximum on $(6z_4,\infty)$, the supremum of $\hat S$ over $\mathcal M_T(\mathfrak t_3)$ is not attained. As a consequence, $\mathfrak t_3$~fails to satisfy requirement~2 of Definition~\ref{def_T-apical}. Also, \begin{align*} \sigma(\mathfrak t_3,T)=\lim_{v\to6z_4}\psi_{z_2,z_4}(v)=\frac2{9z_4}. \end{align*} If $z_2/z_4<7/4$, then $\psi_{z_2,z_4}$ attains its global maximum at the point \begin{align*} v_0=6\sqrt{z_4^2+42z_2z_4-24z_2^2}. \end{align*} Define $h_0\in\mathcal M(\mathfrak t_3)$ by the formula \begin{align*} h_0=-\frac{18v_0z_2}{v_0-6z_4}\pi_{\mathfrak m_2}^*B-v_0\pi_{\mathfrak m_4}^*B. \end{align*} Recalling~\eqref{lasttag3} and~\eqref{lasttag4}, we conclude that $h_0$ lies in $\mathcal M_T(\mathfrak t_3)$ and \begin{align*} \hat S(h_0)=\psi_{z_1,z_2}(v_0)=\sigma(\mathfrak t_3,T). \end{align*} Thus, $\mathfrak t_3$ satisfies requirement~2 of Definition~\ref{def_T-apical}. Also, \begin{align*} \sigma(\mathfrak t_3,T)=\psi_{z_2,z_4}(v_0)=\psi(z_2,z_4) \end{align*} with the function $\psi:\{(x,y)\in(0,\infty)^2\,|\,x<7y/4\}\to\mathbb R$ given by \begin{align*} \psi(x,y)= \frac7{18x}-\frac{\sqrt{y^2+42xy-24x^2}-y}{54x^2}. \end{align*} We are now ready to apply the results of Section~\ref{sec_gen_results}. If the inequalities \begin{align}\label{cond01F4} z_2/z_4\ge7/4,\qquad z_3/z_4\le3/8, \end{align} or the inequalities \begin{align}\label{cond11F4} z_2/z_4<7/4,\qquad 1/z_3\ge12\psi(z_2,z_4), \end{align} hold, then $\sigma(\mathfrak t_1,T)\ge\sigma(\mathfrak t_3,T).$ In this case, $\mathfrak t_1$ meets requirement~3 of Definition~\ref{def_T-apical}, which means $\mathfrak t_1$ is $T$-apical. According to Theorem~\ref{thm_gen} and formula~\eqref{cond_str_const}, a Riemannian metric with Ricci curvature $cT$ exists for some $c>0$ provided that \begin{align}\label{suff_F4_1} 2z_1+3z_2+z_4<30z_3. \end{align} If \begin{align}\label{cond02F4} z_2/z_4\ge7/4,\qquad z_3/z_4\ge3/8, \end{align} then \begin{align*} \sigma(\mathfrak t_2,T)=\sigma(\mathfrak t_3,T)\ge\sigma(\mathfrak t_1,T). \end{align*} In this case, $\mathfrak t_2$ is $T$-apical. By Theorem~\ref{thm_gen} and formula~\eqref{cond_str_const}, a metric with Ricci curvature $cT$ exists for some $c>0$ provided that \begin{align}\label{suff_F4_2} 12z_1+18z_2+4z_3<63z_4. \end{align} Finally, if \begin{align}\label{cond22F4} z_2/z_4<7/4,\qquad 1/z_3\le12\psi(z_2,z_4), \end{align} then $\sigma(\mathfrak t_3,T)\ge\sigma(\mathfrak t_1,T)$. In this situation, $\mathfrak t_3$ is $T$-apical. A metric with Ricci curvature $cT$ exists for some $c>0$ as long as \begin{align}\label{suff_F4_3} (3z_1+z_3)\psi(z_2,z_4)<2. \end{align} \end{example} \begin{remark} In Example~\ref{example_F4}, if $z_2/z_4\ge7/4$, one may use Lemma~\ref{lem_key_apic_ex} rather than a direct computation to find $\sigma(\mathfrak t_3,T)$. Indeed, the generalised flag manifold $F_4/SU(3)\times SU(2)\times U(1)$ satisfies Hypothesis~\ref{hyp_strong}. According to Lemma~\ref{lem_key_apic_ex}, there exists a Lie subalgebra $\mathfrak k$ of $\mathfrak t_3$ such that formulas~\eqref{apic_ex_flas} hold with some $h\in\mathcal M_T(\mathfrak k)$ and $\mathfrak s=\mathfrak t_3$. If $z_2/z_4\ge7/4$, then the supremum of $\hat S$ over $\mathcal M_T(\mathfrak t_3)$ is not attained and $\mathfrak k$ cannot equal~$\mathfrak t_3$. In this case, $\mathfrak k=\mathfrak t_2$ and $\sigma(\mathfrak t_2,T)\ge\sigma(\mathfrak t_3,T)$. On the other hand, Remark~\ref{rem_sigma_subalg} implies $\sigma(\mathfrak t_2,T)\le\sigma(\mathfrak t_3,T)$. Thus, \begin{align*} \sigma(\mathfrak t_2,T)=\sigma(\mathfrak t_3,T)=\frac2{9z_4}. \end{align*} \end{remark} \begin{remark}\label{rem_compar2} Let $M$ be the generalised flag manifold $F_4/SU(3)\times SU(2)\times U(1)$ as in Example~\ref{example_F4}. Assume the decomposition~\eqref{m_decomp} is as in~\cite{AAIC10}. If $T$ is given by~\eqref{T_gen_fl_F4}, the main result of~\cite{MGAP17} implies that a metric with Ricci curvature $cT$ exists for some $c>0$ provided that \begin{align}\label{cond_F4_MGAP} \frac{z_4}{z_2}>\frac47,\qquad \frac{z_3}{2z_1+3z_2+z_4}>\frac1{30}, \qquad \frac{\min\{z_2,z_4\}}{3z_1+z_3}>\frac{47}{72}. \end{align} This condition is more restrictive than the one given by Theorem~\ref{thm_gen}. Indeed, suppose $z_2/z_4\ge7/4$. According to Theorem~\ref{thm_gen}, a metric with Ricci curvature $cT$ exists for some $c>0$ as long as~\eqref{cond01F4} and~\eqref{suff_F4_1} or~\eqref{cond02F4} and~\eqref{suff_F4_2} are satisfied, as explained in Example~\ref{example_F4}. However, inequalities~\eqref{cond_F4_MGAP} fail to hold. Next, suppose $z_2/z_4<7/4$. By Theorem~\ref{thm_gen}, a metric with Ricci curvature $cT$ exists for some $c>0$ as long as~\eqref{cond11F4} and~\eqref{suff_F4_1} or~\eqref{cond22F4} and~\eqref{suff_F4_3} are satisfied, as shown in Example~\ref{example_F4}. One can derive both~\eqref{suff_F4_1} and~\eqref{suff_F4_3} from~\eqref{cond_F4_MGAP}. At the same time,~\eqref{cond22F4} and~\eqref{suff_F4_3} hold if, for instance, \begin{align*} z_2=z_3=z_4,\qquad z_1\in\bigg[\frac{25z_2}{141},\frac{(637+36\sqrt{19})z_2}{465}\bigg). \end{align*} However, such $z_1$, $z_2$, $z_3$ and $z_4$ do not satisfy~\eqref{cond_F4_MGAP}. \end{remark} \section*{Acknowledgement} I am grateful to Andreas Arvanitoyeorgos and Marina Statha for suggesting that I consider the prescribed Ricci curvature problem on generalised Wallach spaces.
\section{Introduction} It is well-known that the CMB anisotropy power spectrum gives us very valuable information about our universe. It is also well-known that the scale-invariance in primordial universe implies that $C_l l(l+1)$ is a constant for low $l$. However, it turns out that $C_l$ is severely suppressed for $l=2$. This could be due to a big cosmic variance, but it could be due to another effect. In this article, we will consider a closed universe. Under such a consideration, our universe is necessarily 3-sphere. In the analysis of CMB anisotropy, only the spherical harmonics of 2-sphere have been considered so far. However, as we will see in this article, considering the spherical harmonics of 3-sphere gives differences to the CMB anisotropy spectrum, even though only for low $l$. In particular, we succeeded in lowering $C_2$, even though not as low as the observed value, implying that the cosmic variance still plays a role, albeit to a less extent. The organization of this article is as follows. In Section 2, we review the spherical harmonics for 3-sphere. In Section 3, we review how the traditional CMB anisotropy analysis is done by using the spherical harmonics for 2-sphere. The aim is to set a comparison with the case of 3-sphere in Section 4. In Section 4, we derive the CMB anisotropy using the spherical harmonics of 3-sphere. This section is the main part of this paper. In particular, we show that for large $l$, we recover the usual scaling law $C_l l(l+1)=\mathrm{const}$. In Section 5, we use data analysis to obtain the radial distance of the last scattering surface. In particular, we will see that it agrees with the one obtained earlier by another method. \section{Spherical harmonics for 3-sphere} The spherical harmonics on 3-sphere is given by \begin{equation} \nabla^2 Y_{qlm}(\chi, \theta,\phi)=-q(q+2)Y_{qlm}(\chi, \theta,\phi) \end{equation} where $q$ is a non-negative integer and $l$ runs from 0 to $q$ and $m$ runs from $-l$ to $l$. Of course, we can write \begin{equation} Y_{qlm}(\chi,\theta,\phi)=X_{ql}(\chi)Y_{lm}(\theta,\phi) \end{equation} for a suitable $X_{ql}$. Given $q$, there is a degeneracy of $(q+1)^2$, as \begin{equation} \sum_{l=0}^{q}\sum_{m=-l}^{l}1=\sum_{l=0}^q (2l+1)=(q+1)^2\label{2l+1q+1^2} \end{equation} For our purpose, the following relation is important (see \cite{3sphere}, for example) \begin{equation} \sum_{lm} Y_{qlm}(\vec u)Y_{qlm}(\vec v)=\frac{q+1}{2\pi^2} U_q(\vec u\cdot \vec v)\label{q+1Uq} \end{equation} where $U_q$ is Chebyshev polynomials of the second kind, i.e., \begin{equation} U_q(\cos\theta)=\frac{\sin(q+1)\theta}{\sin\theta} \end{equation} and $\vec u$ are $\vec v$ are 4-d unit vectors in unit 3-sphere. \section{Traditional spherical harmonics analysis in CMB anisotropy} This section is important to set a comparison with our application of spherical harmonics for 3-sphere. \begin{equation} \Delta T(\hat n)=\sum_{lm} a_{lm} Y_l^m(\hat n),\qquad C_l\equiv\langle|a_{lm}|^2\rangle \end{equation} \begin{equation} \langle\Delta T(\hat n)\Delta T(\hat n')\rangle=\sum_{lm} C_l Y_l^m(\hat n)Y_l^{-m}(\hat n')=\sum_l C_l\left(\frac{2l+1}{4\pi}\right) P_l(\hat n\cdot\hat n')\label{Cl2l+1Pl} \end{equation} Then, using \begin{equation} \int d\Omega_{\hat k} P_l(\hat n \cdot \hat k) P_{l'}(\hat n'\cdot \hat k)=\frac{4\pi}{2l+1} P_l(\hat n\cdot \hat n')\delta_{ll'}\label{PP} \end{equation} $C_l$ can be obtained by \begin{equation} C_l=\frac{1}{4\pi}\int d^2\hat n d^2\hat n'\, P_l(\hat n \cdot \hat n')\langle\Delta T(\hat n)\Delta T(\hat n')\rangle \end{equation} In particular, when Sachs-Wolfe approximation is valid, we can write \begin{equation} \frac{\Delta T(\hat n)}{T}=-\frac 15 \mathcal R (\hat n r_L) \end{equation} where $\mathcal R$ is the primordial curvature perturbation, and $r_L$ is the radial coordinate of the last scattering surface. When $\mathcal R$ satisfies approximate scale invariance, as widely believed, we have \begin{equation} \langle \mathcal R(\lambda \vec x)\mathcal R(\lambda \vec y)\rangle=\langle \mathcal R(\vec x)\mathcal R(\vec y)\rangle \end{equation} in which case we have \begin{equation} C_l=\frac{\mathrm{const}}{l(l+1)} \end{equation} \section{3d-spherical harmonics in CMB anisotropy} Let's re-write (\ref{q+1Uq}) as \begin{equation} \sum_{lm} Y_{qlm}(\vec u)Y_{qlm}(\vec v)=\frac{(q+1)^2}{2\pi^2} \left(\frac{U_q(\cos\theta)}{q+1}\right)=\frac{(q+1)^2}{2\pi^2} \left(\frac{\sin(q+1)\theta}{(q+1)\sin\theta}\right) \end{equation} where $\cos\theta\equiv \vec u\cdot \vec v$. Then, we can write \begin{equation} \langle \Delta T(\hat n) \Delta T(\hat n')\rangle=\sum_q C_q\frac{(q+1)^2}{2\pi^2}\left(\frac{\sin(q+1)\theta}{(q+1)\sin\theta}\right),\qquad C_q\equiv \langle|a_{qlm}|^2\rangle\label{TT3sphere} \end{equation} where $\cos\theta$ is the dot product between $\hat n$ and $\hat n'$ in 3-sphere. Here, by an abuse of notation, we denoted the average of $|a_{qlm}|^2$ as $C_q$; this is not the same one as $C_l$. Now, let's compare this with (\ref{Cl2l+1Pl}). For $\hat n\cdot \hat n'=\cos \theta_{nn'}$, and $\theta_{nn'}$ small, the right-hand side of (\ref{Cl2l+1Pl}) can be expanded as \begin{equation} C_l \frac{2l+1}{4\pi} \left(1-\frac{l(l+1)}{4}\theta_{nn'}^2\right) \end{equation} In case of (\ref{TT3sphere}) for $\theta$ small, we have \begin{equation} C_q \frac{(q+1)^2}{2\pi^2} \left(1-\frac{q(q+2)}{6}\theta^2\right) \end{equation} Thus, we see that they indeed have the similar structure. $C_l$ is replaced by $C_q$, the degeneracy $(2l+1)$ is replaced by $(q+1)^2$, the leading term in the parenthesis is both 1, and the coefficients for $\theta_{nn'}^2$ and $\theta^2$ are both proportional to the eigenvalues for the Laplacian. From this reason, we expressed (\ref{TT3sphere}) by pulling out the factor $(q+1)^2$ to the front, instead of the original expression $C_q(q+1)U_q(\cos\theta)/(2\pi^2)$. Analogous to (\ref{PP}), we have (when $\hat n=\hat n'$) \begin{equation} \int_{0}^{\pi}\left(\frac{U_q(\cos\theta)}{q+1}\right)\left(\frac{U_q'(\cos\theta)}{q'+1}\right)\sin^2\theta d\theta\int d\Omega=\frac{2\pi^2}{(q+1)^2}\delta_{qq'}\label{UU} \end{equation} In 2-sphere case, we used (\ref{PP}) to obtain $C_l$. However, in 3-sphere case, we shall not use (\ref{UU}), because what we want to obtain is $C_l$ not $C_q$. Moreover, the integration range of (\ref{UU}) is not the subdomain 2-sphere, but the whole 3-sphere, as we can see from the measure $\sin^2\theta d\theta d\Omega$. In other words, we still need to use (\ref{UU}), but only if the integration range is properly considered. As we have \begin{equation} \cos\theta=\cos^2\chi+\sin^2\chi \hat n\cdot \hat n' \end{equation} the integration range is \begin{equation} \cos 2\chi\leq \cos \theta \leq 1\qquad\longrightarrow \qquad0\leq \theta \leq 2\chi \end{equation} Thus to obtain $C_l$, we have \begin{eqnarray} C_l(2l+1)&=&\sum_{q=l}^{\infty} C_q \frac{(q+1)^2}{2\pi^2}\int_{\cos\theta=\cos2\chi}^{\cos\theta=1} \left(\frac{U_q(\cos\theta)}{q+1}\right)^2\sin^2\theta d\theta \\ &=&\sum_{q=l}^\infty \frac{C_q}{2\pi^2}\int_{0}^{2\chi} d\theta\, \sin^2(q+1)\theta \end{eqnarray} The range for the infinite sum comes from the fact that, for a given $l$, the possible $q$ runs from $l$ to $\infty$. The $(2l+1)$ term in the left-hand side comes from the fact that there is a degeneracy of $(2l+1)$ for a given $l$. In other words, we have $(2l+1)$ factor on the left-hand side and $(q+1)^2$ factor on the right-hand side as expected from (\ref{2l+1q+1^2}). Now, we need to find $C_q$. Recall that the Lagrangian for $\mathcal R$ in inflation is given by \begin{equation} S_2=\frac 12 \int d^3x dt\, 2a^3 \varepsilon \left((\partial_t\mathcal R)^2-\frac{(\partial_i \mathcal R)^2}{a^2}\right),\qquad \varepsilon\equiv -\frac{\dot H}{H^2} \end{equation} Considering that $\mathcal R$ is conserved, $\partial_t \mathcal R$ is zero. Thus, \begin{equation} \nabla^2_x\langle \mathcal R(x) \mathcal R(y)\rangle=\frac{1}{2a\varepsilon} \delta^3(x-y) \end{equation} Therefore, the two-point function of Fourier mode is given by the inverse of the Laplacian. As the eigenvalues of Laplacian is proportional to $q(q+2)$, we conclude $C_q$ is proportional to $1/(q(q+2))$. Thus, we have \begin{eqnarray} C_l(2l+1)&=&2C \sum_{q=l}^{\infty} \frac{1}{q(q+2)}\left(\chi-\frac{\sin(4(q+1)\chi)}{4(q+1)}\right)\\ &=&C\chi \left(\frac{(2l+1)}{l(l+1)}-\frac {1}{2\chi} \sum_{q=l}^\infty \frac{\sin(4(q+1)\chi)}{q(q+1)(q+2)}\right)\label{Cchi} \end{eqnarray} for some constant $C$. Here, we see that $C_l$ is roughly proportional to $1/(l(l+1))$ from the first term. The second term rapidly converges to zero for higher $l$, not only because there are fewer terms to add (even though there are infinite terms to do so), but also because the sine function is oscillating. \section{Data analysis} Let's set the notation. We have \begin{equation} \chi=\sqrt{\Omega_{\mathrm{tot}}-1}\int_{1/(1+z_L)}^1\frac{da}{a^2\sqrt{\Omega_{\Lambda}-(\Omega_{\mathrm{tot}}-1)a^{-2}+\Omega_M a^{-3}}},\qquad r_L=\sin \chi \end{equation} where we ignored the contribution from the radiation. We use $\Omega_M=\Omega_{\mathrm{tot}}-\Omega_\Lambda$. To calculate $\chi$, we use the data in \cite{Jarosik}. For \emph{WMAP}+BAO+$H_0$, they obtained \begin{equation} \Omega_{\mathrm{tot}}=1.0023^{+ 0.0056}_{- 0.0054},\quad \Omega_\Lambda=0.728^{+0.015}_{-0.016},\quad z_L=1090.89^{+ 0.68}_{- 0.69} \end{equation} which yields \begin{equation} \chi=0.16^{+0.14}_{-0.16}\label{chiwmap} \end{equation} For CMB anisotropy data, we used \cite{CMB Data}. As the present author does not know well about statistics and data processing, we tried to find the best fit $\chi$ by trial and error. First, we defined $D_l\equiv C_l\cdot l(l+1)$ and obtained the value for \begin{equation} \lim_{l\to \infty} D_l=D \end{equation} by averaging from $l=2$ to 29, which we got 851. (If we use the notation of (\ref{Cchi}), we have $D=C\chi$.) Then, we tried to minimize \begin{equation} \frac{(a_{\mathrm{obs}}-a_{\mathrm{th}})^2}{\sigma_a^2}+\frac{(b_{\mathrm{obs}}-b_{\mathrm{th}})^2}{\sigma_b^2}+\frac{(c_{\mathrm{obs}}-c_{\mathrm{th}})^2}{\sigma_c^2}\label{abc} \end{equation} where ``obs'' denotes observed value, and ``th'' denotes theoretical value, and \begin{equation} a=C_2\cdot 2\cdot 3,\qquad b=C_3 \cdot 3\cdot 4,\qquad c=\frac{(C_4\cdot 4\cdot 5)+(C_5\cdot 5\cdot 6)}{2} \end{equation} $\sigma$s are also in the Table 1. We found that $\chi=0.14$ minimizes (\ref{abc}). Then, as you can see from \cite{CMB Data}, $l=2$ is suppressed while $l=5$ is augmented. This is true for $\chi=0.11$ to 0.23. Therefore, our conclusion is $\chi=0.14^{+0.09}_{-0.03}$ which agrees with (\ref{chiwmap}). \begin{table} \caption{$D_l(\chi)$} \centering \begin{tabular}{|l|l|l|l|l|l|} \hline $l$ & $D_{l\mathrm{obs}}$ & $D_{l\mathrm{th}}(0.11)$& $D_{l\mathrm{th}}(0.14)$ & $D_{l\mathrm{th}}(0.16)$ & $\sigma_{D_l}$ \\ \hline 2 & 150 & 562& 664 & 721 & 708 \\ 3 & 902 & 705 & 800 & 844 & 565 \\ 4.5 & 1099 & 833 & 887 & 899 & 312 \\ \hline \end{tabular} \end{table} \section{Discussions and Conclusions} In this article, we examined the CMB anisotropy power spectrum by a novel approach, and found an agreement with the earlier analysis. Future work should consider other effects, going beyond the scale invariant primordial universe. \begin{center} {\Large\bf Acknowledgments} \end{center} I thank Donghui Jeong for help.
\section{Introduction} Understanding the nonequilibrium dynamics of quantum many body systems has become one of the central goals of physics in recent years~\cite{polkovnikov2011nonequilibrium,*gogolin2016equilibration,*dalessio2016quantum,*essler2016quench,*calabrese2016quantum,*cazalilla2016quantum,*bernard2016conformal,*caux2016quench,*vidmar2016generalized,*langen2016prethermalization,*ilievski2016quasilocal,*vasseur2016nonequilibrium,*deluca2016equilibration}. This has been motivated by groundbreaking progress in experiments on cold atomic gases~\cite{weiss2006quantum,*lewenstein2007ultracold}, which realized unprecedented control and isolation of quantum systems. Experiments have highlighted a lack of understanding of fundamental issues, such as thermalization: How and when does a quantum system thermalize? What does thermalization mean in an isolated quantum system undergoing unitary time evolution? The eigenstate thermalization hypothesis (ETH)~\cite{deutsch1991quantum,srednicki1994chaos,rigol2008thermalization,*rigol2009breakdown,rigol2012alternatives,reimann2015eigenstate,deutsch2018eigenstate} plays a central role in answering such questions. It states conditions that matrix elements of an operator $\hat A$ must satisfy in order for its expectation value on an eigenstate to agree with the microcanonical (thermal) prediction. These conditions can be summarized as \begin{align} \hat A_{\alpha,\beta} = A(E) \delta_{\alpha,\beta} + e^{-S(E)/2}f_A(E,\omega) R_{\alpha,\beta}, \label{eth} \end{align} where $\hat A_{\alpha,\beta} = \langle E_\beta | \hat A | E_\alpha\rangle$ are matrix elements in the basis of eigenstates $|E_\alpha\rangle$, $E = (E_\alpha + E_\beta)/2$ and $\omega = E_\alpha-E_\beta$. ETH tells us that the diagonal matrix elements $\hat A_{\alpha,\alpha}$ are controlled by a smooth function $A(E)$.~\footnote{For neighboring energy eigenvalues $E$ and $E'$ ($E'>E$) this function satisfies $A(E')-A(E) \propto e^{-R/\tilde R}$, with $R$ being the system size and $\tilde R$ being some (possibly $E$-dependent) constant.} The off-diagonal elements are suppressed by the thermodynamic entropy $S(E)$ and depend on both a smooth function $f_A(E,\omega)$ and the random variable $R_{\alpha,\beta}$, which has zero mean and unit variance. It is generally assumed that generic quantum many body systems satisfy ETH, in the sense that matrix elements of local observables obey Eq.~\eqref{eth} and hence expectation values are thermal (see, e.g., the brief argument of Ref.~\cite{mondaini2017eigenstate}). It is, however, known that generic finite size systems \textit{can} have rare (nonthermal) eigenstates which violate ETH~\cite{biroli2010effect,santos2010localization,santos2010onset}. Such states are often called nontypical, see Ref.~\cite{richter2018realtime} for a recent example. The presence of rare states in the finite volume leads to two interpretations of ETH. The so-called \textit{``weak ETH''} supposes that the fraction of rare to thermal states vanishes in the infinite volume limit. Weak ETH is not sufficient to imply thermalization: such a scenario applies to integrable models~\cite{biroli2010effect,ikeda2013finitesize,alba2015eigenstate} where thermalization is avoided due to the presence of an extensive number of local conservation laws. On the other hand, the \textit{``strong ETH''} postulates that all rare states must vanish in the infinite volume. This much stronger condition then implies thermalization, with expectation values of local operators coinciding with the microcanonical ensemble (MCE) average. In nonequilibrium scenarios, such as following a quantum quench, thermalization is signaled by the diagonal ensemble (DE) prediction agreeing with the MCE constructed at the appropriate energy density~\cite{rigol2008thermalization,rigol2009breakdown}. Distinguishing the weak and strong ETH scenarios is a challenging problem for state-of-the-art numerical methods. Evidence for the weak ETH has been seen in many nonintegrable systems, primarily through exact diagonalization of small systems~\cite{santos2010localization,santos2010onset,khlebnikov2013thermalization,ikeda2013finitesize,beugeling2014finitesize,sorg2014relaxation,khodja2015relevance,cosme2015relaxation,mondaini2016eigenstate,lan2017eigenstate,mondaini2017eigenstate,lan2017eigenstate}. Generally the rare states are observed at the very edges of the spectrum, which is not entirely surprising with many cases of low energy emergent integrability being known (see, e.g., Ref.~\cite{essler2005applications}). Evidence consistent with strong ETH, on the other hand, is less well established. Numerical studies of lattice hardcore bosons with next-neighbor and next-next-neighbor interactions, as well as the quantum Ising chain with certain values of transverse and longitudinal fields, suggest that it is valid in some contexts~\cite{kim2014testing}. In the context of weak ETH, there are some cases where the nonthermal rare eigenstates are found away from the very edges of the spectrum. Firstly, in the case of AKLT-like models, certain eigenstates with finite energy density can be represented exactly as matrix product states and shown to be nonthermal (through, e.g., the nonthermal entanglement entropies associated with such states)~\cite{moudgalya2018exact,moudgalya2018entanglement}. Another scenario, so-called many-body quantum scars, arises in models that are associated with one-dimensional Rydberg gases~\cite{bernien2017probing}. These models have been seen to have a polynomial-in-the-system-size number of nonthermal states which are distributed throughout the many-body spectrum of the model~\cite{turner2017quantum,khemani2018signatures,ho2018periodic,lin2018exact,turner2018quantum,choi2018emergent}. There are also examples of nonthermal behavior in nonintegrable models with constrained dynamics, which includes the aforementioned models of Rydberg atoms and quantum dimer models~\cite{ates2012thermalization,ji2013equilibration,vanhorssen2015dynamics,lan2018quantum}, and models with long-range interactions~\cite{liu2018confined,lerose2019quasilocalized}. One significant issue in studying ETH is the lack of available techniques. Almost all studies are confined to the exact diagonalization of small systems ($L \lesssim 20$ sites), which results in large finite size effects. This makes it hard to extrapolate results to the infinite volume and hence make concrete statements about strong or weak ETH. Some progress has been made in the last few years using tools from typicality~\cite{steinigeweg2014pushing,bartsch2017necessity,richter2018realtime}, with which one can push to slightly larger system sizes ($L\lesssim 35$). Other techniques that can compute real-time dynamics (such as time evolving block decimation and related algorithms~\cite{kollath2007quench,manmana2007strongly,trotzky2012probing,sorg2014relaxation,james2015quantum,james2018nonperturbative}; numerical renormalization group~\cite{brandino2015glimmers}; equations of motion~\cite{moeckel2008interaction,moeckel2009realtime,eckstein2009new,essler2014quench,nessi2014equations,nessi2015glasslike,bertini2015prethermalization,bertini2016thermalization}; and Boltzmann equations~\cite{moeckel2008interaction,moeckel2009realtime,bertini2015prethermalization,bertini2016thermalization,furst2012matrixvalued,furst2013matrixvalued,biebl2017thermalization}) allow one to establish whether expectation values of operators approach their thermal values following a quench from a given state, but have little to say about ETH. With this in mind, it is desirable to develop techniques that can study system sizes beyond those accessible to exact diagonalization, or in scenarios that exact (full) diagonalization cannot study. Here, to investigate thermalization and the validity of ETH in a large non-integrable system---in both equilibrium and nonequilibrium scenarios---we focus on a \textit{continuum model} and use recently developed extensions of the truncated spectrum method~\cite{rakovsky2016hamiltonian,james2018nonperturbative}. We will see that these results are consistent with the lattice simulations away from the scaling limit. Before introducing the model that we study herein, it would be remiss of us not to mention another example in which ETH is violated: many body localization. Many body localization can arise in interacting disordered models, as shown in the seminal work of Basko, Aleiner and Altshuler~\cite{basko2006metal} (see also the recent review articles~\cite{imbrie2017local,parameswaran2017eigenstate,agarwal2017rareregion,deng2017manybody,abanin2017recent,alet2018manybody}). Much like the scenarios discussed above, study of such models is almost entirely restricted to exact diagonalization (we note the exception of excited state DMRG~\cite{khemani2016obtaining,yu2017finding}), where violation of ETH has been established for numerous examples (see, e.g., Ref.~\cite{alet2018manybody} and references therein). The violation of ETH reflects an emergent integrability in the localized phase, with models possessing an extensive number of local conserved quantities~\cite{imbrie2016manybody,imbrie2017local}. \subsection{Rare states in the perturbed Ising field theory} In this paper we will argue that the perturbed Ising field theory possesses rare states. This model, which arises as the continuum limit of the quantum Ising chain~\cite{mccoy1978twodimension,sachdev2011quantum}, is described by the Hamiltonian \begin{align} H(m,g) = \int {\rm d} x \Big[ i \Big( \bar \psi \partial_x \bar \psi - \psi \partial_x \psi + m\bar \psi \psi\Big) + g \sigma \Big]. \label{FT} \end{align} Here $\psi$ ($\bar \psi$) is a left (right) moving Majorana fermion field, $m$ is the fermion mass, and $g$ is equivalent to a longitudinal field in the lattice model. In the ordered phase, the fermions can (loosely) be thought of as domain wall excitations in the ferromagnetic spin configuration. The longitudinal field $g$ acts as a \textit{nonlocal} confining potential for the domain walls~\cite{mccoy1978twodimension}. While the field theory is nonintegrable for generic values of the parameters $m$ and $g$, there exist two special lines in parameter space ($m=0$ and $g=0$) along which the model is integrable~\cite{onsager1944crystal,zamolodchikov1989integrals}. Herein we will mostly focus on the ordered phase of the model, corresponding to $m>0$. Within this phase, the spectrum of the model depends intimately on the longitudinal field: when $g=0$ a flipped spin fractionalizes into two independent domain walls, which can freely propagate though the system. Thus at low energies, when $g=0$, there is a two particle continuum of excitations, separated from the ground state by an energy gap of $2m$. On the other hand, when $g\neq 0$ there are profound changes in the spectrum. The presence of the longitudinal field, which is nonlocal in terms of the domain wall fermions, induces a linear potential between domain wall excitations, leading to confinement~\cite{mccoy1978twodimension,delfino1996nonintegrable,delfino1998nonintegrable}. This is very much reminiscent of the formation of mesons in quantum chromodynamics (analogies between magnetic systems and quantum chromodynamics have recently been emphasized in Ref.~\cite{sulejmanpasic2017confinement}). The low energy spectrum now completely restructures: the two domain wall continuum at $g=0$ collapses into well-defined meson excitations for $g\neq 0$, with a new multimeson continuum forming above energies $E\sim4m$. We sketch this schematically in Fig.~\ref{Fig:Spectrum}. We note that this restructuring of the continuum has been observed in the quasi-one-dimensional Ising ferromagnet CoNb$_2$O$_6$~\cite{coldea2010quantum,morris2014hierarchy} and the XXZ antiferromagnet SrCo$_{2}$V$_{2}$O$_{8}$~\cite{wang2015spinon,wang2016from}. \begin{figure}[t] \includegraphics[width=0.45\textwidth]{spectrum.png} \caption{Schematic of the low energy spectrum of the Ising field theory~\eqref{FT}. The longitudinal field $g$ leads to a complete restructuring of the low energy continuum (shaded) and the appearance of confined `meson' states (solid lines).} \label{Fig:Spectrum} \end{figure} Working directly with a continuum theory might, at first glance, seem more difficult than working on the lattice. However, we will see that low energy eigenstates of the Hamiltonian~\eqref{FT} can be constructed, and are representative of the behavior in the infinite volume limit. We will do so using truncated spectrum methods~\cite{james2018nonperturbative}, a well-established toolbox in the study of the Ising field theory~\eqref{FT}. One question that it is natural to ask before starting is: What is the status of ETH in a field theory? Is it expected to hold? Here one can turn to the original work of Deutsch~\cite{deutsch1991quantum}, which explicitly considered a continuum model and argued that it would be expected to thermalize. Srednicki's later paper~\cite{srednicki1994chaos} considered a continuum system with a bounded spectrum, i.e. the theory is equipped with a cutoff. We will see that expectation values of local operators in the vast majority of low energy eigenstates of~\eqref{FT} exhibit features consistent with ETH, while there are a subset of rare states that appear to violate it. With regards to ETH in~\eqref{FT}, there is one additional point worth noting. We can split the Hamiltonian~\eqref{FT} into two pieces: a noninteracting part $H(m,0)$ and an interaction term $g\int {\rm d} x \sigma(x)$. The interaction term is strongly renormalization group relevant, with the scaling dimension of the operator $\sigma$ being $1/8$. Defining the theory with an explicit cutoff $\Lambda$ and performing a weak-coupling ($g \ll 1$) renormalization group analysis, the interaction strength $g(\Lambda)$ flows to zero in the ultraviolet $\Lambda \to \infty$. As a result, the high energy eigenstates of the theory~\eqref{FT} should correspond to noninteracting ($g=0$) eigenstates. Concomitantly the high energy sector of the theory~\eqref{FT} has an emergent integrability and hence we should not expect ETH to be valid there. Hence we will concentrate our efforts on the low energy sector, where the interaction term has a strong effect, and ask whether ETH is valid in this subspace. This work complements results presented by the authors in Ref.~\cite{james2018nonthermal}, in particular extending the one-dimensional aspect of that work. \subsection{Layout} This work proceeds as follows. In Sec.~\ref{Sec:RareStates}, we examine the matrix elements of the local spin operator between eigenstates constructed with truncated spectrum methods. We will see clear signatures of rare states that exist in the low energy spectrum of the field theory~\eqref{FT}. We discuss ETH and behavior of these rare states with increasing system size. In Sec.~\ref{Sec:Nature} we establish the nature of the rare states, relating them to the two-fermion ``meson'' confined states of the model. We study the lifetime of the meson excitations to understand their stability and influence on ETH in the infinite volume limit. Following this, in Sec.~\ref{Sec:Dynamics} we turn our attention to the nonequilibrium dynamics following a quench of the longitudinal field strength $g$. The rare states established in the equilibrium spectrum will also be apparent in the DE, signaling a lack of thermalization after certain quenches. In Sec.~\ref{Sec:Lattice} we relate our work to the analogous lattice problem and discuss the presence of rare states there, comparing the finite size scaling analysis on the lattice with that in the continuum. We follow with our conclusions in Sec.~\ref{Sec:Conclusions} and cover a number of technical points in the appendices. \section{Testing ETH in a theory with confinement} \label{Sec:RareStates} In order to test ETH within the field theory~\eqref{FT}, we must be able to construct eigenstates. We do so using truncated spectrum methods, which we briefly summarize below. A detailed overview of the technique can be found in the recent review~\cite{james2018nonperturbative}. \subsection{Truncated spectrum methods} \subsubsection{General philosophy} Truncated spectrum methods (TSMs) are a general approach to treating certain classes of field theory problem~\cite{james2018nonperturbative}. The best known is the truncated conformal space approach (TCSA)~\cite{yurov1990truncated,james2018nonperturbative}, where the Hamiltonian can be written in the following form: \begin{align} H = H_{\rm CFT} + V. \label{tcsa} \end{align} Here the first part of the Hamiltonian, $H_{\rm CFT}$, describes a conformal field theory (CFT)~\cite{BigYellowBook}, while $V$ is a renormalization group relevant, but otherwise arbitrary, operator. The central idea of TSMs is to use the eigenstates of a `known' theory (the CFT in Eq.~\eqref{tcsa}) as a computational basis for constructing the full Hamiltonian~\eqref{tcsa}. The presence of a relevant operator, $V$, leads to a strong mixing of the low-energy computational basis states. This ultimately leads to a failure in any perturbative treatment -- requiring instead a nonperturbative approach. The TSM is one such method: using the fact that $V$ does \textit{not} strongly couple basis states of largely differing energies, one motivates a truncation of the Hilbert space of basis states through the introduction of an energy cutoff $E_\Lambda$. For low energy eigenstates of $H$ this is a reasonable approximation. To obtain a finite spectrum, even with an energy cutoff $E_\Lambda$, one must then place the system in a finite volume $R$. Subsequently one diagonalizes the (finite) Hamiltonian to obtain approximate energies and eigenvectors of the full problem~\eqref{tcsa}. More generally, the TSM can be applied to problems of the form \begin{align} H = H_\text{known} + V, \label{tsm} \end{align} where $H_\text{known}$ is a theory where one knows how to construct eigenstates. As in Eq.~\eqref{tcsa}, this may be a CFT, but more generally one can consider \textit{integrable} theories. Then, one needs to be able to compute matrix elements of $V$ in the basis of $H_\text{known}$, and one can follow the procedure above to obtain approximate eigenstates and eigenvalues. TSMs were first used by Yurov and Zamolodchikov~\cite{yurov1991truncated} to study the field theory~\eqref{FT} in what they called the truncated-free-fermionic-space approach. These methods can also be extended in order to mitigate truncation effects, for example using numerical renormalization group techniques~\cite{konik2007numerical,konik2009renormalization,brandino2010energy,james2018nonperturbative}, which can be a necessity in more complicated theories (we discuss convergence of the TSM for the problem at hand in Appendix~\ref{App:ConvTCSA}). To summarize, TSMs allow us to construct well converged low-energy eigenstates of strongly correlated quantum field theories. These field theories, written in terms of a solvable part and a renormalization group relevant operator, are hard to tackle with alternative methods and the TSM can yield considerable insights into their properties. It is necessary to work in the finite volume (so the spectrum is discrete) and with a finite cutoff (to make the Hamiltonian matrix finite), so it is vital to systematically vary the cutoff and the system size to ensure one is describing the physics of the thermodynamic limit and not finite-size or truncation effects. More detailed discussions of this method can be found in the recent review~\cite{james2018nonperturbative}. We proceed by focusing our attention on the zero momentum sector of the theory, which contains the system's ground state. Restricting ourselves to a particular momentum sector incurs no loss of generality [as momentum is conserved by our theory Eq.~\eqref{FT}]. Eigenstates obtained with TSMs (discussed in further detail in the next section) will be used to compute observables and, following recent works~\cite{rakovsky2016hamiltonian,hodsagi2018quench}, nonequilibrium dynamics. \subsubsection{As applied to the Ising field theory~\eqref{FT}} Let us briefly recap some details of the TSM for the Ising field theory; a recent summary of known results and this method can be found in Ref.~\cite{james2018nonperturbative}. We work in the finite volume $R$ and begin by separating the Hamiltonian~\eqref{FT} into a `known' piece and a perturbation, cf. Eq.~\eqref{tsm}, \begin{align} H(m,g) &= H_0(m) + g V, \\ H_0(m) &= \int_0^R {\rm d} x\, i \Big( \bar \psi\partial_x \bar\psi - \psi\partial_x \psi + m \bar\psi\psi \Big), \\ V &= \int_0^R {\rm d} x \,\sigma(x). \end{align} Here our known piece, $H_0(m)$, describes a system of free fermions with mass $m$. Let us now consider the eigenstates of the known theory~\cite{mccoy1978twodimension}. The Hilbert space of the model is split into two sectors, known as Neveu-Schwartz (NS, antiperiodic boundary conditions) and Ramond (RM, periodic boundary conditions), in which the momenta of fermions is quantized in a different manner: $p_\text{NS} = 2\pi n/R$ with $n\in\mathbb{Z}+1/2$ and $p_\text{R} = 2\pi n/R$ with $n\in\mathbb{Z}$, respectively. Eigenstates are obtained by acting on the vacuum (within a given sector) with fermion creation operators \begin{align} |\{k\}_N \rangle_\text{NS} &= a^\dagger_{k_1}\ldots a^\dagger_{k_N} |0\rangle_\text{NS}, \quad k_i \in \mathbb{Z}+\frac12, \nonumber \\ |\{q\}_N\rangle_\text{RM} &= a^\dagger_{q_1}\ldots a^\dagger_{q_N} |0\rangle_\text{RM}, \quad ~~q_i \in \mathbb{Z}. \end{align} Here $\{k\}_N = \{k_1,\ldots,k_N\}$ is a convenient shorthand notation, and henceforth we use $k_i$ ($q_i$) to signify momenta in the NS (RM) sector. The fermion creation operators obey the canonical anticommutation relations \begin{align} \{ a_k, a^\dagger_{k'} \} = \delta_{k,k'}, \quad \{ a_q, a^\dagger_{q'} \} = \delta_{q,q'}, \quad \{a_k, a^\dagger_q \} = 0. \end{align} Eigenstates of $H_0(m)$ with $N$ particles in the finite volume $R$ have energies \begin{align} E_N(R)_\nu = E_0(R)_\nu + \sum_{j=1}^N \omega_{p_{\nu,i}}(R), \end{align} where $\nu = \text{NS},\,\text{RM}$ and $p_{\nu,i} = k_i\,(q_i)$ for $\nu = \text{NS}\,\text{(RM)}$. The dispersion relation for the fermions is given by \begin{align} \omega_{p_{\nu}}(R) = \sqrt{m^2 + \bigg(\frac{2\pi}{R} p_\nu \bigg)^2}, \label{dispersion} \end{align} while the vacuum energy is \begin{align} E_0(R)_\nu &= \frac{m^2 R}{8\pi} \log m^2 \nonumber\\ & - |m| \int_{-\infty}^\infty \frac{{\rm d}\theta}{2\pi} \cosh\theta\log\Big(1 \pm e^{-|m|R\cosh\theta}\Big), \end{align} with the upper (lower) sign applying for $\nu= \text{NS}\,\text{(RM)}$. With these expressions for the eigenstates and eigenvalues of $H_0(m)$ established, we turn our attention to the full problem~\eqref{FT}. For nonzero longitudinal field strength $g$, the spin operator $\sigma(x)$ is present in the Hamiltonian and has to obey periodic boundary conditions $\sigma(x) = \sigma(x+R)$. This imposes a restriction on the fermion states, which varies depending on the sign of $m$ ($m>0$ corresponds to the ordered phase) \begin{align} & m > 0: \left\{ \begin{array}{l} |\{k\}_N\rangle_\text{NS},~\text{with}~N\in2\mathbb{Z}, \\ |\{q\}_N\rangle_\text{RM},~~~\text{with}~N\in2\mathbb{Z}, \end{array} \right. \nonumber\\ & \label{compbasis} \\ & m < 0: \left\{ \begin{array}{l} |\{k\}_N\rangle_\text{NS},~\text{with}~N\in2\mathbb{Z},\\ |\{q\}_N\rangle_\text{RM},~~~\text{with}~N\in2\mathbb{Z}+1. \end{array} \right. \nonumber \end{align} The spin operator $\sigma(x)$ has non-zero matrix elements between states in different sectors, thus coupling them. Detailed expressions for these matrix elements can be found in the literature~\cite{berg1979construction,fonseca2001ising,bugrij2000correlation,bugrij2001form,james2018nonperturbative}. With both a computational basis, Eqs.~\eqref{compbasis}, and matrix elements at hand, one proceeds by introducing an energy cutoff $E_\Lambda$ for the basis states, forming the (dense) Hamiltonian matrix, and then diagonalizing it. We illustrate how the number of computational basis states, $N_\text{states}$, varies as a function of the energy cutoff $E_\Lambda$ in Table~\ref{table:states}. Subsequently, the eigenstates obtained from the truncated spectrum procedure can be used to compute observables, as we discuss in the following sections. \begin{table} \caption{The number of computational basis states $N_\text{states}$ in the zero momentum sector, as a function of energy cutoff $E_\Lambda$ for a system of size $R=35$.} \vskip 10pt \begin{tabular}{cc} \hline \hline \hspace{0.75cm}$E_\Lambda$\hspace{0.75cm} & \hspace{0.75cm}$N_\text{states}$\hspace{0.75cm} \\ \hline 8 & 2305 \\ 9 & 6269 \\ 9.5 & 9809 \\ 10 & 15309 \\ 10.5 & 23498 \\ \hline \hline \end{tabular} \label{table:states} \end{table} \subsection{Diagonal matrix elements} Let us begin by examining the behavior of diagonal matrix elements. As seen in Eq.~\eqref{eth}, under ETH these matrix elements should be smooth as a function of the energy of the eigenstate~\cite{deutsch1991quantum,srednicki1994chaos,rigol2008thermalization,rigol2009breakdown,reimann2015eigenstate,deutsch2018eigenstate} \begin{align} \hat A_{\alpha,\alpha} = A(E_\alpha), \quad \Big| A_{\alpha+1,\alpha+1} - A_{\alpha,\alpha} \Big| \propto e^{-R/R_0}, \label{ethdiag} \end{align} where $R$ is the system size and $R_0 > 0$ is a dimensionful constant. To examine whether Eqs.~\eqref{ethdiag} hold in the perturbed Ising field theory, we compute the expectation value of the local spin operator $\sigma(0)$ within eigenstates [so-called eigenstate expectation values (EEVs)] in a finite volume, $R$. Results as a function of energy density $E/R$ with $m=1$, $g=0.1$ for $R=25,35,45$ are presented in Figs.~\ref{Fig:EEVs}. It is immediately apparent that in the finite volume EEVs are \textit{not} a smooth function of the energy: in particular there is a clear band of states lying above the majority with significantly different EEVs. \begin{figure} \begin{tabular}{l} (a) $R=25$ \\ \includegraphics[width=0.45\textwidth]{R25_EEV_MCE_arrows.pdf} \\ (b) $R = 35$ \\ \includegraphics[width=0.45\textwidth]{R35_EEV_MCE_arrows.pdf} \\ (c) $R = 45$ \\ \includegraphics[width=0.45\textwidth]{R45_EEV_MCE_arrows.pdf} \end{tabular} \caption{Comparison of the eigenstate expectation values (EEV, black) of the local magnetization $\sigma$ with the microcanonical ensemble prediction (MCE, orange) for eigenstates at energy density $E/R$ in the Ising field theory~\eqref{FT} with $m=1$, $g=0.1$ on the ring of size (a) $R=25$; (b) $R=35$; (c) $R=45$. Eigenstates are constructed via the TSM with an energy cutoff of (a) $E_\Lambda = 13.5$; (b) $E_\Lambda = 10.5$; (c) $E_\Lambda = 9$. States containing up to ten particles are considered in the truncated Hilbert space. The MCE is constructed by uniformly averaging over an energy window of size $\Delta E = 0.1$, with error bars denoting the standard deviation. The red arrows highlight the nonthermal states considered further in Fig.~\ref{Fig:fss}.} \label{Fig:EEVs} \end{figure} The unusual nature of this band of states is further highlighted by a comparison to the microcanonical ensemble (MCE) thermal result \begin{align} A_\text{MCE}(E) = \frac{1}{N_{\Delta E}} \sum_{E-\frac{\Delta E}{2} < E' < E + \frac{\Delta E}{2}} \langle E' | \hat A | E' \rangle, \label{Eq:MCE} \end{align} which is constructed by averaging EEVs over an energy window of size $\Delta E = 0.1$ ($N_{\Delta E}$ is the number of states within the energy window). Error bars on the MCE reflect the standard deviation of the data averaged over.\footnote{We say that the EEVs and MCE agree when the EEVs fall within one standard deviation of the MCE. This spread of the EEVs reflects the second term in Eq.~\eqref{eth}, which features the random variable $R_{\alpha,\beta}$, which has mean zero and unit variance. We see that the standard deviation decreases with increasing system size $R$, reflecting the extensivity of the thermodynamic entropy $S(E)$.} It is clear that numerous states fall outside the MCE prediction (plus one standard deviation), both close to the threshold of the multi-particle continuum ($E/R\sim0$), as well as at energies far within the continuum. The band of states above the continuum, whose EEVs differ significantly from the MCE result, are rare states by definition: their EEVs are nonthermal. We note that when reading figures such as Fig.~\ref{Fig:EEVs}, one should always regard EEVs at larger energy densities as having truncation effects. This can be seen, for example, in the upturn of the MCE (increase in the gradient of the slope as a function of $E/R$) at higher energy densities in Figs.~\ref{Fig:EEVs}(b) and (c) (this also occurs in Fig.~\ref{Fig:EEVs}(a) at higher energy densities than plotted), and the decrease in spread of the continuum at larger energy densities. Convergence checks as a function of energy cutoff are presented in Appendix~\ref{App:ConvTCSA}; it should be noted that the separation between the rare states and multiparticle continuum is \textit{well converged} and not a truncation effect. We also note that the MCE converges rapidly in the energy cutoff. In the next section, we examine the issue of finite size scaling: does this difference between rare and thermal states persist to the infinite volume? Before moving on to the finite size scaling, it is worth briefly commenting on the energy cutoff $E_\Lambda$ as a function of system size $R$. As we see in the definition of the single particle dispersion relation, Eq.~\eqref{dispersion}, at fixed energy cutoff $E_\Lambda$, as $R$ is varied the maximum value of the integer $p_\nu$ is increased. Thus to keep a fixed energy cutoff, one needs to consider polynomially more states as $R$ is increased. This quickly becomes computationally problematic, so generally $E_\Lambda$ has to be decreased as $R$ is increased, as has been done in Fig.~\ref{Fig:EEVs}. \subsubsection{Finite size scaling analysis} \label{Sec:EEVRdep} It is interesting to consider the behavior of the system at different system sizes. One of the major advantages of TSMs is that one can construct thousands of low-energy eigenstates to high precision in rather large systems (up to $R\sim 50|m|^{-1}$, where $|m|^{-1}$ is the correlation length of the unperturbed model). Examples for a number of system sizes are presented in Fig.~\ref{Fig:EEVs}. At each value of the system size, focusing on the the low-energy part of the spectrum (where convergence is best) we see that the same essential features appear: there is a continuum of states where (roughly) the MCE and EEV results agree, and above this there is a separate band of rare states, whose EEVs are distinctly nonthermal. We see that the majority of EEVs are consistent with Eq.~\eqref{eth}: with increasing volume $R$ the thermal continuum narrows (reflecting the extensivity of the thermodynamic entropy $S(E)$) and the MCE encompasses the majority of results. Similar sharpening of the distribution of EEVs, and improved agreement with the MCE, is observed in exact diagonalization of lattice models (see, e.g., Refs.~\cite{santos2010localization,ikeda2013finitesize,kim2014testing,steinigeweg2014pushing,beugeling2014finitesize,khodja2015relevance,mondaini2016eigenstate,mondaini2017eigenstate,lan2017eigenstate}). We note that here the agreement is particularly clear compared to lattice calculations, as TSMs allow us to access many states in the low-energy spectrum at relatively large system size. \begin{figure} \begin{tabular}{lll} (a) $n=11$ & & (b) $n=12$ \\ \includegraphics[width=0.23\textwidth]{fss_11.pdf} & & \includegraphics[width=0.23\textwidth]{fss_12.pdf}\\ (c) $n=13$ & & (d) $n=14$ \\ \includegraphics[width=0.23\textwidth]{fss_13.pdf} & & \includegraphics[width=0.23\textwidth]{fss_14.pdf}\\ (e) $n=15$ & & (f) averaged \\ \includegraphics[width=0.23\textwidth]{fss_15.pdf} & & \includegraphics[width=0.23\textwidth]{fss_averaged.pdf} \end{tabular} \caption{(a)--(e) The finite size scaling the total magnetization $R\langle\sigma\rangle$ of the $n=11-15$ rare states (EEV), compared to the MCE prediction. (f) The average magnetization of the $n=11-15$ rare states compared to that predicted by the average of the MCE results. Clearly the rare states and their proximate thermal states have different magnetization, and this persists to the $R\to\infty$ limit. In all cases, error bars show the standard deviation of the data averaged over. Note that $R(\langle\sigma\rangle_n-\langle\sigma\rangle_0)$ measures the number of overturned spins in the $n$th meson as compared to the (ordered) ground state.} \label{Fig:fss} \end{figure} The band of rare states persists to the largest volumes we can access, and so it is natural to ask what becomes of these in the infinite volume limit, $R\to\infty$? As we cannot work directly in this limit (the spectrum of the theory becomes continuous and there are an infinite number of states below any non-zero energy cut-off), we infer results from a finite size scaling analysis. Ordering the rare states by energy, we focus on the five states numbered $n=11\to15$, which have energies well within the multiparticle continuum. These states are highlighted by the red arrows in Fig.~\ref{Fig:EEVs}. For all system sizes that we access, these states are well converged for the maximum value of the cutoff $E_\Lambda$ achieved with reasonable computational resources. We compare the finite size scaling of these EEVs to the MCE constructed at the same average energy density, as shown in Fig.~\ref{Fig:fss}. In each case, the MCE prediction for the magnetization of the state is different to the EEV of the rare state, and the finite size scaling analysis suggests that this persists to the infinite volume limit, $1/R \to 0$. This is particularly clear if one computes the average magnetization of the five rare states and compares to the average from the MCE, as shown in Fig.~\ref{Fig:fss}(e). The convergence of the whole EEV spectrum as a function of system size $R$ is presented in Sec.~\ref{sec:EEVRdep}, where we compare to similar results on a corresponding lattice model. For the low-energy parts of the spectrum (including the rare states), the results are converged to those of the thermodynamic limit, $R\to\infty$. \subsection{Off-diagonal matrix elements} As we have already seen, ETH~\eqref{eth} also supposes that off-diagonal matrix elements of an operator have a certain structure, \begin{align} \hat A_{\alpha,\beta} = e^{-S(E)/2}f_A(E,\omega) R_{\alpha,\beta}, \qquad \alpha\neq\beta. \label{ethoffdiag} \end{align} Here $S(E)$ is the thermodynamic entropy, $f_A(E,\omega)$ is a smooth function of both the average $E$ and difference $\omega$ of the energies of the eigenstates $E_\alpha,E_\beta$. $R_{\alpha,\beta}$ is a random variable with zero average and unit variance. The off-diagonal matrix elements are exponentially suppressed by $S(E)$, an extensive quantity. We have already seen signatures of this in the previous section: the variance of the diagonal matrix elements decreases with increasing system size. From Eq.~\eqref{ethoffdiag}, we would expect average off-diagonal matrix elements to be much smaller than the diagonal ones (as these are not suppressed by $S(E)$)~\cite{deutsch1991quantum,srednicki1994chaos,rigol2008thermalization,rigol2009breakdown,reimann2015eigenstate,deutsch2018eigenstate}. To examine this, we compute the off-diagonal matrix elements of $\sigma(0)$ in the basis of eigenstates: \begin{align} \sigma_{\alpha\beta} = \langle E_\beta | \sigma(0) | E_\alpha \rangle, \qquad \alpha\neq\beta. \end{align} For $\alpha,\beta=1,\ldots,500$ we present these in Fig.~\ref{Fig:Offdiag}, where we consider the same set of parameters as in Fig.~\ref{Fig:EEVs}. From inspection of the numerical data, as well as Fig.~\ref{Fig:Offdiag}, we see that off-diagonal matrix elements are generally much smaller [$O(10^{-2})$ and smaller] than the diagonal elements (although we note that there are some off-diagonal elements that are comparable to the diagonal ones for $R=35$). It is also apparent that there is significant structure present within the off-diagonal elements (cf. Eq.~\eqref{ethoffdiag}), with clear lines of zeros in the $(\alpha,\beta)$ plane, as well as regions with larger matrix elements (on average). Many of the vertical/horizontal lines with small matrix elements coincide with the index of the rare states. Prominent examples include the $\alpha=175$, $\alpha=319$ and $\alpha=457$ lines (by symmetry, the same lines along the $\beta$ axis), as well as the many lines of suppressed matrix elements at small $\alpha$ and $\beta$. \begin{figure} \includegraphics[width=0.45\textwidth]{OffDiagElements_Log_g01.pdf} \caption{Off-diagonal matrix elements of the local spin operator $\vert \langle E_\beta | \sigma(0) | E_\alpha\rangle \vert$ ($\alpha\neq\beta$) between the first 500 eigenstates constructed with the TSM for $m=1$, $g=0.1$ and $R=35$, cf. Fig.~\ref{Fig:EEVs}(b). Parameters are $m=1$, $g=0.1$. Matrix elements satisfying $|\sigma_{\alpha\beta}| < 10^{-7}$ are plotted as white. Note the visible vertical/horizontal lines are not remnants of the plotting, but show eigenstates that are only coupled very weakly to other states by the spin operator $\sigma(0)$. } \label{Fig:Offdiag} \end{figure} \subsubsection{System size dependence} To examine the system size dependence of the off-diagonal elements, we follow~~\textcite{mondaini2017eigenstate} and study the behavior of the absolute value of the off diagonal matrix elements. In particular, within the lowest 1000 eigenstates we consider matrix elements where the energy of the eigenstates $|E_\alpha\rangle$, $|E_\beta\rangle$ satisfies $(E_\alpha + E_\beta) < 8$ (we note that this corresponds to $|\omega| = |E_\alpha-E_\beta| \lesssim 11$ for all system sizes considered). We then consider the behavior of these elements as a function of the energy differences, $\omega = E_\alpha-E_\beta$, and how this varies with system size. To aid in extracting this behavior, we take a running average and this is shown in Fig.~\ref{Fig:OffDiagFSS}. \begin{figure} \includegraphics[width=0.45\textwidth]{OffDiagFSS_Emax8.pdf} \caption{The running average of the absolute value of off-diagonal matrix elements $|\sigma_{\alpha\beta}|$ between eigenstates with energies satisfying $(E_\alpha+E_\beta) < 8$. For the largest system, $R=50$, this condition restricts to the lowest (in energy) $\sim 1000$ eigenstates (and fewer at smaller volumes). The running average is computed over $300$ data points.} \label{Fig:OffDiagFSS} \end{figure} Figure~\ref{Fig:OffDiagFSS} highlights a number of features of the off-diagonal matrix elements between low-energy eigenstates. Firstly, as mentioned in the previous section for $R=35$, we see that the average off-diagonal matrix element is small $<10^{-2}$. Secondly, this average smallness decreases with increasing system size $R$, consistent with general expectations from ETH. However, due to limitations of our methodology (being restricted to low energy eigenstates), we cannot ascertain whether generic off-diagonal elements are suppressed exponentially in the volume (via the extensivity of the thermodynamic entropy for generic, finite energy density, eigenstates). \section{The nature of the rare states} \label{Sec:Nature} In the previous section, we have seen that rare states with nonthermal EEVs are present within the model~\eqref{FT}. A natural question is then: do these states share common characteristics? Looking at Fig.~\ref{Fig:EEVs} there is an obvious first guess as to their physical characteristics: the rare states extend in a band from the lowest-energy excitations in the system, which are the well-known `meson' confined states, with wave functions of the form \begin{align} |\psi_n\rangle = \sum_{\nu=\text{NS},\text{RM}} \sum_{p_\nu} \Psi_{n,\nu}(p_\nu) a^\dagger_{p_\nu}a^\dagger_{-p_\nu} |\nu\rangle. \label{mesonState} \end{align} These states consist of linearly-confined pairs of domain walls (described by the fermions $a^\dagger_{p_\nu}$ in the $\nu=\mathrm{RM},\mathrm{NS}$ sectors of the Hilbert space, with vacuum $|\nu\rangle$ in each sector, see e.g. Ref.~\cite{james2018nonperturbative}). On the basis of Figs.~\ref{Fig:EEVs} it is easy to suggest that the rare states are simply higher energy meson states. \begin{figure} \includegraphics[width=0.45\textwidth]{R35_EEV_Weights.pdf} \caption{The two particle weight $w_2$~\eqref{weight} and the eigenstate expectation values of the local magnetization operator $\langle\sigma\rangle$ in the field theory~\eqref{FT} with $m=1$, $g=0.1$ on the ring of size $R=35$. Eigenstates are constructed with the TSM for an energy cutoff of $E_\Lambda = 10.5$ and a maximum of ten particles in the basis states. Arrows (upper and lower) are drawn at the energies of the first forty confined states, $M_n$, as computed in Appendix~\ref{App:Semiclassical}. Higher particle weights, as well as histograms of their distributions, are provided in Appendix~\ref{App:Weights}.} \label{Fig:TwoParticleWeight} \end{figure} To ascertain whether this is correct, we can use the information directly accessible to us from the TSM procedure. In the first case, we can check whether the rare states are (majority) two particle in nature by defining the particle weights. To do so, we recall that we construct states in terms of free fermion basis states \begin{align} | E_m \rangle = \sum_{N = 0,2,4,\ldots} \sum_j c^m_{N,j} | \{ p_j \}_N \rangle, \label{eigenstates} \end{align} where $c^m_{N,j}$ are superposition coefficients and $ | \{ p_j \}_N \rangle$ are $N$-fermion Fock states with fermions carrying momenta $\{p_j\}_N \equiv \{p_{j1},\ldots,p_{jN}\}$. Particle weights $w_N$ telling us the $N$-fermion fraction of state are: \begin{align} w_N = \sum_{j} |c_{N,j}|^2. \label{weight} \end{align} We present a plot of the EEV spectrum for $R=35$, Fig.~\ref{Fig:EEVs}(b), with superimposed two particle weights in Fig.~\ref{Fig:TwoParticleWeight}. We see that those EEVs corresponding to rare states are also those which have $w_2 \approx 1$ and so we conclude the rare states are majority two-particle in nature, consistent with Eq.~\eqref{mesonState}. To further strengthen our evidence that rare states are meson-like, we (semi)analytically compute the energy of the meson states. This can proceed in a number of manners; we consider in particular the energies computed via a semiclassical approximation (the salient points of which are summarized in Appendix~\ref{App:Semiclassical})~\cite{fonseca2003ising,rutkevich2005largen,fonseca2006ising}. One achieves consistent results by means of a Bethe-Salpeter analysis, which also allows one to obtain the wave function in Eq.~\eqref{mesonState}, see also Appendix~\ref{App:Wfn}. Computed results for the energies of meson states are also shown in Fig.~\ref{Fig:TwoParticleWeight} via the arrows, which are drawn at the (semiclassical) energies of the first forty meson states. They clearly coincide with the nonthermal EEVs and two particle dominated states. We thus conclude that the rare states are described by Eq.~\eqref{mesonState}, meson-like confined pairs of domain walls~\cite{fonseca2003ising,rutkevich2005largen,fonseca2006ising}. As previously noted, the rare states exist far beyond the multiparticle continuum (occurring in Fig.~\ref{Fig:TwoParticleWeight} at $E/R \sim 0.03$), which is surprising when drawing analogies with mesons in quantum chromodynamics (QCD)~\cite{sulejmanpasic2017confinement}: in QCD we usually think of high energy mesons as splitting into multiple lower-energy mesons. Indeed, in the case considered here such processes \textit{are kinematically allowed}, so it is worth spending some time to understand why the meson states~\eqref{mesonState} exist above the continuum and have EEVs that remain well separated from the thermal result (cf. Fig.~\ref{Fig:fss}). To reemphasize: with the TSM we have constructed well-converged \textit{eigenstates of the Hamiltonian~\eqref{FT}} that are still meson-like above the threshold of the multiparticle continuum.\footnote{We note that in the context of magnetic systems, one might conclude that the mesons are not present in the spectrum as one does not see signatures in dynamical spin-spin correlation functions: but from Fig.~\ref{Fig:EEVs} one could conclude that they are indeed there, though their signal is washed out by the thermal signal from the large number of states in the multiparticle continuum.} \subsection{Stability of meson excitations above the multimeson threshold} To gain some insight into why the rare states persist above the multimeson threshold, we take the mesons defined in Eq.~\eqref{mesonState}, \begin{align} b^\dagger_{n} = \sum_{\nu = \text{NS,RM}} \sum_{p_\nu} \Psi_{n,\nu}(p_\nu) a^\dagger_{p_\nu} a^\dagger_{-p_\nu}, \label{meson} \end{align} which are \textit{approximate quasi-particles} of the problem---they do not have infinite lifetime because exact eigenstates of~\eqref{FT} contain a finite amount of $N\ge4$ particle dressing (see Appendix~\ref{App:Weights})---and discuss their hybridization with states with higher fermion number. We first recap known results for the zero temperature lifetime of meson excitations, before discussing the correction to the meson energies due to hybridization with higher fermion number states. We will see that the simple meson, Eq.~\eqref{meson}, has very long lifetime at zero temperature and only very weakly hybridizes with states containing four (or more) fermions. This is consistent with the idea that with a small amount of dressing the meson excitations~\eqref{meson} become absolutely stable. \subsubsection{Meson lifetime} \label{sec:lifetime} Let us consider the results of Rutkevich~\cite{rutkevich2005largen} for the zero temperature meson lifetime. Firstly, the lowest energy meson excitations (below the two-meson threshold, $E \lesssim 4m$) are absolutely stable, with no decay channels. Above the two meson threshold energy, the $n$th meson state has decay width $\Gamma_n$, which can be estimated to leading order using Fermi's golden rule \begin{align} \Gamma_n = 2\pi \sum_{E_{\rm out}} \left| \langle E_{\rm out} | V | \psi_n \rangle \right|^2 \delta( M_n - E_{\rm out} ). \end{align} Here $M_n$ is the meson mass (energy of the zero momentum meson state), $|\psi_n\rangle$ is the meson wave function (cf. Eq.~\eqref{mesonState} and Appendix~\ref{App:Wfn}), $|E_{\rm out}\rangle$ are eigenstates of the full Hamiltonian with energy $E_{\rm out}$ (measured relative to the ground state energy), and $V$ is the interaction term \begin{align} V = g \int {\rm d} x\, \sigma(x). \end{align} Under a semiclassical analysis, the decay width $\Gamma_n$ \textit{in the infinite volume} has been computed by Rutkevich~\cite{rutkevich2005largen}. This leads to a lifetime, above the two-meson threshold energy, for the meson states~\eqref{mesonState} that varies as \begin{align} \tau \propto g^{-3}, \end{align} which is very large at sufficiently small $g$. We note that this formula was derived for large meson number. More generally one faces a challenge in computing the lifetime using Fermi's golden rule. The matrix elements of the spin operator generically have IR divergences, which reflect the fact that the matrix elements represent both connected and disconnected diagrams. To make sense of a lifetime computation in a fully quantum setting, one must be able to sensibly separate out only the connected part \cite{Zamolodchikov2011}. Alternatively, one can extract the life time of meson excitations from finite-volume TSMs as shown in Ref.~\cite{pozsgay2006characterization}. Results can also be compared to computations from form factor perturbation theory, see also Refs.~\cite{delfino1996nonintegrable,delfino1998nonintegrable,delfino2009particle}. We will do neither here -- we delay a detailed study of the lifetime (as well as the meson Green's function) to a later work. \subsubsection{Corrections to the meson energy: energy dependence} We instead will content ourselves here by considering the correction to the energy of the mesons~\eqref{meson} due to hybridization with zero and four fermion states. From this quantity we will be able to deduce that the mesons as constructed from two-particle states (i.e. Eq.~\eqref{meson}) are only weakly coupled to sectors of the unperturbed theory with different particle number. To second order in perturbation theory in $g$, the energy correction for the $j$th meson is \begin{align} \Delta E_{2j}=& \frac{g^2}{M_j} \sum_{\nu = \text{RM,NS}} \left\vert \sum_{p_{\bar\nu}} \Psi_j(p_{\bar\nu}) \langle \nu | \sigma(0) | \{ -p_{\bar \nu}, p_{\bar\nu}\}\rangle \right\vert^2 \nonumber \\ & + g^2 \sum_{\nu = \text{NS,RM}} \sum_{p_{\nu1} < p_{\nu2} < \ldots} \frac{\delta_{0,\sum_{i} p_{\nu i}} \left\vert f^{4,\nu}_{j,\{p_\nu\}_4} \right\vert^2}{M_j - \sum_{i=1}^4 \omega_{p_{\nu i}}(R)}, \label{encorr} \end{align} where \begin{equation} f^{4,\nu}_{j,\{p_\nu\}_4} = \sum_{p_{\bar\nu}} \Psi_j(p_{\bar\nu}) \langle \{ p_{\nu} \}_4 | \sigma(0) | \{ -p_{\bar \nu}, p_{\bar\nu}\}\rangle. \end{equation} The matrix elements of the spin operator $\sigma(0)$ required above are known, see Refs.~\cite{berg1979construction,fonseca2003ising,bugrij2000correlation,bugrij2001form,james2018nonperturbative}. \begin{figure} \begin{tabular}{l} (a) \\ \includegraphics[width=0.45\textwidth]{lifetime_v7_cropped.pdf}\\ (b) \\ \includegraphics[width=0.45\textwidth]{lifetime_v8_cropped.pdf}\\ \end{tabular} \caption{The second order correction to the energy (measured relative to the ground state) of the first 19 meson masses due to mixing with zero and four domain wall fermion states. This should be compared to the correction to the mass of the spin flip excitation in the disordered phase ($m<0$), shown in blue, which is between two and four orders of magnitude larger. In the two cases we consider (a) $g=0.1$ (reproduced from \cite{james2018nonthermal}); (b) $g=0.2$. Error bars denote uncertainty in the extrapolation to infinite volume.} \label{fig:encorr} \end{figure} The correction to the energy, $\Delta E_{2j}$ will take the form \begin{align} \Delta E_{2j} = \alpha R + \delta E_{2j}, \label{encorrR} \end{align} where the term scaling with volume, $\alpha R$, will be identical to the correction to the vacuum (ground) state due to hybridization with higher fermion number states. This follows from the fact that the energy of a meson excitation will differ only by $O(1)$ compared to the ground state. Thus $\delta E_{2j}$ is the correction to the meson mass relative to the ground state energy. We compute $\Delta E_{2j}$ as a function of $R$ by numerically evaluating~\eqref{encorr} and fitting the result to Eq.~\eqref{encorrR}. We present the results of this in Fig.~\ref{fig:encorr} for two values of the field, $g=0.1, 0.2$. Some insights into the non-monotonic nature of $\delta E_{2j}$ with bound state number can be gained by looking at the wave functions of successive bound states. We do so in Fig.~\ref{fig:wavefun} using the analytic forms of the wave function developed in Appendix~\ref{App:Wfn}. The bound state wave functions have considerable structure and it is this, and its relative positioning relative the $E=4m$ threshold, that leads to the non-monotonic behavior of the energy corrections coming from hybridization with four particle states. \begin{figure} \includegraphics[width=0.45\textwidth]{wavefn_cropped.pdf} \caption{The wave functions in momentum space for the first 10 odd numbered bound states for $g=0.1$. We see that the maxima in the wave functions do not occur at momenta that are increasing in a uniform fashion.} \label{fig:wavefun} \end{figure} We compare the correction to the meson energy to the analogous calculation in the disordered (paramagnetic) phase of the model, $m<0$, where single particle excitations are spin flips (i.e., we compute the correction to the energy of a single Ramond sector fermion). The calculation is similar to that above, with the explicit form for the correction being \begin{align} \Delta E_{2,\text{sf}} &= \left( \frac{g^2 \bar\sigma^2}{m^2}\right) R + \delta E_\text{sf}, \nonumber \\ \delta E_\text{sf} &= \frac{g^2 \bar s^2}{2mR} \sum_{q\in\text{NS}} \frac{1}{\omega_q(R)^2 [ m - 2\omega_q(R)]^2} \frac{\tanh^2 \theta_q}{\tanh^4(\theta_q/2)}. \nonumber \end{align} Here $\theta_q$ is a rapidity variable defined through the relation $|m|R\sinh\theta_q = 2\pi q$. The result for the correction to the spin flip mass, $\delta E_\text{sf}$, is also shown in Fig.~\ref{fig:encorr}. There we see that the correction to the spin flip energy is between two and four orders of magnitude larger than the corresponding corrections to the meson energies. Combined with the results of Sec.~\ref{sec:lifetime}, we see that the mesons~\eqref{meson} are almost unaffected by hybridization with states of higher fermion number. \subsubsection{Corrections to the meson energy: field dependence} We can also consider how the hybridization corrections to the meson energies evolve as a function of field strength $g$. Whilst naively the correction $\Delta E_{2j}$ is a $g^2$ diagram, it also features the meson wave function which evolves with $g$. In Fig.~\ref{fig:encorrvarh} we show the evolution of $\delta E_2$ as a function of $g$ for four meson states: the first, third, fifth and ninth as ordered by energy. One sees that $\delta E_2$ grows with $g$ provided the bound state energy is below the four domain-wall threshold (i.e. 4m). We show when this threshold is crossed, as a function of g, for the four different mesons in Fig.~\ref{fig:energies}. For the lowest meson (the green line in Figs.~\ref{fig:encorrvarh} and \ref{fig:energies}), we see that for $0\leq g \leq 0.3$ this meson's energy never exceeds $4m$, and correspondingly the energy correction increases monotonically. However for the fifth meson (the brown line in these two figures), its energy exceeds $4m$ once $g \gtrsim 0.06$. We further see that while initially $\delta E_2$ increases with increasing $g$ for this meson, it begins to behave non-monotonically (with a decreasing trend) once $g$ exceeds $0.15$. \begin{figure} \includegraphics[width=0.45\textwidth]{lifetime_varh_cropped.pdf} \caption{The second order correction to the energy (measured relative to the ground state) as a function of longitudinal field strength $g$ for four mesons (the first, third, fifth and ninth ordered by energy) arising from mixing with zero and four domain wall fermion states. Error bars denote uncertainties in extrapolating to the infinite volume.} \label{fig:encorrvarh} \end{figure} \begin{figure} \includegraphics[width=0.45\textwidth]{energies_cropped.pdf} \caption{The energies as a function of longitudinal field strength $g$ for four mesons (the first, third, fifth and ninth ordered by energy) whose energy corrections are given in Fig.~\ref{fig:encorrvarh}. The dashed line marks the $4m$ threshold. Once the energy of the meson crosses this threshold, we no longer expect the energy of hybridization with the vacuum and four particle states to increase monotonically with increasing $g$.} \label{fig:energies} \end{figure} \subsubsection{Summary of insights} In the preceding three sections we have shown that two fermion excitations, which are an approximation to the true meson excitations, have a long life time and very small energy corrections due to hybridization. True meson states, as constructed via truncated spectrum methods in Fig.~\ref{Fig:EEVs}, are obtained by dressing the two fermion excitations with small contributions from four, six and more fermion states. The already long lifetime of the approximate meson states should increase upon inclusion of $N>2$ fermion states in the approximation (because they become closer to a true eigenstates), but such a calculation is a significant extension of those presented above and beyond the scope of this work. Instead, one can infer this directly from the results of the TSM in Fig.~\ref{Fig:EEVs}, where the meson states are eigenstates and thus possess infinite lifetimes. \subsection{Approximate $U(1)$ symmetry at low energy} In the previous section, we have seen that single meson excitations~\eqref{meson} only very weakly hybridize with the multi-meson continuum. This is in spite of the fact that the spin operator $\sigma(x)$ in principle couples states with widely differing numbers of fermions (and hence mesons). One might then suppose that there is an approximate low energy $U(1)$ symmetry, with the Hamiltonian being almost block diagonal in the space of fermion number. Here we present results for the EEV spectrum that show such an approximate block diagonalization works well within the low energy eigenstates. We leave a detailed study of this approximate symmetry to future work. \begin{figure} \includegraphics[width=0.45\textwidth]{approxU1_p4.pdf} \caption{We compare the results of a full TSM procedure with $E_\Lambda = 10.5$ (for a system with $g=0.1$, $m=1$ of size $R=35$) to an approximate block diagonalization by fermion number. Two particle states (2p) are considered up to cutoff $E_\Lambda = 200$; four particle states (4p) are considered up to cutoff $E_\Lambda = 16$. Dashed lines show the threshold energies for eigenstates containing $1-3$ mesons (i.e. up to 6 fermions). } \label{approxU1} \end{figure} In Fig.~\ref{approxU1}, we show the EEV spectrum from the full TSM treatment with energy cutoff $E_\Lambda$ (cf. Fig.~\ref{Fig:EEVs}(b)) and contrast it to the EEV spectrum computed from the Hamiltonian with fermion number conservation imposed \textit{by hand} on the interaction vertex (i.e. on the the spin operator). At low energies $E/R \lesssim0.1$ (below the six particle threshold), we see excellent agreement between the full and block diagonal treatments. This agreement between \textit{by-hand} U(1) symmetric results and full results can be understood once one looks at the particle weights of the eigenstates. In Fig.~\ref{Fig:TwoParticleWeight} we presented the two particle weight, $w_2$, and saw that the meson states have $w_2 \approx 1$. Study of the higher particle weights (see Appendix~\ref{App:Weights}) similarly shows that the distribution of two and four particle weights is \textit{bimodal} in low-energy eigenstates, with either $(w_2 \approx 1,w_4 \approx 0)$ or $(w_2 \approx 0,w_4 \approx 1)$. \section{Nonequilibrium Dynamics} \label{Sec:Dynamics} In the previous sections we have shown that rare states exist within the spectrum of the perturbed Ising field theory~\eqref{FT}. These states yield EEVs that do not conform with the MCE. One question that is natural to ask is whether these states can ever been seen? They exist above a large continuum of states that behave thermally, and hence one may imagine any response from the rare states is `washed out' and they cannot be observed. In this section, we will show that features of these rare states can be brought to bear on nonequilibrium dynamics following a quantum quench. We first show that at long times after a quench, one can arrive at a stationary state (the DE) that gives expectation values inconsistent with the appropriate MCE. Having ascertained that rare states show up in the long time limit, we then ask whether at finite times the presence of rare states influences nonequilibrium dynamics. We show that, indeed, they do. We note that the real-time dynamics following a quantum quench of both the fermion mass $m$ and the longitudinal field $g$ in the Ising field theory have been recently studied by~~\textcite{rakovsky2016hamiltonian} A similar quench in the closely-related lattice model has also recently received attention~\cite{kormos2016realtime}; it was shown that confinement leads to a suppression of the light cone spreading of correlations and a back-and-forth motion of domain walls. Similar behavior is also seen in a two dimensional model exhibiting confinement~\cite{james2018nonthermal}. \subsection{Equilibration after a sudden quantum quench} \label{Sec:DEandMCE} Let us begin by defining our nonequilibrium protocol. We study dynamics that are induced at time $t=0$ by an instantaneous change of the longitudinal field within the Hamiltonian~\eqref{FT} \begin{align} H_i \equiv H(m,g_i) \to H_f \equiv H(m,g_f), \end{align} restricting our analysis to quenches starting from eigenstates $|E_m\rangle$ of the initial Hamiltonian. The expectation value of the local spin operator $\sigma(0)$ in the long-time limit is probed through the DE~\cite{kollar2008relaxation,rigol2008thermalization,rigol2009breakdown} \begin{align} \lim_{t\to\infty} \frac{1}{t} \int_0^t {\rm d} t' &\langle E_m|e^{iH_f t'} \sigma(0) e^{-iH_f t'} |E_m\rangle\nonumber \\ & = \sum_n |\tilde c_{m,n}|^2 \langle \tilde E_n| \sigma(0) |\tilde E_n\rangle, \label{DE} \end{align} where $|\tilde E_n\rangle$ are the eigenstates of $H_f$ and $\tilde c_{m,n} = \langle E_m | \tilde E_n\rangle$ are the overlap coefficients. The DE predictions are compared to the MCE at the appropriate energy density constructed by averaging over an energy window $\Delta E$. Agreement between the DE and MCE signals thermalization, whilst disagreement suggests an absence of thermalization. The convergence of the DE and MCE are discussed in the Appendix~\ref{App:ConvTCSA}. Herein we consider quenches in which both the initial and final longitudinal fields are positive -- this avoids problems with convergence for sign changing quenches (see also Ref.~\cite{rakovsky2016hamiltonian}), which can be understood in terms of projecting onto the `false vacuum' in finite size systems. \begin{figure}[t] \includegraphics[width=0.45\textwidth]{R25_DE_MCE.pdf} \caption{The diagonal ensemble (DE) result for long-time expectation values and the microcanonical ensemble (MCE) prediction following the sudden quench $(m=1,g=0.1) \to (m=1,g=0.2)$ in the field theory~\eqref{FT}. Each data point corresponds to starting from a different low energy eigenstate of the initial Hamiltonian, $m=1,g=0.1$. In all cases, results are on a system of size $R=25$ and with energy cutoff $E_\Lambda$. We note that $E_\Lambda = 13$ ($E_\Lambda = 13.5$) corresponds to $23,238$ ($32,149$) computational basis states. The MCE is computed by averaging an energy window of size $\Delta E = 0.1$, and error bars denote the standard deviation of data averaged over.} \label{Fig:DEMCE} \end{figure} We present DE and MCE results for the local spin operator $\sigma(0)$ at long-times after the quench $g = 0.1 \to 0.2$ in Fig.~\ref{Fig:DEMCE}. We use a system of size $R=25$ and fermion mass $m=1$, cf. Figs.~\ref{Fig:EEVs}. Each plotted point of the DE is constructed starting from a different eigenstate of the initial Hamiltonian; we see that the vast majority of initial states have DE and MCE results that agree (within one standard deviation, represented by the error bars on the MCE). However, much like in the equilibrium spectrum (see Figs.~\ref{Fig:EEVs}, and recall the finite size scaling in Fig.~\ref{Fig:fss}) we observe a well-separated band of states above the thermal continuum. We also include the DE ensemble for a smaller value of the TSM cutoff to highlight that these well-separated states are \textit{well converged}. Figure~\ref{Fig:DEMCE} leads us to conclude that the rare states in the equilibrium spectrum indeed influence the nonequilibrium dynamics, leading to states that do not thermalize following a quantum quench. This is despite the fact that the Hamiltonian governing the time evolution is \textit{nonintegrable} and hence generically is expected to lead to thermalization. This is yet more support for ETH: if ETH is absent, thermalization can be avoided even in nonintegrable models. \subsection{Nonequilibrium real-time dynamics} In the long time limit we see that there are states that do not thermalize. Now we want to understand whether such states have unusual behavior (or anything noticeably different from thermal states) in their short-to-intermediate time dynamics. This time window is of primary interest for experiments on cold atomic gases, and is also accessible in lattice models using numerical methods such as TEBD. Let us first discuss how we compute the real-time dynamics, before presenting results. \subsubsection{Time evolution by the Chebyshev Expansion} \label{Sec:Cheb} To compute the time evolution of states within TSMs, we use the recently developed formalism of~~\textcite{rakovsky2016hamiltonian} and expand the time evolution operator in terms of Chebyshev polynomials $T_n$. The expansion reads \begin{align} e^{-iH_ft} = J_0\left(\tilde t\right) \mathbb{1} + 2 \sum_{n=1}^\infty \left(-i\right)^n J_n\left(\tilde t\right)T_n(\tilde H_f), \label{Eq:EvolutionOp} \end{align} where we rescale both the time $\tilde t = E_{\rm max}t$ and the Hamiltonian $\tilde H_f = H_f/E_{\rm max}$ by the maximal eigenvalue of the Hamiltonian $H_f$, such that the eigenvalues of $\tilde H_f$ lie in the interval $[-1,1]$. $J_n(x)$ are the Bessel functions \begin{align} J_n(x) = \sum_{l=0}^\infty \frac{(-1)^l}{l! (n+l)!} \left( \frac{x}{2}\right)^{2l+n}, \end{align} and the Chebyshev Polynomials are defined through the recursion relation \begin{align} T_{n+1}(x) = 2x T_n(x) - T_{n-1}(x), \label{Eq:recursion} \\ {\rm with}\quad T_0(x) = 1,\quad T_1(x) = x. \nonumber \end{align} With Eq.~\eqref{Eq:EvolutionOp} at hand, the procedure for computing the time evolution is straightforward. The initial state $|\Psi_i\rangle$ is known in the free fermion basis, as is the final Hamiltonian, so, one generates the Chebyshev vectors $|t_n\rangle = T_n(\tilde H_f)|\Psi_i\rangle$ through the recursion relation~\eqref{Eq:recursion} and then sums them, Eq.~\eqref{Eq:EvolutionOp}, to obtain the time-evolved state. Observables, such as the local magnetization $\langle \sigma(0)\rangle$, can then be computed. Herein we refer to this approach as TSM+CHEB. The Chebyshev expansion of the time evolution operator, Eq.~\eqref{Eq:EvolutionOp}, contains an infinite number of terms and so it is necessary to truncate the expansion. This truncation introduces a time scale after which the reported time evolution cannot be trusted. Qualitatively we see that this time scale increases (approximately) linearly with the number of terms kept in the sum. We discuss further convergence of TSM+CHEB in Appendix~\ref{App:ConvCheb}. \begin{figure}[t] \begin{tabular}{l} (a) \\ \includegraphics[width=0.45\textwidth]{TimeEvo_GS.pdf}\\ (b) \\ \includegraphics[width=0.45\textwidth]{Power_Spectrum_GS.pdf} \end{tabular} \caption{(a) Time evolution of the local magnetization $\langle \sigma(0)\rangle$ following the quench $(m=1,g=0.2)\to(m=1,g=0.1)$ in~\eqref{FT} with $R=25$. Time evolution is computed via TSM+CHEB with cutoff $E_{\Lambda} = 9,\ 10$ and the expansion evaluated to order 2000. The magnetization is oscillating about its diagonal ensemble (DE) value, computed via the TSM, which also coincides with the microcanonical ensemble prediction. (b) The power spectrum of the time evolution. We note a few prominent frequencies in terms of the {\it post-quench} confined state energies: $\Delta M_{ij} = M_i-M_j$ and $\Delta M_j = M_j$.} \label{Fig:GSquench} \end{figure} \begin{figure}[t] \begin{tabular}{l} (a) \\ \includegraphics[width=0.45\textwidth]{TimeEvo_First.pdf}\\ (b) \\ \includegraphics[width=0.45\textwidth]{Power_Spectrum_First.pdf} \end{tabular} \caption{(a) Time evolution of the local magnetization $\langle \sigma(0)\rangle$ when starting from the first excited state of~\eqref{FT} for the same quench described in Fig.~\ref{Fig:GSquench}. (b) The associated power spectrum. We note a few prominent frequencies in terms of the post-quench confined state energies: $\Delta M_{ij} = M_i-M_j$ and $\Delta M_j = M_j$.} \label{Fig:Firstquench} \end{figure} \subsubsection{Quenches from the ground and first excited states} Let us first develop some intuition by studying quenches from the very lowest states. We present the time evolution of the local spin operator $\sigma(0)$ following the quench $H(m=1,g=0.2)\to H(1,0.1)$, when starting from the ground state of the initial $H$, in Fig.~\ref{Fig:GSquench}. Results are well converged already for $E_\Lambda \sim 10$ and the expectation value oscillates about its DE prediction.\footnote{Interesting, we note that this particular quench has essentially no finite size effects, see the appendix~\ref{App:ConvCheb} for further information. A similar lack of finite-size effects was seen in quenches of the lattice Ising chain perturbed by a longitudinal field~\cite{kormos2016realtime}. $~$} These oscillations occur at many frequencies, as can be extracted through the power spectrum (Fourier transform) shown in the lower panel. These frequencies coincide with the post-quench meson energies (and their differences), giving an effective route for `meson spectroscopy' (for further details of how we compute these energies, see Appendix~\ref{App:Semiclassical}). Analogous behavior is seen for the quench in which we start from the first excited state, Fig.~\ref{Fig:Firstquench}. The power spectrum is now dominated by the frequency $\omega = M_2 - M_1$, implying the initial state projects heaving onto the first and second meson excitations. This is not entirely surprising, as we know in both the initial and final Hamiltonians the meson states are mostly two-particle in nature (see Sec.~\ref{Sec:Nature}). In both the above cases, Figs.~\ref{Fig:GSquench}--\ref{Fig:Firstquench}, oscillations of the expectation value are centered on the DE prediction. For the time-scales that we can reach within the TSM+CHEB procedure, it is not clear that these oscillations are decaying. This is an important question to address, but remains beyond the reach of existing approaches. \subsubsection{Quenches from a rare state and proximate thermal state} Having looked at quenches starting from the very lowest states, let us now turn our attention to states with larger energy densities. In particular, we will compare the short time dynamics of a rare state to that of thermalizing states of similar energy. We choose the rare state by picking one of the initial states where the DE and MCE disagree; it is \textit{a priori} unclear whether we should see qualitatively different dynamics for rare and thermal states. To address this question, we consider the time evolution following the quench $H(m=1,g=0.1)\to H(1,0.2)$ (as in Sec.~\ref{Sec:DEandMCE}), and consider eigenstates of the initial Hamiltonian, $|\Psi_n\rangle$, whose energy in the final basis are very close (computed via $E_n = \langle \Psi_n | H(1,0.2) | \Psi_n\rangle$). This in turn implies that the MCE prediction for the long-time expectation values are very close. The precise states that we consider are summarized in Table~\ref{Table:States}, with the $n=100$ initial eigenstate being a rare state (the DE and MCE disagree outside one standard deviation). All other states are thermal, in the sense that the DE agrees with the MCE prediction (within one standard deviation), cf. Fig.~\ref{Fig:DEMCE}(a). \begin{table}[t] \caption{The energy $E_n = \langle \Psi_n | H_f |\Psi_n\rangle$ and diagonal ensemble result for the local spin operator $\langle \sigma(0)\rangle_{\rm DE}$ for the $n$th eigenstate of the initial Hamiltonian~\eqref{FT} $H_i = H(1,0.1)$, constructed with energy cutoff $E_\Lambda$ in the TSM procedure. The state is time evolved according to the final Hamiltonian $H_f = H(1,0.2)$. The $n=100$ state is a rare state, whilst the others are broadly consistent with the microcanonical ensemble, see Figs.~\ref{Fig:DEMCE}~and~\ref{Fig:TimeEvoRareThermal}. The microcanonical result is $\langle \sigma(0)\rangle_{\rm MCE} = -0.693097 \pm 0.129259$, with the uncertainty showing the standard deviation of values averaged over in the energy window of width $\Delta E = 0.1$.} \vskip 10pt \begin{tabular}{ccc} \hline\hline \hspace{0.75cm}$n$\hspace{0.75cm} & \hspace{0.75cm}$E_n$\hspace{0.75cm} & \hspace{0.75cm}$\langle \sigma(0)\rangle_{\rm DE}$\hspace{0.75cm} \\ \hline 100 & 5.19928 & -0.32158 \\ 185 & 5.21496 & -0.550455 \\ 333 & 5.15805 & -0.657668 \\ 352 & 5.19533 & -0.718688 \\ 502 & 5.19786 & -0.83252 \\ \hline \hline \end{tabular} \label{Table:States} \end{table} Having chosen our initial states with similar energies, we compute their time evolution using the TSM+CHEB explained in Sec.~\ref{Sec:Cheb}. The time evolution of the local magnetization $\sigma(0)$ is shown in the solid lines of Fig.~\ref{Fig:TimeEvoRareThermal}, with dashed lines of the same color corresponding to the DE prediction. The shaded region shows the MCE prediction, with the vertical extent denoting the standard deviation of the data averaged over. As expected, thermalizing states have time evolution compatible with relaxation to the MCE and DE predictions (some of the thermalizing states selected, e.g. $n=185$ and $n=502$, are on the edges of what we call thermal). On the other hand, the rare $n=100$ state is oscillating about a value consistent with the DE result, which is far from the MCE prediction. \begin{figure} \includegraphics[width=0.45\textwidth]{TimeEvo_Rare_Thermal.pdf} \caption{Time evolution of the local spin operator $\sigma(0)$ following a quench $H_i = H(1,0.1) \to H_f = H(1,0.2)$ computed via TSM+CHEB. Each data set starts from a different eigenstate $n$ of the initial Hamiltonian. Dashed lines denote the diagonal ensemble prediction for the long time limit, whilst the shaded region shows the thermal result from the microcanonical ensemble (with the uncertainty representing the standard deviation of the data averaged over).} \label{Fig:TimeEvoRareThermal} \end{figure} In examining Fig.~\ref{Fig:TimeEvoRareThermal}, we do see some apparent differences between the time evolution of the rare states and close-in-energy thermal states. The rare state, $n=100$, exhibits large amplitude low frequency oscillations, whilst the thermal states have many more oscillation frequencies, highlighted in the power spectra of Fig.~\ref{Fig:PowerRareThermal}. The relaxation towards the DE/MCE is rapid for the thermal states, with only small amplitude oscillations beyond times $t\sim30$. In contrast, the rare state still has large amplitude oscillations at the longest accessible times, and it is not clear that these decay within the time frame $mt \sim 100$. These results suggest that one can diagnose rare states even in the short time dynamics by looking for states which exhibit large (and slow decaying) oscillations in observables. Indeed, this is reminiscent of the behavior observed in lattice simulations with confinement~\cite{kormos2016realtime}, where the light cone spreading of correlations is suppressed (but not entirely removed, cf. Ref.~\cite{delfino2018correlation} and Fig. 3b of Ref.~\cite{kormos2016realtime}), leading to dominant `back and forth' oscillations of correlations. \begin{figure} \begin{tabular}{l} (a) \\ \includegraphics[width=0.45\textwidth]{PowerSpectrum_Rare.pdf}\\ (b) \\ \includegraphics[width=0.45\textwidth]{PowerSpectrum_Thermal.pdf} \end{tabular} \caption{Power spectrum $|\sigma(\omega)|^2$ for: (a) the $n=100$ rare state; (b) the $n=333,\,352$ thermalizing states as computed from data in Fig.~\ref{Fig:TimeEvoRareThermal}.} \label{Fig:PowerRareThermal} \end{figure} \section{Relation to the lattice problem} \label{Sec:Lattice} Up until now we have considered states in the perturbed Ising field theory~\eqref{FT}. An important question is whether any of the discussed behavior carries through to the lattice, or if it is an artifact of the scaling limit? To address this, we consider a lattice model whose scaling limit is described by~\eqref{FT}, and work away from this limit. Our lattice Hamiltonian reads \begin{align} H = J \sum_l \sigma^z_{l} \sigma^z_{l+1} + h^x \sum_l \sigma^x_{l} + h^z \sum_l \sigma^z_{l}, \label{lattice} \end{align} where we set the lattice spacing $a$ to one, $\sigma^{x,z}_n$ are the $x,z$ Pauli matrices at position $n$, $J$ is the Ising exchange, and $h^{x,z}$ are magnetic fields in the $x,z$ directions, respectively. Equation~\eqref{lattice} is a good description of CoNb$_2$O$_6$\cite{coldea2010quantum,kjall2011bound,cabrera2014excitations,robinson2014quasiparticle}, a quasi-one-dimensional Ising ferromagnet in which linearly confined domain wall excitations have been observed via inelastic neutron scattering and THz spectroscopy~\cite{coldea2010quantum,wang2015spinon,wang2016from,morris2014hierarchy}. The scaling limit that reproduces~\eqref{FT} is~\cite{zamolodchikov1989integrals,fonseca2003ising} \begin{gather} J \to \infty, \quad a \to 0, \quad h^x \to 1,\quad h^z \ll 1,\nonumber \\ m = 2J\vert 1 - h^x\vert,\quad 2Ja=1. \nonumber \end{gather} The lattice model~\eqref{lattice} has been investigated extensively, with the quench dynamics receiving particular attention~\cite{banuls2011strong,kim2013ballistic,kim2014testing,kim2015slowest,zhang2015thermalization,kormos2016realtime,lin2017quasiparticle,mazza2018suppression}. $\!$~~\textcite{banuls2011strong} showed that certain initial states do not appear to thermalize, in spite of the lack of integrability. It is thought that this is linked to the presence of rare states in the spectrum~\cite{kormos2016realtime,mazza2018suppression}. On the other hand, Ref.~\cite{kim2014testing} studied whether for certain parameter regimes all eigenstates of~\eqref{lattice} obey ETH---finding certain sets of parameters where this did appear to be the case from small system exact diagonalization. Putting these results together, it appears the precise details of the parameter regime matter. This is perhaps not surprising, as the physics contained within this simple lattice model is rather rich~\cite{mccoy2014twodimensional}. In the following subsection we will show that, indeed, rare states exist within the spectrum of this lattice model, at least for certain values of the parameters. \subsection{Eigenstate expectation values} To begin our study of the lattice model, Eq.~\eqref{lattice}, we consider the EEV spectrum for low-energy states. To do so, we use DMRG to construct eigenstates in a finite (open) chain of $N=20-40$ sites. We first use the standard finite-size DMRG technique~\cite{schollwock2011densitymatrix} to find the ground state, and subsequently construct excited states using projector methods (see, e.g., Ref.~\cite{stoudenmire2012studying} for a detailed explanation of this approach). With the projector method, it is important to remember that excited states may not be found in order, but provided one constructs a sufficient number of states (and chooses the `weight parameter' of the procedure carefully) it is possible to correctly construct the low energy spectrum. In our DMRG simulations, the truncation error was $10^{-10}$ and we allowed up to 20 finite size sweeps (20 left and 20 right sweeps) for each state. As a check of our routines, we compared the spectrum computed for $N=14$ sites with that obtained from exact diagonalization of the Hamiltonian, finding excellent agreement. To draw analogies between the lattice model~\eqref{lattice} and the continuum theory~\eqref{FT}, in particular in order to compare to Fig.~\ref{Fig:EEVs}, we compute the average magnetization across the chain. This mimics a projection onto the zero (quasi-)momentum sector of the theory, which is studied in the field theory. We remind the reader that eigenstates of the field theory are translationally invariant and hence satisfy \begin{align} \langle E| \sigma(0) | E \rangle = \frac{1}{R} \int_0^R {\rm d} x \langle E | \sigma(x) | E \rangle, \end{align} where $|E\rangle$ is any eigenstate. \begin{figure} \begin{tabular}{l} (a) $N=20$ \\ \includegraphics[width=0.45\textwidth]{Lattice_N20_nofalsevac.pdf} \\ (b) $N=30$ \\ \includegraphics[width=0.45\textwidth]{Lattice_N30_nofalsevac.pdf} \\ (c) $N=40$ \\ \includegraphics[width=0.45\textwidth]{Lattice_hz005.pdf}\\ \end{tabular} \caption{The eigenstate expectation values for the chain-averaged magnetization $\frac{1}{N}\sum_{l=1}^N \langle \sigma_l^z \rangle$ in the lowest $\sim150$ states of the lattice model, Eq.~\eqref{lattice}, with $J=-1$, $h^x = -0.5$ and $h^z = 0.05$. Eigenstates were computed with DMRG for a chain of (a) $N=20$; (b) $N=30$; (c) $N=40$ sites. We encourage the reader to compare this to the analogous plot in the scaling limit, Fig.~\ref{Fig:EEVs}, and note the striking similarity. In plotting (a), (b), we exclude the false vacuum state. The labels in (c) indicate the states shown in Fig.~\ref{Fig:lattice_mag}.} \label{Fig:LatticeExpectationValues} \end{figure} \begin{figure} \includegraphics[width=0.45\textwidth]{Sz_profile_hx0_5hz0_05.pdf}\\ \caption{The spin expectation value $\langle \sigma_\ell^z \rangle$, on each site $\ell =1,2,\cdots,40$, for the 0th (ground), 1st, 44th, 48th and 51st states in the spectrum as found using DMRG. These states are marked in Fig.~\ref{Fig:LatticeExpectationValues}(c). The 1st and 48th states are examples of mesons localized on the boundary.} \label{Fig:lattice_mag} \end{figure} In Fig.~\ref{Fig:LatticeExpectationValues} we present data from our lattice simulations for~\eqref{lattice} with $J=-1$, $h^x = -0.5$ and $h^z = 0.05$ for three system sizes. This should be compared to analogous Figs.~\ref{Fig:EEVs} in the field theory; the similarity between lattice and field theory calculations is rather striking. We see a clear band of nonthermal states above a multiparticle `continuum' (this appears rather discrete due to the relatively small number of sites, $N=20-40$, but would broaden into a continuum in the large $N$ limit). It is worth noting that in the DMRG simulations on an open system, the meson excitations are localized in the vicinity of the boundaries due to the decreased energy cost of such excitations there. We plot the local magnetization $\langle \sigma^z_l\rangle$ in a number of representative states in Fig.~\ref{Fig:lattice_mag}; the corresponding states are labeled in Fig.~\ref{Fig:LatticeExpectationValues}(c). It is also worth noting that we are only able to access the low-energy part of the spectrum. We will see in the following section that this part of the spectrum is well converged as a function of system size $N$, being representative of the thermodynamic limit -- implying that the low-energy meson states remain well-separated from the continuum in the infinite volume limit. We cannot, however, rule out that the meson states melt into the continuum with increasing energy (although, we note, there is no evidence of this for the states that we can construct). Speculatively, such behavior in the scaling limit could be caused by the presence of marginal or irrelevant operators (neglected in the field theory Hamiltonian~\eqref{FT}), which are difficult to incorporate into a truncated spectrum treatment. Further investigations of the lattice model, which is already known to exhibit anomalous dynamics~\cite{banuls2011strong,kormos2016realtime,lin2017quasiparticle,mazza2018suppression}, are undoubtedly warranted. \subsubsection{Comparison between the finite size scaling of the EEV spectrum on the lattice and in the continuum} \label{sec:EEVRdep} As in the continuum, we can ask to what extent the rare states on the lattice persist to large volumes. To do so, we consider the finite size scaling of the low-energy EEV spectrum, which we also compare to that in the continuum. In order to make a like-for-like comparison between results at different system sizes, in this part of the appendix we focus on the \textit{total} magnetization of the eigenstates relative to the ground state (i.e., the number of flipped spins in the eigenstate) as a function of energy (relative to the ground state) of the eigenstate. We focus on total magnetization to avoid obvious problems with scaling with volume of local magnetization: the states we construct have $O(1)$ flipped spins compared to the ground state and hence in the thermodynamic limit have the same magnetization \textit{density} as the ground state. \begin{figure} \includegraphics[width=0.45\textwidth]{Rconvergence_Lattice.pdf} \caption{The EEV spectrum obtained by DMRG on the finite lattice of $N$ sites for the Hamiltonian~\eqref{lattice} with $J=-1$, $h^x=-0.5$ and $h^z = 0.05$. Here we consider the \textit{total magnetization} of the eigenstates relative to the ground state, as a function of energy (relative to the ground state energy $E_0$). See Fig.~\ref{Fig:LatticeExpectationValues} for further details.} \label{Fig:Rconvlatt} \vspace{3mm} \includegraphics[width=0.45\textwidth]{Rconvergence.pdf} \caption{The EEV spectrum for $m=1$, $g=0.1$ in systems of sizes $R=25-45$ (see Figs.~\ref{Fig:EEVs} for details). Here we plot the \textit{total} magnetization (relative to the ground state) as a function of energy (relative to the ground state). We see that the meson states are well converged as a function of system size $R$, while the thermal continuum is qualitatively converged (in the sense that the features are correct, but the density of state increases with increasing $R$). Note the striking similarity to Fig.~\ref{Fig:Rconvlatt}.} \label{Fig:Rconv} \end{figure} With this in mind, the results of Fig.~\ref{Fig:LatticeExpectationValues} are translated into Fig.~\ref{Fig:Rconvlatt} (the corresponding continuum results, Fig.~\ref{Fig:EEVs}, become Fig.~\ref{Fig:Rconv}). We see that low energy EEV spectrum at different lattice sizes $N$ (system sizes $R$) is well converged: meson state EEVs are well converged and match for different values of $N$ ($R$). The thermal continuum is also qualitatively well converged at low energies, in the sense that the features are correct, but the density of states increases with increasing $N$ ($R$). In Figs.~\ref{Fig:Rconvlatt} and~\ref{Fig:Rconv}, it is nevertheless easy to see that the meson states in the low-energy part of the spectrum remain well-separated from the thermal continuum, and results are converged to the thermodynamic limit, being independent of $N$ and $R$. \subsection{Eigenstate entanglement properties} We finish our consideration of the lattice model with a study of the entanglement properties of the states constructed within DMRG. Much like with the EEV spectrum, we compute the entanglement entropy under a real space bipartition of the system, and average over all bipartitions to avoid probing real space structure of the states. That is, if $S_E(n)$ corresponds to the bipartition of the system on bond $n$, we plot $\sum_n S_E(n)$. Results are presented in Fig.~\ref{fig:SE}. \begin{figure} \begin{tabular}{l} (a) \\ \includegraphics[width=0.45\textwidth]{SE_Ndep.pdf} \\ (b) \\ \includegraphics[width=0.45\textwidth]{SEoverN_Ndep.pdf} \end{tabular} \caption{(a) The entanglement entropy averaged over bipartitions of the system, $\sum_n S_E(n)$, in each eigenstate of energy $E$ relative to the ground state, for the lattice model ~\eqref{lattice} with $J=-1$, $h^x=-0.5$ and $h^z = 0.05$. Data is presented for three different system sizes $N$. We see that there are two classes of states: those that have $N$-independent entanglement (i.e. area law states) and those with volume law entanglement (linear in $N$). The presence of volume law entanglement states is shown more clearly in (b), where we scale the bipartition averaged entanglement by dividing through by the volume $N$. The nonthermal states have area law entanglement, while the thermal states have volume law.} \label{fig:SE} \end{figure} In our results, we see that there are two classes of states within the low-energy spectrum, which display different scaling with system size $N$. Beginning at the lowest energies and persisting through the spectrum, there are states whose entanglement is (essentially) $N$-independent -- so-called area law states. These are in one-to-one correspondence with the nonthermal states seen in the EEV spectrum. These are clear to see in the first panel, Fig.~\ref{fig:SE}(a). On the other hand, we have states whose entanglement varies with $N$, volume law states, which correspond to those states in the thermal continuum of the EEV spectrum. This is more clearly seen in Fig.~\ref{fig:SE}(b), where we have scaled the y-axis by the volume $N$. We thus see that the nonthermal meson states have properties, from the viewpoint of entanglement, that are very different from the thermal continuum. It seems reasonable to expect that the same dichotomy occurs in the field theory, where it is difficult to compute such entanglement measures. \section{Conclusions} \label{Sec:Conclusions} ETH is key to understanding whether quantum systems thermalize. When ETH is valid, and matrix elements of operators in the eigenbasis satisfy Eq.~\eqref{eth}, expectation values of operators within an eigenstate are thermal, and dynamics following a quantum quench are expected to lead to thermalization. In this work, we have shown an explicit example of a nonintegrable model, Eq.~\eqref{FT} and its lattice regularization Eq.~\eqref{lattice}, where ETH is violated. This is signaled through the presence of rare states in the spectrum, with expectation values within these states being nonthermal. To show this, we used TSMs and explicitly construct the low-energy spectrum of the theory. With the eigenstates at hand, we established the nature of the rare states that violate ETH: they arise as a direct result of confinement, corresponding to the well-known ``meson'' states: single particle excitations that can have extensive energy ($E\propto R$). These excitations are formed from pairs of linearly confined ``domain wall fermions'' and remain kinematically stable far above the threshold of the multiparticle continuum. This surprising result can, however, be understood by means of perturbative calculations of the meson lifetime and energy corrections, combining both a standard Bethe-Salpeter analysis for the mesons with a perturbative treatment of the meson-to-four-fermion vertices. This reveals only a very weak hybridization of the meson with the multiparticle continuum. This implies that just slight dressing of the two-fermion excitation can render the excitation absolutely stable. A finite size scaling TSM analysis is consistent with the meson states remaining nonthermal in the infinite volume limit, see Figs.~\ref{Fig:fss} and~\ref{Fig:Rconv}. With rare states established within the spectrum of the model through the study of EEVs, we turned our attention to understanding their influence on nonequilibrium dynamics. We first showed, through construction of the diagonal ensemble, that certain quantum quenches exhibit an absence of thermalization in the infinite time limit. This is in spite of the fact that our model is nonintegrable. Subsequent studies of the real-time nonequilibrium time evolution of observables revealed that rare states have EVs that show large amplitude, low frequency oscillations that appear not to decay on relatively long time scales $t\sim 100|m|^{-1}$. This should be contrasted to thermalizing states, which rapidly relax to their thermal values, showing only small fluctuations about their diagonal ensemble value. These difference may help diagnose rare states in experiments on, e.g., cold atoms. Finally, we addressed whether the violation of ETH in~\eqref{FT} is related to the scaling limit. To do so, we considered the lattice regularization of the model (e.g., the spin chain whose scaling limit gives the field theory) explicitly away from the scaling limit. Using DMRG we constructed the low-energy spectrum and present the EEV spectrum (at low energies). This has striking similarities to the EEV spectrum in the scaling limit, including the presence of a band of rare states above the multiparticle continuum. This finding suggests that confinement-induced rare states are not a remnant of the scaling limit, and supports previous results (see e.g. Ref.~\cite{kormos2016realtime}) that ascribed anomalous nonequilibrium dynamics to the presence of rare states in the spectrum. They may also be responsible for a lack of transport observed in time-evolution of the domain wall initial state~\cite{mazza2018suppression}. We do note, however, that we were unable to probe energies far into the spectrum and could not rule out that on the lattice such states melt into the continuum at finite energy densities. The rare states in the field theory~\eqref{FT} are intimately related to the presence of a linearly confining potential for the domain wall excitations. We note that recent work on confined phases in holographic theories also suggests an absence of thermalization~\cite{myers2017holographic}, which may lead one to speculate that models with confinement in general exhibit a lack of thermalization. This is partially supported by recent results of the authors~\cite{james2018nonthermal} that show anomalous nonequilibrium dynamics in a two-dimensional model with confinement that are completely analogous to the one-dimensional problem~\cite{kormos2016realtime}. It would be interesting to test this conjecture in other theories, such as the Schwinger model~\cite{buyens2014matrix,buyens2016confinement,banuls2016chiral,buyens2017realtime,buyens2017finiterepresentation,banuls2017density,nandkishore2017many,akhtar2018symmetry} or the $q$-state Potts model~\cite{lencses2015confinement,rutkevich2017radiative}, with the view that this may have important consequences in the context of quantum chromodynamics (which has some parallels with the quantum magnetism discussed here~\cite{sulejmanpasic2017confinement}). We finish by noting that recent works suggest that other kinetic constraints, beyond those provided by confinement, can also lead to nonthermal behavior~\cite{ates2012thermalization,ji2013equilibration,vanhorssen2015dynamics,lan2018quantum,turner2017quantum,khemani2018signatures,ho2018periodic,lin2018exact,turner2018quantum,choi2018emergent}. This may have important implications for experiments on Rydberg gases~\cite{bernien2017probing}. \acknowledgments{ We gratefully acknowledge useful conversations with Mari Carmen Ba\~nuls, Bruno Bertini, Mario Collura, Axel Cort\'es Cubero, Fabian Essler, Alessio Lerose, Dante Kennes, M\'arton Kormos, Andreas L\"auchli, Ian Mondragon-Shem, Marcos Rigol, and Gabor Tak\'acs. Parts of this work made use of ChainAMPS~\cite{james2013understanding,james2015quantum,james2018nonperturbative} and ALPS~\cite{albuquerque2007alps,bauer2011alps} routines. Work at Brookhaven National Laboratory was supported by the U.S. Department of Energy, Office of Basic Energy Sciences, under Contract No. DE-SC0012704. A.J.A.J. acknowledges support from the Engineering and Physical Sciences Research Council, grant number EP/L010623/1. N.J.R. is supported by the EU's Horizon 2020 research and innovation programme under grant agreement No 745944. N.J.R., A.J.A.J. and R.M.K. acknowledge the Simons Collaboration Programme entitled ``The Nonperturbative Bootstrap'' as part of the ``Hamiltonian methods in strongly coupled Quantum Field Theory'' meeting at the IHES Universit\'e Paris-Saclay. N.J.R. and R.M.K. also acknowledge the support of the Erwin Schr\"odinger International Institute for Mathematics and Physics, University of Vienna, during the ``Quantum Paths'' program. N.J.R. would further like to acknowledge the Aspen Center for Physics (supported by NSF grant PHY-1066293), the Simons Center for Geometry and Physics at SUNY Stony Brook, and University College London for hospitality during parts of this work. }
\section{Introduction} The connection between random matrices and free probability was first presented in \cite{MR1094052}. This type of construction was extended to the fluctuations and higher-order statistics of random matrices in \cite{MR2216446, MR2294222, MR2302524} in the complex case and in \cite{MR3217665, 2015arXiv150404612R} in the real and quaternionic cases. (Unlike in the first-order case, where the asymptotic behaviour of random matrices is identical in all three cases, the asymptotic higher-order behaviour depends on whether the matrices are real, complex, or quaternionic, or more accurately on whether the probability distribution of the random matrix is orthogonally invariant, unitarily invariant, or symplectically invariant, respectively.) The free cumulants of Speicher (see, e.g.\ \cite{MR2266879}) are quantities which, when applied to mutually free elements will vanish. They can thus be used to test for freeness. They can also be used to compute moments of elements generated by free subalgebras when the moments are known on each subalgebra. The matrix cumulants of \cite{MR2240781, MR2337139, MR2483727} provide a similar construction for finite-dimensional random matrices. These are constructed in terms of a convolution as well as in terms of a geometric projection. These quantities are multiplicative over algebras of random matrices which are independent and unitarily (respectively orthogonally, symplectically) invariant (this definition also depends on the symmetry of the random matrix's probability distribution), and can thus be used to compute moments of expressions in the algebra generated by ensembles of independent matrices in general position if the moments, and hence the matrix cumulants, of the individual ensembles are known. In these papers, it is shown that the asymptotic values of the matrix cumulants are the free cumulants of the limit distribution of the random matrices. \begin{figure} \centering \begin{tabular}{c} \input{orthogonal_cumulant.pdf_t}\\ \input{matrix_cumulant.pdf_t} \end{tabular} \caption{A summand in the topological expansion of an expression with Haar-distributed orthogonal matrces \(O\) and arbitrary orthogonally invariant random matrices \(X_{1},\ldots,X_{7}\) (top), and the corresponding surface gluing in the topological expansion for the \(X_{1},\ldots,X_{7}\) (bottom).} \label{figure: orthogonally invariant} \end{figure} \begin{figure} \centering \begin{tabular}{cc} \input{vertex-1.pdf_t}&\input{vertex-2.pdf_t}\\ \input{vertex-3.pdf_t}&\input{vertex-4.pdf_t} \end{tabular} \caption{The vertices which appear on the surface constructed in Figure~\ref{figure: orthogonally invariant}, bottom.} \label{figure: vertices} \end{figure} The connection between matrix cumulants and topological expansion is described in \cite{MR3217665, 2015arXiv151101087R}. If \(X_{1},\ldots,X_{7}\) are random matrices with orthogonally invariant distributions, a matrix integral which is a product of traces, such as, for example, \begin{equation} \mathbb{E}\left(\mathrm{tr}\left(X_{1}X_{2}X_{3}\right)\mathrm{tr}\left(X_{4}X_{5}X_{6}X_{7}\right)\right) \label{formula: example moment} \end{equation} may be computed by summing over surfaces glued from faces corresponding to the traces (see Figure~\ref{figure: orthogonally invariant}). The lower diagram shows such a gluing. The summand corresponding to this surface is \[N^{2F-\chi}c_{\pi}\left(X_{1},\ldots,X_{7}\right)\] where \(N\) is the dimension of the matrix, \(F\) is the number of traces in the integral, \(\chi\) is the Euler characteristic of the surface, and \(c_{\pi}\left(X_{1},\ldots,X_{7}\right)\) is the cumulant associated to the collection of four vertices which appear on the resulting surface (see Figure~\ref{figure: vertices}; note \(X_{4}^{T}\) and \(X_{7}^{T}\) which appear on the ``backs'' of the corners containing \(X_{4}\) and \(X_{7}\), respectively). The topological expansion for orthogonally invariant matrices follows from the topological expansion for Haar-distributed orthogonal matrices \(O\), which may be expressed as a sum over pairings on the first and second indices of \(O\) \cite{MR2217291,MR2337139,2015arXiv151101087R}. A matrix cumulant is the sum over pairings on the second index for a fixed choice of pairing on the first index. (An example is shown in the top part of Figure~\ref{figure: orthogonally invariant}, with the pairing on the first indices shown in solid lines, and the second indices marked with dotted lines (unpaired). This cumulant corresponds to the gluing shown in the lower part of Figure~\ref{figure: orthogonally invariant}. See Example~\ref{example: gluing} for more detail. If any of the \(X_{k}\) are independent and orthogonally in general position, they may be conjugated by independent Haar matrices, say \(O_{1}\) and \(O_{2}\). In this case, we do not need to consider terms in which independent Haar matrices are connected (by either index), so any term in which \(O_{1}\) and \(O_{2}\) are connected will vanish, and the contribution of the diagram will be the product of the contribution of the \(O_{1}\) vertices and the contribution of the \(O_{2}\). Thus, independent matrices in general position can be thought of as different colours. Only gluings which respect this colouring need be considered. For example, in Figure~\ref{figure: orthogonally invariant}, if \(X_{1}\) and \(X_{4}\) are independent and orthogonally in general position, this term term will vanish. If \(X_{1}\), \(X_{2}\), \(X_{4}\), and \(X_{5}\) as a set are independent from \(X_{3}\), \(X_{6}\) and \(X_{7}\), then the contribution of the lower diagram in Figure~\ref{figure: orthogonally invariant} will be the product of the contribution of the two upper vertices in Figure~\ref{figure: vertices} and the contribution of the two lower vertices. In this way, if the matrix cumulants of independent ensembles in general position are known, it is possible to compute the matrix cumulants, and hence the moments such as (\ref{formula: example moment}), of any expression generated by those ensembles. The contribution is not, however, multiplicative over the vertices in general (i.e.\ the matrix cumulant is not the product of the four matrix cumulants associated to the four vertices). In this topological interpretation, it is natural to ask what the difference is between the product of the cumulants of the vertices individually or in subsets and the cumulant of the vertices together. A natural way to do so is similar to the construction of classical cumulants, where we consider the quantities such as the two-vertex cumulant \[c_{V_{1},V_{2}}\left(X_{1},\ldots,X_{n}\right)-c_{V_{1}}\left(X_{1},\cdots,X_{n}\right)c_{V_{2}}\left(X_{1},\ldots,X_{n}\right)\] where \(c_{V_{1},V_{2}}\) is the cumulant corresponding to the two vertices \(V_{1}\) and \(V_{2}\), and \(c_{V_{i}}\) is the cumulant corresponding to vertex \(V_{i}\) (see Definition~\ref{definition: vertex cumulants} for the general construction). These quantities can be thought of as the difference of the cumulants from being multiplicative. While these quantities do not in general vanish, if the matrices satisfy cerain convergence properties, the cumulants on a larger number of vertices are lower-order: specifically, the vertex cumulants on one vertex are \({\cal O}\left(1\right)\), while the vertex cumulants on \(V\) vertices are \({\cal O}\left(N^{2-2V}\right)\). In this sense, the matrix cumulants are asymptotically multiplicative. These quantities possess a number of other useful properties for computing matrix integrals diagrammatically. In addition, these cumulants have the desirable property of vanishing when they are applied to independent matrices in general position. (When the contribution from the vertices is multiplicative, the difference from the product of the contributions vanishes.) Finally, we find that the asymptotic limit of the appropriately renormalized two-vertex cumulants are the second-order real free cumulants, quantities which vanish when applied to elements which are second-order free. In Section~\ref{section: preliminaries}, we define notation and introduce relevant lemmas. (Other notation and lemmas will appear in the sections to which they are relevant, if this scope is limited.) In Section~\ref{section: poset} we construct a useful poset which extends the annular noncrossing permutations, and compute its M\"{o}bius function. The values of this M\"{o}bius function will be used to compute the coefficients in the expression for the second-order real cumulants. In Section~\ref{section: freeness}, we present expressions for the second-order real cumulants, and demonstrate that the vanishing of mixed cumulants is equivalent to second-order real freeness. In Section~\ref{section: matrix} we construct the vertex cumulants from the matrix cumulants and present a number of useful properties. In Subsection~\ref{subsection: asymptotics} we discuss the asymptotic properties of the vertex cumulants. In Subsection~\ref{subsection: second-order} we discuss the second-order case and show that the asymptotic limit of a two-vertex cumulant is a second-order cumulant. Generalization to higher-order freeness is discussed in \ref{subsection: higher-order}. Section~\ref{section: freeness} and Section~\ref{section: matrix} may be read somewhat independently from each other. In Section~\ref{section: quaternion}, we outline the construction in the quaternionic case. \section{Preliminaries} \label{section: preliminaries} \subsection{Partitions and permutations} \begin{definition} We denote the set of integers \(\left\{1,\ldots,n\right\}\) by \(\left[n\right]\). A {\em partition} of a set \(I\) is a set \(\left\{U_{1},\ldots,U_{k}\right\}\) of nonempty subsets of \(I\) called {\em blocks} such that \(U_{i}\cap U_{j}=\emptyset\) for \(i\neq j\) and \(U_{1}\cup\cdots\cup U_{k}=I\). We denote the number of blocks of a partition \({\cal U}\) by \(\#\left({\cal U}\right)\). The set of partitions of \(I\) is denoted \({\cal P}\left(I\right)\) and the set of partitions of \(\left[n\right]\) by \({\cal P}\left(n\right)\). The partitions may be given a partial order by letting \({\cal U}\preceq{\cal V}\) when every block of \({\cal U}\) is contained in a block of \({\cal V}\). \end{definition} \begin{definition} We denote the set of permutations on set \(I\) by \(S\left(I\right)\), and \(S\left(\left[n\right]\right)\) by \(S\left(n\right)\). The orbits (cycles) of a permutation form a partition of its domain. For \(\pi\in S\left(I\right)\) we denote this partition by \(\Pi\left(\pi\right)\). When it is clear, we will sometimes use \(\pi\) to denote this partition as well as the permutation. We note that \(\pi^{-1}\), as well as any conjugate of \(\pi\), have the same cycle structure as \(\pi\). For \(\pi\in S\left(I\right)\) and subset \(J\subseteq I\), the permutation induced by \(\pi\) on \(J\), denoted \(\left.\pi\right|_{J}\), is the permutation where \(\left.\pi\right|_{J}\left(a\right)=\pi^{k}\left(a\right)\), where \(k>1\) is the smallest exponent such that \(\pi^{k}\left(a\right)\in J\). (This is the permutation obtained from \(\pi\) in cycle notation by deleting all elements not in \(J\)). The permutation induced by \(\pi\) on partition \({\cal U}=\left\{U_{1},\ldots,U_{k}\right\}\) is the product of the permutations induced on each of its blocks: \(\left.\pi\right|_{{\cal U}}:=\left.\pi\right|_{U_{1}}\cdots\left.\pi\right|_{U_{k}}\). To simplify notation, we will often write \(\left.\pi\right|_{\rho}\) for a permutation \(\rho\) for \(\left.\pi\right|_{\Pi\left(\rho\right)}\). We let \[\tau_{n}=\left(1,\ldots,n\right)\] and \[\tau_{p,q}=\left(1,\ldots,p\right)\left(p+1,\ldots,p+q\right)\textrm{.}\] For a permutation \(\rho\), the {\em Kreweras complement} is \[\mathrm{Kr}_{\rho}\left(\pi\right):=\pi^{-1}\rho\textrm{.}\] We write \(\mathrm{Kr}_{p,q}\left(\pi\right)\) for \(\mathrm{Kr}_{\tau_{p,q}}\left(\pi\right)\). (For more on the topological and graph theoretical interpretation of this and the related constructions, see e.g.\ \cite{MR1603700, MR2036721}.) The Euler characteristic of \(\pi\) (on \(\rho\)) is \[\chi_{\rho}\left(\pi\right):=\#\left(\rho\right)+\#\left(\pi\right)+\#\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)-n\textrm{.}\] The Euler characteristic is less than or equal to \(2\) times the number of connected components: \[\chi_{\rho}\left(\pi\right)\leq 2\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\] (see \cite{MR2052516}). A permutation is said to be {\em noncrossing} (on \(\rho\)) if \[\chi_{\rho}\left(\pi\right)=2\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\textrm{.}\] We denote the set of \(\pi\) noncrossing on \(\rho\) by \(S_{\mathrm{nc}}\left(\rho\right)\), and \(S_{\mathrm{nc}}\left(p,q\right):=S_{\mathrm{nc}}\left(\tau_{p,q}\right)\). We denote the set of \(\pi\) such that \(\Pi\left(\pi\right)\preceq\Pi\left(\rho\right)\) by \(S_{\mathrm{disc-nc}}\left(\rho\right)\) (and \(S_{\mathrm{disc-nc}}\left(p,q\right):=S_{\mathrm{disc-nc}}\left(\tau_{p,q}\right)\)). We denote the \(\pi\in S_{\mathrm{nc}}\left(p,q\right)\) such that at least one cycle of \(\pi\) contains elements from both \(\left[p\right]\) and \(\left[p+1,p+q\right]\) by \(S_{\mathrm{ann-nc}}\left(p,q\right)\). For \(\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\), we call a cycle which has elements in both \(\left[p\right]\) and \(\left[p+1,p+q\right]\) a {\em bridge}. A poset may be constructed on \(S_{\mathrm{nc}}\left(\tau\right)\) by letting \(\pi\preceq\rho\) if \(\Pi\left(\pi\right)\preceq\Pi\left(\rho\right)\) and \(\pi\in S_{\mathrm{nc}}\left(\rho\right)\). If \(\tau\) has only one cycle, then this poset is the same as the poset on the partitions of the permutations. This poset is a lattice (any two elements \(\pi\) and \(\rho\) have a unique \(\sup\) \(\pi\vee\rho\) and \(\inf\) \(\pi\wedge\rho\)). It is also self-dual. (See \cite{MR2266879}, Chapters~9 and 10.) \end{definition} In the cases where \(\tau\) has \(1\) or \(2\) cycles, \(\pi\) being noncrossing is equivalent to a number of conditions on a fixed number of elements not occurring. \begin{lemma}[Biane] Let \(\tau\in S\left(I\right)\) have one cycle. Then \(\pi\in S_{\mathrm{nc}}\left(\tau\right)\) iff neither of the following conditions occurs: \begin{enumerate} \item There are \(a,b,c\in I\) such that \(\left.\tau\right|_{\left\{a,b,c\right\}}=\left(a,b,c\right)\) and \(\left.\pi\right|_{\left\{a,b,c\right\}}=\left(a,c,b\right)\). \item There are \(a,b,c,d\in I\) such that \(\left.\tau\right|_{\left\{a,b,c,d\right\}}=\left(a,b,c,d\right)\) and \(\left.\pi\right|_{\left\{a,b,c,d\right\}}=\left(a,c\right)\left(b,d\right)\). \end{enumerate} \label{lemma: disc noncrossing} \end{lemma} See \cite{MR1475837}. \begin{lemma}[Mingo, Nica] Let \(\tau:=\tau_{p,q}\). The annular nonstandard conditions are: \begin{enumerate} \item There are \(a,b,c\in\left[p+q\right]\) with \(\left.\tau\right|_{\left\{a,b,c\right\}}\left(a,b,c\right)\) and \(\left.\pi\right|_{\left\{a,b,c\right\}}\left(a,c,b\right)\). \label{item: ans1} \item There are \(a,b,c,d\in\left[p+q\right]\) with \(\left.\tau\right|_{\left\{a,b,c,d\right\}}\left(a,b\right)\left(c,d\right)\) and \(\left.\pi\right|_{\left\{a,b,c,d\right\}}\left(a,c,b,d\right)\). \label{item: ans2} \end{enumerate} For \(x,y\) in different cycles of \(\tau\), we let \[\lambda_{x,y}:=\left(\tau\left(x\right),\tau^{2}\left(x\right),\ldots,\tau^{-1}\left(x\right),\tau\left(y\right),\tau^{2}\left(y\right),\ldots,\tau^{-1}\left(y\right)\right)\textrm{.}\] The annular noncrossing conditions are: \begin{enumerate} \item There are \(a,b,c,d\in\left[p+q\right]\) with \(\left.\tau\right|_{\left\{a,b,c,d\right\}}\left(a,b,c,d\right)\) and \(\left.\pi\right|_{\left\{a,b,c,d\right\}}=\left(a,c\right)\left(b,d\right)\). \label{item: ac1} \item There are \(a,b,c,x,y\in\left[p+q\right]\) such that \(\left.\lambda_{x,y}\right|_{\left\{a,b,c\right\}}=\left(a,b,c\right)\) and \(\left.\pi\right|_{\left\{a,b,c,x,y\right\}}=\left(a,c,b\right)\left(x,y\right)\). \label{item: ac2} \item There are \(a,b,c,d,x,y\in\left[p+q\right]\) such that and \(\left.\lambda_{x,y}\right|_{\left\{a,b,c,d\right\}}=\left(a,b,c,d\right)\) and \(\left.\pi\right|_{\left\{a,b,c,d,x,y\right\}}=\left(a,c\right)\left(b,d\right)\left(x,y\right)\). \label{item: ac3} \end{enumerate} Then \(\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\) iff none of the following conditions occurs. \end{lemma} See \cite{MR2052516}. \begin{definition} Let \(p\) and \(q\) be fixed. For a permutation \(\pi\in S\left(p+q\right)\), we define \(\pi_{\mathrm{op}}\) to be the permutation constructed from \(\pi\) by switching \(p+1\) and \(p+q\), \(p+2\) and \(p+q-1\), and so on, in the cycle notation. \label{definition: opposite} \end{definition} If \(\pi\in S_{\mathrm{nc}}\left(p,q\right)\), then for \(\tau:=\tau_{p,q}\), \(\pi_{\mathrm{op}}\in S_{\mathrm{nc}}\left(\tau_{\mathrm{op}}\right)\). We note that \(\mathrm{Kr}_{\tau_{\mathrm{op}}}\left(\pi_{\mathrm{op}}\right)\) has the same cycle structure as \(\mathrm{Kr}_{p,q}\left(\pi\right)\). \begin{definition} We denote the set of \(\left({\cal U},\pi\right)\in{\cal P}\left(p+q\right)\times S_{\mathrm{disc-nc}}\left(p,q\right)\) such that \({\cal U}\succeq\Pi\left(\pi\right)\) by \({\cal PS}\left(p,q\right)\). We denote by \({\cal PS}^{\prime}\left(p,q\right)\) the set of \(\left({\cal U},\pi\right)\in{\cal PS}\left(I\right)\) such that each block of \({\cal U}\) contains exactly one block of \(\Pi\left(\pi\right)\), except one block \(U\in{\cal U}\) which contains exactly two blocks of \(\Pi\left(\pi\right)\), one contained in \(\left[p\right]\) and the other contained in \(\left[p+1,p+q\right]\). \end{definition} \subsection{Freeness} \begin{definition} A {\em noncommutative probability space} is a unital algebra \(A\) equipped with a linear functional \(\phi_{1}:A\rightarrow\mathbb{F}\) such that \(\phi_{1}\left(1\right)=1\). A {\em second-order probability space} has, in addition, a bilinear functional \(\phi_{2}:A^{2}\rightarrow\mathbb{F}\). A {\em real second-order probability space} must also have an involution \(x\mapsto x^{t}\) such that \(\left(xy\right)^{t}=y^{t}x^{t}\) and \(\phi_{1}\left(x^{t}\right)=\phi_{1}\left(x\right)\). \end{definition} \begin{definition} We say that an element of a noncommutative probability space \(x\in A\) is {\em centred} if \(\varphi_{1}\left(x\right)=0\). We denote the centred random variable \(x-\varphi_{1}\left(x\right)1=:\mathring{x}\). If noncommutative probability space has subalgebras \(A_{1},\ldots,A_{n}\), we say that variables \(x_{1},\ldots,x_{p}\in A_{1}\cup\cdots\cup A_{n}\) are {\em alternating} if \(x_{i}\) comes from a different algebra from \(x_{i+1}\), \(i=1,\ldots,p-1\). If in addition \(x_{p}\) comes from a different algebra from \(x_{1}\), we say that they are {\em cyclically alternating}. \end{definition} \begin{definition} \label{definition: second-order freeness} Subalgebras \(A_{1},\ldots,A_{n}\subseteq A\) of a noncommutative probability space are free if, for any \(x_{1},\ldots,x_{p}\) are centred and alternating, \[\varphi_{1}\left(x_{1}\cdots x_{p}\right)=0\textrm{.}\] Subalgebras of a second-order probability space are second-order real free if they are free, and if, for \(x_{1},\ldots,x_{p}\) and \(y_{1},\ldots,y_{q}\) centred and cyclically alternating, \begin{multline} \varphi_{2}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\=\left\{\begin{array}{ll}\sum_{k=1}^{p}\prod_{i=1}^{p}\varphi_{1}\left(x_{i}y_{\tau_{p,q}^{-k}\left(i\right)}\right)+\sum_{k=1}^{p}\prod_{i=1}^{p}\varphi_{1}\left(x_{i}y_{\tau_{p,q}^{k}\left(i\right)}\right)&p=q\\0\textrm{,}&p\neq q\end{array}\right. \label{formula: second-order freeness} \end{multline} (see \cite{MR3217665} for diagrams representing this formula). \end{definition} \begin{definition} Let \(\left(A,\varphi\right)\) be a noncommutative probability space, and let \(x_{1},\ldots,x_{n}\in A\). We let \[\alpha_{n}\left(x_{1},\ldots,x_{n}\right):=\varphi_{1}\left(x_{1}\cdots x_{n}\right)\textrm{.}\] Let \(I\subseteq\left[n\right]\), and let \[\pi=\left(c_{1},\ldots,c_{k_{1}}\right)\cdots\left(c_{k_{1}+\cdots+k_{m-1}+1},\ldots,c_{k_{1}+\cdots+k_{m}}\right)\in{\cal P}\left(I\right)\textrm{.}\] Then \[\alpha_{\pi}\left(x_{1},\ldots,x_{n}\right):=\varphi_{1}\left(x_{c_{1}}\cdots x_{c_{k_{1}}}\right)\cdots\varphi_{1}\left(x_{c_{k_{1}+\cdots+k_{m-1}+1}}\cdots x_{c_{k_{1}+\cdots+k_{m}}}\right)\textrm{.}\] \end{definition} \begin{definition}[Speicher] For \(n=1,2,\ldots,\) and for \(I\subseteq\left[n\right]\) and \[\pi=\left(c_{1},\ldots,c_{k_{1}}\right)\cdots\left(c_{k_{1}+\cdots+k_{m-1}+1},\ldots,c_{k_{1}+\cdots+k_{m}}\right)\in{\cal P}\left(I\right)\textrm{.}\] define the {\em free cumulants} \(\kappa_{n}:A^{n}\rightarrow\mathbb{C}\) and \(\kappa_{\pi}\), where \[\kappa_{\pi}\left(x_{1},\ldots,x_{n}\right):=\kappa\left(x_{c_{1}},\ldots,x_{c_{k_{1}}}\right)\cdots\kappa\left(x_{c_{k_{1}+\cdots+k_{m-1}+1}},\ldots,x_{c_{k_{1}+\cdots+k_{m}}}\right)\] by \begin{equation} \label{formula: free moment cumulant} \alpha\left(x_{1},\ldots,x_{n}\right)=\sum_{\pi\in S_{\mathrm{nc}}\left(n\right)}\kappa_{\pi}\left(x_{1},\ldots,x_{n}\right) \end{equation} or equivalently \begin{equation} \label{formula: free cumulant moment} \kappa_{n}\left(x_{1},\ldots,x_{n}\right):=\sum_{\pi\in S_{\mathrm{nc}}\left(n\right)}\mu\left(\pi,\tau_{n}\right)\alpha_{\pi}\left(x_{1},\ldots,x_{n}\right) \end{equation} (see Proposition~\ref{proposition: mobius} for the definition and value of the M\"{o}bius function \(\mu\left(\pi,\tau_{n}\right)\)). \end{definition} If subalgebras of a free probability space are free, cumulants on elements of the different subalgebras vanish; see \cite{MR2266879}. \section{A poset extending the annular noncrossing partitions} \label{section: poset} For a poset \({\cal P}\) and \(\pi,\rho\in{\cal P}\), we denote the set of \(\sigma\in{\cal P}\) with \(\pi\preceq\sigma\preceq\rho\) by \(\left[\pi,\rho\right]\). \begin{definition} The M\"{o}bius function of a poset \(P\) is the unique function \(\mu:P^{2}\rightarrow\mathbb{Z}\) where \(\mu\left(\pi,\rho\right)=0\) unless \(\pi\preceq\rho\), and for any \(\pi,\rho\in P\) with \(\pi\preceq\rho\) \[\sum_{\sigma\in\left[\pi,\rho\right]}\mu\left(\pi,\sigma\right)=\sum_{\sigma\in\left[\pi,\rho\right]}\mu\left(\sigma,\rho\right)=\left\{\begin{array}{ll}1\textrm{,}&\pi=\rho\\0\textrm{,}&\textrm{otherwise}\end{array}\right.\textrm{.}\] \end{definition} (See a standard combinatorics textbook, such as \cite{MR1311922}, Chapter 12, for more of the definitions and properties of posets and M\"{o}bius functions.) It will be convenient to extend a poset including \(S_{\mathrm{disc-nc}}\left(p,q\right)\) and \(S_{\mathrm{ann-nc}}\left(p,q\right)\) so that it is self-dual and has a largest element. \begin{definition} Let \(p,q>0\) be integers, and let \(S_{\mathrm{nc-sd}}\left(p,q\right)\) be the disjoint union of \(S_{\mathrm{ann-nc}}\left(p,q\right)\) with two copies of \(S_{\mathrm{disc-nc}}\left(p,q\right)\), which in this context we will denote \(S_{\mathrm{disc-nc}}\left(p,q\right)\) and \(\hat{S}_{\mathrm{disc-nc}}\left(p,q\right)\). If an element of the first copy is denoted \(\pi\), we will denote the corresponding element of the second copy by \(\hat{\pi}\). We define \(\widehat{\mathrm{Kr}}:S_{\mathrm{nc-sd}}\left(p,q\right)\rightarrow S_{\mathrm{nc-sd}}\left(p,q\right)\) to take \(\pi\) to an element whose underlying permutation is \(\mathrm{Kr}_{p,q}\left(\pi\right)\) and taking \(S_{\mathrm{disc-nc}}\left(p,q\right)\) to \(\hat{S}_{\mathrm{disc-nc}}\left(p,q\right)\) and {\em vice versa}. If \(\pi,\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\cup S_{\mathrm{ann-nc}}\left(p,q\right)\), then \(\pi\preceq \rho\) if \(\Pi\left(\pi\right)\preceq\Pi\left(\rho\right)\) and \(\pi\) is noncrossing on \(\rho\). If \(\pi\in S_{\mathrm{nc-sd}}\left(p,q\right)\) and \(\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\), \(\pi\preceq\hat{\rho}\) if \(\mathrm{Kr}\left(\pi\right)\succeq\mathrm{Kr}\left(\rho\right)\). (It can be easily verified that this creates a poset from the fact that \(S_{\mathrm{disc-nc}}\left(p,q\right)\cup S_{\mathrm{ann-nc}}\left(p,q\right)\) is a poset.) We denote the smallest element, \(\left(1\right)\cdots\left(p+q\right)\), by \(0_{p,q}\) or \(0\) if it is clear from the context. We denote the largest element, \(\widehat{\left(1,\ldots,p\right)\left(p+1,\ldots,p+q\right)}\), by \(1_{p,q}\) or \(1\). We will denote the M\"{o}bius function on \(S_{\mathrm{nc-sd}}\left(p,q\right)\) by \(\mu\). \end{definition} \begin{remark} We note that \(S_{\mathrm{nc-sd}}\left(p,q\right)\) is not a lattice. In \(S_{\mathrm{nc-sd}}\left(1,2\right)\), for example, both \(\left(1,2\right)\left(3\right)\) and \(\left(1,3\right)\left(2\right)\) are covered by both \(\left(1,2,3\right)\) and \(\left(1,3,2\right)\), so they do not have a unique supremum. \end{remark} We collect several technical results which we will need in Lemma~\ref{lemma: technical}. Roughly, these results show how an element of \(S_{\mathrm{ann-nc}}\left(p,q\right)\) can be constructed from an element of \(S_{\mathrm{disc-nc}}\left(p,q\right)\) by choosing the outside faces of the diagrams on the two discs, then connecting cycles to form bridges in a noncrossing way. (See Example~\ref{example: annuli} for the intuition behind the results.) \begin{lemma} Let \(\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\). Here \(\tau=\tau_{p,q}\) and \(\mathrm{Kr}=\mathrm{Kr}_{\tau}\). Let \(\pi_{0}:=\left.\pi\right|_{\tau}\in S_{\mathrm{disc-nc}}\left(p,q\right)\). Then: \begin{enumerate} \item Any bridge of \(\pi\) is of the form \(\left(a_{1},\ldots,a_{r},b_{1},\ldots,b_{s}\right)\), where \(a_{1},\ldots,a_{r}\in\left[p\right]\) and \(b_{1},\ldots,b_{s}\in\left[p+1,p+q\right]\). Therefore there is exactly one element \(a\) of a bridge in \(\left[p\right]\) (resp.\ \(\left[p+1,p+q\right]\)) with \(\pi\left(a\right)\in\left[p+1,p+q\right]\) (resp.\ \(\left[p\right]\)). \label{item: bridge} \item If all cycles of \(\pi\) are bridges, they are of the form, for some \(a\in\left[p\right]\) and some \(b\in\left[p+1,p+q\right]\), \(\left(a,\tau\left(a\right),\ldots,\tau^{r-1}\left(a\right),b,\tau\left(b\right),\ldots,\tau^{s-1}\left(b\right)\right)\). If, following one cycle of \(\tau\), we encounter the bridges of \(\pi\) in a given (cyclic) order, then they will be encountered in the reverse (cyclic) order following the other cycle of \(\tau\). Any \(\pi\) satisfying these two conditions is in \(S_{\mathrm{ann-nc}}\left(p,q\right)\). \label{item: all bridges} \item The set \(I\) of elements in bridges of \(\mathrm{Kr}\left(\pi\right)\) (resp. \(\mathrm{Kr}^{-1}\left(\pi\right)\)) comprise two orbits of \(\mathrm{Kr}\left(\pi_{0}\right)\) (resp.\ \(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\)), one contained in each of \(\left[p\right]\) and \(\left[p+1,p+q\right]\). (These may be viewed as the ``outside faces'' of the configuration; see Figure~\ref{figure: outside faces}.) The \(a\in\left[p\right]\) (resp.\ \(\left[p+1,p+q\right]\)) with \(\pi^{-1}\left(a\right)\in\left[p+1,p+q\right]\) (resp.\ \(\left[p\right]\)) are contained in \(I\). \label{item: outside faces} \item For \(\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\), \(\pi\preceq\hat{\rho}\) when \(\pi_{0}\preceq\rho\) and the bridges of \(\pi\) are contained in two cycles of \(\rho\) (necessarily one of which will be contained in \(\left[p\right]\) and the other in \(\left[p+1,p+q\right]\)). \label{item: partial order} \item Let \(\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\), and let \(J\) be the set of elements in two cycles of \(\rho\), one in each cycle of \(\tau\). Let \(\sigma_{1}\in S_{\mathrm{ann-nc}}\left(\left.\rho\right|_{J}\right)\) and \(\sigma_{2}\in S_{\mathrm{disc-nc}}\left(\left.\rho\right|_{\left[p+q\right]\setminus J}\right)\). Then \(\sigma:=\sigma_{1}\sigma_{2}\in S_{\mathrm{ann-nc}}\left(p,q\right)\) \label{item: piecewise} \item Let \(I\) be the set of elements in bridges of \(\mathrm{Kr}^{-1}\left(\pi\right)\), let \(J\) be the set of elements in the two cycles of \(\rho\) containing the bridges of \(\pi\), and let \(K:=I\cap J\). The elements of \(K\) form two cycles in \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\), one contained in each cycle of \(\tau\). \label{item: selected cycles} \item Any cycle of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\) is either fully contained in \(K\) or outside of it. \label{item: cycle partition} \item If a cycle of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\) is not in \(K\), then it also appears as a cycle of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\). \label{item: spare cycles} \item The cycles of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\) in \(K\) are all bridges; in fact, for any \(\pi_{0}\preceq\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\), any choice of noncrossing two-element bridges on \(\left.\tau\right|_{K}\) is induced by a unique \(\pi\preceq\hat{\rho}\) with \(\left.\pi\right|_{\tau}=\pi_{0}\) and this choice of outside faces of \(\pi_{0}\). \label{item: skeleton} \end{enumerate} \label{lemma: technical} \end{lemma} \begin{proof} \ref{item: bridge}.: This follows immediately from annular-nonstandard condition~\ref{item: ans2}. \ref{item: all bridges}.: Consider a bridge of \(\pi\) \(\left(a_{1},\ldots,a_{r},\ldots,b_{1},\ldots,b_{s}\right)\), \(a_{1},\ldots,a_{r}\in\left[p\right]\), \(b_{1},\ldots,b_{s}\in\left[p+1,p+q\right]\). If there is an \(x\in\left[p\right]\) which is not in this bridge, but which appears between \(a_{1}\) and \(a_{r}\) in \(\tau\), then there must be a \(y\in\left[p+1,p+q\right]\) in the same cycle of \(\pi\) as \(x\). Then \(\left.\pi\right|_{\left\{a_{1},a_{r},b_{1}\right\}}=\left(a_{1},a_{r},b_{1}\right)\) but \(\left.\lambda_{x,y}\right|_{\left\{a_{1},a_{r},b_{1}\right\}}=\left(a_{1},b_{1},a_{r}\right)\), so by annular-crossing condition~\ref{item: ac2}.\ \(\pi\notin S_{\mathrm{ann-nc}}\left(p,q\right)\). Likewise if an \(x\in\left[p+1,p+q\right]\) appears between \(b_{1}\) and \(b_{s}\) in \(\tau\). If the cycles of \(\pi\) do not intersect the two cycles of \(\tau\) in reverse cyclic order, then when we construct one of the \(\lambda_{x,y}\), it will be possible to find cycles of \(\pi\) with elements \(a\) and \(b\) (resp.\ \(c\) and \(d\)) from the two cycles of \(\tau\) such that \(\left.\lambda_{x,y}\right|_{\left\{a,b,c,d\right\}}=\left(a,c,b,d\right)\), satisfying annular-crossing condition \ref{item: ac3}. Conversely, let \(\pi\) have the form described in the statement. Then if \(\pi\left(a\right)\) in the same cycle of \(\tau\) as \(a\), \(\mathrm{Kr}\left(\pi\right)\left(a\right)=\pi^{-1}\tau\left(a\right)=\tau^{-1}\tau\left(a\right)=a\). If \(\pi\left(a\right)\) is not in the same cycle of \(\tau\) as \(a\), then \(\tau\left(a\right)\) is the first element of the next bridge of \(\pi\). Then \(\pi^{-1}\tau\left(a\right)\) is the last element of this bridge in the other cycle of \(\tau\) (and is thus not equal to \(a\)). Since the next cycle along the second cycle of \(\tau\) is the original bridge of \(\pi\) containing \(a\), \(\left(\pi^{-1}\tau\right)^{2}\left(a\right)=a\). This construction shows that \(\pi\) and \(\mathrm{Kr}\left(\pi\right)\) have the same number of bridges, say \(k\). We calculate that \(\chi\left(\pi\right)=2+k+\left(p+q-k\right)-\left(p+q\right)=2\), so \(\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\). \ref{item: outside faces}.: We demonstrate the result for \(\mathrm{Kr}^{-1}\); the proof for \(\mathrm{Kr}\) is similar. For every \(a\in\left[p\right]\) with \(\pi^{-1}\left(a\right)\in\left[p+1,q\right]\), \(\mathrm{Kr}^{-1}\left(\pi\right)\left(a\right)=\tau\pi^{-1}\left(a\right)\in\left[p+1,p+q\right]\), and, conversely, if \(a\in\left[p\right]\) and \(\mathrm{Kr}^{-1}\left(\pi\right)\left(a\right)\in\left[p+1,p+q\right]\), then \(\pi^{-1}\left(a\right)\in\left[p+1,p+q\right]\). By part~\ref{item: bridge}, a bridge has exactly one element it maps from \(\left[p\right]\) to \(\left[p+1,p+q\right]\) and exactly one element it maps from \(\left[p+1,p+q\right]\) to \(\left[p\right]\), so there must be the same number \(k\) of bridges in \(\pi\) as \(\mathrm{Kr}^{-1}\left(\pi\right)\). We know that \(\#\left(\pi\right)+\#\left(\mathrm{Kr}^{-1}\left(\pi\right)\right)=p+q\) and \(\#\left(\pi_{0}\right)+\#\left(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\right)=p+q+2\). By part~\ref{item: bridge}., \(\#\left(\pi_{0}\right)=\#\left(\pi\right)+k\) (since each bridge induces a cycle on each cycle of \(\tau\), and all other cycles induce a cycle on only one cycle of \(\tau\)), so \(\#\left(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\right)=\#\left(\mathrm{Kr}^{-1}\left(\pi\right)\right)-k+2\). The \(\#\left(\mathrm{Kr}^{-1}\left(\pi\right)\right)-k\) cycles of \(\mathrm{Kr}^{-1}\left(\pi\right)\) which are not bridges appear as cycles of \(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\): if \(\tau\pi^{-1}\left(a\right)\) is in the same cycle of \(\tau\) as \(a\), then it is equal to \(\tau\pi_{0}^{-1}\left(a\right)\). The elements of the bridges of \(\mathrm{Kr}^{-1}\left(\pi\right)\) must fall into at least two cycles of \(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\), so they must comprise the two remaining cycles of \(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\). This also implies that all the \(a\in\left[p\right]\) (resp.\ \(\left[p+1,p+q\right]\)) with \(\pi^{-1}\left(a\right)\in\left[p+1,p+q\right]\) (resp.\ \(\left[p\right]\)) are in bridges of \(\mathrm{Kr}^{-1}\left(\pi\right)\), so they appear in the same cycle of \(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\). \ref{item: partial order}.: If \(\pi\preceq\hat{\rho}\), then \(\pi_{0}\preceq\pi\preceq\hat{\rho}\). Furthermore, by part~\ref{item: outside faces}, the bridges of \(\pi=\mathrm{Kr}^{-1}\left(\mathrm{Kr}\left(\pi\right)\right)\) are contained in two cycles of \(\mathrm{Kr}^{-1}\left(\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\right)\). Because \(\mathrm{Kr}\left(\rho\right)\preceq\mathrm{Kr}\left(\pi\right)\), and each cycle of \(\mathrm{Kr}\left(\rho\right)\) is contained in a cycle of \(\tau\), \(\mathrm{Kr}\left(\rho\right)\preceq\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\). Thus each of the two cycles of \(\mathrm{Kr}^{-1}\left(\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\right)\) containing the bridges of \(\pi\) is contained in a cycle of \(\mathrm{Kr}^{-1}\left(\mathrm{Kr}\left(\rho\right)\right)=\rho\). Conversely, if \(\pi_{0}\preceq\rho\) and the bridges of \(\pi=\mathrm{Kr}^{-1}\left(\mathrm{Kr}\left(\pi\right)\right)\) are contained in two cycles of \(\rho=\mathrm{Kr}^{-1}\left(\mathrm{Kr}\left(\rho\right)\right)\), then each of these cycles must contain the cycles of \(\mathrm{Kr}^{-1}\left(\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\right)\) that have the same elements as the bridges of \(\pi\). For any \(a\) which is not an element of a bridge of \(\pi\), \(\mathrm{Kr}^{-1}\left(\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\right)\left(a\right)=\tau\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}^{-1}\left(a\right)=\tau\mathrm{Kr}\left(\pi\right)^{-1}\left(a\right)=\tau\tau^{-1}\pi\left(a\right)=\pi_{0}\left(a\right)\) (the last step because this element is in the same cycle of \(\tau\) as \(a\)). Thus the rest of the cycles of \(\mathrm{Kr}^{-1}\left(\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\right)\) appear as cycles of \(\pi_{0}\). Because \(\pi_{0}\preceq\rho\), any such cycle must be contained in a cycle of \(\rho\). So \[\mathrm{Kr}^{-1}\left(\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\right)\preceq\rho\Rightarrow\mathrm{Kr}\left(\rho\right)\preceq\left.\mathrm{Kr}\left(\pi\right)\right|_{\tau}\Rightarrow\mathrm{Kr}\left(\rho\right)\preceq\mathrm{Kr}\left(\pi\right)\Rightarrow\pi\preceq\hat{\rho}\] as desired. \ref{item: piecewise}.: Each of the annular-nonstandard and annular-noncrossing conditions can be checked. We note that if \(L\subseteq\left[p+q\right]\) is contained in a cycle of \(\sigma\), then \(\left.\rho\right|_{L}=\left.\tau\right|_{L}\) (since \(L\) is either contained in a single cycle of \(\rho\) or in \(J\), the union of a cycle from each of the two different cycles of \(\tau\)). Any annular-nonstandard or annular crossing condition in \(\sigma\) implies the same annular-nonstandard or annular-noncrossing condition in \(\sigma_{1}\) or \(\sigma_{2}\) (if the elements satisfying the condition are contained in \(J\) or in \(\left[p+q\right]\setminus J\)), or a possibly different condition in \(\rho\) (if the elements satisfying the condition are in both \(J\) and \(\left[p+q\right]\setminus J\)). The cases requiring a different condition are (\(x\) and \(y\) are elements of a bridge and hence in \(\sigma_{1}\)): \begin{itemize} \item if annular-crossing condition~\ref{item: ac2}.\ occurs in \(\sigma\) and \(\left(a,c,b\right)\) is in \(\sigma_{2}\), then it is contained in one orbit of \(\tau\) (annular-nonstandard condition~\ref{item: ans1}.), and \item if annular-crossing condition~\ref{item: ac3}.\ occurs in \(\sigma\), then if \(\left(a,c\right)\) and \(\left(b,d\right)\) are both from \(\sigma_{2}\) then annular-crossing condition~\ref{item: ac1}.\ occurs in \(\sigma_{2}\), and if one occurs in \(\sigma_{1}\), then it is contained in an orbit of \(\rho\) with one of \(x\) or \(y\), so annular-crossing condition~\ref{item: ac1}.\ occurs in \(\rho\). \end{itemize} \ref{item: selected cycles}.: Since \(\pi_{0}\preceq\rho\), \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\preceq\rho\). Let \(\varphi:=\mathrm{Kr}_{\tau}^{-1}\left(\pi_{0}\right)=\tau\pi_{0}^{-1}\). Since \(\pi_{0}\preceq\rho\), \(\varphi\succeq\mathrm{Kr}_{\tau}^{-1}\left(\rho\right)\), and so \(\varphi\succeq\mathrm{Kr}_{\varphi}\left(\mathrm{Kr}_{\tau}^{-1}\left(\rho\right)\right)=\left(\tau\rho^{-1}\right)^{-1}\tau\pi_{0}^{-1}=\rho\pi_{0}^{-1}=\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\). Thus any cycle of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\) is contained in the intersection of a cycle of \(\rho\) and a cycle of \(\mathrm{Kr}_{\tau}^{-1}\left(\pi_{0}\right)\). Conversely, we show that the part of \(K\) in each of the cycles of \(\tau\) consists of one cycle of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)=\rho\pi_{0}^{-1}\in S_{\mathrm{disc-nc}}\left(p,q\right)\) by showing that \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\succeq\rho\wedge\mathrm{Kr}_{\tau}^{-1}\left(\pi_{0}\right)\), the part of \(K\) in a given cycle of \(\tau\) being a block of \(\rho\wedge\mathrm{Kr}_{\tau}^{-1}\left(\pi\right)\). Equivalently, we show \(\mathrm{Kr}_{\tau}\left(\rho\pi_{0}^{-1}\right)\preceq\mathrm{Kr}_{\tau}\left(\rho\wedge\mathrm{Kr}_{\tau}^{-1}\left(\pi_{0}\right)\right)=\mathrm{Kr}_{\tau}\left(\rho\right)\vee\pi_{0}\): \(\mathrm{Kr}_{\tau}\left(\rho\pi_{0}^{-1}\right)=\pi_{0}\rho^{-1}\tau\) takes any element to another element of the same orbit of the subgroup generated by \(\pi_{0}\) and \(\rho^{-1}\tau=\mathrm{Kr}_{\tau}\left(\rho\right)\), it must be smaller than their supremum. \ref{item: cycle partition}.: This will follow from parts~\ref{item: selected cycles}.\ and \ref{item: spare cycles}.\ (since \(K\) consists of complete cycles of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\), so does its complement, which part~\ref{item: spare cycles}.\ shows are complete cycles of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\)). \ref{item: spare cycles}.: Let \(a\notin K\). If \(a\) is not in the two cycles of \(\rho\) containing the bridges of \(\pi\), then \(\pi^{-1}\left(a\right)=\pi_{0}^{-1}\left(a\right)\), so \(\rho\pi^{-1}\left(a\right)=\rho\pi_{0}^{-1}\left(a\right)=\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\left(a\right)\). If \(a\) is not in the outside faces of \(\mathrm{Kr}_{\tau}^{-1}\left(\pi_{0}\right)\), then it is not in the bridges of \(\mathrm{Kr}_{\tau}^{-1}\left(\pi\right)\), so \(\rho\pi^{-1}\left(a\right)\) and hence \(\pi^{-1}\left(a\right)\) must be in the same cycle of \(\tau\) as \(a\), and so again \(\rho\pi^{-1}\left(a\right)=\rho\pi_{0}^{-1}\left(a\right)=\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\left(a\right)\). \ref{item: skeleton}.: Let \(J\) be the set of elements in the two cycles of \(\rho\) that contain the bridges of \(\pi\). We note that unless \(\left.\rho\right|_{J}=\left.\tau\right|_{J}\), it is possible to find three elements which satisfy annular-nonstandard condition~\ref{item: ans1}. So \(\left.\pi\right|_{J}\in S_{\mathrm{ann-nc}}\left(\left.\rho\right|_{J}\right)\). The elements of the bridges of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\) are the elements of the outside faces of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\), which contain the \(a\in\left[p\right]\) with \(\pi^{-1}\left(a\right)\in\left[p+1,p+q\right]\) (resp.\ the \(a\in\left[p+1,p+q\right]\) with \(\pi^{-1}\left(a\right)\in\left[p\right]\)), and hence intersect with the outside faces of \(\mathrm{Kr}_{\tau}^{-1}\left(\pi\right)\). Since they also intersect with \(J\), they must comprise \(K\). Let \(\sigma_{1}\in S_{\mathrm{ann-nc}}\left(\left.\tau\right|_{K}\right)\) with every cycle a bridge, let \(\sigma_{2}=\left.\left(\rho\pi_{0}^{-1}\right)\right|_{\left[p+q\right]\setminus K}\), and let \(\sigma:=\sigma_{1}\sigma_{2}\). Then by part~\ref{item: piecewise}., \(\sigma\in S_{\mathrm{ann-nc}}\left(p,q\right)\), as is \(\pi:=\mathrm{Kr}_{\rho}\left(\sigma\right)\). We now show that \(\left.\pi\right|_{\tau}=\pi_{0}\) by showing that \(\sigma\) is \(\mathrm{Kr}_{\rho}^{-1}\) of a permutation with this property, as described in part~\ref{item: outside faces}. On \(J\), the elements of the bridges of \(\sigma\) comprise two cycles of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\), while the remaining cycles are those of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\) (since they do not connect the cycles of \(\tau\)). Likewise, outside of \(J\), the cycles of \(\sigma\) are the same as those of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi_{0}\right)\). Uniqueness follows from the invertibility of \(\mathrm{Kr}_{\rho}\). \end{proof} \begin{figure} \label{figure: outside faces} \centering \begin{tabular}{cc} \input{outside_faces_1.pdf_t}&\input{outside_faces_2.pdf_t}\\ \input{skeleton_1.pdf_t}&\input{skeleton_2.pdf_t}\\ \end{tabular} \caption{Two annular noncrossing permutations \(\pi\) constructed from the same \(\pi_{0}\) with different outside faces (above), and their restrictions to the outside faces. See Example~\ref{example: annuli}.} \end{figure} \begin{example} In the two top diagrams of Figure~\ref{figure: outside faces}, the annulus is given by \(\tau=\tau_{6,7}\). Both diagrams show (in dark grey) the permutation \[\pi_{0}=\left(1\right)\left(2,6\right)\left(3,4\right)\left(5\right)\left(7,10,13\right)\left(8\right)\left(9\right)\left(11,12\right)\in S_{\mathrm{disc-nc}}\left(6,7\right)\textrm{.}\] The complement is given by either \[\mathrm{Kr}_{\tau}\left(\pi_{0}\right)=\pi_{0}^{-1}\tau=\left(1,6\right)\left(2,4,5\right)\left(3\right)\left(7,8,9\right)\left(10,12\right)\left(11\right)\left(13\right)\] or \[\mathrm{Kr}_{\tau}^{-1}\left(\pi_{0}\right)=\tau\pi_{0}^{-1}=\left(1,2\right)\left(3,5,6\right)\left(4\right)\left(7\right)\left(8,9,10\right)\left(11,13\right)\left(12\right)\] depending on whether the white intervals between the numbers share their label with the number counterclockwise or the number clockwise. (Note that the cycle structures of these two permutations are the same, since they are conjugate.) In the diagram on the left, the outside faces are \(\left(2,4,5\right)\) and \(\left(7,8,9\right)\) (respectively \(\left(3,5,6\right)\) and \(\left(8,9,10\right)\)). In the diagram on the right, the outside face are \(\left(2,4,5\right)\) and \(\left(10,12\right)\) (respectively \(\left(3,5,6\right)\) and \(\left(11,13\right)\)). In the diagram on the left, the dark and light grey together form the diagram \[\pi=\left(1\right)\left(2,10,13,7,6\right)\left(3,4,9\right)\left(5\right)\left(8\right)\left(11,12\right)\in S_{\mathrm{ann-nc}}\left(6,7\right)\textrm{.}\] The bridges are formed by connecting a cycle of \(\pi_{0}\) from each cycle of \(\tau\). We can connect any two cycles of \(\pi_{0}\) adjacent to the outside faces as long as it does not create crossings. (If we are considering a fixed \(\rho\succeq\pi_{0}\), we connect only those contained in two of the cycles of \(\rho\).) In the diagram on the right, the complement is \[\mathrm{Kr}^{-1}\left(\pi\right)=\pi^{-1}\tau=\left(1,6\right)\left(2,9\right)\left(3\right)\left(4,5,7,8\right)\left(10,12\right)\left(11\right)\left(13\right)\] with bridges \(\left(2,9\right)\) and \(\left(4,5,7,8\right)\). The elements are exactly the elements of the two outside faces of \(\mathrm{Kr}^{-1}\left(\pi_{0}\right)\). In the diagram on the right, the dark and light grey together form the diagram \[\pi=\left(1\right)\left(2,13,7,10,6\right)\left(3,4\right)\left(5\right)\left(8\right)\left(9\right)\left(11,12\right)\textrm{.}\] The lower two diagrams show the restrictions to the outside faces. We can think of each edge as representing a block adjacent to an outside face containing that number, which may be connected to another such block on the other face in a noncrossing way. The bridges of the complement are the same. The cycles of the complement which do not appear do not depend on \(\pi\) but only on \(\pi_{0}\). (We have been considering \(\rho=\tau\). If \(\rho\) is another permutation, we would restrict to two cycles of \(\rho\).) \label{example: annuli} \end{example} The following proposition gives the M\"{o}bius function: \begin{proposition} Here \(\tau=\tau_{p,q}\) and \(\mathrm{Kr}=\mathrm{Kr}_{\tau}\). If \(\pi,\rho\in S_{\mathrm{nc-sd}}\left(p,q\right)\) with \(\pi\preceq\rho\), and it is not true that both \(\pi\in S_{\mathrm{disc-nc}}\left(p,q\right)\) and \(\rho\in \hat{S}_{\mathrm{disc-nc}}\left(p,q\right)\), then \[\mu\left(\pi,\rho\right)=\prod_{U\in \Pi\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)}\left(-1\right)^{\left|U\right|-1}C_{\left|U\right|-1}\textrm{.}\] Let \(\pi,\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\). Then \begin{multline*} \mu\left(\pi,\hat{\rho}\right)\\=2\sum_{\substack{U_{1},U_{2}\in\Pi\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)\\U_{1}\subseteq\left[p\right],U_{2}\subseteq\left[p+1,p+q\right]}}\frac{\left(-1\right)^{\left|U_{1}\right|+\left|U_{2}\right|}}{\left(\left|U_{1}\right|+\left|U_{2}\right|\right)}\frac{\left(2\left|U_{1}\right|-1\right)!}{\left(\left|U_{1}\right|-1\right)!^{2}}\frac{\left(2\left|U_{2}\right|-1\right)!}{\left(\left|U_{2}\right|-1\right)!^{2}}\\\times\prod_{V\in\Pi\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)\setminus\left\{U_{1},U_{2}\right\}}\left(-1\right)^{\left|V\right|-1}C_{\left|V\right|-1} \end{multline*} \label{proposition: mobius} \end{proposition} \begin{proof} See \cite{MR2266879}, Lectures~9 and 10 for a calculation of the M\"{o}bius function of \(S_{\mathrm{nc}}\left(n\right)\) and the various properties cited here. By the same argument, for \(\pi,\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\cup S_{\mathrm{ann-nc}}\left(p,q\right)\), the interval \(\left[\pi,\rho\right]\) is a product poset of the \(\left[\left.\pi\right|_{U},U\right]\) for \(U\in\Pi\left(\rho\right)\), giving the desired result for such \(\pi\) and \(\rho\). We note that \(S_{nc-sd}\left(p,q\right)\) is self-dual under \(\widehat{\mathrm{Kr}}^{-1}\). For \(\pi,\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\cup\hat{S}_{\mathrm{disc-nc}}\left(p,q\right)\), \(\mu\left(\pi,\rho\right)=\mu\left(\widehat{\mathrm{Kr}}^{-1}\left(\rho\right),\widehat{\mathrm{Kr}}^{-1}\left(\pi\right)\right)\). If we let \(\varphi:=\mathrm{Kr}_{\tau}^{-1}\left(\pi\right)=\tau\rho^{-1}\), then the M\"{o}bius function is a product over the cycles of \(\mathrm{Kr}_{\varphi}\left(\mathrm{Kr}_{\tau}^{-1}\left(\rho\right)\right)=\left(\tau\rho^{-1}\right)^{-1}\tau\pi^{-1}=\rho\pi^{-1}=\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\), giving the desired result for such \(\pi\) and \(\rho\). Let \(\pi,\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\). We wish to calculate \[\mu\left(\pi,\hat{\rho}\right)=-\sum_{\sigma:\pi\prec\sigma\prec\hat{\rho}}\mu\left(\sigma,\hat{\rho}\right)\textrm{.}\] We show first that the sum of the contribution from \(\sigma\) such that \(\sigma\succ\upsilon\succ\pi\) for some \(\upsilon\in S_{\mathrm{disc-nc}}\left(p,q\right)\) vanishes, using the Principle of Inclusion and Exclusion (see, e.g.\ \cite{MR1311922}, Chapter 5). The union of the sets \(\left[\upsilon,\hat{\rho}\right]\) for \(\upsilon\in S_{\mathrm{disc-nc}}\left(p,q\right)\), \(\upsilon\succ\pi\) is the set of \(\sigma\) with \(\pi\prec\sigma\preceq\hat{\rho}\). Because \(S_{\mathrm{disc-nc}}\left(p,q\right)\) is a lattice, any \(\upsilon_{1},\ldots,\upsilon_{n}\in S_{\mathrm{disc-nc}}\left(p,q\right)\) have a least upper bound \(\upsilon^{\prime}\), so the intersection \(\left[\upsilon_{1},\hat{\rho}\right]\cap\cdots\cap\left[\upsilon_{n},\hat{\rho}\right]=\left[\upsilon^{\prime},\hat{\rho}\right]\). Thus any intersection of the \(\left[\upsilon,\hat{\rho}\right]\) will be of this form. Since \(\sum_{\sigma\in\left[\upsilon^{\prime},\hat{\rho}\right]}\mu\left(\sigma,\hat{\rho}\right)=0\), each set of multiply counted terms vanishes, and hence the sum of \(\mu\left(\sigma,\hat{\rho}\right)\) for \(\sigma\succeq\upsilon\) for some \(\upsilon\in S_{\mathrm{disc-nc}}\left(p,q\right)\) with \(\upsilon\succ\pi\) vanishes. Thus, we need only consider the contribution of elements in \(\left[\pi,\hat{\rho}\right]\) not larger than any \(\upsilon\in S_{\mathrm{nc-sd}}\left(p,q\right)\) with \(\upsilon\succ\pi\); i.e., \(\hat{\pi}\) and \(\sigma\in S_{\mathrm{ann-nc}}\left(p,q\right)\) where \(\left.\sigma\right|_{\tau}=\pi\) and \(\sigma\prec\rho\). The value of \(\mu\left(\hat{\pi},\hat{\rho}\right)\) is calculated above, accounting for the last term in the stated value of \(\mu\left(\pi,\hat{\rho}\right)\). By Lemma~\ref{lemma: technical}, part~\ref{item: selected cycles}, the \(\sigma\in S_{\mathrm{ann-nc}}\left(p,q\right)\) with \(\pi\preceq\sigma\preceq\hat{\rho}\) and \(\left.\sigma\right|_{\tau}=\pi\) can be partitioned by which cycles of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\) are the outside faces. We sum over choices of cycles \(U_{1}\) and \(U_{2}\) of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\). By Lemma~\ref{lemma: technical}, part~\ref{item: spare cycles}, the cycles of \(\mathrm{Kr}_{\rho}^{-1}\left(\sigma\right)\) which are not contained in \(U_{1}\cup U_{2}\) are the same as those of \(\mathrm{Kr}_{\rho}^{-1}\left(\pi\right)\). We now calculate the sum of the contributions of the remaning cycles. By part~\ref{item: skeleton}., the \(\sigma\) correspond to choices of bridges on \(K\). Given \(\sigma\in S_{\mathrm{ann-nc}}\left(r,s\right)\) a collection of bridges, we may construct a collection of bridges in \(S_{\mathrm{ann-nc}}\left(r+r^{\prime},s+s^{\prime}\right)\) by adding another bridge (with \(r^{\prime}\) elements in one end and \(s^{\prime}\) elements in the other) between the bridge containing \(1\) and the next bridge along that cycle of \(\tau_{r,s}\) (the one with the next smallest numbers). This determines where the other end of this bridge lies in the other cycle of \(\tau_{r,s}\). If we renumber the points so that the order is preserved, the permutation on \(S_{\mathrm{ann-nc}}\left(r+r^{\prime},s+s^{\prime}\right)\) is uniquely determined, unless the other end of the bridge falls between \(r+s\) and \(r+1\) (i.e.\ if \(1\) and \(r+1\) are in the same cycle, and \(\sigma\left(r+s\right)\neq r+1\), see Figure~\ref{figure: recurrence}, upper left). In this case there are \(s^{\prime}+1\) ways to choose how the \(s^{\prime}\) elements of that end of the bridge are divided between the beginning and end of the interval \(\left[r+r^{\prime}+1,r+r^{\prime}+s+s^{\prime}\right]\). If the permutation is numbered so the added bridge ends at \(r+r^{\prime}+s+s^{\prime}\), the permutation will still have the property that the bridge containing \(1\) also contains \(r+r^{\prime}+1\) and \(\sigma\left(r+r^{\prime}+s+s^{\prime}\right)\neq r+r^{\prime}+1\) (Figure~\ref{figure: recurrence}, upper right); otherwise the cycle containing \(1\) will not contain \(r+r^{\prime}+1\) (Figure~\ref{figure: recurrence}, lower left). It is thus useful to consider these cases separately. We also note that any permutation with at least two bridges is constructed in this manner from a unique permutation and \(r,s,r^{\prime},s^{\prime}\), since the process can be reversed by removing the first bridge after the one containing \(1\) and renumbering. We define a generating function \(f_{1}\left(x,y\right)=\sum_{x,y\geq}f^{\left(1\right)}_{r,s}x^{r}y^{s}\) where the coefficient of \(x^{r}y^{s}\) is the sum of contributions of collections of bridges \(\sigma\in S_{\mathrm{ann-nc}}\left(r,s\right)\) where \(1\) is in the same cycle as \(r+1\) but \(\sigma\left(r+s\right)\neq r+1\): \[f^{\left(1\right)}_{r,s}=\sum_{\substack{\sigma\in S_{\mathrm{ann-nc}}\left(r,s\right)\\\textrm{\(\sigma\) all bridges}\\\left.\sigma\right|_{\left\{1,r+1\right\}}=\left(1,r+1\right)\\\sigma\left(r+s\right)\neq r+1}}\prod_{U\in\Pi\left(\sigma\right)}\left(-1\right)^{\left|U\right|-1}C_{\left|U\right|-1}\textrm{.}\] We let \(g_{1}\left(x,y\right)\) be the generating function of the added bridge (denoting the generating function of the Catalan numbers by \(C\left(x\right)=\frac{1-\sqrt{1-4x}}{2x}\)): \begin{multline*} g_{1}\left(x,y\right)=\sum_{r,s\geq 1}\left(-1\right)^{r+s-1}C_{r+s-1}x^{r}y^{s}\\=\sum_{k\geq 2}\left(-1\right)^{k-1}C_{k-1}\left(x^{k-1}y+x^{k-2}y^{2}+\cdots+x^{2}y^{k-2}+xy^{k-1}\right)\\=\sum_{k\geq 2}\left(-1\right)^{k-1}C_{k-1}xy\frac{x^{k-1}-y^{k-1}}{x-y}=xy\frac{C\left(-x\right)-C\left(-y\right)}{x-y}\\=\frac{1}{2}+\frac{y\sqrt{1+4x}-x\sqrt{1+4y}}{2\left(x-y\right)}\textrm{.} \end{multline*} We let \(h_{1}\left(x,y\right)=\sum_{x,y\geq 1}h^{\left(1\right)}x^{r}y^{s}\) be the generating function of the contribution of the permutations \(\sigma\) with only one bridge, where \(\sigma\left(r+s\right)\neq r+1\). There are \(r\) choices for the first element \(a\) of the bridge in \(\left[r\right]\), and \begin{multline*} h_{1}\left(x,y\right)=\sum_{r,s\geq 1}\left(-1\right)^{r+s}rC_{r+s-1}=x\frac{\partial}{\partial x}g_{1}\left(x,y\right)\\=-\frac{xy\left(1+2x+2y-\sqrt{1+4x}\sqrt{1+4y}\right)}{2\sqrt{1+4x}\left(x-y\right)^{2}}\textrm{.} \end{multline*} (Here and throughout this proof the generating functions may be derived by standard calculation.) Then \(f_{1}\) satisfies the recurrence relation \[f_{1}=f_{1}g_{1}+h_{1}\] so \[f_{1}\left(x,y\right)=\frac{h_{1}\left(x,y\right)}{1-g_{1}\left(x,y\right)}=\frac{xy\left(1+2x+2y-\sqrt{1+4x}\sqrt{1+4y}\right)}{\sqrt{1+4x}\left(x-y\right)\left(y+y\sqrt{1+4x}-x-x\sqrt{1+4y}\right)}\textrm{.}\] We define \(f_{2}\left(x,y\right)=\sum_{r,s\geq 0}f^{\left(2\right)}x^{r}y^{s}\) so \(f^{\left(2\right)}_{r,s}\) is the contribution of diagrams not considered in \(f_{2}\), i.e.\ where \(1\) is not in the same bridge as \(r+1\) or \(\sigma\left(r+s\right)=r+1\): \[f^{\left(2\right)}_{r,s}=\sum_{\substack{\sigma\in S_{\mathrm{ann-nc}}\left(r,s\right)\\\textrm{\(\sigma\) all bridges}\\\textrm{\(\left.\sigma\right|_{\left\{1,r+1\right\}}=\left(1\right)\left(r+1\right)\) or \(\sigma\left(r+s\right)=r+1\)}}}\prod_{U\in\Pi\left(\sigma\right)}\left(-1\right)^{\left|U\right|-1}C_{\left|U\right|-1}\textrm{.}\] We let \(g_{2}\left(x,y\right)\) be the generating function for the contribution of bridges added to a \(\sigma\) with \(1\) and \(r+1\) in the same bridge and \(\sigma\left(r+s\right)=r+1\) such that in the new \(\sigma^{\prime}\) \(r+r^{\prime}+s+s^{\prime}\) is no longer in the same cycle as \(1\). There are \(s^{\prime}\) ways to add the new bridge, so: \begin{multline*} g_{2}\left(x,y\right)=\sum_{r,s\geq 1}\left(-1\right)^{r+s}sC_{r+s-1}=y\frac{\partial}{\partial y}g_{1}\left(x,y\right)\\=-\frac{xy\left(1+2x+2y-\sqrt{1+4x}\sqrt{1+4y}\right)}{2\sqrt{1+4y}\left(x-y\right)^{2}}\textrm{.} \end{multline*} Let \(h_{2}\) be the generating function of the \(\sigma\in S_{\mathrm{ann-nc}}\left(r,s\right)\) with only one bridge and \(\sigma\left(r+s\right)=r+1\). There are \(r\) choices for the first element from \(\left[p\right]\) and \(s-1\) choices for the first element from \(\left[p+1,p+q\right]\) which satisfy this condition, so: \begin{multline*} h_{2}\left(x,y\right)=y\frac{\partial}{\partial y}h_{1}\left(x,y\right)-h_{1}\left(x,y\right)\\=\frac{xy^{2}\left(\left(1+x+3y\right)\sqrt{1+4x}-\left(1+3x+y\right)\sqrt{1+4y}\right)}{\sqrt{1+4x}\sqrt{1+4y}\left(x-y\right)^{3}}\textrm{.} \end{multline*} Then \(f_{2}\) satisfies the recurrence relation: \[f_{2}=f_{1}g_{2}+f_{2}g_{1}+h_{2}\] so \begin{multline*} f_{2}\left(x,y\right)=\frac{f_{1}\left(x,y\right)g_{2}\left(x,y\right)+h_{2}\left(x,y\right)}{1-g_{1}\left(x,y\right)}\\=\frac{x^{2}-2xy+2x^{2}y-6xy^{2}-\left(x-y\right)^{2}\sqrt{1+4y}+y^{2}\sqrt{1+4x}\sqrt{1+4y}}{2\sqrt{1+4x}\sqrt{1+4y}\left(x-y\right)^{2}}\textrm{.} \end{multline*} We let \(f\left(x,y\right)=\sum_{r,s\geq 1}f_{r,s}x^{r}y^{s}\) whose coefficients are the sum of the contribution of all the collections of bridges: \[f_{r,s}=-\sum_{\substack{\sigma\in S_{\mathrm{ann-nc}}\left(r,s\right)\\\textrm{\(\sigma\) all bridges}}}\prod_{U\in\Pi\left(\sigma\right)}\left(-1\right)^{\left|U\right|-1}C_{\left|U\right|-1}\] (negative since this is the value that will contribute to \(\mu\left(\pi,\hat{\rho}\right)\). Then \[f\left(x,y\right)=-f_{1}\left(x,y\right)-f_{2}\left(x,y\right)=\frac{xy\left(1+2x+2y-\sqrt{1+4x}\sqrt{1+4y}\right)}{2\sqrt{1+4x}\sqrt{1+4y}\left(x-y\right)^{2}}\textrm{.}\] Since \[\left.\frac{\partial}{\partial z}f\left(xz,yz\right)\right|_{z=1}=2\frac{x}{\left(1+4x\right)^{3/2}}\frac{y}{\left(1+4y\right)^{3/2}}\] and \begin{multline*} \frac{x}{\left(1+4x\right)^{3/2}}=\sum_{k\geq 1}\left(-1\right)^{k-1}\frac{1\cdot 3\cdot 5\cdot\cdots\cdot\left(2k-1\right)}{2^{k-1}\left(k-1\right)!}\left(4x\right)^{k}\\=\sum_{k\geq 1}\left(-1\right)^{k-1}\frac{\left(2k-1\right)!}{\left(k-1\right)!^{2}}x^{k} \end{multline*} the coefficient \(f_{r,s}\) of \(x^{r}y^{s}\) in \(f\) is \[\frac{\left(-1\right)^{p+q}2}{p+q}\frac{\left(2p-1\right)!}{\left(p-1\right)!^{2}}\frac{\left(2q-1\right)!}{\left(q-1\right)!^{2}}\textrm{.}\] The expression for \(\mu\left(\pi,\hat{\rho}\right)\) follows. \end{proof} \begin{figure} \label{figure: recurrence} \centering \begin{tabular}{cc} \input{f_1.pdf_t}&\input{f_1g_1.pdf_t}\\ \input{f_1g_2.pdf_t}&\input{f_2.pdf_t}\\ \end{tabular} \caption{Top left: A diagram which contributes \(14\cdot 14\cdot 2x^{7}y^{6}=384x^{7}y^{6}\) to \(f_{1}\). Top right: A diagram constructed from top left by adding a bridge. This diagram contributes to \(f_{1}\). Bottom left: A diagram constructed from top left by adding a bridge. This diagram contributes to \(f_{2}\). Bottom right: A diagram which contributes to \(f_{2}\).} \end{figure} \section{Real second-order cumulants} \label{section: freeness} \begin{definition} Let \(\left(A,\phi_{1},\phi_{2}\right)\) be a real second-order noncommutative space. For \(p,q=1,2,\ldots\) the second-order moments \(\alpha_{p,q}:A^{p+q}\rightarrow\mathbb{C}\) are multilinear functions defined by \[\alpha_{p,q}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right):=\varphi_{2}\left(x_{1}\cdots x_{p},y_{1}\cdots y_{q}\right)\textrm{.}\] For \(\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q\right)\) with nontrivial block \(U\) and \(\left.\pi\right|_{U}=\left(c_{1},\ldots,c_{r}\right)\left(p+d_{1},\ldots,p+d_{s}\right)\), the moment over \(\left({\cal U},\pi\right)\), \(\alpha_{\left({\cal U},\pi\right)}:A^{p+q}\rightarrow\mathbb{C}\), is defined by \begin{multline*} \alpha_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\:=\alpha_{\left.\pi\right|_{\left[p+q\right]\setminus U}}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\alpha_{r,s}\left(x_{c_{1}},\ldots,x_{c_{r}},y_{d_{1}},\ldots,y_{d_{s}}\right)\textrm{.} \end{multline*} We define the second-order cumulants \(\kappa_{p,q}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) to be multilinear functions, notating, for \(\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q\right)\) as above, \begin{multline*} \kappa_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\:=\kappa_{\left.\pi\right|_{\left[p+q\right]\setminus U}}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\kappa_{r,s}\left(x_{c_{1}},\ldots,x_{c_{r}},y_{d_{1}},\ldots,y_{d_{s}}\right)\textrm{,} \end{multline*} such that \begin{multline} \alpha_{p,q}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right) \\=:\sum_{\alpha\in S_{\mathrm{ann-nc}}\left(p,q\right)}\kappa_{\alpha}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\+\sum_{\alpha\in S_{\mathrm{ann-nc}}\left(p,q\right)}\kappa_{\alpha}\left(x_{1},\ldots,x_{p},y_{q}^{t},\ldots,y_{1}^{t}\right)\\+\sum_{\substack{\left(U,\alpha\right)\in\mathrm{PS}^{\prime}\left(p,q\right)}}\kappa_{\left(U,\alpha\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\textrm{;} \label{formula: moment cumulant} \end{multline} or equivalently (see Lemma~\ref{lemma: moment cumulant}), \begin{multline} \kappa_{p,q}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\:=2\sum_{\pi\in S_{\mathrm{disc-nc}}\left(p,q\right)}\left[\mu\left(\pi,1\right)+\mu\left(\hat{\pi},1\right)\right]\alpha_{\pi}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\+\sum_{\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)}\mu\left(\pi,1\right)\alpha_{\pi}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\+\sum_{\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)}\mu\left(\pi,1\right)\alpha_{\pi}\left(x_{1},\ldots,x_{p},y_{q}^{t},\ldots,y_{1}^{t}\right)\\+\sum_{\left(U,\pi\right)\in\mathrm{PS}^{\prime}\left(p,q\right)}\mu\left(\hat{\pi},1\right)\alpha_{\left(U,\pi\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\textrm{.} \label{formula: cumulant moment} \end{multline} It follows from (\ref{formula: free moment cumulant}) and (\ref{formula: moment cumulant}) that for \(\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q\right)\) with nontrivial block \(U\) that \begin{multline} \alpha_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\=\sum_{\substack{\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\Pi\left(\rho\right)\preceq{\cal U}}}\kappa_{\rho}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\+\sum_{\substack{\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\Pi\left(\rho_{\mathrm{op}}\right)\preceq{\cal U}}}\kappa_{\rho}\left(x_{1},\ldots,x_{p},y_{q}^{t},\ldots,y_{1}^{t}\right)\\+\sum_{\substack{\left({\cal V},\rho\right)\in{\cal PS}^{\prime}\left(p,q\right)\\{\cal V}\preceq{\cal U}}}\kappa_{\left({\cal V},\rho\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right) \label{formula: general moment cumulant} \end{multline} and from (\ref{formula: free cumulant moment}) and (\ref{formula: cumulant moment}) that \begin{multline} \kappa_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\=2\sum_{\substack{\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\\\rho\preceq\pi}}\mu\left(\left.\rho\right|_{\left[p+q\right]\setminus U},\left.\pi\right|_{\left[p+q\right]\setminus U}\right)\left(\mu\left(\left.\rho\right|_{U},\left.1\right|_{U}\right)+\mu\left(\left.\pi\right|_{U},\left.1\right|_{U}\right)\right)\\\times\alpha_{\rho}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\+\sum_{\substack{\rho\in S_{\mathrm{ann-n}}\left(p,q\right)\\\Pi\left(\rho\right)\preceq{\cal U}}}\mu\left(\rho,\pi\right)\alpha_{\rho}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\\+\sum_{\substack{S\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\Pi\left(\rho_{\mathrm{op}}\right)\preceq{\cal U}}}\mu\left(\rho_{\mathrm{op}},\pi\right)\alpha_{\rho}\left(x_{1},\ldots,x_{p},y_{q}^{t},\ldots,y_{1}^{t}\right)\\+\sum_{\substack{\left({\cal V},\rho\right)\in{\cal PS}^{\prime}\left(p,q\right)\\{\cal V}\preceq{\cal U}}}\mu\left(\hat{\rho},\hat{\pi}\right)\alpha_{\left({\cal V},\rho\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\textrm{.} \label{formula: general cumulant moment} \end{multline} \end{definition} \begin{lemma} \label{lemma: moment cumulant} Definitions (\ref{formula: moment cumulant}) and (\ref{formula: cumulant moment}) are equivalent. \end{lemma} \begin{proof} We note that \(\kappa_{p,q}\) appears with coefficient \(1\) in (\ref{formula: moment cumulant}) and \(\alpha_{p,q}\) appears wtih coefficient \(1\) in (\ref{formula: cumulant moment}). By induction, the expression for \(\kappa_{p,q}\) is determined uniquely by (\ref{formula: moment cumulant}) and that for \(\alpha_{p,q}\) by (\ref{formula: cumulant moment}). We assume (\ref{formula: moment cumulant}) and show (\ref{formula: cumulant moment}) by induction on \(p+q\) (the case \(p=q=1\) is straightforward). We expand each summand in the right-hand side of (\ref{formula: cumulant moment}) in cumulants according to (\ref{formula: free moment cumulant}) and (\ref{formula: general moment cumulant}). If \(\pi\in S_{\mathrm{disc-nc}}\left(p,q\right)\), then \(\kappa_{\pi}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) appears in the expansion of \(\alpha_{\rho}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) for every \(\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\) with \(\rho\succeq\pi\) (which has coefficient \(2\left(\mu\left(\rho,1\right)+\mu\left(\hat{\rho},1\right)\right)\)), in the expansion of \(\alpha_{\rho}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) for every \(\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\) with \(\rho\succeq\pi\) (which has coefficient \(\mu\left(\rho,1\right)\)), and in the form \(\alpha_{\pi_{\mathrm{op}}}\left(x_{1},\ldots,x_{p},y_{q}^{t},\ldots,y_{1}^{t}\right)\) in the expansion of \(\alpha_{\rho}\left(x_{1},\ldots,x_{p},y_{q}^{t},\ldots,y_{1}^{t}\right)\) for every \(\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\) with \(\rho\succeq\pi_{\mathrm{op}}\) (which has coefficient \(\mu\left(\rho,1\right)\)). It does not appear in the expansion of the \(\alpha_{\left({\cal U},\rho\right)}\). Noting that, for \(\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\), \(\mu\left(\rho,1\right)=\mu\left(\rho_{\mathrm{op}},1\right)\) (see the comment after Definition~\ref{definition: opposite}), the total coefficient is \begin{multline*} 2\sum_{\substack{\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\\\rho\succeq\pi}}\left[\mu\left(\rho,1\right)+\mu\left(\hat{\rho},1\right)\right]+\sum_{\substack{\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\rho\succeq\pi}}\mu\left(\rho,1\right)+\sum_{\substack{\rho\in S_{\mathrm{ann-nc}}\\\rho_{\mathrm{op}\succeq\pi}}}\mu\left(\rho,1\right)\\=\sum_{\rho\in\left[\pi,1\right]}\mu\left(\rho,1\right)+\sum_{\rho\in\left[\pi_{\mathrm{op}},1\right]}\mu\left(\rho,1\right)=0\textrm{.} \end{multline*} If \(\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\), then \(\kappa_{\pi}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) appears in the expansion of \(\alpha_{\rho}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) for every \(\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\) with \(\rho\succeq\pi\) (which has coefficient \(\mu\left(\rho,1\right)\)), and in the expansion of \(\alpha_{\left({\cal U},\rho\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) for \(\left({\cal U},\rho\right)\) with \({\cal U}\succeq\Pi\left(\pi\right)\), i.e.\ those where \(\rho\) satisfies Lemma~\ref{lemma: technical} part~\ref{item: partial order} and the nontrivial block of \({\cal U}\) contains the bridges of \(\pi\) (which has coefficient \(\mu\left(\hat{\rho},1\right)\)). The total coefficient is then \[\sum_{\substack{\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\rho\succeq\pi}}\mu\left(\rho,1\right)+\sum_{\substack{\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\\\hat{\rho}\succeq\pi}}\mu\left(\hat{\rho},1\right)=\sum_{\rho\in\left[\pi,1\right]}\mu\left(\rho,1\right)=0\textrm{.}\] Likewise the sum of the coefficients on \(\kappa_{\pi}\left(x_{1},\ldots,x_{p},y_{q}^{t},\ldots,y_{1}^{t}\right)\) also vanishes. If \(\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q\right)\), then \(\kappa_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) appears in the expansion of \(\alpha_{\left({\cal V},\rho\right)}\left(x_{1},\ldots,x_{p},y_{1},\ldots,y_{q}\right)\) for all \(\left({\cal V},\rho\right)\in{\cal PS}^{\prime}\left(p,q\right)\) with \({\cal U}\succeq{\cal V}\) (which has coefficient \(\mu\left(\hat{\rho},1\right)\)). For any \(\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\) with \(\rho\succeq\pi\), we can construct exactly one such \(\left({\cal V},\rho\right)\) by letting the nontrivial block of \({\cal V}\) contain the two cycles of \(\rho\) which contain the two cycles of \(\pi\) in \(U\). The total coefficient is \[\sum_{\substack{\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\\\rho\succeq\pi}}\mu\left(\hat{\rho},1\right)=\sum_{\hat{\rho}\in\left[\hat{\pi},1\right]}\mu\left(\hat{\rho},1\right)=\left\{\begin{array}{ll}1\textrm{,}&\hat{\rho}=1\\0\textrm{,}&\textrm{otherwise}\end{array}\right.\textrm{.}\] By the comment at the beginning of the proof the converse follows. \end{proof} We will make use of the following folklore lemma, which characterises the disc-noncrossing permutations on one cycle which do not connect any element to its neighbour and the annular noncrossing permutations which in addition do not have any single-element cycles: \begin{lemma} \begin{enumerate} \item Let \(\tau\in S_{n}\) have one cycle, \(n\geq 2\). If \(\pi\in S_{\mathrm{nc}}\left(\tau\right)\) does not have any cycle containing both \(a\) and \(\tau\left(a\right)\) for any \(a\in\left[n\right]\), then \(\pi\) has at least two single-element cycles. \label{item: disc singlets} \item Let \(\tau\in S_{n}\) have two cycles. If \(\pi\in S_{\mathrm{ann-nc}}\left(\tau\right)\) does not have any single-element cycles or any cycle containing both \(a\) and \(\tau\left(a\right)\) for \(a\in\left[p,q\right]\), then it is of the form \[\pi=\left(a,b\right)\left(\tau\left(a\right),\tau^{-1}\left(b\right)\right)\left(\tau^{2}\left(a\right),\tau^{-2}\left(b\right)\right)\cdots\left(\tau^{-1}\left(a\right),\tau\left(b\right)\right)\] where \(a\) and \(b\) are in different cycles of \(\tau\) (so the two cycles of \(\tau\) must have the same number of elements for such a \(\pi\) to exist). \label{item: annular spoke} \end{enumerate} \label{lemma: singlets} \end{lemma} \begin{proof} \ref{item: disc singlets}.: If \(\pi\) has no cycles with more than one element, then we are done. Otherwise, there is an orbit of \(\pi\) containing some \(a\) and \(\tau^{k}\left(a\right)\) for some minimal \(k\), \(2\leq k\leq n-2\). Then any element in \(\tau\left(a\right),\ldots,\tau^{k-1}\left(a\right)\) may not share an orbit of \(\pi\) with any element outside this set (noncrossing condition). If an orbit of such an element contains more than one element, we can repeat the argument with \(k^{\prime}<k\), so there must be a single-element cycle among \(\tau\left(a\right),\ldots,\tau^{k-1}\left(a\right)\). We may also repeat the argument starting with \(\tau^{k}\left(a\right)\), to find another single-element cycle. \ref{item: annular spoke}.: No cycle of such a \(\pi\) contains two elements from the same cycle of \(\tau\): if \(a\) and \(\tau^{k}\left(a\right)\) share a cycle of \(\pi\), some element \(x\) of \(\tau\left(a\right),\ldots,\tau^{k-1}\left(a\right)\) must share an orbit of \(\pi\) with an element \(y\) of the other cycle of \(\tau\) instead of being in a single-element cycle (as in part~\ref{item: disc singlets}). Then \(\left.\pi\right|_{\left[n\right]\setminus\left\{x,y\right\}}\) is noncrossing on \(\lambda_{x,y}\), so there must be a single-element cycle of \(\pi\) among \(\tau^{k+1}\left(a\right),\tau^{k+2}\left(a\right),\ldots,\tau^{-1}\left(a\right)\) (by the reasoning in part~\ref{item: disc singlets}.). Thus any cycle of \(\pi\) is of the form \(\left(a,b\right)\) where \(a\) and \(b\) are in different cycles of \(\tau\). Because \(\left.\pi\right|_{\left[n\right]\setminus\left\{a,b\right\}}\) is noncrossing on \(\lambda_{a,b}\), \(\tau\left(a\right)\) and \(\tau^{-1}\left(b\right)\) cannot both be paired with any other elements, so by induction \(\pi\) must be of the form given. \end{proof} The following theorem shows that second-order freeness is equivalent to the vanishing of mixed free and second-order free cumulants: \begin{theorem} Subalgebras \(A_{1},\ldots,A_{m}\subseteq A\) of second-order real probability space \(A\) are real second-order free if and only if all mixed free cumulants and all mixed real second-order cumulants vanish. \end{theorem} \begin{proof} Assume first that the subalgebras are second-order free. We demonstrate that mixed cumulants vanish by induction on \(p+q\). In the base case, where \(p=q=1\) and \(a_{1}\) and \(b_{1}\) are second-order real free, \[\kappa_{1,1}\left(a_{1},b_{1}\right)=-\alpha_{2}\left(a_{1},b_{1}\right)-\alpha_{2}\left(a_{1},b_{1}^{t}\right)+2\alpha_{1}\left(a_{1}\right)\alpha_{1}\left(b_{1}\right)+\alpha_{1,1}\left(a_{1},b_{1}\right)\textrm{.}\] Since \(a_{1}\) is free from \(b_{1}\), \(\alpha_{2}\left(a_{1},b_{1}\right)=\alpha_{2}\left(a_{1},b_{1}^{t}\right)=\alpha_{1}\left(a_{1}\right)\alpha_{1}\left(b_{1}\right)\), and by the definition of second-order freeness, \(\alpha_{1,1}\left(a_{1},b_{1}\right)=0\), so \(\kappa_{1,1}\left(a_{1},b_{1}\right)=0\). We now consider separately the case where the \(a_{1},\ldots,a_{p}\) and \(b_{1},\ldots,b_{q}\) are either cyclically alternating or have only one term, and the case where this does not hold. We first assume that the \(a_{1},\ldots,a_{p}\) and \(b_{1},\ldots,b_{q}\) are cyclically alternating or consist of a single term. Then \begin{multline} \alpha_{p,q}\left(\mathring{a}_{1},\ldots,\mathring{a}_{p},\mathring{b}_{1},\ldots,\mathring{b}_{q}\right)=\\=\sum_{\substack{\left\{i_{1},\ldots,i_{k}\right\}\subseteq\left[p\right]\\\left\{j_{1},\ldots,j_{l}\right\}\subseteq\left[q\right]}}\left(-1\right)^{p+q-k-l}\varphi_{2}\left(a_{i_{1}}\cdots a_{i_{k}},b_{j_{1}}\cdots b_{j_{l}}\right)\\\prod_{i\in\left[p\right]\setminus\left\{i_{1},\ldots,i_{k}\right\}}\varphi_{1}\left(a_{i}\right)\prod_{j\in\left[q\right]\setminus\left\{j_{1},\ldots,j_{l}\right\}}\varphi_{1}\left(b_{j}\right) \label{formula: centred} \end{multline} where we let \(i_{1}<\cdots<i_{k}\) and \(j_{1}<\cdots<j_{l}\). Considering a given \(I=\left\{i_{1},\ldots,i_{k}\right\}\) and \(J=\left\{j_{1},\ldots,j_{l}\right\}\) and expanding the moment in cumulants, the summand is: \begin{multline} \sum_{\substack{\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\pi\left(i\right)=i,i\notin I}}\kappa_{\pi}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\\+\sum_{\substack{\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\pi_{\mathrm{op}}\left(i\right)=i,i\notin I}}\kappa_{\pi}\left(a_{1},\ldots,a_{p},b_{q}^{t},\ldots,b_{1}^{t}\right)\\+\sum_{\substack{\left({\cal V},\pi\right)\in{\cal PS}^{\prime}\left(p,q\right)\\\left\{i\right\}\in{\cal V},i\notin I}}\kappa_{\left({\cal U},\pi\right)}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\textrm{.} \label{formula: cumulant singlets} \end{multline} A cumulant term in (\ref{formula: cumulant singlets}) with \(r\) singlets (of the permutation in the case of the first two sums and of the partition in the case of the third sum) will appear in the expansion of any summand of (\ref{formula: centred}) whose set of singlets \(\left[p+q\right]\setminus I\) is a subset of the cumulant's singlets. There are \(\binom{r}{s}\) such summands with \(s\) singlets, which appear with sign \(\left(-1\right)^{s}\). The total coefficient is then \(\sum_{s=0}^{r}\left(-1\right)^{s}\binom{r}{s}=\left(1-1\right)^{r}\), which is \(0\) unless \(r=0\). So (\ref{formula: centred}) is the sum over cumulants (in the uncentred variables) with no singlets: \begin{multline} \alpha_{p,q}\left(\mathring{a}_{1},\ldots,\mathring{a}_{p},\mathring{b}_{1},\ldots,\mathring{b}_{q}\right)\\=\sum_{\substack{\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\pi\left(i\right)\neq i,i\in\left[p+q\right]}}\kappa_{\pi}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\\+\sum_{\substack{\pi\in S_{\mathrm{ann-nc}}\left(p,q\right)\\\pi\left(i\right)\neq i,i\in\left[p+q\right]}}\kappa_{\pi}\left(a_{1},\ldots,a_{p},b_{q}^{t},\ldots,b_{1}^{t}\right)\\+\sum_{\substack{\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q\right)\\\left\{i\right\}\notin{\cal U},i\in\left[p+q\right]}}\kappa_{\left({\cal U},\pi\right)}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\textrm{.} \label{formula: centred cumulant expansion} \end{multline} In any term, if a cycle of \(\pi\) contains more than one element from the same cycle of \(\tau\), there must be a cycle of \(\pi\) containing two cyclically adjacent elements (Lemma~\ref{lemma: singlets}; at least one cycle of \(\tau\) has at least \(2\) elements since \(p+q\geq 1\)). Such a term therefore contains a mixed free cumulant or free second-order cumulant, and hence vanishes, except possibly the term \(\kappa_{p,q}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\). In (\ref{formula: second-order freeness}), the terms on the right-hand side are exactly those in (\ref{formula: moment cumulant}) in which \(\pi\) has no single-element cycles and no cycle contains cyclically adjacent elements (in both cases \(p=q\) and \(p\neq q\)). Equating this expression for \(\alpha_{p,q}\left(\mathring{a}_{1},\ldots,\mathring{a}_{p},\mathring{b}_{1},\ldots,\mathring{b}_{q}\right)\) with (\ref{formula: centred cumulant expansion}), the only term which does not appear on both sides is \(\kappa_{p,q}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\), which must therefore vanish. If at least one of \(a_{1},\ldots,a_{p}\) and \(b_{1},\ldots,b_{q}\) is not cyclically alternating and consists of more than one term, then there is at least one term followed (cyclically) by a term from the same subalgebra. Without loss of generality, we may assume these are \(b_{q-1}\) and \(b_{q}\). Rearranging (\ref{formula: cumulant moment}) applied to \(a_{1},\ldots,a_{p}\) and \(b_{1},\ldots,b_{q-2},b_{q-1}b_{q}\): \begin{multline} \alpha_{p,q-1}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q-2},b_{q-1}b_{q}\right)\\=\kappa_{p,q-1}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q-2},b_{q-1}b_{q}\right)\\-\sum_{\pi\in S_{\mathrm{disc-nc}}\left(p,q-1\right)}\left(\mu\left(\pi,1\right)+\mu\left(\hat{\pi},1\right)\right)\alpha_{\pi}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q-2},b_{q-1}b_{q}\right)\\-\sum_{\pi\in S_{\mathrm{ann-nc}}\left(p,q-1\right)}\mu\left(\pi,1\right)\alpha_{\pi}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q-2},b_{q-1}b_{q}\right)\\-\sum_{\pi\in S_{\mathrm{ann-nc}}\left(p,q-1\right)}\mu\left(\pi,1\right)\alpha_{\pi_{\mathrm{op}}}\left(a_{1},\ldots,a_{p},b_{1}^{t},\ldots,b_{q-2}^{t},b_{q}^{t}b_{q-1}^{t}\right)\\-\sum_{\substack{\left({\cal U},\pi\right)\in{\cal P}^{\prime}\left(p,q-1\right)\\\left({\cal U},\pi\right)\neq\left(1,\tau_{p,q-1}\right)}}\mu\left(\hat{\pi},1\right)\alpha_{\left({\cal U},\pi\right)}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q-2},b_{q-1}b_{q}\right)\textrm{.} \label{formula: squished moments} \end{multline} By the induction hypothesis, the cumulant vanishes. A moment on the right side with permutation \(\pi\) is equal to a moment of \(p+q\) terms with permutation \(\pi^{\prime}\) constructed by inserting \(p+q\) in the cycle following \(p+q-1\) (and constructing \({\cal U}^{\prime}\in{\cal P}\left(p+q\right)\) by adding \(p+q\) to the same block of \({\cal U}\) as \(p+q-1\)). This can be inverted by taking the permutation \(\left.\pi^{\prime}\right|_{\left[p+q-1\right]}\) (and \(\left.{\cal U}^{\prime}\right|_{\left[p+q-1\right]}\)). Noting that \(\pi^{\prime}\left(p+q-1\right)=p+q\) is equivalent to \(\mathrm{Kr}^{-1}\left(\pi^{\prime}\right)\) containing the cycle \(\left(p+q\right)\) and that \(\mathrm{Kr}^{-1}\left(\pi^{\prime}\right)=\mathrm{Kr}^{-1}\left(\pi\right)\cdot\left(p+q\right)\), this transformation is a poset bijection between \(S_{\mathrm{sd-nc}}\left(p,q-1\right)\) and the \(\pi^{\prime}\in S_{\mathrm{sd-nc}}\left(p,q\right)\) for which \(\pi^{\prime}\left(p+q-1\right)=p+q\). We note that for \(\rho\in S_{\mathrm{sd-nc}}\left(p,q\right)\), there is a \(\tilde{\rho}\in S_{\mathrm{sd-nc}}\left(p,q-1\right)\) such that the \(\pi\in S_{\mathrm{sd-nc}}\left(p,q-1\right)\) with \(\pi^{\prime}\succeq\rho\) are exactly those with \(\pi\succeq\tilde{\rho}\): we have \[\rho\preceq\pi^{\prime}\Leftrightarrow\widehat{\mathrm{Kr}}^{-1}\left(\rho\right)\succeq\widehat{\mathrm{Kr}}^{-1}\left(\pi^{\prime}\right)\Leftrightarrow\left.\mathrm{Kr}^{-1}\left(\rho\right)\right|_{\left[p+q-1\right]}\cdot \left(p+q\right)\succeq\widehat{\mathrm{Kr}}^{-1}\left(\pi^{\prime}\right)\textrm{.}\] (We interpret the permutation on the left-hand side of the last inequality as the element of \(S_{\mathrm{sd-nc}}\left(p,q\right)\) covered by \(\widehat{\mathrm{Kr}}^{-1}\left(\rho\right)\). We verify that this permutation is also noncrossing, since the new cycle contains only one element and therefore cannot introduce any of the nonstandard or crossing conditions; and that \(\mathrm{Kr}^{-1}\left(\pi^{\prime}\right)\) is still noncrossing on this new permutation, as it is noncrossing on each of the disjoint parts on \(\left[p+q-1\right]\) and \(\left\{p+q\right\}\).) The inequality is then equivalent to \begin{multline*} \widehat{\mathrm{Kr}}\left(\left.\mathrm{Kr}^{-1}\left(\rho\right)\right|_{\left[p+q-1\right]}\cdot\left(p+q\right)\right)\preceq\pi^{\prime}\\\Leftrightarrow\tilde{\rho}:=\left.\widehat{\mathrm{Kr}}\left(\left.\mathrm{Kr}^{-1}\left(\rho\right)\right|_{\left[p+q-1\right]}\cdot\left(p+q\right)\right)\right|_{\left[p+q-1\right]}\preceq\pi\textrm{.} \end{multline*} We expand the moments on the right-hand side of (\ref{formula: squished moments}) over \(\pi^{\prime}\) and \(\left({\cal U}^{\prime},\pi^{\prime}\right)\) according to (\ref{formula: moment cumulant}) and (\ref{formula: moment cumulant}) and collect the coefficient on each cumulant. For \(\rho\in S_{\mathrm{disc-nc}}\left(p,q\right)\), the total coefficient on \(\kappa_{\rho}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\) is \[-\sum_{\substack{\pi\in S_{\mathrm{disc-nc}}\left(p,q-1\right)\\\pi\succeq\tilde{\rho}}}\left(\mu\left(\pi,1\right)+\mu\left(\hat{\pi},1\right)\right)-\sum_{\substack{\pi\in S_{\mathrm{ann-nc}}\left(p,q-1\right)\\\pi\succeq\tilde{\rho}}}\mu\left(\pi,1\right)=0\textrm{,}\] for \(\rho\in S_{\mathrm{ann-nc}}\left(p,q\right)\), the total coefficient on \(\kappa_{\rho}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\) is \[-\sum_{\substack{\pi\in S_{\mathrm{ann-nc}}\left(p,q-1\right)\\\pi\succeq\tilde{\rho}}}\mu\left(\pi,1\right)-\sum_{\substack{\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q-1\right)\\\left({\cal U},\pi\right)\neq\left(1,\tau_{p,q-1}\right)\\{\cal U}\succeq\Pi\left(\tilde{\rho}\right)}}\mu\left(\hat{\pi},1\right)=\mu\left(1,1\right)=1\textrm{,}\] and for \(\left({\cal V},\rho\right)\in{\cal PS}^{\prime}\left(p,q\right)\) with \(\left({\cal V},\rho\right)\neq\left(1,\tau_{p,q}\right)\), the total coefficient on \(\kappa_{\left({\cal V},\rho\right)}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\) is \[-\sum_{\substack{\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q-1\right)\\\left({\cal U},\pi\right)\neq\left(1,\tau_{p,q-1}\right)\\{\cal U}\succeq{\cal V}}}\mu\left(\hat{\pi},1\right)=\mu\left(1,1\right)=1\textrm{.}\] Substituting this cumulant expansion of (\ref{formula: squished moments}) for \(\alpha_{p,q}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\) in (\ref{formula: moment cumulant}), the only term that does not appear on both the left-hand and right-hand side is \(\kappa_{p,q}\left(a_{1},\ldots,a_{p},b_{1},\ldots,b_{q}\right)\), which therefore vanishes. The converse of the theorem is much simpler. If mixed cumulants vanish, then we may expand \(\alpha_{p,q}\left(\mathring{a}_{1},\ldots,\mathring{a}_{p},\mathring{b}_{1},\ldots,\mathring{b}_{q}\right)\) as (\ref{formula: moment cumulant}). Of the first and second sums, over \(S_{\mathrm{ann-nc}}\left(p,q\right)\), all terms with single-element cycles vanish. Of the terms in the third sum, over \(\left({\cal U},\pi\right)\in{\cal PS}^{\prime}\left(p,q\right)\), each \(\pi\) has more than two single-element cycles (Lemma~\ref{lemma: singlets}), so not all such cycles may be contained in the nontrivial block of \({\cal U}\), and thus all such terms vanish. The remaining terms from the first two sums are those characterized by part~\ref{item: annular spoke}.\ of Lemma~\ref{lemma: singlets}, which gives us (\ref{formula: second-order freeness}). \end{proof} \section{Matrix cumulants} \label{section: matrix} \begin{definition} Denote the M\"{o}bius function on \({\cal P}\left(I\right)\) by \(\mu_{{\cal P}}\) (\(I\) will be clear from context). Then \[\mu_{{\cal P}}\left({\cal U},{\cal V}\right)=\prod_{V\in{\cal V}}\left(-1\right)^{\#\left(\left.{\cal U}\right|_{V}\right)-1}\left(\#\left(\left.{\cal U}\right|_{V}\right)-1\right)!\] (see \cite{MR2266879}, exercises to Chapter~10). \end{definition} \begin{definition} \label{definition: partition geodesic} For \({\cal U},{\cal V}\in{\cal P}\left(n\right)\), let \(\Gamma\left({\cal U},{\cal V}\right)\) be the set of partitions \({\cal W}\in{\cal P}\left(n\right)\) such that \[\#\left({\cal U}\right)-\#\left({\cal U}\vee{\cal W}\right)=\#\left({\cal U}\vee{\cal V}\right)-\#\left({\cal U}\vee{\cal V}\vee{\cal W}\right)\textrm{.}\] \end{definition} See, \cite{2015arXiv151101087R} for a proof that for any \({\cal W}\), the left-hand side is greater than or equal to the right-hand side, so the \({\cal W}\in\Gamma\left({\cal U},{\cal V}\right)\) are those maximizing the right-hand side. \begin{definition} For random variables \(Y_{1},\ldots,Y_{n}\) and \({\cal U}\in{\cal P}\left(n\right)\), the (classical) moment is \[a_{{\cal U}}\left(Y_{1},\ldots,Y_{n}\right):=\prod_{U\in{\cal U}}\mathbb{E}\left(\prod_{k\in U}Y_{k}\right)\textrm{.}\] For \({\cal U}\in{\cal P}\left(n\right)\), we define the {\em classical cumulants} \(k_{{\cal U}}\) over \(n\) random variables \(Y_{1},\ldots,Y_{n}\) by \[a_{{\cal U}}\left(Y_{1},\ldots,Y_{n}\right)=:\sum_{{\cal V}\preceq{\cal U}}k_{{\cal V}}\left(Y_{1},\ldots,Y_{n}\right)\] or equivalently \[k_{{\cal U}}\left(Y_{1},\ldots,Y_{n}\right):=\sum_{{\cal V}\preceq{\cal U}}\mu_{{\cal P}}\left({\cal V},{\cal U}\right)a_{{\cal V}}\left(Y_{1},\ldots,Y_{n}\right)\textrm{.}\] For \(n=1,2,\ldots\), \[k_{n}\left(Y_{1},\ldots,Y_{n}\right)=k_{1_{{\cal P}\left(n\right)}}\left(Y_{1},\ldots,Y_{n}\right)=\sum_{{\cal U}\in{\cal P}\left(n\right)}\mu_{{\cal P}}\left({\cal U},1\right)a_{{\cal U}}\left(Y_{1},\ldots,Y_{n}\right)\textrm{.}\] \end{definition} \begin{definition} \label{definition: premaps} For \(I\subseteq\left[n\right]\), we define \(\mathrm{PM}\left(I\right)\) as the set of permutations \(\pi\) on the set \(\left\{k,-k:k\in I\right\}\) such that \(\pi\left(k\right)=-\pi^{-1}\left(-k\right)\) and such that no \(k\) is in the same cycle as \(-k\). The cycles of such \(\pi\) consist of pairs where each cycle in a pair may be obtained from the other by reversing the order and the signs on each of the integers. See, e.g., \cite{MR1813436, 2012arXiv1204.6211R} for an explanation of how elements of \(\mathrm{PM}\left(I\right)\) correspond to unoriented surface gluings and the topological interpretations of the related definitions. We denote \(\mathrm{PM}\left(\left[n\right]\right)\) by \(\mathrm{PM}\left(n\right)\). For \(\pi\in\mathrm{PM}\left(I\right)\), we define \(\Pi\left(\pi\right)\) to be the partition, each of whose blocks corresponds to a pair of cycles described above, containing the absolute values of the integers in that pair of cycles. To simplify notation, we denote the restriction of \(\pi\) to \(J\cup\left(-J\right)\) by \(\left.\pi\right|_{J}\) (where \(-J=\left\{-k:k\in J\right\}\)). For \(\tau\in S_{n}\) we define the Kreweras complement of \(\pi\in\mathrm{PM}\left(I\right)\) (relative to \(\tau\)) as \[\mathrm{Kr}_{\tau}\left(\pi\right):=\left(-\tau^{-1}\right)\pi^{-1}\tau\] where we have used \(-\tau^{-1}\) to denote the permutation where integer \(k\) in the cycle notation of \(\tau^{-1}\) has been replaced by \(-k\). We let \(\mathrm{FD}\left(\rho\right)\) be the permutation formed by taking from each pair of cycles the cycle whose smallest absolute value integer has a positive sign. We define \[\mathrm{Kr}_{\rho}\left(\pi\right)=\left(-\mathrm{FD}\left(\rho\right)^{-1}\right)\pi^{-1}\mathrm{FD}\left(\rho\right)\textrm{.}\] We define the Euler characteristic of \(\pi\) (relative to \(\rho\), where \(\rho\) is an element of either \(S\left(n\right)\) or \(\mathrm{PM}\left(n\right)\)) by \[\chi_{\rho}\left(\pi\right):=\#\left(\Pi\left(\rho\right)\right)+\#\left(\Pi\left(\pi\right)\right)+\#\left(\Pi\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)\right)-n\textrm{.}\] We say that \(\pi\in\mathrm{PM}\left(I\right)\) is noncrossing (on \(\rho\)) if \(\chi_{\rho}\left(\pi\right)=2\#\left(\Pi\left(\rho\right)\right)\) (see \cite{MR3217665} for a proof that the left-hand side is less than or equal to the right-hand side). We denote the set of such \(\pi\) by \(\mathrm{PM}_{\mathrm{nc}}\left(n\right)\). We define \(\mathrm{PPM}\left(\tau\right)\subseteq{\cal P}\left(I\right)\times\mathrm{PM}\left(I\right)\) as the ordered pairs \(\left({\cal U},\pi\right)\) with \({\cal U}\succeq\Pi\left(\pi\right)\). For \(\tau\in S\left(I\right)\), we define \(\mathrm{PPM}^{\prime}\left(\tau\right)\subseteq\mathrm{PPM}\left(I\right)\) as the \(\left({\cal U},\pi\right)\) where \(\pi\in\mathrm{PM}_{\mathrm{nc}}\left(\tau\right)\), \(\Pi\left(\tau\right)\vee{\cal U}=1\), and \({\cal U}\in\Gamma\left(\Pi\left(\tau\right),\Pi\left(\pi\right)\right)\). (Such \({\cal U}\) can be thought of as those that join the smallest number of blocks of \(\Pi\left(\pi\right)\) in order for \(\Pi\left(\tau\right)\vee{\cal U}\) to be connected.) We extend the notation \(f_{\pi}\) from \(S\left(I\right)\) to \(\mathrm{PM}\left(I\right)\), for the functions \(f\) for which \(f_{\pi}\) is defined. We let \(X_{-k}:=X_{k}^{T}\). Then for \(\pi\in\mathrm{PM}\left(I\right)\), we let \(f_{\pi}:=f_{\mathrm{FD}\left(\pi\right)}\). We modify this notation for the classical cumulants. For \[\mathrm{FD}\left(\pi\right)=\left(c_{1},\ldots,c_{r_{1}}\right)\cdots\left(c_{r_{1}+\cdots+r_{m-1}+1},\ldots,c_{r_{1}+\cdots+r_{m}}\right)\] we define \[k_{\pi}\left(Y_{1},\ldots,Y_{n}\right)=k_{r}\left(\mathrm{tr}\left(X_{c_{1}}\cdots X_{c_{n_{1}}}\right),\ldots,\mathrm{tr}\left(X_{c_{n_{1}+\cdots+n_{r-1}+1}}\cdots X_{c_{n}}\right)\right)\textrm{.}\] We extend this notation to \(\left({\cal U},\pi\right)\in\mathrm{PPM}\left(n\right)\) by letting \[f_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{n}\right)=\prod_{U\in{\cal U}}f_{\left.\pi\right|_{U}}\left(X_{1},\ldots,X_{n}\right)\textrm{.}\] \end{definition} The following result is shown in \cite{MR3217665}: \begin{lemma} \label{lemma: annular premaps} For \(\tau:=\tau_{p,q}\) with two cycles, then the \(\pi\in\mathrm{PPM}_{\mathrm{nc}}^{\prime}\left(\tau_{p,q}\right)\) may be divided into three disjoint sets, which are respectively in bijection with \(S_{\mathrm{disc-nc}}\left(p,q\right)\), \(S_{\mathrm{ann-nc}}\left(p,q\right)\), and \(S_{\mathrm{ann-nc}}\left(p,q\right)\). In the first two cases, \(\pi\) never takes any element of \(\left[p+q\right]\) to \(-\left[p+q\right]\). Here \(\pi\mapsto\pi^{\prime}\) where \(\pi^{\prime}\) is \(\pi^{-1}\) restricted to \(\left[p+q\right]\). In the third, \(\pi^{\prime}\) never takes any element of \(\left[p\right]\cup\left(-\left[p+1,p+q\right]\right)\) to an element of \(\left(-\left[p\right]\right)\cup\left[p+1,p+q\right]\). Here \(\pi^{\prime}\) is constructed from \(\pi^{-1}\) by replacing \(-\left(p+1\right),\ldots,-\left(p+q\right)\) with \(p+q,\ldots,p-1\) respectively. In each case, the integer partition of \(\Pi\left(\mathrm{Kr}_{\tau}\left(\pi^{\prime}\right)\right)\) is the same as that of \(\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\right)\). \end{lemma} See Figure~\ref{figure: moment cumulant} for the topological intuition. The last case may be interpreted as the planar cases in which the second disc has been ``flipped over'' relative to the first. \begin{definition}[Collins, \'{S}niady] The {\em real Weingarten function} \(\mathrm{Wg}:{\cal P}\rightarrow\mathbb{R}\) is defined in \cite{MR2217291, MR2567222}. (It is typically defined on integer partitions; here, its value on a set partition \({\cal U}\) is its value on an integer partition whose parts are the sizes of the blocks of \({\cal U}\). It may also be defined as a function on a pair of pairings \(\pi_{1}\) and \(\pi_{2}\) (as referenced in the Introduction and Example~\ref{example: gluing}); the parts of the integer partitions are half the sizes of the blocks of \(\pi_{1}\vee\pi_{2}\).) We will suppress \(n\) and \(N\) in the notation. For large \(N\), \(\mathrm{Wg}\left({\cal U}\right)=O\left(N^{n-\#\left({\cal U}\right)}\right)\). We define the normalized Weingarten function \(\mathrm{wg}\left({\cal U}\right):=N^{-n+\#\left({\cal U}\right)}\mathrm{Wg}\left({\cal U}\right)\). It is possible to define a sort of cumulant of the Weingarten function for \({\cal U},{\cal V},{\cal W}\in{\cal P}\left(n\right)\) with \({\cal U}\preceq{\cal V}\preceq{\cal W}\): \[\mathrm{wg}_{{\cal U},{\cal V},{\cal W}}:=\sum_{{\cal X}:{\cal V}\preceq{\cal X}\preceq{\cal W}}\mu_{{\cal P}}\left({\cal X},{\cal W}\right)\prod_{X\in{\cal X}}\mathrm{wg}\left(\left.{\cal U}\right|_{X}\right)\] or equivalently (standard property of M\"{o}bius functions) \[\mathrm{wg}\left({\cal U}\right)=\sum_{{\cal X}:{\cal V}\preceq{\cal X}\preceq{\cal W}}\prod_{X\in{\cal X}}\mathrm{wg}_{{\cal U},{\cal X},{\cal W}}\textrm{.}\] Here the middle term \({\cal V}\) will typically be equal to the first term \({\cal U}\). When this is the case, it may be omitted. Define \begin{multline*} \gamma_{{\cal U},{\cal V}}:=\prod_{V\in{\cal V}}\left(-1\right)^{\left|V\right|-\#\left(\left.{\cal U}\right|_{V}\right)}\frac{2^{2\#\left(\left.{\cal U}\right|_{V}\right)-1}\left(2\left|V\right|+\#\left(\left.{\cal U}\right|_{V}\right)-3\right)!}{\left(2\left|V\right|\right)!}\\\times\prod_{U\in\left.{\cal U}\right|_{V}}\frac{\left(2\left|U\right|-1\right)!}{\left(\left|U\right|-1\right)!^{2}} \end{multline*} (where for a set \(I\), \(\left|I\right|\) denotes the number of elements in the set \(I\)). Then \[\mathrm{wg}_{{\cal U},{\cal V}}=\gamma_{{\cal U},{\cal V}}N^{-2\left(\#\left({\cal U}\right)-\#\left({\cal V}\right)\right)}+O\left(N^{1-\#\left({\cal U}\right)}\right)\textrm{.}\] See \cite{MR2217291, MR1761777, 2015arXiv151101087R} for more detail. \end{definition} \begin{definition}[Capitaine, Casalis] If \(X_{1},\ldots,X_{n}:\Omega\rightarrow M_{N\times N}\left(\mathbb{C}\right)\) are random matrices, then the (normalized) matrix cumulants \(c_{\pi}\), \(\pi\in\mathrm{PM}\left(n\right)\) are defined by the equations, for \(\pi\in\mathrm{PM}\left(n\right)\): \[\mathbb{E}\left(\mathrm{tr}_{\pi}\left(X_{1},\ldots,X_{n}\right)\right)=:\sum_{\rho\in\mathrm{PM}\left(n\right)}N^{\chi_{\pi}\left(\rho\right)-2\#\left(\Pi\left(\pi\right)\right)}c_{\rho}\left(X_{1},\ldots,X_{n}\right)\] or equivalently, \begin{multline*} c_{\rho}\left(X_{1},\ldots,X_{n}\right)\\:=\sum_{\pi\in\mathrm{PM}\left(n\right)}N^{\chi_{\rho}\left(\pi\right)-2\#\left(\Pi\left(\rho\right)\right)}\mathrm{wg}\left(\Pi\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)\right)\mathbb{E}\left(\mathrm{tr}_{\pi^{-1}}\left(X_{1},\ldots,X_{n}\right)\right)\textrm{.} \end{multline*} For \({\cal U}\in{\cal P}\left(n\right)\) with \({\cal U}\succeq\Pi\left(\pi\right)\), we define \[c_{\left({\cal U},\pi\right)}=\left(X_{1},\ldots,X_{n}\right):=\prod_{U\in{\cal U}}c_{\left.\pi\right|_{U}}\left(X_{1},\ldots,X_{n}\right)\textrm{.}\] \end{definition} \begin{definition} For \(n=1,2,\ldots\) and \(\pi\in\mathrm{PM}\left(n\right)\), \({\cal U}\in{\cal P}\left(n\right)\) with \({\cal U}\succeq\Pi\left(\pi\right)\), we define the vertex cumulants \(K_{\left({\cal U},\pi\right)}\) to be multilinear functions of \(n\) random matrices which are multiplicative over the blocks of \({\cal U}\) (i.e. \[K_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{n}\right)=\prod_{U\in{\cal U}}K_{\left(\left\{U\right\},\left.\pi\right|_{U}\right)}\left(X_{1},\ldots,X_{n}\right)\] where each \(K_{\left(\left\{U\right\},\left.\pi\right|_{U}\right)}\) is a function of only the \(X_{k}\) with \(k\in U\)) satisfying \begin{equation} c_{\pi}\left(X_{1},\ldots,X_{n}\right)=:\sum_{\substack{{\cal U}\in{\cal P}\left(n\right)\\{\cal U}\succeq\Pi\left(\pi\right)}}K_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{n}\right) \label{formula: matrix-vertex} \end{equation} or equivalently \begin{equation} K_{\left({\cal U},\pi\right)}:=\sum_{\substack{{\cal V}\in{\cal P}\left(n\right)\\\Pi\left(\pi\right)\preceq{\cal V}\preceq{\cal U}}}\mu_{{\cal P}}\left({\cal V},{\cal U}\right)c_{\left({\cal V},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\textrm{.} \label{formula: vertex-matrix} \end{equation} If \({\cal U}\) is omitted, we will take it to be equal to \(1\in{\cal P}\left(n\right)\): \[K_{\pi}\left(X_{1},\ldots,X_{n}\right)=\sum_{\substack{{\cal V}\in{\cal P}\left(n\right)\\{\cal V}\succeq\Pi\left(\pi\right)}}\mu_{{\cal P}}\left({\cal V},1\right)c_{\left({\cal V},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\textrm{.}\] We will denote \(K_{\tau_{r_{1},\ldots,r_{k}}}\) by \(K_{r_{1},\ldots,r_{k}}\). \label{definition: vertex cumulants} \end{definition} \begin{remark} Real vertex cumulants, like matrix cumulants, may be complex-valued, as in the case of Wishart matrices with a complex covariance matrix. The cumulants are real in the sense of being appropriate to matrices with orthogonally-invariant probability distributions, which is the invariance of the real random matrices. \end{remark} \begin{example} \label{example: gluing} The diagram shown in Figure~\ref{figure: orthogonally invariant} corresponds to the matrix cumulant \(c_{\rho}\left(X_{1},\ldots,X_{7}\right)\) with \[\rho=\left(1,5,-4\right)\left(4,-5,-1\right)\left(2\right)\left(-2\right)\left(3\right)\left(-3\right)\left(6,-7\right)\left(7,-6\right)\textrm{.}\] We compute that \[\mathrm{Kr}_{\tau}\left(\rho\right)=\left(-\tau_{3,4}^{-1}\right)\rho^{-1}\tau_{3,4}=\left(1,2,3,5,-6,7,-4\right)\left(4,-7,6,-5,-3,-2,-1\right)\] so \(\chi_{3,4}\left(\rho\right)=\#\left(\Pi\left(\tau_{3,4}\right)\right)+\#\left(\Pi\left(\rho\right)\right)+\#\left(\Pi\left(\mathrm{Kr}_{3,4}\left(\rho\right)\right)\right)-7=2+4+1-7=0\) (incidentally the surface is a Klein bottle, since it is non-orientable). The upper diagram shows how this cumulant corresponds to the contributions from the topological expansion of Haar-distributed orthogonal matrices where the pairing \(\pi_{1}\) on the first indices of \(O\) is \[\pi_{1}=\left(1,-5\right)\left(-1,-4\right)\left(2,-2\right)\left(3,-3\right)\left(4,5\right)\left(6,7\right)\left(-6,-7\right)\textrm{.}\] (where the negtative signs denote the transposed matrices \(O^{T}\) following the \(X_{k}\). Note that \(\pi_{1}=\delta\rho\) where \(\delta:k\mapsto -k\). The value of the cumulant is \begin{align*} c_{\rho}&=N^{-2}\sum_{\textrm{\(\pi_{2}\) a pairing on \(\left[7\right]\cup\left(-\left[7\right]\right)\)}}\mathrm{Wg}\left(\pi_{1},\pi_{2}\right)\mathbb{E}\left(\mathrm{Tr}_{\delta\pi_{2}}\left(X_{1},\ldots,X_{7}\right)\right) \\&=\sum_{\pi\in\mathrm{PM}\left(7\right)}N^{\chi_{\rho}\left(\pi\right)-8}\mathrm{wg}\left(\Pi\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)\right)\mathbb{E}\left(\mathrm{tr}_{\pi^{-1}}\left(X_{1},\ldots,X_{7}\right)\right) \end{align*} (see \cite{2015arXiv151101087R} for two formulations of the topological expansion for Haar-distributed orthogonal matrices and \cite{MR3455672} for more details on the bijection between \(\mathrm{PM}\left(n\right)\) and pairings on \(\left[n\right]\cup\left(-\left[n\right]\right)\)). The two-vertex cumulant between the top-left and bottom-right vertices in Figure~\ref{figure: vertices} is: \begin{multline*} K_{\left(1,5,-4\right)\left(6,-7\right)}\left(X_{1},\ldots,X_{7}\right)=K_{3,2}\left(X_{1},X_{5},X_{4}^{T},X_{6},X_{7}^{T}\right)\\=c_{\left(1,5,-4\right)\left(6,-7\right)}\left(X_{1},\ldots,X_{7}\right)-c_{\left(1,5,-4\right)}\left(X_{1},\ldots,X_{7}\right)c_{\left(6,-7\right)}\left(X_{1},\ldots,X_{7}\right)\textrm{.} \end{multline*} \end{example} We present several lemmas in this section. \begin{lemma} Let \(X_{1},\ldots,X_{n}:\Omega\rightarrow M_{N\times N}\left(\mathbb{C}\right)\) be random matrices with orthogonally invariant joint probability distribution, \(\pi\in PM\left(n\right)\), and \({\cal U}\in{\cal P}\left(n\right)\) with \({\cal U}\succeq\Pi\left(\pi\right)\). Then the vertex cumulant is the sum over terms where the partitions on the classical cumulant and the Weingarten function connect the cycles of \(\pi\): \begin{multline} K_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\\=\sum_{\substack{\rho\in\mathrm{PM}\left(n\right)\\{\cal V}\succeq\Pi\left(\rho\right)\\{\cal W}\succeq\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right)\\\Pi\left(\pi\right)\vee{\cal V}\vee{\cal W}={\cal U}}}N^{\chi_{\pi}\left(\rho\right)-2\#\left(\Pi\left(\pi\right)\right)}\mathrm{wg}_{\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right),{\cal W}}k_{\left({\cal V},\rho\right)}\left(X_{1},\ldots,X_{n}\right)\textrm{.} \label{formula: connected diagrams} \end{multline} \label{lemma: connected diagrams} \end{lemma} \begin{proof} We show that the expressions satisfy (\ref{formula: matrix-vertex}). Any \(\rho\in\mathrm{PM}\left(n\right)\) appearing in (\ref{formula: connected diagrams}) has \(\Pi\left(\rho\right)\preceq{\cal U}\), since \({\cal V}\preceq{\cal U}\), and can thus be expressed uniquely as the product of permutations in \(\mathrm{PM}\left(U\right)\) for each \(U\in{\cal U}\). Both \(\chi_{\pi}\left(\rho\right)\) and \(\#\left(\Pi\left(\pi\right)\right)\) are additive over the blocks \(U\) of \({\cal U}\), so the power of \(N\) is multiplicative over the \(U\). Likewise, any partitions \({\cal V},{\cal W}\preceq{\cal U}\) may be expressed uniquely as the union of partitions in each \({\cal P}\left(U\right)\). Both \(k_{\left({\cal V},\rho\right)}\) and \(\mathrm{wg}_{\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right),{\cal W}}\) are multiplicative over the blocks of their respective partitions, and hence over the blocks of \({\cal U}\). Thus the conjectured expression for \(K_{\left({\cal U},\pi\right)}\) is the product of the conjectured expressions for the \(K_{\left.\pi\right|_{U}}\), which are multilinear functions on the \(X_{1},\ldots,X_{n}\) which depend only on the \(X_{k}\) for which \(k\in U\). Expanding the matrix cumulant \(c_{\pi}\) in the cumulants of the expected value and the Weingarten function, it is a sum: \[\sum_{\substack{\rho\in\mathrm{PM}\left(n\right)\\{\cal V}\succeq\Pi\left(\rho\right)\\{\cal W}\succeq\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right)}}N^{\chi_{\pi}\left(\rho\right)-2\#\left(\Pi\left(\pi\right)\right)}\mathrm{wg}_{\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right),{\cal W}}k_{\left({\cal V},\rho\right)}\left(X_{1},\ldots,X_{n}\right)\] and hence a sum over the conjectured expression for \(K_{\left({\cal U},\pi\right)}\) for all \({\cal U}\succeq\Pi\left(\pi\right)\). Thus the conjectured expression for the vertex cumulants satisfies (\ref{formula: matrix-vertex}). \end{proof} \begin{lemma} If \(X_{1},\ldots,X_{n}:\Omega\rightarrow M_{N\times N}\left(\mathbb{C}\right)\) are random matrices, and a subset of the \(X_{k}\) is independent from and orthogonally in general position to the others, then the mixed cumulant vanishes: \[K_{\pi}\left(X_{1},\ldots,X_{n}\right)=0\textrm{.}\] \end{lemma} \begin{proof} Let \({\cal U}=\left\{U_{1},\ldots,U_{r}\right\}=\Pi\left(\pi\right)\). We construct a generating function for the matrix cumulants restricted to collections of cycles of \(\pi\): for \(I=\left\{i_{1},\ldots,i_{s}\right\}\subseteq\left[r\right]\) we let \[f_{I}:=c_{\left.\pi\right|_{U_{i_{1}}\cup\cdots\cup U_{i_{s}}}}\left(X_{1},\ldots,X_{n}\right)\] and let \[f\left(x_{1},\ldots,x_{r}\right)=1+\sum_{\substack{I=\left\{i_{1},\ldots,i_{s}\right\}\subseteq\left[r\right]\\I\neq\emptyset}}f_{I}x_{i_{1}}\cdots x_{i_{s}}\textrm{.}\] We now show \(g\left(x_{1},\ldots,x_{r}\right):=\log f\left(x_{1},\ldots,x_{r}\right)\) is a generating function for the vertex cumulants: expanding in the Taylor expansion for the logarithm \[g\left(x_{1},\ldots,x_{r}\right)=\sum_{k=1}^{\infty}\frac{\left(-1\right)^{k-1}}{k}\left(f\left(x_{1},\ldots,x_{r}\right)-1\right)^{k}\] the coefficient of \(x_{1}\cdots x_{r}\) is the sum over partitions \({\cal V}=\left\{V_{1},\ldots,V_{s}\right\}\in{\cal P}\left(r\right)\) of: \[s!\frac{\left(-1\right)^{s-1}}{s}f_{V_{1}}\cdots f_{V_{s}}=\mu_{{\cal P}}\left({\cal V},1\right)\prod_{V\in{\cal V}}c_{\left.\pi\right|_{\bigcup_{i\in V}U_{i}}}\left(X_{1},\ldots,X_{n}\right)\textrm{.}\] (\({\cal V}\) representing contributions from the \(k=s\) term of the logarithm in which the \(x_{i}\) whose subscripts are in the same block \(V_{i}\) are from the same \(\left(f\left(x_{1},\ldots,x_{r}\right)-1\right)\) factor: as the term from each factor is distinct, there are \(s!\) terms corresponding to partition \({\cal V}\) in this way). It is shown in \cite{MR2337139} that if for some \(I\subseteq\left[n\right]\) the \(X_{i}\) for \(i\in I\) are independent and orthogonally in general position from the \(X_{i}\), \(i\notin I\), then for any \(\rho\in\mathrm{PM}\left(n\right)\) such that \(\Pi\left(\rho\right)\) connects \(I\) and \(\left[n\right]\setminus I\), \[c_{\rho}\left(X_{1},\ldots,X_{n}\right)=0\] and if \(\Pi\left(\rho\right)\) which does not connect \(I\) and \(\left[n\right]\setminus I\) \[c_{\rho}\left(X_{1},\ldots,X_{n}\right)=c_{\left.\pi\right|_{I}}\left(X_{1},\ldots,X_{n}\right)c_{\left.\pi\right|_{\left[n\right]\setminus I}}\left(X_{1},\ldots,X_{n}\right)\] (see also \cite{2015arXiv151101087R}). Thus, if \(f_{1}\left(x_{1},\ldots,x_{r}\right)\) is the generating function for the matrix cumulants of the \(X_{i}\) with \(i\in I\) (where the terms with an \(x_{i}\) with \(i\notin I\) vanish) and \(f_{2}\left(x_{1},\ldots,x_{r}\right)\) is the generating function for the matrix cumulants of the \(X_{i}\) with \(i\notin I\) (where, likewise, terms with \(x_{i}\) where \(i\in I\) vanish), then the generating function for the matrix cumulants of all the \(X_{1},\ldots,X_{r}\) is \[f\left(x_{1},\ldots,x_{r}\right)=f_{1}\left(x_{1},\ldots,x_{r}\right)f_{2}\left(x_{1},\ldots,x_{r}\right)\textrm{.}\] Then the generating function for the vertex cumulants is \[\log\left(f_{1}\left(x_{1},\ldots,x_{r}\right)f_{2}\left(x_{1},\ldots,x_{r}\right)\right)=\log\left(f_{1}\left(x_{1},\ldots,x_{r}\right)\right)+\log\left(f_{2}\left(x_{1},\ldots,x_{r}\right)\right)\] which has vanishing coefficients on all terms with \(x_{i}\) from both \(I\) and \(\left[r\right]\setminus I\). \end{proof} \begin{lemma} Let \(r_{1},\ldots,r_{m}\) be positive integers, \(n:=r_{1}+\cdots+r_{m}\), and let \(\tau:=\tau_{r_{1},\ldots,r_{m}}\). Then \begin{multline} k_{m}\left(\mathrm{tr}\left(X_{1}\cdots X_{r_{1}}\right),\ldots,\mathrm{tr}\left(X_{r_{1}+\cdots+r_{m-1}+1}\cdots X_{n}\right)\right)\\=\sum_{\substack{\pi\in\mathrm{PM}\left(n\right)\\{\cal U}\succeq\Pi\left(\pi\right)\\\Pi\left(\tau\right)\vee{\cal U}=1}}N^{\chi_{\tau}\left(\pi\right)-2\#\left(\tau\right)}K_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\textrm{.} \label{formula: moment vertex-cumulant} \end{multline} \label{lemma: classical cumulant connected} \end{lemma} \begin{proof} From the definitions: \begin{align*} &k_{\left(1,\tau\right)}\left(X_{1},\ldots,X_{n}\right)\\&=\sum_{{\cal U}\succeq\Pi\left(\tau\right)}\mu_{{\cal P}}\left({\cal U},1\right)a_{\left({\cal U},\tau\right)}\left(X_{1},\ldots,X_{n}\right)\\&=\sum_{{\cal U}\succeq\Pi\left(\tau\right)}\mu_{{\cal P}}\left({\cal U},1\right)\sum_{\substack{\left({\cal V},\pi\right)\in{\cal PPM}\left(n\right)\\{\cal V}\preceq{\cal U}}}N^{\chi_{\tau}\left(\pi\right)-2\#\left(\tau\right)}K_{\left({\cal V},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\textrm{.} \end{align*} Reversing the order of summation, we get \[\sum_{\left({\cal V},\pi\right)\in{\cal PPM}\left(n\right)}N^{\chi_{\tau}\left(\pi\right)-2\#\left(\tau\right)}K_{\left({\cal V},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\sum_{{\cal U}\succeq\Pi\left(\tau\right)\vee{\cal V}}\mu_{{\cal P}}\left({\cal U},1\right)\textrm{.}\] The result follows from the propertes of the M\"{o}bius function. \end{proof} \subsection{Asymptotics} \label{subsection: asymptotics} We will consider series of random matrices \(\left\{X_{\lambda}^{\left(N\right)}:\Omega\rightarrow M_{N\times N}\left(\mathbb{C}\right)\right\}_{\lambda\in\Lambda,N\in I}\) where \(I\subseteq\mathbb{N}\), and quantities where the dimension of the matrix \(N\rightarrow\infty\). We will typically suppress \(N\) in the notation. \begin{definition} We say that random matrices \(\left\{X_{\lambda}:\Omega\rightarrow M_{N_{k}\times N_{k}}\left(\mathbb{C}\right)\right\}_{\lambda\in\Lambda}\) (for \(N=N_{1},N_{2},\ldots\) with \(N_{k}\rightarrow\infty\)) have {\em limit distribution} \(\left\{x_{\lambda}\right\}_{\lambda\in\Lambda}\subseteq A\) (where \(\left(A,\varphi_{1}\right)\) is a noncommutative probability space) if, for any \(\lambda_{1},\ldots,\lambda_{n}\in\Lambda\), \[\lim_{N\rightarrow\infty}\mathbb{E}\left(\mathrm{tr}\left(X_{\lambda_{1}}\cdots X_{\lambda_{n}}\right)\right)=\phi_{1}\left(x_{\lambda_{1}}\cdots x_{\lambda_{n}}\right)\] while all higher cumulants of normalized traces of random matrices in the algebra generated by \(X_{\lambda}\) vanish as \(N\rightarrow\infty\). This is also a {\em real second-order limit distribution} if \(\left(A,\varphi_{1},\varphi_{2}\right)\) is a real second-order probability space, if there is an involution on \(\Lambda\), \(\lambda\mapsto-\lambda\), such that \(X_{-\lambda}=X_{\lambda}^{T}\), and for \(\lambda_{1},\ldots,\lambda_{p+q}\in\Lambda\): \begin{multline*} \lim_{N\rightarrow\infty}N^{2}k_{2}\left(\mathrm{tr}\left(X_{\lambda_{1}}\cdots X_{\lambda_{p}}\right),\mathrm{tr}\left(X_{\lambda_{p+1}}\cdots X_{\lambda_{p+q}}\right)\right)\\=\phi_{2}\left(x_{\lambda_{1}}\cdots x_{\lambda_{p}},x_{\lambda_{p+1}}\cdots x_{\lambda_{p+q}}\right) \end{multline*} while for \(m>2\) and \(X_{1},\ldots,X_{m}\) in the algebra generated by the \(X_{\lambda}\) \[\lim_{N\rightarrow\infty}N^{m}k_{m}\left(\mathrm{tr}\left(X_{1}\right),\ldots,\mathrm{tr}\left(X_{m}\right)\right)=0\textrm{.}\] For \(m>2\), the matrices have a {\em real \(m\)th order limit distribution} in \(m\)th-order probability space \(\left(A,\varphi_{1},\ldots,\varphi_{m}\right)\) if for every \(m^{\prime}<m\) they have \(m^{\prime}\)th-order limit distribution \(\left(A,\varphi_{1},\ldots,\varphi_{m^{\prime}}\right)\); for any positive integers \(r_{1},\ldots,r_{m}\) and \(X_{\lambda_{1}},\ldots,X_{\lambda_{r_{1}+\cdots+r_{m}}}\) with \(\lambda_{1},\ldots,\lambda_{r_{1}+\cdots+r_{m}}\in\Lambda\): \begin{multline*} \lim_{N\rightarrow\infty}N^{2m-2}k_{m}\left(\mathrm{tr}\left(X_{\lambda_{1}}\cdots X_{\lambda_{r_{1}}}\right),\ldots,\mathrm{tr}\left(X_{\lambda_{r_{1}+\cdots+r_{m-1}+1}}\cdots X_{\lambda_{r_{1}+\cdots+r_{m}}}\right)\right) \\=\varphi_{m}\left(x_{\lambda_{1}}\cdots x_{\lambda_{r_{1}}},\ldots,x_{\lambda_{r_{1}+\cdots+r_{m-1}+1}}\cdots x_{\lambda_{r_{1}+\cdots+r_{m}}}\right)\textrm{;} \end{multline*} and for any \(m^{\prime}>m\) and \(X_{1},\ldots,X_{m^{\prime}}\) in the algebra generated by the \(X_{\lambda}\) all the limits \[\lim_{N\rightarrow\infty}N^{m+m^{\prime}-2}k_{m^{\prime}}\left(X_{1},\ldots,X_{m^{\prime}}\right)=0\textrm{.}\] \end{definition} If the matrices have a higher-order limit distribution, the orders of the cumulants decrease with the number of vertices in the following way: \begin{proposition} Let \(m\geq 2\), \(r_{1},\ldots,r_{m}\geq 0\), \(n:=r_{1}+\cdots+r_{m}\), and \(\tau:=\tau_{r_{1},\ldots,r_{m}}\). If random matrices \(X_{1},\ldots,X_{n}:\Omega\rightarrow M_{N\times N}\left(\mathbb{C}\right)\) have an \(m\)th-order limit distribution, then \begin{multline} \lim_{N\rightarrow\infty}N^{2m-2}K_{r_{1},\ldots,r_{m}}\left(X_{1},\ldots,X_{m}\right)\\=\sum_{\substack{\pi\in\mathrm{PM}_{\mathrm{nc}}\left(r_{1},\ldots,r_{m}\right)\\{\cal U}\succeq\Pi\left(\pi\right),{\cal U}\in\Gamma\left(\Pi\left(\tau\right),\Pi\left(\pi\right)\right)\\{\cal V}\succeq\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\right),{\cal V}\in\Gamma\left(\Pi\left(\tau\right)\vee{\cal U},\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\vee{\cal U}\right)\right)\\\Pi\left(\tau\right)\vee{\cal U}\vee{\cal V}=1}}\gamma_{\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\right),{\cal V}}\alpha_{\left({\cal U},\pi^{-1}\right)}\left(x_{1},\ldots,x_{n}\right)\textrm{.} \label{formula: higher free cumulant} \end{multline} In particular, this quantity can be expressed as a polynomial in \(\varphi_{1},\ldots,\varphi_{m}\) applied to elements in the algebra generated by \(x_{1},\ldots,x_{n}\). For \(m^{\prime}>m\) \begin{equation} K_{r_{1},\ldots,r_{m^{\prime}}}\left(X_{1},\ldots,X_{m^{\prime}}\right)=O\left(N^{2-m-m^{\prime}}\right)\textrm{.} \label{formula: even higher free cumulants} \end{equation} \label{proposition: higher free cumulants} \end{proposition} \begin{proof} We first consider (\ref{formula: higher free cumulant}). Consider a term associated to \(\rho\in\mathrm{PM}\left(n\right)\) in (\ref{formula: connected diagrams}) (we will use the notation of that formula throughout). The exponent on \(N\) is \[\chi_{\pi}\left(\rho\right)-2m\leq 2\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)-2m\textrm{.}\] An \(s\)th classical cumulant of traces is \(O\left(N^{2-s-\min\left(s,m\right)}\right)\). By the comment after Definition~\ref{definition: partition geodesic}, on a block \(I\in\Pi\left(\pi\right)\vee{\cal V}\), we have \(\#\left(\left.{\cal V}\right|_{I}\right)-\#\left(\left.\Pi\left(\rho\right)\right|_{I}\right)\leq\#\left(\left.\Pi\left(\pi\right)\right|_{I}\vee\left.{\cal V}\right|_{I}\right)-\#\left(\left.\Pi\left(\pi\right)\right|_{I}\vee\left.\Pi\left(\rho\right)\right|_{I}\right)=1-\#\left(\left.\Pi\left(\pi\right)\right|_{I}\vee\left.\Pi\left(\rho\right)\right|_{I}\right)\). In the case where at least one of the cumulants is \(O\left(N^{2-s-m}\right)\), since \(1-m\leq 1-\#\left(\left.\Pi\left(\pi\right)\right|_{I}\vee\left.\Pi\left(\rho\right)\right|_{I}\right)\) and the terms \(1-\min\left(s,m\right)\) are never positive, the sum of these terms over all cumulants whose entries are contained in \(I\) will again be less than or equal to \(1-\#\left(\left.\Pi\left(\pi\right)\right|_{I}\vee\left.\Pi\left(\rho\right)\right|_{I}\right)\). Summing over the blocks \(I\in\Pi\left(\pi\right)\vee{\cal V}\), we have \[k_{\left({\cal V},\rho\right)}\left(X_{1},\ldots,X_{n}\right)=O\left(N^{-2\left(\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)-\#\left(\Pi\left(\pi\right)\vee{\cal V}\right)\right)}\right)\textrm{.}\] We also have \begin{multline*} \mathrm{wg}_{\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right),{\cal W}}=O\left(N^{-2\#\left(\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right)-\#\left({\cal W}\right)\right)}\right)\\=O\left(N^{-2\left(\#\left(\Pi\left(\pi\right)\vee{\cal V}\right)-\#\left(\Pi\left(\pi\right)\vee{\cal V}\vee{\cal W}\right)\right)}\right)\textrm{.} \end{multline*} Here \(\#\left(\Pi\left(\pi\right)\right)=m\) and \(\#\left(\Pi\left(\pi\right)\vee{\cal V}\vee{\cal W}\right)=1\), so the limit (\ref{formula: higher free cumulant}) exists. Surviving terms are those where each of the three factors is of highest possible order in \(N\). Thus \(\chi_{\pi}\left(\rho\right)=2\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)\), or equivalently \(\rho\in\mathrm{PM}_{\mathrm{nc}}\left(\pi\right)\). Secondly, \begin{multline*} \sum_{V\in{\cal V}}2-\#\left(\left.\Pi\left(\rho\right)\right|_{V}\right)-\min\left(\#\left(\left.\Pi\left(\rho\right)\right|_{V}\right),m\right)\\=-2\left(\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)-\#\left(\Pi\left(\pi\right)\vee{\cal V}\right)\right) \end{multline*} Since \(\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)\leq m\), no summand on the left-hand side may be less than \(2-2m\), and hence no \(V\in{\cal V}\) may contain more than \(m\) blocks of \(\Pi\left(\rho\right)\). It follows that the classical cumulants are at most \(m\)th cumulants, and thus have \(N\rightarrow\infty\) limits which can be expressed in \(\phi_{1},\ldots,\phi_{m}\) applied to expressions in \(x_{1},\ldots,x_{n}\). Furthermore, a surviving term will have \(\#\left(\Pi\left(\rho\right)\right)-\#\left({\cal V}\right)=\#\left(\Pi\left(\pi\right)\vee{\cal V}\right)-\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)\). The condition is equivalent to the second condition under the summation sign in (\ref{formula: higher free cumulant}), and the limit is the moment. Finally, we need \[\#\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right)-\#\left({\cal W}\right)=\#\left(\Pi\left(\pi\right)\vee{\cal V}\right)-\#\left(\Pi\left(\pi\right)\vee{\cal V}\vee{\cal W}\right)\textrm{,}\] the third condition under the summation in (\ref{formula: higher free cumulant}). The limit of the cumulant of the Weingarten function is \(\gamma_{\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right),{\cal W}}\). The expression (\ref{formula: higher free cumulant}) follows. We now consider (\ref{formula: even higher free cumulants}). Again, let \(I\in\Pi\left(\pi\right)\vee{\cal V}\) and let the blocks of \({\cal V}\) in \(I\) contain \(s_{1},\ldots,s_{t}\) blocks of \(\Pi\left(\rho\right)\) respectively. By the comment after Definition~\ref{definition: partition geodesic}, \[\sum_{i=1}^{t}\left(1-\min\left(s_{i},m\right)\right)\leq 1-\min\left(\#\left(\left.\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right|_{I}\right),m\right)\] (considering the case where each summand on the left-hand side is equal to \(1-s_{i}\) and the case where at least one summand is equal to \(1-m\)). Summing over the blocks \(I\in\Pi\left(\pi\right)\vee{\cal V}\), we have \[\sum_{V\in{\cal V}}\left(1-\min\left(\#\left(\left.\rho\right|_{V}\right),m\right)\right)\leq\#\left(\Pi\left(\pi\right)\vee{\cal V}\right)-\min\left(\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right),m\right)\textrm{.}\] The product of classical cumulants is then \begin{multline*} k_{\left({\cal V},\rho\right)}\left(X_{1},\ldots,X_{n}\right)=O\left(N^{2\#\left({\cal V}\right)-\#\left(\rho\right)-\sum_{V\in{\cal V}}\min\left(\#\left(\left.\rho\right|_{V}\right),m\right)}\right)\\=O\left(N^{-\left(2\#\left(\Pi\left(\pi\right)\vee{\cal V}\right)-\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)-\min\left(\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right),m\right)\right)}\right)\textrm{.} \end{multline*} By the arguments above, if the \(\min\) function takes the value \(\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)\) the result follows, and if it take the value \(m\), then \[K_{r_{1},\ldots,r_{m^{\prime}}}\left(X_{1},\ldots,X_{n}\right)=O\left(N^{2-2m+\left(m-\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)\right)}\right)\textrm{.}\] Since \(\#\left(\Pi\left(\pi\right)\vee\Pi\left(\rho\right)\right)\leq\#\left(\pi\right)=m^{\prime}\), the result follows. \end{proof} We can define \(m\)th order free cumulants on \(m\)th order probability spaces as the limits of such functions. (We will see in Proposition~\ref{proposition: two-vertex limit} that this is consistent with the defintion of \(\kappa_{p,q}\).) Since the higher-order free cumulants are the limits of vertex cumulants, they vanish when applied to the limits of matrices which are independent and orthogonally in general position. \begin{definition} For \(r_{1},\ldots,r_{m}\geq 1\), \(\tau:=\tau_{r_{1},\ldots,r_{m}}\), and \(n:=r_{1}+\cdots+r_{m}\), we define a function \(\kappa_{r_{1},\ldots,r_{m}}:A^{n}\rightarrow\mathbb{C}\) \begin{multline*} \kappa_{r_{1},\ldots,r_{m}}\left(x_{1},\ldots,x_{n}\right)\\:=\sum_{\substack{\pi\in\mathrm{PM}_{\mathrm{nc}}\left(\tau\right)\\{\cal U}\succeq\Pi\left(\pi\right),{\cal U}\in\Gamma\left(\Pi\left(\tau\right),\Pi\left(\pi\right),\right)\\{\cal V}\succeq\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\right),{\cal V}\in\Gamma\left(\Pi\left(\tau\right)\vee{\cal U},\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\right)\right)\\\Pi\left(\tau\right)\vee{\cal U}\vee{\cal V}=1}}\gamma_{\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\right),{\cal V}}\alpha_{\left({\cal U},\pi^{-1}\right)}\left(x_{1},\ldots,x_{n}\right)\textrm{.} \end{multline*} We extend the definition to \(\kappa_{\pi}\) for \(\pi\in\mathrm{PM}\left(\tau\right)\) and \(\kappa_{\left({\cal U},\pi\right)}\) for \(\left({\cal U},\pi\right)\in\mathrm{PPM}^{\prime}\) as in Definition~\ref{definition: premaps}. \end{definition} The higher-order moments may be expressed as sums of the higher-order cumulants: \begin{proposition} Let \(X_{1},\ldots,X_{n}:\Omega\rightarrow M_{N\times N}\left(\mathbb{C}\right)\) be random matrices with an \(m\)th order limit distribution \(x_{1},\ldots,x_{n}\). Then for \(r_{1}+\cdots+r_{m}=n\), \[\alpha_{r_{1},\ldots,r_{m}}\left(x_{1},\ldots,x_{n}\right)=\sum_{\left({\cal U},\pi\right)\in{\cal PPM}^{\prime}\left(n\right)}\kappa_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{n}\right)\textrm{.}\] \label{proposition: limit cumulant} \end{proposition} \begin{proof} Let \(\tau:=\tau_{r_{1},\ldots,r_{m}}\), so \(\alpha_{r_{1},\ldots,r_{m}}\left(x_{1},\ldots,x_{n}\right)=\lim_{N\rightarrow\infty}k_{\tau}\left(X_{1},\ldots,X_{n}\right)\). We expand the cumulant as in Lemma~\ref{lemma: classical cumulant connected} and take the \(N\rightarrow\infty\) limit. The exponent on \(N\) is at most \(2\#\left(\Pi\left(\tau\right)\vee\Pi\left(\pi\right)\right)-2m\). By Proposition~\ref{proposition: higher free cumulants}, the product of vertex cumulants is \(O\left(N^{-2\left(\#\left(\Pi\left(\pi\right)\right)-\#\left({\cal V}\right)\right)}\right)\), and by the comment after Definition~\ref{definition: partition geodesic} \(-2\left(\#\left(\Pi\left(\pi\right)\right)-\#\left({\cal V}\right)\right)\geq -2\left(\#\left(\Pi\left(\tau\right)\vee\Pi\left(\pi\right)\right)-\#\left(\Pi\left(\tau\right)\vee{\cal V}\right)\right)\). Thus the limit of each summand exists, and the surviving terms are those where \(\chi_{\tau}\left(\pi\right)=2\#\left(\Pi\left(\tau\right)\vee\Pi\left(\pi\right)\right)\) (so \(\pi\in\mathrm{PM}_{\mathrm{nc}}\left(\tau\right)\)) and \(\#\left(\Pi\left(\pi\right)\right)-\#\left({\cal V}\right)=\#\left(\Pi\left(\tau\right)\vee\Pi\left(\pi\right)\right)-\#\left(\Pi\left(\tau\right)\vee{\cal V}\right)\) (so \({\cal U}\in\Gamma\left(\Pi\left(\pi\right),\Pi\left(\tau\right)\vee\Pi\left(\pi\right)\right)\)). The limit of the term associated with such a \(\left({\cal U},\pi\right)\) is the desired cumulant. \end{proof} \subsection{Second-order freeness} \label{subsection: second-order} The limits of two-vertex cumulants \(K_{\tau_{p,q}^{-1}}\) are second-order free cumulants \(\kappa_{p,q}\). The definition of \(\kappa_{p,q}\) given in Section~\ref{section: freeness} thus coincides with that given in Section~\ref{section: matrix}. \begin{proposition} If random matrices \(\left\{X_{\lambda}:\Omega\rightarrow\mathbb{C}\right\}_{\lambda\in\Lambda}\) have a second-order limit distribution, then for any \(\lambda_{1},\ldots,\lambda_{p+q}\in\Lambda\), \begin{multline*} \lim_{N\rightarrow\infty}N^{2}K_{\tau_{p,q}^{-1}}\left(X_{\lambda_{1}},\ldots,X_{\lambda_{p}};X_{\lambda_{p+1}},\ldots,X_{\lambda_{p+q}}\right)\\=\kappa_{p,q}\left(x_{\lambda_{1}},\ldots,x_{\lambda_{p}};x_{\lambda_{p+1}},x_{\lambda_{p+q}}\right). \end{multline*} \label{proposition: two-vertex limit} \end{proposition} \begin{proof} Let \(\tau:=\tau_{p,q}\). A summand in (\ref{formula: higher free cumulant}) corresponds to a \(\pi\in\mathrm{PM}_{\mathrm{nc}}\left(\tau\right)\), which corresponds to a \(\pi^{\prime}\) according to Lemma~\ref{lemma: annular premaps}. If \(\Pi\left(\pi^{\prime}\right)\) does not connect \(\left[p\right]\) and \(\left[p+1,p+q\right]\), then either \({\cal U}=\Pi\left(\pi^{\prime}\right)\) (in which case \({\cal V}\) connects two blocks of \(\Pi\left(\mathrm{Kr}_{\tau}\left(\pi^{\prime}\right)\right)\)), or \({\cal U}\) joins two blocks of \(\Pi\left(\pi^{\prime}\right)\) (in which case \({\cal V}=\Pi\left(\mathrm{Kr}_{\tau}\left(\pi^{\prime}\right)\right)\)). The terms corresponding to the former are those in the first sum of (\ref{formula: cumulant moment}), if we sum over all such \({\cal V}\). The terms corresponding to the latter are those in the fourth sum in (\ref{formula: cumulant moment}). If \(\Pi\left(\pi\right)\) connects \(\left[p\right]\) and \(\left[p+1,p+q\right]\), then \({\cal U}=\Pi\left(\pi\right)\) and \({\cal V}=\Pi\left(\mathrm{Kr}_{\tau}\left(\pi\right)\right)\). Such terms correspond to those in the second and third sums of (\ref{formula: cumulant moment}). \end{proof} We show an example of the types of terms that show up in asymptotic expansion of a two-vertex cumulant. The limits of these terms appear as terms in the expression for the second-order cumulant. \begin{example} We consider the two-vertex cumulant \[K_{3,5}\left(X_{1},X_{2},X_{3},X_{4},X_{5},X_{6},X_{7},X_{8}\right)\textrm{.}\] The first diagram corresponds to \[\pi=\left(1,3\right)\left(-3,-1\right)\left(2\right)\left(-2\right)\left(4,7\right)\left(-7,-4\right)\left(5\right)\left(-5\right)\left(6\right)\left(-6\right)\left(8\right)\left(-8\right)\] which has \(\Pi\left(\mathrm{Kr}_{3,5}\left(\pi\right)\right)=\left\{\left\{1,2\right\},\left\{3\right\},\left\{4,5,6\right\},\left\{7,8\right\}\right\}\). This diagram is not connected, so at least one of \({\cal U}\) and \({\cal V}\) must connect the cycles of \(\tau_{3,5}\). We consider the term where \({\cal U}=\Pi\left(\pi\right)=\left\{\left\{1,3\right\},\left\{2\right\},\left\{4,7\right\},\left\{5\right\}\left\{6\right\},\left\{8\right\}\right\}\) and the unique nontrivial block of \({\cal V}\) contains the two cycles of the complement traced with dotted lines: \[{\cal V}=\left\{\left\{1,2\right\},\left\{3,4,5,6\right\},\left\{7,8\right\}\right\}\textrm{.}\] The contribution of the Weingarten function is \[\mathrm{wg}_{\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right),{\cal V}}=\mathrm{wg}\left(\left[2\right]\right)\left(\mathrm{wg}\left(\left[3,1\right]\right)-\mathrm{wg}\left(\left[3\right]\right)\cdot\mathrm{wg}\left(\left[1\right]\right)\right)\mathrm{wg}\left(\left[2\right]\right)\textrm{.}\] Since \(\gamma_{\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right),{\cal V}}=\left(-1\right)\cdot 30\cdot\left(-1\right)=30\), this quantity is \(30N^{-2}+O\left(N^{-3}\right)\). The contribution of the moments is \[\mathbb{E}\left(\mathrm{tr}\left(X_{1}X_{3}\right)\mathrm{tr}\left(X_{2}\right)\mathrm{tr}\left(X_{4}X_{7}\right)\mathrm{tr}\left(X_{5}\right)\mathrm{tr}\left(X_{6}\right)\mathrm{tr}\left(X_{8}\right)\right)\] which has \(N\rightarrow\infty\) limit \[\alpha_{2}\left(x_{1},x_{3}\right)\alpha_{1}\left(x_{2}\right)\alpha_{2}\left(x_{4},x_{7}\right)\alpha_{1}\left(x_{5}\right)\alpha_{1}\left(x_{6}\right)\alpha_{1}\left(x_{8}\right)=\alpha_{\pi^{\prime}}\left(x_{1},\ldots,x_{8}\right)\textrm{.}\] Because \(\chi_{\tau}\left(\pi\right)=4\), the limit (multiplied by \(N^{2}\)) survives, and in the limit its contribution is \(30\alpha_{\pi^{\prime}}\left(x_{1},\ldots,x_{8}\right)\). The sum over all \({\cal V}\succeq\Pi\left(\mathrm{Kr}_{\pi}\left(\rho\right)\right)\) with exactly one nontrivial block connecting \(\left[p\right]\) and \(\left[p+1,p+q\right]\) will have total coefficient \(\mu\left(\pi^{\prime},1\right)\). The second diagram corresponds to \[\pi=\left(1,3,6,4\right)\left(-4,-6,-3,-1\right)\left(2,7\right)\left(-7,-2\right)\left(5\right)\left(-5\right)\left(8\right)\left(-8\right)\] with \(\chi_{3,5}\left(\pi\right)=2\). An asymptotically nonvanishing term must have \({\cal U}=\Pi\left(\pi\right)\) and \({\cal V}=\Pi\left(\mathrm{Kr}_{\tau_{3,5}}\left(\pi\right)\right)\). The limit of the cumulant of traces is \begin{multline*} \lim_{N\rightarrow\infty}k_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{8}\right)\\=\lim_{N\rightarrow\infty}\mathbb{E}\left(\mathrm{tr}\left(X_{1}X_{4}X_{6}X_{3}\right)\right)\mathbb{E}\left(\mathrm{tr}\left(X_{2}X_{7}\right)\right)\mathbb{E}\left(\mathrm{tr}\left(X_{5}\right)\right)\mathbb{E}\left(\mathrm{tr}\left(X_{8}\right)\right)\\=\alpha_{4}\left(x_{1},x_{4},x_{6},x_{3}\right)\alpha_{2}\left(x_{2},x_{7}\right)\alpha_{1}\left(x_{5}\right)\alpha_{1}\left(x_{8}\right)=\alpha_{\pi^{\prime}}\left(x_{1},\ldots,x_{8}\right)\textrm{.} \end{multline*} The limit of the Weingarten function is \(2\), so the limit of the term is \(2\alpha_{\pi^{\prime}}\left(x_{1},\ldots,x_{8}\right)\). The third diagram corresponds to \[\pi=\left(1,-6,2\right)\left(-2,6,-1\right)\left(3,-5\right)\left(5,-3\right)\left(4,7\right)\left(-7,-4\right)\left(8\right)\left(-8\right)\] which has \[\pi^{\prime}=\left(1,2,6\right)\left(3,7\right)\left(4\right)\left(5,8\right)\in S_{\mathrm{ann-nc}}\left(3,5\right)\textrm{.}\] The contribution of the moment is \begin{multline*} \alpha_{\pi^{\prime}}\left(x_{1},x_{2},x_{3},x_{8}^{t},x_{7}^{t},x_{6}^{t},x_{5}^{t},x_{4}^{t}\right)\\=\alpha_{3}\left(x_{1},x_{2},x_{6}^{t}\right)\alpha_{2}\left(x_{3},x_{5}^{t}\right)\alpha_{2}\left(x_{4},x_{7}\right)\alpha_{1}\left(x_{8}\right)\textrm{.} \end{multline*} The limit of this term is \(2\alpha_{3}\left(x_{1},x_{2},x_{6}^{t}\right)\alpha_{2}\left(x_{3},x_{5}^{t}\right)\alpha_{2}\left(x_{4},x_{7}\right)\alpha_{1}\left(x_{8}\right)\). The fourth diagram corresponds to \[\pi=\left(1\right)\left(-1\right)\left(2,3\right)\left(-3,-2\right)\left(4,6,7\right)\left(-7,-6,-4\right)\left(5\right)\left(-5\right)\left(8\right)\left(-8\right)\] Because this diagram is not connected, one of \({\cal U}\) and \({\cal V}\) must connect the two cycles of \(\tau_{3,5}\). We consider the term where the unique nontrivial block of \({\cal U}\) contains the two lighter grey cycles of \(\pi\): \[{\cal U}=\left\{\left\{1\right\},\left\{2,3,4,6,7\right\},\left\{5\right\},\left\{8\right\}\right\}\] while \({\cal V}=\Pi\left(\mathrm{Kr}_{\tau_{3,5}}\left(\pi\right)\right)\). The cumulant of traces is \begin{multline*} k_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{8}\right)\\=\mathbb{E}\left(\mathrm{tr}\left(X_{1}\right)\right)\mathrm{cov}\left(\mathrm{tr}\left(X_{2}X_{3}\right),\mathrm{tr}\left(X_{4}X_{6}X_{7}\right)\right)\mathbb{E}\left(\mathrm{tr}\left(X_{5}\right)\right)\mathbb{E}\left(\mathrm{tr}\left(X_{8}\right)\right)\\=\varphi_{1}\left(x_{1}\right)\varphi_{2}\left(x_{2}x_{3},x_{4}x_{6}x_{7}\right)\varphi_{1}\left(x_{5}\right)\varphi_{1}\left(x_{8}\right)\\=\alpha_{1}\left(x_{1}\right)\alpha_{2,3}\left(x_{2},x_{3},x_{4},x_{6},x_{7}\right)\alpha_{1}\left(x_{5}\right)\alpha_{1}\left(x_{8}\right)=\alpha_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{8}\right) \end{multline*} and the limit of the Weingarten function is \(-1\), so the limit of the term is \[-\alpha_{1}\left(x_{1}\right)\alpha_{2,3}\left(x_{2},x_{3},x_{4},x_{6},x_{7}\right)\alpha_{1}\left(x_{5}\right)\alpha_{1}\left(x_{8}\right)=-\alpha_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{8}\right)\textrm{.}\] \end{example} \begin{figure} \label{figure: cumulant moment} \centering \begin{tabular}{cc} \input{cumulant-moment-Weingarten.pdf_t}\\ \input{cumulant-moment-annular.pdf_t}\\ \input{cumulant-moment-annular-reversed.pdf_t}\\ \input{cumulant-moment-cumulant.pdf_t} \end{tabular} \caption{Examples of the four types of diagrams contributing to the highest order of the two-vertex cumulant \(K_{3,5}\left(X_{1},\ldots,X_{8}\right)\).} \end{figure} The spoke diagram characterization of second-order freeness (Definition~\ref{definition: second-order freeness}) may be recovered from Proposition~\ref{proposition: two-vertex limit} and Lemma~\ref{lemma: singlets} and the observations that, if \(\alpha_{p,q}\) is applied to centred, cyclically alternating terms, any summand with where a block of \({\cal U}\) contains adjacent matrices will have a mixed cumulant and therefore vanish, and any summand where a block of \({\cal U}\) contains a single element \(x\) will have a term \(\alpha_{1}\left(x\right)=0\). We show an example of the types of terms which appear in the asymptotic expansion of a second-order moment in cumulants: \begin{example} \label{example: moment cumulant} We consider random matrices \(X_{1},\ldots,X_{7}:\Omega\rightarrow M_{N\times N}\left(\mathbb{C}\right)\) with a second-order limit distribution \(x_{1},\ldots,x_{7}\in A\). We consider the rescaled large \(N\) limit of the covariance of traces: \begin{multline*} \lim_{N\rightarrow\infty}N^{2}k_{2}\left(\mathrm{tr}\left(X_{1}X_{2}X_{3}X_{4}\right),\mathrm{tr}\left(X_{5}X_{6}X_{7}\right)\right)=\alpha_{4,3}\left(x_{1},x_{2},x_{3},x_{4};x_{5},x_{6},x_{7}\right)\\=\varphi_{2}\left(x_{1}x_{2}x_{3}x_{4},x_{5}x_{6}x_{7}\right)\textrm{.} \end{multline*} The terms in the expansion (\ref{formula: moment vertex-cumulant}) which survive as \(N\rightarrow\infty\) fall into three categories, corresponding to the three sums in (\ref{formula: moment cumulant}), represented by the three examples shown in Figure~\ref{figure: moment cumulant}. The first diagram is a representative of the diagrams which are noncrossing on \(\tau_{p,q}=\left(1,2,3,4\right)\left(5,6,7\right)\). It corresponds to \[\pi=\left(1,6,5,3\right)\left(-3,-5,-6,-1\right)\left(2\right)\left(-2\right)\left(4,7\right)\left(-7,-4\right)\] and \({\cal U}=\Pi\left(\pi\right)=\left\{\left\{1,3,5,6\right\},\left\{2\right\},\left\{4,7\right\}\right\}\). The permutation corresponds to term \[K_{\left({\cal U},\pi\right)}=K_{4}\left(X_{1},X_{6},X_{5},X_{3}\right)K_{1}\left(X_{2}\right)K_{2}\left(X_{4},X_{7}\right)\textrm{.}\] This \(\pi\) corresponds to \(\pi^{\prime}=\left(1,3,5,6\right)\left(2\right)\left(4,7\right)\in S_{\mathrm{nc}}\left(\tau\right)\). The \(N\rightarrow\infty\) limit is \[\kappa_{4}\left(x_{1},x_{3},x_{5},x_{6}\right)\kappa_{1}\left(x_{2}\right)\kappa_{2}\left(x_{4},x_{7}\right)\\=\kappa_{\pi^{\prime}}\left(x_{1},\ldots,x_{7}\right)\] a term in the free cumulant expansion of \(\alpha_{4,3}\left(x_{1},\ldots,x_{7}\right)\). The second diagram is a representative of the third category of \(\pi\in S_{\mathrm{nc}}\left(p,q\right)\) in Lemma~\ref{lemma: annular premaps}. Again, \({\cal U}=\Pi\left(\pi\right)\). Here, \[\pi=\left(1,3\right)\left(-3,-1\right)\left(2\right)\left(-2\right)\left(4,-5,-6\right)\left(6,5,-4\right)\left(7\right)\left(-7\right)\] and \(\pi^{\prime}=\left(1,3\right)\left(2\right)\left(4,6,7\right)\left(5\right)\). The permutation corresponds to term \[K_{\left({\cal U},\pi\right)}=K_{2}\left(X_{1},X_{3}\right)K_{1}\left(X_{2}\right)K_{3}\left(X_{4},X_{5}^{T},X_{6}^{T}\right)K_{1}\left(X_{7}\right)\] with limit \[\kappa_{2}\left(x_{1},x_{3}\right)\kappa_{1}\left(x_{2}\right)\kappa_{3}\left(x_{4},x_{6}^{t},x_{5}^{t}\right)\kappa_{1}\left(x_{7}\right)=\kappa_{\pi^{\prime}}\left(x_{1},x_{2},x_{3},x_{4},x_{7}^{t},x_{6}^{t},x_{5}^{t}\right)\textrm{.}\] The third term corresponds to \(\left({\cal U},\pi\right)\) with \({\cal U}=\left\{\left\{1\right\},\left\{2,4\right\},\left\{3,5,6\right\},\left\{7\right\}\right\}\) and \(\pi=\left(1\right)\left(-1\right)\left(2,4\right)\left(-4,-2\right)\left(3\right)\left(-3\right)\left(5,6\right)\left(-6,-5\right)\left(7\right)\left(-7\right)\). This corresponds to term \[N^{2}K_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{7}\right)=N^{2}K_{1}\left(X_{1}\right)K_{2}\left(X_{2},X_{4}\right)K_{1,2}\left(X_{3},X_{5},X_{6}\right)K_{1}\left(X_{7}\right)\] which has \(N\rightarrow\infty\) limit \[\kappa_{1}\left(x_{1}\right)\kappa_{2}\left(x_{2},x_{4}\right)\kappa_{1,2}\left(x_{3},x_{5},x_{6}\right)\kappa_{1}\left(x_{7}\right)=\kappa_{\left({\cal U},\pi^{\prime}\right)}\left(x_{1},\ldots,x_{7}\right)\textrm{.}\] \end{example} \begin{figure} \label{figure: moment cumulant} \centering \begin{tabular}{cc} \input{moment-cumulant-annular.pdf_t}\\ \input{moment-cumulant-annular-reversed.pdf_t}\\ \input{moment-cumulant-cumulant.pdf_t} \end{tabular} \caption{Examples of the three types of highest-order diagrams contributing to the cumulant \(k_{2}\left(\mathrm{tr}\left(X_{1}X_{2}X_{3}X_{4}\right),\mathrm{tr}\left(X_{5}X_{6}X_{7}\right)\right)\).} \end{figure} \subsection{Higher-order freeness} \label{subsection: higher-order} \begin{proposition} Let \(A\) be an \(m\)th order noncommutative probability space with subalgebras \(A_{1},\ldots,A_{C}\) closed under transposition. Assume that the cumulants as defined in Proposition~\ref{proposition: higher free cumulants} which are mixed (i.e.\ are applied to elements from more than one of the algebras) vanish. Let \(m>2\), let \(r_{1},\ldots,r_{m}>0\), and let \(n:=r_{1}+\cdots+r_{m}\). Let \(x_{1},\ldots,x_{n}\) belong to algebras \(A_{1},\ldots,A_{C}\subseteq A\) such that \(x_{\tau_{r_{1},\ldots,r_{m}}}\left(k\right)\) is always from a different algebra from \(x_{k}\) (i.e.\ the \(x_{k}\) are cyclically alternating under \(\tau_{r_{1},\ldots,r_{m}}\)). Then the value of \(\varphi_{m}\) applied to cyclically alternating products of centred terms can be calculated from the expansion in Proposition~\ref{proposition: limit cumulant}, excluding any terms in which \({\cal U}\) contains two terms adjacent in \(\tau\) or any singlet: \[\alpha_{r_{1},\ldots,r_{m}}\left(x_{1},\ldots,x_{n}\right)=\sum_{\substack{\left({\cal U},\pi\right)\in{\cal PPM}^{\prime}\left(r_{1},\ldots,r_{m}\right)\\\left.\pi\right|_{\left\{k,\tau\left(k\right)\right\}}=\left(k\right)\left(\tau\left(k\right)\right),k\in\left[n\right]\\\left\{k\right\}\neq{\cal U},k\in\left[n\right]}}\kappa_{\left({\cal U},\pi\right)}\left(x_{1},\ldots,x_{n}\right)\textrm{.}\] \end{proposition} \begin{proof} This follows immediately from the hypotheses. \end{proof} The characterization of the surviving diagrams is more complicated than in the second-order case. Some examples of possible diagrams in the third-order case are shown in Figure~\ref{figure: third-order}. Such diagrams may have \(0\), \(1\), or \(2\) cycles of three elements (in Figure~\ref{figure: third-order}, first two diagrams, third diagram, and fourth diagram, respectively), while all other cycles must have exactly \(2\) elements. If all cycles have \(2\) elements, and there are two cycles of \(\gamma\) not connected directly by cycles of \(\pi\), then it is possible that the outside faces (in the sense of Lemma~\ref{lemma: technical}) of those cycles of \(\gamma\) are not the same cycles of \(\mathrm{Kr}_{\tau}\left(\pi\right)\) (as shown in the second diagram in Figure~\ref{figure: third-order}). \begin{figure} \label{figure: third-order} \centering \begin{tabular}{cc} \input{third_order_doublets.pdf_t}\\ \input{third_order_separate.pdf_t}\\ \input{third_order_1_triplet.pdf_t}\\ \input{third_order_2_triplets.pdf_t} \end{tabular} \caption{Four examples of diagrams appearing in the third-order free expansion.} \end{figure} The diagrams in Figure~\ref{figure: third-order} correspond, respectively, to terms: \[\kappa_{2}\left(x_{1},x_{7}^{t}\right)\kappa_{2}\left(x_{2},x_{9}\right)\kappa_{2}\left(x_{3},x_{6}^{t}\right)\kappa_{2}\left(x_{4}^{t},x_{11}\right)\kappa_{2}\left(x_{5}^{t},x_{12}\right)\kappa_{2}\left(x_{8}^{t}\right)\] \[\kappa_{2}\left(x_{1},x_{4}\right)\kappa_{2}\left(x_{2},x_{5}\right)\kappa_{2}\left(x_{3},x_{6}\right)\kappa_{2}\left(x_{7},x_{8}\right)\] \[\kappa_{3}\left(x_{1},x_{10}^{t},x_{6}^{t}\right)\kappa_{2}\left(x_{2},x_{11}^{t}\right)\kappa_{2}\left(x_{3},x_{5}^{t}\right)\kappa_{2}\left(x_{4}^{t},x_{8}^{t}\right)\kappa_{2}\left(x_{7}^{t},x_{9}^{t}\right)\] \[\kappa_{2}\left(x_{1},x_{6}\right)\kappa_{3}\left(x_{2},x_{10}^{t},x_{5}\right)\kappa_{2}\left(x_{3},x_{8}^{t}\right)\kappa_{3}\left(x_{4},x_{7},x_{8}^{t}\right)\textrm{.}\] Higher-order diagrams are more complicated to characterize. In fourth-order diagrams, the permutation need not be connected (consider a pair of spoke diagrams in which the partition connects a spoke from each diagram). In fifth-order diagrams, it is possible for the permutation to have single-element cycles (consider a pair of spoke diagrams along with a noncrossing diagram on a single cycle whose two single-element cycles are connected by the partition to spokes in the two spoke diagrams). \section{The quaternionic case} \label{section: quaternion} We give here the definitions of quaternionic matrix cumulants and quaternionic vertex cumulants. Definitions of quaternionic second-order probability spaces and quaternionic second-order freeness can be found in \cite{2015arXiv150404612R}. More details on the definition of quaternionic matrix cumulants and their use in computing random matrix quantities can be found in \cite{MR2337139, MR3455672}. The analogous results for those given for the real case hold for the quaternionic case with appropriate changes. \begin{definition} The quaternionic Weingarten function \(\mathrm{Wg}^{\mathrm{Sp}\left(N\right)}\) and its cumulants are defined in \cite{MR2217291}. More detail on the quaternionic case and the normalized quaternionic Weingarten function \(\mathrm{wg}^{\mathrm{Sp}\left(N\right)}\), are given in \cite{MR3455672}. For large \(N\), the cumulant of the Weingarten function is \[\mathrm{wg}_{{\cal U},{\cal V}}^{\mathrm{Sp}\left(N\right)}=\gamma^{\mathrm{Sp}\left(N\right)}_{{\cal U},{\cal V}}N^{-2\left(\#\left({\cal U}\right)-\#\left({\cal V}\right)\right)}+O\left(N^{1-\#\left({\cal U}\right)}\right)\] where \begin{multline*} \gamma^{\mathrm{Sp}\left(N\right)}_{{\cal U},{\cal V}}\\:=\prod_{V\in{\cal V}}\left(-1\right)^{\left|V\right|-\#\left(\left.{\cal U}\right|_{V}\right)}\frac{2\left(2\left|V\right|+\#\left(\left.{\cal U}\right|_{V}\right)-3\right)!}{\left(2\left|V\right|\right)!}\prod_{U\in\left.{\cal U}\right|_{V}}\frac{\left(2\left|U\right|-1\right)!}{\left(\left|U\right|-1\right)!^{2}}\textrm{.} \end{multline*} \end{definition} \begin{definition} The quaternionic matrix cumulants are given by: \begin{multline*} c^{\mathbb{H}}_{\rho}\left(X_{1},\ldots,X_{n}\right)\\:=\sum_{\pi\in\mathrm{PM}\left(n\right)}\left(2N\right)^{\chi_{\rho}\left(\pi\right)-2\#\left(\Pi\left(\rho\right)\right)}\mathrm{wg}^{\mathbb{H}}\left(\Pi\left(\mathrm{Kr}_{\rho}\left(\pi\right)\right)\right)\mathbb{E}\left(\left(\mathrm{Re}\circ\mathrm{tr}\right)_{\pi}\left(X_{1},\ldots,X_{n}\right)\right)\textrm{.} \end{multline*} The quaternionic vertex cumulants are given by \[c^{\mathbb{H}}_{\pi}\left(X_{1},\ldots,X_{n}\right)=:\sum_{\substack{{\cal U}\in{\cal P}\left(n\right)\\{\cal U}\succeq\Pi\left(\pi\right)}}K^{\mathbb{H}}_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\] or equivalently \[K^{\mathbb{H}}_{\left({\cal U},\pi\right)}\left(X_{1},\ldots,X_{n}\right)=\sum_{\substack{{\cal V}\in{\cal P}\left(n\right)\\{\cal V}\succeq\Pi\left(\pi\right)}}\mu_{{\cal P}}\left({\cal V},1\right)c_{\left({\cal V},\pi\right)}\left(X_{1},\ldots,X_{n}\right)\textrm{.}\] \end{definition}
\section{Introduction} Coronal mass ejections (CMEs) are the most energetic phemonena in the Solar System, involving around $10^{32}$ ergs of energy in the form of electromagnetic, kinetic, thermal, non-thermal and gravitational potential energy. The energy is ultimately derived from the coronal magnetic field, where it is stored in the form of electric currents \citep{Forbes-2000}. However, the exact evolution of the coronal magnetic field, and the physical processes involved in CMEs, are still subjects of study. CMEs are also of interest because they can drive intense geomagnetic storms \citep{Gosling-1993}. These storms are able to create hazardous space weather conditions at Earth, leading to disruptions of our technological systems, and significant socioeconomic impact \citep[for a review see][]{Eastwood-2017}. Understanding the conditions in which CMEs are created is therefore of importance for a physical understanding of our Sun, as well as for space weather forecasting. The occurrence of CMEs involves an energy storage-and-release process and their formation is often discussed as having two phases; a trigger and a driver. The trigger refers to the physical process(es) that brings the magnetic field to the point of an eruption, whereas the driver is responsible for the sudden expansion and upward acceleration of the erupting volume. The driving mechanism appears to be limited to either magnetic reconnection taking place in a vertical current sheet below the eruptive structure \citep{Moore-2001} or the Lorentz force acting on a flux rope \citep{Forbes-1991,Torok-2005,Kliem-2006,Mackay-2006a,Mackay-2006b,Kliem-2014}. Possible trigger mechanisms, however, appear to be wide-ranging and include, for example, sunspot rotation, flux emergence and photospheric flows. See \cite{Green-2017} for an overview of CME trigger and driver processes. Our efforts to understand (and forecast) CMEs are severely impeded by a lack of knowledge of the relative importance of these trigger mechanisms. In this study we focus on another particular CME trigger known as flux cancellation. In the flux cancellation process small-scale opposite polarity magnetic fragments are seen to converge, collide and disappear along the polarity inversion line (PIL) that separates regions of positive and negative field in the photosphere \citep{Martin-1985}. The disappearance of the two opposite polarity fragments is ultimately the consequence of the fragmentation and dispersion of the magnetic field caused by convective flows and differential rotation. Three scenarios have been proposed to explain the process of flux cancellation (see \cite{Zwaan-1987}): the emergence of a U-loop \citep{vDG-2000,Bernasconi-2002}, the submergence of an $\Omega$-loop below the surface \citep{Harvey-1999,Chae-2004,Yang-2009}, or the result of magnetic reconnection taking place at a low height \citep{vB-1989}. We investigate the third case where flux cancellation due to low-altitude magnetic reconnection is able to gradually transform a sheared arcade field into a flux rope. In this scenario, magnetic reconnection produces two loops: 1) a small loop with a high curvature, which submerges below the photosphere leading to the disappearance of the small bipole; 2) a loop much larger in size-scale that extends into the corona. Ongoing flux cancellation can therefore form a flux rope that is expected to have its underside located in the high plasma-$\beta$ environment of the lower solar atmosphere. During the flux cancellation process an amount of flux equal to that which is cancelled is available to be built into the flux rope. The actual amount of flux that is built into a flux rope depends on the properties of the region, such as the amount of shear and the length of the PIL along which flux cancellation is occurring. The details of this process are discussed in \cite{Green-2011}. The flux cancellation process also has a secondary effect in that it reduces the flux in the region that contributes to the field overlying, and stabilising, the flux rope. If enough flux is transformed from the overlying arcade into the flux rope, a force imbalance can occur leading to a catastrophic loss of equilibrium and a CME \citep{Lin-2000, Bobra-2008}. Or, if the active region evolves to a point where the overlying field decreases rapidly enough with height, the flux rope can become torus unstable \citep{Kliem-2006}. In this way, flux cancellation can be viewed as a CME trigger mechanism, which in itself requires a converging flow, in a sheared field, to bring opposite polarity fragments together. Such a scenario for flux rope formation and eruption due to flux cancellation is well supported by simulations \citep{Amari-2003, Aulanier-2010} and observations \citep{Green-2011, Yardley-2016}. Here we present the first comprehensive study of the eruptive activity in a representative sample of 20 small bipolar active regions (ARs) in order to probe the role of flux cancellation as a CME trigger. We study the evolution of the photospheric magnetic field to quantify the significance of flux cancellation in building an eruptive magnetic field environment. We investigate at what point in an active region's lifetime eruptions occur. \section{Data \& Methods} \subsection{Active Region Selection} In this study, we focus on eruptions that are produced in bipolar active regions. Bipolar active regions are selected for study due to their low magnetic complexity, which minimizes the number of polarity inversion lines (PILs) along which eruptions might originate. Active regions were selected using the following criteria. The regions must have two dominant magnetic polarities with no major mixing of the opposite polarities. The active regions must be isolated from other active regions so that flux cancellation occurring along any external PILs is negligible allowing flux cancellation along the internal PIL to be quantified. They must be short-lived regions and form east of central meridian so that their evolution can be tracked across the disk. Finally, the active regions must emerge within 60$^{\circ}$ of central meridian due to the decreasing reliability of the magnetic flux measurements with increasing distance from disk centre. The above criteria led to the selection of 20 active regions from the HMI era, spanning a time period from March 2012 to November 2015. It should be noted that the above criteria necessarily lead to the selection of small active regions, with magnetic flux $\sim 10^{20}$--10$^{21}$~Mx. Eruptions from these regions may produce relatively subtle signatures in extreme ultraviolet data and no observable coronal mass ejection in white light coronagraph data. Due to this, we do not use the term coronal mass ejection (CME) in this work. Rather we refer to eruptions that are identified in extreme ultraviolet data. These eruptions may be successful or may not be fully ejected from the Sun, leading to a failed eruption. With such weak events it can be hard to discriminate these two categories but since we are interested in the role of flux cancellation as a CME trigger, we do not focus on whether each event is failed or fully ejective only whether it was initiated in the first place. \subsection{Coronal evolution and eruptive activity} \begin{figure*}[ht] \centering \includegraphics[width=\linewidth]{fig1.pdf} \caption{Examples of the three eruption categories: low-altitude external PIL, low-altitude internal PIL and high-altitude events. The top row shows {\it SDO}/AIA 171~\AA\ images that have been overlaid with contours the line-of-sight magnetic field from SDO/HMI (shown at a saturation of $\pm$~100~G). The red (blue) contours correspond to positive (negative) magnetic flux, respectively. The coronal signatures observed in each example have been labelled in white along with the NOAA AR number and time of image. The bottom row shows difference images that have been made using the times given in each image. The location of coronal dimmings associated with each eruption are indicated by yellow arrows. An animation of the images in the bottom row is available. From left to right the sequences start at 2012-03-17 10:35:36 UT, 2012-03-20 14:30:36 UT, and 2012-03-24 00:30:36 UT. The sequences end at 2012-03-17 11:30:36 UT, 2012-03-20 15:25:36 UT, and 2012-03-24 01:25:36 UT, respectively. The video duration is 2 seconds.} \label{fig:fig1} \end{figure*} The coronal evolution of each active region is monitored using extreme ultraviolet (EUV) images produced by the Atmospheric Imaging Assembly (AIA; \citealt{Lemen-2012}) instrument on board the {\it Solar Dynamics Observatory (SDO; \citealt{Pesnell-2012})}. The AIA instrument provides full-disk observations with a high spatial resolution and temporal cadence of 1.5" and 12~s, respectively, for three UV--visible and seven EUV bandpasses. In this study we focus on using 171~\AA\ and 193~\AA\ to analyse the coronal evolution of each active region. The 171~\AA\ passband is dominated by plasma emission at a temperature of around 0.6~MK whereas, the temperature response of the 193~\AA\ has two temperature peaks at approximately 1.2 and 20~MK. Each active region is analysed in order to identify the time and location of eruptions that are produced. Coronal signatures used to indicate the occurrence of an eruption include at least two of the following: the eruption of a filament or EUV loop system, the rapid disappearance of coronal loops and the formation of a post-eruption arcade (flare arcade), flare ribbons and coronal dimmings. Each eruption is then placed into one of three categories; the aim being to identify which eruptive structures form at a low-altitude, and can therefore be studied in the context of flux cancellation taking place in the active region, and which are formed by other processes and/or altitudes. The three categories are given the names: internal PIL events (for the eruption of a low-altitude structure from along the active region's internal PIL); external PIL events (for the eruption of a low-altitude structure along a PIL at the periphery of the active region), high-altitude events (for the eruption of a structure from a high-altitude in the corona and presumably not associated with flux cancellation during the time period studied). One or more of the following criteria must be met for an eruption to be classified as an internal or external PIL (low-altitude) event: \begin{itemize} \item The low-lying core field of the active region must be opened and reconfigured as new post-eruption (flare) loops form. \item Any flare ribbons that form must, in the first instance, be immediately next to and run along the PIL. \item Any dimming regions that form must, in the first instance, be immediately next to the PIL. \end{itemize} One or more of the following criteria must be met for an eruption to be classified as a high-altitude event: \begin{itemize} \item The low-lying core field of the active region must not be involved or modified. \item Any flare ribbons that form must be well separated from the PIL. \item Any post-eruption (flare) loops that form must be located above the active region core field. \item Any dimming regions that form must, in the first instance, be remote from the PIL. \end{itemize} One example from each eruption category is shown in Figure~\ref{fig:fig1} and online in Supplementary Movie 1. \subsection{Magnetic Flux Evolution} \label{sec:mfe} The photospheric field evolution of each active region is analysed using magnetograms obtained by the Helioseismic and Magnetic Imager (HMI; \citealt{Schou-2012}) on board {\it SDO}. The magnetograms used in this study provide information on the line-of-sight component of the magnetic field and are from the 720~s series (hmi.M\_720s) recorded by the vector camera. This camera has a pixel size of 0.5" and a noise level of 10~G. The magnetic flux evolution of each active region was calculated by implementing the Solar Tracking of the Evolution of Photospheric Flux (STEF) algorithm \citep{Yardley-2016} on the line-of-sight magnetograms. The cadence of the magnetograms used is 96 minutes. Active regions are manually identified in the full-disk magnetograms and a field of view is assigned as a rectangular box centered on the active region. The radial component of the magnetic field $B_{R}$ is estimated for each pixel in the series of full-disk magnetograms by applying a cosine correction to the longitudinal magnetic field $B_{LOS}$ using Heliocentric Earth Equatorial Coordinates (HEEQ): \begin{equation} B_{R} = \frac{B_{LOS}}{\cos{\theta} \cos{\phi}}, \end{equation} where $\theta$ and $\phi$ are the helioprojective westward and northward angles, respectively. These angles can be expressed in terms of heliocentric westward and northward coordinates x, y \begin{eqnarray} \theta & = & \arcsin{\frac{x}{R \cos{\phi}}}, \\ \phi & = & \arcsin{\frac{y}{R}}, \end{eqnarray} where $R$ is the radius of the Sun with respect to the observer. The magnetogram containing the radialised field values is then de-rotated to the central meridian passage time of the active region to correct for projection effects using a routine that has been developed in SunPy \citep{SunPy-2015}. The flux-weighted central coordinates of the selected field of view are calculated for each time step making it possible to track the active region such that it always remains in the field of view. The pixels that make up the active region are then selected as follows. First a Gaussian filter is applied to smooth the data with a standard deviation (width) of 7 pixel units. The weighted average of the magnetic flux density of the neighbouring pixels must exceed a threshold of 40 G. This threshold is set manually and has been tested to give the best results. The largest regions of magnetic flux that form at least 60\% of the selected pixels are identified and retained whereas, the smaller features at large distances are disregarded. This is to ensure that quiet sun magnetic features that are not part of the AR are removed. It is still possible that small-scale magnetic features can enter or exit the boundary, introducing a contribution to or reduction of the magnetic flux measurement. These fluctuations are usually small and an error on the flux measurement is estimated by measuring the magnetic flux of small flux fragments that move into or out of the active region area. This error estimation varies in time as the active region evolves. If the automatic detection fails to successfully select the active region flux at any time step a function is used that allows the user to manually select contours of magnetic flux for the flux calculation. Finally, a dilation is applied so that pixels within approximately 5" of those selected are also included within the active region area selection. Figure~\ref{fig:fig2} shows the line of sight photospheric magnetic field evolution of AR 11437 and the active region area (shown by the yellow contour) identified by the STEF algorithm. Magnetic flux is measured in this area. The emergence of small bipoles in or close to an active region, or quiet sun fragments that cancel with flux at the periphery of the active region, can affect the measurement of magnetic flux. In these cases it is not possible to accurately identify and measure the flux cancellation at the internal PIL. To take this into account, if possible, the flux cancellation is not calculated during time periods when external flux cancellation or flux emergence is occurring. \subsection{Separation Distance of AR Polarities} To determine whether there is an overall convergence of the two polarities of the bipole, the separation of the positive and negative polarities is calculated. The separation distance is quantified by computing the separation of the flux-weighted central coordinates of the positive and negative bipoles. The flux-weighted central coordinates $f$ are computed as follows \begin{equation} f = \frac{\sum_{i}B_{i}x_{i}}{\sum_{i} B_{i}}, \end{equation} where $B_{i}$ and $x_{i}$ are the magnetic flux density and coordinate corresponding to pixel ${i}$ of the active region. The flux-weighted central coordinates are computed in both $x$ and $y$. The separation distance $d$ of the polarities is then calculated by \begin{equation} d = \sqrt{(x_{1}-x_{2})^{2} + (y_{1} - y_{2})^{2}}, \end{equation} where ($x_{1}$,$y_{1}$) and ($x_{2}$,$y_{2}$) are the flux-weighted central coordinates of the positive and negative polarities, respectively. \begin{figure*}[ht] \centering \includegraphics[width=\linewidth]{fig2.pdf} \caption{Evolution of the line-of-sight magnetic field of NOAA AR 11437 observed using \textit{SDO}/HMI magnetograms. The magnetic field directed towards (away from) the observer is shown in white (black). The active region shows a typical evolution whereby the polarities emerge and separate. The magnetic flux then disperses over time due to the action of photospheric flows and is reprocessed by granular and supergranular convection \citep{Dacie-2016}. The yellow contour represents the region in which the positive, negative and unsigned flux is calculated. The red (blue) points represent the positive (negative) flux-weighted central coordinates. } \label{fig:fig2} \end{figure*} \section{Results} \subsection{Active Region Eruptions} Of the 20 active regions studied, 13 produced at least one eruption. These 13 active regions produced a total of 24 eruptions during the time period studied. Eight out of these 13 active regions produced low-altitude events that originated from either the internal or external PIL of the active region. The remaining five of these 13 active regions produced high-altitude events. Table~\ref{tab:table1} gives the timings of the different types of event as determined by the eruption and rapid disappearance of EUV coronal loops and also the coronal signatures observed during eruption. The majority of the eruptions (22/24) that occurred exhibited coronal dimmings, which suggests that these events may have been successful CMEs. However, two of the eruptions are not associated with coronal dimmings and are therefore assumed to be confined or failed eruptions. It is notable that, during the time period studied, the active regions that produced eruptions produced \textit{either} internal and/or external PIL events (which originate at a low-altitude) \textit{or} high-altitude events. No active regions produced both low-altitude and high-altitude eruptions. Overall, eruptions occurred in both the emergence and decay phases of the active regions, however the category of event produced depended on the region's evolutionary stage. Table~\ref{tab:CME_AR_phase} and Figure~\ref{fig:fig3} show that there is a tendency for external PIL events to occur during an active region's emergence phase and for internal PIL events to form during the decay phase. In contrast to this, the eruption of a high-altitude structure occurs roughly evenly across the emergence and decay phases. The high-altitude events make up only 38\% of the eruptions originating in the active regions. \subsection{Flux Cancellation} \label{sec:canc_res} The flux cancellation rate and total flux cancelled in each active region is determined from the reduction in the total unsigned magnetic flux with time (see Figure~\ref{fig:fig4} (a)). That is, during the decay phase of each active region. Therefore, the results presented here only refer to the decay phase of the active regions. Flux cancellation, at either an internal or external PIL, was observed to occur in all but one active region (AR 11867). Table \ref{tab:table3} summarises the flux cancellation rates (column 7) and total amount cancelled (column 8). The average flux cancellation rate for all 20 active regions (including AR 11867 that exhibited no cancellation) is 0.84$\times$10$^{19}$~Mx~h$^{-1}$. This compares to an average flux cancellation rate of 0.68$\times$10$^{19}$~Mx~h$^{-1}$ for regions that produce internal and external PIL events, 1.10$\times$10$^{19}$~Mx~h$^{-1}$ for regions that produce high-altitude events, and 0.83$\times$10$^{19}$~Mx~h$^{-1}$ for regions that produce no eruptions at all. Therefore, active regions that do not produce eruptions have a flux cancellation rate close to the average value across all regions, internal and external PIL event active regions have a flux cancellation rate less than average, and high-altitude event active regions have a flux cancellation rate above the average value. Although flux cancellation can play an important role in the creation of a sheared or twisted pre-eruptive structure \citep{vB-1989}, what is important for the occurrence of an eruption is the force balance between this structure and the overlying arcade field. To investigate this, the {\it total} amount of flux cancelled must be considered, as this quantity represents the amount of flux that could have been built into a flux rope. This value can then be compared to the amount of flux that remains in the active region as field overlying the rope. Therefore, we now pay particular attention to the four active regions that produce eruptions from their internal PIL, in order to probe how much flux may have been built into the pre-eruptive structure in relation to that remaining as active region arcade field. We compare these active regions to those that produce high-altitude eruptions. These two groups exhibit a similar amount of total flux cancelled at the internal PIL over the time period studied, despite their differing flux cancellation rates. They therefore provide an interesting dataset to compare and contrast regions where flux cancellation apparently acts as an eruption trigger (through the creation and eruption of a low-altitude structure) and a group of regions where it does not. The flux cancellation measurements for the internal PIL event regions and high-altitude event regions are shown in Table~\ref{tab:flux_canc}. The average total flux cancelled for the internal PIL event regions and for high-altitude event regions is 4.8$\times$10$^{20}$~Mx and 5.3$\times$10$^{20}$~Mx, respectively. The total amount of flux cancelled as a quantity and a percentage of the active region's peak flux value can be seen in the third and fourth columns of Table~\ref{tab:flux_canc}. The percentage values range from 28\% to 49\% for the low-altitude internal PIL events, which is higher than the average value of 24\% of high-altitude event active regions. Now we compare the amount of total flux cancelled (available to be built into the flux rope) to that left in the active region as field overlying (and stabilising) magnetic field for internal PIL eruptions and high-altitude eruptions. For AR 11561, a corrected flux cancellation value was used to account for the fact that the flux cancellation measurement could not be made during the entire time that cancellation was observed to occur. This is due to the emergence of a bipole to the south of the active region, which cannot be removed from the magnetic flux measurement and therefore masks the flux cancellation taking place at the internal PIL. We find that the ratio of flux cancelled compared to that which remains as overlying field for active regions that produce internal PIL events (at the time of eruption) lies between 1:0.03 and 1:1.57 (see column 5 of Table~\ref{tab:flux_canc}). Here we note that the ratio of 1:0.03 for AR 11437 suggests that practically no overlying field remains, indicating that the assumption that flux cancellation injects an equal amount of flux into the rope may not apply. This compares to ratios between 1:0.94 and 1:3.42 for regions that produce high-altitude eruptions. Therefore, on average, high-altitude event regions had a relatively high value of flux overlying the PIL along which flux cancellation was occurring. \subsection{Configuration and Motion of Active Region Polarities} The orientation of the bipole with respect to the polarity inversion line provides information on the level of non-potentiality (or shear) of the magnetic field. A sheared field is an essential component of the flux rope formation model that is relevant to this study \citep{vB-1989}. We use the observational proxy of sheared loops to determine the non-potentiality of the magnetic field of the bipole. The shear angle was measured for each active region at the time of peak magnetic flux (see column 11 of Table \ref{tab:table3}). The magnetic shear angle is defined as the angle between the normal to the line that connects the flux-weighted central coordinates and the PIL, where the clockwise direction corresponds to a positive shear angle. Nineteen out of the 20 active regions studied showed flux cancellation and the amount of shear in these 19 regions ranges from 1$^{\circ}$ to 40$^{\circ}$. We found that, on average, the shear angle of the active regions that produced internal PIL events is significantly higher than the regions that produced high-altitude events. On average, the shear angle for regions that produced internal PIL events and those that produced high-altitude events was found to be 28$^{\circ}$ and 14$^{\circ}$, respectively. Motion toward the polarity inversion line is also an essential component of the model of \citet{vB-1989} as small fragments of the bipole's magnetic field, which break away from the main concentrations, converge, collide and cancel. In addition, an overall convergence of the polarities leads to an inflation of the field which may in turn affect the stability of any flux rope that has formed. Therefore, bipole convergence may also be investigated as a stability proxy. The separation of the active region polarities over time was calculated using the flux weighted central coordinates of the negative and positive flux regions (see Figure~\ref{fig:fig4} (b)). Overall, 75\% of the active regions that produce internal PIL events showed a combination of bipole convergence, shear and flux cancellation. This is much higher than the sub-set of active regions that do not produce internal PIL events (34\%). This sub-set includes regions that produce no eruptions, external PIL eruptions and high-altitude eruptions. \begin{figure*}[ht] \epsscale{1.1} \centering \includegraphics[width=\linewidth]{fig3.pdf} \caption{Normalised magnetic flux evolution as a function of time for the active regions that produce internal and/or external PIL eruptions. The magnetic flux value and time have been normalised with respect to the peak flux of each active region. The red dashed and blue dot-dashed lines represent the timings of the internal and external PIL eruptions, respectively.} \label{fig:fig3} \epsscale{1} \end{figure*} \begin{figure*}[ht] \centering \includegraphics[width=0.8\linewidth]{fig4.pdf} \caption{ (a) The evolution of magnetic flux in AR 11680. The total positive (red), negative (blue) and unsigned (black) magnetic flux is plotted with the red (blue) shaded regions indicating errors in positive (negative) flux measurements. Error calculation is described in Section \ref{sec:mfe}. The grey shaded region represents the time period over which the flux cancellation was calculated. The red dashed line indicates when the active region crosses central meridian (CM) and the green dashed line the time of an eruption originating from the active region's internal PIL at low-altitude (LC event). (b) The separation of flux-weighted central coordinates for AR 11680. The markings CM and LC E have the same meaning as in (a).} \label{fig:fig4} \end{figure*} \section{Discussion} In this study, we investigate the role of flux cancellation as an eruption trigger in a survey of 20 isolated and small bipolar active regions. Nineteen active regions exhibit flux cancellation, the amount of which was quantified from the reduction in the total unsigned magnetic flux with time. This approach is based on the assumption that flux cancellation is the only process by which active region flux is removed from the photosphere on the timescale of a few days. Other mechanisms of removing flux from an active region include the fragmentation and advection of fragments across larger and larger areas by plasma flows. However, these flux fragments are captured in our method of flux measurement. In addition, Ohmic diffusion will cause flux to diffuse through the photosphere, due to the finite electrical resistance of the plasma. This diffusion process occurs on a timescale $t_{D}$, which is given by $t_{D}=L^{2}/\eta$, where L is the length-scale and $\eta$ is the magnetic diffusivity. However, for a sunspot of length-scale 3000~km and using a value of Ohmic diffusion of $\eta=300~$m$^{2}$~s$^{-1}$ gives a large diffusion timescale of the order 1000 years. By definition, flux cancellation as determined by our method can only be calculated during an active region's decay phase, when no new significant flux is emerging into the region and the overall flux value is reducing. We also take into account that even though HMI produces high-quality data products, there are uncertainties and systematic errors present in the line-of-sight magnetic flux measurements. The selection criteria imposed when choosing active regions suitable for the study included that the regions had to emerge between $\pm$60$^{\circ}$. This was to avoid the appearance of symmetric peaks, centred around $\sim$60$^{\circ}$ with respect to central meridian due to the sensitivity of the HMI instrument being dependent upon longitude \citep{Hoeksema-2014, Couvidat-2016}. The increase in flux is caused by the increase in value by a few tens of percent of low to moderate flux densities between 250 and 750~G. However, this effect is still present before the active region reaches 60$^{\circ}$. A recent study by \cite{Falconer-2016} has used a sample of 272 large active regions to reduce the net projection error in parameters measured from deprojected {\it SDO}/HMI vector magnetograms. They remove the average projection error in an active region's total magnetic flux by assuming that the centre-to-limb curve of the average of the absolute values of magnetic flux of a large number of active regions, which is normalised to the value at central meridian for each AR, gives the average fractional projection error at each radial distance from disk centre. In this study we have not followed the method of \cite{Falconer-2016} as we have only analysed flux cancellation that occurs between $\sim \pm$45$^{\circ}$. There are also sinusoidal oscillations with periods of 12 and 24 hours in the evolution of total magnetic flux. This time-varying systematic error is mainly caused by the geosynchronous orbit of the {\textit SDO} spacecraft \citep{Hoeksema-2014}. Since we have selected isolated active regions and studied the flux cancellation that occurred during their decay phase, we are able to probe the characteristics of the active regions that produced eruptions from a low-altitude along their internal PILs and those that did not. Here we single out four active regions that produce internal PIL eruptions (ARs 11437, 11561, 11680 and 12382) and five active regions that produce only high-altitude eruptions (ARs 11446, 11808, 11881, 11886) and analyse their decay phase. In Section~\ref{sec:canc_res} we described that both groups have roughly the same amount of total flux cancelled although the active regions that produce high-altitude eruptions have, on average, a higher flux cancellation rate. These two groups of active region have a similar photospheric field evolution but markedly different outcomes in the evolution of the coronal field. These results lead to two questions. Why do active regions with a higher flux cancellation rate during their decay phase produce no eruptions from their internal PILs as the \cite{vB-1989} flux rope model might suggest? What are the distinguishing features between these two groups of active regions? These questions can be addressed by considering the ratio of cancelled flux that is available to be built into the flux rope, versus the remaining flux in the overlying arcade. When more active region flux is cancelled and built into a flux rope, there is less overlying field remaining in the active region to stabilise the structure. Previous observational flux cancellation studies have found a ratio of flux contained in the rope compared to the flux remaining in the overlying arcade of 1:0.65 \citep{Green-2011} and 1:0.9 \citep{Yardley-2016}. Whereas, studies from a modelling perspective have yielded values between 1:1.5 and 1:1.9 \citep{Bobra-2008, Savcheva-2009, Savcheva-2012}. In this case we found that the ratio of flux cancelled (i.e. the flux available to be built into the rope) compared to that in the overlying field at the time of the internal PIL event is: 1:1.29, 1:1.57, 1:0.03, 1:0.32 for ARs 11437, 11561, 11680 and 12382, respectively. We note that whilst for ARs 11437 and 11561 the ratio is very similar to previous results, for active regions 11680 and 12382 the flux contained in the overlying arcade is very small. This suggests that the assumption that flux cancellation injects an equal amount of flux into the rope as that cancelled may not fully apply here. This is due to the fact that the total flux cancelled is equal to the amount of flux that is {\it available} to be built into the flux rope, and therefore represents an upper limit on the flux that has been built into the rope. However, the actual amount that builds into the rope is dependent upon the shear of the arcade and the length of the active section of the PIL where flux cancellation is taking place \citep{Green-2011}. Both of these parameters can vary during the lifetime of an active region. An increase in the active section of the PIL and the shear of the arcade field can increase the chances of a loop being involved in a flux cancellation event at both of its ends. When this is the case, flux is cancelled without contributing to the amount of flux in the rope. AR 11680 exhibits a strong increase in the length of the active section of the PIL and AR 12382 shows a large increase in shear between the positive and negative polarities meaning that the amount of flux being built into rope may be overestimated. Active regions that produce high-altitude events have a larger proportion of flux remaining in the overlying arcade compared to regions that produce internal PIL events. AR 11881 is an outlier in terms of the ratio for the high-altitude regions as it has a value of 1:0.94, which is within the range that produce internal-PIL eruptions. However, when analysing the AIA data in the time period following the end of our flux cancellation measurement we observe an internal PIL eruption that occurs on 2013 October 31 at around 01:50~UT. This is just over a day after our flux cancellation measurements ceased because the magnetic flux evolution could no longer be followed. There were no internal PIL events observed following the end of the flux cancellation measurement for the remaining active regions that produced high-altitude eruptions. Our results also show that the average shear angle of the active regions that produce internal PIL events is, on average, higher than that of the other event categories. These results suggest that flux cancellation within a sheared arcade may build a potentially eruptive configuration but that a successful eruption depends on the removal of sufficient overlying and stabilising field. In a recent study by \citet{Sterling-2017} the evolution of a series of coronal jets that occurred at the periphery of the leading sunspot of AR 12259 were analysed. They found that seven active region jets occurred during strong flux cancellation calculating an average flux cancellation rate of 1.5 $\times$ 10$^{19}$~Mx~h$^{-1}$ with an average of $\sim$5 $\times$ 10$^{18}$~Mx cancelled prior to each episode. The flux cancellation rates for the active region jets were found to be higher than the active regions in this study. This is not that surprising considering that the photospheric evolution of the jet-productive area is on the same size-scale as the active regions and the area is followed for a period of hours rather than days. On average, the total flux cancelled in the active regions in this study was found to be 2 orders of magnitude larger than for the active region jets. In this study we have focussed on the flux cancellation scenario of \cite{vB-1989} and the role it plays in the productivity of eruptions in small and isolated bipolar ARs. This required an analysis of the relationship between flux cancellation, the evolution of the coronal magnetic field and eruption onset. We conclude that flux cancellation can be considered as a CME trigger if sufficient stabilising field is removed from above the sheared core field. Other studies have investigated which non-potentiality parameters are strong indicators that a CME will occur. For example, \citet{Bobra-2016} used features derived from {\it SDO}/HMI vector magnetograms to deduce whether active regions that produce M1 class flares or above will also produce a CME. They determined which features distinguish flaring active regions that produce CMEs from those that do not. The study found that the highest-performing features, which characterise the non-potentiality of the magnetic field, are the mean horizontal gradient of the magnetic field and the twist parameter. A study by \citet{Tiwari-2015} found that active regions with a larger non-potentiality and total magnetic flux can produce both fast and slow CMEs, whereas smaller active regions with a more potential configuration can only produce slower CMEs. One key factor that plays a key role in CME productivity is the configuration of the overlying field \citep{Torok-2005}. The gradient of the overlying field with height, for the active regions in our study, will be investigated in the future using non-linear force-free modelling. \section{Summary} In this study, we analysed a sample of 20 bipolar active regions over several days starting at the time of emergence, in order to investigate the importance of flux cancellation as a CME trigger. Following the model of \cite{vB-1989}, flux cancellation is the result of magnetic reconnection that is driven by the convergence and collision of loop footpoints in a sheared arcade. This process is able to build an eruptive structure, cut the tethers of the overlying field and hence act as a CME trigger. Flux cancellation was observed in all active regions with the exception of AR 11867, which remained in its emergence phase during the time period studied. In total, 24 eruptions were produced in 13 active regions. These eruptions were categorised into three types: low-altitude eruptions from the internal PIL (internal PIL events), low-altitude eruptions from an external PIL (external PIL events) and eruptions originating from high in the corona (high-altitude events). We found that the category of eruption produced is related to the evolutionary stage of the bipolar active region. For example, the majority of external PIL events occurred during the active region's emergence phase, when the growing bipole pushes into the surrounding, pre-existing magnetic field. This interaction can drive reconnection and flux cancellation, which may build an eruptive structure at the edge of the active region. The three external PIL events that occurred during the decay phase of their host active region appear to be related to the emergence of a small bipole close to the active region periphery. This forms an external PIL where cancellation can occur between opposite polarities. In contrast, internal PIL events only occurred during the bipole's decay phase when the bipole polarities have stopped separating and fragmented active region flux is being brought to the internal PIL via convective flows, driving reconnection and flux cancellation. High-altitude events occurred during both the emergence and decay phase of the active regions and could be the result of the destabilisation of a pre-existing structure or the formation of a high-altitude structure formed during the evolution of the active region. We do not carry out an in-depth study of this category of eruption here, rather we leave this to a subsequent study. In summary, we found that no active regions produced both low- and high-altitude eruptions during the time they were studied and that low-altitude eruptions originating from external PILs were more common than those from internal PILs. Internal PIL and external PIL eruption-productive regions had, on average, lower flux cancellation rates than the active regions that produced high-altitude eruptions and regions that produced no eruptions at all. However, the regions that produced low- or high-altitude eruptions exhibited a similar amount of total flux cancelled, despite the difference in cancellation rates. Therefore, a high rate of flux cancellation and associated reconnection is not alone a sufficient condition for eruption. For the four active regions that produced low-altitude events originating along the internal PIL we found that on average 36\% of the peak active region flux had cancelled prior to eruption. This is consistent with percentages found in previous studies \citep{Green-2011, Baker-2012, Yardley-2016} and is 12\% higher than the average value across non-internal PIL event active regions. A secondary effect of the flux cancellation process is the reduction of active region flux that contributes to the magnetic field overlying and stabilising the sheared core structure (that might contain a flux rope). If a flux rope has formed, and sufficient magnetic flux is transferred from the overlying arcade to this rope, an eruption may be produced. The quantity of flux cancelled, which is equal to the amount available to be built into the flux rope, compared to the flux of the remaining overlying field was found to be in the range 1:0.03 -- 1:1.57 and 1:2.26 -- 1:3.42 for active regions that produced low-altitude internal PIL and high-altitude events, respectively. The ratio for AR 11881 has been omitted from consideration here because this region produced a low-altitude eruption originating from the internal PIL just over a day after the end of the flux cancellation measurement. Therefore, we find that a successful eruption originating from a low-altitude at the internal PIL depends upon the removal of a significant amount of the overlying field, which otherwise acts to stabilise the flux rope. The non-potentiality (or shear) of the arcade field is a key aspect of the \cite{vB-1989} flux rope model. The shear angle measured at the time of the peak active region flux is, on average, 14$^{\circ}$ higher for the regions that produced low-altitude internal PIL events compared to the regions that produced eruptions at high-altitude. An overall convergence of the bipole is important for the gradient of the coronal field that acts to stabilise any flux rope formed. We find that 75\% of the active regions that produced low-altitude eruptions along their internal PIL showed a combination of bipole convergence, shear and flux cancellation. Only 34\% of the active regions that do not produce internal PIL eruptions show this combination. In summary, we have conducted the first extensive study of eruptive activity in a sample of 20 small bipolar active regions taken from the {\it SDO}/HMI era in order to probe the role of flux cancellation as a CME trigger. The results of this study lead to the conclusion that although flux cancellation plays a key role it is not alone sufficient in the production of low-altitude eruptions. A combination of ongoing flux cancellation in a sheared arcade, which is consistent with the flux rope model of \citet{vB-1989}, can build a pre-eruptive configuration but a successful eruption depends upon the removal of sufficient overlying field that would otherwise stabilise the underlying flux rope. In this study the cancellation of more than $\sim$30\% of the peak active region flux value appeared to be sufficient. In addition the eruptions appear to be aided by the convergence of the bipole polarities. \pagebreak \begin{table*}[ht] \centering \begin{tabular}{|c|c|c|c|c|} \hline NOAA & Internal & External & High-Altitude & Coronal \\ AR & PIL Event Timings (UT) & PIL Event Timings (UT) & Event Timings (UT) & Signatures \\ \hline 11437 & - & 2012-03-17 05:14 & - & A, D, L, R \\ & - & 2012-03-17 10:53 & - & A, D, L, R \\ & 2012-03-20 14:46 & - & - & A, D, L \\ 11446 & - & - & 2012-03-24 00:42 & A, D, L \\ 11561 & 2012-09-01 23:37 & - & - & A, D, L, R\\ 11680 & 2013-03-03 17:27* & - & - & A, D, F, R \\ 11808 & - & - & 2013-07-30 04:04 & A, D, L, R \\ & - & - & 2013-07-31 15:10 & A, D, L \\ 11881 & - & - & 2013-10-24 08:10 (09:12) & A, D, L \\ & - & - & 2013-10-27 19:45 & A, D, L \\ &- & - & 2013-10-29 02:58 & A, D \\ 11886 & - & - & 2013-10-29 12:57 & D \\ 12086 & - & 2014-06-10 14:49 & - & D, L, R \\ 12119 & - & 2014-07-18 10:40 & - & A, D, R \\ & - & 2014-07-22 21:02 & - & D, L, R \\ & - & 2014-07-23 07:30 (08:12) & - & A, D, L, R \\ 12229 & - & 2014-12-05 03:46 & - & A, D, R\\ & - & 2014-12-05 08:12 & - & A, D, R \\ & - & 2014-12-05 10:39* & - & R (C) \\ & - & 2014-12-05 12:35 & - & D, R \\ 12274 & - & 2015-01-25 20:00 & - & L, R (C) \\ 12336 & - & - & 2015-05-05 01:29 & A, D, L \\ & - & - & 2015-05-05 09:24 & A, D, L \\ 12382 & 2015-07-09 02:29 & - & - & A, D, L, R \\ \hline \end{tabular} \caption{This table details the eruptions that occurred during the emergence and decay phases of each active region. See Table~\ref{tab:table3} for related active region and flux cancellation information. Column 1 indicates NOAA active region number, columns 2, 3 and 4 indicate the timings of internal PIL events, external PIL events and high-altitude events respectively. Column 4 details the onset time of each eruption as determined by the rapid expansion and eruption of EUV loops. Column 5 gives the coronal signatures observed during an eruption including the eruption of a filament (F), the eruption of an EUV loop system or rapid disappearance of coronal loops (L), post-eruption (flare) arcade or loops (A), flare ribbons (R) and coronal dimming(s) (D). Eruptions that showed no clear coronal dimmings are indicated by (C) in column 5. These could be confined or failed eruptions. *The timings of the eruption onset for one internal PIL eruption originating from AR 11680 and one external PIL eruption from AR 12229 were determined by the onset of a filament eruption. One eruption that originated from AR 11881 and one from AR 12119 could also be observed in LASCO/C2. The timings for the LASCO/C2 observations are given in brackets after the timings of eruption onset. \label{tab:table1}} \end{table*} \begin{table}[h!] \centering \begin{tabular}{|c|c|c|} \hline & Emergence & Decay \\ & phase & phase \\ \hline External PIL & 8 & 3 \\ Internal PIL & 0 & 4 \\ High-altitude & 5 & 4 \\ \hline \end{tabular} \caption{\label{tab:CME_AR_phase} This table details when internal PIL, external PIL and high-altitude eruptions occur in relation to the evolutionary phase of their source active region.} \end{table} \begin{table*}[htbp!] \begin{rotatetable*} \scriptsize \setlength{\tabcolsep}{2pt} \begin{tabular}{*{12}{|c}|} \hline NOAA & Heliographic & Emergence & Peak Flux & Flux Cancellation & Flux Cancellation & Flux Cancellation & Total Flux & Percentage of & FR vs. & Shear & AR \\ AR & Coordinates & Time & Time & Start Time & End Time & Rate & Cancelled & Peak AR Flux & Overlying & Angle at & Bipole \\ No. & ($\theta$,$\phi$) & (UT) & (UT) & (UT) & (UT) & (10$^{19}$~Mx~h$^{-1}$) & (10$^{21}$~Mx) & Cancelled (\%) & AR Ratio & Peak Flux ({}$^{\circ}$) & Convergence \\ \hline 11437 & S29 E33 & 2012-03-16 12:46 & 2012-03-17 15:58 & 2012-03-17 15:58 & 2012-03-21 01:34 & 0.43 & 0.17 & 31 & 1:1.29 & 31 & Y \\ 11446 & N31 E20 & 2012-03-22 15:58 & 2012-03-24 15:58 & 2012-03-25 11:10 & 2012-03-26 03:10 & 1.50 & 0.24 & 24 & 1:2.26 & 6 & Y \\ 11480 & S14 E26 & 2012-05-09 11:10 & 2012-05-11 04:46 & 2012-05-11 11:10 & 2012-05-13 23:58 & 0.29 & 0.17 & 25 & 1:2.38 & 40 & N \\ 11561 & S18 E34 & 2012-08-29 19:10 & 2012-08-31 04:46 & 2012-08-31 04:46 & 2012-09-01 14:22 & 0.99 & 0.33 & 28 & 1:2.55 & 36 & Y \\ 11680 & S25 E52 & 2013-02-24 14:22 & 2013-02-25 14:22 & 2013-02-25 15:58 & 2013-03-03 03:10 & 0.82 & 1.08 & 50 & 1:0.03 & 28 & Y \\ 11808 & N12 E66 & 2013-07-29 01:34 & 2013-07-30 01:34 & 2013-07-30 19:10 & 2013-08-01 11:10 & 2.13 & 0.85 & 29 & 1:2.57 & 18 & N \\ 11813 & S19 E22 & 2013-08-06 01:34 & 2013-08-08 17:34 & 2013-08-08 17:34 & 2013-08-11 23:58 & 1.05 & 0.83 & 31 & 1:1.19 & 37 & Y \\ 11867 & N17 E05 & 2013-10-11 07:58 & 2013-10-13 15:58 & - & - & - & - & - & - & - & - \\ 11881 & S25 E52 & 2013-10-24 01:34 & 2013-10-26 15:58 & 2013-10-26 15:58 & 2013-10-28 14:22 & 1.04 & 0.49 & 34 & 1:0.94 & 25 & N \\ 11886 & N10 E14 & 2013-10-28 09:34 & 2013-10-30 17:34 & 2013-10-30 17:34 & 2013-11-01 04:46 & 0.15 & 0.54 & 24 & 1:2.26 & 23 & Y \\ 12086 & N03 E49 & 2014-06-08 15:58 & 2014-06-09 23:58 & 2014-06-10 15:58 & 2014-06-11 15:58 & 1.00 & 0.24 & 30 & 1:1.67 & 7 & Y \\ 12119 & S26 E38 & 2014-07-18 04:46 & 2014-07-21 06:22 & 2014-07-21 06:22 & 2014-07-23 01:34 & 0.66 & 0.28 & 11 & 1:7.05 & 1 & Y \\ 12168 & N10 E08 & 2014-09-16 12:46 & 2014-09-18 11:10 & 2014-09-19 20:46 & 2014-09-22 14:22 & 0.87 & 0.77 & 37 & 1:0.79 & 37 & Y \\ 12229 & S23 E50 & 2014-12-04 20:46 & 2014-12-05 22:22 & 2014-12-06 04:46 & 2014-12-07 09:34 & 0.83 & 0.24 & 32 & 1:1.3 & 34 & Y \\ 12273 & N02 E21 & 2015-01-15 15:58 & 2015-01-27 19:10 & 2015-01-27 19:10 & 2015-01-29 03:10 & 0.88 & 0.28 & 10 & 1:7.74 & 34 & Y \\ 12274 & N03 E09 & 2015-01-25 17:34 & 2015-01-26 15:58 & 2015-01-26 15:58 & 2015-01-15 01:34 & 0.34 & 0.12 & 28 & 1:1.41 & 23 & N \\ 12336 & N17 E49 & 2015-05-01 14:22 & 2015-05-05 20:46 & 2015-05-05 20:46 & 2015-05-08 23:58 & 0.70 & 0.53 & 18 & 1:3.42 & 1 & Y \\ 12382 & S08 E29 & 2015-07-04 03:10 & 2015-07-05 20:46 & 2015-07-05 20:46 & 2015-07-09 01:34 & 3.50 & 0.27 & 42 & 1:0.32 & 19 & N \\ 12453 & N04 E29 & 2015-11-12 07:58 & 2015-11-15 15:58 & 2015-11-15 15:58 & 2015-11-16 23:58 & 1.58 & 0.51 & 30 & 1:1.35 & 32 & Y \\ 12455 & N14 E61 & 2015-11-13 04:46 & 2015-11-16 03:10 & 2015-11-16 06:22 & 2015-11-18 01:34 & 1.16 & 0.50 & 35 & 1:0.84 & 54 & Y \\ \hline \end{tabular} \caption{Flux cancellation of the 20 ARs in this study. The table shows the active region number as issued by NOAA, the location of the centre of the active region at the time of emergence, the approximate time of active region emergence, peak unsigned flux, start and end of the flux cancellation measurement. This is followed by the flux cancellation values including flux cancellation rate, total flux cancelled, percentage of the peak active region flux cancelled and the ratio of the flux cancelled vs. the flux remaining in the overlying arcade. The flux cancellation values are calculated in the time period between the start and end times of flux cancellation given in columns five and six. Also given is the absolute value of the shear angle of the active region at the time of peak flux, and whether convergence of the active region bipole is observed. \label{tab:table3}} \end{rotatetable*} \end{table*} \begin{table*}[ht] \centering \begin{tabular}{|c|c|c|c|c|c|} \hline NOAA & Flux Cancellation & Total Flux & Total Percentage of & FR vs. Overlying \\ AR & Rate (10$^{19}$~Mx~h$^{-1}$) & Cancelled (10$^{21}$~Mx) & peak AR flux (\%) & Arcade Ratio \\ \hline 11437 & 0.43 & 0.17 & 31 & 1:1.29 \\ 11561* & 0.99 & 0.42 & 28 & 1:1.57 \\ 11680 & 0.82 & 1.08 & 49 & 1:0.03 \\ 12382 & 0.35 & 0.27 & 43 & 1:0.32 \\ \hline 11446 & 1.50 & 0.24 & 23 & 1:2.26 \\ 11808 & 2.13 & 0.85 & 22 & 1:2.57 \\ 11881 & 1.04 & 0.49 & 34 & 1:0.94 \\ 11886 & 0.15 & 0.54 & 24 & 1:2.26 \\ 12336 & 0.70 & 0.53 & 18 & 1:3.42 \\ \hline \end{tabular} \caption{\label{tab:flux_canc} Flux cancellation values for the active regions that produced low-altitude eruptions originating from the internal PIL (top section) and the active regions that produced high-altitude eruptions (bottom section). The table shows the flux cancellation rate, total amount of flux cancelled, total percentage of peak unsigned active region flux cancelled and the ratio of the flux available to be built into the flux rope compared to the flux contained in the overlying arcade, i.e. the flux of the remaining bipole. *Corrected values for total flux cancelled, total percentage of peak active region flux and the ratio of the flux in the flux rope vs. overlying arcade are given for AR 11561.} \end{table*} \acknowledgments The authors are grateful to the SDO/HMI and AIA consortia for the data, and also JHelioviewer (http://jhelioviewer.org/), which was used for browsing data. This research also makes use of SunPy \citep{SunPy-2015} (http://sunpy.org/), an open-source and free community-developed solar data analysis package written in Python. We are also grateful to Sally Dacie who helped with code development. S.L.Y. acknowledges STFC for support via PhD studentship and the Consolidated Grant SMC1 YST025. S.L.Y and L.M.G. are part of an International Space Science Institute (ISSI) team entitled ``Decoding the Pre-Eruptive Magnetic Configurations of Coronal Mass Ejections". We are thankful to ISSI for hosting us, Angelos Vourlidas and Spiros Patsourakos for leading the team, and the rest of the group for valuable discussions. L.M.G. acknowledges support through a Royal Society University Research Fellowship. L.v.D.G. is partially funded under STFC consolidated grant number ST/N000722/1. L.v.D.G. also acknowledges the Hungarian Research grant OTKA K-109276. L.M.G. and L.v.D.G. acknowledge funding under Leverhulme Trust Research Project Grant 2014-051. D.H.M. would like to thank both the STFC and Levehulme trust for financial support. \bibliographystyle{yahapj}
\section{Introduction} The flow past a circular cylinder is a famous, intensively studied problem in fluid mechanics. Above a critical Reynolds number (which measures the relative importance of inertia and viscosity in a flow and is written as $Re = U L / \nu$, where $U$ is the typical velocity in the flow, $L$ a typical length scale, and $\nu$ the kinematic viscosity), the flow results in an organized vortex street that has been studied since the beginning of the 20th century \cite{von1911mechanismus}. While the transition to unsteady flow at a critical Reynolds number $Re_{cr} \approx 46$ has been identified as a supercritical Hopf bifurcation \cite{provansal1987benard}, a number of complex phenomena, some of which are still under discussion, make the situation complex as $Re$ is increased. The detailed mechanisms behind the instability of the time-dependent vortex street have been the subject of controversies in the past \cite{kida1982stabilizing, saffman1982inviscid} and are still an active field of research \cite{mowlavi_arratia_gallaire_2016, heil2017topological}, while attempts to perform active flow control face considerable challenges. Flow control is made challenging due to the unsteady, non-linear, high dimensionality behavior implied by the Navier-Stokes (NS) equations as soon as inertia becomes important \cite{marquet_sipp_jacquin_2008, barbagallo_dergham_sipp_schmid_robinet_2012}. Among the approaches used to attack this problem, the methods based on the adjoint formulation of the optimal control, e.g. \cite{li2003optimal}, require a potentially large number of solutions to the adjoint system (in particular if the problem at hand is ill-posed), and are thus hard to scale. A different class of approaches is based on building a lower-dimensional representation of the flow, e.g. by projecting the full model onto a lower dimensional state space obtained for example by Proper Orthogonal Decomposition or Dynamic Mode Decomposition \cite{ravindran2000reduced}. However, the dimensionality of the space typically grows with $Re$ making construction of the models expensive. Furthermore, the models may not be robust to changes of $Re$ outside of the training/construction range \cite{brunton2015closed}. While strategies based on such models obtain good results on specific applications \cite{7569070}, these methods are difficult to apply to strongly nonlinear dynamic systems and are very specific of a given configuration \cite{brunton2015closed}. As a consequence, a recent review of the field of active flow control calls to embrace the Artificial Intelligence (AI) and Machine Learning paradigm to perform control of complex high-dimensional systems \cite{brunton2015closed}. This view is confirmed by recent experiments of closed-loop control \cite{debien2016closed}, \cite{gautier2015closed}, \cite{benard2016turbulent} where AI techniques, in particular genetic programming, were applied with success. Artificial intelligence and the machine learning paradigm are made even more attractive by several recent highly profiled successes of Deep Artificial Neural Networks (DANNs), such as attaining super-human performance at image labeling \cite{lecun2015deep}, crushing the leading human player at the game of Go \cite{silver2017mastering}, or achieving control of complex robots \cite{7989385}, which have shed the light on their ability to handle complex, non-linear systems. In particular, the Deep Reinforcement Learning (DRL) methodology is a promising avenue for the control of complex systems. This approach consists in letting the DANN interact with the system it should control through 3 channels: an observation of the state of the system, a control imposed by the network on the system, and a reward function measuring control performance. The choice of the reward function allows to direct the efforts of the DANN towards solving a specific problem. Here, we present the first successful use of DANNs trained through DRL to attack the problem of active flow control in a 2D simulation of the flow around a cylinder at a moderate value of the Reynolds number, $Re=100$ ($Re$ is computed based on the cylinder diameter, for more details see the Supplementary Information). This is an illustration of the potential of Artificial Neural Networks trained through Deep Reinforcement Learning for studying and controlling high dimensionality, non-linear systems. \section{Active flow control in a simulation} To demonstrate the ability of DANNs trained through DRL to perform active flow control, we set up a simple 2D simulation of the non-dimensionalized flow around a cylinder as described by the incompressible NS equations at $Re=100$. The configuration chosen is a copy of a classical benchmark used for the validation of numerical codes \cite{Schafer1996}. In addition, two small jets of angular width $10^{\circ}$ are set on the sides of the cylinder and inject fluid in the direction normal to the cylinder surface, following the control set up by the DANN. This implies that the control relies on influencing the separation of the {K}{\'a}rm{\'a}n vortices, rather than direct injection of momentum as could be obtained through propulsion. The jets are controlled through their mass flow rates, respectively $Q_1$ and $Q_2$. We choose to use synthetic jets, meaning that no net mass flow rate is injected in the flow, which translates to the constraint $Q_1 + Q_2 = 0$. More details are available in the Supplementary Information. The aim of the control strategy is guided by the reward function fed to the DRL during training. In the present work, we want to minimize the drag $D$ through a reduction in the strength of the vortex shedding. For this, we define the reward function $r$ from both the drag $D$ and the lift $L$, following: \[ r = \langle D \rangle_{T} - |\langle L\rangle_{T}|, \] \noindent where $\langle\bullet\rangle_{T}$ indicates the mean over one full vortex shedding cycle. In the figures, we present the value of the drag coefficient, which is a normalized value of the drag $C_D = \frac{D}{\rho \bar{U}^2 R}$, where $\bar{U}=2 U(0) / 3$ is the mean velocity magnitude, $\rho$ the volumetric mass density of the fluid, and $R$ the diameter of the cylinder (for more details, see the Supplementary Information). Similarly, the mass flow rates of the jets are normalized as $Q^{*}_i = Q_i / Q_c$, where $Q_c = \int_{-R}^{R}{\rho U(y) dy}$ is the mass flow rate introduced by the inlet profile that intersects the cylinder diameter. Therefore, $Q^{*}_i$ indicates the relative strength of the control jets, compared with the incoming flow. Drastic changes are observed in the flow behind the cylinder in the case of active flow control by a trained DANN compared with the baseline simulation without control, as visible in Fig. \ref{snapshot_comparison}. A video of the flow undergoing active control, compared with the baseline, is also available as Extended Data. The vortex shedding is both strongly reduced in intensity, and displaced around $3$ cylinder diameters downstream of the cylinder. The change in the flow configuration has a notable effect on both the lift and drag: drag is reduced by around $8$\% (see Fig. \ref{drag_control}), while the fluctuations in lift are reduced by around $75$\%. The area $A$ of the recirculation bubble is drastically increased, by $125$\%. In addition, the vortex shedding frequency is modified by the active control, and gets reduced by around $15$\%. \begin{figure} \begin{center} \includegraphics[width=.95\textwidth]{Figures/snapshot_both_together_v1.png} \caption{\label{snapshot_comparison} Snapshots of the velocity magnitude illustrating the effect of the active flow control. Top: baseline simulation. Bottom: result with active flow control. The size of the recirculation bubble is greatly increased in the case with active control, and the strength of the {K}{\'a}rm{\'a}n vortex street is reduced. A video comparing the two flows is available as Extended Data.} \end{center} \end{figure} \begin{figure} \begin{center} \includegraphics[width=.70\textwidth]{Figures/main.png} \caption{\label{drag_control} Time-resolved value of the drag coefficient $C_D$ in the case without (baseline curve) and with (controlled curve) active flow control, and corresponding normalized mass flow rate of the control jet 1 (inset). The effect of the flow control on the drag is clearly visible: a reduction of the drag of around $8$\% is observed, and the fluctuations in time due to vortex shedding are nearly suppressed. Two phases can be distinguished in the mass flow rate control: first, a relatively large control is used to change the flow configuration, up to a non-dimensional time of around $1.1$, before a pseudo periodic regime with very limited flow control is established.} \end{center} \end{figure} The explanation for the reduced drag is to be found in the change of the mean pressure distribution around the cylinder. As visible in Fig. \ref{pressure_difference}, the recirculation area behind the cylinder undergoing active control is both larger, and less intense than in the baseline case. This somewhat counter-intuitive effect is a good illustration of the ability of the DANN to find complex strategies to optimize its reward function. \begin{figure} \begin{center} \includegraphics[width=.95\textwidth]{Figures/pressure_difference.png} \caption{\label{pressure_difference} Difference between the mean pressure field in the actuation case and the baseline case. The pressure in the recirculation bubble is increased by the actuation, which is the cause for the drag reduction.} \end{center} \end{figure} Finally, it should be noted that very little mass flow rate is necessary to perform active flow control, as visible in Fig. \ref{drag_control}. Two phases are visible on Fig. \ref{drag_control}, and also on the video in the Extended Data. First, a very short transient takes place where the DANN changes the flow configuration. Then, the DANN manages to keep the flow in this modified configuration, performing a pseudo-periodic control. While we give the DANN the freedom to set a control mass flow rate for each jet in the range of $Q^{*}_{i} = [-0.07, +0.07]$, in practice the network chooses to use normalized mass flow rates of absolute value at most $0.02$ during the initial transient control, and as small as $5 \times 10^{-3}$ at most to keep the vortex street in its new regime. This represents in average only around $0.35$\% of the incoming mass flow rate that intercepts the diameter of the cylinder for the active flow control in the established regime. Despite the very limited level of actuation in the new pseudo-periodic flow regime, altering the control signal even slightly leads to a collapse of the active control. \section{Discussion and future work} We prove that DANNs trained through DRL are a possible tool for performing active flow control. It is striking to see how efficient the DANN can be, as we show that our trained network uses very small controls to play with the state of a complex system. From the shape of the control signal, it seems that the DANN finds ways to control the flow through infinitesimal modifications of exponentially amplified modes that control the detachment of the vortex street, a fact that was previously reported in attempts to perform optimal flow control on simplified reduced order models \cite{7569070}. Following our results, it appears that DANNs trained through DRL could have a general interest in fluid mechanics. Indeed, we have proved their relevance for active flow control, and a number of interesting cases should be investigated, such as the control of 3D Large Eddy Simulations, or Direct Numerical Simulation of boundary layers. In addition, one could try to combine DANNs with more traditional analytical methods to investigate properties of the solutions implied by the NS equations. Moreover, besides fluid mechanics, our work suggests that the use of DANNs as an experimental tool to study complex systems where traditional analytical approaches are limited should be investigated. In this sense, our results can be seen as one more confirmation of the main message expressed in the last years by the community investigating DANNs: DANNs are a successful tool at studying and handling complexity, which under its many forms is one of the major challenges modern science still fails to fully apprehend. \section{Acknowledgments} We gratefully acknowledge funding by the Research Council of Norway through the grants 'DOFI' (grant number 280625) and 'RigSpray' (grant number 421160). We are grateful to Terje Kvernes and Lucy Karpen for considerable help setting up the computation infrastructure used in this project. \bibliographystyle{jfm}
\section*{Appendix} \begin{figure*}[htb!] \centering \subfloat[Network: polblogs]{ \includegraphics[scale=0.15]{pets18/images/Features/polblogs_syn_vulnerability_features.pdf} \label{fig:polblogs_syn_vulnerability_features} } \hspace{0mm} \subfloat[Network: fb-caltech]{ \includegraphics[scale=0.15]{pets18/images/Features/fb-caltech_syn_vulnerability_features.pdf} \label{fig:fb-caltech_syn_vulnerability_features} } \hspace{0mm} \subfloat[Network: fb-dartmouth]{ \includegraphics[scale=0.15]{pets18/images/Features/fb-dartmouth_syn_vulnerability_features.pdf} \label{fig:fb-dartmouth_syn_vulnerability_features} } \hspace{0mm} \subfloat[Network: fb-michigan]{ \includegraphics[scale=0.15]{pets18/images/Features/fb-michigan_syn_vulnerability_features.pdf} \label{fig:fb-michigan_syn_vulnerability_features} } \hspace{0mm} \subfloat[Network: pokec-1]{ \includegraphics[scale=0.15]{pets18/images/Features/pokec-1_syn_vulnerability_features.pdf} \label{fig:pokec-1_syn_vulnerability_features} } \hspace{0mm} \subfloat[Network: amazon-products]{ \includegraphics[scale=0.15]{pets18/images/Features/amazon-products_syn_vulnerability_features.pdf} \label{fig:amazon-products_syn_vulnerability_features} } \caption{Kernel density estimate of the distribution of probability values which define the importance of features for the prediction tasks between original and ERGM graph structures. } \label{fig:vulnerability_features_syn} \end{figure*} \section{Datasets} \label{sec:datasets} Because our work is empirically driven, a larger set of test datasets promises a better understanding of the relations between vulnerability to re-identification attacks and the particular characteristics of the node attributes (such as fractions of attributes of a particular value or the assignment of attributes to topologically related nodes). In this respect, real datasets are always preferable to synthetic ones, as they potentially encapsulate phenomena that are missing in the graph generative models. As an example, until very recently, the relation between the local degree assortativity coefficient and node degree was not captured in graph topology generators~\cite{sendina2016assortativity}. However, relying only on real datasets has its limitations, due to the scarcity of relevant data (in this case, networks with binary node attributes) and the difficulty of covering the relevant space of graph metrics when relying only on available real datasets. Thus, in this work, we combine real networks (described in Section~\ref{sec:realdatasets}) with synthetic networks generated from the real datasets. For generating synthetic labelled networks, we employ ERGMs~\cite{holland1981exponential,wasserman1996logit} and a controlled node-labeling algorithm as described in Section~\ref{sec:synthetic_graphs}. \subsection{Real Network Datasets} \label{sec:realdatasets} We chose six publicly available datasets from four different contexts and generated eight networks with binary node attributes. \begin{itemize} \item \texttt{polblogs}~\cite{adamic2005political} is an interaction network between political blogs during the lead up to the 2004 US presidential election. This dataset includes ground-truth labels identifying each blog as either conservative or liberal. \item \texttt{fb-dartmouth}, \texttt{fb-michigan}, and \texttt{fb-caltech}~\cite{traud2012social} are Facebook social networks extant at three US universities in 2005. A number of node attributes such as dorm, gender, graduation year, and academic major are available. We chose two such attributes that could be represented as binary attributes: gender and occupation, whereby occupation we could identify the attribute values ``student'' and ``faculty''. From each dataset, we obtained two networks with the same topology but different node attribute distributions. \item \texttt{pokec-1}~\cite{takac2012data} is a sample of an online social network in Slovakia. While the Facebook samples are university networks, Pokec is a general social platform whose membership comprises 30\% of the Slovakian population. \texttt{pokec-1} is a one-fortieth sample. This dataset has gender information available as a node attribute. \item \texttt{amazon-products}~\cite{leskovec2007dynamics} is a bi-modal projection of categories in an Amazon product co-purchase network. Nodes are labeled as ``book'' or ``music'', edges signify that the two items were purchased together. \end{itemize} As Table~\ref{tbl:dataset} shows, the networks generated from these datasets have different graph characteristics. For example, the density ($d$) of the graphs varies across three orders of magnitude, while degree assortativity oscillates between disassortative (for \texttt{polblogs}, $r = -0.22$, where there are more interactions between popular and obscure blogs than expected by chance) to assortative (as expected for social networks). All topologies except for \texttt{amazon-products} have small average path length. The metrics $p$ and $\tau$ shown in Table~\ref{tbl:dataset} are inspired from the synthetic node labeling algorithm used for generating synthetic graphs (and presented later), and they also show high variation across different networks. Intuitively, $p$ captures the diversity of attribute values in the node population (with $p=0.5$ showing equal representation of the attributes) while $\tau$ captures the homophily phenomenon (that functions as an attraction force between nodes with identical attribute values). The homophilic attraction metric $\tau$ varies between 0 in \texttt{pokec-1} (thus, no higher than chance preference for social ties with people of the same gender in Slovakia) to 0.99 in \texttt{amazon-products} (books are purchased together with other books much more strongly than given by chance). The diversity metric $p$ varies between the overrepresentation of males in the US academic Facebook networks (8\% female representation) to an almost perfect political representation in the \texttt{polblogs} dataset (where $p=0.48$). Note that, we only consider $p$ as the minimum proportion of two node groups due to the symmetric nature of attributes in our experiments. This wide variation in graph metrics values is what motivated our choice for these set of real networks. We opted to include the three Facebook networks from similar contexts to also capture more subtle variations in network characteristics. \begin{table*}[!t] \centering \caption{ Graph properties of the real network datasets. All graphs are undirected, and nodes are annotated with a binary valued attribute. E.g., nodes in the polblogs network have the attribute \texttt{party} with values; conservative and liberal. For simplicity, binary values are presented using the notation of \texttt{R} and \texttt{B}, together with the distributions of such values over nodes and edges. $p$ and $\tau$ present the estimated parameter values of the attraction model. Density $(\bar{d})$ is the fraction of all possible edges, transitivity $(C)$ is the fraction of triangles of all possible triangle in the network. degree-assortativity $(r)$ measures the similarity of relations depending on the associated node degree. Average path length $(\kappa)$ depicts the average shortest path length between any pairs of nodes. } \label{tbl:dataset} \begin{tabular}{|r|r|r|r|r|r|r|r|r|r|r|r|} \hline \multirow{2}{*}{Network} & \multicolumn{2}{|c|}{$|N|$} & \multicolumn{3}{|c|}{$|E|$} & \multirow{2}{*}{$p$} & \multirow{2}{*}{$\tau$} & \multirow{2}{*}{$\bar{d}$} & \multirow{2}{*}{$C$} & \multirow{2}{*}{$r$} & \multirow{2}{*}{$\kappa$} \\ \cline{2-6} & $R (\%)$ & $B (\%)$ & $R - R (\%)$ & $B - B (\%)$ & $R - B (\%)$ & & & & & & \\ \hline polblogs & \multicolumn{2}{|c|}{$1224$} & \multicolumn{3}{|c|}{$16718$} & \multicolumn{2}{c|}{} & \multirow{2}{*}{$0.02$} & \multirow{2}{*}{$0.22$} & \multirow{2}{*}{$-0.22$} & \multirow{2}{*}{$2.49$} \\ \cline{1-8} (party) & $48$ & $52$ & $44$ & $48$ & $8$ & $0.48$ & $0.84$ & & & & \\ \hline \\ \hline fb-caltech & \multicolumn{2}{|c|}{$769$} & \multicolumn{3}{|c|}{$16656$} & \multicolumn{2}{c|}{} & \multirow{3}{*}{$0.05$} & \multirow{3}{*}{$0.29$} & \multirow{3}{*}{$-0.06$} & \multirow{3}{*}{$1.33$} \\ \cline{1-8} (gender) & $91.5$ & $8.5$ & $92.8$ & $0.2$ & $7$ & $0.08$ & $0.52$ & & & & \\ \cline{1-8} (occupation) & $72$ & $28$ & $69$ & $8$ & $23$ & $0.28$ & $0.42$ & & & & \\ \hline \\ \hline fb-dartmouth & \multicolumn{2}{|c|}{$7694$} & \multicolumn{3}{|c|}{$304076$} & \multicolumn{2}{c|}{} & \multirow{3}{*}{$0.01$} & \multirow{3}{*}{$0.15$} & \multirow{3}{*}{$0.04$} & \multirow{3}{*}{$2.76$} \\ \cline{1-8} (gender) & $86.5$ & $13.5$ & $83.2$ & $0.9$ & $15.9$ & $0.14$ & $0.34$ & & & & \\ \cline{1-8} (occupation) & $62$ & $38$ & $58$ & $18$ & $24$ & $0.38$ & $0.5$ & & & & \\ \hline \\ \hline fb-michigan & \multicolumn{2}{|c|}{$30147$} & \multicolumn{3}{|c|}{$1176516$} & \multicolumn{2}{c|}{} & \multirow{3}{*}{$0.0026$} & \multirow{3}{*}{$0.13$} & \multirow{3}{*}{$0.115$} & \multirow{3}{*}{$3.05$} \\ \cline{1-8} (gender) & $92.2$ & $7.8$ & $90.5$ & $0.2$ & $9.3$ & $0.08$ & $0.37$ & & & & \\ \cline{1-8} (occupation) & $77.5$ & $22.5$ & $72$ & $9$ & $19$ & $0.22$ & $0.46$ & & & & \\ \hline \\ \hline pokec-1 & \multicolumn{2}{|c|}{$265388$} & \multicolumn{3}{|c|}{$700352$} & \multirow{2}{*}{$0.46$} & \multirow{2}{*}{$0$} & \multirow{2}{*}{$2 \times 10^{-5}$} & \multirow{2}{*}{$0.0068$} & \multirow{2}{*}{$-0.044$} & \multirow{2}{*}{$5.66$} \\ \cline{2-6} (gender) & $46$ & $54$ & $18.6$ & $22.4$ & $59$ & & & & & & \\ \hline \\ \hline amazon-products & \multicolumn{2}{|c|}{$303551$} & \multicolumn{3}{|c|}{$835326$} & \multirow{2}{*}{$0.18$} & \multirow{2}{*}{$0.99$} & \multirow{2}{*}{$1.8 \times 10^{-5}$} & \multirow{2}{*}{$0.21$} & \multirow{2}{*}{$-0.06$} & \multirow{2}{*}{$17.42$} \\ \cline{2-6} (category) & $82$ & $18$ & $83.4$ & $16.4$ & $0.2$ & & & & & & \\ \hline \end{tabular} \end{table*} \subsection{Synthetic Graphs} \label{sec:synthetic_graphs} In order to be able to control graph characteristics and node attribute distributions, we also generated a number of synthetic graphs comparable with the real datasets just described. The graph generation included two aspects: topology generation, for which we opted for ERGMs, and node attribute assignments, for which we implemented the technique proposed in~\cite{Skvoretz2013}. \subsubsection{Varying Topology via ERGMs} \label{sec:ERGM} Exponential-family random graph models (ERGMs) or p-star models~\cite{holland1981exponential,wasserman1996logit} are used in social network analysis for stipulating, within a set structural parameters, distribution probabilities for networks. Its primary use is to describe structural and local forces that shape the general topology of a network. This is achieved by using a selected set of parameters that encompass different structural forces (e.g., homophily, degree correlation/assortativity, clustering, and average path length). Once the model has converged, we can obtain maximum-likelihood estimates, model comparison and goodness-of-fit tests, and generate simulated networks tied to the relationship between the original network and the probability distribution provided by the ERGM. Our interest in ERGMs is based on simulating graphs that retain set structural information from the original graph to generate a diverse set of graph structures. We used R~\cite{team2014r} and the \texttt{statnet} suite~\cite{handcock2014statnet}, which contains several packages for network analysis, to produce ERGMs and simulate graphs from our real-world network datasets. In this case, we focused on three structural aspects of the graphs: clustering coefficient, average path length, and degree correlation/assortativity. For the ERGM based on clustering coefficient, we used the \texttt{edges} and \texttt{triangle} parameters in the statnet package. The \texttt{edges} parameter measures the probability of linkage or no linkage between nodes, and the \texttt{triangle} term looks at the number of triangles or triad formations in the original graph. For the average path length model, \texttt{edges} and \texttt{twopath} terms were used. The \texttt{twopath} term measures the number of 2-paths in the original network and produces a probability distribution of their formation for the converged ERGM. Lastly, for the assortativity measure, the terms \texttt{edges} and \texttt{degcor} were used to produce the models. The \texttt{degcor} term considers the degree correlation of all pairs of tied nodes (for more on ERGMs see \cite{hunter2008ergm,morris2008specification}). These terms proved to be our best choices for preserving, to a certain extent, the desired structural information. Although the creation of ERGMs is a trial and error process, the selected terms were successful in producing models for each of the original networks. After a successful model convergence, a simulated graph was generated constraining the number of edges to those of the original graph for each model. It is worth mentioning that within the built-in \texttt{simulate} function in the \texttt{statnet} suite there is no way of forcibly constraining the aspects of the original we want to control. Thus, we experience variation, in some cases more than others. The difference between the original and the simulated graphs seemed more prominent for smaller networks (see Table 1 and Table 2 for comparison) than models based on the larger networks which came closer to the real values of the original graphs. \subsubsection{Synthetic Labeling} \label{sec:labeling} A simple model that parameterizes a labeled graph with a tendency towards homophily (ties disproportionately between those of similar attribute background) is an ``attraction'' model~\cite{Skvoretz2013}. In the basic case of a binary attribute variable and a constant tendency to inbreed, two parameters, $p$ and $\tau$, both in the (0,1) interval, characterize the distribution of ties within and between the two groups. The first is the proportion of the population that takes on one value of the attribute (with $1-p$, the proportion taking on the other value). The second parameter, the inbreeding coefficient or probability, expresses the degree to which a tie whose source is in one group is "attracted" to a target in that group. When $\tau=0$, there is no special attraction and ties within and between groups occur in chance proportions. When $\tau>0$, ties occur disproportionately within groups, increasing as $\tau$ approaches 1. Given a total number of ties, values for $p$ and $\tau$ determine the number of ties/edges that are between groups, namely, $\delta=|E|\times2\times(1-\tau)p(1-p)$. In the process of generating synthetic node attributes, we first randomly assign two arbitrary values (i.e., R and B) as labels to all the nodes in the graph for a given $p,1-p$ split. Then, we draw an R node and a B node at random and swap labels if it would decrease the number of R-B ties. This process would converge when the total number of cross-group ties reduce to $\delta$ for a particular value of $\tau$. As an example, Figure~\ref{fig:syn_graph_stat} shows the proportion of cross-group ties on the synthetic labelled networks generated from \texttt{polblogs} topology. The proportion of cross-group ties is proportional to $p$, while it is inversely proportional to $\tau$. When $p$ reaches its maximum ($p_{max}=0.5$ due to the symmetric nature of binary attribute values), the proportion of cross group ties is relatively larger at minimum inbreeding coefficient $\tau$. It should be noted that convergence is not guaranteed for all possible combinations of $p$ and $\tau$. The swapping procedure holds constant all graph properties except the mapping of nodes to labels, and consequently, it may not be possible to find a mapping of nodes to labels that achieves a target number of ties between groups (when that number is low as it is for higher values of $\tau$). Table~\ref{tbl:ERGM-characteristics} presents the graph characteristics of the synthetically generated labeled graphs. \begin{figure}[t] \centering \includegraphics[scale=0.4]{./images/Synthetic-Graphs/polblogs_syn_ties_cross_group.pdf} \caption{Network: polblogs, proportion of cross group ties on synthetic networks generated from the original graph structure. } \label{fig:syn_graph_stat} \end{figure} \begin{table*}[!t] \centering \caption{Basic statistics of generated ERGM networks, and the population of node pairs. Note that \texttt{dc,cc} and \texttt{apl} define the set of parameters that used to generate ERGM graphs based on assortativity (degree correlation), clustering coefficient, and average path length, respectively. We generated a total of $\approx$ $500$ million identical and non-identical node pairs over three ERGM graph spaces of the six real social network datasets. $S$ is the population of generated node pairs concerning a given graph topology.} \label{tbl:ERGM-characteristics} \begin{tabular}{|c|c|c|r|r|r|r|} \hline Network & ERGM & $d$ & $C$ & $r$ & $\kappa$ & |S| (\textit{millions})\\ \hline \multirow{3}{*}{polblogs} & dc & 0.02 & 0.03& .08 & 2.52 & 5.5 \\ \cline{2-7} & cc & 0.02 & 0.33& -0.02 & 2.69 & 13.1 \\ \cline{2-7} & apl & 0.02 & 0.10 & -0.06 & 2.49 & 11.5 \\ \hline \multirow{3}{*}{fb-caltech} & dc & 0.06 & 0.08 & 0.11 & 2.13 & 1.2 \\ \cline{2-7} & cc & 0.06 & 0.42 & -0.06 & 2.73 & 4.1 \\ \cline{2-7} & apl & 0.06 & 0.07 & 0.11 & 1.97 & 1.2 \\ \hline \multirow{3}{*}{fb-dartmouth} & dc & 0.01 & 0.17 & 0.07 & 2.66 & 14.5 \\ \cline{2-7} & cc & 0.01 & 0.24 & 0.04 & 2.77 & 13.2 \\ \cline{2-7} & apl & 0.01 & 0.20 & 0.04 & 2.70 & 14.2 \\ \hline \multirow{3}{*}{fb-michigan} & dc & 0.003 & 0.02 & 0.12 & 3.28 & 38.4 \\ \cline{2-7} & cc & 0.002 & 0.20 & 0.12 & 3.52 & 39.9 \\ \cline{2-7} & apl & 0.002 & 0.20& 0.12 & 3.64 & 38.2 \\ \hline \multirow{3}{*}{pokec-1} & dc & 2.02E-5 & 0.06 & -0.04 & 5.60 & 29.5 \\ \cline{2-7} & cc & 2.05E-5 & 0.07 & -0.04 & 5.84 & 29.3 \\ \cline{2-7} & apl & 2.04E-5 & 0.06 & -0.04 & 5.63 & 27.3 \\ \hline \multirow{3}{*}{amazon-products} & dc & 1.82E-5 & 0.37 & -0.06 & 11.86 & 43.7 \\ \cline{2-7} & cc & 1.82E-5 & 0.40 & -0.06 & 13.52 & 72.5 \\ \cline{2-7} & apl & 1.82E-5 & 0.39 & -0.06 & 13.47 & 74.3 \\ \hline \end{tabular} \end{table*} \section{Summary and Discussions} \label{sec:discussions} Our work shows that the addition of even a single binary attribute to nodes in a network graph increases its vulnerability to re-identification. Previous work showed that vulnerability increases with the addition of multiple, multi-category attributes~\cite{JiMittal2016De-SAG}. We measure the vulnerability increase and study how it is affected by network and attribute properties. The increase in vulnerability derives from the fact that the machine learning attack makes use of the interaction between topology and the distribution of node labels. Using information about the distribution of labels in a node's neighborhood provides additional leverage for the re-identification process even when labels are rudimentary. Furthermore, we find that a population's diversity on the binary attribute consistently degrades anonymity and increases vulnerability. Diversity means a more even distribution of the binary attribute which produces a more varied set of neighborhood distributions that a particular node may exhibit. Consequently, nodes are more easily distinguished from one another by virtue of their differing neighborhood distributions of labels. One puzzle remains. There is no consistent discernible impact of homophily, as measured by the inbreeding coefficient, on vulnerability. Our procedure for investigating the impact of homophily simply involves swapping labels without disturbing ties. Therefore, both local and global (unlabeled) topologies remain constant as we decrease the number of cross-group ties to achieve a target value implied by a particular inbreeding coefficient for a given proportional split along the binary attribute. This procedure disturbs the local labeled topology but because the machine learning attack uses information from that local topology it apparently can adapt to the changes and make equally successful predictions regardless of the value of the inbreeding coefficient. Perhaps that is why many different factors in attacks on the labeled graphs have some degree of responsibility for success and, no relatively small subset gets the lion's share of the credit. \section{Empirical Results} \label{sec:experiments} Our objective is not to measure the success of re-identification attacks on original datasets in which node identities have been removed: it has been demonstrated long ago~\cite{backstrom2007wherefore} that naive anonymization of graph datasets does not provide privacy. Instead, our objective is to quantify the exposure provided by node attributes on top of the intrinsic vulnerability of the particular graph topology under attack. In our experiments, we leverage the real and synthetic networks described above. We mount the machine learning attack described in Section~\ref{sec:machine-learning-attack} to re-identify nodes using features based on both graph topology and node attributes. Our first guiding question is thus: \textit{How much risk of node re-identification is added to a network dataset by its binary node attributes?} \subsection{The Vulnerability Cost of Node Attributes} \label{sec:vulnerability_cost} \begin{figure*}[htb!] \scalebox{0.9}{ \begin{tabular}{ccc} \subfloat[Network: fb-caltech (gender)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/fb-caltech-gender_mean_cv.pdf} \label{fig:fb-caltech-gender_org_vulnerability} } & \subfloat[Network: fb-caltech (occupation)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/fb-caltech-oc_mean_cv.pdf} \label{fig:fb-caltech-oc_org_vulnerability} } &\subfloat[Network: polblogs (party)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/polblogs_mean_cv.pdf} \label{fig:polblogs_org_vulnerability} } \\ \subfloat[Network: fb-dartmouth (gender)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/fb-dartmouth-gender_mean_cv.pdf} \label{fig:fb-dartmouth-gender_org_vulnerability} } & \subfloat[Network: fb-dartmouth (occupation)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/fb-dartmouth-oc_mean_cv.pdf} \label{fig:fb-dartmouth-oc_org_vulnerability} } & \subfloat[Network: pokec-1 (gender)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/pokec-1_mean_cv.pdf} \label{fig:pokec-1_org_vulnerability} } \\ \subfloat[Network: fb-michigan (gender)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/fb-michigan-gender_mean_cv.pdf} \label{fig:fb-michigan-gender_org_vulnerability} } & \subfloat[Network: fb-michigan (occupation)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/fb-michigan-oc_mean_cv.pdf} \label{fig:fb-michigan-oc_org_vulnerability} } & \subfloat[Network: amazon-products (category)]{ \includegraphics[width=0.33\linewidth]{./images/GS_GS-LBL/amazon-products_mean_cv.pdf} \label{fig:amazon-products_org_vulnerability} } \\ \end{tabular} } \caption{Accuracy of predictions is presented using 5 $\times$ 2 cross-validation F1-scores. Mean accuracy values are shown for real network datasets on GS and GS(LBL) along with the T-statistic which describes the difference in means of the GS and GS(LBL) vectors of prediction probabilities statistically. The network with node attributes is more vulnerable to node re-identification when T-statistic is positive and large. } \label{fig:org_vulnerability_GS_GS-LBL} \end{figure*} Figure~\ref{fig:org_vulnerability_GS_GS-LBL} presents the accuracy of node re-identification in the original graph topology GS and in the same topology augmented with node attributes GS(LBL). As expected, the re-identification attack performs (generally) better when node attributes are used in the attack. Surprising to us, however, is the relatively small vulnerability cost that node attributes introduce. For example, the \emph{occupation} attribute has a barely noticeable benefit to the attacker in \texttt{fb-dartmouth}. More interestingly, however, the same attribute performs differently for the other two Facebook networks considered: for \texttt{fb-caltech} the \emph{occupation} label functions as noise, leading to a small decrease in the F1-score. For \texttt{fb-michigan}, on the other hand, the \emph{occupation} label significantly improves the attacker's performance. Another observation from this figure is that different node attributes applied to the same topology have different outcomes: see, for example, the case of the \texttt{fb-michigan} topology, where the difference between the impacts of the \emph{gender} and the \emph{occupation} attributes is the largest. We thus formulate a new question: \emph{What placement of attributes onto nodes reveal more information?} \subsection{Diversity Matters, Homophily Not} \label{sec:diversity_matters} To understand how the placement of attribute values on nodes affects vulnerability, we generate synthetic node attributes in a controlled manner. By varying $p$ (the diversity ratio) and $\tau$ (the bias of nodes with same-value attributes to be connected by an edge), we can study the effect of these parameters on node re-identification. Figure~\ref{fig:syn_vulnerability_TStat} presents the T-statistics of the F1-scores for node re-identification attacks on the original topology vs. labeled versions of the original topology. In addition to the original topologies, Figure~\ref{fig:syn_vulnerability_TStat} also presents results on various synthetic networks generated as presented in Section~\ref{sec:synthetic_graphs}. \begin{figure*}[!] \centering \subfloat[Network: polblogs ]{ \includegraphics[scale=0.3]{./images/T-stat/polblogs_syn_vulnerability_TStat_Barplot_updated.pdf} \label{fig:polblogs_syn_vulnerability_TStat_Barplot} } \hspace{0mm} \subfloat[Network: fb-dartmouth ]{ \includegraphics[scale=0.3]{./images/T-stat/fb-dartmouth_syn_vulnerability_TStat_Barplot_updated.pdf} \label{fig:fb-dartmouth_syn_vulnerability_TStat_Barplot} } \hspace{0mm} \subfloat[Network: fb-michigan ]{ \includegraphics[scale=0.3]{./images/T-stat/fb-michigan_syn_vulnerability_TStat_Barplot_updated.pdf} \label{fig:fb-michigan_syn_vulnerability_TStat_Barplot} } \hspace{0mm} \subfloat[Network: pokec-1 ]{ \includegraphics[scale=0.3]{./images/T-stat/pokec-1_syn_vulnerability_TStat_Barplot_updated.pdf} \label{fig:pokec-1_syn_vulnerability_TStat_Barplot} } \hspace{0mm} \subfloat[Network: amazon-products ]{ \includegraphics[scale=0.3]{./images/T-stat/amazon-products_syn_vulnerability_TStat_Barplot_updated.pdf} \label{fig:amazon-products_syn_vulnerability_TStat_Barplot} } \caption{Accuracy of predictions is presented using 5 $\times$ 2 cross-validation F1-scores. T-statistic between prediction scores of GS(LBL) and GS are shown. Results are shown across different structures of original and ERGM graphs. Each ERGM graph is presented using the generated parameters of \texttt{dc} (degree-correlation), \texttt{cc}(clustering coefficient) and \texttt{apl} (average path length) } \label{fig:syn_vulnerability_TStat} \end{figure*} We observe three phenomena: First, it appears that $p$ is positively correlated with the T-statistic value measuring the re-identification impact of attributes. That is, the more diversity (that is, the larger $p$), the more vulnerable to re-identification the labeled nodes become on average. Intuitively, in a highly skewed attribute population, while the minority nodes will be identified quicker due to node attributes, the majority remains protected. On the other hand, when $p=0.5$, a network has two equal-sized sets of nodes where each set takes one of two attribute values. This is explained by the fact that the NAD feature vector captures more diverse information in the attributes of neighbots when $p$ is larger. This is also the explanation for why the node attributes contribute so much more to vulnerability in the \texttt{polblogs} dataset, which has a large diversity ($p=0.48$) (thus, almost equal numbers of conservative and liberal blogs). Note that the effect of $p$ on the added vulnerability remains consistent across all topologies (real and synthetic) tested. The second observation is that there is no visible pattern on how $\tau$ influences the vulnerability added by binary node attributes. While this is disappointing from the perspective of story telling, it is potentially encouraging for data sharing, as it suggests that datasets that record homophily (or influence, the debate is irrelevant in this context) do not have to be anonymized by damaging this pattern. As a specific example, the privacy of a dataset that records an information dissemination phenomenon could be provided without perturbing the cascading-related ties. The third class of observations is related to the relative effect of the topological characteristics on the added vulnerability. Both \texttt{amazon-products} and \texttt{pokec-1} are orders of magnitude sparser than the other datasets considered. This means that the topological information available to the machine learning algorithm is limited. In this situation, the addition of the attribute information turns out to be very significant: the T-statistic values for these datasets are significantly larger than for the other datasets, with values over 400 in some cases. Another topological effect is noticed when comparing the real \texttt{pokec-1} topology with the ERGM-generated ones in Figure~\ref{fig:pokec-1_syn_vulnerability_TStat_Barplot}: the node attribute contributes much more to the vulnerability of the original topology compared to the synthetic topologies. The reason for this unusual behavior may lay in the different clustering coefficients of the networks, as seen in Tables~\ref{tbl:dataset} and \ref{tbl:ERGM-characteristics}: the ERGM-generated topologies have clustering coefficients one order of magnitude higher than the original topology (for the same graph density), which leads to more diverse NDD feature vectors for the networks with higher clustering and thus richer training information. This in turn leads to better accuracy in node re-identification in the unlabeled ERGM topologies (with higher clustering) than in the original topology. For example, the maximum F1-score for the ERGM-dc topology is 0.92 while for the original is 0.76 in \texttt{pokec-1}. Thus, the relative benefit of the node attribute is significantly higher when the topology features were poorer. \subsection{Topology Leaks} \label{sec:features} Figure~\ref{fig:vulnerability_features_org} presents the importance of features that are used in node re-identification. A high importance score represents a feature that is responsible for accurately classifying a large proportion of examples. We make three observations from this figure. First, most of the NAD features (together with node's attribute value) that represent node attribute information prove to be important in all datasets. Second, among the NDD features, only a small number contributes consistently to accurate prediction. As shown in Figures~\ref{fig:polblogs_org_vulnerability_features}~-~\ref{fig:amazon-products_org_vulnerability_features}, the first bin of 1-hop and 2-hop NDD vectors contribute the most. That is, a high impact on the re-identification of a node is brought by the number of its neighbors with degrees between 1 and 50. Even in large networks such as \texttt{pokec-1} and \texttt{amazon-products} with a larger range of node degrees, this behavior is observed. Third, Figure~\ref{fig:vulnerability_features_org} suggests what features explain the effect of diversity $p$ on node re-identification in labeled networks. On datasets with large diversity (such as \texttt{polblogs} or \texttt{pokec-1}), the topological information contributes less than on datasets with low diversity (such as \texttt{fb-caltech (gender)}). This is because high diversity correlates to richer NAD feature vectors, and thus the relative importance of the NAD features increases. \begin{figure*}[!ht] \scalebox{0.9}{ \begin{tabular}{ccc} \subfloat[Network: fb-caltech (gender)]{ \includegraphics[width=0.33\linewidth]{./images/Features/fb-caltech_LBL_UNLBL_feature_importance.pdf} \label{fig:fb-caltech_org_vulnerability_features_gender} } & \subfloat[Network: fb-caltech (occupation)]{ \includegraphics[width=0.33\linewidth]{./images/Features/fb-caltech-oc_LBL_UNLBL_feature_importance.pdf} \label{fig:fb-caltech-oc_org_vulnerability_features_occupation} } & \subfloat[Network: polblogs (party)]{ \includegraphics[width=0.33\linewidth]{./images/Features/polblogs_LBL_UNLBL_feature_importance.pdf} \label{fig:polblogs_org_vulnerability_features} } \\ \subfloat[Network: fb-dartmouth (gender)]{ \includegraphics[width=0.33\linewidth]{./images/Features/fb-dartmouth_LBL_UNLBL_feature_importance.pdf} \label{fig:fb-dartmouth_org_vulnerability_features_gender} } & \subfloat[Network: fb-dartmouth (occupation)]{ \includegraphics[width=0.33\linewidth,height=0.25\textheight, keepaspectratio]{./images/Features/fb-dartmouth-oc_LBL_UNLBL_feature_importance.pdf} \label{fig:fb-dartmouth-oc_org_vulnerability_features} } & \subfloat[Network: pokec-1 (gender)]{ \includegraphics[width=0.33\linewidth,height=0.25\textheight, keepaspectratio]{./images/Features/pokec-1_LBL_UNLBL_feature_importance.pdf} \label{fig:pokec-1_org_vulnerability_features} } \\ \subfloat[Network: fb-michigan (gender)]{ \includegraphics[width=0.33\linewidth,height=0.25\textheight, keepaspectratio]{./images/Features/fb-michigan_LBL_UNLBL_feature_importance.pdf} \label{fig:fb-michigan-gender_org_vulnerability_features} } & \subfloat[Network: fb-michigan (occupation)]{ \includegraphics[width=0.33\linewidth,height=0.25\textheight, keepaspectratio]{./images/Features/fb-michigan-oc_LBL_UNLBL_feature_importance.pdf} \label{fig:fb-michigan-oc_org_vulnerability_features} } & \subfloat[Network: amazon-products (category)]{ \includegraphics[width=0.33\linewidth,height=0.25\textheight, keepaspectratio]{./images/Features/amazon-products_LBL_UNLBL_feature_importance.pdf} \label{fig:amazon-products_org_vulnerability_features} } \\ \end{tabular} } \caption{Probability distribution of the feature importance scores across original networks. NDD features are presented in the index order of node (N), hop (H) and bin (B). As an example, the feature \texttt{N1-H2-B1} presents the first bin of the $NDD^2_1[k]$ vector. NAD features are presented in the index order of node (N), hop (H) and binary attribute value $\in {R,B}$. As an example, the feature \texttt{N1-H2-R} presents $NAD^2_1[R]$. Any feature that does not contribute to the final prediction decision with at least $1\%$ of the samples in average is omitted. } \label{fig:vulnerability_features_org} \end{figure*} \section{Introduction} Real graph datasets are fundamental to understanding a variety of phenomena, such as epidemics, adoption of behavior, crowd management and political uprisings. At the same time, many such datasets capturing computer-mediated social interactions are recorded nowadays by individual researchers or by organizations. However, while the need for real social graphs and the supply of such datasets are well established, the flow of data from data owners to researchers is significantly hampered by serious privacy risks: even when humans' identities are removed, studies have proven repeatedly that de-anonymization is doable with high success rate~\cite{narayanan2011link, srivatsa2012deanonymizing, ji2014structure, korula2014efficient}. Such de-anonymization techniques reconstruct user identities using third-party public data and the graph structure of the naively anonymized social network: specifically, the information about one's social ties, even without the particularities of the individual nodes, is sufficient to re-identify individuals. Many anonymization methods have been proposed to mitigate the privacy invasion of individuals from the public release of graph data~\cite{ji2016survey}. Naive anonymization schemes employ methods to scrub identities of nodes without modifying the graph structure. Structural anonymization methods change the topology of the original graph while attempting to preserve (at least some of) the original graph characteristics~\cite{liu2008towards, sala2011sharing,liu2016linkmirage}. Often the utility of an anonymized graph depends not only on preserving essential graph properties of the original graph, but also node attributes such as labels that identify nodes as cheaters or noncheaters in online gaming platforms~\cite{blackburn2014}. However, the effects of node attributes on the risks of re-identifications are not yet well understood. While intuitively any extra piece of information can be a danger to privacy, a rigorous understanding of what topological and attribute properties affect the re-identification risks is needed. In cases such as information dissemination, node attributes may be informed by the local graph topology. \emph{How does the interplay between topology and node attributes affect node privacy?} Our work assesses the additional vulnerability to re-identification attacks posed by the attributes of a labeled graph. We consider exactly one binary attribute to understand the lower bound of the damage that node attributes inflict. We focus our empirical study on the interplay between topology and labeling as a leverage point for re-identification. Because our focus is to understand in which conditions node re-identification is feasible, this study is independent of any anonymization technique. We apply machine learning techniques that use both topological and attribute information to re-identify nodes based on a common threat model. Our study involves real-world graphs and synthetic graphs in which we control how labels are placed relative to ties to mimic the ubiquitous phenomena of homophily found in social graphs~\cite{mcpherson2001}. Our empirical results show that the vulnerability to node re-identification depends on the population diversity with respect to the attribute considered. Using information about the distribution of labels in a node's neighborhood provides additional leverage for the re-identification process, even when labels are rudimentary. Furthermore, we quantify the relative importance of attribute-related and topological features in graphs of different characteristics. The remainder of this paper is organized as follows. Section~\ref{sec:related_work} outlines the related work. The system model to quantify anonymity is presented in Section~\ref{sec:methodology}. Section~\ref{sec:datasets} describes the characteristics of the datasets we used in our empirical investigations. we present our results in Section~\ref{sec:experiments} and discuss our contributions in Section~\ref{sec:discussions}. \section{Methodology} \label{sec:methodology} Our main objective is to quantitatively estimate the vulnerability to re-identification attacks added by node attributes. In particular, we ask: \emph{Given a graph topology, how much better does a node re-identification attack perform when the node attributes are included in the attack compared to when there is no node attribute information available to the attacker?} We are interested in measuring the intrinsic vulnerability of a graph with attributes on nodes, in the absence of any particular anonymization technique on topology or node attributes. The intuition is that particular graphs are inherently more private: for example, in a regular graph, nodes are structurally indistinguishable. Adding attributes to nodes, however, may contribute extra information that could make the re-identification attack more successful. Consider another example, in a highly disassortative network (such as a sexual relationships network), knowing the attribute values (i.e., gender) of a few nodes will quickly lead to correctly inferring the attribute values of the majority of nodes, and thus possibly contributing to the re-identification of more nodes. Thus, the questions we address in this study also include: \emph{How does the distribution of node attributes affect the intrinsic vulnerability to a re-identification attack of a labeled graph topology?} To answer these question, we developed a machine learning-based re-identification attack inspired from that presented in~\cite{Sharad2016benchmark}. We use the same threat model (Section~\ref{sec:threat-model}) that aims at finding a bijective mapping between nodes in two different graphs. We mount a machine-learning based attack (Section~\ref{sec:machine-learning-attack}), in which the algorithm learns the correct mapping between some pairs of nodes from the two graphs, and estimates the mapping of the rest of the dataset. As input data, we use both real and synthetic datasets (as presented in Section~\ref{sec:datasets}). \subsection{The Threat Model} \label{sec:threat-model} The threat model we consider is the classical threat model in this context~\cite{pedarsani2011privacy}: The attacker aims to match nodes from two networks whose edge sets are correlated. We assume each node is associated with a binary valued attribute, and this attribute is publicly available. Common examples of such attributes are gender, professional level (i.e., junior or senior), or education level (i.e., higher education or not). For clarity, consider the following example: an attacker has access to two networks of individuals in an organization that represent the communication patterns (e.g., email) and friendship information available from an online social network. Individuals in the communication network are described by professional seniority (e.g., junior or senior), while individuals in the friendship network are described by gender. These graphs are structurally overlapping, in that some individuals are present in both graphs, even if their identities have been removed. The attacker's task is to find a bijective mapping between the two subsets of nodes in the two graphs that correspond to the individuals present in both networks. \subsection{Machine Learning Attack} \label{sec:machine-learning-attack} We assume that the adversary has a sanitized graph $G_{san}$ that could be associated with an auxiliary graph $G_{aux}$ for the re-identification attack (as depicted in Figure~\ref{fig:graphminingflow}). As in the scenario discussed above, $G_{san}$ could be the communication network, while $G_{aux}$ is the friendship network of a set of individuals in an organization. In order to model this scenario using real data, we split a real dataset graph $G=(V,E)$ into two subgraphs $G_1=(V_1,E_1)$ and $G_2=(V_2,E_2)$, such that $V_1 \subset V$, $V_2 \subset V$ and $V_1 \cap V_2 = V_\alpha$, where $V_\alpha \ne \phi$. The fraction of the overlap $\alpha$ is measured by the Jaccard coefficient of two subsets: $\alpha=\frac{|V_1 \cap V_2|}{|V_1 \cup V_2|}$. In the shared subgraph induced by the nodes in $V_\alpha$, nodes will preserve their edges with nodes from $V_\alpha$ but might have different edges to nodes that are part of $V_1 - V_{\alpha}$ or part of $V_2 - V_{\alpha}$. Each nodes $v \in V_1 \cup V_2$ maintains its original attribute value. In an optimistic scenario, an attacker has access to a part of the original graph (e.g., $G_1$) as auxiliary data and to an unperturbed subgraph (e.g., $G_2$) as the sanitized data whose nodes the attacker wants to re-identify. We use $G_1$ and $G_2$ as baseline graphs to measure the impact of attributes on de-anonymizability of network data. It is also possible to split $G_1$ and $G_2$ recursively into multiple overlapping graphs, maintaining the same values of overlap parameters as above. This allows us to assess the feasibility of the de-anonymization process for large networks by significantly reducing the size of $G_1$ and $G_2$. The resulting graphs are now the equivalent of the email/friendship networks we used as an example above. The overlap is the knowledge repository that the attacker uses for de-anonymization~\cite{henderson2011s}. Part of this knowledge will be made available to the machine learning algorithms. Previous work shows that the larger $\alpha$, the more successful the attack. However, the relative success of attacks under different anonymization schemes is observed to be independent of $\alpha$~\cite{Sharad2016benchmark}. In order to experiment with a homogeneous attack, we set the value of $\alpha=0.2$, and we build $V_\alpha$ by building a breadth-first-search tree starting from the highest degree node (BFS-HD) in $G$. While other alternatives are certainly possible, we chose this approach for two reasons. First, it appears that the threat model we used is quite sensitive to the sampling process when generating $G_1$ and $G_2$~\cite{pedarsani2011privacy}. To avoid sampling bias, we chose a BFS-HD split to have a deterministic set of nodes in $V_\alpha$. Second, we empirically found that BFS-HD provides the maximally informed seeds for an adversary to propagate the re-identification process, thus providing a best-case scenario for the attacker. \begin{figure}[t] \centering \includegraphics[width=1\linewidth]{./images/ml-methodology.pdf} \caption{Graph mining system flow to generate node pairs with the ground truth of identical and non-identical pairs. } \label{fig:graphminingflow} \end{figure} \subsubsection{\textbf{Node Signatures}} \label{sec:node-signatures} Since we are employing machine learning techniques to re-identify nodes in a graph, we need to represent nodes as feature vectors. We define the node $u$'s features using a combination of two vectors made up from its neighborhood degree distribution (NDD) and neighborhood attribute distribution (NAD) (as depicted in Figure \ref{fig:nodesignature}). NDD is a vector of positive integers where $NDD^q_u[k]$ represents the number of $u$'s neighbors at distance $q$ with degree $k$. We concatenate the binned version of $NDD^1_u$ with the binned version of $NDD^2_u$ to define the node $u$'s NDD signature. We use a bin size of $50$, which was shown empirically~\cite{Sharad2016benchmark} to capture the high degree variations of large social graphs. For each $q$, we use $21$ bins, which would correspond to a larger node degree of $1050$. All larger values are binned in the last bin. This binning strategy is designed to capture the aggregate structure of ego networks, which is expected to be robust against edge perturbation~\cite{sharad2016learning}. NAD is defined by $NAD^q_u[i]$ which represents the number of $u$'s neighbors at distance $q$ with an attribute value $i$. It is shown experimentally that the use of neighbor attributes as features often improves the accuracy of edge classification tasks~\cite{mcdowell2013labels}. We use the notation GS to represent the prediction results from the input features made up from the topology (e.g., NDD). GS(LBL) to represent features from both the topology and attribute information (e.g., concatenation of NDD and NAD vectors). \begin{figure}[!t] \centering \includegraphics[width=0.75\linewidth]{./images/NDD_NAD_updated.pdf} \caption{Example of a node signature defined as a combined feature vector made up from NDD and NAD vectors. In the NDD vector, each bin value corresponds to the number of nodes that have a degree value represented in the bin range, such that the $j^{th}$ bin holds the nodes in the degree ($k_j$) range $j\times b \leq k_j < (j+1)\times b$. If the degree exceeds the maximum range, such nodes are included in the last bin. Further, both 1-hop and 2-hop NDDs are calculated and merged. For example, node $x$ has no 1-hop neighbor nodes that have degree in the range of $1-2$, and one 2-hop neighbor node that its degree is in the range of $1-2$. In the NAD vector, each element corresponds to the number of nodes with the given attribute. Both 1-hop and 2-hop NADs are calculated and merged. Node $x$ has one 1-hop neighbor node, and two 2-hop neighbor nodes with the attribute \texttt{Red}. Note that the node value represents the associated degree, and the border color represents the node attribute \texttt{Red} or \texttt{Blue}. } \label{fig:nodesignature} \end{figure} \subsubsection{\textbf{Random Forest Classification}} \label{sec:random-forest-classification} Note that the nodes in $G_{san} \cap G_{aux}$, common to both graphs, can be recognized as being the same node (identical) in the two graphs based on their node identifier. Non-identical nodes are unique to each $G_{san}$ and $G_{aux}$ and would not exist in the overlap. In the classification task, we wish to output 1 for an identical node pair and 0 for a non-identical node pair. This is the ground truth against which we measure the accuracy of the learning algorithms. We generate examples for the training phase of the deanonymization attack by randomly picking node pairs from the sanitized $(G_{san})$ and the auxiliary $(G_{aux})$ graphs, respectively. In most cases, we have an unbalanced dataset with the degree of imbalance depending on the overlap parameter $\alpha$, where the majority is non-identical node pairs. We use the reservoir sampling technique~\cite{haas2016data} to take $\ell=1000$ balance sub-samples from the population $S$, and the SMOTE algorithm~\cite{smote} as an over-sampling technique for each sub-sample. Each sample is trained by a forest of 100 random decision trees that allows the algorithm to learn features. Gini-index is used as an impurity measure for the random forest classification. Given the size $\alpha$ of the overlap, we measure the quality of the classifier on the task of differentiating two nodes as identical or not. \subsubsection{Metrics} \label{sec:metrics} We measure the accuracy of the classifier in determining whether a randomly chosen pair of nodes (with one node in $G_{san}$ and another in $G_{aux}$) are identical or not. We use F1-score to evaluate the quality of the classifier. F1-score is the harmonic mean between precision and recall, typical metrics for prediction output of machine learning algorithms. For each data sample, we perform $5\times2$ cross-validation to evaluate the classifier and record the mean F1-score. We thus build two vectors of mean F1-scores, each of size $\ell=1000$ (as described above), one for the labeled (GS(LBL)) and one for the unlabeled network topology (GS). An important aspect of these vectors is that they are related in the sense that the $i^{th}$ element in one vector represents the same sample as the $i^{th}$ element of the other vector. This is important for the pairwise comparison of the two mean F1-score vectors. We perform a standard T-test on these two vectors and report the T-statistic value. The T-statistic value is a measure of how close to the hypothesis an estimated value is. In our case, the hypothesis is the prediction accuracy of the node identities in the unlabeled graph (GS) and the estimated value is the prediction accuracy in the labeled graph (GS(LBL)). Thus, a large T-statistic value implies a significantly better prediction accuracy of node identities in GS(LBL) than in GS. In such cases, we can say that the network with node attributes is more vulnerable to node re-identification. This value serves as our statistical measurement to quantify the vulnerability cost of node attributes. \section{Related Work} \label{sec:related_work} The availability of auxiliary data helps reveal the true identities of anonymized individuals, as proven empirically in large privacy violation incidents~\cite{NetflixScandal,griffith2005messin}. Similarly, in the case of graph de-anonymization attacks, information from an auxiliary graph is used to re-identify the nodes in an anonymized graph~\cite{narayanan2009anonymizing}. The quality of such an attack is determined by the rate of correct re-identification of the original nodes in the network. In general, de-anonymization attacks harness structural characteristics of nodes that uniquely distinguish them~\cite{ji2016survey}. Many such attacks can be categorized into \emph{seed-based} and \emph{seed-free}, based on the prior seed knowledge available to an attacker~\cite{ji2016survey}. In seed-based attacks, sybil nodes~\cite{backstrom2007wherefore} or some known mappings of nodes in an auxiliary graph aid the re-identification of anonymized nodes~\cite {narayanan2011link, srivatsa2012deanonymizing, ji2014structure, ji2016general, korula2014efficient}. The effectiveness of such attacks is influenced by the quality of the seeds~\cite{Sharad2016benchmark}. In seed-free attacks, the problem of deanonymization is usually modeled as a graph matching problem. Several research efforts have proposed statistical models for the re-identification of nodes without relying on seeds, such as the Bayesian model~\cite{pedarsani2013bayesian} or optimization models~\cite{ji2014structural, ji2016structuralsf}. Many heuristics are used in the propagation process of re-identification, exploiting graph characteristics such as degree~\cite{gulyas2016efficient}, k-hop neighborhood~\cite{yartseva2013performance}, linkage-covariance~\cite{aggarwal2011hardness}, eccentricity~\cite{narayanan2009anonymizing}, or community~\cite{nilizadeh2014community}. Recently, there have been efforts to incorporate node attribute information into deanonymization attacks. Gong et al.~\cite{gong2014joint} evaluate the combination of structural and attribute information on link prediction models. Attributes not present may be inferred through prior knowledge and network homophily. Qian et al.~\cite{qian2016anonymizing} apply link prediction and attribute inference to deanonymization by quantifying the prior background information of an attacker using knowledge graphs. In knowledge graphs, edges not only represent links between nodes but also node-attribute links and link relationships among attributes. The deanonymization attack in~\cite{JiMittal2016De-SAG} maps node-attribute links between an anonymized graph and its auxiliary. In addition to structural similarity, nodes are matched by attribute difference, the union of the attributes of the node in the anonymized and auxiliary divided by their intersection. However, the success rate of a de-anonymization process is often reported in the literature as dependent on the chosen heuristic of the attack, which is typically designed with knowledge of the anonymization technique. Comparing the strengths of different anonymization techniques thus becomes challenging, if not impossible. Recently, Sharad~\cite{Sharad2016benchmark} proposed a general threat model to measure the quality of a deanonymization attack which is independent of the anonymization scheme. He proposed a machine learning framework to benchmark perturbation-based graph anonymization schemes. This framework explores the hidden invariants and similarities to re-identify nodes in the anonymized graphs~\cite{sharad2013anonymizing, sharad2014automated}. Importantly, this framework can be easily tuned to model various types of attacks. Several researchers propose theoretical frameworks to examine how vulnerable or deanonymizable any (anonymized) graph dataset is, given its structure~\cite{pedarsani2011privacy,ji2014structural, ji2015your, ji2016relative}. However, some techniques are based on Erd{\"o}s-R{\`e}nyi (ER) models~\cite{pedarsani2011privacy}, while others make impractical assumptions about the seed knowledge~\cite{ji2015your}. Ji et al.~\cite{ji2016relative} also introduced a configuration model to quantify the deanonymizablity of graph datasets by considering the topological importance of nodes. The same set of authors analyzed the impact of attributes on graph data anonymity~\cite{JiMittal2016De-SAG}. They show a significant loss of anonymity when more node-attribute relations are shared between anonymized and auxiliary graph data. Specifically, they measure the entropy present in node-attribute mappings available for an attacker. As the entropy decreases, the graph loses node anonymity. The main aspects distinguishing this study from existing works are as follows: i) In our work, we study the inherent conditions in graphs that provide resistance/vulnerability to a general node re-identification attack based on machine learning techniques. ii) To the best of our knowledge, this is the first work that quantifies the privacy impact of node attributes under an attribute attachment model biased towards homophily. iii) We analyze the interplay between the intrinsic vulnerability of the graph structure and attribute information.
\section{Introduction} {As reported by WHO, cancer has caused a very large number of deaths, approximately 8.8 million deaths in 2015 \cite{WHOstat}. Almost 20\% or 1.69 million deaths are due to {\em lung cancer}\cite{WHOstat}. Cancer screening plays an important role in preventive care because cancer is most treatable when caught in the early stages. The study shows that the appearances of the malignant lung nodules more commonly demonstrate a spiculated contour, lobulation, and inhomogeneous attenuation \cite{PulmonaryNodule}. \indent Presently, low dose computed tomography (LDCT) plays an important role in screening lung cancer \cite{RuralAreas}. LDCT screening has reduced lung cancer deaths and is recommended for high-risk demographics \cite{RuralAreas}. Results from LDCT screening may be further evaluated with standard dose computed tomography (CT) \cite{CTscan}. However, there are many barriers to implementing LDCT screening, such as providers' anxiety on the access to LDCT equipment and potential financial burdens in rural populations \cite{RuralAreas}. Moreover, rural populations have limited access to both primary care physicians and specialists \cite{RuralAreas}. On the other hand, chest x-rays are readily available in rural areas. Nonetheless, chest x-rays produce lower quality images compared to LDCT or CT scans and, therefore, a lower quality diagnosis is generally expected. This study explores the use of chest x-rays with a computer-aided diagnosis (CADx) system to improve lung cancer diagnostic performance. \indent The convolutional neural network (CNN) is proven to be very effective in image recognition and classification tasks. The development of CNNs starts from, LeNet \cite{LeNet}, AlexNet \cite{AlexNet}, ZFNet \cite{ZFNet}, VGG \cite{VGG}, Inception \cite{Inceptionv1} \cite{Inceptionv23}, ResNet \cite{ResNet}, Inception-ResNet \cite{InceptionResNet}, Xception \cite{Xception}, DenseNet \cite{DenseNet}, and NASNet \cite{NASNet}. There are many studies on the use of CNNs to detect abnormalities in chest x-rays using the deep convolutional neural network. For instance, M. T. Islam et al., \cite{AbnormDetection} used several CNNs to detect abnormalities in chest x-rays. There is also a study, by X. Wang et al., on using a couple of CNNs to detect thoracic pathologies from chest x-ray images. This study also provides a large dataset that was used in our study \cite{ChestX-ray14}. Among the research, there are some studies about applying Densely Connected Convolutional Networks (DenseNet) \cite{DenseNet} to detect thoracic pathologies such as ChexNet \cite{ChexNet} and the Attention Guided Convolutional Neural Network (AG-CNN) \cite{AGCNN}. Both studies trained the neural network on a very large chest x-ray image dataset. \indent Lung cancer prediction with CNN faces the small sample size problem. Indeed, CNN contains a large number of parameters to be adjusted on large image dataset. In practice, researchers often pre-trained CNNs on {\em ImageNet}, a standard image dataset containing more than one million images. Then, the trained CNNs are adjusted on a specific target image dataset. Unfortunately, the available lung cancer image dataset is too small for this transfer learning to be effective, even with a data augmentation trick. To alleviate this problem, we proposed the idea of applying transfer learning several times to gradually improve the performance of the model. In this work, the transfer learning is applied twice. The first time is to transfer the model from general image domain into chest x-ray domain. The second time is to transfer the model to lung cancer. This multi-transfer learning can solve the small sample size problem and achieves a better result on the task compared to the traditional transfer learning technique. Furthermore, we also show that it is possible to modify the model to compute heatmap showing the predicted position of lung cancer in the chest x-ray image.} \section{Methodology} {In this section, the methodology of our study is discussed. First a description of the datasets used in the study is given, followed by a description the data preparation process. Consequently, an explanation is given of the model architecture and the loss function, and finally the visualizing process.} \subsection{Datasets} \subsubsection{JSRT Dataset \cite{JSRT}} {This public dataset from JSRT (Japanese Society of Radiological Technology) consists of 247 frontal chest x-ray images, of which 154 images have lung nodules (100 malignant cases, 54 benign cases) and 93 are images without lung nodules. All images have a size of $2048\times 2048$ pixels. Since, this dataset is very small, a 10-fold cross-validation was performed to increase reliability on the performance. Malignant cases were used as positive cases, while both benign and non-nodule cases were used as negative cases. Data were randomly split into the training, validation, and test set, with the ratio shown in Table \ref{table: 1}.} \subsubsection{ChestX-ray14 Dataset \cite{ChestX-ray14}} {This public dataset released by Wang et al. \cite{ChestX-ray14} contains 112,120 frontal chest x-ray images, currently the largest public chest x-ray dataset. Each image is individually labeled with up to 14 different thoracic pathology labels. All images have a size of $1024\times 1024$ pixels. However, this dataset does not contain any lung cancer images. The fourteen thoracic pathology labels consist of Atelectasis, Consolidation, Infiltration, Pneumothorax, Edema, Emphysema, Fibrosis, Effusion, Pneumonia, Pleural Thickening, Cardiomegaly, Nodule, Mass, and Hernia. It was decided to use this dataset to compensate the lung cancer data that has only 100 cases, by first training for the recognition of nodules, using nodule cases as positive and all remaining cases (non-nodule) as negative. Data were randomly split into the training, validation, and test set, without having any overlap of patients between the data sets, as shown in Table \ref{table: 1}.} \begin{table} \caption{Training-Validation-Test split for each dataset} \label{table: 1} \centering \begin{tabular}{cccc} \hline & Training & Validation & Test\\ \hline JSRT Dataset & 80 & 10 & 10\\ \hline ChestX-ray14 Dataset & & &\\ Positive cases & 4992 & 1024 & 266\\ Negative cases & 103907 & 1024 & 266\\ Total & 108899 & 2048 & 532\\ \hline\hline \end{tabular} \end{table} \subsection{Data Preparation} {Data preparation was applied to all the images. It consists of four steps as follows: \begin{itemize} \item Step 1: increasing the contrast of all images using Histogram Equalization. This allows normalizing the intensity of images from different datasets. \item Step 2: removing the noise from all images using Median Filtering with a window size of $3\times 3$. \item Step 3: resizing images to $224\times 224$ pixels to match the input of the model used in this study. \item Step 4: normalizing image color based on mean and standard deviation of the ImageNet training set \cite{ImageNet}. \end{itemize} An example of the image after processing in each step is shown in Fig. \ref{Fig1}.} \begin{figure} \includegraphics[width=1.0\linewidth]{new_fig1.pdf} \centering \caption{Illustration of Data Preparation process on example image from JSRT dataset.} \label{Fig1} \end{figure} \subsection{CNN architecture and transfer learning} {Among all the convolutional neural networks architectures like Inception \cite{Inceptionv1} \cite{Inceptionv23}, ResNet \cite{ResNet}, DenseNet \cite{DenseNet}, the model we used in this research is the 121-layer Densely Connected Convolutional Networks (DenseNet-121). This convolutional neural network has the dense blocks architecture that improves the flow of the data along the network, and also solves the problem of vanishing gradient found in very deep neural networks. This CNN also performs very well on many public datasets including ImageNet \cite{DenseNet}. The original model processes an input image of size $224\times 224$ pixels and outputs posterior probabilities for 1000 categories of object. In this work, the last fully connected layer of this CNN was replaced by a single sigmoid node in order to output the probability of having the specified pathology. {Due to the small dataset problem, we considered transfer learning. However, as the lung cancer dataset is truly small, transfer learning was applied more than usual. Specifically, in this study, it was applied twice. The first transfer learning allowed the classification of chest x-ray images as "with nodule" or "without nodule". The second allowed the classification of chest x-ray images as "with malignant nodule" and "without malignant nodule" (including both chest x-rays with benign nodules and those without nodules). Through the training process, the model became more specific to the lung cancer task. The overall training process and the model used in each step is described below and in Fig. \ref{Fig3}, overleaf: \begin{figure} \includegraphics[width=0.9\linewidth]{Pic3.pdf} \centering \caption{The training process and the model in use including Base Model, Retrained Model A, B, or C, along with the data used to train each model.} \label{Fig3} \end{figure} \begin{itemize} \item Base Model: DenseNet-121 with the initial weight from pretrained model on ImageNet training set that has the last fully connected layer modified to 1 class of sigmoid activation function. \item Retrained Model A: Retrained Base Model with the least validation loss from the ChestX-ray14 validation set. Base Model was retrained using the ChestX-ray14 training set, as shown in Table \ref{table: 1}, where positive cases were chest x-ray images with nodules and negative cases are the chest x-ray images without nodules. The training images were randomly flipped horizontally. \item Retrained Model B: Retrained Base Model with the least validation loss from the JSRT validation set. The Base Model was retrained using the JSRT training set, as shown in Table \ref{table: 1}, along with a 10-fold cross-validation. The training images were randomly rotated by the angle within 30 degrees and randomly flipped horizontally. Positive cases were chest x-ray images with malignant nodules, while negative cases were chest x-ray images without malignant nodules. \item Retrained Model C: Retrained Model A with the least validation loss from the JSRT validation set. Due to the fact that the positive cases of the JSRT dataset are all nodules, the Retrained Model A, (which already had the ability to classify "nodule" from "non-nodule", a task similar to the lung cancer classification task) was retrained to identify malignant vs. non-malignant nodules. The JSRT training set was used to retrain the model. All the JSRT training images used to retrain the model were randomly rotated within 30 degrees and randomly flipped horizontally. \end{itemize} \indent The basic idea for the training of Model C is as follows: First, DenseNet-121 was trained on the ImageNet dataset to gain basic knowledge about images in general. Next, the model was retrained on the ChestX-ray14 dataset to adjust this knowledge to chest x-ray images with additional information about lung nodules. As the size of the ChestX-ray14 dataset is much larger than the JSRT dataset, transferring knowledge to the chest x-ray domain first allows better adaptation of the CNN that has been trained on a general images dataset. Model A can be considered as a chest x-ray specialist. Additionally, as lung nodules are very similar to lung cancer, Model A is ready to be adjusted using the JSRT dataset. Experimentally, we have found that Model C shows the best performance compared to single-step transfer learning (i.e. Model B). This underlines the effectiveness of the proposed strategy. \subsection{Loss and optimizer} \indent {The two transfer learnings involve imbalanced binary classification datasets. To counteract this problem, the following weighted binary classification loss was used: \begin{eqnarray} L(X,y)&=&-\omega_+ \cdot y\log p (Y=1|X)\notag\\&&-\omega_- \cdot (1-y) \log p (Y=0|X), \end{eqnarray} where $X$ is the image and $y$ is the real label of the image which is labeled 0 if being a negative case, or 1 if being a positive case, $p(Y=i|X)$ is the predicted probability of having label $i$. $\omega$ is the weight applied on the loss to make the training process more efficient, $\omega_+$ is the number of negative cases per all cases and $\omega_-$ is the number of positive cases per all cases.} \indent {Adam (adaptive moment estimation) optimizer \cite{Adam} was used in this work with the standard parameter setting, i.e. $\beta_{1} = 0.9$ and $\beta_{2} = 0.999$. The initial learning rate was 0.001 and decreased by a factor of 10 when validation loss plateaued. The batch size was 32.} \subsection{Class Activation Mappings (CAMs)} Class Activation Mappings (CAMs) \cite{CAMs} can be derived from Model C to show the most salient location on the image that the model used to identify the output class. This is done using the following equation: \begin{eqnarray} M_c=\sum_{k}w_{c,k}f_k. \end{eqnarray} From equation (2), $M_c$ is the map that shows the most salient features on the image that the model used to classify classes. $w_{c,k}$ is the weight in the last fully connected layer of the feature map $k$ leading to class $c$ and $f_k$ is the $k$th feature map. \begin{table*} \caption{The name of retrained model, dataset used, purpose, accuracy, specificity, and sensitivity of Retrained Model A, B, and C on tasks} \label{table: 2} \centering \begin{tabular}{cccccc} \hline Retrained Model & Dataset used & Purpose & Accuracy & Specificity & Sensitivity\\ \hline A & ChestX-ray14 & to recognize lung nodules & 84.02\% & 85.34\% & 82.71\%\\ B & JSRT & to recognize lung cancer & $65.51\pm 7.67$\% & $80.95\pm 20.59$\% & $45.67\pm 21.36$\%\\ C & ChestX-ray14 and JSRT & to recognize lung cancer & $74.43\pm 6.01$\% & $74.96\pm 9.85$\% & $74.68\pm 15.33$\%\\ \hline\hline \end{tabular} \end{table*} \section{Results and Discussion} \begin{figure} \includegraphics[width=0.9\linewidth]{Picture2.pdf} \centering \caption{Images of malignant cases from JSRT dataset, before and after illustrate Class Activation Maps on using Retrained Model C.} \label{Fig2} \end{figure} {The performance of the model in this study was evaluated using accuracy, specificity, and sensitivity. The accuracy shows the degree to which the model correctly identified both positive and negative cases. The specificity shows the degree to which the model correctly identified negative cases and sensitivity shows the degree to which the model correctly identified positive cases. By having high accuracy, specificity and sensitivity, it can be implied that the model has low error. The performance of Model A on classifying lung nodules was evaluated for accuracy, specificity and sensitivity using a test set of the ChestX-ray14 Dataset as shown in Table \ref{table: 2}. The threshold of Model A is 0.55 as it gives highest sum between specificity and sensitivity. The performance of Model B and Model C on classifying lung cancer were likewise evaluated using the average and standard deviation of accuracy, specificity and sensitivity using a test set of the JSRT dataset in each fold of a 10-fold cross-validation as shown in Table \ref{table: 2}. The threshold of both models is 0.5.} {As shown in Table \ref{table: 2}, Model A, which was trained to recognize lung nodule, after being pretrained on the ImageNet dataset, performed efficiently on the test set of the ChestX-ray14 dataset. Next, Model B resulted in higher specificity but poorer in both accuracy and sensitivity than Model C. In addition, Model C also has lower standard deviation in all evaluation metrics. The result shows that by retraining the model several times for specific tasks gives better results in almost all metrics.} {In Fig.\ref{Fig2}, left hand images are the original images while the right hand images are processed images, using CAMs to show the salient location on the image, with the blue circle corresponding to the actual location of lung cancer on the image, identified by information received with the JSRT images. Model C can show accurate CAMs in most of the correctly predicted images such as (a) and (b), but some images show too large an area over the actual location or show an inaccurate area. The reason is that the model still overfits the training set slightly due to the size of the dataset. On the other hand, CAMs illustrated by Model B do not show the accurate position of lung cancer and often show that the model used too large an area on the image to classify lung cancer.} \section{Conclusion} {To conclude, the performance of the densely connected convolutional network on detecting lung cancer from chest x-ray images was explored. Since the dataset was too small to train the convolutional neural network, was proposed a strategy to train the deep convolutional neural network using a very small dataset. The strategy was to train the model several times, having the model learn about the final task step-by-step, which in this case, starts from the use of general images in the ImageNet dataset, followed by identifying nodules from chest x-rays in ChestX-ray14 dataset, and finally identifying lung cancer from nodules in the JSRT dataset. The proposed training strategy performed better than the normal transfer learning method, which resulted in higher mean accuracy and mean sensitivity but poorer mean specificity, as well as a lower standard deviation. The region used to classify images, was illustrated using CAMs in Model C, showing quite accurate locations of lung cancer, although some do not due to the overfit problem. However, CAMs from Retrained Model B are much poorer. Therefore, it can be concluded that the proposed method can solve the problem of a small dataset.} \newline \indent {For future work, the data augmentation can be additionally performed by randomly adding Gaussian Noise, and randomly cropping the image. The idea of Attention-Guided Convolutional Neural Network (AG-CNN) \cite{AGCNN} can also be used to crop the nodule part from the full image and use its real size to identify the malignancy, since the appearance of malignant nodules is different from benign nodules. Additionally, more features such as family history, and smoking rate can be applied in training along with images for more accuracy. The ensemble of several convolutional neural networks can further improve the results.} \bibliographystyle{IEEEtran} \section{Introduction} {As reported by WHO, cancer has caused a very large number of deaths, approximately 8.8 million deaths in 2015 \cite{WHOstat}. Almost 20\% or 1.69 million deaths are due to {\em lung cancer}\cite{WHOstat}. Cancer screening plays an important role in preventive care because cancer is most treatable when caught in the early stages. The study shows that the appearances of the malignant lung nodules more commonly demonstrate a spiculated contour, lobulation, and inhomogeneous attenuation \cite{PulmonaryNodule}. \indent Presently, low dose computed tomography (LDCT) plays an important role in screening lung cancer \cite{RuralAreas}. LDCT screening has reduced lung cancer deaths and is recommended for high-risk demographics \cite{RuralAreas}. Results from LDCT screening may be further evaluated with standard dose computed tomography (CT) \cite{CTscan}. However, there are many barriers to implementing LDCT screening, such as providers' anxiety on the access to LDCT equipment and potential financial burdens in rural populations \cite{RuralAreas}. Moreover, rural populations have limited access to both primary care physicians and specialists \cite{RuralAreas}. On the other hand, chest x-rays are readily available in rural areas. Nonetheless, chest x-rays produce lower quality images compared to LDCT or CT scans and, therefore, a lower quality diagnosis is generally expected. This study explores the use of chest x-rays with a computer-aided diagnosis (CADx) system to improve lung cancer diagnostic performance. \indent The convolutional neural network (CNN) is proven to be very effective in image recognition and classification tasks. The development of CNNs starts from, LeNet \cite{LeNet}, AlexNet \cite{AlexNet}, ZFNet \cite{ZFNet}, VGG \cite{VGG}, Inception \cite{Inceptionv1} \cite{Inceptionv23}, ResNet \cite{ResNet}, Inception-ResNet \cite{InceptionResNet}, Xception \cite{Xception}, DenseNet \cite{DenseNet}, and NASNet \cite{NASNet}. There are many studies on the use of CNNs to detect abnormalities in chest x-rays using the deep convolutional neural network. For instance, M. T. Islam et al., \cite{AbnormDetection} used several CNNs to detect abnormalities in chest x-rays. There is also a study, by X. Wang et al., on using a couple of CNNs to detect thoracic pathologies from chest x-ray images. This study also provides a large dataset that was used in our study \cite{ChestX-ray14}. Among the research, there are some studies about applying Densely Connected Convolutional Networks (DenseNet) \cite{DenseNet} to detect thoracic pathologies such as ChexNet \cite{ChexNet} and the Attention Guided Convolutional Neural Network (AG-CNN) \cite{AGCNN}. Both studies trained the neural network on a very large chest x-ray image dataset. \indent Lung cancer prediction with CNN faces the small sample size problem. Indeed, CNN contains a large number of parameters to be adjusted on large image dataset. In practice, researchers often pre-trained CNNs on {\em ImageNet}, a standard image dataset containing more than one million images. Then, the trained CNNs are adjusted on a specific target image dataset. Unfortunately, the available lung cancer image dataset is too small for this transfer learning to be effective, even with a data augmentation trick. To alleviate this problem, we proposed the idea of applying transfer learning several times to gradually improve the performance of the model. In this work, the transfer learning is applied twice. The first time is to transfer the model from general image domain into chest x-ray domain. The second time is to transfer the model to lung cancer. This multi-transfer learning can solve the small sample size problem and achieves a better result on the task compared to the traditional transfer learning technique. Furthermore, we also show that it is possible to modify the model to compute heatmap showing the predicted position of lung cancer in the chest x-ray image.} \section{Methodology} {In this section, the methodology of our study is discussed. First a description of the datasets used in the study is given, followed by a description the data preparation process. Consequently, an explanation is given of the model architecture and the loss function, and finally the visualizing process.} \subsection{Datasets} \subsubsection{JSRT Dataset \cite{JSRT}} {This public dataset from JSRT (Japanese Society of Radiological Technology) consists of 247 frontal chest x-ray images, of which 154 images have lung nodules (100 malignant cases, 54 benign cases) and 93 are images without lung nodules. All images have a size of $2048\times 2048$ pixels. Since, this dataset is very small, a 10-fold cross-validation was performed to increase reliability on the performance. Malignant cases were used as positive cases, while both benign and non-nodule cases were used as negative cases. Data were randomly split into the training, validation, and test set, with the ratio shown in Table \ref{table: 1}.} \subsubsection{ChestX-ray14 Dataset \cite{ChestX-ray14}} {This public dataset released by Wang et al. \cite{ChestX-ray14} contains 112,120 frontal chest x-ray images, currently the largest public chest x-ray dataset. Each image is individually labeled with up to 14 different thoracic pathology labels. All images have a size of $1024\times 1024$ pixels. However, this dataset does not contain any lung cancer images. The fourteen thoracic pathology labels consist of Atelectasis, Consolidation, Infiltration, Pneumothorax, Edema, Emphysema, Fibrosis, Effusion, Pneumonia, Pleural Thickening, Cardiomegaly, Nodule, Mass, and Hernia. It was decided to use this dataset to compensate the lung cancer data that has only 100 cases, by first training for the recognition of nodules, using nodule cases as positive and all remaining cases (non-nodule) as negative. Data were randomly split into the training, validation, and test set, without having any overlap of patients between the data sets, as shown in Table \ref{table: 1}.} \begin{table} \caption{Training-Validation-Test split for each dataset} \label{table: 1} \centering \begin{tabular}{cccc} \hline & Training & Validation & Test\\ \hline JSRT Dataset & 80 & 10 & 10\\ \hline ChestX-ray14 Dataset & & &\\ Positive cases & 4992 & 1024 & 266\\ Negative cases & 103907 & 1024 & 266\\ Total & 108899 & 2048 & 532\\ \hline\hline \end{tabular} \end{table} \subsection{Data Preparation} {Data preparation was applied to all the images. It consists of four steps as follows: \begin{itemize} \item Step 1: increasing the contrast of all images using Histogram Equalization. This allows normalizing the intensity of images from different datasets. \item Step 2: removing the noise from all images using Median Filtering with a window size of $3\times 3$. \item Step 3: resizing images to $224\times 224$ pixels to match the input of the model used in this study. \item Step 4: normalizing image color based on mean and standard deviation of the ImageNet training set \cite{ImageNet}. \end{itemize} An example of the image after processing in each step is shown in Fig. \ref{Fig1}.} \begin{figure} \includegraphics[width=1.0\linewidth]{new_fig1.pdf} \centering \caption{Illustration of Data Preparation process on example image from JSRT dataset.} \label{Fig1} \end{figure} \subsection{CNN architecture and transfer learning} {Among all the convolutional neural networks architectures like Inception \cite{Inceptionv1} \cite{Inceptionv23}, ResNet \cite{ResNet}, DenseNet \cite{DenseNet}, the model we used in this research is the 121-layer Densely Connected Convolutional Networks (DenseNet-121). This convolutional neural network has the dense blocks architecture that improves the flow of the data along the network, and also solves the problem of vanishing gradient found in very deep neural networks. This CNN also performs very well on many public datasets including ImageNet \cite{DenseNet}. The original model processes an input image of size $224\times 224$ pixels and outputs posterior probabilities for 1000 categories of object. In this work, the last fully connected layer of this CNN was replaced by a single sigmoid node in order to output the probability of having the specified pathology. {Due to the small dataset problem, we considered transfer learning. However, as the lung cancer dataset is truly small, transfer learning was applied more than usual. Specifically, in this study, it was applied twice. The first transfer learning allowed the classification of chest x-ray images as "with nodule" or "without nodule". The second allowed the classification of chest x-ray images as "with malignant nodule" and "without malignant nodule" (including both chest x-rays with benign nodules and those without nodules). Through the training process, the model became more specific to the lung cancer task. The overall training process and the model used in each step is described below and in Fig. \ref{Fig3}, overleaf: \begin{figure} \includegraphics[width=0.9\linewidth]{Pic3.pdf} \centering \caption{The training process and the model in use including Base Model, Retrained Model A, B, or C, along with the data used to train each model.} \label{Fig3} \end{figure} \begin{itemize} \item Base Model: DenseNet-121 with the initial weight from pretrained model on ImageNet training set that has the last fully connected layer modified to 1 class of sigmoid activation function. \item Retrained Model A: Retrained Base Model with the least validation loss from the ChestX-ray14 validation set. Base Model was retrained using the ChestX-ray14 training set, as shown in Table \ref{table: 1}, where positive cases were chest x-ray images with nodules and negative cases are the chest x-ray images without nodules. The training images were randomly flipped horizontally. \item Retrained Model B: Retrained Base Model with the least validation loss from the JSRT validation set. The Base Model was retrained using the JSRT training set, as shown in Table \ref{table: 1}, along with a 10-fold cross-validation. The training images were randomly rotated by the angle within 30 degrees and randomly flipped horizontally. Positive cases were chest x-ray images with malignant nodules, while negative cases were chest x-ray images without malignant nodules. \item Retrained Model C: Retrained Model A with the least validation loss from the JSRT validation set. Due to the fact that the positive cases of the JSRT dataset are all nodules, the Retrained Model A, (which already had the ability to classify "nodule" from "non-nodule", a task similar to the lung cancer classification task) was retrained to identify malignant vs. non-malignant nodules. The JSRT training set was used to retrain the model. All the JSRT training images used to retrain the model were randomly rotated within 30 degrees and randomly flipped horizontally. \end{itemize} \indent The basic idea for the training of Model C is as follows: First, DenseNet-121 was trained on the ImageNet dataset to gain basic knowledge about images in general. Next, the model was retrained on the ChestX-ray14 dataset to adjust this knowledge to chest x-ray images with additional information about lung nodules. As the size of the ChestX-ray14 dataset is much larger than the JSRT dataset, transferring knowledge to the chest x-ray domain first allows better adaptation of the CNN that has been trained on a general images dataset. Model A can be considered as a chest x-ray specialist. Additionally, as lung nodules are very similar to lung cancer, Model A is ready to be adjusted using the JSRT dataset. Experimentally, we have found that Model C shows the best performance compared to single-step transfer learning (i.e. Model B). This underlines the effectiveness of the proposed strategy. \subsection{Loss and optimizer} \indent {The two transfer learnings involve imbalanced binary classification datasets. To counteract this problem, the following weighted binary classification loss was used: \begin{eqnarray} L(X,y)&=&-\omega_+ \cdot y\log p (Y=1|X)\notag\\&&-\omega_- \cdot (1-y) \log p (Y=0|X), \end{eqnarray} where $X$ is the image and $y$ is the real label of the image which is labeled 0 if being a negative case, or 1 if being a positive case, $p(Y=i|X)$ is the predicted probability of having label $i$. $\omega$ is the weight applied on the loss to make the training process more efficient, $\omega_+$ is the number of negative cases per all cases and $\omega_-$ is the number of positive cases per all cases.} \indent {Adam (adaptive moment estimation) optimizer \cite{Adam} was used in this work with the standard parameter setting, i.e. $\beta_{1} = 0.9$ and $\beta_{2} = 0.999$. The initial learning rate was 0.001 and decreased by a factor of 10 when validation loss plateaued. The batch size was 32.} \subsection{Class Activation Mappings (CAMs)} Class Activation Mappings (CAMs) \cite{CAMs} can be derived from Model C to show the most salient location on the image that the model used to identify the output class. This is done using the following equation: \begin{eqnarray} M_c=\sum_{k}w_{c,k}f_k. \end{eqnarray} From equation (2), $M_c$ is the map that shows the most salient features on the image that the model used to classify classes. $w_{c,k}$ is the weight in the last fully connected layer of the feature map $k$ leading to class $c$ and $f_k$ is the $k$th feature map. \begin{table*} \caption{The name of retrained model, dataset used, purpose, accuracy, specificity, and sensitivity of Retrained Model A, B, and C on tasks} \label{table: 2} \centering \begin{tabular}{cccccc} \hline Retrained Model & Dataset used & Purpose & Accuracy & Specificity & Sensitivity\\ \hline A & ChestX-ray14 & to recognize lung nodules & 84.02\% & 85.34\% & 82.71\%\\ B & JSRT & to recognize lung cancer & $65.51\pm 7.67$\% & $80.95\pm 20.59$\% & $45.67\pm 21.36$\%\\ C & ChestX-ray14 and JSRT & to recognize lung cancer & $74.43\pm 6.01$\% & $74.96\pm 9.85$\% & $74.68\pm 15.33$\%\\ \hline\hline \end{tabular} \end{table*} \section{Results and Discussion} \begin{figure} \includegraphics[width=0.9\linewidth]{Picture2.pdf} \centering \caption{Images of malignant cases from JSRT dataset, before and after illustrate Class Activation Maps on using Retrained Model C.} \label{Fig2} \end{figure} {The performance of the model in this study was evaluated using accuracy, specificity, and sensitivity. The accuracy shows the degree to which the model correctly identified both positive and negative cases. The specificity shows the degree to which the model correctly identified negative cases and sensitivity shows the degree to which the model correctly identified positive cases. By having high accuracy, specificity and sensitivity, it can be implied that the model has low error. The performance of Model A on classifying lung nodules was evaluated for accuracy, specificity and sensitivity using a test set of the ChestX-ray14 Dataset as shown in Table \ref{table: 2}. The threshold of Model A is 0.55 as it gives highest sum between specificity and sensitivity. The performance of Model B and Model C on classifying lung cancer were likewise evaluated using the average and standard deviation of accuracy, specificity and sensitivity using a test set of the JSRT dataset in each fold of a 10-fold cross-validation as shown in Table \ref{table: 2}. The threshold of both models is 0.5.} {As shown in Table \ref{table: 2}, Model A, which was trained to recognize lung nodule, after being pretrained on the ImageNet dataset, performed efficiently on the test set of the ChestX-ray14 dataset. Next, Model B resulted in higher specificity but poorer in both accuracy and sensitivity than Model C. In addition, Model C also has lower standard deviation in all evaluation metrics. The result shows that by retraining the model several times for specific tasks gives better results in almost all metrics.} {In Fig.\ref{Fig2}, left hand images are the original images while the right hand images are processed images, using CAMs to show the salient location on the image, with the blue circle corresponding to the actual location of lung cancer on the image, identified by information received with the JSRT images. Model C can show accurate CAMs in most of the correctly predicted images such as (a) and (b), but some images show too large an area over the actual location or show an inaccurate area. The reason is that the model still overfits the training set slightly due to the size of the dataset. On the other hand, CAMs illustrated by Model B do not show the accurate position of lung cancer and often show that the model used too large an area on the image to classify lung cancer.} \section{Conclusion} {To conclude, the performance of the densely connected convolutional network on detecting lung cancer from chest x-ray images was explored. Since the dataset was too small to train the convolutional neural network, was proposed a strategy to train the deep convolutional neural network using a very small dataset. The strategy was to train the model several times, having the model learn about the final task step-by-step, which in this case, starts from the use of general images in the ImageNet dataset, followed by identifying nodules from chest x-rays in ChestX-ray14 dataset, and finally identifying lung cancer from nodules in the JSRT dataset. The proposed training strategy performed better than the normal transfer learning method, which resulted in higher mean accuracy and mean sensitivity but poorer mean specificity, as well as a lower standard deviation. The region used to classify images, was illustrated using CAMs in Model C, showing quite accurate locations of lung cancer, although some do not due to the overfit problem. However, CAMs from Retrained Model B are much poorer. Therefore, it can be concluded that the proposed method can solve the problem of a small dataset.} \newline \indent {For future work, the data augmentation can be additionally performed by randomly adding Gaussian Noise, and randomly cropping the image. The idea of Attention-Guided Convolutional Neural Network (AG-CNN) \cite{AGCNN} can also be used to crop the nodule part from the full image and use its real size to identify the malignancy, since the appearance of malignant nodules is different from benign nodules. Additionally, more features such as family history, and smoking rate can be applied in training along with images for more accuracy. The ensemble of several convolutional neural networks can further improve the results.} \bibliographystyle{IEEEtran}
\section{Introduction} \label{sec:intro1} Tropical mathematics has found many applications in both pure and applied areas, as documented by a growing number of monographs on its interactions with various other areas of mathematics: algebraic geometry \cite{baker2016nonarchimedean,gross2011tropical,huh2016tropical,maclagan2015introduction}, discrete event systems \cite{baccelli1992synchronization, butkovivc2010max}, large deviations and calculus of variations \cite{kolokoltsov1997idempotent,puhalskii2001large}, and combinatorial optimization \cite{joswig2014essentials}. At the same time, new applications are emerging in phylogenetics \cite{lin2018tropical,yoshida2017tropical,page2020tropical}, statistics \cite{hook2017max}, economics \cite{baldwin2013tropical,crowell2016tropical,elsner2004max,gursoy2013analytic,joswig2017cayley,shiozawa2015international,tran2013pairwise,tran2015product}, game theory, and complexity theory \cite{allamigeon2018log,akian2012tropical}. There is a growing need for a systematic study of probability distributions in tropical settings. Over the classical algebra, the Gaussian measure is arguably the most important distribution to both theoretical probability and applied statistics. In this work, we review the existing analogues of the Gaussian measure in the tropical semiring. We focus on the three main characterizations of the classical Gaussians central to statistics: invariance under orthonormal transformations, independence and orthogonality, and stability. We show that some notions do not yield satisfactory generalizations, others yield the classical geometric or exponential distributions, while yet others yield completely different distributions. There is no single notion of a `tropical Gaussian measure' that would satisfy multiple tropical analogues of the different characterizations of the classical Gaussians. This is somewhat expected, for the interaction between geometry and algebra over the tropical semiring is rather different from that over $\R$. Different branches of tropical mathematics lead to different notions of a tropical Gaussian, and it is a worthy goal to fully explore all the options. We conclude with various research directions. \section{Three Characterizations of the classical Gaussian} \label{sec:intro} The Gaussian measure $\mathcal{N}(\mu,\Sigma)$, also called the normal distribution with mean $\mu \in \R^n$ and covariance $\Sigma \in \R^{n \times n}$ is the probability distribution with density $$ f_{\Sigma,\mu}(x) \propto \exp(-\frac{1}{2}(x-\mu)^\top \Sigma^{-1} (x-\mu)), \quad x \in \R^n. $$ Let $\mathbf{I}$ denote the identity matrix, and $\mathbf{0} \in \R^n$ the zero vector. Measures $\mathcal{N}(\mathbf{0},\Sigma)$ are called centered Gaussians, while $\mathcal{N}(\mathbf{0},\mathbf{I})$ is the standard Gaussian. Any Gaussian can be standardized by an affine linear transformation. \begin{lemma}\label{lem:standard} Let $\Sigma = U\Lambda U^\top$ be the eigendecomposition of $\Sigma$. Then $X \sim \mathcal{N}(\mu,\Sigma)$ if and only if $(U\Lambda^{1/2})^{-1}(X-\mu) \sim \mathcal{N}(\mathbf{0},\mathbf{I})$. \end{lemma} The standard Gaussian has two important properties. First, if $X$ is a standard Gaussian in $\R^n$, then its coordinates $X_1, \dots, X_n$ are $n$ independent and identically distributed (i.i.d) random variables. Second, for any orthonormal matrix $A$, $AX \stackrel{d}{=} X$. These two properties completely characterize the standard Gaussian \cite[Proposition 11.2]{kallenberg2006foundations}. This result was first formalized in dimension three by Maxwell \cite{maxwell1860v} when he studied the distribution of gas particles, though the essence of his argument was made by Herschel \cite{herschel1850quetelet} ten years earlier, as pointed out in \cite[p10]{bryc2012normal}. \begin{theorem}[Maxwell] \label{thm:maxwell} Let $X_1, \dots, X_n$ be i.i.d univariate random variables, where $n \geq 2$. Then the distribution of $X = (X_1, \dots, X_n)$ is spherically symmetric iff the $X_i$'s are centered Gaussians on $\R$. \end{theorem} From a statistical perspective, Lemma \ref{lem:standard} and Theorem \ref{thm:maxwell} reduces working with data from the Gaussian measure to doing linear algebra. In particular, if data points come from a Gaussian measure, then they are the affine linear transformation of data points from a standard Gaussian, whose coordinates are always independent regardless of the orthonormal basis that it is represented in. These properties are fundamental to Principal Component Analysis, an important statistical technique whose tropical analogue is actively being studied \cite{yoshida2017tropical}. There are numerous other characterizations of the Gaussian measure whose ingredients are only orthogonality and independence, see \cite[\S 1.9]{bogachev1998gaussian} and references therein. One famous example is Kac's theorem \cite{kac1939characterization}. It is a special case of the Darmois-Skitovich theorem \cite{darmois1953analyse,skitovitch1953property}, which characterizes Gaussians (not necessarily centered) in terms of independence of linear combinations. A multivariate version of this theorem is also known, see \cite{kagan1973characterization}. \begin{theorem}[Darmois-Skitovich] Let $X_1, \dots, X_n$ be independent univariate random variables. Then the $X_i$'s are Gaussians if and only if there exist $\alpha,\beta \in \R^n$, $\alpha_i,\beta_i \neq 0$ for all $i = 1, \dots, n$, such that $\sum_i\alpha_iX_i$ and $\sum_i\beta_iX_i$ are independent. \end{theorem} Another reason for the wide applicability of Gaussians in statistics is the Central Limit Theorem. An interesting historical account of its development can be found in \cite[\S 4]{kallenberg2006foundations}. From the Central Limit Theorem, one can derive yet other characterizations of the Gaussian, such as the distribution which maximizes entropy subject to a fixed variance \cite{barron1986entropy}. The appearance of the Gaussian in the Central Limit Theorem is fundamentally linked to its characterization as the unique $2$-stable distribution. This is expressed in the following theorem by P\'olya \cite{polya1923herleitung}. There are a number of variants of this theorem, see \cite{bogachev1998gaussian,bryc2012normal} and discussions therein. \begin{theorem}[P\'olya] Suppose $X,Y \in \R^n$ are independent random variables. Then $X,Y$ and $(X+Y)/\sqrt{2}$ have the same distribution iff this distribution is the centered Gaussian. \end{theorem} \section{Tropical analogues of Gaussians} \subsection{Tropicalizations of $p$-adic Gaussians}\label{sec:local.fields} Evans \cite{evans2001local} used Kac's Theorem as the definition of Gaussians to extend them to local fields. Local fields are finite algebraic extensions of either the field of $p$-adic numbers or the field of formal Laurent series with coefficients drawn from the finite field with $p$ elements \cite{evans2001local}. In particular, local fields come with a tropical valuation $\val$, and thus one can define a tropical Gaussian to be the tropicalization of the Gaussian measure on a local field. A direct translation of \cite[Theorem 4.2]{evans2001local} shows that the tropicalization of the one-dimensional $p$-adic Gaussian is the classical geometric distribution. \begin{proposition}[Tropicalization of the $p$-adic Gaussian]\label{lem:p-adic} For a prime $p \in \mathbb{N}$, let $X$ be a $\mathbb{Q}_p$-valued Gaussian with index $k \in \mathbb{Z}$. Then $\val(X)$ is a random variable supported on $\{k, k+1, k+2, \dots\}$, and it is distributed as $k + \emph{geometric}(1-p^{-1})$. That is, $$ \mathbb{P}(\val(X) = k+s) = p^{-s}(1-p^{-1}) \mbox{ for } s = 0, 1, 2, \dots. $$ \end{proposition} \begin{proof} Recall that a non-zero rational number $r \in \mathbb{Q} \backslash \{0\}$ can be uniquely written as $r = p^s(a/b)$ where $a$ and $b$ are not divisible by $p$, in which case the valuation of $r$ is $|r| := p^{-s}$. The completion of $\mathbb{Q}$ under the metric $(x,y) \mapsto |x-y|$ is the field of $p$-adic numbers, denoted $\mathbb{Q}_p$. The tropical valuation of $r$ is $\val(r) := s$. By \cite[Theorem 4.2]{evans2001local}, the family of $\mathbb{Q}_p$-valued Gaussians is indexed by $\mathbb{Z}$. For each $k \in \mathbb{Z}$, there is a unique $\mathbb{Q}_p$-valued Gaussian supported on the ball $p^k\mathbb{Z}_p := \{x \in \mathbb{Q}_p: |x| \leq p^{-k}\}$. Furthermore, the Gaussian is the normalized Haar measure on this support. As $p^k\mathbb{Z}_p$ is made up of $p$ translated copies of $p^{k+1}\mathbb{Z}_p$, which in turn is made up of $p$ translated copies of $p^{k+2}\mathbb{Z}_p$, a direct computation yields the density of $\val(X)$. \end{proof} There is a large and growing literature surrounding probability on local fields, or more generally, analysis on ultrametric spaces. They have found diverse applications, from spin glasses, protein dynamics, and genetics, to cryptography and geology; see the recent comprehensive review \cite{dragovich2017p} and references therein. The $p$-adic Gaussian was originally defined as a step towards building Brownian motions on $\mathbb{Q}_p$ \cite{evans2001local}. It would be interesting to use tools from tropical algebraic geometry to revisit and expand results involving random $p$-adic polynomials, such as the expected number of zeroes in a random $p$-adic polynomial system \cite{MR2266718}, or properties of determinants of matrices with i.i.d $p$-adic Gaussians \cite{evans2002elementary}. Previous work on random $p$-adic polynomials from a tropical perspective tends to consider systems with uniform valuations \cite{avendano2011multivariate}. Lemma \ref{lem:p-adic} hints that to connect the two literatures, the geometric distribution may be more suitable. \subsection{Gaussians via tropical linear algebra} Consider arithmetic done in the tropical algebra $(\overline\R,\oplus,\odot)$, where $\overline{\R}$ is $\R$ together with the additive identity. In the max-plus algebra $(\overline\R,\overline{\oplus},\odot)$ where $a \overline{\oplus} b = \max(a,b)$, for instance, $\overline{\R} = \R \cup \{-\infty\}$. In the min-plus algebra $(\overline\R,\underline{\oplus},\odot)$ where $a \underline{\oplus} b = \min(a,b)$, we have $\overline{\R} = \R \cup \{+\infty\}$. To avoid unnecessary technical details, in this section we focus on vectors taking values in $\R$ instead of $\overline{\R}$. Tropical linear algebra was developed by several communities with different motivations. It evolved as a linearization tool for certain problems in discrete event systems, queueing theory and combinatorial optimization; see the monographs \cite{baccelli1992synchronization,butkovivc2010max}, as well as the recent survey \cite{komenda2018max} and references therein. A large body of work focuses on using the tropical setting to find analogous versions of classical results in linear algebra and convex geometry. Many fundamental concepts have rich tropical analogues, including the spectral theory of matrices \cite{akian2006max,baccelli1992synchronization,butkovivc2010max}, linear independence and projectors \cite{AlGK09,akian2011best,butkovivc2007generators,sergeev2009multiorder}, separation and duality theorems in convex analysis \cite{briec2008halfspaces,cohen2004duality,gaubert2011minimal,nitica2007max}, matrix identities \cite{gaubert1996burnside,hollings2012tropical,morrison2016tropical,simon1994semigroups}, matrix rank \cite{chan20114,develin2005rank,izhakian2009tropical,shitov2011example}, and tensors \cite{butkovic2018tropical,tsukerman2015tropical}. Another research direction focuses on the combinatorics of objects arising in tropical convex geometry, such as polyhedra and hyperplane arrangements \cite{akian2012tropical,develin2004tropical,joswig2016weighted,joswig2007affine,sturmfels2012combinatorial,tran2017enumerating}. These works have close connections to matroid theory and are at the interface of tropical linear algebra and tropical algebraic geometry \cite{ardila2009tropical,fink2015stiefel,giansiracusa2017grassmann,hampe2015tropical,loho2018matching}. Despite the rich theory of tropical linear algebra, in this section we shall show that there is currently no satisfactory way to define the tropical Gaussian as a classical probability measure based on the characterizations of Gaussians via orthogonality and independence as in Section \ref{sec:intro}. This is somewhat surprising, for there are good analogues of norms and orthogonal decomposition in the tropical algebra. In hindsight, the main difficulty stems from the fact that such tropical analogues are compatible with tropical arithmetic, while classical measure theory was developed with the usual algebra. In Section \ref{sec:k} we consider the idempotent probability measure theory, where there is a well-defined Gaussian measure complete with a quadratic density function analogous to the classical case. The natural definition for tropical linear combinations of $v_1,\dots,v_m \in \R^n$ is the set of vectors of the form \begin{equation}\label{[v]} [v_1,\dots,v_m] := \{a_1 \odot v_1 \oplus \dots \oplus a_m \odot v_m \mbox{ for } a_1, \dots, a_m \in \R\}, \end{equation} where scalar-vector multiplication is defined pointwise. That is, for $a \in \R$ and $v \in \R^n$, $a \odot v \in \R^n$ is the vector with entries $$ (a \odot v)_i = a + v_i \mbox{ for } i = 1,\dots,n. $$ We shall also write $a + v$ for $a \odot v$, with the convention scalar-vector addition is defined pointwise. For finite $m$, $V := [v_1,\dots,v_m]$ is always a compact set in $\mathbb{TP}^{n-1} := \R^n / \R \mathbf{1}$ \cite{develin2004tropical}. Unfortunately, this means one cannot hope to have finitely many vectors to `tropically span' $\R^m$. Nonetheless, there is a well-defined analogue orthogonal projection in the tropical algebra. Associated to a tropical polytope $V := [v_1,\dots,v_m]$ defined by \eqref{[v]} is the canonical projector $P_V: \R^n \to V$ that plays the role of the orthogonal projection onto $V$ \cite{cohen2004duality}. This projection is compatible with the projective Hilbert metric $d_H$ \cite{cohen2000hahn,cohen2004duality}, in the sense that $P_V(x)$ is a best-approximation under the projective Hilbert metric of $x$ by points in $V$ \cite{cohen2004duality,akian2011best}. When $V$ is a polytrope, that is, a tropical polytope that is also classically convex, then $P_V$ can be written as a tropical matrix-vector multiplication. This is analogous to classical linear algebra, where best-approximations in the Euclidean distance can be written as a matrix-vector multiplication. In the max-plus algebra, the projective Hilbert metric is defined by $$ d_H(x,y) = \max_{i,j\in[n]}(x_i-y_i+y_j-x_j). $$ It induces the Hilbert projective norm $\|\cdot\|_H: \R^m \to \R$ via $\|x\|_H = d_H(x,0).$ Since $d_H(x,y) = \max_i(x_i-y_i) - \min_j(x_j-y_j)$, one finds that $$ \|x\|_H = \|x - \min_i x_i\|_\infty. $$ This formulation shows that the projective Hilbert norm plays the role of the $\ell_\infty$-norm on~$\mathbb{TP}^{n-1}$. The appearance of $\ell_\infty$, instead of $\ell_2$, agrees with the conventional `wisdom' that generally in the tropical algebra, $\ell_2$ is replaced by $\ell_\infty$ \cite{evans2001local}. To generalize Maxwell's characterization of the classical Gaussians, we need a concept of orthogonality. One could attempt to mimic orthogonality via the orthogonal decomposition theorem, as done in \cite{evans2001local} for the case of local fields discussed in Section \ref{sec:local.fields}. Namely, over a normed space $(\mathcal{Y},\|\cdot\|)$ over some field $K$, say that $y_1, \dots, y_m \in \mathcal{Y}$ are orthogonal if and only if for all $\alpha_i \in K$, the norm of the vector $\sum_i\alpha_iy_i$ equals the norm of the vector $(|\alpha_1|\|y_1\|,\dots,|\alpha_m|\|y_m\|)$, that is, \begin{equation}\label{eqn:orthogonal} \| \sum_i\alpha_iy_i \| = \|(|\alpha_1|\|y_1\|,\dots,|\alpha_m|\|y_m\|)\|. \end{equation} In the Euclidean case, this is the Pythagorean identity $$ \|\sum_i\alpha_iy_i\|_2 = (\sum_i|\alpha_i|^2\|y_i\|^2)^{1/2}, $$ for example. The $\ell_\infty$-norm, unfortunately, does not work well with the usual notion of independence in probability. In the Hilbert projective norm, (\ref{eqn:orthogonal}) can be interpreted either as \begin{equation}\label{eqn:first} \|\max_i(\alpha_i + y_i)\|_H = \max_i\|\alpha_i+y_i\|_H - \min_i\|\alpha_i+y_i\|_H = \max_i\|y_i\|_H - \min_i\|y_i\|_H \end{equation} or \begin{equation}\label{eqn:second} \|\max_i(\alpha_i + y_i)\|_H = \max_i(\alpha_i + \|y_i\|_H) - \min_i (\alpha_i + \|y_i\|_H). \end{equation} Unfortunately, neither formulation give a satisfactory notion of orthogonality. In \eqref{eqn:first}, as the norm is projective, the coefficients $\alpha_i$ have disappeared from the RHS. This does not support the notion that over an orthogonal set of vectors in the classical sense, computing the norm of linear combinations is the same as computing norm of the vector of coefficients. In \eqref{eqn:second}, for sufficiently large $\alpha_1$, the RHS increases without bound whereas the LHS is bounded, and thus equality cannot hold for all $\alpha_i \in \R$ over \emph{any} generating set of $y_i$'s. The Darmois-Skitovich characterization for Gaussians also does not generalize well. Note that the additive identity in $(\overline{\R},\oplus,\odot)$ is either $-\infty$ or $+\infty$, so the condition that $\alpha_i,\beta_i \neq 0$ becomes redundant. The following lemma states that the any compact distribution will satisfy the Darmois-Skitovich condition. \begin{lemma} Let $X_1,\dots,X_n$ be independent random variables on $\R^n$. Then there exist $\alpha,\beta \in \R^n$ such that $\displaystyle\bigoplus_{i=1}^n\alpha_i\odot X_i$ and $\displaystyle\bigoplus_{i=1}^n\beta_i\odot X_i$ are independent if and only if $X_1, \dots, X_n$ have compact support. \end{lemma} \begin{proof} Let us sketch the proof for $n = 2$ under the min-plus algebra. Let $X = (X_1,X_2) \in \R^2$ and $Y = (Y_1,Y_2) \in \R^2$ be two independent variables. Define $\overline{F}_X, \overline{F}_Y: \R^2 \to [0,1]$ via $\overline{F}_X(t) = \P(X \geq t)$ and $\overline{F}_Y(t) = \P(Y \geq t).$ Fix $\alpha,\beta \in \R^2$. For $t \in \R^2$, \begin{align*} \P(\alpha_1\odot X \oplus \alpha_2 \odot Y \geq t) &= \P(\min(\alpha_1+X,\alpha_2+Y) \geq t) \mbox{ by definition } \\ &= \P(X \geq t-\alpha_1)\P(Y \geq t-\alpha_2) \mbox{ by independence} \\ &= \overline{F}_X(t-\alpha_1)\overline{F}_Y(t-\alpha_2). \end{align*} Meanwhile, \begin{align*} & \P(\alpha_1\odot X \oplus \alpha_2 \odot Y \geq t, \beta_1\odot X \oplus \beta_2 \odot Y \geq t) \\ =&\, \P(\min(\alpha_1+X,\alpha_2+Y) \geq t, \min(\beta_1+X,\beta_2+Y) \geq t) \mbox{ by definition} \\ =&\, \P(X \geq t-\alpha_1, X \geq t-\beta_1)\P(Y \geq t-\alpha_2, Y \geq t-\beta_2) \mbox{ by independence} \\ =& \, \min(\overline{F}_X(t-\alpha_1), \overline{F}_X(t-\beta_1)) \min(\overline{F}_Y(t-\alpha_2), \overline{F}_Y(t-\beta_2)). \end{align*} Therefore, for $\alpha_1\odot X \oplus \alpha_2 \odot Y$ and $\beta_1\odot X \oplus \beta_2 \odot Y$ to be independent, for all $t \in \R^2$, we need \begin{align*} &\overline{F}_X(t-\alpha_1)\overline{F}_X(t-\beta_1)\overline{F}_Y(t-\alpha_2)\overline{F}_Y(t-\beta_2) \\ =& \min(\overline{F}_X(t-\alpha_1), \overline{F}_X(t-\beta_1)) \min(\overline{F}_Y(t-\alpha_2), \overline{F}_Y(t-\beta_2))\cdot \\ &\max(\overline{F}_X(t-\alpha_1), \overline{F}_X(t-\beta_1)) \max(\overline{F}_Y(t-\alpha_2), \overline{F}_Y(t-\beta_2))\\ =& \min(\overline{F}_X(t-\alpha_1), \overline{F}_X(t-\beta_1)) \min(\overline{F}_Y(t-\alpha_2), \overline{F}_Y(t-\beta_2)). \end{align*} But $\overline{F}_X$ and $\overline{F}_Y$ are non-increasing functions taking values between $0$ and $1$. So $$\overline{F}_X(t-\alpha_1)\overline{F}_X(t-\beta_1)\overline{F}_Y(t-\alpha_2)\overline{F}_Y(t-\beta_2) \leq \min(\overline{F}_X(t-\alpha_1), \overline{F}_X(t-\beta_1)) \min(\overline{F}_Y(t-\alpha_2), \overline{F}_Y(t-\beta_2)),$$ and equality holds if and only if $$ \min(\overline{F}_X(t-\alpha_1), \overline{F}_X(t-\beta_1)) = 0, \mbox{ or } \min(\overline{F}_Y(t-\alpha_2), \overline{F}_Y(t-\beta_2)) = 0. $$ As either of these scenarios must hold for each $t \in \R^2$, we conclude that $X$ and $Y$ must have compact supports. Conversely, suppose that $X$ and $Y$ have compact supports. Then one can choose $\alpha_1 = \beta_2 = 0$ and $\alpha_2 = \beta_1$ be a sufficiently large number, so that $$ \alpha_1\odot X \oplus \alpha_2 \odot Y = X, \mbox{ and } \beta_1\odot X \oplus \beta_2 \odot Y = Y. $$ In this case, the Darmois-Skitovich condition holds trivially, as desired. \end{proof} Now consider Polya's condition. Here the Gaussian is characterized via stability under addition. When addition is replaced by minimum, it is well-known that this leads to the classical exponential distribution. One such characterization, which generalizes to distributions on arbitrary lattices, is the following \cite[Theorem 3.4.1]{bryc2012normal}. \begin{theorem} Suppose $X,Y$ are independent and identically distributed nonnegative random variables. Then this distribution is the exponential if and only if for all $a,b > 0$ such that $a+b=1$, $\min(X/a,Y/b)$ has the same distribution as $X$. \end{theorem} By considering $\log(X)$ and $\log(Y)$, one could restate this theorem in terms of the min-plus algebra, though the condition $a+b=1$ does not have an obvious tropical interpretation. This shows that the tropical analogue of Gaussian is the classical exponential distribution. \subsection{Gaussians in idempotent probability}\label{sec:k} Idempotent probability is a branch of idempotent analysis, which is functional analysis over idempotent semirings \cite{kolokoltsov1997idempotent}. Idempotent semirings are characterized by the additive operation being idempotent, that is, $a \oplus a = a$. The tropical semirings used in the previous sections are idempotent, but there are others, such as the Boolean semiring in semigroup theory. Idempotent analysis was developed by Litvinov, Maslov and Shipz \cite{litvinov1998linear} in relation to problems of calculus of variations. Closely related are the work on large deviations \cite{puhalskii2001large}, which has found applications in queueing theory, as well as fuzzy measure theory and logic \cite{dubois2012fundamentals,wang2013fuzzy}. The work we discussed in this section is based on that of Akian, Quadrat and Viot and co-authors \cite{akian2011best,akian1994bellman}, whose goal was to develop idempotent probability as a theory completely in parallel to classical probability. Following their convention, we work over the min-plus algebra. All fundamental concepts of probability have an idempotent analogue, see \cite{akian1994bellman} and references therein. For a flavor of this theory, we compare the concept of a measure. In classical settings, a probability measure $\mu$ is a map from the $\sigma$-algebra on a space $\Omega$ to $\R_{\geq 0}$ that satisfies three properties: (i) $\mu(\emptyset) = 0$, (ii) $\mu(\Omega) = 1$, and (iii) for a countable sequence $(E_i)$ of pairwise disjoint sets, $$ \mu(\bigcup_{i=1}^\infty E_i) = \sum_{i=1}^\infty\mu(E_i). $$ The analogous object in the min-plus probability is the cost measure $\mathbb{K}$ defined by three axioms: (i) $\mathbb{K}(\emptyset) = +\infty$, (ii) $\mathbb{K}(\Omega) = 0$, and $$ \mathbb{K}(\bigcup_iE_i) = \bigoplus_i \mathbb{K}(E_i) = \inf_i \mathbb{K}(E_i). $$ Idempotent probability is rich and has interesting connections with dynamic programming and optimization. For instance, tropical matrix-vector multiplication can be interpreted as an update step in a Markov chain, so the Bellman equation plays the analogue of the Kolmogorov-Chapman equation. Most notably, the classical quadratic form~$(x-y)^2/2\sigma^2$ defines a stable distribution \cite{akian1994bellman}. Furthermore, it is the unique density that is invariant under the Legendre-Fenchel transform \cite{akian1994bellman}, which is the tropical analogue of the Fourier transform \cite{kolokoltsov1997idempotent}. This is in parallel to the characterization of the scaled version of the Gaussian density $x \mapsto \exp(-\pi x^2)$ being invariant under the Fourier transform. While $x \mapsto \exp(-\pi x^2)$ is not the unique function to possess this property \cite{duffin1948function}, the fact that the Fourier transform of a $\mathcal{N}(\mu,\sigma^2)$ univariate Gaussian has the form $x \mapsto \exp(i\mu x - \frac{x^2}{2})$ is frequently employed to prove independence of linear combinations of Gaussians. Under this light, one can regard the idempotent measure correspond to the density $(x-y)^2/2\sigma^2$ to be the idempotent analogue of the classical Gaussian. \section{Open directions} \subsection{Tropical curves, metric graphs and Gaussians via the Laplacian operator} From the perspective of stochastic analysis, the Gaussian measure can be characterized as the unique invariant measure for the Ornstein-Uhlenbeck semigroup \cite[\S 1]{bogachev1998gaussian}. This semigroup is a powerful tool in proving hypercontractivity and log-Sobolev inequalities. In particular, the Gaussian density can be characterized as the function that satisfies such inequalities with the best constants \cite{bogachev1998gaussian}. One useful characterization of the Ornstein-Uhlenbeck semigroup is by its generator, whose definition has two ingredients: a Laplacian operator and a gradient operator $\nabla$. Let us elaborate. Let $\gamma$ be a centered Gaussian measure on $\R^n$. The Ornstein-Uhlenbeck semigroup $(T_t,t\geq 0)$ is defined on $L^2(\gamma)$ by the Mehler formula $$ T_th(x) = \int_{\R^n} h(e^{-t}x + \sqrt{1-e^{-2t}}y)\, \gamma(dy), \quad t > 0 $$ and $T_0$ is the identity operator. It characterizes the Gaussian measure in the following sense \cite[\S 1]{bogachev1998gaussian}. \begin{lemma} $\gamma$ is the unique invariant probability measure for $(T_t,t \geq 0)$. \end{lemma} One can arrive at this semigroup without the Mehler's formula as follows. Let $\mathcal{D} = \{h \in L^2(\gamma): \lim_{t \to 0} \frac{T_t h - h}{t} \mbox{ exists in the norm of } L^2(\gamma)\}$. (Recall that $L^2(\gamma)$ is the space of square integrable functions with respect to the measure $\gamma$). The linear operator $L$ defined on $\mathcal{D}$ by $$ Lh = \lim_{t \to 0} \frac{T_t h - h}{t} $$ is called the generator of the semigroup $(T_t, t \geq 0)$. The generator of the Ornstein-Uhlenbeck semigroup is given by $$ Lh (x) = \Delta h (x) - \langle x, \nabla h \rangle = \sum_{i=1}^n \frac{\partial^2 h}{\partial x_i^2}(x) - \sum_{i=1}^n x_i \frac{\partial h}{\partial x_i}(x). $$ This generator uniquely specifies the semigroup. Importantly, the two ingredients needed to define $L$ are the Laplacian operator $\Delta$, and the gradient operator $\nabla$. Thus the semigroup can be defined on Riemannian manifolds, for instance. This opens up ways to define Gaussians on tropical curves. In tropical algebraic geometry, an abstract tropical curve is a metric graph \cite{mikhalkin2008tropical}. There are some minor variants: with vertex weights \cite{brannetti2011tropical,chan2012tropical}, or just the compact part \cite{baker2006metrized}. An embedded tropical curve is a balanced weighted one-dimensional complex in $\R^n$. There are several constructions of tropical curves. In particular, they arise as limits of amoebas through a process called Maslov dequantization in idempotent analysis \cite{litvinov1998linear}. Tropical algebraic geometry took off with the landmark paper of Mikhalkin \cite{mikhalkin2005enumerative}, who used tropical curves to compute Gromov-Witten invariants of the plane $\mathbb{P}^2$ \cite{maclagan2015introduction}. Since then, tropical curves, and more generally, tropical varieties, have been studied in connection to mirror and symplectic geometry \cite{gross2011tropical}. Another heavily explored aspect of tropical curves is their divisors and Riemann-Roch theory \cite{baker2007riemann,baker2016nonarchimedean,gathmann2008riemann,mikhalkin2008tropical}. This theory is connected to chip-firing and sandpiles, which were initially conceived as deterministic models of random walks on graphs \cite{cooper2006simulating}. Metric graphs are Riemannian manifolds with singularities \cite{baker2006metrized}. Brownian motions defined on metric graphs, heat semigroups on graphs, and graph Laplacians are an active research area \cite{kostrykin2012brownian,post2008spectral}. As of now, however, the author is unaware of an analogue of the Ornstein-Uhlenbeck semigroup and its invariant measure on graphs. It would also be interesting to study what Brownian motion on graphs reveals about tropical curves and their Jacobians. \subsection{Further open directions} The natural ambient space for doing tropical convex geometry is not $\R^m$, but $\mathbb{TP}^{n-1}$, where a vector $x \in \R^m$ is identified with all of its scalar multiples $a \odot x$. Probability theory on classical projective spaces relies on group representation \cite{benoist2014random}. Unfortunately, there is no satisfactory tropical analogue of the general linear group. Every invertible $n \times n$ matrix with entries in $\overline{\R}$ is the composition of a diagonal matrix and a permutation of the standard basis of $\overline{\R}^n$ \cite{kolokoltsov1997idempotent}. We note that several authors have studied tropicalization of special linear group over a field with valuation \cite{joswig2007affine,werner2011tropical}. It would be interesting to see whether this can be utilized to define probability measures on $\mathbb{TP}^{n-1}$. Another approach is to `fix' the main difficulty with the idempotent algebra, namely, the lack of the additive inverse. Some authors have put back the additive inverse and developed a theory of linear algebra in this new algebra, called the supertropical algebra \cite{izhakian2008supertropical}. It would be interesting to study matrix groups and their actions under this algebra, and in particular, pursue the definition of Gaussians as invariant measures under actions of the orthogonal group. \subsection{Beyond Gaussians} In a more applied direction, $\mathbb{TP}^{n-1}$ is a natural ambient space to study problems in economics, network flow and phylogenetics. Thus one may want an axiomatic approach to finding distributions on $\mathbb{TP}^{n-1}$ tailored for specific applications. For instance, in shape-constrained density estimation, log-concave multivariate totally positive of ordered two (MTP2) distributions are those whose density $f: \R^d \to \R$ is log-concave and satisfies the inequality $$ f(x)f(y) \leq f(x \vee y)f(x \wedge y) \mbox{ for all } x,y \in \R^d. $$ A variety of distributions belong to this family. Requiring that such inequalities hold for all $x,y \in \mathbb{TP}^{n-1}$ leads to the stronger condition of $L^\natural$-concavity $$ f(x)f(y) \leq f((x+\alpha\mathbf{1}) \vee y)f(x \wedge (y-\alpha \mathbf{1})) \mbox{ for all } x,y \in \R^d, \alpha \geq 0. $$ A Gaussian distribution is log-concave MTP2 if and only if the inverse of its covariance matrix is an $M$-matrix \cite{lauritzen2019maximum}. Only diagonally dominant Gaussians are $L^\natural$-concave \cite[\S 2]{murota2003discrete}. This subclass of densities has nice properties that make them algorithmically tractable in Gaussian graphical models \cite{walk_summable,LBP_inverse_M}. In particular, density estimation for $L^\natural$-concave distributions is significantly easier than for log-concave MTP2 \cite{robeva2018maximum}. It would be interesting to pursue this direction to define distributions on the space of phylogenetic trees. \bibliographystyle{alpha}
\section*{Introduction} Let $M$ be a differentiable manifold with local coordinates $u^1, \ldots, u^n.$ The induced coordinate system of the tangent manifold $TM$ consists of the functions $x^1, \ldots, x^n$ and $y^1, \ldots, y^n$. For any $v\in T_pM$, $x^i(v)=u^i\circ \pi(v)$ and $y^i(v)=v(u^i)$, where $\pi \colon TM\to M$ is the canonical projection, $i=1, \ldots, n$. Introducing the so-called Liouville vector field $\displaystyle{C:=y^i\partial/\partial y^i}$, it can be easily seen that the integral curves of $C$ are of the form $e^tv$ for any nonzero $v\in TM$. If the function $f\colon TM\to \mathbb{R}$ is differentiable on the complement of the zero section such that $f(tv)=t^kf(v)$ for any positive $t\in \mathbb{R}$, then we have that $$C(v)f=\frac{d}{dt}\left(f(e^tv)\right)_{t=0}=kf(v)$$ and vice versa. This means that the function $f$ is positively homogeneous of degree $k$ if and only if $Cf=kf$. It is the so-called Euler's theorem on homogeneous functions. A Finsler metric \cite{BSC} is a continuous function $F\colon TM\to \mathbb{R}$ satisfying the following conditions: $\displaystyle{F}$ is smooth on the complement of the zero section (regularity), $\displaystyle{F(tv)=tF(v)}$ for all $\displaystyle{t> 0}$ (positive homogenity) and the Hessian $\displaystyle{g_{ij}=\partial^2 E /\partial y^i \partial y^j}$, where $E=\frac{1}{2}F^2$, is positive definite at all nonzero elements $\displaystyle{v\in TM}$ (strong convexity). A linear connection $\nabla$ on the base manifold $M$ is called \emph{compatible} to the Finslerian metric if the parallel transports with respect to $\nabla$ preserve the Finslerian length of tangent vectors. Finsler manifolds admitting compatible linear connections are called generalized Berwald manifolds. It can be easily seen \cite{VKMO} that a linear connection $\nabla$ on the base manifold $M$ is compatible to the Finslerian metric function if and only if the induced horizontal distribution is conservative, i.e. the derivatives of the fundamental function $F$ vanish along the horizontal directions with respect to $\nabla$: \begin{equation} \label{cond1} \frac{\partial F}{\partial x^i}-y^j {\Gamma}^k_{ij}(x) \frac{\partial F}{\partial y^k}=0\ \ (i=1, \ldots,n), \end{equation} where ${\Gamma}^k_{ij}(x)$'s are the connection parameters and the vector fields of type $\displaystyle{\partial/\partial x^i-y^j {\Gamma}^k_{ij}(x) \partial/\partial y^k}$ span the associated horizontal distribution belonging to $\nabla$. Equation (\ref{cond1}) is called the \emph{compatibility equation}. The concept of generalized Berwald manifolds goes back to V. Wagner \cite{Wag1}. For a summary of the recent trends and some general results in the theory of generalized Berwald manifolds see \cite{V11}. To express the compatible linear connection in terms of the canonical data of the Finsler manifold is the problem of the intrinsic characterization we are going to solve in some special cases of locally symmetric $m$-th root metrics. Especially, we are interested in generalized Berwald surfaces with locally symmetric fourth root metrics. The main result (Theorem 1) is their intrinsic characterization in terms of the basic notions of linear algebra. We present a one-parameter family of examples as well. The last section contains some computations in 3D. They are supported by the MAPLE mathematics softwer (LinearAlgebra). \section{Locally symmetric $m$-rooth metrics} \begin{Def} Let $m=2l$ be a positive natural number, $l=1, 2, \ldots. $ A Finslerian metric $F$ is called an $m$-th root metric if its $m$-th power $F^m$ is of class $C^{m}$ on the tangent manifold $TM$. \end{Def} Using that $F$ is positively homogeneous of degree one, its $m$-th power is homogeneous of degree $m$. Since it is of class $C^m$ on the tangent manifold $TM$ (including the zero section), its local form must be a polynomial of degree $m$ in the variables $y^1$, $\ldots$, $y^n$ as follows: \begin{equation} \label{polgen} F^m(x,y)=\sum_{i_1+\ldots+i_n=m} a_{i_1 \ldots i_n}(x)(y^1)^{i_1}\cdot \ldots (y^n)^{i_n}. \end{equation} Finslerian metrics of the form (\ref{polgen}) has been introduced by Shimada \cite{Shim}. They are generalizations of the so-called Berwald-Mo\'{o}r metrics. The geometry of the $m$-th root metrics and some special cases have been investigated by several authors such as M. Matsumoto, K. Okubo, V. Balan, N. Brinzei, L. Tam\'{a}ssy, A. Tayebi and B. Najafi etc. in \cite{BB}, \cite{VB}, \cite{Brin}, \cite{MO}, \cite{TN} and \cite{Tam}. \begin{Exm} Riemannian metrics are $2$nd root metrics, i.e. $m=2$. \end{Exm} \begin{Def} $F$ is locally symmetric if each point has a coordinate neighbourhood such that $F^m$ is a symmetric polynomial of degree $m$ in the variables $y^1$, $\ldots$, $y^n$ of the induced coordinate system on the tangent manifold. \end{Def} Suppose that formula (\ref{polgen}) is a symmetric expression of $F(x,y)$ in the variables $y^1$, $\ldots$, $y^n$. Using the fundamental theorem of symmetric polynomials, we can write that \begin{equation} \label{charpol} F^m(x,y)=P(s^1, \ldots, s^n), \end{equation} where $$s^1=y^1+\ldots y^n, \ s^2=y^1y^2+\ldots+y^{n-1}y^n, \ldots, s^n=y^1\cdot \ldots \cdot y^n$$ are the so-called elementary symmetric polynomials. The polynomial $P$ with coefficients depending on the position is called the \emph{local characteristic polinomial} of the locally symmetric $m$-th root metric. Using the homogenity properties, the reduction of the number of the coefficients depending on the position is \begin{equation} \label{polspec} F^m(x,y)=\sum_{j_1+2j_2+\ldots+nj_n=m} c_{j_1 \ldots j_n}(x)(s^1)^{j_1}\cdot \ldots (s^n)^{j_n}. \end{equation} The following tables show the possible values of the powers $j_1$, $\ldots$, $j_n$ in case of $n=2, 3, 4, 5$ and $m=4$ (fourth root metrics). The corresponding local characteristic polynomials are of the form \begin{equation*} \begin{aligned} &P(s^1, s^2)=c_{40}(x)(s^1)^4+c_{21}(x)(s^1)^2s^2+c_{02}(x)(s^2)^2,\\ &P(s^1, s^2,s^3)=c_{400}(x)(s^1)^4+c_{210}(x)(s^1)^2s^2+c_{020}(x)(s^2)^2+c_{101}(x)s^1s^3,\\ &P(s^1, s^2,s^3,s^4)=c_{4000}(x)(s^1)^4+c_{2100}(x)(s^1)^2s^2+c_{0200}(x)(s^2)^2+c_{1010}(x)s^1s^3+c_{0001}(x)s^4. \end{aligned} \end{equation*} \vspace{0.2cm} \begin{center} \begin{tabular}{|l|l|} \hline \multicolumn{2}{|c|}{$n=2$}\\ \multicolumn{2}{|c|}{$j_1+2j_2=4$}\\ \hline $j_1=4$&$j_2=0$\\ \hline $j_1=2$&$j_2=1$\\ \hline $j_1=0$&$j_2=2$\\ \hline --&--\\ \hline --&--\\ \hline \end{tabular} \ \ \begin{tabular}{|l|l|l|} \hline \multicolumn{3}{|c|}{$n=3$}\\ \multicolumn{3}{|c|}{$j_1+2j_2+3j_3=4$}\\ \hline $j_1=4$&$j_2=0$&$j_3=0$\\ \hline $j_1=2$&$j_2=1$&$j_3=0$\\ \hline $j_1=0$&$j_2=2$&$j_3=0$\\ \hline $j_1=1$&$j_2=0$&$j_3=1$\\ \hline --&--&--\\ \hline \end{tabular} \ \ \begin{tabular}{|l|l|l|l|} \hline \multicolumn{4}{|c|}{$n=4$}\\ \multicolumn{4}{|c|}{$j_1+2j_2+3j_3+4j_4=4$}\\ \hline $j_1=4$&$j_2=0$&$j_3=0$&$j_4=0$\\ \hline $j_1=2$&$j_2=1$&$j_3=0$&$j_4=0$\\ \hline $j_1=0$&$j_2=2$&$j_3=0$&$j_4=0$\\ \hline $j_1=1$&$j_2=0$&$j_3=1$&$j_4=0$\\ \hline $j_1=0$&$j_2=0$&$j_3=0$&$j_4=1$\\ \hline \end{tabular} \end{center} \vspace{0.2cm} The case $n=4$ also shows the special form of the local characteristic polynomial of locally symmetric fourth root metrics for $n\geq 5$ up to the formal zero powers for the terms $s_5$, $\ldots$, $s_n$. If $n=5$ then we have that $$P(s^1, s^2,s^3,s^4,s^5)=c_{40000}(x)(s^1)^4+c_{21000}(x)(s^1)^2s^2+c_{02000}(x)(s^2)^2+c_{10100}(x)s^1s^3+c_{00010}(x)s^4.$$ \begin{Cor} A locally symmetric fourth root metric is locally determined by at most five components of its local characteristic polynomial. \end{Cor} \subsection{Regularity properties} Let us introduce the following notations $$A:=F^m(x,y)=\sum_{i_1+\ldots+i_n=m} a_{i_1 \ldots i_n}(x)(y^1)^{i_1}\cdot \ldots (y^n)^{i_n}, \ \ A_i:=\frac{\partial A}{\partial y^i} \ \ \textrm{and} \ \ A_{ij}:=\frac{\partial^2 A}{\partial y^i \partial y^j}.$$ \begin{Lem} The function $F=\sqrt[m]{A}$ is a Finsler metric if and only if $A_{ij}(v)$ is a positive definite matrix for any nonzero $v \in \pi^{-1}(U)$. \end{Lem} \begin{Pf} Suppose that $A_{ij}(v)$ is a positive definite matrix for any nonzero $v \in \pi^{-1}(U)$. Then, by the homogenity properties, $$0<y^iy^jA_{ij}=m(m-1)A,$$ i.e. we can introduce a positive valued one-homogeneous function $F=\sqrt[m]{A}$ on the complement of the zero section in $\pi^{-1}(U)$. Since $\displaystyle{A=(F^2)^l}$, $$A_{ij}=2^llE^{l-1} \left(g_{ij}+\frac{l-1}{E}\frac{\partial E}{\partial y^i}\frac{\partial E}{\partial y^i}\right), \ \textrm{where}\ E=\frac{1}{2}F^2.$$ Taking linearly independent vertical vector fields $V_1, \ldots, V_{n-1}$ such that $V_i(v)E=0$ at a given $v\in \pi^{-1}(U)$, it follows that $V_1, \ldots, V_{n-1}, C$ is a basis of the vertical subspace $V_vTM$. We have $$V_k^i(v)V_k^j(v)g_{ij}(v)=\frac{V_k^i(v)V_k^j(v) A_{ij}(v)}{2^llE^{l-1}(v)}>0\ \ \textrm{and}\ \ C^iC^jg_{ij}=y^iy^jg_{ij}=2E>0$$ in the sense of Euler's theorem on homogeneous functions. This means that $g_{ij}(v)$ is a positive definite matrix for any non-zero $v$. The converse of the statement is clear because of $$y^iy^jA_{ij}(v)=2^llE^{l-1}(v) \left(y^iy^jg_{ij}(v)+\frac{l-1}{E(v)}\left(y^i\frac{\partial E}{\partial y^i}(v)\right)^2\right),$$ i.e. if $g_{ij}(v)$ is a positive definite matrix, then $A_{ij}(v)$ is also positive definite for any non-zero $v\in TM$. \end{Pf} \section{Finsler surfaces with locally symmetric $4$-rooth metrics} Let $M$ be a two-dimensional Finsler manifold (Finsler surface) with a locally symmetric fourth root metric $F=\sqrt[4]{A}$. Its local characteristic polynomial must be of the form \begin{equation} P(s^1, s^2)=A(x,y)=a(x) (y^1+y^2)^4 + b(x) (y^1+y^2)^2 y^1 y^2 + c(x) (y^1y^2)^2, \label{poly1} \end{equation} where $a(x)=c_{40}(x)$, $b(x)=c_{21}(x)$ and $c(x)=c_{02}(x)$. Differentiating (\ref{poly1}) \begin{eqnarray*} &&A_1=\frac{\partial A}{\partial y^1}= 4 a(x) (y^1+y^2)^3 + 2 b(x) (y^1+y^2) y^1 y^2 + b(x) (y^1+y^2)^2y^2 + 2 c(x) y^1 (y^2)^2,\\ &&A_2=\frac{\partial A}{\partial y^2}= 4 a(x) (y^1+y^2)^3 + 2 b(x) (y^1+y^2) y^1 y^2 + b(x) (y^1+y^2)^2y^1 + 2 c(x) y^2 (y^1)^2. \end{eqnarray*} By some further computations \begin{eqnarray} &&A_{11}= 12 a(x) (y^1)^2 + ( 24 a(x)+ 6 b(x)) y^1 y^2 + ( 12 a(x) + 4b(x) + 2c(x) ) (y^2)^2,\label{A11}\\ &&A_{12}=A_{21}= ( 12 a(x)+ 3 b(x))(y^1)^2 + (24 a(x) + 8 b(x) + 4 c(x)) y^1 y^2 + (12 a(x) + 3b(x))(y^2)^2,\label{A12}\\ &&A_{22}= ( 12 a(x) + 4b(x) + 2c(x) )(y^1)^2 + ( 24 a(x)+ 6 b(x)) y^1 y^2 + 12 a(x) (y^2)^2 .\label{A22} \end{eqnarray} Introducing the functions \begin{equation} l(x):= a(x), \ m(x):= 4 a(x) + b(x), \ n(x):= 6 a(x) + 2 b(x) + c(x), \end{equation} we have that \begin{equation} \label{metric} A(x,y)=l(x)(y^1)^{4}+ m(x) (y^1)^{3}y^2+n(x)(y^1)^2 (y^2)^{2}+ m(x) y^1 (y^2)^{3}+l(y^2)^{4}, \end{equation} \begin{eqnarray} &&\frac{\partial A}{\partial y^1}= 4 l(x) (y^1)^3 + 3 m (x) (y^1)^2 y^2+ 2n (x)y^1 (y^2)^2 + m (x) (y^2)^3, \label{A1}\\ &&\frac{\partial A}{\partial y^2}= m (x)(y^1)^3 + 2n (x) (y^1)^2 y^2+ 3m (x)y^1 (y^2)^2 + 4l (x) (y^2)^3.\label{A2} \end{eqnarray} Since \[ \left[ \begin{matrix} l \\ m \\ n \end{matrix} \right] = \left[ \begin{matrix} 1 & 0 & 0 \\ 4 & 1 & 0 \\ 6 & 2 & 1 \end{matrix} \right] \left[ \begin{matrix} a \\ b \\ c \end{matrix} \right]. \] is a regular linear transformation, the coefficients $a(x), b(x)$, $c(x)$ are uniquely determined by $l(x)$, $m(x)$, $n(x)$ and vice versa. Using (\ref{A11}), (\ref{A12}) and (\ref{A22}) $$A_{11}= \left[ \begin{matrix} y^1 & y^2 \end{matrix} \right] \left[ \begin{matrix} 12l & 3m\\ 3m & 2n \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \end{matrix} \right], \ A_{12}= A_{21}=\left[ \begin{matrix} y^1 & y^2 \end{matrix} \right] \left[ \begin{matrix} 3m & 2n\\ 2n & 3m \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \end{matrix} \right], $$ $$A_{22}= \left[ \begin{matrix} y^1 & y^2 \end{matrix} \right] \left[ \begin{matrix} 2n & 3m\\ 3m & 12l \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \end{matrix} \right]. $$ Therefore $A_{ij}=\left[ \begin{matrix} A_{11} & A_{12}\\ A_{21} & A_{22} \end{matrix} \right] $ is positive definite if and only if $$ \left[ \begin {array}{cc} 12\,l&3\,m\\ \noalign{\medskip}3\,m&2\,n \end {array} \right] \ \ \textrm{and}\ \ \left[ \begin {array}{cc} 12\,l&3\,m\\ \noalign{\medskip}3\,m&2\,n \end {array} \right] \left[ \begin {array}{cc} 2\,n&3\,m\\ \noalign{\medskip}3\,m&12\,l \end {array} \right] - \left[ \begin {array}{cc} 3\,m&2\,n\\ \noalign{\medskip}2\,n&3\,m \end {array} \right]^2$$ are positive definite. Using some direct computations $$\left[ \begin {array}{cc} 12\,l&3\,m\\ \noalign{\medskip}3\,m&2\,n \end {array} \right] \left[ \begin {array}{cc} 2\,n&3\,m\\ \noalign{\medskip}3\,m&12\,l \end {array} \right] - \left[ \begin {array}{cc} 3\,m&2\,n\\ \noalign{\medskip}2\,n&3\,m \end {array} \right]^2= \left[ \begin {array}{cc} 24\,nl-4\,{n}^{2}&72\,ml-12\,nm \\ \noalign{\medskip}0&24\,nl-4\,{n}^{2}\end {array} \right] $$ and, consequently, \begin{eqnarray} 12 l >0, \ \ 24 l n - 9 m^2>0\ \ \textrm{and} \ \ 24 n l - 4 n^2 >0.\label{posi1} \end{eqnarray} Especially (\ref{posi1}) is equivalent to \begin{equation} \label{posi2} 6l>n>0 \ \ \textrm{and}\ \ \frac{8}{3} n l > m^2. \end{equation} \subsection{Generalized Berwald surfaces with locally symmetric fourth root metrics} Let $\nabla$ be a linear connection on the base manifold $M$ equipped with a locally symmetric fourth root metric $F=\sqrt[4]{A}$ and suppose that the parallel transports preserve the Finslerian length of tangent vectors. The compatibility condition (\ref{cond1}) can be written into the form \begin{equation} \frac{\partial A}{\partial x^i} - y^j \Gamma^k_{ij}(x) \frac{\partial A}{\partial y^k}=0 \ \ (i=1, 2).\label{gene} \end{equation} Substituting (\ref{metric}), (\ref{A1}) and (\ref{A2}) into (\ref{gene}), we get the following system of linear equations \begin{eqnarray} \left[ \begin{matrix} 4l & 0 & m & 0 \\ 3m & 4l & 2n & m \\ 2n & 3m & 3m & 2n \\ m & 2n & 4l & 3m \\ 0 & m & 0 & 4l \end{matrix} \right] \left[ \begin{matrix} \Gamma^1_{i1}\\ \Gamma^1_{i2} \\ \Gamma^2_{i1} \\ \Gamma^2_{i2}\\ \end{matrix} \right] = \left[ \begin{matrix} \partial l / \partial x^i \\ \partial m / \partial x^i \\ \partial n / \partial x^i \\ \partial m / \partial x^i \\ \partial l / \partial x^i \end{matrix} \right]\label{system} \end{eqnarray} because of $$y^j \Gamma^k_{ij} \frac{\partial A}{\partial y^k}=\left(y^1 \Gamma^1_{i1}+y^2 \Gamma^1_{i2}\right) \frac{\partial A}{\partial y^1}+\left(y^1 \Gamma^2_{i1}(x)+y^2 \Gamma^2_{i2}\right) \frac{\partial A}{\partial y^2}\stackrel{(\ref{A1}), \ (\ref{A2})}{=}$$ $$$$ $$\left(4l\Gamma^1_{i1}+m\Gamma^2_{i1}\right)(y^1)^4+\left(m\Gamma^2_{i2}+2n\Gamma^2_{i1}+4l\Gamma^1_{i2}+3m\Gamma^1_{i1}\right)(y^1)^3 y^2+$$ $$$$ $$\left(2n\Gamma^2_{i2}+3m\Gamma^2_{i1}+3m\Gamma^1_{i2}+2n\Gamma^1_{i1}\right)(y^1)^2(y^2)^2+$$ $$$$ $$\left(3m\Gamma^2_{i2}+4l\Gamma^2_{i1}+2n\Gamma^1_{i2}+m\Gamma^1_{i1}\right)y^1(y^2)^3+\left(m\Gamma^1_{i2}+4l\Gamma^2_{i2}\right)(y^2)^4.$$ \begin{Lem} \label{lemmakey} If $F=\sqrt[4]{A}$ is a non-Riemannain connected generalized Berwald surface with a locally symmetric fourth root metric, then \begin{eqnarray} \textrm{rank} \left[ \begin{matrix} 4l & 0 & m & 0 \\ 3m & 4l & 2n & m \\ 2n & 3m & 3m & 2n \\ m & 2n & 4l & 3m \\ 0 & m & 0 & 4l \end{matrix} \right]=4. \label{matrix} \end{eqnarray} \end{Lem} \begin{Pf} Suppose, in contrary, that the rank is less than 4. In case of $m(x)=0$ \begin{eqnarray*} \textrm{rank} \left[ \begin{matrix} 4l(x) & 0 & 0 & 0 \\ 0 & 4l(x) & 2n(x) & 0 \\ 2n(x) & 0 & 0 & 2n(x) \\ 0 & 2n(x) & 4l(x) & 0 \\ 0 & 0 & 0 & 4l(x) \end{matrix} \right]<4. \end{eqnarray*} Therefore $n(x)= 2l(x)=2a(x)$. Since $m(x)=0$, it follows that $b(x)=-4a(x)$, $c(x)=4a(x)$ and, consequently, $b^2(x)-4a(x)c(x)=0$. This means that \begin{eqnarray*} A(x,y)=a(x) (y^1)^4+ 2 a(x) (y^1)^2 (y^2)^2 + a(x) (y^2)^4= a(x) \left( (y^1)^2 + (y^2)^2 \right)^2 \end{eqnarray*} is a complete square of the quadratic form $E(x,y)$ with respect to the variables $y^1$ and $y^2$. Using that we have a compatible linear connection, the indicatrices are quadrics at each point as the (linear) parallel translates of the indicatrix at the single point $x$. It is a contradiction because the surface is non-Riemannian. In the second case we suppose that $m(x) \neq 0$ and consider the submatrix \begin{eqnarray*} \left[ \begin{matrix} 4l(x) & 0 & m(x) & 0 \\ 2n(x) & 3m(x) & 3m(x) & 2n(x) \\ m(x) & 2n(x) & 4l(x) & 3m(x) \\ 0 & m(x) & 0 & 4l(x) \end{matrix} \right]. \end{eqnarray*} If the rank is less than 4, then its determinant must be zero: $$4m(x) (6l(x) - n(x)) (8 l^2(x) -4 l(x) n(x) + m^2(x))=0.$$ According to the regularity properties (\ref{posi1}), $6l(x)-n(x)>0$ and $m(x)\neq 0$ imply that $$8 l^2(x) -4 l(x) n(x) + m^2(x)=0,$$ $$8a^2(x)-4a(x)\left(6 a(x) + 2 b(x) + c(x)\right)+\left(4 a(x) + b(x)\right)^2=0 \ \ \Rightarrow \ \ b^2(x)-4a(x)c(x)=0$$ and the proof can be finished as above. \end{Pf} \begin{Thm} \label{maintheorem2D} Let $M$ be a connected non-Riemannian Finsler surface with a locally symmetric fourth root metric $F=\sqrt[4]{A}$. It is a generalized Berwald surface if and only if the coefficient matrix $$B:=\left[ \begin{matrix} 4l & 0 & m & 0 \\ 3m & 4l & 2n & m \\ 2n & 3m & 3m & 2n \\ m & 2n & 4l & 3m \\ 0 & m & 0 & 4l \end{matrix} \right]$$ is of constant rank $4$ and \begin{eqnarray} \label{main2D} \det \left[ \begin{matrix} 4l & 0 & m & 0 & \partial l/ \partial x^i \\ 3m & 4l & 2n & m & \partial m/ \partial x^i \\ 2n & 3m & 3m & 2n & \partial n/ \partial x^i \\ m & 2n & 4l & 3m & \partial m/ \partial x^i \\ 0 & m & 0 & 4l & \partial l/ \partial x^i \end{matrix} \right] =0 \ \ \ (i=1,2). \end{eqnarray} The compatible linear connection is uniquely determined by the formula \begin{equation} \label{explicite} \left[ \begin{matrix} \Gamma^1_{i1}\\ \Gamma^1_{i2} \\ \Gamma^2_{i1} \\ \Gamma^2_{i2}\\ \end{matrix} \right] =\left(B^{T} B\right)^{-1} B^T \left[ \begin{matrix} \partial l / \partial x^i \\ \partial m / \partial x^i \\ \partial n / \partial x^i \\ \partial m / \partial x^i \\ \partial l / \partial x^i \end{matrix} \right] \ \ (i=1,2). \end{equation} \end{Thm} \begin{Pf} According to Lemma \ref{lemmakey}, if a generalized Berwald metric is non-Riemannian, then the coefficient matrix in (\ref{system}) is of constant rank $4$ and the existence of the unique solution is equivalent to the vanishing of the determinant of the extended matrix. To conclude the explicite expression of the coefficients of the compatible linear connection note that $B^TB$ is the Gram matrix of the linearly independent column vectors, i.e. the Gram determinant different from zero and $B^TB$ is invertible. Conversely, if the rank is maximal and (\ref{main2D}) holds, then the system of linear equations (\ref{system}) has a unique solution given by formula (\ref{explicite}). \end{Pf} \subsection{Examples} In what follows we give explicite examples for non-constant functions satisfying (\ref{main2D}). To simplify the formulation of the problem we prove that the class of generalized Berwald metrics is closed under the conformal deformation. \begin{Def} The Finsler metrics $F_1$ and $F_2$ are conformally related if $F_2(x,y)=e^{\alpha(x)}F_1(x,y).$ \end{Def} \begin{Thm} \label{confinv} The class of generalized Berwald metrics is closed under the conformal deformation. \end{Thm} \begin{Pf} If the compatibility equation (\ref{cond1}) holds for the Finsler metric $F_1$ then we have that $$ \frac{\partial F_2}{\partial x^i}-y^j {\Gamma}^k_{ij}(x) \frac{\partial F_2}{\partial y^k}=e^{\alpha(x)}\left(\frac{\partial F_1}{\partial x^i}-y^j {\Gamma}^k_{ij}(x) \frac{\partial F_1}{\partial y^k}\right)+F_2\frac{\partial \alpha}{\partial x^i}=F_2\frac{\partial \alpha}{\partial x^i}. $$ This means that the compatibility equation \begin{equation} \label{cond2} \frac{\partial F_2}{\partial x^i}-y^j\left({\Gamma}^k_{ij}(x)+\frac{\partial \alpha}{\partial x^i}(x)\delta_j^k\right) \frac{\partial F_2}{\partial y^k}=0\ \ (i=1, \ldots,n) \end{equation} holds for the Finsler metric $F_2$. \end{Pf} In the sense of the previous theorem we can suppose that $4l(x)=1$ (conformal deformation of the metric). Therefore we should find solutions $n(x)$ and $m(x)$ of equation \begin{eqnarray*} \label{main2Dexm} \det \left[ \begin{matrix} 1 & 0 & m & 0 & 0 \\ 3m & 1 & 2n & m & \partial m/ \partial x^i \\ 2n & 3m & 3m & 2n & \partial n/ \partial x^i \\ m & 2n &1 & 3m & \partial m/ \partial x^i \\ 0 & m & 0 & 1 & 0 \end{matrix} \right] =0 \,\,\,\,\,\,\,\,\,\,\,\, (i=1,2). \end{eqnarray*} We have $$8\partial m/ \partial x^i {m}^{3}n-8\,\partial n/ \partial x^i {m}^{4}-12\partial m/ \partial x^i {m}^{3}-8\partial m/ \partial x^i m {n}^{2}+12\partial n/ \partial x^i {m}^{2}n+$$ $$16\partial m/\partial x^i mn-2\partial n/ \partial x^i{m}^{2}-4\partial n/ \partial x^i {n}^{2}-6m\partial m/ \partial x^i +\partial n/ \partial x^i=0,$$ \begin{equation} \label{exm1} 2m \left( 2\,n-3 \right) \left( 2\,{m}^{2}-2\,n+1 \right) \partial m/ \partial x^i+ \left( 2 \,{m}^{2}-2\,n+1 \right) \left( -4\,{m}^{2}+2\,n+1 \right) \partial n/ \partial x^i=0. \end{equation} Since $l=1/4$, the case $2{m}^{2}-2n+1=0$ gives that $m^2=n-1/2$, $$8 l^2(x) -4 l(x) n(x) + m^2(x)=0,$$ $$8a^2(x)-4a(x)\left(6 a(x) + 2 b(x) + c(x)\right)+\left(4 a(x) + b(x)\right)^2=0 \ \ \Rightarrow \ \ b^2(x)-4a(x)c(x)=0,$$ i.e. the surface is Riemannian\footnote{Recall that the quadratic indicatrix at a single point implies that the indicatrices are quadratic at all points of the manifold because of the compatible (linear) parallel transports.}. Therefore we can suppose that $2{m}^{2}(x)-2n(x)+1\neq 0$ to present non-Riemannian generalized Berwald surfaces. We have $$2m \left( 2n-3 \right) \partial m/ \partial x^i+ \left( -4{m}^{2}+2n+1 \right) \partial n/ \partial x^i=0,$$ $$2m \partial m/ \partial x^i=-{\frac { -4{m}^{2}+2n+1}{2n-3}}\partial n/ \partial x^i.$$ Recall that the regularity conditions in (\ref{posi2}) reduce to \begin{equation} \label{posi3} \frac{3}{2}>n>0 \ \ \textrm{and}\ \ \frac{2}{3}> \frac{m^2}{n} \end{equation} because of $l=1/4$ and we can divide by the term $2n-3$. To present non-constant\footnote{The simplest examples are the constant functions satisfying (\ref{matrix}). In this case (\ref{main2D}) is automathic.} solutions $m(x)$ and $n(x)$ suppose that $n$ is regular at the point $x$ and, by taking $m^2=y(n)$, we have that $$y'(n) =-{\frac {-4y \left( n \right) +2n+1}{2n-3}}.$$ The general form of the solution is $$y_{\varepsilon} \left( n \right) =n-1/2+ \varepsilon \left( 2\,n-3 \right) ^{2}.$$ The integration constant $\varepsilon=1/18$ provides that it is a positive-valued function on the positive half line of the reals. On the other hand $$\frac{m_{1/18}^2}{n}=\frac{y_{1/18}(n)}{n}=\frac{1}{3}+\frac{2}{9}n < \frac{2}{3}$$ on the interval $(0, 3/2)$. Therefore the regularity conditions in (\ref{posi3}) are satisfied and the triplet $$l(x)=r(x)/4, \ \ m_{1/18}(x):=r(x) \sqrt{n-1/2+ \frac{1}{18} \left( 2\,n-3 \right) ^{2}},\ \ r(x) n(x)$$ determines a non-Riemannian generalized Berwald surface for any positive-valued function $r(x)$; see Theorem \ref{maintheorem2D} and Theorem \ref{confinv}. It is a one-parameter family of examples depending on the integration constant $\varepsilon$ satisfying the regularity conditions in (\ref{posi3}). For example for any $1/18 < \varepsilon < 1/6$ it follows that $$0 < n_0:=\frac{18\varepsilon-1}{8\varepsilon}< \frac{3}{2}$$ and $$\frac{m_{\varepsilon}^2(n_0)}{n_0}=\frac{y_{\varepsilon}(n_0)}{n_0}=\varepsilon+\frac{1}{2}< \frac{1}{6}+\frac{1}{2}= \frac{2}{3}.$$ Using a continuity argument, if $n$ is sufficiently close to $n_0$, then the the regularity conditions in (\ref{posi3}) are satisfied. \section{Computations in 3D} Suppose that the base manifold is of dimension $3$, i.e. the locally symmetric fourth root metric must be of the form $$P(s^1, s^2, s^3)=A(x,y)=a(x) (y^1+y^2+y^3)^4 + b(x) (y^1+y^2+y^3)^2 ( y^1 y^2 + y^1 y^3 + y^2 y^3 ) +$$ $$ c(x) ( y^1 y^2 + y^1 y^3 + y^2 y^3 )^2 +d(x) (y^1+y^2+y^3)y^1 y^2 y^3,$$ where $a(x)=c_{400}(x)$, $b(x)=c_{210}(x)$, $c(x)=c_{020}(x)$ and $d(x)=c_{101}(x)$. Introducing the functions $$l(x):=a(x), \ m(x):= 4a(x)+b(x), \ n(x):= 6a(x) + 2b(x) +c(x),$$ $$q(x) := 12 a(x)+ 5b(x) + 2c(x)+d(x),$$ we have that $$ A=l \left((y^1)^4+(y^2)^4+(y^3)^4 \right)+m\left((y^1)^3 y^2 + (y^1)^3 y^3 + (y^2)^3 y^3 + (y^3)^3 y^2 + (y^3)^3 y^1 + (y^2)^3 y^1 \right)+$$ $$n\left((y^1)^2( y^2)^2 + (y^1)^2( y^3)^2 + (y^2)^2( y^3)^2\right)+q\left((y^1)^2y^2y^3+y^1( y^2)^2 y^3+ y^1 y^2( y^3)^2 \right).$$ By some further computations \begin{eqnarray*} A_1:= \frac{\partial A}{\partial y^1}&=& 4l(y^1)^3+m \left(3(y^1)^2 y^2+3(y^1)^2 y^3+(y^2)^3+(y^3)^3\right)+n\left(2y^1 (y^2)^2+2y^1(y^3)^2\right)+\\ &&q\left(2y^1y^2y^3+(y^2)^2y^3+y^2(y^ 3)^2\right),\\ A_2:= \frac{\partial A}{\partial y^2}&=& 4l(y^2)^3+m\left((y^1)^3+3y^1(y^2)^2+3(y^2)^2y^3+(y^3)^3\right)+n\left(2(y^1)^2y^2+2y^2(y^3)^2\right)+\\ &&q\left((y^1)^2y^3+2y^1y^2y^3+y^1(y^3)^2\right),\\ A_3:= \frac{\partial A}{\partial y^3}&=& 4l(y^3)^3+m\left((y^1)^3+3y^1(y^3)^2+(y^2)^3+3y^2(y^3)^2\right)+n\left(2(y^1)^2 y^3+2(y^2)^2y^3\right)+\\ &&q\left((y^1)^2y^2+y^1(y^2)^2+2y^1y^2y^3\right),\\ A_{11}&=& 12 l (y^1)^2 + m \left( 6y^1y^2+6y^1y^3\right)+ n \left(2(y^2)^2 + 2(y^3)^2\right) + 2q y^2y^3,\\ A_{12}&=& A_{21}=m \left( 3(y^1)^2 + 3(y^2)^2\right)+ 4n y^1y^2 + q \left(2y^1y^3+ 2y^2y^3 + (y^3)^2\right),\\ A_{13}&=&A_{31}= m \left( 3(y^1)^2+3(y^3)^2 \right)+4n y^1y^3+ q \left( 2y^1y^2 + (y^2)^2 + 2y^2y^3\right) ,\\ A_{22}&=& 12 l (y^2)^2 + m \left(6 y^1y^2+ 6 y^2 y^3\right)+ n \left(2 (y^1)^2 + 2 (y^3)^2\right)+ 2q y^1y^3,\\ A_{23}&=&A_{32}= m \left( 3(y^2)^2 + 3(y^3)^2\right)+ 4n y^2y^3 + q \left((y^1)^2 + 2y^1y^2 + 2y^1y^3\right) ,\\ A_{33}&=& 12 l (y^3)^2 + m \left(6 y^1y^3+ 6 y^2y^3\right)+ n \left(2 (y^1)^2 + 2 (y^2)^2\right)+ 2q y^1y^2. \end{eqnarray*} The second order partial derivatives can be written into the form $$A_{11}= \left[ \begin{matrix} y^1 & y^2 & y^3 \end{matrix} \right] \left[ \begin{matrix} 12 l & 3m & 3m \\ 3m & 2n & q \\ 3m & q & 2n \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \\ y^3 \end{matrix} \right], \ A_{12}=A_{21}= \left[ \begin{matrix} y^1 & y^2 & y^3 \end{matrix} \right] \left[ \begin{matrix} 3m & 2n & q \\ 2n & 3m & q \\ q & q & q \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \\ y^3 \end{matrix} \right],$$ $$A_{22}= \left[ \begin{matrix} y^1 & y^2 & y^3 \end{matrix} \right] \left[ \begin{matrix} 2n & 3m & q \\ 3m & 12l & 3m \\ q & 3m & 2n \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \\ y^3 \end{matrix} \right], \ A_{13}=A_{31}= \left[ \begin{matrix} y^1 & y^2 & y^3 \end{matrix} \right] \left[ \begin{matrix} 3m & q & 2n \\ q & q & q \\ 2n & q & 3m \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \\ y^3 \end{matrix} \right],$$ $$ A_{33}= \left[ \begin{matrix} y^1 & y^2 & y^3 \end{matrix} \right] \left[ \begin{matrix} 2n & q & 3m \\ q & 2n & 3m \\ 3m & 3m & 12l \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \\ y^3 \end{matrix} \right], \ A_{23}=A_{32}= \left[ \begin{matrix} y^1 & y^2 & y^3 \end{matrix} \right] \left[ \begin{matrix} q & q & q \\ q & 3m & 2n \\ q & 2n & 3m \end{matrix} \right] \left[ \begin{matrix} y^1 \\ y^2 \\ y^3 \end{matrix} \right]. $$ The positive definiteness of $\displaystyle{A_{ij}:= \left[ \begin{matrix} A_{11} & A_{12} & A_{13} \\ A_{21} & A_{22} & A_{23} \\ A_{31} & A_{32} & A_{33} \end{matrix} \right]}$ can be expressed in terms of the formal subdeterminants $$\left[ \begin{matrix} 12 l & 3m & 3m \\ 3m & 2n & q \\ 3m & q & 2n \end{matrix} \right], \ \left[ \begin{matrix} 12 l & 3m & 3m \\ 3m & 2n & q \\ 3m & q & 2n \end{matrix} \right]\left[ \begin{matrix} 2n & 3m & q \\ 3m & 12l & 3m \\ q & 3m & 2n \end{matrix} \right]-\left[ \begin{matrix} 3m & 2n & q \\ 2n & 3m & q \\ q & q & q \end{matrix} \right]^2, \ \ldots $$ of the matrix (\ref{bigmatrix}) all of whose elements are matrices. Therefore the formal determinants are also matrices and all of them must be positive definite. \begin{equation} \label{bigmatrix} \left[ \begin{matrix} \left[ \begin{matrix} 12 l & 3m & 3m \\ 3m & 2n & q \\ 3m & q & 2n \end{matrix} \right] & \left[ \begin{matrix} 3m & 2n & q \\ 2n & 3m & q \\ q & q & q \end{matrix} \right] & \left[ \begin{matrix} 3m & q & 2n \\ q & q & q \\ 2n & q & 3m \end{matrix} \right] \\ && \\ \left[ \begin{matrix} 3m & 2n & q \\ 2n & 3m & q \\ q & q & q \end{matrix} \right] & \left[ \begin{matrix} 2n & 3m & q \\ 3m & 12l & 3m \\ q & 3m & 2n \end{matrix} \right] & \left[ \begin{matrix} q & q & q \\ q & 3m & 2n \\ q & 2n & 3m \end{matrix} \right] \\ && \\ \left[ \begin{matrix} 3m & q & 2n \\ q & q & q \\ 2n & q & 3m \end{matrix} \right] & \left[ \begin{matrix} q & q & q \\ q & 3m & 2n \\ q & 2n & 3m \end{matrix} \right] & \left[ \begin{matrix} 2n & q & 3m \\ q & 2n & 3m \\ 3m & 3m & 12l \end{matrix} \right] \end{matrix} \right]. \end{equation} The compatibility equation (\ref{cond1}) can be written into the form of the following system of linear equations: \begin{equation*} \frac{\partial A}{\partial x^i} - y^j \Gamma^k_{ij} \circ \pi \frac{\partial A}{\partial y^k}=0 \ \ (i=1, 2),\label{gene3D} \end{equation*} \begin{eqnarray} \left[ \begin{matrix} 4l & 0 & 0 & m & 0 & 0 & m & 0 & 0 \\ 0 & m & 0 & 0 & 4l & 0 & 0 & m & 0 \\ 0 & 0 & m & 0 & 0 & m & 0 & 0 & 4l \\ 3m & 4l & 0 & 2n & m & 0 & q & m & 0 \\ 3m & 0 & 4l & q & 0 & m & 2n & 0 & m \\ 0 & q & m & 0 & 3m & 4l & 0 & 2n & m \\ 0 & m & q & 0 & m & 2n & 0 & 4l & 3m \\ m & 0 & 2n & m & 0 & q & 4l & 0 & 3m \\ m & 2n & 0 & 4l & 3m & 0 & m & q & 0 \\ 2q & 3m & 3m & 2q & q & 2n & 2q & 2n & q \\ q & 2q & 2n & 3m & 2q & 3m & 2n & 2q & q \\ q & 2n & 2q & 2n & q & 2q & 3m & 3m & 2q \\ 0 & q & q & 0 & 2n & 3m & 0 & 3m & 2n \\ 2n & 0 & 3m & q & 0 & q & 3m & 0 & 2n \\ 2n & 3m & 0 & 3m & 2n & 0 & q & q & 0 \end{matrix} \right] \left[ \begin{matrix} \Gamma^1_{i1} \\ \Gamma^1_{i2} \\ \Gamma^1_{i3} \\ \Gamma^2_{i1} \\ \Gamma^2_{i2} \\ \Gamma^2_{i3} \\ \Gamma^3_{i1} \\ \Gamma^3_{i2} \\ \Gamma^3_{i3} \end{matrix} \right]= \left[ \begin{matrix} \partial l / \partial x^i \\ \partial l / \partial x^i \\ \partial l / \partial x^i \\ \partial m / \partial x^i \\ \partial m / \partial x^i \\ \partial m / \partial x^i \\ \partial m / \partial x^i \\ \partial m / \partial x^i \\ \partial m / \partial x^i \\ \partial q / \partial x^i \\ \partial q / \partial x^i \\ \partial q / \partial x^i \\ \partial n / \partial x^i \\ \partial n / \partial x^i \\ \partial n / \partial x^i \\ \end{matrix} \right]. \label{bigsystem} \end{eqnarray} \subsection{An example} Suppose\footnote{It is also possible but the symbolical Maple computations give extremely long formulas in general.} that $4l(x)=1$, $3m(x)=1$ and $n(x)=q(x)$. According to (\ref{bigmatrix}), the matrix $A_{ij}$ is positive definite if and only if \begin{itemize} \item[(i)] $\left[ \begin {array}{ccc} 3&1&1\\ \noalign{\medskip}1&2\,n&n \\ \noalign{\medskip}1&n&2\,n\end {array} \right] $ is positive definite: $6n-1>0$ and $9n^2-2n>0$, \item[(ii)] $ \left[ \begin {array}{ccc} 3&1&1\\ \noalign{\medskip}1&2\,n&n \\ \noalign{\medskip}1&n&2\,n\end {array} \right] \left[ \begin {array}{ccc} 2\,n&1&n\\ \noalign{\medskip}1&3&1 \\ \noalign{\medskip}n&1&2\,n\end {array} \right] -\left[ \begin {array}{ccc} 1&2\,n&n\\ \noalign{\medskip}2\,n&1&n \\ \noalign{\medskip}n&n&n\end {array} \right]^2=$ $$\left[ \begin {array}{ccc} -5\,{n}^{2}+7\,n&-{n}^{2}-4\,n+7&-3\,{n}^{ 2}+4\,n+1\\ \noalign{\medskip}0&-5\,{n}^{2}+7\,n&-{n}^{2}+2\,n \\ \noalign{\medskip}-{n}^{2}+2\,n&-3\,{n}^{2}+4\,n+1&{n}^{2}+2\,n \end {array} \right] $$ is positive definite: $-5n^2+7n >0$ and $6n^3(9n^3-27n^2+23n-4) >0$, \item[(iii)] following the formal Sarrus rule, $$\left[ \begin {array}{ccc} 3&1&1\\ \noalign{\medskip}1&2\,n&n \\ \noalign{\medskip}1&n&2\,n\end {array} \right] \left[ \begin {array}{ccc} 2\,n&1&n\\ \noalign{\medskip}1&3&1 \\ \noalign{\medskip}n&1&2\,n\end {array} \right] \left[ \begin {array}{ccc} 2\,n&n&1\\ \noalign{\medskip}n&2\,n&1 \\ \noalign{\medskip}1&1&3\end {array} \right] +...=$$ $$ \left[ \begin {array}{ccc} -5\,{n}^{2}+7\,n+1&-3\,{n}^{3}-10\,{n}^{2} +21\,n+1&-6\,{n}^{3}-9\,{n}^{2}+23\,n+11\\ \noalign{\medskip}6\,{n}^{3 }-8\,{n}^{2}-4\,n-1&-9\,{n}^{3}+7\,{n}^{2}+n&-3\,{n}^{3}-10\,{n}^{2}+ 21\,n+1\\ \noalign{\medskip}18\,{n}^{3}-18\,{n}^{2}-14\,n-2&6\,{n}^{3} -8\,{n}^{2}-4\,n-1&-5\,{n}^{2}+7\,n+1\end {array} \right] $$ is positive definite: $-5n^2+7n+1>0$, $$18\,{n}^{6}+81\,{n}^{5}-316\,{n}^{4}+154\,{n}^{3}+96\,{n}^{2}+26\,n+1>0,$$ $$-1026\,{n}^{9}+1260\,{n}^{8}+6015\,{n}^{7}-12069\,{n}^{6}+4524\,{n}^{5 }+2509\,{n}^{4}-1582\,{n}^{3}-42\,{n}^{2}+100\,n+11>0. $$ \end{itemize} Items (i) and (ii) give that $\displaystyle{4/3> n > \frac{5-\sqrt{13}}{6}}$. Item (ii) obviously implies that $-5n^2+7n+1>0$ in item (iii). Figure 1 shows $$18\,{n}^{6}+81\,{n}^{5}-316\,{n}^{4}+154\,{n}^{3}+96\,{n}^{2}+26\,n+1,$$ $$-1026\,{n}^{9}+1260\,{n}^{8}+6015\,{n}^{7}-12069\,{n}^{6}+4524\,{n}^{5}+2509\,{n}^{4}-1582\,{n}^{3}-42\,{n}^{2}+100\,n+11$$ as the functions of the variable $n$ on the intervall $\displaystyle{\left(\frac{5-\sqrt{13}}{6},4/3\right)}$: \begin{verbatim} with(plots); F := plot(18*n^6+..., n = 5/6-(1/6)*sqrt(13) .. 4/3, linestyle = dashdot): G := plot(-1026*n^9+..., n = 5/6-(1/6)*sqrt(13) .. 4/3): display({F, G}); \end{verbatim} \begin{figure} \includegraphics[scale=0.45]{functions.eps} \caption{Regularity conditions.} \end{figure} Therefore the regularity condition for $n$ is to be in $\displaystyle{\left(\frac{5-\sqrt{13}}{6}, r_1\right)}$, where $r_1$ is the first positive root of the polynomial $-1026\,{n}^{9}+1260\,{n}^{8}+6015\,{n}^{7}-12069\,{n}^{6}+\ldots$ For some numerical estimations note that $r_1 > 0.6458$ and $\displaystyle{\frac{5-\sqrt{13}}{6}< 0.2325}$. To finish the discussion of the problem consider the coefficient matrix $B$ of the system (\ref{bigsystem}). It is of rank $9$ if and only if $\det B^T B \neq 0$. Since $$\det B^TB = \frac{1}{387420489} (46656 n^4-5184 n^3-5589 n^2+2124 n+1492 )$$ $$(3n-2)^2(124659 n^6-51030 n^5-77517 n^4-51030 n^3+158931 n^2-92820 n+17731)^2$$ it follows that the regularity condition $0.2325 < n < 0.6458$ provides the matrix $B^TB$ to be invertible as Figure 2 shows: \begin{verbatim} with(plots); K := plot(46656*n^4..., n = 5/6-(1/6)*sqrt(13) .. 1.2, linestyle = dashdot); L := plot(124659*n^6..., n = 5/6-(1/6)*sqrt(13) .. 1.2); display({K, L}); \end{verbatim} \begin{figure} \includegraphics[scale=0.45]{functions01.eps} \caption{The maximality of the rank.} \end{figure} Therefore the necessary and sufficient condition for the metric $F=\sqrt[4]{A}$ ($4l=1, 3m=1, n=q$, $0.2325 < n < 0.6458$ ) to be a non-Riemannian generalized Berwald metric is the vanishing of the determinant of the extended matrix of the system (\ref{bigsystem}). On the other hand, the compatible linear connection is uniquely determined by the three-dimessional analogue of formula (\ref{explicite}). Having no any other information about the linear connection, the unicity is not an automathic consequence in 3D.
\section{Introduction} Quasars reside at the centres of active galactic nuclei (AGNs) and are believed to be powered by mass accretion onto a supermassive black hole (SMBH). Thanks to their strong intrinsic luminosity, quasars are bright enough \citep[$\rm{L\sim10^{14} L_{\odot}}$ for the most luminous quasar ever discovered at $z = 6.30$, ][]{Wu2015} to be detected at high redshifts, where they can be used to explore the early Universe. Along with other cosmological probes, high-redshift quasars (hereafter, "high-redshift" refers to redshifts $z \gtrsim 5.6$) have proved to be powerful tools for studying not only the epoch of cosmic reionisation \citep[e.g.][]{Fan2006, Jiang2008, Becker2015}, but also for investigating the formation and evolution of primordial SMBHs \citep[e.g.][]{Willott20102}. The relations between luminosity, black hole mass, and broad emission line velocity have been demonstrated at low redshifts by reverberation mapping studies \citep[e.g.][]{Kaspi2000, Vestergaard2002, Bentz2009}. Spectroscopy of high-redshift quasars (high-z quasars) can therefore be exploited in order to measure SMBHs masses, estimate their mass function, and place solid constraints on SMBH formation models, under the assumption that these local relations are still valid at high redshifts. Using this technique, it has been possible to confirm black holes with masses exceeding $\rm{M_{BH}} \gtrsim 10^{9} \rm{M_{\odot}}$ at redshifts $z \gtrsim 6$ \citep{Mortlock2011, Wu2015, Banados2018}. How such massive objects could have formed so quickly in less than 1 Gyr after the Big Bang is still a fundamental question arising from these discoveries \citep[see reviews by][]{Volonteri2010, Haiman2013, Smith2017}. Several scenarios for the formation of SMBHs seeds, including, for instance, remnants of Population III stars \citep[e.g.][]{Madau2001, Volonteri2003} or a direct collapse of gas in atomic cooling halos \citep[DCBH, e.g.][]{Visbal2014, Smidt2017} have been proposed, but they are widely debated, partly because known bright high-z quasars are likely to be the tip of an iceberg that is mainly composed of fainter quasars. The cosmic reionisation that ended the so-called dark ages during which the first sources of the Universe ionised the hydrogen in the intergalactic medium (IGM) is a major event in the Universe's history, and many questions related to the onset, duration, topology, and the sources responsible for this process remain unsolved. High-redshift quasars can be used as background sources whose UV radiation is absorbed at the resonant Lyman lines by intervening neutral hydrogen along the line of sight. Their spectra are therefore reliable tools for absorption studies since they show spectral signatures of the IGM state. The hydrogen neutral fraction $x_{HI}$ can indeed be determined by making a range of measurement on high-z quasar spectra, such as the Gunn-Peterson test \citep[e.g.][]{Gunn1965, Fan2006, Becker2015b}, near-zone measurement \citep[e.g.][]{Venemans2015, Mazzucchelli2017}, dark gaps and dark pixels statistics \citep[e.g.][]{McGreer2015}, and Lyman-$\alpha$ damping wing reconstruction \citep[e.g.][]{Greig2017}. Measurements of the quasar luminosity function (QLF) at $z\sim6$ have shown that the quasar ionising flux was not sufficient to keep the Universe ionised, with a photon rate density lower by between 20 and 100 times than required \citep{Willott2010}. Even though the faint end of the QLF remains poorly constrained, it is now generally agreed that AGNs do not contribute significantly to the required ionising photon budget at $z \sim 6$ \citep{Onoue2017}. \\ If there are compelling reasons to search for high-z quasars, the quest is no less challenging because of their rarity: \citet{Willott2010} predicted a number of quasars of the order of $\rm{\sim 0.1\,deg^{-2}}$ brighter than $\rm{H_{AB} \simeq 24}$ in the redshift range $6.5 < z < 7.5$. In the past few years, substantial progress has been made in this field, where more than 100 high-z quasars have been identified \citep{Banados2016}. Wide area surveys greatly contributed to this success, with surveys first carried out in optical bands, such as the Sloan Digital Sky Survey \citep[SDSS ]{York2000} and the Canada-France High-z Quasar Survey \citep[CFHQS;][]{Willott2005, Willott2007, Willott2009, Willott2010}, providing more than 50 quasars up to redshifts $z \simeq 6.4$. At higher redshifts, the Lyman-$\alpha$ emission line is shifted into the near-infrared (NIR) and becomes undetectable at observed wavelengths $\rm{\lambda_{obs}} \lesssim 0.9\,\rm{\mu} m$ because of IGM absorption; this makes the use of near-IR bands necessary. Ongoing near-IR surveys such as the United Kingdom Infrared Telescope (UKIRT) Infrared Deep Sky Survey \citep[UKIDSS; ][]{Lawrence2007}, the Visible and Infrared Survey Telescope for Astronomy (VISTA) Kilo-degree Infrared Galaxy\citep[VIKING; ][]{Emerson2004}, the Panoramic Survey Telescope \& Rapid Response System \citep[Pan-STARRS; ][]{Kaiser2010}, the Dark Energy Survey \citep[DES; ][]{DES2016}, the VISTA Hemisphere Survey \citep[VHS; ][]{McMahon2013}, and the Subaru HSC-SSP Survey with the Subaru High-z Exploration of Low-Luminosity Quasars (SHELLQs) project \citep{Miyazaki2012, Matsuoka2016} have started to increase the number of known $z \gtrsim 6.5$ quasars by employing filters centred on $\rm{1\,\mu m}$. The use of such data allowed \citet{Mortlock2011} to discover the previous redshift record holder, ULAS J1120+0641 at $z=7.09$, before it was superceded by ULAS J1342+0928 at $z=7.54,$ for which \citet{Banados2018} mined data from the UKIDSS Large Area Survey \citep{Lawrence2007}, the Wide-field Infrared Survey Explorer \citep[ALLWISE, ][]{Wright2010}, and the DECam Legacy Survey (DECaLS\footnote{\url{http://legacysurvey.org/decamls/}}). However, despite all these efforts, these two quasars are the only ones found at redshift $z > 7$ to date. The Canada-France High-z Quasar Survey in the Near Infrared (CFHQSIR) has been designed to find more $z \sim 7$ quasars that can be used to constrain the reionisation epoch as well as the initial growth of SMBHs. \\ The inevitable contamination of any photometric sample by Galactic low-mass stars (main-sequence stars and brown dwarfs) increases the difficulty of finding such rare objects. Colour-colour cuts are commonly used for high-z quasars searches to separate the two populations of sources \citep[e.g.][]{Willott2005, Venemans2013}. However, the photometric noise implies that the resulting candidate list is likely to be still dominated by low-mass stars, which are much more numerous than high-z quasars. Here we adopt a powerful classification technique that is based on Bayesian inference. It was first developed by \citet{Mortlock2012} but was also applied by \citet{Matsuoka2016}, who discovered 39 quasars in the redshift range $5.7 \leq z \leq 6.9$ \citep{Matsuoka2016, Matsuoka2018}. The technique allows assigning to each candidate a probability of being a high-z quasar rather than a low-mass star by combining all the information (observations and prior knowledge) available for each source in an optimal way. Although this approach has not been frequently used, it has proved to be a powerful method since \citet{Mortlock2011} successfully found the second most distant quasar at redshift $z = 7.09$. \\ This paper describes an improved method for searching for $z\sim 7$ quasars, and we report our initial results. In the next section we present the CFHQSIR data and our colour selection criteria. In Sect. \ref{sec3} we describe our photometric candidate selection and detail our Bayesian method of classifying candidates. Our spectroscopic observations and initial results are presented in Sect. \ref{secresults}. Section \ref{sec5} summarises these results and presents our conclusions. All magnitudes in the optical and near-IR bands in this paper are in the AB system. Cosmological parameters of $\rm{H_{0}} = 68$ \mbox{km s$^{-1}$ Mpc$^{-1}$}, $\rm{\Omega _{M} = 0.31}$ and $\rm{\Omega _{\Lambda} = 0.69}$ are assumed throughout \citep{Planck2016}. \section{Searching for high-z quasars in the CFHQSIR survey} \label{sec2} At high redshifts, neutral hydrogen in the IGM induces a complete absorption of the quasar flux blueward of the Ly-$\alpha$ line at $\rm{\lambda_{Ly\alpha}} = 1216\,\AA$. A $z \sim 7$ quasar has a clear photometric signature: it is relatively bright in the NIR above $\rm{1\,\mu m}$ and is totally extinguished in all optical bands. We therefore searched for $z \sim 7$ quasars through Y-band imaging of the CFHTLS Wide fields for which deep optical data exist. We briefly describe our CFHQSIR Y-band data in Sect. \ref{subcfhqsir}. We discuss our colour selection criteria in Sect. \ref{simulcolor} . \subsection{CFHQSIR survey} \label{subcfhqsir} The CFHQSIR is a CFHT Large Program carried out at the 3.6m CFH telescope with the Wide field IR camera (WIRCam) from 2011 to 2013. It aims to extend the highly successful $5.8 < z < 6.5$ CFHQS survey \citep{Willott2005, Willott2007, Willott2009, Willott2010} to higher redshifts. The CFHQSIR covers $\sim 130$ deg$^2$ over the four CFHTLS Wide fields up to a $5\,\sigma$ limiting magnitude of $\mathrm{Y_{lim} \approx 22.4}$ for point sources and is characterised by an average image quality of 0.7\arcsec. The data were obtained in two epoch observations separated by at least 20 days in order to discard transient sources and slow-moving objects. We refer to \citet{Pipien} for further details about the CFHQSIR data. \\ Assuming the quasar luminosity function derived by \citet{Willott2010} at $z = 6$ and considering a pure density evolution with redshift, we estimated the expected number of high-z quasars in the CFHQSIR survey. About $2.3$ quasars are expected in the redshift range $6.78 < z < 7.48$ down to $\rm{M_{1450}} = -24.6$. A completeness correction in magnitude and redshift, as computed in \citet{Pipien} (Fig. 12) and in Sect. \ref{lowmass} (Fig. \ref{complredshift}), respectively, was applied to derive the predicted number. This number decreases from $2.3$ to $1.4$ when considering the quasar luminosity function and evolution from \citet{Jiang2016}, for which a steeper redshift evolution of the quasar density between $z \sim 5$ and $z \sim 6$ was demonstrated. Given this small number, it is therefore necessary to adopt a reliable selection procedure to efficiently identify and classify high-z quasar candidates. This is further described in Sects. \ref{simulcolor} and \ref{sec3}. \subsection{Simulating the colours of quasars and low-mass stars} \label{simulcolor} Our selection of $z \sim 7$ quasar candidates is based on a combination of our CFHQSIR NIR (Y band) and optical data from the 7th and final release (T0007) of the CFHTLS (u-, g-, r-, i-, z- bands) produced by Terapix. At redshifts $z \gtrsim 6.0$, the strong break across the Ly-$\alpha$ line known as the Gunn-Peterson effect makes colour selection the most efficient way for selecting high-z quasars over large areas. At redshifts $z \gtrsim 6.5$, quasars can therefore be selected as z-band dropouts as their spectrum is totally extinguished in the u, g, r, and i bands. As demonstrated by \citet{Venemans2013} for the VIKING survey and by \citet{Mortlock2011} for UKIDSS, the most efficient way of distinguishing high-z quasar and low-mass stars, their main source of contamination, is to use J-band photometry. In order to optimise our colour selection criteria, we performed simulations of the expected optical and near-IR colours of quasars and low-mass stars as measured with the CFHT MegaCam (z filter) and WIRCam cameras (Y and J filters). The simulations are detailed in the following subsections. \subsubsection{High-redshift quasars} \label{simulqso} Based on a principal component analysis (PCA) of 78 $z\sim3$ quasar spectra of the SDSS-DR7, \cite{Paris_2011} derived the principal components characterising the quasar continuum and the PCA eigenvectors. We used the reported values of \citet{Paris_2011} (Table 2) of the distribution of their weights to simulate quasar mock spectra. We decided to consider only the first four components since $95\,\%$ of the variance affecting the 78 quasar spectra are represented by these components (I. Pâris, private communication). We assumed that the spectral index, equivalent width, and intensity of the quasar emission lines at redshifts $z \sim 3$ are representative of the $z \sim 7$ quasar population. The intrinsic quasar luminosity plays an important role in validating this hypothesis since this quantity is anti-correlated with the line equivalent widths \citep[Baldwin effect, ][]{Baldwin1977}. As observed with the two most distant quasars ever discovered at redshift 7.1 and 7.5 \citep{Mortlock2011, Banados2018}, quasar spectra at low- and high-z match remarkably well: the intrinsic luminosities of high-z quasars coincide with those observed at lower redshifts and thus justify the use of $z\sim 3$ quasar spectra. We generated 1\,000 rest-frame quasar spectra, redshifted them in the redshift range $6.2 \leq z \leq 7.6$, and introduced IGM absorption assuming the transmission function of \citet{Meiksin2006}, where the transmitted flux at $ z \gtrsim 6.5$ was set to zero blueward of the Ly-$\alpha$ line due to the Gunn-Peterson trough. We then convolved the 1\,000 simulated quasar spectra with the z (MegaCam), Y, and J (WIRCam) CFHT filters including the atmospheric transmission. Fig. \ref{colorsdiag} shows the $\rm{(z-Y)}$ and $\rm{(Y-J)}$ colours obtained for all simulated quasar spectra. As expected, the quasar track shows a strong evolution of the $\rm{(z-Y)}$ colour with redshift, reflecting the movement of the Ly-$\alpha$ break through the z filter. At redshifts $z \lesssim 7.0$, the Ly-$\alpha$ emission line is in the z band, and it enters the Y band at $z \sim 7$. At higher redshifts, quasars become rapidly fainter in the z band and therefore redder in $\rm{(z-Y)}$. At redshifts $z \gtrsim 7.4$, the Ly-$\alpha$ break is redward of the z filter so that these quasars are entirely extinguished in this band. \begin{figure}\centering \includegraphics[width=0.45\textwidth]{figures/colors.png} \caption{Diagram of $\rm{(z-Y)}$ vs. $\rm{(Y-J)}$ in the CFHT filters for simulated quasars and observed low-mass stars from the SpeX Prism library (triangles in yellow, brown, and red show M, L, and T dwarfs, respectively). The blue curve represents the colours of the mean quasar derived by \citet{Paris_2011} for which IGM absorption is included. The grey curves show the tracks in colour-colour space of the 1\,000 quasars redshifted from $z = 6.2$ to $z=7.7$. The blue dashed lines correspond to the colour criteria chosen to select quasars of redshift $z \sim 7$.} \label{colorsdiag} \end{figure} \subsubsection{Low-mass stars} \label{lowmass} We determined the expected colours of main-sequence stars and brown dwarfs (M, L, and T spectral types) based on a sample of observed spectra from the SpeX Prism library\footnote{The SpeX Prism Library and the SpeX Prism Library Analysis Toolkit are maintained by Adam Burgasser at \url{http://www.browndwarfs.org/spexprism}}. Only spectra covering the z (MegaCam), Y, and J (WIRCam) filters were used. More than 1\,300 spectra of sources with spectral types from M3 to T9 were exploited. The resulting colours computed in these filters are shown in Fig. \ref{colorsdiag}. M and L-dwarfs represent a minor source of contamination compared to the much cooler T-dwarf population, which shows very similar $\rm{(z-Y)}$ colours to $z \sim 7$ quasars. However, the spectral distribution of T-dwarf peaks in the J band, leading to a significantly redder $\rm{(Y-J)}$ colour than quasars and thus allows a clear separation between the two populations of objects. \\ The box bounded by the blue dashed lines in Fig. \ref{colorsdiag} indicates our colour-colour high-z quasar selection criteria: \begin{empheq}{align} \label{eqcolor} \begin{cases} \rm{z-Y} \geq 1.5 \\ \rm{Y-J} \leq 0.5 \end{cases} \end{empheq} \subsubsection{Colour-selection completeness} To study the quasar selection efficiency as a function of redshift more precisely, we followed the approach developed by \citet{Willott2005} by calculating the fraction of artificial quasars that satisfies the criteria of Eq. \ref{eqcolor} as a function of redshift. In order to take into account photometric errors affecting the measurement of the $\rm{(z-Y)}$ and $\rm{(Y-J)}$ colours, each simulated quasar colour was described by a Gaussian probability density distribution with a standard deviation noted $\sigma_{c}$. We note, however, that as discussed in Sect. \ref{bayesian}, it would be more accurate to model each Gaussian in flux units rather than in magnitude units. Figure \ref{complredshift} shows the resulting fraction of high-z quasars falling into the colour-colour box delimited by Eq. \ref{eqcolor}. The different curves illustrate the change in completeness as a function of the error in colours. To take into account the correlated noise, each photometric error was multiplied by a corrective excess noise factor derived for each image \citep[see][for further details]{Pipien}. Figure \ref{complredshift} allows us to define the redshift range probed by our survey for a given completeness. Adopting $\sigma_{c} = 0.5$ as representative of the errors in colours for our sources, the CFHQSIR redshift range corresponding to a completeness greater than 50\% is $6.78 < z < 7.48$. \begin{figure}\centering \includegraphics[width=0.45\textwidth]{figures/completess_redshift2.png} \caption{Fraction of high-z quasars satisfying the colour selection criteria of Eq. \ref{eqcolor} as a function of redshift. Different photometric uncertainties on $\rm{(z-Y)}$ and $\rm{(Y-J)}$ are taken into account, from $\sigma_{c} = 0.1$ to $\sigma_{c} = 0.5$. } \label{complredshift} \end{figure} \section{Photometric candidate selection and Bayesian classification} \label{sec3} \subsection{Initial candidate selection} Using the SExtractor software \citep{Bertin1996}, we produced catalogues of objects detected in the Y-band images. We first ran SExtractor in dual-image mode for source detection in Y-band images and photometry in all bands (u, g, r, i, z, and Y). We set the detection threshold to 1.5$\,\sigma$ above the background and required at least four connected pixels for a measurement. This double analysis of our near-IR and optical data reveals a total of $\sim$ 6 million sources detected in Y band. We then applied some automatic cuts including geometric and photometric criteria in order to keep the reddest point-like sources and remove the faintest objects in Y band. We set the following criteria: no detections in the u, g, r, and i filters, $\rm{(z-Y)}$ > 1.0, $Y \leq 23.0$ ($\rm{M_{1450}\lesssim}-$24.0), and a signal-to-noise ratio $\rm{(S/N)_{Y}} \gtrsim 4$. All magnitudes were measured using the SExtractor \texttt{MAG\_AUTO} parameter. In total, $\sim$ 54\,000 objects satisfied these criteria and were selected. They were then inspected by eye in order to discard artefacts. We note that the main source of non-physical contamination comes from persistences. These effects occur in IR detectors when a saturated star observed in a previous exposure leaves a remnant image in the following exposures. These spurious sources appear in two different forms in our Y-band images. When the persistence is generated during an exposure with no connection with our observations, a single spot appears in our Y-band image. Since our observations were split into two epochs separated by at least 20 days, these spurious sources were easily spotted by inspecting our individual Y-band images before stacking \citep[for more details, see][]{Pipien}. The second form of persistence contaminating our data arises directly during our observations between two dithered exposures. This type of persistence is also easily identified since Y-band images show bright spots aligned according to the dither pattern. After eliminating these artefacts from our candidate list, we repeated the photometric measurements using SExtractor in single-image mode, which optimises the detection threshold and recentres the apertures. This process allowed us to remove sources with proper motion. We then again applied the same colour criteria as previously ($\rm{(z-Y)}$ > 1.0 and no detection in the u, g, r, and i filters) with these new measurements and selected 228 sources in this way. As discussed in Sect. \ref{sec2}, J-band photometry is necessary to distinguish high-z quasar candidates from low-mass stars. J-band follow-up observations were carried out at CFHT using the WIRCam camera, but also the SOFI (son of Isaac) and LIRIS (Long-slit Intermediate Resolution Infrared Spectrograph) cameras mounted on the 3.6m New Technology Telescope (ESO NTT) and the 4.2m William Herschel Telescope (WHT), respectively. The detectors used by SOFI and LIRIS are HgCdTe 1024 $\times$ 1024 Hawaii arrays with pixel scales of 0\arcsec.288. and 0\arcsec.251, respectively. LIRIS data were reduced using the Image Reduction and Analysis Facility (IRAF\footnote{IRAF is distributed by the National Optical Astronomy Observatory, which is operated by the Association of Universities for Research in Astronomy (AURA) under a cooperative agreement with the National Science Foundation.}), and SOFI images were reduced with the SOFI pipeline\footnote{\url{https://www.eso.org/sci/facilities/lasilla/instruments/sofi/tools/SofI_Pipeline.html}}. The photometric calibration for both datasets was performed following a method similar to that presented in \citet{Pipien}. We astrometrically calibrated the LIRIS images with the SCAMP\footnote{\url{https://www.astromatic.net/pubsvn/software/scamp/trunk/doc/scamp.pdf}} software and used the on-line service \href{http://nova.astrometry.net/}{Astrometry.net} for SOFI images.\\ We combined our follow-up observations with existing data when available, coming from the Canada France Brown Dwarfs Survey \citep[CFBDSIR, J band; ][]{Delorme2008}, the Visible and Infrared Survey Telescope for Astronomy \citep[VISTA-VHS, J-, H-, and $\rm{K_{s}}$-bands; ][]{McMahon2013}, and the Vimos Public Extragalactic Redshift Survey \citep[VIPERS-Multi-Lambda Survey, $\rm{K_{s}}$ band; ][]{Moutard2016}. This allowed us to apply the colour cuts defined in Eq. \ref{eqcolor} and to confirm the reality of these objects. We identified a total of 36 high-z quasar candidates that are represented in the $\rm{(z-Y)}$ versus $\rm{(Y-J)}$ diagram of Fig. \ref{diag_cands}. Magnitudes were measured in 2.5\arcsec apertures, and aperture corrections were applied to give the total magnitudes. Non-detected objects in the z and/or J band (arrow points in Fig. \ref{diag_cands}) show colours outside the dashed selection region. The colour cuts defined in Eq. \ref{eqcolor} were not applied to these sources, as they only have a $5\,\sigma$ magnitude lower limit in these bands. Two sources in the W4 field showed blueer $\rm{(Y-J)}$ colours ($\rm{(Y-J)} < -0.5$) than the other candidates. Although they were not detected in the z or J filters, they are not spurious objects and remain candidates because they were both detected in the VIPERS $\rm{K_{s}}$ band. As shown in Fig. \ref{colorsdiag}, in the absence of photometric noise, high-z quasars and low-mass stars are expected to occupy a well-defined region in colour-colour space so that it is, in principle, possible to distinguish the two populations of objects by applying simple colour cuts. However, because high-z quasars are outnumbered by brown dwarfs and large photometric errors affect the faintest sources, this implies that most of our candidates are likely brown dwarfs scattered in the selection box defined in Eq. \ref{eqcolor}. In the next section, we present an alternative approach to the application of hard cuts based on Bayesian inference, which allowed us to classify our candidates in the best possible way according to their probability of being a high-z quasar rather than a brown dwarf. \begin{figure*}[ht!] \centering \includegraphics[width=0.85\textwidth]{figures/diagcands.png} \caption{Colour-colour diagram showing the 36 high-z quasar candidates (blue points) identified in the four CFHTLS Wide fields. The arrow points correspond to a $5\,\sigma$ magnitude lower limit in the case of a non-detection in the z and/or J band.} \label{diag_cands} \end{figure*} \subsection{Bayesian classification method} \label{bayesian} The Bayesian classification method allows introducing priors (e.g. the relative number of high-z quasars compared to the number of brown dwarfs), as opposed to the posterior distribution, which also includes observational data. The strength of this method is that a ranking of all candidates can be optimally established in a coherent statistical framework by combining all the information available for each object. In this section, we adapt and extend the Bayesian approach developed by \citet{Mortlock2012} to the CFHQSIR survey.\\ We assumed that the most important contamination comes from the low-mass stars and that artefacts and any other sources of contamination have been removed from our candidates list. We therefore considered only two population types: the high-z quasars, and the low-mass stars, for which we developed parametric models (see Sects. \ref{qsopop} and \ref{qsopop}).\\ Given a photometric dataset, we need to define the probability that a source detected in the CFHQSIR survey is a high-z quasar rather than a low-mass star. The answer is given by the conditional posterior probability, which can be estimated with the Bayes theorem by comparing parametric models for high-z quasars and low-mass stars. For a detected source with photometric measurements $\rm{\overrightarrow{d}}$, this probability is defined by \begin{equation} \rm{P_{q}=Pr(q|\overrightarrow{d})=\frac{W_{q}(\overrightarrow{d})}{W_{q}(\overrightarrow{d})+W_{s}(\overrightarrow{d})}} \mathrm{,} \end{equation} where the weighted evidence terms are given by \begin{equation} \begin{multlined} \rm{W_{q/s}(\overrightarrow{d})} \\ = \int \rm{\rho_{q/s}(\overrightarrow{p})}\:\rm{Pr(det\, |\, \overrightarrow{p}, q/s)}\:\rm{Pr(\overrightarrow{d}\, |\, \overrightarrow{p}, q/s)}\:\rm{d\overrightarrow{p}}. \end{multlined} \end{equation} Here the subscripts $\rm{q}$ and $\rm{s}$ denote the high-z quasars and low-mass stars, respectively. The vector $\overrightarrow{p}$ corresponds to the parameters used to model the quasar and stars populations. The quantity $\rm{\rho_{q/s}(\overrightarrow{p})}$ represents the surface density of quasars or low-mass stars as a function of their intrinsic properties $\rm{\overrightarrow{p}}$. The functions $\rm{Pr(det\, |\, \overrightarrow{p}, q/s)}$ and $\rm{Pr(\overrightarrow{d}\, |\, \overrightarrow{p}, q/s)}$ are the probability that the source (quasar or star) is detected (det) and the probability that the source is observed with the photometric measurements $\rm{\overrightarrow{d}}$, each as a function of $\rm{\overrightarrow{p}}$.\\ As pointed out in \citet{Mortlock2012}, because the probability of a source to be a high-z quasar cannot be determined without at least some observational information (e.g. colour measurements), the assumption is justified that the source has to be detected in the survey (in at least the Y band in our case). \\ This constraint does not, however, exclude the possibility that some candidates may be not detected in one or more photometric bands. This is especially important for high-z quasars, which can have negligible flux blueward of their Ly-$\alpha$ emission lines. Furthermore, a non-detection can lead to negative flux; this effect directly results from the photometric noise and is described in detail in \citet{Mortlock2012}. Given that such measurements cannot be converted into traditional logarithmic magnitudes \citep{Pogson1856}, we decided to follow the approach developed by \citet{Mortlock2012} by working in terms of flux units. In the following, for each population, stars or quasars, we therefore considered the observational dataset given by $\rm{\overrightarrow{d} = \left ( F_{z_{obs}}, F_{Y_{obs}}, F_{J_{obs}} \right )}$, where $\rm{F_{z_{obs}}}$, $\rm{F_{Y_{obs}}}$, and $\rm{F_{J_{obs}}}$ are the observed flux of the candidates in the z, Y, and J bands, respectively. In the case of non-detections (in z or J), a flux is measured at the exact position where the object has been detected in Y band, using the SExtractor software in double-image mode. \subsubsection{Quasar population} \label{qsopop} Our prior knowledge is given by the surface density of quasars $\rm{\rho_{q}(\overrightarrow{p})}$, which can be calculated with the quasar luminosity function of \citet{Willott2010}, noted $\Phi (\rm{M_{1450}},z)$. This function suggests the use of two parameters for the quasar population modelling: the rest-frame absolute magnitude $\rm{M_{1450}}$ , and the redshift $z$. However, we chose to work with the Y-band apparent magnitude instead of the absolute magnitude for practical reasons. The parameter set that describes the high-z quasar population is thus given by $\overrightarrow{p} = \left \{ \rm{Y_{mod}}, \textit{z}\right \}$, where $\rm{Y_{mod}}$ represents the modelled Y-band magnitude of the quasar. In the following, the subscript mod refers to fluxes and magnitudes estimated for the high-z quasar and low-mass star models. The surface density in \mbox{mag$^{-1}$ sr$^{-1}$ redshift$^{-1}$} can be written as a function of these two parameters: \begin{equation} \rm{\rho_{q}}(\rm{Y_{mod}},\textit{z}) = \frac{1}{4\pi} \times \frac{dV_{c}}{d\textit{z}} \times \Phi \left [ \rm{Y_{mod}}-\mu - K_{corr}(\textit{z}),\textit{z} \right ] \mathrm{,} \end{equation} where $\mu$ is the distance modulus defined as a function of the luminosity distance $D_{L}$ by $\mu = 5log_{10}\left ( D_{L}/10\,\rm{pc}\right )$, $\rm{K_{corr}}(\textit{z})$ is the K-correction that converts the absolute magnitude at rest-frame 1450 $\AA$ into the observed Y-band magnitude, and $1/4\pi \times \rm{dV_{c}/d\textit{z}}$ is the comoving volume element per steradian and per redshift interval d$\textit{z}$.\\ For a given high-z quasar spectrum $\rm{q_{i}}$, the weighted evidence in \mbox{mag$^{-3}$ deg$^{-2}$} is \begin{equation} \label{Wqi} \begin{multlined} \rm{W_{q_{i}}}(\rm{z_{obs}}, \rm{Y_{obs}}, \rm{J_{obs}},\rm{det}) \\ = \int_{-\infty}^{+\infty} \int_{0}^{+\infty}\,\rho_{\rm{q_{i}}}(\rm{Y_{mod}},\textit{z})\,\rm{Pr(det | Y_{mod}}, \textit{z}, \rm{q_{i}}) \\ \times \rm{Pr(z_{obs}, Y_{obs}, J_{obs} | Y_{mod}}, \textit{z}, \rm{q_{i}) \,dY_{mod}}\,d\textit{z}. \end{multlined} \end{equation} Since the Y band is the detection band of our survey, we modelled the probability $\rm{Pr(det | Y_{mod}, \textit{z}, q_{i})}$ with the completeness rate derived in \citet{Pipien}, which corresponds to a function varying between 0 and 1 and is characterised by a magnitude limit at 80 \% completeness of the order of $\rm{Y_{lim}} \sim 22.5$. \\ In the case of faint sources observed photometrically in the NIR, the Poissonian photon noise can reasonably be neglected. As most of our candidates are relatively faint (Y $\sim 21.0 - 23.0$), their photometric errors are dominated by background noise uncertainties, which are typically described by a normal distribution in flux. Ignoring the inter-band correlations, the probability $\rm{Pr(z_{obs}, Y_{obs}, J_{obs} | Y_{mod}, \textit{z}, q_{i})}$ is then given by a product of three Gaussians, each associated with one filter (z, Y or J), which, after conversion into magnitude units, is defined as \begin{equation} \begin{multlined} \label{vraisemblance} \rm{Pr(z_{obs},Y_{obs}, J_{obs} | Y_{mod}, z, q_{i})} \\= \prod_{\rm{b}=1}^{\rm{N_{b}}=3} \frac{1}{\sqrt{2\pi}\sigma_{b}} \times \exp \left ( -\frac{1}{2} \left [ \frac{\rm{F_{b_{obs}}}-\rm{F_{b_{mod}}}(\overrightarrow{p})}{\sigma_{b}} \right ]^{2}\right ) \times \left | \frac{\rm{dF_{b_{mod}}}}{\rm{dm_{b_{mod}}}} \right | , \end{multlined} \end{equation} where the index b refers to the three bands considered here, b $= \left ( \rm{z, Y, J} \right)$, and $\rm{N_{b}}$ is the number of bands used. $\sigma_{b}$ represents the photometric errors following a Gaussian distribution in flux units. The Jacobian used to convert the probability from flux units into magnitude units is \begin{equation} \left | \frac{\rm{dF_{b_{mod}}}}{\rm{dm_{b_{mod}}}} \right | = \frac{2ln(10)\rm{F_{b_{mod}}}}{5} \mathrm{,} \end{equation} where the model flux $\rm{F_{b_{mod}}}$ in the b band is given as a function of the zero-point flux noted $\rm{F_{0}}$, \begin{equation} \label{convertflux2} \rm{F_{b_{mod}} = F_{0} e^{-2ln(10)m_{mod}/5}}.\\ \end{equation} We refer to Appendix A2 of \citet{Mortlock2012} for a complete description of the magnitude - flux conversion for probability densities.\\ In Eq. \ref{Wqi}, the surface density $\rm{\rho_{q_{i}}(Y_{mod},\textit{z})}$ and the probability $\rm{Pr(z_{obs},Y_{obs}, J_{obs} | Y_{mod}, \textit{z}, q_{i})}$ are estimated for one single quasar template noted $\rm{q_{i}}$. We modelled the diversity of intrinsic properties of high-z quasars by considering 80 quasar templates, generated according to the method described in Sect. \ref{simulqso}. After assigning an equivalent weight to each quasar template $\rm{q_{i}}$, we write the final weighted evidence as the average of the evidences $\rm{W_{q_{i}}}$ over the $\rm{N_{temp}} = 80$ templates: \begin{equation} \rm{W_{q}(z_{obs},Y_{obs}, J_{obs},det)} = \frac{1}{N_{temp}} \sum_{i=1}^{N_{temp}=80} \rm{W_{qi}(z_{obs}, Y_{obs}, J_{obs},det)} \mathrm{.} \end{equation} \subsubsection{Brown dwarf population} \label{starpop} Given the colour criteria applied previously ($\rm{z-Y}$ $\geq$ 1.5, $\rm{Y-J}$ $\leq$ 0.5 and no detections in the u, g, r, and i filters), we determined the dominant source of contamination. To do this, we used a spectroscopic sample of M, L, and T stars from the SpeX Prism library covering the i, z, Y, and J bands. Most of the main-sequence stars are far bluer than high-z quasars, so that they do not represent a significant source of contamination. Conversely, T dwarfs are undetected in the i band, have $\rm{z-Y}$ colours mimicking $z \sim 7$ quasars, and noise can scatter their $\rm{Y-J}$ colours inside the selection box of Fig. \ref{colorsdiag}. In M and L dwarfs, sources with $\rm{i-z} \gtrsim \rm{i_{lim}-z_{lim}} = 0.9$ ($\rm{i_{lim} = 24.8}$ and $\rm{z_{lim} = 23.9}$ are the 80\% completeness limits for point sources in the i and z bands respectively, from the CFHTLS-T0007 release\footnote{\url{http://www.cfht.hawaii.edu/Science/CFHTLS/T0007/}}.) can be undetected in the i band, and therefore they are likely to be scattered into our candidate list. This limit is represented by a vertical dashed line in Fig. \ref{justifyBD}, where the observed colours of low-mass stars and of our z-band detected candidates are shown. \\ Here again, noise can scatter $\rm{z-Y}$ colours into our $\rm{z-Y}$ $\geq$ 1.5 criterion, and we therefore chose to adopt a more conservative limit for the contamination by low-mass stars of $\rm{z-Y} > 1.0$. Figure \ref{justifyBD} shows that this approximately corresponds to an L0 spectral type. For this reason, our brown dwarf model is based on a spectroscopic sample of 633 L dwarfs and 180 T dwarfs from the SpeX Prism library, with spectral types from L0 to T9. Hereafter, we assume that these observed spectra are representative of the colour distribution of the entire L- and T-dwarf populations.\\ We chose two parameters to model the brown dwarf population, the apparent magnitude $\rm{Y_{mod}}$ , and the spectral type spt: $\rm{\overrightarrow{p} = \left \{ Y_{mod}, spt\right \}}$. \\ We computed the brown dwarf surface density $\rm{\rho_{s}(\overrightarrow{p})}$ using the Galactic spatial density model of late-L and T dwarfs developed by \citet{Caballero2008}. With this model, we calculated the spatial density distribution of late-type dwarfs at a given Galactic coordinate as a function of luminosity for each spectral type. A complete description of the spatial variation of the density of late dwarfs is given in \citet{Caballero2008}, so we here report only the main calculation steps. We considered the standard Galactic model and followed the same approach as \citet{Caballero2008} by only taking into account the Galactic thin disc, which can be modelled by a double exponential law \citep[e.g.][]{Chen2001}. As discussed in detail in \citet{Caballero2008}, brown dwarfs from the Galactic thick disc and halo can be neglected for two reasons. First, the thick disc and the halo are more rarified and extended than the thin disc. Secondly, thick-disc and halo stars are thought to be very old \citep[ages $\gtrsim$ 10 Ga, see e.g.][]{Feltzing2003}: they are therefore extremely faint and hardly detectable, according to the general cooling theory for brown dwarfs \citep[see e.g.][]{Baraffe2003}. The space density for an object of spectral type $\rm{spt}$ at Galactic coordinates $(l,b)$ and heliocentric distance $d$ is given by \begin{equation} \label{eqtrue1} n_{\rm{spt}}(d,l,b) = n_{0,\rm{spt}}\,\exp\left({ -\frac{R(d,l,b)-R_{\odot}}{h_{R}}}\right) \exp\left({-\frac{|Z_{\odot}+dsin(b)|}{h_{Z}}}\right) \mathrm{,} \end{equation} where $Z_{\odot}$ is the height of the Sun relative to the Galactic plane, $h_{R}$ and $h_{Z}$ are the length and height scales of the thin disc, respectively, and $n_{0,\rm{spt}}$ is the space density at the Galactic plane ($Z=0$) and at the distance to the Galactic centre ($R = R_{\odot}$). The values of the main parameters of the Galaxy thin disc are listed in Table \ref{tablebd}. Since CFHQSIR observations correspond to extragalactic fields, the Galactocentric distance of the object $R(d,l,b)$ can be approximated as follows, under the assumption $R_{\odot} \gg d$: \begin{equation} \label{eqapprox1} R(d,l,b) \approx R_{\odot} - d\cos(b)\cos(l) \mathrm{.} \end{equation} In this approximation, Eq. \ref{eqtrue1} can be rewritten as \begin{equation} \label{eqapprox2} n_{\rm{spt}}(d,l,b) \approx n_{0,\rm{spt}}\, \exp \left({\frac{\mp Z_{\odot}}{h_{Z}}}\right) \exp \left[{-d\left(-\frac{\cos(b)\cos(l)}{h_{R}}\pm \frac{\sin(b)}{h_{Z}}\right)}\right] \mathrm{,} \end{equation} where the sign convention indicates if $d\sin(b)$ is greater or lower than $Z_{\odot}$, that is, whether the object is above or below the Galactic plane. At null heliocentric distance, the local spatial density of an object of spectral type $\rm{spt}$, noted $\rm{n_{\odot}}$, is then \begin{equation} \label{denslocal} n_{\rm{spt}}(R = R_{\odot}, Z = Z_{\odot}) = n_{0,\rm{spt}}\, \exp\left({-\frac{Z_{\odot}}{h_{Z}}}\right) = n_{\odot} \mathrm{.} \end{equation} Fig. \ref{nsol} shows $\rm{n_{\odot}}$ as a function of spectral type. For L0-T7 dwarfs, we used the predicted densities reported in \citet{Caballero2008} that we took from \citet{Burgasser2007}. The densities for the T8 and T9 spectral types are extrapolated values.\\ \begin{figure}[ht]\centering \includegraphics[width=0.45\textwidth]{figures/diagram_imz_zmY_paper.png} \caption{Observed colours of low-mass stars (spectra from the SpeX Prism library) of spectral types M3 (blue) to T8 (red). Colours of our high-z quasar candidates detected in the z band are also shown as magenta points. The box bounded by the dashed lines defines the spectral types that are likely to contaminate our candidate list.} \label{justifyBD} \end{figure} \begin{table}[ht] \caption{Main parameters of the Galactic thin disc used in \citet{Caballero2008} adopted from \citet{Chen2001}} \label{tablebd} \centering \begin{tabular}{c c c c} \hline\hline $R_{\odot}$(pc) & $Z_{\odot}$(pc) & $h_{R}$(pc) & $h_{Z}$(pc) \\ \hline $8600\pm200$ & $+27\pm4$ & $2250\pm1000$ & $330\pm3$ \\ \hline \end{tabular} \end{table} \begin{figure}\centering \includegraphics[width=0.45\textwidth]{figures/nsol.png} \caption{Local spatial density $\rm{n_{\odot}}$ of late dwarfs as a function of spectral type. The blue points refer to the values given in \citet{Caballero2008}, and the red points correspond to extrapolated values.} \label{nsol} \end{figure} \citet{Caballero2008} defined two auxiliar variables, $n_{A,\rm{spt}}$ and $d_{B}(l,b)$ to simplify calculations: \begin{equation} n_{A,\rm{spt}} = n_{0,\rm{spt}}\,\exp\left({\frac{\mp Z_{\odot}}{h_{Z}}}\right) = \begin{cases} n_{A+,\rm{spt}} = n_{0,\rm{spt}}\,\exp \left({\frac{- Z_{\odot}}{h_{Z}}}\right)\,\,\text{if $Z > 0$} \\ \\ n_{A-,\rm{spt}} = n_{0,\rm{spt}}\,\exp \left({\frac{+ Z_{\odot}}{h_{Z}}}\right)\,\,\text{if $Z < 0$} \end{cases} \mathrm{,} \end{equation} \begin{equation} \label{db} \frac{1}{d_{B}(l,b)} = -\frac{\cos(b)\cos(l)}{h_{R}} \pm \frac{\sin(b)}{h_{Z}} \mathrm{,} \end{equation} with \begin{equation} \label{db2} \begin{cases} \frac{1}{d_{B+}(l,b)} = -\frac{\cos(b)\cos(l)}{h_{R}} + \frac{\sin(b)}{h_{Z}} \,\,\text{if $Z > 0$},\\ \\ \frac{1}{d_{B-}(l,b)} = -\frac{\cos(b)\cos(l)}{h_{R}} - \frac{\sin(b)}{h_{Z}} \,\,\text{if $Z < 0$}, \end{cases} \end{equation} Based on Eqs. 12 and 14 of \citet{Caballero2008}, we computed the brown dwarf surface density per spectral type $\rm{\rho_{s}(\textit{d},\rm{spt})}$ (in sr$^{-1}\,$spt$^{-1}$) as a function of the maximum heliocentric distance $d$ with \begin{equation} \label{rhoint} \rho_{s}(d,\rm{spt}) = \begin{cases} n_{A+,\rm{spt}} \int_{0}^{d} \exp \left({-\frac{z}{d_{B+}}}\right) z^{2}dz\,\,\text{if the field $\in$ NGP,}\\ \\ n_{A+,\rm{spt}} \int_{0}^{d_{*}} \exp \left({-\frac{z}{d_{B+}}}\right) z^{2}dz \\+ \, n_{A-,\rm{spt}} \int_{d_{*}}^{d} \exp \left({-\frac{z}{d_{B-}}}\right) z^{2}dz\,\,\text{if the field $\in$ SGP,}\\ \end{cases} \end{equation} where $d_{*} = -Z_{\odot}/\sin(b)$, and NGP and SGP refer to the north and south Galactic poles, respectively. We finally computed the maximum heliocentric distance $d$ beyond which a source with an absolute magnitude $\rm{M_{Y_{mod}}}$ can be detected, by solving the following equation: \begin{equation} \rm{Y_{mod} - M_{Y_{mod}} = 5log(\textit{d}) - 5 + A_{Y_{mod}}} \mathrm{,} \label{Ymoddens} \end{equation} where $\rm{A_{Y_{mod}}}$ corresponds to the attenuation in Y band. Table \ref{tab} presents an example of the obtained values for the distance $d$, considering a brown dwarf with an apparent magnitude $\rm{Y_{mod}}$ = 22.5.\\ Using Eq. \ref{rhoint} and \ref{Ymoddens}, we estimated the brown dwarf surface density $\rm{\rho_{s}(Y_{mod},spt)}$ as a function of the Y-band apparent magnitude for each spectral type in \mbox{mag$^{-1}$ deg$^{-2}$ spt$^{-1}$} units. \begin{table*} \caption{Characteristics of L and T dwarfs} \centering \begin{tabular}{ccccccc} \hline \hline \multirow{2}{*}{ \centering Spectral type spt} & \multirow{2}{*}{ \centering $\rm{M_{Y_{mod}}}$ (mag)} & \multirow{2}{*}{ \centering $\rm{n_{\odot}}$ (\mbox{10$^{-3}$ pc$^{-3}$ spt$^{-1}$})} & \multicolumn{4}{c}{\multirow{2}{*}{$d_{\rm{Y_{mod}}=22.5}$ (pc)}} \\ \\ & & & W1 & W2 & W3 & W4 \\ \hline \\ L0 & 13.21 & 0.637 & 695 & 702 & 687 & 666 \\ L1 & 13.62 & 0.861 & 579 & 584 & 573 & 558 \\ L2 & 14.09 & 1.000 & 470 & 473 & 466 & 456 \\ L3 & 14.54 & 0.834 & 383 & 385 & 380 & 374 \\ L4 & 15.00 & 0.819 & 311 & 312 & 309 & 305 \\ L5 & 15.40 & 0.869 & 259 & 260 & 258 & 255 \\ L6 & 15.76 & 0.785 & 220 & 221 & 220 & 217 \\ L7 & 16.09 & 0.644 & 190 & 191 & 190 & 188 \\ L8 & 16.21 & 0.462 & 180 & 180 & 179 & 178 \\ L9 & 16.36 & 0.308 & 167 & 168 & 167 & 166 \\ T0 & 16.39 & 0.22 & 165 & 166 & 165 & 163 \\ T1 & 16.39 & 0.241 & 166 & 166 & 165 & 164 \\ T2 & 16.36 & 0.406 & 167 & 168 & 167 & 165 \\ T3 & 16.23 & 0.788 & 178 & 178 & 177 & 176 \\ T4 & 16.32 & 1.42 & 171 & 171 & 170 & 169 \\ T5 & 16.35 & 2.38 & 168 & 169 & 168 & 166 \\ T6 & 16.60 & 3.45 & 150 & 151 & 150 & 149 \\ T7 & 17.11 & 4.82 & 119 & 119 & 119 & 118 \\ T8 & 17.96 & 6.19 & 81 & 81 & 81 & 81 \\ T9 & 19.25 & 7.56 & 45 & 45 & 45 & 44 \\ \hline \end{tabular} \tablefoot{$d$ is the maximum heliocentric distance for which a brown dwarf of a given spectral type and with an apparent magnitude $\rm{Y_{mod} = 22.5}$ can be detected. The absolute magnitudes $\rm{M_{Y_{mod}}}$ were computed by combining the absolute magnitude in the 2MASS J filter $\rm{M_{J_{2MASS}}}$ derived by \citet{Dupuy2012} for each spectral type, with the observed colours $\rm{Y_{mod} - J_{2MASS}}$ measured on the 813 brown dwarf spectra used in this study. We also reference the local spatial density $\rm{n_{\odot}}$ .} \label{tab} \end{table*} The weighted evidence for the brown dwarf population in \mbox{mag$^{-3}$ deg$^{-2}$} is given by \begin{equation} \label{poidsbd} \begin{multlined} W_{s}(\rm{z_{obs}},\rm{Y_{obs}},\rm{J_{obs}},\rm{det}) \\ = \int_{L0}^{T9} \int_{-\infty}^{+\infty} \rho_{s}(\rm{Y_{mod}},\rm{spt})\,\rm{Pr(det|Y_{mod},spt)}\\ \times \rm{Pr(z_{obs}, Y_{obs}, J_{obs}| Y_{mod},spt)}\,\rm{dY_{mod}}\,\rm{dspt} , \end{multlined} \end{equation} where $\rho_{s}(\rm{Y_{mod}},\rm{spt})$ is the surface density previously estimated, and the probabilities $\rm{Pr(det|Y_{mod},spt)}$ and $\rm{Pr(z_{obs}, Y_{obs}, J_{obs}| Y_{mod},spt)}$ are defined in the same way as for the quasar population.\\ We note with $\rm{N_{s, spt}}$ the number of brown dwarf spectra available for a spectral type spt. We decided not to reduce one spectral type to a unique pair of colour ($\rm{z_{mod}-Y_{mod}}; \rm{Y_{mod}-J_{mod}})$ but to consider instead each brown dwarf spectrum individually. This allowed us to estimate and account for the dispersion within a single spectral type. We first computed the weighted evidence associated with the $i$-th brown dwarf of spectral type spt, in \mbox{mag$^{-3}$ deg$^{-2}$ spt$^{-1}$}: \begin{equation} \begin{multlined} \rm{w}_{s,spt,i}(\rm{z_{obs}},\rm{Y_{obs}},\rm{J_{obs}},\rm{det}) \\ = \int_{-\infty}^{+\infty} \rho_{s}(Y_{mod,i},spt)\,\rm{Pr(det|Y_{mod,i},spt)}\\ \times \rm{Pr(z_{obs}, Y_{obs}, J_{obs}| Y_{mod,i},spt)}\,\rm{dY_{mod,i}}. \end{multlined} \end{equation} The probability $\rm{Pr(z_{obs}, Y_{obs}, J_{obs}| Y_{mod,i},spt)}$ was calculated in the same way as for the high-z quasar population: using Eq. \ref{vraisemblance} and associating the modeled flux with the observed brown dwarf colours. Each brown dwarf $i$ contributes the same to the weighted evidence associated with the spectral type spt, so that we can write \begin{equation} \label{moyspt} \rm{w}_{\rm{s,spt}}(\rm{z_{obs}},\rm{Y_{obs}},\rm{J_{obs}},\rm{det})= \frac{1}{\rm{N_{s,spt}}} \sum_{i=1}^{\rm{N_{s,spt}}} w_{\rm{s,spt},i}(\rm{z_{obs},Y_{obs},J_{obs},det}). \end{equation} Eq. \ref{poidsbd} then becomes \begin{equation} \rm{W_{s}}(\rm{z_{obs},Y_{obs},J_{obs},det}) = \int_{L0}^{T9} w_{\rm{s,spt}}(\rm{z_{obs},Y_{obs},J_{obs},det})\,\rm{dspt}, \end{equation} where dspt = 1 spt, with $\rm{spt}(L0) = 0$ and $\rm{spt}(L1) = 1$ etc. are as defined in \citet{Burgasser2007}. The latter integral can therefore be reduced to a simple sum over spectral types L0 to T9. \\ We based our Bayesian classification method on the formalism proposed by \citet{Mortlock2012} and improved the quasar and low-mass star modelling in several aspects that we describe below. \citet{Mortlock2012} used 12 different quasar templates spanning four line-strengths and three continuum slopes to account for the intrinsic diversity of the quasar population, while we based our high-z quasar model on 80 simulated quasar spectra, each with different spectral indices, emission line widths, and intensities. Furthermore, we developed an enhanced brown dwarf model that better reflects their properties. We included the variation in space density with Galactic coordinates, while \citet{Mortlock2012} adopted a model corresponding to an average of the brown dwarf population over the range of Galactic latitudes covered by the UKIDSS LAS. Finally, we included the intrinsic colour spread in $\rm{Y-J}$ for L and T dwarfs, whereas \citet{Mortlock2012} attributed only one $\rm{Y-J}$ colour to each spectral type. \\ Our Bayesian probabilistic algorithm is similar to the model developed by \citet{Matsuoka2016} for the SHELLQs project, but has two notable differences. First, \citet{Matsuoka2016} needed to include M dwarfs in their model in addition to L and T dwarfs since they probed a lower redshift range ($5.7 < z < 6.9$). Secondly, they used a unique quasar spectral energy distribution (SED) from the stacking of 340 bright SDSS quasar spectra at $z \sim 3$, while our model uses 80 different spectra created from a principal component analysis of 78 SDSS spectra at $z \sim 3$ (see Sects. \ref{simulqso} and \ref{qsopop}). \subsubsection{Probability of being a high-z quasar: simulations} \begin{figure*}[ht!] \centering \includegraphics[width=0.85\textwidth]{figures/map_simulPq2.png} \caption{Probability $\rm{P_{q}}$ of being a high-redshift quasar for simulated sources with an observed magnitude $\rm{Y_{obs} = 21.5 \pm 0.14}$ (left panel) and $\rm{Y_{obs} = 22.0 \pm 0.22}$ (right panel). This probability reaches from white ($\rm{P_{q}} = 0$) to black ($\rm{P_{q}} = 1$). The coloured points represent brown dwarf colours ranging from blue (L0) to red (T9). The black curve is the mean quasar spectrum derived by \citet{Paris_2011}, for which we included IGM absorption.} \label{Pqsimulmap} \end{figure*} In this section, we explore the dependence of the probability $\rm{P_{q}}$ on photometric measurements. For this purpose, we simulated a set of sources uniformly distributed in the $\rm{z_{obs}-Y_{obs}}$ versus $\rm{Y_{obs}-J_{obs}}$ diagram with CFHQSIR-like z-, Y-, and J-band measurements. Figure \ref{Pqsimulmap} shows the probability $\rm{P_{q}}$ obtained for sources observed with an apparent magnitude $\rm{Y_{obs}} = 21.5 \pm 0.14$ (left panel) and $\rm{Y_{obs}} = 22.0 \pm 0.22$ (right panel). As expected, $\rm{P_{q}}$ increases when the object approaches the characteristic high-z quasar colours. The comparison between the two panels clearly shows that $\rm{P_{q}}$ strongly depends on the observed magnitude $\rm{Y_{obs}}$ , and its high-probability region (in black) is much more prononced for the brightest objects (left panel). This effect is mostly related to the photometric errors: bright objects are measured with a sufficiently high S/N for there to be no ambiguity about their nature. However, faint objects are more likely to be stars measured with high-z quasar colours because of a lower S/N and greater number of stars compared to high-z quasars.\\ This dependency is also demonstrated in Fig. \ref{PqsimulcourbeY}, where the probability $\rm{P_{q}}$ for sources with quasar colours simulated from the mean quasar spectrum discussed in Sect. \ref{simulqso} at four different redshifts is represented as a function of their observed Y-band magnitude. Well-detected sources have a probability $\rm{P_{q}} = 1$, and their nature is unambiguously established. However, for fainter objects, $\rm{P_{q}}$ drops sharply. As mentioned above for the previous figure, the fact that brown dwarfs outnumber the quasars combined with lower S/N implies that these sources are more easily construed as brown dwarfs scattered into the quasar loci. The redshift dependency lies in the slight variation of the $\rm{Y_{mod} - J_{mod}}$ quasar colours. As shown in Fig. \ref{colorsdiag}, the $\rm{Y_{mod} - J_{mod}}$ colour of a $z = 7.2$ quasar is much closer to the brown dwarf locus (with $\rm{Y_{mod} - J_{mod}} \approx 0.3$) than that of a $z = 7.0$ quasar, for which $\rm{Y_{mod} - J_{mod}} \approx 0.1$ because the Ly-$\alpha$ line enters the Y band.\\ In the next section, we present our high-z quasar candidate probabilities and discuss our results. \begin{figure}\centering \includegraphics[width=0.35\textwidth]{figures/courbeY_Pqsimul.png} \caption{Probability $\rm{P_{q}}$ for a source observed with the $\rm{(z_{obs}-Y_{obs})}$ and $\rm{(Y_{obs}-J_{obs})}$ colours of a z = $\left \{6.8, 7.0, 7.2, 7.4\right \}$ quasar as a function of its measured Y-band magnitude $\rm{Y_{obs}}$.} \label{PqsimulcourbeY} \end{figure} \begin{figure}[h!]\centering \includegraphics[width=0.45\textwidth]{figures/histo_cands_Pq.png} \caption{Histogram of the high-z quasar candidate probabilities. Fewer than 20\% of our colour-selected candidates have a probability $\rm{P_{q} > 0.1}$.} \label{Pqhist} \end{figure} \section{Results} \label{secresults} We applied the Bayesian formalism developed in the previous section to our list of 51 high-z quasar candidates. We calculate the $\rm{P_{q}}$ value for each candidate and report the resulting distribution in Fig. \ref{Pqhist}. As expected, the main result is that most of our candidates have a low probability ($\rm{P_{q}} \approx 10^{-2}$). Only 6 of 36 candidates have a chance greater than 10\% ($\rm{P_{q}} > 0.1$) of being high-z quasars. Three of them have a probability $\rm{P_{q}} > 0.6$. This result arises because high-z quasars are outnumbered by low-mass stars and the vast majority of our candidates has a relatively faint Y-band magnitude ($\rm{Y_{obs} \sim 22.4}$ on average). \\ Figure \ref{Pqcands} corresponds to the same colour-colour diagrams as shown in Fig. \ref{diag_cands}, but with the difference that the probabilities $\rm{P_{q}}$ are indicated according to a colour-code from red (low probability) to blue (high probability). Stars refer to candidates observed spectroscopically. In total, 17 candidates have been followed-up in spectroscopy in the W1, W2, and W4 fields using the infrared spectrograph SOFI at NTT (GBF grism blue) and the optical spectrograph FORS2 at the Very Large Telescope (VLT; GRIS\_600z+23 grism). Positions, photometry, probabilities, and spectroscopic informations of these sources are given in Table \ref{table:1}. Of these, 14 with $\rm{P_{q}} \lesssim 0.2$ were consistent with being late brown dwarfs. The remaining 3 candidates observed with FORS2 at the VLT need to have further spectroscopic observations in the infrared because their spectral S/N is too low to confidently confirm their exact nature at this moment. However, as shown in Fig. \ref{Pqcands}, some candidates with a high probability have not yet been observed spectroscopically (one candidate in the W1 field with $\rm{P_{q}} \sim 0.6$ and another in the W4 field with $\rm{P_{q}} \sim 1.0$) because they were judged to be too faint in the z band to be detected in optical spectroscopy with FORS2. \begin{figure*}[ht!] \centering \includegraphics[width=0.85\textwidth]{figures/diagram_Pq_cands.png} \caption{Colour-colour diagram that represents our high-z quasar candidates according to a colour-code from red to blue, corresponding to low and high probability $\rm{P_{q}}$. Stars indicate spectroscopically observed candidates (NTT or VLT).} \label{Pqcands} \end{figure*} \begin{sidewaystable*} \caption{Positions, photometry, and probabilities of being a high-z quasar and spectroscopic informations of the spectroscopically observed quasar candidates} \label{table:1} \centering \begin{tabular}{c c c c c c c} \hline\hline Field, RA and DEC (J2000.0) & Y (mag) & $\rm{z-Y}$ & $\rm{Y-J}$ & $\rm{P_{q}}$ & Telescope/Instrument & Grism\\ \hline W1 02:06:24.64 -07:03:50.73 & $\rm{22.91 \pm 0.56}$ & $\rm{1.87 \pm 0.74}$ & $\rm{-0.16 \pm 0.63}$ & $2.4\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W1 02:07:25.13 -05:29:25.00 & $\rm{22.74 \pm 0.40}$ & $\rm{2.55 \pm 0.75}$ & $\rm{-0.31 \pm 0.50}$ & $2.3\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W1 02:31:08.79 -05:01:12.80 & $\rm{22.15 \pm 0.28}$ & $\rm{2.14 \pm 0.44}$ & $\rm{-0.11 \pm 0.31}$ & $1.2\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23 \\ W1 02:06:50.85 -10:09:33.47 & $\rm{22.12 \pm 0.34}$ & $\rm{3.04 \pm 0.44}$ & $\rm{0.18 \pm 0.46}$ & $3.7\times 10^{-3}$ & VLT/FORS2 & GRIS\_600z + 23 \\ W1 02:34:05.68 -06:21:09.76 & $\rm{22.78 \pm 0.46}$ & $\rm{2.01 \pm 0.50}$ & $\rm{0.36 \pm 0.50}$ & $4.7\times 10^{-3}$ & VLT/FORS2 & GRIS\_600z + 23 \\ W1 02:25:59.13 -10:34:50.71 & $\rm{22.45 \pm 0.32}$ & $\rm{2.64 \pm 0.39}$ & $\rm{-0.49 \pm 0.45}$ & $2.3\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W1 02:09:47.18 -08:23:52.10& $\rm{22.48 \pm 0.34}$ & $\rm{>1.51}$ & $\rm{0.33 \pm 0.47}$ & $2.7\times 10^{-3}$ & NTT/SOFI & GB Grism Blue\\ W1 02:26:56.80 -04:24:06.88 & $\rm{22.20 \pm 0.24}$ & $\rm{2.29 \pm 0.34}$ & $\rm{<-0.40}$ & $7.1\times 10^{-1}$ & VLT/FORS2 & GRIS\_600z + 23\\ W1 02:07:57.65 -08:04:26.00 & $\rm{22.67 \pm 0.38}$ & $\rm{2.08 \pm 0.60}$ & $\rm{<0.13}$ & $5.6\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W1 02:17:29.38 -05:01:31.49 & $\rm{22.81 \pm 0.41}$ & $\rm{>1.15}$ & $\rm{-0.01 \pm 0.66}$ & $1.9\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W2 09:04:32.26 -05:31:56.26 & $\rm{22.38 \pm 0.27}$ & $\rm{1.64 \pm 0.35}$ & $\rm{-0.45 \pm 0.39}$ & $3.0\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W2 09:04:53.35 -03:15:22.06 & $\rm{22.77 \pm 0.36}$ & $\rm{2.16 \pm 0.49}$ & $\rm{-0.11 \pm 0.45}$ & $2.1\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W2 09:04:22.51 -04:34:09.71 & $\rm{21.84 \pm 0.19}$ & $\rm{>2.52}$ & $\rm{0.32 \pm 0.23}$ & $8.4\times 10^{-3}$ & NTT/SOFI & GB Grism Blue\\ W4 22:17:59.64 00:55:02.12 & $\rm{22.85 \pm 0.46}$ & $\rm{1.79 \pm 0.62}$ & $\rm{-0.02 \pm 0.49}$ & $3.9\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W4 22:02:41.32 01:34:31.95 & $\rm{22.44 \pm 0.25}$ & $\rm{1.55 \pm 0.34}$ & $\rm{-0.26 \pm 0.33}$ & $3.2\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W4 22:04:12.48 02:01:23.22& $\rm{22.61 \pm 0.39}$ & $\rm{2.59 \pm 0.59}$ & $\rm{-0.35 \pm 0.43}$ & $2.7\times 10^{-2}$ & VLT/FORS2 & GRIS\_600z + 23\\ W4 22:10:33.26 +02:20:24.89& $\rm{22.38 \pm 0.27}$ & $\rm{>1.43}$ & $\rm{<-0.54}$ & $8.6\times 10^{-2}$ & NTT/SOFI & GB Grism Blue\\ \hline \end{tabular} \tablefoot{No quasar was confirmed after these spectroscopic observations. The detailed analysis of the spectroscopic results will be reported in a future paper.} \end{sidewaystable*} \section{Discussion and conclusions} \label{sec5} We have presented a complete method for selecting and classifying $z \sim 7$ quasar candidates using optical and NIR photometric data as part of the CFHQSIR survey. After visual inspection and removal of artefacts, we selected 228 candidates with red $\rm{z-Y}$ colours. The sample was eventually culled to 36 sources by considering candidates with $\rm{Y-J}$ colours consistent with being high-z quasars after NIR follow-up in J band. We extended and refined the Bayesian formalism developed by \citet{Mortlock2012} in order to improve our selection of high-z quasar candidates. This robust statistical approach allowed us to classify our candidates in the best possible way according to their probability of being a high-redshift quasar. Applying a Bayesian method is indeed very efficient to identify the most promising candidates in any photometrically selected sample since it allows combining the prior knowledge of the brown dwarf and quasar populations and the filter and noise properties of the observational data. Moreover, we demonstrated the importance of acquiring sufficiently precise photometric measurements to clearly determine the nature of the objects. \\ The application of the Bayesian formalism revealed a promising list of six candidates with a probability $\rm{P_{q}} > 0.1$. Only three of these have a chance higher than 60\% of being a high-z quasar. Even though one of them has been observed spectroscopically with the FORS2 instrument, we were unable to draw any conclusions about its nature because its spectral S/N is low. Our immediate goal is to complete the spectroscopic follow-up of our most promising candidates, according to their probability of being a high-z quasar. The full analysis of our search for $z \sim 7$ quasars will be reported in a future paper, including the analysis of our spectroscopic data. A non-detection indicates that the quasar density at $z \sim 7$ is at a 90\% and 75\% confidence level lower than the density inferred from the QLF of \citet{Willott2010} and \citet{Jiang2016}, respectively. Conversely, the discovery of one high-redshift quasar in CFHQSIR would be 23\% and 35\% consistent with the QLF of \citet{Willott2010} and \citet{Jiang2016}, respectively. \\ Our Bayesian method can be consolidated in several aspects, however. Early-type galaxies at $z \sim 2$ may appear compact at faint magnitudes and therefore represent a second source of contamination that would also need to be modelled precisely, in addition to the low-mass stars. \\ Furthermore, the brown dwarf population could be modelled more accurately by considering the stars from the Galactic thick disc and the halo, in addition to the thin disc. There is also further room for improvement concerning the local spatial density of brown dwarfs. Using observed spatial density measurements instead of model-predicted ones would be interesting \citep[see e.g.][]{Reyle2010, Kirkpatrick2011}. As the number of known ultracool dwarfs continues to rise, more precise estimates of their spatial densities will be essential ingredients of an improved Bayesian model. Our results may also be biased as they are based on a heterogeneous collection of L- and T-dwarf spectra coming from various surveys, provided by the SpeX Prism library. In particular, our fundamental assumption that the measured colours of these sources are representative of the colours of the L and T populations may no longer be valid when considering unresolved binaries and peculiar sources. The unusual colours of these rare sources, as well as the uncertainty in their spectral classification, can introduce an intrinsic scatter in the colours that is not taken into account in our model. Unresolved binaries can be an important source of uncertainty, as they could represent $\sim$ 40\% of the dwarf population \citep{Liu2006, Burgasser2007}. To finish, the newly discovered spectral type, the ultracool Y-dwarf class \citep[e.g. ][]{Cushing2011}, should also be included in our model, although these sources are likely to be too faint at our limiting magnitude to represent a real source of contamination.\\ Nevertheless, the Bayesian technique presented in this paper remains a powerful approach to efficiently prioritize high-z quasar candidates, and it is moreover easily adaptable to any other high-z object surveys, whether they are dedicated to the search for quasars or not (e.g. high-z galaxies in deep fields). This technique will be critical to the discovery of many more distant quasars by future NIR surveys such as the Euclid-wide imaging survey \citep{Laureijs2011} or the WFIRST High Latitude Survey \citep[HLS, ][]{Spergel2013}. Thanks to the high sensitivity of these upcoming surveys, high-z quasars will be identified in an unprecedented number. Scheduled to be launched in 2021 and in the mid-2020s, respectively the Euclid space mission is expected to discover $\sim$ 30 quasars at redshifts $z > 8.1$ with $J < 22.0$ over 18 000 $\rm{deg^{2}}$ , and WFIRST will find $\sim$ 500 $z \gtrsim 8$ quasars over 2\,000 $\rm{deg^{2}}$ above 10$\,\sigma$ \citep[mag $\approx$ 26 limit, ][]{Spergel2013}. \\ A great challenge for these high-depth surveys will be the increasing number of contamination sources. In addition to the L and T dwarfs, a significant number of Y dwarfs will be detected, and possibly free-floating planets as well \citep[see e.g.][for free-floating planets detected by microlensing]{Han2004}. The increased number of contamination populations will require careful modeling in Bayesian frameworks such as the one presented in this work. This will be an essential requirement for culling the number of high-z candidates from these surveys before spectroscopic observations with the Extremely Large Telescope (ELTs\footnote{\url{https://www.eso.org/sci/facilities/eelt/docs/E-ELTScienceCase_Lowres.pdf}}) or the James Webb Space Telescope \citep[JWST, ][]{Gardner2006} can be attempted. \begin{acknowledgements} We thank the anonymous referee for valuable comments and suggestions. Based on observations obtained with MegaPrime/MegaCam, a joint project of CFHT and CEA/IRFU, at the Canada-France-Hawaii Telescope (CFHT), which is operated by the National Research Council (NRC) of Canada, the Institut National des Science de l'Univers of the Centre National de la Recherche Scientifique (CNRS) of France, and the University of Hawaii. This work is based in part on data products produced at Terapix available at the Canadian Astronomy Data Centre as part of the Canada-France-Hawaii Telescope Legacy Survey, a collaborative project of NRC and CNRS. Based on observations made with ESO Telescopes at La Silla Paranal Observatory under programmes ID 095.A-0349, 097.A-0650, 098.A-0524, 099.A-0358 and 0100.A-0061. The WHT is operated on the island of La Palma by the Isaac Newton Group of Telescopes in the Spanish Observatorio del Roque de los Muchachos of the Instituto de Astrofísica de Canarias. The LIRIS photometry was obtained as part of OPT/2015B/26 and OPT/20184/007. This research has benefitted from the SpeX Prism Library and SpeX Prism Library Analysis Toolkit, maintained by Adam Burgasser at \url{http://www.browndwarfs.org/spexprism}. This research makes use of the VIPERS-MLS database, operated at CeSAM/LAM, Marseille, France. This work is based in part on observations obtained with WIRCam, a joint project of CFHT, Taiwan, Korea, Canada and France. The CFHT is operated by the National Research Council (NRC) of Canada, the Institut National des Science de l’Univers of the Centre National de la Recherche Scientifique (CNRS) of France, and the University of Hawaii. This work is based in part on observations made with the Galaxy Evolution Explorer (GALEX). GALEX is a NASA Small Explorer, whose mission was developed in cooperation with the Centre National d’Etudes Spatiales (CNES) of France and the Korean Ministry of Science and Technology. GALEX is operated for NASA by the California Institute of Technology under NASA contract NAS5-98034. This work is based in part on data products produced at TERAPIX available at the Canadian Astronomy Data Centre as part of the Canada-France-Hawaii Telescope Legacy Survey, a collaborative project of NRC and CNRS. The TERAPIX team has performed the reduction of all the WIRCAM images and the preparation of the catalogues matched with the T0007 CFHTLS data release. Based on observations obtained as part of the VISTA Hemisphere Survey, ESO Progam, 179.A-2010 (PI: McMahon). \end{acknowledgements} \bibliographystyle{aa}
\section{Introduction} Optical solitons attracted much attention due to their potential applications in optoelectronics and information technologies. The idea of using optical solitons as carriers of information in high-speed communication systems was first proposed in the pioneering paper by Hasegawa and Tappert \ci{Hasegawa}. Later due to the advances made in fiber technology it became possible to realize optical solitons experimentally in different versions (bright, dark, etc) \ci{Fiber1}-\ci{Kivsharbook}. This fact caused great interest to finding the soliton solutions of governing nonlinear wave equations, such as nonlinear Sch\"odinger equations with different nonlinearities. An important problem in the context of optical solitons is the problem of soliton generation in optical media. Mathematically, such problem is reduced to the initial value (Cauchy) problem for nonlinear Sch\"odinger equation, which allows to find soliton solution and number of generated solitons using given initial condition. For optical fibers such problem was studied in the Refs.\ci{Burzlaff}-\ci{Zhong1}. In \ci{Burzlaff} an effective method for finding number of solitons generated in optical fibers was proposed. Later, it was extended for some other initial conditions \ci{Kivshar}. Strict mathematical treatment of soliton generation on a half line as initial-boundary-value problem was considered presented \ci{Fokas}. Soliton generation in optical fibers for a dual-frequency input was studied in \ci{Panoiu}. In \ci{Skryabin} a theory of the generation of new spectral components in optical fibers pumped with a solitonic pulse and a weak continuous wave was proposed and the wave number matching conditions for this process was derived. In \ci{Nishizawa} characteristics of wavelength-tunable femtosecond soliton pulse generation using optical fibers in a negative dispersion region are studied experimentally and theoretically using the extended nonlinear Schr\"odinger equation, in which the wavelength dependence of parameters is considered. A comprehensive analysis of the generation of optical solitons in a monomode optical fibre from a superposition of soliton-like optical pulses at different frequencies in \ci{Panoiu1}, where it is found that there exists a critical frequency separation above which wavelength-division multiplexing with solitons is feasible. Soliton generation and their instability are investigated in a system of two parallel-coupled fibers, with a pumped (active) nonlinear dispersive core and a lossy (passive) linear one in \ci{Malomed1}. A theory of the generation of new spectral components in optical fibers pumped with a solitonic pulse have been studied. Bright-gap-soliton generation in finite optical lattices was discussed in \ci{Carusotto}. Despite the fact that certain progress is made on theoretical and experimental study of soliton generation in optical fibers, all the studies are restricted by considering long, unbranched fibers. However, branched fibers are more attractive from the viewpoint of practical applications, as in may cases information-communication systems use optical fiber networks. Modeling of soliton generation and dynamics in optical fiber networks requires solving of nonlinear Sch\"odinger equation on metric graphs.\\ We note that soliton dynamics described by integrable nonlinear wave equations attracted much attention during past decade \ci{Zarif} -\ci{Karim2018}. In \ci{Zarif} nonlinear Sch\"odinger equation on metric graphs is studied and condition for integrability is derived in the form of a sum rule for nonlinearity coefficients. In \ci{zar2011} such study is extended to Ablowitz-Laddik equation. Stationary Sch\"odinger equation on metric graphs and standing wave soliton in networks are studied in \ci{Adami,noja,Karim2013,Adami16,Adami17}. Integrable sine-Gordon equation on metric graphs is studied in \ci{caputo14,Our1,Karim2018}. Linear and nonlinear systems of PDE on metric graphs are considered in \ci{Bolte,KarimBdG,KarimNLDE}. In this paper we consider the problem of soliton generation in branched optical fibers, or, optical fiber networks described in terms of the initial value problem for nonlinear Sch\"odinger equation on metric graphs. For different given initial conditions, we derive number of solitons generated by considering different network topologies. Unlike linear optical fibers, pulse generation and soliton dynamics in fiber networks strongly depend on the topology of latter. Propagating in such network optical soliton undergo to scattering and transmission through the network branching points that may cause additional effects such as interaction of incoming and scattered solitons, radiation, collisions, etc. Therefore effective transmission of information through the optical fiber networks requires proper tuning both the system architecture and initial pulse profiles. Depending on which branch, or vertex the initial pulse located, the number of solitons and their dynamics can be different. This fact provides powerful tool for tuning of the optical fiber network architecture and optimization of signal and information transmission. This paper is organized as follows. In the next section we briefly recall treatment of the problem of soliton generation for linear (unbrached) optical fibers. In section III we give formulation of the problem and its solution for star branched (Y-junction) optical fibers. Section IV extends the study for other network topologies, modeled by loop and tree graphs. Section V presents some concluding remarks. \begin{figure}[h] \centering \includegraphics[width=80mm]{star.eps} \caption{Basic star graph} \label{f2} \end{figure} \section{Soliton generation in linear optical fibers} Let us first, following the Refs.\ci{Burzlaff,Kivshar}, recall solution of the problem for linear, i.e. unbranched optical fibers. The governing equation for the pulse generation and evolution in optical fibers is the following nonlinear Sch\"odinger equation \begin{equation}}\newcommand{\ee}{\end{equation} i\frac{\partial \psi}{\partial t}+\frac{1}{2}\frac{\partial^2 \psi}{\partial x^2}+|\psi|^2\psi=0,\lab{nls01} \ee where $\psi$ is the normalized complex amplitude of the pulse envelope. The problem of soliton generation in optical fibers is reduced to the Cauchy problem for Eq.\re{nls01}. Such problem can be solved, e.g., using inverse scattering method \ci{Burzlaff,Kivshar,Panoiu}. In \ci{Burzlaff} it was solved for the initial conditions given by $\psi(x,0)=-iq(x)$, with \begin{eqnarray} q(x)= \begin{cases} 0, & \text{for}\;\;\; |x|>\frac{1}{2}a \\ b, & \text{for}\;\;\; |x|\leq\frac{1}{2}a \end{cases}\quad\quad\quad b>0. \end{eqnarray} The evolution of the wave function upon generation of the soliton can be obtained via solving the following eigenvalue problem \begin{equation}}\newcommand{\ee}{\end{equation} Au =\lambda u, \ee where \begin{equation}}\newcommand{\ee}{\end{equation} A = \left(\begin{array}{cc}i\frac{d}{dx}&\psi(x,0)\\-\psi^*(x,0)&-i\frac{d}{dx}\end{array}\right).\lab{current}\ee \begin{figure}[th!] \includegraphics[width=80mm]{psg.eps} \caption{Initial pulse profile in the star branched optical fiber.} \label{psg} \end{figure} Each discrete eigenvalue $\lambda = \xi + i\eta $ with $L^2-$ integrable eigenfunction corresponds to the generated soliton with the amplitude $2\eta$ moving with the velocity $2\xi$. It was shown in \ci{Burzlaff} that number of generated solitons is given by expression \begin{equation}}\newcommand{\ee}{\end{equation} N = <\frac{1}{2} +\frac{F}{\pi}> = <\frac{1}{2} +\frac{ab}{\pi}>,\lab{number}\ee where $F =\int_{-\infty}^{\infty}|\psi(x,0)|dx$ and $<...>$ denotes the integer smaller than the argument. Similar result for the number of solitons was obtained in the Ref.\ci{Burzlaff} for the initial condition given by $$ q(x) =\beta \text{exp}(-\alpha |x|), \;\; \alpha, \beta > 0. $$ Later, Kivshar considered the problem of soliton generation for super Gaussian initial pulse and showed that Eq.\re{number} is general formula for arbitrary initial profile \ci{Kivshar}. More detailed treatment of the problem of soliton generation in optical fibers was presented in \ci{Panoiu}. In particular, the authors of \ci{Panoiu} analyzed scenarios for soliton generation in an ideal fiber for an input that consists of either two in-phase or out-of-phase solitonlike optical pulses at different frequencies by considering symmetric initial input pulse given by $$ \psi(x,0) = \text{sech}(x)[e^{i\omega x} + e^{-i\omega x}], $$ and asymmetric pulse given by $$ \psi(x,0) = i\text{sech}(x)[e^{i\omega x} - e^{-i\omega x}] $$ with the soliton solutions, respectively given as \begin{widetext} $$ \psi(x,t)=\xi\eta e^{\phi(\frac{t}{2})}\frac{e^{i\xi x}\cosh\left[\eta(x+\xi t)+i\varphi\right]+e^{-i\xi x}\cosh\left[\eta(x-\xi t)-i\varphi\right]}{\xi^2\cosh\eta(x+\xi t)\cosh\eta(x-\xi t)+\eta^2\sin\xi(x+i\eta t)\sin\xi(x-i\eta t)}, $$ and \begin{equation} \psi(x,t)=-i\xi\eta e^{\phi(\frac{t}{2})}\frac{e^{i\xi x}\cosh\left[\eta(x+\xi t)+i\varphi\right]-e^{-i\xi x}\cosh\left[\eta(x-\xi t)-i\varphi\right]}{\xi^2\cosh\eta(x+\xi t)\cosh\eta(x-\xi t)+\eta^2\cos\xi(x+i\eta t)\cos\xi(x-i\eta t)},\label{linesol2} \end{equation} \end{widetext} where $\phi(t)=-i(\xi^2-\eta^2)t+\alpha,\,\alpha=\ln|\lambda_0|,\,\tan\varphi=\frac{\eta}{\xi}$. In the next section we extend these studies to the case of branched optical fibers, i.e. fiber networks. \begin{figure}[h] \centering \includegraphics[width=80mm]{hgraph.eps} \caption{Sketch for the H-graph} \label{f3} \end{figure} \section{Description of the model for Star shaped network} Soliton dynamics in networks has attracted much attention during past decade. Convenient approach to describe such system is modeling in terms of nonlinear wave equation on a metric graph. The early treatment of the nonlinear Schrodinger equation on metric graphs dates back to the Ref.~\cite{Zarif}, where soliton solutions of the NLSE on metric graphs was obtained and integrability of the problem under certain constraints was shown by proving the existence of an infinite number of conserving quantities. Here we briefly recall the problem of NLSE in metric star graph following the Ref.~\cite{Zarif}. Consider the star graph with three bonds $e_j$ (see, Fig. 1), for which a coordinate $x_j$ is assigned. Choosing the origin of coordinates at the vertex, 0 for bond $e_1$ we put $x_1\in (-\infty,0]$ and for $e_{2,3}$ we fix $x_{2,3}\in [0,+\infty)$. In what follows, we use the shorthand notation $\Psi_j(x)$ for $\Psi_j(x_j)$ where $x$ is the coordinate on the bond $j$ to which the component $\Psi_j$ refers. The nonlinear Schr\"odinger equation on each bond $e_j$ of such graph can be written as \ci{Zarif}\begin{equation}}\newcommand{\ee}{\end{equation} i\frac{\partial \psi_j}{\partial t}+\frac{\partial^2 \psi_j}{\partial x^2}+\beta_j|\psi_j|^2\psi_j=0.\lab{nls02} \ee To solve Eq. \eqref{nls02} one needs to impose the boundary conditions at the branching point. This can be derived from the fundamental physical laws, such as norm and energy conservation, which are given as \ci{Zarif}\begin{equation}}\newcommand{\ee}{\end{equation} \frac{dN}{dt} = 0, \quad\frac{dE}{dt} =0, \label{conserv} \ee where \begin{equation*} N(t) =\int\limits_{-\infty}^{0}|\psi_1|^2\,dx +\int\limits_{0}^{\infty}|\psi_2|^2\,dx +\int\limits_{0}^{\infty}|\psi_3|^2\,dx \end{equation*} and \begin{equation*} E =E_1+E_2+E_3, \end{equation*} with \begin{equation*} E_k =\int\limits_{e_k}\biggl[\left|\frac{\partial\psi_k}{\partial x}\right|^2 -\frac{\beta_k}{2}|\psi_k|^4\biggr]\,dx. \end{equation*} As it was shown in the Ref. \ci{Zarif}, the conservation laws Eq.~\eqref{conserv} lead to the following vertex conditions \begin{equation}}\newcommand{\ee}{\end{equation} \sqrt{\beta_1} \psi_1(0,t)=\sqrt{\beta_2} \psi_2(0,t)=\sqrt{\beta_3} \psi_3(0,t), \label{vbc1} \ee and generalized Kirchhoff rules \begin{equation}}\newcommand{\ee}{\end{equation} \frac{1}{\sqrt{\beta_1}} \frac{d\psi_1}{dx}|_{x=0} = \frac{1}{\sqrt{\beta_2}} \frac{d\psi_2}{dx}|_{x=0} + \frac{1}{\sqrt{\beta_3}} \frac{d\psi_3}{dx}|_{x=0}, \label{vbc2} \ee where $\beta_j$ are nonzero real constants. The asymptotic conditions for Eq.~\eqref{nls01} are imposed as \begin{equation}}\newcommand{\ee}{\end{equation} \lim_{|x|\to +\infty} \psi_j=0. \label{asymp} \ee The single soliton solutions of Eq.~\eqref{nls01} fulfilling the vertex boundary conditions \eqref{vbc1}, \eqref{vbc2} and the asymptotic condition, \eqref{asymp} can be written as \cite{Zarif} \begin{equation}}\newcommand{\ee}{\end{equation} \psi_j(x,t) = a\,\sqrt{\frac{2}{\beta_j}}\,\frac{\exp\bigl[i\frac{vx}{2}- i(\frac{v^2}{4}-a^2)t\bigr]}{\cosh[a(x-l -vt)]}, \ee where the parameters $\beta_j$ fulfill the sum rule \ci{Zarif}\begin{equation}}\newcommand{\ee}{\end{equation} \frac{1}{\beta_1}= \frac{1}{\beta_2}+\frac{1}{\beta_3}.\label{sumrule} \ee Here $v$, $l$ and $a$ are bond-independent parameters characterizing velocity, initial center of mass and amplitude of a soliton, respectively. Consider branched optical fiber having the form of the Y-junction. Such system can be considered as basic star graph presented in Fig. 1. Then the problem of generation of soliton and its propagation can be modeled in terms of the Cauchy problem for nonlinear Sch\"odinger equation on a basic star graph, which is given by Eq.\re{nls02} for which the following initial condition is imposed: $$ \psi_j(x,0) = -i\sqrt{\frac{2}{\beta_j}}q_j(x,). $$ Here $\psi_j$ is the normalized complex amplitude of the pulse envelope on $j$th bond (branch) of the graph and $q_j(x)$ is the initial profile of the amplitude. To solve this equation, one needs to impose the boundary conditions at the branching point (vertex) of the graph and determine the asymptotic of the wave function at the branch ends. These can be written in the form of Eqs. \re{vbc1}, \re{vbc2} and \re{asymp}. \begin{figure}[h] \centering \includegraphics[width=80mm]{hg.eps} \caption{Initial pulse profile on the optical fiber H-shaped network} \label{f3} \end{figure} Here we consider the problem of soliton generation for Y-junction of the optical fiber for the initial pulse profile given as (see, Fig. \ref{f2}) \begin{equation}}\newcommand{\ee}{\end{equation} q_1(x)=\begin{cases}0, & x<-\frac{1}{2}a \\ b, & -\frac{1}{2}a\leq x\leq 0 \end{cases} \lab{profile00}\ee \begin{equation}}\newcommand{\ee}{\end{equation} q_{2,3}=\begin{cases}0, & x>\frac{1}{2}a \\ b, & 0\leq x\leq \frac{1}{2}a \end{cases} \lab{profile01} \ee Such initial profile implies that soliton is generated around the branching point on each branch. Using the same method as that for linear optical fiber, we can compute the number of generated solitons, $N$ for such profile: \begin{eqnarray} N=\left<\frac{1}{2}+\frac{F}{\pi}\right>, \lab{number1} \end{eqnarray} where \begin{eqnarray} F=\sum_{j=1}^3\int_{e_j}|\psi_j(x,0)|dx=\frac{ab}{2}\left[ \sqrt{\frac{2}{\beta_1}}+\sqrt{\frac{2}{\beta_2}}+\sqrt{\frac{2}{\beta_3}} \right]. \lab{number2} \end{eqnarray} We assume that the sum rule is \re{sumrule} is fulfilled, i.e. the problem is integrable. Difference between Eqs.\re{number} and \re{number1} comes from the constant factor $$(\sqrt{2\beta_1^{-1}}+\sqrt{2\beta_2^{-1}}+ \sqrt{2\beta_3^{-1}}).$$ This allows tuning the soliton number and dynamics using different choices of the set $\beta_j,\;(j=1,2,3).$ In addition, for simplicity, the above initial pulse profiles in Eqs.\re{profile00} and \re{profile01} are given at the vertex and have the same widths, $a$ and heights, $b$. However, in general case one can choose different widths and heights for different bonds. This also provides additional tool for tuning of the soliton number and dynamics. Another initial pulse profile, for which the soliton number and solutions in a Y-junction fiber can be explicitly obtained is given by \begin{equation} \psi_j(x,0)=\sqrt{\frac{2}{\beta_j}}\text{sech}(x)\left[e^{i\left(\omega x+\frac{\theta}{2}\right)}+e^{-i\left(\omega x+\frac{\theta}{2}\right)}\right],\label{incond1} \end{equation} where $2\omega$ and $\theta$ are the frequency detuning and the phase difference between the two solitons, correspondingly. The two-soliton solution of the problem given by Eqs. \re{nls02}, \re{vbc1} and \re{vbc2}can be written as \begin{widetext} \begin{equation} \psi_j(x,t)=\sqrt{\frac{2}{\beta_j}} \xi\eta e^{\phi(\frac{t}{2})}\frac{e^{i\xi x}\cosh\left[\eta(x+\xi t)+i\varphi\right]+e^{-i\xi x}\cosh\left[\eta(x-\xi t)-i\varphi\right]}{\xi^2\cosh\eta(x+\xi t)\cosh\eta(x-\xi t)+\eta^2\sin\xi(x+i\eta t)\sin\xi(x-i\eta t)},\label{starsol1} \end{equation} \end{widetext} which is valid under the constraint: \begin{equation} \frac{1}{\beta_1}=\frac{1}{\beta_2}+\frac{1}{\beta_3},\label{const1} \end{equation} Corresponding soliton number is given by Eq.\re{number1}, where the quantity $F$ can be written as $$ F=2\pi\left(\sqrt{\frac{2}{\beta_1}}+\sqrt{\frac{2}{\beta_2}}+\sqrt{\frac{2}{\beta_3}}\right)\text{sech}\left(\frac{\pi\omega}{2}\right)\cos\left(\frac{\theta}{2}\right) $$ \begin{figure}[h] \centering \includegraphics[width=80mm]{tree.eps} \caption{Sketch for tree graph} \label{f4} \end{figure} \section{Other network topologies} The above treatment of the problem for soliton generation in optical fiber networks can be extended to the case of more complicated topologies. Here we demonstrate this for so-called $H-$graph and tree graph. For H-graph, presented in Fig.3 the coordinates are defines as $x_{1,2}\in(-\infty;0],\,x_3\in[0;L],\,x_{4,5}\in[0;+\infty),$ where $L$ is the length of bond $e_3$, i.e. the distance between two vertices. For NLS equation \re{nls02} and the vertex boundary conditions given by \begin{eqnarray} \sqrt{\beta_1} \psi_1(0,t)=\sqrt{\beta_2} \psi_2(0,t)=\sqrt{\beta_3} \psi_3(0,t),\nonumber\\ \sqrt{\beta_3} \psi_3(L,t)=\sqrt{\beta_4} \psi_4(0,t)=\sqrt{\beta_5} \psi_5(0,t), \lab{vbc3} \end{eqnarray} \begin{eqnarray} \frac{1}{\sqrt{\beta_1}} \frac{d\psi_1}{dx}|_{x=0} + \frac{1}{\sqrt{\beta_2}} \frac{d\psi_2}{dx}|_{x=0} = \frac{1}{\sqrt{\beta_3}} \frac{d\psi_3}{dx}|_{x=0},\nonumber\\ \frac{1}{\sqrt{\beta_3}} \frac{d\psi_3}{dx}|_{x=L} = \frac{1}{\sqrt{\beta_4}} \frac{d\psi_4}{dx}|_{x=0} + \frac{1}{\sqrt{\beta_5}} \frac{d\psi_5}{dx}|_{x=0}.\lab{vbc4} \end{eqnarray} We consider the following initial conditions: $$\psi_j(x,0)=-i\sqrt{\frac{2}{\beta_j}}q_j(x)$$ where the initial pulse profiles are given by (see, Fig.4) \begin{eqnarray} q_{1,2}(x)= \begin{cases} 0, & -\infty< x<-\frac{1}{2}a \\ b_1, & -\frac{1}{2}a\leq x\leq 0 \end{cases} \end{eqnarray} \begin{eqnarray} q_3(x)= \begin{cases} b_1, & 0\leq x \leq \frac{1}{2}a \\ 0, & \frac{1}{2}a<x<L-\frac{1}{2}a\\ b_2, & L-\frac{1}{2}a \leq x \leq L \end{cases} \end{eqnarray} \begin{eqnarray} q_{4,5}(x)= \begin{cases} b_2, & 0\leq x \leq \frac{1}{2}a \\ 0, & \frac{1}{2}a<x<\infty \end{cases} \end{eqnarray} \begin{figure}[h] \centering \includegraphics[width=70mm]{treegraph.eps} \caption{Initial pulse profile on the tree-shaped optical fiber network} \label{f4} \end{figure} Then the number of generated optical solitons in such system we have explicit expression: \begin{eqnarray} N=\left< \frac{1}{2}+\frac{F_1+F_2}{\pi} \right>, \end{eqnarray} where \begin{eqnarray} F_1=\frac{ab_1}{2}\left[ \sqrt{\frac{2}{\beta_1}}+\sqrt{\frac{2}{\beta_2}}+\sqrt{\frac{2}{\beta_3}} \right], \end{eqnarray} and \begin{eqnarray} F_2=\frac{ab_2}{2}\left[ \sqrt{\frac{2}{\beta_3}}+\sqrt{\frac{2}{\beta_4}}+\sqrt{\frac{2}{\beta_5}} \right]. \end{eqnarray} Similarly, one can find number of generated solitons for the tree graph, presented in Fig. \ref{f4}. The vertex boundary conditions for such graph are given by \begin{eqnarray} \sqrt{\beta_1} \psi_1(0,t)=\sqrt{\beta_2} \psi_2(0,t)=\sqrt{\beta_3} \psi_3(0,t),\nonumber\\ \sqrt{\beta_{1i}} \psi_{1i}(L_{1i},t)=\sqrt{\beta_{1ij}} \psi_{1ij}(0,t),\,i,j=1,2, \lab{vbc3} \end{eqnarray} and \begin{eqnarray} \frac{1}{\sqrt{\beta_1}} \frac{d\psi_1}{dx}|_{x=0} = \frac{1}{\sqrt{\beta_2}} \frac{d\psi_2}{dx}|_{x=0} + \frac{1}{\sqrt{\beta_3}} \frac{d\psi_3}{dx}|_{x=0},\nonumber\\ \frac{1}{\sqrt{\beta_{1i}}} \frac{d\psi_{1i}}{dx}|_{x=L_{1i}} = \frac{1}{\sqrt{\beta_{1i1}}} \frac{d\psi_{1i1}}{dx}|_{x=0} + \frac{1}{\sqrt{\beta_{1i2}}} \frac{d\psi_{1i2}}{dx}|_{x=0},\,i=1,2.\lab{vbc4} \end{eqnarray} Furthermore, we choose the initial pulse profile at each vertex ($\psi_e(x,0)=-i\sqrt{\frac{2}{\beta_e}}q_e(x)$) in the forms \begin{eqnarray} q_1(x)= \begin{cases} 0, & -\infty< x<-\frac{1}{2}a \\ b_1, & -\frac{1}{2}a\leq x\leq 0 \end{cases} \end{eqnarray} \begin{eqnarray} q_{11}(x)= \begin{cases} b_1, & 0\leq x \leq \frac{1}{2}a \\ 0, & \frac{1}{2}a<x<L_{11}-\frac{1}{2}a\\ b_2, & L_{11}-\frac{1}{2}a \leq x \leq L_{11} \end{cases} \end{eqnarray} \begin{eqnarray} q_{12}(x)= \begin{cases} b_1, & 0\leq x \leq \frac{1}{2}a \\ 0, & \frac{1}{2}a<x<L_{12}-\frac{1}{2}a\\ b_3, & L_{12}-\frac{1}{2}a \leq x \leq L_{12} \end{cases} \end{eqnarray} \begin{eqnarray} q_{1ij}(x)= \begin{cases} b_{i+1}, & 0\leq x \leq \frac{1}{2}a \\ 0, & \frac{1}{2}a<x<\infty \end{cases} \end{eqnarray} where $i,j=1,2$, $L_{11}$ and $L_{12}$ are lengths of bonds $e_{11}$ and $e_{12}$ respectively. Then for the generated soliton number we have \begin{eqnarray} N=\left<\frac{1}{2}+\frac{F_1+F_2+F_3}{\pi}\right>, \lab{number03} \end{eqnarray} where \begin{eqnarray} F_1=\frac{ab_1}{2}\left[ \sqrt{\frac{2}{\beta_1}}+\sqrt{\frac{2}{\beta_{11}}}+\sqrt{\frac{2}{\beta_{12}}} \right] \end{eqnarray} \begin{eqnarray} F_2=\frac{ab_2}{2}\left[ \sqrt{\frac{2}{\beta_{11}}}+\sqrt{\frac{2}{\beta_{111}}}+\sqrt{\frac{2}{\beta_{112}}} \right] \end{eqnarray} \begin{eqnarray} F_3=\frac{ab_3}{2}\left[ \sqrt{\frac{2}{\beta_{12}}}+\sqrt{\frac{2}{\beta_{121}}}+\sqrt{\frac{2}{\beta_{122}}} \right] \end{eqnarray} The number of parameters in Eq.\re{number03} is much higher that in the case of star graph. This implies that tree-shaped optical fiber network provides more wider possibility for tuning the generated soliton number and their dynamics. \section{Conclusions} In this paper we studied the problem of soliton generation in optical fiber networks using a model based NLS equation on metric graphs. Initial value (Cauchy) problem for NLS equation on metric graphs is solved for different graph topologies, such as star, tree and H-graphs. For branched optical fibers one can choose the initial pulse profile in different ways (e.g., at the vertex or branch, at given vertex or branch, with different shapes at different vertices). Therefore, unlike to linear (unbranched) fibers, soliton generation for optical fiber networks have richer dynamics and tools for manipulation by solitons numbers. The above method can be applied for different network topologies, provided a network has three and more semi-infinite outgoing branches. This allows to use our model for the problem of tunable soliton generation in optical fiber networks, which is of importance for practical applications in the areas, where optical fibers are used for information (signal) transfer. \section{Acknowledgements} This work is supported by the grant of the Ministry for Innovation Development of Uzbekistan (Ref. No. BF2-022).
\section*{Acknowledgments} The authors have been supported by Academy of Finland grant 298020. \section{Empirical analysis}\label{sec:analysis} \subsection{Variation among developers} \begin{figure}[!htp] \centering \includegraphics[width=0.75\columnwidth]{figures/authors-ncomments-comment-ratio} \caption{Number of comments and ratio of comments with at least one emoticon for each developer.} \label{fig:authors-ncomments-comment-ratio} \end{figure} As seen in \fig{fig:authors-ncomments-comment-ratio}, there are some important differences in the frequency of emoticon usage between both Apache and Mozilla developers. However, we find that there are also Apache developers who have used emoticons in more than 10\% of their comments. Mozilla developers are usually more active on their issue tracker than Apache developers. The difference can be explained by the fact that Mozilla forces developers to use the issue tracker for code review. On the other hand, Apache gives more freedom to individual projects to handle modifications and code review. For the remaining of this section, we only keep the developers having written at least 100 comments. This leaves 727 Apache developers (76\%) and 462 (98\%) Mozilla developers, having written respectively 99.3\% and 99.9\% of all the comments. Even after filtering out the developers with less than 100 comments, there is still a statistically significant (p-value $<$ 0.001) difference between Apache and Mozilla developers with a medium effect size (Cliff's $\delta = 0.39$). After filtering out the developers who haven't used any emoticon, Mozilla developers still use emoticons significantly more often than Apache developers with a small effect size (Cliff's $\delta = 0.27$). Specifically for Mozilla, we manually extracted information about developers that were hired by the Mozilla Corporation in order to find out if we could identify demographic characteristics that can explain the differences of emoticon usage between developers. We didn't find any statistical differences between hired and volunteer developers. Moreover, for hired developers we also didn't find any statistically significant difference in terms of gender, position (managers vs. non manager, senior vs. non senior) or experience. We only observe a significant difference (p-value $=$ 0.002) between developers based in Europe or North America, and developers in Asia (Taiwan and Japan) or Oceania (Australia and New Zealand) with a medium size effect (Cliff's $\delta = -0.41$). As seen in \fig{fig:boxplot-mozilla-continent}, western developers are more likely to use emoticons than eastern developers. \begin{figure}[!htp] \centering \includegraphics[width=0.75\columnwidth]{figures/boxplot-mozilla-continent} \caption{Ratios of comments with at least emoticons for hired Mozilla developers based on continents.} \label{fig:boxplot-mozilla-continent} \end{figure} \subsection{Emotions expressed} In accordance with the literature, the majority of emoticons are used to express joy. As seen in \tab{tab:emotions-by-source}, besides joy, emoticons are mostly used to express sadness and surprise. We also looked at anger emoticons but these were used less than 1\% of the time. Differences exist between the Apache and Mozilla communities. In Apache, more than 90\% of the emoticons express joy. In Mozilla where emoticons are more frequently used than in Apache, sad (15\%) and surprised (7\%) emoticons are also used more frequently than in Apache (7\% and 2\%). \begin{table}[ht] \centering \caption{Percentage of emoticons used to express joy, sadness and surprise.} \label{tab:emotions-by-source} \begin{small} \begin{tabular}{l|rrrr} source & \% joy & \% sadness & \% surprise & \% other \\ \hline Apache & 90.13 & 7.27 & 2.3 & 0.34 \\ Mozilla & 78.29 & 14.93 & 6.73 & 0.05 \\ \end{tabular} \end{small} \end{table} There are also differences in term of emotions expressed between developers. 50.3\% of Apache developers, who have used emoticons, have only used them to express joy, while only 7.4\% of the Mozilla developers have. 28.4\% of the Mozilla developers have used more than 90\% of emoticons to express joy and 73.5\% of the Apache. On the other extreme, 6.1\% of the Mozilla developers and 5.6\% Apache developers have used at least as many sad and surprised emoticons as joyful ones. \subsection{Variation across the time of the week} \begin{table}[ht] \centering \caption{Statistical difference (p-vlaue and Cliff's $\delta$ of Mann-Whitney U test) between the ratio of issue comments with emoticons during the weekend and during the week.} \label{tab:weekend-variations} \begin{small} \begin{tabular}{l|r|r|r|r} Source & Emoticons & Joy & Sadness & Surprised \\ \hline Mozilla & 0.17 (0.04) & 0.08 (-0.05) & $<$ 0.001 (0.15) & $<$ 0.001 (0.12) \\ Apache & $<$ 0.001 (0.22) & $<$ 0.001 (-0.19) & $<$ 0.001 (0.18) & $<$ 0.001 (0.11) \end{tabular} \end{small} \end{table} \tab{tab:weekend-variations} shows the p-value and effect sizes of a Mann-Whitney U test between the ratio of developers' comments with emoticons during the weekend and during weekdays. It is for Apache where the differences are more statistically significant and have stronger effect sizes. Emoticons are used more often in Apache projects during the weekend than during weekdays. \fig{fig:weekend-ratios} shows that this difference is observable in Apache because there are a number of developers with a relatively small percentage of comments made during weekends (5 to 20\%) but a large percentage of emoticons used during weekends ($> 25$\%). On the other hand, weekends have a lower proportion of joyful emoticons and high proportions of sad and surprised emoticons. This difference is observed in Apache, and in Mozilla projects only for sad and surprised emoticons. \begin{figure}[!htp] \centering \includegraphics[width=0.75\columnwidth]{figures/weekend-ratios} \caption{Developers' ratio of comments during weekends and ratio of emoticons during weekends.} \label{fig:weekend-ratios} \end{figure} \section{Conclusion and future work}\label{sec:conclusion} In this paper, we conducted a preliminary investigation of the use of emoticons by software developers in Apache and Mozilla issue trackers. First, most Mozilla developers have used at least one emoticon, while more than 30\% of the Apache developers never used any. There are also differences between individual developers and individual projects. We looked specifically at Mozilla's developers but couldn't find any statistical difference showing that professional developers might use emoticons differently than volunteers. Looking specifically at Mozilla's hired developers, we found only a difference between developers based in North America or Europe, and Asia or Oceania. The former using emoticons more frequently than the latter with a medium effect size. These differences between developers show that emoticons are most likely to act as a good proxy for sentiment analysis for developers frequently relying on emoticons. In accordance to previous work, Mozilla and Apache developers mostly use emoticons to express joy. More than 90\% of the emoticons used by Apache developers express joy and 78\% for Mozilla developers. Most other emoticons are used to indicate either sadness (7\% for Apache and 15\% for Mozilla) or surprise (2\% for Apache and 7\% for Mozilla). The presence of a significant amount of sad and surprised emoticons show that it is potentially feasible to partly detect negative emotions such as frustration of developers without advanced sentiment analysis. We found a small difference in emoticon usage during the weekend and weekdays. During weekends, developers use more emoticons but these are less positives and include more sad or surprised emoticons. As this paper is only a first step towards understanding how emoticons are used in software development, we will extend our research in different directions. First we want to study the context in which software developers are more likely to use emoticons. For this, we plan on conducting a survey and ask directly to software developers how they use emoticons. Second, we want to compare emoticon usage with the result of sentiment analysis tools. Finally we also intend find correlate emoticons usage with sentiment polarity, such as valence and arousal. \section{Introduction} Decentralized online software development has grown during the past decades to a point where thousands of developers collaborate on a daily basis using electronic communication means. In software engineering, many empirical studies have studied developers interactions and behavior with mining repository techniques. In particular, sentiment analysis has become more and more popular in the past years to study developers' behavior at a large scale. Because most gold standards for sentiment analysis are not based on software engineering data~\cite{Novielli2015}, generic sentiment analysis tools can often perform poorly~\cite{jongeling2015choosing} for analyzing software development data. Thus, software engineering specific gold standards for sentiment analysis have been developed~\cite{islam2017leveraging, calefato2018sentiment}. Although such approaches improve sentiment analysis tool performance it may not be enough~\cite{lin2018sentiment}. Additionally, they require tedious manual labeling. Emoticon usage on large software engineering text masses may lead to automated sentiment labeling and dictionary building \cite{felbo2017using}. One of the challenge with sentiment analysis in a software engineering context is the large amount of neutral sentences due to the technical nature of discussion. Moreover, it can also be difficult for human beings~\cite{imtiaz2018sentiment} to interpret emotions based solely on text. Emoticons are a popular way to add information about expressed emotion in online textual conversations and can be used to improve sentiment analysis tools~\cite{boia2013worth}. However, emoticon usage can vary between persons, culture or from one context to another~\cite{park2013emoticon}. In this paper, we present the early results of an investigation of the differences in usage of emoticons in open source projects from Mozilla and Apache. Our goal is to understand how developers use emoticons differently and to which extent emoticons can be used as a proxy to measure developer behaviors. We define the following research questions: \begin{itemize} \item How does the use of emoticons vary among developers? \item What kind of emotions are expressed with emoticons? \item How does the use of emoticons vary across a week? \end{itemize} The remaining of this paper is structured as follows. In section 2 we present the related work. In section 3 we present the methodology used to collect data, and how we extracted emoticons from issue comments. In section 4 we present preliminary results for each of our research questions. In section 5, we present the limits of our study and we finally conclude in section 6. \section{Methodology}\label{sec:methodo} In this section, we present first the methodology used for extracting data from Apache's and Mozilla's issue trackers. Then we give details on how we identified emoticons from the data alongside some preliminary numbers about the presence of emoticons in Mozilla and Apache comments. \subsection{Data extraction} To answer our research questions, we mined data from Mozilla's\footnote{\url{https://bugzilla.mozilla.org}} and Apache's\footnote{\url{https://issues.apache.org/jira/}} issue trackers. We specifically extracted the history of all comments with associated authors, projects and timestamps using \emph{Perceval} from the \emph{GrimoireLab} tool chain~\cite{DuenasPerceval}. Because issue tracker comments don't contain the timezone of the commenter, we also extracted information with \emph{Perceval} about commits from Mozilla's Mercurial repositories\footnote{\url{https://hg.mozilla.org}} and Apache's Git repositories\footnote{\url{https://git.apache.org/}}. In order to link developer timezones from the commit repositories to their isssue tracker comments, we performed a basic merging of the different authors' identities. We grouped together identities using the same name or email addresses after cleaning. Two of the authors manually checked the result in order to avoid any false positive. We only kept the (merged) developers who had made at least 100 commits. We end up with 102 Apache projects and 66 Mozilla projects with at least 1000 comments. In total, these amounts to 1.3M Apache comments and 4.5M Mozilla comments. \subsection{Identifying emoticons} In order to detect emoticons, we first used NLoN~\cite{mantyla2018nlon} to discard lines of text that are not natural language, such as code and execution traces. We used the list of ASCII emoticons used by SentiStrength and completed it with common ASCII emoticons from Wikipedia\footnote{\url{https://en.wikipedia.org/wiki/List_of_emoticons}}. From this list, we built regular expressions in order to extract the emoticons present in comments. We found 84 of the 107 emoticons from our list that were used at least once in a comment. We manually classified the emoticons based on basic emotions defined by Plutchik~\cite{plutchik1991emotions}: joy (42 emoticons), sadness (11), surprise (25), anger (4) and unknown (2). We made our list of emoticons and associated emotions available at \url{https://github.com/M3SOulu/ESEM2018-Emoticons-Emotions-List}. \begin{table}[ht] \centering \caption{Number of authors, comments and emoticons, percentage of comments with at least one emoticon, and percentage of authors having used at least one emoticon for Apache and Mozilla.} \label{tab:emoticons-by-source} \begin{small} \begin{tabular}{l|r|r|r} source & comments & authors & emoticons \\ \hline Apache & 1,262,833 (2.12\%) & 956 (68.83\%) & 27,903 \\ Mozilla & 4,466,817 (3.65\%) & 472 (97.46\%) & 172,868 \\ \end{tabular} \end{small} \end{table} \tab{tab:emoticons-by-source} shows for Apache and Mozilla the number of unique developers found in the issue trackers and the percentage who has used at least one emoticon, the total number of comments and percentage of comments with at least one emoticon, and the total number of emoticons detected. Overall most comments only contain at most one emoticon. Only 3.7\% of Apache comments with emoticons and 4.9\% of Mozilla comments with emoticons contain 2 emoticons. Less than 1\% of the comments with emoticons contain more than 2 emoticons. \section{Related Work}\label{sec:related} In the last two decades, emoticons have been widely used for communication on the Internet and considered as the paralanguage of the Web~\cite{marvin1995spoof}. As identified in ~\cite{rezabek1998visual}, 6.1\% of electronic mails contains emoticons and 13.2\% of the posts on UseNet newsgroup have emoticons~\cite{witmer1997line}. Emoticons are exploited in both lexicon based and machine learning approaches of sentiment analysis to improve the accuracy of existing lexicon dictionary based sentiment analysis~\cite{hogenboom2013exploiting, bahri2018novel, novak2015sentiment, hogenboom2015exploiting, liu2012emoticon, davidov2010enhanced}. As shown in~\cite{wang2015sentiment} the prediction capability of tweets as positive and negative is considerably enhanced when the emoticons are considered while training the classifier. One of the issue with traditional machine learning technique for sentiment classification is the dependency on topic, domain or even on natural language. An effort is made in~\cite{read2005using} in order to reduce this dependency by training the classifier using an emoticon corpus. In most literature, emoticons are investigated in social media contents. Differences in emoticon usage have been found between gender, showing that in a same sex context, females use more emoticons than males, while in a mixed sex context, male tend to adopt the same standard of expression~\cite{wolf2000emotional}. Park et al.~\cite{park2013emoticon} showed that emoticon usage differs between geographical area and social network. Moreover, they are generally positive and strongly negative sentences generally don't contain emoticons. Miller et al.~\cite{miller2016blissfully} pointed out that there can be disagreement among users about emojis being positive, negative or neutral. However, in this study, we are investigating it in more formal and technical communication of developers during software development. According to the best of our knowledge, this is the first effort to study the emoticons in software engineering in order to primarily focus on how developers use emoticons and which types of emoticons are more frequent. \section{Threats to Validity}\label{sec:threats} We merged developers' identities using a very basic technique. Although we manually checked for false positives, there might be false negatives remaining. We only identified the most common ASCII emoticons and might have missed less common emoticons. Moreover, we manually classified emotions associated with emoticons and only associated one emotion to each emoticon. Differences of context (irony, sarcasm or different interpretation by the users) could imply a different meaning or emotion for some emoticons. Our study only includes open source projects from Apache and Mozilla. The results obtained are specific to those organization's culture and developer habits (external validity). Thus we cannot guarantee that our data set would be representative of the entire software industry or even open source industry.
\section{Introduction} BCK- and BCI-algebras were introduced by Is\'{e}ki \cite{I66} as algebras induced by Meredith's implicational logics \textsf{BCK} and \textsf{BCI}. As a matter of fact, BCK-algebras are the equivalent algebraic semantics for the logic \textsf{BCK}, but \textsf{BCI} is not algebraizable in the sense of \cite{BP89}. Nevertheless, both BCK- and BCI-algebras are closely related to residuated commutative po-monoids because, as is well-known, BCK-algebras are the $\{\rightarrow,1\}$-subreducts of integral residuated commutative po-monoids (see \cite{Fl,OK,Pa}), and BCI-algebras are the $\{\rightarrow,1\}$-subreducts of semi-integral ones, where ``semi-integral'' means that the monoid identity $1$ is a maximal element of the underlying poset (see \cite{RvA}). Also some other algebras of logic, such as MV-algebras, BL-algebras or hoops, are (equivalent to) certain integral residuated commutative po-monoids. Although non-commutative residuated po-monoids were known since the 1930s (for historical overview see \cite{GJKO}), non-commutative versions of the aforementioned algebras were introduced only about 15 years ago in a series of papers by Georgescu, Iorgulescu and coauthors in which they defined pseudo-MV-algebras\footnote{Rach\r{u}nek \cite{Ra} independently introduced another non-commutative generalization of MV-algebras, called GMV-algebras. In fact, pseudo-MV-algebras and these GMV-algebras are equivalent. In \cite{GJKO}, the name ``GMV-algebra'' has a different, more general meaning.} \cite{GI-mv}, pseudo-BL-algebras \cite{DNGI-bl}, pseudo-hoops \cite{GIP-ph}, and pseudo-BCK-algebras \cite{GI}. The prefix ``pseudo'' is meant to indicate non-commutativity, so that a commutative pseudo-X-algebra is an X-algebra. We refer the reader to \cite{ciungu} or \cite{iorgulescu} for an overview of non-commutative generalizations of algebras of logic. Pseudo-BCK-algebras are algebras $(A,\rightarrow,\rightsquigarrow,1)$ with two binary operations $\rightarrow,\rightsquigarrow$ and a constant $1$ such that $(A,\rightarrow,1)$ is a BCK-algebra whenever $\rightarrow$ and $\rightsquigarrow$ coincide; the exact definition is given in Section~\ref{sect-uvod}. An important ingredient is the partial order which is given by $x\leq y$ iff $x\rightarrow y=1$ iff $x\rightsquigarrow y=1$. The underlying poset $(A,\leq)$ has no special properties except that $1$ is its greatest element. A particular case of pseudo-BCK-algebras are Bosbach's cone algebras \cite{Bo} which may be thought of as the $\{\rightarrow,\rightsquigarrow,1\}$-subreducts of negative cones of lattice-ordered groups. That pseudo-BCK-algebras are indeed the $\{\rightarrow,\rightsquigarrow,1\}$-subreducts of integral residuated po-monoids was proved in \cite{JK-ja07} and independently in \cite{vA06} where pseudo-BCK-algebras are called biresiduation algebras. In this context we should mention Komori's BCC-algebras \cite{Ko} which are the $\{\rightarrow,1\}$-subreducts of integral one-sided residuated po-monoids (see \cite{OK}). It was noted in \cite{ZL} that an algebra $(A,\rightarrow,\rightsquigarrow,1)$ is a pseudo-BCK-algebra if and only if both $(A,\rightarrow,1)$ and $(A,\rightsquigarrow,1)$ are BCC-algebras satisfying the identity $x\rightarrow (y\rightsquigarrow z)=y\rightsquigarrow (x\rightarrow z)$. Pseudo-BCI-algebras were introduced by Dudek and Jun \cite{DJ} as a non-commutative generalization of BCI-algebras. They are also algebras $(A,\rightarrow,\rightsquigarrow,1)$ with the same partial order as pseudo-BCK-algebras such that $(A,\rightarrow,1)$ is a BCI-algebra when $\rightarrow$ and $\rightsquigarrow$ coincide, but in contrast to pseudo-BCK-algebras, $1$ is merely a maximal element of the underlying poset. Thus, roughly speaking, the difference between pseudo-BCK- and pseudo-BCI-algebras is the same as the difference between BCK- and BCI-algebras. In the present paper, we focus on some properties of BCI-algebras and try to establish analogous results in the setting of pseudo-BCI-algebras. Basically, there are three topics we deal with: (1)~embedding of pseudo-BCI-algebras into residuated po-monoids; (2)~congruence properties of the quasivarieties of pseudo-BCK- and pseudo-BCI-algebras; and (3)~direct products of pseudo-BCK-algebras and groups which are regarded as pseudo-BCI-algebras. The paper is organized as follows. Section~\ref{sect-uvod} is an introduction to residuated po-monoids, pseudo-BCK- and pseudo-BCI-algebras. In Section~\ref{sect-vnoreni}, we prove that up to isomorphism every pseudo-BCI-algebra is a subalgebra of the $\{\rightarrow,\rightsquigarrow,1\}$-reduct of a semi-integral residuated po-monoid. Actually, we only sketch the construction which is almost identical to the one for BCI-algebras and semi-integral residuated commutative po-monoids presented by Raftery and van Alten \cite{RvA}. Section~\ref{sect-filters} is devoted to congruence properties of pseudo-BCK- and pseudo-BCI-al\-ge\-bras. They form relatively $1$-regular quasivarieties $\var{PBCK}$ and $\var{PBCI}$; the former is relatively congruence distributive, the latter only relatively congruence modular. In fact, most results are proved for any relatively ideal determined quasivariety $\var Q$, by which we mean that the kernels ($1$-classes) of relative congruences of algebras in $\var Q$ may be characterized via ideal terms, similarly to ideal determined varieties (see \cite{GU,BR99}). We prove that the relative congruence lattices of algebras in such a quasivariety $\var Q$ are arguesian. We also briefly discuss prefilters of pseudo-BCK- and pseudo-BCI-algebras; the name ``filter'' is reserved for the congruence kernels. Here, we can see an analogy with subgroups of groups: when a group is regarded as a pseudo-BCI-algebra, then its subgroups are precisely the prefilters of this pseudo-BCI-algebra. The study of prefilter lattices has proven to be useful for pseudo-BCK-algebras as well as various classes of residuated po-monoids; see e.g. \cite{JK-ja07,JK-csmj05,DK,HK,vA02,BKLT}. In Section~\ref{sect-direktnisoucin}, following \cite{RvA}, we characterize those pseudo-BCI-algebras which are isomorphic to the direct product of a pseudo-BCK-algebra and a group which is regarded as a pseudo-BCI-algebra. \section{Preliminaries} \label{sect-uvod} The basic concept is that of a residuated partially ordered monoid (po-monoid for short). A \emph{residuated po-monoid}\footnote{It follows from \eqref{rl} that $(M,\leq,\cdot,1)$ is indeed a \emph{partially ordered monoid}, in the sense that $\leq$ is preserved by multiplication on both sides.} is a structure $\alg M = (M,\leq,\cdot,\rightarrow,\rightsquigarrow,1)$, where $(M,\cdot,1)$ is a monoid, $\leq$ is a partial order\footnote{If the poset $(M,\leq)$ is a lattice, then $\alg M$---or more exactly, $(M,\vee,\wedge,\cdot,\rightarrow,\rightsquigarrow,1)$ where $\vee,\wedge$ are the associated lattice operations---is called a \emph{residuated $\ell$-monoid} or a \emph{residuated lattice}.} on $M$, and $\rightarrow,\rightsquigarrow$ are binary operations on $M$ satisfying the \emph{residuation law}, for all $x,y,z\in M$: \begin{equation} \label{rl} x\leq y\rightarrow z \quad\text{iff}\quad x\cdot y\leq z,\quad\text{and}\quad x\leq y\rightsquigarrow z \quad\text{iff}\quad y\cdot x\leq z. \end{equation} It is clear that the monoid reduct $(M,\cdot,1)$ is commutative if and only if $x\rightarrow y=x\rightsquigarrow y$ for all $x,y\in M$, in which case $(M,\leq,\cdot,\rightarrow,1)$ is a \emph{residuated commutative po-monoid}. A residuated po-monoid is said to be \begin{enumerate}[\indent\upshape (1)] \item \emph{semi-integral} if the monoid identity $1$ is a maximal element of the poset $(M,\leq)$; \item \emph{integral} if $1$ is the greatest element of $(M,\leq)$. \end{enumerate} In the (semi-) integral case, $\leq$ is specified by either of the ``arrows'' because by \eqref{rl} one has \begin{equation}\label{usporadani} x\leq y \quad\text{iff}\quad x\rightarrow y=1 \quad\text{iff}\quad x\rightsquigarrow y=1. \end{equation} Thus (semi-) integral residuated po-monoids may be likewise defined as algebras $\alg M = (M,\cdot,\rightarrow,\rightsquigarrow,1)$ of type $(2,2,2,0)$. The class of such algebras is a quasivariety, but not a variety. The quasivariety of semi-integral residuated po-monoids can be axiomatized by \begin{gather} \label{rpom1a} (x\rightarrow y)\rightsquigarrow ((y\rightarrow z)\rightsquigarrow (x\rightarrow z)) = 1,\\ \label{rpom1b} (x\rightsquigarrow y)\rightarrow ((y\rightsquigarrow z)\rightarrow (x\rightsquigarrow z)) = 1,\\ \label{rpom2a} 1\rightarrow x = x,\\ \label{rpom2b} 1\rightsquigarrow x = x,\\ \label{rpom3} (x\cdot y)\rightarrow z = x\rightarrow (y\rightarrow z),\\ \label{rpom4} x\rightarrow y = 1 \quad\&\quad y\rightarrow x = 1 \quad\Rightarrow\quad x = y, \end{gather} and the quasivariety of integral residuated po-monoids by \eqref{rpom1a}--\eqref{rpom4} together with \begin{equation}\label{integral} x\rightarrow 1 = 1. \end{equation} The proof is straightforward. In \eqref{rpom4} and \eqref{integral} we could equally use $\rightsquigarrow$ instead of $\rightarrow$, and \eqref{rpom3} could be replaced by the identity $(x\cdot y)\rightsquigarrow z = y\rightsquigarrow (x\rightsquigarrow z)$. Pseudo-BCK-algebras were introduced by Georgescu and Iorgulescu \cite{GI} as a non-com\-mu\-ta\-tive generalization of BCK-algebras; they are equivalent to biresiduation algebras which were defined by van Alten \cite{vA06}. Later, pseudo-BCI-algebras were defined by Dudek and Jun \cite{DJ} along the same lines, thus they generalize both BCI-algebras and pseudo-BCK-algebras. There are several possible definitions out of which we choose this (cf. \cite{DKD13} or \cite{JK-hab}): A \emph{pseudo-BCI-algebra} is an algebra $\alg{A}=(A,\rightarrow,\rightsquigarrow,1)$ of type $(2,2,0)$ satisfying the identities \eqref{rpom1a}--\eqref{rpom2b} and the quasi-identity \eqref{rpom4}, and a \emph{pseudo-BCK-algebra} is a pseudo-BCI-algebra which in addition satisfies the identity \eqref{integral}.\footnote{As in the case of residuated po-monoids, in \eqref{rpom4} and \eqref{integral}, $\rightarrow$ could be equivalently replaced by $\rightsquigarrow$.} If $\alg A$ is a pseudo-BCI-algebra (resp. pseudo-BCK-algebra) in which $x\rightarrow y=x\rightsquigarrow y$ for all $x,y\in A$, then the algebra $(A,\rightarrow,1)$ is a \emph{BCI-algebra} (resp. \emph{BCK-algebra}).\footnote{Is\'{e}ki \cite{I66} originally defined BCI- and BCK-algebras as algebras $(A,*,0)$, where $*$ may be thought of as a kind of subtraction and $0$ is a minimal (or the least) element of the underlying poset $(A,\leq)$ which is defined by $x\leq y$ iff $x*y=0$. Similarly, in \cite{GI} and \cite{DJ}, pseudo-BCI- and pseudo-BCK-algebras were defined as algebras $(A,*,\circ,0)$ with two subtractions $*,\circ$ and minimal element $0$.} For any pseudo-BCI-algebra $\alg{A}$, the relation $\leq$ given by \eqref{usporadani}---more precisely, by $x\leq y$ iff $x\rightarrow y=1$, which is equivalent to $x\rightsquigarrow y=1$---is a partial order on $A$. The poset $(A,\leq)$ is the \emph{underlying poset} of $\alg A$. The difference between pseudo-BCK- and pseudo-BCI-algebras is that in the former case, $1$ is the greatest element of the underlying poset, while in the latter case, $1$ is only a maximal element. Thus, pseudo-BCK-algebras are integral and pseudo-BCI-algebras semi-integral. Of course, pseudo-BCI- and pseudo-BCK-algebras are closely related to residuated po-monoids. If $\alg{M}=(M,\cdot,\rightarrow,\rightsquigarrow,1)$ is a semi-integral (resp. integral) residuated po-monoid, then every subalgebra of the reduct $(M,\rightarrow,\rightsquigarrow,1)$ is a pseudo-BCI-algebra (resp. pseudo-BCK-algebra). All pseudo-BCK-algebras (biresiduation algebras) arise in this way, i.e., up to isomorphism, every pseudo-BCK-algebra is a $\{\rightarrow,\rightsquigarrow,1\}$-subreduct of an integral residuated po-monoid. In Section \ref{sect-vnoreni} we establish an analogue for pseudo-BCI-algebras and semi-integral residuated po-monoids. An easy but important observation is this: Given a pseudo-BCI-algebra (resp. pseudo-BCK-algebra) $\alg{A}=(A,\rightarrow,\rightsquigarrow,1)$, the algebra $\alg{A}^\dagger=(A,\rightsquigarrow,\rightarrow,1)$ is a pseudo-BCI-algebra (resp. pseudo-BCK-algebra), too. It is plain that $\alg{A}$ and $\alg{A}^\dagger$ have the same underlying poset $(A,\leq)$, but it can easily happen that the algebras $\alg A$ and $\alg A^\dagger$ are \emph{not} isomorphic. For example, the prelinearity identities \begin{gather*} (x\rightarrow y)\rightarrow z\leq ((y\rightarrow x)\rightarrow z)\rightarrow z \quad\text{and}\quad (x\rightsquigarrow y)\rightsquigarrow z\leq ((y\rightsquigarrow x)\rightsquigarrow z)\rightsquigarrow z \end{gather*} are independent in general. Note that if $\alg A$ satisfies either of the two identities, then $z\leq 1$ holds in $\alg A$, so $\alg A$ is a pseudo-BCK-algebra. In the following lemma we list the basic arithmetical properties of pseudo-BCI-al\-ge\-bras. For completeness, we also include some properties that have been implicitly mentioned above, such as \eqref{vl1}, \eqref{vl2} or \eqref{vl4}. \begin{lem}[cf. \cite{DJ}, \cite{JKN}, \cite{LP}] \label{L1} In any pseudo-BCI-algebra $\alg{A}$, for all $x,y,z\in A$: \begin{enumerate}[\indent\upshape (1)] \item\label{vl1} $x\rightarrow x=1$, $x\rightsquigarrow x=1$; \item\label{vl2} $x\rightarrow y\leq (y\rightarrow z)\rightsquigarrow (x\rightarrow z)$, $x\rightsquigarrow y\leq (y\rightsquigarrow z)\rightarrow (x\rightsquigarrow z)$; \item\label{vl3} $x\leq (x\rightarrow y)\rightsquigarrow y$, $x\leq (x\rightsquigarrow y)\rightarrow y$; \item\label{vl4} $x\rightarrow y=1$ iff $x\rightsquigarrow y=1$; \item\label{vl5} $x\leq y$ implies $y\rightarrow z\leq x\rightarrow z$ and $y\rightsquigarrow z\leq x\rightsquigarrow z$; \item\label{vl6} $x\rightarrow (y\rightsquigarrow z)=y\rightsquigarrow (x\rightarrow z)$; \item\label{vl7} $x\leq y\rightarrow z$ iff $y\leq x\rightsquigarrow z$; \item\label{vl8} $x\rightarrow y\leq (z\rightarrow x)\rightarrow (z\rightarrow y)$, $x\rightsquigarrow y\leq (z\rightsquigarrow x)\rightsquigarrow (z\rightsquigarrow y)$; \item\label{vl9} $x\leq y$ implies $z\rightarrow x\leq z\rightarrow y$ and $z\rightsquigarrow x\leq z\rightsquigarrow y$; \item\label{vl10} $x\rightarrow 1=x\rightsquigarrow 1$; \item\label{vl11} $(x\rightarrow y)\rightarrow 1=(x\rightarrow 1)\rightsquigarrow (y\rightarrow 1)$, $(x\rightsquigarrow y)\rightsquigarrow 1=(x\rightsquigarrow 1)\rightarrow (y\rightsquigarrow 1)$; \item $((x\rightarrow y)\rightsquigarrow y)\rightarrow y=x\rightarrow y$, $((x\rightsquigarrow y)\rightarrow y)\rightsquigarrow y=x\rightsquigarrow y$. \end{enumerate} \end{lem} Note that the inequalities $y\leq x\rightarrow y$ and $y\leq x\rightsquigarrow y$ hold true only in pseudo-BCK-algebras (because $y\leq x\rightarrow y$ is equivalent to $x\leq y\rightsquigarrow y=1$). Let $\alg A$ be a pseudo-BCI-algebra. The identities \eqref{vl11} of Lemma \ref{L1} entail that the set \[ I_{\alg{A}} = \{x\in A \mid x\leq1\}, \] which we call the \emph{integral part} of $\alg{A}$, is a subuniverse of $\alg{A}$. Clearly, the subalgebra $\alg{I}_{\alg{A}}=(I_{\alg A},\rightarrow,$ $\rightsquigarrow,1)$ is a pseudo-BCK-algebra; in fact, $\alg{I}_{\alg{A}}$ is the largest subalgebra of $\alg A$ which is a pseudo-BCK-algebra. By the \emph{group part} of the pseudo-BCI-algebra $\alg{A}$ we mean the set \[ G_{\alg{A}} = \{x\rightarrow 1 \mid x\in A\} = \{x\rightsquigarrow 1 \mid x\in A\}. \] Again, by \eqref{vl10} and \eqref{vl11}, $G_{\alg A}$ is a subuniverse of $\alg{A}$. The name ``group part'' is justified by the fact that the subalgebra $\alg{G}_{\alg{A}}=(G_{\alg A},\rightarrow,\rightsquigarrow,1)$ is term equivalent to a group. Indeed, if we put \[ g\cdot h = (g\rightarrow 1) \rightsquigarrow h \] for $g,h\in G_{\alg{A}}$, then $(G_{\alg{A}},\cdot,1)$ is a group in which $g^{-1} = g\rightarrow 1 = g\rightsquigarrow 1$ is the inverse of $g\in G_{\alg{A}}$; the original operations $\rightarrow$ and $\rightsquigarrow$ on $G_{\alg{A}}$ are retrieved by \[ g\rightarrow h=h\cdot g^{-1} \quad\text{and}\quad g\rightsquigarrow h=g^{-1}\cdot h, \] respectively. This was essentially proved in \cite{D12a,D12b} (also see \cite{Z10a,Z10b}). If we define $g*h=h\cdot g$, then $(G_{\alg{A}},*,1)$ is a group which is isomorphic to $(G_{\alg{A}},\cdot,1)$ and gives rise to the pseudo-BCI-algebra $\alg{G}_{\alg{A}}^{\dagger}=(G_{\alg{A}},\rightsquigarrow,\rightarrow,1)$, because $g\rightsquigarrow h=g^{-1}\cdot h=h*g^{-1}$ and $g\rightarrow h=h\cdot g^{-1}=g^{-1}*h$. Consequently, the map $g\in G_{\alg{A}}\mapsto g^{-1}\in G_{\alg{A}}$ is an isomorphism between $\alg{G}_{\alg{A}}$ and $\alg{G}_{\alg{A}}^{\dagger}$ (though $\alg A$ and $\alg A^\dagger$ need not be isomorphic). The following was independently proved in several papers; see \cite{D12a,D12b}, \cite{KS} or \cite{Z10a,Z10b}. The proof is easy anyway. \begin{lem}\label{lem-grcast} For any pseudo-BCI-algebra $\alg A$, $G_{\alg{A}}$ is the set of the maximal elements of $(A,\leq)$. For every $x\in A$, the element $g=(x\rightarrow 1)\rightarrow 1$ is the only $g\in G_{\alg{A}}$ such that $x\leq g$. Therefore, $x\in G_{\alg{A}}$ iff $x=(x\rightarrow 1)\rightarrow 1$. \end{lem} Analogously, for the integral part we have: \begin{lem}\label{lem-intcast} Let $\alg A$ be a pseudo-BCI-algebra. For any $x\in A$, $((x\rightarrow 1)\rightarrow 1)\rightarrow x\in I_{\alg A}$, and hence $x\in I_{\alg A}$ iff $x=((x\rightarrow 1)\rightarrow 1)\rightarrow x$. \end{lem} \begin{proof} Since $x\leq (x\rightarrow 1)\rightarrow 1$, it follows $1=x\rightarrow x\geq ((x\rightarrow 1)\rightarrow 1)\rightarrow x$. If $x\leq 1$, then $((x\rightarrow 1)\rightarrow 1)\rightarrow x=(1\rightarrow 1)\rightarrow x=1\rightarrow x=x$. \end{proof} We adopt the notation of \cite{RvA}, but the sets $I_{\alg A}$ and $G_{\alg A}$ can be found in the literature under various names and symbols. $I_{\alg A}$ is often called the \emph{pseudo-BCK-part} of $\alg A$ and denoted by $K(\alg A)$, and $G_{\alg A}$ is called the \emph{anti-grouped part} or the \emph{center} of $\alg A$, denoted by $AG(\alg A)$ or $At(\alg A)$, where ``$At$'' comes from ``atoms''. Pseudo-BCI-algebras satisfying $G_{\alg A}=A$ are called \emph{p-semisimple}. Another important consequence of Lemma \ref{L1} \eqref{vl10} and \eqref{vl11} is that the map \begin{equation}\label{gamma} \gamma\colon x\in A\mapsto x\rightarrow 1\in G_{\alg{A}} \end{equation} is a homomorphism from $\alg{A}$ onto $\alg{G}_{\alg{A}}^\dagger$, and \begin{equation}\label{delta} \delta\colon x\in A\mapsto (x\rightarrow 1)\rightarrow 1\in G_{\alg{A}} \end{equation} is a homomorphism from $\alg{A}$ onto $\alg{G}_{\alg{A}}$. We have $\alg{A}/\ker\gamma\cong\alg{G}_{\alg{A}}^\dagger \cong\alg{G}_{\alg{A}} \cong \alg{A}/\ker\delta$ and $\gamma^{-1}(1)=\delta^{-1}(1)=I_{\alg{A}}$, thus $I_{\alg A}$ is always the kernel of a relative congruence of $\alg A$, while $G_{\alg A}$ is not in general (see Section~\ref{sect-filters}). Given any pseudo-BCK-algebra $\alg B$ and any group $\alg H$ (regarded as a pseudo-BCI-al\-ge\-bra), we can always construct a pseudo-BCI-algebra $\alg A$ such that $\alg I_{\alg A}\cong \alg B$ and $\alg G_{\alg A}\cong \alg H$. For example, we can take the direct product $\alg A=\alg B\times\alg H$ because $I_{\alg A}=\{(b,1)\mid b\in B\}$ and $G_{\alg A}=\{(1,h)\mid h\in H\}$. In Section~\ref{sect-direktnisoucin} we characterize those pseudo-BCI-algebras $\alg{A}$ which are isomorphic to the direct product $\alg{I}_{\alg{A}}\times\alg{G}_{\alg{A}} \cong \alg{I}_{\alg{A}}\times\alg{G}_{\alg{A}}^\dagger$. But there is an easier construction, see \cite{Z13} (in fact, Theorem 4.3 therein presents a construction of a semi-integral residuated po-monoid from a bounded integral residuated po-monoid and a group). Let $\alg{B}=(B,\rightarrow,\rightsquigarrow,1)$ be a pseudo-BCK-algebra, $(H,\cdot,1)$ be a group such that $B\cap H=\{1\}$, and let $\alg{H}=(H,\rightarrow,\rightsquigarrow,1)$ be the pseudo-BCI-algebra derived from the group, i.e. $g\rightarrow h=h\cdot g^{-1}$ and $g\rightsquigarrow h=g^{-1}\cdot h$. Let $A=B\cup H$ be equipped with the operations $\rightarrow,\rightsquigarrow$ defined as follows: \[ x\diamond y= \begin{cases} x\diamond y & \text{if } x,y\in B \text{ or } x,y\in H,\\ y & \text{if } x\in B, y\in H,\\ x^{-1} & \text{if } x\in H\setminus\{1\}, y\in B, \end{cases} \] where $\diamond\in\{\rightarrow,\rightsquigarrow\}$. Then $\alg{A}=(A,\rightarrow,\rightsquigarrow,1)$ is a pseudo-BCI-algebra with $\alg I_{\alg{A}}=\alg B$ and $\alg G_{\alg{A}}=\alg H$. The proof is but a direct inspection of all possible cases. Note that $\alg{A}$ is not a subalgebra of the direct product $\alg{B}\times\alg{H}$. \section{Embedding into the $\{\rightarrow,\rightsquigarrow,1\}$-reducts of residuated po-monoids} \label{sect-vnoreni} It is folklore that BCK-algebras are the $\{\rightarrow,1\}$-subreducts of integral residuated commutative po-monoids (see \cite{Fl,OK,Pa}). Similarly, pseudo-BCK-algebras (biresiduation algebras) are the $\{\rightarrow,\rightsquigarrow,1\}$-subreducts of integral residuated po-monoids, which was proved independently by van Alten in \cite{vA06} and by the second author in \cite{JK-cga}. Also see \cite[Theorem 1.2.1]{JK-hab}, the proof is just a ``non-commutative modification'' of the construction of \cite{OK}. In \cite[Theorem 2]{RvA}, Raftery and van Alten proved that BCI-algebras are the $\{\rightarrow,1\}$-subreducts of semi-integral residuated commutative po-monoids, and the aim of this section is to generalize their result to pseudo-BCI-algebras. In proving that a pseudo-BCK-algebra $\alg{A}$ is isomorphic to a subalgebra of the residuation reduct of an integral residuated po-monoid, one first constructs a certain po-monoid, say $\alg{J}(\alg{A})$, whose identity $\{1\}$ is also its smallest element, and then takes the set of order-filters of this intermediate po-monoid in order to obtain the integral residuated po-monoid into which $\alg{A}$ embeds. In the case that $\alg{A}$ is a pseudo-BCI-algebra, the first step remains unchanged, but $\{1\}$ is merely a minimal element in the po-monoid $\alg{J}(\alg{A})$, and hence the second step must be modified as in \cite{RvA}. Let $\alg{M}=(M,\leq,*,e)$ be a po-monoid in which $e$ is a minimal element. Let $G_{\alg{M}}$ be the set of the minimal elements of $(M,\leq)$ and suppose that every $a\in M$ exceeds a unique $g\in G_{\alg{M}}$. Suppose further that $(G_{\alg{M}},\cdot,e)$ is a group such that $g\cdot h\leq g*h$ for all $g,h\in G_{\alg{M}}$. Note that we do not require that $(G_{\alg{M}},\cdot,e)$ be a subgroup of $(M,*,e)$. Let $\mathfrak{F}_{\alg{M}}$ be the set of all (non-empty) order-filters $X$ in the poset $(M,\leq)$ with the property that $X\subseteq [g)$\footnote{As usual, for an element $p$ in a poset $(P,\leq)$, $[p)$ denotes the order-filter $\{x\in P\mid x\geq p\}$.} for some $g\in G_{\alg{M}}$. Note that $[a)\in \mathfrak{F}_{\alg{M}}$ for every $a\in M$, because there is a unique $g\in G_{\alg{M}}$ with $g\leq a$, and hence the map $a\mapsto [a)$ is an antitone injection from $(M,\leq)$ into $(\mathfrak{F}_{\alg{M}},\subseteq)$. For any $X,Y\in \mathfrak{F}_{\alg{M}}$, let \begin{gather*} X\odot Y = \{a\in M\mid a\geq x*y \text{ for some } x\in X,y\in Y\},\\ X\rightarrow Y = \{a\in M\mid [a)\odot X\subseteq Y\}, \text{ and}\\ X\rightsquigarrow Y = \{a\in M\mid X\odot [a)\subseteq Y\}. \end{gather*} \begin{lem}\label{vnoreni1} If $\alg{M}=(M,\leq,*,e)$ is a po-monoid satisfying the above conditions, then $\bm{\mathfrak{F}}_{\alg{M}}=(\mathfrak{F}_{\alg{M}},\subseteq,$ $\odot,\rightarrow,\rightsquigarrow,[e))$ is a semi-integral residuated po-monoid. \end{lem} \begin{proof} As in \cite{RvA}, we leave the details to the reader, we only make two remarks. First, if $X\subseteq [g)$ and $Y\subseteq [h)$ where $g,h\in G_{\alg{M}}$, then $x*y\geq g*h\geq g\cdot h\in G_{\alg{M}}$ for all $x\in X$ and $y\in Y$, whence $X\odot Y\in\mathfrak{F}_{\alg{M}}$. Second, if $a\in X\rightarrow Y$ where $a\geq f\in G_{\alg{M}}$, then $[a)\odot X\subseteq Y$ and so $a*x\geq h$ for any $x\in X$, and at the same time, $a*x\geq f\cdot g$. Since there is a unique minimal element below $a*x$, it follows that $h=f\cdot g$, whence $a\geq f=h\cdot g^{-1}\in G_{\alg{M}}$. This shows that $X\rightarrow Y\subseteq [h\cdot g^{-1})$, and so $X\rightarrow Y\in\mathfrak{F}_{\alg{M}}$. Analogously, $X\rightsquigarrow Y\in\mathfrak{F}_{\alg{M}}$. \end{proof} Now, let $\alg{A}=(A,\rightarrow,\rightsquigarrow,1)$ be a pseudo-BCI-algebra. As in Section \ref{sect-uvod}, $G_{\alg{A}}$ denotes the group part of $\alg{A}$. Let $W_A$ be the set of all non-empty words $\alpha=a_1\dots a_n$ over the set $A$. For any such $\alpha\in W_A$ and $x\in A$ we write \begin{align*} \alpha \rightarrow x &= a_1\rightarrow (\dots \rightarrow (a_n\rightarrow x)\dots),\\ \alpha \rightsquigarrow x &= a_n\rightsquigarrow (\dots \rightsquigarrow (a_1\rightsquigarrow x)\dots). \end{align*} In view of Lemma \ref{L1} \eqref{vl4} and \eqref{vl6}, we have $\alpha \rightarrow x=1$ iff $\alpha \rightsquigarrow x=1$, and also $\alpha \rightarrow (\beta \rightsquigarrow x) = \beta \rightsquigarrow (\alpha \rightarrow x)$ for all $\alpha,\beta\in W_A$. For any $\alpha\in W_A$, let \[ J(\alpha) = \{x\in A\mid \alpha \rightarrow x=1\}, \] and let $J(\alg{A})=\{J(\alpha)\mid \alpha\in W_A\}$. Note that $J(a)=[a)$ for any $a\in A$, and hence $J(g)=\{g\}$ for any $g\in G_{\alg{A}}$. Also, $a\leq b$ iff $J(b)\subseteq J(a)$ for all $a,b\in A$, whence the map $a\mapsto J(a)$ is an antitone injection from $(A,\leq)$ into $(J(\alg{A}),\subseteq)$. Further, let \[ J(\alpha)*J(\beta)=J(\alpha\beta); \] thus $J(\alpha)*J(\beta)=\{x\in A\mid \alpha\rightarrow (\beta\rightarrow x)=1\}$. \begin{lem}\label{vnoreni2} For any pseudo-BCI-algebra $\alg{A}$, $\alg{J}(\alg{A}) = (J(\alg{A}),\subseteq,*,\{1\})$ is a po-monoid such that $J(g)=\{g\}$ with $g\in G_{\alg{A}}$ are the minimal elements of $(J(\alg{A}),\subseteq)$. Every $J(\alpha) \in J(\alg{A})$ contains a unique $g\in G_{\alg{A}}$, namely, $g=(\alpha\rightarrow 1)\rightarrow 1$. Moreover, for all $\alpha,\beta\in W_A$ and $g,h\in G_{\alg{A}}$, if $g\in J(\alpha)$ and $h\in J(\beta)$, then $g\cdot h\in J(\alpha)*J(\beta)$, where $g\cdot h$ is calculated in the group $(G_{\alg A},\cdot,1)$. \end{lem} \begin{proof} Again, the proof is straightforward. We only prove the last two statements. If $g\in J(\alpha)$ where $g\in G_{\alg{A}}$, then $1=\alpha\rightarrow g=\alpha\rightarrow ((g\rightarrow 1)\rightsquigarrow 1)=(g\rightarrow 1)\rightsquigarrow (\alpha\rightarrow 1)$, so $g\rightarrow 1\leq \alpha\rightarrow 1$ whence $g=(g\rightarrow 1)\rightarrow 1\geq (\alpha\rightarrow 1)\rightarrow 1$. Since $g$ and $(\alpha\rightarrow 1)\rightarrow 1$ are maximal elements, $g=(\alpha\rightarrow 1)\rightarrow 1$. Furthermore, if $g\in J(\alpha)$ and $h\in J(\beta)$ where $g,h\in G_{\alg{A}}$, then $\alpha\rightarrow (\beta\rightarrow (g\cdot h))=\alpha\rightarrow [\beta\rightarrow ((g\rightarrow 1)\rightsquigarrow h)]=\alpha\rightarrow [(g\rightarrow 1)\rightsquigarrow (\beta\rightarrow h)]=\alpha\rightarrow ((g\rightarrow 1)\rightsquigarrow 1)=\alpha\rightarrow g=1$. \end{proof} Since $(G_{\alg{A}},\cdot,1)$ is a group, it follows that also $(G_{\alg{J}(\alg{A})},\cdot,\{1\})$ is a group, where $G_{\alg{J}(\alg{A})}=\{\{g\}\mid g\in G_{\alg{A}}\}$ and $\{g\}\cdot\{h\}=\{g\cdot h\}$.\footnote{In general, $\{g\cdot h\}\neq\{g\}*\{h\}$ for $g,h\in G_{\alg A}$ because it can happen that $g\rightarrow (h\rightarrow x)=1$, but $(g\cdot h)\rightarrow x\neq 1$, or vice versa.} Moreover, by the last statement of Lemma \ref{vnoreni2} we have $\{g\}\cdot\{h\} \subseteq \{g\}*\{h\}$, thus the po-monoid $\alg{J}(\alg{A})=(J(\alg{A}),\subseteq,*,\{1\})$ satisfies the assumptions of Lemma \ref{vnoreni1}, and hence $\bm{\mathfrak{F}}_{\alg{J}(\alg{A})}=(\mathfrak{F}_{\alg{J}(\alg{A})},\subseteq,\odot,\rightarrow,\rightsquigarrow,[\{1\}))$ is a semi-integral residuated po-monoid. If $\alg{A}$ is a pseudo-BCK-algebra, then $\bm{\mathfrak{F}}_{\alg{J}(\alg{A})}$ is integral. Given $x\in A$, we have $J(\alpha)\in [J(x))$ iff $J(x)\subseteq J(\alpha)$ iff $x\in J(\alpha)$, whence the composite injection $A\to J(\alg{A})\to \mathfrak{F}_{\alg{J}(\alg{A})}$ is given by \[ x\mapsto J(x)\mapsto [J(x))=\{J(\alpha)\in J(\alg{A})\mid x\in J(\alpha)\}. \] We conclude: \begin{thm} For any pseudo-BCI-algebra $\alg{A}=(A,\rightarrow,\rightsquigarrow,1)$, the map \[ x\in A \mapsto \{J(\alpha)\in J(\alg{A})\mid x\in J(\alpha)\} \in \mathfrak{F}_{\alg{J}(\alg{A})} \] is an embedding of $\alg{A}$ into the pseudo-BCI-algebra $(\mathfrak{F}_{\alg{J}(\alg{A})},\rightarrow,\rightsquigarrow,[\{1\}))$. Consequently, pseudo-BCI-algebras {\upshape(}resp. pseudo-BCK-algebras{\upshape)} are the $\{\rightarrow,\rightsquigarrow,1\}$-subreducts of se\-mi-integral {\upshape(}resp. integral{\upshape)} residuated po-mo\-noids. \end{thm} \section{Relative congruences, filters and prefilters} \label{sect-filters} First, we recall some general facts; see e.g. \cite{BR99,BR08}. Let $\var{Q}$ be a quasivariety of algebras of a given language with a constant $1$. A congruence $\theta$ of an algebra $\alg A\in\var Q$ is a \emph{relative congruence} (or a \emph{$\var Q$-congruence}) if the quotient algebra $\alg A/\theta$ belongs to $\var Q$. The set of all relative congruences of $\alg A$ is denoted by $\conq Q A$; ordered by set-inclusion, it forms an algebraic lattice $\bconq Q A$. If the lattice of (relative) congruences of every algebra $\alg A\in\var Q$ is modular or distributive, then $\var Q$ is said to be (\emph{relatively}) \emph{congruence modular} or (\emph{relatively}) \emph{congruence distributive}, respectively. Furthermore, $\var Q$ is (\emph{relatively}) \emph{$1$-regular} if distinct (relative) congruences of algebras $\alg A\in\var Q$ have distinct kernels; in other words, if $\phi,\psi$ are (relative) congruences of $\alg{A}$ with $[1]_\phi = [1]_\psi$, then $\phi=\psi$. It is known that $\var Q$ is relatively $1$-regular if and only if there exist binary terms $d_1,\dots,d_n$ such that $\var Q$ satisfies \[\textstyle \bigwedge_{i=1}^{n} d_i(x,y) = 1 \quad\Leftrightarrow\quad x = y. \] In this case, every relative congruence $\theta\in\conq Q A$ is determined by its kernel $[1]_\theta$ by \[ (a,b)\in\theta \quad\text{iff}\quad d_i(a,b)\in [1]_\theta \text{ for all } i=1,\dots,n, \] and the kernels of relative congruences of $\alg A$ form an algebraic lattice which is isomorphic to $\bconq{Q}{A}$; the (inverse) isomorphism is given by $\theta\mapsto [1]_\theta$. It is also known that a $1$-regular variety is always congruence modular, but a relatively $1$-regular quasivariety need not be relatively congruence modular. Now, let $\var{PBCK}$ and $\var{PBCI}$ be respectively the quasivariety of pseudo-BCK-al\-ge\-bras and the quasivariety of pseudo-BCI-algebras. Both $\var{PBCK}$ and $\var{PBCI}$ are relatively $1$-regular (but not $1$-regular), as witnessed by the terms $d_1(x,y)=x\diamond y$ and $d_2(x,y)=y\diamond x$ where $\diamond$ is either of the arrows $\rightarrow$ and $\rightsquigarrow$. Hence every relative congruence $\theta$ is determined by its kernel $[1]_\theta$ by: $(a,b)\in\theta$ iff $a\diamond b,b\diamond a\in [1]_\theta$. An internal characterization of the kernels of relative congruences of pseudo-BCI-algebras, similar to that for pseudo-BCK-algebras, can be found in \cite{D14} (see \cite{HK,JK-hab} for pseudo-BCK-algebras). Given a pseudo-BCI-algebra $\alg A$, a subset $F\subseteq A$ is the kernel $[1]_\theta$ of a (unique) relative congruence $\theta\in\conq{PBCI}{A}$ if and only if \begin{enumerate}[\indent (i)] \item $1\in F$; \item if $a,a\rightarrow b\in F$, then $b\in F$; \item if $a\in F$, then $a\rightarrow 1\in F$; and \item for all $a,b\in A$, $a\rightarrow b\in F$ iff $a\rightsquigarrow b\in F$. \end{enumerate} In \cite{D14}, such subsets are called ``closed compatible deductive systems'', but we will call them ``filters'' (see below). It is not hard to show that in (ii) we can use $\rightsquigarrow$ in place of $\rightarrow$ and that (iv) is equivalent to the condition \begin{enumerate}[\indent (i)]\setcounter{enumi}{4} \item $(b\rightarrow a)\rightarrow a, (b\rightsquigarrow a)\rightsquigarrow a\in F$ for all $a\in A$, $b\in F$. \end{enumerate} Of course, (iii) is redundant if $\alg A$ is a pseudo-BCK-algebra, and (iv) or (v) is redundant if $\alg A$ is a BCI-algebra. There are quite a few papers devoted to the subsets satisfying (i) and (ii); they are called ``deductive systems'' \cite{D14}, ``filters'' \cite{ZJ14} or ``pseudo-BCI-filters'' \cite{Z10b}, and ``ideals'' or ``pseudo-BCI-ideals'' when the dual presentation of pseudo-BCI-algebras is used \cite{D12a,JKN,LP}. The adjective ``closed'' is added when also the condition (iii), which is equivalent to being a subalgebra, is satisfied \cite{D14,D12a}. Our terminology is hopefully simpler: Given a pseudo-BCI-algebra $\alg A$, we say that $F\subseteq A$ is \begin{enumerate}[\indent\upshape (1)] \item a \emph{filter} of $\alg A$ if $F$ is the kernel $[1]_\theta$ of some $\theta\in\conq{PBCI}{A}$, i.e., if $F$ satisfies the above conditions (i)--(iv), or equivalently, the conditions (i)--(iii) and (v); \item a \emph{prefilter} of $\alg A$ if it satisfies (i)--(iii). \end{enumerate} Here, we require that also (iii) be satisfied because when a group is regarded as a pseudo-BCI-algebra, then the subgroups are precisely the prefilters. We let $\fil A$ and $\pfil A$ denote respectively the set of filters and the set of prefilters of $\alg A$; it is obvious that with respect to set-inclusion they form algebraic lattices, $\bfil A$ and $\bpfil A$. We know that $\bfil A \cong \bconq{PBCI}{A}$ under the mutually inverse maps $F\mapsto\theta_F$ and $\theta\mapsto [1]_\theta$ where $\theta_F$ is given by \[ (a,b)\in\theta_F \quad\text{iff}\quad a\rightarrow b,b\rightarrow a\in F \quad\text{iff}\quad a\rightsquigarrow b,b\rightsquigarrow a\in F. \] Dymek \cite{D14} proved somewhat more; he proved that if $F$ is a ``compatible deductive system'' not necessarily ``closed'' (i.e., if $F$ satisfies (i), (ii) and (iv)), then $\theta_F\in\con A$ and $F\subseteq [1]_{\theta_F}$, with equality exactly if $F$ is ``closed''. It is known that the quasivariety of BCK-algebras $\var{BCK}$ is relatively congruence distributive, while the quasivariety of BCI-algebras $\var{BCI}$ is only relatively congruence modular (see \cite{BR99,BR08,RvA}). It comes as no surprise that likewise $\var{PBCK}$ is relatively congruence distributive; more directly, for any pseudo-BCK-algebra $\alg A$, $\bpfil A$ is a distributive lattice and $\bfil A$ is its complete sublattice (see \cite[Corollary 2.1.12, 2.2.9]{JK-hab} and \cite{HK}). However, $\var{PBCI}$ can be relatively congruence modular at best, because it contains a subclass which is term equivalent to groups, so the filter lattice $\bfil A$ need not be distributive. Note that---since subgroups correspond to prefilters---the prefilter lattice $\bpfil A$ need not be even modular. In what follows, we prove that $\var{PBCI}$ is indeed relatively congruence modular. We actually prove that this holds true for any relatively $1$-regular quasivariety which has a ``nice description'' of the kernels of relative congruences, by which we mean a description by means of the so-called ``ideal terms'' (see \cite{GU,BR99}). As before, let $\var Q$ be a quasivariety whose language has a constant $1$. An \emph{ideal term}\footnote{Since the concept of an ideal term as well as that of an ideal obviously depends on the choice of $\var Q$, we should more accurately speak of $\var Q$-ideal terms and $\var Q$-ideals.} (in variables $y_1,\dots,y_n$) is a term $t(x_1,\dots,x_m,y_1,\dots,y_n)$ in the language of $\var Q$ such that $\var{Q}$ satisfies the identity \[ t(x_1,\dots,x_m,1,\dots,1) = 1. \] An \emph{ideal}\footnotemark[\value{footnote}]{} of an algebra $\alg A\in\var Q$ is a non-empty subset $I$ of $A$ which is closed under all ideal terms, in the sense that for every ideal term $t(x_1,\dots,x_m,y_1,\dots,y_n)$ one has $t(a_1,\dots,a_m,b_1,\dots,b_n)\in I$ for all $a_1,\dots,a_m\in A$ and $b_1,\dots,b_n\in I$. Ordered by set-inclusion, the ideals of $\alg A$ form an algebraic lattice $\bidq Q A$. It is easy to see that the ideal generated by $\emptyset\neq S\subseteq A$ consists precisely of the elements $t(a_1,\dots,a_m,b_1,\dots,b_n)$ where $t(x_1,\dots,x_m,y_1,\dots,y_n)$ is an ideal term and $a_1,\dots,a_m\in A$, $b_1,\dots,b_n\in S$. $\var{Q}$ is said to be \emph{ideal determined} if for every $\alg{A}\in\var{Q}$, every ideal $I$ of $\alg{A}$ is the kernel $[1]_\theta$ of a unique congruence $\theta\in\con{A}$, in which case the map $\theta\mapsto [1]_\theta$ is an isomorphism between the lattices $\bcon A$ and $\bidq Q A$. Analogously, we will say that $\var Q$ is \emph{relatively ideal determined} provided that every ideal $I$ of $\alg{A}$ is the kernel of a unique relative congruence $\theta\in\conq{Q}{A}$, for all $\alg{A}\in\var{Q}$. If $\var Q$ has this property, then $\bconq{Q}{A} \cong \bidq {Q}{A}$ for all $\alg{A}\in\var{Q}$. By \cite{GU}, every ideal determined variety is congruence modular. Following the proof given in \cite{GU}, we prove that every relatively ideal determined quasivariety is relatively congruence modular. Recalling the conditions (i)--(iii) and (v), one can easily find a finite basis of ideal terms for pseudo-BCK- and pseudo-BCI-algebras: \begin{prop}\label{prop-idealterms} Let $\alg A$ be a pseudo-BCI-algebra. For any $\emptyset\neq F\subseteq A$, the following are equivalent: \begin{enumerate}[\indent\upshape (1)] \item $F$ is a filter of $\alg A$; \item $F$ is an ideal of $\alg A$, i.e., $F$ is closed under all $\var{PBCI}$-ideal terms; \item $1\in F$ and $F$ is closed under the following ideal terms: \begin{align*} t_1(x,y_1,y_2) &= (y_1\rightarrow (y_2\rightarrow x))\rightarrow x,\\ t_2(x,y) &= (y\rightsquigarrow x)\rightsquigarrow x,\\ t_3(y) &= y\rightarrow 1. \end{align*} \end{enumerate} \end{prop} \begin{proof} (1) $\Rightarrow$ (2). If $F\in\fil{A}$, then $F=[1]_\theta$ for some $\theta\in\conq{PBCI} A$, hence $F$ is closed under all ideal terms. (2) $\Rightarrow$ (3). Trivial. (3) $\Rightarrow$ (1). Suppose that $1\in F$ and that $F$ is closed under the three ideal terms. If $a,a\rightarrow b\in F$, then $b=1\rightarrow b=((a\rightarrow b)\rightarrow (a\rightarrow b))\rightarrow b = t_1 (b,a\rightarrow b,a)\in F$ and also $a\rightarrow 1 = t_3 (a)\in F$. Moreover, for any $a\in A$ and $b\in F$ we have $(b\rightarrow a)\rightarrow a=(1\rightarrow (b\rightarrow a))\rightarrow a=t_1(a,1,b)\in F$ and $(b\rightsquigarrow a)\rightsquigarrow a=t_2(a,b)\in F$. Hence $F\in\fil A$. \end{proof} Instead of $t_1(x,y_1,y_2)$ and $t_2(x,y)$ we could take the ideal term \[ w(x_1,x_2,y_1,y_2)=([(y_1\rightarrow (y_2\rightarrow x_1))\rightarrow x_1]\rightsquigarrow x_2)\rightsquigarrow x_2. \] \begin{cor} The quasivarieties $\var{PBCK}$ and $\var{PBCI}$ are relatively ideal determined. \end{cor} By \cite[Corollary 1.5]{GU}, congruence lattices of algebras in ideal determined varieties are arguesian, and hence modular. For relatively ideal determined quasivarieties we have the following analogue. For the reader's convenience we give a proof which, however, is but a reformulation of the proof of \cite[Lemma 2.1]{Jo53} (also see \cite[Theorem IV.4.10]{gratzer}). Let us recall that a lattice is said to be \emph{arguesian} if it satisfies the identity \[ (x_1\vee y_1) \wedge (x_2\vee y_2) \wedge (x_3\vee y_3) \leq (x_1 \wedge (x_2\vee z)) \vee (y_1 \wedge (y_2\vee z)), \] where $z=z_{12} \wedge (z_{13} \vee z_{23})$ and $z_{ij}=(x_i\vee x_j) \wedge (y_i\vee y_j)$ for $i<j$. An arguesian lattice is a fortiori modular; see \cite[pp. 260--261]{gratzer}. \begin{prop}\label{rid-rcm} Let $\var Q$ be a relatively ideal determined quasivariety. \begin{enumerate}[\indent\upshape (1)] \item For every $\alg A\in\var Q$, $\bconq QA$ is an arguesian lattice. Hence $\var Q$ is relatively congruence modular. \item If there is a binary term $s(x,y)$ in the language of $\var Q$ such that $\var Q$ satisfies the identities $s(x,1) = x$ and $s(x,x) = 1 = s(1,x)$, then $\var Q$ is relatively congruence distributive. \end{enumerate} \end{prop} \begin{proof} Let $\alg A$ be a fixed algebra in a relatively ideal determined quasivariety $\var Q$ with a constant $1$. First, we observe that for any $\phi, \psi\in \conq Q A$ and $a\in A$ we have \begin{equation}\label{spojeniidealu} (a,1)\in\phi\vee\psi \quad\text{iff}\quad (a,1)\in\phi\circ\psi \quad\text{iff}\quad (a,1)\in\psi\circ\phi, \end{equation} whence the join of the $\var Q$-ideals $[1]_\phi$ and $[1]_\psi$ in the $\var Q$-ideal lattice $\bidq Q A$ is $[1]_\phi \vee [1]_\psi = \{a\in A\mid (a,1)\in \phi\circ\psi\} = \{a\in A\mid (a,1)\in\psi\circ\phi\}$. This is basically \cite[Lemma 1.4]{GU} rephrased for relatively ideal determined classes (only ideal determined classes are considered in \cite{GU}). Since $[1]_{\phi}\vee [1]_{\psi} = [1]_{\phi\vee\psi}$ is the $\var Q$-ideal generated by $[1]_{\phi} \cup [1]_{\psi}$, we have $(a,1)\in\phi\vee\psi$ iff there is a $\var Q$-ideal term $t(x_1,\dots,x_m,y_1,\dots,y_n)$ in $y_1,\dots,y_n$ and elements $a_1,\dots,a_m\in A$, $b_1,\dots,b_n\in [1]_\phi\cup [1]_\psi$ such that $a = t(a_1,\dots,a_m,b_1,\dots,b_n)$. For each $i = 1,\dots,n$, let $c_i = 1$ if $(b_i,1)\in\phi$, and $c_i = b_i$ otherwise. Then \[ a=t(a_1,\dots,a_m,b_1,\dots,b_n) \equiv_\phi t(a_1,\dots,a_m,c_1,\dots,c_n) \] since $(b_i,c_i)\in \phi$ for all $i$, and \[ t(a_1,\dots,a_m,c_1,\dots,c_n) \equiv_\psi t(a_1,\dots,a_m,1,\dots,1) = 1 \] since $(c_i,1)\in\psi$ for all $i$, whence $(a,1)\in \phi\circ\psi$. The opposite direction is clear as $\phi\circ\psi\subseteq\phi\vee\psi$. This completes the proof of \eqref{spojeniidealu}. (1) To prove that $\bconq QA \cong \bidq QA$ is an arguesian lattice, we take $\phi_i,\psi_i\in\conq QA$, for $i=1,2,3$, and put \[ \theta = \theta_{12} \cap (\theta_{13} \vee \theta_{23}), \] where \[ \theta_{ij}=(\phi_i \vee \phi_j) \cap (\psi_i \vee \psi_j) \] for $i<j$. Suppose that $(a,1)\in (\phi_1 \vee \psi_1) \cap (\phi_2 \vee \psi_2) \cap (\phi_3 \vee \psi_3)$. By \eqref{spojeniidealu} there exist $b_i\in A$ such that $(a,b_i)\in\phi_i$ and $(b_i,1)\in\psi_i$ for $i=1,2,3$. Obviously, $(b_i,b_j)\in (\phi_i\circ\phi_j) \cap (\psi_i\circ\psi_j)\subseteq \theta_{ij}$. Then $(b_1,b_2)\in \theta_{12} \cap (\theta_{13}\circ \theta_{23}) \subseteq \theta$. Moreover, $(a,b_1)\in \phi_1 \cap (\phi_2\circ\theta)$ since $(a,b_2)\in\phi_2$ and $(b_2,b_1)\in\theta$, and $(b_1,1)\in \psi_1\cap (\theta\circ\psi_2)$ since $(b_2,1)\in\psi_2$ and $(b_1,b_2)\in\theta$. Hence $(a,1)\in (\phi_1 \cap (\phi_2\circ\theta)) \circ (\psi_1 \cap (\theta\circ\psi_2)) \subseteq (\phi_1 \cap (\phi_2\vee\theta))\vee (\psi_1 \cap (\psi_2\vee\theta))$. Recalling \eqref{spojeniidealu} we see that the lattice $\bidq QA$ is arguesian. (2) Let $\phi,\chi,\psi\in\conq{Q}{A}$ and $(a,1)\in \phi \cap (\chi\vee\psi)$. By \eqref{spojeniidealu} there exists $b\in A$ such that $(a,b)\in\chi$ and $(b,1)\in\psi$. Let $c=s(a,s(s(a,b),b))$. Since $\var{Q}$ satisfies the identities $s(x,1) = x$ and $s(x,x) = 1 = s(1,x)$, we have \[ c \equiv_\phi s(1,s(s(1,b),b)) = 1,\quad c \equiv_\chi s(a,s(s(a,a),a)) = a,\quad c \equiv_\psi s(a,s(s(a,1),1)) = 1. \] Hence $(a,c) \in \phi\cap\chi$ and $(c,1) \in \phi\cap\psi$, and so $(a,1)\in (\phi\cap\chi)\circ (\phi\cap\psi) \subseteq (\phi\cap\chi)\vee (\phi\cap\psi)$. \end{proof} The statement (2) is a corollary of \cite[Corollary 12.2.5]{BR08} which says that a relatively $1$-regular quasivariety $\var Q$ is relatively congruence distributive if there is a binary term $s(x,y)$ such that $\var Q$ satisfies the identities of (2). In the case of $\var{PBCK}$ it suffices to take $s(x,y)=y\rightarrow x$. \begin{cor} The relative congruence lattice of any pseudo-BCI-algebra {\upshape(}resp. pseudo-BCK-algebra{\upshape)} is arguesian {\upshape(}resp. distributive{\upshape)}. Thus $\var{PBCI}$ {\upshape(}resp. $\var{PBCK}${\upshape)} is relatively congruence modular {\upshape(}resp. distributive{\upshape)}. \end{cor} For an alternative proof of relative congruence distributivity of pseudo-BCK-algebras, see \cite[Corollary 2.1.12 and 2.2.9]{JK-hab} or \cite{HK}. By \cite[Corollary 1.9]{GU}, a $1$-regular variety $\var V$ is ideal determined if and only if there exists a binary term $s(x,y)$ such that $\var V$ satisfies the identities \[ s(x,x) = 1 \quad\text{and}\quad s(x,1) = x; \] cf. Proposition \ref{rid-rcm} (2). Such a term is called a \emph{subtractive term} for $\var V$. Unfortunately, a relatively $1$-regular quasivariety having a subtractive term may not be relatively ideal determined. For example (cf. \cite[Example 7.7]{BR99} or \cite[Example 4.7.5]{BR08}), if $\var Q$ is the quasivariety of all torsion-free abelian groups, then the additive group of integers $\mathbb{Z}$ belongs to $\var Q$ and the only $\var Q$-congruences of $\mathbb{Z}$ are $\Delta$ and $\nabla$. But the $\var Q$-ideals of $\mathbb{Z}$ are precisely the subgroups of $\mathbb{Z}$, hence $\var Q$ is not relatively ideal determined, though it is relatively $0$-regular and satisfies the identities $x = x-0$ and $x-x = 0$, i.e., $s(x,y)=x-y$ is a subtractive term for $\var Q$. It was proved in \cite[Theorem 12.2.6]{BR08} that a relatively $1$-regular quasivariety $\var Q$ is relatively congruence modular whenever it is \emph{$1$-conservative}, in the sense that $\var Q$ and the variety $\mathrm{HSP}(\var Q)$ generated by $\var Q$ satisfy the same quasi-identities of the form \[\textstyle \bigwedge_{i=1}^{n} s_i(x_1,\dots,x_k) = 1 \quad\Rightarrow\quad t(x_1,\dots,x_k) = 1. \] Conservativeness has some notable consequences (see \cite[Corollary 12.1.2]{BR08}); for instance, relatively (finitely) subdirectly irreducible algebras in $\var Q$ are (finitely) subdirectly irreducible in the absolute sense. That $\var{PBCK}$ has this property was proved in \cite[Corollary 3.6]{vA06}. \begin{prop} Let $\var Q$ be a relatively $1$-regular quasivariety. Then $\var Q$ is relatively ideal determined if and only if $\var Q$ is $1$-conservative and has a subtractive term. \end{prop} \begin{proof} This follows from \cite[Corollary 14.3.5]{BR08}; in fact, the statement is \cite[Corollary 14.3.5]{BR08} particularized to relatively $1$-regular quasivarieties. Conservativeness of $\var Q$ could be established directly, using ideal terms and \eqref{spojeniidealu}. Also, it follows from \cite[Proposition 7.2]{BR99} that a relatively ideal determined quasivariety has a subtractive term. Here, we give a straightforward proof based on the satisfaction of \eqref{spojeniidealu}. For any $\alg A\in\var Q$ and $\rho\subseteq A^2$, $\mathrm{Cg}_{\var Q}(\rho)$ denotes the $\var Q$-congruence of $\alg A$ generated by $\rho$. Let $\alg F$ be the $\var Q$-free algebra $\alg{F}_{\var Q}(x,y)$; then $\alg F\in\var Q$. Clearly, $(x,1) \in \mathrm{Cg}_{\var Q}(x,y) \circ \mathrm{Cg}_{\var Q}(y,1)$, and hence also $(x,1) \in \mathrm{Cg}_{\var Q}(y,1) \circ \mathrm{Cg}_{\var Q}(x,y)$ by \eqref{spojeniidealu}. Thus there exists $s(x,y)\in\alg F$ such that $(x,s(x,y)) \in \mathrm{Cg}_{\var Q}(y,1)$ and $(s(x,y),1) \in \mathrm{Cg}_{\var Q}(x,y)$. Let $\alg A$ be an arbitrary algebra in $\var Q$. For any $a\in A$, the assignment $x\mapsto a$, $y\mapsto 1$ determines a unique homomorphism $\eta$ from $\alg F$ to $\alg A$. The kernel congruence of $\eta$ is a $\var Q$-congruence of $\alg F$, hence $\mathrm{Cg}_{\var Q}(y,1)\subseteq\ker\eta$. But then $a=\eta(x)=\eta(s(x,y))=s(\eta(x),\eta(y))=s(a,1)$. This proves that $\var Q$ satisfies $x = s(x,1)$. The argument for the identity $s(x,x)= 1$ is similar. \end{proof} \begin{cor} The quasivarieties $\var{PBCK}$ and $\var{PBCI}$ are $1$-conservative. \end{cor} In conclusion, we return to pseudo-BCI-algebras. Let $\alg A$ be a pseudo-BCI-algebra. Dymek \cite{D14} described the ``deductive system'' generated by $\emptyset\neq S\subseteq A$; our goal is to describe the prefilter $\mathrm{Pg}(S)$ generated by a given non-empty subset $S$, with an intent to prove that $\bfil A$ is a sublattice of $\bpfil A$. Recall that $a_1\dots a_n\rightarrow x$ and $a_1\dots a_n\rightsquigarrow x$ are shorthands for $a_1\rightarrow (\dots \rightarrow (a_n\rightarrow x)\dots)$ and $a_n\rightsquigarrow (\dots \rightsquigarrow (a_1\rightsquigarrow x)\dots)$, respectively. \begin{lem}\label{L6} Let $\alg{A}$ be a pseudo-BCI-algebra. For any $\emptyset\neq S\subseteq A$ one has \[ \mathrm{Pg}(S) = \{x\in A\mid a_1\dots a_n\rightarrow x=1 \text{ for some } a_1,\dots,a_n\in S\cup (S\rightarrow 1), n\in\mathbb{N}\} \] where $S\rightarrow 1=\{x\rightarrow 1\mid x\in S\}$. \end{lem} \begin{proof} Let $M$ be the set above, i.e., $x\in M$ iff $\alpha\rightarrow x=1$ (or equivalently, $\alpha\rightsquigarrow x=1$) for some $\alpha=a_1\dots a_n$ with $a_1,\dots,a_n\in S\cup (S\rightarrow 1)$. (i) For any $a\in S$, we have $(a\rightarrow 1)\rightarrow (a\rightarrow 1)=1$, so $1\in M$. (ii) Let $x,x\rightarrow y\in M$, i.e., $\alpha\rightsquigarrow (x\rightarrow y)=1$ and $\beta\rightsquigarrow x=1$ for some non-empty words $\alpha,\beta$ over $S\cup (S\rightarrow 1)$. By Lemma \ref{L1}, $x\rightarrow (\alpha\rightsquigarrow y)=\alpha\rightsquigarrow (x\rightarrow y)=1$, so $x\leq \alpha\rightsquigarrow y$ which yields $1=\beta\rightsquigarrow x \leq \beta\rightsquigarrow (\alpha \rightsquigarrow y)=\alpha\beta\rightsquigarrow y$. Hence $\alpha\beta\rightsquigarrow y=1$ and $y\in M$. (iii) Let $x\in M$, i.e., $a_1\dots a_n\rightarrow x=1$ for some $a_1,\dots,a_n\in S\cup (S\rightarrow 1)$. Then, using Lemma \ref{L1} \eqref{vl11}, we have \begin{align*} 1 & =(a_1\dots a_n\rightarrow x)\rightarrow 1\\ & = [a_1\rightarrow (\dots\rightarrow (a_n\rightarrow x)\dots)]\rightarrow 1\\ & =(a_1\rightarrow 1)\rightsquigarrow (\dots\rightsquigarrow [(a_n\ra1 )\rightsquigarrow (x\rightarrow 1)]\dots). \end{align*} If $a_i\in S$, then $a_i\rightarrow 1\in S\cup (S\rightarrow 1)$. On the other hand, if $a_i\in S\rightarrow 1$, then $a_i = b_i\rightarrow 1$ for some $b_i \in S$, and since $b_i\leq (b_i\rightarrow 1)\rightarrow 1=a_i\rightarrow 1$, when replacing $a_i\rightarrow 1$ with $b_i$ we get \begin{align*} 1 & = (a_1\rightarrow 1)\rightsquigarrow (\dots\rightsquigarrow [(a_i\rightarrow 1)\rightsquigarrow (\dots\rightsquigarrow [(a_n\rightarrow 1)\rightsquigarrow (x\rightarrow 1)]\dots)]\dots)\\ & \leq (a_1\rightarrow 1)\rightsquigarrow (\dots\rightsquigarrow [b_i\rightsquigarrow (\dots\rightsquigarrow [(a_n\rightarrow 1)\rightsquigarrow (x\rightarrow 1)]\dots)]\dots) \end{align*} by Lemma \ref{L1} \eqref{vl5}, \eqref{vl9}. Repeating this procedure for each $i=1,\dots,n$ we find $c_1,\dots c_n\in S\cup (S\rightarrow 1)$ such that $c_1\rightsquigarrow (\dots\rightsquigarrow (c_n\rightsquigarrow (x\rightarrow 1))\dots) = 1$, thus $x\rightarrow 1\in M$. We have proved that $M\in \pfil A$. Clearly, $S\subseteq M$. If $P\in\pfil A$ is such that $S\subseteq P$, then also $S\rightarrow 1\subseteq P$ and it follows that $M\subseteq P$. Thus $M=\mathrm{Pg}(S)$. \end{proof} \begin{rem} We know that $I_{\alg A}$ is a filter of $\alg A$; in fact, $I_{\alg A}$ is the kernel of the homomorphisms $\gamma$ and $\delta$ that are defined by \eqref{gamma} and \eqref{delta}, respectively. However, $G_{\alg A}$ is neither a filter nor a prefilter of $\alg A$ in general. Consequently, though $\alg{G}_{\alg A}$ is a subalgebra the prefilters of which are precisely the subgroups of the group $(G_{\alg A},\cdot,1)$, the prefilter of $\alg A$ generated by a subgroup $S\subseteq G_{\alg A}$ need not be contained in $G_{\alg A}$. \end{rem} \begin{cor} For any pseudo-BCI-algebra $\alg A$, the filter lattice $\bfil A$ is a complete sublattice of the prefilter lattice $\bpfil A$. \end{cor} \begin{proof} Let $\phi,\psi \in \conq{PBCI}{A}$. Let $\vee$ and $\sqcup$ denote the join in $\bfil A$ and in $\bpfil A$, respectively. By \eqref{spojeniidealu}, if $a\in [1]_\phi \vee [1]_\psi$, then $(a,1)\in\phi\circ\psi$, so there exists $b\in A$ such that $(a,b)\in\phi$ and $(b,1)\in\psi$. Then $b\rightarrow a\in [1]_\phi$, $b\in [1]_\psi$, and since $b\rightarrow ((b\rightarrow a)\rightsquigarrow a)=1$, it follows that $a\in \mathrm{Pg} ([1]_\phi \cup [1]_\psi) = [1]_\phi \sqcup [1]_\psi$. Thus $[1]_\phi \vee [1]_\psi\subseteq [1]_\phi \sqcup [1]_\psi$; the converse inclusion is evident, and hence $\bfil A$ is a sublattice of $\bpfil A$. Compactness entails that it is actually a complete sublattice. \end{proof} \section{The direct product of $\alg{I}_{\alg A}$ and $\alg{G}_{\alg A}$} \label{sect-direktnisoucin} In this section, we generalize another result of \cite{RvA}; namely, we characterize pseudo-BCI-algebras $\alg A$ that are isomorphic to the direct product $\alg I_{\alg A} \times \alg G_{\alg A}$. The necessary and sufficient condition given in \cite[Theorem 20]{RvA} is associativity of the operation which is defined by the same rule as the group multiplication on $G_{\alg A}$. When $\alg{A}$ is a proper pseudo-BCI-algebra, then for $x,y\in G_{\alg A}$ we have \begin{align*} x\cdot y &= (x\rightarrow 1)\rightsquigarrow y=(x\rightarrow 1)\rightsquigarrow ((y\rightsquigarrow 1)\rightarrow 1)\\ &= (y\rightsquigarrow 1)\rightarrow ((x\rightarrow 1)\rightsquigarrow 1)=(y\rightsquigarrow 1)\rightarrow x, \end{align*} but the elements $(x\rightarrow 1)\rightsquigarrow y$ and $(y\rightsquigarrow 1)\rightarrow x$ may be distinct if $x,y\notin G_{\alg A}$. Therefore, for any $x,y\in A$ we define \[ x\cdot y=(x\rightarrow 1)\rightsquigarrow y \quad\text{and}\quad x\star y=(y\rightsquigarrow 1)\rightarrow x. \] The operations $\cdot$ and $\star$ need not coincide even when $\alg A$ is a BCI-algebra, but in BCI-algebras we have $x\cdot y=y\star x$ for all $x,y\in A$, which fails to be true in pseudo-BCI-algebras. \begin{lem}\label{L3} In any pseudo-BCI-algebra $\alg{A}$, for all $x,y,z\in A$: \begin{enumerate}[\indent\upshape (1)] \item $1\cdot x = x = x\star 1$; \item $x\cdot ( x\rightarrow 1) = 1 = (x\rightsquigarrow 1)\star x$; \item $x\cdot (y\star z) = (x\cdot y)\star z$; \item $(x\cdot y)\cdot z \leq x\cdot (y\cdot z)$; \item $x\star (y\star z) \leq (x\star y)\star z$. \end{enumerate} \end{lem} \begin{proof} (1) and (2) are trivial calculations. Also (3) is obvious because by Lemma \ref{L1} (6) we have $x\cdot (y\star z) = (x\ra1)\rightsquigarrow((z\rs1)\rightarrow y) = (z\rs1)\rightarrow((x\ra1)\rightsquigarrow y) = (x\cdot y)\star z$. For (4), we have \begin{align*} x\rightarrow 1 &\leq ((x\rightarrow 1)\rightsquigarrow y)\rightarrow y && \text{by Lemma \ref{L1} \eqref{vl3}}\\ &\leq (y\rightarrow 1)\rightsquigarrow (((x\rightarrow 1)\rightsquigarrow y)\rightarrow 1) && \text{by Lemma \ref{L1} \eqref{vl2}}\\ &\leq [(((x\rightarrow 1)\rightsquigarrow y)\rightarrow 1)\rightsquigarrow z]\rightarrow ((y\rightarrow 1)\rightsquigarrow z) && \text{by Lemma \ref{L1} \eqref{vl2}}\\ &=((x\cdot y)\cdot z)\rightarrow (y\cdot z) \end{align*} which is equivalent to $(x\cdot y)\cdot z \leq (x\ra1)\rightsquigarrow (y\cdot z) = x\cdot (y\cdot z)$ by Lemma \ref{L1} \eqref{vl7}. The proof of (5) is analogous. \end{proof} \begin{rem} If $x\cdot y=x\star y$ for all $x,y\in A$, then $(x\rightarrow 1)\rightsquigarrow 1=x\cdot 1=x\star 1=x$ for every $x\in A$, and so $x\in G_{\alg A}$. Thus the operations $\cdot$ and $\star$ coincide if and only if $G_{\alg A}=A$. The identity $x\star (y\cdot z)=(x\star y)\cdot z$ obtained by switching $\cdot$ and $\star$ in (3) does not hold true in general; it actually entails that $\cdot$ and $\star$ coincide because $x\star z=x\star (1\cdot z)=(x\star 1)\cdot z=x\cdot z$ for all $x,z\in A$. \end{rem} \begin{rem} The operations $\cdot$ and $\rightarrow$ (or $\star$ and $\rightsquigarrow$) do not satisfy the residuation law \eqref{rl} in general. It is easy to show that $x\cdot y\leq z$ implies $x\leq y\rightarrow z$ (and $x\star y\leq z$ implies $y\leq x\rightsquigarrow z$), but the converse implication holds only if $G_{\alg A}=A$. Indeed, assuming that $x\cdot y\leq z$ iff $x\leq y\rightarrow z$ for all $x,y,z\in A$, we see that for any $x\in A$, $x=1\rightarrow x$ entails $x\leq (x\rightarrow 1)\rightsquigarrow 1=x\cdot 1\leq x$, thus $x\in G_{\alg A}$. \end{rem} \begin{lem}\label{lemJ1} For any pseudo-BCI-algebra $\alg{A}$, the following are equivalent: \begin{enumerate}[\indent\upshape (1)] \item the operation $\cdot$ is associative; \item $(g\cdot h)\cdot x=g\cdot (h\cdot x)$ for all $g,h\in G_{\alg A}$ and $x\in A$; \item $g^{-1} \rightsquigarrow (g\rightsquigarrow x)=x$ for all $g\in G_{\alg A}$ and $x\in A$; \item the operation $\star$ is associative; \item $x\star (h\star g)=(x\star h)\star g$ for all $g,h\in G_{\alg A}$ and $x\in A$; \item $g^{-1} \rightarrow (g\rightarrow x)=x$ for all $g\in G_{\alg A}$ and $x\in A$. \end{enumerate} \end{lem} \begin{proof} (1) $\Rightarrow$ (2). Trivial. (2) $\Rightarrow$ (3). Since $g\cdot g^{-1}=1$, we have $x = 1\cdot x = (g\cdot g^{-1})\cdot x = g\cdot (g^{-1}\cdot x) = (g\rightarrow 1)\rightsquigarrow ((g^{-1}\rightarrow 1)\rightsquigarrow x) = g^{-1} \rightsquigarrow (g\rightsquigarrow x)$. (3) $\Rightarrow$ (1). We first note that $x\rightarrow 1=((x\rightarrow 1)\rightsquigarrow y)\rightarrow y$ for all $x,y\in A$, because $x\rightarrow 1\leq ((x\rightarrow 1)\rightsquigarrow y)\rightarrow y$ and $x\rightarrow 1\in G_{\alg A}$ is a maximal element. Then \begin{align} \begin{split}\label{slbguign346} x\rightarrow (y\rightarrow 1) &=x\rightarrow (y\rightsquigarrow 1)=y\rightsquigarrow (x\rightarrow 1)= y\rightsquigarrow [((x\rightarrow 1)\rightsquigarrow y)\rightarrow y]\\ &=((x\rightarrow 1)\rightsquigarrow y)\rightarrow (y\rightsquigarrow y)=((x\rightarrow 1)\rightsquigarrow y)\rightarrow 1\\ &=(x\cdot y)\rightarrow 1. \end{split} \end{align} Further, since $y\rightarrow 1\in G_{\alg A}$ and $(y\rightarrow 1)^{-1}\rightsquigarrow ((y\rightarrow 1)\rightsquigarrow z)=z$ by (3), we have \begin{alignat*}{2} x\cdot (y\cdot z) &= (x\rightarrow 1)\rightsquigarrow ((y\rightarrow 1)\rightsquigarrow z)\\ &\leq [(y\rightarrow 1)^{-1}\rightsquigarrow (x\rightarrow 1)]\rightsquigarrow [(y\rightarrow 1)^{-1}\rightsquigarrow ((y\rightarrow 1)\rightsquigarrow z)] & \hspace{3mm} & \text{by Lem. \ref{L1} (8)}\\ &=[x\rightarrow ((y\rightarrow 1)^{-1}\rightsquigarrow 1)]\rightsquigarrow z\\ &=(x\rightarrow (y\rightarrow 1))\rightsquigarrow z\\ &=((x\cdot y)\rightarrow 1)\rightsquigarrow z && \text{by \eqref{slbguign346}}\\ &=(x\cdot y)\cdot z. \end{alignat*} The converse inequality holds by Lemma \ref{L3} (4), and hence $x\cdot (y\cdot z)=(x\cdot y)\cdot z$. The proof of (4) $\Leftrightarrow$ (5) $\Leftrightarrow$ (6) is parallel to the above proof of (1) $\Leftrightarrow$ (2) $\Leftrightarrow$ (3), hence it remains to show that, e.g., (3) $\Leftrightarrow$ (6). For any $x,y,z\in A$, \[ y\leq (y\rightarrow (x\rightarrow z))\rightsquigarrow (x\rightarrow z)=x\rightarrow [(y\rightarrow (x\rightarrow z))\rightsquigarrow z] \] implies $x\leq y\rightsquigarrow [(y\rightarrow (x\rightarrow z))\rightsquigarrow z]$ (by Lemma \ref{L1} \eqref{vl3}, \eqref{vl6} and \eqref{vl7}), and hence \[ x\rightsquigarrow (y\rightsquigarrow [(y\rightarrow (x\rightarrow z))\rightsquigarrow z])=1. \] In particular, for any $g\in G_{\alg A}$ and $x\in A$, $g\rightsquigarrow (g^{-1}\rightsquigarrow [(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x])=1$. But if $\alg{A}$ fulfills (3), then we also have \[ g\rightsquigarrow (g^{-1}\rightsquigarrow [(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x])=(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x, \] so $(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x=1$ which proves $g^{-1}\rightarrow (g\rightarrow x)\leq x$. The converse inequality is clear: $x=1\rightarrow x\leq (g\rightarrow 1)\rightarrow (g\rightarrow x)=g^{-1}\rightarrow (g\rightarrow x)$. Thus $\alg{A}$ satisfies (6) whenever it satisfies (3). To prove the converse implication, it suffices to switch the arrows. \end{proof} Theorem \ref{thm-direktnirozklad} below generalizes \cite[Theorem 20]{RvA} which states that a BCI-algebra $\alg{A}$ is isomorphic to the direct product $\alg{I}_{\alg A} \times \alg{G}_{\alg A}$ if and only if the operation $\star$ is associative. Obviously, if $\alg{A}$ is a BCI-algebra, then $\alg{I}_{\alg A}$ is a BCK-algebra, $\alg{G}_{\alg A}=\alg{G}_{\alg A}^{\dagger}$ and $x\cdot y=y\star x$ for all $x,y\in A$, so the group $(G_{\alg A},\cdot,1)$ is abelian. First an easy lemma that will be used in proving the theorem: \begin{lem}\label{L4} Let $\alg{A}$ be a pseudo-BCI-algebra. Then for all $x\in A$ and $g, h\in G_{\alg A}$: \begin{enumerate}[\indent\upshape (1)] \item $x\rightarrow g = (g\rightarrow x)\rightarrow 1$, $x\rightsquigarrow g = (g\rightsquigarrow x)\rightarrow 1$; \item $g\rightarrow x = x \star g^{-1}$, $g \rightsquigarrow x = g^{-1}\cdot x$; \item $(x\rightarrow g)\rightarrow 1=x\cdot g^{-1}$, $(x\rightsquigarrow g)\rightarrow 1=g^{-1}\star x$. \end{enumerate} \end{lem} \begin{proof} We have $(g\rightarrow x)\rightarrow 1 = (g\rightarrow 1) \rightsquigarrow (x\rightarrow 1) = x \rightarrow ((g\rightarrow 1)\rightsquigarrow 1) = x\rightarrow g$, and similarly, $(g\rightsquigarrow x)\rightarrow 1 = x\rightsquigarrow g$. Clearly, $x\star g^{-1} = (g^{-1}\rightsquigarrow 1)\rightarrow x = g\rightarrow x$, $g^{-1}\cdot x =(g^{-1}\rightarrow 1)\rightsquigarrow x = g\rightsquigarrow x$, $x\cdot g^{-1}=(x\rightarrow 1)\rightsquigarrow (g\rightarrow 1)=(x\rightarrow g)\rightarrow 1$ and $g^{-1}\star x=(x\rightsquigarrow 1)\rightarrow (g\rightsquigarrow 1)=(x\rightsquigarrow g)\rightarrow 1$. \end{proof} \begin{thm}\label{thm-direktnirozklad} Let $\alg A$ be a pseudo-BCI-algebra. The following statements are equivalent: \begin{enumerate}[\indent\upshape (1)] \item $\alg A \cong \alg{I_A} \times \alg{G_A} \cong \alg{I_A} \times \alg{G}_{\alg{A}}^{\dagger}$; \item $G_{\alg A}$ is a filter of $\alg A$; \item $\alg A$ satisfies the equivalent conditions of Lemma \ref{lemJ1} and \begin{equation}\label{123456} g\rightarrow x=g\rightsquigarrow x \end{equation} for all $g\in G_{\alg A}$, $x\in I_{\alg A}$. \end{enumerate} \end{thm} \begin{rem} Dymek \cite{D15} recently proved that $\alg A \cong \alg{I_A} \times \alg{G_A}$ if and only if $G_{\alg A}$ is a ``compatible deductive system'' of $\alg A$ (i.e., $G_{\alg A}$ satisfies the conditions (i), (ii) and (iv)), which is actually equivalent to $G_{\alg A}$ being a filter because $G_{\alg A}$ always satisfies the condition (iii). Our proof below is different from that in \cite{D15}. \end{rem} \begin{proof}[Proof of the theorem] (1) $\Rightarrow$ (2). Let $\alg B$ be the direct product $\alg{I_A}\times\alg{G_A}$. We have $\alg{I_A} \times \alg{G_A} \cong \alg{I_A} \times \alg{G}_{\alg{A}}^{\dagger}$. In view of Lemma \ref{lem-grcast}, the group part of $\alg B$ is $G_{\alg B}=\{(1,g)\mid g\in G_{\alg A}\}$ and any isomorphism $\eta$ between $\alg A$ and $\alg B$ maps $G_{\alg A}$ onto $G_{\alg B}$. Hence, if $\pi$ is the projection of $\alg B$ onto $\alg{I_A}$, then $G_{\alg A}$ is the kernel of the composite homomorphism $\pi\eta$ from $\alg A$ onto $\alg{I_A}$. Thus $G_{\alg A}\in\fil A$. (2) $\Rightarrow$ (3). Suppose that $G_{\alg A}$ is a filter of $\alg A$. Let $g\in G_{\alg A}$. First, we show that $\alg A$ satisfies the condition (6) of Lemma \ref{lemJ1}. For any $x\in A$ we have $x=1\rightarrow x\leq (g\rightarrow 1)\rightarrow (g\rightarrow x)=g^{-1}\rightarrow (g\rightarrow x)$, whence $1=x\rightsquigarrow x\geq (g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x$. On the other hand, recalling Lemma \ref{L1} \eqref{vl3}, we get $g^{-1}\leq (g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow (g\rightarrow x)=g\rightarrow [(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x]$; since $g^{-1}$ is a maximal element, we actually have $g^{-1}=g\rightarrow [(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x]$. Now, since both $g$ and $g^{-1}$ belong to the filter $G_{\alg A}$, it follows that $(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x\in G_{\alg A}$. But we have seen before that this element is $\leq 1$, and so $(g^{-1}\rightarrow (g\rightarrow x))\rightsquigarrow x=1$. Thus $g^{-1}\rightarrow (g\rightarrow x)\leq x$. To verify \eqref{123456}, suppose that $x\in I_{\alg A}$. Then $(g\rightarrow x)\rightarrow 1=(g\rightarrow 1)\rightsquigarrow (x\rightarrow 1)=g^{-1}\rightsquigarrow 1=g$, and hence $x\leq 1$ implies $(g\rightarrow x)\rightarrow x\leq (g\rightarrow x)\rightarrow 1=g$. Since the element $g$ is maximal, we have $g=(g\rightarrow x)\rightsquigarrow x\in G_{\alg A}$, whence $(g\rightarrow x)\rightarrow x\in G_{\alg A}$. However, $(g\rightarrow x)\rightarrow x\leq g$, and so $(g\rightarrow x)\rightarrow x=g$ which yields $g\rightarrow x\leq ((g\rightarrow x)\rightarrow x)\rightsquigarrow x=g\rightsquigarrow x$. The proof of the inequality $g\rightsquigarrow x\leq g\rightarrow x$ is parallel. Thus $g\rightarrow x=g\rightsquigarrow x$ for all $g\in G_{\alg A}$ and $x\in I_{\alg A}$. (3) $\Rightarrow$ (1). We prove the map \[ \eta\colon (a,g)\in I_{\alg A}\times G_{\alg A} \mapsto g\rightarrow a\in A \] is an isomorphism from $\alg{I}_{\alg A}\times\alg{G}_{\alg A}^{\dagger}$ onto $\alg{A}$. For any $g,h\in G_{\alg A}$ and $a,b\in I_{\alg A}$ we have \begin{align} \begin{split}\label{6546s4h4gfh64} (g\rightsquigarrow h)\rightsquigarrow b &= (g\rightsquigarrow h)\rightarrow b = b\star (g\rightsquigarrow h)^{-1} = b\star (h^{-1}\star g)= (b\star h^{-1})\star g\\ &= (h\rightarrow b)\star g = g^{-1}\rightarrow (h\rightarrow b) \end{split} \end{align} by \eqref{123456}, Lemma \ref{L4} and by associativity of $\star$. Then, since $g^{-1}\rightarrow (g\rightarrow a)=a$ by Lemma \ref{lemJ1} (6), \begin{align*} (g\rightsquigarrow h)\rightarrow (a\rightarrow b) &= (g\rightsquigarrow h)\rightsquigarrow (a\rightarrow b) = a\rightarrow ((g\rightsquigarrow h)\rightsquigarrow b)\\ &= a\rightarrow (g^{-1}\rightarrow (h\rightarrow b)) = (g^{-1}\rightarrow (g\rightarrow a))\rightarrow (g^{-1}\rightarrow (h\rightarrow b))\\ &\geq (g\rightarrow a)\rightarrow (h\rightarrow b) \end{align*} by Lemma \ref{L1} (8). On the other hand, again using Lemma \ref{lemJ1} (6), Lemma \ref{L1} \eqref{vl8} and \eqref{6546s4h4gfh64}, \begin{align*} (g\rightarrow a)\rightarrow (h\rightarrow b) &= (g\rightarrow a)\rightarrow [g\rightarrow (g^{-1}\rightarrow (h\rightarrow b))]\\ &\geq a\rightarrow (g^{-1}\rightarrow (h\rightarrow b)) = a\rightarrow ((g\rightsquigarrow h)\rightsquigarrow b)\\ &= (g\rightsquigarrow h)\rightsquigarrow (a\rightarrow b) = (g\rightsquigarrow h)\rightarrow (a\rightarrow b). \end{align*} Thus, for all $g,h\in G_{\alg A}$ and $a,b\in I_{\alg A}$ we have \[ (g\rightsquigarrow h)\rightarrow (a\rightarrow b)=(g\rightarrow a)\rightarrow (h\rightarrow b). \] We can analogously show that \[ (g\rightarrow h)\rightsquigarrow (a\rightsquigarrow b)=(g\rightsquigarrow a)\rightsquigarrow (h\rightsquigarrow b). \] Therefore, since $I_{\alg A}\times G_{\alg A}$ is regarded as the universe of the pseudo-BCI-algebra $\alg{I}_{\alg A}\times\alg{G}_{\alg A}^{\dagger}$ (not of $\alg{I}_{\alg A}\times\alg{G}_{\alg A}$), we get $\eta ((a,g)\rightarrow (b,h)) = \eta(a\rightarrow b,g\rightsquigarrow h) = (g\rightsquigarrow h)\rightarrow (a\rightarrow b) = (g\rightarrow a)\rightarrow (h\rightarrow b) = \eta(a,g)\rightarrow\eta(b,h)$ and $\eta ((a,g)\rightsquigarrow (b,h)) = \eta(a\rightsquigarrow b,g\rightarrow h) = (g\rightarrow h)\rightsquigarrow (a\rightsquigarrow b) = (g\rightsquigarrow a)\rightsquigarrow (h\rightsquigarrow b) = \eta(a,g)\rightsquigarrow \eta(b,h)$. Thus $\eta$ is indeed a homomorphism from $\alg{I}_{\alg A}\times\alg{G}_{\alg A}^{\dagger}$ onto $\alg{A}$. It remains to show that $\eta$ is a bijection. Surjectivity: By Lemma \ref{lem-intcast}, $(x\rightarrow 1)^{-1}\rightarrow x\in I_{\alg A}$ for every $x\in A$. Since $x\rightarrow 1\in G_{\alg A}$, by Lemma \ref{lemJ1} (6) we obtain \[ x = (x\rightarrow 1)\rightarrow ((x\rightarrow 1)^{-1}\rightarrow x) = \eta ((x\rightarrow 1)^{-1}\rightarrow x,x\rightarrow 1), \] hence the map $\eta$ is onto. Injectivity: Suppose that $\eta(a,g) = 1$, i.e. $g\rightarrow a = 1$. Then $g\leq a$ which entails $g = a$ as $g$ is a maximal element. Also $a\leq 1$, and hence $g = a = 1$. Thus $\eta^{-1}(1)=\{(1,1)\}$. Since $\eta$ is a homomorphism whose kernel is trivial, we conclude that $\eta$ is injective. \end{proof} The homomorphism $\delta$ defined by \eqref{delta} is a retraction of $\alg A$ onto $\alg{G}_{\alg A}$. By Lemma \ref{lem-grcast} we know that $x\in G_{\alg A}$ iff $x=\delta(x)$. Using this fact and recalling Proposition \ref{prop-idealterms}, we obtain that $G_{\alg A}$ is a filter of $\alg A$ if and only if $\alg A$ satisfies the identities \[ \delta(t_1(x,y_1,y_2)) = t_1(x,\delta(y_1),\delta(y_2)) \quad\text{and}\quad \delta(t_2(x,y)) = t_2(x,\delta(y)), \] where $t_1(x,y_1,y_2)$ and $t_2(x,y)$ are the ideal terms of Proposition \ref{prop-idealterms}. Analogously, by Lemma \ref{lem-intcast} we have $\delta(x)\rightarrow x\in I_{\alg A}$ for every $x\in A$, whence $x\in I_{\alg A}$ iff $x=\delta(x)\rightarrow x$, and hence the condition \eqref{123456} can be captured by the identity \[ \delta(y)\rightarrow (\delta(x)\rightarrow x) = \delta(y)\rightsquigarrow (\delta(x)\rightarrow x). \] Therefore: \begin{cor} The class of pseudo-BCI-algebras $\alg A$ isomorphic to $\alg{I}_{\alg A}\times\alg{G}_{\alg A}$ is a relative subvariety of the quasivariety $\var{PBCI}$. \end{cor} The condition \eqref{123456}, which is obviously redundant in the case of BCI-algebras, cannot be omitted. The following example (found by Prover9-Mace4) shows that there exist pseudo-BCI-algebras satisfying the conditions (1)--(6) of Lemma \ref{lemJ1} but not \eqref{123456}. \begin{exa} Let $\alg A$ be the pseudo-BCI-algebra defined by the tables \begin{center} \begin{tabular}{c|cccccc} $\rightarrow$ & $a$ & $b$ & $x$ & $y$ & $g$ & $1$\\ \hline $a$ & $1$ & $b$ & $g$ & $y$ & $g$ & $1$\\ $b$ & $a$ & $1$ & $x$ & $g$ & $g$ & $1$\\ $x$ & $g$ & $x$ & $1$ & $a$ & $1$ & $g$\\ $y$ & $y$ & $g$ & $b$ & $1$ & $1$ & $g$\\ $g$ & $y$ & $x$ & $b$ & $a$ & $1$ & $g$\\ $1$ & $a$ & $b$ & $x$ & $y$ & $g$ & $1$ \end{tabular} \qquad \begin{tabular}{c|cccccc} $\rightsquigarrow$ & $a$ & $b$ & $x$ & $y$ & $g$ & $1$\\ \hline $a$ & $1$ & $b$ & $x$ & $g$ & $g$ & $1$\\ $b$ & $a$ & $1$ & $g$ & $y$ & $g$ & $1$\\ $x$ & $x$ & $g$ & $1$ & $b$ & $1$ & $g$\\ $y$ & $g$ & $y$ & $a$ & $1$ & $1$ & $g$\\ $g$ & $x$ & $y$ & $a$ & $b$ & $1$ & $g$\\ $1$ & $a$ & $b$ & $x$ & $y$ & $g$ & $1$ \end{tabular} \end{center} Then $I_{\alg A}=\{a,b,1\}$, $G_{\alg A}=\{g,1\}$ and $\alg A$ satisfies the equivalent conditions of Lemma \ref{lemJ1}, but, e.g., $g\rightarrow a=y$ while $g\rightsquigarrow a=x$. Hence $\alg A$ is not isomorphic to $\alg{I_A}\times\alg{G_A}$, which is evident also from the fact that $\alg{I}_{\alg A}$ and $\alg{G}_{\alg A}$ are BCI-algebras, but $\alg A$ is a proper pseudo-BCI-algebra. \end{exa} \section*{Acknowledgements} The authors would like to thank the referees for their comments and suggestions. Both P. E. and J. K. were supported by the Palack\'{y} University project ``Mathematical structures'' IGA PrF 2015010. J. K. was also supported by the bilateral project ``New perspectives on residuated posets'' of the Austrian Science Fund (FWF): project I 1923-N25, and the Czech Science Foundation (GA\v{C}R): project 15-34697L. \nocite{*} \bibliographystyle{amsplain}
\section{Introduction}The \emph{symmetric exclusion process} $\mathrm{EX}(k) $ on a finite, connected graph $G= (V, E)$ (with vertex set $V$ and edge set $E$) is the following continuous-time Markov process. In a configuration, each vertex is occupied by either a black particle or a white particle (where particles of the same colour are indistinguishable), such that the total number of black particles is $k < |V |=:n$. For each edge $e$ independently, at the times of a Poisson process of rate $r_e>0$, switch the particles at the endpoints of $e$. In this work we take $G$ to be $d$-regular and set $r_e\equiv 1/d $. The \emph{interchange process} ${\mathrm{IP}}(k)$ is similarly defined, apart from the fact that we label the black particles by the set $[k]:=\{1,\ldots,k\}$, so that they become distinguishable. The exclusion process is among the most fundamental and well-studied processes in the literature on interacting particle systems \cite{liggettbook2,liggettbook1}, with ties to card shuffling \cite{lacoincycle,lacoin,Wilson}, statistical mechanics \cite{Martinelli,KOV,Q} and numerous other processes (see, e.g., \cite[Ch.\ 23]{levin} and \cite{liggettbook2}). Apart from having a rich literature on the model on infinite graphs, such as the lattices $Z_t^{(1)}^d$, the exclusion process on finite graphs has been one of the major examples driving quantitative study of finite Markov chains. Couplings and random walks collision \cite{aldous,olive}, comparison techniques \cite{comparison} (see the discussion in \cite[Appendix A]{olive}) log-Sobolev inequalities \cite{diaconis,LY,Yau}, path coupling \cite{greenberg,levinex,levin,Wilson} and variants of the evolving sets method \cite{CP,evolving,morris,olive} have been applied to this process. Sharp results have been obtained for certain graphs including the complete graph \cite{lacoincomplete,LY}, the discrete tori $(Z_t^{(1)}/LZ_t^{(1)})^d$ \cite{morris}, the path \cite{lacoin} (including the asymmetric case \cite{asymetric2,asymetric}), the cycle \cite{lacoincycle}, and a variety of random graphs \cite{olive}. Bounds on the mixing time of the related interchange process have also been obtained for various graphs \cite{jonasson}. For a continuous-time Markov process $Q$ we denote by $\mix^{Q}(\varepsilon)$ the total-variation $\varepsilon$-mixing time of $Q$ (see e.g.\! \eqref{e:tvmixdef}). When $\varepsilon=1/4$ we omit it from this notation. Oliveira \cite{olive} showed that for some absolute constant $C$, for general graphs and rates, \begin{equation} \label{e:Olivemain} \forall \varepsilon \in (0,1), \quad \max_{k} \mixex (\varepsilon) \le C \mix^{{\mathrm{RW}}(1)} \log (n/\varepsilon), \end{equation} where ${\mathrm{RW}}(r)$ is the process of $r \in \{1,\ldots,n\} $ independent continuous-time random walks on $G$, each having the same transition rates $(r_e:e \in E)$. It was left as an open problem to determine whether the following stronger relation holds \begin{equation} \label{e:Olivecon} \forall \varepsilon \in (0,1),\, \quad \mixex (\varepsilon) \le C \mix^{{\mathrm{RW}}(k)} (\varepsilon). \end{equation} A heuristic reasoning for this conjecture is the fact that the exclusion process satisfies a strong negative dependency property called negative association \cite{NA}, which in some sense is even stronger than independence (see \S\ref{s:NA}). One of the motivations given in \cite{olive} for \eqref{e:Olivemain} is that it serves as a proxy for \eqref{e:Olivecon}, on which it is commented that ``if at all true, is well beyond the reach of present techniques". Part of the appeal of \eqref{e:Olivecon} is its connection to Aldous' spectral-gap conjecture, now resolved by Caputo, Liggett and Richthammer \cite{Caputo}, which asserts that the spectral-gaps of processes $\mathrm{EX}(k),{\mathrm{IP}}(r),{\mathrm{RW}}(1)$ are the same for all $r \in [n]$ and $k \in [n-1] $. A further discussion of connections to this conjecture can be found in \S\ref{s:con}. In this work we consider the mixing time of EX($k$) for general finite $d$-regular graphs with rates $r_{e} \equiv \sfrac{1}{d} $ and obtain bounds in terms of the spectral-profile and relaxation-time. We obtain a general upper bound which is within a $\log\log n$ factor of Oliveira's conjecture when $k= n^{\Omega(1)}$ and prove the conjecture in certain special cases for all $k$ (which includes hypergraphs). Finally, we give lower bounds on the mixing time of EX$(k)$ in terms of independent random walks. Note that $\mathrm{EX}(k)$ is in one-to-one correspondence with $\mathrm{EX}(n-k)$, as we may consider the set of vacant (white) vertices instead of the occupied (black) ones. Hence we may assume throughout that $k \le n/2 $. \subsection{Our main general results}\label{ss:main} We present various bounds on $\mixex$ and show how they relate to verifying \eqref{e:Olivecon} in general, and for specific graphs. The first result we present bounds $\mixex$ in terms of $\rel:=\sfrac{1}{\mathrm{gap}}$ (the \emph{relaxation-time}, which is the inverse of the \emph{spectral-gap}, the smallest positive eigenvalue of $- \mathcal{L} $ for $\mathcal{L}$ the generator of RW(1)) and a quantity related to the decay of the heat-kernel of a random walk, denoted $P_t$. Specifically, for each $\epsilon\in(0,1)$, let (recall $n:=|V|$) \begin{equation}\label{eq:rast} r_\ast(\epsilon):=\inf\{t:\max_{v\in V} P_t(v,v)-1/n\le \sfrac{\epsilon}{(\log n)^2}\}. \end{equation} \begin{maintheorem}[General mixing bound] \label{thm:main1} There exist universal constants $C_{1.1},\,c_{1.1}>0$ such that for every $n$-vertex $d$-regular graph $G$ with rates $r_{e} \equiv \sfrac{1}{d} $ we have that \begin{equation} \label{e:main1} \forall \varepsilon\in(0,1),\quad \max_k \mixex (\varepsilon) \le C_{1.1}( \rel + r_\ast(c_{1.1})) \log (n/\varepsilon) . \end{equation} \textcolor{black}{In particular, $\max_k \mixex (\varepsilon) \lesssim \mix^{{\mathrm{RW}}(\lceil \sqrt{n} \rceil)} (\varepsilon)+ r_\ast(c_{1.1}) \log (n/\varepsilon) $. }\end{maintheorem} For expanders $\rel \asymp 1 $, while it follows from the spectral decomposition that $r_\ast(\epsilon) \asymp_\epsilon \log \log n $. Hence we obtain the bound $\max_k\mixex\lesssim\log n\log\log n$ for expanders (Oliveira's conjecture gives $\log n$). In fact, this is the only natural example we have where $r_*(\epsilon) \gg \rel $. In general (for $n$-vertex regular graphs) it can be shown (see \eqref{e:ts_*2} in \S\ref{S:prelim}) that \begin{align}\label{e:tastsast} r_\ast(\epsilon)\lesssim_\epsilon(\log n)^4\wedge\rel\log\log n\end{align} from which we verify \eqref{e:Olivecon} if $\rel=\Omega((\log n)^4)$ and $k=n^{\Omega(1)}$. Moreover we establish that \eqref{e:Olivecon} holds in general up to a $\log\log n$ factor for $k=n^{\Omega(1)}$. Next, we bound $\mixex (\varepsilon)$ in terms of $t_{\mathrm{sp}}(\varepsilon) $ the bound on the $\varepsilon$ $L_\infty$-mixing time obtained via the spectral profile -- see \eqref{e:profiles} for a definition and $\rel$. \begin{maintheorem}[Mixing for sublinear number of particles] \label{thm:main3} For each $\delta\in(0,1)$ there exist universal constants $C_{1.2}(\delta),$ $C'_{1.2}(\delta)>0$ such that for every $n$-vertex $d$-regular graph $G$ with rates $r_{e} \equiv \sfrac{1}{d} $ and all $k \le n^\delta$ we have that \begin{equation} \label{e:main4} \begin{split} \forall \varepsilon \in (0,1), \quad \mixex (\varepsilon) &\le C_{1.2}(\delta)t_{\mathrm{sp}}(\sfrac{\varepsilon}{k}) \le C'_{1.2}(\delta)[t_{\mathrm{sp}}(\sfrac{1}{2})+\rel \log (k/ \varepsilon) ]. \end{split} \end{equation}In particular if $k\in[n^\beta,n^{1-\beta}]$ for some $\beta\in(0,1/2)$ then \begin{align}\label{e:main5} \forall \varepsilon \in (0,1), \quad \mixex(\varepsilon) \lesssim \mixrwk(\varepsilon). \end{align} \end{maintheorem} This result is one of our principal improvements to the main result of Oliveira \cite{olive} as it gives refined bounds for the case $k=n^{o(1)}$. By applying this theorem we verify \eqref{e:Olivecon} for all $k$ under the condition $t_{\mathrm{sp}}(\sfrac1{2})\lesssim \rel$, see Corollary~\ref{cor:example}. This condition holds for vertex-transitive graphs of moderate growth and for supercritical percolation on a fixed dimensional torus $(\mathbb{Z}/L\mathbb{Z})^d$ (see \S\ref{s:mod}). In these cases we obtain $\mixex \asymp ( \mathrm{diam}(G))^2 \log k $ uniformly in $k \le n/2 $. Morris \cite{morris} obtained the same bound for $G=(Z_t^{(1)}/LZ_t^{(1)})^d$ and Oliveira proved the same bound on the giant component of supercritical percolation on $(Z_t^{(1)}/LZ_t^{(1)})^d$ for $k=n^{\Omega(1)} $. We now explain how \eqref{e:main5} follows from \eqref{e:main4}. If $n\ge k=n^{\Omega (1)} $ then from the definition of the spectral profile we have $t_{\mathrm{sp}}(\sfrac{\varepsilon}{k}) \asymp \rel \log (n/\varepsilon) $ for each $\varepsilon\in(0,1)$ (we remark that the upper bound here holds for all $k\le n$). Further, it can be shown (see \eqref{e:mixkrel} in \S\ref{S:prelim}) that for such $k$ and $\varepsilon$, $\mixrwk(\varepsilon)\asymp \rel\log(n/\varepsilon)$, and so we verify \eqref{e:Olivecon} for $k\asymp n^\delta$ with $\delta\in(0,1)$. For expanders we obtain $\mixex\lesssim_\delta \log n$ for $k\le n^{\delta}$. In the seminal work \cite{Wilson} where he invented the so-called Wilson method, Wilson proved that for the hypercube $\{ \pm 1 \}^d$ one has that $\mix^{\mathrm{EX}(2^{d-1})} \gtrsim d^2$ \cite[p.\ 308]{Wilson}. He conjectured that $ \mix^{\mathrm{EX}(2^{d-1})} \asymp d^2$ (to be precise, one may interpret the last sentence in \cite[\S9.1]{Wilson} as saying that $\mix^{\mathrm{IP}(2^{d})} \lesssim d^2 $\textcolor{black}{, which was verified by the first named author and Salez \cite{IPhypercube} after this paper appeared online}). Using Theorem~\ref{thm:main3} we show that for the hypercube we have $\mixex\lesssim d\log(d k)$ uniformly in $k\le 2^{d-1}$, see \S\ref{s:hypercube} \textcolor{black}{(in fact, we treat general product graphs)}. We also obtain a lower bound of the same order. To the best of our knowledge, previously the best available upper bound for the hypercube was $\max_k \mixex \lesssim d^2\log d $ and for expanders was $\max_k \mixex \lesssim (\log n)^2 $, both due to Oliveira \cite{olive} (see \eqref{e:Olivemain}). The last main bound on $\mixex$ is again just in terms of $\rel$, but requires the degree to be growing sufficiently fast. \begin{maintheorem}[Mixing for graphs of high degree]\label{thm:maindeg} There exist universal constants $C_{\mathrm{deg}},C_{1.3}>0$ such that for every $n$-vertex $d$-regular graph $G$ with rates $r_e\equiv\sfrac1{d}$ if $d \ge C_{\mathrm{deg}} \log_{n/k} n$ then \begin{equation} \label{e:main3} \forall \varepsilon\in(0,1),\quad \mixex (\varepsilon) \le C_{1.3} \rel \log (n/\varepsilon). \end{equation} \end{maintheorem} This theorem verifies \eqref{e:Olivecon} for $k=n^{\Omega(1)}$ when $d=\Omega(\log_{n/k} n)$. \subsection{Lower bounds} We provide now a general lower bound on $\mixex$ in terms of $\rel$. We remark that there are few known general lower bounds on $\mixex$ in the existing literature. Theorem \ref{thm:lower} shows that under a mild delocalization assumption regarding some eigenvector corresponding to the spectral-gap, one has that $\mixex \gtrsim \mix^{{\mathrm{RW}}(k)} $ when $k = n^{\Omega (1)} $. Proposition \ref{p:LS} provides a general condition ensuring that such delocalization holds. Moreover, Corollary \ref{cor:example} provides a sufficient condition for $\mixex \asymp \mix^{{\mathrm{RW}}(k)} $ for all $k$. To motivate our result, consider an $n$-vertex regular expander and attach a path of length $L:=\lceil \log n \rceil $ to one of its vertices. We expect that in this case $\max_k \mixex \lesssim \rel \log L$, and so $\mixex \ll \rel \log k $ for $k=(\log n)^{\omega(1)}$. This demonstrates that in general we cannot expect $\mixex \gtrsim \rel \log k $. We now give a sufficient condition for this to hold. Here we make no assumptions on $G$ nor on the rates $\mathbf{r}:=(r_e:e \in E)$. Recall that $\mathcal{L} $ denotes the generator of RW$(1)$ and let $\pi:=\mathrm{Unif}(V)$ be the stationary distribution. For $ f,g\in \mathbb{R}^V$ define $\|f\|_p^p:=\mathbb{E}_{\pi}[|f|^p]=\sum_x \pi(x)|f(x)|^p$ for $p \in (0,\infty) $ and $\|f\|_{\infty}:=\max_{v \in V}|f(v)|$. \begin{maintheorem} \label{thm:lower} Let $\lambda>0$ be an eigenvalue of $-\mathcal{L} $ and $f \neq 0 $ a corresponding eigenfunction. If $\varepsilon, \delta \in (0,1/4)$ and $k \le n/2$ are such that $\|f\|_1 \ge k^{-1/4+\delta}\|f\|_2$ and $4\delta\log k - \log (16/\varepsilon ) \ge 0$ then \[\mixex (1-\varepsilon) \ge \sfrac{1}{2\lambda}(4\delta\log k - \log (16/\varepsilon ) ). \] \end{maintheorem} Note that in order to apply Theorem \ref{thm:lower} it suffices to find one eigenfunction\ $f$ satisfying $\sfrac{\|f\|_1}{\|f\|_2} \ge k^{-\sfrac{1}{5}}$. Denote the eigenvalues of $-\mathcal{L} $ by $0=\lambda_1 < \lambda_2 \le \cdots \le \lambda_n $. In practice, when applying Theorem \ref{thm:lower} one should pick $\lambda=\lambda_2$. Observe that $\|f\|_2 \le \sqrt{n} \|f\|_1 $ for all $f$ (not necessarily an eigenfunction). Proposition \ref{p:LS} below provides a general upper bound on $\|f\|_2/\|f\|_1 $ for an eigenfunction $f$ corresponding to an eigenvalue $\lambda>0$ of $-\mathcal{L}$ in terms of $\lambda / c_{\mathrm{LS}}$, where $c_{\mathrm{LS}}=c_{\mathrm{LS}}^{\mathrm{RW}(1)} $ is the log-Sobolev constant of the graph (defined in \eqref{e:logsob} of \S\ref{s:profiles}). \begin{proposition} \label{p:LS} For (non-zero) $f \in \mathbb R^V $ such that $\mathcal{L} f=- \lambda f$ we have \begin{equation} \label{e:distortion} \log ( \|f\|_2/2\|f\|_1) \le \lambda/c_{\mathrm{LS}}. \end{equation} \end{proposition} It is natural to expect that $\mixex $ is at least ``weakly" monotone in $k$ for $k \le n/2$. While this is immediate for $\mixIP $, we do not know how to show this for the exclusion process. \begin{conjecture}[Weak monotonicity of the mixing time in the number of particles] There exists an absolute constant $C>0$ such that if $k_1 \le k_2 \le n/2 $ then $\mix^{\mathrm{EX}(k_1)} \le C\mix^{\mathrm{EX}(k_2)}$. \end{conjecture} Embarrassingly, we can resolve only the case when $k_1=1$. \begin{proposition} \label{p:mixexkatleastmixrw1} There exists an absolute constant $c>0$ such that $\min_{k \in [n-1] }\mix^{\mathrm{EX}(k)} \ge c \mix^{{\mathrm{RW}}(1)}$. \end{proposition} We remark that in Proposition \ref{p:mixexkatleastmixrw1} we make no assumption on $G$ nor on the rates. \subsection{On the interchange process} As is the case in \cite{olive}, our arguments can be used to upper-bound ${\mathrm{IP}}(k) $ as long as $k \le (1-\theta)n $ for some constant $\theta \in (0,1)$ (in this case constants $C_{1.1},C_{1.2}$ and $C_{1.4}$ will depend on $\theta$). In a recent work \cite{Alon} Alon and Kozma showed that in the regular case with $r_e=1/d$ the $L_{\infty}$-mixing-time of $\mathrm{IP}(n)$ is $ \lesssim \mix^{{\mathrm{RW}}(1)} \log n $ \textcolor{black}{(their result is more general, but contains an additional multiplicative term, which need not be of order 1 for general rates or when the graph is not regular)}. This is obtained via a comparison argument which hinges on an elegant use of the octopus inequality of Caputo, Liggett and Richthammer \cite{Caputo}. \subsection{Extensions and further applications}\label{s:introrelax} We present a couple of ways in which some of our assumptions can be relaxed; for further details see Appendix~\ref{s:relax}. \begin{itemize} \item The assumption of regularity can be replaced with an assumption on neighbouring vertices having comparable degrees. In this case, the results of Theorems~\ref{thm:main1}--\ref{thm:maindeg} still hold subject to a few modifications. \item The requirement $d \ge C_{\mathrm{deg}} \log_{n/k} n $ in \eqref{e:main3} can be replaced (under some additional conditions) with the assumption that the $\ell$th neighbourhood of each vertex is at least of size $C_\mathrm{deg}\log_{n/k}n$ for some fixed~$\ell$. \end{itemize} \textcolor{black}{A sequence of Markov chains is said to exhibit \emph{precutoff} if for some $\delta_n=o(1)$ the $1-\delta_n$ and the $\delta_n$ mixing times of the $n$th chain in the sequence are comparable, i.e.\ $\mix^{(n)}(\delta_n) \asymp \mix^{(n)}(1-\delta_n)$. Our results imply precutoff in various circumstances.} The following corollaries summarize various scenarios in which the bounds of Theorems \ref{thm:main1}-\ref{thm:lower} and Proposition \ref{p:mixexkatleastmixrw1} take particularly simple forms \textcolor{black}{and precutoff occurs}. In each of the four following statements we let $G_{m}=(V_m,E_m)$ be a sequence of finite $d_m$-regular graphs of increasing sizes $n_m$ with rates $r_{e}^{(m)} \equiv \sfrac{1}{d_m} $. We emphasize the identity of the graph we are considering by adding it as a superscript or in parentheses. \begin{corollary}[{Proof in Appendix~\ref{appb1}}] \label{cor:example} If $\rel(G_m) \asymp t^{G_m}_{\mathrm{sp}}(\sfrac{1}{2}) $ then uniformly in $k_m \le n_m/2 $ we have \begin{equation} \label{e:mixproptotsp} \mix^{\mathrm{EX}(k_m),G_m} \asymp \rel(G_m) \log (k_m +1)\asymp \mix^{\mathrm{RW}(k_m),G_m}. \end{equation} \textcolor{black}{Moreover, the sequence $\mathrm{(EX}(k_m),G_m)$ exhibits a precutoff, provided $k_m \gg 1 $.} \end{corollary} \begin{corollary}[{Proof in Appendix~\ref{appb1}}] \label{cor:1.9} If $\mix^{{\mathrm{RW}}(1),G_m} \asymp t^{G_{m}}_{\mathrm{sp}}(\sfrac{1}{2}) $, then for all fixed $\delta \in (0,1)$, uniformly in $k_m \le n_m^{1-\delta} $ we have \begin{equation} \label{e:mixproptotsp2} \mix^{\mathrm{EX}(k_m),G_m} \asymp_\delta \mix^{{\mathrm{RW}}(1),G_m} + \rel(G_m) \log (k_m +1)\asymp \mix^{\mathrm{RW}(k_m),G_m}. \end{equation}\end{corollary} \textcolor{black}{Moreover, the sequence $\mathrm{(EX}(k_m),G_m)$ exhibits a precutoff, provided that $ \rel(G_m) \log (k_m +1)\gg \mix^{{\mathrm{RW}}(1),G_m} $ and $1 \ll k_m \le n_m^{1-\delta} $ for some $\delta \in (0,1)$.} \begin{corollary}[{Proof in Appendix~\ref{appb1}}] There exist constants $c,c'>0$ such that for all $\delta_{m} \in (0,1/5) $ if $ \sfrac{1}{c_{\mathrm{LS}}(G_m)} \le c \delta_{m} \rel(G_m) \log n_m $ for all $m$ then \begin{align} \label{e:cor1.10}\mix^{\mathrm{EX}(k_m),G_m} \ge c'(\mix^{{\mathrm{RW}}(1),G_m} \vee \delta_{m} \rel(G_m) \log n_m )\end{align} for all $m$ and all $ k_m \in [ n_m^{5\delta_{m}},\sfrac{n_m}{2}]$. \end{corollary} \begin{corollary}[{Proof in Appendix~\ref{appb1}}] \label{cor:1.11} \textcolor{black}{Let $\delta \in (0,1)$. If $\sfrac{1}{c_{\mathrm{LS}}(G_m)} \lesssim \frac{ \rel(G_m) \log n_m }{\log \log n_m} $ then \begin{align}\label{e:13} \mix^{\mathrm{EX}(k_m),G_m} \asymp \rel(G_m) \log( k_m+1) \asymp \mix^{\mathrm{RW}(k_m),G_m}, \end{align} uniformly for $k_m \in [n_m^{\delta}, \sfrac{n_m}{2}]$, and the sequence $\mathrm{(EX}(k_m),G_m)$ exhibits a precutoff provided $n_m^{\delta} \le k_m \le n_m/2 $.} If $\sfrac{1}{c_{\mathrm{LS}}(G_m)} \lesssim \rel(G_m) $ then uniformly in $k_m \le \sfrac{n_m}{2} $ we have that \begin{align}\label{e:14} \rel(G_m) \log (k_m +1)\lesssim \mix^{\mathrm{EX}(k_m),G_m} \lesssim \rel(G_m) \log (k_m \vee \log n_m). \end{align} \textcolor{black}{Moreover, if $ k_m \gtrsim \log n_m $ (and $k_m \leq n_m/2$) the sequence $\mathrm{(EX}(k_m),G_m)$ exhibits a precutoff and $ \mix^{\mathrm{EX}(k_m),G_m} \asymp \mix^{\mathrm{RW}(k_m),G_m} $.} \end{corollary} \subsection{Aldous' spectral-gap conjecture}\label{s:con} In the spirit of Aldous' spectral-gap conjecture, now resolved by Caputo, Liggett and Richthammer \cite{Caputo}, which asserts that the spectral-gaps of processes $\mathrm{EX}(k),{\mathrm{IP}}(r),{\mathrm{RW}}(1)$ are the same for all $r \in [n]$ and $k \in [n-1] $, one may conjecture the stronger relation \begin{equation} \label{e:strongconjecture}\begin{split} &\forall \mathbf{x} \in (V)_k,\, t \ge 0, \\& \|\Pr_{\mathbf{x}}^{{\mathrm{IP}}(k)}(\mathbf{x}(t) \in \bullet)-\pi_{{\mathrm{IP}}(k)} \|_{\TV} \le \|\Pr_{\mathbf{x}}^{{\mathrm{RW}}(k)}(\mathbf{x}(t) \in \bullet)-\pi_{{\mathrm{RW}}(k)} \|_{\TV}. \end{split} \end{equation} Observe that a positive answer to \eqref{e:strongconjecture} will provide another proof to Aldous' conjecture. Indeed, \eqref{e:strongconjecture} yields $\rel^{{\mathrm{IP}}(k)} \le \rel^{{\mathrm{RW}}(k)}=\rel^{{\mathrm{RW}}(1)}$, which can be deduced from \eqref{e:mixrel}. Conversely, the inequalities $\rel^{{\mathrm{IP}}(k)} \ge \rel^{\mathrm{EX}(k)} \vee \rel^{{\mathrm{RW}}(1)} $ for all $k \in [n] $ (where we define $\rel^{\mathrm{EX}(n)}=0$) and $\rel^{\mathrm{EX}(k)} \ge \rel^{{\mathrm{RW}}(1)}$ for all $k \in [n-1]$ are the easier direction of Aldous' conjecture (see \cite{Caputo}). Similarly, our Theorems \ref{thm:main1}-\ref{thm:maindeg} show that for regular graphs $\max_k \rel^{\mathrm{EX}(k)} \lesssim \rel+r_\ast $ (recall that often $r_* \lesssim \rel$), while if $d \ge C_{\deg} \log_{k/n} n$ then $\rel^{\mathrm{EX}(k)} \lesssim \rel $, and (for all $d$) $\max_{k \le n^{\delta} } \rel^{\mathrm{EX}(k)} \lesssim_{\delta} \rel $. While this is of course weaker than the result of Caputo et al., what is interesting here is that our proof is entirely probabilistic. \textcolor{black}{It is plausible that Aldous' conjecture could be strengthened to an operator $L_2$ inequality, between the generator of the interchange process and that of the corresponding mean-field system (see \cite[Conjecture 1]{IPhypercube}). This would have striking consequences, including verifying Oliveira's conjecture (even for the $L_2$ mixing--time). See \cite{Alon} for an application for the emergence of macroscopic cycles in the cycle decomposition of the permutation obtained by running the interchange process. We note that such an operator inequality was recently proved for the zero range process in \cite{ZRP}. } \begin{question} Is it the case that there exists an absolute constant $C>1$ and some non-decreasing continuous $f:[0,1] \to [0,1]$ with $f(0)=0$ such that for all $t \ge 0$ \begin{equation*} \label{e:revereseconjecture} \begin{split} \forall \mathbf{x} \in (V)_k,\, \quad &\|\Pr_{\mathbf{x}}^{{\mathrm{IP}}(k)}(\mathbf{x}(t) \in \bullet)-\pi_{{\mathrm{IP}}(k)} \|_{\TV}\\& \ge f( \|\Pr_{\mathbf{x}}^{{\mathrm{RW}}(k)}(\mathbf{x}(Ct) \in \bullet)-\pi_{{\mathrm{RW}}(k)} \|_{\TV}), \\ \forall A \in \binom{V}{k},\, k \le n/2 \quad &\|\Pr_{A}^{\mathrm{EX}(k)}(A_{t}\in \bullet)-\pi_{\mathrm{EX}(k)} \|_{\TV} \\&\ge f( \|\Pr_{A}^{\widehat{ {\mathrm{RW}}}(k)}(\widehat{\mathbf{x}}(Ct) \in \bullet)-\pi_{\widehat{ {\mathrm{RW}}}(k)} \|_{\TV}), \\ \forall \varepsilon \in (0,1/4), \quad& C \max_{k} \mixex (\varepsilon) \ge \mix^{{\mathrm{IP}}(n)} (f(\varepsilon)), \end{split} \end{equation*} where $\widehat{ {\mathrm{RW}}}(k) $ is the projection of ${\mathrm{RW}}(k) $ obtained by forgetting the labeling of the particles? \end{question} \subsection*{Asymptotic notation} We write $o(1)$ for terms which vanish as $n \to \infty$. We write $f_n=o(g_n)$ or $f_n \ll g_n$ if $f_n/g_n=o(1)$. We write $f_n=O(g_n)$ and $f_n \lesssim g_n $ (and also $g_n=\Omega(f_n)$ and $g_n \gtrsim f_n$) if there exists a constant $C>0$ such that $|f_n| \le C |g_n|$ for all $n$. We write $f_n=\Theta(g_n)$ or $f_n \asymp g_n$ if $f_n=O(g_n)$ and $g_n=O(f_n)$. Throughout $\log \log n$ is to be interpreted as $\log \log (n \vee e^e)$, where $a \vee b:=\max\{a,b\}$ and $a \wedge b:=\min\{a,b\}$. \subsection*{Organization of the paper} In \S\ref{S:prelim}, we recall some properties of the exclusion process (its graphical construction and negative association), prove Proposition~\ref{p:LS}, show how the mixing time of $k$ particles is related to the mixing time of one particle conditioned on the others, and provide an auxiliary bound on the $L_2$ distance. In \S\ref{S:cham} we introduce the chameleon process as the main tool which allows us to bound the mixing time of one particle conditioned on the others. We also prove Theorem~\ref{thm:main1} subject to some technical propositions (the majority of whose proofs appear in the appendix), the most significant of which being Proposition~\ref{P:beta}. We give a detailed overview of how we use the chameleon process in \S\ref{s:overview} and turn these heuristics into formal arguments in \S\ref{S:neighbours} and \S\ref{S:loss}, proving Proposition~\ref{P:beta} for the case of large degree. In \S\ref{S:modifications} we show how to modify the arguments already presented in order to prove Proposition~\ref{P:beta} for small degree graphs, as well as Theorems~\ref{thm:main3} and~\ref{thm:maindeg}. We present the proof of the lower bounds in \S\ref{s:lower}, and give further applications of our results in \S\ref{s:examples}. \section{Preliminaries}\label{S:prelim} \subsection{Mixing times} Note that since $\mathrm{EX}(k) $ and ${\mathrm{IP}}(k)$ are irreducible and have symmetric transition rates, the uniform distributions on their state spaces $\binom{V}{k}$ (the set of all subsets of $V$ of size $k$) and $(V)_k$ (the set of all $k$-tuples of distinct vertices), respectively, are stationary. Recall that the total variation distance of two distributions on a finite set $\Omega $ is \begin{align*} \|\mu - \nu \|_{\TV}:=\sum_{a:\mu(a)>\nu(a)}(\mu(a)-\nu(a)). \end{align*} Throughout, we use the convention that $(X_t)_{t \ge 0 } $ is a continuous-time random walk on the graph $G$ with the same jump rates as above (\textit{i.e.}, a realisation of $\mathrm{EX}(1)$), and that $(A_t)_{t \ge 0}$ and $(\mathbf{x}(t))_{t\ge0}$ are $\mathrm{EX}(k) $ and ${\mathrm{IP}}(k)$, respectively (we sometimes use $(\mathbf{w}(t))_{t\ge0},(\mathbf{y}(t))_{t\ge0}$ or $(\mathbf{z}(t))_{t\ge0}$ instead of $(\mathbf{x}(t))_{t\ge0}$). We denote the uniform distribution on $V$ by $\pi $ and on $\binom{V}{k}$ and $(V)_k $ by $\pi_{\mathrm{EX}(k)}$ and $\pi_{{\mathrm{IP}}(k)}$. We write $\Pr_x $ (resp.\ $\Pr_A^{\mathrm{EX}(k)} $, $\Pr_\mathbf{x}^{\mathrm{IP}(k)}$) for the law of $(X_t)_{t \ge 0 } $ given $X_0=x$ (resp.\ $(A_t)_{t \ge 0 } $ given $A_0=A$, $(\mathbf{x}(t))_{t\ge0}$ given $\mathbf{x}(0)=\mathbf{x}$). The total variation $\varepsilon$-mixing times of a single walk and of $\mathrm{EX}(k)$ are \begin{align}\label{e:tvmixdef} \mix(\varepsilon)=\mix^{{\mathrm{RW}}(1)}(\varepsilon):= \inf \{t: \max_{x \in V} \|\Pr_x(X_t \in \bullet) - \pi \|_{\TV} \le \varepsilon \}, \\\label{e:tvEXmixdef} \mixex(\varepsilon):= \inf \{t: \max_{A \in \binom{V}{k} } \|\Pr_A^{\mathrm{EX}(k)}(A_t \in \bullet) - \pi_{\mathrm{EX}(k)} \|_{\TV} \le \varepsilon \}. \end{align} The mixing times $\mixIP (\varepsilon)$ and $\mixrwk (\varepsilon) $ of ${\mathrm{IP}}(k)$ and ${\mathrm{RW}}(k)$, respectively, are analogously defined. Recall that when $\varepsilon=1/4$ we omit it from the above notation. The $\delta $ $L_{\infty}$-mixing time of a single walk (throughout, we consider the $L_2$ and $L_{\infty}$ distances and mixing times only w.r.t.\ a single walk) is defined as \[ \mix^{(\infty)} (\delta):=\inf\{t: \max_{x,y \in V} |nP_t(x,y)-1 | \le \delta \} \] and we set $\mix^{(\infty)}:=\mix^{(\infty)}(1/2)$. Recall that $P_t$ denotes the heat-kernel of a single walk. The relaxation-time is defined as $$\rel:=\sfrac{1}{\mathrm{gap}}=\lim_{t \to \infty} \sfrac{-t}{ \log [\max_{x \in V } P_t(x,x)-1/n]}, $$ i.e. it is the inverse of the \emph{spectral-gap}, the smallest positive eigenvalue of $- \mathcal{L} $, where $\mathcal{L}$ is the generator of a single walk. We now note that we can characterize $\mix^{{\mathrm{RW}}(k)}(\varepsilon) $ in terms of $ \mix^{{\mathrm{RW}}(1)}(\varepsilon / k) $, which in turn can be characterized in terms of the relaxation-time when $k=n^{\Omega (1)}$. This was used in the discussion following Theorem~\ref{thm:main3} (mixing for sublinear number of particles). Indeed, \begin{equation} \label{e:kvs1} \forall k \in \mathbb N ,\, \varepsilon \in (0,1/4), \quad \ssfrac{1}{2} \mix^{{\mathrm{RW}}(1)}(4\varepsilon / k) \le \mix^{{\mathrm{RW}}(k)}(\varepsilon) \le \mix^{{\mathrm{RW}}(1)}(\varepsilon / k). \end{equation}The second inequality is easy, while the first requires considering the separation distance, and noting that $$\min_{\mathbf{x},\mathbf{y}\in V^k} \Pr_{\mathbf{x}}^{{\mathrm{RW}}(k)}(\mathbf{x}(t)=\mathbf{y})=[\min_{x,y \in V } \Pr_{x}^{{\mathrm{RW}}(1)}(X_t=y)]^{k},$$ cf.\ \cite{lacoinproduct}. Generally, (\cite[Lemma 20.6 and Lemma 20.11]{levin}) for a Markov chain on a state space $V$ of size $n$ with a symmetric generator \begin{equation} \label{e:mixrel} \forall \varepsilon \in (0,1), \quad \rel | \log \varepsilon| \le \mix^{{\mathrm{RW}}(1)} (\varepsilon /2) \le \mix^{(\infty)} (\varepsilon ) \le \rel | \log n/ \varepsilon|. \end{equation} It follows by combining \eqref{e:kvs1} and \eqref{e:mixrel} that for all $C \ge 1,\varepsilon \in (0,1) $ and all $k \in[ 4 \varepsilon n^{1/C},(n/\varepsilon)^C] $ \begin{equation} \label{e:mixkrel} \sfrac{1}{2C} \rel \log (n/(2\varepsilon) ) \le \mix^{{\mathrm{RW}}(k)}(\varepsilon) \le (C+1)\rel \log (n/\varepsilon). \end{equation} We verify now the claimed bound on $r_\ast(\epsilon)$ of \eqref{e:tastsast}. For ($n$-vertex) regular graphs, $P_t(v,v)-\sfrac{1}{n} \lesssim (t+1)^{-1/2} $ (e.g.\! \cite{sensitivity,Lyonsev}) for all $t$. Hence $r_\ast(\epsilon)\le C(\epsilon)(\log n)^4$ for some constant $C$ depending only on $\epsilon$. As \[\forall t \ge 0,\, i \in \mathbb N, \quad P_{it}(v,v)-\sfrac{1}{n} \ge (P_{t}(v,v)-\sfrac{1}{n})^i \] (which follows via the spectral decomposition), by \eqref{e:mixrel} (used in the third inequality) we get that \begin{equation} \label{e:ts_*2} \begin{split} r_\ast(\epsilon) \lesssim \mix^{(\infty)}( \sfrac{\epsilon n}{(\log n)^2}) &\lesssim_\epsilon (\log n)^4 \wedge\mix^{(\infty)} \sfrac{\log \log n}{\log n} \\& \lesssim (\log n)^4 \wedge \rel \log \log n. \end{split} \end{equation} \subsection{The spectral-profile, evolving sets and log-Sobolev} \label{s:profiles} As the generator $\mathcal{L}$ is symmetric, it is self-adjoint with respect to the inner-product on $\mathbb{R}^V$ induced by $\pi$, given by $\langle f,g\rangle_\pi=\mathbb{E}_\pi[fg]:=\sum_x\pi(x)f(x)g(x)$. Recall that the \emph{spectral-gap} is $\mathrm{gap}:=\lambda_2 $ satisfies \begin{equation} \label{e:gapdef} \lambda_2:=\min \{\mathcal{E}(h,h)/\mathrm{Var}_{\pi}h:h \in \mathbb R^V \text{ is non-constant} \}, \end{equation} where $\mathcal{E}(f,f):=\langle-\mathcal{L}f,f\rangle_{\pi}=\ssfrac{1}{2} \sum_{x,y}\pi(x) \mathcal{L}(x,y)(h(x)-h(y))^2 $. Recall also that the \emph{log-Sobolev constant} is given by \begin{align}\label{e:logsob} c_{\mathrm{LS}}:=\inf \{\sfrac{\mathcal{E}(h,h)}{\mathrm{Ent}_{\pi}h^{2}} : h^{2} \in (0,\infty)^{V} \} , \end{align} where $\mathrm{Ent}_{\pi}f:=\mathbb{E}_{\pi}[f \log(f/\|f\|_1)]$. Denote $\Lambda(\varepsilon):=\min \{\mathcal{E}(h,h)/\mathrm{Var}_{\pi}h : h \in \mathbb R^{V}, \pi( \mathrm{supp}(h)) \le \varepsilon \}$, where $ \mathrm{supp}(h):=\{x \in V :h(x) \neq 0 \}$ is the \emph{support} of $h$. We now recall a couple of results from \cite{spectral}. While some of the results below were originally stated in the case where $\mathcal{L} $ is of the form $K-I$, where $I$ is the identity matrix and $K$ is a transition matrix of a discrete-time Markov chain (possibly with non-zero diagonal entries), they hold for general $\mathcal{L}$, as we can always write $\mathcal{L}:=\max_x |\mathcal{L}(x,x)|(K-I) $ for some transition matrix $K$ (possibly with positive diagonal entries). (All the quantities considered below scale linearly in $\max_x |\mathcal{L}(x,x)|$.) \begin{proposition}[\cite{spectral} Lemma 4.2] For all $\varepsilon \in (0,1) $ \label{p:spectral1} \[(1-\varepsilon)\Lambda(\varepsilon) \ge c_{\mathrm{LS}} \log (1/\varepsilon). \] \end{proposition} \begin{remark} It was shown in \cite{L2} that $17/c_{\mathrm{LS}} \le \max_{\varepsilon \le 1/2 } \frac{\log (1/\varepsilon)}{\Lambda(\varepsilon) }$. \end{remark} \begin{proposition}[\cite{spectral} Lemma 2.1] \label{p:spectral2} For any (non-zero) $u \in \mathbb R_+^V$ we have that \[\sfrac{\mathcal{E}(u,u)}{\mathrm{Var}_{\pi}u} \ge \ssfrac{1}{2} \Lambda \left( 4\|u\|_1^2/ \mathrm{Var}_{\pi}u \right).\] \end{proposition} \begin{proof}[Proof of Proposition \ref{p:LS}] Let $f \in \mathbb R^V $ satisfy $- \mathcal{L} f=\lambda f$. We assume $ \|f\|_2 \ge 2 \|f\|_1 $, as otherwise there is nothing to prove. By Propositions \ref{p:spectral1} and \ref{p:spectral2} we have that \begin{align*}\lambda \ge \sfrac{\mathcal{E}( f,f)}{\mathrm{Var}_{\pi}f} \ge \ssfrac{1}{2} \Lambda \left( 4\|f\|_1^{2} / \mathrm{Var}_{\pi}f \right) &\ge\ssfrac{1}{2} \Lambda \left( 4\|f\|_1^{2} /\|f\|_2^2 \right) \\&\ge c_{\mathrm{LS}} \log (\|f\|_2/2\|f\|_1). \qedhere \end{align*} \end{proof} Recall that the $L_p$ norm of a signed measure $\sigma$ is \begin{equation*} \label{eq: Lpdef} \|\sigma \|_{p,\pi}:=\|\sigma / \pi \|_p, \quad \text{where} \quad (\sigma / \pi)(x)=\sigma(x) / \pi(x). \end{equation*} In particular, for a distribution $\mu$ its $L_2$ distance from $\pi$ satisfies \[\|\mu - \pi \|_{2,\pi}^2:=\|\mu / \pi - 1\|_2^{2}=\mathrm{Var}_{\pi}(\mu / \pi). \] Let $\mu_t:=\Pr_{\mu}^t $ and $u_t:=\mu_{t} / \pi$. It is standard that $\frac{d}{dt}\mathrm{Var}_{\pi}(u_{t} )=-2 \mathcal{E}(u_{t},u_{t}) $ (\textit{e.g.}\ \cite[p.\ 284]{levin}). By \eqref{e:gapdef} $ \mathcal{E}(u_{t},u_{t}) \ge \lambda_2 \mathrm{Var}_{\pi}(u_{t} ) $ from which it follows that $\frac{d}{dt}\mathrm{Var}_{\pi}(u_{t} ) \le -2\lambda_2 \mathrm{Var}_{\pi}(u_{t} ) $, and so by Gr\"onwall's lemma \begin{equation} \label{e:Poincare} \|\mu_{t} - \pi \|_{2,\pi}^2 \le \|\mu - \pi \|_{2,\pi}^2 \exp(-2\lambda_2 t). \end{equation} This is the well-known Poincar\'e inequality. The $\varepsilon$ $L_p$-\emph{mixing time} is defined as \[t_{\mathrm{mix}}^{(p)}(\varepsilon):=\inf\{t:\max_{x}\|\Pr_x^t - \pi\|_{p,\pi} \le \varepsilon \}. \] It is standard (\textit{e.g.}\ \cite{spectral} or \cite[Prop.\ 4.15]{levin}) that for reversible Markov chains, for all $x \in V$ and $t$ we have \begin{equation} \label{e:maxdiag} \max_{x,y}|\sfrac{P_t(x,y)}{\pi(y)}-1|=\max_{x}\sfrac{P_t(x,x)}{\pi(x)}-1 \quad \text{and} \quad \|\Pr_{x}^t - \pi \|_{2,\pi}^2=\sfrac{P_{2t}(x,x)}{\pi(x)}-1. \end{equation} Thus $t_{\mathrm{mix}}^{(\infty)}(\varepsilon^2)=2 t_{\mathrm{mix}}^{(2)}(\varepsilon) $ for all $\varepsilon \le ( \max_x \frac{1-\pi(x)}{\pi(x)})^{1/2}$. The \emph{spectral-profile} \cite{spectral} and \emph{isoperimetric-profile/evolving-sets} \cite{evolving} bounds on the $\varepsilon$ $L_{\infty}$ mixing time are respectively given by \begin{equation} \label{e:profiles} \begin{split} &t_{\mathrm{sp}}(\varepsilon):= \int_{4/n}^{4/\varepsilon} \frac{2d \delta}{\delta \Lambda(\delta) }, \\ & t_{\mathrm{evolving-sets}}(\varepsilon):= \max_x |\mathcal{L}(x,x)|\int_{4/n}^{4/\varepsilon \wedge 1/2} \frac{4d \delta}{\delta \Phi^2(\delta) } + \rel \log (8/\varepsilon) \Ind{\varepsilon \le 8}, \end{split} \end{equation} where $\Phi(\delta):= \inf \left\{\frac{\sum_{a \in A,b \notin A}\pi(a) \mathcal{L}(a,b)}{\pi(A)} : A \subset V \text{ such that } \pi(A) \le \delta \right\}$. A generalization of the well-known discrete Cheeger inequality is that \cite[Lemma 2.4]{spectral} \begin{equation} \label{e:spb0} \Phi^2(\delta)/(2\max_x |\mathcal{L}(x,x)|) \le \Lambda(\delta) \le\Phi(\delta)/(1-\delta), \end{equation} from which it follows that $t_{\mathrm{sp}}(\varepsilon) \le t_{\mathrm{evolving-sets}}(\varepsilon) $. Theorem 1.1 in \cite{spectral} asserts that \begin{equation} \label{e:spb1} \forall \varepsilon \in (0,n] , \quad t_{\mathrm{mix}}^{(\infty)}(\varepsilon) \le t_{\mathrm{sp}}(\varepsilon) \le t_{\mathrm{evolving-sets}}(\varepsilon) . \end{equation} Plugging the estimate of Proposition \ref{p:spectral1} in \eqref{e:profiles} and then integrating over $\delta$ gives \cite[Corollary 4.1]{spectral} (cf.\ \cite{Kozma} for a slightly different argument). \begin{proposition} \label{p:specLS} There exists an absolute constant $C$ such that $$t_{\mathrm{sp}}(\sfrac{1}{2}) \le C\sfrac{\log \log n}{ c_{\mathrm{LS}}}.$$ \end{proposition} Using Proposition \ref{p:spectral2} (noting that $\| u_t \|_1 =1 $) the following refines \eqref{e:Poincare}. \begin{proposition}[\cite{spectral} Theorem 1.1] \label{p:spectral3} For any initial distribution $\mu $ we have that \begin{equation} \label{e:spb2} \|\mu_{t} - \pi \|_{2,\pi}^2 \le M , \quad \text{if} \quad t \ge \int_{4/\|\mu - \pi \|_{2,\pi}^2}^{4/M} \frac{d \delta}{\delta \Lambda(\delta) }. \end{equation} In particular, for all $0<c<1$ we have that \begin{equation} \label{e:spb3} \|\mu_{t} - \pi \|_{2,\pi}^2 \le c \|\mu - \pi \|_{2,\pi}^2 , \quad \text{if} \quad t \ge \frac{\log (1/c)}{\Lambda(4/c \|\mu - \pi \|_{2,\pi}^2)} . \end{equation} \end{proposition} The following lemma is a simple consequence of Proposition \ref{p:spectral1} together with \eqref{e:spb2}. \begin{lemma} \label{lem:r} Let $r_{*}$ be as in \eqref{eq:rast}. For every $c >0$ we have that \begin{equation} \label{e:rLS} r_{*}(c) \lesssim_c \frac{ \log \log n}{ c_{\mathrm{LS}}\log n}. \end{equation} \end{lemma} \subsection{Graphical construction}\label{S:graphical} We present a graphical construction of the processes EX$(k)$, IP$(k)$ and RW$(1)$, similar to that of Liggett \cite{liggettbook2} and Oliveira \cite{olive}. This construction enables us to define the processes on the same probability space, to then allow for direct comparison. We consider the following two ingredients: \begin{enumerate} \item a Poisson process $\Lambda$ of rate $\frac1d|E|$; \item an i.i.d. sequence of uniformly-distributed $E$-valued random variables $\{e_n\}_{n\in\mathbb{N}}$. \end{enumerate}Next we define the transpositions $f_e:V\to V$ for $e=\{u,v\}\in E$ as \[ f_e(x)=\begin{cases} u,&\mbox{if }x=v,\\ v,&\mbox{if }x=u,\\ x,&\mbox{otherwise.} \end{cases} \]We extend $f_e$ to act on subsets of $V$ and $k$-tuples by setting $f_e(A)=\{f_e(a):\,a\in A\}$ and $f_e(\mathbf{x})=(f_e(\mathbf{x}(1)),\ldots,f_e(\mathbf{x}(k))) $. Then for $0\le s\le t<\infty$ we define permutations $I_{[s,t]}$ as $ I_{[s,t]}=f_{e_{\Lambda[0,t]}}\circ f_{e_{\Lambda[0,t]-1}}\circ\cdots\circ f_{e_{\Lambda[0,s)+1}}, $ for $\Lambda[s,t]>0$ (denoting the number of instances of the Poisson process $\Lambda$ during time interval $[s,t]$), otherwise we set $I_{[s,t]}$ to be the identity map. Hence $I_{[s,t]}$ is the composition of the transpositions $f_{e_j}$ that are chosen during $[s,t]$ composed in the order they occur. The following proposition is fundamental and its proof follows by inspection. \begin{proposition}[Proof omitted] Fix $t>0$. Then \begin{enumerate} \item For each $u\in V$ the process $\{I_{[s,s+t]}(u)\}_{t\ge0}$ is a realisation of $\mathrm{RW(1)}$ initialised at $u$ at time~$s$. \item For each $A\in \binom{V}{k}$ the process $\{I_{[s,s+t]}(A)\}_{t\ge0}$ is a realisation of $\mathrm{EX}(k)$ initialised at $A$ at time $s$. \item For each $\mathbf{x}\in (V)_k$ the process $\{I_{[s,s+t]}(\mathbf{x})\}_{t\ge0}$ is a realisation of $\mathrm{IP}(k)$ initialised at $\mathbf{x}$ at time $s$. \end{enumerate} \end{proposition} \subsection{Negative association} \label{s:NA} Let $Y_1,\ldots,Y_m$ be real-valued random variables. Let $\mathbf{Y}_A:=(Y_a)_{a \in A}$. We say that they are \emph{negatively correlated} if $\mathrm{Cov}(Y_i,Y_j) \le 0 $ for all $i \neq j$. We say that they are \emph{negatively associated} if \[\text{(\textbf{NA})} \quad \mathbb{E}[f(\mathbf{Y}_A)g(\mathbf{Y}_B)] \le \mathbb{E}f(\mathbf{Y}_A)\mathbb{E}g(\mathbf{Y}_B), \] for all disjoint $A , B \subset [m] $ and all $f,g$ non-decreasing w.r.t.\ the co-ordinate-wise partial order $\le_{\mathrm{cw}}^i $ on $\mathbb R^{i}$ (for $i=|A|,|B|$, respectively) defined via $(x_1,\ldots,x_i)\le_{\mathrm{cw}}^i (y_1,\ldots,y_i) $ if $x_j \le y_j $ for all $j \in [i]$. We say they are \emph{conditionally negatively associated} (\textbf{CNA}) if for all $D \subset [m] $ the same holds when conditioning on $\mathbf{Y}_D$, \textit{i.e.}, \begin{equation*}(\textbf{CNA})\begin{split} \quad \forall D \subset [m], \quad &\mathbb{E}[f(\mathbf{Y}_A)g(\mathbf{Y}_B) \mid \mathbf{Y}_D ] \\&\le \mathbb{E[}f(\mathbf{Y}_A) \mid \mathbf{Y}_D]\mathbb{E[}g(\mathbf{Y}_B) \mid \mathbf{Y}_D] \end{split}\end{equation*} for all disjoint $A,B$ and all non-decreasing $f,g$. Borcea, Br\"and\'en and Liggett \cite{NA} showed that (for the exclusion process) $(\Ind{v \in A_t}:v \in V)$ is CNA, when $A_0$ is either deterministic or a product measure. It follows by taking the limit as $t \to \infty$ that the CNA property holds also for the stationary distribution $\pi_{\mathrm{EX}(k)}=\mathrm{Unif}(\binom{V}{k}) $ (\textit{i.e.}, for $(\Ind{v \in A}:v \in V)$, when $A \sim \pi_{\mathrm{EX}(k)} $). It is clear that the NA property implies pairwise negative correlation (\textit{i.e.}, $\mathrm{Cov}(\Ind{v \in A_t},\Ind{u \in A_t}) \le 0 $). While in \cite{olive} only the negative correlation property was used, we will make crucial use of the CNA property. \subsection{From mixing of $k$ particles to mixing of 1 particle conditioned on the rest} \label{s:useful} By the contraction principle it suffices to bound the mixing time of ${\mathrm{IP}}(k)$ as for all $k$ \begin{equation} \label{e:trianglein} \begin{split} & \max_{A \in \binom{V}{k} }\|\Pr_{A}^{\mathrm{EX}(k)}[A_t \in \bullet]-\pi_{\mathrm{EX}(k)}(\bullet)\|_{\TV}\\& \le \max_{\mathbf{x} \in (V)_k }\|\Pr_{\mathbf{x}}^{\mathrm{IP}(k)}[\mathbf{x}(t) \in \bullet]-\pi_{\mathrm{IP}(k)}(\bullet)\|_{\TV} \le \max_{\mathbf{x},\mathbf{y} \in (V)_k }\Delta_{\mathbf{x},\mathbf{y}}(t),\\ &\text{where } \Delta_{\mathbf{x},\mathbf{y}}(t):=\max_{\mathbf{x},\mathbf{y} \in (V)_k }\|\Pr_{\mathbf{x}}^{\mathrm{IP}(k)}[\mathbf{x}(t) \in \bullet]-\Pr_{\mathbf{y}}^{\mathrm{IP}(k)}[\mathbf{y}(t) \in \bullet]\|_{\TV}. \end{split} \end{equation} We may interpolate between any two configurations $\mathbf{x},\mathbf{y} \in (V)_k$ via a sequence of at most $k+1$ configurations, $\mathbf{x}=\mathbf{z}_0,\mathbf{z}_1, \ldots ,\mathbf{z}_j=\mathbf{y} \in (V)_k$ such that $\mathbf{z}_i$ and $\mathbf{z}_{i-1}$ differ on exactly one co-ordinate for all $i \in [j]$. By symmetry, we may assume this is the $k$-th co-ordinate (the total variation distance at time $t$ w.r.t.\ two initial configurations is invariant under an application of the same permutation to their co-ordinates). By the triangle inequality, at a cost of picking up a factor $k$, we get that it suffices to consider two initial configurations which disagree only on their last co-ordinates: \begin{equation} \label{e:trianglein2} \max_{\mathbf{x},\mathbf{y} \in (V)_k }\Delta_{\mathbf{x},\mathbf{y}}(t) \le k \max_{(\mathbf{w},y),(\mathbf{w},z) \in (V)_k:\mathbf{w} \in (V)_{k-1},y,z \in V }\Delta_{(\mathbf{w},y),(\mathbf{w},z)}(t). \end{equation} Let $\mathbf{w}(t)=(\mathbf{w}_{1}(t),\ldots,\mathbf{w}_{k-1}(t))$ be the positions of the first $k-1$ co-ordinates at time $t$. Given $\mathbf{w}(t)$, the positions of the $k$-th co-ordinates at time $t $ of both configurations on the r.h.s.\ $y(t)$ and $z(t)$ converge (as $t \to \infty$) to the uniform distribution on $\mathbf{w}(t)^{\complement}:=V \setminus \{\mathbf{w}_{i}(t):i \in [k-1] \} $. It is thus natural to compare the two to $U \sim \mathrm{Unif}(\mathbf{w}(t)^{\complement}) $ (given $\mathbf{w}(t)$) using the triangle inequality: \begin{equation} \label{e:trianglein3}\begin{split} &\max_{(\mathbf{w},y),(\mathbf{w},z) \in (V)_k:\mathbf{w} \in (V)_{k-1} }\Delta_{(\mathbf{w},y),(\mathbf{w},z)}(t) \\&\le 2 \max_{(\mathbf{w},y) (V)_k:\mathbf{w} \in (V)_{k-1} } \| \mathcal{L}_{(\mathbf{w}(t),y(t))}-\mathcal{L}_{(\mathbf{w}(t),U)} \|_{\TV},\end{split} \end{equation} where $\mathcal{L}_X$ denotes the law of $X$. Hence we reduced the problem of showing that $\Delta_{\mathbf{x},\mathbf{y}}(t) \le \varepsilon $ to that of showing that the maximum on the r.h.s.\ of \eqref{e:trianglein3} is at most $\sfrac{\varepsilon}{2k} $. The total-variation distance in the maximum is that of the last co-ordinate from $U \sim \mathrm{Unif}(\mathbf{w}(t)^{\complement})$, averaged over $\mathbf{w}(t) $. Hence loosely speaking, we reduced the problem to that of bounding the $\sfrac{\varepsilon}{2k} $-mixing time of the last co-ordinate, given the rest of the co-ordinates (in some averaged sense). \subsection{An auxiliary lower bound on the $L_2$ distance} Let $\mathscr{P}(V)$ be the collection of all distributions on $ V $. For $A \subsetneq V $ and $\delta \in (0,1) $, let \[\mathscr{P}_{A,\delta}:=\{\mu \in \mathscr{P}(V): \mu(A) \ge \pi(A)+\delta \pi (A^c) \}.\] Note that $\nu_{A,\delta}:= \delta \pi_A+(1-\delta)\pi \in \mathscr{P}_{A,\delta} $, where $\pi_A$ denotes $\pi$ conditioned on $A$ (i.e. $\pi_A(a) = \pi(a)\indic{a\in A}/\pi(A)$). Moreover, $\min \{\delta':\nu_{A,\delta'} \in \mathscr{P}_{A,\delta} \}=\delta $. It is thus intuitive that for a convex distance function between distributions, $\nu_{A,\delta} $ is the closest distribution to $\pi$ in $\mathscr{P}_{A,\delta}$. The assertion of the following proposition can be verified using Lagrange multipliers, noting that the density function of the distribution with respect to $\pi$ has to be constant on $A$ and on $A^{\complement}$. \begin{proposition}[\cite{L2} Proposition 4.1] \label{prop: Lagrange} Let $A \subsetneq V $. Denote $\nu_{A,\delta}:= \delta \pi_A+(1-\delta)\pi$. Then \begin{equation} \label{eq: Lagrange} \forall \delta \in (0,1) \quad \min_{\mu \in \mathscr{P}_{A,\delta}}\| \mu-\pi\|_{2,\pi}^2=\|\nu_{A,\delta}-\pi\|_{2,\pi}^2=\delta^{2} \pi(A^{\complement})/\pi(A). \end{equation} \end{proposition} \section{The chameleon process}\label{S:cham} Our main tool is the use of the \emph{chameleon process}, a process invented by Morris \cite{morris} and used by Oliveira \cite{olive} and Connor-Pymar \cite{CP} to keep track of the distribution of a single particle in an interchange process, conditional on the locations of the other particles (see Proposition \ref{p:inkatb} for a precise formulation). As explained in \S\ref{s:useful}, this can be used to upper bound the mixing time of the interchange process (and thus also of the exclusion process). This is quantified in Proposition \ref{p:chambound}. We will make use of several variants of this process. In some situations the process consists of rounds of unvarying duration and is very similar to that used in \cite{olive}; whereas in others the length of rounds can vary in a way similar to \cite{morris}. The precise nature of the process depends on the values of $k$ and $d$, and the current state of the process. We shall present first the version most similar to \cite{olive} (and with which we prove Theorems~\ref{thm:main1} (general mixing bound) and~\ref{thm:maindeg} (mixing for graphs of high degree)) and show in \S\ref{SS:thm2proof} how this can be adapted to prove Theorem~\ref{thm:main3} (mixing for sublinear number of particles). \subsection{Description of the process}\label{SS:cham_desc} We start this section with the construction of the chameleon process. The first step is to modify slightly the graphical construction of \S\ref{S:graphical}. We suppose now that edges ring at rate $2/d$ and an independent fair coin flip determines whether particles on a ringing edge switch places or not. More formally, consider the following ingredients: \begin{enumerate} \item a Poisson process $\Lambda=\{\tau_1,\tau_2,\ldots\}$ of rate $\frac2{d}|E|$; \item an i.i.d.\! sequence of uniformly-distributed $E$-valued random variables $\{e_n\}_{n\in\mathbb{N}}$; \item an i.i.d.\! sequence of coin flips $\{\theta_n\}_{n\in\mathbb{N}}$ with $\mathbb{P}(\theta_n=1)=\mathbb{P}(\theta_n=0)=1/2$. \end{enumerate} Recall the definition of $f_e$ from \S\ref{S:graphical} and set $f_e^1=f_e$ and let $f_e^0$ be the identity function. We modify the definition of the maps $I_{[s,t]}$ from \S\ref{S:graphical} as follows: \[ I_{[s,t]}=f_{e_{\Lambda[0,t]}}^{\theta_{\Lambda[0,t]}}\circ f_{e_{\Lambda[0,t]-1}}^{\theta_{\Lambda[0,t]-1}}\circ\cdots\circ f_{e_{\Lambda[0,s)+1}}^{\theta_{\Lambda[0,s)+1}}. \] The joint distribution of the maps $I_{[s,t]}$, $0\le s\le t<\infty$ is the same as in \S\ref{S:graphical} by the thinning property of the Poisson process. The choice of $k$ in the following setup is relevant for obtaining an upper bound on $\mixIP(\varepsilon)$. The chameleon process is a continuous-time Markov process built on top of the modified graphical construction and consisting of \emph{burn-in periods}, and of \emph{rounds}. We first describe a version in which the duration of each round is a fixed parameter $t_\mathrm{round}$, known as the \emph{round length} and to be chosen in the sequel. This version will be used to prove Theorems~\ref{thm:main1} (general mixing bound) and~\ref{thm:maindeg} (mixing for graphs of high degree). In the chameleon process there is always one particle on each vertex, although not all particles are distinguishable. Each particle has an associated \emph{colour}: one of black, red, pink, and white. Formally, given a $(k-1)$-tuple $\mathbf{z}\in(V)_{k-1}$, let $\mathbf{O}(\mathbf{z}):=\{\mathbf{z}(1),\ldots,\mathbf{z}(k-1)\}$ be the set of coordinates of $\mathbf{z}$. The state space of the chameleon process is given by \begin{align*} &\Omega_k(V):=\\&\{(\mathbf{z},R,K,W):\,\mathbf{z}\in (V)_{k-1},\text{ and sets }\mathbf{O}(\mathbf{z}), R,K,W\text{ partition }V\}. \end{align*} We denote the state at time $t$ of the chameleon process started from $M_0=(\mathbf{z},R,K,W)$ as $M_t=(\mathbf{z}(t),\mathrm{R}_t,\mathrm{K}_t,\mathrm{W}_t)$. We say a particle at vertex $v$ is \emph{black} at time $t$ if $v\in\mathbf{O}(\mathbf{z}(t))$, \emph{red} if $v\in \mathrm{R}_t$, \emph{pink} if $v\in \mathrm{K}_t$, and \emph{white} if $v\in \mathrm{W}_t$. The black particles are distinguishable and their number remains constant throughout the process. We shall also denote the vector of positions of the black particles at time $t$ by $\mathrm{B}_t$ (\textit{i.e.}, $\mathrm{B}_t=\mathbf{z}(t) $). By abuse of notation we write $|\mathrm{B}_t|$ for $|\mathbf{O}(\mathbf{z}(t))|$, the number of black particles (note that $\mathrm{B}_t$ is a vector, not a set). Marginally, the evolution of $\mathrm{B}_t $ is simply that of the interchange process on $k-1 $ particles, starting from $\mathbf{z}$. Conversely, the white (resp.\ pink and red) particles are indistinguishable, and their number changes as time varies. Suppose the chameleon process starts at time 0 from configuration $M_0=(\mathbf{z},R,\eset,W)$. In order to define a quantity $H_t$ we suppose that all particles are either unmarked or marked and at time $t$ all particles are unmarked. Then suppose that at each instance during time interval $(t,t+1)$ at which an edge connecting an unmarked red particle and an unmarked white particle rings we mark both of these particles. We set $H_t$ to be half the number of marked particles at time $t+1$. We make the following definition: \begin{definition} \label{d:p-good} Let $\alpha \in (0,1/4)$ and $t>0$. We say that a configuration $M_0=(\mathbf{z},R,\eset,W)$ of the chameleon process is $(\alpha,t)$-\emph{good} if $$\mathop{\mathbb E}_{M_{0}}[H_t ] \ge 2 \alpha (|R| \wedge |W| ).$$ Let $p(M_0)=p(M_{0},t):=\Pr_{M_{0}}[H_t \ge \alpha (|R| \wedge |W| ) ] .$ \end{definition} For an $(\alpha,t)$-good configuration with $\alpha \le 1/4$, by Markov's inequality \begin{equation} \label{e:p>alpha/2}\begin{split} p(M_0)&=1-\Pr_{M_{0}}[|R| \wedge |W|-H_t \ge (1- \alpha) (|R| \wedge |W| ) ] \\&\ge 1-\sfrac{\mathop{\mathbb E}_{M_{0}}[|R| \wedge |W|-H_t ]}{(1-\alpha) (|R| \wedge |W| )} \ge \sfrac{\alpha}{1-\alpha} \ge \sfrac{4\alpha}{3} . \end{split} \end{equation} Fix some $\alpha \in (0,1/4) $ to be determined later. At time 0, we start with no pink particles. Similarly, at the beginning of each round we have that $\mathrm{K}_t=\eset$. We only start a round once we have an $(\alpha,t_\mathrm{round}-1)$-good configuration. Initially, we let the process make successive burn-in periods, each of duration $t_{\mathrm{mix}}^{(\infty)}(n^{-10})$ and during which the process updates according to the updates of the underlying modified graphical construction, until the first time that at the end of a burn-in period we obtain an $(\alpha,t_\mathrm{round}-1)$-good configuration. Similarly, if at the end of a round the configuration is not $(\alpha,t_\mathrm{round}-1)$-good, then we let the process make successive burn-in periods, each of duration $t_{\mathrm{mix}}^{(\infty)}(n^{-10})$, until the first time that at the end of a burn-in period we obtain an $(\alpha,t_\mathrm{round}-1)$-good configuration. Denote the beginning of the $i$th round by $\rho_i $ and its end by $\hat \tau_i:=\rho_i+t_\mathrm{round} $. We now describe a round of the chameleon process. Each round consists of two phases. The first is a \emph{constant-colour relaxation phase} of duration $t_\mathrm{round}-1$, while the second is a \emph{pinkening phase} of unit length. Loosely speaking, during a round the chameleon process evolves as the underlying interchange process, apart from the fact that pink particles are created by the recolouring of pairs of red and white particles (each pair consisting of a red and a white particle) during events known as \emph{pinkenings}. Whenever an edge $e_j $ rings at some time $\tau_j $ for which the two endpoints are occupied by a red and a white particle at this time, we colour both these particles pink, unless we have already obtained $2 \lceil \alpha (|R| \wedge |W| ) \rceil $ pink particles. \begin{remark} One place in which our chameleon process differs from Oliveira's process is that we will always depink at the end of a round, whereas Oliveira waits to have a substantial number of pink particles before depinking. \end{remark} The updates of the chameleon process during a single round are as follows: \begin{itemize} \item Intervals of time of the form $J_{i}:=(\rho_i,\hat\tau_i-1]$, for $i\in\mathbb{N}$, are \emph{constant-colour phases} during which the chameleon process updates according to the updates of the underlying modified graphical construction, \textit{i.e.}, if $t=\tau_j\in J_{i}$ for some $i\in\mathbb{N}$ then update as \[ (\mathbf{z}(t),\mathrm{R}_t,\eset,\mathrm{W}_t)=(f_{e_j}^{\theta_j}(\mathbf{z}(t_-)),f_{e_j}^{\theta_j}(\mathrm{R}_{t_-}),\eset,f_{e_j}^{\theta_j}(\mathrm{W}_{t_-})). \] \item Intervals of time of the form $\hat J_i:=(\hat\tau_i-1,\hat\tau_i)$, for $i\in\mathbb{N}$, are \emph{pinkening phases} during which we update as in the constant-colour phase except for times $t=\tau_j\in \hat J_i$ at which both 1 and 2 below hold: \begin{enumerate} \item $e_j$ having a red endpoint $r\in \mathrm{R}_{t_-}$ and a white endpoint $w\in \mathrm{W}_{t_-}$, \item $|\mathrm{K}_{t_-}|<2 \lceil \alpha(|\mathrm{R}_{t_-}|\wedge|\mathrm{W}_{t_-}|) \rceil .$ \end{enumerate} For such times we update as \[ (\mathbf{z}_t,\mathrm{R}_t,\mathrm{K}_t,\mathrm{W}_t)=(\mathbf{z}_{t_-},\mathrm{R}_{t_-}\setminus\{r\},\mathrm{K}_{t_-}\cup\{r,w\},\mathrm{W}_{t_-}\setminus\{w\}). \] and call $t$ a \emph{pinkening time}. \item Times of the form $t=\hat \tau_i $, for $i\in\mathbb{N}$, are called \emph{depinking times} and are of two types: \begin{itemize}\item Type 1 if $|\mathrm{K}_{t_-}|=2 \lceil \alpha(|\mathrm{R}_{t_-}|\wedge|\mathrm{W}_{t_-}|) \rceil$ and an independent biased coin $\hat d_i$ is equal to 1, where $\Pr[\hat d_i=1 \mid M_{\rho_i} ]=\sfrac{\alpha/2}{p(M_{\rho_i},t_\mathrm{round}-1)}$ (recall that $\rho_i $ is the beginning of the $i$th round). We then flip an independent fair (un-biased) coin $d_i$. If it lands heads ($d_i=1$) we colour all pink particles red, and if it lands tails we colour all pink particles white. \item Type 2 if $|\mathrm{K}_{t_-}|<2 \lceil \alpha(|\mathrm{R}_{t_-}|\wedge|\mathrm{W}_{t_-}|) \rceil$ or $\hat d_i =0 $. We then uniformly choose half of the pink particles (there is always an even number of pink particles) and colour these red, and the remaining half we colour white. \end{itemize} \end{itemize} Observe that as soon as $\mathrm{R}_t=\eset $ (resp.\ $\mathrm{W}_t = \eset $) it will remain empty while $|\mathrm{W}_s|=n-|\mathrm{B}_0| $ (resp.\ $|\mathrm{R}_s|=n-|\mathrm{B}_0| $) for all $s \ge t$. After such time there will be no additional rounds. Note that by \eqref{e:p>alpha/2} we have that $\Pr[\hat d_i=1 \mid M_{\rho_i} ] \le 1 $ and by definition of $p(\bullet,\bullet)$ we have that the probability of a type 1 depinking at time $\hat\tau_i$ is exactly $\alpha/2 $ for all $i$ (such that $|\mathrm{R}_{\rho_i} | \wedge |\mathrm{W}_{\rho_i} | \neq 0 $). This means that if the number of red particles at the beginning of the round is $r$, then it stays $r$ w.p.\ $1-\alpha/2 $ and otherwise with equal probability it changes to $r \pm \Delta(r) $, where $\Delta(r):=\lceil \alpha [r \wedge |\mathrm{W}_{\rho_i} | ] \rceil=\lceil \alpha [r \wedge (n-|\mathrm{B}_0| ) ] \rceil $. For $M_0=(B,R,\varnothing,W)$ let $\hat M_t:=(\hat\mathrm{B}_t,\hat\mathrm{R}_t,\hat\mathrm{W}_t)$ be the configuration at time $t$ obtained from the modified graphical construction with $\hat\mathrm{B}_0=B$, $\hat\mathrm{R}_0=R$ and $\hat\mathrm{W}_0=W$, \textit{i.e.}\ without any colour-changing of particles. The definition of $(\alpha,t)$-good extends naturally to the process $\hat M_t$. Let $t_0:= t_{\mathrm{mix}}^{(\infty)}(n^{-10}) $ and \begin{equation} \label{e:beta1}\begin{split} &\beta(\alpha,t):= \max_{B,R,W}\sup_{s \ge t_{0} } \Pr[\hat M_s \text{ is not $(\alpha,t)$-good} \mid \hat M_0=(B,R,W)],\end{split} \end{equation} where the maximum is taken over all partitions of $V$ into sets $\mathbf{O}(B),R,W$ with $B \in (V)_j $ for some $j \le n/2$ satisfying $\{B(i):i \in [j] \} =\mathbf{O}(B) $. Recall the definition of $r_\ast(\epsilon)$ in \eqref{eq:rast}. For each $\epsilon\in(0,1)$, we define similar quantities: \begin{equation} \label{e:ts_*} \begin{split} & t_\ast(\epsilon):=\inf \{t:\max_{v \in V}P_t(v,v)-1/n \le \sfrac{\epsilon}{\log n} \}, \\ & s_\ast(\epsilon):=\inf \{t:\max_{v \in V}P_t(v,v)-1/n \le \sfrac{\epsilon}{t_\ast(\epsilon)} \}. \end{split} \end{equation} For the proof of Theorem~\ref{thm:main1} (general mixing bound) we will show that for some positive constants $\alpha,C_\mathrm{round},\epsilon $, if we take $$t_\mathrm{round}=C_\mathrm{round}(\rel + t_{\ast}(\epsilon)+s_{\ast}(\epsilon))+1$$ we have that $\beta(\alpha,t_\mathrm{round}-1) \le n^{-10} $. We state this as the following proposition. \begin{proposition}\label{P:beta} There exist constants $\epsilon,\alpha, C_\mathrm{round} >~0 $, such that for all $n$ sufficiently large \[\beta(\alpha,C_\mathrm{round}(\rel+t_\ast(\epsilon)+s_\ast(\epsilon)))\le n^{-10}.\] \end{proposition} We will explain in \S\ref{s:proofofmain} how this implies the assertion of Theorem \ref{thm:main1} (general mixing bound). For Theorem~\ref{thm:maindeg} (mixing for graphs of high degree) we show that it suffices to take $t_\mathrm{round}=C_\mathrm{round}\rel +1 $, see Proposition~\ref{P:betadeg} (which is the analogue of the previous proposition). The situation is more involved for the proof of Theorem~\ref{thm:main3} (mixing for sublinear number of particles), see \S\ref{SS:thm2proof}. \subsection{Further technical results}\label{SS:technical} We present the key tools regarding the chameleon process that, together with Proposition~\ref{P:beta}, will be used to complete the proof of Theorem~\ref{thm:main1} (general mixing bound) in the following subsection. Following Oliveira \cite{olive} we introduce a notion of \emph{ink}, which represents the amount of \emph{redness} either at a vertex or in the whole system. We write $\mathrm{ink}_t(v)$ for the amount of ink at vertex $v$ at time $t$ defined as $ \mathrm{ink}_t(v):=\indic{v\in \mathrm{R}_t}+\frac12\indic{v\in \mathrm{K}_t}, $ and the amount of ink in the whole system at time $t$ as $ \mathrm{ink}_t:=|\mathrm{R}_t|+\frac12|\mathrm{K}_t|. $ Notice that, by the construction of the chameleon process, the value of $\mathrm{ink}_t$ can only change at depinking times of Type 1. The following proposition links the amount of ink at a vertex to the probability that vertex is occupied by the $k$-th particle, in a $k$-particle interchange process. The statement is identical to Proposition~5.2 of Oliveira (the difference being our chameleon process is constructed slightly differently). The proof is almost identical to the proof of Lemma 1 of \cite{morris}, and we include our version for completeness. \begin{proposition}[{Proof in Appendix~\ref{A:expink}}] \label{p:inkatb} Consider a realisation $(\mathbf{x}(t))_{t\ge0}$ of the $k$-particle interchange process started from configuration $\mathbf{x}=(\mathbf{z},x)$ and a corresponding chameleon process started from configuration $(\mathbf{z},\{x\},\varnothing,V\setminus(\mathbf{O}(\mathbf{z})\cup\{x\}))$. Then for each $t\ge0$ and $\mathbf{b}=(\mathbf{c},b)\in (V)_k$, $\mathbf{c} \in (V)_{k-1}$, \[ \Pr^\mathrm{IP(k)}[\mathbf{x}(t)=\mathbf{b}]=\mathbb{E}\left[\mathrm{ink}_t(b)\indic{\mathbf{z}(t)=\mathbf{c}}\right]. \] \end{proposition} \begin{remark} Right after we colour two particles pink, since we do not reveal whether the edge ring of the edge connecting them was ignored or not, we cannot tell which one of them is at which location. The action of colouring them by pink symbolizes this uncertainty, which is the real reason that the assertion of the last proposition holds. \end{remark} The next observation is that $\mathrm{ink}_t$ is a martingale. This can be readily checked from the behaviour of the chameleon process at depinking times. Moreover as $t\to\infty$, $\mathrm{ink}_t$ converges to one of the two absorbing states 0 and $=n-k+1$. We define $\mathrm{Fill}$ as the event that this limit is $n-k+1$, \textit{i.e.}, that eventually the only particles present in the system are red and black. One consequence of the martingale property of $\mathrm{ink}_t$ is that $\Pr[\mathrm{Fill}]=(n-k+1)^{-1}.$ \begin{lemma}[cf.\ \cite{olive} proof of Lemma 7.2] \label{L:Fill} The event ${\mathrm{Fill}} $ is independent of $(\mathrm{B}_t:t \ge 0)$. \end{lemma} \noindent \emph{Sketch proof:} This follows from the fact that the coins $(d_i:i \in \mathbb N)$ are independent of the coins $(\hat d_i:i \in \mathbb N)$ and of the graphical representation. \qed \\ \\ Let us write $\mathbb{\widehat E} $ and $\mathrm{\widehat P} $ for the expectation and probability conditioned on the event ${\mathrm{Fill}}$. We may add subscript $(\mathbf{w},y) \in (V)_k $ such that $\mathbf{w} \in (V)_{k-1}$ and $y \in V $ to indicate that the initial configuration of the interchange process is $(\mathbf{w},y) $ and thus for the chameleon process $\mathrm{R}_0=y $ and $\mathrm{B}_t=\mathbf{w}(t)$ for all $t$, where $\mathbf{w}(t)=(\mathbf{w}_{1}(t),\ldots,\mathbf{w}_{k-1}(t))$ is the vector of the positions of the first $k-1$ co-ordinates at time $t$. In this case, we let $y(t)$ denote the position of the $k$-th co-ordinate at time $t$. The main inequality relating the total-variation distance to the chameleon process is the following: \begin{proposition}[{\cite[Lemma 2]{morris}, \cite[Lemma 6.1]{olive}; proof in Appendix~\ref{s:p4.6}]}] \label{p:chambound} Let $\Delta_{\mathbf{x},\mathbf{y}}(t)$ be as in \eqref{e:trianglein}. Then \begin{equation} \label{e:IPtoCP} \max_{\mathbf{x},\mathbf{y} \in (V)_k }\Delta_{\mathbf{x},\mathbf{y}}(t) \le 2k \max_{(\mathbf{w},y)\in (V)_k:\mathbf{w}\in (V)_{k-1},y \in V } {\mathbb{\widehat{E}}}_{(\mathbf{w},y)}[ 1 - {\mathrm{ink}}_t / (n-k+1) ]. \end{equation} \end{proposition} The following proposition, which is essentially Proposition B.1 in \cite{olive}, allows us to bound the r.h.s.\ of \eqref{e:IPtoCP}. For $j\in\mathbb{N}$, we define event \[A(j):=\{\text{config.\! at time }t(j) \text{ is not }(\alpha,t_\mathrm{round}-1)\text{-good}\}.\] The term $t_{\mathrm{mix}}^{(\infty)}(n^{-10}) $ below corresponds to the initial burn-in period, while the error term $\widehat{\Pr}_{(\mathbf{w},y)}[\cup_{j=0}^{i-1} A(j) ] $ corresponds to the probability that additional burn-in periods occurred by the end of the $i$th round (\textit{i.e.}, that at time $t(j):=t_{\mathrm{mix}}^{(\infty)}(n^{-10})+j t_\mathrm{round} $ the configuration was not good). Hence, the assertion of the proposition is that the expected fraction of ``missing ink" $ 1 - {\mathrm{ink}}_t / (n-k+1) $ decays exponentially in the number of rounds. \begin{proposition}[{Proof in Appendix~\ref{A:2}]}] \label{p:chambound2} There exists $c_{\alpha} \in (0,1) $ such that for all $i \in \mathbb N $ and $(\mathbf{w},y)\in (V)_k $, \begin{equation} \label{e:IPtoCP'} \begin{split} {\mathbb{\widehat{E}}}_{(\mathbf{w},y)}[ 1 - {\mathrm{ink}}_{t(i)} / (n-k+1) ] & \le \sqrt{n-k+1} c_{\alpha}^i+ \widehat{\Pr}_{(\mathbf{w},y)}[\cup_{j=0}^{i-1} A(j) ] \\ & \le \sqrt{n-k+1} c_{\alpha}^i+(\Pr[\mathrm{Fill}])^{-1} \Pr_{(\mathbf{w},y)}[\cup_{j=0}^{i-1} A(j) ] \\&\le \sqrt{n-k+1} c_{\alpha}^i + i (n-k+1) \beta(\alpha,t_\mathrm{round}-1). \end{split} \end{equation} \end{proposition} \subsection{Proof of Theorem \ref{thm:main1} (general mixing bound) } \label{s:proofofmain} \begin{proof} Firstly, recall again that for $n$-vertex regular graphs, $P_t(v,v)-\sfrac{1}{n} \lesssim (t+1)^{-1/2} $ from which it follows that there exists a universal constant $\kappa$ such that for any $\epsilon\in(0,1)$ $t_\ast(\epsilon)+s_\ast(\epsilon)\le 2 r_\ast(\epsilon^3/\kappa^2)$. Next, using sub-multiplicativity \cite[p.\ 54]{levin} we have that $\mixex((2n)^{-i})$ $\le i\mixex(\sfrac{1}{4n})$. It follows that it suffices to consider $\varepsilon=\sfrac{1}{4n}$. We may assume $n $ is at least some sufficiently large constant $N$ (this was implicitly/explicitly used in several places), as there are only finitely many graphs for $n\le N$ (and hence finitely many processes, since we assume edge-rates are all $1/d$). Combining Propositions \ref{P:beta}, \ref{p:chambound} and \ref{p:chambound2} concludes the proof (use Proposition \ref{p:chambound2} with $i = \lceil \sfrac{4}{1-c_{\alpha}} \log n \rceil $, noting that the term $t_{\mathrm{mix}}^{(\infty)}(n^{-10})$ in the definition of $t(i)$ is $\lesssim \rel \log n$). \end{proof} \section{An overview of our approach} \label{s:overview} The approach taken by Oliveira \cite{olive} is to let the constant-colour and the pinkening phases both be of order $\mix^{\mathrm{EX}(2)}$. The two main steps in his analysis are (i) to show that $\mix \asymp \mix^{\mathrm{EX}(2)}$ and (ii) by the choice of the duration of the constant-colour phase, using a delicate negative correlation argument deduce that with probability bounded from below a certain fraction of the red (or white, whichever set is of smaller size) particles will become pink in each pinkening phase. Both steps are much more difficult than what one might expect. As explained below, assuming regularity allows us to take our pinkening phase to be of duration of one time unit. Since the red and the white particles play symmetric roles, we may assume that at the end of the last round prior to the current time we have $r \le (n-k+1)/2 $ red particles (\textit{i.e.}, there are at least as many white particles as there are red; otherwise, switch their roles in what comes). We now sketch the main ideas behind the proof of Proposition \ref{P:beta} in more detail. We will focus in this section and in \S\ref{S:neighbours}--\ref{S:loss} on graphs with degree $d$ satisfying $d\ge 10^4$, and describe how to extend the argument to all $d$ in \S\ref{SS:smalld}. In order for a configuration to be $(\alpha,t)$--good for some constant $\alpha$, it suffices that (given the current configuration) with probability bounded from below, after $t$ time units, at least some $c$-fraction of the red particles will have at least a $c$-fraction of their neighbours white. To see this, observe that if a red particle has $j \ge cd$ white neighbours, the chance an edge connecting it to any of them rings before the two particles at its end-point moved is $ \frac{ j}{2d-1}=\Omega(c)$ (and the probability this happens in at most 1 time unit is $\Omega(c) $). Observe that if (at the end of a constant-colour phase) a vertex has at most $(\sfrac{r}{n}+\sfrac{c}{4})d$ red neighbours and at most $(\sfrac{k-1}{n}+\sfrac{c}{4})d $ black neighbours, then it has at least $\ssfrac{1}{2}(1-\sfrac{k-1}{n}-c)d \ge (\sfrac{1}{4}-\sfrac{c}{2})d $ white neighbours (as $r \le \ssfrac{1}{2}(n-k+1)$). Hence, instead of controlling the number of white neighbours of a vertex, conditioned on it being red, we may control the number of red neighbours and the number of black neighbours separately. This is done is \S\ref{S:redvred} and \S\ref{S:redvblack}, respectively. We say that two particles \emph{interacted} if an edge connecting them rang. Exploiting the CNA property in conjunction with $L_2$-contraction considerations allows us to control the number of red with red interactions during the pinkening phase, provided that $t_\mathrm{round}-1 \ge C \rel $. \textcolor{black}{This $L_2$ argument is the key that allows us to avoid taking $t_\mathrm{round} \ge C \mix $, as Oliveira does.} Controlling the number of red with black interactions during a pinkening phase requires exploiting the NA property to derive certain large deviation estimates for the occupation measure of the black particles, as well as a certain decomposition which allows us to overcome the dependencies between the black and the red particles. \textcolor{black}{This is the most difficult and subtle part of the argument.} \subsection{Controlling red neighbours: an overview} It turns out that controlling the number of red neighbours is the easy part. Observe that the dynamics performed by the red particles during a single constant-colour phase of the chameleon process is simply a symmetric exclusion process. Thus by NA if given $\mathrm{R}_{\rho_i} $ (recall that $\rho_i $ is the beginning of the $i$th round) the expected number of red particles neighbouring vertex $v$ at time $\rho_i+ t_\mathrm{round}-1$ is at most $( \sfrac{r}{n}+c)d $, the (conditional) probability (given $\mathrm{R}_{\rho_i}$) of having more than $ ( \sfrac{r}{n}+2c)d $ red particles around vertex $v$ at time $\rho_i+ t_\mathrm{round}-1$ can be made arbitrary small, provided $d$ is large enough (as explained above, we may assume the degree is arbitrarily large; where $c>0$ is some small absolute constant). Crucially, by CNA the same holds even when we condition on $v$ being occupied by a red particle at the end of the constant-colour phase (\textit{i.e.}, at time $\rho_i+ t_\mathrm{round}-1 $). This motivates considering the following set for round $i$: \begin{equation} \label{e:nicei}\begin{split} &\mathrm{Nice}(i):=\\&\{v: \text{expected no.\! red neighbrs of $v$ in }t_\mathrm{round}-1 \text{ time units} \le d( \sfrac{|\mathrm{R}_{\rho_i}|}{n}+ c) \}, \end{split}\end{equation} where the expectation inside the event above is conditional on $\mathrm{R}_{\rho_i}$. It suffices to control the expected number of red particles which lie in $\mathrm{Nice}(i) $ at the end of the constant-colour phase of the $i$th round, as by the above reasoning it is very unlikely for each such red particle to have more than $d( \frac{|\mathrm{R}_{\rho_i}|}{n}+ 2c)$ red neighbours at that time. Using NA one can argue that if the last expectation is large, then the actual number of such red particles is unlikely to deviate from it by a lot. However, it turns out to not be necessary for our purposes. To control the aforementioned (conditional) expectation (given $\mathrm{R}_{\rho_i}$) we observe that the last expectation equals \begin{equation} \label{e:Pnicecomp} |\mathrm{R}_{\rho_i}| \Pr_{\mathrm{Unif}(\mathrm{R}_{\rho_i})}[X_{t_\mathrm{round}-1} \in \mathrm{Nice}(i)]. \end{equation} By Proposition~\ref{prop: Lagrange} and some algebra (see Lemma \ref{L:piNice} for the actual details) we deduce that if $ \Pr_{\mathrm{Unif}(\mathrm{R}_{\rho_i})}[X_{t_\mathrm{round}-1} \in \mathrm{Nice}(i)]$ is smaller than $\pi(\mathrm{Nice}(i))-c $, then we must have that the $L_2$ distance of $\Pr_{\mathrm{Unif}(\mathrm{R}_{\rho_i})}[X_{t_\mathrm{round}-1} \in \bullet] $ from $\pi$ is proportional to $\sfrac{1}{\sqrt{ \pi(V \setminus \mathrm{Nice}(i))}} $. By a simple counting argument (see Lemma \ref{L:niceC}), we must have that \begin{equation} \label{e:countingargument} |V \setminus \mathrm{Nice}(i)| \lesssim |\mathrm{R}_{\rho_i}|, \end{equation} which means that the last $L_2$ distance is $\gtrsim \sfrac{1}{\sqrt{ \pi(\mathrm{R}_{\rho_i})}} \asymp \|\mathrm{Unif}(\mathrm{R}_{\rho_i}) - \pi \|_{2,\pi}$. In simple words, if the duration of the constant-colour relaxation phase is such that the $L_2$ distance from the uniform distribution of a random red particle, chosen uniformly at random, drops by the end of the phase by some sufficiently large constant factor, compared to its value at the beginning of the round (which is $\|\mathrm{Unif}(\mathrm{R}_{\rho_i}) - \pi \|_{2,\pi}$), then with a large probability (in some quantitative manner) a certain fraction of the red particles will have few red neighbours at the end of the relaxation phase (Lemma~\ref{L:piNice}). Using the Poincar\'e inequality \eqref{e:Poincare} it follows from our choices of the durations of the rounds that the aforementioned $L_2$ distance indeed drops by a constant factor, which can be made arbitrarily large by adjusting the constant $C_\mathrm{round}$. \textcolor{black}{For the sake of being precise, we note that the above argument breaks down when $|\mathrm{R}_{\rho_i}| \wedge |\mathrm{W}_{\rho_i}| \ge \varrho_0 n $ for a certain $\varrho_0$ depending on the choice of $c$. Fortunately, in this regime we can work directly with the white particles and argue that at the end of the constant colour phase the expected number of red particles with at least $c\varrho_0 d$ white neighbours is of order $n$. This will be obtained as a relatively simple consequence of the Poincar\'e inequality, and only requires the duration of a round to be $\Omega(\rel) $. } \subsection{Controlling black neighbours: an overview}\label{s:blackoverview}Controlling the number of black neighbours turns out to be a much harder task. By abuse of notation (treating $\mathrm{B}_{t}$ and $\mathrm{B}_{t+s} $ as sets) consider \begin{equation} \label{e:Zvts} Z_v(t,s):=\sum_{u}\Ind{u \in \mathrm{B}_t}P_s(u,N(v))=\mathop{\mathbb E}[ |\mathrm{B}_{t+s} \cap N(v)| \bigm| \mathrm{B}_t ] , \end{equation} where $N(x) $ is the neighbour set of vertex $x$. Using the NA property it is not hard to show (see Lemma \ref{L:largedev}) that if $(\Ind{u \in \mathrm{B}_0}:u \in V) $ has marginals close to $k/n $ (\textit{i.e.}, after a burn-in period) then $\Pr[Z_v(t,s) > (\frac{k}{n}+c)d]$ decays exponentially in $\sfrac{1}{\max_{x,y}P_s(x,y)} $ for all $s$ and $v \in V $. This estimate, which is one of the key ideas in this work, is inspired from the proof of the main result in \cite{BH} (and a variant of that result whose proof also utilized NA). If $s \ge t_{\ast}(\epsilon)$ it is immediate from the definition of $t_*(\epsilon)$, that $\max_{x,y}P_s(x,y) \le \sfrac{\epsilon}{\log n} $ and so this probability is $\ll n^{-20} $ for suitably chosen $\epsilon$. Unfortunately, this does not yield the desired conclusion, since conditioned on having a red particle at $v$ at time $t+s$ changes the distribution of the number of black neighbours of $v $ at that time. To overcome this difficulty, we have to take the duration of the round to be $ t_\mathrm{round}:=C_{\mathrm{round}}( t_{\ast}(\epsilon) +s_{*}(\epsilon) +\rel)+1 $, and consider two cases. We show that for each red particle, the expected number of neighbouring particles it has at the end of the constant-colour relaxation phase, which interacted with it during the first $t_*(\epsilon) $ time units of the round can be made at most $cd$, provided we take $C_{\mathrm{round}} $ to be large enough (see Lemma~\ref{L:interact}). This is obtained by exploiting the definition of $s_*(\epsilon)$, along with a delicate use of negative correlation. Lastly, we show that a variant of the aforementioned large deviation estimate applies to the black particles that did not interact during the first $t_*(\epsilon) $ time units of the round with the considered red particle, and that for such black particles we need not worry about the dependencies with this red particle. \section{Results to control neighbours of red particles}\label{S:neighbours} \subsection{The red neighbours}\label{S:redvred} Recall that $P_t$ is the heat-kernel of a single walk on $G$. We write $T$ for $t_\mathrm{round}-1$, \emph{i.e.}\ $T$ denotes the length of a constant-colour phase. Motivated by \eqref{e:nicei} and the following paragraph we make the following definition. \begin{definition} For each subset $S\subseteq V$, let $e_T(v,S):=\sum_{u:\,v \sim u}P_T(u,S) $ and define $\mathrm{Nice}(S)$ as: \[ \mathrm{Nice}(S):=\Big\{v\in V:\,e_T(v,S)< d\left(\sfrac1{32}+\sfrac{|S|}{n}\right)\Big\}. \] \end{definition} \begin{remark} We will later (see \S\ref{SS:smalld}) modify this definition by replacing adjacency with proximity. This will allow us to deal with the case of small degree. \end{remark}From this definition we see that the set $\mathrm{Nice}(S)$ consists of vertices which have ``few" neighbours (in expectation) at time $T$ which came from (at time 0) the set $S$. The reader should think of $S$ as the set occupied by the red particles at the beginning of a round. In \S\ref{S:loss} we make use of this definition with $S$ being the set of red vertices. Motivated by \eqref{e:countingargument}, we now lower-bound the size of $\mathrm{Nice}(S)$ by a simple counting argument, involving only its definition: \begin{lemma}\label{L:niceC} For each $S\subseteq V$, \[ |\mathrm{Nice}(S)^\complement|\le \left(\sfrac1{32}+\sfrac{|S|}{n}\right)^{-1}|S|. \] \end{lemma} \begin{proof} The definition of $\mathrm{Nice}(S)$ yields that $ d\left(\sfrac1{32}+\sfrac{|S|}{n}\right)|\mathrm{Nice}(S)^\complement|=\sum_{v\in \mathrm{Nice}(S)^\complement} d\left(\sfrac1{32}+\sfrac{|S|}{n}\right) $ is \begin{align*} \le \sum_{v\in \mathrm{Nice}(S)^\complement}\sum_{u:\,v \sim u}P_T(u,S) \le \sum_u\sum_{v:\,v \sim u}P_T(u,S)=d|S|, \end{align*}which proves the result. \end{proof} \begin{remark} The analogous result which is used for the small degree case is Lemma~\ref{L:niceC2}. \end{remark} The next lemma (motivated by \eqref{e:Pnicecomp}) gives a bound on the probability that a random walk started uniformly from set $S$ is in $\mathrm{Nice}(S)$ at time $T$. The proof uses Proposition~\ref{prop: Lagrange} combined with the Poincar\'e inequality \eqref{e:Poincare}. \begin{lemma}[{Proof in Appendix~\ref{proofpiNice}]}]\label{L:piNice} Denote the uniform distribution on $S$ by $\pi_S $. For each $\varepsilon\in(0,1)$, there exist $C_{\ref{L:piNice}}(\varepsilon)>1$ such that for all $C_\mathrm{round}>C_{\ref{L:piNice}}(\varepsilon)$ and all $S\subset V$ with $2|S|\le n$, \[\Pr_{\pi_S}[X_T\in\mathrm{Nice}(S)]\ge\pi(\mathrm{Nice}(S))-\varepsilon.\] \end{lemma} \begin{remark} See Lemma~\ref{L:piNice2} for the version of this result to be used in the proof of Theorem~\ref{thm:main3} (mixing for sublinear number of particles). \end{remark} For $S\subseteq V$ we define $N(S):=\mathrm{Nice}(S)\cap I_{[0,T]}(S)$, which are the $\mathrm{Nice}(S)$ vertices occupied at time $T$ by particles initially in $S$, and further for $\theta\in(0,1)$, we define a subset of $N(S)$ as \[ BN(S)_\theta:=\Big\{v\in N(S):\,\sum_{u:\,v \sim u}\indic{I_{[0,T]}^{-1}(u)\in S}>\theta d\Big\}, \] which are the $N(S)$ vertices which have ``many" ($>\theta d $) neighbours also occupied at time $T$ by particles initially in $S$. Similarly, we define a set $GN(S)_\theta$ to be $N(S)\setminus BN(S)_\theta$ (here the $B$ in $BN(S)_{\theta}$ stands for ``bad" and the $G$ in $GN(S)_{\theta}$ for ``good"). We control the number of such vertices with the following lemma (think of $\theta$ below as being in $(\sfrac{|S|}{n}+\sfrac{1}{32},\sfrac{|S|}{n}+\sfrac{1}{16}]$, and observe that for such $\theta$ we may pick $\lambda>0$ sufficiently small such that $-\lambda\theta+(e^\lambda-1)\left(\sfrac1{32}+\sfrac{|S|}{n}\right) \le -c \lambda$). \begin{lemma}\label{L:BNR} For each $S\subseteq V$, $\theta\in(0,1)$, $\lambda>0$ and $v\in V$, \[ \Pr[v\in BN(S)_\theta\mid v\in N(S)]<\exp\left\{ d\left(-\lambda\theta+(e^\lambda-1)\left(\sfrac1{32}+\sfrac{|S|}{n}\right)\right)\right\}. \] \end{lemma} \begin{remark} Proving this lemma relies crucially on the CNA property. See Lemma~\ref{L:BNR2} for the version of this result for small degree graphs. \end{remark} \begin{proof}For each $v\in\mathrm{Nice}(S)$ and $\lambda>0$, \begin{align*} \Pr[v\in BN(S)_\theta|\,v&\in N(S)]=\Pr\left[\sum_{u:\,v \sim u}\indic{I^{-1}_{[0,T]}(u)\in S}>\theta d \Bigm| v\in I_{[0,T]}(S)\right]\\ \mbox{(Chernoff)}\qquad&\le e^{-\lambda\theta d}\,\mathbb{E}\left[\exp\left\{\lambda\sum_{u:v \sim u}\indic{I^{-1}_{[0,T]}(u)\in S}\right\}\Bigm|v\in I_{[0,T]}(S)\right]\end{align*}\begin{align*} \mbox{(CNA then NA)}\qquad&\le e^{-\lambda\theta d}\prod_{u:\,v \sim u}\mathbb{E}\left[\exp\left\{\lambda\indic{I^{-1}_{[0,T]}(u)\in S}\right\}\right]\\ &=e^{-\lambda\theta d}\prod_{u:\,v\sim u}\left(1+(e^\lambda-1)\Pr[u\in I_{[0,T]}(S)]\right)\\ (1+x\le e^x)\qquad&\le e^{-\lambda\theta d}\exp\left\{\sum_{u:\,v \sim u}(e^\lambda-1)\Pr[u\in I_{[0,T]}(S)]\right\}\\ &=\exp\left\{-\lambda\theta\hat d+(e^\lambda-1)\sum_{u:\,v \sim u}P_T(u,S)\right\}\\ (v\in \mathrm{Nice}(S))\qquad&<\exp\left\{d\left(-\lambda\theta+(e^\lambda-1)\left(\sfrac1{32}+\sfrac{|S|}{n}\right)\right)\right\}, \end{align*}as required. \end{proof} \subsection{The black neighbours}\label{S:redvblack} Recall the modified graphical construction from \S\ref{SS:cham_desc}. Recall also that an \emph{interaction} occurs between two particles occupying vertices $u,v$ in the exclusion/interchange process (constructed using the modified graphical construction as described in~\S\ref{SS:cham_desc}) when edge $\{u,v\}$ rings. For $a,b\in V$, and $t\ge0$, let $N_{t}(a,b)$ denote the number of interactions during time interval $[0,t]$ of the particles at vertices $a$ and $b$ at time 0. For each $v\in V$ and $0\le t<T$, we also define a random variable $\hat N_{t}(v)$ to be the number of interactions during time interval $[0,t]$ of the particle at vertex $v$ at time $0$ with its time-$T$ neighbours, \textit{i.e.}, \[ \hat N_{t}(v):=\sum_{u:\, I_{[0,T]}(v) \sim u}N_{t}(v,I^{-1}_{[0,T]}(u)). \] The next lemma gives control on the expected value of $\hat N_{t_\ast(\epsilon)}(v)$. We will apply this to control the expected number of black particles which interact with red particles during time interval $[0,t_\ast]$ for any initial configuration of black and red particles. \begin{lemma}\label{L:interact} For all $\epsilon\in(0,1)$ and $C_\mathrm{round}\ge 1$ we have \[\max_{v\in V}\mathbb{E}[\hat N_{t_\ast(\epsilon)}(v)]\le 8d\epsilon.\] \end{lemma} \begin{remark} The proof of this lemma makes use of the NA property. See Lemma~\ref{L:interact2} for the version of this result for small degree graphs. \end{remark} \begin{proof} We first write \begin{align*} \hat N_{t_\ast(\epsilon)}(v)&=\sum_u\indic{ I_{[0,T]}(v) \sim u }N_{t_\ast(\epsilon)}(v,I^{-1}_{[0,T]}(u))\\&=\sum_w\indic{ I_{[0,T]}(v) \sim I_{[0,T]}(w) }N_{t_\ast(\epsilon)}(v,w). \end{align*} Let $\tilde N_t(v,w)$ denote the amount of time particles from $v$ and $w$ spend adjacent during the time interval $[0,t]$. We claim that for each $w\in V$, and $0\le t<T$, \[ \mathbb{E}\left[\indic{I_{[0,T]}(v) \sim I_{[0,T]}(w)}N_t(v,w)\right]=\sfrac2d\,\mathbb{E}\left[\indic{I_{[0,T]}(v) \sim I_{[0,T]}(w) }\tilde N_t(v,w)\right]. \] To see this, notice that conditionally on the unordered pair of trajectories $\{I_{[0,t]}(v),I_{[0,t]}(w)\}$, the number of times particles started from vertices $v$ and $w$ interact is Poisson with parameter $\frac2{d}\tilde N_t(v,w)$ (as these interactions do not affect the unordered pair of trajectories). Therefore we have \begin{align*} & \frac{d}{2} \mathbb{E}[\hat N_{t_\ast(\epsilon)}(v)]\\&= \sum_w\mathbb{E}\left[\indic{I_{[0,T]}(v) \sim I_{[0,T]}(w) }\tilde N_{t_\ast(\epsilon)}(v,w)\right]\\ &=\int_0^{t_\ast(\epsilon)}\sum_w\mathbb{E}\left[\indic{I_{[0,T]}(v) \sim I_{[0,T]}(w) }\indic{I_{[0,s]}(w)\sim I_{[0,s]}(v)}\right]ds\\ &=\int_0^{t_\ast(\epsilon)}\sum_w\sum_{a,b:\,a\sim b}\mathbb{E}\left[\indic{I_{[s,T]}(a)\sim I_{[s,T]}(b)}\indic{I_{[0,s]}(w)=b,\, I_{[0,s]}(v)=a}\right]ds\\ &=\int_0^{t_\ast(\epsilon)}\sum_{a,b:\,a\sim b}\mathbb{E}\left[\indic{I_{[0,s]}(v)=a}\indic{I_{[s,T]}(a)\sim I_{[s,T]}(b)} \right]ds\\ &=\int_0^{t_\ast(\epsilon)}\sum_{a,b:\,a\sim b}\Pr[I_{[0,s]}(v)=a]\,\Pr[I_{[s,T]}(a)\sim I_{[s,T]}(b)]ds\\ &=\int_0^{t_\ast(\epsilon)}\sum_{a,b:\,a\sim b}\Pr[I_{[0,s]}(v)=a]\sum_{c,d:\,c\sim d}\Pr\left[I_{[s,T]}(a)=c,\, I_{[s,T]}(b)=d\right]ds\\ &\le \int_0^{t_\ast(\epsilon)}\sum_{a,b:\,a\sim b}\Pr[I_{[0,s]}(v)=a] \\&\phantom{\le \sfrac2{d}\int_0^{t_\ast(\epsilon)}}\cdot\sum_{c,d:\,c\sim d}\Pr\left[I_{[s,T]}(a)\in\{c,d\}\right]\,\Pr\left[I_{[s,T]}(b)\in\{c,d\}\right]ds, \end{align*} where the last line follows from the NA property. Now, since $T\ge t_\ast(\epsilon)+s_\ast(\epsilon)$, for each $0\le s\le t_\ast(\epsilon)$ we have that $T-s \ge s_\ast(\epsilon)$ and so \[ \Pr[I_{[s,T]}(b)\in\{c,d\}]\le \max_{b,c,d}\Pr[I_{[0,s_\ast(\epsilon)]}(b)\in\{c,d\}]\le \frac{2\epsilon}{t_\ast(\epsilon)}. \] We thus obtain \begin{align*} &\mathbb{E}[\hat N_{t_\ast(\epsilon)}(v)]\\&\le\ \frac{4\epsilon}{dt_\ast(\epsilon)}\int_0^{t_\ast(\epsilon)}\sum_{a,b:\,a\sim b}\Pr[I_{[0,s]}(v)=a]\sum_{c,d:\,c\sim d}\Pr\left[I_{[s,T]}(a)\in\{c,d\}\right]ds\\ & \le \frac{8d\epsilon}{dt_\ast(\varepsilon)} \int_0^{t_\ast(\varepsilon)}\sum_{a,b:\,a\sim b}\Pr[I_{[0,s]}(v)=a]\,ds\le 8d\epsilon .\qedhere \end{align*} \end{proof} Motivated by the discussion in \S\ref{s:overview}, for each $a,u,x,v\in V$ and $\epsilon \ge0$, we define \begin{equation} \label{e:Q(a)} Q(a)=Q(a,u,x,v,\epsilon):=\Pr\left[I_{[0,T]}(a)=u,\,N_{t_\ast(\epsilon)}(a,x)=0\bigm| I_{[0,T]}(x)=v\right].\end{equation} The next lemma gives the large-deviation bound (for any initial configuration of black and red particles) on the number of black particles which are time-$T$ neighbours with a red particle and which do not interact with that red particle during time interval $[0,t_\ast(\epsilon)]$. The proof is similar to the proof of Lemma~\ref{L:BNR} in that it revolves around a Chernoff bound and the NA property. \begin{lemma}[{Proof in Appendix~\ref{proofoflargedev}]}]\label{L:largedev} Fix $\epsilon\in(0,10^{-4}]$ and let $Q(a)=Q(a,u,x,v,\epsilon)$ be as in \eqref{e:Q(a)}. There exists $n_0$ such that for all $n\ge n_0$ we have for all $2 \le k\le n/2$, all $u,x,v\in V$, and all $B\in (V)_{k-1}$, \[ \sup_{s\ge t_{\mathrm{mix}}^{(\infty)}(n^{-10})} \Pr\left[\sum_{a\in V}\indic{a\in \mathrm{B}_{s}}Q(a)>\frac{k}{n}+\frac1{16}\Bigm| \mathrm{B}_0=B\right]\le n^{-13}. \] \end{lemma} \begin{remark} The large deviation bound on the black particle measure needed for the proofs of Theorems~\ref{thm:main3} (mixing for sublinear number of particles) and~\ref{thm:maindeg} (mixing for graphs of high degree) is Lemma~\ref{L:black}.\end{remark} \section{Loss of red in a round: proof of Proposition~\ref{P:beta} for $d\ge 10^4$}\label{S:loss} In this section we prove Proposition~\ref{P:beta} for $d\ge 10^4$. We begin with some new definitions. For each $a\in V$, let $\phi_a$ be the first time of the form $\tau_j\in(T,T+1)$ for which $a\in e_j$ (setting $\phi_a=\infty$ if no such time exists). If $\phi_a<\infty$, then define $F_a=I^{-1}_{(T,\phi_a)}(b)$ where $b$ is the other vertex on edge $e_j$; if instead $\phi_a=\infty$ then we write $F_a=\ast$. (This notation is similar to that appearing in \cite[Sec.\ 9.2]{olive}.) Recall also the definition of an $(\alpha,t)$-good configuration from Definition~\ref{d:p-good}. We determine the kinds of configurations that are $(\alpha,T)$-good. \begin{lemma}\label{L:redloss} Suppose $d\ge10^4$. If $C_\mathrm{round}>C_{\ref{L:piNice}}(10^{-4})$ then any configuration $M=(B,R,\eset,W)$ of the chameleon process satisfying \[ \max_{b,v,a}\sum_{z\in \mathrm{B}}Q(z,b,v,a,10^{-4})\le \frac{k}{n}+\frac1{16}, \] is $(\alpha_1,T)$-good, for $T=C_\mathrm{round}(t_\mathrm{rel}+t_\ast(10^{-4})+s_\ast(10^{-4}))$ and some $\alpha_1>0$. \end{lemma} \begin{proof} Recall the definition of $H_t$ from \S\ref{SS:cham_desc}. Without loss of generality suppose $|R|\le|W|$. We bound $H_T$ by only counting pink particles created from red and white particles satisfying: the red particle is on some vertex $a$ at time $T$ and the white on some vertex $b$ with $a\sim b$, and $\phi_a=\phi_b<\infty$. Observe that we have \begin{align*} H_T&\ge\sum_{b\in I_{[0,T]}(W)} \indic{\bigcup_{a\in I_{[0,T]}(R)}\{F_a=b,\,\phi_a=\phi_b\}}\\&=\sum_{b\in I_{[0,T]}(W)}\sum_{a\in I_{[0,T]}(R)} \indic{F_a=b,\,\phi_a=\phi_b}, \end{align*}where the equality follows from the fact that the events $\{F_a=b,\,\phi_a=\phi_b\}$ are disjoint. Recall the definitions of $N(R)$ (as a subset of the Nice$(R)$ vertices) and $GN(R)$ (as the subset of $N(R)$ which are ``good'') from the discussion after Lemma~\ref{L:piNice}. Taking an expectation in the above inequality gives, for any $\theta\in(0,1)$ and $M=(B,R,W)$, \begin{align}\notag \mathbb{E}_M[H_T]&\ge\sum_{a,b:\,a\sim b}\Pr\left[a\in I_{[0,T]}(R),\,b\in I_{[0,T]}(W),\,F_a=b,\,\phi_a=\phi_b\right]\\\notag &=\sum_{a,b:\,a\sim b}\Pr\left[a\in I_{[0,T]}(R),\,b\in I_{[0,T]}(W)\right]\Pr\left[F_a=b,\,\phi_a=\phi_b\right]\\\label{eq:expec_diff} &\ge\sum_{a,b:\,a\sim b}\Pr\left[a\in GN(R)_\theta,\,b\in I_{[0,T]}(W)\right]\Pr\left[F_a=b,\,\phi_a=\phi_b\right], \end{align} where the second equality follows by independence of the edge-rings before and after time $T$. Notice now that we have \begin{align*} \Pr\left[F_a=b,\,\phi_a=\phi_b\right]&=\Pr\left[F_a=b,\,\phi_a=\phi_b|\,F_a\neq\ast\right]\Pr[F_a\neq\ast]\\&=\sfrac1{2d-1}\Pr[F_a\neq\ast]\ge\sfrac1{4d}, \end{align*} where the inequality follows from the fact that some edge incident to vertex $a$ will ring during time interval $(T,T+1)$ with probability $1-e^{-1}>1/2$. Plugging this into \eqref{eq:expec_diff} gives \begin{align} \mathbb{E}_M[H_T]&\ge \frac1{4d}\sum_{a,b:\,a\sim b}\Pr\left[a\in GN(R)_\theta,\,b\in I_{[0,T]}(W)\right].\label{eq:expec_diff2} \end{align} Instead of considering pairs of red and white particles, we consider pairs of red and red, and pairs of red and black. So we now decompose \begin{align}\begin{split} &\Pr\left[a\in GN(R)_\theta,\,b\in I_{[0,T]}(W)\right]\\&= \Pr[a\in GN(R)_\theta]\big(1-\Pr[b\in I_{[0,T]}(R)\mid a\in GN(R)_\theta]\big)\\&\phantom{=}-\Pr[a\in GN(R)_\theta,\,b\in I_{[0,T]}(B)].\label{eq:decomp1}\end{split} \end{align} Using Lemma~\ref{L:BNR} we have, for any $\theta\in(0,1)$ and $\lambda>0$, the bound \begin{align} \Pr[a\in GN(R)_\theta]\ge\left(1-L(\lambda,\theta,d,|R|)\right)\Pr[a\in N(R)],\label{eq:gnr}\end{align} where $L(\lambda,\theta,d,r):=\exp\left\{-\lambda\theta d+(e^\lambda-1)\left(\frac1{32}+\frac{r}{n}\right)d\right\}.$ We decompose the term $\Pr\left[a\in GN(R)_\theta,\,b\in I_{[0,T]}(B)\right]$ according to the starting location of particle at vertex $a$ at time $T$: \begin{align}\notag &\Pr[a\in GN(R)_\theta,\,b\in I_{[0,T]}(B))]\le \Pr\left[a\in N(R),\,b\in I_{[0,T]}(B)\right]\\\notag &=\sum_{v\in R}\Pr\left[a\in \mathrm{Nice}(R),\,b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right]\\\label{eq:gnrB} &=\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr\left[b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right] \end{align} where in the last line we have used the fact that being in Nice is a deterministic property. Using the definition of $GN(R)_\theta$ for any $\theta\in(0,1)$ and $\lambda>0$ and combining equations \eqref{eq:expec_diff2}-\eqref{eq:gnrB} we obtain: \begin{align}\begin{split} \mathbb{E}_M[H_T]\ge &\sfrac1{4d}\sum_{a}\Pr[a\in N(R)](1-L(\lambda,\theta,d,|R|))(d-\theta d)\\ &-\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr\left[b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right].\end{split}\label{eq:blah2} \end{align} We now further decompose $\Pr\left[b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right]$ into two terms, depending on whether the trajectories of particles started from vertices $a$ and $b$ are adjacent, and use Markov's inequality to give \begin{align}\label{eq:decompN}\begin{split} &\Pr\left[b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right] \\&\le \Pr\left[ N_{t_\ast(10^{-4})}(I^{-1}_{[0,T]}(a),I^{-1}_{[0,T]}(b))=0,\,b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right]\\&\phantom{\le}+\mathbb{E}\left[N_{t_\ast(10^{-4})}(I^{-1}_{[0,T]}(a),I^{-1}_{[0,T]}(b))\indic{a=I_{[0,T]}(v)}\right]. \end{split} \end{align} Combining equations \eqref{eq:blah2} and~\eqref{eq:decompN} we obtain, for any $\theta\in(0,1)$ and $\lambda>0$, \begin{align}\begin{split} &\mathbb{E}_M[H_T]\\&\ge\sfrac1{4}\sum_{a}\Pr[a\in N(R)]\left(1-L(\lambda,\theta,d,|R|)\right)(1-\theta)\\ &\phantom{\le}-\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr\Big[ N_{t_\ast(10^{-4})}(I^{-1}_{[0,T]}(a),I^{-1}_{[0,T]}(b))=0,\\ &\phantom{\le-\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr\Big[\,\,}b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\Big]\\ &\phantom{\le}-\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in\mathrm{Nice}(R)}\mathbb{E}\left[N_{t_\ast(10^{-4})}(I^{-1}_{[0,T]}(a),I^{-1}_{[0,T]}(b))\indic{a=I_{[0,T]}(v)}\right].\end{split}\label{eq:expec_diff3} \end{align} For the second term on the r.h.s.\ we have, \begin{align}\notag &\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\\&\phantom{\sfrac1{4d}\sum_{a,b:\,a\sim b}}\cdot\Pr\left[ N_{t_\ast(10^{-4})}(I^{-1}_{[0,T]}(a),I^{-1}_{[0,T]}(b))=0,\,b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right]\notag\\ &=\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\notag\\&\phantom{\sfrac1{4d}\sum_{a,b:\,a\sim b}}\cdot\sum_{z\in B}\Pr\left[ N_{t_\ast(10^{-4})}(v,z)=0,\,b=I_{[0,T]}(z),\,a=I_{[0,T]}(v)\right]\notag\\ &=\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr[a=I_{[0,T]}(v)]\sum_{z\in B}Q(z,b,v,a,10^{-4})\notag\\ &\le\left(\sfrac{k}{n}+\sfrac1{16}\right)\cdot\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr[a=I_{[0,T]}(v)]\notag\\ &=\left(\sfrac{k}{n}+\sfrac1{16}\right)\cdot\sfrac1{4}\sum_a\Pr[a\in N(R)],\label{eq:expec_diff3_term2} \end{align} where the inequality follows from the assumption on the configuration $M$. The third term on the r.h.s\ of \eqref{eq:expec_diff3} is \begin{align} &\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in\mathrm{Nice}(R)}\mathbb{E}\left[N_{t_\ast(10^{-4})}(I^{-1}_{[0,T]}(a),I^{-1}_{[0,T]}(b))\indic{a=I_{[0,T]}(v)}\right]\notag\\ &\le \sfrac1{4d}\sum_{v\in R}\mathbb{E}\left[\sum_a\indic{a=I_{[0,T]}(v)}\sum_{b:\,b\sim I_{[0,T]}(v)}N_{t_\ast(10^{-4})}\big(v, I_{[0,T]}^{-1}(b)\big)\right]\notag\end{align}\begin{align} &=\sfrac1{4d}\sum_{v\in R}\mathbb{E}\left[\sum_{b:\,b\sim I_{[0,T]}(v)}N_{t_\ast(10^{-4})}\big(v, I_{[0,T]}^{-1}(b)\big)\right]\notag\\ &=\sfrac1{4d}\sum_{v\in R}\mathbb{E}\big[\hat N_{t_\ast(10^{-4})}(v)\big]\le \sum_{v\in R}2\times10^{-4} =2\times 10^{-4}|R| ,\label{eq:expec_diff3_term3} \end{align} where the second inequality follows from Lemma~\ref{L:interact}. Plugging equations~\eqref{eq:expec_diff3_term2} and~\eqref{eq:expec_diff3_term3} into~\eqref{eq:expec_diff3} gives, for any $\theta\in(0,1)$ and $\lambda>0$, \begin{align} \begin{split} &\mathbb{E}_M[H_T]\\&\ge\sfrac14\sum_a\Pr[a\in N(R)]\bigg\{\left(1-L(\lambda,\theta,d,|R|)\right)(1-\theta)-\sfrac{k}{n}-\sfrac1{16}\bigg\}-{2\times10^{-4}}|R|. \end{split}\label{eq:expec_diff4} \end{align} Choosing $\lambda=0.05$, $\theta=\frac{9}{16}-\frac{k}{2n}$ and using the bound $|R|/n\le \frac12-\frac{k}{2n}$, \textcolor{black}{we have that $-\lambda\theta+(e^\lambda-1)(\sfrac{1}{32}+\sfrac{|R|}{n}) \le -\lambda(\frac{9}{16}-\frac{1}{32}-\frac 12)+(\frac{\lambda^2}{2}+\frac{\lambda^3}{6}+\lambda^4 )(\frac{1}{32}+\frac 12) $, where we have used $\lambda \le e^\lambda-1\le \frac{\lambda^2}{2}+\frac{\lambda^3}{6}+\lambda^4 $ for $\lambda \in [0,0.05]$, and so} \[ \sfrac1{d}\log L(\lambda,\theta,d,|R|)=-\lambda\theta+(e^\lambda-1)(1/32+|R|/n)\le -0.0008, \] and so since $d\ge10^4$, we obtain \[ \left(1-L(\lambda,\theta,d,|R|)\right)(1-\theta)-\sfrac{k}{n}-\sfrac1{16} \ge -\sfrac{k}{n}(1-\sfrac{1-e^{-8}}{2}) +\sfrac{6-7 e^{-8} }{16} > \sfrac1{16}. \] Plugging this into \eqref{eq:expec_diff4} gives the bound \begin{align}\label{eq:expec_diff5} \mathbb{E}_M[H_T]\ge \sfrac1{64}\mathbb{E}[|N(R)|]-{2\times 10^{-4}}|R|. \end{align} Notice now that $\mathbb{E}[|N(R)|]=|R|\,\Pr_{\pi_R}(X_T\in \mathrm{Nice}(R))$, for $(X_t)$ a realisation of RW$(G)$, and so by Lemmas~\ref{L:niceC} and~\ref{L:piNice} we have that, since $C_\mathrm{round}>C_{\ref{L:piNice}}(10^{-4})$, $\mathbb{E}[|N(R)|]\ge |R|\left(\sfrac1{17}-10^{-4}\right)$. Hence from~\eqref{eq:expec_diff5} we obtain the bound \[ \mathbb{E}_M[H_T]\ge |R|\left(\sfrac1{1088}-\sfrac{129}{64}\times10^{-4}\right)>0.0007|R|. \] The proof is completed by taking any $\alpha_1\le0.0007$. \qedhere \end{proof} \begin{proof}[Proof of Proposition~\ref{P:beta} for $d\ge 10^4$]\ \\ Recall the notation $t_0=t_\mathrm{mix}^{(\infty)}(n^{-10})$ and let $t\ge t_0$. By Lemma~\ref{L:largedev} we have that for any $B\in (V)_{k-1}$, and $n$ sufficiently large, by a union bound \begin{align*} &\Pr\left[\max_{b,v,a}\sum_{z\in \mathrm{B}_{t}}Q(z,b,v,a,10^{-4})\le \sfrac{k}{n}+\sfrac1{16}\Bigm| \mathrm{B}_0=B\right]\\&\ge 1-\sum_{b,v,a}\Pr\left[\sum_{z\in B_{t}}Q(z,b,v,a,10^{-4})>\sfrac{k}{n}+\sfrac1{16}\Bigm| \mathrm{B}_0=B\right]\ge 1-n^{-10}. \end{align*}Therefore if we have $C_\mathrm{round}>C_{\ref{L:piNice}}(10^{-4})$ then, by Lemma~\ref{L:redloss}, since $d\ge 10^4$, with probability at least $1-n^{-10}$, $M_{t}$ (the configuration of the chameleon process at time $t$) is $(\alpha_1,T)$-good, for $T=C_\mathrm{round}(t_\mathrm{rel}+t_\ast(10^{-4})+s_\ast(10^{-4}))$ and some $\alpha_1>0$, i.e.\ $\beta(\alpha_1,t_\mathrm{round}-1)\le n^{-10}$. This completes the proof taking $\alpha=\alpha_1$. \end{proof} \section{Modifications to the main approach}\label{S:modifications} \subsection{Generalising the results of \S\ref{S:neighbours}}\label{S:generalising} For the case of $d<10^4$ for Theorem~\ref{thm:main1} (and for other values of $d$ in general) it will be useful to artificially inflate the degree of vertices by adding \textcolor{black}{``dummy"} directed edges (of zero weight) to the graph (without the addition of new vertices). The number of edges we need to add varies according to the values of $k$ and $d$ and we let $\hat d$ denote the new out-degree of all of the vertices (which is the number of undirected edges plus the number of directed out-edges from a vertex). We will always add these edges between vertices within graph distance at most $\hat d$ in the original graph. These edges are assigned weight 0 and so never ring and play no role in the dynamics of the processes, instead just affecting the structure of the graph (in particular adjacency). Any such graph that has these additional edges is referred to as a \emph{modified} graph and we write $v\stackrel{\rightarrow}{\sim}u$ to indicate that either $(v,u)$ or $\{v,u\}$ is an edge in a modified graph. We denote the maximal in-degree in the modified graph by $d_{\max}^{\mathrm{in}}$. \textcolor{black}{If we could ensure that the in-degrees were all equal (to the out-degree), the argument from \S\ref{S:neighbours}-\ref{S:loss} would work almost verbatim (the main difference is that one has to replace adjacency by adjacency in the modified graph, apart from when controlling the number of interactions between a pair of particles). If the graph is vertex-transitive one can easily ensure this. Alas, in general one cannot do this.} \textcolor{black}{As we inflate the degree only when $d<10^4$ it follows that there exists an absolute constant $D$ such that $ d_\mathrm{max}^{\mathrm{in}} \le D \hat d $. We now explain how, from a high-level perspective, this leads only to minor changes in the outline of the argument. While we expect most readers to be satisfied with this outline, we present all details of the proof below. } \textcolor{black}{ Recall that when $d \ge 10^4$ the (indirect) argument for controlling the expected number of white neighbours that red particles have by considering the number of red and black neighbours they have breaks down when $|R| \wedge |W| > \varrho_{0} n $ for a certain constant $\varrho_{0}$. Fortunately, in this regime we could work directly with the white particles. In the case $d<10^4$ the indirect argument breaks down for a smaller value of $\varrho_{0}$, due to an additional factor $D \ge \frac{d_\mathrm{max}^{\mathrm{in}}}{\hat d} $ appearing in analogous statements to ones from \S\ref{S:neighbours}-\ref{S:loss} related to the analysis of the number of red neighbours. This is not a problem, as when $|R| \wedge |W| > \varrho_{0} n $ (and $d<10^4$) we argue that at the end of the constant colour phase, the expected number of red particles with at least one white neighbour in the modified graph is of order $n$ (provided $T \gtrsim \rel $, where $T+1$ is the duration of the round). As the modified graph has bounded degree, this suffices to argue that $\mathop{\mathbb E}[H_T] \gtrsim n $, as required. } Recall the definition of Nice from \S\ref{S:redvred}. We modify this definition to deal with these modified graphs and in the sequel this is the definition of Nice that we use (i.e.\ every future use of Nice refers to this new defintion). \begin{definition} For each subset $S\subseteq V$, let $e_T(v,S):=\sum_{u:\,v \stackrel{\rightarrow}{\sim} u}P_T(u,S) $ and define $\mathrm{Nice}(S)$ as: \[ \mathrm{Nice}(S):=\Big\{v\in V:\,e_T(v,S)< \hat d\left(\sfrac1{32}+\sfrac{|S|}{n}\right)\Big\}. \] \end{definition} The equivalent statement of Lemma~\ref{L:niceC} is the following. We omit the proof as it follows in a similar manner (i.e. a simple counting argument together with the fact that the modified graph has out-degree $\hat d $ at each site). \begin{lemma}[Proof omitted]\label{L:niceC2} For each $S\subseteq V$, \[ |\mathrm{Nice}(S)^\complement|\le \left(\frac1{32}+\frac{|S|}{n}\right)^{-1}\frac{d_\mathrm{max}^\mathrm{in}}{\hat d}|S|. \] \end{lemma} \begin{remark} Using Lemma~\ref{L:niceC2} it is possible to prove (proof omitted) that Lemma~\ref{L:piNice} still holds with the new definition of Nice and so will make use of this lemma in this section. \end{remark} Next, we recall the definition of $BN(S)$ for $S\subseteq V$ from \S\ref{S:redvred} and redefine it for modified graphs as: \[ BN(S)_\theta:=\Big\{v\in N(S):\,\sum_{u:\,v \stackrel{\rightarrow}{\sim} u}\indic{I_{[0,T]}^{-1}(u)\in S}>\theta \hat d \Big\}. \] We also redefine set $GN(S)_\theta$ to be $N(S)\setminus BN(S)_\theta$. The analogue of Lemma~\ref{L:BNR} is the following. \begin{lemma}\label{L:BNR2} For each $S\subseteq V$, $\theta\in(0,1)$, $\lambda>0$ and $v\in V$, \[ \Pr[v\in BN(S)_\theta\mid v\in N(S)]<\exp\left\{\hat d\left(-\lambda\theta+(e^\lambda-1)\left(\sfrac1{32}+\sfrac{|S|}{n}\right)\right)\right\}. \] \end{lemma} Next, we recall Lemma~\ref{L:interact} which bounds the expected value of $\hat N_t(v)$. We redefine this quantity in terms of modified graphs as follows: \[ \hat N_{t}(v):=\sum_{u:\, I_{[0,T]}(v) \stackrel{\rightarrow}{\sim} u}N_{t}(v,I^{-1}_{[0,T]}(u)). \] We present below the version of Lemma~\ref{L:interact} to be used for modified graphs. The proof is omitted and we remark that the main difference in the proof of this result compared with Lemma~\ref{L:interact} is that we define $\tilde N_t(v,w)$ to be the amount of time particles from $v$ and $w$ spend adjacent w.r.t.\ $G$ (as opposed to w.r.t.\ the modified graph) during the time interval $[0,t]$. \begin{lemma}[Proof omitted]\label{L:interact2} For all $\epsilon\in(0,1)$ and $C_\mathrm{round}\ge 1$ we have \[\max_{v\in V}\mathbb{E}[\hat N_{t_\ast(\epsilon)}(v)]\le 4\epsilon(d_\mathrm{max}^\mathrm{in}+\hat d).\] \end{lemma} We now show that after a burn-in period we have a large deviation estimate of the black particle measure. After a burn-in period, the occupation by the black particle measure has marginals extremely close to $k/n$ and has the NA property. A simple calculation involving the Laplace transform (Lemma~\ref{L:black}) shows that it satisfies large deviation estimates similar to the ones available in the independent case. From this, along with a union bound, one can derive (Corollary~\ref{C:black}) that at each given time after a burn in period, the probability of having a configuration satisfying that given this current configuration, the probability of having more than $(\frac{k}{n}+c)d $ black neighbours of a vertex after $T$ additional time units (where $T+1$ is the duration of a round) is $\ll n^{-10}$ (\emph{i.e.}, if we start a round at this time, the probability that at the end of the constant-colour phase we have at least $(\frac{k}{n}+c)d $ black neighbours is small). The proof is similar to the proof of Lemma~\ref{L:BNR}. For $\varepsilon\in(0,1)$, $n\in\mathbb{N}$ and $2\le k\le n/2$, we denote $m_{\varepsilon,n,k}:=\max\Big\{\log\frac{\varepsilon n}{e^2k},\frac{\varepsilon n}{2k}\big(\frac12-\frac{\varepsilon n}{k}\big)\Big\}.$ \begin{lemma}[{Proof in Appendix~\ref{proofblack}]}] \label{L:black} Fix $\varepsilon\in(0,1)$. There exists $n_0=n_0(\varepsilon)$ such that for all $n\ge n_0$, $2\le k\le n/2$, $B\in(V)_{k-1}$, $v\in V$, and $s\ge t_{\mathrm{mix}}^{(\infty)}(n^{-10})$, \begin{align*} \Pr\Big[\sum_{u:\, v \stackrel{\rightarrow}{\sim} u }\indic{u\in \mathrm{B}_{s}}\ge\left(\sfrac{k}{n}+\varepsilon\right)\hat d \Bigm| \mathrm{B}_0=B\Big]\le \exp\Big(-\hat d\varepsilon m_{\varepsilon,n,k}\Big). \end{align*} \end{lemma} \begin{corollary}\label{C:black} Fix $\varepsilon\in(0,1)$ and for each $t>0$ let $\mathcal{F}_t$ denote the $\sigma$-algebra generated by $\mathrm{B}_t$. There exists $n_0=n_0(\varepsilon)$ such that for all $n\ge n_0$, $2\le k\le n/2$, $B\in(V)_{k-1}$, $v\in V$ and $s_2\ge s_1\ge t_{\mathrm{mix}}^{(\infty)}(n^{-10})$, \begin{align*} &\Pr\left[\Pr\Big[\sum_{u:\,v \stackrel{\rightarrow}{\sim} u}\indic{u\in \mathrm{B}_{s_2}}\ge\left(\sfrac{k}{n}+\varepsilon\right) \hat d\Bigm| \mathcal{F}_{s_1}\Big]\ge \exp(-\sfrac12 \hat d\varepsilon m_{\varepsilon,n,k})\right]\\&\le \exp(-\sfrac12 \hat d\varepsilon m_{\varepsilon,n,k}). \end{align*} \end{corollary} \begin{proof} The proof immediately follows from Lemma~\ref{L:black} using Markov's inequality. \end{proof} \begin{remark}\label{R:black} The above corollary also holds for sufficiently small $\hat c\in (0,1)$ taking $s_2\ge s_1\ge t_\mathrm{mix}^{(\infty)}(\hat c/k)$. This follows from the fact that Lemma~\ref{L:black} holds when $n^{-10}$ is replaced with a sufficiently small $\hat c$ and so in particular holds when replaced with $\hat c/k$. \end{remark} For graphs with sufficiently small degree, once the number of red particles is at least some fraction of $n$, it turns out that we can avoid analysing the number of red and black neighbours of a vertex (conditioned on being red), and instead directly lower-bound the number of white neighbours (in fact in this case we do not even need burn-in periods). To see why, observe that the number of red particles without a nearby white particle after the relaxation phase is comparable (as $|R|\asymp n$) to the number of vertices without a nearby white particle at this time. This can be controlled with a simple argument making use of the Poincar\'e inequality, see Lemma~\ref{L:white1}. For the remaining red vertices in the proximity of a white particle, we can easily lower-bound the probability of their interaction during a unit time interval. For a subset $S\subseteq V$, we define another subset $Q\subseteq V$ in the following way: \[ Q(S)=\big\{v\in V:\,\sum_{u:\,v\stackrel{\rightarrow}{\sim} u}P_T(u,S)<\hat d/{16}\big\}. \] The reader should think of $S$ as the set occupied by the white particles at the beginning of a round. Recall that w.l.o.g.\! we always consider in \S\ref{S:neighbours}--\S\ref{S:modifications} the case that there are as many white particles as there are red, and so $|S|/n \ge 1/4$. We achieve control on the number of white neighbours via the following lemma. \begin{lemma}\label{L:white1} For any $\varepsilon\in(0,1)$ and any $S\subset V$ with $|S|/n\ge 1/4$, if $T\ge \rel |\log(1/\varepsilon)|$ then $|Q(S)|\le 8\varepsilon n\sfrac{d_\mathrm{max}^\mathrm{in}}{\hat d}$. \end{lemma} \begin{proof} If $T\ge\rel |\log(1/\varepsilon)|$ then since $|S|/n\ge 1/4$, the $L_2$-distance of $P_{\pi_S}(X_T\in\bullet)$ from $\pi$ is at most $2\varepsilon$ by the Poincar\'e inequality \eqref{e:Poincare}, and hence this is also a bound on the $L_1$-distance. Therefore by a simple counting argument and reversibility \begin{align} |\{u:\,P_T(u,S)<|S|/(2n)\}|< 4\varepsilon n.\label{eq:PTS} \end{align} We prove the statement of the lemma by contradiction. So suppose $|Q(S)|>8\varepsilon n\sfrac{d_\mathrm{max}^\mathrm{in}}{\hat d}$, \emph{i.e.}\ there are more than $8\varepsilon n\sfrac{d_\mathrm{max}^\mathrm{in}}{\hat d}$ vertices $v$ for which we have $\sum_{u:\,v\stackrel{\rightarrow}{\sim} u}P_T(u,S)< \hat d/16\le \hat d|S|/(4n)$. Then for each $v\in Q(S)$, we must have at least $\hat d/2$ vertices $u$ such that $v\stackrel{\rightarrow}{\sim} u$ with $P_T(u,S)<|S|/(2n)$. Now each $u$ has in-degree at most $d_\mathrm{max}^\mathrm{in}$, and thus overall there are at least $\hat d|Q(S)|/(2d_\mathrm{max}^\mathrm{in})$ vertices $u\in V$ with $P_T(u,S)<|S|/(2n)$, but since we assume $|Q(S)|>8\varepsilon n\frac{d_\mathrm{max}^\mathrm{in}}{\hat d}$, this number of vertices is at least $4\varepsilon n$. This is in contradiction with \eqref{eq:PTS}. \end{proof} \begin{lemma}\label{L:white2} Let $S\subset V$. For each $v\in Q(S)^\complement$, \[\Pr\big[\sum_{u:\,v\stackrel{\rightarrow}{\sim} u}\indic{u\in S_T}=0\big]\le \left(\sfrac{31}{32}\right)^{\hat d/32}.\] \end{lemma} \begin{remark} The proof of this lemma relies on the NA property. \end{remark} \begin{proof} Notice that, since $v\in Q(S)^\complement$, we must have at least $\hat d/32$ vertices $u$ with $v\stackrel{\rightarrow}{\sim} u$ such that $\Pr[u\in S_T]\ge 1/32$. Hence by the NA property, \[\Pr\big[\sum_{u:\,v\stackrel{\rightarrow}{\sim} u}\indic{u\in S_T}=0\big]\le \prod_{u:\,v\stackrel{\rightarrow}{\sim} u}\Pr\big[u\notin S_T\big]\le \left(\sfrac{31}{32}\right)^{\hat d/32}.\qedhere \] \end{proof} \subsection{Proof of Proposition~\ref{P:beta} for $d<10^4$}\label{SS:smalld} In order to prove Proposition~\ref{P:beta} for $d<10^4$, we split into two cases depending on the value of $|R|\wedge|W|$ (the minimum of the number of reds and whites in the initial configuration of the chameleon process) and a constant $\varrho_0\in(0,1/4)$ to be later determined. The following lemma will be used for the case $|R|\wedge|W|\ge\varrho_0 n$. \begin{lemma}\label{L:losssmalldbigR1} Let $\varrho\in(0,1/4),\,C_\ast\ge1$ and consider case $d<C_\ast\log(1/\varrho)$. There exists a constant $C^0_\ast$ such that if $C_\ast\ge C^0_\ast$ then any configuration $M=(B,R,\eset,W)$ of the chameleon process with $|R|\wedge |W|\ge\varrho n$ is $(\alpha_4,T)$-good for $T\ge C_\mathrm{round}\rel$ with $C_\mathrm{round}$ and $\alpha_4$ depending only on $\varrho$ and $C_\ast$. \end{lemma} \begin{proof} We inflate the degree so that $\hat d=\lceil C_\ast\log(1/\varrho)\rceil$. Without loss of generality suppose $|R|\le |W|$. Notice that since $k\le n/2$, we have that $|W|/n\ge 1/4$. Notice that a white particle will get pinkened during $(T,T+1)$ if there exists a red particle such that: \begin{enumerate} \item the red particle is on some vertex $a$ at time $T$ with $a$ belonging to a sparse set $A$, and the white on some vertex $b$, with $a\stackrel{\rightarrow}{\sim}b$, \item $\phi_a<\infty$ (\emph{i.e.}\ vertex $a$ is on a ringing edge during time interval $(T,T+1)$), \item at time $\phi_a$ the other vertex $a'$ incident to the ringing edge is occupied by the white particle (which may have turned pink by this time), \item during time interval $[T,\phi_a)$ the white particle moves along a shortest trajectory from $b$ to $a'$. \end{enumerate} We remark that this will only result in pink particles being created \emph{at time $\phi_a$} if the white particle is in fact still white at time ${\phi_{a}}_-$ (and otherwise it gets pinkened prior to this time). We choose the set $A$ to have minimal size while satisfying $\sum_{a\in A}\Pr[a\in I_{[0,T]}(R)]\ge \hat d^{-2\hat d}|R|$ and with the property that no two elements of $A$ are within graph distance (in the original graph) $2\hat d$. It can be shown (\emph{e.g.}\! with a greedy construction) that $|A|\le \hat d^{-2\hat d}n$. Observe that we can bound \begin{align*} H_T&\ge \sum_{b\in I_{[0,T]}(W)} \indic{\bigcup_{a\in I_{[0,T]}(R)\cap A}\{F_a=b,\,a\stackrel{\rightarrow}{\sim}b\}}\\&=\sum_{b\in I_{[0,T]}(W)}\sum_{a\in I_{[0,T]}(R)\cap A} \indic{F_a=b,\,a\stackrel{\rightarrow}{\sim}b}, \end{align*}where the equality follows from the fact that each $b\in V$ is adjacent to at most one $a\in A$. Taking an expectation gives \begin{align*} \mathop{\mathbb E}_M[H_T]&\ge \sum_{a\in A}\sum_{b:\,a\stackrel{\rightarrow}{\sim} b}\Pr[a\in I_{[0,T]}(R),\,b\in I_{[0,T]}(W),\,F_a=b]\\ &=\sum_{a\in A}\sum_{b:\,a\stackrel{\rightarrow}{\sim} b}\Pr[a\in I_{[0,T]}(R),\,b\in I_{[0,T]}(W)]\Pr[F_a=b], \end{align*} where the equality follows by independence of the edge-rings before and after time $T$. To lower-bound the probability $\Pr[F_a=b]$ we fix a particular trajectory the white particle must follow, from its position at time $T$ (vertex $b$) to a vertex (denoted $a'$) adjacent to $a$. The trajectory chosen is one of shortest length between $a$ and $b$. We additionally impose the condition that the particle must follow this trajectory during time interval $[T,T+1/2]$. Since the degree of each vertex is less than $\hat d$, and vertex $b$ is within graph distance (in the original graph) $\hat d$ from $a$, this event has probability bounded from below by some constant $c_1>0$ (uniformly over $a$ and $b$). The event $\{F_a=b\}$ will then be satisfied if the first edge incident to vertex $a$ to ring during $(T,T+1)$ is edge $\{a,a'\}$ and this edge first rings during time interval $(T+1/2,T+1]$, an event of probability $c_2>0$. Hence we obtain the bound $\Pr[F_a=b]\ge c_1c_2$. Note that these constants depend on $\varrho$ since $\hat d$ depends on $\varrho$. Hence we have \begin{align*} \mathop{\mathbb E}_M[H_T]&\ge c_1c_2\sum_{a\in A}\sum_{b:\,a\stackrel{\rightarrow}{\sim} b}\Pr[a\in I_{[0,T]}(R),\,b\in I_{[0,T]}(W)]\\ &\ge c_1c_2\sum_{a\in A} \Pr[a\in I_{[0,T]}(R),\,\exists b\in I_{[0,T]}(W):\,a\stackrel{\rightarrow}{\sim} b]. \end{align*} Recall the definition of $Q(S)$ from \S\ref{S:generalising}. Decomposing the above sum (and writing $a\stackrel{\rightarrow}{\nsim}b$ to indicate that it is not the case that $a\stackrel{\rightarrow}{\sim}b$) we have \begin{align*} \mathop{\mathbb E}_M[H_T]&\ge c_1c_2\sum_{a\in A}\Pr[a\in I_{[0,T]}(R)]\\&\phantom{\ge}-c_1c_2\sum_{a\in Q(W)}\Pr[a\in I_{[0,T]}(R),\,\forall b\in I_{[0,T]}(W),\,a\stackrel{\rightarrow}{\nsim} b]\\&\phantom{\ge}-c_1c_2\sum_{a\in A\cap Q(W)^\complement}\Pr[a\in I_{[0,T]}(R),\,\forall b\in I_{[0,T]}(W), \,a\stackrel{\rightarrow}{\nsim} b]\\ &\ge \frac{c_1c_2}{\hat d^{2\hat d}}|R|-c_1c_2|Q(W)|-c_1c_2\sum_{a\in A\cap Q(W)^\complement}\Pr[\forall b\in I_{[0,T]}(W),\,a\stackrel{\rightarrow}{\nsim} b]. \end{align*} By Lemma~\ref{L:white1} with $\varepsilon=(\hat d\varrho)/(32d_\mathrm{max}^\mathrm{in}\hat d^{2\hat d})$, since $|W|/n\ge 1/4$, if $C_\mathrm{round}>\log(1/\varepsilon)$ then $|Q(W)|\le\varrho n/(4\hat d^{2\hat d})$. Notice that for a fixed choice of $\hat d$, there exists a universal (over $G$) constant $D$ such that $d_{\mathrm{max}}^\mathrm{in}\le D\hat d$, and hence $C_\mathrm{round}$ depends only on $\varrho$ and the choice of $C_\ast$. By Lemma~\ref{L:white2} if we take $C_\ast^0=2500$ then since $\varrho<1/4$ we have that for each $a\in Q(W)^\complement$, $\Pr[\forall b\in I_{[0,T]}(W),\,a\stackrel{\rightarrow}{\nsim} b]\le \varrho/4$. Hence we obtain \[ \mathop{\mathbb E}_M[H_t]\ge \frac{c_1c_2}{\hat d^{2\hat d}}|R|-\frac{c_1c_2}{\hat d^{2\hat d}}\frac{\varrho n}{4}-c_1c_2 |A|\frac{\varrho}{4}\ge \frac{c_1c_2}{\hat d^{2\hat d}}\frac{|R|}{2}, \] which completes the proof with $\alpha_4=\sfrac12 c_1c_2\hat d^{-2\hat d}$. \end{proof} Now we consider how to deal with the case $|R|\wedge|W|<\varrho_0 n$. Recall Lemma~\ref{L:redloss} from \S\ref{S:loss}. In order to prove the equivalent statement for the case $d<10^4$ we follow a similar argument but also make use of degree-inflation. We first state a preliminary lemma which states that we can find a sparse subset of Nice$(S)$ which picks-up a fraction of the time-$T$ mass of a random walk started uniformly on $S$. \begin{lemma}[{Proof in Appendix~\ref{A:prelim}]}]\label{L:boundA} Suppose $d<10^4$. For any $S\subseteq V$, there exists a constant $c_\mathrm{frac}>0$ and a subset $A(S)$ of Nice$(S)$ such that no two members of $A(S)$ are within graph distance of $2\times 10^4$ and such that \[ \sum_{u\in A(S)}\Pr_{\pi_S}[X_T=u]\ge c_\mathrm{frac}\sum_{u\in \mathrm{Nice}(S)}\Pr_{\pi_S}[X_T=u]. \] \end{lemma} Notice that, due to the sparseness property of $A(S)$, in the modified graph if $v,w\in A$ and $v\stackrel{\rightarrow}{\sim} u$, then $w\stackrel{\rightarrow}{\nsim} u$. \begin{lemma}\label{L:losssmalld} Let $c_\mathrm{frac}$ be the constant from Lemma~\ref{L:boundA} and consider the case $d<10^4$. There exists $\varrho_0\in(0,1/4)$ and $\epsilon\in(0,10^{-4}]$ such that if $C_\mathrm{round}>C_{\ref{L:piNice}}(\epsilon)$ then any configuration $M=(B,R,\eset,W)$ of the chameleon process with $|R|\wedge |W|<\varrho_0 n$ satisfying \[ \max_{b,v,a}\sum_{z\in \mathrm{B}}Q(z,b,v,a,\epsilon)\le \sfrac{k}{n}+\sfrac1{16}, \] is $(\alpha_2,T)$-good, for some universal $\alpha_2>0$, and $T=C_\mathrm{round}(t_\mathrm{rel}+t_\ast(\epsilon)+s_\ast(\epsilon))$. \end{lemma} \begin{proof} We inflate the degree so that $\hat d=10^4.$ Without loss of generality suppose $|R|\le |W|$. Notice that a white particle will get pinkened during $(T,T+1)$ if there exists a red particle satisfying statements 1.\ to 4.\ from the proof of Lemma~\ref{L:losssmalldbigR1}. We choose the set $A$ to be $A(R)$ from Lemma~\ref{L:boundA}. The first part of the proof proceeds similarly to the proof of Lemma~\ref{L:losssmalldbigR1}. We obtain the bound: \begin{align*} \mathbb{E}_M[H_T]&\ge c_1c_2\sum_{a\in A(R)}\,\sum_{b:\,a\stackrel{\rightarrow}{\sim}b}\Pr[a\in GN(R)_\theta,\,b\in I_{[0,T]}(W)]. \end{align*} At this point we refer to the proof of Lemma~\ref{L:redloss}, and following the same arguments (using Lemma~\ref{L:interact2} in place of Lemma~\ref{L:interact}) arrive at the analogous statement to \eqref{eq:expec_diff5}: \begin{align}\label{eq:expdiff2} \mathbb{E}_M[H_T]&\ge \hat c_3\left(\sfrac1{64}\mathbb{E}[|A(R)\cap I_{[0,T]}(R)|]-\epsilon|R|\right), \end{align} for some $\hat c_3>0$. Notice that in applying Lemma~\ref{L:interact2} to obtain the above we have made use of the fact that for a fixed choice of $\hat d$ there exists a universal constant $D$ such that $d_\mathrm{max}^\mathrm{in}\le D\hat d$ \textcolor{black}{(i.e.\ we take $\epsilon$ in Lemma~\ref{L:interact2} to be $\epsilon/D$)}. Now notice that by Lemmas~\ref{L:niceC}, \ref{L:piNice} \textcolor{black}{(with $\varepsilon=10^{-4}$)}, \ref{L:niceC2} \textcolor{black}{(used to argue that $\pi( \text{Nice}(R)) \geq 1- 32 D \varrho_0 $)} and~\ref{L:boundA} we have \begin{align*} &\mathbb{E}[|A(R)\cap I_{[0,T]}(R)|]=|R|\,\Pr_{\pi_R}[X_T\in A(R)]=|R|\sum_{u\in A(R)}\Pr_{\pi_R}[X_T=u]\\&\ge c_\mathrm{frac}|R|\sum_{u\in \mathrm{Nice}(R)}\Pr_{\pi_R}[X_T=u]=c_\mathrm{frac}\mathbb{E}[|N(R)|]\\&\ge c_\mathrm{frac}|R|\left(\pi(\mathrm{Nice}(R))-10^{-4}\right)>c_\mathrm{frac}|R|(1-32D\varrho_0-10^{-4}). \end{align*} Combining this with \eqref{eq:expdiff2} and taking $\epsilon$ and $\varrho_0$ sufficiently small gives the existence of a universal constant $\alpha_2$ such that $ \mathbb{E}_M[H_T]\ge \alpha_2|R|. $ \end{proof} \begin{proof}[Proof of Proposition~\ref{P:beta} for $d< 10^4$]\ \\ Let $t\ge t_0:=t_\mathrm{mix}^{(\infty)}(n^{-10})$ and $\rho_0$ and $\epsilon$ be the constants from Lemma~\ref{L:losssmalld} and suppose $|R|\wedge|W|<\varrho_0 n$. If $C_\mathrm{round}>C_{\ref{L:piNice}}(10^{-4})$, and $T=C_\mathrm{round}(t_\mathrm{rel}+t_\ast(\epsilon)+s_\ast(\epsilon))$, by Lemma~\ref{L:losssmalld} (which we can apply here as Lemma~\ref{L:largedev} holds even for modified graphs since the number of interactions is unaffected by the addition of edges which never ring), there exists a universal $\alpha_2>0$ such that with probability at least $1-n^{-10}$, $M_{t}$ is $(\alpha_2,T)$-good, i.e.\ $\beta(\alpha_2,t_\mathrm{round}-1)\le n^{-10}$. On the other hand if $|R|\wedge|W|\ge\varrho_0 n$ then set $C_{\ast}= C_\ast^0\vee \sfrac{10^4}{\log(1/\varrho_0)}$ (with $C_\ast^0$ the constant from Lemma~\ref{L:losssmalldbigR1}). Then by Lemma~\ref{L:losssmalldbigR1} with $\varrho=\varrho_0$ there exist constants $\alpha_4>0$ and $C_\mathrm{round}^0$ such that if $C_\mathrm{round}> C_\mathrm{round}^0$ then with probability 1, $M_{t}$ is $(\alpha_4,T)$-good, for $T=C_\mathrm{round}t_\mathrm{rel}$, i.e.\ $\beta(\alpha_4,t_\mathrm{round}-1)=0$. This completes the proof taking $\alpha=\alpha_2\wedge\alpha_4$. \end{proof} \section{Mixing for graphs of high degree: proof of Theorem~\ref{thm:maindeg}}\label{SS:thmmaindeg} Recall that in this regime we have $d \gtrsim \log_{n/k} n$. The analogue of Proposition~\ref{P:beta} (which gives a bound on the probability that a configuration is not $(\alpha,t)$-good after a burn-in) for proving Theorem~\ref{thm:maindeg} is the following proposition. \begin{proposition}\label{P:betadeg} There exist constants $\alpha, C_\mathrm{round}, C_\mathrm{deg} >~0 $, such that for all $n$ sufficiently large if $d\ge C_\mathrm{deg}\log_{n/k}n$ then $\beta(\alpha,C_\mathrm{round}\rel)\le n^{-10}$. \end{proposition} \begin{proof}[Proof of Theorem~\ref{thm:maindeg}] This is identical to the proof of Theorem~\ref{thm:main1} (general mixing bound) in \S\ref{s:proofofmain} using Proposition~\ref{P:betadeg} in place of Proposition~\ref{P:beta}. \end{proof} In order to prove Proposition~\ref{P:betadeg} we must control red and black neighbours of red particles (it is not enough to only consider pairs of red and white particles). \textcolor{black}{We make use of the large degree to argue that after a burn-in period of duration $\mix^{(\infty)}(n^{-10})$, the probability that the number of black neighbours of a vertex $v$ will be unusually high is extremely small. This considerably simplifies the analysis, as there is no longer a need to consider the number of intersections (during the first $t_*$ time units of the round) between a red particle and its black neighbours (at the end of the constant colour phase of the round). This is what allows us to avoid the term $r_*(c_{1.1}) \log (n/\varepsilon) $ in Theorem \ref{thm:maindeg}.} \textcolor{black}{Indeed, each neighbour of $v$ is occupied by a black particle with probability at most $\frac{k-1}{n}+n^{-10} $. Using negative association, we can bound the probability that vertex $v$ has at least $(\sfrac{k}{n}+\zeta)d$ black neighbors, for some $\zeta >0$, by a bound similar to the probability that a Binomial$(d,\frac{k-1}{n}+n^{-10} )$ r.v.\ is at least $(\sfrac{k}{n}+\zeta)d$. By assumption on $d$ and $k$, the last probability can be made $n^{-13}$ (for each fixed $\zeta>0$), provided $C_\mathrm{deg}$ is taken to be sufficiently large.} \begin{lemma}\label{L:losslargedegree} Let $\zeta\in(0,1/16]$ and consider the case $d\ge 10^4\log_{n/k}n$. If $C_\mathrm{round}> C_{\ref{L:piNice}}(10^{-4})$ and $T=C_\mathrm{round}t_\mathrm{rel}$ then any configuration $M=(B,R,\eset,W)$ of the chameleon process satisfying \[ \max_{v\in V}\Pr\left[\sum_{u:\,u\sim v}\indic{u\in \mathrm{B}_T}\ge (\sfrac{k}{n}+\zeta)d\Bigm| \mathrm{B}_0=B\right]\le n^{-10} \] is $(\alpha_3,T)$-good, for $\alpha_3>0$ a universal constant, and all $n$ sufficiently large. \end{lemma} \begin{proof} This proof is very similar to the proof of Lemma~\ref{L:redloss}. We count $H_T$ in the same way and arrive at the bound (from equation~\eqref{eq:blah2}) \begin{align}\begin{split} \mathbb{E}_M[H_T]\ge &\sfrac1{4d}\sum_{a}\Pr[a\in N(R)](1-L(\lambda,\theta,d,|R|))(d-\theta d)\\ &-\sfrac1{4d}\sum_{a,b:\,a\sim b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr\left[b\in I_{[0,T]}(B),\,a=I_{[0,T]}(v)\right].\end{split}\label{eq:blah3} \end{align} Let $E_\zeta(a)$ be the event that vertex $a$ has less than $(k/n+\zeta)d$ neighbours occupied by black particles at time $T$. Then by the assumption on $M$, we have that $\Pr[E_\zeta(a)^\complement]\le n^{-10}$. Let $N_t(v)$ be the number of neighbours of vertex $v$ occupied by black particles at time $t$. Summing over $a\in \mathrm{Nice(R)}$, $b:\, a\sim b$ and $v\in R$ in the second double sum on the r.h.s. of equation~\eqref{eq:blah3} gives \begin{align}\notag &\sum_{a,b:\,a{\sim}b}\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\Pr[b\in I_{[0,T]}(\mathrm{B}),a=I_{[0,T]}(v)]\\\notag&=\sum_a\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\mathbb{E}\left[\indic{a=I_{[0,T]}(v)}\sum_{b:\,a{\sim}b}\indic{b\in I_{[0,T]}(\mathrm{B})}\right]\\\notag &=\sum_a\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\mathbb{E}\left[\indic{a=I_{[0,T]}(v)}N_T(a)\right]\end{align}\begin{align}\notag &= \sum_a\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\bigg(\mathbb{E}\left[\indic{E_\zeta(a)}\indic{a=I_{[0,T]}(v)}N_T(a)\right]\notag\\\notag&\phantom{=\sum_a\sum_{v\in R}\indic{a\in \mathrm{Nice}(R)}\mathbb{E}\bigg(}+\mathbb{E}\left[\indic{E_\zeta(a)^\complement}\indic{a=I_{[0,T]}(v)}N_T(a)\right]\bigg)\\\notag &\le \sum_a\sum_{v\in R}\Big(\indic{a\in \mathrm{Nice}(R)}(k/n+\zeta) d\,\Pr[a=I_{[0,T]}(v)]\\\notag&\phantom{\le \sum_a\sum_{v\in R}\Big(}+d\,\Pr\left[E_\zeta(a)^\complement\cap\{a=I_{[0,T]}(v)\}\right]\Big)\\\notag &\le\sum_{a}\Pr[a\in N(R)](k/n+\zeta) d+d\sum_a\Pr\left[E_\zeta(a)^\complement\right]\\ &\le \sum_{a}\Pr[a\in N(R)](k/n+\zeta) d+dn^{-9}.\label{eq:blah} \end{align} Combining equations \eqref{eq:blah3} and~\eqref{eq:blah} we have for any $\theta\in(0,1)$ and $\lambda>0$, \begin{align*} \mathbb{E}_M[H_T]&\ge \sfrac1{4d}\sum_{a}\Pr[a\in N(R)](1-L(\lambda,\theta,d,|R|))(d-\theta d)\\&\phantom{ge}-\sfrac1{4d}\left(\sum_{a}\Pr[a\in N(R)](k/n+\zeta) d+dn^{-9}\right)\\ &= \sfrac14\sum_a\Pr[a\in N(R)]\left\{\left(1-L(\lambda,\theta,d,|R|)\right)(1-\theta)-\sfrac{k}{n}-\zeta\right\}-\sfrac14n^{-9}. \end{align*} Choosing $\lambda=0.05$, $\theta=\frac{9}{16}-\frac{k}{2n}$ and using the bound $|R|/n\le \frac12-\frac{k}{2n}$, we have \textcolor{black}{precisely as in the paragraph following \eqref{eq:expec_diff4} }that \[ \sfrac1{d}\log L(\lambda,\theta,d,|R|)=-\lambda\theta +(e^\lambda-1)(1/32+|R|/n)\le -0.0008, \] and so since $\zeta\le 1/16$ and $d\ge 10^4$ we obtain the bound \[ \mathbb{E}_M[H_T]\ge \sfrac1{64}\mathbb{E}[|N(R)|]-\sfrac14n^{-9}\ge \sfrac1{64}\mathbb{E}[|N(R)|]-\sfrac14n^{-8}|R|. \] Notice now that $\mathbb{E}[|N(R)|]=|R|\,\Pr_{\pi_R}(X_T\in \mathrm{Nice}(R))$, for $(X_t)$ a realisation of RW$(G)$, and so by Lemmas~\ref{L:niceC} and~\ref{L:piNice} we have that, since $C_\mathrm{round}>C_{\ref{L:piNice}}(10^{-4})$ (and as there is no degree-inflation $d_\mathrm{max}^\mathrm{in}=\hat d$), \begin{align*}\mathbb{E}[|N(R)|]\ge |R|(\pi(\mathrm{Nice}(R))-10^{-4})&\ge |R|\left(1-\frac{|R|/n}{1/32+|R|/n}-2\times 10^{-4}\right)\\&\ge |R|\left(\sfrac1{17}-2\times 10^{-4}\right).\end{align*} Thus we obtain $ \mathbb{E}_M[H_T]\ge \alpha_3|R|, $ for all $n$ sufficiently large and any $\alpha_3\le 0.0008$. \end{proof} \begin{proof}[Proof of Proposition~\ref{P:betadeg}] If $k\le 10^{-5}n$ we make use of Lemma~\ref{L:losslargedegree} with $\zeta=1/16$. Recall the definition of $m_{\frac1{16},n,k}$ from Corollary~\ref{C:black}. We have the bound $$\sfrac1{32} d m_{\frac1{16},n,k}\ge \sfrac1{32} C_\mathrm{deg}\log n\left(1-\frac{\log(16e^2)}{\log (10^5)} \right)\ge \sfrac1{64}C_\mathrm{deg}\log n$$ and so combining Corollary~\ref{C:black} and Lemma~\ref{L:losslargedegree} \textcolor{black}{with $\zeta=1/16$} we deduce that if $C_\mathrm{deg}\ge 1000$ and $C_\mathrm{round}>C_{\ref{L:piNice}}(10^{-4})$ then $\beta(\alpha_3,C_\mathrm{round}t_\mathrm{rel})\le n^{-10}$ for some universal $\alpha_3>0$. On the other hand if $k>10^{-5}n$ then we will instead make use of Lemma~\ref{L:losslargedegree} with $\zeta=\frac14\times 10^{-5}$. We have the bound (for each $\varepsilon\in(0,1)$) $\sfrac12d\varepsilon m_{\varepsilon,n,k}\ge \sfrac1{4}d\varepsilon^2\sfrac{n}{k}\left(\sfrac12-\sfrac{\varepsilon n}{k}\right) $ and so with $\varepsilon=\zeta=\sfrac14\times 10^{-5}$ we obtain $\sfrac12d\varepsilon m_{\varepsilon,n,k}\ge 10^{-13}d$ and therefore for $C_\mathrm{deg}$ sufficiently large (e.g.\ $10^{21}$) and $C_\mathrm{round}>C_{\ref{L:piNice}}(10^{-4})$ we get using Corollary~\ref{C:black} with Lemma~\ref{L:losslargedegree} that $\beta(\alpha_3,C_\mathrm{round}t_\mathrm{rel})\le n^{-10}$ for some universal $\alpha_3>0$.\end{proof} \section{Mixing for sublinear number of particles: proof of Theorem~\ref{thm:main3}}\label{SS:thm2proof} We consider separately two cases depending on the growth rate of $k$. \subsection{The case $\sqrt n\le k\le n^\delta$} We further split into two sub-cases depending on the degree. The first is for $d\ge C_\mathrm{deg}/(1-\delta)$ where $C_\mathrm{deg}$ is the constant (of the same name) from Theorem~\ref{thm:maindeg}. The proof of Theorem~\ref{thm:main3} in this case follows immediately by Theorem~\ref{thm:maindeg} \textcolor{black}{(recall that $t_{\mathrm{sp}}(n^{-a}) \asymp_a \rel \log n $)}. The second sub-case is for $d<C_\mathrm{deg}/(1-\delta)$. In this case the analogue of Proposition~\ref{P:beta} (to obtain a bound on the probability that a configuration is not $(\alpha,t)$-good after a burn-in) for this case is the following. \begin{proposition}\label{P:beta3} There exist constants $\alpha_\delta, C_\mathrm{deg}, C_\delta >~0 $, such that for all $n$ sufficiently large if $k\le n^{\delta}$ and $d<C_\mathrm{deg}/(1-\delta)$, then $\beta(\alpha_\delta,C_\mathrm{\delta}\rel)\le n^{-10}$. \end{proposition} To complete the proof of Theorem~\ref{thm:main3} for this case we apply the same arguments as in the proof of Theorem~\ref{thm:main1} (general mixing bound) in \S\ref{s:proofofmain} using Proposition~\ref{P:beta3} in place of Proposition~\ref{P:beta}. To prove Proposition~\ref{P:beta3} in the regime where $|R|\wedge|W|$ is small we need the following lemma to control black particles. The proof of this lemma is omitted as it is similar to the proof of Lemma~\ref{L:losslargedegree}. The degree-inflation referred to in the statement is with $\hat d=\lceil C_\mathrm{deg}/(1-\delta)\rceil$. \begin{lemma}[Proof omitted]\label{L:lossdelta2} Let $\delta\in (0,1)$ and $\zeta\in(0,1/16]$ and consider the case $k\le n^{\delta},\,d<\sfrac{C_\mathrm{deg}}{1-\delta}$. There exist constants $C_\delta,\varrho_\delta$ such that if $C_\mathrm{round}> C_\delta$ then any configuration $M=(B,R,\eset,W)$ of the chameleon process with $|R|\wedge |W|<\varrho_\delta n$ satisfying \[ \max_{v\in V}\Pr\left[\sum_{u:\,v\stackrel{\rightarrow}{\sim}u}\indic{u\in \mathrm{B}_T}\ge (k/n+\zeta)\sfrac{C_\mathrm{deg}}{1-\delta}\Bigm| \mathrm{B}_0=B\right]\le n^{-10} \] is $(\alpha_\delta,T)$-good, for $T=C_\mathrm{round}t_\mathrm{rel}$, $\alpha_\delta>0$ a constant depending only on $\delta$, and all $n$ sufficiently large. \end{lemma} \begin{proof}[Proof of Proposition~\ref{P:beta3}] Suppose (as in the proof of Proposition~\ref{P:beta}) that $t\ge t_0$. Let $\varrho_\delta$ be the constant from Lemma~\ref{L:lossdelta2}, let $\hat d$ equal $\lceil C_\mathrm{deg}/(1-\delta)\rceil$, and suppose $|R|\wedge|W|<\varrho_\delta n$. By Corollary~\ref{C:black} we have that for any $\varepsilon>0$, $B\in(V)_{k-1}$, $v\in V$, and $n=n(\varepsilon)$ sufficiently large, \begin{align*} &\Pr\left[\Pr\big[\sum_{u:\,u\sim v}\indic{u\in \mathrm{B}_{T+t}}\ge\left(\sfrac{k}{n}+\varepsilon\right)\hat d\Bigm| \mathcal{F}_{t}\big]\ge \exp\left(-\sfrac{(1-\delta) \hat d\varepsilon}{4}\log{n}\right)\Bigm| \mathrm{B}_0=B\right]\\&\le \exp\left(-\sfrac{(1-\delta) \hat d\varepsilon}{4}\log{n}\right). \end{align*} Taking $\varepsilon=1/16$ we deduce by Lemma~\ref{L:lossdelta2} that there exist constants $C_\delta,\alpha_\delta>0$ such that if $C_\mathrm{round}>C_\delta$ then with probability at least $1-n^{-10}$, $M_t$ is $(\alpha_\delta,T)$-good, for $T=C_\mathrm{round}t_\mathrm{rel}$, i.e.\ $\beta(\alpha_\delta,t_\mathrm{round}-1)\le n^{-10}$. On the other hand if $|R|\wedge|W|\ge\varrho_\delta n$ then set $C_{\ast}= C_\ast^0\vee \sfrac{C_\mathrm{deg}}{(1-\delta)\log(1/\varrho_\delta)}$. Then by Lemma~\ref{L:losssmalldbigR1} with $\varrho=\varrho_\delta$ there exist constants $\alpha_4(\delta)>0$ and $C_\mathrm{round}^0(\delta)$ such that if $C_\mathrm{round}>C_\mathrm{round}^0(\delta)$ then with probability at least $1-n^{-10}$, $M_{t}$ is $(\alpha_4,T)$-good, for $T=C_\mathrm{round}t_\mathrm{rel}$, i.e.\ $\beta(\alpha_4,t_\mathrm{round}-1)\le n^{-10}$. \end{proof} \subsection{The case $k<\sqrt n$} In this case we require a different chameleon process. This new version of the chameleon process has rounds of varying duration. To be precise, the duration of each burn-in period is taken to be $\mix^{(\infty)}(\hat c /k )$ for some absolute constant $\hat c \in (0,1)$ chosen to be as large as possible while satisfying the requirements described in Remark~\ref{R:black}. Further, if at the beginning of the $j$th round we have $r $ red particles, the round starts with an $(\alpha,L(r)-1)$-good configuration, where if $r \wedge (n-|\mathrm{B}_0|-r) \in (2^{i-1},2^i] $ then \begin{equation} \label{e:L(r)def} L(r)=L_{i}:=C_{\mathrm{round}} /\Lambda(C_{\mathrm{profile}}2^{i}/n) + 1, \end{equation} where $\Lambda(\bullet)$ is as in \S\ref{s:profiles}, for some absolute constants $C_{\mathrm{round}},C_{\mathrm{profile}}>0$ to be determined later. The constant-colour ``relaxation'' phase for such a round is of duration $L(r)-1$, while the pinkening phase is again of unit length. Thus the duration of the $j$th round is $t_\mathrm{round}(j):=L(|\mathrm{R}_{\rho_j}|) $ and so $\hat \tau_j :=\rho_j+L(|\mathrm{R}_{\rho_j}|) $, where $\rho_j$ and $\hat \tau_j$ still denote the beginning and end of the $j$th round. At the end of such a round we follow the same rule as in the constant-round chameleon depinking procedure, apart from the fact that we replace above $p(M_{\rho_i},t_\mathrm{round}-1)$ by $p(M_{\rho_i},L(|\mathrm{R}_{\rho_j}|)-1) $. If after a depinking time we have $r$ red particles, then we start the following round immediately if the current configuration is $(\alpha,L(r)-1)$-good. Otherwise, we perform a sequence of burn-in periods of duration $t_{\mathrm{mix}}^{(\infty)}(\hat c /k ) $ until the end of the first burn-in period after which we have an $(\alpha,L(r)-1)$-good configuration, where $r$ denotes the number of red particles at the end of this burn-in. \textcolor{black}{Recall the process $\hat M_t$ used in the definition of $\beta(\alpha,t)$ in \eqref{e:beta1}.} Let $t_1 := t_{\mathrm{mix}}^{(\infty)}(\hat c /k ) $ and for $i \le \lceil \log_2 (\sfrac{n-k+1}{2}) \rceil $ define \begin{equation} \label{e:beta2}\begin{split} &\beta_{i}(\alpha):= \max_{B,R,W}\sup_{s \ge t_{1} } \Pr[\hat M_s \text{ is not $(\alpha,L_{i}-1)$-good} \mid \hat M_0=(B,R,W)],\end{split} \end{equation} where the maximum is taken over all partitions of $V$ into sets $\mathbf{O}(B),R,W$ satisfying that $|R| \wedge |W| \in (2^{i-1},2^i] $ and $B \in (V)_j $ for some $j < \sqrt{n}$ satisfying $\{B(i):i \in [j] \} =\mathbf{O}(B) $. We will show that if $k=|\mathrm{B}_0|+1 \le \sqrt{n} $ then for some absolute constant $\alpha,C >0 $, we have that $\max_{i \le \lceil \log_2 (\sfrac{n-k+1}{2}) \rceil }\beta_i \le n^{-10} $ (Proposition \ref{P:beta4}). Recall Proposition~\ref{p:chambound2} from \S\ref{S:cham}. The following proposition serves as its replacement for this setting. In simple words, it asserts that for some absolute constant $M$, if no additional burn-in periods occurred (other than the initial one, whose duration is $t_{\mathrm{mix}}^{(\infty)}(\hat c /k )$) by time $t_{\mathrm{mix}}^{(\infty)}(\hat c /k )+Mt_{\mathrm{sp}}(\sfrac{1}{4s} )$, then for all $s \in [k,n^3] $ the expected fraction of ``missing ink" at time $t_{\mathrm{mix}}^{(\infty)}(\hat c /k )+Mt_{\mathrm{sp}}(\sfrac{1}{4s} ) \lesssim t_{\mathrm{sp}}(\sfrac{1}{4s} ) $ would be at most $s^{-1}$. This assertion is similar to the treatment of the chameleon process in \cite{morris}, where $t_{\mathrm{evolving-sets}}$ is used instead of $t_{\mathrm{sp}}$. While it seems that one can derive it from the analysis in \cite{morris}, we give a different proof, which we believe to be simpler. \begin{proposition}[{Proof in in Appendix~\ref{s:upperhard}}] \label{p:chambound3} There exists an absolute constant $M$ such that for all $s \in [k,n^3] $, $k \le \sqrt{n} $ and $(\mathbf{w},y)\in (V)_k $ \textcolor{black}{with $\mathbf{w}\in (V)_{k-1}$ and $y\in V$}, if we write $\hat t(s):=t_{\mathrm{mix}}^{(\infty)}(\hat c /k )+Mt_{\mathrm{sp}}(\sfrac{1}{4s} ) $, then \begin{equation} \label{e:IPtoCP''} \begin{split} {\mathbb{\widehat{E}}}_{(\mathbf{w},y)}[ 1 - {\mathrm{ink}}_{\hat t(s)} / (n-k+1) ] & \le s^{-1} +Mt_{\mathrm{sp}}(\sfrac{1}{4s} ) (n-k+1) \max_{i< \lceil \log_2 (n-k+1) \rceil } \beta_{i}(\alpha). \end{split} \end{equation} \end{proposition} The next proposition serves as the replacement of Proposition~\ref{P:beta}. \begin{proposition}\label{P:beta4} There exist constants $\alpha_\frac12, C_\mathrm{round}, C_\mathrm{profile} >~0 $, such that for all $n$ sufficiently large if $k\le \sqrt n$ then $\max_{i < \lceil \log_2 (n-k+1) \rceil }\beta_i(\alpha_\frac12)\le n^{-10}$ (recall that the definition of $\beta_i$ depends on constants $C_\mathrm{round},C_\mathrm{profile}$ through the definition of $L_i$). \end{proposition} \begin{proof}[Proof of Theorem~\ref{thm:main3}] The result has already been shown for the case of $\sqrt n\le k\le n^\delta$, so it remains to prove the result for $k<\sqrt n$. Using sub-multiplicativity we have that $\mixex((2n)^{-i})$ $\le i\mixex(\sfrac{1}{4n})$. It follows that it suffices to consider $ \varepsilon \in [\sfrac{1}{4n},\sfrac1{4k}] $. Combining Propositions \ref{p:chambound}, \ref{p:chambound3} and \ref{P:beta4} concludes the proof, upon observing that the term \[Mt_{\mathrm{sp}}(\sfrac{1}{4s} ) (n-k+1) \max_{i\le \lceil \log_2 (\sfrac{n-k+1}{2}) \rceil} \beta_{i}(\alpha)\] in the r.h.s.\ of \eqref{e:IPtoCP''} is at most $\lesssim n^{-10} \times n \times n^2 \log n $ (using $\max_i \beta_{i}(\alpha) \le n^{-10}$ and $t_{\mathrm{sp}}(\varepsilon) \lesssim \rel \log (n/\varepsilon) \lesssim n^2 \log (n/\varepsilon) $ for $\varepsilon \le 1/2$, e.g.\ \cite{sensitivity,Lyonsev}). \end{proof} We require two lemmas for the proof of Proposition~\ref{P:beta4}. The first is a modification of Lemma~\ref{L:piNice} suitable for this setting. Instead of using the Poincar\'e inequality we use \eqref{e:spb3} to bound $ \|\Pr_{\pi_S}[X_T\in\bullet]-\pi\|_{2,\pi}^2$. \begin{lemma}[{Proof in Appendix~\ref{proofpiNice}]}]\label{L:piNice2} We denote the uniform distribution on $S$ by $\pi_S $. For each $\varepsilon\in(0,1)$, there exist $C_{\ref{L:piNice2}}(\varepsilon), C_\mathrm{p}(\varepsilon)>1$ such that for all $C_\mathrm{round}>C_{\ref{L:piNice2}}(\varepsilon)$, $C_\mathrm{profile}>C_\mathrm{p}(\varepsilon)$ and all $S\subset V$ with $2|S|\le n$, \[\Pr_{\pi_S}[X_T\in\mathrm{Nice}(S)]\ge\pi(\mathrm{Nice}(S))-\varepsilon,\] for any $T\ge C_\mathrm{round}/\Lambda(C_\mathrm{profile}|S|/n).$ \end{lemma} We will also use the following lemma. The proof is very similar to the proof of Lemma~\ref{L:losslargedegree} except instead of using Lemma~\ref{L:piNice} to bound $\mathbb{E}[|N(R)|]$ we use Lemma~\ref{L:piNice2} which is where the bound on $C_\mathrm{profile}$ originates. \begin{lemma}[Proof omitted]\label{L:losshalf} Let $\zeta\in(0,1/16]$ and consider the case $k\le \sqrt n$. There exist constants $C_{\frac12}, C_\mathrm{p}, \varrho_{\frac12}$ such that if $C_\mathrm{round}> C_\frac12$ and $C_\mathrm{profile}>C_\mathrm{p}$ then any configuration $M=(B,R,\eset,W)$ of the chameleon process with either (i) $|R|\wedge|W|<\varrho_{\frac12} n$ and $d<2\times 10^4$, or (ii) $d\ge 2\times 10^4$; and satisfying \[ \max_{v\in V}\Pr\left[\sum_{u:\,v\stackrel{\rightarrow}{\sim}u}\indic{u\in \mathrm{B}_T}\ge (k/n+\zeta)\hat d\Bigm| \mathrm{B}_0=B\right]\le n^{-10} \] with $\hat d=2\times 10^4$ in case (i) and $\hat d=d$ in case (ii), is $(\alpha_\frac12,T)$-good, for $T\ge C_\mathrm{round}/\Lambda(C_\mathrm{profile}|R|/n)$, $\alpha_\frac12>0$ a universal constant, and all $n$ sufficiently large. \end{lemma} \begin{proof}[Proof of Proposition~\ref{P:beta4}] Recall the notation $t_1 := t_{\mathrm{mix}}^{(\infty)}(\hat c /k ) $ and let $t\ge t_1$. Let $\varrho_\frac12$ be the constant from Lemma~\ref{L:losshalf} and suppose either (i) $|R|\wedge|W|<\varrho_\frac12 n$ and $d<2\times 10^4$ or (ii) $d\ge2\times 10^4$. By Corollary~\ref{C:black} and Remark~\ref{R:black} following it (and recalling the choice of $\hat c$) we have that for any $\varepsilon>0$, $B\in(V)_{k-1}$, $v\in V$, and $n=n(\varepsilon)$ sufficiently large, \begin{align*} &\Pr\left[\Pr\big[\sum_{u:\,u\sim v}\indic{u\in \mathrm{B}_{T+t}}\ge\left(\sfrac{k}{n}+\varepsilon\right)\hat d\Bigm| \mathcal{F}_{t}\big]\ge \exp\left(-\sfrac{ \hat d\varepsilon}{2}\log{(\varepsilon \sqrt n /e^2)}\right)\Bigm| \mathrm{B}_0=B\right]\\&\le \exp\left(-\sfrac{ \hat d\varepsilon}{2}\log{(\varepsilon \sqrt n /e^2)}\right) \end{align*} (with $\hat d=2\times 10^4$ in case (i) and $\hat d=d$ in case (ii)). Taking $\varepsilon=1/16$ we deduce by Lemma~\ref{L:losshalf} with $|R|\textcolor{black}{\wedge|W|}\in(2^{i-1},2^i]$ that there exist constants $C_\mathrm{\frac12}$ and $C_\mathrm{p}$ such that if $C_\mathrm{round}>C_{\frac12}$ and $C_\mathrm{profile}>C_\mathrm{p}$ then with probability at least $1-n^{-10}$, $M_{t}$ is $(\alpha_\frac12, T)$-good, for $T=C_\mathrm{round}/\Lambda(C_\mathrm{profile}2^i/n)$, i.e.\ $\beta_i(\alpha_\frac12)\le n^{-10}$. On the other hand, if $|R|\wedge |W|\ge\varrho_\frac12 n$, then set $C_{\ast,\frac12}= C_\ast^0\vee \sfrac{10^4}{\delta\log(1/\varrho_\frac12)}$. Then by Lemma~\ref{L:losssmalldbigR1} with $\varrho=\varrho_\frac12$ there exist constants $\hat\alpha_\frac12>0$, $C^0_\mathrm{round}$, $\hat C_\mathrm{p}$ (chosen so that for any $|R|\ge\varrho_\frac12 n$ we have $\Lambda(\hat C_\mathrm{p}|R|/n)=1/\rel$) such that if $C_\mathrm{round}>C^0_\mathrm{round}$ and $C_\mathrm{profile}>\hat C_\mathrm{p}$ then with probability at least $1-n^{-10}$, $M_{t}$ is $(\hat\alpha_\frac12,T)$-good, for $T=C_\mathrm{round}/\Lambda(C_\mathrm{profile}2^i/n)$, i.e.\ $\beta_i(\hat\alpha_\frac12)\le n^{-10}$. \end{proof} \section{Lower bounds: proof of Theorem \ref{thm:lower} and Proposition \ref{p:mixexkatleastmixrw1}} \label{s:lower} Recall that $\Pr_F^{\mathrm{EX}(k)}$ is the distribution of the exclusion process with initial set $F$. We denote by $\Pr_{\mu}^t$ (resp.~$\Pr_{\mu}$) the distribution of $X_t$ (resp.~$(X_t)_{t \ge 0 }$), given that the initial distribution is $\mu $. \noindent \emph{Proof of Theorem \ref{thm:lower}.} By the spectral decomposition $-\mathcal{L} $ has eigenvalues $0=\lambda_1 < \lambda_2 \le \cdots \le \lambda_n $. Denote the corresponding orthonormal basis (w.r.t.\ $\langle \bullet, \bullet \rangle_{\pi} $) of eigenvectors by $f_1=\mathbf{1} ,f_2,\ldots,f_n $. W.l.o.g.\ we may assume that $\lambda=\lambda_i$, $f=f_i$ and that $t=t(k,\delta,\varepsilon,\lambda):=\frac{1}{2\lambda}(4\delta\log k - \log (16/\varepsilon ) ) \ge 0$. Consider $B:=\{f \ge 0 \}$. W.l.o.g.\ $|B| \ge n/2 $ (otherwise consider $-f$). Let $F \in \binom{V}{k} $ be such that $\mathbb{E}_{F}[|A_t \cap B| ]=\max_{J \in \binom{V}{k}}\mathbb{E}_{J}[|A_t \cap B| ] $. Then by negative correlation \begin{equation} \label{e:VarF} \begin{split} \mathrm{Var}_{\pi_{\mathrm{EX}(k)}}|A_0 \cap B|& \le \mathbb{E}_{\pi_{\mathrm{EX}(k)}}[|A_0 \cap B| ]=k \pi(B). \\ \mathrm{Var}_{F}|A_t \cap B| &\le \mathbb{E}_{F}[|A_t \cap B| ]. \end{split} \end{equation} Denote $\sigma^2:=\ssfrac{1}{2} ( \mathrm{Var}_{\pi_{\mathrm{EX}(k)}}|A_0 \cap B|+ \mathrm{Var}_{F}|A_t \cap B|) $. By the standard method of distinguishing statistics \cite[Proposition 7.12]{levin} if $a:=|\mathbb{E}_{F}[|A_t \cap B| ]-\mathbb{E}_{\pi_{\mathrm{EX}(k)}}[|A_0 \cap B| ]|^{2} \ge 4r\sigma^2 $, then \[\|\Pr_F^{\mathrm{EX}(k)}(A_t \in \bullet) -\pi_{\mathrm{EX}(k)} \|_{\TV} \ge 1- \sfrac{1}{1+r}. \] We will show that $a \ge 4k/\varepsilon $, which means that we can take above $r=1/\varepsilon$, as \[k \ge \ssfrac{1}{2} ( \mathbb{E}_{\pi_{\mathrm{EX}(k)}}[|A_0 \cap B| ] + \mathbb{E}_{F}[|A_t \cap B| ] )\ge \sigma^2 , \] where the first inequality is trivial and the second inequality follows from \eqref{e:VarF}. If $D \sim \mathrm{Unif}(\{U \subseteq B:U \in \binom{V}{k} \}) $, $\pi_B $ is the uniform distribution on $B$ and $(X_s)_{s \in \mathbb R_+}$ is a random walk on the network $(G,(r_e:e \in E))$ then using the maximality of $F$ (first inequality) and the spectral decomposition in the third equality (namely, $1_B=\pi(B)+ \sum_{j=2}^n \sum_{b \in B}\pi(b)f_j(b) f_j $) \begin{equation*} \begin{split} & \mathbb{E}_{F}[|A_t \cap B| ] \ge \mathbb{E}_{D}[|A_t \cap B| ]= k \Pr_{\pi_B}[X_t \in B ]=\sfrac{k}{\pi(B)}\langle P_t 1_B,1_{B}\rangle_{\pi} \\ &=k \pi(B)+\sfrac{k}{\pi(B)} \sum_{b' \in B}\pi(b')\sum_{j>1} \sum_{b\in B }\pi(b) f_j(b)f_j(b') e^{- \lambda_j t} \\ & \text{(write $b_j:=\sum_{b \in B }\pi(b) f_j(b)$)} \quad =k \pi(B)+\sfrac{k}{\pi(B)}\sum_{j>1} b_j^2 e^{- \lambda_j t} \\ & \ge k \pi(B)+\sfrac{k}{\pi(B)}b_{i}^2 e^{- \lambda t} = k \pi(B)+\sfrac{k}{2\pi(B)}\|f\|_1^{2}e^{- \lambda t}, \end{split} \end{equation*} where we used the fact that $f=f_i $ is orthogonal to $f_1=\mathbf{1}$ and thus $\mathop{\mathbb E}_{\pi}f=0 $ and $\sum_{b \in B }\pi(b) f_i(b)=\mathop{\mathbb E}_{\pi}[f \vee 0] =\|f\|_1/2 $. We get that $a\ge k^{2} \|f\|_1^{4}e^{-2 \lambda t}/4 $. By the choice $t= \frac{1}{2\lambda}(4\delta\log k - \log (16/\varepsilon ) ) $ and the assumption $\|f\|_1^{4} \ge k^{-1+4 \delta } $ we get that $a \ge k^{2} \|f\|_1^{4}e^{-2 \lambda t}/4 \ge k(4/ \varepsilon) \ge 4 \sigma^2 / \varepsilon $, \textcolor{black}{as desired.} \qed \begin{remark} It is interesting to note that when $\|f\|_1 \le k^{-1/8}$ for some unit eigenfunction $f$ as above, it follows from H\"older's inequality that $\|f \|_{\infty} \ge \|f\|_2^2/\|f\|_1 \ge k^{1/8}$ (the exponent $1/8$ in $\|f\|_1 \le k^{-1/8}$ is taken as some arbitrary constant smaller than $1/4$, the exponent appearing in Theorem \ref{thm:lower}). In this case, Wilson's method (\cite{Wilson}, see \cite[\S\ 13.5]{levin} for a systematic presentation of the method) can sometimes yield that $\mix^{{\mathrm{RW}}(1)} \ge c \lambda^{-1}\log k$. We note that in \cite{Wilson} Wilson applied his method to prove a lower bound on the mixing time of $\mathrm{EX}(2^{d-1}) $ and ${\mathrm{IP}}(2^d)$ for the hypercube $\{ \pm 1\}^d $. Our argument is different, in that we obtain control on the variances ``for free" as a consequence of negative correlation. \end{remark} \noindent \emph{Proof of Proposition \ref{p:mixexkatleastmixrw1}} As processes EX$(k)$ and EX$(n-k)$ are identical it suffices to consider $k\le n/2$. For fixed such $k$ and $x\in V$, let $B$ be the set of vertices $y$ having the $k$ smallest $P_t(x,y)$ values, where $t=22\mixex$. By submultiplicativity $t\ge 2\mixex(2^{-11})$. Set $\delta := \max_{y \in B} P_t(x,y)$ so that $P_t(x,B) \leq \delta k$. \textcolor{black}{Using the general fact that \[ \min_{C \in \binom{V}{k}}P_t^{\mathrm{EX}(k)}(B,C)/\pi_{\mathrm{EX}(k)}(C) \geq (1-2 \|P_{t/2}^{\mathrm{EX}(k)}(B,\cdot) - \pi_{\mathrm{EX}(k)} \|_{\mathrm{TV}})^2 \] (e.g. Lemma 7 of Chapter 4 of~\cite{aldous}) we also have} \[\textcolor{black}{P_t(x,B)=\sum_{C:\,x\in C}P_t^{\mathrm{EX}(k)}(B,C)\ge\sum_{C:\,x\in C}\frac{(1-2^{-10})^2}{\binom{n}{k}} = \frac{k}{n}(1-2^{-10})^2.}\] Hence we obtain the bound $\delta\ge \sfrac1{n}(1-2^{-10})^2$. We distinguish between two cases depending on the value of $k$. Consider first the case $k\le n/8$. We have the bound \begin{align*} \sum_y\left(\sfrac1{n}-P_t(x,y)\right)_+&=\sum_{y\in B}\left(\sfrac1{n}-P_t(x,y)\right)_++\sum_{y\notin B}\left(\sfrac1{n}-P_t(x,y)\right)_+\\ &\le \frac{k}{n}+(n-k)\left(\sfrac1{n}-\delta\right)\\& \le1-\left(1-2^{-10}\right)^2(1-k/n)<1/4. \end{align*} Now consider the case $k>n/8.$ We note that $\delta(n-k)\le\sum_{y\notin B}P_t(x,y)\le 1$ and so as $k\le n/2$ we obtain $\delta\le 2/n$. Thus by a simple counting argument (using $P_t(x,B)\ge \sfrac1{8}\left(1-2^{-10}\right)^2$ as $k>n/8$) there must be at least $\sfrac{n}{32}$ vertices $b\in B$ satisfying $P_t(x,b)\ge \sfrac1{8n}\left(1-2^{-10}\right)^2$. Thus we have the bound \begin{align*} \sum_y\left(\sfrac1{n}-P_t(x,y)\right)_+&=\sum_{y\in B}\left(\sfrac1{n}-P_t(x,y)\right)_++\sum_{y\notin B}\left(\sfrac1{n}-P_t(x,y)\right)_+\\ &\le \frac{n}{32}\left(\sfrac{1}{n}-\sfrac1{8n}\left(1-2^{-10}\right)^2\right)+\frac{1}{n}\left(k-\sfrac{n}{32}\right)+(n-k)\left(\sfrac1{n}-\delta\right)\\ &\le 1-\left(1-2^{-10}\right)^2\left(\sfrac12+\sfrac1{256}\right)<\frac12-2^{-9}. \end{align*} Thus, combining the two cases, we obtain that for all $k\le n/2$, \[ \mixrw\left(\frac12-2^{-9}\right)\le 22\mixex, \] and hence there exists a constant $c$ ($2^{-13}$ suffices) so that $c\mixrw\le \mixex$ for all $k\in[n-1]$.\qed \section{Examples} \label{s:examples} We present three additional applications of our results. In the following we denote by $B_r $ a ball of radius $r$. We prove the claimed bounds on $r_\ast(c_{1.1})$ in \S\ref{s:mod}. In \S\ref{s:hypercube} we show how we can apply our results to product graphs and in particular obtain the bounds claimed in \S\ref{ss:main} for the hypercube. \begin{itemize} \item[(i)] For an $n$-vertex $d$-regular vertex-transitive graph satisfying $|B_r| \ge ce^{cr} $ for all $r $ such that $|B_r| \le \sfrac{4}{c_{1.1}} \log n $, for some $c>0$, we have that $r_*(c_{1.1}) \lesssim d^{2} (\log \log n)^3 $ (see Proposition \ref{p:expamples}). Hence (by Theorem \ref{thm:main1}) $\max_k \mixex \lesssim \rel \log n $, provided that $\rel \gtrsim d^{2}(\log \log n)^3 $. \item[(ii)] For an $n$-vertex $d$-regular vertex-transitive graph satisfying $|B_r| \ge ce^{cr^{\alpha}} $ for all $r $ such that $|B_r| \le \sfrac{4}{c_{1.1}}\log n $, for some $\alpha \in (0,1)$ and $c>0$, we have that $r_*(c_{1.1}) \lesssim d^{2} (\log \log n)^{1+\sfrac{2}{\alpha}} $ (see Proposition \ref{p:expamples}). Hence $\max_k \mixex \lesssim \rel \log n $, provided that $\rel \gtrsim d^{2} (\log \log n)^{1+\sfrac{2}{\alpha}}$. In particular, this holds if $|B_r| \le Ce^{Cr^{\beta}} $ for all $r $, for some $\beta \in (0,1)$ and $C>0$ (as this implies that $\rel \gtrsim \sfrac{\mathrm{Diameter}}{\log n} \gtrsim (\log n)^{(1-\beta)/\beta} $). \item[(iii)] The following example is taken from \cite[\S4.2.1]{spectral} (we refer the reader there for the relevant definitions; See also \cite{Nash}, where it is shown that Cayley graphs of moderate growth satisfy a local-Poincar\'e inequality, and many other examples are given). If $G$ is a $d$-regular graph of diameter $\gamma$ and $(A,c)$-moderate growth, satisfying a local-Poincar\'e inequality with a constant $a$, then $\rel \asymp \gamma^2 \asymp t_{\mathrm{sp}}(\sfrac{1}{4}) $ (with the implicit constants depending on $d,A,c $ and $a$); $\rel \asymp \gamma^2 $ is due to Diaconis and Saloff-Coste \cite[Theorem 3.1]{moderate} (cf.\ our \S\ref{s:mod}). By Corollary \ref{cor:example}, $\mixex \asymp_{a,d,A,c} \gamma^2 \log (k+1)$ uniformly in $k$. \end{itemize} \subsection{Vertex-transitive graphs and the giant component of super-critical percolation} \label{s:mod} Let $G=(V,E)$ be an $n$-vertex connected graph. We say that $G$ is \emph{vertex-transitive} if the action of its automorphism group on its vertices is transitive. Denote the volume of a ball of radius $r$ in $G$ by $V(r)$. Denote the diameter of $G$ by $\gamma:=\inf\{r:V(r) \ge n \} $. Following Diaconis and Saloff-Coste we say that $G$ has $(c,a)$-\emph{moderate growth} if $V(r) \ge cn(r/\gamma)^a $. \textcolor{black}{Breuillard and Tointon \cite{Matt} proved that for Cayley graphs of constant degree, this condition is equivalent in some quantitative sense to the condition that $n \le \beta \gamma^{\alpha} $ for some $\alpha,\beta > 0$, which is of course a much simpler condition.} Let $P$ be the transition matrix of simple random walk (SRW) on $G$. We consider the case of continuous-time SRW with $\mathcal{L}=P-I$. Diaconis and Saloff-Coste \cite{moderate} showed that for a Cayley graph $G$ of $(c,a)$-moderate growth we have \[c^2\gamma^2 4^{-2a-1} \lesssim \rel \lesssim t_{\mathrm{mix}}^{(\infty)} \lesssim_{c,a}\gamma^2. \] We note that the proof of $c^2\gamma^2 4^{-2a-1} \lesssim \rel$ works even if $G$ is merely vertex-transitive of $(c,a)$-moderate growth. Namely, they argue that the function $h(x):=\mathrm{distance}(x,\mathbf{o}) $ (for some arbitrary $\mathbf{o} \in V$) satisfies that $\mathrm{Var}_{\pi}h/\mathcal{E}(h,h) \ge \mathrm{Var}_{\pi}h \ge \gamma^{2} (V( \lfloor \gamma/4 \rfloor )/2n)^{2} \ge c^2\gamma^2 4^{-2a-1} $. Indeed, if $h(x)= \gamma $ then for the vertices $y$ in the ball of radius $ r:=\lfloor \gamma/4 \rfloor$ centered at $x$ (resp.\ $\mathbf{o}$) we have $h(y) \ge \frac{3}{4}\gamma $ (resp.\ $\le \sfrac{\gamma}{4} $). Denote these two balls by $B_{x}(r)$ and $B_{\mathbf{o}}(r)$. If $X,Y$ are i.i.d.\ $\pi=\mathrm{Unif}(V)$ then \begin{equation} \label{e:h} \mathrm{Var}_{\pi}h =\sfrac{1}{2}\mathop{\mathbb E} [(h(X)-h(Y))^2] \ge \sfrac{\gamma^{2}}{8}\pi(B_{x}(r))\pi(B_{\mathbf{o}}(r)). \end{equation} Lyons et al.\ \cite[Lemma 7.2]{LMS} showed that for an $n$-vertex vertex-transitive graph, for all $A \subset V $ such that $|A| \le n/2$ we have \begin{equation} \label{e:isoVT} \frac{|\partial_{\mathrm{V}}^{\mathrm{in}} A |}{|A|} \ge \frac{1}{2 R(2|A|) }, \end{equation} where $\partial_{\mathrm{V}}^{\mathrm{in}} A :=\{a \in A:P(a,A^c)>0 \} $ is the internal vertex boundary of $A$ and $ R(m):=\inf\{r:V(r) \ge m \} $ is the inverse growth function \textcolor{black}{(note that $R(m)=\infty$ for $m>n$, and so \eqref{e:isoVT} holds trivially when $|A|>n/2$). (Lemma 7.2 in \cite{LMS} is stated for infinite unimodular graphs, but the proof works verbatim for finite transitive graphs, which are always unimodular. See also \cite[Lemma 10.46]{LyonsPeres}, where $G$ is not assumed to be infinite.)} \begin{proposition} \label{p:moderate} If $G$ is a $d$-regular vertex-transitive of $(c,a)$-moderate growth then \begin{equation} \label{e:VT} c^2\gamma^2 4^{-2a-1} \le \rel \lesssim t_{\mathrm{evolving-sets}}(1/4) \lesssim a (2/c)^{2/a} d^2\gamma^2. \end{equation} Consequentially, (uniformly in $k$) \begin{equation} \label{e:VTEXmix} \mixex \asymp_{c,a,d} \gamma^2 \log (k+1). \end{equation} Similarly, if $G$ is the largest connected component of super-critical percolation on $(Z_t^{(1)}/L Z_t^{(1)})^d$ with parameter $p$ then $\mathrm{w.h.p.}$ (as $L \to \infty $) \begin{equation} \label{e:perc} \gamma^2 \lesssim_{d,p} \rel \lesssim t_{\mathrm{evolving-sets}}(1/4) \lesssim_{d,p} \gamma^2. \end{equation} Consequentially, $\mathrm{w.h.p.}$ (uniformly in $k$) \begin{equation} \label{e:GCEXmix} \mixex \asymp_{d,p} \gamma^2 \log (k+1). \end{equation} \end{proposition} \begin{remark} In the setup of \eqref{e:VT} the bound obtained on $ t_{\mathrm{mix}}^{(\infty)}$ in \cite{Lyonsev} via the spectral measure is often better than the one obtained via $t_{\mathrm{evolving-sets}}$. \end{remark} \begin{proof} We first note that \eqref{e:VTEXmix} and \eqref{e:GCEXmix} follow by combining \eqref{e:VT} and \eqref{e:perc} with \eqref{e:mixproptotsp}. The first inequality in \eqref{e:VT} was discussed above. The corresponding bound in \eqref{e:perc} is obtained by considering the same $h$ as in \eqref{e:h} (noting that the size of any ball of radius $\lfloor \gamma/4 \rfloor$ in the giant component $\mathrm{w.h.p.}$ has volume comparable to the total number of vertices). The middle inequality in \eqref{e:VT} and \eqref{e:perc} follows from \eqref{e:spb1} and \eqref{e:mixrel}. The last inequality in \eqref{e:perc} is taken from \cite{GC}. The proof of the last inequality in \eqref{e:VT} follows by plugging in \eqref{e:profiles} the estimate $\Phi^{-2}(\delta) \lesssim d^2 \gamma^2 (\sfrac{2 \delta}{c} )^{2/a}$, which can be derived via \eqref{e:isoVT}. \end{proof} \begin{proposition} \label{p:expamples} If $G$ is a $d$-regular vertex-transitive graph of size $n$ as in Example (i) (resp.\ (ii)) then \[r_*(c_{1.1}) \le C d^2(\log \log n)^3 \quad (\text{resp.}\ r_*(c_{1.1}) \le C d^2(\log \log n)^{1+\sfrac{2}{\alpha}} ).\] \end{proposition} \begin{proof} As above, use \eqref{e:isoVT} to bound $\Phi^{-2}(\delta) $ for all $\delta \le 4 (\log n) / (c_{1.1}n) $. In the setup of Example (i) \eqref{e:isoVT} yields that $\Phi^{-2}(\delta) \lesssim [d \log (\delta n) ]^2 $ and in that of Example (ii) that $\Phi^{-2}(\delta) \lesssim d^{2}[ \log (n \delta )]^{2/\alpha} $. The assertion of the proposition now follows from \eqref{e:spb1} with $\varepsilon= c_{1.1}n/\log n $. \end{proof} \subsection{The hypercube and product graphs} \label{s:hypercube} We now consider the hypercube $\{\pm 1\}^d$. We consider the case that each edge has rate $1/d$. Then $\rel =\sfrac{d}{2}=2/c_{\mathrm{LS}}$ (see \cite{diaconis}). By Proposition \ref{p:specLS} it is easy to verify that $t_{\mathrm{sp}}(\sfrac{1}{2}) \lesssim d \log d \asymp \mix $. \textcolor{black}{By \eqref{e:rLS}} $r_*(c_{1.1}) \lesssim \log d \ll \rel $. By Theorem \ref{thm:main1} in conjunction with Corollaries \ref{cor:1.9} and \ref{cor:1.11} we get that $\mixex \asymp d \log (dk)$ \textcolor{black}{(for $k \le d $ we use Theorem \ref{thm:lower} to argue that $\mixex \gtrsim d \log d$).} \begin{definition} \label{def:productchains} The Cartesian product $G_1 \times G_2=(V',E')$ of two graphs $G_i=(V_i,E_i) $ is defined via $V':=V_{1}\times V_2 $ and $E':=\{\{(v_{1},v_{2}), (u_{1},u_{2})\}:v_1=u_1 \in V_1 \text{ and }u_1u_2 \in E_2, \text{ or vice-versa} \} $. For a graph $G=(V,E)$ we denote the $d$-fold self (Cartesian) product of $G$ with itself by $G_{\otimes d}=(V^n,E(G_{\otimes n}))$. That is $G_{\otimes d}=G_{\otimes (d-1)} \times G=G \times \cdots \times G $. \end{definition} \textcolor{black}{Note that the $d$-dim hypercube is the $d$-fold self-product of the complete graph on two vertices with itself. Consider the case that $G$ is $d_G$-regular. Then $G_{\otimes d}$ is $d \times d_G$ regular. Consider $\mathrm{EX}(k)$ on $G_{\otimes d}$ in which each edge rings at rate $\frac{1}{d d_G} $. We extend the above argument and show that $\mixex \asymp d \log (dk)$ (all asymptotic notation here is as $d \to \infty$ for a fixed $G$ and some implicit constants may depend on $G$). We note that the analysis below can easily be extended to the case of $\mathrm{EX}(k)$ on $G_1 \times \cdots \times G_{d}$ with the $G_i$'s being of uniformly bounded size. The regularity condition can be lifted as well. Indeed if the $G_i$'s are of uniformly bounded size, then all vertices of $G_1 \times \cdots \times G_{d}$ are of degree proportional to $d$. As explained in Appendix \ref{s:relax} our analysis can be extended to cover this case. } \textcolor{black}{ A general result about the log-Sobolev constant of a product chain asserts that $c_{\mathrm{LS}}(G_{\otimes d})$ the log-Sobolev constant of the random walk on $G_{\otimes d}$ (with the above rates) is $c_{\mathrm{LS}}(G)/d $, where $c_{\mathrm{LS}}(G)$ is the log-Sobolev constant of a random walk on $G$, and likewise $\rel(G_{\otimes d})=d\rel(G) $ (see \cite{diaconis}). By Proposition \ref{p:specLS} we get that $t_{\mathrm{sp}}^{G_{\otimes d}}(\sfrac{1}{2}) \lesssim \frac{ d \log (d \log |G|)}{c_{\mathrm{LS}}(G)}$. \textcolor{black}{By \eqref{e:rLS}} $r_*(c_{1.1}) \lesssim \frac{ \log (d \log |G| ) }{c_{\mathrm{LS}}(G) \log |G| } \ll \rel(G_{\otimes d}) $. Finally, we have that $ \mix(G_{\otimes d})=\frac{\rel(G)}{2}d \log d (1 \pm o(1)) $ \cite[Theorem 20.7]{levin}. In particular, we have that $t_{\mathrm{sp}}^{G_{\otimes d}}(\sfrac{1}{2}) \lesssim \mix(G_{\otimes d}) $. As before, by Theorem \ref{thm:main1} in conjunction with Corollaries \ref{cor:1.9} and \ref{cor:1.11} we get that $\mixex \asymp d \log (dk)$, as claimed.}
\section{Proofs} \label{sec:proof}% In this appendix, we prove all theorems. \subsection{Proof of Theorem~\ref{thm:u-rewritable}} We prove the theorem by contradiction, namely, for any such $p(x,y)$ (with almost surely separable $\prp$ and $\prn$), for all $a,b$ and all $\theta$, we are able to find some $g$ for which \eqref{eq:u-rewritable} fails. Our argument goes from the special case of $\ell_{01}$ to the general case of $\ell$ satisfying \eqref{eq:cond-bnd-loss}. Firstly, let $g(x)=+\infty$ identically, so that $\ell(g(x))=0$ and $\ell(-g(x))=1$. Plugging them into \eqref{eq:risk} and \eqref{eq:u-rewritable}, we obtain that \begin{align*} b=1-\pip. \end{align*} Secondly, let $g(x)=-\infty$ identically; this time $\ell(g(x))=1$ and $\ell(-g(x))=0$, and we obtain that \begin{align*} a=\pip. \end{align*} Thirdly, let $g(x)=+\infty$ over $\prp$ and $g(x)=-\infty$ over $\prn$. To be precise, define \begin{align*} g(x)= \begin{cases} +\infty, & \prp(x)>0 \textrm{ and } \prn(x)=0,\\ -\infty, & \prp(x)=0 \textrm{ and } \prn(x)>0,\\ 0, & \prp(x)>0 \textrm{ and } \prn(x)>0. \end{cases} \end{align*} This is possible because $g$ is arbitrary. The last case $g(x)=0$ should have a zero probability, since $\prp$ and $\prn$ are almost surely separable. Hence, we have $\ell(g(x))=0$ and $\ell(-g(x))=1$ over $\prp$ and $\ell(g(x))=1$ and $\ell(-g(x))=0$ over $\prn$, resulting in \begin{align*} 0 &= \pip\Ep[\ell(g(X))]+(1-\pip)\En[\ell(-g(X))]\\ &= \theta\Ep[\barell(g(X))]+(1-\theta)\En[\barell(g(X))]\\ &= \theta b+(1-\theta)a. \end{align*} By solving this equation, we know that \begin{align} \label{eq:contradiction}% \theta = \frac{a}{a-b} = \frac{\pip}{2\pip-1}. \end{align} Nevertheless, $0\le\theta\le1$ whereas \begin{itemize} \item $\pip/(2\pip-1)<0$, if $0<\pip<1/2$; \item $\pip/(2\pip-1)>1$, if $1/2<\pip<1$; \item $\pip/(2\pip-1)$ is undefined, if $\pip=1/2$. \end{itemize} Therefore, \eqref{eq:contradiction} must be a contradiction, unless $\pip=0$ or $\pip=1$ which implies that there is just a single class and the problem under consideration is not binary classification. Finally, given any $\ell$ satisfying \eqref{eq:cond-bnd-loss}, it is not difficult to verify that the three $g$ above lead to the same contradiction with exactly the same $a$, $b$ and $\theta$ by solving a bit more complicated equations. \qed \subsection{Proof of Theorem~\ref{thm:uu-rewritable}} Let $J(g)$ be an alias of $R(g)$ in Definition~\ref{def:uu-rewritable} serving as the learning objective, i.e., \begin{align} \label{eq:uu-obj}% J(g) = \Etp[\barellpos(g(X))]+\Etn[\barellneg(-g(X))], \end{align} then \begin{align*} J(g) &= \Etp[a\ell(g(X))+b\ell(-g(X))] +\Etn[c\ell(-g(X))+d\ell(g(X))]\\ &= \theta\Ep[a\ell(g(X))+b\ell(-g(X))] +(1-\theta)\En[a\ell(g(X))+b\ell(-g(X))]\\ &\quad +\theta'\Ep[c\ell(-g(X))+d\ell(g(X))] +(1-\theta')\En[c\ell(-g(X))+d\ell(g(X))]\\ &= (a\theta+d\theta')\Ep[\ell(g(X))] +(b\theta+c\theta')\Ep[\ell(-g(X))]\\ &\quad +[a(1-\theta)+d(1-\theta')]\En[\ell(g(X))] +[b(1-\theta)+c(1-\theta')]\En[\ell(-g(X))]. \end{align*} On the other hand, \begin{align*} J(g) = \pip\Ep[\ell(g(X))]+(1-\pip)\En[\ell(-g(X))], \end{align*} since $J(g)$ is an alias of $R(g)$. As a result, in order to minimize $R(g)$ in \eqref{eq:risk}, it suffices to minimize $J(g)$ in \eqref{eq:uu-obj}, if we can make \begin{align*} a\theta+d\theta' &= \pip,\\ b\theta+c\theta' &= 0,\\ a(1-\theta)+d(1-\theta') &= 0,\\ b(1-\theta)+c(1-\theta') &= 1- \pip. \end{align*} Solving these equations gives us Eq.~\eqref{eq:uu-coef}, which concludes the proof. \qed \subsection{Proof of Theorem~\ref{thm:est-err}} First, we show the uniform deviation bound, which is useful to derive the estimation error bound. \begin{lemma} \label{thm:uni-dev}% For any $\delta>0$, let $C_\delta=\sqrt{(\ln2/\delta)/2}$, then we have with probability at least $1-\delta$, \begin{align} \label{eq:uni-dev-bound}% \sup\nolimits_{g\in\cG}|\hRuu(g)-R(g)| \le 2L_\ell\alpha\fR_n(\cG)+2L_\ell\alpha'\fR_{n'}'(\cG) +C_\ell C_\delta\chi_{n,n'}, \end{align} where the probability is over repeated sampling of data for evaluating $\hRuu(g)$. \end{lemma} \begin{proof} Consider the one-side uniform deviation $\sup\nolimits_{g\in\cG}\hRuu(g)-R(g)$. Since $0\le\ell(z)\le C_\ell$, the change of it will be no more than $C_\ell\alpha/n$ if some $x_i$ is replaced, or no more than $C_\ell\alpha'/n'$ if some $x'_j$ is replaced. Subsequently, \emph{McDiarmid's inequality} \citep{mcdiarmid89MBD} tells us that \begin{align*} \pr\{\sup\nolimits_{g\in\cG}\hRuu(g)-R(g)-\bE[\sup\nolimits_{g\in\cG}\hRuu(g)-R(g)]\ge\epsilon\} \le \exp\left(-\frac{2\epsilon^2}{C_\ell^2(\alpha^2/n+\alpha'^2/n')}\right), \end{align*} or equivalently, with probability at least $1-\delta/2$, \begin{align*} \sup\nolimits_{g\in\cG}\hRuu(g)-R(g) &\le \bE[\sup\nolimits_{g\in\cG}\hRuu(g)-R(g)] +C_\ell(\alpha/\sqrt{n}+\alpha'/\sqrt{n'})\sqrt{(\ln2/\delta)/2}\\ &= \bE[\sup\nolimits_{g\in\cG}\hRuu(g)-R(g)] +C_\ell C_\delta\chi_{n,n'}. \end{align*} By \emph{symmetrization} \citep{vapnik98SLT}, it is a routine work to show that \begin{align*} \bE[\sup\nolimits_{g\in\cG}\hRuu(g)-R(g)] \le 2\alpha\fR_n(\ell\circ\cG)+2\alpha'\fR_{n'}'(\ell\circ\cG), \end{align*} and according to \emph{Talagrand's contraction lemma} \citep{sshwartz14UML}, \begin{align*} \fR_n(\ell\circ\cG)\le L_\ell\fR_n(\cG),\quad \fR_{n'}'(\ell\circ\cG)\le L_\ell\fR_{n'}'(\cG). \end{align*} The one-side uniform deviation $\sup\nolimits_{g\in\cG}R(g)-\hRuu(g)$ can be bounded similarly. \end{proof} Based on Lemma~\ref{thm:uni-dev}, the estimation error bound \eqref{eq:est-err-bound} is proven through \begin{align*} R(\hguu)-R(g^*) &= \left(\hRuu(\hguu)-\hRuu(g^*)\right) +\left(R(\hguu)-\hRuu(\hguu)\right) +\left(\hRuu(g^*)-R(g^*)\right)\\ &\le 0 +2\sup\nolimits_{g\in\cG}|\hRuu(g)-R(g)|\\ &\le 4L_\ell\alpha\fR_n(\cG)+4L_\ell\alpha'\fR_{n'}'(\cG) +2C_\ell C_\delta\chi_{n,n'}, \end{align*} where $\hRuu(\hguu)\le\hRuu(g^*)$ by the definition of $\hguu$. \qed \section{Supplementary information on Figure~\ref{fig:illustration}} \label{sec:supp_figure1}% In the introduction, we illustrated the learning problem and the proposed method using a Gaussian mixture of two components. The details of this illustrative example are presented here. The P component $\prp(x)$ and N component $\prn(x)$ are both two-dimensional Gaussian distributions. Their means are \begin{align*} \boldsymbol{\mu}_{+} = [+1,+1]^\T,\quad \boldsymbol{\mu}_{-} = [-1,-1]^\T, \end{align*} and their covariance is the identity matrix. The two training distributions are created following \eqref{eq:train-density} with class priors $\theta=0.9$ and $\theta'=0.4$. Subsequently, the two sets of U training data were sampled from those distributions with sample sizes $n=2000$ and $n'=1000$. Moreover, $\prp(x)$ and $\prn(x)$ are combined to form the test distribution $p(x,y)$ with weights 0.3 and 0.7, so $\pip=0.3$. Note that $p(x)$ changes between training and test distributions (which can be seen from Figure~\ref{fig:illustration} by comparing (c) and (d) in the left panel and the right panel). This is the key difference between UU and CCN \citep{natarajan13nips}. For training, a linear (-in-input) model $g(x)=\boldsymbol{\omega}^\T x+b$ where $\boldsymbol{\omega}\in\bR^{2}$ and $b\in\bR$, and a sigmoid loss $\ellsig(z)=1/(1+\exp(z))$ were used. SGD was employed for optimization, where the learning rate was 0.01 and the batch size was 128. The model just has three parameters, so for the sake of a clear comparison of different risk estimators, we did not add any regularization. For every method, the model was trained 500 epochs. The final models are plotted in Figure~\ref{fig:illustration}. \section{Supplementary information on the experiments} \subsection{Setup} \label{subsec:setup}% \paragraph{MNIST} This is a grayscale image dataset of handwritten digits from 0 to 9 where the size of the images is 28*28. It contains 60,000 training images and 10,000 test images. Since it has 10 classes originally, we used the even digits as the P class and the odd digits as the N class, respectively. The model was FC with ReLU as the activation function: $d$-300-300-300-300-1. Batch normalization \citep{ioffe15icml} was applied before hidden layers. An $\ell_2$-regularization was added, where the regularization parameter was fixed to 1e-4. The model was trained by SGD with an initial learning rate 1e-3 and a batch size 128. In addition, the learning rate was decreased by \begin{align*} \frac{1}{1+\textrm{decay}\cdot\textrm{epoch}}, \end{align*} where decay was chosen from \{0, 1e-6, 1e-5, 5e-5, 1e-4, 5e-4\}. This is a learning rate schedule built in Keras. \paragraph{Fashion-MNIST} This is also a grayscale image dataset similarly to MNIST, but here each data is associated with a label from 10 fashion item classes. It was converted into a binary classification dataset as follows: \begin{itemize} \item the P class is formed by `T-shirt', `Pullover', `Coat', `Shirt', and `Bag'; \item the N class is formed by `Trouser', `Dress', `Sandal', `Sneaker', and `Ankle boot'. \end{itemize} The model and optimizer were same as MNIST, except that the initial learning rate was 1e-4. \paragraph{SVHN} This is a 32*32 color image dataset of street view house numbers from 0 to 9. It consists of 73,257 training data, 26,032 test data, and 531,131 extra training data. We sampled 100,000 data for training from the concatenation of training data and extra training data---the extra training data were used to ensure enough training data so as to perform class-prior changes. For SVHN dataset, `0', `6', `8', `9' made up the P class, and `1', `2', `3', `4', `5', `7' made up the N class. The model was AllConvNet \citep{springenberg15iclr} as follows. \begin{itemize}[leftmargin=10em] \item[0th (input) layer:] (32*32*3)- \item[1st to 3rd layers:] [C(3*3, 96)]*2-C(3*3, 96, 2)- \item[4th to 6th layers:] [C(3*3, 192)]*2-C(3*3, 192, 2)- \item[7th to 9th layers:] C(3*3, 192)-C(1*1, 192)-C(1*1, 10)- \item[10th to 12th layers:] 1000-1000-1 \end{itemize} where C(3*3, 96) means 96 channels of 3*3 convolutions followed by ReLU, [ $\cdot$ ]*2 means 2 such layers, C(3*3, 96, 2) means a similar layer but with stride 2, etc. Again, batch normalization and $\ell_2$-regularization with a regularization parameter 1e-5 were applied. The optimizer was Adam with the default momentum parameters ($\beta_1=0.9$ and $\beta_2=0.999$), an initial learning rate 1e-3, and a batch size 500. \paragraph{CIFAR-10} This dataset consists of 60,000 32*32 color images in 10 classes, and there are 5,000 training images and 1,000 test images per class. For CIFAR-10 dataset, \begin{itemize} \item the P class is composed of `bird', `cat', `deer', `dog', `frog' and `horse'; \item the N class is composed of `airplane', `automobile', `ship' and `truck'. \end{itemize} The model was ResNet-32 \citep{he16cvpr} as follows. \begin{itemize}[leftmargin=10em] \item[0th (input) layer:] (32*32*3)- \item[1st to 11th layers:] C(3*3, 16)-[C(3*3, 16), C(3*3, 16)]*5- \item[12th to 21st layers:] [C(3*3, 32), C(3*3, 32)]*5- \item[22nd to 31st layers:] [C(3*3, 64), C(3*3, 64)]*5- \item[32nd layer:] Global Average Pooling-1 \end{itemize} where [ $\cdot$, $\cdot$ ] means a building block \citep{he16cvpr}. The optimization setup was the same as for SVHN, except that the regularization parameter was set to be 5e-3 and the initial learning rate was set to be 1e-5. \begin{table}[t] \caption{Means (standard deviations) of the final classification errors in percentage corresponding to Figure~\ref{fig:performance}. Best and comparable methods (excluding PN oracle) based on the paired \textit{t}-test at the significance level 1\% are highlighted in boldface.} \label{tab:figure1} \vspace{-1ex}% \begin{center}\small \begin{tabular*}{0.9\textwidth}{l|r|rrr|r} \toprule Dataset & $\theta$, $\theta'$ & small PN & small PN prior-shift & UU & PN oracle \\ \midrule \multirow{2}*{MNIST} & 0.9, 0.1 & 3.56~(0.13) & 6.69 (0.23) & \bf2.37~(0.17) & \multirow{2}*{1.44~(0.08)} \\ & 0.8, 0.2 & 3.56~(0.13) & 4.56 (0.16) & \bf2.55~(0.11) & \\ \midrule \multirow{2}*{Fashion-MNIST} & 0.9, 0.1 & 4.76~(0.17) & 4.93 (0.16) & \bf2.94~(0.07) & \multirow{2}*{2.90~(0.10)} \\ & 0.8, 0.2 & 4.76~(0.17) & 4.86 (0.16) & \bf3.35~(0.13) & \\ \midrule \multirow{2}*{SVHN} & 0.9, 0.1 & 4.28~(1.07) & 9.26 (2.41) & \bf2.69~(0.20) & \multirow{2}*{2.08~(0.43)} \\ & 0.8, 0.2 & \bf4.28~(1.07) & 6.16 (0.66) & \bf3.99~(0.51) & \\ \midrule \multirow{2}*{CIFAR-10} & 0.9, 0.1 & 12.53~(0.69) & 18.58 (1.30) & \bf10.97~(0.91) & \multirow{2}*{9.26~(0.41)} \\ & 0.8, 0.2 & 12.53~(0.69) & 14.59 (1.05) & \bf11.64~(0.54) & \\ \bottomrule \end{tabular*} \end{center} \end{table} \paragraph{Remark} In the experiments on the closeness of $\theta$ and $\theta'$ and on the robustness against inaccurate training class priors, we sampled 40,000 training data from all the training data of MNIST in order to make it feasible to perform class-prior changes. \begin{figure}[t] \centering \begin{minipage}[c]{0.1\textwidth}~\end{minipage}\hspace{1em}% \begin{minipage}[c]{0.4\textwidth}\centering\small $\ellsig$ \end{minipage}% \begin{minipage}[c]{0.4\textwidth}\centering\small $\elllog$ \end{minipage}\\ \begin{minipage}[c]{0.1\textwidth}\flushright\small $\theta=0.9$\\$\theta'=0.1$ \end{minipage}\hspace{1em}% \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{mnist_sig91}% \includegraphics[width=0.5\textwidth]{mnist_log91} \end{minipage}\\ \begin{minipage}[c]{0.1\textwidth}\flushright\small $\theta=0.8$\\$\theta'=0.2$ \end{minipage}\hspace{1em}% \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{mnist_sig82}% \includegraphics[width=0.5\textwidth]{mnist_log82} \end{minipage} \vspace{-1ex}% \caption{Experimental results of comparing $\ellsig$ and $\elllog$.} \label{fig:comp-losses} \vspace{1ex}% \end{figure} \begin{figure}[t] \centering \begin{minipage}[c]{.05\textwidth}~\end{minipage}\hspace{1em}% \begin{minipage}[c]{0.4\textwidth}\centering\small $\theta=0.9$ \end{minipage}% \begin{minipage}[c]{0.4\textwidth}\centering\small $\theta=0.8$ \end{minipage}\\ \begin{minipage}[c]{.05\textwidth}\flushright\small UU \end{minipage}\hspace{1em}% \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{mnist_UU9_nb}% \includegraphics[width=0.5\textwidth]{mnist_UU8_nb} \end{minipage}\\ \begin{minipage}[c]{.05\textwidth}\flushright\small CCN \end{minipage}\hspace{1em}% \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{mnist_CCN9_nb}% \includegraphics[width=0.5\textwidth]{mnist_CCN8_nb} \end{minipage} \vspace{-1ex}% \caption{Experimental results of moving $n$ farther from $n'$ (black dashed lines are PN oracle).} \label{fig:diff-nb} \end{figure} \subsection{Results} \label{subsec:expresults}% \paragraph{Final classification errors} Please find in Table~\ref{tab:figure1}. \paragraph{Comparison of different losses} We have compared the sigmoid loss $\ellsig(z)$ and the logistic loss $\elllog(z)$ on MNIST. The experimental results are reported in Figure~\ref{fig:comp-losses}. We can see that the resulted classification errors are similar---in fact, $\ellsig(z)$ is a little better. \paragraph{On the variation of $n$ and $n'$} We have further investigated the issue of covariate shift by varying $n$ and $n'$. Likewise, we test UU and CCN on MNIST by fixing $n'$ to 20,000 and gradually moving $n$ from 20,000 to 4,000, where $\theta'$ is fixed to 0.4 and $\theta$ is chosen from 0.9 or 0.8. The experimental results in Figure~\ref{fig:diff-nb} indicate that when $n$ moves farther from $n'$, UU and CCN become worse, while UU is affected slightly and CCN is affected severely. Figure~\ref{fig:diff-nb} is consistent with Figure~\ref{fig:near-priors}, showing that CCN methods do not fit our problem setting. \section{Introduction} With some properly chosen loss function \citep[e.g.,][]{bartlett06jasa,tewari07jmlr,reid10jmlr} and regularization \citep[e.g.,][]{tikhonov43dansssr,srivastava14jmlr}, \emph{empirical risk minimization}~(ERM) is the common practice of supervised classification \citep{vapnik98SLT}. Actually, ERM is used in not only supervised learning but also \emph{weakly-supervised learning}. For example, in \emph{semi-supervised learning} \citep{chapelle06SSL}, we have very limited labeled~(L) data and a lot of unlabeled~(U) data, where L data share the same form with supervised learning. Thus, it is easy to estimate the risk from only L data in order to carry out ERM, and U data are needed exclusively in regularization \citep[including but not limited to][]{grandvalet04nips,belkin06jmlr,mann07icml,niu13icml,miyato16iclr,laine17iclr,tarvainen17nips,luoi18cvpr,kamnitsas18icml}. Nevertheless, L data may differ from supervised learning in not only the amount but also the form. For instance, in \emph{positive-unlabeled learning} \citep{elkan08kdd,ward09biometrics}, all L data are from the positive class, and due to the lack of L data from the negative class it becomes impossible to estimate the risk from only L data. To this end, a two-step approach to ERM has been considered \citep{christo14nips,christo15icml,niu16nips,kiryo17nips}. Firstly, the risk is rewritten into an equivalent expression, such that it just involves the same distributions from which L and U data are sampled---this step leads to certain risk estimators. Secondly, the risk is estimated from both L and U data, and the resulted empirical training risk is minimized \citep[e.g.\ by][]{robbins51ams,kingma15iclr}. In this two-step approach, U data are needed absolutely in ERM itself. This indicates that \emph{risk rewrite} (i.e., the technique of making the risk estimable from observable data via an equivalent expression) enables ERM in positive-unlabeled learning and is the key of success. One step further from positive-unlabeled learning is \emph{learning from only U data} without any L data. This is significantly harder than previous learning problems (cf.~Figure~\ref{fig:illustration}). However, we would still like to train \emph{arbitrary binary classifier}, in particular, deep networks \citep{goodfellow16DL}. Note that for this purpose clustering is suboptimal for two major reasons. First, successful translation of clusters into meaningful classes completely relies on the critical assumption that \emph{one cluster exactly corresponds to one class}, and hence even perfect clustering might still result in poor classification. Second, clustering must introduce additional geometric or information-theoretic assumptions upon which the learning objectives of clustering are built \citep[e.g.,][]{xu04nips,gomes10nips}. As a consequence, we prefer ERM to clustering and then no more assumption is required. The difficulty is how to estimate the risk from only U data, and our solution is again ERM-enabling risk rewrite in the aforementioned two-step approach. The first step should lead to an \emph{unbiased risk estimator} that will be used in the second step. Subsequently, we can evaluate the empirical training and/or validation risk by plugging only U training/validation data into the risk estimator. Thus, this two-step ERM needs \emph{no L validation data for hyperparameter tuning}, which is a huge advantage in training deep models nowadays. Note that given only U data, by no means could we learn the class priors \citep{menon15icml}, so that we assume \emph{all necessary class priors are also given}. This is the unique type of supervision we will leverage throughout this paper, and hence this learning problem still belongs to weakly-supervised learning rather than unsupervised learning. \begin{figure}[t] {\centering \hfill{\includegraphics[width=0.48\textwidth]{UU_1} \hfill{\includegraphics[width=0.48\textwidth]{UU_2}} \hfill}\\ {\footnotesiz In the left panel, (a) and (b) show positive~(P) and negative~(N) components of the Gaussian mixture; (c) and (d) show two distributions (with class priors 0.9 and 0.4) where U training data are drawn (marked as black points). The right panel shows the test distribution (with class prior 0.3) and data (marked as blue for P and red for N), as well as four learned classifiers. In the legend, ``CCN'' refers to \cite{natarajan13nips}, ``UU-biased'' means supervised learning taking larger-/smaller-class-prior U data as P/N data, ``UU'' is the proposed method, and ``Oracle'' means supervised learning from the same amount of L data. See Appendix~\ref{sec:supp_figure1} for more information. We can see that UU is almost identical to Oracle and much better than the other two methods. } \vspace{1ex \caption{Illustrative example of classification from a Gaussian mixture dataset.} \label{fig:illustration} \vspace{-1ex \end{figure} In this paper, we raise a fundamental question in weakly-supervised learning---how many sets of U data with \emph{different class priors} are necessary for rewriting the risk? Our answer has two aspects: \begin{itemize} \item Risk rewrite is impossible given a single set of U data (see Theorem~\ref{thm:u-rewritable} in Sec.~\ref{sec:u-erm}); \item Risk rewrite becomes possible given two sets of U data (see Theorem~\ref{thm:uu-rewritable} in Sec.~\ref{sec:uu-erm}). \end{itemize} This suggests that \emph{three class prior \footnote{Two class-prior probabilities are of the training distributions and one is of the test distribution. are all you need} to train deep models from only U data, while any tw \footnote{One of the training distribution and one of the test distribution, or two of the training distributions.}\ should not be enough. The impossibility is a proof by contradiction, and the possibility is a proof by construction, following which we explicitly design an unbiased risk estimator. Therefore, with the help of this risk estimator, we propose an ERM-based learning method from two sets of U data. Thanks to the unbiasedness of our risk estimator, we derive an \emph{estimation error bound} which certainly guarantees the \emph{consistency of learning} \citep{mohri12FML,sshwartz14UML} \footnote{Learning is consistent (more specifically the learned classifier is asymptotically consistent), if and only if as the amount of training data approaches infinity, the risk of the learned classifier converges to the risk of the optimal classifier, where the optimality is defined over a given hypothesis class.} Experiments demonstrate that the proposed method could train multilayer perceptron, AllConvNet \citep{springenberg15iclr} and ResNet \citep{he16cvpr} from two sets of U data; it could outperform state-of-the-art methods for learning from two sets of U data. See Figure~\ref{fig:illustration} for how the proposed method works on a Gaussian mixture of two components. \section{Problem setting and related work} Consider the binary classification problem. Let $X$ and $Y$ be the input and output random variables such that \begin{itemize} \item $p(x,y)$ is the \emph{underlying joint density}, \item $\prp(x)=p(x\mid Y=+1)$ and $\prn(x)=p(x\mid Y=-1)$ are the \emph{class-conditional densities}, \item $p(x)$ is the \emph{marginal density}, and \item $\pip=p(Y=+1)$ is the \emph{class-prior probability}. \end{itemize} \paragraph{Data generation process} Let $\theta$ and $\theta'$ be two valid class priors such that $\theta\neq\theta'$ (here it does not matter if either $\theta$ or $\theta'$ equals $\pip$ or neither of them equals $\pip$), and let \begin{align} \label{eq:train-density \ptr(x)=\theta\prp(x)+(1-\theta)\prn(x),\quad \ptr'(x)=\theta'\prp(x)+(1-\theta')\prn(x) \end{align} be the marginal densities from which U training data are drawn. Eq.~\eqref{eq:train-density} implies there are $\ptr(x,y)$ and $\ptr'(x,y)$, whose class-conditional densities are same and equal to those of $p(x,y)$, and whose class priors are different, i.e., \begin{align*} \ptr(x\mid y)=\ptr'(x\mid y)=p(x\mid y),\quad \ptr(Y=+1)=\theta\neq\theta'=\ptr'(Y=+1). \end{align*} If we could sample L data from $\ptr(x,y)$ or $\ptr'(x,y)$, it would reduce to supervised learning under \emph{class-prior change} \citep{sugi09DSML}. Nonetheless, the problem of interest belongs to weakly-supervised learning---U training (and validation) data are supposed to be drawn according to \eqref{eq:train-density}. More specifically, we have \begin{align} \label{eq:train-data \Xtr=\{x_1,\ldots,x_n\}\sim\ptr(x),\quad \Xtr'=\{x'_1,\ldots,x'_{n'}\}\sim\ptr'(x), \end{align} where $n$ and $n'$ are two natural numbers as the sample sizes of $\Xtr$ and $\Xtr'$. This is exactly same as \cite{christo13taai} and \cite{menon15icml} with some different names. In \cite{menon15icml}, $\theta$ and $\theta'$ are called \emph{corruption parameters}, and if we assume $\theta>\theta'$, $\ptr(x)$ is called the \emph{corrupted P density} and $\ptr'(x)$ is called the \emph{corrupted N density}. Despite the same data generation process in \eqref{eq:train-data}, a vital difference between the problem settings is performance measures to be optimized. \paragraph{Performance measures} Let $g:\bR^d\to\bR$ be an arbitrary \emph{decision function}, i.e., $g$ may literally be any binary classifier. Let $\ell:\bR\to\bR$ be the \emph{loss function}, such that the value $\ell(z)$ means the loss by predicting $g(x)$ when the ground truth is $y$ where $z=yg(x)$ is the \emph{margin}. The \emph{risk} of $g$ is \begin{align} \label{eq:risk R(g) = \bE_{(X,Y)\sim p(x,y)}[\ell(Yg(X))] = \pip\Ep[\ell(g(X))]+(1-\pip)\En[\ell(-g(X))], \end{align} where $\Ep[\cdot]$ means $\bE_{X\sim\prp}[\cdot]$ and $\En[\cdot]$ means $\bE_{X\sim\prn}[\cdot]$ respectively. If $\ell$ is the \emph{zero-one loss} that is defined by $\ell_{01}(z)=(1-\sign(z))/2$, the risk is also known as the \emph{classification error} and it is the standard performance measure in classification. A balanced version of Eq.~\eqref{eq:risk} is \begin{align} \label{eq:bal-risk B(g) = \frac{1}{2}\Ep[\ell(g(X))]+\frac{1}{2}\En[\ell(-g(X))], \end{align} and if $\ell$ is $\ell_{01}$, \eqref{eq:bal-risk} is named the \emph{balanced error} \citep{brodersen10icpr}. The vital difference is that \eqref{eq:risk} is chosen in the current paper whereas \eqref{eq:bal-risk} is chosen in \cite{christo13taai} and \cite{menon15icml} as the performance measure to be optimized. We argue that \eqref{eq:risk} is more natural as the performance measure for binary classification than \eqref{eq:bal-risk}. By the phrase ``binary classification'', we mean $\pip$ is neither very large nor very small. Otherwise, due to extreme values of $\pip$ (i.e., either $\pip\approx0$ or $\pip\approx1$), the problem under consideration should be retrieval or detection rather than binary classification. Hence, it may be misleading to optimize \eqref{eq:bal-risk}, unless $\pip\approx\frac{1}{2}$ which implies that Eqs.~\eqref{eq:risk} and \eqref{eq:bal-risk} are essentially equivalent. \paragraph{Related work} Learning from only U data is previously regarded as \emph{discriminative clustering} \citep{xu04nips,valizadegan06nips,li09aistats,gomes10nips,sugiyama14neco,hu17icml}. Their goals are to maximize the margin or the mutual information between $X$ and $Y$. Recall that clustering is suboptimal, since it requires the \emph{cluster assumption} \citep{chapelle02nips} and it is rarely satisfied in practice that one cluster exactly corresponds to one class. As mentioned earlier, learning from two sets of U data is already studied in \cite{christo13taai} and \cite{menon15icml}. Both of them adopt \eqref{eq:bal-risk} as the performance measure. In the former paper, $g$ is learned by estimating $\sign(\ptr(x)-\ptr'(x))$. In the latter paper, $g$ is learned by taking noisy L data from $\ptr(x)$ and $\ptr'(x)$ as clean L data from $\prp(x)$ and $\prn(x)$, and then its threshold is moved to the correct value by post-processing. In summary, instead of ERM, they evidence the possibility of \emph{empirical balanced risk minimization}, and no impossibility is proven. Our findings are compatible with \emph{learning from label proportions} \citep{quadrianto09jmlr,yu13icml}. \cite{quadrianto09jmlr} proves that the minimal number of U sets is equal to the number of classes. However, their finding only holds for the linear model, the logistic loss, and their proposed method based on mean operators. On the other hand, \cite{yu13icml} is not ERM-based; it is based on discriminative clustering together with expectation regularization \citep{mann07icml}. At first glance, our data generation process, using the names from \cite{menon15icml}, looks quite similar to \emph{class-conditional noise}~\citep[CCN,][]{angluin88mlj} in \emph{learning with noisy labels} \citep[cf.][]{natarajan13nips} \footnote{There are quite few instance-dependent noise models \citep{menon16arxiv,cheng17arxiv}, and others explore instance-independent noise models \citep{natarajan13nips,sukhbaatar15iclr,menon15icml,liu16tpami,goldberger17iclr,patrini17cvpr,han18nips-masking} or assume no noise model at all \citep{reed15iclr,jiang18icml,ren18icml,han18nips-coteaching}.} In fact, \cite{menon15icml} makes use of \emph{mutually contaminated distributions}~\citep[MCD,][]{scott13colt} that is more general than CCN. Denote by $\tilde{y}$ and $\tilde{p}(\cdot)$ the corrupted label and distributions. Then, CCN and MCD are defined by \begin{align*} \begin{pmatrix} \tilde{p}(\tilde{Y}=+1\mid x)\\ \tilde{p}(\tilde{Y}=-1\mid x) \end{pmatrix} = T_{\textrm{CCN}} \begin{pmatrix} p(Y=+1\mid x)\\ p(Y=-1\mid x) \end{pmatrix} \quad\textrm{and}\quad \begin{pmatrix} \tilde{p}(x\mid\tilde{Y}=+1)\\ \tilde{p}(x\mid\tilde{Y}=-1) \end{pmatrix} = T_{\textrm{MCD}} \begin{pmatrix} \prp(x)\\ \prn(x) \end{pmatrix}, \end{align*} where both of $T_{\textrm{CCN}}$ and $T_{\textrm{MCD}}$ are 2-by-2 matrices but $T_{\textrm{CCN}}$ is column normalized and $T_{\textrm{MCD}}$ is row normalized. It has been proven in \cite{menon15icml} that CCN is a strict special case of MCD. To be clear, $\tilde{p}(\tilde{y})$ is fixed in CCN once $\tilde{p}(\tilde{y}\mid x)$ is specified while $\tilde{p}(\tilde{y})$ is free in MCD after $\tilde{p}(x\mid\tilde{y})$ is specified. Furthermore, $\tilde{p}(x)=p(x)$ in CCN but $\tilde{p}(x)\neq p(x)$ in MCD. Due to this \emph{covariate shift}, CCN methods do not fit MCD problem setting, though MCD methods fit CCN problem setting. To the best of our knowledge, the proposed method is the first MCD method based on ERM. \section{Learning from one set of U data} \label{sec:u-erm From now on, we prove that knowing $\pip$ and $\theta$ is insufficient for rewriting $R(g)$. \subsection{A brief review of ERM} \label{sec:erm-rev To begin with, we review ERM \citep{vapnik98SLT} by imaging that we are given $\Xp=\{x_1,\ldots,x_n\}\sim\prp(x)$ and $\Xn=\{x'_1,\ldots,x'_{n'}\}\sim\prn(x)$. Then, we would go through the following procedure: \begin{enumerate} \item Choose a \emph{surrogate loss} $\ell(z)$, so that $R(g)$ in Eq.~\eqref{eq:risk} is defined. \item Choose a model $\cG$, so that $\min_{g\in\cG}R(g)$ is achievable by ERM. \item Approximate $R(g)$ by \begin{align} \label{eq:risk-pn-hat \hRpn(g) = \frac{\pip}{n}\sum\nolimits_{i=1}^n\ell(g(x_i))+\frac{1-\pip}{n'}\sum\nolimits_{j=1}^{n'}\ell(-g(x'_j)). \end{align} \item Minimize $\hRpn(g)$, with appropriate regularization, by favorite optimization algorithm. \end{enumerate} Here, $\ell$ should be \emph{classification-calibrated} \citep{bartlett06jasa} \footnote{$\ell$ is classification-calibrated if and only if there is a convex, invertible, and nondecreasing transformation $\psi_\ell$ with $\psi_\ell(0)=0$, such that $\psi_\ell(R(g;\ell_{01})-\inf\nolimits_gR(g;\ell_{01})) \le R(g;\ell)-\inf\nolimits_gR(g;\ell)$. If $\ell$ is a convex loss, it is classification-calibrated if and only if it is differentiable at the origin and $\ell'(0)<0$.} in order to guarantee that $R(g;\ell)$ and $R(g;\ell_{01})$ have the same minimizer over all measurable functions. This minimizer is the \emph{Bayes optimal classifier} and denoted by $g^{**}=\argmin_g R(g)$. The Bayes optimal risk $R(g^{**})$ is usually unachievable by ERM as $n,n'\to\infty$. That is why by choosing a model $\cG$, $g^*=\argmin_{g\in\cG}R(g)$ became the target (i.e., $\hgpn=\argmin_{g\in\cG}\hRpn(g)$ will converge to $g^*$ as $n,n'\to\infty$). In statistical learning, the \emph{approximation error} is $R(g^*)-R(g^{**})$, and the \emph{estimation error} is $R(\hgpn)-R(g^*)$. Learning is consistent if and only if the estimation error converges to zero as $n,n'\to\infty$. \subsection{Impossibility of risk rewrite} Recall that $R(g)$ is approximated by \eqref{eq:risk-pn-hat} given $\Xp$ and $\Xn$, which does not work given $\Xtr$ and $\Xtr'$. We might rewrite $R(g)$ so that it could be approximated given $\Xtr$ and/or $\Xtr'$. This is known as the \emph{backward correction} in learning with noisy/corrupted labels (\citealp{patrini17cvpr}; see also \citealp{natarajan13nips,vanrooyen18jmlr}). \begin{definition} \label{def:u-rewritable We say that $R(g)$ in \eqref{eq:risk} is rewritable given $\ptr$, if and only if\ \footnote{This is because the backward correction in \eqref{eq:u-rewritable}, if exists, would be unique.} there exist constants $a$ and $b$, such that for any $g$ it holds that \begin{align} \label{eq:u-rewritable R(g) = \Etp[\barell(g(X))], \end{align} where $\Etp[\cdot]$ means $\bE_{X\sim\ptr}[\cdot]$ and $\barell(z)=a\ell(z)+b\ell(-z)$ is the corrected loss function. \end{definition} In Eq.~\eqref{eq:u-rewritable}, the expectation is with respect to $\ptr$ and $\theta$ is a free variable in it. The impossibility will be stronger, if $\theta$ is unspecified and allowed to be adjusted according to $\pip$. \begin{theorem} \label{thm:u-rewritable Let $\ell$ be $\ell_{01}$, or any bounded surrogate loss satisfying that \begin{align} \label{eq:cond-bnd-loss 0\le\ell(+\infty)=\lim\nolimits_{z\to+\infty}\ell(z) <\lim\nolimits_{z\to-\infty}\ell(z)=\ell(-\infty)<+\infty. \end{align} Assume $\prp$ and $\prn$ are almost surely separable. Then, $R(g)$ is not rewritable though $\theta$ is free \footnote{Please find in Appendix~\ref{sec:proof} the proofs of theorems.} \end{theorem} This theorem shows that under the separability assumption of $\prp$ and $\prn$, $R(g)$ is not rewritable. As a consequence, we lack a learning objective, that is, the empirical training risk. It is even worse---we cannot access the empirical validation risk of $g$ after it is trained by other learning methods such as discriminative clustering. In particular, $\ell_{01}$ satisfies \eqref{eq:cond-bnd-loss}, which implies that the common practice of hyperparameter tuning is disabled by Theorem~\ref{thm:u-rewritable}, since U validation data are also drawn from $\ptr$. \section{Learning from two sets of U data} \label{sec:uu-erm From now on, we prove that knowing $\pip$, $\theta$ and $\theta'$ is sufficient for rewriting $R(g)$. \subsection{Possibility of risk rewrite, and unbiased risk estimators} We have proven that $R(g)$ is not rewritable given $\ptr$, and \cite{quadrianto09jmlr} has proven that $R(g)$ can be estimated from $\Xtr$ and $\Xtr'$, where $g$ is a linear model and $\ell$ is the logistic loss. These facts motivate us to investigate the possibility of rewriting $R(g)$, where $g$ and $\ell$ are both arbitrary \footnote{The technique that underlies Theorem~\ref{thm:uu-rewritable} is totally different from \cite{quadrianto09jmlr}. We shall obtain \eqref{eq:uu-coef} by solving a linear system resulted from Definition~\ref{def:uu-rewritable}. As previously mentioned, \cite{quadrianto09jmlr} is based on mean operators, and it cannot be further generalized to handle nonlinear $g$ or arbitrary $\ell$.} \begin{definition} \label{def:uu-rewritable We say that $R(g)$ is rewritable given $\ptr$ and $\ptr'$, if and only if\ \footnote{This is similar because the backward correction in \eqref{eq:uu-rewritable}, if exists, would be unique.} there exist constants $a$, $b$, $c$ and $d$, such that for any $g$ it holds that \begin{align} \label{eq:uu-rewritable R(g) = \Etp[\barellpos(g(X))] +\Etn[\barellneg(-g(X))], \end{align} where $\barellpos(z)=a\ell(z)+b\ell(-z)$ and $\barellneg(z)=c\ell(z)+d\ell(-z)$ are the corrected loss functions. \end{definition} In Eq.~\eqref{eq:uu-rewritable}, the expectations are with respect to $\ptr$ and $\ptr'$ that are regarded as the corrupted $\prp$ and $\prn$. There are two free variables $\theta$ and $\theta'$ in $\ptr$ and $\ptr'$. The possibility will be stronger, if $\theta$ and $\theta'$ are already specified and disallowed to be adjusted according to $\pip$. \begin{theorem} \label{thm:uu-rewritable Fix $\theta$ and $\theta'$. Assume $\theta>\theta'$; otherwise, swap $\ptr$ and $\ptr'$ to make sure $\theta>\theta'$. Then, $R(g)$ is rewritable, by letting \begin{align} \label{eq:uu-coef a=\frac{(1-\theta')\pip}{\theta-\theta'},\quad b=-\frac{\theta'(1-\pip)}{\theta-\theta'},\quad c=\frac{\theta(1-\pip)}{\theta-\theta'},\quad d=-\frac{(1-\theta)\pip}{\theta-\theta'}. \end{align} \end{theorem} Theorem~\eqref{thm:uu-rewritable} immediately leads to an unbiased risk estimator, namely, \begin{align} \label{eq:risk-uu-hat \begin{split} \hRuu(g) &= \frac{1}{n}\sum\nolimits_{i=1}^n\left(\frac{(1-\theta')\pip}{\theta-\theta'}\ell(g(x_i)) -\frac{\theta'(1-\pip)}{\theta-\theta'}\ell(-g(x_i))\right)\\ &\quad +\frac{1}{n'}\sum\nolimits_{j=1}^{n'}\left(-\frac{(1-\theta)\pip}{\theta-\theta'}\ell(g(x'_j)) +\frac{\theta(1-\pip)}{\theta-\theta'}\ell(-g(x'_j))\right). \end{split} \end{align} Eq.~\eqref{eq:risk-uu-hat} is useful for both training (by plugging U training data into it) and hyperparameter tuning (by plugging U validation data into it). We hereafter refer to the process of obtaining the empirical risk minimizer of \eqref{eq:risk-uu-hat}, i.e., $\hguu=\argmin_{g\in\cG}\hRuu(g)$, as \emph{unlabeled-unlabeled}~(UU) \emph{learning}. The proposed UU learning is by nature ERM-based, and consequently $\hguu$ can be obtained by powerful \emph{stochastic optimization} algorithms \citep[e.g.,][]{duchi11jmlr,kingma15iclr}. \paragraph{Simplification} Note that \eqref{eq:risk-uu-hat} may require some efforts to implement. Fortunately, it can be simplified by employing $\ell$ that satisfies a \emph{symmetric condition}: \begin{align} \label{eq:cond-sym-loss \ell(z)+\ell(-z)=1. \end{align} Eq.~\eqref{eq:cond-sym-loss} covers $\ell_{01}$, a ramp loss $\ell_\mathrm{ramp}(z)=\max\{0,\min\{1,(1-z)/2\}\}$ in \cite{christo14nips} and a sigmoid loss $\ellsig(z)=1/(1+\exp(z))$ in \cite{kiryo17nips}. With the help of \eqref{eq:cond-sym-loss}, \eqref{eq:risk-uu-hat} can be simplified as \begin{align} \label{eq:risk-uu-hat-sym \hRuus(g) = \frac{1}{n}\sum\nolimits_{i=1}^n\alpha\ell(g(x_i)) +\frac{1}{n'}\sum\nolimits_{j=1}^{n'}\alpha'\ell(-g(x'_j)) -\frac{\theta'(1-\pip)+(1-\theta)\pip}{\theta-\theta'}, \end{align} where $\alpha=(\theta'+\pip-2\theta'\pip)/(\theta-\theta')$ and $\alpha'=(\theta+\pip-2\theta\pip)/(\theta-\theta')$. Similarly, \eqref{eq:risk-uu-hat-sym} is an unbiased risk estimator, and it is easy to implement with existing codes of cost-sensitive learning. \paragraph{Special cases} Consider some special cases of \eqref{eq:risk-uu-hat} by specifying $\theta$ and $\theta'$. It is obvious that \eqref{eq:risk-uu-hat} reduces to \eqref{eq:risk-pn-hat} for supervised learning, if $\theta=1$ and $\theta'=0$. Next, \eqref{eq:risk-uu-hat} reduces to \begin{align*} \hRpu(g) = \frac{1}{n}\sum\nolimits_{i=1}^n\pip\ell(g(x_i)) -\frac{1}{n}\sum\nolimits_{i=1}^n\pip\ell(-g(x_i)) +\frac{1}{n'}\sum\nolimits_{j=1}^{n'}\ell(-g(x'_j)), \end{align*} if $\theta=1$ and $\theta'=\pip$, and we recover the unbiased risk estimator in positive-unlabeled learning \citep{christo15icml,kiryo17nips}. Additionally, \eqref{eq:risk-uu-hat} reduces to a fairly complicated unbiased risk estimator in similar-unlabeled learning \citep{bao18icml}, if $\theta=\pip,\theta'=\pip^2/(2\pip^2-2\pip+1)$ or vice versa. Therefore, UU learning is a very general framework in weakly-supervised learning. \subsection{Consistency and convergence rate} The consistency of UU learning is guaranteed due to the unbiasedness of \eqref{eq:risk-uu-hat}. In what follows, we analyze the estimation error $R(\hguu)-R(g^*)$ (see Sec.~\ref{sec:erm-rev} for the definition). To this end, assume there are $C_g>0$ and $C_\ell>0$ such that $\sup_{g\in\cG}\|g\|_\infty\le C_g$ and $\sup_{|z|\le C_g}\ell(z)\le C_\ell$, and assume $\ell(z)$ is Lipschitz continuous for all $|z|\le C_g$ with a Lipschitz constant $L_\ell$. Let $\fR_n(\cG)$ and $\fR_{n'}'(\cG)$ be the \emph{Rademacher complexity} of $\cG$ over $\ptr(x)$ and $\ptr'(x)$ \citep{mohri12FML,sshwartz14UML}. For convenience, denote by $\chi_{n,n'}=\alpha/\sqrt{n}+\alpha'/\sqrt{n'}$. \begin{theorem} \label{thm:est-err For any $\delta>0$, let $C_\delta=\sqrt{(\ln2/\delta)/2}$, then we have with probability at least $1-\delta$, \begin{align} \label{eq:est-err-bound R(\hguu)-R(g^*) \le 4L_\ell\alpha\fR_n(\cG)+4L_\ell\alpha'\fR_{n'}'(\cG) +2C_\ell C_\delta\chi_{n,n'}, \end{align} where the probability is over repeated sampling of $\Xtr$ and $\Xtr'$ for training $\hguu$. \end{theorem} Theorem~\ref{thm:est-err} ensures that UU learning is consistent (and so are all the special cases): as $n,n'\to\infty$, $R(\hguu)\to R(g^*)$, since $\fR_n(\cG),\fR_{n'}'(\cG)\to0$ for all parametric models with a bounded norm such as deep networks trained with weight decay. Moreover, $R(\hguu)\to R(g^*)$ in $\cO_p(\chi_{n,n'})$, where $\cO_p$ denotes the order in probability, for all linear-in-parameter models with a bounded norm, including non-parametric kernel models in \emph{reproducing kernel Hilbert spaces} \citep{scholkopf01LK}. \section{Experiments} \label{sec:experiment In this section, we experimentally analyze the proposed method in training deep networks and subsequently experimentally compare it with state-of-the-art methods for learning from two sets of U data. The implementation in our experiments is based on Keras (see \url{https://keras.io}); it is available at \url{https://github.com/lunanbit/UUlearning}. \begin{table}[b] \caption{Specification of benchmark datasets, models, and optimization algorithms.} \label{tab:dataset} \vspace{-1ex \begin{center}\small \begin{tabular*}{0.93\textwidth}{l|rrrr|l|l} \toprule Dataset & \# Train & \# Test & \# Feature & $\pip$ & Model $g(x;\theta)$ & Optimizer \\ \midrule MNIST & 60,000 & 10,000 & 784 & 0.49 & FC with ReLU (depth 5) & SGD \\ Fashion-MNIST & 60,000 & 10,000 & 784 & 0.50 & FC with ReLU (depth 5) & SGD \\ SVHN & 100,000 & 26,032 & 3,072 & 0.27 & AllConvNet (depth 12) & Adam \\ CIFAR-10 & 50,000 & 10,000 & 3,072 & 0.60 & ResNet (depth 32) & Adam \\ \bottomrule \end{tabular*} \vskip1e \begin{minipage}{0.92\textwidth}\footnotesiz See \url{http://yann.lecun.com/exdb/mnist/} for MNIST \citep{lecun98mnist}, \url{https://github.com/zalandoresearch/fashion-mnist} for Fashion-MNIST \citep{xiao17arxiv}, \url{http://ufldl.stanford.edu/housenumbers/} for SVHN \citep{yuval11svhn}, as well as \url{https://www.cs.toronto.edu/~kriz/cifar.html} for CIFAR-10 \citep{krizhevsky09cifar}. \end{minipage} \end{center} \end{table} \begin{figure}[t] \centering \begin{minipage}[c]{0.1\textwidth}~\end{minipage}\hspace{1em \begin{minipage}[c]{0.4\textwidth}\centering\small $\theta=0.9,\theta'=0.1$ \end{minipage \begin{minipage}[c]{0.4\textwidth}\centering\small $\theta=0.8,\theta'=0.2$ \end{minipage}\\ \begin{minipage}[c]{0.1\textwidth}\flushright\small MNIST \end{minipage}\hspace{1em \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{mnist_UU91 \includegraphics[width=0.5\textwidth]{mnist_UU82} \end{minipage}\\ \begin{minipage}[c]{0.1\textwidth}\flushright\small Fashion-MNIST \end{minipage}\hspace{1em \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{fashion_UU91 \includegraphics[width=0.5\textwidth]{fashion_UU82} \end{minipage}\\ \begin{minipage}[c]{0.1\textwidth}\flushright\small SVHN \end{minipage}\hspace{1em \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{svhn_UU91 \includegraphics[width=0.5\textwidth]{svhn_UU82} \end{minipage}\\ \begin{minipage}[c]{0.1\textwidth}\flushright\small CIFAR-10 \end{minipage}\hspace{1em \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{cifar10_UU91 \includegraphics[width=0.5\textwidth]{cifar10_UU82} \end{minipage} \vspace{-1ex \caption{Experimental results of training deep neural networks.} \label{fig:performance} \vspace{-1em \end{figure} \subsection{Training deep neural networks on benchmarks} \label{sec:benchmark In order to analyze the proposed method, we compare it with three supervised baseline methods: \begin{itemize} \item \emph{small PN} means supervised learning from 10\% L data; \item \emph{PN oracle} means supervised learning from 100\% L data; \item \emph{small PN prior-shift} means supervised learning from 10\% L data under class-prior change. \end{itemize} Notice that the first two baselines have L data identically distributed as the test data, which is very advantageous and thus the experiments in this subsection are merely for a proof of concept. Table~\ref{tab:dataset} summarizes the benchmarks. They are converted into binary classification datasets; please see Appendix~\ref{subsec:setup} for details. $\Xtr$ and $\Xtr'$ of the same sample size are drawn according to Eq.~\eqref{eq:train-density}, where $\theta$ and $\theta'$ are chosen as 0.9, 0.1 or 0.8, 0.2. The test data are just drawn from $p(x,y)$. Table~\ref{tab:dataset} also describes the models and optimizers. In this table, FC refers to \emph{fully connected neural networks}, AllConvNet refers to \emph{all convolutional net} \citep{springenberg15iclr} and ResNet refers to \emph{residual networks} \citep{he16cvpr}; then, SGD is short for \emph{stochastic gradient descent} \citep{robbins51ams} and Adam is short for \emph{adaptive moment estimation} \citep{kingma15iclr}. Recall from Sec.~\ref{sec:erm-rev} that after the model and optimizer are chosen, it remains to determine the loss $\ell(z)$. We have compared the sigmoid loss $\ellsig(z)$ and the logistic loss $\elllog(z)=\ln(1+\exp(-z))$, and found that the resulted classification errors are similar; please find the details in Appendix~\ref{subsec:expresults}. Since $\ellsig$ satisfies \eqref{eq:cond-sym-loss} and is compatible with \eqref{eq:risk-uu-hat-sym}, we shall adopt it as the surrogate loss. The experimental results are reported in Figure~\ref{fig:performance}, where means and standard deviations of classification errors based on 10 random samplings are shown, and the table of final errors can be found in Appendix~\ref{subsec:expresults}. When $\theta=0.9$ and $\theta'=0.1$ (cf.~the left column), UU is comparable to PN oracle in most cases. When $\theta=0.8$ and $\theta'=0.2$ (cf.~the right column), UU performs slightly worse but it is still better than small PN baselines. This is because the task becomes harder when $\theta$ and $\theta'$ become closer, which will be intensively investigated next. \begin{figure}[t] \centering \begin{minipage}[c]{.05\textwidth}~\end{minipage}\hspace{1em \begin{minipage}[c]{0.4\textwidth}\centering\small $\theta=0.9$ \end{minipage \begin{minipage}[c]{0.4\textwidth}\centering\small $\theta=0.8$ \end{minipage}\\ \begin{minipage}[c]{.05\textwidth}\flushright\small UU \end{minipage}\hspace{1em \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{mnist_UU9_prior \includegraphics[width=0.5\textwidth]{mnist_UU8_prior} \end{minipage}\\ \begin{minipage}[c]{.05\textwidth}\flushright\small CCN \end{minipage}\hspace{1em \begin{minipage}[c]{0.8\textwidth} \includegraphics[width=0.5\textwidth]{mnist_CCN9_prior \includegraphics[width=0.5\textwidth]{mnist_CCN8_prior} \end{minipage} \vspace{-1ex \caption{Experimental results of moving $\theta'$ closer to $\theta$ (black dashed lines are PN oracle).} \label{fig:near-priors} \vspace{1ex \end{figure} \paragraph{On the closeness of $\theta$ and $\theta'$} It is intuitive that if $\theta$ and $\theta'$ move closer, $\Xtr$ and $\Xtr'$ will be more similar and thus less informative. To investigate this, we test UU and CCN \citep{natarajan13nips} on MNIST by fixing $\theta$ to 0.9 or 0.8 and gradually moving $\theta'$ from 0.1 to 0.5, and the experimental results are reported in Figure~\ref{fig:near-priors}. We can see that when $\theta'$ moves closer to $\theta$, UU and CCN become worse, while UU is affected slightly and CCN is affected severely. The phenomenon of UU can be explained by Theorem~\ref{thm:est-err}, where the upper bound in \eqref{eq:est-err-bound} is linear in $\alpha$ and $\alpha'$ which, as $\theta'\to\theta$, are inversely proportional to $\theta-\theta'$. On the other hand, the phenomenon of CCN is caused by stronger covariate shift when $\theta'$ moves closer to $\theta$ rather than the difficulty of the task. This illustrates CCN methods do not fit our problem setting, so that we called for some new learning method (i.e., UU). Note that there would be strong covariate shift not only by changing $\theta$ and $\theta'$ but also by changing $n$ and $n'$. The investigation of this issue is deferred to Appendix~\ref{subsec:expresults} due to limited space. \begin{table}[t] \caption{Mean errors (standard deviations) in percentage given inaccurate training class priors.} \label{tab:robust} \vspace{-1ex \begin{center}\small \begin{tabular*}{\textwidth}{l|c|rrrrr} \toprule Dataset & $\theta,\theta'$ & $\epsilon,\epsilon'$ = 0.8, 0.8 & $\epsilon,\epsilon'$ = 0.9, 0.9 & $\epsilon$ = $\epsilon'$ = 1.0 & $\epsilon,\epsilon'$ = 1.1, 1.1 & $\epsilon,\epsilon'$ = 1.2, 1.2 \\ \midrule \multirow{3}*{MNIST} & 0.9, 0.1 & 2.31~(0.16) & 2.31~(0.14) & 2.31~(0.14) & 2.32~(0.14) & 2.35~(0.14) \\ & 0.8, 0.2 & 3.00~(0.12) & 3.00~(0.11) & 3.01~(0.10) & 3.02~(0.10) & 3.01~(0.10) \\ & 0.7, 0.3 & 4.24~(0.23) & 4.24~(0.24) & 4.24~(0.26) & 4.25~(0.24) & 4.25~(0.25) \\ \midrule \multirow{3}*{CIFAR-10} & 0.9, 0.1 & 10.19~(0.37) & 10.14~(0.29) & 10.14~(0.30) & 10.11~(0.34) & 10.09~(0.35) \\ & 0.8, 0.2 & 10.84~(0.38) & 10.84~(0.40) & 10.77~(0.40) & 10.73~(0.40) & 10.73~(0.40) \\ & 0.7, 0.3 & 12.04~(0.61) & 12.00~(0.54) & 11.92~(0.54) & 11.91~(0.53) & 11.88~(0.53) \\ \midrule\midrule Dataset & $\theta,\theta'$ & $\epsilon,\epsilon'$ = 0.8, 1.2 & $\epsilon,\epsilon'$ = 0.9, 1.1 & $\epsilon$ = $\epsilon'$ = 1.0 & $\epsilon,\epsilon'$ = 1.1, 0.9 & $\epsilon,\epsilon'$ = 1.2, 0.8 \\ \midrule \multirow{3}*{MNIST} & 0.9, 0.1 & 2.30~(0.15) & 2.31~(0.16) & 2.31~(0.14) & 2.30~(0.13) & 2.30~(0.14) \\ & 0.8, 0.2 & 3.00~(0.10) & 3.00~(0.12) & 3.01~(0.10) & 3.02~(0.12) & 3.01~(0.11) \\ & 0.7, 0.3 & 4.19~(0.22) & 4.22~(0.23) & 4.24~(0.26) & 4.24~(0.25) & 4.25~(0.23) \\ \midrule \multirow{3}*{CIFAR-10} & 0.9, 0.1 & 10.20~(0.33) & 10.15~(0.34) & 10.14~(0.30) & 10.12~(0.35) & 10.08~(0.37) \\ & 0.8, 0.2 & 10.94~(0.46) & 10.83~(0.39) & 10.77~(0.40) & 10.75~(0.37) & 10.71~(0.43) \\ & 0.7, 0.3 & 12.24~(0.71) & 12.05~(0.59) & 11.92~(0.54) & 11.88~(0.53) & 11.95~(0.49) \\ \bottomrule \end{tabular*} \end{center} \end{table} \paragraph{Robustness against inaccurate training class priors} Hitherto, we have assumed that the values of $\theta$ and $\theta'$ are accessible, which is rarely satisfied in practice. Fortunately, UU is a robust learning method against inaccurate training class priors. To show this, let $\epsilon$ and $\epsilon'$ be real numbers around 1, $\vartheta=\epsilon\theta$ and $\vartheta'=\epsilon'\theta'$ be perturbed $\theta$ and $\theta'$, and we test UU on MNIST and CIFAR-10 by drawing data using $\theta$ and $\theta'$ but training models using $\vartheta$ and $\vartheta'$ instead. The experimental results in Table~\ref{tab:robust} imply that UU is fairly robust to inaccurate $\vartheta$ and $\vartheta'$ and can be safely applied in the wild. \begin{table}[t] \caption{Mean errors (standard deviations) in percentage of UU and state-of-the-art methods. Best and comparable methods (paired \textit{t}-test at significance level 1\%) are highlighted in boldface.} \label{tab:result} \vspace{-1ex \begin{center}\small \begin{tabular*}{\textwidth}{l|rrrr|rrrr} \toprule Dataset & $\pip$ & \# Sub & \# Train & $\Delta\theta$ & pSVM & BER & BER-FC & UU \\ \midrule pendigits & 0.1 & 4,000 & 971 & 0.57 & 4.03~(0.27) & 5.51~(1.35) & 5.46~(1.23) & \bf1.97~(0.78) \\ \midrule covertype & 0.3 & 7,400 & 3,863 & 0.80 & 14.63~(1.00) & 11.33~(0.26) & \bf5.17~(0.57) & \bf4.97~(0.48) \\ \midrule MNIST & 0.5 & 11,800 & 7,139 & 0.77 & N/A & \bf3.66~(0.20) & \bf3.03~(0.25) & \bf2.87~(0.28) \\ \midrule spambase & 0.7 & 3,570 & 1,139 & 0.80 & 29.18~(1.29) & \bf11.28~(1.73) & 13.98~(1.63) & \bf12.53~(1.00) \\ \midrule letter & 0.9 & 5,555 & 532 & 0.60 & 15.65~(4.18) & 15.45~(6.99) & 8.45~(2.92) & \bf3.15~(0.84) \\ \midrule \multirow{5}*{USPS} & 0.1 & 4,000 & 971 & 0.57 & 5.91~(1.52) & 12.69~(4.09) & 8.57~(2.40) & \bf3.74~(1.24) \\ & 0.3 & 5,000 & 2,605 & 0.80 & 5.55~(0.46) & 5.36~(0.41) & \bf2.75~(0.28) & \bf2.63~(0.18) \\ & 0.5 & 4,000 & 1,695 & 0.60 & 9.27~(0.61) & \bf7.27~(1.09) & \bf5.48~(1.33) & \bf5.52~(1.02) \\ & 0.7 & 5,720 & 1,853 & 0.80 & 8.20~(0.73) & 7.48~(0.65) & \bf4.23~(0.50) & \bf4.43~(0.94) \\ & 0.9 & 4,445 & 424 & 0.44 & 9.80~(2.07) & 14.13~(2.02) & 18.27~(5.17) & \bf6.20~(1.33) \\ \bottomrule \end{tabular*} \vskip1e \begin{minipage}{0.97\textwidth}\footnotesiz The first five datasets come with the original codes of BER and USPS is from \url{https://cs.nyu.edu/~roweis/data.html}. The rows are arranged according to $\pip$. In this table, \# Sub means the amount of subsampled L training data, \# Train means the amount of generated U training data, and $\Delta\theta$ means $\theta-\theta'$. The cell N/A (in MNIST row and pSVM column) is since pSVM is based on maximum margin clustering and is too slow on MNIST. The task would be harder, if $\pip$ is closer to 0.5, or \# Train or $\Delta\theta$ is smaller. \end{minipage} \end{center} \end{table} \subsection{Comparison with state-of-the-art methods} Finally, we compare UU with two state-of-the-art methods for dealing with two sets of U data \footnote{We downloaded the codes by the original authors; see \url{https://github.com/felixyu/pSVM} and \url{https://akmenon.github.io/papers/corrupted-labels/index.html}.} \begin{itemize} \item \emph{proportion-SVM} \citep[pSVM,][]{yu13icml} that is the best in learning from label proportions; \item \emph{balanced error minimization} \citep[BER,][]{menon15icml} that is the most related work to UU. \end{itemize} The original codes of BER train single-hidden-layer neural networks by LBFGS (which belongs to second-order optimization) in MATLAB. For a fair comparison, we also implement BER by fixing $\pip$ to 0.5 in UU, so that UU and BER only differ in the performance measure. This new baseline is referred to as BER-FC. The information of datasets can be found in Table~\ref{tab:result}. We work on small datasets following \citet{menon15icml}, because pSVM and BER are not reliant on stochastic optimization and cannot handle larger datasets. Furthermore, in order to try different $\pip$, we first subsample the original datasets to match the desired $\pip$ and then calculate the sample sizes $n$ and $n'$ according to how many P and N data there are in the subsampled datasets, where $\theta$ and $\theta'$ are set as close to 0.9 and 0.1 as possible. For UU and BER-FC, the model is FC with ReLU of depth 5 and the optimizer is SGD. We repeat this sampling-and-training process 10 times for all learning methods on all datasets. The experimental results are reported in Table~\ref{tab:result}, and we can see that UU is always the best method (7 out of 10 cases) or comparable to the best method (3 out of 10 cases). Moreover, the closer $\pip$ is to 0.5, the better BER and BER-FC are; however, the closer $\pip$ is to 0 or 1, the worse they are, and sometimes they are much worse than pSVM. This is because their goal is to minimize the balanced error instead of the classification error. In our experiments, pSVM falls behind, because it is based on discriminative clustering and is also not designed to minimize the classification error. \section{Conclusions} We focused on training arbitrary binary classifier, ranging from linear to deep models, from only U data by ERM. We proved that risk rewrite as the core of ERM is impossible given a single set of U data, but it becomes possible given two sets of U data with different class priors, after we assumed that all necessary class priors are also given. This possibility led to an unbiased risk estimator, and with the help of this risk estimator we proposed UU learning, the first ERM-based learning method from two sets of U data. Experiments demonstrated that UU learning could successfully train fully connected, all convolutional and residual networks, and it compared favorably with state-of-the-art methods for learning from two sets of U data. \subsubsection*{Acknowledgments} NL was supported by the MEXT scholarship No.\ 171536. MS was supported by JST CREST JPMJCR1403. We thank all anonymous reviewers for their helpful and constructive comments on the clarity of two earlier versions of this manuscript.
\section*{Acknowledgements} C. Cedzich acknowledges support by the Excellence Initiative of the German Federal and State Governments (ZUK 81) and the DFG (project B01 of CRC 183). T. Geib and R. F. Werner acknowledge support from the ERC grant DQSIM, the DFG SFB 1227 DQmat, and the European project SIQS. A. H. Werner thanks the Humboldt Foundation for its support with a Feodor Lynen Fellowship and the VILLUM FONDEN via the QMATH Centre of Excellence (Grant No. 10059). \section{From continuous to discrete - and back}\label{app:DisCont} Let us here lay out the details of the connection between the differential calculus on smooth manifolds and the discrete differential calculus on ${\mathbb Z}}\def\Nl{{\mathbb N}^s$. This will allow us to conclude a Poincar\'e lemma on ${\mathbb Z}}\def\Nl{{\mathbb N}^s$ from that on ${\mathbb R}}\def\Cx{{\mathbb C}^s$. On both sides we deal with expressions which are sums of terms of the form $f(x)\dd x^{\alpha_1}\wedge \dd x^{\alpha_1}\cdots \wedge\dd x^{\alpha_p}$. The coefficient function $f$ will be a function of position, i.e., $x\in{\mathbb R}}\def\Cx{{\mathbb C}^s$ in the continuum case and $x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s$ in the discrete case. Its values will be in ${\mathbb R}}\def\Cx{{\mathbb C}$ in the continuum case, and in the gauge group $U(1)$ in the discrete case. Both abelian groups will be written additively, so that, although we really mean products in the group of phases, we write sums of terms in ${\mathbb R}}\def\Cx{{\mathbb C}/2\pi{\mathbb Z}}\def\Nl{{\mathbb N}$. We do not require here any multiplication of these coefficients, although, of course, this is well-defined in the continuum case, and is needed to define the wedge product of differential forms. The coordinate differentials ``$\dd x^{\alpha}$'' are used as a purely formal device to aid the bookkeeping of antisymmetric expressions. Their wedge products are completely defined by being associative and antisymmetric. Hence any product of differentials can be brought into the form \begin{equation}\label{dxI} \dd x^{\alpha_1}\wedge \dd x^{\alpha_1}\cdots \wedge\dd x^{\alpha_p}=:\dd x^I \end{equation} where $I=\{\alpha_1,\alpha_2,\ldots,\alpha_p\}\subset\{1,\ldots,s\}$ with $\alpha_1<\alpha_2<\cdots\alpha_p$. The ordering process of a similar expression with permuted $\alpha_i$ to the normal form \eqref{dxI} at most produces signs, which makes sense in the respective coefficient group. The group of forms will be denoted in the continuum case by \begin{equation} \mathcal C=\bigwedge^s\nolimits\mathcal C({\mathbb R}}\def\Cx{{\mathbb C}^s; {\mathbb R}}\def\Cx{{\mathbb C}) \end{equation} with coefficients in $\mathcal C({\mathbb R}}\def\Cx{{\mathbb C}^s;{\mathbb R}}\def\Cx{{\mathbb C})$ the space of suitably differentiable functions $f:{\mathbb R}}\def\Cx{{\mathbb C}^s\to{\mathbb R}}\def\Cx{{\mathbb C}$. The degree of differentiability will be indicated in the context. Similarly, we write in the discrete case \begin{equation} \mathcal D=\bigwedge^s\nolimits\mathcal C({\mathbb Z}}\def\Nl{{\mathbb N}^s;U(1)) \end{equation} where the coefficients are taken as elements of $\mathcal C({\mathbb Z}}\def\Nl{{\mathbb N}^s;U(1))$ the space of functions from the lattice to the additively written group of phases, i.e., ${\mathbb R}}\def\Cx{{\mathbb C}/2\pi{\mathbb Z}}\def\Nl{{\mathbb N}$. Exterior derivatives $d$ taking $p$-forms to $p+1$-forms are defined in the smooth case as \begin{equation} d\bigl(f\,\dd x^I\bigr)=\sum_{\alpha\in I^c}(\partial_\alpha f)\, \dd x^\alpha\wedge \dd x^I, \end{equation} where $\partial_\alpha f=\partial f/\partial x^\alpha$, and $I^c$ denotes the complement of $I$ in $\{1,\ldots,s\}$. In the discrete case we write \begin{equation}\label{eq:ddisc} d\bigl(f\,\dd x^I\bigr)=\sum_{\alpha\in I^c}(d_\alpha f)\, \dd x^\alpha\wedge \dd x^I, \end{equation} where $(d_\alpha f)(x)=f(x+\alpha)-f(x)$ denotes the discrete derivative in direction $\alpha$. Clearly, both kinds of partial derivatives commute, which implies the fundamental relation \begin{equation}\label{eq:d20} d^2=0. \end{equation} In either setting, forms $f$ which satisfy $df=0$ are called \textbf{closed} whereas forms $f$ for which there exists another form $g$ such that $f=dg$ are called \textbf{exact}. It follows immediately from \eqref{eq:d20} that exact forms are closed. The converse is known as the \begin{lem}[Poincar\'e Lemma]\label{lem:poincont} Every closed form is exact. \end{lem} For $\mathcal C$ this is well known \cite{LeeDiffGeo}, and can be shown also for subregions, provided they are ``star-shaped''. For the discrete case this is done in \cite{hydon2004variational,mansfield2008difference}, with a subtle discussion of what star shaped should mean in the discrete case. We will not need this, but only the global version for the entire lattice. In order to strengthen the connections between the two calculi we sketch a proof by which the discrete result is derived from the smooth one. This may not be the natural order (as the discrete result is in some sense more elementary), but we hope it reduces the less familiar to the more familiar for most of our readers. {\bf Discretization} was already discussed in Sect.~\ref{sec:tight}. Here we get it as a map $\Delta:\mathcal C\to\mathcal D$. Its counterpart is a {\bf continuization}, a map $\Gamma:\mathcal D\to\mathcal C$. We will show that \begin{equation}\label{eq:DGid} \Delta\Gamma=\textrm{id}, \end{equation} i.e., first continuizing and then discretizing again gets us back to where we started from. The opposite relation is bound to fail, because discretization is clearly many-to one. To find such maps we first define in one dimension $\Delta_0,\Delta_1:\mathcal C({\mathbb R}}\def\Cx{{\mathbb C})\to\mathcal C({\mathbb Z}}\def\Nl{{\mathbb N})$ by \begin{align}\label{eq:conttodisc} (\Delta_0f)(n) &=f(n) \\ (\Delta_1f)(n) &=\int_n^{n+1} dx f(x). \end{align} Conversely, $\Gamma_0,\Gamma_1:\mathcal C({\mathbb Z}}\def\Nl{{\mathbb N})\to\mathcal C({\mathbb R}}\def\Cx{{\mathbb C})$ are defined by \begin{align} (\Gamma_0f)(x) &=(x-\lfloor x\rfloor)f(\lceil x\rceil)+(\lceil x\rceil-x)f(\lfloor x\rfloor)\\[1mm] (\Gamma_1f)(x) &=f(\lfloor x\rfloor)\label{eq:disctocont}. \end{align} \begin{figure}[t] \begin{center} \input{DeltaGamma} \end{center} \caption{\label{fig:DeltaGamma} Action of the discretization (left) and continuization (right) maps $\Delta_i$ and $\Gamma_i$ \eqref{eq:conttodisc}-\eqref{eq:disctocont}.} \end{figure} Here the floor function is defined as $\lfloor x\rfloor=\max\{n\in{\mathbb Z}}\def\Nl{{\mathbb N}|n\leq x\}$, and the ceiling function (non-standardly) as $\lceil x\rceil=\lfloor x\rfloor+1$. Hence, for an integer $n\in{\mathbb Z}}\def\Nl{{\mathbb N}$, $\lfloor n\rfloor=n$ and $\lceil n\rceil=n+1$. Thus both functions are lower semicontinuous. Fig.~\ref{fig:DeltaGamma} shows these functions. Obviously, the ranges of $\Gamma_0$ and $\Gamma_1$ do not consist of smooth functions, however, as piecewise continuous functions they do make sense as integrands of forms over arbitrary bounded regions. Moreover, for the purpose of such integrals, they can be approximated pointwise by smooth functions, making the integrals converge by dominated convergence. Henceforth we replace $\mathcal C({\mathbb R}}\def\Cx{{\mathbb C};{\mathbb R}}\def\Cx{{\mathbb C})$ by the algebra of piecewise continuous, lower semicontinuous, and locally bounded functions. One quickly verifies that \begin{equation}\label{eq:D01G01id} \Delta_0\Gamma_0=\textrm{id}=\Delta_1\Gamma_1. \end{equation} (Actually, also $\Delta_0\Gamma_1=\textrm{id}$, but $\Delta_1\Gamma_0\neq \textrm{id}$, but these are not needed). If we take the $\Delta_p$ and $\Gamma_p$ to act on the coefficients of $p$-forms for $p=0,1$, respectively, we immediately verify that \begin{equation} d\Delta_0=\Delta_1d \end{equation} as well as \begin{equation} d\Gamma_0=\Gamma_1d, \end{equation} where it is understood from the context which of the two exterior derivatives is meant by $d$. \begin{figure}[t] \begin{center} \input{disc_diff_cal} \end{center} \caption{\label{fig:disc_diff_cal}Discretization and continuization of $0,1,2$-forms. This is commutative except that $\Gamma\Delta\neq{\rm id}$.} \end{figure} These maps allow us now to define $\Delta$ and $\Gamma$ for arbitrary lattice dimension $s$ as follows: First, for any multi-index $I$ we define a map which discretizes elements of $\mathcal C({\mathbb R}}\def\Cx{{\mathbb C}^s)$, i.e. $\Delta^I:\mathcal C({\mathbb R}}\def\Cx{{\mathbb C}^s)\to\mathcal C({\mathbb Z}}\def\Nl{{\mathbb N}^s)$, by \begin{equation} \Delta^I=\Delta_1^{\otimes I}\otimes\Delta_0^{\otimes I^c}, \end{equation} where $I^c$ is the complement of $I$. This discretization can be extended to the algebra of $p$-forms with coefficients in $\mathcal C({\mathbb R}}\def\Cx{{\mathbb C}^s)$ simply by defining \begin{equation} \Delta f=\Delta({\sum_I}'f_I\dd x^I)={\sum_I}'(\Delta^If_I)\dd x^I. \end{equation} Analogously, we define the maps $\Gamma^I$ and $\Gamma$ which continuitize $f\in\mathcal C({\mathbb Z}}\def\Nl{{\mathbb N}^s)$ and $f\in\mathcal D$, respectively. From \eqref{eq:D01G01id} it immediately follows that $\Delta$ and $\Gamma$ satisfy \eqref{eq:DGid}. Moreover, \begin{equation} \label{d-intertwine} \Delta d=d\Delta\quad \text{and}\quad \Gamma d=d\Gamma. \end{equation} These relations are summarized in the commutative diagram Fig.~\ref{fig:disc_diff_cal}, for $0,1,2$-forms. Apart from emphasizing the close relations between the two calculi, this provides a way to import the Poincar{\'e} Lemma from the continuous to the discrete case. \begin{proof}[Proof sketch of the discrete Poincar\'e Lemma] The proof is basically an immediate consequence of the above construction. However, in this sketch we gloss over the question how much smoothness is needed for the continuum version to hold. Let $f\in\mathcal D$ be a closed discrete form, i.e. $df=0$. Then, we construct a corresponding form $f'\in\mathcal C$ by setting $f'=\Gamma f$ which is closed by \eqref{d-intertwine}. According to the Poincar\'e lemma \ref{lem:poincont} $f'$ is exact, i.e. there exists a form $g'$ such that $f'=dg'$. Acting with $\Delta$ on both sides by \eqref{eq:DGid} gives \begin{equation} f=\Delta f'=\Delta dg'=d\Delta g'=dg, \end{equation} where we abbreviated $\Delta g'=g$. \end{proof} \section{Examples} \subsection{Homogeneous Systems}\label{sec:homo} The idea of a homogeneous system is clear enough: Its properties should be everywhere the same. More formally, the translations should act as a symmetry group. Quantum systems in a constant external magnetic field are a notorious example showing that this does not imply that a description in terms of translation invariant quantities is possible. Indeed, the vector potential for a non-zero constant field necessarily grows at least linearly in the coordinates. The translations in this case are indeed a symmetry, but only up to gauge transformations. So it is natural to introduce another translation system $S$, which unites the required shifts and gauge transformations. Indeed, the notion of translation system is ideally suited to express such combinations. Given the translation system $T$ expressing the electromagnetic field, the condition that $S$ acts as a symmetry is simply \begin{equation}\label{stts} S_\alpha T_\beta= T_\beta S_\alpha \end{equation} for all $\alpha,\beta$. Note that $T_\alpha$ cannot express the symmetry operations, because for non-vanishing field the component translations do not commute, see \eqref{eq:plaquetteoperator}. Let us look at the continuous case for guidance to the right questions. The analogy starts from a connection $\partial_\alpha-iA_\alpha$ (infinitesimal version of $T_\alpha$), and asks for the existence of a second connection, $\partial_\beta-iB_\beta$, expressing the symmetry, in the sense of commuting with the first. The condition for that is obviously \begin{equation}\label{dBdAdAdB} \partial_\alpha B_\beta=\partial_\beta A_\alpha \end{equation} for all $\alpha,\beta$. The first consequence is that $\partial_\alpha(A_\beta+B_\beta)=\partial_\beta(A_\alpha+B_\alpha)$. That is, the curvatures (=fields) add up to zero, which implies that $A_\alpha+B_\alpha=\partial_\alpha C$ for some scalar function $C$. This turns \eqref{dBdAdAdB} into an equivalent equation for $C$, namely \begin{equation}\label{dabC} \partial_\alpha\partial_\beta C=\partial_\beta A_\alpha+\partial_\alpha A_\beta. \end{equation} $C=0$ solves this equation if the right hand side vanishes, i.e., $A$ satisfies the \textbf{symmetric gauge} condition, which is quite popular for constant magnetic fields. It actually does not exist otherwise, as one sees from differentiating \eqref{dabC} with respect to $x_\mu$ and using the permutation symmetry of $\partial_\mu\partial_\alpha\partial_\beta C$. This readily gives $\partial_\mu F_{\alpha\beta}=0$, i.e., the fields are constant, which is satisfying, because it implies that also the $\partial_\beta-iB_\beta$ commute up to constants. Hence their exponentials, which are the unitary operators expressing the symmetry of finite translations commute up to global phases. This is just what Wigner's theorem requires of a symmetry. So we would have had to impose this condition anyway, but it turns out it came out just from \eqref{stts}. In the literature these unitaries are known as \textbf{magnetic translation operators} \cite{brown1964bloch,zak1,zak2}. The discrete analogue of these statements is the following. \begin{prop}Let $T$ be an $U(1)$-translation system. Then the following conditions are equivalent: \begin{itemize} \item[(1)] There is a second translation system $S$ such that $S_\alpha T_\beta= T_\beta S_\alpha$. \item[(2)] The plaquette phases $P_{\alpha\beta}$ are independent of $x$. \item[(3)] $T$ is gauge equivalent to a translation system $T^\prime$ that satisfies $T_\alpha^\prime\phi_x =T^\flat_\alpha P^>_{\alpha}(x)\phi_x$ with $P^>_\alpha(x) = \prod_{\beta>\alpha} (P_{\alpha\beta})^{x_\beta}$, see Fig.~\ref{fig:pathorder}. \end{itemize} In this case $S$ in (1) is defined up to a constant phase, has plaquette phases $1/P_{\alpha\beta}$, and in the gauge (3) takes the form $S_\alpha^\prime \phi_x = T^\flat_\alpha P^<_\alpha(x)\phi_x$, with $P^<_\alpha(x)=\prod_{\gamma<\alpha}(P_{\gamma\alpha})^{x_\gamma}$. \end{prop} \begin{proof} \proofdir12 According to \eqref{eq:plaquetteoperator}, $P_{\alpha\beta}$ is given as the product $T_\alpha^*T_\beta^*T_\alpha T_\beta$ and hence clearly invariant under conjugation by $S_\gamma$ if we assume (1). At the same time, $P_{\alpha\beta}$ is a localized operator on which the translation system $S_\gamma$ acts as $S_\gamma P_{\alpha\beta}S^*_\gamma\phi_x = P_{\alpha\beta}(x-\hat{\gamma})\phi_x$, hence $P_{\alpha\beta}(x)$ cannot depend on $x$. \proofdir23 Choosing the path-ordered gauge according to \eqref{pathorder} and using repeatedly $T^\prime_\alpha T^\prime_\beta = P_{\alpha\beta}T^\prime_\beta T^\prime_\alpha$, we find \begin{align} T^\prime_\alpha \phi_x &= T^\prime_\alpha \left(T^\prime_s\right)^{x_s}\cdots \left(T^\prime_\alpha\right)^{x_\alpha}\cdots \left(T^\prime_0\right)^{x_0} \phi_0\\ &= \left(\prod_{\beta>\alpha} \left(P_{\alpha\beta}\right)^{x_\beta}\right)\left(T^\prime_s\right)^{x_s}\cdots \left(T^\prime_\alpha\right)^{x_\alpha+1}\cdots \left(T^\prime_0\right)^{x_0}\phi_0\,. \end{align} \proofdir31 Choosing the path ordered gauge and setting $S^\prime_\alpha \phi_x = P^<_\alpha(x) T^\flat_\alpha\phi_x $, a direct calculation using \eqref{plaqx} shows that both $S^*_\alpha S^*_\beta S_\alpha S_\beta = 1/P_{\alpha\beta}$ and $S_\alpha T_\beta= T_\beta S_\alpha$ are satisfied. \end{proof} The $T'_\alpha$ in this proposition are a basis for a symmetry representation of the translation group in the following sense: for each $x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s$ let $\gamma(x)$ be the standard path $0\to x$. Then $x\mapsto T'_{\gamma(x)}$ corresponds to a projective representation with \begin{equation} T'_{\gamma(x)}T'_{\gamma(y)}=P^>(x,y)T'_{\gamma(x+y)}, \end{equation} where $P^>(x,y)=\prod_{\beta>\alpha}P_{\alpha\beta}^{x_\alpha y_\beta}$ is a multiplier \cite{BackhouseProjective1,BackhouseProjective2}. It follows from standard arguments that $T'_{\gamma(x)}$ commutes with the projective representation with multiplier $P^<(y,x)$ up to normalization of $P^>(x,y)$ \cite{kleppner1962,kleppner1965}. \subsection{Rational fields}\label{sec:ratfields} In general, even under the homogeneity assumption electromagnetic systems are not easy to solve. The main reason is that Fourier transformation fails. After all, the idea is to jointly diagonalize translations and the walk or Hamiltonian, which fails, when the translations do not commute in the first place. However, translation invariance can sometimes be restored for a magnetic system by \textbf{regrouping}. For example, in the two dimensional case of Sect.~\ref{sec:butter}, when $F_{12}=p/q$ is rational the translation in $x$-direction commutes with the translation by $q$ steps in $y$-direction. Hence, if we group cells periodically to supercells of $q$ individual cells stacked in $y$-direction, we come back to a strictly translation invariant system, which can be solved by Fourier transform. The internal structure of the supercells now means that we have $q$ times the number of internal degrees of freedoms, and correspondingly many bands. It is clear even in this simplest example that the regrouping is not unique, and this will persist in more complex cases. The following proposition describes the kind of system for which regrouping to a translation invariant system is feasible. Note that ``rational'' phases are those for which some power is $1$, so that in the present context we call $F$ \textbf{rational} if $F\in2\pi{\mathbb Q}}\def\Tw{{\mathbb T}$. \begin{prop} Let $T$ be a homogeneous translation system on ${\mathbb Z}}\def\Nl{{\mathbb N}^s$, $s\geq2$ with field matrix $F$. Then the following are equivalent \begin{itemize} \item[(1)] All entries of $F$ are rational, i.e., $F_{\mu\nu}\in2\pi{\mathbb Q}}\def\Tw{{\mathbb T}$ for all $\mu,\nu$. \item[(2)] There is a sublattice $\Lambda\subset{\mathbb Z}}\def\Nl{{\mathbb N}^s$, generated by linearly independent vectors $\lambda_1,\ldots,\lambda_s$ such that the translations by lattice vectors commute. \item[(3)] The holonomy group $\hol$ is finite. \end{itemize} Each of these conditions comes with a natural size parameter, namely \begin{eqnarray} q_1 &=&\min\{q\in\Nl|\forall\mu,\nu:\ qF_{\mu\nu}\in2\pi{\mathbb Z}}\def\Nl{{\mathbb N}\} \\ q_2 &=&\min|\det(\lambda_1,\ldots,\lambda_s)|\\ q_3 &=& \#\hol=q_1 \end{eqnarray} \end{prop} The number of practical interest here is $q_2$, which is the number of lattice points of ${\mathbb Z}}\def\Nl{{\mathbb N}^s$ lying in an elementary cell of the lattice $\Lambda$. \begin{proof} In the proof we will keep track of the numbers $q_i$, providing some basic bounds. \noindent{\it (1)$\Leftrightarrow$(3):\ } Since $P_{\alpha\beta}=\exp(iF_{\alpha\beta})\in\hol$. If this group is finite, it consists of the $q_3^{\rm th}$ roots of unity, so $q_3F_{\alpha\beta}\in2\pi{\mathbb Z}}\def\Nl{{\mathbb N}$. Conversely, if all $F_{\alpha\beta}$ are rational with denominator $q_1$ the plaquette phases are all in the group of $q_1^{\rm th}$ roots of unity, and since all closed paths can be composed of plaquettes, this must be the whole holonomy group. Hence $q_1=q_3$. \proofdir12 Take $\lambda_\alpha=q_1\,\hat\alpha$ for $\alpha<s$ and $\lambda_s=\hat s$. Then $F(\lambda_i,\lambda_j)\in2\pi{\mathbb Z}}\def\Nl{{\mathbb N}$, because at least one of the vectors involved has a factor $q_1$. Hence $q_2\leq q_1^{s-1}$. Of course, there may be smaller lattices with this property. \proofdir21 Let $\Lambda$ be a lattice of commuting translations. Consider the dual lattice $\Lambda'\subset{\mathbb R}}\def\Cx{{\mathbb C}^s$, which is spanned by a dual basis, i.e., vectors $\xi_k$ so that $\xi_k\cdot\lambda_j=\delta_{ik}$. The matrix of components of the $\xi_k$ is the inverse of the component matrix of the $\lambda_j$, whose determinant is $q_2$. Hence the components of $\xi_k$ are rational with denominator $q_2$. Expressing the basis vectors of ${\mathbb Z}}\def\Nl{{\mathbb N}^s$ in the basis $\{\lambda_i\}$, and observing that $F$ takes $2\pi{\mathbb Z}}\def\Nl{{\mathbb N}$-values on pairs of such basis vectors, we get that $F$ is rational with denominator $q_2^2$. That is $q_1\leq q_2^2$. \end{proof} The one-dimensional case was excluded here, because holonomy is trivial and there are no plaquette phases. In the two-dimensional case there is only one field component, say, $B=F_{12}=2\pi p/q$. Then for any pair of integer vectors $x,y$ we have \begin{equation}\label{2Dregroup} \sum_{\alpha\beta}F_{\alpha\beta}x_\alpha\,y_\beta=2\pi\frac pq\ (x_1y_2-x_2y_1) =2\pi\frac pq\ \det(x,y). \end{equation} Hence $x$ and $y$ qualify as basis vectors $\lambda_1,\lambda_2$ satisfying (2) iff their determinant is a multiple of the denominator $q$. Clearly, the minimal choice is $q$ itself, so that $q_1=q_2=q_3$ in this case. Preliminary checks suggest that this might also be the case for $s=3$, but for higher dimension we do not yet have a convincing intuition. \subsection{Electric walk 1D}\label{sec:ewalks} Let us briefly come back to the purely electric setting introduced in Sec. \ref{sec:mincoup} $P_{k\ell}=\idty$ for $k,\ell=1,\dots,s$ and $P_{0\alpha}$ is the electric field component in direction $\alpha$. Indeed, in the gauge where the spatial translations are flat, ``switching on'' an electric field by $T^\flat_0\mapstoT^\flat_0 U_0(t,x)$ boils down to \cite{ewalks} \begin{equation}\label{eq:elecFSw} W\mapsto U_0(t,x)W. \end{equation} Note however, that this procedure corresponds to a particular choice of gauge. Other common gauges are the temporal (or ``Weyl'') gauge, were $T^\flat_0$ is left unchanged \cite{creutz1977gauge}, and in the homogeneous case the symmetric gauge. In one spatial dimension quantum walks in homogeneous and static electric fields have been studied extensively, both theoretically \cite{ewalks} and experimentally \cite{meschede13}. There, electric walks are described in the gauge \eqref{eq:elecFSw}, in which the electric walk operators become time-independent, which allows to meaningfully discuss their spectral properties. For electric walks of the form $W=e^{i\EF Q}CS$ the propagation behaviour depends discontinuously on the field $\EF$ \cite{ewalks} or, more precisely on the rationality or irrationality of $E/(2\pi)$. In the rational case, one can regroup local cells as described in Sec. \ref{sec:ratfields} in order to obtain a translation invariant quantum walk with a larger internal degree of freedom. This eventually leads to ballistic expansion, whereas on short time scales of the order of the denominator of the field revivals to the initial state are found. In contrast, irrational fields lead either to Anderson localization \cite{locQuasiPer} similar to the disordered setting \cite{dynloc,dynlocalain}, or they propagate hierarchically. In the latter case, the particle shows an infinite number of sharper and sharper revivals of the initial state. After each of these revivals the particle propagates farther and farther. Each of these propagation behaviours corresponds to a different spectral type: in the rational case the ballistic expansion corresponds to absolutely continuous spectrum, whereas localization in the irrational case is characterized by pure point spectrum. For irrational fields which are enormously well approximable by rationals the spectrum is singular continuous. \subsection{Walk with quasi-periodic coin}\label{sec:qperiodic In temporal gauge $U_0=\idty$ the spatial translations cannot be chosen flat anymore, and the electric walks in the previous section become explicitly time-dependent. For the one-dimensional electric walk of \cite{ewalks} this gauge transformed walk operator was shown in \cite{ususi} to be given by $W(t)=CS(t)$, where $S(t)=\sum_{k=\pm1} P_k\Ts_1^k$ for $\Ts_1=\Tsf_1U_1(x,t)$ with $U_1(x,t)=e^{-itE}$ and $P_k$ denotes the projection onto the $k$-eigenstate of $\sigma_z$. In \cite{susi}, a similar model with quasi-periodically time-dependent coin $C(t)=R_y(\theta)R_x(t\phi)$ was discussed, where $R_\alpha$ denotes rotation around the $\alpha$-axis in coin space. Even though the translation systems in this walk model and the electric walk are not $U(1)$-equivalent but only equivalent up to a Hadamard coin, their propagation behaviour is strikingly similar. In particular, for the walk $W(t)=C(t)S$ the same revival structure is observed. As discussed in \cite{ususi}, the reason for this is that the same techniques apply which, however, is a special feature of this model. \subsection{Magnetic walk 2D}\label{sec:butter} To give a concrete example of the purely magnetic case, let us consider the simplest setting in which magnetic fields can occur, i.e. a two-dimensional lattice \cite{Sajid,marquez2018electromagnetic}. On $\ell_2({\mathbb Z}}\def\Nl{{\mathbb N}^2)\otimes\Cx^2$ we consider the decomposed walk \begin{equation} W=S_2CS_1C' \end{equation} where $C,C'$ are localized unitaries. The $S_\alpha$ are state-dependent shifts defined by $S_\alpha:=\sum_{k=\pm1} P_k\Tsff{k}_\alpha$ where as above $P_k$ denotes the projection onto the $k$-eigenstate of $\sigma_z$. Since there are no electric fields present we have $P_{0\alpha}=\idty$ throughout and the magnetic fields are static by the Maxwell equations \eqref{eq:disc_maxwell}. Magnetic fields identified by non-trivial spatial plaquette phases are implemented via the minimal coupling $\Tsf_\alpha\mapsto \Ts_\alpha$ for $\alpha=0,1,2$. As discussed at the end of Sec.~\ref{sec:mincoup}, in the purely magnetic case it is advantageous to work in temporal gauge: in this (partial) gauge the $U_k(t,x)$ are time-independent and consequently dynamics are implemented by iterating the same walk operator. Assuming the magnetic field $F_{12}$ to be homogeneous and the coin operators $C,C'$ to be given as the constant Hadamard matrix $\left(\begin{smallmatrix} 1&\hphantom{-}1\\1&-1\end{smallmatrix}\right)/\sqrt2$, the spectrum of the magnetic walk in dependence of the field resembles a fractal heavily reminding of the famous \emph{Hofstadter butterfly} \cite{hof76}, see Fig.~\ref{Butterfliege}. The symmetric structure of this ``Quantum Walk Butterfly'' can be understood using techniques from irrational rotation algebras which, however, is beyond the scope of this example. For $F_{12}/(2\pi)=\nr/\dr$ rational the system is translation invariant after regrouping, see Sec.~\ref{sec:ratfields}. Therefore, the spectrum is absolutely continuous and consists of $2\dr$ bands. For irrational fields the spectrum is expected to be homeomorphic to the Cantor set, similar to the continuous system of Bloch electrons in a magnetic field \cite{bellissard1982cantor}\cite[Chapter VI.]{hof76}. A similarly discontinuous dependence of the spectral type on the field parameter was observed for one-dimensional electric walks \cite{ewalks}, see also Sec.~\ref{sec:ewalks}, and for the original butterfly \cite{hof76}. However, since the distinction between the different classes of fields requires infinite precision, it remains unclear how it influences real-life experiments. \begin{figure}[t] \begin{center} \includegraphics[width=.4\textwidth]{Butterfliege.png} \caption{\label{Butterfliege}The spectrum of a two-dimensional magnetic Hadamard walk \cite{christalk}. The vertical axis corresponds to the field and the horizontal axis to the argument of the quasi-energy.} \end{center} \end{figure} \section{Introduction} In textbook quantum mechanics particles are placed in an electromagnetic field by applying the so-called \emph{minimal coupling principle}. This demands a modification of the generators of space and time translations, such that they only commute with each other up to multiplication operators, which reflects the presence of electromagnetic fields. In this manuscript the systems under consideration are single particles with spin which evolve in discrete time on a lattice. Such systems are called \emph{quantum walks} \cite{Ambainis2001,Grimmet,SpaceTimeCoinFlux,TRcoin,GenMeasuringDevice}. The minimal coupling mechanism for turning on an electromagnetic field does not carry over to such systems directly, because discrete translations have no \emph{generators} $P_\mu$. However, one would expect an analogue to hold, where the self-adjoint generators are replaced by unitary one-step translation operators, both in space and in time, and no reference to a background field on a space-time continuum is needed. The first main message of this paper is that this works, and we set up the necessary lattice gauge environment. The important second message is how to set up the minimal coupling scheme, that is, how to put a given walk into an external field, and specifically, what to substitute in the magnetic substitution and how. Of course, our scheme is gauge invariant in the sense that, up to a gauge transformation, the result depends only on the field, and not on the vector potentials. While there are several examples in the literature \cite{ewalks,electric2D,othermagwalk,Sajid,Farrelly15} which describe an external electromagnetic field in accordance with our general scheme, the general case has not been formulated and studied at its natural level of generality. Hence we give a unifying background to the works mentioned, and also help to correct some faulty approaches [no cite]. The following are the main features of our approach \begin{itemize} \item[(1)] The setting allows lattice systems on an infinite cubic lattice ${\mathbb Z}}\def\Nl{{\mathbb N}^s$ of any space dimension $s$, with finite dimensional internal Hilbert space $\Cx^d$. The notion of gauge transformations is established at this kinematical level. \item[(2)] Electric and magnetic fields are properties of {\it translation systems}, the analogues of infinitesimal space-time translations as described by a connection. We show that translation systems are equivalent (in a natural sense) iff they are connected by a gauge transformation iff they have the same fields. \item[(3)] At the level of translation systems there is no difference between space and time, so that time just adds one dimension to the spatial lattice. In this way magnetic and general electromagnetic fields are handled in the same framework. \item[(4)] The cohomology of differential forms has a direct translation to the discrete case \cite{hydon2004variational,mansfield2008difference}, where $p$-forms are functions defined on the set of $p$-dimensional facets of the cubic lattice. Every electromagnetic field arising from a translation system satisfies the discrete analog of the homogeneous Maxwell-equations $dF=0$ and, conversely, any field with this property can be realized in this way. Field zero means gauge equivalence to a trivial translation system. \item[(5)] Every $p$-form in the continuum setting is mapped to a discrete $p$-form by integration over the appropriate facets. This map commutes with exterior differentiation, but is highly many-to-one. We also construct a continuization map in the opposite direction. \item[(6)] The analogue of minimal coupling, i.e., putting a given quantum walk into a field is explicitly defined whenever the walk is given as a finite product of subshift and coin operators. Here subshift operators are shifts, that may be conditional on the internal degree of freedom, but do not otherwise affect the internal degree of freedom, and coin operators act at each site separately, possibly in a different way. \item[(7)] Different decompositions of the same unitary walk operator may lead to different results. This is analogous to the observation in the continuum case that the outcome of minimal coupling depends on ``operator ordering'', i.e., how the Hamiltonian is written as a non-commutative polynomial of momenta. Operator ordering is irrelevant before minimal coupling, since the momenta commute, but makes a real difference afterwards, which cannot be gauged away. \item[(8)] Constant fields play an important role in practice. As in the continuum case they require that a homogeneous system is described by non-constant potentials. Nevertheless, the translations act as a symmetry up to gauge transformations, and this defines a ``dual'' translation system expressing the symmetry. \item[(9)] When the field is rational, a regrouping can be used to restore full translation symmetry for a system of supercells. \end{itemize} We believe that the close analogies with the continuous case and ordinary electrodynamics sufficiently justify talking of ``electromagnetic fields'' in this context. Of course, these structures survive a continuum limit, by which one hence comes back effortlessly to ordinary electromagnetic fields. Our approach thus has some overlap with work \cite{DebbaschMag,DebbaschLandau,DebbaschGrav} that introduces ``electromagnetic fields'' as a structure turning into proper fields in the continuum limit. Electromagnetic lattice systems are also important for the implementation of quantum simulators \cite{buluta2009quantum,bloch2012quantum,blatt2012quantum}, e.g., for solid state systems. The simulating system may consist of neutral atoms in an optical lattice, and although physical electromagnetic fields are around, and are used for controlling the atoms, these are not the ``simulated'' fields, which have to be implemented in another way. For example, electric fields have been realized by accelerating the lattice \cite{meschede13}. A discussion of the options for magnetic fields in 2D is found in \cite{Sajid}. In any case the justification of calling such a system magnetic is in the realization of the structure we describe, or some version thereof. For the simple systems studied so far a direct Peierls substitution gives the right result, but for more complex walks and cellular automata a systematic approach is called for. We do not address here the dynamical consequences of electromagnetic fields. One case that is completely understood is that of 1D electric walks \cite{ewalks,locQuasiPer}. Here the long time behaviour and the spectrum depend on the rational/irrational character of the field parameter in the form of its continued fraction expansion. A similarly sensitive dependence is found for 2D magnetic systems, leading to a version of the well-known Hofstadter butterfly \cite{hof76}. General results on propagation, or the analogs of Landau orbits do not seem to exist yet. Fascinating trapping behaviour of the boundary between two regions with different magnetic field, characterized by distinct Chern numbers, is predicted in \cite{Sajid}. Our paper is organized as follows. We begin by recalling the continuum case (Sect.~\ref{sec:recap}), and describe the kinematical setup for discrete gauge fields in Sect.~\ref{sec:gauge}. In this section only the translations from one space-time point to another are considered, and space and time are treated in exactly the same way. A system Hilbert space (with normalization over space, but not over time) is only introduced in the next Sect.~\ref{sec:NowWalk}. This includes also the equations of motion and the discrete minimal coupling scheme. In the examples section we treat the homogeneous case (Sect.~\ref{sec:homo}), rational fields and regrouping (Sect.~\ref{sec:ratfields}), electric walks in 1D (Sect.~\ref{sec:ewalks}), quasi-periodicity in space and/or time (Sect.~\ref{sec:qperiodic}), and magnetic walks in 2D (Sect.~\ref{sec:butter}). \section{Discrete Minimal coupling}\label{sec:NowWalk} \subsection{The Hilbert space} So far we have described only the kinematical part of the theory: a bundle-like structure of Hilbert spaces attached to points $x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s$ with a system of translations. There was no dynamics and no time coordinate. We start by singling out a time coordinate. Thus our lattice becomes ${\mathbb Z}}\def\Nl{{\mathbb N}\times{\mathbb Z}}\def\Nl{{\mathbb N}^s={\mathbb Z}}\def\Nl{{\mathbb N}^{s+1}$, with the first coordinate henceforth playing the role of time. The point here is that at the level of translation systems there is no difference between temporal and spatial translations, and therefore we automatically have the typical combination of electric field components $F_{0k}$ and magnetic components $F_{k\ell}$, where $k,\ell=1,\ldots,s$ are the spatial indices. We will write the points of ${\mathbb Z}}\def\Nl{{\mathbb N}\times{\mathbb Z}}\def\Nl{{\mathbb N}^s$ as pairs $(t,x)$, and $\HH_{t,x}$ for the local Hilbert space at the event $(t,x)$. The difference between time and space comes in when we describe the Hilbert space of the system. This will now be a family of Hilbert spaces indexed by time, namely \begin{equation}\label{timeslice} \HH(t)=\bigoplus_{x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s}\HH_{t,x}. \end{equation} This direct sum is to be read as a Hilbert space direct sum with the norm $\norm{\psi(t)}^2=\sum_x\norm{\psi(t,x)}^2$, and associated scalar product. Note that $\psi(t,x)$ is the component of $\psi(t)$ in the direct summand $\HH_{t,x}$. There is no normalization condition involving a sum over time. This definition makes sense in the abstract setting, but it can be simplified to \begin{equation}\label{HHtcoo} \HH(t)=\ell^2({\mathbb Z}}\def\Nl{{\mathbb N}^s)\otimes\Cx^d \end{equation} after identifying the local Hilbert spaces by a flat translation system. Let us consider some operators in these Hilbert spaces. Every localized operator $A$ (see Sect.~\ref{sec:tsys}) simply acts on $\HH(t)$ as $\bigoplus_xA_{t,x}$, i.e., for $\psi(t)\in\HH(t)$ we have $(A\psi)(t,x)=A_{t,x}\psi(t,x)$. This means that localized operators become a time-dependent family of operators $A(t)$ acting in $\HH(t)$. In particular, this goes for gauge transformations. The spatial translations of a translation system become a family of unitary operators $\Ts_k\in\BB(\HH(t))$, acting as \begin{equation}\label{unitarytrans} (\Ts_k\psi)(t,x)=T_k\Bigl(\psi(t,x-\hat k)\Bigr). \end{equation} Here the arguments are dictated by the rule that $\psi(t,x)\in\HH_{t,x}$ also holds for $\Ts_k\psi$. A \textbf{constant operator} $A$ is a localized operator commuting with all translations. Since for a $U(1)$-theory all localized operators commute with gauge transformations, a constant operator remains constant for any translation system differing by a gauge transformation as in Sect.~\ref{sec:gaugeTrafo}. In the factorization \eqref{HHtcoo} the constant operators are then simply the ones of the form $\idty\otimes A$ with $A$ an operator on $\Cx^d$ \subsection{Dynamics: Walks} A pure quantum state is now given by a family of vectors $\psi(t)\in\HH(t)$, which we interpret as the state ``at time $t$''. Knowing the state at one time allows us to determine it for all times. This is expressed by a \textbf{dynamical constraint}, or \textbf{equation of motion}. This connection between $\psi(t)$ and $\psi(t+1)$ will involve $T_0$, the timelike member of the translation system, which maps $\HH(t)$ to $\HH(t+1)$. So one possible dynamical constraint would be $\psi(t+1)=T_0\psi(t)$, which from the point of view of the given translation system just means that $\psi$ is ``constant'' in time. In a more general setting, the dynamical constraint is given by a family of unitary operators $W(t)$ on $\HH(t)$ such that \begin{equation}\label{dynamics} \psi(t+1)=T_0\ W(t)\ \psi(t). \end{equation} We have seen that, e.g., in a path ordered gauge the first coordinate can always be represented by a flat translation. Choosing such a \emph{temporal gauge} allows us to just identify the Hilbert spaces $\HH(t)$, and drop the map $T_0$ from the equation. In this way we go back to the more common description in a fixed Hilbert space with a possibly time-dependent unitary step operator $W(t)$. The reason for choosing the form \eqref{dynamics} is that it makes clear how to include gauge transformations which affect the temporal component. What does not work is to take the operator $W$ itself as the time translation. This is like confusing $i\partial_t$ with the Hamiltonian. In any case, since $W$ typically spreads the wave function to many sites, this would not fit the description of translation systems, on which the unification of magnetic and electromagnetic case is based. \subsection{Walks, shifts, and coins} We typically require that $W$ has finite \textbf{jump length} $L$, which means that $W(t)\HH_{t,x}\subset\bigoplus_{y;\,|y-x|<L}\HH_{t,y}$. Here we briefly describe some standard ways for writing down a walk. Let us first consider the case without external fields, using the flat translation system only, and just one fixed $t$. We can write $W\equiv W(t)$ as \begin{equation}\label{Wkernel} (W\psi)(x)=\sum_yW(x,y)\psi(y), \end{equation} where the kernel $W(x,y):\HH_y\to\HH_x$ is operator valued. When $\HH_x\equiv\Cx^d$, each $W(x,y)$ just a $d\times d$-matrix. These matrices by themselves are typically not unitary because they contain only one part of the jump amplitudes. Instead unitarity, i.e., preservation of probability, is expressed by a sum involving all jumps. Rather than the jump origin (as in \eqref{Wkernel}), we can take the translation $z=(x-y)$ to index the sum, emphasizing the translation part of such a map, by bringing in the unitary shift operators $\Tsf_\alpha$ (see \eqref{unitarytrans}): \begin{equation}\label{walk0} (W\psi)(x)=\sum_z W_z(x)(\Tsff z\psi)(x) \end{equation} so that $W_z$ becomes a localized operator, and the sum is only over $|z|<L$. Here $\Tsff z$ with $z=(z_1,\ldots,z_s)$ is a shorthand for $(\Tsf_1)^{z_1}\cdots(\Tsf_s)^{z_s}$, the shift along the lattice vector $z$. Formula \eqref{walk0} is a matrix-valued expression in the following sense: We can think of $\ell^2({\mathbb Z}}\def\Nl{{\mathbb N}^s)\otimes\Cx^d$ either as $\ell^2({\mathbb Z}}\def\Nl{{\mathbb N}^s;\Cx^d)$, that is vectors which are functions on ${\mathbb Z}}\def\Nl{{\mathbb N}^s$ with ``spinor'' values in $\Cx^d$, or else as $d$-component vectors, whose entries are in $\ell^2({\mathbb Z}}\def\Nl{{\mathbb N}^s)$. In the latter view we can think of a walk as a $\d\times d$-block matrix operator whose entries are operators on $\ell^2({\mathbb Z}}\def\Nl{{\mathbb N}^s)$. Then in the above formula each $W_z(x)$ is a $d\times d$-matrix, so the same formula holds matrix element by matrix element. Consider, for example, the translation invariant walk, which is the basis of the example in Sect.~\ref{sec:butter}. Its matrix can be written as \begin{eqnarray}\label{tiwalk} W&=&\frac12\begin{pmatrix}\Tsf_2&0\\0&\Tsff*_2\end{pmatrix}\begin{pmatrix}1&1\\1&-1\end{pmatrix}\begin{pmatrix}\Tsf_1&0\\0&\Tsff*_1\end{pmatrix}\begin{pmatrix}1&1\\1&-1\end{pmatrix} \nonumber\\ &=& \frac12\begin{pmatrix}\Tsf_2(\Tsf_1+\Tsff*_1)&\Tsf_2(\Tsf_1-\Tsff*_1)\\\Tsff*_2(\Tsf_1-\Tsff*_1)&\Tsff*_2(\Tsf_1+\Tsff*_1)\end{pmatrix}. \end{eqnarray} Here every matrix entry is a polynomial in the shift operators. It has constant coefficients, which expresses translation invariance. For more general space dependent coins there would also be $x$-dependent coefficients. The first form in \eqref{tiwalk} is often used in the (theoretical or experimental) construction of walks, and is called a shift-coin decomposition. It is a product of two kinds of operations: On the one hand, the ``coin'' operations are just the localized unitary operators. The term ``coin'' arose in the Quantum Information community, where a spatially constant localized operation was introduced as the analogue of flipping a coin to decide in which direction the system would move by the next step. The steps are implemented by shifts, but it is crucial to allow the shifts to depend on the internal (``coin''-) state of the system. Therefore we must also allow \textbf{subshifts} of the form \begin{equation}\label{subshift} \Ts^P_k= P\Ts_k+(\idty- P)=\begin{pmatrix} \Ts_k & 0 & 0 & 0 \\ 0 & 1 & 0 & 0 \\ 0 & 0 & \ddots & 0 \\ 0 & 0 & 0 & 1 \end{pmatrix}, \end{equation} where $P$ is a constant projection, which in the second equality has been taken as $\kettbra1$. This special case suffices, because we allow products, and by conjugation with a constant coin we can include also shifts with $P=\kettbra\phi$, or like the first factor in \eqref{tiwalk}. A walk will be called \textbf{decomposable}, if it can be written as a finite product \begin{equation}\label{walkDec} W=C_0S_1C_1S_2\cdots S_nC_n \end{equation} of subshifts $S_i=\Ts^{P_i}_{k_i}$ and coin operations $C_i$. It is not known, whether this comprises all walks with finite jump length, but certainly covers all examples in the literature. \subsection{Walks in a minimally coupled external field}\label{sec:mincoup} Let us begin with some walk in zero field. How can we consider ``the same'' walk in an external field? Roughly speaking, minimal coupling is done by replacing the flat translation system in \eqref{walk0} by a general one, expressing the field in question. That sounds easy enough, but the powers in \eqref{walk0} are now ambiguous, and would depend on the choice of a path from $0$ to $z$. Hence the basic minimal coupling scheme has to be augmented by a scheme of choosing a path for every power appearing in \eqref{walk0}, possibly a different one in different matrix elements of $W$. Changing the path ordering in any one of these places is likely to ruin unitarity. Therefore, a rather subtly connected set of choices is demanded. There is one scheme, however, which immediately takes care of all these choices: One makes the substitution not in the form \eqref{walk0} but in a fixed decomposition \eqref{walkDec} of the walk into subshifts and coins. The coins are not affected, and for the subshifts it amounts to replacing the upper left diagonal block matrix $\Ts_k$ in \eqref{subshift} by another unitary operator. Clearly, this automatically preserves unitarity. Multiplying out the product \eqref{walkDec} one gets back to the form \eqref{walk0}, but now every term comes with a definite operator ordering (compare the two expressions in \eqref{tiwalk}). It is clear that no substitution scheme on the basis of just \eqref{walk0} is likely to handle all these choices coherently. The following definition summarizes the main message of this paragraph. \begin{defi}\label{def:mincoup} Consider a quantum dynamical system determined by the equation of motion \eqref{dynamics}, with a walk operator $W$ decomposed into a product \eqref{walkDec} of localized unitary operators and subshifts with respect to some flat translation system $T^\flat$. Then the {\bf minimal coupling} of the system to an external field described by a translation system $T$ corresponds to replacing throughout $T^\flat_\alpha$ with $T_\alpha$ ($\alpha=0,\ldots,s$) in the equation of motion, and every subshift. \end{defi} The field that is turned on in this way has \textbf{electric components} $P_{0\alpha}$ and \textbf{magnetic components} $P_{\alpha\beta}$, for $\alpha,\beta=1,\ldots s$. Since the $T_\alpha$ are determined by these data up to a choice of gauge, so is the walk, see Sect.~\ref{sec:gaugeEqW} for details. As examples, we briefly discuss two special cases: In the \textbf{purely electric} setting the the spatial plaquette operators $P_{k\ell}$ are all equal to the identity. This allows us to choose a gauge in which $T_k=T^\flat_k$ for $k=1,\ldots,s$. In this gauge $T_0=T^\flat_0 U_0(t,x)$, and the electric field in direction $k$ is determined by $P_{0k}=U_0(t,x)^*U_0(t,x+\hat k)$. Note that in the continuous setting the inhomogeneous Maxwell equations imply that this electric field is time-independent. Since we do not have a discrete equivalent of the inhomogeneous Maxwell equations at our disposal we cannot conclude an analogous statement. In the \textbf{purely magnetic} case where $P_{0k}=\idty$, the homogeneous Maxwell equations imply that the magnetic field is time-independent, which in the continuous setting follows from Faraday's law of induction. More than that, in temporal gauge already the $U_k$ must be time independent by $P_{0\ell}=\idty$. \subsection{Gauge equivalent walks}\label{sec:gaugeEqW} We claimed that gauge equivalent minimal coupling substitutions give equivalent walks. One could express this by saying that the equation of motion is gauge invariant in a natural sense. Let us state this a bit more formally. \begin{lem}\label{lem:gaugeeq} Let $W$ be a walk with given decomposition \eqref{walkDec}, and let $T,T'$ be gauge equivalent translation systems, so that there is a gauge transformation $V$ such that $T_\alpha'=VT_\alpha V^*$. Then the walks $\widetilde W, \widetilde W'$ arising by minimal coupling from $T,T'$, respectively, satisfy $\widetilde W'(t)=V(t)W(t)V(t)^*$ for all $t$. \end{lem} This kind of equivalence between $\widetilde W$ and $\widetilde W'$ may not always be obvious to see, but it has strong consequences. If we choose an initial state $\psi'(0)=V(0)\psi(0)$, and iterate the equation of motion \eqref{dynamics} with $\widetilde W'$ and $T_0'$ to achieve the state $\psi'(t)$, we can equivalently iterate $\widetilde W$ with $T_0$ and apply $V(t)$ at the end. In particular, the position probabilities will be the same and also the the internal degrees of freedom, conditioned on any position $x$. What will differ in general are matrix elements involving different positions. We have seen that one of the directions in a translation system may be chosen to be the same as the flat system. It is natural to do this for the time direction. Then $T_0$ just identifies the Hilbert spaces $\HH(t)$, so we can work in a fixed Hilbert space with time translations given exclusively by the walk operator. We call this a \textbf{temporal gauge}. When the operator $T_0W(t)$ does not depend on time its iteration determines the long-time behaviour of the system. It is only in this case that spectral analysis is a helpful tool for studying the propagation behaviour. A discussion for the case of purely electric fields in terms of spectral properties is given in Example~\ref{sec:ewalks}. \subsection{Uniqueness of minimal coupling} The decomposition \eqref{walkDec} is not unique, so the natural question arises whether the result of minimal coupling depends on this choice. The answer is yes, and this is not an artefact of the discrete unitary setting. In fact it arises in almost the same way in the continuum setting. Suppose we have some Hamiltonian $H$ given as a polynomial in the position and momentum operators. Then replacing every momentum operator $P_\mu$ by $P_\mu-A_\mu(t,Q)$ as in \eqref{kinmom} gives another Hamiltonian $\widetilde H$, interpreted as ``the same'' Hamiltonian placed in an external field described by the vector potential $A_\mu$. The reason for repeating this description of the minimal coupling procedure as a straightforward substitution is to point out a hidden assumption: The Hamiltonian must be presented as a polynomial and, in fact, as a non-commutative polynomial, in which monomials with different operator orderings are considered a priori as different. Without this preparatory step the substitution \eqref{kinmom} is just not defined\footnote{Polynomials might be a bit too narrow here if one thinks of functions such as $p\mapsto(p^2+m^2)^{1/2}$. So in general one would want to include the full non-commutative functional calculus (see, e.g., the Appendix of \cite{MF}). For bounded arguments this is covered by a Weiertra{\ss}-type approximation theorem, so polynomials do tell the essential part of the story. For unbounded arguments, as in the present case, the practice in physics is to use the scheme as a formal device, and to look at mathematical subtleties only for the cases one is really interested in, that is, usually later or never. One can easily cook up examples, where minimal substitution on a free particle leads to a Hamiltonian that is not essentially self-adjoint, so dubious as a generator of dynamics}. Hence the substituted Hamiltonian $\widetilde H$ does not just depend on the {\it operator} $H$. Consider, for example, the Hamiltonians \begin{equation}\label{p1p2} H_1=P_1P_2=P_2P_1=H_2. \end{equation} The equality in the middle holds, because the ungauged momenta commute. After minimal coupling we get \begin{equation}\label{p1p2coup} \widetilde H_1=\widetilde P_1\widetilde P_2\neq\widetilde P_2\widetilde P_1=\widetilde H_2. \end{equation} Now $\widetilde H_1-\widetilde H_2=F_{12}$ is the field, which will be non-zero in any non-trivial case. In the given context it seems possible that the two operators are equal up to a gauge transformation. But considering \begin{eqnarray} e^{i\chi(Q)}\widetilde H_1e^{-i\chi(Q)}-\widetilde H_2&=&\\ &&\strut\mkern-160mu= \widetilde H_1-\widetilde H_2-(\partial_1\chi)\magtcont{2}-\magtcont{1}(\partial_2\chi)+(\partial_1\chi)(\partial_2\chi), \nonumber \end{eqnarray} we see that the left hand side can only vanish, when the coefficients of the differential operator on the right are zero. This still leaves us with $F_{12}=0$, so a gauge transformation does not help to achieve equality. In other words, the minimal coupling procedure is not as straightforward as it is often presented in Quantum 101. It is the same ambiguity that we encountered for unitary operators. Here, too, the difference cannot be covered by a gauge transformation. We can see this already for a minimal extension of the above example of pure shifts: consider decomposed walks on $\ell_2({\mathbb Z}}\def\Nl{{\mathbb N}^2)\otimes\Cx^2$ defined as \begin{equation} W_1=S_1S_2=S_2S_1=W_2, \end{equation} where $S_i=P\Tsf_i+(1-P)\Tsff*_i$ and $P$ is a constant projection onto some one-dimensional subspace of $\Cx^2$. As in the Hamiltonian example above, the equality in the middle holds because the flat translation operators $\Tsf_i$ commute. After discrete minimal coupling $\Tsf_i\mapsto\Ts_i$ we get \begin{equation} \widetilde W_1=\begin{pmatrix} \Ts_1\Ts_2 & \\ & \Ts_1^*\Ts_2^* \end{pmatrix} \neq \begin{pmatrix} \Ts_2\Ts_1 & \\ & \Ts_2^*\Ts_1^* \end{pmatrix} =\widetilde W_2. \end{equation} Finding a gauge transformation $V$ which maps $\widetilde W_2$ to $\widetilde W_1$ amounts to finding solutions to \begin{equation} V^*\widetilde W_2^*V\widetilde W_1\phi_x=\idty. \end{equation} This leads to the two conditions \begin{align} V(x+\hat1+\hat2) &= P_{12}^*(x)V(x), \\ V(x+\hat1+\hat2) &= P_{12}(x)V(x), \end{align} which can be satisfied iff $P_{12}(x)=\pm\idty$ for all $x$. Thus, for arbitrary fields the walks $\widetilde W_1$ and $\widetilde W_2$ are not gauge equivalent, and minimal coupling always involves a choice of operator ordering. \subsection{Discussion of minimal coupling} The result of the minimal coupling is another dynamical system of the same kind. Indeed, if we have written $T$ as the flat translation system times $U_\alpha(x)$ as in \eqref{UaxG} a subshift and its substituted version differ by a unitary factor, which we can make part of an adjacent coin, so we are back to a decomposition with respect to a flat translation system. This shows that there is no absolute distinction between walks without or with field: The procedure of adding a field is relative. It can be iterated, but the result of several substitutions can be read off from what happens at the level of translation systems, and can just as well be done in a single step. This ``addition of fields'' is commutative in an abelian gauge theory. The only reason why we have restricted to $U(1)$-gauge fields is the gauge equivalence expressed in Lemma~\ref{lem:gaugeeq}. The argument for this requirement depends crucially on the coins commuting with the gauge transformations, which is automatic for a $U(1)$-theory. There seem to be three possibilities to deal with this: One could either decide to live with the failure of that property, or (preferably) demand that the coins commute with $\ggroup$, or include a transformation of the coins in the definition of minimal coupling. In the spirit of this paper, the decision should be inspired by a study of non-abelian continuum theories, but that would be beyond the scope of our paper. \section{Minimal coupling principle recalled}\label{sec:recap} Before delving into the realm of quantum walks, let us briefly review the minimal coupling principle introducing electromagnetic fields to systems continuous in time and space. Consider a $s$-dimensional system with position and momentum operators $Q_k,P_k,\:k=1,\dots s$. Then, the dynamics is implemented by the Schr\"{o}dinger equation $i\partial_t\psi_t=H\psi_t$ where, for simplicity, we take the Hamiltonian $H=h(P_1,\dots,P_s)$ to be a function of momenta alone. Yet, this equation of motion by itself is not compatible with local gauge transformations $\psi_t\mapsto\psi_t':=e^{i\chi_t(Q)}\psi_t$. To make up for this omission, gauge potentials are introduced via the \emph{minimal coupling principle}: in the Schr\"{o}dinger equation one substitutes the \emph{canonical} by so-called \emph{kinematical} momentum operators, i.e. \begin{align} P_\mu\mapsto \magtcont\mu&:=P_\mu-A_\mu(t,Q), \label{kinmom} \end{align} where $P_0=i\partial_t$, and $A_0$ as well as the $A_k$ are functions on ${\mathbb R}}\def\Cx{{\mathbb C}\times{\mathbb R}}\def\Cx{{\mathbb C}^s$. These substitutions guarantee that gauged solutions to the Schr\"{o}dinger equation are again solutions, but for the Hamiltonian with gauge transformed $A_\mu$, i.e. \begin{equation} \magtcont0\psi_t=\widetilde H\psi_t\quad\Rightarrow\quad \magtcont0'\psi_t'=\widetilde H'\psi_t', \end{equation} where $\widetilde H=h(\magtcont1,\dots,\magtcont s)$ and the gauge potentials transform like $A_0\mapsto A_0'=A_0-\partial_0\chi$ and $A_k\mapsto A_k'=A_k+\partial_k\chi$. Unlike the canonical momentum operators, the $\magtcont\mu$ clearly do not commute anymore. Instead, their commutators \begin{equation}\label{comrelcont} [\magtcont\mu,\magtcont\nu]=i(\partial_\mu A_\nu-\partial_\nu A_\mu)=iF_{\mu\nu} \end{equation} equates to the electromagnetic field-strength tensor encoding electric and magnetic fields. As one quickly verifies, these fields are invariant under the gauge transformation of the $A_\mu$. Conversely, for any field $F_{\mu\nu}$ there exists functions $A_\mu,A_\nu$ such that \eqref{comrelcont} holds. This important result follows directly from the Poincar\'e lemma, see Appendix \ref{app:DisCont}, and the homogeneous Maxwell equations \begin{equation} \partial_{[\alpha}F_{\mu\nu]}=0, \end{equation} where $[\cdots]$ denotes antisymmetrization of indices. A discrete version of the Poincar\'e Lemma will allow us to prove an analogous statement on the uniqueness of discrete electromagnetic fields below. \section{Lattice and gauge}\label{sec:gauge} In this section we set up the basics of gauge theory on a lattice. We follow roughly the well-known continuum theory, and to allow these intuitions to be used more easily we provide a translation table (Table~\ref{tab:concepts}) of basic concepts. The same table applies, when a lattice field is derived from a continuum electromagnetic field, for example in the tight binding approximation (see Sect.~\ref{sec:tight}). But the discrete concepts do not require such a continuum background. Indeed, a simulated electromagnetic field will rarely be derived in this way, and the implementation of electromagnetic systems and the checking of their properties has to be carried out completely in the discrete setting. \begin{table} \centering \begin{tabular}{|c|c|c|} physical concept&continuous GT&discrete GT\\\hline position space&base manifold& ${\mathbb Z}}\def\Nl{{\mathbb N}^s$\\ &vector bundle &$\{\HH_x\}_{x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s}$ \\ pure quantum state&bundle section&$\psi\in\bigoplus_x\HH_x$\\ vector potential&connection & translation system\\ field&curvature &\ plaquette operators \\ \end{tabular} \caption{Basic concepts of continuum gauge theory (GT) and their lattice analogs}\label{tab:concepts} \end{table} \subsection{Translation systems and gauge transformations}\label{sec:tsys} We begin by describing the kinematical setup of lattice gauge systems, which will be the background for the dynamical evolution by quantum walks. As is well known, gauge theories live in vector bundles, and one can also say that we set up the vector bundle structures needed for discrete electromagnetism. This will be very simple, since the base manifold of the bundle is the lattice ${\mathbb Z}}\def\Nl{{\mathbb N}^s$, so there are no differentiability conditions, and we can work with global bundle charts. The vector space at each point is taken as a Hilbert space $\HH_x$ of the same finite dimension $d$. One can think of each $\HH_x$ as the same fixed Hilbert space $\Cx^d$. But no particular isomorphism is fixed from the outset. Even with all spaces equal, the distinction between different $\HH_x$ is useful as it helps with the book-keeping and indicates where a vector is located. The basic object we study is the discrete analogue of a connection, and allows us to ``transport'' vectors along lattice directions. When $\alpha\in\{1,\ldots,s\}$ labels the positive lattice directions, we denote by $\hat\alpha$ the corresponding unit vector. Then a \textbf{translation system} is denoted by $T_1,\ldots,T_s$, where each $T_\alpha$ is a family of unitary operators \begin{equation}\label{tsys} T_\alpha:\HH_x\to\HH_{x+\hat\alpha}, \qquad x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s. \end{equation} At this point we could include the parameter $x$ in the notation of $T_\alpha$, e.g., write the above operator as $T_\alpha(x)$, but it turns out to be less cumbersome to keep track of the spaces $\HH_x$, in which the argument of $T_\alpha$ lies, and then pick the appropriate unitary operator. Just choosing a different basis in each $\HH_x$ changes a translation system only in a trivial way, and we capture this in the following definition. By a \textbf{localized operator} we mean a collection of operators $A(x)$ with $A(x)$ acting in $\HH_x$. For a localized \emph{unitary} operator $U$, every $U(x)$ is unitary. These are the local basis changes, possibly depending on $x$. For the unitary equivalence in the following definition it is convenient to allow the spaces $\HH_x$ resp.\ $\HH'_x$ to be different as well, so $U$ becomes a family of unitary operators $U(x):\HH_x\to\HH_x'$. \begin{defi}\label{def:isotranslation} Two translation systems $T,T'$ on respective families of Hilbert spaces $\{\HH_x\}_{x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s}$ and $\{\HH'_x\}_{x\in{\mathbb Z}}\def\Nl{{\mathbb N}^s}$ are called \textbf{equivalent} if there is a localized unitary operator $U$ such that $UT_\alpha U^*=T'_\alpha$. \end{defi} Note that in this operator product each of the factors is really a family of unitary operators, acting in an $x$-dependent way. Thus \begin{equation}\label{UTU} (UT_\alpha U^*)\phi_x'=U(x+\hat\alpha)T_\alpha U(x)^*\phi_x'. \end{equation} A typical way to detect non-equivalence is to transport a vector around a closed path, which may lead to a different vector. To build such paths we also need steps in the $-\hat\alpha$ direction. In the shorthand notation for paths, where we just keep track of the directions, we label these with $\{-1,\ldots,-s\}$. The corresponding unitary step operator is then $T_{-\alpha}=T_\alpha^*$. A path on the lattice is defined by a sequence $\gamma=(\gamma_1,\ldots\gamma_\ell)$, with $\gamma_i\in\{\pm1,\ldots,\pm s\}$. Naturally we set \begin{equation} T_\gamma=T_{\gamma_{\ell}}\cdots T_{\gamma_1}. \end{equation} Closed paths, or ``loops'', are those whose net transport $\hat\gamma=\sum_i\hat{\gamma_i}$ vanishes. For such operators $T_\gamma:\HH_x\to\HH_x$ for every $x$, i.e., $T_\gamma$ is a localized unitary operator. The loop operators define the \textbf{holonomy group} at $x$ as \begin{equation}\label{holo} {\hol}_x=\{T_\gamma(x)| \gamma\ \text{ a loop}\}. \end{equation} We call a translation system \textbf{flat} if the holonomy group consists everywhere only of the identity. That is, the transport of a vector $\phi_x\in\HH_x$ to $\HH_y$ by an operator $T_\gamma$ with $x+\hat\gamma=y$ is independent of the path $\gamma$. Clearly, only a flat translation systems allows a meaningful interpretation of ``$\phi_x\in\HH_x$ and $\psi_y\in\HH_y$ are equal''. We can use this to rewrite any given translation system in a simplified but equivalent form. \begin{lem}\label{lem:flat} For every translation system $T$ we can find a flat system $T^\flat$ such that \begin{equation}\label{Uax} T_\alpha\phi_x=T^\flat_\alpha U_\alpha(x)\phi_x \end{equation} with a unitary $U_\alpha(x)\in\hol_x$. Moreover, there is an equivalent translation system $T'$, where ${\hol'_x}$ is the same for all $x$ with respect to $T^\flat$. \end{lem} \begin{proof} The key element to chose here is, for every $x$, a path $\gamma(x)$ from a reference point, say $0$, to $x$, such that $T_{\gamma(x)}:\HH_0\to\HH_x$. The flat translation system may now be defined by \begin{equation}\label{tflateq} T^\flat_\alpha \phi_x= T_{\gamma(x+\hat\alpha)}T_{\gamma(x)}^*\phi_x. \end{equation} This is flat, because for any path $T^\flat_\gamma$, during which some sequence of lattice points is traversed, it corresponds to going back to $0$ in every step, and then forward to the next point. These jumps cancel from step to step. With this we can write \begin{align} T_\alpha\phi_x=T_{\gamma(x+\alpha)}T_{\gamma(x)}^*T_{\gamma(x)}T_{\gamma(x+\alpha)}^*T_{\alpha}\phi_x, \end{align} which evaluates to \eqref{Uax}, with $U_\alpha(x)=T_{\gamma(x)}T_{\gamma(x+\alpha)}^*T_{\alpha}\in\hol_x$ (compare Fig.~\ref{fig:flatloop}). To prove the equivalence of all $\hol_x$, we use the standard paths $\gamma(x)$ to identity the spaces $\HH_x$ with each other. The unitary equivalence operator will be $V(x):\HH_x\to\HH_x'=\HH_0$, defined as \begin{equation} V(x)\phi_x=T_{\gamma(x)}^*\phi_x. \end{equation} Given now an element of $\hol_x$, i.e.\ a unitary $T_\sigma$ with a closed loop $\sigma$, starting at $x$, it transforms to \begin{equation} T_\sigma'\phi_x'=VT_\sigma'V^*\phi_x'=T_{\gamma(x)}^*T_{\sigma}T_{\gamma(x)}, \end{equation} which is describes a loop, starting at $x=0$. Hence, $\hol'_x=\hol_0$ for all $x$. \end{proof} \begin{figure} \input{flattranslation} \caption{\label{fig:flatloop} Construction of the flat translation system $T^\flat$ in the proof of \ref{lem:flat}, which allows to express a given translation system $T$ by multiplication of an element of the holonomy group of $T$ (blue) followed by $T^\flat$ (red), see \eqref{Uax}.} \end{figure} Note that after the identification $\HH_x'\equiv\HH_0$ the flat translation system \eqref{tflateq} not only has trivial $\hol_x$, but also acts as the identity for all $\phi_x'$ \begin{equation} (T^\flat_\alpha)'\phi'_x=\phi'_{x+\alpha}. \end{equation} This lemma underlines the importance of the holonomy group. Typically one actually constrains this group to be a subgroup of a certain group $\ggroup\subset U(d)$, the ``gauge group'', and fixes also the form \eqref{Uax} with unitaries from $\ggroup$. This defines a family of translation systems, for many of which $\hol_x$ will be dense in $\ggroup$. In this sense a single translation system and its holonomy group may determine the whole gauge family. The resulting restricted kind of translation systems is described in the next section, before we further specialize to electromagnetic fields, for which $\hol_x$ consists of phases only. \subsection{Gauge transformations}\label{sec:gaugeTrafo} Following the structure found in Lemma~\ref{lem:flat} we now fix a flat translation system $T^\flat$, and hence an a priori identification of the spaces $\HH_x\equiv\Cx^d$, which then only differ by their location index. Moreover, we fix a \textbf{gauge group} $\ggroup$, as a subgroup of the unitary group of $\Cx^d$. Then a \textbf{$\ggroup$-translation system} is one of the form \begin{equation}\label{UaxG} T_\alpha\phi_x=T^\flat_\alpha U_\alpha(x)\phi_x,\quad \forall x,\alpha:\: U_\alpha(x)\in\ggroup. \end{equation} A \textbf{gauge transformation} is a localized unitary $V$ with $V(x)\in\ggroup$, and two translation systems are called \textbf{gauge equivalent} if the operator $U$ in Def~\ref{def:isotranslation} can be chosen as a gauge transformation. The structure of a translation system is now encoded in the operators $U_\alpha(x)$. There is no constraint on these operators. By multiplying steps we get, for every path $\gamma$, operators $U_\gamma(x)\in\ggroup$ so that \begin{eqnarray} T_\gamma\phi_x &=&T^\flat_\gamma U_\gamma(x)\phi_x,\quad \phi_x\in\HH_x \\ U_{\gamma_1\gamma_2}(x) &=& U_{\gamma_1}(x+\hat\gamma_2)U_{\gamma_2}(x) \end{eqnarray} In particular, $\hol_x\subset\ggroup$ for all $x$. This is always a countable, hence proper subgroup of $U(1)$, or even a discrete subgroup (see Sect.~\ref{sec:ratfields}). Lemma~\ref{lem:flat} suggests a choice of gauge by choosing a suitable set of standard paths $\gamma(x)$ connecting $0$ with any given point $x$. A frequently useful choice is the \textbf{path-ordered gauge} where one first does all steps in the positive or negative $1$-direction, then all along $2$ and so on. Thus for $x=(x_1,\ldots,x_s)$ the standard path $\gamma(x)$ leads to \begin{equation}\label{pathorder} T_{\gamma(x)}:=T_s^{x_s}\cdots T_2^{x_2}T_1^{x_1}. \end{equation} With the gauge transformation as in the proof of Lemma~\ref{lem:flat} translations along standard paths are used for the identification of neighbouring $\HH_x$, so no additional unitaries are picked up. In particular, the translations along $T_1$ are flat. For $T_2$ we get unitaries $U_2(x)$ depending only on $x_1$, and so on for the further directions. \begin{figure} \input{pathorderedgauge} \caption{\label{fig:pathorder}The path-ordered gauge is a particular example for a maximal tree gauge \cite{creutz1977gauge}, for which no phases are picked up along the black links. In this gauge, the phases picked up along the dashed lines corresponds to the sum of the plaquette phases enclosed by the loop $0\to x\to x+\hat\alpha\to0$ where $0\to x$ and $x+\alpha\to0$ are standard paths.} \end{figure} Applying a gauge transformation $V$ the translation system \eqref{UaxG} is transformed to $T'_\alpha=VT_\alpha V^*$, characterized by the operators \begin{equation}\label{Ugauged} U'_\alpha(x)=V(x+\hat\alpha)U_\alpha(x)V^*(x). \end{equation} In particular, for a closed path we get \begin{equation}\label{Ugagauged} U'_\gamma(x)=V(x)U_\gamma(x)V^*(x). \end{equation} In an abelian gauge theory, i.e., with $\ggroup$ abelian, $V(x)$ can be commuted through, so the $U_\gamma(x)$ do not change under gauge transformations. Even in non-abelian gauge theories we can get a gauge invariant quantity out of this, namely $\mathop{\rm tr}\nolimits U_\gamma(x)$. Note that in either case the invariance covers also the choice of the initial point: For all points on a closed loop on the lattice is the same (when $\gamma$, as the list of directions is also shifted accordingly). Non-trivial transport around a closed path is the hallmark of curvature. In an abelian gauge theory this quantity simply adds up over surfaces. If we have a large surface $\mathcal S$ divided into two pieces $\mathcal S_1$, $\mathcal S_2$ by a path, we can turn the loop around $S$ into the sum of the loops around $\mathcal S_1$ and $\mathcal S_2$. The dividing path is traversed twice, but in opposite direction, and since all $U_\alpha$ commute, these contributions cancel. General loops can therefore be reduced to elementary ones. In the continuum they are taken to be infinitesimal, given the curvature $2$-form. In the discrete case the smallest we can do is individual plaquettes \begin{equation}\label{eq:plaquetteoperator} P_{\alpha\beta}=T_\alpha^*T_\beta^*T_\alpha T_\beta. \end{equation} Note that these operators still depend on the starting point on the lattice. Explicitly, $P_{\alpha\beta}\phi_x=P_{\alpha\beta}(x)\phi_x$, with \begin{equation}\label{plaqx} P_{\alpha\beta}(x)= U_\alpha(x)^*U_\beta(x+\hat\alpha)^*U_\alpha(x+\hat\beta)U_\beta(x), \end{equation} where we have used the identity $U_{-\alpha}(x)=U_\alpha(x-\hat\alpha)^*$. In general, equality of the plaquette traces is not sufficient for $\ggroup$-translation systems to be gauge equivalent. However, this will be true in the case of main interest for us, to which we now turn. \subsection{U(1)-gauge theory}\label{sec:U1} We now specialize to the case relevant for electromagnetism, that is, the gauge group $\ggroup=U(1)$, so that $U_\alpha(x)$ for all $x,\alpha$ corresponds to multiplication by suitable phases. The structure of $U(1)$-translation systems is completely determined by these phases, and hence independent of $d$. Likewise, the plaquette operators are just phases, so that $P_{\alpha\beta}(x)\in U(1)$. By definition these are multiplicatively antisymmetric, i.e, $P_{\alpha\beta}(x)P_{\beta\alpha}(x)=1$ for all $x$. The main reason why we can say much more in this case is that there is a cohomology theory for these phase systems: \begin{thm}\label{thm:uniqueness}\strut\hfil \begin{itemize} \item[(1)] Two $U(1)$-translation systems $T,T'$ are gauge equivalent iff their plaquette phases are everywhere equal, i.e., $P_{\alpha\beta}(x)=P'_{\alpha\beta}(x)$ for all $x$. \item[(2)] A system of antisymmetric plaquette phases can arise from some $U(1)$-translation systems if and only iff \begin{equation}\label{eq:disc_maxwell} \prod_{{\rm cyc}(\alpha\beta\mu)} P_{\alpha\beta}(x+\hat\mu)P_{\beta\alpha}(x) =1, \end{equation} where the product is over all cyclic permutations of the indices $(\alpha,\beta,\mu)$. \end{itemize} \end{thm} In the continuum the first equation is equivalent to the statement that two vector potentials give the same field iff they differ by a gradient, and the second corresponds to the homogeneous Maxwell equations. To see these analogies, it helps to write the abelian group additively, i.e., to parameterize phases by the phase angle in ${\mathbb R}}\def\Cx{{\mathbb C}/(2\pi{\mathbb Z}}\def\Nl{{\mathbb N})$. That is, for the localized unitaries implementing gauge transformations we write $V(x)=\exp (i\chi(x))$ with $\chi:{\mathbb Z}}\def\Nl{{\mathbb N}^s\to{\mathbb R}}\def\Cx{{\mathbb C}/(2\pi{\mathbb Z}}\def\Nl{{\mathbb N})$. Similarly, translation systems are encoded by $U_\alpha(x)=\exp (iA_\alpha(x))$ for a family of functions $A_\alpha:{\mathbb Z}}\def\Nl{{\mathbb N}^s\to{\mathbb R}}\def\Cx{{\mathbb C}/(2\pi{\mathbb Z}}\def\Nl{{\mathbb N})$, and plaquette phases are given as $P_{\alpha\beta}(x)=\exp(iF_{\alpha\beta}(x))$. Denoting by $d_\alpha$ the discrete derivative in direction $\alpha$, i.e., \begin{equation}\label{latderivative} (d_\alpha f)(x)=f(x+\hat\alpha)-f(x), \end{equation} \eqref{plaqx} translates to \begin{equation}\label{plaqxf} F_{\alpha\beta}(x)=d_\alpha A_\beta(x)-d_\beta A_\alpha(x), \end{equation} the discrete analogue of the electromagnetic field-strength tensor \eqref{comrelcont}. \begin{proof} To prove Theorem \ref{thm:uniqueness} we set up a discrete differential calculus along the lines of \cite{hydon2004variational,mansfield2008difference}, see Appendix \ref{app:DisCont} for details. In this parlance of discrete differential calculus the $A_\alpha:{\mathbb Z}}\def\Nl{{\mathbb N}^s\to{\mathbb R}}\def\Cx{{\mathbb C}/(2\pi{\mathbb Z}}\def\Nl{{\mathbb N})$ implementing a translation system define a discrete $1$-form \begin{equation} A=\sum_\alpha A_\alpha\dd x^\alpha. \end{equation} Similarly, $F_{\alpha\beta}:{\mathbb Z}}\def\Nl{{\mathbb N}^s\to{\mathbb R}}\def\Cx{{\mathbb C}/(2\pi{\mathbb Z}}\def\Nl{{\mathbb N})$ defines a discrete $2$-form \begin{equation} F=\sum_{\alpha<\beta} F_{\alpha\beta}\dd x^\alpha\wedge\dd x^\beta. \end{equation} A discrete exterior derivative is defined in \eqref{eq:ddisc}, and we call discrete forms which are given as $\omega=d\eta$ \emph{exact} and such for which $d\omega=0$ \emph{closed}. Clearly, $d$ satisfies $d^2=0$, i.e. every exact form is closed. Then, the first part of the theorem follows from \begin{equation} F=dA, \end{equation} which is equivalent to \eqref{plaqxf}. That every $U(1)$-translation system satisfies \eqref{eq:disc_maxwell}, follows from direct calculation, and is equivalent to \begin{equation} dF=0. \end{equation} The converse statement, that every set of antisymmetric plaquette phases satisfying \eqref{eq:disc_maxwell} arises from a $U(1)$-translation system is a special instance of the general statement ``every closed form is exact''. This is the content of the discrete Poincar\'e lemma which we discuss in Appendix \ref{app:DisCont}. \end{proof} \begin{figure}[t] \input{plaquette3D} \caption{\label{fig:plaquette3D}A visualization of the discrete Maxwell equations \eqref{eq:disc_maxwell}. Each of the links of the boundary of this cube appear twice, once in positive and once in negative direction, and the corresponding contributions cancel.} \end{figure} \subsection{Continuous to discrete}\label{sec:tight} The standard application of lattice gauge theory in solid state systems is to describe electrons moving under the combined influence of the periodic potential provided by some positively charged ions of a crystal lattice, and an external electromagnetic field. In an approximation of non-interacting electrons the system without external fields is essentially a one-electron Hamiltonian system in a periodic potential. It can be diagonalized jointly with the lattice translations and thus analyzed as a function of quasi-momentum (the Brillouin zone). Since the kinetic energy is unbounded, this gives infinitely many bands, and restricting to the lowest bands (or selecting a small set of electron wave functions per atom) one gets the tight binding model, in which the electrons are described by a discrete lattice position plus some internal degree of freedom. Let us now turn on an external electromagnetic field, which is given in terms of $A_\mu(x)$, $\mu=0,\ldots,s$, $x\in{\mathbb R}}\def\Cx{{\mathbb C}^{s+1}$. How does this lead to a ``lattice gauge field'' in the tight binding approximation? This is easy enough for electric potentials in a suitable gauge, which we can apply as multiplication operators just as in the continuous case. The only thing that changes is that we now have to evaluate $A_0$ only at the lattice points. In other words, a scalar potential $A_0$ is discretized as multiplication by $\exp(iA_0(x))$ on $\ell^2({\mathbb Z}}\def\Nl{{\mathbb N}^s)$. However, for vector potentials this method is bad, because it does not reflect their meaning as a connection, i.e., as a structure that encodes a notion of parallel transport. When $\partial_\alpha-iA_\alpha$ is the generator of translations in the continuum, it is natural to take its lattice analog as the phase acquired in the continuum theory by transporting a vector from $x$ to $x+\hat\alpha$. That is \begin{equation}\label{Peierls} U_\alpha(x)=\exp i\int_0^1 dt\ A_\alpha(x+t\hat\alpha), \end{equation} and is called the \textbf{Peierls phase} \cite{Peierls}. Clearly, this differs from $\exp( iA_\alpha(x))$, the naive expectation from the case of electric fields. When $A_\alpha=\partial_\alpha\chi$, \eqref{Peierls} amounts to $U_\alpha(x)=\exp \bigl(i(\chi(x+\hat\alpha)-\chi(x))\bigr)$, i.e., the lattice gradient. So this kind of discretization is compatible with the differential calculus. For $2$-forms, the interpretation of the field as curvature $F_{\alpha\beta}$ suggests to take integrals over plaquettes, and again this makes the definition compatible with differentiation. In general, a $p$-form is an antisymmetric tensor with $p$ indices. Its discrete version will be an integral over a $p$-dimensional face of the lattice, and one might think of it as a quantity associated with a plaquette: If $\alpha,\beta,\ldots$ are the indices of the electromagnetic field-strength tensor, the plaquette is labelled by a lattice point, from which it is spanned by the vectors in the positive $\hat\alpha,\hat\beta,\hat\gamma,\ldots$ directions. Note that this matches the definition \eqref{latderivative} of the lattice derivatives $d_\alpha$ as unilateral differences in the positive direction. Appendix \ref{app:DisCont} shows that the discretization thus intertwines exterior differentiation with the lattice exterior derivative. There is even a similar map in the opposite direction. However, this cannot be an inverse, because the discretization map sketched here is clearly many-to one. For example, the discretization of a vector potential which is nonzero only on the interior of plaquettes is simply zero.
\section{Introduction} Obstructive sleep apnea (OSA) is a common sleep disorder in which complete or partial upper airway obstruction, caused by pharyngeal collapse during sleep \cite{OSA:syndrome}. There are two types of events which can occur during the airway obstruction including hypopnea which is when the inspiratory airflow is reduced, and apnea when it is completely absent for at least ten seconds. This sleep disorder causes loud snoring or choking, frequent awakenings, disrupted sleep, and excessive daytime sleepiness. Furthermore, it is also associated with the incidence and morbidity of hypertension, coronary heart disease, arrhythmia, heart failure, and stroke \cite{OSA:conseq}. The gold standard of sleep-disordered diagnosis including conditions such as OSA is polysomnography (PSG). It is used to determine the frequency and severity of normal respiratory disorder events per hour and reports as the Apnea-Hypopnea Index (AHI) which can be used to classify the OSA as normal (AHI\textless5), mild (AHI is in 5--14), moderate (AHI is in 15--30), and severe (AHI\textgreater30), respectively \cite{OSA:class}. However, this method is a form of clinical practice which has to be done overnight in a laboratory or hospital \cite{OSA:treatment} using numerous sensors to acquire the necessary data, such as electroencephalogram (EEG), electrooculogram (EOG), chin electromyography (EMG), leg movement, airflow, cannula flow, respiratory effort, oximetry, body position, electrocardiogram (ECG), and so forth \cite{PSG}. One study shows that this sleep disorder affects approximately 9-24\% of the general population, and 90\% remain undiagnosed \cite{OSA:undiagnosed} because of the limited number of diagnostic measurements. Since it has to be done in a sleep lab with clinicians, the diagnosis results may be distorted by the lab environment criteria as well as the intrusive and inconvenient measurement sensors which are attached to the patient's body, such as EEG, EOG, chin EMG on the patient's head, and oximetry sensor on the patient's finger. To solve the above issues, there are several studies which tried to diagnose OSA by other methods. \citeauthor{lit:easy_measurements} show that another condition also provides information for the prediction of OSA severity \cite{lit:easy_measurements}. They consequently proposed a new AHI prediction method using only easily available measurements for the estimation of OSA severity level including three BP-related variables, age, BMI, Epworth Sleepiness Scale (a questionnaire), neck circumference, and waistline in order to distinguish the OSA level of normal-mild from moderate-severe with the threshold equal to 15. The results showed that there is a high correlation between the predicted and actual AHI values. However, the accuracy is not reliable enough since the questionnaire results, which are subjective measures, are included in this method. Another solution is trying to detect some OSA-related events to identify the severity of OSA, for example, \citeauthor{lit:snoring} reducing the number of measurement devices attached to the patient's body by placing only the wireless tracheal sensor on the patient's neck and detecting snoring from breathing. Snoring is a significant symptom or sign of OSA \cite{lit:snoring}. Moreover, \citeauthor{lit:bodyposture} also proposed to detect body postures on beds from OSA patients by using 12 capacitively coupled electrodes, and also a conductive textile sheet attached to the patient's chest to acquire electrocardiogram (ECG) signals. Patients with severe OSA have a higher risk of developing cardiovascular diseases, and the apnea occurs more frequently and severely in a supine position than in others \cite{lit:bodyposture}. Nevertheless, most studies still required some specific tools and attached them to several points on the patient's body, which not only uncomfortable for the patient but also leads to some limitations when the patient moves during sleep. Using wearable devices which provide some necessary bio-sensors for sleep disorder diagnosis such as ECG, EOG, EMG, Heart Rate (HR), Skin Potential and Pulse Oximeter for physiological measurements is obviously a better way because these devices are developed based on the key of unobtrusiveness \cite{lit:wearable}. Moreover, they are also easy to use, easy to find, and cheaper than clinical measurements. One of the most accurate physiological signals provided by various wearable devices and used in several OSA studies are from the ECG \cite{lit:wearableECG1}. \section{Related Works} \citeauthor{lit:mhealth} focused on individual differences among all subjects' ECGs and performed a set of IF-THEN rules by a set of parameters related to HRV for each person in order to describe the occurrence of apnea events \cite{lit:mhealth}. Several studies found that ECGs from different people have some identical characteristics and show that the use of only ECG sensors can achieve good accuracy in the detection of sleep apnea. Since various studies show that patients with OSA have slow-wave sleep (SWS) or N3 sleep stage or less than 25\% of their total sleep, \citeauthor{lit:SWS} developed an automatic SWS detection algorithm based on R-R Interval information in both the time domain and frequency domain \cite{lit:SWS}. In another methodology, there are many studies which have used minute-by-minute ECG segments to classify apnea or hypopnea events from normal ECG data \cite{lit:RQA,lit:singlelead,lit:spectrum,lit:hermite,lit:gabor}. In 2014, \citeauthor{lit:RQA} proposed an apnea detection method by using recurrence plots (RPs) and subsequent recurrence quantification analysis (RQA) of HRV data which provides the statistical characterization of complex HR regulations. They proposed a combination of classifiers including Support Vector Machine (SVM) and Neural Network (NN) with a soft decision fusion rule for performance improvement \cite{lit:RQA}. In 2015, \citeauthor{lit:singlelead} derived all features from the RR Intervals and ECG derived respiration (EDR) signals to be inputs of classifiers including linear discriminant analysis (LDA), SVM, and least-squares support vector machines (LS-SVM). \cite{lit:singlelead}. \citeauthor{lit:spectrum} also showed that it is possible to acquire information regarding non-stationary signals and their deviation from linearity and Gaussianity using a spectrum and higher order spectrum (HOS) \cite{lit:spectrum}. They consequently developed an algorithm for OSA detection using novel features based on bispectral analysis including a spectrum and HOS of HRV and EDR signals. Afterwards, training with LS-SVM allowed discrimination between normal and apnea episodes. In 2016, \citeauthor{lit:hermite} extracted features based on RR time series from ECG segments along with energy in the error of the QRS approximation and coefficients from the Hermite decomposition. Subsequently, they performed a segment classification between the apnea and normal segments with four classifiers including K-Nearest Neighbor (KNN), Multilayer Perceptron Neural Network (MPNN), SVM, and LS-SVM \cite{lit:hermite}. In 2018, \cite{lit:gabor} decomposed one-minute duration (fixed-length) ECG signals obtained from ECG recordings into band-limited signals using a bank of Gabor filters. After that, they computed phase descriptors (PDs) and extracted histogram features. Finally, they classified apnea events using an LS-SVM classifier with radial basis function (RBF) kernel \cite{lit:gabor}. However, the apnea detection which extracted features from fixed-length segments of ECG signals had some limitations about detailed insights such as the duration of the events because apnea or hypopnea events can occur for less than one minute, or for longer than one minute. Instead of fixed-length segmentation, \citeauthor{lit:autoscreen} segmented ECG signals by the iterated cumulative sums of squares (ICSS) algorithm with RR Intervals. They performed feature extractions in the frequency domain and calculated the severity index of each patient. Then, to this value was added some critical subject admission information such as age, body mass index, and gender into an SVM classifier to classify OSA and non-OSA subjects \cite{lit:autoscreen}. Moreover, \citeauthor{lit:HMM} also proposed an OSA detection approach which considers temporal dependence within segmented signals using the Discriminative Hidden Markov Model (HMM). The results showed that the accuracies were improved while classifying OSA events with the use of conventional classifiers with the Discriminative HMM. Nevertheless, the accuracies of all aforementioned works can be affected by the RR Interval detection method because they all used this as a major feature extraction. Furthermore, all of them sought only to detect the apnea or hypopnea events which requires ECG recording for at least one night in order to calculate the AHI value for the purpose of OSA severity detection. \citeauthor{lit:SCD} also showed that the risk of incidence of sudden cardiac death (SCD) was significantly and independently associated with OSA, based both on the frequency of apneas and hypopneas, and the severity of nocturnal oxygen desaturations \cite{lit:SCD}. Recently, one study \cite{lit:onset} proposed a novel method to detect the severity of OSA without recording ECG for a whole night. They detected the sleep-onset period from the heart rate which is lower at that time than during wakefulness. Then they detected respiration cycles from EDR signals and used this as an input to the AHI prediction using regression analysis. Finally, they used the AHI value to classify the severity of OSA into four levels according to the OSA definition. However, the accuracy of this method is still related to the accuracy of sleep-onset period detection. In consideration of all the aforementioned issues, we aim to initiate an OSA severity detection approach with three main characteristics including: 1) Data acquisition is easier by using only single-channel ECG which can be acquired anywhere from many wearable devices; 2) No overnight sleep study is necessary such that we can prevent the sudden cardiac death (SCD) occurring in severe OSA patients by using only 15 seconds of ECG, and 3) No domain knowledge for feature extraction and feature selection is necessary by using a Deep Learning approach \cite{lit:deep}. \begin{figure*} \includegraphics[width=\textwidth, trim={0cm 9cm 0cm 4cm}]{model} \caption{The structure of proposed OSA severity classifier using a Deep Learning approach} \label{fig:model} \end{figure*} \section{Methodology} In this section, we first introduce our data preprocessing procedures. Then, k-fold cross-validation has been applied to test our main classifier. The structure of our classifier will be described at the end of this section. \subsection{Dataset} The dataset used in this research was taken from the MrOS sleep study (Visit 1) database \cite{mros1, mros2, mros3, mros4}. The data were recorded with 2911 people of age 65 years or older at 6 clinical centers in a baseline examination. They provide raw polysomnography (PSG) data as European Data Format (EDF) files and annotation XML files of each participant exported from Compumedics Profusion. The ECG signals in this dataset were acquired from Ag/AgCl patch sensors with the sampling rate of 512 Hz through a high-pass filter at 0.15 Hz. Each annotation file includes a marker of start time and duration for the apnea or hypopnea occurrences for each EDF file. We labeled the severity of OSA for each record by using the AHI variable provided in the dataset which is the number of apneas in all desaturations and hypopnea with 4\% desaturation occurring per hour \cite{lit:autoscreen}. In order to detect severe OSA patients such that we can prevent the sudden cardiac death as mentioned in Section II, we consequently used ECG records from normal patients with AHI values between 2 and 5, and records from extremely severe OSA patients with AHI values greater than 35. Finally, there were 545 subjects including 364 normal subjects and 181 severe OSA subjects which were preprocessed as follows: \subsubsection{Filter ECGs} In order to reduce noise in ECG recordings \cite{ECG:denoising}, the original ECG signal was filtered through a notch filter at 60 Hz and then filtered using a bandpass second-order Butterworth filter with cutoff frequencies at 5 and 35 Hz. \subsubsection{Extract apnea or hypopnea events} The ECG of each subject was extracted as a sample of apnea or hypopnea events from start time to start time added by duration according to its annotation file. We used only events that lasted 28 - 32 seconds. Then, we selected 30 seconds and normalized it by using the z-score function. Finally, we selected only the first 15 seconds to use. \subsubsection{Randomly selected samples} After completing all the data preprocessing procedures, there were 8604 apnea or hypopnea event samples including 3270 samples from normal subjects and 5334 samples from severe OSA patients. We finally randomly selected 1000 samples from each group to use for creating the classifier. \subsection{K-fold cross-validation} We used 10-fold cross-validation by separating samples into 3 sets including 80\%, 10\% and 10\% for training, validation, and testing, respectively. Firstly, 1000 samples were selected from each group of patients, and we randomly partitioned them into 10 equal-sized subsamples such that there were 10 subsamples with 100 samples in each. For each subsample, it then remains 900 samples from the total. Then, we randomly selected 100 samples from these to be the validation data and the remaining 800 samples were used as the training data. This process happened 10 times to let all subsamples be tested. Note that the data were combined samples from normal and severe OSA patients together. \subsection{OSA severity classification using Support Vector Machine} To compare with our main classifier, we detected RR Intervals and ECG derived respiration (EDR) signals from 15 seconds of ECG samples and extracted features from them which are widely used in several works mentioned in Section II. The set of features included: \subsubsection{Mean} An average value of the RR intervals. \subsubsection{Serial correlation} The second and third serial correlation coefficients of the RR intervals. \subsubsection{pNN50} The number of pairs of adjacent RR intervals where the second RR interval exceeds the first one by more than 50 ms. \subsubsection{SDSD} The standard deviation of the differences between adjacent RR Intervals. \subsubsection{Normalized VLF of RR intervals} The normalized power of very low frequency (VLF) of RR Intervals where the total power is the sum of the three components including VLF, low frequency (LF), and high frequency (HF). \subsubsection{Normalized VLF of EDR} The normalized power of VLF of EDR signal. \subsubsection{Normalized LF of EDR} The normalized power of LF of EDR signal. \subsubsection{Ratio of LF to HF of EDR} The ratio of a power of LF to HF of EDR signal. The range of signal frequency is defined by using 0.003--0.04 as VLF, 0.04--0.15 as LF and 0.15--0.4 as HF. Then, we applied these features and OSA severity labels as an input of the Support Vector Machine (SVM) model to predict whether each sample was a normal or severe OSA patient. \subsection{OSA severity classification using a Deep Learning (DL) approach} As shown in Figure \ref{fig:model}, the training dataset of 1600 samples, 7860 points per sample (15 seconds $\times$ 512 Hz), is fed into our model. The model is implemented using Keras with parameter configurations as follows: \begin{itemize} \item A stack of one-dimensional Convolutional Neural Networks (1-D CNNs) with 256, 128 and 64 units, respectively, for automatic feature extraction \cite{lit:deep}. \item Each CNN layer is followed by batch normalization; the rectified linear unit (ReLU) activation function as well as the max pooling process with pool size equal to 2 in order to extract only important features from the output of its previous layer. \item A stack of deep recurrent neural networks with Long Short-Term Memory (LSTM) structure with 128, 128, and 64 units, respectively, with recurrent dropout at 0.4. It is widely used with sequence processing because it is able to preserve the information from the temporal distance between each element in a sequence \cite{model:LSTM}. \item Each LSTM layer is followed by a dropout rate at 0.4. \item A stack of fully-connected neural networks (DNNs) with layers of size 128, 64, 32, 16, 8, and 4 hidden nodes for feature encoding from a large number of features into the number closes to 2. \item Each DNN layer is followed by the Hyperbolic tangent (tanh) activation function. \item The optimizer is \textit{rmsprop} with the learning rate of 0.001. \item The \textit{softmax} function is applied for binary classification including normal and severe OSA patients. \end{itemize} After model optimization, we evaluated our main classifier using accuracy, specificity, sensitivity and F-score. We also compared those metrics with the SVM classifier and performed a paired sample t-test between two classifiers. \begin{figure} {\includegraphics[width=\linewidth,trim=7.5cm 3.5cm 9cm 3.5cm,clip]{ecg}} \caption{An example of 15-second normalized ECG signals (512 Hz) with apnea or hypopnea events from a normal patient (top) and a severe OSA patient (bottom)} \label{fig:ecg} \end{figure} \section{Results and Discussion} An example of 15-second ECG records after normalization from normal and severe OSA subjects is shown in Figure \ref{fig:model}. After training with 10-folds of data in our main classifier with a Deep Learning (DL) approach and the SVM classifier, the results are shown in Table \ref{table:results}. Bold numbers in the table represent the higher value between two classifiers. It shows that our main classifier gives higher accuracy, sensitivity, specificity and F-score in every fold as well as the mean values. Figure \ref{fig:Acc} shows the boxplots of the accuracy acquired from two classifiers. While SVM accuracy ranged from 49.5\% to 59.0\% (mean $\pm$ standard deviation, 55.94\% $\pm$ 2.63\%), our main classifier ranged from 73.5\% to 82.5\% (mean $\pm$ standard deviation, 79.45\% $\pm$ 3.29\%). Consequently, we can conclude that our main classifier performs significantly better than the SVM classifier with \emph{t(10)$=$2.228}, \emph{p\textless0.05}. Although there are 4 levels of OSA severity including normal, mild, moderate, and severe, as we mentioned previously this paper is only a pilot study of OSA severity classification and focuses on detecting severe OSA patients to prevent sudden cardiac death (SCD), so we started classifying with only 2 classes including normal and severe OSA subjects. As shown in Table \ref{table:results}, the result is promising which means it is a good start to detecting severe OSA patients by using only 15 seconds of ECG signals with apnea or hypopnea events occurring. Compared to other previous studies, this proposed classification method achieves a new level of contribution. Firstly, it is more convenient because we use only a single channel of ECG to classify the OSA severity, and such equipment can be found commonly in wearable devices. Secondly, we used only 15 seconds of ECG signals so it is almost instantaneous. From this advantage, it is not only solving a problem of time wasting but also can be adapted to alert the system in order to prevent sudden cardiac death. Lastly, the Deep Learning approach helps us in feature extraction and provides promising results. However, we need to improve the classifier to be compatible with subjects from all OSA severity levels. \begin{table}[t] \centering \caption{Comparison of Accuracies (Acc), Sensitivity, Specificity, and F-Score of normal and severe OSA patients classification between SVM and DL approach in each fold} \label{table:results} \begin{tabular}{@{}cp{.4cm}cp{.4cm}cp{.4cm}cp{.4cm}cp{.4cm}cp{.4cm}cp{.4cm}cp{.4cm}cp{.4cm}@{}} \toprule \multirow{2}{*}{\textbf{K}} & \multicolumn{2}{c}{\textbf{Acc.} {[}\%{]}} & \multicolumn{2}{c}{\textbf{Sensitivity} {[}\%{]}} & \multicolumn{2}{c}{\textbf{Specificity} {[}\%{]}} & \multicolumn{2}{c}{\textbf{F-score} {[}\%{]}} \\ \cmidrule(l){2-9} & {\textbf{SVM}} & {\textbf{DL}} & {\textbf{SVM}} & {\textbf{DL}} & {\textbf{SVM}} & {\textbf{DL}} & {\textbf{SVM}} & {\textbf{DL}} \\ \toprule {1} & {57.00} & {\textbf{80.50}} & {59.00} & {\textbf{83.00}} & {55.00} & {\textbf{78.00}} & {57.84} & {\textbf{80.98}} \\ \midrule {2} & {59.00} & {\textbf{82.50}} & {62.00} & {\textbf{83.00}} & {56.00} & {\textbf{82.00}} & {60.19} & {\textbf{82.59}} \\ \midrule {3} & {58.79} & {\textbf{80.50}} & {48.48} & {\textbf{79.00}} & {69.00} & {\textbf{82.00}} & {53.93} & {\textbf{80.20}} \\ \midrule {4} & {56.78} & {\textbf{82.00}} & {57.58} & {\textbf{77.00}} & {56.00} & {\textbf{85.00}} & {57.00} & {\textbf{80.21}} \\ \midrule {5} & {55.50} & {\textbf{82.00}} & {\textbf{76.00}} & {75.00} & {35.00} & {\textbf{79.00}} & {63.07} & {\textbf{82.52}} \\ \midrule {6} & {55.50} & {\textbf{76.50}} & {55.00} & {\textbf{69.00}} & {56.00} & {\textbf{84.00}} & {55.28} & {\textbf{74.59}} \\ \midrule {7} & {56.28} & {\textbf{82.50}} & {60.61} & {\textbf{88.00}} & {52.00} & {\textbf{77.00}} & {57.97} & {\textbf{83.41}} \\ \midrule {8} & {56.00} & {\textbf{75.00}} & {54.00} & {\textbf{72.00}} & {58.00} & {\textbf{78.00}} & {55.10} & {\textbf{74.23}} \\ \midrule {9} & {49.50} & {\textbf{73.50}} & {61.00} & {\textbf{68.00}} & {38.00} & {\textbf{79.00}} & {54.71} & {\textbf{71.96}} \\ \midrule {10} & {55.00} & {\textbf{79.50}} & {67.00} & {\textbf{82.00}} & {43.00} & {\textbf{77.00}} & {59.82} & {\textbf{80.00}} \\ \midrule \midrule \textbf{Mean} & 55.94 & \textbf{79.45} & 60.07 & \textbf{77.60} & 51.80 & \textbf{80.10} & 57.49 & \textbf{79.07} \\ \bottomrule \end{tabular} \end{table} \begin{figure} \includegraphics[width=1\linewidth, trim={4cm 3cm 3cm 2cm}]{Acc} \caption{Boxplots of OSA severity classification accuracy in 10-fold cross-validation. * notes that the accuracy of DL approach classifier is significantly higher than the SVM, \emph{p$<$0.05}.} \label{fig:Acc} \end{figure} \section{Conclusion and Future Works} In this paper, the OSA severity classifier using a Deep Learning approach is proposed. We used only 15 seconds of ECG with apnea or hypopnea events from 545 subjects and fed them into a stack of CNNs, LSTMs, and DNNs to classify into 2 classes including normal and severe OSA subjects. We evaluated our proposed classifier by a set of metrics as well as comparison to the SVM classifier with a set of features obtained from RR Intervals and ECG derived respiration (EDR) signal. The proposed classifier is capable of detecting extremely severe OSA subjects from normal subjects with an accuracy level of 79.45\% which is significantly better than the result from the SVM classifier which has an accuracy of 55.94\%. It thus provides an initiation for future development of OSA severity detection systems in order to notify clinicians immediately when severe OSA is found. Since there are several studies already focused on apnea and hypopnea event detection, we assumed in this paper that we know at which points of ECG that the apnea or hypopnea events occur. However, the whole system of OSA severity classification should start with detecting apnea and hypopnea onset before using that period to classify the severity. Consequently, the future research study will focus on the methodology of apnea and hypopnea onset detection. Moreover, we will extend the system to support all OSA severity subjects for practical usage. \small \bibliographystyle{plainnat}
\section{Introduction} In 1998, H\"aggstr\"om and Pemantle~\cite{HP_twotype} introduced a model for competing growth on ${\mathbb Z}^2$ known as the two-type Richardson model. Two competing entities, here referred to as type 1 and type 2 infection, initially occupy one site each of the ${\mathbb Z}^2$ nearest-neighbor lattice. As time evolves each uninfected site is occupied by type $i$ at rate $\lambda_i$ times the number of type $i$ neighbors. An infected site remains in its state forever, implying that the model indeed defines a competition scheme between the types. Regardless of the values of the intensities, both types clearly have a positive probability of winning by surrounding the other type at an early stage. Attention hence focuses on the event $\mathscr{C}$ that both types simultaneously grow to occupy infinitely many sites; this is referred to as \emph{coexistence} of the two types. Deciding whether or not $\mathscr{C}$ has positive probability is non-trivial since it cannot be achieved on any finite part of the lattice. By time-scaling and symmetry we may restrict to the case $\lambda_1=1$ and $\lambda_2=\lambda>1$. The conjecture, due to H\"aggstr\"om and Pemantle~\cite{HP_twotype}, then is that $\mathscr{C}$ has positive probability if and only if $\lambda=1$. The \emph{if}-direction of the conjecture was proved in~\cite{HP_twotype}, and extended to higher dimensions independently by Garet and Marchand~\cite{GM_coex} and Hoffman~\cite{Hoff_coex}, using different methods. As for the \emph{only if}-direction, H\"aggstr\"om and Pemantle \cite{HP_absence} showed in 2000 that coexistence is possible for at most countably many values of $\lambda$. Ruling out coexistence for \emph{all} $\lambda>1$ remains a seemingly challenging open problem. In this paper we study the analogous problem in the upper half-plane ${\mathbb Z}\times{\mathbb Z}_+=\{(x,y):y\ge0\}$ with $(0,0)$ initially occupied by type 1 and $(1,0)$ initially occupied by type 2, and show that coexistence has positive probability if and only if $\lambda=1$. That coexistence is possible for $\lambda=1$ follows from similar arguments as in the full plane, so the novelty lies in proving the \emph{only if}-direction. \begin{thm}\label{thm:main} Consider the two-type Richardson model on ${\mathbb Z}\times{\mathbb Z}_+$ with $(0,0)$ and $(1,0)$ initially of type 1 and 2, respectively. Then we have that ${\mathbb P}(\mathscr{C})>0$ if and only if $\lambda=1$. \end{thm} Some readers might suspect that the arguments used to prove this result could be adaptable to settle the H\"aggstr\"om-Pemantle conjecture in the full plane. This however is most likely not the case. It is known that, on the event of coexistence in the full plane, the speed of the growth is determined by the weaker type; see e.g.\ \cite[Proposition 2.2]{HP_absence}. This means that, in order not to grow too fast, the stronger type must survive by maintaining a meandering path surrounded by the weaker type. In fact, it can be shown that the fraction of the infected sites occupied by the stronger type is vanishing; see \cite{GM_invisible}. The crucial point in our half-plane argument is that infinite survival for the stronger type implies that it must occupy all sites along the positive horizontal axis. We use this to show that it will thereby grow fast enough to eventually surround the weaker type. Note that the role of the initial configuration is important for this argument. We have not been able to adapt the argument to rule out coexistence in the half-plane when the initial position of the stronger type is not connected to the horizontal axis. Indeed, working with general initial configurations seems to make the problem as hard as in the full plane. We remark that, in the full plane, it is shown in \cite{initial} that the initial configuration is irrelevant for the possibility of infinite coexistence, but that argument does not apply here. One way of constructing the two-type process is by independently assigning a unit exponential random weight $\tau(e)$ to each nearest-neighbor edge $e$ of the lattice. The time required for type 1 to traverse an edge $e$ is then given by the associated weight $\tau(e)$, and the time for type 2 is $\lambda^{-1}\tau(e)$. Indeed, this construction provides a coupling of the two-type models for all $\lambda\ge1$ simultaneously. The curious partial result of~\cite{HP_absence} is derived based on this coupling by showing that, in the probability measure underlying the coupling, there is almost surely at most one value of $\lambda$ for which coexistence may occur. That coexistence occurs with positive probability for at most countably many $\lambda\ge1$ is an easy consequence of this. There are a number of proofs of coexistence for the case when the types have the same intensities, and (at least some of) these arguments can be adapted to prove the \emph{if}-direction of Theorem \ref{thm:main}. We shall however offer an alternative proof, since it is a simple by-product of the arguments required to prove the \emph{only if}-direction of the theorem. To rule out coexistence for $\lambda>1$, we shall develop an argument inspired by the work of Blair-Stahn~\cite{BS_thesis}, and that incorporates elements of Busemann functions introduced by Hoffman~\cite{Hoff_coex,Hoff_geodesics}. Nevertheless, the proof will be a self-contained and elementary deduction from standard results in first-passage percolation. The two-type Richardson model can be viewed as a two-type version of first passage percolation with exponential edge weights. One of the most fundamental results for first passage percolation is the shape theorem, asserting that the infected set at time $t$ converges on the scale $t^{-1}$ to a deterministic convex set $A$. In order to describe the structure of the proof of Theorem \ref{thm:main}, let $\theta$ denote the maximal angle between any supporting line of $A$ in the first coordinate direction and the vertical supporting line in the same coordinate direction; see Figure \ref{fig1} (left picture). Then $\theta$ equals zero in case the shape is differentiable in the coordinate directions, and $\theta$ is at most $\pi/4$, which occurs if the shape is a diamond. Given $\varepsilon>0$ and $n\in{\mathbb Z}$, we partition the upper half-plane ${\mathbb Z}\times{\mathbb Z}_+$ into two regions $\mathcal{L}_\varepsilon(n)$ and $\mathcal{R}_\varepsilon(n)$ as follows: Consider the semi-infinite line through $(n-1/2,0)$ with angle $\theta+\varepsilon$ to the vertical line through the same point (see Figure \ref{fig1}, right picture), and write $\mathcal{L}_\varepsilon(n)$ for the part of the upper half-plane to the left of this line, excluding points on the line, and $\mathcal{R}_\varepsilon(n)$ for the part to the right of the line, including points on the line. Finally, define the strips $S_k:=\{(x,y)\in {\mathbb Z}^2:0\leqslant y\leqslant k\}$ and $S_k^+=\{(x,y)\in {\mathbb Z}^2: x\geqslant 0, 0\leqslant y\leqslant k\}$. The proof of the \emph{only if}-direction of Theorem \ref{thm:main} can roughly be divided into three steps, where the first one may be considered the most fundamental: \begin{description} \item[Step (i)] Show that, for every $\lambda\geqslant 1$ and $\varepsilon>0$, if type 2 survives indefinitely, then almost surely type 2 reaches $\mathcal{R}_\varepsilon(n)$ before type 1 for infinitely many $n\ge1$. \item[Step (ii)] Show that, for every $\lambda>1$ there exists $\varepsilon>0$ such that, if type 2 comes first to $\mathcal{R}_\varepsilon(n)$, then for each each $k\ge1$ there is a positive probability (uniform in $n$) that type 2 occupies all vertices in $S_k\cap \mathcal{R}_\varepsilon(n)$. \item[Step (iii)] Show that, if type 2 conquers all but finitely many vertices in $S_k^+$ for $k$ large, then it will eventually almost surely defeat type 1. \end{description} Combining steps~(i) and~(ii) (or in fact a slight rephrasing of these claims) one obtains that, if type 2 survives indefinitely, then for all $k\geqslant 1$ it will almost surely conquer all but finitely many sites in the strip $S_k^+$ along the horizontal axis. According to step~(iii), this means that type 1 will eventually become surrounded by type~2, ruling out coexistence. \begin{figure}[htbp] \begin{center} \begin{tikzpicture}[scale=.5] \def4{4} \filldraw[draw=black,fill=gray!40!white] (2,0) -- ({4*cos(45)-2},{4*sin(45)}) -- (-2,4) -- ({4*cos(135)-2},{4*sin(135)}) -- (-6,0) -- cycle; \draw[->] (-7,0) -- (2.5,0); \draw[->] (-2,-.5) -- (-2,4.5); \draw (2,0) -- (2,4); \draw (2,2) arc [start angle=90, end angle=112.5, radius=2]; \draw (2,2) node[anchor=south east] {$\theta$}; \fill[fill=gray!40!white] (12,0) -- ({12+4*cos(67.5)/sin(67.5)},4) -- (16,4) -- (16,0) -- cycle; \draw[->] (7,0) -- (16.5,0); \draw[->] (8,-.5) -- (8,4.5); \draw[dashed] (12,0) -- (12,4); \draw (12,2) arc [start angle=90, end angle=67.5, radius=2]; \draw (12,0) -- ({12+4*cos(67.5)/sin(67.5)},4); \draw (12,0) node[anchor=north] {$(n,0)$}; \draw (13.25,2) node[anchor=south east] {$\scriptscriptstyle{\theta+\varepsilon}$}; \draw (12,1.5) node[anchor=south east] {$\mathcal{L}_\varepsilon(n)$}; \draw (16,1.5) node[anchor=south east] {$\mathcal{R}_\varepsilon(n)$}; \end{tikzpicture} \end{center} \caption{Illustration of $\theta$ and the regions $\mathcal{L}_\varepsilon(n)$ and $\mathcal{R}_\varepsilon(n)$ in the case that the shape is an octagon. The shape and the region $\mathcal{R}_\varepsilon(n)$ are shaded.} \label{fig1} \end{figure} The angle $\theta$ used to define the region $\mathcal{R}_\varepsilon(n)$ can be motivated as follows: On one hand the claim in step~(ii), which will be a consequence of the shape theorem, cannot hold for any angle larger than $\theta$. On the other hand, while the claim in step~(i) certainly could be correct also for angles smaller than $\theta$ (assuming that $\theta>0$), proving such a thing would require detailed understanding of the structure of infinite one-sided geodesics in the half-plane setting. The information needed would go beyond our current understanding for the analogous objects in the full-plane. Of course, since we believe that the shape is differentiable (at least in coordinate directions) we consequently believe that $\theta=0$, and in this case we cannot do better that having $\mathcal{R}_\varepsilon(n)$ defined as an $\varepsilon$-tilted vertical line. The rest of the paper is organized so that relevant background on one-type first passage percolation is given in Section 2. In Section 3 we use Busemann functions to control the evolution of the one-type process to obtain a statement that will establish step (i). Section 4 is devoted to step (ii), which is essentially a consequence of the shape theorem. Finally, the proof of Theorem \ref{thm:main} is completed in Section 5, where step (iii) is established by an adaption of an argument from~\cite{HP_absence}. \section{Preliminaries} In standard first passage percolation each edge $e$ of some underlying graph is independently equipped with a non-negative random variable $\tau(e)$ from some common distribution. Throughout this paper, we shall assume that the underlying graph is the upper half-plane ${\mathbb Z}\times{\mathbb Z}_+$, equipped with edges between nearest-neighbors, and that the weights $\{\tau(e)\}$ are unit exponentials. Note that $\{\lambda^{-1}\tau(e)\}$ are then exponentials with parameter $\lambda$. Given a path $\Gamma$, we let $T_\lambda(\Gamma):=\sum_{e\in\Gamma}\lambda^{-1}\tau(e)$ and define the \emph{passage time} between two sets $\Phi,\Psi\subset{\mathbb Z}\times{\mathbb Z}_+$ in the environment $\{\lambda^{-1}\tau(e)\}$ as $$ T_\lambda(\Phi,\Psi):=\inf\big\{T_\lambda(\Gamma):\Gamma \mbox{ is a path in ${\mathbb Z}\times{\mathbb Z}_+$ connecting $\Phi$ to $\Psi$}\big\},\\ $$ To simplify the notation, we write $T_1(\Gamma)=T(\Gamma)$, $T_1(\Phi,\Psi)=T(\Phi,\Psi)$, and $T_\lambda(x,y)$ for the passage time between $\{x\}$ and $\{y\}$ for $x,y\in\mathbb{Z}^2$. It is immediate from the construction that $T_\lambda(\Phi,\Psi)=\lambda^{-1} T(\Phi,\Psi)$ for all $\lambda\ge1$. The above construction gives rise to a simultaneous coupling of the two-type processes for all $\lambda\geqslant 1$, where type~1 requires time $\tau(e)$ to traverse an edge $e$ while type~2 requires time $\lambda^{-1}\tau(e)$. The passage time $T(\mathbf{0},z)$ then denotes the time at which type~1 arrives at the site $z$, unless $z$ is already reached by type 2 by then, and $T_\lambda(\mathbf{1},z)$ similarly denotes the time it would take type~2 to reach $z$, unless impeded by type~1 along the way.\footnote{Throughout the paper, we shall let bold letters like $\mathbf{n}$ be short for the horizontal vectors $(n,0)$.} In the case that $\lambda=1$, whether or not a site $z$ is eventually occupied by type~2 can be read out directly from $T$; it will in the case that $T(\mathbf{1},z)<T(\mathbf{0},z)$. Understanding the evolution in the two-type Richardson model thus leads us to recall some basic results for one-type first-passage percolation. Due to the relation $T_\lambda(x,y)=\lambda^{-1}T(x,y)$, we focus in the remainder of this section on the case $\lambda=1$; corresponding results for $\lambda>1$ are obtained by a simple scaling argument. Although first passage percolation in half-planes has been studied before, e.g.\ in~\cite{Ahl15,ADH15,WW98}, the vast majority of the literature is concerned with the two and higher dimensional nearest-neighbor lattices. It will be convenient to survey some of the results here. In analogy with the notation in the half-plane, we shall denote by $\overline T(\Phi,\Psi)$ the passage time between the two sets $\Phi,\Psi\subset{\mathbb Z}^2$, where the infimum is now taken over paths in ${\mathbb Z}^2$ connecting $\Phi$ and $\Psi$. A first crucial observation is that $\overline T$ defines a metric on ${\mathbb Z}^2$. In particular, it is subadditive in the sense that $$ \overline T(x,y)\leqslant \overline T(x,z)+\overline T(z,y)\quad\mbox{for all }x,y,z\in{\mathbb Z}^2. $$ Using subadditive ergodic theory \cite{K68,L85}, one can establish the existence of a time constant $\mu\in(0,\infty)$ specifying the asymptotic inverse speed of the growth along the axes. Specifically, we have that $$ \lim_{n\to\infty}\frac{\overline T(\mathbf{0},\mathbf{n})}{n}=\mu\quad \mbox{almost surely and in }L^1. $$ This can be extended to an arbitrary direction in the first octant, and hence by symmetry of ${\mathbb Z}^2$, to any arbitrary direction: For $\alpha\in[0,\pi/4]$, let $u_\alpha$ denote a unit vector with angle $\alpha$ to the $x$-axis, that is, $u_\alpha=(\cos\alpha,\sin\alpha)$. Also, for $x,y\in{\mathbb R}^2$, define $\overline T(x,y):=\overline T(x',y')$, where $x'$ and $y'$ are the points in ${\mathbb Z}^2$ closest to $x$ and $y$, respectively. Then there exists a directional time constant $\mu_\alpha\in(0,\infty)$ such that \begin{equation}\label{dir_mu} \lim_{n\to\infty}\frac{\overline T(\mathbf{0},nu_\alpha)}{n}=\mu_{\alpha}\quad \mbox{almost surely and in }L^1. \end{equation} By definition, we have $\mu_0=\mu$. We remark that passage times to lines rather than single points obey the same asymptotics. For instance, with $\bar{\ell}_\alpha(n)$ denoting the straight line through $nu_\alpha$ with normal vector $u_\alpha$, we have that $\frac1n\overline T(\mathbf{0},\bar{\ell}_\alpha(n))$ converges to $\mu_\alpha$ almost surely. This can be seen as a consequence of the fundamental shape theorem, which in its first version dates back to the work of Richardson~\cite{R73}. Since $\overline T$ defines a (random) metric on ${\mathbb Z}^2$ it is natural to investigate the shape of large balls in this metric. The shape theorem~\cite{Kes73,R73} states that the set of sites that can be reached from the origin within time $t$ converges almost surely on the scale $t^{-1}$ to a deterministic shape $A$, that is, with probability one, we have for every $\varepsilon>0$ that $W(t):=\{x\in{\mathbb R}^2:\overline T(\mathbf{0},x)\leqslant t\}$ satisfies $$ (1-\varepsilon)A\subset \frac{W(t)}{t}\subset (1+\varepsilon)A \quad\mbox{for all large }t. $$ The asymptotic shape $A$ can be characterized as the unit ball in the norm defined by $\mu(x)=\lim_{n\to\infty}\frac1n\overline T(\mathbf{0},nx)$ for $x\in{\mathbb R}^2$. It is thus known to be compact and convex, with non-empty interior, and it inherits all symmetries of ${\mathbb Z}^2$. Apart from this, very little is known about the properties of the shape. It has been studied by aid of simulations in \cite{AlmDeijfen15}, where the results indicate that it is close to, but not identical to, a Euclidean disk. We remark that there is no theoretical support for $A$ being a Euclidean disk, and in large dimension it is known not to be a Euclidean ball. When restricting the growth to a strip $S_k:=\{(x,y)\in {\mathbb Z}^2:0\leqslant y\leqslant k\}$ for some $k\ge1$, the speed of progression decreases. However, the thicker the strip, the smaller is the effect. To be precise, let $T^{\sss (k)}(\Phi,\Psi)$ denote the passage time between $\Phi\subset S_k$ and $\Psi\subset S_k$, where the infimum is taken over paths $\Gamma\subset S_k$ connecting $\Phi$ and $\Psi$. Again, the subadditive ergodic theorem shows that $\frac1nT^{\sss (k)}(\mathbf{0},\mathbf{n})$ converges (almost surely and in $L^1$) to some constant $\mu^{\sss (k)}\in(0,\infty)$. Moreover, \begin{equation}\label{mu_strip} \mu^{\sss (k)}\searrow\mu\quad\mbox{as }k\to\infty; \end{equation} see e.g.~\cite[Proposition 8]{Ahl15}. A similar statement holds for directions other than the axes directions. As a consequence, one can show that a shape theorem holds also for first passage percolation in the upper half-plane ${\mathbb Z}\times{\mathbb Z}_+$, and that the asymptotic shape in this case is the half-plane restriction of the shape $A$ arising in the full-plane growth; see \cite[Theorem 1]{Ahl15}. We shall occasionally need the following stronger form of this half-plane shape theorem, which is a consequence e.g.\ of~\cite[Proposition~15]{Ahl15}: For every $\varepsilon>0$ we have, almost surely, for all $y$ and all but finitely many $z$ in ${\mathbb Z}\times{\mathbb Z}_+$ that \begin{equation}\label{eq:better_shape} \big|T(y,z)-\mu(z-y)\big|<\varepsilon\max\{|z|,|z-y|\}, \end{equation} where $\mu$ is the time constant as determined by $\overline T$. \section{A one-type lemma} The aim of this section is to take the first and most fundamental step towards a proof of our main theorem. It will be crucial for ruling out coexistence in the case when $\lambda>1$, but we will use it also to give a short proof of coexistence in the case when $\lambda=1$. The result is a statement for the one-type process on ${\mathbb Z}\times{\mathbb Z}_+$. \begin{lma}\label{lma:main} For every $\varepsilon>0$ there exists $\gamma>0$ such that $$ {\mathbb P}\Big(T(-\mathbf{n},\mathbf{0})<T(-\mathbf{n},\mathcal{R}_\varepsilon(0)\backslash \{\mathbf{0}\})\text{ for all }n\ge1\Big)>\gamma. $$ \end{lma} Key to the proof of the lemma will be the notion of Busemann functions. Define, for all $n\ge1$ and sites $u,v$ in the half-plane, the Busemann-like function $$ B_n(u,v):=T(-\mathbf{n},u)-T(-\mathbf{n},v). $$ Lemma~\ref{lma:main} can be rephrased to say that with positive probability $B_n(\mathbf{0},v)<0$ for all $v\in\mathcal{R}_\varepsilon(0)\setminus\{\mathbf{0}\}$ and $n\ge1$. We shall first show that, almost surely, $B_n(\mathbf{0},v)<0$ may fail for some $n$ for at most finitely many $v$ (Lemma \ref{lma:negative}). A local modification argument will then show that with positive probability it does not. A key observation is that, for fixed $m\ge1$, the sequence $\{B_n(\mathbf{0},\mathbf{m})\}_{n\ge1}$ is almost surely increasing. The limit $$ B(\mathbf{0},\mathbf{m}):=\lim_{n\to\infty}B_n(\mathbf{0},\mathbf{m}) $$ hence exists almost surely. Indeed, this turns out to be true for all $u$ and $v$, see~\cite{ADH15}, but we shall not need this fact. Instead, we shall make use of the following asymptotic property. \begin{lma}\label{lma:Busemann} For all $m\ge1$, we have that $\E[B(\mathbf{0},\mathbf{m})]=-\mu\cdot m$, and $$ \lim_{m\to\infty}\frac1mB(\mathbf{0},{\bf m})=-\mu\quad\text{almost surely}. $$ \end{lma} \begin{proof} A useful property of $B_n$ is that it is additive. The additivity carries over in the limit as $n\to\infty$ and for $B$ this implies that \begin{equation}\label{eq:B} \frac1mB(\mathbf{0},\mathbf{m})=\frac1m\sum_{j=0}^{m-1}B({\bf j},{\bf j+1}), \end{equation} where $B({\bf j},{\bf j+1}):=\lim_{n\to\infty}B_n({\bf j},{\bf j+1})$. Due to invariance with respect to horizontal shifts, sending $m$ to infinity in~\eqref{eq:B}, the ergodic theorem yields the almost sure limit $\E[B(\mathbf{0},\mathbf{1})]$. By additivity, it only remains to identify $\E[B(\mathbf{0},\mathbf{1})]$ with $-\mu$. To this end, we rephrase $B(\mathbf{0},\mathbf{1})$ as a limit of partial averages, and obtain $$ \E[B(\mathbf{0},\mathbf{1})] = \E\Big[\lim_{n\to\infty}\frac1n\sum_{j=0}^{n-1}B_j(\mathbf{0},\mathbf{1})\Big]=\lim_{n\to\infty}\frac1n\sum_{j=0}^{n-1}\E[B_j(\mathbf{0},\mathbf{1})], $$ where extraction of the limit is allowed by dominated convergence, since $|B_j(\mathbf{0},\mathbf{1})|\leqslant T(\mathbf{0},\mathbf{1})$. Due to invariance with respect to horizontal shifts, we have further that $$ \E[B(\mathbf{0},\mathbf{1})]=\lim_{n\to\infty}\frac1n\sum_{j=0}^{n-1}\E[T(\mathbf{0},{\bf j})-T(\mathbf{0},{\bf j+1})]=\lim_{n\to\infty}\frac1n\E[-T(\mathbf{0},{\bf n})]=-\mu, $$ as required. \end{proof} Let $\partial \mathcal{R}_\varepsilon(n)$ denote the set of sites in $\mathcal{R}_\varepsilon(n)$ that have at least one neighbor in $\mathcal{L}_\varepsilon(n)$. \begin{lma}\label{lma:negative} There exists $\delta>0$ such that, with probability one, for all $n\ge1$ and all but finitely many $v\in\partial\mathcal{R}_\varepsilon(0)$, we have that $$ B_n(\mathbf{0},v)<-\delta|v|\mu<0. $$ \end{lma} \begin{proof} Note that, by convexity of the shape and the definition of $\theta$, there exists $\delta>0$ such that for each $v\in\partial \mathcal{R}_\varepsilon(0)$ there is $m=m(v)$ such that $$ \mu(v-\mathbf{m})\leqslant(1-\delta)\mu(\mathbf{m}); $$ see Figure \ref{fig2} (left picture). \begin{figure}[htbp] \begin{center} \begin{tikzpicture}[scale=.5] \draw[->] (-10,0) -- (6,0); \draw[->] (0,-.5) -- (0,4); \draw[dashed,thick] (0,0) -- (1.5,4); \filldraw[fill=gray!40!white,draw=gray] (14,0) -- (13.5,0) -- (14.625,3) -- (15.125,3) -- cycle; \draw[->] (11,0) -- (16,0); \draw[->] (14,-.5) -- (14,4); \draw[dashed,thick] (14,0) -- (15.5,4); \draw (-9,0) to [curve through={(-8.5,.4) (-8,.6) (-7.5,.5) (-7,.65) (-6,.75) (-5,1) (-4,1.5) (-3,1.75) (-2,1.75) (-1,1.65) (0,1.8)}] (.75,2); \draw (-6,.75) to [curve through={(-5,.65) (-4,.45) (-3,.75) (-2,.45) (-1,.35)}] (0,0); \draw (14,0) to [curve through={(13.5,.25) (13.2,.2) (13.4,.75) (13,1.25) (13.5,1.75) (14,2.3) (14.25,2.2)}] (14.75,2); \draw (-9.3,0) node[anchor=north] {$-\mathbf{n}$}; \draw (4,0) node[anchor=north] {$\mathbf{m}$}; \draw (12,1.5) node[anchor=west] {$\Gamma$}; \draw (.75,2) node[anchor=west] {$v$}; \draw (2.5,2.7) node[anchor=west] {$\mathcal{R}_\varepsilon(0)$}; \draw (14.75,2) node[anchor=west] {$\ell$}; \draw (15.125,3) node[anchor=west] {$\ell'$}; \fill[fill=black] (0,0) circle (.125); \fill[fill=black] (.75,2) circle (.125); \fill[fill=black] (-9,0) circle (.125); \fill[fill=black] (4,0) circle (.125); \draw[thick] (14.625,2) -- (14.825,2); \draw[thick] (15,3) -- (15.25,3); \end{tikzpicture} \end{center} \caption{Geometry in the proofs of Lemmas~\ref{lma:negative} and~\ref{lma:main}.} \label{fig2} \end{figure} Indeed, $m$ can be chosen to roughly equal $c|v|$ for some $c>0$. Together with the strong version of the shape theorem stated in~\eqref{eq:better_shape}, it follows that almost surely for all but finitely many $v\in\partial \mathcal{R}_\varepsilon(0)$ we have that $$ B_n(\mathbf{m},v)\leqslant T(\mathbf{m},v)\leqslant(1+\delta)\mu(v-\mathbf{m})\leqslant(1-\delta^2)\mu(\mathbf{m}). $$ Moreover, by monotonicity of $B_n$ and Lemma~\ref{lma:Busemann}, we have almost surely for all $n\ge1$ and large $m$ that $$ B_n(\mathbf{0},\mathbf{m})\leqslant B(\mathbf{0},\mathbf{m})\leqslant-(1-\delta^2/2)\mu(\mathbf{m}). $$ Combining the two estimates we conclude that almost surely, for all but finitely many $v\in \partial \mathcal{R}_\varepsilon(0)$, we have for all $n\ge1$ that \begin{equation* B_n(\mathbf{0},v)=B_n(\mathbf{0},\mathbf{m})+B_n(\mathbf{m},v)\leqslant-(\delta^2/2)\mu(\mathbf{m})<0. \end{equation*} Since $m$ is roughly $c|v|$ for some $c>0$, the lemma follows. \end{proof} \begin{proof}[Proof of Lemma~\ref{lma:main}] Let $(x_n,y_n)$ be the point in $\mathcal{R}_\varepsilon(0)$ with the smallest passage time to $-\mathbf{n}$. By Lemma~\ref{lma:negative}, the sequence $(y_n)_{n\ge1}$ is almost surely bounded. Fix $\ell$ large so that, with probability at least $3/4$, we have $y_n\leqslant \ell$ for all $n$. Then pick some finite path $\Gamma$, connecting the origin to a point in $\partial\mathcal{R}_\varepsilon(0)$ of the form $(x,\ell+1)$, which except for its endpoints is contained in $\mathcal{L}_\varepsilon(0)$; see Figure \ref{fig2} (right picture). Next, take $t$ large so that, with probability at least $3/4$, the total passage time $T(\Gamma)$ is at most $t$. Note that, since any path from $-\mathbf{n}$ to $(x,y)\in\partial\mathcal{R}_\varepsilon(0)$ with $1\leqslant y\leqslant \ell$ must hit $\Gamma$ before hitting $(x,y)$, we have for all $n\geqslant 1$ that, on the intersection of the above two events, $$ T(-\mathbf{n},\mathbf{0})\leqslant T(-\mathbf{n},\mathcal{R}_\varepsilon(0))+T(\Gamma)\leqslant T(-\mathbf{n},\mathcal{R}_\varepsilon(0))+t. $$ Write $U_{\ell'}$ for the set of sites $(x,y)\in \partial\mathcal{R}_\varepsilon(0)$ with $y\geqslant \ell'$. Due to Lemma~\ref{lma:negative}, we may pick $\ell'\geqslant \ell$ such that $T(-\mathbf{n},U_{\ell'})\geqslant T(-\mathbf{n},\mathbf{0})+2t$ for all $n\ge1$ with probability at least $3/4$. Define $C$ to be the intersection of all three events above. That is, let $$ C:=\big\{y_n\leqslant \ell\text{ for all }n\big\}\cap \big\{T(\Gamma)\leqslant t\big\}\cap \big\{T(-\mathbf{n},U_{\ell'})\geqslant T(-\mathbf{n},\mathbf{0})+2t\text{ for all }n\big\}, $$ and note that ${\mathbb P}(C)\ge1/4$. Let $\Lambda_{\ell'}$ denote the set of edges connecting sites $(x,y)\in\partial\mathcal{R}_\varepsilon(0)\setminus\{\mathbf{0}\}$ with $y\leqslant \ell'$ to sites in $\mathcal{L}_\varepsilon(0)$; see Figure \ref{fig2} (shaded area in the right picture). We complete the proof by arguing that, on the event $C$, a configuration where the origin is the closest point in $\partial\mathcal{R}_\varepsilon(0)$ to $-\mathbf{n}$ for all $n\geqslant 1$ is obtained by increasing the weight of all edges in $\Lambda_{\ell'}$ to $2t$. Indeed, the time minimizing path from $-\mathbf{n}$ to $\mathcal{R}_\varepsilon(0)$ will then not hit a point $(x,y)\in\mathcal{R}_\varepsilon(0)$ for $y=1,\ldots,\ell'$, since it would have reached the origin via $\Gamma$ before the last edge is traversed. It will also not hit $\mathcal{R}_\varepsilon(0)$ for $y\geqslant \ell'$, since it will take at least time $2t$ from the moment when $\Gamma$ is hit to reach that level. To formalize this, we define another i.i.d.\ family of edge weights $\{\hat\tau(e)\}$, where $\hat\tau(e)=\tau(e)$ for $e\not\in\Lambda_{\ell'}$ and where $\hat\tau(e)$ is sampled independently of $\tau(e)$ for $e\in\Lambda_{\ell'}$. Denoting by $Q$ the event $\{\hat{\tau}(e)>t\mbox{ for all }e\in\Lambda_{\ell'}\}$, and distances with respect to $\{\hat\tau(e)\}$ by $\hat T$, the above reasoning gives that $$ {\mathbb P}\left(\hat{T}(-\mathbf{n},\mathbf{0})<\hat{T}(-\mathbf{n},\mathcal{R}_\varepsilon(0)\backslash \{\mathbf{0}\})\text{ for all }n\ge1\right) \geqslant {\mathbb P}\big(C\cap Q\big)={\mathbb P}(C){\mathbb P}(Q)>0, $$ due to independence of the two configurations on $\Lambda_{\ell'}$. Since the two configurations are equal in distribution, the lemma follows. \end{proof} \section{A two-type lemma} The next lemma concerns the two-type process with an unbounded initial configuration. It applies when type 2 is strictly stronger than type 1, and is derived as a geometric consequence of the shape theorem. Recall that $S_k^+=\{(x,y)\in {\mathbb Z}^2: x\geqslant 0, 0\leqslant y\leqslant k\}$. Note also that for small enough values of $\varepsilon>0$ the origin is the only site on the horizontal axis contained in $\partial\mathcal{R}_\varepsilon(0)$. \begin{lma}\label{lma:chance} For every $\lambda>1$ there is $\varepsilon>0$ such that if initially $\mathbf{0}$ is occupied by type 2 and all sites in $\partial\mathcal{R}_\varepsilon(0)\backslash\{\mathbf{0}\}$ are occupied by type 1, then, for every $k\ge1$, there is a positive probability that type 2 occupies all initially uninfected sites in the half-strip $S_k^+$. \end{lma} \begin{proof} Fix $\lambda>1$. Note that it suffices to prove the lemma for large $k$, since if type 2 occupies all uninfected sites in $S_k^+$, then this is trivially the case also for all $k'\leqslant k$. By~\eqref{mu_strip} we thus pick $k$ large so that $$ \lambda^{-1}\mu\leqslant\lambda^{-1}\mu^{\sss (k)}<\mu. $$ Let $\delta=(\mu-\lambda^{-1}\mu^{\sss (k)})/4$ and set $\rho=\lambda^{-1}\mu^{\sss (k)}+2\delta_0$. It follows from the half-plane shape theorem (the version stated in~\eqref{eq:better_shape}), convexity of the shape and the definition of $\mathcal{R}_\varepsilon(0)$ that, almost surely, for large $n$ we have that $$ T(\partial\mathcal{R}_\varepsilon(0),(n,k))>(\mu-\delta')n $$ for some $\delta'=\delta'(\varepsilon)>0$, with $\delta'\to 0$ as $\varepsilon\to 0$. Hence, for $\varepsilon>0$ small, $\mu-\delta'\geqslant\rho+\delta$. Moreover, almost surely, we have that $$ T^{\sss (k)}_\lambda(\mathbf{0},(n,k))<(\rho-\delta)n $$ for all large $n$. Finally, write $\tilde{T}^{\scriptscriptstyle (k)}_\lambda(\mathbf{0},(n,k))$ for the above passage time in the process based on $\{\lambda^{-1}\tau(e)\}$, when sites in $\partial\mathcal{R}_\varepsilon(0)$ cannot be used, and note that this clearly obeys the same asymptotics. (We assume here and in what follows that $\varepsilon>0$ is small, so that the origin is the only site on the horizontal axis contained in $\partial\mathcal{R}_\varepsilon(0)$.) For $m\ge1$ now define \begin{equation*} \begin{aligned} D_m&:=\{T(\partial\mathcal{R}_\varepsilon(0),(n,k))>(\rho+\delta)n\mbox{ for all }n\geqslant m\},\\ D'_m&:=\{\tilde{T}^{\scriptscriptstyle (k)}_\lambda(\mathbf{0},(n,k))<(\rho-\delta)n\mbox{ for all }n\geqslant m\}, \end{aligned} \end{equation*} and pick $m$ large so that ${\mathbb P}(D_m\cap D_m')>3/4$. Let $\Omega_m$ denote the set of edges consisting of all edges connecting an initially type 1 infected site to a neighbor in $S_k^+$, and all vertical edges connecting a site $(j,k+1)$ in $\mathcal{R}_\varepsilon(0)$ with $j\leqslant m$ to $(j,k)$. Hence $\Omega_m$ consists of all edges up to the level $x=m$ through which type 1 can enter the strip; see Figure~\ref{fig3}. \begin{figure}[htbp] \begin{center} \begin{tikzpicture}[scale=.75] \draw[->] (-1,0) -- (9,0); \draw [->] (0,-.5) -- (0,4); \draw (0,2) node[anchor=east] {$k$}; \draw (7,0) node[anchor=north] {$m$}; \filldraw[fill=gray!40!white,draw=gray] (0,0) -- (0.86,2.3) -- (7,2.3) --(7,2) -- (1.1,2) -- (0.3,0) -- cycle; \draw[dashed] (0,0) -- (1.5,4); \draw[dashed] (0,2) -- (9,2); \draw[dashed] (7,0) -- (7,4); \draw (3,1) node[anchor=west] {$\Omega'_m$}; \draw (4,3) node[anchor=west] {$\Omega_m$}; \draw[ultra thin, ->] (4,3) -- (2.8,2.15); \end{tikzpicture} \end{center} \caption{The regions $\Omega_m$ (shaded) and $\Omega_m'$.} \label{fig3} \end{figure} Also, let $\Omega_m'$ denote the set of edges connecting initially uninfected sites in $S_k^+$ up to level $x=m$, and note that $\Omega_m$ and $\Omega_m'$ are disjoint. Next, let \begin{equation*} \begin{aligned} E_{m,t}&:=\{\mbox{$\tau(e)>tkm$ for all $e\in\Omega_m$}\},\\ E_{m,t}'&:=\{\mbox{$\lambda^{-1}\tau(e)<t$ for all $e\in\Omega_m'$}\}. \end{aligned} \end{equation*} Since ${\mathbb P}(E_{m,t}')\to 1$ as $t\to\infty$, we can pick $t$ large so that ${\mathbb P}(D_m\cap D_m'\cap E_{m,t}')>1/2$. We claim that, on $D_m\cap D_m'\cap E_{m,t}\cap E_{m,t}'$, type 2 occupies all initially uninfected sites in $S_k^+$. To see this, note that $E_{m,t}\cap E_{m,t}'$ ensures that type 1 cannot enter the strip at a site $(j,k)$ with $j<m$, since any such site can be reached from the origin by a path in $\Omega_m'$ with weight at most $mkt$. The event $D_m\cap D_m'$ then guarantees that type 1 cannot enter the strip at a site $(j,k)$ with $j\geqslant m$, since type 2 is faster to all such sites once it has access to the initial piece of the strip. It remains to prove that ${\mathbb P}(D_m\cap D_m'\cap E_{m,t}\cap E_{m,t}')>0$. To this end, write $$ {\mathbb P}(D_m\cap D_m'\cap E_{m,t}\cap E_{m,t}')={\mathbb P}(D_m\cap D_m'\cap E_{m,t}'|E_{m,t}){\mathbb P}(E_{m,t}). $$ The events $D_m'$ and $E_{m,t}'$ involve only edges in $\Omega_m'$ while $E_{m,t}$ involves only edges in $\Omega_m$. Hence, since $\Omega_m'$ and $\Omega_m$ are disjoint, the conditioning on $E_{m,t}$ does not affect $D_m'$ and $E_{m,t}'$. As for $D_m$, the event $E_{m,t}$ stipulates that the passage times on certain edges are large. This clearly increases the probability of $D_m$ so that, in summary, ${\mathbb P}(D_m\cap D_m'\cap E_{m,t}'|E_{m,t})\geqslant {\mathbb P}(D_m\cap D_m'\cap E_{m,t}')$. The desired conclusion follows by noting that ${\mathbb P}(E_{m,t})>0$ since $\Omega_m$ is finite and $t$ fixed. \end{proof} \section{Proof of Theorem \ref{thm:main}} In this section we prove Theorem \ref{thm:main}. As mentioned, there are a number of proofs in the literature showing that coexistence is possible on ${\mathbb Z}^2$ when $\lambda=1$, and some of these are easily adapted to show the same statement in the half-plane. However, this can also be obtained by a short argument based on Lemma~\ref{lma:main}. \begin{proof}[Proof of the {\rm{if}}-direction of Theorem \ref{thm:main}] Take $\lambda=1$. Let $F$ denote the event in Lemma~\ref{lma:main}, and let $\bar F$ denote its reflection in the vertical axis. Let further $\bar F_m$ denote the translate of $\bar F$ along the vector $\mathbf{m}$. We observe that, on $F$, type 1 will be first to all sites along the negative horizontal axis. Similarly, on $\bar F_1$, type 2 will be first to all sites along the positive horizontal axis. Although there is no guarantee that the intersection of the two events occurs with positive probability, since $\bar F_m$ occurs with a density (due to the ergodic theorem), we may fix $m\ge1$ so that ${\mathbb P}(F\cap\bar F_m)>0$. To guarantee coexistence, it then remains to show that, on $F\cap\bar F_m$, there is positive probability for type 2 to reach $(m,0)$ before type 1 reaches $\mathcal{R}_\varepsilon(m)$. Let $O$ denote the event that each edge adjacent to the origin has weight at least $\delta$, and note that ${\mathbb P}(F\cap\bar F_m\cap O)>0$ for small $\delta>0$. Let $O'$ denote the event that the sum of the weights on the edges along the axis connecting $\mathbf{1}$ to $\mathbf{m}$ is at most $\delta/2$. Note that, on $O\cap O'$, type 2 will reach $\mathbf{m}$ before type 1 takes its first step. Since $F$, $\bar F_m$ and $O$ are independent of the state of the edges defining $O'$, it follows that $$ {\mathbb P}(\mathscr{C})\geqslant{\mathbb P}(F\cap\bar F_m\cap O\cap O')={\mathbb P}(F\cap\bar F_m\cap O){\mathbb P}(O')>0, $$ as required. \end{proof} We proceed with the \emph{only if}-direction, and start by combining Lemmas~\ref{lma:main} and~\ref{lma:chance} into a statement for the two-type process. \begin{lma}\label{lma:strip} For every $\lambda>1$ and $k\geqslant 1$, if type 2 occupies infinitely many sites in the two-type model on ${\mathbb Z}\times {\mathbb Z}^+$, then type 2 will almost surely occupy all but finitely many vertices in $S_k^+$. \end{lma} \begin{proof} Fix $\lambda>1$ and $k\ge1$. Write $F$ for the event in Lemma~\ref{lma:main}, and let $F_m$ denote the translate of $F$ along the vector $\mathbf{m}$. Also, let $G$ denote the event in Lemma~\ref{lma:chance}, and let $G_m$ denote the translate of $G$ along the vector $(m,0)$. Each of the two events $F$ and $G$ occur with positive probability. Moreover, $F$ is determined by edges between sites in $\mathcal{L}_\varepsilon(0)\cup \partial\mathcal{R}_\varepsilon(0)$ involving at least one site in $\mathcal{L}_\varepsilon(0)$, while $G$ is determined by edges between pairs of sites in $\mathcal{R}_\varepsilon(0)$. Hence, the two events are independent and ${\mathbb P}(F\cap G)>0$. By the ergodic theorem, $F_m\cap G_m$ will occur for infinitely many $m\ge1$, almost surely. It remains to prove that, on the event $F_m\cap G_m\cap \{\text{type 2 survives}\}$, where $m\ge1$, type 2 occupies all but finitely many vertices in $S_k^+$. For this, clearly it suffices to see that, if type 2 survives indefinitely, then $F_m$ implies that type 2 reaches $\mathbf{m}$ before any other site in $\partial\mathcal{R}_\varepsilon(m)$ is reached by type 1. To this end, let $\Gamma$ denote the time minimizing path from the origin to $\mathbf{m}$. Note that, if type 2 survives indefinitely, then $\mathbf{m}$ must be occupied by type 2 in the two-type process. Let $v$ denote the first (in time) point on the path $\Gamma$ that is occupied by type 2 in the two-type process. The fastest way to get from $v$ to $\mathcal{R}_\varepsilon(m)$ is to follow $\Gamma$ and, doing this, type 2 will arrive at $\mathbf{m}$ before any other site in $\mathcal{R}_\varepsilon(m)$ is infected, as desired. \end{proof} The last ingredient we need in order to prove the \emph{only if}-direction of Theorem~\ref{thm:main} is a half-plane version of a result from~\cite[Proposition 2.2]{HP_absence}. More precisely, we need to show that, if type 2 conquers a wide half-strip, then type 2 will end up surrounding type 1. The argument will be similar to that of~\cite{HP_absence}, but the geometric construction is easier in our case and the proof consists of applying the ideas in Lemmas~\ref{lma:chance} and~\ref{lma:strip} in non-axis directions. We shall therefore be brief. \begin{lma}\label{lma:speed} For every $\lambda>1$, there is $k\ge1$ such that, if type 2 occupies all but finitely many sites in $S_k^+$, then almost surely type 1 will occupy only finitely many sites. \end{lma} \begin{proof} If type 2 occupies all but finitely many sites in the half-strip $S_k^+$ for $k$ sufficiently large, then the type 2 speed along the axis in $S_k^+$ will be strictly larger than the speed of type 1. As we shall see, type 2 will then be strictly faster than type 1 also in direction $\alpha$, for some small $\alpha>0$. This can be used to show that type 2 occupies all but finitely many vertices in an $\alpha$-cone. By repeating the argument we then show that type~2 will also occupy almost all sites in a $2\alpha$-cone, etc. Recall the definition, in~\eqref{dir_mu}, of the time constant $\mu_\alpha$ in direction $\alpha$ based on unit rate exponential edge weights. The time constant in direction $\alpha$ based on exponential edge weights with parameter $\lambda$ is then given by $\lambda^{-1}\mu_\alpha$. As is well-known, the directional time constant $\mu_\alpha$ is Lipschitz continuous, since $\mu$ defines a norm. In particular, there exists a constant $c>0$ such that, for any $\alpha_0,\alpha\in[0,2\pi]$, we have that $$ \mu_{\alpha_0+\alpha}\leqslant \mu_{\alpha_0}(1+c\alpha). $$ It follows that, uniformly in the choice of $\alpha_0$, we have $\lambda^{-1}\mu_{\alpha_0+\alpha}\leqslant \mu_{\alpha_0}$ if $\alpha$ is sufficiently small. By picking $\alpha$ even smaller, we further obtain that $\lambda^{-1}\mu_{\alpha_0+\alpha}<\mu_{\alpha_0}\cos\alpha$. For the remainder of this proof we fix $\alpha>0$ so that for all $\alpha_0\in[0,2\pi]$ we have \begin{equation}\label{eq:alpha_choice} \lambda^{-1}\mu_{\alpha_0+2\alpha}<\mu_{\alpha_0}\cos(2\alpha). \end{equation} Let $\ell_\alpha(0)$ denote the semi-infinite line starting at the origin with angle $\alpha$ to the horizontal axis. In a first step, we argue that if type~2 occupies all sites in a thick strip, then type 2 will almost surely occupy all but finitely many sites below the line $\ell_\alpha(0)$. Pick $k$ large so that $\lambda^{-1}\mu^{\sss (k)}<\mu$, which is possible by \eqref{mu_strip}. Let $H_m$ be the event that type~2 eventually occupies the site $(m,k)$, and that at the time at which this occurs type~1 has not yet reached the vertical line $L(m)=\{(x,y)\in\mathbb{Z}^2:x=m\}$. The choice of $k$ assures that, given that type~2 captures all but finitely many sites in the strip $S_k^+$, the probability of $H_m$ tends to one as $m$ tends to infinity. Write $\ell_{2\alpha}(m,k)$ for the semi-infinite line starting at the point $(m,k)$ with angel $2\alpha$ to the horizontal line through $(m,k)$. By~\eqref{eq:alpha_choice}, we have that $\lambda^{-1}\mu_{2\alpha}< \mu\cos(2\alpha)$, and hence that the asymptotic type 2 time from $(m,k)$ to a point on $\ell_{2\alpha}(m,k)$ far from $(m,k)$ is strictly smaller than the type 1 passage time from $L(m)$ to the same point; see Figure \ref{fig4}. \begin{figure}[htbp] \begin{center} \begin{tikzpicture}[scale=.5] \draw[->] (-5,-1) -- (9,-1); \draw[->] (-4,-2) -- (-4,5); \draw[dashed] (0,-1) -- (0,5); \draw[dashed] (-4,0) -- (9,0); \draw (-5,0) node[anchor=west] {$k$}; \draw (0,-1) node[anchor=north] {$m$}; \fill[fill=black] (0,0) circle (.125); \fill[fill=black] (5.6,3) circle (.125); \draw[thick] (0,0) -- (7.5,4); \draw (7.5,4) node[anchor=north west] {$\ell_{2\alpha}(m,k)$}; \draw (1,0) arc [start angle=0, end angle=27, radius=1]; \draw (1.1,0.4) node[anchor=west] {$2\alpha$}; \draw[dashed] (0,3) -- (5.6,3); \draw (2.2,1.8) node[anchor=west] {$x$}; \draw (1,3.3) node[anchor=west] {$x\cos(2\alpha)$}; \end{tikzpicture} \end{center} \caption{The line $\ell_{2\alpha}(m,k)$.} \label{fig4} \end{figure} (Here, we say that a point $z\in{\mathbb R}^2$ is infected when the closest point in ${\mathbb Z}^2$ is infected.) Let $G_m^{\sss2\alpha}$ denote the event that, starting from a configuration in which $(m,k)$ is of type 2 and the rest of the line $L(m)$ is of type 1, every point along the line $\ell_{2\alpha}(m,k)$ is eventually captured by type 2. A similar argument as that used to prove Lemma~\ref{lma:chance} then shows that $G_m^{\sss2\alpha}$ occurs with positive probability. The ergodic theorem implies that $G_m^{\sss2\alpha}$ occur for a positive density of all $m\ge1$, almost surely, and since the conditional probability that $H_m$ occurs, given that type~2 takes the strip, tends to one, their intersection will occur for some (large) value of $m$ almost surely. The occurrence of $H_m\cap G_m^{\scriptscriptstyle 2\alpha}$ guarantees that type 2 captures the whole line $\ell_{2\alpha}(m,k)$, and consequently that the whole area below the line $\ell_{2\alpha}(m,k)$ is captured by type 2. Since $\ell_\alpha(0)$ eventually enters this region, we conclude that if type~2 captures all but finitely many sites in $S_k^+$ (and $k$ is large), then almost surely type~2 captures all but finitely many sites in the cone below the line $\ell_\alpha(0)$. In a second step we show that for any $\alpha_0>0$, if type 2 occupies all but finitely many vertices in the $\alpha_0$-cone below the line $\ell_{\alpha_0}(0)$, then the same is true for the $(\alpha_0+\alpha)$-cone below the line $\ell_{\alpha_0+\alpha}(0)$, almost surely. Since $\alpha_0$ is arbitrary, this will complete the proof of the lemma. We repeat the argument above, and let $v_m$ denote the point on $\ell_{\alpha_0}(0)$ at distance $m$ from the origin, write $\ell_{2\alpha}^{\alpha_0}(m)$ for the semi-infinite line starting at $v_m$ with angel $2\alpha$ to $\ell_{\alpha_0}(0)$, and let $\bar{\ell}_{\alpha_0}(m)$ be the line through $v_m$ that is orthogonal to $\ell_{\alpha_0}(0)$; see Figure \ref{fig5}. \begin{figure}[htbp] \begin{center} \begin{tikzpicture}[scale=.5] \draw[->] (-1,0) -- (12,0); \draw[->] (0,-1) -- (0,6); \draw (0,0) -- (10,2.5); \draw (9,1.6) node[anchor=west] {$\ell_{\alpha_0}(0)$}; \draw (4.8,0) -- (3.53,5); \draw (4.2,5.8) node[anchor=east] {$\bar{\ell}_{\alpha_0}(m)$}; \draw (1.5,0) arc [start angle=0, end angle=20, radius=1]; \draw (1.5,0.22) node[anchor=west] {$\scriptstyle\alpha_0$}; \draw (4.5,1.125) -- (6.5,5.5); \draw (5.5,6.2) node[anchor=west] {$\ell_{2\alpha}^{\alpha_0}(m)$}; \draw (5.5,1.375) arc [start angle=0, end angle=60, radius=1]; \draw (5.2,2.1) node[anchor=west] {$\scriptstyle2\alpha$}; \fill[fill=black] (4.5,1.125) circle (.125); \end{tikzpicture} \end{center} \caption{Lines through the point $v_m$.} \label{fig5} \end{figure} Now, if type 2 occupies all but finitely many vertices in the $\alpha_0$-cone, then its asymptotic speed in direction $\alpha_0$ is determined by $\lambda^{-1}\mu_{\alpha_0}$. Hence, if type~2 occupies all but finitely many vertices in the $\alpha_0$-cone, then the event $H_m^{\alpha_0}$ that type 1 has not yet reached $\bar{\ell}_{\alpha_0}(m)$ when type 2 reaches $v_m$ has probability tending to one as $m\to\infty$. Furthermore, by~\eqref{eq:alpha_choice} it again follows that the type~2 time from $v_m$ to a point far along the line $\ell_{2\alpha}^{\alpha_0}(m)$ is with high probability strictly smaller than the type~1 passage time from $\bar{\ell}_{\alpha_0}(m)$ to the same point. Again repeating the argument in the proof of Lemma~\ref{lma:chance}, we may show that the event $G_m^{\scriptscriptstyle\alpha_0,2\alpha}$ that the whole line $\ell_{2\alpha}^{\alpha_0}(m)$ is captured by type 2, when starting from a configuration where $v_m$ is of type 2 and the rest of the sites on or to the left of the line $\bar{\ell}_{\alpha_0}(m)$ is of type 1, occurs with positive probability. Appealing to the ergodic theorem we again find that, given that type~2 takes all but finitely many sites in the $\alpha_0$-cone, the event $H_m^{\alpha_0}\cap G_m^{\alpha_0,2\alpha}$ will occur for some (large) $m$, almost surely, and so type~2 will occupy all but finitely many sites in the $(\alpha_0+\alpha)$-cone below the line $\ell_{\alpha_0+\alpha}(0)$. Since $\alpha_0$ was arbitrary, this completes the proof. \end{proof} \begin{proof}[Proof of {\rm{only if}}-direction of Theorem \ref{thm:main}] The \emph{only if}-direction of Theorem~\ref{thm:main} is an immediate consequence of Lemmas~\ref{lma:strip} and~\ref{lma:speed}. \end{proof}
\section{Algebraic identities} In this section, we prove \begin{proposition}\label{prop:dichotomy} For all $p\in(0,1)$, $q=1$ or $q=\frac1{\sqrt p}-1$. In particular, $q=1$ if $p\le\frac14$. \end{proposition} Let us first recall a key identity from \cite{haslegrave}, relating $p$, $q$ and \[r\mathrel{\mathop:}=\P((\vec\bullet_1\rightarrow\dot\bullet)\wedge(0\leftarrow\bullet)).\] \begin{lemma}[{\cite[Lemma 2]{haslegrave}}]\label{lemma1} $q=\frac{1-p}2(1+q)+r(1-q)+pq^3$. \end{lemma} The conclusion will follow from the next lemma: \begin{lemma}\label{lemma2} $r=\frac12pq^2$. \end{lemma} \begin{proof}[{Proof of Proposition~\ref{prop:dichotomy}}] Combining Lemmas~\ref{lemma1} and~\ref{lemma2} yields immediately the equation \[0=1-q-p-pq+pq^2+pq^3\] hence \[0=1-q-p(1+q-q^2-q^3 =(1-q)(1-p(1+q)^2),\] implying, since $q\ge0$, that either $q=1$ or $q=\frac1{\sqrt p}-1$. Since $q\le1$, we conclude that $q=1$ when $p\le1/4$. \end{proof} \newcommand{\cev}[1]{\reflectbox{\ensuremath{\vec{\reflectbox{\ensuremath{#1}}}}}} \begin{proof}[Proof of Lemma 2] Let us denote by $y_0$ the location of the first particle that reaches 0, if any, and by $y_1$ the location of the particle that annihilates with the first particle $\bullet_1$, if any. For any configuration $\omega$ of particle locations and speeds in $\{\vec\bullet_1\to\bullet\}$, denote by ${\rm rev}(\omega)$ the configuration obtained by reversing the interval $[x_1,y_1]$, that is, the configuration where particles outside $[x_1,y_1]$ are those of $\omega$, and particles inside $[x_1,y_1]$ are symmetric to those of $\omega$ with respect to $\frac{x_1+y_1}2$ and with opposite speeds. For $\omega$ in the event defining $r$, that is to say $\omega\in\{0\leftarrow\bullet\}\cap\{\vec\bullet_1\rightarrow\dot\bullet\}$, we clearly have ${\rm rev}(\omega)\in\{0\leftarrow\bullet\}\cap\{\dot\bullet_1\leftarrow\bullet\}$, and notice also that in this case the first bullet reaches $y_1$ before the particle initially at $y_0$ does, i.e.\ $y_1-x_1<y_0-y_1$, and this also holds for ${\rm rev}(\omega)$. Since conversely, for $\omega\in \{0\leftarrow\bullet\}\cap\{\dot\bullet_1\leftarrow\bullet\}\cap\{y_1-x_1<y_0-y_1\}$, we have ${\rm rev}(\omega)\in\{0\leftarrow\bullet\}\cap\{\vec\bullet_1\rightarrow\dot\bullet\}$, we conclude that ${\rm rev}$ is a bijection between $\{0\leftarrow\bullet\}\cap\{\vec\bullet_1\rightarrow\dot\bullet\}$ and $\{0\leftarrow\bullet\}\cap\{\dot\bullet_1\leftarrow\bullet\}\cap\{y_1-x_1<y_0-y_1\}$. Because ${\rm rev}$ preserves the measure, it follows that \[\P\big((0\leftarrow\bullet)\wedge(\vec\bullet_1\rightarrow\dot\bullet)\big)=\P\big((0\leftarrow\bullet)\wedge(\dot\bullet_1\leftarrow\bullet)\wedge(y_1-x_1<y_0-y_1)\big).\] We have $ \{0\leftarrow\bullet\}\cap\{\dot\bullet_1\leftarrow\bullet\}=\{\dot\bullet_1\leftarrow\bullet\}\cap\{y_1\leftarrow\bullet\}_{(y_1,\infty)}$, so that, conditional on that event, the distances $y_1-x_1$ and $y_0-y_1$ are independent and have the same distribution, which is atomless. Therefore, \[\P\big((0\leftarrow\bullet)\wedge(\dot\bullet_1\leftarrow\bullet)\wedge(y_1-x_1<y_0-y_1)\big)=\frac12\P\big((0\leftarrow\bullet)\wedge(\dot\bullet_1\leftarrow\bullet)\big).\] To conclude, we finally have \[\P\big((0\leftarrow\bullet)\wedge(\dot\bullet_1\leftarrow\bullet)\big)=\P\big((\dot\bullet_1\leftarrow\bullet)\wedge(y_1\leftarrow\bullet)_{(y_1,\infty)}\big)=pq^2.\] \end{proof} \section{A priori regularity properties} Let us prove the following result, which in combination with Proposition~\ref{prop:dichotomy} immediately gives Theorem~\ref{thm:main}. \begin{proposition}\label{prop:connectivity} For all $p\in(\frac14,1)$, $\theta(p)>0$. \end{proposition} The proof follows from the two lemmas below. These lemmas respectively rely on two different characterizations of the supercritical phase $\{p\st\theta(p)>0\}$ by means of sequences of conditions about finite subconfigurations. Let us already warn the reader that the definition and properties of the more involved characterization are postponed until the next section. \begin{lemma}\label{lem:subcrit_open} The set of subcritical parameters $\{p\in(\frac14,1)\st\theta(p)=0\}$ is open. \end{lemma} \begin{lemma}\label{lem:supercrit_open} The set of supercritical parameters $\{p\in(\frac14,1)\st \theta(p)>0\}$ is open. \end{lemma} \begin{proof}[{Proof of Proposition~\ref{prop:connectivity}}] As a conclusion of the above lemmas, the set $A=\{p\in(\frac14,1)\st\theta(p)=0\}$ is both open and closed in $(\frac14,1)$. By connectivity of this interval, it follows that either $A=(\frac14,1)$ or $A=\emptyset$. Since we already know (cf.~\cite{sidoravicius-tournier}) that $A\subset(\frac14,\frac13)$, we deduce that $A=\emptyset$. \end{proof} \begin{proof}[{Proof of Lemma~\ref{lem:subcrit_open}}] We have $q=\limup_k q_k$ where, for all $k\in\mathbb{N}$, \[q_k=\P((0\leftarrow\bullet)_{[0,x_k]}),\] which gives, using Proposition~\ref{prop:dichotomy}, \begin{align*} \{p\in(\frac14,1)\st\theta(p)=0\} & =\{p\in(\frac14,1)\st q=1\}\\ & =\{p\in(\frac14,1)\st q>\frac1{\sqrt p}-1\}=\bigcup_{k\in\mathbb{N}}\{p\in(\frac14,1)\st q_k>\frac1{\sqrt p}-1\}, \end{align*} and each $q_k$ depends only on a configuration of $k$ particles, hence by conditioning on the speeds of these particles we see that $q_k$ is a polynomial in $p$ and therefore is continuous. The lemma follows. \end{proof} \begin{proof}[{Proof of Lemma~\ref{lem:supercrit_open}}] Using the notation $N_k$ from the next section, the upcoming Proposition~\ref{prop:characterization} gives \[\{p\in(\frac14,1)\st\theta(p)>0\}=\bigcup_{k\in\mathbb{N}}\Big\{p\in(\frac14,1)\st\mathbb{E}[N_k]>0\Big\}, \] so that the lemma follows by noticing that, as can be seen by conditioning on the speeds of the $k$ particles, the function $p\mapsto\mathbb{E}[N_k]$ is polynomial hence continuous. \end{proof} \section{Characterization of the supercritical phase} While Lemma~\ref{lem:subcrit_open} relies on the simple monotone approximation $q=\limup_k q_k$, where for all $k\in\mathbb{N}$ the probabilities $q_k=\P((0\leftarrow\bullet)_{[0,x_k]})$ depend only on a configuration of $k$ particles, Lemma~\ref{lem:supercrit_open} relies on a formally similar but more involved characterization. This characterization is already alluded to in the first of the final remarks of~\cite{sidoravicius-tournier} as a way to numerically upper bound $p_c$. Given its importance in the present proof, we give it here a more thorough presentation, and show it is necessary and sufficient. For all $k\in\mathbb{N}$, consider a random configuration containing only the $k$ bullets $\bullet_1,\ldots,\bullet_k$ (initially located at $x_1,\ldots,x_k$), and denote by $N_k$ the difference between the number of surviving stationary particles and the number of surviving left-going particles: letting $I_k=[x_1,x_k]$, \[N_k\mathrel{\mathop:}=\sum_{i=1}^k({\bf 1}_{\dot\bullet_i}-{\bf 1}_{\cev\bullet_i}){\bf 1}_{(\bullet\not\rightarrow \bullet_i)_{I_k}\wedge(\bullet_i\not\leftarrow \bullet)_{I_k}}\] In the following, the event in the last indicator function will be written ``$(\bullet_i\text{ survives})_{I_k}$''. \begin{proposition}\label{prop:characterization} For all $p\in(0,1)$, $\theta(p)>0$ $\Leftrightarrow$ $\exists k\ge1,\ \mathbb{E}[N_k]>0$. \end{proposition} \paragraph{\bf Remark.} The fact that $\mathbb{E}[N_1]=\frac12(3p-1)$ recovers (cf.~\cite{sidoravicius-tournier}) that $\theta(p)>0$ when $p>1/3$. The proof of this fact in~\cite{sidoravicius-tournier} is in fact the scheme for the general one given below. Considering $\mathbb{E}[N_2]$ gives the same condition, however $\mathbb{E}[N_3]=3p^3+7p^2\overline p-\frac32p\overline p^2-8\overline p^3$ (where $\overline p=\frac{1-p}2$) yields the value $0.32803$ from the remark in~\cite{sidoravicius-tournier}. As the proposition shows, pushing this method further would give arbitrarily good numerical approximations of $p_c$. Let us remind that, although such approximations are rendered pointless by Theorem~\ref{thm:main}, the \textit{existence} of this method still is a theoretical tool in the proof of the said theorem. \begin{proof} \noindent{\it Direct implication.} Assume that $\theta(p)>0$. Let us decompose $N_k=\dot N_k-\cev N_k$, where $\dot N_k$ and $\cev N_k$ respectively denote the number of stationary and left-going particles among $\bullet_1,\ldots,\bullet_k$ that survive in restriction to $[x_1,x_k]$. For any integer $i$, the event $\{\dot\bullet_i\text{ survives}\}_I$ decreases with the interval $I$ (containing $x_i$). If indeed $\bullet_i$ is stationary and is annihilated by a bullet inside an interval $I$, then introducing new bullets outside $I$ can possibly change the side from which $\bullet_i$ is hit, but not the fact that this bullet is hit. In particular, the number of stationary bullets among $\bullet_1,\ldots,\bullet_k$ that survive in restriction to $[x_1,x_k]$ is larger than or equal to the number of such bullets that survive in ``restriction'' to the whole real line. Taking expectations, by translation invariance of the process on $\mathbb{R}$ this gives \[\mathbb{E}[\dot N_k]\ge k \P\big((\dot\bullet_1\text{ survives})_\mathbb{R}\big)=kp\theta(p),\] hence in particular $\mathbb{E}[\dot N_k]\to+\infty$ as $k\to\infty$. On the other hand, $\mathbb{E}[\cev N_k]$ is uniformly bounded in $k$. Indeed, $\cev N_k$ clearly grows with $k$, and its limit $\cev N_\infty=\limup_k \cev N_k$ is the number of surviving left-going particles in $(0,\infty)$, and this number has geometric distribution with parameter $1-q>0$ (notice indeed that the configuration on the right of a surviving left-going particle is identically distributed as the configuration on $(0,\infty)$, up to translation) and therefore is integrable. We conclude that $\mathbb{E}[N_k]=\mathbb{E}[\dot N_k]-\mathbb{E}[\cev N_k]\ge kp\theta(p)-\frac q{1-q}\to +\infty$ as $k\to\infty$, hence $\mathbb{E}[N_k]>0$ for large~$k$. \noindent{\it Reverse implication.} Assume now that $\mathbb{E}[N_k]>0$ for some $k\ge1$. For positive integers $i<j$, define $N(i,j)$ in the same way as $N_k$ except that only the bullets $\bullet_i,\ldots,\bullet_j$ are considered instead of $\bullet_1,\ldots,\bullet_k$. With this notation, $N_k=N(1,k)$. This function $N$ satisfies ``almost'' a superadditivity property. \begin{lemma}\label{lem:superadditivity} Let $k<l$ be positive integers. For any configuration $\omega$ which, in restriction to $[x_1,x_k]$, has no surviving right-going particle, we have \[N(1,l)\ge N(1,k)+N(k+1,l).\] \end{lemma} \begin{proof}[{Proof of Lemma~\ref{lem:superadditivity}}] When the configurations in $I=[x_1,x_k]$ and in $J=[x_{k+1},x_l]$ are combined, the surviving left-going particles from $J$ can interact with particles from $I$. Each of them either annihilates with a surviving stationary particle (hence giving the same $0$ contribution to both hand sides) or annihilates with a stationary particle that was annihilated in restriction to $I$ hence unleashes its right-going peer which can either survive (making the left-hand side greater by 1), annihilate with a surviving left-going particle (making the left-hand side greater by 2), annihilate with a surviving stationary particle (keeping sides equal) or again annihilate with a stationary particle that was annihilated in restriction to $J$ hence unleash its left-going peer which is offered the same range of possibilities as the particle we first considered. Thus in any case the identity remains satisfied after the effect of each of these left-going particles is taken into account. \end{proof} We shall progressively explore the configuration, starting from 0 and going to the right, by repeating the following two steps: first, discover the next $k$ particles, and then discover the least necessary number of particles until there is no surviving right-going particle in the whole discovered region. We will denote by $K_0=0, K_1, K_2,\ldots$, the number of particles discovered in total after each iteration, and by $\widetilde N^{(1)}(=N_k),\widetilde N^{(2)},\ldots$ the quantity computed analogously to $N_k$ but on the newly discovered block of $k$ particles at each iteration, i.e., for all $n$, $\widetilde N^{(n+1)}=N(K_n+1,K_n+k)$. Let us explain the first iteration in some more detail. We start by considering the first $k$ particles. Let $\widetilde N^{(1)}=N(1,k)$. If, in the configuration restricted to $[x_1,x_k]$, no right-going particle survives, then we let $K_1=k$. Otherwise, let $\tau_0$ denote the index of the leftmost surviving right-going particle, and appeal for instance to~\cite[Lemma 3.3]{sidoravicius-tournier} to justify the existence of a minimal $\gamma_1$ such that the event $\{\vec\bullet_{\tau_0}\to\bullet_{\gamma_1}\}_{[\tau_0,\gamma_1]}$ happens, and let $K_1=\gamma_1$. By definition we have that, in both cases, in restriction to $[x_1,x_{K_1}]$, there is no surviving right-going particle and $\widetilde N^{(1)}=N(1,K_1)$. We then keep iterating this construction: define $\widetilde N^{(2)}=N(K_1+1,K_1+k)$, and keep exploring on the right of $\bullet_{K_1+k}$ until no surviving right-going particle remains, define $K_2$ to be the index that was reached, and so on. By this construction, the random variables $\widetilde N^{(n)}$ are i.i.d.\ with same distribution as $N_k$, and for all $n$ we have $N(1,K_n+k)=N(1,K_{n+1})$ and there is no surviving right-going particle in restriction to $[x_1,x_{K_{n+1}}]$. Thus, by repeatedly using the lemma, we have for all $n$, \[N(1,K_n)\ge \widetilde N^{(1)}+\cdots+\widetilde N^{(n)}.\] However, by the assumption and the law of large numbers, with positive probability $\widetilde N^{(2)}+\cdots+\widetilde N^{(n)}>0$ for all $n\ge2$. Therefore, still with positive probability, it may be that the first $k$ particles are stationary (hence $\widetilde N^{(1)}=k$) and that $\widetilde N^{(1)}+\cdots+\widetilde N^{(n)}> k$ for all $n\ge2$, so that $N(1,K_n)> k$ for all $n\ge2$. This event ensures that 0 is never hit: indeed after the $n$-th iteration of the exploration (for $n\ge2$) there are at least $k+1$ surviving stationary particles due to the definition of the event, but at most $k$ of them can be annihilated by the particles discovered between $K_n$ and $K_{n+1}$, hence by induction the first stationary particle survives forever and prevents 0 from being hit. Thus $\theta(p)>0$. \end{proof} \paragraph{\bf Remark} In the discrete ballistic annihilation model introduced in~\cite{junge2}, the analog of Lemma 2 is wrong due to triple collisions. The same arguments indeed give \[\hat r=\P_\mathbb{Z}(D>D')p\hat q^2<\frac12 p\hat q^2,\] where $D$ is the location of the first particle that reaches zero, and $D'$ is an independent copy of $D$. Since $D$ is integer valued, it holds more precisely that \[\P_\mathbb{Z}(D>D')=\frac12\P_\mathbb{Z}(D\ne D')=\frac12\big(1-\P_\mathbb{Z}(D=D')\big)\] and $\P_\mathbb{Z}(D=D')$ can be interpreted as the probability that, on the full line, a given stationary particle is involved in a triple collision. From $\hat r<\frac12p\hat q^2$, the computation done in the proof of Theorem~\ref{thm:main} shows that, if $\hat q<1$, then $0<1-p(1+\hat q)^2$, hence $\hat q<\frac1{\sqrt p}-1$ and thus the surviving probability of a stationary particle on the full line satisfies \[\psi(p)= (1-\hat q)^2>\Big(2-\frac1{\sqrt p}\Big)^2=\theta(p).\] Thanks to this dichotomy, we can argue as in the original model that, for all $p>\frac14$, $\psi(p)>0$ hence furthermore $\psi(p)>\theta(p)$. This comparison was heuristically expected in~\cite{junge2}. \bibliographystyle{acm}
\section{Introduction} In single field inflation, only one type of field, the inflaton, dominates the overall energy momentum density of the universe. At the background level, this field has some time dependence which leads to a time dependent cosmological background $H(t)$. This background will not remain invariant under time diffeomorphisms. However the time diffeomorphisms are a symmetry of the action. On such a time dependent background, there exists modes of a physical scalar perturbation which transforms nonlinearly under further time diffeomorphisms, making sure that the action itself remains invariant. These scalar modes are the inflationary scalar perturbations, observed as temperature fluctuations in the Cosmic Microwave Background (CMB). They lead to formation of protogalaxies in the early universe, on an otherwise homogeneous background. The present day universe is filled with many other types of matter, such as the particles of standard model, dark matter and dark energy. These correspond to perturbations of different types of matter fields, not all of which are scalar. It is an open question to understand how and when these fields start playing an important role in the universe overtime. It could be that a number of fields, nontrivial kinetic terms or non-minimal couplings are responsible for the underlying mechanism of inflation itself. While these cases are being more and more constrained by observations within a window of time during inflation \cite{Akrami:2018odb}, trying to understand couplings of the inflaton to other species is what is at hand for understanding the passage to other matter sources that are present in today's universe. It is likely that perturbations of noninflationary species begin to populate the universe after the end of Inflation rather then during \cite{Armendariz-Picon:2017llj}. The period of inflation corresponds to an accelerated expansion, with a weakly time dependent background $H_I(t)$ that resembles the approximate de Sitter spacetime. Single field inflation ends when the Hubble parameter drops below the mass of the inflaton field $m_\phi$, $H_I(t_{end})\leq m_\phi$. At times of order $m_\phi t\gg 1$, the Firedmann equations give a matter dominated solution with oscillatory corrections whose frequency is set by the mass $m_\phi$. This era is referred to as preheating, during which the time dependence of the background $H_p(t)$ is strong. This time dependence works into the couplings of the inflaton field with perturbations of other species, and leads to their resonant growth leading to a more efficient production of the reheating modes compared to perturbative decay alone \cite{Kofman:1997yn}. At the end of this intermediate stage, the inflaton will decay into fields lighter then itself, giving rise to a radiation dominated phase. In \cite{Ozsoy:2015rna, Giblin:2017qjp}, general interactions for the perturbations of the inflaton and a scalar reheating field were studied during preheating with effective field theory (EFT) methods. It was noticed that studying these perturbations during preheating without addressing the dynamics that can give rise to the background $H_p(t)$ in the fashion of the EFT of quasi single field inflation \cite{Noumi:2012vr}, gives more insight then an EFT for the dynamics of the two species, which have been rather useful in the case of inflation \cite{Weinberg:2008hq,Assassi:2013gxa}. In this EFT approach, being associated with the species that drives the time dependence of the background, scalar inflationary perturbations $\delta g^{00}$ are Goldstone modes that nonlinearly realize time diffeomorphism invariance while reheating sector is introduced as an unspecified scalar perturbation $\chi$. This difference in their nature, leads to different interactions for the different species. How the background behavior $H_p(t)$ enters the quadratic self couplings of each species determines the resonant particle production, and the hierarchy $H_p(t)\ll m_\phi$ between the background scales, leads to hierarchies among the scales important for the dynamics of the perturbations \cite{Giblin:2017qjp}. In addition to interactions that lead to particle production, the EFT of preheating involves three different types of derivative couplings among the inflationary and reheating perturbations. The focus of this work are these derivative interactions. In the first work to address derivative couplings of the inflaton and a scalar reheating field, through an analysis of instability bands it was observed that the derivative coupling of interest does not promise very efficient production of reheating modes \cite{ArmendarizPicon:2007iv}. Among the three derivative EFT couplings, two of them describe energy scales. On a complimentary line to the conventional analyses of instability bands, the main effort of the present work is to understand which of the two species of perturbations occur as the effective degree of freedom at what scales, by considering non relativistic limits and using the methods of \cite{Baumann:2011su}. The conclusion is that, with interactions of the type considered in section \ref{sec:beta1}, the effective lowest energy modes are the inflaton modes. For these type of couplings, the reheating perturbations work to adjust the dispersion relation of the inflaton rather then being present themselves. This suggests that the role of the reheating sector here is to assist the inflationary sector rather then being likely to be produced. The low energy regime of these couplings are named as the regime of Hidden Preheating, in the sense that the presence of the reheating field is hidden. The original example of derivative couplings falls into this category. The situation is reversed with the reheating perturbations being the low energy modes whose dispersion relation is adjusted by the inflaton modes in the presence of couplings considered in section \ref{sec:beta3}. However the couplings of sections \ref{sec:beta2} and \ref{sec:beta3} give rise to further modifications in the dispersion relation that exist even at scales where the inflaton and reheating modes propagate freely. Similar to the polynomial couplings of light fields to heavy ones giving rise to corrections to the mass of the light fields at low energies, derivative couplings give rise to corrections for the dispersion relation of light modes at low scales. This suggests that these later kind of couplings signal the presence of more fields that are actually present and interact with the inflaton and the reheating sectors, but who are themselves too heavy to appear as propagating degrees of freedom The text is organized as follows. The Effective Field Theory formalism of cosmological perturbations and how it captures preheating is reviewed in section \ref{sec:EFTreview}. Section \ref{sec:background scales} together with appendix \ref{ap:background} review the general properties of the preheating background $H_p(t)$ and scales associated with important processes in the EFT. The main consequences of the derivative couplings are explored in section \ref{sec:Hidden} and section \ref{sec:conc} summarizes the main results. \section{Review of EFT of Cosmological Perturbations} \label{sec:EFTreview} Consider cosmological backgrounds as determined by the behavior of the Hubble parameter, $H(t)$, at each epoch. From inflation to dark energy domination, each one of the cosmological backgrounds posses time dependence of different strength. From the pursuit of particle physics, some field content that contributes as the energy momentum source will be responsible for this time dependence. The inflaton, $\phi_0(t)$ for example, is one such field that contributes as a homogeneous scalar source during and at the end of inflation. The Hubble parameter is related to the field content through the Friedmann equations, which in the case of a single scalar field read \begin{subequations} \begin{align} 6m^2_{pl}H^2&=\dot{\phi}_0^2+2V(\phi_0)\\ 2m^2_{pl}\dot{H}&=-\dot{\phi}_0^2. \end{align} \end{subequations} Due to their time dependence, such backgrounds do not respect time diffeomorphism invariance. There exists a scalar degree of freedom $\delta\phi(\vec{x},t)$ or $\delta g^{00}$, associated with such a background, that keeps track of the difference in the rate of expansion between two points in space depending on how the time coordinate is defined in each point \cite{Hawking:1982cz}. This scalar degree of freedom transforms nonlinearly under time diffeomorphisms. As $t\to \tilde{t}=t+\xi^0$, the scalar perturbations transform according to \begin{subequations}\label{timediffofscalar}\begin{align} \Delta\delta\phi&=-\xi^0\dot{\phi}_0,\\ \Delta\delta g_{00}&=-\left[2\bar{g}_{00}\dot{\xi}^0+\dot{\bar{g}}_{00}\xi^0\right]. \end{align} \end{subequations} Equations \eqref{timediffofscalar} imply that the time coordinate can be chosen such that the scalar perturbation is adjusted to appear completely in the metric via $g^{00}$ or as a field perturbation $\delta\phi$, but it can never be completely set to zero. This degree of freedom is the Goldstone boson that transforms under time diffeomorphisms in such a way so that the action on the whole remains invariant, that is the parameter $\xi^0$ never appears after a transformation. Each epoch posses such a Goldstone mode associated to the type of field that dominates the energy momentum density. The first effective field theory to generalize the interactions of such a Goldstone mode at low energies was developed to study violations of the null energy condition \cite{Creminelli:2006xe}. Understanding energy transfer from the matter source that dominates the background energy momentum density to another matter species, entails two different scalar fields. In the early stages of preheating, the inflaton is the dominant field and hence the Goldstone mode encodes the perturbation to the inflaton field. The other matter source, which is considered to be another scalar field $\chi$ here, can be introduced at the level of perturbations alone. This difference works into the interactions that can be written down for the preheating perturbation and the Goldstone mode. $\chi$ enters the action starting from second order in perturbations, and only inflationary perturbations contribute to $g^{00}$ at linear order The gauge in which the inflaton perturbation appears as part of the metric is referred to as the unitary gauge or the $\zeta$-gauge. Once this gauge is fixed the remaining symmetries are spatial diffeomorphisms. Because within this gauge, time direction is fixed and will not be changed further, the time related index zero can appear explicitly, for instance via $g^{00}$. Such terms with zero indices will transform as scalars under further spatial diffeomorphisms. By making this choice the temporal and spatial indices are separated. Thus spatial indices can also appear without accompanying temporal indices, provided the terms they appear in respect the remaining invariance under spatial diffeomorphims. This means perturbations to extrinsic curvature $\delta K_{ij}$, which transforms as a tensor under spatial diffeomorphisms, can contribute starting from second order via its trace $\delta {K^i}_i$. With these concerns, in the unitary gauge the most general contribution to the action from the inflationary sector is \cite{Cheung:2007st} \begin{align} \label{unitaryinf} \nonumber S_{g}=&\int d^4x\sqrt{-g}\Bigg[\frac{1}{2}m^2_{Pl}R+m^2_{Pl}\dot{H}g^{00}-m^2_{Pl}\left(3H^2+\dot{H}\right)\\ \nonumber &+\frac{M_2(t)^4}{2!}\left(g^{00}+1\right)^2 -\frac{\bar{M}_1(t)^3}{2}\left(g^{00}+1\right)\delta {K^\mu}_\mu-\frac{\bar{M}_2(t)^2}{2}(\delta{K^\mu}_\mu)^2\\ & +\frac{M_3(t)^4}{3!}\left(g^{00}+1\right)^3-\frac{\bar{M}_3(t)^2}{2}\delta{K^\mu}_\nu\delta{K^\nu}{_\mu}+...\Bigg] \end{align} In the first line the coefficients of the linear terms are determined by demanding that variation of this action with respect to the metric give the Friedmann equations at zero order in perturbations. The coefficients of the rest of the terms, which are the higher order perturbation terms, are undetermined. All that can be said of them in general is that they are time dependent and their characteristics convey the properties of the background to the level of perturbations. These terms involve different effects, for instance $M_2$ introduces a sound speed for the inflaton perturbation, where as $\bar{M}_3$ modifies the speed of propagation for the tensor degrees of freedom. The action \eqref{unitaryinf} as it appears includes all terms that respect the symmetries within the unitary gauge. A specific model of interest will involve only some of these terms. The preheating field $\chi$ transforms as a scalar under the remaining possible spatial diffeomorphisms. It can be added to the system with the following terms \cite{Noumi:2012vr} \begin{align} S_\chi=\int d^4 x \sqrt{-g}\left[-\frac{\alpha_1(t)}{2}\partial^\mu\chi\partial_\mu\chi+\frac{\alpha_2(t)}{2}\left(\partial^0\chi\right)^2-\frac{\alpha_3(t)}{2}\chi^2+\alpha_4(t)\chi\partial^0\chi\right] \end{align} Here $\alpha_2$ introduces a sound speed in the preheating sector. Possible effects of $\alpha_2$ on sourcing secondary gravitational waves, and the effects of $\alpha_3$ for $\chi$ production through resonance were discussed in \cite{Giblin:2017qjp}. Via $\delta g_{\mu\nu}$, the terms above involve mixing between the inflationary and preheating sectors. In addition to these there can also be the following voluntary contributions \cite{Noumi:2012vr} \begin{align} S_{g\chi}=\int d^4 x \sqrt{-g}\left[\beta_1(t)\delta g^{00}\chi+\beta_2(t)\delta g^{00}\partial^0\chi+\beta_3(t)\partial^0\chi-(\dot{\beta}_3(t)+3H(t)\beta_3(t))\chi\right]. \end{align} Notice that these later contributions involve derivative couplings between the two sectors. It is these terms that we will focus on in the following. A time diffeomorphism $t\to\tilde{t}=t+\xi^0$ performed to this action, requires the introduction of the scalar $\pi$ which transforms as $\pi\to\tilde{\pi}=\pi-\xi^0$, to guarantee that the parameter $\xi^0$ does not begin to appear in the action. The unitary gauge discussed above corresponds to the gauge where $\pi$ was set to zero. Via such transformations $\pi$ becomes explicit in the action. Following \cite{Noumi:2012vr}, as \begin{align} g^{00}&\to g^{00}+2g^{0\mu}\partial_\mu\pi+g^{\mu\nu}\partial_\mu\pi\partial_\nu\pi\\ \beta_i(t)&\to\beta_i(t+\pi)\\ \partial^0\chi&\to\partial^0\chi+g^{\mu\nu}\partial_\mu\chi\partial_\nu\pi\\ \int d^4x\sqrt{-g}&\to\int d^4x\sqrt{-g}. \end{align} the action for the inflationary sector becomes \begin{align} \label{pigaugeinf} \nonumber S_g=&\int d^4 x \sqrt{-g}\Bigg[\frac{1}{2}m^2_{Pl}R-m^2_{Pl}\left(3H^2(t+\pi)+\dot{H}(t+\pi)\right)+\\ \nonumber &+m^2_{Pl}\dot{H}(t+\pi)\left((1+\dot{\pi})^2g^{00}+2(1+\dot{\pi})\partial_i\pi g^{0i}+g^{ij}\partial_i\pi\partial_j\pi\right)\\ &+\frac{m_2(t+\pi)^4}{2!}\left((1+\dot{\pi})^2g^{00}+2(1+\dot{\pi})\partial_i\pi g^{0i}+g^{ij}\partial_i\pi\partial_j\pi+1\right)^2+...\Bigg],\end{align} the reheating sector takes the form \begin{align} S_\chi=\int d^4 x \sqrt{-g}\Bigg[&-\frac{\alpha_1(t+\pi)}{2}\partial^\mu\chi\partial_\mu\chi+\frac{\alpha_2(t+\pi)}{2}\left(\partial^0\chi+g^{\mu\nu}\partial_\mu\chi\partial_\nu\pi\right)^2\\ &-\frac{\alpha_3(t+\pi)}{2}\chi^2+\alpha_4(t+\pi)\chi\left(\partial^0\chi+g^{\mu\nu}\partial_\mu\chi\partial_\nu\pi\right)\Bigg] \end{align} and the action that describes further mixings at second order becomes \begin{align} & S^{(2)}_{g\chi}=\int d^4 x\sqrt{-g}\Bigg[ \beta_1(t+\pi)\left(\delta g^{00}+2\partial^0\pi+\partial_\mu\pi\partial^\mu\pi\right)\chi\\ &+\beta_2(t+\pi)\left(\delta g^{00}+2\partial^0\pi+\partial_\mu\pi\partial^\mu\pi\right)\left(\partial^0\chi+\partial_\nu\pi\partial^\nu\chi\right)\\ &+\beta_3(t+\pi)\left(\partial^0\chi+\partial_\mu\pi\partial^\mu\chi\right)-\left(\dot{\beta}_3(t+\pi)+3H(t+\pi)\beta_3(t+\pi)\right)\chi\Bigg].\end{align} Starting from the unitary gauge one can move to the gauge in which inflationary perturbations appear explicitly as $\delta \phi$ through the diffeomorphism with parameter $\xi^0=-\pi$. The two variables $\delta\phi$ and $\pi$ both denote perturbations to the inflaton and are related to each other via \begin{equation} \delta\phi=\pi_c=\frac{\pi}{c_\pi}\sqrt{-2m^2_{pl}\dot{H}}=\frac{\pi}{c_\pi}\dot{\phi}_0.\end{equation} Even though the action is constructed by making a gauge choice first, the system on the whole always respects invariance under all of the diffeomorphisms. Time diffeomorphims are gauge symmetries. In the presence of backgrounds with time dependence, there is a divergent charge associated with them. This implies that the global time translation invariance is also not respected by the background. Given the isotropy and homogeneity of the background these diffeomorphisms can be thought of as approximate gauge or global symmetries. Such backgrounds, where cosmological backgrounds are included, are said to \emph{spontaneously break} time diffeomorphism invariance. The scale at which the charge associated with the global time translation invariance becomes ill defined sets the symmetry breaking scale \cite{Cheung:2007st, Baumann:2011su} \begin{equation}\label{symbr} \Lambda_{sb}^2=\sqrt{-2m^2_{pl}\dot{H}c_\pi},\end{equation} where $c^{-2}_\pi=1-\frac{M^4_2}{m^2_{pl}\dot{H}}$. Hence this EFT where scalar inflaton perturbations appear as Goldstone modes of nonlinearly realized time diffeomorphisms is valid below the scale $\Lambda_{sb}$. \section{Background and Scales for Preheating} \label{sec:background scales} If the energy momentum density of the universe is dominated by a single scalar matter field, the behavior of the Hubble parameter at the end of inflation, for times such that $1 \ll m_\phi t$ is \begin{equation} \label{Hpre} H_p=H_m(t)-\frac{3}{4}\frac{H^2_m}{m_\phi}sin(2m_\phi t),\end{equation} as summarized in appendix \ref{ap:background}. Here $m_\phi$ denotes the mass of the inflaton field, who remains to be the dominant matter source in the early stages of preheating. At the end of inflation, whatever may be the potential that drives inflation, the inflaton field oscillates at the minimum of its potential. By then, this potential can be approximated via the Taylor expansion as $V\sim\frac{1}{2}m_\phi^2\phi_0^2$. The mass of the inflaton sets the frequency of these oscillations, which start at times when the Hubble parameter drops below the mass of the inflaton $H_p(t)<m_\phi$. Hence during preheating there are two scales associated with the background, the mass of the inflaton field $m_\phi$ and the Hubble parameter $H_p$. And these scales possess the hierarchy $H_p<m_\phi$ between each other. This hierarchy guarantees that \eqref{Hpre} does not describe a background that oscillates, which would be problematic. Instead the preheating background resembles matter domination with oscillatory contributions which are suppressed by $\frac{H_m}{m_\phi}$. The background \eqref{Hpre} fits a symmetry breaking pattern \begin{equation} H(t)=H_{FRW}(t)+H_{osc}P(\omega t)\end{equation} where $P(\omega t)$ can be any periodic function. This resembles the discrete symmetry breaking pattern described for inflation \cite{Behbahani:2011it}. While inflation corresponds to a weak breaking of time translation invariance and can respect discrete time translation invariance, the strong time dependence of $H_m$ implies that during preheating time translation invariance is completely broken. The time dependence of coefficients $H_{FRW}=H_m$ and $H_{osc}=-\frac{3}{4}\frac{H^2_m}{m_\phi}$ is not weak, but it is required that this time dependence is small compared to the scale of oscillations $\omega=2m_\phi$ \begin{equation} \frac{\dot{H}}{\omega H}\sim\frac{\dot{H}_m}{\omega H_m}\sim\frac{\dot{H}_{osc}}{m_\phi H_{osc}}\ll 1.\end{equation} Thus the hierarchies between scales associated with the preheating background go as \begin{equation} \omega\gg H_p\sim H_m,~~H_m\gg H_{osc},~~\omega H_m\gg \dot{H}_m.\end{equation} These hierarchies imply the following form for the derivatives of the Hubble parameter\footnote{The dominant terms in these derivatives are\\ $\dot{H}_p=-\frac{3}{2}\left(1+cos(2m_\phi t+\Delta)\right)H^2_m,$\\ $\ddot{H}_p=3m_\phi H^2_msin(2m_\phi t+\Delta),$\\ $\dddot{H}_p=6m_\phi^2H^2_mcos(2m_\phi t+\Delta).$\\ $\ddddot{H}_p=-12m_\phi^3H^2_{m}sin(2m_\phi t).$ Since we are focusing on times $m_\phi t\gg1$, the oscillations are frequent enough for us to approximate $\ddot{H}_p$ and $\dddot{H}_p$ by their amplitudes. In the main text we also neglect the overall numerical factors in these amplitudes. Our main objective in the next sections will be to emphasize how the frequency of the oscillations $\omega=2m_\phi$ becomes explicit in the scales of the problem.} \begin{equation} \dot{H}_p\sim -H^2_p,~~\ddot{H}_p\sim\omega H^2_p,~~\dddot{H}_p\sim \omega^2H^2_p.\end{equation} While there is expansion at the background, particle production through energy transfer from the background to the reheating field should be a local process, which respects conservation of total energy density. It is a process that merely transfers energy from one species to another. This locality is achieved by focusing on the flat space limit $a\to1$. This limit implies $\dot{H}\to0$ and needs to be accompanied with the limit $m^2_{pl}\dot{H}\to finite$, to guarantee that the combination of scales that appear in the linear order action with dimensions of energy density remain finite. During preheating this limit also implies $m^2_{pl}H^2\to finite$ as $H\to 0$. The $\alpha_i$ terms lead to particle production. In theory, all the terms of similar dimensions in $S_g$, $S_\chi$ or $S_{g\chi}$ are expected to be of equal strength. In practice, some of these terms are turned off in order to be able to focus on different effects one wishes to address. As the linear order action possess $m^2_{pl}\dot{H}\sim m^2_{pl}H^2$, where the similarity holds during preheating, it is natural to expect all the EFT parameters $\{\alpha_i,M_i,\beta_i\}$, to be proportional to $m^2_{pl}\dot{H}$. Since $m_\phi$ is the leading scale among the scales $m_\phi$ and $H_p$ associated with the background, it can be used to adjust for the dimensions of the EFT parameters. For example $\alpha_3$ has mass dimension $M^2$, while $\alpha_1$ has mass dimension zero. So these EFT parameters can be approximated as \begin{equation} \alpha_1\sim \frac{1}{m^4_\phi}m^2_{pl}\dot{H},\end{equation} while \begin{equation} \alpha_3\sim \frac{1}{m^2_{\phi}}m^2_{pl}\dot{H}.\end{equation} In general the equation of motion for the reheating perturbations is of the form \begin{equation} \ddot{\tilde\chi}_c+\omega_\chi^2(t)\tilde\chi_c=0,\end{equation} where the subscript and tilde denote that the field has been canonically normalized $\tilde{\chi}_c\equiv \sqrt{\alpha_1+\alpha_2}\chi a^{3/2}$. Similarly we also absorb a factor of $a^3$ by defining $\tilde{\pi_c}\equiv a^{3/2}\pi_c$, which in return guarantees that the equation of motion for inflaton perturbations will also be of the form of a canonically normalized harmonic oscillator. To ease notation in calculations that will follow, we also define ${\tilde{m}_\chi}^2\equiv m^2_\chi-\left(\frac{9}{4}H^2+\frac{3}{2}\dot{H}\right)$, and ${\tilde{m}_\chi}^2\equiv m^2_\chi-\left(\frac{9}{4}H^2+\frac{3}{2}\dot{H}\right)$. For canonical quantization, it will be the canonically normalized fields $\tilde{\pi}_c$, $\tilde{\chi}_c$ and their conjugate momenta who satisfy the canonical commutation relations. The frequency $\omega_\chi(t)$ will possess some time dependence coming from the time dependence of $\alpha_i(t)$.\footnote{For the canonically normalized field $\tilde{\chi}_c$, the couplings with the background induce the time dependent mass $m^2_\chi(t)=\frac{\alpha_3(t)-\dot{\alpha}_4(t)}{\alpha_1(t)+\alpha_2(t)}-\frac{1}{2}\frac{\ddot{\alpha}_1+\ddot{\alpha}_2}{\alpha_1+\alpha_2}+\frac{1}{4}\left(\frac{\dot{\alpha_1}+\dot{\alpha}_2}{\alpha_1+\alpha_2}\right)^2$. The frequency of $\tilde{\chi}_c$ modes are $\omega^2_k=c^2_\chi(t)\frac{k^2}{a^2}+\tilde{m}^2_\chi$.} Particle production occurs at times when the time dependence in $\omega_\chi(t)$ becomes nonadiabatic. This is independent from the adiabaticity of the background $H_p(t)$. This time dependence, and hence $\chi$ production, can be sourced purely due to a time dependent sound speed in the reheating sector $c_\chi^2=\frac{\alpha_1}{\alpha_1+\alpha_2}$, or it can be sourced by the couplings between the reheating sector and the background. In the later case, particle production with constant sound speed occurs for modes in the range \cite{Giblin:2017qjp, Sengor:2018hkb} \begin{equation} \label{bckprod} k^2<\frac{1}{c^2_\chi}\left[\left(\frac{\dot{\alpha}_3-\ddot{\alpha}_4}{2}\right)^{2/3}-\frac{\alpha_3-\dot{\alpha}_4}{\alpha_1}\right]\equiv K^2_{bck}\propto \mathcal{O}\left(\frac{1}{c^2_\chi}\frac{m^2_{pl}H^2}{m^2_\phi}\right),\end{equation} which lies below the symmetry breaking scale. \section{Hidden Preheating} \label{sec:Hidden} Up to this point we have reviewed the background behavior and general form of interactions during preheating. Among the EFT parameters, $\alpha_i(t)$ control resonant $\chi_c$ production, while $H(t)$ and $m_i(t)$ affect the behavior of inflationary modes. The coefficients $\beta_i(t)$ denote additional couplings between the inflaton fluctuations and $\chi$. These kinds of interactions are unavoidable if the inflaton and the reheat field are derivatively coupled to each other. In the unitary gauge, these interactions are \begin{equation}\label{hiddenS} S^c_{g\chi}=\int d^4x\sqrt{-g}\left[\beta_1(t)\delta g^{00}\chi+\beta_2(t)\delta g^{00}\partial^0\chi+\beta_3(t)\partial^0\chi-(\dot{\beta}_3(t)+3H(t)\beta_3(t))\chi\right],\end{equation} with the mass dimensions of the parameters being $[\beta_1]=M^3$ and $[\beta_2]=[\beta_3]=M^2$. In the following, these interactions will be the focus of our attention and we will proceed in the $\pi$-gauge with \begin{align} \label{hiddenS1}& S^{(2)}_{g\chi}=\int d^4 x\sqrt{-g}\Bigg[ \beta_1(t+\pi)\left(\delta g^{00}+2\partial^0\pi+\partial_\mu\pi\partial^\mu\pi\right)\chi\\ \label{hiddenS2}&+\beta_2(t+\pi)\left(\delta g^{00}+2\partial^0\pi+\partial_\mu\pi\partial^\mu\pi\right)\left(\partial^0\chi+\partial_\nu\pi\partial^\nu\chi\right)\\ \label{hiddenS3}&+\beta_3(t+\pi)\left(\partial^0\chi+\partial_\mu\pi\partial^\mu\chi\right)-\left(\dot{\beta}_3(t+\pi)+3H(t+\pi)\beta_3(t+\pi)\right)\chi\Bigg].\end{align} Let's begin by focusing on the renormalizable quadratic couplings \begin{align} S^{(2)}_{g\chi}\supset\int& d^4xa^3\Bigg[\beta_1(t)\left(\delta g^{00}\chi-2\dot{\pi}\chi\right)+\beta_2(t)\left(-\delta g^{00}\dot{\chi}+2\dot{\pi}\dot{\chi}\right)\\ &-\delta N\beta_3(t)\dot{\chi}-\dot{\beta}_3(t)\pi\dot{\chi}+\beta_3(t)\delta g^{0\mu}\partial_\mu\chi-\beta_3(t)\dot{\chi}\dot{\pi}\\ &+\beta_3(t)\partial_i\chi\partial_i\pi-\ddot{\beta}_3(t)\pi\chi-(3\dot{\beta}_3H+3\beta_3\dot{H})\pi\chi\Bigg],\end{align} and keeping in mind the connection \begin{equation} \delta\phi=\pi_c=\frac{\pi}{c_\pi}\sqrt{-2m^2_{pl}\dot{H}}=\frac{\pi}{c_\pi}\dot{\phi}_0.\end{equation} Consider the terms with temporal derivatives. After canonical normalization with $\alpha_1+\alpha_2=1$, and $\delta g^{00}=\frac{\delta g^{00}_c}{m_{pl}}=\frac{\delta N_c}{m_{pl}}$ these give\footnote{For reference, in the case where $m_i=\beta_i=0$ which would mean no derivative coupling, the constraints give $\delta N=-\frac{\dot{H}}{H}\pi$. This makes $\delta N_c=m_{pl}\delta N=\frac{\sqrt{-\dot{H}}}{\sqrt{2}H}\pi_c\sim\frac{\pi_c}{\sqrt{2}}$.} \begin{align} S^{(2)}_{g\chi}&\supset\int d^4 xa^3\Bigg[\beta_1\delta N_c\frac{\chi_c}{m_{pl}}-2\beta_1\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\left(\frac{\dot{c}_\pi}{c_\pi}\pi_c+\dot{\pi}_c-\frac{\ddot{H}}{2\dot{H}}\pi_c\right)\chi_c\\ &-\beta_2\frac{\delta N_c}{m_{pl}}\dot{\chi}_c+2\beta_2\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\left(\frac{\dot{c}_\pi}{c_\pi}\pi_c+\dot{\pi}_c-\frac{\ddot{H}}{2\dot{H}}\pi_c\right)\dot{\chi}_c+\beta_3\frac{\delta g^{0i}_c}{m_{pl}}\partial_i{\chi}_c\\ &-\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\dot{\beta}_3\dot{\chi}_c\pi_c-\beta_3\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\left[-\frac{1}{2}\frac{\ddot{H}}{\dot{H}}\pi_c+\dot{\pi}_c+\frac{\dot{c}_\pi}{c_\pi}\pi_c\right]\dot{\chi}_c\\ &~~~~~~~~~~-\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\ddot{\beta}_3\pi_c\chi_c-\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}(3\dot{\beta}_3H+3\beta_3\dot{H})\pi_c\chi_c\Bigg]\end{align} Our study of the background taught us that higher derivatives on $H$ are stronger because they involve more powers of $m_\phi$. Derivatives of $H$ appear in $S^{(2)}$ after canonical normalization. Looking at all the terms in $S^{(2)}$, the terms that involve the most number of derivatives will be stronger among the terms of same order in perturbations.\footnote{This does not imply that the next order action will be stronger then the previous. For example at third order one has the term $S^{(3)}_{g\chi}\supset \gamma \ddot{\pi}\chi\dot{\chi}$ \cite{Noumi:2012vr}. This will involve $\gamma\left(-\frac{\dddot{H}}{\dot{H}}+\frac{\ddot{H}^2}{\dot{H}^2}\right)\frac{\dot{\pi}_c}{\sqrt{-2m^2_{pl}\dot{H}}}\chi_c\dot{\chi}_c\sim\gamma \frac{m^2_\phi\omega_k}{m_{pl}H}\pi_c\chi_c^2$where $\gamma$ is dimension zero and this term is highly suppressed via the symmetry breaking scale, compared to terms in $S^{(2)}$.} For each parametrization the strongest terms are \begin{align} \beta_1:&\beta_1\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\frac{\ddot{H}}{\dot{H}}\pi_c\chi_c~\text{and}~-2\beta_1\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\dot\pi_c{\chi}_c\\ \beta_2:&-\beta_2\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\frac{\ddot{H}}{\dot{H}}\pi_c\dot{\chi}_c~\text{and}~2\beta_2\frac{c_\pi}{\sqrt{-2m^2_{pl}\dot{H}}}\dot\pi_c\dot{\chi}_c\\ \beta_3:&-\frac{c_\pi\dot{\beta}_3}{\sqrt{-2m^2_{pl}\dot{H}}}\dot{\chi}_c\pi_c,~ -\frac{\beta_3 c_\pi}{\sqrt{-2m_{pl}\dot{H}}}\frac{\ddot{H}}{\dot{H}}\pi_c\dot{\chi}_c,~ -\frac{c_\pi\ddot{\beta}_3}{\sqrt{-2m^2_{pl}\dot{H}}}\pi_c\chi_c. \end{align} Among these terms, there are the derivative couplings\footnote{The terms coming from metric perturbations via $\delta N_c$ can be ignored as they are Planck Suppressed at this order.} \begin{equation} \frac{\beta_1}{\sqrt{-2m^2_{pl}\dot{H}}}\dot{\pi}_c\chi_c,~~\frac{\beta_2}{\sqrt{-2m^2_{pl}\dot{H}}}\frac{\ddot{H}}{\dot{H}}\pi_c\dot{\chi}_c,~~\frac{\beta_3}{\sqrt{-2m^2_{pl}\dot{H}}}\pi_c\dot{\chi}_c,\end{equation} which are of the form $R_1 \dot{\pi}_c\chi_c$ and $R_3\pi_c\dot{\chi}_c$. These terms can compete with the kinetic terms. Notice that $R_{1,3}$ has dimensions of energy, so it sets the energy scale for these derivative interactions. Below the scale set by $R_{1,3}$, if these derivative couplings dominate over the kinetic terms $\dot{\pi}_c^2$, $\dot{\chi}_c^2$, the system will effectively have a single degree of freedom. This is the same situation that is addressed in \cite{Baumann:2011su}, during inflation. Following the same line of thought, let us consider the consequences during preheating. For the moment the sound speeds $c_\chi$, $c_\pi$ can be set to unity, since how they can amplify or reduce the strength of these interactions is not the main concern. This amounts to setting $m_2=0$, $\alpha_1=1$. To see how the number of effective degrees of freedom goes down to being single, let us consider the quadratic Lagrangian for the canonically normalized perturbations in the presence of these interactions one by one. The scales involved will be considered within the limit $a\to 1$, keeping $m^2_{pl}\dot{H}$ finite, which was also meaningful for particle production purposes. \subsection{Hidden Preheating by $\beta_1(t)$} \label{sec:beta1} In the presence of $\beta_1$ the Lagrangian becomes, \begin{align} \nonumber L^{(2)}=\int d^3 xa^3\mathcal{L}=\int d^3x a^3\Big[ \frac{1}{2}\dot{\chi}_c^2+\frac{1}{2}\dot{\pi}_c^2-\frac{1}{2a^2}(\partial_i\chi_c)^2-\frac{1}{2a^2}(\partial_i\pi_c)^2\\ -\frac{1}{2}m^2_\chi\chi_c^2-\frac{1}{2}m^2_\pi\pi_c^2-2R_1\dot{\pi}_c\chi_c-R_1\frac{\ddot{H}}{\dot{H}}\pi_c\chi_c\Big]\end{align} where $R_1\equiv\frac{\beta_1(t)}{\sqrt{-2m^2_{pl}\dot{H}}}$. In terms of the canonically normalized fields this Lagrangian is \begin{align}\nonumber L=\int d^3x\frac{1}{2}\Big[\dot{\tilde{\pi}}_c^2&-\tilde{m}_\pi^2\tilde{\pi}_c^2-\frac{1}{a^2}\left(\partial_i\tilde{\pi}_c\right)^2+\dot{\tilde{\chi}}_c^2-\tilde{m}_\chi^2\tilde{\chi}_c^2-\frac{1}{a^2}\left(\partial_i\tilde{\chi}_c\right)^2\\ &-4R_1\dot{\tilde{\pi}}_c\tilde{\chi}_c+6HR_1\tilde{\pi}_c\tilde{\chi}_c-2R_1\frac{\ddot{H}}{\dot{H}}\tilde{\pi}_c\tilde{\chi}_c\Big]\end{align} The equations of motion for modes of each species are as follows \begin{align}\label{chieom_beta1} \ddot{\tilde\chi}_{ck}+\left[\frac{k^2}{a^2}+\tilde{m}_\chi^2(t)\right]\tilde{\chi}_{ck}&=R_1\left[-2\dot{\tilde\pi}_{kc}+\left(3H-\frac{\ddot{H}}{\dot{H}}\right)\tilde{\pi}_{ck}\right],\\ \label{pieom_beta1}\ddot{\tilde\pi}_{ck}+\left[\frac{k^2}{a^2}+\tilde{m}^2_\pi(t)\right]\tilde{\pi}_{ck}&=R_1\left[2\dot{\tilde{\chi}}_{ck}+\left(2\frac{\dot{R}_1}{R_1}+3H-\frac{\ddot{H}}{\dot{H}}\right)\tilde{\chi}_{ck}\right]. \end{align} From the right hand sides of equations \eqref{chieom_beta1} and \eqref{pieom_beta1} one can see the source terms introduced for each species because of the $\beta_1$ coupling. We are interested in analyzing how these terms modify the dispersion relation in general. In a different direction, if one is interested in considering particle production in the later stages of preheating, then these terms become important for capturing back reaction effects between the two sectors. While WKB-like solutions $\tilde{\pi}_{ck}\sim e^{-i\int\omega(t')dt'}$, $\tilde{\chi}_{ck}\sim e^{-i\int\omega(t')dt'}$ hold, the kinetic terms go by $\omega^2$, and the kinetic coupling goes as $R_1\omega$ . In the range $R_1\gg \omega$, the kinetic coupling dominates over the kinetic terms, the kinetic terms are negligible and the theory can be approximated by \begin{align} \label{hiddenbeta1lag} \nonumber L\simeq\int d^3x\Big[ -2R_1\dot{\tilde\pi}_c\tilde{\chi}_c-\frac{1}{2a^2}(\partial_i\tilde{\chi}_c)^2-\frac{1}{2a^2}(\partial_i\tilde{\pi}_c)^2\\ -\frac{1}{2}{\tilde{m}}^2_\chi\tilde{\chi}_c^2-\frac{1}{2}{\tilde{m}}^2_\pi\tilde{\pi}_c^2+3HR_1\tilde{\pi}_c\tilde{\chi}_c-\frac{\ddot{H}}{\dot{H}}R_1\tilde{\pi}_c\tilde{\chi}_c\Big].\end{align} At first sight it looks like the kinetic term here has a wrong sign, but this depends on the sign of $R_1$, which is not necessarily positive, as will be demonstrated below with a specific example. In this range $\tilde{\chi}_c$ is no longer a dynamical field, since it doesn't have any kinetic terms and its corresponding conjugate momentum is constrained to vanish. Instead it plays the role of canonical momenta for $\tilde{\pi}_c$, \begin{equation}\label{conjmom_beta1} p_\pi\equiv\frac{\partial\mathcal{L}}{\partial\dot{\tilde\pi}_c}=-2R_1\tilde{\chi}_c,~~~p_\chi\equiv\frac{\partial\mathcal{L}}{\partial\dot{\tilde{\chi}}_c}=0.\end{equation} The original motivation for introducing the reheating field was to populate the universe with its perturbations. One would have liked to see more and more of $\tilde{\chi}_c$ modes being the effective degrees of freedom during preheating, yet it turns out that in the presence of $\beta_1$ interactions, for scales $R_1\gg \omega$ it is only the inflaton perturbations who propagate as the effective degrees of freedom! This is not to say that the presence of the reheat perturbations go completely unnoticed. They affect the system by determining the canonical momenta of $\tilde{\pi}_c$. So in a sense this is a type of reheating where there is a range of energies in which the reheating field determines the dynamics of the inflaton perturbations, while it itself stays hidden. For this reason let us refer to this regime as the regime of ``Hidden Preheating''. Having noticed this Hidden Preheating regime, now is a good point to analyze the dispersion relation in this regime. To make matters more simple for this purpose, let us leave aside the resonant particle production effects by dropping the last two terms in \eqref{hiddenbeta1lag} and assume $R_1$, $\tilde{m}_\pi$, $\tilde{m}_\chi$ do not have strong time dependence. These assumptions can be interpreted to mean that we are considering scales such that $R_1 \gg \omega \gg m_\phi\gg H_p$ and neglecting the time dependence of the EFT parameters $\alpha_i(t)$ and $\beta_1(t)$, which for practical purposes amounts to taking $a\to 1$. Vanishing of $p_\chi$ among the canonical momenta is a primary constraint of the system. It means that not all of the canonical variables, $\{\tilde{\pi}_c, p_\pi, \tilde{\chi}_c, p_\chi\}$, are physical degrees of freedom. Some of them are redundant variables that can be set to zero. For the consistency of the system this constraint must be preserved with time, that is the condition \begin{equation} \label{consistcond} \dot{p}_\chi=0\end{equation} should be satisfied. With the above assumptions the Hamiltonian corresponding to \eqref{hiddenbeta1lag} is \begin{align}\label{hiddenbeta1ham} \nonumber H=&\int d^3x\left[p_\pi\dot{\tilde{\pi}}_c+p_\chi\dot{\tilde{\chi}}_c\right]-L\\ =&\frac{1}{2}\int d^3x\left[\left(\partial_i\tilde{\pi}_c\right)^2+\frac{1}{4R^2_1}\left(\partial_ip_\pi\right)^2+\tilde{m}_\pi^2\tilde{\pi}_c^2+\frac{\tilde{m}_\chi^2}{4R^2_1}p^2_\pi\right]\end{align} where equations \eqref{conjmom_beta1} have been employed in the last line. By the Hamilton equations of motion \begin{equation} \dot{p}_\chi=-\frac{\partial H}{\partial\tilde{\chi}_c}=0\end{equation} and thus the consistency condition \eqref{consistcond} is satisfied. Once the fields are decomposed into Fourier modes, the equations of motion for the remaining variables are \begin{equation} \label{hameomchi_beta1} \dot{\tilde{\chi}}_{ck}=\frac{\partial H}{\partial p_{\chi k}}=0,\end{equation} \begin{equation} \label{hameomppi_beta1} \dot{p}_{\pi k}=-\frac{\partial H}{\partial \tilde{\pi}_{ck}}=-\left[k^2+\tilde{m}_\pi^2\right]\tilde{\pi}_{ck},\end{equation} \begin{equation} \label{hameompi_beta1} \dot{\tilde{\pi}}_{ck}=\frac{\partial H}{\partial p_{\pi k}}=\frac{1}{4R^2_1}\left[k^2+\tilde{m}_\chi^2\right]p_{\pi k}.\end{equation} Equations \eqref{hameompi_beta1} and \eqref{hameomppi_beta1} make up a coupled system of differential equations. By differentiating \eqref{hameomppi_beta1} and employing \eqref{hameompi_beta1} one obtains \begin{equation} \label{diff_pi_beta1} \ddot{\tilde{\pi}}_{ck}=-\frac{1}{4R^2_1}\Big[k^4+\left(\tilde{m}_\pi^2+\tilde{m}_\chi^2\right)k^2+\tilde{m}_\pi^2\tilde{m}_\chi^2\Big]\tilde{\pi}_{ck}.\end{equation} This has solutions of the form $\tilde{\pi}_{ck}\sim e^{-i\omega t}$ with \begin{equation} \label{omega_hiddenregion1} \omega=\frac{1}{2R_1}\sqrt{k^4+\left(\tilde{m}_\pi^2+\tilde{m}_\chi^2\right)k^2+\tilde{m}_\pi^2\tilde{m}_\chi^2}\end{equation} at scales $R_1\gg \omega\gg m_\phi>H_p$. In summary, in the Hidden Preheating regime of $\beta_1$ coupling, the effective degrees of freedom that propagate are the $\tilde{\pi}_{ck}$ modes with the dispersion relation \eqref{omega_hiddenregion1}. In this regime the $\tilde{\chi}_c$ sector has been integrated out. However the present constraints on the $\tilde{\chi}_c$ must be treated with care during quantization in this regime. Similar to the situation discussed in \cite{Baumann:2011su} during inflation, the hidden presence of the reheating perturbations leads to a sound speed and further modifications in the dispersion relation of the inflaton perturbations. For modes in the range $R_1\gg k>\tilde{m}_\pi,\tilde{m}_\chi$ this modification at leading order is \begin{equation} \label{hiddenbeta1_rkm} \omega \simeq \frac{k^2}{2R_1}.\end{equation} And for the longest wavelength modes in the range $R_1\gg \tilde{m}_\pi,\tilde{m}_\chi >k$ the modification becomes \begin{align} \nonumber \omega&\simeq \frac{\tilde{m}_\chi\tilde{m}_\pi}{2R_1}\sqrt{1+\frac{\tilde{m}_\pi^2+\tilde{m}_\chi^2}{\tilde{m}_\pi^2\tilde{m}_\chi^2}k^2}\\ &\simeq \frac{\tilde{m}_\pi \tilde{m}_\chi}{2R_1}+\frac{\tilde{m}_\pi^2+\tilde{m}_\chi^2}{\tilde{m}_\pi^2\tilde{m}_\chi^2}\frac{k^2}{4R_1}+...\end{align} Outside of the Hidden Preheating regime, with the ansatz $\tilde{\chi}_{ck}\sim Ae^{-i\omega t}$, $\tilde{\pi}_{ck}\sim Be^{-i\omega t}$ and our previous assumptions on neglecting the time dependence of the background and EFT coefficients, equations \eqref{chieom_beta1} and \eqref{pieom_beta1} lead to the following dispersion relation \begin{equation} \omega_\pm^2=k^2+\frac{\tilde{m}^2_\chi+\tilde{m}^2_\pi}{2}+2R_1^2\pm \sqrt{4R_1^2 k^2+\left(\frac{\tilde{m}^2_\chi+\tilde{m}^2_\pi}{2}+2R^2_1\right)^2-\tilde{m}^2_\pi \tilde{m}^2_\chi}.\end{equation} From here it is seen that in the range $k^2\gg4R_1^2,m^2_\chi,m^2_\pi$, modes of both the inflationary and reheating fields propagate independently with $\omega \sim k$. For scales where $k$ and $R_1$ are comparable, by defining \begin{equation} \label{defA}\tilde{\mathcal{A}}^2\equiv\left(\frac{\tilde{m}^2_\chi+\tilde{m}^2_\pi}{2}+2R^2_1\right)^2-\tilde{m}^2_\pi \tilde{m}^2_\chi,\end{equation} we see that the modification gives rise to a sound speed and nonlinearities as follows \begin{equation} \omega^2_\pm\simeq k^2+\tilde{\mathcal{A}}\pm\left[\tilde{\mathcal{A}}+\frac{2R^2_1}{\tilde{\mathcal{A}}}k^2-\frac{2R^4_1}{\tilde{\mathcal{A}}^3}k^4+...\right].\end{equation} One of the solutions \begin{equation} \label{omega+}\omega^2_+\simeq 2\tilde{\mathcal{A}}+\left(1+\frac{2R_1^2}{\tilde{\mathcal{A}}}\right)k^2\equiv 2\tilde{\mathcal{A}}+c^2_-k^2\end{equation} describes very heavy modes that at leading order do not propagate and whose dispersion relation involves a sound speed $c^2_-$ in the next order contribution.\footnote{Note the sign difference in the definition of the sound speeds, $c^2_-=1+\frac{2R_1^2}{\tilde{\mathcal{A}}}$ and $c^2_+=1-\frac{2R^2_1}{\tilde{\mathcal{A}}}$. For causality the speed of propagation should not exceed the speed of propagation for light. In the units we are working with this reads $c^2_{\pm}\leq 1$. From equation \eqref{defA} $\tilde{\mathcal{A}}$ can have two different signs $\tilde{\mathcal{A}}=\pm\left[\left(\frac{\tilde{m}^2_\chi+\tilde{m}^2_\pi}{2}+2R^2_1\right)^2-\tilde{m}^2_\pi \tilde{m}^2_\chi\right]^{1/2}$. To satisfy the causality condition the positive solution for $\tilde{\mathcal{A}}$ must contribute to $c_+^2$ and the negative solution to $c_-^2$. The notation for sound speeds in equations \eqref{omega+} and \eqref{omega-} aim to emphasize this point.} The $\omega_-$ solution describes the light modes that obtain a sound speed starting from the leading order \begin{equation}\label{omega-} \omega^2_-=\left(1-\frac{2R^2_1}{\tilde{\mathcal{A}}}\right)k^2+\frac{2R^4_1}{\tilde{\mathcal{A}}^3}k^4\equiv c_+^2k^2+\frac{2R_1^4}{\tilde{\mathcal{A}}^3}k^4.\end{equation} For scales in the range $c^2_+\frac{\tilde{\mathcal{A}}^3}{2R^4_1}<k^2<4R^2_1$, the second term in \eqref{omega-} will dominate over the first and at leading order the dispersion relation will be \begin{equation} \label{omega-smallest}\omega_-^2\simeq \frac{2R_1^2}{\tilde{\mathcal{A}}^3}k^4~~~ \text{for}~~c^2_+\frac{\tilde{\mathcal{A}}^3}{2R^4_1}<k^2<4R^2_1.\end{equation} The range $R_1\gg k> \tilde{m}_\chi,\tilde{m}_\pi$ considered in the previous analysis of the dispersion relation during the Hidden Preheating regime, falls within the range $c^2_+\frac{\tilde{\mathcal{A}}^3}{2R^4_1}<k^2<4R^2_1$ where equation \eqref{omega-smallest} holds. This range implies $\tilde{\mathcal{A}}^2\simeq4R^4_1$, which guarantees that expression \eqref{omega-smallest} matches with expression \eqref{hiddenbeta1_rkm}, and $c^2_+\sim 0$. Thus we know that the modes described by \eqref{omega-smallest} are the $\tilde{\pi}_{ck}$ modes in the Hidden preheating regime, while equations \eqref{omega+} and \eqref{omega-} describe both $\tilde{\chi}_{ck}$ and $\tilde{\pi}_{ck}$ modes. Let us try to make an estimate on the likeliness of such a range occurring, by making assumptions on the form of the EFT coefficients. As noted earlier, the mass dimensions of $\beta_i$ are $[\beta_1]=M^3$, $[\beta_2]=[\beta_3]=M^2$. Since the quadratic terms that were determined by the background are at order $m^2_{pl}\dot{H}$, $\beta_i$ is expected to have a similar form. Unless more is known about the background, $m_\phi$ which is the highest scale in the background evolution which can be used to make the dimensions fit \begin{equation}\label{convbeta1}\beta_1=b_1\frac{m^2_{pl}\dot{H}}{m_\phi},\end{equation} \begin{equation}\label{convbeta2}\beta_2=b_2\frac{m^2_{pl}\dot{H}}{m^2_\phi},\end{equation} \begin{equation}\label{convbeta3}\beta_3(t)=b_3\frac{m^2_{pl}\dot{H}}{m^2_\phi}.\end{equation} As such \begin{equation}\label{rho1est} R_1\equiv\frac{\beta_1}{\sqrt{-2m^2_{pl}\dot{H}}}=\mathcal{O}\left(\frac{m_{pl}H}{m_\phi}\right)=\mathcal{O}\left(\frac{\Lambda^2_{sb}}{m_\phi}\right).\end{equation} So while in the range $\Lambda_{sb}>\omega_{\pi,\chi}>R_1$ there are 2 effective degrees of freedom $\pi_c$ and $\chi_c$, where as in the range $R_1>\omega_{\pi,\chi}$, the inflaton perturbations $\pi_c$ are the only effective degree. \begin{figure}[h]\label{fig:beta1modes} \includegraphics[width=\textwidth]{beta1_modes_june2019} \caption{Here it is shown up to which scales the inflaton modes $\delta\phi=\pi_c$ and reheating modes $\chi_c$ appear as effective degrees of freedom, in the presence of $\beta_1$ type couplings.} \end{figure} Now we need to be a bit careful, does this leave any range for $\chi_c$-production? We found that the $\chi_c$ particles can be produced up to the scale \begin{equation} K^2_{bck}=\frac{1}{c_\chi^2}\left[\left(\frac{\dot{\alpha}_3-\ddot{\alpha}_4}{2}\right)^{2/3}-\alpha_3+\dot{\alpha}_4\right]\sim\mathcal{O}\left(\left[\frac{m^2_{pl}H^2}{m_\phi}\right]^{2/3}\right)=m_\phi^{2/3}R_1^{4/3}\end{equation} Considering \eqref{rho1est}, this suggests that the scale of particle production lies above the scale $R_1$, and so in the range $R_1<E<K_{bck}$ both $\pi_c$ and $\chi_c$ modes are effective degrees of freedom. We sumarize this distribution of effective modes with respect to scale in figure 1. These $\beta_1$ interactions are present in models where the inflaton is derivatively coupled to the reheating sector. In the context of preheating derivative couplings have first been studied in \cite{ArmendarizPicon:2007iv}, with \begin{equation}\mathcal{L}=-\frac{1}{2}\partial^\mu\phi\partial_\mu\phi-\frac{1}{2}\partial^\mu X\partial_\mu X-V(\phi)- U(X)-\frac{1}{F^2}(\partial_\mu\phi\partial^\mu\phi)X^2\end{equation} where $F$ is the cutoff for this effective field theory. In the original work, the authors consider Chaotic Inflation in particular, to govern the inflaton sector in this low energy theory, in which case $F\simeq m_{pl}$. Another example is the case of geometric destabilization of inflation \cite{Renaux-Petel:2015mga}. The Friedman equations at the background level are \begin{equation} -2m^2_{pl}\dot{H}=\left(1+2\frac{\chi_0^2}{F^2}\right)\dot{\phi}_0^2\equiv R^2\dot{\phi}_0^2\end{equation} \begin{equation} 3m^2_{pl}H^2=\frac{1}{2}\left(1+2\frac{\chi_0^2}{F^2}\right)\dot{\phi}_0^2+V(\phi_0)+U(\chi_0)\end{equation} where $\chi_0$ is set to be constant. In general, such effective Lagrangians can also involve $-\frac{\partial_\mu\phi\partial^\mu\phi}{F}\chi$ terms, which would lead to $\chi_0(t)$ and give rise to an unstable growth in the reheating sector. In unitary gauge, the fields are expanded in terms of linear perturbations as $\phi=\phi_0(t)$, $X=\chi_0+\chi(\vec{x},t)$ and, $g^{\mu\nu}=\bar{g}^{\mu\nu}(t)+\delta g^{\mu\nu}(\vec{x},t)$. With $V''(\phi_0)=m^2_\phi$ and $U''(\chi_0)=m^2_\chi$ the Lagrangian up to second order in perturbations is \begin{align} \mathcal{L}^{(2)}&=-m^2_{pl}(3H^2(t)+\dot{H}(t))+m^2_{pl}\dot{H}g^{00}\\ &-\frac{1}{2}\partial_\mu\chi\partial^\mu\chi-\frac{1}{2}\left(m^2_\chi-2\frac{\dot{\phi}_0^2}{F^2}\right)\chi^2-2\frac{\chi_0}{F^2}\dot{\phi}^2\delta g^{00}\chi\end{align} where the background equations of motion have been taken into account. This matches the EFT Lagrangian as a model with \begin{equation} \alpha_1=1,~~\alpha_2=0,~~\alpha_3=m^2_\chi-2\frac{\dot{\phi}_0}{F^2}=m_\chi^2+\frac{4m^2_{pl}\dot{H}}{F^2},~~\alpha_4=0,~~m_i=0.\end{equation} Comparing the last line with \eqref{hiddenS} we can also read off that \begin{equation} \beta_1(t)=-2\frac{\chi_0}{F^2}\dot{\phi}_0^2=4\frac{\chi_0}{F^2R^2}m^2_{pl}\dot{H}.\end{equation} This sets the scale for Hidden preheating to be \begin{equation} R_1=\frac{\beta_1}{\sqrt{-2m^2_{pl}\dot{H}}}=-2\frac{\chi_0}{F^2R^2}\sqrt{-2m^2_{pl}\dot{H}}\sim\frac{\chi_0}{F^2R^2}\Lambda_{sb}^2.\end{equation} Also note that in the range $R_1>\omega$, the canonical momentum of the effective degree of freedom $\pi_c$ is \begin{equation} p_\pi=-2R_1\chi_c=4\frac{\chi_0}{F^2R^2}\sqrt{-2m^2_{pl}\dot{H}}~\chi_c.\end{equation} The $\chi_c$ production scale here is \begin{equation} K^2_{bck}=\left(\frac{2m^2_{pl}\ddot{H}}{F^2}\right)^{2/3}-m^2_\chi-4\frac{m^2_{pl}}{F^2}\dot{H}\end{equation} \begin{equation} K^2_{bck}\sim\left(m_\phi\frac{\Lambda_{sb}^4}{F^2}\right)^{2/3}-m_\chi^2-4\frac{\Lambda_{sb}^4}{F^2}\end{equation} Corrections to $\phi$ dynamics here come with coefficients of $\frac{\chi_0}{F}$, which makes them perturbative corrections as long as $\chi_0\ll F$. This in return implies that $\frac{\chi_0}{R^2}=\frac{\chi_0}{\left(1+2\frac{\chi_0^2}{F^2}\right)^2}\sim\chi_0$, and the particle production scale will lie above the coupling $R_1^2\sim\frac{\chi_0^2}{F^2}\frac{\Lambda_{sb}^4}{F^2}$. The derivative couplings preserve the shift symmetry of the inflaton. Hence they provide a very likely candidate for couplings of the inflaton with other fields. This also makes them more likely to be present in the later stages then nonderivative couplings, such as the original $g^2\phi^2X^2$ interaction considered for preheating. However, previous analysis of the instability regimes they lead to suggested that they are not very efficient for preheating. The line of inquiry here is showing that these type of derivative couplings lead to the presence of only inflationary perturbations with modified dispersion relations as the lightest modes present. This suggests a reason as to why they are inefficient for setting resonance in the reheating sector. \subsection{Hidden Preheating with $\beta_2(t)$} \label{sec:beta2} The quadratic Lagrangian in the presence of $\beta_2$ is \begin{equation} \mathcal{L}^{(2)}=\frac{1}{2}\dot{\chi}_c^2+\frac{1}{2}\dot{\pi}_c^2-\frac{1}{2a^2}(\partial_i\chi_c)^2-\frac{1}{2a^2}(\partial_i\pi_c)^2-\frac{1}{2}m^2_\chi\chi_c^2-\frac{1}{2}m^2_\pi\pi_c^2+2\rho_2\dot{\pi}_c\dot\chi_c-\rho_2\frac{\ddot{H}}{\dot{H}}\pi_c\dot\chi_c\end{equation} where $\rho_2\equiv\frac{\beta_2}{\sqrt{-2m^2_{pl}\dot{H}}}$. In the previous case, the coupling strength $R_1$ had mass dimension one and hence it defined a scale, but $\rho_2$ here is dimensionless. Moreover different then the case with $\beta_1$, here $\chi_c$ appears with time derivatives and there are two derivative couplings. Neglecting the background expansion and considering solutions of the form $\chi_c\sim Ae^{-i\omega t}$, $\pi_c Be^{-i\omega t}$ the strength of the kinetic terms will be of the order \begin{align} \rho_2\dot{\chi}_c\dot{\pi}_c\sim \rho_2\omega^2 AB,~~\dot{\chi}_c^2\sim\omega^2A^2,~~\dot{\pi}_c^2\sim\omega^2B^2.\end{align} Being dimensionless $\rho_2$ does not define a scale and it will at most be order one. But if at times the amplitude of one of the species dominates over the other, the coupling with $\rho_2$ can dominate over the kinetic term for the species with the smaller amplitude and hence give it a sound speed. A similar interaction is also present in the next case with $\beta_3$. \subsection{Hidden Preheating by $\beta_3(t)$} \label{sec:beta3} The quadratic Lagrangian in this case is \begin{align}L^{(2)}=\int d^3x a^3&\Bigg[\frac{1}{2}\dot{\chi}^2_c+\frac{1}{2}\dot{\pi}_c^2-\frac{(\partial_i\chi_c)^2}{2a^2}-\frac{(\partial_i\pi_c)^2}{2a^2}-\frac{m_\chi^2(t)}{2}\chi_c^2-\frac{m^2_\pi(t)}{2}\pi_c^2\\ &-\frac{\dot{\beta}_3\dot{\chi}_c\pi_c}{\sqrt{-2m^2_{pl}\dot{H}}}-\frac{\ddot{H}}{\dot{H}}\frac{\beta_3\pi_c\dot{\chi}_c}{\sqrt{-2m^2_{pl}\dot{H}}}-\frac{\beta_3\dot{\pi}_c\dot{\chi}_c}{\sqrt{-2m^2_{pl}\dot{H}}}-\frac{\ddot{\beta}_3\pi_c\chi_c}{\sqrt{-2m^2_{pl}\dot{H}}}\Bigg].\end{align} This time there are three different couplings, \begin{equation} \rho_3\equiv\frac{\beta_3}{\sqrt{-2m^2_{pl}\dot{H}}},~~ R_2\equiv\frac{\ddot{\beta}_3}{\sqrt{-2m^2_{pl}\dot{H}}},~~R_3\equiv\frac{\dot{\beta}_3}{\sqrt{-2m^2_{pl}\dot{H}}}.\end{equation} With these new definitions the quadratic Lagrangian in terms of $\tilde{\chi}_c$ and $\tilde{\pi}_c$ becomes \begin{align}L^{(2)}=\frac{1}{2}&\int d^3x\Bigg[\dot{\tilde\chi}^2_c+\dot{\tilde\pi}_c^2-\frac{(\partial_i\tilde{\chi}_c)^2}{a^2}-\frac{(\partial_i\tilde{\pi}_c)^2}{a^2}-\tilde{m}_\chi^2(t)\tilde{\chi}_c^2-\tilde{m}^2_\pi(t)\tilde{\pi}_c^2\\ &-2R_3\dot{\tilde\chi}_c\tilde{\pi}_c-2\frac{\ddot{H}}{\dot{H}}\rho_3\tilde{\pi}_c\dot{\tilde\chi}_c-2\rho_3\dot{\tilde\pi}_c\dot{\tilde\chi}_c+3H\rho_3\left(\tilde{\pi}_c\dot{\tilde{\chi}}_c+\tilde{\chi}_c\dot{\tilde{\pi}}_c\right)\\ &3H\left(R_3-\frac{\ddot{H}}{\dot{H}}\rho_3-\frac{9}{2}H^2\rho_3\right)\tilde{\pi}_c\tilde{\chi}_c-2R_2\tilde{\pi}_c\tilde{\chi}_c\Bigg]. \end{align} The coupling strength $\beta_3$ has mass dimension two. This makes $\rho_3$ dimensionless, just like $\rho_2$. $R_2$ and $R_3$ are the dimension full parameters that can set the scales here. The $R_2$ term only contributes to the over all energy. $R_3$ has dimensions of mass and works similar to $R_1$. In the limit $a\to 1$ while the combination $m^2_{pl}\dot{H}$ stays finite, let us assume that $R_2$, $R_3$ and $\rho_3$ stay finite and are constant while the terms involving $3H$ and $\frac{\ddot{H}}{\dot{H}}$ can be dropped. With these assumptions we are focusing on scales $R_3\gg \omega \gg m_\phi >H$ and the Lagrangian equations of motion take the form \begin{equation} \ddot{\tilde\chi}_{ck}+\left(k^2+\tilde{m}^2_\chi(t)\right)\tilde{\chi}_{ck}=R_3\dot{\tilde\pi}_{ck}-R_2\tilde{\pi}_{ck}+\rho_3\ddot{\tilde\pi}_{ck},\end{equation} \begin{equation} \ddot{\tilde\pi}_{ck}+\left(k^2+\tilde{m}^2_\pi\right)\tilde{\pi}_{ck}=-R_3\dot{\tilde\chi}_{ck}-R_2\tilde{\chi}_{ck}+\rho_3\ddot{\tilde\chi}_{ck}.\end{equation} This exhibits modes with frequencies of \begin{align}\nonumber &\omega_\pm^2=\frac{1}{\left(1-\rho_3^2\right)}k^2+\frac{\tilde{\mathcal{B}}^2}{2\left(1-\rho_3^2\right)}\\ &\pm\frac{1}{2\left(1-\rho_3^2\right)}\sqrt{4\rho_3^2k^4+4\left(\rho^2_3\left(\tilde{m}^2_\chi+\tilde{m}^2_\pi\right)+2\rho_3R_2+R^2_3\right)k^2+\tilde{\mathcal{B}}^4-4\left(1-\rho_3^2\right)\mathcal{M}^4}\end{align} where \begin{align} \tilde{\mathcal{B}}^2&\equiv \tilde{m}^2_\chi+\tilde{m}^2_\pi+R^2_3+2\rho_3R_2,\\ \mathcal{M}^4&\equiv \tilde{m}^2_\chi \tilde{m}^2_\pi -R^2_2\end{align} have been defined for ease of notation. Inflaton and reheating modes in the range $k^2\gg \tilde{\mathcal{B}}\left( R_3,\tilde{m}_\chi,\tilde{m}_\pi,R_2\right)$, $\mathcal{M}^2\left(\tilde{m}_\chi,\tilde{m}_\pi,R_2\right)$, propagate freely with $\omega\sim c_\rho k$ where they can acquire a sound speed of the order of $c^2_\rho= \frac{1\pm\rho_3^2}{1-\rho_3^2}$. The main difference of this case from the case with $\beta_1$ is the possibility that a sound speed exists even at this relatively high range of energies! This suggests that these type of couplings arise from the presence of at least three fields, where one of the fields is much heavier then both the inflationary and reheating sectors, leading to a nontrivial sound speed, $c_\rho^2$, even at the ranges where the two sectors of interest appear weakly coupled to each other. In the range $R_3^2\gg \rho_3k^2 > \tilde{m}^2_\chi,\tilde{m}^2_\pi,R_2$, $\tilde{\mathcal{B}}^2\simeq R^2_3$ and the mode frequency is approximately \begin{equation} \omega_\pm^2\simeq \frac{k^2}{\left(1-\rho_3^2\right)}+\frac{R_3^2}{2\left(1-\rho_3^2\right)}\pm\frac{R_3^2}{2\left(1-\rho_3^2\right)}\sqrt{1+\left(4\frac{\rho_3^2}{R_3^4}k^4+\frac{4}{R_3^2}k^2\right)}.\end{equation} Expanding the square root, this range accommodates modes with the dispersion relation \begin{equation} \omega^2_+\simeq \frac{R^2_3}{1-\rho^2_3}+\frac{2}{1-\rho^2_3}k^2.\end{equation} At leading order these are very heavy modes that do not propagate since there is no k-dependence in the first term. The lighter modes in this range have the following dispersion relation \begin{equation} \label{omega-_beta3} \omega_-^2\simeq \frac{k^4}{R_3^2}.\end{equation} Note that this expression is very similar to the dispersion relation \eqref{hiddenbeta1_rkm} that we found for modes in the Hidden preheating regime with $\beta_1$ type couplings, which in that case were purely inflaton modes. For $\rho_3\ll 1$, in the regime $R_3\gg\omega>m_\phi,R_2>H_m$ the Lagrangian \begin{equation} \label{hiddenlag_beta3} L^{(2)}\simeq \int d^3x\left[ -R_3\dot{\tilde\chi}_c\tilde{\pi}_c-\frac{1}{2a^2}(\partial_i\tilde{\chi}_c)^2-\frac{1}{2a^2}(\partial_i\tilde{\pi}_c)^2-\frac{1}{2}\tilde{m}^2_\chi(t)\tilde{\chi}_c^2-\frac{1}{2}\tilde{m}^2_\pi(t)\tilde{\pi}_c^2\right].\e gives rise to the example where the $\tilde{\chi}_c$ modes are the lightest degree of freedom, and $\tilde{\pi}_c$ plays the role of their canonical momenta \begin{equation} \label{canmomt_beta3} p_\chi\equiv\frac{\partial\mathcal{L}}{\partial\dot{\tilde\chi}_c}=-R_3\tilde{\pi}_c,~~~~p_\pi\equiv \frac{\partial \mathcal{L}}{\partial\dot{\tilde{\pi}}_c}=0.\end{equation} And again there is a constraint which now demands that the momentum of inflaton modes vanish. Taking the limit $a\to 1$ with $m_{pl}^2\dot{H}$ remaining finite, and demanding equations \eqref{canmomt_beta3} be satisfied, the Hamiltonian corresponding to \eqref{hiddenlag_beta3} is \begin{align} \nonumber H&=\int d^3x \left[p_\pi\dot{\tilde\pi}_c+p_\chi\dot{\tilde{\chi}}_c\right]-L\\ \label{hamhidden_beta3}&=\frac{1}{2}\int d^3x \left[\left(\partial_i\tilde{\chi}_c\right)^2+\frac{1}{R^2_3}\left(\partial_ip_\chi\right)^2+\tilde{m}_\chi^2\tilde{\chi}_c^2+\frac{\tilde{m}_\pi^2}{R^2_3}p^2_\chi\right]. \end{align} Decomposing the fields into their Fourier modes, the Hamilton equations of motion read \begin{align} \dot{p}_{\pi k}&=-\frac{\partial H}{\partial \tilde{\pi}_{ck}}=0,\\ \dot{\tilde{\pi}}_{ck}&=\frac{\partial H}{\partial p_{\pi k}}=0,\\ \dot{p}_{\chi k}&=-\frac{\partial H}{\partial \tilde{\chi}_{ck}}=-\left[k^2+\tilde{m}_\chi^2\right]\tilde{\chi}_{c k},\\ \dot{\tilde{\chi}}_{ck}&=\frac{\partial H}{\partial p_{\chi k}}= \frac{1}{R^2_3}\left[k^2+\tilde{m}_\pi^2\right]p_{\chi k}. \end{align} The first of these guarantee that the constraint is satisfied at all times. With our previous assumptions and neglecting the time dependence in $R_3$, $\tilde{m}_\chi$ and $\tilde{m}_\pi$, this system exhibits modes $\tilde{\chi}_{ck}\sim e^{-i\omega t}$ with the dispersion relation \begin{equation} \label{hiddendis_chi_beta3} \omega=\frac{1}{R_3}\sqrt{k^4+\left(\tilde{m}_\chi^2+\tilde{m}_\pi^2\right)k^2+\tilde{m}_\chi^2\tilde{m}_\pi^2}\end{equation} for scales in the range $R_3\gg k> m_\phi,R_2>H_m$ and $\rho_3\ll1$. In fact at leading order in this regime equation \eqref{omega-_beta3} is recovered \begin{equation} \label{hiddenregime_beta3_dis} \omega \simeq\frac{k^2}{R_3}=\omega_-\end{equation} Thus we can identify $\omega_-$ modes to be purely reheating modes. This is similar to the case of Hidden preheating with $\beta_1$, only this time the roles of the two fields are switched around. Since the reheating perturbations are the light modes here, these type of kinetic couplings could be more likely to give rise to efficient preheating. Unlike the case with $\beta_1(t)$, there do not seem to appear previously studied examples to this case in neither the inflationary nor preheating literature. This may be due to the fact that in generalizing couplings usually the main attention is given to modifying the kinetic terms of the inflaton. The scale that the $R_3$ defines, the scale up to which $\chi_c$ is the single effective species, is around $\mathcal{O}\left(\frac{m_{pl}H}{m_\phi}\right)$ order of magnitude wise. Considering $\sqrt{m_{pl}H}$ as a unit scale, the relationship between the magnitude of this scale to the $\chi$-production scale is $K_{bck}=(m_{pl}H)^{1/3}R_3^{1/3}\sim R_3^{1/3}$. In conclusion at frequencies below the $R_3$ scale, $\omega<R_3$, the effective modes are the reheating modes alone where as at scales $R_3<\omega<K_{bck}$ modes of both $\pi_c$ and $\chi_c$ are present, and above $K_{bck}$ there is only the inflaton perturbations due to the lack of resonant $\chi_c$ production. These scales and the corresponding species are summarized in figure 2. \begin{figure}[h] \label{beta3modes} \includegraphics[width=\textwidth]{beta3_modes_june2019} \caption{Here the regions where the inflaton modes $\delta\phi=\pi_c$ and reheating modes $\chi_c$ appear as effective degrees of freedom in the presence of $\beta_3$ interactions, where a sound speed is probable at all levels, are shown.} \end{figure} \section{Conclusions} \label{sec:conc} Low energy effective field theories (EFT), especially the ones that are developed at the level of perturbations such as the EFT considered here, aim to capture the variety of interactions in the most general way. This generality is achieved by considering all of the interactions allowed by the symmetries that are present below a specified scale. This scale in the EFT set up considered here was the scale of spontaneous breaking of time translation invariance, due to the time dependent nature of the background $H(t)$. Among the possible interactions for the inflaton and reheating field perturbations, the present work has focused on the extra derivative couplings that appear under three different classes, specified by the EFT parameters $\{\beta_1,\beta_2,\beta_3\}$. The scales these derivative couplings introduce, the nature of the effective degrees of freedom at energies below the introduced scales ( whether they are inflaton perturbations or the scalar reheating perturbations), and the corrections to the dispersion relation for the effective modes at low energies have been explored in this work. The properties of the background as determined by the preheating era, that is the presence of two scales $m_\phi$ and $H_m$ with the hierarchy $m_\phi\gg H_m\simeq H_p$ between them, have been used to determine the hierarchy between the scales of the interactions, such as the particle production scale and the scale associated to derivative couplings. All this has led to the main conclusion that, all though the aim of preheating is to capture energy transfer between two different species, here the inflaton and the scalar reheating sector $\chi$, in the presence of such derivative couplings only one of the species propagates as an effective degree of freedom at very low energies, while the other stays hidden and modifies the dispersion relation of the propagating species. Instead of an analysis of instability bands to determine the efficiency of $\chi$-production, the main pursuit here has been the identification of the relevant species for low energies and exploring how the dispersion relation of this species gets modified. It is left for future to discuss the efficiency in production of the identified low energy modes through studying the details of resonance in comparison to perturbative decay rates. While this EFT method allows one to study the properties of perturbations right away, the disadvantage can be that it is not always clear what kind of interactions at the background level would give rise to these interactions at the level of perturbations. For example, an interaction of type $(\frac{1}{\Lambda}\partial^\mu\phi\partial_\mu\phi)X$ where $\phi$ is the inflaton which is to be expanded as $\phi(\vec{x},t)=\phi_0(t)+\delta\phi(\vec{x},t)$, $X$, with $X(\vec{x},t)=X_0(t)+\chi(\vec{x},t)$, is the reheating field and $\Lambda$ is some mass scale; is an example that gives rise to $\beta_1$ type couplings. And indeed these type of interactions are common in inflationary literature in many studies that wish to respect the shift symmetry for the inflaton. On the other hand, $\frac{1}{\Lambda}(\partial^\mu X\partial_\mu X)\phi$ would be an example to $\beta_3$ type couplings, which however would not be an interaction to consider if one is concerned with a shift symmetric inflaton. Looking at the preheating literature, the interactions considered are more of a polynomial type, for instance $g^2\phi^2X^2$ is the first case that has been considered. Derivative couplings during preheating have not been studied at the level they have been during inflation. So far, derivative couplings in preheating literature involve examples of only the class of $\beta_1$ couplings, among the three classes that the EFT methods suggest. Moreover the examples to $\beta_1$ case that have been studied are noted to be not very efficient for resonant production of low energy reheating modes, $\tilde{\chi}_{ck}$. Looking at the dispersion relations, here it is noted that at scales below the scale of derivative coupling $R_1$, the reheating modes appear to effect the canonical momenta of the inflaton perturbations, leaving them as the low energy species with a modified dispersion relation derived in equations \eqref{hiddenbeta1_rkm} and \eqref{omega-smallest}. On the other hand, $\beta_3$ interactions accommodate the reheating modes as the light degrees of freedom with a modified dispersion relation of \eqref{hiddenregime_beta3_dis}. Hence these later type of interactions may be more promising for resonant production of $\chi$ through derivative couplings. Moreover some of the derivative couplings, in the presence of $\beta_2$ and $\beta_3$ imply a sound speed and modified dispersion relations for both of the species even at energies where modes of both propagate freely. This suggests that these EFT coefficients may address models that involve additional heavy degrees of freedom. The reheating sector $\chi$ as considered here is quite general. Being a primordial scalar field, $\chi$ is most likely to contribute to structure formation and resemble fields associated to dark matter. In principal any of these couplings can arise in models of multi-field inflation. Since the effective field theory method at the level of perturbations followed here considers all possible terms that respect the symmetries at the scales of interest, one of the expected benefits of this approach is to come across new types of interactions that may not have been thought of yet. The appearance of the less explored case of $\beta_3(t)$ type couplings are an example to this. They would arise from attempts of generalizing interactions of the reheating field, as sketched in the previous paragraphs. It is left for future to explore for this later case, the phenomenological implications and the detailed structure of resonance in comparison with rate of perturbative decays. With regards to perturbative decay rates, the EFT interactions would give the possible Feynmann diagrams to be computed, however the strength of the amplitude from these diagrams will depend on the coupling parameter which in turn depends on the background physics. The background information is determined by how $H_p(t)$ and $m_\phi$ work into $\phi_0(t)$ and $X_0(t)$. The same holds for the efficiency of resonant particle production. One can make estimates on the scale of particle production from the general behavior of the background as it has been done here, but to study the actual efficiency one again has to first study the details of how the background parameters work into the Mathieu variables. Once solid examples that give rise to $\beta_3$ type interactions at the level of perturbations are constructed, then how the coupling parameters depend on $m_{pl},$ $H$ and $m_\phi$ through the background behavior of $\phi_0$ and $X_0$ will become more clear and, the perturbative decay rates and efficiency of resonance can be studied more concretely. \begin{acknowledgements} It is a great pleasure to thank Scott Watson and an anonymous referee for their valuable comments on earlier versions of this manuscript, to Cristian Armendariz Picon, Johanna Karouby, Caner Ünal, and Evangelos Sfakianakis for useful discussions, to Vak\i f \"Onemli and Costantinos Skordis for their encouragement. This work was initiated at Syracuse University Physics Department under the Graduate Student Assistantship, supported in part by the DOE grant DE-FG02-85ER40237 and completed at CEICO supported by the IOP Researchers Mobility Grant $CZ.02.2.69/0.0/0.0/16\_027/0008215$. \end{acknowledgements}
\section{Introduction} The enormous success of quantum theory has led many physicists believe that quantum theory is the ultimate theory and all other theories, including gravity, should be described in the language of quantum theory. While this is true to some extent, one can safely say that the picture is not complete yet. There are many glitches in quantum theory that remain unanswered, and mostly remain ignored by the community. The theory does not explain the collapse of the wavefunction during a measurement process. Neither does it allow a natural transition between quantum to classical phenomena. The superposition principle is violated during a measurement and it is simply taken as an outcome, not as a consequence of the theory. The theory also fails to address the origin of probabilistic outcomes which obey Born probability rule. The crucial role played by the measuring apparatus which is ``classical" is also very discomforting since, in an ideal picture where everything is described by quantum theory, even the measuring apparatus should follow the rules of quantum mechanics. These set of problems together are known as the ``quantum measurement problem" \cite{Bell}. One way to address these set of questions is to completely reinterpret quantum theory such that known observations are kept intact. Bohmian mechanics is one such approach \cite{Bohm}. The theory considers the coexistence of particles and wavefunctions, and thus there is no concept of collapse in the theory. The decoherence compensated by many worlds interpretation is another approach where quantum theory is treated as sacred \cite{Zurek,Everett}. The collapse of the outcomes are attributed to observers in different branches of the universe. The third approach is to extend quantum theory beyond linear regime in such a way that the collapse is encoded in the dynamics of the theory rather than depending upon measurements taking place. Theories like GRW (Ghirardi-Rimini-Weber), QMUPL (Quantum Mechanics with Universal Position Localization) and CSL (Continuous Spontaneous Localization) fall in this category \cite{Ghirardi:86,Ghirardi}. These theories are nonlinear and stochastic in nature and can naturally explain the Born probability rule. The equations are formulated such that quantum theory and classical theory are recovered in appropriate limits. For a general review on such theories, one can refer to \cite{reviewbassi,review}. CSL theory is the most advanced form of its previous versions. A lot of interests have grown in recent times in testing CSL theory in laboratory experiments via observation of the breakdown of superposition principle in the macroscopic limit. Experiments on molecular interference are pushing the limits in the mass spectrum to observe the breakdown of quantum theory \cite{Arndt}. Other avenues to test CSL are also being explored, for example, tests of CSL-induced spectral line broadening \cite{Hendrik}, excess heat measurement via temperature increase \cite{thermo} and bounds deduced from heating of an atomic Bose-Einstein Condensate \cite{BEC}. Such proposals rely upon the ``side-effects" of CSL theory, which allow a small violation of energy-momentum conservation. CSL assumes the presence of a universal noise that couples with the matter and imparts an excess energy to the system. As a result, a particle affected by CSL can undergo a Brownian motion or a slight increase in its temperature. These effects should be detectable in an experiment given other sources of noise are minimized. Recent proposals on the detection of heating effect and resulting random walk have been discussed in \cite{Bhawna,Bedingham,Adler}. In a very recent experiment reported in \cite{Vinante}, the authors claim to have observed an extra noise source. If this could be connected to CSL, then that would be a significant step towards understanding the fundamental theory. Various bounds on the CSL parameters have already restricted the parameter space to a large extent, and it is only a matter of time when the theory would be validated/ ruled out by experiments. Given the surge of interest in testing CSL, that does not seem far-fetched. In this letter, we rather try to point out basic readjustments in the apparatus that need to be done in order to test CSL and similar theories. Most of the proposals of detection rely on a trapping mechanism where particles undergoing CSL are trapped optically or via oscillating electric fields. The most widely used ion traps in this context are Paul traps that use transverse electric fields oscillating in radio-frequency and producing a stable field configuration to hold the charged particle. In this work, we consider scenarios where the stability of the particle might get disturbed due to additional random motion caused by CSL. It can even drive the particle out of its stability zone. Thus to perform such experiments, one must first consider the backreaction of CSL effect on the particle stability inside the trap and readjust the trap parameters such that throughout the experiment the particle is confined inside the trap. We solve the modified trajectory of the particle with CSL noise and plot the resulting stability zone. We also draw an exclusion plot of the CSL parameters for a given trap configuration. \section{Trajectory of an ion in Paul trap} Paul traps involve time dependent cross electric fields to restrict the motion of a charged particle and hence trapping the ion inside a small region. The most widely used Paul traps are quadrupolar Paul traps where the field applied is of quadrupolar nature. The potential depends upon a time varying voltage applied to the electrodes on top of a static dc voltage. The restoring force on the ion increases linearly with its distance from the centre, thus effectively confining the ion at the centre of the trap. Here we consider the 2D quadrupolar Paul trap which was considered in \cite{Bedingham}. Such ion traps confine ions in two direction while the third direction is used to eject ions inside the trap. Figure below depicts the basic structure of a 2D Paul trap. \begin{figure}[H] \centering \includegraphics[width=8cm,height=7cm] {finalimage.png} \caption[Optional caption for list of figures]{\small Schematic diagram of a 2-D quadrupolar Paul trap. An oscillating electric field is applied between each pair of electrodes. In the diagram, $X-Y$ is the confining plane, and particles are inserted into the trap along the $Z$-direction.} \end{figure} There are four electrodes, each pair of opposite rods having the same polarity. This structure creates a quadrupolar field in the $x-y$ plane. The distance from the centre of the trap to the surface of the electrodes is $r_0$. A potential $U-V \cos(\Omega t)$ is applied to the x-electrodes, while $-(U-V \cos(\Omega t))$ is applied to the y-electrodes. $U$ is the dc voltage and $V$ denotes the zero-to-peak amplitude of an oscillating radio-frequency voltage having frequency $\Omega$. It can be shown that the equation of motion of an ion with charge $Q$ inside the trap can be written as, \begin{equation} m\left(\frac{d^2 x}{dt^2}\right) + \left(\frac{2QU}{r_0^2}- \frac{2QV\cos(\Omega t)}{r_0^2}\right)x = 0 \label{Mathieu1} \end{equation} A similar equation is valid for the y-direction.\\ This equation has the same form as the Mathieu equation which was obtained to describe the motion of a vibrating elliptical drumhead \cite{Mathieu}. The equation has the following form, \begin{equation} \frac{d^2 u}{d\xi^2} + \left(a_u + 2q_u\cos(2\xi)\right)u = 0 \label{Mathieu2} \end{equation} where $\xi = \Omega t/2$ is dimensionless parameter. $a_u$ and $q_u$ are the dimensionless parameters called the stability parameters. The solution of the Mathieu equation can be described in terms of stability zones in the $a_u-q_u$ parameter space. \\ Using the transformation $\xi = \Omega t/2$, Eq. \eqref{Mathieu1} can be written exactly in the form of the Mathieu equation \eqref{Mathieu2} with $a_x= 8 QU/m\Omega^2 r_0^2$ and $q_x=-4 QV/m\Omega^2 r_0^2$. For the equation in y-direction, we get $a_y=-a_x$ and $q_y=-q_x$. The general solution can be written as \begin{equation} u(\xi)= A e^{\mu\xi}\sum_{n=-\infty}^\infty C_{2n}e^{2in\xi} + B e^{-\mu\xi}\sum_{n=-\infty}^\infty C_{2n}e^{-2in\xi} \end{equation} where $A,\ B$ are the integration constants that depend upon the initial conditions, $C_{2n}$ denote the amplitude of oscillations and $\mu$ is a dimensionless parameter (Floquet index) that depends upon $a_u$ and $q_u$. This parameter is crucial to determine the stable and unstable regions of the solution. When $\mu$ is purely imaginary, i.e. $\mu=i \beta$, then those solutions are stable oscillatory solutions.\\ For the cases of our interest, we work with $|a_u| \ll |q_u| \ll 1$. The analytical solution in terms of $t$ in this regime can be obtained as (two integration constants are chosen to be same): \begin{equation} x(t) = A \cos(\mu \Omega t/2)\left[1+\frac{q}{2} \cos(\Omega t)\right] \end{equation} where $\mu= \sqrt{a+q^2/2}$ (Dehmelt's approximation). \section{Continuous Spontaneous Localization and random motion} The Continuous Spontaneous Localization or the CSL model was first proposed by Ghirardi, Pearle and Rimini in the context of modifying quantum mechanics in order to address the issues related to the ``quantum measurement problem" \cite{Ghirardi}. The proposed model is a \textit{non-relativistic} modification to quantum mechanics and a proper relativistic extension is yet to be formulated. The mass proportional version of CSL evolution equation can be written as \cite{review}, \begin{equation} \begin{split} \label{eq:csl-massa} & d\psi_t = \Big[-\frac{i}{\hbar}\hat{H}dt + \frac{\sqrt{\gamma}}{m_{0}}\int d\mathbf{x} (\hat{M}(\mathbf{x}) - \langle \hat{M}(\mathbf{x}) \rangle_t) dW_{t}(\mathbf{x}) \\ & ~~~~~~~~~~ - \frac{\gamma}{2m_{0}^{2}} \int d\mathbf{x}\, d\mathbf{y}\, \mathcal{G}({\bf x}-{\bf y}) (\hat{M}(\mathbf{x})-\langle \hat{M}(\mathbf{x}) \rangle_t) \times \\ & ~~~~~~~~~~~~~~~~~~~~~~~~~~~~(\hat{M}(\mathbf{y})-\langle \hat{M}(\mathbf{y}) \rangle_t)dt\Big] \psi_t \end{split} \end{equation} where $H$ represents the linear part - the standard Hamiltonian of the system, and the other two terms which are non-linear and stochastic modifications, are accountable for the collapse of the wave function. The mass $m_0$ is a reference mass i.e. the mass of a nucleon. Here $\mathcal{G}({\bf x}-{\bf y})$ is the noise two point correlation function which is taken to be Gaussian in this model. $\gamma$, a free parameter of the theory, is the positive coupling constant which sets the strength of the collapse process. $\hat{M}({\bf x})$ is the smeared mass density operator that encodes the amplification mechanism in CSL and is given as, \begin{eqnarray} \hat{M}({\bf x})&=& \sum_{j}m_{j}\hat{N}_{j}({\bf x}) \\ \hat{N}_{j}({\bf x})&=& \int d{\bf y}g({\bf y}-{\bf x})\hat{a}_{j}^{\dagger}({\bf y})\hat{a}_{j}({\bf y}) \end{eqnarray} The number operator $\hat{N}_{j}$ contains $\hat{a}_{j}^{\dagger}({\bf y})$ and $\hat{a}_{j}({\bf y})$ which are, respectively, the creation and annihilation operators of a particle of type $j$ at the space point ${\bf y}$. The smearing function is defined as \begin{equation} g({\bf x})=\frac{1}{(\sqrt{2\pi}r_{c})^{3}}e^{-{\bf x}^{2}/2r_{c}^{2}} \end{equation} The free parameter $r_c$ of the theory represents the correlation length. $W_t({\bf x})$ is an ensemble of Wiener processes representing white noise. The collapse strength $\gamma$ is related to the correlation/ collapse width $r_c$ and the collapse rate parameter $\lambda_{CSL}$ in the following way, $$ \lambda_{CSL} = \frac{\gamma}{(4\pi r_c^2)^{3/2}}$$ $\lambda_{CSL}$ denotes the collapse rate of a single nucleon. For multi-particle systems, the rate is amplified by the total number of particles. The values of these parameters, as suggested in the original theory, are $r_c=10^{-5} cm$ and $\lambda_{CSL}= 10^{-17}s^{-1}$ (we call it $\lambda_{GRW}$). A different and a much stronger value of $\lambda_{CSL} $ was later suggested by Adler based on the observations in the latent image formation in photography, which is $ \lambda_{CSL}=10^{-8}s^{-1}$ (we call it $\lambda_{ADLER}$). Both the values satisfy known experimental observations and only future and more precise experiments can suggest which of these bounds is correct \footnote{The recent experiment reported in \cite{Vinante} is in tension with Adler's choice of parameters. In a recent paper \cite{Adler}, it has been proposed that the CSL noise should be treated as non-white with a frequency cut-off. Adler's parameter values are not ruled out if this scenario is taken into account}. One of the major consequences of CSL dynamics that distinguishes it from quantum theory is the violation of energy-momentum conservation law. Since CSL contains a noise source that interacts with matter, we have a resulting non-conservation of energy and momentum when the system is concerned. The noise field imparts energy and momentum to the particles, causing a Brownian motion-like random motion, and corresponding increase in temperature due to this heating effect. These effects were investigated in \cite{Adler1, Pearle} and possible experiments were suggested in \cite{Bhawna,Bedingham,Goldwater,Adler}. For a sphere of radius $R$, the rms diffusion caused by CSL can be written as, \begin{equation} \Delta x_{CSL} = \frac{\hbar}{m_0 r_c}\left(\frac{\lambda_{CSL}f(R/r_c)}{6}\right)^{1/2} t^{3/2} \label{CSLwalk} \end{equation} Notice that the displacement is not directly dependent upon the mass or density of the particle; the dependence is through the size $R$ of the system. The function $f$ is given as, \begin{equation} f(R/r_c)= 6 \left(\frac{r_c}{R}\right)^4 \left[1-2\frac{r_c^2}{R^2}+ \left(1+2\frac{r_c^2}{R^2}\right)e^{-R^2/r_c^2}\right] \end{equation} For our cases of interest, we take $R \sim r_c$ for which $f \approx 1$ \cite{Bedingham,Bhawna}. It has been suggested in \cite{Bedingham} that the heating effect due to CSL can be detected for a particle trapped inside a Paul trap. The aim of this letter is to investigate the consequences of such heating effect in terms of the stability of the trapped ion. Since CSL induces a random motion causing a particle jitter in space, it may throw a particle out of the stable region. Thus, a charged particle, which would ideally be stable in a given Paul trap configuration, may finally become unstable and come out of the trap due to additional motions caused by CSL noise. In this article, we show how CSL affects the trajectory of an ion inside the trap and work out the resultant stability region for the suggested values of the CSL parameters. Let us consider the motion of an ion in the x-direction. The rms displacement in the x-direction due to the CSL noise is given by \eqref{CSLwalk}. The corresponding effective force on the ion can be obtained by differentiating this twice with respect to $t$. This gives, $$ F_{CSL}= \frac{\hbar m\sqrt{\lambda}}{m_0 r_c \sqrt{6}}\left(\frac{3}{4} t^{-1/2}-\frac{\Omega^2}{4}(a_x + 2 q_x \cos \Omega t) t^{3/2}\right) $$ The second term in the above equation is explicitly due to the extra restoring force acting on an ion as it undergoes CSL random walk, and thus depends on the trap parameters. The resultant equation of motion for an ion inside the Paul trap and acted upon by CSL is thus given by, \begin{eqnarray} m\ddot{x}&+&\left[a_x + 2 q_x \cos \Omega t\right]\frac{m\Omega^2}{4} x \nonumber \\ \nonumber &+&\frac{\hbar m\sqrt{\lambda}}{m_0 r_c \sqrt{6}}\left(-\frac{3}{4} t^{-1/2}+\frac{\Omega^2}{4}\left(a_x + 2 q_x \cos \Omega t\right) t^{3/2}\right)=0\\ \label{cslmathieu} \end{eqnarray} Using the approximation $|a_x|\ll |q_x| \ll 1$, we get an analytical solution of the above equation which looks very complicated. The form of the solution is not presented in this article to maintain brevity, since we perform a fully numerical analysis for the final results. \section{Stability region with CSL dynamics} As mentioned earlier, the trajectory of a charged particle inside a Paul trap can be stable or unstable based on the nature of the solution. If the solution diverges with time (i.e. when $\mu$ is real or complex), then the trajectory becomes unstable. Only for the cases when $\mu$ becomes purely imaginary, the solution is stable and periodic. Thus, the stability depends upon the trapping parameters $a$ and $q$ that define the Floquet index $\mu$.\\ In presence of CSL, things are different and the nature of the solution of the equation \eqref{cslmathieu} now also depends on the CSL parameters $\lambda_{CSL}$ and $r_c$. To see how the stability of the ion trajectory depends upon the four parameters $a$, $q$, $r_c$ and $\lambda_{CSL}$, we make use of the transfer matrix method described in \cite{ref1, ref2}. Here we briefly discuss the method. For a better understanding, readers may refer to \cite{ref1, ref2}. Transfer matrix connects the initial solution $x(0)$ and $v(0)$ with the solution at any time $t$ i.e. $x(t)$ and $v(t)$, where $x(t)$ is the displacement and $v(t)$ denotes the velocity. In matrix formalism, we can write, \[ \left[ {\begin{array}{c} x_1\\ v_1\\ \end{array} } \right]= M \left[ {\begin{array}{c} x_0 \\ v_0\\ \end{array} } \right] \] where $x_0=x(0)$, $v_0=v(0)$, $x_1= x(T=2\pi/\Omega)$ (i.e. the displacement after one period of oscillation), $v_1= v(T=2\pi/\Omega)$ and $M$ is the transfer matrix. Let us consider two linearly independent solutions of the equation of motion: $u_1$ and $u_2$ . Then the general solution for $x(t)$ and $v(t)$ is given by, \begin{eqnarray} x(t)&=& A_1 u_1(t) + A_2 u_2(t) \nonumber \\ v(t)&=& A_1 \dot{u}_1(t) + A_2 \dot{u}_2(t)\nonumber \end{eqnarray} The transfer matrix $M$ can be written as \cite{ref2}, \[ M = \left[ {\begin{array}{cc} u_1(T) & u_2(T) \\ \dot{u}_1(T) & \dot{u}_2(T)\\ \end{array} } \right] \left[ {\begin{array}{cc} u_1(0) & u_2(0) \\ \dot{u}_1(0) & \dot{u}_2(0)\\ \end{array} } \right]^{-1} \] The transfer matrix $M$ has a property $\det(M)=1$ \cite{ref2}. For simplicity, we denote the elements of $M$ as: \[ M = \left[ {\begin{array}{cc} m_{11} & m_{12} \\ m_{21} & m_{22}\\ \end{array} } \right] \] It can be shown that the solution at any time t = nT follow a recursion relation i.e, \[ \left[ {\begin{array}{c} x_n\\ v_n\\ \end{array} } \right]= M^n \left[ {\begin{array}{c} x_0 \\ v_0\\ \end{array} } \right] \] Now, since $M$ is a $2 \times 2$ matrix, it has two eigen values, say $\lambda_1$ and $\lambda_2$ corresponding to two eigenvectors $m_1$ and $m_2$ respectively. The initial solutions can be expressed in terms of the eigenvectors as follows: \[ \left[ {\begin{array}{c} x_{0} \\ v_{0} \\ \end{array} } \right] = A_1 m_1 + A_2 m_2 \] Using the recursion relation, the solution at time $t= nT$ is obtained as, \[ \left[ {\begin{array}{c} x_{n} \\ v_{n} \\ \end{array} } \right] = A_1\lambda_1^n m_1 + A_2 \lambda_2^n m_2 \] We say that the solution is stable, i.e, it does not diverge after $t=nT$ if $|\lambda_1|, |\lambda_2| \leq 1$ since, otherwise $\lambda_1^n, \lambda_2^n$ becomes arbitrarily large for $n \gg 1$. This is precisely the stability condition that the solution needs to satisfy in order to represent a stable trap configuration. The values $\lambda_1,\lambda_2$ can be obtained from the following characteristic equation, \[ \det \left[ {\begin{array}{cc} m_{11}-\lambda & m_{12} \\ m_{21} & m_{22}-\lambda\\ \end{array} } \right] =0 \] The solutions are given as \begin{equation} \lambda_{1,2}= s \pm i\sqrt{1-s^2} \end{equation} where $s= (m_{11}+m_{22})/2 = Tr(M)/2$\\ Now, for $|s| \leq 1$, we have, $|\lambda_1|,|\lambda_1| = 1$. This requires $|Tr(M)| \leq 2$. On the other hand, for $|s| > 1$, we get both $\lambda_1$ and $\lambda_2$ to be real, and one of them is always greater than $1$ making the solution diverge. Thus, the stability conditions as obtained from transfer matrix method is, \begin{eqnarray} |Tr(M)| &\leq & 2 \quad {\rm for ~ stable ~ solution} \nonumber \\ |Tr(M)| & >& 2 \quad {\rm for ~ unstable ~ solution} \end{eqnarray} Thus, for a given set of values of $a$, $q$, $r_c$ and $\lambda_{CSL}$, the solution is said to be stable if the trace of this matrix lies between $\pm 2$. To get the stability zone in the $a-q$ parameter space, we fix $r_c$ and $\lambda_{CSL}$ to the suggested values by Ghirardi-Rimini-Weber ($r_c = 10^{-5}$ cm, $\lambda_{GRW} = 10^{-17} s^{-1}$) and Adler ($r_c = 10^{-5}$ cm, $\lambda_{ADLER} = 10^{-8} s^{-1}$) respectively, and plot the combinations $a,q$ for which $|Tr(M)| \leq 2$. The pair of points in $a-q$ plane, for which this condition is violated, correspond to unstable region. Below we show the stability zone for Adler's choices of CSL parameters. We can compare this stability plot with the usual stability region of Mathieu's equations and it is evident that there is no visible change in the stability diagram. This is good in the sense that one does not need to worry much about the alteration of ion stability in the presence of CSL. But care must be taken for certain configurations of the trap, especially for those values of $a$, $q$ which are very close to the boundary of the stable region since CSL induced random motions can make such points unstable. In fact, we do find that certain stable points move out to the unstable region if the CSL effect is made strong enough. \vspace{.5in} \begin{figure}[H] \centering \includegraphics[width=9cm,height=6cm] {cslstabilityplotfull.pdf} \caption[Optional caption for list of figures]{\small Full stability region of a Paul trap in the presence of CSL. The dotted regions represent the stable regions which appear in form of bands.} \end{figure} Next we choose a pair of points ($a,q$) very close to the boundary of the stability curve of the Mathieu equation, and by demanding that this point remains stable even with CSL, we put bounds on $r_c$ and $\lambda_{CSL}$. \newpage Below we show the allowed region in the $r_c-\lambda_{CSL}$ parameter space by choosing $a=-0.000526947, q= 0.0326158$ which is a stable point for Mathieu equation but very close to the boundary. This can be achieved, for example, for a trap configuration with RF oscillator frequency $\sim 100$ MHz, a dc voltage of the order of $\sim 70$ V, ac zero-to-peak voltage amplitude $\sim 8$ kV (sign of the voltage applied depends upon $x$ or $y$ direction) for a trapped ion with a mass-to-charge ratio of $\sim 100$ kg/Coulomb. These parameters are typically used in Paul trap experiments \cite{parameter1,parameter2}. Figure \ref{bound} shows the corresponding plot of $Log_{10} \lambda$ vs $Log_{10} r_c$. The dotted region represents the parameter space allowed by the stability analysis (i.e. they do not alter the stability of the above mentioned point). The white region represents unstable region. Although the bounds obtained are similar in nature to the bounds obtained from X-ray emission from an isolated Germanium slab in \cite{xray}, we find that the bounds obtained are rather weak and both $\lambda_{GRW}$ and $\lambda_{ADLER}$ are well inside the allowed region. \begin{figure}[H] \centering \includegraphics[width=9cm,height=6cm] {lambdarcplot.pdf} \caption[Optional caption for list of figures]{$\lambda-r_c$ exclusion plot from the stability of charged particles in a Paul trap. The dotted region shows the allowed parameter space. The GRW and Adler parameter values ($\lambda_{GRW} = 10^{-17} s^{-1}$ and $\lambda_{ADLER} = 10^{-8} s^{-1}$) lie well within the allowed region.} \label{bound} \end{figure} In an actual experiment involving Paul traps, there will be other factors present inevitably during the experiment that can produce significant amount of noise. In particular, one has to deal with the noises coming from fluctuations in the electromagnetic field, collision of the charged particle with ambient gas molecules, mechanical vibrations, production of eddy currents etc. very carefully to eliminate any disturbances that can jeopardize the stability of the trapped body. This has been discussed and taken into account in \cite{Bedingham}. In principle, with proper experimental parameters, such noises can be minimized and can be made subdominant to CSL effect, as has been shown in ref. \cite{Bedingham}. \begin{figure}[H] \centering \includegraphics[width=9cm,height=8cm] {bassibound.jpg} \caption[Optional caption for list of figures]{Constraints on CSL parameters $\lambda_{CSL}$ and $r_c$ coming from various experiments. The plot has been taken from ref. \cite{CSLbound1}} \label{bassi} \end{figure} \section{Discussions} Recently, with growing interests in testing collapse models, the field has seen a surge of interesting experimental ideas which can possibly give stringent bounds on CSL model parameters. A number of experiments have already ruled out a large portion of the parameter space. Recently in \cite{CSLbound1,CSLbound2}, the authors have put bounds on the CSL parameters coming from LIGO, LISA and AURIGA. If we also consider bounds on parameters based on purely theoretical arguments, then the allowed parameter space becomes even smaller and $\lambda_{GRW}$ lies just at the boundary of the upper bounds coming from theoretical arguments \cite{thbound}. Figure \ref{bassi} shows various bounds on CSL parameters coming from different experiments. In the plot, the shaded regions of blue, green, and red lines are the exclusion regions as coming from LIGO, LISA Pathfinder, and AURIGA. Blue and green dashed lines represent upper bounds from foreseen improved sensitivity of LIGO and LISA Pathfinder, respectively. Purple line (towards the top) shows the upper bound from ultracold cantilever experiments \cite{cantilever}. Light blue region is excluded from x-ray experiments \cite{xray}. Gray region near the bottom is the exclusion zone based on theoretical arguments \cite{thbound}. The GRW and Adler values and ranges are indicated in black. It would be interesting to check if $\lambda_{GRW}$ can be ruled out by experiments, and in that case we would have made the bounds even more stringent or possibly would invalidate the theory as a whole. At this juncture, it thus becomes very important to take care of each and every minute aspect in a proposed experiment, for example, various sources of noise, experimental setup, particle dynamics, careful and precise detection techniques etc. Any of these factors could affect the final outcome and lead to an erroneous conclusion. In this article, we discuss one of these factors that is effect of CSL dynamics on the stability of charged particles inside a Paul trap. Paul traps are used in such experiments to confine the particle in a small region so that the heating effect or the random displacement due to CSL can be observed. It is thus very important to make sure that the particle remains confined inside the stable region even when CSL noise force tries to displace it in random directions. Our study deals with the backreaction of CSL motion on the particle trajectory. The results show that for $\lambda_{GRW}$ parameters, there is no significant change in the stability zone. However, the points near the stable zone boundary can become unstable for certain values of the CSL parameter and hence extreme care should be taken while working in such a region. Ideally the trapping parameters should be chosen such that it lies well inside the stability zone, as for such cases, the CSL random motion will be ineffective to drive the particle out of its stable trajectory. \\ We have also plotted an exclusion plot for CSL parameters based on the Paul trap stability criteria. The bounds obtained are very similar to the constraints coming from X-ray experiments \cite{xray}, as can be seen in the plot above, but rather weaker. Future experiments are expected to produce stronger bounds and pushing the allowed region in the CSL parameter space further down before the theory can be ruled out with confirmation. \section*{Acknowledgements} We would like to thank Hendrik Ulbricht, Jerome Martin and Tejinder P. Singh for various helpful discussions and the organizers of the FPQP 2016 meeting held at ICTS, Bangalore (India) where the idea was conceived. \newpage
\section{Introduction}\label{section:intro} In the Galactic bulge, the Red Clump (RC) stars, which are core-helium burning low-mass stars with ages from intermediate (1$\leq$age<10 Gyr) to old (age$\geq$10 Gyr) and average to high metallicities \citep[{[Fe/H]}$\gtsim$--1.5 dex,][]{cole1998,hill2011}, are used extensively to study their kinematics, chemical abundances, and spatial distributions \citep{mcwilliamzoccali2010,saito2011,gonzalez2015, zoccali2017}. High-resolution spectroscopic studies of RCs suggest that only stars that are more metal-rich than [Fe/H]$\sim$--0.5 dex trace an X-shaped structure that appears to be in the form of a peanut-boxy bulge \citep{ness2013,zoccali2016}. Recently, mid-infrared data obtained with the Wide-field Infrared Survey Explorer (WISE) also showed a clear large-scale X structure \citep{nesslang2016}. In contrast, stars that are more metal-poor than [Fe/H]$\sim$--0.5 dex not only display a centrally concentrated axisymmetric spatial distribution, but also reveal different kinematics \citep{ness2013,valenti2016,zoccali2017}. However, the spatial distribution of the old and more metal-poor population of stars in the bulge, which is traced by RR Lyr{\ae} (RRLs), is still under discussion. \citet{pietrukowicz2015} found an ellipsoidal distribution (axis ratios of 1 : 0.49$\pm$0.02 : 0.39$\pm$0.02), elongated along the same direction as the bar traced by the metal-rich red giants, while \citet{dekany2013} and \citet{kunder2016} found a spheroidal distribution. Type II Cepheids (T2Cs) are old (>10 Gyr), low-mass post-horizontal branch, asymptotic giant branch (AGB) and post-AGB stars. Like the RRLs, T2Cs trace old stellar populations, but they have longer periods (1-80 days), are brighter by 1-3 mag, and their amplitudes can be up to twice as large as those of the RRLs. In his pioneering work that led to the separation of Population I and Population II stars, \citet{baade44} showed that T2Cs are distance indicators that obey a period-luminosity (PL) relation different from that of Classical Cepheids. T2Cs have been widely used in the literature as distance indicators, both in the optical \citep{harris85,nemec1994} and in the near-infrared (NIR) bands \citep{matsunaga06,matsunaga11a,bhardwaj17b,bhardwaj17c}, although not as frequently as RRLs and Classical Cepheids. A key feature of the PL relations is that their intrinsic dispersion becomes smaller from the optical to the NIR \citep{dicriscienzo07}. This means that NIR PL relations are not only more accurate because the reddening is less severe, but they are also intrinsically more precise. Near-infrared photometry of T2Cs in the bulge obtained with the Son of ISAAC (SOFI) telescope was used by \citet{groenewegen08} to estimate the distance of the Galactic center ($R_0$=7.99$\pm$0.09 kpc) using a sample of 38 T2Cs. \citet{bhardwaj17c} matched photometry of the VISTA Variables in the V\'ia L\'actea (VVV) survey \citep{minniti2010,saito2012} with the OGLE III version of the catalog of T2Cs \citep[][335 T2Cs]{soszynski2011} and obtained individual distances. They estimated $R_0$=8.34$\pm$0.03 kpc and ruled out a barred structure. All recent estimates of $R_0$ based on other diagnostics and recent reviews agree that the official IAU value of $R_0$=8.5 kpc is overestimated ($R_0$=8.2$\pm$0.1 kpc, \citealt{blandhawthorn2016}; $R_0$=8.3$\pm$0.2$\pm$0.4 kpc, \citealt{degrijs2016}). Recently, the Optical Gravitational Lensing Experiment (OGLE) IV survey \citep{udalski2015} has generated the largest homogeneous sample of T2Cs known to date, amounting to 924 objects projected toward the Galactic bulge \citep{soszynski2017}. This is almost three times the size of the previous sample. The VVV survey has collected NIR $K_s$-band time series toward the Galactic bulge in a sky area that covers almost the entire OGLE survey area and provides an optimal framework to characterize the structure of the old population of the Galactic bulge with stellar tracers such as RRLs and T2Cs, for which the optical photometry and accurate periods are available from the OGLE survey. The increase of the sample size with respect to previous works is a unique opportunity to achieve new insight into the old stellar population in the bulge, especially for a detailed comparison with RRLs, which has always been hampered by the small sample size of T2Cs. Furthermore, we have the unprecedented opportunity to combine the T2C NIR catalog with the proper motion measurements from VVV itself \citep{contreras2017,smith2018} and {\it Gaia} DR2 \citep{gaia_alldr,gaia_dr2} to constrain the kinematic properties of the old stellar population. The paper is organized as follows: in Section~\ref{section:data} we present our photometric and astrometric databases. We analyze the light curves and derive their properties in Section~\ref{section:lcv}. Section~\ref{section:pls} is dedicated to estimating individual distances of T2Cs and their overall distribution, while in Section~\ref{section:kinematics} we discuss the kinematic properties of our targets. We discuss and summarize our results in Section~\ref{section:conclusions}. \section{Data}\label{section:data} {\it Light curves.} We used the aperture photometry of VVV DR4 data \citep{minniti2010,saito2012} that is publicly available through VISTA Science Archive (VSA)\footnote{\url{vsa.roe.ac.uk/index.html}}. We compared point spread function (PSF) with aperture photometry for a sample of our targets and found the differences to be negligible, but aperture photometry has the advantage of being available in the entire VVV survey area. As a first step, we matched the OGLE IV catalog of T2Cs \citep{soszynski2017} with the source detection catalog of VVV, adopting a matching radius of 2{\sec}. This allowed us to retrieve 894 of 924 targets within the VVV survey area. A posteriori, we checked that all the good matches are within 1\Sec3 of the OGLE coordinates. Of those that were not retrieved, 25 are outside the VVV area, and for five of them we could not find a good match, even with a larger searching radius of 10{\sec}. Of these 894 T2Cs, according to the classification of \citet{soszynski2017}, 369 are BL Herculis (BLHs), 343 are W Virginis (WVs), 28 are peculiar W Virginis (pWVs), and 154 are RV Tauri (RVTs). We discuss the different types of T2Cs in more detail in Section~\ref{section:dist}. We collected both the single-epoch $JH$-band photometry and the $K_s$-band time series. $ZY$ photometry was neglected because it is not useful for our goals and we cannot even estimate mean magnitudes in these bands, since light-curve templates \citep{bhardwaj17b} are available only for the $JHK_s$ bands. The number of valid $K_s$-band phase points per variable (those with good photometric solution) ranges from four to 185, with a median of 51. Only four variables have fewer than ten phase points, and 90\% of the variables have more than 47 observations, with a good phase coverage over the whole range of periods of our targets (1-85 days). The number of available $K_s$ epochs varies across the VVV survey area, with the majority of the VVV pointings (so-called tiles) having between 50-100 epochs. Given the overlap between the adjacent tiles, which amounts to about 1{\min} on a side, a small fraction of our variables (34) were observed in two tiles, with up to 185 data points. {\it Reddening.} We adopted the two Galactic bulge E(\jmk) reddening maps of \citet{gonzalez2012} and \citet{schultheis2014}, henceforth, G12 and S14. The reasons are manifold: {\it 1)} They were both obtained with VVV data, therefore no photometric system conversion is needed. {\it 2)} The map of G12 provides very high resolution especially in the central regions (2$\times$2 arcmin for --3\Deg5<$b$<5\Deg0, 4$\times$4 arcmin for --7\Deg0<$b$<--3\Deg5 and 6$\times$6 arcmin for --10\Deg0<$b$<--7\Deg0), while the ``pixels'' of the S14 map have a size of 6$\times$6 arcmin everywhere. However, the map by S14 has the key advantage to be three-dimensional. It provides a grid of E(\jmk) for 21 bins of distance, from 0 to 10.5 kpc. This is crucial for studying a complex structure such as that of the Galactic bulge and possibly intervening thick-disk populations. In the following, we indicate as E(\jmk)$_{G12}$ and E(\jmk)$_{S14}$ the two reddening values obtained from the G12 and S14 maps, respectively. As explained in Section~\ref{section:lcv}, we adopt the 3D reddening map of S14 for our final estimates, but G12 serves as a comparison. {\it Proper motions.} We retrieved relative proper motions for 894 of 924 targets from the publicly available VIRAC catalog \citep{smith2018}, obtained with VVV data. According to their recommendations, we discarded all targets for which the flag $reliable$, based on the validation of the photometric solutions, is equal to zero. We point out that although the cross-match was made by unique VVV ID and not by coordinate, we found multiple (either double, triple, or quadruple) records for 120 targets in VIRAC. We checked the multiple identifications one by one on the basis of right ascension ($\alpha$), declination ($\delta$), and $K_s$-band magnitude. About two-thirds of the time, all of the records of a multiple identification had $reliable$=0 and were thus all discarded. Of the remaining fraction, an a posteriori check revealed that the majority had $reliable$=1 for the correct match and $reliable$=0 for the incorrect matches. This validates our selection of the best match. We also retrieved relative proper motions for 416 targets from PSF photometry, obtained from VVV data by the method explained in \citet{contreras2017}. The match was performed using a searching radius of 2\sec. This catalog of proper motions does not cover the entire VVV area, but only the low latitudes (--3\Deg0$\ltsim b \ltsim$3\Deg0), that is, the most crowded region, where PSF photometry has several advantages over aperture photometry. A comparison between the two sets of proper motions from the VVV is performed in Section~\ref{section:kinematics}. Finally, we searched our targets within the recent {\it Gaia} DR2 \citep{gaia_alldr,gaia_dr2}, using a searching radius of 4\sec. We retrieved matches for 920 targets. Because of the density of {\it Gaia} DR2, a search radius of 4{\sec} means multiple records for almost all our targets. We note that for {\it Gaia}, we needed a larger searching radius because $\alpha$ and $\delta$ are at the epoch J2015.5. We selected the best matches on the basis of the separation in ($\alpha$,$\delta$) and the $V-G$ and $I-G$ color indexes, and retrieved 914 targets (for the remaining 6 targets, it was not possible to select a best match based on the adopted criteria). Of these, 868 have a five-parameter {\it Gaia} solution (coordinates, parallaxes, and absolute proper motions). \section{Light curves and properties of T2Cs}\label{section:lcv} We have phased the VVV light curves using the periods provided by OGLE IV \citep{soszynski2017}. We visually inspected all the VVV light curves and separated promising from noisy or poorly sampled light curves. We estimated the uncertainty on the mean magnitude ($eK_s$) as the sum in quadrature of the standard error of mean of the phase points around the fit (see below) plus the median photometric error of the phase points. We note that the standard error on the mean and median photometric error represents a statistical and systematic measure of uncertainties, respectively, $$eK_s = \sqrt{\dfrac{1}{n}\dfrac{\sum_{i=1}^{n} (mag_i-mag_{i(fit)})^2}{n-1}+median(err)^2.}$$ We adopted $eK_s$ as a quantitative criterion to select good-quality light curves, with a threshold at $eK_s<0.05$. We performed visual inspection to validate this threshold and further selected promising light curves within the range $0.05<eK_s <0.10$~mag. However, some of the brighter stars ($\langle K_s\rangle \lesssim 11.5$~mag) were classified as poor-quality light curves in this range (see below), and all stars with $eK_s >0.10$ mag were also included in the poor-quality sample. Examples of good- and poor-quality light curves are displayed in Figure~\ref{fig:lc_eg}. \begin{figure*}[!htbp] \centering \includegraphics[height=8cm]{OGLE-BLG-T2CEP-269_8_CASU_ap_polyx.eps} \includegraphics[height=8cm]{OGLE-BLG-T2CEP-272_8_CASU_ap_polyx.eps} \caption{Left: Example of a good-quality light curve. Right: Example of a poor-quality light curve. The periods are labeled at the top of the panels, while the names, as provided in the OGLE catalog, are labeled at the bottom. The PLOESS fit of the good-quality light curve is displayed as a red line.} \label{fig:lc_eg} \end{figure*} For the 161 targets with poor-quality light curves, we adopted for the mean magnitude the median of the magnitudes, converted into flux, of the individual phase points. The uncertainty on the mean magnitude is the standard deviation of the median. We do not provide a light-amplitude estimate for these targets since the uncertainty would be on the same order as the amplitude itself. We point out that most of these targets are very bright (135 of 161 have $\langle K_s\rangle \lesssim 11.5$~mag), meaning that they are either saturated or in the nonlinear regime of the camera. However, we also point out that not all stars in this magnitude range have poor-quality light curves. The cause of poor photometry is a synergy between saturation and crowding by other nearby bright stars. The magnitude for saturated sources is derived from the most external apertures (those with the largest radii). When another bright source contaminates the external aperture, the photometric solution is worse. In these cases, PSF photometry would not help to improve the photometry because it would be even more affected by saturation. To compute the mean magnitudes, amplitudes, and relative uncertainties of the good-quality targets, we adopted the fits of the light curves obtained with the PLOESS \citep{braga2018} fitting method, which is a variant of the GLOESS method \citep{persson2004}. The mean magnitude is the integral of the fitting curve converted into flux, while the amplitude is the difference between the brightest and faintest points of the fit. The uncertainty on the mean magnitude was defined before as $eK_s$. The uncertainty on the amplitude was derived as the sum in quadrature of the median photometric errors of the phase points around the maximum and minimum, plus the standard deviation of these phase points around the fit of the light curve. The final value was weighted with the number of phase points around the maximum and the minimum. We also derived mean $J$- and $H$-band magnitudes by applying the light-curve templates of \citet{bhardwaj17b} to the single $J$ and $H$ phase points and using the time of maximum from OGLE \citep{soszynski2017}. The photometric properties of our final sample are listed in Table~\ref{tab:jhk}. \begin{table*} \scriptsize \caption{Photometric properties of target T2Cs.} \centering \begin{tabular}{l l l l c c c c c c c} \hline\hline ID (OGLE IV)\tablefootmark{a} & ID (VVV) & ID ({\it Gaia}) & Type & Period & $\langle V \rangle$ & $\langle I \rangle$ & $\langle J \rangle$ & $\langle H \rangle$ & $\langle K_s \rangle$ & Amp($K_s$) \\ & & & & days & mag & mag & mag & mag & mag & mag \\ \hline 001 & \ldots & 5980064527510861824 & BLHer & 3.9983508 & 15.759 & 14.176 & \ldots & \ldots & \ldots & \ldots \\ 002 & 515601356315 & 5979966877097299328 & BLHer & 2.2684194 & 15.188 & 13.909 & 12.976$\pm$0.006 & 12.644$\pm$0.007 & 12.507$\pm$0.004 & 0.212$\pm$0.013 \\ 003 & 515601679485 & 5979980380479944704 & BLHer & 1.4844493 & 16.519 & 15.061 & 14.027$\pm$0.007 & 13.648$\pm$0.009 & 13.409$\pm$0.008 & 0.334$\pm$0.019 \\ 004 & \ldots & 4107385973738284672 & BLHer & 1.2118999 & 16.404 & 14.856 & \ldots & \ldots & \ldots & \ldots \\ 005 & 515594023082 & 5980291576574487808 & BLHer & 2.0075505 & 18.666 & 16.842 & 15.485$\pm$0.024 & 14.993$\pm$0.034 & 14.782$\pm$0.034 & 0.407$\pm$0.040 \\ 006 & \ldots & 4107420780154292480 & pWVir & 7.6364832 & 14.728 & 13.352 & \ldots & \ldots & \ldots & \ldots \\ 007 & 515543342733 & 4059723965740384128 & BLHer & 1.8174741 & 17.452 & 15.530 & 13.696$\pm$0.010 & 13.559$\pm$0.012 & 13.292$\pm$0.011 & 0.286$\pm$0.014 \\ 008 & 515520862858 & 4059946032759214976 & BLHer & 1.1829551 & 17.765 & 15.970 & \ldots & 14.034$\pm$0.015 & 13.967$\pm$0.017 & 0.183$\pm$0.019 \\ 009 & 515555436341 & 4059508427192076928 & BLHer & 1.8960190 & 17.620 & 15.657 & 14.003$\pm$0.009 & 13.457$\pm$0.011 & 13.266$\pm$0.013 & 0.336$\pm$0.029 \\ 010 & \ldots & 4109969452496082432 & BLHer & 1.9146565 & 16.639 & 14.969 & \ldots & \ldots & \ldots & \ldots \\ \hline \end{tabular} \tablefoot{Only the first 10 of the 924 lines of the table are shown. The full table is shown in the machine-readable version of the paper.\\ \tablefoottext{a}{The full name is OGLE-BLG-T2CEP-XXX, where ``XXX'' is the ID appearing in the first column.}} \label{tab:jhk} \end{table*} Next, we corrected the mean magnitudes for extinction. As stated in section~\ref{section:data}, we derived two extinction values from two different reddening maps. We obtained E(\jmk)$_{G12}$ and $A_{Ks(G12)}$ for each target from the online tool BEAM\footnote{\url{mill.astro.puc.cl/BEAM/calculator.php}}. However, estimating E(\jmk)$_{S14}$ is not straightforward because the distance of the target needs to be known in order to obtain E(\jmk)$_{S14}$. Distance and reddening in S14 are degenerate. Therefore, we adopted the following method. First, we located the four pixels of the map that are closest to the position of our target. We weighted the E(\jmk)$_{S14}$ of each pixel by their inverse angular distance of the pixel center from our target. We repeated this for each of the 21 bins and obtained 21 possible values for E(\jmk)$_{S14}$ for each target. Using an iterative method \citep{bhardwaj17c}, we simultaneously found the most plausible values of E(\jmk)$_{S14}$ and $A_{Ks(S14)}$ and an estimate of the distance. We adopted a new reddening law with both reddening maps to derive the extinction $A_{Ks}$ from E(\jmk). This law was derived by \citet{alonsogarcia2017} using VVV data for the innermost regions of the bulge between $|l|$<2\Deg7 and $|b|$<1\Deg55. Specifically, we adopted as the ratio of total-to-selective extinction $R_{JK}=\dfrac{A_{Ks}}{E(\jmk)}$ the values shown in their Table 2, according to the quadrant, within their surveyed sky area. For targets outside the quoted area, we adopted $R_{JK}$=0.428, which is the average suggested by \citet{alonsogarcia2017}. We checked the differences $\Delta A_{Ks}$ = $A_{Ks(G12)} - A_{Ks(S14)}$ for all our targets, and found that $\Delta A_{Ks}$ values follow an almost Gaussian distribution with a mean of --0.007 mag and $\sigma$=0.032 mag. A tail of targets with 0.1<$\Delta A_{Ks}$<0.25 mag and one target with $\Delta A_{Ks}$ as high as 0.63 mag were found. Almost all of these targets are located at distance moduli (DM) smaller than 14.5 mag ($\sim$8 kpc). This means that they are closer than the Galactic center. On the other hand, targets with $\Delta A_{Ks}$<--0.1 mag are mostly located at DMs larger than 14.5 mag. This is expected when comparing a reddening map fixed at $\sim$8 kpc (G12) with one that takes distance into account (S14). This also suggests that we can adopt the S14 map to derive our final results. However, since reddening and distance were derived simultaneously, $A_{Ks(S14)}$ may depend on the calibration selected for the PL relation. We checked that for different calibrations (see Section~\ref{section:dist}), the differences between $A_{Ks(S14)}$ from different calibrations are within 0.05 mag and are smaller than 0.01 mag for $\sim$80\% of the targets \section{PL relations and distances}\label{section:pls} \subsection{Empirical PL relation}\label{section:pl_empirical} Figure~\ref{fig:pl} shows the targets in the $\log{P}$-$K_{s0}$ plane. The BLHs and WVs were dereddened adopting the S14 map, but $A_{Ks(S14)}$ values and distances were estimated simultaneously. Since we did not estimate the distances of pWVs and RVTs, as explained below, these targets were dereddened with $A_{Ks(G12)}$, which is independent of distance. In stellar system like the bulge, where stars are not all at the same distance (as in the case of globular clusters, external galaxies, etc.), extinction and distance are degenerate and a simple empirical PL does not provide precise insight into the structure, especially if the reddening is not constant. Moreover, there is a debate on whether the old population in the bulge is indeed spheroidal \citep{dekany2013,kunder2016} or if it is ellipsoidal and tilted, similarly to the Galactic bar \citep{pietrukowicz2015}. Therefore, as done before by \citet{groenewegen08}, we fit the PL relation by adding the dependence on the Galactic longitude ($l$) and latitude ($b$). We selected all the BLHs and WVs from our sample, and after an iterative rejection of outliers at more than 3$\sigma$, we found $K_{s0} = (10.66\pm0.02) - (2.21\pm0.03)\cdot(\log{P}-1.2) - (0.020\pm0.003)\cdot l + (0.050\pm0.008)\cdot |b|$ mag, with a standard deviation of 0.07 mag. The positive coefficient in $|b|$ means that fainter stars are located at higher distances from the Galactic plane, where the reddening is lower. This is an evidence that the T2C sample is biased by reddening. On the other hand, the non-zero dependence of $K_{s0}$ on $l$ indicates that the T2C ellipsoid is tilted. If we ignore the $l$ and $|b|$ terms, the simple PL relation is $K_{s0} = (10.76\pm0.02) - (2.23\pm0.03)\cdot(\log{P}-1.2)$ mag, and the standard deviation increases to 0.28 mag. Figure~\ref{fig:pl} shows our newly derived empirical, coordinate-independent PL as a black solid line. We set the zero of the independent variable at $\log{P}$=1.2 to facilitate comparison with \citet{groenewegen08}. The coefficients of both the coordinate-dependent and the simple PL relations agree remarkably well with those obtained with an identical approach by \citet{groenewegen08}: all of them agree within 1$\sigma$. However, while the error on the coefficient of the $l$ coordinate in \citet{groenewegen08} was larger than the value itself (--0.028$\pm$0.031 mag/\deg, thus including the zero value within 1$\sigma$), our coefficient is more precise (--0.019$\pm$0.003 mag/\deg) because the set of variables is much larger, and it clearly rules out a PL relation that is independent of $l$. We also compared our empirical PL with that of \citet[][ $K_{s0} = (10.749\pm0.0056) - (2.189\pm0.032)\cdot(\log{P}-1.2)$ mag]{bhardwaj17c}. We adjusted their zero-point since they had adopted $\log{P}$=1.0 as the zero of their independent variable. The slope and zero-point both agree with ours within 1$\sigma$. \begin{figure*}[!htbp] \centering \includegraphics[width=11cm]{pk_ogle4.eps} \vspace{-0.2cm}\caption{Top: Bulge T2Cs in the period-luminosity plane. Dark blue, light blue, and cyan circles mark BLHs, WVs, and RVTs, respectively. Red crosses mark pWVs. Bottom: Close-up of the empirical PL$K_{s0}$ relation obtained by fitting BLHs and WVs in our sample (black solid line). Larger symbols display BLHs and WVs that were kept after an iterative 3$\sigma$ clipping procedure. The purple, red, and green dashed lines display the literature PL$K_{s0}$ shifted by 14.6 mag ($\sim$8.3 kpc) of \citet{matsunaga06}, \citet{groenewegen08}, and \citet{bhardwaj17b}, respectively.} \label{fig:pl} \end{figure*} The bottom panel of Figure~\ref{fig:pl} also shows PLs from the literature, Galactic globular clusters (\citealt{matsunaga06}), bulge (\citealt{groenewegen08}), Large Magellanic Cloud (LMC; \citealt{bhardwaj17b}) as purple, red, and green dashed lines, respectively. The PL relations of \citet{matsunaga06} and \citet{bhardwaj17b} were placed at a DM of 14.6 mag ($\sim$8.3 kpc), which is the best recommended value of $R_0$ in the literature in general \citep{blandhawthorn2016,degrijs2016} and a very common value obtained from methods based on the PL of RRLs and T2Cs \citep{dekany2013,pietrukowicz2015,bhardwaj17c,majaess2018}. We note that the slope of our relation is the same within the uncertainties as the slope found by \citet[][b$_{B17}$=--2.21$\pm$0.02 mag]{bhardwaj17b}. Finally, we note that RVTs are systematically fainter than predicted by the PLs, which would be $K_{s0}$<10 mag. This is an effect of saturation, which in the VVV is severe at magnitudes brighter than $K_s\sim$10.0 mag \citep{minniti2010,mauro2013}. This is also supported by the fact that as we discuss in Section~\ref{section:dist}, RVTs are expected to be either brighter than predicted by the PL \citep{matsunaga2009a,matsunaga11a,ripepi2015} or to follow the PL \citep{matsunaga06,bhardwaj17b}, but not to be fainter. We also checked for possible selection biases that would favor the selection of the closest RVTs, but found none. This further supports the saturation scenario for these variables. \subsection{Individual distances}\label{section:dist} Before deriving individual distances, we discuss a few key points below. {\it 1) Metallicity dependence.} There is a general consensus about the independence, or a very mild dependence, less than 0.1 mag/dex \citep{dicriscienzo07}, of the PL relation of T2Cs on metal abundance, based on both empirical \citep{matsunaga06,matsunaga11a} and theoretical \citep{bono97e,dicriscienzo07} arguments. The advantage of adopting a metal-independent PL relation to calibrate distances is straightforward because the metallicity of our targets is unknown. Since T2Cs belong to the same stellar population as RRLs, their metallicity dispersion should be similar, and it should be fairly small \citep[0.25 dex,][]{pietrukowicz2012}. {\it 2) RV Tauri and peculiar W Virginis.} T2Cs are separated into BLHs (1 day<P<5 days), WVs (5 days<P<20 days), and RVTs (P>20 days). The thresholds are those by \citet{soszynski2011}. They are based on the period distribution of OGLE III T2Cs, and the authors kept them unchanged in the OGLE IV catalog \citet{soszynski2017}. However, there is a debate as to whether RVTs obey the same PL as shorter-period T2Cs: \citet{matsunaga2009a} using data from the InfraRed Survey Facility (IRSF) and \citet{ripepi2015} using VMC data, showed that in the LMC, RVTs are overluminous with respect to the extrapolation at long periods of the PL of BLHs and WVs. In contrast, \citet{bhardwaj17b} used NIR data in the central bar of the LMC \citep{macri2015} and found that RVTs also fall on the linear PL fit to short-period T2Cs in the LMC. However, their photometry for short-period variables (that is, at fainter magnitudes) was more prone to be affected by crowding in the central regions than longer-period variables. On the other hand, RVTs in Globular clusters also follow the same PL relation as shorter period T2Cs \citep{matsunaga06}. We do not discuss this in detail since this is not the aim of this work, but it is crucial to remember that in addition to these empirical findings, there are two different evolutionary channels from which RVTs are generated: either from low-mass ($\sim$0.50 M$_{\odot}$), very old (>10 Gyr) AGB stars \citep{wallerstein2002}, or from more massive ($\gtsim$1 M$_{\odot}$) and younger objects \citep{willsontempleton2009}. Recent findings about RVTs also involve binarity, to distinguish their evolutionary channel \citep{manick2018}. This means that RVTs are not reliable as distance indicators, and we did not take them into account for our PL relations. Finally, following the classification in \citet{soszynski2017}, we also discarded pWVs, which are a subclass of WVs that likely belong to binary systems \citep{soszynski08c}. They are overluminous \citep[0.3-0.5 mag in the $K_s$ band][]{ripepi2015} when compared to WVs with similar periods. This means that they do not follow the PL relation of T2Cs and cannot be used as distance indicators. We note that pWVs in Figure~\ref{fig:pl} are not more luminous than WVs at the same period. Nonetheless, we did not take them into account for the quoted reasons. {\it 3) No semi-empirical calibration.} In principle, it is not possible, in our case, to adopt a semi-empirical calibration (empirical slope from our own sample and zero-point from literature) for the PLs because our targets are not all located at the same distance. This is true in principle, even though our empirical slope is identical within 0.01 mag to that by \citet{bhardwaj17b}, as stated in section~\ref{section:pl_empirical}. {\it 4) Selection of the calibration.} Keeping these points in mind, we have searched the literature, where several calibrations of the PL relation of T2Cs in the NIR are available \citep[][henceforth PL$_{M06}$,PL$_{D07}$,PL$_{M09}$,PL$_{R15}$,PL$_{B17}$ and PL$_{C17}$]{matsunaga06,dicriscienzo07,matsunaga2009a,ripepi2015,bhardwaj17b,clementini2017}. We rule out the preliminary calibration PL$_{C17}$, based on {\it Gaia} DR1 parallaxes, because it yields DM$_{LMC}$>18.9 mag, which does not agree with literature values nor with the {\it Gaia} DR1 calibration of RRLs and Classical Cepheids derived in the same work. We note that PL$_{M09}$, PL$_{R15}$ and PL$_{B17}$, which are all based on T2Cs in the LMC, do not provide absolute calibrations of their PLs. Therefore, we adopted the distance of the LMC based on eclipsing binaries \citep[][DM$_{LMC}$=18.493$\pm$0.008$\pm$0.047 mag]{pietrzynski2013} to set the zero-point. In principle, we could calibrate the zero-point using Baade-Wesselink parallaxes for field T2Cs obtained by \citet{feast08}, but this would be based only on two objects, with a strong difference among the different values of the parallaxes in the literature. After checking each of these calibrating PLs, we decided to adopt PL$_{B17}$. The choice was guided by the following reasons. First, the calibrating PL must be based on both BLHs and WVs. This rules out PL$_{D07}$ since they only used BLHs pulsation models. Second, of the three PLs from the LMC (PL$_{M09}$, PL$_{R15}$ , and PL$_{B17}$), the latter is based on light curves with an average of 50 epochs, which is more than twice that of the other two together. Moreover, for targets that are outside their surveyed sky area, they include data from the previous works. Third, we excluded the M06 calibration because it is based on all the three subclasses of T2Cs, including RVTs, which we did not include in our distance analysis. In the end, we adopted PL$_{B17}$, which is based only on BLHs and WVs, which are the subclasses of variables for which we did estimate the distance. As stated in section~\ref{section:data}, we simultaneously estimated distances and the 3D extinction E(\jmk)$_{S14}$. This was made iteratively, following the method of \citet{bhardwaj17c}. Normally, after the second or third iteration, the values of distance and reddening converge. We derived individual distances for 710 variables, which are listed in Table~\ref{tab:dist}. Taking all sources of uncertainty into account (uncertainty on the mean magnitude, on the extinction, on the coefficients of the calibrating PL, and the intrinsic width of the PL), the relative uncertainties are in the range 8\%-9\% for 676 objects, 9\%-20\% for 38, and only one, at a distance of 2.87 kpc, has a relative uncertainty of $\sim$27\%. \subsection{Spatial distribution of Type II Cepheids}\label{section:distribution} Knowing the coordinates ($l$,$b$) and the distances $d$, we derived the coordinates $x_{GAL}$, $y_{GAL}$ and $z_{GAL}$. We adopted a reference frame with the Sun at the origin ($x_{GAL}$=$y_{GAL}$=$z_{GAL}$=0), $x_{GAL}$ which increases toward the Galactic center, $y_{GAL}$ which is on the Galactic plane and positive for $l$>0, and $z_{GAL}$ which is perpendicular to the Galactic plane and positive for $b$>0. \begin{table*}[!htbp] \footnotesize \caption{Extinction, distances, and Cartesian coordinates of target T2Cs.} \centering \begin{tabular}{l c c c c c c c c c} \hline\hline ID & $A_{Ks(G12)}$\tablefootmark{a} & $A_{Ks(S14)}$ & $x_{GAL}$ & $y_{GAL}$ & $z_{GAL}$ & $d$ \\ & mag & mag & kpc & kpc & kpc & kpc \\ \hline 001 & \ldots & \ldots & \ldots & \ldots & \ldots & \ldots \\ 002 & 0.07$\pm$0.04 & 0.11$\pm$0.01 & 7.44$\pm$0.62 & --1.06$\pm$0.09 & 0.62$\pm$0.05 & 7.54$\pm$0.63 \\ 003 & 0.12$\pm$0.04 & 0.16$\pm$0.01 & 9.09$\pm$0.77 & --1.23$\pm$0.10 & 0.70$\pm$0.06 & 9.20$\pm$0.78 \\ 004 & \ldots & \ldots & \ldots & \ldots & \ldots & \ldots \\ 005 & 0.17$\pm$0.04 & 0.21$\pm$0.01 & 19.25$\pm$1.65 & --2.20$\pm$0.19 & 1.30$\pm$0.11 & 19.42$\pm$1.66 \\ 006 & \ldots & \ldots & \ldots & \ldots & \ldots & \ldots \\ 007 & 0.21$\pm$0.05 & 0.25$\pm$0.03 & 9.15$\pm$0.78 & --0.43$\pm$0.04 & 0.63$\pm$0.05 & 9.18$\pm$0.79 \\ 008 & 0.17$\pm$0.04 & 0.20$\pm$0.03 & 10.55$\pm$0.91 & --0.31$\pm$0.03 & 0.83$\pm$0.07 & 10.58$\pm$0.91 \\ 009 & 0.20$\pm$0.05 & 0.21$\pm$0.03 & 9.36$\pm$0.80 & --0.48$\pm$0.04 & 0.59$\pm$0.05 & 9.39$\pm$0.80 \\ 010 & \ldots & \ldots & \ldots & \ldots & \ldots & \ldots \\ \hline \end{tabular} \tablefoot{Only the first 10 of the 924 lines of the table are shown. The full table is shown in the machine-readable version of the paper.\\ \tablefoottext{a}{For some coordinates, the G12 map does not provide an error on E(\jmk), therefore there is no error on $A_{Ks(G12)}$.}} \label{tab:dist} \end{table*} Figure~\ref{fig:map} clearly shows that several objects are located either in front of or beyond the bulge. The individual distances range from 2.0 to 111.7 kpc, with 11 objects more distant than 30 kpc, most likely belonging to the outer halo, which dominates at Galactocentric distances greater than $\sim$20 kpc \citep{carollo07,carollo2018}. \begin{figure*}[!htbp] \centering \includegraphics[width=10cm]{distance_inner_pk_b17_ogle4.eps} \vspace{-0.5cm}\caption{Top: Projection, on the Galactic plane, of T2Cs within 14 kpc. The Sun is at the vertex of the plot. Black circles with error bars represent the means and standard deviations of the distances projected onto the Galactic plane, in 2{\deg} wide angular areas (4{\deg} wide for the most peripheral one at positive $l$). Thirty-four T2Cs were not plotted because they are more distant than 14 kpc. Bottom: Same as the top panel, but projected in latitude. The angular areas are 2{\deg} wide, except the central one, which is 3{\deg} wide.} \label{fig:map} \end{figure*} The two panels of Figure~\ref{fig:map} also show as black circles with error bars the means and standard deviations of the distances projected onto the Galactic plane (top panel) or onto the longitude ($l$=0) plane (bottom panel), in angular areas of 2{\deg}. We point out that in the top panel, the most peripheral area at positive $l$ is 4{\deg} wide, and in the bottom panel, the most central area is 3{\deg} wide, to take into account the lower density of objects. These mean and standard deviations were derived by fitting a rescaled histogram with a Gaussian. A detailed explanation is provided below. {\it Galactic ($b$=0) plane).} The central angular areas share basically identical averages. However, the most peripheral areas (5\Deg0<|$l$|<9\Deg0, that is, between 0.7 and 1.25 kpc from the Galactic center) show a slight deviation similar to that of the barred distribution of Red Clump stars \citep{wegggerarhd2013}: closer at positive $l$ and more distant at negative $l$. This agrees with our finding that the PL relation does depend on the $l$ coordinate, and gives further evidence of the ellipsoidal symmetry of the old stellar component of the bulge, as has been outlined by \citet{pietrukowicz2015}, who found an ellipsoidal structure for bulge RRLs, with an inclination of the major axis with respect to the Sun of 20\deg$\pm$3\deg, similar to the orientation of the Galactic bar \citep[$\sim$30\deg][]{gonzalez2011,wegggerarhd2013}. {\it Longitude ($l$=0) plane).} A distinct yet fictitious trend of the average distance with $b$ is displayed in the bottom panel of Figure~\ref{fig:map}. The variables that are closer to the Galactic plane appear to have smaller distances. This is due to a selection effect caused by extinction in the original OGLE catalog, which more easily detects stars in the closest part of the bulge than stars in the farthest part, which are more heavily reddened. The extinction ratio between the $I$ band of OGLE and the $K_s$ band of VVV ranges within a factor of four to ten, and the lower limit of $A_{Ks}(S14)$ for our targets is $\sim$0.3 mag. We have considered two other possible explanations for this trend: either an overestimate of reddening at low $b$ or the effect of crowding on aperture photometry, but none can explain the quoted behavior. We discard the possibility that reddening is overestimated because other experiments that adopted either the G12 or the S14 map, which are consistent between themselves, provided estimates of $R_0$, all at about 8.3 kpc \citep{gonzalez2012,bhardwaj17c,majaess2018}. We also rule out the possibility that crowding affects the magnitudes from aperture photometry, making the targets brighter. A direct comparison of PSF versus aperture photometry does not reveal any clear trend with $b$, and the average difference of mean magnitudes is $\Delta K_{s(Aperture-PSF)}$=0.03$\pm$0.013 mag. With individual distances and coordinates for our targets, we can estimate the distance of the Galactic center $R_0$. However, the calculation is not straightforward, and cuts and resampling are needed to take the biases into account. First, we selected only stars at $R_{G}=\sqrt{x_{GAL}^2+y_{GAL}^2}$, which is the distance of the star, projected onto the Galactic plane, between 6 and 11 kpc, to avoid non-bulge stars within the sample. The choice is justified by the results of \citet[][see their Fig. 5]{pietrukowicz2015}, who showed that the density of bulge stars is very low (lower than $\sim$10\% of the peak) outside this distance range. Second, we only selected stars at $b$>3\Deg0 and $b$<--3\Deg0 to avoid the OGLE selection bias. A similar cut was applied by \citet{pietrukowicz2015}, who only used RRLs at $b$<--2\Deg7 to estimate $R_0$. These selection criteria left us with 172 stars. However, their average longitude ($\langle l \rangle$) is 0\Deg275, which means that the sample is biased toward shorter distances. To overcome this bias, we performed a resampling of the data by randomly selecting 75 stars at negative $l$ and 75 at positive $l$. If $\langle l \rangle$ of the 150 random targets is lower in absolute values than 0\Deg1, we kept the sample, otherwise, we repeated the random target selection. We point out that this process is not a proper bootstrap method because we did not allow sampling the same element more than once. With this set of 150 targets, we plot the distribution of $R_{G}$ in bins of 0.25 kpc as shown in Figure~\ref{fig:distance2} (black histogram). However, this distribution is biased and shifted to greater distances. At fixed coordinates ($l$,$b$), the volume within a given sky area ($\Delta l$,$\Delta b$) and a given depth range ($\Delta d$) increases with distance. This means that the number of stars within the volume (and therefore the probability of detecting a target in the volume) increases quadratically with distance. This causes a bias that shifts the distribution toward the more probable larger distances. To take this geometric effect into account, we scaled the distribution by $d^{-2}$. We fit the scaled distribution (red histogram in Figure~\ref{fig:distance2}) with a Gaussian. We estimated the abscissa of the peak ($x_0$) and adopted it as our estimate of $R_{0(i)}$ on the $i$-th resampled set. Starting from the random extraction of 150 targets, this process was repeated 5,000 times to avoid any selection bias. \begin{figure*}[!htbp] \centering \includegraphics[width=10cm]{histo_pk_b17_n09_ogle4_s14_all_resample.eps} \caption{Top: Overall histogram of the distances of 150 targets resampled 5,000 times (750,000 in total, shown in black). $d^{-2}$ scaled histogram (red). A Gaussian centered at $R_0$ is displayed. The estimate of $R_0$ is labeled with its uncertainty as derived by using percentiles, as described in the text. Bottom: $d^{-2}$ scaled histogram of 75 targets at $l$<0\deg resampled 5,000 times (375,000 in total, shown in blue) Light blue: Same as the blue, but for targets at $l$>0\deg.} \label{fig:distance2} \end{figure*} We adopted an overall average of the 5,000 estimates of $R_{0(i)}$ as our final estimate of $R_0$. Based on a sample with $\langle l \rangle$=0\Deg016$\pm$0\Deg050, we obtain a final $R_0$ estimate of 8.46 kpc. The statistical uncertainty of both $R_0$ was derived as half of the range between the 15.8\% and 84.1\% percentiles of the distribution of $R_{0(i)}$ (see Fig.~\ref{fig:distance3}). These thresholds were chosen to enclose 68.3\% of the estimates provided by the simulations, like a $\pm$1$\sigma$ range in a Gaussian distribution. We derived a range of 8.43-8.49 kpc for $R_0$, which means a statistical uncertainty of 0.03 kpc. \begin{figure*}[!htbp] \centering \includegraphics[width=10cm]{histo_pk_b17_n09_ogle4_s14_r0_resample.eps} \caption{Distribution of the 5,000 estimates of $R_0$ from the resampled sets of targets. The dashed lines display the percentiles at 15.8\% and at 84.1\% that we used to derive the uncertainty on $R_0$.} \label{fig:distance3} \end{figure*} We calculated the systematic uncertainty as the squared sum of the average uncertainty on the mean magnitude (0.020 mag), the average uncertainty on the extinction (0.021 mag), and the average propagation of the uncertainties of the calibrating PL coefficients (almost vanishing, 0.001 mag). These together are 0.028 mag, which is 0.11 kpc at 8.30 kpc. Our estimate of $R_0$ does not agree very well with estimates from similar works, either using T2Cs \citep[8.34$\pm$0.03{[}stat.{]}$\pm$0.41{[}syst.{]} kpc,][]{bhardwaj17c} or RRLs (8.33$\pm$0.05{[}stat.{]}$\pm$0.14{[}syst.{]} kpc, \citealt{dekany2013}; 8.27$\pm$0.01{[}stat.{]}$\pm$0.40{[}syst.{]} kpc, \citealt{pietrukowicz2015}). However, all the quoted papers adopted the reddening law by \citet{nishiyama2009}, which provides a higher $R_{JK}=0.528$ and, in turn, smaller distances. Had we adopted the \citet{nishiyama2009} reddening law with our data, it would have provided $R_0$=8.30$\pm$0.03(stat.)$\pm$0.11(syst.), which would agree perfectly well with the quoted papers. This is evidence of how crucial a correct understanding of the reddening law is. Our estimate of $R_0$ agrees within 1$\sigma$ with the best overall recommended value from a recent review \citep[$\sim$8.3$\pm$0.2{[}stat.{]}$\pm$0.4{[}syst.{]} kpc,][]{degrijs2016}. Finally, a more detailed analysis of the data allows us to show further evidence of the asymmetrical distribution of T2Cs around the Galactic center. By resampling 5,000 times only T2Cs at positive $l$, we obtain an average peak of the distribution of 8.29$\pm$0.09 kpc. The same process on T2Cs at negative $l$ provides a value of 8.68$\pm$0.05 kpc. Together with the distribution of average distances in the Galactic plane (top panel of Figure~\ref{fig:map}) and the dependence of the PL relation on $l$, this is strong evidence that T2Cs trace an old, ellipsoidal stellar population. \section{Kinematics}\label{section:kinematics} \subsection{Proper motion of the center of mass} The proper motion of Sgr A*, the supermassive black hole at the center of the Milky Way, based on VLBA measures, is $\mu_{l*(Sgr A*)}$=--6.379$\pm$0.026 mas/yr; $\mu_{b(Sgr A*)}$=--0.202$\pm$0.019 mas/yr \citep{reid2004}. Assuming that the center of mass of the old population traced by T2Cs overlaps with Sgr A* and has the same proper motion, we adopt the proper motions of T2Cs to obtain an indirect estimate of the proper motion of the center of mass. As discussed in Section~\ref{section:data}, we collected proper motions from three different catalogs: VIRAC, PSF, and {\it Gaia}. For the analysis in this section, we rejected, from all three catalogs proper motions with a combined statistical error $CSE=\sqrt{err\mu_{\alpha *}^2+err\mu_{\delta}^2}$ or $CSE=\sqrt{err\mu_{l*}^2+err\mu_{b}^2}$ larger than 2 mas/yr, leaving 553, 343, and 837 targets from VIRAC, PSF, and {\it Gaia}, respectively. We point out that the error propagation for the {\it Gaia} proper motions, when converting from ($\mu_{\alpha *}$,$\mu_{\delta}$) into ($\mu_{l*}$,$\mu_{b}$), was performed taking into account the covariance terms as suggested by \citet{gaia_dr2_parallax}. {\it Gaia} coordinates were precessed from their native J2015.5 epoch to J2000, the same reference epoch as for VIRAC and PSF, to perform the quoted conversion. It is crucial to remember that while VIRAC and PSF provide relative proper motions in the frame of reference of the Galaxy, {\it Gaia} provides absolute proper motions in the practically inertial frame of reference defined by quasars. This allows an interesting comparison among the catalogs. As a first step, we left out VIRAC proper motions. As displayed in Figure~\ref{fig:deltamu}, the distribution of $\Delta\mu_{l*}=\mu_{l*(Gaia)}-\mu_{l*(PSF)}$ is centered at $\Delta\mu_{l*(peak)}$=--6.41$\pm$0.02 mas/yr. For the $b$ component, we find $\Delta\mu_{b(peak)}$=0.12$\pm$0.03 mas/yr. These numbers were derived using 251 T2Cs for which we have both {\it Gaia} and PSF proper motions and that are located within 2 kpc from the center of the Galaxy, as derived in Section~\ref{section:distribution}. The latter criterion was adopted as a compromise to leave out possible thick-disk stars and to retain a large sample of targets. \begin{figure*}[!htbp] \centering \includegraphics[width=12cm]{delta_pm_rodrigo_gaia.eps} \caption{Left: Distribution of $\Delta\mu_{l*}$ for 251 T2Cs located less than 2 kpc away from the center of the Galaxy. A Gaussian fit to the distribution is shown in red. The abscissa of the peak and the $\sigma$ of the fit are labeled. Right: Same as left panel, but for $\Delta\mu_{b}$.} \label{fig:deltamu} \end{figure*} When we assume that the velocities of our targets are randomly distributed around the center of mass, which is reasonable because this is the behavior of old, low-mass bulge stars \citep{spaenhauer1992,minniti1996,babusiaux2010,kunder2016}, then ($\Delta\mu_{l*(peak)}$,$\Delta\mu_{b(peak)}$) is an indirect estimate of the proper motion of the center of mass of the Galaxy. This is supported by the fact that $\Delta\mu_{l*(peak)}$ is identical well within 1$\sigma$ to the longitudinal component of the proper motion of Sgr A*. The latitudinal component $\Delta\mu_{b(peak)}$ does not agree with that of Sgr A*, but the mean uncertainty on the proper motions (0.82 mas/yr for PSF and 0.47 for {\it Gaia}) is larger than the offset. We also checked whether there is a trend of $\mu_{l*}$ and $\mu_{b}$ with distance, and found nothing significant in either the {\it Gaia} or the PSF sample. This implies that there is no evidence of net rotation. We have performed the same analysis using proper motions from VIRAC and {\it Gaia} and found that in this case, $\Delta\mu_{l*(peak)}=-5.43\pm0.03$ mas/yr and $\Delta\mu_{l*(peak)}=-0.04\pm0.02$ mas/yr. While the $b$ component is similar to that of Sgr A*, the component along $l$ is different from $\mu_{l*(Sgr A*)}$ by as much as $\sim$1 mas/yr. Moreover, we found that for 265 targets in common between the VIRAC and PSF datasets, the difference between the medians of $\mu_{l*}$ and $\mu_{b}$, are --0.97$\pm$2.62 and +0.12$\pm$2.62 mas/yr, respectively. No dependence of $\mu_{l*}$ on $l$ or on $b$ was found in either of the two catalogs. We conclude that the $\mu_{PSF}$ are more reliable than $\mu_{VIR}$ not only a priori, as discussed in Section~\ref{section:data}, but also a posteriori. Because these are both relative measures of the proper motion, the assumption of randomly distributed motions around the Galactic center would imply a zero median $\mu_{l*}$. The comparisons with {\it Gaia} and that with the PSF sources both indicate that VIRAC proper motions are systematically shifted by $\sim$1 mas/yr to the east on the Galactic plane. \subsection{Velocity dispersion}\label{section:veldispersion} Tangential velocities can be used to test the kinematic properties of a stellar population. If bulge T2Cs trace a spheroidal population that is kinematically hot, then their distribution should be dominated by a velocity dispersion with negligible rotation such as the Bulge RRL population \citep[][and references therein; Contreras Ramos et al. 2018, submitted]{minniti1996,kunder2016,marconiminniti2018}. In this case, the velocity ellipsoid should be fairly symmetric in the Galactic longitude ($v_{l*}$) and latitude ($v_b$) components. To test this hypothesis, we derived the tangential velocity ($v_t$) and its two components $v_l*$ and $v_b$, using the classical relation $v_t = 4.74\cdot d \cdot \mu$, where $d$ is in kpc and and $\mu$ in mas/yr. We used $d$ as derived in Section~\ref{section:dist} and $\mu$ from {\it Gaia} because it is the most complete sample with the smallest uncertainties. While pWVs and RVTs might have valid values of $\mu$, we cannot derive their $v_t$, since $d$ is not available. Table~\ref{tab:pm} displays the proper motions and velocities. \begin{table*} \footnotesize \caption{Proper motions and velocities of target T2Cs.} \centering \begin{tabular}{l c c c c c c c c c} \hline\hline & \multicolumn{2}{c}{VIRAC} & \multicolumn{2}{c}{PSF} & \multicolumn{2}{c}{{\it Gaia}} & & & \\ ID & $\mu_{l*}$ & $\mu_b$ & $\mu_{l*}$ & $\mu_b$ & $\mu_{l*}$ & $\mu_b$ & $v_l$\tablefootmark{a} & $v_b$\tablefootmark{a} & $v_t$\tablefootmark{a} \\ & mas/yr & mas/yr & mas/yr & mas/yr & mas/yr & mas/yr & km/s & km/s & km/s \\ \hline 001 & \ldots & \ldots & \ldots & \ldots & --8.91$\pm$0.09 & 0.01$\pm$0.12 & \ldots & \ldots & \ldots \\ 002 & --3.13$\pm$0.81 & 1.75$\pm$0.04 & \ldots & \ldots & --8.49$\pm$0.06 & 2.50$\pm$0.06 & --303.4$\pm$25.4 & 89.3$\pm$7.8 & 316.3$\pm$24.5 \\ 003 & --3.46$\pm$0.81 & --1.05$\pm$0.06 & \ldots & \ldots & --8.88$\pm$0.12 & --2.03$\pm$0.11 & --387.4$\pm$33.2 & --88.5$\pm$8.9 & 397.3$\pm$32.5 \\ 004 & \ldots & \ldots & \ldots & \ldots & --2.27$\pm$0.09 & 2.92$\pm$0.08 & \ldots & \ldots & \ldots \\ 005 & 2.63$\pm$1.48 & 1.68$\pm$0.06 & \ldots & \ldots & --5.12$\pm$0.29 & --0.47$\pm$0.26 & --471.4$\pm$48.4 & --42.9$\pm$24.1 & 473.3$\pm$48.3 \\ 006 & \ldots & \ldots & \ldots & \ldots & --6.66$\pm$0.06 & --0.90$\pm$0.07 & \ldots & \ldots & \ldots \\ 007 & \ldots & \ldots & \ldots & \ldots & --4.53$\pm$0.22 & --4.54$\pm$0.14 & --197.0$\pm$19.5 &--197.4$\pm$18.1 & 278.9$\pm$18.8 \\ 008 & 0.71$\pm$0.92 & --1.25$\pm$0.12 & \ldots & \ldots & --4.79$\pm$0.21 & --0.95$\pm$0.18 & --240.2$\pm$23.2 & --47.9$\pm$ 9.7 & 245.0$\pm$22.8 \\ 009 & \ldots & \ldots & \ldots & \ldots & --5.98$\pm$0.19 & --1.67$\pm$0.18 & --266.3$\pm$24.2 & --74.2$\pm$10.1 & 276.5$\pm$23.4 \\ 010 & \ldots & \ldots & \ldots & \ldots & --5.21$\pm$0.10 & --5.46$\pm$0.10 & \ldots & \ldots & \ldots \\ \hline \end{tabular} \tablefoot{Only the first 10 of the 924 lines of the table are shown. The full table is shown in the machine-readable version of the paper.} \tablefoottext{a}{The velocities are based on the absolute proper motions by {\it Gaia}} \label{tab:pm} \end{table*} \begin{figure*}[!htbp] \centering \includegraphics[width=12cm]{vt_histo_bulge_gaia.eps} \caption{Left: Distribution of the $l$ component of $v_t$ for 164 T2Cs located at less than 2 kpc from the center of the Galaxy, as in Section~\ref{section:distribution}. The simple and true standard deviations of the sample are labeled. Right: Same as left panel, but for the $b$ component of $v_t$.} \label{fig:vdispersion} \end{figure*} Finally, we derived the standard deviation of $v_{l*}$ and $v_b$ and obtained 106.2$\pm$3.0 km/s and 97.3$\pm$5.5 km/s, respectively. These values were corrected by subtracting, in quadrature, the average uncertainties on $v_{l*}$ (20.5 km/s) and $v_b$ (9.9 km/s). After this correction, we find $\sigma v_{l*}$=104.2$\pm$3.0 km/s, and $\sigma v_b$=96.8$\pm$5.5 km/s. The agreement between the two is better than 1.2$\sigma$, thus providing further evidence that the T2Cs belong to a kinematically hot population. We cannot rule out the possibility that despite our cuts, we still included some thick-disk objects. Stricter selections concerning the target distance from the center are hampered by the sample size. \section{Conclusions}\label{section:conclusions} We have retrieved $K_s$-band light curves from VVV aperture photometry for 894 of 924 T2Cs in the OGLE IV catalog \citep{soszynski2017}. We calculated mean magnitudes and amplitudes based on PLOESS fits \citep{persson2004,braga2018} to the light curves. For BLHs and WVs, we simultaneously estimated individual extinctions and distance moduli, based on a 3D reddening map \citep{schultheis2014} and on a PL relation. The calibration of the PL relation was based on the slope and zero-point of T2Cs in the LMC \citep{bhardwaj17b}, anchored with a late-type eclipsing binaries distance to the LMC \citep{pietrzynski2013}. We found distances ranging from 2.0 to 111.7 kpc kpc, which means that our objects are located in the bulge, in the inner and outer halo, and possibly in the thick disk. The mean individual relative uncertainty is 8.6\%, independent of distance and with a small standard deviation of 1.2\%. The distribution of the individual distances, taking various geometric and selection biases into account, provides an estimate of the distance of the Galactic center $R_0$ of 8.46$\pm$0.03(stat.)$\pm$0.11(syst.), which agrees with the recommended value of 8.3$\pm$0.2(stat.)$\pm$0.4(syst.) kpc \citep{degrijs2016}. Our estimate of $R_0$ does not agree with other estimates with similar methods \citep[$R_0 \approx 8.30$ kpc][]{dekany2013,pietrukowicz2015,bhardwaj17c}, but the difference is consistent with the different reddening law that was adopted (\citealt{alonsogarcia2017} instead of \citealt{nishiyama2009}). We provided solid evidence that the old stellar population in the bulge is ellipsoidal. First, we found a non-negligible dependence of the PL relation on the $l$ coordinate. This has been described before by \citet{groenewegen08}, but their limited sample hampered the precision of the coefficient (--0.028$\pm$0.031 mag/\deg), while ours is more precise (--0.019$\pm$0.003 mag/\deg). Second, we found that at $l\lesssim$--5\deg, the average distance is larger, while at $l\gtrsim$5\deg the average distance of T2Cs is smaller, on a map projected onto the Galactic plane. Third, which is a similar but more quantitative approach as the second point, we found that the distribution of T2Cs at positive $l$ is centered at 8.29$\pm$0.09 kpc, while that of T2Cs at negative $l$ is centered at 8.68$\pm$0.05 kpc. We also adopted proper motions from both {\it Gaia} and VVV itself to constrain the kinematic properties of T2Cs in the bulge. The analysis was restricted to only the sources with a combined statistical error smaller than 2 mas/yr. The power of the synergy between {\it Gaia} and VVV astrometric data is clear when comparing the absolute proper motions from {\it Gaia} with relative proper motions from the VVV. The mean difference (--6.41$\pm$0.02 and 0.12$\pm$0.03 mas/yr in the longitude and latitude direction, respectively) for T2Cs within 2 kpc from the Galactic center is similar within the uncertainties (0.82 mas/yr for PSF and 0.47 mas/yr for {\it Gaia}) to the VLBA estimate of the relative proper motion of Sgr A* (--6.379$\pm$0.026 and --0.202$\pm$0.019 mas/yr). This is reasonable if we assume that the T2Cs of the bulge belong to the kinematically hot, old stellar population \citep{minniti1996,kunder2016}. Another piece of evidence supporting this assumption is that the velocity dispersion in both the longitude and latitude directions agree within almost 1$\sigma$ ($\sigma v_{l*}$=104.2$\pm$3.0 km/s, $\sigma v_b$=96.8$\pm$5.5 km/s.) The difference may be due to contamination by thick-disk stars in the 2 kpc sphere around the Galactic center. It is important to note that while the distribution and kinematics of metal-rich populations in the bulge, tracing the X-shaped structure, have been studied widely, the distributions of more metal-poor populations based on different tracers remain to be investigated in detail. This work on T2Cs provides results that are consistent with RRLs. The spectroscopic follow-up of these objects in the near future will allow us to confirm the differences in their spatial distributions and kinematics to those of metal-rich populations in the Galactic bulge. \begin{acknowledgements} We are grateful to the anonymous referee for the useful suggestions that helped us to improve our paper. This work has made use of data from the European Space Agency (ESA) mission {\it Gaia} (\url{https://www.cosmos.esa.int/gaia}), processed by the {\it Gaia} Data Processing and Analysis Consortium (DPAC, \url{https://www.cosmos.esa.int/web/gaia/dpac/consortium}). Funding for the DPAC has been provided by national institutions, in particular the institutions participating in the {\it Gaia} Multilateral Agreement. \end{acknowledgements} \bibliographystyle{aa}
\section{Introduction} The concept of locality is widely employed in various branches of mathematics, such as local algebras~\mcite{JS} and local operators in functional analysis~\mcite{BAE,Bat}. Locality is also used in computer science and physics, especially in classic and quantum field theory. For instance, the locality principle is a critical factor in Einstein's theory. It is well-known that renormalization, which is a technique to remove the divergences in Feynman integrals calculations, plays an important role in quantum field theory~\mcite{Bor,BP,CK,Z} and mathematics~\mcite{GZ,GPZ3,M}. More recently, from an algebraic viewpoint, the study about how to preserve locality in the renormalization under the framework of algebraic Birkhoff factorization was proposed by P. Clavier, L. Guo, S. Paycha and B. Zhang~\mcite{CGPZ1}. As a result, locality semigroup, locality algebras, locality coalgebras, and locality Rota-Baxters are established in the context of locality. As a starting point of this paper, we develop the basic results of locality semigroups. One of these results is free objects in the category of locality semigroups. As is well known, a quiver $Q:=(Q_0,Q_1,s,t)$ is a directed graph and can be viewed as a basic mathematical object. The theory of representations of quivers was originally introduced to solve the classification problem of tuples of subspaces of a prescribed vector space from linear algebra. Since then quiver representations have been studied quite extensively with board application in mathematics, including invariant theory, Kac-Moody Lie algebras and quantum groups~\mcite{Br,FH,HJ,Scho}. Denote $\calp$ by the set of all paths in $Q$. In fact, the definition of multiplication of path in $Q$ is involved in partially defined binary operations, since the composition $pq$ makes sense only if $t(p)=s(q)$ for $p,q\in\calp$. This means that the multiplication of path is well-defined only for some elements of $\calp$. Roughly speaking, the path is analogous to the locality semigroups and possesses some ``freeness" property, and hence is called a {\bf path locality semigroup} in the sequel. Motivated by the freeness property of path, we explore the basic results of path locality semigroups. We finally show that the path locality semigroup of a quiver is the free refined locality semigroup on a locality set. On the other hand, a {\bf path semigroup} is a path locality semigroup $\calp$ by adding a zero element (or zero path) and then defining $pq=0$ when $t(p)\neq s(q)$ for $p,q\in\calp$. In~\mcite{For,MB}, the authors study formulas for determining effective dimensions of path semigroups over an uncountable field. Furthermore, the path algebra $\bfk \calp$ of a quiver $Q$ is essential in the theory of quiver representations as well. For example, a representation of $Q$ is equivalent to a left module over the path algebra $\bfk \calp$~\mcite{Br}. Also, according to the well-known Gabriel Theorem~\mcite{ASS,ARS} an algebra over an algebraically closed field is a quotient of the path algebra of its Ext-quiver modulo an admissible ideal. More generally, an Artinian algebra over a perfect field is isomorphic to a quotient of the generalized path algebra of its natural quiver~\mcite{LL}. In a recent study ~\mcite{GL} of path algebras, the authors developed the Lie algebra of derivations on the path algebra of a quiver, and gave the characterizations of derivations on a path algebra. More recently, the Hopf algebras on path algebras, reconstruction of path algebras and the dimensions of path algebras were also studied ~\mcite{AH,HU,KW}. As a consequence, the relationships between path algebras and path locality algebras will be continued in a future work. A partial semigroup can be regarded as a generalization of a semigroup $(S,\cdot)$ to partial binary operations, that is, operations are defined only for some elements of $S$. In~\mcite{Sch}, partial semigroups were also used to develop the coordinatization of all bounded posets. There are close relationships between the partial semigroups and locality semigroups, because of the property that their multiplications are partially defined similarly. Then a natural question comes up: whether or not one of them includes the other. For this reason this paper discusses the relationships between locality semigroups and partial semigroups. Meanwhile, we also develop the relationships among \fine locality semigroups, \weak locality semigroups and partial semigroups. In fact, partial algebras are introduced in order to solve the word problem, which is whether two words in the generators represent the same element of the algebra ~\mcite{Ev51}. Nowadays, partial algebras are especially useful for theoretical computer science~\mcite{Bur}. See~\mcite{BBH,Bur, Gr, Gud, LE,SW} for further details. In addition, in~\mcite{GS}, the authors give a general way to construct algebras with given properties, starting with a simple constructed partial algebra and completing it by using some universal constructions. Thus, the last main goal of this paper is to provide a method to construct a semigroup from any given partial semigroup. We discuss this question in the last section. The layout of the paper is as follows. In Section~\mref{sec:FreefineLSG} we start by recalling the concept of locality semigroups and give some examples. We then give the construction of free \fine locality semigroups. In Section~\mref{sec:parSG} we first give the relations among refined locality semigroups, strong locality semigroup and the intersection between partial semigroups and locality semigroups. We further discuss in some detail the relationship between partial semigroups and locality semigroups. Section~\mref{sec:stro} then gives a natural way to construct a strong semigroup with zero from a \fine locality semigroup, and some necessary examples are also provided to show why this method dose not apply to more general partial semigroups. Finally, we show that the path locality semigroup is a \fine locality semigroup, and hence is a strong semigroup with zero. \smallskip \noindent \section{Free \fine locality semigroups} \mlabel{sec:FreefineLSG} The main purpose of this section is to construct the free \fine locality semigroup on a locality set. We first recall the basic concepts of locality and give some necessary examples in Section~\mref{subsec:locsg}. We then introduce the path locality semigroups of a quiver in Section~\mref{subsec:pathlocsg}. We show that the path locality semigroup is the free \fine locality semigroup on a locality set in Section~\mref{subsec:fineLSG}, stated in Theorem~\mref{thm:FreeStrLocSg}. \subsection{Locality semigroups} \mlabel{subsec:locsg} We start by recalling the definition of locality semigroups and extend some related concepts of semigroups, such as subsemigroups and ideals, to that of locality semigroups. Several examples of locality semigroups which often arise in practice are given. \begin{defn}{\bf(}\cite[Definition 2.1]{CGPZ1}{\bf)} \begin{enumerate} \item A {\bf locality set} is a couple $(X,\top)$, where $X$ is a set and $\top\subseteq X\times X$ is a binary relation on $X$, called a {\bf locality relation} of locality set. When the underlying set $X$ needs to be emphasized, we also denote $X\times_\top X:=\mtop_X:=\top$. \item Let $(X,\mtop_X)$ be a locality set. Let $X'$ be a subset of $X$ and let $\mtop_{X'}:=(X'\times X')\cap \mtop_X$. Then the pair $(X',\mtop_{X'})$ is called a {\bf sub-locality set} of $(X,\mtop_X)$. \item Let $(X,\top)$ be a locality set. For any subset $U\subseteq X$, let \begin{equation} \lt:=\{x\in X\,|\,(x,u)\in X\times_\top X\,\text{for all}\, u\in U\} \end{equation} to be the {\bf left polar subset} of $U$. Similarly, we let \begin{equation} U^\top:=\{x\in X\,|\,(u,x)\in X\times_\top X\,\text{for all}\, u\in U\} \end{equation} to be the {\bf right polar subset} of $U$. \item Let $(X,\top)$ be a locality set. A map $$\mu:X\times_{\top} X\to X,\quad (x,y)\mapsto \mu(x,y)\,\, \text{for all}\,\, (x,y)\in \top,$$ is called a {\bf partial binary operation on $X$}. The image $\mu(x,y)$ is written simply $x\cdot y$ or $xy$ in the sequel if this ambiguous notation will cause no confusion in context. \end{enumerate} \end{defn} The first example of locality sets and partial binary operations is very simple. \begin{exam} Let $\R$ be the set of real numbers. Let $\mtop_\R:=\{(x,y)\in\R^2|\,y\neq 0\}$. Then $(\R,\mtop_\R)$ is a locality set. Take $U:=\{0\}$. Then $U^\top=\R \setminus\{0\}$ and $\lts U=\emptyset$. So $U^\top\neq \lts U$. We note that the division $\div:\R\times_{\mtop_\R} \R\to \R,\,(x,y)\mapsto \frac{x}{y}$, is a partial binary operation on $\R$. \end{exam} \begin{defn} \begin{enumerate} \item A {\bf locality semigroup} is a locality set $(S,\top)$ together with a partial binary operation defined on $S$: $$\mu_S:S\times_\top S \to S,\quad (a,b)\mapsto a b\,\,\,\text{for all}\, (a,b)\in \top,$$ such that for all subset $U$ of $S$, \begin{equation} \mu_S((\lt\times \lt)\cap \top)\subseteq \lt, \mlabel{eq:leftclosed} \end{equation} and for all subset $U$ of $S$, \begin{equation} \mu_S((U^\top\times U^\top)\cap \top)\subseteq U^\mtop, \mlabel{eq:rightclosed} \end{equation} and the {\bf locality associative law }holds: for all $a,b,c\in S$, \begin{equation} (a,b),(b,c),(a,c)\in \top\Rightarrow (a b) c=a (b c). \mlabel{eq:locass} \end{equation} We denote a locality semigroup $(S,\top)$ with a partial binary operation $\mu_S$ by $(S,\top,\mu_S)$ or simply $(S,\top)$ if there is no danger of confusion. \mlabel{it:defnlocsg} \item We say that a locality semigroup $(S,\top)$ is {\bf transitive} if $\top$ is transitive, that is, $(a,b),(b,c)\in \top \Rightarrow (a,c)\in \top$. \item A {\bf left identity} {\bf[right identity]} of a locality semigroup $(S,\top)$ is an element $1\in S$ such that for all $a\in S$, $(1,a)\in \top$ and $1a=a$ [$(a,1)\in \top$ and $a1=a$]. An {\bf identity} of $(S,\top)$ is an element $1\in S$ that is both a left and right identity. A locality semigroup $(S,\top)$ with an identity is called a {\bf locality monoid}, usually denoted by $(S,\top,1)$ or $(M,\top)$. \item A {\bf left zero element} {\bf [right zero element]} of a locality semigroup $(S,\top)$ is an element $0\in S$ such that for all $a\in S$, $(0,a)\in \top$ and $0a=0$ [$(a,0)\in \top$ and $a0=0$]. If $0\in S$ is both a left and right zero element, we say that $0$ is a {\bf zero element} of $(S,\top)$, and that $(S,\top)$ is a {\bf locality semigroup with zero}. \end{enumerate} \mlabel{defn:locsg} \end{defn} \begin{remark} Let $(S,\top)$ be a locality set with a partial binary operation. For any given $a,b,c\in S$, suppose that $(a,b),(a,c),(b,c)\in \top$. On the one hand, if we take $U:=\{c\}$, then $a,b\in \lts U$, and so $(a,b)\in(\lt\times \lt)\cap \top$. By Eq.~(\mref{eq:leftclosed}), we obtain $(ab,c)\in \top$. On the other hand, if we take $U:=\{a\}$, then $b,c\in U^\top$, and hence $(a,bc)\in \top$ by Eq.~(\mref{eq:rightclosed}). This shows that both sides of Eq.~(\mref{eq:locass}) make sense. \end{remark} \begin{exam}Let $X$ be a nonempty set and let $\mathscr{P}(X)$ be the power set of $X$. Let $\mtop_\mathscr{P}:=\{(A,B)\in \mathscr{P}(X)\times \mathscr{P}(X)\,|\,A\subseteq B\}$. Then $(\mathscr{P}(X),\mtop_\mathscr{P})$ together with the union operation $\cup$ or the intersection operation $\cap$ is a locality semigroup. Furthermore, $(\mathscr{P}(X),\mtop_\mathscr{P},\cup)$ is a locality semigroup with left identity $\emptyset$, and $(\mathscr{P}(X),\mtop_\mathscr{P},\cap)$ is a locality semigroup with left zero element $\emptyset$. Both are also transitive, since the inclusion relation $\subseteq$ on $\mathscr{P}(X)$ is a partial order. \mlabel{exam:powset} \end{exam} \begin{exam}{\bf(}\cite[Example 3.6]{CGPZ1}{\bf)} Let $\N^+$ be the set of positive integers and let $a,b\in \N^+$. Let $\gcd(a,b)$ be the greatest common divisor of $a,b$. Denote $$\mtop_{cop}:=\{(a,b)\,|\, \gcd(a,b)=1,a,b\in \N^+\}.$$ Since $\gcd(a,b)=\gcd(b,a)$, we have $\lt=U^\top$ for all $U\subseteq \N^+$. Let $u\in U$. If $\gcd(u,a)=1$ and $\gcd(u,b)=1$, then $\gcd(u,ab)=1$, and so Eqs.~(\mref{eq:leftclosed}) and (\mref{eq:rightclosed}) hold. Then $(\N^+,\mtop_{cop})$ with the ordinary multiplication on $\N^+$ is a locality monoid. \mlabel{exam:PosIn} \end{exam} \begin{exam} Let $\N$ be the set of nonnegative integers. Denote $$\top:=\mtop_{cop}^{\,0}:=\mtop_{cop}\cup\{(0,0),(0,a),(a,0)\,|\, a\in \N^+\}.$$ Then $\{0\}^\mtop={}^\top\!\{0\}=\N$, and if $(0,a)\in \mtop_{cop}^{\,0}$ and $(0,b)\in \mtop_{cop}^{\,0}$ with $(a,b)\in \mtop_{cop}^{\,0}$ for all $a,b\in \N$, then $(0,a b)\in \mtop_{cop}^{\,0}$. Thus, Eqs.~(\mref{eq:leftclosed}) and (\mref{eq:rightclosed}) hold by Example~\mref{exam:PosIn}, and hence $(\N,\mtop_{cop}^{\,0})$ with the ordinary multiplication on $\N$ is a locality semigroup with zero. \end{exam} As a result, we obtain a way, analogous to that for semigroups~\mcite{How,PRe}, to construct a locality monoid or locality semigroup with zero from a locality semigroup as follows. \begin{lem}Let $(S,\mtop_S)$ be a locality semigroup. Let $0,1\notin S$. \begin{enumerate} \item Let $S^1:=S\cup\{1\}$. Denote $\mtop_{S^1}:=\mtop_S\cup\{(1,1),(1,a),(a,1)\,|\, a\in S\}$. Define a partial binary operation on $S^1$: $$\mu_1:S^1\times_{\mtop_{S^1}}S^1\to S^1,\quad \mu_1(a,b):=\left\{\begin{array}{llll}ab,\quad\text{if}\,\,(a,b)\in \mtop_S;\\ b,\quad\text{if}\,\, a=1;\\ a,\quad\text{if}\,\, b=1.\end{array}\right.$$ Then $(S^1,\mu_1)$ is a locality monoid. \item Let $S^0:=S\cup\{0\}$. Denote $\mtop_{S^0}:=\mtop_S\cup\{(0,0),(0,a),(a,0)\,|\, a\in S\}$. Define a partial binary operation on $S^0$: $$\mu_0:S^0\times_{\mtop_{S^0}}S^0\to S^0,\quad \mu_0(a,b):=\left\{\begin{array}{llll}ab,\quad\text{if}\,\,(a,b)\in \mtop_S;\\ 0,\quad\text{if}\,\, a=0\,\text{or}\,\, b=0.\end{array}\right.$$ Then $(S^0,\mu_0)$ is a locality semigroup with zero. \end{enumerate} \end{lem} \begin{defn}Let $(S,\mtop_S)$ be a locality semigroup. Let $\emptyset\neq A\subseteq S$ and let $\mtop_A:=(A\times A) \cap \mtop_S$. \begin{enumerate} \item A sub-locality set $(A,\mtop_A)$ is called a {\bf sub-locality semigroup} of $(S,\mtop_S)$ if it is closed under the partial binary operation of $(S,\mtop_S)$, i.e. it satisfies the condition: for all $(a,b)\in \mtop_A$, $ab\in A$; \item Let $\mtop_{\ell}:=(S\times A) \cap \mtop_S$. The pair $(A,\mtop_\ell)$ is called a {\bf left locality ideal} of $(S,\mtop_S)$ if it satisfies the condition: for all $(s,a)\in \mtop_\ell$, $sa\in A$; \item Let $\mtop_r:=(A\times S) \cap \mtop_S$. The pair $(A,\mtop_r)$ is called a {\bf right locality ideal} of $(S,\mtop_S)$ if it satisfies the condition: for all $(a,s)\in \mtop_r$, $as\in A$; \item The pair $(A,\mtop_\ell\cup\mtop_r)$ is called a {\bf locality ideal} of $(S,\mtop_S)$ if $(A,\mtop_\ell)$ is a left locality ideal and $(A,\mtop_r)$ is a right locality ideal, that is, for all $s\in S$ and all $a\in A$, if $(s,a)\in \mtop_\ell$ and $(a,s)\in \mtop_r$, then $sa\in A$ and $as\in A$. \end{enumerate} \end{defn} We know that if $(A,\mtop_\ell\cup\mtop_r)$ is a locality ideal, then $(A,\mtop_A)$ is a locality semigroup, but not vice versa. For example, \begin{exam} \begin{enumerate} \item According to Example~{\mref{exam:PosIn}}, we let $\mo: =2\N+1$ be the set of positive odd integers, and let $\mtop_\mo:=(\mo\times \mo)\cap \mtop_{cop}$. Then $(\mo,\mtop_\mo)$ is a sub-locality semigroup of $(\N^+,\mtop_{cop})$, since the multiplication of two odd numbers is still odd. But if we let $\mtop_{\ell}:=(\N^+\times \mo) \cap \mtop_{cop}$, then $(\mo,\mtop_\ell)$ is not a left locality ideal of $(\N^+,\mtop_{cop})$ (although $(2,3)\in\mtop_{\ell}$, $6\notin \mo$). Also, let $\mtop_{r}:=(\mo\times \N^+) \cap \mtop_{cop}$. Then $(\mo,\mtop_r)$ is also not a right locality ideal. Thus, $(\mo,\mtop_\ell \cup\mtop_r)$ is not a locality ideal of $(\N^+,\mtop_{cop})$. \item By Example~{\mref{exam:powset}}, we choose a fixed $x_0\in X$ and let $\mathscr{P}_{x_0}:=\{A\in \mathscr{P}(X)\,|\,x_0\in A\}$. Denote $\mtop_{\mathscr{P}_{x_0}}:=(\mathscr{P}_{x_0}\times\mathscr{P}_{x_0})\cap \mtop_\mathscr{P}$. Then we see that $(\mathscr{P}_{x_0},\mtop_{\mathscr{P}_{x_0}})$ is a sub-locality semigroup of $(\mathscr{P}(X),\mtop_\mathscr{P},\cup)$. In addition, if we let $\mtop_\ell:=(\mathscr{P}(X)\times \mathscr{P}_{x_0})\cap \mtop_\mathscr{P}$, then $(\mathscr{P}_{x_0},\mtop_\ell)$ is a left locality ideal of $(\mathscr{P}(X),\mtop_\mathscr{P},\cup)$. Let $\mtop_r:=(\mathscr{P}_{x_0}\times \mathscr{P}(X))\cap \mtop_\mathscr{P}$. Then $(\mathscr{P}_{x_0},\mtop_r)$ is a right locality ideal of $(\mathscr{P}(X),\mtop_\mathscr{P},\cup)$. Thus, $(\mathscr{P}_{x_0},\mtop_\ell\cup\mtop_r)$ is a locality ideal. \end{enumerate} \end{exam} \begin{remark} For every sub-locality set $(A,\mtop_A)$ of $(S,\mtop_S)$, there is at least sub-locality semigroup containing $(A,\mtop_A)$. Denote by $\{ (A_i,\mtop_{A_i})\,|\, i\geq 1\}$, where $(A_i,\mtop_{A_i})$ is a sub-locality semigroup of $(S,\mtop_S)$ containing $(A,\mtop_A)$ for each $i\geq 1$, the set consisting of all sub-locality semigroups containing $(A,\mtop_A)$. Note that \begin{equation} \cap_{i\geq 1}\mtop_{A_i}=\big((\cap_{i\geq 1}A_i)\times (\cap_{i\geq 1}A_i)\big)\cap \mtop_S. \mlabel{eq:Inter} \end{equation} Let $$\bigcap_{i\geq 1}(A_i,\mtop_i):=(\cap_{i\geq 1}A_i, \cap_{i\geq 1}\mtop_{A_i})$$ be the intersection of all sub-locality semigroups containing $(A,\mtop_A)$. Then by Eq.~(\mref{eq:Inter}), $\bigcap_{i\geq 1}(A_i,\mtop_i)$ is a sub-locality semigroup of $(S,\mtop_S)$. We denote it by $\langle A,\top_A \rangle$, and we call $\langle A,\top_A \rangle$ the {\bf sub-locality semigroup of $(S,\mtop_S)$ generated by the sub-locality set $(A,\mtop_A)$}, i.e. the smallest sub-locality semigroup containing $(A,\mtop_A)$. \end{remark} \begin{defn} Let $(X,\mtop_X)$ and $(Y,\mtop_Y)$ be locality sets. A set map $\phi:X\to Y$ is called a {\bf locality map} if it satisfies $(\phi \times \phi)(\mtop_X)\subseteq \mtop_Y$, that is, $(\phi\times \phi)(x_1,x_2):=(\phi(x_1),\phi(x_2))\in \mtop_Y$ for all $(x_1,x_2)\in \mtop_X$. \end{defn} \begin{defn} Let $(S_1,\mtop_{S_1},\cdot_{S_1})$ and $(S_2,\mtop_{S_2},\cdot_{S_2})$ be locality semigroups. A set map $\phi:S_1\to S_2$ is called a {\bf locality semigroup homomorphism} if it satisfies the following conditions: \begin{enumerate} \item $\phi$ is a locality map; \item $\phi$ is {\bf locality multiplicative}: for all $(a,b)\in \mtop_{S_1}$, we have $\phi(a\cdot_{S_1} b)=\phi (a)\cdot_{S_2}\phi(b)$. \end{enumerate} \end{defn} Furthermore, let $(S_1,\mtop_{S_1},1_{S_1})$ and $(S_2,\mtop_{S_2}, 1_{S_2}) $ be monoids. We say that a locality semigroup homomorphism $\phi: (S_1,\mtop_{S_1},1_{S_1})\to (S_2,\mtop_{S_2},1_{S_2}$) is a {\bf locality monoid homomorphism} if $\phi (1_{S_1})=1_{S_2}$. For instance, $(\N^+,\mtop_{cop})$ is a locality monoid according to Example~\mref{exam:PosIn}~\mcite{CGPZ1}. Then the Euler's totient function $\varphi:\N^+\to \N^+,\,n\mapsto \varphi(n)$, counting the positive integers coprime to (but not bigger than) $n$, is a locality monoid homomorphism from $(\N^+,\mtop_{cop})$ to $(\N^+,\mtop_{ful})$, where $\mtop_{ful}$ is the full relation on $\N^+$. \subsection{Path locality semigroups of a quiver} \mlabel{subsec:pathlocsg} Now we introduce the path locality semigroups of a quiver. \begin{defn} A {\bf quiver} is a quadruple $ Q:=(Q_0,Q_1,s,t)$, where \begin{enumerate} \item $Q_0$ is a set, called the {\bf vertex set}; \item $Q_1$ is also a set, called the {\bf arrow set}; \item $s:Q_1\to Q_0$ is a map, called the {\bf source function}, and $t:Q_1\to Q_0$ is a map, called the {\bf target function}. \end{enumerate} \end{defn} We shall denote the vertices $x,y,z,\cdots$ in the vertex set $Q_0$ and denote the arrows $\alpha, \beta,\gamma,\cdots$ in the arrow set $Q_1$. For every arrow $\alpha \in Q_1$, if $s(\alpha)=x$ [resp. $t(\alpha)=y$], then we call $x$ [resp. $y$] a {\bf source} [resp. {\bf target}] of $\alpha$. An arrow with a source $x$ and a target $y$ will be denoted by $\alpha:x\to y$, or simply by $x\overset{\alpha}{\to} y$. Thus, for example, the quiver with vertices $x,y$ and arrows $\alpha:x\to y$, $\beta_1: x\to x$ and $\beta_2: y\to y$, can be depicted as follows: \begin{equation} \xymatrix{ x \ar@(ul,dl)[]_{\beta_1} \ar[r]^{\alpha} & y \ar@(ur,dr)[]^{\beta_2}}. \mlabel{eq:quiver} \end{equation} \begin{defn} Let $Q:=(Q_0,Q_1,s,t)$ be a quiver and let $k\geq 1$. \begin{enumerate} \item A {\bf path} in $Q$ is either a vertex $v\in Q_0$, usually called an {\bf empty path} or a {\bf trivial path} and often denoted by $e_v$, or a sequence $p:=\alpha_1\alpha_2\cdots\alpha_k$ of arrows, where $\alpha_i\in Q_1$ for each $1\leq i\leq k$, and $t(\alpha_i)=s(\alpha_{i+1})$ for all $1\leq i\leq k-1$. \item Let $k\geq 1$. For all nonempty path $p=\alpha_1\alpha_2\cdots\alpha_k$ in $Q$, where $\alpha_i\in Q_1$ for each $i=1,\cdots,k$, we call $s(p):=s(\alpha_1)$ the {\bf source} of $p$ and call $t(p):=t(\alpha_k)$ the {\bf target} of $p$. In that case we say that the {\bf length} of $p$ is $k$, denoted by $\ell(p)$. By convention, if $p=e_v$ is an empty path, we say that $s(p)=t(p)=v$, and the length of $p$ is $0$. Then $\ell(p)=0$ if and only if $p$ is an empty path. \item An {\bf oriented cycle} is a path $p$ with $s(p)=t(p)$. \end{enumerate} \end{defn} When there is no danger of confusion, we also denote $Q:=(Q_0,Q_1)$. \begin{remark} We denote by $\calp$ the set of paths in a quiver $Q$. By the definition of length of a path in $Q$, we identity $Q_0$ and $Q_1$ with the set of all paths of length $0$ and the set of all paths of length $1$, respectively. More generally, for all $n\geq 0$, we define \begin{equation} Q_n:=\{p\in \calp\,|\, \ell(p)=n\}. \end{equation} Thus we get \begin{equation} \calp=\bigsqcup_{n\geq 0} Q_n, \end{equation} the disjoint union of the sets $Q_n$. \end{remark} \begin{exam} Let $Q$ be the quiver $$\xymatrix{ &x\ar[r]^{\alpha} &y, \,\,y \ar[r]^{\beta} &z.} $$ Then $\calp=\{e_x,e_y,e_z,\alpha,\beta,\alpha\beta\}$, where $$\xymatrix{ &\alpha\beta:=x\ar[r]^{\alpha} &y \ar[r]^{\beta} &z,}$$ the composition of paths $\alpha$ and $\beta$. \end{exam} Let $Q$ be a quiver. Let $\calp$ be the set of all paths in $Q$. Then we define \begin{equation} \mtop_\calp:=\calp \times_\top \calp:=\{(p,q)\,|\, t(p)=s(q),p,q\in \calp\}. \mlabel{eq:mtopcalp} \end{equation} For all $(p,q)\in \mtop_\calp$, we define $pq$ to be the composition of paths $p$ and $q$. \begin{defn} Let $Q$ be a quiver and let $\calp$ be the set of all paths in $Q$. Let $p\in \calp$. \begin{enumerate} \item The expression $$p=v_0\alpha_1v_1\alpha_2\cdots v_{k-1}\alpha_k v_k,$$ where $v_i\in Q_0$ for $0\leq i\leq k$ and $\alpha_j\in Q_1$, and $s(\alpha_j)=v_{j-1}$ and $t(\alpha_j)=v_j$ for $1\leq j\leq k$, is called the {\bf standard decomposition of $p$}. \item The expression $$p:=\alpha_1\alpha_2\cdots\alpha_k,$$ where $\alpha_i\in Q_1$ for $1\leq i\leq k$, is called the {\bf standard decomposition of $p$ into arrows}. \end{enumerate} \end{defn} For every $p\in \calp$, we know that the standard decomposition of $p$ into arrows is unique. Here is a natural way to construct a locality semigroup from the set of paths $\calp$. \begin{prop} Let $Q$ be a quiver and let $\calp$ be the set of all paths in $Q$. Denote $$\mtop_\calp:=\calp \times_\top \calp:=\{(p,q)\,|\, t(p)=s(q),p,q\in \calp\}.$$ A partial binary operation $\mu_\calp:\calp\times_\top\calp\to \calp$ is given by $(p,q)\mapsto pq$, the composition of paths $p$ and $q$. Then $(\calp,\mtop_\calp,\mu_\calp)$ is a locality semigroup, called a {\bf path locality semigroup} of $Q$. \mlabel{prop:pathsg} \end{prop} \begin{proof} We shall prove that $\mu_\calp((U^{\mtop_\calp}\times U^{\mtop_\calp})\cap \mtop_\calp)\subseteq U^{\mtop_\calp}$ and $\mu_\calp(({}^{\mtop_\calp}\!U\times{}^{\mtop_\calp}\!U)\cap \mtop_\calp)\subseteq {}^{\mtop_\calp}\!U$ for all subset $U$ of $\calp$. Let $(p,q)\in (U^{\mtop_\calp}\times U^{\mtop_\calp})\cap \mtop_\calp$. This means that $(u,p)\in \mtop_\calp$ and $(u,q)\in \mtop_\calp$ for all $u\in U$, and so $t(u)=s(p)=s(q)$. Then $s(pq)=s(p)=t(u)$, and hence $(u,pq)\in \mtop_\calp$ holds for all $u\in U$. Thus $pq\in U^{\mtop_\calp}$. On the other hand, let $(p,q)\in ({}^{\mtop_\calp}\!U\times{}^{\mtop_\calp}\!U)\cap \mtop_\calp$. Then $(p,u)\in \mtop_\calp$ and $(q,u)\in \mtop_\calp$ for all $u\in U$, and so $t(p)=s(u)=t(q)$. Thus $t(pq)=t(q)=s(u)$. Then we get $(pq,u)\in \mtop_\calp$ for all $u\in U$. This gives $pq\in {}^{\mtop_\calp}\!U$. Next we verify that the locality associative law holds, that is, $(p_1 p_2) p_3=p_1 (p_2 p_3) $ for all $(p_1,p_2),(p_1, p_3),(p_2,p_3)\in \mtop_\calp$. Let $(p_1,p_2),(p_1, p_3),(p_2,p_3)\in \mtop_\calp$. Then $t(p_1)=s(p_2)$ and $t(p_2)=s(p_3)$. Thus $t(p_1p_2)=t(p_2)=s(p_3)$ and $t(p_1)=s(p_2)=s(p_2p_3)$, and hence $(p_1p_2,p_3)\in \mtop_\calp$ and $(p_1,p_2p_3)\in \mtop_\calp$. This shows that $$(p_1 p_2) p_3=p_1p_2p_3=p_1(p_2 p_3).$$ \end{proof} \subsection{Free \fine locality semigroups on a locality set} \mlabel{subsec:fineLSG} We then give a explicit construction of free objects in the category of \fine locality semigroups. We begin by introducing the definition of \fine locality semigroups. \begin{defn} Let $(S,\top)$ be a locality set. A {\bf \fine locality semigroup} is a locality set $(S,\top)$ together with a partial binary operation: $$\mu_S:S\times_\top S \to S,\quad (a,b)\mapsto ab\,\,\,\text{for all}\, (a,b)\in \top,$$ such that for all $a,b,c\in S$, \begin{enumerate} \item If $(a,b)\in\top$, then $(b,c)\in\top$ if and only if $(ab,c)\in\top$; and \mlabel{it:fineone} \item If $(b,c)\in\top$, then $(a,b)\in \top$ if and only if $(a,bc)\in\top$; and \mlabel{it:finetwo} \item If $(a,b),(b,c)\in \top $, then $(ab)c=a(bc).$ \mlabel{it:fineass} \end{enumerate} \mlabel{defn:flocsg} \end{defn} \begin{remark} By Definition~\mref{defn:flocsg}(\mref{it:fineone}) and (\mref{it:finetwo}), we have \begin{equation} (a,b),(b,c)\in\top\Rightarrow (ab,c),(a,bc)\in\top\quad \text{for all}\,\,a,b,c\in S. \mlabel{eq:refinedremark} \end{equation} Thus $(ab)c$ and $a(bc)$ make sense. \end{remark} \begin{prop}Let $(\calp,\mtop_\calp,\mu_\calp)$ be the path locality semigroup as defined in Proposition~\mref{prop:pathsg}. Then $(\calp,\mtop_\calp,\mu_\calp)$ is also a refined locality semigroup. \mlabel{prop:pathresg} \end{prop} \begin{proof} We first show that $(\calp,\mtop_\calp)$ satisfies the condition (\mref{it:fineone}) of Definition~\mref{defn:flocsg}. For all $p_1,p_2,p_3\in\calp$, assume $(p_1,p_2)\in \mtop_\calp$. If $(p_2,p_3)\in\mtop_\calp$, then $t(p_2)=s(p_3)$, and so $t(p_1p_2)=t(p_2)=s(p_3)$. Thus, $(p_1p_2,p_3)\in\mtop_\calp$. For the converse, if $(p_1p_2,p_3)\in\mtop_\calp$, then $t(p_2)=t(p_1p_2)=s(p_3)$, and hence $(p_2,p_3)\in\mtop_\calp$. Secondly, we verify that the condition (\mref{it:finetwo}) of Definition~\mref{defn:flocsg} holds. Suppose $(p_2,p_3)\in\mtop_\calp$. If $(p_1,p_2)\in\mtop_\calp$, then $t(p_1)=s(p_2)=s(p_2p_3) $, and thus $(p_1,p_2p_3)\in\mtop_\calp$. Conversely, if $(p_1,p_2p_3)\in\mtop_\calp$, then $t(p_1)=s(p_2p_3)=s(p_2)$, and so $(p_1,p_2)\in\mtop_\calp$. Finally, we prove that $(\calp,\mtop_\calp)$ satisfies the condition~(\mref{it:fineass}) of Definition~\mref{defn:flocsg}. Suppose $(p_1,p_2),(p_2,p_3)\in\mtop_\calp$. Then $t(p_1)=s(p_2)$ and $t(p_2)=s(p_3)$, and this gives equations $t(p_1)=s(p_2p_3)$ and $t(p_1p_2)=s(p_3)$. Hence $(p_1,p_2p_3),(p_1p_2,p_3)\in\mtop_\calp$, and thus $(p_1p_2)p_3=p_1(p_2p_3)$. \end{proof} \begin{lem} Let $(S,\mtop_S)$ be a \fine locality semigroup and let $n\geq 2$. Let $(X,\mtop_X)$ be a locality set and let $(x_i,x_{i+1})\in \mtop_X$ for $i=1,\cdots,n-1$. If $f:(X,\mtop_X)\to (S,\mtop_S)$ is a locality map, then \begin{equation} (f(x_1)\cdots f(x_{n-1}),f(x_{n}))\in \mtop_S \mlabel{eq:fs1} \end{equation} and \begin{equation} (f(x_1),f(x_2)\cdots f(x_{n}))\in \mtop_S. \mlabel{eq:fs2} \end{equation} \mlabel{lem:fs} \end{lem} \begin{proof} We prove Eqs.~(\mref{eq:fs1}) and (\mref{eq:fs2}) by induction on $n\geq 2$. For $n=2$, we have $(f(x_1),f(x_2))\in \mtop_S$ by $f$ being a locality map. Assume that Eqs.~(\mref{eq:fs1}) and (\mref{eq:fs2}) have been proved for $n\leq k$. Consider $n=k+1$. By hypothesis, $(x_i,x_{i+1})\in \mtop_X$ for $i=1,\cdots,k$ . Since $f$ is a locality map, $(f(x_{i}),f(x_{i+1}))\in \mtop_S$ for all $i$, and especially $(f(x_k),f(x_{k+1}))\in\mtop_S$. By the induction hypothesis, we get $$(f(x_1)\cdots f(x_{k-1}), f(x_{k}))\in \mtop_S,\quad (f(x_1),f(x_2)\cdots f(x_{k}))\in \mtop_S$$ and $ (f(x_2)\cdots f(x_{k}),f(x_{k+1}))\in \mtop_S$. Since $(S,\mtop_S)$ is a \fine locality semigroup, we have $$(f(x_1)\cdots f(x_{k-1})f(x_k),f(x_{k+1}))\in \mtop_S$$ and $$(f(x_1),f(x_2)\cdots f(x_{k})f(x_{k+1}))\in \mtop_S.$$ This completes the induction, and thus the proof. \end{proof} \begin{lem} Let $(S,\mtop_S)$ be a \fine locality semigroup and let $m,n\geq 1$. Let $(X,\mtop_X)$ be a locality set. Let $(x_i,x_{i+1})$, $(y_j,y_{j+1})\in \mtop_X$ for $i=1,\cdots,m-1$ and $j=1,\cdots,n-1$. If $f:(X,\mtop_X)\to (S,\mtop_S)$ is a locality map and $(x_m,y_1)\in \mtop_X$, then \begin{equation} (f(x_1)\cdots f(x_m),f(y_1)\cdots f(y_n))\in \mtop_S. \mlabel{eq:fmul} \end{equation} \mlabel{lem:fmul} \end{lem} \begin{proof} We first verify that Eq.~(\mref{eq:fmul}) holds for special cases $m=1$ or $n=1$. If $m=1$, then by hypothesis, $$(x_1,y_1), (y_1,y_2),\cdots,(y_{n-1},y_n)\in \mtop_X.$$ By Eq.~(\mref{eq:fs2}), $(f(x_1),f(y_1)\cdots f(y_n))\in \mtop_S$. Similarly, if $n=1$, then $$(x_1,x_2), \cdots,(x_{m-1},x_m),(x_m,y_1)\in \mtop_X,$$ and so $(f(x_1)\cdots f(x_m),f(y_1))\in \mtop_S$ by Eq.~(\mref{eq:fs1}). Next we consider $m,n\geq 2$. By Lemma~\mref{lem:fs}, we obtain \begin{equation} (f(x_1)\cdots f(x_{m-1}), f(x_m))\in \mtop_S \end{equation} and \begin{equation} (f(y_1),f(y_2)\cdots f(y_n))\in \mtop_S. \mlabel{eq:fbeta} \end{equation} Since $f$ is a locality map, we have $(f(x_m),f(y_1))\in \mtop_S$. By $(S,\mtop_S)$ being a \fine locality semigroup and Eq.~(\mref{eq:refinedremark}), we get $$(f(x_1)\cdots f(x_{m-1})f(x_m),f(y_1))\in \mtop_S.$$ Thus, together with Eqs.~(\mref{eq:refinedremark}) and (\mref{eq:fbeta}), $$(f(x_1)\cdots f(x_{m-1})f(x_m),f(y_1)f(y_2)\cdots f(y_n))\in \mtop_S.$$ \end{proof} \begin{defn} {\rm Let $(X,\mtop_X)$ be a locality set. A {\bf free \fine locality semigroup} on $(X,\mtop_X)$ is a \fine locality semigroup $(F_L(X),\mtop_F)$ together with a locality map $j_X: (X,\mtop_X)\to (\FL(X),\mtop_F)$ such that, for any \fine locality semigroup $(S,\mtop_S)$ and any locality map $f:(X,\mtop_X)\to (S, \mtop_S)$, there exists a unique locality semigroup homomorphism $\free{f}: (\FL(X),\mtop_F)\to (S,\mtop_S)$ such that $f=\free{f}\circ j_X$, that is, the following diagram $$\xymatrix{ (X,\mtop_X) \ar[rr]^{j_X}\ar[drr]_{f} && (\FL(X),\mtop_F) \ar[d]^{\free{f}} \\ && (S,\mtop_S)} $$ commutes.} \mlabel{defn:freelocsg} \end{defn} We next give a construction of free \fine locality semigroups on a locality set. Let $Q$ be a quiver. Denote \begin{equation} \mtop_\calq:=Q\times_\mtop Q:=\{(\alpha,\beta)\,|\,t(\alpha)=s(\beta),\alpha,\beta\in Q\}. \end{equation} Then $(Q,\mtop_\calq)$ is a locality set. Define a set map \begin{equation} j_\calq: Q\to \calp,\quad\alpha\mapsto \alpha,\quad \alpha\in Q. \end{equation} Then $(j_\calq\times j_\calq)(\alpha,\beta)=(\alpha,\beta)\in \mtop_\calp$ for all $(\alpha,\beta)\in \mtop_\calq$, and so $j_\calq$ is a locality map. We next give the main result of this section. \begin{theorem} With notations as above, the path locality semigroup $(\calp,\mtop_\calp, \mu_\calp)$ with $j_\calq$ is a free \fine locality semigroup on a locality set $(Q,\mtop_\calq)$. \mlabel{thm:FreeStrLocSg} \end{theorem} \begin{proof} By Proposition~\mref{prop:pathresg}, the path locality semigroup $(\calp,\mtop_\calp, \mu_\calp)$ is a \fine locality semigroup. We next show that $(\calp,\mtop_\calp, \mu_\calp)$ satisfies the required universal property. Let $(S,\mtop_S)$ be a \fine locality semigroup and let $f: (Q,\mtop_\calq) \to (S,\mtop_S)$ be a locality map. Define a set map $$ \bar{f}: \calp \to S,\quad p\mapsto \bar{f}(p):=f(\alpha_1)f(\alpha_2)\cdots f(\alpha_k), $$ where $ p=\alpha_1\cdots\alpha_k\in \calp$, and $\alpha_i\in Q$ for $1\leq i\leq k.$ Since $(\alpha_i,\alpha_{i+1})\in\mtop_\calq$ for $i=1,\cdots,k-1$, we have $(f(\alpha_1),f(\alpha_2)\cdots f(\alpha_k))\in\mtop_S$ by Eq.~(\mref{eq:fs2}) in Lemma~\mref{lem:fs}, and thus $\bar{f}$ is well-defined. Firstly, we see that $f=\bar{f}\circ j_\calq$. We then prove that $\bar{f}$ is indeed a locality semigroup homomorphism, that is, $(\bar{f}\times\bar{f})(p_1,p_2)=(\bar{f}(p_1),\bar{f}(p_2))\in \mtop_S$ and $\bar{f}(p_1p_2)=\bar{f}(p_1)\bar{f}(p_2)$ for all $(p_1,p_2)\in \mtop_\calp$. Let $(p_1,p_2)\in \mtop_\calp$. Suppose that $p_1=\alpha_1\cdots\alpha_m$ and $p_2=\beta_1\cdots \beta_n$ with $m,n\geq 1$, where $\alpha_i, \beta_j\in Q$ for $1\leq i\leq m $ and $1\leq j\leq n$. Then we obtain $(\alpha_i,\alpha_{i+1})\in \mtop_\calq$ and $(\beta_j,\beta_{j+1})\in \mtop_\calq$ for $i=1,\cdots, m-1$ and $j=1,\cdots,n-1$. By $(p_1,p_2)\in \mtop_\calp$, $$t(\alpha_m)=t(p_1)=s(p_2)=s(\beta_1),$$ and so $(\alpha_m,\beta_1)\in \mtop_\calp$. Thus, by Lemma~\mref{lem:fmul}, we get $$(f(\alpha_1)\cdots f(\alpha_{m-1})f(\alpha_m),f(\beta_1)f(\beta_2)\cdots f(\beta_n))\in \mtop_S.$$ This means that $(\bar{f}(p_1),\bar{f}(p_2))\in \mtop_S$. Now we prove that $\bar{f}(p_1p_2)=\bar{f}(p_1)\bar{f}(p_2)$. By the definition of $\bar{f}$, we have \begin{eqnarray*} \bar{f}(p_1p_2)&=&\bar{f}(\alpha_1\cdots\alpha_m\beta_1\cdots\beta_n)\\ &=&f(\alpha_1)\cdots f(\alpha_m)f(\beta_1)\cdots f(\beta_n)\\ &=&\bar{f}(p_1)\bar{f}(p_2). \end{eqnarray*} To complete the proof, we finally verify the uniqueness of $\bar{f}$. Assume that there is another locality semigroup homomorphism $\tilde{f}:(\calp,\mtop_\calp)\to (S,\mtop_S)$ such that $f=\tilde{f}\circ j_\calq$. For every $p=\alpha_1\cdots\alpha_k\in \calp$, we have \begin{eqnarray*} \tilde{f}(p)&=&\tilde{f}(\alpha_1\cdots \alpha_k)\\ &=&\tilde{f}(\alpha_1)\cdots\tilde{f}(\alpha_k)\\ &=&\tilde{f}(j_\calq(\alpha_1))\cdots\tilde{f}(j_\calq(\alpha_k))\\ &=&f(\alpha_1)\cdots f(\alpha_k)\\ &=&\bar{f}(p). \end{eqnarray*} Thus $\tilde{f}=\bar{f}$, as desired. \end{proof} \section{The relationships among several classes locality semigroups} \mlabel{sec:parSG} In this section, we first introduce the \weak locality semigroups and partial semigroups. We then investigate the relationships among \weak locality semigroups, partial semigroups and \fine locality semigroups. \subsection{Strong locality semigroups} \mlabel{subsec:strlsg} We first introduce the concept of \weak locality semigroups. \begin{defn}Let $(S,\top)$ be a locality set. A {\bf \weak locality semigroup} is a locality set $(S,\top)$ together with a partial binary operation defined on $S$: $$\mu_S:S\times_\top S \to S,\quad (a,b)\mapsto ab\,\,\text{for all}\, (a,b)\in \top,$$ such that the {\bf \weak locality associative law} holds: for all $a,b,c\in S$, \begin{equation} (a,b), (b,c)\in \top \Rightarrow (ab,c),(a,bc)\in \top\,\, \text{and}\,\,(ab)c=a(bc). \mlabel{eq:wcomp} \end{equation} \mlabel{defn:wlocsg} \end{defn} \begin{lem} Let $(\calp,\mtop_\calp,\mu_\calp)$ be the path locality semigroup defined as in Proposition~\mref{prop:pathsg}. Then $(\calp,\mtop_\calp,\mu_\calp)$ is a \weak locality semigroup. \mlabel{lem:PathWeak} \end{lem} \begin{proof} Let $(p_1,p_2), (p_2,p_3)\in \mtop_\calp$. Then $t(p_1)=s(p_2)$ and $t(p_2)=s(p_3)$, and so $t(p_1p_2)=t(p_2)=s(p_3)$ and $t(p_1)=s(p_2)=s(p_2p_3)$. This means that $(p_1p_2,p_3) \in \mtop_\calp$ and $(p_1,p_2p_3)\in \mtop_\calp$, and thus $(p_1p_2)p_3=p_1(p_2p_3).$ \end{proof} Furthermore, we know that \begin{prop}Every \weak locality semigroup is a locality semigroup. \mlabel{prop:weak-loca} \end{prop} \begin{proof} Suppose that $(S,\mtop_S,\mu_S)$ is a \weak locality semigroup. We first prove Eqs.~(\mref{eq:leftclosed}) and (\mref{eq:rightclosed}) in Definition~\mref{defn:locsg}. Let $U\subseteq S$ and let $(a,b)\in (\lt\times\lt)\cap \mtop_S$. Then $(b,u)\in \mtop_S$ for all $u\in U$. Since $(a,b)\in \mtop_S$, we have $(ab,u)\in \mtop_S$ by Eq.~(\mref{eq:wcomp}). This gives $ab\in \lt$, and thus $\mu_S((\lt\times\lt)\cap \mtop_S)\subseteq \lt$. Let $(a,b)\in (U^\top\times U^\top)\cap \mtop_S$. Then $(u,a)\in \mtop_S$ for all $u\in U$. By $(a,b)\in \mtop_S$ and Eq.~(\mref{eq:wcomp}) again, we get $(u,ab)\in \mtop_S$, and so $\mu_S((U^\top\times U^\top)\cap \mtop_S)\subseteq U^\top$. The locality associative law follows from that for every $(a,b),(b,c)\in\mtop_S$, $(ab,c),(a,bc)\in\mtop_S$ and $(ab)c=a(bc)$. \end{proof} But it is not true that every locality semigroup is a \weak locality semigroup. \begin{coex} According to Example~\mref{exam:PosIn}, $(\N^+,\mtop_{cop})$ is a locality semigroup. But it is not a \weak locality semigroup. In fact, we note that $(2,3)\in \mtop_{cop}$ and $(3,4)\in \mtop_{cop}$, but $(6,4)\notin \mtop_{cop}$ and $(2,12)\notin \mtop_{cop}$. This means that $(\N^+,\mtop_{cop})$ does not satisfy Eq.~(\mref{eq:wcomp}). \mlabel{coex:locsg-weaksg} \end{coex} \subsection{Partial semigroups} In this section, we give the definition of partial semigroups~\mcite{Sch}. \begin{defn} \begin{enumerate} \item Let $(S,\top)$ be a locality set. A {\bf partial semigroup} is a locality set $(S,\top)$ together with a partial binary operation defined on $S$: $$\mu_S:S\times_\top S \to S,\quad (a,b)\mapsto ab\,\,\text{for all}\,\, (a,b)\in \top,$$ such that the {\bf partial associative law} holds: for all $a,b,c\in S$, if $(a,b), (b,c)\in \top $, then \begin{equation} (ab,c)\in \top \Leftrightarrow (a,bc)\in \top \mlabel{eq:equivalent} \end{equation} and in that case, \begin{equation} (ab)c=a(bc). \mlabel{eq:parasslaw} \end{equation} \item A partial semigroup $(S,\top)$ is said to be {\bf transitive} if $\top$ is transitive, that is, $$(a,b)\in \top \,\,\text{and}\,\, (b,c)\in \top \Rightarrow (a,c)\in \top.$$ \end{enumerate} \mlabel{defn:parsg} \end{defn} Firstly, we see that every semigroup is a partial semigroup. Next we give another example of patrial semigroups. \begin{exam} Let $S:=\{0,1\}$ and let $\top:=\{(0,0),(0,1),(1,0)\}$. A {\bf partial addition} $+:S\times_\top S\to S$ is defined by $(0,0)\mapsto 0,\quad(0,1)\mapsto 1,\quad (1,0)\mapsto 1.$ We shall prove that $(S,\top,+)$ is a partial semigroup. There are also five cases: $(0,0),(0,0)\in \top$; $(0,0),(0,1)\in \top$; $(0,1),(1,0)\in \top$; $(1,0),(0,0)\in \top$ and $(1,0),(0,1)\in \top$, having the property: $(a,b),(b,c)\in\top$ in Definition~\mref{defn:parsg}. We can check that Eq.~(\mref{eq:equivalent}) in Definition~\mref{defn:parsg} holds for the first four cases. The last case gives $(1+0,1)=(1,1)\notin \top$ and $(1,0+1)=(1,1)\notin\top$, and so Eq.~(\mref{eq:equivalent}) still holds. This means that $(S,\top,+)$ is a partial semigroup. But it is not a \weak locality semigroup, since for $(1,0)\in \top$ and $(0,1)\in \top$, $(1+0,1)=(1,1)\notin \top$ and $(1,0+1)=(1,1)\notin\top$, that is, $(S,\top,+)$ does not satisfy Eq.~(\mref{eq:wcomp}) in Definition~\mref{defn:wlocsg}. \mlabel{exam:psnsl} \end{exam} Let {\bf PSg} be the category of partial semigroups. Let {\bf LSg} be the category of locality semigroups, and let {\bf SLSg} be the category of \strong locality semigroups. Then by Example~\mref{exam:psnsl}, we have \begin{equation} {\bf SLSg} \subsetneq {\bf PSg}. \mlabel{eq:slps} \end{equation} By Proposition~\mref{prop:weak-loca} and Counterexample~\mref{coex:locsg-weaksg}, we obtain \begin{equation} {\bf SLSg} \subsetneq {\bf LSg}. \mlabel{eq:slls} \end{equation} Together with Eqs.~(\mref{eq:slps}) and (\mref{eq:slls}), we get $${\bf SLSg}\subseteq {\bf LSg}\cap {\bf PSg}.$$ Furthermore, we show that ${\bf SLSg}$ is a proper subclass of ${\bf LSg}\cap {\bf PSg}$. \begin{prop}With notations as above, we have $${\bf SLSg}\subsetneq {\bf LSg}\cap {\bf PSg}.$$ \end{prop} \begin{proof} According to Example~\mref{exam:PosIn}, we see that $(\N^+,\mtop_{cop}) $ is a locality semigroup. But it is not a \weak locality semigroup by Counterexample~\mref{coex:locsg-weaksg}. Next we prove that $(\N^+,\mtop_{cop}) $ is indeed a partial semigroup. For $a,b,c\in\N^+$, we let $(a,b)\in \mtop_{cop}$ and $(b,c)\in \mtop_{cop}$. We shall prove that $(ab,c)\in \mtop_{cop}$ if and only if $(a,bc)\in \mtop_{cop}$. Suppose first that $(ab,c)\in \mtop_{cop}$. Then there exist $s,t\in\Z$ such that \begin{equation}abs+ct=1 \mlabel{eq:coprm1} \end{equation} By $(a,b)\in \mtop_{cop}$, there exist $m,n\in\Z$ such that $am+bn=1$, and then multiplying by $ct$, we obtain $amct+bcnt=ct$. By Eq.~(\mref{eq:coprm1}), we get $a(mct+bs)+bcnt=1$. Thus $(a,bc)\in \mtop_{cop}$. Similarly, if $(a,bc)\in \mtop_{cop}$, we can prove $(ab,c)\in\mtop_{cop}$ by using $(b,c)\in\mtop_{cop}$. This means that $(\N^+,\mtop_{cop})$ satisfies Eq.~(\mref{eq:equivalent}), and so it is a partial semigroup. Thus $(\N^+,\mtop_{cop})\in {\bf LSg}\cap {\bf PSg}$, and $(\N^+,\mtop_{cop})\notin {\bf SLSg}$. Thus, \begin{equation} {\bf SLSg}\subsetneq {\bf LSg}\cap {\bf PSg}. \end{equation} \end{proof} We now explore the relationships between {\bf LSg} and {\bf PSg}. For example, \begin{exam} Let $S:=\{0,1\}$ and let $\top:=\{(0,0),(0,1),(1,0)\}$. A partial binary operation $\cdot:S\times_\top S\to S$ is given by $(0,0)\mapsto 0,\quad(0,1)\mapsto 0,\quad (1,0)\mapsto 1.$ Consider the case: $(1,0),(0,1)\in\top$. Then $(1\cdot 0,1)=(1,1)\notin \top$. But $(1,0\cdot 1)=(1,0)\in\top$. This means that $(S,\top,\cdot)$ does not satisfy Eq.~(\mref{eq:equivalent}) in Definition~\mref{defn:parsg}. Thus $(S,\top,\cdot)$ is not a partial semigroup. Next we prove that $(S,\top,\cdot)$ is a locality semigroup. Firstly, we verify that Eqs.~(\mref{eq:leftclosed}) and (\mref{eq:rightclosed}) hold for all subset $U$ of $S$. Three cases arise: $U=\{0\}, U=\{1\}$ and $U=\{0,1\}$. In the first case, $\lt=\{0,1\}=U^\top$, $(\lt\times \lt )\cap \top= \top$ and $0\cdot0=0\cdot 1=0\in\lt, 1\cdot 0=1\in \lt$. In the second case, $\lt=\{0\}=U^\top$, $(\lt\times \lt) \cap \top=\{(0,0)\}$ and $0\cdot 0=0\in\lt$. In the third case, $\lt=\{0\}=U^\top$, and this is similar to the second case. Thus, Eqs.~(\mref{eq:leftclosed}) and (\mref{eq:rightclosed}) hold. Secondly, there are four cases: $$(0,0),(0,0),(0,0)\in\top,\,(0,0),(0,1),(0,1)\in\top,$$ $$(0,1),(1,0),(0,0)\in\top, (1,0),(0,0),(1,0)\in \top, $$ satisfying the hypothesis: $(a,b),(b,c),(a,c)\in\top$ in Eq.~(\mref{eq:locass}) of Definition~\mref{defn:locsg}. Note that the case: $(1,0),(0,1)$, does not satisfy the hypothesis since $(1,1)\notin \top$. We finally check that the locality associative law holds for all cases. By the equations $0\cdot 0=0$, $0\cdot 1=0$ and $1\cdot 0=1$, the first two cases give $(0\cdot 0)\cdot 0=0=0\cdot (0\cdot 0)$ and $(0\cdot 0)\cdot 1=0=0\cdot (1\cdot 0)$. In the third case, $(0\cdot 1) \cdot 0=0=0\cdot (1\cdot 0)$. In the fourth case, $(1\cdot 0)\cdot 0=1=1\cdot (0\cdot 0)$. \mlabel{exam:lsg-psg} \end{exam} By Example~\mref{exam:lsg-psg}, we get \begin{equation} {\bf LSg} \nsubseteq {\bf PSg}. \end{equation} However, if a locality semigroup is transitive, then it is a partial semigroup. \begin{prop} Let $(S,\top)$ be a locality semigroup. If $(S,\top)$ is transitive, then $(S,\top)$ is a partial semigroup. \end{prop} \begin{proof} For all $a,b,c\in S$, if $(a,b),(b,c)\in \top$, then $(a,c)\in \top$ by transitivity of $\top$, and so $a,b\in \lts\{c\}$ and $b,c\in\{a\}^\top$. By Eqs.~(\mref{eq:leftclosed}) and (\mref{eq:rightclosed}), $(ab,c)\in \top$ and $(a,bc)\in \top$. Thus Eq.~(\mref{eq:equivalent}) holds, and $(ab)c=a(bc)$ by the locality associative law. \end{proof} We finally verify that {\bf LSg} also does not include {\bf PSg}, that is, \begin{equation} {\bf PSg} \nsubseteq{\bf LSg}. \end{equation} In order to prove the above statement, we take an example as follows. \begin{exam} Let $S:=\{a,b\}$ be a set. Let $\top:=S\times_\top S:=\{(a,a),(b,b)\}\subseteq S\times S$. Define a partial binary operation $\cdot:S\times_\top S \to S$ by defining $$(a,a)\mapsto a, (b,b)\mapsto a.$$ We first verify that $(S,\top)$ is a partial semigroup, that is, for every $(x,y),(y,z)\in \top$, we have $(xy,z)$ if and only if $(x,yz)\in\top$, and in that case $(xy)z=x(yz)$. Consider all possible cases: $(a,a),(a,a)\in \top$ and $(b,b),(b,b)\in \top$, having the property that $(x,y),(y,z)\in \top$. The first case gives $(aa,a)=(a,a)=(a,aa)$ and $(aa)a=a=a(aa)$. In the second case, $(bb,b)=(a,b)\notin\top $ and $(b,bb)=(b,a)\notin\top$, as desired. We now prove that $(S,\top)$ is not a locality semigroup. Take $U=\{b\}$. Then $\lt=\{b\}$ and $(\lt\times\lt) \cap\top=\{(b,b)\}$. By the equation $bb=a$ and $a\notin \lt$, we know that $(S,\top)$ does not satisfy Eq.~(\mref{eq:leftclosed}) in Definition~\mref{defn:locsg}. This means that $(S,\top,\cdot) \in {\bf PSG}$, but $(S,\top,\cdot)\notin {\bf LSg}$. \end{exam} Let {\bf RLSg} be the category of \fine locality semigroups. By the definition of \fine locality semigroups, every \fine locality semigroup is a \weak locality semigroup, but not vice versa. See Example~\mref{exam:str-fine} below. Thus, ${\bf RLSg}\subsetneq {\bf SLSg}$. Now let us put all the pieces together to give the main result of this section. \begin{theorem} With notations as above, we have \begin{equation*} {\bf RLSg}\subsetneq {\bf SLSg}\subsetneq {\bf LSg}\cap {\bf PSg}\quad\text{and}\quad{\bf LSg}\nsubseteq{\bf PSg}\nsubseteq {\bf LSg}. \end{equation*} \mlabel{thm:relation} \end{theorem} \section{Constructions of semigroups from \fine locality semigroups} \mlabel{sec:stro} In this section, we first describe how to obtain a partial semigroup from any given full semigroup. Let $S:=(S,\mu_S)$ be a semigroup. We can get a partial semigroup from $S$ by the following way. Let $A$ be a nonempty set of $S$. Denote $$\mtop_A:=A\times_\top A:=\{(a,b)\in A\times A\,|\,a b\in A\}.$$ Let $\mu_S|_{\mtop_A}$ be the restriction of $\mu_S$ to $\mtop_A$. Then we get a partial binary operation $\mu_S|_{\mtop_A}:A\times_\top A\to A,\,(a,b)\mapsto ab $. Thus, $(A,\mtop_A,\mu_S|_{\mtop_A})$ is a partial semigroup, since $(ab,c)\in \mtop_A$ if and only if $(a,bc)\in\mtop_A$ for $(a,b),(b,c)\in\mtop_A$. In particular, if $A$ is a subsemigroup of $S$, then $\mtop_A=A\times A$. This means that every subsemigroup is a partial semigroup. Now a natural question arises: \vspace{4pt} {\bf Question}\, How to construct a semigroup from any given partial semigroup? \vspace{4pt} By Theorem~\mref{thm:relation}, we see that every \fine locality semigroup is a special partial semigroup. Moreover, we can construct a full semigroup from any \fine locality semigroup as follows. \begin{theorem} Let $(S,\mtop_S,\cdot)$ be a \fine locality semigroup. Let $0\notin S$ and let $S^0:=S\cup \{0\}$. Define a binary operation $\ast:S^0\times S^0\to S^0$ by defining \begin{equation*} (x,y)\mapsto x\ast y:=\left\{\begin{array}{lll} x \cdot y, &(x,y)\in \mtop_S;\\ 0,&(x,y)\notin \mtop_S.\\ \end{array}\right. \end{equation*} Then $(S^0,\ast)$ is a semigroup with zero. \mlabel{thm:sgzero} \end{theorem} \begin{proof} We shall prove the associative law: for all $x,y,z\in S^0$, $(x\ast y)\ast z=x\ast (y\ast z)$. Two cases arise. \smallskip \noindent {\bf Case 1.} $(x,y)\in \mtop_S$. Then there are two subcases depending on whether or not $(y,z)\in \mtop_S $. If $(y,z)\in \mtop_S$, then $(x\cdot y,z),(x,y\cdot z)\in\mtop_S$ by Eq.~(\mref{eq:refinedremark}), and thus $(x\cdot y)\cdot z=x\cdot (y\cdot z)$ by Definition~\mref{defn:flocsg}(\mref{it:fineass}). By the definition of $\ast$, we obtain $$(x\ast y)\ast z=(x\cdot y)\cdot z=x\cdot(y\cdot z)=x\ast (y\ast z).$$ If $(y,z)\notin \mtop_S$, then $(x\cdot y,z)\notin \mtop_S$ by Definition~\mref{defn:flocsg}(\mref{it:fineone}), and so $(x\ast y)\ast z=0$. Hence, $$(x\ast y)\ast z=0=x\ast(y\ast z).$$ \smallskip \noindent {\bf Case 2.} $(x,y)\notin \mtop_S$. Then $x\ast y=0$, and so $(x\ast y)\ast z=0$. In order to prove the associative law, we also consider two subcases: $(y,z)\in \mtop_S $ and $(y,z)\notin \mtop_S$. If $(y,z)\in\mtop_S$, then $(x,y\cdot z)\notin \mtop_S$ by Definition~\mref{defn:flocsg}(\mref{it:finetwo}). This gives $$x\ast (y\ast z)=0=(x\ast y)\ast z.$$ If $(y,z)\notin \mtop_S$, then $y\ast z=0$, and thus $$x\ast (y\ast z)=0=(x\ast y)\ast z.$$ Then $(x\ast y)\ast z=x\ast (y\ast z)$ and $x\ast0=0 \ast x=0$ for all $x,y,z\in S^0$. It follows that $(S^0,\ast)$ is a semigroup with zero. \end{proof} \begin{remark} For any given partial semigroup $(S,\cdot,\mtop_S)$, it is not necessary to construct a semigroup by adding elements, such as, zero element, to it as follows. Firstly, let $0\notin S$ and let $S^0:=S\cup\{0\}$. Then we define a binary operation $\mu_{S^0}:S^0\times S^0\to S^0$ by defining $$(x,y)\mapsto\mu_{S^0}(x,y):=\left\{\begin{array}{lll} x\cdot y, &(x,y)\in \mtop_S;\\ 0,&(x,y)\notin \mtop_S.\\ \end{array}\right.$$ But $(S^0,\mu_{S^0})$ may not be a semigroup. \end{remark} The next example shows that it really not necessary to extend any partial semigroup $(S,\cdot,\mtop_S)$ to a full semigroup using the above method even if $(S,\cdot,\mtop_S)$ is a strong locality semigroup. \begin{exam} Let $S:=\{a,b\}$ be a set. Let $\top:=S\times_\top S:=\{(a,a),(a,b)\}\subseteq S\times S$. Define a partial binary operation $\cdot:S\times_\top S \to S$ by defining $$(a,a)\mapsto a, (a,b)\mapsto a.$$ We shall show that $(S,\top)$ is a strong locality semigroup, that is, for every $(x,y),(y,z)\in \top$, we have $(xy,z),(x,yz)\in\top$, and $(xy)z=x(yz)$. Consider all possible cases: $(a,a),(a,a)\in \top$ and $(a,a),(a,b)\in \top$. In the first case, since $aa=a$, we have $(aa,a),(a,aa)\in\top$, and hence $(aa)a=a(aa)$. In the second case, we obtain $(aa,b)=(a,b)\in\top$, $(a,ab)=(a,a)\in\top$ and $(aa)b=a=a(ab)$. It follows that $(S,\top,\cdot)$ is a strong locality semigroup. Secondly, we verify that $(S,\top,\cdot)$ is not a \fine locality semigroup. Since $(a,b)\in\top$ and $ab=a$, we have $(ab,a)=(a,a)\in\top$. But $(b,a)\notin\top$, and hence $(S,\top,\cdot)$ does not satisfy Definition~\mref{defn:flocsg}(\mref{it:fineone}) (that is, if $(x,y)\in\top$, then $(y,z)\in \top$ if and only if $(xy,z)\in\top$). Thus, $(S,\top,\cdot)$ is not a \fine locality semigroup. Finally, let $0\notin S$ and let $S^0:=S\cup\{0\}$. Define a binary operation $\mu_{S^0}:S^0\times S^0\to S^0$ by defining $$(x,y)\mapsto\mu_{S^0}(x,y):=\left\{\begin{array}{lll} x\cdot y, &(x,y)\in \top;\\ 0,&(x,y)\notin \top.\\ \end{array}\right.$$ Since $(ab)a=a\neq 0=a(ba)$, $(S^0,\mu_{S^0})$ is not a semigroup. \mlabel{exam:str-fine} \end{exam} According to Theorem~\mref{thm:sgzero}, we have \begin{prop}Let $(S,\mtop_S,\cdot)$ be a \fine locality semigroup. Let $(S^0,\ast)$ be the semigroup with zero defined in Theorem~\mref{thm:sgzero}. Then \begin{equation} xyz\neq0\Leftrightarrow xy\neq 0\,\,\text{and}\,\, yz\neq 0\quad\text{for all}\,\, x,y,z\in S^0. \end{equation} \mlabel{prop:stgpro} \end{prop} \begin{proof}$(\Rightarrow)$ is trivial. \\ $(\Leftarrow)$ By the hypothesis that $xy\neq 0$ and $yz\neq 0$, we get $(x,y),(y,z)\in\mtop_S$. Since $(S,\mtop_S,\cdot)$ is a \fine locality semigroup, we have $(xy,z),(x,yz)\in\mtop_S$. This gives $(xy)z,x(yz)\in S$, and thus $$xyz=(xy)z=x(yz)\neq 0.$$ \end{proof} \begin{defn}Let $S^0$ be a semigroup with zero. We say that $S^0$ is {\bf strong} if \begin{equation} abc\neq0\Leftrightarrow ab\neq 0\,\,\text{and}\,\, bc\neq 0\quad\text{for all}\,\, a,b,c\in S^0. \mlabel{eq:xyz} \end{equation} \mlabel{defn:strsgzero} \end{defn} Note that Eq.~(\mref{eq:xyz}) is equivalent to \begin{equation} abc=0\Leftrightarrow ab= 0\,\,\text{or}\,\, bc= 0\quad\text{for all}\,\, a,b,c\in S^0. \end{equation} \begin{prop}Let $(\calp,\mtop_\calp,\mu_\calp)$ be the path locality semigroup defined as in Proposition~\mref{prop:pathsg}. Let $0\notin \calp$ and let $\calp^0:=\calp\cup \{0\}$. Define a binary operation $\ast_\calp:\calp^0\times \calp^0\to \calp^0$ by defining \begin{equation*} (p,q)\mapsto p\ast_\calp q:=\left\{\begin{array}{lll} pq, &(p,q)\in \mtop_\calp;\\ 0,&(p,q)\notin \mtop_\calp.\\ \end{array}\right. \end{equation*} Then $(\calp^0,\ast_\calp)$ is a strong semigroup with zero, called a {\bf path semigroup with zero}, or simply a {\bf path semigroup}. \mlabel{prop:pathsgzero} \end{prop} \begin{proof} By Proposition~\mref{prop:pathresg}, we know that the path locality semigroup $(\calp,\mtop_\calp,\mu_\calp)$ is a \fine locality semigroup. Then by Theorem~\mref{thm:sgzero} and Proposition~\mref{prop:stgpro}, $(\calp^0,\ast_\calp)$ is a strong semigroup with zero. \end{proof} \smallskip \noindent {\bf Acknowledgements.} This work was supported by the National Natural Science Foundation of China (Grant No.~11601199) and the Foundation of Jiangxi Provincial Education Department (Grant No. GJJ160336).
\section{Introduction} A {\em morph} between two drawings of the same graph is a continuous transformation from one drawing to the other. Thus, any time instant of the morph defines a different drawing of the graph. Ideally, the morph should preserve the properties of the initial and final drawings throughout. As the most notable example, a morph between two planar graph drawings should guarantee that every intermediate drawing is also planar; if this happens, then the morph is called {\em planar}. Planar morphs have been studied for decades and find nowadays applications in animation, modeling, and computer graphics; see, e.g.,~\cite{fg-hmti-99,gs-gifm-pm}. A planar morph between any two topologically-equivalent\footnote[2]{Two planar drawings of a connected graph are \emph{topologically equivalent} if they define the same clockwise order of the edges around each vertex and the same outer face.} planar straight-line\footnote[3]{A \emph{straight-line drawing} $\Gamma$ of a graph $G$ maps vertices to points in a Euclidean space and edges to open straight-line segments between the images of their end-vertices. We denote by $\Gamma(v)$ (by $\Gamma(G')$) the image of a vertex $v$ (of a subgraph $G'$ of $G$, resp.).} drawings of the same planar graph always exists; this was proved for maximal planar graphs by Cairns~\cite{c-dplc-44} back in 1944, and then for all planar graphs by Thomassen~\cite{t-dpg-83} almost forty years later. Note that a planar morph between two planar graph drawings that are not topologically equivalent does not exist. It has lately been well investigated whether a planar morph between any two topologically-equivalent planar straight-line drawings of the same planar graph always exists such that the vertex trajectories have low complexity. This is usually formalized as follows. Let $\Gamma$ and $\Gamma'$ be two topologically-equivalent planar straight-line drawings of the same planar graph $G$. Then a morph $\mathcal M$ is a sequence $\langle \Gamma_1,\Gamma_2,\dots,\Gamma_k\rangle$ of planar straight-line drawings of $G$ such that $\Gamma_1=\Gamma$, $\Gamma_k=\Gamma'$, and $\langle \Gamma_i,\Gamma_{i+1}\rangle$ is a planar linear morph, for each $i=1,\dots,k-1$. A {\em linear morph} $\langle \Gamma_i,\Gamma_{i+1}\rangle$ is such that each vertex moves along a straight-line segment at uniform speed; that is, assuming that the morph happens between time $t=0$ and time $t=1$, the position of a vertex $v$ at any time $t\in[0,1]$ is $(1-t)\Gamma_i(v) + t\Gamma_{i+1}(v)$. The complexity of a morph $\mathcal M$ is then measured by the number of its {\em steps}, i.e., by the number of linear morphs it consists of. A recent sequence of papers~\cite{SODA-morph,Angelini-optimal-14,angelini2013morphing,Barrera-unidirectional} culminated in a proof~\cite{alamdari2017morph} that a planar morph between any two topologically-equivalent planar straight-line drawings of the same $n$-vertex planar graph can always be constructed consisting of $\Theta(n)$ steps. This bound is asymptotically optimal in the worst case, even for paths. The question we study in this paper is whether morphs with sub-linear complexity can be constructed if a third dimension is allowed to be used. That is: Given two topologically-equivalent planar straight-line drawings $\Gamma$ and $\Gamma'$ of the same $n$-vertex planar graph $G$ does a morph $\mathcal M=\langle \Gamma=\Gamma_1,\Gamma_2,\dots,\Gamma_k=\Gamma'\rangle$ exist such that: (i) for $i=1,\dots,k$, the drawing $\Gamma_i$ is a crossing-free straight-line 3D drawing of $G$, i.e., a straight-line drawing of $G$ in $\mathbb{R}^3$ such that no two edges cross; (ii) for $i=1,\dots,k-1$, the step $\langle \Gamma_i,\Gamma_{i+1}\rangle$ is a crossing-free linear morph, i.e., no two edges cross throughout the transformation; and (iii) $k=o(n)$? A morph $\mathcal M$ satisfying properties (i) and (ii) is a {\em crossing-free 3D morph}. Our main result is a positive answer to the above question for trees. Namely, we prove that, for any two planar straight-line drawings $\Gamma$ and $\Gamma'$ of an $n$-vertex tree $T$, there is a crossing-free 3D morph with $O(\log n)$ steps between $\Gamma$ and $\Gamma'$. More precisely the number of steps in the morph is linear in the \emph{pathwidth} of $T$. Notably, our morphing algorithm works even if $\Gamma$ and $\Gamma'$ are not topologically equivalent, hence the use of a third dimension overcomes another important limitation of planar two-dimensional morphs. Our algorithm morphs both $\Gamma$ and $\Gamma'$ to an intermediate suitably-defined {\em canonical 3D drawing}; in order to do that, a root-to-leaf path $H$ of $T$ is moved to a vertical line and then the subtrees of $T$ rooted at the children of the vertices in $H$ are moved around that vertical line, thus resembling a pole dance, from which the title of the paper comes. We also look at whether our result can be generalized to morphs of crossing-free straight-line 3D drawings of trees. That is, the drawings $\Gamma$ and $\Gamma'$ now live in $\mathbb{R}^3$, and the question is again whether a crossing-free 3D morph between $\Gamma$ and $\Gamma'$ exists with $o(n)$ steps. We prove that this is not the case: Two crossing-free straight-line 3D drawings of a path might require $\Omega(n)$ steps to be morphed one into the other. The matching upper bound can always be achieved: For any two crossing-free straight-line 3D drawings $\Gamma$ and $\Gamma'$ of the same $n$-vertex tree $T$ there is a crossing-free 3D morph between $\Gamma$ and $\Gamma'$ with $O(n)$ steps. The rest of the paper is organized as follows. In Sect.~\ref{sec:3dtrees} we deal with crossing-free 3D morphs of 3D tree drawings. In Sect.~\ref{sec:morphing-paths} we show how to construct $2$-step crossing-free 3D morphs between planar straight-line drawings of a path. In Sect.~\ref{sec:morphing-trees} we present our main result about crossing-free 3D morphs of planar tree drawings. Finally, in Sect.~\ref{sec:conclusions} we conclude and present some open problems. Because of space limitations, some proofs are omitted or just sketched; they can be found in the full version of the paper. \section{Morphs of 3D drawings of trees} \label{sec:3dtrees} In this section we give a tight $\Theta(n)$ bound on the number of steps in a crossing-free 3D morph between two crossing-free straight-line 3D tree drawings. \begin{theorem} \label{th:upper-bound-3d} For any two crossing-free straight-line 3D drawings $\Gamma$, $\Gamma'$ of an $n$-vertex tree $T$, there exists a crossing-free 3D morph from $\Gamma$ to $\Gamma'$ that consists of $O(n)$ steps. \end{theorem} \begin{proof}[sketch] The proof is by induction on $n$. The base case, in which $n=1$, is trivial. If $n>1$, then we remove a leaf $v$ and its incident edge $uv$ from $T$, $\Gamma$, and $\Gamma'$. This results in an $(n-1)$-vertex tree $T'$ and two drawings $\Delta$ and $\Delta'$ of it. By induction, there is a crossing-free 3D morph between $\Delta$ and $\Delta'$. We introduce $v$ in such a morph so that it is arbitrarily close to $u$ throughout the transformation; this significantly helps to avoid crossings in the morph. The number of steps is the one of the recursively constructed morph plus one initial step to bring $v$ close to $u$, plus two final steps to bring $v$ to its final position.\qed \end{proof} \begin{figure}[tb] \begin{minipage}{0.49\textwidth} \centering \includegraphics[scale = 0.6]{TwoLinks-1.pdf} (a) \end{minipage} \begin{minipage}{0.49\textwidth} \centering \includegraphics[scale = 0.6,page=2]{TwoLinks-1.pdf} (b) \end{minipage} \caption{Illustration for the proof of Theorem~\ref{thm:lower-bound-3d}: (a) The drawing $\Gamma$ of $P$, with $n=26$; (b) the link obtained from $\Gamma$; the invisible edges are dashed. } \label{fig:lower-bound-3d} \end{figure} \begin{theorem} \label{thm:lower-bound-3d} There exist two crossing-free straight-line 3D drawings $\Gamma, \Gamma'$ of an $n$-vertex path $P$ such that any crossing-free 3D morph from $\Gamma$ to $\Gamma'$ consists of $\Omega(n)$ steps. \end{theorem} Before proving Theorem~\ref{thm:lower-bound-3d}, we review some definitions and facts from knot theory; refer, e.g., to the book by Adams~\cite{adams2004knot}. A \emph{knot} is an embedding of a circle $S^{1}$ in $\mathbb{R}^3$. A {\em link} is a collection of knots which do not intersect, but which may be linked together. For links of two knots, the (absolute value of the) {\em linking number} is an invariant that classifies links with respect to ambient isotopies. Intuitively, the linking number is the number of times that each knot winds around the other. The linking number is known to be invariant with respect to different projections of the same link~\cite{adams2004knot}. Given a projection of the link, the linking number can be determined by orienting the two knots of the link, and for every crossing between the two knots in the projection adding $+1$ or $-1$ if rotating the understrand respectively clockwise or counterclockwise lines it up with the overstrand (taking into account the direction). \begin{proof}[Theorem~\ref{thm:lower-bound-3d}] The drawing $\Gamma$ of $P$ is defined as follows. Embed the first $\lfloor n/2 \rfloor$ edges of $P$ in 3D as a spiral of monotonically decreasing height. Embed the rest of $P$ as a same type of spiral affinely transformed so that it goes around one of the sides of the former spiral. See Figure~\ref{fig:lower-bound-3d}a. The drawing $\Gamma'$ places the vertices of $P$ in order along the unit parabola in the plane $y = 0$. Cut the edge joining the two spirals (the bold edge in Figure~\ref{fig:lower-bound-3d}a). Removing an edge makes morphing easier so any lower bound would still apply. Now close the two open curves using two \emph{invisible} edges to obtain a \emph{link} of two knots; see Figure~\ref{fig:lower-bound-3d}b. It is easy to verify that the (absolute value of the) linking number of this link is $\Omega(n^2)$: indeed, determining it by the above procedure for the projection given by Figure~\ref{fig:lower-bound-3d} results in the linking number being equal to the number of crossings between the two links in this projection. In the drawing $\Gamma'$, each of the two halves of $P$ (and their invisible edges) are separated by a plane and so their linking number is $0$. In a valid linear morph, the edges of $P$ cannot cross each other, but they can cross invisible edges. However, during a linear morph between two straight-line 3D drawings of a graph $G$ any two non-adjacent edges of $G$ intersect $O(1)$ times. Thus each invisible edge can only be crossed $O(n)$ times during a linear morph. A single crossing can only change the linking number by 1. Therefore the linking number can only decrease by $O(n)$ in a single linear morph. \qed \end{proof} \section{Morphing two planar drawings of a path in 3D}\label{sec:morphing-paths} In this section we show how to morph two planar straight-line drawings $\Gamma$ and $\Gamma'$ of an $n$-vertex path $P:=(v_0,\dots v_{n-1})$ into each other in two steps. The \emph{canonical 3D drawing} of $P$, denoted by $\canon{P}$, is the crossing-free straight-line 3D drawing of $P$ that maps each vertex $v_i$ to the point $(0,0,i) \in \mathbb{R}^3$, as shown in Figure~\ref{fig:canonical-path}. We now prove the following. \begin{figure}[tb] \centering \includegraphics[scale=.6]{canonical} \caption{(a) A straight-line planar drawing $\Gamma$ of an $n$-vertex path $P$ and (b) a morph from $\Gamma$ to $\canon{P}$. The vertex trajectories are represented by dotted lines.} \label{fig:canonical-path} \end{figure} \begin{theorem} \label{thm:path} For any two planar straight-line drawings $\Gamma$ and $\Gamma'$ of an $n$-vertex path $P$, there exists a crossing-free 3D morph $\mathcal{M}=\langle \Gamma,\canon{P},\Gamma' \rangle$ with 2 steps. \end{theorem} \begin{proof} It suffices to prove that the linear morph $\langle \Gamma,\canon{P}\rangle$ is crossing-free, since the morph $\langle \canon{P},\Gamma'\rangle$ is just the morph $\langle\Gamma',\canon{P}\rangle$ played backwards. Since $\langle \Gamma,\canon{P}\rangle$ is linear, the speed at which the vertices of $P$ move is uniform (though it might be different for different vertices). Thus the speed at which their projections on the $z$-axis move is uniform as well. Since $v_i$ moves uniformly from $(x_i,y_i,0)$ to $(0,0,i)$, at any time during the motion (except at the time $t=0$) we have $z(v_0) < z(v_1) < \ldots < z(v_{n-1})$. Therefore, in any intermediate drawing any edge $(v_i,v_{i+1})$ is separated from any other edge by the horizontal plane through one of its end-points. Hence no crossing happens during $\langle \Gamma,\canon{P}\rangle$. \qed \end{proof} \section{Morphing two planar drawings of a tree in 3D} \label{sec:morphing-trees} Let $T$ be a tree with $n$ vertices, arbitrarily rooted at any vertex. In this section we show that any two planar straight-line drawings of $T$ can be morphed into one another by a crossing-free 3D morph with $O(\log n)$ steps (Theorem~\ref{thm:morph-trees}). Similarly to Section~\ref{sec:morphing-paths}, we first define a canonical 3D drawing $\canon{T}$ of $T$ (see Section~\ref{sec:canonical-tree}), and then show how to construct a crossing-free 3D morph from any planar straight-line drawing of $T$ to $\canon{T}$. We describe the morphing procedure in Section~\ref{sec:morph-tree}; then in Section~\ref{subsec:space} we present a procedure \needspace{ } that carries out the computations required by the morphing procedure; finally, in Section~\ref{subsec:morph-analysis} we analyze the correctness and efficiency of both procedures. Before proceeding, we introduce some necessary definitions and notation. By a {\em cone} we mean a straight circular cone induced by a ray rotated around a fixed vertical line (the {\em axis}) while keeping its origin fixed at a point (the {\em apex}) on this line. The {\em slope} $\slope{C}$ of a cone $C$, is the slope of the generating ray as determined in the vertical plane containing the ray. By a {\em cylinder} we always mean a straight cylinder having a horizontal circle as a base. Such cones or cylinders are uniquely determined, up to translations, respectively by their apex and slope or by their height and radius. For a tree $T$, let $T(v)$ denote the subtree of $T$ rooted at its vertex $v$. Also let $|T|$ denote the number of vertices in $T$. The {\em heavy-path decomposition}~\cite{sleator1981data} of a tree $T$ is defined as follows. For each non-leaf vertex $v$ of $T$, let $w$ be the child of $v$ in $T$ such that $|T(w)|$ is maximum (in case of a tie, we choose the child arbitrarily). Then $(v,w)$ is a {\em heavy edge}; further, each child $z$ of $v$ different from $w$ is a \emph{light child} of $v$, and the edge $(v,w)$ is a {\em light edge}. Connected components of heavy edges form paths, called \emph{heavy paths}, which may have many incident light edges. Each path has a vertex, called the \emph{head}, that is the closest vertex to the root of $T$. See Figure~\ref{fig:heavy-path-cactus} for an example. A \emph{path tree} of $T$ is a tree whose vertices correspond to heavy paths in $T$. The parent of a heavy path $P$ in the path tree is the heavy path that contains the parent of the head of $P$. The root of the path tree is the heavy path containing the root of $T$. It is well-known~\cite{sleator1981data} that the height of the path tree is $O(\log{n})$. We denote by $H(T)$ the root of the path tree of $T$; let $v_0, \ldots, v_{k-1}$ be the ordered sequence of the vertices of $H(T)$, where $v_0$ is the root of $T$. For $i=0,\dots,k-1$, we let $v_i^0, \ldots, v_i^{t_i}$ be the light children of $v_i$ in any order. Let $L(T) = u_0, u_1, \ldots, u_{l-1}$ be the sequence of the light children of $H(T)$ ordered so that: (i) any light child of a vertex $v_j$ precedes any light child of a vertex $v_i$, if $i < j$; and (ii) the light child $v_i^{j+1}$ of a vertex $v_i$ precedes the light child $v_i^j$ of $v_i$. When there is no ambiguity we refer to $H(T)$ and $L(T)$ simply as $H$ and $L$, respectively. \begin{figure}[tb] \centering \includegraphics[scale = 0.7]{heavy-path.pdf} \caption{(a) A tree $T$; (left) its heavy edges (bold lines) forming the heavy paths $H=H(T),H_0, \ldots, H_4$, and (right) the path tree of $T$; (b) $\canon{T}$ for the tree $T$ in (a). } \label{fig:heavy-path-cactus} \end{figure} \subsection{Canonical 3D drawing of a tree} \label{sec:canonical-tree} We define the {\em canonical 3D drawing} $\canon{T}$ of a tree $T$ as a straight-line 3D drawing of $T$ that maps each vertex $v$ of $T$ to its {\em canonical position} $\canon{v}$ defined as follows (see Figure~\ref{fig:heavy-path-cactus}b). Note that our canonical drawing is equivalent to the \emph{``standard''} straight-line upward drawing of a tree~\cite{therese,chan2018tree,crescenzi1992note}. First, we set $\canon{v_0} = (0,0,0)$ for the root $v_0$ of $T$. Second, for each $i=1,\dots,k-1$, we set $\canon{v_i} = (0,0, z_{i-1} + |T(v_{i-1})|-|T(v_i)|)$, where $z_{i-1}$ is the $z$-coordinate of $\canon{v_{i-1}}$. Third, for each $i=1,\dots,k-1$ and for each light child $v_i^j$ of $v_i$, we determine $\canon{v_i^j}$ as follows. If $j = 0$, we set $\canon{v_i^j} = (1,0,1+z_i)$, where $z_i$ is the $z$-coordinate of $\canon{v_i}$; otherwise, we set $\canon{v_i^j} = (1,0,z^{j-1}_i+|T(v_i^{j-1})|)$, where $z^{j-1}_i$ is the $z$-coordinate of $\canon{v^{j-1}_i}$. Finally, in order to determine the canonical positions of the vertices in $T(v_i^j) \setminus \{v_i^j\}$, we recursively construct the canonical 3D drawing $\canon{T(v_i^j)}$ of ${T(v_i^j)}$, and translate all the vertices by the same vector so that $v_i^j$ is sent to $\canon{v_i^j}$. \begin{Remark} Notice that the canonical position $\canon{v}$ of any vertex $v$ of $T$ is $({\emph{dpt}}(v), 0, {\emph{dfs}}(v))$. Here ${\emph{dpt}}(v)$ is the depth, in the path tree of $T$, of the node that corresponds to the heavy path of $T$ that contains $v$; and ${\emph{dfs}}(v)$ is the position of $v$ in a depth-first search on $T$ in which the children of any vertex are visited as follows: first visit the light children in reverse order with respect to $L$, and then visit the child incident to the heavy edge. \end{Remark} The following lemma is a direct consequence of the construction of $\canon{T}$. \begin{lemma} \label{lemma:canon-tree} The canonical 3D drawing $\canon{T}$ of $T$ lies on a rectangular grid in the plane $y=0$, where the grid has height $n$ and width equal to the height $h=O(\log{n})$ of the path tree of $T$. Moreover, $\canon{T}$ is on or above the line $z = x$. \end{lemma} \begin{Remark} \label{rem:therese} In the above definition of the canonical 3D drawing $\canon{T}$, instead of the heavy-path decomposition of $T$, we can use the decomposition based on the \emph{Strahler number} of $T$, see~\cite{therese} where the Strahler number is used under the name \emph{rooted pathwidth} of $T$. With this change, the width of $\canon{T}$ will be equal to the Strahler number of $T$, which is the instance-optimal width of an upward drawing of a tree~\cite{therese}. Moreover, since the Strahler number is linear in the \emph{pathwidth} of $T$, so is the width of $\canon{T}$ defined this way. This is clearly not worse, and, for some instances, much better than the width given by the heavy-path decomposition. \end{Remark} In the below description of the morph we use heavy paths, however we can use the paths given by Remark~\ref{rem:therese} instead, without any modification. \subsection{The procedure {\em Canonize($\Gamma$)}} \label{sec:morph-tree} Let $\Gamma = \Gamma({T})$ be a planar straight-line drawing of a tree $T$. Below we give a recursive procedure \canonize{\Gamma} that constructs a crossing-free 3D morph from $\Gamma$ to the canonical 3D drawing $\canon{T}$. We assume that $\Gamma$ is enclosed in a disk of diameter $1$ centered at $(0,0,0)$ in the plane $z=0$, and that the root $v_0$ of ${T}$ is placed at $(0,0,0)$ in $\Gamma$. This is not a loss of generality, up to a suitable modification of the reference system. \paragraph{Step 1 (set the pole).} The first step of the procedure \canonize{\Gamma} aims to construct a linear morph $\langle \Gamma,\Gamma_1\rangle$, where $\Gamma_1$ is such that the heavy path $H=(v_0,\dots,v_{k-1})$ of $T$ lies on the vertical line through $\Gamma(v_0)$ and the subtrees of $T$ rooted at the light children of each vertex $v_i$ lie on the horizontal plane through~$v_i$. More precisely, the vertices of $T$ are placed in $\Gamma_1$ as follows. For $i=0,\dots,{k-1}$, place $v_i$ at the point $\canon{v_i}$. Every vertex that belongs to a subtree rooted at a light child of $v_i$ is placed at a point such that its trajectory in the morph defines the same vector as the trajectory of $v_i$.\footnote{Since the morph $\langle \Gamma,\Gamma_1\rangle$ is linear, the trajectory of any vertex $v$ is simply the line segment connecting the positions of $v$ in $\Gamma$ and in $\Gamma_1$. To define a vector, we orient the segment towards the position of $v$ in $\Gamma_1$.} Below we refer to $\Gamma_1(H)$ as the \emph{pole}. The pole will remain still throughout the rest of the morph. \paragraph{Step 2 (lift).} The aim of the second step of the procedure \canonize{\Gamma} is to construct a linear morph $\langle \Gamma_1,\Gamma_2\rangle$, where $\Gamma_2$ is such that the drawings of any two subtrees $T(u_i)$ and $T(u_j)$ rooted at different light children $u_i$ and $u_j$ of vertices in $H$ are vertically and horizontally separated. The separation between $\Gamma_2(T(u_i))$ and $\Gamma_2(T(u_j))$ is set to be large enough so that the recursively computed morphs \canonize{\Gamma_2(T(u_i))} and \canonize{\Gamma_2(T(u_j))} do not interfere with each other. We describe how to construct $\Gamma_2$. As anticipated, $\Gamma_2(v_i)=\Gamma_1(v_i)$, for each vertex $v_i$ in $H$. In order to determine the placement of the vertices not in $H$ we use $l$ cones \innerCone{u_0}, \ldots,\innerCone{u_{l-1}} and $l$ cones \outerCone{u_0}, \ldots,\outerCone{u_{l-1}}, namely one cone \innerCone{u_t} and one cone \outerCone{u_t} per vertex $u_t$ in $L$. We also use, for each $u_t$, a cylinder \needspace{\Gamma_2(T(u_t))} that bounds the volume used by \canonize{\Gamma_2(T(u_t))}. We defer the computation of these cones and cylinders to Section~\ref{subsec:space}, and for now assume that they are already available. For each $t=0,\dots,l-1$ and for each $j=0,\dots,t-1$, assume that $\Gamma_2(T(u_j))$ has been computed already -- this is indeed the case when $t=0$. Let $\mathcal{P}_t$ be the horizontal plane $z=|T|-1 + \sum_{j = 0}^{t-1}{h(u_j)}$, where $h(u_j)$ is the height of the cylinder \needspace{\Gamma_2(T(u_j))}. The drawing $\Gamma_2$ maps the subtree $T(u_t)$ to the plane $\mathcal{P}_t$, just outside the cone \innerCone{u_t} and just inside the cone \outerCone{u_t}. See Figure~\ref{fig:cones}. We proceed with the formal definition of $\Gamma_2$. Let $v$ be any vertex of $T(u_t)$ and let $(v_x, v_y, v_z)$ be the coordinates of $\Gamma_1(v)$. Then $\Gamma_2(v)$ is the point $(v_x\frac{r_t}{r}, v_y\frac{r_t}{r}, z_t)$. Here $z_t$ is the height of the plane $\mathcal{P}_t$, $r_t$ is the radius of the section of \innerCone{u_t} by the plane $\mathcal{P}_t$, and $r$ is the distance from $\Gamma_1(v_i)$ to its closest point of the drawing $\Gamma_1(T(u_t))$, where $v_i$ is the parent of $u_t$. See Figure~\ref{fig:cones}. Note that the latter closest point can be a point on an edge. \begin{figure} \centering \includegraphics[scale=0.9]{Cones1} \caption{The vertices $v_0, v_1, v_2, v_3, v_4$ are in the heavy path $H$ of $T$. The lower gray disk has its center at $v_1$ and has radius equal to the distance from $\Gamma_1(v_i)$ to its closest point in $\Gamma_1(T(u_1))$. Blue arrows show the mapping of vertices in subtrees $T(u_0)$ and $T(u_1)$.} \label{fig:cones} \end{figure} \paragraph{Step 3 (recurse).} For each $u_{t} \in L$, we make a recursive call \canonize{\Gamma_2(T(u_t))}. The resulting morphs are combined into a unique morph $\langle \Gamma_2,\dots,\Gamma_3\rangle$, whose number of steps is equal to the maximum number of steps in any of the recursively computed morphs. Indeed, the first step of $\langle \Gamma_2,\dots,\Gamma_3\rangle$ consists of the first steps of all the recursively computed morphs that have at least one step; the second step of $\langle \Gamma_2,\dots,\Gamma_3\rangle$ consists of the second steps of all the $t$ recursively computed morphs that have at least two steps; and so on. \paragraph{Step 4 (rotate, rotate, rotate).} The next morph transforms $\Gamma_3$ into a drawing $\Gamma_4$ such that each vertex $u_t\in L$ is mapped to the intersection of the cone \innerCone{u_t}, the planes $y=0$, $\mathcal{P}_t$, and the half-space $x>0$. Note that going from $\Gamma_3$ to $\Gamma_4$ in one linear crossing-free 3D morph is not always possible. Refer to Lemma~\ref{lemma:rotations} for the implementation of the morph from $\Gamma_3$ to $\Gamma_4$ in $O(1)$ steps. After Step 4 the whole drawing lies on the plane $y=0$. \paragraph{Step 5 (go down).} This step consists of a single linear morph $\langle \Gamma_4,\Gamma_5\rangle$, where $\Gamma_5$ is defined as follows. For every vertex $v_i$ in $H$, $\Gamma_5(v_i)=\Gamma_4(v_i)$; further, for every vertex $u_t \in L$, all the vertices of $T(u_t)$ have the same $x$- and $y$-coordinates in $\Gamma_5$ as in $\Gamma_4$, however their $z$-coordinate is decreased by the same amount so that $u_t$ lies on the horizontal plane through $\canon{u_t}$. \paragraph{Step 6 (go left).} The final part of our morphing procedure consists of a single linear morph $\langle \Gamma_5,\Gamma_6\rangle$, where $\Gamma_6$ is the canonical 3D drawing $\canon{T}$ of $T$. Note that this linear morph only moves the vertices horizontally. \subsection{The procedure {\em Space($\Gamma$)}} \label{subsec:space} In this section we give a procedure to compute the cylinders and the cones which are necessary for Steps 2 and 4 of the procedure \canonize{\Gamma}. We fix a constant $c \in \mathbb{R}$ with $c>1$, which we consider global to the procedure \canonize{\Gamma} and its recursive calls; below we refer to $c$ as the \emph{global constant}. The global constant $c$ will help us to define the cones so that Step~4 of \canonize{\Gamma} can be realized with $O(1)$ linear morphs, see Lemma~\ref{lemma:rotations}. The procedure \needspace{\Gamma} returns a cylinder that encloses all the intermediate drawings of the morph determined by \canonize{\Gamma}. At the same time, \needspace{\Gamma} determines the cones \innerCone{u_t} and \outerCone{u_t} for every vertex $u_t\in L$. We now describe \needspace{\Gamma}. Let $\Gamma_1$ be the result of the application of Step 1 of \canonize{\Gamma}. Figure~\ref{fig:space-procedure} illustrates our description. If $T$ is a path, i.e., $T = H$, return the cylinder of height $|T|-1$ and radius~$1$. In particular, if $T$ is a single vertex, return the disk of radius 1. Otherwise, construct the cylinder and the cones in the following fashion: \begin{itemize} \item Set the current cone $C$ to be an infinite cone of slope 1. The apex of $C$ is determined as follows: starting with the apex being at the highest point of the pole, slide $C$ vertically downwards until it touches the drawing $\Gamma_1(T(u_0))$. That is, the apex of $C$ is at the lowest possible position on the pole such that the whole drawing $\Gamma_1(T(u_0))$ is outside of $C$. See Figure~\ref{fig:space-procedure}a. \item Set the current height $h$ to be $|T|-1$. \item Iterate through the light children of $H$ in the order as they appear in $L$. For every $u_t$ in $L$: \begin{itemize} \item Set \innerCone{u_t} to be the current cone $C$. \item Add the height of \needspace{\Gamma_2(T(u_t))} to the current height $h$. \item Let $C'$ be the cone with the same apex as $C$ and with a slope defined so that the drawing $\Gamma_1(T(u_t))$ is in-between $C$ and $C'$, and $C$ is \emph{well-separated} from $C'$ with the global constant $c$. That is, $\slope{C'} = \min{(\slope{C}/\spread{u_t, \Gamma_1}, \slope{C}/c)}$, where $\spread{u_t, \Gamma_1}$ is the spread of the drawing $\Gamma_1(T(u_t))$ with respect to the parent $v_i$ of $u_t$ in $H$. Namely $\spread{u_t, \Gamma_1}$ is the ratio between the outer and the inner radius of the minimum annulus centered at $v_i$ and enclosing the drawing $\Gamma_1(T(u_t))$. See Figure~\ref{fig:space-procedure}a. \item Let $\mathcal{S}_t$ be the cylinder \needspace{\Gamma_2(T(u_t))} translated so that the center of its lower base is at the point $\Gamma_2(u_t)$. \item Decrease $\slope{C'}$ so that $C'$ encloses the entire cylinder $\mathcal{S}_t$. \item Set \outerCone{u_t} to be the cone $C'$. \item If $u_t$ is not the last element of $L$ (i.e., $t < l-1$), then let $u_t = v_i^j$ and define an auxiliary cone $\tilde{C}$ as follows. The apex of $\tilde{C}$ is at $\Gamma_1({v_x})$ where $v_x$ is the parent of $u_{t+1}$; note that $v_x=v_i$ iff $j>0$. The slope of $\tilde{C}$ is the maximum slope that satisfies the following requirement: (i) the slope of $\tilde{C}$ is at most the slope of $C'$. In addition, only for the case when $v_x = v_i$, we require: (ii) in the closed half space $z \leq h$, the portion of $\tilde{C}$ encloses the portion of $C'$. See Figure~\ref{fig:space-procedure}b. Update the cone $C$ to be the lowest vertical translate of $\tilde{C}$ so that $\Gamma_1(T(u_{t+1}))$ is still outside the cone. \end{itemize} \item Return the cylinder of height $h$ (the current height), and radius equal to the radius of the section of the current cone $C$ cut by the plane $z=h$. \end{itemize} \subsection{Correctness of the morphing procedure } \label{subsec:morph-analysis} In this section, we analyze the correctness and the efficiency of the procedure \canonize{\Gamma} (see Theorem~\ref{thm:morph-trees}) and we give the details of Step~4 (see Lemma~\ref{lemma:rotations}). \begin{figure}[htb] \begin{minipage}{0.49\linewidth} \centering \includegraphics[scale=0.9]{Cones} \\ (a) \end{minipage} \hfill \begin{minipage}{0.49\linewidth} \centering \includegraphics[scale=0.9]{Space} \\ (b) \end{minipage} \caption{Illustration for \needspace{\Gamma}: (a) construction of $C$ and $C'$; (b) construction of $\tilde{C}$.} \label{fig:space-procedure} \end{figure} \begin{figure} \centering \includegraphics[scale=0.9]{Annulus} \caption{(a) Annuli for the subtrees rooted at $u_0$ and $u_1$; (b) top view of the annuli.} \label{fig:annuli} \end{figure} \begin{lemma} \label{lemma:rotations} Step 4 of the procedure \canonize{\Gamma} can be realized as a crossing-free 3D morph whose number of steps is bounded from above by a constant that depends on the global constant $c$. \end{lemma} \begin{proof} Let \annulus{t} be the annulus formed by the section of \innerCone{u_t} and \outerCone{u_t} cut by the plane $\mathcal{P}_t$. See Figure~\ref{fig:annuli}. The morph performed in Step~4 consists of a sequence of linear morphs; in each of these morphs all the vertices of $T(u_t)$ are translated by the same vector. This is done so that $u_t$ stays in \annulus{t} during the whole Step 4. Thus, the trajectory of $u_t$ during Step~4 defines a polygon inscribed in \annulus{t}. Since the ratio between the outer and the inner radius of \annulus{t} is at least the global constant $c$, we can inscribe a regular $O(1)$-gon in \annulus{t}, and the trajectory of $u_t$ can be defined so that it follows this $O(1)$-gon plus at most one extra line segment. We now prove that since each $u_t \in L$ stays in \annulus{t}, all the steps of the above morph are crossing-free. Recall that at any moment during the morph, the drawing of $T(u_t)$ is a translation of the canonical 3D drawing $\canon{T(u_t)}$. By Lemma~\ref{lemma:canon-tree}, the space below the line of slope 1 passing through $u_t$ in plane $y=0$ does not contain any point of $\canon{T(u_t)}$. Since the slope of \outerCone{u_t} is at most 1, the drawing of $T(u_t)$ is enclosed in \outerCone{u_t} as long as $u_t$ is in \annulus{t}. By conditions ($i$) and ($ii$) of \needspace{\Gamma}, the cone \innerCone{u_{t+1}} encloses \outerCone{u_t} in the closed half-space above $\mathcal{P}_t$. Hence the edge connecting $u_{t+1}$ to the pole never touches \outerCone{u_t} above $\mathcal{P}_t$. \qed \end{proof} \begin{theorem} \label{thm:morph-trees} For any two plane straight-line drawings $\Gamma, \Gamma'$ of an $n$-vertex tree $T$, there exists a crossing-free 3D morph from $\Gamma$ to $\Gamma'$ with $O(\log n)$ steps. \end{theorem} \begin{proof}[sketch] A 3D morph from $\Gamma$ to $\Gamma'$ can be constructed as the concatenation of \canonize{\Gamma} with the reverse of \canonize{\Gamma'}. Hence, it suffices to prove that \canonize{\Gamma} is a crossing-free 3D morph with $O(\log n)$ steps. It is easy to see that Steps 1, 5, and 6 of \canonize{\Gamma} are crossing-free linear morphs. The proof that Step 2 is a crossing-free linear morph is more involved. In particular, for any two light children $u_s$ and $u_t$ with $s<t$ of the same vertex $v_i$ of $H$, the occurrence of a crossing between the edge $v_iu_s$ and an edge of $T(u_t)$ during Step 2 can be ruled out by arguing that the same two edges would also cross in $\Gamma_1$; this argument exploits the uniformity of the speed in a linear morph and that the horizontal component of the morph of Step~2 is a uniform scaling. Lemma~\ref{lemma:rotations} ensures that Step~4 is a crossing-free 3D morph with $O(1)$ steps. Thus, Steps 1, 2, 4, 5, and 6 require a total of $O(1)$ steps. Since the number of morphing steps of Step~3 of \canonize{\Gamma} is equal to the maximum number of steps of any recursively computed morph and since, by definition of heavy path, each tree $T(u_t)$ for which a recursive call \canonize{\Gamma_2(T(u_t))} is made has at most $n/2$ vertices, it follows that \canonize{\Gamma} requires $O(\log n)$ steps. \qed \end{proof} \section{Conclusions and Open Problems} \label{sec:conclusions} In this paper we studied crossing-free 3D morphs of tree drawings. We proved that, for any two planar straight-line drawings of the same $n$-vertex tree, there is a crossing-free 3D morph between them which consists of $O(\log n)$ steps. This result gives rise to two natural questions. First, is it possible to bring our logarithmic upper bound down to constant? In this paper we gave a positive answer to this question for paths. In fact our algorithm to morph planar straight-line tree drawings has a number of steps which is linear in the pathwidth of the tree (see Remark~\ref{rem:therese}), thus for example it is constant for caterpillars. Second, does a crossing-free 3D morph exist with $o(n)$ steps for any two planar straight-line drawings of the same $n$-vertex planar graph? The question is interesting to us even for subclasses of planar graphs, like outerplanar graphs and planar $3$-trees. We also proved that any two crossing-free straight-line 3D drawings of an $n$-vertex tree can be morphed into each other in $O(n)$ steps; such a bound is asymptotically optimal in the worst case. An easy extension of our results to graphs containing cycles seems unlikely. Indeed, the existence of a deterministic algorithm to construct a crossing-free 3D morph with a polynomial number of steps between two crossing-free straight-line 3D drawings of a cycle would imply that the unknot recognition problem is polynomial-time solvable. The {\em unknot recognition} problem asks whether a given knot is equivalent to a circle in the plane under an ambient isotopy. This problem has been the subject of investigation for decades; it is known to be in NP~\cite{hlp-ccklp-99} and in co-NP~\cite{l-ecktn-16}, however determining whether it is in P has been an elusive goal so far. \subsubsection*{Acknowledgments} We thank Therese Biedl for pointing out Remark~\ref{rem:therese}. \\ The research for this paper started during the Intensive Research Program in Discrete, Combinatorial and Computational Geometry, which took place in Barcelona, April-June 2018. We thank Vera Sacrist\'an and Rodrigo Silveira for a wonderful organization and all the participants for interesting discussions. \\ \bibliographystyle{plain}
\part*{Introduction} In this article we generalise the work of P. Maisonobe in \cite{Maisonobe} on morphisms \emph{without slopes} for $\mathscr{D}$-modules to the category of mixed Hodge modules of M. Saito. \section*{Morphisms without slope} The classical example of Lê shows that in general, for a morphism $\boldsymbol{f}:\mathbb{C}^n\to\mathbb{C}^p$ with $p\geq 2$, there is no Milnor fibration: \[\begin{array}{ccccc} \boldsymbol{f} & : & (\mathbb{C}^3,0) & \to & (\mathbb{C}^2,0) \\ && (x,y,z) & \mapsto & (x^2-y^2z,y). \end{array} \] Indeed it can be shown that there is no closed analytic subset $F$ in $\mathbb{C}^2$ such that the number of connected components of the fiber of a representative of the germ of $\boldsymbol{f}$ is constant on $(\mathbb{C}^2-F,0)$. In order to study morphisms $\boldsymbol{f}:\mathbb{C}^n\to\mathbb{C}^p$ with $p\geq 2$ we must then add conditions. In \cite{HMS} J. P. Henry, M. Merle and C. Sabbah introduce for the morphism $\boldsymbol{f}=(f_1,\dots,f_p)$ the condition of being \emph{without blow-up in codimension $0$}. Under this condition they manage to construct stratifications of the morphism satisfying Whitney and Thom type conditions. Following ideas of Lê D. T. (\cite{Le}), with such a stratification we get Milnor type fibrations above the strata of the target of the morphism. In \cite{SabbahMaS} C. Sabbah shows that, for any analytical morphism $f$, after a proper sequence of blowings-up of the target we can reduce to the case without blow-up in codimension $0$. If furthermore the critical locus of $f$ is a subset of the union of the hypersurfaces $f_j^{-1}(0)$ for $j=1,\dots,p$, following \cite{BMM2}, the morphism is called \emph{without slope}. For a $\mathscr{D}$-module $\mathcal{M}$ or a perverse sheaf $\mathcal{F}$ they also define what it means for pairs $(\boldsymbol{f},\mathcal{M})$ or $(\boldsymbol{f},\mathcal{F})$ to be \emph{without slope}. In this case the former stratification of the target is the usual stratification associated with the coordinate hyperplanes. In \cite{Maisonobe} P. Maisonobe proves important results about these morphisms. He shows that if $\mathcal{M}$ corresponds to $\mathcal{F}$ via the Riemann-Hilbert correspondence, i.e. $\mathbf{DR}(\mathcal{M})\simeq \mathcal{F}$, then it is equivalent to have $(\boldsymbol{f},\mathcal{M})$ without slope or $(\boldsymbol{f},\mathcal{F})$ without slope. He defines the functors $\Psi^{alg}_{\boldsymbol{f}}$, $\Phi^{alg}_{\boldsymbol{f}}$ and $\Psi_{\boldsymbol{f}}$ for pairs without slope. He shows that as for the Milnor fibration we have in this case \[\Psi_{\boldsymbol{f}}(\mathcal{F})_0\simeq R\Gamma(B_\epsilon\cap f^{-1}(D_\eta^*)\cap f^{-1}(t),\mathcal{F})\] for $t\in D_\eta^*$ and $0<\eta\ll\epsilon\ll 1$, where $D_\eta^*$ is a polydisc of radius $\eta$ minus the coordinate hyperplanes. He then shows that there exist natural isomorphisms \[\begin{array}{ccc} \Psi_{\boldsymbol{f}}\mathcal{F} & \simeq & \Psi_{f_1}\cdots\Psi_{f_p}\mathcal{F}, \\ \Psi^{alg}_{\boldsymbol{f}}\mathcal{M} & \simeq & \Psi^{alg}_{f_1}\cdots\Psi^{alg}_{f_p}\mathcal{M}, \\ \Phi^{alg}_{\boldsymbol{f}}\mathcal{M} & \simeq & \Phi^{alg}_{f_1}\cdots\Phi^{alg}_{f_p}\mathcal{M}. \end{array} \] \section*{Aim of the article} This work has its origins in the work of P. Maisonobe on $\mathscr{D}$-modules without slopes in \cite{Maisonobe} on the one hand, and in results of M. Saito on mixed Hodge modules of normal crossing type in \cite{HM1} and \cite{SaitoMHM} on the other hand. Normal crossing being a special case of a morphism without slope and having in mind the results and technics of P. Maisonobe, our aim is to extend the properties of mixed Hodge modules of normal crossing type to the without slope case. More precisely we give results on the compatibility of the filtrations involved, namely the Kashiwara-Malgragne filtrations and the Hodge filtration. In \cite{SaitoMHM}, M. Saito shows that, for a mixed Hodge module of normal crossing type, the Kashiwara-Malgrange filtrations and the Hodge filtration are compatible in the sense of definition \ref{Fcomp}. Using P. Maisonobe results, we get the following proposition \begin{prop*}[\cite{kocher1} Proposition 2.12] If $((f_1,\dots,f_p),\mathcal{M})$ is without slope then the Kashiwara-Malgrange filtrations for the $p$ hypersurfaces $f_j^{-1}(0)$ are compatible in the sense of the definition \ref{Fcomp}. \end{prop*} This leads to the following conjecture \begin{conja}\label{conjH} Let $\mathscr{M}$ be a mixed Hodge module with underlying $\mathscr{D}$-module $\mathcal{M}$ such that the pair $(\boldsymbol{f},\mathcal{M})$ is without slope. Then the Kashiwara-Malgrange filtrations for the $p$ hypersurfaces $f_j^{-1}(0)$ \emph{and the Hodge filtration $F_{\bullet} \mathcal{M}$} are compatible in the sense of the definition \ref{Fcomp}. \end{conja} A result of \cite{DMST} gives an evidence for this conjecture. In this article the authors showed the compatibility of the filtrations in the non-characteristic case which is a particular case of being without slope. \\ We will use two approaches to tackle this problem. The first one will consists in using the description of nearby and vanishing cycles functors involving Nilsson classes. The functoriality of this description will enable us to make use of the power of M. Saito's theory of mixed Hodge modules. In this way, we will prove the commutativity of the various nearby and vanishing cycles functors for mixed Hodge modules, using their commutativity for the underlying $\mathscr{D}$-modules. For the second approach, we will developed the theory of \emph{strictly multispecialisable} $\tilde{\mathscr{D}}$-modules which mimics the theory of $\mathscr{D}$-modules without slope, while taking the Hodge filtration into account. We will highlight the link between this notion and the compatibility of Kashiwara-Malgrange filtrations and the Hodge filtration. In this way we will prove the stability of these properties by a projective direct image. We will also give results on the monodromy filtrations inspired by the normal crossing case. We will then apply these results to quasi-ordinary hypersurface singularities.\\ \subsection*{Mixed Hodge modules without slope} Following \cite{SaitoMHM}, a mixed Hodge module is made of a triple $\mathscr{M}=(\mathcal{M},F_\bullet\mathcal{M},\mathcal{F})$ and a finite increasing filtration $W_\bullet \mathscr{M}$ satisfying some Hodge conditions where: \begin{enumerate} \item $\mathcal{F}$ is a perverse sheaf over $\mathbb{Q}$, \item $\mathcal{M}$ is a regular holonomic $\mathscr{D}$-module corresponding to $\mathbb{C}\otimes_\mathbb{Q} \mathcal{F}$ via the Riemann-Hilbert correspondence, in other words $\mathbf{DR}(\mathcal{M})\simeq \mathbb{C}\otimes_\mathbb{Q} \mathcal{F}$. \item $F_\bullet\mathcal{M}$ is a good filtration by $\mathscr{O}$-coherent submodules of $\mathcal{M}$. \end{enumerate} Nearby and vanishing cycles functors are among the main ingredients used in the inductive definition of Hodge modules by M. Saito. We give results on the relations between Kashiwara-Malgrange filtrations and the Hodge filtration $F_\bullet\mathcal{M}$ for a mixed Hodge module $\mathscr{M}$ such that the pair $(\boldsymbol{f},\mathcal{M})$ is without slope. In the part \ref{section1} we prove a theorem of commutation of the nearby and vanishing cycles applied to Hodge modules. \begin{theorema}[Corollary \ref{theocommuthodge}]\label{commutMHM} Let $\mathscr{M}$ be a mixed Hodge module and let us suppose that $(\boldsymbol{f},\mathcal{M})$ without slope where $\mathcal{M}$ is the $\mathscr{D}$-module underlying $\mathscr{M}$. Then we have the following isomorphisms \[\begin{array}{ccc} \Psi_{f_1}^{HM}\cdots\Psi_{f_p}^{HM}\mathscr{M} & \simeq & \Psi_{f_{\sigma(1)}}^{HM}\cdots\Psi_{f_{\sigma(p)}}^{HM}\mathscr{M}, \\ \Phi_{f_1}^{HM}\cdots\Phi_{f_p}^{HM}\mathscr{M} & \simeq & \Phi_{f_{\sigma(1)}}^{HM}\cdots\Phi_{f_{\sigma(p)}}^{HM}\mathscr{M} \end{array} \] where $\sigma$ is a permutation of $\{1,\dots,p\}$ and $\Psi_{\boldsymbol{f}}^{HM}$ and $\Phi_{\boldsymbol{f}}^{HM}$ are the nearby and vanishing cycles functors in the category of mixed Hodge modules. \end{theorema} \begin{remark*} If Conjecture \ref{conjH} were true, then this theorem would be an easy consequence of it. \end{remark*} In Part \ref{section2}, mimicking the definition of being without slope for a pair $(\boldsymbol{f},\mathcal{M})$, we give a definition of being \emph{strictly multispecialisable} for the pair $(\boldsymbol{f},\mathscr{M})$ and we prove the following theorem \begin{theorema}[Propositions \ref{compatstrict} et \ref{strictmulcompat}] Let $\mathscr{M}$ be a mixed Hodge module and $\boldsymbol{f}$ a morphism such that the pair $(\boldsymbol{f},\mathcal{M})$ is without slope, then the following statements are equivalent: \begin{enumerate} \item the pair $(\boldsymbol{f},\mathscr{M})$ is strictly multispecialisable \item the filtrations $(F_\bullet\mathcal{M},V_1^\bullet\mathcal{M},\dots,V_p^\bullet\mathcal{M})$ are compatible. \end{enumerate} Here $V_j^\bullet\mathcal{M}$ is the Kashiwara-Malgrange filtration for the hypersurface $f_j^{-1}(0)$. \end{theorema} We then prove two theorems of push-forward for mixed Hodge modules strictly multispecialisable. \begin{theorema}[Theorem \ref{commutVgrH}] Let $\mathscr{M}$ be a mixed Hodge module. If $\mathscr{M}$ is strictly multispecialisable then the push-forward of $\mathscr{M}$ by a proper morphism is also strictly multispecialisable. Moreover, in this case, the Kashiwara-Malgrange \emph{multi}filtration, the nearby cycles $\Psi_{\boldsymbol{f}}^{HM}$ and the vanishing cycles $\Phi_{\boldsymbol{f}}^{HM}$ commute with the push-forward. \end{theorema} \begin{defi*} Let $A$ be an object in an abelian category equipped with $p$ nilpotent endomorphisms $N_1,\dots,N_p$. We say that $(A,N_1,\dots,N_p)$ satisfies property $(MF)$ if the relative monodromy filtrations satisfy \[W(N_1,W(\dots,W(N_p)))A=W(N_1+\dots+N_p)A.\] (See section \ref{relatmonofilt} for definitions.) \end{defi*} \begin{theorema}[Theorem \ref{imagedirecteW}] Let $\mathscr{M}$ be a mixed Hodge module. Let $f:X\times \mathbb{C}^p_{\boldsymbol{t}}\to Y\times \mathbb{C}^p_{\boldsymbol{t}}$ be a projective morphism and suppose that $(\mathscr{M},N_1,\dots,N_p)$ satisfy property (MF), then $(\Psi_{\boldsymbol{t}}\mathscr{M},N_1,\dots,N_p)$ also satisfy property (MF). \end{theorema} As an application we prove conjecture \ref{conjH} for quasi-ordinary hypersurface singularities. \section*{Notation} \subsubsection*{Sheaves} Let $X$ be a complex variety, we will consider the following sheaves: \begin{itemize} \item $\mathcal{O}_X$ the sheaf of holomorphic functions on $X$, \item $\Omega^p_X$ the sheaf of holomorphic $p$-forms on $X$, \item $\mathscr{D}_X$ the sheaf of differential operators on $X$, \item $F_\bullet\mathscr{D}_X$ the order filtration of $\mathscr{D}_X$, \item $\tilde{\mathscr{O}}_X:=R_F\mathscr{O}_X$ the sheaf associated to $(\mathscr{O}_X,F_\bullet\mathscr{O}_X)$ by Rees's construction \ref{Rees}. \item $\tilde{\mathscr{D}}_X:=R_F\mathscr{D}_X$ the sheaf associated to $(\mathscr{D}_X,F_\bullet\mathscr{D}_X)$ by Rees's construction \ref{Rees}. \end{itemize} \subsubsection*{Categories} Let $X$ be a complex variety, we will consider the following categories: \begin{itemize} \item the category of perverse sheaves $\textup{Perv}(X)$, \item the category of regular holonomic $\mathscr{D}_X$-modules $\textup{Mod}_{h,r}(\mathscr{D}_X)$, \item the category of graded holonomic $\tilde{\mathscr{D}}_X$-modules $\textup{Mod}_{r}(\tilde{\mathscr{D}}_X)$, \item the bounded derived category of sheaves with constructible cohomology $D_c^b(X)$, \item the bounded derived category of $\mathscr{D}_X$-modules with regular holonomic cohomology $D_{h,r}^b(\mathscr{D}_X)$, \item the category of polarisable pure Hodge modules of weight $k$ $\textup{MH}^p(X,\mathbb{Q},k)$, \item the category of mixed Hodge modules $\textup{MHM}(X,\mathbb{Q})$, we will always suppose that the graded pieces for the weight filtration are polarisable. \end{itemize} \subsubsection*{Objects} We will denote the objects of the above categories in the following way: \begin{itemize} \item $\mathcal{F},\mathcal{G}\in D_c^b(X)$, \item $\mathcal{M},\mathcal{N}\in \textup{Mod}_{h,r}(\mathscr{D}_X)$, \item $\mathfrak{M},\mathfrak{N}\in \textup{Mod}_{r}(\tilde{\mathscr{D}}_X)$, \item $\mathscr{M},\mathscr{N}\in \textup{MHM}(X,\mathbb{Q})$. \end{itemize} \subsubsection*{Multi-indexes} Let $X$ be a complex variety of dimension $d$. Let $\{H_i\}_{1\leq i\leq d}$ be $p$ smooth hypersurfaces given by the equations $t_i=0$. We will use the following notations: \begin{itemize} \item $\partial_{i} := \partial_{t_i}\in\mathscr{D}_X$, \item $\eth_{i}:=\eth_{t_i}=z\partial_i\in\tilde{\mathscr{D}}_X$, \item $E_i := t_i\partial_{i}$, \item $\boldsymbol{x}:=(x_1,\dots,x_{d-p})$, \item $\boldsymbol{1}_i:=(0,\dots,0,1,0,\dots,0)$ where $1$ is in the $i$-th place, \item $\boldsymbol{\alpha}:=(\alpha_1,\dots,\alpha_p)$, \item $\boldsymbol{\alpha}_{I}:=(\alpha_i)_{i\in I}$ for $I\subset \{1,\dots,p\}$, \item $\boldsymbol{t}:=t_1\dots t_p$, \item $\boldsymbol{t}^{{\boldsymbol{s}}}:=t_1^{s_1}\dots t_p^{s_p}$, \item $\mathscr{D}_X[{\boldsymbol{s}}]:=\mathscr{D}_X[s_1,\dots,s_p]$. \item Let $V_{\boldsymbol{\alpha}}\mathcal{M}$ be a multifiltration, we denote \[\textup{gr}_{\boldsymbol{\alpha}}^V:=\frac{V_{\boldsymbol{\alpha}}} {\sum_{1\leq i\leq p}V_{\alpha_1 \dots <\alpha_i \dots \alpha_p}}\] and for for $I\subset \{1,\dots,p\}$, \[V_{<\boldsymbol{\alpha_{I}},\boldsymbol{\alpha}_{I^c}}:=\sum_{i\in I}V_{\alpha_1 \dots <\alpha_i \dots \alpha_p}. \] \end{itemize} \part{Commutativity of nearby and vanishing cycles}\label{section1} In this part, we prove the following commutativity result for mixed Hodge modules: \textit{Let $\mathscr{M}\in \textup{MHM}(X\times{\Delta}^p_{\boldsymbol{t}})$ be a mixed Hodge module on $X\times{\Delta}^p_{\boldsymbol{t}}$ such that the pair $(\mathbf{H},\mathcal{M})$ is without slope where $\mathcal{M}$ is the right $\mathscr{D}_{X\times\Delta^p_{\boldsymbol{t}}}$-module underlying $\mathscr{M}$. Then, for all permutation $\sigma$ of $\{1,\dots ,p\}$, we have an isomorphism} \[\Psi_{t_1}\cdots \Psi_{t_p}\mathscr{M} \simeq \Psi_{t_{\sigma(1)}}\cdots \Psi_{t_{\sigma(p)}}\mathscr{M}.\] We are going to use commutativity results of \cite[corollary 2.13]{kocher1} for the $\mathscr{D}$-module underlying $\mathscr{M}$. However, this proposition enables us to compare iterated vanishing cycles through vanishing cycles for several functions. A priori, we cannot equip the latter with a mixed Hodge module structure. That's why we will rather use the definition of algebraic nearby cycles that uses Nilsson class functions module. With this definition we will be able to use the powerful functorial formalism of the category of mixed Hodge modules. Thus, we will start by endowing the Nilsson class functions module with a mixed Hodge module structure. Then, in order to make the link between the graded pieces of the $V$-multifiltration and the Nilsson classes, we will define the morphism $\mathbf{Nils}$ for mixed Hodge modules. This will enable us to construct a comparison morphism between iterated vanishing cycles \emph{in the category of mixed Hodge modules}. We will then use results on $\mathscr{D}$-modules thanks to proposition \ref{isoDH}. \begin{rema}\label{defiprodtens} In this part, we will indicate the category we consider on the bottom left of each functor. We will use the letters $D$, $\tilde{D}$, $P$ and $H$ to denote respectively the categories $\textup{Mod}(\mathscr{D}_X)$, $\textup{Mod}(\tilde{\mathscr{D}}_X)$, $\textup{Perv}(\mathbb{Q}_X)$ and $\textup{MHM}(X)$. For instance, the inverse image functor by a smooth morphism $f$ in the category of perverse sheaves over $\mathbb{Q}$ will be denoted $_Pf^*$ and the tensor product functor in the category of mixed Hodge modules will be denoted $_H\otimes$. In the category $\textup{MHM}(X)$, the tensor product of $\mathscr{M}$ and $\mathscr{N}$ is defined by the following formula: \[\mathscr{M}{_H\otimes}~\mathscr{N}:={_H\delta}^*\left(\mathscr{M}{_H\boxtimes}~\mathscr{N}\right) \] where $\delta:X\to X\times X$ is the inclusion of the diagonal. \end{rema} \section{The mixed Hodge module $\mathscr{N}_{q,k}$} In order to make the link between nearby cycles and the Nilsson class, the first step in the proof of the commutativity theorem is to define the following morphism in the category of mixed Hodge modules \[ \mathbf{Nils}:\Psi_{t}\mathscr{M} \to {_Hi_*}\mathscr{H}^{-1}{_Hi^*}\left(\mathscr{M}_{q,k}\right)\] where \[\mathscr{M}_{q,k}:=\mathscr{M}~{_H\otimes} ~{_H\pi^{!}}\left(\mathscr{N}_{q,k}\right).\] with \[\begin{array}{cccc} \pi:& X\times {\Delta} & \to & {\Delta}\\ & (x,t) & \mapsto & t \end{array}.\] Accordingly, in this section we define the mixed Hodge module $\mathscr{N}_{q,k}$. Let $\Delta\subset \mathbb{C}$ be a small disc with center $0$ and coordinate $s$. We denote $\Delta^*:=\Delta-\{0\}$. We start by defining a polarized mixed Hodge structure for all $k\in \mathbb{N}$. \begin{defi} Let $k\in\mathbb{N}$ and let $V_k$ be the $\mathbb{Q}$-vector space with basis $\{v_\ell\}_{0\leq \ell\leq k}$, we define: \begin{itemize} \item the decreasing filtration $F^pV_{k,\mathbb{C}}:=\text{Vect}(\{v_\ell\}_{p\leq \ell\leq k})$, \item the nilpotent endomorphism $N$ satisfying $N(v_\ell)=v_{\ell-1}$ for all $\ell$ such that $0\leq \ell\leq k$. \item the bilinear form $Q$ satisfying $Q(v_\ell,v_{k-\ell'})=\delta_{\ell\ell'}$ for all $\ell$ such that $0\leq \ell\leq k$. \end{itemize} The weight filtration of this polarized mixed Hodge structure is given by the formula \[W_iV_k=\text{Vect}(\{v_\ell\}_{0\leq \ell\leq i/2}).\] \end{defi} \begin{rema} This mixed Hodge structure satisfies the following equality of Hodge structures of weight $2k$ \[P_k(V_k)\simeq\textup{gr}_{2k}^W V_k=\mathbb{Q}(-k). \] \end{rema} Following \cite[Corollary (3.13)]{CKS2}, the nilpotent orbit associated to this polarized mixed Hodge structure is a polarized variation of Hodge structure of weight $k$ on $\Delta^*$, we denote it ${\mathcal{H}}_k$. The corresponding $\mathbb{Q}$-local system is given by the monodromy endomorphism $\exp(N)$. The Hodge filtration is given by the following formula \[F^p{\mathcal{H}}_k:=\exp\left(\frac{\log s}{2i\pi}N\right)F^pV_k. \] We denote $\{e_\ell\}_{0\leq \ell\leq k}$ the basis of holomorphic sections defined by \[e_\ell:=(2i\pi)^\ell\sum_{0\leq j\leq \ell}\frac{1}{j!}\left(\frac{\log s}{2i\pi}\right)^jv_{\ell-j}, \] we have \[s\partial_s\cdot e_{\ell}=e_{\ell-1}, \] and \[F^p{\mathcal{H}}_k=\bigoplus_{p\leq \ell\leq k}\mathcal{O}_{\Delta^*}e_\ell. \] We switch to the right $\mathscr{D}_{\Delta^*}$-modules convention and we denote $\mathscr{H}_k$ the polarized Hodge module corresponding to the polarized variation of Hodge structure ${\mathcal{H}}_k$. \begin{defi} We define $\mathscr{N}_{k}\in \textup{MHM}(\Delta)$ as the localisation of $\mathscr{H}_k$ \[\mathscr{N}_{k}:=\mathscr{H}_k[*0]. \] \end{defi} The right $\tilde{\mathscr{D}}_{\Delta}$-module underlying $\mathscr{N}_k$ is spanned by the sections $\left\{\frac{\tilde{e}_\ell}{s}\right\}_{0\leq \ell\leq k}$, where $\tilde{e}_{\ell}:=\frac{{e}_{\ell}}{z^\ell}$. We have \[\frac{\tilde{e}_\ell}{s}\cdot s\eth_s=-\frac{\tilde{e}_{\ell-1}}{s}. \] Let us consider the application \[\begin{array}{cccc} r_q:& \Delta & \to & {\Delta}\\ & s & \mapsto & t=s^q \end{array}.\] \begin{defi}\label{MHMNilss} We define a polarized mixed Hodge module: \[\mathscr{N}_{q,k}:={_Hr_{q*}}\mathscr{N}_k.\] we denote $V^{\mathbb{Q}}_{q,k}$ the perverse sheaf underlying $\mathscr{N}_{q,k}$ and $\{v_{p,\ell}\}_{\substack{0\leq\ell\leq k \\ 1\leq p\leq q}}$ basis of $_P\Psi_tV^{\mathbb{Q}}_{q,k}$ coming from the basis $\{v_\ell\}_{0\leq \ell\leq k}$. The right $\tilde{\mathscr{D}}_{\Delta}$-module underlying $\mathscr{N}_{q,k}$ can be written \[\bigoplus_{1\leq p\leq q} \mathfrak{N}_{-\frac{p}{q},k},\] where $\mathfrak{N}_{-\frac{p}{q},k}$ is the right $\tilde{\mathscr{D}}_{\Delta}$-module spanned by the sections $\left\{\tilde{e}_{-\frac{p}{q},\ell}\right\}_{0\leq \ell\leq k}$ where $\tilde{e}_{-\frac{p}{q},\ell}:=s^{-p}q^\ell\tilde{e}_\ell$. We have \begin{equation}\label{eqNilssMHM} \tilde{e}_{-\frac{p}{q},\ell}\cdot t\eth_t = -\left(1-\frac{p}{q}\right)z\cdot\tilde{e}_{-\frac{p}{q},\ell}-\tilde{e}_{-\frac{p}{q},\ell-1}. \end{equation} \end{defi} Thus, for all $\alpha\in\mathbb{Q}\cap[-1,0[$ and for all $k\in\mathbb{N}$, $\mathfrak{N}_{\alpha,k}$ is a direct factor of a polarizable mixed Hodge module and, by definition, for all $\alpha\in\mathbb{Q}\cap[-1,0[ $ and for all $k\in\mathbb{N}$, $\mathfrak{N}_{\alpha,k}$ is equal to its localization. \begin{defi} Let us consider the projection \[\begin{array}{cccc} \pi:& X\times {\Delta} & \to & {\Delta}\\ & (x,t) & \mapsto & t \end{array}.\] and let $\mathscr{M}$ be a mixed Hodge module, we define \[\mathscr{M}_{q,k}:=\mathscr{M}~{_H\otimes} ~{_H\pi^{!}}\left(\mathscr{N}_{q,k}\right).\] We have a decomposition in the category $\textup{Mod}_{r}(\tilde{\mathscr{D}}_{X\times \Delta})$ \[\mathfrak{M}_{q,k}=\bigoplus_{1\leq p\leq q} \mathfrak{M}_{-\frac{p}{q},k}\] where \[\mathfrak{M}_{\alpha,k}:=\mathfrak{M}~{_{\tilde{D}}\otimes}~ \left({_{\tilde{D}}\pi^*}\mathfrak{N}_{\alpha,k}\right). \] with $\mathfrak{M}$ the $\tilde{\mathscr{D}}_{X\times \Delta}$-module underlying $\mathscr{M}$. \end{defi} \section{The $V$-filtration of $\mathfrak{M}_{\alpha,k}$} In this section, we compute the Kashiwara-Malgrange filtration of $\mathfrak{M}_{\alpha,k}$ in terms of the Kashiwara-Malgrange filtration of $\mathfrak{M}[*{X_0}]$, where $X_0:=X\times \{0\}\subset X\times \Delta$. We have the equality \[\mathfrak{M}_{\alpha,{k}}=\bigoplus_{0\leq\ell\leq{k}}\mathfrak{M}\left[*X_0\right]\tilde{e}_{\alpha,\ell} \] compatible with the Kashiwara-Malgrange filtration in the following sense. \begin{prop}\label{VfilttildeMalpha} Let $\alpha\in \mathbb{Q}\cap[-1,0[$ and $k\in \mathbb{N}$, the $\tilde{\mathscr{D}}_{X\times{\Delta}}$-module $\mathfrak{M}_{\alpha,k}$ is strictly $\mathbb{R}$-specialisable along $X_0$ and, for all $\beta\in{\mathbb{R}}$, we have: \[V_{\beta}(\mathfrak{M}_{\alpha,{k}})=\bigoplus_{0\leq\ell\leq{k}}V_{\beta+\alpha+1} \left(\mathfrak{M}\left[*X_0\right]\right)\tilde{e}_{\alpha,\ell}. \] with localisation defined in \ref{localisationF}. \end{prop} \begin{proof} According to the above, $\mathfrak{M}_{\alpha,k}$ is a direct factor of a $\tilde{\mathscr{D}}_{X\times{\Delta}}$-module underlyinga polarizable mixed Hodge module. Thus it is strictly $\mathbb{R}$-specialisable along $X_0$. We denote \[U_{\beta}(\mathfrak{M}_{\alpha,{k}}):=\bigoplus_{0\leq\ell\leq{k}}V_{\beta+\alpha+1} \left(\mathfrak{M}[*X_0]\right)\tilde{e}_{\alpha,\ell}. \] Let $m\in \mathfrak{M}[*X_0]$, $\ell\in \mathbb{N}$ and $\gamma\in {\mathbb{R}}$, we have \begin{equation}\label{calcul2} (m\otimes \tilde{e}_{\alpha,\ell})(t\eth_t+\gamma z)=(m(t\eth_t+\gamma z-(\alpha+1)z))\otimes \tilde{e}_{\alpha,\ell} - m\otimes \tilde{e}_{\alpha,\ell-1}, \end{equation} Thus, for all $\beta\in{\mathbb{R}}$, $U_\beta(\mathfrak{M}_{\alpha,{k}})$ is a $V_0\tilde{\mathscr{D}}_{X\times{\Delta}}$-module. Let us show that $U_{\beta}(\mathfrak{M}_{\alpha,{k}})\subset V_{\beta}(\mathfrak{M}_{\alpha,{k}})$. Let $m\in V_{\beta+\alpha+1}\left(\mathfrak{M}[*X_0]\right)$, there exist polynomials \begin{itemize} \item $b(s)=\prod_{a\in A} (s-az)$ such that for all $a\in A$, $a\leq \beta+\alpha+1$, \item $P(s)\in\tilde{\mathscr{D}}_{X\times{\Delta}/{\Delta}}[s]$ with coefficients independent from $\eth_t$ \end{itemize} such that \[m\cdot(b(t\eth_t)-tP(t\eth_t))=0.\] We deduce from \eqref{calcul2} that \[(m\otimes \tilde{e}_{\alpha,\ell})\cdot(b\left(t\eth_t+(\alpha+1)z\right)-tP(t\eth_t+(\alpha+1)z)) \in \bigoplus_{0\leq\ell'<{\ell}}V_{\beta+\alpha+1} \left(\mathfrak{M}[*X_0]\right)\tilde{e}_{\alpha,\ell'}, \] yet the roots of $b\left(s+(\alpha+1)z\right)$ are less or equal than $\beta$, thus we show by induction that $(m\otimes \tilde{e}_{\alpha,\ell})\in V_{\beta}(\mathfrak{M}_{\alpha,{k}})$ and therefore that $U_{\beta}(\mathfrak{M}_{\alpha,{k}})\subset V_{\beta}(\mathfrak{M}_{\alpha,{k}})$. To prove the converse Let us consider the exact sequence of $V_0(\tilde{\mathscr{D}}_X)$-modules: \[ 0 \to U_\beta(\mathfrak{M}_{{\alpha},{{k}}-1}) \to U_\beta(\mathfrak{M}_{{\alpha},{{k}}}) \to U_\beta(\mathfrak{M}_{{\alpha},0}) \to 0, \] from the above, it is enough to show that $U_\beta(\mathfrak{M}_{{\alpha},0})=V_\beta(\mathfrak{M}_{{\alpha},0})$ to conclude that $U_\beta(\mathfrak{M}_{{\alpha},k})=V_\beta(\mathfrak{M}_{{\alpha},k})$ for all $k\in\mathbb{N}$. Let $(m\otimes \tilde{e}_{\alpha,0})\in V_{\beta}(\mathfrak{M}_{\alpha,0})$, there exists polynomials \begin{itemize} \item $b(s)=\prod_{a\in A} (s-az)$ such that for all $a\in A$, $a\leq \beta$, \item $P(s)\in\tilde{\mathscr{D}}_{X\times{\Delta}/{\Delta}}[s]$ with coefficients independent from $\eth_t$ \end{itemize} such that \[(m\otimes \tilde{e}_{\alpha,0})\cdot(b(t\eth_t)-tP(t\eth_t))=0.\] We deduce from \eqref{calcul2} that \[\left[m\cdot(b(t\eth_t-(\alpha+1)z)-tP(t\eth_t-(\alpha+1)z))\right]\otimes \tilde{e}_{\alpha,0}=0,\] and thus \[m\cdot(b(t\eth_t-(\alpha+1)z)-tP(t\eth_t-(\alpha+1)z))=0.\] Finally, $m\in V_{\beta+\alpha+1} \left(\mathfrak{M}[*X_0]\right)$, which concludes the proof. \end{proof} \section{The morphism Nils} Here we define the morphism $\bold{Nils}$ for $\tilde{\mathscr{D}}_{X\times{\Delta}}$-modules and for perverse sheaves and then combine both definitions for mixed Hodge modules. \begin{defi}\label{DNils} Let $\mathfrak{M}$ be a $\tilde{\mathscr{D}}_{X\times{\Delta}}$-module underlying a polarizable mixed Hodge module. Following proposition \ref{VfilttildeMalpha}, we define the following morphism \[\begin{array}{cccc} {_{\tilde{{D}}}\mathbf{N}}: & \text{gr}^V_{{\alpha}}\left(\mathfrak{M}\right) & \longrightarrow & \text{gr}^V_{-{1}}(\mathfrak{M}_{{\alpha},{{k}}}) \\ & m & \longmapsto & \displaystyle\sum_{0\leq {\ell}\leq{{k}}}\left[m\cdot(t\eth_t-\alpha z)^{\ell}\right]\otimes \tilde{e}_{{\alpha},{\ell}}. \end{array}\] \end{defi} \begin{defi}\label{PervNils} We consider here the rational perverse sheaf $V^{\mathbb{Q}}_{q,k}$ of definition \ref{MHMNilss}. Let $K\in{Perv}(\mathbb{Q}_{X\times{\Delta}})$ be a perverse sheaf on $X\times{\Delta}$. We define ${_{P}}\mathbf{N}: {_{P}\Psi_t(K)} \longrightarrow {_{P}\Psi_{t,1}}(K~{_{P}\otimes}~ {_{P}\pi^!} V^{\mathbb{Q}}_{q,k}[1])$ as the morphism of perverse sheaves \[\displaystyle\sum_{\substack{ 0 \leq \ell \leq k \\ 1 \leq p \leq q }} \left({\log T_u} \right)^\ell\otimes v_{p,\ell} \] composed with the projection from $_{P}\Psi_t$ to $_{P}\Psi_{t,1}$. Here, $T_u$ is the unipotent part of the monodromy. \end{defi} \begin{defi} Let $\mathscr{M}\in \textup{MHM}(X\times{\Delta})$ be a mixed Hodge module on $X\times{\Delta}$. There exists a finite set of rational numbers in $[-1,0[$, $A$ such that the $V$-filtration of the $\tilde{\mathscr{D}}_{X\times{\Delta}}$-module underlying $\mathscr{M}$ is indexed by $A+\mathbb{Z}$. Let $q\in\mathbb{N}$ be such that $A\subset \{-\frac{p}{q}|1\leq p\leq q\}$, we consider \[\mathscr{M}_{q,k}:=\mathscr{M}~{_H\otimes} ~{_H\pi^{!}}\left(\mathscr{N}_{q,k}\right).\] If $\mathcal{M}$ is a $\mathscr{D}_{X\times \Delta}$-module, the monodromy endomorphism of ${_{P}\Psi_t\mathbf{DR}_{X\times\Delta}\mathcal{M}}$ correspond to the action of $\exp(2i\pi t\partial_t)$ on ${_{D}\Psi_t\mathcal{M}}$. Combining definitions \ref{DNils} and \ref{PervNils}, we get a morphism of mixed Hodge modules \[_H\mathbf{N}: \Psi_t(\mathscr{M}) \longrightarrow \Psi_{t,1}(\mathscr{M}_{q,k}).\] \end{defi} \begin{lemm}\label{canul} Let $k_{\alpha}$ be the exponent of the nilpotent endomorphism of right multiplication by $(t\eth_t -\alpha z)$ on $\Psi_{t,\lambda}\mathscr{M}$ where $\lambda:=e^{2i\pi\alpha}$. Then, for all $k\geq\max_{\alpha\in[-1,0[}k_\alpha$, the morphism \[\textup{can}\circ {_{H}\textup{\textbf{{N}}}} : \Psi_{t}\mathscr{M} \to \Phi_{t,1}\left(\mathscr{M}_{q,k}\right)\] is equal to zero. \end{lemm} \begin{proof} We check this on the definition of $_{\tilde{D}}\mathbf{N}$. The forgetful functor from the category of mixed Hodge modules to the category of $\mathscr{\tilde{D}}$-modules is faithful, therefore if $\textup{can}\circ {_{\tilde{D}}\textup{\textbf{{N}}}}$ is equal to zero, then $\textup{can}\circ {_{H}\textup{\textbf{{N}}}}$ is also equal to zero. \end{proof} \begin{defi}\label{Nils} Let us consider the exact sequence (2.24.3) fo \cite[2.24]{SaitoMHM} \begin{equation}\label{SEsaito}0 \to {_Hi_*}\mathscr{H}^{-1}{_Hi^*}\left(\mathscr{M}_{q,k}\right) \to \Psi_{t,1}\left(\mathscr{M}_{q,k}\right) \xrightarrow{\textup{can}} \Phi_{t,1}\left(\mathscr{M}_{q,k}\right) \to {_Hi_*}\mathscr{H}^{0}{_Hi^*}\left(\mathscr{M}_{q,k}\right) \to 0. \end{equation} Conbined with the previous lemma \ref{canul}, this gives a natural morphism \[\mathbf{Nils}:\Psi_{t}\mathscr{M} \to {_Hi_*}\mathscr{H}^{-1}{_Hi^*}\left(\mathscr{M}_{q,k}\right).\] \end{defi} \begin{rema}\label{defiminv} Here, $i$ is the inclusion of $X_0\times\{0\}$ in $X\times\Delta$. We denote by $j:X\times \Delta^*\hookrightarrow X\times \Delta$ the inclusion. According to definition \ref{defimageinverseH}, ${_Hi_*}\mathscr{H}^{-1}{_Hi^*}\mathscr{M}$ is $\mathscr{H}^{-1}$ of the complex \[0 \to {_Hj_!}{_Hj^{*}}\mathscr{M} \to \underset{\bullet}{\mathscr{M}} \to 0.\] \end{rema} \section{The natural morphism for two hypersurfaces} In this section we construct a comparison morphism between $\Psi_{t_1}\Psi_{t_2}\mathscr{M}$ and $\Psi_{t_1}\Psi_{t_2}\mathscr{M}$. The intermediate objects occurring in this construction will be defined using usual functors. Thanks to the functorial formalism of M. Saito, the comparison morphism will thus be defined \emph{in the category of mixed Hodge modules}. \begin{defi}\label{MHMplat} Let $\mathscr{N}\in \textup{MHM}(X)$, we say that $\mathscr{N}$ is \emph{flat} if its underlying $\mathscr{D}_X$-module is flat as an $\mathscr{O}_X$-module. \end{defi} \begin{lemm} If $\mathscr{N}\in \textup{MHM}(X)$ is flat, then the functor $\cdot{_H\otimes}~\mathscr{N}$ is exact. \end{lemm} \begin{proof} The tensor product functor in the category $\textup{MHM}(X)$ correspond to the tensor product of the underlying $\mathscr{D}_X$-modules through the natural forgetful functor. Let $0\to\mathscr{M}_1\to\mathscr{M}_2\to\mathscr{M}_3\to 0$ be an exact sequence in $\textup{MHM}(X)$ considered as a complex $\mathscr{M}_\bullet$. Since the $\mathscr{O}_X$-module underlying $\mathscr{N}$ is flat, for all $i\in \mathbb{Z}$, the $\mathscr{D}_X$-module underlying $\mathscr{H}^i(\mathscr{M}_{\bullet}{_H\otimes}~\mathscr{N})$ is zero. Thus, for all $i\in\mathbb{Z}$, $\mathscr{H}^i(\mathscr{M}_{\bullet}{_H\otimes}~\mathscr{N})$ is equal to zero and $\mathscr{M}_{\bullet}{_H\otimes}~\mathscr{N}$ is a short exact sequence. \end{proof} \begin{lemm}\label{morphismenat} Let $i:Y\to X$ be the inclusion of a smooth hypersurface, $\mathscr{M}$ and $\mathscr{N}$ objetcs in $\textup{MHM}(X)$ such that $\mathscr{N}$ is flat. There exists a natural morphism \begin{equation}\label{commuttensor} {_Hi}_*\mathscr{H}^{-1}{_Hi}^*(\mathscr{M}{_H\otimes}\mathscr{N})\to ({_Hi}_*\mathscr{H}^{-1}{_Hi}^*\mathscr{M}){_H\otimes}\mathscr{N}.\end{equation} \end{lemm} \begin{proof} In this proof, we will omit the index $H$ of functors to lighten notation. We will use the definition of the functor ${i}_*\mathscr{H}^{-1}{i}^*$ in remark \ref{defiminv}. Let us denote by $j:X\setminus Y\to X$ the inclusion. We consider the following commutative square: \[\xymatrix{ (j_!j^{*}\mathscr{M})\otimes\mathscr{N} \ar[r] & \mathscr{M}\otimes\mathscr{N} \\ j_!j^{*}\left((j_!j^{*}\mathscr{M})\otimes\mathscr{N}\right) \ar[u]^{\psi} \ar[r]^-{\phi} & j_!j^{*}(\mathscr{M}\otimes\mathscr{N}). \ar[u] }\] The functor $j_!j^{*}$ depends only on the restriction to $X\setminus Y$, thus the morphism $\phi$ is an isomorphism. We deduce that the morphism of complexes induced by $f$ is a quasi-isomorphism. Therefore we have a morphism of complexes \[\xymatrix{ 0 \ar[r] & (j_!j^{*}\mathscr{M})\otimes\mathscr{N} \ar[r] & \mathscr{M}\otimes\mathscr{N} \ar[r] & 0 \\ 0 \ar[r] & j_!j^{*}(\mathscr{M}\otimes\mathscr{N}) \ar[u]^{\psi\circ\phi^{-1}} \ar[r] & \underset{\bullet}{\mathscr{M}\otimes\mathscr{N}} \ar@{=}[u] \ar[r] & 0. }\] This induces a morphism between the $\mathscr{H}^{-1}$ of these two complexes, applying the definition of the functor ${i}_*\mathscr{H}^{-1}{i}^*$ in remark \ref{defiminv}, we get the morphism \[{i}_*\mathscr{H}^{-1}{i}^*(\mathscr{M}\otimes\mathscr{N})\longrightarrow ({i}_*\mathscr{H}^{-1}{i}^*\mathscr{M})\otimes\mathscr{N}, \] we use here the exactness of the functor $\cdot\otimes\mathscr{N}$. \end{proof} Let us consider the projection \[\begin{array}{cccc} \pi=(\pi_1,\pi_2):& X\times {\Delta}^2 & \to & {\Delta}^2\\ & (x,t_1,t_2) & \mapsto & (t_1,t_2). \end{array}\] We denote $H_i:=\{t_i=0\}$ for $i\in\{1,2\}$, we have the natural inclusions \begin{itemize} \item $i_1:H_1\hookrightarrow X\times {\Delta}^2$, \item $i_2:H_2 \hookrightarrow X\times {\Delta}^2 $, \item $i_{(1,2)}:H_1\cap H_2\hookrightarrow X\times {\Delta}^2$. \end{itemize} We define the following polarizable mixed Hodge module on $\Delta^2$: \[\mathscr{N}_{\boldsymbol{q},\boldsymbol{k}}:= \mathscr{N}_{q_1,k_1}~{_H\boxtimes}~\mathscr{N}_{q_2,k_2}\] and \[\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}:= \mathscr{M}~{_H\otimes}~{_H\pi}^!\mathscr{N}_{\boldsymbol{q},\boldsymbol{k}}. \] \begin{prop}\label{constructiondemidiag} Let $\mathscr{M}\in \textup{MHM}(X\times\Delta^2)$, there exist natural morphisms \begin{equation}\label{demidiag} \xymatrix{{_Hi}_{1*}\mathscr{H}^{-1}{_Hi}_{1}^*({_Hi}_{2*}\mathscr{H}^{-1}{_Hi}_{2}^* (\mathscr{M}_{q_1,k_1})~{_H\otimes}~{_H\pi_2}^!\mathscr{N}_{q_2,k_2}) \\ {_Hi}_{(1,2)*}\mathscr{H}^{-2}{_Hi}_{(1,2)}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}) \ar[u] \ar[d] \\ {_Hi}_{2*}\mathscr{H}^{-1}{_Hi}_{2}^*({_Hi}_{1*}\mathscr{H}^{-1}{_Hi}_{1}^* (\mathscr{M}_{q_2,k_2})~{_H\otimes}~{_H\pi_1}^!\mathscr{N}_{q_1,k_1}).} \end{equation} \end{prop} \begin{rema} Here, the functor ${_Hi}_{(1,2)*}\mathscr{H}^{-2}{_Hi}_{(1,2)}^*$ is also defined using definition \ref{defimageinverseH}. \end{rema} \begin{proof} We are going to construct the natural morphism \[{_Hi}_{(1,2)*}\mathscr{H}^{-2}{_Hi}_{(1,2)}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}) \to {_Hi}_{1*}\mathscr{H}^{-1}{_Hi}_{1}^*({_Hi}_{2*}\mathscr{H}^{-1}{_Hi}_{2}^* (\mathscr{M}_{q_1,k_1})~{_H\otimes}~{_H\pi_2}^!\mathscr{N}_{q_2,k_2}), \] the second one being deduced by symmetry. We will omit the index $H$ in functors to lighten the notation. We denote $U_i:=H_i^c=\{t_i\neq 0\}$ for $i\in\{1,2\}$, we have the natural inclusions \begin{itemize} \item $j_1:U_1\hookrightarrow X\times {\Delta}^2$, \item $j_2:U_2 \hookrightarrow X\times {\Delta}^2 $, \item $j_{(1,2)}:U_1\cap U_2=X\times(\Delta^*)^2\hookrightarrow X\times {\Delta}^2$. \end{itemize} Following definition \ref{defimageinverseH}, ${i}_{(1,2)*}\mathscr{H}^{-2}{i}_{(1,2)}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}})$ is the $\mathscr{H}^{-2}$ of the simple complex associated to the following double complex: \begin{equation}\label{doublecomp}\xymatrix{ j_{1!}j_1^{*}\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}} \ar[r] & \overset{\bullet}{\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}} \\ j_{(1,2)!}j_{(1,2)}^{*}\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}} \ar[r] \ar[u] & j_{2!}j_2^{*}\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}. \ar[u] }\end{equation} Let us consider the cartesian square \[\xymatrix{U_1\cap U_2 \ar[r]^{j_2} \ar[d]^{j_1} & U_1 \ar[d]^{j_1} \\ U_2 \ar[r]^{j_2} & X. }\] By adjunction, we have a natural transformation of proper base change \[ {j}_{2!}{j}_{1}^{*}\xrightarrow{}{j}_{1}^{*}{j}_{2!}. \] If we apply this morphism to a mixed Hodge module, since proper base change is an isomorphism in the category of perverse sheaves, the perverse sheaves underlying the kernel and the cokernel are zero. Thus, the kernel and cokernel are zero in the category $\textup{MHM}(X)$. The natural transformation of proper base change is therefore an isomorphism in $\textup{MHM}(X)$. We deduce from that the isomorphism of functors \[j_{(1,2)!}j_{(1,2)}^{*}\xrightarrow{\sim}j_{1!}j_1^{*}j_{2!}j_2^{*} \] using the equality $j_{(1,2)}=j_{2}\circ j_{1}$. We then deduce for the double complex \eqref{doublecomp} the following commutative diagram with short exact sequences: \[\xymatrix{ i_{1*}\mathscr{H}^{-1}i_1^*\left(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}\right) \ar[r] & j_{1!}j_1^{*}\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}} \ar[r] & \overset{\bullet}{\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}} \\ i_{1*}\mathscr{H}^{-1}i_1^*\left(j_{2!}j_2^{*}\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}\right) \ar[r] \ar[u] & j_{1!}j_1^{*}j_{2!}j_2^{*}\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}} \ar[r] \ar[u] & j_{2!}j_2^{*}\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}} \ar[u] \\ i_{1*}\mathscr{H}^{-1}i_1^*\left(i_{2*}\mathscr{H}^{-1}i_2^*\left(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}\right)\right). \ar[u] }\] We have $i_{1*}\mathscr{H}^{-2}i_1^*=0$, therefore the exactness of the vertical short sequence comes from the same result for perverse sheaves. Since ${i}_{(1,2)*}\mathscr{H}^{-2}{i}_{(1,2)}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}})$ is the $\mathscr{H}^{-2}$ of the simple complex associated to the double complex \eqref{doublecomp}, we have the isomorphism \begin{equation}\label{isom101} {i}_{(1,2)*}\mathscr{H}^{-2}{i}_{(1,2)}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}})\simeq i_{1*}\mathscr{H}^{-1}i_1^*\left(i_{2*}\mathscr{H}^{-1}i_2^*\left(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}\right)\right).\end{equation} The mixed Hodge module ${_H\pi_2}^!\mathscr{N}_{q_2,k_2}$ is flat in the sense of definition \ref{MHMplat}. Indeed, following definition \ref{imageinverse!}, the underlying $\mathscr{D}_{X\times {\Delta}^2}$-module is the inverse image for $\mathscr{D}$-modules of the module underlying $\mathscr{N}_{q_2,k_2}$. The latter being a free $\mathscr{O}_\Delta$-module, its inverse image by the projection on $\Delta$ is also free hence flat. We then apply lemma \ref{morphismenat} to $i_2$, $\mathscr{M}_{q_1,k_1}$ et ${_H\pi_2}^!\mathscr{N}_{q_2,k_2}$. We get the morphism \begin{equation}\label{adjonc}{i}_{2*}\mathscr{H}^{-1}{i}_{2}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}) \to {i}_{2*}\mathscr{H}^{-1}{i}_{2}^* (\mathscr{M}_{q_1,k_1})~{\otimes}~{\pi_2}^!\mathscr{N}_{q_2,k_2}. \end{equation} Combining the morphisms \eqref{isom101} and \eqref{adjonc}, we get the expected morphism. \end{proof} By applying the morphism $\mathbf{Nils}$ of definition \ref{Nils} for the functions $t_1:X\times {\Delta}^2\to\mathbb{C}$ and $t_2:X\times {\Delta}^2\to\mathbb{C}$, we add two morphisms to diagram \eqref{demidiag} in the following way: \begin{equation}\label{presquediag} \xymatrix{\Psi_{t_1}\Psi_{t_2}\mathscr{M} \ar[r] & {_Hi}_{1*}\mathscr{H}^{-1}{_Hi}_{1}^*\left({_Hi}_{2*}\mathscr{H}^{-1}{_Hi}_{2}^* (\mathscr{M}_{q_2,k_2})~{_H\otimes}~{_H\pi_2}^!\mathscr{N}_{q_1,k_1}\right) \\ & {_Hi}_{(1,2)*}\mathscr{H}^{-2}{_Hi}_{(1,2)}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}) \ar[u] \ar[d] \\ \Psi_{t_2}\Psi_{t_1}\mathscr{M} \ar[r] & {_Hi}_{2*}\mathscr{H}^{-1}{_Hi}_{2}^*\left({_Hi}_{1*}\mathscr{H}^{-1}{_Hi}_{1}^* (\mathscr{M}_{q_1,k_1})~{_H\otimes}~{_H\pi_1}^!\mathscr{N}_{q_2,k_2}\right).} \end{equation} \section{Applying the forgetful functor} In this section, we consider the projection \[\begin{array}{cccc} \pi=(\pi_1,\pi_2):& X\times {\Delta}^2 & \to & {\Delta}^2\\ & (x,t_1,t_2) & \mapsto & (t_1,t_2). \end{array}\] We denote $\mathbf{H}:=\{H_1,H_2\}$. Let $\mathcal{M}$ be a coherent right $\mathscr{D}_{X\times\Delta^2}$-module such that the pair $(\mathbf{H},\mathcal{M})$ is \emph{without slope}. According to \cite[proposition 2]{Maisonobe}, the canonical $V$-multifiltration satisfies, for all $(\alpha_1,\alpha_2)\in\mathbb{C}^2$, \begin{equation}\label{commutmaisonobe}\textup{gr}_{\alpha_1}^{V^{H_1}}\textup{gr}_{\alpha_2}^{V^{H_2}}\mathcal{M} \xleftarrow{\sim} \textup{gr}_{\alpha_1,\alpha_2}^{V^{\mathbf{H}}}\mathcal{M} \xrightarrow{\sim} \textup{gr}_{\alpha_2}^{V^{H_2}}\textup{gr}_{\alpha_1}^{V^{H_1}}\mathcal{M}. \end{equation} \begin{defi} Let $\mathcal{N}_{\alpha,k}$ be the $\mathscr{D}_\Delta$-module underlying the $\tilde{\mathscr{D}}_\Delta$-module of definition \ref{MHMNilss}. Let $\boldsymbol{\alpha}\in[-1,0[^2$ and $\boldsymbol{k}\in \mathbb{N}^2$, we define the following $\mathscr{D}_{\Delta^2}$-module: \[\mathcal{N}_{\boldsymbol{\alpha},\boldsymbol{k}}:=\mathcal{N}_{\alpha_1,k_1}~{_D\boxtimes}~\mathcal{N}_{\alpha_2,k_2}, \] for $\mathbf{0}\leq\boldsymbol{\ell}\leq\boldsymbol{k}$, we denote \[e_{\boldsymbol{\alpha},\boldsymbol{\ell}}:=e_{\alpha_1,\ell_1}\otimes e_{\alpha_2,\ell_2}.\] We define \[\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}:=\mathcal{M}~{_D\otimes}~{_D\pi^*}\mathcal{N}_{\boldsymbol{\alpha},\boldsymbol{k}}.\] \end{defi} \begin{prop}\label{VfiltNils} Let $\boldsymbol{\alpha}\in[-1,0[^2$ and $\boldsymbol{k}\in \mathbb{N}^2$. Under the previous hypothesis, the pair $(\mathbf{H}, \mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}})$ is without slope and, for all $\boldsymbol{\beta}\in{\mathbb{C}^2}$, we have: \[V_{\boldsymbol{\beta}}(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}})=\bigoplus_{\boldsymbol{0}\leq\boldsymbol{\ell}\leq\boldsymbol{k}} V_{\boldsymbol{\beta}+\boldsymbol{\alpha}+\boldsymbol{1}} \left(\mathcal{M}[\frac{1}{t_1t_2}]\right){e}_{\boldsymbol{\alpha},\boldsymbol{\ell}}. \] \end{prop} \begin{proof} It is the case when $p=2$ of \cite[Proposition 2.26]{kocher1}. \end{proof} \begin{defi}\label{DmultNils} We define the following morphism: \[\begin{array}{cccc} \mathbf{{_{D}}N}_{(1,2)}: & \text{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\mathcal{M} & \longrightarrow & \text{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \\ & m & \longmapsto & \displaystyle\sum_{\boldsymbol{0}\leq\boldsymbol{\ell}\leq\boldsymbol{k}} m\cdot(t_1\partial_{t_1}-\alpha_1)^{\ell_1}(t_2\partial_{t_2}-\alpha_2)^{\ell_2}\otimes e_{\boldsymbol{\alpha},\boldsymbol{\ell}}. \end{array}\] \end{defi} \begin{prop}\label{H2tot} Let us consider the following double complex: \begin{equation}\label{cplxdouble}\xymatrix{ \textup{gr}^{V^{\mathbf{H}}}_{-1,0}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \ar[r]^{\cdot\partial_{t_1}} & \textup{gr}^{V^{\mathbf{H}}}_{0,0}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \\ \textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \ar[r]^{\cdot\partial_{t_1}} \ar[u]^{\cdot\partial_{t_2}} & \textup{gr}^{V^{\mathbf{H}}}_{0,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \ar[u]^{\cdot\partial_{t_2}} }\end{equation} and Let us denote $\mathbf{Gr_{\bullet}}$ the associated simple complex, concentrated in degree $-2$, $-1$ and $0$. If, for $i=1$ and $i=2$, $k_i$ is bigger than the exponent of the nilpotent endomorphism of right multiplication by $(t_i\partial_{t_i}-\alpha_i)$ on $\textup{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\mathcal{M}$, then the morphism $\mathbf{{_{D}}N}_{(1,2)}$ factorises as an isomorphism \[\mathbf{{_{D}}N}_{(1,2)}: \textup{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\mathcal{M} \xrightarrow{\sim} \mathscr{H}^{-2}(\mathbf{Gr_{\bullet}}). \] \end{prop} \begin{proof} By definition, $\mathscr{H}^{-2}(\mathbf{Gr_{\bullet}})$ is the intersection of kernels of the right multiplication by $\partial_{t_1}:\textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\to \textup{gr}^{V^{\mathbf{H}}}_{0,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}$ and by $\partial_{t_2}:\textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\to \textup{gr}^{V^{\mathbf{H}}}_{-1,0}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}$. Furthermore the right multiplication by $t_1$ and $t_2$ on $\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}$ being bijective, the properties of the canonical $V$-multifiltration imply that the morphisms of right multiplication by $t_1:\textup{gr}^{V^{\mathbf{H}}}_{0,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\to \textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}$ and by $t_2:\textup{gr}^{V^{\mathbf{H}}}_{-1,0}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\to \textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}$ are bijectives. Therefore we have \begin{equation}\label{H-2} \mathscr{H}^{-2}(\mathbf{Gr_{\bullet}})=\bigcap_{1\leq i\leq 2}\ker[\cdot\partial_{t_i}t_i:\textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \to \textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}]. \end{equation} According to proposition \ref{VfiltNils}, a section of $\textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}$ can be written in the following way : \[\sum_{\substack{ 0 \leq \ell_1 \leq k_1 \\ 0 \leq \ell_2 \leq k_2 }} m_{\ell_1,\ell_2}\otimes e_{\boldsymbol{\alpha},\boldsymbol{\ell}} \] where the $m_{\ell_1,\ell_2}$ are sections of $\text{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\left(\mathcal{M}[\frac{1}{t_1t_2}]\right)$. According to \eqref{H-2}, this section is in $\mathscr{H}^{-2}(\mathbf{Gr_{\bullet}})$ if and only if for all pairs $(\ell_1,\ell_2)$: \[m_{\ell_1,\ell_2}\cdot (t_1\partial_{t_1}-\alpha_1)-m_{\ell_1+1,\ell_2}= m_{\ell_1,\ell_2}\cdot (t_2\partial_{t_2}-\alpha_2)-m_{\ell_1,\ell_2+1}=0,\] equivalently if and only if for all pair $(\ell_1,\ell_2)$: \[m_{\ell_1,\ell_2}=m_{0,0}\cdot(t_1\partial_{t_1}-\alpha_1)^{\ell_1}(t_2\partial_{t_2}-\alpha_2)^{\ell_2}.\] On the other hand, since $\alpha_1<0$ et $\alpha_2<0$, we have $\text{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\left(\mathcal{M}[\frac{1}{t_1t_2}]\right)=\text{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\left(\mathcal{M}\right)$. Noticing that, according to the hypothesis made on the size of the $k_i$, for all $m\in\text{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\left(\mathcal{M}\right)$ \[m\cdot(t_1\partial_{t_1}-\alpha_1)^{k_1}=m\cdot(t_2\partial_{t_2}-\alpha_2)^{k_2}=0,\] we conclude that $\mathbf{{_{D}}N}_{(1,2)}$ factorises as an isomorphism \[\mathbf{{_{D}}N}_{(1,2)}: \textup{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\mathcal{M} \xrightarrow{\sim} \mathscr{H}^{-2}(\mathbf{Gr_{\bullet}}). \] \end{proof} \begin{lemm}\label{isomnat} We have a natural isomorphism \[{_Di}_{(1,2)*}\mathscr{H}^{-2}{_Di}_{(1,2)}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}) \xrightarrow{\sim} \mathscr{H}^{-2}(\mathbf{Gr_{\bullet}}). \] \end{lemm} \begin{proof} Following the proof of proposition \ref{constructiondemidiag}, we notice the following natural isomorphisms \[{_Di}_{2*}\mathscr{H}^{-1}{_Di}_{2}^!{_Di}_{1*}\mathscr{H}^{-1}{_Di}_{1}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}})\xleftarrow{\sim}{_Di}_{(1,2)*}\mathscr{H}^{-2}{_Di}_{(1,2)}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}) \xrightarrow{\sim} {_Di}_{1*}\mathscr{H}^{-1}{_Di}_{1}^!{_Di}_{2*}\mathscr{H}^{-1}{_Di}_{2}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}) \] In the category of $\mathscr{D}$-modules, we still have the exact sequence \eqref{SEsaito} (cf \cite[(2.24.3)]{SaitoMHM}). We apply the sequence twice to the double complex \eqref{cplxdouble} and, thanks to the exactness of the nearby cycles functors, we get the following diagram of exact sequences: \[\xymatrix{ 0 \ar[r] & \textup{gr}_0^{V^{H^2}}\left({_Di}_{1*}\mathscr{H}^{-1}{_Di}_{1}^!\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\right) \ar[r] & \textup{gr}^{V^{\mathbf{H}}}_{-1,0}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \ar[r] & \textup{gr}^{V^{\mathbf{H}}}_{0,0}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \\ 0 \ar[r] & \textup{gr}_{-1}^{V^{H^2}}\left({_Di}_{1*}\mathscr{H}^{-1}{_Di}_{1}^!\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\right) \ar[u] \ar[r] & \textup{gr}^{V^{\mathbf{H}}}_{-1,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \ar[r] \ar[u] & \textup{gr}^{V^{\mathbf{H}}}_{0,-1}\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}} \ar[u] \\ 0 \ar[r] & {_Di}_{(1,2)*}\mathscr{H}^{-2}{_Di}_{(1,2)}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}) \ar[u] \ar[r] & \textup{gr}_{-1}^{V^{H^1}}\left({_Di}_{2*}\mathscr{H}^{-1}{_Di}_{2}^!\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\right) \ar[r] \ar[u] & \textup{gr}_0^{V^{H^1}}\left({_Di}_{2*}\mathscr{H}^{-1}{_Di}_{2}^!\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}\right) \ar[u] \\ & 0 \ar[u] & 0 \ar[u] & 0. \ar[u] & }\] the rows and the columns of this diagram are exact, thus we have the isomorphism \[{_Di}_{(1,2)*}\mathscr{H}^{-2}{_Di}_{(1,2)}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}) \xrightarrow{\sim} \mathscr{H}^{-2}(\mathbf{Gr_{\bullet}}). \] \end{proof} We deduce from lemma \ref{isomnat} and proposition \ref{H2tot} an isimorphism \[\text{gr}^{V^{\mathbf{H}}}_{\boldsymbol{\alpha}}\mathcal{M} \xrightarrow{\sim} {_Di}_{(1,2)*}\mathscr{H}^{-2}{_Di}_{(1,2)}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}).\] We combine this with mophisms \eqref{commutmaisonobe} and diagram \eqref{presquediag} to which we apply the forgetful functor from the category of mixed Hodge modules to the category of $\mathscr{D}_X$-modules and we get yhe following commutative diagram: \begin{equation}\label{diag} \xymatrix{\textup{gr}_{\alpha_1}^{V^{H_1}}\textup{gr}_{\alpha_2}^{V^{H_2}}\mathcal{M} \ar[r]^-{(a)} & {_Di}_{1*}\mathscr{H}^{-1}{_Di}_{1}^!\left({_Di}_{2*}\mathscr{H}^{-1}{_Di}_{2}^! (\mathcal{M}_{\alpha_2,k_2})~{_D\otimes}~{_D\pi_1}^*\mathcal{N}_{\alpha_1,k_1}\right) \\ \textup{gr}_{\boldsymbol{\alpha}}^{V^{\mathbf{H}}}\mathcal{M} \ar[r]^-{\simeq} \ar[d] \ar[u]^-{\simeq} & {_Di}_{(1,2)*}\mathscr{H}^{-2}{_Di}_{(1,2)}^!(\mathcal{M}_{\boldsymbol{\alpha},\boldsymbol{k}}) \ar[u] \ar[d] \\ \textup{gr}_{\alpha_2}^{V^{H_2}}\textup{gr}_{\alpha_1}^{V^{H_1}}\mathcal{M} \ar[r] & {_Di}_{2*}\mathscr{H}^{-1}{_Di}_{2}^!\left({_Di}_{1*}\mathscr{H}^{-1}{_Di}_{1}^! (\mathcal{M}_{\alpha_1,k_1})~{_D\otimes}~{_D\pi_2}^*\mathcal{N}_{\alpha_2,k_2}\right).} \end{equation} \begin{prop}\label{aiso} Morphism $(a)$ is an isomorphism. \end{prop} \begin{proof} We show, in the same way as for proposition \ref{H2tot}, that for $j\in\{1,2\}$ \[\textup{gr}_{\alpha_j}^{V^{H_j}}\mathcal{M}\simeq {_Di}_{j*}\mathscr{H}^{-1}{_Di}_{j}^! (\mathcal{M}_{\alpha_j,k_j})\] when $k_1$ and $k_2$ are big enough. To conclude, it is then enough to apply this isomorphism twice. \end{proof} \section{Commutativity theorem} \begin{theo}\label{commut2MHM} Let $\mathscr{M}\in \textup{MHM}(X\times{\Delta}^2)$ be a mixed Hodge module on $X\times{\Delta}^2$, such that the pair $(\mathbf{H},\mathcal{M})$ is without slope where $\mathcal{M}$ is the right $\mathscr{D}_{X\times\Delta^2}$-module underlying $\mathscr{M}$. We then have an isomorphism \[\Psi_{t_1}\Psi_{t_2}\mathscr{M} \simeq \Psi_{t_2}\Psi_{t_1}\mathscr{M}. \] \end{theo} \begin{proof} Let us consider the diagram \eqref{presquediag} \[ \xymatrix{\Psi_{t_1}\Psi_{t_2}\mathscr{M} \ar[r] & {_Hi}_{1*}\mathscr{H}^{-1}{_Hi}_{1}^*\left({_Hi}_{2*}\mathscr{H}^{-1}{_Hi}_{2}^* (\mathscr{M}_{q_2,k_2})~{_H\otimes}~{_H\pi_2}^!\mathscr{N}_{q_1,k_1}\right) \\ & {_Hi}_{(1,2)*}\mathscr{H}^{-2}{_Hi}_{(1,2)}^*(\mathscr{M}_{\boldsymbol{q},\boldsymbol{k}}) \ar[u] \ar[d] \\ \Psi_{t_2}\Psi_{t_1}\mathscr{M} \ar[r] & {_Hi}_{2*}\mathscr{H}^{-1}{_Hi}_{2}^*\left({_Hi}_{1*}\mathscr{H}^{-1}{_Hi}_{1}^* (\mathscr{M}_{q_1,k_1})~{_H\otimes}~{_H\pi_1}^!\mathscr{N}_{q_2,k_2}\right).} \] We are going to show that under the hypothesis of the theorem, every arrow of this diagram is an isomorphism. When we apply the forgetful functor from the category of mixed Hodge modules to the category of right $\mathscr{D}_X$-modules, the diagram \eqref{diag} and proposition \ref{aiso} imply that the arrows of diagram \eqref{presquediag} are isomorphisms in the category of right $\mathscr{D}_X$-modules. Yet, according to proposition \ref{isoDH}, if a morphism of mixed Hodge modules is an isomorphism between the underlying right $\mathscr{D}_X$-modules then it is an isomorphism of mixed Hodge modules. Thus, we get an isomorphism \[\Psi_{t_1}\Psi_{t_2}\mathscr{M} \simeq \Psi_{t_2}\Psi_{t_1}\mathscr{M}. \] \end{proof} Let us consider the projection \[\begin{array}{cccc} \pi=(\pi_1,\dots ,\pi_p):& X\times {\Delta}^p & \to & {\Delta}^p\\ & (x,t_1,\dots ,t_p) & \mapsto & (t_1,\dots ,t_p) \end{array}\] and $\mathbf{H}:=\{H_1,\dots ,H_p\}$ where $H_i:=\{t_i=0\}$. We deduce from theorem \ref{commut2MHM} the following corollary. \begin{coro}\label{theocommuthodge} Let $\mathscr{M}\in \textup{MHM}(X\times{\Delta}^p)$ be a mixed Hodge module on $X\times{\Delta}^p$ such that the pair $(\mathbf{H},\mathcal{M})$ is without slope where $\mathcal{M}$ is the right $\mathscr{D}_{X\times\Delta^p}$-module underlying $\mathscr{M}$. Then, for all permutation $\sigma$ of $\{1,\dots ,p\}$, we have an isomorphism \[\Psi_{t_1}\cdots \Psi_{t_p}\mathscr{M} \simeq \Psi_{t_{\sigma(1)}}\cdots \Psi_{t_{\sigma(p)}}\mathscr{M}. \] \end{coro} \begin{proof} The proposition 3 of \cite{Maisonobe} asserts that if $(\mathbf{H},\mathcal{M})$ is without slope then, for all $I\subset\{1,\dots ,p\}$, the pair $(\mathbf{H}_{I^c},\textup{gr}_{\boldsymbol{\alpha}_I}^{V^{\mathbf{H}_I}}\mathcal{M})$ is without slope. We get can therefore apply as many times as necessary theorem \ref{commut2MHM} to the pairs of consecutive functors $\Psi_{t_i}$. Thus we get the expected isomorphism. \end{proof} \part{Mixed Hodge modules without slope}\label{section2} In this part, we define a condition analogous to the condition without slope for \emph{filtered} $\mathscr{D}$-modules. It will be called strict $\mathbb{R}$-multispecialisability. Actually, we will rather consider the associated Rees's module (cf. \ref{Rees}). Thus the strict $\mathbb{R}$-multispecialisability will be defined for $R_F\mathscr{D}$-modules. In section 8.1, we define the strict $\mathbb{R}$-multispecialisability. Then we determine the connection between the filtered $\mathscr{D}$-modules case and the $R_F\mathscr{D}$-modules case when they underlie a mixed Hodge module. We will see that the notion of compatibility of the filtrations plays a key role (cf. \ref{Fcomp}). In section 8.2, we show that strict $\mathbb{R}$-multispecialisability is preserved by a proper direct image. This result is analogous to the direct image theorem of M. Saito for mixed Hodge modules. However our approach is different from M. Saito's who considers filtered $\mathscr{D}$-modules and not $R_F\mathscr{D}$-modules. This enables us to work in an \emph{abelian} category and thus to handle more easily the direct image functor in the corresponding derived category. In section 8.3, we study the behaviour of the weight filtrations. We expect this behaviour to be the same as with polarizable variations of Hodge structures in the neighbourhood of a normal crossing divisor. We prove that this condition is preserved by a projective direct image. In section 8.4, we are interested in the case of a quasi-ordinary hypersurfaces singularities. Some pure Hodge modules with support on such singularities can be naturally seen as the direct image of variations of Hodge structures defined outside of a normal crossing divisor. Thus we will be able to apply the previous results. \section{Strict $\mathbb{R}$-multispecialisability} Here, we define the strict $\mathbb{R}$-multispecialisability and we determine the connection between this condition and the compatibility of the filtrations in the sense of definition \ref{Fcomp}. \begin{defi}[multispecialisability] Let $\mathbf{H}:=\{H_1,\dots ,H_p\}$ $p$ be smooth hypersurfaces of $X$ and let $\mathfrak{M}$ be a (right) coherent $\tilde{\mathscr{D}}_X$-module. \begin{enumerate} \item $\mathfrak{M}$ is said to be \emph{multispecialisable} along $\mathbf{H}$ if, in the neighbourhood of any point of $X$, there exists a good $V$-multifiltration $U_\bullet\mathfrak{M}$ of $\mathfrak{M}$, polynomials $b_i(s)=\prod(s-\alpha_iz)$ (for $1\leq i\leq p$) and integers $\ell_i\in\mathbb{N}$ (for $1\leq i\leq p$) such that, for all $\boldsymbol{k}\in\mathbb{Z}^p$ \begin{equation}\label{eqbern1} U_{\boldsymbol{k}}\mathfrak{M}\cdot z^{\ell_i}b_i(E_i-k_iz)\subset U_{\boldsymbol{k-1}_i}\mathfrak{M}. \end{equation} \item $\mathfrak{M}$ is said to be \emph{multispecialisable by section} along $\mathbf{H}$ if, for any local section $m$ of $\mathfrak{M}$ and for all $1\leq i\leq p$, there exists $\ell_i\in\mathbb{N}$, $b_i(s)=\prod(s-\alpha_iz)$ and $P_i\in V_{\mathbf{-1}_i}\tilde{\mathscr{D}}_X$ such that \begin{equation}\label{eqbern2} m\cdot (z^{\ell_i}b_i(E_i)-P_i) = 0. \end{equation} \end{enumerate} \end{defi} \begin{rema} \begin{itemize} \item These two definitions are equivalent, and if they are satisfied, then condition 1. is satisfied for any good $V$-multifiltration. \item If $\mathfrak{M}$ is multispecialisable along $\mathbf{H}$, the unitary polynomials of smallest degree satisfying equation \eqref{eqbern1} or equation \eqref{eqbern2} are called \emph{weak Bernstein-Sato polynomials}. \item If these properties are satisfied and if the roots of the polynomials $b_i$ are real numbers, then $\mathfrak{M}$ is said to be $\mathbb{R}$-{multispecialisable} along $\mathbf{H}$. \item In the case $\mathbb{R}$-multispecialisable by section, we can define the order multifiltration along $\mathbf{H}$ if we consider the unitary polynomials of smallest degree satisfying equation \eqref{eqbern2} for a local section $m$. \end{itemize} \end{rema} \begin{defi} let $\mathcal{M}$ $\mathscr{D}_X$-module such that the pair $(\mathbf{H},\mathcal{M})$ is without slope and such that the roots of the Bernstein-Sato polynomials are real numbers. We will say as well that $\mathcal{M}$ is $\mathbb{R}$-multispecialisable along $\mathbf{H}$. \end{defi} \begin{rema}\label{multispeF} Let $\mathcal{M}$ be a coherent $\mathscr{D}_X$-module with a coherent $F$-filtration. If $\mathcal{M}$ is $\mathbb{R}$-multispecialisable along $\mathbf{H}$, then the Rees's module $R_F\mathcal{M}$ is $\mathbb{R}$-multispecialisable along $\mathbf{H}$ and the converse is also true. \end{rema} \begin{defi}[strict $\mathbb{R}$-multispecialisability]\label{defmultstrict} Let $\mathfrak{M}$ be a $\tilde{\mathscr{D}}_X$-module $\mathbb{R}$-multispecialisable along $\mathbf{H}$. $\mathfrak{M}$ is said to be \emph{strictly} $\mathbb{R}$-multispecialisable along $\mathbf{H}$, if \begin{enumerate} \item There exists a finite set $A\in ]-1,0]^p$ such that the order multifiltration along $\mathbf{H}$ is a good $V$-multifiltration indexed by $A+\mathbb{Z}^p$, \item for all $I\subset\{1,\dots ,p\}$ and all $\boldsymbol{\alpha}\in \mathbb{R}^p$, $V_{\boldsymbol{\alpha}}\mathfrak{M}/V_{<\boldsymbol{\alpha}_I,\boldsymbol{\alpha}_{I^c}}\mathfrak{M}$ is strict, \item for all $1\leq i\leq p$ and all $\alpha_i<0$, the morphism $t_i:\textup{gr}_{\boldsymbol{\alpha}}\mathfrak{M}\to \textup{gr}_{\boldsymbol{\alpha-1}_i}\mathfrak{M}$ is surjective, \item for all $1\leq i\leq p$ and all $\alpha_i>-1$, the morphism $\eth_i:\textup{gr}_{\boldsymbol{\alpha}}\mathfrak{M}\to \textup{gr}_{\boldsymbol{\alpha+1}_i}\mathfrak{M}(-1)$ is surjective. \end{enumerate} In this case, we call the order $V$-multifiltration \emph{the canonical $V$-multifiltration}. \end{defi} \begin{rema} If $\mathfrak{M}$ is \emph{strictly} $\mathbb{R}$-multispecialisable along $\mathbf{H}$, then \begin{itemize} \item for all $1\leq i\leq p$ and all $\alpha_i<0$, the morphism $t_i:\textup{gr}_{\boldsymbol{\alpha}}\mathfrak{M}\to \textup{gr}_{\boldsymbol{\alpha-1}_i}\mathfrak{M}$ is an isomorphism, \item for all $1\leq i\leq p$ and all $\alpha_i>-1$, the morphism $\eth_i:\textup{gr}_{\boldsymbol{\alpha}}\mathfrak{M}\to \textup{gr}_{\boldsymbol{\alpha+1}_i}\mathfrak{M}(-1)$ is an isomorphism. \end{itemize} \end{rema} \begin{prop}\label{compatstrict} Let $\mathcal{M}$ be a coherent $\mathscr{D}_X$-module, $\mathbb{R}$-{multispecialisable} along $\mathbf{H}$ and equipped with a coherent $F$-filtration such that \begin{enumerate} \item The Rees module $R_F\mathcal{M}$ underlies a mixed Hodge module, \item The filtrations $(F_\bullet\mathcal{M},V^1_\bullet\mathcal{M},\dots ,V^p_\bullet\mathcal{M})$ are compatible. \end{enumerate} Then $R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}$. \end{prop} \begin{proof} According to Remark \ref{multispeF}, $R_F\mathcal{M}$ is $\mathbb{R}$-multispecialisable along $\mathbf{H}$. We define a $V$-multifiltration of $R_F\mathcal{M}$ in the following way: \begin{equation}\label{multifilt} U_{\boldsymbol{\alpha}}R_F\mathcal{M}:=\bigoplus_{p\in\mathbb{Z}}(F_pV_{\boldsymbol{\alpha}}\mathcal{M})z^p. \end{equation} By definition, there exists a finite set $A\subset ]-1,0]^p$ such that this $V$-multifiltration is indexed by $A+\mathbb{Z}^p$. The filtrations $(F_\bullet\mathcal{M},V^1_\bullet\mathcal{M},\dots ,V^p_\bullet\mathcal{M})$ being compatible, we get that, for all $I\subset\{1,\dots ,p\}$ and all $\boldsymbol{\alpha}\in \mathbb{R}^p$, $U_{\boldsymbol{\alpha}}R_F\mathcal{M}/U_{<\boldsymbol{\alpha}_I,\boldsymbol{\alpha}_{I^c}}R_F\mathcal{M}= R_F\left(V_{\boldsymbol{\alpha}}\mathcal{M}/V_{<\boldsymbol{\alpha}_I,\boldsymbol{\alpha}_{I^c}}\mathcal{M}\right)$, thus $U_{\boldsymbol{\alpha}}R_F\mathcal{M}/U_{<\boldsymbol{\alpha}_I,\boldsymbol{\alpha}_{I^c}}R_F\mathcal{M}$ is strict. Let $mz^p$ be a local section of $(F_pV_{\boldsymbol{\alpha}}\mathcal{M})z^p$, for all $1\leq i\leq p$, there exists an integer $\nu_i$ such that \[mz^p(t_i\eth_i-\alpha_iz)^{\nu_i}\in (F_{p+\nu_i}V_{\alpha_1,\dots ,<\alpha_i,\dots ,\alpha_p}\mathcal{M})z^{p+\nu_i},\] thus, we have $U_{\boldsymbol{\alpha}}R_F\mathcal{M}\subset V_{\boldsymbol{\alpha}}R_F\mathcal{M}$. We are going to show that the $V$-multifiltration $U_{\bullet}R_F\mathcal{M}$ is a good $V$-multifiltration, this will imply that it is the canonical $V$-multifiltration and therefore that points 1. and 2. of definition \ref{defmultstrict} are satisfied. We first prove points 3. and 4. of definition \ref{defmultstrict}. Since The Rees's module $R_F\mathcal{M}$ underlies a mixed Hodge module, it is strictly $\mathbb{R}$-specialisable along any hypersurface, in particular we have for all $1\leq i\leq p$: \begin{enumerate}[label=(\alph*')] \item $\forall p$ and $\forall \alpha_i<0, t_i:F_pV_{\alpha_i}^{H_i}\mathcal{M}\to F_pV_{\alpha_i-1}^{H_i}\mathcal{M}$ is an isomorphism, \item\label{b'} $\forall p$ and $\forall \alpha_i>-1, \partial_i:F_p\textup{gr}_{\alpha_i}^{V_i}\mathcal{M}\to F_{p+1}\textup{gr}_{\alpha_i+1}^{V_i}\mathcal{M}$ is an isomorphism. \end{enumerate} Furthermore, we deduce from the $\mathbb{R}$-multispecialisability property of $\mathcal{M}$ that, for all $1\leq i\leq p$: \begin{enumerate}[label=(\alph*'')] \item $\forall \alpha_i<0, t_i:V_{\boldsymbol{\alpha}}\mathcal{M}\to V_{\boldsymbol{\alpha-1}_i}\mathcal{M}$ is an isomorphism, \item\label{b''} $\forall \alpha_i>-1, \partial_i:\textup{gr}_{\boldsymbol{\alpha}}\mathcal{M}\to \textup{gr}_{\boldsymbol{\alpha+1}_i}\mathcal{M}$ is an isomorphism. \end{enumerate} We can then deduce that for all $1\leq i\leq p$: \begin{enumerate}[label=(\alph*)] \item\label{a} $\forall p$ and $\forall \alpha_i<0, t_i:F_pV_{\boldsymbol{\alpha}}\mathcal{M}\to F_pV_{\boldsymbol{\alpha-1}_i}\mathcal{M}$ is an isomorphism, \item\label{b} $\forall p$ and $\forall \alpha_i>-1, \partial_i:F_p\textup{gr}_{\boldsymbol{\alpha}}\mathcal{M}\to F_{p+1}\textup{gr}_{\boldsymbol{\alpha+1}_i}\mathcal{M}$ is an isomorphism. \end{enumerate} let us prove \ref{b}, in order to lighten notation, we set $i=1$. Injectivity is a direct consequence of \ref{b''}. For surjectivity, we use the compatibility of filtrations. Let $\bar{m}\in F_{p+1}\textup{gr}_{\boldsymbol{\alpha+1}_1}\mathcal{M}$ and $m\in F_{p+1}V_{\alpha_2,\dots ,\alpha_p}\textup{gr}^{V_1}_{\alpha_1+1}\mathcal{M}$ be a representative. According to the surjectivity of \ref{b'}, there exists $\tilde{m}\in F_p\textup{gr}^{V_1}_{\alpha_1}\mathcal{M}$ such that $\partial_1\tilde{m}=m$. According to the surjectivity of \ref{b''}, there exists $m'\in V_{\alpha_2,\dots ,\alpha_p}\textup{gr}^{V_1}_{\alpha_1}\mathcal{M}$ and $n\in\sum_{j=2}^pV_{\alpha_2 ,\dots ,<\alpha_j,\dots ,\alpha_p}\textup{gr}^{V_1}_{\alpha_1+1}\mathcal{M}$ such that $\partial_1 m'=n+m$. For $2\leq i\leq p$, there exists real numbers $\beta_i$ such that $\beta_i\geq \alpha_i$ and $\tilde{m}-m'\in V_{\beta_2 ,\dots ,\beta_p}\textup{gr}^{V_1}_{\alpha_1}\mathcal{M}$. Following \ref{b''}, the morphism $\partial_1:\textup{gr}^{V_2}_{\beta_2}\textup{gr}_{\alpha_1,\beta_3\dots ,\beta_p}\mathcal{M}\to \textup{gr}^{V_2}_{\beta_2}\textup{gr}_{\alpha_1+1,\beta_3\dots ,\beta_p}\mathcal{M}$ is injective. Yet, the class of $n$ in $\textup{gr}^{V_2}_{\beta_2}\textup{gr}_{\alpha_1+1,\beta_3\dots ,\beta_p}\mathcal{M}$ is zero and $\partial_1(\tilde{m}-m')=n$. we deduce that $\tilde{m}-m'\in V_{<\beta_2 ,\dots ,\beta_p}\textup{gr}^{V_1}_{\alpha_1}\mathcal{M}$. Thus, we show by induction that $\tilde{m}-m'\in V_{\alpha_2 ,\dots ,\alpha_p}\textup{gr}^{V_1}_{\alpha_1}\mathcal{M}$. Finally, $\tilde{m}\in F_pV_{\alpha_2 ,\dots ,\alpha_p}\textup{gr}^{V_1}_{\alpha_1}\mathcal{M}$ et $\partial_1\tilde{m}=m$, thus we get the surjectivity in \ref{b}. Statement \ref{a} can be proven in the same way. This implies points 3. and 4. in definition \ref{defmultstrict} for the $V$-multifiltration $U_{\bullet}R_F\mathcal{M}$. Thus it remains to prove that it is a good $V$-multifiltration. The set $A$ of indices in $[-1,0]^p$ of the multifiltration $U_\bullet R_F\mathcal{M}$ being finite, in order to show coherence it is enough to prove that for all $\boldsymbol{\alpha}\in [-1,0]^p$, the module $U_{\boldsymbol{\alpha}}R_F \mathcal{M}$ is $V_{\mathbf{0}}R_F\mathscr{D}_X$-coherent, and we will conclude by using the two isomorphisms above. More precisely we are going to show that $U_{\boldsymbol{\alpha}}R_F \mathcal{M}$ is $R_F\mathscr{D}_{X/\mathbb{C}^p}$-coherent where we consider the reduced local equations $(t_1,\dots ,t_p):X\to \mathbb{C}^p$ of $\mathbf{H}$. let us show that $F_pV_{\boldsymbol{\alpha}}\mathcal{M}$ is $\mathcal{O}_X$-coherent for all $p$. The module $\mathcal{M}$ is $\mathbb{R}$-{multispecialisable} along $\mathbf{H}$ therefore $V_{\boldsymbol{\alpha}}\mathcal{M}$ is $V_{\boldsymbol{0}}\mathscr{D}_X$-coherent, we can thus filter $V_{\boldsymbol{\alpha}}\mathcal{M}$ by $\mathcal{O}_X$-coherent submodules $(V_{\boldsymbol{\alpha}}\mathcal{M})_l$. The increasing sequence of coherent $\mathcal{O}_X$-modules $F_p\mathcal{M}\cap (V_{\boldsymbol{\alpha}}\mathcal{M})_l$ is included in $F_p\mathcal{M}$ therefore it is locally stationary, thus $F_pV_{\boldsymbol{\alpha}}\mathcal{M}$ is $\mathcal{O}_X$-coherent. It remains to show that, locally, there exists $p_0$ such that $F_p\mathscr{D}_{X/\mathbb{C}^p}\cdot F_{p_0}V_{\boldsymbol{\alpha}}\mathcal{M}=F_{p+p_0}V_{\boldsymbol{\alpha}}\mathcal{M}$ for all $p\geq 0$. The Rees's module $R_F\mathcal{M}$ underlies a mixed Hodge module and the filtrations $(F_\bullet\mathcal{M},V^1_\bullet\mathcal{M},\dots ,V^p_\bullet\mathcal{M})$ are compatible, therefore $R_F\textup{gr}_{\boldsymbol{\alpha}}\mathcal{M}$ also underlies a mixed Hodge module on $\cap_iH_i$ and thus it is $R_F\mathscr{D}_{\cap_iH_i}$-coherent. We deduce from that the $R_F\mathscr{D}_{\cap_iH_i}$-coherence of \[\frac{R_FV_{\boldsymbol{\alpha}}\mathcal{M}}{\displaystyle\sum_{1\leq i\leq p}R_FV_{\boldsymbol{\alpha-1}_i}\mathcal{M}} \] and therefore the existence of $p_0$ such that, for all $p\geq 0$, \begin{equation}\label{egalitécohérence} F_p\mathscr{D}_{\cap_iH_i}\cdot \frac{F_{p_0}V_{\boldsymbol{\alpha}}\mathcal{M}}{\displaystyle\sum_{1\leq i\leq p}F_{p_0}V_{\boldsymbol{\alpha-1}_i}\mathcal{M}}=\frac{F_{p+p_0}V_{\boldsymbol{\alpha}}\mathcal{M}}{\displaystyle\sum_{1\leq i\leq p}F_{p+p_0}V_{\boldsymbol{\alpha-1}_i}\mathcal{M}}. \end{equation} let us denote $U_{\boldsymbol{\alpha},p}:=F_p\mathscr{D}_{X/\mathbb{C}^p}\cdot F_{p_0}V_{\boldsymbol{\alpha}}\mathcal{M}$. according to \ref{a}, if $\boldsymbol{\alpha}\in [-1,0[^p$, then we can rewrite the equality \eqref{egalitécohérence}: \[ \frac{U_{\boldsymbol{\alpha},p}}{\displaystyle\sum_{1\leq i\leq p}U_{\boldsymbol{\alpha},p}\cdot t_i} = \frac{F_{p+p_0}V_{\boldsymbol{\alpha}}\mathcal{M}}{\displaystyle\sum_{1\leq i\leq p}F_{p+p_0}V_{\boldsymbol{\alpha}}\mathcal{M}\cdot t_i}. \] According to Nakayama's lemma, this implies that $U_{\boldsymbol{\alpha},p}=F_{p+p_0}V_{\boldsymbol{\alpha}}\mathcal{M}$ in the neighbourhood of $\cap_i H_i$. There remains the case where $\alpha_i=0$ for some index $1\leq i\leq p$. We use an induction on the number of indices $1\leq i\leq $ such that $\alpha_i=0$. In order to simplify, let us suppose that there exists $1\leq k\leq p$ such that $(\alpha_1,\dots ,\alpha_k)\in [-1,0[^k$ and $\alpha_{k+1}=\dots =\alpha_p=0$. We can apply the above argument to $R_F\textup{gr}_{\alpha_{k+1}\dots \alpha_p}^{H_{k+1}\dots H_{p}}\mathcal{M}$ and deduce that \[F_p\mathscr{D}_{(\bigcap_{i>k}H_i)/\mathbb{C}^k}F_{p_0}V_{\alpha_1\dots \alpha_k}\textup{gr}_{\alpha_{k+1}\dots \alpha_p}\mathcal{M}=F_{p+p_0}V_{\alpha_1\dots \alpha_k}\textup{gr}_{\alpha_{k+1}\dots \alpha_p}\mathcal{M}.\] We can rewrite this equality \[ F_{p+p_0}V_{\boldsymbol{\alpha}}\mathcal{M}=F_p\mathscr{D}_{X/\mathbb{C}^p}F_{p_0} V_{\boldsymbol{\alpha}}\mathcal{M}+\displaystyle\sum_{k+1\leq i\leq p}F_{p+p_0}V_{\alpha_1\dots <\alpha_i\dots \alpha_p}\mathcal{M}. \] In the sum on the right side, we decreased the number of indices $1\leq i\leq $ such that $\alpha_i=0$ by $1$. Thus, using the induction hypothesis, we have \[F_{p+p_0}V_{\alpha_1\dots <\alpha_i\dots \alpha_p}\mathcal{M}=F_p\mathscr{D}_{X/\mathbb{C}^p}F_{p_0} V_{\alpha_1\dots <\alpha_i\dots \alpha_p}\mathcal{M}\] and we deduce that \[F_{p+p_0}V_{\boldsymbol{\alpha}}\mathcal{M}=F_p\mathscr{D}_{X/\mathbb{C}^p}F_{p_0} V_{\boldsymbol{\alpha}}\mathcal{M}.\] The multifiltration \eqref{multifilt} is therefore a good $V$-multifiltration of $R_F\mathcal{M}$, then it is the canonical $V$-multifiltration, which gives us points 1. and 2. of definition \ref{defmultstrict} and concludes the proof of the proposition. \end{proof} Conversely, strict $\mathbb{R}$-multispecialisability implies the compatibility of the filtrations. \begin{prop}\label{strictmulcompat} If $R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}$, then the filtrations $(F_\bullet\mathcal{M},V^1_\bullet\mathcal{M},\dots ,V^p_\bullet\mathcal{M})$ are compatible. \end{prop} \begin{proof} In order to prove this proposition, we denote $\mathscr{M}$ the $\mathbb{C}[z,y_1,\dots ,y_p]$-module given by the Rees's construction of definition \ref{Rees} starting with $\mathcal{M}$, the filtration $F_\bullet\mathcal{M}$ and the canonical $V$-filtrations $V^{H_i}_\bullet\mathcal{M}$. In order to show the compatibility of the filtrations, we will show that $\mathscr{M}$ is a flat $\mathbb{C}[z,y_1,\dots ,y_p]$-module (proposition \ref{compatReesplat}). According to corollary \ref{coroKoszul}, it is enough to show that, for all $0\leq k\leq p$, the sequence $y_1,\dots ,y_k,z$ is regular. Let us first prove that multiplication by $y_{\ell}$ on $\mathscr{M}/(y_1,\dots ,y_{\ell-1})\mathscr{M}$ is injective for all $1\leq \ell\leq k$. let us consider the following diagram: \[\xymatrix{\mathscr{M}/(y_1,\dots ,y_{\ell-1})\mathscr{M} \ar[r]^{.y_{\ell}} \ar[d] & \mathscr{M}/(y_1,\dots ,y_{\ell-1})\mathscr{M} \ar[d] \\ \mathscr{M}/(y_1,\dots ,y_{\ell-1},z-1)\mathscr{M} \ar[r]^{.y_\ell} & \mathscr{M}/(y_1,\dots ,y_{\ell-1},z-1)\mathscr{M}.}\] According to lemma \ref{multispeF}, $\mathcal{M}$ is $\mathbb{R}$-multispecialisable along $\mathbf{H}$. Therefore, according to \cite[proposition 2.12]{kocher1}, the filtrations $(V^{H_1}_\bullet\mathcal{M},\dots ,V^{H_p}_\bullet\mathcal{M})$ of $\mathcal{M}$ are compatible. We deduce that the lower horizontal morphism in the above diagram is injective. According to point 2. in definition \ref{defmultstrict}, $\mathscr{M}/(y_1,\dots ,y_{\ell-1})\mathscr{M}$ is a strict graded $\mathbb{C}[z]$-module. Furthermore, the multiplication by $y_{\ell}$ on $\mathscr{M}/(y_1,\dots ,y_{\ell-1})\mathscr{M}$ is a morphism of degree zero graded $\mathbb{C}[z]$-modules. This implies that the multiplication by $y_{\ell}$ on $\mathscr{M}/(y_1,\dots ,y_{\ell-1})\mathscr{M}$ is injective. In the same way, $\mathscr{M}/(y_1,\dots ,y_{k})\mathscr{M}$ is a strict $\mathbb{C}[z]$-module, according to point 2. of definition \ref{defmultstrict}, the multiplication by $z$ is thus injective. The sequence $y_1,\dots ,y_k,z$ is therefore regular and this concludes the proof of the proposition. \end{proof} \begin{prop} Let $I\subset \{1,\dots ,p\}$ and let us denote $\mathbf{H}_I:=\{H_i\}_{i\in I}$. Let $\mathcal{M}$ be a coherent $\mathscr{D}_X$-module equipped with a coherent $F$-filtration such that $R_F\mathcal{M}$ underlies a mixed Hodge module. If $R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispeciali\-sable along $\mathbf{H}$, then \begin{itemize} \item $R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_I$, \item the canonical $V^{\mathbf{H}_I}$-multifiltration of $R_F\mathcal{M}$ satisfies: $V^{\mathbf{H}_I}_{\boldsymbol{\alpha}_I}R_F\mathcal{M}=\displaystyle \sum_{\boldsymbol{\alpha}_{I^c} \in\mathbb{C}^{I^c}}V^{\mathbf{H}_I}_{\boldsymbol{\alpha}_I,\boldsymbol{\alpha}_{I^c}}R_F\mathcal{M}$, \item for all $\boldsymbol{\alpha}_I\in \mathbb{R}^I$, $\textup{gr}^{\mathbf{H}^I}_{\boldsymbol{\alpha_I}}R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_{I^c}$. \end{itemize} \end{prop} \begin{proof} Following \cite[corollaire 1]{Maisonobe} $\mathcal{M}$ is $\mathbb{R}$-multispecialisable along $\mathbf{H}_I$. Moreover, following proposition \ref{strictmulcompat}, the filtrations $(F_\bullet\mathcal{M},V^1_\bullet\mathcal{M},\dots ,V^p_\bullet\mathcal{M})$ are compatible. Thus the filtrations $(F_\bullet\mathcal{M},\{V^i_\bullet\mathcal{M}\}_{i\in I})$ are compatible. Then, following proposition \ref{compatstrict}, we have that $R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_I$. We deduce from \eqref{multifilt} of the proof of proposition \ref{compatstrict} and from \cite[corollaire 1]{Maisonobe} that the canonical $V^{\mathbf{H}_I}$-multifiltration of $R_F\mathcal{M}$ satisfies: $V^{\mathbf{H}_I}_{\boldsymbol{\alpha}_I}R_F\mathcal{M}=\displaystyle \sum_{\boldsymbol{\alpha}_{I^c} \in\mathbb{C}^{I^c}}V^{\mathbf{H}_I}_{\boldsymbol{\alpha}_I,\boldsymbol{\alpha}_{I^c}}R_F\mathcal{M}$. The compatibility of the filtrations implies that $\textup{gr}^{\mathbf{H}^I}_{\boldsymbol{\alpha_I}}R_F\mathcal{M}= R_F\textup{gr}^{\mathbf{H}^I}_{\boldsymbol{\alpha_I}}\mathcal{M}$ underlies a mixed Hodge module. Moreover, following \ref{appA}, the filtrations $(F_\bullet\textup{gr}^{\mathbf{H}^I}_{\boldsymbol{\alpha_I}}\mathcal{M},\{V^i_\bullet\textup{gr}^{\mathbf{H}^I}_{\boldsymbol{\alpha_I}}\mathcal{M}\}_{i\in I^c})$ are compatible. Following proposition \ref{compatstrict} we deduce that $\textup{gr}^{\mathbf{H}^I}_{\boldsymbol{\alpha_I}}R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_{I^c}$. \end{proof} \section{Direct image} Here we show that strict $\mathbb{R}$-multispecialisability is preserved by a proper direct image. We also show that, under this condition, the canonical $V$-multifiltration and its graded pieces commute with proper direct image. \begin{theorem}\label{commutVgrH} Let $h:X\to Y$ be an holomorphic map between two complex manifolds, and $f=h\times \text{Id}:X\times \mathbb{C}^p\to Y\times \mathbb{C}^p$. Let $\mathbf{H}$ be the set of hyperplanes of equation $\{t_i=0\}$ for $1\leq i\leq p$ where the $t_i$ are the coordinates of $\mathbb{C}^p$. Let $\mathcal{M}$ be a coherent $\mathscr{D}_{X\times \mathbb{C}^p}$-module equipped with a good $F$-filtration. let us suppose that $R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}$ and that $R_F\mathcal{M}$ underlies a mixed Hodge module. Then for all $k\in\mathbb{Z}$: \begin{itemize} \item the $R_F\mathscr{D}_{Y\times\mathbb{C}^p}$-module $\mathcal{H}^kf_*(R_F\mathcal{M})$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}$. \item For all $\boldsymbol{\alpha}\in\mathbb{C}^p$, the canonical $V$-multifiltration for the functions $(t_1,\dots ,t_p)$ satisfies \begin{equation} \mathcal{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})\simeq V_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M}) \label{commutVH}\end{equation} and \begin{equation} \mathcal{H}^kf_*(\text{gr}^{V}_{\boldsymbol{\alpha}}R_F\mathcal{M})\simeq \text{gr}^{V}_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M}). \label{commutgrH}\end{equation} \end{itemize} \end{theorem} \begin{proof} We define a $V$-multifiltration of $\mathcal{H}^kf_*(R_F\mathcal{M})$ in the following way: \begin{equation}U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M}):=\text{image}[\mathcal{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})\to \mathcal{H}^kf_*(R_F\mathcal{M})]. \label{deffiltrH}\end{equation} First we will find locally, for all $1\leq i\leq p$, polynomials satisfying \[(U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M}))b_i(E_i-\alpha_iz)\subset (U_{\boldsymbol{\alpha-1}_i}\mathcal{H}^kf_*(R_F\mathcal{M}))\] and with roots in $[-1,0[$. Second we will show that the natural morphism \[\mathcal{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})\to \mathcal{H}^kf_*(R_F\mathcal{M})\] is injective, that the $V$-multifiltration \eqref{deffiltrH} is a good $V$-multifiltration and that it satisfy the properties of the canonical $V$-multifiltration. This will imply that $\mathcal{H}^kf_*(R_F\mathcal{M})$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}$ and this will provide us with the natural isomorphism \eqref{commutVH}. Finally, we will construct the isomorphism \eqref{commutgrH}. \subsubsection*{Cancelling polynomials.} Let $(y,t)\in Y\times \mathbb{C}^p$ and let $1\leq i\leq p$, we are going to find a polynomial $b_i(s)\in \mathbb{C}[s]$ satisfying for all $\boldsymbol{\alpha}\in\mathbb{C}^p$, $(U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M}))_{(y,t)}b_i(E_i-\alpha_iz)\subset (U_{\boldsymbol{\alpha-1}_i}\mathcal{H}^kf_*(R_F\mathcal{M}))_{(y,t)}$. Let $x\in f^{-1}(y)$, by the definition of the canonical $V$-multifiltration there exists an open neighbourhood $U$ of $(x,t)$ and a polynomial $b_i^x(s)\in \mathbb{C}[s]$ satisfying for all $\boldsymbol{\alpha}\in\mathbb{C}^p$, $\restriction{V_{\boldsymbol{\alpha}}R_F\mathcal{M}}{U}b_i^x(E_i-\alpha_iz)\subset \restriction{V_{\boldsymbol{\alpha-1}_i}R_F\mathcal{M}}{U}$ and with roots in $[-1,0[$. The map $f$ being proper, $f^{-1}(y)$ is compact, thus there exists a finite set $J$, points $x_j\in f^{-1}(y)$ for all $j\in I$ and an open neighbourhood $V$ of $f^{-1}(y)\times \{t\}$ such that \[\restriction{V_{\boldsymbol{\alpha}}R_F\mathcal{M}}{V}\prod_{j\in J}b_i^{x_j}(E_i-\alpha_iz)\subset \restriction{V_{\boldsymbol{\alpha-1}_i}R_F\mathcal{M}}{V}.\] By functoriality, the action of $E_i$ on the $\mathscr{D}_X$-module $V_{\boldsymbol{\alpha}}R_F\mathcal{M}/V_{\boldsymbol{\alpha-1}_i}R_F\mathcal{M}$ induce an action on \[\left(U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M})\right)/\left(U_{\boldsymbol{\alpha-1}_i} \mathcal{H}^kf_*(R_F\mathcal{M})\right)\] and \[(U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M}))_{(y,t)}\prod_{j\in J}b_i^{x_j}(E_i-\alpha_iz)\subset (U_{\boldsymbol{\alpha-1}_i}\mathcal{H}^kf_*(R_F\mathcal{M}))_{(y,t)}.\] The roots of the polynomials $b_i^{x_j}(s)$ are in $[-1,0[$. \subsubsection*{Injectivity.} let us show that the natural morphism \[\mathcal{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})\to \mathcal{H}^kf_*(R_F\mathcal{M})\] is injective. We will show this by induction on the integer $p$, using property 7.5.8 of \cite{kaiserslautern}. We are going to show that the two following morphisms are injective: \[\mathcal{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M}) \underset{(1)}{\to} \mathcal{H}^kf_*(V^{\boldsymbol{H}_{2,\dots ,p}}_{\alpha_2,\dots ,\alpha_p}R_F\mathcal{M}) \underset{(2)}{\to} \mathcal{H}^kf_*(R_F\mathcal{M}),\] where $V^{\boldsymbol{H}_{2,\dots ,p}}_{\alpha_2,\dots ,\alpha_p}R_F\mathcal{M}$ is the canonical $V$-multifiltration associated to the $p-1$ functions $t_2,\dots ,t_p$. let us denote $\mathcal{N}^\bullet:=f_*(V^{\boldsymbol{H}_{2,\dots ,p}}_{\alpha_2,\dots ,\alpha_p}R_F\mathcal{M})$ equipped with the $V$-filtration $U_{\alpha_1}\mathcal{N}^\bullet:=f_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})$ for the hyperplane $\{t_1=0\}$. In order to consider $U_{\alpha_1}\mathcal{N}^\bullet$ as a sub-object of $\mathcal{N}^\bullet$, we use a definition of the functor $f_*$ involving explicit resolutions given in \cite[definition 4.3.3]{kaiserslautern}, namely $f_*R_F\mathcal{M}$ is the simple complex associated to the double complex \[f_*R_F\mathcal{M}:=f_*\textup{God}^\bullet\left(R_F\mathcal{M} \otimes_{R_F\mathscr{D}_{X\times\mathbb{C}^p}} \textup{Sp}^\bullet_{X\times\mathbb{C}^p\to Y\times\mathbb{C}^p}(R_F\mathscr{D}_{X\times\mathbb{C}^p})\right).\] Morphism (1) can be rewritten \[\mathcal{H}^k(U_{\alpha_1}\mathcal{N}^\bullet) \underset{(1)}{\to} \mathcal{H}^k(\mathcal{N}^\bullet).\] let us check the three hypothesis of property 7.5.8 of \cite{kaiserslautern}: \begin{enumerate} \item let us show that $\text{gr}^{U}\mathcal{N}^\bullet$ is strict, namely for all $k\in\mathbb{N}$, $\mathcal{H}^k\text{gr}^{U}\mathcal{N}^\bullet$ is strict. We have, thanks to the compatibility of the filtrations, $\mathcal{H}^k\text{gr}^{U}\mathcal{N}^\bullet=\mathcal{H}^kf_*(V^{\boldsymbol{H}_{2,\dots ,p}}_{\alpha_2,\dots ,\alpha_p}\text{gr}^{H_1}_{\alpha_1}R_F\mathcal{M})$. By definition of mixed Hodge modules, $\text{gr}^{H_1}_{\alpha_1}R_F\mathcal{M}$ also satisfy the hypothesis of the theorem. By induction we thus get \[\mathcal{H}^kf_*(V^{\boldsymbol{H}_{2,\dots ,p}}_{\alpha_2,\dots ,\alpha_p}\text{gr}^{H_1}_{\alpha_1}R_F\mathcal{M})\simeq V^{\boldsymbol{H}_{2,\dots ,p}}_{\alpha_2,\dots ,\alpha_p}\mathcal{H}^kf_*(\text{gr}^{H_1}_{\alpha_1}R_F\mathcal{M}). \] Following the direct image theorem \cite[Proposition 2.16]{SaitoMHM}, $\text{gr}^{H_1}_{\alpha_1}R_F\mathcal{M}$ underlying a mixed Hodge module, $\mathcal{H}^kf_*(\text{gr}^{H_1}_{\alpha_1}R_F\mathcal{M})$ is strict. Thus $\text{gr}^{U}\mathcal{N}^\bullet$ is strict. \item Strict $\mathbb{R}$-specialisability and $f$ being proper enable us to show, as above, the existence of cancelling polynomials of $\text{gr}^{U}\mathcal{N}^\bullet$ and thus the hypothesis of monodromy of property 7.5.8 of \cite{kaiserslautern}. \item By the definition of the canonical $V$-multifiltration, for $\alpha_1<0$, right multiplication by $t_1$ gives an isomorphism $t_1:U_{\alpha_1}\mathcal{N}^j\xrightarrow{\sim} U_{\alpha_1-1}\mathcal{N}^j$ for all $j$. \item Remark 4.3.4(4) of \cite{kaiserslautern} ensure that for $k>2\text{dim}X+p$ and for all $\alpha_1$, $\mathcal{H}^k(U_{{\alpha}_1}\mathcal{N}^\bullet)=0$. \end{enumerate} Thus, morphism (1) is injective. We apply the induction hypothesis to show that morphism (2) is injective. The natural morphism \begin{equation}\mathcal{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})\to \mathcal{H}^kf_*(R_F\mathcal{M}) \label{commutVbisH}\end{equation} is therefore injective. Thus we have \begin{equation}\label{commutVU} \mathcal{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})= U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M}) \end{equation} Furthermore property 7.5.8 of \cite{kaiserslautern} also provide the equality \begin{equation}\label{commutVUgr} \text{gr}_{\alpha_1}^{U_1}\mathcal{H}^kf_*(V_{\alpha_2,\dots ,\alpha_p}R_F\mathcal{M})= \mathcal{H}^kf_*(V_{\alpha_2,\dots ,\alpha_p}\text{gr}_{\alpha_1}^{V_1}R_F\mathcal{M}). \end{equation} \subsubsection*{Good $V$-multifiltration property.} let us show that the $V$-multifiltration \eqref{deffiltrH} is a good $V$-multifiltration. We have to show that, for all $\boldsymbol{\alpha}\in\mathbb{C}^p$, the $V$-multifiltration $U_{\boldsymbol{\alpha}+\bullet}(\mathcal{H}^kf_*(R_F\mathcal{M}))$ (indexed by $\mathbb{Z}^p$) is good. In order to lighten notations, we deal with the case $\boldsymbol{\alpha}=0$. Following \eqref{commutVU} we have \begin{equation} \mathcal{H}^kf_*(V_{{\boldsymbol{k}}}R_F\mathcal{M})\xrightarrow{\sim} U_{{\boldsymbol{k}}}(\mathcal{H}^kf_*(R_F\mathcal{M})). \end{equation} The compatibility property ensure that $V_{{\boldsymbol{k}}}R_F\mathcal{M}=R_F(V_{{\boldsymbol{k}}}\mathcal{M})$, thus $V_{{\boldsymbol{k}}}R_F\mathcal{M}$ is a coherent strict $V_{\boldsymbol{0}}\tilde{\mathscr{D}}_{Y\times\mathbb{C}^p}$-module. It is therefore filtered by the $\mathcal{O}_{Y\times\mathbb{C}^p}$-modules \[\sum_{0\leq \ell\leq p} F_\ell V_{{\boldsymbol{k}}}\mathcal{M}z^\ell \] that give a good filtration. Since $f$ is proper we can then apply Grauert coherence theorem to these $\mathcal{O}_{Y\times\mathbb{C}^p}$-modules. We deduce that $\mathcal{H}^kf_*(V_{{\boldsymbol{k}}}R_F\mathcal{M})$ is $V_{\boldsymbol{0}}\tilde{\mathscr{D}}_{Y\times\mathbb{C}^p}$-coherent. Thus, $U_{{\boldsymbol{k}}}(\mathcal{H}^kf_*(R_F\mathcal{M}))$ is $V_{\boldsymbol{0}}\tilde{\mathscr{D}}_{Y\times\mathbb{C}^p}$-coherent. We remark that, for all $1\leq i\leq p$ and ${\boldsymbol{k}}\in\mathbb{Z}^p$ satisfy $k_i\leq -1$, the isomorphism of multiplication by $t_i$ \[t_i:V_{\boldsymbol{k}}\mathcal{M}\xrightarrow{\sim} V_{\boldsymbol{k-1}_i}\mathcal{M}\] induce an isomorphism \begin{equation}t_i:U_{{\boldsymbol{k}}}(\mathcal{H}^kf_*(R_F\mathcal{M})) \xrightarrow{\sim} U_{\boldsymbol{k-1}_i}(\mathcal{H}^kf_*(R_F\mathcal{M})).\label{isotH}\end{equation} In order to lighten notations we will denote here $\mathfrak{M}$ instead of $R_F\mathcal{M}$. let us consider the short exact sequence \[0 \to V_{\boldsymbol{k-1}_i}\mathfrak{M} \to V_{{\boldsymbol{k}}}\mathfrak{M} \to V_{{\boldsymbol{k}}}\mathfrak{M}/V_{\boldsymbol{k-1}_i}\mathfrak{M}\to 0\] and let us apply the functor $f_*$. We get the associated long exact sequence, \begin{multline}\notag\dots \to\mathcal{H}^kf_*(V_{\boldsymbol{k-1}_i}\mathfrak{M}) \to \mathcal{H}^kf_*(V_{{\boldsymbol{k}}}\mathfrak{M}) \to \mathcal{H}^kf_*(V_{{\boldsymbol{k}}}\mathfrak{M}/V_{\boldsymbol{k-1}_i}\mathfrak{M})\to \\ \mathcal{H}^{k+1}f_*(V_{\boldsymbol{k-1}_i}\mathfrak{M}) \to \mathcal{H}^{k+1}f_*(V_{{\boldsymbol{k}}}\mathfrak{M})\to\dots \end{multline} Following \eqref{commutVbisH}, the first and last morphisms are injective, we thus get the short exact sequence \[0 \to U_{\boldsymbol{k-1}_i}\mathcal{H}^kf_*(\mathfrak{M}) \to U_{\boldsymbol{k}}\mathcal{H}^kf_*(\mathfrak{M}) \to \mathcal{H}^kf_*(V_{{\boldsymbol{k}}}\mathfrak{M} /V_{\boldsymbol{k-1}_i}\mathfrak{M})\to 0.\] let us consider the following commutative diagram: \[\xymatrix{0 \ar[r] & U_{\boldsymbol{k-1}_i}\mathcal{H}^kf_*(\mathfrak{M}) \ar[r] \ar[d]^{\cdot\eth_{t_i}} & U_{{\boldsymbol{k}}}\mathcal{H}^kf_*(\mathfrak{M}) \ar[r] \ar[d]^{\cdot\eth_{t_i}} & \mathcal{H}^kf_*(V_{{\boldsymbol{k}}}\mathfrak{M}/V_{\boldsymbol{k-1}_i}\mathfrak{M})\ar[r] \ar[d]^{\cdot\eth_{t_i}} & 0 \\ 0 \ar[r] & U_{{\boldsymbol{k}}}\mathcal{H}^kf_*(\mathfrak{M}) \ar[r] & U_{\boldsymbol{k+1}_i}\mathcal{H}^kf_*(\mathfrak{M}) \ar[r] & \mathcal{H}^kf_*(V_{\boldsymbol{k+1}_i}\mathfrak{M}/V_{{\boldsymbol{k}}}\mathfrak{M})\ar[r] & 0. }\] For $k_i\geq 0$, following the properties of the canonical $V$-multifiltration, the third vertical arrow of the diagram is an isomorphism. Using the snake lemma, we deduce that \[U_{\boldsymbol{k+1}_i}\mathcal{H}^kf_*(\mathfrak{M})= U_{{\boldsymbol{k}}}\mathcal{H}^kf_*(\mathfrak{M}) +U_{{\boldsymbol{k}}}\mathcal{H}^kf_*(\mathfrak{M})\cdot\eth_{t_i}.\] This result and the isomorphism \eqref{isotH} give the good $V$-multifiltration property of \[U_{{\bullet}}\mathcal{H}^kf_*(R_F\mathcal{M}).\] \subsubsection*{Graded pieces.} We are going to show that for all $I\subset\{1,\dots ,p\}$ and all $\boldsymbol{\alpha}\in\mathbb{R}^p$, \begin{equation}\label{commutUgrV} \frac{U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M})}{U_{<\boldsymbol{\alpha}_{I},\boldsymbol{\alpha}_{I^c}}\mathcal{H}^kf_*(R_F\mathcal{M})}\simeq U_{\boldsymbol{\alpha}_{I^c}}\mathcal{H}^kf_* (\textup{gr}_{\boldsymbol{\alpha}_I}^{\mathbf{H}_I}R_F\mathcal{M}). \end{equation} We use an induction on the cardinality if $I$. Upon renumbering we can suppose that $1\in I$. If we omit to write $\mathcal{H}^kf_*(R_F\mathcal{M})$ we have \begin{equation}\label{divis} \frac{U_{\boldsymbol{\alpha}}}{U_{<\boldsymbol{\alpha}_{I},\boldsymbol{\alpha}_{I^c}}}= \left. \frac{U_{\boldsymbol{\alpha}}}{U_{<\alpha_1,\boldsymbol{\alpha}_{\{1\}^c}}} \middle/\sum_{i\in I-\{1\}} \frac{U_{\alpha_1,\dots ,<\alpha_i,\dots }}{U_{<\alpha_1,\dots ,<\alpha_i,\dots }} \right. \end{equation} Following \eqref{commutVU}, \eqref{commutVUgr} and the compatibility of the canonical filtrations of $R_F\mathcal{M}$ we have \[ \frac{U_{\boldsymbol{\alpha}}}{U_{<\alpha_1,\boldsymbol{\alpha}_{\{1\}^c}}}= \text{gr}_{\alpha_1}^{U_1}\mathcal{H}^kf_*(V_{\alpha_2,\dots ,\alpha_p}R_F\mathcal{M})= \mathcal{H}^kf_*(V_{\alpha_2,\dots ,\alpha_p}\text{gr}_{\alpha_1}^{V_1}R_F\mathcal{M})= U_{\alpha_2,\dots ,\alpha_p}\mathcal{H}^kf_*(\text{gr}_{\alpha_1}^{V_1}R_F\mathcal{M}). \] In the same way we get, using \eqref{divis}, \[\frac{U_{\boldsymbol{\alpha}}}{U_{<\boldsymbol{\alpha}_{I},\boldsymbol{\alpha}_{I^c}}}= \frac{U_{\boldsymbol{\alpha}_{ \{1\}^c}}\mathcal{H}^kf_*(\text{gr}_{\alpha_1}^{V_1}R_F\mathcal{M})} {U_{<\boldsymbol{\alpha}_{I-\{1\}},\boldsymbol{\alpha}_{I^c}}\mathcal{H}^kf_*(\text{gr}_{\alpha_1}^{V_1}R_F\mathcal{M})}. \] Since $\text{gr}_{\alpha_1}^{V_1}R_F\mathcal{M}$ stisfy the hypothesis of the theorem we have, using the induction hypothesis, \[\frac{U_{\boldsymbol{\alpha}}\mathcal{H}^kf_*(R_F\mathcal{M})}{U_{<\boldsymbol{\alpha}_{I},\boldsymbol{\alpha}_{I^c}}\mathcal{H}^kf_*(R_F\mathcal{M})}= U_{\boldsymbol{\alpha}_{I^c}}\mathcal{H}^kf_* (\textup{gr}_{\boldsymbol{\alpha}_{I-\{1\}}}^{\mathbf{H}_{I-\{1\}}}\text{gr}_{\alpha_1}^{V_1}R_F\mathcal{M})= U_{\boldsymbol{\alpha}_{I^c}}\mathcal{H}^kf_* (\textup{gr}_{\boldsymbol{\alpha}_I}^{\mathbf{H}_I}R_F\mathcal{M}) \] where the last equality follow from the compatibility of the filtrations. \subsubsection*{Canonical $V$-multifiltration properties.} let us show that the $V$-multifiltration $U_{{\bullet}}\mathscr{H}^kf_*(R_F\mathcal{M})$ satisfies the properties of definition \ref{defmultstrict} of the canonical $V$-multifiltration. We have already shown the propertiy of good $V$-multifiltration. Following the isomorphism \eqref{commutUgrV}, the module \[\frac{U_{\boldsymbol{\alpha}}\mathscr{H}^kf_*(R_F\mathcal{M})}{U_{<\boldsymbol{\alpha}_{I},\boldsymbol{\alpha}_{I^c}}\mathscr{H}^kf_*(R_F\mathcal{M})}\] is a sub-object of $\mathscr{H}^kf_* (\textup{gr}_{\boldsymbol{\alpha}_I}^{\mathbf{H}_I}R_F\mathcal{M})$. Yet, since $R_F\mathcal{M}$ underlies a mixed Hodge module, $\textup{gr}_{\boldsymbol{\alpha}_I}^{\mathbf{H}_I}R_F\mathcal{M}$ also do. Thus its direct image is strict and we deduce that \[\frac{U_{\boldsymbol{\alpha}}\mathscr{H}^kf_*(R_F\mathcal{M})}{U_{<\boldsymbol{\alpha}_{I},\boldsymbol{\alpha}_{I^c}}\mathscr{H}^kf_*(R_F\mathcal{M})}\] is strict for all $I\subset\{1,\dots ,p\}$ and all $\boldsymbol{\alpha}\in \mathbb{R}^p$. We deduce surjectivity properties of the multiplication by $t_i$ and $\eth_i$ from the isomorphism \[\mathscr{H}^kf_*(\text{gr}_{\boldsymbol{\alpha}}R_F\mathcal{M})\simeq \text{gr}^{U}_{\boldsymbol{\alpha}}\mathscr{H}^kf_*(R_F\mathcal{M}),\] and from the following facts \begin{itemize} \item for all $1\leq i\leq p$ and all $\alpha_i<0$, the morphism $t_i:\textup{gr}_{\boldsymbol{\alpha}}R_F\mathcal{M}\to \textup{gr}_{\boldsymbol{\alpha-1}_i}R_F\mathcal{M}$ is an isomorphism, \item for all $1\leq i\leq p$ and all $\alpha_i>-1$, the morphism $\eth_i:\textup{gr}_{\boldsymbol{\alpha}}R_F\mathcal{M}\to \textup{gr}_{\boldsymbol{\alpha+1}_i}R_F\mathcal{M}(-1)$ is an isomorphism. \end{itemize} Thus, the $V$-multifiltration \[U_{{\bullet}}\mathscr{H}^kf_*(R_F\mathcal{M})\] is the canonical $V$-multifiltration, $\mathscr{H}^kf_*(R_F\mathcal{M})$ is therefore strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}$ and we have the following isomorphisms \[ \mathscr{H}^kf_*(V_{\boldsymbol{\alpha}}R_F\mathcal{M})\simeq V_{\boldsymbol{\alpha}}\mathscr{H}^kf_*(R_F\mathcal{M}) \] and \[ \mathscr{H}^kf_*(\text{gr}^V_{\boldsymbol{\alpha}}R_F\mathcal{M})\simeq \text{gr}^V_{\boldsymbol{\alpha}}\mathscr{H}^kf_*(R_F\mathcal{M}). \] \end{proof} \section{The direct image of relative monodromy filtrations} Let $X$ be a complex manifold, $\mathscr{M}\in \textup{MH}(X\times \mathbb{C}^p_{\boldsymbol{t}})$ a pure Hodge module on $X\times \mathbb{C}^p_{\boldsymbol{t}}$ and $S(.,.)$ a polarisation of $\mathscr{M}$. We suppose that $\mathscr{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}$ where $H_i:=\{t_i=0\}$. The mixed Hodge module $\Psi_{\boldsymbol{t}}\mathscr{M}$ is equipped with $p$ nilpotent endomorphisms $N_i$, for $1\leq i\leq p$. \begin{defi} Let $A$ be an object in and abelian category equipped with $p$ nilpotent endomorphisms $N_1,\dots ,N_p$. We say that $(A,N_1,\dots ,N_p)$ satisfy property $(MF)$ if the relative monodromic filtrations (definition \ref{defifiltmonorelat}) satisfy \[W(N_1,W(N_2,W(\dots W(N_p))))A=W(N_1+\dots +N_p)A.\] \end{defi} \begin{rema} Following \cite[4.12]{NilpSchmid} and \cite[Proposition 4.72]{CKS} this condition is satified in the case of a nilpotent orbit. \end{rema} \begin{theo}\label{imagedirecteW} Let $f:X\times \mathbb{C}^p_{\boldsymbol{t}}\to Y\times \mathbb{C}^p_{\boldsymbol{t}}$ be a projective morphism and let us supose that $(\Psi_{\boldsymbol{t}}\mathscr{M},N_1,\dots ,N_p)$ satisfy property $(MF)$, then $(\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M},N_1,\dots ,N_p)$ also satisfy $(MF)$. \end{theo} First we will prove a lemma. \begin{lemm}\label{pHLP} Let $(\mathscr{M},N_1,\dots ,N_p,S)$ be a polarized $p$-graded Hodge-Lefschetz module with polarization $S$ (definition \ref{defiMHLP}). If we define the $(p-1)$-graduation \[\mathscr{M}_{\ell,\ell_3,\dots ,\ell_p}=\bigoplus_{\ell_1+\ell_2=\ell} \mathscr{M}_{\ell_1,\ell_2,\ell_3,\dots ,\ell_p},\] then $(\mathscr{M},N_1+N_2,N_3,\dots ,N_p,S)$ is a polarized graded Hodge-Lefschetz module with polarization $S$. \end{lemm} \begin{proof} We will make an induction on the dimension of the support of $\mathscr{M}$. Using Kshiwara equivalence, the $0$ dimension case correspond to the case of polarised Hodge-Lefschetz structures of proposition \ref{SHLP}. Let $g$ be a germ of holomorphic function. The definition by induction \ref{defiMHL} of polarised graded H-L modules implies that \[(P_\ell\Psi_{g,\lambda}\mathscr{M},P_\ell\Psi_{g,\lambda}N_1,\dots ,P_\ell\Psi_{g,\lambda}N_p,N,P_\ell\Psi_{g,\lambda}S) \] is a $(p+1)$-graded polarised H-L module. Locally, we have a decomposition \[\mathscr{M}=\bigoplus_{Z}\mathscr{M}_Z \] where $Z$ is irreducible and $\mathscr{M}_Z$ has strict support $Z$. If $g$ is zero on $Z$, then $\Psi_{g,\lambda}\mathscr{M}_Z=0$ for all $\lambda$, otherwise $\Psi_{g,\lambda}\mathscr{M}_Z$ has codimension $1$ support in $Z$. Thus dimension of the support has strictly decrease and, by induction, we get that \[\begin{array}{cll} & & (P_\ell\Psi_{g,\lambda}\mathscr{M},(P_\ell\Psi_{g,\lambda}N_1+P_\ell\Psi_{g,\lambda}N_2), P_\ell\Psi_{g,\lambda}N_3,\dots ,P_\ell\Psi_{g,\lambda}N_p,N,P_\ell\Psi_{g,\lambda}S)\\ & = & (P_\ell\Psi_{g,\lambda}\mathscr{M},P_\ell\Psi_{g,\lambda}(N_1+N_2),P_\ell\Psi_{g,\lambda}N_3,\dots ,P_\ell\Psi_{g,\lambda}N_p,N,P_\ell\Psi_{g,\lambda}S) \end{array} \] is a bigraded polarised H-L module. Thus, $(\mathscr{M},N_1+N_2,N_3,\dots ,N_p,S)$ satisfies the inductive definition of graded polarised Hodge-Lefschetz modules. \end{proof} \begin{proof}[Proof of theorem \ref{imagedirecteW}] We have to prove that \begin{equation}\label{pfiltW} W(N_1,W(N_2,W(\dots W(N_p))))\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M} =W(N_1+\dots +N_p)\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M}. \end{equation} let us denote $\mathscr{N}:=\Psi_{\boldsymbol{t}}\mathscr{M}$ and $W\mathscr{N}:=W(N_1,W(N_2,W(\dots W(N_p))))\mathscr{N}=W(N_1+\dots +N_p)\mathscr{N}$. Following the strict $\mathbb{R}$-multispecialisability and theorem \ref{commutVgrH}, we have \[\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M}\simeq \mathscr{H}^jf_*\Psi_{\boldsymbol{t}}\mathscr{M}=\mathscr{H}^jf_*\mathscr{N}. \] We define the following filtration: \begin{equation}\label{pdefW} W\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M}:= \text{Im}(\mathscr{H}^jf_*W\mathscr{N}\to \mathscr{H}^jf_*\mathscr{N}). \end{equation} We are going to show that this filtration is the same as the two filtrations of \eqref{pfiltW}. Following \cite[Theorem 5.3.1 and Proposition 5.3.4]{HM1}, the filtration \[\text{Im}(\mathscr{H}^jf_*W(N_p)\Psi_{t_p}\mathscr{M}\to \mathscr{H}^jf_*\Psi_{t_p}\mathscr{M}) \] of $\mathscr{H}^jf_*\Psi_{t_p}\mathscr{M}$ is the filtration associated to $N_p$. Furthermore, by definition of pure Hodge modules, we can consider the mixed Hodge module $(\Psi_{t_p}\mathscr{M},W(N_p))$. Proposition 2.16 of \cite{SaitoMHM} for mixed Hodge modules ensure that the filtration \[\text{Im}(\mathscr{H}^jf_*W(N_{p-1},W(N_p))\Psi_{t_{p-1}} \Psi_{t_p}\mathscr{M}\to \mathscr{H}^jf_*\Psi_{t_{p-1}}\Psi_{t_p}\mathscr{M}) \] is equal to \[W(N_{p-1},W(N_{p}))\Psi_{t_{p-1}}\mathscr{H}^jf_* \Psi_{t_p}\mathscr{M}\simeq W(N_{p-1},W(N_{p}))\Psi_{t_{p-1}}\Psi_{t_p}\mathscr{H}^jf_* \mathscr{M}.\] Thus, using an induction and applying direct image theorems at each step, we can get the equality between the first filtration of \eqref{pfiltW} and the filtration \eqref{pdefW}: \begin{equation}\label{pegal1} W\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M}\simeq W(N_1,W(N_2,W(\dots W(N_p))))\Psi_{\boldsymbol{t}} \mathscr{H}^jf_*\mathscr{M}. \end{equation} For the second filtration of \eqref{pfiltW}, we are going to use lemma \ref{pHLP}. let us consider the following polarized bigraded H-L module: \[\left(\bigoplus_{\boldsymbol{\ell}} \textup{Gr}_{\ell_1}^{W(N_1)}\dots \textup{Gr}_{\ell_p}^{W(N_p)}\mathscr{N}, N_1,\dots ,N_p, S\right). \] Iterating \cite[Theorem 3.2.9]{Kash86}, we get \begin{equation} \textup{Gr}_{\ell}^{W(N_1,W(N_2,W(\dots W(N_p))))}\mathscr{N} = \bigoplus_{k_1+\dots +k_p=\ell} \textup{Gr}_{k_1}^{W(N_1)}\dots \textup{Gr}_{k_p}^{W(N_p)}\mathscr{N}. \end{equation} The equality $W(N_1,W(N_2,W(\dots W(N_p))))\mathscr{N}=W(N_1+\dots +N_p)\mathscr{N}$ and lemma \ref{pHLP} imply that \[ \left(\bigoplus_{\ell} \textup{Gr}_{\ell}^{W(N_1+\dots +N_p)}\mathscr{N}, N_1+\dots +N_p, S\right) \] is a polarized graded H-L module. The direct image theorem \cite[Proposition 5.3.5]{HM1} ensure then that the filtration \[\text{Im}(\mathscr{H}^jf_*W(N_1+\dots +N_p)\mathscr{N}\to \mathscr{H}^jf_*\mathscr{N})\] is equal to the monodromy filtration \[W(N_1+\dots +N_p)\mathscr{H}^jf_*\mathscr{N}.\] Thus we have the equality \begin{equation}\label{pegal2} W\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M}\simeq W(N_1+\dots +N_p)\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M}. \end{equation} Combining \eqref{pegal1} and \eqref{pegal2}, we get the expected equality \[W(N_1,W(N_2,W(\dots W(N_p))))\Psi_{\boldsymbol{t}} \mathscr{H}^jf_*\mathscr{M} =W(N_1+\dots +N_p)\Psi_{\boldsymbol{t}}\mathscr{H}^jf_*\mathscr{M}.\] \end{proof} \section{Quasi-ordinary hypersurface singularities} We apply here the above results to some mixed Hodge modules with support a quasi-ordinary hypersurface singularity. \begin{defi} A germ of a complex analytic space $(Z,0)$ of dimension $p$ is a \emph{quasi-ordinary} singularity if there exists a finite projection $(Z,0)\to (\mathbb{C}^{p},0)$ unramified outside a normal crossing divisor in $(\mathbb{C}^{p},0)$. If $(Z,0)$ is a irreducible quasi-ordinary hypersurface singularity, then there exists a parametrisation \[\begin{array}{ccccc} y & :& \mathbb{C}^p_{\boldsymbol{t}} & \to & \mathbb{C}^{p+1}_{\boldsymbol{z}}\\ & & (t_1,\dots ,t_p) & \mapsto & (t_1^k,\dots ,t_p^k,H(t_1,\dots ,t_p)) \end{array}\] where $H$ is a convergent series. \end{defi} Let $D:=\{t_1\dots t_p=0\}\subset \mathbb{C}^p_{\boldsymbol{t}}$ and $U:=\mathbb{C}^p_{\boldsymbol{t}} \setminus D$. \begin{prop} Let $(\mathcal{M},F_\bullet\mathcal{M})$ be a filtered $\mathscr{D}_X$-module underlying a polarizable pure Hodge module $\mathscr{M}$ with strict support $\mathbb{C}^p_{\boldsymbol{t}}$ and with smooth restriction to $U$ (in other words $\mathscr{M}$ is the intermediate extension of a polarised variation of Hodge structures with support $U$). Then the direct image $y_+R_F\mathcal{M}$, wich also underlies a polarizable pure Hodge module, is strictly $\mathbb{R}$-multispecialisable along the family $\mathbf{H}_{\boldsymbol{z}}$ where $H_{z_i}:=\{z_i=0\}$ pour $1\leq i\leq p$. Furthermore, for all $j\in\mathbb{Z}$, the Hodge-Lefschetz module $(\textup{gr}_{\boldsymbol{\alpha}}^{V}\mathscr{H}^jy_+\mathscr{M},N_1,\dots ,N_p)$, satisfies property $(FM)$. \end{prop} \begin{proof} let us consider the family of hyperplanes $\mathbf{H}_{\boldsymbol{t}}$ given by the coordinate hyperplanes $H_{t_i}:=\{t_i=0\}$ for $1\leq i\leq p$. Following \cite[3.b]{SaitoMHM}, the filtrations of $\mathcal{M}$ $(F_\bullet\mathcal{M},V^{H_{t_1}}_\bullet\mathcal{M},\dots ,V^{H_{t_i}}_\bullet\mathcal{M})$ are compatible. Moreover, using definition \cite[Théorème 3]{Maisonobe}, we get that $\mathcal{M}$ is $\mathbb{R}$-multispecialisable along $\mathbf{H}_{\boldsymbol{t}}$. Following proposition \ref{compatstrict}, $R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_{\boldsymbol{t}}$. Let \[\begin{array}{ccccc} i & :& \mathbb{C}^p_{\boldsymbol{t}} & \to & \mathbb{C}^p_{\boldsymbol{t}}\times\mathbb{C}^{p}_{\boldsymbol{z}}\\ & & (t_1,\dots ,t_p) & \mapsto & (t_1,\dots ,t_p,t_1^k,\dots ,t_p^k), \end{array}\] be the inclusion by the graph map. Following \cite[Théorème 3.4]{SaitoMHM}, $i_+R_F\mathcal{M}$ is also strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_{\boldsymbol{z}}$. Following theorem \ref{commutVgrH}, $(y\times id_{\mathbb{C}_{\boldsymbol{z}}^p})_+i_+R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_{\boldsymbol{z}}$. Yet, $(y\times id_{\mathbb{C}_z^p})\circ i=j\circ y$ where \[\begin{array}{ccccc} j & :& \mathbb{C}^{p+1}_{\boldsymbol{z}} & \to & \mathbb{C}^{p+1}_{\boldsymbol{z}}\times\mathbb{C}^{p}_{\boldsymbol{z}}\\ & & (z_1,\dots ,z_{p+1}) & \mapsto & (z_1,\dots ,z_{p+1},z_1,\dots ,z_p) \end{array}\] is the inclusion of the graph of the projection on the $p$ first coordinates. Thus $j_+y_+R_F\mathcal{M}$ is strictly $\mathbb{R}$-multispecialisable along $\mathbf{H}_{\boldsymbol{z}}$. Following the nilpotent orbit theorem \cite[4.12]{NilpSchmid} and \cite[Proposition 4.72]{CKS},$(\textup{gr}_{\boldsymbol{\alpha}}^{V}\mathscr{M},N_1,\dots ,N_p)$ satisfy property $(FM)$. Theorem \ref{imagedirecteW} implies then that $(\textup{gr}_{\boldsymbol{\alpha}}^{V}\mathscr{H}^jy_+\mathscr{M},N_1,\dots ,N_p)$ satisfy property $(FM)$. \end{proof} \begin{coro} With the notation of the above proposition, the filtrations \[(F_\bullet y_+\mathcal{M},V^{H_{z_1}}_\bullet y_+\mathcal{M},\dots , V^{H_{z_i}}_\bullet y_+\mathcal{M})\] are compatible. \end{coro} \begin{proof} This is a consequence of theorem \ref{commutVgrH} and proposition \ref{strictmulcompat}. \end{proof}
\chapter{A simple approach to genuine multipartite nonlocality of pure states}\label{Chapter:GenuineGisin} \section{Introduction} Quantum theory is rich in features that defy classical intuition. Systems of several particles are particularly interesting in that sense, with quantum systems exhibiting more intricate correlations than those possible within classical ones. For instance, some composite quantum systems can not be specified by the state of their parts alone, but require a global description -- a phenomenon known as \textit{quantum entanglement}. When the parts of such entangled systems are separated at a distance, and local (independent) measurements are made on them, the distribution of outcomes can exhibit \textit{nonlocal correlations}, in the sense that they cannot be explained by the existence of a (possibly hidden) classical common cause~\cite{EPR,Bell}. Apart from their fundamental interest, quantum entanglement and quantum nonlocality have been identified as key resources for Quantum Information Science. Nonlocal correlations have been extensively studied in the simplest scenario of bipartite systems, which is sufficient to obtain powerful resources for information tasks with no classical equivalent: randomness expansion~\cite{colbeck2009quantum, ColbeckExpansion, Randomness} and amplification~\cite{ColbeckAmplification}, distribution of secret keys in a provably secure way~\cite{EkertQKD, barrett2005no, acin2007device} or testing the functioning of devices with minimal assumptions on their internal machinery~\cite{MayersSelfTesting}, for example. Multipartite scenarios -- consisting of set-ups with at least three parties -- have received far less attention due to their greater complexity. They offer, however, a much richer source of correlations than the bipartite set-up, and have already been proven useful for several tasks. Either for a better use of the potential provided by multipartite systems -- which might be particularly interesting for tasks on quantum networks -- or simply to explore scenarios that go beyond the standard bipartite set-up, the study of multipartite scenarios is nowadays a central problem~\cite{Svetlichny,Svetlichny2,Gallego:PRL:070401,Bancal:PRA:014102,BancalDIEW,gallego2013full,bancal2014quantum,BoudaRandomness,Jordi} A detailed study of correlations in the multipartite scenario is an increasingly demanding task, as the complexity of the possible states of the systems and sets of correlations grows exponentially with the number of parties. A common approach to characterise multipartite correlations consists of testing whether they can be reproduced by models in which the parties share different physical resources (classical, quantum or post-quantum correlations)~\cite{Svetlichny,BancalQuantifying,Bancal:PRA:014102,Gallego:PRL:070401}. These models range from completely classical -- where all parties can only share classical correlations, to \emph{genuine multipartite} -- where all parties are required to be non-classically correlated. Intermediate models include, for instance, hybrid models where non-classical correlations are allowed inside groups of the parties, but the different groups can only be correlated classically between each other ~\cite{Bancal:PRA:014102}. Although families of Bell inequalities that provide insight on the rich structure of multipartite scenario have been built \cite{Svetlichny,BancalQuantifying,Bancal:PRA:014102}, we are far from a complete characterisation of multipartite correlations. Understanding the precise relation between entanglement and nonlocality in the multipartite scenario is of particular interest. While quantum entanglement is necessary for the display of quantum nonlocality, it is not sufficient. Indeed, there exist entangled mixed states for which single local measurements never generate nonlocal correlations \cite{Werner,BarrettPOVM}. Remarkably, bipartite systems in a pure quantum state display a straighforward relation between entanglement and nonlocality: all pure entangled bipartite states are nonlocal, a result known as Gisin's Theorem ~\cite{GisinThrm}. This result has been extended to the multipartite scenario ~\cite{PopescuGeneric,PopescuErratum}, with the caveat that the used definitions of entanglement and nonlocality do not capture any truly multipartite features (with these definitions, a multipartite system is said to be non-classically correlated if at least two parties share non-classical correlations). Partial results have been obtained for the genuine multipartite (GM) notions of entanglement and nonlocality: all three-qubit systems in a GM entangled (GME) pure state are GM nonlocal (GMNL), as well as any $n$-qubit systems in a fully-symmetric GME pure state~\cite{Yu3,Chinese1}. However, these results rely on the use of GM Hardy-type paradoxes ~\cite{Hardy}, which have the drawback of not allowing for experimental tests, contrary to nonlocal correlations detected by the violation of a Bell inequality. In this work we introduce a new technique to build Bell inequalities for the detection of truly multipartite nonlocal correlations, in a no-signalling framework \cite{Bancal:PRA:014102}. These inequalities have a very clear operational meaning and capture essential features of multipartite nonlocality. Our construction takes a ``seed'' -- a Bell inequality that fulfils certain constraints -- to generate Bell inequalities for an arbitrary number of parties. The inequalities can be designed to detect $m$-way nonlocality, for any $2 \leq m \leq n$, including the extreme case of GMNL ($m=2$). We illustrate the potential of the method by constructing several families of multipartite Bell inequalities from different seeds and for different notions of multipartite nonlocality. Our technique is particularly fit for the detection of multipartite nonlocal correlations of pure states. Indeed, using the CHSH inequality~\cite{CHSH} as the seed, we design two families of Bell inequalities, $I_{\textrm{sym}}$ and $I_{\textrm{\ding{192}}}$ that detect GMNL in large classes of GME pure states. Note that the CHSH inequality has already been used to prove the equivalence between pure state entanglement and nonlocality for bipartite systems~\cite{GisinThrm}. Moreover, for three parties, $I_{\textrm{sym}}$ coincides with a Bell inequality obtained in \cite{Bancal:PRA:014102}, for which the authors found numerical evidence that the equivalence holds for all three-qubit states. Here we show analytically that, for any number of parties, all pure GHZ-like states that are GME contain GMNL correlations detected by $I_{\textrm{sym}}$, even almost separable states. We supplement these analytical results by providing numerical evidence that all four-qubit systems in a GME pure state violate $I_{\textrm{sym}}$. In the tripartite scenario, using $I_{\textrm{\ding{192}}}$, we also show analytically that all pure states symmetrical under the permutation of two parties are GMNL. The partial results obtained added to the operational meaning of our construction lead us to conjecture that the family of Bell inequalities $I_{\textrm{sym}}$ can be used to generalise Gisin's theorem, proving that all GME pure states are GMNL. \\ \section{The tripartite scenario} We start by introducing the main concepts used in this work and our results for the tripartite scenario, which is the simplest multipartite scenario for the observation of nonlocal correlations. This scenario counts with three distant observers $A_i$, $i\in\{1,2,3\}$ making rounds of measurements on multipartite quantum systems. At each round, the choice of local measurement performed by each party is labelled $x_i$ and the obtained outcome $a_i$. The generated joint conditional probability distribution $P(a_1a_2a_3|x_1x_2x_3)$ is then said to be \textit{local} if it factorises, given the additional knowledge of a (possibly hidden) common classical cause $\lambda$: \begin{equation}\begin{split}\label{FullyLocal} P_{\mathcal{L}}(a_1a_2a_3|x_1x_2x_3) \\ =\sum\limits_{\lambda} q(\lambda) P_{A_1}(a_1|x_1,\lambda) P_{A_2}(a_2|x_2,\lambda)& P_{A_3}(a_3|x_3,\lambda) \end{split}\end{equation} The common cause $\lambda$ is a discrete random variable with distribution $q(\lambda) \geq 0$, $\sum\limits_{\lambda} q(\lambda) = 1$, and $P_{A_i}(a_i|x_i,\lambda)$ is a probability distribution for party $A_i$. A distribution $P(a_1a_2a_3|x_1x_2x_3)$ that does not allow for a decomposition \eqref{FullyLocal} is said to be \emph{nonlocal}. Note that this definition of locality for three parties is a straightforward generalisation of the bipartite scenario, where the only difference is the addition of a third party. Because of the measurement arrangements it is assumed that the \emph{no-signalling (NS)} principle~\cite{GhirardiNS} holds, i.e. party $A_1$ cannot signal to the other parties by performing a choice of measurement \begin{equation}\begin{split}\label{NScond} P(a_2a_3|x_2x_3) \equiv P(a_2a_3|x_1x_2x_3)\\=\sum_{a_1}P(a_1a_2a_3|x_1x_2x_3), \hspace{0.2cm} \forall x_1 \end{split}\end{equation} and similarly for parties $A_2$ and $A_3$. The notion of separability for a tripartite pure state $\ket{\psi_{123}}$ is also a direct extension of the bipartite case, $\ket{\psi_{123}}=\ket{\phi_1}\ket{\phi_2}\ket{\phi_3}$, where $\ket{\phi_{i}}$ is the state of party $A_i$. The state $\ket{\psi_{123}}$ is then entangled whenever it does not admit for the previous decomposition. In that case, it is already known to be nonlocal, as there always exist local measurements on it that lead to a nonlocal joint distribution \cite{PopescuGeneric}. This equivalence between pure state entanglement and nonlocality is however essentially the same as for bipartite systems \cite{GisinThrm}, since it only requires two parties to be entangled.\\ Here we are interested in genuinely multipartite definitions of entanglement and nonlocality. As first noticed by Svetlichny~\cite{Svetlichny}, distributions generated in a tripartite scenario lead to stronger notions of nonlocality. Consider for instance a relaxation of the locality assumption, where pairs of parties are now allowed to group together and share nonlocal resources. This type of hybrid local/nonlocal models leads to joint conditional probability distributions \begin{equation}\begin{split}\label{GenuineNonlocal} P_{2/1}(a_1a_2a_3|x_1x_2x_3)& = \\ = \sum\limits_{\lambda_1} q_1(\lambda_1) P_{A_1A_2}(a_1a_2|x_1x_2,\lambda_1) & P_{A_3}(a_3|x_3,\lambda_1)\\ + \sum\limits_{\lambda_2} q_2(\lambda_2) P_{A_1A_3}(a_1a_3|x_1x_3,\lambda_2) & P_{A_2}(a_2|x_2,\lambda_2)\\+ \sum\limits_{\lambda_3} q_3(\lambda_3) P_{A_2A_3}(a_2a_3|x_2x_3,\lambda_3) & P_{A_1}(a_1|x_1,\lambda_3) \end{split}\end{equation} with $q_i(\lambda_i) \geq 0$ and $\sum\limits_{i_,\lambda_i} q_i(\lambda_i)= 1$. Distributions $P(a_1a_2a_3|x_1x_2x_3)$ that cannot be decomposed in the form \eqref{GenuineNonlocal} are named \emph{genuine tripartite nonlocal}. As shown in \cite{Gallego:PRL:070401}, the original notion of multipartite nonlocality by Svetlichny \cite{Svetlichny} faces operational problems. To avoid these, one assumes that the no-signalling principle~\cite{NS} also holds at the level of distributions $P_{A_iA_j}(a_ia_j|x_ix_j,\lambda)$, which implies that the marginals $P(a_i|x_i,\lambda) = P(a_i|x_ix_j,\lambda) = \sum_{a_j} P(a_ia_j|x_ix_j,\lambda), \hspace{0.2cm} \forall x_j$, are well defined for all $\lambda$. In analogy, a tripartite system is said to be in a genuine tripartite entangled pure state if it can not be decomposed as $\ket{\psi_{123}}=\ket{\phi_{ij}}\ket{\phi_k}$, where $ijk$ is any combination of the parties. One can easily verify that local measurements on biseparable states always lead to a hybrid joint distribution \eqref{GenuineNonlocal}.\\ Before introducing our inequalities witnessing genuine tripartite nonlocal correlations, recall that a Bell inequality is described by a bounded linear combination of probability terms \begin{equation}\label{Bellineq} \sum_{\vec{a},\vec{x}}c_{\vec{a},\vec{x}}P(\vec{a}|\vec{x})\leq \mathcal B \end{equation} in a experiment with $n$ parties, where the number of observables $\vec{x}=(x_1,x_2,\ldots,x_n)$ and respective outcomes $\vec{a}=(a_1,a_2,\ldots,a_n)$ is fixed. The coefficients $c_{\vec{a},\vec{x}}$ are real numbers and $\mathcal B$ is the maximum attained by local or hybrid distributions, according to the problem. In the bipartite scenario, where each party has two choices of two-outcome measurements, i.e. $x_i,a_i\in\{0,1\}$ for $i=1,2$, the violation of the CHSH inequality is both necessary and sufficient for $P(a_1a_2|x_1x_2)$ to be nonlocal~\cite{CHSH,FroissartSingleCHSH,FineSingleCHSH}. This is also the inequality used to show that all pure bipartite entangled states are nonlocal~\cite{GisinThrm}. Here we use a variant of the CHSH inequality, \begin{equation}\label{IA1A2} I^{A_1A_2}= P(00|00)-P(01|01)-P(10|10)-P(00|11) \leq 0 \end{equation} that, for no-signalling distributions, is equivalent to the standard expression \begin{equation}\label{StandardCHSH} \textrm{CHSH} = \langle A_0B_0 \rangle + \langle A_1B_0 \rangle + \langle A_0B_1 \rangle - \langle A_1B_1 \rangle \leq 2 \end{equation} where $\langle A_xB_y \rangle = \sum\limits_{ab} P(a=b|xy)-P(a\neq b|xy)$. \section{Bell inequalities for genuine tripartite nonlocality} We start by exemplifying our method through the construction of two Bell inequalities witnessing genuine tripartite nonlocal correlations. In both cases, we use the CHSH inequality \eqref{IA1A2} as the seed. The main idea is to make enough pairs of parties to play the nonlocal game defined by the seed, such the inequality can only be violated by genuine tripartite correlations. The first inequality is symmetrical under permutation of the three parties , \begin{equation}\begin{split}\label{IA1A2A3sym} I^{A_1A_2A_3}_{\textrm{sym}} = I^{A_1A_2}_{0|0}+I^{A_1A_3}_{0|0}+I^{A_2A_3}_{0|0}-P(000|000) \leq 0 \end{split}\end{equation} and the second inequality is symmetrical under the permutation of parties $A_2$ and $A_3$, \begin{equation}\begin{split}\label{IA1A2A3} I^{A_1A_2A_3}_{\textrm{\ding{192}}} = I^{A_1A_2}_{0|0}+I^{A_1A_3}_{0|0}-P(000|000) \leq 0 \end{split}\end{equation} where the term \begin{equation}\begin{split}\label{I3Liftee} I^{A_1A_2}_{0|0} \equiv P(000|000)-P(010|010)-P(100|100)\\ -P(000|110) \end{split}\end{equation} represents the \textit{lifting}~\cite{Pironio:Lifting} of the seed $I^{A_1A_2}$ \eqref{IA1A2} to the tripartite scenario, by setting observer $A_3$ to measurement $x_3=0$ and outcome $a_3=0$ (and similarly for the terms $I^{A_1A_3}_{0|0} $ and $I^{A_2A_3}_{0|0}$). Intuitively, in $I^{A_1A_2A_3}_{\textrm{sym}}$ every pair of parties plays a (lifted) CHSH game while in $I^{A_1A_2A_3}_{\textrm{\ding{192}}}$ party $A_1$ acquires a central role by playing a CHSH game with every remaining party. Note that the local bound of the lifted inequalities remains the same as the local bound for the seed, $I^{A_iA_j}_{0|0}\leq0$. See Appendix \ref{APP1:liftings} for the proof of this property and more details on lifted Bell inequalities. \begin{theorem}\label{3partyisGMNL} The Bell inequalities $I^{A_1A_2A_3}_{\textrm{sym}}$ \eqref{IA1A2A3sym} and $I^{A_1A_2A_3}_{\textrm{\ding{192}}}$ \eqref{IA1A2A3} witness genuine tripartite nonlocality. \end{theorem} \begin{proof} We want to show that any hybrid distribution satisfies $I^{A_1A_2A_3}_{\textrm{sym}} \leq 0$ and $I^{A_1A_2A_3}_{\textrm{\ding{192}}} \leq 0$. First, observe that due to the convexity of hybrid distributions \eqref{GenuineNonlocal}, it is sufficient to perform the proof for the extremal distributions $P_{A_iA_j}(a_ia_j|x_ix_j)P_{A_k}(a_k|x_k)$. The second basic element of our proof is that \begin{equation}\label{GGG:genralLiftings0} I^{A_jA_k}_{0|0} \big( P_{A_iA_j}(a_ia_j|x_ix_j)P_{A_k}(a_k|x_k) \big) \leq 0 \end{equation} for any triplet $i,j,k \in \{1,2,3\}$ with $i \neq j \neq k \neq i$. This comes from the fact that the (lifted) inequality $I^{A_jA_k}_{0|0}$ can only be violated if parties $A_j$ and $A_k$ are non-classically correlated, which is not the case when the correlations allow for a decomposition of the form $P_{A_jA_k}(a_ja_k|x_jx_k)P_{A_i}(a_i|x_i)$. (A proof of this property can be found in Appendix \ref{APP1:liftings}.) After this observation, we know that for every extremal hybrid distribution, the only potentially positive term in both our inequalities is $I^{A_iA_j}_{0|0} \big( P_{A_iA_j}(a_ia_j|x_ix_j)P_{A_k}(a_k|x_k)\big)$, therefore: \begin{equation}\begin{split} I^{A_1A_2A_3}_{\textrm{sym}} \leq I^{A_iA_j}_{0|0} - P(000|000)\\ I^{A_1A_2A_3}_{\textrm{\ding{192}}} \leq I^{A_iA_j}_{0|0} - P(000|000) \end{split}\,.\end{equation} The last element of our proof is then the fact that \begin{equation}\begin{split}\label{IbarA1A2A3} \bar{I}^{A_iA_j}_{0|0} \equiv & I^{A_iA_j}_{0|0} - P(000|000)=\\ = -P(010|010)-&P(100|100)-P(000|110) \leq 0 \end{split}\end{equation} for any probability distribution, which will cancel the potentially positive term. \end{proof} Notice that the idea behind our construction can be extended to build a three-parameter $\mu_{12},\mu_{13},\mu_{23}$ family of inequalities that also witness genuine tripartite nonlocality \begin{equation}\begin{split}\label{IA1A2A3FULL} I^{A_1A_2A_3}_{\mu} = \mu_{12} I^{A_1A_2}_{0|0}+\mu_{13} I^{A_1A_3}_{0|0}\\+\mu_{23} I^{A_2A_3}_{0|0}-P(000|000) \leq 0 \end{split}\end{equation} for $\mu_{ij} \in [0,1]$ and $\mu_{12}+\mu_{13}+\mu_{23} > 1$ (if this last condition is not met, the inequality is trivial: $I^{A_1A_2A_3}_{\mu} \leq 0$ for any probability distribution). Indeed, following the arguments of the proof of Theorem \ref{3partyisGMNL}, one can verify that \eqref{IA1A2A3FULL} holds for any hybrid distribution \eqref{GenuineNonlocal}: \begin{equation}\begin{split}\label{IA1A2A3FULLifull} I^{A_1A_2A_3}_{\mu}\big( P_{A_iA_j}(a_ia_j|x_ix_j)P_{A_k}(a_k|x_k) \big)\leq &\\ \mu_{ij}I^{A_iA_j}_{0|0}-P(000|000) \leq \bar{I}^{A_iA_j}_{0|0} \leq& 0 \end{split}\end{equation} \vspace{0.3cm} It is interesting to observe that the local strategy where every party always obtains outcome $a_i=1$ for any measurement $x_i$ saturates both inequalities $I^{A_1A_2A_3}_{\textrm{\ding{192}}} = 0$ and $I^{A_1A_2A_3}_{\textrm{sym}} = 0$, thus as well $I^{A_1A_2A_3}_{\mu} = 0$. This implies that the local and hybrid bounds of our inequalities coincide. It also implies that our inequalities are tangent, both to the set of local correlations \eqref{FullyLocal} and hybrid ones \eqref{GenuineNonlocal}.\\ \section{Detection of genuine tripartite nonlocality in pure states} Bell inequality $I^{A_1A_2A_3}_{\textrm{sym}}$ seems particularly fit for the detection of genuine tripartite nonlocality of pure states. Indeed, it belongs to class 6 of \cite{Bancal:PRA:014102}, where strong numerical evidence was provided indicating that all three-qubit systems in a GME pure state could generate correlations violating it. This result hints that $I^{A_1A_2A_3}_{\textrm{sym}}$ is a good candidate for an analytical proof of equivalence between GME and GMNL for tripartite pure states. Later, we will generalise this inequality for $n$ parties, prove analytically that it detects GMNL in a large class of GME pure states and provide numerical evidence that all GME pure states of four qubits are GMNL. We now focus on inequality $I^{A_1A_2A_3}_{\textrm{\ding{192}}} \leq 0$ and show that it is useful for the detection of genuine tripartite nonlocality of pure states. In \cite{Acin2000}, it was shown that all systems of three qubits in a pure state could be written as \begin{equation}\begin{split}\label{3qubitsMAIN} \ket{\Psi_3} = h_0 \ket{000} + h_1 e^{i \phi} \ket{100} + h_2 \ket{101} + h_3 \ket{110} + h_4 \ket{111} \end{split}\end{equation} where $h_i \in \mathbb{R}_{+}$, $\sum\limits_i h_i^2 = 1$ and $\phi \in [0,\pi]$. \begin{theorem}\label{GG:THRM2} For all tripartite pure states \eqref{3qubitsMAIN} that are GME and symmetrical under the permutation of any two parties, say $A_2$ and $A_3$ ($h_0,h_4>0$ and $h_2=h_3$), one can find local measurements on them such that the generated correlations violate inequality $I^{A_1A_2A_3}_{\textrm{\ding{192}}} \leq 0$ \eqref{IA1A2A3}, hence generating GMNL correlations. \end{theorem} \begin{proof} A complete proof of Theorem \ref{GG:THRM2} can be found in Appendix \ref{APPGG:TheoremN3}. The main line of it goes as follows. We will start by choosing parties $A_2$ and $A_3$ to perform the same (projective) measurements $\bra{m_{a_2|x_2}} = \bra{m_{a_3|x_3}} \hspace{0.2cm}, \forall a_2=a_3$ and $x_2=x_3$. This, together with the $A_2 \leftrightarrow A_3$ invariance of the state, implies that the observed correlations $P(a_1a_2a_3|x_1x_2x_3)$ are also symmetrical with respect to the permutation of $A_2$ and $A_3$. Consequently, for these correlations, we have $I^{A_1A_2}_{0|0}=I^{A_1A_3}_{0|0}$ \eqref{I3Liftee} and $I^{A_1A_2A_3}_{\textrm{\ding{192}}}$ can be simplified to \begin{equation}\begin{split} I^{A_1A_2A_3}_{\textrm{\ding{192}}} = 2 I^{A_1A_2}_{0|0}-P(000|000) =\\=P(000|000)-\\-2P(010|010)-2P(100|100)-2P(000|110)\leq 0 \end{split}\end{equation} We now show that we can always find appropriate measurements such that we obtain a particular violation of the previous inequality \begin{equation}\begin{split}\label{HARDYMEASMAIN} P(000|000) & > 0\\ P(010|010) &= P(100|100) = P(000|110) = 0\,. \end{split}\end{equation} These conditions correspond to an Hardy paradox \cite{Hardy} on parties $A_1$ and $A_2$. Consider the post-measurement state $\ket{\psi_{0|0}^{A_1A_2}}$, which is the state prepared by party $A_3$ after making the measurement $\bra{m_{a_3=0|x_3=0}}$ on $\ket{\Psi_3}$: \begin{equation} \ket{\psi_{0|0}^{A_1A_2}} \propto \mathbbm{1}_{A_1} \otimes \mathbbm{1}_{A_2} \otimes \bra{m_{a_3=0|x_3=0}} \ket{\Psi_3}\,. \end{equation} Since $\ket{\Psi_3}$ is GME by assumption, we can tune the measurement $\bra{m_{a_3=0|x_3=0}}$ such that the prepared state $\ket{\psi_{0|0}^{A_1A_2}}$ is non-maximally entangled \cite{PopescuGeneric}. After Hardy's construction \cite{Hardy}, we know that for a pure non-maximally entangled state $\ket{\psi_{0|0}^{A_1A_2}}$ we can always find a one-parameter family of measurements on $\bra{m_{a_1|x_1}}$ and $\bra{m_{a_2|x_2}}$ leading to an Hardy paradox \eqref{HARDYMEASMAIN}. This means that we can choose freely the first measurement, say $\bra{m_{a_2=0|x_2=0}}$, and always find three other measurements $\bra{m_{a_2=0|x_2=1}},\bra{m_{a_1=0|x_1=0}},\bra{m_{a_1=0|x_1=1}}$ such that \eqref{HARDYMEASMAIN} is satisfied. Therefore, we are able to choose $\bra{m_{a_2=0|x_2=0}}=\bra{m_{a_3=0|x_3=0}}$ in order to be compatible with the condition of preparing a state $\ket{\psi_{0|0}^{A_1A_3}}$ $(=\ket{\psi_{0|0}^{A_1A_2}})$ that is non-maximally entangled. More details can be found in Appendices \ref{APPGG:TheoremN3} and \ref{GGAPP:HardyMeasurements} . \end{proof} \section{The general multipartite scenario} We proceed now to exposing our results in the general multipartite scenario. We consider any number $n>2$ of observers making dichotomic choices of local measurements $x_i \in \{0,1\}$ on their share of a joint quantum system and obtaining outcomes $a_i \in \{0,1\}$, generating a distribution $P(a_1a_2...a_n|x_1x_2...x_n) \equiv P(\vec{a}|\vec{x})$. The definition of genuine multipartite nonlocality for any number of parties is more intricate than the tripartite case, but follows basically the same idea as \eqref{GenuineNonlocal}. A distribution $P(\vec{a}|\vec{x})$ is said to be \textit{biseparable} if \begin{equation}\begin{split}\label{biseparable} P_{\textrm{2-sep}}(\vec{a}|\vec{x}) = \sum\limits_{g}\sum\limits_{\lambda_g} q_g(\lambda_g) P(\vec{a}_g|\vec{x}_g,\lambda_g)P(\vec{a}_{\bar{g}}|\vec{x}_{\bar{g}},\lambda_{g}) \end{split}\end{equation} where $\sum\limits_{g}\sum\limits_{\lambda_g} q_g(\lambda_g) = 1$, $q_g(\lambda_g) \geq 0$ and $g$ is a group consisting of a particular subset of the $n$ observers and $\bar{g}$ its complement. We label the string of measurement choices (resp. outcomes) of the observers belonging to the group $g$ as $\vec{x}_g$ ($\vec{a}_g$). For example, for $n=3$ there are only three possible inequivalent ways of making two groups: $(g_1=A_1A_2,\bar{g}_1=A_3$), $(g_2=A_1A_3, \bar{g}_2=A_2$) and $(g_3=A_2A_3, \bar{g}_3=A_1$), leading to a decomposition of the form \eqref{GenuineNonlocal}. Distributions that can not be written according to the decomposition \eqref{biseparable} are \emph{genuine multipartite nonlocal}. This corresponds to the strongest type of multipartite nonlocality, in the sense that all the parties of the system are engaged in a nonclassical correlation. We will see later that we can define intermediate types of multipartite nonlocal correlations, where one allows for more than two groups of parties Again, local measurements on pure biseparable states $\ket{\psi_{1\ldots n}}=\ket{\phi_g}\ket{\phi_{\bar{g}}}$ for some splitting $g/\bar{g}$ of the particles, always lead to biseparable joint distributions \eqref{biseparable}. Genuine multipartite entanglement is necessary to generate genuine multipartite nonlocal correlations.\\ \section{Bell inequalities for genuine multipartite nonlocality} The generalisation of inequalities $I^{A_1A_2A_3}_{\textrm{sym}}$ \eqref{IA1A2A3sym} and $I^{A_1A_2A_3}_{\textrm{\ding{192}}}$ \eqref{IA1A2A3} to any number $n$ of parties gives two distinct families of Bell inequalities that can be written in a simple form: \begin{equation}\begin{split}\label{IGeneralsym} I^{A_1\ldots A_n}_{\textrm{sym}} =\sum\limits_{i=1}^{n-1}\sum\limits_{j>i}^{n} I^{A_iA_j}_{\vec{0}|\vec{0}} - {n-1\choose 2} P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} \begin{equation}\begin{split}\label{IGeneral} I^{A_1\ldots A_n}_{\textrm{\ding{192}}} = \sum\limits_{j>1}^{n} I^{A_1A_j}_{\vec{0}|\vec{0}} - (n-2) P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} where ${n-1\choose 2} = \frac{(n-1)(n-2)}{2}$ and we take the freedom of writing $\vec{0}\equiv (0,0,...,0)$, the size of the string should be obvious in the context. Similarly to \eqref{I3Liftee}, $I^{A_iA_j}_{\vec{0}|\vec{0}}$ is a lifting of inequality $I^{A_iA_j}$ \eqref{IA1A2} to $n$ observers by setting the remaining $n-2$ observers to have their measurement and outcome set to $0$: \begin{equation}\begin{split}\label{InLiftee} I^{A_iA_j}_{\vec{0}|\vec{0}} = P(0_i0_j\vec{0}|0_i0_j\vec{0})-P(1_i0_j\vec{0}|1_i0_j\vec{0})\\ -P(0_i1_j\vec{0}|0_i1_j\vec{0})-P(0_i0_j\vec{0}|1_i1_j\vec{0})\,. \end{split}\end{equation} The operational meaning of these inequalities is the following. In both cases, we use as ``seed'' the CHSH inequality \eqref {IA1A2}, which defines a nonlocal game between parties $A_i$ and $A_j$ represented by the lifted inequalities $I^{A_iA_j}_{\vec{0}|\vec{0}}$. For the symmetrical family \eqref{IGeneralsym} every pair of parties is required to play a CHSH game while for the inequalities ``centered" on $A_1$ \eqref{IGeneral}, party $A_1$ is required to play a CHSH game with every other party. \begin{theorem}\label{NpartyisGMNL} The Bell inequalities $I^{A_1\ldots A_n}_{\textrm{sym}}\leq 0$ \eqref{IGeneralsym} and $I^{A_1\ldots A_n}_{\textrm{\ding{192}}}\leq 0$ \eqref{IGeneral} are witnesses of genuine multipartite nonlocality for all $n\geq3$. \end{theorem} \begin{proof} Here we only provide an outline, the full proof can be found in Appendix \ref{APP2:IGeneral}. The idea is similar to the one for three parties. We want to show that all biseparable distributions \eqref{biseparable} for $n$ parties satisfy $I^{A_1\ldots A_n}_{\textrm{sym}} \leq 0$ and $I^{A_1\ldots A_n}_{\textrm{\ding{192}}}\leq 0$. Again, by convexity, it is enough to verify it for extremal biseparable distributions $P(\vec{a}_g|\vec{x}_g)P(\vec{a}_{\bar g}|\vec{x}_{\bar g})$ from \eqref{biseparable}. If parties $A_i$ and $A_j$ belong to different groups, they are only classically correlated and therefore $I^{A_iA_j}_{\vec{0}|\vec{0}}\leq0$. Then, the only terms that can give a positive contribution $I^{A_iA_j}_{\vec{0}|\vec{0}} > 0$ are terms where parties $A_i$ and $A_j$ belong to the same group. Now the trick is to kill these positive contributions by subtracting enough $P(\vec0|\vec0)$ terms since, similarly to $n=3$ \eqref{IbarA1A2A3}, \begin{equation}\label{Ibar} \bar{I}^{A_iA_j}_{\vec{0}|\vec{0}}\equiv I^{A_iA_j}_{\vec{0}|\vec{0}} - P(\vec{0}|\vec{0}) \leq0 \end{equation} for any probability distributions. \emph{Symmetric family} $I_{\textrm{sym}}$ --- In general, if the first group $g$ consists of $m$ parties and $\bar{g}$ of $n-m$ for some $1 \leq m \leq n-1$, a total number of ${m\choose 2}+{n-m\choose 2}$ inequalites $I^{A_iA_j}_{\vec{0}|\vec{0}}$ can in principle be positive. Since ${n-1\choose 2} > {m\choose 2}+{n-m\choose 2} \hspace{0.2cm}, \forall m \geq 2$, the largest number of pairs is obtained by putting $n-1$ parties in one group, which means ${n-1\choose 2}$ potentially positive terms $I^{A_iA_j}_{\vec{0}|\vec{0}}$. Then, \begin{equation}\begin{split} I^{A_1\ldots A_n}_{\textrm{sym}}\big(P(\vec{a}_g|\vec{x}_g)&P(\vec{a}_{\bar g}|\vec{x}_{\bar g})\big)\leq \\ \sum\limits_{i=1}^{n-2}\sum\limits_{j>i}^{n-1} I^{A_iA_j}_{\vec{0}|\vec{0}} - {n-1\choose 2} &P(\vec{0}|\vec{0}) =\sum\limits_{i=1}^{n-2}\sum\limits_{j>i}^{n-1} {\bar I}^{A_iA_j}_{\vec{0}|\vec{0}} \leq 0 \end{split}\end{equation} where we used the fact that $I^{A_1\ldots A_n}_{\textrm{sym}}$ is invariant under permutations of parties to consider the specific partition $g=\{1,..,n-1\}$ and $\bar g =\{n\}$. \\\ \emph{Centered family} $I_{\textrm{\ding{192}}}$ --- The proof follows the same idea as before. Using \eqref{Ibar}, any biseparable distribution \eqref{biseparable} with $m$ parties in the first group $g$ containing party $A_1$ and $n-m$ in the other group $\bar{g}$ gives \begin{equation}\begin{split}\label{IbarNonSym} I^{A_1\ldots A_n}_{\textrm{\ding{192}}}\big(P(\vec{a}_g|\vec{x}_g) P(\vec{a}_{\bar g}|\vec{x}_{\bar g})\big) \\ \leq \sum\limits_{j \in g} I^{A_1A_j}_{\vec{0}|\vec{0}} - (n-2) P(\vec{0}|\vec{0}) \leq \sum\limits_{j \in g} &\bar{I}^{A_1A_j}_{\vec{0}|\vec{0}} \leq 0 \end{split}\end{equation} since there are at most $n-2$ parties together with party $A_1$ in the first group $g$ \end{proof}\vspace{0.5cm} \begin{figure}[h!]\begin{center} \scalebox{0.7}{\includegraphics{GGN5.png}} \caption{\label{Fig:GG_n5} An abstract representation of five parties (blue circles) arranged into groups (gray areas). Two parties $i$ and $j$ inside the same group can potentially violate a lifted inequality $I^{A_iA_j}_{\vec{0}|\vec{0}}$ (as represented by a dashed line between them). $i)$ Two groups of parties $|g|=2;|\bar{g}|=3$, giving a distribution of the form $P(\vec{a}|\vec{x})=P(a_1a_2|x_1x_2)P(a_3a_4a_5|x_3x_4x_5)$ and a maximum number of ${2\choose 2}+{3\choose 2} = 4$ violated inequalities $I^{A_iA_j}_{\vec{0}|\vec{0}}>0$. $ii)$ Two groups of parties $|g|=1;|\bar{g}|=4$, for ${4 \choose 2} = 6$ potentially violated inequalities $I^{A_iA_j}_{\vec{0}|\vec{0}}>0$. $iii)$ GMNL: all parties are in the same group and thus ${5 \choose 2} = 10$ inequalities can be violated. Only $iii)$ can violate $I^{A_1\ldots A_5}_{\textrm{sym}} = \sum\limits_{i=1}^4 \sum\limits_{j>i}^5 I^{A_iA_j}_{\vec{0}|\vec{0}} - 6P(\vec{0}|\vec{0})$ since $I^{A_iA_j}_{\vec{0}|\vec{0}} - P(\vec{0}|\vec{0}) \leq 0$.} \end{center}\end{figure} One can understand a violation of the families of inequalities \eqref{IGeneralsym} and \eqref{IGeneral} in the following way: $a)$ any (extremal) distribution that violates $I^{A_1\ldots A_n}_{\textrm{sym}}$ \eqref{IGeneralsym} needs to be capable of violating more than ${n-1\choose 2}$ lifted CHSH inequalities $I^{A_iA_j}_{\vec{0}|\vec{0}}$ between different observers $A_i$ and $A_j$; and $b)$ any distribution that violates $I^{A_1\ldots A_n}_{\textrm{\ding{192}}}$ \eqref{IGeneral} violates more than $n-2$ lifted CHSH inequalities $I^{A_1A_j}_{\vec{0}|\vec{0}}$ between $A_1$ and different observers $A_j$. Only GMNL correlations, where all pairs of parties are nonlocally correlated, are able to do this More insight on the rich structure of the symmetrical family of inequalities \eqref{IGeneralsym} is given by noticing that they can also be written in a recursive form for $n\geq3$ \begin{equation}\begin{split}\label{IGeneralsym2} I^{A_1A_2...A_n}_{\textrm{sym}} = \sum\limits_{i = 1}^{n} I^{\textrm{all}\setminus A_i}_{0|0} - (n-2)P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} where $I^{\textrm{all}\setminus A_i}_{0|0}$ is the symmetrical inequality for $n-1$ observers lifted to $n$ of them with observer $A_i$'s input and outcome set to $0$. If $n=3$ for example, $I^{\textrm{all}\setminus A_i}_{0|0}$ corresponds to the CHSH inequality lifted to 3 parties \eqref{I3Liftee}. The proof of the equivalence between the direct expression \eqref{IGeneralsym} and the recursive one \eqref{IGeneralsym2} can be found in Appendix~\ref{APP:Alternative}. In other words, operationally a violation of the symmetrical family $I^{A_1A_2...A_n}_{\textrm{sym}}$ can also be understood as a violation of more than $n-2$ inequalities $I^{\textrm{all}\setminus A_i}_{0|0}$ between $n-1$ parties lifted to $n$ parties -- instead of ${n-1\choose 2}$ bipartite ones $I^{A_iA_j}_{\vec{0}|\vec{0}}$ lifted to $n$ parties. Since this argument can be used recursively, one concludes that GMNL correlations violating our inequalities violate numerous inequalities between subset of $m$ parties lifted to $n$ parties, for all $m$ Observe that, similar to the tripartite case, the generalised families $I^{A_1\ldots A_n}_{\textrm{sym}}$ \eqref{IGeneralsym} and $I^{A_1\ldots A_n}_{\textrm{\ding{192}}}$ \eqref{IGeneral} are also saturated by local distributions. The local strategy is the same as for $n=3$: every party $A_i$ outputs $a_i=1$ for all measurements $x_i$. It follows that the local and biseparable bounds of our families of inequalities coincide for all $n$. Again, it also implies that our inequalities are tangent to the set of local and biseparable correlations. \section{Detection of genuine multipartite nonlocality in pure states} Let us now analyse how the symmetric family of Bell inequalities $I^{A_1\ldots A_n}_{\textrm{sym}}$ sheds light on the relation between GME and GMNL of pure states. The goal is to understand whether it is possible to find local measurements on \emph{any} pure GME state that generate GMNL correlations. Our Bell inequalities seem fit to prove this result since for any pure GME state there exist local projections on \emph{any} $n-2$ parties that leave the remaining two in a pure entangled state \cite{PopescuGeneric}, which can in turn be used to violate the CHSH inequality~\cite{GisinThrm}. The main difficulty in proving the result in full generality is to find local measurements that simultaneously perform the desired projections but are also fit to violate the CHSH terms. For $n=2$ our two families of inequalities coincide with the CHSH inequality, which was used to prove the equivalence between nonlocality and pure state entanglement~\cite{GisinThrm}. For $n=3$, there is numerical evidence that this holds for GME three-qubits pure states \cite{Bancal:PRA:014102} using the symmetrical family $I^{A_1A_2A_3}_{\textrm{sym}}$ \eqref{IA1A2A3}.\\ We consider the generalisation of these results to the scenario with $n=4$ parties, where we obtained numerical evidence that all four-qubit systems in a pure GME state generate distributions violating the Bell inequality $I^{A_1\ldots A_4}_{\textrm{sym}}$ \eqref{IGeneralsym}. For this, we have randomly drawn four qubit states and numerically searched for local measurements leading to a violation of our inequality. Note that the set of separable states is of volume zero in the state space.\\ We now proceed to show analytically that a large class of pure GME states of the GHZ family~\cite{greenberger1989going} can generate GMNL correlations, for all number of parties $n\geq3$, as detected by the symmetrical family of inequalities $I_{\textrm{sym}}^{A_1\ldots A_n}$ \eqref{IGeneralsym} . \begin{theorem}\label{GG:THRM1} All pure GME states of the form \begin{equation}\begin{split}\label{GG:greenberger1989going} \ket{GHZ^n}_{\theta} = \cos\theta\ket{0}^{\otimes n} - \sin\theta\ket{1}^{\otimes n} \end{split}\end{equation} with $\theta \in ]0,\frac{\pi}{4}[$ violate the Bell inequality $I_{\textrm{sym}}^{A_1\ldots A_n}$ \eqref{IGeneralsym} for all $n\geq 3$. All parties $A_i$ make the same projective measurements, $\bra{m_{a_i|x_i}}= \bra{m_{a|x}}$, defined by \begin{align} \begin{split}\label{Measurements} \bra{m_{0|x}} = \cos\alpha_x\bra{0}+\sin\alpha_x\bra{1}\\ \bra{m_{1|x}} = \sin\alpha_x\bra{0}-\cos\alpha_x\bra{1} \end{split} \end{align} where \begin{align} \begin{split}\label{angles} \alpha_0 &= \arctan(\tan^{-\frac{3}{3n-4}}(\theta))\\ \alpha_1 &= -\arctan(\tan^{-\frac{1}{3n-4}}(\theta))\,. \end{split} \end{align} In other words, all states of the form \eqref{GG:greenberger1989going} that are GME are GMNL. \end{theorem} \begin{proof} A detailed and constructive proof of this theorem can be found in Appendix \ref{APP3:GME-GMNL}. The key point is to impose the local measurements to be the same for every party, which makes the joint outcome distribution invariant under permutations of the parties (since the state $\ket{GHZ^n}_{\theta}$ \eqref{GG:greenberger1989going} also has this invariance). This symmetry simplifies the problem and allowed us to find an analytical solution. \end{proof} Interestingly, the only GME pure state of this family for which our construction fails is the maximally entangled state ($\theta = \pi/4$), which is already known to generate GMNL for any number of observers \cite{BancalQuantifying}. We have however found, numerically, several sets of measurements on this state that lead to distributions violating our inequality, but the amount of symmetries is reduced. Interestingly, Theorem \ref{GG:THRM1} implies that even states that are almost separable ($\theta \rightarrow 0$) can be used to generate GMNL correlations for any number of observers.\\ It is important to observe that we already knew from \cite{Chinese1} that all $n$-qubit systems in a GME symmetric pure state are GMNL, which is a more general result than Theorem \ref{GG:THRM1}. In particular, for three-qubit systems, the problem was completely solved: all three-qubit systems in a pure GME state can exhibit GMNL \cite{Chinese2}. These results rely however on the violation of two families of Hardy-like paradoxes witnessing GMNL, making it untestable in an experiment (where even the smallest imperfections lead to values $P(ab|xy)= \epsilon > 0$). Indeed, the correlations obtained in~\cite{Yu3,Chinese1} are nonlocal, because they violate a Hardy paradox, and therefore should also violate a Bell inequality in a robust way. However, the form of this inequality is unknown. Although clearly not as general, our results are testable and might lead the way to a complete generalisation of Gisin's theorem for $n$ parties. \section{Constructing genuine multipartite Bell inequalities from different seeds}\label{OtherSeed} The construction was so far done using as ``seed" the CHSH inequality $I^{A_1A_2}$ \eqref{IA1A2} to build new families of inequalities. We now show the versatility of our technique by using different inequalities as seed. In general, any inequality $S^{A_1\ldots A_m}$ for $m<n$ parties that can be written as \begin{equation}\begin{split}\label{GG:UsefulIneqs} S^{A_1\ldots A_m}\big(P(\vec{a}|\vec{x})\big) &=\\= P(\vec0|\vec0) &- \sum\limits_{\substack{\vec{a},\vec{x} \neq \vec0,\vec0}} \beta_{\vec a}^{\vec x} P(\vec a|\vec x) \leq \mathcal{B}_{2-sep}= 0\end{split} \end{equation} such that $\beta_{\vec a}^{\vec x} \geq 0 \hspace{0.2cm}$,$ \forall {\vec a,\vec x \neq \vec0,\vec0}$, and with biseparable bound $\mathcal{B}_{2-sep}=0$, is a valid seed to build a Bell inequality for $n$ parties. To see that, note that the key ingredient in our proofs is, again, that \begin{equation}\label{GG:UsefulIneqs2} \bar{S}^{A_1\ldots A_m} \equiv S^{A_1\ldots A_m} - P(\vec0|\vec0) = - \sum\limits_{\substack{\vec a,\vec x \neq \vec 0,\vec 0}} \beta_{\vec a}^{\vec x} P(\vec a|\vec x) \leq 0 \end{equation} for any probability distribution. (This implies that the lifting of \eqref{GG:UsefulIneqs2} to more parties is also always negative $\bar{S}^{A_1\ldots A_n}_{\vec{0}|\vec{0}} \leq 0$, which we used frequently in our proofs). Although the condition for a Bell inequality to be used as a seed is fairly simple, we do not know of a systematic way to find out which inequalities can be written in the form \eqref{GG:UsefulIneqs}. We will now illustrate our construction with two different seeds.\\ \textbf{The tilted CHSH inequality.--} As a first example, we use the ``tilted CHSH" inequality \cite{Acin2012} as the new seed. This inequality is a variation of the CHSH inequality with two free parameters, used for randomness certification~\cite{Acin2012} and self-testing of partial entangled states \cite{bamps2015sum}. By setting one of the parameters to 1, the tilted CHSH inequality can be written in the form \eqref{GG:UsefulIneqs} \begin{equation}\begin{split}\label{Ibeta} I^{A_1A_2}_{\beta} = P(00|00)-P(01|01)-P(10|10)\\-P(00|11)-\frac{\beta}{2}P_{A_1}(1|0) \leq 0 \end{split}\end{equation} where $\beta \geq 0$ and $P(a_1|x_1) = \sum\limits_{a_2} P(a_1a_2|x_1x_2) \hspace{0.2cm},\forall x_2$, is the marginal distribution of party $A_1$. Clearly, the inequality satisfies condition \eqref{GG:UsefulIneqs2}. Starting from the new seed $I^{A_1A_2}_{\beta}$ \eqref{Ibeta}, we construct two new families of GMNL Bell inequalities. \begin{theorem}\label{GG:NewSeedTHRM} The families of inequalities \begin{equation}\begin{split}\label{IGeneralsymBeta} I^{A_1\ldots A_n}_{\beta,\textrm{sym}} =\sum\limits_{i=1}^{n-1}\sum\limits_{j>i}^{n} I^{A_iA_j}_{\beta,\vec{0}|\vec{0}} - {n-1\choose 2} P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} \begin{equation}\begin{split}\label{IGeneralBeta} I^{A_1\ldots A_n}_{\beta,\textrm{\ding{192}}} = \sum\limits_{j>1}^{n} I^{A_1A_j}_{\beta,\vec{0}|\vec{0}} - (n-2) P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} witness GMNL for any number $n\geq3$ of parties. \end{theorem} \begin{proof} The proof that these two families of inequalities indeed witness GMNL for all $n$ is exactly the same as for the families \eqref{IGeneralsym} and \eqref{IGeneral}, but now using the seed $I_\beta^{A_1A_2}$ and property \eqref{GG:UsefulIneqs2}. \end{proof} \textbf{A tripartite inequality as seed.--} As a second example, we illustrate how to use a multipartite inequality as a seed. We chose a Bell inequality for three parties -- that witnesses GMNL in tripartite correlations -- that belongs to class $5$ of \cite{Bancal:PRA:014102} and that can be written as \begin{equation}\begin{split}\label{Ifor3} I^{A_1A_2A_3}_{\textrm{tri}} = &P(000|000) - P(010|111) - \\-&P(000|011) - P(001|001) - P(100|110) -\\&- P(010|010) - P(100|100) \leq 0 \end{split}\end{equation} and hence satisfying condition \eqref{GG:UsefulIneqs2}. This allows us to construct, again, two new families of Bell inequalities witnessing GMNL for any $n \geq 4$. \begin{theorem}\label{GG:TripartiteSeedTHRM} The families of inequalities \begin{equation}\begin{split}\label{IGeneralsym3seed} I^{A_1\ldots A_n}_{\textrm{tri},\textrm{sym}} =\sum\limits_{i=1}^{n-2}\sum\limits_{j>i}^{n-1} \sum\limits_{k>j}^{n} I^{A_iA_jA_k}_{\textrm{tri},\vec{0}|\vec{0}} - {n-1\choose 3} P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} \begin{equation}\begin{split}\label{IGeneral3seed} I^{A_1\ldots A_n}_{\textrm{tri},\textrm{\ding{192}\ding{193}}} = \sum\limits_{j>2}^{n} I^{A_1A_2A_j}_{\textrm{tri},\vec{0}|\vec{0}} - (n-3) P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} \end{theorem} witness GMNL for $n\geq 4$ parties. \begin{proof} Although this proof is again analogous to the previous families, a tripartite inequality as the seed changes the weights associated to the term $P(\vec0|\vec0)$. For the symmetric family \eqref{IGeneralsym3seed}, consider that a biseparable probability distribution \eqref{biseparable} can violate at most ${n-1\choose 3}$ inequalities $I^{A_iA_jA_k}_{\textrm{tri},\vec{0}|\vec{0}}$ between three different parties. This comes from the fact that the best for a biseparable distribution is a grouping $g=\{1,2,...,n-1\}$, $\bar{g}=\{n\}$ of the parties, allowing a maximum of ${n-1\choose 3}$ to potentially violate the inequality $I^{A_iA_jA_k}_{\textrm{tri},\vec{0}|\vec{0}}$. For the centered family \eqref{IGeneral3seed}, consider that there are at most $n-3$ inequalities $I^{A_1A_2A_j}_{\textrm{tri},\vec{0}|\vec{0}}$ that can potentially be violated for a grouping $g=\{1,2,...,n-1\}$, $\bar{g}=\{n\}$ of the parties. \end{proof} It would obviously be interesting to explore up to which extent the inequalities that can be built -- as the ones in \eqref{IGeneralsymBeta},\eqref{IGeneralBeta}, \eqref{IGeneralsym3seed} and \eqref{IGeneral3seed} -- are useful to witness GMNL from quantum states. We leave this direction of research open for further work. Finally, it would also be insightful to consider seeds allowing for more measurement choices and/or outcomes. \section{Constructing $m$-way nonlocality Bell inequalities}\label{GG:MoreKway} Now we show how our construction also allows one to build families of Bell inequalities that witness intermediate types of multipartite nonlocality. Indeed, in the multipartite scenario it is possible to define a hierarchy of multipartite correlations taking into account the extent to which these are multipartite nonlocal. This can be measured, for example, by notions such as $m-$way (non)locality or $m-$separability of correlations \cite{Bancal:PRA:014102,BancalQuantifying}. Instead of asking whether given correlations can be decomposed into (convex mixtures) of two groups as in \eqref{biseparable}, one can ask whether the correlations can be decomposed into $m$ groups. Correlations that are decomposable into $m<n$ groups are then less multipartite nonlocal than other correlations that do not allow for such decomposition.\\ Correlations $P(\vec{a}|\vec{x})$ are said to be $m-$separable (or $m-$way local), i.e. decomposable into $m$ groups, if \begin{equation}\begin{split}\label{mseparable} P_{\textrm{m-sep}}(\vec{a}|\vec{x}) = \sum\limits_{k}\sum\limits_{\lambda_k} q_k(\lambda_k) \prod\limits_{i=1}^m P(\vec{a}_{k_i}|\vec{x}_{k_i},\lambda_{k}) \end{split}\end{equation} where $\sum\limits_{k}\sum\limits_{\lambda_k} q_k(\lambda_k) = 1$, $q_k(\lambda_k) \geq 0$. Here, the variable $k$ defines a \textit{grouping} of the $n$ parties into $m$ pairwise disjoint and non-empty groups $k_i$, $i = 1,2,...m$: $|k_i|>0 \hspace{0.2cm} \forall i$, $k_i \cap k_j = \emptyset \hspace{0.2cm} \forall i \neq j$ and $\sum\limits_{i=1}^m |k_i| = n$. Biseparable correlations \eqref{biseparable} for $m=2$ can be decomposed into (convex mixtures of) two group of parties $k_1 = g$ and $k_2 = \bar{g}$.\\ For the sake of simplicity, we use the seed inequality $I^{A_1A_2}$ \eqref{IA1A2} to generalise our two families of Bell inequalities, symmetric and centered, for the detection of $m$-way nonlocality. \begin{theorem}\label{GG:msepTHRM} The families of inequalities for $n$ parties \begin{equation}\begin{split}\label{ImsepSYM} I^{A_1\ldots A_n}_{\textrm{m-sep},\textrm{sym}} =\sum\limits_{i=1}^{n-1}\sum\limits_{j>i}^{n} I^{A_iA_j}_{\vec{0}|\vec{0}} - {n+1-m\choose 2} P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} \begin{equation}\begin{split}\label{Imsep} I^{A_1\ldots A_n}_{\textrm{m-sep},\textrm{\ding{192}}} = \sum\limits_{j>1}^{n} I^{A_1A_j}_{\textrm{m},\vec{0}|\vec{0}} - (n-m) P(\vec{0}|\vec{0}) \leq 0 \end{split}\end{equation} witness $m-$way nonlocality (or non $m-$separability) for all $n\geq3, m<n$. \end{theorem} \begin{proof} The proofs follow the same line as the proofs for the other families of inequalities we have already constructed. By making $m$ groups instead of $2$, one needs to count the maximum number of pairs of parties $A_iA_j$ that can be made inside all the $m$ groups for the family \eqref{ImsepSYM}. Indeed, only pairs $A_iA_j$ inside the same group can potentially violate a lifted inequality $I^{A_iA_j}_{\vec{0}|\vec{0}}$. The best way to group $n$ parties into $m$ groups, in order to maximise the number of such pairs of parties, is to put $n-m+1$ parties into one group and the remaining $m-1$ ones into one group each. In this way, a maximum amount of ${n+1-m\choose 2}$ inequalities $I^{A_iA_j}_{\vec{0}|\vec{0}}$ can potentially be violated, but these can be cancelled by the ${n+1-m\choose 2} P(\vec{0}|\vec{0})$ terms in \eqref{ImsepSYM} since $I^{A_iA_j}_{\vec{0}|\vec{0}}-P(\vec{0}|\vec{0}) \leq 0$. For the family \eqref{Imsep}, one needs to count the maximum number of pairs $A_1A_j$ that can be made inside the group containing party $A_1$. By putting the maximal number of $n-m$ parties, plus party $A_1$, in one group, one gets that a maximum number of $n-m$ pairs $A_1A_j$ can be formed. This implies that a maximum amount of $n-m$ inequalities $I^{A_iA_j}_{\vec{0}|\vec{0}}$ can potentially be violated, but these are cancelled by the $(n-m) P(\vec{0}|\vec{0})$ term in \eqref{Imsep} since $I^{A_iA_j}_{\vec{0}|\vec{0}} - P(\vec{0}|\vec{0}) \leq 0$. \end{proof} \section{Conclusion} In this work, we have introduced a versatile technique to build Bell inequalities for the $n$-partite scenario. It consists of taking a ``seed'' -- a Bell inequality for $m<n$ parties obeying certain constraints -- to generate new families of Bell inequalities. Intuitively, the seed defines the nonlocal game that will be played by numerous groups of $m$ parties in the $n$-partite system. The specification of the sets of parties that are required to play the nonlocal game defines the level of multipartite nonlocality to be detected. Indeed, our construction can be used to witness $k$-nonlocal multipartite correlations, including the stronger notion of genuine multipartite nonlocality (where all the parties of the system are nonclassically correlated). To illustrate the power of our construction, we have first used the CHSH inequality as the seed to build two new families of Bell inequalities, $I_\textrm{sym}$ and $I_{\textrm{\ding{192}}}$, for the detection of genuine multipartite nonlocality in systems with any number $n\geq3$ of parties. We showed that these families are particularly useful for the detection of genuine multipartite nonlocality (GMNL) in genuine multipartite entangled (GME) pure states. Indeed, for $n=3$ we proved that $I^{A_1A_2A_3}_{\textrm{\ding{192}}}$ is able to detect genuine tripartite nonlocality in all genuine entangled three-qubit pure states invariant under the permutation of two parties. We also showed that the family $I_\textrm{sym}$ witnesses GMNL in all pure GME GHZ-like states $\cos\theta\ket{0}^{\otimes n} - \sin\theta\ket{1}^{\otimes n}$, including those which are almost product. Note that for three parties, $I^{A_1A_2A_3}_\textrm{sym}$ coincides with a Bell inequality found in \cite{Bancal:PRA:014102}, where numerical evidence was given that it detects GMNL in all GME three-qubit pure states. We extended this numerical evidence to the four-partite case, using $I^{A_1\ldots A_4}_\textrm{sym}$ to detect GMNL in all pure GME four-qubit states. Taking into account these partial results and the operational meaning of the family $I_\textrm{sym}$, we conjecture that this single family of Bell inequalities can be used to show that all GME pure states display GMNL, establishing a direct relation between genuine multipartite notions of pure state entanglement and nonlocality. Apart from a proof in full generality, which seems not straightforward, it would be interesting to extend these results to more families of GME pure states. A possibility is to study the multipartite $W$-state, $\ket{W_n}=\frac{1}{\sqrt{n}} \sum\limits_{i=1}^n \ket{1}_i \otimes_{j \neq i} \ket{0}_j$, for which we already managed to obtain, numerically, violations up to $n=5$. It would also be interesting to use further the characterisation of all three-qubit systems in a pure state ~\cite{AcinThreeQubits} to obtain an analytical proof that our inequality for $n=3$ detects GMNL when these states are GME by detecting also the states which have no symmetries. Further numerical exploration, for more observers or systems of larger dimensions, is another possibility. We have further used our technique to build families of Bell inequalities taking two different seeds: the bipartite ``tilted CHSH inequality'' and a tripartite inequality witnessing GMNL from \cite{Bancal:PRA:014102}. We have also shown how to design families of Bell inequalities that detect $m$-way multipartite nonlocality. In all cases, the construction is quite straightforward, which shows the potential and versatility of the method. For future work, it would be interesting to further explore the applicability of the Bell inequalities built through our method. For instance, can the family of Bell inequalities with the tilted CHSH inequality as a seed \eqref{Ibeta} be used to self-test certain classes of multipartite entangled pure states? Also generalising our seed to more settings and/or outcomes has the potential for generating Bell inequalities fit to detect multipartite correlations in a whole range of new different scenarios. \begin{acknowledgments} This work is supported by the ERC CoG QITBOX, the AXA Chair in Quantum Information Science, the Templeton Foundation, the Spanish MINECO (QIBEQI FIS2016-80773-P and Severo Ochoa SEV-2015-0522), Fundacio Cellex, Generalitat de Catalunya (CERCA Program and SGR1381). \end{acknowledgments}
\section{Results} \subsection{Stability} We begin our study by exploring whether a Bloch point emerges in the system shown in Fig.~\ref{fig:geometry}~(c), obtained as a result of a thought experiment we conducted in the introduction. In order to base our study on realistic material parameters and therefore encourage the experimental verification of our predictions, we use cubic B20 FeGe material parameters (see Methods section). We set the DMI constant in the bottom layer to be negative ($D=-|D|$) and fix its thickness $h_\text{bottom}$ to be $20 \,\text{nm}$. In the top layer we impose a positive DMI constant ($D=|D|$) and vary its thickness $h_\text{top}$ between $2 \,\text{nm}$ and $18 \,\text{nm}$ in steps of $1 \,\text{nm}$. The diameter of the disk sample is $150 \,\text{nm}$ and no external magnetic field is applied. For each thickness of the top layer, we begin by initialising the system with a uniform magnetisation configuration in the positive out-of-plane ($+z$) direction. This initial configuration corresponds to the fully saturated magnetisation configuration feasible in an experimental setup. After that, we relax the system by integrating a set of dissipative time-dependent equations until the condition of vanishing torque ($\mathbf{m} \times \mathbf{H}_\text{eff}$) is satisfied. After the relaxed (equilibrium) state is obtained, we compute a three-dimensional topological charge in the top and the bottom layer individually using \begin{equation} \label{eq:topological_charge_3d} Q = \frac{1}{4\pi} \int \mathbf{m} \cdot \left( \frac{\partial \mathbf{m}}{\partial x} \times \frac{\partial \mathbf{m}}{\partial y}\right) \,\text{d}^{3}r, \end{equation} as suggested by Lee et al.~\cite{Lee2009}. Because $Q$ is proportional to the volume (and accordingly the thickness) of individual layers, we normalise it by the thickness $\tilde{Q} = Q/h$, in order to make the values mutually comparable between different layers. The only reason we use normalised topological charge is to track changes in the magnetisation of individual layers in the system. We show in Fig.~\ref{fig:stability}~(a) how normalised topological charges $\tilde{Q}$ of the equilibrium state in individual layers depend on the thickness of the top layer $h_\text{top}$. Although the topological charge of the bottom layer $\tilde{Q}_\text{bottom}$ remains relatively constant, a sharp decrease of $\tilde{Q}_\text{top}$ between $8 \,\text{nm}$ and $9 \,\text{nm}$ thicknesses of the top layer is evident. Consequently, we assume that depending on the thickness of the top layer, two different configurations can emerge as equilibrium states in the studied system. Subsequently, we explore these two magnetisation configurations. \begin{figure*} \includegraphics{stability.eps} \caption{\label{fig:stability} \textbf{Normalised topological charge $\tilde{Q}$ dependence in individual layers, identified equilibrium states, and a Bloch point structure.} (\textbf{a})~Dependence of the normalised topological charge $\tilde{Q}$ in individual layers on $h_\text{top}$. Two identified magnetisation configurations: (\textbf{b})~for $h_\text{top} \le 8 \,\text{nm}$ and (\textbf{c})~for $h_\text{top} \ge 9 \,\text{nm}$. (\textbf{d})~Bloch point structure and demonstration that the magnetisation direction covers a sufficiently small closed surface surrounding the Bloch point exactly once.} \end{figure*} To explore the state that emerges for $h_\text{top} \le 8 \,\text{nm}$, we visualise the magnetisation obtained for $h_\text{top} = 5 \,\text{nm}$ in Fig.~\ref{fig:stability}~(b) and for $h_\text{top} \ge 9 \,\text{nm}$ magnetisation configurations, we show in Fig.~\ref{fig:stability}~(c) the state obtained with $t_\text{top} = 15 \,\text{nm}$. We show the magnetisation vector field together with the $m_{z}$ scalar field after we cut out a slice from the sample in order to be able to look inside and inspect its centre. We observe that for both states, vortex-like configurations with clear chiralities and polarisations emerge in individual layers. In the literature, the vortex-like states formed as a consequence of DM energy are also called quasi-ferromagnetic~\cite{Rohart2013}, edged vortex~\cite{Du2013}, or incomplete skyrmion~\cite{Beg2015, Carey2016, Pepper2018} states. In both states we identified, the polarisation and the handedness of the vortex-like states in bottom layers are the same and related by the right hand rule - characteristic for the negative DM energy constant. On the other hand, the vortex-like states in the top layer differ for two equilibrium states we obtained. The vortex-like state in the top layer with $5 \,\text{nm}$ thickness shown in Fig.~\ref{fig:stability}~(b), has the same handedness and polarisation as the thicker bottom layer. However, this is against the left hand rule which establishes the relationship between the handedness and polarisation for a positive DMI constant. Therefore, the DM energy density in the top layer is significantly higher than in the bottom layer and one can ask why the polarisation of the vortex-like state in the top layer is not reversed in order to minimise its energy. Because the energy contribution of the top layer to the total energy of the system is relatively small due to its thickness, it is energetically cheaper for the top layer to follow the magnetisation of the bottom layer (violate the left hand rule, and eventually have the higher energy density), than to reorient itself, which would result in an energetically more expensive Bloch point at the interface between two layers. Now, we look at magnetisation configuration in the system with $h_\text{top} = 15 \,\text{nm}$, shown in Fig.~\ref{fig:stability}~(c). The chiralities of vortex-like states in both layers are the same, but their polarisations are opposite and a Bloch point emerges between them. For $h_\text{top} \ge 9 \,\text{nm}$ and above, the energy contribution of the top layer to the total energy of the system becomes significant. Therefore, the top layer now does not follow the polarisation of the bottom layer, but reverses its polarisation to follow the left hand rule. It is now energetically cheaper for the system to host a Bloch point than to tolerate the top layer following the polarisation of the bottom layer and having high energy density. The location marked by a circle in the middle of the sample in Fig.~\ref{fig:stability}~(c) identifies a Bloch point: a noncontinuous singularity in the magnetisation vector field where the magnetisation magnitude vanishes to zero~\cite{Feldtkeller1965, Doring1968}. Because micromagnetic models assume constant magnetisation magnitude, the precise magnetisation configuration at the Bloch point cannot be obtained using micromagnetic simulations~\cite{Andreas2014}. However, it is known how to identify the signature of a Bloch point in such situations: the magnetisation direction covers any sufficiently small closed surface surrounding the Bloch point exactly once~\cite{Slonczewski1975, Thiaville2003}. We illustrate this property in Fig.~\ref{fig:stability}~(d). \subsection{Hysteretic behaviour} In the previous section we demonstrated the existence and stability of a Bloch point in the proposed system at zero external magnetic field. In all relaxation simulations so far, we started the relaxation from the uniform magnetisation configuration in the positive out-of-plane ($+z$) direction which resulted in the vortex-like state in the bottom layer with the $+z$ polarisation. Furthermore, for $h_\text{top} \ge 9 \,\text{nm}$, top layer relaxed in the vortex-like configuration with negative $-z$ polarisation. This resulted in a head-to-head Bloch point as we showed in Fig.~\ref{fig:stability}~(d). At this point, we can assume that if we started our relaxations from the uniform configuration in the $-z$ direction, the polarisations of the bottom and the top layer would be in $-z$ and $+z$ directions, respectively. Consequently, a tail-to-tail Bloch point would emerge. Motivated by this assumption and knowing that uniform magnetisation configurations can be obtained by applying a sufficiently strong external magnetic field, we now explore the hysteretic behaviour of the proposed system in order to verify our assumption. We fix the thickness of the bottom layer with $D<0$ to be $20 \,\text{nm}$ as before and set the thickness of the top layer with $D>0$ to be $10 \,\text{nm}$ so that we can expect a Bloch point to emerge. The diameter of the disk is $150 \,\text{nm}$. We apply an external magnetic field in the out-of-plane $+z$ direction and vary it between $1 \,\text{T}$ and $-1 \,\text{T}$ in steps of $0.1 \,\text{T}$. We simulate the hysteretic behaviour in the standard way by relaxing the system to an equilibrium state after changing the external magnetic field, and then using the resulting state as the starting point for a new energy minimisation. We show the average out-of-plane magnetisation component $\langle m_{z}\rangle$ as a function of an external magnetic field $\mu_{0}H$ in Fig.~\ref{fig:hysteresis}~(a). From this plot, we see that hysteretic behaviour of the simulated system is evident and now we investigate what are the equilibrium magnetisation states at zero external magnetic field. \begin{figure} \includegraphics{hysteresis.eps} \caption{\label{fig:hysteresis} \textbf{Hysteretic behaviour and two different Bloch point configurations.} (\textbf{a})~Average out-of-plane magnetisation $\langle m_{z} \rangle$ as a function of external magnetic field $\mu_{0}H$. Two Bloch point configurations at zero external magnetic field: (\textbf{b})~head-to-head and (\textbf{c})~tail-to-tail.} \end{figure} We start our hysteresis simulations with $1 \,\text{T}$ external magnetic field, which saturates the sample magnetisation in the $+z$ direction. By reducing the external magnetic field in steps of $0.1 \,\text{T}$, we reach $\mu_{0}H=0$ and plot the equilibrium magnetisation vector field together with $m_{z}$ scalar field in the $xz$ cross section containing the disk sample centre in Fig.~\ref{fig:hysteresis}~(b). We see that bottom and top layers relax in vortex-like magnetisation configurations with the same handedness, but with $+z$ and $-z$ polarisations, respectively. This results in a head-to-head Bloch point as we observed in the previous section. Now, we keep reducing the external magnetic field and when we reach $-1 \,\text{T}$, the sample is again fully saturated, but this time in the $-z$ direction. Starting from this magnetisation state, we increase the field in same steps until we reach $\mu_{0}H=0$, and plot the $xz$ cross section of the equilibrium state in Fig.~\ref{fig:hysteresis}~(c). Bottom and top layers are now hosting vortex-like states with the same handedness, but now with $-z$ and $+z$ polarisations, respectively. Therefore, a tail-to-tail Bloch point configuration is formed. Finally, we keep increasing an external magnetic field until we reach the $1 \,\text{T}$ value from which we started the hysteresis loop simulation. We show the evolution of the magnetisation field in the $xz$ cross section through the entire hysteresis loop in Supplementary Video 1. We demonstrated that the studied system undergoes hysteretic behaviour and that two different types of Bloch point configurations can emerge. In addition, by applying an external magnetic field, one can manipulate the Bloch point and switch between head-to-head and tail-to-tail configurations. \subsection{Creation mechanism} Now, we explore how the Bloch point is created in the sample. We simulate the same sample we used in hysteresis simulations, but this time we do not apply an external magnetic field. We start by initialising the system in the positive out-of-plane $+z$ direction. After that, we let the magnetisation evolve towards its equilibrium state and record the magnetisation configuration every $1 \,\text{ps}$. We set the Gilbert damping value to the experimentally measured value~\cite{Beg2017} $\alpha=0.28$. In Fig.~\ref{fig:creation}~(a) we show time evolutions of the normalised topological charge $\tilde{Q}$ as well as the average out-of-plane magnetisation component $\langle m_{z} \rangle$ for both bottom and top layers individually. \begin{figure} \includegraphics{creation.eps} \caption{\label{fig:creation} \textbf{Time evolution and the Bloch point creation mechanism.} (\textbf{a})~Time evolution of the normalised topological charge $\tilde{Q}$ and the average out-of-plane magnetisation component $\langle m_{z} \rangle$ for the bottom and top layers individually. (\textbf{b})~Snapshots of the magnetisation configuration in the $xz$ cross section containing the sample centre at different points in time.} \end{figure} Starting from $\tilde{Q}_\text{bottom} = \tilde{Q}_\text{top} = 0$ and $\langle m_{z} \rangle_\text{bottom} = \langle m_{z} \rangle_\text{top} = 1$ at $t=0 \,\text{ps}$, which corresponds to the initial uniform state, all quantities evolve. In order to explore how the Bloch point is created in the sample, we show snapshots at different points in time in Fig.~\ref{fig:creation}~(b). We show the magnetisation vector field together with the $m_{z}$ scalar field in the $xz$ cross section containing the centre of the sample. By locating a Bloch point in the magnetisation fields (denoted in magnetisation field plots) in Fig.~\ref{fig:creation}~(b), we explore its creation mechanism. Starting from the uniform configuration at $t=0 \,\text{ps}$, until approximately $t = 55 \,\text{ps}$ the magnetisations in both layers evolve so that vortex-like states with the same handedness and polarisation are formed. At $t=58 \,\text{ps}$ we identify that the polarisation of the top layer begins to reverse and a Bloch point is formed at the top boundary of the sample. Furthermore, Bloch point propagates downwards - towards the interface between layers, until it eventually reaches its final position at $t=80 \,\text{ps}$. We notice that the Bloch point creation mechanism is based on the polarisation (core orientation) reversal of the top layer which is the same as the reversal mechanism for skyrmionic states in confined helimagnetic nanostructures~\cite{Beg2015}. More precisely, in the process of reversal of the top layer polarisation, the Bloch point is created in the same way - at the boundary, propagating through the thickness of the sample and sitting at the interface between layers rather than being expelled out of the sample. We show the entire creation mechanism in the $xz$ cross section of the sample in Supplementary Video 2. \section{Discussion} Using finite element micromagnetic simulations, we studied nanostructures composed of two layers with different handedness. We found that for certain thicknesses of individual layers, a stable Bloch point can emerge at the interface between the two layers. By applying an external magnetic field we found that the system undergoes hysteretic behaviour and two different types of Bloch point configurations exist. In the first, the magnetisation at the centre of each layer points towards the interface - the head-to-head configuration. In the second, the magnetisation points away from the interface towards the outer surface of the disk - the tail-to-tail configuration. We demonstrated the switch between these two different types of Bloch point using an external magnetic field. Finally, we simulated the time evolution in order to determine the mechanism by which the Bloch point is created, showing that the Bloch point is created at the boundary of the thinner layer and then propagates through the thickness of the sample until it reaches the boundary between layers where it sits. Now, we discuss our findings focusing on four main topics: (i) the possibility of fabrication, (ii) the suitability of micromagnetic simulations for the study of Bloch points, (iii) similarities and differences of our studied system with previous works, and (iv) implications of our results. We based our simulations on realistic FeGe material parameters~\cite{Beg2015} for a realistically sized disk in order to encourage the experimental verification of our predictions. In addition, in all of our simulations we used a uniform magnetisation configuration as an initial magnetisation state which is feasible to obtain in an experimental setup by applying a strong field. More precisely, applying an external magnetic field of approximately $1 \,\text{T}$, and then removing it, should allow the system to relax into the magnetisation configuration containing a Bloch point. However, before our predictions can be validated, one should be able to grow a helimagnetic thin film which consists of two layers with different chirality. More precisely, in the growth of a thin film, it is necessary to be able to switch the Dzyaloshinskii-Moriya energy constant $D$ once a layer of sufficient thickness has been grown. Recent research by Spencer at al.~\cite{Spencer2018} demonstrated that by changing the Co content $y$ in Fe$_{1-y}$Co$_{y}$Ge compound grown on Si(111), it is possible not only to modify the value of the DMI constant, but also to change its sign. This finding may contribute to the growth of a thin film system, composed of two layers with different chirality in order to fabricate our proposed system hosting a stable and manipulable Bloch point. In this work, we used finite elements to discretise the continuous magnetisation fields. Because of the imposition of a constant magnetisation saturation in micromagnetics, this method is inaccurate to determine the Bloch point structure~\cite{Andreas2014}. This is because at the Bloch point the magnetisation vanishes to zero~\cite{Feldtkeller1965, Doring1968}. However, it is well known that micromagnetics can provide us enough information to determine whether the Bloch point is present in the sample and its position, by analysing the magnetisation field on a sufficiently small closed surface surrounding the Bloch point. More precisely, it is necessary for the magnetisation direction to cover a sufficiently small closed surface surrounding the Bloch point exactly once~\cite{Slonczewski1975, Thiaville2003}. Using this condition we were able to determine the existence and the position of a Bloch point. However, because of the imposed constant magnetisation saturation, we did not attempt to determine its internal structure, which was not the topic of this work. As an example of suitability of micromagnetics to determine the existence of a Bloch point, Rybakov et al.~\cite{Rybakov2015} predicted, using micromagnetic simulations, the existence of a chiral bobber - a hybrid particle emerging at the surface of chiral magnets composed of both smooth magnetisation configuration and a Bloch point. The existence of a Bloch point as a part of chiral bobber was then experimentally confirmed in FeGe~\cite{Ahmed2018, Zheng2018}, demonstrating the validity of the micromagnetic predictions. To some extent similar concept was introduced by Zhang et al.~\cite{Zhang2016}, where two ferromagnetic layers hosting skyrmions were antiferromagnetically coupled in order to suppress the skyrmion Hall effect, when skyrmions are driven using spin-polarised currents. However, in that system, no Bloch point can emerge between two skyrmions with different polarisations because they are physically separated by an insulating spacer of non-zero thickness. On the other hand, we achieve different polarisations (in our case, of vortex-like states) by stacking helimagnetic layers with different chirality. Because of that, there is no insulating spacer between the two layers with different chiralities and a Bloch point can be identified. Our discovery of a stable and manipulable Bloch point in a planar magnetic system could add the Bloch point to the collection of already existing and well studied particle-like magnetic configurations that could possibly change the way we store and process data. Now, we discuss and speculate about the possibilities of how the Bloch point we explored in this work can be employed in spintronic applications. We found two different Bloch point configurations that can be switched using an external magnetic field, thus one can propose that a single information bits (0 or 1) can be encoded using the type of a Bloch point (HHBP or TTBP) -- similar to the bit-patterned media. However, from the hysteresis simulations, we saw that the average out-of-plane component of magnetisation $\langle m_{z} \rangle$ at zero field is almost zero due to the symmetry of the magnetisation field. This poses a difficulty for reading such information bits. A possible solution is to increase the thickness of the bottom layer, which does not affect the stability of the Bloch point, but increases $\langle m_{z} \rangle$ at zero field. Furthermore, our initial studies show that the Bloch point does not emerge only is disk geometries, but also in a wide variety of different geometries, such as nanostrips. In this case, the manipulation of a Bloch point is not only limited to its type, but also its position in the sample. This manipulation can be achieved using an external excitation, for instance, external magnetic fields or spin-polarised currents. However, a Bloch point coupling to such external excitations is beyond the scope of this work and should be a topic of further research. All results obtained in this work can be reproduced from the repository in Ref.~\onlinecite{Repository}, which contains micromagnetic simulation, data analysis, and plotting scripts. \section{Methods} In our simulations, magnetisation dynamics is governed by the Landau-Lifshitz-Gilbert (LLG) equation~\cite{Landau1935, Gilbert2004} \begin{equation} \label{eq:llg_equation} \frac{\partial \mathbf{m}}{\partial t} = -\gamma_{0}^{*} \mathbf{m} \times \mathbf{H}_\text{eff} + \alpha\mathbf{m} \times \frac{\partial \mathbf{m}}{\partial t}, \end{equation} where $\gamma_{0}^{*} = \gamma_{0} (1+\alpha^{2})$, with $\gamma_{0} = 2.21 \times 10^{5} \,\text{m}\,\text{A}^{-1}\text{s}^{-1}$ and $\alpha \ge 0$ is the Gilbert damping. We compute the effective magnetic field $\mathbf{H}_\text{eff}$ using \begin{equation} \mathbf{H}_\text{eff} = -\frac{1}{\mu_{0}M_\text{s}} \frac{\delta E[\mathbf{m}]}{\delta \mathbf{m}}, \end{equation} where $E[\mathbf{m}]$ is the total energy functional, and contains several energy contributions: \begin{equation} \label{eq:total_energy} E = \int \left[ w_\text{ex} + w_\text{dmi} + w_\text{z} + w_\text{d} \right] \,\text{d}^{3}r. \end{equation} The first term $w_\text{ex} = A \left[ (\nabla m_{x})^{2} + (\nabla m_{y})^{2} + (\nabla m_{z})^{2} \right]$ with material parameter $A$ in Eq.~\ref{eq:total_energy} is the energy density of the symmetric exchange contribution. The unit vector field $\mathbf{m}$, with Cartesian components $m_{x}$, $m_{y}$, and $m_{z}$, represents the normalised magnetisation field $\mathbf{M} = M_\text{s}\mathbf{m}$, where $M_\text{s}$ is the saturation magnetisation. The second term $w_\text{dmi} = D \mathbf{m} \cdot \left(\nabla \times \mathbf{m} \right)$ with material parameter $D$ is the Dzyaloshinskii-Moriya (DM) energy density. This form of DM energy density is obtained by including Lifshitz invariants for materials of crystallographic classes T and O. The coupling of magnetisation to an external magnetic field $\mathbf{H}$ is defined by the Zeeman energy density term $w_\text{z} = - \mu_{0}M_\text{s}\mathbf{H} \cdot \mathbf{m}$, with $\mu_{0}$ being the magnetic constant. The $w_\text{d}$ term is the demagnetisation (magnetostatic) energy density. Because demagnetisation energy cannot be neglected in the study of FeGe helimagnetic nanostructures~\cite{Beg2015, Vousden2016, Carey2016, Beg2017} we include its contribution in all simulations. We assume the simulated material is isotropic and neglect the magnetocrystalline anisotropy energy contribution. The specific boundary conditions~\cite{Rohart2013} have been validated by a series of standard problem simulations proposed by Cort\'{e}s-Ortu\~{n}o et al.~\cite{Cortes2018}. The FeGe material parameters we use are:~\cite{Beg2015} saturation magnetisation $M_\text{s} = 384 \,\text{kA}\,\text{m}^{-1}$, exchange energy constant $A = 8.78 \,\text{pJ}\,\text{m}^{-1}$, and Dzyaloshinskii-Moriya energy constant $|D| = 1.58 \,\text{mJ}\,\text{m}^{-2}$. The relevant length scales are the exchange length $l_\text{ex} = \sqrt{2A/\mu_{0}M_\text{s}^{2}} = 9.73 \,\text{nm}$ and helical length $L_\text{D} = 4\pi A/D = 70 \,\text{nm}$. We discretise the finite element mesh so that the maximum spacing between two neighbouring mesh nodes is below $l_\text{max} = 3 \,\text{nm}$. We implemented this micromagnetic model in the finite element method framework and developed a micromagnetic simulation tool Finmag~\cite{Finmag}. For the low-level finite element operations, we use the FEniCS project~\cite{Logg2012} and for the adaptive step time integration we use Sundials/CVODE solver~\cite{Hindmarsh2005, Cohen1996}. \bibliographystyle{naturemag}
\section{Motivation} The purpose of this article is to present a convergence analysis of an explicit $P1$ finite element solution scheme of hyperbolic Maxwell's equations for the electric field with constant dielectric permittivity in a neighborhood of the boundary of the computational domain. The technique of analysis is inspired by those developed in \cite{Ruas, Thomee}.\\ The standard continuous $P1$ FEM is a tempting possibility to solve Maxwell's equations, owing to its simplicity. It is well known however that, for different reasons, this method is not always well suited for this purpose. The first reason is that in general the natural function space for the electric field is not the Sobolev space ${\bf H}^1$, but rather in the space ${\bf H}(curl)$. Another issue difficult to overcome with continuous Lagrange finite elements is the prescription of the zero tangential-component boundary conditions for the electric field, which hold in many important applications. All this motivated the proposal by N\'ed\'elec about four decades ago of a family of ${\bf H}(curl)$-conforming methods to solve these equations (cf. \cite{Nedelec}). These methods are still widely in use, as much as other approaches well adapted to such specific conditions (see e.g. \cite{Assous}, \cite{CiarletJr} and \cite{AMIS}). A comprehensive description of finite element methods for Maxwell's equations can be found in \cite{Monk}. \\ \indent There are situations however in which the $P1$ finite element method does provide an inexpensive and reliable way to solve the Maxwell's equations. In this work we consider one of such cases, characterized by the fact that the electric permittivity is constant in a neighborhood of the whole boundary of the domain of interest. This is because, at least in theory, whenever the electric permittivity is constant, the Maxwell's equations simplify into as many wave equations as the space dimension under consideration. More precisely we show here that, in such a particular case, a space discretization by means of conforming linear elements, combined with a straightforward explicit finite-difference scheme for the time discretization, gives rise to optimal approximations of the electric field, as long as a classical CFL condition is satisfied. \\ \indent Actually this work can be viewed as both a continuation and the completion of studies presented in \cite{BG, cejm} for a combination a the finite difference method in a sub-domain with constant permittivity with the finite element method in the complementary sub-domain. As pointed out above, the Maxwell's equations reduces to the wave equation in the former case. Since the analysis of finite-difference methods for this type of equation is well established, only an explicit $P1$ finite element scheme for Maxwell's equations is analyzed in this paper. \\ \indent In \cite{BG, cejm} a stabilized domain-decomposition finite-element/finite-difference approach for the solution of the time-dependent Maxwell's system for the electric field was proposed and numerically verified. In these works \cite{BG, cejm} different manners to handle a divergence-free condition in the finite-element scheme were considered. The main idea behind the domain decomposition methods in \cite{BG, cejm} is that a rectangular computational domain is decomposed into two sub-domains, in which two different types of discretizations are employed, namely, the finite-element domain in which a classical $P1$ finite element discretization is used, and the finite-difference domain, in which the standard five- or seven-point finite difference scheme is applied, according to the space dimension. The finite element domain lies strictly inside the finite difference domain, in such a way that both domains overlap in two layers of structured nodes. First order absorbing boundary conditions \cite{EM} are enforced on the boundary of the computational domain, i.e. on the outer boundary of the finite-difference domain. In \cite{BG, cejm} it was assumed that the dielectric permittivity function is strictly positive and has a constant value in the overlapping nodes as well as in a neighborhood of the boundary of the domain. An explicit scheme was used both in the finite-element and finite-difference domains. \\%so that P1 finite element method was \indent We recall that for a stable finite-element solution of Maxwell's equation divergence-free edge elements are the most satisfactory from a theoretical point of view ~\cite{Nedelec, Monk}. However, the edge elements are less attractive for solving time-dependent problems, since a linear system of equations should be solved at every time iteration. In contrast, $P1$ elements can be efficiently used in a fully explicit finite element scheme with lumped mass matrix \cite{delta, joly}. On the other hand it is also well known that the numerical solution of Maxwell's equations with nodal finite elements can result in unstable spurious solutions \cite{MP, PL}. Nevertheless a number of techniques are available to remove them, and in this respect we refer for example to \cite{Jiang1, Jiang2, Jin, div_cor, PL}. In the current work, similarly to \cite{BG, cejm}, the spurious solutions are removed from the finite element scheme by adding the divergence-free condition to the model equation for the electric field. Numerical tests given in \cite{cejm} demonstrate that spurious solutions are removable indeed, in case an explicit $P1$ finite-element solution scheme is employed.\\ \indent Efficient usage of an explicit $P1$ finite-element scheme for the solution of coefficient inverse problems (CIPs), in the particular context described above was made evident in \cite{BK}. In many algorithms aimed at solving electromagnetic CIPs, a qualitative collection of experimental measurements is necessary on the boundary of a computational domain, in order to determine the dielectric permittivity function therein. In this case, in principle the numerical solution of the time-dependent Maxwell's equations is required in the entire space $\mathbb{R}^{3}$ (see e.g. \cite{BK, BCN, BTKM, MalmbergBeilina1, MalmbergBeilina2, Malmberg}, but instead it can be more efficient to consider Maxwell's equations with a constant dielectric permittivity in a neighborhood of the boundary of a computational domain. The explicit $P1$ finite-element scheme considered in this work was numerically tested in the solution of the time-dependent Maxwell's system in both two- and three-dimensional geometry (cf. \cite{cejm}). It was also combined with a few algorithms to solve different CIPs for determining the dielectric permittivity function in connection with the time-dependent Maxwell's equations, using both simulated and experimentally generated data (see \cite{BCN, BTKM, MalmbergBeilina1, MalmbergBeilina2, Malmberg}). In short, the formal reliability analysis of such a method conducted in this work, corroborates the previously observed adequacy of this numerical approach.\\ An outline of this paper is as follows: In Section 2 we describe in detail the model problem being solved, and give its equivalent variational form. In Section 3 we set up the discretizations of the model problem in both space and time. Section 4 is devoted to the stability analysis of the explicit scheme considered in the previous section, and Section 5 to the corresponding consistency study. Next we combine the results of the two previous sections to prove error estimates in Section 6. Underlying convergence results under the very realistic assumption that the time step varies linearly with the mesh size as the meshes are refined are thus established. In Section 7 we present a numerical validation of our scheme. Finally we conclude in Section 8 with a few comments on the whole work. \section{The model problem} The Maxwell's equations for the electric field ${\bf e}=(e_1, e_2, e_3)$ in a bounded domain $\Omega$ of $\Re^3$ with boundary $\partial \Omega$ that we study in this work is as follows. First we consider that $\Omega = \bar{\Omega}_{in} \cup \Omega_{out}$, where $\Omega_{in}$ is an interior open set whose boundary does not intersect $\partial \Omega$ and $\Omega_{out}$ is the complementary set of $\bar{\Omega}_{in}$ with respect to $\Omega$. ${\bf n}$ being the unit outer normal vector on $\partial \Omega$ we denote by $\partial_n(\cdot)$ the outer normal derivative of a field on $\partial \Omega$. Now in case ${\bf e}$ satisfies absorbing boundary conditions, given ${\bf e}_0 \in [H^1(\Omega)]^3$ and ${\bf e}_1 \in {\bf H}(div,\Omega)$ satisfying $\nabla \cdot (\varepsilon {\bf e}_0) = \nabla \cdot (\varepsilon {\bf e}_1) = 0$ where $\varepsilon$ is the electric permittivity. $\varepsilon$ is assumed to belong to $C^{2,\infty}(\bar{\Omega})$ and to fulfill $\varepsilon \equiv 1 $ in $\Omega_{out}$ and $\varepsilon \geq 1$. Incidentally, throughout this article we denote the standard semi-norm of $C^m(\bar{\Omega})$ by $| \cdot |_{m,\infty}$ for $m >0$ and the standard norm of $C^{0}(\bar{\Omega})$ by $\| \cdot \|_{0,\infty}$. \\ \indent In doing so, the problem to solve is: \begin{equation}\label{eq1} \begin{array}{ll} \varepsilon \partial_{tt} {\bf e} + \nabla \times \nabla \times {\bf e} = {\bf 0} & \mbox{ in } \Omega \times (0, T), \\ {\bf e}(\cdot,0) = {\bf e}_0(\cdot), \mbox{ and } \partial_t{\bf e}(\cdot,0) = {\bf e}_1(\cdot) & \mbox{ in } \Omega, \\ \partial _{n} {\bf e} = - \partial_t {\bf e} & \mbox{ on } \partial \Omega \times (0,T), \\ \nabla \cdot (\varepsilon {\bf e}) = {\bf 0} & \mbox{ in } \Omega. \end{array} \end{equation} \begin{remark} The study that follows also apply to the case where boundary conditions other than absorbing boundary conditions $\partial_n {\bf e}=-\partial_t {\bf e}$ are prescribed, for which the same qualitative results hold. As pointed out in Section 1, the choice of the latter here was motivated by the fact that they correspond to practical situations addressed in \cite{BCN, BTKM, MalmbergBeilina1,MalmbergBeilina2, Malmberg}. \rule{2mm}{2mm} \end{remark} \begin{remark} The assumption that $\varepsilon$ attains a minimum in an outer layer is not essential for our numerical method to work. However, as far as we can see, it is a condition that guarantees optimal convergence results. In the final section a more elaborated discussion on this issue can be found. \rule{2mm}{2mm} \end{remark} \subsection{Variational form} Let us denote the standard inner product of $[L^2(\Omega)]^M$ by $(\cdot,\cdot)$ for $M \in \{1,2,3\}$ and the corresponding norm by $\parallel \{\cdot\} \parallel$. Similarly we denote by $(\{\cdot\},\{\cdot\})_{\partial \Omega}$ the standard inner product of $[L^2(\partial \Omega)]^M$ and the associated norm by $\| \{\cdot\} \|_{\partial \Omega}$. Further, for a given negative function $\omega \in L^{\infty}(\Omega)$ we introduce the weighted $L^2(\Omega)$-semi-norm $\| \{\cdot\} \|_{\omega}:=\sqrt{\int_{\Omega} |\omega| |\{\cdot\}|^2 d{\bf x}}$, which is actually a norm if $\omega \neq 0$ everywhere in $\bar{\Omega}$. We also introduce, the notation $(A,B)_{\omega}:= \int_{\Omega} \omega A \cdot B d{\bf x}$ for two fields $A,B$ which are square integrable in $\Omega$. Notice that if $\omega$ is strictly positive this expression defines an inner product associated with the norm $\| \{\cdot\} \|_{\omega}$.\\ Then requiring that ${\bf e}_{|t=0} = {\bf e}_0$ and $\{\partial_t{\bf e}\}_{|t=0} = {\bf e}_1$, we write for all $ {\bf v} \in [H^1(\Omega)]^3$, \begin{equation}\label{eq2} \left (\partial_{tt} {\bf e},{\bf v} \right )_{\varepsilon} + (\nabla {\bf e},\nabla {\bf v}) + (\nabla \cdot \varepsilon {\bf e}, \nabla \cdot {\bf v}) - (\nabla \cdot {\bf e}, \nabla \cdot {\bf v}) + (\partial_t{\bf e}, {\bf v})_{\partial \Omega} = 0 \;\forall t \in (0, T). \end{equation} Problem (\ref{eq2}) is equivalent to Maxwell's equations \eqref{eq1}. Indeed integrating by parts \eqref{eq2}, for all $ {\bf v} \in [H^1(\Omega)]^3$ we get, \begin{equation}\label{eq3} \begin{array}{l} \left ( \partial_{tt} {\bf e},{\bf v} \right )_{\varepsilon} + ( \nabla \times \nabla \times {\bf e}, {\bf v}) - (\nabla \nabla \cdot \varepsilon {\bf e},{\bf v}) \\ + \left(\partial_n{\bf e} + \partial_t {\bf e},{\bf v} \right)_{\partial \Omega} + (\nabla \cdot \varepsilon {\bf e} - \nabla \cdot {\bf e}, {\bf v} \cdot {\bf n} )_{\partial \Omega} = 0 \end{array} \end{equation} Noting that $\varepsilon=1$ on $\partial \Omega$ we get \begin{equation}\label{eq3bis} \begin{array}{ll} \varepsilon \partial_{tt} {\bf e} + \nabla \times \nabla \times {\bf e} - \nabla (\nabla \cdot \varepsilon {\bf e}) = 0 & \mbox{ in } \Omega \times (0, T),\\ \partial _{n} {\bf e} = - \partial_t {\bf e} & \mbox{ on } \partial \Omega \times (0,T). \end{array} \end{equation} This implies that $\nabla \cdot (\varepsilon {\bf e})=0$. Indeed, let $\tilde{{\bf e}}$ be the unique solution of the Maxwell's equations \begin{equation}\label{eq4} \begin{array}{ll} \varepsilon \partial_{tt} \tilde{\bf e} + \nabla \times \nabla \times \tilde{\bf e} = 0 & \mbox{ in }\Omega \times (0, T), \\ \tilde{\bf e}(\cdot,0) = {\bf e}_0(\cdot) \mbox{ and } \partial_t \tilde{\bf e}(\cdot,0) = {\bf e}_1(\cdot) & \mbox{ in } \Omega, \\ \partial_{n} \tilde{\bf e} = - \partial_t \tilde{\bf e} & \mbox{ on } \partial \Omega \times (0,T), \\ \nabla \cdot ( \varepsilon \tilde{\bf e}) = 0 & \mbox{ in } \Omega. \end{array} \end{equation} Using the well-known operator identity $-\nabla^2 (\cdot)= \nabla \times \nabla \times (\cdot) - \nabla \nabla \cdot (\cdot)$, $\bar{{\bf e}} := {\bf e} - \tilde{{\bf e}}$ is easily seen to fulfill : \begin{equation}\label{eq5} \begin{array}{ll} \varepsilon \partial_{tt} \bar{\bf e} - \nabla^2 \bar{{\bf e}} - \nabla \nabla \cdot (\varepsilon - 1) \bar{{\bf e}} = {\bf 0} & \mbox{ in } \Omega \times (0, T), \\ \bar{{\bf e}}(\cdot,0) = {\bf 0} \mbox{ and } \partial_t \bar{\bf e}(\cdot,0) = {\bf 0} & \mbox{ in } \Omega, \\ \partial_{n} \bar{{\bf e}} = - \partial_t \bar{\bf e} & \mbox{ on } \partial \Omega \times (0,T). \end{array} \end{equation} Now we multiply both sides of (\ref{eq5}) by ${\bf v} \in [H^1(\Omega)]^3$ and integrate the resulting relation in $\Omega$. Since $(\nabla \cdot (\varepsilon-1) \bar{\bf e}, {\bf v} \cdot {\bf n} )_{\partial \Omega}=0$, after integration by parts we obtain: \begin{equation}\label{aux0} \begin{array}{ll} (\partial_{tt} \bar{\bf e}, {\bf v})_{\varepsilon} + (\nabla \bar{{\bf e}},\nabla {\bf v}) + (\nabla \cdot \bar{{\bf e}},\nabla \cdot {\bf v})_{\varepsilon - 1} + (\partial_t \bar{\bf e},{\bf v})_{\partial \Omega} = 0 & \forall t \in (0,T] \\ & \\ \bar{{\bf e}}(\cdot,0) = {\bf 0} \mbox{ and } \partial_t \bar{\bf e}(\cdot,0) = {\bf 0} & \mbox{ in } \Omega. \end{array} \end{equation} Next we take ${\bf v} = \partial_t \bar{\bf e}$ in (\ref{aux0}) and integrate the resulting relation in $(0,t)$ for $t \in (0,T]$. Using the zero initial conditions satisfied by $\bar{{\bf e}}$ and $\partial_t \bar{\bf e}$, we easily obtain: \begin{equation}\label{aux1} \parallel \partial_t \bar{\bf e} \parallel^2_{\varepsilon} + \parallel \nabla \bar{{\bf e}} \parallel^2 + \parallel \nabla \cdot \bar{{\bf e}} \parallel^2_{\varepsilon - 1} + \int_0^t \parallel \partial_t \bar{\bf e}(\cdot,s) \parallel_{\partial \Omega}^2 \; ds = 0. \end{equation} We readily infer from (\ref{aux1}) that $\bar{{\bf e}} \equiv 0$ and hence ${\bf e}$ is the solution of Maxwell's equations \eqref{eq1}.\\ \section{Space-time discretization} Henceforth, for the sake of simplicity, we assume that $\Omega$ is a polyhedron. \subsection{Space semi-discretization} Let $V_h$ be the usual $P1$ FE-space of continuous functions related to a mesh ${\mathcal T}_h$ fitting $\Omega$, consisting of tetrahedrons with maximum edge length $h$, belonging to a quasi-uniform family of meshes (cf. \cite{Ciarlet}). Each element $K \in {\mathcal T}_h$ is to be understood as a closed set. \\ Setting ${\bf V}_h := [V_h]^3$ we define ${\bf e}_{0h}$ (resp. ${\bf e}_{1h}$) to be the usual ${\bf V}_h$-interpolate of ${\bf e}_0$ (resp. ${\bf e}_1$). Then the space semi-discretized problem to solve is \\ \emph{Find }${\bf e}_{h}\in {\bf V}_{h}$ \emph{ such that $\forall {\bf v} \in {\bf V}_{h}$ } \begin{equation}\label{eq6} \begin{array}{l} \left ( \partial_{tt} {\bf e}_{h}, {\bf v} \right )_{\varepsilon} + (\nabla {\bf e}_h,\nabla {\bf v})+ (\nabla \cdot[\varepsilon {\bf e}_h], \nabla \cdot {\bf v} ) -(\nabla \cdot {\bf e}_h, \nabla \cdot {\bf v}) + (\partial_t {\bf e}_{h}, {\bf v})_{\partial \Omega} = 0, \\ \\ {\bf e}_h(\cdot,0) = {\bf e}_{0h}(\cdot) \mbox{ and } \partial_t {\bf e}_h(\cdot,0) = {\bf e}_{1h}(\cdot) \mbox{ in } \Omega. \end{array} \end{equation} \subsection{Full discretization} To begin with we consider a natural centered time-discretization scheme to solve \eqref{eq6}, namely: Given a number $N$ of time steps we define the time increment $\tau := T/N$. Then we approximate ${\bf e}_h(k\tau)$ by ${\bf e}_h^k$ for $k=1,2,...,N$ according to the following FE scheme for $k=1,2,\ldots,N-1$: \begin{equation}\label{eq7consist} \begin{array}{l} \displaystyle \left(\frac{{\bf e}_h^{k+1} - 2 {\bf e}_h^k + {\bf e}_h^{k-1}}{\tau^2}, {\bf v} \right)_{\varepsilon} + (\nabla {\bf e}_h^k, \nabla {\bf v}) + (\nabla \cdot \varepsilon {\bf e}_h^k, \nabla \cdot {\bf v}) - (\nabla \cdot {\bf e}_h^k, \nabla \cdot {\bf v}) \\ + \displaystyle \left(\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}}{2\tau}, {\bf v} \right)_{\partial \Omega} = 0 \; \forall {\bf v} \in {\bf V}_h,\\ \\ {\bf e}_h^0 = {\bf e}_{0h} \mbox{ and } {\bf e}_h^1 = {\bf e}_h^0 + \tau {\bf e}_{1h} \mbox{ in } \Omega. \end{array} \end{equation} Owing to its coupling with ${\bf e}_h^{k}$ and ${\bf e}_h^{k-1}$ on the left hand side of \eqref{eq7consist}, ${\bf e}_h^{k+1}$ cannot be determined explicitly by \eqref{eq7consist} at every time step. In order to enable an explicit solution we resort to the classical mass-lumping technique. We recall that for a constant $\varepsilon$ this consists of replacing on the left hand side the inner product $( {\bf u},{\bf v})_{\varepsilon}$ (resp. $({\bf u},{\bf v})_{\partial \Omega}$) by an inner product $({\bf u},{\bf v})_{\varepsilon.h}$ (resp. $({\bf u},{\bf v})_{\partial \Omega,h}$), using the trapezoidal rule to compute the integral of $\int_K \varepsilon {\bf u}_{|K} \cdot {\bf v}_{|K}d{\bf x}$ (resp. $\int_{K \cap \partial \Omega} {\bf u}_{|K} \cdot {\bf v}_{|K}dS$), for every element $K$ in ${\mathcal T}_h$, where ${\bf u}$ stands for ${\bf e}_h^{k+1} - 2 {\bf e}_h^k + {\bf e}_h^{k-1}$ (resp. ${\bf e}_h^{k+1} - {\bf e}_h^{k-1}$). It is well-known that in this case the matrix associated with $(\varepsilon {\bf e}_h^{k+1},{\bf v})_h$ (resp. $({\bf e}_h^{k+1},{\bf v})_{\partial \Omega,h}$) for ${\bf v} \in {\bf V}_h$, is a diagonal matrix. In our case $\varepsilon$ is not constant, but the same property will hold if we replace in each element $K$ the integral of $\varepsilon {\bf u}_{|K} \cdot {\bf v}_{|K}$ in a tetrahedron $K \in {\mathcal T}_h$ or of ${\bf u}_{|F} \cdot {\bf v}_{|F}$ in a face $F \subset \partial \Omega$ of a certain tetrahedron $K \in {\mathcal T}_h$ as follows: \[ \begin{array}{l} \int_K \varepsilon {\bf u}_{|K} \cdot {\bf v}_{|K} d{\bf x} \approx \varepsilon(G_K) \displaystyle volume(K) \sum_{i=1}^4 \frac{{\bf u}(S_{K,i}) \cdot {\bf v}(S_{K,i})}{4} \\ \int_{F \subset \partial \Omega} {\bf u}_{|F} \cdot {\bf v}_{|F} dS \approx \displaystyle area(F \subset \partial \Omega) \sum_{i=1}^3 \frac{{\bf u}(R_{F,i}) \cdot {\bf v}(R_{F,i})}{3}, \end{array} \] \noindent where $S_{K,i}$ are the vertexes of $K$, $i=1,2,3,4$, $G_K$ is the centroid of $K$ and $R_{F,i}$ are the vertexes of a face $F \subset \partial \Omega$ of certain tetrahedrons $K \in {\mathcal T}_h$, $i=1,2,3$.\\ Before pursuing we define the auxiliary function $\varepsilon_h$ whose value in each $K \in {\mathcal T}_h$ is constant equal to $\varepsilon(G_K)$. Furthermore we introduce the norms $\parallel \{\cdot\} \parallel_{\varepsilon_h,h}$ and $\parallel \{\cdot\} \parallel_{h}$ of $V_h$, given by $( \{\cdot\}, \{\cdot\} )_{\varepsilon_h,h}^{1/2}$ and $(\{\cdot\},\{\cdot\})_h^{1/2}$, respectively. Similarly we denote by $\parallel \{\cdot\} \parallel_{\partial \Omega,h}$ the norm defined by $(\{\cdot\},\{\cdot\})_{\partial\Omega,h}^{1,2}$. Then still denoting the approximation of ${\bf e}_h(k\tau)$ by ${\bf e}_h^k$, for $k=1,2,...,N$ we determine ${\bf e}_h^{k+1}$ by, \begin{equation}\label{eq7} \begin{array}{l} \displaystyle \left( \frac{{\bf e}_h^{k+1} - 2 {\bf e}_h^k + {\bf e}_h^{k-1}}{\tau^2}, {\bf v} \right)_{\varepsilon_h,h} + (\nabla {\bf e}_h^k, \nabla {\bf v}) + (\nabla \cdot \varepsilon {\bf e}_h^k, \nabla \cdot {\bf v}) - (\nabla \cdot {\bf e}_h^k, \nabla \cdot {\bf v}) \\ + \displaystyle \left(\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}}{2\tau}, {\bf v} \right)_{\partial \Omega,h} = 0 \; \forall {\bf v} \in {\bf V}_h,\\ \\ {\bf e}_h^0 = {\bf e}_{0h} \mbox{ and } {\bf e}_h^1 = {\bf e}_h^0 + \tau {{\bf e}_1}_h \mbox{ in } \Omega. \end{array} \end{equation} Now we recall a result given in Lemma 3 of \cite{JCAM2010}, which allows us to assert that the norm $\parallel v \parallel_{\varepsilon_h}$ is bounded above by $\parallel v \parallel_{\varepsilon_h,h}$ $\forall v \in V_h$. In order to prove such a result we use the barycentric coordinates $\lambda_{K,i}$ of tetrahedron $K \in {\mathcal T}_h$, $i=1,2,3,4$. We have $u_{|K} = \displaystyle \sum_{i=1}^4 u(S_{K,i}) \lambda_{K,i}$. Since $\int_k \lambda_{K,i} \lambda_{K,j} d{\bf x} = volume(K) (1+ \delta_{i,j})/20$, after straightforward manipulations we obtain, \[ \displaystyle \int_K \varepsilon_h u_{|K}^2 d{\bf x} \leq \displaystyle \frac{\varepsilon(G_K) volume(K)}{4} \sum_{i=1}^4 u^2(S_{K,i}). \] This immediately implies that \begin{equation} \label{upperbound} \parallel v \parallel_{\varepsilon_h} \leq \parallel v \parallel_{\varepsilon_h,h} \; \forall v \in V_h. \end{equation} For the same reason we have, \begin{equation} \label{upperboundary} \parallel v \parallel_{\partial \Omega} \leq \parallel v \parallel_{\partial \Omega,h} \; \forall v \in V_h. \end{equation} \section{Stability analysis} In order to conveniently prepare the subsequent steps of the reliability study of scheme \eqref{eq7}, following a technique thoroughly exploited in \cite{Ruas}, we carry out the stability analysis of a more general form thereof, namely: \begin{equation}\label{eq7bis} \begin{array}{l} \displaystyle \left(\frac{{\bf e}_h^{k+1} - 2 {\bf e}_h^k + {\bf e}_h^{k-1}}{\tau^2}, {\bf v} \right)_{\varepsilon_h,h} + (\nabla {\bf e}_h^k, \nabla {\bf v}) + (\nabla \cdot \varepsilon {\bf e}_h^k, \nabla \cdot {\bf v}) - (\nabla \cdot {\bf e}_h^k, \nabla \cdot {\bf v}) \\ + \displaystyle \left(\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}}{2\tau}, {\bf v} \right)_{\partial \Omega,h}= {\bf F}^k({\bf v} ) + (d^k,\nabla \cdot {\bf v}) + {\bf G}^k({\bf v}) ~ \forall {\bf v} \in {\bf V}_h,\\ \\ {\bf e}_h^0 = {\bf e}_{0h} \mbox{ and } {\bf e}_h^1 = {\bf e}_h^0 + \tau {\bf e}_{1h} \mbox{ in } \Omega. \end{array} \end{equation} \noindent where for every $k \in \{1,2,\ldots,N-1\}$, ${\bf F}^k$ and ${\bf G}^k$ are given bounded linear functionals over ${\bf V}_h$ and the space of traces over $\partial \Omega$ of fields in ${\bf V}_h$ equipped with the norms $\| \cdot \|_h$ and $\| \cdot \|_{\partial \Omega,h}$ respectively. We denote by $| {\bf F}^k |_h$ and $| {\bf G}^k |_{\partial \Omega,h}$ the underlying norms of both functionals. $d^k$ in turn is a given function in $L^2(\Omega)$ for $k \in \{1,2,\ldots,N-1\}.$\\ Taking ${\bf v}= {\bf e}_h^{k+1} - {\bf e}_h^{k-1}$ in \eqref{eq7bis} we get for $k=1,2,\ldots,N-1$, \begin{equation}\label{eq8} \begin{array}{l} \displaystyle \left( \frac{{\bf e}_h^{k+1} - 2{\bf e}_h^k + {\bf e}_h^{k-1}}{\tau}, \displaystyle \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}}{\tau} \right)_{\varepsilon_h,h} + (\nabla {\bf e}_h^k, \nabla {\bf e}_h^{k+1} - \nabla {\bf e}_h^{k-1}) \\ \\ + (\nabla \cdot \{\varepsilon - 1\} {\bf e}_h^k, \nabla \cdot {\bf e}_h^{k+1} - \nabla \cdot {\bf e}_h^{k-1}) + \displaystyle \left(\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}}{2\tau}, {\bf e}_h^{k+1} - {\bf e}_h^{k-1} \right)_{\partial \Omega.h} \\ \\ = {\bf F}^k({\bf e}_h^{k+1} - {\bf e}_h^{k-1}) + (d^k,\nabla \cdot \{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}\}) + {\bf G}^k({\bf e}_h^{k+1} - {\bf e}_h^{k-1}) \end{array} \end{equation} Noting that ${\bf e}_h^{k+1} - 2{\bf e}_h^k + {\bf e}_h^{k-1}= ({\bf e}_h^{k+1} - {\bf e}_h^k) -({\bf e}_h^k-{\bf e}_h^{k-1})$ and that $ {\bf e}_h^{k+1}-{\bf e}_h^{k-1} = ({\bf e}_h^{k+1} - {\bf e}_h^k) + ({\bf e}_h^k-{\bf e}_h^{k-1})$, the following estimate trivially holds for equation \eqref{eq7bis}: \begin{equation}\label{eq8bis} \begin{array}{l} \displaystyle \left\|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \|_{\varepsilon_h,h}^2 - \displaystyle \left\|\frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right \|_{\varepsilon_h,h}^2 +I_1 + I_2 + 2 \tau \displaystyle \left\| \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}}{2\tau} \right\|_{\partial \Omega,h}^2 \\ \leq | {\bf F}^k |_h \left\| {\bf e}_h^{k+1} - {\bf e}_h^{k-1} \right\|_{h} + \| d^k\| \|\nabla \cdot ( {\bf e}_h^{k+1} - {\bf e}_h^{k-1} )\| \\ + | {\bf G}^k |_{\partial \Omega,h} \;\left\| {\bf e}_h^{k+1} - {\bf e}_h^{k-1} \right\|_{\partial \Omega,h} \\ \mbox{where} \\ I_1:= (\nabla {\bf e}_h^k, \nabla \{{\bf e}_h^{k+1} - {\bf e}_h^{k-1} \}) ; \\ \mbox{and} \\ I_2:= (\nabla \cdot \{\varepsilon - 1\} {\bf e}_h^k, \nabla \cdot \{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}\}). \end{array} \end{equation} Next we estimate the terms $I_1$ and $I_2$ given by \eqref{eq8bis}. \\ First of all it is easy to see that \begin{equation}\label{eq9} \begin{array}{l} I_1 = \displaystyle \frac{1}{2} (\| \nabla {\bf e}_h^{k+1}\|^2 + \| \nabla {\bf e}_h^{k}\|^2 - \| \nabla ({\bf e}_h^{k+1} - {\bf e}_h^k)\|^2 ) \\ - \displaystyle \frac{1}{2} (\| \nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1}\|^2 - \| \nabla ({\bf e}_h^{k} - {\bf e}_h^{k-1})\|^2 ). \end{array} \end{equation} Next we note that, \begin{equation} \label{eq100} \begin{array}{l} I_2= J_{1} + J_{2} \\ \mbox{where } \\ J_1:= (\nabla \cdot {\bf e}_h^k, \nabla \cdot \{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}\})_{\varepsilon -1} \\ \mbox{and } \\ J_2 := (\nabla \varepsilon \cdot {\bf e}_h^k, \nabla \cdot \{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}\}). \end{array} \end{equation} Similarly to \eqref{eq9} we can write, \begin{equation} \label{eq10} \begin{array}{l} J_1 = \displaystyle \frac{1}{2} (\| \nabla \cdot {\bf e}_h^{k+1}\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{k}\|_{\varepsilon-1}^2 - \| \nabla \cdot({\bf e}_h^{k+1} - {\bf e}_h^k)\|_{\varepsilon-1}^2 ) \\ - \displaystyle \frac{1}{2} (\| \nabla \cdot {\bf e}_h^{k}\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{k-1}\|_{\varepsilon-1}^2 - \| \nabla \cdot ({\bf e}_h^{k} - {\bf e}_h^{k-1})\|_{\varepsilon-1}^2 ) \end{array} \end{equation} Now observing that $\nabla \varepsilon \equiv {\bf 0}$ on $\partial \Omega$, we integrate by parts $J_{2}$ given by \eqref{eq100}, to get \begin{equation} \label{eq11} \begin{array}{l} J_2 = -(\nabla \{\nabla \varepsilon \cdot {\bf e}_h^k\}, {\bf e}_h^{k+1} - {\bf e}_h^{k-1}). \end{array} \end{equation} Let us rewrite $J_2$ as, \begin{equation} \label{eq12bis} \begin{array}{l} J_2 = M_1 + M_2 \\ \mbox{where } \\ M_1 :=- \left (\nabla \nabla \varepsilon {\bf e}_h^k,{\bf e}_h^{k+1}- {\bf e}_h^{k-1} \right) \\ \mbox{and} \\ M_2 := - \left (\{\nabla {\bf e}_h^k\}^{\cal T} \nabla \varepsilon,{\bf e}_h^{k+1}-{\bf e}_h^{k-1} \right) \end{array} \end{equation} $M_1$ in turn can be rewritten as follows: \begin{equation}\label{eq12} \begin{array}{l} M_1 = N_1 + N_2 \\ \mbox{where} \\ N_1:= -\tau \displaystyle \left(\nabla \nabla \varepsilon {\bf e}_h^k,\frac{ {\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right) \\ \mbox{and}\\ N_2:= -\tau \displaystyle \left (\nabla \nabla \varepsilon {\bf e}_h^k,\frac{ {\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right). \end{array} \end{equation} Then we further observe that \begin{equation}\label{eq13} N_1 = -\tau^2 \displaystyle \sum_{i=1}^k \left (\nabla \nabla \varepsilon \frac{{\bf e}_h^i - {\bf e}_h^{i-1}}{\tau}, \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right) - \tau \displaystyle \left(\nabla \nabla \varepsilon {\bf e}_h^0,\frac{ {\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right). \end{equation} and hence, \begin{equation*} N_1 \geq - \tau^2 | \varepsilon |_{2,\infty} \displaystyle \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \| \displaystyle \sum_{i=1}^k \left \| \frac{{\bf e}_h^{i} - {\bf e}_h^{i-1}}{\tau} \right \| + \tau | \varepsilon |_{2,\infty} \| {\bf e}_h^0\| \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \| \end{equation*} or yet, \begin{equation*} N_1 \geq -\tau | \varepsilon |_{2,\infty} \displaystyle \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \| \left\{ \tau \sqrt{k} \left( \displaystyle \sum_{i=1}^k \left \| \frac{{\bf e}_h^{i} - {\bf e}_h^{i-1}}{\tau} \right \|^2 \right)^{1/2} + \| {\bf e}_h^0\| \right\}, \end{equation*} and noting that $k \leq T/\tau$ we get \begin{equation} \label{eq14} \begin{array}{l} N_1 \geq -\tau | \varepsilon |_{2,\infty} \displaystyle \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \| \left\{ \tau \sqrt{\frac{T}{\tau}} \left( \displaystyle \sum_{i=1}^k \left \| \frac{{\bf e}_h^{i} - {\bf e}_h^{i-1}}{\tau} \right \|^2 \right)^{1/2} + \| {\bf e}_h^0\| \right\}. \end{array} \end{equation} Applying to \eqref{eq14} Young's inequality $ab \leq \delta a^2/2 + b^2/(2 \delta)$ $\forall a, b \in \Re$ and $\delta >0$ with $\delta = 1$, we easily conclude that \begin{equation}\label{eq15} \begin{array}{l} N_1 \geq - \displaystyle \frac{\tau}{2} | \varepsilon |_{2,\infty} \displaystyle \left( 2 \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \|^2 + \tau T\displaystyle \sum_{i=1}^k \left \| \frac{{\bf e}_h^{i} - {\bf e}_h^{i-1}}{\tau} \right\|^2 + \| {\bf e}_h^0\|^2 \right). \end{array} \end{equation} Similarly to \eqref{eq15}, \begin{equation}\label{eq15bis} \begin{array}{l} N_2 \geq - \displaystyle \frac{\tau}{2} | \varepsilon |_{2,\infty} \displaystyle \left( 2 \left\|\frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right \|^2 + \tau T \displaystyle \sum_{i=1}^k \left \| \frac{{\bf e}_h^{i} - {\bf e}_h^{i-1}}{\tau} \right\|^2 + \| {\bf e}_h^0\|^2 \right). \end{array} \end{equation} Combining \eqref{eq15} and \eqref{eq15bis} we come up with \begin{equation} \label{eq15ter} \begin{array}{l} M_1 \geq -\tau | \varepsilon |_{2,\infty} \left( \displaystyle \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \|^2 +\displaystyle \left\|\frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right \|^2 + L_k \right),\\ \mbox{where} \\ L_k := \tau T \displaystyle \sum_{i=1}^k \left \| \frac{{\bf e}_h^{i} - {\bf e}_h^{i-1}}{\tau} \right\|^2 + \| {\bf e}_h^0\|^2. \end{array} \end{equation} As for $M_2$ given by (\ref{eq12bis}) we have: \begin{equation*} M_2 \geq - \left| \varepsilon \right|_{1,\infty} \left\| \nabla {\bf e}_h^k \right\| \left\| {\bf e}_h^{k+1} - {\bf e}_h^{k-1} \right\| \geq -\tau | \varepsilon|_{1,\infty} \left\| \nabla {\bf e}_h^k \right\| \displaystyle \left( \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \| + \displaystyle \left \|\frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right \| \right) \end{equation*} or yet \begin{equation} \label{eq16} M_2 \geq - \displaystyle \frac{\tau}{2} | \varepsilon|_{1,\infty} \left( 2 \| \nabla {\bf e}_h^k \|^2 + \displaystyle \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \|^2 + \displaystyle \left \|\frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right \|^2 \right). \end{equation} Now we recall \eqref{eq8bis} together with \eqref{upperboundary} and notice that for every square-integrable field ${\bf A}$ in $\Omega$ we have $\| {\bf A} \| \leq \| {\bf A} \|_{\varepsilon_h}$, Then taking into account that $\| \nabla \cdot {\bf v} \| \leq \sqrt{3} \| \nabla {\bf v} \|$ $\forall {\bf v} \in [H^1(\Omega)]^3$, and using Young's inequality with $\delta=\tau$, $\delta = 1/\tau$ and $\delta = \tau$, respectively, we easily obtain the following estimates: \begin{equation} \label{eq17} \begin{array}{l} | {\bf F}^k |_h \; \| {\bf e}_h^{k+1} - {\bf e}_h^{k-1}\| \leq \displaystyle \frac{\tau}{2} | {\bf F}^k |^2_h + \displaystyle \tau \left( \left \|\frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right \|^2_h + \displaystyle \left \|\frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right \|^2_h \right),\\ \\ \| d^k\| \; \|\nabla \cdot ( {\bf e}_h^{k+1} - {\bf e}_h^{k-1} ) \| \leq \displaystyle \frac{3}{2 \tau} \| d^k\|^2 + \tau ( \| \nabla {\bf e}_h^{k+1} \|^2 + \| \nabla {\bf e}_h^{k-1})\|^2), \\ \\ |{\bf G}^k |_{\partial \Omega,h} \displaystyle \left\| {\bf e}_h^{k+1} - {\bf e}_h^{k-1} \right\|_{\partial \Omega,h} \leq \displaystyle \frac{\tau}{2} |{\bf G}^k |_{\partial \Omega,h}^2 + 2 \tau \displaystyle \left\| \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k-1}}{2 \tau} \right\|_{\partial \Omega,h}^2.\, \end{array} \end{equation} where in the first and the second inequality we also used the fact that $\| {\bf A} \pm {\bf B} \|^2 \leq 2 (\| {\bf A} \|^2 + \| {\bf B} \|^2 )$ for all square-integrable fields ${\bf A}$ and ${\bf B}$.\\ Now we collect \eqref{eq9}, \eqref{eq100}, \eqref{eq10}, \eqref{eq11}, \eqref{eq12bis} and \eqref{eq15ter}, \eqref{eq16}, \eqref{eq17} to plug them into \eqref{eq8bis}. Using the fact that $\| \cdot \| \leq \| \cdot \|_h \leq\| \cdot \|_{\varepsilon_h}\leq \| \cdot \|_{\varepsilon_h,h}$ we obtain for $1 \leq k \leq N-1$: \begin{equation} \label{eq19} \begin{array}{l} ( A_k - B_k ) + ( C_k - D_k ) \leq \displaystyle \frac{\tau}{2}| {\bf F}^k|^2_h + \displaystyle \frac{3}{2 \tau} \| d^k\|^2 + \displaystyle \frac{\tau}{2} \left| {\bf G}^k \right|^2_{\partial \Omega_h}, \\ \mbox{where} \\ A_k:= \displaystyle \left\| \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right\|^2_{\varepsilon_h,h} - \displaystyle \frac{\tau}{2} \left( 2 + | \varepsilon |_{1,\infty} + 2 | \varepsilon |_{2,\infty} \right) \displaystyle \left\| \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right\|^2_{\varepsilon_h,h} \\ + \displaystyle \frac{1}{2} \left\{ (1-2\tau)\|\nabla {\bf e}_h^{k+1}\|^2 + (1-\tau | \varepsilon |_{1,\infty}) \| \nabla {\bf e}_h^k \|^2 \right\} \\ \\ B_k := \displaystyle \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau}\right \|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \left( 2 + | \varepsilon |_{1,\infty} + 2| \varepsilon|_{2,\infty} \right) \displaystyle \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau}\right \|^2_{\varepsilon_h,h} \\ + \displaystyle \frac{1}{2} \left\{ \left(1 + 2\tau \right) \| \nabla {\bf e}_h^{k-1}\|^2 + \left( 1 + \tau |\varepsilon|_{1,\infty} \right) \| \nabla {\bf e}_h^k\|^2 \right\} + \tau | \varepsilon |_{2,\infty} L_k\\ \\ C_k := \displaystyle -\frac{1}{2} \left\{ \|\nabla ({\bf e}_h^{k+1} - {\bf e}_h^k)\|^2 + \| \nabla \cdot ({\bf e}_h^{k+1} - {\bf e}_h^k) \|_{\varepsilon-1}^2 \right\} + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^{k+1}\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^k\|_{\varepsilon-1}^2 \right) \\ \\ D_k := \displaystyle -\frac{1}{2} \left\{ \|\nabla ({\bf e}_h^k - {\bf e}_h^{k-1})\|^2 + \| \nabla \cdot ({\bf e}_h^k - {\bf e}_h^{k-1})\|_{\varepsilon-1}^2 \right\} + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^k\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{k-1} \|_{\varepsilon-1}^2 \right). \end{array} \end{equation} Setting \begin{equation} \label{eta} \begin{array}{l} \eta := 2 + | \varepsilon |_{1,\infty} + 2| \varepsilon|_{2,\infty}; \\ \theta := | \varepsilon |_{1,\infty}; \\ \rho := T^2 | \varepsilon |_{2,\infty}, \end{array} \end{equation} we can rewrite $A_k$ and $B_k$ as follows: \begin{equation} \label{eq20} \begin{array}{l} A_k:= \displaystyle \left\| \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right\|^2_{\varepsilon_h,h} - \displaystyle \frac{\tau}{2} \eta \displaystyle \left\| \frac{{\bf e}_h^{k+1} - {\bf e}_h^{k}}{\tau} \right\|^2_{\varepsilon_h,h} \\ + \displaystyle \frac{1}{2} \left(\|\nabla {\bf e}_h^{k+1}\|^2 + \| \nabla {\bf e}_h^k \|^2 \right) -\displaystyle \tau \left( \|\nabla {\bf e}_h^{k+1}\|^2 + \frac{\theta}{2} \| \nabla {\bf e}_h^k \|^2 \right); \\ \\ B_k:= \displaystyle \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \eta \displaystyle \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} \\ + \displaystyle \frac{1}{2} \left(\|\nabla {\bf e}_h^{k-1}\|^2 + \| \nabla {\bf e}_h^k \|^2 \right) +\displaystyle \tau \left( \|\nabla {\bf e}_h^{k-1}\|^2 + \frac{\theta}{2} \| \nabla {\bf e}_h^k \|^2 \right) + \displaystyle \frac{\tau \rho}{T^2} L_k \\ \end{array} \end{equation} Then we note that for $1 \leq k \leq m - 1$ with $2 \leq m \leq N-1$, \begin{equation} \label{eq21} \begin{array}{l} A_{k-1} - B_{k} = - \displaystyle \tau \eta \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} -\displaystyle \tau \left( 1+\frac{\theta}{2} \right) \left( \|\nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1} \|^2 \right) - \displaystyle \frac{\tau \rho}{T^2} L_k. \end{array} \end{equation} It follows that \begin{equation} \label{eq21bis} \begin{array}{l} \displaystyle \sum_{k=1}^m (A_k-B_k) = A_m - B_1 + \displaystyle \sum_{k=2}^{m} (A_{k-1}-B_{k}) \\ = \displaystyle \frac{1}{2} \left( 2- \tau \eta \right) \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{1}{2} \left( 1 - 2 \tau \right) \|\nabla {\bf e}_h^{m+1}\|^2 + \displaystyle \frac{1}{2} \left( 1 - \tau \theta \right) \| \nabla {\bf e}_h^m \|^2 \\ - \displaystyle \frac{1}{2} \left( 2 + \tau \eta \right) \left\| \frac{{\bf e}_h^{1} - {\bf e}_h^{0}}{\tau} \right\|^2_{\varepsilon_h,h} - \displaystyle \frac{1}{2} \left( 1 + 2 \tau \right) \|\nabla {\bf e}_h^{0}\|^2 - \frac{1}{2} \left( 1 +\tau \theta \right) \| \nabla {\bf e}_h^1 \|^2 - \displaystyle \frac{\tau \rho}{T^2} L_1 \\ - \displaystyle \sum_{k=2}^m \left\{ \displaystyle \tau \eta \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \left( 2+ \theta \right) \left( \|\nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1} \|^2 \right) + \displaystyle \frac{\tau \rho}{T^2} L_k \right\}. \end{array} \end{equation} Now we extend to $k=1$ the summation range on the right hand side of \eqref{eq21bis} to obtain, \begin{equation} \label{eq21ter} \begin{array}{l} \displaystyle \sum_{k=1}^m (A_k-B_k) \\ = \displaystyle \frac{1}{2} \left( 2- \tau \eta \right) \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{1}{2} \left( 1 - 2 \tau \right) \|\nabla {\bf e}_h^{m+1}\|^2 + \displaystyle \frac{1}{2} \left( 1 - \tau \theta \right) \| \nabla {\bf e}_h^m \|^2 \\ - \displaystyle \frac{1}{2} \left( 2 - \tau \eta \right) \left\| \frac{{\bf e}_h^{1} - {\bf e}_h^{0}}{\tau} \right\|^2_{\varepsilon_h,h} - \displaystyle \frac{1}{2} \left( 1 - \tau \theta \right) \|\nabla {\bf e}_h^{0}\|^2 - \frac{1}{2} \left( 1 - 2 \tau \right) \| \nabla {\bf e}_h^1 \|^2 \\ - \displaystyle \sum_{k=1}^m \left\{ \displaystyle \tau \eta \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \left( 2+ \theta \right) \left( \|\nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1} \|^2 \right) + \displaystyle \frac{\tau \rho}{T^2} L_k\right\}. \end{array} \end{equation} Moreover since $C_{k-1} = D_k$ for all $m \geq k \geq 2$, recalling \eqref{eq19} we easily derive, \begin{equation} \label{eq22} \begin{array}{l} \displaystyle \sum_{k=1}^m (C_k - D_k) = C_m - D_1 \\ = - \displaystyle \frac{1}{2} \left\{ \|\nabla ({\bf e}_h^{m+1} - {\bf e}_h^m)\|^2 + \| \nabla \cdot ({\bf e}_h^{m+1} - {\bf e}_h^m)\|_{\varepsilon-1}^2 \right\} + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^{m+1}\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^m\|_{\varepsilon-1}^2 \right) \\ + \displaystyle \frac{1}{2} \left\{ \|\nabla ({\bf e}_h^1 - {\bf e}_h^{0})\|^2 + \| \nabla \cdot ({\bf e}_h^1 - {\bf e}_h^{0})\|_{\varepsilon-1}^2 \right\} - \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^1\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{0} \|_{\varepsilon-1}^2 \right). \end{array} \end{equation} Combining \eqref{eq21ter} and \eqref{eq22}, we obtain for $2 \leq m \leq N-1$: \begin{equation} \label{eq22bis} \begin{array}{l} \displaystyle \sum_{k=1}^m (A_k + C_k) - \displaystyle \sum_{k=1}^m (B_k + D_k)\\ = \displaystyle \frac{1}{2} \left( 2- \tau \eta \right) \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{1}{2} \left( 1 - 2 \tau \right) \|\nabla {\bf e}_h^{m+1}\|^2 + \displaystyle \frac{1}{2} \left( 1 - \tau \theta \right) \| \nabla {\bf e}_h^m \|^2 \\ - \displaystyle \frac{1}{2} \left( 2 - \tau \eta \right) \left\| \frac{{\bf e}_h^{1} - {\bf e}_h^{0}}{\tau} \right\|^2_{\varepsilon_h,h} - \displaystyle \frac{1}{2} \left( 1 - \tau \theta \right) \|\nabla {\bf e}_h^{0}\|^2 - \frac{1}{2} \left( 1 - 2 \tau \right) \| \nabla {\bf e}_h^1 \|^2 \\ - \displaystyle \sum_{k=1}^m \left\{ \displaystyle \tau \eta \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \left( 2 + \theta \right) \left( \|\nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1} \|^2 \right) + \displaystyle \frac{\tau \rho}{T^2} L_k \right\} \\ - \displaystyle \frac{1}{2} \left\{ \|\nabla ({\bf e}_h^{m+1} - {\bf e}_h^m)\|^2 + \| \nabla \cdot ({\bf e}_h^{m+1} - {\bf e}_h^m)\|_{\varepsilon-1}^2 \right\} + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^{m+1}\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^m\|_{\varepsilon-1}^2 \right) \\ + \displaystyle \frac{1}{2} \left\{ \|\nabla ({\bf e}_h^1 - {\bf e}_h^{0})\|^2 + \| \nabla \cdot ({\bf e}_h^1 - {\bf e}_h^{0})\|_{\varepsilon-1}^2 \right\} - \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^1\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{0} \|_{\varepsilon-1}^2 \right). \end{array} \end{equation} On the other hand, recalling \eqref{eq15ter} we note that for $2 \leq m \leq N-1$ \begin{equation} \label{eq180} \begin{array}{l} \displaystyle \sum_{k=1}^m L_k \leq \displaystyle \sum_{k=1}^m \left( \tau T \displaystyle \sum_{i=1}^m \left \|\frac{{\bf e}_h^i - {\bf e}_h^{i-1}}{\tau} \right \|^2 + \| {\bf e}_h^0\|^2 \right) = T m \tau \displaystyle \sum_{k=1}^m \left \|\frac{{\bf e}_h^k - {\bf e}_h^{k-1}}{\tau} \right \|^2 + m \| {\bf e}_h^0\|^2 \end{array} \end{equation} In short since $m \tau \leq T$, from \eqref{eq180} we easily derive for $2 \leq m \leq N-1$: \begin{equation} \label{eq18} \begin{array}{l} \displaystyle \frac{\tau \rho}{T^2} \sum_{k=1}^m L_k \leq \tau \rho \displaystyle \sum_{k=1}^m \left \|\frac{{\bf e}_h^k - {\bf e}_h^{k-1}}{\tau} \right \|^2 + \frac{\rho}{T} \| {\bf e}_h^0\|^2. \end{array} \end{equation} Plugging \eqref{eq18} into \eqref{eq22bis} and summing up both sides of \eqref{eq19} from $k=1$ through $k=m$ for $2 \leq m \leq N-1$ by using \eqref{eq20}, \eqref{eq22bis} yields: \begin{equation} \label{eq22ter} \begin{array}{l} \displaystyle \frac{1}{2} \left( 2- \tau \eta \right) \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{1}{2} \left( 1 - 2 \tau \right) \|\nabla {\bf e}_h^{m+1}\|^2 + \displaystyle \frac{1}{2} \left( 1 - \tau \theta \right) \| \nabla {\bf e}_h^m \|^2 \\ - \displaystyle \frac{1}{2} \left( 2 - \tau \eta \right) \left\| \frac{{\bf e}_h^{1} - {\bf e}_h^{0}}{\tau} \right\|^2_{\varepsilon_h,h} - \displaystyle \frac{1}{2} \left( 1 - \tau \theta \right) \|\nabla {\bf e}_h^{0}\|^2 - \frac{1}{2} \left( 1 - 2 \tau \right) \| \nabla {\bf e}_h^1 \|^2 \\ - \displaystyle \sum_{k=1}^m \left\{ \displaystyle \tau \left( \eta + \rho \right) \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \left( 2 + \theta \right) \left( \|\nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1} \|^2 \right) \right\} \\ - \displaystyle \frac{1}{2} \left\{ \|\nabla ({\bf e}_h^{m+1} - {\bf e}_h^m)\|^2 + \| \nabla \cdot ({\bf e}_h^{m+1} - {\bf e}_h^m)\|_{\varepsilon-1}^2 \right\} + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^{m+1}\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^m\|_{\varepsilon-1}^2 \right) \\ + \displaystyle \frac{1}{2} \left\{ \|\nabla ({\bf e}_h^1 - {\bf e}_h^{0})\|^2 + \| \nabla \cdot ({\bf e}_h^1 - {\bf e}_h^{0})\|_{\varepsilon-1}^2 \right\} - \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^1\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{0} \|_{\varepsilon-1}^2 \right) \\ \leq \displaystyle \sum_{k=1}^m \left(\frac{\tau}{2}| {\bf F}^k|^2_h + \displaystyle \frac{3}{2 \tau} \| d^k\|^2 + \displaystyle \frac{\tau}{2} \left| {\bf G}^k \right|^2_{\partial \Omega_h} \right) + \displaystyle \frac{\rho}{T} \| {\bf e}_h^0\|^2. \end{array} \end{equation} Thus taking into account that ${\bf e}_h^1 - {\bf e}_h^0 = \tau {\bf e}_{1h}$, leaving on the left hand side only the terms with superscripts $m+1$ and $m$, and increasing the coefficients of $\| \nabla {\bf e}_h^j \|^2$ for $j=0,1$ and $\| {\bf e}_{1h} \|_{\varepsilon_h,h}^2$, we derive for $2 \leq m \leq N-1$: \begin{equation} \label{eq23} \begin{array}{l} \displaystyle \frac{1}{2} \left( 2 - \tau \eta\right) \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{1}{2} \left( 1 - 2 \tau \right) \|\nabla {\bf e}_h^{m+1}\|^2 + \displaystyle \frac{1}{2} \left(1 - \tau \theta \right) \| \nabla {\bf e}_h^m \|^2 \\ - \displaystyle \frac{1}{2} \left\{ \|\nabla ({\bf e}_h^{m+1} - {\bf e}_h^m)\|^2 + \| \nabla \cdot ({\bf e}_h^{m+1} - {\bf e}_h^m)\|_{\varepsilon-1}^2 \right\} + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^{m+1}\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^m\|_{\varepsilon-1}^2 \right) \\ \leq \displaystyle \sum_{k=1}^m \displaystyle \left\{ \tau \left(\eta + \rho \right) \displaystyle \left\| \frac{{\bf e}^k_h-{\bf e}_h^{k-1}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \left( 2 + \theta \right) \left( \| \nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1}\|^2 \right) \right. \\ \left. + \displaystyle \frac{\tau}{2} | {\bf F}^k |^2_h + \displaystyle \frac{3}{2 \tau} \| d^k\|^2 + \displaystyle \frac{\tau}{2} \left| {\bf G}^k \right|^2_{\partial \Omega,h} \right\} + \displaystyle \left\|{\bf e}_{1h} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau^2}{2} \left( \|\nabla {\bf e}_{1h} \|^2 + \| \nabla \cdot {\bf e}_{1h} \|_{\varepsilon-1}^2 \right) \\ + \displaystyle \frac{1}{2} \left( \|\nabla {\bf e}_h^{1} \|^2 + \| \nabla {\bf e}_h^0 \|^2 \right) + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^1\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{0} \|_{\varepsilon-1}^2 \right) + \displaystyle \frac{\rho}{T} \| {\bf e}_h^0\|^2. \end{array} \end{equation} Now we recall a classical inverse inequality (cf. \cite{Ciarlet}), according to which, \begin{equation} \label{inversineq} \| \nabla v \| \leq C h^{-1} \| v \| \leq C h^{-1} \| v \|_{\varepsilon_h,h} \mbox{ for all } v \in V_h, \end{equation} where $C$ is a mesh-independent constant, and we apply the trivial upper bound $\| \nabla \cdot {\bf v} \|_{\varepsilon-1} \leq \sqrt{3 \| \varepsilon - 1 \|_{\infty} } \| \nabla {\bf v} \|$ for all ${\bf v} \in {\bf V}_h$. \\ Let us assume that $\tau$ satisfies the following CFL-condition: \begin{equation} \label{CFL} \tau \leq h /\nu \mbox{ with } \nu=C(1+ 3 \| \varepsilon - 1 \|_{\infty})^{1/2}. \end{equation} Then we have, $\forall {\bf v} \in {\bf V}_h$: \begin{equation} \label{eq16bis} \| \nabla {\bf v} \|^2 + \| \nabla \cdot {\bf v} \|_{\varepsilon-1}^2 \leq \displaystyle \nu^2 \displaystyle \frac{\tau^2}{h^2} \frac{\| {\bf v} \|^2}{\tau^2} \leq \displaystyle \frac{\| {\bf v} \|^2_{\varepsilon_h,h}}{\tau^2} \end{equation} This means that \begin{equation} \label{eq16ter} \|\nabla ({\bf e}_h^{m+1} - {\bf e}_h^m)\|^2 + \| \nabla \cdot ({\bf e}_h^{m+1} - {\bf e}_h^m)\|_{\varepsilon-1}^2 \leq \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} \end{equation} Plugging \eqref{eq16ter} into \eqref{eq23} we come up with, \begin{equation} \label{eq23bis} \begin{array}{l} \displaystyle \frac{1}{2} \left( 1- \tau \eta \right) \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{1}{2} \left(1 - 2 \tau \right)\|\nabla {\bf e}_h^{m+1}\|^2 + \displaystyle \frac{1}{2} \left(1 - \tau \theta \right) \| \nabla {\bf e}_h^m \|^2 \\ \leq \displaystyle \sum_{k=1}^m \left\{ \tau \left( \eta + \rho \right) \displaystyle \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau}\right \|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau}{2} \left( 2 + \theta \right) \left( \| \nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1}\|^2 \right) \right. \\ \left. + \displaystyle \frac{\tau}{2}| {\bf F}^k|^2_h + \displaystyle \frac{3}{2 \tau} \| d^k\|^2 + \displaystyle \frac{\tau}{2} \left| {\bf G}^k \right|^2_{\partial \Omega,h} \right\} + \displaystyle \left\|{\bf e}_{1h} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau^2}{2} \left( \|\nabla {\bf e}_{1h} \|^2 + \| \nabla \cdot {\bf e}_{1h} \|_{\varepsilon-1}^2 \right) \\ + \displaystyle \frac{1}{2} \left( \| \nabla {\bf e}_h^1 \|^2 + \|\nabla {\bf e}_h^{0} \|^2 \right) + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^1\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{0} \|_{\varepsilon-1}^2 \right) + \displaystyle \frac{\rho}{T} \| {\bf e}_h^0\|^2 . \end{array} \end{equation} Next we note that both $1 - 2 \tau$ and $1-\tau \theta$ are bounded below by $1- \tau \eta$ and moreover $\frac{1}{2}(2+\theta)$ is obviously bounded above by $\eta+\rho$. Therefore it is easy to see that \eqref{eq23bis} can be transformed into : \begin{equation} \label{eq24} \begin{array}{l} \displaystyle \frac{1}{2} \left( 1 - \tau \eta \right) \displaystyle \left( \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \|\nabla {\bf e}_h^{m+1}\|^2 + \| \nabla {\bf e}_h^m \|^2 \right) \\ \leq S_N + E_0 + \displaystyle \sum_{k=1}^m \tau \left( \eta + \rho \right) \displaystyle \left( \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau}\right \|^2_{\varepsilon_h,h} + \| \nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1}\|^2 \right), \end{array} \end{equation} \noindent where \begin{equation} \label{eq24bis} \begin{array}{l} S_N := \displaystyle \sum_{k=1}^{N-1} \left( \displaystyle \frac{\tau}{2} | {\bf F}^k|^2_h + \displaystyle \frac{3}{2 \tau} \| d^k\|^2 + \displaystyle \frac{\tau}{2} \left| {\bf G}^k \right|^2 _{\partial \Omega,h} \right) \\ \\ E_0 := \displaystyle \left\|{\bf e}_{1h} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau^2}{2} \left( \|\nabla {\bf e}_{1h} \|^2 + \| \nabla \cdot {\bf e}_{1h} \|_{\varepsilon-1}^2 \right) \\ + \displaystyle \frac{1}{2} \left( \| \nabla {\bf e}_h^1 \|^2 + \|\nabla {\bf e}_h^{0} \|^2 \right) + \displaystyle \frac{1}{2} \left( \| \nabla \cdot {\bf e}_h^1\|_{\varepsilon-1}^2 + \| \nabla \cdot {\bf e}_h^{0} \|_{\varepsilon-1}^2 \right) + \displaystyle \frac{\rho}{T} \| {\bf e}_h^0\|^2 . \end{array} \end{equation} Let us assume that $\tau \leq \displaystyle \frac{1}{2 \eta}$. Then from \eqref{eq24bis} we have \begin{equation} \label{eq25} \begin{array}{l} \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} \right\|^2_{\varepsilon_h,h} + \|\nabla {\bf e}_h^{m+1}\|^2 + \| \nabla {\bf e}_h^m \|^2 \\ \leq 4 \left\{ S_N + E_0 + \displaystyle \sum_{k=1}^m \tau \left( \eta + \rho \right) \displaystyle \left( \left\| \frac{{\bf e}_h^{k} - {\bf e}_h^{k-1}}{\tau}\right \|^2_{\varepsilon_h,h} + \| \nabla {\bf e}_h^{k}\|^2 + \| \nabla {\bf e}_h^{k-1}\|^2 \right) \right\}. \end{array} \end{equation} Now setting \begin{equation} \label{eq26} \beta= 4 N \tau (\eta + \rho) = 4 T \left\{ 2 + | \varepsilon |_{1,\infty} + (2 + T^2) | \varepsilon |_{2,\infty} \right\}, \end{equation} from the discrete Gr\"onwall's Lemma and \eqref{upperbound} from \eqref{eq25} we derive for all $m \leq N-1$: \begin{equation} \label{stability} \boxed{ \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^m}{\tau} \right\|^2 + \| \nabla {\bf e}_h^{m+1}\|^2 + \| \nabla {\bf e}_h^{m}\|^2 \leq 4 (S_N + E_0) e^{\beta}, } \end{equation} \noindent as long as $\tau \leq \min\{h/\nu ,1/(2 \eta)\}$, where $\nu$, $\eta$-$\rho$ and $\beta$ are defined in \eqref{CFL}, \eqref{eta} and \eqref{eq26}, respectively, and in the expression of $E_0$, ${\bf e}^1_h$ is to be replaced by ${\bf e}^0_h + \tau {\bf e}_{1h}$. \rule{2mm}{2mm} \section{Scheme consistency} Before pursuing the reliability study of our scheme we need some approximation results related to the Maxwell's equations. The arguments employed in this section found their inspiration in Thom\'ee \cite{Thomee} and in Ruas \cite{Ruas}. \subsection{Preliminaries} Henceforth we assume that $\Omega$ is a convex polyhedron. In this case one may reasonably assume that for every ${\bf g} \in [L^2_0(\Omega)]^3$, where $L^2_0(\Omega)$ is the subspace of $L^2(\Omega)$ consisting of functions whose integral in $\Omega$ equals zero, the solution ${\bf v}_{\bf g} \in [H^1(\Omega) \cap L^2_0(\Omega)]^3$ of the equation \begin{equation} \label{vectpoisson} \begin{array}{ll} -\nabla^2 {\bf v}_{\bf g} - \nabla [(\varepsilon - 1) \nabla \cdot {\bf v}_{\bf g}] = {\bf g} & \mbox{ in } \Omega\\ \partial_n {\bf v}_{\bf g} = {\bf 0} & \mbox{ on } \partial \Omega. \end{array} \end{equation} belongs to $[H^2(\Omega)]^3$. \\ Another result that we take for granted in this section is the existence of a constant $C$ such that, \begin{equation} \label{regularity} \forall {\bf g} \in [L^2_0(\Omega)]^3 \mbox{ it holds } \| {\mathcal H}({\bf v}_{\bf g}) \| \leq C \| {\bf g} \| , \end{equation} where ${\mathcal H}(\cdot)$ is the Hessian of a function or field. \eqref{regularity} is a result whose grounds can be found in analogous inequalities applying to the scalar Poisson problem and to the Stokes system. In fact \eqref{vectpoisson} can be viewed as a problem half way between the (vector) Poisson problem and a sort of generalized Stokes system, both with homogeneous Neumann boundary conditions. In order to create such a system we replace in \eqref{vectpoisson} $- (\varepsilon - 1) \nabla \cdot {\bf v}_{\bf g}$ by a fictitious pressure $p_{\bf g}$. Then the resulting equation is supplemented by the relation $(\varepsilon - 1) \nabla \cdot {\bf v}_{\bf g} + p_{\bf g} = 0$ in $\Omega$. Akin to the classical Stokes system, the operator associated with this system is weakly coercive over $[H^1(\Omega) \cap L^2_0(\Omega)]^3 \times L^2_0(\Omega)$ equipped with the natural norm. This can be verified by choosing in the underlying variational form a test field ${\bf w}=(\varepsilon-1/2){\bf v}_{\bf g}$ in the first equation, and a test-function $q=p_{\bf g}$ in the second equation. Thus the convexity of $\Omega$ strongly supports \eqref{regularity}.\\ Now in order to establish the consistency of the explicit scheme \eqref{eq7} we first introduce an auxiliary field $\hat{\bf e}_h(\cdot,t)$ belonging to ${\bf V}_h$ for every $t \in [0,T]$, uniquely defined up to an additive field depending only on $t$ as follows, for every $t \in [0,T]$: \begin{equation} \label{consist1} (\nabla \hat{\bf e}_h\{\cdot,t\}, \nabla {\bf v}) + (\nabla \cdot \hat{\bf e}_h\{\cdot,t\}, \nabla \cdot {\bf v})_{\varepsilon-1} = (\nabla {\bf e}\{\cdot,t\}, \nabla {\bf v}) + (\nabla \cdot {\bf e}\{\cdot,t\}, \nabla \cdot {\bf v})_{\varepsilon-1} \; \forall {\bf v} \in {\bf V}_h. \end{equation} The time-dependent additive field up to which $\hat{\bf e}_h\{\cdot,t\}$ is defined can be determined by requiring that $\int_{\Omega} \{\hat{\bf e}_h(\cdot,t)-{\bf e}(\cdot,t)\}d{\bf x} = {\bf 0}$ $\forall t \in [0,T]$.\\ Let us further assume that for every $t \in [0,T]$ ${\bf e}(\cdot,t) \in [H^2(\Omega)]^3$. In this case, from classical approximation results based on the interpolation error, we can assert that, \begin{equation} \label{consist1bis} \| \nabla \{ \hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t)\} \| + \| \nabla \cdot \{ \hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t)\} \|_{\varepsilon-1} \leq \hat{C}_1 h \| {\mathcal H}({\bf e})(\cdot,t) \| \, \forall t \in [0,T], \end{equation} where $\hat{C}_1$ is a mesh-independent constant.\\ Let us show that there exists another mesh-independent constant $\hat{C}_0$ such that for every $t \in [0,T]$ it holds, \begin{equation} \label{consist0} \| \hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t) \| \leq \hat{C}_0 h^2 \| {\mathcal H}({\bf e})(\cdot,t) \| \, \forall t \in [0,T]. \end{equation} Since $\hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t) \in [L^2_0(\Omega)]^3$ for every $t$, we may write: \begin{equation} \label{consist2} \| \hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t) \| = \displaystyle \sup_{{\bf g} \in [L^2_0(\Omega)]^3 \setminus \{{\bf 0}\}} \frac{(\hat{\bf e}_h\{\cdot,t\} - {\bf e}\{\cdot,t\},{\bf g})}{\| {\bf g} \|} \; \forall t \in [0,T]. \end{equation} Defining ${\bf W} := \{ {\bf w} \; | \; {\bf w} \in [H^2(\Omega) \cap L^2_0(\Omega)]^3 \; \partial_n {\bf w} = {\bf 0} \mbox{ on } \partial \Omega \}$, owing to \eqref{regularity} we have $\forall t \in [0,T]$: \begin{equation} \label{consist3} \| \hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t) \| \leq C \displaystyle \sup_{{\bf w} \in {\bf W} \setminus \{{\bf 0}\}} \frac{(\hat{\bf e}_h\{\cdot,t\} - {\bf e}\{\cdot,t\}, -\nabla^2 {\bf w} - \nabla \{\varepsilon - 1\} \nabla \cdot {\bf w})}{\| {\mathcal H}({\bf w}) \|}. \end{equation} Since $\partial_n {\bf w} = {\bf 0}$ and $\varepsilon =1$ on $\partial \Omega$ we may integrate by parts the numerator in \eqref{consist3} to obtain for every $t \in [0,T]$, \begin{equation} \label{consist4} \| \hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t) \| \leq C \displaystyle \sup_{{\bf w} \in {\bf W} \setminus \{{\bf 0}\}} \frac{(\nabla [\hat{\bf e}_h\{\cdot,t\} - {\bf e}\{\cdot,t\}], \nabla {\bf w}) + (\nabla \cdot [\hat{\bf e}_h\{\cdot,t\} - {\bf e}\{\cdot,t\}], \nabla \cdot {\bf w})_{\varepsilon - 1}}{\| {\mathcal H}({\bf w}) \|}. \end{equation} Taking into account (\ref{consist1}) the numerator of \eqref{consist4} can be rewritten as \[ (\nabla[\hat{\bf e}_h\{\cdot,t\} - {\bf e}\{\cdot,t\}], \nabla [ {\bf w} - {\bf v}]) + (\nabla \cdot [\hat{\bf e}_h\{\cdot,t\} - {\bf e}\{\cdot,t\}], \nabla \cdot [{\bf w}-{\bf v}])_{\varepsilon - 1} \; \forall {\bf v} \in {\bf V}_h. \] Then choosing ${\bf v}$ to be the ${\bf V}_h$-interpolate of ${\bf w}$, taking into account \eqref{consist1bis} we easily establish \eqref{consist0} with $\hat{C}_0 = C \hat{C}_1^2$.\\ To conclude these preliminary considerations, we refer to Chapter 5 of \cite{Ruas}, to conclude that the second order time-derivative $\partial_{tt} \hat{\bf e}_h(\cdot,t)$ is well defined in $[H^1(\Omega)]^3$ for every $t \in [0,T]$, as long as $\partial_{tt} {\bf e}(\cdot,t)$ lies in $[H^1(\Omega)]^3$ for every $t \in [0,T]$. Moreover, provided $\partial_{tt} {\bf e} \in [H^2(\Omega)]^3$ for every $t \in [0,T]$, the following estimate holds: \begin{equation} \label{consist0bis} \| \partial_{tt}\{\hat{\bf e}_h(\cdot,t) - {\bf e}(\cdot,t)\} \| \leq \hat{C}_0 h^2 \| {\mathcal H}(\partial_{tt}{\bf e})(\cdot,t) \| \; \forall t \in [0,T]. \end{equation} In addition to the results given in this sub-section, we recall that, according to the Sobolev Embedding Theorem, there exists a constant $C_T$ depending only on $T$ such that it holds: \begin{equation} \label{Sobolemb} \| u \|_{L^{\infty}(0,T)} \leq C_T [ \| u \|_{L^2(0,T)}^2 + \| u_t \|_{L^2(0,T)}^2 ]^{1/2} \; \forall u \in H^1(0,T). \end{equation} In the remainder of this work we assume a certain regularity of ${\bf e}$, namely, \\ \noindent \underline{\textit{Assumption}$^*$ :} The solution ${\bf e}$ to equation \eqref{eq1} belongs to $[H^4\{\Omega \times(0,T)\}]^3$. \\ \noindent Now taking $u = \| {\mathcal H}({\bf e})(\cdot,t) \|$ we have $u_t(t) = \displaystyle \frac{\int_{\Omega} \{{\mathcal H}({\bf e}) : {\mathcal H}(\partial_t{\bf e})\}({\bf x},t) d{\bf x}}{\| \{{\mathcal H}({\bf e})\}(\cdot,t)\|}$, where $:$ denotes the inner product of two constant tensors of order greater than or equal to three. Then by the Cauchy-Schwarz inequality and taking into account \textit{Assumption} $^*$, it trivially follows from \eqref{Sobolemb} that the following upper bound holds: \begin{equation} \label{hessianbound} \| \{{\mathcal H}({\bf e})\}(\cdot,t) \| \leq C_T [ \| \| {\mathcal H}({\bf e}) \| \|_{L^2(0,T)}^2 + \| \| {\mathcal H}(\partial_t{\bf e}) \| \|_{L^2(0,T)}^2 ]^{1/2} \; \forall t \in (0,T). \end{equation} In complement to the above ingredients we extend the inner products $(\cdot,\cdot)_{\varepsilon_h,h}$ and $(\cdot,\cdot)_{\partial \Omega,h}$, and associated norms $\parallel \cdot \parallel_{\varepsilon_h,h}$ and $\parallel \cdot \parallel_{\partial \Omega,h}$ in a semi-definite manner, to fields in $[L^2(\Omega)]^N$, $N \leq 3$ as follows: \\ First of all, $\forall K \in {\mathcal T}_h$ let $\Pi_K : L^2(K) \rightarrow P_1(K)$ be the standard orthogonal projection operator onto the space $P_1(K)$ of linear functions in $K$. We set \[ \forall {\bf u} \mbox{ and }{\bf v} \in [L^2(\Omega)]^N, \; ({\bf u},{\bf v})_{\varepsilon_h,h} := \displaystyle \sum_{K \in {\mathcal T}_h} \frac{\varepsilon(G_K) volume(K)}{4} \sum_{i=1}^4 \Pi_K{\bf u}(S_{K,i}) \cdot \Pi_K{\bf v}(S_{K,i}). \] Let us generically denote by $F \subset \partial \Omega$ a face of tetrahedron $K$ such that $area(K \cap \partial \Omega)>0$. Moreover we denote by $\Pi_F(v)$ the standard orthogonal projection of a function $v \in L^2(F)$ onto the space of linear functions on $F$. Similarly we define: \[ \forall {\bf u} \mbox{ and }{\bf v} \in [L^2(\partial \Omega)]^N, \; ({\bf u},{\bf v})_{\partial \Omega,h} := \displaystyle \sum_{F \subset \partial \Omega} \frac{area(F)}{3} \sum_{i=1}^3 \Pi_F{\bf u}(R_{F,i}) \cdot \Pi_F{\bf v}(R_{F,i}). \] It is noteworthy that whenever ${\bf u}$ and ${\bf v}$ belong to ${\bf V}_h$, both semi-definite inner products coincide with the inner products previously defined for such fields.\\ The following results hold in connection to the above inner products: \begin{lemma} \label{JCAM} Let $\Delta_{\varepsilon_h}({\bf u},{\bf v}):=({\bf u},{\bf v})_{\varepsilon_h,h}-({\bf u},{\bf v})_{\varepsilon_h}$ for ${\bf u},{\bf v} \in [L^2(\Omega)]^N$ There exists a mesh independent constant $c_{\Omega}$ such that $\forall {\bf u} \in [H^1(\Omega)]^3$ and $\forall {\bf v} \in {\bf V}_h$, \begin{equation} \label{Delta} |\Delta_{\varepsilon_h}({\bf u},{\bf v})| \leq c_{\Omega} \parallel \varepsilon \parallel_{0,\infty} h \parallel \nabla{\bf u} \parallel \parallel {\bf v} \parallel_h \mbox{ \rule{2mm}{2mm}}. \end{equation} \end{lemma} \begin{lemma} \label{JCAMbis} Let $ \Gamma_{h}(\gamma\{{\bf u}\},\gamma\{{\bf v}\}):=(\gamma\{{\bf u}\},\gamma\{{\bf v}\})_{\partial \Omega,h}-(\gamma\{{\bf u}\},\gamma\{{\bf v}\})_{\partial \Omega}$ for ${\bf u},{\bf v} \in [H^1(\Omega)]^N$, where $\gamma\{w\}$ represents the trace on $\partial \Omega$ of a function $w \in H^1(\Omega)$. Let also $\nabla_{\partial \Omega}$ be the tangential gradient operator over $\partial \Omega$. There exists a mesh independent constant $\tilde{c}_{\partial \Omega}$ such that $\forall {\bf u} \in [H^{2}(\Omega)]^3$ and $\forall {\bf v} \in {\bf V}_h$, \begin{equation} \label{tildeGamma} |\Gamma_{h}(\gamma\{{\bf u}\},\gamma\{{\bf v}\}) | \leq \tilde{c}_{\partial \Omega} h \parallel \nabla_{\partial \Omega} \gamma\{{\bf u}\} \parallel_{\partial \Omega}\parallel \gamma\{{\bf v}\} \parallel_{\partial \Omega,h}. \mbox{ \rule{2mm}{2mm}}. \end{equation} \end{lemma} The proof of Lemma \ref{JCAM} is based on the Bramble-Hilbert Lemma, and we refer to \cite{JCAM2010} for more details. Lemma \ref{JCAMbis} in turn follows from the same arguments combined with the Trace Theorem, which ensures that $\nabla_{\partial \Omega} \gamma\{{\bf u}\}$ is well defined in $[L^2(\partial \Omega)]^3$ if ${\bf u} \in [H^2(\Omega)]^3$. Incidentally the Trace Theorem allows us to bound above the right hand side of \eqref{tildeGamma} in such a way that the following estimate also holds for another mesh independent constant $c_{\partial \Omega}$: \begin{equation} \label{Gamma} |\Gamma_{h}(\gamma\{{\bf u}\},\gamma\{{\bf v}\}) | \leq c_{\partial \Omega} h [\parallel \nabla {\bf u} \parallel^2 + \parallel {\mathcal H}({\bf u}) \parallel^2]^{1/2} \parallel \gamma\{{\bf v}\} \parallel_{\partial \Omega,h}. \mbox{ \rule{2mm}{2mm}}. \end{equation} To conclude we prove the validity of the following upper bounds: \begin{lemma} \label{JCAMter} $\forall {\bf v} \in [L^2(\Omega)]^3$ it holds $$\|{\bf v}\|_{\varepsilon_h,h} \leq \sqrt{5} \parallel {\bf v} \parallel_{\varepsilon_h}.$$ \end{lemma} \underline{Proof:} Denoting by $\Pi_h({\bf v})$ the function defined in $\Omega$ whose restriction to every $K \in {\mathcal T}_h$ is $\Pi_K({\bf v})$ for a given ${\bf v} \in [L^2(\Omega)]^3$, from an elementary property of the orthogonal projection we have \begin{equation} \label{intermezzo} \parallel \Pi_{h}({\bf v}) \parallel_{\varepsilon_h} \leq \parallel {\bf v} \parallel_{\varepsilon_h}, \; \forall {\bf v} \in [L^2(\Omega)]^3. \end{equation} Now taking $v$ such that $v_{|K} \in P_1(K) \; \forall K \in {\mathcal T}_h$, by a straightforward calculation using the expression of $v_{|K}$ in terms of barycentric coordinates we have: \[ \int_K \varepsilon(G_K) v_{|K}^2 d{\bf x} = \displaystyle \frac {\varepsilon(G_K) volume(K)}{10} \left\{ \displaystyle \sum_{i=1}^4 |v(S_{K,i})|^2 + \displaystyle \sum_{i=1}^3 \displaystyle \sum_{j=i+1}^4 v(S_{K,i})v(S_{K,j}) \right\}. \] It trivially follows that \[ \int_K \varepsilon(G_K) v_{|K}^2 d{\bf x} = \displaystyle \frac {\varepsilon(G_K) volume(K)}{20} \left\{ \displaystyle \sum_{i=1}^4 |v(S_{K,i})|^2 + \displaystyle \left[ \sum_{i=1}^4 v(S_{K,i}) \right]^2 \right\}. \] and finally \[ 5 \int_K \varepsilon(G_K) v_{|K}^2 d{\bf x} \geq \displaystyle \frac {\varepsilon(G_K) volume(K)}{4} \displaystyle \sum_{i=1}^4 |v(S_{K,i})|^2. \] This immediately yields Lemma \ref{JCAMter}, taking into account \eqref{intermezzo}. \rule{2mm}{2mm} \begin{lemma} \label{JCAMqua} $\forall {\bf v} \in [L^2(\partial \Omega)]^3$ it holds $\|{\bf v}\|_{\partial \Omega,h} \leq 2 \parallel {\bf v} \parallel_{\partial \Omega}$. \rule{2mm}{2mm} \end{lemma} The proof of this Lemma is based on arguments entirely analogous to Lemma \ref{JCAMter}. \subsection{Residual estimation} To begin with we define for $k=0,1,\ldots,N$ functions $\hat{\bf e}^k_h \in {\bf V}_h$ by $\hat{\bf e}^k_h(\cdot) := \hat{\bf e}_h(\cdot,k \tau)$. In the sequel for any function or field $A$ defined in $\Omega \times (0,T)$, $A^k(\cdot)$ denotes $A(\cdot,k \tau)$, except for other quantities carrying the subscript $h$ such as ${\bf e}_h^k$.\\ Let us substitute ${\bf e}^k_h$ by $\hat{\bf e}^k_h$ for $k=2,3,\ldots,N$ on the left hand side of the first equation of \eqref{eq7} and take also as initial conditions $\hat{\bf e}_h^j$ instead of ${\bf e}_h^j$, $j=0,1$.\\ The case of the initial conditions will be dealt with in the next section in the framework of the convergence analysis. As for the variational residual $E_h^k({\bf v})$ resulting from the above substitution, where $E_h^k$ being a linear functional acting on ${\bf V}_h$, it can be expressed in the following manner: \begin{equation} \label{consist7} \begin{array}{l} E_h^k({\bf v}) = ( \{\partial_{tt}{\bf e}\}^k,{\bf v})_{\varepsilon} + (\nabla {\bf e}^k,\nabla {\bf v}) + (\nabla \cdot {\bf e}^k,\nabla \cdot {\bf v})_{\varepsilon-1} + (\nabla \varepsilon \cdot {\bf e}^k,\nabla \cdot {\bf v}) + ( \{\partial_t {\bf e}\}^k, {\bf v})_{\partial \Omega} \\ \\ + \bar{\bf F}^k({\bf v}) + (\bar{d}^k,\nabla \cdot {\bf v})+ \bar{\bf G}^k({\bf v}) \; \forall {\bf v} \in {\bf V}_h, \end{array} \end{equation} \noindent where \begin{equation} \label{residual2} \begin{array}{l} \bar{d}^k = \nabla \varepsilon \cdot \{ \hat{\bf e}^k_h - {\bf e}^k \}, \end{array} \end{equation} \noindent and $\bar{\bf F}^k({\bf v})$ and $\bar{\bf G}^k({\bf v})$ can be written as follows: \begin{equation} \label{residual1} \begin{array}{l} \bar{\bf F}^k({\bf v})= {\bf F}^k_1({\bf v})+{\bf F}^k_2({\bf v})+{\bf F}^k_3({\bf v})+{\bf F}^k_4({\bf v}),\\ \mbox{with} \\ {\bf F}_1^k({\bf v})= ({\bf T}^k(\hat{\bf e}_h-{\bf e}),{\bf v})_{\varepsilon_h,h};\\ {\bf F}_2^k({\bf v})= \Delta_{\varepsilon_h} ({\bf T}^k({\bf e}),{\bf v} );\\ {\bf F}_3^k({\bf v})= ((\varepsilon_h-\varepsilon){\bf T}^k({\bf e}),{\bf v});\\ {\bf F}_4^k({\bf v})= ({\bf T}^k({\bf e}) - \{\partial_{tt}{\bf e}\}^k,{\bf v})_{\varepsilon}, \end{array} \end{equation} \noindent ${\bf T}^k$ being the finite-difference operator defined by, \begin{equation} \label{Tk} {\bf T}^k(\cdot) := \displaystyle \frac{\{\cdot\}^{k+1} - 2 \{\cdot\}^{k} +\{\cdot\}^{k-1}}{\tau^2}, \end{equation} \noindent and \begin{equation} \label{residual3} \begin{array}{l} \bar{\bf G}^k({\bf v})= {\bf G}^k_1({\bf v})+{\bf G}^k_2({\bf v})+{\bf G}^k_3({\bf v}),\\ \mbox{with} \\ {\bf G}_1^k({\bf v})= ({\bf Q}^k(\hat{\bf e}_h-{\bf e}),{\bf v})_{\partial \Omega,h};\\ {\bf G}_2^k({\bf v})= \Gamma_{h}({\bf Q}^k({\bf e}),{\bf v}) ;\\ {\bf G}_3^k({\bf v})= ({\bf Q}^k({\bf e})-\{\partial_t{\bf e}\}^k,{\bf v} )_{\partial \Omega}, \end{array} \end{equation} \noindent ${\bf Q}^k$ being the finite-difference operator defined by, \begin{equation} \label{Qk} {\bf Q}^k(\cdot) := \displaystyle \frac{\{\cdot\}^{k+1} - \{\cdot\}^{k-1}}{2 \tau}. \end{equation} Notice that, under \textit{Assumption} $^*$ both $\partial_{t} {\bf e}(\cdot,t)$ and $\partial_{tt} {\bf e}(\cdot,t)$ belong to $[H^1(\Omega)]^3$ for every $t \in [0,T]$. Hence we can define $\partial_{t} \hat{\bf e}_h$ from $\partial_{t} {\bf e}$ and $\partial_{tt} \hat{\bf e}_h$ from $\partial_{tt} {\bf e}$ in the same way as $\hat{\bf e}_h$ is defined from ${\bf e}$. Moreover straightforward calculations lead to, \begin{equation} \label{consist80} {\bf T}^k({\cdot}) = \displaystyle \frac{1}{\tau^2} \left\{ \int_{(k-1) \tau}^{k \tau} \left( \int_t^{ k \tau} \partial_{tt} \{\cdot\} \; ds \right) dt + \displaystyle \int_{ k \tau}^{(k+1) \tau} \left( \int_{k \tau}^t \partial_{tt} \{\cdot\} \; ds \right)dt \right\}. \end{equation} Furthermore another straightforward calculation allows us writing: \begin{equation} \label{consist81} \begin{array}{l} {\bf T}^k({\bf e}) = \{\partial_{tt}{\bf e}\}^k + {\bf R}^k({\bf e}) \\ \\ \mbox{where }\\ {\bf R}^k({\bf e}) := \displaystyle \frac{1}{2 \tau^2} \left[ -\int_{(k-1) \tau}^{k \tau} \{ t - (k-1)\tau \}^2 \partial_{ttt} {\bf e} dt + \int_{k \tau}^{(k+1) \tau} \{ (k+1)\tau - t \}^2 \partial_{ttt} {\bf e} dt \right]. \end{array} \end{equation} Similarly, \begin{equation} \label{consist82} {\bf Q}^k(\cdot) = \displaystyle \frac{1}{2\tau} \int_{(k-1) \tau}^{(k+1) \tau} \partial_{t} \{\cdot\} \; dt, \end{equation} and \begin{equation} \label{consist83} \begin{array}{l} {\bf Q}^k({\bf e}) = \{\partial_{t}{\bf e}\}^k + {\bf S}^k({\bf e}), \\ \mbox{where } \\ {\bf S}^k({\bf e}) = \displaystyle \frac{1}{2 \tau} \left[ - \int_{(k-1) \tau}^{k \tau} \{ t - (k-1)\tau \} \partial_{tt} {\bf e} dt + \int_{k \tau}^{(k+1) \tau} \{ (k+1)\tau - t \} \partial_{tt} {\bf e} dt \right]. \end{array} \end{equation} Now we note that the sum of the terms on the first line of the expression of $E_h^k({\bf v})$ equals zero because they are just the left hand side of \eqref{eq2} at time $t = k \tau$. Therefore the functions $\hat{\bf e}_h^k \in {\bf V}_h$ are the solution of the following problem, for $k=1,2,\ldots,N-1$: \begin{equation}\label{consist7bis} \begin{array}{l} \displaystyle \left (\varepsilon \frac{\hat{\bf e}_h^{k+1} - 2 \hat{\bf e}_h^k + \hat{\bf e}_h^{k-1}}{\tau^2}, {\bf v} \right) + (\nabla \hat{\bf e}_h^k, \nabla {\bf v}) + (\nabla \cdot \{\varepsilon \hat{\bf e}_h^k\}, \nabla \cdot {\bf v}) - (\nabla \cdot \hat{\bf e}_h^k, \nabla \cdot {\bf v}) \\ + \displaystyle \left (\frac{\hat{\bf e}_h^{k+1} - \hat{\bf e}_h^{k-1}}{2\tau}, {\bf v} \right)_{\partial \Omega}= \bar{\bf F}^k({\bf v} ) + ( \bar{d}^k, \nabla \cdot {\bf v} ) + \bar{\bf G}^k({\bf v}) ~ \forall {\bf v} \in {\bf V}_h,\\ \\ \hat{\bf e}_h^0(\cdot) = \hat{\bf e}_h(\cdot,0) \mbox{ and } \hat{\bf e}_h^1(\cdot) = \hat{\bf e}_h(\cdot,\tau) \mbox{ in } \Omega, \end{array} \end{equation} $\bar{d}^k$, $\bar{\bf F}^k$ and $\bar{\bf G}^k$ being given by \eqref{residual2}, \eqref{residual1}-\eqref{Tk} and \eqref{residual3}-\eqref{Qk}. \\ Estimating $\| \bar{d}^k \|$ is a trivial matter. Indeed, since ${\bf e}^k \in [H^2(\Omega)]^3$, from \eqref{consist0} we immediately obtain, \begin{equation} \label{Normdk} \| \bar{d}^k \| \leq \hat{C}_0 h^2 | \varepsilon |_{1,\infty} \| {\mathcal H}({\bf e}^k) \|. \end{equation} \noindent Therefore consistency of the scheme will result from suitable estimations of $| \bar{\bf F}^k |_h$ and $| \bar{\bf G}^k |_{\partial \Omega,h}$ in terms of ${\bf e}$, $\varepsilon$, $\tau$ and $h$, which we next carry out.\\ First of all we derive some upper bounds for the operators ${\bf T}^k(\cdot)$, ${\bf Q}^k(\cdot)$, ${\bf R}^k(\cdot)$ and ${\bf S}^k(\cdot)$. With this aim we denote by $| \cdot |$ the euclidean norm of $\Re^M$, for $M \geq 1$. \\ From \eqref{consist80} and the Cauchy-Schwarz inequality, we easily derive for every ${\bf x} \in \Omega$ and ${\bf u}$ such that $\{\partial_{tt}{\bf u}\}(\cdot,t) \in [H^{2}(\Omega)]^3$ $\forall t \in (0,T)$, \begin{equation*} \begin{array}{l} | {\bf T}^k_h\{{\bf u}({\bf x}) \} | \leq \displaystyle \frac{1}{\tau^2} \left\{ \int_{(k-1) \tau}^{k \tau} \left[ \int_t^{ k \tau} \left| \{\partial_{tt} {\bf u}\}({\bf x}) \right| ds \right]dt + \displaystyle \int_{ k \tau}^{(k+1) \tau} \left[ \int_{k \tau}^t \left| \{\partial_{tt} {\bf u}\}({\bf x}) \right|ds \right]dt \right\} \\ \leq \displaystyle \frac{1}{\tau^2} \left\{ \int_{(k-1) \tau}^{k \tau} \left[ \int_{(k-1)\tau}^{k \tau} \left| \{\partial_{tt} {\bf u}\}({\bf x}) \right| ds \right]dt + \displaystyle \int_{ k \tau}^{(k+1) \tau} \left[ \int_{k \tau}^{(k+1)\tau} \left| \{ \partial_{tt} {\bf u}\}({\bf x}) \right|ds \right]dt \right\} \\ = \displaystyle \frac{1}{\tau} \int_{(k-1)\tau}^{(k+1) \tau} \left| \{\partial_{tt} {\bf u}\}({\bf x}) \right| dt. \end{array} \end{equation*} It follows that, for every ${\bf u}$ such that $\{\partial_{tt}{\bf u}\}(\cdot,t) \in [H^{2}(\Omega)]^3$ $\forall t \in (0,T)$ we have, \begin{equation} \label{consist7qui} | {\bf T}^k_h\{{\bf u}({\bf x}) \} | \leq \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left| \{ \partial_{tt} {\bf u}\}({\bf x}) \right|^2 dt \right]^{1/2}. \end{equation} Furthermore, from \eqref{consist81} and the inequality $a + b \leq [2(a^2+b^2)]^{1/2} \; \forall a,b \in \Re$, for every ${\bf x} \in \Omega$ we obtain: \begin{equation*} \begin{array}{l} |{\bf R}^k\{{\bf e}({\bf x})\}| \leq \displaystyle \frac{1}{2} \left[ \int_{(k-1) \tau}^{k \tau} \displaystyle \left| \{\partial_{ttt} {\bf e}\}({\bf x}) \right| dt + \int_{k \tau}^{(k+1) \tau} \displaystyle \left| \{\partial_{ttt} {\bf e}\}({\bf x}) \right| dt \right] \\ \leq \displaystyle \frac{\sqrt{\tau}}{2} \left[ \left\{\int_{(k-1) \tau}^{k \tau} \displaystyle \left| \{\partial_{ttt} {\bf e}\}({\bf x}) \right|^2 dt \right\}^{1/2} + \left\{\int_{k \tau}^{(k+1) \tau} \displaystyle \left| \{\partial_{ttt} {\bf e}\}({\bf x}) \right|^2 dt \right\}^{1/2} \right]. \end{array} \end{equation*} It follows that, \begin{equation} \label{consist7ter} |{\bf R}^k\{{\bf e}({\bf x})\}| \leq \displaystyle \sqrt{\frac{\tau}{2}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \displaystyle \left| \{\partial_{ttt} {\bf e}\}({\bf x}) \right|^2 dt \right]^{1/2}. \end{equation} On the other hand from \eqref{consist82} and the Cauchy-Schwarz inequality we trivially have for every ${\bf x} \in \partial \Omega$ and ${\bf u}$ such that $\gamma\{\partial_{t}{\bf u}\}(\cdot,t) \in [H^{3/2}(\partial \Omega)]^3$ $\forall t \in (0,T)$: \begin{equation} \label{consist7sex} | {\bf Q}^k\{{\bf u}({\bf x})\} | \leq \displaystyle \frac{1}{\sqrt{2\tau}} \left[\int_{(k-1) \tau}^{(k+1) \tau} |\{\partial_{t} {\bf u}\}({\bf x})|^2 dt \right]^{1/2}. \end{equation} Finally, similarly to \eqref{consist7ter}, from \eqref{consist83} for every ${\bf x}$ in $\partial \Omega$ we successively derive, \begin{equation*} \begin{array}{l} |{\bf S}^k\{{\bf e}({\bf x})\}| \leq \displaystyle \frac{1}{2} \left[ \int_{(k-1) \tau}^{k \tau} \displaystyle \left| \{\partial_{tt} {\bf e}\}({\bf x}) \right| dt + \int_{k \tau}^{(k+1) \tau} \displaystyle \left| \{\partial_{tt} {\bf e}\}({\bf x}) \right| dt \right] \\ \leq \displaystyle \frac{\sqrt{\tau}}{2} \left[ \left\{\int_{(k-1) \tau}^{k \tau} \displaystyle \left| \{\partial_{tt} {\bf e}\}({\bf x}) \right|^2 dt \right\}^{1/2} + \left\{\int_{k \tau}^{(k+1) \tau} \displaystyle \left| \{\partial_{tt} {\bf e}\}({\bf x}) \right|^2 dt \right\}^{1/2} \right]. \end{array} \end{equation*} Therefore it holds, \begin{equation} \label{consist7qua} |{\bf S}^k\{{\bf e}({\bf x})\}| \leq \displaystyle \sqrt{\frac{\tau}{2}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \displaystyle \left| \{\partial_{tt} {\bf e}\}({\bf x}) \right|^2 dt \right]^{1/2}. \end{equation} Notice that bounds entirely analogous to \eqref{consist7qui} and \eqref{consist7sex} hold for $\nabla {\bf T}^k(\cdot)={\bf T}^k(\nabla \cdot)$ and $\nabla_{\partial \Omega} {\bf Q}^k(\cdot)={\bf Q}^k(\nabla_{\partial \Omega} \cdot)$, that is, $\forall {\bf x} \in \Omega$, \begin{equation} \label{consist7sep} \begin{array}{l} | \nabla {\bf T}^k_h({\bf e})({\bf x}) | \leq \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left| \{ \partial_{tt} \nabla {\bf e}\}({\bf x}) \right|^2 dt \right]^{1/2}, \end{array} \end{equation} \noindent and $\forall {\bf x} \in \partial \Omega$, \begin{equation} \label{consist7oct} | \nabla_{\partial \Omega} {\bf Q}^k({\bf e})({\bf x}) | \leq \displaystyle \frac{1}{\sqrt{2\tau}} \left [\int_{(k-1) \tau}^{(k+1) \tau} |\{\partial_{t} \nabla_{\partial \Omega} {\bf e}\}({\bf x})|^2 dt \right]^{1/2}. \end{equation} Next we estimate the four terms in the expression \eqref{residual1} of ${\bf F}^k({\bf v})$.\\ With the use of \eqref{consist7qui} and of Lemma \ref{JCAMter} followed by a trivial manipulation, we successively have: \begin{equation} \label{F10} \begin{array}{l} |{\bf F}_1^k({\bf v})| \leq \parallel \varepsilon \parallel_{0,\infty} \displaystyle \sqrt{\frac{2}{\tau}} \left\| \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left| \{ \partial_{tt} (\hat{\bf e}_h-{\bf e})\}(\cdot,t) \right|^2 dt \right]^{1/2} \right\|_{h} \parallel {\bf v} \parallel_{h}\\ \leq \sqrt{5} \parallel \varepsilon \parallel_{0,\infty} \displaystyle \sqrt{\frac{2}{\tau}} \left\| \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left| \{ \partial_{tt} (\hat{\bf e}_h-{\bf e})\}(\cdot,t) \right|^2 dt \right]^{1/2} \right\| \parallel {\bf v} \parallel_h \\ \leq \sqrt{5} \parallel \varepsilon \parallel_{0,\infty} \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left\| \{ \partial_{tt} (\hat{\bf e}_h-{\bf e})\}(\cdot,t) \right\|^2 dt \right]^{1/2} \parallel {\bf v} \parallel_h \end{array} \end{equation} Recalling \eqref{residual1} and applying \eqref{consist0bis} to \eqref{F10}, we come up with, \begin{equation} \label{F1} |{\bf F}_1^k({\bf v})| \leq \hat{C}_0 h^2 \displaystyle \sqrt{\frac{10}{\tau}} \parallel \varepsilon \parallel_{0,\infty} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \parallel \{ {\mathcal H}(\partial_{tt}{\bf e})\}(\cdot,t) \parallel^2 dt \right]^{1/2} \parallel {\bf v} \parallel_h. \end{equation} Next, combining \eqref{Delta} and \eqref{consist7sep} we immediately obtain. \begin{equation} \label{F2} |{\bf F}_2^k({\bf v})| \leq c_{\Omega} h \parallel \varepsilon \parallel_{0,\infty} \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left|\ \{ \partial_{tt} \nabla {\bf e}\}(\cdot,t) \right\|^2 dt \right]^{1/2} \parallel {\bf v} \parallel_h. \end{equation} Further, from \eqref{upperbound}, \eqref{consist80}, \eqref{consist7sep} and the standard estimate $\parallel \varepsilon_h - \varepsilon \parallel_{0,\infty} \leq C_{\infty} h | \varepsilon |_{1,\infty}$ where $C_{\infty}$ is a mesh-independent constant, we derive \begin{equation} \label{F3} |{\bf F}_3^k({\bf v})| \leq C_{\infty} h | \varepsilon |_{1,\infty} \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left\| \{ \partial_{tt} {\bf e}\}(\cdot,t) \right\|^2 dt \right]^{1/2} \parallel {\bf v} \parallel_h \end{equation} Finally by \eqref{upperbound}, \eqref{consist81} and \eqref{consist7ter}, we have \begin{equation} \label{F4} |{\bf F}_4^k({\bf v})| \leq \parallel \varepsilon \parallel_{0,\infty} \displaystyle \sqrt{\frac{\tau}{2}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \displaystyle \left\| \{\partial_{ttt} {\bf e}\}(\cdot,t) \right\|^2 dt \right]^{1/2} \parallel {\bf v} \parallel_h. \end{equation} Now we turn our attention to the three terms in the expression \eqref{residual3} of ${\bf G}^k({\bf v})$. First of all, owing to Assumption$^{*}$ and standard error estimates, we can write for a suitable mesh-independent constant $\hat{C}_1$: \begin{equation} \label{H1estimate} \parallel \{\nabla \partial_t(\hat{\bf e}_h - {\bf e})\}(\cdot,t) \parallel \leq \hat{C}_1 h \parallel \{{\mathcal H}(\partial_t{\bf e})\}(\cdot,t)) \parallel, \; \forall t \in [0,T]. \end{equation} On the other hand, by the Trace Theorem there exists a contant $C_{Tr}$ depending only on $\Omega$ such that, \begin{equation} \label{trace} \parallel \{\partial_t(\hat{\bf e}_h - {\bf e})\}(\cdot,t) \parallel_{\partial \Omega} \leq C_{Tr} [\parallel \{\partial_t (\hat{\bf e}_h - {\bf e})\}(\cdot,t) \parallel^2 + \parallel \{\nabla \partial_t (\hat{\bf e}_h - {\bf e})\}(\cdot,t) \parallel^2 ]^{1/2}\; \forall t \in [0,T]. \end{equation} Hence by \eqref{consist0bis}, \eqref{H1estimate} and \eqref{trace}, we have, for a suitable mesh-independent constant $C_B$: \begin{equation} \label{boundarestim} \parallel \{\partial_t(\hat{\bf e}_h - {\bf e})\}(\cdot,t) \parallel_{\partial \Omega} \leq C_{B} h \parallel \{{\mathcal H}(\partial_t{\bf e})\}(\cdot,t) \parallel \; \forall t \in [0,T]. \end{equation} Now recalling \eqref{residual1} and taking into account \eqref{consist7oct} and Lemma \ref{JCAMqua}, similarly to \eqref{F10} we first obtain: \begin{equation} \label{G10} | {\bf G}_1^k({\bf v}) | \leq \displaystyle \frac{2}{\sqrt{2\tau}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \left\| \{\partial_{t} (\hat{\bf e}_h-{\bf e})\}(\cdot,t) \right\|_{\partial \Omega}^2 dt \right]^{1/2} \parallel {\bf v} \parallel_{\partial \Omega,h}. \end{equation} Then using \eqref{boundarestim} we immediately establish, \begin{equation} \label{G1} | {\bf G}_1^k({\bf v}) | \leq C_B h \displaystyle \sqrt{\frac{2}{\tau}} \left [\int_{(k-1) \tau}^{(k+1) \tau} \parallel \{{\mathcal H}(\partial_t{\bf e})\}(\cdot,t) \parallel^2 dt \right]^{1/2} \parallel {\bf v} \parallel_{\partial \Omega,h}. \end{equation} Next we switch to ${\bf G}^k_2$. Using \eqref{Gamma} and \eqref{consist7oct}, similarly to \eqref{F2} we derive, \begin{equation} \label{G2} |{\bf G}_2^k({\bf v})| \leq c_{\partial \Omega} h \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left(\parallel \{\nabla \partial_t {\bf e}\}(\cdot,t) \parallel^2 + \parallel \{{\mathcal H}(\partial_t {\bf e})\}(\cdot,t) \parallel^2 \right) dt \right]^{1/2} \parallel {\bf v} \parallel_{\partial \Omega,h}. \end{equation} As for $G_3^k$, taking into account \eqref{consist83} together with \eqref{consist7qua} and \eqref{upperboundary}, we obtain: \begin{equation} \label{G30} |{\bf G}_3^k({\bf v})| \leq \displaystyle \sqrt{\frac{\tau}{2}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \displaystyle \left\| \{\partial_{tt} {\bf e}\}(\cdot,t) \right\|^2_{\partial \Omega} dt \right]^{1/2} \parallel {\bf v} \parallel_{\partial \Omega,h}. \end{equation} Then using the Trace Theorem (cf. \eqref{trace}), we finally establish, \begin{equation} \label{G3} |{\bf G}_3^k({\bf v})| \leq C_{Tr} \displaystyle \sqrt{\frac{\tau}{2}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \displaystyle \left( \parallel \{\partial_{tt} {\bf e}\}(\cdot,t) \parallel^2 + \parallel \{\nabla \partial_{tt} {\bf e}\}(\cdot,t) \parallel^2 \right) dt \right]^{1/2} \parallel {\bf v} \parallel_{\partial \Omega,h}. \end{equation} Now collecting \eqref{F1}, \eqref{F2}, \eqref{F3} and \eqref{F4} we can write, \begin{equation} \label{NormFk} \begin{array}{l} | \bar{F}^k |_h \leq \hat{C}_0 h^2 \displaystyle \sqrt{\frac{10}{\tau}} \parallel \varepsilon \parallel_{0,\infty} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \parallel \{ {\mathcal H}(\partial_{tt}{\bf e})\}(\cdot,t) \parallel^2 dt \right]^{1/2} \\ + c_{\Omega} h \parallel \varepsilon \parallel_{0,\infty} \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left|\ \{ \partial_{tt} \nabla {\bf e}\}(\cdot,t) \right\|^2 dt \right]^{1/2} \\ + C_{\infty} h | \varepsilon |_{1,\infty} \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left\| \{ \partial_{tt} \nabla {\bf e}\}(\cdot,t) \right\|^2 dt \right]^{1/2} \\ + \parallel \varepsilon \parallel_{0,\infty} \displaystyle \sqrt{\frac{\tau}{2}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \displaystyle \left\| \{\partial_{ttt} {\bf e}\}(\cdot,t) \right\|^2 dt \right]^{1/2}. \end{array} \end{equation} On the other hand \eqref{G1}, \eqref{G2} and \eqref{G3} yield, \begin{equation} \label{NormGk} \begin{array}{l} | \bar{G}^k |_{\partial \Omega,h} \leq C_B h \displaystyle \sqrt{\frac{2}{\tau}} \left [\int_{(k-1) \tau}^{(k+1) \tau} \parallel \{{\mathcal H}(\partial_t{\bf e})\}(\cdot,t) \parallel^2 dt \right]^{1/2} \\ + c_{\partial \Omega} h \displaystyle \sqrt{\frac{2}{\tau}} \left[ \int_{(k-1)\tau}^{(k+1) \tau} \left(\parallel \{\nabla \partial_t {\bf e}\}(\cdot,t) \parallel^2 + \parallel \{{\mathcal H}(\partial_t {\bf e})\}(\cdot,t) \parallel^2 \right) dt \right]^{1/2} \\ + C_{Tr} \displaystyle \sqrt{\frac{\tau}{2}} \left[ \int_{(k-1) \tau}^{(k+1) \tau} \displaystyle \left( \parallel \{\partial_{tt} {\bf e}\}(\cdot,t) \parallel^2 + \parallel \{\nabla \partial_{tt} {\bf e}\}(\cdot,t) \parallel^2 \right) dt \right]^{1/2}. \end{array} \end{equation} Then, taking into account \eqref{consist7bis} and the stability condition \eqref{CFL}, by inspection we can assert that the consistency of scheme \eqref{eq7} is an immediate consequence of \eqref{Normdk}, \eqref{NormFk} and \eqref{NormGk}. \section{Convergence results} In order to establish the convergence of scheme \eqref{eq7} we combine the stability and consistence results obtained in the previous sections. With this aim we define $\bar{\bf e}^k_h := \hat{\bf e}^k_h- {\bf e}^k_h$ for $k=0,1,2,\ldots,N$. By linearity we can assert that the variational residual on the left hand side of the first equation of \eqref{eq7} for $k=2,3,\ldots,N$, when the ${\bf e}^k_h$s are replaced with the $\bar{\bf e}^k_h$s, and ${\bf e}_h^j$ is replaced with $\bar{\bf e}_h^j$ for $j=0,1$, is exactly $E_h^k({\bf v})$, since the residual corresponding to the ${\bf e}^k_h$'s vanishes by definition. The initial conditions $\bar{\bf e}^j_h$ for $j=0$ and $j=1$ corresponding to the thus modified problem have to be estimated. This is the purpose of the next subsection. \subsection{Initial-condition deviations} Here we turn our attention to the estimate of $\bar{E}_0$, which accounts for the deviation in the initial conditions appearing in the stability inequality \eqref{stability} that applies to the modification of \eqref{eq7} when ${\bf e}^k_h$ is replaced by $\bar{\bf e}^k_h$. \\ Let us first define, \begin{equation} \label{consist8bis} \begin{array}{l} \hat{\bf e}_{1h} := (\hat{\bf e}^1_h - \hat{\bf e}^0_h)/\tau \\ \\ \bar{\bf e}_{1h} := \hat{\bf e}_{1h}-{\bf e}_{1h}, \\ \\ \bar{E}_0 := \displaystyle \left\|\bar{\bf e}_{1h} \right\|^2_{\varepsilon_h,h} + \displaystyle \frac{\tau^2}{2} \left( \|\nabla \bar{\bf e}_{1h} \|^2 + \| \nabla \cdot \bar{\bf e}_{1h} \|_{\varepsilon-1}^2 \right) \\ + \displaystyle \frac{1}{2} \left( \| \nabla \bar{\bf e}_h^1 \|^2 + \|\nabla \bar{\bf e}_h^{0} \|^2 \right) + \displaystyle \frac{1}{2} \left( \| \nabla \cdot \bar{\bf e}_h^1\|_{\varepsilon-1}^2 + \| \nabla \cdot \bar{\bf e}_h^{0} \|_{\varepsilon-1}^2 \right) + T | \varepsilon |_{2,\infty} \| \bar{\bf e}_h^0\|^2 \end{array} \end{equation} Recalling that ${\bf e}^1_h = {\bf e}^0_h + \tau {\bf e}_{1h}$ we have $\bar{\bf e}^1_h = \bar{\bf e}^0_h + \tau \bar{\bf e}_{1h}$. Thus, taking either ${\mathcal A}=\nabla \bar{\bf e}_h^0$ or ${\mathcal A}=\nabla \cdot \bar{\bf e}_h^0$ and either ${\mathcal B} = \tau \nabla \bar{\bf e}_{1h}$ or ${\mathcal B} = \tau \nabla \cdot \bar{\bf e}_{1h}$, we apply twice the inequality $\|{\mathcal A}+{\mathcal B}\|^2/2 \leq \| {\mathcal A} \|^2 + \|{\mathcal B}\|^2$ to \eqref{consist8bis} together with Lemma \ref{JCAMter}, to obtain, \begin{equation} \label{consist8ter} \begin{array}{l} \bar{E}_0 \leq \displaystyle \frac{3}{2} \left\{\|\nabla \bar{\bf e}_{h}^0 \|^2 + \| \nabla \cdot \bar{\bf e}_h^0\|_{\varepsilon-1}^2 + \tau^2 \left(\| \nabla \bar{\bf e}_{1h} \|^2 + \| \nabla \bar{\bf e}_{1h}\|^2_{\varepsilon-1} \right) \right\} \\ + T | \varepsilon |_{2,\infty} \| \bar{\bf e}_h^0 \|^2 + 5 \| \varepsilon \|_{0,\infty} \| \bar{\bf e}_{1h} \|^2. \end{array} \end{equation} Finally using the inequality $\| \nabla \cdot {\bf v} \|^2_{\varepsilon -1} \leq 3 \| \varepsilon - 1 \|_{0,\infty} \| \nabla {\bf v} \|^2$ $\forall {\bf v} \in [H^1(\Omega)]^3$, after straightforward manipulations we easily derive from \eqref{consist8ter}: \begin{equation} \label{consist9bis} \begin{array}{l} \bar{E}_0 \leq \displaystyle \frac{3(1+ 3 \| \varepsilon - 1 \|_{0,\infty})}{2} \left( \|\nabla \bar{\bf e}_{h}^0 \|^2 + \tau^2 \| \nabla \bar{\bf e}_{1h} \|^2 \right) + T | \varepsilon |_{2,\infty} \| \bar{\bf e}_h^0 \|^2 + 5 \| \varepsilon \|_{0,\infty} \| \bar{\bf e}_{1h} \|^2. \end{array} \end{equation} We next use the obvious splitting $\bar{\bf e}_{h}^0 = (\hat{\bf e}_{h}^0 -{\bf e}_0) + ({\bf e}_0 -{\bf e}_{h}^0 )$, together with the trivial one, \begin{equation} \label{consist10} \bar{\bf e}_{1h} = \displaystyle \frac{\hat{\bf e}_{h}^1 - \hat{\bf e}_{h}^0}{\tau} - {\bf e}_{1h} = (\{\partial_t \hat{\bf e}_{h}\}_{|t=0} - {\bf e}_1 ) + \displaystyle \frac{1}{\tau} \int_0^{\tau} (\tau-t)\partial_{tt} \hat{\bf e}_h \; dt + ({\bf e}_1 - {\bf e}_{1h}). \end{equation} Then plugging \eqref{consist10} into \eqref{consist9bis}, since $\left[ \sum_{i=1}^p \| A_i \| \right]^2 \leq p \sum_{i=1}^p \| A_i \|^2$ for any set of $p$ functions or fields $A_i$, we obtain: \begin{equation} \label{consist11} \begin{array}{l} \bar{E}_0 \leq \displaystyle \frac{3(1+ 3 \| \varepsilon - 1 \|_{0,\infty})}{2} \left[ 2 \left\{ \| \nabla (\hat{\bf e}_{h}^0 - {\bf e}_{0}) \|^2 + \| \nabla ({\bf e}_{0} - {\bf e}_{h}^0 ) \|^2 \right\} \right. \\ \left. 3 \tau^2 \displaystyle \left\{ \| \nabla \partial_t(\hat{\bf e}_h - {\bf e})(\cdot,0) \|^2 + \displaystyle \frac{1}{\tau^2} \left \|\int_0^{\tau} (\tau-t)\partial_{tt} \nabla \hat{\bf e}_h \; dt \right\|^2 + \| \nabla ({\bf e}_1 - {\bf e}_{1h}) \|^2 \right\} \right] \\ + 2 T | \varepsilon \textit{}|_{2,\infty} \left( \| \hat{\bf e}_h^0 - {\bf e}_0 \|^2 + \| {\bf e}_0 - {\bf e}_h^0 \|^2 \right) \\ + 15 \| \varepsilon \|_{0,\infty} \displaystyle \left\{ \| \partial_t (\hat{\bf e}_h - {\bf e})(\cdot,0) \|^2 + \displaystyle \frac{1}{\tau^2} \left \|\int_0^{\tau} (\tau-t)\partial_{tt} \hat{\bf e}_h \; dt \right\|^2 + \| {\bf e}_1 - {\bf e}_{1h} \|^2 \right\}. \end{array} \end{equation} Owing to a trivial upper bound and to the Cauchy-Schwarz inequality we easily derive \begin{equation*} \begin{array}{l} \displaystyle \frac{1}{\tau^2} \left\| \int_0^{\tau} (\tau-t) \nabla \partial_{tt} \hat{\bf e}_h \; dt \right\|^2 \leq \left\| \int_0^{\tau} |\nabla \partial_{tt} \hat{\bf e}_h | dt \right\|^2 \leq \tau \left\| \displaystyle \left[ \int_0^{\tau} | \nabla \partial_{tt} \hat{\bf e}_h |^2 dt \right]^{1/2} \right\|^2. \end{array} \end{equation*} It follows that, \begin{equation} \label{consist12} \displaystyle \frac{1}{\tau^2} \left\| \int_0^{\tau} (\tau-t) \nabla \partial_{tt} \hat{\bf e}_h \; dt \right\|^2 \leq \tau \int_0^{\tau} \left\| \nabla \partial_{tt} \hat{\bf e}_h \right\|^2 dt \leq (1+3 \| \varepsilon -1 \|_{0,\infty} ) \tau \int_0^{\tau} \left\| \nabla \partial_{tt} {\bf e} \right\|^2 dt. \end{equation} The last inequality in \eqref{consist12} follows from the definition of $\hat{\bf e}_h$. Indeed we know that, \begin{equation} \label{consist13} (\nabla \partial_{tt} \hat{\bf e}_h,\nabla {\bf v}) + (\nabla \cdot \partial_{tt} \hat{\bf e}_h,\nabla \cdot {\bf v})_{\varepsilon-1} = (\nabla \partial_{tt} {\bf e},\nabla {\bf v}) + (\nabla \cdot \partial_{tt} {\bf e},\nabla \cdot {\bf v})_{\varepsilon-1} \; \forall {\bf v} \in {\bf V}_h. \end{equation} Taking ${\bf v} = \hat{\bf e}_h$, by the Cauchy-Schwarz inequality, we easily obtain: \begin{equation} \label{consist14} [ \| \nabla \partial_{tt} \hat{\bf e}_h \|^2 + \| \nabla \cdot \partial_{tt} \hat{\bf e}_h \|_{\varepsilon-1}^2 ]^{1/2} \leq [ \| \nabla \partial_{tt} {\bf e} \|^2 + \| \nabla \cdot \partial_{tt} {\bf e} \|_{\varepsilon-1}^2 ]^{1/2}, \end{equation} or yet \begin{equation} \label{consist15} \| \nabla \partial_{tt} \hat{\bf e}_h \| \leq \sqrt{1 + 3 \| \varepsilon -1 \|_{0,\infty}} \| \nabla \partial_{tt} {\bf e} \|, \end{equation} which validates \eqref{consist12}.\\ On the other hand according to \eqref{consist0bis} we have $\| \partial_{tt} \hat{\bf e}_h \| \leq \| \partial_{tt}{\bf e} \| + \hat{C}_0 h^2 \| {\mathcal H}(\partial_{tt}{\bf e}) \|$. This yields, \begin{equation} \label{consist12bis} \left\| \int_0^{\tau} (\tau-t) \partial_{tt} \hat{\bf e}_h \; dt \right\|^2 \leq \tau \int_0^{\tau} \left\| \partial_{tt} \hat{\bf e}_h \right\|^2 dt \leq 2 \tau \left[\int_0^{\tau} \left\| \partial_{tt} {\bf e} \right\|^2 dt + \hat{C}_0^2 h^4 \int_0^{\tau} \left\| {\mathcal H}(\partial_{tt} {\bf e}) \right\|^2 dt \right]. \end{equation} Incidentally we point out that \textit{Assumption} $^*$ and \eqref{Sobolemb} allow us to assert that \begin{itemize} \item $\partial_{tt} \nabla {\bf e} \in [L^2\{\Omega \times (0,T)\}]^3$; \item $\| \partial_{tt} {\bf e} \| \in [ L^{\infty}(0,T)]^3$; \item $\{\partial_t {\bf e}\}_{|t=0} = {\bf e}_1 \in [H^2(\Omega)]^3$; \item $\{{\bf e}\}_{|t=0} = {\bf e}_0 \in [H^2(\Omega)]^3$. \end{itemize} Clearly enough, besides \eqref{consist0} and \eqref{consist1bis}, we will apply to \eqref{consist11} standard estimates based on the interpolation error in Sobolev norms (cf. \cite{Ciarlet}), together with the following obvious variants of \eqref{consist1bis} and \eqref{consist0bis}, namely, \begin{equation} \label{consist0ter} \begin{array}{l} \left\| \nabla \partial_{t} (\hat{\bf e}_h - {\bf e})(\cdot,0) \right\| \leq \hat{C}_1 h \left\| {\mathcal H}({\bf e}_1) \right\|, \\ \left\| \partial_{t} (\hat{\bf e}_h - {\bf e})(\cdot,0) \right\| \leq \hat{C}_0 h^2 \left\| {\mathcal H}({\bf e}_1) \right\|. \end{array} \end{equation} Then taking into account that $\tau \leq 1/(2 \eta)$, from \eqref{consist11}-\eqref{consist12}-\eqref{consist12bis}-\eqref{consist0ter} and Assumption$^*$, we conclude that there exists a constant $\bar{C}_0$ depending on $\Omega$, $T$ and $\varepsilon$, but neither on $h$ nor on $\tau$, such that, \begin{equation} \label{E00} \begin{array}{l} \bar{E}_0 \leq \bar{C}_0^2 \displaystyle \left[(h^2 + \tau h^2 + h^4)\| {\mathcal H}({\bf e}_0) \|^2 + (h^2 + \tau^2 h^2)\| {\mathcal H}({\bf e}_1) \|^2 + \tau^3 \| \| \nabla \partial_{tt} {\bf e} \| \|_{L^2(0,T)}^2 \right. \\ \left. + \tau^2 \| \| \partial_{tt} {\bf e} \| \|_{L^{\infty}(0,T)}^2 + \tau h^4 \int_0^{\tau} \left\| {\mathcal H}(\partial_{tt} {\bf e}) \right\|^2 dt \right]. \end{array} \end{equation} Notice that, starting from \eqref{Sobolemb} with $u = \| \nabla \partial_{tt} {\bf e} \|$, similarly to \eqref{hessianbound}, we obtain \[ \| \| \partial_{tt}{\bf e} \| \|_{L^{\infty}(0,T)} \leq C_T [ \| \| \partial_{tt}{\bf e} \| \|_{L^2(0,T)}^2 + \| \| \partial_{ttt}{\bf e}) \| \|_{L^2(0,T)}^2 ]^{1/2}. \] Thus noting that $h \leq diam(\Omega)$, using again the upper bound $\tau \leq 1/(2 \eta)$ and extending the integral to the whole interval $(0,T)$ in \eqref{E00}, from the latter inequality we infer the existence of another constant $C_0$ independent of $h$ and $\tau$, such that, \begin{equation} \label{E0} \begin{array}{l} \bar{E}_0 \leq C_0^2 \displaystyle \left[h^2 \{\| {\mathcal H}({\bf e}_0) \|^2 + \| {\mathcal H}({\bf e}_1) \|^2 + \| {\mathcal H}(\partial_{tt} {\bf e}) \|^2_{L^2[\Omega \times (0,T)]} \} \right. \\ \left. + \tau^2 \{ \| \partial_{tt} {\bf e} \|^2_{L^2[\Omega \times (0,T)]} + \| \partial_{ttt} {\bf e} \|^2_{L^2[\Omega \times (0,T)]} + \| \nabla \partial_{tt} {\bf e} \|^2_{L^2[\Omega \times (0,T)]} \} \right]. \end{array} \end{equation} \subsection{Error estimates} In order to fully exploit the stability inequality \eqref{stability} we further define, \begin{equation} \label{BarSN} \bar{S}_N := \displaystyle \sum_{k=1}^{N-1} \left( \displaystyle \frac{\tau}{2} | \bar{\bf F}^k |_h^2 + \displaystyle \frac{3}{2 \tau} \| \bar{d}^k\|^2 + \displaystyle \frac{\tau}{2} \left| \bar{\bf G}^k \right|^2_{\partial \Omega,h} \right). \end{equation} According to \eqref{consist7bis}, in order to estimate $\bar{S}_N$ under the regularity Assumption$^*$ on ${\bf e}$, we resort to the estimates \eqref{Normdk}, \eqref{NormFk} and \eqref{NormGk}. Using the inequality $|{\bf a} \cdot {\bf b}| \leq |{\bf a}| |{\bf b}|$ for ${\bf a},{\bf b} \in \Re^M$, it is easy to see that there exists two constants $\bar{C}_F$ and $\bar{C}_G$ independent of $h$ and $\tau$ such that \begin{equation} \label{BarFk} \displaystyle \sum_{k=1}^{N-1} \displaystyle \frac{\tau}{2} | \bar{\bf F}^k |_h^2 \leq \bar{C}_F \displaystyle \left( h^2 + \tau^2 \right) | {\bf e} |_{H^4[\Omega \times (0,T)]}^2, \end{equation} \begin{equation} \label{BarGk} \displaystyle \sum_{k=1}^{N-1} \displaystyle \frac{\tau}{2} | \bar{\bf G}^k |_{\partial \Omega,h}^2 \leq \bar{C}_G \displaystyle \left( h^2 + \tau^2 \right) | {\bf e} |_{H^3[\Omega \times (0,T)]}^2. \end{equation} On the other hand, recalling \eqref{hessianbound} we have $k=1,2,\ldots,N-1$: \begin{equation} \label{Hek} \| {\mathcal H}({\bf e}^k) \|^2 \leq C_T^2 \displaystyle \int_0^T \left[ \| {\mathcal H}({\bf e}) \|^2 + \| {\mathcal H}(\partial_t{\bf e}) \|^2 \right] dt. \end{equation} Therefore, since $N = T/\tau$ we have: \begin{equation} \label{SHek} \displaystyle \sum_{k=1}^{N-1} \| {\mathcal H}({\bf e}^k) \|^2 \leq \displaystyle \frac{C_T^2 T}{\tau} \displaystyle \int_0^T \left[ \| {\mathcal H}({\bf e}) \|^2 + \| {\mathcal H}(\partial_t{\bf e}) \|^2 \right] dt \end{equation} It follows from \eqref{SHek} and \eqref{Normdk} that, \begin{equation} \label{Bardk} \displaystyle \sum_{k=1}^{N-1} \displaystyle \frac{3}{2\tau} \| \bar{\bf d}^k \|^2 \leq \hat{C}_0^2 C_T ^2 T | \varepsilon |_{1,\infty}^2 \displaystyle \frac{3h^4}{2\tau^2} \left( | {\bf e} |_{H^2[\Omega \times (0,T)]}^2 + | {\bf e} |_{H^3[\Omega \times (0,T)]}^2 \right) \end{equation} Plugging \eqref{BarFk}, \eqref{Bardk} and \eqref{BarGk} into \eqref{BarSN} we can assert that there exists a constant $\tilde{C}$ depending on $\Omega$, $T$ and $\varepsilon$, but neither on $h$ nor on $\tau$, such that, \begin{equation} \label{SN} \begin{array}{l} \bar{S}_N \leq \tilde{C}^2 \displaystyle \left( h^2 + \tau^2 + \frac{h^4}{\tau^2} \right) \| {\bf e} \|_{H^4[\Omega \times (0,T)]}^2 \end{array} \end{equation} \noindent Now recalling \eqref{stability}-\eqref{eq26}, provided \eqref{CFL} holds, together with $\tau \leq 1/(2 \eta)$, we have: \begin{equation} \label{convergence0} \displaystyle \left[ \left\| \frac{\bar{\bf e}_h^{m+1} - \bar{\bf e}_h^m}{\tau} \right\|^2 + \| \nabla \bar{\bf e}_h^{m+1}\|^2 + \| \nabla \bar{\bf e}_h^{m}\|^2 \right]^{1/2} \leq 2 \sqrt{\bar{S}_N + \bar{E}_0} e^{\beta/2}. \end{equation} This implies that, for $m=1,2,\ldots,N-1$, it holds: \begin{equation} \label{convergence1} \begin{array}{l} \displaystyle \left[ \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} - \frac{{\bf e}^{m+1} - {\bf e}^{m}}{\tau} \right\|^2 + \| \nabla \left({\bf e}_h^{m+1}-{\bf e}^{m+1} \right) \|^2 + \| \nabla \left({\bf e}_h^{m} - {\bf e}^m) \right) \|^2 \right]^{1/2} \\ \leq \displaystyle \left[ \left\| \frac{\hat{\bf e}_h^{m+1} - {\bf e}^{m+1}}{\tau} - \frac{\hat{\bf e}_h^{m} - {\bf e}^{m}}{\tau} \right\|^2 + \| \nabla \left(\hat{\bf e}_h^{m+1}-{\bf e}^{m+1} \right) \|^2 + \| \nabla \left(\hat{\bf e}_h^{m} - {\bf e}^m \right) \|^2 \right]^{1/2} \\ +\; 2 \sqrt{\bar{S}_N + \bar{E}_0} e^{\beta/2}. \end{array} \end{equation} Let us define a function ${\bf e}_h$ in $\bar{\Omega} \times [0,T]$ whose value at $t=k\tau$ equals ${\bf e}_h^k$ for $k=1,2,\ldots,N$ and that varies linearly with $t$ in each time interval $([k-1] \tau,k \tau)$, in such a way that $\partial_t{\bf e}_{h}({\bf x},t)=\displaystyle \frac{{\bf e}^k_h({\bf x}) - {\bf e}^{k-1}_h({\bf x})}{\tau}$ for every ${\bf x} \in \bar{\Omega}$ and $t \in ([k-1]\tau,k \tau)$. \\ Now we define $\tilde{A}^{m-1/2}(\cdot)$ for any function or field $A(\cdot,t)$ to be the mean value of $A(\cdot,t)$ in $(m \tau, [m+1]\tau$, that is $\tilde{A}^{m+1/2} = \tau^{-1} \int_{m \tau}^{(m+1)\tau} A(\cdot,t) dt$. Clearly enough we have \begin{equation} \label{convergence2} \displaystyle \left\| \frac{{\bf e}_h^{m+1} - {\bf e}_h^{m}}{\tau} - \frac{{\bf e}^{m+1} - {\bf e}^{m}}{\tau} \right\|^2 = \displaystyle \left\| \{\widetilde{\partial_t {\bf e}_h}\}^{m+1/2} - \{\widetilde{\partial_t {\bf e}}\}^{m+1/2} \right\|^2. \end{equation} and also recalling \eqref{SHek} and \eqref{hessianbound} \begin{equation*} \begin{array}{l} \displaystyle \left\| \frac{\hat{\bf e}_h^{m+1} - {\bf e}^{m+1}}{\tau} - \frac{\hat{\bf e}_h^{m} - {\bf e}^{m}}{\tau} \right\|^2 = \displaystyle \left\| \displaystyle \int_{m \tau}^{(m+1)\tau} \frac{\partial_t \hat{\bf e}_h - \partial_t {\bf e}}{\tau} dt \right\|^2 \\ \leq \left\| \displaystyle \frac{ \left[\int_{m \tau}^{(m+1)\tau} (\partial_t \hat{\bf e}_h - \partial_t {\bf e})^2 dt \right]^{1/2}}{\sqrt{\tau}} \right\|^2 = \displaystyle \frac{1}{\tau} \int_{m \tau}^{(m+1)\tau} \left\| \partial_t \hat{\bf e}_h - \partial_t {\bf e} \right\|^2 dt \\ \leq \displaystyle \frac{\hat{C}_0^2 h^4}{\tau} \int_{m \tau}^{(m+1)\tau} \| {\mathcal H}(\partial_t {\bf e}) \|^2 dt \leq C_T^2 \hat{C}_0^2 h^4 \int_0^T [\| {\mathcal H}(\partial_t {\bf e}) \|^2 + \| {\mathcal H}(\partial_{tt} {\bf e}) \|^2 ] dt, \end{array} \end{equation*} which implies that \begin{equation} \label{convergence3} \begin{array}{l} \displaystyle \left\| \frac{\hat{\bf e}_h^{m+1} - {\bf e}^{m+1}}{\tau} - \frac{\hat{\bf e}_h^{m} - {\bf e}^{m}}{\tau} \right\|^2 \leq C_T^2 \hat{C}_0^2 h^2 |diam(\Omega)|^2 \| {\bf e} \|_{H^4[ \Omega \times (0,T)]}^2. \end{array} \end{equation} On the other hand from \eqref{consist1bis} and \eqref{hessianbound} we have for $j=m$ or $j=m+1$: \begin{equation*} \| \nabla (\hat{\bf e}_h^{j}-{\bf e}^{j} ) \|^2 \leq \hat{C}_1^2 h^2 \| {\mathcal H}({\bf e}^j) \|^2 \leq \hat{C}_1^2 C_T^2 h^2 \displaystyle \int_0^T \left[ \| {\mathcal H}({\bf e}) \|^2 + \| {\mathcal H}(\partial_t {\bf e}) \|^2 \right] dt. \end{equation*} which yields, \begin{equation} \label{convergence4} \| \nabla (\hat{\bf e}_h^{j}-{\bf e}^{j}) \|^2 \leq C_T^2 \hat{C}_1^2 h^2 \| {\bf e} \|_{H^3[ \Omega \times (0,T)]}^2. \end{equation} Now using Taylor expansions about $t=(m+1/2)\tau$ together with some arguments already exploited in this work, it is easy to establish that for a certain constant $\tilde{\mathcal C}$ independent of $h$ and $\tau$ it holds, \begin{equation} \label{brokenpartialt} \left\| \{ \widetilde{\partial_t {\bf e}}\}^{m+1/2} - [\partial_t {\bf e}]^{m+1/2} \right\| \leq \tilde{\mathcal C} \tau^2 \left\| {\bf e} \right\|_{H^4[\Omega \times (0,T)]}, \end{equation} where for every function $g$ defined in $\bar{\Omega} \times [0,T]$ and $s \in \Re^{+}$, $g^s$ is the function defined in $\Omega$ by $g^s(\cdot) = g(\cdot,s \tau)$.\\ Noticing that $\{\widetilde{\partial_t {\bf e}_h}\}^{m+1/2}(\cdot)$ is nothing but $[\partial_t {\bf e}_h]^{m+1/2}(\cdot)$, collecting \eqref{convergence1}, \eqref{convergence2}, \eqref{convergence3}, \eqref{convergence4}, \eqref{brokenpartialt}, together with \eqref{E0} and \eqref{SN}, we have thus proved the following convergence result for scheme \eqref{eq7}:\\ \textbf{Provided the CFL condition \eqref{CFL} is satisfied and $\tau$ also satisfies $\tau \leq 1/[2\eta]$, under Assumption $^*$ on ${\bf e}$, there exists a constant ${\mathcal C}$ depending only on $\Omega$, $\varepsilon$ and $T$ such that} \begin{equation} \label{convergence} \boxed{ \begin{array}{l} \displaystyle \max_{1 \leq m \leq N-1} \left\| [\partial_t ({\bf e}_h - {\bf e})]^{m+1/2} \right\| + \displaystyle \max_{2 \leq m \leq N} \| \nabla ({\bf e}_h^{m} - {\bf e}^{m}) \| \\ \leq {\mathcal C} (\tau + h + h^2/\tau) \displaystyle \left\{ \| {\bf e} \|_{H^4[\Omega \times (0,T)]} + \| {\mathcal H}({\bf e}_0) \| + \| {\mathcal H}({\bf e}_1) \| \right\}. \mbox{ \rule{2mm}{2mm}} \end{array} } \end{equation} \textbf{In short, as long as $\tau$ varies linearly with $h$, first order convergence of scheme \eqref{eq7} in terms of either $\tau$ or $h$ is thus established in the sense of the norms on the left hand side of \eqref{convergence}}. \section{Assessment of the scheme} We performed numerical tests for the model problem \eqref{eq1}, taking $T=0.5$ and $\Omega$ to be the unit disk given by $\Omega= \{(x_1;x_2) |\; r < 1\}$, where $r:= \sqrt{x_1^2+x_2^2}$. We consider that the exact solution ${\bf e}$ of \eqref{eq1} is given by: \begin{center} ${\bf e}=(e_1,e_2)$ with $e_1=-x_2 v_{\theta}(r,t)$ and $e_2 = x_1 v_{\theta}(r,t)$,\\ \vspace{2mm} where $\displaystyle v_{\theta}(r,t) = \frac{e^{r-2t}}{\varepsilon(r)}$ \\ \end{center} with \begin{equation} \label{eps} \varepsilon(r) = 1+(1-4r^2)^m(1-H_{1/2}(r)), \mbox{for an integer } m > 1, \end{equation} $H_{1/2}$ being the Heaviside function.\\ The initial data ${\bf e}_0$ and ${\bf e}_1$ are given by \begin{align*} {\bf e}_0 &:= {\bf e}_{|t=0} = \displaystyle \frac{(-x_2,x_1)e^r}{\varepsilon(r)}, \\ {\bf e}_1 &:= [\partial_t{\bf e}]_{|t=0} = \displaystyle \frac{2 (x_2,-x_1) e^r}{\varepsilon(r)}. \end{align*} The right hand side ${\bf f}$ in turn is given by, \begin{align*} f_{1} &:= \varepsilon \partial_{tt} e_1 - \Delta e_1 + \partial_{x_1} (\nabla \cdot {\bf e}) = -4 x_2 e^{r-2t} - \Delta e_1, \\ f_{2} &:= \varepsilon \partial_{tt} e_2 - \Delta e_2 + \partial_{x_2} (\nabla \cdot {\bf e}) = 4 x_1 e^{r-2t} - \Delta e_2, \end{align*} with \begin{align*} \Delta e_1 &= - \displaystyle \frac{3x_2}{r} v_{\theta}^{'} - x_2 v_{\theta}^{''}, \\ \Delta e_2 &= \displaystyle \frac{3x_1}{r} v_{\theta}^{'} + x_1 v_{\theta}^{''}, \\ v_{\theta}^{'} &= \displaystyle \frac{\varepsilon - \varepsilon^{'}}{\varepsilon^2} e^{r-2t}, \\ v_{\theta}^{''} &= \displaystyle \frac{\varepsilon^2-2\varepsilon \varepsilon^{'}-\varepsilon \varepsilon^{''} + 2 (\varepsilon^{'})^2}{\varepsilon^3} e^{r-2t}, \\ \varepsilon^{'} &= -8mr(1-4r^2)^{m-1}(1-H_{1/2}(r)), \\ \varepsilon^{''} &= 8m(8m^2r^2-4r^2-1)(1-4r^2)^{m-2}(1-H_{1/2}(r)). \\ \end{align*} Notice that ${\bf e}$ satisfies absorbing conditions on the boundary of the unit disk. Indeed, \begin{align*} \partial_r e_1 = \displaystyle \frac{x_1}{r} \partial_{x_1} e_1 + \displaystyle \frac{x_2}{r} \partial_{x_2} e_1 = -\displaystyle \frac{x_2}{r} v_{\theta} - x_2 v_{\theta}^{'} \end{align*} and \begin{align*} \partial_r e_2 = \displaystyle \frac{x_{1}}{r} \partial_{x_1} e_2 + \displaystyle \frac{x_2}{r} \partial_{x_2} e_2 = \displaystyle \frac{x_1}{r} v_{\theta} + x_1 v_{\theta}^{'}. \end{align*} Therefore, at $r=1$ we have \begin{align*} \partial_n {\bf e} = \partial_r {\bf e}=(-x_2,x_1) (v_{\theta}(1)+v_{\theta}^{'}(1))=2(-x_2,x_1)e^{1-2t}. \end{align*} Since ${\bf e} = (-x_2,x_1) e^{r-2t}$ for $r > 1/2$, it follows that $\partial_n {\bf e} + \partial_t {\bf e} = {\bf 0}$ for $r=1$.\\ In our computations we used the software package Waves \cite{waves} only for the finite element method applied to the solution of the model problem \eqref{eq1}. We note that this package was also used in \cite{cejm} to solve the the same model problem \eqref{eq1} by a domain decomposition FEM/FDM method.\\ We discretized the spatial domain $\Omega$ using a family of quasi-uniform meshes consisting of $2 \times 2^{2l+2}$ triangles $K$ for $l=1,...,6$, constructed as a certain mapping of the same number of triangles of the uniform mesh of the square $(-1,1)\times (-1,1)$, which is symmetric with respect to the cartesian axes and have their edges parallel to those axes and either to the line $x_1=x_2$ if $x_1x_2 \geq 0$ or to the line $x_1=-x_2$ otherwise. The above mapping is defined by means of a suitable transformation of cartesian into polar coordinates. For each value of $l$ we define a reference mesh size $h_l$ equal to $2^{-l}$.\\ We consider a partition of the time domain $(0,T)$ into time intervals $J=(t_{k-1},t_k]$ of equal length $\tau_l$ for a given number of time intervals $N, l=1,...,6$. We performed numerical tests taking $m=2,3,4,5$ in \eqref{eps}. We choose the time step $\tau_l = 0.025 \times 2^{-l}, \; l=1,...,6$, which provides numerical stability for all meshes. We computed the maximum value over the time steps of the relative errors measured in the $L_2$-norms of the function, its gradient and its time-derivative in the polygons $\Omega_h$ defined to be the union of the triangles in the different meshes in use. Now ${\bf e}$ being the exact solution of \eqref{eq1}, ${\bf e}_h$ being the computed solution and setting $N := T /\tau_l$, these quantities are represented by, \begin{equation}\label{norms} \begin{split} e_l^1 &= \displaystyle \frac{\displaystyle \max_{1 \leq k \leq N} \| {\bf e}^k-{\bf e}_h^k \|_h}{\displaystyle \max_{1 \leq k \leq N}\| {\bf e}^k \|_h},\\ e_l^2 &= \displaystyle \frac{ \displaystyle \max_{1 \leq k \leq N} \| \nabla ({\bf e}^k - {\bf e}^k_h) \|_h}{ \displaystyle \max_{1 \leq k \leq N} \| \nabla {\bf e}^k \|_h}, \\ e_l^3 &= \displaystyle \frac{\displaystyle \max_{1 \leq k \leq N-1} \| \{ \partial_t ({\bf e}-{\bf e}_h)\}^{k+1/2} \|_h}{\displaystyle \max_{1 \leq k \leq N-1} \| \{ \partial_t {\bf e}\}^{k+1/2}\|_h}, \end{split} \end{equation} respectively, where $\| \cdot \|_h$ stands for the standard norm of $[L^2(\Omega_h)]^2$. Notice that, in the case of $P_1$ elements and of convex domains, the error estimates in mean-square norms that hold for a polygonal domain extend to a curved domain, as long as the norm $\| \cdot \|$ is replaced by $\| \cdot \|_h$. \\ In Tables 1-4 method's convergence in these three senses is observed taking $m=2,3,4,5$ in \eqref{eps}. \begin{table} \center \begin{tabular}{ l l l l l l l l l } \hline $l$ & $nel$ & $nno$ & $e_l^{(1)}$ & $e_{l-1}^{(1)}/e_{l}^{(1)}$ & $e_l^{(2)}$ & $e_{l-1}^{(2)}/e_{l}^{(2)}$ & $e_l^{(3)}$ & $e_{l-1}^{(3)}/e_{l}^{(3)}$\\ \hline 1 & 32 & 25 & 0.6057 & & 2.2827 & & 3.1375 & \\ 2 & 128 & 81 & 0.1499 & 4.0418 & 1.0769 & 2.1198 & 1.1536 & 2.7196 \\ 3 & 512 & 289 & 0.0333 & 4.5007 & 0.4454 & 2.4178 & 0.5776 & 1.9972 \\ 4 & 2048 & 1089 & 0.0078 & 4.2466 & 0.2077 & 2.1449 & 0.2802 & 2.0617 \\ 5 & 8192 & 4225 & 0.0019 & 4.1288 & 0.1066 & 1.9483 & 0.1379 & 2.0313 \\ 6 & 32768 & 16641 & 0.0005 & 4.0653 & 0.0535 & 1.9905 & 0.0690 & 1.9981 \\ \hline \end{tabular} \caption{ The computed maximum relative errors $e_n$ in maximum energy, maximum $L_2$ and maximum in broken time error on different meshes with mesh sizes $h_l= 2^{-l}, l=1,...,6$ for the function $\varepsilon$ with $m=2$ in \eqref{eps}.} \label{test1} \end{table} \begin{table} \center \begin{tabular}{ l l l l l l l l l } \hline $l$ & $nel$ & $nno$ & $e_l^{(1)}$ & $e_{l-1}^{(1)}/e_{l}^{(1)}$ & $e_l^{(2)}$ & $e_{l-1}^{(2)}/e_{l}^{(2)}$ & $e_l^{(3)}$ & $e_{l-1}^{(3)}/e_{l}^{(3)}$\\ \hline 1 & 32 & 25 & 0.6144 & & 1.8851 & & 3.0462 & \\ 2 & 128 & 81 & 0.1511 & 4.0666 & 1.0794 & 1.7464 & 1.1417 & 2.6682 \\ 3 & 512 & 289 & 0.0339 & 4.4553 & 0.4713 & 2.2904 & 0.5680 & 2.0099 \\ 4 & 2048 & 1089 & 0.0080 & 4.2216 & 0.2166 & 2.1753 & 0.2760 & 2.0583 \\ 5 & 8192 & 4225 & 0.0019 & 4.1207 & 0.1137 & 1.9049 & 0.1354 & 2.0381 \\ 6 & 32768 & 16641 & 0.0005 & 4.0615 & 0.0566 & 2.0092 & 0.0677 & 1.9997 \\ \hline \end{tabular} \caption{ The computed maximum relative errors $e_n$ in maximum energy, maximum $L_2$ and maximum in broken time error on different meshes with mesh sizes $h_l= 2^{-l}, l=1,...,6$ for the function $\varepsilon$ with $m=3$ in \eqref{eps}.} \label{test2} \end{table} \begin{table} \center \begin{tabular}{ l l l l l l l l l } \hline $l$ & $nel$ & $nno$ & $e_l^{(1)}$ & $e_{l-1}^{(1)}/e_{l}^{(1)}$ & $e_l^{(2)}$ & $e_{l-1}^{(2)}/e_{l}^{(2)}$ & $e_l^{(3)}$ & $e_{l-1}^{(3)}/e_{l}^{(3)}$\\ \hline 1 & 32 & 25 & 0.6122 & & 1.9517 & & 3.0545 & \\ 2 & 128 & 81 & 0.1529 & 4.0027 & 1.0896 & 1.7912 & 1.1445 & 2.6689 \\ 3 & 512 & 289 & 0.0346 & 4.4266 & 0.4879 & 2.2331 & 0.5639 & 2.0296 \\ 4 & 2048 & 1089 & 0.0082 & 4.2069 & 0.2234 & 2.1839 & 0.2728 & 2.0667 \\ 5 & 8192 & 4225 & 0.0020 & 4.1151 & 0.1183 & 1.8879 & 0.1336 & 2.0418 \\ 6 & 32768 & 16641 & 0.0005 & 4.0585 & 0.0595 & 1.9890 & 0.0668 & 2.0008 \\ \hline \end{tabular} \caption{ The computed maximum relative errors $e_n$ in maximum energy, maximum $L_2$ and maximum in broken time error on different meshes with mesh sizes $h_l= 2^{-l}, l=1,...,6$ for the function $\varepsilon$ with $m=4$ in \eqref{eps}.} \label{test3} \end{table} \begin{table} \center \begin{tabular}{ l l l l l l l l l } \hline $l$ & $nel$ & $nno$ & $e_l^{(1)}$ & $e_{l-1}^{(1)}/e_{l}^{(1)}$ & $e_l^{(2)}$ & $e_{l-1}^{(2)}/e_{l}^{(2)}$ & $e_l^{(3)}$ & $e_{l-1}^{(3)}/e_{l}^{(3)}$\\ \hline 1 & 32 & 25 & 0.6107 & & 1.9930 & & 3.0603 & \\ 2 & 128 & 81 & 0.1546 & 3.9505 & 1.1006 & 1.8108 & 1.1464 & 2.6696 \\ 3 & 512 & 289 & 0.0351 & 4.4031 & 0.4982 & 2.2090 & 0.5619 & 2.0403 \\ 4 & 2048 & 1089 & 0.0084 & 4.1954 & 0.2288 & 2.1777 & 0.2706 & 2.0765 \\ 5 & 8192 & 4225 & 0.0020 & 4.1106 & 0.1223 & 1.8715 & 0.1325 & 2.0417 \\ 6 & 32768 & 16641 & 0.0005 & 4.0561 & 0.0607 & 2.0139 & 0.0662 & 2.0011 \\ \hline \end{tabular} \caption{ The computed maximum relative errors $e_n$ in maximum energy, maximum $L_2$ and maximum in broken time error on different meshes with mesh sizes $h_l= 2^{-l}, l=1,...,6$ for the function $\varepsilon$ with $m=5$ in \eqref{eps}.} \label{test4} \end{table} Figure \ref{fig:F2} shows convergence rates of our numerical scheme based on a $P_1$ space discretization, taking the function $\varepsilon$ defined by \eqref{eps} with $m=2$ (on the left) and $m=3$ (on the right) for $\varepsilon(r)$. Similar convergence results are presented in Figures \ref{fig:F3} taking $m=4$ (on the left) and $m=5$ (on the right) in \eqref{eps}. \begin{figure}[h!] \begin{center} \begin{tabular}{cc} {\includegraphics[ trim = 4.0cm 4.0cm 1.0cm 4.0cm, scale=0.5, clip=]{disk_allnormsm2.pdf}} & {\includegraphics[trim = 4.0cm 4.0cm 1.0cm 4.0cm, scale=0.5, clip=]{disk_allnormsm3.pdf}} \\ $m=2$ & $m=3$ \end{tabular} \end{center} \caption{Maximum in time of relative errors for $m=2$ (left) and $m=3$ (right)} \label{fig:F2} \end{figure} \begin{figure}[h!] \begin{center} \begin{tabular}{cc} {\includegraphics[trim = 4.0cm 4.0cm 1.0cm 4.0cm, scale=0.5, clip=]{disk_allnormsm4.pdf}} & {\includegraphics[trim = 4.0cm 4.0cm 1.0cm 4.0cm, scale=0.5, clip=]{disk_allnormsm5.pdf}} \\ $m=4$ & $m=5$ \end{tabular} \end{center} \caption{Maximum in time of relative errors for $m=4$ (left) and $m=5$ (right)} \label{fig:F3} \end{figure} Observation of these tables and figures clearly indicates that our scheme behaves like a first order method in the (semi-)norm of $L^{\infty}[(0,T);H^1(\Omega)]$ for ${\bf e}$ and in the norm of $L^{\infty}[(0,T);L^2(\Omega)]$ for $\partial_t {\bf e}$ for all the chosen values of $m$. As far as the values of $m$ greater or equal to $4$ are concerned this perfectly conforms to the a priori error estimates established in Section 6. However those tables and figures also show that such theoretical predictions extend to cases not considered in our analysis such as $m=2$ and $m=3$, in which the regularity of the exact solution is lower than assumed. Otherwise stated some of our assuptions seem to be of academic interest only and a lower regularity of the solution such as $H^2[\Omega \times (0,T)]$ should be sufficient to attain optimal first order convergence in both senses. On the other hand second-order convergence can be expected from our scheme in the norm of $L^{\infty}[(0,T);L^2(\Omega)]$ for ${\bf e}$, according to Tables 1-4 and Figures \ref{fig:F2} and \ref{fig:F3}. \section{Final remarks} As previously noted, the approach advocated in this work was extensively and successfully tested in the framework of the solution of CIPs governed by Maxwell's equations. More specifically it was used with minor modifications to solve both the direct problem and the adjoint problem, as steps of an adaptive algorithm to determine the unknown electric permittivity. More details on this procedure can be found in \cite{MalmbergBeilina1,Malmberg}.\\ As a matter of fact the method studied in this paper was designed to handle composite dielectrics structured in such a way that layers with higher permittivity are completely surrounded by layers with a (constant) lower permittivity, say with unit value. It should be noted however that the assumption that the minimum value of $\varepsilon$ equal one in the outer layer was made here only to simplify things. Actually under the same assumptions \eqref{convergence} also applies to the case where $\varepsilon$ in inner layers is allowed to be smaller than in the outer layer, say $\varepsilon <1$. For instance, if $\varepsilon > 2/3$ the upper bound \eqref{convergence} also holds for a certain mesh-independent constant ${\mathcal C}$. This is because under such an assumption on $\varepsilon$ it is possible to guarantee that the auxiliary problems \eqref{consist1} and \eqref{vectpoisson} are coercive. \\ On the other hand in case $\varepsilon$ can be less than or equal to $2/3$, the convergence analysis of scheme \eqref{eq7} is a little more laborious. The key to the problem is a modification of the variational form \eqref{eq2} as follows. First of all we set $\varepsilon_{min} = \displaystyle \min_{{\bf x} \in \Omega} \varepsilon({\bf x})$. Then we recast \eqref{eq2} for every $t \in (0, T)$ as : $\forall {\bf v} \in [H^1(\Omega)]^3$ it holds, \begin{equation} \label{eq2bis} \left ( \varepsilon \partial_{tt} {\bf e},{\bf v} \right ) + (\nabla {\bf e},\nabla {\bf v}) + \displaystyle \left(\nabla \cdot \left[\frac{\varepsilon {\bf e}} {\varepsilon_{min}}\right], \nabla \cdot {\bf v} \right) - (\nabla \cdot {\bf e}, \nabla \cdot {\bf v}) + (\partial_t{\bf e}, {\bf v})_{\partial \Omega} = 0. \end{equation} Akin to \eqref{eq2}, problem (\ref{eq2bis}) is equivalent to Maxwell's equations \eqref{eq1}. Indeed, integrating by parts in \eqref{eq2bis}, for all $ {\bf v} \in [H^1(\Omega)]^3$ we get, \begin{equation}\label{eq2ter} \begin{array}{l} \left ( \varepsilon \partial_{tt} {\bf e},{\bf v} \right ) + ( \nabla \times \nabla \times {\bf e}, {\bf v}) - (\nabla \nabla \cdot [\varepsilon {\bf e}],{\bf v}) \\ + \left(\partial_n{\bf e} + \partial_t {\bf e},{\bf v} \right)_{\partial \Omega} + (\nabla \cdot[\varepsilon_{min}^{-1} \varepsilon {\bf e}] - \nabla \cdot {\bf e}, {\bf v} \cdot {\bf n} )_{\partial \Omega} = 0 \end{array} \end{equation} Besides the Maxwell's equations in $\Omega \times (0, T)$, this time the conditions on $\partial \Omega \times (0,T)$ are those resulting from \eqref{eq2ter}, that is, \begin{equation} \label{mixedbc} \begin{array}{l} (\partial_{n} {\bf e} + \partial_t {\bf e} ) \cdot {\bf n} + \nabla \cdot [\varepsilon_{min}^{-1} \varepsilon {\bf e}] - \nabla \cdot {\bf e} = 0, \\ (\partial_{n} {\bf e} + \partial_t {\bf e} ) \times {\bf n} = {\bf 0}. \end{array} \end{equation} Since $\nabla \cdot \tilde{\bf e} = \nabla \cdot [\varepsilon \tilde{\bf e}] = 0$ on $\partial \Omega$, where $\tilde{\bf e}$ is the solution of Maxwell's equations in strong form \eqref{eq1}, this field necessarily satisfies the boundary conditions \eqref{mixedbc} as well. Then in the same way as the solution of \eqref{eq2}, this implies that the solution of \eqref{eq2bis} also fulfills $\nabla \cdot (\varepsilon {\bf e})=0$.\\ However in this case, given ${\bf g} \in [L^2_0(\Omega)]^3$, the auxiliary problem \eqref{vectpoisson} must be modified into, \begin{equation} \label{statbc} \begin{array}{ll} -\nabla^2 {\bf v} - \nabla [(\varepsilon_{min}^{-1} \varepsilon - 1) \nabla \cdot {\bf v}] = {\bf g} & \mbox{in } \Omega, \\ \left. \begin{array}{l} \partial_{n} {\bf e} \cdot {\bf n} + \nabla \cdot [\varepsilon_{min}^{-1} \varepsilon {\bf e}] - \nabla \cdot {\bf e} = 0, \\ \partial_{n} {\bf e} \times {\bf n} = {\bf 0}. \end{array} \right\} & \mbox{on } \partial \Omega. \end{array} \end{equation} This is actually the only real difference to be taken into account in order to extend to \eqref{eq2bis} the convergence analysis conducted in this paper. More precisely the final result that can be expected to hold for the fully discrete analog of \eqref{eq2bis}, defined as \eqref{eq7} under the same assumptions, is an $O(h^{\mu})$ error estimate, where $\mu \in (0,1]$ is such that the solution of \eqref{statbc} belongs to $[{\bf H}^{1+\mu}(\Omega)]^3$ for every ${\bf g} \in [L^2_0(\Omega)]^3$.\\ Another issue that is worth a comment is the practical calculation of the term $(\nabla \cdot \varepsilon {\bf e}_h^k, \nabla \cdot {\bf v})$ in \eqref{eq7}. Unless $\varepsilon$ is a simple function such as a polynomial, it is not possible to compute this term exactly. That is why we advocate the use of the well-known trapezoidal rule do carry out these computations. At the price of small adjustments in some terms involving norms of $\varepsilon$, the thus modified scheme is stable in the same sense as \eqref{stability}. Moreover the qualitative convergence result \eqref{convergence} remains unchanged, provided we require a little more regularity from $\varepsilon$. We skip details here for the sake of brevity.\\ To conclude the authors should point out that the analysis conducted in this work can be adapted to the two-dimensional case without any significant modification. Clearly enough the same qualitative results apply to this case under similar assumptions. \bigskip \noindent \textbf{\underline{Acknowledgment:}} The second author gratefully acknowledges the financial support provided by CNPq/Brazil through grant 307996/2008-5, while part of this work was accomplished. \rule{2mm}{2mm}
\section{Introduction} The Moran Model \cite{moran:model} is a fundamental population model of evolutionary biology. It has been used to study the evolution of a population of fixed size containing individuals of differing allelic types, subject to neutral or selective drift. In the large-population limit, its dual process describing population and sample genealogies is Kingman's Coalescent \cite{kingman:coalescent}. A very intuitive graphical representation of the infinite-population Moran Model is the Lookdown-Construction \cite{donnelly:lookdown,donnelly:lookdowna,donnelly:lookdownb}, which has also proven useful in the analysis of genealogical traits of a Moran population; for instance, it can be used to study the underlying process of \textit{Most Recent Common Ancestors} (\textit{MRCA}'s), i.e., the speed of evolution, or loss of information on the past \cite{pfaffelhuber:mrca}. A related approach to study the genealogy of a Moran population is to interpret the genealogy as a \textit{metric measure space}, which leads to a measure-valued Fleming-Viot process in the infinite-population limit \cite{depperschmidt:fleming}.\\ It is well known that genealogies of finite samples from such an infinite population can be represented in a discrete setting making use of the Yule process \cite{steel:yule}. This process generates random trees in the graph-theoretical sense and is often interpreted as a model of speciation. The distribution on trees of a given size that it induces, however, is equivalent to Kingman's Coalescent of finite size with respect to graph-theoretical and statistical properties of the trees it generates \cite{aldous:probability}. The aforementioned duality in turn establishes a connection between Moran and Yule processes.\\ In this work, we observe the evolution of the genealogy of a finite Moran population. We call this process the \textit{Evolving Moran Genealogy} (\textit{EMG}). It turns out that the state space of the \textit{EMG} can also be represented by the Yule process of finite iterations. In order to provide a detailed description of the \textit{EMG} as a Markov chain we discuss explicitly the Yule process and its associated the tree structures. We make use of this construction to observe genealogical properties of an evolving Moran population. This gives rise to the finite-population analogue of the limiting tree balance process described before \cite{pfaffelhuber:mrca,delmas:families}. This is related to the so-called root-jump process, also referred to as the \textit{MRCA}-process \cite{pfaffelhuber:mrca}. Again, here we study its finite-population counterpart. A crucial feature of this discrete setting is the time-reversibility of the \textit{EMG}. The time-reversed process, denoted by $\textit{EMG}^\flat$, is algorithmically simpler than the \textit{EMG}, because it requires only grafting of branches, instead of the two independent processes of splitting and killing. Therefore, the analysis of genealogical properties over time, e.g. of the \textit{MRCA}- process, is simplified. Furthermore, the consideration of the reversed process offers new and interesting insights on the "age structure" and persistence time of tree nodes. \section{Material} \subsection{Trees Generated under the Yule Process}\label{subsec:yp} Many variations of the original Yule Process, or Yule Model, as defined by G. U. Yule \cite{yule:process}, have been considered throughout the literature of mathematical population genetics. One very basic, discrete version of the process is described in Procedure~\ref{proc:yule} (see also \cite{steel:yule}):\\ \vbox{ \vspace{5pt} \begin{algbox}{Discrete Yule Process}{proc:yule} \begin{algorithmic}[1] \State Start with a tree consisting of one single leaf node $\iota$. \While{Tree has $k<n$ leaves} \State Choose one leaf $\iota$ uniformly, label it by the current total number of leaves, turn it into an internal node $\nu$ with label $k$ and append two new leaves to it. \EndWhile \Ensure Tree with $n$ leaves \end{algorithmic} \end{algbox} } \vbox{ \begin{definition} \vskip 0pt ~ \begin{itemize} \item A tree $T$ generated according to Procedure~\ref{proc:yule} is called a (random) \textit{Yule tree}. \item The \textit{size} $|T|$ of $T$ is given by the number $n$ of leaves. \item Let $\iota = T^{(1)},\cdots,T^{(n)}=T$ denote the trees at intermediate iterations. \end{itemize} \end{definition} } In the context of \cite{ford:alpha}, Procedure~\ref{proc:yule} corresponds to the $\alpha$-model with $\alpha=0$. We ssume that appending of leafs is graphically carried out in downward direction and in such a way that $T$ is a plane graph. In particular, this means that in each iteration, one of the leaves is appended to the bottom left and one to the bottom right. This induces an orientation on the branch pairs appended below an internal node, and a horizontal ordering of the leaves of $T$, which allows us to denote them by $\iota_1,\dots,\iota_n$ from left to right. Similarly, identifying the index of an internal node with its label assigned by the Yule process, we may denote the internal nodes consecutively by $\nu_1,\dots,\nu_{n-1}$. If $n\geq 2$, the internal node $\nu_1$ is of (total) degree $2$ and is called \textit{root} of $T$, while all other internal nodes are of degree $3$. $T$ has exactly $2n-2$ edges (\textit{branches}), and for any leaf $\iota\in\{\iota_1,\dots,\iota_n\}$, when moving downward on the unique path from $\nu_1$ toward $\iota$, the sequence of integer labels of internal nodes on this path is increasing. Because of that, $T$ can be interpreted as an object of the class of \textit{binary increasing trees} \cite{donaghey:bij} that are additionally equipped with an orientation on the branches, i.e., ordered (e.g. \cite{flajolet:combinatorics}, pp. 143-144). \vbox{ \begin{definition} \vskip 0pt ~ \begin{itemize} \item An \textit{ordered binary increasing tree} $T$ of size $n$ is a rooted binary tree with $n$ leaves and $n-1$ internal nodes carrying unique labels from the set $\{1,\dots,n-1\}$, such that the sequence of integers encountered on any path from the root to a leaf is increasing, and for any internal node, it holds that one of the two branches attached below (from the root) points to the left, and the other one to the right. \item Let $\mathcal{T}_n$ denote the set of all binary increasing trees of size $n$. \end{itemize} \end{definition} } The size of $\mathcal{T}_n$ equals $(n-1)!$, and it is easily deduced that for any $T\in\mathcal{T}_n$, there exists precisely one sequence of possible iterations of the Yule process such that the resulting Yule tree equals $T$. Furthermore, since leaves are always chosen uniformly in the Yule process, the probability of obtaining some $T\in\mathcal{T}_n$ under the Yule Process is $\Pr(T)=\frac{1}{(n-1)!}$, i.e., the Yule tree is uniformly distributed on $\mathcal{T}_n$.\\ \begin{figure} \includegraphics[scale=.5]{yuleprocess} \caption{Some possible iterations of the Yule tree-generating procedure} \label{fig:yp} \end{figure} Suppose further that all $n$ leaves of $T$ are drawn on the same vertical "height" $0$, and all internal nodes $\nu_k$ on height $n-k$. Then, $T$ divides the plane into $n$ layers $l_1,\dots,l_n$, where layer $l_k,k=2,\dots,n-1$ is vertically restricted by the heights of $\nu_{k-1}$ and $\nu_{k}$. Layer $1$ extends upwards to infinity from the root's height, and layer $n$ from height $1$ to $0$. If $k\geq 2$, the $k$'th layer of $T$ is the layer which is crossed by precisely $k$ branches. This notion can be extend to layer $1$ by assuming that it contains an \textit{imaginary branch} extending from the root upwards. We may think of a branch $\beta$ as a composite of \textit{branch segments}, where a segment only extends over one layer. Then $T$ contains $1+2+\dots+n=\frac{n(n+1)}{2}$ such segments (counting the imaginary branch as a single segment). We denote them by $b_1,\dots,b_{\frac{n(n+1)}{2}}$ from top to bottom and left to right (see Figure \ref{fig:yt2}).\\ \begin{figure} \includegraphics[scale=.5]{yuletree2} \caption{A Yule tree of size $5$ with all layer, branch segment and node labellings depicted} \label{fig:yt2} \end{figure} To simplify the following calculations, we define the following notation:\\ \vbox{ \begin{enumerate} \item We denote by $\sigma_T(i)$ the mapping from an integer $i,i=1,\dots,n-1$ to the leaf $\iota$ of $T^{(i)}$ chosen in the $i$'th iteration of the process generating $T$. \item We denote by $l(b)$ the layer across which a segment $b$ extends. \end{enumerate} } Let $S$ denote a set of leaves of some $T\in\mathcal{T}_n$. Connecting all leaves of $S$ according to the branching pattern of $T$ generates another tree $T_{S}$ on $|S|$ leaves, where $|S|-1$ internal nodes of $T$ are preserved. If we label the internal nodes of $T_{S}$ by $1,\dots,|S|-1$ such that their relations with respect to height are preserved from $T$, $T_{S}\in\mathcal{T}_{|S|}$. Each leaf $\iota'$ in $T_S$ equals some leaf $\iota\in \{\iota_1,\dots,\iota_n\}$ of $T$, and the horizontal order of leaves in $T_S$ is in accordance with that in $T$. Similarly, each internal node $\nu'_k$ in $T_S$ is representative of some internal node $\nu_{l}$ in $T$, with $k\leq l$.\\ \vbox{ \begin{definition} For $T\in\mathcal{T}_n$ and $\emptyset\neq S\subseteq\{\iota_1,\dots,\iota_n\}$: \begin{itemize} \item The object $T_{S}$ is called the ($S$-)\textit{induced subtree} of $T$. \item For an internal node $\nu'\in\{\nu'_1,\dots,\nu'_{|S|-1}\}$ of $T_S$, let $\phi(\nu')$ denote the internal node of $T$ that is represented by $\nu'$ in $T_S$. \item For all $j=1,\dots,|S|-1$, let $\tau(j)\in\{1,\dots,n-1\}$ denote the label of $\phi(\nu'_j)$ in $T$ \end{itemize} \end{definition} } \begin{figure} \includegraphics[scale=.625]{induced} \caption{A Yule tree of size 5 and the induced subtree of leaves $\iota_1,\iota_3,\iota_5$.} \label{fig:induced} \end{figure} See Figure~\ref{fig:induced} for an example. If $S=\{\iota\}$ for some single leaf $\iota$ of $T$, $T_S$ equals the tree of size $1$ consisting just of $\iota$, and $T_{\{\iota_1,\dots,\iota_{n}\}}=T$.\\ In the following Lemma, we state that Yule trees exhibit a form of self-similarity with respect to induced subtrees. \begin{lemma}[Sample-Subtree Invariance of Yule trees]\label{lemma:ssiyt} Let $T$ denote a Yule tree of size $n$, and $S\subseteq \{\iota_1,\dots,\iota_n\}$, $|S|=k$, where the leaves $\iota\in S$ are chosen uniformly and without replacement. Then \begin{equation} \forall \tilde{T}\in\mathcal{T}_k:\ \Pr(T_S=\tilde{T})=\frac{1}{(k-1)!} \end{equation} \end{lemma} \begin{proof} We show that we can treat $T_S$ as a tree generated by the Yule Process. Since this is obviously true for $|S|=1$ (or $S=2$), we apply induction on $k$.\\ Let $S=\{\iota'_1,\dots,\iota'_{k}\}$. Tracing back the iterations $l = n,\dots,\tau(|S|-1)$ of the process generating $T$, for each $\iota'_{j}\in S$ there is a unique leaf $\iota^{(l)}_{j}$ of $T^{(l)}$ such that either $\iota'_j=\iota^{(l)}_j$ or $\iota'_j$ is appended below $\iota^{(l)}_j$ by one or more Yule iterations. In $T^{(\tau(|S|-1)-1)}$, a leaf $\iota^{*}=\sigma_T(\tau(|S|-1))$ is turned into $\phi(\nu_{|S|-1})$ in iteration $\tau(|S|-1)$ and two of the leafs $\iota^{(\tau(|S|-1))}_m,\iota^{(\tau(|S|-1))}_{m+1}$ that are the correspondents of $\iota'_m,\iota'_{m+1}$ in $T^{(\tau(|S|-1))}$ are appended below.\\ Consider the set $S'=\{\iota^{\tau(|S|-1)}_{1},\dots,\iota^{\tau(|S|-1)}_{m-1},\iota^*,\iota^{\tau(|S|-1)}_{m+2},\dots,\iota^{\tau(|S|-1)}_k\}$. Because of the established correspondence of internal nodes between $T_S$ and $T^{(\tau(|S|-1)-1)}_{S'}$, $T_S$ is created out of $T^{(\tau(|S|-1)-1)}_{S'}$ by turning $\iota^*$ into an internal node and appending two new leaves. If $\iota^*$ is chosen uniformly from $S'$, then this simply corresponds to one Yule iteration. We verify this, writing $\Pr(\sigma_{T_S}(|S'|)=\iota^*)$ for the probability that $\iota =\iota^*$ for $\iota\in S'$: \begin{align*} \Pr(\sigma_{T_S}(|S'|)=\iota^*)&=\Pr\left(\sigma_T(\tau(|S|-1))=\iota^*|\sigma_T(\tau(|S|-1)) \in S'\right)\\ &=\frac{1/\tau(|S|-1)}{|S'|/\tau(|S|-1)}\\ &=\frac{1}{|S'|} \end{align*} In addition, the fact that $i^*$ is chosen uniformly from $S'$ implies that $S'$ can be treated as a set of size $k-1$ that is randomly chosen from the leaves of $T^{(\tau(|S|-1)-1)}$. By induction hypothesis, the induced subtree $T^{(\tau(|S|-1)-1)}_{S'}$ is then a Yule tree of size $k-1$, i.e. generated by $k-2$ iterations. Since the last step from $T^{(\tau(|S|-1)-1)}_{S'}$ to $T_S$ can be interpreted as a $k-1$'th iteration, we conclude that the process generating $T_S$ is a Yule Process of $|S|-1=k-1$ iterations. \end{proof} This property is similar to what is called \textit{Markovian self-similarity} in \cite{ford:alpha}. Another form of self-similarity that arises in the context of the Yule Process is \textit{Horton self-similarity}, which applies, for example, to the limit of Kingman's Coalescent \cite{kovchegov:similarity}.\\ Let again $T$ denote a Yule tree of size $n$. Instead of applying an iteration of the Yule process, $T$ can also be transformed into a Yule tree of size $n+1$ by \textit{random grafting} (Procedure~\ref{proc:rg}) a new branch leading to a leaf into $T$:\\ \vbox{ \vspace{5pt} \begin{algbox}{Random Grafting Operation}{proc:rg} \begin{algorithmic}[1] \Require Yule tree $T$ of size $n$ \State Choose a branch segment $b$ uniformly from all $\frac{n(n+1)}{2}$ possible segments and an "orientation" $\chi\in \{\textit{left,right}\}$ uniformly \Comment{including the imaginary branch} \State Split all branch segments $b',l(b')=l(b)$ into two separate branch segments \Comment{forming an additional layer} \State Between the two pieces $b^{(1)},b^{(2)}$ resulting from splitting $b$, place a new internal node $\nu$ with label $l(b)$. \State Increase the labels of all internal nodes in layers $k>l(b)$ by one; \State At $\nu$, append a new branch $\beta$ consisting of $n-l(b)+1$ segments and ending in a new leaf $\iota$, to the left or right depending on $\chi$; \State $\hat{T}\leftarrow T$ \Ensure Tree $\hat{T}$ with $n+1$ leaves \end{algorithmic} \end{algbox} } The orientation $\chi$ accounts for the fact that branches are implicitly oriented in the version of the Yule Process described above. Note that the position of the new leaf $\iota$ in $\hat{T}$ depends on $\chi$. A possible realization of Procedure~\ref{proc:rg} is depicted in Figure~\ref{fig:regraft}.\\ Applying Procedure~\ref{proc:rg}, we obtain an object $\hat{T}\in\mathcal{T}_{n+1}$. We write $T\uparrow\hat{T}$ if $\hat{T}$ was constructed from $T$ by random grafting. In total, there are $k(k+1)$ possibilities $(b,\chi)$ of performing a grafting in $T$ of equal probability, and unique with respect to which leaf and internal node of $\hat{T}$ they generate. However, different grafting operations on $T$ may generate the same object $\hat{T}$. \begin{figure} \includegraphics[scale=.5]{regraft} \caption{The regrafting operation~\ref{proc:rg} performed on the branch segment with the "\textcolor{green}{o}" mark, transforming the $3$-sized tree on the left into a tree of size $4$.} \label{fig:regraft} \end{figure} The relation between grafting operation and the original Yule Process is described by the following Lemma: \begin{lemma}[Piecewise Recovery by Grafting]\label{lemma:pwr} Let $T$ be a Yule tree of size $n$, $S=\{\iota_1',\dots,\iota_{k+1}'\}\subseteq \{\iota_1,\dots,\iota_n\}$ a set of leaves chosen uniformly without replacement, and $\iota'\in S$ chosen uniformly. Then \begin{equation} \forall T'\in\mathcal{T}_{k},T''\in\mathcal{T}_{k+1}:\ \Pr(T_S=T''|T_{S\setminus \iota'}=T')=\Pr(T'\uparrow T'') \end{equation} \end{lemma} \begin{proof} Let $l\in\mathbb{N}_0$ denote the number of graftings that can be performed on $T'$ to generate $T''$, thus $\Pr(T'\uparrow T'')=\frac{l}{k(k+1)}$. On the other hand, \begin{align*}\Pr(T_S=T''|T_{S\setminus \iota'}=T')&=\frac{\Pr(T_S=T'',T_{S\setminus \iota'}=T')}{\Pr(T_{S\setminus \iota'}=T')}\\ \end{align*} and by Lemma~\ref{lemma:ssiyt}, $\Pr(T_{S\setminus \iota'}=T')=1/(k-1)!$. Let $m\in\mathbb{N}_0$ denote the number of leafs $\iota'\in S$ such that $T_{S\setminus \iota'}=T'$. Since each tree $\tilde{T}\in\mathcal{T}_{k+1}$ is equally likely to be the induced subtree $T_S$ and $\iota'\in S$ is chosen uniformly, we have $$\Pr(T_S=T'',T_{S\setminus \iota'}=T')=\frac{m}{k!(k+1)}$$ and thus $\Pr(T_S=T''|T_{S\setminus \iota'}=T')=\frac{m}{k(k+1)}$.\\ Let $\iota'\in S$ such that $T_{S\setminus \iota'}=T'$, and $\nu'$ the internal node $\iota'$ is appended to. There exists exactly one tuple $(b,\chi)$ such that, performing the associated grafting operation in $T'$, we obtain $T''$, the leaf generated by the operation occupies the position of $\iota'$ in $T''$, and the internal node generated by it carries the label of $\nu'$. Conversely, each tuple $(b,\chi)$ such that the associated grafting operation on $T'$ yields $T''$ generates a unique leaf $\iota ^*$ with respect to horizontal position and an internal node $\nu ^*$. Then, there exists a unique $\iota'\in S$ that occupies the position of $\iota ^*$ in $T_S$, and since $T''=T_S$, the induced subtree $T_{S\setminus \iota'}$ of $T_S$ equals $T'$. Therefore, $m=l$ holds, which ends the proof. \end{proof} We immediately conclude \begin{corollary} The distributions of the $n$-sized Yule tree and $T\in\mathcal{T}_n$ generated by successive random graftings are equal, therefore $$\Pr(T|T\textnormal{ generated by random grafting})=\frac{1}{(n-1)!}$$ \end{corollary} \begin{proof} This follows by induction on $n$, making use of Lemma~\ref{lemma:pwr}. \end{proof} \subsection{The Genealogical Process of a Moran Population} The Moran process of finite size $n\in\mathbb{N}$ in discrete time is a Markov chain whose state space consists of ordered multisets $\mathcal{P}_i=\{x_1,\dots,x_n\}$ ("populations") of objects ("individuals"), where $i\in\mathbb{N}_0$ represents time, and $\mathcal{P}_0$ is some initial set. The transition between time steps is facilitated by the following operation, incorporating two random mechanics:\\ \vbox{ \vspace{5pt} \begin{algbox}{Iteration of the Moran process}{proc:moran} \begin{algorithmic}[1] \Require Population $P$ of size $N$ \State Choose one element $x_k$ of $P$ uniformly and create a copy $x_k'=x_k$ \State Choose one element $x_l$ of $P$ uniformly \State $P'\leftarrow \{x_1,\dots,x_{l-1},x_k',x_{l+1},\dots,x_N\}$ \Ensure New population $P'$ of size $N$ \end{algorithmic} \end{algbox} }\\ \vbox{ \begin{definition} The neutral Moran process is denoted by $M=(\mathcal{P}_i)_{i\in\mathbb{N}}$, where $\mathcal{P}_{i+1}$ is obtained by the application of Procedure~\ref{proc:moran} on $\mathcal{P}_i$. \end{definition} } One iteration of $M$ is often interpreted as one individual of $\mathcal{P}_i$ producing offspring, and one dying. Note that $k=l$ is not excluded, therefore, there are $n^2$ possible transitions of equal probability $\frac{1}{n^2}$. Several modifications of this process exist \cite{etheridge:popmodels}; for instance, the case of an initial population consisting of two different "types" of individuals $a,A$ is known as the \textit{two-allele} Moran process. Other versions allow mutations between types or let the probabilities of producing offspring and/or dying depend on the type of individuals to model natural selection \cite{kluth:moranselection}. Here, we only consider the \textit{neutral} Moran process with uniform transition probabilities and without mutation.\\ With probability $1$, there is a finite time $i^*$ at which $M$ will enter a state in which the population consists only of the copies (descendants) of some $x_k\in \mathcal{P}_0$, while all other $x_l\in \mathcal{P}_0,l\neq k$, and their copies have been removed from the population. The individual $x_k$, or one of its descendants, is thus the \textit{Most Recent Common Ancestor} (\textit{MRCA}) dating back to at most time $0$, and looking backwards in time, there exists a branching pattern describing how the current population of $x_k$-copies has been created, in the form of a binary tree $T$ with branch lengths given implicitly by the number of time steps between splits. Considering $n\rightarrow \infty$ and rescaling time by $2/n^2$, the (infinitely large) genealogy $T$ after the first time at which there exists a \textit{MRCA}) is a realization of Kingman's Coalescent \cite{wakeley:coaltheory} and all sample genealogies are (Kingman-) Coalescent trees of sample size $n'$, $n'\in\mathbb{N}$. In this work, we focus on genealogies of finite Moran processes.\\ We assume that copy and original are indistinguishable after a duplication ($M$ is memoryless), and the copy is placed to the side of the original (instead of replacing the killed individual), and other individuals are shifted to the left or right depending on whether $l<k$ or $l>k$. This is achieved by following Procedure~\ref{proc:pmoran} and produces a "disentangled" version of the Moran process. Importantly, $T$ can then be treated as a plane graph without having to re-order individuals (see Figure~\ref{fig:plane}). Although this may seem like a minor additional complication, it is in fact crucial for the following considerations, similarly to the case of the Lookdown-Construction \cite{donnelly:lookdown,donnelly:lookdowna,donnelly:lookdownb}, whose benefits also result from intelligent organization of duplications and removals in the underlying population model.\\ \vbox{ \vspace{5pt} \begin{algbox}{Planar order maintenance in $M$}{proc:pmoran} \begin{algorithmic}[1] \Require Population $P$ of size $N$ \State Choose one element $x_k$ of $P$ uniformly and create a copy $x_k'=x_k$ \State Choose one element $x_l$ of $P$ uniformly \If{$l<k$} \State Lower the position of individuals $x_{l+1},\dots,x_{k-1}$ by one; \State Assign the possible positions $k-1,k$ to individual $x_k$ and its copy with probability $1/2$; \State $P'\leftarrow \{x_1,\dots,x_{l-1},x_{l+1},\dots,x_{k-1},x_k\textnormal{v}x_{k}',x_k\textnormal{v}x_{k}',x_{k+1},\dots,x_n \}$ \ElsIf{$l>k$} \State Increase the position of individuals $x_{k+1},\dots,x_{l-1}$ by one; \State Assign the possible positions $k,k+1$ to individual $x_k$ and its copy with probability $1/2$; \State $P'\leftarrow \{x_1,\dots,x_k\textnormal{v}x_{k}',x_k\textnormal{v}x_{k}',x_{k+1},\dots,x_{l-1},x_{l+1},\dots,x_n \}$ \Else \State Replace $x_k$ by $x_k'$; \State $P'\leftarrow \{x_1,\dots,x_{k-1},x_{k}',x_{k+1},\dots,x_n \}$ \EndIf \Ensure New population $P'$ of size $N$ \end{algorithmic} \end{algbox} } \begin{figure} \begin{center} \includegraphics[scale=.325]{moran} \end{center} \caption{Iterations of a Moran process, where the order is maintained according to~\ref{proc:pmoran}.} \label{fig:plane} \end{figure} Since the time $i^*$ is almost surely finite, we assume in what follows that at $i=0$ there already exists a genealogy $T_0$. We disregard the branch lengths of $T_0$ and instead assume that internal nodes of $T_0$ are labeled by integers $1,\dots,n-1$ respecting the order of the past split events which they represent, and obtain an $n$-sized Yule tree, where the leaves $\iota_1,\dots \iota_n$ represent the individuals $x_1,\dots,x_n$ of the population. By \cite{aldous:probability}, $T_0$ can be treated as the result of a Yule process of $n-1$ iterations. In the following iterations $i>0$, $M$ can be emulated by observing the genealogy $T_i,i\geq 0$ directly, where $T_i$ is modified according to Procedure~\ref{proc:emg}. \vbox{ \vspace{5pt} \begin{algbox}{Evolving Moran Genealogy given $T_i$}{proc:emg} \begin{algorithmic}[1] \Require Current tree $T_i\in\mathcal{T}_n$ \State Choose $k,l\in \{1,\dots,n\}$ uniformly and independently \If{$k=l$} \State $T_{i+1}\leftarrow T_i$ \Else \State Remove the leaf representing the killed individual $x_l$ alongside the branch connecting it to the remainder of $T_i$, and the internal node $\nu_j$ at the position in $T_i$ that branch is attached at; \State Merge the two branch segments $b,b'$ connected to $\nu_j$ into one; \State Merge all pairs of branch segments $b,b'$ in layers $j,j+1$ belonging to the same branch into single branch segments;\\ \Comment{4-6 "remove" layer $j+1$} \State Decrease the labels of $\nu_{j'},j'>j$ by one in $T_i$; \State Turn the leaf representing the duplicated individual $x_k$ in $T_i$ into an internal node with two new leaves appended to it and label it by $n-1$; $T_{i+1}\rightarrow T_i$; \EndIf \Ensure New tree $T_{i+1}\in\mathcal{T}_n$ \end{algorithmic} \end{algbox} } Let $\Phi_{k,l}(T_i)$ denote the output of Procedure~\ref{proc:emg} given $k,l$. Then, we define:\\ \vbox{ \begin{definition} \vskip 0pt ~ \begin{itemize} \item The process $(\mathcal{T}_i)_{i\in\mathbb{N}}$ with $T_{i+1}=\Phi_{k,l}(T_i)$ for uniform $k,l$ and uniform $T_0$ is called \textit{Evolving Moran Genealogy}, for short \textit{EMG}. \item We will identify a leaf $\iota$ of any $T_i,i\geq 0$ with the individual $x$ representing it and write $x\in T_i$ if an individual $x$ is part of $T_i$. \item For $T,T'\in\mathcal{T}_n$, we define the notation $$T \rightarrow T' \Leftrightarrow \exists k,l\in\{1,\dots,n\}: \Phi_{k,l}(T)=T'$$ \end{itemize} \end{definition} } \begin{figure} \includegraphics[scale=.25]{emg2step} \caption{Two steps in an \textit{EMG} of size $4$. Each step, one individual is killed ("\textcolor{red}{X}") and one duplicated ("\textcolor{red}{$\Lambda$}").} \label{fig:emg2step} \end{figure} The \textit{EMG} (see Figure~\ref{fig:emg2step}) is a Markov chain on the set $\mathcal{T}_n$. Its transition matrix $E$ has nonzero diagonal entries, since $l=k$ entails $T_{i+1}=T_i$. Secondly, at most $n-1$ transition steps of the above form are needed to transform $T_i$ into some arbitrary $T'\in\mathcal{T}_n$, because all duplications may be applied to one single individual $x$ of the population $\mathcal{P}_i$ at time $i$ and its descendants, and all removals to the remaining individuals of $\mathcal{P}_i$, corresponding to a Yule process of $n-1$ iterations. As a result, the \textit{EMG} is a recurrent Markov chain. Aperiodicity of the \textit{EMG} also follows, as $T_{i+1}=T_i$ can always happen with positive probability.\\ As a consequence, there exists a stationary distribution $P^*$ of the \textit{EMG} on $\mathcal{T}_n$. Since we may interpret the genealogy $T_{i}$ as a result of a Yule process at each stage $i>0$, and since all $T\in\mathcal{T}_n$ are equally likely under the Yule process, it follows that $P^*$ is the uniform distribution, i.e. $P^*(T)=\frac{1}{(n-1)!}$ for all $T\in\mathcal{T}_n$.\\ The relation $T\rightarrow T$, indicating that $T$ can be transformed into $T'$ by some duplication/remove combination in $M$, can be used to describe the entries of $E$. Importantly, \begin{equation}\notag T=T'\Rightarrow T\rightarrow T';\ T\rightarrow T'\not\Rightarrow T' \rightarrow T \end{equation} Then the $T,T'$-entry of $E$ can be denoted in the following way: \begin{equation}\notag \Pr(T_{i+1}=T'|T_i=T)=\begin{cases} 0 & T\not\rightarrow T' \\ \frac{|\{(k,l)\in\{1,\dots,n\}^2:\Phi_{k,l}(T)=T'\}|}{n^2} & \textnormal{otherwise} \\ \end{cases} \end{equation} In particular, the diagonal entries of $E$ are nonzero and depend on $T$. Suppose $n=2^k$ for some $k\geq 2$, and consider the \textit{caterpillar} $C\in\mathcal{T}_n$ obtained under the Yule process by always choosing the leftmost individual to split, and any \textit{complete binary search tree} $B\in\mathcal{T}_n$, i.e. a tree characterized by the fact that there is an equal number of leaves on both subtrees below each internal node. Then $\Pr(T_{i+1}=C|T_i=C)=\frac{2n}{n^2}$, whereas $\Pr(T_{i+1}=B|T_i=B)=\frac{n+2}{n^2}$. \section{Results} \subsection{The Process of Tree Balance} Since a tree $T\in\mathcal{T}_n$ obtained under the \textit{EMG} is plane and individuals ordered from left to right, we may consider the left and right subtrees $T^l,T^r$ below the root node $\nu_1$. Essentially, $T^l$ can be thought of as the induced subtree of all leaves on the left side below $\nu_1$ (the same holds for $T^r$). Suppose we are interested in the dynamics of the number of leafs on the left, i.e. $|T^l|$.\\ \vbox{ \begin{definition} The process $\textit{TB}:=(|T_i^l|)_{i\in\mathbb{N}}$ is called Tree Balance Process of the Evolving Moran genealogy. \end{definition} } The choice between observing left and right subtree size is arbitrary, since always $|T^r|=n-|T^l|$. Closely related to the process $\textit{TB}$ is the $\Omega_1$-statistic \cite{aldous:balance,feretti:srecevents} observed over time, where $\Omega_1(T_i):=\min(|T_i^l|,|T_i^r|)$, and one observes $(\Omega_1)_{i\in\mathbb{N}}$. There is little difference between $\textit{TB}$ and the process of $\Omega_1$, as paths of $\textit{TB}$ are essentially mirrored at $\frac{n}{2}$ when considering $\Omega_1$. Determining the dynamics of $\textit{TB}$ thus suffices to also obtain those of $\Omega_1$.\\ \begin{prop} The transition probabilities of $\textit{TB}$ are as follows:\\ \hfill\\ If $2\leq |T_i^l|\leq n-2$, \begin{equation}\notag \Pr\left(|T_{i+1}^l|=\omega ~\Bigm| ~|T_i^l|\right)= \begin{cases} \frac{|T_i^l|(n-|T_i^l|)}{n^2} & \omega = |T_i^l|+1 \\ \frac{|T_i^l|^2+(n-|T_i^l|)^2}{n^2} & \omega = |T_i^l|\\ \frac{|T_i^l|(n-|T_i^l|)}{n^2} & \omega = |T_i^l|-1 \\ \end{cases} \end{equation} If $|T_i^l|=1$, \begin{equation}\notag \Pr\left(|T_{i+1}^l|=\omega\right)= \begin{cases} \frac{1}{n} & \omega = 2 \\ \frac{(n-1)^2+2}{n^2} & \omega = 1\\ \frac{1}{n^2} & \textnormal{otherwise} \\ \end{cases} \end{equation} And if $|T_i^l|=n-1$, \begin{equation}\notag \Pr\left(|T_{i+1}^l|=\omega\right)= \begin{cases} \frac{1}{n} & \omega = n-2 \\ \frac{(n-1)^2+2}{n^2} & \omega = n-1\\ \frac{1}{n^2} & \textnormal{otherwise} \\ \end{cases} \end{equation} \end{prop} \begin{proof} Suppose $2\leq |T_i^l|\leq n-2$. $|T_{i+1}^l|=|T_i^l|-1$ is the case if one individual on the left side is removed and one on the right is duplicated. This happens with probability $\frac{|T_i^l|(n-|T_i^l|)}{n^2}$. We obtain the same probability for the case $|T_{i+1}^l|=|T_i^l|+1$.\\ Finally, we have $|T_{i+1}^l|=|T_i^l|$ if removal and duplication take place on the same side. The probability of this is $\frac{|T_i^l|^2+(n-|T_i^l|)^2}{n^2}$.\\ The only difference in the cases $|T_i^l|=1,n-1$ is that one has to include the possibility of a complete removal of $T_i^l$ in the first and $T_i^r$ in the latter case. If this happens, $|T_{i+1}^l|$ and $|T_{i+1}^r|$ are independent of $|T_i^l|$ and $|T_i^r|$. In fact, $|T_{i+1}^l|$ then assumes any value $1,\dots,n-1$ with uniform probability \cite{aldous:balance}.\\ Therefore, considering $|T_i^l|=1$, the total probability $\Pr(|T_{i+1}^l|=2)$ is the sum of the probability that the individual on the left is duplicated and one on the right is removed, which amounts to $\frac{(n-1)}{n^2}$, and the probability that it is removed and $|T_{i+1}^l|=2$ by chance, which happens with probability $\frac{n-1}{n^2}\frac{1}{n-1}=\frac{1}{n^2}$. This sum equals $\frac{1}{n}$.\\ For $\Pr(|T_{i+1}^l|=1)$ and $\Pr(|T_{i+1}^l|>2)$ the calculation is similar, and of course the case $|T_i^l|=n-1$ can be treated analogously. \end{proof} We notice that the transition probabilities within an episode are identical to those in a two-allele Moran Model. In the large-population limit, tree balance has been identified before as a Wright-Fisher Diffusion \cite{pfaffelhuber:mrca,delmas:families}, to which $(|T_i^l|/n)_{i\in\mathbb{N}}$ (the values of \textit{TB} divided by population size) indeed converges if time is rescaled by $2/n^2$. The transition probabilities of \textit{TB} in the cases $|T_i^l|=1$ and $|T_i^l|=n-1$ correspond to the behaviour of the tree balance process in the limit, which, upon hitting a "boundary" ($0$ or $1$), resets at any value in $[0,1]$ with uniform probability.\\ Also, if $n$ is large and $\frac{|T_i^l|}{n}$ is either close to $0$ or $1$ (the genealogy is "unbalanced"), the strength of diffusion is weakest. Consequently, if the Evolving Moran Genealogy enters an unbalanced state, genealogies in the following generations are expected to be unbalanced as well.It might be worth to investigate whether and to what extent this can have diluting effects on statistics like Tajima's $D$ \cite{tajima:d}, or $T_3$ \cite{wieheli:t3}, which crucially depend on tree shape; particularly because unbalanced tree shapes can introduce a bias in the frequency spectrum of polymorphisms that may be confused with the effect of of natural selection.\\ We may refer to the phases between complete removals of $T_i^l$ or $T_i^r$ as \textit{episodes} of the process \textit{TB}. It is worth mentioning that the complete removals of $T_i^l$ or $T_i^r$, i.e. starting and ending times of episodes in $\textit{TB}$, are precisely the times of \textit{MRCA} jumps in the \textit{EMG}, to be discussed in section~\ref{sec:mrca}. \subsection{Time Reversal of the \textit{EMG}} We consider a second process on the set $\mathcal{T}_n$. Let $T\in\mathcal{T}_n$ and consider the \textit{Merge-Regraft} operation:\\ \vbox{ \vspace{5pt} \begin{algbox}{Merge-Regraft on given $T$}{proc:mrg} \begin{algorithmic}[1] \Require $T\in\mathcal{T}_n$ \State Choose one branch segment $b$ of $T$ from the set $\{b_1,\dots,b_{\frac{n(n+1)}{2}}\}$ with probability \begin{equation}\notag \Pr(b=b_k)=\begin{cases}\frac{1}{n^2} & b_k\textnormal{ ends in a leaf}\\ \frac{2}{n^2} & \textnormal{ otherwise} \end{cases} \end{equation} and $\chi$ from $\{\textit{left,right}\}$ with equal probability; \If{$b$ ends in a leaf} \State $T'\leftarrow T$ \Else \State Remove the $n$-th layer of $T$; remove $\nu_{n-1}$; place leafs at the tips of the branch segments that extend across layer $n-1$; \\ \Comment{the position of $\nu_{n-1}$ is then occupied by some leaf} \State Regraft a new leaf at branch $b$ with orientation $\chi$ in $T$ according to Procedure~\ref{proc:rg} (skipping step 1); \State $T'\leftarrow T$ \EndIf \Ensure $T'\in\mathcal{T}_n$ \end{algorithmic} \end{algbox} } Graphically, this operation adds a new leaf by performing a regrafting operation at segment $b$, and merges the two leaves belonging to the lowermost split into one. Note that if $b$ ends in a leaf ($l(b)=n$), regrafting at this branch establishes the lowermost split, in which case the tree remains the same. To clarify the purpose of step $5$, one may also imagine that all leafs are moved up by one layer, such that two of them must "merge". An example of such an operation is shown in Figure~\ref{fig:mr}.\\ \begin{figure} \begin{center} \includegraphics[scale=.375]{merge-regraft} \end{center} \caption{Visualization of a possible Merge-Regraft operation on the tree on the left. The pair of leaves belonging to the lowermost split merge (red area), the lowermost layer is removed, and a branch ending in a single "revived" leaf is inserted at the branch segment carrying the "\textcolor{green}{o}" mark. The resulting tree is shown on the right; note that both trees belong to $\mathcal{T}_4$.} \label{fig:mr} \end{figure} Let the result of this operation be denoted by $\Phi'_{b,\chi}(T)$. $\Phi'_{b,\chi}(T)$ is itself an object of the set $\mathcal{T}_n$. The function $\Phi'$ can be thought of as a combinatorial inversion of $\Phi$: The split event facilitated by $\Phi$ is revoked by $\Phi'$, and the leaf that is removed under $\Phi$ can be recovered ("revived") by $\Phi'$ by regrafting; in fact, we have $T\rightarrow T'\Leftrightarrow \exists (b,\chi): \Phi'_{b,\chi}(T')=T$.\\ We consider the process $$R:=(\tilde{T}_{i})_{i\in\mathbb{N}},$$ where $\tilde{T}_0$ is uniformly chosen and, given $\tilde{T}_i$, $\tilde{T}_{i+1}$ is generated by the mechanism described above, i.e. $\tilde{T}_{i+1}=\Phi'_{b,\chi}(\tilde{T}_i)$ for some random choice of $b$ and $\chi$ (See Figure~\ref{fig:emgb}). In what follows, we will show that this process represents a \textit{time-reversal} of the $EMG$ (where the term time-reversal is used in th e sense of e.g. \cite{lovasz:reversal}).\\ \begin{lemma} For all $T,T'\in\mathcal{T}_n$: \begin{equation} \textnormal{Pr}_{\textit{EMG}}(T_{j+1}=T'|T_{j}=T)=\textnormal{Pr}_{R}(\tilde{T}_{i+1}=T|\tilde{T}_{i}=T') \label{eq:transprobabilities} \end{equation} with $\Pr_{\textit{EMG}}$ denoting the transition probability of the \textit{EMG}-process, and $\Pr_{R}$ that of the process $R$. \end{lemma} \begin{proof} Recall that $\Phi$ was dependent on the choice of $k,l$, which were both chosen uniformly. The probability of $k=l$ in one step of the \textit{EMG}, which for all $T\in\mathbb{T}_n$ entails $\Phi_{k,k}(T)=T$, is $\frac{1}{n}$. The probability that the branch segment $b$ chosen in a transition of the process $R$ is inside layer $n$, which always leads to $\Phi'_{b,\chi}(\tilde{T})=\tilde{T}$, is also $\frac{1}{n}$ in total for any $T$.\\ We define for arbitrary $T,T'\in\mathcal{T}_n,T\rightarrow T'$: \begin{align*} S_1&:=\{(k,l)\in\{1,\dots,n\}^2:\Phi_{k,l}(T)=T',k\neq l\}\\ S_2&:=\{(b,\chi)\in\{b_1,\dots,b_{\frac{n(n-1)}{2}}\}\times\{\textit{left,right}\}:\Phi'_{b,\chi}(T')=T\} \end{align*} If we can show that $|S_1|=|S_2|$, we are done. Let $(k,l)\in S_1$. Let $\nu$ denote the internal node deleted by $\Phi_{k,l}(T)$. Choosing the regrafting site $b$ as the branch segment generated by merging the two segments connected to $\nu$ (compare step 5 in Procedure~\ref{proc:emg}), and $\chi$ according to whether the branch of $x_l$ extends to the left or right in $T$, we obtain a unique $(b,\chi)\in S_2$, which yields a mapping $\mu:S_1\rightarrow S_2$. Since by definition of the Yule process there cannot be two or more tuples $k,l$ and $k',l$ with $k\neq k'$ such that $\Phi_{k,l}(T)=\Phi_{k',l}(T)$, $\mu$ is injective.\\ On the other hand, for any $(b,\chi)\in S_2$ such that $\Phi'_{b,\chi}(T')=T$, choosing $l$ such that $x_l$ is the leaf regrafted in $T'$ by $\Phi'_{b,\chi}(T')$ and $k$ such that $x_k$ is the leaf replacing the highest-labeled internal node in $T'$ by $\Phi'_{b,\chi}(T')$ (see step 5 of Procedure~\ref{proc:mrg}), we obtain $(k,l)\in S_1$ such that $\mu((k,l))=(b,\chi)$. Therefore, $\mu$ is a bijection and both sets are equally large. \end{proof} \begin{corollary} The process $R$ represents the time-reversed process of the \textit{EMG}. \end{corollary} \begin{proof} The existence of a time-reversed process $R(\textit{EMG})$ on $\mathcal{T}_n$ is provided by the fact that it is a recurrent Markov chain with nonzero stationary distribution. The transition probabilities of this process are \begin{align*} \textnormal{Pr}_{R(\textit{EMG})}(T_{j+1}=T'| T_{j}=T)&=\textnormal{Pr}_{\textit{EMG}}(T_{i}=T'| T_{i+1}=T)\\ &=\textnormal{Pr}_{\textit{EMG}}(T_{i+1}=T| T_{i}=T')\frac{\textnormal{Pr}_{\textit{EMG}}(T_i=T')}{\textnormal{Pr}_{\textit{EMG}}(T_{i+1}=T)}\\ \end{align*} Since the stationary distribution of the \textit{EMG} is the uniform distribution, we have $\textnormal{Pr}_{\textit{EMG}}(T_i=T')=\textnormal{Pr}_{\textit{EMG}}(T_{i+1}=T)$. Therefore, \begin{equation} \textnormal{Pr}_{R(\textit{EMG})}(T_{j+1}=T'| T_{j}=T)=\textnormal{Pr}_{\textit{EMG}}(T_{i+1}=T| T_{i}=T') \end{equation} and these transition probabilities are exactly the ones provided by the process $R$ (compare equation~\eqref{eq:transprobabilities}). \end{proof} \vbox{ \begin{definition} We call the process $R$ the \textit{Evolving Moran Genealogy backwards in time}, for short $\textit{EMG}^\flat$. \end{definition} } \begin{figure} \includegraphics[scale=.25]{emg2a} \caption{Two possible transitions of the process $R$, i.e. the $\textit{EMG}^\flat$ of size $4$. Branch segment chosen for regrafting marked by "\textcolor{green}{o}".} \label{fig:emgb} \end{figure} We end this section with the remark that the \textit{EMG} and $\textit{EMG}^\flat$ bear a certain resemblance to the \textit{Aldous chain} on cladograms \cite{aldous:cladograms}, of which also an infinite-size limiting process has been described \cite{lohr:aldouschain}. The state space of the Aldous chain consists of cladograms, which are constructed slightly differently than $\mathcal{T}_n$. In particular, they are not internally labelled and their branches are not subdivided into segments. Still, both \textit{EMG} and $\textit{EMG}^\flat$ feature one of the two components of the \textit{Aldous move}, i.e. removal (\textit{EMG}) and reattachment ($\textit{EMG}^\flat$) of a single leaf and its associated branch. In combining those two mechanisms, one can define a third Markov chain, which would represent a version of the Aldous chain on $\mathcal{T}_n$. A possibility of further research could be to compare the mixing times of the respective chains. \subsection{\textit{MRCA} and Age Structure in the $\textit{EMG}^\flat$}\label{sec:mrca} Besides the technical aspects, there are some reasons why the $\textit{EMG}^\flat$ as a stochastic process can prove useful in theoretical and practical regard. While the transitions in the $\textit{EMG}$ rely on two random mechanics (duplication and removal), in the $\textit{EMG}^\flat$ they are unified within the regrafting operation. Because of that, aspects about the genealogy itself may become more tractable to analytic investigation. One good example for this is the \textit{MRCA}-process.\\ Let $x^*$ denote the \textit{MRCA} of a genealogy generated by a neutral Moran process. With probability $1$, after some finite time a descendant of $x^*$ will become ancestral to the entire population, establishing a new \textit{MRCA}. Therefore, defining $\chi_{\textit{MRCA}}(i)=1$ if at time $i$ a new \textit{MRCA} of the population is established (i.e., the \textit{MRCA} "jumps", which in the \textit{EMG} is represented by the eventual obliteration and repositioning of the root node of $T_i$), and $\chi_{\textit{MRCA}}(i)=0$ otherwise, we call $(\chi_{\textit{MRCA}}(i))_{i\geq 0}$ the \textit{MRCA}-process.\\ \begin{lemma}\label{lemma:mrca1} $(\chi_{MRCA}(i))_{i\geq 0}$ is a geometric jump process of intensity $\frac{2}{n^2}$. \end{lemma} \begin{proof} In the $\textit{EMG}^\flat$, the root of the genealogy $T_i$ changes if and only if the imaginary branch $b_1$ is chosen for regrafting. This happens with probability $\frac{2}{n^2}$ in each step (see also Figure \ref{fig:jumps}). \end{proof} This agrees with the results in \cite{pfaffelhuber:mrca}, where the \textit{MRCA}-process in the infinite-population limit is identified as a Poisson-process of intensity $1$, which is the limit of the geometric jump process as $n\rightarrow \infty$ with time sped up by $\frac{n^2}{2}$. Also by Lemma \ref{lemma:mrca1}, the number of steps needed to observe any number $r\in\mathbb{N}$ of root jumps follows a negative binomial distribution $\textit{NB}(r,\frac{2}{n^2})$.\\ The discrete structure of the $\textit{EMG}^\flat$ also allows us to derive properties of the \textit{MRCA}-process during ongoing fixations in the underlying Moran process.\\ \vbox{ \begin{definition} Suppose a member $\tilde{x}$ in a neutral Moran process was generated as the result of some duplication at time $i^*\gg 0$, and we observe, by chance, the fixation of descendants of $\tilde{x}$ in the population at time $i^{\textit{fix}}\gg 0$.\\ \begin{itemize} \item $i^{\textit{fix}}$ is called \textit{fixation time} of the individual $\tilde{x}$ \item $i^*$ is called \textit{birth time} of $\tilde{x}$ \end{itemize} \end{definition} } \begin{lemma}\label{lemma:fixjumps} In a Moran Population of size $n\geq 2$, we expect to observe $2-\frac{2}{n}$ \textit{MRCA}-jumps between (and including) $i^*$ and $i^{\textit{fix}}$. \end{lemma} \begin{proof} By our assumptions, we know that one \textit{MRCA}-jump necessarily happens at the transition of $T_{i^{\textit{fix}}-1}$ to $T_{i^{\textit{fix}}}$. We claim that we expect another one during the remainder of the fixation time.\\ Let $l=i^{\textit{fix}}-1-i^*$. We know $l\geq n-2$, since the minimal number of steps necessary to fix the descendants of $\tilde{x}$ is $n-1$. The sequence of genealogies $(T_{i^*},\dots,T_{i^{\textit{fix}}-1})$ in reverse order is a path $y=(T_0',\dots,T_l')$ of the $\textit{EMG}^\flat$, where $T_{0}'=T_{i^{\textit{fix}}-1},\dots,T_l'=T_{i^*}$.\\ The set of $\textit{EMG}^\flat$-time steps $\{1,\dots,l\}$ contains a subset $I=\{i_1,\dots,i_{n-1}\}$, $i_l\leq i_{l+1}$, where $i\in I$ if and only if $x\in T_l'$ holds for the individual $x$ regrafted at time $i$; i.e., $x$ is also present in the population at the time $l$, which represents the birth time of $\tilde{x}$ in the $\textit{EMG}^\flat$. $I$ thus consists of exactly the times where individuals of the population at the birth time of $\tilde{x}$ are revived. In particular, $i_1=0$ and $i_{n-1}=l$. For $i\in I$, let $S_i:=\{x \in T'_i:x\in T'_l\}$ denote the set of individuals that will be members of the population at the birth time of $\tilde{x}$. \\ Starting from $T_{1}'$, a root jump can only occur in some step $i$ if $i\in I$. For any $i_j\in I$, we know that regrafting must take place in some layer $k\leq j+1$. We therefore consider the sequence $$\hat{T}^{(1)} = (T_l')_{S_{i_1}},\dots,\hat{T}^{(n-2)}=(T_l')_{S_{i_{n-2}}},\hat{T}^{(n-1)}=T_l'$$ of $S_i$-induced subtrees of $T_l'$ for $i\in I$. Since $T_{l}'$ is a Yule tree, by Lemma~\ref{lemma:pwr} we may assume that each $\hat{T}^{(j)}$, $j=2,\dots,n-1$ is obtained from a random grafting operation~\ref{proc:rg} performed on $\hat{T}^{(j-1)}$. The probability of a root jump in step $i_j$ is therefore the probability of regrafting at the imaginary branch of $\hat{T}^{(j)}$, which equals $\frac{2}{j(j+1)}$.\\ The total expected number of root jumps along the $\textit{EMG}^\flat$-path $y$ is then $$\sum_{k=2}^{n-1}\frac{2}{k(k+1)}=\frac{n-2}{n}.$$ This expression equals $1-\frac{2}{n}$. Adding the root jump that necessarily occurs in step $1$, we end up with an expectation of $2-\frac{2}{n}$. \end{proof} \begin{figure} \includegraphics[scale=.25]{emg_mrca} \includegraphics[scale=.25]{emg2ajump} \caption{\textit{MRCA} jumps in the \textit{EMG} and $\textit{EMG}^\flat$ (See also Figures~\ref{fig:emg2step}, \ref{fig:emgb}).} \label{fig:jumps} \end{figure} Considering the infinite-population limit, we conclude that between birth and fixation time of an individual, there are $2$ expected \textit{MRCA} jumps in total. It is noteworthy that in the backward view, we do not need to condition the process on fixation of the allele $\tilde{x}$, since every root jump necessarily coincides with a fixation. In the limiting process, one possible solution to this problem is to consider a Wright-Fisher diffusion conditioned on not hitting $0$, which is achieved by introducing an artificial drift term (see \cite{delmas:families}).\\ By similar arguments, we may calculate the exact distribution of root jumps during a neutral fixation for any $n$, and show that these distributions converge as $n\rightarrow \infty$. For $n\geq 2$, let $\Pr_n(k)$ denote the probability of observing $k$ root jumps during a neutral fixation in an $\textit{EMG}$ of size $n$, and $\Pr_\infty(k)$ the same probability in the infinite-population limit. $\Pr_n(k)$ can be written as follows: $${\Pr}_n(k):=\sum_{2\leq i_1,\dots,i_{k-1}\leq n-1}\Pi_1^k\frac{2}{i_k(i_k+1)}\Pi_{j\neq i_1,\dots,i_{k-1}}\left(1-\frac{2}{j(j+1)}\right)$$ This is obtained by multiplying the probabilities of regrafting at the imaginary branches of $\hat{T}^{(i_1)},\dots,\hat{T}^{(i_k-1)}$ (in the sense of the notation used in Lemma~\ref{lemma:fixjumps}) and not regrafting at the imaginary branches of all other $\hat{T}^{(j)}$, summed up over all possible choices of $i_1,\dots,i_{k-1}$. For $k=1$, in which case the imaginary branch is never chosen for regrafting, we have simply: \begin{equation}\label{eq:p1}{\Pr}_n(1)=\Pi_{j=2}^{n-1}\left(1-\frac{2}{j(j+1)}\right)=\Pi_{j=2}^{n-1}\frac{(j+2)(j-1)}{j(j+1)}=\frac{n+1}{3(n-1)}\end{equation} By reordering of the factors, we obtain the following expressions for $k=2,3,\dots$: \begin{align}\label{eq:jumpdist} {\Pr}_n(2)&=\Pi_{j=2}^{n-1}\left(1-\frac{2}{j(j+1)}\right)\left[\sum_{k=2}^{n-1}\frac{2}{k(k+1)-2}\right]\notag\\ {\Pr}_n(3)&=\Pi_{j=2}^{n-1}\left(1-\frac{2}{j(j+1)}\right)\left[\sum_{k=2}^{n-2}\frac{2}{k(k+1)-2}\cdot\left(\sum_{l=k+1}^{n-1}\frac{2}{l(l+1)-2}\right)\right]\notag\\ \dots & \notag\\ \end{align} For small $k$, it is possible to also obtain closed-form expressions for $\Pr_n(k)$ similar to equation~(\ref{eq:p1}) using computational algebra. For $n=2$, $\Pr_n(1)=1$, and as $n\rightarrow \infty$, $\Pr_n(1)$ converges to $\frac{1}{3}=:\Pr_\infty(1)$, decreasing monotonously. Note that this can be interpreted as an analogon to a result in \cite{pfaffelhuber:mrca} about the infinite-population limit. In the terminology of this work, the value $\frac{1}{3}$ corresponds to the probability that the "next fixation curve has not yet started" at the time $i^*$.\\ The other probabilities in the infinite-population limit can be calculated numerically by evaluating the infinite-sum expressions on the right-hand sides of~\eqref{eq:jumpdist}. By continuity, the probabilities $\sum_{k=1}^{\infty}\Pr_\infty(k)$ sum up to $1$. The largest contribution comes from $\Pr_\infty(2)=\frac{11}{27}=\frac{11}{9}\cdot\frac{1}{3}$. As a side note, since $\Pr_n(2)$ increases monotonously with $n$, we can calculate that for $n\leq 9$, the distribution is dominated by $\Pr_n(1)$, whereas for $n\geq 10$, the probability $\Pr_n(2)$ provides the largest value. Figure~\ref{fig:jumpdist} outlines some of the distributions for different population sizes.\\ \begin{figure} \includegraphics[scale=.625]{rootjumps} \caption{The distributions of $P_n(k)$, $k=1,\dots,8$, $n=2$ (blue), $5$ (turquoise), $10$ (green), $25$ (red) and $\infty$ (black).} \label{fig:jumpdist} \end{figure} Another implication of the $\textit{EMG}^\flat$ is that coalescent events are "visible" in the genealogy for a certain average number of steps, such that we can determine their age structure. In general, the time until the internal node labeled $k$ is moved down by one layer is geometrically distributed with parameter $\frac{k(k+1)}{n^2}$, because $\frac{k(k+1)}{2}$ branches exist above this internal node. In the case of the root node, this expectation is $\frac{2}{n^2}$, as stated before.\\ The time until the current root node of $T_i$ vanishes under the $\textit{EMG}^\flat$ is therefore distributed as the sum of $n-1$ independent random variables $\rho_1,\dots,\rho_{n-1}$, where $\rho_k$ is geometrically distributed with parameter $\frac{k(k+1)}{n^2}$. Its expectation is the sum of the expectations of the $\rho_k$, i.e. $\sum_{k=1}^{n-1}\frac{n^2}{k(k+1)}=n^2\left(1-\frac{1}{n}\right)$. In the large-population limit, this corresponds to a rate of $2$.\\ The expected time until an internal node of $T_i$ becomes invisible, averaged over all nodes, is \begin{eqnarray} \frac{1}{n-1}\sum_{k=1}^n n^2 \sum_{j=k}^{n-1} \frac{1}{j(j+1)}&=&\frac{n^2}{n-1}\sum_{k=1}^{n-1}\left( \frac{1}{k}-\frac{1}{n-1}\right)\nonumber\\ &=&\frac{n^2}{n-1}a_{n-1}-\frac{n^2}{(n-1)^2}\nonumber\\ &\approx & n\log(n)\nonumber \end{eqnarray} Rescaling time, we obtain $\frac{2\log(n)}{n}\rightarrow 0$ as $n\rightarrow\infty$. We conclude that in a large evolving tree, most internal nodes (which correspond to coalescent events) only exist for a short time until they are removed by the dynamics. \section{Discussion} The \textit{Evolving Moran Genealogy} and time-reversed version reveal interesting properties of the genealogies generated by the neutral Moran process. We have used them to re-formulate classic diffusion-limit results on the \textit{MRCA} process, but also obtain exact expressions for the finite-population setting. Additionally, the distribution of \textit{MRCA} jumps during fixation periods becomes tractable in the $\textit{EMG}^\flat$, for both finite and limiting case. Of practical interest may be the fact that the $\textit{EMG}^\flat$ reduces the number of operations from $2$ to $1$ in contrast to the underlying Moran Model, if we think of the regrafting operation as one single operation.\\ It might prove insightful to extend this to other Moran-type population models, such as ones involving alleles with a selective advantage. In such models, the associated tree-valued processes need to be described and may not admit such simple definitions as those we find in the neutral case. Still, such constructions might enable a similar kind of analysis that we have performed here. In many settings, tree-valued dual processes have been described for the infinite-population limits, e.g. the ancestral selection graph \cite{krone:asg}, which involves both mutation and selection between and among types, and admits a graphical representation similar to the lookdown-construction under neutrality \cite{lenz:lookdownasg}, making many implicit features of the model accessible (see e.g. \cite{baake:mutseleceq}). Tree-valued constructions of finite time and population size may help here to bridge the gap between finite and infinite population case likewise. \section*{Acknowledgments} We would like to thank Anton Wakolbinger and Peter Pfaffelhuber for helpful suggestions, Jan Rolfes and Anna-Lena Tychsen for interesting discussions and two anonymous reviewers for their comments.\\ This work was financially supported by the German Research Foundation (DFG-SPP1590).\\
\section{Introduction} As the amount of cyber data continues to grow, cyber network defenders are faced with increasing amounts of data they must analyze to ensure the security of their networks. In addition, new types of attacks are constantly being created and executed globally. Current rules-based approaches are effective at characterizing and flagging known attacks, but they typically fail when presented with a new attack or new types of data. By comparison, unsupervised machine learning offers distinct advantages by not requiring labeled data to learn from large amounts of network traffic. In this paper, we present a natural language-based technique (suffix trees) as applied to cyber anomaly detection. We illustrate one methodology to generate a language using cyber data features, and our experimental results illustrate positive preliminary results in applying this technique to flow-type data. As an underlying assumption to this work, we make the claim that malicious cyber actors leave observables in the data as they execute their attacks. This work seeks to identify those artifacts and exploit them to identify a wide range of cyber attacks without the need for labeled ground-truth data. \section{Previous Work} Previous work has investigated network data for pattern-of-life and anomaly detection that informs the approaches taken in this paper. In terms of pattern-of-life, work focuses on identifying and classifying users within a network \cite{gu2015novel, sharafuddin2010know, verde2014no,abt2014small}. Clustering for anomaly detection \cite{leung2005unsupervised, portnoy2001intrusion, munz2007traffic} is a common technique for network data due to the fact that most network datasets are unlabeled and contain no ground truth. The focus of these works is largely centered around intrusion detection and make the assumption that intrusions should be anomalous relative to the network as a whole. Likewise, there exists previous work around the probabilistic suffix tree (PST) and using it to model and predict protein families \cite{bejerano2001variations} as well as determine anomalous user behavior from event logs \cite{liu2013incorporating}. \section{Data Sources and Experimental Configuration} Our data for this effort consists of network traffic data collected in a traditional compute environment. Specifically, we utilize the University of New Brunswick Information Security Centre of Excellence (ISCX) Intrusion Detection Evaluation DataSet \cite{ids2012}. The reason we selected this dataset is that it contains labeled data for known attacks, and this permits us to produce ROC curves and calculate AUC in order to evaluate the effectiveness of the technique. We concentrate on Bro netflow data. By default, Bro creates separate log files for different actions. For example, the DNS log file contains DNS resolution requests and associated metadata while the HTTP log file contains, among other things, GET and POST requests (with the associated URLs) for activity over HTTP and HTTPS ports. The Bro CONN (connection) log contains high-level metadata for other log types, including: IP addresses, ports used, bytes transferred, packets transferred, duration, TCP flags, and protocol. Bro netflow is aggregated to the session level and is bidirectional, enabling it to represent many PCAP frames in a single row of information. The relationship between PCAP and flow-type data is illustrated in Figure \ref{fig1}. The ISCX dataset contains 2,028,053 labeled Netflow records, with 96.6\% of them labeled normal and the remaining 3.4\% labeled as attack. The volume of traffic is shown Figure \ref{fig2}. Statistical analysis of real network traffic is used to create agent-based background traffic in a testbed environment, and the attacks are real and planned by a white hat team based on the architecture of the testbed environment. \begin{figure}[h!] \centering \includegraphics[width=.95\columnwidth]{Picture1.png} \caption{Flow-type data (top) compared with PCAP data (bottom). Flow data is aggregated and contains information across multiple PCAP frames, and raw PCAP data provides access to the application payload that may not be represented in aggregated flow data.} \label{fig1} \end{figure} \begin{figure}[h!] \centering \includegraphics[width=.95\columnwidth]{Picture2.png} \caption{Volume of attack (top) and normal (bottom) traffic in the ISCX dataset} \label{fig2} \end{figure} Our analytics run on a cloud compute environment using Cloudera CDH v5.11.0 and a heavily modified Spark v.2.1.0.cloudera1. The physical machine contains 6.15TB of addressable RAM with 420 VCores. Actual physical servers include: 8x24 cores, 22x40 cores, 1x12 core, and 1x4 cores. HDFS is currently configured for a total capacity of 260.4TiB. Our analytics utilize Spark MLLib heavily, and input/output is managed via Hive tables in HDFS. It is important to note that this is a research cloud and is not a production environment. \section{Creating Sequences of Cyber Data} Before we can apply the analytic to the cyber data, we must transform it into a sequence of activity (i.e., create the communication language). Figure \ref{fig3} illustrates this process in detail. In general, some feature engineering is performed \textit{a priori} to sequence creation. Various combinations of protocol, port, bytes, packets, and other features can be encoded into discrete tokens, and sequences of these tokens effectively compress the communication between two networked computers. For this work, we focus on proto-bytes (a protocol identifier with the sum of the bytes transferred) and proto-density (a protocol identifier with the sum of bytes/packet transferred). In order to keep the vocabulary at a manageable size, we also bin the quantitative features in some way. One method that has shown promise is to take the floor of the log2 feature value. This allows us to keep some sense of magnitude (e.g., bytes, KB, MB, GB) while reducing the number of tokens produced. \begin{figure}[h!] \centering \includegraphics[width=.95\columnwidth]{Picture3.png} \caption{Construction of cyber language sequences from flow data} \label{fig3} \end{figure} Another issue to consider when creating sequences of cyber data is the sequence length. Sequence length directly relates to time and how long the communication remains open. Various ways to sessionize exist, including by hour, day, week, and after 30 minutes of no activity between two IP addresses. For this work, we construct sequences that terminate after an hour. This has the added benefit of keeping most sequences to a relatively similar length, so there is not the issue of normalizing all sequences to account for widely varying lengths. These sequences are created using a parallelized Spark-based approach that can construct multiple types of sequences relatively quickly. \section{Modeling Cyber Data using a Probabilistic Suffix Tree} Creating the PST model is relatively straightforward. The cyber language sequences are fed into a slightly modified PST code model that distributes the learning across a Spark cluster. Typical starting hyperparemeter values set the depth of the tree to 14, the minimum probability to 0.0001, the probability threshold (specifying the minimum probability necessary for inclusion of the suffix in the tree) to 0.0005, and the two smoothing parameters at $\tau=10$ and $\epsilon=0.0$. After creating the sequences and the PST model, we then score each sequence using the model. The overall process is shown in Figure \ref{fig4}. Each sequence receives a likelihood score (a probability between 0 and 1), and we flag for investigation those sequences that receive a non-zero likelihood score below a set limit. These sequences represent those less likely to exist in the data (i.e., anomalous sequences). \begin{figure}[h!] \centering \includegraphics[width=.95\columnwidth]{Picture4.png} \caption{Analytic flow for creating PST models from cyber network data} \label{fig4} \end{figure} To build intuition, we present Figure \ref{fig5}. In this figure, the application of PST modeling to English words is on the left while the cyber application is on the right. In the traditional application, we seek to quantify a word’s conformity to traditional spelling patterns. Notice that words like “actions” and “stations” are more likely (therefore further to the right on the histogram) while words like “chutzpah” and “syzygy” are less likely (further to the left). In our application to cyber data via construction of a cyber language, we seek to add interpretability to findings using similar intuition. Our application necessitates an additional step to transform the data and sequence the tokens. Instead of analyzing English spelling patterns, we are quantifying spelling patterns of our tokenized sequences representing machine-to-machine communication. The underlying assumption is that sequences of less-likely spellings are anomalous to the network environment where they are observed, and these events warrant increased scrutiny by a cyber expert. \begin{figure}[h!] \centering \includegraphics[width=.95\columnwidth]{Picture5.png} \caption{Application of PST to natural language (left) and cyber data (right)} \label{fig5} \end{figure} \section{Experimental Results} This section presents experimental results of the PST approach to cyber anomaly detection on the ISCX dataset. Figure \ref{fig6} shows the results for two different types of tokens and their respective ROC curves. We experimented with two main types of tokenization including proto-density binned in buckets of 10 (left) and proto-bytes binned using log2 (right). For the ISCX dataset, using proto-bytes as a feature significantly outperformed using proto-density. \begin{figure}[h!] \centering \includegraphics[width=.95\columnwidth]{Picture6.png} \caption{The effect of tokenization on the performance of the PST analytic} \label{fig6} \end{figure} Another factor in PST performance is the tuning of the analytic hyperparameters. As implemented, the PST has several hyperparameters. The tree depth specifies the maximum depth of the model generated while the probability threshold value is used to determine if a sequence is significant and is a candidate to add to the PST. Raising the probability threshold makes the PST more restrictive. The other parameters (tau, epsilon, and probability minimum) are essentially used together to remove useless nodes from the PST model and as a smoothing factor. Figure \ref{fig7} illustrates the effect of tuning these PST hyperparameters to a specific dataset. \begin{figure}[h!] \centering \includegraphics[width=.95\columnwidth]{Picture7.png} \caption{The effect of tuning PST hyperparameters to increase the AUC} \label{fig7} \end{figure} By tuning the PST hyperparameters, we are able to increase the AUC from 0.545 (shown on the right side of Figure \ref{fig6}) to 0.748. It should also be noted that the shape of the ROC curve is of interest from the view of a cyber analyst. By noting the sharp rise in the ROC curve at the beginning, we observe that the results presented to a cyber analyst (assuming this same ordering) are less likely to be false positives (i.e., less likely to degrade trust in the system). In an operational environment, we would typically not have ground truth labels for our data. It is important to build trust in the system by presenting minimal false positives to the cyber security analyst. \section{Conclusions and Future Work} This work demonstrates that there is a method to view and interpret cyber communications as a language and that applying language-based analytic techniques to this new synthetic language has potential. We have shown that there is value in viewing network traffic as a language, and that PSTs can be used to characterize that language. By selectively engineering the input features and tuning the PST hyperparameters, we can substantially increase the AUC while maintaining a favorable ROC curve shape. Future work in this area includes how to best retain the labels when aggregating flows into sessions. While we have characterized on attack vs. non-attack (normal), there are various types of attacks that exist and generating more nuanced labels than these binary indicators would be useful. Additional research and experimentation should be devoted to the correct evaluation criteria for results. Do cyber analysts care about the overall AUC or, perhaps more importantly, the true positive rate for the first $n$ predicted anomalies/attacks? In addition, experiments that evaluate how generalizable the results from applying this methodology on the ISCX data are necessary. One method to do this is to use additional labeled datasets from ISCX and then generate model-fit comparisons on labeled and unlabeled data to show correlation. \bibliographystyle{unsrt}
\section{Introduction} Breast cancer is one of the top causes of cancer death in women. In 2017, it is estimated that there are 252,710 new diagnoses of invasive breast cancer among women in the United States, and approximately 40,610 women are expected to die from the disease \cite{desantis2017breast}. The detection of breast cancer in its early stage by mammography allows patients to get better treatments, and thus can effectively lower the mortality rate. Currently, mammogram screening is still based on experts’ reading, but this process is laborious and prone to error. Computer-aided diagnosis (CADx) system is a potential solution to facilitate mammogram screening, and the research on automatic (or semi-automatic) mammogram analysis has been a focus in medical vision field. Given the fact that a mass only occupies a small region (typically ~2\%) of a whole mammogram (i.e. the “needle in a haystack” problem \cite{lotter2017multi}), it is very hard to identify a mass from the whole image without introducing a large number of false positives. Therefore, traditionally, both hand-crafted feature based methods \cite{buciu2011directional,pratiwi2015mammograms} and deep learning models \cite{geras2017high,kooi2017large} require manually extracted regions of interest (ROIs), which, however, affects their usefulness in clinical practice. Recently, Dhungel et al. \cite{dhungel2017deep} proposed a sophisticated framework integrating mass detection, segmentation and classification modules to do whole-image classification, which achieved state-of-the-art performance with minimal manual intervention (manually rejecting false positives after detection). Besides, Lotter et al. \cite{lotter2017multi} proposed a 2-stage curriculum learning method to cope with the classification of whole mammograms, and Zhu et al. \cite{zhu2017deep} developed a sparse multi-instance learning (MIL) scheme to facilitate the end-to-end training of convolution neural networks (CNNs) for whole-image classification. Nevertheless, these methods either require manual intervention and multi-stage training, or only focus on the classification problem, while the accurate location and size of masses also play a critical role in a CADx system. In this paper, we propose a CNN-based model with Hybrid Deep Supervision (Hybrid DS, HDS) to perform whole-mammogram classification and mass segmentation simultaneously. This model is based on a very deep U-Net \cite{ronneberger2015u} with residual connections \cite{he2016deep} (U-ResNet) which has 45 convolutional layers in the main stream. To facilitate the multi-task training of the deep network and boost its performance, we extend deep supervision (DS) \cite{lee2015deeply} to Hybrid DS by introducing multi-task supervision into each auxiliary classifier in DS, and apply this scheme to the U-ResNet model. To evaluate the proposed method, we performed extensive experiments on a publicly available full-field digital mammographic (FFDM) dataset, i.e. INbreast \cite{moreira2012inbreast}. The results show that our model achieves state-of-the-art performance in both classification and segmentation metrics, and ablation studies are performed to demonstrate the efficacy of HDS scheme. \section{Method} \begin{figure} \includegraphics[width=\textwidth]{archi.pdf} % \caption{Architecture of the U-ResNet model with Hybrid DS. Best viewed in color.} \label{fig_archi} \end{figure} \subsection{Motivation} Due to the very small size of masses, directly training deep CNN models for whole mammogram classification can lead to a severe overfitting problem, where the powerful model may easily memorize the patterns presented in the background area rather than learn the feature of masses, leading to poor generalization performance. To deal with this problem, we propose to employ both image-wise and pixel-wise labels to supervise the training process. The underlying assumption for this multi-task scheme is two-fold. First, since classification (whether there exist any masses in a mammogram) and segmentation (whether each pixel belongs to a mass) are highly correlated tasks, the features learned in one task should also be useful in the other; second, multi-task learning itself can serve as a regularization method as it prevents the training process from biasing towards either task. Therefore, we propose a multi-task CNN model trained with Hybrid DS to attack the whole-mammogram classification and segmentation problems. \subsection{Hybrid Deep Supervision} Similar to DS, Hybrid DS directly supervises intermediate layers via auxiliary classifiers to force the model to learn more discriminative features in early layers. Meanwhile, HDS extends DS by introducing multi-task classifiers into each supervision level. Formally, the optimization objective of HDS is defined as: \begin{equation}\label{hds1} \begin{aligned} \mathcal{L}(\bm X;\bm W,\widehat{\bm w}) = &\mathcal{L}^{(\rm{seg})}(\bm X;\bm W,\widehat{\bm w}^{(\rm{seg})}) + \alpha\mathcal{L}^{(\rm{cls})}(\bm X;\bm W,\widehat{\bm w}^{(\rm{cls})}) \\ &+ \lambda(\|\bm W\|_2 + \|\widehat{\bm w}^{(\rm{seg})}\|_2 + \|\widehat{\bm w}^{(\rm{cls})}\|_2) \end{aligned} \end{equation} where $\bm X$ denotes the training dataset, $\bm W$ is the trainable parameters of the main stream, i.e. the U-ResNet model without multi-task supervision pathways, $\widehat{\bm w}^{(\rm{seg})}$ and $\widehat{\bm w}^{(\rm{cls})}$ respectively denote the parameters of the segmentation and classification parts of the multi-task paths, and $\alpha$ is a constant that controls the relative importance of the classification loss. The third term to the right is a regularization term weighted by a hyper-parameter $\lambda$, and $\|\cdot\|_2$ denotes L2-norm. The segmentation loss $\mathcal{L}^{(\rm{seg})}$ and classification loss $\mathcal{L}^{(\rm{cls})}$ are defined as follow: \begin{align}\label{hds2} \mathcal{L}^{(\rm{seg})}(\bm X;\bm W,\widehat{\bm w}^{(\rm{seg})}) &= \sum_{d\in \mathcal{D}}\eta_d\mathcal{J}_d^{\rm{(seg)}}(\bm X; \bm W_d, \widehat{\bm w}^{\rm{(seg)}}_d) \\ \mathcal{L}^{(\rm{cls})}(\bm X;\bm W,\widehat{\bm w}^{(\rm{cls})}) &= \sum_{d\in \mathcal{D}}\eta_d\mathcal{J}_d^{\rm{(cls)}}(\bm X; \bm W_d, \widehat{\bm w}^{\rm{(cls)}}_d) \end{align} where $\bm W_d$ denotes the parameter in the first $d$ layers of the main stream, $\widehat{\bm w}^{\rm{(seg)}}_d$ and $\widehat{\bm w}^{\rm{(cls)}}_d$ are respectively the weights in the segmentation and the classification parts of the multi-task path associated with the $d$-th layer, $\eta_d$ is the weights of the corresponding loss level, and $\mathcal{D}$ is a set that contains the indices of the layers directly connected to multi-task supervision paths. $\mathcal{J}_d^{\rm{(seg)}}$ is a segmentation cross-entropy cost function that returns the average loss across all pixel locations. $\mathcal{J}_d^{\rm{(cls)}}$ is basically a cross-entropy cost function, which is made compatible with MIL scheme, and its definition will be detailed in the following section. \subsection{Deep Multi-Instance Learning} Conventionally, CNN models used in classification tasks includes at least 1 fully connected (FC) layers, which can only take fixed-size inputs. However, segmentation models, e.g. fully convolutional networks (FCNs), are usually trained on cropped image patches and tested on whole images, where the input size may vary. To integrate the two tasks into one unified framework, we convert the classification part of the model into a FCN manner. Thus, the classification part may take inputs of different sizes like a segmentation model, but its output also turns into a 2D probabilistic map, no longer a single value. If we map the pixels in such a 2D map back to nonoverlapping patches in the input image, the whole input image can then be regarded as a bag of patches (instances), thus the mammogram classification can be treated as a standard MIL problem. In this case, denoting the pixel values in a 2D probabilistic map as $r_{i,j}$, the mass probability of the input image $\bm I$ is then $p(y=1|\bm I) = \max_{i,j}\{r_{i,j}\}$. Following the practice of Zhu et al. in \cite{zhu2017deep}, we define the classification cost for an input image $\bm I$ as below: \begin{equation}\label{eq_mil} \mathcal{J}^{\rm {(cls)}}(\bm I,y_I;\bm W, \bm w^{\rm{(cls)}}) = -\log p(y=y_I|\bm I) + \mu\sum_{i,j}r_{i,j} \end{equation} where $y_I$ is the true label of image $\bm I$, and $r_{i,j}$ is the pixel value in the 2D probabilistic map. Since masses are sparse in mammograms, the summation of $r_{i,j}$ should be small. Therefore, a sparsity term (the second term to the right) is added to the cost function, which is weighted by $\mu$. \subsection{Network Architecture} The architecture of the proposed neural network model is illustrated in Fig. \ref{fig_archi}. The model is basically a deep U-ResNet with 45 $3\times3$ convolutional layers (1 convolution and 22 residual blocks), and multi-task supervision pathways are inserted into each scale level for Hybrid DS. We use max pooling in downsampling modules (except for the last downsampling layer in the classification part of each multi-task path, which employs average pooling), and bi-linearly upsample feature maps in upsampling layers. For those transition modules (i.e. downsample, upsample and concatenation), if the input and output channel dimensions are different, $1\times1$ convolutions are inserted before the operation to change the channel dimension. All max pooling layers have a stride of 2, and the stride of average pooling layers ranges from $2^0$ to $2^5$ to ensure a total downsampling factor of $2^7$ for the output of each classification path (so the size of the output probabilistic map is $4\times3$ in training and $8\times4$ in testing). Similarly, All upsampling layers except for the ones in multi-task paths have a stride of 2, and those in multi-task paths range from $2^0$ to $2^5$ to ensure the output mask have the same size as the input image. Besides, Dropout \cite{srivastava2014dropout} layers of rate 0.2 (for residual blocks with less than 128 channels) or 0.5 (for others) are inserted into each residual block. \section{Experiments and Results} \subsubsection{Dataset} The proposed method was evaluated on a publicly available FFDM dataset, i.e. INbreast \cite{moreira2012inbreast}. Among the 410 mammograms in INbreast dataset, 107 contain one or more masses, and totally contain 116 benign or malignant masses. In pre-processing, we removed the left or right blank regions by thresholding, resized the mammograms to $1024\times512$, and then normalized each image to zero-mean and unit-std according to the statistics of training sets. During training, the whole image was randomly flipped vertically or horizontally, and patches of size $512\times384$ were randomly sampled from it with 50\% chance centered on a positive (mass) pixel. The classification label of a cropped patch was set to 1 if the patch contained any pixel from masses, and 0 otherwise. In our experiment, the whole dataset was uniformly divided into 5 folds (82 images per fold), and we used three of them for training, one for validation and one for testing. We first performed ablation study on one data split to demonstrate the efficacy of the proposed method, and then ran a 5-fold cross validation for a fairer comparison with existing methods. \subsubsection{Implementation Details} The proposed method was implemented with PyTorch v0.4.0 on a PC with one NVIDIA Titan Xp GPU. Stochastic gradient descent (SGD) method with a momentum of 0.9 was used to optimize the model, with an initial learning rate of 0.01 and decayed by 0.3 after 1000, 1800, 2400 and 2410 epochs. In all experiments, the model was trained for 2800 epochs, which took about 12.5 hours and was long enough for each configuration to converge. The model parameters were initialized by Kaiming method \cite{he2015delving}. Other hyperparameters were set as follows: classification loss weight $\alpha=0.03$ (such that the segmentation and classification losses of each mini-batch were comparable in magnitude), weight decay $\lambda=0.0005$, sparsity weight $\mu=10^{-6}$, and the weights of different supervision levels $(\eta_0,\eta_1,\eta_2,\eta_3,\eta_4,\eta_5)=(1.0, 1.5, 2.0, 2.5, 3.0, 3.5)$, where $\eta_1$ to $\eta_5$ were gradually decayed to very small values (i.e. 0.005$\eta_i$) during training. The losses stemmed from inner layers of the U-Net were initially weighted higher to force the these layers to learn meaningful features, otherwise they tended to be ignored due to the difficulty in learning from low-resolution feature maps. \subsubsection{Metrics} We employed dice similarity coefficient (DSC), sensitivity (SE) and false positives per image (FPI) to evaluate the segmentation results. For classification, accuracy (ACC), area under ROC curve (AUC), $F_1$ score, precision (Prec) and recall (Recl) were reported. \begin{table}[] \centering \caption{Ablation Study} \label{tab_ablation} \begin{threeparttable} \setlength{\tabcolsep}{2mm}{ \begin{tabular}{lllllllll} \hline \multirow{2}{*}{Model} & \multicolumn{3}{c|}{Segmentation} & \multicolumn{5}{c}{Classification} \\ \cline{2-9} & \multicolumn{1}{c}{DSC} & \multicolumn{1}{c}{SE} & \multicolumn{1}{c|}{FPI} & \multicolumn{1}{c}{ACC} & \multicolumn{1}{c}{AUC} & \multicolumn{1}{c}{$F_1$} & \multicolumn{1}{c}{Recl} & \multicolumn{1}{c}{Prec} \\ \hline Multi-task Only & 0.787 & 0.882 &0.293 & 0.829 & 0.866 & 0.682 & 0.714 & 0.652 \\ Cls + DS & N/A & N/A &N/A & 0.878 & 0.853 & 0.722 & 0.619 & 0.867 \\ Seg + DS$^*$ & 0.802 & \textbf{0.910} &0.183 & 0.842 & \textbf{0.890} & 0.723 & \textbf{0.810} & 0.654 \\ Hybird DS & \textbf{0.848} & 0.907 &0.110 & \textbf{0.915} & 0.887 & \textbf{0.821} & 0.762 & \textbf{0.889} \\ \hline \end{tabular}} \begin{tablenotes} \item $^*$Classification results were retrieved from segmentation masks by assigning the largest activation across the output probabilistic map to the whole image. \end{tablenotes} \end{threeparttable} \end{table} \subsubsection{Ablation Study} To investigate the efficacy of the proposed Hybrid DS scheme, a series of experiments were conducted on one data split. From Table \ref{tab_ablation}, it can be observed that the Hybrid DS model achieves the best performance on several important metrics (e.g. DSC, FPI, ACC, $F_1$, etc.), and also has high scores on others. HDS outperforms the baseline multi-task model by a large margin (0.848 vs 0.787 in DSC, 0.915 vs 0.829 in ACC), indicating that directly supervising intermediate layers is necessary for training such a deep model. Thanks to the sparse MIL \cite{zhu2017deep} and DS schemes, the Cls+DS model performed well in classification, having an accuracy of 0.878. Meanwhile, HDS achieves even higher classification performance (e.g. ACC: 0.915) than Cls+DS, which evidences the benefit of employing extra pixel-wise supervision. Compared to Seg+DS, HDS achieves better DSC (0.848), accuracy (0.915), $F_1$ score (0.821) and precision (0.889), which we attribute to the extra image-wise supervision. Since image-wise supervision can force the network to look wider and to learn features based on the whole image (or at least a larger area), the network becomes less sensitive to local patterns that mimic masses and more robust in rejecting false positives, as has been validated by the much higher precision of HDS (0.889) than Seg+DS (0.654). Altogether, these experiments suggest that the proposed Hybrid DS scheme is a promising approach to improve deep model's performance on the mammogram analysis problem. \begin{table}[b] \centering \caption{Comparison with State-of-the-art Methods} \label{tab_comparison} \begin{threeparttable} \begin{tabular}{lllllllll} \hline \multirow{2}{*}{Model} & \multicolumn{3}{c|}{Segmentation} & \multicolumn{5}{c}{Classification} \\ \cline{2-9} & \multicolumn{1}{c}{DSC} & \multicolumn{1}{c}{SE} & \multicolumn{1}{c|}{FPI} & \multicolumn{1}{c}{ACC} & \multicolumn{1}{c}{AUC} & \multicolumn{1}{c}{$F_1$} & \multicolumn{1}{c}{Recl} & \multicolumn{1}{c}{Prec} \\ \hline D. \cite{dhungel2017deep} & 0.85$^*$ & N/A & 1.00$^\#$ & 0.91$\pm$0.02 & 0.76$\pm$0.23 & N/A & N/A & N/A \\ Z. \cite{zhu2017deep} & N/A & N/A & N/A & 0.90$\pm$0.02 & 0.89$\pm$0.04 & N/A & N/A & N/A \\ Ours & 0.85$\pm$0.01 & 0.88$\pm$0.02 & 0.08$\pm$0.02 & 0.89$\pm$0.02 & 0.85$\pm$0.02 & 0.77$\pm$0.04 & 0.69$\pm$0.04 & 0.87$\pm$0.06 \\ \hline \end{tabular} \begin{tablenotes} \item $^*$Calculated on correctly detected masses. \item $^\#$These detection false positives were manually rejected before further processing. \end{tablenotes} \end{threeparttable} \end{table} \subsubsection{Comparison with Existing Methods} To compare the proposed model with other mammogram analysis methods, we used 5-fold cross validation to evaluate it on the whole INbreast dataset. As shown in Table \ref{tab_comparison}, our model matches the current state-of-the-art performance on both mass segmentation and classification tasks, achieving a high average segmentation DSC of 0.85 and a classification accuracy of 0.89. Besides, our method is fully automatic and easy to deploy, which takes whole mammograms as input and then outputs segmentation masks and image-wise labels simultaneously. In contrast, the method by Dhungel et al. \cite{dhungel2017deep} still requires manual intervention to reject false positives after mass detection, and the method by Zhu et al. \cite{zhu2017deep} can only give a very rough location of identified masses. Qualitative segmentation results of our method on several typical testing images have been illustrated in Fig. \ref{fig_quali}. \newcommand{0.7in}{0.7in} \begin{figure*}[t] \captionsetup[subfigure]{labelformat=empty} \centering \subfloat{\includegraphics[width=0.7in]{quality/20587902}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/20588216}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/22613822}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/53586896}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/22580367}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/22580706}} \subfloat{\includegraphics[width=0.7in]{quality/20587902ol}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/20588216ol}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/22613822ol}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/53586896ol}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/22580367ol}} \hspace{0in} \subfloat{\includegraphics[width=0.7in]{quality/22580706ol}} \caption{Qualitative results. The first row is original mammograms. In the second row, red and green boundaries are ground truth delineation and automatic segmentation results, respectively. The fifth column contains a false negative lesion, and the last column has a false positive lesion. Best viewed in color.} \label{fig_quali} \end{figure*} \section{Conclusion} In this paper, we have developed an end-to-end and unified framework for mammogram classification and segmentation. We seamlessly integrate the two tasks into one model by employing the novel Hybrid DS scheme, which not only inherits the merits of DS but also supports multi-task learning. With such a multi-task learning scheme, pixel-wise labels tell the model where to learn while image-wise labels force the network to make better use of contextual information. We conducted extensive experiments on the publicly available INbreast dataset, and the results show that our method matches the state-of-the-art performance on both segmentation and classification tasks. Ablation study demonstrates that pixel-wise and image-wise supervisions are mutually beneficial, and the proposed Hybrid DS can effectively boost the model's performance on both tasks. Besides, our unified framework is inherently general, which can be easily extended to other medical vision problems. \bibliographystyle{splncs04}
\section{Introduction}\label{introduction} Black holes are among the most captivating aspects of Einstein's Theory of General Relativity (GR) \cite{Einstein:1916vd,Schwarzschild:1916uq,Finkelstein:1958zz,Kerr:1963ud,Misner:1974qy}, and their properties have been studied extensively since the dawn of GR in the early 20th century. Of great interest to physicists and mathematicians alike is the response of black holes to perturbations. Notably, perturbed black holes `ring', emitting gravitational waves at a characteristic set of frequencies known as the quasi-normal mode (QNM) frequencies \cite{1975RSPSA.343..289C,0264-9381-16-12-201,Kokkotas:1999bd,Berti:2009kk,Konoplya:2011qq}. These QNM frequencies are dependent on the background properties of the black hole (e.g. mass or angular momentum), acting like a `fingerprint' for a given black hole. Furthermore, the presence of a cosmological constant, or a modification to the theory of gravity itself, can and will affect the spectrum of frequencies that a black hole will emit gravitational waves at. Thus studying the QNM frequencies of black holes (and other fields propagating on the black hole spacetime) provides a window from which to observe not only the properties of the black hole itself, but also of the wider universe and indeed of the fundamental laws governing gravity \cite{Dreyer:2003bv,Berti:2005ys,Berti:2015itd,2018PhRvD..97d4021T,Berti:2018vdi,Barack:2018yly,Brito:2018rfr}. From an observational point of view, given the dawn of the gravitational wave era of astronomy (with multiple direct observations of gravitational waves from mergers of highly compact objects, i.e. black holes or neutron stars, having now been made by advanced LIGO and VIRGO \cite{2016PhRvL.116f1102A,2016PhRvL.116x1103A,2017PhRvL.118v1101A,Abbott:2017oio,PhysRevLett.119.161101}), determining and detecting the QNM frequencies of the remnant black holes left perturbed after the merger of compact objects is an interesting and important area of study. In this paper, we will study the responses a variety of fields to linear perturbations on a black hole spacetime, and present analytical expressions for the QNM frequencies that each type of field characteristically `rings' at. The black holes we will consider will possess angular momentum and be embedded in a universe with a cosmological constant that can be positive or negative (i.e. the spacetime will be either asymptotically de Sitter or Anti-de Sitter). For the case of a positive cosmological constant, the black holes studied here will represent the kind of astrophysical black holes that we expect to observe in our universe (assuming the $\Lambda$CDM paradigm of cosmology \cite{Akrami:2018vks}). For a negative cosmological constant, on the other hand, the AdS/CFT correspondence provides an interesting motivation to study the QNMs of asymptotically Anti-de Sitter black holes as a method of gaining insight into certain conformal quantum field theories \cite{Maldacena:1997re,Nunez:2003eq,Son:2007vk,Hartnoll:2009sz,Herzog:2009xv}. \textit{Summary}: In section \ref{background}, we will present the background spacetime of the black holes that are to be studied in this work. In section \ref{perturbations}, we will review aspects of black hole perturbation theory before presenting second order Schr{\"o}dinger-style master equations for perturbations of massive scalar (spin $s=0$), massive vector ($s=-1$), and massless tensor ($s=-2$) fields. Some of the master equations presented are known from the literature, with others (to the author's best knowledge) being new results. In section \ref{qnmsection} we will then present analytic expressions for the QNM frequencies that satisfy each of the master equations present in section \ref{perturbations}, and compare these analytic expressions to previously obtained numerical results. Finally, in section \ref{conclusion}, we will discuss the results presented and make some concluding remarks. Throughout we will use units such that $G=c=1$. \section{Background}\label{background} The background spacetime that we will be concerned with in this work is that of a \textit{slowly} rotating black hole in a universe with a cosmological constant $\Lambda$. The black hole spacetime is described by the Kerr-(Anti)-de Sitter (henceforth referred to as Kerr-(A)dS) solution which, to linear order in dimensionless black hole spin $a$, is given in Boyer-Lindquist coordinates by \cite{1973blho.conf...57C}: \begin{align} ds^2=\bar{g}_{\mu\nu}dx^\mu dx^\nu=&-F(r)dt^2+F^{-1}(r)dr^2+r^2d\Omega^2\nonumber\\ &-2aM\left(\frac{2M}{r}+\frac{\Lambda}{3}r^2\right)\sin^2\theta dtd\phi\label{backgroundg} \end{align} with $d\Omega^2$ being the metric on the surface of the unit 2-sphere, $M$ the black hole mass, and we assume $|a|\ll1$. The metric function $F(r)$ is given by: \begin{align} F(r)=1-\frac{2M}{r}-\frac{\Lambda}{3}r^2. \end{align} The spacetime is asymptotically de Sitter (thus describing a Kerr-dS black hole) for $\Lambda>0\;$; for $\Lambda<0$, we have a Kerr-AdS black hole with an asymptotically Anti-de Sitter spacetime. \section{Perturbation Master Equations}\label{perturbations} When considering perturbations on a spherically symmetric background spacetime, it is standard to decompose the perturbed fields into spherical harmonics to factor out the angular dependence of the perturbation \cite{1975RSPSA.343..289C,0264-9381-16-12-201,Kokkotas:1999bd,Berti:2009kk,Martel:2005ir,Ripley:2017kqg}. Using $Y^{\ell m}_{\mu_1...\mu_n}(\theta,\phi)$ to schematically represent the appropriate choice of scalar, vector, or tensor spherical harmonics depending on the perturbed field $f$ in question: \begin{align} f_{\mu_1...\mu_n}(t,r,\theta,\phi)=\sum_{\ell,m}f^{\ell m}(r,t)Y^{\ell m}_{\mu_1...\mu_n}(\theta,\phi). \end{align} About a spherically symmetric background, perturbations of different polarity (either axial/odd or polar/even) decouple from each other, greatly simplifying the analysis of the equations of motion for the perturbed fields. In addition perturbations of different $\ell$ decouple. The result is that, if we further assume a harmonic time dependence of the form $e^{-i\omega t}$, the equations of motion can often be cast into homogeneous Schr{\"o}dinger style second order differential equations for some unknown function of $r$ representing the perturbation: \begin{align} \left[\frac{d^2}{dr^2}+\left(\omega_{\ell m}^2-V_{\ell m}(r)\right)\right]\mathcal{F}^{\ell m}(r)=0. \end{align} The $\omega_{\ell m}$ are the characteristic QNM frequencies associated with the perturbation, as mentioned in section \ref{introduction}. Detailed reviews on QNMs can be found in \cite{1975RSPSA.343..289C,0264-9381-16-12-201,Kokkotas:1999bd,Berti:2009kk}. The fact that the equations of motion governing the perturbations can often be cast into a single Schr{\"o}dinger style second order differential equation is useful, with the techniques of quantum mechanics and time-independent scattering theory being available to the modern physicist to analyse such an equation (see, for example, the Appendix of \cite{Kokkotas:1999bd}). Unfortunately the decoupling of perturbations of different polarity and $\ell$ no longer occurs when the background is not spherically symmetric (e.g. in axisymmetric spacetimes such as the Kerr family of black holes \cite{Teukolsky:2014vca}), and thus the task of simplifying the equations of motion governing the perturbations is greatly complicated. For example, for a Kerr black hole one has to solve the more complex Teukolsky equation \cite{1973ApJ...185..635T} to find the QNM frequencies, rather than the simpler Regge-Wheeler \cite{Regge:1957td} or Zerilli \cite{Zerilli:1970se} equations that one calculates for Schwarzschild black holes. In \cite{2012PhRvD..86j4017P}, however, it was shown that in slowly rotating backgrounds, where the `breaking' of spherical symmetry is controlled by the dimensionless black hole spin $a$ (and terms $O(a^2)$ are neglected), it is sufficient to continue to use spherical harmonics and to treat perturbations of different polarity and $\ell$ as completely decoupled. This technique yields equations of motion that are sufficient to determine the QNM frequency spectrum of the system accurately to linear order in $a$ (and has been utilised in, for example, \cite{Pani:2013pma,Pani:2013wsa,Brito:2013wya}). The benefit of this approach is that one can continue to exploit the useful properties of spherical harmonics and often still arrive at simple second order equations of motion for the perturbed fields, whilst now including the effects of (slow) rotation. In the following sections we will make use of the above technique for perturbations in slowly rotating backgrounds to derive Schr{\"o}dinger style master equations for various type of perturbations on a slowly rotating Kerr-(A)dS background, keeping terms linear in black hole spin and neglecting terms $O(a^2)$ and higher. This will allow us in Section \ref{qnmsection} to determine the QNM frequency spectra for each type of perturbation to linear order in $a$. From now on we will also suppress spherical harmonic indices so as not to clutter notation, with each equation assumed to hold for a given $(\ell,m)$. \subsection{Massive Scalar field} First we consider a massive test scalar field $\Phi$ (such that $\Phi$ does not contribute to the background energy momentum and thus does not affect the background spacetime) propagating on the slowly rotating Kerr-(A)dS background given by eq.~(\ref{backgroundg}). Such a field obeys the massive Klein-Gordon equation: \begin{align} \Box\Phi=\mu^2\Phi. \end{align} In \cite{2012PhRvD..86j4017P,Pani:2013pma} it was shown that for scalar perturbations such that: \begin{align} \Phi=\sum_{\ell m}\frac{\varphi_{\ell m}(r)}{r}e^{-i\omega t}Y^{\ell m} (\theta,\phi), \end{align} the massive Klein-Gordon equation (linearised to first order in black hole spin $a$) takes the form: \begin{widetext} \begin{align} \left[\frac{d^2}{dr_\ast^2}+\left(\omega^2-\frac{2amM\omega}{r^2}\left(\frac{2M}{r}+\frac{\Lambda}{3} r^2\right)-F(r)\left(\frac{l(l+1)}{r^2}+\frac{2M}{r^3}-\frac{2\Lambda}{3}+\mu^2\right)\right)\right]\varphi=0\label{scalareq}. \end{align} \end{widetext} We see that the effective potential of eq.~(\ref{scalareq}) is modified from the usual spin zero Regge Wheeler equation \cite{1975RSPSA.343..289C,0264-9381-16-12-201,Kokkotas:1999bd,Berti:2009kk} through $\Lambda$ and $a$. Eq.~(\ref{scalareq}) is, nonetheless, still in the generic form of a Schr{\"o}dinger style wave equation. \subsection{Massive Vector field} We now consider a massive vector field propagating on the black hole background. We again assume that the test field does not contribute to the background energy momentum and thus does not affect the background spacetime. Whilst vector fields can have both axial and polar parity components of their perturbations, it was shown in \cite{2012PhRvD..86j4017P} that the polar perturbations for a \textit{massive} vector field on a slowly rotating background cannot be reconciled into a single Schr{\"o}dinger style wave equation. Thus in this paper we will only consider axial parity perturbations for simplicity. It is worth noting that, in the case of a massless vector field (i.e. electromagnetic perturbations), the equations for axial and polar perturbations coincide. In \cite{2012PhRvD..86j4017P} the master equation governing the axial component of a massive vector perturbation is given for a generic slowly rotating background. For the slowly rotating Kerr-AdS background that we are concerned with, the perturbation $A(r)$ satisfies: \begin{widetext} \begin{align} \left[\frac{d^2}{dr_\ast^2}+\left(\omega^2-\frac{2amM\omega}{r^2}\left(\frac{2M}{r}+\frac{\Lambda}{3} r^2\right)-F(r)\left(\frac{l(l+1)}{r^2}+\mu^2\right)\right)\right]A=0,\label{procaeq} \end{align} \end{widetext} where $\mu$ is the vector field mass. In the case that $a=0$, eq.~(\ref{procaeq}) agrees with the master equations derived in \cite{Cardoso:2001bb}. \subsection{Gravitational field} Finally, we consider perturbations to the black hole spacetime itself, such that the metric $g_{\mu\nu}$ can be decomposed into a background part $\bar{g}$ and a perturbation $h$: \begin{align} g_{\mu\nu}=\bar{g}_{\mu\nu}+h_{\mu\nu}, \end{align} where $\bar{g}_{\mu\nu}$ is given by eq.~(\ref{backgroundg}). The perturbed Einstein equations then read \begin{align} \delta R_{\mu\nu} + \Lambda h_{\mu\nu} = 0 \end{align} with $\delta R_{\mu\nu}$ representing the Ricci tensor expanded to linear order in the metric perturbation $h_{\mu\nu}$. For the gravitational perturbations we adopt the Regge-Wheeler gauge and decompose the metric perturbation into tensor spherical harmonics, with the tensor perturbation $h_{\mu\nu}$ having both axial and polar parity perturbations \cite{Regge:1957td,Rezzolla:2003ua}: \begin{widetext} \begin{align} h_{\mu\nu,\ell m}^{ax}=& \begin{pmatrix} 0&0&h_0(r)B^{\ell m}_\theta&h_0(r)B^{\ell m}_\phi\\ 0&0&h_1(r)B^{\ell m}_\theta&h_1(r)B^{\ell m}_\phi\\ sym&sym&0&0\\ sym&sym&0&0 \end{pmatrix}e^{-i\omega_{\ell m} t}, \label{hodd}\\ h_{\mu\nu,\ell m}^{p}=& \begin{pmatrix} H_0(r)F(r)&H_1(r)&0&0\\ sym&H_2(r)F(r)^{-1}&0&0\\ 0&0&K(r)r^2&0\\ 0&0&0&K(r)r^2\sin\theta \end{pmatrix}Y^{\ell m}e^{-i\omega_{\ell m} t}, \label{heven} \end{align} \end{widetext} where $sym$ indicates a symmetric entry, $B^{\ell m}_\mu$ is the axial parity vector spherical harmonic and $Y^{\ell m}$ is the standard scalar spherical harmonic, as described in \cite{Martel:2005ir,Ripley:2017kqg}. Once again we can treat perturbations of different parity separately in order to study the QNM spectrum to linear order in $a$ \cite{2012PhRvD..86j4017P}. \subsubsection{Axial sector} For the axial sector, we can define a function $Q(r)$ in terms of the perturbation fields $h_i$ which satisfies the following Schr{\"o}dinger style master equation: \begin{widetext} \begin{align} \left[\frac{d^2}{dr_\ast^2}+\left(\omega^2-\frac{2amM\omega}{r^2}\left(\frac{2M}{r}+\frac{\Lambda}{3}r^2\right)-F(r)\left(\frac{l(l+1)}{r^2}-\frac{6M}{r^3}+am\frac{24M^2(3r-7M-2r^3\Lambda/3)}{l(l+1)r^6\omega}\right)\right)\right]Q=0.\label{gravaxial} \end{align} \end{widetext} For $\Lambda=0$, eq.~(\ref{gravaxial}) agrees with the Schr{\"o}dinger style equation for axial gravitational perturbations of a slowly rotating Kerr black hole given in \cite{Pani:2013pma}. With $a=0$, eq.~(\ref{gravaxial}) agrees with the result of \cite{Cardoso:2001bb} for the axial perturbations of a Schwarzschild-(A)dS black hole. With $a=\Lambda=0$, we recover the familiar Regge-Wheeler equation \cite{Regge:1957td}. \subsubsection{Polar sector} For the polar sector, we can define a function $Z(r)$ in terms of the perturbation fields $H_i$, and $K$ which obeys the following Schr{\"o}dinger style master equation: \begin{widetext} \begin{align} \left[\frac{d^2}{dr_\ast^2}+\left(\omega^2-\frac{2amM\omega}{r^2}\left(\frac{2M}{r}+\frac{\Lambda}{3}r^2\right)-F(r)\left(V_Z^{(0)}+amV^{(1)}_Z\right)\right)\right]Z=0\label{gravpolar} \end{align} \end{widetext} where $V_Z^{(0)}$ is the familiar Zerilli-like potential for Schwarzschild-(A)dS perturbations given by: \begin{align} V_Z^{(0)}=\frac{2}{r^3}\frac{9M^3+3c^2Mr^2+c^2(1+c)r^3+3M^2(3cr-r^3\Lambda)}{(3M+cr)^2} \end{align} with $c=\frac{1}{2}[l(l+1)-2]$ \cite{Cardoso:2001bb}. $V^{(1)}_Z(r)$ is the $O(a)$ correction to the potential given in Appendix \ref{appendixpolar}. For $\Lambda=0$, i.e. when considering a slowly rotating Kerr black hole, $V^{(1)}_Z(r)$ agrees with the linear in spin correction to the polar potential given in \cite{Pani:2013pma}. With $a=\Lambda=0$, we recover the familiar Zerilli equation \cite{Zerilli:1970se}. \section{Quasinormal modes}\label{qnmsection} \subsection{Analytical Expressions}\label{analyticsec} As a complement to other methods of calculating the QNM frequencies $\omega$ that satisfy the equations presented in section \ref{perturbations} \cite{Kokkotas:1999bd,0264-9381-16-12-201,Berti:2009kk,1985RSPSA.402..285L,Cho:2011sf}, we will present analytic expressions for the QNM frequencies calculated via the method developed in \cite{2009CQGra..26v5003D}. We direct the reader to \cite{2009CQGra..26v5003D} for the details of the method, with the important result being that the $\omega$ for each perturbation master equation can be expressed as a sum over inverse powers of $L=\ell+1/2$, with $\ell$ being the multi-polar spherical harmonic index: \begin{align} \omega=\sum_{k=-1}^{k=\infty}\omega_k \;L^{-k}.\label{expansion} \end{align} In appendix \ref{coeff} we present the $\omega_k$ that satisfy eqs.~(\ref{scalareq}), ~(\ref{procaeq}), ~(\ref{gravaxial}), and ~(\ref{gravpolar}) for the fundamental $n=0$ mode (with $n$ being the overtone index). In principle one can calculate the $\omega_k$ for arbitrary $n$, but for simplicity's sake we focus on the fundamental modes in this work. In each case we have calculated the first eight terms in the expansion, i.e. to $O(L^{-6})$. One can straightforwardly calculate terms to higher order in inverse powers of $L$ through the use of a computer algebra package. We will see in the following section that the QNM frequencies calculated via this analytic expansion method give results in very strong agreement with those calculated via, for example, 6th order WKB methods. In the limit that $\ell\rightarrow\infty$ the QNM frequencies, irrespective of field spin or mass, are given by: \begin{align} M\omega_{\ell m}=\;&\frac{\sqrt{1-9\Lambda M^2}}{6\sqrt{3}}\left(2\ell+1-i\right)+am\left(\frac{2}{27}+\frac{\Lambda M^2}{3}\right)\nonumber\\ &\;+O(\ell^{-1}). \end{align} A result of interest from calculating the $\omega_k$ that satisfy eq.~(\ref{gravaxial}) and (\ref{gravpolar}) analytically is that the axial and polar gravitational frequencies are isospectral to $O(L^{-3})$, with any differences between the $\omega_k$ at higher orders in $1/L$ being proportional to both $a$ and $\Lambda$ (see appendix \ref{polarcoeff}). Thus, to linear order in $a$, it is only in the case of non-zero black hole spin \textit{and} non-zero cosmological constant that the spectra of the axial and polar perturbations split. The isospectrality of the gravitational modes for a Schwarzschild black hole is well known \cite{1975RSPSA.343..289C,0264-9381-16-12-201,Kokkotas:1999bd}, with the isospectrality of Schwarzschild-dS and slowly rotating Kerr-Newman black holes having been observed numerically in \cite{Zhidenko:2003wq,Pani:2013wsa}. It is worth noting that the expansion technique of \cite{2009CQGra..26v5003D} is designed for use in spherically symmetric background spacetimes; indeed we will see in the following section that the results for Schwarzschild-de-Sitter black holes are indeed highly accurate. In \cite{Tattersall:2018nve}, however, the expansion was nevertheless used to find the QNM frequencies of a massive scalar field on a slowly rotating Kerr background (i.e. the $\omega$ satisfying eq.~(\ref{scalareq}) with $\Lambda=0$). Good agreement was again found between those frequencies calculated numerically and those using the analytic expansion method, despite the background spacetime no longer being spherically symmetric. In the following section we will calculate the QNM frequencies satisfying each of eqs.~(\ref{scalareq}), ~(\ref{procaeq}), ~(\ref{gravaxial}), and ~(\ref{gravpolar}) for non-zero $a$ (i.e. on non-spherically symmetric, slowly rotating backgrounds) and investigate how well an approximation the $\omega_k$ presented in appendix \ref{coeff} provide for the QNM frequencies at linear order in black hole spin. In fact, we will see that for $a\ll 1$, the frequencies calculated in this paper provide a very good approximation to those calculated in the literature. Furthermore, as explained in \cite{2009CQGra..26v5003D}, the analytic expansion method for calculating QNM frequencies utilised here is not applicable to asymptotically AdS spacetimes (i.e. for $\Lambda<0$) due to the differing boundary conditions used at spatial infinity. Thus in the following examples we will limit ourselves solely to $\Lambda\geq0$ cases. Nonetheless, the equations presented in section \ref{perturbations} remain valid for both positive and negative $\Lambda$. \subsection{Comparison to Other Results} \subsubsection{Schwarzschild-de-Sitter}\label{sdssec} We first consider the case of a unit mass Schwarzschild-de-Sitter black hole ($a=0$, $M=1$, $0\leq 9\Lambda \leq 1$) \cite{PhysRevD.15.2738}. The QNM frequencies for electromagnetic, gravitational, and massless scalar perturbations in a Schwarzschild-de-Sitter background have been calculated, for example, using the 6th order WKB method in \cite{Zhidenko:2003wq}. We find that in general the frequencies calculated using the analytic expansion method of \cite{2009CQGra..26v5003D} (utilising the expansion coefficients given in appendices \ref{scalarcoeff}-\ref{polarcoeff}) are in good agreement with those presented in \cite{Zhidenko:2003wq}. Tables \ref{sdstablescalar}--\ref{sdstableaxial} in appendix \ref{tables} give the QNM frequencies for massless scalar perturbations, massless vector (i.e. electromagnetic) perturbations, and gravitational perturbations for a selection of $\Lambda$ values. We do not distinguish between axial and polar gravitational frequencies in this case as, further to the discussion above, the coefficients presented in appendix \ref{polarcoeff} show that for $a=0$ the axial and polar QNM frequencies are isospectral (this was also shown in \cite{Zhidenko:2003wq}). In all cases the frequencies are presented as calculated via the WKB method as in \cite{Zhidenko:2003wq} and via the analytical expansion method of \cite{2009CQGra..26v5003D} used in this work, with the errors between the two methods also given. Figures \ref{scalarcomplanesds}-\ref{axialcomplanesds} show QNM frequencies in the complex plane as calculated via both methods. Tables \ref{sdstablescalar}--\ref{sdstableaxial} show that in all cases the relative errors between methods stays comfortably below 1\%, with figures \ref{scalarcomplanesds}-\ref{axialcomplanesds} showing almost complete alignment of frequencies in the complex plane. The expressions for the QNM frequencies given in appendix \ref{coeff} thus appear to compare very well with other methods of calculating QNM frequencies in the case that $a=0$. \begin{figure} \caption{Complex massless scalar frequencies for the $n=0$ mode for varying values of $\Lambda$} \label{scalarcomplanesds} \includegraphics[width=0.5\textwidth]{scalarcomplex} \end{figure} \begin{figure} \caption{Complex electromagnetic frequencies for the $n=0$ mode for varying values of $\Lambda$} \label{vectorcomplanesds} \includegraphics[width=0.5\textwidth]{vectorcomplex} \end{figure} \begin{figure} \caption{Complex gravitational frequencies for the $n=0$ mode for varying values of $\Lambda$} \label{axialcomplanesds} \includegraphics[width=0.5\textwidth]{axialcomplex} \end{figure} \subsubsection{Slowly rotating Kerr} We will now consider the case of a unit mass slowly rotating Kerr black hole ($a>0$, $M=1$, $\Lambda=0$) \cite{Kerr:1963ud}. The QNM frequencies for electromagnetic, gravitational, and massless scalar perturbations in a Kerr background have been calculated, for example, in \cite{Berti:2009kk} using Leaver's continued fraction method \cite{1985RSPSA.402..285L}. We will compare the results of using the expansion coefficients given in appendix \ref{coeff} to the QNM frequency data provided at \url{http://www.phy.olemiss.edu/~berti/ringdown/}. Tables \ref{kerrtablescalar}--\ref{kerrtablegrav} in appendix \ref{tables} give QNM frequencies for massless scalar perturbations, massless vector (i.e. electromagnetic) perturbations, and gravitational perturbations for a selection of $a$ values. As discussed above, we do not distinguish between axial and polar gravitational frequencies as to linear order in $a$ the axial and polar spectra are isospectral for $\Lambda=0$ (see appendix \ref{polarcoeff}). In all cases the frequencies are presented as calculated via continued fractions in \cite{Berti:2009kk} and via the analytical expansion method of \cite{2009CQGra..26v5003D} used in this work, with the errors between the two methods also given. In \cite{Tattersall:2018nve} the analytic expansion results for a \textit{massive} scalar field on a slowly rotating Kerr background were compared to the continued fractions results of \cite{2006PhRvD..73l4040K}. For $a\ll1$, figures \ref{kerrscalarl1}-\ref{kerrgravl3} show that the linear in $a$ approximation to the QNM frequencies calculated from the expressions in appendix \ref{coeff} match well with the numerical data, with tables \ref{kerrtablescalar}-\ref{kerrtablegrav} show the relative errors between methods staying below 1\% for spins of up to $a\sim 0.2$. From figures \ref{kerrscalarl1}-\ref{kerrgravl3}, however, we see that the linear in $a$ approximation for the QNM frequencies clearly starts to fail at smaller values of $a$. This is particularly noticeable for the imaginary frequency components, where the departure from the linear approximation is clearly seen by $a\sim 0.1$. Predictably, in all cases, as $a$ increases the difference between linear in spin approximation used in this work and the frequencies calculated numerically increases. The higher accuracy of the real frequency components compared to the imaginary components can be understood by considering that $O(a)$ contributions to the imaginary component only appear in two terms in the QNM expansion up to $O(L^{-6})$, $\omega_3$ and $\omega_5$ (see appendix \ref{coeff}). This is contrast to the real frequency component which receives contributions linear in $a$ in $\omega_0$, $\omega_2$, $\omega_4$, and $\omega_6$. Thus one should compute higher order terms in the expansion to calculate further $O(a)$ corrections to the imaginary component of the QNM frequencies, and thus improve agreement. Nonetheless, for small $a$ the analytic expressions for the QNM frequencies appear to be a good approximation to those calculated numerically. \begin{figure} \caption{Real and imaginary components of the $\ell=m=2$, $n=0$ massless scalar mode for varying values of $a$} \label{kerrscalarl1} \includegraphics[width=0.5\textwidth]{kerrscalarl1m1real} \includegraphics[width=0.5\textwidth]{kerrscalarl1m1im} \end{figure} \begin{figure} \caption{Real and imaginary components of the $\ell=m=2$, $n=0$ electromagnetic mode for varying values of $a$} \label{kerrelecl2} \includegraphics[width=0.5\textwidth]{kerrelecl2m2real} \includegraphics[width=0.5\textwidth]{kerrelecl2m2im} \end{figure} \begin{figure} \caption{Real and imaginary components of the $\ell=m=3$, $n=0$ gravitational mode for varying values of $a$} \label{kerrgravl3} \includegraphics[width=0.5\textwidth]{kerrgravl3m3real} \includegraphics[width=0.5\textwidth]{kerrgravl3m3im} \end{figure} \subsubsection{Slowly rotating Kerr-de Sitter} We now turn to the most general case of a slowly rotating Kerr-dS black hole, where both $a$ and $\Lambda$ are non-zero and positive. The gravitational QNM frequencies for a Kerr-dS black hole of varying mass were calculated in \cite{PhysRevD.81.044005} by continued fractions, whilst their asymptotics were studied in \cite{Dyatlov:2011jd}. Kerr-de Sitter black holes have further been studied in \cite{PhysRevD.97.104060}. The expressions for $\omega_{-1}$ and $\omega_0$ in appendix \ref{coeff} (i.e. the first two terms in the $L$ expansion, as explained in section \ref{analyticsec}) agree exactly with the expressions given by eq.~(0.3) and (0.4) in \cite{Dyatlov:2011jd}, thus verifying the dominant $O(a)$ correction to $Re(\omega)$ calculated in this paper. Turning to comparisons with \cite{PhysRevD.81.044005}, a table of fitting parameters $(\bar{\omega}, \omega_a)$ (referred to as $(\omega_0, \omega_1)$ in \cite{PhysRevD.81.044005}) is provided to approximate the QNM frequencies of slowly rotating Kerr-dS black holes in the form: \begin{align} \omega = \bar{\omega} + am \omega_a +O(a^2), \end{align} where $\bar{\omega}$ is the QNM frequency evaluated for $a=0$, i.e. the corresponding Schwarzschild-dS frequency for a black hole of the same $M$ and $\Lambda$; $\omega_a$ represents the linear in $a$ correction term. Table \ref{kerrdstable} compares data for $\bar{\omega}$ and $\omega_a$ from \cite{PhysRevD.81.044005} and as calculated in this paper for two black holes of differing mass, with the relative errors between both methods given in parentheses. Note that the fitting parameters $(\bar{\omega}, \omega_a)$ are rescaled by $M$ from their values in \cite{PhysRevD.81.044005} to coincide with the dimensionless black hole spin $a$ that we are using in this paper. Also note that, as previously mentioned, in the case that both $a$ and $\Lambda$ are non-zero, the axial and polar gravitational frequencies are no longer isospectral (see appendix \ref{polarcoeff}). Thus in table \ref{kerrdstable} we compare the results of \cite{PhysRevD.81.044005} to both axial and polar frequencies as calculated in this paper. \begin{table*} \caption{Comparison of the $n=0$ gravitational QNM frequency fitting parameters as calculated by Leaver's continued fraction method in \cite{PhysRevD.81.044005} and analytical expansion techniques for varying $M$ with $\Lambda=3, \ell=2$.} \label{kerrdstable} \begin{ruledtabular} \begin{tabular}{ccccccc} \multicolumn{1}{l}{} & \multicolumn{2}{c}{Leaver}& \multicolumn{2}{c}{L-expansion (axial)}& \multicolumn{2}{c}{L-expansion (polar)}\\ $M$ & $\bar{\omega}$ & $\omega_a$ & $\bar{\omega}$ & $\omega_a$ & $\bar{\omega}$ & $\omega_a$ \\ \hline \\ $0.1205$ & $2.418-0.5944i$ & $0.67564+0.0092i$ & $2.419-0.5931i$ & $0.67391+0.0117i$ & $2.419-0.5931i$ & $0.67720+0.0112i$ \\ (\% error) & & & ($+0.04$,$-0.22$)& ($-0.26$,$+27$)&($+0.04$,$-0.22$)&($+0.23$,$+22$)\\ $0.1789$ & $0.769-0.1964i$ & $0.58375+0.0022i$ & $0.770-0.1962i$ & $0.58324+0.0024i$ & $0.770-0.1962i$ & $0.58380+0.0022i$ \\ (\% error) & & & ($+0.13$,$-0.10$)& ($-0.09$,$+9.1$)& ($+0.13$,$-0.10$)&($+0.01$,$+0.00$)\\ \end{tabular} \end{ruledtabular} \end{table*} As demonstrated in section \ref{sdssec} for the case of a Schwarzschild-dS black hole, we find good agreement between the $\bar{\omega}$ calculated in \cite{PhysRevD.81.044005} and those calculated in this work. We also find good agreement in the real part of $\omega_a$, with errors staying comfortably below 1\% when considering either the polar or axial frequencies. The imaginary part of $\omega_a$ does not agree as well, with relative errors of order $\sim10-20$\%. This can be understood similarly to the case of the imaginary Kerr frequencies as discussed above. For the imaginary frequency component, $O(a)$ contributions only appear in two terms in the QNM expansion up to $O(L^{-6})$ ($\omega_3$ and $\omega_5$). This is in contrast to the real frequency component which receives contributions linear in $a$ in all $\omega_{n}$ for even $n$. One should compute higher order terms in the expansion to calculate further $O(a)$ corrections to the imaginary component of the QNM frequencies. Indeed if one calculates, for example, $\omega_7$ for axial gravitational modes, the error in the imaginary component of $\omega_a$ for $M=0.1789$ drops from $9.1$\% to $5.1$\%, whilst for $M=0.1205$ the error drops from $27$\% to $11$\%. See appendix \ref{coeff} for the explicit expressions of the QNM frequencies calculated in this paper to $O(L^{-6})$. \section{Conclusion}\label{conclusion} In this paper we have presented Schr{\"o}dinger style master equations for the perturbations of massive scalar, massive vector, and gravitational fields on a slowly rotating Kerr-(A)dS black hole. These represent generalisations of the Regge-Wheeler and Zerilli equations (for fields of spin $0,-1,$ or $-2$) to include the effects of both a non-zero cosmological constant $\Lambda$ \textit{and} of slow rotation (i.e. to linear order in dimensionless black hole spin $a$). Some of these equations have been presented before in their entirety (e.g. eq.~(\ref{scalareq}) and (\ref{procaeq}) in \cite{2012PhRvD..86j4017P}), whilst versions of the equations with either $a=0$ or $\Lambda=0$ have been presented in, for example, \cite{Pani:2013pma,Cardoso:2001bb}. The generalisation of the gravitational perturbation equations to include both the effects of rotation and of a cosmological constant presented here should, however, prove useful given the wealth of knowledge accumulated to address such Schr{\"o}dinger style equations. We have also presented, following the method of \cite{2009CQGra..26v5003D}, analytical expressions for the QNM frequencies that satisfy each of the perturbation master equations present in section \ref{perturbations} (eq.~(\ref{scalareq}), (\ref{procaeq}), (\ref{gravaxial}), and (\ref{gravpolar})). The expressions given in appendix \ref{coeff} are intended as a compliment to existing methods of QNM calculation, with the equations presented in section \ref{perturbations} of course being amenable to being solved via one's preferred method. Given that there are relatively few numerical results for QNM frequencies in the literature for some categories of black holes (e.g. Kerr-de Sitter), numerically investigating the perturbation master equations presented in this paper and elsewhere is worthy of further attention. In addition, a natural extension of this work would be to consider black holes possessing non-zero electric charge \cite{doi:10.1063/1.1704350,doi:10.1063/1.1704351}. In section \ref{qnmsection} we find that the analytic expressions calculated in this paper agree well with the QNM frequencies calculated via other methods for a Schwarzschild-dS black hole \cite{Zhidenko:2003wq}, for a slowly rotating Kerr black hole \cite{Berti:2009kk}, and for a slowly rotating Kerr-de Sitter black hole \cite{PhysRevD.81.044005,Dyatlov:2011jd}. They are not, however, valid for asymptotically AdS spacetimes (as explained in \cite{2009CQGra..26v5003D}). The frequencies calculated in this paper support the numerically observed isospectrality of gravitational modes to linear order in spin for Kerr black holes \cite{Pani:2013wsa}, whilst the axial and polar gravitational spectra are shown to split for $a\neq0$ \textit{and} $\Lambda \neq0$. Given the good agreement with numerical results, the analytic expressions for QNM frequencies presented here provide a useful addition to those techniques already in the modern physicist's toolbox, allowing one to see the explicit dependence of the QNM frequencies on the parameters of the black hole and/or field. The study of gravitational QNM frequencies is, of course, of great interest in the context of gravitational wave observations. Properties of black hole merger remnants can be inferred from the observation of the QNM ringing, as well as tests of GR and of the `no-hair hypothesis' \cite{Dreyer:2003bv,Berti:2005ys,Berti:2015itd,0264-9381-33-17-174001,2018PhRvD..97d4021T,Berti:2018vdi,Barack:2018yly,Brito:2018rfr}. Meanwhile, the study of the QNM frequencies of massive bosons (e.g. the scalar and vector cases considered here) propagating on rotating black hole backgrounds finds great relevance in the study of black hole superradiance \cite{Brito:2015oca}. Furthermore, the AdS/CFT correspondence continues to provide motivation for studying QNMs in asymptotically AdS spacetimes \cite{Maldacena:1997re,Nunez:2003eq,Son:2007vk,Hartnoll:2009sz,Herzog:2009xv}. The technique of recasting the complicated, multidimensional, equations of motion governing black hole perturbations in GR into decoupled one-dimensional Schr{\"o}dinger style equations is an incredibly useful one that has allowed great advances in the understanding and numerical calculation of QNM frequencies. The ability to execute such a simplification of the equations of motion, and in particular to include the effects of rotation, in theories of gravity \textit{beyond} GR is in many cases still a work in progress \cite{Tattersall:2018nve,Konoplya:2001ji,Cardoso:2009pk,Molina:2010fb,Lasky:2010bd,Brito:2013wya,Brito:2013yxa,Babichev:2015zub,Blazquez-Salcedo:2016enn,Blazquez-Salcedo:2017txk,Dong:2017toi,2018arXiv180709081B,Zhang:2014kna}. Given that the strong gravity regime of black hole mergers is likely to be one of the best `laboratories' available to us to probe any potential deviations from Einstein's theory, continuing the analysis of black hole perturbations for a variety of fields in alternative theories of gravity will remain an important avenue of research as gravitational wave astronomy matures in the coming years. \section*{Acknowledgments} \vspace{-0.2in} \noindent The author would like to thank P. G. Ferreira, A. O. Starinets, E. Berti, and S. Dyatlov for insightful discussions and advice throughout the preparation of this paper. OJT was supported by the Science and Technology Facilities Council (STFC) Project Reference 1804725, and acknowledges financial support from ERC Grant No: 693024.
\section{Introduction}\label{intro} When investigating smooth group actions on manifolds, an insightful topological invariant one associates to it is its equivariant cohomology. (The coefficient ring throughout this paper is $\mathbb{Q}$, unless otherwise specified.) This remains an effective tool even in cases when concrete descriptions are hard to obtain. Geometric features of the action are reflected by algebraic properties of its equivariant cohomology. Equivariant formality is an example of such a property, which is relevant due to its simple definition (see Sect.~\ref{sec:general}) and to the numerous situations when it is satisfied, such as Hamiltonian actions of compact Lie groups on compact symplectic manifolds (cf.~\cite{Ki}) or isotropy actions of compact symmetric spaces (see \cite{Go}). A larger class consists of the so-called Cohen-Macaulay actions, which are defined in Sect.~\ref{sec:general} below. Their relevance in the context of equivariant topology was noticed by several authors already in the 70s and early 80s: for example, M.~F.~Atiyah used the Cohen-Macaulay condition to study equivariant $K$-theory for torus actions in \cite{Atiyah} and his ideas were adapted to equivariant cohomology by G.~E.~Bredon in \cite{Bredon}; see also the paper \cite{Duflot} by J.~Duflot for actions of discrete groups. More recently, Lie group actions whose equivariant cohomology satisfies the requirement above have been considered in \cite{FranzPuppe2003}, before being thoroughly investigated in \cite{Go-Ro} and \cite{Go-To}. They are natural generalizations of equivariantly formal group actions to the more general situation when all isotropy subgroups may have their ranks strictly smaller than the rank of the acting group. Cohen-Macaulay actions are worth studying due to their interesting features: for example, just like in the equivariantly formal case, a compact Lie group action and the induced action of a maximal torus satisfy simultaneously this requirement; furthermore, Cohen-Macaulay actions are characterized by the exactness of a certain Atiyah-Bredon long sequence; for more details we refer to Sect.~\ref{cmsec} and the appendix below. Also, this condition is satisfied in numerous concrete situations, for example when the cohomogeneity of the action is zero or one, as it was pointed out in \cite{Go-Ma}. Cohomogeneity-one actions are special cases of hyperpolar actions. Recall that an isometric action of a compact connected Lie group on a Riemannian manifold is {\it polar} if there exists a submanifold which is intersected by each orbit of the action, the orbit being orthogonal to the submanifold at each intersection point. If the submanifold can be chosen to be flat relative to the induced Riemannian metric, we say that the action is {\it hyperpolar}. In this paper we will be interested in the case when the manifold on which the group acts is a Riemannian symmetric space of compact type, that is, a quotient $G/H$, where $G$ is a compact connected semisimple Lie group and $H$ a closed subgroup such that $G^\sigma_0 \subset H \subset G^\sigma$, where $\sigma$ is an involutive automorphism of $G$, $G^\sigma$ its fixed point set and $G^\sigma_0$ the identity component of the latter group. Polar actions on compact symmetric spaces have been extensively investigated by many authors, see for instance \cite{HPTT1}, \cite{HPTT2}, \cite{Ko1}, \cite{Ko2}, \cite{Ko3}, and \cite{Ko}. We will prove the following: \begin{theorem}\label{thm:realmain} Any hyperpolar action of a compact connected Lie group on a symmetric space of compact type is Cohen-Macaulay. \end{theorem} The proof relies essentially on the classification of the actions mentioned in the theorem, which was obtained by A.~Kollross in \cite{Ko}. Before stating this result, we need to describe an important class of examples of hyperpolar actions on the symmetric space $G/H$ mentioned above. Let $\tau$ be another involutive automorphism of $G$ and consider its fixed point set, $G^\tau$, along with the identity component $K:=G^\tau_0$. The action of $K$ on $G/H$ by left translations turns out to be hyperpolar, see \cite[Ex.~3.1]{HPTT1}. It is known under the generic name of a {\it Hermann action}, after R.~Hermann, who first investigated this situation in \cite{Her} (note that originally, in \cite{Her}, the group $G^\tau$ was assumed to be connected). According to Kollross' theorem \cite{Ko}, any hyperpolar action is orbit equivalent to a direct product of actions of one of the following types: transitive, of cohomogeneity one, or Hermann (for the notion of orbit equivalence, see Sect.~\ref{oea}). We already know that any action of one of the first two types is Cohen-Macaulay, see \cite[Cor.~1.2]{Go-Ma}. Thus, to prove Thm.~\ref{thm:realmain}, there are two steps to be performed: show first that any Hermann action is Cohen-Macaulay and second that the Cohen-Macaulay property is preserved under orbit equivalence. The first goal is achieved by the following result: \begin{theorem} \label{main} If $G$, $K$, and $H$ are as above, then the (Hermann) action of $K$ on $G/H$ by left translations is Cohen-Macaulay. \end{theorem} A big part of the paper is devoted to the proof of this theorem, see Sect.~\ref{semisimple} (also note that the result remains true even if $G$ is not necessarily semisimple, see Rem.~\ref{nonsemi}). It is worth recalling at this point a related result, obtained by the first-named author of this paper in \cite{Go}, which says that the $K$-action on $G/K$ by left translations is equivariantly formal; recently, a conceptually different proof has been obtained by the second-named author in \cite{No}. Thm.~\ref{main} above is a generalization of this (taking into account Prop.~\ref{characef} below). Pairs $(G,K)$ with the property that the action of $K$ on $G/K$ is equivariantly formal have also been investigated in \cite{Go-No}, \cite{Ca2}, \cite{Ca1}, \cite{Ca-Fo}, and again \cite{No}. The second of the aforementioned goals is to show that the Cohen-Macaulay property is preserved under orbit equivalence. This turns out to be true: see Thm.~\ref{orbit}, which represents the main result of Sect.~\ref{oea}. The proof of Thm.~\ref{thm:realmain} is also given in full detail in that section. \noindent{\bf Acknowledgement.} We would like to thank the referee for numerous valuable comments on a previous version of this paper. \section{General considerations}\label{sec:general} \subsection{The action of $G$ on $M$}\label{cmsec} Throughout this subsection $G$ will always be a compact and connected Lie group which acts smoothly on a closed manifold $M$, although many of the results presented below hold in a larger generality. To any such action one attaches the equivariant cohomology $H^*_G(M)$. This can be defined as the usual cohomology of the Borel construction $EG\times_G M$, where $EG\to BG$ is the classifying principal bundle of $G$. This construction originally belongs to A.~Borel \cite{Bo} and it became gradually an important tool in the theory of transformation groups by work of M.~F.~Atiyah and R.~Bott \cite{At-Bo}, D.~Quillen \cite{Quillen}, and many others. The book \cite{AlldayPuppe} by C.~Allday and V.~Puppe is a useful reference for this topic. We confine ourselves to mentioning the basic fact that $H^*_G(M)$ has a canonical structure of an $H^*(BG)$-algebra. In case $H^*_G(M)$ is free as an $H^*(BG)$-module, we say that the $G$-action is {\it equivariantly formal}. Here is a well-known class of examples of such actions (cf.~\cite[Thm.~6.5.3]{GS}): \begin{ex} \label{exodd} {\rm If $H^{\rm odd}(M)=0$ then any $G$-action on $M$ is equivariantly formal.} \end{ex} The following criterion will be useful later, see \cite[p.~46]{Hs}. \begin{proposition}\label{criteqf} Let $T$ be a torus acting on a closed manifold $M$. (a) The total Betti number of the fixed point set $M^T$ is at most equal to the total Betti number of $M$. (b) The two numbers mentioned above are equal if and only if the $T$-action is equivariantly formal. \end{proposition} In what follows we will be looking in more detail at the algebraic structure of $H^*_G(M)$. Relative to its structure of an $H^*(BG)$-module, it is a positively graded module over a positively graded ring. The latter, $H^*(BG)$, is a polynomial algebra on generators of even degrees, and thus a commutative, graded, Noetherian ring. It is also a *local ring, in the sense that it has a unique graded ideal which is maximal among all graded ideals (namely $H^{>0}(BG)$). The theory of graded modules over *local Noetherian rings is nicely treated in \cite[Sect.~1.5]{BrunsHerzog}. Let us just briefly recall that to each such module one can associate its depth, that is, the maximal length of a regular sequence of elements in the maximal graded ideal. One can also associate its Krull dimension, which is the Krull dimension of the ring modulo the annihilator of the module. In general, the latter number is at least equal to the depth. We say that the module is Cohen-Macaulay if it is equal to 0 or its Krull dimension is equal to its depth. For a more detailed account of this topic, suitable for applications to equivariant cohomology, we refer to \cite[Sect.~5]{Go-To}. \begin{definition}\label{def:cm} A smooth action $G\times M \to M$ is called {\rm Cohen-Macaulay} if $H^*_G(M)$, considered as a module over $H^*(BG)$, is Cohen-Macaulay. \end{definition} A systematic study of this type of actions was undertaken in \cite{Go-Ro} and \cite{Go-To} and we will often rely on results obtained there. However, some caution is necessary, since in the two references above the coefficient field for cohomology is $\mathbb{R}$, whereas in this paper it is $\mathbb{Q}$. We will next show that the two seemingly different Cohen-Macaulayness conditions are in fact equivalent. This will be done by using the following general result \begin{proposition}\label{commalg} Let $R$ and $S$ be two Noetherian *local rings and $\varphi : R \to S$ a ring homomorphism which is homogeneous of degree 0 and maps the maximal graded ideal ${\mathfrak m}$ of $R$ into the maximal graded ideal ${\mathfrak n}$ of $S$. Assume that both $R/{\mathfrak m}$ and $S/{\mathfrak n}$ are fields. Let $A$ be a finitely generated non-zero $R$-module and $B$ a finitely generated non-zero $S$-module, which is flat over $R$. Then: (a) ${\rm depth}_S \ \! A\otimes_R B = {\rm depth}_R \ \! A + {\rm depth}_S \ \! B/{\mathfrak m}B$; (b) $\dim_S A\otimes_R B = \dim_R A + \dim_S B/{\mathfrak m}B$; (c) The module $A\otimes_R B$ is Cohen-Macaulay over $S$ if and only if $A$ and $B/{\mathfrak m}B$ are Cohen-Macaulay over $R$ and $S$, respectively. \end{proposition} \begin{proof} In the special case when $R$ and $S$ are just local rings, both (a) and (b) are standard facts in commutative algebra, cf.~e.g.~Prop.~1.2.16 and Thm.~A.11 in \cite{BrunsHerzog}. The general case can be reduced to this special situation by using localization at the maximal graded ideals. One takes into account that if $I$ is a graded ideal of $R$ then $ {\rm grade} \ \! (I, A)={\rm grade} \ \! (I_{\mathfrak m}, A_{\mathfrak m})$, see \cite[Prop.~1.5.15 (e)]{BrunsHerzog}: this takes care of the three terms involved in equation (a). For (b), one uses three times the general formula $\dim A=\dim A_{\mathfrak m}$, for which we refer to the proof of Prop.~5.1 in \cite{Go-To} (note that the argument found there uses the assumption that $R/{\mathfrak m}$ is a field). \end{proof} \begin{corollary} A group action $G\times M \to M$ is Cohen-Macaulay in the sense of Def.~\ref{def:cm} if and only if $H^*_G(M; \mathbb{R})$ is Cohen-Macaulay as a module over $H^*(BG; \mathbb{R})$. \end{corollary} \begin{proof} One applies Proposition \ref{commalg} by taking $R=H^*(BG)$, $S=H^*(BG; \mathbb{R})$, $A=H^*_G(M)$, and $B=H^*(BG;\mathbb{R})$, in each case with the obvious module structure; also, take $\varphi : H^*(BG)\to H^*(BG; \mathbb{R})$ the inclusion map. \end{proof} \begin{remark} \label{pair} {\rm The same argument shows that if $N$ is a $G$-invariant subspace of $M$, then the $G$-equivariant cohomologies $H^*_G(M, N)$ and $H^*_G(M, N; \mathbb{R})$ as modules over $H^*(BG)$, respectively $H^*(BG; \mathbb{R})$, have the same depth, the same Krull dimension, and are thus simultaneously Cohen-Macaulay.} \end{remark} An immediate observation is that any equivariantly formal action is Cohen-Macaulay. The converse implication is in general not true, as one can easily see in concrete situations (for example, by \cite[Prop.~2.6]{Go-Ma}, any transitive action is Cohen-Macaulay, without being in general equivariantly formal). However, the following result is helpful in this context, see \cite[Prop.~2.5]{Go-Ro}: \begin{proposition}\label{characef} A smooth action $G\times M \to M$ is equivariantly formal if and only if it is Cohen-Macaulay and there exists at least one point in $M$ whose isotropy subgroup has rank equal to ${\rm rank } \ \! G$. \end{proposition} For later use, we also mention: \begin{proposition}\label{maxtor} Let $G\times M \to M$ be a smooth action and $T\subset G$ an arbitrary maximal torus. (a) The $G$-action on $M$ is equivariantly formal if and only if so is the induced $T$-action. (b) The $G$-action on $M$ is Cohen-Macaulay if and only if so is the induced $T$-action. \end{proposition} Item (a) is a standard result, see for instance \cite[Prop.~C.26]{GGK}. Item (b) is the content of \cite[Prop.~2.9]{Go-Ro}. It is worth pointing out in this context that if $H\subset G$ is an arbitrary closed subgroup, then the property of being equivariantly formal is preserved when passing from $G$ to $H$: indeed, on the one hand, the $G$-action is equivariantly formal if and only if the canonical map $H^*_G(M)=H^*(E\times_G M) \to H^*(M)$ is surjective (cf., e.g., \cite[Prop.~2.1]{Go-Ma}), and on the other hand the previous map factors as $H^*_G(M) \to H^*_H(M) \to H^*(M)$. However, it is possible for the $G$-action to be Cohen-Macaualy and the $H$-action not to be like that, see \cite[Ex.~2.13]{Go-Ro}. From the previous proposition one can deduce: \begin{corollary} \label{dirprod} If two smooth actions on closed manifolds are Cohen-Macaulay then their direct product is Cohen-Macaulay as well. \end{corollary} \begin{proof} Let the two group actions be $G_i \times M_i \to M_i$ and let $T_i \subset G_i$ be maximal tori, where $i=1,2$. By Prop.~\ref{maxtor} above, the restricted $T_i$-action on $M_i$ is Cohen-Macaulay. By \cite[Rem.~2]{Go-To}, the restricted $T_i$-action on $M_i$ is Cohen-Macaulay if and only if there exists a subtorus $S_i \subset T_i$ of rank equal to the minimal dimension of a $T_i$-orbit on $M_i$, which acts locally freely on $M_i$ such that the induced action of $T/S_i$ on the orbit space $M/S_i$ is equivariantly formal. But then $S_1 \times S_2$ acts locally freely on $M_1 \times M_2$, has rank equal to the minimal dimension of a $T_1\times T_2$-orbit on $M_1\times M_2$ and the induced action of $T_1/S_1 \times T_2/S_2$ on $M_1/S_1 \times M_2/S_2$ is equivariantly formal (note that equivariant formality is preserved under taking the direct product). Thus the $T_1\times T_2$-action on $M_1 \times M_2$ is Cohen-Macaulay, and so is the $G_1\times G_2$-action. \end{proof} We will need an equivalent characterization of the Cohen-Macaulay condition above, this time exclusively in terms of the ring structure of $H^*_G(M)$. The latter is in general not a commutative ring, but it is nevertheless graded commutative, in the sense that $x\cdot y =(-1)^{({\rm deg} x)({\rm deg} y)}y\cdot x$, for all homogeneous $x, y \in H^*_G(M)$. Although a self-contained treatment of graded commutative rings is not immediately available in the literature, there is no essential difference relative to the (usual) commutative case. A systematic and thorough study of graded commutative rings has been undertaken by M.~Poulsen in Appendix A of his Master Thesis \cite{Po}. For instance, by using the remark following Prop.~A.5 in \cite{Po} and also taking into account that $H^*_G(M)$ is finitely generated as an algebra over its degree zero component $H^0_G(M)\simeq \mathbb{Q}$ (see for instance \cite[Cor.~2.2]{Quillen}), we deduce that $H^*_G(M)$ is a Noetherian ring. For graded commutative Noetherian rings of the type $R=\oplus_{i\ge 0}R^i$ whose degree zero component $R^0$ is a field, one can see in \cite{Po} that the concepts of Krull dimension, depth (relative to the ideal $\oplus_{i>0}R^i$), and Cohen-Macaulayness can be defined in the same way as for commutative rings. This enables us to prove the following result. It is obtained by adapting \cite[Prop.~12, Sect.~IV.B]{Se} to our current set-up. \begin{lemma} {\rm (J.-P.~Serre)} \label{serre} Let $R=\oplus_{i\ge 0}R^i$ and $S=\oplus_{i\ge 0}S^i$ be two graded commutative Noetherian rings with $R^0=S^0=\mathbb{Q}$ and $\varphi: R\to S$ a homomorphism of graded rings which makes $S$ into an $R$-module which is finitely generated. Let also $A$ be a finitely generated $S$-module. Then $A$ is Cohen-Macaulay as an $S$-module if and only if so is $A$ as an $R$-module. \end{lemma} \begin{corollary}\label{cmcrit} The $G$-action on $M$ is Cohen-Macaulay if and only if the ring $H^*_G(M)$ is Cohen-Macaulay. \end{corollary} \subsection{The action of $K$ on $G/H$} Let $G$ be again a compact and connected Lie group and let $K, H\subset G$ be closed subgroups. In this section we list some results concerning the three group actions mentioned in the following proposition. \begin{proposition}\label{crit} If $K$ and $H$ are connected, the following assertions are equivalent: \begin{itemize} \item[(a)] the action of $K$ on $G/H$ by left translations is Cohen-Macaulay; \item[(b)] the action of $H$ on $G/K$ by left translations is Cohen-Macaulay; \item[(c)] the action of $H\times K$ on $G$ given by \begin{equation}\label{hgk}(h,k)\cdot g=hgk^{-1},\end{equation} is Cohen-Macaulay. \end{itemize} \end{proposition} \begin{proof} For the equivalence between (b) and (c) observe that we have the ring isomorphisms $$ H^*_{H\times K}(G)\simeq H^*_H(G/K),$$ due to the fact that the factor $K$ of the product $H\times K$ acts freely on $G$. The equivalence between (a) and (c) can be proved in a similar way, although this time one also needs to take into account that the $H\times K$-action in the lemma is equivalent to the group action $(H\times K)\times G \to G$, $(h, k)\cdot g = kgh^{-1}.$ The result now follows from Cor.~\ref{cmcrit}. \end{proof} In the light of item (c) above, the following proposition is useful. It is a direct consequence of a certain Sullivan model obtained by J.~D.~Carlson and C.-K.~Fok in \cite[Sect.~3.1]{Ca-Fo} (see also \cite[Sect.~8.8.3]{Ca1} or \cite[end of Sect.~2]{Ca3}), which describes the equivariant cohomology of actions on $G$ of type (\ref{hgk}), the acting group being a general subgroup of $G\times G$. Denote by ${\mathfrak g}, {\mathfrak k}, {\mathfrak h}$ the Lie algebras of $G$, $K$, and $H$. \begin{proposition}{\rm (J.~D.~Carlson and C.-K.~Fok)} \label{carlson} If $K$ and $H$ are connected, then the equivariant cohomology of the action of $H\times K$ on $G$ given by $(h,k).g=hgk^{-1}$ depends only on ${\mathfrak g}$, ${\mathfrak h}$, ${\mathfrak k}$, and the inclusions ${\mathfrak h}\hookrightarrow {\mathfrak g}$ and $ {\mathfrak k}\hookrightarrow {\mathfrak g}$. \end{proposition} Finally, we mention a result that shows how to deal with the situation when $H$ is not connected. \begin{proposition}\label{redcon} Assume $K$ is connected and let $H_0$ be the identity component of $H$. If the $K$-action on $G/H_0$ is Cohen-Macaulay, then so is the $K$-action on $G/H$. \end{proposition} \begin{proof} Use the characterization given by Prop.~\ref{crit}, (c). Note that $H_0\times K$ is the identity component of $H\times K$, hence $H^*_{H\times K}(G)\simeq H^*_{H_0\times K}(G)^{H/H_0}.$ By hypothesis, $H^*_{H_0\times K}(G)$ is Cohen-Macaulay as a module over the ring $H^*(BH_0 \times BK)$, thus also over its subring $H^*(BH\times BK)=H^*(BH_0 \times BK)^{H/H_0}$, since the ring is a finitely generated module over the subring and one can use Lemma \ref{serre}. By a standard averaging argument, the invariant module $H^*_{H_0\times K}(G)^{H/H_0}$ can be realized as a direct summand of $H^*_{H_0\times K}(G)$ in the category of $H^*(BH \times BK)$-modules, hence it is Cohen-Macaulay. \end{proof} \section{Hermann actions}\label{semisimple} In this section we will prove Thm.~\ref{main}. The meaning of $G$, $H$, and $K$ is as in Sect.~\ref{intro}. In particular, the Lie group $G$ is compact, connected, and semisimple (the case when $G$ is not necessarily semisimple is discussed in Rem.~\ref{nonsemi}). Due to Propositions \ref{crit} and \ref{redcon}, we only need to show that the equivariant cohomology ring of the $H_0 \times K$-action on $G$ is Cohen-Macaulay. By Prop.~\ref{carlson}, we lose no generality by assuming that $G$ is simply connected, since otherwise we can replace the triple $G$, $H_0$, $K$ with the universal cover of $G$ along with its two connected and closed subgroups that are locally isomorphic to $H_0$ and $K$ respectively. Under the aforementioned assumption, the fixed point sets of $\sigma$ and $\tau$ are connected, see \cite[Thm.~1.8, Ch.~VII]{He}, and thus equal to $H_0$ and $K$ respectively. \subsection{The case when $G$ is simple}\label{sec:simple} We will prove Thm.~\ref{main} under the assumption that $G$ is simple and simply connected, which is valid throughout the whole subsection. The induced automorphisms of $\mathfrak{g}$ will also be denoted by $\sharp\sharp$ and $\tau$. In general, we will not make any notational distinction between an automorphism of $G$ and the induced Lie algebra automorphism. \begin{lemma} \label{torus} Assume $G$ is not equal to ${\rm Spin}(8)$. If ${\rm rank} \ \! K \le {\rm rank} \ \! H$, then a maximal torus in $K$ is group-conjugate with a subgroup of $H$. \end{lemma} \begin{proof} If one of $\sigma$ or $\tau$ is an inner automorphism, the claim in the lemma is clear by \cite[Thm.~5.6, p.~424]{He}. From now on we will assume that both $\sigma$ and $\tau$ are outer automorphisms of $G$. Let $T_K\subset K$ be an arbitrary maximal torus. There is a unique maximal torus $T$ in $G$ such that $T_K\subset T$; furthermore, $T$ is $\tau$-invariant and there is a Weyl chamber $C$ in ${\mathfrak t}:={\rm Lie}(T)$ which is $\tau$-invariant as well (see \cite[Prop.~3.2, p.~125]{Lo}). Let $c: G \to G$ be an inner automorphism such that the torus $S:=c(T)$ contains $T_H$, the latter being a maximal torus in $H$. As before, there exists a Weyl chamber $C'\subset c({\mathfrak t})$ which is invariant under $\sigma$. On the other hand, $c\tau c^{-1}$ is an involutive automorphism of $G$ which leaves $S$ invariant; it even leaves the chamber $c(C)$ (inside the Lie algebra of $S$) invariant. But the chambers $c(C)$ and $C'$ are conjugate under the Weyl group of $(G,S)$; that is, there exists an inner automorphism, say $c'$, such that $$c'(S) =S \ {\rm and} \ c'(C') = c(C).$$ We now compare the involutions $c\tau c^{-1}$ and $c'\sigma c'^{-1}$ of $G$: they both leave the torus $S$ invariant, and along with it, its Lie algebra and the chamber $c(C)$ inside it: both are realized in terms of permuting the simple roots that determine the chamber, the permutation being necessarily a Dynkin diagram automorphism. Since $G$ is different from ${\rm Spin}(8)$, there is a unique such (involutive) permutation which is not the identity map. But none of the automorphisms $c\tau c^{-1}$ and $c'\sigma c'^{-1}$ is inner, thus by composing them and then restricting the result to the chamber $c(C)$, one gets the identity map; as an automorphism of $G$, this composition must consequently be an inner automorphism $c_g$ defined by some $g\in S$. That is, $$c\tau c^{-1}=c'\sigma c'^{-1} c_g.$$ Notice that the automorphism in the left hand side of the previous equation leaves $c(T_K)\subset S$ pointwise fixed. Consequently, $c'\sigma c'^{-1}$ does the same. In other words, $c(T_K)$ is contained in the fixed point set of $c'\sigma c'^{-1}$, which is just $c'(H)$. This finishes the proof. \end{proof} \noindent{\it Proof of Thm.~\ref{main} in the case $G$ simple.} First assume that $G$ is different from ${\rm Spin}(8)$. By Prop.~\ref{crit}, we may assume that ${\rm rank} \ \! K \le {\rm rank} \ \! H$. Thus, by Lemma \ref{torus}, there exists $T\subset K$ a maximal torus and $g_0\in G$ such that $g_0Tg_0^{-1}\subset H$. The actions $K \times G/H\to G/H$ and $g_0Kg_0^{-1} \times G/H\to G/H$ given by left translation are equivalent, relative to the map $$(K, G/H) \to (g_0Kg_0^{-1}, G/H), \quad (k, gH) \mapsto (g_0kg_0^{-1}, g_0gH).$$ Thus it is sufficient to show that the $g_0Kg_0^{-1}$-action on $G/H$ is Cohen-Macaulay. Equivalently, by means of Prop.~\ref{maxtor} above, that the action of $g_0Tg_0^{-1}$ on $G/H$ is so. But this is clear, because, by the main result in \cite{Go}, the action of $H$ on $G/H$ is equivariantly formal. If $G={\rm Spin}(8)$, then, as in the proof of Lemma \ref{torus}, we can assume that both $\sigma$ and $\tau$ are outer automorphisms. It is known that the group of outer automorphisms of ${\rm Spin}(8)$ is isomorphic to the symmetric group $\Sigma_3$ on three letters and the fixed point set of any order-two outer automorphism is isomorphic to ${\rm Spin}(7)$, giving rise to a copy of the symmetric space ${\rm Spin}(8)/{\rm Spin}(7) = S^7$ (cf.~\cite[Sect.~2]{Ad1}). Thus Thm.~\ref{main} is a consequence of Lemma \ref{odd} below. $\square$ \begin{lemma}\label{odd} Any smooth action of a compact connected Lie group on a closed manifold which is a rational cohomology sphere is Cohen-Macaulay. \end{lemma} \begin{proof} If the dimension of the sphere is even, the lemma is a consequence of Ex.~\ref{exodd}. To deal with the remaining situation, we use Prop.~\ref{maxtor} (b), which enables us to only consider the action of a torus $T$ on $X$, where $X$ is a closed manifold with $H^*(X)\simeq H^*(S^{2n+1})$ as vector spaces, for some $n \ge 0$. In particular, the total Betti number $\dim H^*(X)$ is equal to 2. In case the fixed point set $X^T$ is non-empty, the latter is a union of closed submanifolds of $X$. By Prop.~\ref{criteqf}, $\dim H^*(X^T)$ is thus a strictly positive number at most equal to 2. On the other hand, the Euler-Poincar\'e characteristics of $X$ and $X^T$ are equal, see e.g.~\cite[Thm., (4)]{Kobayashi} or \cite[Thm.~9.3]{Go-Zo}; thus $\dim H^*(X^T)$ is an even number. We conclude that the latter number is equal to 2, hence the $T$-action on $X$ is equivariantly formal and consequently Cohen-Macaulay. Let us now consider the case when the set $X^T$ is empty. There exists a one-dimensional subtorus $S\subset T$ whose action on $X$ is locally free. One can compute the cohomology of the orbit space $X/S$ by means of the following version of the Gysin sequence (cf.~\cite[Lemma 2.2]{Co}): $$\ldots \to H^j(X/S) \to H^{j+2}(X/S) \to H^{j+2}(X) \to H^{j+1}(X/S) \to \ldots .$$ It follows that $H^*(X/S)\simeq H^*(\mathbb{C} P^n)$ by an isomorphism of vector spaces. Consequently, by Ex.~\ref{exodd}, the canonical action of $T/S$ on $X/S$ is equivariantly formal, hence, by Cor.~\ref{cmcrit}, the ring $H^*_{T/S}(X/S)$ is Cohen-Macaulay. To conclude the proof, it only remains to notice that we have the ring isomorphism $$H^*_T(X)\simeq H^*_{T/S}(X/S).$$ \end{proof} \subsection{The case when $G$ is not simple} From now on, $G$ is just simply connected, not necessarily being simple. Our main tool in dealing with this situation is the following result, see \cite[Prop.~18]{Ko}: \begin{proposition}{\rm (A.~Kollross)}\label{andreas} If $G$ is simply connected then the $H$-action on $G/K$ is a direct product of actions of one of the following types: \begin{itemize} \item[(i)] the action of $H'\times L^{n-1} \times K'$ on $L^n$ defined by \begin{align*} {}&(h, g_1, \ldots, g_{n-1}, k)\cdot(x_1, \ldots, x_n)\\{}&= (hx_1g_1^{-1}, g_1x_2g_2^{-1}, \ldots, g_{n-2}x_{n-1}g_{n-1}^{-1}, g_{n-1}x_n k^{-1}),\end{align*} \item[(ii)] the action of $H'\times L^{n-1}$ on $L^{n-1}\times L/K'$ defined by \begin{align*} {}&(h, g_1, \ldots, g_{n-1})\cdot(x_1, \ldots, x_{n-1}, x_nK')\\{}&= (hx_1g_1^{-1}, g_1x_2g_2^{-1}, \ldots, g_{n-2}x_{n-1}g_{n-1}^{-1}, g_{n-1}x_n K'),\end{align*} \item[(iii)] the action of $L^{n-1}$ on $H'\backslash L\times L^{n-2}\times L/K'$ defined by \begin{align*}{}&(g_1,\ldots, g_{n-1})\cdot (H'x_1, x_2, \ldots, x_{n-1}, x_n K') \\{}&=(H'x_1g_1^{-1}, g_1x_2g_2^{-1}, \ldots, g_{n-2}x_{n-1}g_{n-1}^{-1}, g_{n-1}x_n K'),\end{align*} \item[(iv)] the action of $L^n$ on $L^n$ defined by \begin{align*}{}&(g_1, \ldots, g_n)\cdot(x_1,\ldots, x_n)\\{}& =(g_1x_1g_2^{-1}, g_2x_2g_3^{-1}, \ldots, g_{n-1}x_{n-1}g_n^{-1}, g_n x_n\alpha(g_1)^{-1}),\end{align*} \end{itemize} where $L$ is a simply connected, simple and compact Lie group, $H',K'\subset L$ are fixed points of involutions of $L$, $\alpha$ is an outer or trivial automorphism of $L$, and $n$ is an arbitrary integer, at least equal to 1 in cases (i), (ii), and (iv), respectively to 2 in case (iii). \end{proposition} For the reader's convenience, here are a few details concerning this result. \begin{remark} {\rm (a) Proposition \ref{andreas} above is just a consequence of the result actually proved in \cite{Ko}. Namely, we are here in the special case when $G$ is simply connected. Thus our $H$-action on $G/K$ is of the Hermann type in the sense of \cite[Def.~15]{Ko} (see the definition of locally symmetric subgroups at the beginning of \cite[Sect.~2]{Ko} and also recall the well-known fact that the identity component of the isometry group of the symmetric space $G/K$ is just $G$). Under the hypothesis mentioned above, $G/K$ is simply connected as well, hence the $H$-action on $G/K$ is not only locally conjugate to one of the types (i)-(iv), as the result in \cite{Ko} says, but genuinely conjugate. (b) We also wish to explain the meaning of the number $n$ in the proposition above. It comes from the structure of $G/K$. For example, in case (i) the pair $(G, K)$ is equal to $(L \times \cdots \times L, \Delta(L)\times \cdots \times \Delta(L))$, where the first direct product has $2n$ factors, the second has $n$, and $\Delta(L) :=\{(g, g) | g\in L\}$. The cases (ii)-(iv) are left as an exercise to the reader.} \end{remark} In view of Cor.~\ref{dirprod}, to prove Thm.~\ref{main} for $G$ semisimple it is sufficient to show that the actions (i)-(iv) are Cohen-Macaulay. Let us start with (i). We use an inductive argument. Note that the first factor $L$ in $H'\times L^{n-1}\times K'$ acts freely on $L^{n}$, the orbit space being diffeomorphic to $L^{n-1}$ via $$L^{n}/L \to L^{n-1}, \quad (x_1, x_2, \ldots, x_{n}) \mapsto (x_1 x_2, x_3 \ldots, x_{n}).$$ Thus it is sufficient to prove that the action of $H'\times L^{n-2}\times K'$ on $L^{n-1}$ given by \begin{align*} {}&(h, g_2, \ldots, g_{n-1}, k)\cdot(x_2, \ldots, x_n)\\{}&= (hx_2g_2^{-1}, g_2x_3g_3^{-1}, \ldots, g_{n-2}x_{n-1}g_{n-1}^{-1}, g_{n-1}x_n k^{-1}),\end{align*}is Cohen-Macaulay. We continue the procedure and gradually drop out the $L$-factors in $H'\times L^{n-1}\times K'$ until we finally obtain the action of $H'\times K'$ on $L$ given by $(h, k)\cdot x=hxk^{-1}$. But this action is Cohen-Macaulay by the result already proved in Subsect.~\ref{sec:simple} (see also Prop.~\ref{crit}). To deal with (ii), we start by modding out the action of the first factor $L$ in $H'\times L^{n-1}$, which is clearly a free action. In this way, we reduce the problem to showing that the action of $H'\times L^{n-2} $ on $L^{n-2}\times L/K'$ described by \begin{align*} {}&(h, g_2, \ldots, g_{n-1})\cdot(x_2, \ldots, x_{n-1}, x_nK')\\{}&= (hx_2g_2^{-1}, g_2x_3g_3^{-1}, \ldots, g_{n-2}x_{n-1}g_{n-1}^{-1}, g_{n-1}x_n K'),\end{align*}is Cohen-Macaulay. We continue the procedure until we are led to the action of $H'$ on $L/K'$ given by left translations. Again, this action is Cohen-Macaulay by the result we proved in Subsect.~\ref{sec:simple}. Similarly, in case (iii) we reduce the problem to the action of $L$ on $H'\backslash L \times L/K'$ described by $g\cdot (H'x_1, x_2K')=(H'x_1g^{-1}, gx_2K')$. The map $$H'\backslash L \times L/K'\to L/H'\times L/K', \quad (H'x_1, x_2K')\mapsto (x_1^{-1}H', K'x_2)$$ is an $L$-equivariant diffeomorphism. This allows us to change our focus to the action of $\Delta(L):=\{(g,g)\mid g\in L\}$ on $(L\times L)/(H'\times K')$ by left translations. By Prop.~\ref{crit}, this is Cohen-Macaulay if and only if so is the action of $H'\times K'$ on $(L\times L)/\Delta(L)$. But the latter is just the action of $H'\times K'$ on $L$ given by $(h, k)\cdot x=hxk^{-1}$, which was discussed in Subsect.~\ref{sec:simple}. As about (iv), the recursive procedure already used in each of the previous cases leads us to the action of $L$ on itself given by $g\cdot x=gx\alpha(g)^{-1}$. It was proved by Baird in \cite[p.~212]{Ba} (cf.~also \cite[p.~58]{Sieb}) that all isotropy groups of this action have the same rank. By \cite[Cor.~4.3]{Go-Ro}, the action is thus Cohen-Macaulay. \begin{remark}\label{nonsemi} {\rm Thm.~\ref{main} holds even when $G$ is not necessarily semisimple. To prove this, consider a finite cover of $G$ of the type $T\times G_s$, where $T$ is a torus and $G_s$ is compact, connected, and simply connected. In view of Propositions~\ref{crit}, \ref{carlson}, and \ref{redcon} it is sufficient to consider the case when $G$ is equal to such a direct product and $H$ is the identity component of $G^\tau$. But then both $\sigma$ and $\tau$ leave the factors $T$ and $G_s$ invariant. Their fixed point sets split as direct products of subgroups of $T$ and $G_s$ respectively; that is, $H_0=T_1\times H_s$ and $K=T_2\times K_s$, where $T_1, T_2\subset T$ are subtori and $H_s, K_s \subset G_s$. The $H_0\times K$-action on $G$ can be described as follows: $$\left((t_1, h), (t_2, k)\right). \left(t, g\right) = \left(t_1tt_2^{-1}, hgk^{-1}\right).$$ This is the direct product of the following two actions: \begin{align*}{}&(T_1 \times T_2) \times T \to T, \ (t_1, t_2)\cdot t =t_1tt_2^{-1}\\ {}& (H_s \times K_s)\times G_s \to G_s, \ (h, k)\cdot g = hgk^{-1}. \end{align*} In view of Cor.~\ref{dirprod}, it is sufficient to observe that both of them are Cohen-Macaulay: for the first factor, one observes that the kernel of the $T_1 \times T_2$-action on $T$ is isomorphic to $T_1\cap T_2$, and an arbitrary direct complement of its identity component acts locally freely; for the second factor, one uses Thm.~\ref{main}. } \end{remark} We conclude the section with a remark concerning equivariant formality of Hermann actions: \begin{remark} {\rm Let $G, K$, and $H$ be as in Thm.~\ref{main}. The action of $K$ on $G/H$ is equivariantly formal if and only if a maximal torus in $K$ is conjugate with a subgroup of $H$ (note that the latter condition is equivalent to the existence of a fixed point for the action of the maximal torus in $K$, which is necessary for the equivariant formality of the $K$-action; the other implication is proved by invoking the main result of \cite{Go} as in the proof of Thm.~\ref{main} in the case $G$ simple). In particular, ${\rm rank} \ \! K \le {\rm rank } \ \! H$. We note that the latter condition alone is not sufficient for equivariant formality. Take for instance two Dynkin diagram involutions of ${\rm Spin}(8)$ which are not conjugate with each other. Their fixed point sets, $H$ and $K$ respectively, are both isomorphic to ${\rm Spin}(7)$. It turns out that the action of $H$ on ${\rm Spin}(8)/K\simeq S^7$ by left translations is transitive, with isotropy subgroups isomorphic to the exceptional compact Lie group of type $G_2$, see e.g.~\cite[Thm.~3]{Va}. Thus this action is not equivariantly formal. It is interesting to notice, however, that if $G$ is simple and simply connected, $G\neq {\rm Spin}(8)$, then the condition ${\rm rank} \ \! K \le {\rm rank } \ \! H$ is sufficient for the $K$-action on $G/H$ to be equivariantly formal: this follows from Lemma \ref{torus} above. } \end{remark} \section{Orbit equivalent actions}\label{oea} We start by proving the following two lemmata, whose relevance will become clear immediately: \begin{lemma}\label{prop:orbit} Let $M$ be a closed manifold and $K, K'$ two compact and connected Lie groups that act on $M$ such that $K\subseteq K'$ and $Kp=K'p$ for all $p\in M$. Then the $K$-action on $M$ is Cohen-Macaulay if and only if so is the $K'$-action. \end{lemma} \begin{proof} Let $b$ denote the maximal rank of an isotropy subgroup of the $K$-action and $M_{b,K}$ the subspace of $M$ consisting of all points whose isotropy group has rank equal to $b$. In the same way, to the action of $K'$ one assigns the number $b'$ and the subspace $M_{b', K'}$. For any $p\in M$ we have $Kp=K'p$. In general, if $G$ is a compact Lie group and $U \subset G$ a closed subgroup, then the rank $\chi\pi(G/U)$ of the homogeneous space $G/U$ is a homotopy invariant, which turns out to be equal to the difference ${\rm rank } \ \! U - {\rm rank } \ \! G$ (see \cite[Def.~Sect.~1.1 and Sect. 4.2]{All2}). In our situation, for any $p\in M$ we have $Kp = K'p$, and hence the homogeneous spaces $K/K_p$ and $K'/K'_p$ are diffeomorphic, where $K_p$ and $K'_p$ are the isotropy subgroups at $p$. We deduce \begin{equation}\label{rankk}{\rm rank } \ \! K - {\rm rank } \ \! K_p={\rm rank } \ \! K' - {\rm rank } \ \! K'_p.\end{equation} (We note that the same argument was used in \cite[Prop.~7]{Go-Po}; we could also just apply the latter proposition to the $K$- and $K'$-actions on $Kp=K'p$ to obtain the same conclusion.) Eq.~(\ref{rankk}) implies: \begin{equation}\label{mbh} M_{b, K} = M_{b', K'}.\end{equation} Pick maximal tori $T$ in $K$ and $T'$ in $K'$ such that $T\subset T'$. The minimal dimension of a $T$-orbit in $M$ is ${\rm rank} \ \! K - b$, cf.~e.g.~\cite[Lemma 4.1]{Go-Ro}. Similarly, the minimal dimension of a $T'$-orbit in $M$ is ${\rm rank} \ \! K' - b'$. But the two aforementioned numbers are the $K$-, respectively $K'$-coranks of any point in $M_{b,K}$ respectively $M_{b',K'}$, hence, by eq.~(\ref{mbh}), they are equal. Thus, there exists a subtorus $S\subset T$ of rank equal to the two numbers which acts locally freely on $M$. The sets $M_{b, T}$ and $M_{b', T'}$ defined in the same way as before are non-empty, clearly contained in $M_{b,K}$ and $M_{b', K'}$ respectively. The $K$-action on $M_{b, K}$ is Cohen-Macaulay, see \cite[Cor.~4.3]{Go-Ro}. Consequently, this time by Prop.~\ref{maxtor} (b) and Cor.~\ref{cmcrit}, $H^*_T(M_{b,K})$ is a Cohen-Macaulay ring. Since $S\subset T$ acts locally freely, the latter ring is isomorphic to $H^*_{T/S}(M_{b,K}/S)$. On the other hand, the $T/S$-action on $M_{b,K}/S$ admits points that are fixed. Namely, they are orbits of the form $Sp$ such that $Sp=Tp$, which implies that \begin{equation}\label{fix}{\rm corank}_T \ \! T_p = {\rm rank} \ \! S.\end{equation} But if $p\in M$ satisfies the latter condition, then $Sp$ is a connected and closed submanifold of $Tp$, of the same dimension as the latter, hence $Sp=Tp$. Thus condition (\ref{fix}) characterizes the fixed points. Since ${\rm rank} \ \! S = {\rm rank} \ \! T -b$, that condition is actually equivalent to $p\in M_{b, T}$. We have actually proved: \begin{equation}\label{movers}(M/S)^{T/S}=(M_{b,K}/S)^{T/S}=M_{b,T}/S.\end{equation} From the previous considerations, the $T/S$-action on $M_{b,K}/S$ is equivariantly formal. Consequently, by eq.~(\ref{movers}), \begin{equation}\label{dimh} \dim H^*(M_{b,K}/S) =\dim H^*(M_{b,T}/S).\end{equation} In the same way, one analyzes the $K'$-action on $M$ and obtains \begin{equation}\label{movers2}(M/S)^{T'/S}=(M_{b',K'}/S)^{T'/S}=M_{b',T'}/S.\end{equation} as well as \begin{equation}\label{dimh2} \dim H^*(M_{b',K'}/S) =\dim H^*(M_{b',T'}/S).\end{equation} We are now in a position to prove the equivalence stated in the lemma. First, the $K$-action on $M$ is Cohen-Macaulay if and only if so is the induced $T$-action, see Prop.~\ref{maxtor} (b). But $H^*_T(M)=H^*_{T/S}(M/S)$ and the $T/S$-action on $M/S$ admits fixed points, thus the latter Cohen-Macaulay condition is equivalent to: the $T/S$-action on $M/S$ is equivariantly formal. Equivalently, by eqs.~(\ref{movers}) and (\ref{dimh}), $$\dim H^*(M/S)= \dim H^*(M_{b,K}/S).$$ In exactly the same way, this time by using eqs.~(\ref{movers2}) and (\ref{dimh2}), the $K'$-action on $M$ is Cohen-Macaulay if and only if $$\dim H^*(M/S)= \dim H^*(M_{b',K'}/S).$$ The proof is completed by taking into account eq.~(\ref{mbh}). \end{proof} \begin{lemma}\label{kernel} Let $M$ be a closed manifold and $K$ a compact and connected Lie group that acts smoothly on $M$. Let also $H\subset K$ be the kernel of the action. Then the $K$-action on $M$ is Cohen-Macaulay if and only if so is the $K/H$-action. \end{lemma} \begin{proof} Let $b$ and $M_{b,K}$ be as in the proof of Lemma \ref{prop:orbit}. Pick maximal tori $T$ and $T'$ in $K$ and $H$ respectively such that $T'\subset T$. Again, let $S\subset T$ be a subtorus of rank equal to ${\rm rank} \ \! T -b$ whose action on $M$ is locally free. We already noticed that the $K$-action on $M$ is Cohen-Macaulay if and only if $$\dim H^*(M/S)= \dim H^*(M_{b,T}/S).$$ Observe that there exists a maximal torus $T_1 \subset K/H$ along with a covering map $T/T' \to T_1$. Furthermore, for the $K/H$-action on $M$, the maximal rank of an isotropy subgroup is $b_1:=b - {\rm rank} \ \! H.$ Since the intersection $T'\cap S$ is finite, the image $S_1$ of $S$ under the projection $T\to T/T'\to T_1$ is a subtorus of rank equal to ${\rm rank} \ \! S={\rm rank} \ \! T_1 -b_1$ which acts locally freely on $M$. As before, the $K/H$-action on $M$ is Cohen-Macaulay if and only if $$\dim H^*(M/S_1)= \dim H^*(M_{b_1,T_1}/S_1).$$ But $M/S_1=M/S$ and $M_{b_1,T_1}=M_{b, T}$, thus the equivalence stated in the lemma is clear. \end{proof} Let us now recall that two isometric actions of two connected compact Lie groups on a Riemannian manifold are {\it orbit equivalent} if there is an isometry of the manifold to itself which maps each orbit of the first group action to an orbit of the second one. \begin{theorem}\label{orbit} Let $M$ be a compact Riemannian manifold and $K$ a connected and closed subgroup of the isometry group of $M$. Assume that the $K$-action on $M$ is orbit equivalent to a Cohen-Macaulay action on $M$. Then the $K$-action is Cohen-Macaulay as well. \end{theorem} \begin{proof} Let $G$ be the isometry group of $M$. By hypothesis, there exists a connected and closed subgroup $K'\subset G$ whose canonical action on $M$ is Cohen-Macaulay such that the actions of $K$ and $K'$ on $M$ are orbit equivalent (notice that a priori $K'$ might not be contained in $G$; in this case, we mod out the kernel of its action on $M$ and use Lemma \ref{kernel} above). Thus there exists an isometry $f : M \to M$ which maps any $K$-orbit to a $K'$-orbit. Consider the closed subgroup $K''$ of $G$ generated by $f^{-1} K' f$ and $K$. Note that $K''$ is connected. The key-observation is that for any $p\in M$, we have \begin{equation}\label{hp} Kp=(f^{-1}K'f)p=K''p.\end{equation} The first equality is clear and immediately implies the second. Due to eq.~(\ref{hp}), the result stated in the theorem is a direct consequence of Lemma \ref{prop:orbit}, used twice.\end{proof} We are now in a position to prove the main result of the paper: \noindent{\it Proof of Thm.~\ref{thm:realmain}.} As already mentioned in the introduction, Kollross has shown in \cite{Ko} that any hyperpolar action is orbit equivalent to a direct product of actions of one of the following types: transitive, of cohomogeneity one, or Hermann. We know that an action of each of these three types is Cohen-Macaulay: for the first two, see \cite[Cor.~1.2]{Go-Ma}, for the last, use Thm.~\ref{main}. We apply Thm.~\ref{orbit}: even though the acting group is not necessarily a subgroup of ${\rm Iso}(M)$, we can mod out the kernel of the action and use Lemma \ref{kernel}.\hfill $\square$ \begin{remark} {\rm It would be interesting to find a classification-free proof of Thm.~\ref{thm:realmain}, using the very definition of a hyperpolar action.} \end{remark}
\section{emission process from defects in hbn} A typical emission process from a defect in hBN is shown in Fig.~\ref{fig:SFig1}. The transitions for the zero-phonon line and the phonon sidebands are labelled as $G_0$ and $G_{-2,-1,1,2}$, respectively. \begin{figure}[h] \centerline{\includegraphics[width=5 cm]{SFig1_SA}} \caption{The electron-phonon system for defect center in hBN in the configuration coordinate space. Parabolas represents the harmonic potentials of the lattice in the electronic states.} \label{fig:SFig1} \end{figure} \section{Temperature dependent optical phonon sidebands} \begin{figure}[h] \centerline{\includegraphics[width=9 cm]{SFig2_SA}} \caption{Temperature dependent spectra of the defect taken between 78~K and 138~K. The ZPL energy is centered in each spectrum to observe the temperature dependent detuning between the sidebands and the ZPL energies.} \label{fig:SFig11} \end{figure} \section{Temperature dependent broadening and lineshift of ZPL} The temperature dependent broadening and shift of the ZPL energy can be determined by considering the coupling of low energy LA phonons to the electronic states of the defect. The linear electron-phonon coupling terms introduce a linear temperature dependence to the linewidth as \cite{Stoneham2001}: \begin{equation} \Gamma (T) = \left\lbrace8 \ln(2) \sum_\alpha (\hbar \omega_\alpha)^2 S_{\alpha 0} \coth(\hbar \omega_\alpha/2k_BT) \right\rbrace^{1/2} \\ \end{equation} where $S_{\alpha 0}$ is the Huang-Rhys factor for the phonon with the frequency of $\omega_\alpha$, $k_B$ is the Boltzmann constant. The integral form of the above-equation can be written as: \begin{equation} \Gamma (T) = \left\lbrace8 \ln(2) \int_0^{\omega_M} d\omega (\hbar \omega)^2 D(\omega) S(\omega) (2n(\omega)+1) \right\rbrace^{1/2} \label{eq:linG} \end{equation} where $S(\omega)$ is Huang-Rhys factor $D(\omega)$ is density of states, $n(\omega)$ is the Bose-Einstein distribution function, and $\omega_M$ is the maximum phonon frequency. Considering the coupling to LA phonons through deformation potential ($V(\omega) \propto \hbar \omega/\sqrt{\hbar \omega }$) and piezoelectric coupling ($V(\omega) \propto 1/\sqrt{\hbar \omega }$) with Huang-Rhys parameter $S(\omega)=(V(\omega)/\hbar \omega)^{2}$) and the density of states in 2D ($D(\omega) \propto \omega$), the contribution to the broadening from linear electron-coupling terms becomes $T^{3/2}$ and $T^{1/2}$, respectively. The quadratic electron-phonon coupling results in a temperature dependent broadening of the ZPL as \cite{Stoneham2001}: \begin{equation} \Gamma(T) \propto \int_0^{\omega_M} d\omega \left\lbrace \sum_q |V_q|^2 \delta(\omega-\omega_q) \right\rbrace^2 n(\omega) \lbrace n(\omega)+1\rbrace \label{eq:quadG} \end{equation} where $V_q$ is the electron-phonon coupling parameter. Alternatively the integral form of the Equation \ref{eq:quadG} is: \begin{equation} \Gamma(T) \propto \int_0^{\omega_M} d\omega \left\lbrace V^2(\omega) D(\omega)\right\rbrace^2 n(\omega) \lbrace n(\omega)+1\rbrace \end{equation} Considering the coupling to LA phonons through deformation potential with the density of states in 2D, the contribution to the broadening of the ZPL from the quadratic electron-phonon coupling is derived as: \begin{equation} \Gamma(T) \propto T^5 \end{equation} Additionally, the coupling of LA phonons through piezoelectric coupling with the density of states in 2D, the contribution to the broadening of the ZPL from the quadratic electron-phonon coupling is derived as: \begin{equation} \Gamma(T) \propto T \end{equation} The general temperature dependence of the width from the emission centered at ZPL becomes: \begin{equation} \Gamma(T)=\Gamma_0+a T^{1/2}+b T^{3/2}+c T+d T^5 \label{eq:gamma} \end{equation} However, second and third terms approaches to a constant value at low temperatures. In Figure \ref{fig:SFig3}, fits to the experimental FWHM data with the only quadratic electron-phonon coupling terms and linear plus quadratic coupling terms are shown. Both models represent the experimental data quite efficiently. Therefore, temperature dependence of the FWHM is modelled by considering only the quadratic electron-phonon coupling terms. \begin{figure}[H] \centerline{\includegraphics[width=10 cm]{SFig3_SA}} \caption{Temperature dependence of the FWHM of the defect center exhibiting a ZPL at 2.2 eV. The experimental data is shown with black dots, while the solid line represents the fit of quadratic coupling terms ($\Gamma(T) = \Gamma_0 + aT + bT^5$) and the dashed line shows the fit of linear and quadratic coupling terms ($\Gamma(T)=\Gamma_0+a T^{1/2}+b T^{3/2}+cT+dT^5$) together.} \label{fig:SFig3} \end{figure} The lowest non-vanishing contribution from the electron-phonon interaction to the lineshift is the quadratic coupling which is given as \cite{Stoneham2001}: \begin{equation} \Lambda(T) \propto \int_0^{\omega_M} d\omega \left\lbrace \sum_q |V_q|^2 \delta(\omega-\omega_q) \right\rbrace \lbrace n(\omega)+1\rbrace \label{eq:quadL} \end{equation} \begin{equation} \Lambda(T) \propto \int_0^{\omega_M} d\omega \left\lbrace V^2(\omega) D(\omega)\right\rbrace \lbrace n(\omega)+1\rbrace \label{eq:quadL1} \end{equation} Similarly, considering the coupling to LA phonons through deformation potential and piezoelectric coupling with the density of states in 2D, the temperature dependence of the lineshift becomes $\Lambda(T) =cT+ dT^3$. \section{Temperature dependent Lineshape analysis of ZPL} \begin{figure}[H] \centerline{\includegraphics[width=14 cm]{SFig4_SA}} \caption{PL emission spectrum from the ZPL (2.2 eV) at various temperatures (a) 78 K, (b) 103 K, (c) 113 K, (d) 123 K are given with symbols. The blue solid lines represent the lineshape calculated from the linear electron coupling theory with the contributions from ZPL (orange line), OPL (green line), and TPL (red line). Calculated Huangh-Rhys and Debye-Waller parameters at relevalent temperature are given in the insets.} \label{fig:SFig2} \end{figure} Figure \ref{fig:SFig2} (a) shows the experimental (symbols) spectral lineshape obtained at 78 K, 103 K, 113 K, 123 K and the result of the fitting with the theoretical lineshape given in the main text including up to two phonon process involving the phonon sidebands from LA phonons coupled to electronic states through deformation potential. \bibliographystyle{apsrev}
\section{Introduction} The planetary system HR8799 is unique in that it hosts four directly-imaged planets \citep{Marois2008,Marois2010}. The A-star is estimated to have an age of 30 Myr \citep{Marois2010} and is located at a distance of 39 pc \citep{Marois2008}. The planets orbit at 15 to 70 au between a warm dust belt and a cold Kuiper belt-like structure \citep{Su2009, Booth2016}, implying orbital periods between 50 and 500 years. Indeed, recent time series observations clearly show the orbital motion of the planets \footnote{http://jasonwang.space/orbits.html}. HR8799b is the outermost planet, 1.7 arcseconds away from the host star, with a K-band magnitude of Ks=14.05, corresponding to a contrast of $\sim3300$ at these wavelengths \citep{Marois2008}. Comparisons of the planet's spectral energy distribution with planet evolutionary models provide a mass estimate of $M=5^{+2}_{-1} M_{\rm{J}}$ with a planet radius of $R=1.2\pm0.1 R_{\rm{J}}$ \citep{Currie2011,Soummer2011,Wright2011}. Early observations with the integral field spectrograph OSIRIS \citep{OSIRIS2003,OSIRIS2006} on the Keck II telescope at $2.1 - 2.2\ \mu $m combined with flux measurements at other wavelengths show that the near-infrared spectrum of HR8799b is consistent with that of an early T-dwarf with an intermediate cloud deck and possibly a weak methane feature \citep{Bowler2010}. Atmospheric modeling by \citet{Madhusudhan2011} infers a thick cloud cover, and shows that the 3.3 $\mu $m flux of the planet is inconsistent with the expected fiducial methane abundance - requiring significantly less methane (see also \cite{Marley2012,Skemer2012}). Further observations by \citet{Oppenheimer2013} and \citet{Ingraham2014} also show no significant methane absorption. However, later observations with OSIRIS at H and K-band do provide evidence for methane \citep{Barman2011,Barman2015}. A binned-down, low resolution spectral analysis of the IFU data \citep{Barman2011} shows strong water absorption in H and K, and weak methane and CO in K-band. Subsequent analysis at the full resolving power of R=4000 \citep{Barman2015} using cross-correlation techniques, seem to confirm the methane and carbon monoxide detections in K-band, but show no evidence for methane absorption in the H-band data, while this is expected from the absorption feature at 1.65 $\mu$m. In this paper, we apply a different analysis on the existing OSIRIS H and K-band data, also making use of cross-correlation techniques. The technique, dubbed {\it molecule mapping}, targets the high-frequency signatures of particular molecules in an IFU data cube, ultimately providing a measure of the amount of evidence for molecular absorption at all spatial locations in the IFU data cube \citep{Hoeijmakers2018}. The technique is described in detail in \cite{Hoeijmakers2018}, where it is applied to SINFONI/VLT data of the beta Pictoris system, showing strong absorption from both CO and H$_2$O at SNRs$\sim$15 at the location of exoplanet beta Pictoris b. First, a stellar reference spectrum is constructed using the spaxels near the star position. Subsequently, a scaled version of this stellar reference is subtracted from the spectra at each position in the IFU field of view. The redisual spectra are then cross-correlated with molecular templates. The cross-correlation co-adds the individual absorption lines of the planet emission spectrum constructively, while this is not the case for (residual) telluric and stellar features \citep{Hoeijmakers2018}. The method depends neither on field rotation, as is the case for Angular Differential Imaging (ADI; \cite{Marois2006}) methods, nor on wavelength scaling of the PSF, as for Spectral Differential Imaging (SDI; \cite{Mawet2012}) techniques, making it particularly powerful at small angular distances from the host star where residual speckles are strongest. Molecule mapping is different from the technique utilized by \cite{Barman2015}. In particular, they perform telluric calibrations using an early-type standard star, which implicitly also removes possible stellar absorption lines. The observations are described in Section \ref{sec:observations}, and the data analysis is presented in Section \ref{sec:analysis}. The resulting molecule maps are shown and discussed in Section \ref{sec:results}. \section{Observations} \label{sec:observations} The data of HR8799b were taken on four nights in July 2009 (H-band) and July 2013 (K-band; see Table \ref{tab:exposures}) using the Natural guide star adaptive optics OH-Suppressing InfraRed Imaging Spectrograph (OSIRIS) on Keck II \citep{OSIRIS2006}, as part of programs U150O and U136O \citep{Barman2011,Barman2015}. OSIRIS utilizes a grid of lenslets to slice the field of view, after which a grating disperses the light from each lenslet resulting in a spectrum for each field-point. The data were taken in H-band mode and K-band mode, producing a nominal spectral resolution of R$\sim$4,000. Each data cube contains 16$\times$64 spectra at an angular scale of 0.02" per pixel. Time series of 6$\times$900s and 4$\times$900s in H-band, and two of 9$\times$600s in K-band were taken. \begin{table}[h] \centering \begin{tabular}{|c|c|c|c|} \hline Band & Exposures & Exposure time & Date\\ \hline H & 6 & 900s & 23-07-2009 \\ H & 4 & 900s & 30-07-2009\\ K & 9 & 600s & 25-07-2013\\ K & 9 & 600s & 26-07-2013\\ \hline \end{tabular} \caption{\label{tab:exposures}Overview of the used OSIRIS observations.} \end{table} \section{Data analysis} \label{sec:analysis} \subsection{Background and telluric removal} We used the pipeline-reduced datacubes retrieved from the Keck Archive, which provide the user with standardised and calibrated data cubes. These cubes were aligned and co-added such that the planet position was the same, resulting in one final data cube for each band. Two of the ten original H band cubes were excluded as the planet was not distinguishable from the background. \begin{figure} \centering \resizebox{\hsize}{!}{\includegraphics{white_light.jpeg}} \caption{\label{fig:whitelight}White light frames of the master data cubes in the H band and the K band.} \end{figure} The H band observations were performed in nodding mode with 0.5'' offsets perpendicular to the star direction, keeping the planet in view. This meant that no seperate background subtraction was necessary. However, in the K band there was significant background flux, meaning that the spectra contained a mix of planetary and stellar light with strong telluric lines. The measured spectrum in each pixel is decribed by, \begin{equation} \label{eq:signal} \centering \begin{aligned} F_{\rm{x,y}}(\lambda) &= (A_{\rm{x,y}} * F_{\rm{s}}(\lambda)+B_{\rm{x,y}} * F_{\rm{p}}(\lambda)) \times S_{\rm{T}}(\lambda) \\ \end{aligned} \end{equation} where $F_{\rm{s}}$ and $F_{\rm{p}}$ are the spectra of the star and planet respectively, and $S_{\rm{T}}$ is the telluric absorption spectrum. Constants $A_{\rm{x,y}}$ and $B_{\rm{x,y}}$ denote the relative contribution of the star and planet at each pixel location $x,y$. The latter is generally zero, except near or at the planet position. The first part of the data analysis was aimed at removing the contribution and contamination from the stellar and telluric spectrum from each spaxel. A Phoenix spectral model \citep{PHOENIXI}, with $T_{\rm{eff}}$ = 7200 K, log(g) = 4.50 cm sec$^{-2}$, solar metallicity, and convolved to the resolution of the observed spectra, was used as a template for the stellar spectrum. Subsequently, a reference spectrum was constructed by combining the spectra from a section of 25 by 10 pixels away from the planet position, which was divided by the stellar model to obtain the telluric spectrum. Each spaxel in the dataset is subsequently divided by the telluric spectrum to obtain a 'telluric free' data cube. As a final step, a stellar spectrum was weighted and subtracted from each spaxel such that the stellar lines were removed and only the planetary contribution remains. \subsection{Cross-correlation} Because we focus our analysis on the high-frequency planet absorption features, each spaxel was high-pass filtered using a 6th-order Butterworth filter with a window of 10 nm in each band, corresponding to 50 and 40 pixels in the H and K bands respectively. This also removes any residual low-frequency stellar speckle contributions in the spectra. Data points that were more than 5$\sigma$ away from the mean were replaced by the local mean to prevent bad data points from influencing the cross correlation. The data were cross-correlated with models from \cite{Models} of absorption spectra of methane, water, carbon monoxide and ammonia in the K-band, and of methane and water in the H-band, as carbon monoxide and ammonia have no strong features in this latter band. These models are the result of line-by-line model calculations using HITEMP \citep{rothman2010hitemp} and HITRAN 2008 \citep{rothman2009hitran} line databases, after which they were convolved to the resolution of the observed spectra and high-pass filtered as above. The cross-correlation was performed for each spaxel for radial velocities in the range from $-$1500 km/s to $+$1500km/s in steps of 35 km sec$^{-1}$. \section{Results and Discussion} \label{sec:results} \subsection{Molecule maps} The resulting molecule maps consist of the cross-correlation signal from each spaxel at the planet radial velocity, here assumed to be 35 km sec$^{-1}$ (blueshifted) for all nights, originating from the combination of the barycentric velocity of the observatory (similar for all observations) and the system velocity of the star. The resolution of the cross-correlation function in both bands is also about 35 km sec$^{-1}$. Figure \ref{fig:mmH} presents the molecule maps from the H-band data, showing water and methane respectively. While water is marginally detected at SNR$\sim$2, there is no sign of methane. The SNRs are determined as the peak signal at the planet velocity divided by the standard devation of the cross-correlation function over a wide range of velocity ($\pm15000$ km sec$^{-1}$). Figure \ref{fig:mmK} presents the molecule maps from the K-band data, showing from top-left to bottom-right water, carbon monoxide, methane, and ammonia. Both carbon monoxide and water are clearly detected at SNR$\sim$6, while again there is no sign of methane, and neither of ammonia. \begin{figure} \centering \includegraphics[scale=.5]{Figure2.pdf} \caption{\label{fig:mmH}Molecule maps from the H-band data showing water on the left and methane on the right. The maps are centered on the location of the planet. The planet is detected in the map of water, but not in that of methane.} \end{figure} \begin{figure} \centering \includegraphics[scale=.5]{Figure3.pdf} \caption{\label{fig:mmK} Molecule maps from the K-band data showing in the top row left to right carbon monoxide and water and in the bottom row methane and ammonia. The maps are centered on the location of the planet. The planet is detected in the maps of water and carbon monoxide, but not in the maps of methane and ammonia.} \end{figure} The top panel of Figure \ref{fig:cc-H-results} shows the normalized and filtered water and methane model spectra used for the cross-correlation in H-band, and the processed spectrum at the planet position. The lower panel shows the cross-correlation functions for these molecules at this planet position, showing the low-confidence signal for water, and the absence of a methane signal. Figure \ref{fig:cc-K-results} shows the same for the K-band data, including carbon monoxide, water, methane and ammonia. The cross correlation functions show the clear detection for water and carbon monoxide at the planet velocity, but no sign of methane and ammonia. The resulting signal-to-noise ratios are summarized in Table \ref{tab:SNR}. \begin{figure} \centering \resizebox{\hsize}{!}{\includegraphics{cc_H.jpeg}} \caption{\label{fig:cc-H-results} \emph{Top:} Filtered spectrum of HR8799b (black) and template spectra of water (blue) and methane (red) in the H band, offset by an arbitrary amount. \emph{Bottom:} Cross-correlation functions of the planet spectrum with the model spectra plotted above.} \end{figure} \begin{figure} \centering \resizebox{\hsize}{!}{\includegraphics{cc_K.jpeg}} \caption{\label{fig:cc-K-results} As Figure \ref{fig:cc-H-results}, but in the K band and with the addition of methane (green) and ammonia (cyan) model spectra and cross-correlation functions. The difference in the resolution of the CCF is due to the difference in resolution of the H and K band data.} \end{figure} \begin{table}[h!] \centering \begin{tabular}{|c|c|c|} \hline Molecule & H band & K band\\ \hline $H_2O$ & 2.2 & 6.2 \\ $CH_4$ & 0.4 & 0.8 \\ $CO$ & - & 6.4 \\ $NH_3$ & - & 0.6 \\ \hline \end{tabular} \caption{\label{tab:SNR}Signal to noise ratios of the cross-correlation functions in the H and K bands at a the planet radial velocity of -35 km sec$^{-1}$. } \end{table} No significant molecule signals are found away from the planet position. This means that the telluric line removal was successful, and that possible telluric residuals have not resulted in spurious signals. \subsection{Comparison to earlier work} We directly compare our results with those obtained by \cite{Barman2011} and \cite{Barman2015}, who used the same OSIRIS data - albeit we use a total of 50\% and 40\% fewer on-target exposures than the previous analysis due to the availability of reduced data cubes in the Keck archive. An equally powerful analysis would result in $\sim$30\% lower SNRs. Although \cite{Barman2011} and \cite{Barman2015} do not explicitly quote a statistical significance for their detections, visual inspection of their cross-correlation functions indicate that our detections of H$_2$O and CO, in particular in the K-band, are significantly stronger. We also note that the velocity resolution of our cross-correlation functions are higher. This may in part explain why our analysis results in a higher confidence for these molecules.s In contrast, while \cite{Barman2015} present a significant detection of methane in the K-band OSIRIS data, we see no sign of this molecule in our analysis. Possible causes could be the presence of telluric residuals in either of the analyses, the differences in spectral filtering techniques, or the use of different methane models. In particular, they perform telluric calibrations using an early-type standard star, while our analysis performs effectively a 'self-calibration' for telluric line removal using the data themselves. We also note that in the original analysis methane was only detected in the K-band, while the H-band methane signal could be expected to be comparably strong. Future more sensitive observations, e.g. with the JWST, should reveal whether methane is really present in the atmosphere of HR8799b or not. \bibliographystyle{apa}
\section{Introduction} Neural machine translation (NMT) predicts the target sentence one word at a time, and thus models the task as a sequence classification problem where the classes correspond to words. Typically, words are treated as categorical variables which lack description and semantics. This makes training speed and parametrization dependent on the size of the target vocabulary \cite{mikolov2013distributed}. Previous studies overcome this problem by truncating the vocabulary to limit its size and mapping out-of-vocabulary words to a single ``unknown'' token. Other approaches attempt to use a limited number of frequent words plus \emph{sub-word units} \cite{sennrich-haddow-birch:2016:P16-12}, the combination of which can cover the full vocabulary, or to perform character-level modeling \cite{chung-cho-bengio:2016:P16-1, TACL1051, costajussa-fonollosa:2016:P16-2, ling2015character}; with the former being the most effective between the two. The idea behind these alternatives is to overcome the vocabulary size issue by modeling the morphology of rare words. One limitation, however, is that semantic information of words or sub-word units learned by the input embedding are not considered when learning to predict output words. Hence, they rely on a large amount of examples per class to learn proper word or sub-word unit output classifiers. \begin{table*} \centering {\def\arraystretch{0.98}\tabcolsep=10pt \begin{tabular}{ c c c c cc } \hline & \multicolumn{2}{c}{NMT} & NMT-\code{tied} & \multicolumn{2}{c}{NMT-\code{joint}} \\ \textbf{Query} & \textbf{Input} & \textbf{Output} & \textbf{Input/Output} & \textbf{Input} & \textbf{Output} \\ \hline visited & attacked & \textcolor{red}{visiting} & \textcolor{red}{visits} & visiting & attended \\ (Verb past tense) & conquered & attended & attended & attended & witnessed\\ & contacted & \textcolor{red}{visit} & \textcolor{red}{visiting} & visits & discussed \\ & occupied & \textcolor{red}{visits} & frequented & visit & recognized \\ & consulted & discovered & \textcolor{red}{visit} & frequented & demonstrated \\ \hdashline generous & modest & spacious & \textcolor{red}{generosity} & spacious & friendly\\ (Adjective) & extensive & \textcolor{red}{generosity} & spacious & generosity & flexible\\ & substantial & \textcolor{red}{generously} & \textcolor{red}{generously} & flexible & brilliant \\ & ambitious & massive & lavish & generously & fantastic \\ & sumptuous & huge & massive & massive & massive \\\hdashline friend & wife & \textcolor{red}{friends} & colleague & colleague & colleague \\ (Noun) & husband & colleague & \textcolor{red}{friends} & friends & fellow \\ & colleague & \textcolor{red}{Fri@@} & neighbour & neighbour & supporter\\ & friends & fellow & girlfriend & girlfriend & partner \\ & painter & \textcolor{red}{friendship} & companion & husband & manager \\ \hline \hline \end{tabular}} \caption{Top-5 most similar input and output representations to two query words based on cosine similarity for an NMT trained without (NMT) or with \textit{weight tying} (NMT-\code{tied}) and our \textit{structure-aware} output layer (NMT-\code{joint}) on De-En ($|\mathcal{V}| \approx 32K$). Our model learns representations useful for encoding and generation which are more consistent to the dominant semantic and syntactic relations of the query such as verbs in past tense, adjectives and nouns (inconsistent words are marked in \textcolor{red}{red}).} \label{example} \end{table*} One way to consider information learned by input embeddings, albeit restrictively, is with \textit{weight tying} i.e.~sharing the parameters of the input embeddings with those of the output classifiers \cite{press-wolf:2017:EACLshort, inan2016tying} which is effective for language modeling and machine translation \cite{sennrich-EtAl:2017:EACLDemo, klein-EtAl:2017:ACL-2017-System-Demonstrations}. Despite its usefulness, we find that \textit{weight tying} has three limitations: (a) It biases all the words with similar input embeddings to have a similar chance to be generated, which may not always be the case (see Table \ref{example} for examples). Ideally, it would be better to learn distinct relationships useful for encoding and decoding without forcing any general bias. (b) The relationship between outputs is only implicitly captured by \textit{weight tying} because there is no parameter sharing across output classifiers. (c) It requires that the size of the translation context vector and the input embeddings are the same, which in practice makes it difficult to control the output layer capacity. In this study, we propose a \textit{structure-aware} output layer which overcomes the limitations of previous output layers of NMT models. To achieve this, we treat words and subwords as units with textual descriptions and semantics. The model consists of a joint input-output embedding which learns what to share between input embeddings and output classifiers, but also shares parameters across output classifiers and translation contexts to better capture the similarity structure of the output space and leverage prior knowledge about this similarity. This flexible sharing allows it to distinguish between features of words which are useful for encoding, generating, or both. Figure \ref{example} shows examples of the proposed model's input and output representations, compared to those of a softmax linear unit with or without \textit{weight tying}. This proposal is inspired by joint input-output models for zero-shot text classification \cite{yazdani2015model,nam2016all}, but innovates in three important directions, namely in learning complex non-linear relationships, controlling the effective capacity of the output layer and handling structured prediction problems. Our contributions are summarized as follows: \begin{itemize} \item We identify key theoretical and practical limitations of existing output layer parametrizations such as softmax linear units with or without \textit{weight tying} and relate the latter to joint input-output models. \item We propose a novel \textit{structure-aware} output layer which has flexible parametrization for neural MT and demonstrate that its mathematical form is a generalization of existing output layer parametrizations. \item We provide empirical evidence of the superiority of the proposed structure-aware output layer on morphologically simple and complex languages as targets, including under challenging conditions, namely varying vocabulary sizes, architecture depth, and output frequency. \end{itemize} \vspace{-2mm} The evaluation is performed on 4 translation pairs, namely English-German and English-Finnish in both directions using BPE \cite{sennrich-haddow-birch:2016:P16-12} of varying operations to investigate the effect of the vocabulary size to each model. The main baseline is a strong LSTM encoder-decoder model with 2 layers on each side (4 layers) trained with or without \textit{\textit{weight tying}} on the target side, but we also experiment with deeper models with up to 4 layers on each side (8 layers). To improve efficiency on large vocabulary sizes we make use of negative sampling as in \cite{mikolov2013distributed} and show that the proposed model is the most robust to such approximate training among the alternatives. \section{Background: Neural MT} \label{lanmt} The translation objective is to maximize the conditional probability of emitting a sentence in a target language \(Y =\{y_1,...,y_n\}\) given a sentence in a source language \(X =\{x_1,...,x_m\}\), noted \(p_{\Theta}(Y | X)\), where \(\Theta\) are the model parameters learned from a parallel corpus of length $N$: \vspace{-2mm} \begin{equation} \max_{\Theta} \frac{1}{N} \sum_{i=1}^N \log(p_{\Theta}(Y^{(i)}|X^{(i)})). \end{equation} By applying the chain rule, the output sequence can be generated one word at a time by calculating the following conditional distribution: \begin{equation} p(y_t|y_1^{t-1},X ) \approx f_{\Theta}(y_1^{t-1},X). \end{equation} where $f_{\Theta}$ returns a column vector with an element for each $y_t$. Different models have been proposed to approximate the function $f_{\Theta}$ \cite{kalchbrenner13,Sutskever14,bahdanau2014neural,cho-EtAl:2014:EMNLP2014, gehring2017convolutional, vaswani2017attention}. Without loss of generality, we focus here on LSTM-based encoder-decoder model with attention \citet{luong-pham-manning:2015:EMNLP}. \subsection{Output Layer parametrizations} \subsubsection{Softmax Linear Unit} The most common output layer (Figure \ref{fig:tied}), consists of a linear unit with a weight matrix $W\in \rm I\!R^{d_h \times |\mathcal{V}|}$ and a bias vector $b \in \rm I\!R^{|\mathcal{V}|}$ followed by a softmax activation function, where $V$ is the vocabulary, noted as NMT. For brevity, we focus our analysis specifically on the nominator of the normalized exponential which characterizes softmax. Given the decoder's hidden representation ${h}_t$ with dimension size $d_h$, the output probability distribution at a given time, $y_t$, conditioned on the input sentence $X$ and the previously predicted outputs $y_1^{t-1}$ can be written as follows: \begin{align} p(y_t|y_1^{t-1},X) & \propto \text{exp}(W^T{h}_t + b) \nonumber \\ & \propto \text{exp}(W^TI{h}_t + b), \label{baseline_eq} \end{align} where $I$ is the identity function. From the second line of the above equation, we observe that there is no explicit output space structure learned by the model because there is no parameter sharing across outputs;~the parameters for output class $i$, $W^T_i$, are independent from parameters for any other output class $j$, $W^T_j$. \subsubsection{Softmax Linear Unit with \textit{Weight Tying}} \label{weighttying} The parameters of the output embedding $W$ can be tied with the parameters of the input embedding $E \in \rm I\!R^{|\mathcal{V}| \times d}$ by setting $W = E^T$, noted as NMT-\code{tied}. This can happen only when the input dimension of $W$ is restricted to be the same as that of the input embedding ($d = d_h$). This creates practical limitations because the optimal dimensions of the input embedding and translation context may actually be when $d_h \neq d$. With tied embeddings, the parametrization of the conditional output probability distribution from Eq.~\ref{baseline_eq} can be re-written as: \vspace{-3mm} \begin{align} p(y_t|y_1^{t-1},X) & \propto \text{exp}((E^T)^T{h}_t + b) \nonumber \\ & \propto \text{exp}(E{h}_t + b). \label{tied_eq} \end{align} As above, this model does not capture any explicit output space structure. However, previous studies have shown that the input embedding learns linear relationships between words similar to distributional methods \cite{mikolov2013distributed}. The hard equality of parameters imposed by $W=E^T$ forces the model to re-use this implicit structure in the output layer and increases the modeling burden of the decoder itself by requiring it to match this structure through $h_t$. Assuming that the latent linear structure which E learns is of the form $E \approx E_{l} \mathcal{W}$ where $E_{l} \in \rm I\!R^{|\mathcal{V}| \times k}$ and $\mathcal{W} \in \rm I\!R^{k \times d}$ and $d = d_h$, then Eq.~\ref{tied_eq} becomes: \begin{equation} \begin{split} p(y_t|y_1^{t-1},X) & \propto exp(E_{l} \mathcal{W} {h}_t + b)\ \square. \end{split} \end{equation} \begin{figure*}[htbp] \centering \begin{subfigure}[b]{0.45\textwidth} \centering \includegraphics[width=0.75\textwidth]{lanmt_schema_baseline} \vspace{-0mm}\caption{Typical output layer which is a softmax linear unit without or with \textit{\textit{weight tying}} ($W=E^T$).} \label{fig:tied} \end{subfigure} \hspace{3mm} \begin{subfigure}[b]{0.47\textwidth} \centering \includegraphics[width=0.9\textwidth]{lanmt_schema} \vspace{-0mm}\caption[1]{The \textit{structure-aware} output layer is a joint embedding between translation contexts and word classifiers. } \label{fig:proposed} \end{subfigure} \caption[1]{Schematic of existing output layers and the proposed output layer for the decoder of the NMT model with source context vector $c_t$, previous word $y_{t-1} \in \rm I\!R^d$, and decoder hidden states, $h_t \in \rm I\!R^{d_h}$. } \end{figure*} The above form, excluding bias $b$, shows that \textit{weight tying} learns a similar linear structure, albeit implicitly, to joint input-output embedding models with a bilinear form for zero-shot classification \cite{yazdani2015model,nam2016all}.\footnote{The capturing of implicit structure could also apply for the output embedding $W$ in Eq.~\ref{baseline_eq}, however that model would not match the bilinear input-output model form because it is based on the input embedding $E$.} This may explain why \textit{weight tying} is more sample efficient than the baseline softmax linear unit, but also motivates the learning of explicit structure through joint input-output models. \subsection{Challenges} \label{challenges} We identify two key challenges of the existing parametrizations of the output layer: (a) their difficulty in learning complex structure of the output space due to their bilinear form and (b) their rigidness in controlling the output layer capacity due to their strict equality of the dimensionality of the translation context and the input embedding. \subsubsection{Learning Complex Structure} The existing joint input-output embedding models \cite{yazdani2015model,nam2016all} have the following bilinear form: \begin{align} E \hspace{-0.5ex}\underbrace{\mathcal{W}}_{\text Structure}\hspace{-0.5ex} h_{t}\, \label{eq:bilinear} \end{align} where $\mathcal{W} \in \rm I\!R^{d \times d_h}$. We can observe that the above formula can only capture linear relationships between encoded text ($h_t$) and input embedding ($E$) through $\mathcal{W}$. We argue that for structured prediction, the relationships between different outputs are more complex due to complex interactions of the semantic and syntactic relations across outputs but also between outputs and different contexts. A more appropriate form for this purpose would include a non-linear transformation $\sigma(\cdot)$, for instance with either: \begin{align} \text{(a)} \underbrace{\sigma(E \mathcal{W})}_{\text{Output structure}}\hspace{-1ex} h_{t}\ \ \text{~~or~~}\ \ \text{(b)~~} E \hspace{-1ex}\underbrace{\sigma(\mathcal{W} h_{t})}_{\text{Context structure}}. \label{nonlin} \end{align} \subsubsection{Controlling Effective Capacity} Given the above definitions we now turn our focus to a more practical challenge, which is the capacity of the output layer. Let $\Theta_{base}$, $\Theta_{tied}$, $\Theta_{bilinear}$ be the parameters associated with a softmax linear unit without and with \textit{weight tying} and with a joint bilinear input-output embedding, respectively. The capacity of the output layer in terms of effective number of parameters can be expressed as: \begin{align} \mathcal{C}_{base} \approx |\Theta_{base}| = |\mathcal{V}| \times d_h + |\mathcal{V}|\\ \mathcal{C}_{tied} \approx |\Theta_{tied}| \leq |\mathcal{V}| \times d_h + |\mathcal{V}|\\ \mathcal{C}_{bilinear} \approx |\Theta_{bilinear}| = d \times d_h + |\mathcal{V}|. \end{align} But since the parameters of $\Theta_{tied}$ are tied to the parameters of the input embedding, the effective number of parameters dedicated to the output layer is only $|\Theta_{tied}| = |\mathcal{V}|$. The capacities above depend on \textit{external} factors, that is $|\mathcal{V}|$, $d$ and $d_h$, which affect not only the output layer parameters but also those of other parts of the network. In practice, for $\Theta_{base}$ the capacity $d_h$ can be controlled with an additional linear projection on top of $h_t$ (e.g.~as in the OpenNMT implementation), but even in this case the parametrization would still be heavily dependent on $|\mathcal{V}|$. Thus, the following inequality for the effective capacity of these models holds true for fixed $|V|$, $d$, $d_{h}$: \begin{align} \mathcal{C}_{tied} < \mathcal{C}_{bilinear} < \mathcal{C}_{base}. \label{capacity_ineq} \end{align} This creates in practice difficulty in choosing the optimal capacity of the output layer which scales to large vocabularies and avoids underparametrization or overparametrization (left and right side of Eq.~\ref{capacity_ineq} respectively). Ideally, we would like to be able to choose the effective capacity of the output layer more flexibly moving freely in between $C_{bilinear}$ and $C_{base}$ in Eq.~\ref{capacity_ineq}. \section{Structure-aware Output Layer for Neural Machine Translation} The proposed \textit{structure-aware} output layer for neural machine translation, noted as NMT-\code{joint}, aims to learn the structure of the output space by learning a joint embedding between translation contexts and output classifiers, as well as, by learning what to share with input embeddings (Figure \ref{fig:proposed}). In this section, we describe the model in detail, showing how it can be trained efficiently for arbitrarily high number of effective parameters and how it is related to weight tying. \subsection{Joint Input-Output Embedding} Let $g_{inp}(h_{t})$ and $g_{out}(e_{j})$ be two non-linear projections of $d_{j}$ dimensions of any translation context $h_{t}$ and any embedded output $e_{j}$, where $e_{j}$ is the j$_{th}$ row vector from the input embedding matrix E, which have the following form: \begin{gather} e_{j}' = g_{out}(e_{j}) = \sigma(U e_{j}^T + b_{u})\\ h_t' = g_{inp}(h_{t}) = \sigma( V h_{t} + b_{v}), \end{gather} \noindent where the matrix $U \in \rm I\!R^{d_j \times d}$ and bias $b_{u} \in \rm I\!R^{d_j}$ is the linear projection of the translation context and the matrix $V \in \rm I\!R^{ d_j \times d_h}$ and bias $b_{v} \in \rm I\!R^{d_j}$ is the linear projection of the outputs, and $\sigma$ is a non-linear activation function (here we use \code{Tanh}). Note that the projections could be high-rank or low-rank for $h_t'$ and $e'_{j}$ depending on their initial dimensions and the target joint space dimension. With $E' \in \rm I\!R^{|\mathcal{V}| \times d_{j}} $ being the matrix resulting from projecting all the outputs $e_j$ to the joint space, i.e. $g_{out}(E)$, and a vector $b \in \rm I\!R^{|\mathcal{V}|}$ which captures the bias for each output, the conditional output probability distribution of Eq~\ref{baseline_eq} can be re-written as follows: \begin{align} p&(y_t|y_1^{t-1},X) \label{jointeq} \\ & \propto \text{exp}\big( E' h_t' + b\big) \nonumber\\ & \propto \text{exp}\big( g_{out}(E) g_{inp}(h_t) + b\big) \nonumber\\ & \propto \text{exp}\big( \sigma(U E^T + b_{u})\, \sigma( V h_{t} + b_{v}) + b\big).\nonumber \end{align} \subsubsection{What Kind of Structure is Captured?} From the above formula we can derive the general form of the joint space which is similar to Eq.~\ref{nonlin} with the difference that it incorporates both components for learning output and context structure: \begin{equation} \underbrace{\sigma(E \mathcal{W}_{o})}_{\text{Output structure~~~}} \!\!\!\! \underbrace{\sigma( \mathcal{W}_{c} h_{t} )}_{\text{~~~Context structure}}, \label{oursgen} \end{equation} where $\mathcal{W}_{o} \in \rm I\!R^{d \times d_j}$ and $\mathcal{W}_{c} \in \rm I\!R^{d_j \times d_h}$ are the dedicated projections for learning output and context structure respectively (which correspond to $U$ and $V$ projections in Eq.~\ref{jointeq}). We argue that both nonlinear components are essential and validate this hypothesis empirically in our evaluation by performing an ablation analysis (Section \ref{ablation}). \subsubsection{How to Control the Effective Capacity?} The capacity of the model in terms of effective number of parameters ($\Theta_{joint}$) is: \begin{align} \mathcal{C}_{joint} \approx |\Theta_{joint}| = d \times d_j + d_j \times d_h + |\mathcal{V}|. \end{align} By increasing the joint space dimension $d_j$ above, we can now move freely between $\mathcal{C}_{bilinear}$ and $\mathcal{C}_{base}$ in Eq~.\ref{capacity_ineq} without depending anymore on the external factors ($d$, $d_h$, $|V|$) as follows: \begin{align} \mathcal{C}_{tied} < \mathcal{C}_{bilinear} \leq \mathcal{C}_{joint} \leq \mathcal{C}_{base}. \end{align} However, for very large number of $d_j$ the computational complexity increases prohibitively because the projection requires a large matrix multiplication between $U$ and $E$ which depends on $|\mathcal{V}|$. In such cases, we resort to sampling-based training, as explained in the next subsection. \begin{table*}[htp] \center \small {\def\arraystretch{1.5}\tabcolsep=3pt \begin{tabular}{p{1em}l ll ll ll ll} \hline & &\multicolumn{2}{c}{\textbf{En $\rightarrow$ Fi}} & \multicolumn{2}{c}{\textbf{Fi $\rightarrow$ En}} &\multicolumn{2}{c}{\textbf{En $\rightarrow$ De}} & \multicolumn{2}{c}{\textbf{De $\rightarrow$ En}} \\ & \textbf{Model} &\textbf{$|\Theta|$} & {BLEU} ($\Delta$) & \textbf{$|\Theta|$} & {BLEU} ($\Delta$) &\textbf{$|\Theta|$} & {BLEU} ($\Delta$) & \textbf{$|\Theta|$} & {BLEU} ($\Delta$) \\ \hline\hline \parbox[t]{1mm}{\multirow{3}{*}{\rotatebox[origin=c]{90}{ {32K} }}} & NMT & 60.0M & 12.68 (--) & 59.8M & 9.42 (--) & 61.3M & 18.46 (--) & 65.0M & 15.85 (--) \\ & NMT-\code{tied} & 43.3M & 12.58 (\textcolor{black}{$-0.10$}) & 43.3M & 9.59 ($+0.17$) & 44.9M & 18.48 ($+0.0$) & 46.7M & 16.51 ($+0.66$)$\dagger$ \\ & NMT-\code{joint} & 47.5M & \textbf{13.03} ($+0.35$)$\ddagger$ & 47.5M & \textbf{10.19} ($+0.77$)$\ddagger$ & 47.0M & \textbf{19.79} ($+1.3$)$\ddagger$ & 48.8M & \textbf{18.11} ($+2.26$)$\ddagger$ \\ \hline \parbox[t]{1mm}{\multirow{3}{*}{\rotatebox[origin=c]{90}{ {64K} }}} & NMT & 108.0M & 13.32 (--) & 106.7M & \textbf{12.29} (--) & 113.9M & 20.70 (--) & 114.0M & 20.01 (--) \\ & NMT-\code{tied} & 75.0M & 13.59 ($+0.27$) & 75.0M & 11.74 (\textcolor{black}{$-0.55$})$\ddagger$ & 79.4M & 20.85 (\textcolor{black}{$+0.15$}) & 79.4M & 19.19 (\textcolor{black}{$-0.82$})$\dagger$ \\ & NMT-\code{joint} & 75.5M & \textbf{13.84} ($+0.52$)$\ddagger$ & 75.5M & 12.08 ($-0.21$) & 79.9M & \textbf{21.62} ($+0.92$)$\ddagger$ & 79.9M & \textbf{20.61} ($+0.60$)$\dagger$ \\ \hline \parbox[t]{1mm}{\multirow{3}{*}{\rotatebox[origin=c]{90}{ {128K} ($\sim$) }}} & NMT & 201.1M & 13.52 (--) & 163.1M & 11.64 (--) & 211.3M & 22.48 (--) & 178.3M & 19.12 (--) \\ & NMT-\code{tied} & 135.6M & {13.90} ($+0.38$)$^*$ & 103.2M & 11.97 ($+0.33$)$^*$ & 144.2M & 21.43 ($-0.0$) & 111.6M & 19.43 ($+0.30$) \\ & NMT-\code{joint} & 137.7M & \textbf{13.93} ($+0.41$)$\dagger$ & 103.7M & \textbf{12.07} ($+0.43$)$\dagger$ & 146.3M & \textbf{22.73} ($+0.25$)$\dagger$ & 115.8M & \textbf{20.60} ($+1.48$)$\ddagger$ \\ \hline \end{tabular}} \caption{Model performance and number of parameters ($|\Theta|$) with varying BPE operations (32K, 64K, 128K) on the English-Finish and English-German language pairs. The significance of the difference against the NMT baseline with $p$-values $<$$.05$, $<$$.01$ and $<$$.001$ are marked with $^*$, $\dagger$ and $\ddagger$ respectively.} \label{tab:scores} \end{table*} \subsection{Sampling-based Training} To scale up to large output sets we adopt the negative sampling approach from \cite{mikolov2013distributed}. The goal is to utilize only a sub-set $\mathcal{V}'$ of the vocabulary instead of the whole vocabulary $\mathcal{V}$ for computing the softmax. The sub-set $\mathcal{V}'$ includes all positive classes whereas the negative classes are randomly sampled. During back propagation only the weights corresponding to the sub-set $\mathcal{V}'$ are updated. This can be trivially extended to mini-batch stochastic optimization methods by including all positive classes from the examples in the batch and sampling negative examples randomly from the rest of the vocabulary. Given that the joint space models generalize well on seen or unseen outputs \cite{yazdani2015model,Nam16}, we hypothesize that the proposed joint space will be more sample efficient than the baseline NMT with or without \textit{weight tying}, which we empirically validate with a sampling-based experiment in Section \ref{emb_size_effect} (Table \ref{tab:scores}, last three rows with $|\mathcal{V}| \approx 128K$). \subsection{Relation to \textit{Weight Tying}} The proposed joint input-output space can be seen as a generalization of \textit{\textit{weight tying}} ($W=E^T$, Eq.~\ref{baseline_eq}), because its degenerate form is equivalent to \textit{weight tying}. In particular, this can be simply derived if we set the non-linear projection functions in the second line of Eq.~\ref{jointeq} to be the identity function, $g_{inp}(\cdot) = g_{out}(\cdot) = I$, as follows: \begin{align} p(y_t|y_1^{t-1},X) & \propto \text{exp}\big( (I E) \ (I h_{t}) + b\big) \nonumber \\ & \propto \text{exp}\big( E h_{t} + b\big)\ \square. \label{gen} \end{align} Overall, this new parametrization of the output layer generalizes over previous ones and addresses their aforementioned challenges in Section \ref{challenges}. \section{Evaluation} \vspace{-2mm} We compare the NMT-\code{joint} model to two strong NMT baselines trained with and without \textit{weight tying} over four large parallel corpora which include morphologically rich languages as targets (Finnish and German), but also morphologically less rich languages as targets (English) from WMT 2017 \cite{bojar-EtAl:2017:WMT1}\footnote{\url{http://www.statmt.org/wmt17/}}. We examine the behavior of the proposed model under challenging conditions, namely varying vocabulary sizes, architecture depth, and output frequency. \subsection{Datasets and Metrics} The English-Finnish corpus contains 2.5M sentence pairs for training, 1.3K for development (Newstest2015), and 3K for testing (Newstest2016), and the English-German corpus 5.8M for training, 3K for development (Newstest2014), and 3K for testing (Newstest2015). We pre-process the texts using the BPE algorithm \cite{sennrich-haddow-birch:2016:P16-12} with 32K, 64K and 128K operations. Following the standard evaluation practices in the field \cite{bojar-EtAl:2017:WMT1}, the translation quality is measured using BLEU score \citep{papineni-EtAl:2002:ACL} (\emph{multi-blue}) on \emph{tokenized} text and the significance is measured with the paired bootstrap re-sampling method proposed by \cite{koehn-EtAl:2007:PosterDemo}.\footnote{\texttt{multi-bleu.perl} and \texttt{bootstrap-hypothe- sis-difference-significance.pl} scripts.} The quality on infrequent words is measured with METEOR \cite{denkowski:lavie:meteor-wmt:2014} which has originally been proposed to measure performance on function words. To adapt it for our purposes on English-German pairs ($|\mathcal{V}| \approx 32K$), we set as \emph{function words} different sets of words grouped according to three frequency bins, each of them containing $\frac{|\mathcal{V}|}{3}$ words of \textit{high}, \textit{medium} and \textit{low} frequency respectively and set its parameters to $\{0.85, 0.2, 0.6, 0.\}$ and $\{0.95, 1.0, 0.55, 0.\}$ when evaluating on English and German respectively. \vspace{0mm} \subsection{Model Configurations} The baseline is an encoder-decoder with 2 stacked LSTM layers on each side from OpenNMT \cite{klein-EtAl:2017:ACL-2017-System-Demonstrations}, but we also experiment with varying depth in the range $\{1, 2, 4, 8\}$ for German-English. The hyperparameters are set according to validation accuracy as follows: maximum sentence length of 50, 512-dimensional word embeddings and LSTM hidden states, dropout with a probability of 0.3 after each layer, and Adam \cite{kingma2014adam} optimizer with initial learning rate of 0.001. The size of the joint space is also selected on validation data in the range $\{512, 2048, 4096\}$. For efficiency, all models on corpora with $\mathcal{V}\approx 128K$ ($\sim$) and all \textit{structure-aware} models with $d_j \geq 2048$ on corpora with $\mathcal{V} \leq 64K$ are trained with 25\% negative sampling.\footnote{Training the models with a full 128K vocabulary without sampling runs out of memory on our machines.} \subsection{Translation Performance} Table \ref{tab:scores} displays the results on four translation sets from English-German and English-Finish language pairs when varying the number of BPE operations. The NMT-\code{tied} model outperforms the NMT baseline in many cases, but the differences are not consistent and it even scores significantly lower than NMT baseline in two cases, namely on Fi $\rightarrow$ En and De $\rightarrow$ En with $\mathcal{V}\approx 64K$. This validates our claim that the parametrization of the output space of the original NMT is not fully redundant, otherwise the NMT-\code{tied} would be able to match its BLEU in all cases. In contrast, the NMT-\code{joint} model outperforms consistently both baselines with a difference up to $+$2.2 and $+$1.6 BLEU points respectively,\footnote{Except in the case of Fi $\rightarrow$ En with $|\mathcal{V}| \approx 64K$, where the NMT baseline performed the best.} showing that the NMT-\code{tied} model has a more effective parametrization and retains the advantages of both baselines, namely sharing weights with the input embeddings, and dedicating enough parameters for generation. \begin{table} \centering {\def\arraystretch{1.25}\tabcolsep=1.3pt \begin{tabular}{l lllc }\hline & \textbf{Model} & \textbf{Layer form} & \textbf{BLEU} & $|\Theta|$ \\\hline & NMT & $W^Th_{t}$ & 15.85 &65.0M \\ & NMT-\code{tied} & $E h_{t}$ & 16.51 & 46.7M\\\hdashline \parbox[t]{3mm}{\multirow{5}{*}{\rotatebox[origin=c]{90}{ {NMT-\code{joint}} }}} & Eq.~\ref{eq:bilinear} & $E \mathcal{W} h_{t} $ & 16.23 & 47.0M \\ & Eq.~\ref{nonlin} a & $\sigma(E \mathcal{W}) h_{t} $ & 16.01 & 47.0M\\ & Eq.~\ref{nonlin} b & $E \sigma(\mathcal{W} h_{t}) $ & 17.52 & 47.0M\\ & Eq.~\ref{oursgen} (512) & $\sigma(E \mathcal{W}_{o}) \sigma( \mathcal{W}_{c} h_{t} )$ & 17.54 & 47.2M\\ & Eq.~\ref{oursgen} (2048) & $\sigma(E \mathcal{W}_{o}) \sigma( \mathcal{W}_{c} h_{t} )$ & \textbf{18.11} & 48.8M\\ \hline \end{tabular}} \caption{BLEU scores on De $\rightarrow$ En ($|\mathcal{V}| \approx 32K$) for the ablation analysis of NMT-\code{joint}.} \label{ablationres} \vspace{-5mm} \end{table} Overall, the highest scores correlate with a high number of BPE operations, namely 128K, 64K, 128K and 64k respectively. This suggests that the larger the vocabulary the better the performance, especially for the morphologically rich target languages, namely En $\rightarrow$ Fi and En $\rightarrow$ De. Lastly, the NMT baseline seems to be the least robust to sampling since its BLEU decreases in two cases. The other two models are more robust to sampling, however the difference of NMT-\code{tied} with the NMT is less significant than that of NMT-\code{joint}. \subsection{Ablation Analysis} \label{ablation} To demonstrate whether all the components of the proposed joint input-output model are useful and to which extend they contribute to the performance, we performed an ablation analysis; the results are displayed in Table \ref{ablationres}. Overall, all the variants of the NMT-\code{joint} outperform the baseline with varying degrees of significance. The NMT-\code{joint} with a bilinear form (Eq.~~\ref{eq:bilinear}) as in \cite{yazdani2015model,Nam16} is slightly behind the NMT-\code{tied} and outperforms the NMT baseline; this supports our theoretical analysis in Section \ref{weighttying} which demonstrated that \textit{weight tying} is learning an implicit linear structure similar to bilinear joint input-output models. \begin{figure}\vspace{-4mm} \centering \hspace{-3mm}\includegraphics[width=0.49\textwidth]{emb_size-vertical} \vspace{-3mm} \caption{BLEU scores for the NMT-\code{joint} model when varying its dimension ($d_j$) with $|\mathcal{V}| \approx 32K$. } \label{fig:emb_size} \vspace{-3mm} \end{figure} The NMT-\code{joint} model without learning explicit translation context structure (Eq.~\ref{nonlin} a) performs similar to the bilinear model and the NMT-\code{tied} model, while the NMT-\code{joint} model without learning explicit output structure (Eq.~\ref{nonlin} b) outperforms all the previous ones. When keeping same capacity (with $d_{j}{=}512$), our full model, which learns both output and translation context structure, performs similarly to the latter model and outperforms all the other baselines, including joint input-output models with a bilinear form \cite{yazdani2015model,Nam16}. But when the capacity is allowed to increase (with $d_{j}{=}2048$), it outperforms all the other models. Since both nonlinearities are necessary to allow us to control the effective capacity of the joint space, these results show that both types of structure induction are important for reaching the top performance with NMT-\code{joint}. \begin{figure*}[htbp] \centering \begin{subfigure}[b]{0.47\textwidth} \centering \includegraphics[width=0.84\textwidth]{meteor_en-de} \vspace{-1mm}\caption{Results on En $\rightarrow$ De ($|\mathcal{V}| \approx 32K$). } \label{fig:tied} \end{subfigure} \hspace{3mm} \begin{subfigure}[b]{0.47\textwidth} \centering \includegraphics[width=0.84\textwidth]{meteor_de-en} \vspace{-1mm}\caption[1]{Results on De $\rightarrow$ En ($|\mathcal{V}| \approx 32K$). } \end{subfigure} \vspace{-2mm} \caption[1]{METEOR scores (\%) on both directions of German-English language pair for all the models when focusing the evaluation on different frequency outputs grouped into three bins (high, medium, low).} \label{fig:outfreq} \vspace{-2mm} \end{figure*} \subsection{Effect of Embedding Size} \label{emb_size_effect} \textbf{Performance} Figure \ref{fig:emb_size} displays the BLEU scores of the proposed model when varying the size of the joint embedding, namely $d_{j} \in \{512, 2048, 4096\}$, against the two baselines. For English-Finish pairs, the increase in embedding size leads to a consistent increase in BLEU in favor of the NMT-\code{joint} model. For the English-German pairs, the difference with the baselines is much more evident and the optimal size is observed around 2048 for De $\rightarrow$ En and around 512 on En $\rightarrow$ De. The results validate our hypothesis that there is parameter redundancy in the typical output layer. However the ideal parametrization is data dependent and is achievable systematically only with the \code{joint} output layer which is capacity-wise in between the typical output layer and the \code{tied} output layer. \begin{table} \centering \begin{tabular}{ ll llll }\hline & & \multicolumn{3}{c}{{ \textbf{Sampling } }}\\ \textbf{Model} & $d_j$ & 50\% & 25\% & 5\% \\ \hline\hline NMT & - & 4.3K & 5.7K & 7.1K \\ NMT-\code{tied} & - & 5.2K & 6.0K & 7.8K \\ NMT-\code{joint} & 512 & 4.9K & 5.9K & 7.2K\\ NMT-\code{joint} & 2048 & 2.8K & 4.2K & 7.0K\\ NMT-\code{joint} & 4096 & 1.7K & 2.9K & 6.0K\\ \hline \end{tabular} \caption{Target tokens processed per second during training with negative sampling on En $\rightarrow$ De pair with a large BPE vocabulary $|\mathcal{V}| \approx 128K$.} \label{speed} \vspace{-4mm} \end{table} \textbf{Training speed} Table \ref{speed} displays the target tokens processed per second by the models on En $\rightarrow$ DE with $|\mathcal{V}|\approx 128K$ using different levels of negative sampling, namely 50\%, 25\%, and 5\%. In terms of training speed, the 512-dimensional NMT-\code{joint} model is as fast as the baselines, as we can observe in all cases. For higher dimensions of the joint space, namely 2048 and 4096 there is a notable decrease in speed which is remidiated by reducing the percentage of the negative samples. \begin{table*} \centering \begin{tabular}{ c ccccccccc }\hline \textbf{Model} & $d_j$ & \textbf{1-layer} & $|\Theta|$ & \textbf{2-layer} & $|\Theta|$ & \textbf{3-layer} & $|\Theta|$ & \textbf{4-layer} & $|\Theta|$ \\\hline NMT & - & 16.49 & 60.8M & 15.85 & 65.0M & 17.71 & 69.2M & 17.74 & 73.4M \\ NMT-\code{tied} & - &15.93 & 42.5M & 16.51 & 46.7M & 17.72 & 50.9M & 17.60 & 55.1M\\ NMT-\code{joint} & 512 &\textbf{16.93} & 43.0M & \textbf{17.54} & 47.2M & \textbf{17.83} & 51.4M& \textbf{18.13} & 55.6M\\ \hline \end{tabular} \caption{BLEU scores on De $\rightarrow$ En ($|\mathcal{V}| \approx 32K$) for the NMT-\code{joint} with $d_j=512$ against baselines when varying the depth of both the encoder and the decoder of the NMT model.} \label{depth} \end{table*} \subsection{Effect of Output Frequency and Architecture Depth} Figure \ref{fig:outfreq} displays the performance in terms of METEOR on both directions of German-English language pair when evaluating on outputs of different frequency levels (high, medium, low) for all the competing models. The results on De $\rightarrow$ EN show that the improvements brought by the NMT-\code{joint} model against baselines are present consistently for all frequency levels including the low-frequency ones. Nevertheless, the improvement is most prominent for high-frequency outputs, which is reasonable given that no sentence filtering was performed and hence frequent words have higher impact in the absolute value of METEOR. Similarly, for En $\rightarrow$ De we can observe that NMT-\code{joint} outperforms the others on high-frequency and low-frequency labels while it reaches parity with them on the medium-frequency ones. We also evaluated our model in another challenging condition in which we examine the effect of the NMT architecture depth in the performance of the proposed model. The results are displayed in Table \ref{depth}. The results show that the NMT-\code{joint} outperforms the other two models consistently when varying the architecture depth of the encoder-decoder architecture. The NMT-\code{joint} overall is much more robust than NMT-\code{tied} and it outperforms it consistently in all settings. Compared to the NMT which is overparametrized the improvement even though consistent it is smaller for layer depth 3 and 4. This happens because NMT has a much higher number of parameters than NMT-\code{joint} with $d_j{=}512$. Increasing the number of dimensions $d_j$ of the joint space should lead to further improvements, as shown in Fig.~2. In fact, our NMT-\code{joint} with $d_j=2048$ reaches 18.11 score with a 2-layer deep model, hence it outperforms all other NMT and NMT-\code{tied} models even with a deeper architecture (3-layer and 4-layer) regardless of the fact that it utilizes fewer parameters than them (48.8M vs 69.2-73.4M and 50.9-55.1M respectively). \section{Related Work} Several studies focus on learning joint input-output representations grounded to word semantics for zero-shot image classification \citep{Weston2011,Socher13,ZhangGS16}, but there are fewer such studies for NLP tasks. \citep{yazdani2015model} proposed a zero-shot spoken language understanding model based on a bilinear joint space trained with hinge loss, and \citep{Nam16}, proposed a similar joint space trained with a WARP loss for zero-shot biomedical semantic indexing. In addition, there exist studies which aim to learn output representations directly from data such as \citep{Srikumar14,YehWKW17,augenstein18}; their lack of semantic grounding to the input embeddings and the vocabulary-dependent parametrization, however, makes them data hungry and less scalable on large label sets. All these models, exhibit similar theoretical limitations as the softmax linear unit with \textit{weight tying} which were described in Sections 2.2. To our knowledge, there is no existing study which has considered the use of such joint input-output labels for neural machine translation. Compared to previous joint input-label models our model is more flexible and not restricted to linear mappings, which have limited expressivity, but uses non-linear mappings modeled similar to energy-based learning networks \citep{belanger16}. Perhaps, the most similar embedding model to ours is the one by \citep{pappas_18a}, except for the linear scaling unit which is specific to sigmoidal linear units designed for multi-label classification problems and not for structured prediction, as here. \section{Conclusion and Perspectives} We proposed a re-parametrization of the output layer for the decoder of NMT models which is more general and robust than a softmax linear unit with or without \textit{\textit{weight tying}} with the input word embeddings. Our evaluation shows that the \textit{structure-aware} output layer outperforms \textit{\textit{weight tying}} in all cases and maintains a significant difference with the typical output layer without compromising much the training speed. Furthermore, it can successfully benefit from training corpora with large BPE vocabularies using negative sampling. The ablation analysis demonstrated that both types of structure captured by our model are essential and complementary, as well as, that their combination outperforms all previous output layers including those of bilinear input-output embedding models. Our further investigation revealed the robustness of the model to sampling-based training, translating infrequent outputs and to varying architecture depth. As future work, the \textit{structure-aware} output layer could be further improved along the following directions. The computational complexity of the model becomes prohibitive for a large joint projection because it requires a large matrix multiplication which depends on $|\mathcal{V}|$; hence, we have to resort to sampling based training relatively quickly when gradually increasing $d_j$ (e.g.~for $d_j >= 2048$). A more scalable way of increasing the output layer capacity could address this issue, for instance, by considering multiple consecutive additive transformations with small $d_j$. Another useful direction would be to use more advanced output encoders and additional external knowledge (contextualized or generically defined) for both words and sub-words. Finally, to encourage progress in joint input-output embedding learning for NMT, our code is available on Github: \url{http://github.com/idiap/joint-embedding-nmt}. \section*{Acknowledgments} We are grateful for the support from the European Union through its Horizon 2020 program in the SUMMA project n.\ 688139, see \url{http://www.summa-project.eu} and for the valuable feedback from the anonymous reviewers.
\section{Introduction} Electrons on helium form a strongly correlated nondegenerate liquid or a Wigner crystal. The profound effects of electron correlations have been studied at length theoretically and experimentally \cite{Andrei1997,Monarkha2004}. However, the detailed dynamics of the electrons in the liquid has been explored only indirectly, through its effects on the behavior at the wavelengths long compared to the interlectron distance, such as magnetotransport, tunneling, and a number of resonant nonlinear phenomena \cite{Menna1993,Dykman1993i,Lea1997,Dykman2001a,Konstantinov2009,Konstantinov2013,Chepelianskii2015}. An insight into the short-wavelength dynamics has been coming from modeling the system, and a significant number of molecular dynamics simulations and Monte Carlo simulations have been done over the last four decades, cf. \cite{Totsuji1978,Gann1979,Hansen1979,Morf1979,Kalia1981,Kalia1983,Strandburg1988,FangYen1997,Muto1999,Piacente2005,Clark2009,damasceno2010, Rees2012,Mazars2015,Khrapak2018}. Much of the emphasis was placed on the melting transitions and the occurrence of the hexatic phase. The recent Monte Carlo results for a record large system indicate that the hexatic phase emerges, but only in a vary narrow range of temperatures \cite{Mazars2015}. An advantageous feature of molecular dynamics simulations is that they allow one to see how the electron system evolves in time. However, so far such simulations were done using either Langevin equations of motion with a phenomenologically added friction force, which does not describe the electron dynamics on helium, or using a comparatively short thermalization time, which may be insufficient, at least in the transition region (for example, in the Monte Carlo simulations \cite{Mazars2015} a much longer equilibration time was used). In this paper we develop a numerical algorithm that allows one to take into account the actual microscopic mechanism of the electron scattering off the excitations in helium along with the long-range electron-electron interaction. Using this algorithm, we perform molecular dynamics simulations of a large electron system comprised of 1600 electrons with periodic boundary conditions. To the best of our knowledge, this is the largest system used in molecular dynamics simulations of two-dimensional electron systems. An important characteristic of the electron dynamics is the coefficient of self-diffusion. It describes the motion of individual electrons on a mesoscopic scale that exceeds the interelectron spacing, but is small on the macroscopic scale. We study self-diffusion in the presence of electron scattering by helium excitations. It should be emphasized that the coefficient of self-diffusion is not described by the standard Einstein relation between diffusion and mobility, which refers to the macroscopic diffusion and the long-wavelength mobility. A characteristic feature of the electron system is that it remains a liquid where the ratio $\Gamma$ of the electron-electron interaction energy $E_C$ to the kinetic energy is very large, \begin{align} \label{eq:Gamma} \Gamma = E_C/k_BT, \qquad E_C=e^2(\pi n_s)^{1/2}. \end{align} Here, $n_s$ is the electron density and $T$ is temperature. For $\Gamma\gg 1$ self-diffusion should reflect a correlated motion in the system. Diffusive motion should largely stop once the system crystallizes, and therefore the self-diffusion coefficient is an important indicator of crystallization. We find that it goes to zero extremely sharply which, we believe, is also a consequence of the strong electron correlations. The peculiar features of the transition are due to the long-range electron-electron interaction and the absence of long-wavelength longitudinal acoustic phonons in the electron crystal. Electrons on helium is a unique condensed-matter system in that it allows studying many-body phenomena that are not masked by disorder due to impurities and other defects present in solid-state systems. An important group of these phenomena are related to commensurate-incommensurate transitions \cite{Bak1982}. They occur where a crystalline monolayer is placed on a crystalline substrate with close lattice spacing \cite{Pokrovskii1980}. The commensurate-incommensurate transitions occur also in a macroscopic system of colloidal particles in a periodic potential created by laser radiation \cite{Wei1998,Radzihovsky2001}. The motion of colloidal particles is usually overdamped, and therefore the dynamics is qualitatively different from that of solid-state systems. For electrons on helium, a tunable periodic potential can be created by placing a periodic structure beneath the helium surface. Most interesting effects are expected to occur for a structure with a period on the order of the interelectron distance. Since this distance is $\sim 1\,\mu$m, such a structure can be made using standard fabrication techniques. A periodic potential can significantly, and nontrivially, affect not only the electron solid, but also a strongly correlated electron liquid, and in particular the dynamics of the electron liquid. This should happen just because the spatial structure of the liquid should be sensitive to a periodic potential where the period is close to the interelectron distance. Self-diffusion is a natural characteristic of the changes in the dynamics. The first molecular dynamics simulations of self-diffusion in a periodic potential were described in the interesting paper \cite{Kalia1983}. The results were obtained for a system of 256 electrons, with no coupling to helium excitations, for $\Gamma=36$ and for several values of the integer and half-integer ratio of the distance between the electron rows in the Wigner crystal and the modulation period. In this paper we study self-diffusion and freezing of the electron system on helium placed in a one-dimensional (1D) potential. The potential slows down the dynamics, and we found that obtaining reliable statistics requires very long simulations. We find that the electron thermalization improves when scattering by the helium excitations is taken into account. Our simulations allow us to characterize the anisotropy of self-diffusion close to the commensurability of the periodic potential, including the detailed dependence of the self-diffusion coefficients on the control parameter $\Gamma$. In Sec.~2 we describe the model and the algorithm of the numerical integration that takes into account elastic and inelastic scattering of electrons on the helium surface. In Sec.~3 we describe self-diffusion and its sharp change at the freezing transition in the absence of a periodic potential. We also describe the short-wavelength structure factor. In Sec. 4 we study self-diffusion in an external 1D periodic potential, which is maximally commensurate with the electron crystal. We show that, for a Wigner crystal in such a potential, the mean-square electron displacement from the lattice site does not diverge, which leads to a qualitative change of the liquid to solid transition. We show that the diffusion becomes strongly anisotropic and study its dependence on $\Gamma$ and the amplitude of the periodic potential. In Sec. 5 we study the diffusion in the system where the potential is close to maximal commensurability. We also explore the possiblity of the onset of a lattice of solitons in the electron density close to maximal commensurability. Section 6 contains concluding remarks. \section{Model of the electron system and the numerical approach} \label{sec:model} \subsection{The Hamiltonian} We consider a two-dimensional (2D) many-electron system with the Coulomb electron-electron interaction. The system is placed into an external one-dimensional periodic potential $U(x)$. The electrons are interacting with surface capillary waves on helium, ripplons, and with phonons in helium. The Hamiltonian is \begin{align} \label{eq:Hamiltonian} &H=H_{ee} + H_U + H_{\mathrm He} + H_i, \quad H_{ee} = \sum_n\frac{\boldsymbol{p}_n^2}{2m} + \frac{1}{2}\sum_{n\neq m}\frac{e^2}{|\bf r_n-\bf r_m|},\nonumber\\ &H_U = \sum_n U(\bf r_n), \quad H_{\mathrm He} = \hbar\sum_{\boldsymbol{q},q_z}\omega_{\boldsymbol{q},q_z}a^\dagger_{\boldsymbol{q},q_z} a_{\boldsymbol{q},q_z} + \hbar\sum_{\boldsymbol{q}}\omega_{\boldsymbol{q}} b^\dagger_{\boldsymbol{q}} b_{\boldsymbol{q}} \end{align} Here, $\bf r_n$ and $\boldsymbol{p}_n$ are the 2D coordinate and momentum of an $n$th electron, $U(\bf r)$ is the external potential, $a_{\boldsymbol{q},q_z}$ is the annihilation operator of a phonon in helium with 2D wave vector $\boldsymbol{q}$ and the wave number $q_z>0$ of motion transverse to the surface, $\omega_{\boldsymbol{q},q_z}$ is the phonon frequency, $b_{\boldsymbol{q}}$ is the ripplon annihilation operator, and $\omega_{\boldsymbol{q}}$ is the ripplon frequency. To calculate the electron-phonon coupling, one should keep in mind that the density modulation $\delta\rho_{\rm He}$ in the phonon field as a function of the in-plane coordinate $\bf r$ and the coordinate $z$ normal to the surface is \[\delta\rho_{\rm He}(\bf r, z) =-i\sum_{\boldsymbol{q},q_z} (\hbar \rho_{\rm He}\omega_{\boldsymbol{q},q_z}/Vv_{\rm He}^2)^{1/2}e^{i\boldsymbol{q}\bf r} \sin (q_z z)(a_{\boldsymbol{q},q_z}- a^\dagger_{-\boldsymbol{q},qz}),\] where $V$ is the helium volume and $v_{\rm He}$ is the sound velocity. Ripplons are very soft excitations. For typical wave vectors of the ripplons that scatter electrons $\boldsymbol{q} \sim \boldsymbol{p}/\hbar$ the ripplon energy $\hbar\omega_{\boldsymbol{q}}$ is much smaller than the electron energy. Therefore scattering by ripplons is essentially elastic. Inelastic scattering comes from two-ripplon processes and from scattering by phonons. Generally, these two mechanisms give comparable scattering rates, with the phonon scattering rate being slightly higher. However, the overall rate of inelastic scattering is orders of magnitude smaller than the rate of elastic scattering, for thermal electron energies \cite{Andrei1997}. In our analysis the role of inelastic scattering is to make sure the electron energy distribution remains close to equilibrium, and therefore it suffices to take into account just one mechanism of inelastic scattering, which we chose to be the scattering by phonons. Respectively, we consider one-ripplon and one-phonon coupling, \begin{align} \label{eq:coupling} H_i = \sum_n\sum_{\boldsymbol{q}}V_{\boldsymbol{q}}^{\mathrm {(rp)}}(z_n)e^{i\boldsymbol{q}\bf r_n}(b_{\boldsymbol{q}}+b_{-\boldsymbol{q}}^\dagger) + \sum_n\sum_{\boldsymbol{q},q_z}V_{\boldsymbol{q},q_z}^{\mathrm {(ph)}}(z_n)e^{i\boldsymbol{q}\bf r_n}(a_{\boldsymbol{q},q_z}- a^\dagger_{-\boldsymbol{q},q_z}) \end{align} The parameters $V_{\boldsymbol{q}}^{\mathrm {(rp)}}(z)$ and $V_{\boldsymbol{q},q_z}^{\mathrm {(ph)}}(z)$ of the coupling to ripplons and to phonons as functions of the distance $z>0$ of the electron from the helium surface are well-known \cite{Andrei1997,Dykman2003,Schuster2010a}. We will be interested in the case of a weak field that presses electrons to the surface. Respectively, we keep in $H_i$ only the terms related to the change of the image potential by the vibrational excitations; moreover, in the case of the coupling to phonons, we keep only the terms related to the phonon-induced spatial modulation of the helium dielectric constant [which is $\propto \delta \rho_{\rm He}(\bf r,z)$]; the effect of the phonon-induced change of the shape of the helium surface is comparable, but somewhat smaller. Then \begin{align} \label{eq:matrix_elements} &V_{\boldsymbol{q}}^{\mathrm {(rp)}}(z)=\Lambda\frac{(\hbar q)^{1/2}}{(2\rho\omega_{\boldsymbol{q}}S)^{1/2}}\left\{z^{-2}[1-qz K_1(qz)]\right\}_z,\nonumber\\ &V_{\boldsymbol{q},q_z}^{\mathrm {(ph)}}(z)=-i\Lambda q(\hbar\omega_{\boldsymbol{q},q_z}/V v_{\rm He}^2\rho_{\rm He})^{1/2}\int_{-\infty}^0 dz'\frac{\sin (q_z z')}{z-z'}K_1\bigl(q(z-z')\bigr) \end{align} Here $\Lambda = e^2(\epsilon -1)/4(\epsilon+1)$ ($\epsilon$ is the dielectric constant of helium, $\epsilon\approx 1.057$) and $K_1(x)$ is the Bessel function; the expression for $V^{\mathrm (ph)}_{\boldsymbol{q},q_z}(z)$ corrects the typos in the corresponding expression in Refs.~\cite{Dykman2003, Schuster2010a}. \subsection{Many-electron dynamics} Strong correlations in the electron system can affect the electron scattering by ripplons and phonons. However, this effect is small in the absence of a magnetic field provided the electron dynamics is classical \cite{Dykman1997a}. The typical duration of a scattering event (collision) $t_{\rm coll}$ is determined by the kinetic energy of an electron, $t_{\rm coll} \sim \hbar/k_BT$. The kinetic energy is not a good quantum number because of the electron-electron interaction. The uncertainty of the kinetic energy of an electron is equal to the uncertainty of its potential energy in the electric field $E_{\rm fl}$ created by other electrons. This uncertainty is $\sim eE_{\rm fl}\lambda_T$, where $\lambda_T = \hbar/(mk_BT)^{1/2}$ is the thermal wavelength and thus the uncertainty in the electron position. In a strongly correlated system one can estimate $E_{\rm fl}$ assuming that electrons form a crystal and $eE_{\rm fl}$ is a characteristic force on an electron performing small-amplitude vibrations about its equilibrium position (only short-range order is essential for the estimate of $E_{\rm fl}$ \cite{FangYen1997}). This gives $E_{\rm fl}\sim (k_BT n_s^{3/2})^{1/2}$. One can disregard the effect of the electron-electron interaction on collisions with ripplons and phonons if the duration of a collision is small compared to the characteristic time over which the electron kinetic energy is changed by the electron-electron interaction and the uncertainty of the kinetic energy is small compared to $\hbar/t_{\mathrm coll}$. From the above estimate, both conditions are satisfied if \begin{align} \label{eq:classical_dynamics} \hbar\omega_p\ll k_BT, \qquad \omega_p = (2\pi e^2n_s^{3/2}/m)^{1/2}. \end{align} Parameter $\omega_p$ is the short-wavelength plasma frequency of the electron system. This is also the short-wavelength phonon frequency in a Wigner crystal. The condition (\ref{eq:classical_dynamics}) shows that the electron dynamics is classical. We note that this condition must be satisfied where Monte Carlo or molecular dynamics simulations are used to determine the temperature of the transition into a Wigner crystal. In fact, it limits the numerical results on the crystallization to densities $n_s\lesssim 5\times10^7$~cm$^{-2}$, which is often lower than the densities where the crystallization is observed in the experiment. In our simulations we kept the effective density fixed, which corresponds to keeping $\omega_p$ fixed; different values of the plasma parameter $\Gamma$ correspond to different values of the temperature. It should be noted that the ``dynamical classicality condition'' (\ref{eq:classical_dynamics}) differs from the conventional condition that the electron system is classical if the Fermi energy $\varepsilon_F= \pi\hbar^2 n_s/2m $ is small compared to $k_BT$. Indeed, the latter condition does not take into account the effect of the electron-electron interaction. One can see that $\varepsilon_F/k_BT = (\sqrt{\pi}/4)(\hbar\omega_p/k_BT)^2 \Gamma^{-1}$. Therefore in the strongly correlated regime the inequality (\ref{eq:classical_dynamics}) is far more restrictive than $\varepsilon_F\ll k_BT$. \subsubsection{Integrating equations of motion} \label{sec:integrating} We performed molecular dynamics-type simulations of the many-electron system assuming that collisions with ripplons and phonons are instantaneous. The collisions happen at random and are not correlated. They are characterized by the rate $w(\boldsymbol{k} \to \boldsymbol{k}')$ of electron scattering from the state with a given wave vector $\boldsymbol{k}$ into the state with the wave vector $\boldsymbol{k}'$ [$w(\boldsymbol{k}\to \boldsymbol{k}')$ is the probability density per unit time and per unit area in the $\boldsymbol{k}'$-space]. This rate is given by the Fermi golden rule. Scattering by ripplons is elastic, and for this process $|\boldsymbol{k}'| = |\boldsymbol{k}|$ and the scattering rate $w(\boldsymbol{k}\to\boldsymbol{k}')$ depends only on the angle between $\boldsymbol{k}$ and $\boldsymbol{k}'$. Scattering by phonons is inelastic. The scattering rate $w^{\rm (ph)}(\boldsymbol{k}\to\boldsymbol{k}')$ is calculated on a grid in the space of the wave vectors $\boldsymbol{k}$ and $\boldsymbol{k}'$. Importantly, the change of the electron velocity in a collision $\hbar (\boldsymbol{k}' - \boldsymbol{k})/m$ is large, of the order of the velocity itself. The rate $w^{\rm (ph)}(\boldsymbol{k}\to\boldsymbol{k}')$ as function of $\boldsymbol{k}'$ is shown in Fig.~\ref{fig:wkkp_phonon} for several values of $\boldsymbol{k}$. The calculation involves integration over the transverse to the surface component of the phonon wave vector. Function $w^{\rm (ph)}(\boldsymbol{k}\to\boldsymbol{k}')$ depends on temperature,we plot it by scaling $\boldsymbol{k}$ and $\boldsymbol{k}'$ by the thermal wave number $k_T=(2mk_BT)^{1/2/}\hbar$. \begin{figure}[h] \centering \includegraphics[width =\textwidth]{Fig1_scattering.pdf} \caption{\small The rate of scattering by phonons $w^{(\mathrm{ph})}(\boldsymbol{k}\to \boldsymbol{k}')$ as a function of $\boldsymbol{k}'$. The left, central, and right panels refer to $\boldsymbol{k}/k_T = (0.6, 0)$, $\boldsymbol{k}/k_T = (1, 0)$, and $\boldsymbol{k}/k_T = (1.4, 0)$, respectively. Vector $\boldsymbol{k}$ is shown by a red cross. The color shows $ k_T^2w^{(\mathrm{ph})}(\boldsymbol{k}\to \boldsymbol{k}')$ in s$^{-1}$. The scattering rate vanishes at points where $|\boldsymbol{k}'| = |\boldsymbol{k}|$. The plot refers to $T=0.3$~K.} \label{fig:wkkp_phonon} \end{figure} The simulations are done by discretizing the time and assuming that, at equidistant instants $t_i$, there is a probability for an electron to change its velocity due to a collision with ripplons and phonons from $\hbar\boldsymbol{k}/m$ to $\hbar\boldsymbol{k}'/m$; it is given by $(t_{i+1} - t_i)w(\boldsymbol{k} \to \boldsymbol{k}')d\boldsymbol{k}'$. In the considered classical approximation, a collision is not accompanied by a change of the electron position. In the interval between $t_i$ and $t_{i+1}$ an electron is accelerated by the Coulomb force from other electrons. The difference in the position of an electron at instants $t_i$ and $t_{i+1}$ is calculated using the electron velocity at $t_i+0$ (i.e., with the account of the possible scattering at time $t_i$), which is incremented by the acceleration calculated for the positions of all electrons at time $t_i$ and multiplied by $(t_{i+1}-t_i)/2$. The discretized equations of motion are given in Appendix~\ref{sec:appA}. We consider electrons in the rectangular region with the size ratio $L_x/L_y=\sqrt{3}/2$ and impose periodic boundary conditions. When an electron leaves the main rectangle, it is injected on the other side of it. The geometry is chosen in such a way as to fit a triangular electron lattice into the main rectangle. Respectively, the mean inter-electron distance is $a_s =(2/n_s\sqrt{3})^{1/2} =L_y/N^{1/2}$, where $N$ is the number of electrons in the main rectangle and $N^{1/2}$ is an integer. Our simulations were carried out for $N=1600$. To allow for the long-range interaction, the Coulomb force on an electron and the energy of the system are calculated using the Ewald summation in two dimensions, cf. \cite{Gann1979}. We tabulate the electric field from an electron and its periodically repeated images on a $2000\times 2000$ grid that covers the rectangle of size $(L_x/2,L_y/2)$, assuming that the electron is at the origin; the field at a general point is interpolated from the grid. We choose the external periodic potential $U(\bf r)$ to be one-dimensional. This is the easiest form of a periodic potential that can be implemented in the experiment. It is constant along the $y$-coordinate, i.e., $U(\bf r)\equiv U(x)$. To maintain the periodicity of the system, the period of $U(x)$ is set to be $L_x/M$ with an integer $M$. \section{Diffusion in a spatially uniform electron system} \label{sec:uniform} To calculate electron diffusion we keep track of the actual electron position in the extended system, that is, to find the electron displacement, the position after re-injection into the main rectangle is incremented by the length of the corresponding side of the rectangle. We calculate the displacement along the $x$ and $y$ axes separately. For a long calculation time of $10^7$ steps, the mean square displacement in the both directions is proportional to time. The proportionality coefficients are the coefficients of self-diffusion $D_x$ and $D_y$ along the shorter and the longer sides of the main rectangle, respectively. Note that these are not the long-wavelength diffusion coefficients that describe the density current in response to a smooth electron density gradient. Therefore they are finite even in the absence of electron scattering by ripplons and phonons. A natural scale for the self-diffusion coefficient in the electron liquid is \begin{align} \label{eq:diffusion_scale} D_0=k_BT/m\omega_p \equiv \Gamma^{-1} (e^2/2m\sqrt{n_s})^{1/2} . \end{align} This value is obtained by taking into account that the liquid is strongly correlated for all values of the plasma parameter $\Gamma \gg 1$, and therefore it has a pronounced short-range order. The mean-square thermal displacement of an electron about its quasi-equilibrium position in the liquid is of the same order of magnitude as if the electrons formed a crystal, $\sim k_BT/m\omega_p^2$, whereas the typical dynamical time in the strongly correlated system is $\omega_p^{-1}$, cf. Eq.~(\ref{eq:classical_dynamics}). The estimate (\ref{eq:diffusion_scale}) is close to the De Gennes estimate \cite{Gennes1959} of the self-diffusion coefficient in liquids. Instead of $\omega_p$, De Gennes used a parameter of the same order of magnitude that depends on the pair correlation function of the liquid, which makes it temperature-dependent; however, the electron liquid that we study is quite different from a normal liquid, because it is two-dimensional and the electron-electron interaction is long-range; therefore we do not compare our results with the theory \cite{Gennes1959}. The self-diffusion coefficients $D_x$ and $D_y$ are shown in Fig.~\ref{fig:diff_isotropic}(a) for a broad range of $\Gamma$. The finite amount of data used to average the squared displacements leads to an uncertainty in the coefficients $D_{x,y}$. The uncertainty is manifested as the spread of the data points in Fig. \ref{fig:diff_isotropic}(a). It decreases with the increasing system size or the simulation time. In the absence of the periodic potential, $D_x$ and $D_y$ are close to each other, but $D_x$ is systematically slightly larger, which reflects the anisotropy imposed by the periodic boundary conditions with different lengths in the $x$ and $y$ directions. It is seen that both $D_x$ and $D_y$ remain on the order of $D_0$ and the ratios $D_x/D_0, D_y/D_0$ smoothly depend on $\Gamma$ in a broad range $25\lesssim \Gamma\lesssim 90$. \begin{figure}[h] \centering \includegraphics[height=4.5truecm]{Fig2a_diffu_free_brod_range.pdf}\hspace*{0.3in} \includegraphics[height=4.5truecm]{Fig2b_g_r_free.pdf} \\ \includegraphics[height=4.5truecm]{Fig2c_diffu_free_120_150.pdf} \qquad \includegraphics[height=4.5truecm]{Fig2d.pdf} \caption{\small (a): The coefficients of self-diffusion $D_x$ and $D_y$ as functions of $\Gamma$. For each point $\Gamma$, the system is prepared as a triangular lattice that fits the main rectangle with the side ratio $L_x/L_y=\sqrt{3}/2$. The initial density is the same for all $\Gamma$, but the initial velocities are random. Then the system is equilibrated for $10^6$ time steps before collecting data for another $10^7$ steps. The simulation is carried out with the account taken of the both elastic and inelastic scattering by the excitations in helium. The electron temperature, and thus the value of $\Gamma$, is calculated after the equilibration period from the electron kinetic energy as $T=(m/2Nk_B)\sum {\bf v}_n^2$, where ${\bf v}_n$ is the velocity of the $n$th electron; it coincides with the temperature of phonons in helium. (b) The radial pair correlation function for the considered system of 1600 electrons with periodic boundary conditions. (c) The same as in (a), with higher resolution in the region of transition from the crystal to the liquid, (d) The diffusion coefficients in the transition region obtained by preparing the system initially in a spatially disordered state and letting the electrons come to equilibrium with the phonons at the chosen temperature, which requires $\lesssim 7\times 10^5$ steps. } \label{fig:diff_isotropic} \end{figure} With the increasing $\Gamma$, the correlation length in the system increases, cf. \cite{Gann1979}. This is seen in Fig.~\ref{fig:diff_isotropic}(b), which shows the radial distribution function \[g(r) =[2\pi r n_s N(N-1)]^{-1}\sum_{n\neq m}\delta(r-|\bf r_n-\bf r_m|) .\] The electron liquid becomes more ``rigid'' with the increasing correlation length. Respectively, the ratio $D_{x,y}/D_0$ decreases. Ultimately both $D_x$ and $D_y$ simultaneously sharply drop to zero, within the simulation precision. The transition to zero diffusion manifests crystallization of the system. The dependence of $D_{x,y}$ on $\Gamma$ in the transition region is shown in Fig.~\ref{fig:diff_isotropic}(c) and (d). We have found that the value of $\Gamma$ where the transition occurs depends on the size of the system and increases with the increasing size. This agrees with the conclusion drawn from the Monte Carlo simulations \cite{Mazars2015}. For 1600 electrons the transition region is $\Gamma \approx 137\pm 1$. The results of two different Monte Carlo simulations led to the conclusions that the transitions between the Wigner crystal and the hexatic phase is of the first order \cite{Clark2009} and the transition between the hexatic phase and the liquid is also a first order transition \cite{Mazars2015}. The sharp decrease of the diffusion coefficient in a narrow range of $\Gamma$ agrees with these conclusions. However, a comparison of Figs.~\ref{fig:diff_isotropic}(c) and (d) shows that there is no observable hysteresis when the system changes from the solid to the liquid phase and vice versa. This may be related to the uncertainty in the value of the diffusion coefficient and can be understood from the Monte Carlo result \cite{Mazars2015}, which suggests that the hexatic phase exists only in a very narrow range of $\Gamma$. The spread of the values of the diffusion coefficients does not allow us to resolve this range. The sharp increase of $D_{x,y}$ with decreasing $\Gamma$ in the region of the transition from the Wigner crystal to the electron liquid is a consequence of the sharp increase of the density of topological defects in this region. This is seen from Fig.~\ref{fig:triangulation}. The number of unbound dislocations and vortices, which correspond to isolated regions where an electron has more or less than 6 nearest neighbors, sharply increases with decreasing $\Gamma$ below the transition. When the density of these defects is small, the diffusion coefficient is approximately proportional to this density. When the density jumps up at the transition, so does also the diffusion coefficient. For somewhat smaller $\Gamma$, i.e., further away but not too far from the transition, the defect density is still low, but keeps increasing with the decreasing $\Gamma$. This is behind the superlinear increase of $D_{x,y}/D_0$ with the decreasing $\Gamma$ close to the transition. Once the density of defects is no longer small, the dependence of $D_{x,y}/D_0$ on $\Gamma$ becomes smooth. We remind that the simulations have been performed for constant electron density and the change of $\Gamma$ corresponds to the change of the temperature, with $D_0\propto T\propto \Gamma^{-1}$. \begin{figure}[h] \centering \includegraphics[height=4.5truecm]{Fig3a_Delaunay_120_150.pdf} \qquad \includegraphics[height=4.5truecm]{Fig3b_Delaunay_120-150.pdf} \caption{\small Delaunay triangulation of the electron positions for a portion of the system with $N=1600$ electrons in the presence of scattering by ripplons and phonons. Electrons are represented by vertices. The red vertices are electrons with five nearest neighbors, the green vertices are electrons with seven nearest neighbors. Pairs of red and green vertices represent dislocations. (a) Liquid phase with $\Gamma =133$ close to the freezing transition, the self-diffusion coefficients are $D_x \approx D_y\approx 0.2 D_0$. There are unbound dislocations, pairs of bound dislocations, and unbound vortices with 5 or 7 nearest neighbors. (b) Solid phase with $\Gamma =140$ and $D_x = D_y = 0$. Only bound pairs of dislocations are present in the solid.} \label{fig:triangulation} \end{figure} It should be noted that, sufficiently far from the region of the liquid to solid transition. the results on the diffusion coefficients in the presence of weak scattering by ripplons and phonons are very close to the results with no scattering However, in the transition region there is a difference. A discussion of this difference and its origin is beyond the scope of this paper. \section{One-dimensional commensurate periodic potential} \label{sec:commensurte} \subsection{The commensurability parameter} In this and the following sections we consider self-diffusion in the electron liquid placed into a periodic potential \begin{align} \label{eq:potential} U(x)=-A\cos Qx, \qquad Q=2\pi M/L_x, \end{align} where $M$ is an integer. Such form of a potential describes the potential from a periodic structure with period $2\pi/Q$ submerged beneath the helium surface by depth that exceeds $2\pi/Q$, in which case higher spatial harmonics of the potential can be safely disregarded. Parameter $A$ characterizes the strength of the modulation. A natural scale for $A$ is $k_BT$. The solid-state structure, which creates the potential $U(x)$ in the electron layer, modifies the electron-electron interaction, because it leads to an image potential. If the structure is submerged by the depth of $4\pi/Q$, for example, and the voltage on the structure is 10~V, we have $A/k_B \approx 0.4$~K. The image potential depends on the details of the structure and, for a dielectric structure with a periodic set of interdigitized metal nanowires, the long-range Coulomb inter-electron potential will not be fully screened. As a result, as we discussed, the transitions between different phases of the electron system differ from those in system with short-range potential, cf.~\cite{Clark2009,Mazars2015}. To reveal the features of the electron dynamics on the helium surface related to the interplay of a periodic potential and the long-range electron-electron coupling, in this work we disregard the screening. In our simulations the electron density $n_s$ is fixed, and then $k_BT$ is fully determined by the plasma parameter $\Gamma$, Eq.~(\ref{eq:Gamma}). Temperature is also explicitly contained in the strength of the coupling to ripplons and in the phonon distribution. However, for the considered weak coupling to ripplons and phonons, changing temperature just modifies the small scattering rate. For a given $\Gamma$, its effect on self-diffusion is minor; this should be contrasted with the change of the the long-wavelength mobility, which is limited by the scattering by ripplons and phonons. The electron dynamics sensitively depends on the interrelation between the period of the potential $2\pi/Q$ and the mean inter-electron distance $a_s$. If the electrons form a Wigner crystal that optimally fits into the main rectangle with the sides $(L_x,L_y)$, so that $L_y/a_s=2L_x/a_s\sqrt{3}$ is an integer, the distance between the neighboring electron rows in the $x$-direction is $a_s\sqrt{3}/2$. One can then define the commensurability parameter \cite{Radzihovsky2001} as \begin{align} \label{eq:commensurability_parameter} p_c = a_sQ\sqrt{3}/4\pi, \end{align} which is the ratio of the inter-row distance to the period of the potential. We will assume that the potential $U(x)$ is weak compared to the potential of the electron-electron interaction, $A\ll e^2n_s^{1/2}$. The effect of the potential is most pronounced when $p_c$ is an integer or a fraction with small numerator and denominator, in which case the electron system can effectively adjust to the potential. In our simulations $p_c$ is always a fraction with not too large numerator and denominator. We find that, for a weak potential that we are studying, the ``incommensurability'' becomes strong already for $p_c \lesssim 0.3$. In what follows we use the term ``maximally commensurate'' for the case where $p_c=1$ and ``weakly incommensurate'' for $p_c \gtrsim 0.75$. \subsection{Long-wavelength excitations in the solid phase} In this section we consider self-diffusion in the electron liquid for $p_c=1$, where the potential has a most pronounced effect. To gain intuition, we start with the analysis of the electron dynamics for $A\gg k_BT$ and $\Gamma\gg 1$ and assume that the electrons form a crystal. To minimize the energy, the crystal should be aligned with the potential, so that the electrons are at the troughs of $U(x)$. It is convenient to describe the small-amplitude electron vibrations about the equilibrium positions $\boldsymbol{R}_n$ using the equations for the Fourier components $\delta\bf r(\boldsymbol{q})$ of the electron displacements $\delta\bf r_n=\bf r_n - \boldsymbol{R}_n$. These equations have the form \begin{align} \label{eq:WC_commensurate} \delta\ddot r_\alpha(\boldsymbol{q}) = -\sum_\beta[\nu_0^2\delta_{\alpha\,x}\delta_{\alpha\beta} + C_{\alpha\beta}(\boldsymbol{q})]\delta r_\beta(\boldsymbol{q}),\qquad \nu_0^2 = AQ^2 /m=8\pi^2n_sA/m\sqrt{3}. \end{align} Here, the subscripts $\alpha,\beta$ enumerate the components $x,y$; $\nu_0$ is the frequency of vibrations of an isolated electron in the direction $x$ near the minimum of $U(x)$. Parameters $C_{\alpha\beta}$ describe the effect of the electron-electron interaction. For small $q$ , $C_{\alpha\beta}(\boldsymbol{q})$ is a sum of the plasma contribution $C^{\rm (pl)}_{\alpha\beta}(\boldsymbol{q}) = \omega_p^2 q_\alpha q_\beta/(qn_s^{1/2})$ and the contribution that describes the restoring force for transverse waves. For a hexagonal Wigner crystal the latter has the form \cite{Bonsall1977} $C^{\rm (tr)}_{xx}(\boldsymbol{q}) = c_t^2 q_y^2 + a_{\rm BM}q_x^2$, $C^{\rm (tr)}_{yy}(\boldsymbol{q}) = c_t^2 q_x^2 + a_{\rm BM}q_y^2$, and $C^{\rm (tr)}_{xy}(\boldsymbol{q}) = (a_{\rm BM}-c_t^2)q_xq_y$. Here $c_t\approx 0.245e^2n_s^{1/4}/m$ is the transverse sound velocity in a Wigner crystal without an external periodic potential; $a_{\rm BM}\sim -5 c_t^2$. The confinement imposed by the periodic potential $U(x)$ changes the long-wavelength excitation spectrum. For $\omega_p q/n_s^{1/2}, c_t q\ll \nu_0$ the frequencies of the eigenmodes of the crystal are \begin{align} \label{eq:frequencies} \omega_1^2(\boldsymbol{q}) \approx \nu_0^2 + \omega_p^2 q_x^2/(qn_s^{1/2}),\qquad \omega_2^2(\boldsymbol{q}) \approx \omega_p^2 q_y^2/(qn_s^{1/2}) + c_t^2 q_x^2 +a_{\rm BM}q_y^2 \end{align} The second branch corresponds to the Goldstone mode in the crystal placed into a 1D commensurate potential with the displacement along the potential trough, $\omega_2(\boldsymbol{q})\to 0$ for $|\boldsymbol{q}|\to 0$. The Landau-Peierls argument against the crystalline order in an infinite 2D system is based on the observation that the thermal mean-square displacement from a lattice site diverges. The divergence comes from the low-frequency acoustic phonons. From Eq.~(\ref{eq:frequencies}), the contribution of the low-frequency phonon branch (branch 2) to the mean-square electron displacement in the presence of a commensurate 1D periodic potential is \begin{align} \label{eq:displace_estimate} \langle \delta\bf r_n^2\rangle_2 \propto k_BT \int d\boldsymbol{q} \omega_2^{-2}(\boldsymbol{q})=2\pi k_BT (n_s^{1/4}/\omega_p c_t)\int q^{-1/2} dq. \end{align} This integral converges at the lower limit $q\to 0$. Therefore one may expect that the commensurate potential stabilizes the crystalline configuration. In this case the nature of the transition from the electron liquid to the electron solid should change compared to the case of a free electron system. We should note that the estimate (\ref{eq:displace_estimate}) is specific for a Wigner crystal. The denominator in the right-hand side contains the characteristic parameter $\omega_p$ of the long-wavelength longitudinal plasma vibrations with frequency $\omega_p (q/\sqrt{n_s})^{1/2}$ for $q\to 0$ as well as the transverse sound velocity $c_t$. One therefore may expect that the liquid-to-solid transition will be different for a Wigner crystal from that in a crystal with short-range interaction placed into a 1D commensurate potential. \subsection{Electron diffusion and the liquid-to-solid transition} \label{subsec:diffusion_commensurate} The data of simulations of the electron diffusion in the presence of a 1D maximally commensurate ($p_c=1$) periodic potential are shown in Fig.~\ref{fig:diffusion_commensurate}. In the simulations, where we keep the electron density fixed, a natural scale for the potential is the Coulomb energy $E_C=e^2(\pi n_s)^{1/2}$, Eq.~(\ref{eq:Gamma}). The potential makes a very strong impact on the dynamics where it is still much smaller than $E_C$. The vibration frequency $\nu_0$ is also small, $\nu_0^2/\omega_p^2 =4(\pi^3/3)^{1/2}A/E_C\ll 1$. To have a flavor of the numbers involved we note that, for the interelectron distance $a_s = 1~\mu$m, the amplitude of the potential in panels (a) and (b) corresponds to $A=0.5$~K and $A=0.05$~K. \begin{figure}[h] \centering \includegraphics[width = 4.5truecm]{Fig4a_diffu_A05.pdf} \qquad \includegraphics[width =4.5truecm]{Fig4b_diffu_A005.pdf} \caption{\small Diffusion constants $D_x\equiv D_\perp$ and $D_y\equiv D_\parallel$ vs $\Gamma$ in the maximally commensurate 1D periodic potential where the commensurability parameter (\ref{eq:commensurability_parameter}) is $p_c=1$. Panels (a) and (b) refer to the different strength of the potential, $A/E_C=0.0157$ and $A/E_C=0.00157$, respectively. The simulations are done in the same way as in obtaining the data in Fig.~\ref{fig:diff_isotropic}, the results refer to $N=1600$ electrons; both elastic and inelastic scattering are taken into account. For every point $\Gamma$, the system is prepared in a liquid state with $\Gamma =45$ and then cooled down in the periodic potential.} \label{fig:diffusion_commensurate} \end{figure} The dramatic effect of a periodic potential on the diffusion and on the character of the liquid-to-solid transition is seen from the comparison of Figs.~\ref{fig:diffusion_commensurate} and \ref{fig:diff_isotropic}. Even for a very small potential in Fig.~\ref{fig:diffusion_commensurate}~(b) the diffusion coefficient approaches zero smoothly, indicating a continuous liquid to solid transition. The transition occurs around $\Gamma= 110$, the value significantly smaller (the temperature higher) than in a free electron system. For a 10 times stronger potential in Fig.~\ref{fig:diffusion_commensurate}~(a), the transition occurs for still smaller $\Gamma$. In contrast to the previous case, the coefficients of diffusion transverse and parallel to the potential troughs, $D_x\equiv D_\parallel$ and $D_y\equiv D_\perp$, are significantly different even very close to the transition, i.e., diffusion transverse to the troughs freezes out with decreasing temperature (increasing $\Gamma$) significantly earlier than diffusion along the troughs. A strong drop of $D_x$ compared to the value in the absence of the potential was seen in the simulations \cite{Kalia1983} for $\Gamma=36$ and the potential stronger than the one used here by a factor of $\sim 2$. Since close to the transition the electrons within a trough are strongly correlated, quasi-one-dimensional diffusion along the troughs comes either from density fluctuations (an extra electron or a missing electron in a small region) or has a purely numerical source: in a finite system a whole electron row of length $L_y$ can shift by an inter-electron distance, which would contribute to the diffusion, according to the way the diffusion is calculated. This contribution may lie behind the spread of the data on $D_y$ in Fig.~\ref{fig:diffusion_commensurate}~(a), see below. In contrast, nearly isotropic diffusion in Fig.~\ref{fig:diffusion_commensurate}~(b) shows that a weak potential (small $A/k_BT$) weakly impedes the diffusion across the troughs compared to the diffusion along the troughs, as both are dominated by the disorder in the electron system. Nevertheless, even a weak potential changes the character of the transition between the liquid and solid phases. \begin{figure}[h] \centering \ \includegraphics[width =4.2truecm]{Fig5a_pair_corr_commen_G100.pdf} \qquad \includegraphics[width =4.2truecm]{Fig5b_pair_corr_commen_G110.pdf} \caption{\small Pair correlation function $g^{(2)}(\bf r)$ of the electron system in the external potential for the same parameters as in Fig.~\ref{fig:diffusion_commensurate}~(b): $A/E_C=0.00157$ and $p_c=1$. \textbf{(a)} $\Gamma=100$, \textbf{(b)} $\Gamma=110$. The correlation function is dimensionless. The red cross indicates the location of the origin.} \label{fig:pair_correlator_commensurate} \end{figure} An insight into the change of the ordering imposed by a weak potential can be gained from Fig.~\ref{fig:pair_correlator_commensurate} that shows the pair correlation function \begin{align} \label{eq:pair_correlation} g^{(2)}(\bf r) = \frac{1}{n_s N(N-1)}\sumprime{n,m}\delta[\bf r - (\bf r_n -\bf r_m)]. \end{align} Figure~\ref{fig:pair_correlator_commensurate} refers to the weak periodic potential, the value of the amplitude $A$ is the same as in Fig.~\ref{fig:diffusion_commensurate}~(b). Even above the liquid to solid transition, as seen from Fig.~\ref{fig:pair_correlator_commensurate}~(a), there is partial electron ordering along the troughs of $U(x)$. As $\Gamma$ increases, the electrons become more localized within the troughs and there also increases the correlation between electrons in different troughs, ultimately resulting in the formation of a Wigner crystal. \section{Incommensurate periodic potential} \label{sec:incommensurate} \subsection{Strong incommensurability} We found that, for strong incommensurability, $p_c\lesssim 0.3$, a weak periodic potential ($A\ll E_C$) makes a small effect on the diffusion and on the position and the character of the crystallization transition. In particular, for $p_c=12/40$ and $A/E_C = 0.0157$ the dependence of the diffusion coefficients on $\Gamma$ is essentially indistinguishable, within the simulation error, from that for the free electron system in Fig.~\ref{fig:diff_isotropic}~(a). This is in qualitative difference with a system of noninteracting electrons, where diffusion transverse to the potential troughs is strongly modified once $A\gtrsim k_BT$, as the electrons have to overcome a high potential barrier. The density of the electrons with the appropriate energy is $n_s(2\pi A/k_BT)^{1/2}\exp(-2A/k_BT)$ for $2A\gg k_BT$. It is much smaller than $n_s$. In contrast, the many-electron system averages out the potential where it is not very strong and is far from commensurability. \subsection{Weak incommensurability} \label{subsec:weak_incommensurability} Where a periodic potential is close to being strongly commensurate, i.e., $p_c$ becomes close to 1, it makes a pronounced effect on the electron system even if it is weak. For systems with a short-range inter-particle coupling (for example, crystal monolayers deposited on a crystalline structure with different periodicity), this effect was considered in Refs.~\cite{Pokrovsky1979,Pokrovskii1980}, see also \cite{Bak1982}. It was predicted that there may be formed a lattice of solitons that would minimize the overall elastic energy. The long-range interaction and the associated inapplicability of the conventional elasticity theory can change the character of the crystallization transition for a Wigner crystal. In Fig.~\ref{fig:diffusion_incommens} we show the dramatic effect of the weakly incommensurate potential on the electron diffusion. The chosen potential height is the same as in Fig.~\ref{fig:diffusion_commensurate}~(a). We find that, not too close to the maximal commensurability, $p_c=30/40$, the liquid to solid transition is seen as an abrupt change of the diffusion coefficient. This behavior is similar to that of the free electron system. However, the values of the diffusion coefficients are different and moreover, they can display strong anisotropy. A strong anisotropy is seen also for other values of $p_c$. Strikingly, we found that for $p_c = 30/40$ and 32/40, the value of $\Gamma$ where the system ``freezes'' into a state with no diffusion increases with the increasing $p_c$ and is significantly larger than in the free system. \begin{figure}[h] \centering \includegraphics[width = 4.5truecm]{Fig6a_diffu_p30.pdf}\qquad \includegraphics[width = 4.5truecm]{Fig6b_diffu_p34.pdf}\qquad \includegraphics[width = 4.5truecm]{Fig6c_diffu_p37.pdf} \caption{\small Diffusion constants $D_\perp$ and $D_\parallel$ vs $\Gamma$ in the periodic potential for $A/E_C=0.0157$ and $N=1600$. The simulations include both elastic and inelastic scattering. For every point, the system is prepared as a liquid at $\Gamma=45$, cooled down to the temperature corresponding to a given $\Gamma$, and equilibrated for $10^6$ steps. The commensurability parameter $p_c$ in (a), (b), and (c) is 30/40, 34/40, and 37/40, respectively. } \label{fig:diffusion_incommens} \end{figure} A part of the diffusion anisotropy can be attributed to the finite size of the system. Since the system is translationally invariant along the $y$-axis and is finite, whole rows of electrons can move along this axis, as mentioned previously. We reconstructed what happens to the electrons initially confined to the main region $0\leq x < L_x, \; 0\leq y < L_y$ when we look at their positions in the extended region of $x,y$. We saw that, for $p=34/40$, even for $\Gamma=200$ the electrons remain largely confined to the region $x\in (0, L_x)$, but along the $y$-axis the whole rows shift beyond the boundaries at $y=0, L_y$. We remind that, in the simulations, once an electron goes over the boundary of the main region, it is reinjected on the other side; however, in calculating the diffusion coefficient we take into account the total displacement, and therefore a displacement of an electron row gives a large contribution to the diffusion coefficient $D_y$. A displacement of a whole row is a rare event. Therefore even the large number of steps we are using is apparently not sufficient for obtaining a good statistics, as we see from the dependence of $\langle [y(t)-y(0)]^2\rangle$ on time. However, improving statistics in this case does not make sense, since we are dealing with a finite-size effect, which is of a limited physical interest. The decrease of the freezing temperature (the increase of the critical $\Gamma$) as the system starts approaching the strong commensurability is a consequence of the competition between different structures that almost fit into the periodic potential. They correspond to the electron crystal being deformed and tilted with respect to the potential grating. If the difference in the energy densities of the deformed crystal and the electron liquid is smaller than in the free system, the freezing temperature should go down. As seen from the Delaunay triangulation in Fig.~\ref{fig:solitons}~(b), for $\Gamma$ already above the critical value for the free system, the liquid phase in the modulated system consists of regions with the orientation largely correlated with the potential symmetry. The color in Fig.~\ref{fig:solitons}~(b) shows the real part of the bond orientational order parameter $\psi_6^{(n)}$, \begin{align} \label{eq:hexatic} \psi_6^{(n)}=M_{\rm nn}^{-1}\sum_m\exp(6i\theta_{mn}), \end{align} where the sum runs over the nearest neighbors of the $n$th electrons, $M_{nn}$ is the number of the neighbors, and $\theta_{nm}$ is the angle between the bond to neighbor $m$ and the $x$-axis. By construction, $\psi^{(n)}_6$ is constant within a Voronoi cell centered at an $n$th electron. In Fig.~\ref{fig:solitons}~(b), different regions in the electron liquid are aligned close to the $x$ axis (magenta) or close to the $y$-axis (blue). The sizes of these regions are different and vary from a snapshot to a snapshot. The electrons diffuse along the boundaries and the boundaries themselves move. The pair correlation function in Fig.~\ref{fig:solitons}~(a) shows a short-range order for $\Gamma\approx 140$ with weak overall density modulation imposed by the potential. \begin{figure}[h] \centering \includegraphics[height =5.0truecm]{Fig7a_pair_corr_p30.pdf}\quad \includegraphics[height =5.0truecm]{Fig7b_delaunay_p30.pdf}\quad \includegraphics[height =5.1truecm]{Fig7c_Voronoi_p30.png} \caption{\small The results of the simulations of a system of $N=1600$ electrons in the 1D periodic potential for $A/E_C = 0.0157$ and the commensurability parameter $p_c=3/4$. (a) Pair correlation function $g^{(2)}(\bf r)$, Eq.~(\ref{eq:pair_correlation}), $\Gamma=140.3$. (b) Delaunay triangulation of a snapshot of the system with electrons represented by vertices of the triangulation,$\Gamma=140.3$. The background color shows $\mathrm{Re}\left[\psi_6^{(n)}\right]$, Eq.~(\ref{eq:hexatic}). (c) Voronoi tessellation of the Wigner crystal for $\Gamma \approx 149$. Voronoi cells are colored depending on their surface area: from dark purple for smaller cells to light yellow for larger cells. The variation of the cell areas is from $0.97/n_s$ to $1.02/n_s$. The electron positions are time-averaged to account for small-amplitude thermal fluctuations. Clear rows of increased density appear at a nonzero angle with the modulation direction. They correspond to the incommensuration solitons \cite{Pokrovskii1980}.} \label{fig:solitons} \end{figure} In the crystalline phase, for several values of $p_c$ we observed the onset of periodically repeated ranges of increased density, the incommensuration solitons \cite{Pokrovskii1980}. They are shown in Fig.~\ref{fig:solitons} for $p_c=3/4$. The data are obtained by cooling the system from the liquid state at $\Gamma=45$ to the targeted value of $\Gamma$. We found that the resulting solitonic structure is metastable, it depends on $\Gamma$. The observation of the solitons shows that the onset of solitons is robust. It is not limited to systems with a short-range interaction, but rather applies to systems with the Coulomb coupling, even though the Wigner crystallization in such systems in the presence of a periodic potential is qualitatively different from that in systems with a short-range coupling. \begin{figure}[h] \centering \includegraphics[height=5.0truecm]{Fig8a_Voronoi_p34.png}\qquad \includegraphics[height=5.0truecm]{Fig8b_Voronoi_p37.png} \caption{\small Voronoi cells for N=1600 electrons in the 1D periodic potential for $A/E_C=0.0157$; (a) $p_c=34/40$, $\Gamma=240$, and (b) $p_c=37/40, \Gamma= 141$. The coloring scheme is the same as in Fig.~\ref{fig:solitons}(c), and the data are obtained by cooling the system from the liquid state at $\Gamma=45$.} \label{fig:strong_incommensurability} \end{figure} The structure of the system and the dynamics change dramatically as $p_c$ further approaches the maximal commensurabiltiy value $p_c=1$. The Voronoi tessellation in Fig.~\ref{fig:strong_incommensurability}(a) shows that, for $p_c=34/40$, the system remains disordered even for a very large $\Gamma$. Compared to a Wigner crystal, it has a large number of defects that stretch in certain symmetry directions. Such defects can move. This should be the reason of the persistent diffusion in Fig.~\ref{fig:diffusion_incommens}(b). Interestingly, as $\Gamma$ increases, the coefficients of diffusion along and transverse to the troughs become essentially equal. For $p_c=34/40$, this happens for $\Gamma\approx 240$. We noticed that the motion of electron rows as a whole along the potential troughs is strongly suppressed for large $\Gamma$ and diffusion becomes almost isotropic. This is a natural consequence of the strong correlations in the system. Interestingly, we did not see freezing of the diffusion for $p_c=34/40$ even for $\Gamma=240$. In contrast, For $p_c=37/40$ motion transverse to the troughs is frozen already for $\Gamma\approx 90$, whereas motion along the troughs does not freeze even for $\Gamma=220$. It is fully dominated by the random motion of the rows, and therefore in Fig.~\ref{fig:diffusion_incommens}~(c) we show data only for $\Gamma<150$. Figure~\ref{fig:strong_incommensurability}(b) shows that for $p_c=37/40$ defects tend to cluster along the troughs into the regions of higher electron density surrounded in the neighboring troughs by regions of lower density. For the values of $\Gamma$ in Figs.~\ref{fig:strong_incommensurability}(a) and (b), the defects already have a pronounced orientational structure. Our results do not show a long-range order in the system for $p_c=34/40$ or 37/40. It might be related to the system being too small. One expects that for $p_c\to 1$ the behavior of the infinite system should approach that for the maximal commensurability. \section{Conclusions} \label{sec:conclusions} This paper reports the results of the molecular dynamics simulations of the electron system on liquid helium. We concentrated on electron self-diffusion in this strongly correlated system, as it characterizes the long-term electron dynamics. We have found that, where the electrons are in the liquid phase, the diffusion is ``normal'', with the mean square displacement proportional to time. This is the case both for a uniform electron system and for an electron system placed into a 1D periodic potential, although the values of the diffusion coefficients can be very strongly changed by the potential even if the modulation of the electron potential energy is much weaker than the characteristic energy of the electron-electron interaction. Important distinctions of our simulations of the electron dynamics from the previous work are not only the large size of the system but also that we take into account both elastic and inelastic electron scattering off the excitations in the thermal reservoir. We model the scattering as short events with the rates that correspond to the scattering rates for electrons on the helium surface. The scattering rate is small compared to the plasma frequency and $k_BT/\hbar$, so that the electron motion is underdamped. Yet the scattering leads to the relaxation of the total electron momentum and, even more importantly in the context of this paper, it leads to thermalization of the electron system. This is particularly helpful in the analysis of the dynamics in the vicinity of the liquid to solid transition, where the thermalization of an isolated electron system slows down. Another important feature of our simulations is that we use over $10^7$ time steps. We found that such a long time is necessary to achieve full equilibration and improve the statistics. For a free electron system, the diffusion coefficient monotonically decreases with the decreasing temperature. At the liquid to solid transition, it drops to zero in an extremely narrow temperature range, essentially discontinuously. In our long simulations we are unable to see a hysteresis; this should be contrasted with the observation of the hysteresis in the earlier work \cite{Kalia1981} where the number of steps was smaller by a factor $\sim 10^3$ (we saw hysteresis when we used a smaller number of steps). For the long simulations we use, within the simulation error, the sharp change of the diffusion coefficient occurs for the same $\Gamma$ whether we cool the system down starting from a random electron configuration or heat it up starting from a Wigner crystal. A maximally commensurate 1D periodic potential dramatically changes the electron dynamics. We see this change for the ratio of the amplitude of the modulation of the potential energy $A$ to the energy of the electron-electron interaction $E_C$ as small as $\sim 1.6\times 10^{-3}$. We show that, in contrast to systems with a short-range coupling, in a 2D Wigner crystal placed into a commensurate 1D potential the mean-square electron displacement from a lattice site does not diverge. This indicates stability of the Wigner crystal and leads to a qualitative change of the character of the liquid to solid transition. We find that, in contrast to the free system, the diffusion coefficient smoothly goes to zero with the decreasing temperature. It becomes equal to zero, withing the accuracy of the data, for the value of the plasma parameter $\Gamma$ noticeably smaller than in the absence of the potential, $\Gamma\approx 110$ instead of $\Gamma\approx 137$. The critical value of $\Gamma$ strongly depends on the ratio $A/E_C$ and drops down to $\approx 75$ for $A/E_C\approx 0.016$. In the liquid phase, the diffusion in a 1D periodic potential is anisotropic. It is slower transverse to the potential troughs. The anisotropy strongly depends on the strength of the potential and the commensurability. Unexpectedly, the critical value of $\Gamma$ where the diffusion coefficient turns to zero depends on the commensurability parameter nonmonotonically. Even for a comparatively weak potential, $A/E_C\approx 0.016, $ as the period of the potential is changed toward the maximal commensurability, the critical $\Gamma$ first becomes higher than for the free-electron system and thus very much higher than for the maximally commensurate potential. In our finite system with periodic boundary conditions, for $A/E_C\approx 0.016$ we did not see the decrease of the critical $\Gamma$ expected in the region of the crossover to the behavior in the maximally commensurate potential. This crossover and its dependence on the strength of the potential warrant further investigation. Not too close to the maximal commensurability, we have seen solitons in the crystalline phase. They appear even though the longitudinal long-wavelength excitations in the Wigner crystal qualitatively differ from acoustic phonons. In contrast to colloidal particles, where motion of individual particles can be traced in the experiment, cf. \cite{Chowdhury1985,Wei1998,Mangold2003,Lu2013,Li2016}, there are no established means to trace individual electrons on the helium surface. A potentially feasible experimental approach to characterizing the electron motion is to study the decay of the density correlation function. The measurement can be done if one places a periodic one-dimensional array of nanoscale sensors of the local potential beneath the helium surface. This array can be placed on the same substrate as the array of the electrodes that create the periodic potential. Fluctuations of the electron density will lead to fluctuations $\delta {\cal Q}$ of the total charge of the array. In the presence of self-diffusion, one may expect that the correlator $\langle \delta {\cal Q}(t) \;\delta {\cal Q}(0)\rangle$ will decay as $\exp[-(2\pi/a_m)^2D_m t/2]$, where $a_m$ is the inter-sensor distance and $D_m$ is the component of the diffusion coefficient along the sensor array. Electrons on helium can be used also to observe the lattice of solitons that emerge where electrons crystallize in a periodic potential and the system is close to the maximal commensurability. A convenient way of detecting solitons is by measuring the electron transport along the potential troughs. Because of the weak coupling to the helium surface, the current-voltage characteristic becomes nonlinear already for a weak driving field in the presence of a translational order in the electron system. We expect that the characteristic current is determined by the velocity of the surface waves on helium with the wave vector equal to the vector of the reciprocal soliton lattice. The underlying Bragg-Cherenkov mechanism \cite{Dykman1997b,Vinen1999} has been revealed for a Wigner crystal and used to establish Wigner crystallization in the absence of an extra periodic potential, cf.~\cite{Kristensen1996, Glasson2001, Rees2016,Rees2017}. Since the lattice constant of the solitons is significantly larger than the inter-electron distance, the phase velocity of the helium surface waves is smaller than in the case of the Wigner crystal. Respectively, the nonlinearity of the current-voltage characteristic should emerge for significantly smaller current than that in the absence of a periodic potential and should directly reveal the soliton spacing. \noindent {\bf Acknowledgments} We are grateful for the discussion of the results of this paper to the participants of The International Workshop on Electrons and Ions in Quantum Fluids and Solids (Japan 2018) and the organizer of this workshop K. Kono. This research was supported in part by the NSF-DMR Grant 1708331 \hfill \noindent {\large\bf Appendix}
\section{Introduction} Automatic Speech Recognition (ASR) is a major application domain in the bloom of Artificial Intelligence (AI). Huge effort has been made from both research community and industry to improve ASR system performance. Among all solutions proposed, deep learning approach has been dominating for the last half decade. Given enough data, neural network (NN) models generally perform better in terms of recognition accuracy, and turn out to be more robust. From industrial perspective, accessing and collecting large amount of speech data has become easier than ever before, with emerging market of smart phones and various other smart devices. However, on the other hand, research community still has limited-access to real-world application data. As a result, improvements in research community do not always scale well to industrial scenarios. In computer vision, there are many high quality free data sets which transform research efforts into industrial applications, such as ImageNet~\cite{imagenet} and COCO~\cite{coco}. In Mandarin ASR, although there are corpus like thchs30~\cite{thchs30} and hkust~\cite{hkust1}, a large-scale high-quality free corpus is still needed. In AISHELL-1~\cite{aishell1}, we released 170 hours of Mandarin speech with high quality human transcriptions. Various training and evaluation recipes based on such corpus have been developed in Kaldi~\cite{kaldi}, which is a robust and widely-acknowledged framework for speech research. To the best knowledge of the authors, it is the first fully open-sourced system for Mandarin ASR with high quality Mandarin speech data(e.g. ~\cite{do2017, do2018_1, do2018_2}). Furthering the success from AISHELL-1 with efforts, in this paper, we introduce AISHELL-2, an open-sourced, self-contained baseline for industrial-scale Mandarin ASR research. On one hand, 1000 hours of iPhone-recorded speech data is released. On the other hand, baseline recipes(containing must-have components such as Chinese word segmentation, customizable Chinese lexicon etc) are published into Kaldi, following what have been done with AISHELL-1 formally. Moreover, besides training data(iOS), we release development and test data from 3 acoustic channels(iOS, Android and Mic). We hope these resources would be helpful to transform Mandarin ASR research into industrial scale. The rest of this paper is organized as follows: The details of AISHELL-2 corpus data is introduced in Section 2. Section 3 describes the Mandarin ASR pipeline for producing baseline system and Section 4 presents system performance on test sets from different acoustic channels. \section{AISHELL-2 corpus} AISHELL-2 corpus contains 1000 hours of clean reading-speech data, which will be released to academic research community for free. Raw data was recorded via three parallel acoustic channels - a high fidelity microphone (Mic), an Android smartphone (Android) and an iPhone (iOS). The relative position between speaker and devices are shown in Figure~\ref{fig:setup}. Data from iPhone, i.e. the iOS channel is open-sourced. Speaker, environment and content coverage are explained as below: \begin{itemize} \item \textbf{Speaker information.} There are 1991 speakers participated in the recording, including 845 male and 1146 female. Age of speaker ranges from 11 to over 40. Ideally the speakers shall speak everything to be recorded in Mandarin, while there are some slight accent variations. Generally speaking of the accents, there were 1293 speakers using Northern ones, 678 speakers using Southern ones and 20 speakers use other accents during recording. \item \textbf{Recording environment.} 1347 speakers are recorded in a studio, while the rest are in a living room with natural reverberation. \item \textbf{Content of speech}. The content of the recording covers 8 major topics: voice commands such as IoT device control and digital sequential input, places of interest, entertainment, finance, technology, sports, English spellings and free speaking without specific topic. The total number of prompts is around half a million. \end{itemize} \noindent Aside from AISHELL-2 corpus introduced above, which is supposed to be used for training, we also provide development and test sets. Development set contains 2500 utterances from 5 speakers and test set contains 5000 utterances from 10 speakers. Each speaker contributed approximately half an hour of speech, covering 500 prompts. First 7 prompts of all speakers are extracted from high frequency online queries. Speaker-gender is balanced as well. \begin{figure}[h] \centering \includegraphics[width=\linewidth]{setup.jpg} \caption{Recording setup} \label{fig:setup} \end{figure} \section{AISHELL-2 recipe} As briefly mentioned in Section 1, based on AISHELL-2 corpus, several recipes are released to Kaldi repository as a complete collection, including data and lexicon preparation, language model training, Gaussian mixture model (GMM) and Neural Network training, as well as test set evaluation procedure. \subsection{Lexicon and word segmentation} Unlike English ASR system, Mandarin ASR often requires sophisticated word segmentation. In AISHELL-1, word segmentation was implemented via forward maximum matching algorithm, based on a variation of open-source mandarin dictionary CC-CEDIT\footnote{https://cc-cedict.org/wiki}. In AISHELL-2, an open-source Chinese dictionary called DaCiDian is released\footnote{https://github.com/aishell-foundation/DaCiDian}. In most common Chinese dictionaries, words are directly mapped to phonemes. While in DaCiDian, this mapping is decomposed into 2 independent layers. An exemplar DaCiDian structure is shown in Figure~\ref{fig:lex1} and Figure~\ref{fig:lex2}. The first layer maps word to PinYin syllables~\cite{pinyin}. Anyone who is familiar with PinYin (basically every Mandarin speaker) can enrich DaCiDian's vocabulary by adding new words into this layer. The second layer is a mapping from Pinyin syllable to phoneme. ASR system developers can easily adapt DaCiDian to their own phone set by redefining this layer of mapping. \begin{figure}[t] \centering \includegraphics[width=0.8\linewidth]{dacidianl1.png} \caption{Layer 1 of DaCiDian} \label{fig:lex1} \end{figure} \begin{figure}[t] \centering \includegraphics[width=0.8\linewidth]{dacidianl2.png} \caption{Layer 2 of DaCiDian} \label{fig:lex2} \end{figure} In terms of word segmentation, we choosed a popular and easy-to-use open-source toolkit called Jieba~\cite{jieba}, it implemented a trie-tree based algorithm and supports vocabulary customization. Based on DaCiDian and Jieba, we provide a script to segment AISHELL-2 transcription and language model text. \subsection{Acoustic model} Acoustic training contains two stages: GMM-HMM state model training based on maximum likelihood and later the training of a hybrid DNN-HMM state estimator. Both can be implemented by calling standard methods and designing corresponding recipes in Kaldi toolkit. The GMM models were firstly trained using 13 dimensional MFCC plus pitches, which made the input dimension 16. A monophone model was trained to set a starting point for the triphone models. A small triphone model and a larger triphone model were then consecutively trained using delta features. After that, a more sophisticated feature transform method was applied to replace the delta features. Linear discriminant analysis (LDA) was applied on stack of frames to reduce the dimension and MLLT-based global transform is estimated iteratively. This follows a standard setup pipeline in the majority of available Kaldi recipes. The resulting number of physical GMM states from the four steps were 605, 3216, 5720 and 8080 respectively. GMM training of the AISHELL-2 stopped at the speaker independent stage, without speaker dependent transform involved, such as fMLLR. For industrial-scale corpus, it is not worth spending too much time and computation power at GMM-HMM training stage, since the final system performance primarily depends on later neural network models. Therefore, we adopted speaker independent GMM training and pushed the speaker dependent steps to later DNN training phase, as described below. Based on the tied-triphone state alignments from GMM, a time-delayed neural network (TDNN, \cite{tdnn}) is then configured and trained. It has 8 layers in total, with 1280 hidden units in each layer. It is, as described in \cite{tdnn}, not fully connected - the input of each hidden layer is a frame-wise spliced output of its preceding layer. The input feature was high-resolution MFCC with cepstral normalization plus pitches, which made its dimension 43. Note that for each frame-wise input a 100-dimensional i-vector~\cite{ivector} was also attached, whose extractor was trained based on the corpus itself. The corresponding diagonal universal background model (UBM) was trained using a quarter of training features. This indicates that different from GMM-level training, we encoded speaker information here to produce a stronger baseline for research community. The network was trained using lattice-free maximum mutual information (LFMMI, \cite{lfmmi}) as the objective function. More configurations about NN training itself such as lattice generation and tree topology can be found at \cite{lfmmi} and AISHELL-2 exemplar scripts in Kaldi repository \footnote{https://github.com/kaldi-asr/kaldi/egs/aishell2}. \subsection{Language model} A trigram language model was trained on 5.7 million-word speech transcripts from AISHELL-2. Out-of-vocabulary (OOV) words were mapped as $<$UNK$>$. The 3-order ARPA language model is trained using Kneser-Ney smoothing, with 516552 unigrams, 1498603 bigrams and 932475 trigrams, respectively. \section{Experiment and evaluations} \begin{table*}[tp] \caption{Baseline system results and training time} \label{tab:base} \centering \begin{tabular}{ llllllll } \toprule CER & dev\_android & dev\_ios & dev\_mic & test\_android & test\_ios & test\_mic & Training time in hours \\ \midrule Mono & 47.08 & 43.37 & 47.33 & 45.40 & 44.81 & 44.28 & 0.5 \\ tri1 & 26.61 & 22.94 & 26.55 & 26.08 & 24.79 & 25.36 & 1 \\ tri2 & 24.59 & 21.47 & 24.59 & 23.82 & 22.69 & 23.37 & 2 \\ tri3(LDA+MLLT) & 22.24 & 18.86 & 22.47 & 21.00 & 19.77 & 21.10 & 2.5 \\ Chain-TDNN & 10.43 & 9.10 & 11.84 & 9.59 & 8.81 & 10.87 & 15 \\ \bottomrule \end{tabular} \end{table*} Presented baseline system was trained on a standalone server, with 36 cores of Intel Xeon (2.3GHz) for all cpu-based steps and 4 Tesla K80 processors for DNN model training. Character Error Rate (CER) was used as the evaluation metric. Results along with training time of each stage, are presented in Table~\ref{tab:base}. Note that during training, we only used open-sourced iOS data, while evaluated these models on dev and test sets for all 3 channels (Android, Mic, and iOS). System performance on iOS outperformed Android and Mic, which is as expected due to better acoustic channel condition matching. \section{Conclusions} In this paper, we generally introduce AISHELL-2, a 1000-hour Mandarin ASR corpus, freely available to research community. In the meantime, we present a self-contained recipe in Kaldi toolkit as a research baseline. We hope this open-source project provides essential ingredients for researchers to explore more scalable and practical solutions regarding to industrial scenarios for Mandarin speech recognition. \section{Acknowledgements} The authors would like to thank all other members of AISHELL foundation who contributed to this project and Emotech Labs who provided computational resources for producing most recent system performance statistics. \bibliographystyle{IEEEtran}
\section{Introduction} Collision resistance is one of the fundamental desirable properties of a hash function. Since hash values are often used as digital fingerprints, it should be difficult to find pairs of messages with the same hash value. The main contribution of this paper is a formula that deterministically produces partial or full collisions for Merkle-Damg\aa rd hash functions, such as MD5, SHA1, and the SHA2 family. The formula provides collisions on the iterated compression function for any Merkle-Damg\aa rd hash function. It may or may not provide full collisions depending on the padding scheme and limitations on input length. In the case of MD5, the formula yields full collisions. It does not provide full collisions for SHA1 and SHA256 due to the requirement that inputs have fewer than $2^{64}$ bits. After explaining the formula, we show that it produces messages with length double exponential in the security parameter, and that this methodology probably cannot be used to find colliding messages of sub-exponential length. However, the colliding messages are highly redundant and can be compressed to logarithmic space. Because of ambiguity in the existing definitions of collision resistance, we point out that one can arguably perform a trivial collision attack by simply writing out the collision formula. \section{Background} The Merkle-Damg\aa rd construction has been used to design some of the most commonly used hash functions. The construction is conceptually simple: the input message is read one block at a time to iteratively update an internal state, and after all blocks have been read, the final internal state is used to derive the hash value. More specifically, the construction specifies a block length $b$, an output length $n$, an internal state size $\ell$, an initial internal state $IV$, and a compression function $f: \{0,1\}^b \times \{0,1\}^\ell \to \{0,1\}^\ell$. The following steps are performed to determine the hash value: \begin{itemize} \item[1.] Pad the input so that the total length is a multiple of the block length. \item[2.] Initialize the internal state $IV$. \item[3.] Read in the individual blocks of the input; for each block $B$, update $IV$ as \[IV \leftarrow f(B, IV).\] \item[4.] Once all blocks have been read, derive the hash value from the final value of $IV$. \end{itemize} Note that the inner workings of the construction are much like a DFA, with states corresponding to the possible values of $IV$ and transitions determined by the blocks of the padded message. The functions MD5, SHA1, and SHA256 share some similarities: all three use $b = 512$, let $\ell = n$, and simply output the final value of $IV$ as the hash value. They also use the same padding scheme (up to endianness), which works as follows: \begin{itemize} \item[1.] Append a single ``1'' bit to the input. \item[2.] Append ``0'' bits until the total length is equivalent to 448 modulo 512. \item[3.] Append the input length as a 64-bit integer, producing a padded message with length a multiple of 512. \end{itemize} If the input has $2^{64}$ or more bits, then its length cannot be encoded in a 64-bit integer. In this case, MD5 simply uses the lowest order 64 bits of the input length \cite{md5}. The NIST standardizations of SHA1 and SHA256, meanwhile, prohibit these long inputs \cite{fips180}. If we fix the block $B \in \{0,1\}^b$ in the compression function $f$, the result is a function $f_B: \{0,1\}^\ell \to \{0,1\}^\ell$. An ideal hash function should be difficult to distinguish from a random function; therefore, if a hash function is well designed, then we expect $f_B$ to behave as a randomly chosen function from $\{0,1\}^\ell$ to itself. Consequently, hash functions are sometimes studied by examining the expected asymptotic properties of random mappings on finite domains. We now define and state some of these properties. \\ \noindent \textbf{Definition 1:} Suppose $X$ is a finite set, and let $f: X \to X$. The \emph{functional graph} of $f$ is the directed graph $G_f$ with vertex set \[V = X\] and edge set \[E = \{(x, f(x)) ~|~ x \in X\}.\] In general, each component of any functional graph will have a central directed cycle and some directed trees leading to the cycle \cite{HAC}. Next, we define some of the properties of nodes in a functional graph: \\ \noindent \textbf{Definition 2:} Suppose $f: X \to X$. For any $x \in X$: \begin{itemize} \item[1.] The \emph{tail length} $\lambda(x)$ of $x$ is the minimum length of a directed path from $x$ to a cyclic node in $G_f$. \item[2.] The \emph{cycle length} $\mu(x)$ of $x$ is the length of the cycle in the component containing $x$. \item[3.] The \emph{rho length} $\rho(x)$ of $x$ is the sum of its tail and cycle lengths, $\rho(x) = \lambda(x) + \mu(x)$. \end{itemize} Following are some expected properties of individual nodes in random functional graphs, as given in the \emph{Handbook of Applied Cryptography}: \\ \noindent \textbf{Theorem 1 \cite{HAC}:} Suppose $|X| = N$. If $x \in X$ and $f: X \to X$ are chosen uniformly at random, then the expected tail, cycle, and rho lengths of $x$ are asymptotically given as follows: \begin{itemize} \item[1.] $\lambda(x) \sim \sqrt{\pi N/8}$ \item[2.] $\mu(x) \sim \sqrt{\pi N/8}$ \item[3.] $\rho(x) \sim \sqrt{\pi N/2}$ \end{itemize} Finally, we state expectations for some properties of the functional graph itself: \\ \noindent \textbf{Theorem 2 \cite{HAC}:} Suppose $|X| = N$, and $f: X \to X$ is chosen uniformly at random. Then the following are asymptotically true as $N \to \infty$: \begin{itemize} \item[1.] The expected number of cyclic nodes in $G_f$ is $\sim\sqrt{\pi N/2}$. \item[2.] The expected maximum tail length of a node in $G_f$ is $\sim c_1\sqrt{N}$, where $c_1 \approx 0.78$. \item[3.] The expected maximum cycle length in $G_f$ is $\sim c_2\sqrt{N}$, where $c_2 \approx 1.74$. \item[4.] The expected maximum rho length in $G_f$ is $\sim c_3\sqrt{N}$, where $c_3 \approx 2.41$. \end{itemize} While nodes in functional graphs can have variable in-degree, each has out-degree 1, since $f$ is a function. Starting from any node in any $G_f$, traversing the out-edges will eventually lead us to a cycle. Suppose now that we let $X = \{0,1\}^\ell$, the set of possible internal states for a hash function, and choose $f$ to be the the function $f_B$ obtained by fixing a block $B$ in the hash compression function. Let $[B]^k$ denote the message consisting of the block $B$ repeated $k$ times. Observe that if we begin at the node $IV$ in the functional graph $G_{f_B}$ and traverse $k$ out-edges, we arrive at the node \[IV' = f_B^k(IV) = f_B(f_B(\dots f_B(IV))).\] The value $IV'$ is also the intermediate internal state of a hash function after processing $k$ blocks that are all identical to $B$. This observation, and the aforementioned facts about functional graphs, inspire our collision formula. \section{The Collision Formula} Arbitrarily fix a block $B \in \{0,1\}^b$ in a hash function's compression function to obtain a function $f_B: \{0,1\}^\ell \to \{0,1\}^\ell$. Consider the messages \[M_0 = [B]^{\lambda(IV)}, ~~~~~ M_1 = [B]^{\lambda(IV) + \mu(IV)}.\] When $f_B$ is applied iteratively to these messages one block at a time, the two clearly agree after the first $\lambda(IV)$ blocks, since the messages are identical up to that point. By the definition of $\lambda(\cdot)$, we see that these first $\lambda(IV)$ blocks bring us to a cyclic node in the functional graph $G_{f_B}$. After the first $\lambda(IV)$ blocks, message $M_0$ ends immediately, while $M_1$ has $\mu(IV)$ more blocks to complete a full additional cycle in the functional graph. Starting from $IV$ in $G_{f_B}$, traversing $\lambda(IV) + \mu(IV)$ out-edges brings us to the same node as if we only traverse $\lambda(IV)$ out-edges. Therefore, when $M_0$ and $M_1$ are passed to our unspecified hash function, the two will collide directly prior to the final padding block. The above collision construction still works if we replace $\lambda(IV)$ with any $a \geq \lambda(IV)$, as any such value is sufficient to bring $M_0$ and $M_1$ into a cycle in the functional graph. Furthermore, after $M_0$ and $M_1$ arrive at the same cyclic node, the two can traverse the cycle any whole number of times and still collide. Thus, we see that the messages \[M_0 = [B]^{a + c_1 \mu(IV)}, ~~~~~ M_1 = [B]^{a + c_2 \mu(IV)}\] also collide for any $a \geq \lambda(IV)$ and any natural numbers $c_1, c_2$. In fact, for fixed $a \geq \lambda(IV)$, the set \[\left\{[B]^{a + c \mu(IV)} ~ \left| ~ c \in \mathbb{N} \right.\right\}\] is an infinite family of messages which mutually collide up until the final padding blocks are processed. There are two reasons that we do not yet have a full collision formula. First, it is nontrivial to compute $\lambda(IV)$ and $\mu(IV)$. From the results cited in the previous section, these values are roughly $2^{\ell/2}$ each, and we tend to have $\ell \geq 128$ in practice. Second, the mutually colliding messages all have different lengths; hence, they are padded differently, so we should expect the collisions to disappear once their final blocks are processed. We begin by addressing the problem of computing $\lambda(IV)$ and $\mu(IV)$. While we should expect it to be infeasible in general to compute $\lambda(IV)$, we do not need an exact value---it is sufficient simply to find a value $a \geq \lambda(IV)$. Since our functional graph $G_{f_B}$ only has $2^\ell$ nodes, we know that $\lambda(IV) < 2^\ell$, hence the choice $a = 2^\ell$ will suffice. Similarly, we do not need to know the exact value of $\mu(IV)$---we will still have an infinite family of mutually colliding messages if we replace the term $c \mu(IV)$ with any multiple of $\mu(IV)$. And while computing $\mu(IV)$ is probably infeasible, we know that $\mu(IV) \in \{1, 2, \dots, 2^\ell\}$. Thus, $(2^\ell)!$ must be a multiple of $\mu(IV)$. We therefore obtain our formula that produces hash collisions: \[[B]^{2^\ell + c(2^\ell)!} \tag{*}\] For any fixed block $B$, compression function $f_B$, and any two values of $c \in \mathbb{N}$, we obtain a hash collision. Indeed, the set \[\left\{[B]^{2^\ell + c(2^\ell)!} ~|~ c \in \mathbb{N}\right\}\] is a subset of the infinite family of mutually colliding messages. As previously mentioned, some padding schemes may thwart this formula. We have actually already resolved this issue for some functions, however. The specification for MD5, given in RFC 1321 \cite{md5}, explicitly allows messages of arbitrary length: if the input length is at least $2^{64}$ bits, then the padding only uses the low order 64 bits of the length in the padding. Therefore, for two messages to receive the same MD5 padding, it is not necessary that they have the same length---it is sufficient that their lengths be equivalent modulo $2^{64}$. For MD5, all messages produced by our formula have bit lengths that are multiples of $2^\ell = 2^{128}$, so their lengths are all equivalent modulo $2^{64}$. Hence, our formula produces full collisions for MD5. SHA1 and SHA256 have, respectively, $\ell = 160$ and $\ell = 256$. This means that for these functions, all messages produced by our formula have equivalent lengths modulo $2^{64}$. However, the NIST standardizations of these functions, given in FIPS 180-4 \cite{fips180}, require input messages to have fewer than $2^{64}$ bits. (This is not unreasonable---it is still difficult to envision a future in which files with $2^{64}$ bits are hashed. And allowing such long inputs allows for some potent attacks \cite{kelsey}.) All messages produced by our formula for SHA1 and SHA256 have lengths much greater than $2^{64}$. For these functions, the formula only produces collisions on the iterated compression function. If the domains of SHA1 and SHA256 were extended in the natural way, our formula would produce full collisions for these functions, too. \section{Analysis of Message Lengths} The messages produced by our formula are too long for SHA1 and SHA256, but how long are they, really? The dominant term in the formula is $(2^\ell)!$, which is not a familiar quantity. We can, however, set upper and lower bounds on it. The upper bound is obtained by replacing all $2^\ell$ individual factors with $2^\ell$, while the lower bound is obtained by neglecting the smallest half of the terms and replacing all remaining terms with $2^\ell/2 = 2^{\ell-1}$. We obtain \[(2^{\ell-1})^{2^{\ell-1}} < (2^\ell)! < (2^\ell)^{2^\ell}.\] Rewriting these bounds as \[2^{2^{\ell-1+\log(\ell-1)}} < (2^\ell)! < 2^{2^{\ell+\log \ell}},\] it becomes clear that $(2^\ell)!$ is double exponential in $\ell$. The number of $b$-bit blocks in our messages is roughly $c(2^\ell)!$ (the term $2^\ell$ is comparatively negligible), so the total bit length of our messages is roughly \[bc2^{2^\ell}\] for arbitrary choice of $c \in \mathbb{N}$. For typical values of $\ell$ with $\ell \geq 128$, it is safe to say that such a message cannot ever be fully hashed, much less written out in full. (The possible exception is the message with $c = 0$, but that message has length $b2^\ell$, which is still prohibitively large for the foreseeable future.) Our collision formula is perhaps excessive---we upper bounded the tail and cycle lengths in functional graphs by $2^\ell$, but by theorem 2, the maximum tail and cycle lengths over the whole graph are on the order of $2^{\ell/2}$ in expectation. This suggests a collision formula that still works in expectation but produces smaller messages: \[[B]^{\lceil 0.78 \cdot 2^{\ell/2} \rceil + c(\lceil 1.74 \cdot 2^{\ell/2} \rceil)!}\] While the messages produced by this formula are objectively much shorter than those produced by the first formula, these message lengths are still double exponential in $\ell/2$. This does not bring us meaningfully closer to practical message lengths. And if we further decrease the message lengths, we correspondingly decrease the probability that the formula yields collisions. Our formula exploits cycles in functional graphs to find collisions. This method, at minimum, requires us to enter a cycle. By theorem 1, we know that the average node is at distance $\sqrt{\pi 2^\ell/8} \approx 0.63 \cdot 2^{\ell/2}$ from the nearest cycle, so it is difficult to see how this method could produce colliding messages much shorter than about $2^{\ell/2}$ bits. The cycle lengths pose an even greater problem. Whereas our formula only needs an upper bound on $\lambda(IV)$, it needs an exact multiple of $\mu(IV)$, and it is not obvious that we can find a small multiple of $\mu(IV)$ without determining $\mu(IV)$. Since $\mu(IV)$, like $\lambda(IV)$, has an expected value of about $0.63 \cdot 2^{\ell/2}$, determining $\mu(IV)$ in the straightforward way puts us roughly even with a randomized birthday collision attack---and the colliding messages found this way would still be too long for SHA1 and SHA256. One idea for a cycle-based collision attack (and perhaps also a second preimage attack) is to hope that, for our block choice $B$, the node $IV$ is a cyclic node. However, there are only about $\sqrt{\pi 2^\ell/2}$ cyclic nodes out of $2^\ell$ total nodes, and it is unclear how to efficiently identify cyclic nodes. Our formula identifies long colliding messages with virtually no work. It does not seem, however, that there is a noteworthy length/time tradeoff here. Collisions found with this methodology necessarily have at least exponential length in expectation, and achieving single exponential length straightforwardly requires exponential time. \section{Collision Resistance} While the messages produced by our collision formula are unimaginably long, the very existence of a hash collision formula raises an interesting question: does this formula technically break the collision resistance of some hash functions? Existing definitions of collision resistance are just vague enough that the answer is arguably yes. Collision resistance is formalized in terms of keyed hash functions and a ``collision game''. Keyed hash functions differ from real world hash functions in that they cannot be evaluated without knowledge of a special key. Real world hash functions can be viewed as keyed hash functions with standardized key values. In a collision game \cite{gb} \cite{katz}, a key is randomly generated, and an adversary must produce messages which collide for that particular key. Roughly speaking, a hash function is said to be collision resistant if its keyed variant thwarts the adversary with overwhelming probability. There are several versions of the collision experiment---while the adversary is usually given the key immediately, several variants \cite{gb} require the adversary to produce one or both of the colliding messages before being given the key. The adversary in the collision game must run in time polynomial in the security parameter. A message of double exponential length requires double exponential time to write out in full. However, the long colliding messages produced by our collision formula are highly redundant, consisting of the same block repeated many times. These long colliding messages can be compressed to logarithmic space, $O(\log \ell + \log c)$, by simply writing out formula (*) for two different values of $c$. The collision resistance definitions given by \cite{gb} and \cite{katz} do not state that the colliding messages must be of polynomial length, and they only state that the adversary must ``output'' the colliding messages. Since these definitions do not explicitly state that the adversary must write out the messages in full, it is arguably acceptable for the adversary to provide compressed output. If compressed output is allowed, then the adversary can win the collision game with probability 1 under all models, including those which require the adversary to produce collisions without knowledge of the chosen key. This is because our formula is very general---it does not use any information about hash function internals or key values. It only takes advantage of inevitable properties of functions over finite domains. \section{Conclusion} This hash collision formula is a theoretical curiosity. It does not compromise collision resistance in any practical sense, and there is good reason to believe that this methodology cannot be converted into a practical collision attack. Nevertheless, it is theoretically ambiguous whether the formula compromises the security of real world hash functions. If the adversary in the collision game is allowed to give compressed output, then the formula trivially breaks the collision resistance of MD5 and nearly does the same to SHA1 and SHA256. A collision attack on MD5 is perhaps unexciting, since collisions can already be found in about $2^{24.1}$ evaluations of the compression function \cite{md5coll}. Our collision formula, however, produces collisions without any evaluations of the compression function. This collision attack is impractical, and can be theoretically ruled out by tightening the definition of collision resistance. SHA1 and SHA256 already accomplish this by placing limits on input message length. This defense can be extended to all hash functions by specifying that adversaries must write out colliding messages in full, or by requiring that the colliding messages must have length polynomial in the security parameter. \section*{Acknowledgement} This work was supported by the National Science Foundation (grant CCF-1420750). The author is also grateful to Eric Bach for many helpful discussions over the course of this research. \newpage
\section*{Acknowledgments} \label{sec:acknowledgments} We thank Angeliki Lazaridou, Douwe Kiela and Calvin Lee for their useful discussions and insights. We also thank Francisco Massa for his help on setting up the experiments. \section{Discussion} \label{sec:discussion} Existing literature in game theory already showed that convergence towards successful communication is ensured under specific conditions (see ~\citet{Skyrms2010} and references therein). However, the important contribution of \citet{Lazaridou:etal:2017} is to play a signaling game with real-life images instead of artificial symbols. This raises new empirical questions that are not answered by the general mathematical results, such as: When the agents do succeed at communicating, what are the input features they rely upon? Do the internal representations they develop relate to the conceptual properties of the input? Our study suggests that the agents' representations are not capturing general conceptual properties of different objects, but they are rather specifically tuned to successfully distinguish images based on inscrutable low-level relational properties. Interestingly, our conclusions can be aligned with findings in psycholinguistic experimental literature on dialogue. In order to achieve communication, the agents develop a form of `'conceptual pact'' \citep{Brennan:96}: Their internal representations align while at the same time drifting away from human-level properties of the input. The agents agree on a shared use of the vocabulary, that does not correspond to concepts in the input data. In future work, we would like to encourage the development of more natural word meanings by enforcing the agent representations to stay more faithful to the perceptual input they receive. Moving ahead, it is fundamental to design setups where agents would have stronger reasons to develop human-like communication strategies. \section{Experiments} \label{sec:experiments} We first asked in which way playing the game affects the way agents ``see'' the input data, that is, in which way their image embeddings differ from the input image representations, and from each other. Concerning Sender and Receiver, a reasonable expectation is that successful communication implies a convergence of representations. How should these representations relate to the input? Recall that input representations are from one of the top layers of a state-of-the-art ConvNet trained on ImageNet concept categorization, and the top layers of such networks are known to capture high-level concept semantics \citep{Zeiler:Fergus:2014}. The game image pairs are always sampled from different concepts. So, it would make sense for the agents to simply learn to carry through the similarity structure of the input space, in order to communicate about distinct concepts. Consequently, we predicted that, as training proceeds, Sender and Receiver representations will become closer to each other, and to the input ones. In order to compare the similarity structure of input, Sender and Receiver spaces, we borrow \emph{representational similarity analysis} (RSA) from computational neuroscience \citep{Kriegeskorte:etal:2008}. Given two sets $r_1$ and $r_2$ of representations of the same item collection (e.g., $r_1$ is the collection of input images mapped in Sender embedding space and $r_2$ is the same collection represented by Receiver), we first compute $s_1$ as all possible pairwise (cosine) similarities between the representations in $r_1$, and $s_2$ as those in $r_2$. We then compute the (Spearman) correlation between the similarity vectors $s_1$ and $s_2$. This latter value, which we will call \emph{RSA score}, measures the global agreement between $s_1$ and $s_2$, relative to the chosen input collection. If $N$ is the number of items in the collection that we compute representations for, both similarity vectors $s_1$ and $s_2$ are of length $N(N-1)$. Therefore, it is not necessary for representations $r_1$ and $r_2$ to belong to the same space (for example, in our case, input and agent vectors have different dimensionality). \begin{figure} \includegraphics[width=\columnwidth]{images/rsaval2.jpeg} \caption{RSA scores of the two agents ($\rho_{S/R}$), and of each agent with the input ($\rho_{S/I}$ and $\rho_{R/I}$), during the first $10,000$ training games. $S$ refers to Sender, $R$ to Receiver, $I$ to input. Values remain stable until end of training. Best viewed in color.} \label{fig:perf-rsa} \end{figure} Figure \ref{fig:perf-rsa} shows RSA and mean validation reward (MVR) development curves for the cross-validated best seed in the same-image game. At the beginning of training, the RSA scores are non-zeros, which is expected as the two agents architectures are similar and randomly initialized the same way. They are also somewhat correlated with the input, which we attribute to the fact that untrained neural networks can already extract relevant image features \citep{Jarrett:etal:2009}. % As training converges, Sender and Receiver similarity spaces also converge. However, contrary to our prediction, the agent similarity spaces are not strongly correlated with the input visual space. We note that, during the first few hundred games, the Sender (green curve) aligns with the input, but the Receiver (blue curve) does not. Therefore, it seems that, in order to establish communication, the two agents have to drift from the input. Indeed, when communication is successfully established at the end of training,\footnote{We consider training successful if MVR $\geq{}80\%$.} the two agents have a RSA score of $\rho_{S/R}=0.98$. However either agent's score with the input is a much lower $\rho_{S/I}=\rho_{R/I}=0.33$.\footnote{Values averaged over the $96$ successful seeds.} On the contrary, when the agents fail to establish communication, by the end of training their RSA score is just $\rho_{S/R}=0.39$, but they stay closer to the input ($\rho_{S/I}=0.58$ and $\rho_{R/I}=0.42$).\footnote{Values averaged over the $4$ failing seeds.} The drift of the agents from input similarity could be attributed to the characteristics of the game they are playing. Since they are only asked to distinguish between pictures of different concepts, they have no incentive to keep different instances of a concept distinct (if the agents are never asked to distinguish one dog from another, they might eventually become unable to tell dogs apart). That is, we might be assisting to the inception of a form of categorical perception \citep{Goldstone:Hendrickson:2009}, whereby the agents lose sensitivity to within-category differences. If this is the case, we should observe that same-concept image similarity is \emph{higher} in Sender (or Receiver) space with respect to input space. However, this turns out not to be the case. To the contrary, average pairwise same-concept similarity is consistently \emph{lower} in Sender space than in the input (mean $z$-normalized same-concept similarity in input space is at $1.94$ vs.~$0.57$ in Sender space, averaged across successful seeds). A similar effect is observed by looking at higher-class (\emph{mammal}, \emph{furniture}, etc.) similarities: images from the same classes become less similar in Sender space ($0.61$ $z$-normalized within-class input similarity vs.~$0.30$ in Sender space). This suggests that the agents are becoming less proficient at capturing the similarity among instances of the same concept or of the same class. The same conclusion is qualitatively supported by the pairs of images that underwent the largest shift between input and Sender space. For example, for two test images of avocados which have an input similarity of $0.82$ (and are reasonably similar to the human eye), the Sender similarity is at the low value of $-0.27$ (Receiver similarity is $-0.59$). Contrarily, for an image of a cabin in a field and an image of a telephone that have an intuitively correct very low input similarity of $0.02$, the Sender similarity for these images is $0.94$ (Receiver similarity is $0.95$). \citet{Lazaridou:etal:2017} designed their second game to encourage more general, concept-like referents. % Unfortunately, we replicate the anomalies above in the different-image setup, although to a less marked extent. When successful communication is established at the end of training, the agents have $\rho_{S/R}=0.90$. But again, the agents' representation do not align with the input space: their scores with the input are at lower values of $\rho_ {S/I}=0.40$ and $\rho_{R/I}=0.37$.\footnote{Values averaged over the $19$ successful seeds.} In case of communication failure, by the end of training their RSA score is at the lower value of $\rho_{S/R}=0.74$, and their values with respect to the input are $\rho_{S/I}=0.36$ and $\rho_{R/I}=0.34$.\footnote{Values averaged over the $81$ failing seeds.} Again, same-concept images drift apart in agent space, although now to a lesser extent ($1.94$ $z$-normalized mean similarity in input space vs.~$1.07$ in Sender space). More encouragingly, we don't find the same pattern for within-class mean similarities ($0.61$ input space vs.~$0.75$ Sender space). We must conjecture that the agents are comparing low-level properties of the image pairs, independently of the game they play. As an extreme way to test this, we look at how agents trained to play the two games behave when tested with input pairs that are just random noise vectors drawn from a standard Normal distribution.\footnote{As during training inputs are divided by their norm, we also normalize each noise vector, so multiple noise variances would have no effect.} If the agents are indeed indifferent to the objects represented by images, the radical shift in the nature of the input to the game should not affect them much. \begin{table}[tpb] \centering \begin{footnotesize} \begin{tabular}{|l|cccc|} \hline ~ & ~ &\multicolumn{3}{c|}{Test}\\\hline \multirow{4}{*}{\rotatebox[origin=c]{90}{Train}} & ~ & Same im. & Diff. im. & Noise \\ ~ &Same im. &$100$&$72$& $95 $\\ ~ & Diff. im. &$98$ &$83$ & $87$\\ \hline \end{tabular} \end{footnotesize} \caption{Percentage average rewards on the same-image, different-image and noise test sets for agents trained in the same- and different-image games (chance level at 50\%). For each game, values are averaged on $10$ test runs consisting of $1,000$ games of mini-batches of $32$ image pairs, using the cross-validated best seed.} \label{tab:tabperf} \end{table} Results are shown in Table~\ref{tab:tabperf}. We confirm that the same-image game is the easiest, and we observe that agents trained in one game perform reasonably well on the other. More importantly, no matter which game they are trained on, the agents perform very well on noise input! This confirms our hypothesis that the Sender and Receiver are able to communicate about input data that contain no conceptual content at all, which in turn suggests that they haven't extracted any concept-level information (e.g., features that would allow them to recognize instances of the \emph{dog} or \emph{chair} category) during training. To get a sense of the sort of noise pairs agents succeed to communicate about, Figure \ref{fig:noise} provides an example. \begin{figure}[tbp] \centering \begin{subfigure}[t]{0.49\columnwidth} \centering \includegraphics[width=\textwidth]{images/noise1.png} \end{subfigure} \hfill \begin{subfigure}[t]{0.49\columnwidth} \centering \includegraphics[width=\textwidth]{images/noise2.png} \end{subfigure} \caption{Noise vectors agents trained on the same-image game successfully communicate about.} \label{fig:noise} \end{figure} Finally, we draw $1,000$ noise pairs $(z_1,z_2)$, and present each to the Sender with either $z_1$ or $z_2$ as target. We then compare, pair by pair, whether the highest probability symbol changes when the target is swapped. We average across $10$ random runs using the best cross-validated seed. In both versions of the game, for more than $99\%$ of the pairs, the symbol with highest probability changes when the target is swapped. This suggests that the agents perform a \emph{relative} comparison of the two inputs, rather than an absolute one, in line with the general conclusion that they are not using the vocabulary to denote stable conceptual properties of the objects depicted in the images. \section{Introduction} \label{sec:introduction} There has recently been a revival of interests in language emergence simulations involving agents interacting in visually-grounded games. Unlike earlier work \citep[e.g.,][]{Briscoe:2002,Cangelosi:Parisi:2002,Steels:2012}, many recent simulations consider realistic visual input, for example, by playing referential games with real-life pictures \citep[e.g.,][]{Jorge:etal:2016,Lazaridou:etal:2017,Havrylov:Titov:2017,Lee:etal:2018b,Evtimova:etal:2018}. This setup allows us to address the exciting issue of whether the needs of goal-directed communication will lead agents to associate visually-grounded conceptual representations to discrete symbols, developing natural-language-like word meanings. However, while most studies present some analysis of the agents' symbol usage, they pay little or no attention to the representation of the visual input that the agents develop as part of their evolving interaction. We study here agent representations following the model and setup of \citet{Lazaridou:etal:2017}. This is an ideal starting point, since it involves an extremely simple signaling game \citep{Lewis:1969}, that is however played with naturalistic images, thus allowing us to focus on the question of how the agents represent these images, and whether such representations meet our expectations for natural word meanings. In their first game, Lazaridou's Sender and Receiver are exposed to the same pair of images, one of them being randomly marked as the ``target''. The Sender always sees the target in the left position, and it must pick one discrete symbol from a fixed vocabulary to send to the Receiver. The Receiver sees the images in random order, together with the sent symbol, and it tries to guess which image is the target. In case of success, both players get a payoff of 1. Since an analysis of vocabulary usage brings inconclusive evidence that the agents are using the symbols to represent natural concepts (such as \emph{beaver} or \emph{bayonet}), Lazaridou and colleagues next modify the game, by presenting to the Sender and the Receiver different images for each of the two concepts (e.g., the Sender must now signal that the target is a \emph{beaver}, while seeing a different beaver from the one shown to the Receiver). This setup should encourage concept-level thinking, since the two agents should not be able to communicate about low-level perceptual characteristics of images they do not share. Lazaridou and colleagues present preliminary evidence suggesting that, indeed, agents are now developing conceptual symbol meanings. We replicate Lazaridou's games, and we find that, in both, the agents develop successfully aligned representations that, however, are not capturing conceptual properties at all. In what is perhaps our most striking result, agents trained in either version of the game succeed at communicating about pseudo-images generated from random noise (Fig.~\ref{fig:noise}). We conclude that, if we want interactive agents to develop a vocabulary of words denoting natural meanings, more attention must be paid to the way in which they are representing their perceptual input. \section{Experimental setup} \label{section:setup} \paragraph{Architecture} We re-implement Lazaridou's Sender and Receiver architectures (using their better-behaved ``informed'' Sender). Both agents are feed-forward networks. The \textbf{Sender} takes image representations as input, it projects them into its own representational space, compares them, and finally outputs a probability distribution over vocabulary symbols, from which a single discrete symbol is then sampled. We report here results obtained with an output vocabulary of $100$ symbols, but the same patterns were observed using a range of sizes from $2$ to $1,000$. The \textbf{Receiver} takes as input the target and distractor input image representations in random order, as well as the symbol produced by the sender (as a vocabulary-sized one-hot vector). It embeds the images and the symbol into its own representational space, where it performs a symbol-to-image comparison, producing a probability distribution over the two images, one of which is selected by sampling from this distribution. If the Receiver selected the target image, a reward of 1 is assigned to both agents. The whole architecture is jointly trained by letting the agents play, and updating their parameters with Reinforce \citep{Williams:1992}. See \citet{Lazaridou:etal:2017} for details. \paragraph{Data} Following \citet{Lazaridou:etal:2017}, for each of the $463$ concepts they used, we randomly sample $100$ images from ImageNet \citep{Deng:etal:2009}. We construct $50,000$ mini-batches of $32$ image pairs during training and $1,024$ pairs for validation. We construct a held-out test set in the same way by sampling $10$ images per concept from ImageNet (for 2 concepts, we were not able to assemble enough further images), for a total of $4,610$. We compute RSA scores (see below) on the cross-product of these images. We also use the held-out set to construct mini-batches of images pairs to compute test performance. Following Lazaridou, the images are passed through a pre-trained VGG ConvNet \citep{Simonyan:Zisserman:2015}. The input vector fed to the agents is the second-to-last $4096$-D fully connected layer\footnote{We found very similar results with the top $1000$-D softmax layer.}. \paragraph{Games} We re-implement both Lazaridou's \textbf{same-image} game, where Sender and Receiver are shown the same two images (always of different concepts), and their \textbf{different-image} game, where the Receiver sees different images than the Sender's. We repeat all experiments using $100$ random initialization seeds. As we faithfully reproduced the setup of \citet{Lazaridou:etal:2017}, we refer the reader there for hyper-parameters and training details.
\section{Introduction} \label{sec:introduction} Neutrino oscillations are among the three experimentally established phenomena beyond the Standard Model (SM). Two others are the baryon asymmetry of the Universe (BAU) and elusive Dark Matter (DM). Flavour oscillations of active neutrinos are prohibited within the canonical SM because of conservation of individual global lepton numbers. The simplest and, probably, the most natural way of describing neutrino masses is introduction of right-handed neutrinos into the model~\cite{Minkowski:1977sc,GellMann:1980vs,Mohapatra:1979ia,Yanagida:1980xy,Schechter:1980gr,Schechter:1981cv}. The oscillation data is compatible with the presence of two or more right-handed neutrinos. In contrast to the SM particles, there are no symmetries prohibiting Majorana mass terms for right-handed neutrinos. The scale of this mass term is not fixed by neutrino oscillations and can vary by many orders of magnitude. In refs.~\cite{Asaka:2005an,Asaka:2005pn} it was suggested that the minimal extension of the SM with three right-handed neutrinos with masses \emph{below the electroweak scale}---the $\nu$MSM---can simultaneously address the problems of neutrino oscillations, dark matter (DM) and BAU. Two right-handed neutrinos (following the PDG we will also refer to right-handed neutrinos as heavy neutral leptons or HNLs) that are responsible for the production of the BAU in the $\nu$MSM may have masses in the GeV range. They could be searched for in current and planned experiments. The lightest right-handed neutrino may play the role of the DM particle~\cite{Dodelson:1993je,Shi:1998km,Dolgov:2000ew,Abazajian:2001nj}, \cite{Asaka:2005an}. Baryogenesis with GeV scale HNLs suggested in ref.~\cite{Akhmedov:1998qx} and refined in ref.~\cite{Asaka:2005pn} has attracted a lot of attention and a significant progress has been achieved recently. An incomplete list of related works includes~\cite{Shaposhnikov:2006nn,Shaposhnikov:2008pf,Canetti:2010aw,Asaka:2010kk,Anisimov:2010gy,Asaka:2011wq,Besak:2012qm,Canetti:2012vf,Drewes:2012ma,Canetti:2012kh,Shuve:2014zua,Bodeker:2014hqa,Abada:2015rta,Hernandez:2015wna,Ghiglieri:2016xye,Hambye:2016sby,Drewes:2016lqo,Asaka:2016zib,Drewes:2016gmt,Hernandez:2016kel,Drewes:2016jae,Asaka:2017rdj,Eijima:2017anv,Ghiglieri:2017gjz,Eijima:2017cxr,Antusch:2017pkq,Ghiglieri:2017csp}. The structure of kinetic equations proposed in~\cite{Asaka:2005pn} remained unchanged, however, understanding of the rates entering into these equations has considerably improved \cite{Ghiglieri:2016xye,Eijima:2017anv,Ghiglieri:2017gjz}. The role of neutrality of electroweak plasma has been clarified~\cite{Shuve:2014zua,Ghiglieri:2016xye,Eijima:2017cxr}. Dynamics of the freeze-out of the baryon number has been carefully studied~\cite{Eijima:2017cxr}. The testability of the model has also drawn a considerable attention from the experimental side and the new searches for HNLs were carried out \cite{Liventsev:2013zz,Aaij:2014aba,Artamonov:2014urb,Aad:2015xaa,Khachatryan:2015gha,Sirunyan:2018mtv,Boiarska:2019jcw}. There are several proposals of the experiments which will be very sensitive to the HNLs of the $\nu$MSM: NA62 in the beam dump mode~\cite{Drewes:2018gkc}, SHiP~\cite{Alekhin:2015byh} and MATHUSLA~\cite{Curtin:2018mvb}.\footnote{Also the recently proposed CODEX-b~\cite{Gligorov:2017nwh} and FASER~\cite{Feng:2017uoz,Kling:2018wct} will be probably sensitive to the HNLs of the $\nu$MSM. Note that indirect searches, such as $\mu \to e \gamma$, are not sensitive to the $\nu$MSM~\cite{Gorbunov:2014ypa}. } Of course, it is important to understand whether the HNLs responsible for baryogenesis can be found in these experiments. There were already several studies of the parameter space of the model \cite{Canetti:2012vf,Canetti:2012kh,Hernandez:2016kel,Drewes:2016gmt,Drewes:2016jae} relevant for the current or near-future experiments. Still, these investigations are not complete. In the present work we improve the analysis by \emph{(i)} using the kinetic equations derived in ref.~\cite{Eijima:2017anv}. These equations account for both fermion number conserving and violating reactions, \emph{(ii)} accounting for the neutrality of the electroweak plasma and the non-instantaneous freeze-out of the baryon number using methods suggested in ref.~\cite{Eijima:2017cxr}, and \emph{(iii)} using the fast numerical code that allows scanning over a wider region of the parameter space. We find that the region of parameters leading to the successful baryogenesis with light HNLs is notably larger than it was previously obtained. The results are presented in a way that they can be used for a detailed study of sensitivity of different experiments. The paper is organized as follows. First, we introduce the $\nu$MSM and the parameters the model in section~\ref{sec:nuMSM}. Then we describe the experimentally relevant quantities in section~\ref{sec:experimentally_observable_quantities} and present the cosmologically favourable values of these quantities in section~\ref{sec:results}. These values are determined by imposing the requirement of the successful baryogensis. In section~\ref{sec:open_access_data_sets} we provide all necessary information on the open-access datasets. All theoretical and technical details are presented in the subsequent sections. In section~\ref{sec:production_of_the_baryon_asymmetry} we overview the kinetic equations derived in ref.~\cite{Eijima:2017anv}. We discuss our approach for the numerical solution of these equations and describe the impact of the improvements in section~\ref{sec:numerical_solution_of_the_equations}. The study of the parameter space is performed in section~\ref{sec:scan_of_the_parameter_spaces}. Section~\ref{sec:comparison_with_other_works} contains a detailed comparison with the works~\cite{Canetti:2012vf,Canetti:2012kh,Hernandez:2016kel,Drewes:2016gmt,Drewes:2016jae,Ghiglieri:2017gjz,Ghiglieri:2017csp}. We summarise in section~\ref{sec:conclusions_and_outlook}. Appendix~\ref{sec:mixing_angles_of_hnls_and_active_neutrinos} describes the mixings of active neutrinos and HNLs in our parametrization of Yukawas. Appendix~\ref{sec:derivation_of_kinetic_equations} contains the derivation of the kinetic equations. Finally, in appendix~\ref{sec:benchmark_points} we list several sets of the model parameters along with the corresponding values of the BAU. These sets can be used by other groups as benchmarks to compare numerical results. \section{The \texorpdfstring{$\nu$}{nu}MSM} \label{sec:nuMSM} In this section we fix our notations by introducing the Lagrangian of the $\nu$MSM~\cite{Asaka:2005an, Asaka:2005pn} and the parametrization of Yukawa couplings~\cite{Casas:2001sr,Asaka:2011pb}. Even though these expressions are well known and have been presented many times, we list them to make the paper self-consistent. The Lagrangian of the $\nu$MSM is the usual see-saw one~\cite{Minkowski:1977sc,GellMann:1980vs,Mohapatra:1979ia,Yanagida:1980xy,Schechter:1980gr,Schechter:1981cv} \begin{equation} \mathcal{L} = \mathcal{L}_{SM} + i \bar{\nu}_{R_I} \gamma^\mu \partial_\mu \nu_{R_I} - F_{\alpha I} \bar{L}_\alpha \tilde{\Phi} \nu_{R_I} - \frac{M_{I J}}{2} \bar{\nu}_{R_I}^c \nu_{R_J} + h.c., \label{Lagr} \end{equation} where $\mathcal{L}_{SM}$ is the Lagrangian of the SM, $\nu_{R_I}$ are right-handed neutrinos labelled with the generation indices $I, J = 1, 2, 3$, $F_{\alpha I}$ is the matrix of Yukawa couplings, $L_\alpha$ are the left-handed lepton doublets labelled with the flavour index $\alpha = e, \mu, \tau$ and $\tilde{\Phi} = i\sigma_2 \Phi^*$, $\Phi$ is the Higgs doublet. We work in a basis where charged lepton Yukawa couplings and the Majorana mass term for the right-handed neutrinos $M_{I J}$ are diagonal. In the broken phase, the Higgs field acquires a temperature dependent vacuum expectation value $\langle \Phi (T) \rangle$, which is $174.1$~GeV at zero temperature. The Yukawa couplings in the Lagrangian~\eqref{Lagr} lead to the Dirac mass terms $[M_D]_{\alpha I} = F_{\alpha I} \langle \Phi \rangle$. The $6\times 6$ symmetric mass matrix of neutrinos can be diagonalized by a complex orthogonal transformation. We will restrict ourselves to the see-saw limit $|[M_D]_{\alpha I}|\ll M_I$. In this limit the active neutrino flavour states are given by \begin{equation} \nu_{L_\alpha} = U^{PMNS}_{\alpha i} \nu_i + \Theta_{\alpha I} N_I^c, \label{mixing} \end{equation} where $U^{PMNS}$ is the Pontecorvo-Maki-Nakagawa-Sakata (PMNS) matrix~\cite{Pontecorvo:1957qd,Maki:1962mu}, $\nu_i$ are mass eigenstates of active neutrinos, $N_I$ are the mass eigenstate of HNLs. The active-sterile mixing matrix in the leading order of the see-saw mechanism is \begin{equation} \Theta_{\alpha I} = \frac{\langle \Phi \rangle F_{\alpha I}}{M_I}. \label{Theta} \end{equation} The parameters of the theory~\eqref{Lagr} are restricted by the see-saw mechanism since one has to reproduce the observed values of the mass differences and mixing angles for the active neutrinos~\cite{Esteban:2016qun}.\footnote{The NuFIT group has recently released an updated global analysis of neutrino oscillation measurements, \emph{NuFIT 3.2 (2018), www.nu-fit.org}. In our analysis, we use these updated data. The most important update of v3.2 is the $3 \sigma$ bound on the value of the Dirac phase $\delta$. In the inverted hierarchy case $\delta$ is no longer compatible with zero. We will comment on this in section~\ref{sec:scan_of_the_parameter_spaces}.} A convenient parametrization of the Yukawa couplings which automatically accounts for these observables was proposed by Casas and Ibarra in ref.~\cite{Casas:2001sr}. The application of the Casas-Ibarra parametrization to the $\nu$MSM has been studied in ref.~\cite{Asaka:2011pb}. In the matrix form, the Yukawa couplings entering the Lagrangian~\eqref{Lagr} read (in the notations of refs.~\cite{Eijima:2017anv,Eijima:2017cxr}) \begin{equation} F = \frac{i}{\langle \Phi (0) \rangle} U^{PMNS} m_\nu^{1/2} \Omega m_N^{1/2}, \label{CasasIbarra} \end{equation} where $m_\nu$ and $m_N$ are the diagonal mass matrices of the three active neutrinos and HNLs correspondingly. The matrix $\Omega$ is an arbitrary complex orthogonal $\mathcal{N}_\nu \times \mathcal{N}_N$ matrix, where $\mathcal{N}_\nu$ is the number of left-handed neutrinos and $\mathcal{N}_N$ is the number of right-handed neutrinos. In the $\nu$MSM, the lightest HNL $N_1$ is the dark matter particle. A combination of Lyman-$\alpha$ and X-ray constraints puts strong bounds on the magnitude of its Yukawa couplings, see~\cite{Boyarsky:2009ix} and references therein. As a result, $N_1$ is almost decoupled and does not contribute to the see-saw masses of active neutrinos. Therefore, the masses and mixings of active neutrinos correspond to the case of two HNLs. In this case the matrix $\Omega$ can be chosen in the form \begin{align} \Omega &= \left( \begin{array}{cc} 0 & 0 \\ \cos \omega & \sin \omega \\ -\xi \sin \omega & \xi \cos \omega \\ \end{array} \right)\quad\text{for NH},\\ \Omega &= \left( \begin{array}{cc} \cos \omega & \sin \omega \\ -\xi \sin \omega & \xi \cos \omega \\ 0 & 0 \\ \end{array} \right)\quad\text{for IH}, \end{align} with a complex mixing angle $\omega$. The sign parameter is $\xi= \pm1$. We fix it to be $\xi = +1$, since the change of the sign of $\xi$ can be compensated by $\omega \to - \omega$ along with $ N_3 \to - N_3$~\cite{Abada:2006ea}. Throughout this work, we will use the abbreviations NH and IH to refer to the normal and inverted hierarchy of neutrino masses. In what follows it is convenient to introduce \begin{equation} X_\omega=\exp( \imw). \end{equation} In the case of two right-handed neutrinos, the PMNS matrix contains only two $CP$-violating phases, one Dirac $\delta$ and one Majorana $\eta$, see Appendix \ref{sec:mixing_angles_of_hnls_and_active_neutrinos} for the details of our parametrization of the PMNS matrix. Two Majorana masses in~\eqref{Lagr} can be parametrized by the common mass $M$ and the Majorana mass difference $\Delta M$. Note that the \emph{physical} mass difference controlling the oscillations of two HNLs is a sum of $\Delta M$ and a term proportional to the product of Yukawa couplings with $\langle \Phi \rangle$. The expression for this mass difference can be found in ref.~\cite{Shaposhnikov:2008pf}. We end up with six free parameters of the theory which are listed in table~\ref{table_parameters} along with their ranges considered in this work. \begin{table}[htb!] \begin{center} \begin{tabular}{| c | c | c | c | c | c |} \hline $M$, GeV & $\log_{10} (\Delta M/\mbox{GeV})$ & $\imw$ & $\rew$ & $\delta$ & $\eta$\\ \hline $[0.1 - 10]$ & $[-17,-1]$ & $[-7,7]$ & $[0, 2\pi]$ &$[0, 2\pi]$ & $[0, 2\pi]$\\ \hline \end{tabular} \end{center} \caption{\label{table_parameters} Parameters of the theory: common mass; mass difference; $\imw$; $\rew$; Dirac and Majorana phases. In the second line we indicate the ranges of these parameters which were considered in this work.} \end{table} The common mass $M$ of HNLs is restricted to the $[0.1 - 10]$~GeV interval. The smaller masses are in tension with the Big Bang nucleosynthesis (BBN)~\cite{Ruchayskiy:2012si}. Heavier HNLs, which we do not consider in this work, deserve a separate study. The ranges of the Majorana mass difference $\Delta M$ and $\imw$ are determined by the a posteriori requirement of generating enough BAU. The real part of the complex angle $\omega$ plays a role of a phase, therefore it is enough to restrict it, along with the single Majorana phase, to the interval $[0, 2 \pi]$. The range of the Dirac phase $\delta$ is somewhat more subtle since it was restricted in the recent global analysis of neutrino oscillation measurements. We will comment on this in section~\ref{sec:scan_of_the_parameter_spaces}. Note that the relation~\eqref{CasasIbarra} is not an isomorphism, i.e. more than one set of the parameters lead to the same Yukawas $F_{\alpha I}$ and therefore are physically equivalent. Still, the parametrization~\eqref{CasasIbarra} spans all possible values of Yukawas compatible with the oscillation data. Dependence of the resulting BAU on the Yukawas (and parameters in table~\ref{table_parameters}) is in general very complicated. Therefore a thorough study of the parameter space of the model is required in order to determine the boundary of the region where successful baryogenesis is possible in terms of the experimentally interesting quantities. \section{Experimentally observable quantities} \label{sec:experimentally_observable_quantities} The parameters listed in table~\ref{table_parameters} are useful for the theoretical understanding of the model, but the last four of them cannot be directly measured. In this section, we discuss the experimentally observable quantities and their relations to the parameters of the model. \subsection{The total mixing} \label{sub:the_total_mixing} The formula~\eqref{mixing} establishes the basis for experimental searches of the HNLs. It shows that an amplitude of a process involving HNL $N_I$ is equal to the analogous amplitude involving active neutrino $\nu_\alpha$ multiplied by $\Theta_{\alpha I}$. In order to understand, how weakly HNLs are coupled to the SM in general, it is helpful to sum $|\Theta_{\alpha I}|^2$ over flavours of active neutrinos and over $I=2,3$. This defines the total mixing \begin{equation} |U|^2 \equiv \sum_{\alpha I} |\Theta_{\alpha I}|^2 = \frac{1}{2M}\left[(m_2 + m_3)\left(X_\omega^2 + X_\omega^{-2}\right) + \mathcal{O}\left(\frac{\Delta M}{M} \right)\right], \label{U2} \end{equation} where $m_{2,3}$ are masses of active neutrinos and the normal hierarchy (NH) of the active neutrino masses is assumed (the inverted hierarchy (IH) case can be obtained by replacing $m_2\to m_1, m_3\to m_2$ in~\eqref{U2}). The total mixing~\eqref{U2} controls the amount of HNLs produced in an experiment and the lifetime of these HNLs. \subsection{Individual mixings} \label{sub:individual_mixings} The total mixing~\eqref{U2} is useful to quantify interactions of the HNLs with the SM particles, however, it is not sufficient for determining sensitivity of experiments to the HNLs. Therefore we also consider individual, or flavoured, mixings. To clarify the role of flavoured mixings, let us consider, e.g. the SHiP experiment~\cite{Anelli:2015pba,Alekhin:2015byh}. This is the beam damp-type experiment. An intense proton beam from the SPS accelerator hits the target. The main detector consists of a large empty decay volume with calorimeters and trackers at the end. In the SHiP set-up, HNLs are supposed to be produced mostly in decays of heavy mesons and the observational signatures consist of boosted charged particles originating from a vertex in the empty volume. The production is proportional to the partial decay width of a heavy meson into an HNL $\Gamma(H \to N_I \ell_\alpha)$, which is in turn proportional to the $|\Theta_{I \alpha}|^2$. It is important to note that the HNL production channels with different accompanying leptons $\ell_\alpha$ are in principle distinguishable. In the SHiP, they could be discriminated if the mass of HNLs is close to upper bounds of kinematically allowed regions. Let us illustrate this in an example. Suppose that one observes a decay of an HNL with the mass exceeding $m_{B_c}-m_\mu$ to a muon. This means that the HNL was produced along with an electron in the process $B_c\to N_I e$ since the process $B_c\to N_I \mu$ is kinematically forbidden. The decay widths of HNLs are in turn proportional to $|\Theta_{J \beta}|^2$. The channels with charged leptons $\ell_\beta$ in the final state are also distinguishable. In the example above the product of $|\Theta_{I \alpha}|^2$ and $|\Theta_{I \beta}|^2$ is important. Therefore, individual mixings are phenomenologically relevant. Notice also that for the mass difference range which we are studying here the characteristic oscillation length is several orders of magnitude smaller than the length SHiP shielding and fiducial volume.\footnote{The case when the oscillations of HNLs are important will be addressed in a separate study.} Namely, the oscillation length $100$ m coincides to $\sim 10^{-7}$~eV \emph{physical} mass difference. Therefore for the lepton $\ell_\alpha$ in the target and $\ell_\beta$ in the detector one has to sum incoherently over $I, J$. So the total dependence on mixings is $$ \sum_{I, J = 2,3}|\Theta_{I \alpha}|^2\cdot |\Theta_{J \beta}|^2 =|U_\alpha|^2\cdot|U_\beta|^2. $$ The individual mixings as functions of the parameters are given by \begin{equation} |U_\alpha|^2 \equiv \sum_{I= 2,3}|\Theta_{I \alpha}|^2 = \frac{1}{2M} \left( |C_\alpha^+|^2X_\omega^2 + |C_\alpha^-|^2X_\omega^{-2} + \mathcal{O}\left( \frac{\Delta M}{M} \right) \right), \label{Ua2} \end{equation} where the combinations $C_\alpha^\pm$ for the NH case are \begin{equation} C_\alpha^\pm = i U^{PMNS}_{\alpha 2}\sqrt{m_2} \pm \xi U^{PMNS}_{\alpha 3}\sqrt{m_3} \label{Cpm_nh} \end{equation} and for the IH case \begin{equation} C_\alpha^\pm = i U^{PMNS}_{\alpha 1}\sqrt{m_1} \pm \xi U^{PMNS}_{\alpha 2}\sqrt{m_2}, \label{Cpm_ih} \end{equation} where $U^{PMNS}_{\alpha i}$ with $i=1,2,3$ are the elements of the PMNS matrix (should not be confused with $|U_\alpha|^2$). \section{Cosmologically motivated values of mixings} \label{sec:results} In this section, we present our main results, namely, the values of the total and individual mixings of HNLs with active neutrinos for which the observed BAU can be explained by the $\nu$MSM. We describe how these results were obtained in a separate section~\ref{sec:scan_of_the_parameter_spaces}. The value of the BAU can be characterised in different ways. Throughout this work, we use the variable $Y_B = n_B/s$, where $n_B$ is the baryon number density (particles minus antiparticles) and $s$ is the entropy density. The observed value is $Y_B^{obs} = (8.81 \pm 0.28) \cdot 10^{-11}$~\cite{Patrignani:2016xqp}. For each set of the model parameters, we numerically find the value of $Y_B$. We are interested in the regions of the parameter space where one can reproduce the observed value $Y_B^{obs}$. The regions of successful baryogenesis are shown in figure~\ref{U2_bounds}. In order to indicate how large can be the effect of the theoretical uncertainties in BAU computation, discussed in section~\ref{sec:production_of_the_baryon_asymmetry}, we show the borders of the regions where one can generate $2\cdot Y_B^{obs}$, and $Y_B^{obs}/2$. \begin{figure}[htb!] \centerline{ \includegraphics[width = 0.5\textwidth]{U2_NH.pdf} \includegraphics[width = 0.5\textwidth]{U2_IH.pdf} } \caption{\label{U2_bounds} Within the white regions it is possible to reproduced the observed value of the BAU (black solid curves). The dashed and dotted curves demonstrate how large the possible theoretical uncertainties could be. Namely, the dashed curves correspond to the condition $Y_B \ge 2\cdot Y_B^{obs}$, whereas the dotted lines correspond to $Y_B \ge Y_B^{obs}/2$ accounting for the factor of $2$ uncertainty in the computation of the BAU. The thin grey lines show the see-saw limit, i.e. it is impossible to obtain the correct masses of active neutrinos below these lines. The blue line shows the projected sensitivity of the SHiP experiment ref.~\cite{ship_new} as presented in ref.~\cite{Bondarenko:2018ptm}. \emph{Left panel}: normal hierarchy, \emph{right panel}: inverted hierarchy.} \end{figure} The cosmologically favoured region of the parameter space is larger for light HNLs than it was previously recognized (see also the discussion in section~\ref{sec:comparison_with_other_works}, in particular, figure~\ref{fig:comparison}). The fact that successful baryogenesis is possible for quite large values of the mixings rises the question about the upper bounds of sensitivity of the direct detection experiments. To illustrate this point, we estimate the lifetime of an HNL using expressions for the decay rates of HNLs from ref.~\cite{Gorbunov:2007ak}\footnote{Note that this work was updated recently~\cite{Bondarenko:2018ptm} with new channels added, so our estimate is conservative.}. For instance, let us consider an HNL with the mass $M=5$~GeV and mixings close to the upper boundary in figure~\ref{U2_bounds}. For such an HNL the lifetime is of the order of $5\cdot 10^{-9}$~s. Estimating the gamma factor to be $\simeq 10$ we see that the decay length in the lab frame is less than $15$~m. This implies that, e.g., in the SHiP experiment this HNL will decay well before the detector. Therefore it might be interesting to revisit the current experimental bounds on HNLs. Let us note in passing that there also exist bounds from the Big Bang nucleosynthesis~\cite{Gorbunov:2007ak,Boyarsky:2009ix,Canetti:2012kh}. The question of the derivation of such bounds has been addressed in details for HNLs with the mass below $140$~MeV in ref.~\cite{Ruchayskiy:2012si}. For heavier Majorana HNLs an accurate derivation is still missing. Results for the individual mixings $|U_\alpha|^2$ and products $|U_\alpha|\cdot|U_\beta|$ are presented in figures~\ref{UaUb_NH} and~\ref{UaUb_IH}. { \begin{figure}[htb!] \includegraphics[width = 1.0\textwidth]{UaUb_NH.pdf} \caption{\label{UaUb_NH} Cosmologically motivated regions of the individual mixings $|U_\alpha|^2$ and products $|U_\alpha|\cdot|U_\beta|$. Within the white regions it is possible to reproduced the observed value of the BAU. The common mass is shown in the horizontal axes, whereas the vertical axes show the corresponding product of mixings. NH case.} \end{figure} \begin{figure}[htb!] \includegraphics[width = 1.0\textwidth]{UaUb_IH.pdf} \caption{\label{UaUb_IH} Cosmologically motivated regions of the individual mixings $|U_\alpha|^2$ and products $|U_\alpha|\cdot|U_\beta|$. Within the white regions it is possible to reproduced the observed value of the BAU. The common mass is shown in the horizontal axes, whereas the vertical axes show the corresponding product of mixings. IH case.} \end{figure} } \section{Open access datasets} \label{sec:open_access_data_sets} In the previous section we have presented the boundaries of the regions where all observed BAU can be addresses within the $\nu$MSM in terms of various combinations of the mixings of HNLs and active neutrinos. However, the parameter space of the $\nu$MSM is not completely determined by the plots presented above, and there are more hidden parameters. These parameters can be essential for experimental searches for different signatures, and, e.g. it is interesting to know branching ratios, such as $N\to \pi \ell_\alpha$ determined by $U_e:U_\mu:U_\tau$. For instance, what ratios of $U_e:U_\mu:U_\tau$ are possible for some point in the allowed region of figure~\ref{UaUb_NH} or~\ref{UaUb_IH}? This information is crucial to determine the decay length and branching ratios of various detection channels. In order to fill in this gap, we publish several datasets~\cite{IT}. \begin{itemize} \item Upper and lower boundaries of the $M - |U|^2$ region where successful baryogenesis is possible as functions of the common mass of HNLs. Note that these lines correspond to the region where one can obtain $Y_B\ge Y_B^{obs}$. \item The dataset of models with successful baryogenesis. The value of the BAU for every model (a parameter set) in this list lies in the range $[Y_B^{obs}/2, 2\cdot Y_B^{obs}]$. Note that the value of the $Y_B$ is recorded for each parameter set so one can easily perform another cuts. The models of this dataset can be used to perform detailed Monte Carlo simulations of the experiments because they contain all necessary information ($M, |U_e|^2, |U_\mu|^2, |U_\tau|^2$). \item The dataset of models leading to various values of the BAU. Even though not all of these models provide a correct value of the BAU, they can be used to compare different theoretical approaches. \item Selected benchmark points are gathered in appendix~\ref{sec:benchmark_points}. \end{itemize} \section{Generation of the baryon asymmetry} \label{sec:production_of_the_baryon_asymmetry} \subsection{Kinetic equations} \label{sub:kinetic_equations} In this section, we discuss the machinery of baryogenesis in the $\nu$MSM. We present the kinetic equations which form the basis of the numerical analysis of this paper. These equation possess the same generic structure as those used in refs.~\cite{Asaka:2005pn,Shaposhnikov:2008pf,Canetti:2012kh,Drewes:2016gmt,Hernandez:2016kel,Drewes:2016jae}. However, several important improvements are incorporated. These are: \emph{(i)} splitting of the rates to fermion number conserving and fermion number violating ones~\cite{Eijima:2017anv,Ghiglieri:2017gjz}; \emph{(ii)} accounting for neutrality of the electroweak plasma (this requirement was added to kinetic equations in \cite{Shuve:2014zua}) and \emph{(iii)} non-instantaneous freeze-out of sphalerons studied in~\cite{Eijima:2017cxr,Ghiglieri:2017csp}. The rates entering the kinetic equations are updated using the recent results of ref.~\cite{Ghiglieri:2018wbs}. The only remaining source of possible uncertainties is the averaging procedure described below. The detailed derivation of the equations is presented in appendix~\ref{sec:derivation_of_kinetic_equations}. Here we start from the system of kinetic equations, introduce an ansatz which allows us to integrate these equations over the momentum and show how the gradual freeze-out of the sphaleron processes can be accounted for. The subscripts $2$ and $3$ are inherited from the $\nu$MSM and used to distinguish two HNLs participating in the generation of the BAU. We are interested in coherent oscillations of HNLs and their interactions with leptons. The HNLs $N_2$ and $N_3$ are Majorana fermions with two helicity states each. Helicities are used to distinguish particles from anti-particles. We assign positive fermion number to HNLs with positive helicity and vice versa. Distribution functions and correlations of two HNLs are combined into matrices of density $\rho_N$ ($\rho_{\bar{N}}$ for antiparticles). The kinetic equations for leptons are presented in terms of the densities of the $\Delta_\alpha=L_\alpha-B/3$, where $L_\alpha$ are the lepton numbers and $B$ is the total baryon number. These combinations are not affected by the fast sphaleron processes and change only due to interactions with HNLs, therefore their derivatives are equal to the derivatives of the lepton number densities $n_{L_\alpha}$. Here we present the equations determining the generation of asymmetries in terms of $\Delta_\alpha$. In the next subsection, these asymmetries are related to the BAU. The system of kinetic equations reads \begin{subequations} \begin{align} i \frac{d n_{\Delta_\alpha}}{dt} &= - 2 i \frac{\mu_\alpha}{T} \int \frac{d^{3}k}{(2 \pi)^{3}} \Gamma_{\nu_\alpha} f_{\nu} (1-f_{\nu}) \, + i \int \frac{d^{3}k}{(2 \pi)^{3}} \left( \, \text{\text{Tr}}[\tilde{\Gamma}_{\nu_\alpha} \, \rho_{\bar{N}}] - \, \text{\text{Tr}}[\tilde{\Gamma}_{\nu_\alpha}^\ast \, \rho_{N}] \right),\label{kin_eq_a} \\ i \, \frac{d\rho_{N}}{dt} &= [H_N, \rho_N] - \frac{i}{2} \, \{ \Gamma_{N} , \rho_{N} - \rho_N^{eq} \} - \frac{i}{2} \, \sum_\alpha \tilde{\Gamma}_{N}^\alpha \, \left[ 2 \frac{\mu_\alpha}{T} f_{\nu} (1-f_{\nu}) \right],\label{kin_eq_b} \\ i \, \frac{d\rho_{\bar{N}}}{dt} &= [H_N^\ast, \rho_{\bar{N}}] - \frac{i}{2} \, \{ \Gamma_{N}^\ast , \rho_{\bar{N}} - \rho_N^{eq} \} + \frac{i}{2} \, \sum_\alpha (\tilde{\Gamma}_{N}^\alpha)^\ast \, \left[ 2 \frac{\mu_\alpha}{T} f_{\nu} (1-f_{\nu}) \right]. \label{kin_eq_c} \end{align}\label{KE_1a}\end{subequations} In~\eqref{KE_1a} $f_\nu = 1/\left( e^{k/T}+1 \right) $ is the Fermi-Dirac distribution function of a massless neutrino. The effective Hamiltonian describing the coherent oscillations of HNLs is \begin{equation} H_N = H_0 + H_I, \quad H_0 = -\frac{\Delta M M}{E_N} \sigma_{1}, \quad H_I = h_{+} \sum_{\alpha} Y_{+, \alpha}^{N} + h_{-} \sum_{\alpha} Y_{-, \alpha}^{N}, \label{H_N} \end{equation} where $E_{N}=\sqrt{k_{N}^{2} + M^{2}}$ and $\sigma_1$ is the first Pauli matrix. The damping rates are \begin{equation} \begin{aligned} \Gamma_N &= \Gamma_+ + \Gamma_-,\quad \Gamma_+ = \gamma_+ \sum_{\alpha} Y_{+, \alpha}^{N},\quad \Gamma_- = \gamma_- \sum_{\alpha} Y_{-, \alpha}^{N},\\ \Gamma_{\nu_\alpha} &= (\gamma_+ + \gamma_-) \sum_I h_{\alpha I} h_{\alpha I}^\ast. \end{aligned} \label{damping} \end{equation} The communication terms, describing the transitions from HNLs to active neutrinos, are \begin{equation} \tilde{\Gamma}_N^\alpha = - \gamma_{+} Y_{+, \alpha}^{N} + \gamma_{-} Y_{-, \alpha}^{N}, \quad \tilde{\Gamma}_{\nu_\alpha} = - \gamma_+ Y_{+,\alpha}^{\nu}+ \gamma_- Y_{-,\alpha}^{\nu}. \label{communication} \end{equation} In the expressions above the subscripts $+$ and $-$ refer to the fermion number conserving and violating quantities correspondingly. The functions $h_\pm$ and $\gamma_\pm$ depend only on kinematics (i.e. on the common mass of HNLs). These functions have to be determined over the whole temperature region of the interest. This region includes both symmetric and Higgs phases. In the Higgs phase, the rates can be split---in terms of ref.~\cite{Ghiglieri:2016xye}---into ``direct'' and ``indirect'' contributions\footnote{Note that this separation is gauge dependent~\cite{Ghiglieri:2016xye}. It is the sum of direct and indirect contributions which is gauge independent.}. The direct contributions correspond to the processes where the Higgs field actually propagates. These reactions are also present in the symmetric phase. The processes with the Higgs field replaced by its temperature dependent expectation value give rise to the indirect contributions. These indirect contributions are crucial at low temperatures. As we show below, they are also important for the baryogenesis. \begin{equation} \begin{aligned} h_+ &= h_+^{\rm direct} + \frac{2 \langle \Phi \rangle^2 E_\nu (E_N + k) (E_N + E_\nu)} {k E_N \left( 4(E_N+E_\nu)^2 +\gamma_{\nu (+)}^2 \right) }, \\ h_- &= h_-^{\rm direct} +\frac{2 \langle \Phi \rangle^2 E_\nu (E_N - k) (E_N - E_\nu)} {k E_N \left( 4(E_N-E_\nu)^2 +\gamma_{\nu (-)}^2 \right) }, \\ \gamma_+ &= \gamma_+^{\rm direct} +\frac{2 \langle \Phi \rangle^2 E_\nu (E_N + k)\gamma_{\nu (+)} } {k E_N \left( 4(E_N+E_\nu)^2 +\gamma_{\nu (+)}^2 \right) }, \\ \gamma_- &= \gamma_-^{\rm direct} + \frac{2 \langle \Phi \rangle^2 E_\nu (E_N - k)\gamma_{\nu (-)} } {k E_N \left( 4(E_N-E_\nu)^2 +\gamma_{\nu (-)}^2 \right) }, \end{aligned} \label{gamma_pm} \end{equation} In eqs.~\eqref{gamma_pm} the first and second terms represent the direct and indirect contributions respectively. Below we discuss the direct contributions, the neutrino dumping rates $\gamma_{\nu, (\pm)}$, and the neutrino potential in medium $b$ entering eq.~\eqref{gamma_pm} through $E_\nu = k - b$. The derivation of the indirect contributions is presented in Appendix~\ref{sec:derivation_of_kinetic_equations}. The direct contributions to the effective Hamiltonians $h_\pm$ come from the real part of HNL's self energy $\slashed{\Sigma}_N(p) = \slashed{p} \alpha + \slashed{u} \beta$. Namely, one has\footnote{Note that the term proportional to $\alpha$ has been omitted in ref.~\cite{Ghiglieri:2018wbs} since it is subleading. Here we keep it for completeness. Note also that according to the formal power counting of ref.~\cite{Ghiglieri:2018wbs} the contribution $h_-^{\rm direct}$ has to be omitted as well.} \begin{equation} h_\pm^{\rm direct} = \frac{1}{2p^0} \left( \Re\beta (p^0 \pm p) \mp m_N^2\Re\alpha\right). \end{equation} At hight-temperature limit the function $h_+$ reproduces the standard Weldon correction $T^2/(8k)$~\cite{Weldon:1982bn}. If one neglects $\alpha$, which is numerically insignificant, the $h_-$ is suppressed compared to $h_+$ by a factor $M_N^2/p^2$. Thus $h_-$ is very small in the symmetric phase and, at the same time, the indirect contribution dominates in the Higgs phase. In our numerical computations we use the real part of the HNL safe energy calculated in ref.~\cite{Ghiglieri:2016xye}. We now move to the direct contributions $\gamma_\pm^{\rm direct}$. They originate from $1\leftrightarrow2$, $2\leftrightarrow2$, and $1 + n \leftrightarrow 2 + n$ processes. The latter two require proper resummations~\cite{Anisimov:2010gy,Ghiglieri:2017gjz}. Fermion number conserving rate comes mainly from the $2 \leftrightarrow 2 $ scatterings . Another contribution to $\gamma_+^{\rm direct}$ comes from $1 + n \leftrightarrow 2 + n$. Fermion number violating rate comes from the $1 + n \leftrightarrow 2 + n$ processes (note that $2 \leftrightarrow 2 $ scatterings do not contribute to $\gamma_-^{\rm direct}$). For our numerical analysis we use $\gamma_\pm^{\rm direct}$ kindly provided by the authors of ref.~\cite{Ghiglieri:2018wbs}. It is important to stress that in ref.~\cite{Ghiglieri:2018wbs} the temperature of the electroweak crossover $T_c$ has been extracted from the one loop correction to the Higgs potential. Computed this way, $T_c \simeq 150$~GeV~\cite{Ghiglieri:2016xye}, whereas the non-perturbative result is $T_c^{\rm NP} \simeq 160$~GeV \cite{Laine:2015kra,DOnofrio:2015gop}. Since we are using the rates from ref.~\cite{Ghiglieri:2018wbs}, the crossover temperature is set to $T_c \simeq 150$~GeV. We also implement one-loop running of the couplings following the approach of ref.~\cite{Ghisoiu:2014ena}. The last two ingredients entering \eqref{gamma_pm} are the neutrino dumping rates $\gamma_{\nu, (\pm)}$ and the neutrino potential in the medium $b$. The function $b$ can be calculated following, e.g. refs.~\cite{Notzold:1987ik,Morales:1999ia}. The neutrino damping rates are related to its self energy $\slashed{\Sigma}_\nu(k) = \slashed{k} \left( a+ i \Gamma_k/2 \right) + \slashed{u} \left( b + i \Gamma_u/2 \right)$ as \begin{equation} \gamma_{\nu (+)} = \Gamma_u + 2 k^0 \Gamma_k, \quad \gamma_{\nu (-)} = \Gamma_u. \label{two_nu_rates} \end{equation} In the temperature region of interest, the neutrino damping rates are dominated by $2 \leftrightarrow 2$ process mediated by soft gauge bosons. The calculation of these rates requires proper resummations~\cite{Ghiglieri:2016xye}. We use analytical results presented in ref.~\cite{Ghiglieri:2018wbs}. The dependence on the Yukawa coupling constants factorises out from the rates~\eqref{H_N}--\eqref{communication}. It is convenient to introduce the matrix of Yukawa couplings $h_{\alpha I}$ related to the matrix $F_{\alpha I}$ defined in~\eqref{Lagr} as follows \begin{equation} F_{\alpha I} = h_{\alpha J} [U_N^\ast]_{JI}, \quad U_N = \frac{1}{\sqrt{2}}\begin{pmatrix} -i & 1 \\ i & 1 \end{pmatrix}. \end{equation} In terms of these couplings we have \begin{equation} \begin{aligned} Y_{+, \alpha}^{N} &= \left( Y_{+, \alpha}^{\nu} \right)^T = \begin{pmatrix} h_{\alpha 3} h_{\alpha 3}^\ast & - h_{\alpha 3} h_{\alpha 2}^\ast \\ - h_{\alpha 2} h_{\alpha 3}^\ast & h_{\alpha 2} h_{\alpha 2}^\ast \end{pmatrix},\\ Y_{-, \alpha}^{N} &= \left( Y_{-, \alpha}^{\nu} \right)^T = \begin{pmatrix} h_{\alpha 2} h_{\alpha 2}^\ast & - h_{\alpha 3} h_{\alpha 2}^\ast \\ - h_{\alpha 2} h_{\alpha 3}^\ast & h_{\alpha 3} h_{\alpha 3}^\ast \end{pmatrix}. \end{aligned} \end{equation} The relation between the number densities and the chemical potentials to leptons in eq.~\eqref{KE_1a} has to take into account the neutrality of plasma. When the system is in equilibrium with respect to sphaleron processes, this relation reads \begin{equation} \mu_\alpha = \omega_{\alpha \beta}(T) n_{\Delta_\beta}, \label{susceptibilities} \end{equation} where $\omega_{\alpha \beta}(T)$ is the so-called susceptibility matrix, see, e.g.~\cite{Ghiglieri:2016xye,Eijima:2017cxr}. In the symmetric phase its diagonal elements are ${\omega_{\alpha \alpha} = 514/(237 \, T^2)}$, while the off-diagonal $\omega_{\alpha \beta} = 40/(237 \, T^2), \alpha \neq \beta$. Note that relation~\eqref{susceptibilities} should be modified for temperatures below the $T_{sph}\simeq 131.7$~GeV at which the sphalerons decouple~\cite{DOnofrio:2014rug}. Full expressions of the susceptibility matrices can be found in ref.~\cite{Eijima:2017cxr}. The set~\eqref{KE_1a} is a system of coupled integro-differential equations for each momentum mode of HNLs. Numerical solution of this system is a very complicated task~\cite{Asaka:2011wq,Ghiglieri:2017csp}. However, a certain ansatz could be made to simplify the system. Namely, let us assume that the momentum dependence of the distribution functions is the equilibrium one, $\rho_{X} (k,t) = R_{X}(t) f_N(k)$, where $f_N(k)$ is the Fermi-Dirac distribution of the massive HNLs. Then it is possible to integrate the kinetic equations over the momentum and obtain a set of ordinary differential equations. This procedure is the main source of the theoretical uncertainty. The error can be estimated by comparing solutions of the averaged equations with solutions of the full set~\eqref{KE_1a}. This has been done first in ref.~\cite{Asaka:2011wq}. Results of this work indicate that the error in the value of the BAU doesn't exceed $40 \%$. Authors of the recent study~\cite{Ghiglieri:2017csp} have also solved the full system. They have found that the accurate result differs by a factor of $1.5$ from the benchmark of ref.~\cite{Hernandez:2016kel}. However, note that the equations of ref.~\cite{Ghiglieri:2017csp} include effects that haven't been accounted for in ref.~\cite{Hernandez:2016kel}. We have also tested the benchmark points listed in~\cite{Mikko} using the same neutrino oscillation data as in~\cite{Ghiglieri:2017csp} and found a surprisingly good agreement for the most of the benchmark points. A file with the values of the BAU for all benchmark points could be found in~\cite{IT}. In what follows we will be conservative and assume that the averaging can lead to a factor of two error. Let us finally present the system of equations that we actually solve numerically. It is convenient to introduce the CP-even and CP-odd combinations $\rho_+ \equiv (\rho_N+\rho_{\bar{N}})/2 - \rho_N^{eq}$,\quad $\rho_- \equiv \rho_N - \rho_{\bar{N}}$. The averaged equations read \begin{equation} \begin{aligned} \dot{n}_{\Delta_{\alpha}} = &- \text{Re}\,\overline{\Gamma}_{\nu_{\alpha}} \mu_\alpha\frac{T^2}{6} + 2 i \Tr [(\text{Im}\,\overline{\tilde{\Gamma}}_{\nu_{\alpha}})n_{+}] - \Tr [(\text{Re}\,\overline{\tilde{\Gamma}}_{\nu_{\alpha}}) n_{-}], \\ \dot{n}_{+} = &-i [\text{Re}\,\overline{H}_N,n_{+}] + \frac{1}{2}[\text{Im}\,\overline{H}_N,n_{-}] - \frac{1}{2}\{\text{Re}\,\overline{\Gamma}_N,n_{+}\} - \frac{i}{4} \{\text{Im}\,\overline{\Gamma}_N,n_{-}\} \\ & - \frac{i}{2} \sum (\text{Im}\,\overline{\tilde{\Gamma}}_N^{\alpha})\mu_\alpha\frac{T^2}{6}- S^{eq}, \\ \dot{n}_{-} =&\; 2 [\text{Im}\,\overline{H}_N,n_{+}] -i [\text{Re}\,\overline{H}_N,n_{-}] - i\{\text{Im}\,\overline{\Gamma}_N,n_{+}\} - \frac{1}{2} \{\text{Re}\,\overline{\Gamma}_N,n_{-}\} \\ &- \sum (\text{Re}\,\overline{\tilde{\Gamma}}_N^{\alpha}) \mu_\alpha\frac{T^2}{6}, \label{KE_2} \end{aligned} \end{equation} with the integrated rates defined as \begin{equation} \begin{aligned} \overline{\Gamma}_{\nu_{\alpha}} &= \frac{6}{\pi^2} \int dk_c k_c^2 e^{k_c} f_\nu^2 \Gamma_{\nu_\alpha}, \quad \overline{\tilde{\Gamma}}_{\nu_{\alpha}} = \frac{T^3}{2 \pi^2} \frac{1}{n_N^{eq}} \int dk_c k_c^2 f_N \tilde{\Gamma}_{\nu_\alpha}, \\ \overline{H}_N &= \frac{T^3}{2 \pi^2} \frac{1}{n_N^{eq}} \int dk_c k_c^2 f_N H_N, \quad \overline{\Gamma}_N = \frac{T^3}{2 \pi^2} \frac{1}{n_N^{eq}} \int dk_c k_c^2 f_N \Gamma_N, \\ \overline{\tilde{\Gamma}}^{\alpha}_N &= \frac{6}{\pi^2} \int dk_c k_c^2 e^{k_c} f_\nu^2 \tilde{\Gamma}^{\alpha}_N, \quad S^{eq} = \frac{T^3}{2 \pi^2} \frac{1}{s} \int dk_c k_c^2 \dot{f_N}\cdot {\bf 1}_{2\times 2}. \end{aligned} \label{integrated_rates} \end{equation} Equations~\eqref{KE_2} are formulated in a static universe. The expansion of the Universe can be accounted for by rewriting eqs~\eqref{KE_2} in terms of the so-called yields $Y_X = n_X/s$, where $n_X$ is the number density of species $X$ and $s$ is the entropy density which is conserved in the co-moving volume. For the numerical computations we use $s(T)$ calculated in refs.~\cite{Laine:2006cp,Laine:2015kra}. \subsection{Gradual freeze-out of sphalerons} \label{sub:gradual_freeze_out_of_sphalerons} The asymmetry generated in the lepton sector is communicated to the baryon sector by the sphaleron processes. As long as these processes are fast compared to the rate of the asymmetry generation, the following equilibrium relation holds~\cite{Khlebnikov:1996vj,Burnier:2005hp} \begin{equation} Y_{B^{eq}}=- \chi(T) \sum_\alpha Y_{\Delta_\alpha} , \quad \chi(T) = \frac{4 \left(27 (\sqrt{2}\langle \Phi \rangle/T)^2+77\right)}{333 (\sqrt{2}\langle \Phi \rangle/T)^2+869}, \label{B_eq} \end{equation} where $\langle \Phi \rangle$ is the Higgs vacuum expectation value, which is equal to $174.1$~GeV at zero temperature. However, as was demonstrated in ref.~\cite{Eijima:2017cxr}, a deviation from the equilibrium with respect to sphalerons happens at temperatures around $140$~GeV, i.e., before the freeze-out. It was also shown that the errors stemming from the usage of the equilibrium formula can exceed an order of magnitude. To overcome this problem, one can implement the method suggested in ref.~\cite{Eijima:2017cxr}. Namely, one solves the kinetic equation for the baryon number~\cite{Khlebnikov:1988sr,Burnier:2005hp} \begin{equation} \dot{Y}_B = -\Gamma_B (Y_B-Y_{B^{eq}}), \label{kine_ec_B} \end{equation} where for the three SM generations \begin{equation} \Gamma_B= 3^2\cdot \frac{869 + 333 (\sqrt{2}\langle \Phi \rangle/T)^2}{792 + 306 (\sqrt{2}\langle \Phi \rangle/T)^2} \cdot \frac{\Gamma_{diff}(T)}{T^3} , \label{Gamma_B} \end{equation} were $Y_{B^{eq}}$ is given by eq.~\eqref{B_eq} and $\sum_\alpha Y_{\Delta_\alpha}$ is calculated from the main system~\eqref{KE_2}. It is enough to solve eq~\eqref{kine_ec_B} starting from $T=150$~GeV. This finishes the presentation of the kinetic equations. To summarize, our equations incorporate all physical effects that are relevant for the range of HNL masses considered here. The only source of errors is the momentum averaging of the kinetic equations. Based on the previous studies~\cite{Asaka:2011wq,Ghiglieri:2017csp}, we conservatively estimate that these errors do not exceed a factor of two. \subsection{Physics of asymmetry generation } \label{sub:physics_of_asymmetry_generation_} Before solving eqs.\eqref{KE_2} numerically, we briefly discuss the physics of the asymmetry generation. There are several important temperature scales. One of them is the already mentioned sphaleron freeze-out temperature $T_{sph}\simeq 131.7$~GeV~\cite{DOnofrio:2014rug}. The lepton asymmetry generated at temperatures lower than $T_{sph}$ does not affect the final value of $Y_B$. Second scale is a temperature at which the HNLs enter thermal equilibrium, $T_{in}$. This temperature can be determined from the condition $\overline{\Gamma}_N(T_{in})/H(T_{in})\simeq 1$, where $H(T)$ is the Hubble rate and we take the largest eigenvalue of the matrix $\overline{\Gamma}_N(T_{in})$. The Hubble rate during radiation-dominated epoch is $H(T) = T^2/M_{Pl}^*$, where $M_{Pl}^* = \sqrt{90/(8\pi^3 g_*)} \,M_{Pl}$, $g_*$~is the effective number of relativistic degrees of freedom. Another important scale is the so-called oscillation temperature, $T_{osc}$. Coherent oscillations of the HNLs play the crucial role in the generation of the individual lepton asymmetries. In fact, they provide a CP-even phase, which, being combined with the CP-odd phase from Yukawas, leads to the generation of the individual asymmetries, see, e.g. the discussion in ref.~\cite{Shaposhnikov:2008pf}. This mechanism becomes efficient around the first oscillation. The temperature at which the first oscillation takes place can be estimated as \cite{Akhmedov:1998qx,Asaka:2005pn} \begin{equation} T_{osc} \simeq \left( \frac{\delta M M M_{Pl}^*}{3} \right)^{1/3}, \label{Tosc} \end{equation} where $\delta M$ is the physical mass difference. This mass difference is the splitting between two eigenvalues of the effective Hamiltonian~\eqref{H_N}. Since the asymmetry generation is efficient at $T $ around $ T_{osc}$, one can roughly estimate the lower bound on the $\delta M$ by requiring $T_{osc} > T_{sph}$. Let us consider two cases: \begin{itemize} \item $T_{in} < T_{Sph}$ This regime is sometimes referred to as \emph{oscillatory}. In this case the kinetic equations could be solved perturbatively~\cite{Akhmedov:1998qx,Asaka:2005pn} if also $T_{osc}>T_{Sph}$.\footnote{Note that when the fermion number violating effects are introduced, the total asymmetry is generated at order $F^4$.} Late thermalization implies that Yukawa couplings are relatively small. In terms of the parameters listed in table~\ref{table_parameters}, this regime is realized if the value of $|\imw|$ is small. \item $T_{in} \ge T_{Sph}$ In this case, the dampings of the generated asymmetries are efficient, so this scenario is referred to as \emph{strong wash-out regime}. Yukawa couplings must be relatively large, this can be in agreement with the oscillation data if $|\imw|$ is large as well. Sizeable damping causes a wash-out of asymmetries before the freeze-out of sphaleron processes. However, the production of HNLs and interactions with left-handed leptons at high temperatures are also enhanced, so the asymmetry generation is more efficient. In order to account for all relevant processes, the kinetic equations have to be solved numerically. \end{itemize} \section{Numerical analysis of the kinetic equations} \label{sec:numerical_solution_of_the_equations} Equations~\eqref{KE_2} together with~\eqref{B_eq} or~\eqref{kine_ec_B} allow one to determine the value of the BAU for each parameter set in table~\ref{table_parameters}. For most values of the parameters, the equations~\eqref{KE_2} have to be solved numerically. In this section, we discuss the procedure of solving these equations and demonstrate how the improvements in the equations influence the results. \subsection{The procedure for numerical solution of the equations} \label{sub:the_procedure_for_numerical_solution_of_the_equations} First of all, it is necessary to determine initial conditions. Right after the inflation the baryon and lepton numbers of the Universe as well as number densities of HNLs are equal to zero.\footnote{The effect of the initial asymmetry in the HNL sector has been studied in ref.~\cite{Asaka:2017rdj}.} Thus we start from the vanishing $Y_- (T_{0})\equiv n_-(T_{0})/s(T_{0})$ and $Y_{\Delta_\alpha}(T_{0})$. According to the definition of $\rho_+$, at initial stage $Y_+(T_{0}) = - n^{eq}(T_{0})/s(T_{0})$, where $n^{eq}(T)$ is an equilibrium number density of a fermion with mass $M$. The appropriate initial temperature can be specified on physical grounds. As we have discussed, the asymmetry generation starts around the temperature of the first oscillation, $T_{osc}$. We have checked numerically that no significant asymmetry is generated at the temperature $10\cdot T_{osc}$, i.e. much before the onset of oscillations. Therefore we take $T_{0}=10\cdot T_{osc}$ if $10\cdot T_{osc} > 10^3$~GeV, or $T_0 = 10^3$~GeV otherwise. Now, having set up the initial conditions, we can solve equations~\eqref{KE_2}. It is convenient to implement them using $z = \log(M/T)$ as a variable. Even though the problem is reduced to the solution of the set of 11 ordinary differential equations (ODE) by means of averaging~\eqref{integrated_rates}, it still remains challenging. The reason is that significantly different time scales are present in the system~\eqref{KE_2}. Appropriate stiff ODE solvers, such as LSODA~\cite{LSODE}, can handle our equations quite efficiently. However, the integration time can be reduced further. Notice that the effective Hamiltonian entering equations~\eqref{KE_1a} can be decomposed as $H_N = H_0 + H_I$, where $H_0 = -\Delta M M \sigma_{1}/E_N $. Therefore, we can move to the `interaction picture' with respect to $H_0$. After this transformation, the equations can be solved using a non-stiff method. The final value of the BAU is founded by solving eq.~\eqref{kine_ec_B}. This ensures that the value of the BAU is not affected by the assumption of an instantaneous freeze-out of sphalerons. In order to find an appropriate method we have implemented equations~\eqref{KE_2} in the Python programming language. The SciPy library~\cite{scipy} allows one to use several different ODE solvers. We have found that the most efficient (in terms of the number of calls of the r.h.s.) one for our purposes is the LSODE~\cite{LSODE}. The equations were then coded in the Fortran 77/95 along with the native Fortran implementation of the LSODE~\cite{netlib}. Note that for the successful integration it is important to carefully tune the parameters of the solver (such as absolute and relative tolerances for each variable). We have also implemented the same system of kinetic equations in Mathematica \cite{Mathematica}. This allowed us to validate the results obtained using the Fortran code. However, since the computation of r.h.s. takes much longer, the overall computation time is also very large. The Fortran realization outperforms the Mathematica one by more than four orders of magnitude. The whole computation of the BAU for a single set of the parameters takes from $\simeq 0.05$~sec in the oscillatory regime (approximately $|\imw| < 2$) to $\simeq 1.0$~sec in the strong wash-out regime (approximately $|\rew| > 5.5$). The very efficient numerical procedure allows performing a comprehensive study of the parameter space. \subsection{Analysis of the equations} \label{sub:analysis_of_the_equations} Before presenting the phenomenologically relevant results it is instructive to study the outcome of the improvements of the kinetic equations. First of all, it is interesting to see what values of mass splitting $\Delta M$ and $X_\omega$ can lead to a successful baryogenesis. In figure~\ref{Xw_dM_bounds} we show the regions in the $X_\omega - \Delta M$ plane where the value of the $Y_B\ge Y_B^{obs}$ can be generated. To obtain this plot we have fixed the phases to the following values \begin{subequations} \begin{align} \mbox{NH:} &\quad \delta = \pi , \quad \eta = 3 \pi/2,\quad \rew = \pi/4, \label{NHphases0}\\ \mbox{IH:} &\quad \delta = 0,\quad \, \eta = \pi/2,\quad \;\, \rew = \pi/4. \label{IHphases0} \end{align} \label{fixed_phases0}\end{subequations} This choice of phases maximizes the value of $|Y_B|$ in the strong wash-out regime (see more detailed discussion in section~\ref{sec:scan_of_the_parameter_spaces}). \begin{figure}[htb!] \centerline{ \includegraphics[width = 0.5\textwidth]{Xw_dM_NH.pdf} \includegraphics[width = 0.5\textwidth]{Xw_dM_IH.pdf} } \caption{\label{Xw_dM_bounds}Allowed region in the $X_\omega - \Delta M$ plane obtained for the fixed values of the phases~\eqref{fixed_phases}. It is possible to generate $Y_B\ge Y_B^{obs}$ within the corresponding regions. Common masses of the HNLs are fixed to be equal to $0.1, 1.0, 10$~GeV. The blue horizontal line indicates the zero-temperature Higgs contribution to the physical mass difference $\delta M$ in the limit $\Delta M/M\to0$. } \end{figure} Note that since the values of Dirac and Majorana phases were fixed and only $\imw$ was varied, the contours are not symmetric. In all cases the positive $\imw$ (large $X_\omega$) gives larger BAU, as can be seen from figure~\ref{Xw_dM_bounds}. The blue horizontal line in figure~\ref{Xw_dM_bounds} indicates the zero-temperature Higgs contribution to the physical mass difference $\delta M$ in the limit $\Delta M/M\to0$. Below this line the Higgs contributions to the physical mass difference dominates, whereas above the line, the physical mass difference is mostly determined by the Majorana mass difference. This means that $\delta M$ cannot be much smaller than $\Delta M$ in the region above the line and $\delta M$ cannot be much smaller than the Higgs contribution below the line. Smaller values of $\delta M$---which are interesting, e.g. for studies of resolvable HNL oscillations at the SHiP experiment---are only possible if there is a cancellation between $\Delta M$ and the Higgs contribution. This cancellation can happen only close to the blue line. It is also important to understand the role of the improvements that we consider. We want to address the questions: \emph{(i)} what is the effect of the fermion number violating rates on the final value of the BAU; \emph{(ii)} what is the effect of considering the Higgs phase; \emph{(iii)} what is the effect of susceptibilities; \emph{(iv)} what is the effect of the gradual decoupling of the sphalerons. In order to answer the first question, we effectively switch off fermion number violating processes in our kinetic equations. It is possible because the fermion number conserving and fermion number violating processes are neatly separated in eqs.\eqref{H_N},~\eqref{damping} and~\eqref{communication}. So we can set $\gamma_- = h_- = 0$ for the whole range of temperatures. In order to model the absence of the Higgs phase at temperatures down to $130$~GeV we put $\langle \Phi (T) \rangle = 0$. We consider the NH case and two different values of the common mass, $1$~GeV and $10$~GeV. The phases are fixed to the values~\eqref{NHphases0}. We present the results in figure~\ref{diff}. \begin{figure}[htb!] \centerline{ \includegraphics[width = 0.5\textwidth]{contour_YBHNM1} \includegraphics[width = 0.5\textwidth]{contour_YBHNM10} } \caption{\label{diff} Red, solid line -- full kinetic equations~\eqref{KE_2}. No fermion number violation -- green, dashed lines. Blue, dotted lines correspond to an assumption, $T_\text{EWPT} \simeq T_\text{sph}$, which has been used in a number of previous works so far. \emph{Left panel}, common mass $M = 1$~GeV. \emph{Right panel}, common mass $M = 10$~GeV. } \end{figure} In order to see how accounting for the charge neutrality of plasma modifies the results we replace the susceptibility matrix in~\eqref{susceptibilities} by a diagonal one. In figure~\ref{sus_sph} we compare results with and without susceptibilities. One can see that the effect is quite sizeable. In the same figure we demonstrate the results with and without careful treatment of sphalerons. \begin{figure}[htb!] \centerline{ \includegraphics[width = 0.5\textwidth]{Xw_dM_NH_compar1.pdf} \includegraphics[width = 0.5\textwidth]{Xw_dM_NH_compar10.pdf} } \caption{\label{sus_sph} Comparing the kinetic equations with accurate susceptibilities and accurate treatment of sphalerons (red curve), with diagonal susceptibilities (no plasma neutrality) (green dashed curve) and with the instantaneous freeze-out of sphalerons (blue dotted curve). The same choice of phases as in the previous figure. \emph{Left panel}, common mass $M = 1$~GeV. \emph{Right panel}, common mass $M = 10$~GeV. } \end{figure} Inspecting figures~\ref{diff} and~\ref{sus_sph} one can arrive at the following conclusions. \begin{itemize} \item Fermion number violating rates.\\ Accounting for the fermion number violation increases the $Y_B$. See figure~\ref{diff}, green dashed lines. \item Broken phase.\\ Equations without the fermion number violation solved under the assumption that the Higgs vacuum expectation value is zero at all temperatures above the $T_{sph}$ lead to larger amount of the $Y_B$ for heavy HNLs at large $|\imw|$. See figure~\ref{diff}, blue dotted lines. \item Neutrality of plasma.\\ Accounting for the neutrality of plasma by means of susceptibilities is important. The effect is stronger for lighter HNLs. See figure~\ref{sus_sph}. \item Freeze-out of sphalerons.\\ The boundary of the allowed region in figure~\ref{sus_sph} is not sensitive to the method of calculation of the BAU from the lepton asymmetry. In fact, if one is interested in the upper bounds on the mixings (large $|\imw|$) the instantaneous freeze-out of sphalerons can be assumed. See figure~\ref{sus_sph}. \end{itemize} \section{Study of the parameter space} \label{sec:scan_of_the_parameter_spaces} In this section, we describe how the study of the parameter space of the model have been performed. Our strategy is a direct sampling of the parameters defining the theory. In subsection~\ref{sub:bounds_on_the_total_mixings} we fix specific values of the phases $\delta, \;\eta, \;\rew$ which maximize the generated asymmetry. In subsection~\ref{sub:bounds_on_the_individual_mixings} we sample the whole $6$ dimensional parameter space. \subsection{Total mixing} \label{sub:bounds_on_the_total_mixings} In order to set the bound on the value of the total mixing~\eqref{U2} we need to find, for each value of the common mass, the largest value of $|U|^2$. Since the value of $|U|^2$ for a given mass depends only on $\imw$, one can marginalize over phases $\delta, \;\eta, \; \rew$ and mass difference $\Delta M$ and solve an optimization problem for $\imw$. The optimization problem consists of maximizing (or minimizing for negative values) $\imw$ subject to $Y_B \simeq Y_B^{obs}$. Several comments are in order. The value $Y_B$ can be both positive or negative. If it is possible to obtain some value $Y_B^1$ for some $X_\omega$ and mass difference, then it is also possible to obtain $-Y_B^1$ for the same $X_\omega$ and $\Delta M$ provided that the phase parameters in the model can vary freely. In what follows we would always take the absolute value $|Y_B|$ of the computed BAU. Next, it is important to clarify what does $Y_B \simeq Y_B^{obs}$ actually mean. The kinetic equations that we solve contain an inherent error stemming from the assumption of equilibrium momentum dependence of density matrices. In order to account for this theoretical uncertainty we impose the following condition $Y_B^{obs}/2 < |Y_B| < 2 Y_B^{obs}$. In practice, it is easier to maximize $|Y_B|$ for given values of $\imw$ and $M$. If the maximal value of $|Y_B|$ exceeds e.g. $Y_B^{obs}$, then it is also possible to generate a smaller value of asymmetry. One can iterate this procedure on a grid in $\imw$ and $M$ space. Then by interpolating $|Y_B|$ as a function of $\imw$ for a given $M$ and finding roots of the equation $|Y_B| = \kappa Y_B^{obs}$, $\kappa = 0.5, 1, 2$, one can find the upper and lower bounds on $|U|^2$. The case of $\kappa = 2$ corresponds to the conservative assumption that the averaging procedure amounts to a twice larger asymmetry compared to the accurate treatment. Authors of ref.~\cite{Ghiglieri:2017csp} have solved the full system of equations for several parameter points. Their results indicate that the averaged equations rather tend to underestimate the value of BAU. This case is indicated by $\kappa = 0.5$. Maximizing $|Y_B|$ with respect to $\Delta M, \rew, \delta, \eta$ is a resource demanding task. It can be significantly simplified in the strong wash-out regime, i.e. for large values $| \imw |$. In this regime the value of the total asymmetry strongly depends on the difference in the damping rates of active neutrinos. For a given mass, $X_\omega$ and mass difference the damping rates are controlled by Dirac and Majorana phases together with the real part of $\omega$. Note that a set of phases that maximizes the difference among these damping rates (and, the total lepton asymmetry consequently) also minimizes (maximizes in the case of IH) $|U_e|^2$. We have used the following values\footnote{The value $\delta = 0$ for the IH case is incompatible with the recent $3 \sigma$ bounds of the NuFit 3.2 analysis. However, setting $\delta= 354^\circ$ doesn't change the results presented here.} \begin{subequations} \begin{align} \mbox{NH:} &\quad \delta = \pi , \quad \eta = 3 \pi/2,\quad \rew = \pi/4, \label{NHphases}\\ \mbox{IH:} &\quad \delta = 0,\quad \, \eta = \pi/2,\quad \;\, \rew = \pi/4. \label{IHphases} \end{align} \label{fixed_phases}\end{subequations} These choices of phases maximize one of the individual mixings $U_\alpha$ (see Appendix~\ref{sec:mixing_angles_of_hnls_and_active_neutrinos}). For the NH case the phases \eqref{NHphases} maximize $U_\mu$, while for the IH case the phases~\eqref{IHphases} maximize $U_e$. Since the phases are fixed, we need to find only the value of $\Delta M$ which maximizes BAU at each point of the $M-\imw $ grid. The upper bounds in figure~\ref{U2_bounds} were obtained using the method described above. Let us stress that the same upper bounds can be obtained by the random sampling described in the next subsection. We have checked that two methods agree with each other. The lower bounds on the $|U|^2$ obtained with the fixed phases~\eqref{fixed_phases} are not optimal, since the asymmetry is generated in the oscillatory regime. Therefore, the lower bounds in figure~\ref{U2_bounds} are obtained by the direct sampling. \subsection{Individual mixings} \label{sub:bounds_on_the_individual_mixings} The mixings $|U_\alpha|^2$ depend on $\delta$ and $\eta$ through the elements of the PMNS matrix entering eqs.~\eqref{Cpm_nh} or~\eqref{Cpm_ih}. Therefore it is no longer possible to solve a simple optimization problem, as was the case for $|U|^2$. However, our numerical routines solve kinetic equations for different values of parameters very efficiently. This allows us to perform a scan of the full parameter space. The parameter space is sampled as follows. As was already mentioned, we are restricted to the discrete grid in the common mass $M$ in the interval $[0.1, 10.0]$ GeV. The rest of parameters we sample randomly, so that $\log_{10} \Delta M, \imw, \rew, \delta, \eta$ are distributed uniformly in the intervals specified in table~\ref{table_parameters}.\footnote{Note that for the Dirac phase we have actually used the $3 \sigma$ interval from the NuFit 3.2 analysis. Namely, $\delta \in [144^\circ, 374^\circ]$ in the NH case, and $\delta \in [192^\circ, 354^\circ]$ in the IH case. } Note that according to eq.~\eqref{U2A}, the uniform distribution in $\imw$ approximately coincides to a uniform distribution of $|U_\alpha|^2$ in log-scale. However, in order to obtain the upper bounds more accurately, we also perform a flat sampling in the $X_\omega$. After computing the value of BAU for each point we select the points according to the criterion $|Y_B| > Y_B^{obs}$. In order to plot figures \ref{UaUb_NH} and \ref{UaUb_IH} we have generated \num{2800000} points for each hierarchy type and selected only those points for which $|Y_B| > Y_B^{obs}$. We also have utilized these datasets to obtain the lower bounds and to cross check the upper bounds on the total mixing $|U|^2$. \section{Comparison with other works} \label{sec:comparison_with_other_works} \begin{figure}[htb!] \centerline{ \includegraphics[width = 0.5\textwidth]{comparison_NH.pdf} \includegraphics[width = 0.5\textwidth]{comparison_IH.pdf} } \caption{\label{fig:comparison}Comparison of the bounds from three different works. Our lower bounds (black solid lines) are obtained from the parameter sampling, whereas upper bounds are obtained for fixed phases. } \end{figure} Baryogenesis in the $\nu$MSM has attracted a lot of attention of the community in recent years. The first scan of the parameter space was performed in refs~\cite{Canetti:2012vf, Canetti:2012kh}. Authors of ref.~\cite{Shuve:2014zua} have accounted for the neutrality of the electroweak plasma which leads to $\mathcal{O}(1)$ corrections to the final asymmetry. More recently, scans of the parameter space were performed by two groups, see refs.~\cite{Drewes:2016gmt,Hernandez:2016kel}. The role of fermion number violating processes was clarified in refs~\cite{Hambye:2016sby, Eijima:2017anv,Ghiglieri:2017gjz,Hambye:2017elz}. Implications of a non-instantaneous freeze-out of sphalerons were addressed in refs.~\cite{Eijima:2017cxr,Ghiglieri:2017csp}. In what follows we list corresponding works. \begin{description} \item \textbf{L. Canetti, M. Drewes, T. Frossard, and M. Shaposhnikov \cite{Canetti:2012vf, Canetti:2012kh}}\\ The first detailed study of the parameter space. Only the symmetric phase has been considered. Asymmetries in the leptonic sector were described by means of the chemical potentials, i.e. neutrality of the plasma has not been accounted for. The rates were underestimated by a factor of two (see table~\ref{table_rates} below). In the scan of the parameter space the values of phases were fixed to non-optimal values. As a result, the allowed region of the parameter space is much smaller compared to what we have obtained in this work. \item \textbf{M. Drewes, B. Garbrecht, D. Gueter, and J. Klaric \cite{Drewes:2016gmt,Drewes:2016jae}}\\ In ref.~\cite{Drewes:2016gmt} only the symmetric phase has been considered. The kinetic equations were generalized to the broken phase in ref.~\cite{Drewes:2016jae}. The rescaling of the parameters that simplified computations has been suggested in ref.~\cite{Drewes:2016gmt}. The relation between leptonic chemical potentials and number densities accounting for the neutrality of the plasma has been implemented. This relation is analogous to eq~\eqref{susceptibilities}, however it is valid only at large temperatures. In high-temperature limit this relation agrees with eq~\eqref{susceptibilities}. Note the persistent disagreement between the damping rate of the active neutrinos in ref.~\cite{Drewes:2016gmt} and in our work (see discussion below). \item \textbf{P. Hern\'{a}ndez, M. Kekic, J. L\'{o}pez-Pav\'{o}n, J. Racker and J. Salvado \cite{Hernandez:2016kel}}\\ Only the symmetric phase has been considered. The neutrality of the plasma has been accounted for, however, apparently, the susceptibilities disagree with those in ref.~\cite{Drewes:2016gmt} and with ours at high-temperature limit.\footnote{ It is important to clarify that the matrix $C_{\alpha \beta}$, entering eq. (2.20) from ref.~\cite{Hernandez:2016kel} agrees with our matrix $\omega_{\alpha \beta}$ from eq.~\eqref{susceptibilities} provided that in ref.~\cite{Hernandez:2016kel} the symbol $\mu_\alpha$ denotes the chemical potential to left-handed leptons. Note that our $\mu_\alpha$ are the chemical potentials to all leptons of flavour $\alpha$. Therefore, $\mu_\alpha^{(ref.~[33])} = \mu_\alpha^{(our)} - \mu_Y/2$, where $\mu_Y$ is the chemical potential to the hypercharge. We thank Jacopo Ghiglieri for pointing this out. However, once the chemical potentials are eliminated from the kinetic equations by means of eqs.~\eqref{susceptibilities} and (2.20) from ref.~\cite{Hernandez:2016kel}, the equations are actually different. Namely, in the r.h.s. of the equations the terms proportional to $\sum_\beta \omega_{\alpha, \beta} Y_{\Delta_\beta}$ will appear. The matrices multiplying $Y_{\Delta_\beta}$ are different in ref.~\cite{Hernandez:2016kel} and in this work. } The approach to the study of the parameter space is different from what we use in this work. The parameter space has been sampled by means of the Markov Chain Monte Carlo (MCMC) with certain priors. The cosmologically allowed regions of the parameter space were presented as contours $90\%$ of all generated points. This method resulted in regions which are much smaller compared to what we have obtained in this work. \item \textbf{S. Antusch, E. Cazzato, M. Drewes, O. Fischer, B. Garbrecht, D. Gueter et al \cite{Antusch:2017pkq}}\\ The scan of the parameter space of heavy HNLs ($M>5$~GeV). Fermion number violating processes have been accounted for in the symmetric phase. The parameter space has been sampled by means of the Markov Chain Monte Carlo (MCMC). However, the selection criteria is different from~\cite{Hernandez:2016kel}. Namely, the models leading to $Y_B^{obs}- 5 \sigma_{Y_B^{obs}} < |Y_B| < Y_B^{obs} + 5 \sigma_{Y_B^{obs}} $ were selected. This approximately corresponds to $0.68\cdot Y_B^{obs} < |Y_B| < 1.32\cdot Y_B^{obs}$. Let us emphasize that the uncertainties in the value of $|Y_B|$ are theoretical, whereas the experimental uncertainty, characterized by $\sigma_{Y_B^{obs}}$ is much smaller. This is the reason why throughout this work we consider a larger interval for $|Y_B|$. \item \textbf{J. Ghiglieri and M. Laine~\cite{Ghiglieri:2016xye,Ghiglieri:2017gjz,Ghiglieri:2017csp,Ghiglieri:2018wbs}}\\ There were no scans of the parameter space. However, a thorough derivation of all rates has been performed. The susceptibilities have been calculated accounting for the non-zero masses of the fermions in ref.~\cite{Ghiglieri:2016xye}. The full non-averaged system has been solved for several benchmark points in ref.~\cite{Ghiglieri:2017csp}. After the ArXiv version of this paper had been released, a new study~\cite{Ghiglieri:2018wbs} appeared. This work contains the most up-to-date determination of both fermion number conserving and violating rates in the whole temperature region relevant for baryogenesis. It was pointed out in ref.~\cite{Ghiglieri:2018wbs} that the $2k \Gamma_k$ part of the $\gamma_{\nu (+)}$ was missing in the ArXiv version of the present paper. In the current version of the paper we correct this point. We have also updated all rates entering the kinetic equations using the results of ref.~\cite{Ghiglieri:2018wbs}. \item \textbf{T. Hambye and D. Teresi~\cite{Hambye:2016sby,Hambye:2017elz}}\\ There were no scans of the parameter space. A role of fermion number violating Higgs decays has been discussed. The considerations of ref.~\cite{Hambye:2017elz} are limited to the Higgs decays and inverse decays. The rate of the fermion number conserving processes has been underestimated compared to the ones including $2 \leftrightarrow 2$ scatterings. This can be seen, e.g. from figure 4 of ref.~\cite{Ghiglieri:2017gjz}. Therefore, a direct comparison between our study and ref.~\cite{Hambye:2017elz} is not straightforward. \end{description} It is important to note that the generic structure of kinetic equations is the same in all studies of the low-scale leptogenesis. Therefore it is possible to compare the rates in the kinetic equations independently of their derivation. In order to be able to compare refs~\cite{Canetti:2012kh,Drewes:2016gmt,Hernandez:2016kel,Ghiglieri:2017csp}, we compute the corresponding rates at temperature $T_{ref} = 10^3$~GeV. At this temperature the rates are dominated by lepton number conserving processes. The production rate of HNLs, the communication term of HNLs, the damping term of the lepton asymmetries and their communication term can be described as \begin{align} \overline{\Gamma}_N/h^2 = C_1\cdot T, \\ \overline{\tilde{\Gamma}}_N/h^2 = C_2\cdot T\\ \overline{\Gamma}_\nu/h^2 = C_3 \cdot T\\ \overline{\tilde{\Gamma}}_\nu/h^2 = C_4\cdot T \end{align} where $h^2$ is a symbolic representation of an appropriate product of Yukawa coupling constants for each term. The values of the coefficients $C_i$ in considered works are summarized in table~\ref{table_rates}. Note that since authors of ref.~\cite{Ghiglieri:2017csp} treat the momentum dependence exactly in their numerical computations, we cannot compare their rates, however the hierarchy among the rates and their values at $k = 3 T$ are the same as ours. \begin{table}[htb!] \begin{center} \begin{tabular}{| c || c | c | c | c |} \hline Article & $C_1$ & $C_2$ & $C_3$ & $C_4$ \\ \hline This work & 0.0097 & 0.0086 & 0.0086 & 0.0097 \\ \hline L. Canetti et al.~\cite{Canetti:2012kh} & 0.005 & 0.005 &0.005 & 0.005 \\ \hline M. Drewes et al.~\cite{Drewes:2016gmt} & 0.012 & 0.012 & 0.006 & 0.006 \\ \hline P. Hern\'{a}ndez et al.~\cite{Hernandez:2016kel} & 0.0118 & 0.0069 & 0.0076 & 0.0130 \\ \hline \end{tabular} \end{center} \caption{\label{table_rates} The coefficients of the rates in considered works.} \end{table} Leaving aside ref.~\cite{Canetti:2012kh}, one can see that the values of the coefficient $C_1$ do agree with a reasonable precision. However, the values of the other coefficients differ roughly by a factor of two from work to work. In order to understand this difference, we numerically solve our kinetic equations with the rates multiplied by a constant coefficients $\kappa_a$ $(a=1,2,3,4)$ as follows. \begin{subequations} \begin{align} \overline{\Gamma}_N &\rightarrow \kappa_1 \overline{\Gamma}_N, \\ \overline{\tilde{\Gamma}}_N &\rightarrow \kappa_2 \overline{\tilde{\Gamma}}_N, \\ \overline{\Gamma}_\nu &\rightarrow \kappa_3 \overline{\Gamma}_\nu, \\ \overline{\tilde{\Gamma}}_\nu &\rightarrow \kappa_4 \overline{\tilde{\Gamma}}_\nu. \end{align}\label{modification}\end{subequations} Four different cases are considered. \begin{description} \item[case 1] : $\kappa_1 = \kappa_2 = \kappa_3 = \kappa_4 = 1$ for our equations (red lines in the following plot). \item[case 2] : $\kappa_1 = \kappa_2 = \kappa_3 = \kappa_4 = \frac{1}{2}$ for ref~\cite{Canetti:2012kh} by L. Canetti et al. (magenta lines). \item[case 3] : $\kappa_1 = \kappa_2 = 1$ and $\kappa_3 = \kappa_4 = \frac{1}{2}$ for ref~\cite{Drewes:2016gmt} M. Drewes et al. (blue lines).\footnote{ After the preprint of this paper had been released, we received a comment from the authors of refs.~\cite{Drewes:2016gmt,Drewes:2016jae}. They found a missing factor of two in their calculations. Once this factor is corrected, the relative sizes of the coefficients $C_i$ in the corresponding row of table~\ref{table_rates} will approximately agree with these of ref~\cite{Hernandez:2016kel}. Namely, the \textbf{case 4 } will be realized. } \item[case 4] : $\kappa_1 = \kappa_4 = 1$ and $\kappa_2 = \kappa_3 = \frac{1}{2}$ for ref~\cite{Hernandez:2016kel} by P. Hernandez et al. (green lines). \end{description} For the cases 2, 3, and 4 the values above do not reproduce the kinetic equations in each works exactly, but allow us to understand the qualitative behaviour in each case. We demonstrate the time-evolution of asymmetries up to $T=160 \, \text{GeV}$ in figure~\ref{fig:evo_Iw1}. \begin{figure}[!bth] \centerline{ \includegraphics[clip, width=0.5\textwidth]{EvoYBcom_factor_dM-7Iw1.pdf}\\ \includegraphics[clip, width=0.5\textwidth]{EvoYBcom_factor_dM-7Iw5.pdf} } \caption{Time-evolution of asymmetris; solid lines are sum of asymmetries in the left-handed lepton sector and dashed lines are that of the HNL sector. Note that blue and green dashed lines are overlapped. The common mass $M=1$~GeV, phases are fixed to the values~\eqref{fixed_phases}. \emph{Left panel:} $\Delta M = 10^{-7} \, \text{GeV}$ and $\text{Im} \, \omega = 1$. \emph{Right panel:} $\Delta M = 10^{-7} \, \text{GeV}$ and $\text{Im} \, \omega =5$. } \label{fig:evo_Iw1} \end{figure} The qualitative picture of figure~\ref{fig:evo_Iw1} agrees with the results presented in figure~\ref{fig:comparison}. There is also an important comment regarding studies of the parameter space. In fact, each point in this space defines a \emph{theory}. It is not clear at all what could be a prior probability in the space of theories. The problem is not entirely philosophical. This can be most easily seen comparing the first columns of sub-plots in figures 4 and 5 from ref.~\cite{Hernandez:2016kel} with the diagonal sub-plots in our figures~\ref{UaUb_IH} and~\ref{UaUb_NH}. Our allowed regions of the parameters space a much larger than the contours shown in ref.~\cite{Hernandez:2016kel}. The reason for this difference is that the study of ref.~\cite{Hernandez:2016kel} relied on a Bayesian analysis of the Markov Chain Monte Carlo (MCMC). This analysis assumes certain prior probabilities in the space of theories and depends strongly on the chosen priors~\cite{Hernandez:2016kel}. We advocate the point of view that each parameter point leading to the correct values of the observables (such as neutrino mixing angles and the value of the BAU) should be accounted for. \section{Conclusions and outlook} \label{sec:conclusions_and_outlook} In this work we have performed the thorough study of the parameter space of baryogenesis in the $\nu$MSM. All important effects have been accounted for in our kinetic equations. Our study improves that of previous works in several respects. \emph{(i)} The rates entering kinetic equations are calculated from the parameters of the theory. In the symmetric phase, as one can see from the table~\ref{table_rates}, in ref.~\cite{Canetti:2012kh} the values of the rates were consistently underestimated. Moreover, apart from a factor of two difference in the damping rates, there is an agreement among all studies. Note also that all considered rates are practically the same in our work and in ref.~\cite{Ghiglieri:2017csp}. \emph{(ii)} In the broken phase the effects of the fermion number violation were systematically taken into account for the first time. These effects are important for the baryogenesis even though the temperature interval between the electroweak crossover and the sphaleron freeze-out is rather small. \emph{(iii)} We have accurately accounted for the sphaleron freeze-out utilizing the `improved approach' of ref.~\cite{Eijima:2017cxr}. \emph{(iv)} Last but not the least improvement is related to the performance of the ODE solver which was used to solve the kinetic equations numerically. Impressive increase of efficiency of the numerical routine allowed us to perform a comprehensive sampling of the parameter space. Our main results are upper and lower bounds of the region where successful baryogenesis in the $\nu$MSM is possible. We list them and stress significant points. \begin{itemize} \item Bounds in the $|U|^2 - M$ plane, figure~\ref{U2_bounds}. The allowed region is significantly larger for light HNLs compared to the previous studies. Let us emphasize that the position of the upper bound is actually important for the direct detection. Even though this region seems to be the easiest for the direct detection owing to the most efficient production of HNLs, it might be actually not the case, because the life time of HNLs is short. HNLs can decay before they reach the detector. See the line of the SHiP experiment in figure~\ref{U2_bounds}. Also, it might be interesting to update the study of the neutrinoless double beta decay in the $\nu$MSM, refs.~\cite{Drewes:2016lqo,Hernandez:2016kel,Asaka:2016zib}. \item Bounds on individual mixings $|U_\alpha|\cdot|U_\beta|$ as functions of $M$. Note that we present also the off-diagonal elements. These are important for thorough simulations of the experimental sensitivity. \item The dataset of different choices of the parameters of the $\nu$MSM. This dataset can be used to compare our approach with other groups. As we have already stressed, we use momentum averaged kinetic equations. Computation of the BAU in the full system is highly non-trivial and a scan of the parameter space is very demanding. Therefore our parameter sets can be used as benchmark points to test different regimes of the BAU production with the accurate non-averaged equations. Models from the dataset could also be used by experimental collaborations for Monte Carlo simulations. \end{itemize} \acknowledgments We are grateful to Jacopo Ghiglieri and Mikko Laine for helpful discussions and for sharing the numerical data on the direct rates from ref.~\cite{Ghiglieri:2018wbs}. We thank Alexey Boyarsky, Jacopo Ghiglieri, Mikko Laine, and Oleg Ruchayskiy for helpful comments on the paper. We thank Juraj Claric for useful discussions and for sharing the data points from ref.~\cite{Drewes:2016jae}. We also thank Jacobo L\'{o}pez-Pav\'{o}n for discussions related to the plasma neutrality and the comparison of kinetic equations. This work was supported by the ERC-AdG-2015 grant 694896. The work of M.S. and I.T. was supported partially by the Swiss National Science Foundation.
\section{Introduction}\label{sec:introduction} \input{introduction} \section{Results and discussion}\label{sec:results} \input{network_structure} \input{nobility} \section{Conclusion} \input{conclusion} \section{Methods} \input{methods} \section{Acknowledgements} V.I.H was supported by the Accelerated Materials Design and Discovery program at Toyota Research Institute. \bibliographystyle{apsrev4-1}
\subsubsection{\@startsection{subsubsection}{3}{\z@}% {-0.5ex\@plus -1ex \@minus -.2ex}% {-1.5ex \@plus -.2ex {\normalfont\normalsize\bfseries}} \makeatother \newcommand{\secref}[1]{Section~\ref{sec:#1}} \newcommand{\figref}[1]{Fig.~\ref{fig:#1}} \newcommand{\tabref}[1]{Table~\ref{tab:#1}} \title{Residual2Vec: Debiasing graph embedding with random graphs} \author{% Sadamori Kojaku$ ^1$, Jisung Yoon$ ^2$, Isabel Constantino$ ^3$, Yong-Yeol Ahn$ ^{1,3,4}$ \And \\ \vspace{-1em} \begin{minipage}{17em} \centering $ ^1$Center for Complex Networks and Systems Research, Luddy School of Informatics, Computing and Engineering, Indiana University, USA \end{minipage} \And \\\vspace{-1em} \begin{minipage}{15em} \centering $ ^2$Department of Industrial Management and Engineering Pohang University of Science and Technology, South Korea \end{minipage} \And \\ \vspace{-1em} \begin{minipage}{12em} \centering $ ^3$Indiana University Network Science Institute Indiana University, USA \end{minipage} \And \\ \vspace{-1em} \begin{minipage}{12em} \centering $ ^4$Connection Science Massachusetts Institute of Technology, USA \end{minipage} \And \\ \vspace{-1em} \begin{minipage}{\hsize} \centering \texttt{\{skojaku, imconsta, yyahn\}@iu.edu, <EMAIL>} \end{minipage} } \begin{document} \maketitle \begin{abstract} Graph embedding maps a graph into a convenient vector-space representation for graph analysis and machine learning applications. Many graph embedding methods hinge on a sampling of context nodes based on random walks. However, random walks can be a biased sampler due to the structural properties of graphs. Most notably, random walks are biased by the degree of each node, where a node is sampled proportionally to its degree. The implication of such biases has not been clear, particularly in the context of graph representation learning. Here, we investigate the impact of the random walks' bias on graph embedding and propose {\it residual2vec}, a general graph embedding method that can debias various structural biases in graphs by using random graphs. We demonstrate that this debiasing not only improves link prediction and clustering performance but also allows us to explicitly model salient structural properties in graph embedding. % \end{abstract} \section{Introduction} \label{sec:intro} On average, your friends tend to be more popular than you. This is a mathematical necessity known as the \textit{friendship paradox}, which arises due to a sampling bias, i.e.,~ popular people have many friends and thus are likely to be on your friend list~\cite{Feld1991}. Beyond being a fun trivia, the friendship paradox is a fundamental property of graphs: following an edge is a biased sampling that preferentially samples nodes based on nodes' degree (i.e.,~ the number of neighbors). The fact that random walk is used as the default sampling paradigm across many graph embedding methods raises important questions: what are the implications of this sampling bias in graph embedding? If it is undesirable, how can we debias it? Graph embedding maps a graph into a dense vector representation, enabling a direct application of many machine learning algorithms to graph analysis~\cite{Chai2018}. A widely used framework is to turn a graph into a ``sentence of nodes'' and then feed the sentence to \w2v~\cite{Perozzi2014, Grover2016,Dong2017, Mikolov2013}. A crucial difference from word embedding is that, rather than using given sentences, graph embedding methods generate synthetic ``sentences'' from a given graph. In other words, the generation of synthetic ``sentences'' in graph is an implicit modeling decision~\cite{Eriksson2021-kf}, which most graph embedding methods take for granted. A common approach for generating sentences from a graph is based on random walks, which randomly traverse nodes by following edges. The friendship paradox comes into play when a walker follows an edge (e.g., friendship tie): it is more likely to visit a node with many neighbors (e.g., popular individual). As an example, consider a graph with a core-periphery structure, where core nodes have more neighbors than periphery (Fig.~\ref{fig:bias-in-random-walk}A). Although core nodes are the minority, they become the majority in the sentences generated by random walks (Fig.~\ref{fig:bias-in-random-walk}B). This is because core nodes have more neighbors than periphery and thus are likely to be a neighbor of other nodes, which is a manifestation of the friendship paradox. Then, how does the sampling bias affect the embedding? Previous approaches to mitigate the degree bias in embedding are based on modifying random walks or the post-transformation of the embedding \cite{Andersen2006-ki,Wu2019-qq,Tang2020-ta,Ahmed2020-vl,Ha2020-fs,Fountoulakis2019-fv,Palowitch2020-tu,Faerman2018-pd,Rahman2019-uh}. Here we show that word2vec by itself has an implicit bias arising from the optimization algorithm---skip-gram negative sampling (SGNS)---which happens to negate the bias due to the friendship paradox. To leverage this debiasing feature further, we propose a more general framework, \r2v, that can also compensate for other systematic biases in random walks. We show that \r2v performs better than conventional embedding methods in link prediction and community detection tasks. Using a citation graph of 260k journals, we demonstrate that the biases from random walks overshadow the salient features of graphs. By removing the bias, \r2v better captures the characteristics of journals such as the impact factor and journal subject. The python code of residual2vec is available at GitHub~\cite{r2v}. \begin{figure} \centering \includegraphics[width=0.75\hsize]{bias-demo.pdf} \caption{ Random walks have a strong preference towards hubs. ({\bf A}) A toy graph generated by a stochastic block model with a core-periphery structure, where core nodes have more neighbors than peripheral nodes~\cite{Zhang2015}. ({\bf B}) Random walkers preferentially visit nodes with many neighbors, generating a trajectory that overrepresents the core nodes. } \label{fig:bias-in-random-walk} \end{figure} \section{Built-in debiasing feature of SGNS word2vec} \label{sec:related_work} \subsection{Background: SGNS word2vec} Consider a sentence of words $(x_{1}, x_{2}, x_{3},\ldots)$ composed of $N$ unique words. \w2v associates the $t$th word $x_{t}$ with words in its surrounding $x_{t-T}, \ldots, x_{t-1}, x_{t+1},\ldots, x_{t+T}$, which are referred to as context words, determined by a prescribed window size $T$. For a center-context word pair $(i,j)$, \w2v models conditional probability \begin{equation} P_{\text{w2v}}(j \vert i) = \frac{\exp(\vec{u}_i ^\top \vec{v}_{j})}{\sum_{j'=1}^N \exp(\vec{u}_{i}^\top \vec{v}_{j'})},\label{eq:cond_prob_w2v} \end{equation} where $\vec{u}_i, \vec{v}_i \in {\mathbb R}^{K\times 1}$ are \textit{embedding vectors} representing word $i$ as center and context words, respectively, and $K$ is the embedding dimension. An approach to fit $P_{\text{w2v}}$ is the maximum likelihood estimation, which is computationally expensive because $P_{\text{w2v}}$ involves the sum over all words. Alternatively, several heuristics have been proposed, among which \textit{negative sampling} is the most widely used~\cite{Mikolov2013,Perozzi2014,Grover2016} Negative sampling trains \w2v as follows. Given a sentence, a center-context word pair $(i,j)$ is sampled and labeled as $Y_j=1$. Additionally, one samples $k$ random word $\ell$ as candidate context words from a noise distribution $p_0(\ell)$, and then labels $(i,\ell)$ as $Y_{\ell} = 0$. In general, a popular choice of the noise distribution $p_0(\ell)$ is based on word frequency, i.e.,~ $p_0(\ell) \propto P_\text{d} (\ell) ^\gamma$, where $P_{\text{d}} (\ell)$ is the fraction of word $\ell$ in the given sentence, and $\gamma$ is a hyper-parameter. Negative sampling trains $\vec{u}_i$ and $\vec{v}_j$ such that its label $Y_j$ is well predicted by a logistic regression model \begin{align} \label{eq:logistic-regress} P_{\text{NS}}(Y_{j} = 1; \vec{u}_{i}, \vec{v}_j) = \frac{1}{1 + \exp(-\vec{u}_i ^\top \vec{v}_{j})}, \end{align} by maximizing its log-likelihood. \subsection{Implicit debiasing by negative sampling} Negative sampling efficiently produces a good representation~\cite{Mikolov2013}. An often overlooked fact is that negative sampling is a simplified version of Noise Contrastive Estimation (NCE)~\cite{Gutmann2010,Dyer2014}, and this simplification biases the model estimation. In the following, we show that this estimation bias gives rise to a built-in debiasing feature of SGNS word2vec. \subsubsection*{Noise contrastive estimation} NCE is a generic estimator for probability model $P_m$ of the form~\cite{Gutmann2010}: \begin{align} \label{eq:nce-model} P_m(x) = \frac{ f(x;\theta) }{\sum_{ x' \in {\cal X}} f(x';\theta) }, \end{align} where $f$ is a non-negative function of data $x$ in the set ${\cal X}$ of all possible values of $x$. \w2v (Eq.~\eqref{eq:cond_prob_w2v}) is a special case of $P_m$, where $f(x) = \exp(x)$ and $x = u_i ^\top v_{j}$. NCE estimates $P_m$ by solving the same task as negative sampling---classifying a positive example and $k$ randomly sampled negative examples using logistic regression---but based on a Bayesian framework~\cite{Gutmann2010,Dyer2014}. Specifically, as prior knowledge, we know that $1$ in $1+k$ pairs are taken from the given data, which can be expressed as prior probabilities~\cite{Gutmann2010,Dyer2014}: \begin{align} \label{eq:prior} P(Y_{j} = 1) = \frac{1}{k + 1},\quad P(Y_{j} = 0) = \frac{k}{k + 1}. \end{align} Assuming that the given data is generated from $P_m$, the positive example ($Y_j = 1$) and the negative examples ($Y_j = 0$) are sampled from $P_m$ and $p_0(j)$, respectively~\cite{Gutmann2010,Dyer2014}, i.e., \begin{align} \label{eq:class-cond} P(j \vert Y_{j} = 1) & = P_m(\vec{u}_i ^\top \vec{v}_{j}), \quad P(j \vert Y_{j} = 0) = p_0 (j). \end{align} Substituting Eqs.~\eqref{eq:prior} and \eqref{eq:class-cond} into the Bayes rule yields the posterior probability for $Y_j$ given an example $j$~\cite{Gutmann2010,Dyer2014}: \begin{align} \label{eq:posterior} P_{\text{NCE}}\left(Y_{j} =1 \vert j\right) = \frac{ P\left(j \vert Y_{j}=1\right)P(Y_{j}=1) }{ \sum_{y \in \{0,1\}} P\left(j \vert Y_{j} = y\right)P(Y_{j} = y) } = \frac{ P_m(\vec{u}_i ^\top \vec{v}_{j}) }{ P_m(\vec{u}_i ^\top \vec{v}_{j}) + kp_0(j) }, \end{align} which can be rewritten with a sigmoid function as \begin{align} \label{eq:nce} P_{\text{NCE}}\left(Y_{j}=1 \vert j\right) & = \frac{ 1 }{ 1 + kp_0(j) / P_m(\vec{u}_i ^\top \vec{v}_{j}) } = \frac{ 1 }{ 1 + \exp\left[ - \ln f(\vec{u}_i ^\top \vec{v}_{j}) + \ln p_0(j) + c \right] }, \end{align} where $c = \ln k + \ln\sum_{ x' \in {\cal X}} f(x')$ is a constant. NCE learns $P_m$ by the logistic regression based on Eq.~\eqref{eq:nce}. The key feature of NCE is that it is an asymptomatically unbiased estimator of $P_m$ whose bias goes to zero as the number of training examples goes to infinity~\cite{Gutmann2010}. \subsubsection*{Estimation bias of negative sampling} In the original paper of word2vec~\cite{Mikolov2013}, the authors simplified NCE into negative sampling by dropping $\ln p_0(j) + c$ in Eq.~\eqref{eq:nce} because it reduced the computation and yielded a good word embedding. In the following, we show the impact of this simplification on the final embedding. We rewrite $P_{\text{NS}}$ (i.e.,~ Eq.~\eqref{eq:cond_prob_w2v}) in the form of $P_{\text{NCE}}$ (i.e.,~ Eq.~\eqref{eq:nce}) as \begin{align} P_{\text{NS}}(Y_{j} = 1; \vec{u}_{i}, \vec{v}_j) & = \frac{1}{1 + \exp(-\vec{u}_i ^\top \vec{v}_{j})} = \frac{ 1 }{ 1 + \exp\left[ - \left( \vec{u}_i ^\top \vec{v}_{j} + \ln p_0(j) + c \right) + \ln p_0(j) + c \right] } \nonumber \\ & = \frac{ 1 }{ 1 + \exp\left[ - \ln f(\vec{u}_i ^\top \vec{v}_{j}) + \ln p_0(j) + c \right] }, \end{align} Equation (8) makes clear the relationship between negative sampling and NCE: negative sampling is the NCE with $f(\vec{u}_i ^\top \vec{v}_{j}) = \exp\left( \vec{u}_i ^\top \vec{v}_{j} + \ln p_0(j) + c\right)$ and noise distribution $p_0$~\cite{murray2020unsupervised}. Bearing in mind that NCE is the asymptomatically unbiased estimator of Eq.~\eqref{eq:nce-model} and substituting $f(\vec{u}_i ^\top \vec{v}_{j})$ into Eq.~\eqref{eq:nce-model}, we show that SGNS word2vec is an asymptomatically unbiased estimator for probability model: \begin{align} \label{eq:word2vecns} P_{\text{w2v}}^{\text{SGNS}}(j\mid i) = \frac{ p_0(j)\exp( \vec{u}_i ^\top \vec{v}_{j} ) }{Z_i '},\quad \text{where}\; Z_i ' := \sum_{j'=1}^N p_0(j') \exp(\vec{u}_{i} ^\top \vec{v}_{j'}). \end{align} Equation~\eqref{eq:word2vecns} clarifies the role of noise distribution $p_0$. Noise probability $p_0$ serves as a baseline for $P_{\text{w2v}}^{\text{SGNS}}$, and word similarity $\vec{u}_i ^\top \vec{v}_{j}$ represents the \textit{deviation} from $p_0(j)$, or equivalently the characteristics of words \textit{not} captured in $p_0(j)$. Notably, baseline $p_0(j) \propto P_\text{d}(j) ^\gamma$ is determined by word frequency $X_\text{d}(j)$ and thus negates the word frequency bias. This realization---that we can explicitly use a noise distribution to obtain ``residual'' information---is the motivation for our method, \textit{residual2vec}. \section{Residual2vec graph embedding} We assume that the given graph is undirected and weighted, although our results can be generalized to directed graphs (see Supplementary Information). We allow multi-edges (i.e., multiple edges between the same node pair) and self-loops, and consider unweighted graphs as weighted graphs with all edge weight set to one~\cite{Fortunato2010,Newman2014}. \subsection{Model} The presence of $p_0(j)$ effectively negates the bias in random walks due to degree. This bias dictates that, for a sufficiently long trajectory of random walks in undirected graphs, the frequency $P_\text{d}(j)$ of node $j$ is proportional to degree $d_j$ (i.e.,~ the number of neighbors) irrespective of the graph structure~\cite{MASUDA2017b}. Now, if we set $\gamma=1$, baseline $p_0(j)=P_\text{d}(j)$ matches exactly with the node frequency in the trajectory, negating the bias due to degree. But, we are free to choose any $p_0$. This consideration leads us to \textit{residual2vec} model: \begin{align} \label{eq:model_residual2vec} P_{\text{r2v}}(j\mid i) = \frac{P_{0}(j \mid i)\exp( \vec{u}_i ^\top \vec{v}_{j} )}{Z_i'}, \end{align} where we explicitly model baseline transition probability denoted by $P_{0}(j \mid i)$. In doing so, we can obtain the \textit{residual} information that is not captured in $P_{0}$. Figure~\ref{fig:r2v-schematic} shows the framework of \r2v. To negate a bias, we consider ``null'' graphs, where edges are randomized while keeping the property inducing the bias intact~\cite{Fortunato2010,Newman2014}. Then, we compute $P_{0}$ either analytically or by running random walks in the null graphs. The $P_0$ is then used as the noise distribution to train SGNS \w2v. \begin{figure} \centering \includegraphics[width=\hsize]{schematic-r2v.pdf} \caption{ \r2v framework. We first choose an explicit ``null'' model (e.g.,~ dcSBM random graph). By running random walks in the input and random graphs, ``sentences of nodes'' are generated and then compared to extract the residual information not in the random graphs. The final embedding encodes the residual information. Probabilities $P_{\text{d}}(j\mid i)$ and $P_{0}(j\mid i)$ can be computed analytically in many cases. For instance, we use the analytical solution for dcSBM (i.e.,~ $P_{\text{d}}(j \mid i)$ and $P_0(j \mid i)$) instead of simulating actual random walks. } \label{fig:r2v-schematic} \end{figure} \subsubsection*{Random graph models} Among many models for random graph~\cite{erdHos1959random,Karrer2009,Garlaschelli2009,Karrer2011,Expert2011,Levy2014,fosdick2018}, here we focus on the degree-corrected stochastic block model (dcSBM), which can be reduced to many fundamental random graph models with certain parameter choices~\cite{Karrer2011}. With the dcSBM, one partitions nodes into $B$ groups and randomizes edges while preserving (i) the degree of each node, and (ii) the number of inter-/intra-group edges. Preserving such group connectivity is useful to negate biases arising from less relevant group structure such as bipartite and multilayer structures. The dcSBM can be mapped to many canonical ensembles that preserve the expectation of structural properties. In fact, when $B=1$, the dcSBM is reduced to the soft configuration model that preserves the degree of each node on average, with self-loops and multi-edges allowed~\cite{fosdick2018}. Furthermore, by setting $B = 1$ and $d_i=\text{constant}$, the dcSBM is reduced to the Erdős-Rényi model for multigraphs that preserves the number of edges on average, with self-loops and multi-edges allowed. In the dcSBM, the edge weights follow a Poisson distribution and thus take integer values. Suppose that the nodes in the given graph have $B$ discrete labels (e.g.,~ gender), and we want to remove the structural bias associated with the labels. If no such label is available, all nodes are considered to have the same label (i.e.,~ $B=1$). We fit the dcSBM with $B$ groups, where each group consists of the nodes with the same label. The dcSBM generates random graphs that preserve the number of edges within and between the groups (e.g.,~ assortativity by gender types). We can calculate $P_{0}(j\mid i)$ without explicitly generating random graphs (Supplementary Information) \begin{align} \label{eq:pnull} P_{0}(j \mid i) =\frac{d_j}{D_{g_j}} \left( \frac{1}{T}\sum_{t=1}^T \mat{P}_{\text{SBM}} ^t \right)_{g_i, g_j}, \end{align} where node $j$ has degree $d_j$ and belongs to group $g_j$, $D_{g}=\sum_{\ell=1}^N d_{\ell} \delta(g_\ell, g)$, and $\delta$ is Kronecker delta. The entry $P^{\text{SBM}} _{g,g'}$ of matrix $\mat{P}_{\text{SBM}} = (P^{\text{SBM}} _{g,g'}) \in \mathbb{R}^{B\times B}$ is the fraction of edges to group $g'$ in $D_g$. Table~\ref{ta:null_models} lists $P_{0}(j\mid i)$ for the special classes of the dcSBM. See Supplementary Information for the step-by-step derivation. \begin{table} \centering \caption{ Baseline probability $P_{0}(j \mid i)$ for the dcSBM along with its special cases. } \label{ta:null_models} \scalebox{0.9}{ \begin{tabular}{lp{10em}p{12em}p{12em}} \toprule & \multicolumn{3}{c}{Canonical random graph models} \\\cmidrule{2-4} & {Erd\H{o}s-R\'{e}nyi}\xspace model for multigraphs~\cite{erdHos1959random} & \multirow{1}{10em}{The soft configuration model~\cite{fosdick2018}} & \multirow{2}{10em}{dcSBM~\cite{Karrer2011}} \\ \midrule $P_0(j \mid i)$ & \(\displaystyle 1/N \) & $d_j / \sum_{\ell=1}^N d_{\ell}$ & \(\displaystyle d_j D_{g_j} ^{-1}\left( T^{-1}\sum_{t=1}^T \mat{P}_{\text{SBM}} ^t \right)_{g_i, g_j} \) \\ \multirow{2}{5em}{Algorithm} & \multirow{2}{5em}{\DeepWalk~\cite{Perozzi2014}} & \n2v ($\gamma=0.75$)~\cite{Grover2016} & \\ \ & & \method{NetMF} ($\gamma=1$)~\cite{Qiu2018} & \\ \bottomrule \end{tabular} } \end{table} \subsubsection*{Other graph embedding as special cases of residual2vec}% \r2v can be considered as a general framework to understand structural graph embedding methods because many existing graph embedding methods are special cases of \r2v. \n2v and \method{NetMF} use SGNS \w2v with $p_0(j) \propto P_\text{d}(j) ^\gamma$. This $p_0(j)$ is equivalent to the baseline for the soft configuration model~\cite{fosdick2018}, where each node $i$ has degree $d_i^\gamma$. \DeepWalk is also based on \w2v but trained with an unbiased estimator (i.e.,~ the hierarchical softmax). Because negative sampling with $p_0(j) = 1/N$ is unbiased~\cite{Gutmann2010,Dyer2014}, \DeepWalk is equivalent to \r2v with the {Erd\H{o}s-R\'{e}nyi}\xspace random graphs for multigraphs. \subsection{Residual2vec as matrix factorization} % Many structural graph embedding methods implicitly factorize a matrix to find embeddings~\cite{Qiu2018}. \r2v can also be described as factorizing a matrix $\mat{R}$ which captures residual pointwise mutual information. Just like a $K$th order polynomial function can be fit to $K$ points without errors, we can fit \w2v to the given data without errors when the embedding dimension $K$ is equal to the number of unique words $N$~\cite{Levy2014}. In other words, $P_{\text{d}}(j \mid i)=P_{\text{r2v}}(j \mid i),\; \forall i,j$ if $K=N$. By substituting $P_{\text{r2v}}(j \mid i) = P_0(j \mid i)\exp(\vec{u}^\top _i \vec{v}_j)/Z' _i$, we obtain \begin{align} P_{\text{d}}(j \mid i) & = \frac{P_{\text{d}}(j \mid i)\exp\left( \vec{u}_i ^\top \vec{v}_{j} + \ln P_{0}(j \mid i)-\ln P_{\text{d}}(j \mid i)\right) }{\sum_{j'=1}^N P_{\text{d}}(j' \mid i)\exp\left( \vec{u}_i ^\top \vec{v}_{j'} + \ln P_{0}(j' \mid i) - \ln P_{\text{d}}(j' \mid i)\right)}. \end{align} The equality holds if $\exp( \vec{u}_i ^\top \vec{v}_{j} + \ln P_{0}(j \mid i )-\ln P_{\text{d}}(j \mid i)) = c_i$ for all $i$ and $j$, where $c_i$ is a constant. The solution is not unique because $c_i$ can be any real value. We choose $c_i=1$ to obtain a solution in the simplest form, yielding matrix $\mat{R}$ that \r2v factorizes: \begin{align} \label{eq:root_finding} R_{ij}:= \vec{u}_i ^\top \vec{v}_j = \ln P_{\text{d}}(j \mid i) - \ln P_{0}(j\mid i). \end{align} Matrix $\mat{R}$ has an information-theoretic interpretation. We rewrite \begin{align} \label{eq:root_finding2} R_{ij} & = \ln \frac{P_{\text{d}}(i,j)}{P_\text{d}(i)}-\ln \frac{P_{\text{0}}(i,j)}{P_\text{0}(i)} = \ln \frac{P_{\text{d}}(i,j)}{P_\text{d}(i)P_\text{d}(j)}-\ln \frac{P_{\text{0}}(i,j)}{P_\text{0}(i)P_\text{0}(j)} + \ln P_\text{d}(j) - \ln P_\text{0}(j). \end{align} The dcSBM preserves the degree of each node and thus has the same the degree bias with the given graph, i.e.,~ $P_\text{d}(i) = P_\text{0}(i)$ (Supplementary Information), which leads \begin{align} \label{eq:root_finding3} R_{ij} & = \text{PMI}_{\sim P_\text{d}}(i,j) - \text{PMI}_{\sim P_\text{0}}(i,j),\;\text{where}\; \text{PMI}_{\sim P}(i,j) = \ln \frac{P(i,j)}{P(i)P(j)}. \end{align} $\text{PMI}_{\sim P}(i,j)$ is the pointwise mutual information that measures the correlation between center $i$ and context $j$ under joint distribution $P(i,j)$, i.e.,~ $\text{PMI}_{\sim P}(i,j) = 0$ if $i$ and $j$ appear independently, and $\text{PMI}_{\sim P}(i,j) > 0$ otherwise. In sum, $R_{ij}$ reflects residual pointwise mutual information of $i$ and $j$ from the null model. \subsection{Efficient matrix factorization} Although we assume that $N=K$ above, in practice, we want to find a compact vector representation (i.e.,~ $K\ll N$) that still yields a good approximation~\cite{Levy2014,Qiu2018}. There are several computational challenges in factorizing $\mat{R}$. First, $\mat{R}$ is ill-defined for any node pair $(i,j)$ that never appears because $R_{ij}=\ln 0 =-\infty$. Second, $\mat{R}$ is often a dense matrix with ${\cal O}(N^2)$ space complexity. For these issues, a common remedy is a truncation~\cite{Levy2014,Qiu2018}: \begin{align} \tilde R_{ij}:= \max(R_{ij}, 0). \end{align} This truncation discards negative node associations ($R_{ij}<0$) while keeping the positive associations ($R_{ij}>0$) based on the idea that negative associations are common, and thus are less informative~\cite{Qiu2018}. In both word and graph embeddings, the truncation substantially reduces the computation cost of the matrix factorization~\cite{Levy2014,Qiu2018}. We factorize $\mat{\tilde R}=(\tilde R_{ij})$ into embedding vectors $\vec{u}_i$ and $\vec{v}_j$ such that $\vec{u}_i ^\top \vec{v}_j \simeq \tilde R_{ij}$ by using the truncated singular value decomposition (SVD). Specifically, we factorize $\mat{\tilde R}$ by $\mat{\tilde R} = \mat{\Phi}_{\text{left}} \cdot \text{diag}(\sigma_1, \sigma_2, \ldots, \sigma_K)\cdot \mat{\Phi}_{\text{right}} ^\top$, where $\mat{\Phi}_{\text{left}}=(\phi_{ik} ^{\text{left}})_{ik} \in {\mathbb R}^{N\times K}$ and $\mat{\Phi}_{\text{right}}=(\phi^{\text{right}}_{ik})_{ik} \in {\mathbb R}^{N\times K}$ are the left and right singular vectors of $\mat{\tilde R}$ associated with the $K$ largest singular values ($\sigma_1,\ldots \sigma_K$) in magnitude, respectively. Then, we compute $\vec{u}_i$ and $\vec{v}_j$ by $u_{ik} = \sigma_k^{\alpha}\phi_{ik}^{\text{left}}, \; v_{ik} = \sigma_k^{1-\alpha}\phi_{ik}^{\text{right}}$ with $\alpha = 0.5$ following the previous studies~\cite{Levy2014,Qiu2018}. The analytical computation of $P_{\text{d}}(j \mid i)$ is expensive because it scales as ${\cal O}(TN^3)$, where $T$ is the window size~\cite{Qiu2018}. Alternatively, one can simulate random walks to estimate $P_{\text{d}}(j \mid i)$. Yet, both approaches require ${\cal O}(N^2)$ space complexity. Here, we reduce the time and space complexity by \textit{the block approximation} that approximates the given graph by the dcSBM with $\hat B$ groups (we set $\hat B=1,000$) and then computes an approximated $P_{\text{d}}(j \mid i)$. The block approximation reduces the time and space complexity to ${\cal O}((N + M)\hat B + T\hat B^3)$ and ${\cal O}(NB\hat B)$ for a graph with $N$ nodes and $M$ edges, respectively, with a high accuracy (the average Pearson correlation of 0.85 for the graphs in Table~\ref{ta:network_list}). See Supplementary Information for the block approximation. \begin{table} \centering \caption{ List of empirical graphs and structural properties. Variables $N$ and $M$ indicate the number of nodes and edges, respectively. } \scalebox{0.75}{ \begin{tabular}{lllllll} \toprule Network & $N$ & $M$ & Assortativity & Max. degree & Clustering coef. & Ref. \\ \midrule Airport & 3,188 & 18,834 & -0.02 & 911 & 0.493 & \cite{ToreOpsahl} \\ Protein-Protein & 3,852 & 37,840 & -0.10 & 593 & 0.148 & \cite{Stark2006} \\ Wikipedia vote & 7,066 & 100,736 & -0.08 & 1065 & 0.142 & \cite{Leskovec2010} \\ Coauthorship (HepTh) & 8,638 & 24,827 & 0.24 & 65 & 0.482 & \cite{Leskovec2007} \\ Citation (DBLP) & 12,494 & 49,594 & -0.05 & 713 & 0.118 & \cite{Ley2002} \\ Coauthorship (AstroPh) & 17,903 & 197,031 & 0.20 & 504 & 0.633 & \cite{Leskovec2007} \\ \bottomrule \end{tabular} } \label{ta:network_list} \end{table} \section{Results} \label{sec:results} We test \r2v using link prediction and community detection benchmarks~\cite{Lancichinetti2009,Newman2006a,Fortunato2010,Grover2016,abu2017learning}. We use the soft configuration model~\cite{fosdick2018} as the null graph for \r2v, denoted by \method{r2v-config}, which yields a degree-debiased embedding. The soft configuration model allows self-loops and multi-edges---which are not present in the graphs used in the benchmarks---and thus is not perfectly compatible with the benchmark graphs. Nevertheless, because the multi-edges and self-loops are rare in the case of sparse graphs, the soft configuration model has been widely used for sparse graphs without multi-edges and self-loops~\cite{Newman2006a,Newman2014,fosdick2018}. As baselines, we use (i) three random-walk-based methods, \n2v~\cite{Grover2016}, \DeepWalk~\cite{Perozzi2014}, and \FairWalk~\cite{Rahman2019-uh}, (ii) two matrix-factorization-based methods, \Glove~\cite{Pennington2014} and Laplacian eigenmap (\LEM)~\cite{Belkin2003}, and (iii) the graph convolutional network (\GCN)~\cite{kipf2017semi}, the graph attention networks (\GAT)~\cite{Velickovic2018-tl}, and \GraphSAGE~\cite{Hamilton2017}. For all random-walk-based methods, we run 10 walkers per node for 80 steps and set $T=10$ and training iterations to 5. We set the parameters of \n2v by $p=1$ and $q \in \{0.5, 1, 2\}$. For \Glove, we input the sentences generated by random walks. We use two-layer \GCN, \GraphSAGE, and \GAT implemented in StellarGraph package~\cite{StellarGraph} with the parameter sets (e.g.,~ the number of layers and activation function) used in \cite{kipf2017semi,Hamilton2017,Velickovic2018-tl}. Because node features are not available in the benchmarks, we alternatively use degree and eigenvectors for the $\hat K$ smallest eigenvalues of the normalized Laplacian matrix because they are useful for link prediction and clustering~\cite{Luxburg2007,Kunegis2009}. We set $\hat K$ to dimension $K$ (i.e.,~ $\hat K = K$). Increasing $\hat K$ does not improve performance much (Supplementary Information). \begin{figure} \centering \includegraphics[width=\textwidth]{result-benchmark.pdf} \caption{ Performance for link prediction and community detection. We average AUC-ROC values over 30 runs with different random seeds and compute the 90\% confidence interval by a bootstrapping with $10^4$ resamples. For link prediction, some underperforming models are not shown. See Supplemantary Information for the full results. \method{r2v-config} consistently performs the best or nearly the best for all graphs in both benchmarks, as indicated by the higher AUC-ROC values. } \label{fig:benchmarks} \end{figure} \subsubsection*{Link prediction} Link prediction task is to find missing edges based on graph structure, a basic task for various applications such as recommending friends and products~\cite{Grover2016,abu2017learning,zhang2018arbitrary}. The link prediction task consists of the following three steps. First, given a graph, a fraction ($\rho=0.5$) of edges are randomly removed. Second, the edge-removed graph is embedded using a graph embedding method. Third, the removed edges are predicted based on a likelihood score calculated based on the generated embedding. In the edge removal process, we keep edges in a minimum spanning tree of the graph to ensure that the graph is a connected component~\cite{Grover2016,abu2017learning}. This is because predicting edges between disconnected graphs is an ill-defined task because each disconnected component has no relation to the other. We leverage both embedding $\vec{u}_i$ and baseline probability $P_0(j \vert i)$ to predict missing edges. Specifically, we calculate the prediction score by $\vec{u}_i ^\top \vec{u}_j + z_i + z_j$, where we set $z_j=\ln P_0(j \vert i)$ for residual2vec because $\ln P_0(j \vert i)$ has the same unit as $\vec{u}_i ^\top \vec{u}_j$ (Supplementary Information). Glove has a bias term that is equivalent to $z_i$. Therefore, we set $z_i$ to the bias term for Glove. Other methods do not have the parameter that corresponds to $z_i$ and thus we set $z_i = 0$. We measure the performance by the area under the curve of the receiver operating characteristics (AUC-ROC) for the prediction scores, with the removed edges and the same number of randomly sampled non-existent edges being the positive and negative classes, respectively. We perform the benchmark for the graphs in Table~\ref{ta:network_list}. \method{r2v-config} performs the best or nearly the best for all graphs (Figs.~\ref{fig:benchmarks}A--F). It consistently outperforms other random walk-based methods in all cases despite the fact that \n2v and \method{r2v-config} train the same model. The two methods have two key differences. First, \method{r2v-config} uses baseline $P_0(\ell \mid i) = P_{\text{d}}(\ell)$, whereas \n2v uses $P_0(\ell \mid i) \propto P_{\text{d}}(\ell)^{3/4}$ that does not exactly fit to the degree bias. Second, \method{r2v-config} optimizes the model based on a matrix factorization, which often yields a better embedding than the stochastic gradient descent algorithm used in \n2v~\cite{Levy2014,Qiu2018}. The performance of \r2v is substantially improved when incorporating offset $z_i$, which itself is a strong predictor as indicated by the high AUC-ROC. \subsubsection*{Community detection} We use the Lancichinetti–Fortunato–Radicchi (LFR) community detection benchmark~\cite{Lancichinetti2009}. The LFR benchmark generates graphs having groups of densely connected nodes (i.e.,~ communities) with a power-law degree distribution with a prescribed exponent $\tau$. We set $\tau = 3$ to generate the degree heterogeneous graphs. See Supplementary Information for the case of degree homogeneous graphs. In the LFR benchmark, each node has, on average, a specified fraction $\mu$ of neighbors in different communities. We generate graphs of $N=1,000$ nodes with the parameters used in Ref.~\cite{Lancichinetti2009} and embed the graphs to $K=64$ dimensional space. We evaluate the performance by randomly sampling $10,000$ node pairs and calculate the AUC-ROC for their cosine similarities, with nodes in the same and different communities being the positive and negative classes, respectively. A large AUC value indicates that nodes in the same community tend to have a higher similarity than those in different communities. As $\mu$ increases from zero, the AUC for all methods decreases because nodes have more neighbors in different communities. \DeepWalk and \LEM have a small AUC value even at $\mu=0.05$. \method{r2v-config} consistently achieves the highest or the second-highest AUC. \subsubsection*{Case study} \begin{figure} \centering \includegraphics[width=0.95\hsize]{wos-journal-embeddings.jpg} \caption{ Embedding of the WOS journal citation graph. ({\bf A}) Each node represents a pair $(j,t)$ of journal $j$ and year $t$, and each edge is weighted by citations. ({\bf B}, {\bf C}) A 2d projection of 128-dimensional embedding by the LDA. ({\bf D}) \method{r2v-dcSBM} produces the embedding that is less dependent on degree and time. ({\bf E}) By using the k-nearest neighbor algorithm, the embedding by \method{r2v-dcSBM} best predicts the impact factor and subject category. } \label{fig:wos-journal-embedding} \end{figure} Can debiasing reveal the salient structure of graphs more clearly? We construct a journal citation graph using citation data between 1900 and 2019 indexed in the Web of Science (WoS) (Fig.~\ref{fig:wos-journal-embedding}A). Each node represents a pair $(i, t)$ of journal $i$ and year $t$. Each undirected edge between $(i,t)$ and $(j,t')$ is weighted by the number of citations between journal $i$ in year $t$ and journal $j$ in year $t'$. The graph consists of $242,789$ nodes and $254,793,567$ undirected and weighted edges. Because the graph has a high average degree (i.e.,~ $1,049$), some algorithms are computationally demanding. For this reason, we omit \n2v with $q=0.5$ and $q=2$, \method{NetMF}, and \GAT due to memory shortage (1Tb of RAM). Furthermore, for \GCN, we set $\hat K=32$, which still took more than 18 hours. We also perform the whole analysis for the directed graph to respect the directionality of citations. Although all methods perform worse in predicting impact factor and subject category, we find qualitatively the same results. See Supplementary Information for the results for the directed graph. Here, in addition to the degree bias, there are also temporal biases, e.g.,~ there has been an exponential growth in publications, older papers had more time to accumulate citations, and papers tend to cite those published in prior few years~\cite{Wang2013}. To remove both biases, we use \r2v with the dcSBM (denoted by \method{r2v-dcSBM}), where we group journals by year to randomize edges while preserving the number of citations within and between years. We generate $K=128$ dimensional embeddings with $T=10$. Figures~\ref{fig:wos-journal-embedding}B and C show the 2d projection by the Linear Discriminant Analysis (LDA) with journals' subject categories as the class labels. \Glove and \n2v capture the temporal structure prominently, placing many old issues at the center of the embeddings. By contrast, \method{r2v-dcSBM} spreads out the old issues on the embedding. To quantify the effect of temporal bias, we randomly sample $50,000$ node pairs $(i,j)$ and then fitting a linear regression model $y_{ij} = w_{0} + w_1 (x_i + x_j) + w_2 |x_i - x_j| + w_3 x_i x_j$ that predicts cosine similarity $y_{ij}$ for node pair $(i,j)$ with attributes $x_i$ and $x_j$, where $x_i$ is either the degree or the year of node $i$. We perform 5-cross validations and compute $R^2$-score (Fig.~\ref{fig:wos-journal-embedding}D). A smaller $R^2$-score indicates that node similarity is less dependent on node attributes and thus less biased. \LEM has the smallest $R^2$-score for both degree and year. \method{r2v-dcSBM} has a smaller $R^2$-score than \method{r2v-config} for year, respectively, suggesting that \method{r2v-dcSBM} successfully negates the biases due to time. Is debiasing useful to capture the more relevant structure of graphs? We use embedding vectors to predict journal's impact factor (IF) and subject category. By employing the $k$-nearest neighbor algorithm, we carry out $5$-cross validations and measure the prediction performance by $R^2$-score and the micro-F1 score. To ensure that the train and test sets do not have the same journals in the cross-validation, we split the set of journals $i$ into the train and test sets instead of splitting the set of nodes ($i$,$t$). No single method best predicts both impact and subject categories. Yet, \method{r2v-config} and \method{r2v-dcSBM} consistently achieve the strongest or nearly the strongest prediction power for all $k$ we tested (Fig.~\ref{fig:wos-journal-embedding}E). This result demonstrates that debiasing embedding can reveal the salient structure of graphs that is overshadowed by other systematic biases. \section{Discussion} \label{sec:discussion} In this paper, starting from the insight that \w2v with SGNS has a built-in debiasing feature that cancels out the bias due to the degree of nodes, we generalize this debiasing feature further, proposing a method that can selectively remove any structural biases that are modeled by a null random graph. By exposing the bias and explicitly modeling it, we provide a new way to integrate prior knowledge about graphs into graph embedding, and a unifying framework to understand structural graph embedding methods. Under our residual2vec framework, other structural graph embedding methods that use random walks can be understood as special cases with different choices of null models. Through empirical evaluations, we demonstrate that debiasing improves link prediction and community detection performances, and better reveals the characteristics of nodes, as exemplified in the embedding of the WoS journal citation graph. Our method is highly flexible because any random graph model can be used. Although we focus on two biases arising from degree and group structure in a graph, one can remove other biases such as the degree-degree correlation, clustering, and bipartitivity by considering appropriate null graphs. Beyond these statistical biases, there have been growing concerns about social bias (e.g.,~ gender stereotype) as well as surveillance and privacy in AI applications, which prompted the study of gender and frequency biases in word embedding~\cite{Bolukbasi2016,ethayarajh-etal-2019-towards,ethayarajh-etal-2019-understanding,Zhou2021}. The flexibility and power of our selective and explicit debiasing approach may also be useful to address such biases that do not originate from common graph structures. There are several limitations in \r2v. We assume that random walks have a stationary distribution, which may not be the case for directed graphs. One can ensure the stationarity in random walks by randomly teleporting walkers~\cite{Lambiotte2012}. Second, it is not yet clear to what extent debiasing affects downstream tasks (e.g.,~ by losing information about the original graph). Nevertheless, we believe that the ability to understand and control systematic biases is critical to model graphs through the prism of embedding. \section*{Broader Impact} \label{sec:broad_impact} There has been an ever-increasing concern on inappropriate social stereotyping and the leak of sensitive information in word and graph embeddings~\cite{Bolukbasi2016,Edwards2016}. Although we have not studied social biases in this paper, given the wide usage of graph embedding methods to model social data, our approach may lead to methods and studies that expose and mitigate social biases that manifest as structural properties in graph datasets. Our general idea and approach may also be applied to modeling natural language and may contribute to the study of biases in language models. At the same time, by improving the accuracy of graph embedding, our method may also have negative impacts such as privacy attacks and exploitation of personal data (surveillance capitalism)~\cite{Bose2019,Edwards2016}. Nevertheless, we believe that our approach contributes to the effort to create transparent and accountable machine learning methods, especially because our method enables us to explicitly model what is structurally expected. \section*{Disclosure of Funding} The authors acknowledge support from the Air Force Office of Scientific Research under award number FA9550-19-1-0391. \small
\subsection{Modularizing Concern: Convolution-Based Backtrack (MC-CBB)} \begin{algorithm}[ht] \caption{MC-BI: Modularizing Concern: Backtrack to Input.} \footnotesize \begin{algorithmic}[1] \Procedure{Sliding\_Window\_Mapping($input$, $W$, $pad$, $stride$)}{} \State mapping =[], count=0\label{algo4:1}\Comment{Performs the forward pass and map input output nodes} \State $temp=zeros_like(input)$\label{algo4:2} \State $temp=temp.flatten()$\label{algo4:3} \For{$i=0$ to $i=|temp|$}\label{algo4:4} \State $temp[i]=i+1$\label{algo4:5} \EndFor \State $temp=temp.flatten()$\label{algo4:6} \State $sliding\_window=sw(temp, W, pad, stride)$\label{algo4:7} \For{$i=0$ to $i=|sliding\_window|$}\label{algo4:8} \For{$j=0$ to $j=W.length[3]$}\label{algo4:9} \State $mapping.add(temp[i][j], count)$\label{algo4:10} \EndFor \EndFor \EndProcedure \Procedure{CMBI($input$, $W$, $pad$, $stride$, $B$, $preceeding\_layer$, $deactive\_map$)}{}\label{algo4:11} \State $convDepth=depth$\label{algo4:12} \State $mapping\_window=Sliding\_Window\_Mapping$($input$, $W$, $pad$, $stride$, $B$) \State $source\_mapping=mapping\_window[:0]$\label{algo4:13}\Comment{Input nodes} \State $sink\_mapping=mapping\_window[:1]$\label{algo4:14}\Comment{Output nodes} \For{each $deactived\_node$ $\in deactive\_map$}\label{algo4:15} \State $source$=$source\_mapping$[$sink\_mapping$==$deactived\_node]$\label{algo4:16} \State $flag= True$\label{algo4:17}\Comment{Identify the source, where sink is deactive} \State $source\_mapping=source\_mapping[source\_mapping]>0]$\label{algo4:18} \For {$source\_node$ $\in source\_mapping$}\label{algo4:19} \If{$flag==true$}:\label{algo4:20} \State $sink\_node$=$sink\_mapping$[$source\_mapping$==$source\_node]$\label{algo4:21} \If{$|sink\_node-deactive\_map|>0$}\label{algo4:22} \State $flag=false$\label{algo4:23}\Comment{All sinks formed by source are not deactive} \EndIf \EndIf \If{$flag==true$}\label{algo4:24} \For{each $source$ $\in source\_mapping$}\label{algo4:25} \If{$source$ not $\in deactive\_map$}\label{algo4:26} \State $deactive\_map[-1].add(source+1)$\label{algo4:27}\Comment{Update Map} \EndIf \If{$preceeding\_layer$=="Add"}\label{algo4:28} \State $deactive\_map[-2].add(source+1)$\label{algo4:29}\Comment{Update Map} \EndIf \EndFor \EndIf \EndFor \EndFor \EndProcedure \end{algorithmic} \label{algo:cmfb} \end{algorithm} \section{Concern Identification} \begin{algorithm}[ht] \caption{Concern Identification (CI).} \footnotesize \label{algo:concern} \begin{algorithmic}[1] \Procedure{Initialization($model$)}{}\label{algo1:1} \State $convW$, $convB$ =[]\label{algo1:2} \For{each layer $\in model$}\label{algo1:3}\Comment{Retrieve the weight and bias} \If{$layer_{type}$=="Convolution"}\label{algo1:4} \State $convW.add(layer.Weight); convB.add(layer.Bias);$ \Else \If{$layer_{type}$=="Dense"}\label{algo1:5} \State $denseW.add(layer.Weight); denseB.add(layer.Bias);$\label{algo1:6} \EndIf \EndIf \EndFor \State \Return $convW, convB, denseB, denseW$\label{algo1:7} \EndProcedure \Procedure{CILayer ($model$, $input$, $convW_{Layer}$,\label{algo1:8} $convB_{Layer}$, $convMap_{Layer}$, $pad$=$with$, $Stride$=$1$, $first$=$False$)}{} \State $I$=$input$\label{algo1:9} \State $sliding_{w}$=$procSliding(I$, $pad$, $(Stride$, $Stride))$\label{algo1:10} \Comment{Sliding window} \State $Output$=$sliding_{w}*convW_{Layer}$ + $convB_{Layer}$\label{algo1:11} \State $flatOutput$=$flatten(Output)$\label{algo1:12} \Comment{Convert into an 1-D array} \For{$j=0$ to $j=|flatOutput|$}\label{algo1:13} \If{$first$}\label{algo1:14} \If{$flatOutput[j]$<=0}\label{algo1:15}\Comment{Identify the inactive nodes} \State $convMap_{Layer}.add(j)$\label{algo1:16} \EndIf \Else \Comment{Remove the inactive node if it is active for other inputs} \If{$j\in convMap_{Layer}$ }\label{algo1:17} \If{$flatOutput[j]$>0}\label{algo1:18} \State $index$=$findIndex(flatOutput, j)$\label{algo1:19} \State temp=[]\label{algo1:20} \For{$k=0$ to $k=convMap_{Layer}$}\label{algo1:21} \If{$k!=index$}\label{algo1:22} \State $temp.add(convMap_{Layer}[k])$\label{algo1:23} \EndIf \EndFor \State $convMap_{Layer}$=$temp$\label{algo1:24} \EndIf \EndIf \EndIf \EndFor \State \Return $convMap_{Layer}$, $Output$\label{algo1:25} \EndProcedure \Procedure{CI ($model$, $input, convMap$)}{} \State $convW, convB, denseB, denseW$=$initialization(model)$\label{algo1:26} \For{each $layer \in model$}\label{algo1:27}\Comment{Perform CI for all the layers} \State count=0\label{algo1:28} \If{$layer_{type}$==$``Convolution"$}\label{algo1:29} \State convMap[count], output = CILayer(($model$, $input$, $convW[count]$, $convB[count]$, $convMap[count]$, $pad$=$layer_{pad}$, $Stride$=$layer_{stride}$))\label{algo1:30} \EndIf \If{$layer_{type}$=$``BatchNormalization"$}\label{algo1:31} \State output = BatchNorm(($model$, $Gamma$))\label{algo1:32} \EndIf \If{$layer_{type}$==$``AveragePooling"$}\label{algo1:33} \State output = AvgPool(($model$, $Pool_{Size}$))\label{algo1:34} \EndIf \If{$layer_{type}$=$``MaxPooling"$}\label{algo1:35} \State output = MaxPool(($model$, $Pool_{Size}$))\label{algo1:36} \EndIf \If{$layer_{type}$=$``Add"$}\label{algo1:37} \State output = input+$Previous_{input}$\label{algo1:38} \Comment{Add both the layers that are merged} \EndIf \If{$layer_{type}$=$``Dense"$}\label{algo1:39} \State output = denseMod($model$, $input$, $indicator$=$False$, $denseW[count]$, $denseB[count]$)\label{algo1:40}\Comment{Apply dense-based CI} \EndIf \If{$layer_{type}$=$``Flatten"$}\label{algo1:41} \State output = flatten($input$)\label{algo1:42} \Comment{Apply flatten-based CI} \EndIf \State $input$=$output$ \EndFor \EndProcedure \end{algorithmic} \end{algorithm} \section{Motivation} \label{sec:motivation} \begin{figure*}[!ht] \includegraphics[, width=1\linewidth]{overview.pdf} \caption{How Decomposing a Convolution Neural Network can Help Solving a Real-life Problem.} \label{fig:overview} \end{figure*} Decomposing a convolutional neural network into modules can help to achieve various real-life scenarios. Because of the complex architecture and the massive size, retraining a model from scratch is not always feasible. Instead of building a new model, we propose utilizing parts from the already trained model and reusing or replacing them based on different scenarios. First, we describe one such requirement, where replacing a section of the model (module) with another (module) can be done with no or little retraining. Then, we describe how reusing these modules can be done. In Figure \ref{fig:overview}, we have shown a real-life example, where Google Photo App tagged a black woman as a gorilla. To resolve this issue, Google has decided to remove the output class ``Gorilla'' by suppressing the output label. In fact, they have suppressed labels for ``Chimpanzee'', ``Monkey'', ``Chimp'', etc~\cite{verge}., from the output of the convolutional neural network. Though the problem can be temporarily solved by suppressing the output label, to fix the model, one needs to retrain from scratch, which requires both high-computational and time-related resources. Instead of the prior approach, we propose three different solutions that reuse and replace modules from the trained model. We will discuss each of such approaches and their pros and cons and illustrate how retraining the model can be avoided. First, we decompose the faulty convolution neural network into modules for each output class. For instance, we have one module for each output class that classifies whether an input belongs to the output class, for which the module has been created, or not. In this example, our goal is to replace the faulty part or module responsible for classifying gorilla with a working module for the same. If we have another working model that is either trained with the same dataset or a subset of the dataset, we will decompose that working model into modules. The working model needs to have the gorilla and person output label, and that model should not exhibit the behavior present in the faulty model. Then, we can replace the faulty gorilla module with the working gorilla module, and a composed version of the decomposed modules can be sent to production. However, the drawback of this approach is the availability of such models. Training a model with a large dataset needs heavy computational resources and a non-trivial amount of time. Second, we decompose the faulty model into modules. Moreover, we train a new model with a person and gorilla and validate that the trained model does not demonstrate faulty behavior. We decompose the newly trained model into two modules and replace the faulty gorilla module with the new decomposed gorilla module. In this scenario, decomposition can not alone solve the problem. However, the decomposition bundled with the traditional training could help in this situation. Also, training the small model requires less resources. Third, we decompose the faulty model into modules and remove the gorilla module from the collection. In this scenario, there is no cost of retraining involved. However, using this approach, the actual problem of faulty classification has not been addressed. This solution is similar to what Google proposed, but instead of suppressing the label, we remove the module. The pros in this situation are that for other primates (``Chimpanzee'', ``Monkey'', ``Chimp'', etc.), we can remove the modules easily, whereas, for the other two techniques, we need to have models with those output classes or train a small network for them. We can also reuse the person and gorilla module from a working model without the faulty behavior and predict any input classified as a person or gorilla using the faulty model to verify it further. Here, instead of replacing the faulty parts, we reuse modules and add another verification with them. \section{Concern Identification} \begin{algorithm}[ht] \caption{Concern Identification (CI).} \footnotesize \label{algo:concern} \begin{algorithmic}[1] \Procedure{Initialization($model$)}{}\label{algo1:1} \State $convW$, $convB$ =[]\label{algo1:2} \For{each layer $\in model$}\label{algo1:3}\Comment{Retrieve the weight and bias} \If{$layer_{type}$=="Convolution"}\label{algo1:4} \State $convW.add(layer.Weight); convB.add(layer.Bias);$ \Else \If{$layer_{type}$=="Dense"}\label{algo1:5} \State $denseW.add(layer.Weight); denseB.add(layer.Bias);$\label{algo1:6} \EndIf \EndIf \EndFor \State \Return $convW, convB, denseB, denseW$\label{algo1:7} \EndProcedure \Procedure{CILayer ($model$, $input$, $convW_{Layer}$,\label{algo1:8} $convB_{Layer}$, $convMap_{Layer}$, $pad$=$with$, $Stride$=$1$, $first$=$False$)}{} \State $I$=$input$\label{algo1:9} \State $sliding_{w}$=$procSliding(I$, $pad$, $(Stride$, $Stride))$\label{algo1:10} \Comment{Sliding window} \State $Output$=$sliding_{w}*convW_{Layer}$ + $convB_{Layer}$\label{algo1:11} \State $flatOutput$=$flatten(Output)$\label{algo1:12} \Comment{Convert into an 1-D array} \For{$j=0$ to $j=|flatOutput|$}\label{algo1:13} \If{$first$}\label{algo1:14} \If{$flatOutput[j]$<=0}\label{algo1:15}\Comment{Identify the inactive nodes} \State $convMap_{Layer}.add(j)$\label{algo1:16} \EndIf \Else \Comment{Remove the inactive node if it is active for other inputs} \If{$j\in convMap_{Layer}$ }\label{algo1:17} \If{$flatOutput[j]$>0}\label{algo1:18} \State $index$=$findIndex(flatOutput, j)$\label{algo1:19} \State temp=[]\label{algo1:20} \For{$k=0$ to $k=convMap_{Layer}$}\label{algo1:21} \If{$k!=index$}\label{algo1:22} \State $temp.add(convMap_{Layer}[k])$\label{algo1:23} \EndIf \EndFor \State $convMap_{Layer}$=$temp$\label{algo1:24} \EndIf \EndIf \EndIf \EndFor \State \Return $convMap_{Layer}$, $Output$\label{algo1:25} \EndProcedure \Procedure{CI ($model$, $input, convMap$)}{} \State $convW, convB, denseB, denseW$=$initialization(model)$\label{algo1:26} \For{each $layer \in model$}\label{algo1:27}\Comment{Perform CI for all the layers} \State count=0\label{algo1:28} \If{$layer_{type}$==$``Convolution"$}\label{algo1:29} \State convMap[count], output = CILayer(($model$, $input$, $convW[count]$, $convB[count]$, $convMap[count]$, $pad$=$layer_{pad}$, $Stride$=$layer_{stride}$))\label{algo1:30} \EndIf \If{$layer_{type}$=$``BatchNormalization"$}\label{algo1:31} \State output = BatchNorm(($model$, $Gamma$))\label{algo1:32} \EndIf \If{$layer_{type}$==$``AveragePooling"$}\label{algo1:33} \State output = AvgPool(($model$, $Pool_{Size}$))\label{algo1:34} \EndIf \If{$layer_{type}$=$``MaxPooling"$}\label{algo1:35} \State output = MaxPool(($model$, $Pool_{Size}$))\label{algo1:36} \EndIf \If{$layer_{type}$=$``Add"$}\label{algo1:37} \State output = input+$Previous_{input}$\label{algo1:38} \Comment{Add both the layers that are merged} \EndIf \If{$layer_{type}$=$``Dense"$}\label{algo1:39} \State output = denseMod($model$, $input$, $indicator$=$False$, $denseW[count]$, $denseB[count]$)\label{algo1:40}\Comment{Apply dense-based CI} \EndIf \If{$layer_{type}$=$``Flatten"$}\label{algo1:41} \State output = flatten($input$)\label{algo1:42} \Comment{Apply flatten-based CI} \EndIf \State $input$=$output$ \EndFor \EndProcedure \end{algorithmic} \end{algorithm} \section{Conclusion and Future Work} \label{sec:conclusion} In this paper, we introduce decomposition in convolutional networks and transform a trained model into smaller components or modules. We used a data-driven approach to identify the section in the model responsible for a single output class and convert that into a binary classifier. Modules created from the same or different datasets can be reused or replaced in any scenario if the input size of the modules is the same. We found that decomposition involves a small cost of accuracy. However, both intra-dataset reuse and replaceability increase the accuracy compared to the trained model. Furthermore, enabling reusability and replaceability reduces $CO_2e$ emission significantly. For this work, we omit the heterogeneous inputs (the input size for modules are not the same) while reusing and replacing modules, and it will be a good research direction for the future to study how an interface could be built around the modules to take different types of inputs. \section{Dataset and Model Descriptions} \paragraph{Datasets} We evaluate our proposed approach based on three widely used and well-vetted datasets. \noindent\textbf{CIFAR-10~\cite{krizhevsky2009learning}:} This dataset comprises of 3-D images of different objects. It has 10 output classes, and the dataset is divided into training and testing datasets. The training dataset has 50,000 images and the testing dataset has 10,000 images. The number of examples for each class is equally distributed. The output classes are airplane, automobile, bird, cat, deer, dog, frog, horse, ship, and truck. Each of the images is of size (32, 32, 3), where the length, width, and color channels are 32, 32 pixels, and three dimensions, respectively. \noindent\textbf{CIFAR-100~\cite{krizhevsky2009learning}:} This dataset has 100 output classes. This is widely used to evaluate CNN-based studies due to the complexity of the dataset. Here, there are 50,000 training images and 10,000 testing images. There are 20 different types of images in this dataset, and for each type, there are 5 varieties of images are there. For instance, one of twenty superclasses is the aquatic animal, and within that class, we have beaver, dolphin, otter, seal, and whale. The image size is similar to the CIFAR-10. \noindent\textbf{ImageNet-200~\cite{deng2009imagenet}:} This dataset is very popular and widely use to measure the scalability of CNN-based applications. Unlike the previous two datasets, the total number of output classes is 200. ImageNet dataset has been designed to help the computer vision-related task in machine learning. This dataset has 80,000+ nouns (name of the class), and for each class, there are at least 500 images associated with it. This dataset has been used in training models in real-life scenarios. However, due to the complexity of the dataset, a smaller dataset specially intended for research purposes with similar complexity has been made public. This dataset (ImageNet-tiny) comprises 200 types of images. The training dataset has 100000 images, and the testing has 10000 images. There are 3 different variations of the dataset, where the length and width of the images are 224, 64, and 32. In our experiments, we used the 64 version of the dataset to reduce the time-complexity of training such networks and have an experimental dataset that is different from CIFAR-10 and CIFAR-100 in terms of the image size. \paragraph{Models} In this study, we used the ResNet models to evaluate our proposed approach. There are multiple blocks present in a ResNet model, and each block consists of convolution, add, and activation layers. There are two versions of ResNet, the original version, where there is a stack of convolution, add, and batch normalization layers are put together to form a residual block, and finally, those residual blocks build the network. In the second version, the residual block is modified to form a bottleneck layer with convolution, add, and batch normalization. We performed our evaluation against the first version of the network for simplicity and to reduce the training time and resources. Each such version can either have a batch normalization layer or not, as described in the original paper. Since batch normalization is only used to train and does not participate in the prediction, we chose the model without batch normalization to reduce the training time as some of our experiments include training models multiple times. We used ResNet-20, ResNet-32, and ResNet-56, where 3, 5, and 9 residual blocks are present with 21, 33, and 57 convolution layers, respectively. The accuracy reported in this study is different from the original paper because we re-trained the model from scratch with 200 epochs. The code can be accessed at. \section{Evaluation} \label{sec:results} \input{tbrq1.tex} In this section, we discuss the experimental settings. Furthermore, we discuss the performance of decomposing the convolutional neural network into modules by answering three research questions, 1) does decomposition involve cost?, 2) how module reuse and replacement can be done compared to retraining a model from scratch?, and 3) does reusing and replacing the decomposed modules emit less $CO_2$? \subsection{Experimental Settings} \subsubsection{Datasets} We evaluate our proposed approach based on three widely used and well-vetted datasets. \noindent\textbf{CIFAR-10 (C10)~\cite{krizhevsky2009learning}:} This dataset comprises of 3-D images of different objects. It has 10 output classes, and the dataset is divided into training and testing datasets. The training dataset has 50,000 images, and the testing dataset has 10,000 images. \noindent\textbf{CIFAR-100 (C100)~\cite{krizhevsky2009learning}:} This dataset has 100 output classes. This is widely used to evaluate CNN-based studies due to the complexity of the dataset. Here, there are 50,000 training images and 10,000 testing images. The image size is similar to the CIFAR-10. \noindent\textbf{ImageNet-200 (I200)~\cite{le2015tiny}:} This dataset is very popular and widely used to measure the scalability of CNN-based applications. Unlike the previous two datasets, the total number of output classes is 200. ImageNet dataset has been designed to help the computer-vision related task in machine learning. This dataset has 80,000+ nouns (name of the output class), and for each class, there are at least 500 images associated with it. This dataset has been used in training models in real-life scenarios. However, due to the complexity of the dataset, a smaller dataset with similar complexity has been made public for research purposes. This dataset (ImageNet-tiny) comprises 200 types of images. The training dataset has 100000 images, and the testing has 10000 images. \subsubsection{Models} We used the ResNet~\cite{he2016deep, he2016identity} models to evaluate our proposed approach. In a ResNet model, there are multiple blocks present and each block consists of \texttt{Convolution}, \texttt{Add}, and \texttt{Activation} layer. There are two versions of ResNet, the original version, where there is a stack of \texttt{Convolution}, \texttt{Add}, and \texttt{Batch Normalization} layers are put together to form a residual block, and those residual blocks build the network. In the second version, the residual block is modified to form a bottleneck layer with \texttt{Convolution}, \texttt{Add}, and \texttt{Batch Normalization}. We performed our evaluation against the first version of the network for simplicity and to reduce the training time and resources. Each such version can either have \texttt{Batch Normalization} layer or not as described in the original paper. Since \texttt{Batch Normalization} is only used to train and does not participate in the prediction, we chose the model without \texttt{Batch Normization} to reduce the training time as some of our experiments include training models multiple times. We used ResNet-20, ResNet-32, and ResNet-56, where 3, 5, and 9 residual blocks are present with 21, 33, and 57 convolution layers, respectively. The reported model accuracies are different from the original paper, as we trained the model from scratch with 200 epochs. \subsubsection{Metrics Used} \textbf{Accuracy.} We compute the composed accuracy of the decomposed modules as shown in the prior work~\cite{pan2020decomposing}. Pan~{\em et al.}\xspace computed the top-1 accuracy for all the experiments, whereas we compute both top-1 and top-5 accuracies. \textbf{Jaccard Index.} Similar to the prior work, we compute the variability between the model and the modules using Jaccard Index. \textbf{$\boldsymbol{CO_2e}$ Emission.} In this context, we refer to $CO_2e$ as carbon dioxide and equivalent gases. These gases are harmful to humankind and the earth due to various reasons. One of them is that they are heat-trapping gases, and the excess presence of such gases can increase the average temperature of the earth, which can lead to several devastating circumstances. To measure the total emission of such gases due to computation, we utilize the metrics used by Strubell~{\em et al.}\xspace~\cite{strubell2019energy}. The total power consumption during the training is measured as , \begin{equation} \label{eq:1} p_t=\frac{1.58t(p_c+p_r+gp_g)}{1000} \end{equation} In this equation, $p_c$, $p_r$, $p_g$, and $g$ denote the average power consumption of CPU, DRAM, GPU, and the total number of GPU cores, respectively. The $t$ denotes the time. Here, 1.58 denotes the PUE co-efficient, which is the same value used in the prior work. We performed our experiment on iMac with 4.2 GHz Quad-Core Intel Core i7 and 32 GB 2400 MHz DDR4 RAM. Since we do not have any GPU, both $g$ and $p_g$ are zero. The power consumption has been measured using Intel Power Gadget ~\cite{intel}. Finally, the $CO_2e$ emission has been computed as, \begin{align} CO_2e=0.954p_t \end{align} \section{Introduction} \label{sec:intro} Deep learning is increasingly being used for image segmentation, object detection, and similar computer vision tasks. With the need for bigger and complex datasets, the size and complexity of models also increase. Often, training a model from scratch needs several hours or even days. To ease the training process, layer architecture~\cite{sun2018resinnet, luo2017thinet}, transfer learning~\cite{torrey2010transfer, tan2018survey}, one-shot learning~\cite{vinyals2016matching, rezende2016one}, few-shot learning~\cite{sung2018learning, sun2019meta, lifchitz2019dense, wertheimer2019few}, etc., have been introduced. With these techniques, model structure, parameters can be reused for building a model for similar or different problems. However, in all cases, retraining is needed. Also, there may be scenarios, as shown in Figure \ref{fig:overview}, where a faulty section of the network needs to be amputated or replaced. Now, suppose we can decompose a Convolutional Neural Network (CNN) into smaller components (modules), where each component can recognize a single output class. In that case, we can reuse these components in various settings to build a new model, remove a specific output class, or even replace an output class from a model without retraining. In the past, modular networks~\cite{andreas2016neural, hu2017learning, ghazi2019recursive}, capsule networks~\cite{hinton2000learning, sabour2017dynamic}, etc., have been studied to train the network and incorporate memory into the learning process. But, these modules are not created for enabling reusability and replaceability. As others have noted~\cite{pan2020decomposing}, there are strong parallels between deep neural network development now and software development before the notion of decomposition was introduced~\cite{dijkstra1982role, parnas1972criteria, tarr1999n}, and developers wrote monolithic code that can be reused or replaced as easily. Recently, decomposition has been used to enable reuse and replacement in dense-based networks~\cite{pan2020decomposing}. This work shows that decomposed modules can be reused or replaced in various scenarios. However, this work focused on dense-based networks and did not explore a more complex set of deep learning techniques, e.g., convolutional neural networks. This work~\cite{pan2020decomposing} relies on the dense architecture of the models, where nodes and edges (weight and bias) have a one-to-one relationship. In contrast, edges in CNN are shared among all the input and the output nodes. \begin{figure*}% \centering \footnotesize \subfloat{\includegraphics[, width=1.0\linewidth]{overview.pdf}}% \qquad \subfloat{\input{tbMotiv.tex}} \caption{How Decomposing a Convolution Neural Network into Modules Can Help Solve a Real-life Problem.}% \label{fig:overview}% \end{figure*} In this paper, we propose an approach to decompose a CNN model used for image classification into modules, in which each module can classify a single output class. Furthermore, these modules can be reused or replaced in different scenarios. In Figure \ref{fig:overview}, we illustrate an issue faced by users while using the Google Photo app. We show how Google has resolved the problem and how replacing and reusing decomposed modules can be applied. In the past, Google Photo App tagged a black woman as a gorilla~\cite{verge}. To resolve this issue, Google decided to remove the output class ``Gorilla'' by suppressing the output label~\cite{verge}. Precisely, they have suppressed the output for ``Chimpanzee'', ``Monkey'', ``Chimp'', etc. Though the problem can be temporarily solved by suppressing the output label, to fix the model, one needs to retrain the model. We propose four different solutions based on reusing and replacing decomposed modules. We discuss each approach, its pros, cons, and illustrate how retraining the model can be avoided. The code and other artifacts are made available~\footnote{https://github.com/rangeetpan/Decomposition}. The key contributions of our work are the following: \begin{itemize} \item We introduce a technique to decompose a CNN model into modules, one module per output class. \item We describe an approach for reusing these decomposed modules in different scenarios to build models for new problems. \item We replace a part of the model with decomposed modules. \item We evaluate our approach against the $CO_2e$ consumption of models created from scratch and reusing or replacing decomposed modules. \end{itemize} \textbf{Results-at-a-glance. }Our evaluation suggests that decomposing a CNN model can be done with a little cost (-1.77\% (top-1) and -0.85\% (top-5)) compared to the trained model accuracy. Reusing and replacing modules can be done when the modules belong to the same datasets (reusability: +2.5\%, replaceability: +0.7\% (top-1) and +1.0\% (top-5)) and the different datasets (reusability: -7.63\%, replaceability: +2.5\% (top-1) and -7.0\% (top-5)). Furthermore, enabling reusability and replaceability reduce $CO_2e$ emission by 37 times compared to training from scratch. \textbf{Outline.} In \S\ref{sec:related} we describe the related work. Then in \S\ref{sec:methodology}, we discuss our approach to decompose a CNN model into modules. In \S\ref{sec:results}, we answer three research questions to evaluate the cost of decomposition, the benefit of reusing or replacing the modules, and the resource consumption. Lastly, in \S\ref{sec:conclusion}, we conclude. \begin{figure*}[htp] \centering \includegraphics[, width=1\linewidth]{approach.pdf} \caption{High-level Overview of Our Approach. Inactive nodes are denoted by black boxes.} \label{fig:approach} \end{figure*} \subsubsection{Does reusing and replacing the decomposed modules emit less $CO_2e$?} \label{subsec:rq3} \begin{figure}[!ht] \centering \includegraphics[, trim={2cm 7cm 0cm 7cm}, width=1.12\linewidth]{combined.pdf} \caption{Comparison of $CO_2e$ Emission.} \label{fig:c02} \end{figure} Strubell~{\em et al.}\xspace~\cite{strubell2019energy} have identified that training a model often emits six times more $CO_2e$ than a car emits over a year. To understand how decomposition can help to reduce the harmful effect, we measure the $CO_2e$ emission for both intra and inter-dataset reuse and replace scenarios. First, we start computing the power consumption before executing the program. Then, we measure the average power drawn by other tasks running in the background for 10 sec and compute the average power drawn by CPU and DRAM. We negate these two values to separate the resource consumption of the program and other background tasks. Then, we measure the power consumption for each 100 ms (default for Intel Power Gadget). Figure \ref{fig:c02} shows the $CO_2e$ emission for different scenarios. We do not show intra dataset replacement scenarios as that cannot be compared with training from scratch. For training scenarios, we build the model from scratch, and after training, we predict the same set of images. This experimental setting has been done to compare a similar situation, where developers need to build and predict inputs. The value reported in the figure is the average $CO_2e$ consumption for all the experimented scenarios described in \S\ref{subsec:rq2}. Also, since the epoch has been fixed for each retraining, the power consumption is somewhat fixed for each retraining scenario. However, the best model can be found earlier. For instance, a model is trained with 100 epochs, but the best model is found at the 20th epoch. To remove the effect of overfitting, we compute the power consumed until the return of the best model and report that in the figure. We found that for reuse scenarios, decomposition reduces the $CO_2e$ consumption by 23.7x and 18.3x for the fixed epoch and the best model scenarios, respectively. For replacement scenarios, it is 42x and 31.5x, respectively. If we apply the continuous learning-based approach, there is a slight increase in resource consumption, but still significantly less than training from scratch. Also, we computed the additional $CO_2e$ consumption for the one-time decomposition approach and found that on average 116, 371, and 3800 lbs of $CO_2e$ has been generated for decomposing CIFAR-10, CIFAR-100, and ImageNet-200 models, respectively. The overhead is significantly lower for CIFAR-10 and CIFAR-100 compared to training a new model for both reuse and replace scenarios. However, for ImageNet-200, the overhead is high, but it is a one-time operation that can enable both reuses and replacements at a very low cost. \subsubsection{How module reuse and replacement can be done compared to retraining a model from scratch?} Here, we evaluate how decomposed modules can be reused and replaced in various scenarios. \label{subsec:rq2} \input{tbintrareplace.tex} \input{tbinterreplace.tex} \textbf{Reusability:} Table \ref{tb:reuse}, and \ref{tb:interreuse} show two different reuse scenarios: 1) intra-dataset reuse, 2) inter-dataset reuse. In intra-dataset reuse, we build a model by taking two output classes from a dataset and building a new model. For instance, output classes 0 and 1 have been taken from CIFAR-10, and we evaluate the accuracy by combining the decomposed modules for output classes 0 and 1 (we represent the output class with their index in the dataset). We compare the performance with retraining a model with the same structure with the same output classes and measure the accuracy. We took the best model for each dataset (based on the trained model accuracy) and the modules created from that. For CIFAR-10, CIFAR-100, and ImageNet-200, the best model in terms of training accuracy are ResNet-56, ResNet-20, and ResNet-20, respectively. Since these models take a long time to train, we performed the experiments for 4 output classes randomly chosen from the dataset to evaluate the reusability scenarios. In Table \ref{tb:reuse}, the intra-dataset reuse scenarios are reported. C1, C2, C3, and C4 denote the four randomly chosen classes, and they are different for each dataset. Since we take 2 output classes in each experiment, the total number of choices for a dataset with $n$ output classes under experiment is $n \choose 2$. In our cases, we take 4 output classes from each dataset to evaluate, and the total choices would be $4 \choose 2$ or 6. For CIFAR-10, reusing the modules increase 6.6\% accuracy, on average. For CIFAR-100, there is an average 0.67\% loss, but 4/6 cases reusing the modules perform better than the trained model. For ImageNet, there is an average 1.5\% increase in accuracy. Overall, the gain in the accuracy in intra-dataset reuse is 2.5\%. In inter-dataset reuse, we take two output classes from different datasets and build a binary classification-based problem. For example, output classes 1 and 2 have been taken from the CIFAR-10 and CIFAR-100 datasets, respectively. We compute the accuracy the same way as we did for intra-dataset reuse scenario. Since the model structure of the decomposed modules for two datasets are different, e.g., the decomposed modules for CIFAR-10 follow the model structure of ResNet-56, whereas it is ResNet-20 for CIFAR-100. The best model in terms of accuracy has been taken for retraining. We did a pilot study and found that ResNet-20 does better in terms of accuracy for the inter-dataset reuse scenario for CIFAR-10 and CIFAR-100 datasets. To overcome overfitting, we store the checkpoints for all training-based evaluations and report the last checkpoint with the best validation accuracy. In Table \ref{tb:interreuse}, the inter-dataset reuse scenarios are reported. We found that inter-dataset reuse has a non-trivial cost. In this case, the loss of accuracy is 12.06\%. Our intuition is that since these modules originate from a different dataset, they still have some traits of the parent dataset. In fact, by applying the tangling identification approach, we deliberately add some non-concerned examples to distinguish between the concerned and the non-concerned examples. To alleviate the effect, we perform a continuous learning-based approach, where we re-apply the tangling identification with the unseen output class(es). We found that enabling continuous learning can reduce the cost of decomposition significantly. The overall loss while reusing modules is 7.63\%, which is a 4.4\% gain compared to the previous reusability approach. Since the input size of the CIFAR-10 and CIFAR-100 images are not the same as ImageNet-200, both training a single model and reusing modules cannot be done. \textbf{Replaceability:} Similar to the reusability scenario, we evaluated both inter and intra-dataset reuses. For intra dataset reuse, we replace a module decomposed from a model with less accuracy with a module for the same output class decomposed from a model with higher accuracy. In Table \ref{tb:intrareplace}, we report the evaluation for replacing the module. For each dataset, we evaluate for 10 output classes to match the total number of classes for all the datasets. For CIFAR-10, we replace a module decomposed from ResNet-32 with a module for the same output class decomposed from ResNet-20. We found that the intra-dataset reuse increases the accuracy by 0.7\% and 1.0\% for top-1 and top-5 accuracy, respectively in comparison to the prior composed accuracy of the decomposed modules. In fact, 80.0\% (24/30) and 83.3\% (25/30) times replacing a module does the better or the same compared to the composed accuracy of the decomposed modules for top-1 and top-5 accuracy, respectively. Also, for 33.3\% and 66.7\% cases, reusing modules does better than the model accuracy for top-1 and top-5 accuracies, respectively. Although we incorporated the continuous learning approach, there is no significant increase in accuracy (top-1: 0.02\% and top-5: 0.01\%). Inter-dataset replacement scenarios are reported in Table \ref{tb:interreuse}. To reduce the experiment time, we replace a module from CIFAR-10 with a module taken randomly from CIFAR-100 and report both composed accuracy and the accuracy of the trained model for four different output classes. We found that for top-1 accuracy, there is a 2.5\% accuracy increase, and for top-5, there is a loss of 7.1\%, on average. \input{motivationtb.tex} \noindent\textbf{Motivating Example.} Here, we recreate the example shown in Figure \ref{fig:overview}. Since human face and Gorilla images are not present in the ImageNet-200 dataset, we added two classes from the ImageNet large dataset. However, there is no class specifically categorized as ``human face'' in the dataset. So, we take the closest class that contains the images of different persons. First, we build a model with 202 (ImageNet-200 + Person + Gorilla) output classes. For the first option, we create a hypothetical model that does not exhibit faulty behavior. We do that by training a model with more epochs (+100 epochs) and achieve higher accuracy (+1.8\%). Then, we decompose the model into modules. Then, we replace the Gorilla module with the module created from the second model. In the second option, we train a model with Person and Gorilla examples and replace the faulty Gorilla module with the newly created one. In the third option, we remove the Gorilla module from the set of modules. Finally, in the fourth option, if the original model predicts Person or Gorilla, we re-verify with the modules created from the 2-class classification model in the second option. The evaluation has been shown in Table \ref{tb:motivating}, and we found that enabling the replacement and reuse of modules can solve the problem. Based on the need and available resources, users can pick any of the four options. \subsection{Results} In this section, we evaluate our approach to understand the cost involved in decomposition, whether the decomposed modules can be reused or replaced, and how decomposition can be beneficial compared to training from scratch. \subsubsection{Does Decomposing CNN Model into Module Involve Cost?} \label{subsec:rq1} \input{tbintrareuse1.tex} \input{tbinterreuse1.tex} To understand how decomposing CNN models into modules performs, we evaluate our approach on 9 datasets and model combinations. First, we decompose the CNN model into small modules, and then we compose them to evaluate how these composed modules perform compared to the trained CNN models. In Table \ref{tb:rq1}, the composed accuracy of the decomposed modules and the trained models' accuracy have been shown. We report the top-1 and top-5 accuracies of the models. Here, in the first and second columns, we show the top-1 and top-5 accuracy of the model. Whereas, in columns 3-11, the accuracy shown is from the composition of the decomposed modules. While composing the modules, we apply the voting-based approach that is similar to the prior work. Also, we compute the Jaccard index (JI) to identify the average variability between the modules and the model. Lesser value of the JI represents better decomposition as the modules are desired to be significantly different from the model. Suppose the value of the Jaccard index is very high. In that case, it denotes that the module has essentially become similar to the model. While the lower JI is a criterion for better decomposition, the cost is another criteria to be considered while decomposing a model into modules. In this study, our objective is to have the least cost of decomposition with the most dissimilarities between the modules and the model. We found that in all the cases, there is a cost involved while decomposing. For instance, our first approach identifies the concern, adds negative examples, and finally modularizes the concern involves 3.46\% and 2.54\% (top-1 and top-5) of loss of accuracy with an average Jaccard index 0.50. Whereas applying dense-based backtracking, the loss has reduced. The average loss with this approach is 1.77\% and 0.85\%, and the average Jaccard index is 0.63. For approach involving the backtrack through the convolution layer includes a loss of 1.86\% and 1.93\% accuracy with an average 0.64 Jaccard index. For the further experiments, we choose the second approach as the loss is the least of all. Based on these results, we can conclude that decomposition is possible in CNN models. However, it involves a small cost, and the modules produced are significantly different from the models. For further studies, we used the dense-based backtracking technique. \section{Related Works} \label{sec:related} There is a vast body of work~\cite{backus1957fortran, backus1960report, dijkstra2001go, dijkstra1970notes, dijkstra1982role, parnas1972criteria, liskov1974programming, parnas1976design, america1990designing, dhara1997forcing, cardelli1997program, flatt1998units, tarr1999n} on software decomposition that has greatly influenced us to decompose CNN model into reusable and replaceable modules. The closest work is by Pan and Rajan~\cite{pan2020decomposing}, where the dense-based model has been decomposed into modules to enable reuse and replacement in various contexts. Though this work has motivated to decompose a CNN model into modules, the dense-based approach cannot be applied due to: 1) the shared weight and bias architecture in convolution layers, and 2) support for layers other than dense. Also, this work did not evaluate the impact of decomposition on $CO_2e$ emission during training. Ghazi~{\em et al.}\xspace~\cite{ghazi2019recursive} have introduced modular neural networks to incorporate memory into the model. They have proposed a hierarchical modular architecture to learn an output class and classes within that output class. Though this work has been able to increase the interpretability of the network by understanding how inputs are classified, the modules are not built to enable reusability or replaceability. Other works on modular networks~\cite{andreas2016neural, hu2017learning} have learned how different modules communicate with others to achieve better training. Also, capsule networks~\cite{hinton2000learning, sabour2017dynamic} can be utilized to incorporate memory into deep neural networks. In capsule networks, each capsule contains a set of features, and they are dynamically called to form a hierarchical structure to learn and identify objects. However, modules decomposed by our approach can be reused or replaced in various scenarios without re-training. \citeauthor{sairam2018hsd}~\cite{sairam2018hsd} have proposed an approach to convert a CNN model into a hierarchical representation. At each level, nodes representing similar output classes are clustered together, and each cluster is decomposed further down the tree. Finally, with parameter transfer, the tree-based model is trained. While, in that work, a sub-section of the tree-based can be reused for a subset of the output classes, our approach decomposes a trained CNN model into reusable and replaceable modules to build a model for a new problem (intra and inter dataset) without retraining. Furthermore, we have shown that reusing and replacing modules decreases CO2e consumption significantly. \section{Approach} \label{sec:methodology} In this section, we provide an overview of our approach for CNN model decomposition. We discuss the challenges in general. We also discuss each step of decomposing a CNN model into modules. Figure \ref{fig:approach} shows the steps for decomposing a CNN model into modules. Our approach starts with the trained model and identifies the section in the CNN that is responsible for a single output class (Concern Identification). Since we remove nodes for all non-concerned output classes, the identified section acts as a single-class classifier. To add the notion of the negative output classes, we add a limited section of the inputs from unconcerned output classes (Tangling Identification). Finally, we channel the concerns to create a module(s) (Concern Modularization). In the example, we show the decomposition of the module for the output class A. Here, a model trained to predict four output classes has been decomposed into four modules. Each one is a binary classifier that recognizes if an input belongs to the output class. In this paper, we use \textit{concerned} and \textit{unconcerned} as terminologies that represent the input belonging to the output class for which module has been created and all the other output classes, respectively. For example, in Figure~\ref{fig:approach}, we show a module that is responsible for identifying output class $A$. For that module, output class $A$ is the concerned output class, and other output classes, e.g., $B$, $C$, and $D$, are the unconcerned classes. \subsection{Challenges} \label{subsec:challenges} In the prior work on decomposing dense-based models, modules were created by removing edges. There, the value of the node has been computed. If it is $\le$0, then all incoming and outgoing edges are removed. In a typical dense-based model, the first layer is a flatten layer that converts an input into a single-dimensional representation. From there, one or more dense layers are attached sequentially. In each such dense layer, nodes are connected with two different edges, 1) an edge that connects with other nodes from the previous layer (weight) and 2) a special incoming edge (bias). However, for a \textit{Convolution}\xspace layer, this is not the case. Figure \ref{fig:cnn} illustrates a traditional \textit{Convolution}\xspace layer. In that figure, on the left side, we have input nodes. Weight and bias are shown in the middle, and finally, on the right side, we have the output nodes. Each node in the input is not directly connected with the weight and bias, rather a set of nodes (sliding window) are chosen at a time as the input, and the output is computed based on that. The weight and bias are the same for all the input blocks. Due to these differences in the underlying architecture of a \textit{Convolution}\xspace layer, the dense-based decomposition approach could not be applied to a \textit{Convolution}\xspace layer directly. In the next paragraphs, we discuss each of such challenges. \begin{figure} \centering \includegraphics[, width=1\linewidth]{cnn.pdf} \caption{Architecture of a Convolutional Layer. } \label{fig:cnn} \end{figure} \textbf{Challenge 1: Shared Weight and Bias.} The removal of edges in dense-based layers has been done to forcing the value of the nodes that are not needed to be 0 and eventually remove them from the decision-making process in the module. This approach is possible in dense layers because there is a one-to-one relationship between two nodes that belong to subsequent layers. If we remove a part of the weight and bias for one node in the \textit{Convolution}\xspace layer, the weight and the bias will be turned off for all other nodes as well, and there will not be any output produced. \textbf{Challenge 2: Backtracking.} The prior work channels the concerns to convert the module into a binary classification problem. However, before channeling the output nodes, a backtracking approach has been applied that starts with removing nodes at the last hidden layer that are only connected to the unconcerned nodes at the output layers and backtrack to the first hidden layer. However, the same approach cannot be directly applied to the CNN models due to the differences in the architecture of the convolutional layers and other supporting layers, e.g., \textit{Pooling}, \textit{Merge}. \textbf{Challenge 3: Loss of Accuracy in Inter-Dataset Scenarios.} Prior work evaluated their approach by reusing and replacing modules that belong to different datasets. It has been found that such scenarios involve a non-trivial cost. Since these modules involved in the reuse and replace scenario do not belong to the same datasets, they are not programmed to distinguish between them. To remediate the cost, we propose a continuous learning-based approach that enables retraining of the decomposed modules. \subsection{Modularizing Concern: Convolution-Based Backtrack (MC-CBB)} \begin{algorithm}[ht] \caption{MC-BI: Modularizing Concern: Backtrack to Input.} \footnotesize \begin{algorithmic}[1] \Procedure{Sliding\_Window\_Mapping($input$, $W$, $pad$, $stride$)}{} \State mapping =[], count=0\label{algo4:1}\Comment{Performs the forward pass and map input output nodes} \State $temp=zeros_like(input)$\label{algo4:2} \State $temp=temp.flatten()$\label{algo4:3} \For{$i=0$ to $i=|temp|$}\label{algo4:4} \State $temp[i]=i+1$\label{algo4:5} \EndFor \State $temp=temp.flatten()$\label{algo4:6} \State $sliding\_window=sw(temp, W, pad, stride)$\label{algo4:7} \For{$i=0$ to $i=|sliding\_window|$}\label{algo4:8} \For{$j=0$ to $j=W.length[3]$}\label{algo4:9} \State $mapping.add(temp[i][j], count)$\label{algo4:10} \EndFor \EndFor \EndProcedure \Procedure{CMBI($input$, $W$, $pad$, $stride$, $B$, $preceeding\_layer$, $deactive\_map$)}{}\label{algo4:11} \State $convDepth=depth$\label{algo4:12} \State $mapping\_window=Sliding\_Window\_Mapping$($input$, $W$, $pad$, $stride$, $B$) \State $source\_mapping=mapping\_window[:0]$\label{algo4:13}\Comment{Input nodes} \State $sink\_mapping=mapping\_window[:1]$\label{algo4:14}\Comment{Output nodes} \For{each $deactived\_node$ $\in deactive\_map$}\label{algo4:15} \State $source$=$source\_mapping$[$sink\_mapping$==$deactived\_node]$\label{algo4:16} \State $flag= True$\label{algo4:17}\Comment{Identify the source, where sink is deactive} \State $source\_mapping=source\_mapping[source\_mapping]>0]$\label{algo4:18} \For {$source\_node$ $\in source\_mapping$}\label{algo4:19} \If{$flag==true$}:\label{algo4:20} \State $sink\_node$=$sink\_mapping$[$source\_mapping$==$source\_node]$\label{algo4:21} \If{$|sink\_node-deactive\_map|>0$}\label{algo4:22} \State $flag=false$\label{algo4:23}\Comment{All sinks formed by source are not deactive} \EndIf \EndIf \If{$flag==true$}\label{algo4:24} \For{each $source$ $\in source\_mapping$}\label{algo4:25} \If{$source$ not $\in deactive\_map$}\label{algo4:26} \State $deactive\_map[-1].add(source+1)$\label{algo4:27}\Comment{Update Map} \EndIf \If{$preceeding\_layer$=="Add"}\label{algo4:28} \State $deactive\_map[-2].add(source+1)$\label{algo4:29}\Comment{Update Map} \EndIf \EndFor \EndIf \EndFor \EndFor \EndProcedure \end{algorithmic} \label{algo:cmfb} \end{algorithm} \subsection{Concern Identification} Concern Identification (CI) involves identifying the section of the CNN model, responsible for the single output class. As a result of this process, we remove nodes and edges in the model. In traditional CNN models for image classification, both convolution, and dense layers have the notion of node and edges, and we discuss the concern identification approaches for both the layers. \noindent\textbf{Dense Layers:} Here, the concerned section can be identified by updating or removing the edges connected to the nodes. In a dense-based network, there is a one-to-one relationship between the edges connecting the nodes from different layers (including the bias nodes). For each edge, the originating and the incident nodes are unique except for bias, where the incident node is unique. The edges between nodes are removed or updated based on the value associated with the nodes. In this process, we identify nodes based on the assumption that ReLU has been used as the activation function. Since our work is focused on image-based classification models, ReLU is the most commonly used activation function for the hidden layers. Also, prior work on decomposition~\cite{pan2020decomposing} has been carried out with the same assumption. First, we compute the value associated with the nodes by applying training inputs from the concerned output class. For an input, if the computed value at a node is $\le$0, then we remove all the incident and originated edges. We do that for all the concerned inputs from the training dataset. If the value associated with a node is $>$0 for some input and $\le$0 for other inputs, we do not remove that node. For instance, for a layer $L_d$, there are $n_{L_d}$ number of nodes, and the preceding and the following layer has $n_{L_{d-1}}$ and $n_{L_{d+1}}$ nodes, respectively. For any node at the layer $L_d$, there will be $n_{L_{d-1}}$incident edges and $n_{L_{d+1}}$ outgoing edges. Based on our computation, if a node $n_i$ is inactive (value $\le$0), then all the incoming and outgoing weight edges ($n_{i(L_{d-1})}$ + $n_{i(L_{d+1})}$) and one bias edge incident to $n_i$ will be removed. We do the same for all the hidden dense layers. \input{algoci.tex} \noindent\textbf{Convolution Layers:} In a convolutional layer, we identify the inactive sections in the output nodes by using a mapping-based technique that stores the position of the nodes that are not part of a module. In Algo.\ref{algo:concern}, we describe the steps involved in building the map and storing the nodes' positions. First, we store the weight and bias for all the layers. Then, we identify the parts of the convolution layer that are not used for a single output class. We start by computing all possible combinations of sliding windows at line \ref{algo1:10}. To build the sliding windows, we use the $stride$, $padding$ as input. Below, we describe each such parameter. \textbf{Sliding Window.} In convolutional layers, instead of one input node at a time, a set of nodes are taken as an input for computation. For instance, in Figure \ref{fig:cnn}, the blue box is a sliding window. For each sliding window, one or more output nodes are created based on the size of the shared weight in the layer. \textbf{Padding.} Two variations of padding is possible in CNN, zero-padding and with-padding. In zero-padding, the input is not changed. For with-padding, the input is padded based on the size of the sliding window, and the size of the output will be the same as the input. For the example shown in Figure \ref{fig:cnn}, we used the with-padding, and that adds padding with value zero and transforms the input into (5, 5, 3) size (the white boxes are the added padding). \textbf{Stride.} This parameter controls the movement of the sliding window while computing the output. Stride along with the padding decides the output of the layer. Once we compute the sliding windows (line \ref{algo1:10}), we feed inputs from the training dataset to our approach and observe the output value of that particular convolution layer. At line \ref{algo1:11}, we compute the output of the convolution layer based on S*W + B, where S, W, and B denote the sliding window, shared weight, and bias, respectively. Then, we monitor the value at each node (line \ref{algo1:12}-\ref{algo1:25}). If a node has a value $\le0$, we store the position of the node in our map. We initialize the map with all the nodes (for the first input) that have value $\le0$ (line \ref{algo1:14}-\ref{algo1:16}). The \textit{first} flag is used to denote this first input to the module. Then, we remove the nodes that are previously in the mapping list, but the nodes have a positive value for the input under observation (line \ref{algo1:17}-\ref{algo1:24}). We perform such operations to identify the section of the layer that is inactive for a particular concern. For the batch normalization layer, there is no weight or bias involved, and the layer is utilized for normalizing the input based on the values learned during the training session. Max pooling and average pooling are utilized for reducing the size of the network using the pool size. For merge or add layer, we add the value computed from the two layers connected with this layer. \subsection{Tangling Identification} In concern identification, a module is created based on identifying the nodes and edges for a single output class. Since all the nodes and edges related to the other output classes in the dataset have been removed, the module essentially characterizes any input as the concerned output class or behaves as a single-class classifier. To add the notion of unconcerned output classes and able to distinguish between the concerned and unconcerned output classes, we bring back some of the nodes and edges to the module. In Tangling Identification (TI), a limited set of inputs belonging to the unconcerned output classes have been added. Based on the prior work, we add concerned and unconcerned inputs with a 1:1 ratio. For instance, if we have a problem with 200 output classes and build a module based on observing 1000 inputs from the concerned class, then we observe 5 inputs from each unconcerned class (5x199=995$\approx$1000). \subsection{Modularizing Concerns} \label{subsec:cm} So far, we identify the section of the network that is responsible for an output class and added examples from unconcerned output classes. However, the module is still an $n$-class classification problem. We channel the output layer for each module to convert that into a binary classification-based problem. However, before applying the channeling technique, we remove irrelevant nodes (do not participate in the classification task for a module) using a bottom-up backtracking approach. \noindent\textbf{Dense Layers:} We channel the out edges as described by the prior work~\cite{pan2020decomposing}. Instead of having $n$ nodes at the output layer ($L_{d}$, where $d$ is the total number of dense-based layers), two nodes (concerned and unconcerned output nodes) have been kept. For instance, the concerned output class for a module is the first output class in the dataset. We have $n$ output classes and $n$ nodes ($V_1, V_2, \dots, V_n$) at the output layer. Also, the layer preceding the output layer ($L_{d-1}$) has $n_{L_{d-1}}$ nodes. For each node at the output layer, there will be $n_{L_{d-1}}$ incident edges. For instance, the incoming edges for $V_1$ node will be $E_{11}, E_{21}, \dots, E_{n_{L_{d-1}}1}$, where $E_{n_{L_{d-1}}*1}$ (in this case, n=1) denotes that an edge is connected with $n_{L_{d-1}}^{th}$ node from $L_{d-1}$ layer and the first node at the output layer. For the module responsible for identifying the first output label, the edges incident to the first node (as the concerned node is $V_1$) at the output layer have been kept intact. However, all the other edges are modified. All the edges incident to any of the unconcerned nodes ($V_2$, $V_3$, $\dots$, $V_n$) at the $L_d$ layer will be updated by a single edge. The assigned weight for the updated edge is the mean of all the edges (same for bias). Then, that updated edge has been connected to a node at the output layer, which is the unconcerned node for the module. For a module, there will be two nodes at the output layer, $V_c$ and $V_{uc}$, where $V_c$ and $V_{uc}$ denote the concerned node and the unconcerned node. All the updated edges will be connected to the $V_{uc}$. \noindent\textbf{Modularizing Concern: Backtrack:} Once the nodes at the output layer are channeled, we backtrack the concerned and unconcerned nodes to the previous layers. In this process, we remove the nodes that only participate in identifying the unconcerned classes. First, we discuss the backtracking approach to handle the dense layers and other non-dense layers, and then we describe how we can backtrack till the input to reduce the size of the module. In all approaches, we support the other layers, e.g., pooling, merge, flatten. \begin{figure}[htp] \centering \includegraphics[, width=0.88\linewidth]{backtrack.pdf} \caption{Backtrack Through a Convolution Layer. } \label{fig:backtrack} \end{figure} \input{algodbp.tex} \textbf{Modularizing Concern: Backtrack To Last Convolutional Layer (MC-BLC).} Once we channel the output layer, we prune the network based on the inactive nodes at the dense layers. In a typical CNN model, either a \textit{Pooling} layer, \textit{Convolution} layer, or a \textit{Merge} layer will precede \textit{Dense} layers and the \textit{Flatten} layers In this approach, we leverage that information to backtrack through the \textit{Dense} layers (including \textit{Flatten} layer) to the last convolution layer(s) (based on the presence of \textit{Merge} layer or not) or the pooling layer. In this process, we identify the nodes that have edges $E=\left\{E_{ij}; i\in L_{d-1}, j\in L_{d}, j\in V_{l(uc)} \right\}$, where all the edges are only connected to the unconcerned nodes ($V_{uc}$) at the $d^{th}$ layer (line \ref{algo3:4}-\ref{algo3:10}). We start the backtracking process from the output layer and move through the dense layer. For each layer, we identify the nodes connected to the unconcerned nodes in the following layer and remove them from the model. Also, we tag the removed nodes as the unconcerned nodes for that layer. To identify the nodes that strongly contribute to the unconcerned node, we introduce a constant ($\delta$) to verify the value associated with the node. Based on the experimental evaluation, we used $\delta=0.5$. Then, we backtrack the nodes at the layer preceding the output layer is identified at line \ref{algo3:11}-\ref{algo3:17}. Finally, we backtrack to the flatten layer. In a traditional CNN model for image classification, the flatten layer is preceded by a pooling layer, or a merge layer, or a convolutional layer. If the preceding layer is a convolution layer, we update the mapping (as discussed in \S\ref{subsec:cl}) for that particular convolutional layer. Since the convolution layer's output is directly reshaped into the flatten layer, there is a one-to-one relationship between the two layers. If the preceding layer is a pooling layer, then there will be $X^2$ (X is the pool size) inactive nodes at the pooling layer for one inactive node at the flatten layer. If the preceding layer is a merge layer, then the convolution layers that are merged will be updated. \textbf{Modularizing Concern: Backtrack To Input (MC-BI).} In the previous approach, we can only backtrack from the output layer to the last convolution layer. However, we cannot backtrack through the convolution layer. In a convolution layer, the input nodes cannot be directly mapped with the output nodes. For instance, in Figure \ref{fig:backtrack}, the input image shown on the left side is turned into the image shown in the middle, which is after adding the paddings (for this example, we choose \textit{Valid} padding). In the output, the nodes on the top left corner for both arrays will be produced by the first sliding window (blue box) from each array shown in the middle. So, for mapping, a node in the output on the right side of the image, at least 4 (in this example, we chose the sliding window size to be 2x2) nodes can be mapped. Those four individual nodes are also mapped with other nodes in the output. The black-colored node in the middle is a part of two sliding windows (the blue box and the orange box). To remove irrelevant nodes from the convolution layer, we take a two-pass approach. First, we store the position of the nodes in each sliding window with the nodes in the output (forward pass). During the forward pass, we store the mapping $M=\left\{(V_i, V_j) ; V_j=f(V_i, W, B)\right\}$, where $f$ denotes the convolution operation. During the backward pass, we remove the nodes. \input{algobp.tex} In Algo. \ref{algo:cmfb}, we describe the step to do the mapping. From line \ref{algo4:1}-\ref{algo4:10}, the forward pass has been described. In the forward pass, we store the mapping between the sliding window and output nodes. In order to denote the position of the sliding window, we mark each node with a unique number (line \ref{algo4:4}-\ref{algo4:5}) before adding the padding. For padding, the nodes are marked as ``0'' as they are not present in the input of the \textit{Convolution}\xspace layer. Then for each output node, the input nodes are stored in a list. In this process, we define an operation named \texttt{sw} that computes the sliding windows from the weight $W$, padding $pad$, and stride. Now, we compute the mapping with the input and the output nodes at line \ref{algo4:12}. Then, we separate the input and the output nodes at line \ref{algo4:13} and \ref{algo4:14}. We scan through the inactivate nodes in the output and identify if they match the pattern as illustrated in Figure~\ref{fig:backtrack}. We identify all the input nodes that are mapped with an output node and vice versa. We focus on searching nodes that are not part of the padding operation and remove the nodes marked with 0 at line \ref{algo4:18}. For each such input node, we find all the output nodes generated from the particular input node. If these output nodes are already in the deactivation node list, we add the input node to the deactivation list for the preceding convolution (output of the preceding convolution layer is the input of the next convolution layer). If the previous layer is an add layer, then the two convolution layers that are merged at the merge layer are updated with the changes. If the preceding layer is a pooling layer, the update is carried based on the pool size. \subsection{Continuous Learning} \label{subsec:cl} In the prior study, reusing modules that originated from different datasets involves non-trivial cost. Our intuition is that since the modules are originated from a different dataset, they still have some traits of the parent dataset. In fact, by applying the tangling identification approach, we deliberately add some unconcerned examples to learn the modules on how to distinguish between the concerned and the unconcerned examples. However, in the inter dataset scenarios, the unconcerned output classes are not the same. To solve this problem, we propose a continuous learning-based approach. In deep learning, continuous learning~\citeauthor{collobert2008unified}~\cite{collobert2008unified} has been widely applied. In Figure \ref{fig:cl}, we illustrate a reuse scenario, where module F is originated from dataset 1 and module 2 is originated from dataset 2. Dataset 1 represents a set of English letters (A-G), and applying decomposition creates modules for each output class. Similarly, dataset 2 represents a set of English digits (1-7), and decomposition creates seven modules, each for one output class. When module F and module 2 are reused in a scenario, based on the prior work, each input belongs to 2, and F will be given as input to the composition of the decomposed modules. However, due to the parent dataset traits, module 2 can recognize itself but does not know how to distinguish from any input belonging to the output class F. To learn the concerned output classes in this scenario, we take the unconcerned section of the dataset. For instance, for module F, the unconcerned output class will be output class 2 from dataset 2. We take the examples from output class 2 from dataset 2 and update module F by removing the nodes responsible for detecting the output class 2. We do the same for module 2, where we remove the nodes responsible for recognizing output class F from dataset 1. Finally, the modified modules are ready to be reused. \begin{figure} \centering \includegraphics[, width=0.84\linewidth]{CL.pdf} \caption{Continuos Learning. } \label{fig:cl} \end{figure} \section{Conclusion and Future Work} \label{sec:conclusion} In this paper, we introduce decomposition in convolutional networks and transform a trained model into smaller components or modules. We used a data-driven approach to identify the section in the model responsible for a single output class and convert that into a binary classifier. Modules created from the same or different datasets can be reused or replaced in any scenario if the input size of the modules is the same. We found that decomposition involves a small cost of accuracy. However, both intra-dataset reuse and replaceability increase the accuracy compared to the trained model. Furthermore, enabling reusability and replaceability reduces $CO_2e$ emission significantly. For this work, we omit the heterogeneous inputs (the input size for modules are not the same) while reusing and replacing modules, and it will be a good research direction for the future to study how an interface could be built around the modules to take different types of inputs. \section{Dataset and Model Descriptions} \paragraph{Datasets} We evaluate our proposed approach based on three widely used and well-vetted datasets. \noindent\textbf{CIFAR-10~\cite{krizhevsky2009learning}:} This dataset comprises of 3-D images of different objects. It has 10 output classes, and the dataset is divided into training and testing datasets. The training dataset has 50,000 images and the testing dataset has 10,000 images. The number of examples for each class is equally distributed. The output classes are airplane, automobile, bird, cat, deer, dog, frog, horse, ship, and truck. Each of the images is of size (32, 32, 3), where the length, width, and color channels are 32, 32 pixels, and three dimensions, respectively. \noindent\textbf{CIFAR-100~\cite{krizhevsky2009learning}:} This dataset has 100 output classes. This is widely used to evaluate CNN-based studies due to the complexity of the dataset. Here, there are 50,000 training images and 10,000 testing images. There are 20 different types of images in this dataset, and for each type, there are 5 varieties of images are there. For instance, one of twenty superclasses is the aquatic animal, and within that class, we have beaver, dolphin, otter, seal, and whale. The image size is similar to the CIFAR-10. \noindent\textbf{ImageNet-200~\cite{deng2009imagenet}:} This dataset is very popular and widely use to measure the scalability of CNN-based applications. Unlike the previous two datasets, the total number of output classes is 200. ImageNet dataset has been designed to help the computer vision-related task in machine learning. This dataset has 80,000+ nouns (name of the class), and for each class, there are at least 500 images associated with it. This dataset has been used in training models in real-life scenarios. However, due to the complexity of the dataset, a smaller dataset specially intended for research purposes with similar complexity has been made public. This dataset (ImageNet-tiny) comprises 200 types of images. The training dataset has 100000 images, and the testing has 10000 images. There are 3 different variations of the dataset, where the length and width of the images are 224, 64, and 32. In our experiments, we used the 64 version of the dataset to reduce the time-complexity of training such networks and have an experimental dataset that is different from CIFAR-10 and CIFAR-100 in terms of the image size. \paragraph{Models} In this study, we used the ResNet models to evaluate our proposed approach. There are multiple blocks present in a ResNet model, and each block consists of convolution, add, and activation layers. There are two versions of ResNet, the original version, where there is a stack of convolution, add, and batch normalization layers are put together to form a residual block, and finally, those residual blocks build the network. In the second version, the residual block is modified to form a bottleneck layer with convolution, add, and batch normalization. We performed our evaluation against the first version of the network for simplicity and to reduce the training time and resources. Each such version can either have a batch normalization layer or not, as described in the original paper. Since batch normalization is only used to train and does not participate in the prediction, we chose the model without batch normalization to reduce the training time as some of our experiments include training models multiple times. We used ResNet-20, ResNet-32, and ResNet-56, where 3, 5, and 9 residual blocks are present with 21, 33, and 57 convolution layers, respectively. The accuracy reported in this study is different from the original paper because we re-trained the model from scratch with 200 epochs. The code can be accessed at. \section{Introduction} \label{sec:intro} Deep learning is increasingly being used for image segmentation, object detection, and similar computer vision tasks. With the need for bigger and complex datasets, the size and complexity of models also increase. Often, training a model from scratch needs several hours or even days. To ease the training process, layer architecture~\cite{sun2018resinnet, luo2017thinet}, transfer learning~\cite{torrey2010transfer, tan2018survey}, one-shot learning~\cite{vinyals2016matching, rezende2016one}, few-shot learning~\cite{sung2018learning, sun2019meta, lifchitz2019dense, wertheimer2019few}, etc., have been introduced. With these techniques, model structure, parameters can be reused for building a model for similar or different problems. However, in all cases, retraining is needed. Also, there may be scenarios, as shown in Figure \ref{fig:overview}, where a faulty section of the network needs to be amputated or replaced. Now, suppose we can decompose a Convolutional Neural Network (CNN) into smaller components (modules), where each component can recognize a single output class. In that case, we can reuse these components in various settings to build a new model, remove a specific output class, or even replace an output class from a model without retraining. In the past, modular networks~\cite{andreas2016neural, hu2017learning, ghazi2019recursive}, capsule networks~\cite{hinton2000learning, sabour2017dynamic}, etc., have been studied to train the network and incorporate memory into the learning process. But, these modules are not created for enabling reusability and replaceability. As others have noted~\cite{pan2020decomposing}, there are strong parallels between deep neural network development now and software development before the notion of decomposition was introduced~\cite{dijkstra1982role, parnas1972criteria, tarr1999n}, and developers wrote monolithic code that can be reused or replaced as easily. Recently, decomposition has been used to enable reuse and replacement in dense-based networks~\cite{pan2020decomposing}. This work shows that decomposed modules can be reused or replaced in various scenarios. However, this work focused on dense-based networks and did not explore a more complex set of deep learning techniques, e.g., convolutional neural networks. This work~\cite{pan2020decomposing} relies on the dense architecture of the models, where nodes and edges (weight and bias) have a one-to-one relationship. In contrast, edges in CNN are shared among all the input and the output nodes. \begin{figure*}% \centering \footnotesize \subfloat{\includegraphics[, width=1.0\linewidth]{overview.pdf}}% \qquad \subfloat{\input{tbMotiv.tex}} \caption{How Decomposing a Convolution Neural Network into Modules Can Help Solve a Real-life Problem.}% \label{fig:overview}% \end{figure*} In this paper, we propose an approach to decompose a CNN model used for image classification into modules, in which each module can classify a single output class. Furthermore, these modules can be reused or replaced in different scenarios. In Figure \ref{fig:overview}, we illustrate an issue faced by users while using the Google Photo app. We show how Google has resolved the problem and how replacing and reusing decomposed modules can be applied. In the past, Google Photo App tagged a black woman as a gorilla~\cite{verge}. To resolve this issue, Google decided to remove the output class ``Gorilla'' by suppressing the output label~\cite{verge}. Precisely, they have suppressed the output for ``Chimpanzee'', ``Monkey'', ``Chimp'', etc. Though the problem can be temporarily solved by suppressing the output label, to fix the model, one needs to retrain the model. We propose four different solutions based on reusing and replacing decomposed modules. We discuss each approach, its pros, cons, and illustrate how retraining the model can be avoided. The code and other artifacts are made available~\footnote{https://github.com/rangeetpan/Decomposition}. The key contributions of our work are the following: \begin{itemize} \item We introduce a technique to decompose a CNN model into modules, one module per output class. \item We describe an approach for reusing these decomposed modules in different scenarios to build models for new problems. \item We replace a part of the model with decomposed modules. \item We evaluate our approach against the $CO_2e$ consumption of models created from scratch and reusing or replacing decomposed modules. \end{itemize} \textbf{Results-at-a-glance. }Our evaluation suggests that decomposing a CNN model can be done with a little cost (-1.77\% (top-1) and -0.85\% (top-5)) compared to the trained model accuracy. Reusing and replacing modules can be done when the modules belong to the same datasets (reusability: +2.5\%, replaceability: +0.7\% (top-1) and +1.0\% (top-5)) and the different datasets (reusability: -7.63\%, replaceability: +2.5\% (top-1) and -7.0\% (top-5)). Furthermore, enabling reusability and replaceability reduce $CO_2e$ emission by 37 times compared to training from scratch. \textbf{Outline.} In \S\ref{sec:related} we describe the related work. Then in \S\ref{sec:methodology}, we discuss our approach to decompose a CNN model into modules. In \S\ref{sec:results}, we answer three research questions to evaluate the cost of decomposition, the benefit of reusing or replacing the modules, and the resource consumption. Lastly, in \S\ref{sec:conclusion}, we conclude. \begin{figure*}[htp] \centering \includegraphics[, width=1\linewidth]{approach.pdf} \caption{High-level Overview of Our Approach. Inactive nodes are denoted by black boxes.} \label{fig:approach} \end{figure*} \section{Approach} \label{sec:methodology} In this section, we provide an overview of our approach for CNN model decomposition. We discuss the challenges in general. We also discuss each step of decomposing a CNN model into modules. Figure \ref{fig:approach} shows the steps for decomposing a CNN model into modules. Our approach starts with the trained model and identifies the section in the CNN that is responsible for a single output class (Concern Identification). Since we remove nodes for all non-concerned output classes, the identified section acts as a single-class classifier. To add the notion of the negative output classes, we add a limited section of the inputs from unconcerned output classes (Tangling Identification). Finally, we channel the concerns to create a module(s) (Concern Modularization). In the example, we show the decomposition of the module for the output class A. Here, a model trained to predict four output classes has been decomposed into four modules. Each one is a binary classifier that recognizes if an input belongs to the output class. In this paper, we use \textit{concerned} and \textit{unconcerned} as terminologies that represent the input belonging to the output class for which module has been created and all the other output classes, respectively. For example, in Figure~\ref{fig:approach}, we show a module that is responsible for identifying output class $A$. For that module, output class $A$ is the concerned output class, and other output classes, e.g., $B$, $C$, and $D$, are the unconcerned classes. \subsection{Challenges} \label{subsec:challenges} In the prior work on decomposing dense-based models, modules were created by removing edges. There, the value of the node has been computed. If it is $\le$0, then all incoming and outgoing edges are removed. In a typical dense-based model, the first layer is a flatten layer that converts an input into a single-dimensional representation. From there, one or more dense layers are attached sequentially. In each such dense layer, nodes are connected with two different edges, 1) an edge that connects with other nodes from the previous layer (weight) and 2) a special incoming edge (bias). However, for a \textit{Convolution}\xspace layer, this is not the case. Figure \ref{fig:cnn} illustrates a traditional \textit{Convolution}\xspace layer. In that figure, on the left side, we have input nodes. Weight and bias are shown in the middle, and finally, on the right side, we have the output nodes. Each node in the input is not directly connected with the weight and bias, rather a set of nodes (sliding window) are chosen at a time as the input, and the output is computed based on that. The weight and bias are the same for all the input blocks. Due to these differences in the underlying architecture of a \textit{Convolution}\xspace layer, the dense-based decomposition approach could not be applied to a \textit{Convolution}\xspace layer directly. In the next paragraphs, we discuss each of such challenges. \begin{figure} \centering \includegraphics[, width=1\linewidth]{cnn.pdf} \caption{Architecture of a Convolutional Layer. } \label{fig:cnn} \end{figure} \textbf{Challenge 1: Shared Weight and Bias.} The removal of edges in dense-based layers has been done to forcing the value of the nodes that are not needed to be 0 and eventually remove them from the decision-making process in the module. This approach is possible in dense layers because there is a one-to-one relationship between two nodes that belong to subsequent layers. If we remove a part of the weight and bias for one node in the \textit{Convolution}\xspace layer, the weight and the bias will be turned off for all other nodes as well, and there will not be any output produced. \textbf{Challenge 2: Backtracking.} The prior work channels the concerns to convert the module into a binary classification problem. However, before channeling the output nodes, a backtracking approach has been applied that starts with removing nodes at the last hidden layer that are only connected to the unconcerned nodes at the output layers and backtrack to the first hidden layer. However, the same approach cannot be directly applied to the CNN models due to the differences in the architecture of the convolutional layers and other supporting layers, e.g., \textit{Pooling}, \textit{Merge}. \textbf{Challenge 3: Loss of Accuracy in Inter-Dataset Scenarios.} Prior work evaluated their approach by reusing and replacing modules that belong to different datasets. It has been found that such scenarios involve a non-trivial cost. Since these modules involved in the reuse and replace scenario do not belong to the same datasets, they are not programmed to distinguish between them. To remediate the cost, we propose a continuous learning-based approach that enables retraining of the decomposed modules. \section{Motivation} \label{sec:motivation} \begin{figure*}[!ht] \includegraphics[, width=1\linewidth]{overview.pdf} \caption{How Decomposing a Convolution Neural Network can Help Solving a Real-life Problem.} \label{fig:overview} \end{figure*} Decomposing a convolutional neural network into modules can help to achieve various real-life scenarios. Because of the complex architecture and the massive size, retraining a model from scratch is not always feasible. Instead of building a new model, we propose utilizing parts from the already trained model and reusing or replacing them based on different scenarios. First, we describe one such requirement, where replacing a section of the model (module) with another (module) can be done with no or little retraining. Then, we describe how reusing these modules can be done. In Figure \ref{fig:overview}, we have shown a real-life example, where Google Photo App tagged a black woman as a gorilla. To resolve this issue, Google has decided to remove the output class ``Gorilla'' by suppressing the output label. In fact, they have suppressed labels for ``Chimpanzee'', ``Monkey'', ``Chimp'', etc~\cite{verge}., from the output of the convolutional neural network. Though the problem can be temporarily solved by suppressing the output label, to fix the model, one needs to retrain from scratch, which requires both high-computational and time-related resources. Instead of the prior approach, we propose three different solutions that reuse and replace modules from the trained model. We will discuss each of such approaches and their pros and cons and illustrate how retraining the model can be avoided. First, we decompose the faulty convolution neural network into modules for each output class. For instance, we have one module for each output class that classifies whether an input belongs to the output class, for which the module has been created, or not. In this example, our goal is to replace the faulty part or module responsible for classifying gorilla with a working module for the same. If we have another working model that is either trained with the same dataset or a subset of the dataset, we will decompose that working model into modules. The working model needs to have the gorilla and person output label, and that model should not exhibit the behavior present in the faulty model. Then, we can replace the faulty gorilla module with the working gorilla module, and a composed version of the decomposed modules can be sent to production. However, the drawback of this approach is the availability of such models. Training a model with a large dataset needs heavy computational resources and a non-trivial amount of time. Second, we decompose the faulty model into modules. Moreover, we train a new model with a person and gorilla and validate that the trained model does not demonstrate faulty behavior. We decompose the newly trained model into two modules and replace the faulty gorilla module with the new decomposed gorilla module. In this scenario, decomposition can not alone solve the problem. However, the decomposition bundled with the traditional training could help in this situation. Also, training the small model requires less resources. Third, we decompose the faulty model into modules and remove the gorilla module from the collection. In this scenario, there is no cost of retraining involved. However, using this approach, the actual problem of faulty classification has not been addressed. This solution is similar to what Google proposed, but instead of suppressing the label, we remove the module. The pros in this situation are that for other primates (``Chimpanzee'', ``Monkey'', ``Chimp'', etc.), we can remove the modules easily, whereas, for the other two techniques, we need to have models with those output classes or train a small network for them. We can also reuse the person and gorilla module from a working model without the faulty behavior and predict any input classified as a person or gorilla using the faulty model to verify it further. Here, instead of replacing the faulty parts, we reuse modules and add another verification with them. \section{Related Works} \label{sec:related} There is a vast body of work~\cite{backus1957fortran, backus1960report, dijkstra2001go, dijkstra1970notes, dijkstra1982role, parnas1972criteria, liskov1974programming, parnas1976design, america1990designing, dhara1997forcing, cardelli1997program, flatt1998units, tarr1999n} on software decomposition that has greatly influenced us to decompose CNN model into reusable and replaceable modules. The closest work is by Pan and Rajan~\cite{pan2020decomposing}, where the dense-based model has been decomposed into modules to enable reuse and replacement in various contexts. Though this work has motivated to decompose a CNN model into modules, the dense-based approach cannot be applied due to: 1) the shared weight and bias architecture in convolution layers, and 2) support for layers other than dense. Also, this work did not evaluate the impact of decomposition on $CO_2e$ emission during training. Ghazi~{\em et al.}\xspace~\cite{ghazi2019recursive} have introduced modular neural networks to incorporate memory into the model. They have proposed a hierarchical modular architecture to learn an output class and classes within that output class. Though this work has been able to increase the interpretability of the network by understanding how inputs are classified, the modules are not built to enable reusability or replaceability. Other works on modular networks~\cite{andreas2016neural, hu2017learning} have learned how different modules communicate with others to achieve better training. Also, capsule networks~\cite{hinton2000learning, sabour2017dynamic} can be utilized to incorporate memory into deep neural networks. In capsule networks, each capsule contains a set of features, and they are dynamically called to form a hierarchical structure to learn and identify objects. However, modules decomposed by our approach can be reused or replaced in various scenarios without re-training. \citeauthor{sairam2018hsd}~\cite{sairam2018hsd} have proposed an approach to convert a CNN model into a hierarchical representation. At each level, nodes representing similar output classes are clustered together, and each cluster is decomposed further down the tree. Finally, with parameter transfer, the tree-based model is trained. While, in that work, a sub-section of the tree-based can be reused for a subset of the output classes, our approach decomposes a trained CNN model into reusable and replaceable modules to build a model for a new problem (intra and inter dataset) without retraining. Furthermore, we have shown that reusing and replacing modules decreases CO2e consumption significantly. \section{Evaluation} \label{sec:results} \input{tbrq1.tex} In this section, we discuss the experimental settings. Furthermore, we discuss the performance of decomposing the convolutional neural network into modules by answering three research questions, 1) does decomposition involve cost?, 2) how module reuse and replacement can be done compared to retraining a model from scratch?, and 3) does reusing and replacing the decomposed modules emit less $CO_2$? \subsection{Experimental Settings} \subsubsection{Datasets} We evaluate our proposed approach based on three widely used and well-vetted datasets. \noindent\textbf{CIFAR-10 (C10)~\cite{krizhevsky2009learning}:} This dataset comprises of 3-D images of different objects. It has 10 output classes, and the dataset is divided into training and testing datasets. The training dataset has 50,000 images, and the testing dataset has 10,000 images. \noindent\textbf{CIFAR-100 (C100)~\cite{krizhevsky2009learning}:} This dataset has 100 output classes. This is widely used to evaluate CNN-based studies due to the complexity of the dataset. Here, there are 50,000 training images and 10,000 testing images. The image size is similar to the CIFAR-10. \noindent\textbf{ImageNet-200 (I200)~\cite{le2015tiny}:} This dataset is very popular and widely used to measure the scalability of CNN-based applications. Unlike the previous two datasets, the total number of output classes is 200. ImageNet dataset has been designed to help the computer-vision related task in machine learning. This dataset has 80,000+ nouns (name of the output class), and for each class, there are at least 500 images associated with it. This dataset has been used in training models in real-life scenarios. However, due to the complexity of the dataset, a smaller dataset with similar complexity has been made public for research purposes. This dataset (ImageNet-tiny) comprises 200 types of images. The training dataset has 100000 images, and the testing has 10000 images. \subsubsection{Models} We used the ResNet~\cite{he2016deep, he2016identity} models to evaluate our proposed approach. In a ResNet model, there are multiple blocks present and each block consists of \texttt{Convolution}, \texttt{Add}, and \texttt{Activation} layer. There are two versions of ResNet, the original version, where there is a stack of \texttt{Convolution}, \texttt{Add}, and \texttt{Batch Normalization} layers are put together to form a residual block, and those residual blocks build the network. In the second version, the residual block is modified to form a bottleneck layer with \texttt{Convolution}, \texttt{Add}, and \texttt{Batch Normalization}. We performed our evaluation against the first version of the network for simplicity and to reduce the training time and resources. Each such version can either have \texttt{Batch Normalization} layer or not as described in the original paper. Since \texttt{Batch Normalization} is only used to train and does not participate in the prediction, we chose the model without \texttt{Batch Normization} to reduce the training time as some of our experiments include training models multiple times. We used ResNet-20, ResNet-32, and ResNet-56, where 3, 5, and 9 residual blocks are present with 21, 33, and 57 convolution layers, respectively. The reported model accuracies are different from the original paper, as we trained the model from scratch with 200 epochs. \subsubsection{Metrics Used} \textbf{Accuracy.} We compute the composed accuracy of the decomposed modules as shown in the prior work~\cite{pan2020decomposing}. Pan~{\em et al.}\xspace computed the top-1 accuracy for all the experiments, whereas we compute both top-1 and top-5 accuracies. \textbf{Jaccard Index.} Similar to the prior work, we compute the variability between the model and the modules using Jaccard Index. \textbf{$\boldsymbol{CO_2e}$ Emission.} In this context, we refer to $CO_2e$ as carbon dioxide and equivalent gases. These gases are harmful to humankind and the earth due to various reasons. One of them is that they are heat-trapping gases, and the excess presence of such gases can increase the average temperature of the earth, which can lead to several devastating circumstances. To measure the total emission of such gases due to computation, we utilize the metrics used by Strubell~{\em et al.}\xspace~\cite{strubell2019energy}. The total power consumption during the training is measured as , \begin{equation} \label{eq:1} p_t=\frac{1.58t(p_c+p_r+gp_g)}{1000} \end{equation} In this equation, $p_c$, $p_r$, $p_g$, and $g$ denote the average power consumption of CPU, DRAM, GPU, and the total number of GPU cores, respectively. The $t$ denotes the time. Here, 1.58 denotes the PUE co-efficient, which is the same value used in the prior work. We performed our experiment on iMac with 4.2 GHz Quad-Core Intel Core i7 and 32 GB 2400 MHz DDR4 RAM. Since we do not have any GPU, both $g$ and $p_g$ are zero. The power consumption has been measured using Intel Power Gadget ~\cite{intel}. Finally, the $CO_2e$ emission has been computed as, \begin{align} CO_2e=0.954p_t \end{align} \subsection{Results} In this section, we evaluate our approach to understand the cost involved in decomposition, whether the decomposed modules can be reused or replaced, and how decomposition can be beneficial compared to training from scratch. \subsubsection{Does Decomposing CNN Model into Module Involve Cost?} \label{subsec:rq1} \input{tbintrareuse1.tex} \input{tbinterreuse1.tex} To understand how decomposing CNN models into modules performs, we evaluate our approach on 9 datasets and model combinations. First, we decompose the CNN model into small modules, and then we compose them to evaluate how these composed modules perform compared to the trained CNN models. In Table \ref{tb:rq1}, the composed accuracy of the decomposed modules and the trained models' accuracy have been shown. We report the top-1 and top-5 accuracies of the models. Here, in the first and second columns, we show the top-1 and top-5 accuracy of the model. Whereas, in columns 3-11, the accuracy shown is from the composition of the decomposed modules. While composing the modules, we apply the voting-based approach that is similar to the prior work. Also, we compute the Jaccard index (JI) to identify the average variability between the modules and the model. Lesser value of the JI represents better decomposition as the modules are desired to be significantly different from the model. Suppose the value of the Jaccard index is very high. In that case, it denotes that the module has essentially become similar to the model. While the lower JI is a criterion for better decomposition, the cost is another criteria to be considered while decomposing a model into modules. In this study, our objective is to have the least cost of decomposition with the most dissimilarities between the modules and the model. We found that in all the cases, there is a cost involved while decomposing. For instance, our first approach identifies the concern, adds negative examples, and finally modularizes the concern involves 3.46\% and 2.54\% (top-1 and top-5) of loss of accuracy with an average Jaccard index 0.50. Whereas applying dense-based backtracking, the loss has reduced. The average loss with this approach is 1.77\% and 0.85\%, and the average Jaccard index is 0.63. For approach involving the backtrack through the convolution layer includes a loss of 1.86\% and 1.93\% accuracy with an average 0.64 Jaccard index. For the further experiments, we choose the second approach as the loss is the least of all. Based on these results, we can conclude that decomposition is possible in CNN models. However, it involves a small cost, and the modules produced are significantly different from the models. For further studies, we used the dense-based backtracking technique. \subsubsection{How module reuse and replacement can be done compared to retraining a model from scratch?} Here, we evaluate how decomposed modules can be reused and replaced in various scenarios. \label{subsec:rq2} \input{tbintrareplace.tex} \input{tbinterreplace.tex} \textbf{Reusability:} Table \ref{tb:reuse}, and \ref{tb:interreuse} show two different reuse scenarios: 1) intra-dataset reuse, 2) inter-dataset reuse. In intra-dataset reuse, we build a model by taking two output classes from a dataset and building a new model. For instance, output classes 0 and 1 have been taken from CIFAR-10, and we evaluate the accuracy by combining the decomposed modules for output classes 0 and 1 (we represent the output class with their index in the dataset). We compare the performance with retraining a model with the same structure with the same output classes and measure the accuracy. We took the best model for each dataset (based on the trained model accuracy) and the modules created from that. For CIFAR-10, CIFAR-100, and ImageNet-200, the best model in terms of training accuracy are ResNet-56, ResNet-20, and ResNet-20, respectively. Since these models take a long time to train, we performed the experiments for 4 output classes randomly chosen from the dataset to evaluate the reusability scenarios. In Table \ref{tb:reuse}, the intra-dataset reuse scenarios are reported. C1, C2, C3, and C4 denote the four randomly chosen classes, and they are different for each dataset. Since we take 2 output classes in each experiment, the total number of choices for a dataset with $n$ output classes under experiment is $n \choose 2$. In our cases, we take 4 output classes from each dataset to evaluate, and the total choices would be $4 \choose 2$ or 6. For CIFAR-10, reusing the modules increase 6.6\% accuracy, on average. For CIFAR-100, there is an average 0.67\% loss, but 4/6 cases reusing the modules perform better than the trained model. For ImageNet, there is an average 1.5\% increase in accuracy. Overall, the gain in the accuracy in intra-dataset reuse is 2.5\%. In inter-dataset reuse, we take two output classes from different datasets and build a binary classification-based problem. For example, output classes 1 and 2 have been taken from the CIFAR-10 and CIFAR-100 datasets, respectively. We compute the accuracy the same way as we did for intra-dataset reuse scenario. Since the model structure of the decomposed modules for two datasets are different, e.g., the decomposed modules for CIFAR-10 follow the model structure of ResNet-56, whereas it is ResNet-20 for CIFAR-100. The best model in terms of accuracy has been taken for retraining. We did a pilot study and found that ResNet-20 does better in terms of accuracy for the inter-dataset reuse scenario for CIFAR-10 and CIFAR-100 datasets. To overcome overfitting, we store the checkpoints for all training-based evaluations and report the last checkpoint with the best validation accuracy. In Table \ref{tb:interreuse}, the inter-dataset reuse scenarios are reported. We found that inter-dataset reuse has a non-trivial cost. In this case, the loss of accuracy is 12.06\%. Our intuition is that since these modules originate from a different dataset, they still have some traits of the parent dataset. In fact, by applying the tangling identification approach, we deliberately add some non-concerned examples to distinguish between the concerned and the non-concerned examples. To alleviate the effect, we perform a continuous learning-based approach, where we re-apply the tangling identification with the unseen output class(es). We found that enabling continuous learning can reduce the cost of decomposition significantly. The overall loss while reusing modules is 7.63\%, which is a 4.4\% gain compared to the previous reusability approach. Since the input size of the CIFAR-10 and CIFAR-100 images are not the same as ImageNet-200, both training a single model and reusing modules cannot be done. \textbf{Replaceability:} Similar to the reusability scenario, we evaluated both inter and intra-dataset reuses. For intra dataset reuse, we replace a module decomposed from a model with less accuracy with a module for the same output class decomposed from a model with higher accuracy. In Table \ref{tb:intrareplace}, we report the evaluation for replacing the module. For each dataset, we evaluate for 10 output classes to match the total number of classes for all the datasets. For CIFAR-10, we replace a module decomposed from ResNet-32 with a module for the same output class decomposed from ResNet-20. We found that the intra-dataset reuse increases the accuracy by 0.7\% and 1.0\% for top-1 and top-5 accuracy, respectively in comparison to the prior composed accuracy of the decomposed modules. In fact, 80.0\% (24/30) and 83.3\% (25/30) times replacing a module does the better or the same compared to the composed accuracy of the decomposed modules for top-1 and top-5 accuracy, respectively. Also, for 33.3\% and 66.7\% cases, reusing modules does better than the model accuracy for top-1 and top-5 accuracies, respectively. Although we incorporated the continuous learning approach, there is no significant increase in accuracy (top-1: 0.02\% and top-5: 0.01\%). Inter-dataset replacement scenarios are reported in Table \ref{tb:interreuse}. To reduce the experiment time, we replace a module from CIFAR-10 with a module taken randomly from CIFAR-100 and report both composed accuracy and the accuracy of the trained model for four different output classes. We found that for top-1 accuracy, there is a 2.5\% accuracy increase, and for top-5, there is a loss of 7.1\%, on average. \input{motivationtb.tex} \noindent\textbf{Motivating Example.} Here, we recreate the example shown in Figure \ref{fig:overview}. Since human face and Gorilla images are not present in the ImageNet-200 dataset, we added two classes from the ImageNet large dataset. However, there is no class specifically categorized as ``human face'' in the dataset. So, we take the closest class that contains the images of different persons. First, we build a model with 202 (ImageNet-200 + Person + Gorilla) output classes. For the first option, we create a hypothetical model that does not exhibit faulty behavior. We do that by training a model with more epochs (+100 epochs) and achieve higher accuracy (+1.8\%). Then, we decompose the model into modules. Then, we replace the Gorilla module with the module created from the second model. In the second option, we train a model with Person and Gorilla examples and replace the faulty Gorilla module with the newly created one. In the third option, we remove the Gorilla module from the set of modules. Finally, in the fourth option, if the original model predicts Person or Gorilla, we re-verify with the modules created from the 2-class classification model in the second option. The evaluation has been shown in Table \ref{tb:motivating}, and we found that enabling the replacement and reuse of modules can solve the problem. Based on the need and available resources, users can pick any of the four options. \subsubsection{Does reusing and replacing the decomposed modules emit less $CO_2e$?} \label{subsec:rq3} \begin{figure}[!ht] \centering \includegraphics[, trim={2cm 7cm 0cm 7cm}, width=1.12\linewidth]{combined.pdf} \caption{Comparison of $CO_2e$ Emission.} \label{fig:c02} \end{figure} Strubell~{\em et al.}\xspace~\cite{strubell2019energy} have identified that training a model often emits six times more $CO_2e$ than a car emits over a year. To understand how decomposition can help to reduce the harmful effect, we measure the $CO_2e$ emission for both intra and inter-dataset reuse and replace scenarios. First, we start computing the power consumption before executing the program. Then, we measure the average power drawn by other tasks running in the background for 10 sec and compute the average power drawn by CPU and DRAM. We negate these two values to separate the resource consumption of the program and other background tasks. Then, we measure the power consumption for each 100 ms (default for Intel Power Gadget). Figure \ref{fig:c02} shows the $CO_2e$ emission for different scenarios. We do not show intra dataset replacement scenarios as that cannot be compared with training from scratch. For training scenarios, we build the model from scratch, and after training, we predict the same set of images. This experimental setting has been done to compare a similar situation, where developers need to build and predict inputs. The value reported in the figure is the average $CO_2e$ consumption for all the experimented scenarios described in \S\ref{subsec:rq2}. Also, since the epoch has been fixed for each retraining, the power consumption is somewhat fixed for each retraining scenario. However, the best model can be found earlier. For instance, a model is trained with 100 epochs, but the best model is found at the 20th epoch. To remove the effect of overfitting, we compute the power consumed until the return of the best model and report that in the figure. We found that for reuse scenarios, decomposition reduces the $CO_2e$ consumption by 23.7x and 18.3x for the fixed epoch and the best model scenarios, respectively. For replacement scenarios, it is 42x and 31.5x, respectively. If we apply the continuous learning-based approach, there is a slight increase in resource consumption, but still significantly less than training from scratch. Also, we computed the additional $CO_2e$ consumption for the one-time decomposition approach and found that on average 116, 371, and 3800 lbs of $CO_2e$ has been generated for decomposing CIFAR-10, CIFAR-100, and ImageNet-200 models, respectively. The overhead is significantly lower for CIFAR-10 and CIFAR-100 compared to training a new model for both reuse and replace scenarios. However, for ImageNet-200, the overhead is high, but it is a one-time operation that can enable both reuses and replacements at a very low cost. \subsection{Concern Identification} Concern Identification (CI) involves identifying the section of the CNN model, responsible for the single output class. As a result of this process, we remove nodes and edges in the model. In traditional CNN models for image classification, both convolution, and dense layers have the notion of node and edges, and we discuss the concern identification approaches for both the layers. \noindent\textbf{Dense Layers:} Here, the concerned section can be identified by updating or removing the edges connected to the nodes. In a dense-based network, there is a one-to-one relationship between the edges connecting the nodes from different layers (including the bias nodes). For each edge, the originating and the incident nodes are unique except for bias, where the incident node is unique. The edges between nodes are removed or updated based on the value associated with the nodes. In this process, we identify nodes based on the assumption that ReLU has been used as the activation function. Since our work is focused on image-based classification models, ReLU is the most commonly used activation function for the hidden layers. Also, prior work on decomposition~\cite{pan2020decomposing} has been carried out with the same assumption. First, we compute the value associated with the nodes by applying training inputs from the concerned output class. For an input, if the computed value at a node is $\le$0, then we remove all the incident and originated edges. We do that for all the concerned inputs from the training dataset. If the value associated with a node is $>$0 for some input and $\le$0 for other inputs, we do not remove that node. For instance, for a layer $L_d$, there are $n_{L_d}$ number of nodes, and the preceding and the following layer has $n_{L_{d-1}}$ and $n_{L_{d+1}}$ nodes, respectively. For any node at the layer $L_d$, there will be $n_{L_{d-1}}$incident edges and $n_{L_{d+1}}$ outgoing edges. Based on our computation, if a node $n_i$ is inactive (value $\le$0), then all the incoming and outgoing weight edges ($n_{i(L_{d-1})}$ + $n_{i(L_{d+1})}$) and one bias edge incident to $n_i$ will be removed. We do the same for all the hidden dense layers. \input{algoci.tex} \noindent\textbf{Convolution Layers:} In a convolutional layer, we identify the inactive sections in the output nodes by using a mapping-based technique that stores the position of the nodes that are not part of a module. In Algo.\ref{algo:concern}, we describe the steps involved in building the map and storing the nodes' positions. First, we store the weight and bias for all the layers. Then, we identify the parts of the convolution layer that are not used for a single output class. We start by computing all possible combinations of sliding windows at line \ref{algo1:10}. To build the sliding windows, we use the $stride$, $padding$ as input. Below, we describe each such parameter. \textbf{Sliding Window.} In convolutional layers, instead of one input node at a time, a set of nodes are taken as an input for computation. For instance, in Figure \ref{fig:cnn}, the blue box is a sliding window. For each sliding window, one or more output nodes are created based on the size of the shared weight in the layer. \textbf{Padding.} Two variations of padding is possible in CNN, zero-padding and with-padding. In zero-padding, the input is not changed. For with-padding, the input is padded based on the size of the sliding window, and the size of the output will be the same as the input. For the example shown in Figure \ref{fig:cnn}, we used the with-padding, and that adds padding with value zero and transforms the input into (5, 5, 3) size (the white boxes are the added padding). \textbf{Stride.} This parameter controls the movement of the sliding window while computing the output. Stride along with the padding decides the output of the layer. Once we compute the sliding windows (line \ref{algo1:10}), we feed inputs from the training dataset to our approach and observe the output value of that particular convolution layer. At line \ref{algo1:11}, we compute the output of the convolution layer based on S*W + B, where S, W, and B denote the sliding window, shared weight, and bias, respectively. Then, we monitor the value at each node (line \ref{algo1:12}-\ref{algo1:25}). If a node has a value $\le0$, we store the position of the node in our map. We initialize the map with all the nodes (for the first input) that have value $\le0$ (line \ref{algo1:14}-\ref{algo1:16}). The \textit{first} flag is used to denote this first input to the module. Then, we remove the nodes that are previously in the mapping list, but the nodes have a positive value for the input under observation (line \ref{algo1:17}-\ref{algo1:24}). We perform such operations to identify the section of the layer that is inactive for a particular concern. For the batch normalization layer, there is no weight or bias involved, and the layer is utilized for normalizing the input based on the values learned during the training session. Max pooling and average pooling are utilized for reducing the size of the network using the pool size. For merge or add layer, we add the value computed from the two layers connected with this layer. \subsection{Tangling Identification} In concern identification, a module is created based on identifying the nodes and edges for a single output class. Since all the nodes and edges related to the other output classes in the dataset have been removed, the module essentially characterizes any input as the concerned output class or behaves as a single-class classifier. To add the notion of unconcerned output classes and able to distinguish between the concerned and unconcerned output classes, we bring back some of the nodes and edges to the module. In Tangling Identification (TI), a limited set of inputs belonging to the unconcerned output classes have been added. Based on the prior work, we add concerned and unconcerned inputs with a 1:1 ratio. For instance, if we have a problem with 200 output classes and build a module based on observing 1000 inputs from the concerned class, then we observe 5 inputs from each unconcerned class (5x199=995$\approx$1000). \subsection{Modularizing Concerns} \label{subsec:cm} So far, we identify the section of the network that is responsible for an output class and added examples from unconcerned output classes. However, the module is still an $n$-class classification problem. We channel the output layer for each module to convert that into a binary classification-based problem. However, before applying the channeling technique, we remove irrelevant nodes (do not participate in the classification task for a module) using a bottom-up backtracking approach. \noindent\textbf{Dense Layers:} We channel the out edges as described by the prior work~\cite{pan2020decomposing}. Instead of having $n$ nodes at the output layer ($L_{d}$, where $d$ is the total number of dense-based layers), two nodes (concerned and unconcerned output nodes) have been kept. For instance, the concerned output class for a module is the first output class in the dataset. We have $n$ output classes and $n$ nodes ($V_1, V_2, \dots, V_n$) at the output layer. Also, the layer preceding the output layer ($L_{d-1}$) has $n_{L_{d-1}}$ nodes. For each node at the output layer, there will be $n_{L_{d-1}}$ incident edges. For instance, the incoming edges for $V_1$ node will be $E_{11}, E_{21}, \dots, E_{n_{L_{d-1}}1}$, where $E_{n_{L_{d-1}}*1}$ (in this case, n=1) denotes that an edge is connected with $n_{L_{d-1}}^{th}$ node from $L_{d-1}$ layer and the first node at the output layer. For the module responsible for identifying the first output label, the edges incident to the first node (as the concerned node is $V_1$) at the output layer have been kept intact. However, all the other edges are modified. All the edges incident to any of the unconcerned nodes ($V_2$, $V_3$, $\dots$, $V_n$) at the $L_d$ layer will be updated by a single edge. The assigned weight for the updated edge is the mean of all the edges (same for bias). Then, that updated edge has been connected to a node at the output layer, which is the unconcerned node for the module. For a module, there will be two nodes at the output layer, $V_c$ and $V_{uc}$, where $V_c$ and $V_{uc}$ denote the concerned node and the unconcerned node. All the updated edges will be connected to the $V_{uc}$. \noindent\textbf{Modularizing Concern: Backtrack:} Once the nodes at the output layer are channeled, we backtrack the concerned and unconcerned nodes to the previous layers. In this process, we remove the nodes that only participate in identifying the unconcerned classes. First, we discuss the backtracking approach to handle the dense layers and other non-dense layers, and then we describe how we can backtrack till the input to reduce the size of the module. In all approaches, we support the other layers, e.g., pooling, merge, flatten. \begin{figure}[htp] \centering \includegraphics[, width=0.88\linewidth]{backtrack.pdf} \caption{Backtrack Through a Convolution Layer. } \label{fig:backtrack} \end{figure} \input{algodbp.tex} \textbf{Modularizing Concern: Backtrack To Last Convolutional Layer (MC-BLC).} Once we channel the output layer, we prune the network based on the inactive nodes at the dense layers. In a typical CNN model, either a \textit{Pooling} layer, \textit{Convolution} layer, or a \textit{Merge} layer will precede \textit{Dense} layers and the \textit{Flatten} layers In this approach, we leverage that information to backtrack through the \textit{Dense} layers (including \textit{Flatten} layer) to the last convolution layer(s) (based on the presence of \textit{Merge} layer or not) or the pooling layer. In this process, we identify the nodes that have edges $E=\left\{E_{ij}; i\in L_{d-1}, j\in L_{d}, j\in V_{l(uc)} \right\}$, where all the edges are only connected to the unconcerned nodes ($V_{uc}$) at the $d^{th}$ layer (line \ref{algo3:4}-\ref{algo3:10}). We start the backtracking process from the output layer and move through the dense layer. For each layer, we identify the nodes connected to the unconcerned nodes in the following layer and remove them from the model. Also, we tag the removed nodes as the unconcerned nodes for that layer. To identify the nodes that strongly contribute to the unconcerned node, we introduce a constant ($\delta$) to verify the value associated with the node. Based on the experimental evaluation, we used $\delta=0.5$. Then, we backtrack the nodes at the layer preceding the output layer is identified at line \ref{algo3:11}-\ref{algo3:17}. Finally, we backtrack to the flatten layer. In a traditional CNN model for image classification, the flatten layer is preceded by a pooling layer, or a merge layer, or a convolutional layer. If the preceding layer is a convolution layer, we update the mapping (as discussed in \S\ref{subsec:cl}) for that particular convolutional layer. Since the convolution layer's output is directly reshaped into the flatten layer, there is a one-to-one relationship between the two layers. If the preceding layer is a pooling layer, then there will be $X^2$ (X is the pool size) inactive nodes at the pooling layer for one inactive node at the flatten layer. If the preceding layer is a merge layer, then the convolution layers that are merged will be updated. \textbf{Modularizing Concern: Backtrack To Input (MC-BI).} In the previous approach, we can only backtrack from the output layer to the last convolution layer. However, we cannot backtrack through the convolution layer. In a convolution layer, the input nodes cannot be directly mapped with the output nodes. For instance, in Figure \ref{fig:backtrack}, the input image shown on the left side is turned into the image shown in the middle, which is after adding the paddings (for this example, we choose \textit{Valid} padding). In the output, the nodes on the top left corner for both arrays will be produced by the first sliding window (blue box) from each array shown in the middle. So, for mapping, a node in the output on the right side of the image, at least 4 (in this example, we chose the sliding window size to be 2x2) nodes can be mapped. Those four individual nodes are also mapped with other nodes in the output. The black-colored node in the middle is a part of two sliding windows (the blue box and the orange box). To remove irrelevant nodes from the convolution layer, we take a two-pass approach. First, we store the position of the nodes in each sliding window with the nodes in the output (forward pass). During the forward pass, we store the mapping $M=\left\{(V_i, V_j) ; V_j=f(V_i, W, B)\right\}$, where $f$ denotes the convolution operation. During the backward pass, we remove the nodes. \input{algobp.tex} In Algo. \ref{algo:cmfb}, we describe the step to do the mapping. From line \ref{algo4:1}-\ref{algo4:10}, the forward pass has been described. In the forward pass, we store the mapping between the sliding window and output nodes. In order to denote the position of the sliding window, we mark each node with a unique number (line \ref{algo4:4}-\ref{algo4:5}) before adding the padding. For padding, the nodes are marked as ``0'' as they are not present in the input of the \textit{Convolution}\xspace layer. Then for each output node, the input nodes are stored in a list. In this process, we define an operation named \texttt{sw} that computes the sliding windows from the weight $W$, padding $pad$, and stride. Now, we compute the mapping with the input and the output nodes at line \ref{algo4:12}. Then, we separate the input and the output nodes at line \ref{algo4:13} and \ref{algo4:14}. We scan through the inactivate nodes in the output and identify if they match the pattern as illustrated in Figure~\ref{fig:backtrack}. We identify all the input nodes that are mapped with an output node and vice versa. We focus on searching nodes that are not part of the padding operation and remove the nodes marked with 0 at line \ref{algo4:18}. For each such input node, we find all the output nodes generated from the particular input node. If these output nodes are already in the deactivation node list, we add the input node to the deactivation list for the preceding convolution (output of the preceding convolution layer is the input of the next convolution layer). If the previous layer is an add layer, then the two convolution layers that are merged at the merge layer are updated with the changes. If the preceding layer is a pooling layer, the update is carried based on the pool size. \subsection{Continuous Learning} \label{subsec:cl} In the prior study, reusing modules that originated from different datasets involves non-trivial cost. Our intuition is that since the modules are originated from a different dataset, they still have some traits of the parent dataset. In fact, by applying the tangling identification approach, we deliberately add some unconcerned examples to learn the modules on how to distinguish between the concerned and the unconcerned examples. However, in the inter dataset scenarios, the unconcerned output classes are not the same. To solve this problem, we propose a continuous learning-based approach. In deep learning, continuous learning~\citeauthor{collobert2008unified}~\cite{collobert2008unified} has been widely applied. In Figure \ref{fig:cl}, we illustrate a reuse scenario, where module F is originated from dataset 1 and module 2 is originated from dataset 2. Dataset 1 represents a set of English letters (A-G), and applying decomposition creates modules for each output class. Similarly, dataset 2 represents a set of English digits (1-7), and decomposition creates seven modules, each for one output class. When module F and module 2 are reused in a scenario, based on the prior work, each input belongs to 2, and F will be given as input to the composition of the decomposed modules. However, due to the parent dataset traits, module 2 can recognize itself but does not know how to distinguish from any input belonging to the output class F. To learn the concerned output classes in this scenario, we take the unconcerned section of the dataset. For instance, for module F, the unconcerned output class will be output class 2 from dataset 2. We take the examples from output class 2 from dataset 2 and update module F by removing the nodes responsible for detecting the output class 2. We do the same for module 2, where we remove the nodes responsible for recognizing output class F from dataset 1. Finally, the modified modules are ready to be reused. \begin{figure} \centering \includegraphics[, width=0.84\linewidth]{CL.pdf} \caption{Continuos Learning. } \label{fig:cl} \end{figure}
\section{Introduction}\label{sec1} The wireless communication networks are experiencing a paradigm shift from being smartphone-centric to become more of an Internet-of-Things (IoT) oriented system that connects billions of miniature and power-limited devices \cite{8755300}. In order to support hyper-connectivity of these massive IoT networks, the next generation wireless communication systems such as sixth generation (6G) networks are envisioned to be characterized by an unprecedented flexible, adaptive and reconfigurable architectures. Hence, the next generation communication systems will entail optimization of the sheer number of network parameters. Keeping this fact in mind, it is clear that existing optimization approaches that are based on conventional mathematical models will either become completely obsolete or highly inadequate for the next generation wireless communication systems. In other words, it will be the first time since the inception of wireless networks that a \textit{complexity crunch} will exist for optimizing the resource allocations of the next generation wireless networks. Moreover, the current non-data driven techniques will be unable to achieve autonomy in the next generation of wireless networks. This necessitates to develop new data-driven techniques which either complement or completely replace the traditional non data-driven optimization approaches and should be able to orchestrate the network resources in an intelligent manner. \begin{table*}[t] \caption{Survey articles on FL in the domain of wireless communications.} \label{tab:1} \centering \begin{tabular}{|c|c|c|c| \hline \multirow{1}{*}{\textbf{Title}} & \multirow{1}{*}{\textbf{FL for wireless}} & \multirow{1}{*}{\textbf{Wireless for FL}} & \multirow{1}{*}{\textbf{Communication efficient FL}} \\ \hline Niknam \textit{et al.}\cite{niknam2020federated} & \ding{52} & & \\ Lim \textit{et al.} \cite{lim2020federated} & \ding{52} & & \ding{52} \\ Liu \textit{et al.} \cite{9205981} & \ding{52} & & \ding{52} \\ Khan \textit{et al.} \cite{khan2020federated} &\ding{52} & & \ding{52} \\ Wahab \textit{et al.} \cite{wahab2021federated} & \ding{52} & & \ding{52} \\ Xia \textit{et al.} \cite{xia2021survey} & \ding{52} & & \ding{52} \\ Du \textit{et al.} \cite{du2020federated} & \ding{52} & & \\ Chen \textit{et al.}\cite{chen2021distributed} & & \ding{52} & \ding{52} \\ Gafni \textit{et al.}\cite{gafni2021federated} & & \ding{52} & \\ Hu \textit{et al.}\cite{hu2021distributed} &\ding{52} & & \ding{52} \\ Hellstrom \textit{et al.}\cite{hellstrom2020wireless} & & \ding{52} & \\ \textbf{Our paper} & \ding{52} & \ding{52} & \ding{52}\\ \hline \end{tabular} \end{table*} The performance of deep-learning has been phenomenal in areas such as computer vision, natural language processing (NLP) and speech recognition etc\cite{dong2021survey, dargan2020survey}. Moreover, the performance of deep learning is surpassing the performance of ordinary machine learning algorithms with the ever-increasing amount of trainable data and the recent advancements in computing devices e.g., Graphical Processing Units (GPU)\cite{chen2019deep}. Motivated by this fact and to address the aforementioned complexity crunch challenge, researchers have shown interest to develop new deep learning based solutions specifically tailored for next generation wireless communication systems. The job of a typical resource management unit in any wireless system is to allocate network resources (e.g., transmission power, bandwidth, beamforming vector, time slots, antennas, base-stations etc.) with an objective to optimize one or more performance metrics (e.g., throughput). In case, an accurate mathematical model exists that characterizes the performance metric, then any resource allocation decision can be cast into an optimization problem. Apparently, solving such an optimization problem seems to be a trivial task. However, considering the fact that the next generation wireless communication systems will be highly complex in nature owing to integration of advanced technologies such as highly dense small cell networks, Massive multiple-input-multiple-output (MIMO), distributed MIMO and Intelligent reflecting surfaces (IRS) etc., the underlying optimization problems are generally non-deterministic polynomial time (NP)-hard. Therefore, the complexity for solving these problems increases exponentially with the number of radio parameters which are far more in number for future networks as compared to the current wireless networks. Furthermore, the resource allocation decision has to be repeated every time when any of the system parameters (e.g., users’ position, channel realizations etc.) change its value and this change occurs quite frequently particularly in high mobility environments due to shorter channel coherence time. Therefore, the real-time implementation of existing resource allocation (or optimization) algorithms is a huge challenge for highly complex next generation wireless communication systems. However, the use of deep learning techniques with a trained neural network will enable true online (real-time) resource allocation and thus solve the NP-hard problems efficiently. Moreover, it is well-known that neural networks are universal function approximators\cite{hornik1989multilayer}, thus it is quite possible to either completely eliminate or reduce the dependence of human knowledge and to achieve complete autonomy for the wireless networks. Majority of the deep learning related works in many fields including computer vision, NLP and wireless communications \cite{voulodimos2018deep, otter2020survey, zhang2019deep} considered a central entity that accommodates an entire raw data for training the neural network. As discussed above, these deep learning based approaches have shown remarkable performance for solving challenging non-convex optimization problems, however some critical issues have been observed in the centralized architecture of these deep-learning solutions. Firstly, a massive amount of data needs to be stored, processed and trained at the central entity, which seems to be impractical as the training process on a single compute instance is very time-consuming \cite{9120226}. Secondly, as the raw data has to be uploaded to the central entity, this uplink data offloading can be extremely expensive for devices with short battery life, such as smartphones and IoT nodes. Thirdly, uploading such large volume of raw data exacerbates the stress on wireless networks and can cause network congestion. Fourthly, devices that are used for privacy-sensitive applications, owing to the potential of theft of their valuable data, may be unwilling to upload their raw data\cite{hosseinalipour2020federated}. Federated learning (FL) has recently emerged as a disruptive distributed learning paradigm that has an ability to overcome all the aforementioned issues of the centralized learning approaches. Moreover, FL facilitates Artificial Intelligence (AI) democratization in which besides the large enterprises, small organisations can also play role in data storage, processing, inference and decision-making. It is envisaged that 6G communication systems will be based on the concept of self-sustaining networks, which refer to the networks that can optimize themselves automatically and handle all dynamic interactions with the real-world environment without human involvement. Traditional centralized deep learning algorithms will not be able to achieve the desired outcomes due to tremendous computational overload in these dynamic network settings, which create massive volumes of data in a short amount of time. Therefore, we believe that FL will be a critical component in reaching the objective of self-sustaining networks, as managing massive dynamic data will not be a problem when there is a large number of devices available to store, process, compute such huge data and to train a single global model collaboratively.\\ \section{Related surveys on FL and Our Contributions} \begin{figure*}[t!] \centering \includegraphics[width=0.75\textwidth, height=5in]{bidirectional-diagram} \caption{Illustration of the Bi-directional relationship} \label{fig:1} \end{figure*} Motivated by the huge advantages of the FL when compared to the centralized learning approaches, recently few survey articles have appeared that discuss FL in the domain of wireless communications. These survey papers are listed in Table 1. In \cite{niknam2020federated}, the authors survey FL and its applications towards 5G networks along with the future directions. Lim \textit{et al.} \cite{lim2020federated} present a detailed tutorial on FL and a comprehensive survey on challenges and applications of FL in mobile edge networks (MEC). It is worth mentioning here that this paper put more focus on the statistical challenges of FL which have been less discussed in prior literature. Liu \textit{et al.} \cite{9205981}, provide a detailed survey on the impact of FL for achieving the goals of 6G communication systems. This paper discusses the core challenges in the deployment of FL in wireless networks and the authors propose some key ideas to solve these challenges. In context of the IoT networks, Khan \textit{et al.} \cite{khan2020federated} provide a survey that discusses the advances, evaluation metrics, challenges, taxonomy of literature and future directions of FL . Furthermore, the authors in \cite{wahab2021federated} present a detailed survey on FL for the advancements of wireless communications with focus on grouping the existing literature using a multi-level classification scheme. Furthermore, Xia \textit{et al.}\cite{xia2021survey} provide a detailed analysis on the intersection of FL and edge computing with a focus on the challenges, applications, security, privacy and tools. Du \textit{et al.} \cite{du2020federated} discuss a comprehensive overview of the recent advances and applications of FL in the context of vehicular networks and IoT. Chen \textit{et al.}\cite{chen2021distributed} present a comprehensive survey on the deployment of distributed learning systems over wireless networks with a major focus on communication efficiency of all the different paradigms of distributed learning. In addition, Gafni \textit{et al.}\cite{gafni2021federated} provide a detailed survey on the need for efficient signal processing to boost the performance of FL systems deployed at the edge. Hu \textit{et al.}\cite{hu2021distributed} review the topic of distributed machine learning and its applications in wireless networks and communication efficiency. Hellstrom \textit{et al.}\cite{hellstrom2020wireless} present a survey that discusses the role of wireless communications for performance characterization of the FL. It is evident from the aforementioned discussion and Table \ref{tab:1} that the majority of the survey articles focus either on applications of FL for wireless communications or on designing communication efficient FL protocols. The role of wireless communications for FL has been touched upon in relatively less number of survey articles e.g., in \cite{chen2021distributed} \cite{gafni2021federated} \cite{hellstrom2020wireless}.To the best of our knowledge, this is a first survey article that highlights the bidirectional relationship between FL and wireless communications by providing a holistic overview on the FL for wireless, wireless for FL and communication efficient FL. This bidirectional relationship is shown in Figure \ref{fig:1} that illustrates a scenario of the future wireless networks (e.g., a multiuser MIMO setup with multiple users that carry their local data sets) where a global model is trained in a distributed manner using FL. This global model is responsible for decision making and transforming the network into a self-sustaining network which manages and allocates resources and takes control decisions in real-time. However, the federated training would only be beneficial if efficiency of the wireless network is optimal as FL needs to transmit the model over uplink and downlink channels. \textit{We term this inter-dependency among FL and wireless communications as a bi-directional relationship. This paper emphasizes the fact that there needs to be frameworks and solutions in future which jointly optimize both FL and wireless communications considering the significance of this bidirectional relationship.} Keeping aforementioned discussion in mind, our main contributions are summarized as follows: \begin{enumerate} \item[(i)] An important `bidirectional' relationship among FL and wireless networks has been explored in a comprehensive manner. None of the existing survey papers take into account this inter-dependency which is crucial in order to make them co-exist and achieve the goals of the next generation wireless communication systems. \item[(ii)] We classify progress in this field into three categories: FL for wireless communications, Communication-efficient FL and Wireless communications for FL. This kind of fine-grained classification has been mostly overlooked and has not been discussed in a holistic manner. \item[(iii)] For the first time, we discuss the role of the smart radio environments (i.e., IRS assisted environments) in the context of wireless for FL. \item[(iv)] Our survey article also provides a discussion on the open problems and future directions of this interesting but less explored field, which we believe will help researchers to put focus on the important but challenging problems. \end{enumerate} \section{Organization} The organization of the rest of this survey article with its sections and subsections is shown in Figure 2 using a hierarchical diagram. This paper is mainly divided into nine sections. Section \ref{sec2} provides the necessary background knowledge required to understand the further sections of this paper. In particular, in this section, we provide theoretical details about the centralized and distributed learning strategies. In addition, we also present an elaborate theory of FL and its statistical perspective. Furthermore, Section 5 provides discussion about those techniques that can be used for communication-efficient FL. Section \ref{sec4} presents a detailed discussion on the influence of wireless communication on the performance of the FL. In Section 7 we discuss the impact, challenges and applications of FL for the advancements of wireless communication networks. Moreover, Section 8 provides a discussion on all the open challenges and future directions which we believe are capable of driving breakthroughs in this domain. Finally, Section 9 concludes the survey article. \begin{figure}[t] \centering \includegraphics[width=0.4\textwidth]{cdl} \caption{Centralized training} \label{fig:3} \end{figure} \begin{figure*}[!t] \centering \includegraphics[width=0.9\textwidth]{org} \caption{Paper organization} \label{fig:2} \end{figure*} \section{Evolution towards federated learning}\label{sec2} The exciting race for intelligence began almost 78 years ago, when threshold logic inspired by the human brain was used to create a computer model for neural networks. After that, the inventions of Back-propagation \cite{rumelhart1986learning}, Perceptron\cite{rosenblatt1958perceptron}, Hebbian learning \cite{hebb1949organization} and Hopfield Networks\cite{pribram2014hopfield} transformed the concept of neural networks into a promising field. However, due to the rise of shallow machine learning algorithms like Decision Trees and Support Vector machines, the progress in neural networks was on a stall for many years. Back in 2006, Hinton \textit{et al.}\cite{hinton2006reducing} proposed the concept of Deep Belief Nets which was a stepping stone towards the deep learning revolution. Multiple advances, such as the ImageNet moment\cite{krizhevsky2012imagenet}, increased computing power in terms of powerful GPUs and the emergence of big data, have since moulded deep learning into one of the most successful fields in history. In this section, we will go through a brief overview of the theoretical aspects of both centralized learning, distributed learning and federated learning. \subsection{Centralized learning} In centralized training, the deep learning model is housed in a single PS and client edge devices send their entire data sets to the server. All of these client's local data sets are aggregated and loaded batch-wise to train the model as shown in Figure \ref{fig:3}. The most frequent way for training deep learning models is to employ Gradient Descent\cite{ruder2016overview}, a popular optimization algorithm that iterates over training data and gradually changes model parameters ($\theta$) in order to minimize a loss function ($L$). Following are variants of the Gradient Descent algorithm that are used widely in deep learning theory: \begin{enumerate} \item \textbf{Vanilla gradient descent: } All of the samples from the training dataset are forward fed through the neural network in Vanilla / Batch gradient descent, thus there is just one parameter update step for the whole dataset. The learning rate $\eta$ determines the size of a parameter update step. \begin{equation} \theta = \theta - \Dot{\eta}{\nabla_\theta}{L(\theta)} \end{equation} It has a smooth optimization curve, but it would only be helpful in very small datasets because modern-day deep learning models contain millions of trainable parameters and training would take months with Vanilla gradient descent. \item \textbf{Stochastic gradient descent: } Only one random sample from the training dataset is forward transmitted and backpropagated upon in Stochastic gradient descent (SGD) to create one parameter update step. It has a fluctuating optimization curve due to its stochastic nature, but with an adequate learning rate, global minima may be attained in less time than Batch gradient descent. \begin{equation} \theta = \theta - \Dot{\eta}{\nabla_\theta}{L(\theta, x^{(i)}, y^{(i)})} \end{equation} \item \textbf{Mini-batch gradient descent: } In mini-batch gradient descent, the parameter update step works upon a random batch of training data of batch-size $n$. It is superior to Stochastic gradient descent because of its more steady convergence, and it is superior to Batch gradient descent because with an ideal batch size $n$, it can be used on bigger datasets. \begin{equation} \theta = \theta - \Dot{\eta}{\nabla_\theta}{L(\theta, x^{(i:i+n)}, y^{(i:i+n)})} \end{equation} \end{enumerate} \subsection{Distributed learning} As the datasets and models have been growing at an unprecedented rate, it is becoming impractical to train a model on a single machine\cite{l2017machine}. In order to overcome this challenge and to preserve privacy of the end users, distributed learning strategies are gaining popularity, as discussed earlier. Distributed learning is divided into two categories (as illustrated in Figure 4) dependent on which component of the training process is distributed: \begin{enumerate} \item \textbf{Model parallelism: } It refers to the technique of training large models by sharing the layers among different compute resources and training them using an efficient parallel pipeline. \item \textbf{Data parallelism: } It refers to splitting the large datasets into multiple parts and training the model(s) on those chunks of data in parallel. \end{enumerate} Data parallelism is the most important paradigm as most of the wireless edge devices do not yet have the capability to utilize model parallelism due to computing constraints. Distributed learning is an important area, however it is still in its early stages of development. Most distributed training methodologies have been focused on using large data centers and dividing data and models within them, however this approach does not utilize the full advantage of distributed learning and is still computationally expensive. Moreover, this approach poses a threat to user's private data. The various types of distributed learning methods are illustrated in Figure \ref{fig:4} with categorization based on model or data parallelism. \begin{figure*}[t!] \centering \includegraphics[width=350pt]{ddl} \caption{Types of Distributed deep learning} \label{fig:4} \end{figure*} \\ Ensemble learning is the process of creating and combining multiple models to address a specific machine learning problem. The obvious reason for the ensemble technique comes from human nature and our proclivity to collect and consider several viewpoints in order to make a complicated decision\cite{sagi2018ensemble}. As it uses multiple diverse models to train on the same dataset, it falls under pseudo model parallelism. When environmental dynamics impact agent's decisions, they must learn about them and adapt their techniques based on their experiences with agent-to-environment and inter-agent interactions. Reinforcement Learning (RL) is important because of its exploration and exploitation capabilities. In RL, exploration assists agents in learning about the implications of their actions. Multi-agent RL is used to investigate the interactions of several agents in a comparable environment as they make decisions based on local observations. It can fall into the paradigm of data parallelism when each agent trains on decentralized datasets, and also fall under model parallelism when a large agent is parallelized over a compute instance for faster convergence. FL is a distributed learning methodology that falls under the category of data parallelism \cite{mcmahan2017communication}. Each client has its own training dataset, which is not shared with the PS. As illustrated in Figure 2, a global model is delivered from the PS to all participating client devices and trained on each of their local datasets. As FL employs distributed data, it is a perfect method for training deep learning models over these private datasets of client devices. This would help to capture the local patterns of each user, making the model much more personalized and thereby making better decisions for the user's devices. For instance, the first real-world deployment of FL was observed in Gboard, the multilingual keyboard by Google presented in Android smartphones. FL made it possible to capture user behavior with local learning which eventually led to enhancing the future next-word predictions. Split learning \cite{vepakomma2018split} is a type of model parallelism, where the neural network's layers are split and transferred to multiple devices to be trained locally. A deep neural network with a huge size cannot fit into the tiny memory of an edge device. By breaking a single model into numerous segments and spreading the lower portions among different clients holding raw data, Split learning addresses this problem. Each device uploads its model's cut-layer activations by linking the lower segments to a shared top segment maintained at a PS. Gossip learning\cite{giaretta2019gossip} is a type of Distributed learning in which there is no requirement for a central entity to create a global model or to aggregate model updates from local learners. Similar to FL, it is a recent paradigm built as an on-device collaborative training architecture that does not need the transfer of raw data. Fog learning automatically spreads machine learning models to train throughout a network of nodes, from edge devices to cloud servers. Fog learning\cite{hosseinalipour2020federated} improves FL in three ways: on the network, in heterogeneity, and in proximity. It takes into account a multi-layer hybrid learning architecture made up of heterogeneous devices with varying degrees of proximity. The fog learning system automatically distributes machine learning model training over a continuum of nodes, from edge devices to cloud servers. Fog learning improves FL in three key ways: network, heterogeneity, and proximity. It analyses a multi-layer hybrid learning framework made up of heterogeneous devices located at different distances. The parameters/gradients of the trained (Edge) models are uploaded to the server and aggregated with the Global model using specific aggregation methods. \subsection{Theoretical notions of Federated learning} \subsubsection{FL training steps} A typical FL training round is a multi-stage procedure orchestrated by a global PS. A general template\cite{kairouz2019advances} for any FL round involves the following steps: \begin{enumerate} \item \textbf{Client selection: }The PS selects a set of clients based on some criteria. \item \textbf{Global model broadcasting: }The participating client devices download the global model present at the PS. \item \textbf{Local training: }The clients perform on-device computation using any form of gradient descent and update their respective local models. \item \textbf{Local updates transfer: }After each FL round on a client device, the parameters / gradients of the locally trained model are transmitted to the PS. \item \textbf{Global aggregation: } The PS collects parameters / gradients from multiple clients and aggregates them to update the global model. \end{enumerate} \subsubsection{Statistical perspective} Federated training occurs under several constraints such as non-independent and identical distributed (non-IID), unbalanced and massively distributed local datasets of client devices along with imperfections of the wireless network. FL has been classified into three categories based on statistical aspects of the accessible decentralized data, as illustrated in Figure \ref{fig:5}. \begin{enumerate} \item \textbf{Horizontal FL: }This is the scenario when the decentralized datasets have the same feature space, but differ in sample space. A typical example would be the use-case of FedFace\cite{aggarwal2021fedface}, in which a global optimal face recognition model gets trained by using private facial data of multiple client devices each employ the same facial application. \item \textbf{Vertical FL: }It refers to the scenario when the decentralized datasets have same sample space, but they differ in feature space. An example of Vertical FL would be an e-commerce company and a social media platform trying to collaboratively train a model to predict customer's purchase behaviour. Here, the two companies have a large number of common users which make them have the same sample space, but they have non-overlapping features as an e-commerce company would generally track a customer's product viewing and purchase history whereas the social media app would track following, likes and social behaviour of the customer. \item \textbf{Transfer FL: }It refers to the case when the decentralized datasets differ from each other in terms of both sample and feature space. An example of Transfer FL is a recommendation model that learns from various app-usage behaviours of two users in different nations. Since they use different applications on their devices, resulting in a distinct decentralized datasets without any overlap of sample and feature space among them. \end{enumerate} \begin{figure*}[t!] \centering \includegraphics[width=350pt]{FLtypes} \caption{Types of Federated learning} \label{fig:5} \end{figure*} \section{Communication efficient Federated learning}\label{sec3} One of the main goals for designing FL was to reduce communication overhead, however deployment of FL in practice still requires considerable communication resources. Hence, in the sequel, we discuss the major advances and efforts that are made in the literature to make FL more communication efficient and deployable. \subsection{Efficient global aggregation} The technique used for globally aggregating parameters/gradients from all the clients needs to be statistically efficient in order to reduce the time required for convergence of the global loss during FL training. In literature, several global model aggregation and training techniques have been proposed, with Federated Averaging (FedAvg) being the standard. In FedAvg\cite{mcmahan2017communication}, at first the PS initializes the global model and selects a random set of $M$ clients out of all of the available client devices. A global model with random weights is initialized at the PS and passed on to each of the client devices. At each participating device, the local datasets are divided into mini-batches each having size of $B$ and the local training phase starts in parallel across all the participating clients. In each epoch of the local training, each mini-batch is passed on a step of gradient descent for minimizing the local loss function. All the local weights from each client are transferred to the PS via \textit{wireless links} and the PS aggregates these weights/gradients together by averaging them. FedProx \cite{li2018federated} is an improved version of the FedAvg algorithm by tolerating partial work and varying resource constraints among the participating client devices. In other words, not all devices have the computing power to handle model training at the same scale, therefore FedProx includes a variable called $\gamma$-inexactness that represents how much work the device can manage. It also includes a proximal factor, which helps to address statistical heterogeneity by limiting local updates to be closer to the global model without needing an explicit definition of the number of local epochs. It also allows for the safe integration of varying amounts of local effort induced by system heterogeneity. Federated Matched Averaging (FedMA) \cite{wang2020federated} is a novel statistical layers-wise FL approach for current Convolutional Neural Networks (CNNs) and Long short term memory networks (LSTMs) that use Bayesian non-parametric approaches to adjust the data heterogeneity. It considers permutation invariance of each neuron in the model before the global aggregation to achieve globally adaptive model size. FedPAQ\cite{reisizadeh2020fedpaq} is a communication-efficient FL approach that incorporates Periodic Averaging and Quantization. It involves periodic averaging, in which models are updated locally at devices and only periodically averaged at the PS. It takes into account partial device involvement, in which only a small percentage of devices engage in each round of training. Moreover, it utilizes quantized message-passing where the edge devices quantize their updates before uploading to the PS. \subsection{Gradient compression} FL requires high network bandwidth during the gradient transfer phase over the uplink wireless channels and model transfer phase from PS to client devices over downlink channels. Widely used models with deep architectures such as transformers have upto a billion parameters, which would lead to a massive communication bottleneck if used for standard FL training. Gradient compression is a promising solution which involves selective transmission of gradients during the FL training rounds in order to reduce the effect of the communication bottleneck. Deep Gradient Compression (DGC) was presented by Lin \textit{et al.}\cite{lin2017deep} that leveraged several advanced techniques and achieved up to 600 times compression of the gradients without significant degradation in performance. The authors used gradient sparsification to send only those gradient updates in each communication round which are larger than a threshold to ensure that most important gradients are transmitted. The total communication cost in distributed training depends on the number of bits in each transmission and number of communication rounds. To reduce the number of bits in each round, Sattler \textit{et al.}\cite{sattler2019sparse} proposed sparse binary compression (SBC) which involved a novel binarization method for gradient sparsification and was able to achieve up to 37208 times reduction in bits with only 1\% reduction in model accuracy. Furthermore, Cui \textit{et al.}\cite{cui2020creat} used K-means clustering for selectively uploading only a small fraction of gradients considering the fact that only few gradients are distant from `zero' value. The authors quantized these selected gradients and verified them using blockchain based method to ensure no forged gradients are uploaded to the PS. Tang \textit{et al.}\cite{tang2019doublesqueeze} proposed DoubleSqueeze, a bidirectional (from the clients to the PS and vice-versa) compression technique for distributed learning in an IID setting. The approach consists of transmitting a gradient compression coupled with error compensation for both uplink and downlink channels. Artemis\cite{philippenko2020bidirectional}, a theoretical framework for bidirectional compression was proposed by Philippenko \textit{et al.} in order to be robust under Non-IID data and partial client participation. Abrahamyan \textit{et al.}\cite{9451554} designed an autoencoder with a lightweight architecture which captures the common patterns in the gradients of the different distributed clients and achieved a 8095 times compression which is 8 times more than DGC. Entropy based gradient compression scheme was proposed by Kuang \textit{et al.}\cite{kuang2019entropy} which consisted of an entropy based threshold selection method and a learning rate correction algorithm. Entropy is a well known metric from information theory which here measures the uncertainty or disorder of the gradients. Generally, the entropy of a layer's gradient is low if the gradient includes lesser information. Using the obtained entropy information and QuickSelect algorithm, the threshold is calculated and only those gradients with absolute value above the threshold are transmitted in that communication round. The results in \cite{kuang2019entropy} showed that up to 1000 times gradient compression is achievable while keeping the accuracy of the model nearly unchanged. Fast FL was proposed by Nori \textit{et al.}\cite{nori2021fast} which attempts to jointly consider the local weight updates and gradient compression tradeoff in FL. They formulate their problem as an optimization objective of minimizing learning rate error under the constraints of computation and communication interdependency in FL. \subsection{Reducing communication rounds} It is well-understood that reduction in the number of communication rounds results in improving communication-efficiency. In the literature, several attempts have been made to make the FL communication efficient. Luping \textit{et al.} \cite{luping2019cmfl} presented Communication Mitigated FL (CMFL) that identifies the importance of each communication round and prevents the less important model updates to be transferred over the uplink while having a guaranteed convergence. CMFL uses the most recent global model and compares it with the present local model update. If the number of same sign parameters is high, then intuitively it ensures that the communication round is of high relevance and is not an outlier with respect to the global updates. Jiang \textit{et al.}\cite{jiang2020adaptive} presented Adaptive periodic averaging in which they showed that by communicating more in the earlier rounds of FL and gradually reducing the number of communication rounds at the later stages of the training gives a much better convergence due to the fact that variance of model parameters is larger during the initial rounds and becomes much lower during the later stages. Furthermore, Yao \textit{et al.}\cite{yao2018two} designed a method termed two-stream FL where they introduced maximum mean discrepancy (MMD) loss in order to reduce the number of communication rounds of FL. This novel MMD loss function measures the distance between the outputs of the received global model and trained local model in order to force the local model to gather more knowledge from the local data available for faster convergence, thus resulting in lesser number of communication rounds. Feature fusion FL was developed recently\cite{8803001} in which features from global and local models were aggregated in order to achieve reduction in number of communication rounds by 60\% while maintaining equivalent accuracy. In this approach, a local image serves as input to the local feature extractor as well as a global feature extractor, and a fusion operator translates those extracted global and local features into a fusion feature space and each feature fusion module is sent to the PS for global aggregation. \subsection{Asynchronous updates} In the classical FL setting as introduced in \cite{mcmahan2017communication}, the communication type is synchronous where the global model is sent to all clients and then the training process starts, which leads to a large communication delay due to massive number of participating devices. All devices are not capable enough at all times to support federated training due to factors such as power discharge or network failure. Hence, a training process of the FL can stall that may ultimately lead to poor communication efficiency. Therefore, development of FL communication rounds in an asynchronous way is of utmost importance. Recently, some progress has been made in literature on asynchronous FL. A Semi-Asynchronous Federated Averaging (SAFA)\cite{wu2020safa} protocol was developed in which prior to every local training round, the PS classifies all available clients into three categories: (i) Up-to-date clients who have completed previous training rounds successfully, (ii) Deprecated clients who have outdated models in comparison with the latest global model, and (iii) Tolerable clients whose local model version is outdated but not too old. SAFA only allows up-to-date and deprecated clients to synchronize with the PS while tolerable clients are trained in an asynchronous manner. Here, deprecated clients are forced to synchronize in order to make sure that their outdated local updates do not poison and affect the latest global model. Chen \textit{et al.}\cite{chen2019communication} designed an asynchronous FL technique in which layers of the neural networks are classified into deep and shallow layers. In this proposed protocol, more often, the local updates constitute weights from the shallow layers as compared to the deeper layers because the deeper ones learn dataset specific characteristics whereas shallow ones learn generalized patterns. The authors also used a temporally weighted aggregation approach where the recent updates are considered of more importance and thus assigned higher weights. \section{Wireless communications for Federated learning}\label{sec4} As aforementioned discussion and illustration given in Figure 1, wireless communication is critical for FL, however it poses a difficulty for model training since channel randomness skews each client's model update, and numerous client updates cause severe interference due to restricted bandwidth. In this section, we discuss techniques of wireless communications that can be designed to improve performance of the FL. \subsection{Client selection and scheduling} As discussed in previous section that the standard FL\cite{mcmahan2017communication} training process can become highly inefficient when resource constraints of real-world wireless networks are taken into account. Edge devices have limited and varying compute resources and are connected to wireless networks with dynamically changing conditions due to fading and/or shadowing. Under such limitations, using all devices for FL is not reasonable and thus to tackle this issue, client selection methodologies have been proposed by several researchers. In \cite{nishio2019client}, a new FL protocol is proposed, termed as `FedCS' that uses a two step client selection procedure by requesting the clients their edge device's resource information in real-time and a subsequent client selection step based on the received information. The client selection step has been framed as a multi-objective maximization problem for accepting as many relevant client updates as possible. This maximization problem is solved by a Heuristic greedy algorithm. Furthermore, `FedMCCS' is proposed in \cite{abdulrahman2020fedmccs} that works as a multi-criteria based client selection procedure in order to predict if a client is capable of participating in the federated training, taking into account the client device's resource information such as CPU, free memory, time and energy. The authors show experimentally that FedMCCS is able to reduce the number of communication rounds, maximize the number of clients, optimizes the network traffic as tries to minimize the number of discarded rounds. Among the large number of client edge devices participating in FL, there is a high possibility of unreliable updates be it intentionally for poisoning attacks or unintentionally due to resource constraints. Keeping this in mind, Kang \textit{et al.}\cite{kang2020reliable} discussed the idea of selecting clients based upon a new metric termed as reputation using a consortium blockchain based scheme. After broadcasting the global model, the PS receives the identity and resource information from the clients and calculates the reputation metric. These reputation values are fetched either from the historical logs of client participation from the PS, or from an open access consortium blockchain of multiple PSs. These values depend on interaction frequency, timelines and effects of each client. Moreover, three standard scheduling algorithms (Round-robin, proportional fair and random scheduling) were compared for efficiency in terms of client scheduling for FL in a study by Yang \textit{et al.}\cite{yang2019scheduling}. In this work, convergence of FL is considered in a large-scale wireless setting with practical network limitations such as interference. More specifically, in random scheduling (RS), the PS selects a subset of clients at random in each update transmission round. In round-robin scheduling (RR), the PS clusters all the available clients into groups in each communication round and assigns them to utilize the radio channels to communicate their respective updates. In proportional-fair scheduling (PF), the PS selects a subset of clients using a policy that ranks them based on signal-to-noise ratio (SINR) values. It is demonstrated through numerical and experimental simulations that PF scheduling outperforms the other two in terms of iteration time when the SINR is high, whereas RS performs best under low SINR conditions. Age-based scheduling algorithms have also been investigated \cite{yang2020age,buyukates2020timely} which select and transmit only those client updates which are less stale (i.e, more recent). All the above discussed client selection and scheduling methods have been summarized in Table \ref{tab:3}. \begin{table*}[t] \caption{Client selection and scheduling algorithms in literature} \label{tab:3} \centering \begin{tabular}{| m{3cm} | m{5cm} | m{4cm} | m{4cm} |} \hline \textbf{Paper(s)} & \textbf{System model} & \textbf{Metric} & \textbf{Results / Objective}\\ \hline FedCS\cite{nishio2019client} & \begin{itemize} \item Channel information \item Non IID data \item Resource constraints \end{itemize}& \begin{itemize} \item Accuracy \item Elapsed time \item Number of clients \end{itemize}& \begin{itemize} \item Client maximization \item Time minimization \end{itemize} \\ \hline FedMCCS\cite{abdulrahman2020fedmccs} & \begin{itemize} \item Location based sampling \item Non IID data \item Device information \item Resource constraints \end{itemize}& \begin{itemize} \item Resource utilization \item Accuracy \item Number of clients \item Elapsed time \end{itemize}& \begin{itemize} \item Client maximization \item Number of rounds minimization \item Discarded round minimization \item Network traffic optimization \end{itemize} \\ \hline Kang \textit{et al.}\cite{kang2020reliable} & \begin{itemize} \item Client reliability \item Poisoning attacks \item Real-time client monitoring \end{itemize}& \begin{itemize} \item Reputation \end{itemize}& \begin{itemize} \item Secure FL \item Client maximization \end{itemize} \\ \hline Yang \textit{et al.}\cite{yang2019scheduling} & \begin{itemize} \item RS, RR and PF scheduling \item Channel information \item Resource constraints \end{itemize}& \begin{itemize} \item Number of rounds minimization \item Elapsed time \item Accuracy \end{itemize}& \begin{itemize} \item Comparative study \end{itemize} \\ \hline Yang \textit{et al.}\cite{yang2020age} Buyukates \textit{et al.}\cite{buyukates2020timely} & \begin{itemize} \item Staleness \item Channel information \item Power constraint \end{itemize}& \begin{itemize} \item Age of update \end{itemize}& \begin{itemize} \item Low complexity \item Client maximization \end{itemize} \\ \hline \end{tabular} \end{table*} \begin{figure*}[!t] \centering \includegraphics[width=0.7\textwidth]{aircomp} \caption{AirComp based FL mechanism} \label{fig:6} \end{figure*} \subsection{AirComp} \label{aircomp} A wireless channel has several hidden properties that are not fully explored in the existing literature. Nevertheless, these properties can be leveraged to make edge machine learning much more communication efficient. Distributed computation over multi-access wireless channels has been explored in wireless communications\cite{nazer2007computation, goldenbaum2013harnessing}. It is based on utilizing the phenomena of analogue signal superposition across wireless channels for computing nomographic functions over the air (AirComp), as illustrated in Figure \ref{fig:6}. Keeping in mind the fact that the model/gradient aggregation operation is a nomographic function\cite{hua2019device}, this AirComp idea has been investigated in literature for use in the gradient aggregation phase of FL. Analog gradient aggregation schemes provide a huge improvement in terms of communication latency compared to standard orthogonal frequency division multiple access (OFDMA) based schemes\cite{zhu2019broadband}. \begin{table*}[!htbp] \caption{FL with AirComp methods in literature} \centering \begin{tabular}{| m{3cm} | m{5cm} | m{4cm} | m{4cm} |} \hline \textbf{Paper(s)} & \textbf{System model} & \textbf{Metric} & \textbf{Results / Objective}\\ \hline Zhu \textit{et al.}\cite{zhu2019broadband} & \begin{itemize} \item Channel Noise and fading \item Large number of clients \item OFDM modulation \item Amplitude alignment \end{itemize}& \begin{itemize} \item Recieve SNR \item Truncation ratio \item Latency reduction ratio \item Reliability ratio \end{itemize}& \begin{itemize} \item Convergence gurantee \item Latency minimization \item Path loss minimization \end{itemize} \\ \hline COTAF\cite{sery2020cotaf} & \begin{itemize} \item Noisy channels \item Pre-coding and scaling \end{itemize}& \begin{itemize} \item Convergence rate \item Model loss \end{itemize}& \begin{itemize} \item Convergence gurantee \item Channel noise mitigation \end{itemize} \\ \hline Amiri \textit{et al.}\cite{amiri2020machine} & \begin{itemize} \item Power allocation \item Error monitoring \item Non IID data \item Resource constraints \item Gradient sparsification \end{itemize}& \begin{itemize} \item Accuracy \end{itemize}& \begin{itemize} \item Bandwidth efficient \item Latency minimization \end{itemize} \\ \hline Yang \textit{et al.}\cite{yang2020federated} & \begin{itemize} \item Ideal channel assumption \item Non IID data \item Resource constraints \end{itemize}& \begin{itemize} \item Feasibility \item Accuracy \item Number of clients \end{itemize}& \begin{itemize} \item Client maximization \item Feasibility maximization \end{itemize} \\ \hline Vu \textit{et al.} \cite{vu2020cell} & \begin{itemize} \item Cell-free MIMO \item Joint resource, accuracy and training time optimization \end{itemize}& \begin{itemize} \item Training time \item Accuracy \item Data rate \end{itemize}& \begin{itemize} \item Training time minimization \end{itemize} \\ \hline Wang \textit{et al.}\cite{wang2021federated} & \begin{itemize} \item IRS assisted AirComp \item Two-step low rank optimization \end{itemize}& \begin{itemize} \item Client frequency \item Mean Squared error \end{itemize}& \begin{itemize} \item Client maximization \item Faster convergence \end{itemize} \\ \hline Yu \textit{et al.} \cite{yu2020optimizing} & \begin{itemize} \item IRS assisted AirComp \item Large-scale C-RAN \item Joint optimization of reflection phase and linear detection vector \end{itemize}& \begin{itemize} \item Mean squared error \end{itemize}& \begin{itemize} \item MSE minimization \end{itemize} \\ \hline \end{tabular} \label{tab:4} \end{table*} Convergent over-the-air FL (COTAF) algorithm is proposed in \cite{sery2020cotaf} and is shown to converge successfully even over the shared noisy wireless channels. COTAF employs temporal precoding and scaling methods to reduce the impact of channel noise while transmitting local updates to the PS over the uplink channels. Amiri \textit{et al.}\cite{amiri2020machine} presented Analog distributed stochastic gradient descent (ADSGD) which sparsifies local model gradients and encodes them to a low dimensional space to be efficient for over-the-air computation under limited bandwidth of the wireless channel. They formulate DSGD as a distributed wireless computation problem for addressing power and bandwidth constraints while considering both physical layer properties as well as the model's convergence. The authors showed that without loss in performance, ADGSD is much more bandwidth efficient as compared to the other digital schemes. Moreover, Broadband Analog Aggregation (BAA) framework was introduced by Zhu \textit{et al.}\cite{zhu2019broadband} which utilized the air computation principle over broadband multi-access wireless channels. BAA was designed with an aim to reduce communication latency. BAA considers the scenario of a single cell network where each device transmits a large local model update over a broadband channel in blocks by linear modulation. Furthermore, in order to deal with fading and interference, BAA also utilizes orthogonal frequency division multiplexing (OFDM) to split the channel into sub-channels. In order to make sure identical amplitudes of local model updates are transmitted, BAA uses a broadband channel inversion mechanism for reliable analog transmission. A joint beamforming and client selection optimization approach was used by Yang \textit{et al.}\cite{yang2020federated} to maximize the number of client devices satisfying the thresholds of satisfactory performance in AirComp based FL training. The corresponding non-convex combinatorial optimization problem is transformed into a sparse and low rank problem using a sparse representation for the objective function and matrix lifting technique. A difference of convex functions based algorithm was proposed by the authors which proved to be better than conventional approaches. However, an important aspect often overlooked by the above methods is that gradient statistics differ across training iterations and feature dimensions and are unknown in advance. Zhang \textit{et al.} \cite{zhang2021gradient} investigated the power control problem for over-the-air FL by taking into consideration the effects of gradient statistics. Their goal was to reduce aggregation error by maximizing transmit power at each device while keeping average power limits in mind. When we have gradient statistics, we can find the optimal policy in closed form. Notably, they demonstrate that the optimal transmit power is continuous and decreases monotonically with the squared multivariate coefficient of variation of gradient vectors. Cell-free massive MIMO is a novel architecture for multi-user MIMO that is recently proposed\cite{zhang2019cell}. When using cell-free massive MIMO, base stations are deployed to serve users in a cooperative manner using the same time and frequency resources. The backhaul network connects all access points making it possible to synchronize conjugate beamforming in downlink and matching filtering in uplink. The primary benefit of using a cell-free design is to provide coverage to the large area because of the large number of base stations. To support any FL architecture, Vu \textit{et al.} \cite{vu2020cell} presented a new approach for cell-free massive MIMO networks. This plan enables for each iteration of the FL framework to occur in a large-scale coherence time to provide a stable FL process. IRS is a planar surface made up of low-cost, passive reflecting elements each of which can give rise to an amplitude or phase change to the incident signal and collectively these changes result in 3-D reflect beamforming\cite{wu2019towards}. IRS helps to mitigate the effect of wireless channel fading which in turn makes the network energy efficient and improves the signal strength. In a study\cite{waqarperformance}, it was demonstrated that an IRS-assisted communication system outperforms other baseline systems even with a small number of discrete phase shifts. IRS is capable of solving the problem of AirComp systems suffering a lot from challenging signal propagation conditions\cite{jiang2019over}. AirComp has been proven to be a promising method for enhancing FL performance under tough constraints of real-world wireless communication systems and improving AirComp with IRS would result in much more increase in FL performance. Wang \textit{et al.}\cite{wang2021federated} showed IRS based AirComp-FL was able to achieve a much lower training loss and higher prediction accuracy than conventional baseline methods. Their method's objective was to simultaneously optimize device selection, IRS's phase shifts and the aggregation beamformer so as to cancel out the higher model aggregation errors when the number of client devices are maximized and the optimization problem was solved using a difference of convex (DC) algorithm. Furthermore, Yu \textit{et al.} \cite{yu2020optimizing} discussed the benefits of IRS assisted AirComp in a cloud radio access network. The system model of \cite{yu2020optimizing} consisted of distributed access points (APs) to which the local model updates were sent and each AP forwarded the received update signals to the PS through the finite capacity fronthaul link. The authors designed an iterative algorithm for optimizing the reflecting phases of the IRS along with linear detection vector of the global PS. The aforementioned AirComp techniques for the FL have been summarized in Table. \ref{tab:3}. \vspace{10 pt} \subsection{Efficient resource management} Client devices have many resource constraints, among which battery depletion is one of the most fundamental challenges for the success of FL. This opens a research problem of energy optimization for FL which has been discussed by a few research articles. Zhan \textit{et al.}\cite{zhan2020experience} formulated it as optimization of the weighted sum of the energy consumed and the time taken for each round of local training. Even IID local datasets of approximately same size can take different amounts of time for the local training due to varying amount of processing power and network quality available at each client. In a synchronous FL setup, the devices which take lesser time to update would have an unnecessary idle time to communicate the update. To solve the joint optimization problem, the authors used an actor-critic based deep reinforcement learning (DRL) algorithm instead of the conventional heuristic algorithms due to the unpredictable and highly dynamic conditions of the real-world wireless networks. The DRL agent selects an action using the learnt policy based upon the present states where state space includes a set of historical bandwidth information. The reward function resembles negative of the system cost so as to guide the DRL agent towards minimizing the system cost. The experimental results show a 40\% reduction in the system cost compared to previous state-of-the-art approaches. Furthermore, a novel resource allocation framework termed `resource rationing' was introduced by Shen \textit{et al.}\cite{shen2021resource} in which it was highlighted that each learning round has a different importance level towards the final performance of the system due to the fact that factors like bandwidth, number of clients and energy limits are unique in each client device. Resource rationing is built upon the ``later-is-better" principle indicating that there is a significant performance boost if resources are reserved at the early stages of training and then utilized as much as possible in the later rounds. Most of the works in literature have considered a system model assuming only one FL service, but once FL systems start getting deployed at scale, there would be multiple simultaneous FL services co-existing within the same wireless network. Allocating resources in this multi-service FL scenario is a tough challenge due to sharing of the same spectrum among those services. In a study\cite{xu2021bandwidth}, it has been highlighted that multi-service FL's efficiency depends upon both intra-service and inter-service spectrum allocation. Intra-service refers to the general client-level resource allocation which we had been discussing prior to this. Inter-service refers to the wireless spectrum allocation among multiple active FL services where there can be two scenarios. Under the first scenario, the FL service providers are assumed to be cooperative and the wireless network operator fairly distributes the bandwidth which in turn resembles the same optimization problem as of the intra-service case with the FL service providers acting as users and has been solved using a distributed algorithm designed by the authors. The second scenario considers selfish FL service providers who misreport their resource constraints and workload to get a higher share of the spectrum to boost its own performance, which may lead to performance degradation among the other FL services sharing the spectrum. To solve this issue, the authors designed a multi-bidding auction mechanism and experimental results show that their algorithm's performance exceeds previous benchmarks. The summary of the aforementioned efficient resource management techniques for the FL is given in Table. \ref{tab:4}. \begin{table*}[t] \caption{Resource management techniques in literature} \centering \begin{tabular}{| m{2cm} | m{5cm} | m{5cm} | m{4cm} |} \hline \textbf{Paper(s)} & \textbf{System model} & \textbf{Metric} & \textbf{Results / Objective}\\ \hline Zhan \textit{et al.}\cite{zhan2020experience} & \begin{itemize} \item Dynamic network environment \item Client-side resource management \item Synchronous FL \end{itemize}& \begin{itemize} \item Average computational energy \item Average training time \item Client CPU-cycle frequency \item Average system cost \end{itemize}& \begin{itemize} \item Energy efficiency \item Faster convergence \end{itemize} \\ \hline Shen \textit{et al.}\cite{shen2021resource} & \begin{itemize} \item "Later is better" principle \item Generalized system model \end{itemize}& \begin{itemize} \item Bandwidth \item Client frequency \item Accuracy \end{itemize}& \begin{itemize} \item Client maximization \end{itemize} \\ \hline Xu \textit{et al.}\cite{xu2021bandwidth} & \begin{itemize} \item Multi-service FL scenario \item Two-level allocation \item Selfish service providers \item Multi-bid auction \end{itemize}& \begin{itemize} \item Training time \item Bandwidth ratio \item FL frequency \end{itemize}& \begin{itemize} \item Number of rounds minimization \item Fair bandwidth allocation \end{itemize} \\ \hline \end{tabular} \label{tab:5} \end{table*} \section{Federated learning for Wireless communications}\label{sec5} In this section, we will discuss the major applications of FL for improving the future wireless communication networks. \subsection{Channel estimation} Channel estimation plays a critical role in optimizing link performance in wireless communication systems. With the advent of mmWave in 6G, acquiring the channel state information becomes a challenging problem due to massive number of antennas, high bandwidth and complex design of transceiver \cite{hassan2020channel}. In the earlier generation of wireless communication systems, channels are estimated through machine learning based shallow algorithms by formulating a regression problem received pilot signals as the input data and the channel state information (CSI) as the output data. In addition to this, support vector machine (SVM) algorithms have been used widely in literature for channel estimation\cite{sanchez2004svm, charrada2012complex, 5159013, garcia2006support, 9148630} due to their ability to handle non-linear relationships between input and output data. Due to the increased complexity and non-linearity in current 5G and future 6G wireless communication channels, deep learning evolved as a potential solution for channel estimation. Most of the proposed deep learning models for channel estimation use centralized architectures, which can generate a huge overhead on the network, thus creating the need for decentralized learning. Elbir \textit{et al.}\cite{elbir2020federated} showed that models trained with FL for channel estimation have 16 times lesser network overhead as compared to the models trained with centralized learning. The authors trained a convolutional neural network (CNN) based model for estimating the channel matrix in both standard and IRS assisted MIMO settings. \subsection{Symbol detection} Symbol detection refers to the mapping of symbols received through a wireless channel to decoded clean symbols. Centralized learning based symbol detection has been explored widely in literature due to its efficiency in end-to-end learning and detecting symbols without the need of channel information which is otherwise required in conventional algorithmic approaches. However, centralized learning suffers from high network overload due to the huge size of the received symbol data. FedRec, a downlink fading symbol detector, based on decentralized data was proposed by Mashhadi \textit{et al.} \cite{mashhadi2020fedrec}. It consists of neural networks under a fading channel system based on the maximum a posteriori probability (MAP) rule. It utilizes as a collaborative training technique that utilises channel diversity among several users through FL. \subsection{Vehicular networks} In complex Quality of Service (QoS) real-world settings, emerging vehicular networks incorporate a huge volume of vehicle sensor data and applications. Till date, such systems only considered centralized learning which is not a scalable and efficient solution due to privacy and network overload concerns in resource constrained vehicular networks\cite{du2020federated}. FL is ideal for these requirements as it can efficiently utilize decentralized data and compute from different vehicles in a privacy preserving manner. Hence, Mashhadi \textit{et al.}\cite{mashhadi2021federated} presented an FL based beam selection scheme that utilizes on-vehicle Light Detection and Ranging (LIDAR) data. It was shown that the proposed scheme outperforms the previous state-of-the-art approaches in terms of classification accuracy and subsequently reduces floating point operations by a factor of 100. Moreover, Qi \textit{et al.}\cite{qi2020federated} used an asynchronous FL based transfer learning approach for pro-active handover in mmWave vehicular networks with varying mobility patterns. Their results show a reduction in uplink communication overhead and improvement in user's QoS. FedVCP is an FL based framework designed by Kong \textit{et al.}\cite{kong2021fedvcp} for privacy-aware cooperative positioning in vehicular networks which was also demonstrated to outperform previous schemes. Furthermore, Saputra \textit{et al.}\cite{saputra2019energy} implemented an FL based energy demand estimation method in a network of electric vehicles. A selective FL aggregation scheme for vehicular networks was presented by Ye \textit{et al.}\cite{ye2020federated} where only those local models are chosen for global aggregation which have high quality images and sufficient compute power. \subsection{Network slicing} Personalized network as a service has been considered as one of the main motivations for development of 5G networks. In heterogeneous networks, the aim of radio access network (RAN) slicing is to deliver tailored personalized services for mobile users with varying QoS needs. As a result, the most important aspect of RAN slicing is determining how to efficiently distribute network resources while still satisfying user QoS requirements. In the existing literature, there have been some works on application specific network slicing using deep learning \cite{du2018deep, 9348019, thantharate2019deepslice}. In application oriented slicing, the incoming traffic is analyzed at the packet level and each packet is classified into labels based upon the application using a neural network that was trained to learn the non-linear mapping between input and output data. Here input data consists of packet properties and sender device information, whereas output data depends on the application type. Based upon the classified packets, the network resources are distributed so as to satisfy the respective applications. Next generation wireless networks tend to have extremely dynamic usage patterns which are very tough to capture by supervised learning based resource allocation models. Deep reinforcement learning (DRL) has been known for its capability to make sequential decisions under dynamic constraints and thus has been considered in many works on network slicing \cite{li2018deep, qi2019deep, koo2019deep, shome2021deep}. Most of the above discussed methods require private data and computation intensive models which can be of serious concern when deployed in the real-world. As per 3rd Generation Partnership Project (3GPP) guidelines, network slices are required to be isolated from each other, which is not possible with the above discussed centralized learning schemes. These issues have been addressed in literature by designing FL based network slicing strategies. For instance, Brik \textit{et al.}\cite{brik2020predicting} used FL to train a model that predicts key performance indicators (KPIs) of all the isolated running network slices in a distributed manner ensuring privacy among the slices. Their model was able to achieve equivalent performance in terms of mean squared error metric while consuming significantly lesser amount of network overhead. \subsection{Computation offloading at the Edge} Offloading and caching computations at the wireless edge is a potential approach for reducing network traffic and backhaul burden while performing big data deliveries across the network. It has been shown that the same popular content is requested from the content delivery network multiple times by different users, and these duplicated requests result in unnecessary network latency. As discussed earlier, the Quality of Experience (QoE) in future wireless networks will be a complex metric jointly quantified by latency, bandwidth utilization, throughput and other KPIs. Edge computation offloading can provide a significant boost to the overall QoE by optimizing all the KPIs due to much lower network load. A few works considered machine learning based content caching schemes using K-nearest neighbours\cite{8170936}, kernel ridge regression\cite{8711328}, bayesian learning\cite{8510864}, Collaborative filtering\cite{8951133}, but these traditional machine learning approaches fail to capture the real-time dynamics of content popularity at different locations and preferences among different users. However, in a study\cite{mohammed2021performance}, it was shown that a neural network outperforms traditional machine learning approaches for edge caching whenever the number of input features is high and communication range and file sizes are large. This shows that deep learning is a key enabler for wireless content caching and thus there has been a lot of work in literature on using deep learning for edge caching which proved to have better performance than conventional baselines\cite{8624176, 8576500, rahman2020deep, bhandari2021deep}. Reinforcement learning has also been used widely for edge content offloading due to its real-time decision making capabilities and directly being able to take actions to control the network\cite{8629363} and it has shown good results in performing personalized content caching based on user's preferences\cite{8737456}. For real-world deployment, the above mentioned methods may not be feasible due to the requirement for user's personal private data in traditional centralized learning architectures. Thus, intelligent wireless content caching models implemented with FL seems to be the best possible approach due to the privacy-preserved nature of the FL. To this end, Chilukuri \textit{et al.} presented FedCache\cite{chilukuri2020achieving}, an FL based edge caching methodology that dynamically allocates the net available cache resource per edge node while ensuring a high cache hit ratio. Their system model assumes each edge node is able to divide its available cache space among all the different classes of data flowing in the network. They consider the real-time state of each class of data as a tuple with average inflow and outflow rates. During the initial phase, they collect data at the edge nodes with input features as state per data class and cache hit ratio as the output which needs to be predicted in real-time. Then, a synchronous FL phase starts at the node and the local models learn to predict the cache hit ratio based upon allocated cache space and network state. These local model's parameters are transmitted to the central PS where the global model learns from these aggregated parameters. The trained global model makes decision at the edge node of how much cache space to allocate for optimal wireless caching at that moment of time. These two phases keep on repeating at specific time intervals leading to a lifelong learning strategy which is able to adapt to the changing network dynamics. Experimental results show that FedCache has a better performance than chosen conventional methods such as Proportional split cache and unified cache. Furthermore, Shahidinejad \textit{et al.}\cite{shahidinejad2021context} proposed an FL based context-aware approach for intelligent content caching at the wireless edge in a multi-user mobile edge computing (MEC) system. Their framework consists of monitor, analyze, plan and execute (MAPE) phases. In the monitoring phase, all the available network, resources, media and sensor information at the edge are collected and termed as context information. During the planning phase, DRL agents are trained to learn the content offloading policy from experience replay memory. As the DRL agents need a lot of data and compute to train and they require private data, it can lead to network overload as well as privacy concerns if trained on mobile devices. To tackle these challenges, the authors used FL based distributed training strategy for the DRL agents which led to a significant amount of energy savings than centralized approaches. \subsection{Internet of Things} The broad use of smart technologies, cloud computing, and the IoT has been accelerated by recent improvements in wireless communications\cite{jiang2020federated}. IoT is an emerging paradigm with the potential to realize the goal of smart cities\cite{khan20206g}. The massive scale of data generated by billions of IoT devices globally would pave a path for deploying intelligence at the edge. The major challenge is that current generation centralized learning schemes do not guarantee user privacy, and also are not able to handle such massive data in real-time. To cope with these limitations, FL would be a promising solution due to its inherent abilities to preserve privacy and to reduce network overload. Smart digital healthcare services are one of the most key applications in modern smart cities. FL has the potential to enable precision medicine on a broad scale, leading to models that provide impartial choices, optimally represent an individual's physiology, and are sensitive to uncommon illnesses while respecting governance and privacy issues\cite{rieke2020future}. FedHealth, the first federated transfer learning framework for wearable healthcare was developed by Chen \textit{et al.}\cite{chen2020fedhealth} in an attempt to address these problems. FedHealth aggregates data via FL and then uses transfer learning to construct reasonably personalized models. In the real-world, labeled data necessary for supervised learning approaches is scarce, whereas unlabeled data is available at a massive scale. Keeping this fact in mind, Albaseer \textit{et al.} \cite{albaseer2020exploiting} proposed FedSem, an FL framework which implements a semi-supervised learning approach in order to make use of the large amounts of unlabeled data available in smart cities and train optimal models with minimum supervision. Acquiring enough data in the medical imaging area is a big difficulty as labeling medical imaging data necessitates expertise of a medical specialist. Collaboration across institutions might address this difficulty, however transferring medical data to a centralized server raises a number of legal, privacy, technological, and data-ownership issues, particularly among multinational organisations. To this end, Sheller \textit{et al.} \cite{sheller2018multi} provided the first use of FL for multi-institutional collaboration, enabling deep learning modelling without exchanging patient data to train efficient brain tumor segmentation models. Similarly, Liu \textit{et al.} \cite{liu2021federated} presented an FL framework for collaboratively learning power consumption patterns in distributed smart grids in a privacy-preserving manner. Moreover, Ta{\"\i}k \textit{et al.} \cite{taik2020electrical} used Edge FL for household electrical load forecasting. \section{Open problems and Future directions}\label{sec6} \subsection{Hierarchical FL} Hierarchical FL\cite{abad2020hierarchical} (HFL) is a framework that implements Edge FL across heterogeneous wireless networks with a novel three-level hierarchy which constitutes client devices, small base stations (SBS) and macro-cell base stations (MBS). For each SBS, a set of client devices are selected and the models are trained on each of these clients using FedSGD algorithm and then the parameter updates are sent to the respective SBS. The MBS and SBS communicate at periodic intervals so as to maintain a central model. Experimental results verified that HFL achieves better performance in terms of latency and accuracy than conventional FL. This concept can be generalized into multi-level hierarchy based FL and the architecture of the system can be designed based on particular use-case. The major benefit from HFL is due to much lesser computational overload on each of the distributed SBSs compared to only one MBS present in traditional FL. Most privacy enhancing methodologies have a high time complexity as well as computational/network overload. This reduced overload due to HFL opens room for improving privacy by utilizing these methodologies\cite{wainakh2020enhancing}. Moreover, traditional FL relies on a single PS which may lead to an entire FL system crash under emergency situations/attacks. HFL helps to overcome the limitation due to the presence of multiple aggregation servers instead of one. \subsection{Decentralized FL} Traditional FL schemes involve a central PS where the aggregation of local model weights takes place. Unfortunately, the PS may be the victim of malicious attacks or system failures which may lead to a major downfall in FL performance and in the worst case, the entire distributed training can come to a halt. Also, the client devices and the centralized server need to transmit model updates between each other through wireless links multiple times, which leads to a large network overhead when a huge set of client devices participate in FL training. Taking these facts into account, Khan \textit{et al.} \cite{khan2020dispersed} presented a framework termed 'Dispersed FL' which trains a global FL model in a fully decentralized manner and compared it with hierarchical FL. The authors mentioned that this fully decentralized approach has some serious issues such as increase in latency and extra bandwidth requirements for transmitting local and global models during the training phase among the distributed nodes. Chen \textit{et al.}\cite{chen2020wireless} proposed Collaborative FL (CFL) framework which is a hybrid approach where a set of client devices may be connected to the central PS whereas other client devices connect with nearby devices to transmit parameters after each local training step. Considering the fact that mobility of distributed devices / nodes has not been taken into account in any of the existing works, as a future work, researchers can investigate the impact of mobility on the performance of FL. \subsection{Federated personalization} Local datasets on client devices have different varying features correlated with the personal preferences and characteristics of the user. For example, in the case of computational offloading, different users would have different usage patterns and it would be very beneficial to use those patterns such as app-wise screen time, choices of photos and search queries etc., as input features to the local models as these can make the models much more efficient in understanding what the user actually wants. When those local gradients would be aggregated into the global model, the global model would learn what all the participating users personally prefer. In Hierarchical FL, this kind of personalization can be more useful in cases where geographically nearer users would have certain features which are local to them and do not benefit users from other areas. For instance. in case of offloading video content, preferences are correlated with locations. Thus, as a future research direction, we recommend searching for local data which can be used as input for capturing personal features for FL. \subsection{Security} In spite of the fact that, a privacy-preserving feature is immanent in FL process, it can still be vulnerable to numerous security threats and privacy issues mainly due to involvement of many clients. There are relatively few articles in the literature that identify dangers of the vulnerabilities and propose methodologies for mitigating those dangers \cite{mothukuri2021survey}. For the iterative learning process of FL to achieve higher accuracy, the PS has to communicate extensively with a large number of clients. However, the probability of having insecure communication links also increases with increasing the number of clients, thus an accuracy-privacy tradeoff may exist, and we suggest investigating this important tradeoff in future works. Poisoning is a major category of attacks that use malicious data in the training phase, or adversely update the model parameters in order to significantly degrade performance of the FL learning model. Additionally, Generative Adversarial Networks (GANs) have the power to launch attacks against any machine learning model, including the FL model. It is shown in \cite{hitaj2017deep} that these GAN based attacks have high severity because such attacks have an ability to steal information of any client by generating prototypical samples of the targeted training dataset. There have been some efforts in literature to tackle such security challenges. Differential Privacy based perturbation approaches \cite{dwork2006calibrating} conceal certain sensitive attributes, thereby making the data impossible to restore, consequently safeguarding user privacy. Secure multi-party computation (SMC) is another popular technique that employs a four-round interactive protocol that can be enabled during the reporting phase of a given FL communication round \cite{zhu2020relationship}. After receiving messages from each device in a protocol round, the server returns an individual answer to each device. The third cycle is referred to as the "commit phase" in which devices send encrypted model updates to the server. There is a final stage where devices give enough cryptographic secrets so that the server may unmask the aggregated model update. Another popular technique is Homomorphic encryption (HE) \cite{aono2017privacy} which is a key-based security method. HE enables computations on encrypted data. By leveraging HE in the context of FL, first the participating clients create public and private keys, which are used to encrypt locally learned models. This is followed by a secure server-side aggregate of all model updates received from clients. The global model changes are decrypted by the clients using the private keys. It is quite evident that the increased security is provided by using HE, however, the computational complexity of the cryptographic operations adds additional overhead on the resource-constrained clients, in terms of cost, time and power consumption. Moreover, these encrypted models are significantly larger, thus also scaling up the overall communication overhead. Hence, one of the important future research directions is to develop robust security enhanced frameworks for FL with a focus on reduction in computational and communication overheads. In traditional communications, cryptographic operations are completely avoided by invoking approaches that are based on the principles of the physical layer security (PLS) \cite{Waqar_TVT}. As PLS may serve an alternative to cryptographic security techniques even for the FL, PLS based approaches should be worthy enough to be considered in future for the FL. \section{Conclusion} An ever-growing demand for data hungry applications on a wireless network along with the phenomenal success of Deep Learning in various fields has resulted in a natural integration of the two technologies, namely, deep learning and wireless communications. However, the rising concern of private data leakage in conjunction with the high latency associated with uploading the entire raw data to a central cloud, makes the centralized deep learning techniques unattractive. To this end, recently, FL has been proposed and owing to its privacy-preserving and communication efficient features, it has become a natural choice for the next generation communication systems. However, there exists an interdependency between the two technologies as performance of the FL strongly depends on conditions of the wireless channels. Therefore, the aim of this survey is to excavate this bidirectional relationship between FL and wireless communications in a holistic manner. As a result, we provide a comprehensive survey of the techniques that have been proposed in state-of-the-art literature for the communication efficient FL, wireless communications for FL and FL for wireless communications. Moreover, this is the first survey article that discusses the role of the smart radio environments for the performance improvement of the FL. Lastly, we also discuss the open problems for the FL and provide future directions which will be helpful for those researchers working in the intersection of the two emerging paradigms i.e., FL and next generation wireless communications. \bibliographystyle{IEEEtran}