An intelligent determination method for food-grade triacetin
By obtaining infrared spectrum data and solution parameters, determining the characteristic wavelength and optimal offset, correcting the infrared spectrum data and establishing a regression model, the problem of inaccurate triacetin concentration measurement in the existing technology is solved and a higher accuracy is achieved. Detection accuracy and precision.
Patent Information
- Application Number
- CN202410853538.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-28
- Publication Date
- 2024-09-24
- Estimated Expiration
- 2044-06-28
AI Technical Summary
When the existing technology uses near-infrared spectroscopy technology to measure the concentration of triacetin, it is affected by impurities and complex environmental factors in the solution, resulting in changes in the position and intensity of the spectral absorption peak, which in turn affects the PCA principal component dimensionality reduction results, resulting in concentration measurement The accuracy is poor.
By obtaining the infrared spectrum data and solution parameter data of the triacetin solution, the characteristic wavelength and the optimal wavelength offset are determined, the infrared spectrum data is corrected, and the regression model and principal component linear combination coefficient are established based on the real concentration to perform concentration detection. .
It effectively eliminates the influence of complex environmental factors on spectral data, improves the accuracy and precision of triacetin concentration determination, obtains a more reliable regression model and principal component combination coefficient, and achieves accurate determination of food-grade triacetin. detection.
Smart Images

