Method for performing spectrogram inversion structure based on upper bound confidence interval inverse Monte Carlo

By introducing reinforcement learning strategies based on upper bound confidence intervals in the inverse Monte Carlo method, intelligent selection of atomic movement strategies solves the problem of inefficient optimization of traditional RMC methods in large-scale atomic systems or complex material systems, and achieves more efficient and precise structural inversion.

CN120068653AActive Publication Date: 2025-05-30SHANGHAI UNIV
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202510235161.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-28
Publication Date
2025-05-30
Estimated Expiration
2045-02-28

AI Technical Summary

Technical Problem

The traditional reverse Monte Carlo (RMC) method has inefficient optimization problems in large-scale atomic systems or complex material systems, especially in the treatment of multi-element systems or non-periodic structures. Reliance on constraints may limit the flexibility and accuracy of the algorithm, resulting in insufficient accuracy of the results.

Method used

The inverse Monte Carlo method based on upper bound confidence interval (UCB) is adopted, combined with the UCB strategy in reinforcement learning, and intelligently select the optimal atomic movement strategy during the optimization process, dynamically balance exploration and utilization, improve global search capabilities and accelerate convergence.

Benefits of technology

Through the UCB-driven atomic movement selection mechanism, the dependence on experimental parameters is reduced, the calculation cost is reduced, and the accuracy and efficiency of structural inversion are improved. It is suitable for spectral inversion modeling of multi-element systems, aphasic materials, nanostructures and dynamic evolution processes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120068653A_ABST
    Figure CN120068653A_ABST
Patent Text Reader

Abstract

The invention provides an inverse Monte Carlo method based on an upper bound confidence interval (UCB), and the inverse Monte Carlo method is used for structural optimization in spectrogram inversion. According to the method, an upper bound confidence interval strategy in reinforcement learning is combined, an optimal atom movement strategy is intelligently selected in the optimization process, and efficient structure inversion modeling is achieved. A user can specify an experiment spectrogram according to needs, and a program can efficiently conduct reverse speculation on structure information under the condition that an initial structure is not used.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of new materials, and more particularly, to a method for spectral inversion structure based on inverse Monte Carlo of the Upper Confidence Bound (UCB). Background Art

[0002] The development of the Reverse Monte Carlo (RMC) method can be traced back to 1988, first proposed by McGreevy and Pusztai. Its original intention was to reconstruct the atomic structure of disordered materials from experimentally obtained scattering data (such as neutron scattering). The core idea of RMC is to optimize the atomic positions to make the simulation results as consistent as possible with the experimental data. In the early days, RMC was mainly applied to the research of liquids, glasses, and amorphous materials. With the in-depth research, constraint conditions (such as chemical bond length, coordination number, and density, etc.) were gradually introduced to improve the physical rationality of the model. In the 1990s, RMC was widely used in the research of disordered systems and extended to more complex material systems, such as nanomaterials and crystalline defects. After entering the 2000s, thanks to the rapid development of computing power, RMC was combined with other technologies (such as molecular dynamics simulation and density functional theory), which further improved the modeling accuracy. In the past decade, the application scope of the RMC method has continued to expand. Combining with high-energy X-ray and synchrotron radiation technologies, its simulation ability has been extended from the microscopic atomic structure to time-resolved dynamic structure changes. In the field of nanomaterials, the data of small-angle X-ray scattering (SAXS) can be analyzed by the RMC model to reveal the shape, size distribution of particles, and the local structure of surface atoms. In composite materials and multi-component systems, combining with anomalous X-ray scattering (AXS) data, RMC can analyze the spatial distribution and interaction of each element in the multi-element system. For example, the local defects of perovskite-structured oxides can be analyzed. RMC is also used in the research of defects in crystalline materials. Through the reverse modeling of X-ray diffraction data, the distribution of non-periodic structures such as dislocations and vacancies can be obtained. In addition, in time-resolved X-ray scattering (such as pump-probe experiments), the RMC method is used to analyze the evolution process of dynamic structures, such as the transient atomic distribution during liquid-solid phase transitions or chemical reactions. In recent years, with the progress of computer technology, RMC is gradually combined with methods such as molecular dynamics and density functional theory to achieve multi-scale modeling from local to long-range scales, and is expected to play a greater role in more complex multi-component material systems, dynamic experimental environments, and machine learning-driven modeling optimization. RMC plays an important role in current materials science, condensed matter physics, and the research of disordered systems. However, it depends on high-quality initial structures and expert knowledge, and requires reasonable constraint conditions and high-precision experimental data to ensure the physical reliability of the modeling. In addition, RMC requires a large amount of computing resources and a long optimization process. It may get stuck in local minima or fail to effectively explore the global structure during the sampling process. For systems with a large number of atoms, it becomes extremely difficult to move atoms, which easily leads to a decrease in the acceptance rate, resulting in a reduction in optimization efficiency, thus affecting the convergence of the calculation, increasing the large computational consumption and time cost, and being unfavorable for the efficient modeling of large-scale systems and the accurate analysis of dynamic structure evolution.

