\section{Introduction}

A dimer cover, or perfect matching on a graph is a subset of edges such that each vertex is incident to exactly one edge in the subset. The dimer model is a probability measure on the set of perfect matchings (See \cite{RK09}).
The dimer model is a natural mathematical model for the structures of matter; for example, each perfect matching on a hexagonal lattice corresponds to a double-bond configuration of a graphite molecule; the dimer model on a Fisher graph has a measure-preserving correspondence with the 2D Ising model (see \cite{Fi66,MW73,ZL12}).


Just as in the structure of matter different molecule configurations have certain probabilities to occur depending on the underlying energy, mathematically we define a probability measure on the set of all perfect matchings of a graph depending on the energy of the dimer configuration, quantified as the product of weights of present edges in the configuration.
The asymptotical behavior and phase transition of the dimer model has been an interesting topic for mathematicians and physicists for a long time. A combinatorial argument shows that the total number of perfect matchings on any finite planar graph can be computed by the Pfaffian of the corresponding weighted adjacency matrix (\cite{Kas61,TF61}). The local statistics can be computed by the inverse of the weighted adjacency matrix (\cite{Ken01}); a complete picture of phase transitions was obtained in \cite{KOS}. Empirical results shows that in large graphs, there are certain regions where the the configuration is almost deterministic, i.e. one type of edges have very high probability to occur in the dimer configuration. These are called ``frozen regions", and their boundary are called ``frozen boundary".
When the mesh size of the graph goes to 0 such that the graph approximates a simply-connected region in the plane, the limit shape of height functions can be obtained by a variational principle (\cite{ckp}), and the frozen boundary is proved to be an algebraic curve of a specific type called the cloud curve (\cite{KO07}). It is also known that the fluctuations of (unrescaled) dimer heights converge to the Gaussian free field (GFF) in distribution when the boundary satisfies certain conditions (\cite{Ken01,Li13}).

 

In this paper, we investigate perfect matchings on a general class of bipartite graphs called rail-yard graph. This type of graphs were defined in \cite{bbccr}, and the formula to compute the partition function of pure dimer coverings on such graphs was also proved in \cite{bbccr}. The major goal of the paper is to study the limit shape and height fluctuations of pure dimer coverings on such graphs.
Special cases of rail-yard graphs include the Aztec diamond (\cite{EKLP92a,EKLP92b,KJ05,bk}), the pyramid partition (\cite{BY09}), the steep tiling (\cite{BCC17}), the tower graph (\cite{BF15}), the contracting square-hexagon lattice (\cite{BL17,ZL18,ZL20,Li182}) and the contracting bipartite graph (\cite{ZL202}).
Pure dimer coverings on rail-yard graphs are in one-to-one correspondence with sequences of partitions, and the probability distribution of these sequences of partitions corresponding to that of pure dimer coverings forms a generalized version of McDonald processes. The observables of Mcdonald processes have been extensively studied in \cite{bc13,bcgs13}, and applied to study the asymptotics of lozenge tilings in \cite{DE16,Ah18}. Unlike \cite{DE16,Ah18}, the Mcdonald processes used to study dimer configurations on rail-yard graph involve dual partitions as well. Such Macdonald process can also be obtained from the Macdonald processes defined in \cite{bc13,bcgs13} by a specialization,  which is a homomorphism from the algebra of symmetric polynomials to $\CC$, but not a function evaluation. As a result, we obtain the Law of Large Numbers and the Central Limit Theorem for perfect matchings on a large class of graphs, including the well-known pure steep tilings and (\cite{BCC17}) and pyramid partitions (\cite{Ken05,Sze08,BY09,you10}).

The organization of the paper is as follows. In Section \ref{sect:bk}, we define the rail-yard graph, the perfect matching and the height function, and review related technical facts. In Section \ref{sect:sc}, we discuss a class of Mcdonald processes related to the probability measure of perfect matchings on the rail-yard graphs. In \ref{sect:mh}, we compute the moments of height functions of perfect matchings on rail-yard graphs by computing the observables in the generalized Mcdonald processes. In Section \ref{sect:as}, we study the asymptotics of the moments of the random height functions and prove its Gaussian fluctuation in the scaling limit. In Section \ref{sect:fb}, we prove an integral formula for the Laplace transform of the rescaled height function (see Lemma \ref{l61}), which turns out to be deterministic, as a 2D analog of law of large numbers. We further obtain an the explicit formula for the frozen boundary in the scaling limit. In Section \ref{sect:gff}, we prove that the fluctuations of unrescaled height function converges to the pull-back Gaussian Free Field (GFF) in the upper half plane under a diffeomorphism from the liquid region to the upper half plane (see Theorem \ref{t77}). In section \ref{sect:ex}, we discuss specific examples of the rail-yard graph, such that the limit shape and height fluctuations of perfect matchings on these graphs can be obtained by the technique developed in the paper; these examplse include the pure steep tilings and pyramid partitions. In Apendixes \ref{sc:dmp} and \ref{scb}, we include some known technical results.

\section{Backgrounds}\label{sect:bk}

In this section, we define the rail-yard graph, the perfect matching and the height function, and review related technical facts.

\subsection{Weighted rail-yard graphs}

Let $l,r\in\ZZ$ such that $l\leq r$. Let
\begin{eqnarray*}
[l..r]:=[l,r]\cap\ZZ,
\end{eqnarray*}
i.e., $[l..r]$ is the set of integers between $l$ and $r$. For a positive integer $m$, we use
\begin{eqnarray*}
[m]:=\{1,2,\ldots,m\}.
\end{eqnarray*}
Consider two binary sequences indexed by integers in $[l..r]$ 
\begin{itemize}
\item the $LR$ sequence $\underline{a}=\{a_l,a_{l+1},\ldots,a_r\}\in\{L,R\}^{[l..r]}$;
\item the sign sequence $\underline{b}=(b_l,b_{l+1},\ldots,b_l)\in\{+,-\}^{[l..r]}$.
\end{itemize}
The rail-yard graph $RYG(l,r,\underline{a},\underline{b})$ with respect to integers $l$ and $r$, the $LR$ sequence $\underline{a}$ and the sign sequence $\underline{b}$, is the bipartite graph with vertex set $[2l-1..2r+1]\times \left\{\ZZ+\frac{1}{2}\right\}$. A vertex is called even (resp.\ odd) if its abscissa is an even (resp.\ odd) integer. Each even vertex $(2m,y)$, $m\in[l..r]$ is incident to 3 edges, two horizontal edges joining it to the odd vertices $(2m-1,y)$ and $(2m+1,y)$ and one diagonal edge joining it to
\begin{itemize}
\item the odd vertex $(2m-1,y+1)$ if $(a_m,b_m)=(L,+)$;
\item the odd vertex $(2m-1,y-1)$ if $(a_m,b_m)=(L,-)$;
\item the odd vertex $(2m+1,y+1)$ if $(a_m,b_m)=(R,+)$;
\item the odd vertex $(2m+1,y-1)$ if $(a_m,b_m)=(R,-)$.
\end{itemize} 

See Figure \ref{fig:rye} for an example of a rail-yard graph.
\begin{figure}
\includegraphics[width=.8\textwidth]{ryg.pdf}
\caption{A rail yard graph with LR sequence $\underline{a}=\{L,R,R,L\}$and sign sequence $\underline{b}=\{+,+,-,-\}$. Odd vertices are represented by red points, and even vertices are represented by blue points. Dark lines represent a pure dimer covering. Assume that above the horizontal line $y=4$, only horizontal edges with an odd vertex on the left are present in the dimer configuration; and below the horizontal line $y=-4$, only horizontal edges with an even vertex on the left are present in the dimer configuration. The corresponding sequence of partitions (from the left to the right) is given by $\emptyset\prec(2,0,\ldots)\prec' (3,1,1,\ldots)\succ'(2,0,\ldots)\succ \emptyset$.}\label{fig:rye}
\end{figure}


The left boundary (resp.\ right boundary) of $RYG(l,r,\underline{a},\underline{b})$ consists of all odd vertices with abscissa $2l-1$ (resp.\ $2r+1$). Vertices which do not belong to the boundaries are called inner. A face of $RYG(l,r,\underline{a},\underline{b})$ is called an inner face if it contains only inner vertices.

We assign edge weights to a rail yard graph $RYG(l,r,\underline{a},\underline{b})$ as follows:
\begin{itemize}
    \item all the horizontal edges has weight 1; and
    \item each diagonal edge adjacent to a vertex with abscissa $2i$ has weight $x_i$.
\end{itemize}

\subsection{Dimer coverings and pure dimer coverings}

\begin{definition}
A dimer covering is a subset of edges of $RYG(l,r,\underline{a},\underline{b})$ such that
\begin{enumerate}
\item each inner vertex of $RYG(l,r,\underline{a},\underline{b})$ is incident to exactly one edge in the subset;
\item each left boundary vertex or right boundary vertex is incident to at most one edge in the subset;
\item only a finite number of diagonal edges are present in the subset.
\end{enumerate}
A pure dimer covering of $RYG(l,r,\underline{a},\underline{b})$ is dimer  covering of $RYG(l,r,\underline{a},\underline{b})$ satisfying the following two additional conditions
\begin{itemize}
\item each left boundary vertex $(2l-1,y)$ is incident to exactly one edge (resp.\ no edges) in the subset if $y>0$ (resp.\ $y<0$).
\item each right boundary vertex $(2r+1,y)$ is incident to exactly one edge (resp.\ no edges) in the subset if $y<0$ (resp.\ $y>0$).
\end{itemize}
\end{definition}

See Figure \ref{fig:rye} for an example of pure dimer coverings on a rail yard graph.

For a dimer covering $M$ on the rail-yard graph $RYG(l,r,\underline{a},\underline{b})$, define the associated height function $h_{M}$ on faces of $RYG(l,r,\underline{a},\underline{b})$ as follows. We first define a preliminary height function $\overline{h}_M$ on faces of $RYG(l,r,\underline{a},\underline{b})$. Note that there exists a positive integer $N>0$, such that when $y<-N$, only horizontal edges with even vertices on the left are present.  Fix a face $f_0$ of $RYG(l,r,\underline{a},\underline{b})$ such that the midpoint of $f_0$ is on the horizontal line $y=-N$, and define
\begin{eqnarray*}
\overline{h}_M(f_0)=0.
\end{eqnarray*}
For any two adjacent faces $f_1$ and $f_2$ sharing at least one edge, 
\begin{itemize}
\item If moving from $f_1$ to $f_2$ crosses a present (resp.\ absent) horizontal edge in $M$ with odd vertex on the left, then $\ol{h}_M(f_2)-\ol{h}_M(f_1)=1$ (resp.\ $\ol{h}_M(f_2)-\ol{h}_M(f_1)=-1$).
\item If moving from $f_1$ to $f_2$ crosses a present (resp.\ absent) diagonal edge in $M$ with odd vertex on the left, then $\ol{h}_M(f_2)-\ol{h}_M(f_1)=2$ (resp.\ $\ol{h}_M(f_2)-\ol{h}_M(f_1)=0$).
\end{itemize}

Let $\ol{h}_0$ be the preliminary height function associated to the dimer configuration satisfying 
\begin{itemize}
\item no diagonal edge is present; and
\item each present edge is horizontal with an even vertex on the left.
\end{itemize}
The height function $h_{M}$ associated to $M$ is then defined by 
\begin{eqnarray}
h_M=\ol{h}_M-\ol{h}_0.\label{dhm}
\end{eqnarray}

Let $m\in[l..r]$. Let $x=2m-\frac{1}{2}$ be a vertical line such that all the horizontal edges and diagonal edges of $RYG(l,r,\underline{a},\underline{b})$ crossed by $x=2m-\frac{1}{2}$ have odd vertices on the left. Then for each point $\left(2m-\frac{1}{2},y\right)$ in a face of $RYG(l,r,\underline{a},\underline{b})$, we have
\begin{eqnarray}
h_{M}\left(2m-\frac{1}{2},y\right)=2\left[N_{h,M}^{-}\left(2m-\frac{1}{2},y\right)+N_{d,M}^{-}\left(2m-\frac{1}{2},y\right)\right];\label{hm1}
\end{eqnarray}
where $N_{h,M}^{-}\left(2m-\frac{1}{2},y\right)$ is the total number of present horizontal edges in $M$ crossed by $x=2m-\frac{1}{2}$ below $y$, and $N_{d,M}^{-}\left(2m-\frac{1}{2},y\right)$ is the total number of present diagonal edges in $M$ crossed by $x=2m-\frac{1}{2}$ below $y$. From the definition of a pure dimer covering we can see that both $N_{h,M}^{-}\left(2m-\frac{1}{2},y\right)$ and $N_{d,M}^{-}\left(2m-\frac{1}{2},y\right)$ are finite for each finite $y$.

Note also that $x=2m+\frac{1}{2}$ is a vertical line such that all the horizontal edges and diagonal edges of $RYG(l,r,\underline{a},\underline{b})$ crossed by $x=2m+\frac{1}{2}$ have even vertices on the left. Then for each point $\left(2m+\frac{1}{2},y\right)$ in a face of $RYG(l,r,\underline{a},\underline{b})$, we have
\begin{eqnarray}
h_{M}\left(2m+\frac{1}{2},y\right)=2\left[J_{h,M}^{-}\left(2m+\frac{1}{2},y\right)-N_{d,M}^{-}\left(2m+\frac{1}{2},y\right)\right];\label{hm2}
\end{eqnarray}
where $J_{h,M}^{-}\left(2m+\frac{1}{2},y\right)$ is the total number of absent horizontal edges in $M$ crossed by $x=2m+\frac{1}{2}$ below $y$, and $N_{d,M}^{-}\left(2m+\frac{1}{2},y\right)$ is the total number of present diagonal edges in $M$ crossed by $x=2m+\frac{1}{2}$ below $y$. From the definition of a pure dimer covering we can also see that both $J_{h,M}^{-}\left(2m+\frac{1}{2},y\right)$ and $N_{d,M}^{-}\left(2m+\frac{1}{2},y\right)$ are finite for each finite $y$.



\subsection{Partitions}

A partition is a non-increasing sequence $\lambda=(\lambda_i)_{i\geq 0}$ of non-negative integers which vanish eventually. Let $\mathbb{Y}$ be the set of all the partitions. The size of a partition is defined by
\begin{eqnarray*}
|\lambda|=\sum_{i\geq 1}\lambda_i.
\end{eqnarray*}
Two partitions $\lambda$ and $\mu$ are called interlaced, and written by $\lambda\succ\mu$ or $\mu\prec \lambda$ if
\begin{eqnarray*}
\lambda_1\geq \mu_1\geq\lambda_2\geq \mu_2\geq \lambda_3\ldots
\end{eqnarray*}

When representing partitions by Young diagrams, this means $\lambda/\mu$ is a horizontal strip. The conjugate partition $\lambda'$ of $\lambda$ is a partition whose Young diagram $Y_{\lambda'}$ is the image of the Young diagram $Y_{\lambda}$ of $\lambda$ by the reflection along the main diagonal. More precisely
\begin{eqnarray*}
\lambda_i':=\left|\{j\geq 0: \lambda_j\geq i\}\right|,\qquad \forall i\geq 1.
\end{eqnarray*}

The skew Schur functions are defined in Section I.5 of \cite{IGM15}.

\begin{definition}\label{dss}Let $\lambda$, $\mu$ be partitions. Define the skew Schur functions as follows
\begin{eqnarray*}
&&s_{\lambda/\mu}=\det\left(h_{\lambda_i-\mu_j-i+j}\right)_{i,j=1}^{l(\lambda)}\\
\end{eqnarray*} 
Here for each $r\geq 0$, $h_r$ is the $r$th complete symmetric function defined by the sum of all monomials of total degree $r$ in the variables $x_1,x_2,\ldots$. More precisely,
\begin{eqnarray*}
h_r=\sum_{1\leq i_1\leq i_2\leq \ldots\leq i_r} x_{i_1}x_{i_2}\cdots x_{i_r}
\end{eqnarray*}
If $r<0$, $h_r=0$.



Define the Schur function as follows
\begin{eqnarray*}
s_{\lambda}=s_{\lambda/\emptyset}.
\end{eqnarray*}
\end{definition}

For a dimer covering $M$ of $RYG(l,r,\underline{a},\underline{b})$, we associate a particle-hole configuration to each odd vertex of $RYG(l,r,\underline{a},\underline{b})$ as follows: let $m\in[l..(r+1)]$ and $k\in\ZZ$: if the odd endpoint $\left(2m-1,k+\frac{1}{2}\right)$ is incident to a present edge in $M$ on its right (resp.\ left), then associate a hole (resp.\ particle) to the odd endpoint $\left(2m-1,k+\frac{1}{2}\right)$. When $M$ is a pure dimer covering, it is not hard to check that there exists $N>0$, such that when $y>N$, only holes exist and when $y<-N$, only particles exist.


We associate a partition $\lambda^{(M,m)}$ to the column indexed by $m$ of particle-hole configurations, which corresponds to a pure dimer covering $M$ adjacent to odd vertices with abscissa $(2m-1)$ as follows. Assume
\begin{eqnarray*}
\lambda^{(M,m)}=(\lambda^{(M,m)}_1,\lambda^{(M,m)}_2,\ldots),
\end{eqnarray*}
Then for $i\geq 1$, $\lambda^{(M,m)}_i$ is the total number of holes in $M$ along the vertical line $x=2m-1$ below the $i$th highest particles. Let $l(\lambda^{(M,m)})$ be the total number of nonzero parts in the partition $\lambda^{(M,m)}$.

We define the charge $c^{(M,m)}$ on column $(2m-1)$ for the configuration $M$ as follows:
\begin{eqnarray}
c^{(M,m)}&=&\mathrm{number\ of\ particles\ on\ column\ }(2m-1)\ \mathrm{in\ the\ upper\ half\ plane}\label{dcg}\\
&&-\mathrm{number\ of\ holes\ on\ column\ }(2m-1)\ \mathrm{in\ the\ lower\ half\ plane}\notag
\end{eqnarray}

The weight of a dimer covering $M$ of $RYG(l,r,\underline{a},\underline{b})$ is defined as follows
\begin{eqnarray*}
w(M):=\prod_{i=l}^{r}x_i^{d_i(M)},
\end{eqnarray*}
where $d_i(M)$ is the total number of present diagonal edges of $M$ incident to an even vertex with abscissa $2i$. 

Let $\lambda^{(l)},\lambda^{(r+1)}$ be two partitions. The partition function $Z_{\lambda^{(l)},\lambda^{(r+1)}}(G,\underline{x})$ of dimer coverings on $RYG(l,r,\underline{a},\underline{b})$ whose configurations on the left (resp.\ right) boundary correspond to partition $\lambda^{(l)}$ (resp.\ $\lambda^{(r+1)}$) is the sum of weights of all such dimer coverings on the graph. Given the left and right boundary conditions $\lambda^{(l)}$ and $\lambda^{(r+1)}$, respectively, the probability of a dimer covering $M$ is then defined by
\begin{eqnarray}
\mathrm{Pr}(M|\lambda^{(l)},\lambda^{(r+1)}):=\frac{w(M)}{Z_{\lambda^{(l)},\lambda^{(r+1)}}(G,\underline{x})}.\label{ppd}
\end{eqnarray}
Note that pure dimer coverings have left and right boundary conditions given by
\begin{eqnarray}
\lambda^{(l)}=\lambda^{(r+1)}=\emptyset;\label{pbc}
\end{eqnarray}
respectively.

Let $f$ be an inner face of $RYG(l,r,\underline{a},\underline{b})$. Let $M$ be a dimer covering of $C$. If exactly half of the edges bordering $f$ are present in $M$, we can obtain another dimer covering $M'$ from $M$, such that $M'$ and $M$ coincide on each edge not bordering $f$; while for an edge bordering $f$, it is present in $M'$ if and only if it is absent in $M$. In particular, $M$ and $M'$ have the same configuration on the left and right boundary. The operation of replacing $M$ by $M'$ is called a flip of $f$; see Figures \ref{fig:flip1}-\ref{fig:flipG}, where odd vertices are represented by red dots, even vertices are represented by blue dots.

\begin{figure}
\includegraphics{flip1.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip11.pdf}\\
\bigskip
\bigskip
\includegraphics{flip2.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip21.pdf}\\
\bigskip
\bigskip
\includegraphics{flip3.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip31.pdf}\\
\bigskip
\bigskip
\includegraphics{flip4.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip41.pdf}
\caption{Flip of dimer configurations on a face between two columns $(L-,L-)$, $(L-,R-)$, $(L-,L+)$, $(L-,R+)$ }\label{fig:flip1}
\end{figure}





\begin{figure}
\includegraphics{flip5.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip51.pdf}\\
\bigskip
\bigskip
\includegraphics{flip6.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip61.pdf}\\
\bigskip
\bigskip
\includegraphics{flip7.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip71.pdf}\\
\bigskip
\bigskip
\includegraphics{flip8.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip81.pdf}
\caption{Flip of dimer configurations on a face between two columns $(L+,L-)$, $(L+,L+)$, $(L+,R+)$, $(L+,R-)$.}\label{fig:flip2}
\end{figure}





\begin{figure}
\includegraphics{flip9.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flip91.pdf}\\
\bigskip
\bigskip
\includegraphics{flipA.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flipA1.pdf}\\
\bigskip
\bigskip
\includegraphics{flipB.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flipB1.pdf}\\
\bigskip
\bigskip
\includegraphics{flipC.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flipC1.pdf}
\caption{Flip of dimer configurations on a face between two columns $(R+,L+)$, $(R+,L-)$, $(R+,R-)$, $(R+,R+)$.}\label{fig:flip3}
\end{figure}

\begin{figure}
\includegraphics{flipD.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flipD1.pdf}\\
\bigskip
\bigskip
\includegraphics{flipE.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flipE1.pdf}\\
\bigskip
\bigskip
\includegraphics{flipF.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flipF1.pdf}\\
\bigskip
\bigskip
\includegraphics{flipG.pdf}\qquad$\longleftrightarrow$\qquad\includegraphics{flipG1.pdf}
\caption{Flip of dimer configurations on a face between two columns $(R-,L+)$, $(R-,L-)$, $(R-,R+)$, $(R-,R-)$}\label{fig:flipG}
\end{figure}


Then we have the following lemma.

\begin{lemma}\label{l01}\label{l01}Let $M$ be a pure dimer covering on the rail-yard graph $RYG(l,r,\underline{a},\underline{b})$. Then 
\begin{eqnarray*}
c^{(M,m)}=0,\ \forall m\in[l..(r+1)].
\end{eqnarray*}
\end{lemma}

\begin{proof}Let $M_0$ be the pure dimer covering on $RYG(l,r,\underline{a},\underline{b})$ such that
\begin{itemize}
\item all the present edges in the upper half plane are horizontal with odd vertex on the left; and
\item all the present edges in the lower half plane are horizontal with even vertex on the left.
\end{itemize}
It is straightforward to check that in the particle-whole representation for any column in $M_0$, the upper half plane only has holes, while the lower half plane only has particles. By (\ref{dcg}) we obtain
\begin{eqnarray*}
c^{(M_0,m)}=0,\qquad \forall m\in[l..(r+1)].
\end{eqnarray*}
By Section 2.3 of \cite{bbccr} (see also \cite{jp02}), any pure dimer covering $M$ of $RYG(l,r,\underline{a},\underline{b})$ can be obtained from $M_0$ by finitely many flips.
The particle-hole configuration is associated to each odd vertex.  The particle-hole configuration for each type of flips in Figures \ref{fig:flip1}-\ref{fig:flipG} are shown as in Figure \ref{fig:ph}, where particles are represented by black dots, while holes are represented by circles.
\begin{figure}
\scalebox{0.5}{\includegraphics{ph11l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph11r.pdf}}\qquad\qquad\qquad \scalebox{0.5}{\includegraphics{ph12l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph12r.pdf}}\\
\bigskip\bigskip\bigskip
\scalebox{0.5}{\includegraphics{ph14l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph14r.pdf}}\qquad\qquad\qquad \scalebox{0.5}{\includegraphics{ph16l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph16r.pdf}}\\
\bigskip\bigskip\bigskip
\scalebox{0.5}{\includegraphics{ph17l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph17r.pdf}}\qquad\qquad\qquad
\scalebox{0.5}{\includegraphics{ph18l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph18r.pdf}}
\\
\bigskip\bigskip\bigskip
 \scalebox{0.5}{\includegraphics{ph15l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph15r.pdf}}\qquad\qquad\qquad
\scalebox{0.5}{\includegraphics{ph19l.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph19r.pdf}}\\
\bigskip\bigskip\bigskip
 \scalebox{0.5}{\includegraphics{ph1G.pdf}}\qquad$\longleftrightarrow$\qquad\scalebox{0.5}{\includegraphics{ph1G1.pdf}}\qquad\qquad\qquad
\caption{Flip of particle-hole configurations on a face between two columns $L-$ and $L-$ corresponding to Figure \ref{fig:flip1}(1)(3), Figure \ref{fig:flip1}(2), Figure \ref{fig:flip1}(4), Figure \ref{fig:flip2}(1)(2), Figure \ref{fig:flip2}(3), Figure \ref{fig:flip3}(1)(2) and Figure 1.4(1)(2), Figure \ref{fig:flip3}(3) and Figure 1.4(4), Figure \ref{fig:flip3}(4) and Figure 1.4(3)}\label{fig:ph}
\end{figure}

Each local particle-hole configuration in Figure \ref{fig:ph} consists of two adjacent rows. The following cases might occur
\begin{itemize}
\item both rows are in the upper half plane; or
\item both rows are in the lower half plane; or
\item the top row is in the upper half plane and the bottom row is in the lower half plane.
\end{itemize}
It is straightforward to check that for each one of the 3 cases above, and each type particle-hole configuration change corresponding to a specific type of flip in Figure \ref{fig:ph}, the charge $c^{M,m}$ for all $m\in[l..r+1]$ remains unchanged. Then for any pure dimer covering $M$,
\begin{eqnarray*}
c^{(M,m)}=c^{(M_0,m)}=0.
\end{eqnarray*}
Then the lemma follows.
\end{proof}

\subsection{Asymptotic height function.}

Let $M$ be a dimer covering of $RYG(l,r,\underline{a},\underline{b})$. Let $Y^{(i,M,m)}$ be the ordinate of the $i$th highest particle along the line $x=2m-1$ for the pure dimer covering $M$. Then by (\ref{dcg}) we obtain
\begin{eqnarray}
\lambda_i^{(M,m)}=Y^{(i,M,m)}-c^{(M,m)}+i-\frac{1}{2}.\label{dny}
\end{eqnarray}




Assume $k\log t<0$, we have
\begin{eqnarray}
\label{ih}\int_{-\infty}^{\infty}h_{M}(x,y)t^{ky}dy&=&\frac{1}{k\log t}\int_{-\infty}^{\infty}h_M(x,y)\frac{d e^{ky\log t}}{dy}dy\\
&=&-\frac{1}{k\log t}\int_{-\infty}^{\infty}e^{ky\log t}\frac{d h_M(x,y)}{dy}dy\notag
\end{eqnarray}
Let $x=2m-\frac{1}{2}$.
From (\ref{hm1}), we obtain
\begin{eqnarray}
\frac{d h_M(2m-\frac{1}{2},y)}{dy}=2\left(1-\sum_{i=1}^{l(\lambda^{(M,m)})}\mathbf{1}_{[Y^{(i,M,m)}-\frac{1}{2},Y^{(i,M,m)}+\frac{1}{2}]}(y)\right).\label{drh}
\end{eqnarray}
Here for $A\subseteq \RR$, $\mathbf{1}_{A}(y):\RR\rightarrow \{0,1\}$ is the indicator function for the set $A$, i.e.,
\begin{eqnarray*}
\mathbf{1}_{A}(y)=\begin{cases}1&\mathrm{if}\ y\in A;\\0&\mathrm{otherwise}.\end{cases}
\end{eqnarray*}
By (\ref{dny}) we obtain for $1\leq i\leq l(\lambda^{(M,m)})$
\begin{eqnarray}
Y^{(i,M,m)}=\frac{1}{2}+\lambda_i^{(M,m)}-i+c^{(M,m)}.\label{dyi}
\end{eqnarray}

Let
\begin{eqnarray*}
B_M(m):=Y^{(l(\lambda^{(M,m)})+1)}+\frac{1}{2};
\end{eqnarray*}
Note that below $B_M(m)$, only particles are present along the vertical line $y=2m-1$, hence we have
\begin{eqnarray*}
\frac{d h_M(2m-\frac{1}{2},y)}{dy}=0,\qquad \forall y<B_M(m).
\end{eqnarray*} 
Moreover, since the charge $c^{(M,m)}=0$, there are exactly the same number of particles on the upper half plane and holes in the lower half plane along the line $x=2m-1$, we obtain
\begin{eqnarray}
-B_M(m)&=&\mathrm{number\ of\ particles\ at\ } \left(2m-1,y\right)\ \mathrm{with\ }B_M(m)<y<0\notag\\&&+
\mathrm{number\ of\ holes\ at\ }\left(2m-1,y\right)\ \mathrm{with}\ B_M(m)<y<0\notag
\\
&=&\mathrm{number\ of\ particles\ at\ }(2m-1,y)\ \mathrm{with\ }B_M(m)<y<0\notag\\&&+
\mathrm{number\ of\ particles\ at\ } (2m-1,y)\ \mathrm{with}\ y>0\notag\\
&=&
l(\lambda^{(M,m)}).\label{b0}
\end{eqnarray}
Then from (\ref{ih}) (\ref{drh}) we obtain
\begin{eqnarray*}
&&\int_{-\infty}^{\infty}h_{M}(x,y)t^{ky}dy\\
&=&-\frac{2}{k\log t}\int_{B_M(m)}^{\infty}e^{ky\log t}dy+\frac{2}{k\log t}\int_{B_M(m)}^{\infty}\sum_{i=1}^{l(\lambda^{(M,m)})}\mathbf{1}_{[Y^{(i,M,m)}-\frac{1}{2},Y^{(i,M,m)}+\frac{1}{2}]}(y) e^{ky\log t}dy\\
&=&\frac{2 t^{kB_M(m)}}{(k\log t)^2}+\frac{2}{(k\log t)^2}\sum_{i=1}^{l(\lambda^{(M,m)})}\left(e^{k(Y^{(i,M,m)}+\frac{1}{2})\log t}-e^{k(Y^{(i,M,m)}-\frac{1}{2})\log t}\right)
\end{eqnarray*}
By (\ref{dyi}), we obtain
\begin{eqnarray}
\int_{-\infty}^{\infty}h_{M}(x,y)t^{ky}dy&=&\frac{2t^{k(B_M(m)+l(\lambda^{(M,m)}))}}{(k\log t)^2}\left[t^{-kl(\lambda^{(M,m)})}+(1-t^{-k})\sum_{i=1}^{l(\lambda^{(M,m)})}t^{k(\lambda_i^{(M,m)}+c^{(M,m)}-i+1)}\right]\notag\\
&=&\frac{2}{(k\log t)^2}\left[t^{-kl(\lambda^{(M,m)})}+(1-t^{-k})\sum_{i=1}^{l(\lambda^{(M,m)})}t^{k(\lambda_i^{(M,m)}+c^{(M,m)}-i+1)}\right]\label{hme};
\end{eqnarray}
where the last identity follows from (\ref{b0}). In particular if $M$ is a pure dimer covering, we have
\begin{eqnarray*}
\int_{-\infty}^{\infty}h_{M}(x,y)t^{ky}dy
&=&\frac{2}{(k\log t)^2}\left[t^{-kl(\lambda^{(M,m)})}+(1-t^{-k})\sum_{i=1}^{l(\lambda^{(M,m)})}t^{k(\lambda_i^{(M,m)}-i+1)}\right];
\end{eqnarray*}

The bosonic Fock space $\mathcal{B}$ is the infinite dimensional Hilbert space spanned by the orthonormal basis vectors $|\lambda\rangle$, where $\lambda$ runs over all the partitions. Let $\langle \lambda |$ denote the dual basis vector. Let $x$ be a formal or a complex variable. Introduce the operators $\Gamma_{L+}(x)$, $\Gamma_{L-}(x)$, $\Gamma_{R+}(x)$, $\Gamma_{R-}(x)$ from $\mathcal{B}$  to $\mathcal{B}$ as follows
\begin{eqnarray*}
\Gamma_{L+}(x)|\lambda\rangle=\sum_{\mu\prec \lambda}x^{|\lambda|-|\mu|}|\mu\rangle;\qquad \Gamma_{R+}(x)|\lambda\rangle=\sum_{\mu'\prec \lambda'}x^{|\lambda|-|\mu|}|\mu\rangle;\\
\Gamma_{L-}(x)|\lambda\rangle=\sum_{\mu\succ \lambda}x^{|\mu|-|\lambda|}|\mu\rangle;\qquad \Gamma_{R-}(x)|\lambda\rangle=\sum_{\mu'\succ \lambda'}x^{|\mu|-|\lambda|}|\mu\rangle;
\end{eqnarray*}
Such operators were first studied in \cite{oko01} for random partitions.

