The invention relates to the technical field of
clock synchronization, in particular to a
clock synchronization method based on a self-adaptive dynamic adjustment
Kalman filter, which comprises the following steps of: defining a
state vector containing
clock skew and drift by adopting a second-order
clock model, constructing a state transition and observation model, and calculating the state of the state transition and observation model; adaptively estimating a
noise covariance based on a historical residual sliding window; measuring and predicting residual errors are recorded in each round of filtering, and the
prediction residual errors are quantized; the residual error is stored in a sliding window, sample variance is calculated to obtain
noise covariance initial
estimation, and meanwhile, a simplified model of the proportional relation between
clock skew and drift
noise covariance is assumed; according to a covariance matching principle, using maximum likelihood
estimation to calculate observation and
process noise covariance from a sliding window residual error, that is, measuring a residual error square mean value as an observation noise covariance, presenting the
process noise covariance in a
matrix form, and accurately estimating noise characteristics; and performing exponential weighted
moving average updating on the noise covariance by using a
smoothing factor, performing Kalman filtering prediction and updating iteration to obtain
clock skew and drifting
optimal estimation, correcting a local clock according to the
clock skew and drifting
optimal estimation, and performing loop iteration to realize high-precision
clock synchronization. According to the method, the noise covariance can be estimated and adjusted in real time, higher synchronization precision, higher convergence speed and higher robustness can be realized in a complex environment, and the problem that high-precision and stable
clock synchronization is difficult to guarantee in a non-stable and high-dynamic
wireless environment by the existing method is solved.