A pressure data processing method and apparatus
Patent Information
- Application Number
- CN202610866796.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-16
- Publication Date
- 2026-09-15
AI Technical Summary
[0021] The pressure data processing method and apparatus provided in this application, by globally pre-normalizing the contribution of atomic stress volume to the total volume of the simulated system and performing posterior volume correction in combination with the actual number of grids or the real grid volume, effectively avoids the local pressure and stress conversion errors caused by the indivisibility between the simulation box size and the grid size, boundary grid distortion, and the fixed preset grid volume in existing methods. Furthermore, by suppressing the instantaneous fluctuations of molecular thermal motion based on multi-time step sampling time averaging, the numerical accuracy and stability of local pressure and stress tensor statistics in molecular dynamics simulation can be improved.
Smart Images

Figure CN122762018A_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of molecular dynamics simulation data processing technology, and in particular relates to a pressure data processing method and apparatus. Background Technology
[0002] In molecular dynamics simulations, pressure and stress tensors are important physical quantities characterizing the mechanical state of a system. For homogeneous systems, the overall system pressure can usually determine the simulated state; however, for multi-component systems, interfacial systems, porous systems, or confined fluid systems, obtaining only the overall system pressure often fails to reflect local pressure differences. Therefore, it is necessary to obtain the pressure or stress distribution at different spatial locations within the simulated system.
[0003] Existing molecular dynamics software can output global pressure and calculate atomic-scale stress tensor data. Based on the atomic stress tensor, the atomic contributions within a spatial region can be statistically analyzed to obtain local pressure or stress-related information. However, the atomic-scale stress tensor is usually not a direct representation of local physical stress, but rather a stress-volume contribution in the form of a pressure-volume product. To obtain local pressure or stress in units of pressure, this stress-volume contribution needs to be divided by an appropriate volume.
[0004] In local stress statistics, a common practice is to divide the simulated system into a spatial grid and then statistically analyze the stress volume contribution of atoms within each grid. However, when the simulation box size is not divisible by the preset grid size, the actual number of generated grids, boundary grid sizes, or grid volumes may differ from the pre-assumed grid volumes. If the preset grid volume is directly used for normalization in the input script, such as by dividing it directly by a set 0.5×0.5 or 1×1 grid area, it may lead to errors in the local stress or pressure conversion.
[0005] There is currently no effective solution for accurately determining local pressure. Summary of the Invention
[0006] The purpose of this application is to provide a pressure data processing method and apparatus that can achieve accurate and efficient determination of local pressure.
[0007] This application provides a pressure data processing method and apparatus, which are implemented as follows: A stress data processing method, comprising: Obtain the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; The molecular dynamics simulation system is divided into spatial grids according to a preset spatial orientation and grid size, and the grid to which each atom belongs and the spatial position of each grid are determined. By pre-normalizing the stress volume contribution of each atom to the total volume of the simulated system, the intermediate pressure contribution or intermediate stress contribution of the atom is obtained. By reducing and summing the intermediate contributions of atomic pressure or stress belonging to the same grid, the intermediate pressure or stress values for each grid can be obtained: Time averaging is performed on intermediate pressure or stress values obtained within multiple time steps or multiple sampling windows to obtain time-averaged intermediate pressure or stress values in the grid. Based on the actual number of generated grids or the actual volume of each grid, the intermediate pressure or stress values of the time-averaged grids are corrected a posteriori to obtain the actual pressure or stress values of each grid: Based on the spatial location of each grid and the actual pressure or stress value of each grid, the global pressure or stress distribution of the simulation system is constructed. Cross-validation of local pressure statistics in global pressure or stress distribution results is performed using direct pressure path and tensor component path.
[0008] In one implementation, cross-validation of local pressure statistics in global pressure or stress distribution results is performed using direct pressure paths and tensor component paths, including: In the direct pressure path, the intermediate contribution of pressure at the atomic scale is:
[0009] in, As a contributor to the intermediate pressure, Let i be the volumetric stress contribution of the i-th atom in the xx component. Let be the stress volume contribution of the i-th atom in the yy component. Let i be the volumetric stress contribution of the i-th atom in the z-component. To simulate the total volume of the system; The first pressure result is obtained by reducing and summing the intermediate pressure contribution based on the grid, averaging over time, and making a posteriori correction. In the tensor component path, the six tensor components xx, yy, zz, xy, xz, and yz are pre-normalized, meshed, time-averaged, and posteriorly corrected to obtain the tensor components of each mesh. Then, the pressure is reconstructed based on the normal tensor components to obtain the second pressure result.
[0010] in, As a result of the second pressure, Let be the tensor component in the x-direction of the g-th grid. Let be the tensor component in the yy direction of the g-th grid. Let be the tensor component in the zz direction of the g-th grid; The difference between the first pressure result and the second pressure result is determined, and the reliability of the local pressure statistics result is determined based on the difference.
[0011] In one implementation, based on the actual number of generated grids or the actual volume of each grid, a post-hoc correction is performed on the intermediate pressure or stress values of the time-averaged grids to obtain the actual pressure or stress values of each grid, including: The actual pressure or stress value of each grid is calculated using the following formula: ; in, This represents the actual pressure or stress value of the g-th grid. This represents the intermediate pressure or stress value at the g-th grid after time averaging. Let g be the actual volume of the g-th grid. The actual number of grid cells generated. This is to simulate the total volume of the system.
[0012] In one implementation, the stress volume contribution of each atom is pre-normalized by simulating the total volume of the system to obtain the intermediate pressure contribution or intermediate stress contribution of the atom, including: The intermediate contribution of atomic pressure or stress can be obtained using the following formula:
[0013] in, For the first i The intermediate contribution of pressure or stress to an individual atom For the first i The volumetric stress contribution of each atom To simulate the total volume of the system, a , b These represent the x, y, and z directions, respectively. Correspondingly, the intermediate contributions of atomic pressure or stress belonging to the same grid are reduced and summed to obtain the intermediate pressure or stress quantities for each grid, including: Calculate the intermediate pressure or stress for each grid using the following formula:
[0014] in, This represents the intermediate pressure or stress value for the g-th grid. Let g be the set of atoms in the g-th grid.
[0015] In one implementation, obtaining the stress volume contribution of each atom of the target object in the molecular dynamics simulation system includes: The stress tensor in atomic dimensions, comprising six components (xx, yy, zz, xy, xz, yz), is output atom-by-atom using molecular dynamics simulation software. The stress tensor output is multiplied by the volume to obtain the stress volume contribution of each atom. Save the coordinates of all atoms and the corresponding stress volume contribution at each time step to construct a time-series atomic stress dataset.
[0016] In one embodiment, the molecular dynamics simulation system is divided into spatial grids according to a preset spatial orientation and grid size, and the grid to which each atom belongs and the spatial position of each grid are determined, including: Preset the spatial orientation and mesh size for two-dimensional or three-dimensional division, read the box boundary of the molecular dynamics simulation system, and calculate the actual side length of the molecular dynamics simulation system; The molecular dynamics simulation system is naturally meshed according to the mesh size, and the actual number of meshes generated in each direction and the total number of global meshes are calculated. For each grid, its spatial boundary coordinates and center coordinates are labeled, and the correspondence between grid number and spatial location is established; By using atomic spatial coordinates and grid interval indexing rules, the grid number to which each atom belongs is determined, and the coordinate mirroring correction of boundary atoms is performed in combination with periodic boundary conditions to complete the matching of all atoms and grids.
[0017] A pressure data processing device, comprising: The acquisition module is used to acquire the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; The determination module is used to divide the molecular dynamics simulation system into spatial grids according to a preset spatial direction and grid size, and to determine the grid to which each atom belongs and the spatial position of each grid. The normalization module is used to pre-normalize the stress volume contribution of each atom by simulating the total volume of the system, so as to obtain the intermediate pressure contribution or stress contribution of the atom. The reduction module is used to reduce and sum the intermediate contributions of atomic pressure or stress belonging to the same grid, to obtain the intermediate pressure or stress values for each grid. The time averaging module is used to perform time averaging on intermediate pressure or stress values obtained within multiple time steps or multiple sampling windows to obtain time-averaged intermediate pressure or stress values in the grid. The correction module is used to perform a posteriori correction on the intermediate pressure or stress values of the time-averaged meshes based on the actual number of meshes generated or the actual volume of each mesh, to obtain the actual pressure or stress values of each mesh. The building module is used to construct the global pressure or stress distribution results of the simulation system based on the spatial location of each grid and the actual pressure or stress value of each grid. The verification module is used to cross-validate the local pressure statistics in the global pressure or stress distribution results through the direct pressure path and the tensor component path.
[0018] A terminal device includes a processor and a memory for storing processor-executable instructions, wherein the processor implements the steps of the method described above when executing the instructions.
[0019] A computer-readable storage medium having a computer program / instructions stored thereon, which, when executed by a processor, implement the steps of the above-described method.
[0020] A computer program product includes a computer program / instructions that, when executed by a processor, implement the steps of the above-described method.
[0021] The pressure data processing method and apparatus provided in this application, by globally pre-normalizing the contribution of atomic stress volume to the total volume of the simulated system and performing posterior volume correction in combination with the actual number of grids or the real grid volume, effectively avoids the local pressure and stress conversion errors caused by the indivisibility between the simulation box size and the grid size, boundary grid distortion, and the fixed preset grid volume in existing methods. Furthermore, by suppressing the instantaneous fluctuations of molecular thermal motion based on multi-time step sampling time averaging, the numerical accuracy and stability of local pressure and stress tensor statistics in molecular dynamics simulation can be improved. Attached Figure Description
[0022] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0023] Figure 1 This is a flowchart of one embodiment of the stress data processing method provided in this application; Figure 2 This is a flowchart of an embodiment of the local pressure statistics method based on global volume pre-normalization and posterior mesh correction in molecular dynamics simulation provided in this application; Figure 3This is a two-dimensional pressure distribution time diagram provided in this application; Figure 4 This is a hardware structure block diagram of an electronic device for a pressure data processing method provided in this application; Figure 5 This is a schematic diagram of the module structure of one embodiment of the pressure data processing device provided in this application. Detailed Implementation
[0024] To enable those skilled in the art to better understand the technical solutions in this application, the technical solutions in the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort should fall within the scope of protection of this application.
[0025] It should also be noted that in the embodiments of this specification, certain software, components, models and other existing solutions in the industry may be mentioned. These should be regarded as exemplary and are only intended to illustrate the feasibility of implementing the technical solution of this application. However, it does not mean that the applicant has used or necessarily used the solution.
[0026] Existing methods for directly calculating pressure using preset local mesh volumes are susceptible to problems such as the simulation box size not being divisible by the mesh size, variations in the actual mesh number, or deviations in boundary mesh sizes. Furthermore, performing pressure statistics separately for different local regions is cumbersome, making it difficult to obtain reusable global pressure or stress distributions in a single operation. Local pressure results obtained from single-path calculations lack cross-validation, making it difficult to promptly identify errors in symbol processing, volume correction, or tensor component reconstruction. In this example, by globally pre-normalizing the atomic stress volume contribution using the total volume of the simulated system and performing posterior volume correction based on the actual mesh number or real mesh volume, this approach effectively avoids the local pressure and stress conversion errors caused by the indivisibility of the simulation box size and mesh size, boundary mesh distortion, and fixed preset mesh volumes in traditional methods. Simultaneously, by relying on multi-timestep sampling time averaging to suppress instantaneous fluctuations in molecular thermal motion, the numerical accuracy and stability of local pressure and stress tensor statistics in molecular dynamics simulations are significantly improved.
[0027] Furthermore, it is compatible with 2D / 3D mesh generation, various simulation ensembles such as NVT / NPT, and orthogonal periodic box systems. It eliminates the need to re-hardcode mesh volume parameters when changing mesh scales, exhibiting good adaptability to uniform meshes and meshes with non-uniform boundary volumes. It boasts strong versatility and portability, and achieves dual-path cross-validation by constructing direct pressure paths and tensor component reconstruction paths. This automatically identifies sign, volume correction, and tensor reconstruction errors during the calculation process, ensuring reliable and traceable statistical results. Using the method described in this example, a global mesh pressure stress field can be constructed only once, allowing for rapid extraction of mesh sets from interfaces, pores, and arbitrary irregular target regions as needed. It enables flexible multi-dimensional statistics such as mean, maximum / minimum, and distribution, eliminating the need for repeated atomic reduction calculations for different regions. This significantly simplifies post-processing operations and improves data analysis efficiency. It also supports decoupling analysis of stress contributions in multi-component systems, making it suitable for various molecular dynamics simulation scenarios such as multi-component fluids, interface systems, confined pores, and polymers. It balances statistical accuracy, computational efficiency, and engineering practicality without increasing computational overhead.
[0028] Figure 1 This is a flowchart of one embodiment of the stress data processing method provided in this application. Although this application provides method operation steps or apparatus structures as shown in the following embodiments or figures, more or fewer operation steps or module units may be included in the method or apparatus based on conventional or non-inventive effort. In steps or structures where there is no logically necessary causal relationship, the execution order of these steps or the module structure of the apparatus is not limited to the execution order or module structure described in the embodiments and figures of this application. When the method or module structure is applied in actual devices or terminal products, it can be executed sequentially or in parallel according to the method or module structure shown in the embodiments or figures (e.g., in a parallel processor or multi-threaded processing environment, or even a distributed processing environment).
[0029] Specifically, such as Figure 1 As shown, the pressure data processing method described above may include the following steps: Step 101: Obtain the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; Step 102: Divide the molecular dynamics simulation system into a spatial grid according to a preset spatial direction and grid size, and determine the grid to which each atom belongs and the spatial position of each grid. Step 103: Pre-normalize the stress volume contribution of each atom by simulating the total volume of the system to obtain the intermediate pressure contribution or intermediate stress contribution of the atom. For example, the intermediate contribution of pressure or stress to an atom can be obtained using the following formula:
[0030] in, For the first i The intermediate contribution of pressure or stress to an individual atom For the first i The volumetric stress contribution of each atom To simulate the total volume of the system, a , b These represent the x, y, and z directions, respectively.
[0031] Step 104: Reduce and sum the intermediate contributions of atomic pressure or stress belonging to the same grid to obtain the intermediate pressure or stress for each grid: For example, the intermediate pressure or stress of each grid can be calculated using the following formula:
[0032] in, This represents the intermediate pressure or stress value for the g-th grid. Let g be the set of atoms in the g-th grid.
[0033] Step 105: Perform time averaging on the intermediate pressure or stress values obtained in multiple time steps or multiple sampling windows to obtain the time-averaged intermediate pressure or stress values in the grid. Step 106: Based on the actual number of generated meshes or the actual volume of each mesh, perform a posteriori correction on the intermediate pressure or stress values of the time-averaged meshes to obtain the actual pressure or stress values for each mesh: Step 107: Based on the spatial location of each grid and the actual pressure or stress value of each grid, construct the global pressure or stress distribution results of the simulation system; Step 108: Cross-validate the local pressure statistics in the global pressure or stress distribution results using the direct pressure path and tensor component path.
[0034] In one example, cross-validation of local pressure statistics in global pressure or stress distribution results using direct pressure paths and tensor component paths can include: 1) In the direct pressure path, the intermediate contribution of structural pressure at the atomic scale:
[0035] in, As a contributor to the intermediate pressure, Let i be the volumetric stress contribution of the i-th atom in the xx component. Let be the stress volume contribution of the i-th atom in the yy component. Let i be the volumetric stress contribution of the i-th atom in the z-component. To simulate the total volume of the system; The first pressure result is obtained by reducing and summing the intermediate pressure contribution based on the grid, averaging over time, and making a posteriori correction. 2) In the tensor component path, pre-normalization, mesh reduction, time averaging, and posterior correction are performed on the six tensor components xx, yy, zz, xy, xz, and yz respectively to obtain the tensor components of each mesh. Then, the pressure is reconstructed based on the normal tensor components to obtain the second pressure result:
[0036] in, As a result of the second pressure, Let be the tensor component in the x-direction of the g-th grid. Let be the tensor component in the yy direction of the g-th grid. Let be the tensor component in the zz direction of the g-th grid; The difference between the first pressure result and the second pressure result is determined, and the reliability of the local pressure statistics result is determined based on the difference.
[0037] In one example, based on the actual number of generated grids or the actual volume of each grid, a post-hoc correction is performed on the intermediate pressure or stress values of the time-averaged grids to obtain the actual pressure or stress values for each grid. This can include: The actual pressure or stress value of each grid is calculated using the following formula: ; in, This represents the actual pressure or stress value of the g-th grid. This represents the intermediate pressure or stress value at the g-th grid after time averaging. Let g be the actual volume of the g-th grid. The actual number of grid cells generated. This is to simulate the total volume of the system.
[0038] In one example, obtaining the stress volume contribution of each atom of a target object in a molecular dynamics simulation system can include: S1: Output the stress tensor of atomic dimensionalities containing six components: xx, yy, zz, xy, xz, and yz, one atom at a time, using molecular dynamics simulation software; S2: Multiply the output stress tensor by the volume to obtain the stress volume contribution of each atom; S3: Save the coordinates of all atoms and the corresponding stress volume contribution step by step to construct a time-series atomic stress dataset.
[0039] Furthermore, dividing the molecular dynamics simulation system into a spatial grid according to a preset spatial orientation and grid size, and determining the grid to which each atom belongs and the spatial position of each grid, may include: S1: Preset the spatial orientation and mesh size for two-dimensional or three-dimensional division, read the box boundary of the molecular dynamics simulation system and calculate the actual side length of the molecular dynamics simulation system; S2: Perform natural meshing on the molecular dynamics simulation system according to the mesh size, and calculate the actual number of meshes generated in each direction and the total number of global meshes; S3: For each grid, mark its spatial boundary coordinates and center coordinates, and establish the correspondence between grid number and spatial location; S4: Using atomic spatial coordinates and grid interval indexing rules, determine the grid number to which each atom belongs, and combine periodic boundary conditions to perform coordinate mirroring correction on boundary atoms, thus completing the matching of all atoms with grids.
[0040] In other words, by combining global volume pre-normalization with mesh posterior volume correction, the calculation errors caused by non-divisible mesh partitioning and boundary mesh distortion are effectively eliminated. Furthermore, time averaging suppresses molecular thermal motion fluctuations, significantly improving the accuracy of local pressure and stress statistics. It is adaptable to two-dimensional / three-dimensional meshes and different simulation ensembles, and mesh size adjustment does not require manual parameter modification, making it widely applicable and highly compatible. The use of dual-path cross-validation can self-check calculation errors, thus ensuring reliable results. Only one global stress field needs to be constructed to quickly calculate the pressure and stress characteristics of any target region without repeated calculations, which can greatly improve post-processing efficiency. It can also realize the decomposition of multi-component stress contributions, and overall, it takes into account high accuracy, high reliability, and efficient and convenient post-processing capabilities.
[0041] The aforementioned statistical method for local pressure or stress distribution based on atomic stress volume contribution, spatial grid division, global volume pre-normalization, and posterior grid correction can be used for molecular dynamics simulations of multi-component fluids, interface systems, confined space systems, porous systems, and other systems that require spatially resolved pressure or stress distribution.
[0042] The above method will be described below with reference to a specific embodiment. However, it should be noted that this specific embodiment is only for better illustration of this application and does not constitute an improper limitation of this application.
[0043] Considering the need to analyze multiple arbitrary regions, redefining each region and separately calculating pressure each time would lead to repetitive operations and low processing efficiency. This is especially true when simultaneously analyzing global pressure distribution, local pressure, density distributions of different components, and pressure tensor components, where existing methods are inflexible. Therefore, this paper presents a molecular dynamics-based method for local pressure statistics. This method does not improve upon the fundamental calculation methods of atomic stress tensors, spatial binning methods, or time averaging methods themselves. Instead, it utilizes existing molecular dynamics simulation output data to propose a volume pre-normalization, posterior mesh correction, global pressure field construction, and arbitrary region statistical method for local pressure field construction. This avoids direct reliance on preset local mesh volumes, allows for correction based on the actual number or volume of generated meshes, and enables the one-time construction of global pressure or stress distributions, thus supporting rapid pressure or stress statistics for any specified region.
[0044] This example presents a local pressure statistics method for molecular dynamics simulations based on global volume pre-normalization and posterior mesh correction, which can be used as follows: Figure 2 As shown, it includes the following steps: S1, obtain the volumetric contribution of atomic stress: Obtain the stress volume contribution of each atom in the molecular dynamics simulation system. The stress volume contribution may include, but is not limited to, at least one stress or pressure tensor component, for example, it may include six components: xx, yy, zz, xy, xz, and yz.
[0045] S2, dividing the space grid: The molecular dynamics simulation system is divided into spatial grids according to a preset spatial orientation and grid size, and the grid to which each atom belongs and the spatial position of each grid are determined. The spatial grid can be a two-dimensional grid or a three-dimensional grid.
[0046] S3, perform global volume pre-normalization: Using the total volume of the simulated system The stress volume contribution of each atom is pre-normalized to obtain the atomic pressure or intermediate stress contribution. For the ab component of the i-th atom, it can be expressed as:
[0047] in, For the first i The volumetric stress contribution of each atom This refers to the intermediate contribution of atomic pressure or stress after pre-normalization of the total system volume. a , b These represent the x, y, and z directions, respectively.
[0048] It should be noted that the pre-normalization does not mean making physical quantities dimensionless, but rather converting the stress volume contribution into an intermediate pressure or stress quantity based on the total system volume.
[0049] S4, perform grid reduction summation: By reducing and summing the intermediate contributions of atomic pressure or stress belonging to the same grid, the intermediate pressure or stress values for each grid can be obtained:
[0050] in, Let g be the set of atoms in the g-th grid. This represents the intermediate pressure or stress value of the g-th grid.
[0051] S5, performing time averaging: Acquired within multiple time steps or multiple sampling windows Perform time averaging to obtain the time-averaged grid pressure or stress intermediate value. .
[0052] S6, perform posterior mesh correction: Based on the actual number of generated meshes or the actual volume of each mesh, a post-hoc correction is performed on the intermediate values of mesh pressure or stress after time averaging to obtain the actual pressure or stress values for each mesh:
[0053] in, For the actual pressure or stress tensor component of the g-th grid, Let g be the actual volume of the g-th grid.
[0054] When all grids have equal volume and completely cover the simulated system, we have: .
[0055] Therefore, the posterior correction can be simplified to:
[0056] in, This represents the actual number of grid cells generated.
[0057] S7, construct global pressure or stress distribution: Based on the spatial location of each grid and its corresponding pressure or stress tensor components, a global pressure or stress distribution of the simulated system is constructed. This global pressure or stress distribution may include at least one of the following: grid number, grid center coordinates, grid boundary coordinates, pressure value, stress tensor component values, and component density values.
[0058] S8, perform dual-path cross-validation: In practical implementation, direct pressure path and tensor component path can be used to cross-validate the local pressure statistics results.
[0059] In the direct pressure pathway, the intermediate pressure contribution is first constructed at the atomic scale: ; Then, reduction summation, time averaging, and posterior correction are performed according to the grid to obtain the direct stress results. .
[0060] In the tensor component path, the six tensor components xx, yy, zz, xy, xz, and yz are pre-normalized, meshed, time-averaged, and posteriorly corrected to obtain the tensor components of each mesh. The pressure is then reconstructed from the normal tensor components. .
[0061] Compare and The difference or relative error is used to determine the reliability of the local pressure statistics results.
[0062] The above example avoids directly relying on preset local mesh volumes. First, pre-normalization is performed using the total system volume, then a posteriori correction is made based on the actual number of generated meshes or the actual mesh volume. This reduces pressure conversion errors caused by the indivisibility between the simulation box size and the preset mesh size. When the mesh size is adjusted from 0.5×0.5 to 1×1 or other sizes, this example does not require re-hardcoding the local mesh volume in the input script; instead, the correction is completed by reading the actual number of meshes or the actual mesh volume during post-processing. In this example, pressure is not statistically analyzed only for a single preset region; instead, a global meshed pressure or stress distribution is constructed first, allowing for flexible extraction of pressure or stress from any region during post-processing. Local pressure is obtained through both direct pressure paths and tensor component paths, and the results of the two paths are compared to improve the reliability of local pressure statistical results. Furthermore, after obtaining the global pressure or stress distribution, users can filter the mesh set based on coordinate range, interface region, pore region, or component-rich region to quickly obtain the average pressure, maximum pressure, minimum pressure, or pressure distribution of a specified region.
[0063] The following example illustrates the simulation using the molecular dynamics simulation software LAMMPS to establish a fluid system containing water and n-octane. The simulation employs real units, full atom type, and three-dimensional periodic boundary conditions. Water molecules are modeled using the TIP4P / 2005 type water model with long-range coulombic interactions; n-octane molecules are simulated using Lennard-Jones nonbonded interactions and corresponding bond, angle, dihedral angle, and improper interaction parameters. The simulation system is imported from the data file "data".
[0064] Atoms of types 1, 2, and 3 were defined as the c8 group of n-octane, and atoms of types 4 and 5 were defined as the H2O group of water. The c8 and H2O groups were then combined into the fluid group for subsequent statistical analysis of local pressure and stress distribution. The OH and HOH bond angles in water molecules were constrained using the SHAKE method. The system temperature was set to 300 K, and isothermal control was applied to both the H2O and c8 groups.
[0065] Then, the simulation system is divided into a two-dimensional spatial grid in the xy plane. In this embodiment, the grid is divided at intervals of 0.5 along both the x and y directions, and each atom is assigned to a corresponding grid according to its spatial position. The actual number of grids generated is determined by the simulation output and is denoted as . It should be noted that the number of grid cells is not fixed in advance, but is determined based on the actual box size and the grid division results.
[0066] In the stress statistics process, this embodiment does not directly use the preset single grid volume for stress conversion, but first divides the stress volume contribution of each atom by the total volume of the simulated system. The intermediate contribution of pressure or stress based on the total system volume is obtained. Then, the intermediate contributions of atoms within the same grid are summed and averaged over a set time window to obtain the intermediate pressure or stress for each grid.
[0067] For the case of equal-volume meshes, this embodiment multiplies the intermediate values output by each mesh by the actual number of meshes generated during the post-processing stage. The actual pressure or stress components of each grid are obtained. If there are non-uniform volume grids or different volumes of boundary grids, corrections are made based on the ratio of the total volume of the simulation system to the actual volume of the corresponding grid.
[0068] This embodiment employs two paths to calculate local pressure. The first path is the direct pressure path, which first constructs the intermediate pressure contribution based on the volumetric normal stress contribution of the atoms, and then obtains the pressure value for each grid by summing, averaging over time, and performing posterior correction. The second path is the tensor component path, which statistically analyzes the six tensor components xx, yy, zz, xy, xz, and yz, obtains the pressure or stress tensor components for each grid after posterior correction, and then reconstructs the pressure value from the three normal components xx, yy, and zz. By comparing the pressure results obtained from the two paths, the pressure statistical and posterior correction processes are cross-validated.
[0069] Simultaneously, this embodiment statistically analyzes the mass density distribution of fluid, H2O, and C8 components in each grid to identify interface regions, component-rich regions, or other target analysis regions. By mapping the corrected grid pressure and stress tensor components to the grid coordinates, the global pressure or stress distribution in the xy plane can be obtained.
[0070] like Figure 3 The figure shown is a two-dimensional pressure distribution over time, in which... Figure 3 The 1 in the figure represents the pressure distribution along the x-direction in the specified area; Figure 3 The number 2 in the figure indicates that the statistical value of pressure can be output for any region in 1 (the figure shows the number of data points, mean and SD). Figure 3 The 3 in the figure represents the pressure distribution after the entire system is divided into grids; Figure 3 The number 4 in the figure indicates the pressure distribution along the y-direction in the specified area; Figure 3 The number 5 in the figure represents the statistical distribution of pressure within an area of arbitrary shape outside the droplet; Figure 3 The number 6 in the figure represents the statistical distribution of pressure within any shaped region inside the droplet.
[0071] After obtaining the global pressure or stress distribution, a corresponding mesh set is selected based on the coordinate range of the target region, and the pressure or stress values of the meshes within that set are statistically analyzed to obtain the average pressure, maximum pressure, minimum pressure, or pressure distribution of the specified region. This embodiment can be used for local pressure analysis in any region of a water-n-octane multi-component system, such as the interface region, component enrichment region, or fluid bulk region.
[0072] Through the above implementation, this embodiment can obtain the local pressure or stress distribution of the entire system based on a single global mesh statistical analysis, and can extract results for any region in post-processing. Compared with the method of directly dividing by a preset mesh volume at the input stage, this embodiment reduces the local pressure conversion error caused by the incomplete matching between the simulation box size and the mesh division by pre-normalizing the total system volume and a posteriori correction of the actual mesh quantity; at the same time, the reliability of the local pressure statistical results is improved by cross-validation of the direct pressure path and the tensor component path.
[0073] The methods and embodiments provided in the above-described embodiments of this application can be executed in a mobile terminal, computer terminal, or similar computing device. Taking its operation on an electronic device as an example... Figure 4 This is a hardware structure block diagram of an electronic device for a pressure data processing method provided in this application. (See diagram for example.) Figure 4 As shown, the electronic device 10 may include one or more (only one is shown in the figure) processors 02 (processors 02 may include, but are not limited to, processing devices such as microprocessors (MCUs) or programmable logic devices (FPGAs), a memory 04 for storing data, and a transmission module 06 for communication functions. Those skilled in the art will understand that... Figure 4 The structure shown is for illustrative purposes only and does not limit the structure of the electronic device described above. For example, electronic device 10 may also include... Figure 4 The more or fewer components shown, or having the same Figure 4 The different configurations shown.
[0074] The memory 04 can be used to store software programs and modules of application software, such as the program instructions / modules corresponding to the pressure data processing method in this embodiment. The processor 02 executes various functional applications and data processing by running the software programs and modules stored in the memory 04, thereby implementing the pressure data processing method of the aforementioned application. The memory 04 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 04 may further include memory remotely located relative to the processor 02, and these remote memories can be connected to the electronic device 10 via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0075] The transmission module 06 is used to receive or send data via a network. Specific examples of the network described above may include a wireless network provided by the communication provider of the electronic device 10. In one example, the transmission module 06 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission module 06 may be a Radio Frequency (RF) module, used for wireless communication with the Internet.
[0076] At the software level, the aforementioned pressure data processing device can, as follows: Figure 5 As shown, it includes: The acquisition module 501 is used to acquire the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; The determination module 502 is used to divide the molecular dynamics simulation system into spatial grids according to a preset spatial direction and grid size, and to determine the grid to which each atom belongs and the spatial position of each grid. Normalization module 503 is used to pre-normalize the stress volume contribution of each atom by simulating the total volume of the system, so as to obtain the intermediate pressure contribution or intermediate stress contribution of the atom. The reduction module 504 is used to reduce and sum the intermediate contributions of atomic pressure or stress belonging to the same grid, to obtain the intermediate pressure or stress values for each grid. The time averaging module 505 is used to perform time averaging on intermediate pressure or stress values obtained within multiple time steps or multiple sampling windows to obtain time-averaged intermediate pressure or stress values in the grid. Correction module 506 is used to perform a posteriori correction on the intermediate pressure or stress values of the time-averaged meshes based on the actual number of meshes generated or the actual volume of each mesh, to obtain the actual pressure or stress values of each mesh: Module 507 is used to construct the global pressure or stress distribution results of the simulation system based on the spatial location of each grid and the actual pressure or stress value of each grid. The verification module 508 is used to cross-verify the local pressure statistics in the global pressure or stress distribution results through the direct pressure path and the tensor component path.
[0077] In one implementation, the verification module 508 can specifically construct the intermediate pressure contribution at the atomic scale in the direct pressure path:
[0078] in, As a contributor to the intermediate pressure, Let i be the volumetric stress contribution of the i-th atom in the xx component. Let be the stress volume contribution of the i-th atom in the yy component. Let i be the volumetric stress contribution of the i-th atom in the z-component. To simulate the total volume of the system, the intermediate pressure contribution is reduced, summed, time-averaged, and corrected posteriorly according to the grid to obtain the first pressure result. In the tensor component path, the six tensor components xx, yy, zz, xy, xz, and yz are pre-normalized, meshed, time-averaged, and posteriorly corrected to obtain the tensor components of each mesh. Then, the pressure is reconstructed based on the normal tensor components to obtain the second pressure result.
[0079] in, As a result of the second pressure, Let be the tensor component in the x-direction of the g-th grid. Let be the tensor component in the yy direction of the g-th grid. Let be the tensor component in the zz direction of the g-th grid; determine the difference between the first pressure result and the second pressure result, and determine the reliability of the local pressure statistics result based on the difference.
[0080] In one implementation, the correction module 506 can specifically calculate the actual pressure or stress value of each grid according to the following formula: ; in, This represents the actual pressure or stress value of the g-th grid. This represents the intermediate pressure or stress value at the g-th grid after time averaging. Let g be the actual volume of the g-th grid. The actual number of grid cells generated. This is to simulate the total volume of the system.
[0081] In one implementation, the normalization module 503 can specifically obtain the intermediate pressure contribution or intermediate stress contribution of the atom according to the following formula:
[0082] in, For the first i The intermediate contribution of pressure or stress to an individual atom For the first i The volumetric stress contribution of each atom To simulate the total volume of the system, a , bThese represent the x, y, and z directions, respectively. Accordingly, the reduction module 504 can calculate the intermediate pressure or stress values for each grid according to the following formula:
[0083] in, This represents the intermediate pressure or stress value for the g-th grid. Let g be the set of atoms in the g-th grid.
[0084] In one implementation, the acquisition module 501 can specifically output the stress tensor of the atomic dimension containing six components (xx, yy, zz, xy, xz, yz) atom by atom using molecular dynamics simulation software; multiply the output stress tensor by the volume to obtain the stress volume contribution of each atom; and save the coordinates of all atoms and the corresponding stress volume contribution at each time step to construct a time-series atomic stress dataset.
[0085] In one implementation, the determining module 502 can specifically preset the two-dimensional or three-dimensional spatial division direction and grid size, read the box boundary of the molecular dynamics simulation system and calculate the actual side length of the molecular dynamics simulation system; perform natural grid partitioning of the molecular dynamics simulation system according to the grid size, calculate the actual number of grids generated in each direction and the total number of global grids; calibrate the spatial boundary coordinates and center coordinates of each grid, establish the correspondence between grid number and spatial position; use atomic spatial coordinates and grid interval indexing rules to determine the grid number to which each atom belongs, and perform coordinate mirror correction on the boundary atoms in combination with periodic boundary conditions to complete the matching of all atoms with grids.
[0086] This application also provides a specific implementation of an electronic device capable of implementing all steps of the pressure data processing method in the above embodiments. The electronic device specifically includes: a processor, a memory, a communication interface, and a bus; wherein the processor, memory, and communication interface communicate with each other via the bus; the processor is used to call a computer program in the memory, and when the processor executes the computer program, it implements all steps of the pressure data processing method in the above embodiments. For example, when the processor executes the computer program, it implements the following steps: Step 1: Obtain the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; Step 2: Divide the molecular dynamics simulation system into a spatial grid according to a preset spatial direction and grid size, and determine the grid to which each atom belongs and the spatial position of each grid; Step 3: Pre-normalize the stress volume contribution of each atom by simulating the total volume of the system to obtain the intermediate pressure contribution or intermediate stress contribution of the atom. Step 4: Reduce and sum the intermediate contributions of atomic pressure or stress belonging to the same grid to obtain the intermediate pressure or stress for each grid: Step 5: Perform time averaging on the intermediate pressure or stress values obtained within multiple time steps or multiple sampling windows to obtain the time-averaged intermediate pressure or stress values in the grid. Step 6: Based on the actual number of generated meshes or the actual volume of each mesh, perform a posteriori correction on the intermediate pressure or stress values of the time-averaged meshes to obtain the actual pressure or stress values for each mesh. Step 7: Based on the spatial location of each grid and the actual pressure or stress value of each grid, construct the global pressure or stress distribution results of the simulation system; Step 8: Cross-validate the local pressure statistics in the global pressure or stress distribution results using the direct pressure path and tensor component path.
[0087] Embodiments of this application also provide a computer-readable storage medium capable of implementing all steps of the pressure data processing method in the above embodiments. The computer-readable storage medium stores a computer program that, when executed by a processor, implements all steps of the pressure data processing method in the above embodiments. For example, when the processor executes the computer program, it implements the following steps: Step 1: Obtain the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; Step 2: Divide the molecular dynamics simulation system into a spatial grid according to a preset spatial direction and grid size, and determine the grid to which each atom belongs and the spatial position of each grid; Step 3: Pre-normalize the stress volume contribution of each atom by simulating the total volume of the system to obtain the intermediate pressure contribution or intermediate stress contribution of the atom. Step 4: Reduce and sum the intermediate contributions of atomic pressure or stress belonging to the same grid to obtain the intermediate pressure or stress for each grid: Step 5: Perform time averaging on the intermediate pressure or stress values obtained within multiple time steps or multiple sampling windows to obtain the time-averaged intermediate pressure or stress values in the grid. Step 6: Based on the actual number of generated meshes or the actual volume of each mesh, perform a posteriori correction on the intermediate pressure or stress values of the time-averaged meshes to obtain the actual pressure or stress values for each mesh. Step 7: Based on the spatial location of each grid and the actual pressure or stress value of each grid, construct the global pressure or stress distribution results of the simulation system; Step 8: Cross-validate the local pressure statistics in the global pressure or stress distribution results using the direct pressure path and tensor component path.
[0088] As can be seen from the above description, the embodiments of this application use the total volume of the simulated system to globally pre-normalize the contribution of atomic stress volume, and combine the actual number of grids or the real grid volume to carry out posterior volume correction. This effectively avoids the local pressure and stress conversion errors caused by the inability of the simulation box size and grid size to be divided evenly, boundary grid distortion, and fixed preset grid volume in existing methods. Furthermore, based on the multi-time step sampling time averaging to suppress the instantaneous fluctuations of molecular thermal motion, the numerical accuracy and stability of local pressure and stress tensor statistics in molecular dynamics simulation can be improved.
[0089] 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.
[0090] 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.
[0091] While this application provides the method operation steps as described 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 methods shown in the embodiments or drawings can be executed sequentially or in parallel (e.g., in a parallel processor or multi-threaded processing environment).
[0092] While this specification provides method operation steps as described in the embodiments or flowcharts, more or fewer operation steps may be included based on conventional or non-inventive means. 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 end product execution, the methods shown in the embodiments or drawings may be executed sequentially or in parallel (e.g., in a parallel processor or multi-threaded processing environment, or even a distributed data processing environment). The terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, product, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, product, or apparatus. Without further limitations, the presence of other identical or equivalent elements in the process, method, product, or apparatus that includes said elements is not excluded.
[0093] For ease of description, the above devices are described in terms of function, divided into various modules. Of course, in implementing the embodiments of this specification, the functions of each module can be implemented in one or more software and / or hardware components, or a module that performs the same function can be implemented by a combination of multiple sub-modules or sub-units. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division; in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, or indirect coupling or communication connection between devices or units, and may be electrical, mechanical, or other forms.
[0094] Those skilled in the art will also know that, besides implementing the controller using purely computer-readable program code, the same functions can be achieved by logically programming the method steps, making the controller function as logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers (PLCs), and embedded microcontrollers. Therefore, such a controller can be considered a hardware component, and the devices within it used to implement various functions can also be considered structures within that hardware component. Alternatively, the devices used to implement various functions can be considered as both software modules implementing the method and structures within a hardware component.
[0095] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart... Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0096] Those skilled in the art will understand that the embodiments of this specification can be provided as methods, systems, or computer program products. Therefore, the embodiments of this specification can take the form of entirely hardware embodiments, entirely software embodiments, or embodiments combining software and hardware aspects. Furthermore, the embodiments of this specification can take the form of computer program products implemented 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.
[0097] The embodiments described in this specification can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a specific task or implement a specific abstract data type. The embodiments of this specification can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.
[0098] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, system embodiments are basically similar to method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments. In the description of this specification, the terms "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of the embodiments in this specification. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described can be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification and the features of different embodiments or examples.
[0099] The above description is merely an embodiment of the present specification and is not intended to limit the embodiments of the present specification. For those skilled in the art, various modifications and variations can be made to the embodiments of the present specification. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principle of the embodiments of the present specification should be included within the scope of the claims of the embodiments of the present specification.
Claims
1. A pressure data processing method, characterized in that, include: Obtain the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; The molecular dynamics simulation system is divided into spatial grids according to a preset spatial orientation and grid size, and the grid to which each atom belongs and the spatial position of each grid are determined. By pre-normalizing the stress volume contribution of each atom to the total volume of the simulated system, the intermediate pressure contribution or intermediate stress contribution of the atom is obtained. By reducing and summing the intermediate contributions of atomic pressure or stress belonging to the same grid, the intermediate pressure or stress values for each grid can be obtained: Time averaging is performed on intermediate pressure or stress values obtained within multiple time steps or multiple sampling windows to obtain time-averaged intermediate pressure or stress values in the grid. Based on the actual number of generated grids or the actual volume of each grid, the intermediate pressure or stress values of the time-averaged grids are corrected a posteriori to obtain the actual pressure or stress values of each grid: Based on the spatial location of each grid and the actual pressure or stress value of each grid, the global pressure or stress distribution of the simulation system is constructed. Cross-validation of local pressure statistics in global pressure or stress distribution results is performed using direct pressure path and tensor component path.
2. The method according to claim 1, characterized in that, Cross-validation of local pressure statistics in global pressure or stress distribution results is performed using direct pressure paths and tensor component paths, including: In the direct pressure path, the intermediate contribution of pressure at the atomic scale is: in, As a contributor to the intermediate pressure, Let i be the volumetric stress contribution of the i-th atom in the xx component. Let be the stress volume contribution of the i-th atom in the yy component. Let i be the volumetric stress contribution of the i-th atom in the z-component. To simulate the total volume of the system; The first pressure result is obtained by reducing and summing the intermediate pressure contribution based on the grid, averaging over time, and making a posteriori correction. In the tensor component path, the six tensor components xx, yy, zz, xy, xz, and yz are pre-normalized, meshed, time-averaged, and posteriorly corrected to obtain the tensor components of each mesh. Then, the pressure is reconstructed based on the normal tensor components to obtain the second pressure result. in, As a result of the second pressure, Let be the tensor component in the x-direction of the g-th grid. Let be the tensor component in the yy direction of the g-th grid. Let be the tensor component in the zz direction of the g-th grid; The difference between the first pressure result and the second pressure result is determined, and the reliability of the local pressure statistics result is determined based on the difference.
3. The method according to claim 1, characterized in that, Based on the actual number of generated grids or the actual volume of each grid, the intermediate pressure or stress values of the time-averaged grids are a posteriori corrected to obtain the actual pressure or stress values of each grid, including: The actual pressure or stress value of each grid is calculated using the following formula: ; in, This represents the actual pressure or stress value of the g-th grid. This represents the intermediate pressure or stress value at the g-th grid after time averaging. Let g be the actual volume of the g-th grid. The actual number of grid cells generated. This is to simulate the total volume of the system.
4. The method according to claim 1, characterized in that, By pre-normalizing the stress volume contribution of each atom to the total simulated system volume, the intermediate pressure contribution or stress contribution of the atom is obtained, including: The intermediate contribution of atomic pressure or stress can be obtained using the following formula: in, For the first i The intermediate contribution of pressure or stress to an individual atom For the first i The volumetric stress contribution of each atom To simulate the total volume of the system, a , b These represent the x, y, and z directions, respectively. Correspondingly, the intermediate contributions of atomic pressure or stress belonging to the same grid are reduced and summed to obtain the intermediate pressure or stress quantities for each grid, including: Calculate the intermediate pressure or stress for each grid using the following formula: in, This represents the intermediate pressure or stress value for the g-th grid. Let g be the set of atoms in the g-th grid.
5. The method according to claim 1, characterized in that, Obtain the stress volume contribution of each atom of the target object in the molecular dynamics simulation system, including: The stress tensor in atomic dimensions, comprising six components (xx, yy, zz, xy, xz, yz), is output atom-by-atom using molecular dynamics simulation software. The stress tensor output is multiplied by the volume to obtain the stress volume contribution of each atom. Save the coordinates of all atoms and the corresponding stress volume contribution at each time step to construct a time-series atomic stress dataset.
6. The method according to claim 1, characterized in that, The molecular dynamics simulation system is divided into spatial grids according to a preset spatial orientation and grid size, and the grid to which each atom belongs and the spatial position of each grid are determined, including: Preset the spatial orientation and mesh size for two-dimensional or three-dimensional division, read the box boundary of the molecular dynamics simulation system, and calculate the actual side length of the molecular dynamics simulation system; The molecular dynamics simulation system is naturally meshed according to the mesh size, and the actual number of meshes generated in each direction and the total number of global meshes are calculated. For each grid, its spatial boundary coordinates and center coordinates are labeled, and the correspondence between grid number and spatial location is established; By using atomic spatial coordinates and grid interval indexing rules, the grid number to which each atom belongs is determined, and the coordinate mirroring correction of boundary atoms is performed in combination with periodic boundary conditions to complete the matching of all atoms and grids.
7. A pressure data processing device, characterized in that, include: The acquisition module is used to acquire the stress volume contribution of each atom of the target object in the molecular dynamics simulation system; The determination module is used to divide the molecular dynamics simulation system into spatial grids according to a preset spatial direction and grid size, and to determine the grid to which each atom belongs and the spatial position of each grid. The normalization module is used to pre-normalize the stress volume contribution of each atom by simulating the total volume of the system, so as to obtain the intermediate pressure contribution or stress contribution of the atom. The reduction module is used to reduce and sum the intermediate contributions of atomic pressure or stress belonging to the same grid, to obtain the intermediate pressure or stress values for each grid. The time averaging module is used to perform time averaging on intermediate pressure or stress values obtained within multiple time steps or multiple sampling windows to obtain time-averaged intermediate pressure or stress values in the grid. The correction module is used to perform a posteriori correction on the intermediate pressure or stress values of the time-averaged meshes based on the actual number of meshes generated or the actual volume of each mesh, to obtain the actual pressure or stress values of each mesh. The building module is used to construct the global pressure or stress distribution results of the simulation system based on the spatial location of each grid and the actual pressure or stress value of each grid. The verification module is used to cross-validate the local pressure statistics in the global pressure or stress distribution results through the direct pressure path and the tensor component path.
8. A terminal device, comprising a processor and a memory for storing processor-executable instructions, characterized in that, When the processor executes the instructions, it implements the steps of the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having a computer program / instructions stored thereon, characterized in that, When the computer program / instructions are executed by the processor, they implement the steps of the method described in any one of claims 1 to 6.
10. A computer program product comprising a computer program / instructions, characterized in that, When the computer program / instructions are executed by the processor, they implement the steps of the method described in any one of claims 1 to 6.