A gas concentration detection method based on gas chromatography overlapping peak separation

By employing asymmetric least squares baseline correction, continuous wavelet transform, and Gaussian fitting to separate overlapping peaks, the problem of overlapping peaks in complex components under gas chromatography was solved, enabling accurate quantification of gas concentrations and making it suitable for gas detection of complex components.

CN122193487APending Publication Date: 2026-06-12HENAN HANWEI ELECTRONICS

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HENAN HANWEI ELECTRONICS
Filing Date
2026-04-24
Publication Date
2026-06-12

Smart Images

  • Figure CN122193487A_ABST
    Figure CN122193487A_ABST
Patent Text Reader

Abstract

The application provides a gas concentration detection method based on gas chromatography overlapping peak separation, which comprises the following steps: performing asymmetric least squares baseline correction on an original chromatographic signal; performing continuous wavelet transform and multi-scale wavelet envelope peak positioning on the baseline-corrected chromatographic signal in sequence to obtain peak top positions; performing peak-by-peak fitting and separation on the overlapping peaks by using a physically constrained Gaussian model to obtain restored Gaussian fitting curves of each peak; performing first derivative and second derivative analysis on the Gaussian fitting curves of each peak to determine the starting point and the ending point of each peak, and constructing a local baseline function of the corresponding peak based on the starting point and the ending point; and performing integral calculation on the difference between the Gaussian fitting curve and the local baseline in the interval of the starting point and the ending point of the peak to obtain the real peak area of the target peak; and the concentration of the to-be-detected gas is calculated according to the proportional relationship between the real peak area of the target peak and the peak area of the standard gas and the concentration of the standard gas, so that the accuracy of peak position detection and the noise resistance are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the technical field of chromatographic analysis, and more particularly to a gas concentration detection method based on gas chromatography overlapping peak separation. Background Technology

[0002] Gas chromatography (GC) is an analytical technique used to separate and detect chemical components in mixtures, and it is widely used in environmental monitoring, safety testing, and other fields. This technique utilizes the differences in migration rates of different components in a mixed gas within a stationary phase (chromatographic column) to achieve component separation. The separated gases sequentially enter a detector, where they generate and acquire electrical signals. By continuously reading these electrical signals, the raw curve data of the gas chromatography analysis, i.e., the gas chromatogram, can be obtained.

[0003] In practical engineering applications such as quantitative detection of methane and ethane in natural gas leaks and concentration detection of tetrahydrothiophene in natural gas pipelines, the complex composition of natural gas can lead to situations where interfering peaks and target peaks cannot be completely separated on the stationary phase (chromatographic column). This results in overlap between interfering and target peaks in the gas chromatogram, affecting the qualitative and quantitative analysis of the target peak.

[0004] Gas chromatographic data analysis typically employs first and second derivatives to determine characteristic points, including the start, peak apex, and end point of the target peak, for accurate target peak identification. Based on the positive correlation between the peak area and the target gas concentration, the target gas concentration is calculated. For example, invention patent CN117233283A discloses an intelligent identification method for dissolved gas chromatographic spectra in transformer oil. This method utilizes differential threshold filtering to remove invalid data from the first chromatographic curve sequence, obtaining a second chromatographic curve sequence without anomalies. The second chromatographic curve sequence is then smoothed to obtain a third chromatographic curve sequence. A convolutional neural network is used to identify the first and second derivative spectra of the third chromatographic curve sequence, extracting peaks and determining their types. However, in real-world industrial scenarios such as quantitative detection of ethane at natural gas leak sites and monitoring of tetrahydrothiophene odorant concentration in natural gas pipelines, the components of the analyte gas mixture are complex, and many interfering components have retention times very close to those of the target component, making complete separation within the chromatographic column impossible. This ultimately leads to overlapping of target and interfering peaks in the chromatogram, typically manifested as back-shoulder peaks, multiple peak superposition, and overlapping positive and negative peaks. This overlapping peak problem poses a fundamental technical deficiency to existing peak identification and quantification algorithms.

