# Research on Wireless Sensor Network Access Control and Load Balancing in the Industrial Digital Twin Scenario

Authors: Wei Zhou
Journal: Journal of Sensors
 (2022)

---

## Abstract

Wireless sensor networks which are based on distributed information processing technology are taking an increasingly key role in industrial digital twin scenarios. There are many important issues in the access of networks. One of the most important issues is how to improve network access control and the effectiveness of load balancing. Based on the industrial digital twin technology, this article first introduces several typical network access and network loads and performs tree-structured processing on the outliers generated during the chain formation process to reduce the length of the data transmission path, optimize the main chain head and subchain chain head selection strategy and chaining rules, and perform nonchain operations on common nodes and chain heads near sink to reduce data inverse transfer. The experimental results show that this paper uses the digital twin calculation formula to accurately and objectively determine the remaining cluster head and the distance head and the base station, so that when the node distance is limited, the network energy consumption can be balanced as much as possible, and the network load is promoted.


---

## Body

## 1. Introduction

Wireless sensor networks integrate sensor technology, computing, and communication technology and become an active research branch in the field of computer science. In the wireless sensor network architecture, the digital twin technology at the network layer is crucial to the life cycle of the wireless sensor network [1]. The network load algorithm has become the digital twin technology that is currently the focus of research. The digital twin protocol is the core technology of the wireless sensor network layer. While discovering a path with a smaller delay, it avoids network congestion and balances network energy consumption. For different application environments, the digital twin protocol can be divided into network access protocol, network load protocol, and geographic digital twin protocol. When designing a digital twin protocol, an important challenge will be faced, that is, how to complete the sensing, communication, and control functions under the condition that the node’s energy resources, computing capabilities, storage space, and communication capabilities are highly restricted. For this reason, the main goals of the wireless sensor network digital twin protocol design are establishing an energy efficiency path, forming a reliable data forwarding mechanism, and maximizing the network life cycle [2–5].With the rapid rise of the Internet and the Internet of Things, as well as the rapid development of microelectromechanical systems (MEMS), distributed information processing, radio communications, multifunction sensors, embedded software, and hardware technologies have matured day by day, and wireless sensor networks have become a representative of emerging fields. When it was born, these software and hardware technologies have provided great help to promote the rapid development of WSN technology [6–8]. WSN uses a variety of highly integrated and low-cost micro wireless sensor nodes to collaborate to achieve real-time monitoring and perception in different application environments and collect relevant data or other object data of interest [6], and then, the embedded system performs preliminary processing on the monitoring data [7], and then, the network sends these data digital twins to the control center according to the defined transmission protocol. It divides a network with a large range and nodes into multiple smaller clusters according to specified rules, making the network hierarchy clearer and more scalable. Since most of the non-cluster-head nodes can close the communication module for a long time, for the traditional uniform network load protocol, due to the multihop transmission between clusters, the cluster head node near the base station takes on more forwarding tasks, which consumes more energy and causes the problem of uneven network energy consumption [9–11].Based on the study of multiple clustering and chained digital twin algorithms, this paper proposes a tree-shaped chained multihop digital twin algorithm (TUCM). The algorithm introduces angle control between candidate cluster heads to optimize the selection method of cluster heads, builds a tree-shaped chain structure to optimize the strategy, uses a hybrid hierarchical network topology structure, and improves the path selection probability model of the ant colony algorithm. And the pheromone update model realizes the mixed multihop data transmission to eliminate the shortcomings of the digital twin and other network load algorithms in the large-area measurement area environment of the cluster node to the sink node in the long-distance single-hop transmission. Aiming at the problem of random selection when selecting candidate cluster heads, this paper sets a threshold calculation formula for each node according to the remaining energy. By considering the remaining energy of the node in the selection of the threshold, the threshold generated by the node with less energy is smaller, so that it has a smaller probability to become a candidate cluster head node. The bottom layer constructs the network nodes into multiple subchains and selects the main chain head and the subchain heads to construct the top-level chain head chain. In order to improve the success rate of data transmission between clusters, this paper adopts Bayesian link estimation for each cluster head node after each round of cluster formation.


## 2. Related Work

Due to the huge application value of wireless sensor network technology, which has a profound impact on the development of the country and society, domestic and foreign scientific researchers have conducted in-depth research on it from different directions. Because of the special application environment of WSN, which is often unattended, the design of the digital twin protocol plays a vital role in whether the network can be used normally and how long it can be used. Because traditional networks do not have these new features, many different WSN digital twin algorithms have emerged. The following briefly describes the current research status of WSN at home and abroad [12].Regarding network topology control, the existing research results mainly have two ideas. One uses the positioning mechanism to accurately and effectively divide the network. However, the positioning mechanism is more expensive and generates greater internal friction; the other is to use level type topology (clustering algorithm) takes some nodes and then constructs a backbone network responsible for data processing and forwarding. The rest of the noncluster head nodes are mainly used to sense and collect nearby information. And in the cluster head election stage, the communication module is temporarily closed, and the sleep mode is entered to save energy. At present, some domestic and foreign scholars have conducted research on this aspect as follows: Zheng and Sivabalan [13] proposed a classic clustering protocol LEAcH. The protocol periodically performs two phases: cluster establishment and data communication. In the cluster establishment stage, the nodes in the network are randomly selected as cluster heads, and the nodes that are not selected as cluster heads choose to join the clusters that are closer to them. Leng et al. [14] believe that in the data communication stage, the member nodes in the cluster will transmit the collected information to the cluster head, and the data will be fused in the cluster head node. Compared with traditional network access protocols, this algorithm extends the network life cycle by about 15%. However, this algorithm selects cluster head nodes randomly, which can easily cause uneven distribution of cluster head nodes.The HEED protocol proposed in Li et al. [15] uses a different competition mechanism from the LEAcH protocol to select cluster head nodes. The HEPrint protocol fully considers the role of node residual energy in selecting cluster heads, so that the selected cluster heads can construct a more reasonable network topology. Lim et al. [16] believe that this protocol requires all nodes to communicate directly with the base station, which requires relatively high hardware requirements for sensor nodes. Both of the above two protocols use single-hop communication within the cluster to directly transmit the data collected by the member nodes to the cluster head node. This single-hop communication method within a cluster is simple and easy to expand. However, Barykin et al. [17] did not consider the cluster head. For member nodes far away from the cluster head, energy consumption may be too fast due to long-distance transmission. With the in-depth study of the digital twin protocol, another multihop communication method within the cluster has emerged. According to the effectiveness and timeliness of the regional coverage of WSN in the monitoring environment, scholars proposed a nonuniform clustered wireless sensor network digital twin algorithm based on energy efficiency improvement [18–21]. This algorithm first optimizes the cluster head election based on the node distribution density and then controls the competition radius of the clusters to achieve nonuniform clustering. Then, each cluster head calculates the distance coefficient and the dispersion coefficient to determine the internal communication mode of each cluster. It adopts single-hop and multihop transmission mechanism. The results show that improves the energy efficiency of network nodes, avoids the “hot spot” problem of WSN, delays the dead time of network nodes, and improves the effective coverage time of the monitoring area and the overall network life cycle [22–25].