\begin{lemma}\label{l12}Let $a_1,a_2\in \{L,R\}$. We have the following commutation relations for the operators $\Gamma_{a_1,\pm}$, $\Gamma_{a_2,\pm}$.
\begin{eqnarray*}
\Gamma_{a_1,+}(x_1)\Gamma_{a_2,-}(x_2)=\begin{cases}\frac{\Gamma_{a_2,-}(x_2)\Gamma_{a_1,+}(x_1)}{1-x_1x_2}&\mathrm{if}\ a_1=a_2\\(1+x_1x_2)\Gamma_{a_2,-}(x_2)\Gamma_{a_1,+}(x_1)&\mathrm{if}\ a_1\neq a_2.\end{cases}.
\end{eqnarray*}
Moreover,
\begin{eqnarray*}
\Gamma_{a_1,b}(x_1)\Gamma_{a_2,b}(x_2)=\Gamma_{a_2,b}(x_2)\Gamma_{a_1,b}(x_1);
\end{eqnarray*}
for all $a_1,a_2\in\{L,R\}$ and $b\in\{+,-\}$.
\end{lemma}

\begin{proof}See Proposition 7 of \cite{bbccr}; see also \cite{you10,bbb14}.
\end{proof}

Given the definitions of the operators $\Gamma_{a,b}(x)$ with $a\in\{L,R\}$, $b\in\{+,-\}$, it is straightforward to check the following lemma.

\begin{lemma}\label{l13}The partition function of dimer coverings on a rail yard graph $G=RYG(l,r,\underline{a},\underline{b})$ with left and right boundary conditions given by $\lambda^{(l)},\lambda^{(r+1)}$, respectively,  is 
\begin{eqnarray}
Z_{\lambda^{(l)},\lambda^{(r+1)}}(G;\underline{x})=\langle\lambda^{(l)}| \Gamma_{a_lb_l}(x_l)\Gamma_{a_{l+1}b_{l+1}}(x_{l+1})\cdots \Gamma_{a_rb_r}(x_r)|\lambda^{(r+1)} \rangle\label{bf}
\end{eqnarray}
\end{lemma}







\begin{corollary}
The partition function of pure dimer coverings can be computed as follows:
\begin{eqnarray}
Z_{\emptyset,\emptyset}(G;\underline{x})=\prod_{l\leq i<j\leq r;b_i=+,b_j=-}z_{i,j}\label{fp}
\end{eqnarray}
where
\begin{eqnarray}
z_{ij}=\begin{cases}1+x_ix_j&\mathrm{if}\ a_i\neq a_j\\\frac{1}{1-x_ix_j}&\mathrm{if}\ a_i=a_j\end{cases}\label{dzij}
\end{eqnarray}
\end{corollary}

\begin{proof}The corollary follows from Lemma \ref{l13} by letting $\lambda^{(l)}=\lambda^{(r+1)}=\emptyset$; it also appears in Proposition 8 of \cite{bbccr} for (\ref{bf}); and Theorem 1 of \cite{bbccr} for (\ref{fp}).
\end{proof}

\noindent{\textbf{Remark.}} The partition function $Z(G;\underline{x})$ is always well-defined as a power series in $\underline{x}$. When we consider the edge weights $x_i$'s to be positive numbers, to make sure the convergence of the power series representing the partition function, we need to assume that
\begin{itemize}
\item For any $i,j\in[l..r]$, $i<j$, $a_i=a_j$ and $b_i=+$, $b_j=-$ we have
\begin{eqnarray*}
x_ix_j<1.
\end{eqnarray*}
\end{itemize}
However, when considering the corresponding probability measure, we do not necessarily need this assumption.

\subsection{Piecewise Periodicity of $\underline{a}$ and $\underline{b}$}

We shall assume that the sequences $\underline{a}$ and $\underline{b}$ describing the structure of the graph satisfy the following piecewise periodicity assumption.

\begin{assumption}\label{ap41}Let $\epsilon>0$ be a small positive parameter. 
\begin{enumerate}
\item Let $l^{(\epsilon)}<r^{(\epsilon)}$ be the  integers representing the left and right boundary of the rail-yard graph depending on $\epsilon$ such that
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\epsilon l^{(\epsilon)}=l^{(0)}<r^{(0)}=\lim_{\epsilon\rightarrow 0}\epsilon r^{(\epsilon)}
\end{eqnarray*}
so that the scaling limit of the sequence of rail-yard graphs $\{\epsilon RYG(l^{(\epsilon)},r^{(\epsilon)},\underline{a}^{(\epsilon)},\underline{b}^{(\epsilon)})\}_{\epsilon>0}$, as $\epsilon\rightarrow 0$, has left boundary given by $x=2l^{(0)}$ and right boundary given by $x=2r^{(0)}$.
\item Let $n$ be a positive integer independent of $\epsilon$. Assume for each $\epsilon>0$, the sequence $\underline{a}^{(\epsilon)}$ with indices in 
in $\left(l^{(\epsilon)},r^{(\epsilon)}\right)$ is $n$-periodic. More precisely,
for any integers $i,j$ satisfying 
\begin{eqnarray}
l^{(\epsilon)}< i<j \leq r^{(\epsilon)},\qquad \mathrm{and}\qquad
[(i-j)\mod n]=0,\label{cdij}
\end{eqnarray}
then
\begin{eqnarray*}
a_i^{(\epsilon)}=a_j^{(\epsilon)}.
\end{eqnarray*}
Moreover, assume that for each $\epsilon>0$,
\begin{eqnarray*}
N_L:=\{i\in[n]:a^{(\epsilon)}_i=L\};\qquad
N_R:=\{i\in[n]:a^{(\epsilon)}_i=R\}.
\end{eqnarray*}
then $N_L$ and $N_R$ are independent of $\epsilon$.
\item Assume for each $\epsilon>0$, there exist integers
\begin{eqnarray*}
l^{(\epsilon)}=v_0^{(\epsilon)}<v_1^{(\epsilon)}<\ldots<v_m^{(\epsilon)}=r^{(\epsilon)};
\end{eqnarray*}
such that for each $p\in[m]$, the sequence
$\underline{b}^{(\epsilon)}$ with indices in 
in $\left(v_{p-1}^{(\epsilon)},v_{p}^{(\epsilon)}\right)$ is $n$-periodic. More precisely,
for any integers $i,j$ satisfying 
\begin{eqnarray}
v_{p-1}^{(\epsilon)}< i<j \leq v_p^{(\epsilon)},\qquad \mathrm{and}\qquad
[(i-j)\mod n]=0,\label{cdij2}
\end{eqnarray}
then
\begin{eqnarray*}
 b_i^{(\epsilon)}=b_j^{(\epsilon)};
\end{eqnarray*}
Here $m$ is a positive integers independent of $\epsilon$.
\item There exist
\begin{eqnarray*}
0=l^{(0)}=V_0<V_1<\ldots<V_m=r^{(0)},
\end{eqnarray*}
such that
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\epsilon v_p^{(\epsilon)}=V_p,\ \forall p\in[m].
\end{eqnarray*}
\item For each $p\in [m]$, $j\in[n]$, $\mathbf{a}\in\{L,R\}$, $\mathbf{b}\in\{+,-\}$,
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\frac{\left|\left\{u\in [v_{p-1}^{(\epsilon)}+1..v_p^{(\epsilon)}]\cap \{n\ZZ+j\}: a_u=\mathbf{a},b_u=\mathbf{b}\right\}\right|}{v_p^{(\epsilon)}-v_{p-1}^{(\epsilon)}}&=&\zeta_{\mathbf{a},\mathbf{b},j,p
\end{eqnarray*}
\end{enumerate}
\end{assumption}

\begin{remark}\label{rm42}Under Assumption \ref{ap41}, it is straightforward to check that for each fixed $p\in [m]$ and $j\in[n]$,
\begin{eqnarray*}
\zeta_{L,+,j,p}+\zeta_{L,-,j,p}+\zeta_{R,+,j,p}+\zeta_{R,-,j,p}=\frac{1}{n}.
\end{eqnarray*}
Moreover, exactly one of $\zeta_{L,+,j,p},\zeta_{L,-,j,p}, 
\zeta_{R,+,j,p}, \zeta_{R,-,j,p}$ is $\frac{1}{n}$, and all the other three are 0, by Assumption \ref{ap41}(2).
\end{remark}

\begin{assumption}\label{ap43}Suppose that Assumption \ref{ap41} holds. Suppose that the weights of diagonal edges also depend on $\epsilon$. More precisely, for integer $i,j$ satisfying (\ref{cdij2}) and $p\in[m]$, let $k$ be the unique positive integer satisfying
\begin{eqnarray*}
k\in[n];\ \mathrm{and}\ [(k-i)\mod n]=0.
\end{eqnarray*}
then there exists $\tau_1,\ldots,\tau_n$ independent of $\epsilon$ and $p$, such that
\begin{enumerate}
\item if $b_i^{(\epsilon)}=b_j^{(\epsilon)}=+$, then
\begin{eqnarray*}
x_j^{(\epsilon)}=e^{-(j-i)\epsilon}x_i^{(\epsilon)}.
\end{eqnarray*}
and 
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}e^{(i-k)\epsilon}x_i^{(\epsilon)}=x_{k}^{(0,p)}:=\tau_k
\end{eqnarray*}
\item if $b_i^{(\epsilon)}=b_j^{(\epsilon)}=-$, then
\begin{eqnarray*}
x_j^{(\epsilon)}=e^{(j-i)\epsilon}x_i^{(\epsilon)}.
\end{eqnarray*}
and
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}e^{-(i-k)\epsilon}x_i^{(\epsilon)}=x_k^{(0,p)}:=\frac{1}{\tau_k}
\end{eqnarray*}
\end{enumerate}
\end{assumption}

\section{McDonald Processes}\label{sect:sc}

In this section, we discuss a class of Mcdonald processes related to the probability measure of perfect matchings on the rail-yard graphs. The major characterstic of the processes defined here is that the processes here involve dual partitions as well, which, as we will see, can also be obtained from a specialization of the Macdonald processes defined without dual partitions (see \cite{bc13},\cite{bcgs13}) by a specialization that is not a function evaluation, when the parameters satisfy $q=t$.



Let $G=RYG(l,r,\underline{a},\underline{b})$ be a rail-yard graph. Let $(\lambda^{(M,l)},\lambda^{(M,l+1)},\ldots,\lambda^{(M,r)},\lambda^{(M,r+1)})$ be the sequence of partitions corresponding to a dimer covering $M$ on $G$. By  Lemmas \ref{l12} and \ref{l13}, we obtain
for $i\in[l..r]$
\begin{enumerate}
\item If $(a_i,b_i)=(L,-)$, $\lambda^{(M,i+1)}\prec \lambda^{(M,i)}$;
\item If $(a_i,b_i)=(L,+)$, $\lambda^{(M,i+1)}\succ \lambda^{(M,i)}$;
\item If $(a_i,b_i)=(R,-)$, $[\lambda^{(M,i+1)}]'\prec [\lambda^{(M,i)}]'$;
\item If $(a_i,b_i)=(R,+)$, $[\lambda^{(M,i+1)}]'\succ [\lambda^{(M,i)}]'$
\end{enumerate}


Given Definition \ref{dss}, we can express the probability of a dimer covering $M$ conditional on boundary the left and right conditions $\lambda^{(l)}$ and $\lambda^{(r+1)}$ respectively, as defined by (\ref{ppd}), as follows:
\begin{eqnarray}
&&\mathrm{Pr}(M|\lambda^{(l)},\lambda^{(r+1)}):=\frac{1}{Z_{\lambda^{(l)},\lambda^{(r+1)}}(G,\underline{x})}\label{pm}\\
&&\left(\prod_{i\in[l..r],(a_i,b_i)=(L,-)} s_{\lambda^{(M,i)}/\lambda^{(M,i+1)}}(x_i)\prod_{j\in[l..r],(a_i,b_i)=(L,+)} s_{\lambda^{(M,j+1)}/\lambda^{(M,j)}}(x_j)\right.\notag\\
&&\left.\times\prod_{i\in[l..r],(a_i,b_i)=(R,-)} s_{[\lambda^{(M,i)}]'/[\lambda^{(M,i+1)}]'}(x_i)\prod_{j\in[l..r],(a_i,b_i)=(R,+)} s_{[\lambda^{(M,j+1)}]'/[\lambda^{(M,j)}]'}(x_j)\right)\notag
\end{eqnarray}

Now we define a generalized MacDonald process, which is a formal probability measure on sequences of partitions such that the probability of each sequence of partitions is proportional to a sum of products of skew MacDonald polynomials.
\begin{definition}\label{df22}Let
\begin{eqnarray*}
\bA&=&(A^{(l)},A^{(l+1)},\ldots,A^{(r)},A^{(r+1)});\\
\bB&=&(B^{(l)},B^{(l+1)},\ldots,B^{(r)},B^{(r+1)}).
\end{eqnarray*}
be $2(r-l+2)$ set of variables, in which each $A^{(i)}$ or $B^{(j)}$ consists of countably many variables.
Let $\mathcal{P}=\{\mathcal{L},\mathcal{R}\}$ be a partition of the set $[l..r]$, i.e.
\begin{enumerate}
    \item $\mathcal{L}\cup\mathcal{R}=[l..r]$; and
    \item $\mathcal{L}\cap \mathcal{R}=\emptyset$.
\end{enumerate}

Define a formal probability measure on sequences of $(r-l+2)$ partitions
\begin{eqnarray*}
(\lambda^{(l)},\lambda^{(r+1)},\ldots,\lambda^{(r)},\lambda^{(r+1)})
\end{eqnarray*}
with respect to $\mathcal{P}$, $\bA$ and $\bB$ and parameters $q,t\in(0,1)$ by
\begin{eqnarray}
&&\MP_{\bA,\bB,\mathcal{P},q,t}(\lambda^{(l)},\ldots,\lambda^{(r+1)})\propto
\label{pmd}
\\&&
\left[\prod_{i\in\mathcal{L}}\Psi_{\lambda^{(i)},\lambda^{(i+1)}}(A^{(i)},B^{(i+1)};q,t)\right] \left[\prod_{j\in\mathcal{R}}\Phi_{[\lambda^{(j)}]',[\lambda^{(j+1)}]'}(A^{(j)},B^{(j+1)};q,t)\right] \notag
\end{eqnarray}
where for two partitions $\lambda,\mu\in \YY$, and two countable set of variables $A$, $B$,
\begin{eqnarray*}
\Psi_{\lambda,\mu}(A,B;q,t)=\sum_{\nu\in \YY}P_{\lambda/\nu}(A;q,t)Q_{\mu/\nu}(B;q,t).\\
\Phi_{\lambda,\mu}(A,B;q,t)=\sum_{\nu\in \YY}Q_{\lambda/\nu}(A;t,q)P_{\mu/\nu}(B;t,q)
\end{eqnarray*}
\end{definition}

See Section \ref{sc:dmp} for definitions of MacDonald polynomials $P_{\lambda}$, $Q_{\lambda}$, $P_{\lambda/\mu}$, $Q_{\lambda/\mu}$.

\begin{remark}In terms of the scalar product as defined in (\ref{dsp}), we also have
\begin{eqnarray*}
&&\Psi_{\lambda,\mu}(A,B;q,t)=\langle P_{\lambda}(A,Y;q,t),Q_{\mu}(Y,B;q,t) \rangle_Y, \\
&&\Phi_{\lambda,\mu}(A,B)=\langle P_{\mu}(Y,B;t,q),Q_{\lambda}(A,Y;t,q) \rangle_Y
\end{eqnarray*}
where $Y$ is a countable set of variables.
\end{remark}

\begin{lemma}\label{l23}Consider dimer coverings on the rail-yard graph with probability measure conditional on left and right boundary conditions $\lambda^{(l)}$ and $\lambda^{(r+1)}$, respectively, given by (\ref{pm}). Then the corresponding sequences of partitions form a generalized MacDonald process as in Definition \ref{df22} with 
\begin{enumerate}
\item $\mathcal{L}=\{i\in[l..r]:a_i=L\}$ and $\mathcal{R}=\{j\in[l..r]:a_j=R\}$; and
\item For $i\in [l..r]$, 
\begin{enumerate}
\item if $b_i=-$, then $A^{(i)}=\{x_i\},B^{(i+1)}=\{0\}$;
\item if $b_i=+$, then $A^{(i)}=\{0\},B^{(i+1)}=\{x_i\}$;
\end{enumerate}
\item $q=t$;
\end{enumerate}
conditional on fixed $\lambda^{(l)}$ and $\lambda^{(r+1)}$ on the left and right boundaries, respectively.
\end{lemma}
\begin{proof}Note that when $q=t$ and each one of $A^{(i)}$ and $B^{(i+1)}$ consists of a single variable,
\begin{eqnarray*}
\Psi_{\lambda^{(i)},\lambda^{(i+1)}}(A^{(i)},B^{(i+1)};t,t)=\sum_{\nu\in\YY}s_{\lambda^{(i)}/\nu}(A^{(i)})s_{\lambda^{(i+1)}/\nu}(B^{(i+1)})
\end{eqnarray*}
When $b_i=-$,
\begin{eqnarray*}
s_{\lambda^{(i+1)}/\nu}(0)=\begin{cases}1&\mathrm{if}\ \nu=\lambda^{(i+1)};\\0&\mathrm{otherwise}.\end{cases};
\end{eqnarray*}
and therefore
\begin{eqnarray*}
\Psi_{\lambda^{(i)},\lambda^{(i+1)}}(x_i,0;t,t)&=&s_{\lambda^{(i)}/\lambda^{(i+1)}}(x_i)
\end{eqnarray*}
Similarly, we obtain that when $b_i=-$,
\begin{eqnarray*}
\Phi_{\lambda^{(i)},\lambda^{(i+1)}}(x_i,0;t,t)&=&s_{\lambda^{(i)}/\lambda^{(i+1)}}(x_i);
\end{eqnarray*}
and when $b_i=+$,
\begin{eqnarray*}
\Psi_{\lambda^{(i)},\lambda^{(i+1)}}(x_i,0;t,t)&=&s_{\lambda^{(i+1)}/\lambda^{(i)}}(x_i)=
\Phi_{\lambda^{(i)},\lambda^{(i+1)}}(x_i,0;t,t)
\end{eqnarray*}
It is straightforward to check that when all the assumptions of the lemma hold, the probability measure of the formal MacDonald process, defined by (\ref{pmd}), is exactly the probability measure given by (\ref{pm}).
\end{proof}

\section{Moments of Random Height Functions}\label{sect:mh}.

In this section, we compute the moments of height functions of perfect matchings on rail-yard graphs by computing the observables in the generalized Mcdonald processes.

Let $\lambda\in \YY$ be a partition and $q,t\in(0,1)$ be parameters. Let
\begin{eqnarray}
\gamma_k(\lambda;q,t)=(1-t^{-k})\sum_{i=1}^{l(\lambda)}q^{k\lambda_i}t^{k(-i+1)}+t^{-kl(\lambda)}\label{dgm}
\end{eqnarray}

Define
\begin{eqnarray}
H(W,X;q,t)=\prod_{i=1}^k\prod_{x_j\in X}\frac{w_i-\frac{q x_j}{t}}{w_i-q x_j}\label{dh}
\end{eqnarray}


We have the following lemma.

\begin{lemma}\label{l41}
\begin{eqnarray*}
\gamma_k(\lambda';t,q)=\gamma_k\left(\lambda;
\frac{1}{q},\frac{1}{t}\right)
\end{eqnarray*}
\end{lemma}

\begin{proof}For $\lambda\in \YY$, $q,t\in \RR^+$, let $f_{\lambda}(q,t)$ be defined as in Lemma \ref{a13}. By Lemma \ref{a13}, it is straightforward to check that
\begin{eqnarray*}
\gamma_k(\lambda';t,q)=1+f_{\lambda'}\left(t^k,\frac{1}{q^k}\right)=1+f_{\lambda}\left(\frac{1}{q^k},t^k\right)=\gamma_k\left(\lambda;\frac{1}{q},\frac{1}{t}\right).
\end{eqnarray*}
Then the lemma follows.
\end{proof}

\begin{lemma}\label{l31
\begin{small}
\begin{eqnarray*}
&&\left.\EE_{\MP_{A,B,\mathcal{P};q,t}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}\left[\prod_{i\in[l+1..r]} \gamma_{l_i}(\lambda^{(i)};q,t)\right]\right|_{q=t}\\
&=&\frac{1}{\mathcal{Z}}\oint\ldots\oint \left(\prod_{i<j;i,j\in[l+1..r]}T_{a_i,a_j}(W^{(i)},W^{(j)})\right)
\cdot\left(\prod_{i=[l+1..r]}D(W^{(i)};\omega(t,t,a_i))H(W^{(i)},A^{(i)};\omega(t,t,a_i))\right)
\\
&&\times\left(\prod_{i<j;i,j\in[l+1..r]}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}A^{(j)};\omega(t,t,a_i))\right)^{(-1)^{\delta_{a_i,a_j}-1}}\right)
\\
&&\times\left(\prod_{i<j;i,j\in[l..r]}\frac{\Pi_{a_i,a_j}(B^{(i+1)},(A^{(j)},W^{(j)}))}{\Pi_{a_i,a_j}(B^{(i+1)},\xi(t,t,a_j)W^{(j)})}\right)
\end{eqnarray*}
\end{small}
where the expectation is with respect to the probability measure on pure dimer configurations of $RYG(l,r,\underline{a},\underline{b})$ as defined in (\ref{ppd}), (\ref{pm});  and
\begin{eqnarray}
&&\omega(q,t,a_{i})=\begin{cases}
(q,t)&\mathrm{if}\ a_{i}=L\\
\left(\frac{1}{t},\frac{1}{q}\right)&\mathrm{if}\ a_{i}=R
\end{cases}\label{do}\\
&&\xi(q,t,a_j)=\begin{cases}q^{-1}&\mathrm{If}\ a_j=L\\ t&\mathrm{If}\ a_j=R. \end{cases}\label{dx}
\end{eqnarray}
and
\begin{eqnarray*}
T_{c,d}(Z,W):=\begin{cases}
\prod_{z_i\in Z}\prod_{w_j\in W}\frac{(1-w_jz_i^{-1})^2}{(1-t^{-1}w_j z_i^{-1})
(1-tw_j z_i^{-1})
}&\mathrm{if}\ c=d\\
\prod_{z_i\in Z}\prod_{w_j\in W}\frac{(1+tw_jz_i^{-1})^2}{(1+t^2w_j z_i^{-1})
(1+w_j z_i^{-1})}
&\mathrm{if}\ c=L\ \mathrm{and}\ d=R\\
\prod_{z_i\in Z}\prod_{w_j\in W}\frac{(1+t^{-1}w_jz_i^{-1})^2}{(1+t^{-2}w_j z_i^{-1})
(1+w_j z_i^{-1})
}&\mathrm{if}\ c=R\ \mathrm{and}\ d=L.
\end{cases}
\end{eqnarray*}
where $|W^{(i)}|=l_i$, and the integral contours are given by $\{\mathcal{C}_{i,j}\}_{i\in [l+1..r],s\in[l_i]}$ such that
\begin{enumerate}
    \item $\mathcal{C}_{i,s}$ is the integral contour for the variable $w^{(i)}_s\in W^{(i)}$;
    \item if $a_i=L$, $\mathcal{C}_{i,s}$ encloses 0 and every singular point of 
    \begin{eqnarray*}
\prod_{j\in[i..r]}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}A^{(j)};t,t)\right)^{(-1)^{\delta_{a_i,a_j}-1}},
\end{eqnarray*}
but no other singular points of the integrand.
\item if $a_i=R$, $\mathcal{C}_{i,s}$ encloses 0 and every singular point of 
    \begin{eqnarray*}
\prod_{j\in[i..r]}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}A^{(j)};t^{-1},t^{-1})\right)^{(-1)^{\delta_{a_i,a_j}-1}},
\end{eqnarray*}
but no other singular points of the integrand.
    \item the contour $\mathcal{C}_{i,j}$ is contained in the domain bounded by $\min\{t,\frac{1}{t}\}\mathcal{C}_{i',j'}$ whenever $(i,j)<(i',j')$ in lexicographical ordering;
\end{enumerate}
$H(W,X;q,t)$ is given by (\ref{dh}), and $D(W;q,t)$ is given by (\ref{ddf}).
\end{lemma}

\begin{proof}By Lemma \ref{l41}, we obtain
\begin{eqnarray*}
&&\left.\EE_{\MP_{A,B,\mathcal{P};q,t}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}\left[\prod_{i\in[l+1..r]} \gamma_{l_i}(\lambda^{(i)};q,t)\right]\right|_{q=t}\\
&=&\left.\EE_{\MP_{A,B,\mathcal{P};q,t}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}\left[\prod_{i\in[l+1..r]\cap \mathcal{L}} \gamma_{l_i}(\lambda^{(i)};q,t)\right] \left[\prod_{i\in[l+1..r]\cap \mathcal{R}} \gamma_{l_i}\left(\left[\lambda^{(i)}\right]';\frac{1}{t},\frac{1}{q}\right)\right]
\right|_{q=t}
\end{eqnarray*}
Recall that the Macdonald polynomials satisfy (See Page 324 of \cite{IGM15})
\begin{eqnarray}
P_{\lambda}(X;q,t)=P_{\lambda}\left(X;\frac{1}{q},\frac{1}{t}\right);\qquad
Q_{\lambda}(X;q,t)=\left(\frac{t}{q}\right)^{|\lambda|}Q_{\lambda}\left(X;\frac{1}{q},\frac{1}{t}\right)\label{pqr}
\end{eqnarray}
We obtain
\begin{small}
\begin{eqnarray*}
&&\left.\EE_{\MP_{A,B,\mathcal{P};q,t}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}\left[\prod_{i=[l+1..r]\cap \mathcal{L}} \gamma_{l_i}(\lambda^{(i)};q,t)\right] \left[\prod_{i=[l+1..r]\cap \mathcal{R}} \gamma_{l_i}\left(\left[\lambda^{(i)}\right]';\frac{1}{t},\frac{1}{q}\right)\right]
\right|_{q=t}\\
&=&\sum_{\lambda^{(l)},\ldots,\lambda^{(r+1)}\in\YY}
\left[\prod_{i=[l+1..r]\cap \mathcal{L}} \gamma_{l_i}(\lambda^{(i)};q,t)\right] \left[\prod_{i=[l+1..r]\cap \mathcal{R}} \gamma_{l_i}\left(\left[\lambda^{(i)}\right]';\frac{1}{t},\frac{1}{q}\right)\right]\\
&&\times\left.\MP_{A,B,\mathcal{P};q,t}(\lambda^{(l)},\ldots,\lambda^{(r+1)}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset)\right|_{q=t}\\
&=&\frac{1}{\mathcal{Z}}\sum_{\lambda^{(l+1)},\ldots,\lambda^{(r)}\in\YY}
\left[\prod_{i=[l+1..r]\cap \mathcal{L}} \gamma_{l_i}(\lambda^{(i)};q,t)\right] \left[\prod_{i=[l+1..r]\cap \mathcal{R}} \gamma_{l_i}\left(\left[\lambda^{(i)}\right]';\frac{1}{t},\frac{1}{q}\right)\right]\\
&&\times\left[\prod_{i\in\mathcal{L}}\langle P_{\lambda^{(i)}}(A^{(i)},Y^{(i)};q,t),Q_{\lambda^{(i+1)}}(Y^{(i)},B^{(i+1)};q,t) \rangle_{Y^{(i)}}\right]\\
&&\left.\left[\prod_{i\in\mathcal{R}}\langle Q_{[\lambda^{(i)}]'}\left(A^{(i)},Y^{(i)};t,q\right),P_{[\lambda^{(i+1)}]'}\left(Y^{(i)},B^{(i+1)};t,q\right) \rangle_{Y^{(i)}}\right]\right|_{q=t,\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}
\end{eqnarray*}
\end{small}
where for each $i$, $Y^{(i)}$ is a countable collection of variables; and
\begin{small}
\begin{eqnarray*}
\mathcal{Z}&=&\sum_{\lambda^{(l+1)},\ldots,\lambda^{(r)}\in\YY}\left[\prod_{i\in\mathcal{L}}\langle P_{\lambda^{(i)}}(A^{(i)},Y^{(i)};q,t),Q_{\lambda^{(i+1)}}(Y^{(i)},B^{(i+1)};q,t) \rangle_{Y^{(i)}}\right]\\
&&\left.\left[\prod_{i\in\mathcal{R}}\langle Q_{[\lambda^{(i)}]'}(A^{(i)},Y^{(i)};t,q),P_{[\lambda^{(i+1)}]'}(Y^{(i)},B^{(i+1)};t,q) \rangle_{Y^{(i)}}\right]\right|_{q=t,\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}.
\end{eqnarray*}
\end{small}
For $i\in[l+1..r]$, let
\begin{eqnarray*}
\mathbf{E}_i=\begin{cases}\sum_{\lambda^{(i)}\in \YY}\gamma_{l_i}(\lambda^{(i)};q,t)P_{\lambda^{(i)}}(A^{(i)},Y^{(i)};q,t)Q_{\lambda^{(i)}}(Y^{(i-1)},B^{(i)};q,t)& \mathrm{if}\ i-1\in \mathcal{L},\ i\in\mathcal{L}\\ \sum_{\lambda^{(i)}\in\YY}\gamma_{l_i}\left(\left[\lambda^{(i)}\right]';\frac{1}{t},\frac{1}{q}\right)Q_{\lambda^{(i)}}(Y^{(i-1)},B^{(i)};q,t)Q_{[\lambda^{(i)}]'}(A^{(i)},Y^{(i)};t,q)& \mathrm{if}\ i-1\in\mathcal{L},\ i\in\mathcal{R}\\
\sum_{\lambda^{(i)}\in\YY}\gamma_{l_i}(\lambda^{(i)};q,t)P_{[\lambda^{(i)}]'}(Y^{(i-1)},B^{(i)};t,q)P_{\lambda^{(i)}}(A^{(i)},Y^{(i)};q,t)& \mathrm{if}\ i-1\in\mathcal{R},\ i\in\mathcal{L}\\
\sum_{\lambda^{(i)}\in\YY}\gamma_{l_i}\left(\left[\lambda^{(i)}\right]';\frac{1}{t},\frac{1}{q}\right)P_{[\lambda^{(i)}]'}(Y^{(i-1)},B^{(i)};t,q)Q_{[\lambda^{(i)}]'}(A^{(i)},Y^{(i)};t,q)& \mathrm{if}\ i-1\in\mathcal{R},\ i\in\mathcal{R}
\end{cases}
\end{eqnarray*}
Moreover,
\begin{eqnarray*}
\mathbf{E}_l&=&\begin{cases}P_{\lambda^{(l)}}(A^{(l)},Y^{(l)};q,t);&\mathrm{if}\ l\in \mathcal{L}\\
Q_{[\lambda^{(l)}]'}(A^{(l)},Y^{(l)};t,q).&\mathrm{if}\ l\in \mathcal{R}
\end{cases}\\
\mathbf{E}_{r+1}&=&\begin{cases}
P_{[\lambda^{(r+1)}]'}(Y^{(r)},B^{(r+1)};t,q);&\mathrm{if}\ r\in \mathcal{R}\\
Q_{\lambda^{(r+1)}}(Y^{(r)},B^{(r+1)};q,t).&\mathrm{if}\ r\in \mathcal{L}
\end{cases}.
\end{eqnarray*}
When $\lambda^{(l)}=\lambda^{(r+1)}=\emptyset$ and $q=t$, we have
\begin{eqnarray*}
\mathbf{E}_l=\mathbf{E}_{r+1}=1.
\end{eqnarray*}
Then
\begin{small}
\begin{eqnarray*}
&&\left.\EE_{\MP_{A,B,\mathcal{P},q,t}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}
\left[\prod_{i=[l+1..r]\cap \mathcal{L}} \gamma_{l_i}(\lambda^{(i)};q,t)\right] \left[\prod_{i=[l+1..r]\cap \mathcal{R}} \gamma_{l_i}\left(\left[\lambda^{(i)}\right]';t,q\right)\right]
\right|_{q=t}\\
&=&\left.\frac{1}{\mathcal{Z}}\langle \mathbf{E}_{l}\langle \mathbf{E}_{l+1}\ldots\langle \mathbf{E}_{r},\mathbf{E}_{r+1}\rangle_{Y^{((r))}}\ldots \rangle_{Y^{(l+1)}} \rangle_{Y^{(l)}}\right|_{q=t,\ \lambda^{(l)}=\lambda^{(r+1)}=\emptyset}
\end{eqnarray*}
\end{small}
Let
\begin{small}
\begin{eqnarray*}
\Pi_{LL}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))=\sum_{\lambda\in\YY}P_{\lambda}(A^{(i)},Y^{(i)};q,t)Q_{\lambda}(Y^{(i-1)},B^{(i)};q,t)\\
\Pi_{LR}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))=\sum_{\lambda\in\YY}Q_{\lambda}(Y^{(i-1)},B^{(i)};q,t)Q_{\lambda'}(A^{(i)},Y^{(i)};t,q)\\
\Pi_{RL}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))=\sum_{\lambda\in\YY}P_{\lambda'}(Y^{(i-1)},B^{(i)};t,q)P_{\lambda}(A^{(i)},Y^{(i)};q,t)\\
\Pi_{RR}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))=\sum_{\lambda\in\YY}P_{\lambda'}(Y^{(i-1)},B^{(i)};t,q)Q_{\lambda'}(A^{(i)},Y^{(i)};t,q)
\end{eqnarray*}
\end{small}
Then for $i\in[l+1..r]$,
\begin{eqnarray*}
&&\mathbf{E}_i=
\begin{cases}
D_{-l_i,(A^{(i)},Y^{(i)});q,t}\Pi_{a_{i-1},a_i}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))&\mathrm{If}\ a_i=L;\\
D_{-l_i,(A^{(i)},Y^{(i)});\frac{1}{t},\frac{1}{q}}\Pi_{a_{i-1},a_i}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))&\mathrm{If}\ a_i=R;
\end{cases}
\end{eqnarray*}
where $D_{-l_i,(A^{(i)},Y^{(i-1)})}$ is the operator defined as in (\ref{ngt}).

By Lemma \ref{la3}, we obtain
\begin{eqnarray*}
&&\Pi_{LL}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))=\Pi(
(A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)});q,t)\\
&&\Pi_{RR}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))=\Pi(
(A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)});t,q).
\end{eqnarray*}
Moreover,
\begin{eqnarray*}
&&\Pi_{LR}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))=
\Pi_{RL}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))\\
&=&\prod_{u\in 
(A^{(i)},Y^{(i)}), v\in (Y^{(i-1)},B^{(i)})}(1+uv)
\end{eqnarray*}
By Proposition \ref{pa2}, we obtain for $i\in[l+1..r]$ and $q=t$,
\begin{itemize}
\item If $a_i=L$;
\begin{eqnarray*}
\mathbf{E}_i&=&\Pi_{a_{i-1},a_i}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))\\
&&\oint\cdots\oint D(W^{(i)};q,t)H(W^{(i)},(A^{(i)},Y^{(i)});q,t)\frac{\Pi_{a_{i-1},a_i}((Y^{(i-1)},B^{(i)}),W^{(i)})}{\Pi_{a_{i-1},a_i}((Y^{(i-1)},B^{(i)}),q^{-1}W^{(i)})};
\end{eqnarray*}
\item If $a_i=R$;
\begin{eqnarray*}
\mathbf{E}_i&=&\Pi_{a_{i-1},a_i}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))\\
&&\oint\cdots\oint D\left(W^{(i)};\frac{1}{t},\frac{1}{q}\right)H\left(W^{(i)},(A^{(i)},Y^{(i)});\frac{1}{t},\frac{1}{q}\right)\frac{\Pi_{a_{i-1},a_i}((Y^{(i-1)},B^{(i)}),W^{(i)})}{\Pi_{a_{i-1},a_i}((Y^{(i-1)},B^{(i)}),tW^{(i)})};
\end{eqnarray*}
\end{itemize}
where each integral contour encloses $0$ and all the poles of $H(W^{(i)},(A^{(i)},Y^{(i)});q,t)$; moreover, if 
\begin{eqnarray*}
W^{(i)}=\left(w^{(i)}_1,w^{(i)}_2,\ldots, w^{(i)}_{l_i}\right),
\end{eqnarray*}
then along the integral contours $|w_j^{(i)}|\leq |tw_{j+1}^{(i)}|$ for each $i\in[l_i-1]$.