Figure FT_1 
Figure QLYQS_1 
Figure QLYQS_14
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of infrared light material analysis, and in particular to an intelligent determination method for food-grade triacetin. Background Art
[0002] Triacetin is an organic compound, mainly used as a cigarette filter adhesive, flavor fixative, solvent and plasticizer, and is widely used in tobacco, food, ink, cosmetics, casting, medicine, dye and other industries. Near infrared spectroscopy can be used to quickly and non-destructively analyze the substance concentration of triacetin, and can complete the analysis of a large number of samples in a short time, thereby improving the efficiency of detection. In the process of using near infrared spectroscopy to measure the concentration of triacetin, the prior art is to perform regression analysis based on the PCA (Principal Component Analysis) principal component dimensionality reduction results of the spectral data under all wavelengths, and then obtain the mapping relationship between the spectral data and the actual substance concentration, and realize the concentration measurement of triacetin based on the mapping relationship.
[0003] Taking into account factors such as the impurities present in the solution and the complex measurement environment, the position and intensity of the absorption peak of the substance in the obtained spectrum will be affected to a certain extent. In addition, due to the interactive influence of the absorption peaks of multiple different substances, the traditional PCA principal component dimensionality reduction will not be able to extract the absorption wavelength of triacetin well, which will in turn affect the weight coefficients at different wavelengths in the subsequent regression analysis, resulting in poor accuracy of the obtained concentration measurement. Summary of the invention
[0004] The object of the present invention is to provide an intelligent determination method of food-grade triacetin, which is used to solve the problem of inaccurate determination of triacetin concentration in the prior art.
[0005] In order to solve the above technical problems, the present invention provides an intelligent determination method of food-grade triacetin, comprising the following steps:
[0006] Acquire infrared spectrum data and different types of solution parameter data of each triacetin solution sample, wherein the different types of solution parameter data at least include actual triacetin concentration and different types of solution environment parameters;
[0007] Determine each characteristic wavelength corresponding to the infrared spectrum data of each triacetin solution sample according to the distribution of the spectral absorbance at each wavelength in the infrared spectrum data of each triacetin solution sample;
[0008] According to the difference between the solution parameter data of the same type of different triacetin solution samples, the maximum wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample is determined, and each characteristic wavelength of the infrared spectrum data of each triacetin solution sample is moved, and the movement amount of each movement is less than or equal to the corresponding maximum wavelength offset, and each moving characteristic wavelength of each movement is obtained, and each moving characteristic wavelength is compared with each characteristic wavelength of the infrared spectrum data of other triacetin solution samples to determine the optimal wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample;
[0009] According to the optimal wavelength offset, the infrared spectrum data of each triacetin solution sample is corrected to obtain the corrected infrared spectrum data of each triacetin solution sample;
[0010] The corrected infrared spectrum data of each triacetin solution sample is subjected to principal component analysis, and the regression model and the linear combination coefficients of the principal components are determined in combination with the actual triacetin concentration of each triacetin solution sample, and the concentration of the triacetin solution is detected based on the regression model and the linear combination coefficients of the principal components.
[0011] Furthermore, the characteristic wavelengths corresponding to the infrared spectrum data of each triacetin solution sample are determined, and the corresponding calculation formula is:
[0012] ;
[0013] ;
[0014] in, Indicates The spectral absorbance threshold of the infrared spectrum data of the triacetin solution samples; Indicates The average value of the spectral absorbance at each wavelength in the infrared spectrum data of the triacetin solution samples; Indicates The standard deviation of the spectral absorbance of the infrared spectrum data of the triacetin solution samples at each wavelength; Indicates adjustment parameters; Indicates A set of characteristic wavelengths corresponding to the infrared spectrum data of triacetin solution samples; Indicates In the infrared spectrum data of a triacetin solution sample, the wavelength Spectral absorbance under ; Indicates In the infrared spectrum data of a triacetin solution sample, the wavelength The adjacent wavelength Spectral absorbance under ; The neighborhood radius represents the wavelength; Indicates the wavelength shift.
[0015] Furthermore, the maximum wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample is determined, and the corresponding calculation formula is:
[0016] ;
[0017] in, Indicates The maximum wavelength shift corresponding to the infrared spectrum data of the triacetin solution sample; Indicates The first Solution parameter data; Indicates the first The average value of the solution parameter data; Indicates the first The standard deviation of the solution parameter data; Indicates the set wavelength offset; represents the number of types of solution parameter data of triacetin solution samples; Indicates the round-up symbol.
[0018] Furthermore, the optimal wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample is determined, and the corresponding calculation formula is:
[0019] ;
[0020] in, Indicates The optimal wavelength shift corresponding to the infrared spectrum data of triacetin solution samples; Represents the minimum point function; Indicates Each characteristic wavelength corresponding to the infrared spectrum data of the triacetin solution sample shifted by The corresponding moving characteristic wavelengths are obtained later; Indicates that except The first The characteristic wavelengths corresponding to the infrared spectrum data of the triacetin solution samples; express and The distance indicator; N represents the total number of triacetin solution samples; Indicates The maximum wavelength shift corresponding to the infrared spectrum data of a triacetin solution sample.
[0021] Further, confirm and Distance indicators include:
[0022] The first The mobile characteristic wavelengths corresponding to the triacetin solution samples are arranged in order of size to obtain a mobile characteristic wavelength sequence, and the mobile characteristic wavelength sequence except the first The first The characteristic wavelengths corresponding to the triacetin solution samples are arranged in order of size to obtain a characteristic wavelength sequence;
[0023] Calculate the DTW distance between the moving characteristic wavelength sequence and the characteristic wavelength sequence, and determine the DTW distance as and distance indicator.
[0024] Furthermore, the corrected infrared spectrum data of each triacetin solution sample is obtained, including:
[0025] Determine the absolute value of the optimal wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample, and determine the infrared spectrum data with the smallest absolute value as the standard spectrum data;
[0026] Calculating the difference between the optimal wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample and the optimal wavelength shift corresponding to the standard spectrum data, to obtain the actual wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample;
[0027] According to the actual wavelength shift amount, the infrared spectrum data of each triacetin solution sample is shifted left and right to obtain the corrected infrared spectrum data of each triacetin solution sample.
[0028] Furthermore, the regression model and the linear combination coefficients of each principal component are obtained, including:
[0029] In the corrected infrared spectrum data of each triacetin solution sample, the influence coefficient of any wavelength on another wavelength is determined according to the distance between any two wavelengths and the change of the wavelength corresponding spectral absorbance between any two wavelengths;
[0030] Determine the confidence of the spectral data of each wavelength according to the influence coefficient of each adjacent wavelength within the neighborhood range of each wavelength on the wavelength, and the correlation between the spectral absorbance corresponding to the same adjacent wavelength within the neighborhood range of each wavelength in the corrected infrared spectral data of each triacetin solution sample and the actual triacetin concentration of each triacetin solution sample;
[0031] According to the confidence of the spectral data, the covariance matrix corresponding to the corrected infrared spectral data of each triacetin solution sample is corrected to obtain a corrected covariance matrix, and according to the corrected covariance matrix, each principal component linear combination coefficient and each principal component of each triacetin solution sample are determined;
[0032] The principal components of each triacetin solution sample were used as independent variables, and the true triacetin concentration of each triacetin solution sample was used as the dependent variable to obtain a regression model.
[0033] Furthermore, the influence coefficient of any wavelength on another wavelength is determined, and the corresponding calculation formula is:
[0034] ;
[0035] in, Indicates wavelength For another wavelength The influence coefficient of Indicates wavelength With another wavelength The wavelength distance between them; Indicates the set wavelength distance; represents the denominator correction factor; represents the normalization function; Indicated in In the infrared spectrum data of a triacetin solution sample, along the wavelength arrive In the direction of wavelength The rate of change of spectral absorbance under represents the directional coefficient, ; N Represents the total number of triacetin solution samples.
[0036] Furthermore, the confidence level of the spectral data at each wavelength is determined, including:
[0037] In the corrected infrared spectrum data of each triacetin solution sample, the spectral absorbance at the same adjacent wavelength within the neighborhood range of the same wavelength is arranged to obtain a spectral absorbance sequence, and the real triacetin concentration of each triacetin solution sample is arranged accordingly to obtain a real triacetin concentration sequence, and a correlation index between the spectral absorbance sequence and the real triacetin concentration sequence is determined;
[0038] The confidence level of the spectrum data of each wavelength is determined according to the influence coefficient of each neighboring wavelength within the neighborhood range of each wavelength on the wavelength and the correlation index corresponding to each neighboring wavelength within the neighborhood range of each wavelength.
[0039] Furthermore, the covariance matrix corresponding to the infrared spectrum data of each triacetin solution sample is corrected to obtain a corrected covariance matrix, and the corresponding calculation formula is:
[0040] ;
[0041] ;
[0042] in, represents the corrected covariance matrix; represents the covariance matrix corresponding to the infrared spectrum data of each triacetin solution sample; The spectral absorbance at all wavelengths in the corrected infrared spectrum data of each triacetin solution sample is represented by The spectral absorbance matrix of express The transposed matrix of represents the total number of triacetin solution samples obtained; represents the number of wavelengths in the corrected infrared spectrum data of each triacetin solution sample; Represents a weight coefficient matrix composed of the confidence of the spectral data of each wavelength; Indicates wavelength Confidence of spectral data; Indicates wavelength Confidence of spectral data.
[0043] The present invention has the following beneficial effects: by considering the influence of complex environmental factors in the process of acquiring infrared spectrum data of each triacetin solution sample, firstly, according to the distribution of spectral absorbance at each wavelength in the infrared spectrum data, multiple wavelengths with better expression of triacetin concentration in different spectrum data are selected to determine each characteristic wavelength in the infrared spectrum data. Since the characteristic wavelengths of infrared spectrum data of different triacetin solution samples are different, and this characteristic wavelength difference is mainly caused by different environmental factors when measuring the easy spectrum data, in order to find the best wavelength offset in different neighborhood sizes, firstly, the difference between the same type of solution parameter data of different triacetin solution samples is analyzed, and the maximum wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample is determined, and within the neighborhood size determined by the maximum wavelength offset, the characteristic wavelength of the infrared spectrum data of each triacetin solution sample is moved, so as to screen out the best wavelength offset with a smaller difference with the characteristic wavelength of each other triacetin solution sample. Based on the optimal wavelength offset, the infrared spectral data of each triacetin solution sample is corrected so that the corrected infrared spectral data can eliminate the influence of complex environmental factors in the acquisition process of the infrared spectral data, which is conducive to obtaining an accurate regression model and each principal component linear combination coefficient through principal component analysis and combining with the corresponding actual triacetin concentration. Finally, the concentration of the triacetin solution is accurately detected based on the regression model and each principal component linear combination coefficient. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] In order to more clearly illustrate the technical solutions and advantages in the embodiments of the present invention or the prior art, the drawings required for use in the embodiments or the prior art descriptions are briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0045] Figure 1 The present invention is a flowchart of the steps of the intelligent determination method of food-grade triacetin according to an embodiment of the present invention. DETAILED DESCRIPTION
[0046] In order to further explain the technical means and effects adopted by the present invention to achieve the predetermined invention purpose, the specific implementation methods, structures, features and effects of the technical solutions proposed by the present invention are described in detail below in conjunction with the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" does not necessarily refer to the same embodiment. In addition, specific features, structures or characteristics in one or more embodiments may be combined in any suitable form.
[0047] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by those skilled in the art of the present invention. In addition, all parameters or indicators in the formulas involved in this article are normalized values that eliminate the influence of dimensions.
[0048] In order to solve the problem of inaccurate determination of existing triacetin, this embodiment provides an intelligent determination method for food-grade triacetin, and the corresponding process of the method is as follows: Figure 1 As shown, the following steps are included:
[0049] Step S1: Obtain infrared spectrum data and different types of solution parameter data of each triacetin solution sample, wherein the different types of solution parameter data at least include actual triacetin concentration and different types of solution environment parameters.
[0050] In order to obtain an accurate regression model, so as to facilitate the subsequent accurate determination of the triacetin concentration in the triacetin solution, a near-infrared spectrometer was used to obtain infrared spectral data of multiple different triacetin solution samples and different types of solution parameter data. Among them, the wavelength resolution of the spectral data is 1, the unit is nm, the horizontal axis of the spectral data is the wavelength, and the vertical axis is the spectral absorbance at the corresponding wavelength. Different types of solution parameter data refer to the actual triacetin concentration corresponding to the triacetin solution and different types of solution environmental parameters. Different types of solution environmental parameters include solution environmental parameters such as pH, solution temperature when measuring infrared spectral data, etc.
[0051] Step S2: determining each characteristic wavelength corresponding to the infrared spectrum data of each triacetin solution sample according to the distribution of the spectral absorbance at each wavelength in the infrared spectrum data of each triacetin solution sample.
[0052] After obtaining infrared spectral data of multiple different triacetin solution samples, in order to obtain an accurate regression model, the influence of complex environmental factors in the acquisition process of the obtained infrared spectral data is first considered, and the differences between the characteristic wavelengths obtained on the basis of different wavelength offsets are analyzed to obtain the optimal wavelength offset for each spectral data; as for the influence of impurities, it is necessary to consider the mutual influence between multiple characteristic peaks, analyze the influence coefficients between different wavelengths, and combine the correlation index between the absorbance sequence and the true triacetin concentration sequence. For the case where the wavelength is less affected by the other wavelengths and has a larger correlation index, a higher confidence is given to the wavelength, so that it performs better for the concentration of the substance, so that the final PCA result is more in line with the actual situation for the expression of regression analysis.
[0053] Among them, in order to obtain the optimal wavelength offset size of each spectral data, considering that in a single infrared spectral data, the spectral absorbance at different wavelengths has different expressions for its corresponding true triacetin concentration, the change of spectral absorbance with wavelength is considered, and multiple wavelengths with better expressions for the infrared spectral data are preliminarily selected as the characteristic wavelengths of the infrared spectral data to perform subsequent peak offset correction.
[0054] For the infrared spectrum data of any triacetin solution sample, the spectral absorbance threshold corresponding to the infrared spectrum data is adaptively determined according to the average distribution and discreteness of the spectral absorbance at each wavelength in the infrared spectrum data; and then the characteristic wavelength corresponding to the infrared spectrum data is determined based on the spectral absorbance threshold corresponding to the infrared spectrum data and the relationship between the spectral absorbance at each wavelength in the infrared spectrum data and the spectral absorbances corresponding to other wavelengths in the neighborhood of the wavelength.
[0055] In this embodiment, the characteristic wavelength corresponding to the infrared spectrum data of each triacetin solution sample is determined by the calculation formula:
[0056] ;
[0057] ;
[0058] in, Indicates A set of characteristic wavelengths corresponding to the infrared spectrum data of triacetin solution samples; Indicates In the infrared spectrum data of a triacetin solution sample, the wavelength Spectral absorbance under ; Indicates In the infrared spectrum data of a triacetin solution sample, the wavelength The adjacent wavelength Spectral absorbance under ; Indicates the neighborhood radius of the wavelength. In this embodiment, ; Indicates the wavelength shift; Indicates The spectral absorbance threshold of the infrared spectrum data of the triacetin solution samples; Indicates The average value of the spectral absorbance of the infrared spectrum data of the triacetin solution samples at each wavelength; Indicates The standard deviation of the spectral absorbance of the infrared spectrum data of the triacetin solution samples at each wavelength; Indicates adjustment parameters. In this embodiment, .
[0059] In the above-mentioned calculation formula of the spectral absorbance threshold, it is considered that the characteristic peak corresponding to triacetin under different measurement environments may be offset to a certain extent. Therefore, some maximum points in the infrared spectrum data of each triacetin solution sample are first obtained. However, when the response value, that is, the spectral absorbance, is small, the spectral absorbance at some wavelengths may fluctuate to a certain extent due to the influence of noise, and there are also some maximum points, which makes it impossible to better represent the size of the measured triacetin concentration. Therefore, it is considered to use the mean and standard deviation of the spectral absorbance corresponding to all wavelengths in the infrared spectrum data to give an adaptive spectral absorbance threshold corresponding to each infrared spectrum data to avoid the influence of noise on the determined maximum points.
[0060] Step S3: According to the difference between the solution parameter data of the same type of different triacetin solution samples, the maximum wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample is determined, and each characteristic wavelength of the infrared spectrum data of each triacetin solution sample is moved, and the movement amount of each movement is less than or equal to the corresponding maximum wavelength offset, so as to obtain each moving characteristic wavelength of each movement, and compare the each moving characteristic wavelength with each characteristic wavelength of the infrared spectrum data of other triacetin solution samples to determine the optimal wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample.
[0061] After obtaining the characteristic wavelengths corresponding to the infrared spectrum data of different triacetin solution samples, it is considered that the characteristic wavelengths corresponding to different triacetin solution samples are different due to the influence of different measurement environments. For example, at higher temperatures, the absorption peak of the infrared spectrum data will shift toward a smaller wavelength compared to the absorption peak at a lower temperature, and the higher the temperature, the greater the peak shift of the absorption peak. Therefore, in order to facilitate the subsequent correction of the covariance matrix of the traditional PCA principal component analysis according to the influence of the measurement environment, so as to finally obtain a more accurate regression model, it is necessary to determine the optimal wavelength shift corresponding to the infrared spectrum data of different triacetin solution samples.
[0062] To this end, according to different types of solution parameter data of each triacetin solution sample, the maximum wavelength offset corresponding to the infrared spectrum data of the triacetin solution sample is adaptively determined, and within the maximum wavelength offset, each characteristic wavelength corresponding to the infrared spectrum data is moved to obtain each moving characteristic wavelength for each movement, and each moving characteristic wavelength obtained after each movement is compared with each characteristic wavelength corresponding to the infrared spectrum data of other triacetin solution samples, so that the difference between each moving characteristic wavelength and each characteristic wavelength corresponding to other triacetin solution samples is minimized, and finally the optimal wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample is determined.
[0063] In the embodiment of the present invention, the maximum wavelength offset and the optimal wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample are determined, and the corresponding calculation formula is:
[0064] ;
[0065] ;
[0066] in, Indicates The optimal wavelength shift corresponding to the infrared spectrum data of triacetin solution samples; It represents the minimum point function, which refers to the value of the independent variable that makes the function reach the minimum value; Indicates Each characteristic wavelength corresponding to the infrared spectrum data of the triacetin solution sample shifted by The corresponding moving characteristic wavelengths are: ; Indicates that except The first The characteristic wavelengths corresponding to the infrared spectrum data of the triacetin solution samples; express and The distance indicator; N represents the total number of triacetin solution samples; Indicates The maximum wavelength shift corresponding to the infrared spectrum data of the triacetin solution sample; Indicates The first Solution parameter data; Indicates the first The average value of the solution parameter data; Indicates the first The standard deviation of the solution parameter data; Indicates the setting of wavelength offset. In this embodiment, ; represents the number of types of solution parameter data of triacetin solution samples; Indicates the round-up symbol.
[0067] In the above optimal wavelength offset calculation formula, determine and Distance indicator The method is: The mobile characteristic wavelengths corresponding to the triacetin solution samples are arranged in order of size, such as from small to large, to obtain a mobile characteristic wavelength sequence, and the mobile characteristic wavelength sequence is The first The characteristic wavelengths corresponding to the triacetin solution samples are arranged in order of size, such as from small to large, to obtain a characteristic wavelength sequence, and the DTW distance between the moving characteristic wavelength sequence and the characteristic wavelength sequence is calculated to obtain and distance indicator.
[0068] Of course, as another embodiment, based on the above-mentioned moving characteristic wavelength sequence and characteristic wavelength sequence, the number of elements in the moving characteristic wavelength sequence can also be determined. p 1 and the number of elements in the characteristic wavelength sequence p 2. Determine the number of elements p 1 and p 2, and record it as p min , and determine the previous p min The sequence of elements is composed of , and the cosine similarity of the two sequences is calculated. The absolute value of the difference between the cosine similarity and 1 is taken as and distance indicator.
[0069] In the above optimal wavelength shift calculation formula, Indicates that the Each characteristic wavelength corresponding to the triacetin solution sample is shifted by the wavelength offset After that, the wavelength difference between each obtained moving characteristic wavelength and each characteristic wavelength corresponding to other triacetin solution samples is calculated, and the wavelength offset corresponding to the minimum wavelength difference is calculated. as the optimal wavelength shift. Indicates The abnormality of the solution parameter data of the infrared spectrum data of the triacetin solution sample is determined. When the abnormality is greater, a larger maximum wavelength offset is assigned to minimize the wavelength difference within the maximum wavelength offset, so as to find the wavelength offset that minimizes the wavelength difference as the optimal wavelength offset.
[0070] Step S4: correcting the infrared spectrum data of each triacetin solution sample according to the optimal wavelength offset to obtain the corrected infrared spectrum data of each triacetin solution sample.
[0071] After obtaining the optimal wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample, the absolute value of the optimal wavelength shift is determined, and the infrared spectrum data with the smallest absolute value is used as the standard spectrum data. According to the optimal wavelength shift of the standard spectrum data and the optimal wavelength shift corresponding to each other triacetin solution sample, the infrared spectrum data of each triacetin solution sample is corrected to obtain the corrected infrared spectrum data of each triacetin solution sample. In the process of correcting the infrared spectrum data of each triacetin solution sample, the difference between the optimal wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample and the optimal wavelength shift of the standard spectrum data is calculated, and the difference is used as the actual wavelength shift. According to the actual wavelength shift, the infrared spectrum data of each triacetin solution sample is moved left and right. When the wavelength shift is a negative value, it is moved left, and when the wavelength shift is a positive value, it is moved right, so as to obtain the corrected infrared spectrum data. For example, the optimal wavelength shifts of each triacetin solution sample are -10, -5, 9, and 2, respectively. At this time, the infrared spectrum data corresponding to the optimal wavelength shift 2 is selected as the standard spectrum data. At this time, the infrared spectrum data with the optimal wavelength shift of -10 is moved to the left by 12 wavelength units, the infrared spectrum data with the optimal wavelength shift of -5 is moved to the left by 7 wavelength units, and the infrared spectrum data with the optimal wavelength shift of 9 is moved to the right by 7 wavelength units.
[0072] It should be understood that since the standard spectrum data as a basis does not need to be moved, the corresponding actual wavelength movement amount is 0, and the standard spectrum data is directly used as the corrected infrared spectrum data corresponding to the triacetin solution sample.
[0073] After obtaining the corrected infrared spectrum data of each triacetin solution sample, considering that the spectrum data on both sides may exceed or fall short, the spectrum data corresponding to the maximum wavelength range of the spectrum absorbance value in the corrected infrared spectrum data is intercepted, thereby obtaining the final corrected infrared spectrum data of each triacetin solution sample.
[0074] Step S5: performing principal component analysis on the corrected infrared spectrum data of each triacetin solution sample, and determining a regression model and linear combination coefficients of each principal component in combination with the actual triacetin concentration of each triacetin solution sample, and performing triacetin solution concentration detection based on the regression model and the linear combination coefficients of each principal component.
[0075] After obtaining the optimal wavelength offset corresponding to different triacetin solution samples and correcting the corresponding infrared spectral data, considering that in the existing PCA dimensionality reduction process of spectral data, since the weights of the spectral absorbance at each wavelength are the same, but affected by the impurities present in the solution, the spectral absorbance at multiple wavelengths does not represent the true change in triacetin concentration, which makes the absorption peaks corresponding to multiple different substances affect each other, and then causes the final spectral data changes not caused by a single triacetin. Therefore, in order to remove the mutual influence between different characteristic peaks, it is necessary to measure the influence coefficient between wavelengths.
[0076] Step S51: in the corrected infrared spectrum data of each triacetin solution sample, determine the influence coefficient of any wavelength on another wavelength according to the distance between any two wavelengths and the change of the wavelength-corresponding spectral absorbance between any two wavelengths.
[0077] In the embodiment of the present invention, the influence coefficient of any wavelength on another wavelength is determined, and the corresponding calculation formula is:
[0078] ;
[0079] in, Indicates wavelength For another wavelength The influence coefficient of Indicates wavelength With another wavelength The wavelength difference between To set the wavelength distance, this embodiment sets ; represents the denominator correction coefficient. In this embodiment, ; represents the normalization function; Indicated in In the corrected infrared spectrum data of the triacetin solution sample, along the wavelength arrive In the direction of wavelength The spectral absorption rate change rate under the condition of wavelength resolution is set to 1 in this embodiment, so , represents the directional coefficient, , Indicated in wavelength The spectral absorption rate under Indicated in wavelength Spectral absorbance under ; N Represents the total number of triacetin solution samples.
[0080] In the above calculation formula of the influence coefficient, when two wavelengths are considered and When the distance between the two wavelengths is close, it means that the spectral absorption rate at the two wavelengths is more likely to be caused by the concentration of the same substance, so the influence coefficient is given a maximum value of 1. and When the distance between them is far, since the probability that the spectral data with a long wavelength distance are caused by the same characteristic peak is low, the corresponding influence coefficient should gradually decrease as the distance increases. It represents point to The sum of the change rates of the spectral absorbances of multiple wavelengths in the set wavelength distance in the direction. If the sum of the change rates of the spectral absorbances is negative and small, it means that the spectral absorbance decays rapidly along this direction, reflecting that the spectral absorbance of a certain substance decays to 0 in the shorter wavelength neighborhood, and there is a small probability of wavelength overlap. for The influence coefficient should be small, otherwise for The influence coefficient should be larger.
[0081] Step S52: Determine the confidence of the spectral data of each wavelength according to the influence coefficient of each adjacent wavelength within the neighborhood range of each wavelength on the wavelength, and the correlation between the spectral absorbance corresponding to the same adjacent wavelength within the neighborhood range of each wavelength in the corrected infrared spectral data of each triacetin solution sample and the actual triacetin concentration of each triacetin solution sample.
[0082] After obtaining the influence coefficients between different wavelengths in the above manner, on the basis of the corrected infrared spectrum data, the actual triacetin concentration measured in the triacetin solution sample is used to measure whether the spectral absorbance at each wavelength is caused by the change in triacetin concentration, that is, the correlation between the absorbance sequence and the concentration sequence of the spectrum at each wavelength is analyzed. For wavelengths that are less affected by multiple adjacent wavelengths and have a higher correlation, a higher confidence level is assigned, otherwise it is suppressed to prevent the remaining wavelengths from affecting the subsequent regression analysis.
[0083] To this end, the confidence of the spectral data of each wavelength is determined based on the influence coefficient of the adjacent wavelengths in the neighborhood range of each wavelength on the wavelength, combined with the correlation between the sequence of spectral absorbances corresponding to the same adjacent wavelengths in the neighborhood range of each wavelength in the corrected infrared spectral data of each triacetin solution sample and the sequence of true triacetin concentrations of each triacetin solution sample.
[0084] In this embodiment, the confidence of the spectrum data of each wavelength is determined, and the corresponding calculation formula is:
[0085] ;
[0086] in, Indicates wavelength Confidence of spectral data; Indicates wavelength The neighboring wavelengths within the neighborhood range For wavelength The influence coefficient of Indicates that in the corrected infrared spectrum data of each triacetin solution sample, at wavelength The neighboring wavelengths within the neighborhood range The spectral absorbance sequence composed of the spectral absorbance under ; Indicates wavelength The size of the neighborhood range is set in this embodiment. ; A real triacetin concentration sequence representing the real triacetin concentration of each triacetin solution sample; express and In this embodiment, the correlation index refers to and Pearson correlation coefficient between ; Represents the normalization function.
[0087] In the above calculation formula for the confidence of spectral data, Indicates wavelength The neighboring wavelengths within the neighborhood range The reliability level is high and the wavelength When the influence coefficient is small, it means that the wavelength There is a high probability that it contains information of different types from its neighborhood, and it should be given a higher confidence level for retention. When the influence coefficient is large, it means that the wavelength There is a high probability that the change in spectral data is caused by the influence of other impurities, and the corresponding confidence level should also be lower.
[0088] Step S53: According to the confidence of the spectral data, the covariance matrix corresponding to the corrected infrared spectral data of each triacetin solution sample is corrected to obtain a corrected covariance matrix, and the linear combination coefficients of each principal component and each principal component of each triacetin solution sample are determined according to the corrected covariance matrix.
[0089] Determine the covariance matrix of the traditional PCA principal component analysis of the corrected infrared spectral data of each triacetin solution sample. Since the process of obtaining the covariance matrix belongs to the prior art, it will not be described in detail here. After determining the confidence of the spectral data of each wavelength through the above steps, the covariance matrix is corrected based on the confidence of the spectral data to obtain the corrected covariance matrix. The corresponding calculation formula is:
[0090] ;
[0091] ;
[0092] in, represents the corrected covariance matrix; represents the covariance matrix corresponding to the corrected infrared spectrum data of each triacetin solution sample; The spectral absorbance at all wavelengths in the corrected infrared spectrum data of each triacetin solution sample is represented by The spectral data matrix of express The transposed matrix of represents the total number of triacetin solution samples obtained; represents the number of wavelengths in the corrected infrared spectrum data of each triacetin solution sample; Represents a weight coefficient matrix composed of the confidence of the spectral data of each wavelength; Indicates wavelength Confidence of spectral data; Indicates wavelength Confidence of spectral data.
[0093] In the above-mentioned corrected covariance matrix, by using the obtained confidence of the spectral data of each wavelength, the covariance matrix of the traditional PCA principal component analysis of the corrected infrared spectral data of each triacetin solution sample is corrected, so that the subsequently selected principal components can better represent the actual triacetin concentration.
[0094] Based on the above modified covariance matrix, select the front principal components, and obtain the previous The linear combination coefficients corresponding to the principal components are called the principal component linear combination coefficients. The specific implementation process of the principal components and their corresponding linear combination coefficients belongs to the prior art and will not be described here. The principal component linear combination coefficient corresponding to each principal component in the principal components is weighted averaged for the spectral absorbance at each wavelength in the corrected infrared spectrum data of each triacetin solution sample, thereby obtaining the front view of the triacetin solution sample. The contribution rate threshold can be reasonably set as needed. In this embodiment, the contribution rate threshold is set to .
[0095] Step S54: taking the principal components of each triacetin solution sample as independent variables and the actual triacetin concentration of each triacetin solution sample as the dependent variable, a regression model is obtained by fitting.
[0096] Each triacetin solution sample was The principal components were taken as independent variables, and the true triacetin concentration of the triacetin solution sample was taken as the dependent variable. The PLS partial least squares method was performed to obtain the regression model between the independent variables and the dependent variables.
[0097] After the regression model and the linear combination coefficients of the principal components are obtained through the above steps S51-S54, for the new triacetin solution to be measured, after obtaining its infrared spectrum data, the wavelength offset is corrected according to the above steps S1-S4. After obtaining the corrected infrared spectrum data, the above-mentioned The linear combination coefficient of each principal component corresponding to the principal component of the principal components is weighted averaged to obtain the spectral absorbance at each wavelength in the corrected infrared spectrum data. principal component, this The principal components are input into the regression model to calculate the corresponding true triacetin concentration, thus achieving accurate measurement of triacetin concentration.
[0098] It should be understood that, without considering the influence of impurity factors present in each triacetin solution sample, in other embodiments, the corresponding covariance matrix can be directly obtained based on the corrected infrared spectrum data of each triacetin solution sample, and the linear combination coefficients of each principal component and each principal component of each triacetin solution sample can be determined based on the covariance matrix.
[0099] Similarly, without considering the influence of complex environmental factors during the acquisition process of the infrared spectrum data of each triacetin solution sample, in other embodiments, the original infrared spectrum data of each triacetin solution sample can be directly based on the original infrared spectrum data of each triacetin solution sample, and according to the above steps S51-S54, the influence coefficient of any wavelength on another wavelength can be determined, and the spectrum data confidence of each wavelength can be determined. Based on the spectrum data confidence, the covariance matrix corresponding to the original infrared spectrum data of each triacetin solution sample is corrected to obtain the corrected covariance matrix, and finally the regression model and the linear combination coefficients of each principal component are obtained. Based on the regression model and the linear combination coefficients of each principal component, the measurement of triacetin concentration can be achieved directly according to the infrared spectrum data of the new triacetin solution to be measured. At this time, the corresponding implementation steps are as follows:
[0100] Obtaining infrared spectrum data and solution parameter data of each triacetin solution sample, wherein the solution parameter data at least indicates the actual triacetin concentration;
[0101] In the infrared spectrum data of each triacetin solution sample, the influence coefficient of any wavelength on another wavelength is determined according to the distance between any two wavelengths and the change of the wavelength corresponding spectral absorbance between any two wavelengths;
[0102] Determine the confidence of the spectral data of each wavelength according to the influence coefficient of each adjacent wavelength within the neighborhood range of each wavelength on the wavelength, and the correlation between the spectral absorbance corresponding to the same adjacent wavelength within the neighborhood range of each wavelength in the infrared spectral data of each triacetin solution sample and the actual triacetin concentration of each triacetin solution sample;
[0103] According to the confidence level of the spectral data, the covariance matrix corresponding to the infrared spectral data of each triacetin solution sample is corrected to obtain a corrected covariance matrix;
[0104] Determining the linear combination coefficients of the principal components and the principal components of each triacetin solution sample according to the modified covariance matrix;
[0105] Taking each principal component of each triacetin solution sample as an independent variable and the actual triacetin concentration of each triacetin solution sample as a dependent variable, a regression model is obtained by fitting;
[0106] The concentration of triacetin solution is detected based on the regression model and the linear combination coefficients of each principal component.
[0107] The present invention obtains and corrects the offset of each spectral data by analyzing the difference of characteristic wavelengths of infrared spectral data of different triacetin solution samples, thereby overcoming the situation that the obtained spectral data is biased due to the measurement environment. At the same time, by analyzing the influence coefficient between spectral data at different wavelengths, combining the correlation between spectral absorbance sequences at multiple different wavelengths and true triacetin concentration sequences, the confidence of multiple wavelengths is obtained, avoiding the influence of characteristic peaks of impurities on the true triacetin concentration; the covariance matrix in the traditional PCA principal component analysis process is corrected by the confidence, so that the obtained principal component has a better performance on the triacetin concentration, thereby improving the accuracy of subsequent regression analysis and concentration prediction.
[0108] It should be noted that 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 aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or make equivalent replacements for some of the technical features therein. These modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. An intelligent determination method for food-grade triacetin, characterized in that: The following steps are involved: Acquire infrared spectrum data and different types of solution parameter data of each triacetin solution sample, wherein the different types of solution parameter data at least include actual triacetin concentration and different types of solution environment parameters; Determine each characteristic wavelength corresponding to the infrared spectrum data of each triacetin solution sample according to the distribution of the spectral absorbance at each wavelength in the infrared spectrum data of each triacetin solution sample; According to the difference between the solution parameter data of the same type of different triacetin solution samples, the maximum wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample is determined, and each characteristic wavelength of the infrared spectrum data of each triacetin solution sample is moved, and the movement amount of each movement is less than or equal to the corresponding maximum wavelength offset, and each moving characteristic wavelength of each movement is obtained, and each moving characteristic wavelength is compared with each characteristic wavelength of the infrared spectrum data of other triacetin solution samples to determine the optimal wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample; According to the optimal wavelength offset, the infrared spectrum data of each triacetin solution sample is corrected to obtain the corrected infrared spectrum data of each triacetin solution sample; Performing principal component analysis on the corrected infrared spectrum data of each triacetin solution sample, and determining a regression model and linear combination coefficients of each principal component in combination with the actual triacetin concentration of each triacetin solution sample, and performing triacetin solution concentration detection based on the regression model and the linear combination coefficients of each principal component; Determine the maximum wavelength offset corresponding to the infrared spectrum data of each triacetin solution sample, and the corresponding calculation formula is: ; in, Indicates The maximum wavelength shift corresponding to the infrared spectrum data of the triacetin solution sample; Indicates The first Solution parameter data; Indicates the first The average value of the solution parameter data; Indicates the first The standard deviation of the solution parameter data; Indicates the set wavelength offset; represents the number of types of solution parameter data of triacetin solution samples; Indicates the rounding up symbol; Determine the optimal wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample, and the corresponding calculation formula is: ; in, Indicates The optimal wavelength shift corresponding to the infrared spectrum data of triacetin solution samples; Represents the minimum point function; Indicates Each characteristic wavelength corresponding to the infrared spectrum data of the triacetin solution sample shifted by The corresponding moving characteristic wavelengths are obtained later; Indicates that except The first The infrared spectrum data of the triacetin solution samples correspond to the various characteristic wavelengths; express and The distance indicator; N represents the total number of triacetin solution samples; Indicates The maximum wavelength shift corresponding to the infrared spectrum data of the triacetin solution sample; Sure and Distance indicators include: The first The mobile characteristic wavelengths corresponding to the triacetin solution samples are arranged in order of size to obtain a mobile characteristic wavelength sequence, and the mobile characteristic wavelength sequence except the first The first The characteristic wavelengths corresponding to the triacetin solution samples are arranged in order of size to obtain a characteristic wavelength sequence; Calculate the DTW distance between the moving characteristic wavelength sequence and the characteristic wavelength sequence, and determine the DTW distance as and The distance indicator; The corrected infrared spectrum data of each triacetin solution sample is obtained, including: Determine the absolute value of the optimal wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample, and determine the infrared spectrum data with the smallest absolute value as the standard spectrum data; Calculating the difference between the optimal wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample and the optimal wavelength shift corresponding to the standard spectrum data, to obtain the actual wavelength shift corresponding to the infrared spectrum data of each triacetin solution sample; According to the actual wavelength shift amount, the infrared spectrum data of each triacetin solution sample is shifted left and right to obtain the corrected infrared spectrum data of each triacetin solution sample; Get the regression model and the linear combination coefficients of each principal component, including: In the corrected infrared spectrum data of each triacetin solution sample, the influence coefficient of any wavelength on another wavelength is determined according to the distance between any two wavelengths and the change of the wavelength corresponding spectral absorbance between any two wavelengths; Determine the confidence of the spectral data of each wavelength according to the influence coefficient of each adjacent wavelength within the neighborhood range of each wavelength on the wavelength, and the correlation between the spectral absorbance corresponding to the same adjacent wavelength within the neighborhood range of each wavelength in the corrected infrared spectral data of each triacetin solution sample and the actual triacetin concentration of each triacetin solution sample; According to the confidence of the spectral data, the covariance matrix corresponding to the corrected infrared spectral data of each triacetin solution sample is corrected to obtain a corrected covariance matrix, and according to the corrected covariance matrix, each principal component linear combination coefficient and each principal component of each triacetin solution sample are determined; Taking each principal component of each triacetin solution sample as an independent variable and the actual triacetin concentration of each triacetin solution sample as a dependent variable, a regression model is obtained by fitting; Determine the influence coefficient of any wavelength on another wavelength. The corresponding calculation formula is: ; in, Indicates wavelength For another wavelength The influence coefficient of Indicates wavelength With another wavelength The wavelength distance between them; Indicates the set wavelength distance; represents the denominator correction factor; represents the normalization function; Indicated in In the infrared spectrum data of a triacetin solution sample, along the wavelength arrive In the direction of wavelength The rate of change of spectral absorbance under represents the directional coefficient, ; N Represents the total number of triacetin solution samples.
2. The intelligent determination method of food-grade triacetin according to claim 1, characterized in that: Determine the characteristic wavelengths corresponding to the infrared spectrum data of each triacetin solution sample, and the corresponding calculation formula is: ; ; in, Indicates The spectral absorbance threshold of the infrared spectrum data of the triacetin solution samples; Indicates The average value of the spectral absorbance at each wavelength in the infrared spectrum data of the triacetin solution samples; Indicates The standard deviation of the spectral absorbance of the infrared spectrum data of the triacetin solution samples at each wavelength; Indicates adjustment parameters; Indicates A set of characteristic wavelengths corresponding to the infrared spectrum data of triacetin solution samples; Indicates In the infrared spectrum data of a triacetin solution sample, the wavelength Spectral absorbance under ; Indicates In the infrared spectrum data of a triacetin solution sample, the wavelength The adjacent wavelength Spectral absorbance under ; The neighborhood radius represents the wavelength; Indicates the wavelength shift.
3. The intelligent determination method of food-grade triacetin according to claim 1, characterized in that: Determine the confidence level of the spectral data at each wavelength, including: In the corrected infrared spectrum data of each triacetin solution sample, the spectral absorbance at the same adjacent wavelength within the neighborhood range of the same wavelength is arranged to obtain a spectral absorbance sequence, and the real triacetin concentration of each triacetin solution sample is arranged accordingly to obtain a real triacetin concentration sequence, and a correlation index between the spectral absorbance sequence and the real triacetin concentration sequence is determined; The confidence level of the spectrum data of each wavelength is determined according to the influence coefficient of each neighboring wavelength within the neighborhood range of each wavelength on the wavelength and the correlation index corresponding to each neighboring wavelength within the neighborhood range of each wavelength.
4. The intelligent determination method of food-grade triacetin according to claim 1, characterized in that: The covariance matrix corresponding to the infrared spectrum data of each triacetin solution sample is corrected to obtain a corrected covariance matrix, and the corresponding calculation formula is: ; ; in, represents the corrected covariance matrix; represents the covariance matrix corresponding to the infrared spectrum data of each triacetin solution sample; The spectral absorbance at all wavelengths in the corrected infrared spectrum data of each triacetin solution sample is represented by The spectral absorbance matrix of express The transposed matrix of represents the total number of triacetin solution samples obtained; represents the number of wavelengths in the corrected infrared spectrum data of each triacetin solution sample; Represents a weight coefficient matrix composed of the confidence of the spectral data of each wavelength; Indicates wavelength Confidence of spectral data; Indicates wavelength Confidence of spectral data.