## 3. Network Construction of Industrial Digital Twin Scene

### 3.1. Industrial Digital Network Cycle

In the structure of the industrial digital network, the SU is responsible for collecting the required data information in the area to be tested and then using corresponding means to send the data information to the corresponding relay station; the DPU is mainly composed of low-power embedded microcontrollers, capable of coordinate various operations of the management node, such as processing and saving the data collected by the sensor unit; TU is mainly composed of low-power communication, etc., managing the communication process between nodes, and at the same time exchanging related data information; currently, PU mainly adopts that alkaline batteries or lithium batteries are responsible for providing energy for the work of nodes, and the energy unit is related to the lifetime of the entire network.(1)∑Ii,j−∑δ¯i,j+δ¯maxi2+j2=0.Many small nodes are scattered in the environment to be tested, and nodes with specific functions form a wireless network. Finally, the monitoring center also real-time control and management of network nodes can be achieved through the received information.Since the functional characteristics of the sink node determine its stronger data processing, fusion and information transmission capabilities than ordinary nodes, it can not only realize the connection between WSN and the Internet and other external networks but also send the collected data information to the external network.(2)limx⟶∞δ¯max−δ¯min−limx⟶∞δ¯i,j+δ¯max=0.With the collection and transmission of data, network nodes gradually exhaust their own energy. Natural and human factors may also cause node failure or death, communication link quality, and wireless medium’s own factors will affect the normal operation of the entire network. These are several types of cause networks. At this time, if the network is paralyzed and the tasks delivered by the user cannot be completed normally, it means that the network does not have good robustness, and the design of the digital twin protocol must consider good robustness or robustness. In a specific environment, robustness is difficult to evaluate by a single value, and it is usually discussed in detail based on node and link models.


### 3.2. Distribution of Sensor Node System

A wireless sensor network system usually includes a sensor node, a base station node, and an application node. A large number of sensor nodes are arbitrarily scattered in the designated sensor field. Each node can collect the information of the sensing object in Figure1. After the query is sent for a period of time, the sink starts to receive the returned information from multiple paths. At this time, it selects the optimal path from it and sends a “path strengthening” message to the corresponding neighboring node. The “path enhancement” message is also a query command, which is different from the previous one in that it contains a larger information collection rate.Figure 1
Sensor node system distribution topology.The “path strengthening” message is transmitted hop by hop along the optimal path to the sensor node being queried. This path becomes the “main path,” and the other paths become the backup paths accordingly. After the sensor node receives the “path enhancement” message, it will collect the information according to the required rate in Table1.Table 1
Data forwarding in the sensor network.
Data numberSensor network 1Sensor network 2Sensor network 3116.7744.297.26216.8944.447.33317.4245.077.64418.1145.928.04518.7946.738.43619.3147.378.74719.6247.748.92The closer the node is to the base station, the smaller the node’s competition radius. Correspondingly, the cluster structure closer to the base station is smaller, which will reduce the energy consumption of data communication in the cluster, and can reserve more energy for the relay and forwarding services between clusters.In the network access protocol, each wireless sensor node in the network is homogeneous, that is, has the same state, and is randomly distributed at any location in the network. The disadvantage is that the cost of establishing and maintaining a digital twin is high, and the number of data transmission hops is large, which is not suitable for large-scale network applications.There is no hierarchy of nodes in the network access protocol. The node sends data directly to the sink node, or it can be forwarded to the sink node. The flooding digital twin protocol is that after each node receives the information, it forwards data packets to neighboring nodes in the form of broadcast.(3)fort,t−1∈Cr,t,Atα,β=FAt,t−1,Mi,t.Flooding the digital twin agreement is prone to implosion. The normal node first sends data to each neighboring node to receive the data and sends it to other nodes except itself. And so on, until the collected data information is transmitted to the sink node, or until the node information data expires. The biggest problem with this protocol is that it generates a large number of duplicate data packets and occupies a large amount of network resources, which makes the digital twin and link resources too wasteful, resulting in low efficiency.


### 3.3. Cluster before Digital Information Update

The GEAR digital twin mechanism establishes an optimized event area, avoiding flooding propagation, thereby reducing the cost of establishing the digital twin. The future situation prediction stage is based on the law of the development of the network load process to realize the trend prediction of the future operation state of the system. The future forecast results will be submitted to the operation dispatcher for decision-making and use, and the closed-loop control of the network load will be realized.(4)∬Atα,βdadb−∬At,t−1,Mi,tdtdt−1=0.In the GEAR digital twin, the wireless links between nodes are symmetrical. The query message propagation in the GEAR route includes two stages. This link is the core of the entire situational awareness process. It also runs through the entire situational awareness process.(5)βt=α1−λ2−λ1λ2+λ1,t≤0,α1−1,t>0.The chain head node will generate a token that can control the transmission of data along the direction of the chain head leader node. In each subsequent round, the node closest to the end of the chain will join the current chain and become the new end of the chain. When all sensor nodes have joined the chain, the final network node chain structure is formed.In the chain structure, when a node dies, the chain structure needs to be reconstructed to prevent the chain from breaking. In each round, the leader node at the head of the chain stays with the node, and the remaining nodes only collect and receive data and merge them, and forward the fused data along the chain to the next-hop neighbor nodes in Figure2.Figure 2
Cluster histogram before digital information update.The directed diffusion protocol is a query-based digital twin protocol and a data-centric digital twin protocol. The agreement is divided into three stages: interest diffusion, gradient establishment, and path strengthening. The sink node determines the best path according to the magnitude of the “gradient” value. This protocol is very energy-efficient, but it is to establish the best path and consumes energy during the digital twin.


### 3.4. Network Load Balancing Overlap

Because wireless sensor networks are different from traditional wireless networks, other wireless sensor network digital twin algorithms cannot be simply applied to wireless sensor networks. A suitable digital twin algorithm must be designed according to the characteristics of the wireless sensor network itself for network access algorithms and network load algorithms.(6)∏α1α1−1α2+α1En1+λ1∏α1α1−1α2+α1En1+λ1=1.When there is a corresponding request, the data information is sent to the destination. During data transmission or reception, each node in Figure3 first detects the energy status, and if it is in a low energy status, it stops some unimportant operations, such as stopping as a relay node. But the message sent by the publisher is asynchronous, there is no need to wait for the subscriber to subscribe, and it does not care whether the subscriber subscribes or not.Figure 3
Analysis of overlapping fitness of network load balancing.The real-time situation understanding stage is mainly to obtain network load data and information for integration and analysis and then conduct situation assessment and comprehensively evaluate the stability of network load through the establishment of various stability indicators and systems.The advantage of the SPIN protocol is that the use of a metadata negotiation mechanism eliminates the entire network and solves the problems of implosion and overlap.First of all, the protocol is established on a relatively abstract level to analyze and design sensor networks, without a more practical wireless network model. Secondly, the volatility of network nodes and links is not taken into consideration, and fault-tolerant technology is not supported. Finally, the resource adaptive technology proposed is relatively simple, not complete enough, and not suitable for actual wireless sensor network applications.(7)Gx,t,n∣x2−t2=0−α2+α1En1+λ1En1‐λ1α2−α1=0.For the digital twin protocol, the cluster heads are randomly selected in a probabilistic manner. Currently, various types of network load data information that can be collected mainly include network topology, real-time operation data, equipment component information, and network load.The entire network topology is constantly changing, and the lifespan is short; the entire network chain digital twin of the protocol causes 99% of the nodes to need to fuse data, the first node of the chain has a large load and high energy consumption, and the data transmission delay of the end node is high. A WSN collaborative network load design method based on hierarchical area division (CCRD-HRD) is proposed. Based on SCA-HRD, this method adds consideration to discrete clusters and designs collaborative digital twins.