It is straightforward to check that for $a_{i-1},a_i\in \{L,R\}$, 
\begin{eqnarray*}
&&\Pi_{a_{i-1},a_i}((A^{(i)},Y^{(i)}),(Y^{(i-1)},B^{(i)}))\\&=&
\Pi_{a_{i-1},a_i}(A^{(i)},Y^{(i-1)})\cdot 
\Pi_{a_{i-1},a_i}(A^{(i)},B^{(i)})\cdot
\Pi_{a_{i-1},a_i}(Y^{(i)},Y^{(i-1)})\cdot
\Pi_{a_{i-1},a_i}(Y^{(i)},B^{(i)}).
\end{eqnarray*}
Moreover,
\begin{eqnarray*}
&&\Pi_{a_{i-1},a_i}((Y^{(i-1)},B^{(i)}),W^{(i)})=\Pi_{a_{i-1},a_i}(B^{(i)},W^{(i)})\Pi_{a_{i-1},a_i}(Y^{(i-1)},W^{(i)});\\
&&H(W^{(i)},(A^{(i)},Y^{(i)});q,t)=H(W^{(i)},Y^{(i)};q,t)H(W^{(i)},A^{(i)};q,t).
\end{eqnarray*}
Since the integrand in each $\mathbf{E}_i$ is $\Lambda_{Y^{(i)}}$-projective, by Lemma \ref{A12} we can interchange the order of the residue and Macdonald scalar product and obtain
\begin{small}
\begin{eqnarray*}
&&\left.\EE_{\MP_{A,B,\mathcal{P};q,t}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}\left[\prod_{i=[l+1..r]} \gamma_{l_i}(\lambda^{(i)};q,t)\right] \right|_{q=t}
\\&=&\frac{1}{\mathcal{Z}}\left(\prod_{i=l+1}^r \Pi_{a_{i-1},a_i}(A^{(i)},B^{(i)})\right)\cdot\oint\langle F_{l}\langle F_{l+1}\ldots\langle F_{r},F_{r+1} \rangle_{Y^{(r)}} \rangle_{Y^{(l+1)}} \rangle_{Y^{(l)}}\\
&&\times
\left(\prod_{i=[l+1..r]\cap \mathcal{L}}D(W^{(i)};q,t)H(W^{(i)},A^{(i)};q,t)\frac{\Pi_{a_{i-1},a_i}(B^{(i)},W^{(i)})}{\Pi_{a_{i-1},a_i}(B^{(i)},q^{-1}W^{(i)})}\right)\\
&&\left.\times
\left(\prod_{i=[l+1..r]\cap \mathcal{R}}D\left(W^{(i)};
\frac{1}{t},\frac{1}{q}\right)H\left(W^{(i)},A^{(i)};\frac{1}{t},\frac{1}{q}\right)\frac{\Pi_{a_{i-1},a_i}(B^{(i)},W^{(i)})}{\Pi_{a_{i-1},a_i}(B^{(i)},tW^{(i)})}\right)\right|_{q=t};
\end{eqnarray*}
\end{small}

Moreover for $i\in[l+1..r]$,
\begin{itemize}
\item If $a_i=L$,
\begin{eqnarray*}
F_i&=&\Pi_{a_{i-1},a_i}(A^{(i)},Y^{(i-1)})\cdot\Pi_{a_{i-1},a_i}(Y^{(i-1)},Y^{(i)})\cdot
\Pi_{a_{i-1},a_i}(Y^{(i)},B^{(i)})\\
&&\times H(W^{(i)},Y^{(i)};q,t)\frac{\Pi_{a_{i-1},a_i}(Y^{(i-1)},W^{(i)})}{\Pi_{a_{i-1},a_i}(Y^{(i-1)},q^{-1}W^{(i)})}.
\end{eqnarray*}
\item If $a_i=R$,
\begin{eqnarray*}
F_i&=&\Pi_{a_{i-1},a_i}(A^{(i)},Y^{(i-1)})\cdot\Pi_{a_{i-1},a_i}(Y^{(i-1)},Y^{(i)})\cdot
\Pi_{a_{i-1},a_i}(Y^{(i)},B^{(i)})\\
&&\times H\left(W^{(i)},Y^{(i)};\frac{1}{t},\frac{1}{q}\right)\frac{\Pi_{a_{i-1},a_i}(Y^{(i-1)},W^{(i)})}{\Pi_{a_{i-1},a_i}(Y^{(i-1)},tW^{(i)})}.
\end{eqnarray*}
\end{itemize}
and
\begin{eqnarray*}
F_l=F_{r+1}=1.
\end{eqnarray*}
By Lemmas \ref{la5} and \ref{la6}, we obtain
\begin{eqnarray*}
\mathcal{F}_r:=
\langle F_r,F_{r+1} \rangle_{Y^{(r)}}=
\begin{cases}
\frac{\Pi_{a_{r-1},a_r}((A^{(r)},W^{(r)}),Y^{(r-1)})}{\Pi_{a_{r-1},a_r}(q^{-1}W^{(r)},Y^{(r-1)})}&\mathrm{If}\ a_r=L\\
\frac{\Pi_{a_{r-1},a_r}((A^{(r)},W^{(r)}),Y^{(r-1)})}{\Pi_{a_{r-1},a_r}(tW^{(r)},Y^{(r-1)})}&\mathrm{If}\ a_r=R
\end{cases}
\end{eqnarray*}
Then the lemma follows by inductively computing the scalar product 
\begin{eqnarray*}
\langle F_{l}\langle F_{l+1}\ldots\langle F_{r},F_{r+1} \rangle_{Y^{(r)}} \rangle_{Y^{(l+1)}} \rangle_{Y^{(l)}};
\end{eqnarray*}
and applying Lemmas \ref{l32} and \ref{l33}.
\end{proof}

\begin{remark}Using similar arguments, we can also obtain the following formula.
\begin{small}
\begin{eqnarray*}
&&\left.\EE_{\MP_{A,B,\mathcal{P};q,t}|\lambda^{(l)}=\lambda^{(r+1)}=\emptyset}\left[\prod_{i\in[l+1..r]\cap \mathcal{L}} \gamma_{l_i}(\lambda^{(i)};q,t)\right] \left[\prod_{i\in[l+1..r]\cap \mathcal{R}} \gamma_{l_i}\left(\left[\lambda^{(i)}\right]';t,q\right)\right]
\right|_{q=t}\\
&=&\frac{1}{\mathcal{Z}}\oint\ldots\oint \left(\prod_{i<j;i,j\in[l+1..r]}D_{a_i,a_j}(W^{(i)},W^{(j)})\right)\\
&&\times\left(\prod_{i<j;i,j\in[l+1..r]}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}A^{(j)};t,t)\right)^{(-1)^{\delta_{a_i,a_j}-1}}\right)
\\
&&\times\left(\prod_{i=l+1}^{r}D(W^{(i)};t,t)H(W^{(i)},A^{(i)};t,t)\right)\cdot\left(\prod_{i<j;i,j\in[l..r]}\frac{\Pi_{a_i,a_j}(B^{(i+1)},(A^{(j)},W^{(j)}))}{\Pi_{a_i,a_j}(B^{(i+1)},t^{-1}W^{(j)})}\right)
\end{eqnarray*}
\end{small}
where the expectation is with respect to the probability measure on pure dimer configurations of $RYG(l,r,\underline{a},\underline{b})$ as defined in (\ref{ppd}), (\ref{pm});
and
\begin{eqnarray*}
D_{c,d}(Z,W):=\left[\prod_{z_i\in Z}\prod_{w_j\in W}\frac{(1+(-1)^{\delta_{c,d}}t^{-1}w_j z_i^{-1})
(1+(-1)^{\delta_{c,d}}tw_j z_i^{-1})
}{(1+(-1)^{\delta_{c,d}}w_jz_i^{-1})^2}\right]^{(-1)^{\delta_{c,d}}}
\end{eqnarray*}
where $|W^{(i)}|=l_i$, and the integral contours are given by $\{\mathcal{C}_{i,j}\}_{i\in [l+1..r],s\in[l_i]}$ such that
\begin{enumerate}
    \item $\mathcal{C}_{i,s}$ is the integral contour for the variable $w^{(i)}_s\in W^{(i)}$;
    \item $\mathcal{C}_{i,s}$ encloses 0 and every singular point of 
    \begin{eqnarray*}
\prod_{j\in[i..r]}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}A^{(j)};t,t)\right)^{(-1)^{\delta_{a_i,a_j}-1}};
\end{eqnarray*}
but no other singular points of the integrand.
    \item the contour $\mathcal{C}_{i,j}$ is contained in the domain bounded by $t\mathcal{C}_{i',j'}$ whenever $(i,j)<(i',j')$ in lexicographical ordering;
\end{enumerate}
$H(W,X;q,t)$ is given by (\ref{dh}), and $D(W;q,t)$ is given by (\ref{ddf}).
\end{remark}

\begin{lemma}\label{l32}Let $c_1,c_2,c_3\in\{L,R\}$. Let $A,B,Y$ be 3 collections of countably many variables. 
Then we have
\begin{eqnarray*}
\langle \Pi_{c_1,c_2}(A,Y),\Pi_{c_2,c_3}(Y,B) \rangle_Y
=\Pi_{c_1,c_3}(A,B).
\end{eqnarray*}
where if $c_2=L$ (resp.\ $c_2=R$), the scalar product $\langle \cdot,\cdot\rangle$ is with respect to $(q,t)$ (resp.\ $(t,q)$).
\end{lemma}


\begin{lemma}\label{l33}For $i\in[l+2..r]$, and $j\in[i..r]$,
let
\begin{small}
\begin{eqnarray*}
\mathcal{G}:&=&\left\langle \Pi_{a_{i-2},a_{i-1}}\left(\left(Y^{(i-2)},B^{(i-1)}\right),Y^{(i-1)}\right)H\left(W^{(i-1)},Y^{(i-1)};\omega(q,t;a_{i-1})\right), \right.\\
&&\left.\frac{\Pi_{a_{i-1},a_j}((A^{(j)},W^{(j)}),Y^{(i-1)})}{\Pi_{a_{i-1},a_j}(\xi(q,t,a_j)W^{(j)},Y^{(i-1)})}\right\rangle_{Y^{(i-1)}}
\end{eqnarray*}
\end{small}
where in $\mathcal{G}$, the scalar product $\langle\cdot,\cdot \rangle$ is with respect to $(q,t)$ if $a_{i-1}=L$ and with respect to $(t,q)$ if $a_{i-1}=R$; and $\omega$, $\xi$ are defined as in (\ref{do}), (\ref{dx}), respectively.
Assume $q=t$, we have
\begin{enumerate}
\item If $a_{i-1}=a_j=L$;
\begin{small}
\begin{eqnarray*}
\mathcal{G}
=\frac{\Pi_{a_{i-2},a_j}((Y^{(i-2)},B^{(i-1)}),(A^{(j)},W^{(j)}))}
{\Pi_{a_{i-2},a_j}(Y^{(i-2)},B^{(i-1)}),t^{-1}W^{(j)})
}\frac{H(W^{(i-1)},(A^{(j)},W^{(j)}),(t,t))}{
H(W^{(i-1)},t^{-1}W^{(j)},(t,t))
}
\end{eqnarray*}
\end{small}
\item If $a_{i-1}=a_j=R$;
\begin{small}
\begin{eqnarray*}
\mathcal{G}
=\frac{\Pi_{a_{i-2},a_j}((Y^{(i-2)},B^{(i-1)}),(A^{(j)},W^{(j)}))}
{\Pi_{a_{i-2},a_j}(Y^{(i-2)},B^{(i-1)}),tW^{(j)})
}\frac{H(W^{(i-1)},(A^{(j)},W^{(j)}),(t^{-1},t^{-1}))}{
H(W^{(i-1)},tW^{(j)},(t^{-1},t^{-1}))
}
\end{eqnarray*}
\end{small}
\item If $a_{i-1}=L$ and $a_j=R$;
\begin{small}
\begin{eqnarray*}
\mathcal{G}
&=&\frac{\Pi_{a_{i-2},a_j}((Y^{(i-2)},B^{(i-1)}),(A^{(j)},W^{(j)}))}
{\Pi_{a_{i-2},a_j}(Y^{(i-2)},B^{(i-1)}),tW^{(j)})
}\left[\frac{H(W^{(i-1)},-(A^{(j)},W^{(j)}),(t,t))}{
H(W^{(i-1)},-tW^{(j)},(t,t))}\right]^{-1}
\end{eqnarray*}
\end{small}
\item If $a_{i-1}=R$ and $a_j=L$;
\begin{small}
\begin{eqnarray*}
\mathcal{G}
&=&\frac{\Pi_{a_{i-2},a_j}((Y^{(i-2)},B^{(i-1)}),(A^{(j)},W^{(j)}))}
{\Pi_{a_{i-2},a_j}(Y^{(i-2)},B^{(i-1)}),t^{-1}W^{(j)})
}\left[\frac{H(W^{(i-1)},-(A^{(j)},W^{(j)}),(t^{-1},t^{-1}))}{
H(W^{(i-1)},-t^{-1}W^{(j)},(t^{-1},t^{-1}))}\right]^{-1}
.
\end{eqnarray*}
\end{small}
\end{enumerate}
\end{lemma}

\begin{proof}The lemma follows from Lemma \ref{la5} with
\begin{eqnarray*}
d_n&=&\begin{cases}
(-1)^{(n+1)(\delta_{a_{i-2},a_{i-1}}-1)}p_n(Y^{(i-2)},B^{(i-1)})+(1-t^{-n})p_n\left(\frac{q}{W^{(i-1)}}\right)&\mathrm{If}\ a_{i-1}=L;\\
(-1)^{(n+1)(\delta_{a_{i-2},a_{i-1}}-1)}p_n(Y^{(i-2)},B^{(i-1)})+(1-q^{n})p_n\left(\frac{1}{tW^{(i-1)}}\right)&\mathrm{If}\ a_{i-1}=R;
\end{cases}
\\
u_n&=&\begin{cases}
(-1)^{(n+1)}p_n(A^{(j)},W^{(j)})-p_n\left(W^{(j)}\xi(a_j)\right)(-1)^{(n+1)}&\mathrm{If}\ a_{i-1}\neq a_j.\\
\frac{1-t^n}{1-q^n}\left[p_n(A^{(j)},W^{(j)})-p_n\left(W^{(j)}\xi(a_j)\right)\right]&\mathrm{If}\ a_{i-1}=a_j=L.\\
\frac{1-q^{-n}}{1-t^{-n}}\left[p_n(A^{(j)},W^{(j)})-p_n\left(W^{(j)}\xi(a_j)\right)\right]&\mathrm{If}\ a_{i-1}=a_j=R.
\end{cases}
\end{eqnarray*}
and the fact that
\begin{eqnarray*}
\exp\left(-\sum_{k=1}^{\infty}\frac{p_n(X)p_n(Y)}{k}\right)=\prod_{x\in X}\prod_{y\in Y}(1-xy)
\end{eqnarray*}
\end{proof}

\begin{lemma}\label{l35}Let $\mathrm{Pr}$ be the probability measure for pure dimer coverings on the rail-yard graph $RYG(l,r,\underline{a},\underline{b})$ as defined by (\ref{ppd}). Let $M$ be a pure dimer covering on $RYG(l,r,\underline{a},\underline{b})$, and let
\begin{eqnarray*}
\Lambda^{(M)}=\{\lambda^{(M,i)}\}_{i\in[l+1..r]}
\end{eqnarray*}
be the corresponding sequence of partitions.
Then
\begin{small}
\begin{eqnarray*}
&&\mathbb{E}_{\mathrm{Pr}}\left[\prod_{i\in[l+1..r]} \gamma_{l_i}(\lambda^{(M,i)};t,t)\right] 
\\
&=&\oint\ldots\oint 
\left(\prod_{i\leq j;i,j\in[l+1..r],b_j=-}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}\{x_j\};\omega(t,t;a_i))\right)^{(-1)^{\delta_{a_i,a_j}-1}}\right)\\
&&\left(\prod_{i=[l+1..r]}D(W^{(i)};\omega(t,t;a_i))\right)\cdot\left(\prod_{i<j;i,j\in[l..r];b_i=+}\frac{\Pi_{a_i,a_j}(\{x_i\},W^{(j)})}{\Pi_{a_i,a_j}(\{x_i\},\xi(t,t;a_j)W^{(j)})}\right)\\
&&\cdot\left(\prod_{i<j;i,j\in[l+1..r]}T_{a_i,a_j}(W^{(i)},W^{(j)})\right)
\end{eqnarray*}
\end{small}
where $|W^{(i)}|=l_i$, and the integral contours are given by $\{\mathcal{C}_{i,j}\}_{i\in [l+1..r],s\in[l_i]}$ satisfying the condition as described in Lemma \ref{l31}.
\end{lemma}

\begin{proof}Note that
\begin{eqnarray*}
&&H(X,\{0\};q,t)=1;\\
&&\Pi_{a,b}(X,\{0\})=\Pi_{a,b}(\{0\},X)=1.
\end{eqnarray*}
By Lemmas \ref{l31} and \ref{l23}(2), we have
\begin{small}
\begin{eqnarray*}
&&\mathbb{E}_{\mathrm{Pr}}\left[\prod_{i\in[l+1..r]} \gamma_{l_i}(\lambda^{(M,i)};t,t)\right]
\\
&=&\frac{1}{\mathcal{Z}}\oint\ldots\oint 
\left(\prod_{i\leq j;i,j\in[l+1..r],b_j=-}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}\{x_j\};\omega(t,t,a_i))\right)^{(-1)^{\delta_{a_i,a_j}-1}}\right)
\\
&&\times\left(\prod_{i=l+1}^{r}D(W^{(i)};\omega(t,t;a_i))\right)\cdot\left(\prod_{i<j;i,j\in[l..r];b_i=+}\frac{\Pi_{a_i,a_j}(\{x_i\},W^{(j)})}{\Pi_{a_i,a_j}(\{x_i\},\xi(t,t;a_j)W^{(j)})}\right)\\
&&\left(\prod_{i<j;i,j\in[l+1..r]}T_{a_i,a_j}(W^{(i)},W^{(j)})\right)
\left(\prod_{i<j;i,j\in[l..r];b_i=+,b_j=-}\Pi_{a_i,a_j}\left(\{x_i\},\{x_j\}\right)\right)
\end{eqnarray*}
\end{small}
Note also that when $q=t$,
\begin{eqnarray*}
\prod_{i<j;i,j\in[l..r];b_i=+,b_j=-}\Pi_{a_i,a_j}\left(\{x_i\},\{x_j\}\right)=\mathcal{Z}
\end{eqnarray*}
Then the lemma follows.
\end{proof}

\begin{lemma}Let $\bA$, $\bB$ be defined as in Definition \ref{df22}. For each $i\in[l..r]$, let $\Lambda_{A^{(i)}}$, (resp. $\Lambda_{B^{(i+1)}}$) be the algebra of symmetric functions on $A^{(i)}$ (resp. $B^{(i+1)}$) over $\CC$. Define a map 
\begin{eqnarray*}
\phi_0^{(i)}:\Lambda_{A^{(i)}}\otimes \Lambda_{B^{(i+1)}}\rightarrow \CC
\end{eqnarray*}
by
\begin{eqnarray*}
\phi_0^{(i)}(f\otimes g)=f(\mathbf{0})g(\mathbf{0}).
\end{eqnarray*}
Define a formal measure
\begin{eqnarray*}
M^{(i)}:=\phi_0^{(i)}\left(\MP_{\bA,\bB,\mathcal{P},q,t}\right)
\end{eqnarray*}
Then for any sequence of partitions $(\lambda^{(l)},\lambda^{(l+1)},\ldots,\lambda^{(r+1)}\in \YY^{r-l+2}$ in the support of $M^{(i)}$, we have $\lambda^{(i)}=\lambda^{(i+1)}$. Moreover, for all $i\in [l..r]$ let
\begin{eqnarray*}
\widehat{\bA}^{(i)}=\bA\setminus\{A^{(i)}\},\qquad
\widehat{\bB}^{(i+1)}=\bB\setminus\{B^{(i+1)}\}.
\end{eqnarray*}
and
\begin{eqnarray*}
\widehat{\mathcal{L}}^{(i)}=\mathcal{L}\setminus\{i\},\qquad
\widehat{\mathcal{R}}^{(i)}=\mathcal{R}\setminus\{i\};
\end{eqnarray*}
so that $\{\widehat{\mathcal{L}}^{(i)},\widehat{\mathcal{R}}^{(i)}\}$ form a partition $\mathcal{P}'$ of $[l..r]\setminus\{i\}$. Then the restriction of $M^{(i)}$ to 
\begin{eqnarray*}
(\lambda^{(l)},\ldots,\lambda^{(i-1)},\lambda^{(i+1)},\ldots,\lambda^{(r+1)})\in \YY^{(r-l+1)}
\end{eqnarray*}
is the formal MacDonald process $\MP_{\widehat{A}^{(i)},\widehat{B}^{(i)},\mathcal{P}',q,t}$.
\end{lemma}

\begin{proof}Note that
\begin{eqnarray*}
\Psi_{\lambda^{(i)},\lambda^{(i+1)}}(\mathbf{0},\mathbf{0};q,t)=\sum_{\nu\in \YY}P_{\lambda^{(i)}/\nu}(\mathbf{0};q,t)Q_{\lambda^{(i+1)}/\nu}(\mathbf{0};q,t)
\end{eqnarray*}
By Lemma \ref{la1}, we obtain
\begin{eqnarray*}
P_{\lambda^{(i)}/\nu}(\mathbf{0};q,t)=0;
\end{eqnarray*}
unless $\nu=\lambda^{(i)}$. Similarly,
\begin{eqnarray*}
Q_{\lambda^{(i+1)}/\nu}(\mathbf{0};q,t)=0;
\end{eqnarray*}
unless $\nu=\lambda^{(i+1)}$. Therefore $\Psi_{\lambda^{(i)},\lambda^{(i+1)}}(\mathbf{0},\mathbf{0};q,t)\neq 0$ only if $\lambda^{(i)}=\lambda^{(i+1)}$. Similarly we obtain that $\Phi_{\lambda^{(i)},\lambda^{(i+1)}}(\mathbf{0},\mathbf{0};q,t)\neq 0$ only if $\lambda^{(i)}=\lambda^{(i+1)}$.



For any sequence of partitions $(\lambda^{(l)},\lambda^{(l+1)},\ldots,\lambda^{(r+1)})\in \YY^{r-l+2}$ in the support of $M^{(i)}$, one of the following two cases occurs:
\begin{itemize}
    \item if $i\in \mathcal{L}$, then $\Psi_{\lambda^{(i)},\lambda^{(i+1)}}(\mathbf{0},\mathbf{0};q,t)\neq 0$
    \item if $i\in \mathcal{R}$, then $\Phi_{\lambda^{(i)},\lambda^{(i+1)}}(\mathbf{0},\mathbf{0};q,t)\neq 0$
\end{itemize}
It follows that for any sequence of partitions $(\lambda^{(l)},\lambda^{(l+1)},\ldots,\lambda^{(r+1)})\in \YY^{r-l+2}$ in the support of $M^{(i)}$, we have $\lambda^{(i)}=\lambda^{(i+1)}$.
It is straightforward to check from Definition \ref{df22} that the restriction of $M^{(i)}$ to 
\begin{eqnarray*}
(\lambda^{(l)},\ldots,\lambda^{(i-1)},\lambda^{(i+1)},\ldots,\lambda^{(r+1)})\in \YY^{r-l+1}
\end{eqnarray*}
is the formal MacDonald process $\MP_{\widehat{A}^{(i)},\widehat{B}^{(i)},\mathcal{P}',q,t}$.
\end{proof}

\begin{lemma}\label{l36}Let $i_1\leq i_2\leq \ldots\leq i_m\in[l+1..r]$, and let $l_1,\ldots,l_m>0$ be integers. Let
\begin{small}
\begin{eqnarray*}
I:=\{i_1,i_2,\ldots,i_m\}
\end{eqnarray*}
Then
\begin{eqnarray*}
&&\mathbb{E}_{\mathrm{Pr}}\left(\prod_{j\in I} \gamma_{l_j}(\lambda^{(M,i_j)};t,t\right)
\\
&=&\oint\ldots\oint 
\left(\prod_{i\leq j;i\in I,j\in[l+1..r],b_j=-.}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}\{x_j\};\omega(t,t;a_i))\right)^{(-1)^{\delta_{a_i,a_j}-1}}\right)
\\
&&\times\left(\prod_{i\in I}D(W^{(i)};\omega(t,t;a_i))\right)\cdot\left(\prod_{i<j;i\in[l..r];j\in I;b_i=+}\frac{\Pi_{a_i,a_j}(\{x_i\},W^{(j)})}{\Pi_{a_i,a_j}(\{x_i\},\xi(t,t;a_j)W^{(j)})}\right)\\
&&\left(\prod_{1\leq s<j\leq m}T_{a_{i_s},a_{i_j}}\left(W^{(i_s)},W^{(i_j)}\right)\right)
\end{eqnarray*}
\end{small}
where $|W^{(i)}|=l_i$, and the integral contours are given by $\{\mathcal{C}_{i,j}\}_{i\in I,s\in[l_i]}$ satisfying the condition as described in Lemma \ref{l31}.
\end{lemma}

\begin{proof}Take $2(r-l+m)$ auxiliary sets of variables $C= (C_1,...,C_{r-l+m}),D= (D_1,...,D_{r-l+m})$. 

Let $\mathcal{L}_*$ (resp. $\mathcal{R_*}$) be a set consisting of all the indices in $\mathcal{L}$ (resp.\ $\mathcal{R}$) as well as one copy for each $i_j\in I\cap \mathcal{L}, (j\in [m])$ 
(resp.\ $i_j\in I\cap \mathcal{R}, j\in [m]$) and relabeling them. 

More precisely, $\mathcal{L}_*$ and $\mathcal{R}_*$ can be constructed as follows. First of all, we obtain an ordered sequence of integers
\begin{eqnarray}
\label{sq1}
&&l+1,l+2,\ldots, i_1-1,i_1,i_1,i_1+1,\ldots,\\
&&i_2-1,
i_2,i_2,i_2+1,\ldots,i_m-1,i_m,i_m,i_m+1,\ldots,r-1,r\notag
\end{eqnarray}
consisting of $r-l+m$ items in total. (If $i_1=i_2<i_3$, then $i_1$ appears 3 times consecutively in the sequence above, and so on.)

For each $j\in [r-m+l]$, if the $j$th number in the sequence above is in $\mathcal{L}$ (resp.\ $\mathcal{R}$), then put $j$ in $\mathcal{L}_*$ (resp.\ $\mathcal{R}_*$). This way $\{\mathcal{L}_*,\mathcal{R}_*\}$ form a partition $\mathcal{P}_*$ of $[r-l+m]$.



Let 
\begin{eqnarray*}
\mu^{(0)}=\emptyset,\mu^{(1)},\ldots,\mu^{(r-l+m)},\mu^{(r-l+m+1)}=\emptyset
\end{eqnarray*}
be distributed according to 
\begin{eqnarray*}
\left.\MP_{C,D,\mathcal{P}_*,q,t}\right|_{\mu^{(0)}=\mu^{(r-l+m+1)}=\emptyset} 
\end{eqnarray*}
and apply Lemma \ref{l31} to it with the sequence of numbers $r_i,\ i= 1,...,r-l+m$ obtained as follows: 
$r_j\neq 0$ if and only if the $j$th number in the sequence (\ref{sq1}) is equal to the $(j-1)$th number in the sequence. It is straightforward to check that there are exactly $m$ such numbers in the sequence (\ref{sq1}), indexed by
\begin{eqnarray}
i_1-l+1,i_2-l+2,\ldots,i_m-l+m\label{loi}
\end{eqnarray}
For $j\in [m]$, let
\begin{eqnarray*}
r_{i_j-l+j}=l_j.
\end{eqnarray*}


Applying to the result $\phi_0^{(u-1)}$(as in Lemma \ref{l35}) for all indices $1\leq u\leq r-l+m$ in (\ref{loi}), and renaming the remaining sets of variables $C_j,D_j$ into $A^{(i)}$ and $B^{(i)}$, we obtain the lemma.
\end{proof}




\section{Asymptotics}\label{sect:as}

In this section, we study the asymptotics of the moments of the random height functions and prove its Gaussian fluctuation in the scaling limit.

When the index set $I$ in Lemma \ref{l36} consists of a single number $i\in[l+1..r]$ such that $a_i=L$, we have
\begin{eqnarray*}
&&\mathbb{E}_{\mathrm{Pr}}\left[ \gamma_{k}(\lambda^{(M,i)};t,t)\right]
\\
&=&\oint\ldots\oint 
\left(\prod_{j\in[l+1..r],b_j=-;j\geq i}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}\{x_j\};t,t)\right)^{(-1)^{\delta_{a_i,a_j}-1}}\right)
\\
&&\times\left(D(W^{(i)};t,t)\right)\cdot\left(\prod_{j<i;j\in[l..r];b_j=+}\frac{\Pi_{a_i,a_j}(W^{(i)},\{x_j\})}{\Pi_{a_i,a_j}(t^{-1}W^{(i)},\{x_j\})}\right)
\end{eqnarray*}
where $|W^{(i)}|=k$.

Note also that
\begin{eqnarray*}
\frac{\Pi_{a_i,a_j}(W^{(i)},\{x_j\})}{\Pi_{a_i,a_j}(t^{-1}W^{(i)},\{x_j\})}=\left[t^k H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}\{x_j^{-1}\};t,t)\right]^{(-1)^{\delta_{a_i,a_j}}}
\end{eqnarray*}

If $a_i=a_j$, define
\begin{eqnarray}
G_{1,<i}(W^{(i)},x_j,t)&=&\prod_{w_s^{(i)}\in W^{(i)}}\frac{t-w_s^{(i)}x_j}{t(1-w_s^{(i)}x_j)}\label{dg1}\\
G_{1,>i}(W^{(i)},x_j,t)&=&\prod_{w_s^{(i)}\in W^{(i)}}\frac{w_s^{(i)}-x_j}{w_s^{(i)}-tx_j}\label{dg2}
\end{eqnarray}

