A barometric pressure estimation method based on kalman filtering
By using a Kalman filter-based pressure estimation method, the problem of low accuracy in pressure value acquisition was solved, achieving high precision and real-time performance of pressure values, and improving the reliability and stability of the airtightness tester.
Patent Information
- Application Number
- CN202310053288.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-02-03
- Publication Date
- 2025-11-07
- Estimated Expiration
- 2043-02-03
AI Technical Summary
Existing air pressure data acquisition methods have low accuracy in airtightness testing and are easily affected by solenoid valve operation and temperature fluctuations, resulting in significant data noise.
A Kalman filter-based pressure estimation method is adopted. By determining the Kalman filter model, a pressure change model is constructed, and simulation verification and genetic algorithm conversion are performed. The air tightness tester program is added, the filter parameters are optimized, and the final tester and Kalman filter are used to estimate the pressure.
It improves the accuracy of air pressure value acquisition, ensures the repeatability of test results and the stability of the instrument, meets the accuracy and real-time requirements of practical applications, and has a certain filtering effect.
Smart Images

Figure CN116086723B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the technical field of data processing, and in particular to a barometric pressure estimation method based on Kalman filtering. BACKGROUND
[0002] Air tightness test is a test method used to measure the sealing ability of a seal. Its importance lies in its ability to detect whether a seal can maintain the designed sealing ability.
[0003] Air pressure acquisition and analysis is an important part of air tightness testing. In order to improve the reliability, stability and repeatability of air tightness testing, stable and accurate real-time air pressure values are needed.
[0004] CN107071148B discloses a method and terminal for collecting and processing atmospheric pressure data, including a server, an acquisition module and a calculation module. The server obtains atmospheric pressure measurement values from a barometer of the terminal. The acquisition module is used to obtain a plurality of second atmospheric pressure measurement values, their measurement times and measurement locations from the server, and output them to the calculation module. The calculation module is used to calculate and process the plurality of second atmospheric pressure measurement values according to the measurement times and measurement locations, and take the calculation and processing result as the current atmospheric pressure value. The present application can reliably determine the atmospheric pressure value of the environment where the terminal is located. Further, when the terminal has a barometer, the atmospheric pressure value measured by the terminal itself is used to further correct the calculation and processing result of the measurement value returned by the server, thereby improving data reliability and user experience.
[0005] CN114968695A discloses a method and device for monitoring atmospheric pressure data and a mobile terminal. The mobile terminal is installed with a barometer. The method includes obtaining a plurality of groups of measured atmospheric pressure data and corresponding network-side atmospheric pressure data collected by the barometer, wherein the collection time and collection location corresponding to each group of measured atmospheric pressure data and network-side atmospheric pressure data are the same. The comprehensive atmospheric pressure deviation value of the mobile terminal is calculated according to the plurality of groups of measured atmospheric pressure data and network-side atmospheric pressure data. It is determined whether the barometer is in a calibration state according to the comprehensive atmospheric pressure deviation value.
[0006] CN213148184U is a differential digital barometer, belonging to the technical field of automatic observation equipment. It includes an air pressure acquisition assembly, which is an independent assembly structure, including three air pressure acquisition units, a static pressure chamber and a static pressure chamber cover. The three air pressure acquisition units are installed in the static pressure chamber, and the static pressure chamber cover is used to realize the overall sealing of the static pressure chamber.
[0007] The air pressure value collection method mainly uses a single air pressure gauge, and the air pressure value obtained by the air pressure gauge is easily affected by the action of the electromagnetic valve and the temperature fluctuation during the air tightness test, and there is serious data noise, thereby reducing the accuracy of the air pressure value collection. SUMMARY
[0008] The present application aims to provide a Kalman filter-based air pressure estimation method, aiming to solve the problem of low accuracy of existing air pressure value collection.
[0009] To achieve the above-mentioned purpose, the present application provides a Kalman filter-based air pressure estimation method, comprising the following steps:
[0010] Based on the solution and the filter structure, the final model is obtained after modeling and promotion according to the actual observation data;
[0011] Determine the Kalman filter model;
[0012] Combine the final model with the Kalman filter model for simulation verification to obtain an accurate model;
[0013] Convert the genetic algorithm of the accurate model to obtain a filter algorithm;
[0014] Add the filter algorithm to the program of the air tightness tester to obtain a test program;
[0015] Use the test program for repeated testing, and obtain filter parameters through group comparison;
[0016] Based on the filter parameters, the accurate model is modified to obtain a Kalman filter, and based on the test group, the parameters of the air tightness test of the air tightness tester are modified to obtain a final tester;
[0017] Use the final tester and the Kalman filter to estimate the air pressure to obtain an estimation result.
[0018] The final model obtained based on the solution and the filter structure after modeling and promotion according to the actual observation data comprises:
[0019] Determine the structure of the Kalman filter model to obtain a filter structure;
[0020] Determine the solution of air pressure data processing;
[0021] Based on the solution and the filter structure, a construction model is obtained by modeling according to the actual observation data;
[0022] Based on the construction model, the air pressure change rate is constructed isomorphically to obtain additional information, and the additional information is used to promote the construction model to obtain a final model.
[0023] The air pressure estimation using the Kalman filter includes:
[0024] The original value of the sensor is sampled using the final test instrument.
[0025] The original value collected is estimated after filtering using the Kalman filter to obtain an estimated result.
[0026] The air pressure estimation method based on Kalman filtering provided by the present application comprises the following steps: modeling and improving according to actual observation data based on a solution and a filter structure to obtain a final model; determining a Kalman filter model; simulating and verifying the final model combined with the Kalman filter model to obtain an accurate model; converting the genetic algorithm of the accurate model to obtain a filtering algorithm; adding the filtering algorithm to the program of an air tightness tester to obtain a test program; repeatedly testing using the test program, and obtaining filtering parameters through group comparison; modifying the parameters of the accurate model based on the filtering parameters to obtain a Kalman filter, and modifying the parameters of the air tightness test of the air tightness tester based on the test group to obtain a final test instrument; and estimating the air pressure using the final test instrument and the Kalman filter to obtain an estimated result. BRIEF DESCRIPTION OF DRAWINGS
[0027] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the prior art, the drawings needed to be used in the embodiments or prior art description will be briefly introduced. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor.
[0028] Figure 1 is a flow chart of the air pressure estimation method based on Kalman filtering provided by the present application.
[0029] Figure 2 is a schematic diagram of air pressure noise.
[0030] Figure 3 is a schematic diagram of noise filtering.
[0031] Figure 4 is a code schematic diagram of coding simulation in matlab.
[0032] Figure 5 is a code diagram for converting matlab algorithm into c implementation.
[0033] Figure 6 is a schematic diagram of the filtering effect.
[0034] Figure 7 is a code diagram for registering the Kalman filtered air pressure value into the sensor framework of the embedded device. DETAILED DESCRIPTION
[0035] Embodiments of the present application are described in detail below with reference to examples illustrated in the accompanying drawings, in which the same or similar components have the same or similar designations throughout the various figures and identical or similar components have the same or similar reference numerals. The embodiments described below are examples and are intended to explain the present application, and should not be understood as limiting the present application.
[0036] Referring to Figures 1 to 7 , the present application provides a Kalman filtering-based air pressure estimation method, comprising the following steps:
[0037] S1, based on the solution and the filter structure, modeling and improving according to the actual observation data to obtain the final model;
[0038] The specific mode is:
[0039] S11, determining the structure of the Kalman filter modeler to obtain the filter structure;
[0040] Specifically, the filter structure is
[0041] wherein, is the optimal estimation value at time k; is the prediction of time k at time k-1, K k is the gain matrix; is the innovation Ps, and the Kalman optimal estimation value is the weighted sum of the optimal prediction and the innovation.
[0042] S12, determining the solution of air pressure data processing;
[0043] S13, based on the solution and the filter structure, modeling according to the actual observation data to obtain the constructed model;
[0044] Specifically, the air pressure change model is unknown, and lacks an accurate mathematical model. According to a large amount of actual observation data, it is assumed that the air tightness tester has a constant air leakage speed in the test stage, and is modeled. The modeling is a model in which the air leakage acceleration is approximately 0, the air leakage speed is approximately constant, and the air leakage is constant attenuation.
[0045] According to the integral relationship of the three, after discretization, it is expressed as follows:
[0046]
[0047]
[0048] Wherein, Φ k,k-1 : state prediction matrix;
[0049] Q: variance prediction parameter;
[0050] T is the sampling period.
[0051] S14 constructs the pressure rate of change based on the constructed model, obtains additional information, and uses the additional information to improve the constructed model to obtain a final model.
[0052] Specifically, in the air tightness tester, only one direct pressure sensor is provided, and increasing the number of sensors cannot make the collected air pressure value more stable or more reliable. For the constructed model, there is only one-dimensional data, the observation information is less and not objective. The one-dimensional data cannot obtain both air pressure data and air leakage speed information, and the isomorphic construction of the pressure rate of change obtains additional confidence, thereby improving the observability of the model.
[0053] According to the integral relationship of the three, after discretization, it is expressed as follows:
[0054]
[0055]
[0056] Wherein, Z is the estimated sequence parameter, and H is the estimated sequence parameter.
[0057] S2 determines a Kalman filter model;
[0058] Specifically, the selection of the filter is determined in the whole test cycle. On a large scale (multiple air tightness tests), the air pressure amplitude changes sharply; on a small scale (test stage of a single test), the air pressure noise is sharp.
[0059] According to the data and the purpose of the application, the large-scale change does not perform Kalman filtering, and only mean value smoothing is performed. In order to reduce the influence of small-scale noise, the filtered air pressure data is replaced by the smoothed air pressure and the air pressure rate of change respectively.
[0060] S3 combines the final model with the Kalman filter model to perform simulation verification to obtain an accurate model;
[0061] Specifically, the established model is combined with the Kalman filter to perform coding simulation in matlab.
[0062] S4 converts the genetic algorithm of the accurate model to obtain a filtering algorithm;
[0063] Specifically, after confirming that the model is correct (excluding parameter adjustment), the matlab algorithm is converted into c to be implemented in an embedded device (Cortex-M3) for running.
[0064] S5 adds the filtering algorithm to the program of the air tightness tester to obtain a test program;
[0065] Specifically, the filtering algorithm is added to the program of the air tightness tester so as to be able to simultaneously collect original pressure, filtered pressure, original test result and filtered test result.
[0066] S6 uses the test program to perform repeated tests, and obtains filtering parameters through group comparison;
[0067] Specifically, the above program is used to perform tests, and test data is collected to adjust parameters. The test group includes original collected signals, smooth mean filtering, and Kalman filtering (1-n) parameters constructed according to the model. This step is repeatedly performed until a group of parameters are obtained, and the filtering effect is obviously improved.
[0068] The test program is used to perform repeated tests, and test data is collected to obtain a test group, as shown in the following table:
[0069] Test group Standard deviation Range CPK performance GRR performance Raw acquisition signal Smoothed mean filter Kalman filter - parameter 1 Kalman filter - parameter 2 .... Kalman filter - parameter n
[0070] S7 modifies parameters of the accurate model based on the filtering parameters to obtain a Kalman filter, and modifies parameters of the air tightness test of the air tightness tester based on the test group to obtain a final tester;
[0071] Specifically, the parameters of the air tightness test (test pressure and test time) are modified, and step nine is repeatedly verified. Until a group of parameters are obtained, the filtering effect is obviously improved under the pressure range of 0-1 Mpa and the test time of 1-600 s, and the repeatability, stability and reliability of the instrument are obviously improved.
[0072] S8 uses the final tester and the Kalman filter to perform air pressure estimation to obtain an estimation result.
[0073] The specific mode is as follows:
[0074] S81 uses the final tester to sample original values of a sensor;
[0075] Specifically, the C-implemented filtering algorithm is structured, and the context is encapsulated to realize reentrant filtering function and non-interference simultaneous filtering for multiple sensors.
[0076] S82 estimates the estimated result by filtering the collected original value using the Kalman filter.
[0077] Specifically, the filtering rate of the Kalman filter is 150 sps. The air pressure value filtered by the Kalman filter is registered in the sensor framework of the embedded device for calling by an application layer program.
[0078] Beneficial effects:
[0079] 1. The Kalman filter is designed according to the air pressure change model of the air tightness tester, real-time reliable air pressure values are inferred, the estimated result can meet the accuracy and real-time requirements of actual application, has a certain filtering effect, and can make the repeatability of the test result good and the instrument stable and reliable.
[0080] 2. The present application has the advantages of low cost, high precision, close to the actual application scene of the air tightness tester, and can effectively improve the reliability of the air tightness tester.
[0081] 3. The algorithm only needs 10KB of Flash and 16KB of RAM to run, and the calling frequency is 20ms / time, which can run on most embedded devices and can be used in multiple models of air tightness testers.
[0082] The above only discloses a preferred embodiment of the air pressure estimation method based on the Kalman filter, and of course cannot limit the scope of the present application, and those skilled in the art can understand that the above-mentioned embodiment can be implemented in whole or in part, and equivalent changes made according to the claims of the present application still belong to the scope covered by the present application.
Claims
1. A barometric pressure estimation method based on Kalman filtering, characterized by, The method comprises the following steps: Based on the solution and the filter structure, the actual observation data is modeled and promoted to obtain a final model; A Kalman filter model is determined; The final model is combined with the Kalman filter model for simulation verification to obtain an accurate model; The genetic algorithm of the accurate model is converted to obtain a filter algorithm; The filter algorithm is added to the program of the air tightness tester to obtain a test program; The test program is used for repeated testing, and through group comparison, filter parameters are obtained; The test program is used for repeated testing, and test data is collected to obtain a test group; Based on the filter parameters, the accurate model is modified to obtain a Kalman filter, and based on the test group, the parameters of the air tightness test of the air tightness tester are modified to obtain a final tester; The final tester and the Kalman filter are used for air pressure estimation to obtain an estimation result.
2. The Kalman filter-based air pressure estimation method of claim 1, wherein Based on the solution and the filter structure, the actual observation data is modeled and promoted to obtain a final model, comprising: Determine the structure of the Kalman filter modeler to obtain a filter structure; Determine the solution of air pressure data processing; Based on the solution and the filter structure, the actual observation data is modeled to obtain a constructed model; Based on the constructed model, the air pressure change rate is constructed to obtain additional information, and the additional information is used to promote the constructed model to obtain a final model.
3. The Kalman filter-based air pressure estimation method of claim 2, wherein The Kalman filter is used for air pressure estimation to obtain an estimation result, comprising: The final tester is used to sample the original value of the sensor; The Kalman filter is used to filter and estimate the collected original value to obtain an estimation result.
Citation Information
Patent Citations
A method and terminal for atmospheric pressure data acquisition and processing
CN107071148B
Differential digital barometer
CN213148184U
Air tightness detection method and device for vehicle component
CN114323489A
Mobile phone function detection method and device
CN115165248A