Method and device for improving measurement precision of NDIR sensor and storage medium
Through multiple steps of temperature compensation, signal correction and interference gas influence removal, the problem of inaccurate measurement of NDIR sensors in complex environments is solved, real-time monitoring and accurate measurement of gas concentration are achieved.
Patent Information
- Application Number
- CN202510567468.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-30
- Publication Date
- 2025-07-25
AI Technical Summary
The measurement accuracy of the gas concentration measurement in complex environments of NDIR sensors is affected by ambient temperature changes and interfering gases, resulting in inaccurate measurements.
By obtaining ambient temperature information, adjusting the current and voltage in the signal processing circuit for temperature compensation, and using a linearized circuit composed of an operational amplifier and nonlinear components for signal correction, combining a multi-optical system and an interference gas absorption spectrum model, the absorption effect of the interference gas is analyzed and deducted, and the target gas concentration is finally calculated.
Real-time monitoring and accurate measurement of gas concentration in complex environments is achieved, ensuring the stability and reliability of the sensor output signal and improving measurement accuracy.
Smart Images

Figure CN120369660A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of gas detection, and in particular to a method, device and storage medium for improving the measurement accuracy of NDIR sensors. Background Art
[0002] With the increasing demand for gas detection in the fields of industry and environmental monitoring, gas sensing technology has gradually become an important detection means. Non-dispersive infrared (NDIR) sensors are widely used in gas detection, environmental monitoring, industrial control and other fields due to their advantages such as high precision and non-contact measurement. The NDIR sensor calculates the gas concentration by measuring the absorption degree of the target gas to infrared light with a specific wavelength. However, in practical applications, the NDIR sensor may be restricted by factors such as environmental temperature changes and the influence of interfering gases, thus affecting the measurement accuracy. Summary of the Invention
[0003] In order to improve the measurement accuracy of the gas concentration of the NDIR sensor in a complex environment, the present application provides a method, device and storage medium for improving the measurement accuracy of the NDIR sensor.
[0004] The first above-mentioned invention object of the present application is achieved through the following technical solutions: A method for improving the measurement accuracy of an NDIR sensor, the method for improving the measurement accuracy of the NDIR sensor includes: Obtain environmental temperature information; According to the environmental temperature information, adjust the current and voltage in the signal processing circuit of the NDIR sensor to generate a temperature-compensated signal; Use a linearization circuit composed of an operational amplifier and a non-linear element to perform non-linear correction on the temperature-compensated signal and output a linearized signal; After obtaining the linearized signal, use a multi-optical path system to obtain the absorption information of the interfering gas, analyze the absorption information of the interfering gas through an interfering gas absorption spectrum model, analyze the absorption characteristics of the interfering gas, and obtain the absorption contribution information of the interfering gas; According to the absorption contribution information of the interfering gas, deduct the absorption influence of the interfering gas from the linearized signal to obtain the target gas concentration information, and generate a gas concentration report according to the target gas concentration information.
[0005] By adopting the above technical solution, the accuracy and reliability of the sensor output signal are ensured through multiple steps such as temperature compensation, signal nonlinear correction, removal of interfering gas influence, and calculation of target gas concentration. First, the impact of temperature changes on sensor output is minimized through ambient temperature compensation, and then the signal is corrected through the linearization circuit of the operational amplifier and nonlinear element to make the output signal more linear. Next, the absorption information of the interfering gas is obtained through the multi-optical path system, and the absorption spectrum model is used to eliminate these interfering effects. Finally, the concentration information of the target gas is accurately obtained through the concentration conversion algorithm. Combined with this technical solution, the NDIR sensor can monitor gas concentration changes in real time under various complex environmental conditions, and automatically calibrate and correct through intelligent algorithms to ensure data stability and accuracy.
[0006] In a preferred example, the present application may be further configured as follows: adjusting the current and voltage in the signal processing circuit of the NDIR sensor according to the ambient temperature information to generate a temperature-compensated signal, including: According to the ambient temperature information, adjusting the current in the signal processing circuit by changing the resistance value of the positive temperature coefficient thermistor to obtain a processed current; Based on the processed current, adjusting a gain setting in a voltage source or an operational amplifier to automatically adjust the voltage in the signal processing circuit to obtain a processed voltage; The processed current and the processed voltage are used as the temperature compensated signals.
[0007] By adopting the above technical solution, the automatic compensation of the temperature change of the NDIR sensor can be effectively realized, ensuring the stable operation of the sensor under different environmental conditions. This solution uses the change in the resistance value of the positive temperature coefficient thermistor to automatically adjust the current in the signal processing circuit according to the real-time ambient temperature information, thereby optimizing the signal transmission process. The processed current and voltage can eliminate the influence of temperature fluctuations on the signal, thereby ensuring that the temperature compensated signal is more accurate and avoiding measurement errors caused by temperature changes.
[0008] In a preferred example, the present application can be further configured as follows: the linearization circuit composed of an operational amplifier and a nonlinear element performs nonlinear correction on the temperature compensated signal and outputs a linearization signal, including: The operational amplifier and the nonlinear element form a linearization circuit, and logarithm operation is performed on the temperature-compensated signal to obtain a logarithm operation result; According to the logarithmic operation result, the temperature compensated signal is converted into the linearized signal by adjusting the gain of the operational amplifier.
[0009] By adopting the above technical solution, it is possible to effectively convert the temperature-compensated signal into a linearized signal, thereby improving the accuracy and stability of the signal. First, a linearization circuit composed of an operational amplifier and a non-linear element is used to perform a logarithmic operation on the temperature-compensated signal. This step can convert the non-linear signal that may be affected by noise and environmental fluctuations into a more regular logarithmic signal, thereby reducing the non-linear error of the signal. After obtaining the logarithmic operation result, the signal is further converted into a linearized signal by adjusting the gain setting of the operational amplifier. This process makes the signal more consistent with the absorption characteristics of the target gas when output, reduces the interference of temperature and other external factors, and effectively improves the accuracy and response speed of the sensor.
[0010] In a preferred example of the present application, it can be further configured that: the linearization circuit composed of the operational amplifier and the non-linear element performs a logarithmic operation on the temperature-compensated signal to obtain a logarithmic operation result, including: the linearization circuit performs a logarithmic operation on the temperature-compensated signal based on the following formula: V out = k·log(I in + b)+ c, where, the Vout refers to the logarithmic operation result, the k refers to the gain of the operational amplifier and the circuit characteristics, the Iin refers to the input current signal after temperature compensation, the b refers to a constant used to correct signal offset and ensure that the starting point of the logarithmic conversion is not zero, and the c refers to an offset constant used to adjust the reference value of the output voltage.
[0011] By adopting the above technical solution, it is possible to accurately achieve the logarithmic conversion of the temperature-compensated signal during the signal processing process, thereby effectively improving the linearity and stability of the signal. The linearization circuit utilizes the gain of the operational amplifier and the circuit characteristics to perform a logarithmic operation on the input current signal I in after temperature compensation to obtain the output voltage V out . Among them, the constant b included in the formula is used to correct signal offset to ensure that the starting point of the signal logarithmic conversion is not zero, and the offset constant c is used to adjust the reference value of the output voltage to adapt to different working environments. This signal conversion method based on logarithmic operation can effectively reduce the influence of external factors such as temperature fluctuations and environmental changes on the sensor, ensuring that the output signal is more stable and accurate.
[0012] In a preferred example of the present application, it can be further configured that: after obtaining the linearized signal, a multi-optical path system is used to obtain the absorption information of the interfering gas, and the absorption information of the interfering gas is analyzed through an interfering gas absorption spectrum model to analyze the absorption characteristics of the interfering gas and obtain the absorption contribution information of the interfering gas, including: The absorption signals of the interfering gas in multiple spectral bands are obtained through the multi-optical path system, and the absorption signals in multiple spectral bands are filtered according to a preset absorption wavelength range to obtain the absorption information of the interfering gas; The absorption information of the interfering gas is fitted by using the statistical analysis method in the absorption spectrum model of the interfering gas to extract the absorption intensity information of the interfering gas; The real-time environmental information is obtained, and based on the real-time environmental information, the absorption intensity information of the interfering gas is corrected by using the information correction algorithm in the absorption spectrum model of the interfering gas to obtain the absorption contribution information of the interfering gas.
[0013] By adopting the above technical solutions, the absorption information of the interfering gas can be accurately obtained and analyzed, thereby improving the accuracy and reliability of the gas monitoring system. First, the absorption signals of the interfering gas are obtained in multiple spectral bands through the multi-optical path system, and the signals are filtered in combination with the preset absorption wavelength range, so as to extract the representative absorption information of the interfering gas, which provides high-quality input data for subsequent analysis. Then, the absorption information is fitted based on the statistical analysis method in the absorption spectrum model of the interfering gas, and the absorption intensity information of the interfering gas is further extracted. This process helps to accurately identify and quantify the presence and concentration changes of the interfering gas. In addition, by obtaining the environmental information in real time and correcting the absorption intensity data based on this information, the influence of environmental changes on the detection results can be eliminated, ensuring that the measurement results are more accurate.
[0014] In a preferred example of the present application, it can be further configured that: the absorption information of the interfering gas is fitted by using the statistical analysis method in the absorption spectrum model of the interfering gas to extract the absorption intensity information of the interfering gas, including: comparing the absorption information of the interfering gas with the preset absorption characteristics in the absorption spectrum model of the interfering gas to obtain a preliminary fitting error; Through the statistical analysis method, the absorption information of the interfering gas is statistically fitted according to the preliminary fitting error to obtain the absorption intensity information of the interfering gas.
[0015] By adopting the above technical solutions, the fitting accuracy and reliability of the absorption signals of the interfering gas can be effectively improved. First, the absorption information of the interfering gas is compared with the preset absorption characteristics to obtain a preliminary fitting error. This process can help the system detect the difference between the absorption signal and the model and timely discover potential deviations or abnormalities. Then, the statistical analysis method is used to further analyze and correct the preliminary fitting error, so as to optimize the fitting of the absorption information of the interfering gas. This method can accurately calculate the error through a mathematical model to ensure that the finally obtained absorption intensity information is more accurate.
[0016] In a preferred example, the present application can be further configured as follows: according to the absorption contribution information of the interference gas, the absorption influence of the interference gas is deducted from the linearized signal to obtain the target gas concentration information, including: Determine the absorption intensity information of the interference gas based on the absorption contribution information of the interference gas; Match the absorption intensity information with the absorption characteristics in the absorption spectrum model of the interference gas, calculate the contribution of the interference gas to the signal at a preset wavelength, obtain the interference signal, and deduct the interference signal from the linearized signal to obtain the net signal; Compare the net signal with the known absorption spectrum characteristics of the target gas through the gas concentration conversion algorithm to obtain the target gas concentration information.
[0017] By adopting the above technical solution, the influence of the interference gas on the measurement of the target gas concentration can be effectively eliminated, thereby improving the accuracy of gas concentration monitoring. First, based on the absorption contribution information of the interference gas, the system can accurately determine the absorption intensity of the interference gas, and use this information to match the absorption characteristics in the absorption spectrum model of the interference gas to calculate the contribution of the interference gas to the signal at a preset wavelength. In this way, the influence of the interference signal can be identified and quantified in signal processing. Next, the interference signal is deducted from the linearized signal to obtain the net signal. This operation ensures that the measurement of the target gas concentration is not affected by the interference gas, thereby providing a more accurate detection result. Finally, through the gas concentration conversion algorithm, the system compares the net signal with the known absorption spectrum characteristics of the target gas to calculate the concentration information of the target gas. It can ensure the accurate measurement of the target gas concentration in complex environmental conditions, such as multi-gas interference or a dynamically changing gas concentration environment, and effectively eliminate the interference of other gases or environmental factors, improving the accuracy and reliability of the gas sensor.
[0018] The above-mentioned second invention object of the present application is achieved through the following technical solutions: A device for improving the measurement accuracy of an NDIR sensor, the device for improving the measurement accuracy of an NDIR sensor includes: An environmental temperature information acquisition module for acquiring environmental temperature information; An NDIR sensor signal circuit adjustment module for adjusting the current and voltage in the signal processing circuit of the NDIR sensor according to the environmental temperature information to generate a temperature-compensated signal; A linearized signal processing module for performing nonlinear correction on the temperature-compensated signal by using a linearized circuit composed of an operational amplifier and a nonlinear element, and outputting a linearized signal; An interference gas absorption contribution analysis module, configured to, after obtaining the linearized signal, use a multi-optical path system to acquire absorption information of the interference gas, analyze the absorption information of the interference gas through an interference gas absorption spectrum model, analyze the absorption characteristics of the interference gas, and obtain the absorption contribution information of the interference gas; A gas concentration reporting module, configured to, according to the absorption contribution information of the interference gas, deduct the absorption influence of the interference gas from the linearized signal, obtain target gas concentration information, and generate a gas concentration report based on the target gas concentration information.
[0019] By adopting the above technical solution, through multiple steps such as temperature compensation, signal non-linearity correction, removal of the influence of interference gas, and target gas concentration calculation, the accuracy and reliability of the sensor output signal are ensured. First, the influence of temperature change on the sensor output is minimized through environmental temperature compensation, and then the signal is corrected through a linearization circuit of an operational amplifier and a non-linear element to make the output signal more linear. Immediately afterwards, the absorption information of the interference gas is acquired through a multi-optical path system, and the absorption spectrum model is used to eliminate these interference influences. Finally, the concentration information of the target gas is accurately obtained through a concentration conversion algorithm. Combining with this technical solution, the NDIR sensor can monitor the change of gas concentration in real time under various complex environmental conditions, and perform automatic correction and modification through an intelligent algorithm to ensure the stability and accuracy of the data.
[0020] The above object three of the present application is achieved by the following technical solution: A computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the method for improving the measurement accuracy of the NDIR sensor are implemented.
[0021] The above object four of the present application is achieved by the following technical solution: A computer-readable storage medium, storing a computer program, wherein when the computer program is executed by a processor, the steps of the method for improving the measurement accuracy of the NDIR sensor are implemented.
[0022] In summary, the present application includes at least one of the following beneficial technical effects: 1. The accuracy and reliability of the sensor output signal are ensured through multiple steps such as temperature compensation, signal nonlinear correction, removal of interfering gas influence, and calculation of target gas concentration. First, ambient temperature compensation is used to minimize the impact of temperature changes on sensor output, and then the signal is corrected through the linearization circuit of the operational amplifier and nonlinear elements to make the output signal more linear. Next, the absorption information of the interfering gas is obtained through the multi-optical path system, and the absorption spectrum model is used to eliminate these interfering influences. Finally, the concentration information of the target gas is accurately obtained through the concentration conversion algorithm. Combined with this technical solution, the NDIR sensor can monitor gas concentration changes in real time under various complex environmental conditions, and automatically calibrate and correct through intelligent algorithms to ensure data stability and accuracy; 2. It can accurately realize the logarithmic conversion of the temperature-compensated signal during the signal processing process, thereby effectively improving the linearity and stability of the signal. The linearization circuit uses the gain and circuit characteristics of the operational amplifier to perform logarithmic operations on the temperature-compensated input current signal Iin to obtain the output voltage Vout. Among them, the constant b contained in the formula is used to correct the signal offset to ensure that the starting point of the logarithmic conversion of the signal is not zero, and the offset constant c is used to adjust the reference value of the output voltage to adapt to different working environments. This signal conversion method based on logarithmic operations can effectively reduce the impact of external factors such as temperature fluctuations and environmental changes on the sensor, ensuring that the output signal is more stable and accurate; 3. It can accurately acquire and analyze the absorption information of interfering gases, thereby improving the accuracy and reliability of the gas monitoring system. First, the absorption signal of the interfering gas is acquired in multiple spectral bands through a multi-optical system, and the signal is filtered in combination with the preset absorption wavelength range to extract representative absorption information of the interfering gas, which provides high-quality input data for subsequent analysis. Next, the absorption information is fitted based on the statistical analysis method in the interfering gas absorption spectrum model, and the absorption intensity information of the interfering gas is further extracted. This process helps to accurately identify and quantify the presence and concentration changes of interfering gases. In addition, by acquiring environmental information in real time and correcting the absorption intensity data based on this information, the impact of environmental changes on the detection results can be eliminated, ensuring that the measurement results are more accurate. BRIEF DESCRIPTION OF THE DRAWINGS
[0023] Figure 1 It is a schematic diagram of the structure of a method for improving the measurement accuracy of an NDIR sensor in an embodiment of the application; Figure 2 This is a flowchart for implementing step S20 in a method for improving the measurement accuracy of an NDIR sensor in an embodiment of the present application; Figure 3 This is a flowchart for implementing step S30 in a method for improving the measurement accuracy of an NDIR sensor in an embodiment of the present application; Figure 4 It is the implementation flowchart in step S301 of the method for improving the measurement accuracy of the NDIR sensor in an embodiment of the present application; Figure 5 It is the implementation flowchart in step S40 of the method for improving the measurement accuracy of the NDIR sensor in an embodiment of the present application; Figure 6 It is the implementation flowchart in step S402 of the method for improving the measurement accuracy of the NDIR sensor in an embodiment of the present application; Figure 7 It is the implementation flowchart in step S50 of the method for improving the measurement accuracy of the NDIR sensor in an embodiment of the present application; Figure 8 It is a principle block diagram of the device for improving the measurement accuracy of the NDIR sensor in an embodiment of the present application; Figure 9 It is a schematic diagram of the device in an embodiment of the present application. Specific embodiments
[0024] The following further elaborates on the present application in conjunction with the accompanying drawings.
[0025] In an embodiment, as Figure 1 shown, the present application discloses a method for improving the measurement accuracy of the NDIR sensor, which specifically includes the following steps: S10: Obtain environmental temperature information.
[0026] Specifically, the environmental temperature information can be obtained through a temperature sensor installed near the NDIR sensor. The temperature sensor can be a thermistor (such as an NTC thermistor or PT100, etc.) or a semiconductor temperature sensor. The resistance change of these temperature sensors is used to measure the surrounding environment temperature. By transmitting the output signal of the temperature sensor to the signal processing circuit, accurate environmental temperature data can be obtained. The environmental temperature information can be obtained in real time or measured regularly by sampling.
[0027] S20: According to the environmental temperature information, adjust the current and voltage in the signal processing circuit of the NDIR sensor to generate a temperature-compensated signal.
[0028] Specifically, after the ambient temperature information passes through the temperature sensor, it will be matched with the temperature data through a dedicated current regulation circuit. The change in temperature causes the resistance of the thermistor to change, thereby affecting the current. By calculating the corresponding relationship between the resistance change and the temperature change, the current intensity in the current source is adjusted to ensure that the current is linearly related to the ambient temperature. In addition, the change in current affects the voltage output. Therefore, the operational amplifier will automatically adjust the gain according to the change in the signal. By adjusting the gain setting, the voltage output is further optimized. After the adjustment is completed, the output current and voltage signals are the temperature-compensated signals.
[0029] S30: Use a linearization circuit composed of an operational amplifier and a non-linear element to perform non-linear correction on the temperature-compensated signal and output a linearized signal.
[0030] Specifically, after the signal is temperature-compensated, since the output signal of the NDIR sensor usually exhibits a non-linear relationship, it needs to be processed through a linearization circuit. This circuit is composed of an operational amplifier and a non-linear element (such as a diode or a specific resistance element). First, the signal is amplified by the operational amplifier, and the compensated signal is adjusted to increase the amplitude of the signal. Then, the non-linear element is used for non-linear correction of the signal. For example, through logarithmic conversion or exponential conversion, the input signal is converted into a linear signal. This can form an accurate linear relationship between the output signal of the NDIR sensor and the target gas concentration. Finally, through signal amplification and correction, a linearized signal is obtained.
[0031] S40: After obtaining the linearized signal, use a multi-optical path system to obtain the absorption information of the interfering gas, analyze the absorption information of the interfering gas through the interfering gas absorption spectrum model, analyze the absorption characteristics of the interfering gas, and obtain the absorption contribution information of the interfering gas.
[0032] Specifically, after obtaining the linearized signal, the NDIR sensor works through its multi-optical path system. This system can perform spectral absorption measurements in multiple wavelength ranges, using multiple different light sources and detectors. By changing the angle and path of the optical path, the absorption information from the interfering gas is collected from multiple angles respectively. The interfering gas usually has different absorption characteristics at different wavelengths. Therefore, the sensor will analyze each wavelength separately, calculate the absorbance of the interfering gas in each band, and through these absorption data, use the interfering gas absorption spectrum model for fitting and analysis, so as to accurately extract the absorption intensity information of the interfering gas.
[0033] S50: According to the absorption contribution information of the interfering gas, deduct the absorption influence of the interfering gas from the linearized signal to obtain the target gas concentration information, and generate a gas concentration report based on the target gas concentration information.
[0034] Specifically, using the absorption contribution information of the interfering gas, first determine the absorption intensity of the interfering gas within a preset wavelength range. By analyzing the absorbance of the interfering gas and matching it with the absorption characteristics in the model, calculate the contribution of the interfering gas to the signal in each band. Then, use these calculation results as the interfering signal and subtract the interfering signal from the linearized signal through algorithms such as weighted average algorithm or direct subtraction algorithm to obtain the net signal. The net signal is the true signal of the target gas after removing the influence of the interfering gas. Next, compare the known absorption spectrum characteristics of the target gas with the net signal to calculate the concentration information of the target gas. Finally, generate a gas concentration report based on the obtained concentration information of the target gas, and the report will display the concentration value of the target gas in this environment.
[0035] In one embodiment, as Figure 2 shown, in step S20, that is, according to the ambient temperature information, adjust the current and voltage in the signal processing circuit of the NDIR sensor to generate a temperature-compensated signal, including: S201: According to the ambient temperature information, adjust the current in the signal processing circuit through the change in the resistance value of the positive temperature coefficient thermistor to obtain the processed current.
[0036] Specifically, temperature changes will cause the resistance value of the positive temperature coefficient thermistor (such as NTC thermistor) to change. As the ambient temperature rises, the resistance value of the thermistor will also increase, and vice versa. This change can be used to obtain temperature information by measuring the change in the resistance value of the thermistor. Through the current source control circuit, the resistance value of the thermistor is monitored in real time, and the magnitude of the current is adjusted according to the change in the resistance. Usually, a constant current source is used to achieve this current adjustment to ensure the stability of the current during temperature changes. The adjustment of the current is based on the set temperature compensation curve, which is usually determined through experiments or simulation models. After the current adjustment, a temperature-compensated current value will be obtained.
[0037] S202: Based on the processed current, adjust the gain setting in the voltage source or operational amplifier to automatically adjust the voltage in the signal processing circuit to obtain the processed voltage.
[0038] Specifically, the current after temperature compensation will directly affect the voltage output in the signal processing circuit. To maintain the stability of the signal, the voltage in the signal processing circuit needs to be adjusted according to the processed current. Usually, in the voltage source or operational amplifier, the gain setting is the key factor affecting the voltage output. According to the change in the current, the gain setting will be dynamically adjusted. The operational amplifier amplifies the input signal through a feedback loop. The larger the current, the greater the gain, and the higher the voltage output; when the current is small, the gain will decrease, and the voltage output will decrease.
[0039] S203: Use the processed current and processed voltage as the signals after temperature compensation.
[0040] Specifically, the processed current and processed voltage are two key signals obtained during the temperature compensation process, and they jointly determine the output signal of the sensor. During this process, the processed current is first adjusted through the temperature compensation mechanism to ensure that the relationship between the change in current and the ambient temperature is eliminated. The influence of temperature change on the sensor signal is suppressed by the dynamic adjustment of the current source for the processed current. At the same time, the processed voltage reflects the change in current after temperature compensation by adjusting the gain setting, ensuring that the voltage output is stable at different temperatures. To integrate these two signals into a signal after temperature compensation, a weighted or superposition method is used. The signals of current and voltage are uniformly converted, for example, by combining the current and voltage signals through an analog multiplier or adder to generate a unified output signal.
[0041] Furthermore, during the integration process, the current signal and voltage signal can first be standardized through certain gains respectively, so that they are both within the same reference range. For example, assuming that the magnitudes of the processed current signal and voltage signal are different, the amplitudes of these two signals can be adjusted to a similar range first by setting corresponding gain factors (such as the gain of an operational amplifier). Then, these two signals are added together through a weighting coefficient to form a composite signal. Specifically, the current and voltage signals can be combined through an analog adder or multiplier to obtain a comprehensive signal, which reflects the result after temperature compensation. The following formula is used for combination: X comp = A·I processed + B·V processed , where X comp is the signal after temperature compensation, I processed is the processed current signal, V processed is the processed voltage signal, and A and B are the weighting coefficients of the current and voltage signals respectively. Through this weighted combination process, the finally obtained V comp signal is the signal after temperature compensation.
[0042] In one embodiment, as Figure 3 shown, in step S30, a linearization circuit composed of an operational amplifier and a nonlinear element is used to perform nonlinear correction on the signal after temperature compensation and output a linearized signal, including: S301: A linearization circuit composed of an operational amplifier and a nonlinear element is used to perform a logarithmic operation on the signal after temperature compensation to obtain a logarithmic operation result.
[0043] Specifically, the temperature-compensated signal first enters a circuit composed of an operational amplifier and a non-linear element (such as a diode or a photodiode, etc.). The function of this circuit is to perform logarithmic processing on the temperature-compensated signal. The operational amplifier is used to amplify the amplitude of the input signal for subsequent processing, while the non-linear element is responsible for converting the relationship between the amplitude of the signal and the voltage into a logarithmic relationship. Through the cooperation between the operational amplifier and the non-linear element, the amplitude of the signal is compressed and output in logarithmic form, which makes the signal that originally changes exponentially more controllable in amplitude, reduces the influence of temperature on the signal change, and thus effectively improves the stability and accuracy of the signal. Finally, through this logarithmic operation, the logarithmic operation result is obtained.
[0044] S302: According to the logarithmic operation result, by adjusting the gain of the operational amplifier, the temperature-compensated signal is converted into a linearized signal.
[0045] Specifically, after obtaining the logarithmic operation result, in order to make the signal more accurately reflect the concentration of the target gas, it is necessary to further convert the signal into a linearized signal. To achieve this, by adjusting the gain of the operational amplifier, the gain of the output signal can be dynamically adjusted according to the amplitude of the input signal, so that the temperature-compensated signal can maintain a linear response. The adjustment of the gain is completed through a feedback circuit. The feedback circuit adjusts the gain of the operational amplifier in real time according to the change of the output signal to ensure that the linearity of the signal is improved. For example, when the temperature changes greatly, the amplitude of the signal may fluctuate greatly. At this time, the gain will be adjusted accordingly to ensure that the output signal remains linear within the full range. Finally, through this gain adjustment method, the temperature-compensated signal is converted into a linearized signal. In one embodiment, as Figure 4 shown, in step S301, that is, a linearization circuit composed of an operational amplifier and a non-linear element is used to perform logarithmic operation on the temperature-compensated signal to obtain the logarithmic operation result, including: S3011: The linearization circuit performs logarithmic operation on the temperature-compensated signal based on the following formula: V out = k·log(I in + b)+ c, where Vout refers to the logarithmic operation result, k refers to the gain of the operational amplifier and the circuit characteristics, Iin refers to the temperature-compensated input current signal, b refers to a constant used to correct signal offset and ensure that the starting point of the logarithmic conversion is not zero, and c refers to an offset constant used to adjust the reference value of the output voltage.
[0046] Specifically, through the above formula, the temperature-compensated input signal Iin is first fed into the circuit as an input signal. Inside the circuit, the temperature compensation signal is amplified by an operational amplifier. The gain k of this amplifier, together with the circuit characteristics, acts to adjust the gain k so that the amplitude of the input signal is suitable for logarithmic operation. During the logarithmic operation, the constant b is used to correct the signal offset, ensuring that the starting point of the logarithmic conversion is not zero and avoiding inaccurate conversion results due to the offset of the signal itself. In addition, the offset constant c is used to adjust the reference value of the output voltage to ensure that the output signal matches the voltage range of the expected target. Finally, after processing the input current signal, the logarithmic operation result V is obtained. out 。
[0047] Further, assume the following values: input signal I in = 0.003 A (temperature-compensated current signal), gain k = 50, offset constant b = 0.0001 A, offset constant c = 0.2 V. Substitute these values into the formula for calculation: V out = 50·log(0.003 + 0.0001) + 0.2. The final output signal V out is -125.445 V.
[0048] In one embodiment, as Figure 5 shown, in step S40, that is, after obtaining the linearized signal, the absorption information of the interfering gas is acquired using a multi-optical path system. The absorption information of the interfering gas is analyzed through an interfering gas absorption spectrum model to analyze the absorption characteristics of the interfering gas and obtain the absorption contribution information of the interfering gas, including: S401: Acquire the absorption signals of the interfering gas in multiple spectral bands through the multi-optical path system, and filter the absorption signals in multiple spectral bands according to a preset absorption wavelength range to obtain the absorption information of the interfering gas.
[0049] In this embodiment, the multi-optical path system refers to a system that can measure the gas absorption information simultaneously through multiple independent optical paths. Specifically, the multi-optical path system includes multiple different light sources and detectors. Each optical path corresponds to a specific spectral band, and these optical paths can measure the gas from multiple angles and wavelengths through different absorption characteristics. These optical paths work in parallel inside the sensor, can emit light of different wavelengths respectively, and receive the transmitted light or reflected light after passing through the gas sample at the corresponding wavelengths, and use multiple detectors to measure the absorption signals at these wavelengths respectively.
[0050] Specifically, first, the multi-optical path system emits light beams through a set of light sources with different wavelengths. These light beams pass through the interfering gas and penetrate its absorption region, and part of the energy of the light beams will be absorbed by the interfering gas. Since different gas molecules have different absorption characteristics for light of different wavelengths, the NDIR sensor can receive the light signals absorbed by the interfering gas within multiple predetermined wavelength ranges. Multiple detectors configured in the sensor receive signals in different spectral bands respectively, obtaining the absorption signals of the interfering gas in multiple bands. To improve the detection accuracy, the sensor screens and filters the signals of multiple spectral bands received according to the preset absorption wavelength range, only retaining the absorption signals of the interfering gas within these wavelength ranges. For example, certain bands may be mainly used to detect the absorption characteristics of specific gases, while other bands may not be suitable for the detection of the target gas. Through this wavelength filtering method, irrelevant spectral signals are removed. After the filtering process, the finally obtained absorption signal is the true absorption information of the interfering gas within the specified wavelength range.
[0051] S402: Use the statistical analysis method in the absorption spectrum model of the interfering gas to fit the absorption information of the interfering gas, and extract the absorption intensity information of the interfering gas.
[0052] Specifically, after the absorption information of the interfering gas is obtained through the multi-optical path system, this information is input into the absorption spectrum model of the interfering gas. The model contains multiple absorption spectrum features and parameters, which can describe the absorption characteristics of different gas molecules in each band. Through statistical analysis methods, such as the least squares method or the maximum likelihood estimation, data fitting is performed. The fitting process will compare the actually collected absorption signals with the preset absorption characteristics in the model. During this fitting process, the model will take into account the noise, interference, and measurement errors in the spectral signals, and by adjusting the parameters in the model, minimize the gap between the absorption signals predicted by the model and the actual measured values. At this time, different statistical methods may also be used in the fitting process to optimize the fitting effect. For example, the weighted least squares method is used to give higher weights to the absorption signals for more accurate fitting, or the regularization method is used to avoid overfitting. Finally, the fitting result will extract the absorption intensity information of the interfering gas in multiple bands.
[0053] S403: Obtain the real-time environmental information. Based on the real-time environmental information, correct the absorption intensity information of the interfering gas through the information correction algorithm in the absorption spectrum model of the interfering gas to obtain the absorption contribution information of the interfering gas.
[0054] In this embodiment, the correction algorithm refers to an algorithm based on the relationship between environmental changes and the absorption characteristics of interfering gases. The correction algorithm is used to correct the absorption intensity information of interfering gases in real time to reduce the influence of environmental factors on the measurement results of the NDIR sensor. Specifically, the correction algorithm calculates an adjustment factor that adapts to environmental changes by considering the influence of environmental factors such as temperature, humidity, and air pressure on the gas absorption wavelength.
[0055] Specifically, obtaining real-time environmental information means obtaining factors such as the temperature, humidity, and air pressure of the current environment that affect the gas absorption characteristics through environmental sensors. These environmental factors may have a certain impact on the absorption characteristics of interfering gases, thereby affecting the measurement results of the NDIR sensor. Therefore, real-time monitoring is required. Real-time environmental information can be dynamically collected by integrating devices such as temperature sensors, humidity sensors, and air pressure sensors, and a real-time environmental status report can be generated based on the collected environmental data. Based on the real-time environmental information, the absorption intensity information of interfering gases is corrected through the information correction algorithm in the interfering gas absorption spectrum model. First, it is necessary to correct the absorption intensity of interfering gases by combining the established mathematical relationship between the environment and absorption characteristics with the real-time obtained environmental data. The specific correction process includes: using the environmental information and the known model of the influence of the environment on gas absorption characteristics to calculate the adjustment factor of the absorption intensity of interfering gases under specific environmental conditions; then, using this adjustment factor to perform weighted correction on the absorption intensity data of interfering gases to eliminate the absorption signal fluctuations caused by environmental changes. The corrected absorption intensity information is the absorption contribution information of interfering gases.
[0056] In one embodiment, as Figure 6 shown, in step S402, that is, using the statistical analysis method in the interfering gas absorption spectrum model to fit the absorption information of interfering gases and extract the absorption intensity information of interfering gases, including: S4021: Compare the absorption information of interfering gases with the preset absorption characteristics in the interfering gas absorption spectrum model to obtain a preliminary fitting error.
[0057] Specifically, to compare the absorption information of the interfering gas with the preset absorption characteristics in the interfering gas absorption spectrum model, it is first necessary to obtain the absorption signals of the interfering gas in multiple spectral bands from the multi-optical path system of the NDIR sensor. These absorption signals represent the degree of light absorption by the interfering gas at different wavelengths, and the absorption characteristics of each gas exhibit different absorption intensities at different wavelengths. Therefore, by measuring the absorption information in these bands, the concentration and characteristics of the interfering gas can be inferred. The preset absorption characteristics were constructed from the absorption intensity data measured under different environmental conditions based on the theoretical model or historical data of the interfering gas in early experiments. These absorption intensity data include the typical absorption spectra of the interfering gas at the preset wavelengths. These data are usually stored in the absorption spectrum database to form the interfering gas absorption spectrum model. The interfering gas absorption spectrum model contains multiple preset absorption peaks, and each absorption peak corresponds to a specific wavelength range, indicating the strong absorption of the gas molecules to the light in this band. After obtaining the absorption signals of the interfering gas, these signals need to be matched with the preset absorption characteristics. First, the measured absorption signals need to be divided into the corresponding spectral bands according to the wavelength and aligned with the preset wavelength ranges in the interfering gas absorption spectrum model. When comparing, the matching is mainly evaluated by calculating the difference between the absorption signals of the interfering gas and the preset absorption characteristics, and this difference is called the preliminary fitting error.
[0058] Furthermore, the specific method for calculating the fitting error generally uses statistical methods. For example, the least squares method can be used to evaluate the fitting error. The least squares method measures the fitting accuracy by calculating the sum of the squared differences between the signal and the model. If the fitting error is small, it indicates that the measured absorption signals of the interfering gas are relatively consistent with the preset absorption characteristics in the model, and the fitting effect of the model is good. On the contrary, if the error is large, it means that there is a large deviation between the actual absorption signal and the absorption signal predicted by the model, which may imply problems such as measurement errors, changes in environmental conditions, or the inapplicability of model parameters to the current conditions. In addition, if the fitting error is large, it is necessary to further analyze according to the real-time environmental conditions and adjust the model. It may be necessary to retrain the absorption spectrum model or correct the existing model. The correction process may involve adjusting the model parameters, such as adjusting the absorption peaks and smoothing the absorption characteristic curves, to ensure that the model can better adapt to the actual measurement data.
[0059] S4022: Through statistical analysis methods, statistically fit the absorption information of the interfering gas according to the preliminary fitting error to obtain the absorption intensity information of the interfering gas.
[0060] Specifically, first, after obtaining the absorption information of the interfering gas, the fitting error calculation needs to be carried out. At this time, the preliminary fitting error refers to the difference between the absorption information of the interfering gas and the preset absorption spectrum of the model. In order to obtain accurate absorption intensity information, the least squares method in statistical analysis is used for error fitting. The basic idea of the least squares method is to minimize the error between the result output by the model and the actual measurement signal by adjusting the parameters. In actual operation, first, an error function needs to be defined. Usually, the error function is the sum of the squares of the residuals. Let y i be the absorption intensity value predicted by the model, and x i be the actual measured absorption signal. The error function E is: Next, the gradient descent method or other optimization algorithms (such as Newton's method) are used to minimize this error function. Specifically, the gradient descent method iteratively adjusts the model parameters, such as the spectral wavelength range, absorption coefficient, etc., until the error value drops to the lowest. After each iteration, the prediction error under the current parameter setting is calculated, and the parameters are updated according to the gradient until the error converges to a predetermined threshold. To improve the fitting accuracy, the weighted least squares method can also be used, applying different weights to different measurement points. This is because there may be different degrees of noise or measurement errors in different spectral bands, and weighting can effectively suppress the influence of data with larger errors on the results. During the fitting process, background correction also needs to be performed on the absorption spectrum of the interfering gas. If the absorption signal is interfered by other environmental factors (such as temperature, humidity, etc.), the absorption information needs to be further adjusted through the aforementioned temperature compensation or other environmental correction algorithms to ensure the accuracy of the fitting process. Finally, through repeated iterative optimization, a set of fitting parameters that best match the actual measurement conditions are obtained, and then the absorption intensity information of the interfering gas is obtained.
[0061] In one embodiment, as Figure 7 shown, in step S50, that is, according to the absorption contribution information of the interfering gas, the absorption influence of the interfering gas is deducted from the linearized signal to obtain the target gas concentration information, including: S501: Determine the absorption intensity information of the interfering gas based on the absorption contribution information of the interfering gas.
[0062] Specifically, the established absorption spectrum model is used to calculate the absorption intensity in different bands. The absorption spectrum model is based on the absorption characteristics of the gas in each band and usually includes factors such as the intensity attenuation of the optical path and the wavelength response. Through these factors, the contribution information can be converted into a quantitative absorption intensity. During the calculation process, first, the contribution values of each spectral band are extracted, and these contribution values represent the degree of influence of this band on the absorption signal in the sensor measurement. Next, these contribution values are weighted and combined with the absorption intensity coefficients of different wavelengths to determine the contribution of each band to the absorption intensity of the interfering gas. These coefficients can be obtained through experiments or by referring to known absorption spectrum libraries of interfering gases. For example, for a specific interfering gas, it has strong absorption characteristics in certain bands of the infrared spectrum and weak absorption in other bands. Therefore, the model outputs the absorption intensity of each band by analyzing the absorption contributions of each band and combining the actual measurement values. Finally, the system integrates the absorption intensities of these bands into an overall absorption intensity information S502: Match the absorption intensity information with the absorption characteristics in the absorption spectrum model of the interfering gas, calculate the contribution of the interfering gas to the signal at the preset wavelength, obtain the interference signal, and subtract the interference signal from the linearized signal to obtain the net signal.
[0063] Specifically, compare the absorption intensity information obtained in the previous step with the absorption spectrum model of the interfering gas to accurately calculate the influence of the interfering gas on the optical signal. The absorption spectrum model contains the absorption characteristics of the interfering gas at different wavelengths, and these characteristics can help determine the specific influence of the absorption intensity of the interfering gas on the signal at a specific wavelength. Input the absorption intensity information of the interfering gas into the established absorption spectrum model of the interfering gas for wavelength matching. The absorption spectrum model contains the spectral absorption characteristics of different interfering gases in different bands, and these characteristics are provided by experimental data or existing literature. For each specific wavelength, the model will output the absorption intensity of the interfering gas in this band and the corresponding absorption characteristics. In this way, the contribution of the interfering gas to the optical signal at the preset wavelength can be calculated. For example, assume that the absorption characteristics of the interfering gas are strong in a certain specific wavelength range. In these wavelength bands, the interfering gas will significantly absorb the passing infrared optical signal, resulting in a decrease in the signal intensity. To compensate for this influence, the system calculates the absorption signal of the interfering gas based on the absorption intensity information in this wavelength range and the absorption characteristics in the model. This calculation usually uses numerical fitting and integration methods to quantify the absorption intensity of the interfering gas in this band, thereby obtaining the interference signal in this band. Next, subtract these interference signals from the obtained linearized signal. By this method, the influence of the interfering gas on the signal can be eliminated. The subtraction operation is usually completed by simple subtraction, subtracting the interference signal from the original linearized signal to obtain the net signal. The net signal is the optical signal after removing the influence of the interfering gas and can more accurately reflect the concentration information of the target gas.
[0064] S503: Compare the net signal with the known absorption spectral characteristics of the target gas through a gas concentration conversion algorithm to obtain the target gas concentration information.
[0065] Specifically, the net signal (i.e., the signal after deducting the influence of interfering gases) is used to calculate the concentration of the target gas. First, the known absorption spectral characteristics of the target gas need to be determined in advance through experiments or literature data. The absorption spectral characteristics describe the absorption behavior of the target gas for infrared light in different wavelength ranges, that is, the absorbance of the target gas at different wavelengths. Based on these data, a relationship between the target gas concentration and its absorbance is established. In actual implementation, the gas concentration conversion algorithm compares the absorption spectral characteristics of the target gas with the net signal. Specifically, the intensity change of each wavelength in the net signal represents the absorption contribution of the target gas at that wavelength. Therefore, the concentration of the target gas can be deduced by fitting or comparing with the known absorption spectral characteristics of the target gas. For example, each absorption peak (change in wavelength) in the net signal corresponds to a specific absorption characteristic in the absorption spectrum of the target gas. By calculating the difference in absorbance between the net signal and the absorption spectrum of the target gas, the concentration of the target gas can be obtained. To implement this conversion process, a gas concentration conversion algorithm (such as the least squares fitting method, Bayesian inference method, etc.) is usually used to establish a mathematical relationship between the signal and the concentration. The algorithm calculates the absorbance values of the target gas at different concentrations through the input net signal and known absorption spectral characteristics, and compares them with the absorbance obtained from the net signal to finally obtain the concentration of the target gas. For example, in practical applications, the system may fit the characteristic peaks in the absorption spectrum of the target gas, use the corresponding intensity values of these peaks in the net signal, and apply the known concentration-absorbance relationship formula to calculate the actual concentration value of the target gas. This process involves comparison and calculation, and the algorithm can be appropriately adjusted and optimized according to different gas types, environmental conditions, and specific spectral characteristics to ensure high measurement accuracy.
[0066] It should be understood that the magnitudes of the sequence numbers of the steps in the above embodiments do not mean the order of execution. The execution order of each process should be determined according to its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present application.
[0067] In one embodiment, a device for improving the measurement accuracy of an NDIR sensor is provided. This device for improving the measurement accuracy of an NDIR sensor corresponds one-to-one with the method for improving the measurement accuracy of an NDIR sensor in the above embodiment. As Figure 9As shown in the figure, the device for improving the measurement accuracy of the NDIR sensor includes an ambient temperature information acquisition module, an NDIR sensor signal circuit adjustment module, a linearized signal processing module, an interference gas absorption contribution analysis module, and a gas concentration reporting module. The detailed descriptions of each functional module are as follows: The ambient temperature information acquisition module is used to acquire ambient temperature information; The NDIR sensor signal circuit adjustment module is used to adjust the current and voltage in the signal processing circuit of the NDIR sensor according to the ambient temperature information, and generate a temperature-compensated signal; The linearized signal processing module is used to perform nonlinear correction on the temperature-compensated signal by using a linearized circuit composed of an operational amplifier and a nonlinear element, and output a linearized signal; The interference gas absorption contribution analysis module is used to, after obtaining the linearized signal, acquire the absorption information of the interference gas by using a multi-path system, analyze the absorption information of the interference gas through an interference gas absorption spectrum model, analyze the absorption characteristics of the interference gas, and obtain the absorption contribution information of the interference gas; The gas concentration reporting module is used to, according to the absorption contribution information of the interference gas, deduct the absorption influence of the interference gas from the linearized signal, obtain the target gas concentration information, and generate a gas concentration report based on the target gas concentration information.
[0068] Optionally, the NDIR sensor signal circuit adjustment module includes: The temperature current adjustment sub-module is used to adjust the current in the signal processing circuit according to the ambient temperature information through the change in the resistance value of a positive temperature coefficient thermistor, and obtain the processed current; The voltage regulation sub-module is used to, based on the processed current, adjust the gain setting in the voltage source or the operational amplifier, automatically adjust the voltage in the signal processing circuit, and obtain the processed voltage; The temperature compensation signal generation sub-module is used to use the processed current and the processed voltage as the temperature-compensated signal.
[0069] Optionally, the NDIR sensor signal circuit adjustment module includes: The logarithmic processing sub-module is used to perform a logarithmic operation on the temperature-compensated signal by using a linearized circuit composed of an operational amplifier and a nonlinear element, and obtain the logarithmic operation result; The gain adjustment sub-module is used to, according to the logarithmic operation result, convert the temperature-compensated signal into a linearized signal by adjusting the gain of the operational amplifier.
[0070] Optionally, the logarithmic processing sub-module includes: The logarithmic operation unit is used to perform a logarithmic operation on the temperature-compensated signal by the linearized circuit based on the following formula: Vou t = k·log(I in + b) + c, where Vout refers to the result of the logarithmic operation, k refers to the gain of the operational amplifier and the circuit characteristics, Iin refers to the input current signal after temperature compensation, b refers to a constant used to correct signal offset and ensure that the starting point of the logarithmic conversion is not zero, and c refers to an offset constant used to adjust the reference value of the output voltage.
[0071] Optionally, the interference gas absorption contribution analysis module includes: An absorption signal filtering sub-module for obtaining the absorption signals of the interference gas in multiple spectral bands through a multi-optical path system, and filtering the absorption signals of the multiple spectral bands according to a preset absorption wavelength range to obtain the absorption information of the interference gas; An absorption information fitting sub-module for fitting the absorption information of the interference gas by using the statistical analysis method in the interference gas absorption spectrum model to extract the absorption intensity information of the interference gas; An absorption information correction sub-module for obtaining real-time environmental information, and based on the real-time environmental information, correcting the absorption intensity information of the interference gas through the information correction algorithm in the interference gas absorption spectrum model to obtain the absorption contribution information of the interference gas.
[0072] Optionally, the absorption information fitting sub-module includes; A fitting error calculation unit for comparing the absorption information of the interference gas with the preset absorption characteristics in the interference gas absorption spectrum model to obtain a preliminary fitting error; An absorption information statistical fitting unit for statistically fitting the absorption information of the interference gas according to the preliminary fitting error by using a statistical analysis method to obtain the absorption intensity information of the interference gas.
[0073] Optionally, the gas concentration reporting module includes: An interference gas absorption intensity determination sub-module for determining the absorption intensity information of the interference gas based on the absorption contribution information of the interference gas; An interference signal subtraction sub-module for matching the absorption intensity information with the absorption characteristics in the interference gas absorption spectrum model, calculating the contribution of the interference gas to the signal at a preset wavelength to obtain an interference signal, and subtracting the interference signal from the linearized signal to obtain a net signal; A gas concentration conversion sub-module for comparing the net signal with the known absorption spectrum characteristics of the target gas through a gas concentration conversion algorithm to obtain the target gas concentration information.
[0074] For the specific limitations of the device for improving the measurement accuracy of the NDIR sensor, reference can be made to the limitations of the method for improving the measurement accuracy of the NDIR sensor in the foregoing text, which will not be elaborated herein. Each module in the above device for improving the measurement accuracy of the NDIR sensor can be implemented in whole or in part by software, hardware, and their combination. Each of the above modules can be embedded in the processor of the computer device in hardware form or be independent of it, or can be stored in the memory of the computer device in software form, so as to facilitate the processor to call and execute the operations corresponding to each of the above modules.
[0075] In one embodiment, a computer device is provided. The computer device can be a server, and its internal structure diagram can be as Figure 8 shown. The computer device includes a processor, a memory, a network interface, and a database connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store an absorption spectrum database. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, it implements a method for improving the measurement accuracy of the NDIR sensor.
[0076] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored on the memory and executable on the processor. When the processor executes the computer program, the following steps are implemented: Obtain ambient temperature information; According to the ambient temperature information, adjust the current and voltage in the signal processing circuit of the NDIR sensor to generate a temperature-compensated signal; Use a linearization circuit composed of an operational amplifier and a nonlinear element to perform nonlinear correction on the temperature-compensated signal and output a linearized signal; After obtaining the linearized signal, use a multi-optical path system to obtain the absorption information of the interfering gas, analyze the absorption information of the interfering gas through an interfering gas absorption spectrum model, analyze the absorption characteristics of the interfering gas, and obtain the absorption contribution information of the interfering gas; according to the absorption contribution information of the interfering gas, deduct the absorption influence of the interfering gas from the linearized signal to obtain the target gas concentration information, and generate a gas concentration report based on the target gas concentration information.
[0077] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by the processor, the following steps are implemented: Obtain ambient temperature information; Adjust the current and voltage in the signal processing circuit of the NDIR sensor according to the ambient temperature information to generate a temperature-compensated signal; Use a linearization circuit composed of an operational amplifier and a non-linear element to perform non-linear correction on the temperature-compensated signal and output a linearized signal; After obtaining the linearized signal, use a multi-optical path system to obtain the absorption information of the interfering gas, analyze the absorption information of the interfering gas through the absorption spectrum model of the interfering gas, analyze the absorption characteristics of the interfering gas, and obtain the absorption contribution information of the interfering gas; According to the absorption contribution information of the interfering gas, subtract the absorption influence of the interfering gas from the linearized signal to obtain the target gas concentration information, and generate a gas concentration report based on the target gas concentration information.
[0078] Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be completed by instructing relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above methods. Among them, any reference to a memory, storage, database or other medium used in the various embodiments provided in the present application can include non-volatile and / or volatile memories. Non-volatile memories can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memories can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.
[0079] Those skilled in the art can clearly understand that for the convenience and simplicity of description, only the above-mentioned division of each functional unit and module is used as an example. In actual applications, the above functions can be allocated to different functional units and modules according to needs, that is, the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above.
[0080] The above-described embodiments are only used to illustrate the technical solutions of the present application, rather than to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions recorded in the foregoing embodiments, or perform equivalent replacements on some of the technical features; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included within the protection scope of the present application.
Claims
1. A method for improving the measurement accuracy of an NDIR sensor, characterized in that, The method for improving the measurement accuracy of the NDIR sensor includes: Obtaining ambient temperature information; Adjusting the current and voltage in the signal processing circuit of the NDIR sensor according to the ambient temperature information to generate a temperature-compensated signal; Performing non-linear correction on the temperature-compensated signal using a linearization circuit composed of an operational amplifier and a non-linear element, and outputting a linearized signal; After obtaining the linearized signal, using a multi-optical path system to obtain the absorption information of the interfering gas, analyzing the absorption information of the interfering gas through the interfering gas absorption spectrum model, analyzing the absorption characteristics of the interfering gas, and obtaining the absorption contribution information of the interfering gas; According to the absorption contribution information of the interfering gas, deducting the absorption influence of the interfering gas from the linearized signal to obtain the target gas concentration information, and generating a gas concentration report based on the target gas concentration information.
2. The method for improving the measurement accuracy of the NDIR sensor according to claim 1, wherein, The adjusting the current and voltage in the signal processing circuit of the NDIR sensor according to the ambient temperature information to generate a temperature-compensated signal includes: Adjusting the current in the signal processing circuit according to the change in the resistance value of the positive temperature coefficient thermistor based on the ambient temperature information to obtain a processed current; Based on the processed current, adjusting the gain setting in the voltage source or operational amplifier to automatically adjust the voltage in the signal processing circuit to obtain a processed voltage; Taking the processed current and the processed voltage as the temperature-compensated signal.
3. The method for improving the measurement accuracy of the NDIR sensor according to claim 1, characterized in that, The performing non-linear correction on the temperature-compensated signal using a linearization circuit composed of an operational amplifier and a non-linear element, and outputting a linearized signal includes: Performing a logarithmic operation on the temperature-compensated signal through a linearization circuit composed of the operational amplifier and the non-linear element to obtain a logarithmic operation result; According to the logarithmic operation result, converting the temperature-compensated signal into the linearized signal by adjusting the gain of the operational amplifier.
4. The method for improving the measurement accuracy of the NDIR sensor according to claim 3, wherein, The performing a logarithmic operation on the temperature-compensated signal through a linearization circuit composed of the operational amplifier and the non-linear element to obtain a logarithmic operation result includes: The linearization circuit performs a logarithmic operation on the temperature-compensated signal based on the following formula: V out = k·log(I in + b)+ c, where the V out refers to the result of the logarithmic operation, the k refers to the gain of the operational amplifier and the circuit characteristics, the I in refers to the input current signal after temperature compensation, the b refers to a constant used to correct signal offset and ensure that the starting point of the logarithmic conversion is not zero, and the c refers to an offset constant used to adjust the reference value of the output voltage.
5. The method for improving the measurement accuracy of the NDIR sensor according to claim 1, wherein The after obtaining the linearized signal, using a multi-optical path system to obtain the absorption information of the interfering gas, analyzing the absorption information of the interfering gas through the interfering gas absorption spectrum model, analyzing the absorption characteristics of the interfering gas, and obtaining the absorption contribution information of the interfering gas includes: Obtaining the absorption signals of the interfering gas in multiple spectral bands through the multi-optical path system, and filtering the absorption signals in multiple spectral bands according to a preset absorption wavelength range to obtain the absorption information of the interfering gas; Fitting the absorption information of the interfering gas using the statistical analysis method in the interfering gas absorption spectrum model to extract the absorption intensity information of the interfering gas; Obtaining real-time environmental information, and based on the real-time environmental information, correcting the absorption intensity information of the interfering gas through the information correction algorithm in the interfering gas absorption spectrum model to obtain the absorption contribution information of the interfering gas.
6. The method for improving the measurement accuracy of the NDIR sensor according to claim 5, characterized in that, Fitting the absorption information of the interfering gas by using the statistical analysis method in the interfering gas absorption spectrum model to extract the absorption intensity information of the interfering gas, including: Comparing the absorption information of the interfering gas with the preset absorption characteristics in the interfering gas absorption spectrum model to obtain a preliminary fitting error; Performing statistical fitting on the absorption information of the interfering gas according to the preliminary fitting error by using the statistical analysis method to obtain the absorption intensity information of the interfering gas.
7. The method for improving the measurement accuracy of the NDIR sensor according to claim 1, characterized in that Deducting the absorption influence of the interfering gas from the linearized signal according to the absorption contribution information of the interfering gas to obtain the target gas concentration information, including: Determining the absorption intensity information of the interfering gas based on the absorption contribution information of the interfering gas; Matching the absorption intensity information with the absorption characteristics in the interfering gas absorption spectrum model, calculating the contribution of the interfering gas to the signal at a preset wavelength to obtain an interference signal, and deducting the interference signal from the linearized signal to obtain a net signal; Comparing the net signal with the known absorption spectrum characteristics of the target gas through the gas concentration conversion algorithm to obtain the target gas concentration information.
8. A device for improving the measurement accuracy of an NDIR sensor, characterized in that, The device for improving the measurement accuracy of the NDIR sensor includes: An ambient temperature information acquisition module for acquiring ambient temperature information; An NDIR sensor signal circuit adjustment module for adjusting the current and voltage in the signal processing circuit of the NDIR sensor according to the ambient temperature information to generate a temperature-compensated signal; A linearized signal processing module for performing nonlinear correction on the temperature-compensated signal by using a linearization circuit composed of an operational amplifier and a nonlinear element and outputting a linearized signal; An interfering gas absorption contribution analysis module for, after obtaining the linearized signal, acquiring the absorption information of the interfering gas by using a multi-path system, analyzing the absorption information of the interfering gas through the interfering gas absorption spectrum model, analyzing the absorption characteristics of the interfering gas, and obtaining the absorption contribution information of the interfering gas; A gas concentration reporting module for deducting the absorption influence of the interfering gas from the linearized signal according to the absorption contribution information of the interfering gas to obtain the target gas concentration information, and generating a gas concentration report according to the target gas concentration information.
9. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, the steps of the method for improving the measurement accuracy of the NDIR sensor according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium storing a computer program, characterized in that, When the computer program is executed by the processor, the steps of the method for improving the measurement accuracy of the NDIR sensor according to any one of claims 1 to 7 are implemented.