If $a_i\neq a_j$, define
\begin{eqnarray}
G_{0,<i}(W^{(i)},x_j,t)&=&\prod_{w_s^{(i)}\in W^{(i)}}\frac{t(1+w_s^{(i)}x_j)}{t+w_s^{(i)}x_j}\label{dg3}\\
G_{0,>i}(W^{(i)},x_j,t)&=&\prod_{w_s^{(i)}\in W^{(i)}}\frac{w_s^{(i)}+tx_j}{w_s^{(i)}+x_j}\label{dg4}
\end{eqnarray}
Then we have
\begin{eqnarray}
&&\mathbb{E}_{\mathrm{Pr}}\left[ \gamma_{k}(\lambda^{(M,i)};t,t)\right]
=\oint\ldots\oint 
\left(\prod_{j\in[l+1..r],b_j=-;j\geq i;a_j=a_i}G_{1,>i}(W^{(i)},x_j,t)
\right)\label{ep1}\\
&&\left(\prod_{j\in[l+1..r],b_j=-;j\geq i;a_j \neq a_i}G_{0,>i}(W^{(i)},x_j,t)
\right)\times\left(\prod_{j<i;j\in[l..r];b_j=+;a_i= a_j}G_{1,<i}(W^{(i)},x_j,t)\right)\notag\\
&&\left(\prod_{j<i;j\in[l..r];b_j=+;a_i= a_j}G_{0,<i}(W^{(i)},x_j,t)\right)
\left(D(W^{(i)};t,t)\right)\notag
\end{eqnarray}

Let $\epsilon>0$ be small and positive. 
Under the periodicity Assumption \ref{ap41}, when
\begin{eqnarray*}
\epsilon(r^{(\epsilon)}-l^{(\epsilon)})=(V_m-V_0)+o(1),
\end{eqnarray*}
for each $p\in [m]$, $j\in[n]$ and $i\in[l^{(\epsilon)}..r^{(\epsilon)}]$, let
\begin{eqnarray*}
I^{(\epsilon)}_{j,p,>i,1}&=&\left\{u\in\left[v_{p-1}^{(\epsilon)}+1,v_p^{(\epsilon)}\right]\cap \{n\ZZ+j\}\cap[i..r]:b_u=-,a_u=a_i\right\}\\
I^{(\epsilon)}_{j,p,<i,1}&=&\left\{u\in\left[v_{p-1}^{(\epsilon)}+1,v_p^{(\epsilon)}\right]\cap \{n\ZZ+j\}\cap[l..i-1]:b_u=+,a_u=a_i\right\}\\
I^{(\epsilon)}_{j,p,>i,0}&=&\left\{u\in\left[v_{p-1}^{(\epsilon)}+1,v_p^{(\epsilon)}\right]\cap \{n\ZZ+j\}\cap[i..r]:b_u=-,a_u\neq a_i\right\}\\
I^{(\epsilon)}_{j,p,<i,0}&=&\left\{u\in\left[v_{p-1}^{(\epsilon)}+1,v_p^{(\epsilon)}\right]\cap \{n\ZZ+j\}\cap[l..i-1]:b_u=+,a_u\neq a_i\right\}
\end{eqnarray*}
Similar to Remark \ref{rm42}, one can check the following lemma in a straightforward way.

\begin{lemma}\label{l51}Let $\epsilon>0$, $p\in[m]$, $j\in[n]$, $i\in[l^{(\epsilon))}..r^{(\epsilon)}]$, $S\in\{>i,<i\}$. Suppose that Assumption \ref{ap41} holds. Then at least three of $I^{(\epsilon)}_{j,p,>i,1}$, $I^{(\epsilon)}_{j,p,<i,1}$, 
$I^{(\epsilon)}_{j,p,>i,0}$ and $I^{(\epsilon)}_{j,p,<i,0}$
are empty sets. Moreover,
\begin{enumerate}
\item if $I^{(\epsilon)}_{j,p,>i,1}\neq \emptyset$, then $\zeta_{a_i,-,j,p}=\frac{1}{n}$;
\item if $I^{(\epsilon)}_{j,p,>i,0}\neq \emptyset$, then $\zeta_{\overline{a}_i,-,j,p}=\frac{1}{n}$;
\item if $I^{(\epsilon)}_{j,p,<i,1}\neq \emptyset$, then $\zeta_{a_i,+,j,p}=\frac{1}{n}$;
\item if $I^{(\epsilon)}_{j,p,<i,0}\neq \emptyset$, then $\zeta_{\overline{a}_i,+,j,p}=\frac{1}{n}$;
\end{enumerate}
where
\begin{eqnarray*}
\overline{a}_i=\begin{cases}L,&\mathrm{if}\ a_i=R;\\R&\mathrm{if}\ a_i=L.\end{cases}
\end{eqnarray*}
\end{lemma}

Define
\begin{eqnarray*}
q_{j,p,>i,1}=\max I^{(\epsilon)}_{j,p,>i,1};\qquad
q_{j,p,<i,1}=\min I^{(\epsilon)}_{j,p,<i,1};
\end{eqnarray*}
where we take the convention that the minimum (resp.\ maximum) of an empty set is $\infty$ (resp.\ $-\infty$), and define 
\begin{eqnarray*}
x_{-\infty}^{(\epsilon)}=x_{\infty}^{(\epsilon)}:=0;\ \forall \epsilon\geq 0.
\end{eqnarray*}
Then we obtain
\begin{eqnarray*}
&&\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i;a_j=a_i}G_{1,>i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{c\in[v_{p-1}^{(\epsilon)}+1..v_p^{(\epsilon)}]\cap\{n\ZZ+j\}\cap[i..r^{(\epsilon)}],b_j=-,a_j=a_i}\left[G_{1,>i}
(W^{(i)},e^{-n\epsilon(q_{j,p,>i,1}-c)}x_{q_{j,p,>i,1}}^{(\epsilon)},t)\right]
\end{eqnarray*}

When $\epsilon$ is sufficiently small, we obtain
\begin{eqnarray*}
&&\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i;a_j=a_i}G_{1,>i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\frac{\left(\left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,1}}^{(\epsilon)};e^{-n\epsilon}\right)_{N_{j,p,>i,1}(\epsilon)}}{
\left(t\left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,1}}^{(\epsilon)};e^{-n\epsilon}\right)_{N_{j,p,>i,1}(\epsilon)}
}
\end{eqnarray*}
where for $N\in \ZZ$,
\begin{eqnarray*}
&&(a;q)_{N}=\prod_{i=0}^{N}(1-aq^{i}),\ \forall N\geq 0;\\
&&(a;q)_{\infty}=\prod_{i=0}^{\infty}(1-aq^{i});\\
&&(a;q)_{N}=1,\ \forall N<0;
\end{eqnarray*}
and
\begin{eqnarray*}
N_{j,p,>i,1}(\epsilon)=\left|I_{j,p,>i,1}^{(\epsilon)}\right|-1
\end{eqnarray*}

Similarly, we have
\begin{eqnarray*}
&&\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=+;j< i;a_j=a_i}G_{1,<i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{c\in\left[v_{p-1}^{(\epsilon)}+1..v_p^{(\epsilon)}\right]\cap\{n\ZZ+j\}\cap[l..i-1],b_j=+,a_j=a_i}\left[G_{1,<i}
(W^{(i)},e^{-n\epsilon(c-q_{j,p,<i,1})}x_{q_{j,p,<i,1}}^{(\epsilon)},t)\right]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\frac{\left( t^{-1}w_s^{(i)}x_{q_{j,p,<i,1}}^{(\epsilon)};e^{-n\epsilon}\right)_{N_{j,p,<i,1}(\epsilon)}}{
\left(w_s^{(i)}x_{q_{j,p,<i,1}}^{(\epsilon)};e^{-n\epsilon}\right)_{N_{j,p,<i,1}(\epsilon)}
}
\end{eqnarray*}
with
\begin{eqnarray*}
N_{j,p,<i,1}(\epsilon)=\left|I^{(\epsilon)}_{j,p,<i,1}\right|-1
\end{eqnarray*}

Moreover, let
\begin{eqnarray*}
q_{j,p,>i,0}&=&\max I^{(\epsilon)}_{j,p,>i,0};\qquad
q_{j,p,<i,0}=\min I^{(\epsilon)}_{j,p,<i,0};\\
N_{j,p,>i,1}(\epsilon)&=&\left|I^{(\epsilon)}_{j,p,>i,0}\right|-1;\qquad
N_{j,p,<i,1}(\epsilon)=\left|I^{\epsilon}_{j,p,<i,0}\right|-1.
\end{eqnarray*}

Then
\begin{eqnarray*}
&&\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i;a_j\neq a_i}G_{0,>i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{c\in\left[v_{p-1}^{(\epsilon)}+1..v_p^{(\epsilon)}\right]\cap\{n\ZZ+j\}\cap[i+1..r^{(\epsilon)}],b_j=-,a_j\neq a_i}\left[G_{0,>i}
(W^{(i)},e^{-n\epsilon(q_{j,p,>i,0}-c)}x_{q_{j,p,>i,0}}^{(\epsilon)},t)\right]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\frac{\left( -t \left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,0}}^{(\epsilon)};e^{-n\epsilon}\right)_{N_{j,p,>i,0}(\epsilon)}}{
\left(-\left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,0}}^{(\epsilon)};e^{-n\epsilon}\right)_{N_{j,p,>i,0}(\epsilon)}
}
\end{eqnarray*}

\begin{eqnarray*}
&&\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=+;j< i;a_j\neq a_i}G_{0,<i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{c\in\left[v_{p-1}^{(\epsilon)}+1..v_p^{(\epsilon)}\right]\cap\{n\ZZ+j\}\cap[l^{(\epsilon)}..i-1],b_j=+,a_i\neq a_j}\left[G_{0,<i}
(W^{(i)},e^{-n\epsilon(c-q_{j,p,<i,0})}x_{q_{j,p,<i,0}}^{(\epsilon)},t)\right]\\
&=&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\frac{\left( -w_s^{(i)}x_{q_{j,p,<i,0}}^{(\epsilon)},e^{-n\epsilon}\right)_{N_{j,p,<i,0}(\epsilon)}}{
\left(-t^{-1}w_s^{(i)}x_{q_{j,p,<i,0}}^{(\epsilon)},e^{-n\epsilon}\right)_{N_{j,p,<i,0}(\epsilon)}
}
\end{eqnarray*}



We further make the assumption below:
\begin{assumption}\label{ap52}Suppose
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}-\frac{\log t}{n \epsilon}=\beta>0,
\end{eqnarray*}
where $\beta$ is a positive integer independent of $\epsilon$.
\end{assumption}

Under Assumptions \ref{ap41} and \ref{ap52}, by Lemma \ref{l51}, we obtain as $\epsilon\rightarrow 0$.
\begin{small}
\begin{eqnarray*}
&&\prod_{j\in[l+1..r],b_j=-;j\geq i;a_j=a_i}G_{1,>i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&\sim&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\left(\frac{1-\left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,1}}^{(\epsilon)}}{1-e^{-n\epsilon N_{j,p,>i,1}(\epsilon)}\left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,1}}^{(\epsilon)}}\right)^{-\frac{\log t}{n\epsilon}};
\end{eqnarray*}

\begin{eqnarray*}
&&\prod_{j\in[l+1..r],b_j=+;j< i;a_j=a_i}G_{1,<i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&\sim& \prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\left(\frac{1-t^{-1}w_s^{(i)}x_{q_{j,p,<i,1}}^{(\epsilon)}}{1-e^{-n\epsilon N_{j,p,<i,1}(\epsilon)}t^{-1}w_s^{(i)}x_{q_{j,p,<i,1}}^{(\epsilon)}}\right)^{-\frac{\log t}{n\epsilon}};
\end{eqnarray*}

\begin{eqnarray*}
&&\prod_{j\in[l+1..r],b_j=-;j\geq i;a_j\neq a_i}G_{0,>i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&\sim&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\left(\frac{1+\left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,0}}^{(\epsilon)}}{1+e^{-n\epsilon N_{j,p,>i,0}(\epsilon)}\left[w_s^{(i)}\right]^{-1}x_{q_{j,p,>i,0}}^{(\epsilon)}}\right)^{\frac{\log t}{n\epsilon}};
\end{eqnarray*}

\begin{eqnarray*}
&&\prod_{j\in[l+1..r],b_j=+;j< i;a_j\neq a_i}G_{0,<i}(W^{(i)},x_j^{(\epsilon)},t)]\\
&\sim&\prod_{p=1}^{m}\prod_{j=1}^{n}\prod_{w_s^{(i)}\in W^{(i)}}
\left(\frac{1+t^{-1}w_s^{(i)}x_{q_{j,p,<i,0}}^{(\epsilon)}}{1+e^{-n\epsilon N_{j,p,<i,0}(\epsilon)}w_s^{(i)}x_{q_{j,p,<i,0}}^{(\epsilon)}}\right)^{\frac{\log t}{n\epsilon}};
\end{eqnarray*}
\end{small}
where when $W^{(i)}\in \CC^k$, we choose the branch such that when a complex number approaches the positive real line, its argument approaches 0.

Let $j\in[n]$, $p\in[m]$, and $i^{(\epsilon)}\in[l^{(\epsilon)}..r^{(\epsilon)}]$.
Assume
\begin{eqnarray}
\lim_{\epsilon\rightarrow 0}\epsilon i^{(\epsilon)}=\chi.\label{dci}
\end{eqnarray}
Then, 
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,>i,1}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,>i,1}=\emptyset;\\ n\zeta_{a_i, -,j,p}( V_p-\max\{V_{p-1},\chi\})&\mathrm{otherwise}
\end{cases}
\\
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,<i,1}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,<i,1}=\emptyset;\\ n\zeta_{a_i, +,j,p}(\min\{V_p,\chi\}-V_{p-1})&\mathrm{otherwise}
\end{cases}
\\
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,>i,0}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,>i,0}=\emptyset;\\ n\zeta_{\overline{a}_i, -,j,p}( V_p-\max\{V_{p-1},\chi\})&\mathrm{otherwise}
\end{cases}
\\
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,<i,0}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,<i,0}=\emptyset;\\ n\zeta_{\overline{a}_i, +,j,p}(\min\{V_p,\chi\}-V_{p-1})&\mathrm{otherwise}
\end{cases}
\end{eqnarray*}

By Lemma \ref{l51}, we have
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,>i,1}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,>i,1}=\emptyset;\\  V_p-\max\{V_{p-1},\chi\}&\mathrm{otherwise}
\end{cases}
\\
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,<i,1}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,<i,1}=\emptyset;\\ \min\{V_p,\chi\}-V_{p-1}&\mathrm{otherwise}
\end{cases}
\\
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,>i,0}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,>i,0}=\emptyset;\\ V_p-\max\{V_{p-1},\chi\}&\mathrm{otherwise}
\end{cases}
\\
\lim_{\epsilon\rightarrow 0} n\epsilon N_{j,p,<i,0}(\epsilon)
=\begin{cases}0,&\mathrm{if}\ I^{(\epsilon)}_{j,p,<i,0}=\emptyset;\\ \min\{V_p,\chi\}-V_{p-1}&\mathrm{otherwise}
\end{cases}
\end{eqnarray*}

Moreover, under Assumption \ref{ap52}, it is straightforward to see that
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}t=1.
\end{eqnarray*}

Furthermore, we make the following Assumption
\begin{assumption}\label{aps5}Let $j\in[n]$, $p\in[m]$ be fixed. Let $\chi\in \RR$, and  let $\{i^{(\epsilon)}\in \ZZ\}_{\epsilon>0}$ be a sequence such that (\ref{dci}) holds. Suppose that Assumption \ref{ap41} holds.
\begin{enumerate}
    \item  either for all $\epsilon>0$ and $\chi<V_p$, $I_{j,p,>i^{(\epsilon)},1}^{(\epsilon)}=\emptyset$; or for none of $\epsilon>0$ and $\chi<V_p$, 
    $I_{j,p,>i^{(\epsilon)},1}^{(\epsilon)}=\emptyset$.
    \item  either for all $\epsilon>0$ and $\chi>V_{p-1}$, $I_{j,p,<i^{(\epsilon)},1}^{(\epsilon)}=\emptyset$; or for none of $\epsilon>0$ and $\chi>V_{p-1}$, 
    $I_{j,p,<i^{(\epsilon)},1}^{(\epsilon)}=\emptyset$.
\end{enumerate}
\end{assumption}

Under Assumption \ref{aps5} we have the following corollary.
\begin{corollary}Let $j,p,\chi, \{i^{(\epsilon)}\}_{\epsilon}$ be given as in Assumption \ref{aps5}. Suppose Assumption \ref{aps5} holds. Then
\begin{enumerate}
    \item either for all $\epsilon>0$ and $\chi<V_p$, $I_{j,p,>i^{(\epsilon)},0}^{(\epsilon)}=\emptyset$; or for none of $\epsilon>0$ and $\chi<V_p$, 
    $I_{j,p,>i^{(\epsilon)},0}^{(\epsilon)}=\emptyset$.
    \item  either for all $\epsilon>0$ and $\chi>V_{p-1}$, $I_{j,p,<i^{(\epsilon)},0}^{(\epsilon)}=\emptyset$; or for none of $\epsilon>0$ and $\chi>V_{p-1}$, 
    $I_{j,p,<i^{(\epsilon)},0}^{(\epsilon)}=\emptyset$.
\end{enumerate}
\end{corollary}



\begin{proof}The corollary follows from Assumption \ref{aps5} and Lemma \ref{l51}.
\end{proof}

We use $\mathcal{E}_{j,p,>,1}$ to denote the event that for none of $\epsilon>0$ and $\chi<V_p$, 
    $I_{j,p,>i^{(\epsilon)},1}^{(\epsilon)}=\emptyset$; $\mathcal{E}_{j,p,<,1}$ to denote the event that for none of $\epsilon>0$ and $\chi>V_{p-1}$, 
    $I_{j,p,<i^{(\epsilon)},1}^{(\epsilon)}=\emptyset$; $\mathcal{E}_{j,p,>,0}$ to denote the event that for none of $\epsilon>0$ and $\chi<V_p$, 
    $I_{j,p,>i^{(\epsilon)},0}^{(\epsilon)}=\emptyset$; $\mathcal{E}_{j,p,<,0}$ to denote the event that for none of $\epsilon>0$ and $\chi>V_{p-1}$, 
    $I_{j,p,<i^{(\epsilon)},0}^{(\epsilon)}=\emptyset$.
    
By Assumptions \ref{ap41}, \ref{ap43} and \ref{aps5}, we obtain

\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}x_{q_{j,p,>i,1}}^{(\epsilon)}&=&x_j^{(0,p)}e^{-\max\{V_{p-1},\chi\}}\mathbf{1}_{\mathcal{E}_{j,p,>,1}}=\left[\tau_j\right]^{-1}e^{-\max\{V_{p-1},\chi\}}\mathbf{1}_{\mathcal{E}_{j,p,>,1}}.\\
\lim_{\epsilon\rightarrow 0}x_{q_{j,p,<i,1}}^{(\epsilon)}&=&x_j^{(0,p)}e^{-V_{p-1}}\mathbf{1}_{\mathcal{E}_{j,p,<,1}}=\tau_je^{-V_{p-1}}\mathbf{1}_{\mathcal{E}_{j,p,<,1}}.\\
\lim_{\epsilon\rightarrow 0}x_{q_{j,p,>i,0}}^{(\epsilon)}&=&x_j^{(0,p)}e^{-\max\{V_{p-1},\chi\}}\mathbf{1}_{\mathcal{E}_{j,p,>,0}}=[\tau_j]^{-1}e^{-\max\{V_{p-1},\chi\}}\mathbf{1}_{\mathcal{E}_{j,p,>,0}}..\\
\lim_{\epsilon\rightarrow 0}x_{q_{j,p,<i,0}}^{(\epsilon)}&=&
x_j^{(0)}e^{-V_{p-1}}\mathbf{1}_{\mathcal{E}_{j,p,<,0}}=\tau_je^{-V_{p-1}}\mathbf{1}_{\mathcal{E}_{j,p,<,0}}..
\end{eqnarray*}
   
    
We obtain the following lemma.

\begin{lemma}\label{l55}Suppose Assumptions \ref{ap41}, \ref{ap52} \ref{aps5} and (\ref{dci}) hold. Define
\begin{eqnarray}
\mathcal{G}_{1,>\chi}(w):&=&\prod_{(p\in [m],V_p>\chi)}\prod_{j=1}^{n}
\left(\frac{1-\left[w\tau_j\right]^{-1}e^{V_p}}{1-e^{\max\{V_{p-1},\chi\}}\left[w\tau_j\right]^{-1}}\right)^{ \mathbf{1}_{\mathcal{E}_{j,p,>,1}}}\label{dgs1}\\
\mathcal{G}_{1,<\chi}(w):&=&\prod_{(p\in[m],V_{p-1}<\chi)}\prod_{j=1}^{n}
\left(\frac{1-w e^{-V_{p-1}}\tau_j}{1-e^{-\min\{V_p,\chi\}}w \tau_j}\right)^{ 
\mathbf{1}_{\mathcal{E}_{j,p,<,1}}}\label{dgs2}\\
\mathcal{G}_{0,>\chi}(w):&=&\prod_{(p\in[m],V_p>\chi)}\prod_{j=1}^{n}
\left(\frac{1+e^{\max\{V_{p-1},\chi\}}\left[w\tau_j\right]^{-1}}{1+\left[w\tau_j\right]^{-1}e^{V_p}}\right)^{\mathbf{1}_{\mathcal{E}_{j,p,>,0}}}\label{dgs3}\\
\mathcal{G}_{0,<\chi}(w):&=&\prod_{(p\in[m],V_{p-1}<\chi)}\prod_{j=1}^{n}
\left(\frac{1+e^{-\min\{V_p,\chi\}}w \tau_j}{1+w e^{-V_{p-1}}\tau_j}\right)^{
\mathbf{1}_{\mathcal{E}_{j,p,<,0}}}\label{dgs4}
\end{eqnarray}


Then
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\prod_{j\in [(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=+,j\geq i,a_j=a_i}G_{1,>i}(W,x_j^{(\epsilon)},t)
&=&\left[\prod_{w_s\in W}\mathcal{G}_{1,>\chi}(w_s)\right]^{\beta}
\end{eqnarray*}
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\prod_{j\in[l+1..r],b_j=+;j< i;a_j=a_i}G_{1,<i}(W,x_j^{(\epsilon)},t)
&=& \left[\prod_{w_s\in W}\mathcal{G}_{1,<\chi}(w_s)\right]^{\beta}
\end{eqnarray*}
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\prod_{j\in[l+1..r],b_j=-;j\geq i;a_j=a_i}G_{0,>i}(W,x_j^{(\epsilon)},t)
&=&\left[\prod_{w_s\in W}\mathcal{G}_{0,>\chi}(w_s)\right]^{\beta}
\end{eqnarray*}

\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\prod_{j\in[l+1..r],b_j=+;j< i;a_j=a_i}G_{0,<i}(W,x_j^{(\epsilon)},t)
&=&\left[\prod_{w_s\in W}\mathcal{G}_{0,<\chi}(w_s)\right]^{\beta}
\end{eqnarray*}
Here the logarithmic branches for $\mathcal{G}_{1,>\chi}$, $\mathcal{G}_{1,<\chi}$, $\mathcal{G}_{0,>\chi}$, $\mathcal{G}_{0,<\chi}$ are chosen so that when $z$ approaches the positive real axis, the imaginary part of $\log z$ approaches 0.
\end{lemma}

We next consider the zeros and poles of $\mathcal{G}_{1,>\chi}(w_s)$, $\mathcal{G}_{1,<\chi}(w_s)$,
$\mathcal{G}_{0,>\chi}(w_s)$, $\mathcal{G}_{0,<\chi}(w_s)$.
\begin{enumerate}
\item For $\mathcal{G}_{1,>\chi}(w)$, the condition that the denominator vanishes gives
\begin{eqnarray*}
w\in\left\{e^{\max\{V_{p-1},\chi\}}\tau_j^{-1}\right\}_{V_p>\chi,j\in[n]\ \mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,>,1}}=1}:=\mathcal{R}_{\chi,1,1},\ \forall s\in [k];
\end{eqnarray*}
the condition that the numerator vanishes gives
\begin{eqnarray*}
w\in\left\{e^{V_p}\tau_j^{-1}\right\}_{V_p>\chi,j\in[n]\ \mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,>,1}}=1}:=\mathcal{R}_{\chi,1,2},\ \forall s\in [k];
\end{eqnarray*}
Hence for each $\chi\in(l^{(0)},r^{(0)})$, and $\chi\notin\{V_i\}_{i\in[m]}$, $\mathcal{G}_{1,>\chi}(w)$ has zeros given by $\mathcal{R}_{\chi,1,2}\setminus \mathcal{R}_{\chi,1,1}$
and poles given by $\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}$.
\item For $\mathcal{G}_{1,<\chi}(w)$, the condition that the denominator vanishes gives
\begin{eqnarray*}
w\in\left\{e^{\min\{V_p,\chi\}}\tau_j^{-1}\right\}_{V_{p-1}<\chi,j\in[n]\ \mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,<,1}}=1}:=\mathcal{R}_{\chi,2,1},\ \forall s\in [k]
\end{eqnarray*}
the condition that the numerator vanishes gives
\begin{eqnarray*}
w\in\left\{e^{V_{p-1}}\tau_j^{-1}\right\}_{V_{p-1}<\chi,j\in[n]\ \mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,<,1}}=1}:=\mathcal{R}_{\chi,2,2},\ \forall s\in [k]
\end{eqnarray*}
Hence for each $\chi\in(l^{(0)},r^{(0)})$, and $\chi\notin\{V_i\}_{i\in[m]}$, $\mathcal{G}_{1,<\chi}(w)$ has zeros given by 
$\mathcal{R}_{\chi,2,2}\setminus \mathcal{R}_{\chi,2,1}$
and poles given by $\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}$;
\item For $\mathcal{G}_{0,>\chi}(w)$, the condition that the denominator vanishes gives
\begin{eqnarray*}
w\in\left\{-e^{V_p}\tau_j^{-1}\right\}_{V_p>\chi,j\in[n]\ \mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,>,0}}=1}:=\mathcal{R}_{\chi,3,1},\ \forall s\in [k]
\end{eqnarray*}
the condition that the numerator vanishes gives
\begin{eqnarray*}
w\in\left\{-e^{\max\{V_{p-1},\chi\}}\tau_j^{-1}\right\}_{V_p>\chi,j\in[n]\mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,>,0}}=1}:=\mathcal{R}_{\chi,3,2},\ \forall s\in [k]
\end{eqnarray*}
Hence for each $\chi\in(l^{(0)},r^{(0)})$, and $\chi\notin\{V_i\}_{i\in[m]}$, $\mathcal{G}_{0,>\chi}(w)$ has zeros given by 
$\mathcal{R}_{\chi,3,2}\setminus \mathcal{R}_{\chi,3,1}$
and poles $\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}$.
\item For $\mathcal{G}_{0,<\chi}(w)$, the condition that the denominator vanishes gives
\begin{eqnarray}
w\in\left\{-e^{V_{p-1}}\tau_j^{-1}\right\}_{V_{p-1}<\chi,j\in[n]\ \mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,<,0}}=1}:=\mathcal{R}_{\chi,4,1},\ \forall s\in [k]\label{sg4}
\end{eqnarray}
the condition that the numerator vanishes gives
\begin{eqnarray*}
w\in\left\{-e^{\min\{V_{p},\chi\}}\tau_j^{-1}\right\}_{V_{p-1}<\chi,j\in[n]\ \mathrm{s.t.}\ \mathbf{1}_{\mathcal{E}_{j,p,<,0}}=1}:=\mathcal{R}_{\chi,4,2},\ \forall s\in [k]
\end{eqnarray*}
Hence for each $\chi\in(l^{(0)},r^{(0)})$, and $\chi\notin\{V_i\}_{i\in[m]}$, $\mathcal{G}_{0,>\chi}(w_s)$ has zeros given by $\mathcal{R}_{\chi,4,2}\setminus \mathcal{R}_{\chi,4,1}$, and poles given by $\mathcal{R}_{\chi,4,1}\setminus \mathcal{R}_{\chi,4,2}$.
\end{enumerate}





We have the following asymptotic results.

\begin{proposition}\label{p57}Suppose Assumptions \ref{ap41}, \ref{ap52} \ref{aps5} and (\ref{dci}) hold. Assume
\begin{eqnarray*}
a_{i^{(\epsilon)}}=L;\qquad\forall \epsilon>0.
\end{eqnarray*}
Let $\mathrm{Pr}^{(\epsilon)}$ be the corresponding probability measure. Then
\begin{small}
\begin{eqnarray}
&&\lim_{\epsilon\rightarrow 0}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[ \gamma_{k}(\lambda^{(M,i^{(\epsilon)})};t,t)\right]=\frac{1}{2\pi\mathbf{i}}\oint_{\mathcal{C}} \left[\mathcal{G}_{1,>x}(w)\cdot\mathcal{G}_{1,<x}(w)\cdot\mathcal{G}_{0,>x}(w)\cdot
\mathcal{G}_{0,<x}(w)\right]^{k\beta}\frac{dw}{w}\label{skm}
\end{eqnarray}
\end{small}
where the contour is positively oriented (which may be a union of disjoint simple closed curves) enclosing $0$ and every point in $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]\cup [\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]$, but does not enclose any other zeros or poles of 
$\mathcal{G}_{1,>x}(w)\cdot\mathcal{G}_{1,<x}(w)\cdot\mathcal{G}_{0,>x}(w)\cdot
\mathcal{G}_{0,<x}(w)$; the expression
\begin{eqnarray*}
F^{k\beta}=e^{k\beta\log F}
\end{eqnarray*}
where the branch of $\log F$ is the one which takes positive real values when $F$ is positive and real.
\end{proposition}

\begin{proof}
By (\ref{ep1}), we obtain
\begin{small}
\begin{eqnarray*}
&&\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[ \gamma_{k}(\lambda^{(M,i)};t,t)\right]
=\frac{1}{(2\pi\mathbf{i})^{k}}\oint_{\mathcal{C}_1^{(\epsilon)}}\ldots\oint_{\mathcal{C}_k^{(\epsilon)}} 
\left(\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i;a_j=a_i}G_{1,>i}(W,x_j^{(\epsilon)},t)
\right)\\
&&\left(\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i;a_j \neq a_i}G_{0,>i}(W,x_j^{(\epsilon)},t)
\right)\times\left(\prod_{j<i;j\in[l^{(\epsilon)}..r^{(\epsilon)}];b_j=+;a_i= a_j}G_{1,<i}(W,x_j^{(\epsilon)},t)\right)\notag\\
&&\left(\prod_{j<i;j\in[l^{(\epsilon)}..r^{(\epsilon)}];b_j=+;a_i= a_j}G_{0,<i}(W,x_j^{(\epsilon)},t)\right)\\
&&\times\frac{\sum_{i=1}^k\frac{1 }{w_i}}{\left(w_2-w_1\right)\ldots\left(w_k-w_{k-1}\right)}\prod_{i<j}\frac{(1-\frac{w_i}{w_j})^2}{\left(1-\frac{w_i}{tw_j}\right)\left(1-\frac{tw_i}{w_j}\right)}\prod_{i=1}^kdw_i,
\end{eqnarray*}
\end{small}
where for $1\leq i\leq k$, $\mathcal{C}_i^{(\epsilon)}$ is  the integral contour for $w_i$, and $\mathcal{C}_1^{(\epsilon)},\ldots,\mathcal{C}_k^{(\epsilon)}$ satisfy the conditions as described in Lemma \ref{l31}. As $\epsilon\rightarrow 0$, assume that 
$\mathcal{C}_1^{(\epsilon)},\ldots,\mathcal{C}_k^{(\epsilon)}$ converge to contours $\mathcal{C}_1,\ldots,\mathcal{C}_k$, respectively, such that $\mathcal{C}_1,\ldots\mathcal{C}_k$ are separated from one another and do not cross any of the singularities of the integrand, by Lemma \ref{l55}, we obtain
\begin{eqnarray*}
&&\lim_{\epsilon\rightarrow 0}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[ \gamma_{k}(\lambda^{(M,i)};t,t)\right]\\
&=&\frac{1}{(2\pi\mathbf{i})^{k}}\oint_{\mathcal{C}_1}\ldots\oint_{\mathcal{C}_k} 
\prod_{w_s\in W}\left[\mathcal{G}_{1,>}\chi(w_x)\mathcal{G}_{1,<\chi}(w_s)\mathcal{G}_{0,>\chi}(w_s)\mathcal{G}_{0,<\chi}(w_s)\right]^{\beta}\\
&&\frac{\sum_{i=1}^k\frac{1 }{w_i}}{\left(w_2-w_1\right)\ldots\left(w_k-w_{k-1}\right)}\prod_{i=1}^kdw_i,
\end{eqnarray*}


The (\ref{skm}) follows from Lemmas \ref{lb2} and $\ref{l55}$.
\end{proof}