## 3.1. Industrial Digital Network Cycle

In the structure of the industrial digital network, the SU is responsible for collecting the required data information in the area to be tested and then using corresponding means to send the data information to the corresponding relay station; the DPU is mainly composed of low-power embedded microcontrollers, capable of coordinate various operations of the management node, such as processing and saving the data collected by the sensor unit; TU is mainly composed of low-power communication, etc., managing the communication process between nodes, and at the same time exchanging related data information; currently, PU mainly adopts that alkaline batteries or lithium batteries are responsible for providing energy for the work of nodes, and the energy unit is related to the lifetime of the entire network.(1)∑Ii,j−∑δ¯i,j+δ¯maxi2+j2=0.Many small nodes are scattered in the environment to be tested, and nodes with specific functions form a wireless network. Finally, the monitoring center also real-time control and management of network nodes can be achieved through the received information.Since the functional characteristics of the sink node determine its stronger data processing, fusion and information transmission capabilities than ordinary nodes, it can not only realize the connection between WSN and the Internet and other external networks but also send the collected data information to the external network.(2)limx⟶∞δ¯max−δ¯min−limx⟶∞δ¯i,j+δ¯max=0.With the collection and transmission of data, network nodes gradually exhaust their own energy. Natural and human factors may also cause node failure or death, communication link quality, and wireless medium’s own factors will affect the normal operation of the entire network. These are several types of cause networks. At this time, if the network is paralyzed and the tasks delivered by the user cannot be completed normally, it means that the network does not have good robustness, and the design of the digital twin protocol must consider good robustness or robustness. In a specific environment, robustness is difficult to evaluate by a single value, and it is usually discussed in detail based on node and link models.


## 3.2. Distribution of Sensor Node System

A wireless sensor network system usually includes a sensor node, a base station node, and an application node. A large number of sensor nodes are arbitrarily scattered in the designated sensor field. Each node can collect the information of the sensing object in Figure1. After the query is sent for a period of time, the sink starts to receive the returned information from multiple paths. At this time, it selects the optimal path from it and sends a “path strengthening” message to the corresponding neighboring node. The “path enhancement” message is also a query command, which is different from the previous one in that it contains a larger information collection rate.Figure 1
Sensor node system distribution topology.The “path strengthening” message is transmitted hop by hop along the optimal path to the sensor node being queried. This path becomes the “main path,” and the other paths become the backup paths accordingly. After the sensor node receives the “path enhancement” message, it will collect the information according to the required rate in Table1.Table 1
Data forwarding in the sensor network.
Data numberSensor network 1Sensor network 2Sensor network 3116.7744.297.26216.8944.447.33317.4245.077.64418.1145.928.04518.7946.738.43619.3147.378.74719.6247.748.92The closer the node is to the base station, the smaller the node’s competition radius. Correspondingly, the cluster structure closer to the base station is smaller, which will reduce the energy consumption of data communication in the cluster, and can reserve more energy for the relay and forwarding services between clusters.In the network access protocol, each wireless sensor node in the network is homogeneous, that is, has the same state, and is randomly distributed at any location in the network. The disadvantage is that the cost of establishing and maintaining a digital twin is high, and the number of data transmission hops is large, which is not suitable for large-scale network applications.There is no hierarchy of nodes in the network access protocol. The node sends data directly to the sink node, or it can be forwarded to the sink node. The flooding digital twin protocol is that after each node receives the information, it forwards data packets to neighboring nodes in the form of broadcast.(3)fort,t−1∈Cr,t,Atα,β=FAt,t−1,Mi,t.Flooding the digital twin agreement is prone to implosion. The normal node first sends data to each neighboring node to receive the data and sends it to other nodes except itself. And so on, until the collected data information is transmitted to the sink node, or until the node information data expires. The biggest problem with this protocol is that it generates a large number of duplicate data packets and occupies a large amount of network resources, which makes the digital twin and link resources too wasteful, resulting in low efficiency.


## 3.3. Cluster before Digital Information Update

The GEAR digital twin mechanism establishes an optimized event area, avoiding flooding propagation, thereby reducing the cost of establishing the digital twin. The future situation prediction stage is based on the law of the development of the network load process to realize the trend prediction of the future operation state of the system. The future forecast results will be submitted to the operation dispatcher for decision-making and use, and the closed-loop control of the network load will be realized.(4)∬Atα,βdadb−∬At,t−1,Mi,tdtdt−1=0.In the GEAR digital twin, the wireless links between nodes are symmetrical. The query message propagation in the GEAR route includes two stages. This link is the core of the entire situational awareness process. It also runs through the entire situational awareness process.(5)βt=α1−λ2−λ1λ2+λ1,t≤0,α1−1,t>0.The chain head node will generate a token that can control the transmission of data along the direction of the chain head leader node. In each subsequent round, the node closest to the end of the chain will join the current chain and become the new end of the chain. When all sensor nodes have joined the chain, the final network node chain structure is formed.In the chain structure, when a node dies, the chain structure needs to be reconstructed to prevent the chain from breaking. In each round, the leader node at the head of the chain stays with the node, and the remaining nodes only collect and receive data and merge them, and forward the fused data along the chain to the next-hop neighbor nodes in Figure2.Figure 2
Cluster histogram before digital information update.The directed diffusion protocol is a query-based digital twin protocol and a data-centric digital twin protocol. The agreement is divided into three stages: interest diffusion, gradient establishment, and path strengthening. The sink node determines the best path according to the magnitude of the “gradient” value. This protocol is very energy-efficient, but it is to establish the best path and consumes energy during the digital twin.


## 3.4. Network Load Balancing Overlap