[0005] The superposition effect of overlapping peaks directly interferes with the calculation results of the first and second derivatives, causing the algorithm to fail to accurately identify the true start and end points of the target peak, resulting in a significant shift in feature point determination and invalidation of the basic data for peak shape recognition. Existing technologies rely on incorrect peak start and end points to fit the baseline, resulting in a large deviation between the obtained baseline and the true baseline, which cannot be used as an effective benchmark for peak area integration. Incorrect determination of the baseline end point will directly lead to an overall shift in the baseline, thereby affecting the detection accuracy of concentration values. Summary of the Invention

[0006] To address the technical problem that existing methods cannot solve the separation and accurate quantification of overlapping peaks in complex components, this invention proposes a gas concentration detection method based on gas chromatography overlapping peak separation.

[0007] To achieve the above objectives, the technical solution of the present invention is implemented as follows:

[0008] A gas concentration detection method based on gas chromatography overlapping peak separation, comprising the following steps:

[0009] S1: Perform asymmetric least squares baseline correction on the original chromatographic signal to obtain the baseline-corrected chromatographic signal;

[0010] S2: Perform continuous wavelet transform and multi-scale wavelet envelope peak localization on the baseline-corrected chromatographic signal to obtain the peak position of all chromatographic peaks.

[0011] S3: Determine the number of Gaussian fitting peaks based on the number of peak positions, and use a physically constrained Gaussian model to fit and separate overlapping peaks one by one to obtain the restored Gaussian fitting curves of each peak.

[0012] S4: Perform first-order and second-order derivative analysis on the Gaussian fitting curves of each peak to determine the start and end points of each peak, and construct the local baseline function of the corresponding peak based on the start and end points;

[0013] S5: Within the interval between the start and end points of the peak, the difference between the Gaussian fitted curve and the local baseline is integrated to obtain the true peak area of ​​the target peak.

[0014] S6: Based on the ratio of the actual peak area of ​​the target peak to the peak area of ​​the standard gas, and in conjunction with the concentration of the standard gas, the concentration of the gas to be measured is calculated.

[0015] Furthermore, asymmetric least-squares baseline correction is performed on the original chromatographic signal, including:

[0016] S11. Construct the baseline correction objective function using an asymmetric least squares algorithm;

[0017] S12. The baseline correction objective function is solved using the iterative reweighted least squares algorithm to obtain the optimal baseline;

[0018] S13. Remove the optimal baseline from the original chromatographic signal to obtain the baseline-corrected chromatographic signal.

[0019] Furthermore, the baseline correction objective function is:

[0020] ;

[0021] in, The baseline correction objective function; For the first The original chromatographic signal of each sampling point This represents the total number of sampling points; For the first The true baseline to be determined for each sampling point; These are asymmetric weighting coefficients used to reduce the interference of peak region signals on baseline fitting. This is the smoothing coefficient, used to control the degree of smoothness of the baseline. This is a second-order difference operator used to constrain the curvature variation of the baseline. , The first , The baseline to be determined for each sampling point.

[0022] Furthermore, the baseline correction objective function is solved using an iterative reweighted least squares algorithm, specifically including:

[0023] Initialize baseline Set the value to 1 or use the original chromatographic signal;

[0024] Calculate each sampling point The residual of the current iteration k ;

[0025] Calculate and update the asymmetric weighting coefficients according to the asymmetric weighting rule. ;

[0026] The baseline correction objective function is solved using the least squares method to obtain the new baseline. ;

[0027] Repeat the iterations until the baseline converges. Or, it may reach the maximum number of iterations. This is the convergence threshold.

[0028] Furthermore, the asymmetric weighting rule is as follows:

[0029]

[0030] in, For asymmetric parameters, The threshold for the asymmetric weighting rule. Indicates the peak region. Indicates the baseline region.

[0031] Furthermore, wavelet transforms are sequentially applied to the baseline-corrected chromatographic signals, using either the discrete form of continuous wavelet transform or Discrete Wavelet Transform (DWT) for each scale. and each point in time Perform calculations to obtain the multi-scale wavelet coefficient matrix. The Mexican hat wavelet function is used as the mother wavelet basis function during wavelet transform.

[0032] Furthermore, multi-scale wavelet envelope peak localization includes:

[0033] S23. Accumulate the absolute values ​​of the multi-scale wavelet coefficients to construct the wavelet envelope function, use the wavelet envelope function to calculate the wavelet envelope function value, and generate the wavelet envelope curve based on the wavelet envelope function value;

[0034] S24. Local maxima extraction of wavelet envelope curves is performed using a sliding window search algorithm.

[0035] S25, Set noise threshold , The noise standard deviation of the baseline-corrected chromatographic signal is used to retain only envelope function values ​​greater than the noise threshold. The candidate peak vertices are selected, and spurious extreme points caused by noise are eliminated.

[0036] S26. Combine the amplitude sign of the baseline-corrected chromatographic signal to determine the positive and negative peaks, and obtain the set of peak positions.

[0037] Furthermore, a physically constrained Gaussian model is used to perform peak-by-peak fitting and separation of overlapping peaks, including:

[0038] S31. Construct a Gaussian model with physical constraints:

[0039] ;

[0040] in, The signal value of the Gaussian fitted curve. As a reference amplitude, the signal amplitude corresponding to the peak of the baseline-corrected chromatographic signal is taken. The peak position determined in step S26 Gaussian half-width, This is the fitting time constraint range;

[0041] S32. The Gaussian model is fitted and solved using the LM nonlinear least squares method to obtain the Gaussian fitting curves for each peak.

[0042] Furthermore, first-order and second-order derivative analyses were performed on the Gaussian fitting curves of each peak to determine the start and end points of each peak, including:

[0043] Gaussian fitting curve Find the first derivative ,like If the peak rises, The interval where the peak decreases is defined; the zero point of the first derivative is the peak apex.

[0044] Gaussian fitting curve Find the second derivative The zero point of the second derivative is the inflection point of the peak;

[0045] By combining the rising and falling intervals of the first derivative with the inflection points of the second derivative, the inflection point corresponding to the rising interval is determined as the peak starting point. The inflection point of the descending range is the peak end point. .

[0046] Furthermore, when constructing the local baseline function for the corresponding peak based on the starting and ending points, a linear baseline model is adopted;

[0047] When integrating the difference between the Gaussian fitted curve and the local baseline, the trapezoidal numerical integration method or the adaptive Simpson method is used to calculate the difference signal within the interval. Integrate within the range to obtain the target peak area. ;

[0048] The method for calculating the concentration of the gas to be measured is as follows:

[0049] ;

[0050] in, For standard gas peak area, This refers to the standard gas concentration.

[0051] The beneficial effects of this invention are as follows:

[0052] The method uses AsLS asymmetric least squares to replace the traditional method of calculating a univariate quadratic baseline with a misaligned starting point, actively weakening peak signal interference and calculating a smooth and realistic baseline, thus solving the baseline drift distortion problem at its root. Wavelet transform and multi-scale envelope enhancement replace the traditional first / second derivative peak finding method, improving the accuracy and noise resistance of peak position detection. Through a Gaussian fitting method with peak position constraints, overlapping peaks are automatically separated, restoring near-real single peaks and achieving effective separation of overlapping peaks. Based on the above, derivative analysis is used to determine peak boundaries, combined with integration of the real baseline to calculate the area, improving the stability of the integrated area calculation. The overall method requires no complex manual intervention and has good automation capabilities; it is suitable for complex gas component analysis and has strong engineering application value. Attached Figure Description

[0053] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0054] Figure 1 This is a flowchart of the method of the present invention.

[0055] Figure 2 The original curve and baseline are shown in the embodiments of the present invention.

[0056] Figure 3 This is a curve spectrum after baseline subtraction in an embodiment of the present invention.

[0057] Figure 4 This is a distribution diagram of the prepositioned extreme points of the wavelet transform peak position in an embodiment of the present invention.

[0058] Figure 5 This is the first positive peak of the Gaussian fitting in this embodiment of the invention.

[0059] Figure 6 This is the second positive peak of the Gaussian fitting in this embodiment of the invention.

[0060] Figure 7 The negative peak of the Gaussian fitting in this embodiment of the invention is shown. Detailed Implementation