\begin{theorem}\label{t58}Suppose Assumptions \ref{ap41}, \ref{ap52} \ref{aps5} hold. Let $s$ be a positive integer such that for all $d\in [s]$,
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\epsilon i_d^{(\epsilon)}=\chi_d, 
\end{eqnarray*}
such that
\begin{eqnarray*}
\chi_1\leq \chi_2\leq \ldots\leq \chi_s.
\end{eqnarray*}
Assume that
\begin{eqnarray}
a_{i_1^{(\epsilon)}}=a_{i_2^{(\epsilon)}}=\ldots=a_{i_s^{(\epsilon)}}=L.\label{ael}
\end{eqnarray}
Let $\mathrm{Pr}^{(\epsilon)}$ be the corresponding probability measure. Then
\begin{eqnarray*}
\frac{1}{\epsilon}\left(\gamma_{k_1}(\lambda^{(M,i_1^{(\epsilon)})};t,t)-\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\gamma_{k_1}(\lambda^{(M,i_1^{(\epsilon)})};t,t),\ldots,
\gamma_{k_s}(\lambda^{(M,i_s^{(\epsilon)})};t,t)-\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}
\gamma_{k_s}(\lambda^{(M,i_s^{(\epsilon)})};t,t)
\right)
\end{eqnarray*}
converges in distribution to the centered Gaussian vector 
\begin{eqnarray*}
(Q_{k_1}(\chi_1),\ldots,Q_{k_s}(\chi))
\end{eqnarray*}
as $\epsilon\rightarrow 0$, whose co-variances are
\begin{eqnarray*}
&&\mathrm{Cov}\left[Q_{k_d}(\chi_d),Q_{k_h}(\chi_h)\right]
=\frac{k_dk_hn^2\beta^2}{(2\pi\mathbf{i})^2}\oint\oint dz dw\\
&&\frac{\left[\mathcal{G}_{1,>{\chi_d}}(z)\cdot\mathcal{G}_{1,<{\chi_d}}(z)\cdot\mathcal{G}_{0,>\chi_d}(z)\cdot
\mathcal{G}_{0,<\chi_d}(z)\right]^{k_d\beta}\left[\mathcal{G}_{1,>\chi_h}(w)\cdot\mathcal{G}_{1,<\chi_h}(w)\cdot\mathcal{G}_{0,>\chi_h}(w)\cdot
\mathcal{G}_{0,<\chi_h}(w)\right]^{k_h\beta}}{(z-w)^2}  
\end{eqnarray*}
where
\begin{itemize}
    \item $1\leq d<h\leq s$; and
    \item the $z$-contour is positively oriented enclosing $0$ and every point in $\mathcal{R}_{0,>\chi_d}\cup\mathcal{R}_{1,>\chi_d}]$, but does not enclose any other zeros or poles of 
$\mathcal{G}_{1,>\chi_d}(w)\cdot\mathcal{G}_{1,<\chi_d}(w)\cdot\mathcal{G}_{0,>\chi_d}(w)\cdot
\mathcal{G}_{0,<\chi_d}(w)$; and
    \item the $w$-contour is positively oriented  enclosing $0$ and every point in $\mathcal{R}_{0,>\chi_h}\cup\mathcal{R}_{1,>\chi_h}]$, but does not enclose any other zeros or poles of 
$\mathcal{G}_{1,>\chi_h}(w)\cdot\mathcal{G}_{1,<\chi_h}(w)\cdot\mathcal{G}_{0,>\chi_h}(w)\cdot
\mathcal{G}_{0,<\chi_h}(w)$; and
    \item the $z$-contour and the $w$-contour are disjoint;
    \item the branch of logarithmic function is chosen to take positive real values along the positive real axis.
  \end{itemize}
\end{theorem}
For $j\in[s]$, define
\begin{eqnarray*}
Q_{k_d}^{(\epsilon)}\left(\epsilon i_d^{(\epsilon)}\right):=\frac{1}{\epsilon}\left(\gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})})-\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}
\gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})})
\right)
\end{eqnarray*}
To prove Theorem \ref{t58}, we shall compute the moments of $Q_{k_d}^{(\epsilon)}\left(\epsilon i_d^{(\epsilon)}\right)$ and show that these moments satisfy the Wick's formula in the limit as $\epsilon\rightarrow 0$. We start with the following lemma about covariance.

\begin{lemma}\label{le59}Let $d,h\in[s]$. Under the assumptions of Theorem \ref{t58}, we have
\begin{eqnarray*}
&&\lim_{\epsilon\rightarrow 0}\mathrm{Cov}\left[Q_{k_d}^{(\epsilon)}\left(\epsilon i_d^{(\epsilon)}\right)
Q_{k_h}^{(\epsilon)}\left(\epsilon i_h^{(\epsilon)}\right)\right]=\frac{n^2\beta^2 k_dk_h}{(2\pi\mathbf{i})^2}\oint_{\mathcal{C}_d}\oint_{\mathcal{C}_h} dzdw\\
&&\frac{\left[\mathcal{G}_{1,>{\chi_d}}(z)\cdot\mathcal{G}_{1,<{\chi_d}}(z)\cdot\mathcal{G}_{0,>\chi_d}(z)\cdot
\mathcal{G}_{0,<\chi_d}(z)\right]^{k_d\beta}\left[\mathcal{G}_{1,>\chi_h}(w)\cdot\mathcal{G}_{1,<\chi_h}(w)\cdot\mathcal{G}_{0,>\chi_h}(w)\cdot
\mathcal{G}_{0,<\chi_h}(w)\right]^{k_h\beta}}{(z-w)^2}   
\end{eqnarray*}
where the $z$-contour $\mathcal{C}_d$ and the $w$-contour $\mathcal{C}_h$ satisfy the Assumptions of Theorem \ref{t58}.
\end{lemma}

\begin{proof}
Note that
\begin{eqnarray*}
&&\mathrm{Cov}\left[Q_{k_d}^{(\epsilon)}\left(\epsilon i_d^{(\epsilon)}\right)
Q_{k_h}^{(\epsilon)}\left(\epsilon i_h^{(\epsilon)}\right)\right]
\\
&=&\frac{1}{\epsilon^2}\left[\mathbb{E}_{\mathrm{Pr}}\left( \gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})};t,t)\right)
\left( \gamma_{k_h}(\lambda^{(M,i_h^{(\epsilon)})};t,t)\right)-\mathbb{E}_{\mathrm{Pr}}\left( \gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})};t,t)\right)\mathbb{E}_{\mathrm{Pr}}
\left( \gamma_{k_h}(\lambda^{(M,i_h^{(\epsilon)})};t,t)\right)\right]
\end{eqnarray*}
By Lemma \ref{l36}, we obtain
\begin{eqnarray*}
&&\frac{1}{\epsilon^2}\left[\mathbb{E}_{\mathrm{Pr}}\left( \gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})};t,t)\right)
\left( \gamma_{k_h}(\lambda^{(M,i_h^{(\epsilon)})};t,t)\right)-\mathbb{E}_{\mathrm{Pr}}\left( \gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})};t,t)\right)\mathbb{E}_{\mathrm{Pr}}
\left( \gamma_{k_h}(\lambda^{(M,i_h^{(\epsilon)})};t,t)\right)\right]\\
&=&\frac{1}{\epsilon^2}\oint\oint 
\left(\prod_{i\leq j;i\in \{i_d^{(\epsilon)},i_h^{(\epsilon)}\},j\in[l+1..r],b_j=-.}\left(H(W^{(i)},(-1)^{\delta_{a_i,a_j}-1}\{x_j\};t,t)\right)^{(-1)^{\delta_{a_i,a_j}-1}}\right)
\\
&&\times\left(\prod_{i\in \{i_d^{(\epsilon)},i_h^{(\epsilon)}\}}D(W^{(i)};t,t)\right)\cdot\left(\prod_{i<j;i\in[l..r];j\in \{i_d^{(\epsilon)},i_h^{(\epsilon)}\};b_i=+}\frac{\Pi_{a_i,a_j}(\{x_i\},W^{(j)})}{\Pi_{a_i,a_j}(\{x_i\},q^{-1}W^{(j)})}\right)\\
&&\times\left(T_{L,L}(W^{(i_d^{(\epsilon)})},W^{(i_h^{(\epsilon)})})-1\right)
\end{eqnarray*}
where
\begin{eqnarray}
T_{L,L}(Z,W):=\prod_{z_i\in Z}\prod_{w_j\in W}\frac{\left(z_i-w_j\right)^2}{\left(z_i-t^{-1}w_j \right)
\left(z_i-tw_j \right)\label{tll}
}
\end{eqnarray}
and
\begin{eqnarray*}
\left|W^{(i_d^{(\epsilon)})}\right|=k_d;\qquad\left|W^{(i_h^{(\epsilon)}}\right|=k_h.
\end{eqnarray*}
Note that
\begin{eqnarray*}
&&T_{L,L}(W^{(i_d^{(\epsilon)})},W^{(i_h^{(\epsilon)})})-1\\
&=&\sum_{\left\{\emptyset\neq S\subset [k_d]\times  [k_h] \right\}}\prod_{(u,v)\in S}\frac{(1-t)\left(t^{-1}-1\right)w_{u}^{(i_d^{(\epsilon)})}
w_{v}^{(i_h^{(\epsilon)})}
}{\left(w_{u}^{(i_d^{(\epsilon)})}-t^{-1}
w_{v}^{(i_h^{(\epsilon)})}
\right)
\left(w_{u}^{(i_d^{(\epsilon)})}-t
w_{v}^{(i_h^{(\epsilon)})}
\right)
}
\end{eqnarray*}
Under Assumption \ref{ap52}, we obtain
\begin{eqnarray}
\frac{1}{\epsilon^2}(1-t)(1-t^{-1})=n^2\beta^2+O(\epsilon)\label{lmt}
\end{eqnarray}
Therefore 
\begin{eqnarray*}
&&\frac{1}{\epsilon^2}T_{L,L}(W^{(i_d^{(\epsilon)})},W^{(i_h^{(\epsilon)})})-1\\
&=&n^2\beta^2\left[\sum_{\left\{(u,v)\subset [k_d]\times  [k_h] \right\}}\frac{w_{u}^{(i_d^{(\epsilon)})}
w_{v}^{(i_h^{(\epsilon)})}
}{\left(w_{u}^{(i_d^{(\epsilon)})}-t^{-1}
w_{v}^{(i_h^{(\epsilon)})}
\right)
\left(w_{u}^{(i_d^{(\epsilon)})}-t
w_{v}^{(i_h^{(\epsilon)})}
\right)}\right]+o(\epsilon)
\end{eqnarray*}
By (\ref{dg1})-(\ref{dg4}), we obtain
\begin{small}
\begin{eqnarray*}
&&\frac{1}{\epsilon^2}\mathbb{E}_{\mathrm{Pr}}\left( \gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})};t,t)\right)
\left( \gamma_{k_h}(\lambda^{(M,i_h^{(\epsilon)})};t,t)\right)-\mathbb{E}_{\mathrm{Pr}}\left( \gamma_{k_d}(\lambda^{(M,i_d^{(\epsilon)})};t,t)\right)\mathbb{E}_{\mathrm{Pr}}
\left( \gamma_{k_h}(\lambda^{(M,i_h^{(\epsilon)})};t,t)\right)\\
&=&\frac{n^2\beta^2}{(2\pi\mathbf{i})^{k_d+k_h}}\oint_{\mathcal{C}_{1,1}^{(\epsilon)}}\ldots\oint_{\mathcal{C}_{1,k_d}^{(\epsilon)}} 
\oint_{\mathcal{C}_{2,1}^{(\epsilon)}}\ldots\oint_{\mathcal{C}_{2,k_h}^{(\epsilon)}}
\left(\prod_{i\in \left\{i_d^{(\epsilon)},i_h^{(\epsilon)}\right\},j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i;a_j=a_i}G_{1,>i}(W^{(i)},x_j^{(\epsilon)},t)
\right)\\
&&\left(\prod_{i\in \left\{i_d^{(\epsilon)},i_h^{(\epsilon)}\right\},j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i;a_j \neq a_i}G_{0,>i}(W^{(i)},x_j^{(\epsilon)},t)
\right)\\
&&\left(\prod_{i\in \left\{i_d^{(\epsilon)},i_h^{(\epsilon)}\right\},j<i;j\in[l^{(\epsilon)}..r^{(\epsilon)}];b_j=+;a_i= a_j}G_{1,<i}(W^{(i)},x_j^{(\epsilon)},t)\right)\notag\\
&&\left(\prod_{i\in \left\{i_d^{(\epsilon)},i_h^{(\epsilon)}\right\},j<i;j\in[l^{(\epsilon)}..r^{(\epsilon)}];b_j=+;a_i= a_j}G_{0,<i}(W^{(i)},x_j^{(\epsilon)},t)\right)\\
&&\prod_{\xi\in\{d,h\}}\frac{\sum_{j=1}^{k_{\xi}}\frac{1 }{w_j^{\left(i_{\xi}^{(\epsilon)}\right)}}}{\left(w_2^{\left(i_{\xi}^{(\epsilon)}\right)}-w_1^{\left(i_{\xi}^{
(\epsilon)}\right)}\right)\ldots\left(w_{k_{\xi}}^{\left(i_{\xi}^{(\epsilon)}\right)}-w_{k_{\xi}-1}^{\left(i_{\xi}^{(\epsilon)}\right)}\right)}\prod_{1\leq u<j\leq k_{\xi}}\frac{\left(1-\frac{w_u^{\left(i_{\xi}^{(\epsilon)}\right)}}{w_j^{\left(i_{\xi}^{(\epsilon)}\right)}}\right)^2}{\left(1-\frac{w_u^{\left(i_{\xi}^{(\epsilon)}\right)}}{tw_j^{\left(i_{\xi}^{(\epsilon)}\right)}}\right)\left(1-\frac{tw_u^{\left(i_{\xi}^{(\epsilon)}\right)}}{w_j^{\left(i_{\xi}^{(\epsilon)}\right)}}\right)}\prod_{j=1}^{k_{\xi}}dw_j^{(i_{\xi}^{(\epsilon)})},\\
\\
&&\left[\sum_{\left\{(u,v)\subset [k_d]\times  [k_h] \right\}}\frac{w_{u}^{(i_d^{(\epsilon)})}
w_{v}^{(i_h^{(\epsilon)})}
}{\left(w_{u}^{(i_d^{(\epsilon)})}-t^{-1}
w_{v}^{(i_h^{(\epsilon)})}
\right)
\left(w_{u}^{(i_d^{(\epsilon)})}-t
w_{v}^{(i_h^{(\epsilon)})}
\right)}+o(\epsilon)\right],
\end{eqnarray*}
\end{small}
where for $1\leq i\leq k_d$ (resp.\ $1\leq j\leq k_h$), $\mathcal{C}_{1,i}^{(\epsilon)}$ (resp.\ $\mathcal{C}_{2,j}^{(\epsilon)}$) is  the integral contour for $w_i^{\left(i_d^{(\epsilon)}\right)}$ (resp.\ 
$w_j^{\left(i_h^{(\epsilon)}\right)}$
), and $\mathcal{C}_{1,1}^{(\epsilon)},\ldots,\mathcal{C}_{1,k_d}^{(\epsilon)}$, 
$\mathcal{C}_{2,1}^{(\epsilon)},\ldots,\mathcal{C}_{2,k_h}^{(\epsilon)}$
satisfy the conditions as described in Lemma \ref{l31}. As $\epsilon\rightarrow 0$, assume that 
$\mathcal{C}_1^{(\epsilon)},\ldots,\mathcal{C}_k^{(\epsilon)}$ converge to contours $\mathcal{C}_1,\ldots,\mathcal{C}_k$, respectively, such that $\mathcal{C}_1,\ldots\mathcal{C}_k$ are separated from one another and do not cross any of the singularities of the integrand.


Then by Lemma \ref{lb2}, we have
\begin{small}
\begin{eqnarray*}
&&\lim_{\epsilon\rightarrow 0}\frac{1}{(2\pi\mathbf{i})^{k_h}} 
\oint_{\mathcal{C}_{2,1}^{(\epsilon)}}\ldots\oint_{\mathcal{C}_{2,k_h}^{(\epsilon)}}
\left(\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i_h^{(\epsilon)};a_j=a_i}G_{1,>{i_h^{(\epsilon)}}}(W^{\left(i_h^{(\epsilon)}\right)},x_j^{(\epsilon)},t)
\right)\\
&&\left(\prod_{j\in[(l+1)^{(\epsilon)}..r^{(\epsilon)}],b_j=-;j\geq i_h^{(\epsilon)};a_j \neq a_i}G_{0,>{i_h^{(\epsilon)}}}(W^{\left(i_h^{(\epsilon)}\right)},x_j^{(\epsilon)},t)
\right)\\
&&\left(\prod_{j<i_h^{(\epsilon)};j\in[l^{(\epsilon)}..r^{(\epsilon)}];b_j=+;a_i= a_j}G_{1,<i_h^{(\epsilon)}}(W^{(i_h^{(\epsilon)})},x_j^{(\epsilon)},t)\right)\notag\\
&&\left(\prod_{i\in \left\{i_d^{(\epsilon)},i_h^{(\epsilon)}\right\},j<i;j\in[l^{(\epsilon)}..r^{(\epsilon)}];b_j=+;a_i= a_j}G_{0,<i_h^{(\epsilon)}}(W^{(i_h^{(\epsilon)})},x_j^{(\epsilon)},t)\right)\\
&&\frac{\sum_{j=1}^{k_{h}}\frac{1 }{w_j^{\left(i_{h}^{(\epsilon)}\right)}}}{\left(w_2^{\left(i_{h}^{(\epsilon)}\right)}-w_1^{\left(i_{h}^{
(\epsilon)}\right)}\right)\ldots\left(w_{k_{h}}^{\left(i_{h}^{(\epsilon)}\right)}-w_{k_{h}-1}^{\left(i_{h}^{(\epsilon)}\right)}\right)}\prod_{1\leq u<j\leq k_{h}}\frac{\left(1-\frac{w_u^{\left(i_{h}^{(\epsilon)}\right)}}{w_j^{\left(i_{h}^{(\epsilon)}\right)}}\right)^2}{\left(1-\frac{w_u^{\left(i_{h}^{(\epsilon)}\right)}}{tw_j^{\left(i_{h}^{(\epsilon)}\right)}}\right)\left(1-\frac{tw_u^{\left(i_{h}^{(\epsilon)}\right)}}{w_j^{\left(i_{h}^{(\epsilon)}\right)}}\right)}\prod_{j=1}^{k_{h}}dw_j^{(i_{h}^{(\epsilon)})},\\
\\
&&\left[\sum_{v\in [k_h]}\sum_{u\in [k_d]}\frac{w_{u}^{(i_d^{(\epsilon)})}
w_{v}^{(i_h^{(\epsilon)})}
}{\left(w_{u}^{(i_d^{(\epsilon)})}-t^{-1}
w_{v}^{(i_h^{(\epsilon)})}
\right)
\left(w_{u}^{(i_d^{(\epsilon)})}-t
w_{v}^{(i_h^{(\epsilon)})}
\right)}+o(\epsilon)\right]\\
&=&\frac{k_h}{2\pi \mathbf{i}}\oint_{\mathcal{C}_h}\left[\mathcal{G}_{1,>\chi_h}(w)\cdot 
\mathcal{G}_{1,<\chi_h}(w)\cdot\mathcal{G}_{0,>\chi_h}(w)\cdot \mathcal{G}_{0,<\chi_h}(w)
\right]^{k_h\beta}\\
&&\times\lim_{\epsilon\rightarrow 0}\left[\sum_{u\in [k_d]}\frac{w_{u}^{(i_d^{(\epsilon)})}
w
}{\left(w_{u}^{(i_d^{(\epsilon)})}-w
\right)
\left(w_{u}^{(i_d^{(\epsilon)})}-w
\right)}\right]  \frac{dw}{w}
\end{eqnarray*}
\end{small}
Applying Lemma \ref{lb2} again to integrals over $\mathcal{C}_{1,1}^{(\epsilon)}$, \ldots, $\mathcal{C}_{1,k_d}^{(\epsilon)}$, we obtain the result.
\end{proof}

\begin{lemma}\label{l510}Assume (\ref{ael}) holds. 
\begin{enumerate}
\item Let $s\in \NN$ be odd, and $s\geq 3$. Then
\begin{eqnarray*}
&&\lim_{\epsilon\rightarrow 0}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[\prod_{u=1}^{s}Q_{k_{u}}^{(\epsilon)}\left(\epsilon i_u^{(\epsilon)}\right)\right]=0.
\end{eqnarray*}
\item If $s\in \NN$ is even, then
\begin{eqnarray*}
&&\lim_{\epsilon\rightarrow 0}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[\prod_{u=1}^{s}Q_{k_{u}}^{(\epsilon)}\left(\epsilon i_u^{(\epsilon)}\right)\right]=\sum_{P\in\mathcal{P}_{s}^2}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\prod_{u,v\in P}\left[
Q_{k_{u}}^{(\epsilon)}\left(\epsilon i_u^{(\epsilon)}\right)
Q_{k_{v}}^{(\epsilon)}\left(\epsilon i_v^{(\epsilon)}\right)
\right]
\end{eqnarray*}
where the sum runs over all pairings of $[s]$.
\end{enumerate}
\end{lemma}

\begin{proof}
Note that
\begin{eqnarray*}
&&\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[\prod_{u=1}^{s}Q_{k_{u}}^{(\epsilon)}\left(\epsilon i_u^{(\epsilon)}\right)\right]\\
&=&\frac{1}{\epsilon^s}\sum_{J\subseteq [s]}(-1)^{\left|[s]\setminus J\right|}\left[\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}} \prod_{j\in J}\gamma_{k_j}\left(\lambda^{(M,i_j^{(\epsilon)})}\right)\right]\prod_{u\in[s]\setminus J}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}
\gamma_{k_u}\left(\lambda^{(M,i_u^{(\epsilon)})}\right)
\end{eqnarray*}
When computing $\mathbb{E}\left[\prod_{u=1}^{s}Q_{k_{u}}^{(\epsilon)}\left(\epsilon i_u^{(\epsilon)}\right)\right]$ by Lemma \ref{l36}, in the integrand there is a factor
\begin{eqnarray}
\sum_{J\subseteq [s]}(-1)^{\left|[s]\setminus J\right|}\prod_{u<v;u,v\in[s]\setminus J}T_{L,L}\left(W^{\left(i_u^{(\epsilon)}\right)},W^{\left(i_v^{(\epsilon)}\right)}\right)\label{fct}
\end{eqnarray}
By (\ref{tll}) we obtain
\begin{eqnarray*}
(\ref{fct})&=&\sum_{J\subseteq [s]}(-1)^{\left|[s]\setminus J\right|}\prod_{u<v;u,v\in[s]\setminus J}\prod_{w_j^{(u)}\in W^{\left(i_u^{(\epsilon)}\right)},w_f^{(v)}\in 
W^{\left(i_v^{(\epsilon)}\right)}}\left[1+\frac{(1-t)(t^{-1}-1)w_j^{(u)}w_f^{(v)}}{\left(w_j^{(u)}-t^{-1}w_f^{(v)}\right)
\left(w_j^{(u)}-tw_f^{(v)}\right)}\right
\end{eqnarray*}



Under Assumption \ref{ap52}, (\ref{lmt}) is true, let
\begin{eqnarray*}
\frac{1}{\epsilon^2}\frac{(1-t)(t^{-1}-1)w_j^{(u)}w_f^{(v)}}{\left(w_j^{(u)}-t^{-1}w_f^{(v)}\right)
\left(w_j^{(u)}-tw_f^{(v)}\right)}=C_{u,v,j,f}^{(\epsilon)}
\end{eqnarray*}
where $C_{u,v,j,f}$ is a constant independent of $\epsilon$. As $\epsilon\rightarrow 0$, let
\begin{eqnarray*}
K_J:=\left\{(u,v,j,f):u<v;u,v\in[s]\setminus J, w_j^{(u)}\in W^{\left(i_u^{(\epsilon)}\right)},w_f^{(v)}\in 
W^{\left(i_v^{(\epsilon)}\right)}\right\}
\end{eqnarray*}
Then (\ref{fct}) is equal to
\begin{eqnarray}
\left(\sum_{J\subseteq [s]}(-1)^{\left|[s]\setminus J\right|}\right)+
\left[\sum_{J\subseteq [s]}(-1)^{\left|[s]\setminus J\right|}\left(\sum_{\emptyset\neq H\subseteq K_J}\epsilon^{2|H|}\prod_{(u,v,j,f)\in H}\left(C_{u,v,j,f}^{(\epsilon)}\right)\right)\right]\label{ep5}
\end{eqnarray}
Note that
\begin{eqnarray*}
\sum_{J\subseteq [s]}(-1)^{\left|[s]\setminus J\right|}=0.
\end{eqnarray*}
For each fixed $H\subseteq K_{\emptyset}$, if $H\neq K_{\emptyset}$, let
\begin{eqnarray*}
H_0:=\{u\in[s]: \exists v\in[s]\ \mathrm{and} j,f,\ \mathrm{s.t.} (u,v,j,f)\in H,\ \mathrm{or}\ (v,u,j,f\in H)\}
\end{eqnarray*}
the sum of terms with $\prod_{(u,v,j,f)\in H}\left(C_{u,v,j,f}^{(\epsilon)}\right)$ in (\ref{ep5}) is
\begin{eqnarray}
\epsilon^{2|H|}\prod_{(u,v,j,f)\in H}\left(C_{u,v,j,f}^{(\epsilon)}\right)\sum_{J\in [s]:J\cap H_0=\emptyset}(-1)^{|[s]\setminus J|}\label{smh}
\end{eqnarray}
As long as $H_0\neq S$, the sum of $(-1)^{|[s]\setminus J|}$ over all the subsets of $[s]\setminus H_0$ is 0. Therefore (\ref{ep5}) and (\ref{fct}) are equal to 
\begin{eqnarray*}
\sum_{\emptyset\neq H\subseteq K_{\emptyset}, H_0=[s]}\epsilon^{2|H|}\prod_{(u,v,j,f)\in H}\left(C_{u,v,j,f}^{(\epsilon)}\right)
\end{eqnarray*}
we obtain
\begin{enumerate}
\item If $s$ is odd, as $\epsilon\rightarrow 0$,
\begin{eqnarray*}
\sum_{\emptyset\neq H\subseteq K_{\emptyset}, H_0=[s]}\epsilon^{2|H|}\prod_{(u,v,j,f)\in H}\left(C_{u,v,j,f}^{(\epsilon)}\right)=O(\epsilon^{s+1})
\end{eqnarray*}
therefore
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0}\frac{1}{\epsilon^s}\sum_{J\subseteq [s]}(-1)^{\left|[s]\setminus J\right|}\prod_{u<v;u,v\in[s]\setminus J}T_{L,L}\left(W^{\left(i_u^{(\epsilon)}\right)},W^{\left(i_v^{(\epsilon)}\right)}\right)=0.
\end{eqnarray*}
\item If $s$ is even, as $\epsilon\rightarrow 0$,
\begin{eqnarray*}
&&\sum_{\emptyset\neq H\subseteq K_{\emptyset}, H_0=[s]}\epsilon^{2|H|}\prod_{(u,v,j,f)\in H}\left(C_{u,v,j,f}^{(\epsilon)}\right)\\
&=&\epsilon^{s}\sum_{P\in \mathcal{P}_s^2}\prod_{(u,v)\in \mathcal{P}}\prod_{(j,f):w_j^{(u)}\in W^{\left(i_u^{(\epsilon)}\right)}, 
w_j^{(v)}\in W^{\left(i_v^{(\epsilon)}\right)}}C_{u,v,j,f}^{(\epsilon)}
+ O(\epsilon^{s+1})\\
&=&\epsilon^{s}\sum_{P\in \mathcal{P}_s^2}\prod_{(u,v)\in \mathcal{P}}
\left(\frac{1}{\epsilon^2}T_{L,L}(W^{\left(i_u^{(\epsilon)}\right)}),W^{\left(i_v^{(\epsilon)}\right)}\right)
\end{eqnarray*}
\end{enumerate}
Then the lemma follows.
\end{proof}

\noindent{\textbf{Proof of Theorem \ref{t58}}.} The theorem follows from Lemmas \ref{le59} and \ref{l510}.

\section{Frozen Boundary}\label{sect:fb}

In this section, we prove an integral formula for the Laplace transform of the rescaled height function (see Lemma \ref{l61}), which turns out to be deterministic, as a 2D analog of law of large numbers. We further obtain an the explicit formula for the frozen boundary in the scaling limit. 

For $z\in \CC$ and $\chi\in \RR$, define
\begin{eqnarray}
\mathcal{G}_{\chi}(z):=\mathcal{G}_{1,>{\chi}}(z)\cdot\mathcal{G}_{1,<{\chi}}(z)\cdot\mathcal{G}_{0,>\chi}(z)\cdot
\mathcal{G}_{0,<\chi}(z)\label{dgc}
\end{eqnarray}
 
\begin{lemma}\label{l61}Let $M$ be a random pure dimer covering on the rail yard graph $RYG(l,r,\underline{a},\underline{b})$ with probability distribution given by (\ref{ppd}) and (\ref{pbc}). Let $h_M$ be the height function associated to $M$ as defined in (\ref{dhm}).
Suppose Assumptions \ref{ap41}, \ref{ap52} \ref{aps5} and (\ref{dci}) hold. 
Then the rescaled random height function $\epsilon h_M\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)$ converges, as $\epsilon\rightarrow 0$, to a non-random function $\mathcal{H}(\chi,\kappa)$ such that the Laplace transform of $\mathcal{H}(\chi,\cdot)$ is given by
\begin{small}
\begin{eqnarray}
\int_{-\infty}^{\infty} e^{-n\alpha \kappa}\mathcal{H}(\chi,\kappa)d\kappa=
\lim_{\epsilon\rightarrow 0}\int_{-\infty}^{\infty} e^{-n\alpha \kappa}\epsilon h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)d\kappa=\frac{1}{n^2\alpha^2\pi\mathbf{i}}\oint_{\mathcal{C}} \left[\mathcal{G}_{\chi}(w)\right]^{\alpha}\frac{dw}{w},\label{lph}
\end{eqnarray}
\end{small}
where the contour $\mathcal{C}$ satisfies the conditions of Proposition \ref{p57}. Here 
\begin{eqnarray*}
\left[\mathcal{G}_{\chi}(w)\right]^{\alpha}=e^{\alpha \log [\mathcal{G}_{\chi}(w)]}
\end{eqnarray*}
and the branch of $\log(\zeta) $ is chosen to be real positive when $\zeta$ is real positive.
Note that the right hand side is non-random. 
\end{lemma}

\begin{proof}
By Proposition \ref{p57}, (\ref{hme}) and (\ref{dgm}), let $\frac{\kappa}{\epsilon}=y$, we obtain
\begin{eqnarray*}
&&\lim_{\epsilon\rightarrow 0}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\int_{-\infty}^{\infty} e^{-n\beta \kappa k}\epsilon h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)d\kappa\\
&=&\lim_{\epsilon\rightarrow 0}\epsilon^2\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\int_{-\infty}^{\infty} h_{M}\left(\frac{\chi}{\epsilon},y\right)t^{ky}dy
\\
&=&\lim_{\epsilon\rightarrow 0}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\frac{2\epsilon^2}{(k\log t)^2}\gamma_{k}(\lambda^{(M,i^{(\epsilon)})};t,t)\\
&=&\frac{1}{k^2n^2\beta^2\pi\mathbf{i}}\oint_{\mathcal{C}} \left[\mathcal{G}_{1,>x}(w)\cdot\mathcal{G}_{1,<x}(w)\cdot\mathcal{G}_{0,>x}(w)\cdot
\mathcal{G}_{0,<x}(w)\right]^{k\beta}\frac{dw}{w}
\end{eqnarray*}
To show that the limit, as $\epsilon\rightarrow 0$, of $\int_{-\infty}^{\infty} e^{-n\beta \kappa k}\epsilon h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)d\kappa$, is non-random, it suffices to show that the limit of its variance is 0. Note that
\begin{eqnarray*}
&&\lim_{\epsilon\rightarrow 0}\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[\int_{-\infty}^{\infty} e^{-n\beta \kappa k}\epsilon h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)d\kappa-\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\int_{-\infty}^{\infty} e^{-n\beta \kappa k}\epsilon h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)d\kappa\right]^2\\
&=&\lim_{\epsilon\rightarrow 0}\epsilon^4\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\left[\int_{-\infty}^{\infty} e^{-n\beta \kappa k} h_{M}\left(\frac{\chi}{\epsilon},y\right)d y-\mathbb{E}_{\mathrm{Pr}^{(\epsilon)}}\int_{-\infty}^{\infty} e^{-n\beta \kappa k}\epsilon h_{M}\left(\frac{\chi}{\epsilon},y\right)dy\right]^2\\
&=&\lim_{\epsilon\rightarrow 0}\frac{\epsilon^6}{(k\log t)^4}\mathrm{Var}\left[Q_k^{(\epsilon)}(\chi)\right]\\
&=&0
\end{eqnarray*}
where the last identity follows from Lemma \label{l59} and Assumption \ref{ap52}. Let $\alpha=k\beta$ and consider analytic continuation if necessary, then the lemma follows.
\end{proof}

By (\ref{lph}), we obtain 
\begin{eqnarray}
\int_{-\infty}^{\infty} e^{-n\alpha \kappa}\frac{\partial\mathcal{H}(\chi,\kappa)}{\partial \kappa}d\kappa
&=&n\alpha\int_{-\infty}^{\infty} e^{-n\alpha \kappa}\mathcal{H}(\chi,\kappa)d\kappa
=
\frac{1}{n\alpha\pi\mathbf{i}}\oint_{\mathcal{C}} \left[\mathcal{G}_{\chi}(w)\right]^{\alpha}\frac{dw}{w},\label{dedh}
\end{eqnarray}
for $\alpha>0$.

Let $\mathbf{m}_{\chi}$ be the measure on $(0,\infty)$ defined by 
\begin{eqnarray*}
\mathbf{m}_{\chi}(ds)=\left.e^{-\kappa}\frac{\partial\mathcal{H}(\chi,\kappa)}{\partial \kappa}|d\kappa|\right|_{\kappa=-\ln s}
\end{eqnarray*}
We are particularly interested in the measure $\mathbf{m}_{\chi}$ because its density with respect to the Lebesgue measure on $\RR$ is given by
\begin{eqnarray}
\frac{\mathbf{m}_{\chi}(ds)}{ds}=\left.\frac{\partial\mathcal{H}(\chi,\kappa)}{\partial \kappa}\right|_{\kappa=-\ln s};\label{slht}
\end{eqnarray}
which is exactly the slope of the limiting rescaled height function in the $\kappa$-direction when $s=e^{-\kappa}$.