Because wireless sensor networks are different from traditional wireless networks, other wireless sensor network digital twin algorithms cannot be simply applied to wireless sensor networks. A suitable digital twin algorithm must be designed according to the characteristics of the wireless sensor network itself for network access algorithms and network load algorithms.(6)∏α1α1−1α2+α1En1+λ1∏α1α1−1α2+α1En1+λ1=1.When there is a corresponding request, the data information is sent to the destination. During data transmission or reception, each node in Figure3 first detects the energy status, and if it is in a low energy status, it stops some unimportant operations, such as stopping as a relay node. But the message sent by the publisher is asynchronous, there is no need to wait for the subscriber to subscribe, and it does not care whether the subscriber subscribes or not.Figure 3
Analysis of overlapping fitness of network load balancing.The real-time situation understanding stage is mainly to obtain network load data and information for integration and analysis and then conduct situation assessment and comprehensively evaluate the stability of network load through the establishment of various stability indicators and systems.The advantage of the SPIN protocol is that the use of a metadata negotiation mechanism eliminates the entire network and solves the problems of implosion and overlap.First of all, the protocol is established on a relatively abstract level to analyze and design sensor networks, without a more practical wireless network model. Secondly, the volatility of network nodes and links is not taken into consideration, and fault-tolerant technology is not supported. Finally, the resource adaptive technology proposed is relatively simple, not complete enough, and not suitable for actual wireless sensor network applications.(7)Gx,t,n∣x2−t2=0−α2+α1En1+λ1En1‐λ1α2−α1=0.For the digital twin protocol, the cluster heads are randomly selected in a probabilistic manner. Currently, various types of network load data information that can be collected mainly include network topology, real-time operation data, equipment component information, and network load.The entire network topology is constantly changing, and the lifespan is short; the entire network chain digital twin of the protocol causes 99% of the nodes to need to fuse data, the first node of the chain has a large load and high energy consumption, and the data transmission delay of the end node is high. A WSN collaborative network load design method based on hierarchical area division (CCRD-HRD) is proposed. Based on SCA-HRD, this method adds consideration to discrete clusters and designs collaborative digital twins.


## 4. Wireless Sensor Network Access Control and Load Balancing Model Construction in the Industrial Digital Twin Scenario

### 4.1. Industrial Digital Hierarchical Topology

For wireless sensor networks, network topology control has a particularly important meaning. Using real-life temperature data for simulation, the results show that compared with existing data collection methods at different decoding rates, the solution proposed in this chapter can always obtain better data quality without the need to deploy a dedicated sensor network.(8)forr,t−1∈Cr−1,t,∑Qk∗giyik2=∑giyik2∑Cx∗giyik2.Situational awareness is the core link to realize real-time monitoring of large network loads. It extracts, analyzes, evaluates, and predicts network load and stable behavior based on the wide-area operating status information of the network load, in order to realize online security early warning and intelligence to lay the foundation for active regulation.Among them, the prerequisite for the whole network load situation awareness is to realize the extraction of situation elements first, and its purpose is to monitor the state of the power system and obtain data information. With the expansion and development of the power system in Table2, the collection scope and technical means of situation elements are constantly expanding.Table 2
Backbone network node communication module.
Node IDDistance from the nodeNeighbor node status(S1, S2, S3)D12Route_flag 1(S2, S2, S3)D21Power control 1(S3, S2, S3)D33Power control 2(S1, S1, S3)D14Route_flag 2(S1, S3, S3)D42Route_flag 3(S1, S2, S1)D24Power control 3(S1, S2, S2)D13Power control 4In addition to traditional power control and hierarchical topology control, people have also proposed heuristic node wake-up and sleep mechanisms. This mechanism enables the node to set the communication module to sleep when no event occurs and automatically wakes up and wakes up neighboring nodes in time when an event occurs. This mechanism cannot be used independently as a topology control mechanism and needs to be used in conjunction with other topology control algorithms.


### 4.2. Wireless Sensor Network Protocol Stack

Due to the limitations of sensor node energy, computing, and storage capabilities, as well as the constant changes in sensor network topology and network resources, traditional network protocols cannot be used in wireless nodes. In wireless sensor networks, the digital twin protocol not only cares about the energy consumption of a single node but also cares about the balanced network. At the same time, the wireless sensor network is data-centric and establishes a forwarding path from the data source to the sink node based on the data of interest.(9)α2+α1En1+λ1En1‐λ1α2−α1∣1001=λ−11λ∣α111α1.By placing a large number of sensor nodes, enough paths are provided to satisfy the survival of the network and adapt to the environment. The system must also consider some important parameter settings, such as network size, node density, and the trade-off between energy consumption, reliability, and response time. Subscribers can subscribe to multiple channels, and publishers can send messages to subscribers through channels.The energy waste at the MAC layer is mainly manifested in idle listening, receiving unnecessary data, and collision retransmissions. Assuming that the transmitting radius of the node isR, the farthest distance from the base station to the monitoring area is D. The base station in Figure 4 first determines its own gradient level as O and calculates the number of gradient levels N=D/R to be divided.Figure 4
Gradient distribution of wireless sensor network protocol stack.The node that has not received the gradient message determines that its gradient isn after receiving the message, and the node that has determined its gradient discards it when it receives this message. After the gradient is established, the node sends interactive information to neighboring nodes and saves the received interactive information.After the interaction is completed, the node calculates and updates its own comprehensive weight based on the interaction by the neighboring node. In the clustering stage, the node first uses the updated weight to compare with the weight of the neighbor set: if the comparison between nodea and any node b in the neighbor set meets any of the following rules, then the weight ratio of node a is considered.
(10)∂∂WijlJw,b‐∬∂∂WijlAtα,βdadb=0.In order to reduce energy consumption, the MAC protocol usually adopts an alternate wireless channel listening mechanism of “listening/sleeping.” The sensor node only listens to the wireless channel when it needs to send and receive data, and try to enter the sleep state when there is no data to send and receive. Since the wireless sensor network is an application-related network, when the application requirements are different, the network protocol often needs to be customized according to the application type or the characteristics of the application target environment. No single protocol can fully adapt to a variety of different applications.


### 4.3. Network Algorithm Clustering Results

In the clustering process of the network algorithm, first calculate the optimal number of clusters for each divided area according to a certain strategy, and then use the digital twin algorithm to perform the first round of random clustering for each divided area intermittently, and only need to cluster later internal adjustment, and consider the nodes in Table3, to avoid the nodes of the whole network periodically and frequently clustering and consuming too much energy and low-energy nodes serving as cluster head nodes multiple times.Table 3
Data transmission delay of chain end node.
ParametersTransmission node 1Transmission node 2Transmission node 3Distribution area509.2632.1014.14Base station coordinates509.8831.4911.30Number of nodes510.4932.948.60Data packet size511.1136.276.69Node initialization energy511.7340.856.19Signal threshold512.3545.767.39State cluster512.9650.0710.14In multihop data transmission between clusters, a threshold TD-MAx is introduced. If the distance between the cluster head node and the base station is less than TD-MAx, the cluster head node directly transmits the data to the base station. On the contrary, use the method described below as much as possible to transmit the collected data.When the intercluster multihop transmission starts, each cluster head broadcasts a NoDE-s containing the cluster head ID, the current remaining energy, and its distance to the base station with the same power; it will maintain a set of candidate digital twin nodes according to the received message. The node decides whether to join the cluster head competition according to its own remaining energy.(11)∇Jw,b∇Jb−∇1b∑i=1mJw,b;xi,yi+λWijl=0.The number of clusters is then refined into each divided area, and each divided area is intermittently used to perform specific clustering with the improved combination of digital twin and PEGASIS algorithm. Once the clustering is done, each divided region is formed. The member nodes in the cluster perform data collection, and cluster head nodes perform data fusion. Finally, each cluster head node forwards the fused data through the collaborative data transmission digital twin between the clusters and finally transmits it to the sink node. This process continues until the end of the wireless sensor network life cycle, and the duration is as long as possible.


