A gas detection device based on an environmental parameter compensation algorithm

By integrating temperature and humidity sensors and wind speed sensors into the gas detection device for environmental parameter compensation, and combining this with the Grubbs criterion to eliminate abnormal data, the accuracy problem of gas detection devices in chemical plant areas has been solved, achieving high-precision gas concentration detection.

CN116400012BActive Publication Date: 2025-10-21NANJING LONGYUAN MICROELECTRONICS TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310226613.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-03-09
Publication Date
2025-10-21
Estimated Expiration
2043-03-09

AI Technical Summary

Technical Problem

Existing gas detection devices are sensitive to changes in environmental parameters within chemical plant areas, resulting in low accuracy of detection data. In particular, insufficient comprehensive compensation for temperature and wind speed leads to significant errors in gas concentration detection.

Method used

A gas detection device based on an environmental parameter compensation algorithm is used. It connects to a processor via temperature and humidity sensors and wind speed sensors to perform temperature and wind speed compensation corrections. Combined with the Grubbs criterion, abnormal data is eliminated, thereby improving the accuracy of gas concentration detection.

Benefits of technology

It achieves high accuracy in gas concentration detection under different environments, reduces the impact of temperature, humidity and wind speed on the detection results, and improves the accuracy of gas detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116400012B_ABST
    Figure CN116400012B_ABST
Patent Text Reader

Abstract

A kind of gas detection device based on environmental parameter compensation algorithm, including processor, sensor detection module, communication module and compensation correction module;Sensor detection module includes temperature and humidity sensor, gas detection sensor and wind speed sensor respectively connected with processor, the temperature, humidity value corresponding to each state point is saved in processor;When the device starts to carry out gas concentration detection, processor automatically obtains the initial value of gas concentration, temperature value and wind speed value corresponding to the same time point and calculates temperature compensation value and wind speed compensation value;After the initial value of gas concentration, temperature value and wind speed value obtained by processor, compensation correction operation is carried out to gas concentration data according to compensation algorithm;Finally, error correction is carried out again.The gas detection parameter value is compensated and corrected by temperature compensation and wind speed compensation in the application, and the gas concentration value can be compensated;So the data of gas detection can be closer to real value, and the accuracy of device under different environments is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of gas detection devices, and in particular to a gas detection device based on an environmental parameter compensation algorithm. Background Art

[0002] The trend of chemical companies concentrating in chemical plant areas in my country is accelerating. Chemical plant areas contain a large number of flammable, explosive, and toxic hazardous chemicals, making them prone to leaks, fires, explosions, and poisoning accidents. Chemical plant areas often emit toxic gases such as CO, NH3, NO, and NO2, which are harmful to the human body. These gases are extremely harmful to the human body. At low concentrations, they can damage the respiratory system, while at high concentrations, they can cause coma and even death. However, these toxic gases are difficult to detect with human senses until they reach a certain concentration. Therefore, these emitted toxic gases can easily cause harm to the human body. Therefore, toxic gas detection in chemical plant areas is essential.

[0003] Toxic gas detectors consist of a miniature plug-in electrochemical sensor housed in a 3166 stainless steel housing, an epoxy-resin-encapsulated intelligent transmitter module (ITM), and a sensor splash shield. However, because gas sensors are sensitive to changes in the external environment, various factors can affect the sensor's detection performance. This is especially true for airborne pollutant concentration detection. Without data compensation, the measured data may contain significant errors. Temperature and wind speed compensation are performed, taking into account daily temperature and wind speed. Single temperature compensation or wind speed compensation has inherent flaws. If only one of these is compensated, rather than a combination of multiple factors, the data obtained by the gas detection device will have certain errors and low accuracy in certain environmental conditions.

[0004] This invention aims to develop an algorithm for accurately detecting toxic gas concentrations in the air, based on temperature and wind speed compensation, and to deploy it on a drone. This invention can detect toxic gas concentrations in the air above chemical plants in real time, providing a certain degree of protection for the personal safety of workers within the plant. This significantly frees up manpower and can replace blind spots that are often inaccessible to human operators, making daily work more efficient. Summary of the Invention