By (\ref{dedh})
we deduce that for any $\chi\in (l^{(0)},r^{(0)})$
$\int_{0}^{\infty}\mathbf{m}_{\chi}(d s)<\infty$, i.e. $\mathbf{m}_{\chi}(d s)$ is a measure on $\RR$ with finite total mass. Note also that for any positive integer $j$, by (\ref{dedh}) we obtain
\begin{eqnarray*}
\int_0^{\infty} s^{j-1}\mathbf{m}_{\chi}(ds)=\int_{-\infty}^{\infty}e^{-\kappa j}\frac{\partial\mathcal{H}(\chi,\kappa)}{\partial \kappa}d\kappa=\frac{1}{j\pi \mathbf{i}}\oint_{\mathcal{C}}[\mathcal{G}_{\chi}(w)]^{\frac{j}{n}}\frac{dw}{w}
\leq C^j
\end{eqnarray*}
where $C>0$ is a positive constant independent of $j$. Hence we obtain
\begin{eqnarray*}
\int_{2C}^{\infty}\mathbf{m}_{\chi}(ds)\leq \frac{\int_{2C}^{\infty}s^{j-1}\mathbf{m}_{\chi}(ds)}{(2C)^{j-1}}\leq \frac{1}{2C}\left(\frac{1}{2}\right)^j\longrightarrow 0
\end{eqnarray*}
as $j\rightarrow\infty$. Hence we obtain that $\mathbf{m}_{\chi}(ds)$ has compact support in $(0,\infty)$. 

We shall now compute the density of the measure $\mathbf{m}_{\chi}(ds)$ with respect to the Lebesgue measure on $\RR$. It is a classical fact about Stieltjes transform that
\begin{eqnarray*}
\frac{\mathbf{m}_{\chi}(ds)}{ds}
=-\lim_{\epsilon\rightarrow 0+}\frac{1}{\pi}\Im\left(\mathrm{St}_{\mathbf{m}_{\chi}}(s+\mathbf{i}\epsilon)\right)
\end{eqnarray*}
where $\Im$ denotes the imaginary part of a complex number and $\mathrm{St}_{\mathbf{m}_{\chi}}$ is the Stieltjes transform of the measure $\mathbf{m}_{\chi}$, which can be computed as follows: 
for $\zeta\in \CC\setminus\mathrm{supp}(\mathbf{m}_{\chi})$,
\begin{eqnarray}
\mathrm{St}_{\mathbf{m}_{\chi}}(\zeta)&=&\int_{0}^{\infty}\frac{\mathbf{m}_{\chi}(ds)}{\zeta-s}
=\sum_{i=0}^{\infty}\int_{0}^{\infty}\frac{s^i\mathbf{m}_{\chi}(ds)}{\zeta^{i+1}}
=\sum_{j=1}^{\infty}\frac{1}{\zeta^j}\int_0^{\infty}e^{-j\kappa}\frac{\partial\mathcal{H}(\chi,\kappa)}{\partial\kappa}d\kappa\label{stc}
\end{eqnarray}
Again by (\ref{dedh}) we obtain
\begin{eqnarray*}
\mathrm{St}_{\mathbf{m}_{\chi}}(\zeta)=\sum_{j=1}^{\infty}\frac{1}{\zeta^j j\pi\mathbf{i}}
\oint_{\mathcal{C}}[\mathcal{G}_{\chi}(w)]^{\frac{j}{n}}\frac{dw}{w}.
\end{eqnarray*}
When the contour $\mathcal{C}$ satisfies the the conditions given as in Proposition \ref{p57}, we can split $\mathcal{C}$ into a positively oriented simple closed curve $\mathcal{C}_0$ enclosing only 0, and a union $\mathcal{C}_1$ of positively oriented simple closed curves enclosing every point in
\begin{eqnarray*}
\mathcal{R}_{\chi}:=[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]\cup
[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}].
\end{eqnarray*}
By the residue theorem, we obtain that 
\begin{eqnarray*}
\sum_{j=1}^{\infty}\frac{1}{\zeta^j j\pi\mathbf{i}}
\oint_{\mathcal{C}_0}[\mathcal{G}_{\chi}(w)]^{\frac{j}{n}}\frac{dw}{w}=
\sum_{j=1}^{\infty}\frac{2}{\zeta^j j}
[\mathcal{G}_{\chi}(0)]^{\frac{j}{n}}=-2\log\left(1-\frac{[\mathcal{G}_{\chi}(0)]^{\frac{1}{n}}}{\zeta}\right).
\end{eqnarray*}
Moreover,
\begin{eqnarray*}
\sum_{j=1}^{\infty}\frac{1}{\zeta^j j\pi\mathbf{i}}
\oint_{\mathcal{C}_1}[\mathcal{G}_{\chi}(w)]^{\frac{j}{n}}\frac{dw}{w}
=-\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}\log\left(1-\frac{[\mathcal{G}_{\chi}(w)]^{\frac{1}{n}}}{\zeta}\right)\frac{dw}{w}
\end{eqnarray*}
where $\left|\frac{[\mathcal{G}_{\chi}(0)]^{\frac{1}{n}}}{\zeta}\right|<1$ and 
$\max_{\zeta\in\mathcal{C}_1}\left|\frac{[\mathcal{G}_{\chi}(\zeta)]^{\frac{1}{n}}}{\zeta}\right|<1$ to ensure the convergence of Maclaurin series.
Hence we have
\begin{eqnarray*}
\mathrm{St}_{\mathbf{m}_{\chi}}(\zeta)=-2\log\left(1-\frac{[\mathcal{G}_{\chi}(0)]^{\frac{1}{n}}}{\zeta}\right)-\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}\log\left(1-\frac{[\mathcal{G}_{\chi}(w)]^{\frac{1}{n}}}{\zeta}\right)\frac{dw}{w}
\end{eqnarray*}

We would like to get rid of the fractal exponent for the simplicity of computing complex integrals. To that end, we define another function
\begin{eqnarray}
\Theta_{\chi}(\zeta):=-2\log\left(1-\frac{\mathcal{G}_{\chi}(0)}{\zeta^n}\right)-\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}\log\left(1-\frac{\mathcal{G}_{\chi}(w)}{\zeta^n}\right)\frac{dw}{w}\label{dtx}
\end{eqnarray}
Let $\omega=e^{\frac{2\pi\mathbf{i}}{n}}$, then it is straightforward to check that
$
\Theta_{\chi}(\zeta)=\sum_{i=0}^{n-1}\mathrm{St}_{\mathbf{m}_{
\chi}}(\omega^{-i}\zeta)$. Then we obtain
\begin{eqnarray*}
\frac{1}{\pi}\lim_{\epsilon\rightarrow 0+}\Im \Theta_{\chi}(s+\mathbf{i}\epsilon)
=\frac{1}{\pi}\lim_{\epsilon\rightarrow 0+}\sum_{i=0}^{n-1}\Im \mathrm{St}_{\mathbf{m}_{\chi}}(\omega^{-i}(s+\mathbf{i}\epsilon))
\end{eqnarray*}
Since $\mathrm{St}_{\mathbf{m}_{\chi}}(\zeta)$ is continuous in $\zeta$ when $\zeta\in \CC\setminus \mathrm{supp}(\mathbf{m}_{\chi})$, $\mathrm{supp}(\mathbf{m}_{\chi})\in(0,\infty)$, and $\mathrm{St}_{\mathbf{m}_{\chi}}(\overline{\zeta})=
\overline{\mathrm{St}_{\mathbf{m}_{\chi}}(\zeta)}$, we obtain that when $s\in \mathrm{supp}(\mathbf{m}_{\chi})$,
\begin{eqnarray}
\label{dsm2}&&\frac{1}{\pi}\lim_{\epsilon\rightarrow 0+}\Im \Theta_{\chi}(s+\mathbf{i}\epsilon)
=\frac{1}{\pi}\sum_{i=1}^{n-1}\Im \mathrm{St}_{\mathbf{m}_{\chi}}(\omega^{-i}s)+
\frac{1}{\pi}\lim_{\epsilon\rightarrow 0+}\Im\mathrm{St} _{\mathbf{m}_{\chi}}(s+\mathbf{i}\epsilon)\\
&=&\frac{1}{\pi}\lim_{\epsilon\rightarrow 0+}\Im\mathrm{St} _{\mathbf{m}_{\chi}}(s+\mathbf{i}\epsilon)=-\frac{\mathbf{m}_{\chi}(ds)}{ds}\notag
\end{eqnarray}

Hence by (\ref{slht}), to compute the slope of the limiting rescaled height function in the $\kappa$-direction, it suffices to compute 
$-\frac{1}{\pi}\lim_{\epsilon\rightarrow 0+}\Im \Theta_{\chi}(s+\mathbf{i}\epsilon)$ when $s=e^{-\kappa}$.

By (\ref{dtx}) we obtain
\begin{small}
\begin{eqnarray}
\label{ctx}\Theta_{\chi}(\zeta):&=&-2\log\left(1-\frac{\mathcal{G}_{\chi}(0)}{\zeta^n}\right)-\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}\log\left(1-\frac{\mathcal{G}_{\chi}(w)}{\zeta^n}\right)d\log w\\
&=&-2\log\left(1-\frac{\mathcal{G}_{\chi}(0)}{\zeta^n}\right)-\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}d\left[\log\left(1-\frac{\mathcal{G}_{\chi}(w)}{\zeta^n}\right)\log w\right]\notag\\
&&-\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}
\frac{\mathcal{G}'_{\chi}(w)\log w}{\zeta^n-\mathcal{G}_{\chi}(w)}dw\notag
\end{eqnarray}
\end{small}

To compute the contour integral above, we need to consider the root of the following equation in $w$:
\begin{eqnarray}
\mathcal{G}_{\chi}(w)=\zeta^n;\label{eeq}
\end{eqnarray}
in particular, the roots of (\ref{eeq}) that are enclosed by the contour $\mathcal{C}_1$. Recall that $\mathcal{C}_1$ is the union of positively oriented simple closed curves enclosing every point in $\mathcal{R}_{\chi}$, but no other zeros or poles of $\mathcal{G}_{\chi}$. We may assume
\begin{eqnarray*}
\mathcal{C}_1:=\cup_{\xi\in \mathcal{R}}\mathcal{C}_{\xi};
\end{eqnarray*}
where $\mathcal{C}_{\xi}$ is a positively oriented simple closed curve enclosing $\xi$ but no other zeros or poles of $\mathcal{G}_{\chi}$.

When $\zeta\rightarrow \infty$, zeros of (\ref{eeq}) will approach poles of $\mathcal{G}_{\chi}$. For each $\xi\in \mathcal{R}_{\chi}$, let $w_{\xi,\chi}(\zeta)$ be a root of (\ref{eeq}) such that $\lim_{\zeta\rightarrow\infty}w_{\xi,\chi}(\zeta)=\xi$.

When $|\zeta|$ is sufficiently large, $w_{\xi,\chi}(\zeta)$ is enclosed by $\mathcal{C}_{\xi}$. Enclosed by each $\mathcal{C}_{\xi}$, there is exactly one zero and one pole for $1-\frac{\mathcal{G}_{\chi}(w)}{\zeta^n}$, hence
\begin{eqnarray}
\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}d\left[\log\left(1-\frac{\mathcal{G}_{\chi}(w)}{\zeta^n}\right)\log w\right]=0.\label{ctx1}
\end{eqnarray}
By computing residues at each $w_{\xi,\chi}(\zeta)$ and $\xi$, we obtain 
\begin{eqnarray}
-\frac{1}{\pi \mathbf{i}}\oint_{\mathcal{C}_1}
\frac{\mathcal{G}'_{\chi}(w)\log w}{\zeta^n-\mathcal{G}_{\chi}(w)}dw
=2\sum_{\xi\in \mathcal{R}_{\chi}}\left[\log w_{\xi,\chi}(\zeta)-\log\xi\right]\label{ctx2}
\end{eqnarray}

We may further assume that the edge weights of the graph satisfy the following conditions:

\begin{assumption}\label{ap62}
\begin{itemize}
    \item Between each two consecutive points in $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]
    \cup[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]$, there is a unique point in $[\mathcal{R}_{\chi,1,2}\setminus \mathcal{R}_{\chi,1,1}]
    \cup[\mathcal{R}_{\chi,3,2}\setminus \mathcal{R}_{\chi,3,1}]$; and
    \item let
\begin{eqnarray*}
c_1=\max[\mathcal{R}_{2,1}\setminus \mathcal{R}_{2,2}]>0;\qquad
c_2=\min[\mathcal{R}_{2,1}\setminus \mathcal{R}_{2,2}]>0;\\
c_3=\max[\mathcal{R}_{4,1}\setminus \mathcal{R}_{4,2}]<0;\qquad
c_4=\min[\mathcal{R}_{4,1}\setminus \mathcal{R}_{4,2}]<0;
\end{eqnarray*}
    between each two consecutive points in $[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]
    \cup[\mathcal{R}_{\chi,4,1}\setminus \mathcal{R}_{\chi,4,2}]$ except $c_3,c_2$, there is a unique point in $[\mathcal{R}_{\chi,2,2}\setminus \mathcal{R}_{\chi,2,1}]
    \cup[\mathcal{R}_{\chi,4,2}\setminus \mathcal{R}_{\chi,4,1}]$; moreover, there is a unique point in $\{[\mathcal{R}_{\chi,2,2}\setminus \mathcal{R}_{\chi,2,1}]
    \cup[\mathcal{R}_{\chi,4,2}\setminus \mathcal{R}_{\chi,4,1}]\}\cap\{(-\infty,c_4)\cup (c_1,\infty)\}$.
\item let 
\begin{eqnarray*}
c_5=\max[\mathcal{R}_{1,1}\setminus \mathcal{R}_{1,2}]>0;\qquad
c_6=\min[\mathcal{R}_{3,1}\setminus \mathcal{R}_{3,2}]<0;
\end{eqnarray*}
then
\begin{eqnarray*}
c_3<c_6<0<c_5<c_2.
\end{eqnarray*}
\end{itemize}
\end{assumption}


In the following assumption, we give explicit conditions on graph parameters to guarantee Assumption \ref{ap62}.

\begin{assumption}\label{ap64}
Let $i,j$ be positive integers satisfying
\begin{itemize}
    \item $\epsilon i\in (V_{p_1-1},V_{p_1})$, $\epsilon j\in (V_{p_2}-1,V_{p_2})$ and 
    \item $i_*\in[n]$ such that $[(i-i_*)\mod n]=0$; and
    \item $j_*\in[n]$ such that $[(j-j_*)\mod n]=0$;
    \item $i_*\neq j_*$;
\end{itemize}
If furthermore 
\begin{enumerate}
\item
\begin{itemize}
    \item $b_i^{(\epsilon)}=-$ and $b_j^{(\epsilon)}=+$ and $p_1>p_2$
\end{itemize}
then we have
\begin{eqnarray*}
\tau_{i_*}^{-1}\tau_{j_*}<e^{V_{p_2}-V_{p_1-1}}\mathrm{and}\ \tau_{i*}^{-1}\tau_{j_*}\leq e^{V_{p_2-1}-V_{p_1}}
\end{eqnarray*}


\item 
\begin{itemize}
    \item $b_i^{(\epsilon)}=b_j^{(\epsilon)}$; and 
    \item $a_i^{(\epsilon)}=a_j^{(\epsilon)}$; and
    \item $\tau_{i_*}\geq \tau_{j_*}$
\end{itemize}
then we have
\begin{eqnarray*}
\tau_{i*}^{-1}\tau_{j_*}\leq e^{V_{p_2-1}-V_{p_1}}\ 
\end{eqnarray*}


\end{enumerate}
\end{assumption}


\begin{lemma}\label{l65}Suppose that either Assumption \ref{ap62} or Assumption \ref{ap64} holds. Then for any $s\in \RR$, the equation in $w$
\begin{eqnarray}
\mathcal{G}_{\chi}(w)=s^n,\label{ceqn}
\end{eqnarray}
has at most one pair of complex conjugate roots.
\end{lemma}

\begin{proof}We first show that the conclusion of the lemma is true when Assumption \ref{ap62} holds. We then show that Assumption \ref{ap64} implies Assumption \ref{ap62}. Then the lemma follows.

Now suppose that Assumption \ref{ap62} holds. Note that 
\begin{eqnarray*}
\mathcal{G}_{\chi}(w)=C\frac{\prod_{b_j\in [\mathcal{R}_{\chi,1,2}\setminus \mathcal{R}_{\chi,1,1}]
    \cup[\mathcal{R}_{\chi,3,2}\setminus \mathcal{R}_{\chi,3,1}]\cup[\mathcal{R}_{\chi,2,2}\setminus \mathcal{R}_{\chi,2,1}]
    \cup[\mathcal{R}_{\chi,4,2}\setminus \mathcal{R}_{\chi,4,1}]}(w-b_j)}{\prod_{a_i\in [\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]
    \cup[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]\cup[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]
    \cup[\mathcal{R}_{\chi,4,1}\setminus \mathcal{R}_{\chi,4,2}]}(w-a_i)}
\end{eqnarray*}
where $C\neq 0$ is an absolute constant. Assume that 
\begin{eqnarray*}
&&[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]
    \cup[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]\cup[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]
    \cup[\mathcal{R}_{\chi,4,1}\setminus \mathcal{R}_{\chi,4,2}]=
    \{a_1<a_2<\ldots <a_k\}\\
&&[\mathcal{R}_{\chi,1,2}\setminus \mathcal{R}_{\chi,1,1}]
    \cup[\mathcal{R}_{\chi,3,2}\setminus \mathcal{R}_{\chi,3,1}]\cup[\mathcal{R}_{\chi,2,2}\setminus \mathcal{R}_{\chi,2,1}]
    \cup[\mathcal{R}_{\chi,4,2}\setminus \mathcal{R}_{\chi,4,1}]=
    \{b_1<b_2<\ldots <b_k\}
\end{eqnarray*}
If $a_i,a_{i+1}\in \mathcal{R}_{\chi,1,2}\setminus \mathcal{R}_{\chi,1,1}]
    \cup[\mathcal{R}_{\chi,3,2}\setminus \mathcal{R}_{\chi,3,1}]$ is a pair of consecutive points, by Assumption \ref{ap62}, there exists a unique $b_j\in (a_i,a_{i+1})$ where $j\in[k]$. It is straightforward to check that one of the following two cases occurs
    \begin{itemize}
        \item $\lim_{w\rightarrow a_i+}\mathcal{G}_{\chi}(w)=-\infty$ and $\lim_{w\rightarrow a_{i+1}-}\mathcal{G}_{\chi}(w)=+\infty$; or
        \item $\lim_{w\rightarrow a_i+}\mathcal{G}_{\chi}(w)=+\infty$ and $\lim_{w\rightarrow a_{i+1}-}\mathcal{G}_{\chi}(w)=-\infty$.
    \end{itemize}
By continuity $\mathcal{G}_{\chi}(w)$ is a surjection from $(a_i,a_{i+1})$ onto $(-\infty,\infty)$. Hence for each $s\in \RR$, 
$\mathcal{G}_{\chi}(w)=s$ has at least one root in $(a_i,a_{i+1})$. 

If $a_p,a_{p+1}\in \mathcal{R}_{\chi,2,2}\setminus \mathcal{R}_{\chi,2,1}]
    \cup[\mathcal{R}_{\chi,4,2}\setminus \mathcal{R}_{\chi,4,1}]$ is a pair of consecutive points, similar arguments as above shows that for each $s\in \RR$, 
$\mathcal{G}_{\chi}(w)=s$ has at least one root in $(a_p,a_{p+1})$.

Note that all the $i$'s and $p$'s above give us at least $k-3$ real roots of (\ref{ceqn}).

The following cases might occur
\begin{enumerate}
    \item $s^n=C$. In this case the equation (\ref{ceqn}) in $w$ has at most $k-1$ roots in the complex plane. But we already have $(k-3)$ real roots, hence in this case (\ref{ceqn}) has at most one pair of complex conjugate roots.
    \item $s^n\neq C$. In this case the equation (\ref{ceqn}) in $w$ has exactly $k$ roots in the complex plane. Again it is straightforward to check that one of the following two cases occurs
    \begin{itemize}
        \item $\lim_{w\rightarrow a_k+}\mathcal{G}_{\chi}(w)=-\infty$ and $\lim_{w\rightarrow a_{1}-}\mathcal{G}_{\chi}(w)=+\infty$; or
        \item $\lim_{w\rightarrow a_k+}\mathcal{G}_{\chi}(w)=+\infty$ and $\lim_{w\rightarrow a_{1}-}\mathcal{G}_{\chi}(w)=-\infty$.
    \end{itemize}
    By continuity $\mathcal{G}_{\chi}(w)$ is a surjection from $(-\infty,a_{1})\cup(a_p,\infty)$ onto $(-\infty,C)\cup(C,\infty)$. Hence for each $s\neq C$, 
$\mathcal{G}_{\chi}(w)=s$ has at least one root in $(-\infty,a_{1})\cup(a_p,\infty)$. Since (\ref{ceqn}) at least $(k-2)$ real roots, we deduce that it has at most one pair of complex conjugate roots.
\end{enumerate}

It is straightforward to check that Assumption \ref{ap64} implies Assumption \ref{ap62}. Then the proof is complete.
\end{proof}

\begin{lemma}\label{l66}Suppose Assumptions \ref{ap41}, \ref{ap52} \ref{aps5} and (\ref{dci}) hold. Suppose that either Assumption \ref{ap62} or Assumption \ref{ap64} holds. Let $\mathcal{H}(\chi,\kappa)$ be the limit of the rescaled height function of pure dimer coverings on rail yard graphs as $\epsilon\rightarrow 0$, as obtained in Lemma \ref{l61}. Assume that equation (\ref{ceqn}) in $w$ with $s=e^{-\kappa}$ has exactly one pair of nonreal conjugate roots and $\mathcal{R}_{\chi}\neq \emptyset$.
\begin{enumerate}
    \item If $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]=\emptyset$, then 
    \begin{eqnarray*}
    \mathcal{G}_{\chi}(0)<e^{-n\kappa}.
    \end{eqnarray*}
    \item If $[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]=\emptyset$, then 
    \begin{eqnarray*}
    \mathcal{G}_{\chi}(0)>e^{-n\kappa}.
    \end{eqnarray*}
\end{enumerate}
\end{lemma}

\begin{proof}We only prove part (1) here; part (2) can be proved using exactly the same technique. Assume $\mathcal{R}_{\chi}\neq \emptyset$ and $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]=\emptyset$, then $[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]\neq \emptyset$. Let
\begin{eqnarray}
B_1:=\max[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]<0.\label{db1}
\end{eqnarray}
\begin{itemize}
\item If $[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]\neq  \emptyset$, let
\begin{eqnarray}
B_2:=
\min[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]>0.\label{db21}
\end{eqnarray}
\item If $[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]= \emptyset$, let
\begin{eqnarray}
B_2:=+\infty.\label{db22}
\end{eqnarray}
\end{itemize}
Then by (\ref{dgs1})-(\ref{dgs4}) and (\ref{dgc}) we have
\begin{eqnarray}
\lim_{u\rightarrow B_1+}\mathcal{G}_{\chi}(u)=-\infty\label{lsb1}
\end{eqnarray}
Let $K$ be the total number of complex roots (counting multiplicities) in $w$ of $\mathcal{G}_{\chi}(w)=e^{-n\kappa}$. 
From the proof of Lemma \ref{l65}, we see that there are at least $K-2$ real roots of $\mathcal{G}_{\chi}(w)=e^{-n\kappa}$ in $(-\infty,B_1)\cup (B_2,+\infty)$. If $\mathcal{G}_{\chi}(0)\geq e^{-n\kappa}$, by (\ref{lsb1}) and the continuity of $\mathcal{G}_{\chi}(w)$ when $w\in (B_1,B_2)$, we deduce that there is at least one real root of $\mathcal{G}_{\chi}(w)=e^{-n\kappa}$ in $(B_1,0]$, which contradicts the assumption that $\mathcal{G}_{\chi}(w)=e^{-n\kappa}$ has exactly one pair of nonreal conjugate roots. Then part (1) of the lemma follows.
\end{proof}



Then we have the following proposition:
\begin{proposition}\label{p67}Suppose Assumptions \ref{ap41}, \ref{ap52} \ref{aps5} and (\ref{dci}) hold. Suppose that either Assumption \ref{ap62} or Assumption \ref{ap64} holds. Let $\mathcal{H}(\chi,\kappa)$ be the limit of the rescaled height function of pure dimer coverings on rail yard graphs as $\epsilon\rightarrow 0$, as obtained in Lemma \ref{l61}. Assume that equation (\ref{ceqn}) in $w$ with $s=e^{-\kappa}$ has exactly one pair of nonreal conjugate roots and $\mathcal{R}_{\chi}\neq \emptyset$ and $\mathcal{G}_{\chi}(0)\neq e^{-n\kappa}$.  
Then
\begin{eqnarray}
\frac{\partial \mathcal{H}(\chi,\kappa)}{\partial \kappa}\label{mde}
=2-\frac{2\mathrm{arg}(\mathbf{w}_{+})}{\pi}
\end{eqnarray}
where $\mathbf{w}_+$ is the unique nonreal root of $\mathcal{G}_{\chi}(w)=e^{-n\kappa}$ in the upper half plane, and the branch of $\mathrm{arg}(\cdot)$ is chosen such that $\mathrm{arg}(\mathbf{w}_{+})\in(0,\pi)$.
\end{proposition}

\begin{proof}By (\ref{slht}) (\ref{dsm2}), we obtain
\begin{eqnarray*}
\frac{\partial \mathcal{H}(\chi,\kappa)}{\partial \kappa}
=-\left.\lim_{\epsilon\rightarrow 0+}\frac{1}{\pi}\Im \Theta_{\chi}(s+\mathbf{i}\epsilon)\right|_{s=e^{-\kappa}}
\end{eqnarray*}
By (\ref{ctx}), (\ref{ctx1}), (\ref{ctx2}), we obtain
\begin{eqnarray}
\frac{\partial \mathcal{H}(\chi,\kappa)}{\partial \kappa}
=2\mathbf{1}_{\mathcal{G}_{\chi}(0)>e^{-n\kappa}}-\frac{2}{\pi}\sum_{\xi\in \mathcal{R}_{\chi}}\left[\mathrm{arg}(w_{\xi,\chi}(e^{-\kappa}))-\mathrm{arg}(\xi)\right]\label{phk}
\end{eqnarray}
where the branch of $\mathrm{arg}$ is chosen to have range $(-\pi, \pi]$. Hence we have
\begin{eqnarray*}
\mathrm{arg}(\xi)=\begin{cases}0&\mathrm{if}\ \xi>0;\\ 1&\mathrm{otherwise}.\end{cases}
\end{eqnarray*}
Under the assumption that $\mathcal{R}_{\chi}\neq \emptyset$ and $\mathcal{G}_{\chi}(0)\neq e^{-n\kappa}$, the following cases might occur:
\begin{enumerate}
\item 
$[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]\neq \emptyset$. In this case
the number of negative poles in $\mathcal{R}_{\chi}$ is exactly $|\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}|$. From the proof of Lemma \ref{l65} we see that  there are at least $|\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}|-1$ negative real roots in $\{w_{\xi,\chi}(e^{-\kappa})\}_{\xi\in \mathcal{R}_{\chi}}$.
Let $B_1$ be defined as in (\ref{db1}).
\begin{enumerate}
\item If $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]\neq \emptyset$, let
\begin{eqnarray*}
B_2:=
\min[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]>0.
\end{eqnarray*}
\item If $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]= \emptyset$ and If $[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]\neq  \emptyset$, let $B_2$ be defined as in (\ref{db21}).
\item If $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]= \emptyset$ and If $[\mathcal{R}_{\chi,2,1}\setminus \mathcal{R}_{\chi,2,2}]= \emptyset$, let $B_2$ be defined as in (\ref{db22}).
\end{enumerate}
Then by (\ref{dg1})-(\ref{dg4}) and (\ref{dgc}) we have (\ref{lsb1})
The following cases might occur
\begin{enumerate}
    \item $\mathcal{G}_{\chi}(0)>e^{-\kappa}$: then there exists a unique root in $\{w_{\xi,\chi}(e^{-\kappa})\}_{\xi\in \mathcal{R}_{\chi}}\cap (B_1,B_2)$ which is negative; in this case the argument of each negative pole in $\mathcal{R}_{\chi}$ cancels with an argument of a unique negative root in $\{w_{\xi,\chi}(e^{-\kappa})\}_{\xi\in\mathcal{R}_{\chi}}$;
    \item $\mathcal{G}_{\chi}(0)<e^{-\kappa}$: then there exists no root in $\{w_{\xi,\chi}(e^{-\kappa})\}_{\xi\in \mathcal{R}_{\chi}}\cap (B_1,0)$; in this case there is a unique negative pole in $\mathcal{R}_{\chi}$ whose argument cannot  cancels with an argument of a unique negative root in $\{w_{\xi,\chi}(e^{-\kappa})\}_{\xi\in\mathcal{R}_{\chi}}$;
\end{enumerate}
in either case we have (\ref{mde}) holds.
\item $[\mathcal{R}_{\chi,1,1}\setminus \mathcal{R}_{\chi,1,2}]
\neq\emptyset$ and 
$[\mathcal{R}_{\chi,3,1}\setminus \mathcal{R}_{\chi,3,2}]= \emptyset$. In this case there are neither negative poles in $\mathcal{R}_{\chi}$ nor negative real roots in $\{w_{\xi,\chi}(e^{-\kappa})\}_{\xi\in \mathcal{R}_{\chi}}$.
By Lemma \ref{l66}, we have $\mathcal{G}_{\chi}(0)>0$. Then (\ref{mde}) follows from (\ref{phk}).
\end{enumerate}
\end{proof}

\begin{definition}Let $\{RYG(l^{(\epsilon)},r^{(\epsilon)},\underline{a}^{(\epsilon)},\underline{b}^{(\epsilon)})\}_{\epsilon>0}$ be a collection of rail-yard graphs satisfying Assumptions \ref{ap41}, \ref{ap52} \ref{aps5} and (\ref{dci}). Suppose that either Assumption \ref{ap62} or Assumption \ref{ap64} holds. Let $\mathcal{H}(\chi,\kappa)$ be the limit of the rescaled height function of pure dimer coverings on rail yard graphs as $\epsilon\rightarrow 0$, as obtained in Lemma \ref{l61}. The liquid region for the limit shape of pure dimer coverings on these rail yard graphs as $\epsilon\rightarrow 0$ is defined to be
\begin{eqnarray*}
\mathcal{L}:=\left\{(\chi,\kappa)\in(l^{(0)},r^{(0)})\times \RR:\frac{\partial \mathcal{H}}{\partial \kappa}(\chi,\kappa)\in (0,2)\right\}.
\end{eqnarray*}
and the frozen region is defined to be 
\begin{eqnarray*}
\left\{(\chi,\kappa)\in(l^{(0)},r^{(0)})\times \RR:\frac{\partial \mathcal{H}}{\partial \kappa}(\chi,\kappa)\in \{0,2\}\right\}.
\end{eqnarray*}
The frozen boundary is defined to be the boundary separating the frozen region and the liquid region.
\end{definition}

\begin{remark}By Proposition \ref{p67}, we see that if $\mathcal{R}_{\chi}\neq \emptyset$ and $\mathcal{G}_{\chi}(0)\neq \emptyset$, $(\chi,\kappa)\in(l^{(0)},r^{(0)})\times \RR$ is in the liquid region if and only if the following equation
\begin{eqnarray}
\mathcal{G}_{\chi}(w)=e^{-n\kappa}\label{gck}
\end{eqnarray}
in $w$ has exactly one pair of nonreal conjugate roots in $w$. By Lemma \ref{l65}, we see that the the frozen boundary is given by the condition that (\ref{gck}) has double real roots.
\end{remark}

Next we shall find the frozen boundary. The discussion above shows that if $\mathcal{R}_{\chi}\neq \emptyset$ and $\mathcal{G}_{\chi}(0)\neq \emptyset$, $(\chi,\kappa)\in(l^{(0)},r^{(0)})\times \RR$ is on the frozen boundary if and only if $(\chi,\kappa)$ satisfies the following system of equations
\begin{eqnarray}\label{fb}
\begin{cases}
\mathcal{G}_{\chi}(w)=e^{-n\kappa}\\
\frac{d\log \mathcal{G}_{\chi}(w)}{dw}=0.
\end{cases}
\end{eqnarray}
The second equation in (\ref{fb}) gives
\begin{eqnarray}
0&=&\sum_{(p\in [m],V_p>\chi),j\in[n]: \mathbf{1}_{\mathcal{E}_{j,p,>,1}}=1}
\frac{1}{w-e^{V_p}\tau_j^{-1}}-\frac{1}{w-e^{\max\{V_{p-1},\chi\}}\tau_{j}^{-1}}\label{fb}\\
&&+\sum_{(p\in[m],V_{p-1}<\chi)j\in[n]:\mathbf{1}_{\mathcal{E}_{j,p,<,1}}=1}
\frac{1}{w- e^{V_{p-1}}\tau_j^{-1}}-\frac{1}{w-e^{\min\{V_p,\chi\}}\tau_{j}^{-1}}\notag\\
&&+\sum_{(p\in[m],V_p>\chi),j\in[n]:\mathbf{1}_{\mathcal{E}_{j,p,>,0}}=1}\frac{1}{w+e^{\max\{V_{p-1},\chi\}}\tau_j^{-1}}
-\frac{1}{w+e^{V_p}\tau_{j}^{-1}}\notag
\\
&&+\sum_{(p\in[m],V_{p-1}<\chi),j\in[n]:\mathbf{1}_{\mathcal{E}_{j,p,<,0}}=1}
\frac{1} {w+e^{\min\{V_p,\chi\}} \tau_{j}^{-1}}-\frac{1}{w+e^{V_{p-1}}\tau_j^{-1}}\notag
\end{eqnarray}



