## 4 Model Formulation  
Our new double-row model can be formulated as follows:  
Objective functions:  
\[\min F_{1}=\sum_{i=1}^{N-1}\sum_{j=i+1}^{N}c_{ij}\cdot d_{ij} \tag{1}\]  
\[\max F_{2}=\sum_{i=1}^{N-1}\sum_{j=i+1}^{N}r_{ij}\cdot b_{ij} \tag{2}\]  
Subject to:  
\[de_{i}=min_{e}\{|x_{i}-x_{i}|+|y_{1i}wr_{1}+y_{2}(wr_{1}+wc)-y_{t}|\}\forall i \in N,\;\forall t\in E \tag{3}\]  
\[d_{ij}=B_{ij}\big{[}F_{ij}|x_{i}-x_{j}\big{|}+\big{(}1-F_{ij}\big{)}\big{(}|x_{ i}-x_{j}|+wc\big{)}\big{]}+\big{(}1-B_{ij}\big{)}\big{(}de_{i}+de_{j}\big{)}+H \big{|}f_{i}-f_{j}\big{|}\;\forall i,j\in N \tag{4}\]  
\[\sum_{k=1}^{f}A_{ik}=1\;\forall i\  
\[b_{ij}=\begin{cases}0&\frac{d_{ij}^{c}}{\frac{a_{ij}^{c}}{w_{k}^{c}+l_{k}^{c \alpha}}\geq 5}\geq 5\\ 0.2&5>\frac{d_{ij}^{c}}{w_{k}^{c}+l_{k}^{c\alpha}}\geq 4\\ 0.4&4>\frac{d_{ij}^{c}}{w_{k}^{c}+l_{k}^{c\alpha}}\geq 3\\ 0.6&3>\frac{d_{ij}^{c}}{w_{k}^{c}+l_{k}^{c\alpha}}\geq 2\\ 0.8&2>\frac{d_{ij}^{c}}{w_{k}^{c}+l_{k}^{c\alpha}}\geq 1\\ 1&1>\frac{d_{ij}^{c}}{w_{k}^{c}+l_{k}^{c\alpha}}>0\end{cases} \tag{20}\]  
In the above formulations, the two objective functions, Equations (1) and (2), are used to minimize the movement distance of patients and maximize the closeness rating score weighted by adjacency factor, respectively. The minimum distance between department \(i\) and all elevators is calculated by Equation (3). From Equation (4), the distance between two departments is determined by three factors: their coordinates, located floors, and located rows. When two departments are located on different floors, the distance between them is calculated by adding together three components: the minimum distance between department \(i\) and elevators, the minimum distance between department \(j\) and elevators, and the vertical distance which is calculated according to the height of each floor and the number of floors between departments. Equation (5) ensures each department can only be assigned to one floor using binary variable \(A_{ik}\). From Equation (6), the located floor of department \(i\) is determined. Equation (7) ensures \(B_{ij}\) is equal to 1 only if departments \(i\) and \(j\) are on the same floor. Equation (8) ensures each department is located either in the lower row (\(r=1\)) or the upper row (\(r=2\)). By Equation (9), only if departments \(i\) and \(j\) are located in the same row of one floor will \(F_{ij}\) be 1. The length of department \(i\) varies with the located row by Equations (10) and (11) is used to avoid any overlap between departments. Equations (12) and (13) ensure that all departments are located within the floor space. Equations (14) and (15) ensure no overlap between departments and the hall or the fixed facilities. The width of department \(i\) is calculated by Equation (16). In order to calculate the closeness rating score, the average width and length of departments in each floor are firstly calculated by Equations (17) and (18), and the rectilinear distance between departments \(i\) and \(j\) is determined by Equation (19) only if the two departments are on the same floor, otherwise the rectilinear distance is set to a very large value \(M\) which means the adjacency factor of the two department is zero in Equation (20). Then in Equation (20), the adjacency factor of each two departments is calculated based on the rectilinear distance between them and the average width/length of the departments on the floor.