Open Access
ARTICLE
Adaptive Time Synchronization in Time Sensitive-Wireless Sensor Networks Based on Stochastic Gradient Algorithms Framework
1 Department of Physics, Faculty of Science, Universiti Putra Malaysia (UPM), Serdang, 43400, Malaysia
2 International Graduate School of Artificial Intelligence, National Yunlin University of Science and Technology YunTech, Douliu, 64002, Taiwan
3 Sunway University, Petaling Jaya, 47500, Selangor, Malaysia
4 Chandigarh University, Punjab, 140413, India
* Corresponding Author: Mohd Amiruddin Abd Rahman. Email:
Computer Modeling in Engineering & Sciences 2025, 142(3), 2585-2616. https://doi.org/10.32604/cmes.2025.060548
Received 04 November 2024; Accepted 20 January 2025; Issue published 03 March 2025
Abstract
This study proposes a novel time-synchronization protocol inspired by stochastic gradient algorithms. The clock model of each network node in this synchronizer is configured as a generic adaptive filter where different stochastic gradient algorithms can be adopted for adaptive clock frequency adjustments. The study analyzes the pairwise synchronization behavior of the protocol and proves the generalized convergence of the synchronization error and clock frequency. A novel closed-form expression is also derived for a generalized asymptotic error variance steady state. Steady and convergence analyses are then presented for the synchronization, with frequency adaptations done using least mean square (LMS), the Newton search, the gradient descent (GraDes), the normalized LMS (N-LMS), and the Sign-Data LMS algorithms. Results obtained from real-time experiments showed a better performance of our protocols as compared to the Average Proportional-Integral Synchronization Protocol (AvgPISync) regarding the impact of quantization error on synchronization accuracy, precision, and convergence time. This generalized approach to time synchronization allows flexibility in selecting a suitable protocol for different wireless sensor network applications.Keywords
Wireless sensor networks (WSNs) are distributed control systems utilized for a variety of sensing and instrumentation applications. A precise, adaptable, and reliable time synchronization protocol for WSNs is required due to a number of reasons, such as the close connection between sensors and the physical environment [1], the lack of power for stationed nodes, the requirement for large-scale deployment, decentralized topologies, and unpredictable and intermittent connectivity between network nodes [2,3]. Large WSNs need sophisticated time synchronization techniques, especially if the network experiences dynamic changes from time to time and communication among WSN nodes is unstable, resulting in packet losses.
Time delays between node clocks which are caused by transmission and reception, media access, channel propagation, interrupt management, encoding and decoding, and byte alignment, all contribute to synchronization issues between WSN nodes. Therefore, several time synchronization protocols have been implemented as discussed in the literature [4–8]. The protocols can be divided into two variants based on the network architectures adopted in the synchronization. They include centralized protocols (CPs) and distributed protocols (DPs). The centralized and structured algorithms can be further divided into tree-structured and cluster-structured protocols. CPs often accomplish global network synchronization in time by synchronizing all network nodes to a leader node in a hierarchical tree structure or by utilizing network clusters. In most CPs, this leader node gets elected after the preceding one fails. In DPs, nodes communicate clock parameters in their neighborhoods and agree on a global time via trees, clusters, or a leader node. The following section examines various relevant and current centralized and distributed time synchronization techniques.
1.1 Review of Centralized Protocols
The Flooding Time Synchronization Protocol (FTSP) [9] is an ad hoc and multi-hop time synchronization strategy. This protocol assumes the base node as the node with the lowest identity value; the rest of the nodes use its clock value as their reference time. The synchronization packets are transmitted regularly by the root node to all network nodes, containing their local time. FTSP uses linear regression to adjust for drifts between nodes and reference nodes. However, the main issue with this approach is that the resynchronization time is relatively short, requiring a high overhead and as a huge bandwidth during each resynchronization phase, resulting in a significant energy cost.
Chen et al. [10] proposed a closed-loop feedback-based synchronization protocol that implements a proportional-integral (PI) controller to compensate for clock drift. The accuracy of this method is determined by the output and transient times. This technique requires a base node and is synchronized via a tree, hence it is susceptible to connection and node malfunctions.
Yildirim et al. [11] demonstrated that the synchronization accuracy and scalability of WSNs are significantly reduced by the slower flooding transmission speed used in FTSP. In addition, they observed the fact that the PulseSync protocol’s speedy flooding has several disadvantages [12]. They created a procedure that eliminates the negative aspects of delayed flooding in FTSP without changing the flood’s propagation rate. Through tests, they demonstrate that the synchronization accuracy and slow-flooding scaling could be significantly improved using the proposed clock speed agreement technique.
FloodPISync and PulsePISync time synchronization algorithms were introduced in [13] to improve the PulseSync protocol. The techniques represent and change node clocks as a PI controller. The algorithms’ calculations, simulations, and experimental investigations efficiently synchronizes the nodes. Using FloodPISync, the PI analogy changes the nodes clock drift and offset to improve the synchronization of all nodes to the reference node. A similar concept is applied for PulsePISync with the quick flooding technique adapted based on the PulseSync protocol.
Lee et al. [14] presented a novel time synchronization technique that uses a dual-clock delayed message mechanism. The clock synchronization system uses the flooding time-sync approach with one-way timing messages to ensure low power consumption for WSN nodes. The maximum-likelihood technique for time parameters is then employed to calculate the time parameters, such as clock drift and offset. However, because the flooding strategy necessitates transmitting many packets in order to accomplish synchronization, it is inefficient for extensive networks.
1.2 Review of Distributed Protocols
Apicharttrisorn et al. [15] introduced an energy-efficient gradient protocol which is efficient in terms of power and diffused. The technique implements progressive mean estimation and drift prediction to achieve temporal convergence and slope. Because the protocol broadcasts continuously, it produces small trends that use much energy from WSNs. Each node computes the continuous averaging of clock values immediately after it receives the broadcast packet from one of its neighbors. The global time increases as the stepwise averaging is decreased.
Schenato et al. [16] introduced the Average Time Sync (ATS) consensus algorithm. The mechanism works by averaging the nodes’ local times in order to achieve global synchronization in the network. In addition, two consensus approaches are cascaded to compute the clock properties as the clock convergence to a specific value.
Consensus Clock Synchronization (CCS) [17] employs the average consensus technique to compute and adjust each node’s clock offset. The drifted values of each node’s clock from the global consensus time is calculated by accumulating clock offset errors. The drifted values of each node’s clock from the global consensus time are calculated by accumulating clock offset errors. The errors are removed in each iteration from the offset compensation. The clock drift is adjusted by using those data. This system, such as the ATS, is entirely distributed, although it converges somewhat slowly.
Cheng et al. [18] proposed the Maximum Time Synchronization (MTS) protocol which is aimed to maximize local time for global synchronization. Compared to previous methods, this approach has a faster convergence speed. The technique adjusts the skew or offset clock values by defining a finite value. The protocol is entirely distributed, asynchronous, and resilient to node failure. The approach is also feasible for replacing or adding additional nodes. The same study suggested another approach, the Weighted Maximum Time Synchronization Protocol, which addresses the delay issue related to receipt and broadcast packets.
Wu et al. [19] introduced a clustered consensus time synchronization (CCTS) protocol for synchronizing nodes’ clocks in WSNs. The method is distributed in operation and relies on consensus. This CCTS technique was classed as intracluster or intercluster time synchronization. The simulation findings revealed that the node’s communication traffic is reduced. However, the node could be subjected to failures due to dynamic topologies which is caused by the leader nodes.
Yildirim et al. [13] introduced Proportional Integral Synchronization (PISync), a distributed time synchronization technique based on a proportional-integral (PI) controller. They introduced the AvgPISync protocol, an average consensus-based and completely distributed PISync protocol based on the PISync algorithm, and conducted real-world tests and simulations to assess its performance. They reported that the AvgPISync protocol has some advantages compared to current techniques because it possesses a minimal code footprint, requires minimal data to be exchanged, has not much overhead associated with memory allocation and CPU, stores no unique time information, and has highly scalable steady-state condition and global clock error.
A technique to synchronize poor infrastructure sensor networks in severe environments was proposed in the literature [20,21]. The studies presented three novel asynchronous, decentralized, and energy-efficient time synchronization techniques that only require a single hop of sparse communication with unlabeled network nodes to determine the time of the gateway node. The time of a node in a discrete system can be observed as a changing factor whose growth is either inhibited or initiated asynchronously by a different dynamic switching process. The protocols are designated as Unidirectional Asynchronous Flooding (UAF), Bidirectional Asynchronous Flooding (UAF), and Timed Sequential Asynchronous Update (TSAU). After substantial modeling, the protocols are developed and tested on the MICAz sensor node platform. The energy usage of the suggested protocols, memory needs, convergence time, and local and global synchronization flaws are evaluated compared to Flooding Time Synchronization Protocol (FTSP) and FloodPISync. The findings suggested that the procedures outperform the well-known methods.
An Energy Efficiency Time Synchronization Protocol (EETS) for WSNs was presented in the literature [22]. This protocol was demonstrated to take advantage of the pairing of the Auto Regressive Moving Average (ARMA) model and the Kalman filter model in time series prediction, which can both address the shortcomings of the Kalman filter prediction and the low prediction accuracy of ARMA in complex environments. The validation results demonstrate energy efficiency for WSNs and validate the effectiveness of EETS, which was done by the authors using a prototype system. However, this protocol was not evaluated against existing protocols for real-time performance using parameters such as memory usage, synchronization precision, and convergence time.
In a newer study, the unique synchronization technique proposed in the literature [23] takes advantage of both the CP and DP architectures. The hybrid time synchronization protocol (HTSP) technique uses a temporary reference node to drastically shorten convergence times, while an average-based consensus is used in regular operations to handle node failures. The protocol is distributed, but each node is programmed to switch between the reference and consensus modes while in operation. Despite performing better than specific established protocols such as FTSP and GTSP, this protocol exhibited greater global synchronization error values. In addition, more real-time experimental work is required to verify enhanced synchronization accuracy and convergence time claims.
Abdul-Rashid et al. [24] presented a new time synchronization protocol for wireless sensor networks (WSNs). The authors addressed the challenges of achieving accurate synchronization in unstructured multi-hop networks by formulating the problem as an optimization task. They utilized the Butterfly Optimization Algorithm (BOA) to optimize clock parameters and achieve global synchronization across the network. The proposed protocol was experimentally evaluated against two existing protocols: the Newton Inspired Time Synchronization protocol and the Average Proportional Integral Synchronization protocol. Results indicated that the new protocol significantly outperformed these alternatives in terms of synchronization accuracy. The study highlighted the effectiveness of BOA in enhancing time synchronization in WSNs and suggested potential directions for future research in this area.
Recently, numerous attempts have been made to improve the convergence rate and synchronization error. The studies [25–27] utilized the concept of Packet-Coupled Oscillators (PkCOs). The Minimum Variance Time Synchronization (MVTS) algorithm in the literature [24] uses output feedback to reduce the noise on the accumulation of synchronization errors. Static feedback control using H
1.3 Distributed and Centralized Protocols
In general, DPs have a steady state value and are resilient and adaptable to changes in the network topology. They are also impacted by network propagation delays and noise, just as other protocols. Since surrounding nodes can communicate with one another to reach the consensus point based solely on the initial analysis, the protocols are distinguished by low-complexity repetitive procedures, eliminating the requirement to transfer information to a reference node. Conversely, CPs are typically simple to set up and consist mainly of pairwise synchronization followed by global network synchronization. The protocols do, however, have a number of shortcomings, including the substantial overhead associated with building the entire tree structure, which makes them unsuitable for use in networks with dynamic topologies and typically adds extra time and overhead. At the same time, another node is connected to the network, or a reference election is necessary.
In the literature [13], the protocol uses two dynamic control parameters called proportional and integral gains,
In more recent approaches like EETS [22], using Kalman Filters and the ARMA model will render the synchronization protocol ineffective in real-world WSN applications. Although Kalman filtering offers precise state estimation and noise reduction capabilities, its computational demands, sensitivity to model inaccuracies, scalability challenges, and implementation costs make it less suitable for clock synchronization. Simpler and more energy-efficient synchronization algorithms, such as gradient-based or distributed consensus algorithms, can be better alternatives for highly constrained or large-scale WSNs [30]. Also, the HTSP protocol [23] is expected to have a significant overhead due to the combined operations of the much older protocols of FTSP and Gradient Time Synchronization Protocol (GTSP), and hence its adaptivity to changes in network dynamics remains to be proven.
The proposed synchronization framework improves the methods in [28,29] with a more general and optimized approach. The proposed framework can trade off between WSN application requirements and the advantages of different stochastic algorithms for time synchronization.
This study outlines the following contribution:
1. A novel adaptive framework is proposed for WSN time synchronization that uses the advantages of different stochastic gradient algorithms for clock frequency adjustments.
2. Generalized conditions are derived for which any stochastic gradient-based synchronization algorithm will converge and closed-form asymptotic variance for synchronization precision comparisons between different stochastic gradient algorithms.
3. Design and implement a light-weight multi-hop time synchronization protocol based on the suggested framework.
4. Evaluate the proposed protocol using several stochastic gradient algorithms through real-time experiments and compare performances against AvgPISync.
The remainder of the paper is structured as follows: Section 2 covers the system concept; Section 3 presents the proposed clock synchronization architecture; Section 4 describes the convergence analysis of the proposed synchronization strategy; Section 5 explains the analytical performance of different stochastic gradient algorithms based on the suggested framework; Section 6 presents the experimental comparative evaluation of the synchronization protocols. Lastly, Section 7 concludes the paper.
Ordinary nodes dispersed throughout a comparatively small region or sensor field regularly send readings to a base or gateway node in a sparsely distributed WSN. Most base nodes possess many resources, in contrast with ordinary nodes with smaller power, communication rate, and memory. In addition, the gateway node in many WSNs is connected to a reliable and precise time reference, like a GPS receiver. For clarity in the presentation of the proposed framework, this study provides a glossary of terms and symbols used in Appendix A to improve readability and accessibility.
Fig. 1 indicates that all the other sensor nodes synchronize with the hardware clock of the gateway node
Figure 1: Time synchronization network concept in which nodes share neighboring clock data to synchronize their clocks to that of a gateway node,
A WSN with symmetric connections is assumed, which can be depicted as an undirected graph
In a Wireless Sensor Network (WSN), each node is furnished with a hardware clock, denoted as
where
where
2.3 Generalized Update of Clock Parameters
Because the clock parameters of a physical clock are incapable of being modified, every network node additionally retains a logical clock parameter that is a function of the present physical clock value,
Using the distributed network architecture shown in Fig. 1 as a basis, we may express this update rule as follows [31]: at a transmission moment,
As for the logical clock speed,
where
Figure 2: Suggested clock setup for node synchronization
Considering that
where
3 Proposed Framework for Clock Synchronization
In the proposed framework, Since the gateway clock,
where B is the resynchronization period of nodes. A linear dynamic update strategy may be derived from this mechanism, using a training set
Figure 3: Model framework for clock synchronization for the sake of illustration
Thus, an apparent comparability is found between the synchronization problem and the adaptive filter in Fig. 3. This comparability is shown by
where
The goal of the synchronization algorithm is to achieve in each pooling cycle, an optimal clock rate
The update of
where
4 Convergence and Steady State Analysis
The piece-wise form of the clock rate update in (12) can be written for some node
Considering that there is a delay in transmission and node
Then node
At the second packet reception time
Lemma 4.1.
4.1 Asymptotic Convergence and Steady-State in the Mean Sense
For simplicity, we assume
Combining (17) and (18) into a state representation yields (19).
Definition 4.1 (
Theorem 4.1. The update of the logical clock rate of a node
where
Proof of Theorem 4.1. To assess the pairwise convergence of the proposed generalized algorithm for clock synchronization in the mean-sense, we evaluate
For the technique to asymptotically converge in the mean-sense, a unit circle must contain the modes
Based on Theorem 4.1, our proposed system can converge to an asymptotically stable points of error and rate define as
Theorem 4.2. The evolving pairwise synchronization error,
Proof of Theorem 4.2. To assess the pairwise convergence of the proposed framework for clock synchronization in terms of the synchronization error and the clock rate, we utilize (17) and (18). Each algorithm used for the rate update aims to converge to a rate that achieves a zero synchronization error.
From (17), it can write the steady state error as follows:
and the asymptotic clock rate is given by
After some simple manipulations, then
Substituting (24) in (23) yields a steady-state error of
and let
Lemma 4.2. Consider a WSN whose nodes carry out time synchronization based on the model presented in Figs. 2, 3, and using a stochastic gradient algorithm of the form given by (13) for clock rate update. Time Synchronization will eventually be achieved with zero steady-state error,
The steady-error asymptotic variance must be as small as possible to maintain tight global synchronization among network nodes [32]. For any particular stochastic gradient algorithm, the value of
Theorem 4.3. The asymptotic variance in synchronization error of a stochastic gradient algorithm of the form given by (13) for clock rate update is given by
where
The proof of Theorem 4.3 is given in Appendix C. From the analysis of our generalized paradigm for clock synchronization, we observe that the steady-state values and the conditions are all independent of the propagation error.
Lemma 4.3. A node
5 Theoretical Performance of Stochastic-Gradient Algorithms
In this section, we extend the analysis of the proposed generalized paradigm for synchronization to study the convergence and steady state of node clock rate or frequency adjustment using the LMS algorithm, the Newton search algorithm, the GraDes algorithm, N-LMS algorithm, Sign-Error LMS and Sign-Data LMS. The following steps can be taken to undertake this analysis while choosing a particular stochastic gradient algorithm for clock rate update, the following steps can be taken:
1. Reconfigure the chosen stochastic gradient algorithm to fit the form of (13) and estimate a simplified form of the function
2. To obtain the range of values for which the clock frequency update will converge in the mean sense, find
3. To obtain the steady state values of the synchronization error,
4. Calculate and simplify
5.1 Gradient Descent (GraDes) Algorithm Inspired Time Synchronization
In the literature [28], the GraDes based time synchronization protocol is expressed as follows:
Therefore
For this algorithm to converge,
This condition is more accurate as compared to that presented in [28] which approximates
For the asymptotic variance, we compute
The lower-bound approximation is adopted for
Inserting these values in (26) and simplifying yields,
Lemma 5.1. The asymptotic error and clock rate for the GraDes algorithm used for clock rate update in synchronization for WSNs will reach zero steady-state,
5.2 Least Mean Square (LMS) Algorithm Inspired Time Synchronization
The instantaneous LMS algorithm can be adopted for the update of logical clock rate and hence, the update of clock parameters for this algorithm can be given as follows:
Hence,
For this algorithm to converge,
In addition, after some simple manipulations the variable
and
Inserting these values in (26) and simplifying yields,
Lemma 5.2. The asymptotic error and clock rate for the LMS algorithm used for clock rate update in time Synchronization for WSNs will eventually reach zero steady-state,
Proof of Lemma 5.2. Given
Since the clock frequency cannot be zero,
5.3 N-LMS and Newton Algorithm Based Time Synchronization
The equations of the time synchronization protocol inspired by the Newton algorithm are given by
The clock rate update in (38) is reminiscent of the N-LMS algorithm for a scalar parameter which can be given as follows:
Assuming an infinitesimal
The variable
Inserting these values in (26) and simplifying yields,
5.4 Sign-Data LMS Algorithm Inspired Time Synchronization
The Sign-Error LMS algorithm is a modified variant of the conventional LMS algorithm and can also be used to update the logical clock rate. In this algorithm, Instead of using
Since the the hardware clock is constantly ticking, we assume
From this formulation,
In addition, the variable
Inserting in (26) and simplifying yields,
5.5 Theoretical Comparison of Synchronization Algorithms
This section summarizes the theoretical differences and similarities between the LMS algorithm, the Newton search algorithm, the GraDes algorithm, the SignData-LMS algorithm, and the N-LMS algorithm for synchronization clock rate update. The yardstick for this exercise is based on the steady-state synchronization error and clock rate, the convergence time, the asymptotic error variance, and the order of algorithm complexity.
5.5.1 Steady-State Convergence
Using the steady-state values of synchronization error and the clock rate, three algorithms: the N-LMS, the Newton search, and the Sign-Data LMS are observed to converge to zero synchronization error and the nominal clock rate,
5.5.2 Asymptotic Error Variance
The asymptotic variance indicates the statistical distance between the steady-state synchronization error of each network node and the global average steady-state error. The degree of synchronization precision of a protocol, which is inversely proportional to the asymptotic variance, can be compared between protocols. From the generalized derived closed-form asymptotic variance of all protocols, we observe that the differences in each protocol’s variance lie in the third multiplicative factor,which we denote here as
It can be observed from (45) that the asymptotic variance,
The complexity of all the stochastic gradient-based algorithms, i.e., GraDes, LMS, N-LMS, Newton, and SignData-LMS, are similar. In the algorithms, for each node
5.6 Multi-Hop Synchronization with Generalized Protocol
Based on the pair-wise synchronization assessment, this section describes an extensive procedure for achieving time synchronization in WSNs. A generic protocol is devised that allows any node to achieve local synchronization and by extension, allows network-wide synchronization. The gateway node, G, and its associated timestamp,
After clearing its stored data and determining
The node updates of
6 Experimental Results and Discussion
This study implemented the proposed generalized protocol configured with five (5) stochastic algorithms, GraDes, LMS, N-LMS, Newton, SignData-LMS and also AvgPISync [13] for a MICAz WSN platform using TinyOS operating system. Based on our evaluation of recent protocols, even though there are newer alternatives, AvgPISync stands out as a high-performing adaptive and distributed protocol with proven practical implementation results. Therefore, it is an excellent candidate for comparison with newly developed protocols.
The experimental test-bed utilizes MICAz nodes from Memsic, which are built around a 7.37 MHz 8-bit Atmel Atmega128L microcontroller. The nodes are equipped with 4 kB of RAM, 128 kB of program flash, and a Chipcon CC2420 radio chip, capable of transmitting data at a rate of 250 kbps at a frequency of 2.4 GHz. The 7.37 MHz quartz oscillator on the MICAz board serves as the clock source for the timer used for timing measurements. Since the timer operates at one-eighth of the oscillator frequency, each timer tick occurs approximately every 921 kHz (approximately 1
TinyOS-2.1.2, installed on the Ubuntu Linux Distribution, is used as the base operating system for all experimental work. The MICAz board’s CC2420 transceiver timestamps synchronization packets at the MAC layer using the timing measurement timer [21]. Although the motes are a bit old-fashioned, they have the same architecture as most of the recent motes and are still used by several contemporary researchers [33–35] for WSN protocol design. Also, the proposed adaptive algorithms are hardware-neutral, as they primarily target algorithmic convergence and synchronization precision and are expected to perform better on more recent devices. Additionally, the higher clock rates and lower energy consumption in contemporary devices could further enhance the performance of our framework.
The test-bed layout used for our experiments is based on a grid and line topology of 16 nodes, as shown in Fig. 4, with a diameter of 8 between nodes. The grid topology allows us to evaluate the performances of protocols on a dense network, and the line topology is employed to study protocol performances on a sparse network and the effects of the shape of networks on synchronization accuracy and convergence. Each testbed is configured such that one node acts as the gateway node and the others as ordinary nodes, which are programmed independently with the synchronization protocol. A specialized node configured to act as the base station or sink is connected to a PC and gathers all time-sync packets onto a computer for analysis. In our experiments, a beacon period B of 30 s was used for all protocols. The experimental parameters for AvgPISync,
Figure 4: Layout of WSN Testbed for Experiments
6.2 Logical Clock and Frequency (Rate)
This study needs to examine the clock value discrepancies among the network nodes to assess the synchronization accuracy of each protocol. It achieves this by gathering the clock values of all nodes at each communication instant
Figure 5: Average global logical clock,
All protocols are observed to converge approximately to the nominal frequency of
6.3 Criteria for Synchronization Accuracy
The error between the logical clocks of arbitrary nodes,
Network-wide synchronization accuracy at each communication instant is then calculated using maximum global synchronization error,
The synchronization accuracy between any two network nodes can be assessed using the global synchronization error,
The study then computes the global error’s mean, standard deviation, and maximum statistics as key indicators of each protocol’s robustness and ability to perform in grid and line topologies. The mean error reflects the overall accuracy of the synchronization, and the standard deviation indicates the variability of the synchronization between nodes, and the maximum error highlights the worst-case performance. Consistent results across both topologies suggest that the protocol is not overfitted to specific test cases but instead demonstrates some level of adaptability and reliability. The study validates a protocol’s resilience to structural topology changes by analyzing these metrics collectively. These metrics also provide a foundation for future validation in broader real-world applications.
6.4 Experimental Results on Grid
The experimental results on the grid network for
Figure 6: Global and local synchronization-error on the
In addition to the error curves, an error distribution histogram and kernel density estimation (KDE) for the probability density function (PDF) of
Figure 7: The (a) probability density and (b) normalized distribution histogram of the global synchronization-error,
For WSN applications on dense networks requiring rapid convergence, it might be best to consider the N-LMS-based protocol for logical clock frequency adjustments. If synchronization accuracy or precision is rather paramount with tolerable slower convergence, then it is best to use Sign-Data LMS for the frequency update. For balanced accuracy and convergence time requirements, the GraDes or Newton search algorithms can be employed, although the LMS algorithm will also perform in such a case.
6.5 Experimental Results on Line Topology
The experimental results on the line network for
Figure 8: Global and local synchronization-error on the line network
Figure 9: The (a) probability density and (b) normalized distribution histogram of the global synchronization-error,
Therefore, in selecting the optimal algorithm for logical clock frequency adjustments, for WSN applications where sparse or simple type network architectures are used, if accuracy and precision are paramount over fast convergence, Sign-Data LMS is recommended; otherwise, if fast convergence is the priority, then the Newton search algorithm is preferred. For a more balanced performance, N-LMS or GraDes are recommended. A summary of the mean, STD, maximum, and convergence time of the global error of all tested protocols is shown in Table 5.
6.5.1 Implications of Protocol Performance on WSN Reliability and Efficiency
The proposed synchronization protocol enhances the reliability and efficiency of WSNs in several helpful ways:
1. The protocol helps conserve energy, which is critical for sensor nodes operating on limited battery power, by reducing the number of resynchronization events and unnecessary communication.
2. The protocol’s high synchronization accuracy can ensure that data from different nodes is well-aligned in time, resulting in more consistent and dependable measurements of nodes.
3. The adaptive design of the protocol can lead to nodes adapting dynamically to harsh conditions like interference and packet loss, maintaining performance even in unpredictable environments.
4. Scalability and Stability: The flexibility in protocol design is expected to allow it to scale smoothly with larger networks or changing topologies. This is also shown in the protocol performance on the line topology.
These conclusions are drawn from theoretical analyses and the limited experimental tests conducted in this study. Although the initial results are promising, further extensive experimental testing across a broader range of real-world scenarios is necessary to validate these claims and assess the protocol’s broader applicability and effectiveness.
This study presents an adaptive method of time synchronization for WSNs inspired by a generalized class of stochastic gradient algorithms. It develops a generalized framework for time synchronization in unstructured WSNs that allows for a trade-off between synchronization accuracy, precision, and convergence time by selecting different gradient algorithms for logical clock frequency adjustments. The generalized conditions for pairwise convergence are derived in the mean-sense, steady-state error, and clock rates. Then, synchronization precision is analyzed using closed-form relations for each proposed proto-col. The LMS, GraDes, N-LMS, Newton-search, and Sign-Data LMS algorithms are analyzed using this generalized framework. All protocols achieve zero steady-state synchronization error with high synchronization precision. A generalized protocol is developed for multi-hop synchronization and implemented on real-time WSNs. Experimental results from the protocol for some algorithms show that it outperforms the AvgPISync protocol in terms of synchronization accuracy, precision, and convergence time. Despite promising results, the proposed framework has limitations, including assumptions of stationary nodes and ideal noise conditions, which cannot be applied in real-world, dynamic environments. The framework also lacks optimization for energy efficiency, a critical factor for large-scale WSNs. Future work can involve incorporating affine stochastic algorithms for improved performance, optimizing the protocols for joint synchronization accuracy and energy efficiency, and implementing them in networks with non-stationary nodes. Additionally, addressing scalability in larger, dynamic networks while maintaining synchronization accuracy will be an important challenge.
Acknowledgement: The authors acknowledge the Department of Physics, Universiti Putra Malaysia, for providing facilities and funding for the present study.
Funding Statement: This research was funded by Universiti Putra Malaysia under a Geran Putra Inisiatif (GPI) research grant with reference to GP-GPI/2023/9762100.
Author Contributions: The authors confirm their contribution to the paper as follows: study conception, protocol design, and implementation: Ramadan Abdul-Rashid, Mohd Amiruddin Abd Rahman; data collection: Ramadan Abdul-Rashid; analysis and interpretation of results: Ramadan Abdul-Rashid, Mohd Amiruddin Abd Rahman, Kar Tim Chan, Arun Kumar Sangaiah; draft manuscript preparation: Ramadan Abdul-Rashid, Mohd Amiruddin Abd Rahman. All authors reviewed the results and approved the final version of the manuscript.
Availability of Data and Materials: The data that support the findings of this study are available from the corresponding author upon reasonable request.
Ethics Approval: Not applicable.
Conflicts of Interest: The authors declare no conflicts of interest to report regarding the present study.
Appendix A. Symbol Definitions
Appendix B. Reconfiguration of Stochastic Gradient Algorithms Based on Generalized Framework
The pairwise logical clock error when node
GraDes Algorithm
The gradient function is derived as follows:
LMS Algorithm The general update equation for LMS can be given as
Using the orthogonality principle and simplifying,
Since we are dealing with the instantaneous values, we adopt the approximations:
Hence
Newton Search Algorithm
where
Using (4), we derive
Since
Since
N-LMS Algorithm
Similar to the Newton search algorithm,
Appendix C. Asymptotic Variance for Generalized Algorithm
To prove Theorem 4.3, let
where
Based on these definitions, we can rewrite the error and clock rate recursion equations respectively as
Let
Since
Taking the expectation of both sides,
Limiting
For stochastic gradient algorithms, assuming,
then
Since
Using straight-forward steps, the asymptotic variance of the error can be given as
Let
1 where Ts is the upper bound on the variance in the convergence time of all network nodes, presuming that clock inputs from 1-hop neighbors are received quickly. Node i calculates the average local error, enew, during this period after expecting to receive values from all nearest neighbors.
References
1. Quattrocchi C, Furnari A, Di Mauro D, Giuffrida MV, Farinella GM. Synchronization is all you need: exocentric-to-egocentric transfer for temporal action segmentation with unlabeled synchronized video pairs. In: European Conference on Computer Vision; 2024; MiCo Milano, Italy: Springer. p. 253–70. [Google Scholar]
2. Fu S, Wu J, Zhang Q, Xie B. Robust and efficient synchronization for structural health monitoring data with arbitrary time lags. Eng Struct. 2025;322(1):119183. doi:10.1016/j.engstruct.2024.119183. [Google Scholar] [CrossRef]
3. Weng Y, Zhang Y. A survey of secure time synchronization. Appl Sci. 2023;13(6):3923. doi:10.3390/app13063923. [Google Scholar] [CrossRef]
4. Shi F, Yang SX, Tuo X, Ran L, Huang Y. A novel rapid flooding approach with real-time delay compensation for wireless-sensor network time synchronization. IEEE Transact Cybernet. 2022;52(3):1415–28. doi:10.1109/TCYB.2020.2987758. [Google Scholar] [PubMed] [CrossRef]
5. Jia XD, Cui D, Hu Y. Asynchronous broadcast-based event triggered control for discrete-time clock synchronization. IET Cont Theo Appl. 2023;17(11):1543–51. doi:10.1049/cth2.12488. [Google Scholar] [CrossRef]
6. Huan X, He H, Wang T, Wu Q, Hu H. A timestamp-free time synchronization scheme based on reverse asymmetric framework for practical resource-constrained wireless sensor networks. IEEE Transact Communs. 2022;70(9):6109–21. doi:10.1109/TCOMM.2022.3188830. [Google Scholar] [CrossRef]
7. Huan X, Chen W, Wang T, Hu H, Zheng Y. A one-way time synchronization scheme for practical energy-efficient LoRA network based on reverse asymmetric framework. IEEE Transact Commun. 2023;71(11):6468–81. doi:10.1109/TCOMM.2023.3305515. [Google Scholar] [CrossRef]
8. Zong Y, Dai X, Gao S, Canyelles-Pericas P, Liu S. PkCOs: synchronization of packet-coupled oscillators in blast wave monitoring networks. IEEE Internet Things J. 2022;9(13):10862–71. doi:10.1109/JIOT.2021.3126059. [Google Scholar] [CrossRef]
9. Maróti M, Kusy B, Simon G, Lédeczi A. The flooding time synchronization protocol. In: Proceedings of the 2nd International Conference on Embedded Networked Sensor Systems. SenSys ’04; 2004; New York, NY, USA: Association for Computing Machinery; p. 39–49. [Google Scholar]
10. Chen J, Yu Q, Zhang Y, Chen HH, Sun Y. Feedback-Based clock synchronization in wireless sensor networks: a control theoretic approach. IEEE Transact Veh Technol. 2010;59(6):2963–73. doi:10.1109/TVT.2010.2049869. [Google Scholar] [CrossRef]
11. Yıldırım KS, Kantarci A. Time synchronization based on slow-flooding in wireless sensor networks. IEEE Transact Parall Distrib Syst. 2014;25(1):244–53. doi:10.1109/TPDS.2013.40. [Google Scholar] [CrossRef]
12. Lenzen C, Sommer P, Wattenhofer R. PulseSync: an efficient and scalable clock synchronization protocol. IEEE/ACM Trans Netw. 2015;23(3):717–27. doi:10.1109/TNET.2014.2309805. [Google Scholar] [CrossRef]
13. Yıldırım KS, Carli R, Schenato L. Adaptive proportional-integral clock synchronization in wireless sensor networks. IEEE Transact Cont Syst Technol. 2018;26(2):610–23. doi:10.1109/TCST.2017.2692720. [Google Scholar] [CrossRef]
14. Lee YR, Chin WL. Low-complexity time synchronization for energy-constrained wireless sensor networks: dual-clock delayed-message approach. Peer Peer Netw Appl. 2017;10(4):887–96. doi:10.1007/s12083-016-0437-4. [Google Scholar] [CrossRef]
15. Apicharttrisorn K, Choochaisri S, Intanagonwiwat C. Energy-efficient gradient time synchronization for wireless sensor networks. In: 2010 2nd International Conference on Computational Intelligence, Communication Systems and Networks; 2010; Liverpool, UK. p. 124–9. [Google Scholar]
16. Schenato L, Fiorentin F. Average TimeSynch: a consensus-based protocol for clock synchronization in wireless sensor networks. Automatica. 2011;47(9):1878–86. doi:10.1016/j.automatica.2011.06.012. [Google Scholar] [CrossRef]
17. Maggs M, O’Keefe S, Thiel D. Consensus clock synchronization for wireless sensor networks. IEEE Sens J. 2012;12(6):2269–77. doi:10.1109/JSEN.2011.2182045. [Google Scholar] [CrossRef]
18. He J, Cheng P, Shi L, Chen J, Sun Y. Time synchronization in WSNs: a maximum-value-based consensus approach. IEEE Transact Automat Cont. 2014;59(3):660–75. doi:10.1109/TAC.2013.2286893. [Google Scholar] [CrossRef]
19. Wu J, Zhang L, Bai Y, Sun Y. Cluster-based consensus time synchronization for wireless sensor networks. IEEE Sens J. 2015;15(3):1404–13. doi:10.1109/JSEN.2014.2363471. [Google Scholar] [CrossRef]
20. Abdul-Rashid R, Al-Shaikhi A, Masoud A. Accurate, energy-efficient, decentralized, single-hop, asynchronous time synchronization protocols for wireless sensor networks. arXiv:1811.01152. 2018. [Google Scholar]
21. Al-Shaikhi A, Abdul-Rashid R, Masoud A. Asynchronous time synchronization protocol for WSNs. In: 2019 16th International Multi-Conference on Systems, Signals & Devices (SSD); 2019; Istanbul, Turkey. p. 518–23. [Google Scholar]
22. Wang F, Wu X, Liu Z. Energy efficiency time synchronization protocol for wireless sensor networks. In: 2021 40th Chinese Control Conference (CCC); 2021; Shanghai, China. p. 5649–54. [Google Scholar]
23. Phan LA, Kim T. Hybrid time synchronization protocol for large-scale wireless sensor networks. J King Saud Univ-Comput Inf Sci. 2022;34(10):10423–33. [Google Scholar]
24. Abdul-Rashid R, Abd Rahman MA. An adaptive procedure of time synchronization in unstructured multi-hop wireless sensor networks using butterfly optimization algorithm. J Phy: Conf Ser. 2024;2891:162026. doi:10.1088/1742-6596/2891/16/162026. [Google Scholar] [CrossRef]
25. Jia Z, Cui D, Dai X, Liu ZW, Liu S, Chai T. Low overhead minimum variance time synchronization for time-sensitive wireless sensor networks. IEEE Trans Autom Sci Eng. 2024;1–11. doi:10.1109/TASE.2024.3419142. [Google Scholar] [CrossRef]
26. Zong Y, Liu S, Liu X, Gao S, Dai X, Gao Z. Robust synchronized data acquisition for biometric authentication. IEEE Transacti Indust Inform. 2022;18(12):9072–82. doi:10.1109/TII.2022.3182326. [Google Scholar] [CrossRef]
27. Zong Y, Dai X, Wei Z, Zou M, Guo W, Gao Z. Robust time synchronization for industrial internet of things by h∞ output feedback control. IEEE Inter Things J. 2023;10(3):2021–30. doi:10.1109/JIOT.2022.3144199. [Google Scholar] [CrossRef]
28. Yıldırım KS. Gradient descent algorithm inspired adaptive time synchronization in wireless sensor networks. IEEE Sens J. 2016;16(13):5463–70. doi:10.1109/JSEN.2016.2555996. [Google Scholar] [CrossRef]
29. Abdul-Rashid R, Zerguine A. Time synchronization in wireless sensor networks based on newton’s adaptive algorithm. In: 2018 52nd Asilomar Conference on Signals, Systems, and Computers; 2018; Pacific Grove, CA, USA. p. 1784–8. [Google Scholar]
30. Butusov D, Rybin V, Karimov A. Fast time-reversible synchronization of chaotic systems. Phys Rev E. 2025;111(1):014213. doi:10.1103/PhysRevE.111.014213. [Google Scholar] [PubMed] [CrossRef]
31. Wei C, Wang X, Ren F, Zeng Z. Local and global finite-time synchronization of fractional-order complex dynamical networks via hybrid impulsive control. IEEE Transact Syst Man Cybernet: Syst. 2025;99:1–10. doi:10.1109/TSMC.2024.3520135. [Google Scholar] [CrossRef]
32. Hu T, Park JH, Liu X, He Z, Zhong S. Sampled-data-based event-triggered synchronization strategy for fractional and impulsive complex networks with switching topologies and time-varying delay. IEEE Transact Syst Man Cybernet: Syst. 2021;52(6):3568–80. doi:10.1109/TSMC.2021.3071811. [Google Scholar] [CrossRef]
33. Resmi NC, Chouhan S. An enhanced methodology for energy-efficient interdependent source-channel coding for wireless sensor networks. IEEE Transact Green Commun Network. 2020;4(4):1072–80. doi:10.1109/TGCN.2020.3008079. [Google Scholar] [CrossRef]
34. Gao D, Zhang S, Zhang F, He T, Zhang J. RowBee: a routing protocol based on cross-technology communication for energy-harvesting wireless sensor networks. IEEE Access. 2019;7:40663–73. doi:10.1109/ACCESS.2019.2902902. [Google Scholar] [CrossRef]
35. Aman MN, Basheer MH, Sikdar B. Two-factor authentication for IoT with location information. IEEE Inter Things J. 2019;6(2):3335–51. doi:10.1109/JIOT.2018.2882610. [Google Scholar] [CrossRef]
Cite This Article

This work is licensed under a Creative Commons Attribution 4.0 International License , which permits unrestricted use, distribution, and reproduction in any medium, provided the original work is properly cited.