[0061] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0062] A gas concentration detection method based on gas chromatography overlapping peak separation, such as... Figure 1 As shown, the steps include:

[0063] S1: Perform asymmetric least squares baseline correction on the original chromatographic signal, subtract the true baseline from the original chromatographic signal, and obtain the baseline-corrected chromatographic signal.

[0064] In this embodiment, the original signal comes from the detector output of the gas chromatograph and is a one-dimensional time series. , For the first The original chromatographic signal from each sampling point is measured in mV at a sampling frequency of 10 Hz (10 data points per second) for a total sampling duration of 80 seconds, resulting in a total number of sampling points L = 800. In this embodiment, the original chromatographic signal from the gas chromatograph is collected. This signal is affected by baseline drift, random noise, and multi-component overlap during actual detection. Its overall structure is a complex one, containing two positive peaks and one negative peak. The peak shapes in the original signal exhibit significant overlap and are accompanied by a noticeable sloping baseline characteristic, such as... Figure 2 As shown.

[0065] In this embodiment, the AsLS asymmetric least squares baseline correction process is the core of the entire preprocessing process. Its purpose is to eliminate baseline drift, tilt and noise interference of the original signal, obtain a pure chromatographic signal without baseline distortion, and provide a reliable data basis for subsequent peak localization and peak fitting.

[0066] In this embodiment of the application, asymmetric least-squares baseline correction is performed on the original chromatographic signal, including:

[0067] S11. The baseline correction objective function is constructed using the asymmetric least squares (AsLS) algorithm. The optimal true baseline is obtained by minimizing the baseline correction objective function. The objective function formula is as follows:

[0068] ;

[0069] in, The baseline correction objective function is denoted as . The smaller the function value, the smaller the deviation between the fitted baseline and the true baseline, and the better the fitting effect. For the first The original chromatographic signal of each sampling point This represents the total number of sampling points; For the first The true baseline to be determined for each sampling point; This is an asymmetric weighting coefficient used to weaken the interference of peak signals on baseline fitting. This value ensures that the contribution of peak signals to baseline calculation is minimized, avoiding peak shape interference with baseline fitting. This is a smoothing coefficient used to control the smoothness of the baseline, preventing drastic fluctuations or overfitting. This is a second-order difference operator used to constrain the curvature variation of the baseline, ensuring a smooth baseline without inflection points. , The first , The baseline to be determined for each sampling point.

[0070] The first part of the objective function The second part is the fitting error term, which controls the deviation between the baseline and the original signal. To smooth the constraint terms, control the curvature of the baseline, and avoid baseline distortion, the objective function achieves a correction effect of non-interference in the peak area and sufficient baseline smoothness through the synergistic effect of asymmetric weights and smoothing coefficients.

[0071] Specifically, an asymmetric weighting rule needs to be set for the asymmetric weighting coefficients, as follows:

[0072] ;

[0073] in, For asymmetric parameters, take Here, p is set to 10. -6 It represents a minimal weight for the peak region, the purpose of which is to ensure that the peak region data hardly participates in baseline fitting, thus avoiding interference from the peak signal on the baseline. The threshold for the asymmetric weighting rule is determined by calculating the mean of the original signal. and standard deviation ,Pick (k is usually taken as 1~3, and k=2 or 3 is commonly used). Areas above the threshold are considered peak areas, and areas below the threshold are considered baseline areas.

[0074] S12. The baseline correction objective function is solved using an iterative reweighted least squares algorithm to obtain the optimal baseline. :

[0075] Initialize baseline Set to 1 or retrieve the original signal;

[0076] Calculate each sampling point The residual of the current iteration k ;

[0077] Calculate and update the asymmetric weighting coefficients according to the asymmetric weighting rule. ;

[0078] The baseline correction objective function is solved using the least squares method to obtain the new baseline. ;

[0079] Repeat the iterations until the baseline converges. Or, it may reach the maximum number of iterations. This is the convergence threshold.

[0080] S13, Optimal baseline From the raw chromatographic signal After removing the negative values, the baseline-corrected chromatographic signal is obtained. :

[0081] ;

[0082] Where t represents the sampling time.

