A method for correcting echelle spectrometer spectrum coordinates based on least squares and polynomial fitting
Patent Information
- Application Number
- CN202410864250.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-06-30
- Publication Date
- 2026-08-18
- Estimated Expiration
- 2044-06-30
AI Technical Summary
[0003]本发明的目的是为了克服现有技术中的不足,解决现有传统谱图还原方法的精度低、稳定性差、标定困难等问题,提供一种基于最小二乘和多项式拟合的中阶梯光谱仪谱图坐标修正方法,该方法优先考虑谱图还原的精度,建立实际成像与理论成像的误差修正与补偿模型
[0056] 1. Improve the accuracy of spectrum reconstruction: By establishing an error correction and compensation model between actual imaging and theoretical imaging, this method can significantly improve the accuracy of spectrum reconstruction and ensure that wavelength information can still be accurately reconstructed under environmental changes and processing and assembly errors.
Smart Images

Figure CN118840425B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of spectral analysis, and in particular to a method for correcting the coordinates of a spectral image in a mid-level echelle spectrometer based on least squares and polynomial fitting. Background Technology
[0002] The development trend of modern spectroscopic instruments is miniaturization, lightweight design, portability, and high resolution. Traditional spectrometers achieve higher resolution by increasing grating line density or increasing the system focal length. However, the technological level for increasing grating line density is difficult to surpass, and increasing the system focal length contradicts the trend of spectrometer miniaturization. Echo-set spectrometers, by increasing the grating tilt angle, achieve higher diffraction orders, enabling high spectral resolution with small grating line densities and without changing the system focal length. The core dispersive element of an echelle-set spectrometer is the echelle grating. Echo-set gratings have very high operating orders, and the spectra dispersed by them often exhibit severe aliasing. An auxiliary dispersive element is needed to separate the aliased spectra. This cross-dispersion method forms a two-dimensional spectrum on the image plane; therefore, two-dimensional spectral information processing is the core of echelle-set spectrometers. The method of restoring wavelength information from the two-dimensional spectrum is called a spectral reconstruction algorithm. In theory, each position coordinate on a two-dimensional spectrum corresponds to a unique wavelength. Current spectrum reconstruction techniques establish a relatively accurate correspondence between the light spot coordinates and the wavelength. However, they do not take into account that environmental changes, processing and adjustment factors can cause changes in the imaging light spot coordinates, which seriously affects the accuracy of spectrum reconstruction. Summary of the Invention
[0003] The purpose of this invention is to overcome the shortcomings of existing technologies and solve the problems of low accuracy, poor stability, and difficult calibration in traditional spectral reconstruction methods. It provides a method for correcting spectral coordinates in echelle spectrometers based on least squares and polynomial fitting. This method prioritizes the accuracy of spectral reconstruction and establishes an error correction and compensation model between actual and theoretical imaging. Wavelength estimation is performed on the corrected spot imaging coordinates to establish a spectral reconstruction model of pixel coordinates and wavelengths in a two-dimensional spectrum. This method offers high reconstruction accuracy, convenient computation, and requires only a few characteristic wavelengths for high-precision calibration. It can be widely applied to various types of echelle spectrometers and various spectroscopic instruments and equipment with multiple dispersion characteristics.
[0004] The objective of this invention is achieved through the following technical solution:
[0005] A method for correcting spectral coordinates in a mid-step spectrometer based on least squares and polynomial fitting includes:
[0006] S1. The two-dimensional spectrum of the calibration light source is obtained by measuring the calibration light source using a echelle spectrometer;
[0007] S2. Perform image processing on the two-dimensional spectrum of the calibration light source to obtain the actual image points corresponding to the wavelength of the calibration light source;
[0008] S3. Obtain the theoretical image point corresponding to the wavelength of the calibrated light source using simulation software;
[0009] S4. By using the least squares method, the actual image points are fitted to the theoretical image points to obtain the corrected image point coordinates, and the image point coordinate correction coefficients A1, A2, B1, B2, C1, and C2 are obtained.
[0010] S5. Calculate the corrected coordinate residuals of the image point coordinates corresponding to the wavelength of the calibrated light source;
[0011] S6. Evaluate whether the coordinate residual level meets the accuracy requirements. If it does, proceed to S10; otherwise, proceed to S7.
[0012] S7. By using polynomial fitting, the corrected image point coordinates are fitted to the theoretical image points twice, and the residual compensation coefficients A′1, A′2, B′1, B′2, C′1, and C′2 are obtained.
[0013] S8. Use a echelle spectrometer to measure the light source under test and obtain a two-dimensional spectrum of the light source under test;
[0014] S9. Perform image processing on the two-dimensional spectrum of the light source under test to obtain the actual image points corresponding to the wavelength of the light source under test;
[0015] S10. Use coordinate correction coefficients A1, A2, B1, B2, C1, and C2 to correct the actual image points corresponding to the wavelength of the light source under test, and obtain the corrected coordinates of the actual image points corresponding to the wavelength of the light source under test.
[0016] S11. Reconstruct the spectrum of the actual image point corresponding to the wavelength of the light source under test by performing spectral reconstruction to obtain the wavelength data of the light source under test;
[0017] S12. Calculate the corrected coordinate residual of the actual image point corresponding to the wavelength of the light source under test, and use the residual compensation coefficients A′1, A′2, B′1, B′2, C′1, C′2 to perform residual compensation on the corrected coordinates obtained in S10 to obtain the second-order fitted coordinates;
[0018] S13. Reconstruct the spectrum from the second-fit coordinates to obtain the wavelength data of the light source under test.
[0019] Furthermore, step S4 is detailed as follows:
[0020] Several external and internal factors lead to the actual image point S(x) i ',y i ') and theoretical image point S(xi y i The positions are inconsistent, so external and internal factors are equivalent to theoretical image points obtained through scaling, translation, and rotation; first consider scaling and translation.
[0021]
[0022] Where a1 and a2 are scaling factors, and b1 and b2 are translation factors; assuming the wavelength λ is known... i (i = 1, 2, ..., n), whose corresponding theoretical image point coordinates S(x i y i (i = 1, 2, ..., n), the actual image point coordinates S(x) measured by the area array detector. i ',y i (i = 1, 2, ..., n), the scaling and translation coefficients are obtained by the least squares method;
[0023] Then, a rotation operation is used to correct the actual image points. The image plane coordinate system is translated to the rotation center, and the rotation vector is corrected. Combining the scaling and translation formula (1) and extending it to be expressed using mathematical matrices, we get:
[0024]
[0025] Where θ is the rotation angle, and x0 and y0 are the centers of rotation, the equations can be written in the following form:
[0026]
[0027] There are 7 variables that need to be fitted, and at least 7 sets of known wavelength image point coordinates and actual image point coordinates are required for calibration. The values of x0 and y0 are obtained directly from the actual situation. The simplified formula (3) is as follows:
[0028]
[0029] {S'(x) i ',y i Substituting '),i=1,2,3…n} into the above equation, we obtain the system of equations:
[0030]
[0031] Solve the matrix equation system (5) using equation (6).
[0032]
[0033] Since the objective function is convex and b is the coefficient matrix, taking the derivative of the objective function and setting its reciprocal to zero yields the optimal solution x. * :
[0034]
[0035] Optimal solution x * :
[0036] A T Ax * -A T b = 0 (8)
[0037] x * =(A T A) -1 A T b (9)
[0038] The analytical solution to the coefficient matrix is as follows:
[0039]
[0040]
[0041] Furthermore, step S7 is detailed as follows:
[0042] Actual image point coordinates S'(x) i ',y i After correction by formula (17), the image point coordinates S(x) are found to be the same as those of the theoretical image point. i ,y i There is a residual (Δx) i ,Δy i ):
[0043]
[0044] The residual is a function of wavelength λ. A second-order polynomial is introduced to fit the residual:
[0045]
[0046] Substituting the coordinate data into the formula yields the matrix:
[0047]
[0048] Solving for the residual compensation coefficients A′1, A′2, B′1, B′2, C′1, and C′2 yields:
[0049]
[0050]
[0051] The image point coordinates are estimated after compensation of the corrected image point coordinates. Substituting the wavelengths into the spectrum reconstruction formula, we obtain:
[0052]
[0053] An electronic device includes a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the method for correcting the spectral coordinates of a echelle spectrometer based on least squares and polynomial fitting.
[0054] A computer-readable storage medium having a computer program stored thereon, characterized in that, when executed by a processor, the computer program implements the steps of the method for correcting the coordinates of a echelle spectrometer based on least squares and polynomial fitting.
[0055] Compared with the prior art, the beneficial effects of the technical solution of the present invention are:
[0056] 1. Improve the accuracy of spectrum reconstruction: By establishing an error correction and compensation model between actual imaging and theoretical imaging, this method can significantly improve the accuracy of spectrum reconstruction and ensure that wavelength information can still be accurately reconstructed under environmental changes and processing and assembly errors.
[0057] 2. Enhanced Stability: Compared to traditional spectral reconstruction methods, this invention exhibits higher stability under various environmental conditions, reducing the impact of spot coordinate variations caused by external factors on the reconstruction results. Furthermore, this method provides a detailed analysis of the roll error of the receiving image plane, ensuring the accuracy of spectral reconstruction of two-dimensional spectra.
[0058] 3. Simplified calibration process: This method requires only a small number of characteristic wavelengths for high-precision calibration, which simplifies the calibration process of the spectrometer and requires less data, thus reducing the complexity and time cost of calibration work.
[0059] 4. Convenient computation: The algorithm based on least squares and polynomial fitting has the characteristics of high computational efficiency, which can quickly complete the spectral coordinate correction and wavelength estimation, thus improving the overall computational speed of the spectrometer.
[0060] 5. Wide range of applications: The method of this invention is not only applicable to various types of echelle spectrometers, but can also be extended to other spectroscopic instruments and equipment with multiple dispersion characteristics, and has strong universality and promotional value.
[0061] 6. High resolution and miniaturization: Through this correction method, the echelle spectrometer can achieve high spectral resolution while maintaining miniaturization and lightweight design, which is in line with the development trend of modern spectroscopic instruments. Attached Figure Description
[0062] Figure 1 This is a schematic diagram of the image plane detector structure of the echelle spectrometer.
[0063] Figure 2This is a schematic diagram of the reconstruction of a two-dimensional spectral image from a echelle spectrometer.
[0064] Figure 3 This is a flowchart illustrating the method of the present invention. Detailed Implementation
[0065] The present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. It should be understood that the specific embodiments described herein are only for explaining the present invention and are not intended to limit the present invention.
[0066] The echelle grating spectrometer images a two-dimensional spectrum using an area array detector (see...). Figure 1 However, due to unavoidable optical errors, even in the most ideal scenario, the image formed by a single wavelength on an area array detector is a diffuse spot, requiring centroid extraction. In the conventional spectral reconstruction model, the origin of the coordinate system should be at the center O” of the image plane, with the diffraction direction of the echelle grating in the Y direction and the center located at the center of the diffraction order. Corresponding to the blaze angle of the echelle grating, the wavelength calculation is relatively simple. The grating dispersion direction is in the X direction. Since the relationship between wavelength and dispersion angle is non-linear, finding the dispersion angle midline does not help in wavelength calculation but increases the algorithm difficulty. Therefore, the midpoint O’ on the left side of the image plane is selected as the origin of the spectral reconstruction coordinate system in the X direction, so that the lower limit of the wavelength coincides with the image boundary, thereby better utilizing the image plane (i.e., the image plane). Figure 1 The horizontal pixels of the camera's effective light-sensitive area.
[0067] See Figure 2 , Figure 2 In the diagram, O is the midpoint of the spherical focusing lens; O' is the origin of the two-dimensional spectrum; O” is the center of the image plane; y i x represents the ordinate of the theoretical image point; i S is the abscissa of the theoretical image point; S is the theoretical imaging point; S' is the actual image point S'; Y' is the ordinate of the spectral reconstruction; f is the focal length of the echelle spectrometer optical system; θ x θ is the dispersion angle of a horizontal prism. y θ is the vertical grating diffraction deflection angle; W is the image plane size.
[0068] According to the basic theory of optical imaging, when the equivalent beam exits from the midpoint O of the spherical focusing lens and reaches the image plane, the x-coordinate of the theoretical image point is... i with the vertical coordinate y i They are respectively:
[0069] x i =OO'tanθ x =ftanθ x (1)
[0070] y i =OO'tanθ y =ftanθy (2)
[0071] These are all about the dispersion angle and the system focal length f and the dispersion angle θ. x Deflection angle θ y The dispersion angle is a function of the wavelength λ, while the dispersion angle is a function of the wavelength λ.
[0072] S(x i ,y i )=S[f(λ i ),g(λ i (3)
[0073] Alternatively, the wavelength can be considered to be about the theoretical image point S(x). i ,y i Position function:
[0074] λ i =f[S(x i ,y i (4)
[0075] However, the refractive index of the prism is affected by temperature and air pressure, and assembly errors in the actual optical path are unavoidable. Therefore, the actual measured coordinates of the light spot and the actual image point are S'(x). i ',y i At this point, the wavelength calculated from the theoretical spectrum is:
[0076] λ i '=f[S'(x i ',y i ')] (5)
[0077] Clearly, using the actual image point S'(x) i ',y i Wavelength calculation and theoretical image point S(x) are performed. i ,y i The wavelength calculation itself contains a large error. To correct this deviation, the image plane coordinates (the coordinates of the position of the light spot on the image plane) can be corrected. If the actual imaging coordinates are corrected:
[0078] S(x i ,y i )=g[S(x i ',y i ')] (6)
[0079] Substituting the corrected coordinates into the wavelength calculation (spectral reconstruction) function yields the true wavelength:
[0080] λ i =f{g[S(x i ',y i ')]} (7)
[0081] Since the coordinates have only two variables, theoretically, finding two sets of theoretical and actual image point coordinates for known wavelengths is sufficient to correct the actual imaging coordinates for other wavelengths. However, this method is incomplete, as it only considers the case of image point translation. In actual measurements, when the image plane tilts or the system focal length deviates, the actual image point is scaled relative to the theoretical image point; when the image plane rolls, the actual image point is rotated relative to the theoretical image point. These deviations cannot be corrected by a single translation. Therefore, this embodiment proposes a spectral coordinate correction method based on least squares and polynomial fitting, see [link to documentation]. Figure 3 This improves the accuracy of spectrum reconstruction while reducing computational load. Specifically:
[0082] S1. The two-dimensional spectrum of the calibration light source is obtained by measuring the calibration light source using a echelle spectrometer;
[0083] S2. Perform image processing on the two-dimensional spectrum of the calibration light source to obtain the actual image points corresponding to the wavelength of the calibration light source;
[0084] S3. Obtain the theoretical image point corresponding to the wavelength of the calibrated light source using simulation software;
[0085] S4. By using the least squares method, the actual image points are fitted to the theoretical image points to obtain the corrected image point coordinates, and the image point coordinate correction coefficients A1, A2, B1, B2, C1, and C2 are obtained.
[0086] S5. Calculate the corrected coordinate residuals of the image point coordinates corresponding to the wavelength of the calibrated light source;
[0087] S6. Evaluate whether the coordinate residual level meets the accuracy requirements. If it does, proceed to S10; otherwise, proceed to S7.
[0088] S7. By using polynomial fitting, the corrected image point coordinates are fitted to the theoretical image points twice, and the residual compensation coefficients A′1, A′2, B1′, B2′, C1′, and C2′ are obtained.
[0089] S8. Use a echelle spectrometer to measure the light source under test and obtain a two-dimensional spectrum of the light source under test;
[0090] S9. Perform image processing on the two-dimensional spectrum of the light source under test to obtain the actual image points corresponding to the wavelength of the light source under test;
[0091] S10. Use coordinate correction coefficients A1, A2, B1, B2, C1, and C2 to correct the actual image points corresponding to the wavelength of the light source under test, and obtain the corrected coordinates of the actual image points corresponding to the wavelength of the light source under test.
[0092] S11. Reconstruct the spectrum of the actual image point corresponding to the wavelength of the light source under test by performing spectral reconstruction to obtain the wavelength data of the light source under test;
[0093] S12. Calculate the corrected coordinate residual of the actual image point corresponding to the wavelength of the light source under test, and use the residual compensation coefficients A′1, A′2, B1′, B2′, C1′, C2′ to perform residual compensation on the corrected coordinates obtained in S10 to obtain the second-order fitted coordinates;
[0094] S13. Perform spectral reconstruction on the second-fit coordinates to obtain the wavelength data of the light source under test. The wavelength data of the light source under test obtained here is no different from the wavelength data of the light source under test in step S11. S11 is because the corrected coordinates were not compensated (because the accuracy was already sufficient). S13 is because the accuracy of the correction after step S10 was insufficient, so a second compensation correction is performed through steps S12 and S13.
[0095] Preferably, in step S4, the discrepancy between the actual image point S' and the theoretical image point S can be caused by many factors. These external and internal factors can be equivalent to the theoretical image point obtained through scaling, translation, and rotation. First, consider scaling and translation:
[0096]
[0097] Where a1 and a2 are scaling factors, and b1 and b2 are translation factors. Assume the wavelength λ is known. i (i=1,2,…,n), corresponding to the coordinates S of the theoretical image point, and the coordinates S'(x) of the actual image point measured by the array detector. i ',y i The scaling and translation coefficients (i = 1, 2, ..., n) can be obtained by the least squares method.
[0098] However, the area array detector is not precisely fixed; the image plane will roll during installation, and the correction of the image points must take the rotation factor into account. It is necessary to first translate the coordinate system to the center of rotation before correcting the rotation vector. Combining the scaling and translation formula (8) and extending it to the general case, we can obtain:
[0099]
[0100] Where θ is the rotation angle, and x0 and y0 are the centers of rotation, it can also be written in the form of a system of equations:
[0101]
[0102] There are 7 variables to be fitted, requiring at least 7 sets of theoretical and actual image point coordinates with known wavelengths for calibration. The computational load is significant, but in most cases, the calculations can be simplified, and the values of x0 and y0 can be directly obtained from the actual situation. Figure 2Taking the spectral reconstruction model as an example, the rotation center is the center O” of the phase plane of the area array sensor: x0=W / 2,y0=0. That is, it is half of the image plane width w, and does not need to be used as a variable for fitting. The simplified formula (3) is as follows:
[0103]
[0104] {S'(x) i ',y i Substituting '),i=1,2,3…n} into the above equation, we obtain the system of equations:
[0105]
[0106] Solve the matrix equation system (5) using equation (6). Figure 3 Step S4 is shown below:
[0107]
[0108] Since the objective function is convex, taking the derivative of the objective function and setting its reciprocal to zero yields the optimal solution x. * :
[0109]
[0110] Therefore, the optimal solution x * :
[0111] A T Ax * -A T b = 0 (15)
[0112] x * =(A T A) -1 A T b (16)
[0113] The analytical solution to the coefficient matrix is as follows:
[0114]
[0115] Preferably, step S7 is as follows:
[0116] Actual image point coordinates S'(x) i ',y i After correction by formula (11), the coordinates of the theoretical image point S(x) are obtained. i ,y i They are already very similar, but residuals still exist:
[0117]
[0118] The residual is a function of wavelength λ. A second-order polynomial is introduced to fit the residual:
[0119]
[0120] Substituting the data into the formula yields the matrix:
[0121]
[0122] The residual compensation coefficients A′1, A′2, B1′, B2′, C1′, and C2′ are obtained from equation (10):
[0123]
[0124]
[0125] The image point coordinates are estimated after compensation of the corrected image point coordinates. Substituting the wavelengths into the spectrum reconstruction formula, we obtain:
[0126]
[0127] When the instrument's operating environment remains unchanged, the parameters mentioned above only need to be measured once using a mercury lamp to calibrate the wavelength. The resulting correction and compensation coefficients can be used for measurements at any other wavelength.
[0128] Preferably, embodiments of this application also provide a specific implementation of an electronic device capable of implementing all steps in the least squares and polynomial fitting-based echelle spectrometer spectral coordinate correction method described in the above embodiments. The electronic device specifically includes the following components:
[0129] Processor, memory, communications interface, and bus;
[0130] The processor, memory, and communication interface communicate with each other via a bus; the communication interface is used to realize information transmission between server-side devices, metering devices, and user-side devices.
[0131] Preferably, the processor is used to call a computer program in memory, and when the processor executes the computer program, it implements all the steps in the method for correcting the coordinates of a echelle spectrometer based on least squares and polynomial fitting in the above embodiments.
[0132] Embodiments of this application also provide a computer-readable storage medium capable of implementing all steps of the echelle spectrometer spectral coordinate correction method based on least squares and polynomial fitting in the above embodiments. The computer-readable storage medium stores a computer program that, when executed by a processor, implements all steps of the echelle spectrometer spectral coordinate correction method based on least squares and polynomial fitting in the above embodiments.
[0133] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to interchangeably. Each embodiment focuses on its differences from other embodiments. In particular, hardware + program embodiments are relatively simple in description because they are fundamentally similar to method embodiments; relevant parts can be referred to the descriptions in the method embodiments.
[0134] The foregoing has described specific embodiments of this specification. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps recited in the claims may be performed in a different order than that shown in the embodiments and may still achieve the desired result. Furthermore, the processes depicted in the drawings do not necessarily require the specific or sequential order shown to achieve the desired result. In some embodiments, multitasking and parallel processing are possible or may be advantageous.
[0135] While this application provides method operation steps as shown in the embodiments or flowcharts, more or fewer operation steps may be included based on conventional or non-inventive labor. The order of steps listed in the embodiments is merely one possible execution order among many and does not represent the only execution order. In actual device or client product execution, the method can be executed sequentially as shown in the embodiments or drawings, or in parallel (e.g., in a parallel processor or multi-threaded processing environment).
[0136] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0137] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0138] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0139] This invention is not limited to the embodiments described above. The above description of specific embodiments is intended to illustrate and explain the technical solutions of this invention. The specific embodiments described above are merely illustrative and not restrictive. Without departing from the spirit and scope of the claims, those skilled in the art can make many specific modifications based on the teachings of this invention, and these modifications all fall within the scope of protection of this invention.
Claims
1. A method for correcting spectral coordinates in a mid-step spectrometer based on least squares and polynomial fitting, characterized in that, include: S1. The two-dimensional spectrum of the calibration light source is obtained by measuring the calibration light source using a echelle spectrometer; S2. Perform image processing on the two-dimensional spectrum of the calibration light source to obtain the actual image points corresponding to the wavelength of the calibration light source; S3. Obtain the theoretical image point corresponding to the wavelength of the calibrated light source using simulation software; S4. By using the least squares method, the actual image points are fitted to the theoretical image points to obtain the corrected image point coordinates, and the image point coordinate correction coefficients A1, A2, B1, B2, C1, and C2 are obtained. S5. Calculate the corrected coordinate residuals of the image point coordinates corresponding to the wavelength of the calibrated light source; S6. Evaluate whether the coordinate residual level meets the accuracy requirements. If it does, proceed to S10; otherwise, proceed to S7. S7. By using polynomial fitting, the corrected image point coordinates are fitted to the theoretical image points twice, and the residual compensation coefficients A′1, A′2, B1′, B2′, C1′, and C2′ are obtained. S8. Use a echelle spectrometer to measure the light source under test and obtain a two-dimensional spectrum of the light source under test; S9. Perform image processing on the two-dimensional spectrum of the light source under test to obtain the actual image points corresponding to the wavelength of the light source under test; S10. Use coordinate correction coefficients A1, A2, B1, B2, C1, and C2 to correct the actual image points corresponding to the wavelength of the light source under test, and obtain the corrected coordinates of the actual image points corresponding to the wavelength of the light source under test. S11. Reconstruct the spectrum of the actual image point corresponding to the wavelength of the light source under test by performing spectral reconstruction to obtain the wavelength data of the light source under test; S12. Calculate the corrected coordinate residual of the actual image point corresponding to the wavelength of the light source under test, and use the residual compensation coefficients A′1, A′2, B1′, B2′, C1′, C2′ to perform residual compensation on the corrected coordinates obtained in S10 to obtain the second-order fitted coordinates; S13. Reconstruct the spectrum from the second-fit coordinates to obtain the wavelength data of the light source under test.
2. The method for correcting spectral coordinates of a mid-level echelle spectrometer based on least squares and polynomial fitting as described in claim 1, characterized in that, Step S4 is as follows: Several external and internal factors lead to the actual image point S'(x) i ',y i ') and theoretical image point S(x i ,y i The positions are inconsistent, so external and internal factors are equivalent to theoretical image points obtained through scaling, translation, and rotation; first consider scaling and translation. Where a1 and a2 are scaling factors, and b1 and b2 are translation factors; assuming the wavelength λ is known... i (i = 1, 2, ..., n), whose corresponding theoretical image point coordinates S(x i ,y i (i = 1, 2, ..., n), the actual image point coordinates S'(x) measured by the area array detector. i ',y i (i = 1, 2, ..., n), the scaling and translation coefficients are obtained by the least squares method; Then, a rotation operation is used to correct the actual image points. The image plane coordinate system is translated to the rotation center, and the rotation vector is corrected. Combining the scaling and translation formula (1) and extending it to be expressed using mathematical matrices, we get: Where θ is the rotation angle, and x0 and y0 are the centers of rotation, the equations can be written in the following form: There are 7 variables that need to be fitted, and at least 7 sets of known wavelength image point coordinates and actual image point coordinates are required for calibration. The values of x0 and y0 are obtained directly from the actual situation. The simplified formula (3) is as follows: {S'(x) i ',y i Substituting '),i=1,2,3…n} into the above equation, we obtain the system of equations: Solve the matrix equation system (5) using equation (6). Since the objective function is convex and b is the coefficient matrix, taking the derivative of the objective function and setting its reciprocal to zero yields the optimal solution x. * : Optimal solution x * : A T Ax * -A T b=0 (8) x * =(A T A) -1 A T b (9) The analytical solution to the coefficient matrix is as follows:
3. The method for correcting spectral coordinates of a mid-level echelle spectrometer based on least squares and polynomial fitting according to claim 1, characterized in that, Step S7 is as follows: Actual image point coordinates S'(x) i ',y i After correction by formula (17), the image point coordinates S(x) are found to be the same as those of the theoretical image point. i ,y i There is a residual (Δx) i ,Δy i ): The residual is a function of wavelength λ. A second-order polynomial is introduced to fit the residual: Substituting the coordinate data into the formula yields the matrix: Solving for the residual compensation coefficients A′1, A′2, B1′, B2′, C1′, and C2′ yields: The image point coordinates are estimated after compensation of the corrected image point coordinates. Substituting the wavelengths into the spectrum reconstruction formula, we obtain:
4. An electronic device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the method for correcting the spectral coordinates of a echelle spectrometer based on least squares and polynomial fitting as described in any one of claims 1 to 3.
5. A computer-readable storage medium having a computer program stored thereon, characterized in that, When executed by a processor, the computer program implements the steps of the method for correcting the coordinates of a echelle spectrometer based on least squares and polynomial fitting as described in any one of claims 1 to 3.
Citation Information
Patent Citations
Method and system for detecting and authenticating a taggant in a marking via surface-enhanced raman spectroscopy
CA3189045A1
Self-adaptive surface absorption spectrum analysis method and system, storage medium and equipment
CN109991181A