A method for correcting spectrum
By calculating the crude oil spectral difference spectrum on different spectra and performing fitting the difference spectrum processing, the problem of inconsistent spectra of crude oil measurements of different spectras is solved, and the accuracy and consistency of crude oil identification is achieved.
Patent Information
- Application Number
- CN202010724586.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-24
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2040-07-24
AI Technical Summary
Different models of near-infrared spectrometers will produce inconsistent spectral data when measuring crude oil, resulting in the same crude oil being misjudged as two different crude oils.
By selecting a set of representative crude oil standards, the spectrum is collected on two spectrometers and the spectral difference spectrum is calculated. Then, the spectrum of the crude oil sample to be measured is collected on one of the spectrometers, and the fitting difference spectrum is obtained through the fitting algorithm Finally, the spectrum of the crude oil sample to be measured is different from the fitted difference spectrum to obtain the corrected spectrum on another spectrometer.
Effectively eliminates wavelength differences between different spectrometers, ensuring accuracy and consistency in crude oil identification, simplifying operation and improving the accuracy of testing.
Smart Images

Figure CN113970531B_ABST
Abstract
Description
Technical Field
[0001] The invention relates to a method for correcting a spectrum. Background Art
[0002] Patent 200910169611.8 "A method for quickly identifying crude oil types by near-infrared spectra" proposes a method for quickly identifying crude oil near-infrared spectra based on the concept of moving window (Moving Window) combined with the traditional correlation coefficient method - the moving window correlation coefficient method. This method can accurately identify crude oil varieties and provide detailed difference information between near-infrared spectra of different crude oils, providing powerful assistance for analyzing spectra. However, in actual applications, the problem of inconsistent near-infrared spectra is often encountered, that is, the spectra obtained by the same crude oil on different models of near-infrared spectrometers are different. The main reason is that there are slight differences in key components between different models of spectrometers. If the near-infrared spectrum database established on one model of near-infrared spectrometer is used on another model of instrument, due to the differences between the spectra, it will lead to erroneous identification results. For example, the same crude oil may be misjudged as two different crude oils.
[0003] In order to solve the problem of inconsistent spectra collected by different instruments, a variety of methods have been proposed for different application objects. The commonly used algorithm is the Direct Standardization (DS) algorithm, which is aimed at the situation where there are large spectral differences between two types of instruments. The spectral conversion coefficient between the two types of instruments is found through a set of standard samples. The Mean Spectra Subtraction Correction Method (MSSC) is aimed at the situation where there are differences in absorbance but no differences in wavelength between two types of instruments. The absorbance difference between different instruments is found through a set of standard samples. The spectral difference used is the average value of the difference spectrum of a set of standard samples.
[0004] The commonly used algorithm is the DS (Direct Standardization) algorithm, which is used to find the spectral conversion coefficients between two types of instruments through a set of standard samples when there are large spectral differences between the two types of instruments. The Mean Spectra Subtraction Correction Method (MSSC) is used to find the absorbance differences between different instruments through a set of standard samples when there are differences in absorbance but no differences in wavelength between the two types of instruments. The spectral difference used is the average value of the difference spectrum of a set of standard samples.
[0005] In the article "Study on Model Transfer of Filter-Type Near-Infrared Instrument" (Spectroscopy and Spectral Analysis, 2008, 28(10): 2459-2462), Chen Jiawei took the near-infrared spectrum of corn kernels (to detect the moisture content) as an example to investigate the problem of model transfer. Model transfer was implemented on 5 filter-type near-infrared instruments using the slope-intercept algorithm, direct correction method and target factor analysis, and the model transfer effects of various methods were compared. The study showed that the direct correction method had the best model transfer effect, with an average transfer difference of 7.01% for the 4 instruments. The article also studied the effect of the number of standard samples on the model transfer effect. The more standard samples there are as a conversion set, the better the model transfer effect. Generally, 20 standard samples can achieve a stable effect. When the conversion set is less than 20, the transfer effect of the direct correction method drops sharply, while the effect of the number of standard samples on the slope-intercept method and the target factor analysis method is not obvious.
[0006] In the article "Study on the Transfer of Mathematical Models between Fourier Transform Near Infrared Spectrometers Based on SVR" (Spectroscopy and Spectral Analysis, 2008, 28(10): 2299-2303), Zhao Longlian used two Fourier transform near infrared spectrometers as experimental research objects and corn powder samples as experimental materials. He used the moving window support vector regression (SVR) method to transfer the near infrared quantitative analysis mathematical model established on one instrument to the other instrument: when the window size of the SVR regression was 31 wavelength points and the number of transferred samples was 15, the model transfer effect was good. The mathematical model of protein content established by the "host" was used to analyze the corrected spectrum on the "slave", and the correlation coefficient between the chemical determination value and the near infrared prediction value increased to 0.9434, and the relative standard deviation was 4.23%. This shows that it is feasible to use the moving window SVR method to transfer mathematical models between Fourier transform near infrared spectrometers. However, the calculation process of this method is relatively complicated. Summary of the invention
[0007] The object of the present invention is to provide a spectrum correction method, which can eliminate the wavelength difference between different spectrometers.
[0008] In order to achieve the above object, the present invention provides a method for correcting a spectrum, the method comprising the following steps:
[0009] Obtaining a crude oil sample to be tested and known crude oil samples including multiple types;
[0010] Using a first spectrometer to detect the known crude oil sample and perform spectrum preprocessing to obtain a first spectrum matrix;
[0011] Using a second spectrometer to detect the known crude oil sample and perform spectrum preprocessing to obtain a second spectrum matrix;
[0012] Calculating a spectral difference matrix between the first spectral matrix and the second spectral matrix;
[0013] Using the first spectrometer to detect the crude oil sample to be tested and perform spectrum preprocessing to obtain a spectrum to be transferred;
[0014] In the same wavelength range, fitting the spectrum to be transferred by using the first spectrum matrix to obtain a fitting coefficient vector;
[0015] Calculating the product of the fitting coefficient vector and the spectrum difference spectrum matrix as a fitting difference spectrum band, and forming a fitting difference spectrum from the fitting difference spectrum band;
[0016] A difference spectrum between the spectrum to be transferred and the fitting difference spectrum is calculated as a correction spectrum of the spectrum to be transferred on the second spectrometer.
[0017] Optionally, the spectrum preprocessing includes at least one of differentiation processing, standardization processing, normalization processing and wavelet transform processing.
[0018] Optionally, in the same band interval, fitting the spectrum to be transferred by using the first spectrum matrix to obtain a fitting coefficient vector; calculating the product of the fitting coefficient vector and the spectrum difference spectrum matrix as a fitting difference spectrum band, and forming a fitting difference spectrum from the fitting difference spectrum band, including:
[0019] Dividing the first spectrum matrix and the spectrum difference spectrum matrix into a plurality of band intervals with the same interval width respectively;
[0020] For each of the band intervals, fitting the spectral band of the spectrum to be transferred through the first spectral matrix to obtain the fitting coefficient vector corresponding to the band interval; calculating the product of the fitting coefficient vector and the spectral difference spectrum matrix as the fitting difference spectrum band;
[0021] The fitting difference spectrum is composed of the fitting difference spectrum bands corresponding to all the band intervals in the order of the wavelengths of the corresponding band intervals.
[0022] Optionally, the wavelength range includes 4000-5500cm -1 Band range: 5500~7000cm -1 Band range: 7000~8500cm -1 Band range: 8500~10000cm -1 Band range.
[0023] Optionally, in the same wavelength range, fitting the spectrum to be transferred by using the first spectrum matrix to obtain a fitting coefficient vector includes:
[0024] Under the same band interval, the fitting coefficient vector is determined according to the non-negative constrained least squares method.
[0025] Optionally, for each of the wavelength intervals, fitting the wavelength band of the spectrum to be transferred by using the first spectrum matrix to obtain a fitting coefficient vector corresponding to the wavelength interval includes:
[0026] Within each of the mentioned band intervals:
[0027] --Use the first spectral matrix X A All spectra in the above formula (1) are fitted to the spectra to be transferred:
[0028]
[0029] In formula (1), y A is the spectrum to be transferred, v i is the spectrum of the i-th known crude oil sample in the first spectrum matrix, a i is the fitting coefficient corresponding to the spectrum of the i-th known crude oil sample in the first spectrum matrix, and k is the number of spectra in the first spectrum matrix;
[0030] --The fitting coefficients are obtained by using the classical non-negative constrained least squares method, wherein the fitting coefficients satisfy the objective function shown in the following formula (2):
[0031]
[0032] --All the obtained fitting coefficients are combined into the fitting coefficient vector corresponding to the band interval.
[0033] Optionally, the first spectrometer and the second spectrometer are spectrometers of the same type and are selected from one of a near-infrared spectrometer, a mid-infrared spectrometer, an ultraviolet spectrometer and a Raman spectrometer.
[0034] Optionally, the first spectrometer and the second spectrometer are Fourier transform near-infrared spectrometers respectively; the detection conditions for obtaining the first spectral matrix and the second spectral matrix are the same;
[0035] The detection is a transmission detection, the detection adopts a cuvette injection method, and the transmission light path is 0.5mm;
[0036] The detection conditions include: resolution of 8cm -1 , wave number range is 4000cm -1 ~10000cm -1 , the number of scans is 64 times.
[0037] Optionally, the crude oil sample to be transferred and the known crude oil sample are each tested at 25-40°C.
[0038] Optionally, the known crude oil samples include more than 50 known crude oil samples.
[0039] Through the above technical scheme, the spectrum correction method of the present invention selects a group of representative crude oil standards to collect spectra on two spectrometers respectively, and calculates the difference spectrum of the spectra collected by the same known crude oil sample on different spectrometers, and then, for the unknown sample spectrum collected on one of the spectrometers A, the spectrum area is segmented, and the fitting coefficient vector of the spectrum of the known crude oil sample collected on the spectrometer and the spectrum to be transferred is obtained by using a fitting algorithm in each band interval, and the product of the fitting coefficient vector and the difference spectrum is subtracted from the spectrum to be transferred to obtain the correction spectrum of the unknown crude oil sample collected on another spectrometer, and the corrected spectrum is consistent with the spectrum obtained by using instrument B to collect the unknown crude oil. The method has the advantages of simple operation and accurate testing.
[0040] Other features and advantages of the present invention will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] The accompanying drawings are used to provide a further understanding of the present invention and constitute a part of the specification. Together with the following specific embodiments, they are used to explain the present invention but do not constitute a limitation of the present invention. In the accompanying drawings:
[0042] Figure 1 It is a flow chart of a spectral correction method provided by one embodiment of the present disclosure. DETAILED DESCRIPTION
[0043] The specific implementation of the present invention is described in detail below in conjunction with the accompanying drawings. It should be understood that the specific implementation described here is only used to illustrate and explain the present invention, and is not used to limit the present invention.
[0044] Figure 1 A flow chart of a spectrum correction method provided by an embodiment of the present disclosure. Figure 1 As shown, the spectrum correction method provided in this embodiment includes the following steps:
[0045] Step S101, obtaining a crude oil sample to be tested and a known crude oil sample including multiple types of known crude oil samples.
[0046] Specifically, the types of crude oil samples to be tested and known crude oil samples are not limited, that is, the method disclosed in the present invention is applicable to various types of crude oil samples produced in major oil-producing areas around the world. Furthermore, the crude oil sample to be tested and the known crude oil sample can each be tested at 25 to 40°C, for example, at 38°C. In an optional embodiment, the crude oil sample to be tested and the known crude oil sample are tested at the same temperature. In an optional embodiment, the types of crude oil samples to be tested are more than 50, for example, 50 to 100. Furthermore, the known crude oil samples preferably cover major oil-producing areas around the world.
[0047] Step S102: Use a first spectrometer to detect the known crude oil sample and perform spectrum preprocessing to obtain a first spectrum matrix, denoted as X A ;
[0048] Step S103: Use a second spectrometer to detect the known crude oil sample and perform spectrum preprocessing to obtain a second spectrum matrix, denoted as X B .
[0049] The method disclosed in the present invention is applicable to the case where there is a difference in absorbance between two spectrometers but no difference in wavelength, and can find the absorbance difference between the two spectrometers through a set of known crude oil samples. Specifically, the first spectrometer in step S102 and the second spectrometer in step S103 are spectrometers of the same type, such as near-infrared spectrometers, mid-infrared spectrometers, ultraviolet spectrometers, or Raman spectrometers.
[0050] Among them, the near-infrared spectrum is generated by the vibration-rotation energy level transition of molecules. Conventionally, the wavelength is often 2500-25000nm (wave number 4000-400cm -1 The spectral region with wavelengths of 780 to 2500 nm (wave numbers of 12820 to 4000 cm) is called the mid-infrared region. -1 ) is called the near-infrared region. The wave number is the number of waves contained in a unit centimeter, and the wave number is the reciprocal of the wavelength. The near-infrared region is very effective for quantitative analysis of organic matter.
[0051] The conditions for testing samples using the above-mentioned type of spectrometer may be well known to those skilled in the art. For example, when the first spectrometer and the second spectrometer are near-infrared spectrometers respectively, the detection may be a transmission detection, using a cuvette injection method, and a transmission light path of 0.5 mm; the detection conditions may include: a resolution of 8 cm -1 , wave number range is 4000cm -1 ~10000cm -1 , scan times 64 times.
[0052] Specifically, the spectrum preprocessing in step S102 and step S103 may each include, but are not limited to, one or more of differentiation processing, standardization processing, normalization processing and wavelet transformation processing.
[0053] Step S104, calculating the spectrum difference matrix between the first spectrum matrix and the second spectrum matrix, denoted as E AB .
[0054] Specifically, E AB =X A -X B More specifically, for each known crude oil sample among the known crude oil samples, the difference spectrum of the spectrum detected on the first spectrometer and the second spectrometer is calculated, and the difference spectra corresponding to all the known crude oil samples form a spectrum difference matrix E AB .
[0055] Step S105: Use the first spectrometer to detect the crude oil sample to be tested and perform spectrum preprocessing to obtain a spectrum to be transferred, which is recorded as y A .
[0056] Specifically, the spectrum preprocessing in step S105 may include but is not limited to differentiation processing, standardization processing, normalization processing and wavelet transformation processing.
[0057] Step S106: In the same wavelength range, the spectrum to be transferred is fitted by the first spectrum matrix to obtain a fitting coefficient vector, which is recorded as b j , (j=1,2,3…n); Calculate the product of the fitting coefficient vector and the spectral difference matrix as the fitting difference spectrum band, denoted by e AB,j (j=1,2,3…n), and the fitting difference spectrum band e AB,j Composition fitting difference spectrum e AB .
[0058] Specifically, the first spectrum matrix and the spectrum difference spectrum matrix are respectively divided into a plurality of the band intervals with the same interval width. For example, the first spectrum matrix is divided into n band intervals X A,j , (j=1,2,3…n), and the spectral difference matrix E AB Divided into the same n band intervals E AB,j , (j=1,2,3…n); for each of the band intervals, the spectral band of the spectrum to be transferred is fitted by the first spectral matrix to obtain a fitting coefficient vector corresponding to the band interval, which is recorded as b1, b2, b3…b n .
[0059] Specifically, for each of the band intervals, the spectral band of the spectrum to be transferred is fitted by the first spectral matrix to obtain a fitting coefficient vector corresponding to the band interval, for example, the fitting coefficient vector is determined according to a non-negative constrained least squares method.
[0060] For example, within each of the band intervals:
[0061] --Use the first spectral matrix X A All spectra in are treated according to the following formula (1): A Perform the fit:
[0062]
[0063] In formula (1), y A is the spectrum to be transferred, v i is the spectrum of the i-th known crude oil sample in the first spectrum matrix, a i is the fitting coefficient corresponding to the spectrum of the i-th known crude oil sample in the first spectrum matrix, and k is the number of spectra in the first spectrum matrix;
[0064] --Use the classical non-negative constrained least squares method to obtain the fitting coefficient, where the fitting coefficient a is i Satisfy the objective function shown in the following formula (2):
[0065]
[0066] --All the obtained fitting coefficients are combined into the fitting coefficient vector corresponding to the band interval.
[0067] Specifically, the fitting difference spectrum band e corresponding to all the band intervals AB,j The fitting difference spectrum e is composed according to the wavelength sequence of the corresponding band intervals. AB .
[0068] Specifically, in step S106, the first spectrum matrix and the spectrum difference spectrum matrix can be divided into a plurality of the band intervals with the same interval width respectively; wherein the same interval width can be adjusted as needed, for example, it can be 1000-1500cm -1 , it can also be divided unevenly into bands of different lengths.
[0069] For example, the first spectrum matrix and the spectrum difference matrix can be based on 1500cm -1 The width of the interval is divided into 4000~5500cm -1 Band, 5500~7000cm -1 Band, 7000~8500cm -1Band and 8500~10000cm -1 Band.
[0070] Step S107, calculating the difference spectrum between the spectrum to be transferred and the fitting difference spectrum as the correction spectrum of the spectrum to be transferred on the second spectrometer, denoted as y B .
[0071] Specifically, y B =y A -e AB .
[0072] The present invention first collects spectra of known crude oil samples on two spectrometers respectively and calculates the difference spectra of the spectra of the same known crude oil sample collected on different spectrometers. Then, for the spectrum of the unknown sample collected on one of the spectrometers, a fitting algorithm is used to obtain the fitting coefficient vector of the spectrum of the known crude oil sample collected on the spectrometer and the spectrum to be transferred within the same band interval, the product of the fitting coefficient vector and the spectrum difference matrix is calculated to obtain the fitting difference spectrum band, the fitting difference spectrum is composed of the fitting difference spectrum band, the difference between the unknown sample spectrum and the fitting difference spectrum is calculated, and the correction spectrum of the unknown crude oil sample collected on the other spectrometer can be obtained.
[0073] The method of the present invention is further described below in conjunction with embodiments, but the present invention is not limited thereto.
[0074] In the example, the instruments A and B used to collect the near-infrared spectrum of crude oil are both Fourier transform near-infrared spectrometers produced by Thermo Company, model Antaris II. There is no difference between the two instruments in the wavelength abscissa. The spectrum collection conditions of instruments A and B are: resolution 8cm -1 , wave number range 4000cm -1 ~10000cm -1 , cumulative scanning times 64 times, transmission measurement mode, using cuvette injection mode, transmission light path length 0.5mm. Detection was carried out at 38℃.
[0075] Example 1
[0076] (1) 50 representative known crude oil samples were collected as known crude oil samples, and their crude oil near-infrared spectra were collected on instrument A and instrument B respectively to form spectral matrices S A and S B ; Then perform second-order differential spectrum preprocessing to obtain the first spectrum matrix X A and the second spectral matrix X B ;
[0077] Take 5 crude oil samples to be tested, numbered 1#, 2#, 3#, 4#, and 5#, use instrument A and instrument B to collect their near-infrared spectra respectively, and perform second-order differential spectrum preprocessing to obtain the spectrum y to be transferred. A1 ,y A2 ,y A3 ,y A4 ,y A5 , where the spectrum y detected by instrument B is B1 ,y B2 ,y B3 ,y B4 ,y B5 As a verification spectrum.
[0078] (2) For each known crude oil sample, calculate the first spectral matrix X A and the second spectral matrix X B The spectral difference spectrum E AB =X A -X B ,
[0079] (3) Then the first spectral matrix X A Divide into 10 bands, and in each band, use the known standard sample spectrum X A Fitting the spectrum of crude oil to be transferred A Get 10 fitting coefficient vectors b1, b2, b3…b 10 , the dimension of each fitting coefficient vector is 50;
[0080] The fitting method can be adopted in CN102374975B; specifically,
[0081] In each band interval, the fitting coefficient corresponding to each known crude oil sample is determined by the following formula (1) according to the non-negative constrained least squares method, and all the fitting coefficients form a fitting coefficient vector;
[0082] --Use the first spectral matrix X A All spectra in are treated according to the following formula (1): A Perform the fit:
[0083]
[0084] In formula (1), v i is the spectrum of the i-th known crude oil sample in the first spectrum matrix, a i is the fitting coefficient corresponding to the spectrum of the i-th known crude oil sample in the first spectrum matrix, and k is the number of spectra in the first spectrum matrix;
[0085] --Use the classic non-negative constrained least squares method to obtain the fitting coefficient a i, where the fitting coefficient a i Satisfy the objective function shown in the following formula (2):
[0086]
[0087] --All the obtained fitting coefficients are combined into the fitting coefficient vector corresponding to the band interval.
[0088] (4) The spectral difference spectrum E AB Divide into 10 band intervals, and calculate the fitting coefficient vector b in each band interval j The spectrum difference E in the corresponding band interval AB The product of , and get the fitting difference spectrum band e corresponding to the band interval AB,j ; Then all 10 fitting difference spectrum bands are spliced in wavelength order to form the fitting difference spectrum e AB ;
[0089] (5) Convert spectrum, spectrum to be transferred y A1 ,y A2 ,y A3 ,y A4 ,y A5 Subtract the fitted difference spectrum e AB , and obtain the calibration spectrum of the crude oil sample to be tested
[0090] (6) Identify the crude oil sample to be tested.
[0091] ① Use the spectrum measured by instrument B to establish a crude oil spectrum library
[0092] X B and B1 ,y B2 ,y B3 ,y B4 ,y B5 Compose the spectral database and select 6076.0~5556.0cm -1 and 4628.0~4000.0cm -1 Absorbance in the spectral range, establish a crude oil near-infrared spectral database based on instrument B Its dimension is 55×289, where 55 is the number of crude oil samples collected and 289 is the number of sampling points for near-infrared spectral absorbance.
[0093] ② Establish the absorbance vector of the crude oil to be tested
[0094] For the corrected spectrum 6076.0~5556.0cm -1 and 4628.0~4000.0cm -1 The absorbance in the spectral range forms the vector xB1 , x B2 , x B3 , x B4 , x B5 Its dimension is 1×289.
[0095] ③Identify unknown crude oil types
[0096] For the spectral database matrix and the spectral vector x B1 , respectively from 4000.0cm -1 The corresponding spectral interval is taken as the moving window starting from , and the moving width is 11 sampling points. In the first moving window, calculate Each spectrum and spectral vector x B1 The correlation coefficient between the absorbances in this spectral range is denoted by r. 1,i , i = 1, 2, ..., 55. Then, move one sampling interval, that is, calculate the spectrum database in the next window Each spectrum in is respectively related to the spectral vector x B1 The correlation coefficient between them is denoted as r 2,i , i = 1, 2, ..., 55. And so on, until the correlation coefficient of the last moving window is calculated, recorded as r 279,i , i=1,2,…,55.
[0097] Calculate the spectral vector x separately B1 and The identification parameter Q of each library spectrum in i ,in i=1,2,…,802. Threshold Q t =dw-0.15=289-11-0.15=277.85.
[0098] When identifying the type of unknown crude oil sample, if all Q i No greater than the threshold Q t , indicating that the database does not contain any unknown crude oil sample types. i >Q t , and each moving correlation coefficient of sample i is not less than 0.9950, then the crude oil to be tested is the same as sample i in the database.
[0099] x B2 , x B3 , x B4 , x B5 The identification was performed in the same manner as above, and the results are shown in Table 1.
[0100] Table 1
[0101]
[0102] From the identification results listed in Table 1, it can be seen that after correction, the spectra collected by instrument A can be obtained from the crude oil near-infrared spectrum identification library collected by instrument B and established. The five crude oils can be identified, indicating that the method of the present invention effectively eliminates the spectral differences between instruments.
[0103] The preferred embodiments of the present invention are described in detail above in conjunction with the accompanying drawings. However, the present invention is not limited to the specific details in the above embodiments. Within the technical concept of the present invention, a variety of simple modifications can be made to the technical solution of the present invention, and these simple modifications all belong to the protection scope of the present invention.
[0104] It should also be noted that the various specific technical features described in the above specific embodiments can be combined in any suitable manner without contradiction. In order to avoid unnecessary repetition, the present invention will not further describe various possible combinations.
[0105] In addition, various embodiments of the present invention may be arbitrarily combined, and as long as they do not violate the concept of the present invention, they should also be regarded as the contents disclosed by the present invention.
Claims
1. A method for correcting a spectrum, characterized in that: The method comprises the following steps: obtaining a crude oil sample to be tested and a known crude oil sample including multiple types of known crude oil samples; Using a first spectrometer to detect the known crude oil sample and perform spectrum preprocessing to obtain a first spectrum matrix; Using a second spectrometer to detect the known crude oil sample and perform spectrum preprocessing to obtain a second spectrum matrix; Calculating a spectral difference matrix between the first spectral matrix and the second spectral matrix; Using the first spectrometer to detect the crude oil sample to be tested and perform spectrum preprocessing to obtain a spectrum to be transferred; The first spectrum matrix and the spectrum difference spectrum matrix are divided into a plurality of band intervals with the same interval width; the band intervals include 4000-5500 cm -1 Wavelength range: 5500-7000 cm -1 Band range: 7000~8500cm -1 Band range and 8500~10000 cm -1 Band interval; For each of the band intervals, fitting the spectral band of the spectrum to be transferred through the first spectral matrix to obtain a fitting coefficient vector corresponding to the band interval; calculating the product of the fitting coefficient vector and the spectral difference spectrum matrix as a fitting difference spectrum band; The fitting difference spectrum bands corresponding to all the band intervals are composed of the fitting difference spectrum in the order of the wavelengths of the corresponding band intervals; Calculating a difference spectrum between the spectrum to be transferred and the fitted difference spectrum as a correction spectrum of the spectrum to be transferred on the second spectrometer; Wherein, the first spectrometer and the second spectrometer are Fourier transform near-infrared spectrometers respectively.
2. The method according to claim 1, wherein: The spectrum preprocessing includes at least one of differentiation processing, standardization processing, normalization processing and wavelet transformation processing.
3. The method according to claim 1, wherein: For each of the wavelength intervals, fitting the wavelength band of the spectrum to be transferred by using the first spectrum matrix to obtain a fitting coefficient vector corresponding to the wavelength interval includes: Within each of the mentioned band intervals: --Use the first spectral matrix X A All spectra in the above formula (1) are fitted to the spectra to be transferred: y A= Formula (1) In formula (1), y A is the spectrum to be transferred, i is the spectrum of the i-th known crude oil sample in the first spectrum matrix, a i is the fitting coefficient corresponding to the spectrum of the i-th known crude oil sample in the first spectrum matrix, k is the number of spectra in the first spectrum matrix; --The fitting coefficients are obtained by using the non-negative constrained least squares method, wherein the fitting coefficients satisfy the objective function shown in the following formula (2): min||y A - ||,s.t. a i ≥0, Equation (2) --All the obtained fitting coefficients are combined into the fitting coefficient vector corresponding to the band interval.
4. The method according to claim 1, wherein: The detection conditions for obtaining the first spectral matrix and the second spectral matrix are the same; The detection is a transmission detection, the detection adopts a cuvette injection method, and the transmission light path is 0.5mm; The detection conditions include: resolution of 8cm -1 , wave number range is 4000cm -1 ~10000 cm -1 , the number of scans is 64 times.
5. The method according to claim 1, wherein: The crude oil sample to be tested and the known crude oil sample are each tested at 25-40°C.
6. The method according to claim 1, wherein: The known crude oil samples include more than 50 known crude oil samples.
Citation Information
Patent Citations
Method for fast recognition of crude oil variety through near infrared spectrum
CN101995389B
Method for predicting physical property data of oil product by using near infrared spectrum
CN102374975B