[0005] In response to the above-mentioned technical problems, the present technical solution provides a gas detection device based on an environmental parameter compensation algorithm, which is carried on a drone. The gas detection parameter values ​​are compensated and corrected through temperature compensation and wind speed compensation, and its gas concentration value can be compensated; thereby, the gas detection data can be closer to the true value, and the accuracy of the device in different environments is improved; it can effectively solve the above-mentioned problems.

[0006] The present invention is achieved through the following technical solutions:

[0007] A gas detection device based on an environmental parameter compensation algorithm comprises a processor, a sensor detection module, a communication module, and a compensation correction module. The sensor detection module comprises a temperature and humidity sensor, a gas detection sensor, and a wind speed sensor, which are respectively connected to the processor and store the temperature and humidity values ​​corresponding to each state point in the processor. When the device begins to detect gas concentration, the processor automatically obtains the initial gas concentration value, temperature value, and wind speed value corresponding to the same time point and calculates the temperature compensation value and the wind speed compensation value. After the processor obtains the initial gas concentration value, the temperature compensation value, and the wind speed compensation value, it performs a compensation correction operation on the gas concentration data according to the compensation algorithm to obtain the compensation value for gas detection. Finally, the compensation correction module performs error correction on the compensation value for gas detection to ensure that a true and accurate compensation value is sent to the processor, thereby achieving the purpose of outputting an accurate gas concentration value.

[0008] Furthermore, the gas detection sensor includes a three-electrode gas chemical sensor for monitoring carbon monoxide, sulfur dioxide, nitric oxide, nitrogen dioxide, hydrogen sulfide, and ethylene in toxic gases. The PCB board in the processor is hexagonal, and the six three-electrode gas chemical sensors responsible for gas concentration detection are respectively installed at the six sides of the PCB board to achieve a full range of gas concentration detection in the space; the PCB board is installed in a hexagonal box body, and a plurality of air holes are provided on the box body so that gas can enter the interior of the box to complete concentration detection.

[0009] Furthermore, the gas detection device is installed on the lower side of the drone to detect toxic gases in the drone's flight area when the drone is flying.

[0010] Furthermore, when the gas detection device is started, gas concentration detection begins. The processor obtains the current temperature value and wind speed value and the pre-set corresponding relationship to obtain the temperature compensation and wind speed compensation corresponding to the current temperature value and wind speed value. The gas concentration detection sensor sends the current gas concentration value to the processor. The processor sums the gas concentration compensation value after temperature compensation and wind speed compensation with the current gas concentration value to obtain the true gas concentration value. The true gas concentration consists of three parts: the gas concentration transmitted by the gas detection sensor, the temperature compensation value of the gas concentration affected by temperature, and the wind speed compensation value of the gas concentration affected by the external wind speed received by the microcontroller. It can be expressed as (2-1):

[0011] V 实际 =V c +V' 补偿 (2-1);

[0012] Where V 实际 is the actual gas concentration value, V c is the gas concentration value received by the processor, V 补偿 It is the gas concentration compensation value after temperature compensation and wind speed compensation, ppm.

[0013] Furthermore, the temperature compensation value is obtained by the corresponding relationship between the change of the temperature value and the fluctuation of the gas concentration. When the device is started, the processor obtains the temperature value and gas concentration value in the windless state at that time. When the device is launched for 60 seconds, the processor obtains the temperature value and gas concentration value in the current state. The difference between the two temperature values ​​under the two reference states and the error value caused by the gas concentration value can be calculated. The compensation coefficient of the gas concentration is shown in the calculation formula (2-2).

[0014]

[0015] Where W is the gas compensation coefficient, ppm / °C; V0 is the gas concentration value when the device is started, and V1 is the gas concentration value 60 seconds after the device is started, in ppm; T0 is the temperature when the device is started, and T1 is the temperature measured by the temperature and humidity sensor 60 seconds after the device is started, in °C;

[0016] In the environment where the device is located, there is no significant temperature fluctuation in a short period of time. However, as the temperature change increases, the gas compensation coefficient also changes, following the exponential gradient change function (2-3):

[0017]