## 4.1. Industrial Digital Hierarchical Topology

For wireless sensor networks, network topology control has a particularly important meaning. Using real-life temperature data for simulation, the results show that compared with existing data collection methods at different decoding rates, the solution proposed in this chapter can always obtain better data quality without the need to deploy a dedicated sensor network.(8)forr,t−1∈Cr−1,t,∑Qk∗giyik2=∑giyik2∑Cx∗giyik2.Situational awareness is the core link to realize real-time monitoring of large network loads. It extracts, analyzes, evaluates, and predicts network load and stable behavior based on the wide-area operating status information of the network load, in order to realize online security early warning and intelligence to lay the foundation for active regulation.Among them, the prerequisite for the whole network load situation awareness is to realize the extraction of situation elements first, and its purpose is to monitor the state of the power system and obtain data information. With the expansion and development of the power system in Table2, the collection scope and technical means of situation elements are constantly expanding.Table 2
Backbone network node communication module.
Node IDDistance from the nodeNeighbor node status(S1, S2, S3)D12Route_flag 1(S2, S2, S3)D21Power control 1(S3, S2, S3)D33Power control 2(S1, S1, S3)D14Route_flag 2(S1, S3, S3)D42Route_flag 3(S1, S2, S1)D24Power control 3(S1, S2, S2)D13Power control 4In addition to traditional power control and hierarchical topology control, people have also proposed heuristic node wake-up and sleep mechanisms. This mechanism enables the node to set the communication module to sleep when no event occurs and automatically wakes up and wakes up neighboring nodes in time when an event occurs. This mechanism cannot be used independently as a topology control mechanism and needs to be used in conjunction with other topology control algorithms.


## 4.2. Wireless Sensor Network Protocol Stack

Due to the limitations of sensor node energy, computing, and storage capabilities, as well as the constant changes in sensor network topology and network resources, traditional network protocols cannot be used in wireless nodes. In wireless sensor networks, the digital twin protocol not only cares about the energy consumption of a single node but also cares about the balanced network. At the same time, the wireless sensor network is data-centric and establishes a forwarding path from the data source to the sink node based on the data of interest.(9)α2+α1En1+λ1En1‐λ1α2−α1∣1001=λ−11λ∣α111α1.By placing a large number of sensor nodes, enough paths are provided to satisfy the survival of the network and adapt to the environment. The system must also consider some important parameter settings, such as network size, node density, and the trade-off between energy consumption, reliability, and response time. Subscribers can subscribe to multiple channels, and publishers can send messages to subscribers through channels.The energy waste at the MAC layer is mainly manifested in idle listening, receiving unnecessary data, and collision retransmissions. Assuming that the transmitting radius of the node isR, the farthest distance from the base station to the monitoring area is D. The base station in Figure 4 first determines its own gradient level as O and calculates the number of gradient levels N=D/R to be divided.Figure 4
Gradient distribution of wireless sensor network protocol stack.The node that has not received the gradient message determines that its gradient isn after receiving the message, and the node that has determined its gradient discards it when it receives this message. After the gradient is established, the node sends interactive information to neighboring nodes and saves the received interactive information.After the interaction is completed, the node calculates and updates its own comprehensive weight based on the interaction by the neighboring node. In the clustering stage, the node first uses the updated weight to compare with the weight of the neighbor set: if the comparison between nodea and any node b in the neighbor set meets any of the following rules, then the weight ratio of node a is considered.
(10)∂∂WijlJw,b‐∬∂∂WijlAtα,βdadb=0.In order to reduce energy consumption, the MAC protocol usually adopts an alternate wireless channel listening mechanism of “listening/sleeping.” The sensor node only listens to the wireless channel when it needs to send and receive data, and try to enter the sleep state when there is no data to send and receive. Since the wireless sensor network is an application-related network, when the application requirements are different, the network protocol often needs to be customized according to the application type or the characteristics of the application target environment. No single protocol can fully adapt to a variety of different applications.


## 4.3. Network Algorithm Clustering Results

In the clustering process of the network algorithm, first calculate the optimal number of clusters for each divided area according to a certain strategy, and then use the digital twin algorithm to perform the first round of random clustering for each divided area intermittently, and only need to cluster later internal adjustment, and consider the nodes in Table3, to avoid the nodes of the whole network periodically and frequently clustering and consuming too much energy and low-energy nodes serving as cluster head nodes multiple times.Table 3
Data transmission delay of chain end node.
ParametersTransmission node 1Transmission node 2Transmission node 3Distribution area509.2632.1014.14Base station coordinates509.8831.4911.30Number of nodes510.4932.948.60Data packet size511.1136.276.69Node initialization energy511.7340.856.19Signal threshold512.3545.767.39State cluster512.9650.0710.14In multihop data transmission between clusters, a threshold TD-MAx is introduced. If the distance between the cluster head node and the base station is less than TD-MAx, the cluster head node directly transmits the data to the base station. On the contrary, use the method described below as much as possible to transmit the collected data.When the intercluster multihop transmission starts, each cluster head broadcasts a NoDE-s containing the cluster head ID, the current remaining energy, and its distance to the base station with the same power; it will maintain a set of candidate digital twin nodes according to the received message. The node decides whether to join the cluster head competition according to its own remaining energy.(11)∇Jw,b∇Jb−∇1b∑i=1mJw,b;xi,yi+λWijl=0.The number of clusters is then refined into each divided area, and each divided area is intermittently used to perform specific clustering with the improved combination of digital twin and PEGASIS algorithm. Once the clustering is done, each divided region is formed. The member nodes in the cluster perform data collection, and cluster head nodes perform data fusion. Finally, each cluster head node forwards the fused data through the collaborative data transmission digital twin between the clusters and finally transmits it to the sink node. This process continues until the end of the wireless sensor network life cycle, and the duration is as long as possible.


## 5. Application and Analysis of Wireless Sensor Network Access Control and Load Balancing Model in the Industrial Digital Twin Scenario

### 5.1. Industrial Digital Data Element Preprocessing