[0003] Therefore, the prior art has the following problems: for large-scale atomic systems or complex material systems, the traditional RMC method requires a large number of Monte Carlo iterations, resulting in a long calculation time and difficulty in meeting the actual application requirements. In addition, when dealing with multi-element systems or non-periodic structures, the traditional RMC method relies on constraint conditions, and the introduction of these constraint conditions may limit the flexibility and accuracy of the algorithm, resulting in insufficient precision of the results.

[0004] Therefore, developing an exploration process that can accelerate atomic movement and optimizing the selection strategy has become one of the key challenges in improving the efficiency and accuracy of RMC. In recent years, with the rapid development of machine learning (ML) technology, reinforcement learning (RL) has been proposed as a possible improvement method, providing a new idea for the optimization of RMC. In RMC, the adjustment of atomic positions can be regarded as a decision-making process based on reward feedback. The agent evaluates the effectiveness of structure optimization in each adjustment step and gradually learns the optimal adjustment strategy. This method can not only avoid inefficient sampling caused by blindly randomly moving atoms but also improve the global search ability under the premise of meeting experimental constraints, thus accelerating convergence. Summary of the Invention

[0005] To solve the problem of inefficient optimization of the existing reverse Monte Carlo (RMC) method in large-scale atomic systems or complex material systems, the present invention proposes an inverse Monte Carlo method based on the upper confidence bound for structure optimization in spectral inversion. This method combines the upper confidence bound strategy in reinforcement learning to intelligently select the optimal atomic movement strategy during the optimization process, realizing efficient structure inversion modeling. The core idea of this method is that during the RMC optimization process, each possible atomic movement is regarded as a decision option, and the UCB strategy is used to dynamically balance exploration and exploitation. The UCB strategy can adaptively adjust the selection probability of atomic movement according to the current optimization history, enhancing the exploratory nature in the initial stage of optimization to avoid getting trapped in local optimal solutions, and strengthening high-yield decisions in the later stage, thereby accelerating optimization convergence and improving the accuracy of structure inversion. Through the UCB-driven atomic movement selection mechanism, the present invention reduces the dependence on experimental parameters and at the same time reduces the computational cost brought by blind trial and error. Combining with a physically guided reward function, this method improves the global search ability while meeting the experimental scattering spectrum constraints, making the final optimization result more in line with the physical real structure. The present invention is applicable to spectral inversion modeling of multi-element systems, non-periodic materials, nanostructures, and dynamic evolution processes, and has broad application prospects in the fields of materials science, catalysis, nanotechnology, and condensed matter physics.

[0006] The present invention adopts the following technical solutions and steps:

[0007] Step S1: using an existing reference crystal structure or randomly generating a crystal / amorphous structure as an initialization structure;

[0008] Step S1.1: If reference structure information is available, select a given composition or combination of existing components as the basic reference, use the Materials Project as the database for collecting crystal structures, and use the official structure download tool;

[0009] Step S1.2: Call the official software package Pymatgen provided by the Materials Project to convert the extracted crystal structure and save it as a file with the suffix .vasp;

[0010] Step S1.3: If there is no reference structure information, call the random generation program to generate a crystal / amorphous structure file and automatically save it as a file with the suffix .vasp

[0011] Step S2: Connecting the initialized structure to the diffraction pattern forward calculation program to obtain a structure simulation spectrum;

[0012] Step S2.1: Initialization of diffraction spectrum simulation calculation. The initialization structure file (.vasp format) obtained from step S1 is used as input to call the diffraction spectrum forward calculation program, such as the structure factor calculation method based on the Debye scattering equation or the Fourier transform, to calculate its theoretical diffraction spectrum.

[0013] Step S2.2: Determine the appropriate scattering factor according to the type of diffraction experiment (e.g., X-ray diffraction XRD, neutron scattering NS, or electron diffraction ED). For XRD, select the atomic X-ray scattering factor; for neutron scattering, select the element-specific neutron scattering length; for electron diffraction, use dynamic scattering theory for correction.

[0014] Step S2.3: Atomic coordinate information r based on the initialization structure ij The structure factor S(q) corresponding to the scattering vector q is:

[0015]

[0016] Step S2.4: Perform Fourier transform based on the calculated structure factor to obtain the scattering intensity I(q) = |S(q)| 2 , and the obtained scattering spectrum is normalized to make it comparable with the experimental target spectrum.

[0017] Step S3: importing the target diffraction pattern into the real-time monitoring program;

[0018] Step S3.1: Import the target diffraction spectrum obtained from experimental measurement. The data format can include common experimental spectrum data formats such as.chi,.dat,.xy,.txt, etc., and perform data preprocessing (such as noise removal, baseline correction, peak position matching, etc.).

[0019] Step S3.2: Initialize the real-time supervised calculation. Initialize the supervised calculation module, which is used to evaluate the similarity between the current simulated spectrum and the target spectrum, and can accept various evaluation method metrics, such as root mean square error, Pearson correlation coefficient, Chi2 value difference and other similarity evaluation methods.

[0020] Step S3.3: Feed the error back to the optimization module. If the similarity score of the current optimized structure does not reach the set threshold, call the upper confidence bound calculation program.

[0021] Step S4: Start the upper confidence bound calculation program and perform decision atom movement;

[0022] S4.1: Initialize the UCB weights: In the absence of historical movement success rate data, assign uniformly distributed initial weights to all atoms to ensure that all atoms have an equal chance of being selected by weighted random selection during the initialization stage;

[0023] S4.2: Randomly select a candidate atom: Randomly select an atom as a movement candidate according to the current UCB weights, where the UCB weights dynamically adjust the randomly selected weights assigned to each atom according to the historical movement success rate throughout the process.

[0024] S4.3: Generate a random movement vector: Generate a random movement vector for the selected atom. The direction of the movement vector is uniformly distributed within a preset spherical shell, and the radial length of the spherical shell is within the range of the minimum and maximum movement lengths selected during initialization.

[0025] S4.4: Check the minimum distance constraint: Try to move the selected atom and check whether the movement violates the minimum distance constraint. If it is found that the minimum distance constraint is violated, regenerate the movement vector until the constraint condition is satisfied;

[0026] S4.5: Decide whether to accept the movement based on the Metropolis criterion: Calculate the change in the system metric (such as Chi2 value) before and after the movement, and decide whether to accept this movement according to the Metropolis criterion. If the movement is accepted, update the corresponding atom's UCB weights according to the movement result.

[0027] Step S5: Determine by the real-time supervision program whether the degree of conformity of the simulated spectrum of the structure under adjustment reaches the preset accuracy;

[0028] Step S5.1: Calculate the degree of conformity between the current structure simulated spectrum and the target spectrum

[0029] After the atomic movement decision in step S4, the updated structure is used to recalculate the simulated diffraction spectrum, which is then compared with the target diffraction spectrum. According to the comparison result, a conformity threshold is calculated. This conformity threshold reflects the similarity between the simulated spectrum and the target spectrum. Conformity can be calculated by various methods, such as root mean square error (RMSE), correlation coefficient (e.g., Pearson correlation coefficient), Chi2 value, etc. The specific choice depends on the nature of the problem and the required accuracy.

[0030] The real-time supervision program will determine whether the conformity has reached the conformity threshold. If the conformity reaches the threshold, it will enter step S6 to end the optimization process. If the conformity does not reach the threshold, it will return to step S4 to continue the atomic movement optimization to further optimize the matching degree between the structure simulation spectrum and the target spectrum.

[0031] Step S6: The program ends, and the final adjusted material structure file is output.

[0032] Step S6.1: Output the final optimized structure. When the conformity reaches the set threshold, the RMC optimization process is terminated.

[0033] Step S6.2: Specify the path of the preset save file and save the finally optimized atomic structure to a standardized structure file format. The standardized structure file format includes but is not limited to:

[0034] VASP format (.vasp) is suitable for first-principles calculations

[0035] XYZ format (.xyz) is suitable for visualization software, such as OVITO

[0036] CIF format (.cif) is suitable for database storage and diffraction analysis

[0037] LAMMPS data format (.data) is suitable for molecular dynamics simulations.

[0038] Meanwhile, the present invention also provides a computer-readable storage medium, on which computer program instructions for executing the above method are stored. When the instructions are executed on a computer, the steps of the method are implemented.

[0039] And a computer system for executing the above method, including a processor, a memory, and input / output devices. The memory stores computer program instructions for executing the method, and the processor executes the instructions to implement the method.

[0040] Compared with the prior art, the present invention has the following obvious outstanding substantial features and remarkable advantages:

[0041] 1. The present invention reduces the experimental dependence, decreases the demand for a large amount of expensive computations, while improving the accuracy of structure inversion, avoiding high costs and blindness, and enhancing the efficiency of material structure analysis.

[0042] 2. The present invention introduces the Upper Confidence Bound (UCB) strategy in reinforcement learning, optimizes the atomic movement process through intelligent decision-making, effectively solves the deficiencies of the existing RMC method (especially in terms of efficiency, flexibility, global search ability, and resource consumption), and significantly improves the efficiency and accuracy of structure inversion.

[0043] 3. By dynamically adjusting the radial length of the movement vector according to the atomic type and system complexity (for example, the movement range of surface atoms is greater than that of bulk atoms), the inversion of SAXS data for nanogold particles shows that the reconstruction accuracy of surface atoms (RDF matching degree) is increased from 85% of the traditional method to 93%, and the optimization time is reduced by 25%.

[0044] 4. The inverse Monte Carlo method based on Upper Confidence Bound optimization proposed by the present invention is not limited to material science in its application, but can also be extended to other engineering fields, such as drug design, energy materials, nanotechnology, and functional polymer materials, etc., and has broad application prospects. The optimized structure file supports output in formats such as VASP, CIF, LAMMPS, etc., and can be directly used for first-principles calculations, molecular dynamics simulations, or database storage. For example, a.vasp format file can be directly imported into the VASP software for band calculations, and a.cif file can be uploaded to the Materials Project database for sharing. The cross-platform compatibility of the optimized structure shortens the entire process time from inversion to performance prediction by 50%.

[0045] 5. The intelligent decision-making optimization method proposed by the present invention retains the process information during the structure optimization process, and can further provide support for other scientific research such as machine learning-driven material discovery, inverse design optimization, and intelligent structure prediction, promoting the development of the integration of data-driven and physical modeling. Description of the Drawings

[0046] Figure 1 It shows the structure of the initialized structure in the embodiment.

[0047] Figure 2 It is the simulated spectrum calculated for the initial structure in the embodiment.

[0048] Figure 3 It is the visualization of the initial structure (left) and the atoms of the structure during the optimization process selected by UCB (right) in the embodiment.

[0049] Figure 4 It is the comparison chart of the initial structure (upper) and the structure during the optimization process (lower) in the embodiment, respectively comparing the radial distribution function and the structure factor. Detailed implementation mode

[0050] Taking the structure inversion of Al alloy as an example, the present invention will be described in detail below in combination with the accompanying drawings and specific preferred embodiments, but the protection scope of the present invention should not be limited thereby.

[0051] Example 1

[0052] Step S1: Since there is no Al structure that can be referenced in the database, a random generation program is called to generate a structure file, which includes lattice parameters a, b, c, α, β, γ and atomic coordinates, information that can completely represent the atomic structure of the material;

[0053] Step S2.1: Input the randomly generated Al structure file in S1;

[0054] Step S2.2: By calling the XRD forward calculation program, read the structure file, and automatically obtain the correction method according to the type of the target diffraction experiment;

[0055] Step S2.3: Combining the structure provided in S2.1 and the correction method determined in S2.2, calculate the structure factor;

[0056] Step S2.4: Perform Fourier transform on the structure factor calculated in S2.3, and the spectral information in the initial state can be obtained. Perform spectral normalization processing and store the data.

[0057] Step S3.1: If it is the first time to execute step S3.1, read the experimental test spectral data exp.txt file, perform the same normalization method as in S2.4 on the experimental spectrum and store the data. If it is not the first time to execute step 3.1, directly read the experimental spectrum from the stored data;

[0058] Step S3.2: Call the real-time supervision program for real-time calculation, and record the Chi2 value between the current calculated simulation spectrum and the calculated spectrum;

[0059] Step S3.3: Numerically feedback to the error recording module of the main program. In the current example, it is set that the error reduction amplitude within one thousand steps is less than one in one hundred thousand. If the convergence requirement cannot be met, execute the fourth step;

[0060] Step S4.1: Call the upper confidence bound calculation program. If it is the first time to start step S4.1, initialize the UCB weight as a uniform distribution weight, otherwise directly skip S4.1;

[0061] Step S4.2: Dynamically adjust the randomly selected weights assigned to each atom according to the success rate under UCB obtained from the historical movement, and select Al atoms;

[0062] Step S4.3: Move the selected Al atoms by random walk;

[0063] Step S4.4: Check whether the structure after the move satisfies the minimum distance constraint. If not, move again;

[0064] Step S4.5: Calculate the change in the Chi2 value before and after the move, use the Metropolis criterion to decide whether to accept this move, and further update the UCB weight according to the move result.