[0018] Where W T is the gas compensation coefficient for temperature compensation, W is the initial gas compensation coefficient, ppm / °C; T2 is the temperature for calculating temperature compensation, °C; n is the ground roughness, which is taken as 0.4 here;

[0019] To calculate the temperature compensation value for the gas at a certain moment, we first need to obtain the temperature difference between the current temperature and the temperature when the device is started (2-4)

[0020] ΔT0=T2-T0(2-4);

[0021] Where ΔT0 is the temperature difference, T2 is the temperature measured by the temperature and humidity sensor when calculating temperature compensation, °C;

[0022] Therefore, the calculation formula for the temperature compensation value of gas concentration is (2-5):

[0023] V 温度补偿 =W T ΔT0 (2-5);

[0024] Where V温度补偿 is the temperature compensation value of gas concentration, ppm; W T is the gas compensation coefficient for temperature compensation, ppm / ℃; ΔT0 is the temperature difference, ℃.

[0025] Furthermore, the wind speed compensation value is the difference between the temperature received by the processor from the sensor and the initial temperature. After temperature compensation, the actual gas concentration of the gas in the current environment can be corrected and displayed. Temperature, humidity and wind speed are all factors that affect the gas concentration detected by the device, and the three are also closely related. As the wind speed increases, the temperature gradually decreases; as the wind speed decreases, the temperature will rise accordingly. Humidity is the water content in the air. As humidity increases, the temperature decreases, and as humidity decreases, the temperature increases.

[0026] The wind speed at high altitudes is generally higher than that at low altitudes, but the difference between the two varies with weather conditions. On sunny days with strong sunlight and strong air convection, the difference between the wind speeds at high altitudes and low altitudes is small. On cloudy days with weak sunlight and weak air convection, the difference between the wind speeds at high altitudes and low altitudes is large. Combining the above two situations, this device calculates the wind speed proportionally using the wind speed measured by the sensor and the drone's flight altitude.

[0027] The temperature and humidity sensor obtains real-time temperature and humidity values. It is known that in summer, every 15% increase in relative humidity is equivalent to a 0.5°C increase in temperature, and every 0.18m / s increase in wind speed is equivalent to a 0.45°C decrease in temperature. The device uses 50% relative humidity and the initial temperature t0 at device startup as the critical points, and the temperature compensation calculation formula (2-6) based on wind speed can be determined:

[0028]

[0029] Where ΔT1 is the temperature difference under the influence of wind speed, °C; v h is the wind speed at the height of the device, m / s; α is the humidity measured by the temperature and humidity sensor;

[0030] The wind speed compensation calculation for gas concentration is the temperature difference of ΔT1 under the influence of wind speed, which can be used to obtain the calculation formula (2-7) for wind speed compensation of gas concentration detection.

[0031] V 风速补偿 =ΔT1·W T (2-7);

[0032] Where V 风速补偿 is the wind speed compensation value of gas concentration, ppm; W T is the gas compensation coefficient during temperature compensation, ppm / ℃; ΔT1 is the temperature difference under the influence of wind speed, ℃.

[0033] Furthermore, the compensation value of the gas detection is obtained by summing the temperature compensation value and the wind speed compensation value and taking the average value. The calculation formula is as follows (2-8):

[0034]

[0035] Furthermore, the error correction is to obtain the temperature compensation value and the wind speed compensation value, and then the value is compensated and corrected by the processor before the real gas concentration value is output; in the compensation correction module of the processor, in order to effectively reduce the error and take into account the accuracy and response speed, every multiple V 补偿 The data values ​​are grouped together, and the Grubbs criterion is used to remove data that deviates too far from the data set, eliminate error data, improve accuracy, and reduce the impact of outliers on the overall data.

[0036] Furthermore, the multiple V 补偿 In the data value, if the absolute value of the residual error of a certain compensation value|X i |>Gg, it can be judged that this data has a large error and should be deleted; the residual error of the compensation value |X i |Satisfy the following formula (3-1):

[0037]

[0038] Where, is the average value of the compensation values ​​collected n times; σ(V) is the standard deviation of the compensation value data set; g(n,a) depends on the data volume n and the significance level a in the compensation value data set, and a is usually 0.01.