In the wireless sensor network, the energy consumption of the wireless communication module of the sensor node in the idle state is equivalent to that in the transceiver state, so only by turning off the node’s communication module can the energy consumption of the wireless communication module be greatly reduced, considering a certain mechanism choice.A subscriber, such as a client, expresses an event or a type of event that it is interested in receiving in the form of event subscription. Some nodes are used as backbone network nodes, and their communication modules are turned on, and the communication modules of nonbackbone nodes are turned off. The backbone nodes build a network to be responsible for the digital twin forwarding of data.(12)∂Jw,b;xi,yiJxi,yi=∂fxi,yi∂fx,y.After the wireless sensor network monitoring area is divided into hierarchical regions, the first-level region closest to the sink node is first used to calculate the probability and the principle of minimizing total energy consumption and then based on the total energy between regions.Among them, the cluster head selection probability of each area in Table4 is different, and it becomes smaller as the distance from the sink node increases, so as to ensure the nonuniform clustering of the entire network. Through this algorithm, participants can compress the sensory data collected in the target area into CS measurement values. In order to improve data quality, a data reconstruction algorithm based on multiple rounds is further proposed.Table 4
Algorithm of optimal cluster number for hierarchical area.
Circle stepsAlgorithm meaningStep codes1Upper-layer applications inXi% Program P1_12An efficient network control system% Generation of a Unit Sample Sequence3The cluster head selection probabilityX¯Clf;4Logical network structure asXi−X¯% Generate a vector from -10 to 205A reasonable and effective networkN = -10:20;6The distance from the sink node∑i=1nκXi% Generate the unit sample sequence7In networks depends on the clusteredμXκ−tU = [zeros (1,3) ones(1,28)];8A foundation for data fusion inXi+X¯2% Plot the unit sample sequence9Good clustering algorithmStem (n,u);10It becomes smaller as the distance∑i=1nXi+X¯2Xlabel ('Time index n'); ylabel ('Amplitude');11It is possible to establishℤ0,1Title ('Unit Step Sequence');12The application of many protocolsAxis ([-10 20 0 1.2]);13So as to ensure the nonuniformAt,t−1Clf; % Clear old graph14It provides channel control incovXi−X¯∣XStem (n,x); % Plot the generated sequence15It is beneficial to extending the lifetimeAxis ([0 40 -4 4]);16A foundation for data fusion inlimx⟶∞Xi−X¯2Grid;A good clustering algorithm can provide a foundation for data fusion, time synchronization, target positioning, and network management and is beneficial to extending the time of the entire network. Based on a reasonable and effective network clustering structure, it is possible to establish an efficient network control system, realize effective resource scheduling and application including bandwidth allocation and frequency reuse, provide channel access control, efficient digital twin computing, and establish virtual circuits and other functions.The application of many protocols in sensor networks depends on the clustered logical network structure, and many upper-layer applications can run on this structure. By introducing a new spatiotemporal data abstract model in the target perception area, the participant’s movement process is represented as a random measurement of the perception task.(13)∂Jw,b;xi,yi∂Jw,b=∂fw,b∂fw∂fb.The protocol uses digital twins in the multihop phase between clusters to adaptively determine the weight coefficients occupied by multiple metric factors. The selection of each metric factor is of great significance for the node when selecting the next hop standard for evaluating the network survival time, and the distance can reduce the number of hops and reduce the transmission delay.The quality status can estimate the reliability of the wireless link transmission channel, and they reserve more energy for intercluster data forwarding. In this paper, when the cluster head node selects the next hop node in the multihop phase between clusters, it is based on a cost function improved from the protocol, which includes the cluster head. The number of internal members is used as a measurement factor, and the weight coefficients occupied by each measurement factor in the cost function are objectively and adaptively calculated using digital twins.


### 5.2. Realization of Wireless Sensor Network Access Control Simulation

Assuming that nodes in the wireless sensor network access control, each node calculates the probability of becoming a candidate cluster head according to the formula. In each round of selection of cluster heads, the percentage of candidate cluster heads to all nodes isp. For all nodes N, the number of candidate cluster heads will be approximately N×p, and HEAD_MsG will be broadcast.
(14)limx⟶∞At,t−1−Mi,t=ℤ0,1,limx⟶∞At−Mt=ℤ0,0.After that, ifK nodes are generated from these candidate cluster head nodes as cluster head nodes in this round, it is necessary to broadcast MsG messages with the largest energy and MsG messages for successful elections. Finally, the remaining N-K ordinary nodes in the network select the cluster head node with a stronger signal according to the received signal strength.The cluster head node in Figure5 calculates and sends K time slot information to the member nodes in the cluster. Based on the above analysis, in each round of cluster formation, the total number of messages in the network is N×p. Experimental results show that compared with existing collection methods, the proposed scheme can obtain better data quality under different decoding rates.Figure 5
Distribution of wireless sensor network access control nodes.This article will use OMNeT++ (Objective Modular Network Testbed in C++) as a simulation platform tool. This software is a component-based, object-oriented modular simulation software. OMNeT++ provides a graphical network editor and network data stream viewing tool and can run on multiple operating system platforms. It uses events as the basic communication mechanism to provide the loosely coupled interaction mode required by large-scale systems.On the OMNeT++ platform, the network protocol is written in “+” language, and the user-defined language “NE0” is used to construct the network model. Compared with simulation platforms such as Ns-2 and OPN, OMNe++ not only can easily define the network topology and has obvious advantages in the perfection of the model library and the support for debugging and tracing of the protocol code.(15)Qk∗giyik2Cx−CxQk∗giyik2×sinθ−cosθcosθ−sinθ=1.The main documents are introduced as follows: (1) need file: use ned language to describe the network topology, network simulation parameters, and network connections between nodes; (2) cc file: use “+ language to write each module algorithm; (3) msg file: message file, mainly used to simulate various events, messages, frames, etc. in the transmission process; (4) I.b file: the kernel library and user connection library used in the simulation process; (5) ini file: users set various parameters in the simulation module; and (6) -vec and -sna files: output vector files and output scalar files, mainly it is used to store data and record the simulation results.(16)∑i=1nκXiZi−∑i=1nκXi+μX=∑i=1nμXκ−tXi.According to two different values ofc, the sensory data collected by each participant in the target area during a period of time will be compressed into a measured value. The original data is reconstructed by an iterative algorithm using the measurement matrix and measured values. In order to improve the quality of data reconstruction, a data recovery algorithm based on multiple rounds is further proposed by using the time correlation between the data.


### 5.3. Case Application and Analysis