[0083] It is known that, as Figure 3 As shown, after baseline correction processing by the method of this invention, the tilted baseline in the original signal is effectively removed, the signal as a whole is restored to a stable level, random noise is initially suppressed, and the original peak structure characteristics are preserved, thus solving the core problems of traditional methods that rely on peak boundaries to calculate the baseline and baseline distortion.

[0084] S2: Perform wavelet transform and multi-scale wavelet envelope peak localization on the baseline-corrected chromatographic signal in sequence to obtain the peak position of all chromatographic peaks.

[0085] In this embodiment of the application, the baseline-corrected chromatographic signal is subjected to continuous wavelet transform sequentially, including:

[0086] S21. The Mexican cap wavelet function is selected as the mother wavelet basis function. Its shape highly matches the peak shape in gas chromatography, making it the optimal wavelet function for peak localization. The function form is as follows:

[0087] ;

[0088] in, The normalization constant ensures the energy conservation of the wavelet function. In this embodiment... Pick .

[0089] S22. Based on the Mexican hat wavelet function, the baseline-corrected chromatographic signal... Perform wavelet transform, using either the discrete form of continuous wavelet transform or discrete wavelet transform, for each scale. and each point in time Calculate convolution to obtain the multi-scale wavelet coefficient matrix. The embodiments of this application employ the discrete form of continuous wavelet transform, for each scale. and each point in time The calculation formula is:

[0090] ;

[0091] in, These are the wavelet transform coefficients. Wavelet scale, scale set M represents the total number of scales. The sampling interval is... This is the Mexican hat wavelet function after scaling and time shifting. Specifically, a scale set is selected. Covering the full range from narrow peaks to wide peaks, sampling interval It takes 0.1 seconds.

[0092] In this embodiment of the application, multi-scale wavelet envelope peak localization includes:

[0093] S23. Constructing the wavelet envelope function by accumulating the absolute values ​​of the multi-scale wavelet coefficients: For the multi-scale wavelet coefficient matrix... Each wavelet coefficient in Take the absolute value, eliminate the interference of negative coefficients, and sort by time. The envelope function value at each time point is obtained by summing the absolute values ​​of the wavelet coefficients at all scales. Based on the envelope function value at each time point, a wavelet envelope curve is generated. This curve can significantly amplify the response amplitude of the true peak, suppress the amplitude of random noise to near zero, and completely eliminate spurious peak interference. The formula is as follows:

[0094] .

[0095] S24. A sliding window search algorithm is used to extract local maxima from the wavelet envelope curve. In this embodiment, as shown in the figure, starting from time 20s, the algorithm iterates sequentially up to 80s. Taking the current time as the center, two sampling points before and after the current time are taken to form a window. It is determined whether the envelope function value within the window is the maximum value. If so, it is recorded as a candidate peak vertex.

[0096] S25, Set noise threshold , The noise standard deviation of the baseline-corrected chromatographic signal is used to retain only envelope function values ​​greater than the noise threshold. The candidate peak vertices are selected, and spurious extreme points caused by noise are eliminated.

[0097] S26, Combined with baseline-corrected chromatographic signal The amplitude sign is used to determine the positive and negative peaks, and the set of peak positions is obtained. :

[0098] If the candidate peak apex corresponds to the baseline-corrected chromatographic signal Then it is the peak;

[0099] If the candidate peak apex corresponds to the baseline-corrected chromatographic signal If the peak is negative, then it is a negative peak.

[0100] It is known that, as Figure 4 As shown, multi-scale wavelet analysis is used to process the corrected signal. By constructing a wavelet envelope curve, the true peak response can be significantly enhanced while suppressing noise interference. Based on this, analysis of the envelope curve accurately locates the peak positions, specifically the two positive peaks and one negative peak, with stable positioning results and no obvious spurious peak interference. Figure 4 As shown, this embodiment includes three peaks: the positive peak 1, =37s, peak 2, =53s, negative peak =45s, peak position pre-position extreme point distribution, solves the problems of peak position misjudgment, poor noise resistance and inability to identify negative peaks in the traditional method of directly using the first / second derivative.