\section{Height Fluctuations and Gaussian Free Field}\label{sect:gff}

In this section, we prove that the fluctuations of height function converges to the pull-back Gaussian Free Field (GFF) in the upper half plane under a diffeomorphism from the liquid region to the upper half plane. The main theorem proved in this section in Theorem \ref{t77}.

 \subsection{Gaussian free field} 
 
 Let $C_0^{\infty}$ be the space of smooth real-valued functions with compact
 support in the upper half plane $\HH$. The \emph{Gaussian free field} (GFF)
 $\Xi$ on $\HH$ with the zero boundary condition is a collection of Gaussian
 random variables $\{\Xi_{f}\}_{f\in C_0^{\infty}}$ indexed by functions in
 $C_0^{\infty}$, such that the covariance of two Gaussian random variables
 $\Xi_{f_1}$, $\Xi_{f_2}$ is given by
 \begin{equation}
 \mathrm{Cov}(\Xi_{f_1},\Xi_{f_2})=\int_{\HH}\int_{\HH}f_1(z)f_2(w)G_{\HH}(z,w)dzd\ol{z}dwd\ol{w},\label{cvf}
 \end{equation}
 where
 \begin{equation*}
 G_{\HH}(z,w):=-\frac{1}{2\pi}\ln\left|\frac{z-w}{z-\ol{w}}\right|,\qquad z,w\in \HH
 \end{equation*}
 is the Green's function of the Laplacian operator on $\HH$ with the Dirichlet
 boundary condition. The Gaussian free field $\Xi$ can also be considered as a
 random distribution on $C_0^{\infty}$,

 such that for any $f\in C_0^{\infty}$, we have
 \begin{equation*}
 \Xi(f)=\int_{\HH}f(z)\Xi(z)dz:=\xi_f.
 \end{equation*}
Here $\Xi(f)$ is the Gaussian random variable with respect to $f$, which has
mean 0 and variance given by \eqref{cvf}) with $f_1$ and $f_2$ replaced by $f$.
See~\cite{SS07} for more about the GFF.

\subsection{$\mathbf{w}_{+}$ as a mapping from $\mathcal{L}$ to $\mathbb{H}$}:





By (\ref{dgs1})-(\ref{dgs4}) and (\ref{dgc}), we may write $\mathcal{G}_{\chi}(w)$ as the quotient of two functions $U_{\chi}(w)$ and $R(w)$, such that $U_{\chi}(w)$ depends on $\chi$ and $R(w)$ is independent of $\chi$. More precisely,
\begin{eqnarray*}
\mathcal{G}_{\chi}(w)=\frac{U_{\chi}(w)}{R(w)};
\end{eqnarray*}
where
\begin{eqnarray*}
U_{\chi}(w)&=&\frac{\prod_{j\in[n],a_j=R}\left(1+e^{-\chi}w \tau_j\right)}{\prod_{j\in[n],a_j=L}({1-e^{-\chi}w \tau_j})}
\end{eqnarray*}
and
\begin{eqnarray}
R(w)&=&A_1\cdot A_2\label{drw}
\end{eqnarray}

For $j\in[n]$ and $p\in[m]$ we use $b_j(p-1,p)=+$ to denote that for each $\epsilon>0$, and each integer $k$ such that $\epsilon k\in \left(V_{p-1},V_p\right)$ and $[(k-j)\mod n]=0$, $b_k^{(\epsilon)}=+$

Note that
\begin{small}
\begin{eqnarray}
A_1&=&\prod_{j_1}^{n}\prod_{(p\in [m],V_p>\chi)}
\left(1-e^{-V_p}w \tau_{j}\right)^{- \mathbf{1}_{\mathcal{E}_{j,p,>,1}}}\prod_{(p\in [m],V_{p-1}>\chi)}\left(1-w e^{-V_{p-1}}\tau_j\right)^{\mathbf{1}_{\mathcal{E}_{j,p,>,1}}}\notag\\
&&\times\prod_{(p\in[m],V_{p-1}<\chi)}
\left(1-w e^{-V_{p-1}}\tau_j\right)^{ 
-\mathbf{1}_{\mathcal{E}_{j,p,<,1}}}
\prod_{(p\in[m],V_{p}<\chi)}\left(1-e^{-V_p}w \tau_{j}\right)^{ 
\mathbf{1}_{\mathcal{E}_{j,p,<,1}}}\notag\\
&=&\prod_{j\in[n]:a_j=L}\left[\left(1-e^{-V_0}w\tau_j\right)^{-\mathbf{1}_{b_j(0,1)=+}}\left(1-e^{-V_m}w\tau_j\right)^{-\mathbf{1}_{b_j(m-1,m)=-}}\right]\notag\\
&&\times\left[\prod_{p=1}^{m-1}\left(1-e^{-V_p}\tau_j w\right)^{-\mathbf{1}_{b_j(p,p+1)=+}+\mathbf{1}_{b_j(p-1,p)=+}}\right]\label{da1}
\end{eqnarray}
\end{small}
and
\begin{small}
\begin{eqnarray}
A_2&=&\prod_{j=1}^{n}\prod_{(p\in[m],V_p>\chi)}
\left(1+e^{-V_p}w\tau_{j}\right)^{\mathbf{1}_{\mathcal{E}_{j,p,>,0}}}\prod_{(p\in[m],V_{p-1}>\chi)}\left({1+w e^{-V_{p-1}}\tau_j}\right)^{-\mathbf{1}_{\mathcal{E}_{j,p,>,0}}}\notag\\
&&\times\prod_{(p\in[m],V_{p}<\chi)}
\left(1+e^{-V_p}w \tau_{j}\right)^{
-\mathbf{1}_{\mathcal{E}_{j,p,<,0}}}
\prod_{(p\in[m],V_{p-1}<\chi)}\left({1+w e^{-V_{p-1}}\tau_j}\right)^{
\mathbf{1}_{\mathcal{E}_{j,p,<,0}}}\notag\\
&=&\prod_{j\in[n]:a_j=R}\left[\left(1+e^{-V_0}w\tau_j\right)^{\mathbf{1}_{b_j(0,1)=+}}\left(1+e^{-V_m}w\tau_j\right)^{\mathbf{1}_{b_j(m-1,m)=-}}\right]\notag\\
&&\times\left[\prod_{p=1}^{m-1}\left(1+e^{-V_p}\tau_j w\right)^{\mathbf{1}_{b_j(p,p+1)=+}-\mathbf{1}_{b_j(p-1,p)=+}}\right]\label{da2}
\end{eqnarray}
\end{small}

We shall always use $[\cdot]^{\frac{1}{n}}$ to denote the branch which takes positive real values on the positive real line. 
Define
\begin{eqnarray*}
U(w_*,z_*)&=&\left[\frac{\prod_{j\in[n],a_j=R}\left(1+w_* \tau_j\right)}{\prod_{j\in[n],a_j=L}({1-w_*\tau_j})}\right]^{\frac{1}{n}}-z_*
\end{eqnarray*}

Hence we have 
\begin{eqnarray}
\mathcal{G}_{\chi}(w)=e^{-n\kappa}\label{cpeq}
\end{eqnarray}
if and only if 
\begin{eqnarray*}
\begin{cases}
U(w_*,z_*)=0\\
[R(w)]^{\frac{1}{n}}=z\\
(w_*,z_*)=(e^{-\chi}w,e^{-\kappa}z)
\end{cases}
\end{eqnarray*}

\begin{lemma}\label{l71}
Let
\begin{eqnarray*}
n_R:=|\{j\in[n]:a_j=R\}|;\qquad n_L:=|\{j\in[n]:a_j=L\}|;
\end{eqnarray*}
For any $(\alpha,\theta)$ such that 
\begin{eqnarray}
\theta\in(0,\pi),\qquad \alpha\in \left(0,\frac{n_L\pi+(n_R-n_L)\theta}{n}\right),\label{cta}
\end{eqnarray}
there exists a unique pair $(w_*,z_*)$ such that $\arg z_*=\alpha$ for some $k\in\ZZ$, $\arg w_*=\theta$ and $U(w_*,z_*)=0$. 
\end{lemma}

\begin{proof}
Note that $n_R+n_L=n$. For $\theta\in (0,\pi)$, define a map $B_{\theta}: [0,\infty)\rightarrow \RR$ by
\begin{eqnarray*}
B_{\theta}(\rho):=\frac{1}{n}\left[\sum_{j\in[n]:a_j=R}\arg(1+\rho e^{\mathbf{i}\theta}\tau_j)
-\sum_{j\in[n]:a_j=L}\arg(1-\rho e^{\mathbf{i}\theta}\tau_j)\right]
\end{eqnarray*}
where the branch of $\arg(\cdot)$ is chosen such that it has range $(-\pi,\pi]$. It is straightforward to check that $B_{\theta}(\rho)$ is strictly increasing when $\rho\in(0,\infty)$. Moreover,
\begin{eqnarray*}
\lim_{\rho\rightarrow0} B_{\theta}(\rho)=0;\qquad
\lim_{\rho\rightarrow\infty} B_{\theta}(\rho)=\frac{n_L\pi}{n}+\frac{(n_R-n_L)\theta}{n}.
\end{eqnarray*}
Since $B_{\theta}$ is a bijection from $(0,\infty)$ to $\left(0,\frac{n_L\pi}{n}+\frac{(n_R-n_L)\theta}{n}\right)$, for any $(\alpha,\theta)$ satisfying (\ref{cta}), we can find a unique $\rho>0$, such that $B_{\theta}(\rho)=\alpha$. Let
\begin{eqnarray*}
w_*:&=&\rho e^{\mathbf{i}\theta};\\
z_*:&=&\left[\frac{\prod_{j\in[n],a_j=R}\left(1+w_* \tau_j\right)}{\prod_{j\in[n],a_j=L}({1-w_*\tau_j})}\right]^{\frac{1}{n}}.
\end{eqnarray*}
Then the lemma follows.
\end{proof}

\begin{proposition}For each $(\chi,\kappa)\in \mathcal{L}$, let $\mathbf{w}_+(\chi,\kappa)$ be the unique root of (\ref{cpeq}) in the upper half plane $\HH$. Then $\mathbf{w}_+:\mathcal{L}\rightarrow \HH$ is a diffeomorphism.
\end{proposition}

\begin{proof}We first show that $\mathbf{w}_+$ is a bijection. 
For any $w\in\mathbb{H}$, let $z=[R(w)]^{\frac{1}{n}}$. Let
\begin{eqnarray*}
\theta:=\arg w\in (0,\pi);\qquad \alpha:=\arg z
\end{eqnarray*}
By (\ref{drw}) (\ref{da1}) (\ref{da2}) we obtain
\begin{small}
\begin{eqnarray}
\alpha&=&\frac{1}{n}\sum_{j\in[n]:a_j=L}\left[-\arg\left(1-e^{-V_0}w\tau_j\right)\mathbf{1}_{b_j(0,1)=+}-\arg\left(1-e^{-V_m}w\tau_j\right)\mathbf{1}_{b_j(m-1,m)=-}\right]\label{agr}\\
&&+\left[\sum_{p=1}^{m-1}\arg\left(1-e^{-V_p}\tau_j w\right)\left(-\mathbf{1}_{b_j(p,p+1)=+}+\mathbf{1}_{b_j(p-1,p)=+}\right)\right]\notag\\
&&+\sum_{j\in[n]:a_j=R}\left[\arg\left(1+e^{-V_0}w\tau_j\right)
\mathbf{1}_{b_j(0,1)=+}
+\arg\left(1+e^{-V_m}w\tau_j\right)\mathbf{1}_{b_j(m-1,m)=-}\right]\notag\\
&&+\left[\sum_{p=1}^{m-1}\arg\left(1+e^{-V_p}\tau_j w\right)\left(\mathbf{1}_{b_j(p,p+1)=+}-\mathbf{1}_{b_j(p-1,p)=+}\right)\right]\notag
\end{eqnarray}
\end{small}
Then we have 
\begin{eqnarray}
\alpha&=&\frac{1}{n}\sum_{j\in[n]:a_j=L}\left[\sum_{p=1}^m\left[\arg\left(1-e^{-V_{p}}w\tau_j\right)-\arg\left(1-e^{-V_{p-1}}w\tau_j\right)\right]\mathbf{1}_{b_j(p-1,p)=+}\right]\label{al1}\\
&&\left.-\arg\left(1-e^{-V_m}w\tau_j\right)\right]+\sum_{j\in[n]:a_j=R}\left[\arg\left(1+e^{-V_m}w\tau_j\right)\right.\notag\\
&&+\left.\sum_{p=1}^{m}\left[\arg\left(1+e^{-V_{p-1}}w\tau_j\right)-
\arg\left(1+e^{-V_{p}}w\tau_j\right)
\right]\mathbf{1}_{b_j(p-1,p)=+}\right]\notag
\end{eqnarray}
and
\begin{eqnarray}
\alpha&=&\frac{1}{n}\sum_{j\in[n]:a_j=L}\left[-\arg\left(1-e^{-V_0}w\tau_j\right)\right.\label{al2}\\
&&\left.\sum_{p=1}^{m}\left[
\arg\left(1-e^{-V_{p-1}}w\tau_j\right)
-\arg\left(1-e^{-V_p}w\tau_j\right)\right]\mathbf{1}_{b_j(p-1,p)=-}\right]\notag\\
&&\sum_{j\in[n]:a_j=R}\left[\arg\left(1+e^{-V_0}w\tau_j\right)\right.\notag\\
&&+\left.\sum_{p=1}^{m}\left[\arg\left(1+e^{-V_{p}}w\tau_j\right)-
\arg\left(1+e^{-V_{p-1}}w\tau_j\right)
\right]\mathbf{1}_{b_j(p-1,p)=-}\right]\notag
\end{eqnarray}
Note that for any $w\in \HH$, $u,v\in[0,\infty]$ and $u<v$, we have
\begin{eqnarray*}
-(\pi-\arg w)\leq \arg\left(1-u^{-1}w\right)< \arg\left(1-v^{-1}w\right)\leq 0
\end{eqnarray*}
and
\begin{eqnarray*}
\arg w\geq\arg\left(1+u^{-1}w\right)> \arg\left(1+v^{-1}w\right)\geq 0
\end{eqnarray*}
Hence from (\ref{al1}), we obtain
\begin{eqnarray*}
\alpha&>&\frac{1}{n}\left\{\sum_{j\in[n]:a_j=L}
\left[-\arg\left(1-e^{-V_m}w\tau_j\right)\right]+\sum_{j\in[n]:a_j=R}\left[\arg\left(1+e^{-V_m}w\tau_j\right)\right]\right\}\geq 0
\end{eqnarray*}
By (\ref{al2}), we obtain
\begin{eqnarray*}
\alpha&<&\frac{1}{n}\left\{\sum_{j\in[n]:a_j=L}
\left[-\arg\left(1-e^{-V_0}w\tau_j\right)\right]+\sum_{j\in[n]:a_j=R}\left[\arg\left(1+e^{-V_0}w\tau_j\right)\right]\right\}\\
&\leq &\frac{n_L\pi+(n_R-n_L)\theta}{n}
\end{eqnarray*}
By Lemma \ref{l71}, we can a unique pair $(w_*,z_*)$ such that $\arg z_*=\alpha$ for some $k\in\ZZ$, $\arg w_*=\theta$ and $U(w_*,z_*)=0$. 
\begin{eqnarray*}
\chi:=\log\left(\frac{w}{w_*}\right);\qquad
\kappa:=\log\left(\frac{z}{z_*}\right)
\end{eqnarray*}
where the branch of the $\log(\cdot)$ is chosen such that it takes real values on the positive real axis. Then we deduce that $\mathbf{w}_+$ is a bijection. From the process we see that both the mapping $\mathbf{w}_+$ and its inverse are differentiable. Then the proposition follows.
\end{proof}

\subsection{Convergence of height fluctuations to GFF}

Splitting the sum of the RHS of (\ref{fb}) into those depending on $\chi$ and those independent of $\chi$, we obtain
\begin{small}
\begin{eqnarray*}
0&=&-\sum_{j\in[n]:a_j=L}\frac{1}{w-e^{\chi}\tau_j^{-1}}
+\sum_{j\in[n]:a_j=R}\frac{1}{w+e^{\chi}\tau_j^{-1}}\\
&&+\sum_{p\in[m-1],j\in [n],a_j=L}\frac{\mathbf{1}_{b_j(p,p+1)=+}-\mathbf{1}_{b_j(p-1,p)=+}}{w-e^{V_p}\tau_j^{-1}}
+\sum_{j\in[n],a_j=L}\left(\frac{\mathbf{1}_{b_j(m-1,m)=-}}{w-e^{V_m}\tau_j^{-1}}
+\frac{\mathbf{1}_{b_j(0,1)=+}}{w-e^{V_0}\tau_j^{-1}}
\right)\\
&&+\sum_{p\in[m-1],j\in [n],a_j=R}\frac{\mathbf{1}_{b_j(p-1,p)=+}-\mathbf{1}_{b_j(p,p+1)=+}}{w+e^{V_p}\tau_j^{-1}}
-\sum_{j\in[n],a_j=R}\left(\frac{\mathbf{1}_{b_j(m-1,m)=-}}{w+e^{V_m}\tau_j^{-1}}
+\frac{\mathbf{1}_{b_j(0,1)=+}}{w+e^{V_0}\tau_j^{-1}}
\right)
\end{eqnarray*}
\end{small}

Let $\mathcal{S}$ be the set of all the zeros and poles of $\mathcal{G}_{\chi}$ that are independent of $\chi$; or equivalently, $\mathcal{S}$ is the set of all the zeros and poles of $R(w)$. More precisely,
\begin{small}
\begin{eqnarray*}
\mathcal{S}&=&\left\{e^{V_p}\tau_j^{-1}:p\in[m-1],j\in[n],a_j=L,b_j(p-1,p)\neq b_j(p,p+1)\right\}
\\
&&\cup
\left\{-e^{V_p}\tau_j^{-1}:p\in[m-1],j\in[n],a_j=R,b_j(p-1,p)\neq b_j(p,p+1)\right\}\\
&&\cup\{e^{V_0}\tau_j^{-1},e^{V_m}\tau_j^{-1}:j\in[n],a_j=L\}
\cup\{-e^{V_0}\tau_j^{-1},-e^{V_m}\tau_j^{-1}:j\in[n],a_j=R\}
\end{eqnarray*}
\end{small}
Then we have the following lemma.

\begin{lemma}
Each $u\in \RR\setminus \mathcal{S}$ is a double root of (\ref{cpeq}) for a unique pair of $(\chi,\kappa)\in\RR^2$.
\end{lemma}

\begin{proof}Define
\begin{eqnarray*}
f(s):=\sum_{j\in[n]:a_j=L}\frac{1}{1-\tau_j^{-1}s}
-\sum_{j\in[n]:a_j=R}\frac{1}{1+\tau_j^{-1}s}
\end{eqnarray*}
and
\begin{small}
\begin{eqnarray*}
g(w):&=&\sum_{p\in[m-1],j\in [n],a_j=L}\frac{\mathbf{1}_{b_j(p,p+1)=+}-\mathbf{1}_{b_j(p-1,p)=+}}{w-e^{V_p}\tau_j^{-1}}
+\sum_{j\in[n],a_j=L}\left(\frac{\mathbf{1}_{b_j(m-1,m)=-}}{w-e^{V_m}\tau_j^{-1}}
+\frac{\mathbf{1}_{b_j(0,1)=+}}{w-e^{V_0}\tau_j^{-1}}
\right)\\
&&+\sum_{p\in[m-1],j\in [n],a_j=R}\frac{\mathbf{1}_{b_j(p-1,p)=+}-\mathbf{1}_{b_j(p,p+1)=+}}{w+e^{V_p}\tau_j^{-1}}
-\sum_{j\in[n],a_j=R}\left(\frac{\mathbf{1}_{b_j(m-1,m)=-}}{w+e^{V_m}\tau_j^{-1}}
+\frac{\mathbf{1}_{b_j(0,1)=+}}{w+e^{V_0}\tau_j^{-1}}
\right)
\end{eqnarray*}
\end{small}
Then $u$ is a double root for (\ref{ceqn}) for some $(\chi,\kappa)\in[r^{(0)},l^{(0)}]\times \RR$ if and only if 
\begin{eqnarray}
&&e^{\kappa}=\left[\frac{R(u)}{U_{\chi}(u)}\right]^{\frac{1}{n}}\label{drt1}\\
&&f(e^{\chi}u^{-1})=ug(u)\label{drt2}
\end{eqnarray}
where $[\cdot]^{\frac{1}{n}}$ is the branch that takes positive real value on the positive real axis.
The function $f(s)$ is defined in $\RR\setminus[\{-\tau_j\}_{j\in[n]:a_j=R}\cup\{\tau_j\}_{j\in[n],a_j=L}]$.
Suppose that we enumerate all the points in $\{-\tau_j\}_{j\in[n]:a_j=R}\cup\{\tau_j\}_{j\in[n],a_j=L}$ in increasing order as follows:
\begin{eqnarray*}
-d_{n_L}<-d_{n_L-1}<\ldots<-d_1<0<\alpha_1<\alpha_2<\ldots<\alpha_{n_R}
\end{eqnarray*}
Since for all $s\in\RR\setminus[\{-\tau_j\}_{j\in[n]:a_j=R}\cup\{\tau_j\}_{j\in[n],a_j=L}]$,
\begin{eqnarray*}
f'(s)=\sum_{j\in[n]:a_j=L}\frac{1}{\tau_j(1-\tau_j^{-1}s)^2}
+\sum_{j\in[n]:a_j=R}\frac{1}{\tau_j(1+\tau_j^{-1}s)^2}>0;
\end{eqnarray*}
we obtain 
\begin{enumerate}
    \item $f$ is strictly increasing in each interval $(\alpha_i,\alpha_{i+1})$, for $i\in[n_R-1]$ from $-\infty$ to $\infty$;
    \item $f$ is strictly increasing in each interval $(-d_{j+1},-d_{j})$, for $j\in[n_L-1]$ from $-\infty$ to $\infty$;
    \item $f$ is strictly increasing in the interval $(-d_1,\alpha_1)$ from $-\infty$ to $\infty$;
    \item $f$ is strictly increasing in the interval $(\alpha_{n_R},\infty)$ from $-\infty$ to $0$;
    \item $f$ is strictly increasing in the interval $(-\infty,\alpha_{n_L})$ from $0$ to $\infty$.
\end{enumerate}

Hence for each $u\in \RR$ and for each set 
\begin{small}
\begin{eqnarray}
\Delta\in &&\{(-d_{n_L},-d_{n_L-1}),\ldots,(-d_2,d_1),(d_1,\alpha_1),(\alpha_1,\alpha_2),\ldots,\label{dta1}\\
&&(\alpha_{n_R-1},\alpha_{n_R}),(\alpha_{n_R},\infty)\cup(-\infty,-d_{n_L})\},\notag
\end{eqnarray}
\end{small}
there is a unique $\chi$ such that (\ref{drt2}) holds and $e^{\chi}u^{-1}\in \Delta$.

For $j\in[n]$, let
\begin{eqnarray}
p_{j,L}&=&\max\{p\in[0..m]:e^{V_p}\tau_j^{-1}<u, a_j=L\};\label{dpl}\\
p_{j,R}&=&\max\{p\in[0..m]:u<-e^{V_p}\tau_j^{-1}, a_j=R\}\label{dpr}
\end{eqnarray}
again we take the convention that the minimum (resp.\ maximum) of an empty set is $\infty$ ($-\infty$); and assume for all $j\in[n]$
\begin{eqnarray*}
b_j(-\infty,-\infty)=-;\qquad
b_j(m,m+1)=+.
\end{eqnarray*}
From (\ref{agr}), we obtain
\begin{small}
\begin{eqnarray}
&&\lim_{\epsilon\rightarrow 0+}\arg [R(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}\label{agm5}\\
&=&
\frac{\pi}{n}\left(\sum_{j\in[n]:a_j=R}\mathbf{1}_{b_j(p_{j,R},p_{j,R}+1)=+}+
\sum_{j\in[n]:a_j=L}\mathbf{1}_{b_j(p_{j,L},p_{j,L}+1)=+}\right)\notag
\end{eqnarray}
\end{small}
where $k\in\ZZ$. Moreover,
\begin{small}
\begin{eqnarray}
&&\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}\label{agm6}\\
&=&\lim_{\epsilon\rightarrow 0+}\frac{1}{n}\left(\sum_{j\in[n],a_j=R}\arg(1+e^{-\chi}(u+\mathbf{i}\epsilon)\tau_j)-\sum_{j\in[n],a_j=L}\arg(1-e^{-\chi}(u+\mathbf{i}\epsilon)\tau_j)\right)\notag\\
&=&\frac{\pi}{n}\left(\sum_{j\in[n],a_j=R}
\mathbf{1}_{u<-e^{\chi}\tau_j^{-1}}
+\sum_{j\in[n],a_j=L}\mathbf{1}_{u>e^{\chi}\tau_j^{-1}}\right).\notag
\end{eqnarray}
\end{small}
The following cases might occur
\begin{enumerate}
    \item $u< 0$: then
    \begin{eqnarray}
    \lim_{\epsilon\rightarrow 0+}\arg [R(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=
\frac{\pi}{n}\left|\{j\in[n]:a_j=R,b_j(p_{j,R},p_{j,R}+1)=+\}\right|\label{agm1}
    \end{eqnarray}
    and
    \begin{eqnarray}
    \lim_{\epsilon\rightarrow 0+}\arg [U_{\chi}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}&=&\frac{\pi}{n}\left|\{j\in[n]:a_j=R,
    -\tau_j<e^{\chi}u^{-1}\}\right|\label{agm2}
    \end{eqnarray}
    It is straightforward to check that there exists a unique $\Delta$ satisfying (\ref{dta1}), such that (\ref{agm1}) and (\ref{agm2}) are equal when $e^{\chi}u^{-1}\in \Delta$.
     \item $u\geq0$: then
    \begin{eqnarray}
    \lim_{\epsilon\rightarrow 0+}\arg [R(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=
\frac{\pi}{n}\left|\{j\in[n]:a_j=L,b_j(p_{j,L},p_{j,L}+1)=+\}\right|\label{agm3}
    \end{eqnarray}
    and
    \begin{eqnarray}
    \lim_{\epsilon\rightarrow 0+}\arg [U_{\chi}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}&=&\frac{\pi}{n}\left|\{j\in[n]:a_j=L,
   e^{\chi}u^{-1}<\tau_j\}\right|\label{agm4}
    \end{eqnarray}
    It is straightforward to check that there exists a unique $\Delta$ satisfying (\ref{dta1}), such that (\ref{agm3}) and (\ref{agm4}) are equal when $e^{\chi}u^{-1}\in \Delta$.
\end{enumerate}
Then we deduce that $u\in \mathcal{R}\setminus \mathcal{S}$, there exists a unique $\chi$ such that (\ref{drt2}) holds and $(\ref{agm5})$ and (\ref{agm6}) are equal. The condition that (\ref{agm5}) and (\ref{agm6}) are equal is equivalent of saying that the right hand side of (\ref{drt1}) is real and positive. When the right hand side of (\ref{drt1}) is positive, we obtain a unique $\kappa\in \RR$. Then the lemma follows.
\end{proof}

\begin{assumption}\label{ap74}
Let $i,j$ be positive integers satisfying
\begin{itemize}
    \item $\epsilon i\in (V_{p_1-1},V_{p_1})$, $\epsilon j\in (V_{p_2}-1,V_{p_2})$ and 
    \item $i_*\in[n]$ such that $[(i-i_*)\mod n]=0$; and
    \item $j_*\in[n]$ such that $[(j-j_*)\mod n]=0$;
    \item $i_*\neq j_*$ and $\tau_{i_*}>\tau_{j_*}$
    \item $a_i^{(\epsilon)}=a_j^{(\epsilon)}$;
\end{itemize}
then we have
\begin{eqnarray*}
\tau_{i_*}^{-1}\tau_{j_*}<e^{V_{p_2}-V_{p_1}}.
\end{eqnarray*}
\end{assumption}

\begin{remark}Under Assumption \ref{ap74}, if we order all the points in $\{-\tau_j\}_{j\in[n]:a_j=R}\cup\{-\tau_j\}_{j\in[n],a_j=L}$ as follows
\begin{eqnarray*}
-d_{n_R}<-d_{n_{R-1}}<\ldots<-d_1<0<\alpha_1<\alpha_2<\ldots<\alpha_{n_L}
\end{eqnarray*}
Then we can order all the points in $\{e^{V_p}\tau_j^{-1}\}_{p\in[0..m],j\in[n],a_j=L}\cup
\{e^{V_p}\tau_j^{-1}\}_{p\in[0..m],j\in[n],a_j=R}
$ as follows
\begin{eqnarray*}
&&-d_1^{-1}e^{V_m}<-d_1^{-1}e^{V_{m-1}}<\ldots<-d_1^{-1}e^{V_0}<\\
&&-d_2^{-1}e^{V_m}<-d_2^{-1}e^{V_{m-1}}<\ldots<-d_2^{-1}e^{V_0}<\\
&&\ldots\\
&&-d_{n_R}^{-1}e^{V_m}<-d_{n_R}^{-1}e^{V_{m-1}}<\ldots<-d_{n_R}^{-1}e^{V_0}<\\
&&\alpha_{n_L}^{-1}e^{V_0}<\alpha_{n_L}^{-1}e^{V_1}<\ldots<\alpha_{n_L}^{-1}e^{V_m}\\
&&\ldots\\
&&\alpha_{1}^{-1}e^{V_0}<\alpha_{1}^{-1}e^{V_1}<\ldots<\alpha_{1}^{-1}e^{V_m}
\end{eqnarray*}
\end{remark}

\begin{lemma}\label{l76}Suppose Assumption \ref{ap74} holds. For $u\in \HH\cup \RR$, let $(\chi_u,\kappa_u)\in \RR^2$ such that
\begin{eqnarray*}
\mathcal{G}_{\chi_u}(u)=e^{-n\kappa u}
\end{eqnarray*}
Assume one of the 
following two conditions holds
\begin{enumerate}
\item $u\rightarrow e^{V_p}\tau_j^{-1}\in\mathcal{S}$ for some $p\in[0..m]$, $j\in[n]$ and $a_j=L$;
\item $u\rightarrow -e^{V_p}\tau_j^{-1}\in\mathcal{S}$ for some $p\in[0..m]$, $j\in[n]$
and $a_j=R$;
\end{enumerate}
 then $\chi_u\rightarrow V_p$.
\end{lemma}
\begin{proof}
\begin{enumerate}
\item
We first consider case (1). 
\begin{enumerate}
\item Assume that $u\rightarrow e^{V_p}\tau_j^{-1}\in \mathcal{S}$ for some $p\in[m-1]$, $j\in[n]$ and $a_j=L$. 
Let $\delta>0$ be positive and small. By (\ref{dpl}), under Assumption \ref{ap64} we obtain that for $i\in[n]$, $a_i=L$, 
\begin{itemize}
\item if $u=e^{V_p}\tau_j^{-1}-\delta$
\begin{eqnarray*}
p_{i,L}=\begin{cases}-\infty &\mathrm{If}\ \tau_i<\tau_j\\
p-1 &\mathrm{If}\ \tau_i=\tau_j\\
m &\mathrm{If}\ \tau_i>\tau_j
\end{cases}
\end{eqnarray*}
\item if $u=e^{V_p}\tau_j^{-1}+\delta$
\begin{eqnarray*}
p_{i,L}=\begin{cases}-\infty &\mathrm{If}\ \tau_i<\tau_j\\
p&\mathrm{If}\ \tau_i=\tau_j\\
m &\mathrm{If}\ \tau_i>\tau_j
\end{cases}
\end{eqnarray*}
\end{itemize}
By (\ref{agm3}) we have
\begin{small}
 \begin{eqnarray}
 \lim_{[u\rightarrow e^{V_p}\tau_j^{-1}-]}   \lim_{\epsilon\rightarrow 0+}\arg [R(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}

&=&\frac{\pi}{n}\left|\{i\in[n]:a_i=L;
   \tau_i>\tau_j\}\right|+\mathbf{1}_{b_i(p-1,p)=+}\label{es5}
    \end{eqnarray}
    \end{small}
and
\begin{small}
 \begin{eqnarray}
 \lim_{[u\rightarrow e^{V_p}\tau_j^{-1}+]}   \lim_{\epsilon\rightarrow 0+}\arg [R(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}

&=&\frac{\pi}{n}\left|\{i\in[n]:a_i=L;
   \tau_i>\tau_j\}\right|+\mathbf{1}_{b_i(p,p+1)=+}\label{es6}
    \end{eqnarray}
    \end{small}

Note also that
\begin{eqnarray*}
\lim_{[u\rightarrow e^{V_p}\tau_j^{-1}-]} ug(u)
=\begin{cases}
+\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}<\mathbf{1}_{b_j(p-1,p)=+}\\
-\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}>\mathbf{1}_{b_j(p-1,p)=+}\\
\mathrm{a\ finite\ real\ number}&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}=\mathbf{1}_{b_j(p-1,p)=+}
\end{cases}
\end{eqnarray*}
and
\begin{eqnarray*}
\lim_{[u\rightarrow e^{V_p}\tau_j^{-1}+]} ug(u)
=\begin{cases}
-\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}<\mathbf{1}_{b_j(p-1,p)=+}\\
+\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}>\mathbf{1}_{b_j(p-1,p)=+}\\
\mathrm{a\ finite\ real\ number}&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}=\mathbf{1}_{b_j(p-1,p)=+}
\end{cases}
\end{eqnarray*}
Since $e^{V_p}\tau_j^{-1}\in\mathcal{S}$, we obtain that $b_j(p-1,p)\neq b_{j}(p,p+1)$. We obtain that when $u\rightarrow e^{V_p}\tau_j^{-1}+$ or 
$u\rightarrow e^{V_p}\tau_j^{-1}-$, by (\ref{drt2}), $e^{\chi}u^{-1}$ approaches some $\tau_k$ for $a_k=L$, $k\in[n]$. Moreover
\begin{enumerate}
    \item If $\mathbf{1}_{b_j(p-1,p)}>\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow e^{V_p}\tau_j^{-1}-$, $e^{\chi}u^{-1}$ approaches $\tau_k$ from the left;
    \item If $\mathbf{1}_{b_j(p-1,p)}<\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow e^{V_p}\tau_j^{-1}-$, $e^{\chi}u^{-1}$ approaches $\tau_k$ from the right;
    \item If $\mathbf{1}_{b_j(p-1,p)}>\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow e^{V_p}\tau_j^{-1}+$, $e^{\chi}u^{-1}$ approaches $\tau_k$ from the right;
    \item If $\mathbf{1}_{b_j(p-1,p)}<\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow e^{V_p}\tau_j^{-1}+$, $e^{\chi}u^{-1}$ approaches $\tau_k$ from the left;