[0039] Furthermore, the data volume n is set to 20. According to the Grubbs criterion table, when n=20, a=0.01, g(n,a)=2.88; the 20 compensation values ​​are summed to calculate the average value, the residual error is calculated, and the standard deviation σ(V) is calculated; if the absolute value of the residual error of a certain compensation value |X i If the value is greater than 2.88 times the standard deviation σ(V), the compensation value has a large error. After deleting it, calculate the average value again. After calculating the new average value, repeat the above process until there is no error value.

[0040] According to the above process, 20 compensation values ​​are set as a set of data. The standard deviation of the compensation value is obtained by the Bessel formula and then compared with the residual of the compensation value to determine whether the residual is reasonable and whether the compensation value has deviation; the following formula (3-2) is satisfied:

[0041]

[0042] In the data set, if the residual of each data is less than 2.88σ(V), then there is no error in the data set, and the compensation value can be calculated; satisfying the following formula (3-3)

[0043]

[0044] After correction and compensation, the accurate gas concentration compensation value V' is obtained 补偿 , V' 补偿 Substituting into formula (2-1), we can get the final gas concentration value V 实际 .

[0045] Beneficial effects

[0046] The gas detection device based on the environmental parameter compensation algorithm proposed in this invention has the following beneficial effects compared with the prior art:

[0047] (1) The present invention provides a temperature and humidity sensor and a wind speed sensor disposed adjacent to the gas detection sensor. The temperature and humidity sensor, wind speed sensor, and gas detection sensor are connected to a processor, respectively, to compensate for harmful gas concentrations. The gas detection parameter values ​​are compensated and corrected through temperature compensation and wind speed compensation, thereby making the gas detection data closer to the true value and improving the accuracy of the device under different environments. This effectively solves the problem that the accuracy of the gas sensor output signal is easily affected by temperature, humidity, and wind speed, thereby causing low gas detection accuracy. BRIEF DESCRIPTION OF THE DRAWINGS

[0048] Figure 1 It is a structural block diagram of the present invention.

[0049] Figure 2 This is a box diagram of the gas detection device in the present invention.

[0050] Figure 3 This is a flow chart of the operation of the environmental parameter compensation algorithm in the present invention. DETAILED DESCRIPTION

[0051] The following will be combined with the accompanying drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. The described embodiments are only part of the embodiments of the present invention, rather than all the embodiments. Under the premise of not departing from the design concept of the present invention, various modifications and improvements made by ordinary persons in this field to the technical solutions of the present invention should fall within the scope of protection of the present invention.

[0052] Example 1:

[0053] like Figure 1As shown, a gas detection device based on an environmental parameter compensation algorithm includes a processor, a sensor detection module, a communication module and a compensation correction module; the sensor detection module includes a temperature and humidity sensor, a gas detection sensor and a wind speed sensor, which are respectively connected to the processor, and the temperature and humidity values ​​corresponding to each state point are stored in the processor; when the device starts to detect gas concentration, the processor automatically obtains the initial gas concentration value, temperature value and wind speed value corresponding to the same time point and calculates the temperature compensation value and the wind speed compensation value; after the processor obtains the initial gas concentration value, temperature compensation value and wind speed compensation value, it performs compensation correction operation on the gas concentration data according to the compensation algorithm to obtain the compensation value of gas detection; finally, the compensation correction module performs error correction on the compensation value of gas detection to ensure that the true and accurate compensation value is sent to the processor, so as to achieve the purpose of outputting an accurate gas concentration value.

[0054] Chemical plants may produce toxic gases such as carbon monoxide, sulfur dioxide, nitric oxide, nitrogen dioxide, hydrogen sulfide, and ethylene. Depending on the primary toxic gas produced, circuit design requires separate detection capabilities for each toxic gas. Therefore, the gas detection sensor includes a three-electrode gas chemical sensor for monitoring carbon monoxide, sulfur dioxide, nitric oxide, nitrogen dioxide, hydrogen sulfide, and ethylene. The PCB in the processor is designed as a hexagon, and the six three-electrode gas chemical sensors responsible for gas concentration detection are mounted on each of the six sides of the PCB, enabling comprehensive detection of gas concentrations in the space.