[0101] S3: Determine the number of Gaussian fitting peaks based on the number of peak positions. Use a physically constrained Gaussian model to fit and separate overlapping peaks one by one, obtaining the restored Gaussian fitting curves for each peak. This step, based on accurate peak positions, uses a constrained Gaussian model to separate overlapping target peaks and interference peaks into independent single peaks, restoring the true peak shape. This step, through Gaussian fitting constrained by peak positions, completely solves the problems of inseparable overlapping peaks and peak shape distortion caused by back-shoulder peaks. The fitted peaks are infinitely close to the true peaks, providing accurate single-peak data for subsequent peak boundary determination and peak area calculation.

[0102] In this embodiment of the application, the number of Gaussian fitting peaks is determined based on the number of peak positions, and a physically constrained Gaussian model is used to perform peak-by-peak fitting and separation of overlapping peaks, including:

[0103] S30. Determine the number of Gaussian fitting peaks based on the number of elements in the peak position set. In this embodiment, there are 3 peaks, so 3 Gaussian peak models are constructed, corresponding to two positive peaks and one negative peak respectively.

[0104] S31. Construct a physically constrained Gaussian model, using a Gaussian model with reference amplitude, peak position, peak width, and fitting time constraints. The formula is:

[0105] ;

[0106] in, The signal value of the Gaussian fitted curve. As a reference amplitude, the signal amplitude corresponding to the peak of the baseline-corrected chromatographic signal is taken. The peak position determined in step S26 Given a Gaussian half-width, this embodiment preferably uses an initial value of... Gaussian half-width of chromatographic peak The relationship between the half-width at half-maximum (FWHM) and the Gaussian half-width of a conventional chromatographic peak is related to the actual width of the peak. In most chromatographic analyses, the half-width at half-maximum (WHM) of common chromatographic peaks is typically in the range of 7-10. The initial value falls within the range of 4-6. The advantages are: the initial value is close to the true value, significantly reducing the number of fitting iterations and improving computational efficiency; it avoids the initial value deviating too much, preventing the fitting from getting trapped in a local optimum, thus ensuring the stability and accuracy of the fitting; and it adapts to the morphology of most common chromatographic peaks, making it highly versatile. t represents the fitting time constraint range. The Gaussian function decays exponentially at its peak. The signal strength is high nearby, but far away The signal then rapidly approaches 0. These distant points contribute very little to the fit and introduce baseline noise. The advantage is that the main effective signal of the peak is preserved within this interval, while excluding the distant endpoints with high noise levels.

[0107] S32. The Levenberg-Marquardt (LM) nonlinear least squares method is used to fit and solve the problem, and the Gaussian fitting curves of each peak are obtained:

[0108] Initialize fitting parameters: fix peak position Set Gaussian half-width The initial value is 5, and the reference amplitude A is the signal amplitude of the peak corresponding to the baseline-corrected chromatographic signal;

[0109] Construct the fitting error function: calculate the sum of squares of the differences between the Gaussian fitting curve and the baseline-corrected chromatographic signal;

[0110] Iterative optimization: Adjusting the Gaussian half-width using the LM nonlinear least squares method The parameters are used until the error function converges;

[0111] Output Gaussian fitting curves for each peak .

[0112] It can be seen that by fitting and decomposing the two positive peaks based on the peak position detection results, the restored single-peak curve has good smoothness and symmetry, and the peak position is clear and consistent with the actual peak position in the original signal. This indicates that the method of the present invention can achieve the separation of overlapping positive peaks. The positive peak separation results are as follows: Figure 5 , 6 As shown. Similarly, after restoring the negative peak separately, its peak shape is complete and its position is accurate. The result of the negative peak restoration is as follows. Figure 7 As shown, this invention's method can effectively identify and recover negative peaks under complex interference conditions, overcoming the problem of insufficient negative peak processing capability of traditional methods. (Summary) Figures 2 to 7 The results show that the method of the present invention can still achieve stable and accurate peak position positioning and peak shape decomposition even in the presence of baseline drift, noise interference and positive and negative peak overlap, and has good robustness and engineering applicability.

