text:
\section{Introduction}
\label{sec:intro}
With the proliferation of digitalized data, and with the rapid advances in deep learning, there is an ever-increasing demand to benefit from insights that can be extracted from state-of-the-art deep learning models, while still not sacrificing on data privacy \cite{geyer2017differentially,yang2019federated}.
For effective training, these models would require a huge amount of data, which is usually distributed over a large heterogeneous network of clients who are not willing to share their private data. Federated learning (FL) promises to solve these key issues, by training a global model collaboratively over decentralized data at local clients \cite{konevcny2016federated2,mcmahan2017communication}.

The key idea of FL is that all clients keep their private data and share a global model under the coordination of a central server, which is summarized as the \texttt{FedAvg} algorithm \cite{mcmahan2017communication}.
In a typical communication round, a fraction of the clients, selected by the server, would download the current global model and perform training on local data.
Next, the server performs model aggregation to
compute a new global model, based on all updated models transmitted by the selected clients.
However, in real-world non-IID data distributions, FL in heterogeneous networks would face many statistical challenges, such as model divergence and accuracy reduction \cite{smith2017federated,li2019convergence,ghosh2019robust,karimireddy2020scaffold}.

{\bf Related work:} A theoretical analysis of the convergence of \texttt{FedAvg} in non-IID data settings is given in \cite{li2019convergence}.
\texttt{FedProx}, a general optimization framework with robust convergence guarantees, was proposed in \cite{li2020prox} to tackle data heterogeneity by introducing a proximal term in the local optimization process.
In \cite{karimireddy2020scaffold}, a stochastic algorithm \texttt{SCAFFOLD} was proposed to reduce the variance and gradient dissimilarity in local FL updates, which yields better communication efficiency and faster convergence. To address fairness issues in FL, $q$-Fair Federated Learning (\texttt{\emph{q}-FFL})~\cite{li2019fair} and Agnostic Federated Learning (\texttt{AFL})~\cite{mohri2019agnostic} were proposed as modified federated optimization algorithms that improve fairness in performance across clients.

In \cite{wang2019fedma}, a layer-wise Federated Matched Averaging (\texttt{FedMA}) algorithm was proposed for CNN-based and LSTM-based FL models.
Ji \emph{et al.}~\shortcite{ji2019learning} also introduced a layer-wise attentive aggregation method for federated optimization, which has lower perplexity and communication cost for neural language models.
Other methods have been proposed to tackle data heterogeneity and communication efficiency, from the perspective of asynchronous optimization \cite{xie2019asynchronous}, model compression \cite{konevcny2016federated2,sattler2019robust}, personalized training \cite{deng2020adaptive}, and incentive design \cite{yu2020fairness,kang2019incentive}.

There are also several works in FL that tackle performance degradation in non-IID data settings, but for which the data privacy assumption in FL is not strictly adhered to.
These works require a small amount of raw data to be shared either among clients \cite{zhao2018federated} or with the global server \cite{jeong2018communication}.
\texttt{FedMix} \cite{yoon2021fedmix} avoids the direct sharing of raw data, by incorporating \textit{mixup} data augmentation \cite{zhang2018mixup} into FL, whereby clients share averaged data with each other.
Such methods would require the exchange of raw or averaged data, which no longer guarantee strict data privacy, and which also require additional communication cost.

In each communication round of the usual FL framework, a fixed fraction of the clients is selected, based on a fixed probability distribution.
A good choice for this fraction is not clear.
Small fractions are widely used in existing work  \cite{mcmahan2017communication,karimireddy2020scaffold}, but when such small fractions are used, data heterogeneity inadvertently causes fluctuations in training performance and reduces the rate of convergence~\cite{li2019convergence}.
Large fractions yield a more stable performance, as well as a slight acceleration in convergence, but at the expense of a larger communication cost~\cite{li2019convergence}.
Hence, to obtain a stable training performance with relatively low communication cost, we shall instead consider a dynamic fraction method that captures the advantages of both small and large fractions.

The selection probability for each client is a measure of the ``importance'' of that client. Thus, in heterogeneous networks where different clients have different ``importance'', the fixed client selection probability distribution used in the usual FL is typically non-uniform.
However, the relative contribution of each client is fluid. It depends on both the client's local model performance, and on the actual aggregated global model, so the ``importance'' of the clients may vary during training.

With these considerations, we propose
an attention-based adaptive federated learning algorithm,
which we shall call \texttt{AdaFL}.
The attention mechanism in \texttt{AdaFL} serves to better capture the relative ``importance'' among the clients, by taking into account the divergence of the local updated models, relative to the global model.
Our method gives clients who have worse models a higher chance to participate in training.
\texttt{AdaFL} also incorporates a dynamic fraction method to balance the trade-off between small and large fractions,
which essentially represents the trade-off between communication efficiency and performance stability.

Our contributions are summarized as follows:
\setlist{nosep}
\begin{itemize}
    \item We introduce a method to update the client selection probability in FL, by using a distance-based attention mechanism, so as to better capture the heterogeneity of client performance.

    \item To the best of our knowledge, we are the first to propose a dynamic fraction method in FL.
    We show that by increasing the fraction progressively, we can improve both the performance stability and the final model accuracy, while concurrently achieving lower communication and computation costs.

    \item We propose \texttt{AdaFL}, which combines both methods. We show experimentally the outperformance of \texttt{AdaFL} over \texttt{FedAvg} with respect to model accuracy, performance stability, and communication efficiency. We also show that \texttt{AdaFL} can be incorporated to enhance the performance of various state-of-the-art FL algorithms.
\end{itemize}

\section{Proposed method}
\label{sec:method}

The training of FL would typically be performed based on updates over hundreds, or even thousands of communication rounds.
In this section, we introduce the preliminaries of FL ~\cite{mcmahan2017communication}, and show the details of our proposed algorithm within each round.
For concreteness, we assume in this paper that FL is used to learn a global neural network model.

\begin{figure}[tb!]

  \begin{minipage}[b]{1.0\linewidth}
    \centering
    \centerline{\includegraphics[width=8.5cm]{model_single}}

  \end{minipage}

  \caption{An illustration of the FL framework, with $M$ clients. In communication round $t$, the server selects and distributes a global model $\mathbf{W}^{(t)}$ to a subset of clients based on $\bf{a}^{(t)}$ (Downlink Update). Then, the selected clients compute and transmit their local models \{$\mathbf{W}^{(t)}_{i}$\} to the server (Uplink Update).}
  \label{fig:model}

  \end{figure}

\subsection{Preliminaries of FL and \texttt{FedAvg} Algorithm}
\label{ssec:subfed}

The FL framework consists of one central server and multiple clients. Clients participate in training a shared global model under the coordination of the server, without having to share private data.
Given $M$ clients, let $n_k$ be the number of datapoints that client $k$ has, and let $n := n_1 + \dots + n_M$ be the total number of datapoints. In the usual FL set-up, the stochastic vector $\mathbf{n} := [\tfrac{n_1}{n}, \dots, \frac{n_M}{n}]$ represents the discrete probability distribution used for client selection, where $p_k := \tfrac{n_k}{n}$ is the probability that client $k$ is selected in each communication round.
The optimization problem that FL tackles can thus be formulated as the minimization problem:
\vspace*{0.6em}
\[\min _{w} f(w)=\smash{\sum_{k=1}^{M}} \ p_{k} f_{k}(w),\]
where $f_{k}$ is the local loss function of client $k$, whose input $w$ is the set of model parameters of a fixed model architecture.

The \texttt{FedAvg} algorithm summarizes how this FL optimization problem is solved~\cite{mcmahan2017communication}.
In each communication round, a small group of clients is selected and local training is performed at each client, based on the same model downloaded from the global server.
The main idea is that the gradient updates from the clients are aggregated at the server via a weighted average.
At the end of round $t$, the server updates the model parameters with gradient descent
via $w_{t+1} \leftarrow w_{t}-\eta \nabla\!f(w_{t})$,
where $\nabla\!f(w_{t})= \sum_{k \in \mathcal{S}_t} \tfrac{n_k}{n_{\mathcal{S}_t}}g_{k}$,
and $\eta$ is the learning rate.
Here, $g_{k}$ is the local update of selected client $k$,
\smash{$\mathcal{S}_t$} is the subset of selected clients in round $t$,
and \smash{$n_{\mathcal{S}_t} := \sum_{i\in \mathcal{S}_t} n_i$}.
The number $K = |\mathcal{S}_t|$ of selected clients is calculated by the formula $K=\gamma \cdot M$, where $\gamma$ (satisfying $0<\gamma<1$) denotes the \textit{fraction} of the selected clients.

In this usual \texttt{FedAvg} algorithm, both the probability distribution for client selection and the fraction $\gamma$ of selected clients, are kept invariant throughout all communication rounds.
In the next two subsections, we explain how \texttt{AdaFL} varies the client selection probability distribution, and varies the fraction $\gamma$, respectively.

