Dislocation configuration identification and statistical methods and systems for molecular dynamics simulations
Through molecular dynamics simulation and dislocation structure analysis and identification modules, complex dislocation structures in metal materials are identified and counted, which solves the problem that the existing technology is difficult to identify complex dislocations, and achieves rapid and accurate identification and statistics of dislocation structures.
Patent Information
- Application Number
- CN202510295827.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-13
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2045-03-13
AI Technical Summary
The prior art is difficult to identify and analyze complex dislocation structures in metal materials, such as dislocation rings, stacking fault tetrahedrons, etc., which limits the understanding of the role of dislocations in the deformation behavior of metal materials.
Dislocation structure information is obtained through molecular dynamics simulation, and the dislocation structure analysis and identification module is used to extract the structural nodes of the dislocation segment, deduplicate based on the node coordinates, and establish a matrix file to record the Burger vector, length and connection relationship between the dislocation segments between nodes, thereby identifying and counting complex dislocation structures.
It realizes rapid identification and statistics of complex dislocation structures in metal materials, and can accurately identify full dislocations, stacking fault tetrahedrons, dislocation rings and dominant dislocations, helping to understand the role of dislocations in material performance.
Smart Images

Figure CN119811514B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of micro-nano mechanics, and in particular relates to a dislocation configuration identification and statistical method and system for molecular dynamics simulation. Background Art
[0002] Dislocations are the main carriers of plastic deformation in metals, and dislocation motion has an important influence on mechanical properties such as strength, fatigue behavior, and fracture toughness of materials. Dislocations have a variety of complex structures, including single dislocation lines, dislocation loops, entangled dislocations, and stacking fault tetrahedrons. On the one hand, the dislocation structure gradually changes with the progress of loading; on the other hand, the dislocation's own structure has an important influence on its motion behavior and the macroscopic mechanical properties of the material. Revealing the evolutionary behavior of dislocations under external loads at the atomic scale through computer simulation technology (such as molecular dynamics simulation) is of great significance for understanding the relationship between dislocation motion and material properties. Existing software can identify dislocations, but can only identify individual dislocation segments and cannot analyze the complex topological relationship of dislocations in the model, so it is impossible to identify complex dislocation structures such as statistical full dislocations, dislocation loops, and stacking fault tetrahedrons, which limits the understanding of the role of complex dislocation structures in the deformation behavior of metal materials. Summary of the invention
[0003] The purpose of the present invention is to solve the technical problems existing in the prior art and to provide a dislocation configuration identification and statistical method and system for molecular dynamics simulation, which can quickly and conveniently count the number of various typical dislocation configurations in the model and perform post-processing on specific dislocation configurations.
[0004] The specific technical solutions adopted by the present invention are as follows:
[0005] In a first aspect, the present invention provides a dislocation configuration identification and statistical method for molecular dynamics simulation, which comprises:
[0006] S1. Based on the molecular dynamics model of the target metal material, a first result file containing dislocation structure information is obtained through molecular dynamics simulation;
[0007] S2, analyzing and identifying the dislocation structure of the first result file to obtain a second result file containing relevant information of all dislocation segments, wherein the relevant information of each dislocation segment includes node numbers and coordinates of all dislocation nodes contained in the dislocation segment;
[0008] S3, taking the dislocation nodes at both ends of the dislocation segment as structural nodes and the remaining nodes as internal nodes, extracting the structural nodes of all dislocation segments from the second result file and removing duplicates based on the node coordinates, retaining all independent structural nodes, assigning a unique identifier to each independent structural node, and recording the coordinates of the independent structural node and its corresponding original node sequence number set on all dislocation segments; at the same time, for all independent structural nodes, re-establishing a first matrix file for recording the Burger vectors of the dislocation segments between nodes, a second matrix file for recording the lengths of the dislocation segments between nodes, and a third matrix file for recording the direct connection relationship between nodes;
[0009] S4. Based on the third matrix file, further analyzing whether any two independent structural nodes satisfy any one of direct connection or indirect connection. If so, it is considered that there is a connectivity relationship between the two independent structural nodes, and the relationship is recorded in the fourth matrix file.
[0010] S5. Based on the information recorded in the first matrix file, the second matrix file, the third matrix file and the fourth matrix file, the positions of one or more of full dislocations, stacking fault tetrahedrons, dislocation loops and dominant dislocations in the molecular dynamics model are identified and the number is counted.
[0011] As a preferred embodiment of the first aspect, the molecular dynamics simulation is implemented by a large-scale atomic and molecular parallel simulator LAMMPS, and the analysis and identification of the dislocation structure is implemented by a dislocation analysis module in OVITO.
[0012] As a preferred embodiment of the first aspect, the first matrix file, the second matrix file and the third matrix file are established as follows:
[0013] According to the total number of nodes N of all independent structural nodes, a first matrix file of N×N×3 size, a second matrix file of N×N size, and a third matrix file of N×N size are established, and the row and column numbers of the matrix elements in the three matrix files correspond to the unique identifiers of the N independent structural nodes respectively; then, each dislocation segment in the second result file is traversed in turn, the original node serial numbers of the structural nodes at both ends of the current dislocation segment are read and mapped to their respective unique identifiers respectively, and the two unique identifiers obtained by the mapping are used as row and column numbers in different orders to locate two target matrix elements in the three matrix files respectively, and a mark symbol representing that the nodes are directly connected through the dislocation segment is written into the target matrix element of the third matrix file, and at the same time, a three-dimensional Burger vector is read from the relevant information of the current dislocation segment and written into the three channels of the target matrix element in the first matrix file, and all the dislocation node coordinates contained in the relevant information of the current dislocation segment are read, and the Euclidean distances between adjacent dislocation nodes are calculated and summed to obtain the length of the current dislocation segment, which is written into the target matrix element of the second matrix file.
[0014] As a preferred embodiment of the first aspect, the method for identifying the full dislocation is:
[0015] A first undirected graph is established with all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix, wherein each edge in the first undirected graph corresponds to a direct dislocation segment, and each pair of direct dislocation segments in the undirected graph is traversed in turn, and combined with the burgers vectors of the pair of direct dislocation segments read from the first matrix file, it is determined whether the criterion condition for constituting a full dislocation is met. If so, the pair of direct dislocation segments is identified as a full dislocation, and the two structural node coordinates of the full dislocation are calculated based on the endpoint coordinates of the pair of direct dislocation segments, and the sum of the burgers vectors of the pair of direct dislocation segments is used as the burgers vector of the full dislocation.
[0016] As a preferred embodiment of the first aspect, there are three criteria for the full dislocation; the first criterion is that the vertical distance between the two direct dislocation segments is less than the distance threshold; the second criterion is that the angle between the two direct dislocation segments is less than the angle threshold; the third criterion is that the burgers vectors of the two direct dislocation segments belong to The burgers vector corresponding to the type partial dislocation, and the sum of the burgers vectors of the two direct dislocation segments belongs to The burgers vector corresponding to the type full dislocation.
[0017] As a preferred embodiment of the first aspect, for each pair of direct dislocation segments, when calculating the two structural node coordinates of the full dislocation, if the direction vectors of the two direct dislocation segments are in the same direction, then the head structural node coordinates of the full dislocation are the coordinates of the midpoint between the head structural node of one direct dislocation segment and the head structural node of the other direct dislocation segment, and the tail structural node coordinates of the full dislocation are the coordinates of the midpoint between the tail structural node of one direct dislocation segment and the tail structural node of the other direct dislocation segment; if the direction vectors of the two direct dislocation segments are in different directions, then the head structural node coordinates of the full dislocation are the coordinates of the midpoint between the head structural node of one direct dislocation segment and the tail structural node of the other direct dislocation segment, and the tail structural node coordinates of the full dislocation are the coordinates of the midpoint between the tail structural node of one direct dislocation segment and the head structural node of the other direct dislocation segment.
[0018] As a preferred embodiment of the first aspect, the stacking fault tetrahedron identification method is as follows: using all independent structure nodes as graph nodes and the fourth matrix file as an adjacency matrix to establish a second undirected graph; searching in the second undirected graph whether there are four independent structure nodes constituting a K4 complete subgraph, and if so, identifying a stacking fault tetrahedron by the topological structure corresponding to each K4 complete subgraph;
[0019] The method for identifying the dislocation ring is as follows: using all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix to establish a first undirected graph; searching in the first undirected graph whether there is a circular subgraph connected end to end, and if so, identifying the topological structure corresponding to each circular subgraph as a dislocation ring.
[0020] As a preferred embodiment of the first aspect, the method for identifying the dominant dislocation is:
[0021] A first undirected graph is established with all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix; combining the node connectivity relationship recorded in the fourth matrix file and the dislocation segment length recorded in the second matrix file, two independent structural nodes with a connectivity relationship and a sum of all dislocation segment lengths on the shortest connectivity path exceeding the critical length of the dislocation are searched in the first undirected graph, and the topological structure corresponding to the shortest connectivity path of the two independent structural nodes constitutes a long dislocation; and all dislocation segments directly or indirectly connected to each long dislocation in the first undirected graph and the long dislocation itself are identified as a dominant dislocation.
[0022] In a second aspect, the present invention provides a dislocation configuration identification and statistical system for molecular dynamics simulation, which comprises:
[0023] A molecular dynamics simulation module, used for obtaining a first result file containing dislocation structure information through molecular dynamics simulation based on a molecular dynamics model of a target metal material;
[0024] A dislocation structure analysis and identification module, used to analyze and identify the dislocation structure of the first result file to obtain a second result file containing relevant information of all dislocation segments, wherein the relevant information of each dislocation segment includes node numbers and coordinates of all dislocation nodes contained in the dislocation segment;
[0025] A structural node reconstruction module is used to use the dislocation nodes at both ends of the dislocation segment as structural nodes and the remaining nodes as internal nodes, extract the structural nodes of all dislocation segments from the second result file and remove duplicates based on the node coordinates, retain all independent structural nodes, assign a unique identifier to each independent structural node, and record the coordinates of the independent structural node and its corresponding original node sequence number set on all dislocation segments; at the same time, for all independent structural nodes, re-establish a first matrix file for recording the Burger vectors of the dislocation segments between nodes, a second matrix file for recording the lengths of the dislocation segments between nodes, and a third matrix file for recording the direct connection relationship between nodes;
[0026] A connectivity relationship analysis module, used for further analyzing whether any two independent structural nodes satisfy any direct connection or indirect connection based on the third matrix file, and if so, it is considered that there is a connectivity relationship between the two independent structural nodes, and recorded in the fourth matrix file;
[0027] The dislocation identification and statistics module is used to identify and count the positions of one or more of full dislocations, stacking fault tetrahedrons, dislocation rings and dominant dislocations in the molecular dynamics model based on the information recorded in the first matrix file, the second matrix file, the third matrix file and the fourth matrix file.
[0028] In a third aspect, the present invention provides a computer electronic device comprising a memory and a processor;
[0029] The memory is used to store computer programs;
[0030] The processor is used to implement the dislocation configuration identification and statistical method for molecular dynamics simulation as described in any one of the first aspects above when executing the computer program.
[0031] Compared with the prior art, the present invention has the following beneficial effects:
[0032] Traditional dislocation analysis methods can only identify individual dislocation segments but cannot analyze the complex topological relationship of dislocations in the model. The present invention further analyzes and reconstructs dislocation node information and dislocation segment information, obtains all independent structure nodes after deduplication, and re-establishes a matrix file to record the dislocation segment Burger vector between nodes, the dislocation segment length between nodes, the direct connection relationship between nodes, and the connectivity relationship between nodes, and then based on the topological connection relationship between independent structure nodes and the Burgers vector information, identifies the positions of various types of dislocations such as full dislocations, stacking fault tetrahedrons, dislocation rings, and dominant dislocations in the model and counts the number. The present invention can analyze the complex dislocation structure between dislocation segments, thereby accurately identifying various types of dislocations, which is helpful for the analysis of complex dislocation structures and the identification of complex dislocation reactions. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] Figure 1 Schematic diagram of the steps of dislocation configuration identification and statistical methods for molecular dynamics simulation;
[0034] Figure 2 is an exemplary dislocation structure and the discretized dislocation nodes;
[0035] Figure 3 Schematic diagram of the module composition of the dislocation configuration identification and statistical system for molecular dynamics simulation.
[0036] Figure 4A schematic diagram of the components of computer electronic equipment;
[0037] Figure 5 is a schematic diagram of an exemplary full dislocation identification process and results;
[0038] Figure 6 An exemplary stacking fault tetrahedron (SFT) and dislocation loop (LOOP) identification result;
[0039] Figure 7 An exemplary dominant dislocation identification result. DETAILED DESCRIPTION
[0040] In order to make the above-mentioned purpose, features and advantages of the present invention more obvious and easy to understand, the specific implementation mode of the present invention is described in detail below in conjunction with the accompanying drawings. In the following description, many specific details are set forth to facilitate a full understanding of the present invention. However, the present invention can be implemented in many other ways different from those described herein, and those skilled in the art can make similar improvements without violating the connotation of the present invention. Therefore, the present invention is not limited to the specific embodiments disclosed below. The technical features in each embodiment of the present invention can be combined accordingly without conflicting with each other.
[0041] In the description of the present invention, it is to be understood that when an element is considered to be "connected" to another element, it may be directly connected to the other element or indirectly connected, that is, there are intermediate elements. On the contrary, when an element is said to be "directly" connected to another element, there are no intermediate elements.
[0042] In the description of the present invention, it should be understood that the terms "first" and "second" are only used for the purpose of distinguishing descriptions, and should not be understood as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features.
[0043] Existing software can identify dislocations, but can only identify individual dislocation segments and cannot analyze the complex topological relationship of dislocations in the model, and therefore cannot identify complex dislocation structures such as statistical dislocation loops, stacking fault tetrahedrons, and entangled dislocations. The dislocation configuration identification and statistical method for molecular dynamics simulation proposed in the present invention can automatically identify and statistically analyze dislocation structures such as full dislocations, dislocation loops, stacking fault tetrahedrons, and entangled dislocations in the system, which helps to accurately and quickly identify dislocation structures in complex systems. The specific implementation method of the dislocation configuration identification and statistical method for molecular dynamics simulation will be described in detail below.
[0044] like Figure 1 As shown, in a preferred embodiment of the present invention, a dislocation configuration identification and statistical method for molecular dynamics simulation is provided, which includes:
[0045] S1. Based on the molecular dynamics model of the target metal material, a first result file containing dislocation structure information is obtained through molecular dynamics simulation.
[0046] It should be noted that the molecular dynamics model in the present invention is a molecular dynamics model constructed for the target metal material to be studied, and the specific molecular dynamics model construction method belongs to the prior art, and the method of performing molecular dynamics simulation on it also belongs to the prior art. In an embodiment of the present invention, the molecular dynamics simulation is implemented by a large-scale atomic / molecular massively parallel simulator (LAMMPS).
[0047] S2. Analyze and identify the dislocation structure of the first result file to obtain a second result file containing relevant information of all dislocation segments, wherein the relevant information of each dislocation segment includes the node serial numbers and coordinates of all dislocation nodes contained in the dislocation segment.
[0048] In an embodiment of the present invention, the analysis and identification of dislocation structure can be realized by the dislocation analysis (DXA) module in OVITO (Open Visualization Tool). Of course, in addition to using the DXA module of OVITO software, other dislocation analysis software or modules can also be used to replace the analysis and identification of dislocation structure.
[0049] It should be noted that the dislocation segment related information in the second result file records the node serial numbers and three-dimensional coordinates of all dislocation nodes contained in each dislocation segment. Each dislocation segment contains at least two dislocation nodes, that is, at least two endpoints at both ends of the dislocation line segment, but there may be other internal nodes between the two endpoints.
[0050] exist Figure 2 In the example, a dislocation structure and the different dislocation nodes contained therein are shown, where (a) shows the dislocation structure, which includes three dislocation line segment features (represented by black segments) and the corresponding three burgers vector features b1, b2, and b3 (represented by black arrows), and (b) shows the discretized dislocation nodes obtained through dislocation analysis in the dislocation structure. Figure 2The solid red nodes K1~K5 in the figure represent structural nodes, and the hollow nodes P1~P5 represent internal nodes. In crystalline materials, a dislocation line can only end at the crystal surface or internal interface (such as grain boundary or phase boundary, these nodes are called "termination nodes") unless it is connected to other dislocation line segments (the connected nodes are called "junction points") . The structural nodes in the second result file correspond to the "junction points", "termination nodes" of the dislocation, or a node in a long dislocation (that is, they do not necessarily exist as "junction points" or "termination nodes"). In contrast, internal nodes must be nodes between two structural nodes, and they will never be used as "junction points" or "termination nodes". Since different dislocation line segments can only be connected through structural nodes, when analyzing the topological connection relationship between dislocation nodes in the subsequent analysis, it is only necessary to analyze the topological connection relationship between the structural nodes at both ends of the dislocation segment. In addition, due to the complexity of the dislocation structure, the same dislocation node may be stored repeatedly in different dislocation segments and marked with different node numbers, so the dislocation structural nodes also need to be reconstructed in the subsequent analysis.
[0051] S3, taking the dislocation nodes at both ends of the dislocation segment as structural nodes and the remaining nodes as internal nodes, extracting the structural nodes of all dislocation segments from the second result file and deduplicating them based on the node coordinates, retaining all independent structural nodes, assigning a unique identifier to each independent structural node, and recording the coordinates of the independent structural node and its corresponding original node sequence number set on all dislocation segments; at the same time, for all independent structural nodes, re-establishing a first matrix file for recording the Burger vectors of the dislocation segments between nodes, a second matrix file for recording the lengths of the dislocation segments between nodes, and a third matrix file for recording the direct connection relationship between nodes.
[0052] It should be noted that when extracting the structural nodes of the dislocation segment, the extraction algorithm can be designed accordingly according to the data recording rules in the actually generated second result file. Generally speaking, taking the second result file in caf format generated by the DXA module as an example, the relevant information of the dislocation segment for each dislocation segment record is stored line by line in the following order: the first line stores the dislocation segment serial number; the second line stores the dislocation segment burgers vector; the third line stores the serial number of the crystal cluster where the dislocation is located, which is regarded as a blank information line; the fourth line stores the total number of structural nodes and internal nodes contained in the dislocation segment (recorded as nPoints); the fifth line to the (4+nPoints)th line: store the coordinates of the head structural node, the internal node (if any), and the tail structural node in turn. Among them, the three-dimensional node coordinates of the head structural node and the tail structural node must exist, but the internal nodes may not exist. Therefore, the node coordinate information of the head structure node in the 5th row and the node coordinate information of the tail structure node in the (4+nPoints)th row can be extracted as the node coordinate information of the two structure nodes of the dislocation segment, and all the node coordinate information of the remaining rows are regarded as internal nodes and do not need to be extracted.
[0053] In addition, after extracting the structural nodes of all dislocation segments, since the same dislocation node may be stored repeatedly in different dislocation segments and marked with different node numbers, it is necessary to perform deduplication based on the uniqueness of the node coordinates. Due to calculation accuracy or errors, the actual node coordinates may have certain deviations, so a smaller error threshold can be set when deduplication is performed. , traverse all two pairable structure nodes, calculate the Euclidean distance based on their respective node coordinates, and if the Euclidean distance is less than the error threshold The two are considered to be the same structural node, otherwise they are considered to belong to different structural nodes. After the deduplication of structural nodes is completed, the remaining retained structural nodes are named independent structural nodes. In order to facilitate subsequent analysis, it is necessary to assign a unique identifier (i.e., a unique ID) to each independent structural node, and record the coordinates of the independent structural node and the corresponding original node serial number set on all dislocation segments. The coordinates of the independent structural node can be replaced by the original node coordinates of any structural node belonging to this independent structural node, or the original node coordinates of all structural nodes belonging to this independent structural node can be averaged. In addition, the original node serial number set corresponding to each independent structural node on all dislocation segments refers to the original node serial numbers of all structural nodes belonging to this independent structural node in the second result file. For example, suppose that in all the dislocation segment related information in the second result file, there are three structural nodes with original node serial numbers id1, id2 and id3 respectively. After the deduplication operation, it is determined that these three structural nodes actually belong to the same structural node, so a unique identifier is recorded as UniqueIDi Independent structure node, and the unique identifier for this is UniqueID i For an independent structure node, it is necessary to further construct a field for the original node serial number set to record the three original node serial numbers id1, id2, and id3. The purpose of recording the original node serial number set is to establish the UniqueID of the independent structure node. i The association relationship between id1, id2 and id3 enables each original node serial number to be mapped to a unique identifier, and each unique identifier can also find the corresponding original node serial number. When constructing the first matrix file, the second matrix file and the third matrix file later, each independent structural node needs to rely on its original node serial number to find the corresponding information from the second result file. Therefore, according to the aforementioned association relationship, the dislocation segment Burger vector, the dislocation segment length between nodes and the direct connection relationship between nodes can be found or calculated from the second result file.
[0054] In an embodiment of the present invention, the first matrix file, the second matrix file and the third matrix file are established as follows:
[0055] First, according to the total number of nodes N of all independent structural nodes, a first matrix file of N×N×3 size, a second matrix file of N×N size, and a third matrix file of N×N size are established. The row and column numbers of the matrix elements in the three matrix files correspond to the unique identifiers of the N independent structural nodes, respectively. The matrix elements in the i-th row and j-th column are used to record the relevant information between the two independent structural nodes corresponding to the i-th unique identifier and the j-th unique identifier.
[0056] Then, traverse each dislocation segment in the second result file in turn (for the convenience of description, the present invention records the dislocation segment currently traversed during the traversal process as the current dislocation segment), read the original node serial numbers of the structural nodes at both ends of the current dislocation segment and map them to their respective unique identifiers, and locate the two target matrix elements in the three matrix files respectively by using the two unique identifiers obtained by mapping as row and column numbers in different orders. It should be noted that the two unique identifiers obtained by mapping can constitute the row and column numbers in two different orders. Assuming that the independent structural node unique identifier corresponding to the original node serial number of the structural node at the head of the current dislocation segment is iStart, and the independent structural node unique identifier corresponding to the original node serial number of the structural node at the end of the current dislocation segment is iEnd, the matrix coordinates of the two target matrix elements located are (iStart, iEnd) and (iEnd, iStart) respectively. The reason why two matrix elements need to be taken at the same time is that the graph composed of all independent structural nodes is an undirected graph, so the two matrix element information at the positions (iStart, iEnd) and (iEnd, iStart) are equivalent.
[0057] Finally, for each current dislocation segment in the traversal process, after locating the two target matrix elements corresponding to the current dislocation segment, it is necessary to assign values to the corresponding matrix elements in the three matrix files. The specific method is as follows: write a marker symbol representing that the nodes are directly connected through the dislocation segment in the target matrix element of the third matrix file, and at the same time read the three-dimensional Burger vector from the relevant information of the current dislocation segment and write it into the three channels of the target matrix element in the first matrix file. In addition, read the coordinates of all dislocation nodes contained in the relevant information of the current dislocation segment, calculate the Euclidean distances between adjacent dislocation nodes pairwise and sum them up to obtain the length of the current dislocation segment, and write it into the target matrix element of the second matrix file.
[0058] It should be noted that each matrix element in the first matrix file has three channels, because the Burger vector is three-dimensional, and each channel is used to record a dimension of the Burger vector. In addition, in the second matrix file, because there is no direct connection between some independent structure nodes, the corresponding target matrix elements do not have the length of the dislocation segment to be recorded, so these target matrix elements can be directly copied as "-1" to represent that there is no corresponding dislocation segment. Furthermore, in the third matrix file, the marking symbol representing the nodes directly connected through the dislocation segment can generally be marked with the number "1", and the marking symbol representing the nodes not directly connected through the dislocation segment can generally be marked with the number "0", so that the third matrix file can be used as an adjacency matrix. Of course, in theory, it is also possible to use other marking symbols.
[0059] It should also be noted that the above assignment operation for the two target matrix elements can be performed together after being located at the same time, or one of the target matrix elements can be assigned first, and after all the current dislocation segments are traversed, the entire matrix file is symmetric along the matrix diagonal. The essence of the two is the same. In addition, the assignment operation for the three matrix files can be performed synchronously. In this case, it is only necessary to traverse each dislocation segment in the second result file once, but it is also possible to complete the assignment operation of all matrix elements in one matrix file first and then perform the assignment operation of all matrix elements in another matrix file. In this case, each matrix file needs to traverse each dislocation segment in the second result file once.
[0060] It should also be noted that the unique identifier of each independent structural node, the coordinates of the independent structural node, and the corresponding original node serial number set on all dislocation segments can be stored by designing a corresponding data table or structure array, and the specific form is not limited. Considering the convenience of subsequent calls, in an embodiment of the present invention, a structure can be designed to record the unique identifier of each independent structural node, the coordinates of the independent structural node, and the corresponding original node serial number set on all dislocation segments, and then the structures of all independent structural nodes form a structure array for storage.
[0061] S4. Based on the third matrix file, further analyze whether any two independent structural nodes satisfy any one of direct connection or indirect connection. If so, it is considered that there is a connectivity relationship between the two independent structural nodes, and the relationship is recorded in the fourth matrix file.
[0062] It should be noted that there is a connectivity relationship between two independent structure nodes, which can be that the two are directly connected through a dislocation segment, or that the two are indirectly connected through multiple dislocation segments. Any connection form can be considered as a connectivity relationship between the two independent structure nodes. Whether there is a direct connection or an indirect connection between the two independent structure nodes can actually be judged by the direct connection relationship between the nodes recorded in the third matrix file. In an embodiment of the present invention, the connectivity between the independent structure nodes can be analyzed based on the third matrix file through a breadth first search (Breadth First Search, BFS), and the shortest path length between any two independent structure nodes is calculated. If the shortest path length is not less than 1, it is considered that there is a connectivity relationship between the two independent structure nodes, otherwise it is considered that there is no connectivity relationship between the two independent structure nodes.
[0063] S5. Based on the information recorded in the first matrix file, the second matrix file, the third matrix file and the fourth matrix file, the positions of one or more of full dislocations, stacking fault tetrahedrons (SFTs), dislocation loops and dominant dislocations in the molecular dynamics model are identified and the number is counted.
[0064] It should be noted that the first matrix file, the second matrix file, the third matrix file and the fourth matrix file respectively record the related information between nodes of different dimensions, and the identification of different dislocation types needs to rely on different information, so the matrix files to be read may also be different. The identification methods of the four dislocation types are specifically introduced below.
[0065] In the embodiment of the present invention, the identification of the full dislocation depends on the first matrix file and the third matrix file. The method for identifying the full dislocation that can be used is:
[0066] A first undirected graph is established with all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix, wherein each edge in the first undirected graph corresponds to a direct dislocation segment, and each pair of direct dislocation segments in the undirected graph is traversed in turn, and combined with the burgers vectors of the pair of direct dislocation segments read from the first matrix file, it is determined whether the criterion condition for constituting a full dislocation is met. If so, the pair of direct dislocation segments is identified as a full dislocation, and the two structural node coordinates of the full dislocation are calculated based on the endpoint coordinates of the pair of direct dislocation segments, and the sum of the burgers vectors of the pair of direct dislocation segments is used as the burgers vector of the full dislocation.
[0067] It should be noted that, since there are directly connected independent structure nodes and indirectly connected independent structure nodes in the present invention, in order to avoid confusion, the dislocation segment connecting two adjacent independent structure nodes is called a direct dislocation segment. When the third matrix file is used as the adjacency matrix to establish an undirected graph, each edge is a direct dislocation segment. Assume that the two direct dislocation segments that need to be judged are and , and Dislocation Segments The head structure node and the tail structure node of and Dislocation Segments The head structure node and the tail structure node of the whole dislocation have three existence criteria:
[0068] The first criterion condition is that the vertical distance between two direct dislocation segments is less than the distance threshold;
[0069] The second criterion condition is that the angle between the two direct dislocation segments is less than the angle threshold;
[0070] The third criterion condition is that the burgers vectors of the two direct dislocation segments belong to The burgers vector corresponding to the type partial dislocation, and the sum of the burgers vectors of the two direct dislocation segments belongs to The burgers vector corresponding to the type full dislocation.
[0071] It should be noted that the above distance thresholds and angle thresholds are preset values and can be determined based on actual experiments or reference values in literature.
[0072] In addition, for each pair of direct dislocation segments, when calculating the coordinates of the two structural nodes of the full dislocation, if the direction vectors of the two direct dislocation segments are in the same direction, then the structural node coordinates of the head of the full dislocation are the same as those of the direct dislocation segments. Head structure node With another direct dislocation segment Head structure node The coordinates of the middle point of the full dislocation are the tail structure node coordinates of a direct dislocation segment. The tail structure node With another direct dislocation segment The tail structure node The coordinates of the middle point of the dislocation; if the direction vectors of the two direct dislocation segments are in different directions, the coordinates of the head structure node of the full dislocation are the coordinates of a direct dislocation segment. Head structure node With another direct dislocation segment The tail structure node The coordinates of the middle point of the full dislocation are the tail structure node coordinates of a direct dislocation segment. The tail structure node With another direct dislocation segment Head structure node The coordinates of the middle point.
[0073] In an embodiment of the present invention, the identification of stacking fault tetrahedrons depends on the fourth matrix file, and the method for identifying stacking fault tetrahedrons that can be adopted is: using all independent structural nodes as graph nodes and the fourth matrix file as the adjacency matrix to establish a second undirected graph; searching in the second undirected graph whether there are four independent structural nodes forming a K4 complete subgraph, and if so, identifying the topological structure corresponding to each K4 complete subgraph as a stacking fault tetrahedron.
[0074] Furthermore, in order to improve the search efficiency of the K4 complete subgraph, we can first search the K3 complete subgraph in the second undirected graph, and then determine whether there is a node in any graph node of the K3 complete subgraph that has direct edge connections with the three graph nodes in the K3 complete subgraph. If such a node exists, then this node and the three graph nodes in the K3 complete subgraph together constitute the K4 complete subgraph.
[0075] In an embodiment of the present invention, the identification of dislocation loops depends on a third matrix file, and the method for identifying dislocation loops that can be adopted is: using all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix to establish a first undirected graph; searching in the first undirected graph whether there are end-to-end connected circular subgraphs, and if so, identifying the topological structure corresponding to each circular subgraph as a dislocation loop.
[0076] In an embodiment of the present invention, the identification of the dominant dislocation depends on the second matrix file and the third matrix file. The method for identifying the dominant dislocation that can be used is:
[0077] A first undirected graph is established with all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix; combining the node connectivity relationship recorded in the fourth matrix file and the dislocation segment length recorded in the second matrix file, two independent structural nodes with a connectivity relationship and a sum of all dislocation segment lengths on the shortest connectivity path exceeding the critical length of the dislocation are searched in the first undirected graph, and the topological structure corresponding to the shortest connectivity path of the two independent structural nodes constitutes a long dislocation; and all dislocation segments directly or indirectly connected to each long dislocation in the first undirected graph and the long dislocation itself are identified as a dominant dislocation.
[0078] It should be noted that there is a long dislocation between two independent structural nodes, which requires two conditions to be met at the same time. The first condition is that the two independent structural nodes have a connected relationship recorded in the fourth matrix file, and the second condition is that the sum of the lengths of all dislocation segments along the shortest connected path between the two independent structural nodes in the first undirected graph exceeds the critical length of the dislocation. The critical length of the dislocation is a preset value, which can be determined based on actual experiments or reference values in literature.
[0079] Therefore, based on the above four dislocation type identification methods, the location of each type of dislocation can be identified from the molecular dynamics model of the target metal material, and the number of each type of dislocation can be counted.
[0080] In addition, it should be noted that in the dislocation configuration identification and statistical method for molecular dynamics simulation described in the above embodiment, each step S1 to S5 can be implemented in the form of program code.
[0081] Therefore, based on the same inventive concept, another preferred embodiment of the present invention also provides a dislocation configuration identification and statistical system for molecular dynamics simulation corresponding to the dislocation configuration identification and statistical method for molecular dynamics simulation provided in the above embodiment, such as Figure 3 As shown, the system includes:
[0082] A molecular dynamics simulation module, used for obtaining a first result file containing dislocation structure information through molecular dynamics simulation based on a molecular dynamics model of a target metal material;
[0083] A dislocation structure analysis and identification module, used to analyze and identify the dislocation structure of the first result file to obtain a second result file containing relevant information of all dislocation segments, wherein the relevant information of each dislocation segment includes node numbers and coordinates of all dislocation nodes contained in the dislocation segment;
[0084] A structural node reconstruction module is used to use the dislocation nodes at both ends of the dislocation segment as structural nodes and the remaining nodes as internal nodes, extract the structural nodes of all dislocation segments from the second result file and remove duplicates based on the node coordinates, retain all independent structural nodes, assign a unique identifier to each independent structural node, and record the coordinates of the independent structural node and its corresponding original node sequence number set on all dislocation segments; at the same time, for all independent structural nodes, re-establish a first matrix file for recording the Burger vectors of the dislocation segments between nodes, a second matrix file for recording the lengths of the dislocation segments between nodes, and a third matrix file for recording the direct connection relationship between nodes;
[0085] A connectivity relationship analysis module, used for further analyzing whether any two independent structural nodes satisfy any direct connection or indirect connection based on the third matrix file, and if so, it is considered that there is a connectivity relationship between the two independent structural nodes, and recorded in the fourth matrix file;
[0086] The dislocation identification and statistics module is used to identify and count the positions of one or more of full dislocations, stacking fault tetrahedrons, dislocation rings and dominant dislocations in the molecular dynamics model based on the information recorded in the first matrix file, the second matrix file, the third matrix file and the fourth matrix file.
[0087] The specific implementation method of each functional module in the above system is the same as the corresponding method steps in the above embodiment, and will not be repeated here.
[0088] Similarly, based on the same inventive concept, another preferred embodiment of the present invention also provides a computer electronic device corresponding to the dislocation configuration identification and statistical method for molecular dynamics simulation provided in the above embodiment, such as Figure 4 As shown, the computer electronic device includes a memory and a processor;
[0089] The memory is used to store computer programs;
[0090] The processor is used to implement the above-mentioned dislocation configuration identification and statistical method for molecular dynamics simulation when executing the computer program.
[0091] In addition, the logic instructions in the above-mentioned memory can be implemented in the form of software functional units and can be stored in a computer-readable storage medium when sold or used as an independent product. Based on such an understanding, the technical solution of the present invention, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present invention.
[0092] Therefore, based on the same inventive concept, another preferred embodiment of the present invention also provides a computer-readable storage medium corresponding to the dislocation configuration identification and statistical method for molecular dynamics simulation provided in the above embodiment, and a computer program is stored on the storage medium. When the computer program is executed by the processor, it can implement the dislocation configuration identification and statistical method for molecular dynamics simulation as described above.
[0093] It is understandable that the above storage medium and memory may be a random access memory (RAM) or a non-volatile memory (NVM), such as at least one disk memory. The storage medium may also be a U disk, a mobile hard disk, a magnetic disk or an optical disk, etc., which can store program codes.
[0094] It is understandable that the above-mentioned processor can be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it can also be a digital signal processor (DSP), an application specific integrated circuit (ASIC), a field programmable gate array (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0095] It should also be noted that those skilled in the art can clearly understand that for the convenience and simplicity of description, the specific working process of the device described above can refer to the corresponding process in the aforementioned method embodiment, and will not be repeated here. In each embodiment provided in this application, the division of steps or modules in the device and method is only a logical function division, and there may be other division methods in actual implementation, such as multiple modules or steps can be combined or integrated together, and a module or step can also be split.
[0096] The present invention will further demonstrate the detailed implementation process and technical effects of the dislocation configuration identification and statistical method for molecular dynamics simulation shown in the above steps S1 to S5 on a specific example through a specific embodiment, so as to facilitate understanding of the essence of the present invention.
[0097] Example
[0098] In this embodiment, the specific implementation steps of the dislocation configuration identification and statistical method for molecular dynamics simulation are as follows:
[0099] Step 1: Establish a molecular dynamics model, load the model based on LAMMPS and output the result file.
[0100] In this embodiment, in step 1, it is necessary to pre-set the initial simulation parameters, use the three-dimensional simulation mode, select the metal format as the measurement unit, set the potential function, set the atomic mass, set the boundary conditions, and output the calculation results as a dump file.
[0101] Step 2: Import the calculation result file into OVITO software, use the dislocation analysis (DXA) module to analyze and identify the dislocation structure, and export the DXA analysis results.
[0102] In this embodiment, in step 2, the dump file output by the LAMMPS calculation needs to be read by the OVITO software. The lattice type in the dislocation analysis (DXA) module can be automatically identified. The lattice type of the metal crystal is usually FCC / BCC or HCP. The loop length and loop elongation parameters can usually take the default values of 14 and 9. After the dislocation analysis of the OVITO software is completed, the Crystal Analysis File (caf) file is exported.
[0103] In this step, the caf file exported by OVITO software stores the serial numbers and corresponding coordinates of all dislocation nodes contained in each dislocation line. Specifically, it stores the structural nodes (with ) and internal nodes (denoted by Represents) implementation, such as Figure 2 As shown, Represents 5 structure nodes, Indicates 5 internal nodes. Since different dislocation segments can only be connected through structural nodes, when analyzing the topological connection relationship between dislocation nodes in the subsequent analysis, only the topological connection relationship between structural nodes needs to be analyzed. In addition, due to the repeatability of the DXA analysis algorithm, the same structural node in the caf file may be stored repeatedly and marked with different serial numbers, so it needs to be reconstructed in the subsequent reading of the dislocation structural node information in the caf file.
[0104] Step 3: Read and store the dislocation node information and dislocation line segment information obtained by DXA analysis and reconstruct them, delete the redundant information caused by repeated dislocation nodes in the system, and establish the Burgers vector matrix, dislocation length matrix and node connection matrix;
[0105] In this embodiment, in step 3, the caf file output by the DXA module can be read by a program, and the dislocation information storage area can be located in the caf file by the "DISLOCATIONS" keyword, and then the information of each dislocation segment is stored in the following order: Line 1: store the dislocation segment serial number; Line 2: store the dislocation segment burgers vector; Line 3: store the serial number of the crystal cluster where the dislocation is located, which is regarded as a blank information line; Line 4: the total number of structural nodes and internal nodes contained in the dislocation segment (recorded as nPoints); Line 5 to Line (4+nPoints): store the coordinates of the head structural node, internal node and tail structural node in turn.
[0106] In this embodiment, step 3 can be implemented through the following three sub-steps.
[0107] Step 3.1: Get the total number of dislocation segments nDisSeg and the total number of structure nodes nStructPoint in the caf file.
[0108] As mentioned above, the same structure node in the caf file may be stored repeatedly and marked with different serial numbers, so the dislocation structure node information needs to be reconstructed according to the uniqueness of the coordinates for subsequent structural analysis. To facilitate the determination of the array length in future programs, in this step, the program will first traverse all dislocation segments and dislocation node information, obtain the total number of dislocation segments and store it in the variable nDisSeg, and obtain the total number of structure nodes and store it in the variable nStructPoint.
[0109] Step 3.2: Traverse the dislocation structure node information in the caf file, and establish a structure array UniqueNodesArray to store the sequence number, coordinates and equivalent node sequence number of independent structure nodes. The specific steps of this step are as follows:
[0110] Create a new structure UniqueNode in the program, which includes the following variables: an integer variable named "index" is used to store the serial number of a dislocation structure node (the serial number is the unique ID of the structure), a floating-point array named "Point" is used to store the coordinates of a dislocation structure node, an integer variable named "nEqualPoints" is used to store the number of equivalent nodes to the current structure node (equivalent nodes are structure nodes that are actually located in the same position in the caf file but are identified as different serial numbers), and an integer array named equalPointNames is used to store the serial numbers of each equivalent node of the current dislocation structure node (that is, the original node number of the structure node in the caf file).
[0111] Step 3.3: Re-traverse the dislocation node information in the caf file (including dislocation burgers vector information, structure nodes and internal node coordinates), establish the matrix DirectConnect to store the connection relationship between dislocation structure nodes, establish the matrix DirectDistance to store the dislocation length between dislocation structure nodes, and establish the matrix BurgersMatrix to store the burgers vector of the dislocation line segment. The specific steps of this step are as follows:
[0112] Step 3.3.1): Create a new structure array named UniqueNodesArray, where each element is a structure UniqueNode, and its length is set to 1000+nStructPoint / 3. Based on the program (such as MATLAB), read the structure node information of each dislocation line in turn and store them in the structure array UniqueNodesArray in turn. In the process of reading the structure node, it is necessary to check whether the current structure node has been read. Let the coordinates of the current structure node be , the coordinates of all structure nodes stored in the structure array UniqueNodesArray form a matrix (Assume that the number of structure nodes stored in UniqueNodesArray is n, then is a matrix of n rows and 3 columns). The basis for judging whether the current structure node has been read is:
[0113]
[0114] in Representation Matrix The array formed by the i-th row. If the above criteria are met, it means that the node has not been read yet, and the program will create a new unit in the structure array to store the unit number and coordinates; on the contrary, if the above criteria are not met, it means that the node has been read, and the program will store the serial number corresponding to the node in the equalPointNames array in the structure at the corresponding position of the structure array, and increment the nEqualPoints variable; traverse all the structure nodes in the caf file in turn, and obtain the structure array variable UniqueNodesArray that stores non-repeated information location information. Finally, count the number of non-empty elements N in UniqueNodesArray and save it in the variable nUniquePoint, and delete the empty elements in UniqueNodesArray. Therefore, each structure UniqueNode in UniqueNodesArray stores a structure node, and the structure nodes stored in any two structures UniqueNode in UniqueNodesArray are not repeated, which can be called independent structure nodes. The value of the variable nUniquePoint is the number N of independent structure nodes in UniqueNodesArray.
[0115] Step 3.3.2): After obtaining the structure array UniqueNodesArray used to store the serial number and position information of the dislocation structure nodes, in order to obtain the connection relationship between the dislocation structure nodes, the length of each dislocation segment and the burgers vector information, it is necessary to traverse the dislocation nodes again based on the dislocation information storage fragments in the caf file to establish reading and storing related information. In this embodiment, the connection relationship between the dislocation structure nodes is stored by the matrix DirectConnect, the dislocation length between the dislocation structure nodes is stored by the matrix DirectDistance, and the burgers vector of the dislocation line segment is stored by the matrix BurgersMatrix. The specific construction method of the three matrix files is described in detail below.
[0116] A. Construction of BurgersMatrix
[0117] The burgers vector of the dislocation is directly stored in the caf file. A new matrix BurgersMatrix (three-dimensional tensor file) of nUniquePoint×nUniquePoint×3 is created in the program to store the burgers vector information of each dislocation.
[0118] Traverse the area storing dislocation information in the caf file, and for the coordinates of the head structure node and the tail structure node of a certain dislocation, find the corresponding serial number in the structure array UniqueNodesArray based on their respective coordinate values (the serial number is a unique ID in the array, not the node serial number in the caf file). Let the serial numbers found be iStart and iEnd, that is:
[0119]
[0120]
[0121] Where pointStart and pointEnd are the coordinates of the head and tail structure nodes of the dislocation respectively. The element in the iStart row and iEnd column of the tensor Burgers is assigned the corresponding burgers vector value read, that is:
[0122]
[0123] BurgersMatrix is a tensor used to store the burgers vector information of each dislocation segment, and burgersTmp is the burgers vector corresponding to the current dislocation segment read.
[0124] Due to the undirected connectivity between dislocation structure nodes, after all traversals and assignments are completed, a symmetric operation is performed on each burgers vector dimension of the matrix BurgersMatrix, namely:
[0125]
[0126] Where: i represents the i-th burgers vector dimension in BurgersMatrix.
[0127] B. Construction of DirectDistance Matrix
[0128] In the program, a new matrix DirectDistance of nUniquePoint×nUniquePoint is created to store the length of the dislocation segment. All elements are initialized to -1, indicating that any two structure nodes are not connected at the beginning. The length information of the dislocation is obtained by calculating the distance between adjacent nodes and summing them. Suppose the structure nodes at the head and tail of the dislocation segment p are indexed in the structure array UniqueNodesArray as iStart and iEnd respectively. The dislocation segment composed of these two structure nodes contains a total of m dislocation nodes. Then the length of the dislocation segment p is calculated as:
[0129]
[0130] In the formula Represents the qth dislocation node inside dislocation segment p and the q+1th dislocation node The Euclidean distance in three-dimensional space can be calculated by coordinates. It should be noted that the m dislocation nodes here need to include all nodes on the dislocation segment, that is, they need to include structural nodes and internal structures.
[0131] Then you can assign values to the DirectDistance matrix:
[0132]
[0133] in represents the total length of the pth dislocation, Represents a structure node With structure nodes The length of the dislocation segment formed between them, m represents the total number of dislocation nodes that constitute the dislocation segment p. represents the qth node constituting the dislocation segment p (including the structural node K and the internal node P, which are uniformly represented by N here), Represents the element in the DirectDistance matrix at row iStart and column iEnd.
[0134] Due to the undirected nature of the connectivity between dislocation structure nodes, after all traversals and assignments are completed, the matrix DirectDistance is subjected to a symmetric operation, namely:
[0135]
[0136] C. Construction of DirectConnect Matrix
[0137] In the program, a new matrix DirectConnect of nUniquePoint×nUniquePoint is created to store the connection relationship between the dislocation structure nodes, and its initial values are all set to 0. Traverse the area storing the dislocation information in the caf file, and for the coordinates of the head structure node and the tail structure node of a certain dislocation, find the corresponding serial number in the structure array UniqueNodesArray based on their respective coordinate values. Suppose the serial numbers found are iStart and iEnd respectively, which means that the structure node With structure nodes Dislocation segments are formed between them, so the structural nodes With structure nodes They are connected, and the matrix DirectConnect is assigned as follows:
[0138]
[0139] Due to the undirected nature of the connectivity between dislocation structure nodes, after all traversals and assignments are completed, the matrix DirectConnect is subjected to a symmetric operation, namely:
[0140]
[0141] Step 4: Analyze the connection relationship between dislocation nodes based on the breadth-first search algorithm;
[0142] In step 4 of this embodiment, a breadth first search (BFS) is used to analyze the connectivity of the nodes and calculate the shortest path. In the present invention, an undirected graph can be modeled by storing the connection relationship between the dislocation structure nodes through the nUniquePoint×nUniquePoint array DirectConnect, and the element DirectConnect(i,j) in the i-th row and j-th column in the matrix DirectConnect represents the connection relationship between the structure node i and the structure node j. If DirectConnect(i,j)=1, it means that the structure node i and the structure node j can be directly connected through a path (called "direct connection"), otherwise it means that they cannot be directly connected.
[0143] In the program implementation, you first need to initialize a queue and two auxiliary arrays to assist the algorithm. The queue is used to store the nodes that need to be visited in order and record the number of steps from the starting point to the node. The access array is used to mark which nodes have been processed to avoid repeated visits. The distance array is used to record the number of steps of the shortest path from the starting point to each node. In the initial state, the distance of all nodes is infinite, indicating that they are unreachable. As BFS progresses, when a node is visited, its corresponding shortest path length will be calculated and updated.
[0144] Specifically, step 4 of this embodiment can be implemented by the following sub-steps:
[0145] Step 4.1: Initialize the connection matrix and distance matrix. As mentioned above, there are nUniquePoint structure nodes in total. Define the nUniquePoint×nUniquePoint matrix StepMatrix to store the shortest number of steps from each structure node to other structure nodes. Initially: the elements of the matrix StepMatrix except the diagonal are assigned -1, indicating that they are unreachable; the diagonal elements are assigned 0, and the distance from each structure node to itself is 0.
[0146] Step 4.2: BFS traversal. For structure nodes To structure node For each point, start the BFS traversal from it. Use a queue queue to store the points to be visited. Each element in the queue is a tuple (current point, current step number). Add the starting point start (i.e. the first structure node) in the queue queue to the queue and set StepMatrix(start,start)=0.
[0147] Take a point current from the queue and traverse all its adjacent points neighbor. If DirectConnect (current, neighbor) == 1 and neighbor has not been visited (that is, StepMatrix (start, neighbor) == -1), update StepMatrix (start, neighbor) to add 1 to the current step number and add neighbor to the queue. Repeat the above process until the queue is empty. After the traversal is completed, mark all distances that are still float ('inf') as 1, indicating that they are unreachable.
[0148] So far, the StepMatrix matrix stores the shortest number of connection steps between any two structural nodes. Define the matrix TotalConnectMatrix to store the connectivity between any two structural nodes, that is, for the structural nodes To structure node , if it can be connected through several steps, then TotalConnectMatrix(i,j)=1, otherwise TotalConnectMatrix(i,j)=0. The matrix TotalConnectMatrix can be calculated based on StepMatrix, and the calculation rules are as follows:
[0149]
[0150] Step 5: Based on the connection relationship between dislocation nodes and the Burgers vector information, identify the positions of various types of dislocations in the model, such as full dislocations, stacking fault tetrahedrons, dislocation rings, and dominant dislocations, and count their numbers.
[0151] In step 5 of this embodiment, the dislocation configuration identification and statistical method for molecular dynamics simulation includes four key functional modules, namely, a full dislocation identification module, a stacking fault tetrahedron (SFT) identification statistical module, a dislocation ring identification statistical module, and a dominant dislocation identification module. The specific implementation methods of each functional module will be introduced below.
[0152] 5.1. Full dislocation identification module
[0153] In actual metal crystals, dislocations may exist in the form of full dislocations or partial dislocations. Dislocations with a Burgers vector equal to the lattice vector or an integer multiple thereof are usually called full dislocations, while those with a Burgers vector less than the lattice vector are called partial dislocations (or partial dislocations). Taking FCC metals as an example, their full dislocation is Type, partial dislocation is Type, one A full dislocation can be achieved through the dislocation reaction: Decomposed into 2 partial dislocations. In molecular dynamics simulations, dislocations often exist in the form of partial dislocations. The results of dislocation analysis directly based on molecular dynamics simulation results are also partial dislocations. Therefore, further identification of the full dislocation position is crucial to understanding dislocation behavior.
[0154] Identifying all dislocations can be transformed into the following mathematical problem: For an undirected graph storing dislocation information , is the set of all independent structure nodes, is a set of dislocation line segments, representing the dislocation segments between connected structural nodes. Undirected graph in the full dislocation identification module The matrix DirectConnect is used as the adjacency matrix. The matrix DirectConnect stores the direct connection relationship between dislocation structure nodes (i.e., for two structure nodes , if the two are directly connected, then DirectConnect(i,j)=1, otherwise DirectConnect(i,j)=0). In addition, the matrix BurgersMatrix is also needed to identify the whole dislocation. The BurgersMatrix stores the burgers vector information of each segment of dislocation (for 2 structural nodes , if the two are directly connected, then BurgersMatrix(i,j,:) is the burgers vector of the dislocation segment formed by the connection of these two structural nodes. If the two are not connected, then BurgersMatrix(i,j,:) is [-1;-1;-1] indicating an invalid value). In this embodiment, the criterion for the existence of a full dislocation is: find the four structural nodes on the two dislocation segments , ,in Dislocation segment , Dislocation segment , so that the following three conditions are met at the same time: 1) The dislocation segment and The vertical distance between Less than a given value ; 2) Dislocation segment and The angle between them is less than the given value ; 3) Dislocation segment and burgers vector Belong to Type partial dislocation, and dislocation segment and The sum of the burgers vector belong Type total dislocation. The mathematical expression of the above three criteria is:
[0155]
[0156] in Dislocation Segments , Any point on Dislocation segment , The direction vector of . For all possible The burgers vector corresponding to the type of partial dislocation (i.e. the set of partial dislocation burgers vectors), For all possible The burgers vector corresponding to the type full dislocation (i.e. the set of burgers vectors for the full dislocation).
[0157] If the above criteria are met, the two structural node positions of the full dislocation are defined as and They are:
[0158]
[0159]
[0160] In the above and In the definition of Direction vector and dislocation segment Direction vector In the same direction, for and The midpoint of Direction vector and dislocation segment Direction vector Different direction, for and The middle point of the dislocation segment Direction vector and dislocation segment Direction vector In the same direction, for and The midpoint of Direction vector and dislocation segment Direction vector Different direction, for and The middle point.
[0161] In addition, the burgers vector of the entire dislocation needs to be calculated :
[0162]
[0163] In an example of this embodiment, DXA dislocation analysis is first performed on the FCC type metal simulated by LAMMPS to obtain four partial dislocations, and the caf file obtained by the dislocation analysis is subjected to full dislocation identification based on the method of the present invention, and the setting =20, , and get Figure 5 The results shown, where (a) is the atomic model of the dislocation, the green atoms represent the FCC crystal type, the red atoms represent the HCP crystal type, and the red HCP atoms in the figure are stacking faults between partial dislocations; (b) is the 4 partial dislocations obtained by DXA analysis, the green line segments represent partial dislocations, and the gray arrows represent the burgers vector of each dislocation; (c) is the full dislocation identified based on the method of the present invention, the blue line segments represent the full dislocation, and the gray arrows represent the burgers vector of each dislocation. It can be seen that the method of the present invention can accurately identify the full dislocation in the model.
[0164] 5.2. Stacking Fault Tetrahedron (SFT) Identification Statistics Module
[0165] Stacking fault tetrahedron (SFT) is a typical irradiation defect (three-dimensional vacancy defect) that is widely present in irradiated face-centered cubic (FCC) metal materials and has a significant effect on the mechanical properties of the material. SFT consists of four {111} stacking fault planes and six strut dislocations in different directions. In terms of topological structure, the dislocation structure of SFT is characterized by the presence of four structural nodes, and any two structural nodes are connected in pairs. Therefore, the key to identifying and counting SFT from the dislocation structure is to find a four-point combination that satisfies the two-to-two connection.
[0166] The above problem corresponds to the "complete subgraph" problem in graph theory. In graph theory, by modeling dislocation points as nodes and dislocation segments as edges, an undirected graph can be constructed. ,in is the set of all independent structure nodes, is a set of dislocation line segments, representing the dislocation segments between connected structural nodes. is a complete subgraph , then corresponding to any two points in their subsets ,have: ,in and Each The number of edges that the subgraph needs to satisfy its four points is strip.
[0167] From an undirected graph Fast search for complete subgraphs in In order to improve the efficiency, the present invention adopts an optimization search method based on the adjacency matrix and triangular relationship. nUniquePoint is the total number of structural nodes in the system. Compared with directly enumerating all This method takes advantage of the local characteristics of the graph structure and the triangle relationship ( Complete triangular subgraph) to recursively construct , thereby reducing unnecessary combination checks.
[0168] The specific steps of the algorithm in the stacking fault tetrahedron identification statistical module are as follows:
[0169] Step 5.2.1: Construct an undirected graph Since there are few connections between the structural nodes of the dislocation, it belongs to a sparse graph, so the undirected graph in the statistical module of stacking fault tetrahedron identification Connect Matrix As an adjacency matrix, it is easy to query whether there is an edge between any two nodes.
[0170] Step 5.2.2: Find all Complete subgraph. Traverse each node v in the graph and treat it as Then, check all neighbor nodes u and w of v to make sure that there is an edge connection between u and w. If the condition is met, then Constitute a Complete subgraph. The specific steps are: 1. For each node v, traverse its adjacent nodes u; 2. For each adjacent node u, traverse the other adjacent nodes of node v (set as w, w≠u); 3. Check whether u and w are connected, if so, Constitute a Complete subgraph.
[0171] Step 5.2.3: Based on Complete subgraph search Complete subgraph. For each K3 complete subgraph found , traverse other nodes to find node x so that x is connected to u, v, and w by edges. Constitute a Complete subgraph.
[0172] In order to improve efficiency, the following optimization measures can be adopted. When the subgraph is complete, if the number of adjacent nodes of a structural node is less than 2, it can be skipped directly because it cannot belong to any K3 complete subgraph. In addition, a hash table can be used to store the adjacent node set of each node to quickly query common adjacent nodes.
[0173] 5.3 Dislocation loop identification statistics module
[0174] Dislocation loop is a kind of line defect in crystal, but it is not composed of a single screw dislocation or edge dislocation, but a ring dislocation caused by dislocation movement. There are two common dislocation loops, one is the dislocation loop caused by Frank-Read dislocation multiplication mechanism; the other is the dislocation loop caused by dislocation bypassing the second phase particles. Dislocation loops are widely present in metal crystals and have an important influence on dislocation movement behavior and plastic deformation mechanism. Therefore, the key to identifying and counting dislocation loops from dislocation structure is to find out whether there is a loop in the undirected graph.
[0175] As mentioned above, dislocation points are modeled as nodes and dislocation segments are modeled as edges to construct an undirected graph ,in is the set of all independent structure nodes, is a set of dislocation line segments, representing the dislocation segments between connected structural nodes, and an undirected graph in the dislocation loop identification statistics module use As the adjacency matrix of the graph. Start from any unvisited node and perform a depth-first search. During the traversal process, if it is found that a neighbor node of a node has been visited and this neighbor node is not the parent node of the current node, it means that there is a cycle in the graph.
[0176] The specific steps of the algorithm in the dislocation loop identification statistics module are as follows:
[0177] Step 5.3.1: Initialization. Create a visited tag array visited to record whether each node has been visited. At the same time, create a parent node array parent to record the parent node of each node.
[0178] Step 5.3.2: Traverse nodes and detect loops: Start DFS traversal from each unvisited node. During the DFS process, if a node that has been visited is found and this node is not the parent node of the current node, it means that there is a dislocation loop.
[0179] Step 5.3.3: Save the nodes of the dislocation loop: When a dislocation loop is detected, find the nodes that constitute the dislocation loop by backtracking the parent node array parent.
[0180] In an example of this embodiment, the internal dislocation evolution of FCC metal subjected to external loads is first simulated based on LAMMPS, and the LAMMPS calculation results are imported into OVITO software for DXA dislocation analysis. The caf file obtained by the dislocation analysis is further analyzed for dislocation structure (i.e., identification of stacking fault tetrahedrons and dislocation rings) based on the method of the present invention. The identification results are as follows: Figure 6 As shown, (a) is the dislocation configuration obtained based on DXA analysis, and (b) is the number of stacking fault tetrahedra (SFTs) and dislocation loops (LOOPs) counted based on the method of the present invention. Further manual statistics verified the correctness of the number of stacking fault tetrahedra and dislocation loops identified and counted by the algorithm.
[0181] It should be pointed out that although the full dislocation recognition, stacking fault tetrahedron and dislocation ring recognition modules in the present invention are all based on FCC crystals as examples, the algorithm is universal and can be directly applied to body-centered cubic (BCC) and hexagonal close-packed (HCP) crystals.
[0182] 5.4. Dominant dislocation identification module
[0183] In metal crystals, defects such as stacking fault tetrahedrons and dislocation loops are often immobile, but serve as obstacles to the movement of other movable dislocations. In contrast, the dislocation structure that directly affects the current plastic behavior of the crystal is often several long dislocations. These long dislocations may be moving and reacting with other dislocations at the same time. Identifying these long dislocations and the dislocation structures connected to them in the system is of great significance for capturing the changes in dislocation configuration and understanding the deformation mechanism of crystalline materials.
[0184] Since most dislocations that directly affect the plastic behavior of crystals are long dislocations, the critical dislocation length is defined as , and further define the dominant dislocation as: Finding the dominant dislocation can be transformed into the following mathematical problem: modeling the dislocation points as nodes and the dislocation segments as edges, constructing an undirected graph ,in is the set of all independent structure nodes, is a set of dislocation line segments, representing the dislocation segments between connected structural nodes.
[0185] The specific sub-steps of the algorithm in the dominant dislocation identification module are as follows:
[0186] Step 5.4.1: Filter the length greater than According to the connection matrix The connectivity relationship between nodes recorded in traverses the undirected graph For any two independent structural nodes that are connected, all dislocation segments on the shortest connected path between the two independent structural nodes form a dislocation to be screened. Based on the dislocation segment length information recorded in the matrix DirectDistance, select the dislocations with a length greater than are regarded as long dislocations, and their set is denoted as long_edges.
[0187] Step 5.4.2: Construct the adjacency matrix of the graph. Construct an undirected graph ,in is the set of all independent structure nodes, is a set of dislocation segments, used in the dominant dislocation identification module As an undirected graph The adjacency matrix is used to facilitate subsequent traversal.
[0188] Step 5.4.3: Label the main line segments. For each long dislocation in the set long_edges, in the undirected graph A depth-first search (DFS) is performed in the set to mark all dislocation segments that can be directly or indirectly connected to this long dislocation. The marked dislocation segments and the long dislocation itself constitute a dominant dislocation. Therefore, each long dislocation in the set long_edges can form a dominant dislocation.
[0189] Step 5.4.4: Extract the main line segments. Each long dislocation and all the marked dislocation segments connected to this long dislocation are the dominant dislocations.
[0190] In an example of this embodiment, the internal dislocation evolution of FCC metal subjected to external loads is first simulated based on LAMMPS, and the LAMMPS calculation results are imported into OVITO software for DXA dislocation analysis. The caf file obtained by the dislocation analysis is further analyzed for dislocation structure (marking "dominant dislocation") based on the method of the present invention. Figure 7 As shown, the The results of retaining the dominant dislocation under the condition of (a) showing the initial dislocation configuration of the atomic model obtained by molecular dynamics after DXA analysis; (b) showing the initial dislocation configuration of the atomic model obtained by the method of the present invention after DXA analysis; In this case, only the dominant dislocation is retained and the calculation results after deleting the other dislocations; (c) shows the calculation results of the method of the present invention. The calculation results are as follows. As the critical length increases As the length of the dislocation increases, more short dislocations are deleted, and only the long dislocations in the system and the dislocation structures connected to or reacting with them are retained. It can be seen that the method of the present invention can accurately identify the dominant dislocations in the system, that is, the long dislocations undergoing dislocation reactions and other dislocation lines or dislocation loops with lengths greater than a given value, while deleting other non-dominant dislocation structures.
[0191] In summary, the present invention can automatically identify and count dislocation structures such as full dislocations, dislocation rings, stacking fault tetrahedrons, and entangled dislocations in a system, which helps to accurately and quickly identify dislocation structures in complex systems.
[0192] The above-described embodiments are only some preferred implementations of the present invention, but are not intended to limit the present invention. A person skilled in the relevant technical field may make various changes and modifications without departing from the spirit and scope of the present invention. Therefore, any technical solution obtained by equivalent replacement or equivalent transformation falls within the protection scope of the present invention.
Claims
1. A dislocation configuration identification and statistical method for molecular dynamics simulation, characterized in that: include: S1. Based on the molecular dynamics model of the target metal material, a first result file containing dislocation structure information is obtained through molecular dynamics simulation; S2, analyzing and identifying the dislocation structure of the first result file to obtain a second result file containing relevant information of all dislocation segments, wherein the relevant information of each dislocation segment includes node numbers and coordinates of all dislocation nodes contained in the dislocation segment; S3, taking the dislocation nodes at both ends of the dislocation segment as structural nodes and the remaining nodes as internal nodes, extracting the structural nodes of all dislocation segments from the second result file and removing duplicates based on the node coordinates, retaining all independent structural nodes, assigning a unique identifier to each independent structural node, and recording the coordinates of the independent structural node and its corresponding original node sequence number set on all dislocation segments; at the same time, for all independent structural nodes, re-establishing a first matrix file for recording the Burger vectors of the dislocation segments between nodes, a second matrix file for recording the lengths of the dislocation segments between nodes, and a third matrix file for recording the direct connection relationship between nodes; S4. Based on the third matrix file, further analyzing whether any two independent structural nodes satisfy any one of direct connection or indirect connection. If so, it is considered that there is a connectivity relationship between the two independent structural nodes, and the relationship is recorded in the fourth matrix file. S5. Based on the information recorded in the first matrix file, the second matrix file, the third matrix file and the fourth matrix file, the positions of one or more of full dislocations, stacking fault tetrahedrons, dislocation loops and dominant dislocations in the molecular dynamics model are identified and the number is counted.
2. The dislocation configuration identification and statistical method for molecular dynamics simulation according to claim 1, characterized in that: The molecular dynamics simulation is implemented by the large-scale atomic and molecular parallel simulator LAMMPS, and the analysis and identification of the dislocation structure is implemented by the dislocation analysis module in OVITO.
3. The dislocation configuration identification and statistical method for molecular dynamics simulation according to claim 1, characterized in that: The first matrix file, the second matrix file and the third matrix file are established as follows: According to the total number of nodes N of all independent structural nodes, a first matrix file of N×N×3 size, a second matrix file of N×N size, and a third matrix file of N×N size are established, and the row and column numbers of the matrix elements in the three matrix files correspond to the unique identifiers of the N independent structural nodes respectively; then, each dislocation segment in the second result file is traversed in turn, the original node serial numbers of the structural nodes at both ends of the current dislocation segment are read and mapped to their respective unique identifiers respectively, and the two unique identifiers obtained by the mapping are used as row and column numbers in different orders to locate two target matrix elements in the three matrix files respectively, and a mark symbol representing that the nodes are directly connected through the dislocation segment is written into the target matrix element of the third matrix file, and at the same time, a three-dimensional Burger vector is read from the relevant information of the current dislocation segment and written into the three channels of the target matrix element in the first matrix file, and all the dislocation node coordinates contained in the relevant information of the current dislocation segment are read, and the Euclidean distances between adjacent dislocation nodes are calculated and summed to obtain the length of the current dislocation segment, which is written into the target matrix element of the second matrix file.
4. The dislocation configuration identification and statistical method for molecular dynamics simulation according to claim 1, characterized in that: The method for identifying the total dislocation is: A first undirected graph is established with all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix, wherein each edge in the first undirected graph corresponds to a direct dislocation segment, and each pair of direct dislocation segments in the undirected graph is traversed in turn, and combined with the burgers vectors of the pair of direct dislocation segments read from the first matrix file, it is determined whether the criterion condition for constituting a full dislocation is met. If so, the pair of direct dislocation segments is identified as a full dislocation, and the two structural node coordinates of the full dislocation are calculated based on the endpoint coordinates of the pair of direct dislocation segments, and the sum of the burgers vectors of the pair of direct dislocation segments is used as the burgers vector of the full dislocation.
5. The dislocation configuration identification and statistical method for molecular dynamics simulation according to claim 4, characterized in that: There are three criteria for the full dislocation. The first criterion is that the vertical distance between the two direct dislocation segments is less than the distance threshold. The second criterion is that the angle between the two direct dislocation segments is less than the angle threshold. The third criterion is that the burgers vectors of the two direct dislocation segments belong to The burgers vector corresponding to the type partial dislocation, and the sum of the burgers vectors of the two direct dislocation segments belongs to The burgers vector corresponding to the type full dislocation.
6. The dislocation configuration identification and statistical method for molecular dynamics simulation according to claim 4, characterized in that: For each pair of direct dislocation segments, when calculating the two structural node coordinates of the full dislocation, if the direction vectors of the two direct dislocation segments are in the same direction, then the head structural node coordinates of the full dislocation are the coordinates of the midpoint between the head structural node of one direct dislocation segment and the head structural node of the other direct dislocation segment, and the tail structural node coordinates of the full dislocation are the coordinates of the midpoint between the tail structural node of one direct dislocation segment and the tail structural node of the other direct dislocation segment; if the direction vectors of the two direct dislocation segments are in different directions, then the head structural node coordinates of the full dislocation are the coordinates of the midpoint between the head structural node of one direct dislocation segment and the tail structural node of the other direct dislocation segment, and the tail structural node coordinates of the full dislocation are the coordinates of the midpoint between the tail structural node of one direct dislocation segment and the head structural node of the other direct dislocation segment.
7. The dislocation configuration identification and statistical method for molecular dynamics simulation according to claim 1, characterized in that: The stacking fault tetrahedron identification method is as follows: using all independent structure nodes as graph nodes and the fourth matrix file as an adjacency matrix to establish a second undirected graph; searching in the second undirected graph whether there are four independent structure nodes constituting a K4 complete subgraph, and if so, identifying a stacking fault tetrahedron by the topological structure corresponding to each K4 complete subgraph; The method for identifying the dislocation loop is as follows: using all independent structure nodes as graph nodes and the third matrix file as an adjacency matrix to establish a first undirected graph; In the first undirected graph, it is searched whether there is a ring subgraph connected end to end. If so, the topological structure corresponding to each ring subgraph is identified as a dislocation ring.
8. The dislocation configuration identification and statistical method for molecular dynamics simulation according to claim 1, characterized in that: The method for identifying the dominant dislocation is: A first undirected graph is established with all independent structural nodes as graph nodes and the third matrix file as an adjacency matrix; combining the node connectivity relationship recorded in the fourth matrix file and the dislocation segment length recorded in the second matrix file, two independent structural nodes with a connectivity relationship and a sum of all dislocation segment lengths on the shortest connectivity path exceeding the critical length of the dislocation are searched in the first undirected graph, and the topological structure corresponding to the shortest connectivity path of the two independent structural nodes constitutes a long dislocation; and all dislocation segments directly or indirectly connected to each long dislocation in the first undirected graph and the long dislocation itself are identified as a dominant dislocation.
9. A dislocation configuration identification and statistical system for molecular dynamics simulation, characterized in that: include: A molecular dynamics simulation module, used for obtaining a first result file containing dislocation structure information through molecular dynamics simulation based on a molecular dynamics model of a target metal material; A dislocation structure analysis and identification module, used to analyze and identify the dislocation structure of the first result file to obtain a second result file containing relevant information of all dislocation segments, wherein the relevant information of each dislocation segment includes node numbers and coordinates of all dislocation nodes contained in the dislocation segment; A structural node reconstruction module is used to use the dislocation nodes at both ends of the dislocation segment as structural nodes and the remaining nodes as internal nodes, extract the structural nodes of all dislocation segments from the second result file, remove duplicates based on the node coordinates, retain all independent structural nodes, assign a unique identifier to each independent structural node, and record the coordinates of the independent structural node and its corresponding original node sequence number set on all dislocation segments; at the same time, for all independent structural nodes, re-establish a first matrix file for recording the Burger vectors of the dislocation segments between nodes, a second matrix file for recording the lengths of the dislocation segments between nodes, and a third matrix file for recording the direct connection relationship between nodes; A connectivity relationship analysis module, used for further analyzing whether any two independent structural nodes satisfy any direct connection or indirect connection based on the third matrix file, and if so, it is considered that there is a connectivity relationship between the two independent structural nodes, and recorded in the fourth matrix file; The dislocation identification and statistics module is used to identify and count the positions of one or more of full dislocations, stacking fault tetrahedrons, dislocation rings and dominant dislocations in the molecular dynamics model based on the information recorded in the first matrix file, the second matrix file, the third matrix file and the fourth matrix file.
10. A computer electronic device, characterized in that: including memory and processor; The memory is used to store computer programs; The processor is used to implement the dislocation configuration identification and statistical method for molecular dynamics simulation as described in any one of claims 1 to 8 when executing the computer program.
Citation Information
Patent Citations
A method for constructing hybrid dislocation atomic structure
CN109299786A
Modeling method of mixed dislocation atom structure
CN109448796A