[0113] S4: Perform first-order and second-order derivative analysis on the Gaussian fitting curves of each peak to determine the starting and ending points of each peak, and construct the local baseline function of the corresponding peak based on the starting and ending points.

[0114] In this embodiment of the application, the first and second derivative analyses of the Gaussian fitting curves of each peak are performed to determine the start and end points of each peak, including:

[0115] Gaussian fitting curve Find the first derivative ,like If the peak rises, The interval where the peak decreases is defined; the zero point of the first derivative is the peak apex.

[0116] Gaussian fitting curve Find the second derivative The zero point of the second derivative is the inflection point of the peak, that is, the critical point where the curve changes from convex to concave or from concave to convex, and is the core characteristic point of the peak boundary.

[0117] By combining the rising and falling intervals of the first derivative with the inflection points of the second derivative, the inflection point corresponding to the rising interval is determined as the peak starting point. The inflection point of the descending range is the peak end point. .

[0118] In this embodiment of the application, a local baseline function corresponding to the peak is constructed based on the start point and the end point, including:

[0119] Using the starting and ending points as dependent variables, and the signal values ​​of the Gaussian fitted curves corresponding to the starting and ending points as dependent variables, a linear baseline model is fitted to obtain the local baseline function. , , represents the fitting coefficient.

[0120] It is known that, based on the proposed asymmetric least squares baseline correction, continuous wavelet transform and multi-scale wavelet envelope peak localization, and physical constraint Gaussian model for peak-by-peak fitting and separation of overlapping peaks, the peak boundary localization accuracy can be effectively improved by performing first-order and second-order derivative analysis to determine the starting and ending points of each peak.

[0121] S5: Within the interval between the start and end points of the peak, the difference between the Gaussian fitted curve and the local baseline is integrated to obtain the true peak area of ​​the target peak.

[0122] In this embodiment of the application, the difference between the Gaussian fitted curve and the local baseline is integrated to obtain the true peak area of ​​the target peak, including:

[0123] The difference signal between the Gaussian fitted curve and the local baseline is calculated, and the trapezoidal numerical integration method or adaptive Simpson method is used to analyze the difference signal within the interval. Integrating within the range yields the target peak area. .

[0124] S6: Based on the ratio of the actual peak area of ​​the target peak to the peak area of ​​the standard gas, and in conjunction with the concentration of the standard gas, the concentration of the gas to be measured is calculated.

[0125] In this embodiment, the concentration of the gas to be measured is calculated based on the ratio of the actual peak area of ​​the target peak to the peak area of ​​the standard gas, combined with the concentration of the standard gas. The formula is as follows:

[0126] ;

[0127] in, For standard gas peak area, This represents the standard gas concentration.

[0128] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.

Claims

1. A gas concentration detection method based on gas chromatography overlapping peak separation, characterized in that, The steps are as follows: S1: Perform asymmetric least squares baseline correction on the original chromatographic signal to obtain the baseline-corrected chromatographic signal; S2: Perform continuous wavelet transform and multi-scale wavelet envelope peak localization on the baseline-corrected chromatographic signal to obtain the peak position of all chromatographic peaks. S3: Determine the number of Gaussian fitting peaks based on the number of peak positions, and use a physically constrained Gaussian model to fit and separate overlapping peaks one by one to obtain the restored Gaussian fitting curves of each peak. S4: Perform first-order and second-order derivative analysis on the Gaussian fitting curves of each peak to determine the start and end points of each peak, and construct the local baseline function of the corresponding peak based on the start and end points; S5: Within the interval between the start and end points of the peak, the difference between the Gaussian fitted curve and the local baseline is integrated to obtain the true peak area of ​​the target peak. S6: Based on the ratio of the actual peak area of ​​the target peak to the peak area of ​​the standard gas, and in conjunction with the concentration of the standard gas, the concentration of the gas to be measured is calculated.

2. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 1, characterized in that, Asymmetric least-squares baseline correction was performed on the raw chromatographic signal, including: S11. Construct the baseline correction objective function using an asymmetric least squares algorithm; S12. The baseline correction objective function is solved using the iterative reweighted least squares algorithm to obtain the optimal baseline; S13. Remove the optimal baseline from the original chromatographic signal to obtain the baseline-corrected chromatographic signal.

3. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 2, characterized in that, The baseline correction objective function is: ; in, The baseline correction objective function; For the first The original chromatographic signal of each sampling point This represents the total number of sampling points; For the first The true baseline to be determined for each sampling point; These are asymmetric weighting coefficients used to reduce the interference of peak region signals on baseline fitting. This is the smoothing coefficient, used to control the degree of smoothness of the baseline. This is a second-order difference operator used to constrain the curvature variation of the baseline. , The first , The baseline to be determined for each sampling point.

4. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 3, characterized in that, The baseline correction objective function is solved using an iterative reweighted least squares algorithm, specifically including: Initialize baseline Set the value to 1 or use the original chromatographic signal; Calculate each sampling point The residual of the current iteration k ; Calculate and update the asymmetric weighting coefficients according to the asymmetric weighting rule. ; The baseline correction objective function is solved using the least squares method to obtain the new baseline. ; Repeat the iterations until the baseline converges. Or, it may reach the maximum number of iterations. This is the convergence threshold.

5. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 4, characterized in that, The asymmetric weighting rule is as follows: ; in, For asymmetric parameters, The threshold for the asymmetric weighting rule. Indicates the peak region. Indicates the baseline region.

6. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 5, characterized in that, The baseline-corrected chromatographic signals were sequentially subjected to wavelet transforms, using either the discrete form of continuous wavelet transform or Discrete Wavelet Transform (DWT), for each scale. and each point in time Perform calculations to obtain the multi-scale wavelet coefficient matrix. The Mexican hat wavelet function is used as the mother wavelet basis function during wavelet transform.

7. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 6, characterized in that, Multi-scale wavelet envelope peak localization includes: S23. Accumulate the absolute values ​​of the multi-scale wavelet coefficients to construct the wavelet envelope function, use the wavelet envelope function to calculate the wavelet envelope function value, and generate the wavelet envelope curve based on the wavelet envelope function value; S24. Local maxima extraction of wavelet envelope curves is performed using a sliding window search algorithm. S25, Set noise threshold , The noise standard deviation of the baseline-corrected chromatographic signal is used to retain only envelope function values ​​greater than the noise threshold. The candidate peak vertices are selected, and spurious extreme points caused by noise are eliminated. S26. Combine the amplitude sign of the baseline-corrected chromatographic signal to determine the positive and negative peaks, and obtain the set of peak positions.

8. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 7, characterized in that, A physically constrained Gaussian model is used to perform peak-by-peak fitting and separation of overlapping peaks, including: S31. Construct a Gaussian model with physical constraints: ; in, The signal value of the Gaussian fitted curve. As a reference amplitude, the signal amplitude corresponding to the peak of the baseline-corrected chromatographic signal is taken. The peak position determined in step S26 Gaussian half-width, This is the fitting time constraint range; S32. The Gaussian model is fitted and solved using the LM nonlinear least squares method to obtain the Gaussian fitting curves for each peak.

9. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 8, characterized in that, First and second derivative analyses were performed on the Gaussian fitting curves of each peak to determine the start and end points of each peak, including: Gaussian fitting curve Find the first derivative ,like If the peak rises, The interval where the peak decreases is defined; the zero point of the first derivative is the peak apex. Gaussian fitting curve Find the second derivative The zero point of the second derivative is the inflection point of the peak; By combining the rising and falling intervals of the first derivative with the inflection points of the second derivative, the inflection point corresponding to the rising interval is determined as the peak starting point. The inflection point of the descending range is the peak end point. .

10. The gas concentration detection method based on gas chromatography overlapping peak separation according to claim 9, characterized in that, When constructing the local baseline function for the corresponding peak based on the start and end points, a linear baseline model is used; When integrating the difference between the Gaussian fitted curve and the local baseline, the trapezoidal numerical integration method or the adaptive Simpson method is used to calculate the difference signal within the interval. Integrate within the range to obtain the target peak area. ; The method for calculating the concentration of the gas to be measured is as follows: ; in, For standard gas peak area, This represents the standard gas concentration.