# Intersection Routing Based on Fuzzy Multi-Factor Decision for VANETs
## 3 Intersection Routing Based on Fuzzy Multi-Factor Decision
### Vehicle Decision
#### 3.2.4 Candidate Vehicle Selection  
After the quantification of all three factors, the next step is to calculate the fuzzy performance scores of the potential candidate factors. We defined the set of candidate vehicles as \(\text{C}=\{C_{i}|i=1,\;2\ldots n\}\), the set of factors as \(\mathrm{F}=\{F|j=1,\,2,\,3\}\), and weights \(\mathrm{W}=\{\widetilde{w}_{j}|j=1\,,\,2,\,3\}\), \(\mathrm{X}=\{\widetilde{x}_{ij}|i=1,\,2\ldots n;j=1,\,2,\,3\}\), which means the \(j\)th fuzzy factor score of the \(i\)th candidate vehicle based on the factor evaluation of the candidate vehicle as shown above. The fuzzy weights of factors distance, neighbor quantity, and relative velocity are indicated by a TFN, \(\widetilde{w}_{j}=\{lv_{j},mw_{j},uw_{j}\}\). Here, \(lv_{j}\), \(mw_{j}\), and \(uw_{j}\) stand for the lower, middle, and upper values of the fuzzy weight of the \(j\)th factor, respectively.  
To depict the differences of the factor scores between vehicles, we import descriptor, the standard deviation of probability theory, and statistics to calculate the weight of these factors. A small variance means that the data points are close to the expected value and each other. Correspondingly, high variance means that the data points are dispersed from the expected value and from each other. In this paper, the standard deviation is used to measure the difference of the same factor between candidate vehicles.  
First, the expected value of scores of the \(j\)th factor was calculated using the following equation:  
\[\widetilde{\mathrm{r}_{j}}(\mathrm{x})=\frac{1}{n}*\sum_{i=1}^{n}\widetilde{ \mathrm{x}_{ij}} \tag{5}\]  
Then, the standard deviation of each factor was calculated as follows:  
\[\widetilde{\mathrm{D}_{j}}=\sqrt{\frac{1}{n}*\sum_{i=1}^{n}\left[\widetilde{ \mathrm{x}_{ij}}-\widetilde{\mathrm{r}_{j}}(\mathrm{x})\right]^{2}} \tag{6}\]  
Hence, the weight of each factor was calculated as shown below:  
\[\widetilde{\mathrm{w}_{j}}=\widetilde{\mathrm{D}_{j}}/\sum_{j=1}^{3}\widetilde {\mathrm{D}_{j}} \tag{7}\]  
According to the above formulas, the fuzzy performance score and fuzzy relative weight of each factor were obtained and the utility \(\widetilde{\mathrm{u}_{i}}(\mathrm{x})\) of the \(i\)th candidate vehicle can be calculated as follows:  
\[\widetilde{\mathrm{u}_{i}}(\mathrm{x})=\sum_{j=1}^{3}\widetilde{\mathrm{x}_{ ij}}\,*\,\widetilde{\mathrm{w}_{j}} \tag{8}\]  
The vehicle with the highest utility will be selected as the next hop:  
\[\mathrm{C}=\{\widetilde{\mathrm{u}_{i}}\}\mathrm{max}\widetilde{\mathrm{u}_{ i}}(\mathrm{x}),\mathrm{i}=1,2\ldots n\} \tag{9}\]  
The \(\widetilde{\mathrm{u}_{i}}\) is a fuzzy number. However, the non-fuzzy ranking method for fuzzy numbers must be employed to compare the various candidates. The procedure of de-fuzzification involves the location of the best non-fuzzy performance (BNP) value. Generally, several available methods include the mean of maximum, center-of-area (COA), and \(\alpha\)-cut method [24]. In this paper, we utilize the center of area (COA) method to determine the best non-fuzzy performance (BNP) [25] value of the candidates. The BNP value for the fuzzy number \(\widetilde{\mathrm{u}_{i}}(\mathrm{x})\) can be found using the following equation:  
\[\mathrm{BNP_{i}}=[(\mathrm{ur_{i}}-\mathrm{lr_{i}})+(\mathrm{mr_{i}}-\mathrm{ lr_{i}})]/3+\mathrm{lr_{i}}. \tag{10}\]  
According to the value of the derived BNP, the ranking of \(\widetilde{\mathrm{u}_{i}}(\mathrm{x})\) proceeds and the best candidate can be selected.