\subsection{Attention Mechanism}
\label{ssec:subattention}

In any real-world FL implementation on non-IID client data, the relative training performances of different clients cannot be predicted in advance. Different clients could have different relative importance towards model aggregation, which could vary over different communication rounds.
To avoid making idealistic assumptions, we shall take a data-driven approach. We introduce an attention mechanism to measure the relative importance of the different clients, and adjust the probability distribution for client selection accordingly, based on real-time local training performance.
Our approach differs from existing FL approaches, e.g. ~\cite{konevcny2016federated2,mcmahan2017communication,li2019fair,ji2019learning}, where client selection is not modified and hence independent of the local training performance of the clients.

We shall use Euclidean distance as a measure of the model divergence of each local model, relative to the global model.
The vector of attention scores $\mathbf{a}^{(t)}=[a^{(t)}_1, a^{(t)}_2,..., a^{(t)}_M]$ in round $t$ is identical to the corresponding client selection probability distribution $\mathbf{p}=[ p_1,p_2,...,p_M]$ for that round $t$, and it is initialized in the first round as $\mathbf{a}^{(1)}= \mathbf{n} $.

Specifically, at the beginning of round $t$, the server selects $K$ clients, according to the probability distribution $\mathbf{p}$.
Local training then occurs. We shall denote the local models of the selected clients by
\smash{$\mathbf{W}^{(t)}_{i_1}, \mathbf{W}^{(t)}_{i_2},...,\mathbf{W}^{(t)}_{i_K}$}, where $i_j$ is the index of the $j$-th client in the selected subset $\mathcal{S}_t$ (for round $t$).
Each $\mathbf{W}^{(t)}_{i_j}$ is a collection of weight matrices for the layers of the neural network.
After aggregation at the server, we obtain a new global model, denoted by $\mathbf{W}^{(t+1)}$.
The process in a typical round is shown in Fig. \ref{fig:model}.

Identify each $r$-by-$s$ weight matrix as a vector in $\mathbb{R}^{rs}$ and concatenate all such vectors, so that \smash{$\mathbf{W}^{(t)}_{i_j}$} is represented by a single parameter vector \smash{$\mathbf{w}^{(t)}_{i_j}$}.
Thus, the $K$ local models and the new global model are represented by the vectors
\smash{$\mathbf{w}^{(t)}_{i_1}, \mathbf{w}^{(t)}_{i_2},\dots ,\mathbf{w}^{(t)}_{i_K}$} and
\smash{$\mathbf{w}^{(t+1)}$} respectively.
For selected client $i \in \mathcal{S}_t$ in round $t$, we calculate the Euclidean distance between the global and local parameter vectors as follows:
\begin{equation}\label{eqn:dt}
d^{(t)}_{i}=\left\|\mathbf{w}^{(t+1)}-\mathbf{w}_{i}^{(t)}\right\|_{2}.
\end{equation}
To reduce the fluctuations in attention scores of consecutive rounds, we incorporate the current attention score in our updating criterion:
\begin{equation}\label{eqn:at}
a^{(t+1)}_{i}=\alpha a^{(t)}_{i} + (1-\alpha) \cdot \frac{d^{(t)}_{i}}{\sum_{k \in \mathcal{S}_t}d^{(t)}_{k}} \sum_{k \in \mathcal{S}_t}a^{(t)}_{k},
\end{equation}
where $\alpha \in [0,1)$ represents a decay rate of previous attention score contributions.
For an unselected client $j$, we set \smash{$a^{(t+1)}_j=a^{(t)}_j$}.
Note that $\mathbf{a}^{(t+1)}$ remains as a stochastic vector.
Client selection in round $t+1$ then follows the updated
probability distribution $\mathbf{p} = \mathbf{a}^{(t+1)}$.

Since our work does not deal with the usual federated optimization, our attention mechanism only updates the client selection probability distribution and will not change the aggregation weights. Moreover, the additional communication cost brought by our proposed algorithm is negligible.
Notice also that by \eqref{eqn:dt} and \eqref{eqn:at}, a larger Euclidean distance between the vectors for the global model \smash{$w^{(t+1)}$} and local model \smash{$w^{(t)}_{i}$} will increase the probability that client $i$ would be selected in the next communication round. Subsequently, more training and computation would be done at the corresponding clients to obtain a better performance.
Hence, the overall effect is a fairer scheme, whereby the variance of local training performances among the clients is deliberately reduced.

\subsection{Dynamic Fraction for  Client Selection }
\label{ssec:subada}

How do we choose a ``good'' fraction $\gamma$ for client selection? What is considered ``good'' will depend on how we want to balance the trade-off between communication efficiency and performance stability.
A smaller $\gamma$ would mean a lower communication cost in each communication round, but at the expense of larger fluctuations in training performance, and a slower rate of convergence \cite{li2019convergence}; this implies that more training rounds are required to reach a desired performance level.
A larger $\gamma$ would bring better performance stability, and less communication rounds, but at the expense of a larger total communication cost.
Under the usual assumption in FL that $\gamma$ is fixed throughout training, we would then be forced to choose between communication efficiency and performance stability.

