# AODV-EOCW: An Energy-Optimized Combined Weighting AODV Protocol for Mobile Ad Hoc Networks
## 3 AODV-EOCW Protocol
### Subjective Weighting  
The purpose of using AHP in the study was to obtain the weights of the three metrics mentioned above. When dealing with decision-making problems in the process of engineering applications and social production, AHP treats a complex, multiobjective decision-making problem as a system and decomposes the goal into multiple goals or criteria, and then decomposes it into several levels of multiple indicators. AHP is a hierarchical weight decision-making analysis method based on network system theory and the multiobjective comprehensive evaluation method. This method requires less information, it is simple and practical, and it is widely used in operations research. One disadvantage of AHP is that although it can only be used to select one better solution from existing solutions, it does not provide a new and different solution. However, for routing path selection problems, at any specific time, the node always knows its neighbors, because the last hop node is known, and the route is always selected from the neighbors. This disadvantage has little impact on the routing selection. Before AHP can be adopted for routing path selection, it is first necessary to build a hierarchical structure model and divide it into the target layer, criterion layer, and solution layer, according to their relationships. The hierarchical structure is shown in Figure 2.  
Figure 1: Flowchart of the proposed protocol. Figure 2: Hierarchy structure of AHP adapted for route selection. The target layer in Figure 2 is used for decision-making and solving problems. In the proposed routing method, the target layer is designed to judge the quality of the communication links between nodes. The criteria layer contains the factors and criteria that need to be considered when judging the target layer, namely, the node congestion, hop count, and residual energy. The solution layer contains the alternatives for decision making, that is, the different communication links between each node and the previous hop. When determining the weights among the factors at different levels, the consistency matrix method [9] is adopted. The purpose of the consistency matrix is to avoid the difficulty associated with comparing all factors together. Through a pairwise comparison, the difficulty caused by the mutual comparison of multiple factors with different properties can be reduced as much as possible. Afterwards, metrics are evaluated according to their importance, and the evaluated values are used to construct a comparison matrix. Finally, the weight value of each element is determined. The form of the judgment matrix \(A\) is a square matrix, as shown in Equation (1):  
\[A= \begin{pmatrix}1&a_{12}&\cdots&a_{1m}\\ \frac{1}{a_{21}}&1&\cdots&a_{2m}\\ \vdots&\vdots&\ddots&\vdots\\ \frac{1}{a_{11}}&\frac{1}{a_{22}}&\cdots&1\\ \end{pmatrix}  \tag{1}\]  
where \(m\) is a factor in the standard layer. Since the criterion layer only uses three factors for judging the routing metric, the value of \(m\) is 3, and the elements in the matrix are usually determined subjectively. \(a_{ij}\) indicates the importance of the \(i\)-th element to the \(j\)-th element. In this study, the authors used the same method as that used by [PERSON] [33] to construct the judgment matrix. The values and definitions of each element in the matrix are shown in Table 1; the matrix is adapted from [PERSON] [33] too. After the consistency matrix has been constructed, the eigenvector and the corresponding eigenvalue \(\lambda_{max}\) (the largest eigenvalue of the matrix after normalization) can be obtained. Each element in this eigenvector is a weight of the parameters in each criterion layer. In addition, in order to prevent the degree of inconsistency caused by subjective experiences from exceeding the allowable range, the algorithm also uses the random consistency ratio \(CR\) to check the consistency to ensure that the degree of inconsistency is within the allowable range.