CN111988011B - Anti-divergence method for filter - Google Patents
Anti-divergence method for filter Download PDFInfo
- Publication number
- CN111988011B CN111988011B CN202010756820.9A CN202010756820A CN111988011B CN 111988011 B CN111988011 B CN 111988011B CN 202010756820 A CN202010756820 A CN 202010756820A CN 111988011 B CN111988011 B CN 111988011B
- Authority
- CN
- China
- Prior art keywords
- filter
- deviation
- value
- average value
- sliding window
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Images
Classifications
-
- H—ELECTRICITY
- H03—ELECTRONIC CIRCUITRY
- H03H—IMPEDANCE NETWORKS, e.g. RESONANT CIRCUITS; RESONATORS
- H03H9/00—Networks comprising electromechanical or electro-acoustic devices; Electromechanical resonators
- H03H9/46—Filters
Landscapes
- Physics & Mathematics (AREA)
- Acoustics & Sound (AREA)
- Feedback Control In General (AREA)
Abstract
The invention relates to a method for preventing divergence of a filter, which is characterized in that a sliding window with a certain width for storing the output and input deviation of the filter is established, and the sliding window is initialized when the filter is initialized; respectively sliding the current deviation value and the first deviation value into and out of the sliding window in each period, sequentially sliding the middle deviation value, calculating the absolute value of the average deviation of the sliding window, and when the result is greater than a certain specified threshold, judging that the filter diverges, and resetting the filter to work again; when the filter is within the specified threshold, the filter works normally, so that the filter is always in a closed-loop controlled state. The invention adds a monitoring measure for the filter, and the filter is reset in time when diverging, so that the filter is always in a controlled state.
Description
Technical Field
The invention belongs to the field of digital filters, and the method is suitable for occasions applying the digital filters.
Background
Digital filters are widely used in modern circuits to filter/suppress interference and retain useful signals through complex algorithms, however, because of the instability of the filters caused by various reasons, the problem of uncontrollable divergence often occurs in practical operation, and engineers always have many ways to avoid the problem, and refer to related patents, and the solution is as follows:
publication (publication) No. (CN 108550371 a) patent "echo cancellation method for fast and stable of intelligent voice interaction device" while in tracking, divergence of adaptive filter can be prevented by limiting the increment range of filter coefficient.
The patent of publication (CN 108663068 a) entitled "an SVM adaptive kalman filtering method applied to initial alignment" discloses that, in order to solve the problems that a noise model is difficult to quantify and a system has sudden changes, thereby causing filter divergence and unstable numerical value, an adaptive factor generated by a support vector machine is introduced, so as to improve the robustness of an algorithm and improve the tracking capability of state and parameter sudden changes.
The method is characterized in that a feedback loop is constructed through observation noise in Kalman filtering, a model noise variance matrix is adjusted on line in the feedback loop by applying a machine learning theory, and an estimated mean square error matrix and a filter gain matrix of a filter are changed, so that the filter is prevented from diverging, and the filtering precision is improved.
The patent publication (CN 103983996 a) describes "a method for tightly combined adaptive filtering against GPS outliers" monitoring a filter residual sequence by using a fuzzy logic controller to estimate the measured noise strength on line and adaptively adjust the measured noise matrix parameter value of the filter to improve the filtering precision and prevent the filter from diverging ".
Publication (publication) No. (CN 108646191 a) patent "a battery state of charge estimation method based on DAFEKF" said "using time-varying attenuation factor to suppress memory length of filter, … …, while adaptively adjusting process noise and measurement noise covariance, preventing … … filter divergence etc.
The above patents all dynamically modify filter parameters to avoid filter divergence, most algorithms are complex and should have some effect, but the action mechanism cannot ensure that divergence is eradicated immediately after divergence occurs.
Disclosure of Invention
Technical problem to be solved
In order to avoid the defects of the prior art, the invention provides a filter anti-divergence method.
Technical scheme
A method for preventing divergence of a filter, comprising: setting a sliding window with a certain width for storing the deviation between the output and the input of the filter, and initializing the sliding window when the filter is initialized; respectively sliding the current deviation value and the first deviation value into and out of the sliding window in each period, sequentially sliding the middle deviation value, calculating the absolute value of the average deviation of the sliding window, and when the result is greater than a certain specified threshold, judging that the filter diverges, and resetting the filter to work again; when the filter is within the specified threshold, the filter works normally, so that the filter is always in a closed-loop controlled state.
The specified threshold refers to a local filter monitoring threshold, and is obtained by adopting a statistical method: for batch products, a certain product acquires sample files 1-m respectively containing N sampling points according to use conditions, each sampling point comprises a filter input sampling value and a filter output sampling value, each i =10 divisions are performed on the sampling point of each sample file, the deviation value of the filter output and input of each sampling point is calculated and stored in a corresponding segmented file, then the average value of the i deviation values is obtained, and the average value is respectively written into a local deviation average value file for the certain product and a global deviation average value file for the batch products until all the sample files are processed; and traversing the local deviation average value file and the global deviation average value file to respectively obtain a local deviation average value maximum value and a global deviation average value maximum value, respectively multiplying the two maximum values by a margin coefficient which is more than 1, and taking the absolute value to respectively obtain a local filter monitoring threshold and a global filter monitoring threshold of the product and the batch product under the use condition.
The number i =10 can also be the value number i =10 × j, and j is a positive integer which is larger than or equal to 1 and smaller than or equal to 5j and smaller than or equal to N.
The margin coefficient is 2.5.
Advantageous effects
The invention provides a method for preventing divergence of a filter, which adds a monitoring measure for the filter, and resets in time when the filter diverges, so that the filter is always in a controlled state. Compared with the prior art, the invention has the following beneficial effects:
1. the method is simple;
2. eliminating divergence in time;
3. the reliability of the filter is greatly improved.
Drawings
FIG. 1 is a schematic diagram of the present invention
FIG. 2 is a diagram of an embodiment: (a) Leveling the lower embodiment, and (b) erecting the lower embodiment with rough leveling.
Detailed Description
The invention will now be further described with reference to the following examples and drawings:
a simple and easy filter anti-divergence method is characterized in that:
setting a sliding window with a certain width (1.. N, n is the width of the sliding window, n is more than or equal to 1) for storing the deviation between the output and the input of the filter, and initializing the sliding window when the filter is initialized; respectively sliding the current deviation value and the first deviation value into and out of the sliding window in each period, sequentially sliding the intermediate deviation value, calculating the absolute value of the average deviation of the sliding window, and when the result is greater than a certain specified threshold, judging that the filter diverges, resetting the filter to work again, and simultaneously (or not) resetting the sliding window; when the filter is within the specified threshold, the filter works normally, so that the filter is always in a closed-loop controlled state.
The threshold determination can be obtained by a statistical method, and a filter monitoring threshold statistical algorithm is referred to as follows: for a batch product, a certain product can obtain sample files 1-m respectively containing N sampling points according to a use condition 1, each sampling point comprises a filter input sampling value and a filter output sampling value, each i =10 (or other sampling numbers i, i =10 xj, j is a positive integer with j being more than or equal to 1 and less than or equal to 5 and j being less than or equal to 5) of each sampling point of each sample file is divided, a deviation value of the filter output and input of each sampling point is obtained and stored into a corresponding segmented file, then an average value is obtained for the i deviation values, and the average value is respectively written into a local deviation average value file for the certain product and a global deviation average value file for the batch product, if all sample files are processed. Traversing the local deviation average value file and the global deviation average value file to respectively obtain a maximum value of the local deviation average value and a maximum value of the global deviation average value, multiplying the two maximum values by a margin coefficient which is larger than 1, taking absolute values to respectively obtain a monitoring threshold 1 of a local filter and a monitoring threshold 1 of a global filter under the use condition 1 of the product and the batch product, and respectively storing the monitoring thresholds into corresponding files. The local and global filter monitoring threshold acquisition method under other use conditions of the product is similar.
Example 1:
an embodiment of the invention is schematically shown in figure 2a.
Referring to fig. 2a, a sliding window with a certain width of 64 is established to store the deviation between the output and the input of the filter, and the sliding window is initialized when the filter is initialized; the current deviation value and the first deviation value of each period respectively slide into and slide out of the sliding window, the middle deviation value slides in sequence, the absolute value of the average deviation of the sliding window is calculated, when the result is greater than the dispersion threshold under leveling, the filter is judged to be dispersed, the filter is reset to work again, and the sliding window can be reset (or not needed) at the same time; when the dispersion threshold is within the leveling lower dispersion threshold, the filter normally works, so that the filter is always in a closed-loop controlled state.
The threshold determination can be obtained by adopting a statistical method, and the statistical algorithm of the filter monitoring threshold is as follows: for a batch product, a certain product can obtain sample files 1-3 respectively containing 207 sampling points according to leveling use conditions, each sampling point comprises a filter input sampling value and a filter output sampling value, each sampling point of each sample file is divided into i =10 sampling points, deviation values of the filter output and input of each sampling point are calculated and stored in corresponding segmented files, then an average value is obtained for 10 deviation values, the average value is respectively written into a local deviation average value file for the certain product and a global deviation average value file for the batch product, and if all sample files are processed, all the sample files are obtained. And traversing the local deviation average value file and the global deviation average value file to respectively obtain a local deviation average value maximum value and a global deviation average value maximum value, respectively multiplying the two maximum values by a margin coefficient of 2.5, respectively obtaining absolute values to respectively obtain local and global filter monitoring thresholds aiming at the product and the batch products under the leveling use condition, and respectively storing the local and global filter monitoring thresholds into corresponding files.
Example 2:
referring to fig. 2b, a sliding window with a certain width of 64 is established to store the deviation between the output and the input of the filter, and the sliding window is initialized when the filter is initialized; respectively sliding the current deviation value and the first deviation value into and out of the sliding window in each period, sequentially sliding the intermediate deviation values, calculating the absolute value of the average deviation of the sliding window, and when the result is greater than the divergence threshold under the erection of the coarse adjustment level, judging that the filter diverges, resetting the filter to work again, and simultaneously (or not) resetting the sliding window; when the divergence threshold is within the setting coarse adjustment level, the filter works normally, so that the filter is always in a closed-loop controlled state.
The method for obtaining the monitoring threshold of the local and global filters of the product under the use condition of erection rough leveling is similar to the previous embodiment.
Claims (3)
1. A method for preventing divergence of a filter, comprising: setting a sliding window with a certain width for storing the deviation between the output and the input of the filter, and initializing the sliding window when the filter is initialized; respectively sliding the current deviation value and the first deviation value into and out of the sliding window in each period, sequentially sliding the middle deviation value, calculating the absolute value of the average deviation of the sliding window, and when the result is greater than a certain specified threshold, judging that the filter diverges, and resetting the filter to work again; when the voltage is within the specified threshold, the filter normally works to enable the filter to be in a closed-loop controlled state all the time; the specified threshold refers to a local filter monitoring threshold, and is obtained by adopting a statistical method: for batch products, a certain product acquires sample files 1-m respectively containing N sampling points according to use conditions, each sampling point comprises a filter input sampling value and a filter output sampling value, each i =10 divisions are performed on the sampling point of each sample file, the deviation value of the filter output and input of each sampling point is calculated and stored in a corresponding segmented file, then the average value of the i deviation values is obtained, and the average value is respectively written into a local deviation average value file for the certain product and a global deviation average value file for the batch products until all the sample files are processed; and traversing the local deviation average value file and the global deviation average value file to respectively obtain a local deviation average value maximum value and a global deviation average value maximum value, respectively multiplying the two maximum values by a margin coefficient which is more than 1, and taking the absolute value to respectively obtain a local filter monitoring threshold and a global filter monitoring threshold of the product and the batch product under the use condition.
2. The method as claimed in claim 1, wherein i =10 further includes a number i =10 xj, j being a positive integer with j being 1 ≤ 5 and N being 5j ≤.
3. A method as claimed in claim 1, wherein said margin coefficient is 2.5.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010756820.9A CN111988011B (en) | 2020-07-31 | 2020-07-31 | Anti-divergence method for filter |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010756820.9A CN111988011B (en) | 2020-07-31 | 2020-07-31 | Anti-divergence method for filter |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111988011A CN111988011A (en) | 2020-11-24 |
CN111988011B true CN111988011B (en) | 2023-01-03 |
Family
ID=73444830
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010756820.9A Active CN111988011B (en) | 2020-07-31 | 2020-07-31 | Anti-divergence method for filter |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111988011B (en) |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2007142111A1 (en) * | 2006-06-08 | 2007-12-13 | Nec Corporation | Noise erasing device and method, and noise erasing program |
CN106130508A (en) * | 2016-06-13 | 2016-11-16 | 电子科技大学 | Digital multimeter noise-reduction method based on FIR filter |
CN108631753A (en) * | 2018-05-15 | 2018-10-09 | 西安空间无线电技术研究所 | A kind of integration compensation digital filter design method |
WO2020078399A1 (en) * | 2018-10-17 | 2020-04-23 | 深圳锐越微技术有限公司 | Filtering method and device for filter, filter and storage medium |
Family Cites Families (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US7317842B2 (en) * | 2003-10-30 | 2008-01-08 | Samsung Electronics Co., Ltd. | Global and local statistics controlled noise reduction system |
US8279345B2 (en) * | 2009-07-21 | 2012-10-02 | Qualcomm Incorporated | System and method for random noise estimation in a sequence of images |
US10215862B2 (en) * | 2014-04-07 | 2019-02-26 | Honeywell International Inc. | Systems and methods for a code carrier divergence high-pass filter monitor |
US9552711B2 (en) * | 2014-07-18 | 2017-01-24 | Google Inc. | Systems and methods for intelligent alarming |
-
2020
- 2020-07-31 CN CN202010756820.9A patent/CN111988011B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2007142111A1 (en) * | 2006-06-08 | 2007-12-13 | Nec Corporation | Noise erasing device and method, and noise erasing program |
CN106130508A (en) * | 2016-06-13 | 2016-11-16 | 电子科技大学 | Digital multimeter noise-reduction method based on FIR filter |
CN108631753A (en) * | 2018-05-15 | 2018-10-09 | 西安空间无线电技术研究所 | A kind of integration compensation digital filter design method |
WO2020078399A1 (en) * | 2018-10-17 | 2020-04-23 | 深圳锐越微技术有限公司 | Filtering method and device for filter, filter and storage medium |
Non-Patent Citations (2)
Title |
---|
"A Drift Detecting Anti-Divergent EKF for Online Biodynamic Model Identification";James L. Coyte等;《2015 IEEE 17th International Conference on High Performance Computing and Communications, 2015 IEEE 7th International Symposium on Cyberspace Safety and Security, and 2015 IEEE 12th International Conference on Embedded Software and Systems》;20151130;第1116-1121页 * |
"机动目标跟踪的一种防发散RBUKF算法";张园等;《指挥仿真与控制》;20170228;第39卷(第1期);第41-43页 * |
Also Published As
Publication number | Publication date |
---|---|
CN111988011A (en) | 2020-11-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CA2315637C (en) | Method of predicting overshoot in a control system response | |
CN112418051B (en) | State estimation method for nonlinear dynamic system under non-Gaussian noise | |
CN108983610B (en) | Robust self-adaptive anti-interference control method | |
CN115437425B (en) | Temperature control method, device, equipment and storage medium | |
CN110826021A (en) | Robust identification and output estimation method for nonlinear industrial process | |
CN109946979A (en) | A kind of self-adapting regulation method of servo-system sensitivity function | |
CN111176112A (en) | Improved PID control algorithm for dynamically adjusting upper limit value of integral | |
Khosravian et al. | State estimation for nonlinear systems with delayed output measurements | |
CN111988011B (en) | Anti-divergence method for filter | |
CN108512528B (en) | Ratio control and normalization LMP filtering method under a kind of CIM function | |
Jiao et al. | Backstepping tracking control using Gaussian processes with event-triggered online learning | |
CN108776274A (en) | A kind of wind electric converter fault diagnosis based on adaptive-filtering | |
Chadli et al. | On the stability analysis of multiple model systems | |
CN110048694A (en) | Random Fourier's feature core least mean square algorithm based on argument step-length | |
CN117075466B (en) | PID controller parameter setting method and device, electronic equipment and storage medium | |
CN112925207A (en) | Greenhouse environment temperature self-adaption method based on parameter identification | |
Yue et al. | Event-triggered adaptive control for stochastic nonlinear systems with time-varying full state constraints and output dead-zone | |
CN111222214A (en) | Improved strong tracking filtering method | |
CN114614490A (en) | Reactive voltage control method and device, medium and computing device | |
CN110723594B (en) | Rope tying tension control device and method | |
Su et al. | Stationary Policies are Optimal in Risk-averse Total-reward MDPs with EVaR | |
Kim et al. | Controller design for time domain specifications | |
KR101572241B1 (en) | Control system with robust control capability | |
CN110852397A (en) | Adaptive signal fusion method and system based on relative fluctuation | |
FILIPOVIĆ et al. | On robustified adaptive minimum-variance controller |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |