Frequency Offset Estimation Method For Average Consistency Clock Synchronization

20220369258 · 2022-11-17

Assignee

Inventors

Cpc classification

International classification

Abstract

The present invention relates to a frequency offset estimation method for average consensus-based clock synchronization, and belongs to the technical field of wireless sensor networks. According to the method, in combination with distributed one-way broadcast characteristics, solving of maximum likelihood estimation is converted into a linear optimization problem, and a relative frequency offset estimation value is obtained by adopting an iterative method. By applying the estimation value to the compensation of logic clock parameter between nodes, an effect of keeping logic clocks of network nodes consistent can be achieved. According to the present invention, distribution characteristics of communication time delay are fully considered, accurate relative frequency offset estimation can be implemented, so the synchronization precision of average consensus-based clock synchronization is effectively improved, the maximum likelihood estimation solving is performed by adopting the iterative method, an estimation algorithm is simplified, and storage overhead is reduced.

Claims

1. A frequency offset estimation method for average consensus-based clock synchronization, specifically comprising following steps: S1: assuming that each node i in a network periodically broadcasts a local clock message τ.sub.i(t.sub.l.sup.i), receiving, by a neighbor node j thereof, the clock message, recording a current local clock τ.sub.j(t.sub.l.sup.id) of the neighbor node, so the neighbor node establishes a relative clock relationship according to known local clock information and time delay:
τ.sub.j(t.sub.l.sup.id)=ω.sub.ijτ.sub.i(t.sub.l.sup.i)+φ.sub.ij+d.sub.ij.sup.f+d.sub.ij.sup.r(t.sub.l.sup.i) where ω.sub.ij and φ.sub.ij respectively represent a relative frequency offset and a relative phase offset of the node i with respect to the node j, d.sub.ij.sup.r(t.sub.l.sup.i) represents random communication time delay satisfying truncated exponential distribution of which an average value is λ and an upper limit is D; d.sub.ij.sup.f represents fixed time delay existing in a data packet transmission process; S2: performing relative frequency offset estimation according to the relative clock relationship after the neighbor node j receives synchronization messages each cycle, wherein when the node j receives L synchronization messages from the node i, the relative frequency offset ω.sub.ij between nodes is estimated using a maximum likelihood estimation method: max z = arg max ω ij , θ ij exp ( L θ ij + ω ij .Math. l = 1 L τ i ( t l i ) ) , { 0 < τ j ( t 1 id ) - θ ij - ω ij τ i ( t 1 i ) D 0 < τ j ( t 2 id ) - θ ij - ω ij τ i ( t 2 i ) D M 0 < τ j ( t L id ) - θ ij - ω ij τ i ( t L i ) D where θ.sub.ij=φ.sub.ij+d.sub.ij.sup.f.

2. The frequency offset estimation method for average consensus-based clock synchronization according to claim 1, characterized in that: in step S2, nodes in the network periodically broadcast clock synchronization messages, a number of local clocks of the broadcast nodes is an integral multiple of a broadcast cycle T so solving of the relative frequency offset ω.sub.ij under maximum likelihood estimation is converted into a linear optimization problem: max z = θ ij + L + 1 2 T ω ij , { 0 < τ j ( t 1 id ) - θ ij - T ω ij D 0 < τ j ( t 2 id ) - θ ij - 2 T ω ij D M 0 < τ j ( t L id ) - θ ij - LT ω ij D .

3. The frequency offset estimation method for average consensus-based clock synchronization according to claim 2, characterized in that: the estimation problem solving of the relative frequency offset under the maximum likelihood estimation method is simplified to a linear objective function with linear constraints, a feasible region of the objective function is a common region under constraint line ω.sub.ij=(τ.sub.j(t.sub.l.sup.id)−θ.sub.ij)/lT and above constraint line ω.sub.ij=(τ.sub.j(t.sub.l.sup.id)−D−θ.sub.ij)/lT, the two cluster of constraint lines being formed according to a truncated boundary of time delay, an optimal value is located on a vertex of a feasible region boundary; by comparing intersection points of the constraint lines, only information of vertexes on the boundary is stored using an iterative method so as to reduce storage overhead, specifically including following steps: S21: calculating an upper boundary B1 of the feasible region and vertexes thereof; assuming that an upper boundary of the feasible region surrounded by L constraint lines ω.sub.ij=(τ.sub.j(t.sub.l.sup.id)−θ.sub.ij)/lT has P vertexes, when the node j receives a (L+1).sup.th synchronization packet from i, generating a new constraint line ω.sub.ij=(τ.sub.j(t.sub.L+1.sup.id)−θ.sub.ij)/(L+1)T, comparing the new constraint line with the P vertexes on the original boundary B1, obtaining new upper boundary vertexes; S22: calculating a lower boundary B2 of the feasible region and vertexes thereof, similar to S21, when the node j receives a (L+1).sup.th synchronization packet from i, generating a new constraint line ω.sub.ij=(τ.sub.j(t.sub.L+1.sup.id)−D−θ.sub.ij)/(L+1)T, comparing the new constraint line with the Q vertexes on the original lower boundary B2, obtaining new lower boundary vertexes; S23: comparing the upper boundary vertexes with the lower boundary vertexes, obtaining available boundary vertexes, and new B1, B2 corresponding thereto, and substituting values of the boundary vertexes into an objective function z, so ω.sub.ij corresponding to a vertex in the case where the objective function z is maximum is a relative frequency offset value under iterative maximum likelihood estimation.

4. The frequency offset estimation method for average consensus-based clock synchronization according to claim 3, characterized in that: in step S21, obtaining new upper boundary vertexes specifically comprises: first, checking whether - θ ij τ i ( t L i ) + τ j ( t L j ) τ i ( t L i ) < ω ij _ 1 u is true when θ.sub.ij=θ.sub.ij_min, where θ.sub.ij_min represents a priori minimum value of θ.sub.ij; if not, ignoring new constraint line; if so, checking whether - θ ij τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) < ω ij _ p u is true when p=2, L P, θ.sub.ij=θ.sub.ij_p.sup.u, where θ.sub.ij_p.sup.u and ω.sub.ij_p.sup.u respectively represent abscissa and ordinate values of a p.sup.th vertex of the upper boundary B1; if all cases are true, constructing a new boundary B1 by the new constraint line, boundary vertexes being c 1 u = ( θ ij _ min , - θ ij _ min τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ) , c 2 u = ( θ ij _ max - θ ij _ max τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ) ; If - θ ij _ p u τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) < ω ij _ p u is not true when p≥custom-character, the new constraint line intersects a connecting line between a (custom-character−1).sup.th vertex and a custom-character.sup.th vertex of the original boundary B1, coordinates (θ.sub.ij_x.sup.u,ω.sub.ij_x.sup.u) of an intersection point satisfying: { ω ij _ x u = θ ij _ x u - θ ? θ ? - θ ? ( ω ? - ω ? ) + ω ? ω ij _ x u = - θ ij _ x u τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ; ? indicates text missing or illegible when filed the new boundary B1 has P−custom-character+3 vertexes, where c 1 u = ( θ ij _ min , - θ ij _ min τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ) , c 2 u = ( θ ij _ x u , ω ij _ x u ) replace the first custom-character−1 vertexes of the original boundary B1.

Description

DESCRIPTION OF THE DRAWINGS

[0024] To enable the purpose, the technical solution and the advantages of the present invention to be more clear, the present invention will be preferably described in detail below in combination with the drawings, wherein:

[0025] FIG. 1 is a diagram showing a communication topology of a fully distributed network;

[0026] FIG. 2 is a schematic diagram of a synchronization clock information exchange mechanism between nodes;

[0027] FIG. 3 is a schematic diagram showing linear programming of the frequency offset estimation method of the present invention;

[0028] FIG. 4 is a flow chart of the frequency offset estimation method of the present invention.

DETAILED DESCRIPTION OF THE INVENTION

[0029] Embodiments of the present invention are described below through specific embodiments. Those skilled in the art can understand other advantages and effects of the present invention easily through the disclosure of the description. The present invention can also be implemented or applied through additional different specific embodiments. All details in the description can be modified or changed based on different perspectives and applications without departing from the spirit of the present invention. It should be noted that the figures provided in the following embodiments only exemplarily explain the basic conception of the present invention, and if there is no conflict, the following embodiments and the features in the embodiments can be mutually combined.

[0030] Referring to FIGS. 1-4, FIG. 1 is a diagram showing a communication topology of a distributed network used in the present invention. As shown in FIG. 1, nodes are randomly distributed in a network, wherein each node broadcasts local clock messages thereof and receives information about other nodes within a communication range thereof. A communication exchange topology of the wireless sensor network may be modeled as a strongly connected graph G=(N,E), where N={1, 2, L, n} represents a set of nodes in the network, E represents a set of reliable communication links, for example, (i,j)∈E represents that a node j can successfully receive information from a node i. A neighbor node of the node i is represented as N.sub.i={j∈N:(i,j)∈E}.

[0031] A synchronization clock information exchange mechanism between nodes is shown in FIG. 2, taking two nodes as an example, the node i broadcasts local clock information τ.sub.i(t.sub.l.sup.i) over a cycle T, the neighbor node j of the node receives clock messages and records a current local clock τ.sub.i(t.sub.l.sup.id) thereof. The neighbor node establishes a relative clock relationship according to known local clock information and time delay due to influence of fixed time delay d.sub.ij.sup.f and random time delay d.sub.ij.sup.r(t.sub.l.sup.i) existing in a data packet transmission process,


τ.sub.j(t.sub.l.sup.id)=ω.sub.ijτ.sub.i(t.sub.l.sup.i)+ω.sub.ij+d.sub.ij.sup.f+d.sub.ij.sup.r(t.sub.l.sup.i)

where ω.sub.ij and φ.sub.ij respectively represent a relative frequency offset and a relative phase offset of the node i with respect to node j, d.sub.ij.sup.r represents communication time delay satisfying truncated exponential distribution.

[0032] After receiving synchronization messages, according to the relative clock relationship, the neighbor node j obtains:


d.sub.ij.sup.r(t.sub.l.sup.i)=τ.sub.j(t.sub.l.sup.id)−ω.sub.ijτ.sub.i(t.sub.l.sup.i)−φ.sub.ij−d.sub.ij.sup.f  (1)

When the node j receives L synchronization messages from the node i, because the random delay are mutually independent truncated exponential distribution variables, a joint probability density function of the random time delay d.sub.ij.sup.r is:

[00008] f d ( d ij r ) = .Math. l = 1 L λ exp ( - λ d ij r ( t l i ) ) 1 - exp ( - λ D ) , { 0 d ij r ( t 1 i ) D 0 d ij r ( t 2 i ) D M 0 d ij r ( t L i ) D ( 2 )

[0033] (1) is substituted into (2), obtaining a likelihood function with respect to the known local clocks and the parameters to be estimated:

[00009] f τ j ( τ j ) = λ L ( 1 - exp ( - λ D ) ) L exp ( - λ ( .Math. l = 1 L τ j ( t l id ) - L θ ij - ω ij .Math. l = 1 L τ i ( t l i ) ) ) { 0 < τ j ( t 1 id ) - θ ij - ω ij τ i ( t 1 i ) D 0 < τ j ( t 2 id ) - θ ij - ω ij τ i ( t 2 i ) D M 0 < τ j ( t L id ) - θ ij - ω ij τ i ( t L i ) D ( 3 )

where θ.sub.ij=φ.sub.ij+d.sub.ij.sup.f. The maximum likelihood estimation is to find parameters under the condition of satisfying the constraints so that equation (3) is maximized, that is,

[00010] exp ( - λ ( .Math. l = 1 L τ j ( t l id ) - L θ ij - ω ij .Math. l = 1 L τ i ( t l i ) ) )

is maximized. Under the maximum likelihood estimation method, the relative frequency offset ω.sub.ij between nodes is:

[00011] ω ˆ ij = arg max ω ij , θ ij exp ( L θ ij + ω ij .Math. l = 1 L τ i ( t l i ) ) , ( 4 ) { 0 τ j ( t 1 id ) - θ ij - ω ij τ i ( t 1 i ) D 0 τ j ( t 2 id ) - θ ij - ω ij τ i ( t 2 i ) D M 0 τ j ( t L id ) - θ ij - ω ij τ i ( t L i ) D

[0034] Nodes periodically broadcast clock synchronization messages, so a number of local clocks of the broadcast nodes is an integral multiple of a broadcast cycle T, i.e. τ.sub.i(t.sub.l.sup.i)=lT. Thus, solving of the relative frequency offset ω.sub.ij under maximum likelihood estimation may be converted into an optimization problem:

[00012] max z = θ ij + L + 1 2 T ω ij , ( 5 ) { 0 < τ j ( t 1 id ) - θ ij - T ω ij D 0 < τ j ( t 2 id ) - θ ij - 2 T ω ij D M 0 < τ j ( t L id ) - θ ij - LT ω ij D

[0035] The estimation problem of the relative frequency offset under the maximum likelihood estimation method is a maximum value problem of a linear objective function with linear constraints, a feasible region of the objective function is a common region under constraint lines ω.sub.ij=(τ.sub.j(t.sub.l.sup.id)−θ.sub.ij)/lT and above constraint lines ω.sub.ij=(τ.sub.j (t.sub.l.sup.id)−D−θ.sub.ij)/lT. Therefore, with the increase of the number of synchronization information packets, the number of constraint lines is increased, and more information is required to be stored by the neighbor node. However, as shown in FIG. 3, not every constraint line is useful for constructing the feasible region, so there is a need to construct an efficient algorithm to simplify estimation solving and reduce storage overhead. Because this is a linear objective function with linear constraints, an optimal value must be located at a vertex of a boundary of the feasible region. Thus, by comparing intersection points of the constraint lines, only information of vertexes on the boundary is stored using an iterative method so as to reduce storage overhead, specifically including following steps:

[0036] Step 1: Discussing an upper boundary B1 of the feasible region and vertexes thereof; assuming that an upper boundary of the feasible region surrounded by L constraint lines ω.sub.ij=(τ.sub.j(t.sub.l.sup.id)−θ.sub.ij)/lT has P vertexes, when the node j receives a (L+1).sup.th synchronization packet from i, generating a new constraint line ω.sub.ij=(τ.sub.j(t.sub.L+1.sup.id)−θ.sub.ij)/(L+1)T. First, checking whether

[00013] - θ ij τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) < ω ij _ 1 u

is true when θ.sub.ij=θ.sub.ij_min. If not, ignoring this constraint line, because the feasible region is located below all constraint lines

[00014] ω ij = - θ ij τ i ( t l i ) + τ j ( t l id ) τ i ( t l i )

and an absolute value of a slope of the new constraint line is smaller and smaller, if so, checking whether

[00015] - θ ij τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) < ω ij _ p u

is true when p=2, L P, θ.sub.ij=θ.sub.ij_p.sup.u. If all cases are true, constructing a new boundary B1 by the new constraint line, boundary vertexes being

[00016] c 1 u = ( θ ij _ min , - θ ij _ min τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ) , c 2 u = ( θ ij _ max - θ ij _ max τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ) . If - θ ij _ p u τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) < ω ij _ p u

is not true when p≥custom-character, the new constraint line intersects a connecting line between a (custom-character−1).sup.th vertex and a custom-character.sup.th vertex of the original boundary B1, coordinates (θ.sub.ij_x.sup.u,ω.sub.ij_x.sup.u) of an intersection point satisfying:

[00017] { ω ij _ x u = θ ij _ x u - θ ? θ ? - θ ? ( ω ? - ω ? ) + ω ? θ ij _ x u = - θ ij _ x u τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ? indicates text missing or illegible when filed

the new boundary B1 has P−custom-character++3 vertexes, where

[00018] c 1 u = ( θ ij _ min , - θ ij _ min τ i ( t L i ) + τ j ( t L id ) τ i ( t L i ) ) , c 2 u = ( θ ij _ x u , ω ij _ x u )

replace the first custom-character−1 vertexes of the original boundary B1.

[0037] S22: Discussing a lower boundary B2 of the feasible region and vertexes thereof, similar to Step 1, when the node j receives a (L+1).sup.th synchronization packet from i, generating a new constraint line ω.sub.ij=(τ.sub.j(t.sub.L+1.sup.id)−D−θ.sub.ij)/(L+1)T, comparing the new constraint line with the Q vertexes on the original lower boundary B2, obtaining new lower boundary vertexes.

[0038] Step 3: forming a boundary of the feasible region by a common region between the boundary B1 and the boundary B2, comparing vertexes on B1 with vertexes on B2 in combination with a relative position relationship between B1 and B2, obtaining available boundary vertexes.

[0039] After analyzing all influence of the new constraint line on the feasible region and obtaining the new boundary vertexes of the feasible region, coordinate values of the new boundary vertexes are substituted into an objective function z=θ.sub.ij+(L+1)Tω.sub.ij/2, so ω.sub.ij corresponding to a vertex in the case where z is maximum is a relative frequency offset value under iterative maximum likelihood estimation. The estimated relative frequency offset may be used in subsequent logic clock compensation.

Embodiments

[0040] FIG. 4 is a flow chart of the frequency offset estimation method for average consensus-based clock synchronization of the present invention. This embodiment provides a maximum likelihood estimation-based relative frequency offset estimation method for average consensus-based synchronization, as shown in the figure, specifically comprising following steps:

[0041] V1: starting a synchronization process.

[0042] V2-V4: Initializing message broadcast cycles, determining, by a node, whether a broadcast condition is met, if so, broadcasting clock synchronization messages, otherwise waiting until the condition is met.

[0043] V5-V6: Receiving and recording, by a neighbor node, a local clock thereof, analyzing a relative clock relationship between nodes.

[0044] V7-V10: Performing, by the neighbor node, maximum likelihood estimation of a relative frequency offset according to a new clock relationship, updating a likelihood function, that is, updating the objective function and constraints, and comparing same with existing boundary position information to update the feasible region.

[0045] V11: Comparing vertex values of the feasible region, obtaining a relative frequency offset under maximum likelihood estimation.

[0046] V12: Performing clock parameter compensation using an average consensus-based synchronization method.

[0047] V13-V14: Judging whether a synchronization termination condition is met, ending if synchronization is achieved, otherwise, monitoring clock information, updating estimation, compensation and other operations, until the synchronization termination condition is met.

[0048] Finally, it should be noted that the above embodiments are only used for describing, rather than limiting the technical solution of the present invention. Although the present invention is described in detail with reference to the preferred embodiments, those ordinary skilled in the art shall understand that the technical solution of the present invention can be amended or equivalently replaced without departing from the purpose and the scope of the technical solution. The amendment or equivalent replacement shall be covered within the scope of the claims of the present invention.