[0055] like Figure 2 As shown, the PCB is mounted within a hexagonal box with multiple ventilation holes, allowing gas to enter the box for concentration detection. The gas detection device is mounted on the underside of the drone, detecting toxic gases in the flight area during flight. The ventilation holes are positioned on the underside of the box based on the PCB's shape and the drone's state. This semi-enclosed space, with only one side permeable, is designed to accommodate the device's operating conditions. Perforations are drilled underneath the box to allow gas to enter and complete concentration detection.

[0056] When the gas detection device is started, gas concentration detection begins. The processor obtains the current temperature value and wind speed value and the pre-set corresponding relationship to obtain the temperature compensation and wind speed compensation corresponding to the current temperature value and wind speed value. The gas concentration detection sensor sends the current gas concentration value to the processor. The processor sums the gas concentration compensation value after temperature compensation and wind speed compensation with the current gas concentration value to obtain the true gas concentration value. The true gas concentration consists of three parts: the gas concentration transmitted by the gas detection sensor received by the single-chip microcomputer, the temperature compensation value of the gas concentration affected by temperature, and the wind speed compensation value of the gas concentration affected by external wind speed. It can be expressed as (2-1):

[0057] V 实际 =V c +V' 补偿 (2-1);

[0058] Where V 实际 is the actual gas concentration value, V c is the gas concentration value received by the processor, V 补偿 It is the gas concentration compensation value after temperature compensation and wind speed compensation, ppm.

[0059] The temperature compensation value is obtained by the corresponding relationship between the change in temperature value and the fluctuation of gas concentration. When the device is started, the processor obtains the temperature value and gas concentration value in the windless state. When the device is launched for 60 seconds, the processor obtains the temperature value and gas concentration value at this state. The difference between the two temperature values ​​under the two reference states and the error value of the gas concentration value can be calculated. The gas concentration compensation coefficient is shown in the calculation formula (2-2).

[0060]

[0061] Where W is the gas compensation coefficient, ppm / °C; V0 is the gas concentration value when the device is started, and V1 is the gas concentration value 60 seconds after the device is started, in ppm; T0 is the temperature when the device is started, and T1 is the temperature measured by the temperature and humidity sensor 60 seconds after the device is started, in °C.

[0062] In the environment where the device is located, there is no significant temperature fluctuation in a short period of time. However, as the temperature change increases, the gas compensation coefficient also changes, following the exponential gradient change function (2-3):

[0063]

[0064] Where W T is the gas compensation coefficient for temperature compensation, W is the initial gas compensation coefficient, ppm / ℃; T2 is the temperature for calculating temperature compensation, ℃; n is the ground roughness, which is 0.4 here.

[0065] To calculate the temperature compensation value for the gas at a certain moment, we first need to obtain the temperature difference between the current temperature and the temperature when the device is started (2-4)

[0066] ΔT0=T2-T0(2-4);

[0067] Where ΔT0 is the temperature difference, and T2 is the temperature measured by the temperature and humidity sensor when calculating temperature compensation, in °C.

[0068] Therefore, the calculation formula for the temperature compensation value of gas concentration is (2-5):

[0069] V 温度补偿 =W T ΔT0 (2-5);

[0070] Where V 温度补偿 is the temperature compensation value of gas concentration, ppm; W T is the gas compensation coefficient for temperature compensation, ppm / ℃; ΔT0 is the temperature difference, ℃.

[0071] The wind speed compensation value is the difference between the temperature received by the processor from the sensor and the initial temperature. After temperature compensation, the actual gas concentration of the gas in the current environment can be corrected and displayed. Temperature, humidity and wind speed are all factors that affect the gas concentration detected by the device, and the three are also closely related. As the wind speed increases, the temperature gradually decreases; as the wind speed decreases, the temperature will rise accordingly. Humidity is the water content in the air. As the humidity increases, the temperature decreases, and as the humidity decreases, the temperature increases.

[0072] Wind speeds at high altitudes are generally greater than those at low altitudes, but the difference between these two speeds varies with weather conditions. On sunny days with strong sunlight and strong air convection, the difference in wind speeds between high and low altitudes is smaller. On cloudy days with weak sunlight and weak air convection, the difference in wind speeds between high and low altitudes is larger. Combining these two conditions, this device calculates wind speed proportionally using the wind speed measured by the sensor and the drone's flight altitude.

