# Research on Secure Community Opportunity Network Based on Trust Model
## 4 Performance Evaluation
The Spray algorithm, employing a limited copy forwarding strategy, outperforms the Epdic and BubbleRap algorithms in transmission success rate. Meanwhile, the Direct algorithm, solely delivering messages to the destination node, exhibits a low and gradually increasing forwarding success rate over time. Figure 3 illustrates the average transmission delay observed with the Direct, Epdic, Spray, BubbleRap, and SCTM routing algorithms. Initially, the forwarding of data packets in the network is random, leading to varied delays. However, as time progresses, the average transmission delay gradually stabilizes. Notably, the Direct algorithm exhibits the highest transmission delay due to its inherent characteristic of exclusively routing data to the destination node. In contrast, algorithms such as Epdic and BubbleRap, characterized by flooding forwarding strategies, demonstrate relatively lower average delays in successfully transmitted data packets. Moreover, owing to community division, the BubbleRap algorithm outperforms the Epdic algorithm in terms of transmission delay. Nonetheless, with the increasing number of data packets circulating in the network, the forwarding delay of these algorithms gradually escalates. On the other hand, the Spray and SCTM algorithms employ copy forwarding limitations, resulting in consistently stable average transmission delays. Particularly, the SCTM algorithm leverages historical interaction records to establish trust-based communities, ensuring efficient selection of next-hop relay  
Figure 2: Deliveryratio and simulation time. nodes while considering node centrality. Consequently, the SCTM algorithm achieves the lowest average transmission delay, affirming the efficacy of community division in optimizing network performance. As depicted in Figure 4, the Direct algorithm exclusively routes data directly to the destination node, resulting in a routing overhead of 0. Conversely, the Spray algorithm's forwarding behavior is determined by the number of message copies held by each node. When a node holds only one message copy, it ceases forwarding before reaching the destination node. Meanwhile, the Epdic and BubbleRap algorithms consistently exhibit high routing overheads owing to their flooding forwarding strategies. In contrast, the SCTM algorithm employs a community-based approach to limit copy forwarding. Despite also restricting the number of message copies, the SCTM algorithm stands apart from the Spray algorithm by considering additional factors such as node community, centrality, remaining cache, and energy levels. Consequently, the SCTM algorithm selects more optimal relay nodes for message forwarding. Figure 4: Overhead and simulation time. Figure 3: Latency_avg and simulation time. In social opportunistic networks, the cache size of nodes significantly influences routing algorithm performance. Hence, this study conducts a comparative experimental analysis by adjusting node cache sizes to explore their impact. Figure 5 illustrates the relationship between transmission success rate and node cache for the Direct, Epdic, Spray, BubbleRap, and SCTM routing algorithms. As depicted, with an increase in node cache size, the forwarding success rate of SCTM, Epdic, and BubbleRap algorithms experiences a significant rise, while that of the Direct and Spray algorithms remains relatively unchanged. This divergence arises because the Direct and Spray algorithms do not generate redundant message copies during message forwarding. Instead, the Spray algorithm implements limited copy forwarding by attributing messages with representations, thereby minimizing the number of message copies transmitted across the network and alleviating caching pressure on nodes. Conversely, the Epdic and BubbleRap algorithms produce numerous message copies during transmission, leading to cache pressure and subsequent message loss, thus reducing transmission success rates. Increasing node cache size effectively mitigates this issue, improving the forwarding success rate of these algorithms.