[0065] Step S5.1: Calculate the conformity between the simulated spectrum of the current structure and the target spectrum, using the same evaluation method as in S3.2;

[0066] Step S5.2: Call the calculation in Step S3.2, record the Chi2 value between the current calculated simulated spectrum and the calculated spectrum, check whether the convergence accuracy is reached. If not, repeat Step S4. If satisfied, proceed to S6;

[0067] Step S6.1: Save the atomic structure and close the database storage function;

[0068] Step S6.2: Output the information of the atomic structure of the last frame in the running directory with the file suffix of.data.

Claims

1. A method for spectral inversion structure based on inverse Monte Carlo with upper confidence interval, characterized in that: The following steps are involved: Step S1: providing an initialization material structure, wherein the initialization material structure is obtained in one of the following two ways: using an existing reference crystal structure; if there is no existing reference crystal structure, randomly generating a crystal structure or an amorphous structure; Step S2: generating a simulated diffraction spectrum of the initialization structure by a diffraction pattern forward calculation program, comprising: S2.1: Select an appropriate scattering factor from the preset scattering factor library according to the target diffraction experiment type; S2.2: Calculate the structure factor S(q) corresponding to each scattering vector based on the atomic coordinate information in the initialization material structure file and the selected scattering factor; S2.2: Perform Fourier transformation on the structure factor to calculate the scattering intensity I(q)=|S(q)| 2 , and normalized to obtain a simulated diffraction spectrum comparable to the experimental target diffraction spectrum; Step S3: importing the target diffraction spectrum into the real-time monitoring program, and initializing the real-time monitoring program to evaluate the conformity between the simulated diffraction spectrum and the target spectrum; Step S4: Start the upper confidence interval (UCB) calculation program and dynamically adjust the atom movement strategy, including the following sub-steps: S4.1: Initialize or update UCB weights and adjust the probability of atom selection according to the historical move success rate; S4.2: Randomly select candidate atoms based on UCB weights and generate random movement vectors whose directions are uniformly distributed within the spherical shell and whose radial lengths are within a preset range; S4.3: Check whether the minimum distance constraint is violated after the move, and if so, regenerate the move vector; S4.4: accept or reject the move according to the Metropolis criterion, which is based on the change in Chi2 values ​​before and after the move; S4.5: Update UCB weight according to the movement result; Step S5: Determine whether the conformity between the simulated spectrum and the target spectrum reaches a preset conformity threshold; if not, return to step S4; otherwise, output the optimized material structure file and end the optimization process.

2. The method for performing spectral inversion structure based on upper confidence interval inverse Monte Carlo according to claim 1, characterized in that: The step S1 comprises: S1.1: If a reference structure exists, extract the crystal structure from the Materials Project database and convert it into a .vasp file using the Pymatgen tool; S1.2: If there is no reference structure, call the random generation program to generate the crystal / amorphous structure file and save it in .vasp format.

3. The method for performing spectral inversion structure based on upper confidence interval inverse Monte Carlo according to claim 1, characterized in that: The calculation formula of the structure factor is as follows: Among them, r ij is the atomic coordinate information of the initialized structure, and q is the scattering vector.

4. The method for performing spectral inversion structure based on upper confidence interval inverse Monte Carlo according to claim 1, characterized in that: The conformity evaluation index in step S3 includes root mean square error, Pearson correlation coefficient or Chi2 value difference.

5. The method for performing spectral inversion structure based on upper confidence interval inverse Monte Carlo according to claim 1, characterized in that: In step S4.2, the radial length of the spherical shell is dynamically adjusted according to the atom type and system complexity.

6. A computer-readable storage medium having stored thereon computer program instructions for executing the method according to any one of claims 1 to 5, wherein when the instructions are executed on a computer, the steps of the method are implemented.

7. A computer system for executing the method according to any one of claims 1 to 5, comprising a processor, a memory and an input / output device, wherein the memory stores computer program instructions for executing the method, and the processor executes the instructions to implement the method.

Citation Information

Patent Citations

  • Parallel simulated annealing quick optimization method for inversion measurement of multiple thermophysical parameters of material

    CN111898237A

  • Light-weight shielding depth coupling optimization method for small reactor

    CN116595885A

  • Structural optimization method for free-form surface super-structure surface deflector based on reinforcement learning

    CN119442909A

  • Applying monte carlo and machine learning methods for robust convex optimization based prediction algorithms

    US20210081828A1

  • Method and system for reverse design of micro-nano structure based on deep neural network

    US20220398351A1