In this paper, the algorithm is mainly simulated and tested. In the case of limited experimental conditions, MATLAB is mainly used as an experimental simulation tool to simulate the setting of WSN simulation scenarios and simulation parameters, and the experimental simulation is performed based on the simulation performance metrics.Through several simulations in MATLAB, better simulation analysis results of the network survival time and total energy consumption of the three algorithms are obtained. For the simulation results of the network survival time in Figure6, we, respectively, counted the number of rounds of the three algorithms at the beginning of dead nodes, 10% node deaths, 50% node deaths, 70% node deaths, and the entire network node death.Figure 6
Comparison distribution of total energy consumption of wireless sensor network load.This article is the effect diagram of the nonuniform clustering of the protocol formed by 100 nodes in a square network with a side length. Among them, the first to sixth steps are the cluster formation stage, and the seventh to eighth steps are the intercluster multihop data transmission stage.In the first step of the protocol, network initialization for the base station sends a start message to all nodes. All nodes calculate the approximate distance from the base station based on the received signal strength. The dead node no longer establishes any contact with the base station. When the participants move to some monitoring points to collect data, the movement of the monitoring points is similar to the random walk between nodes in WSNs to collect data.(17)covXi−X¯∣X=∑i=1nXi−X¯2+∑i=1nXi+X¯2+∑i=1nXi2.In the text, the green dot represents the broadcast message, and the straight line with the arrow represents the wireless communication connection established by the node and the base station; the right picture shows the start of the surviving node in the network receiving the base station transmission, where the white dots represent nodes that died due to exhaustion of energy, and no communication connection with the base station is established.It can be seen that the algorithm prolongs the network lifetime more effectively. For the simulation results of the network, the number of rounds in which the three algorithms consume 10% of the total energy, 50% of the total energy, 70% of the total energy, and total energy consumption of the three algorithms is, respectively, counted. In a sense, its trajectory can completely cover the target area. In this topic, a distributed coding algorithm based on compressed sensing is proposed.All nodes in the network in Figure7 enter the dormant state. Each node that becomes a candidate cluster head will broadcast the message according to its own competition radius. After receiving the message, the other candidate in the election before will be awakened from the dormant state.Figure 7
Three-dimensional distribution of the survival time of wireless sensor network.The message with stronger signal is selected, and the message is sent to it to apply to join the cluster. The cluster head node will calculate the TDMA time slot according to the number of members in the cluster and send it to the establishment of the cluster which is completed. First, we simulate the movement trajectory of the participant and obtain the respective measurement vector of the participant through the trajectory position. Multiple participant trajectories can obtain a binary measurement matrix.(18)covXi−X¯∣XcovXi+X¯∣X=limx⟶∞Xi−X¯2×∑i=1n∑i=1nXi−X¯22∑i=1nXi+X¯2.After the cluster in each level area is formed in the cluster domain, it will allocate time slots according to the TDMA scheduling method. At the beginning, the member nodes in the cluster are in a dormant state. When the participants move to some monitoring points to collect data, the movement of the monitoring points is similar to the random walk between nodes in WSNs to collect data.When the node is activated, the member nodes in the nonchain structure collect data and send it to the cluster head in a single hop, while the cluster node in the chain structure needs to transmit the data along the chain after collecting the data pairs. If the node meets the conditions, it will become a candidate cluster head, and then, the candidate cluster head selects the final cluster head node through regional competition.


## 5.1. Industrial Digital Data Element Preprocessing

In the wireless sensor network, the energy consumption of the wireless communication module of the sensor node in the idle state is equivalent to that in the transceiver state, so only by turning off the node’s communication module can the energy consumption of the wireless communication module be greatly reduced, considering a certain mechanism choice.A subscriber, such as a client, expresses an event or a type of event that it is interested in receiving in the form of event subscription. Some nodes are used as backbone network nodes, and their communication modules are turned on, and the communication modules of nonbackbone nodes are turned off. The backbone nodes build a network to be responsible for the digital twin forwarding of data.(12)∂Jw,b;xi,yiJxi,yi=∂fxi,yi∂fx,y.After the wireless sensor network monitoring area is divided into hierarchical regions, the first-level region closest to the sink node is first used to calculate the probability and the principle of minimizing total energy consumption and then based on the total energy between regions.Among them, the cluster head selection probability of each area in Table4 is different, and it becomes smaller as the distance from the sink node increases, so as to ensure the nonuniform clustering of the entire network. Through this algorithm, participants can compress the sensory data collected in the target area into CS measurement values. In order to improve data quality, a data reconstruction algorithm based on multiple rounds is further proposed.Table 4
Algorithm of optimal cluster number for hierarchical area.
Circle stepsAlgorithm meaningStep codes1Upper-layer applications inXi% Program P1_12An efficient network control system% Generation of a Unit Sample Sequence3The cluster head selection probabilityX¯Clf;4Logical network structure asXi−X¯% Generate a vector from -10 to 205A reasonable and effective networkN = -10:20;6The distance from the sink node∑i=1nκXi% Generate the unit sample sequence7In networks depends on the clusteredμXκ−tU = [zeros (1,3) ones(1,28)];8A foundation for data fusion inXi+X¯2% Plot the unit sample sequence9Good clustering algorithmStem (n,u);10It becomes smaller as the distance∑i=1nXi+X¯2Xlabel ('Time index n'); ylabel ('Amplitude');11It is possible to establishℤ0,1Title ('Unit Step Sequence');12The application of many protocolsAxis ([-10 20 0 1.2]);13So as to ensure the nonuniformAt,t−1Clf; % Clear old graph14It provides channel control incovXi−X¯∣XStem (n,x); % Plot the generated sequence15It is beneficial to extending the lifetimeAxis ([0 40 -4 4]);16A foundation for data fusion inlimx⟶∞Xi−X¯2Grid;A good clustering algorithm can provide a foundation for data fusion, time synchronization, target positioning, and network management and is beneficial to extending the time of the entire network. Based on a reasonable and effective network clustering structure, it is possible to establish an efficient network control system, realize effective resource scheduling and application including bandwidth allocation and frequency reuse, provide channel access control, efficient digital twin computing, and establish virtual circuits and other functions.The application of many protocols in sensor networks depends on the clustered logical network structure, and many upper-layer applications can run on this structure. By introducing a new spatiotemporal data abstract model in the target perception area, the participant’s movement process is represented as a random measurement of the perception task.(13)∂Jw,b;xi,yi∂Jw,b=∂fw,b∂fw∂fb.The protocol uses digital twins in the multihop phase between clusters to adaptively determine the weight coefficients occupied by multiple metric factors. The selection of each metric factor is of great significance for the node when selecting the next hop standard for evaluating the network survival time, and the distance can reduce the number of hops and reduce the transmission delay.The quality status can estimate the reliability of the wireless link transmission channel, and they reserve more energy for intercluster data forwarding. In this paper, when the cluster head node selects the next hop node in the multihop phase between clusters, it is based on a cost function improved from the protocol, which includes the cluster head. The number of internal members is used as a measurement factor, and the weight coefficients occupied by each measurement factor in the cost function are objectively and adaptively calculated using digital twins.


## 5.2. Realization of Wireless Sensor Network Access Control Simulation

