## 3 System Model Design
### Community Structure Contraction Strategy
The cohesion of nodes is an important index to measure whether the network structure can be recontracted, which is represented as:  
\[\varphi\left[G\right]=\frac{1}{S*D} \tag{8}\]  
\[D=\frac{\sum_{i\
eq j\in V}d_{ij}}{S\left(S-1\right)} \tag{9}\]  
When the structure shrinks, the cohesion of the network depends on the connectivity between nodes in the network and the number of nodes in the network. The connectivity between nodes can be measured by the average distances, that is, the average distances between all node pairs. By formula (5) and (6), the cohesion degree \(\varphi\left[G\right]\) can be expressed as:  
\[\varphi\left[G\right]=\frac{S-1}{\sum_{i\
eq j}D_{ij}} \tag{10}\]  
\(S\geq 2\), \(D_{ij}\) represent the distance between node \(V_{i}\) and \(V_{j}\). When there is only one node in the network, \(\varphi\left[G\right]=1\). \(G*V_{i}\) represents the graph obtained after the node is contracted. The criticality of nodes in the network can be calculated according to the cohesion. \[S_{B}\left(v_{i}\right)=S_{b}\left(v_{i}\right)/\left[\left(N-1\right)\left[N -2\right]/2\right] \tag{4}\]0  
Under the same conditions, the larger the connectivity of nodes is, the smaller the number of nodes and the greater the network cohesion. If there is a node in the key position, the shortest path between many nodes will pass through this node, and the average network distances will be greatly reduced after the network shrinks. By (7) and (8), formula (11) can be expressed as:  
\[S_{B}\left(v_{i}\right)=S_{b}\left(v_{i}\right)/\left[\left(N-1\right)\left[N -2\right]/2\right] \tag{4}\]1  
Now we calculate the criticality \(IM\left(v_{i}\right)\) of each node after contraction according to formula (11). If the criticality \(IM\left(v_{i}\right)\) of node \(V_{i}\) is bigger than the control parameter \(\varepsilon\), it shows that the network structure is more compact after structure contraction. At this point, we can use a new node \(V_{i}^{\prime}\) to replace the original node \(V_{i}\) and its associated nodes. In this part, we propose a strategy for the contraction of community structures. We first remove some of the inefficient nodes in the community structure through node attributes. Then, the network is further contracted according to the influence of nodes on network cohesion, and we can get several close-knit community structures, which can improve the efficiency of information transmission and data forwarding. The simplified pseudo-code for this part is as follows (See Algorithm 1):```
0: adjusted subgraph \(G_{n}\)
1: For each group do //delete inefficient node
2: For each node \(V_{i}\) do
3: Calculate the importance \(IM\left(v_{i}\right)\) of node \(V_{i}\)
4: If \(IM\left(v_{i}\right)<\tau\)
5: Delete node \(V_{i}\)
6: End If
7: End For
8: End for
9: For each node pair \(e=\left(v_{i},v_{j}\right)\) // structure-shorten
10: Calculate distance \(D_{ij}\)
11: Calculate initial network cohesion \(\varphi\left[G\right]\) and \(\varphi\left[G*V_{i}\right]\)
12: If the value of \(V_{i}^{\prime}\) is bigger than \(\varepsilon\) then
13: replace \(V_{i}\) and its neighbor with a new node \(V_{i}^{\prime}\)
14: End If
15: End For
```

**Algorithm 1** Community structure contraction algorithm

### Community-Based Data-Forwarding Algorithm

In the ESR algorithm, the data-forwarding process is divided into two phases. In the first stage, we will make several copies of the data we need to forward and send these copies to all the adjacent nodes. If an adjacent node is in the same community structure, the node propagates data to its own community structure, otherwise it will spread the data copies to all its adjacent nodes. In the second process, the information forwarding process ends when the target node receives the message and sends a receive-confirmation message. Our algorithm proposed in this paper is based on the structure of the community, and we propose a method to reduce the structure of a community. Then, we copy a certain number of messages.