# PECSA: Practical Edge Computing Service Architecture Applicable to Adaptive IoT-Based Applications
## 5 Performance Evaluation
### Comparative Analysis  
For trust evaluation, we consider the situation in which the malicious data device behaves abnormally and generates incorrect trust values to cause the user to make incorrect decisions. Figures 2 and 3 show the comprehensive trust evaluation results of a good node and a malicious node, randomly picked, respectively. \(pm\) denotes the proportion of malicious nodes. The convergence time is very small, about 50 s for both figures, where the update interval is set as 5 s. We see that trust convergence behavior is observed for both figures. The trust bias is acceptable since the trust value of the good node is between 0.7 and 0.8 and that of the malicious node is between 0.45 and 0.55. In a complex communication environment, good nodes and malicious nodes could be distinguished by their trust value. The service time for a requirement is determined by the amount of computation and transmission. Two tasks that transmit the same amount of information often require different calculation amounts. The product factor \(l\) is used to describe the relationship between the data volume and calculation amount of a task. Our proposed architecture can be applied to fields such as artificial intelligence, image recognition, coding, and so on. In these fields, various iterative algorithms are usually used to complete specific work. The iterative algorithm can be implemented by a for-loop statement. The calculation times of each cycle are the same, so the value of \(l\) can be determined by the number of iterations. For example, in [40], BP-decoding algorithms achieved good results in 20 iterations. If the amount of calculation per iteration is 50, then \(l\) is 1000. In [41], the RANSAC algorithm is used for image matching. The upper limit of the number of iterations is 400. Let us suppose that one iteration requires 250 operations; then, \(l\) is 100,000. If the number of iterations of the improved RANSAC algorithm is 40, then \(l\) is 10,000. In fact, the value of \(l\) depends on the number of iterations of a specific algorithm. To illustrate the efficiency of our proposed scheme, here we set \(l\) = 1000, 2000, 5000, 10,000, 50,000, and 100,000, respectively. In Figures 4-7, the data volumes of the task are set to 5 GB. Usually, the price is a critical factor for a user when purchasing cloud services. Four charging models are considered in our architecture: flat rate billing of the 4G network, flat rate billing of the 5G network, and billing by flow. \begin{table}
\begin{tabular}{c c} \hline \hline
**Parameter** & **Value** \\ \hline Data transmission rate of 5G, \(v_{i}\) & 1024 Mbps \\ Data transmission rate of 4G, \(v_{i}\) & 72 Mbps \\ Computing capability of nodes in \(GA\), \(cp_{i}\) & 0.08 ms/10,000 multiplications \\ Computing capability of nodes in \(GB\), \(cp_{i}\) & 0.12 ms/10,000 multiplications \\ Computing capability of nodes in \(GC\), \(cp_{i}\) & 0.15 ms/10,000 multiplications \\ Computing capability of nodes in \(GD\), \(cp_{i}\) & 0.20 ms/10,000 multiplications \\ Computing capability of nodes in \(GE\), \(cp_{i}\) & 0.25 ms/10,000 multiplications \\ Calculation price of nodes in \(GA\), \(pc_{i}\) & 0.06/10,000 multiplications \\ Calculation price of nodes in \(GB\) & 0.03/10,000 multiplications \\ Calculation price of nodes in \(GC\) & 0.012/10,000 multiplications \\ Calculation price of nodes in \(GD\) & 0.0054/10,000 multiplications \\ Security price, \(p_{s_{i}}\) & 0.08/1 MB \\ Computing energy consume in edge cloud, \(\rho\) & 90 W/Gigacycles \\ The total battery capacity, \(E_{i}^{max}\) & 1000 J \\ \hline \hline \end{tabular}
\end{table} 
Table 3: Experimental parameters. Figure 4 shows that the time cost of a task increases with the increase in the coefficient \(l\). The abscissa is not uniformly distributed; the delay at \(l=\) 10,000 is about twice the delay at \(l=\) 5000, and the delay at \(l=\) 50,000 is about five times the delay at \(l=\) 10,000. In general, cost and delay are approximately linear.