[0073] The temperature and humidity sensor obtains real-time temperature and humidity values. It is known that in summer, every 15% increase in relative humidity is equivalent to a 0.5°C increase in temperature, and every 0.18m / s increase in wind speed is equivalent to a 0.45°C decrease in temperature. The device uses 50% relative humidity and the initial temperature t0 at device startup as the critical points, and the temperature compensation calculation formula (2-6) based on wind speed can be determined:

[0074]

[0075] Where ΔT1 is the temperature difference under the influence of wind speed, °C; vh is the wind speed at the height of the device, m / s; α is the humidity measured by the temperature and humidity sensor.

[0076] The wind speed compensation calculation for gas concentration is the temperature difference of ΔT1 under the influence of wind speed, which can be used to obtain the calculation formula (2-7) for wind speed compensation of gas concentration detection.

[0077] V 风速补偿 =ΔT1·W T (2-7);

[0078] Where V 风速补偿 is the wind speed compensation value of gas concentration, ppm; W T is the gas compensation coefficient during temperature compensation, ppm / ℃; ΔT1 is the temperature difference under the influence of wind speed, ℃.

[0079] Temperature, humidity, and wind speed all have significant effects on the true value of gas concentration. This device, by analyzing the relationship between temperature, humidity, and wind speed, converts the effects of humidity and wind speed on the detection results into the effects of temperature on the detection results. The compensation value for gas detection is obtained by summing and averaging the temperature compensation value and the wind speed compensation value. The calculation formula is as follows (2-8):

[0080]

[0081] The error correction is to compensate the temperature compensation value and wind speed compensation value, and then the processor outputs the real gas concentration value; in the compensation correction module of the processor, in order to effectively reduce the error and take into account the accuracy and response speed, every 20 V 补偿 The data values ​​are grouped together, and the Grubbs criterion is used to remove data that deviates too far from the data set, eliminate error data, improve accuracy, and reduce the impact of outliers on the overall data.

[0082] The 20 V 补偿 In the data value, if the absolute value of the residual error of a certain compensation value|X i |>Gg, it can be judged that this data has a large error and should be deleted; the residual error of the compensation value |X i |Satisfy the following formula (3-1):

[0083]

[0084] Where, is the average value of the compensation values ​​collected n times; σ(V) is the standard deviation of the compensation value data set; g(n,a) depends on the data volume n and the significance level a in the compensation value data set, and a is usually 0.01.

[0085] The data volume n is 20. According to the Grubbs criterion table, when n = 20, a = 0.01, g(n,a) = 2.88; the 20 compensation values ​​are summed to calculate the average value, the residual error is calculated, and the standard deviation σ(V); if the absolute value of the residual error of a certain compensation value |X i If the value is greater than 2.88 times the standard deviation σ(V), the compensation value has a large error. After deleting it, calculate the average value again. After calculating the new average value, repeat the above process until there is no error value.

[0086] According to the above process, 20 compensation values ​​are set as a set of data. The standard deviation of the compensation value is obtained by the Bessel formula and then compared with the residual of the compensation value to determine whether the residual is reasonable and whether the compensation value has deviation; the following formula (3-2) is satisfied:

[0087]

[0088] In the data set, if the residual of each data is less than 2.88σ(V), then there is no error in the data set, and the compensation value can be calculated; satisfying the following formula (3-3)

[0089]

[0090] After correction and compensation, the accurate gas concentration compensation value V' is obtained 补偿 , V' 补偿 Substituting into formula (2-1), we can get the final gas concentration value V 实际 .

[0091] The above are only specific embodiments of the present invention, but the protection scope of the present invention is not limited thereto. Any changes, replacements and improvements within the technical scope disclosed by the present invention are within the protection scope of the present invention.

Claims

