# Vertical Handover Algorithm for WBANs in Ubiquitous Healthcare with Quality of Service Guarantees
## 4 MADM Handover Algorithm
### Handover Decision-Making
#### 4.2.2 The Attribute Weight Calculations  
The methods for performing the weight calculations of the attributes are the main challenges in the MADM approaches. With an increasing heterogeneous complexity of the nature of the attributes, the attribute weight calculation is increasingly challenging, which in turn affects the handover execution. Furthermore, depending on each WBAN application, each attribute will have a different level of importance in meeting the requirements of the application. For example, some of the signals (e.g., heartbeat, BP, EEG) are strictly required for timely transmission, and thus, the QoS parameters (end-to-end delay and packet loss) are very critical in guaranteeing the transmission deadline. In contrast, there are some normal applications in which the cost is more important than any of the QoS parameters.  
Therefore, to determine attribute weights effectively for each of the application requirements, we calculated the weights of the attributes based on the Analytical Hierarchy Process (AHP) approach [31] and divided them into two weight vectors according to the WBAN traffic categories.  
The following are the main steps for the weight calculation of the \(m\) attributes.  
_Step 1_: Deriving the reciprocal matrix A with the perceived one-dimensional vector \(L_{m}\):  
\[\mathbf{A}=\mathbf{a}_{\text{qp}}=\left[\begin{array}{cc}1,&if\ L_{p}=L_{q }\\ L_{p}-L_{q}+1,&if\ L_{p}>L_{p}\\ \frac{1}{L_{p}-L_{q}+1},&if\ L_{p}<L_{q}\end{array}\right] \tag{7}\]  
where the attributes \(p\) and \(q\) are mapped to any one of the linguistic values \(\in\{1,3,5,7,9\}\) to denote the scale of importance, as shown in Table 3. The pairwise comparison \(a_{qp}\in\{1/9,1/7,1/5,1/3,1,3,5,\)[7; 9] depends on \(L_{m}\) as defined by the decision maker.  
_Step 2_: Computation of weights as follows:  
\[w_{j}=\frac{1}{m}\sum\limits_{p=1}^{m}\frac{a_{jp}}{\sum\limits_{q=1}^{m}a_{qp}} \tag{8}\]  
where \(j=1,\,2,\,3,\,\ldots,\,m\) with \(\sum\limits_{1}^{m}w_{j}=1\).  
_Step 3_: Verification of the weight.  
This step aims to check the consistency and reliability of the calculated attribute weights \(W_{j}\) in step 1 and is evaluated using the consistency ratio (CR), which is given by Equation (9).  
\[CR=\frac{\text{Consistency Index }(CI)}{\text{Random Consistency Index }(RI)} \tag{9}\]  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline  & **RSSI (dBm)** & **Delay (s)** & **Utilization (\%)** & **Packet Loss (\%)** \\ \hline Emergency Traffic & \(-50\) & \(10\) & \(100\) & \(3\) \\ Normal Traffic & \(-87\) & \(100\) & \(100\) & \(30\) \\ \hline \hline \end{tabular}
\end{table}
Table 2: The quality of service (QoS) parameter threshold of different application types.  
where  
\[CI=\frac{\lambda_{\max}-m}{m-1} \tag{10}\]  
\[\lambda_{\max}=\sum_{j=1}^{m}\left(\text{w}_{j}\times\sum_{p=1}^{m}a_{pj}\right) \tag{11}\]  
where \(RI\) is the index of the matrix coherence. The value of \(RI\) is 0.52, 0.89, 1.11, 1.25, 1.35, 1.40, 1.45, 1.49, 1.51, 1.54 and 1.56, with the different sizes of the matrices (or number of attributes) being 3, 4, 5,..., 12 and 13, respectively [32].  
According to the main steps of the Simplified and Improved Analytical Hierarchy Process (SI-AHP) approach above, we calculated two weight vectors for the WBAN traffic categories (\(W_{1}\), \(W_{2}\)) with the consistency ratios CR\({}_{1}\) = 0.02, CR\({}_{2}\) = 0.03, respectively. The values of the consistency ratios are very low and are fulfilled by the condition (CR \(\leq\) 0.1). Therefore, the calculated weight attributes \(W_{1}\), \(W_{2}\) are accepted, which ensures a high consistency and reliability of these values, as detailed in Table 4.