\end{enumerate}
By
(\ref{agm4}),
\begin{enumerate}
\item If $\mathbf{1}_{b_j(p-1,p)}>\mathbf{1}_{b_j(p,p+1)}$
\begin{small}
\begin{eqnarray}
&&\lim_{[u\rightarrow e^{V_p}\tau_j^{-1}-]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=L;\label{es1}
  \tau_i\geq \tau_k\}\right|\\
&&\lim_{[u\rightarrow e^{V_p}\tau_j^{-1}+]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=L;
  \tau_i>\tau_k\}\right|\label{es2}
\end{eqnarray}
\end{small}
\item The case when $u\rightarrow e^{V_0}\tau_j^{-1}$ and $u\rightarrow e^{V_m}\tau_j^{-1}$ for some $j\in[n]$, $a_j=L$ can be proved similarly.
\begin{small}
\begin{eqnarray}
&&\lim_{[u\rightarrow e^{V_p}\tau_j^{-1}-]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=L;
  \tau_i> \tau_k\}\right|\label{es3}\\
&&\lim_{[u\rightarrow e^{V_p}\tau_j^{-1}+]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=L;
  \tau_i\geq \tau_k\}\right|\label{es4}
\end{eqnarray}
\end{small}
\end{enumerate}
In either case to make (\ref{es1})-(\ref{es4}) equal to the corresponding arguments in (\ref{es5}), (\ref{es6}), we must have $\tau_k=\tau_j$.
\item The case $u\rightarrow e^{V_0}\tau_j^{-1}$ or
$u\rightarrow e^{V_0}\tau_j^{-1}$
for some $j\in [n]$ and $a_j=L$ can be proved similarly.
\end{enumerate}
\item Now we consider case (2). 
\begin{enumerate}
\item Assume that $u\rightarrow -e^{V_p}\tau_j^{-1}$ for some $p\in[m-1]$, $j\in[n]$ and $a_j=R$. 
Let $\delta>0$ be positive and small. By (\ref{dpr}), under Assumption \ref{ap64} we obtain that for $i\in[n]$, $a_i=R$, 
\begin{itemize}
\item if $u=-e^{V_p}\tau_j^{-1}-\delta$
\begin{eqnarray*}
p_{i,R}=\begin{cases}-\infty &\mathrm{If}\ \tau_i<\tau_j\\
p &\mathrm{If}\ \tau_i=\tau_j\\
m &\mathrm{If}\ \tau_i>\tau_j
\end{cases}
\end{eqnarray*}
\item if $u=-e^{V_p}\tau_j^{-1}+\delta$
\begin{eqnarray*}
p_{i,R}=\begin{cases}-\infty &\mathrm{If}\ \tau_i<\tau_j\\
p-1&\mathrm{If}\ \tau_i=\tau_j\\
m &\mathrm{If}\ \tau_i>\tau_j
\end{cases}
\end{eqnarray*}
\end{itemize}
By (\ref{agm1}) we have
\begin{small}
 \begin{eqnarray}
 \lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}-]}   \lim_{\epsilon\rightarrow 0+}\arg [R(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}

&=&\frac{\pi}{n}\left|\{i\in[n]:a_i=R;
   \tau_i>\tau_j\}\right|+\mathbf{1}_{b_i(p,p+1)=+}\label{et5}
    \end{eqnarray}
    \end{small}
and
\begin{small}
 \begin{eqnarray}
 \lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}+]}   \lim_{\epsilon\rightarrow 0+}\arg [R(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}

&=&\frac{\pi}{n}\left|\{i\in[n]:a_i=R;
   \tau_i>\tau_j\}\right|+\mathbf{1}_{b_i(p-1,p)=+}\label{et6}
    \end{eqnarray}
    \end{small}
Note also that
\begin{eqnarray*}
\lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}-]} ug(u)
=\begin{cases}
+\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}<\mathbf{1}_{b_j(p-1,p)=+}\\
-\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}>\mathbf{1}_{b_j(p-1,p)=+}\\
\mathrm{a\ finite\ real\ number}&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}=\mathbf{1}_{b_j(p-1,p)=+}
\end{cases}
\end{eqnarray*}
and
\begin{eqnarray*}
\lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}+]} ug(u)
=\begin{cases}
-\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}<\mathbf{1}_{b_j(p-1,p)=+}\\
+\infty&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}>\mathbf{1}_{b_j(p-1,p)=+}\\
\mathrm{a\ finite\ real\ number}&\mathrm{if}\ \mathbf{1}_{b_j(p,p+1)=+}=\mathbf{1}_{b_j(p-1,p)=+}
\end{cases}
\end{eqnarray*}
Since $-e^{V_p}\tau_j^{-1}\in\mathcal{S}$, we obtain that $b_j(p-1,p)\neq b_{j}(p,p+1)$. We obtain that when $u\rightarrow -e^{V_p}\tau_j^{-1}+$ or 
$u\rightarrow -e^{V_p}\tau_j^{-1}-$, by (\ref{drt2}), $e^{\chi}u^{-1}$ approaches some $-\tau_k$ for $a_k=R$, $k\in[n]$. Moreover
\begin{enumerate}
    \item If $\mathbf{1}_{b_j(p-1,p)}>\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow -e^{V_p}\tau_j^{-1}-$, $e^{\chi}u^{-1}+\tau_k$ approaches $0$ from the left;
    \item If $\mathbf{1}_{b_j(p-1,p)}<\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow -e^{V_p}\tau_j^{-1}-$, $e^{\chi}u^{-1}+\tau_k$ approaches $0$ from the right;
    \item If $\mathbf{1}_{b_j(p-1,p)}>\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow-e^{V_p}\tau_j^{-1}+$, $e^{\chi}u^{-1}+\tau_k$ approaches $0$ from the right;
    \item If $\mathbf{1}_{b_j(p-1,p)}<\mathbf{1}_{b_j(p,p+1)}$, as $u\rightarrow -e^{V_p}\tau_j^{-1}+$, $e^{\chi}u^{-1}+\tau_k$ approaches $0$ from the left;
\end{enumerate}
By
(\ref{agm2}),
\begin{enumerate}
\item If $\mathbf{1}_{b_j(p-1,p)}>\mathbf{1}_{b_j(p,p+1)}$
\begin{small}
\begin{eqnarray}
&&\lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}-]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=R;\label{et1}
  \tau_i> \tau_k\}\right|\\
&&\lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}+]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=R;
  \tau_i\geq\tau_k\}\right|\label{et2}
\end{eqnarray}
\end{small}
\item If $\mathbf{1}_{b_j(p-1,p)}<\mathbf{1}_{b_j(p,p+1)}$
\begin{small}
\begin{eqnarray}
&&\lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}-]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=R;
  \tau_i\geq\tau_k\}\right|\label{et3}\\
&&\lim_{[u\rightarrow -e^{V_p}\tau_j^{-1}+]}\lim_{\epsilon\rightarrow 0+}\arg [U_{\chi_u}(u+\mathbf{i}\epsilon)]^{\frac{1}{n}}=\frac{\pi}{n}\left|\{i\in[n]:a_i=R;
  \tau_i> \tau_k\}\right|\label{et4}
\end{eqnarray}
\end{small}
\end{enumerate}
In either case to make (\ref{et1})-(\ref{et4}) equal to the corresponding arguments in (\ref{et5}), (\ref{et6}), we must have $\tau_k=\tau_j$.
\item The case when $u\rightarrow -e^{V_0}\tau_j^{-1}$ or $u\rightarrow -e^{V_m}\tau_j^{-1}$ for some $j\in[n]$, $a_j=R$ can be proved similarly.
\end{enumerate}
\end{enumerate}
\end{proof}


\begin{theorem}\label{t77}Let $\{RYG(l^{(\epsilon)},r^{(\epsilon)},\underline{a}^{(\epsilon)},\underline{b}^{(\epsilon)})\}_{\epsilon>0}$ be a sequence of rail-yard graphs satisfying Assumptions \ref{ap41}, \ref{ap43}, \ref{ap52}, \ref{aps5}, \ref{ap62}, \ref{ap74}. Let $\mathbf{w}_+:\mathcal{L}\rightarrow \HH$ be the diffeomorphism from the liquid region to the upper half plane which maps each point $(\chi,\kappa)$ in the liquid region to the unique root of (\ref{ceqn}) in the upper half plane $\HH$. Then as $\epsilon\rightarrow 0$, the height function of pure dimer coverings on $\{RYG(l^{(\epsilon)},r^{(\epsilon)},\underline{a}^{(\epsilon)},\underline{b}^{(\epsilon)})\}_{\epsilon>0}$ in the liquid region converges to the $\mathbf{w}_+$-pullback of GFF in the sense that for any $(\chi,\kappa)\in \mathcal{L}$, $\chi\notin\{V_p\}_{p=0}^{m}$ and positive integer $k$
\begin{eqnarray*}
\int_{-\infty}^{\infty}\left(h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)-
\mathbb{E}\left[h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)
\right]\right)
e^{-n\beta k\kappa}d\kappa\longrightarrow\int_{(\chi,\kappa)\in\mathcal{L}}e^{-n\kappa k\beta} \Xi(\mathbf{w}_+(\chi,\kappa)) d\kappa
\end{eqnarray*}
in distribution.
\end{theorem}

\begin{proof}Let $\chi\in [r^{(0)},l^{(0)}]$ and $k$ be a positive integer. By (\ref{hme}) and Assumption \ref{ap52}, we have
\begin{eqnarray*}
\int_{-\infty}^{\infty}\left(h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)-
\mathbb{E}\left[h_{M}\left(\frac{\chi}{\epsilon},\frac{\kappa}{\epsilon}\right)
\right]\right)
e^{-n\beta k\kappa}d\kappa=
\frac{2\epsilon}{(k\log t)^2}\left[\gamma_k(\lambda^{(M,m)},t;t)-
\mathbb{E}\gamma_k(\lambda^{(M,m)},t;t)
\right]
\end{eqnarray*}
where $\chi=2m-\frac{1}{2}$.
By Theorem \ref{t58}, we obtain that for
\begin{eqnarray*}
l^{(0)}<\chi_1<\chi_2<\ldots<\chi_s<r^{(0)}
\end{eqnarray*}
and positive integers $k_1,\ldots,k_s$
\begin{eqnarray*}
\left\{\int_{-\infty}^{\infty}\left(h_{M}\left(\chi_i,\frac{y}{\epsilon}\right)-
\mathbb{E}\left[h_{M}\left(\chi_i,\frac{y}{\epsilon}\right)
\right]\right)
t^{-k_iy}dy\right\}_{i\in[s]}
\end{eqnarray*}
converges to the Gaussian vector with covariance
\begin{eqnarray*}
I_2:=\frac{1}{k_ik_jn^2\beta^2(\pi\mathbf{i})^2}\oint_{\mathcal{C}_w}\oint_{\mathcal{C}_z} \frac{\left[\mathcal{G}_{\chi_i}(z)\right]^{k_i\beta}\left[\mathcal{G}_{\chi_j}(w)\right]^{k_j\beta}}{(z-w)^2}dz dw
\end{eqnarray*}



 Under Assumption \ref{ap62}, we deform the integral contour $\mathcal{C}_w$ to $\widetilde{\mathcal{C}}_w$ such that
 \begin{enumerate}
     \item $\widetilde{\mathcal{C}}_w=C_{w,1}\cup C_{w,2}$;
     \item $C_{w,1}$ lies in the upper half plane except two endpoints along the real axis;
     \item $C_{w,2}$ is the reflection of $C_{w,1}$ along the real axis;
     \item $[\mathbf{w}_+]^{-1}(C_{w,1})$ is the vertical line in $\mathcal{L}$ passing through $(\chi_j,0)$.
 \end{enumerate}
Similarly, we deform the integral contour $\mathcal{C}_z$ to $\widetilde{\mathcal{C}}_z$ such that
 \begin{enumerate}
     \item $\widetilde{\mathcal{C}}_z=C_{z,1}\cup C_{z,2}$;
     \item $C_{z,1}$ lies in the upper half plane except two endpoints along the real axis;
     \item $C_{z,2}$ is the reflection of $C_{z,1}$ along the real axis;
     \item $[\mathbf{w}_+]^{-1}(C_{z,1})$ is the vertical line in $\mathcal{L}$ passing through $(\chi_i,0)$.
 \end{enumerate}
 Then making a change of variables from $(z,w)\in \CC^2$ to $((\chi_1,\kappa_1),(\chi_2,\kappa_2))\in \mathcal{L}^2$ by $[\mathbf{w}_+]^{-1}\times [\mathbf{w}_+]^{-1}$ and the corresponding complex conjugates, we obtain
 \begin{small}
 \begin{eqnarray*}
 I_2&=&\frac{1}{k_ik_jn^2\beta^2(\pi\mathbf{i})^2}\oint_{\widetilde{\mathcal{C}}_w}\oint_{\widetilde{\mathcal{C}}_z} \frac{\left[\mathcal{G}_{\chi_i}(z)\right]^{k_i\beta}\left[\mathcal{G}_{\chi_j}(w)\right]^{k_j\beta}}{(z-w)^2}dz dw\\
 &=&\frac{1}{k_ik_jn^2\beta^2(\pi\mathbf{i})^2}\left[\int_{(\chi_j,\kappa_j)\in\mathcal{L}}\int_{(\chi_i,\kappa_i)\in\mathcal{L}} \frac{e^{-n\kappa_ik_i\beta}e^{-n\kappa_jk_j\beta}}{(\mathbf{w}_+(\chi_i,\kappa_i)-\mathbf{w}_+(\chi_j,\kappa_j))^2}\frac{\partial \mathbf{w}_+(\chi_i,\kappa_i)}{\partial \kappa_i}\frac{\partial \mathbf{w}_+(\chi_j,\kappa_j)}{\partial \kappa_j}d\kappa_i d\kappa_j\right.\\
  &&-\int_{(\chi_j,\kappa_j)\in\mathcal{L}}\int_{(\chi_i,\kappa_i)\in\mathcal{L}} \frac{e^{-n\kappa_ik_i\beta}e^{-n\kappa_jk_j\beta}}{(\mathbf{w}_+(\chi_i,\kappa_i)-\overline{\mathbf{w}_+(\chi_j,\kappa_j)})^2}\frac{\partial \mathbf{w}_+(\chi_i,\kappa_i)}{\partial \kappa_i}\frac{\partial\overline{ \mathbf{w}_+(\chi_j,\kappa_j)}}{\partial \kappa_j}d\kappa_i d\kappa_j\\
   &&-\int_{(\chi_j,\kappa_j)\in\mathcal{L}}\int_{(\chi_i,\kappa_i)\in\mathcal{L}} \frac{e^{-n\kappa_ik_i\beta}e^{-n\kappa_jk_j\beta}}{\overline{(\mathbf{w}_+(\chi_i,\kappa_i)}-\mathbf{w}_+(\chi_j,\kappa_j))^2}\frac{\partial \mathbf{w}_+(\chi_i,\kappa_i)}{\partial \kappa_i}\frac{\partial \overline{\mathbf{w}_+(\chi_j,\kappa_j)}}{\partial \kappa_j}d\kappa_i d\kappa_j\\
   &&+\left.\int_{(\chi_j,\kappa_j)\in\mathcal{L}}\int_{(\chi_i,\kappa_i)\in\mathcal{L}} \frac{e^{-n\kappa_ik_i\beta}e^{-n\kappa_jk_j\beta}}{\overline{(\mathbf{w}_+(\chi_i,\kappa_i)}-\overline{\mathbf{w}_+(\chi_j,\kappa_j)})^2}\frac{\partial \overline{\mathbf{w}_+(\chi_i,\kappa_i)}}{\partial \kappa_i}\frac{\partial \overline{\mathbf{w}_+(\chi_j,\kappa_j)}}{\partial \kappa_j}d\kappa_i d\kappa_j\right]\\
 \end{eqnarray*}
\end{small}

Integral by parts, we obtain that 
\begin{eqnarray*}
I_2&=&\frac{2}{(\pi\mathbf{i})^2}\int_{(\chi_j,\kappa_j)\in\mathcal{L}}\int_{(\chi_i,\kappa_i)\in\mathcal{L}}
e^{-n\kappa_ik_i\beta}e^{-n\kappa_jk_j\beta}
\log\left|\frac{\mathbf{w}_+(\chi_i,\kappa_i)-\mathbf{w}_+(\chi_j,\kappa_j)}{
\mathbf{w}_+(\chi_i,\kappa_i)-\overline{\mathbf{w}_+(\chi_j,\kappa_j)}
}\right|
d\kappa_i d\kappa_j\\
&=&4\mathrm{Cov}\left(
\int_{(\chi_i,\kappa_i)\in\mathcal{L}}e^{-n\kappa_ik_i\beta} \Xi(\mathbf{w}_+(\chi_i,\kappa_i)) d\kappa_i,
\int_{(\chi_j,\kappa_j)\in\mathcal{L}} \Xi(\mathbf{w}_+(\chi_j,\kappa_j))
e^{-n\kappa_jk_j\beta}d\kappa_j
\right).
\end{eqnarray*}
Then the proposition follows.
\end{proof}

\section{Examples}\label{sect:ex}

In section \ref{sect:ex}, we discuss specific examples of the rail-yard graph, such that the limit shape and height fluctuations of perfect matchings on these graphs can be obtained by the technique developed in the paper; these examplse include the pure steep tilings and pyramid partitions.

\subsection{Pyramid partitions}

A fundamental pyramid partition is a heap of square bricks such that
\begin{itemize}
    \item Each square brick is of size $2\times 2$ and has a length-2 central line dividing it into two equal-size rectangular parts; hence the direction of the central line determines the direction of the square brick; and
    \item Each square brick lies upon two side-by-side square bricks; and is rotated 90 degrees from the bricks immediately below it; and
    \item there is a unique brick on the top.
\end{itemize}

A pyramid partition is obtained from the fundamental pyramid partition by removing finitely many square bricks, such that if a square brick is removed, then all the square bricks above it are also removed.

Let $s$ be a fixed positive integer which is odd. Let $\Lambda_s$ be the set of pyramid partitions that can be obtained from the fundamental partition where the center of the square brick on the top is $(0,0)$ and where we can only take off bricks that lie inside the strip $-s-1\leq x-y\leq s+1$.
See Figure \ref{f91} for examples of pyramid partitions, and Figure \ref{f92} for the corresponding domino tilings and perfect matchings.

From Figures \ref{f91} and \ref{f92}, we can see that looking from the top each pyramid partition corresponds to a domino tiling of the square grid. From a pyramid partition, we can obtain a pure dimer covering on a rail-yard graph by the following steps:
\begin{enumerate}
\item rotate the pyramid partition clockwise by 45 degrees,  
\item For each blue vertex $v_b$, assume it has 4 incident edges $e_1,e_2,e_3,e_4$. Assume that $e_1$ and $e_2$ (resp.\ $e_3$ and $e_4$) are to the left (resp.\ right) of $v_b$. Split each blue vertex $v_b$ of the dual graph into 3 vertices, $v_{b_1}$, $v_{b_2}$, $v_{b_3}$ such that $v_{b_1}$ and $v_{b_3}$ are blue vertices while $v_{b_2}$ is a red vertex. The red vertex $v_{b_2}$ has exactly two incident edges joining it to $v_{b_1}$ and $v_{b_3}$, respectively. $v_{b_1}$ has 3 incident edges $e_1$ $e_2$ and $(v_{b_1},v_{b_2})$; while $v_{b_3}$ has 3 incident edges $e_3$ $e_4$ and $(v_{b_3},v_{b_2})$.
\item If one of $e_1,e_2$ (resp.\ $e_3,e_4$) is in the dimer covering, while neither $e_3$ nor $e_4$ (resp.\ neither $e_1$ nor $e_2$) are in the dimer covering, make $(v_{b_2},v_{b_3})$ (resp.\ $(v_{b_1},v_{b_2})$) present in the dimer covering and $(v_{b_1},v_{b_2})$ (resp. $(v_{b_2},v_{b_3})$) absent in the dimer covering.
\end{enumerate}
See Figure \ref{f93} (resp.\ Figure \ref{f94}) for the pure dimer covering on a rail-yard graph corresponding to the pyramid partition on the left graph (resp. right graph) of Figure \ref{f92}, in which the rail-yard graph corresponding the the left graph (resp. right graph) of Figure \ref{f92}
is bounded by the green curve.

\begin{proposition}
There is a one-to-one correspondence between pyramid partitions in $\Lambda_s$ and pure dimer coverings on the rail-yard graph such that for $i\in[-s..s-1]$
\begin{itemize}
    \item $a_i=L$ if $i$ is odd; and 
    \item $a_i=R$ if $i$ is even; and
    \item $b_i=+$ if $i<0$; and
    \item $b_i=-$ if $i\geq 0$.
\end{itemize}
Equivalently, there is a bijection between pyramid partitions in $\Lambda_s$ and sequences of partitions $(\lambda^{(-s)},\lambda^{(-s+1)},\ldots,\lambda^{(0)},\lambda^{(1)},\ldots,\lambda^{(s)})$ such that
\begin{eqnarray*}
\emptyset=\lambda^{(-s)}\prec\lambda^{(-s+1)}\prec'\lambda^{(-s+2)}\ldots\prec \lambda^{(0)}\succ'\lambda^{(1)}\succ\lambda^{(2)}\ldots\succ'\lambda^{(s)}=\emptyset.
\end{eqnarray*}
\end{proposition}
\begin{proof}
See Lemma 5.9 of \cite{you10} and Proposition 8 of \cite{BCC17}.
\end{proof}

\begin{figure}
\includegraphics[width=.35\textwidth]{prpt1.pdf}\qquad\qquad\qquad \includegraphics[width=.35\textwidth]{prpt3.pdf}
\caption{Pyramid partition with two types of bricks: each grey brick has a vertical central line while each white brick has a horizontal central line. The left graph is the pyramid partition with maximal number of bricks (fundamental pyramid partition); the right graph is obtained from the left graph by removing 3 bricks.}\label{f91}
\end{figure}

\begin{figure}
\includegraphics[width=.3\textwidth]{prpt.pdf}\qquad\qquad\qquad\includegraphics[width=.3\textwidth]{prpt2.pdf}
\caption{Looking from the top, pyramid partitions correspond to domino tilings, which are equivalent to perfect matchings on the dual graph. The left graph is the domino tiling corresponding to the fundamental pyramid partition, as shown in the left graph of Figure \ref{f91}; the right graph corresponds to pyramid partition with 3 bricks removed from the left graph, as shown in the right graph of Figure \ref{f91}.}\label{f92}
\end{figure}

\begin{figure}
\includegraphics[width=.9\textwidth]{pmry.pdf}
\caption{Pure dimer covering on a rail-yard graph corresponding to domino tiling on the left graph of Figure \ref{f92}, where the subgraph corresponding to the square grid in Figure \ref{f92} is bounded by the green curve.}\label{f93}
\end{figure}
\begin{figure}
\includegraphics[width=.9\textwidth]{pmry1.pdf}
\caption{Pure dimer covering on a rail-yard graph corresponding to domino tiling on the right graph of Figure \ref{f92}, where the subgraph corresponding to the square grid in Figure \ref{f92} is bounded by the green curve.}\label{f94}
\end{figure}

The formula to compute partition function of pyramid partitions was conjectured in \cite{Ken05,Sze08} and proved in \cite{BY09,you10}.

 Consider the pure dimer coverings on rail-yard graphs corresponding to pyramid partitions. Then we have $m=2$, $V_1=0$ and $V_0=-V_2$. Assume $n=2$; we obtain

When $\mathcal{G}_{\chi}$ is defined by (\ref{dgc}), we obtain that the frozen boundary has the following parametric equation (parametrized by $w$):
\begin{eqnarray*}
\begin{cases}
\frac{U_{\chi}(w)}{R(w)}=e^{-2\kappa}\\
f(e^{\chi}w^{-1})=wg(w).
\end{cases}
\end{eqnarray*}
where
\begin{eqnarray*}
f(s):=\frac{1}{1-\tau_1^{-1}s}
-\frac{1}{1+\tau_2^{-1}s}
\end{eqnarray*}
and
\begin{small}
\begin{eqnarray*}
g(w):&=&-\frac{1}{w-e^{V_1}\tau_1^{-1}}
+\frac{1}{w-e^{V_2}\tau_1^{-1}}
+\frac{1}{w-e^{V_0}\tau_1^{-1}}
+\frac{1}{w+e^{V_1}\tau_2^{-1}}
-\frac{1}{w+e^{V_2}\tau_2^{-1}}
-\frac{1}{w+e^{V_0}\tau_2^{-1}}
\end{eqnarray*}
\end{small}
and
\begin{eqnarray*}
U_{\chi}(w)&=&\frac{\left(1+e^{-\chi}w \tau_2\right)}{({1-e^{-\chi}w \tau_1})};
\end{eqnarray*}
\begin{eqnarray*}
R(w)&=&\frac{\left(1+e^{-V_0}w\tau_2\right)\left(1+e^{-V_2}w\tau_2\right)\left(1-e^{-V_1}\tau_1 w\right)}{\left(1-e^{-V_0}w\tau_1\right)\left(1-e^{-V_2}w\tau_1\right)\left(1+e^{-V_1}\tau_2 w\right)}
\end{eqnarray*}
By (\ref{dpl}), (\ref{dpr}), we obtain
\begin{eqnarray*}
p_{1,L}&=&\max\{p\in\{0,1,2\}:e^{V_p}\tau_1^{-1}<w\};\\
p_{2,R}&=&\max\{p\in\{0,1,2\}:w<-e^{V_p}\tau_2^{-1}\}.
\end{eqnarray*}
By (\ref{agm1})-(\ref{agm4}), we have
\begin{itemize}
    \item $w< 0$: then
    \begin{eqnarray*}
    \lim_{\epsilon\rightarrow 0+}\arg [R(w+\mathbf{i}\epsilon)]^{\frac{1}{2}}=
\frac{\pi}{2}\mathbf{1}_{b_2(p_{2,R},p_{2,R}+1)=+}
    \end{eqnarray*}
    and
    \begin{eqnarray*}
    \lim_{\epsilon\rightarrow 0+}\arg [U_{\chi}(w+\mathbf{i}\epsilon)]^{\frac{1}{2}}&=&\frac{\pi}{2}\mathbf{1}_
    {-\tau_2<e^{\chi}w^{-1}}
    \end{eqnarray*}
   \item $w\geq0$: then
    \begin{eqnarray*}
    \lim_{\epsilon\rightarrow 0+}\arg [R(w+\mathbf{i}\epsilon)]^{\frac{1}{2}}=
\frac{\pi}{2}\mathbf{1}_{b_1(p_{1,L},p_{1,L}+1)=+}
    \end{eqnarray*}
    and
    \begin{eqnarray*}
    \lim_{\epsilon\rightarrow 0+}\arg [U_{\chi}(w+\mathbf{i}\epsilon)]^{\frac{1}{2}}&=&
   \mathbf{1}_{e^{\chi}w^{-1}<\tau_1}
    \end{eqnarray*}
In order to make   
\begin{eqnarray*}
\lim_{\epsilon\rightarrow 0+}\arg [R(w+\mathbf{i}\epsilon)]^{\frac{1}{2}}= \lim_{\epsilon\rightarrow 0+}\arg [U_{\chi}(w+\mathbf{i}\epsilon)]^{\frac{1}{2}},
\end{eqnarray*}
 we have
 \begin{enumerate}
     \item If $w>e^{V_2}\tau_1^{-1}$, $e^{\chi}w^{-1}\in (0,\tau_1)$;
     \item If $w\in(e^{V_1}\tau_1^{-1},e^{V_2}\tau_1^{-1})$, $e^{\chi}w^{-1}\in (\tau_1,\infty)$;
     \item If $w\in(e^{V_0}\tau_1^{-1},e^{V_1}\tau_1^{-1})$, $e^{\chi}w^{-1}\in (0,\tau_1)$;
     \item If $w\in(0,e^{V_0}\tau_1^{-1})$, $e^{\chi}w^{-1}\in (\tau_1,\infty)$;
     \item If $w<-e^{V_2}\tau_2^{-1}$, $e^{\chi}w^{-1}\in (-\tau_2,0)$;
     \item If $w\in(-e^{V_2}\tau_2^{-1},-e^{V_1}\tau_2^{-1})$, $e^{\chi}w^{-1}\in (-\infty,-\tau_2)$;
     \item If $w\in(-e^{V_1}\tau_2^{-1},-e^{V_0}\tau_2^{-1})$, $e^{\chi}w^{-1}\in (-\tau_2,0)$;
     \item If $w\in(-e^{V_0}\tau_2^{-1},0)$, $e^{\chi}w^{-1}\in (-\infty,-\tau_2)$;
    \end{enumerate}
\end{itemize}
Hence for each $w\in \mathbb{R}\setminus \{\pm e^{V_p}\tau_j^{-1},0\}_{p\in\{0,1,2\},j\in\{1,2\}}$, we can find a unique $\chi$ satisfying (1)-(8) and $f(e^{\chi}w^{-1})=wg(w)$; then knowing $w$ and $\chi$ we can find a unique $\kappa$ by $\frac{U_{\chi}(w)}{R(w)}=e^{-n\kappa}$. See Figure \ref{f95} for frozen boundary of pyramid partitions.


\begin{figure}
\includegraphics[trim=150 100 150 0, clip,width=.5\textwidth]{lspp1.pdf}
\includegraphics[trim=150 80 150 120, clip,width=.47\textwidth]{lspp2.pdf}
\caption{Frozen boundary of pyramid partitions with parameters $V_0=-1$, $V_1=0$, $V_2=1$. The left graph has $\tau_1=\tau_2=1$, the right graph has $\tau_1=10,\tau_2=1/10$.}\label{f95}
\end{figure}
 
 

    








\subsection{Steep tilings}

A domino is a $2\times 1$ (horizontal domino) or $1\times 2$ (vertical domino) rectangle whose corners have integer coordinates. Let $s$ be a fixed positive integer. An oblique strip of width $2s$ is the region of the Cartesian plane between the lines $y=x$ and $y=2s$. A tiling of oblique strip is a set of dominoes whose interior are disjoint, and whose union is the tiled region $R$ satisfying
\begin{eqnarray*}
\{(x,y)\in\RR^2:x-y\in[1,2s-1]\}\subseteq R\subseteq \{(x,y)\in\RR^2:x-y\in[-1,2s+1]\}
\end{eqnarray*}

A horizontal (resp.\ vertical) domino is called north-going (resp.\ east-going) if the sum of the coordinates of its top left corner is odd, and south-going (resp.\ west-going) otherwise (see \cite{CEP96}). A tiling of an oblique strip is called steep if moving towards infinity in the northeast (resp.\ southwest) direction, eventually there are only north- or east-going (resp.\ south- or west-going) dominoes.

For each given sequence $(b_0,\ldots,b_{2s})\in\{\pm 1\}^{2s}$, and each left and right boundary condition $\lambda^{(0)}$ and $\lambda^{(2s+1)}$, there is a one-to-one correspondence between pyramid partitions in $\Lambda_s$ and pure dimer coverings on the rail-yard graph such that for $i\in[0..2s]$
\begin{enumerate}
    \item $a_i=L$ if $i$ is odd; and 
    \item $a_i=R$ if $i$ is even.
\end{enumerate}

The formula to compute the partition function of steep tilings was proved in \cite{BCC17}.

\bigskip
\bigskip