1. A gas detection device based on an environmental parameter compensation algorithm, comprising a processor, a sensor detection module, a communication module, and a compensation correction module; characterized in that: The sensor detection module includes a temperature and humidity sensor, a gas detection sensor, and a wind speed sensor. The temperature and humidity sensor, the gas detection sensor, and the wind speed sensor are respectively connected to the processor, and the temperature and humidity values ​​corresponding to each state point are stored in the processor. When the device starts to detect gas concentration, the processor automatically obtains the initial gas concentration value, temperature value, and wind speed value corresponding to the same time point and calculates the temperature compensation value and the wind speed compensation value. After the processor obtains the initial gas concentration value, the temperature compensation value, and the wind speed compensation value, it performs compensation correction calculation on the gas concentration data according to the compensation algorithm to obtain the compensation value of gas detection. Finally, the compensation correction module performs error correction on the compensation value of gas detection to ensure that the true and accurate compensation value is sent to the processor, so as to achieve the purpose of outputting an accurate gas concentration value. The temperature compensation value is obtained by the corresponding relationship between the change of temperature value and the fluctuation of gas concentration. When the device is started, the processor obtains the temperature value and gas concentration value in the windless state at that time. When the device is launched for 60 seconds, the processor obtains the temperature value and gas concentration value in the current state. The compensation coefficient of gas concentration is calculated by the difference between the two temperature values ​​under the two reference states and the error value caused by the gas concentration value, as shown in the calculation formula (2-2). Where W is the gas compensation coefficient, ppm / °C; V0 is the gas concentration value when the device is started, and V1 is the gas concentration value 60 seconds after the device is started, ppm; T0 is the temperature when the device is started, and T1 is the temperature measured by the temperature and humidity sensor 60s later, °C; In the environment where the device is located, there is no significant temperature fluctuation in a short period of time. However, as the temperature change increases, the gas compensation coefficient also changes, following the exponential gradient change function (2-3): Where W T is the gas compensation coefficient for temperature compensation, W is the initial gas compensation coefficient, ppm / °C; T2 is the temperature for calculating temperature compensation, °C; n is the ground roughness, which is taken as 0.4 here; To calculate the temperature compensation value for the gas at a certain moment, we first need to obtain the temperature difference between the current temperature and the temperature when the device is started (2-4) ΔT0=T2-T0(2-4); Where ΔT0 is the temperature difference, T2 is the temperature measured by the temperature and humidity sensor when calculating temperature compensation, °C; Therefore, the calculation formula for the temperature compensation value of gas concentration is (2-5): V 温度补偿 =W T ·ΔT0(2-5); where V 温度补偿 is the temperature compensation value of gas concentration, ppm; W T is the gas compensation coefficient for temperature compensation, ppm / ℃; ΔT0 is the temperature difference, ℃; The wind speed compensation value is the difference between the temperature received by the processor from the sensor and the initial temperature. After temperature compensation, the actual gas concentration of the gas in the current environment can be corrected and displayed; The temperature and humidity sensor obtains real-time temperature and humidity values. It is known that in summer, every 15% increase in relative humidity is equivalent to a 0.5°C increase in temperature, and every 0.18m / s increase in wind speed is equivalent to a 0.45°C decrease in temperature. The device uses 50% relative humidity and the initial temperature t0 at device startup as the critical points to determine the temperature compensation calculation formula (2-6) based on wind speed: Where ΔT1 is the temperature difference under the influence of wind speed, °C; v h is the wind speed at the height of the device, m / s; α is the humidity measured by the temperature and humidity sensor; The wind speed compensation calculation for gas concentration is the temperature difference of ΔT1 under the influence of wind speed, which can be used to obtain the calculation formula (2-7) for wind speed compensation of gas concentration detection. V 风速补偿 =ΔT1·W T (2-7); where V 风速补偿 is the wind speed compensation value of gas concentration, ppm; W T is the gas compensation coefficient during temperature compensation, ppm / ℃; ΔT1 is the temperature difference under the influence of wind speed, ℃.

2. A gas detection device based on an environmental parameter compensation algorithm according to claim 1, characterized in that: The gas detection sensor includes a three-electrode gas chemical sensor for monitoring carbon monoxide, sulfur dioxide, nitric oxide, nitrogen dioxide, hydrogen sulfide, and ethylene in toxic gases. The PCB board in the processor is hexagonal, and the six three-electrode gas chemical sensors responsible for gas concentration detection are respectively installed at the six sides of the PCB board to achieve a full range of gas concentration detection space. The PCB board is installed in a hexagonal box body, and the box body is provided with multiple air holes to allow gas to enter the box to complete concentration detection.