\begin{figure}[tb!

  \begin{minipage}[b]{1.0\linewidth}
    \centering
    \centerline{\includegraphics[width=8.5cm]{frac6-eps-converted-to}}
  \end{minipage}
  \caption{An example of our dynamic fraction scheme. $\Delta_T$  is the fixed
  step size (number of communication rounds) between two consecutive fraction updates in the training. $\Delta_\gamma$ is the increasing step of the fraction.}
  \label{fig:ada_frac}
  \end{figure}

To circumvent this trade-off, we drop the assumption that $\gamma$ is fixed, and propose a dynamic fraction method, which adopts different fractions during different training stages, with the fraction increasing progressively. As an explicit example, depicted in Fig. \ref{fig:ada_frac}, we begin training with a small fraction $0.1$, and end training with a large fraction $0.5$. (Here, $0.1$ and $0.5$ are arbitrarily selected.) When using gradient descent, our method yields a relatively good performance, even with fewer clients involved at the beginning of training. With an increased amount of local training data in subsequent rounds, the training performance would have a more stable convergence. Intuitively, the updated global model gradients would be closer to optimal gradients that reflect the true data distribution, as there are increasingly more clients (and hence more data) involved in training, as the fraction increases.

To represent dynamic fractions, we shall use $\boldsymbol{\gamma}$ to denote the vector of fractions, whose $t$-th entry $\boldsymbol{\gamma}^{(t)}$ is the fraction used in the $t$-th communication round.
Since $T$ is the total number of communication rounds, $\boldsymbol{\gamma}^{(1)}$ (resp. $\boldsymbol{\gamma}^{(T)}$) is the starting (resp. ending) fraction used in our dynamic fraction method.
For simplicity, we recommend using a fixed step size $\Delta_T$ between consecutive fraction updates, and a fixed increment $\Delta_{\gamma}$ when updating the fraction $\gamma$; this means that $\Delta_T=\tfrac{1}{F} \cdot T$ and $\boldsymbol{\gamma}^{(T)} - \boldsymbol{\gamma}^{(1)} = (F-1)\Delta_{\gamma}$, where $F$ is the desired number of distinct fractions to be used. The vector $\boldsymbol{\gamma}$ can be computed accordingly.
Observe that in our running example (see Fig.~\ref{fig:ada_frac}), we used $F = 5$, so that each fraction update, which increases the value of $\gamma$ by $\Delta_{\gamma} = \tfrac{1}{F} = 0.1$, occurs at every $\Delta_T = \tfrac{1}{F}\cdot T = 0.2T$ communication rounds.

Although we only consider fixed $\Delta_T$ and $\Delta_\gamma$ for simplicity, it should be noted that our method works for any number $F$ of fraction values and any non-constant $\Delta_{\gamma}, \Delta_T$,
and more generally, for any non-constant fraction $\gamma$ that is monotonically increasing from $\boldsymbol{\gamma}^{(1)}$ to $\boldsymbol{\gamma}^{(T)}$.
In this paper, we do not address all the different (infinitely many) types of monotonically increasing $\gamma$ that could be used for our proposed dynamic fraction method; In our experiments, this simple use of multiple fraction values as described above, is already sufficient to yield performance improvement over the use of constant fraction.

\subsection{Algorithm Summary}
\label{ssec:subalgo}
Adaptive Federated Learning (\texttt{AdaFL}), our proposed method, combines both the attention mechanism described in Section~\ref{ssec:subattention}, and the dynamic fraction method described in Section~\ref{ssec:subada}.
The juxtaposition of these two components, on top the usual \texttt{FedAvg} algorithm, incorporates adaptive training adjustments, thereby yielding better communication efficiency with better performance stability.
We give an overview of \texttt{AdaFL} in Algorithm 1.
\begin{algorithm}
  \caption{Adaptive Federated Learning \texttt{(AdaFL)}}
  \label{alg: AdaFL}
  \textbf{Inputs:} $M, T, \boldsymbol{\gamma}, \alpha, \mathbf{W}^{(1)}, \mathbf{n}$
  \begin{algorithmic}[1]
\STATE{$\mathbf{a}^{(1)} \gets \mathbf{n}$}
\FOR {$t=1$ \textbf{to} $T$}
    \STATE{$\mathbf{p} \gets \mathbf{a}^{(t)}$ and $K \gets \boldsymbol{\gamma}^{(t)} \cdot M$}
    \STATE{Server selects a subset of clients $\mathcal{S}_t$ of size $|\mathcal{S}_t|=K$}
		\STATEx{\ \ \ \ using probability distribution $\mathbf{p}$}
    \STATEx{\vspace*{-0.7em}}
    \STATEx{\ \ \ \ \textit{// local computation at clients}}
    \FOR{\textbf{selected client} $k \in \mathcal{S}_t$}
        \STATE{Client $k$ downloads global model $\mathbf{W}^{(t)}$}
        \STATE{Client $k$ computes local model $\mathbf{W}_k^{(t)}$}
    \ENDFOR
    \STATEx{\vspace*{-1.0em}}
    \STATEx{\ \ \ \ \textit{// global computation at server}}
    \STATE{Server computes a new global model by aggregation:
    \vspace*{-0.3em}
    \[\mathbf{W}^{(t+1)} \leftarrow \textstyle\sum_{k \in \mathcal{S}_t}  \tfrac{n_k}{n_{\mathcal{S}_t}}\mathbf{W}^{(t)}_{k}\]}
    \vspace*{-1.0em}
    \FOR {\textbf{selected client} $i \in \mathcal{S}_t$}
        \STATE{Server updates $d^{(t)}_{i} \gets \big\|\mathbf{w}^{(t+1)}-\mathbf{w}_{i}^{(t)}\big\|_{2}$ \ \ and}
				\STATEx{\ \ \ \ \ \ \ \ $a^{(t+1)}_{i} \gets \alpha a^{(t)}_{i} + (1-\alpha) \cdot \tfrac{d^{(t)}_{i}}{\sum_{k \in \mathcal{S}_t}d^{(t)}_{k}} \textstyle\sum_{k \in \mathcal{S}_t}a^{(t)}_{k}$}
    \ENDFOR
    \FOR {\textbf{unselected client} $j \notin \mathcal{S}_t$}
        \STATE{Server updates $a^{(t+1)}_j \gets a^{(t)}_j$}
    \ENDFOR
\ENDFOR
  \end{algorithmic}

\end{algorithm}
The key difference of our proposed \texttt{AdaFL} algorithm over the \texttt{FedAvg} algorithm is the adaptive parameter adjustment scheme.
Parameters are adjusted by using real-time information from local training.
Hence, the central server also plays a dual role as a resource allocator during training, in addition to its usual role of coordinating the aggregation of local weights in each communication round.
The resource allocation can be made fairer by improving the weights of clients with larger model divergence.

It should be noted that our proposed algorithm complements existing communication-efficient federated algorithms, such as compression~\cite{konevcny2016federated2,sattler2019robust}, data augmentation~\cite{yoon2021fedmix} and some optimization methods for federated learning~\cite{li2020prox,karimireddy2020scaffold}.
Later in our experiments, we show how our proposed \texttt{AdaFL} can enhance the performance of existing popular FL algorithms.

\section{Experiments}
\label{sec:exp}

In this section, we describe the details of our experiments, and evaluate the performance of our proposed \texttt{AdaFL} algorithm.

\subsection{Experiment Setup}
\label{ssec:subexp}

We evaluate our \texttt{AdaFL} algorithm on image classification tasks on two image datasets, MNIST~\cite{lecun1998gradient}
and CIFAR-10~\cite{krizhevsky2009learning}, with neural network models.
For experiments on the MNIST dataset, we train a Multi-Layer-Perceptron (MLP) model (2 hidden layers, each layer with 200 units and ReLU activation) with a fixed learning rate $\eta=0.01$. For training data samples, we use the non-IID data partition as described in \cite{mcmahan2017communication}.
For experiments on the CIFAR-10 dataset, we train a CNN model with the same model architecture as given in \cite{yoon2021fedmix}, with IID data partition. We used an initial learning rate of $\eta=0.01$ with a decay of $0.99$ across the communication rounds.
In all our experiments, across all FL algorithms, we train a local model at each selected client via stochastic gradient descent (SGD), using momentum coefficient $0.5$.

The remaining parameter settings are given as follows. We use $M=100$ clients for training. The number of local epochs and batch size are set as $E=5$ and $B=10$ respectively.
The initial attention score vector $\mathbf{a}^{(1)}$ is determined by the local dataset size as described in Algorithm \ref{alg: AdaFL}.
For our attention score update process, we fix $\alpha=0.9$.
For the local dataset size, we consider a balanced data distribution for all experiments, in which every client has the same local dataset size (number of local training samples); this implies that the initial attention score of each client is $\frac{1}{100}$.
For the dynamic selection of fractions, we use $\boldsymbol{\gamma}^{(1)}=0.1$ and $\boldsymbol{\gamma}^{(T)}=0.5$, with increments of $\Delta_\gamma=0.1$ (see Fig. \ref{fig:ada_frac}).

\subsection{Ablation Study}
\label{ssec:subcomp}

We report our ablation study results in Tables \ref{table:ablation} and \ref{table:rnd_ablation}, in which we evaluate the performances of our proposed \texttt{AdaFL} on the two datasets, with and without the two components in \texttt{AdaFL}: the attention mechanism and the dynamic fraction method.
We use \texttt{FedAvg-0.1} and \texttt{FedAvg-0.5} as our baselines, which refer to the usual \texttt{FedAvg} algorithm with a constant fraction of $\gamma = 0.1$ and $\gamma = 0.5$ respectively.
For illustration, a comparison of \texttt{AdaFL} with both baselines \texttt{FedAvg-0.1} and \texttt{FedAvg-0.5}, over all $500$ communication rounds of our experiments on MNIST, is given in Fig. \ref{fig:acc}. In particular, Fig. \ref{fig:acc} shows that \texttt{AdaFL} has the advantages of both \texttt{FedAvg-0.1} and \texttt{FedAvg-0.5}, which starts training with smaller communication cost, and ends training with better performance stability and test accuracy.

For both Tables \ref{table:ablation} and \ref{table:rnd_ablation}, we write \texttt{Attn.-0.1} and \texttt{Attn.-0.5} to mean that we apply only the attention mechanism to \texttt{FedAvg} with a constant fraction of $\gamma = 0.1$ and $\gamma = 0.5$ respectively, while we write \texttt{Dyn.\,FedAvg} to mean that we apply only the dynamic fraction method (with the fraction increasing progressively from $0.1$ to $0.5$, with $T=1500$) to \texttt{FedAvg}, without the attention mechanism.

In Table \ref{table:ablation}, we report the ``best test accuracies'' of all aforementioned methods, on both datasets. However, it should be noted that our chosen model architectures do not yield state-of-the-art ``best accuracies'' on the respective datasets,
since our goal is to show that \texttt{FedAvg} can be improved with our two proposed components in \texttt{AdaFL}.
Due to the natural random fluctuations in test accuracy performance over consecutive communication rounds, we shall also report ``average test accuracy'' as a measure of performance stability; see Section \ref{sssec:ablacc} for more details.
In Table \ref{table:rnd_ablation}, we report the number of communication rounds and total communication cost that each method takes to reach a specified target accuracy,
which is chosen to be close to the corresponding best accuracy as given in Table \ref{table:ablation}; see Section \ref{sssec:ablcomm} for more details.

\begin{figure}[tb!

    \begin{minipage}[b]{1.0\linewidth}
      \centering
      \centerline{\includegraphics[clip,trim=0 0.2cm 0 0.95cm,width=9.5cm]{acc_fig-eps-converted-to}}

    \end{minipage}

    \caption{A comparison of the test accuracy between \texttt{AdaFL} and \texttt{FedAvg} on MNIST with non-IID local data.
    Here, we used a dynamic fraction scheme, starting from $\gamma = 0.1$ and increasing to $\gamma = 0.5$.
    This figure shows that (i): \texttt{AdaFL} has better performance stability than \texttt{FedAvg} at smaller fractions; and (ii): \texttt{AdaFL} has better test accuracy than \texttt{FedAvg} at larger fractions.}
    \label{fig:acc}

    \end{figure}

For the rest of this subsection, we shall evaluate the two components of \texttt{AdaFL} (using $T=1000$) with respect to (i) accuracy and performance stability; and (ii) required number of communication rounds and total communication cost, respectively.

\subsubsection{Accuracy Performance}
\label{sssec:ablacc}
We use average accuracy and best accuracy to evaluate the outperformance and convergence stability. To better capture the notion of performance stability, we use the average accuracy of the last $\ell$ rounds as a key performance metric (we use $\ell = 10$ in our experiments). As the results in Table \ref{table:ablation} show, our experiments on both datasets, for which training end with a larger fraction (\texttt{AdaFL}, \texttt{Attn.-0.5} and \texttt{Dyn.\,FedAvg}) have higher average accuracies and hence better performance stability.

Thus, the attention component increases model accuracy, while the dynamic fraction component improves performance stability.
Compared to the two baselines (\texttt{FedAvg-0.1} and \texttt{FedAvg-0.5}), \texttt{AdaFL} achieved higher accuracies
on both MNIST ($0.43\%$--$2.45\%$) and CIFAR-10 ($0.71\%$--$1.5\%$), with better performance stability.
The experiments with the attention mechanism incorporated (\texttt{AdaFL}, \texttt{Attn.-0.1} and \texttt{Attn.-0.5}) have higher best accuracy performance.

\begin{table}[htb]

    \centering
    \begin{tabular}{>{\small}ccccc}

    \toprule

    \multirow{2}{*}{\bf{Algorithm}}
    & \multicolumn{2}{c}{\bf{MNIST}} & \multicolumn{2}{c}{\bf{CIFAR-10}} \\
    \cmidrule(){2-3} \cmidrule(){4-5}

                  & Average   & Best       & Average   & Best        \\ \midrule
    \addlinespace[0.04cm]

    \texttt{AdaFL}  & {\bf 91.13}& {\bf 91.64}&  74.38   & {\bf 76.17}         \\
    \addlinespace[0.01cm]
    \hline
    \addlinespace[0.04cm]
    \texttt{Attn.-0.1}  &  88.92     &  91.30     & 73.13       & 74.91             \\
    \addlinespace[0.04cm]
    \texttt{Attn.-0.5}  &  91.07    &  91.58     &  {\bf74.42}  & 75.96             \\
    \addlinespace[0.04cm]
    \texttt{Dyn.\,FedAvg}   &90.33     &91.19      & 74.33       & 75.04             \\
    \addlinespace[0.04cm]
    \hline
    \addlinespace[0.04cm]
    \texttt{FedAvg-0.1}    & 88.68    & 91.05    & 72.88    &  74.82     \\
    \addlinespace[0.04cm]

    \texttt{FedAvg-0.5}    & 90.40    & 91.21    & 73.67     &  75.31       \\

    \addlinespace[0.01cm]

    \bottomrule
    \end{tabular}
    \caption{Ablation study in terms of average and best test accuracy performances (averaged over $3$ trials). Each value in the Average column represents the average test accuracy of the last $10$ communication rounds, which serves dually as a measure of performance stability. Each value in the Best column represents the best test accuracy achieved over all communication rounds.}
    \label{table:ablation}
    \end{table}

\subsubsection{Communication Efficiency Performance}
\label{sssec:ablcomm}

We define communication cost in terms of relative units, where each relative unit is the cost of transmitting data representing all parameter updates of a single neural network model, from a single client to the global server, in a single communication round.
Given $\boldsymbol{\gamma}$ and the required number $T^*$ of communication rounds to reach target accuracy, we define the \textit{total communication cost} to be {$\sum_{t=1}^{T^*} \boldsymbol{\gamma}^{(t)} \cdot M$}; this value is the total number of relative units across all $T^*$ communication rounds.
Hence, \textit{better communication efficiency} shall mean a lower total communication cost.

\begin{table}[htb]

    \centering
    \begin{adjustbox}{width=\columnwidth,center}

    \begin{tabular}{ccccc}

    \toprule

    \multirow{2}{*}{\bf{Algorithm}}
      & \multicolumn{2}{c}{\bf{MNIST}} & \multicolumn{2}{c}{\bf{CIFAR-10}} \\
    \cmidrule(){2-3} \cmidrule(){4-5}

                  & 90\%      & 91\%   &      &  73\%      \\ \midrule
    \addlinespace[0.01cm]

    \texttt{AdaFL}  & {\bf 423}\,({\bf 6690}) &{\bf761}\,({\bf18440})& &{\bf 683}\,({\bf 15320})    \\
    \addlinespace[0.04cm]
    \hline
    \addlinespace[0.04cm]
    \texttt{Attn.-0.1} &939\,(9390) &1952\,(19520) & & 1571\,(15710) \\
    \addlinespace[0.04cm]
    \texttt{Attn.-0.5} &420\,(21000) &741\,(37050) & &635\,(31570) \\
    \addlinespace[0.04cm]
    \texttt{Dyn.\,FedAvg} &951\,(20040) & 1485\,(44250)& &1103\,(26120) \\
    \addlinespace[0.04cm]
    \hline
    \addlinespace[0.04cm]
    \texttt{FedAvg-0.1}    & 1008\,(10080)   &  2528\,(25280)  &       &   1957\,(19570)    \\
    \addlinespace[0.04cm]

    \texttt{FedAvg-0.5}    & 570\,(28500)  &  1232\,(61600)   &       &   892\,(44600)    \\
    \addlinespace[0.01cm]

    \bottomrule
    \end{tabular}
    \end{adjustbox}
    \caption{Ablation study in terms of the required number of rounds (values preceding brackets) and the total communication cost (values in brackets) to reach the specified target test accuracy. All reported values are averaged over $3$ trials. For a fair evaluation, the stopping criterion used is that the average test accuracy of the last $5$ rounds must exceed the target test accuracy.}
    \label{table:rnd_ablation}

    \end{table}

As Table \ref{table:rnd_ablation} shows, the use of larger fractions would require less communication rounds to reach the specified target accuracies, while the use of small fraction (with lower communication cost per round) would require more communication rounds to reach stable convergence, i.e. a larger total communication cost.
In comparison, the use of dynamic fractions not only yields faster stable convergence, but also has better communication efficiency.

To conclude, the ablation study results reported in Tables \ref{table:ablation} and \ref{table:rnd_ablation} show conclusively that both components in \texttt{AdaFL} contribute towards the outperformance over \texttt{FedAvg}.

\subsection{Performance Evaluation}
\label{perf_ana}
As discussed earlier in Section~\ref{sec:intro},
\texttt{FedProx} and \texttt{SCAFFOLD} are federated optimization methods, while \texttt{FedMix} is a data augmentation method designed for FL.
These algorithms employ a fixed probability distribution for client selection and a fixed fraction $\gamma$ throughout training.
In this subsection, we report how our proposed \texttt{AdaFL} can be incorporated to further improve these algorithms.
Table \ref{table:compare_acc} shows that the incorporation of \texttt{AdaFL} improves both model accuracy and performance stability, while Table \ref{table:compare_rnds} shows that the incorporation of \texttt{AdaFL} reduces the required number of communication rounds and total communication cost to reach target accuracy.

\begin{table}[htb]

    \centering
    \begin{tabular}{>{\small}ccccc}

    \toprule

    \multirow{2}{*}{\bf{Algorithm}}
    & \multicolumn{2}{c}{\bf{MNIST}} & \multicolumn{2}{c}{\bf{CIFAR-10}} \\
    \cmidrule(){2-3} \cmidrule(){4-5}

                  & Average   & Best       & Average   & Best        \\ \midrule
    \addlinespace[0.04cm]

    \texttt{AdaFL+FedProx}   & {\bf91.67}   &  {\bf92.42}    &   {\bf74.94}       &  {\bf76.24}          \\
    \addlinespace[0.04cm]

    \texttt{FedProx-0.1}   &   89.15      &    91.46       &  72.88       &  75.90           \\
    \addlinespace[0.04cm]

    \texttt{FedProx-0.5}   &   90.81     &     91.55      &   73.57       &  76.12           \\
    \addlinespace[0.04cm]
    \hline
    \addlinespace[0.04cm]
    \texttt{AdaFL+FedMix}   & {\bf90.52}    & {\bf91.30}  &{\bf73.27}    &   {\bf75.05}          \\
    \addlinespace[0.04cm]

    \texttt{FedMix-0.1}   & 88.37      &  90.61       &  71.53        &   73.43          \\
    \addlinespace[0.04cm]

    \texttt{FedMix-0.5}   &  89.91     &  91.08        & 72.42         &  74.12           \\

    \addlinespace[0.04cm]
    \hline
    \addlinespace[0.04cm]
    \texttt{AdaFL+SCAFFOLD}   & {\bf90.30}   & {\bf91.52}        & {\bf74.98}       &    {\bf75.53}         \\
    \addlinespace[0.04cm]

    \texttt{SCAFFOLD-0.1}   &  87.82      &  89.96      &  71.62      &     74.12        \\
    \addlinespace[0.04cm]

    \texttt{SCAFFOLD-0.5}   &   89.73      &  90.82     &  73.50      &   74.77       \\

    \addlinespace[0.01cm]

    \bottomrule
    \end{tabular}
    \caption{A comparison of the average and best test accuracy performance for various FL algorithms (averaged over $3$ trials). \texttt{AdaFL+FedProx} stands for \texttt{AdaFL} incorporated into \texttt{FedProx}, while \texttt{FedProx-0.1/0.5} refers to the usual \texttt{FedProx} with constant fraction $0.1$ or $0.5$. The other algorithms reported in this table are defined analogously. We use the same performance metrics as used in Table \ref{table:ablation}. In particular, average test accuracy (of the last $10$ communication rounds) is a measure of performance stability.}
    \label{table:compare_acc}
    \end{table}

\begin{table}[htb]

    \centering

    \begin{tabular}{>{\small}c>{\small}c>{\small}c}

    \toprule

     {\bf{Algorithm}}   & {\bf{MNIST}}     &{\bf{CIFAR-10}} \\\midrule

    \addlinespace[0.06cm]
                                & 91\%         &  73\%      \\
                            \cmidrule(){2-3}
    \addlinespace[0.01cm]

    \texttt{AdaFL+FedProx}   &{\bf 821\,(21600)} &721\,{\bf(16840)}                     \\
    \addlinespace[0.04cm]

    \texttt{FedProx-0.1}   &   2439\,(24390)  &   1762\,(17620)                     \\
    \addlinespace[0.04cm]

    \texttt{FedProx-0.5}   &   1084\,(54200)    &   {\bf658}\,(32900)                      \\
    \addlinespace[0.04cm]
    \hline
    \addlinespace[0.04cm]
                          & 90\%         &  72\%      \\
                            \cmidrule(){2-3}
    \addlinespace[0.01cm]
    \texttt{AdaFL+FedMix}   & {\bf  852\,(22600)}   &  {\bf  698\,(15920) }                   \\
    \addlinespace[0.04cm]

    \texttt{FedMix-0.1}   &    2275\,(22750)   &   1903\,(19030)                       \\
    \addlinespace[0.04cm]

    \texttt{FedMix-0.5}   &    1241\,(62050)   &   732\,(36600)                     \\

    \addlinespace[0.04cm]
    \hline
    \addlinespace[0.04cm]
                         & 89\%         &  72\%      \\
                            \cmidrule(){2-3}
    \addlinespace[0.01cm]
    \texttt{AdaFL+SCAFFOLD}   &  {\bf 794\,(19760) }        &  {\bf  672\,(15600)  }        \\
    \addlinespace[0.04cm]

    \texttt{SCAFFOLD-0.1}   &    2252\,(22520)  &     1981\,(19810)            \\
    \addlinespace[0.04cm]

    \texttt{SCAFFOLD-0.5}   &     1034\,(51700) &    725\,(36250)          \\
    \addlinespace[0.01cm]

    \bottomrule
    \end{tabular}
    \caption{A comparison of the required number of communication rounds (values preceding brackets) and total communication cost (values in brackets) to reach target test accuracy, for various algorithms (averaged over $3$ trials). Similar to the settings used in Table~\ref{table:rnd_ablation}, the target test accuracies are chosen based on the results of Table~\ref{table:compare_acc}. For a fair evaluation, the stopping criterion used is that the average accuracy of last $5$ rounds must exceed the target accuracy.}
    \label{table:compare_rnds}

    \end{table}

Overall, \texttt{AdaFL} complements the performance of the three state-of-the-art algorithms on both datasets (see boldfaced values in Tables \ref{table:compare_acc} and \ref{table:compare_rnds}), with respect to test accuracy and communication efficiency.
For test accuracy, the \texttt{AdaFL}-based experiments yield better performance, with improvements on both MNIST (increase of $2.52\%$, $2.15\%$, and $2.48\%$ respectively) and CIFAR-10 (increase of $2.06\%$, $1.74\%$, and $3.06\%$ respectively), for all three algorithms.
Also, observe that our \texttt{AdaFL} requires the least number of communication rounds in most of the experiments and has the lowest total communication cost to reach the specified target accuracy for all the experiments, giving a $0.7\%$ to $21.3\%$ reduction in total communication cost for small fractions, and more significantly, a $48.8\%$ to $63.6\%$ reduction for large fractions.

These results show conclusively that the incorporation of \texttt{AdaFL} into these state-of-the-art FL algorithms would enhance the performance of all three aspects:
model accuracy, performance stability, and communication efficiency.

\section{Conclusion}
\label{sec:conc}
In this paper, we propose an attention-based federated learning algorithm with dynamic fraction for client selection, which we call \texttt{AdaFL}.
It is a simple algorithm that can be easily incorporated into various state-of-the-art FL algorithms to obtain improvements on several aspects: model accuracy, performance stability, and communication efficiency.

Our detailed ablation study shows that the two components in \texttt{AdaFL} indeed contribute significantly towards the outperformance over the usual \texttt{FedAvg} algorithm, with respect to all three aspects.
When incorporated into existing state-of-the-art FL algorithms, \texttt{AdaFL} yields consistently better performance.
We foresee that \texttt{AdaFL} can easily be incorporated into subsequent FL algorithms, to enhance the performance, especially in non-IID data settings.

Our proposed \texttt{AdaFL} algorithm gives clients who have larger model divergence a higher chance to participate in training. Can \texttt{AdaFL} be used as a stepping stone to develop other methods to improve fairness in FL? We plan to further explore this issue.
We also plan to study the attention mechanism in \texttt{AdaFL}, in the context of imbalanced data.

\section*{Acknowledgments}
This research is supported by the National Research Foundation, Singapore under its AI Singapore Programme (AISG Award No: AISG-RP-2019-015).

\bibliographystyle{named}


text:
\section{Introduction}
Recently there has been considerable interest in quantum spin liquids,
which are magnetic systems without LRO at low temperature.  While in
general, the ground state of quantum spin systems lack true LRO in 1D, the
ground state of the 2D Heisenberg antiferromagnet exhibits Neel ordering
even for $S = 1/2$, albeit with an sublattice magnetization that is
considerably decreased from its classical value.  Since spin is quantized,
the spin value cannot be decreased beyond $1/2$, hence the model does not
have a spin liquid ground state.  On the other hand, when two planes of
antiferromagnetic spins are coupled together
\cite{Millis,Hida1,Hida2,Hida3,Dagotto,Sandvik1,Sandvik2,Yoshioka,Maekawa}, and
if the interplane
coupling is strong enough, the ground state is easily seen to be one of
valence bond solid of interplane singlets (IVBS).  Thus, there should be a
transition from the LRO Neel state to a spin liquid state as the interplane
coupling is increased.  It has been suggested that  the unusual magnetic
properties of YBCO, with its basic unit of a pair of coupled CuO planes,
may be due to its lying close to this quantum transition \cite{Millis}.

It is of interest to study the nature of this quantum transition.  Within a
non-linear sigma-model (NLSM) description, Haldane \cite{Haldane} has pointed
out that for
a single plane of spins, topological Berry phase terms exist which differ
between half-integer, odd integer, and even integer spins. One way to
understand this is to consider the degeneracy of the valence bond solid
states which maximize the number of resonating plaquettes in each case
(4-fold, 2-fold, and non-degenerate respectively). On the other hand, the
mapping of the two-plane system to the NLSM does not yield a topological
term, which is consistent with the valence bond solid state for two planes
with large interplane vs. intraplane coupling being zero-dimensional like
and non-degenerate.  Since the 2+1 D NLSM has only one phase transition
which is second order, this suggests the same for the 2D quantum Heisenberg
antiferromagnet at T = 0.  However, the NLSM mapping assumes slow variation
on the scale of lattice spacing, and so additional disordered phases and/or
first order transition cannot be ruled out conclusively.

In this paper we investigate the ground state of the 2D bilayered Heisenberg
AF for general $S$ using the Schwinger boson mean field theory
\cite{Arovas,Sarker} with no
additional approximation . Our calculation complements previous
calculations for $S = 1/2$ only and/or using additional approximations, as
well as a calculation using the related Takahasi bosons approach
\cite{Hida1,Hida2,Hida3}.  Our
results show that a first order transition is favored by decreasing quantum
fluctuations, i.e.. increasing $S$.  In particular, in agreement with those
previous works, the transition for $S = 1/2$ is first order.  The critical
$S$ separating first from second order transition equals $0.35$.  While
increasing interplane coupling $J_ {\perp}$ eventually destroys LRO,
ordering is stabilized by small $J_ {\perp}$, and the critical $S$ for no
LRO is shifted from the single plane value of  $0.2$ to $0.13$.  A simple
argument using spin wave theory helps to explain why first order transition
occurs for large $S$.  Since quantum fluctuations increases both with
decreasing $S$ and decreasing $d$, we also study the dimensionality
dependence of the "bilayer" hypercubic system.  For $S = 1/2$, we find that
for $d < 1.86$ , the first order transition is replaced by second order one.
En route, we also calculate the $S$ vs. $d$ phase diagram for $J_ {\perp} =
0$, i.e. the hypercubic Heisenberg AF.  In addition to contradicting the NLSM
description by having the possibility of a first order phase transition,
whenever the transtion is continuous, the Schwinger boson MFT gives an
additional phase transition between two disordered phases for all $S$,
corresponding to a jump in the ratio of short-ranged intraplane to
interplane correlations.  However, since the Schwinger boson order
parameter is not related directly to any physical symmetry breaking, it is
likely this does not constitute a real phase transition but a sharp
cross-over in behavior.

\section{Bilayered Antiferromagnet in 2D}

We begin with a quick review of Schwinger boson mean field theory \cite{Sarker}
as
applied to the translationally invariant nearest neighbor Heisenberg
antiferromagnet on a
bipartite lattice. The Hamiltonian is

\begin{eqnarray}
H=\sum_{\langle ij \rangle} J_{ij}{\bf{S}}_i\cdot{\bf{S}}_j; ~~~~~
J_{ij}>0,~~ \langle
ij \rangle =n.n.
\nonumber
\end{eqnarray}
In the Schwinger boson representation, spin operators in each lattice site
are replaced by spin 1/2 bosons as follows:

\begin{eqnarray}
S^{\dag}_{i} &=& b_{i\uparrow}^{\dag} b_{i\downarrow},~~~~ S^{-}_{i} =
b_{i\downarrow}^{\dag} b_{i\uparrow} \nonumber\\
S^{z}_{i} &=& \frac{1}{2}( b_{i\uparrow}^{\dag} b_{i\uparrow} -
b_{i\downarrow}^{\dag} b_{i\downarrow}), \nonumber
\end{eqnarray}
The number of bosons at each lattice site is subject to the constraint:

\begin{eqnarray}
\sum_{\sigma}b^{\dag}_{i\sigma}b_{i\sigma} = 2 S, \nonumber
\end{eqnarray}
which can be implemented by introducing a Lagrange multiplier on each site.
The Hamiltoninan can now be written as

\begin{eqnarray}
H = -2 \sum_{\langle ij \rangle} J_{ij}\tilde{A}^{\dag}_{ij} \tilde{A}_{ij}
+ \frac{1}{2} NzJS^{2} + \sum_{i}
\lambda_i(\tilde{b}^{\dag}_{i\sigma}\tilde{b}_{i\sigma} -
2S), \nonumber
\end{eqnarray}
where $\tilde{A}^{\dag}_{ij}=\frac{1}{2}\sum_{\sigma}
\tilde{b}^{\dag}_{i\sigma}
\tilde{b}^{\dag}_{j\sigma}$ and
$\tilde{b}_{i\uparrow}=b_{i\downarrow},~\tilde{b}_{i\downarrow}
=-b_{i\uparrow}$ for sites on one sublattice and  $\tilde{b}_{i\sigma} =
b_{i\sigma}$
for sites on the other sublattice.  Physically, the product
$\tilde{A}^{\dag}_{ij} \tilde{A}_{ij}$ acts as the valence bond (singlet)
number operator for sites (i,j).  In the mean field approximation, this
product is decoupled by the Hartree-Fock decomposition.  In addition, the
exact local constraint is relaxed to one  for the average:

\begin{eqnarray}
\langle\sum_{\sigma}b^{\dag}_{i\sigma}b_{i\sigma}\rangle = 2 S \nonumber,
\end{eqnarray}
leading to the mean field Hamiltonian

\begin{eqnarray}
H_{MF} =
E_{0}+\lambda\sum_{i\sigma}\tilde{b}^{\dag}_{i\sigma}\tilde{b}_{i\sigma}
- 2\sum_{\langle ij \rangle} J_{ij} A_{ij}
(\tilde{A}^{\dag}_{ij}+\tilde{A}_{ij}),
\nonumber
\end{eqnarray}
where we have taken  $A_{ij}=\langle \tilde{A}_{ij}\rangle$ to be real.

First consider the case that all the  bonds are identical by symmetry, and
assuming no spontaneous dimerization, then all $A_{ij}$ must be the same
$A_{ij}=A$, .  In this case $E_{0}=\frac{1}{2}NzJS^{2} - 2\lambda NS +
JA^{2}Nz$, where $z$ is the coordiantion number.  $H_{MF}$ can be
diagonalized by going to momentum space and perfroming the Bogoliubov
transformation:

\begin{eqnarray}
H_{MF}=E_{0}-\lambda N
+\sum_{\bf{k}}\omega_{\bf{k}}(\alpha^{\dag}_{\bf{k}}\alpha_{\bf{k}} +
\beta^{\dag}_{\bf{k}}\beta_{\bf{k}} + 1), \nonumber
\end{eqnarray}
where $\omega_{\bf{k}} = [\lambda^{2} -
(J\tilde{A}z\gamma_{\bf{k}})^{2}]^{\frac{1}{2}}$, $\gamma_{\bf{k}} =
\frac{1}{z} \sum_ \delta e^{i\bf{k} \cdot \delta} = \sum_{i=1}^{d} \cos
k_{i}/d$. At $T=0$, the energy should be minimized with respect to
$\lambda$ and $A$, yielding the set of self-consistent equations:

\begin{eqnarray}
S + \frac{1}{2} &=& \frac{1}{2N}\sum_{\bf{k}}\frac{\mu} {(\mu^{2}-
\gamma_{\bf{k}}^{2})^{\frac{1}{2}}}, \nonumber\\
\tilde{A} &=& \frac{1}{2N}\sum_{\bf{k}}\frac{\gamma^{2}_{\bf{k}}} {(\mu^{2}-
\gamma_{\bf{k}}^{2})^{\frac{1}{2}}}, \nonumber
\end{eqnarray}
where we define $\mu\equiv\lambda/(J\tilde{A}z)$.  An essential point of the
theory is that a non-zero mean field amplitude $A$, which gives rise to
boson hopping, indicates short-ranged antiferromagnetic order.  Long-ranged
order is achieved if the hopping amplitude is sufficiently large to give
Bose condensation.  This occurs when these eqs. cannot be satisfied by
having $\mu>1$, in which case $\mu=1$, and the $k=0$ term gives a finite
contribution when converting the momentum sums into integrals:

\begin{eqnarray}
S+\frac{1}{2} &=& m_{s} + \frac{1}{2} \int^{\pi}_{-\pi} \frac{d^{d}{\bf{k}}}
{(2\pi)^{d}} \frac{1} {(1-\gamma_{\bf{k}}^{2})^{\frac{1}{2}}}, \nonumber\\
A &=& m_{s}+\frac{1}{2} \int^{\pi}_{-\pi} \frac{d^{d}{\bf{k}}} {(2\pi)^{d}}
\frac{\gamma_{\bf{k}}^{2}} {(1-\gamma_{\bf{k}}^{2})^{\frac{1}{2}}}, \label{ms2}
\end{eqnarray}

It has been shown that the condensate density $m_{s}$ is also the
sublattice magnetization. For the Heisenberg antiferromagnet on a square
lattice, it was found that Bose condensation occurs for all $S>S_{c}$,
where $S_{c}=0.2$, with a gapless linear excitation spectrum characteristic
of spin waves.  For $S<S_{c}$, $\mu>1$, and there is an energy gap for
excitations.  Thus, for all physical values of $S$, there is
AFLRO.

On the other hand, if two such planes are coupled together
antiferromagnetically, and the interplane coupling is very large compared
to intraplane coupling, the ground state is obviously a valence bond solid
of interplane singlets, and the intraplane correlation length is zero.
Thus, there must be at least one phase transition as the interplane
coupling is increased.  We now analyze this for general $S$ using Schwinger
boson MFT.

The Hamiltonian in this case is

\begin{eqnarray}
H=J\sum_{\langle ij \rangle} {\bf{S}}_{i} {\bf{S}}_{j} +
J_{\perp}\sum_{\langle ij
\rangle_{z}} {\bf{S}}_{i} {\bf{S}}_{j}, \nonumber
\end{eqnarray}
where $\sum_{\langle ij \rangle}$ sums over n.n. on the same plane and
$\sum_{\langle ij \rangle _{z}}$ sums over n.n. on different planes.
Since there is still translational invariance, the mean field Lagrange
multiplier will be the same on all sites.  However, the lack of symmetry
between intraplane and interplane bonds means two mean field ampitudes must
be introduced for the bond decoupling.  Letting these be $A$ and $B$
respectively, and taking them to be both real, the mean field Hamiltonian
is now

\begin{eqnarray}
H_{MF} = &&E_{0} + \lambda\sum_{i\sigma} (\tilde{b}^{\dag}_{i\sigma}
\tilde{b}_{i\sigma}) - 2JA\sum_{\langle ij \rangle}
(\tilde{A}^{\dag}_{ij}+\tilde{A}_{ij})
\nonumber\\
&-& 2J_{\perp}B\sum_{\langle ij \rangle _{z}}
(\tilde{A}^{\dag}_{ij}+\tilde{A}_{ij})\nonumber,
\end{eqnarray}
where $E_{0} = 2NJS^{2}-2\lambda NS + 4JA^{2}N + NJ_{\perp}S^{2}/2 +
J_{\perp}B^{2}N$.  As before, we diagonalize $H_{MF}$ through the
Bogoliubov transformation, giving

\begin{eqnarray}
H_{MF}=E_{0}-\lambda N
+\sum_{\bf{k}\sigma}\omega_{\bf{k}\sigma}(\alpha^{\dag}_{\bf{k}\sigma}\alpha
_{\bf{k}\sigma} + \beta^{\dag}_{\bf{k}\sigma}\beta_{\bf{k}\sigma} + 1),
\nonumber
\end{eqnarray}
The excitation energies are given by

\begin{eqnarray}
\omega_{{\bf{k}},\sigma} = [\lambda^{2} - (2JA\sum_{i=1}^{d} \cos k_{i} +
J_{\perp}B\sigma)^{2}] ^{\frac{1}{2}}. \nonumber
\end{eqnarray}
where $\sigma= \pm 1$.  Minimizing $H_{MF}$ with respect to $\lambda$, $A$, and
$B$ gives the self-consistent equations:

\begin{eqnarray}
S+\frac{1}{2} &=& \frac{1}{2N} \sum_{\bf{k},\alpha} \frac{\mu} {(\mu^{2} -
\Gamma_{\bf{k},\alpha}^{2})^{\frac{1}{2}}} \nonumber\\
A &=& \frac{1}{2N} \sum_{\bf{k},\alpha} \frac{\Gamma_{\bf{k},\alpha}}
{(\mu^{2} - \Gamma_{\bf{k},\alpha}^{2})^{\frac{1}{2}}}
(\frac{\sum_{i=1}^{d} \cos k_{i}} {d})\nonumber\\
B &=& \frac{1}{2N} \sum_{\bf{k},\alpha} \frac{\Gamma_{\bf{k},\alpha}
\alpha} {(\mu^{2} - \Gamma_{\bf{k},\alpha}^{2})^{\frac{1}{2}}},
\label{consist1}
\end{eqnarray}
where $\Gamma_{\bf{k},\alpha} = (\sum_{i=1}^{d} \cos k_{i} + Q \alpha)/d$ and
$Q=J_{\perp}B/(2JA)$.  Note that $\mu$, the excitation gap,
must be greater than or equal $1+Q/d$. In particular, in the case of bose
condensation, the value of $\mu$ is fixed to $1+Q/d$ and hence the
summations in Eq. (\ref{consist1}) turn out to be a function of the
parameter $Q$ only.  The magnetization $m_{s}$ is calculated by solving the
self-consistent equations with the summations converted into intergrals:

\begin{eqnarray}
S+\frac{1}{2} &=& m_{s} + \frac{1}{4} \int \frac{d^{d} {\bf{k}}} {(2\pi)^{d}}
\sum_{\alpha} \frac{\mu_{0}} {(\mu_{0}^{2} -
\Gamma_{\bf{k},\alpha}^{2})^{\frac{1}{2}}} \nonumber\\
\tilde{A} &=& m_{s}+\frac{1}{4} \int \frac{d^{d} {\bf{k}}} {(2\pi)^{d}}
\sum_{\alpha} \frac{\Gamma_{\bf{k},\alpha}} {(\mu_{0}^{2} -
\Gamma_{\bf{k},\alpha}^{2})^{\frac{1}{2}}} (\frac{\sum_{i=1}^{d} \cos
k_{i}} {d} )\nonumber\\
\tilde{B} &=& m_{s}+\frac{1}{4} \int \frac{d^{d} {\bf{k}}} {(2\pi)^{d}}
\sum_{\alpha} \frac{\Gamma_{\bf{k},\alpha} \alpha} {(\mu_{0}^{2} -
\Gamma_{\bf{k},\alpha}^{2})^{\frac{1}{2}}}, \label{consist2}
\end{eqnarray}
where $\mu_{0} = 1+Q/d$.  These equations \cite{Millis} hold so long as they
give
$m_{s}>0$, ie., Bose condensation, otherwise Eqs. (\ref{consist2}) should
be used with $\mu$ also as an unknown parameter.  In principle, we can
solve for $Q$ and $m_{s}$ or $\mu$.  In practice, the form of these
equations allow us to avoid this by plugging in an arbitrary values of $Q$
into the equations to find out $m_{s}$ or $\mu$, and then $A$ and $B$.  The
self-consistency is then reduced to using the values of  $A$, $B$, and $Q$
to determine the
value of $\beta \equiv J_{\perp}/J$.

The behavior of $Q$ as a function of $\beta$ for $S=1/2$ is shown in Fig.
\ref{qvsj}, and is representative of all $S$.  Discounting the trivial
solutions
$Q=0$ and $Q=\infty$, corresponding to independent planes and IVBS
respectively, there are $Q\neq 0$ solutions indicating both intraplane and
interplane correlations.  For small  $\beta$, there is only one solution,
with Q increasing from $0$ with $\beta$.  For $\beta > 4(S+1/2)^{2}$, a
second branch of solution, beginning at infinity appears.  The two
solutions merge at some larger value of $\beta$, and beyond that, only the
trivial solutions remain.  The significance of these solutions can be
understood if we consider the energy $E(Q)$ obtained by minimizing the
energy with respect to all other parameters except $Q$.  Then, the
non-trivial solutions are extrema of $E(Q)$.  Thus, for $\beta <
\beta_{0}=4(S+1/2)^{2}$, the solution of $Q$ corresponds to a global
minimum in $E(Q)$, and describes the ground state.  For $\beta >
\beta_{0}$, the upper branch corresponds to a local maximum while the lower
branch remains a local minimum.  The local maximum begins at $Q=\infty$ at
$\beta_{0}$, and moves towards the local minimum with increasing $\beta$.
Eventually, the two extrema merge into a saddle point at $\beta_{2}$.
Beyond that, $E(Q)$ is  strictly decreasing with $Q$.  By continuity, this
means somewhere between $\beta_{0}$ and $\beta_{2}$, $E(\infty)$ must cross
from being greater than $E(Q_{1})$ to less than it, where $Q_{1}$ is the
lower branch solution. Thus, at this value $\beta_{1}$, the ground state
jumps from the 2D correlated state described by $Q_{1}$ to the interplane
VBS state.

We can solve for the value of $m_{s}$ at the non-trivial solutions.
Initially, $m_{s}$ increases with increasing $Q$, but eventually will
decrease, vanishing at some $Q_{c}$. For sufficiently large $S$, $Q_{c}$
will belong to the upper branch (maximum energy) solution.  More
importantly,  in the case where $Q_{c}$ lies in the lower branch, its
$\beta$ value changes from less than to greater than $\beta_{1}$ with
increasing $S$. Thus, the transition from the LRO'ed state to disordered
state is second order for small $S$, but becomes first order for larger
$S$.  In the former case, there is a subsequent transition from a
disordered state with finite $Q$, hence with both interplane and intraplane
short-ranged correlations, to the $Q=\infty$ state with only interplane
correlations. Along with the jump in $Q$ is a discontinous jump in the gap.
It is tempting to associate this jump as a transition from some disordered
state associate with a single plane to the non-degenerate IVBS. More likely
this transition is probably an artifact of the Schwinger boson MFT, and
indicates a relative sharp drop in the intraplane correlation length and a
sharp rise in the gap. This is similar to the finite temperature MFT solution
for a single plane, where $A$, hence short-ranged correlation, drops to zero
above some finite temperatures \cite{Sarker}. In the latter case of first order
transition in
sublattice magnetization, the ground state jumps from one with LRO to the
IVBS state.  Since this latter state should be the correct ground state
only in the $\beta$ goes to infinity limit, we interpret this as the MFT
way  of showing a transition into a disordered state with a very short
intraplane correlation length.  The behavior of $m_{s}$ and the gap
$\Delta$ as a function of $\beta$ is shown in Fig. \ref{fig2} for
representative
values of $S$.  Fig. 2c shows an example of reentrance, where LRO first
develops with increasing $\beta$, but is subsequently destroyed when
$\beta$ gets too large.  This occurs for $S$ smaller than approximately
0.2, the MFT value of $S$ below which the ground state has no LRO, but
greater than approximately 0.13, the minimum value of $S$ for LRO at some
$\beta$.

The phase diagram of $S$ vs. $\beta$ is shown in Fig. \ref{phase}.  For $S <
0.13$,
the ground state is always disordered.  For $0.13<S<0.2$, the system
undergoes first a disorder-order and then a order-disorder continuous
transition with increasing $\beta$.  For $S>0.2$, there is LRO for $\beta =
0$, and only the order-disorder transition remains.  This transition is
continuous until it terminates at a tricritical point at $S \approx 0.35,
\beta \approx 2.92$, beyond which the continuous transition is preempted by a
first order transition.  Thus, for $S>0.35$, there are values of $\beta$ where
the LRO'ed state is not the ground state, but is nevertheless metastable.
The continuous transition phase boundary remains metastable until $S \approx
0.4$, beyond which the $m_{s}=0_{+}$ state moves into the upper branch and
becomes unstable.  In all cases of $S$ where a disordered ground state with
finite $Q$ exists, a subsequent "first-order transition" occurs, with a
discontinuous jump in $Q$ and the gap $\Delta$. As mentioned above, we
interpret the jump as unphysical, and represents in reality a relatively
sharp drop in the 2D correlation length.

We can understand why large $S$ favors a first order transition quite
simply in terms of spin wave theory \cite{Hida1,Hida2}.  The Neel state energy
is $E_{N} =
S^{2}(2Jz+J_{\perp})$ while the energy of the IVBS state is
$E_{V}=J_{\perp}S(S+1)$.  Equating the two implies an estimate for the
first order transition at $\beta_{1}$ of the order of $S$ for large $S$.
Within spin wave theory, the sublattice magnetization is given by $m_{s}$
in Eq. (\ref{consist2}) with $B/A=1$.  For large $\beta$, the integral on
the LHS scales as $\sqrt{\beta}$.  If we set $m_{s}=0$ as an estimate for
the critical value $\beta_{c}$ for continuous transition, then $\beta_{c}$
is of order $S^{2}$.  Thus, for large $S$, $\beta_{1}$ is much less than
$\beta_{c}$.

Within MFT, the tricritical point and even the metastable continuous
transition boundary occurs below the minimum physical value of $S=1/2$.
Thus, a first order transition is predicted for all physical systems
described by the model.
In fact, the sublattice magnetization jump at transition for $S=1/2$ is
about 30\% of that at $\beta=0$, clearly contradicting the results of
numerical work on the model for $S=1/2$, which supports a continuous
transition in the same universality class as the finite temperature
transition of the $3D$ classical Heisenberg model.  On the other hand,
there is no reason to expect the Schwinger boson MFT to give the exact
answer, so the true position of the tricritical point might very well be
above $S=1/2$.  This is particularly so since by relaxing the local
constraint to a global one, unphysical states are included in the mean
field solution, and the MF energy is not even variational.  Thus, using
these MF energies to find the position of first order transition is
necessarily suspect.  Nevertheless, we believe the prediction of larger $S$
favoring a first order transition to be correct, and the nature of phase
transition in the bilayer system is non-universal.  For example, the
transition for $S=1/2$ may become first order if there is a sufficiently
large next nearest neighbor ferromagnetic interaction.  Conversely, first
order transition may become continuous if frustration is introduced.  In
other words, the value of $S$ at the tricritical point can be changed by
enlarging the parameter space.  The seeming contradiction to the fact that
the 2+1 $D$ NLSM has only continuous transition is resolved by noting that
the mapping of the Heisenberg model into the NLSM is legitimate only if the
correlation length is long, which does not have to be the case of the
disordered state close to a first order transition.  Also of interest is
that with sufficient frustration, the single-layered system can be
disordered for $S=1/2$ or other physical values, and the reentrance
behavior for small $S$ discussed above in the bilayered system can be
physically observed.

Within our MFT and according to general arguments, first order transition
implies the existence of metastable states with finite sublattice
magnetization.  This may lead to observeable dynamics characteristic of
macroscopic quantum tunneling.  It would also be of significance with
respect to Monte Carlo type numerical calculations
\cite{Hida3,Dagotto,Sandvik1,Sandvik2} due to problems of being
"stuck" in the metastable minimum.  For example, the first order transition
may be missed if the metastability persists till the would-be continuous
transition.

\section{Extension to the Fractional Dimensions}

We have seen that  for the 2D bilayered square lattice  antiferromagnet,
Schwinger boson MFT shows the physically interesting case of $S=1/2$  as
undergoing  a first order transition.  Since the continuous transition is
favored by small $S$, hence increasing quantum fluctuations, one way of
getting  a continuous  transition in MFT for $S=1/2$ is to go to a
dimension below $2$.  In this section, we show that indeed this is the
case. En route, we present the phase diagram of $S$ vs. $d$ (Fig.
\ref{critdim}) for a
single layer. These non-integer dimension results may be relevant to the
physics of the Heisenberg antiferromagnet on percolating clusters, which
have fractal dimensionality.

 We first perform the Schwinger boson MFT  for a single hypercubic lattice
in $d$ dimension (square lattice for $d=2$).  The self-consistent equations
(Eq. (\ref{ms2})) depend on $d$ only through the momentum sum, which must
be analytically continued to non-integer dimensions.  This can be done by
using the gaussian identity:

\begin{eqnarray}
\frac{1} {(1 \pm \gamma_{\bf{k}})^{\frac{1}{2}}} = 2 \sqrt{\frac{d}{\pi}}
\int^{\infty}_{0} dx ~e^{-x^{2}(d \pm \sum^{d}_{i=1} \cos k_{i})},
\label{gauss}
\end{eqnarray}
to rewrite Eq. (\ref{ms2}) as

\begin{eqnarray}
\frac{2d}{\pi} \int^{\infty}_{0} dxdy~ e^{-(x^{2}+y^{2})d} (\int^{\pi}_{-\pi}
\frac{dk}{2\pi} e^{-\cos k (x^{2}-y^{2})} ) ^{d}. \label{bessel}
\end{eqnarray}
In this form, the analytic continuation to arbitrary $d$ is obvious (see
Appendix).  In
Fig. \ref{msgap}, the result for $S=1/2$ is shown.  As $d$ is decreased below
$2$,
$m_{s}$ decreases and vanishes at some critical dimension $d_{c}=1.46$.
Below $d_{c}$, the excitation spectrum has a gap, which rises with
decreasing $d$.  These behaviors are representative for all $S$. However,
it is known that for the simple Heisenberg Hamiltonian, $1/2$ integer spin
chains and integer spin chains are intrinsically different in that the
former should be gapless,
which can be understood as due to the presence of a topological term the
appropriate NLSM.  Thus MFT must break down for $1/2$ integer spins even
qualitatively as $d$ gets sufficiently close to $1$,  and $\Delta$  must
decrease again.

Next we generalize our bilayer calculation to two coupled hypercubes in $d$
dimension. The analytic continuation of Eqs (\ref{consist2}) can again be done
using the gaussian identity (\ref{gauss}). As expected,  a continuous
transition can now be observed within MFT if $d$ is reduced sufficiently from
$2$. For $d <1.46$, the critical dimension for LRO for a single hypercube, the
reentrance
seen with increasing $\beta$ for $S<0.2$ is seen for $S=1/2$.  So far, we
have concentrated on lowering the dimension from $2$.  Of course, raising
it would have the opposite effect.  For example, for two $3D$ hypercubes,
the $S=1/2$ transition would be strongly first order within MFT, and so
even taking into account inaccuracy of MFT, strongly implies a first order
transition.

Finally we discuss the critical phenomena of the continuous transition of this
model. Analyzing Eqs. (2) and (3) close to the transition, we find the
staggered magnetization vanishes linearly, while the gap vanishes as $(\beta -
\beta_{c})^{s}$ with $s=1/(d-1)$ for $d<3$, and $s=1/2$ for $d>3$ (there are
logarithm corrections at $d=3$). These MF exponents are the same as those for
the finite temperature transition of a single hypercube with the substitution
$d\rightarrow d+1$, reflecting the quantum nature of the present transition.

\section{Appendix}

Notice that in Eq. (\ref{bessel}), the integral inside the bracket is a
modified Bessel function of the first kind $I_{0}(x^{2}-y^{2})$. Therefore the
first equation of Eq. (\ref{consist2}) can be written as:

\begin{eqnarray}
S+\frac{1}{2} = m_{s} + \frac{2d}{\pi} \int^{\infty}_{0} dxdy
(e^{-(x^{2}+y^{2})} I_{0}(x^{2}-y^{2}))^{d}. \nonumber
\end{eqnarray}
Take the transformation:

\begin{eqnarray}
u=x^{2}-y^{2}, ~~~~~~v=x^{2}+y^{2} \nonumber
\end{eqnarray}
with $v\geq |u|$, for the integration variable will give us:

\begin{eqnarray}
S+\frac{1}{2} &=& m_{s} + \frac{2d}{\pi} \int^{\infty}_{-\infty} du
(I_{0}(u))^{d} \int^{\infty}_{|u|} dv \frac{e^{-vd}}{\sqrt{v^{2}-u^{2}}}
\nonumber \\
&=& m_{s} \frac{2d}{\pi} \int^{\infty}_{0} du (I_{0}(u))^{d}
K_{0}(ud).\nonumber
\end{eqnarray}
It reduces the final formula into a single integral of $I_{0}$ and $K_{0}$,
modified Bessel function of the second kind. In this form, the integral indeed
converges much faster than the original form in Eq. (\ref{consist2}) and
consequently save much of the computation time. The same trick is also applied
to both interplane and intraplane mean field equations.

redpajama_set_name: RedPajamaArXiv