Assuming that nodes in the wireless sensor network access control, each node calculates the probability of becoming a candidate cluster head according to the formula. In each round of selection of cluster heads, the percentage of candidate cluster heads to all nodes isp. For all nodes N, the number of candidate cluster heads will be approximately N×p, and HEAD_MsG will be broadcast.
(14)limx⟶∞At,t−1−Mi,t=ℤ0,1,limx⟶∞At−Mt=ℤ0,0.After that, ifK nodes are generated from these candidate cluster head nodes as cluster head nodes in this round, it is necessary to broadcast MsG messages with the largest energy and MsG messages for successful elections. Finally, the remaining N-K ordinary nodes in the network select the cluster head node with a stronger signal according to the received signal strength.The cluster head node in Figure5 calculates and sends K time slot information to the member nodes in the cluster. Based on the above analysis, in each round of cluster formation, the total number of messages in the network is N×p. Experimental results show that compared with existing collection methods, the proposed scheme can obtain better data quality under different decoding rates.Figure 5
Distribution of wireless sensor network access control nodes.This article will use OMNeT++ (Objective Modular Network Testbed in C++) as a simulation platform tool. This software is a component-based, object-oriented modular simulation software. OMNeT++ provides a graphical network editor and network data stream viewing tool and can run on multiple operating system platforms. It uses events as the basic communication mechanism to provide the loosely coupled interaction mode required by large-scale systems.On the OMNeT++ platform, the network protocol is written in “+” language, and the user-defined language “NE0” is used to construct the network model. Compared with simulation platforms such as Ns-2 and OPN, OMNe++ not only can easily define the network topology and has obvious advantages in the perfection of the model library and the support for debugging and tracing of the protocol code.(15)Qk∗giyik2Cx−CxQk∗giyik2×sinθ−cosθcosθ−sinθ=1.The main documents are introduced as follows: (1) need file: use ned language to describe the network topology, network simulation parameters, and network connections between nodes; (2) cc file: use “+ language to write each module algorithm; (3) msg file: message file, mainly used to simulate various events, messages, frames, etc. in the transmission process; (4) I.b file: the kernel library and user connection library used in the simulation process; (5) ini file: users set various parameters in the simulation module; and (6) -vec and -sna files: output vector files and output scalar files, mainly it is used to store data and record the simulation results.(16)∑i=1nκXiZi−∑i=1nκXi+μX=∑i=1nμXκ−tXi.According to two different values ofc, the sensory data collected by each participant in the target area during a period of time will be compressed into a measured value. The original data is reconstructed by an iterative algorithm using the measurement matrix and measured values. In order to improve the quality of data reconstruction, a data recovery algorithm based on multiple rounds is further proposed by using the time correlation between the data.


## 5.3. Case Application and Analysis

In this paper, the algorithm is mainly simulated and tested. In the case of limited experimental conditions, MATLAB is mainly used as an experimental simulation tool to simulate the setting of WSN simulation scenarios and simulation parameters, and the experimental simulation is performed based on the simulation performance metrics.Through several simulations in MATLAB, better simulation analysis results of the network survival time and total energy consumption of the three algorithms are obtained. For the simulation results of the network survival time in Figure6, we, respectively, counted the number of rounds of the three algorithms at the beginning of dead nodes, 10% node deaths, 50% node deaths, 70% node deaths, and the entire network node death.Figure 6
Comparison distribution of total energy consumption of wireless sensor network load.This article is the effect diagram of the nonuniform clustering of the protocol formed by 100 nodes in a square network with a side length. Among them, the first to sixth steps are the cluster formation stage, and the seventh to eighth steps are the intercluster multihop data transmission stage.In the first step of the protocol, network initialization for the base station sends a start message to all nodes. All nodes calculate the approximate distance from the base station based on the received signal strength. The dead node no longer establishes any contact with the base station. When the participants move to some monitoring points to collect data, the movement of the monitoring points is similar to the random walk between nodes in WSNs to collect data.(17)covXi−X¯∣X=∑i=1nXi−X¯2+∑i=1nXi+X¯2+∑i=1nXi2.In the text, the green dot represents the broadcast message, and the straight line with the arrow represents the wireless communication connection established by the node and the base station; the right picture shows the start of the surviving node in the network receiving the base station transmission, where the white dots represent nodes that died due to exhaustion of energy, and no communication connection with the base station is established.It can be seen that the algorithm prolongs the network lifetime more effectively. For the simulation results of the network, the number of rounds in which the three algorithms consume 10% of the total energy, 50% of the total energy, 70% of the total energy, and total energy consumption of the three algorithms is, respectively, counted. In a sense, its trajectory can completely cover the target area. In this topic, a distributed coding algorithm based on compressed sensing is proposed.All nodes in the network in Figure7 enter the dormant state. Each node that becomes a candidate cluster head will broadcast the message according to its own competition radius. After receiving the message, the other candidate in the election before will be awakened from the dormant state.Figure 7
Three-dimensional distribution of the survival time of wireless sensor network.The message with stronger signal is selected, and the message is sent to it to apply to join the cluster. The cluster head node will calculate the TDMA time slot according to the number of members in the cluster and send it to the establishment of the cluster which is completed. First, we simulate the movement trajectory of the participant and obtain the respective measurement vector of the participant through the trajectory position. Multiple participant trajectories can obtain a binary measurement matrix.(18)covXi−X¯∣XcovXi+X¯∣X=limx⟶∞Xi−X¯2×∑i=1n∑i=1nXi−X¯22∑i=1nXi+X¯2.After the cluster in each level area is formed in the cluster domain, it will allocate time slots according to the TDMA scheduling method. At the beginning, the member nodes in the cluster are in a dormant state. When the participants move to some monitoring points to collect data, the movement of the monitoring points is similar to the random walk between nodes in WSNs to collect data.When the node is activated, the member nodes in the nonchain structure collect data and send it to the cluster head in a single hop, while the cluster node in the chain structure needs to transmit the data along the chain after collecting the data pairs. If the node meets the conditions, it will become a candidate cluster head, and then, the candidate cluster head selects the final cluster head node through regional competition.


## 6. Conclusion

In the homogeneous node environment, based on the network load algorithm, this paper optimizes the digital twin topology structure, divides the network nodes into two layers, constructs the network nodes into multiple subchains at the bottom layer, and selects the main chain head and the branch chain heads to construct the top-level chain head chain. Secondly, the isolated points generated in the chain formation process are processed in a tree structure to reduce the length of the data transmission path, optimize the selection strategy of the main chain head and the branch chain head and the chaining rules, and compare the common nodes and chain heads near the sink. The number of clusters generated is small, and the packet delivery delay is low; but the overlap between the generated clusters is large, the cluster head nodes are often overloaded, and the load among the cluster heads is extremely uneven. At the same time, the gateway node serves as another cluster head to share part of the nodes, which not only maintains the advantages of the original algorithm with less packet delivery delay but also reduces the burden on the cluster head node that is overloaded. Finally, the digital twin algorithm is studied in detail, and an energy adaptive nonuniform clustering algorithm based on digital twin is designed. In addition, the idea of nonuniform clustering is introduced in the single-hop mode, and the clustering radius is determined by integrating node connectivity and the distance between the node and the base station, so that the cluster head far away from the base station manages fewer nodes. The experimental results show that the protocol proposed in this paper is stable in the network, network energy efficiency, and data transmission efficiency. It is superior to other comparison protocols in terms of it and can improve the success rate of data transmission.



---

*Source: 3929958-2022-01-24.xml*