3. A gas detection device based on an environmental parameter compensation algorithm according to claim 1 or 2, characterized in that: The gas detection device is installed on the lower side of the drone to detect toxic gases in the drone's flight area when the drone is flying.

4. A gas detection device based on an environmental parameter compensation algorithm according to claim 3, characterized in that: When the gas detection device is started, it begins to detect gas concentration. The processor obtains the current temperature value and wind speed value and the pre-set corresponding relationship to obtain the temperature compensation and wind speed compensation corresponding to the current temperature value and wind speed value; the gas chemical sensor sends the current gas concentration value to the processor; The processor sums the gas concentration compensation value after temperature compensation and wind speed compensation with the current gas concentration value to obtain the true gas concentration value. The true gas concentration consists of three parts: the gas concentration received by the microcontroller from the gas detection sensor, the temperature compensation value of the gas concentration affected by temperature, and the wind speed compensation value of the gas concentration affected by the external wind speed. It is expressed as (2-1): V 实际 =V c +V 补偿 (2-1); Where V 实际 is the actual gas concentration value, V c is the gas concentration value received by the processor, V 补偿 It is the gas concentration compensation value after temperature compensation and wind speed compensation, ppm.

5. The gas detection device based on the environmental parameter compensation algorithm according to claim 4, characterized in that: The compensation value of the gas detection is obtained by summing the temperature compensation value and the wind speed compensation value and taking the average value. The calculation formula is as follows (2-8):

6. A gas detection device based on an environmental parameter compensation algorithm according to claim 4 or 5, characterized in that: The error correction is to compensate and correct the temperature compensation value and wind speed compensation value after obtaining the value, and then the processor outputs the real gas concentration value; in the compensation correction module of the processor, in order to effectively reduce the error and take into account the accuracy and response speed, take every multiple V 补偿 The data values ​​are grouped together, and the Grubbs criterion is used to remove data that deviates too far from the data set, eliminate error data, improve accuracy, and reduce the impact of outliers on the overall data.

7. A gas detection device based on an environmental parameter compensation algorithm according to claim 6, characterized in that: The multiple V 补偿 In the data value, if the absolute value of the residual error of a certain compensation value|X i |>Gg, it can be judged that this data has a large error and should be deleted; the residual error of a gas compensation value X i Satisfy the following formula (3-1): Where, is the average value of the compensation values ​​collected n times; σ(V) is the standard deviation of the compensation value data set; g(n,a) depends on the data volume n in the compensation value data set and the significance level a, where a is 0.

01.

8. The gas detection device based on the environmental parameter compensation algorithm according to claim 7, characterized in that: The data volume n is set to 20. According to the Grubbs criterion table, when n=20, a=0.01, g(n,a)=2.88; the 20 compensation values ​​are summed to calculate the average value, the residual error is calculated, and the standard deviation σ(V) is calculated; if the absolute value of the residual error of a certain compensation value |X i If the value is greater than 2.88 times the standard deviation σ(V), the compensation value has a large error. After deleting it, calculate the average value again. After calculating the new average value, repeat the above process until there is no error value. According to the above process, 20 compensation values ​​are set as a set of data. The standard deviation of the compensation value is obtained by the Bessel formula and then compared with the residual of the compensation value to determine whether the residual is reasonable and whether the compensation value has deviation; the following formula (3-2) is satisfied: In the data set, if the residual of each data is less than 2.88σ(V), then there is no error in the data set, and the compensation value can be calculated; satisfying the following formula (3-3) After correction and compensation, the accurate gas concentration compensation value V is obtained 补偿 , V 补偿 Substituting into formula (2-1), we can get the final gas concentration value V 实际 .

Citation Information

Patent Citations

  • Method for resisting high-speed airflow of multi-sensor cavity

    CN111624310A

  • Gas concentration calculation method, device and equipment and storage medium

    CN113758890A