A method and system for measuring gas concentration by identifying unknown gas characteristics
By identifying unknown gas characteristics and incorporating them into the known gas characteristic library, the problem of unknown gas interference in industrial exhaust gases is solved, and the accuracy and accuracy of the gas measurement system are significantly improved.
Patent Information
- Application Number
- CN202211656520.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-12-22
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2042-12-22
AI Technical Summary
When detecting industrial exhaust gases, it is difficult to effectively identify and eliminate the interference of unknown gases on measurement accuracy, resulting in the impact of the accuracy and accuracy of the measurement system.
By identifying unknown gas characteristics, a square loss function model is constructed using known gas characteristics and mixed gas characteristics, unknown gas characteristics are obtained through learning training, and added to the known gas characteristic library to perform gas concentration inversion calculation.
Maximize the impact of unknown gases on measurement accuracy and improve the accuracy and accuracy of the gas measurement system.
Smart Images

Figure CN115791663B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a method and a system for measuring gas concentration by identifying unknown gas characteristics, and belongs to the technical field of gas concentration detection. Background Art
[0002] Spectral detection technology is widely used in the monitoring of water quality, air and soil in the field of environment in my country, especially for the detection of industrial pollutant gas concentration. This measurement method is not only fast and simple, but also has relatively accurate detection results. However, in actual applications, in addition to the known pollutants that need to be measured, industrial emissions also contain many unknown gases, which causes absorption spectrum overlap and serious cross-interference, greatly affecting the accuracy of the measurement system.
[0003] In order to solve the above problems, the existing technology mainly uses filtering methods or mathematical algorithms to eliminate the interference of unknown gases on measurement accuracy. The filtering method refers to letting the gas pass through a certain filter before entering the measurement cell, and using chemical reactions to filter out some gases that do not need to be detected, such as a dehydrogenator. However, this method can only filter specific known gases and still cannot identify the remaining unknown gases. Commonly used mathematical algorithms include compensation methods and correction methods, such as least squares method, regression method, support vector machine, etc. Least squares method and regression method are not robust and have poor inversion accuracy. They are easily affected by singular points. Support vector machines have high sample requirements. These algorithms are only effective for specific gases in specific scenarios and cannot completely eliminate the impact of unknown interfering gases on system accuracy. Summary of the invention
[0004] To overcome the deficiencies of the prior art, the present invention provides a method and system for measuring gas concentration by identifying unknown gas characteristics, which can eliminate the influence of unknown interfering gases on gas measurement accuracy to the greatest extent and greatly improve the accuracy and precision of the gas measurement system.
[0005] A method for measuring gas concentration by identifying unknown gas characteristics comprises the following steps:
[0006] S1, pass m known gas standard samples into the measuring cell of the gas analyzer respectively, and scan the absorption spectrum of each sample in a wide spectral range to obtain the characteristic D of each sample gas i , establish a known gas characteristic library D;
[0007] S2, pass the mixed gas into the measuring cell of the gas analyzer and scan the mixed gas in a wide spectral range to obtain the characteristic d of the mixed gas. The mixed gas includes m known gases and n unknown gases. The unknown gas characteristic is defined as Du j ;
[0008] S3, define and initialize the known gas weight parameter w and the unknown gas weight parameter wu, based on the known gas characteristics D i , known gas weight parameter w, unknown gas characteristics Du j , the unknown gas weight parameter wu and the mixed gas characteristic d jointly construct the square loss function and the objective function;
[0009] S4, learn and train the parameters in the square loss function until the objective function is less than the set value or the number of learning times reaches the target number, and obtain the final unknown gas characteristic Du j ;
[0010] S5, the final unknown gas characteristics Du j Add it to the known gas characteristic library D, and obtain the concentration of the gas to be measured in the mixed gas by gas concentration inversion calculation.
[0011] Furthermore, the square loss function described in step S3 is defined as follows:
[0012]
[0013] And construct the objective function min(θ) based on the square loss function.
[0014] Furthermore, in step S2, the unknown gas characteristic Du j The definition is as follows:
[0015] Establish the gas characteristic function basis Φ and gas characteristic function space, define and initialize the unknown gas parameter Pu j , according to the gas characteristic function basis Φ and unknown gas parameter Pu j Construct unknown gas signature Du j .
[0016] Furthermore, according to the gas characteristic function basis Φ and the unknown gas parameter Pu j Construct unknown gas signature Du j as follows:
[0017] Du j =Pu j *Φ.
[0018] Further, the parameters in the learning and training square loss function described in step S4 are obtained until the obtained objective function is less than the set value or the number of learning times reaches the target number, and the final unknown gas characteristic Du is obtained. j , including the following steps:
[0019] S41, use iterative algorithm to learn and train weight parameters w, wu and unknown gas characteristic parameters Pu j , record the number of iterations K;
[0020] S42, determine whether the remainder of K divided by the given integer N is zero, if yes, go to step S43, if no, go to step S44;
[0021] S43. Construct unknown gas characteristics j The correlation R between the known gas feature library D j function, initialize the correlation coefficient r, and judge R j Is it greater than r? If so, reinitialize the unknown gas characteristic parameter Pu j , go to step S41; if not, go to step S44;
[0022] S44, determine whether the number of iterations K reaches the set maximum number K_max or whether the objective function min(θ) is less than the set value ε; when at least one of the above conditions is "yes", the iteration stops and the final unknown gas characteristic Du is calculated. j ; When the results of the above conditions are all "No", go to step S41 and continue learning and training.
[0023] Preferably, in step S41, the iterative algorithm is a gradient projection method with momentum.
[0024] Further, in step S43, the unknown gas characteristic Du j The correlation R between the known gas feature library D j The function is as follows:
[0025] res=(Du j *D)*(D*D) -1 *D-Du j ,
[0026]
[0027] Further, in step S5, the final unknown gas characteristic Du j Add it to the known gas characteristic library D, and use the least squares method to invert the gas concentration to obtain the concentration of the gas to be measured in the mixed gas.
[0028] A system for measuring gas concentration by identifying unknown gas characteristics adopts the above-mentioned method for measuring gas concentration by identifying unknown gas characteristics, including a light source, a measuring cell and a spectrometer, the light source is connected to the measuring cell and the spectrometer in sequence, and also includes a storage module, a learning and training module, an initialization module and an inversion module; the gas to be measured is passed into the measuring cell, and the light emitted by the light source passes through the measuring cell filled with the gas to be measured, is received by the spectrometer and converted into digital signals and respectively input into the storage module and the learning and training module; the storage module is used to store a variety of known gas characteristic data; the learning and training module is used to construct a square loss function model between the unknown gas characteristics and the known gas characteristics and perform learning and training; the initialization module is connected to the learning and training module and is used to initialize the parameter data in the function model; the final unknown gas characteristic data obtained by learning and training is input into the storage module; the inversion module is connected to the storage module and is used to calculate the concentration of the gas to be measured, and the known gas characteristic data in the storage module and the final unknown gas characteristic data obtained by calculation are input into the inversion module for inversion calculation.
[0029] The present invention provides a method and system for measuring gas concentration by identifying unknown gas characteristics, with the purpose of obtaining the gas characteristics of the unknown gas in the mixed gas, using the known gas characteristics and the mixed gas characteristics to construct a function model, and finally obtaining the unknown gas characteristics through learning and training. All unknown gases that are different from the known gas characteristics can obtain gas characteristics through this method, without being restricted by scenes and gas types; the unknown gas characteristics are incorporated into the known gas characteristic library, providing more accurate parameters for inverse calculation to obtain the concentration of each component in the mixed gas, effectively reducing the cross interference caused by spectral overlap, and eliminating the influence of unknown interfering gases on the measurement accuracy to the greatest extent, greatly improving the accuracy and precision of the measurement system. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] Figure 1 A step diagram of a method for measuring gas concentration by identifying unknown gas characteristics provided by the present invention;
[0031] Figure 2 This is a schematic diagram of a process of Embodiment 1 of the present invention;
[0032] Figure 3 A comparison diagram of an unknown gas characteristic curve obtained by applying the method in Example 1 of the present invention and an actual gas characteristic curve;
[0033] Figure 4 A comparison table of the concentrations of gases to be measured obtained in Example 1 of the present invention;
[0034] Figure 5 This is a schematic diagram of the process of Embodiment 2 of the present invention;
[0035] Figure 6A comparison diagram of two mixed unknown gas characteristic curves obtained by applying the method in Example 2 of the present invention and the actual gas characteristic curve;
[0036] Figure 7 A comparison table of the concentrations of gases to be measured obtained in Example 2 of the present invention;
[0037] Figure 8 A schematic diagram of a system for measuring gas concentration by identifying characteristics of unknown gases provided by the present invention. DETAILED DESCRIPTION
[0038] To explain the present invention more clearly, the present invention is further described below in conjunction with the accompanying drawings.
[0039] like Figure 1 As shown, a method for measuring gas concentration by identifying unknown gas characteristics comprises the following steps:
[0040] S1, pass m known gas standard samples into the measuring cell of the gas analyzer respectively, and scan the absorption spectrum of each sample in a wide spectral range to obtain the gas characteristic D of each sample i , establish a known gas characteristic library D;
[0041] S2, pass the mixed gas into the measuring cell of the gas analyzer and scan the mixed gas in a wide spectral range to obtain the characteristic d of the mixed gas. The mixed gas includes m known gases and n unknown gases. The unknown gas characteristic is defined as Du j ;
[0042] S3, define and initialize the weight w of known gases and the weight wu of unknown gases, based on the known gas characteristics D i , the weight w of known gases, the characteristics Du of unknown gases j , the unknown gas weight wu and the mixed gas feature d jointly construct the square loss function;
[0043] S4, learning training weights w and wu, until the minimum value of the square loss function is less than the set value or the number of learning times reaches the target number, and the final unknown gas characteristics Du are obtained j ;
[0044] S5, the final unknown gas characteristics Du j Add it to the known gas characteristic library D, and obtain the concentration of each component gas in the mixed gas by gas concentration inversion calculation.
[0045] This method aims to obtain the gas characteristics of unknown gases in mixed gases. A function model is constructed using known gas characteristics and mixed gas characteristics. The unknown gas characteristics are finally obtained through learning and training. All unknown gases that are different from known gas characteristics can obtain the characteristics of unknown gases through this method, which is not limited by scenes and gas types. The unknown gas characteristics are incorporated into the known gas characteristic library to provide more accurate parameters for inversion calculation to obtain the concentration of each component in the mixed gas, effectively reduce the cross-interference caused by spectral overlap, and eliminate the influence of unknown interfering gases on measurement accuracy to the greatest extent, greatly improving the accuracy and precision of the measurement system.
[0046] The square loss function in step S3 is defined as follows:
[0047]
[0048] And construct the objective function min(θ) based on the square loss function;
[0049] Among them, m represents the serial number of different known gases, and n represents the serial number of different unknown gases.
[0050] Among them, the unknown gas characteristic Du in step S2 j The definition is as follows:
[0051] Establish the gas characteristic function basis Φ and gas characteristic function space, define and initialize the unknown gas parameter Pu j , according to the gas characteristic function basis Φ and unknown gas parameter Pu j Construct unknown gas signature Du j .
[0052] Among them, the gas characteristic function basis Φ, unknown gas parameter Pu j Construct unknown gas signature Du j as follows:
[0053] Du j =Pu j *Φ.
[0054] Among them, the learning and training of each parameter in the square loss function in step S4 is performed until the obtained objective function is less than the set value or the number of learning times reaches the target number, and the final unknown gas characteristic Du is obtained. j , including the following steps:
[0055] S41, use iterative algorithm to learn and train weight parameters w, wu and unknown gas characteristic parameters Pu j , record the number of iterations K;
[0056] S42, determine whether the remainder of K divided by the given integer N is zero, if yes, go to step S43, if no, go to step S44;
[0057] S43. Construct unknown gas characteristics j The correlation R between the known gas feature library D j function, initialize the correlation coefficient r, and judge R j Is it greater than r? If so, reinitialize the unknown gas characteristic parameter Pu j , go to step S41; if not, go to step S44;
[0058] S44, determine whether the number of iterations K reaches the set maximum number K_max or whether the objective function min(θ) is less than the set value ε; when at least one of the above conditions is "yes", the iteration stops and the final unknown gas characteristic Du is calculated. j ; When the results of the above conditions are all "No", go to step S41 and continue learning and training.
[0059] In step S41, the iterative algorithm may be a gradient projection method with momentum, and other gradient descent algorithms may also be used.
[0060] In step S43, the unknown gas characteristic Du j The correlation R between the known gas feature library D j The function is as follows:
[0061] res=(Du j *D)*(D*D) -1 *D-Du j ,
[0062]
[0063] In step S5, the final unknown gas characteristic Du j Add it to the known gas feature library D, and use the least squares method to invert the concentration of the gas to be measured in the mixed gas.
[0064] like Figure 8As shown, a system for measuring gas concentration by identifying unknown gas characteristics adopts the method for measuring gas concentration by identifying unknown gas characteristics described in any of the above embodiments, including a light source, a measuring cell, a spectrometer, a storage module, a learning and training module, an initialization module and an inversion module, the light source is connected to the measuring cell and the spectrometer in sequence, the gas to be measured is passed into the measuring cell, the light source enters the spectrometer through the gas in the measuring cell, the spectrometer is used to obtain the characteristic data of the gas to be measured and input it into the storage module and the learning and training module respectively; the storage module is used to store a variety of known gas characteristic data; the learning and training module is used to construct a square loss function model between the unknown gas characteristics and the known gas characteristics and perform learning optimization training; the initialization module is connected to the learning and training module, and is used to initialize the parameter data in the function model; the learning and training module is used to perform learning and training on the parameter data in the function model; the final unknown gas characteristic data obtained by learning and training is input into the storage module; the inversion module is connected to the storage module, the known gas characteristic data in the storage module and the final unknown gas characteristic data obtained by calculation are input into the inversion module for inversion calculation.
[0065] A non-transitory computer-readable storage medium includes instructions for executing the method for measuring gas concentration by identifying unknown gas characteristics as described in any of the above embodiments.
[0066] An electronic device includes a non-transitory computer-readable storage medium; and one or more processors capable of executing the instructions of the non-transitory computer-readable storage medium.
[0067] Embodiment 2
[0068] In order to make those skilled in the art better understand the present invention, a more detailed embodiment is listed below for illustration. In this embodiment, a mixed gas consisting of two known gases SO2 and NO and one unknown gas is used as a test sample. The unknown gas used in this experiment is actually o-xylene. The characteristic curve of the unknown gas obtained by this method is compared with the characteristic curve of the actual o-xylene to verify this method.
[0069] like Figure 2 As shown, a method for measuring gas concentration by identifying unknown gas characteristics comprises the following steps:
[0070] Step 1, respectively introduce standard samples of two known gases, SO2 and NO, into the measuring cell of the gas analyzer, and scan in a wide spectral range to obtain the absorption spectrum of each sample, obtain the gas characteristic D1 of SO2 and the gas characteristic D2 of NO, and establish a known gas characteristic library D = [D1, D2];
[0071] Step 2: Pass the mixed gas into the measuring cell of the gas analyzer and scan it in a wide spectral range to obtain the characteristic d of the mixed gas. The mixed gas includes two known gases, SO2 and NO, and one unknown gas. The unknown gas characteristic is defined as Du; establish the gas characteristic function basis Φ and the gas characteristic function space, define and randomly initialize the unknown gas parameter Pu j , Pu j Obey the standard normal distribution; according to the gas characteristic function basis Φ, unknown gas parameter Pu j Construct unknown gas characteristics: Du=Pu j *Φ;
[0072] Step 3: Define and initialize the weight parameters w1, w2 of SO2 and NO and the unknown gas weight parameter wu, with the initial values of 0.01. The square loss function is constructed by the known gas features D1, D2, the known gas weights w1, w2, the unknown gas feature Du, the unknown gas weight wu and the mixed gas feature d as follows:
[0073] θ=(w1*D1+w2*D2+wu*Du-d) 2
[0074] And construct the objective function min(θ) based on the square loss function;
[0075] Step 4: Use the momentum-containing gradient projection method to learn and train the weight parameters w1 and w2 of SO2 and NO, the unknown gas weight parameter wu, and the unknown gas parameter Pu j , calculate the unknown gas characteristic Du and record the number of iterations K;
[0076] Step 5, set N to 100, and determine whether the remainder of K divided by N is zero. If yes, go to step 6, if not, go to step 7;
[0077] Step 6: Construct the correlation R between the unknown gas feature Du and the known gas feature library D as follows:
[0078]
[0079] Initialize the correlation coefficient r = 0.3, and determine whether R is greater than 0.3; if so, reinitialize the unknown gas characteristic parameter Pu j , go to step 4; if not, go to step 7;
[0080] Step 7. Set K max =5000, ε=1e-3, the number of iterations K reaches 5000, the iteration stops and the final unknown gas characteristic D is calculated. The final unknown gas characteristic curve calculated by this method is compared with the characteristic curve of actual o-xylene. Figure 3 shown.
[0081] Step 8: Add the unknown gas characteristics obtained by iterative calculation to the known gas characteristics library. According to Lambert-Beer law: d = C SO2 *D1+C NO *D2+C u *Du, using the least squares method to invert the concentration of the gas to be measured in the mixed gas, the specific formula is as follows:
[0082]
[0083] like Figure 4 As shown, in this embodiment, the concentrations of SO2 and NO of the gases to be tested are finally calculated to be 14.45% and 14.23% respectively; without obtaining the unknown gas characteristics, the concentrations of SO2 and NO directly obtained by inversion calculation are 28.84% and 18.79% respectively; the actual concentrations of SO2 and NO are 15% and 15% respectively.
[0084] Embodiment 2
[0085] In this embodiment, a mixed gas consisting of two known gases, SO2 and NO, and two unknown gases is used as a test sample. The unknown gases used in this experiment are actually NH3 and CS2. The unknown gas mixture characteristic curve obtained by this method is compared with the actual NH3 and CS2 mixture characteristic curves to further verify this method.
[0086] like Figure 5 As shown, a method for measuring gas concentration by identifying unknown gas characteristics comprises the following steps:
[0087] Step 1, respectively introduce standard samples of two known gases, SO2 and NO, into the measuring cell of the gas analyzer, and scan in a wide spectral range to obtain the absorption spectrum of each sample, obtain the gas characteristic D1 of SO2 and the gas characteristic D2 of NO, and establish a known gas characteristic library D = [D1, D2];
[0088] Step 2: Pass the mixed gas into the measuring cell of the gas analyzer and scan the mixed gas in a wide spectral range to obtain the characteristic d of the mixed gas. The mixed gas includes two known gases, SO2 and NO, and two unknown gases. The unknown gas characteristic is defined as Du; establish the gas characteristic function basis Φ and the gas characteristic function space, define and randomly initialize the unknown gas parameter Pu j , where Pu j Obey the standard normal distribution; according to the gas characteristic function basis Φ, unknown gas parameter Pu j Construct unknown gas characteristics: Du=Pu j *Φ;
[0089] Step 3: Define and initialize the weight parameters w1, w2 of SO2 and NO and the weight parameter wu of unknown gas, with the initial value of 0.01. The square loss function is constructed by the known gas characteristics D1, D2, the weight parameters w1, w2 of known gas, the unknown gas characteristic Du, the unknown gas weight parameter wu and the mixed gas characteristic d as follows:
[0090] θ=(w1*D1+w2*D2+wu*Du-d) 2
[0091] And construct the objective function min(θ) based on the square loss function;
[0092] Step 4: Use the momentum-containing gradient projection method to learn and train the weight parameters w1 and w2 of SO2 and NO, the unknown gas weight parameter wu, and the unknown gas parameter Pu j , calculate the unknown gas characteristic Du and record the number of iterations K;
[0093] Step 5, set N to 100, and determine whether the remainder of K divided by N is zero. If yes, go to step 6, if not, go to step 7;
[0094] Step 6: Construct the correlation R between the unknown gas feature Du and the known gas feature library D as follows:
[0095]
[0096] Initialize the correlation coefficient r = 0.3, and determine whether R is greater than 0.3; if so, reinitialize the unknown gas characteristic parameter Pu j , go to step 4; if not, go to step 7;
[0097] Step 7. Set K max =5000, ε=1e-3, the number of iterations K reaches 5000, the iteration stops and the final unknown gas characteristic D is calculated. In this embodiment, the gas characteristic of NH3 and CS2 mixture is obtained. The final unknown gas characteristic curve calculated by this method is compared with the actual NH3 and CS2 mixture characteristic curve. Figure 6 shown.
[0098] Step 8: Add the unknown gas characteristics obtained by iterative calculation to the known gas characteristics library. According to Lambert-Beer law, d = C SO2 *D1+C NO *D2+C u *Du, the concentration inversion formula obtained by the least squares method is as follows:
[0099]
[0100] like Figure 7As shown, in the third embodiment, the concentrations of SO2 and NO finally calculated are 18.99% and 19.18% respectively; without obtaining the unknown gas characteristics, the concentrations of SO2 and NO directly calculated by inversion are 121.03% and 231.6% respectively; the actual concentrations of SO2 and NO are 20% and 20% respectively.
[0101] According to the above two specific embodiments, it can be seen that the method provided by the present invention can obtain one unknown gas characteristic or two or more mixed unknown gas characteristics, and then add the unknown gas characteristic to the known gas characteristic library to invert the concentration of the gas to be measured. Through this method, the measured concentration of the gas to be measured is basically consistent with the actual data, which greatly improves the measurement accuracy of the gas concentration and eliminates the influence of unknown interfering gases on the measurement accuracy to the greatest extent.
[0102] The main principle of the method and system provided by the present invention is to import the mixed element characteristics and known element characteristics by constructing a function model, and then use the parameters of the learning and training characteristic elements to finally obtain the unknown element characteristics, and then perform inversion calculation after the unknown element characteristics are included in the known element characteristic library. The specific embodiments of the present application are mainly used in gas concentration measurement, and this principle can also be applied to unknown image recognition, unknown solution recognition, waveform recognition, etc., and can be applied in other fields without departing from the spirit of the present method, and can be considered to fall within the scope of protection of the present application.
[0103] Those skilled in the art will appreciate that embodiments of the present invention may be provided as methods, systems, or computer program products. Therefore, the present invention may take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product 7 implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0104] The present invention is described with reference to flowcharts and / or block diagrams of methods, devices (systems), and computer program products according to embodiments of the present invention. It should be understood that each process and / or block in the flowchart and / or block diagram, as well as the combination of processes and / or blocks in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0105] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.
[0106] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 A step that specifies a function in one or more boxes.
[0107] The present invention uses specific embodiments to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only used to help understand the method of the present invention and its core idea. At the same time, for those skilled in the art, according to the idea of the present invention, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present invention.
Claims
1. A method for measuring gas concentration by identifying unknown gas characteristics, characterized in that: The following steps are involved: S1, pass m known gas standard samples into the measuring cell of the gas analyzer respectively, and scan the absorption spectrum of each sample in a wide spectral range to obtain the characteristic D of each sample gas i , establish a known gas characteristic library D; S2, pass the mixed gas into the measuring cell of the gas analyzer and scan the mixed gas in a wide spectral range to obtain the characteristic d of the mixed gas. The mixed gas includes m known gases and n unknown gases. The unknown gas characteristic is defined as Du j ; S3, define and initialize the known gas weight parameter w and the unknown gas weight parameter wu, based on the known gas characteristics D i , known gas weight parameter w, unknown gas characteristics Du j , the unknown gas weight parameter wu and the mixed gas characteristic d jointly construct the square loss function and the objective function; wherein the square loss function is defined as follows: And construct the objective function min(θ) based on the square loss function; S4, learn and train the parameters in the square loss function until the objective function is less than the set value or the number of learning times reaches the target number, and obtain the final unknown gas characteristic Du j ; S5, the final unknown gas characteristics Du j Add it to the known gas characteristic library D, and obtain the concentration of the gas to be measured in the mixed gas by gas concentration inversion calculation.
2. The method for measuring gas concentration by identifying unknown gas characteristics according to claim 1, characterized in that: The unknown gas characteristic Du in step S2 j The definition is as follows: Establish the gas characteristic function basis Φ and gas characteristic function space, define and initialize the unknown gas parameter Pu j , according to the gas characteristic function basis Φ and unknown gas parameter Pu j Construct unknown gas signature Du j .
3. The method for measuring gas concentration by identifying unknown gas characteristics according to claim 2, characterized in that: According to the gas characteristic function basis Φ, unknown gas parameter Pu j Construct unknown gas signature Du j As follows: j =Pu j *Φ.
4. The method for measuring gas concentration by identifying unknown gas characteristics according to claim 3, characterized in that: The parameters in the learning and training square loss function described in step S4 are trained until the obtained objective function is less than the set value or the number of learning times reaches the target number, and the final unknown gas characteristic Du is obtained. j , including the following steps: S41, use iterative algorithm to learn and train weight parameters w, wu and unknown gas characteristic parameters Pu j , record the number of iterations K; S42, determine whether the remainder of K divided by the given integer N is zero, if yes, go to step S43, if no, go to step S44; S43. Construct unknown gas characteristics j The correlation R between the known gas feature library D j function, initialize the correlation coefficient r, and judge R j Is it greater than r? If so, reinitialize the unknown gas characteristic parameter Pu j , go to step S41; If not, go to step S44; S44, determine whether the number of iterations K reaches the set maximum number K_max or whether the objective function min(θ) is less than the set value ε; when at least one of the above conditions is "yes", the iteration stops and the final unknown gas characteristic Du is calculated. j ; When the results of the above conditions are all "No", go to step S41 and continue learning and training.
5. The method for measuring gas concentration by identifying unknown gas characteristics according to claim 4, characterized in that: In step S41, the iterative algorithm is a gradient projection method with momentum.
6. The method for measuring gas concentration by identifying unknown gas characteristics according to claim 5, characterized in that: In step S43, the unknown gas characteristic Du j The correlation R between the known gas feature library D j The function is as follows: res=(From j *D)*(D*D) -1 *D-Du j , 7. The method for measuring gas concentration by identifying unknown gas characteristics according to claim 6, characterized in that: In step S5, the final unknown gas characteristic Du j Add it to the known gas feature library D, and use the least squares method to invert the concentration of the gas to be measured in the mixed gas.
8. A system for measuring gas concentration by identifying unknown gas characteristics, using the method for measuring gas concentration by identifying unknown gas characteristics as claimed in any one of claims 1 to 7, comprising a light source, a measuring cell and a spectrometer, wherein the light source is connected to the measuring cell and the spectrometer in sequence, and characterized in that: It also includes a storage module, a learning and training module, an initialization module and an inversion module; the gas to be tested is passed into the measuring cell, and the light emitted by the light source passes through the measuring cell filled with the gas to be tested, is received by the spectrometer and converted into digital signals, which are respectively input into the storage module and the learning and training module; the storage module is used to store a variety of known gas characteristic data; the learning and training module is used to construct a square loss function model between unknown gas characteristics and known gas characteristics and perform learning and training; the initialization module is connected to the learning and training module and is used to initialize the parameter data in the function model; the final unknown gas characteristic data obtained by learning and training is input into the storage module; The inversion module is connected to the storage module and is used to calculate the concentration of the gas to be measured. The known gas characteristic data in the storage module and the final unknown gas characteristic data obtained by calculation are input into the inversion module for inversion calculation.
Citation Information
Patent Citations
Process of vector machine emendation model method supported by gas infrared spectrum analysis
CN101271063A
Multicomponent gas concentration quantitative analysis method based on absorption spectrogram reconstruction
CN101881727A