A method for constructing polycrystalline microstructure models using image recognition technology
By adjusting the grain position using image recognition technology and the Monte Carlo method, the problem of insufficient accuracy of polycrystalline microstructure models in existing technologies is solved, and more efficient finite element analysis is achieved.
Patent Information
- Application Number
- CN202210912915.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-07-31
- Publication Date
- 2025-11-14
- Estimated Expiration
- 2042-07-31
AI Technical Summary
Existing techniques for constructing polycrystalline microstructure models use simplified geometric models, resulting in insufficient accuracy and difficulty in accurately describing the details of the real crystal structure, leading to large errors in finite element analysis.
Image recognition technology was used to identify the polycrystalline microstructure from metallographic images obtained by microscopic analysis, and the actual distribution matrix of grains in three-dimensional space was obtained. The grain positions were adjusted by combining the Monte Carlo method, the von Lono diagram was constructed, and a polycrystalline microstructure model was established.
The constructed polycrystalline microstructure model can more accurately reflect the real crystal structure, improve the efficiency and accuracy of finite element analysis, and simplify the modeling process.
Smart Images

Figure CN115798637B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of finite element analysis, and more specifically to a method for constructing a polycrystalline microstructure model using image recognition technology. Background Technology
[0002] With the development of computer technology, the finite element analysis method is increasingly used in the micromechanical simulation of polycrystalline materials. The establishment of polycrystalline finite element models has enabled researchers to gain a deeper understanding of the interaction behavior between grains and the mechanism of local deformation; moreover, as an effective tool for simulating mechanical processes at the microscale, it can simulate the local deformation and damage processes of components in service.
[0003] Since stress and strain are related to grain size, shape, orientation and distribution, finite element analysis in micromechanical simulation studies is usually performed by establishing a polycrystalline microstructure model in a computer simulation environment.
[0004] In early studies of polycrystalline microstructures, simplified geometric models were typically used to represent them, such as two-dimensional shapes like squares and hexagons, or three-dimensional shapes like cubes, rhombic dodecahedrons, and truncated octahedrons. However, because the simplified geometric models describe grain shapes and sizes that differ significantly from the actual sizes and shapes of grains in the polycrystalline microstructure models, this greatly affects the accuracy of mechanical simulations such as strain localization and microcrack propagation.
[0005] In recent years, the von Neumann diagram has been widely used in the construction of polycrystalline finite element models. Typically, a physical parameter (such as average grain size) of each grain in the polycrystalline material is first measured experimentally, and then the von Neumann diagram is constructed using the experimental data to form the polycrystalline finite element model. This type of polycrystalline finite element model constructed using the von Neumann diagram is a statistical model. However, because real crystal structures vary greatly, it is difficult to quantify them using a single physical parameter. Directly constructing a statistical model using the von Neumann diagram will lose detailed information about the real crystal structure, inevitably leading to significant errors in accuracy when using this statistical model for finite element analysis. How to construct a polycrystalline microstructure model that conforms to the real crystal structure is a problem that has been urgently needed to be solved in this field. Summary of the Invention
[0006] The purpose of this invention is to address the shortcomings of existing technologies by providing a method for constructing polycrystalline microstructure models using image recognition technology. This method directly applies the real crystal structure obtained from microscopic analysis to the modeling of polycrystalline microstructures. Compared to statistical similarity models that use a single physical parameter to quantify complex real crystal structures, the polycrystalline microstructure model constructed using this invention is more accurate and does not lose the detailed information of the real crystal structure.
[0007] The objective of this invention is achieved through the following approach: a method for constructing a polycrystalline microstructure model using image recognition technology, comprising the following steps:
[0008] 1) Perform microscopic analysis on the metal sample to obtain a metallographic image of the metal sample;
[0009] 2) Image recognition technology is used to identify the polycrystalline microstructure of the metal sample in the metallographic image, and the actual grain distribution matrix is obtained based on the distribution of grains of different sizes in the three-dimensional space in the polycrystalline microstructure. This matrix is used to represent the distribution of the position of each grain in the polycrystalline microstructure.
[0010] 3) Obtain the position of each grain in the polycrystalline microstructure in the three-dimensional coordinate system, and summarize the three-dimensional coordinates of each grain to form the initial position matrix of the grain;
[0011] 4) Establish the von Ronoy diagram of the polycrystalline microstructure based on the initial grain position matrix, and obtain the theoretical grain distribution matrix in the von Ronoy diagram;
[0012] 5) Based on the Monte Carlo method, the theoretical optimal position of each grain is determined by the error function between the actual grain distribution matrix and the theoretical grain distribution matrix, and the optimal grain position matrix is constructed.
[0013] 6) Establish a polycrystalline microstructure model of the metal sample based on the optimal grain position matrix.
[0014] Preferably, the process of identifying the polycrystalline microstructure of a metal sample in a metallographic image using image recognition technology is as follows:
[0015] 2-1) Convert the metallographic image to a grayscale image, and then convert the grayscale image to a binary image;
[0016] 2-2) Edge extraction is performed on the binary image to obtain the polycrystalline microstructure of the metal sample in the metallographic image.
[0017] Preferably, the binary image needs to undergo noise reduction processing before edge extraction.
[0018] Preferably, the three-dimensional coordinates of each grain are the coordinates of the centroid of each grain in a three-dimensional coordinate system.
[0019] Preferably, the parameters of the actual grain distribution matrix and the theoretical grain distribution matrix both include the average grain size, the actual size of large grains, the actual size of small grains, and the total percentage of grains of each size. The large grains are grains whose actual size is greater than the average size, and the small grains are grains whose actual size is less than the average size.
[0020] Preferably, the process of constructing the optimal grain position matrix is as follows:
[0021] 5-1) Number each grain;
[0022] 5-2) Select a grain and move it several times. Calculate the error function once for each move. Select the position where the error function value is minimized after the grain is moved as the theoretical optimal position of the grain. Adjust the actual position of the grain in the theoretical distribution matrix of the grain in the von Lono diagram to the theoretical optimal position.
[0023] 5-3) Select other grains and repeat step 5-2) several times to obtain the theoretical optimal position of each grain in turn, and construct the optimal position matrix of the grains;
[0024] Preferably, the expression for the error function is as follows:
[0025]
[0026] In the formula, E i Let F be the error function value. i F is the theoretical grain distribution matrix formed after moving the i-th grain. r is the actual grain distribution matrix, and n is the total number of grains in the polycrystalline microstructure.
[0027] The advantages of this invention are that the polycrystalline microstructure model constructed by this invention is suitable for predicting material deformation based on the real crystal structure when performing micromechanical finite element analysis. It can generate a polycrystalline microstructure model equivalent to the real crystal structure at any scale, which greatly improves the efficiency and quality of finite element simulation analysis. The steps are simple and convenient to use. Attached Figure Description
[0028] Figure 1 This is a flowchart of the present invention;
[0029] Figure 2 This is a schematic diagram illustrating the experimental principle of an embodiment of the present invention;
[0030] Figure 3 These are metallographic images and schematic diagrams of the polycrystalline microstructure of the metal samples in the embodiments of the present invention. Detailed Implementation
[0031] like Figures 1 to 3As shown, a method for constructing a polycrystalline microstructure model using image recognition technology includes the following steps:
[0032] 1) Perform microscopic analysis on the metal sample to obtain a metallographic image of the metal sample;
[0033] 2) Image recognition technology is used to identify the polycrystalline microstructure of the metal sample in the metallographic image, and the actual grain distribution matrix is obtained based on the distribution of grains of different sizes in the three-dimensional space in the polycrystalline microstructure. This matrix is used to represent the distribution of the positions of each grain in the polycrystalline microstructure, i.e. the real crystal structure.
[0034] In this embodiment, the process of using image recognition technology to identify the polycrystalline microstructure of a metal sample in a metallographic image is as follows:
[0035] 2-1) Convert the metallographic image to a grayscale image, and then convert the grayscale image to a binary image;
[0036] 2-2) Edge extraction is performed on the binary image to obtain the polycrystalline microstructure of the metal sample in the metallographic image.
[0037] In this embodiment, the Otsu's method is used to extract edges from the binary image. Based on the grayscale characteristics of the image, the image is divided into two parts: background and target. The target part is taken as the polycrystalline microstructure of the metal sample.
[0038] To ensure that the identified polycrystalline microstructure matches the real crystal structure as closely as possible, the binary image needs to be denoised before edge extraction. In this embodiment, mean filtering is used for denoising.
[0039] 3) Obtain the position of each grain in the polycrystalline microstructure in the three-dimensional coordinate system, and summarize the three-dimensional coordinates of each grain to form the initial position matrix of the grain;
[0040] To ensure that the initial position matrix of the grains accurately represents the true crystal structure of the polycrystalline material, the three-dimensional coordinates of the grains are generally represented by the coordinates of the centroid in a three-dimensional coordinate system. In this invention, it is assumed that the mass distribution of each grain is average, meaning that the centroid is the center of mass.
[0041] In this embodiment, the three-dimensional coordinates of each grain are the coordinates of the centroid of each grain in the three-dimensional coordinate system.
[0042] 4) Establish the von Ronoy diagram of the polycrystalline microstructure based on the initial grain position matrix, and obtain the theoretical grain distribution matrix in the von Ronoy diagram;
[0043] In this embodiment, the parameters of the actual grain distribution matrix and the theoretical grain distribution matrix both include the average size of the grains, the actual size of the large grains, the actual size of the small grains, and the total percentage of grains of each size. The large grains are grains whose actual size is greater than the average size, and the small grains are grains whose actual size is less than the average size.
[0044] 5) Based on the Monte Carlo method, the theoretical optimal position of each grain is determined by the error function between the actual grain distribution matrix and the theoretical grain distribution matrix, and the optimal grain position matrix is constructed.
[0045] In this embodiment, the expression for the error function is as follows:
[0046]
[0047] In the formula, E i Let F be the error function value. i F is the theoretical grain distribution matrix formed after moving the i-th grain. r is the actual grain distribution matrix, and n is the total number of grains in the polycrystalline microstructure.
[0048] The error function reflects the difference between the theoretical crystal structure and the actual crystal structure. The smaller the error function value, the smaller the difference between the theoretical crystal structure and the actual crystal structure. For example, if the error function value is zero, the theoretical crystal structure and the actual crystal structure are completely identical.
[0049] The process of constructing the optimal grain position matrix is as follows:
[0050] 5-1) Number each grain, for example, grain 1, grain 2, grain 3, ..., grain n;
[0051] 5-2) Select a grain and move it several times. Calculate the error function once for each move. Select the position where the error function value is minimized after the grain is moved as the theoretical optimal position of the grain. Adjust the actual position of the grain in the theoretical distribution matrix of the grain in the von Lono diagram to the theoretical optimal position.
[0052] 5-3) Select other grains and repeat step 5-2) several times to obtain the theoretical optimal position of each grain in turn, and construct the optimal position matrix of the grains;
[0053] For example, first select grain 1 and move it several times. Calculate the error function once for each move. Select the position where the error function value is the smallest after moving grain 1 as the theoretical optimal position of grain 1.
[0054] Then, move grain 1 in the theoretical distribution matrix of grains in the von Lono diagram to the theoretical optimal position of grain 1, and then select grain 2 and repeat step 5-2) to continue to determine the theoretical optimal position of grain 2. In this way, the theoretical optimal positions of all grains are confirmed, and then construct the grain optimal position matrix of the polycrystalline material based on the theoretical optimal positions of all grains.
[0055] 6) Obtain the theoretical crystal structure based on the optimal grain position matrix, and establish a polycrystalline microstructure model of the metal sample.
[0056] Since the theoretical crystal structure obtained from the optimal grain position matrix of the polycrystalline material is very close to the real crystal structure, importing the polycrystalline microstructure model constructed in this invention into computer simulation software such as CAE and MATLAB for finite element analysis can greatly improve the accuracy of the finite element analysis.
Claims
1. A method for constructing a polycrystalline microstructure model using image recognition technology, characterized in that, Includes the following steps: 1) Perform microscopic analysis on the metal sample to obtain a metallographic image of the metal sample; 2) Image recognition technology is used to identify the polycrystalline microstructure of the metal sample in the metallographic image and obtain the actual grain distribution matrix; 3) Obtain the position of each grain in the polycrystalline microstructure in the three-dimensional coordinate system, and summarize the three-dimensional coordinates of each grain to form the initial position matrix of the grain; 4) Establish the von Ronoy diagram of the polycrystalline microstructure based on the initial grain position matrix, and obtain the theoretical grain distribution matrix in the von Ronoy diagram; 5) Based on the Monte Carlo method, the theoretical optimal position of each grain is determined by the error function between the actual grain distribution matrix and the theoretical grain distribution matrix, and the optimal grain position matrix is constructed. 6) Establish a polycrystalline microstructure model of the metal sample based on the optimal grain position matrix.
2. The method for constructing a polycrystalline microstructure model using image recognition technology according to claim 1, characterized in that, The process of identifying the polycrystalline microstructure of a metal sample in a metallographic image using image recognition technology is as follows: 2-1) Convert the metallographic image to a grayscale image, and then convert the grayscale image to a binary image; 2-2) Edge extraction is performed on the binary image to obtain the polycrystalline microstructure of the metal sample in the metallographic image.
3. The method for constructing a polycrystalline microstructure model using image recognition technology according to claim 2, characterized in that, The binary image needs to be denoised before edge extraction.
4. The method for constructing a polycrystalline microstructure model using image recognition technology according to claim 1, characterized in that, The three-dimensional coordinates of each grain are the coordinates of the centroid of each grain in the three-dimensional coordinate system.
5. The method for constructing a polycrystalline microstructure model using image recognition technology according to claim 1, characterized in that, The parameters of both the actual grain distribution matrix and the theoretical grain distribution matrix include the average grain size, the actual size of large grains, the actual size of small grains, and the total percentage of grains of each size. Large grains are those whose actual size is greater than the average size, and small grains are those whose actual size is less than the average size.
6. The method for constructing a polycrystalline microstructure model using image recognition technology according to claim 1, characterized in that, The process of constructing the optimal grain position matrix is as follows: 5-1) Number each grain; 5-2) Select a grain and move it several times. Calculate the error function once for each move. Select the position where the error function value is minimized after the grain is moved as the theoretical optimal position of the grain. Adjust the actual position of the grain in the theoretical distribution matrix of the grain in the von Lono diagram to the theoretical optimal position. 5-3) Select other grains and repeat step 5-2) several times to obtain the theoretical optimal position of each grain in turn, and construct the optimal position matrix of the grains.
7. The method for constructing a polycrystalline microstructure model using image recognition technology according to claim 1 or 6, characterized in that, The expression for the error function is as follows: In the formula, E i Let F be the error function value. i F is the theoretical grain distribution matrix formed after moving the i-th grain. r is the actual grain distribution matrix, and n is the total number of grains in the polycrystalline microstructure.
Citation Information
Patent Citations
Grain finite element model modeling method based on real metallographic diagram structure
CN112712860A
Multi-scale simulation method for mechanical behavior of multi-phase composite material
WO2020237977A1