Neutron diffraction data processing method and device, electronic equipment and storage medium
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- INSTITUTE OF NUCLEAR PHYSICS AND CHEMISTRY CHINA ACADEMY OF ENGINEERING PHYSICS
- Filing Date
- 2024-06-19
- Publication Date
- 2026-07-14
Smart Images

Figure CN118711716B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of neutron scatter diffraction experimental data analysis technology, and in particular to a neutron scatter diffraction data processing method, apparatus, electronic device and storage medium. Background Technology
[0002] Due to the deep penetrating power and non-destructive nature of neutrons, neutron scattering diffraction technology is widely used to characterize the internal performance parameters and evolution laws of engineering components and materials, providing accurate and reliable scientific criteria for material structural design, performance evaluation, and process optimization. By combining experimental setup, instrument and sample layout with the internal structure and motion information of the sample obtained from neutron scattering diffraction experimental data analysis, the evolution law of material properties with sample sites can be obtained. However, due to limitations such as equipment precision and experimental time, the number of sample measurement points directly obtained from the experiment is limited, making it impossible to comprehensively and accurately characterize the changes in material properties in the sample measurement area, and the evolution law is difficult to express intuitively and explicitly. Summary of the Invention
[0003] This invention provides a method for processing neutron scatter diffraction data. It can perform key region deduction on the neutron scatter diffraction data to be processed using a first deduction mode or a second deduction mode, determining the refined coordinates of the key region. Based on the original spatial distribution of material properties and the refined coordinates of the key region, the continuous spatial distribution of material properties in the key region is determined. This allows for visualization of the continuous spatial distribution of material properties in the key region, resulting in a visualized processing result of the neutron scatter diffraction data. This method solves the problem that existing methods are limited by factors such as equipment precision and experimental time, resulting in a limited number of sample measurement points obtained directly from experiments. This makes it impossible to comprehensively and accurately characterize the changes in material properties in the sample measurement area, and the evolution law is difficult to express intuitively and explicitly. It fills the measurement gap in the intermediate region of discrete measurement points caused by limitations in equipment precision and experimental time.
[0004] This invention provides a method for processing neutron scatter diffraction data, the method comprising:
[0005] Acquire neutron scattering diffraction data to be processed, wherein the neutron scattering diffraction data to be processed includes the original material property spatial distribution of each original measurement point, wherein the original material property spatial distribution includes the original spatial position coordinates of the original measurement point and the corresponding original material property value;
[0006] The key region of the neutron scattering diffraction data to be processed is deduced by using either the first or the second deduction mode, and the refined coordinates of the key region are determined. The refined coordinates of the key region include the original spatial coordinates of the measurement points in the key region.
[0007] Based on the original spatial distribution of material properties and the refined coordinates of the key region, the continuous spatial distribution of material properties in the key region is determined;
[0008] The continuous spatial distribution of material properties in the key region is visualized to obtain the visualization results of the neutron scattering diffraction data to be processed.
[0009] Optionally, the first deduction mode has a higher deduction timeliness than the second deduction mode, and the first deduction mode has a lower deduction accuracy than the second deduction mode. The step of performing key region deduction on the neutron scattering diffraction data to be processed using the first or second deduction mode to determine the refined coordinates of the key region includes:
[0010] When the user selects the first simulation mode, the key region simulation is performed on the neutron scattering diffraction data to be processed through the first simulation mode to determine the refined coordinates of the key region.
[0011] When the user selects the second simulation mode, the key region simulation is performed on the neutron scattering diffraction data to be processed through the second simulation mode to determine the refined coordinates of the key region.
[0012] Optionally, the step of performing key region extrapolation on the neutron scattering diffraction data to be processed using the first extrapolation mode to determine the refined coordinates of the key region includes:
[0013] Based on the original spatial coordinates, and according to the coordinate range of each of its three dimensions and the user-defined three-dimensional grid density, a target cube that encloses all the original measurement points is interpolated.
[0014] The original spatial coordinates are triangulated by Delaunay triangulation to form a set of connected but non-overlapping Delaunay triangles, i.e., Delaunay triangulation network. Moreover, the circumcircle of each Delaunay triangle does not contain any other original measurement point in the region where the Delaunay triangle is located, i.e., any four points in the original measurement points cannot be on the same circle.
[0015] The new coordinates obtained by interpolation in the target cube are judged. If the new coordinates obtained by interpolation are inside the Deloitte triangulation, the new coordinates obtained by interpolation are added to the key area contour coordinate set; otherwise, the new coordinates obtained by interpolation are deleted. After judging each new coordinate obtained by interpolation, the key area contour coordinate set is obtained. The key area contour coordinate set should include the original measurement point spatial position coordinates.
[0016] The refined coordinates of the key region are obtained based on the spatial coordinates of the original measurement points.
[0017] Optionally, the step of performing key area deduction on the to-be-processed neutron diffraction data through the second deduction mode and determining the refined coordinates of the key area includes:
[0018] Based on the original spatial position coordinates, layer the original spatial position coordinates in three directions of X, Y, and Z to obtain multiple original coordinate layers. In the same direction, coordinate points with the same coordinate value or within the user-defined error range in the dimension of the layering direction are regarded as the same layer, and each coordinate point corresponds to an original measurement point;
[0019] Use a layer coordinate filter to screen the coordinate points of each layer, remove the original coordinate layers with the number of coordinate points <m after layering and the original coordinate layers with differences only in one dimension after layering, and obtain filtered coordinate layers;
[0020] For each of the filtered coordinate layers, respectively, according to the coordinate ranges of the remaining two dimensions and the preset three-dimensional grid density, interpolate a target rectangle that encloses the filtered coordinate layer;
[0021] Perform Delaunay triangulation on each of the filtered coordinate layers to form a set of a series of connected but non-overlapping Delaunay triangles, that is, a Delaunay triangulation network, and no other original measurement points in the plane area where each Delaunay triangle is located are included in the circumcircle of the Delaunay triangle, that is, any four points among the original measurement points cannot be concyclic;
[0022] Judge the newly interpolated coordinates in the target rectangle. If the newly interpolated coordinates are inside the Delaunay triangulation network, the newly interpolated coordinates are newly added to the key area contour coordinate set, otherwise the newly interpolated coordinates are deleted. After judging each of the newly interpolated coordinates in each of the filtered coordinate layers, a key area contour coordinate set is obtained, and the key area contour coordinate set should include the spatial position coordinates of the original measurement points;
[0023] Obtain the refined coordinates of the key area based on the spatial position coordinates of the original measurement points.
[0024] Optionally, the step of determining the continuous spatial distribution of the material properties in the key area based on the original material property spatial distribution and the refined coordinates of the key area includes:
[0025] Based on the original material property spatial distribution and the refined coordinates of the key area, use an interpolation algorithm based on radial basis functions to calculate the material characteristic values, and obtain the continuous spatial distribution of the material properties in the key area.
[0026] Optionally, the step of calculating the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region, using an interpolation algorithm based on radial basis functions, includes:
[0027] The radial basis function φ takes the distance between the interpolation coordinate point and the input coordinate point as a parameter, and utilizes the influence coefficient λ of each input coordinate point on the eigenvalues based on the input coordinate points and their corresponding eigenvalues. i The solution is performed using the original spatial position coordinates of the input coordinates. The interpolation algorithm based on the radial basis function is shown in the following formula:
[0028]
[0029] Among them, |xx i | represents the distance between the interpolated coordinate point and the input coordinate point;
[0030] In solving λ i At that time, the original input coordinate point x i Its corresponding material property value y i Substituting into equation (1), for any point (x) in the original measurement points j ,y j Substituting into equation (1), we get:
[0031]
[0032] Substituting all n coordinate points and their corresponding material property values from the original measuring points, we obtain n equations for the n unknowns λ1, λ2, ... λ. n The influence coefficient is obtained by solving the equation (2), and the material characteristic value y corresponding to the new coordinate x in the refined coordinate of the key area is obtained.
[0033] Alternatively, the radial basis function φ is shown in the following equation:
[0034]
[0035] Where m is the average distance between the original measurement points by default.
[0036] Optionally, the step of visualizing the continuous spatial distribution of material properties in the key region to obtain the visualization result of the neutron scattering diffraction data to be processed includes:
[0037] Based on the continuous spatial distribution of material properties in the key area, and combined with a preset color bar, each coordinate point in the key area is assigned a color corresponding to the material property value. A three-dimensional cloud map of the key area of the sample is drawn in the form of a scatter plot or a surface, and each material property value corresponds to a color value in the color bar.
[0038] This invention also provides a neutron scattering diffraction data processing device, the neutron scattering diffraction data processing device comprising:
[0039] The acquisition module is used to acquire neutron scattering diffraction data to be processed. The neutron scattering diffraction data to be processed includes the original material property spatial distribution of each original measurement point. The original material property spatial distribution includes the original spatial position coordinates of the original measurement point and the corresponding original material property value.
[0040] The first determining module is used to perform key region deduction on the neutron scattering diffraction data to be processed through a first deduction mode or a second deduction mode, and determine the refined coordinates of the key region. The refined coordinates of the key region include the original spatial position coordinates of the measurement points in the key region.
[0041] The second determining module is used to determine the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region;
[0042] The processing module is used to visualize the continuous spatial distribution of material properties in the key region to obtain the visualization results of the neutron scattering diffraction data to be processed.
[0043] The present invention also provides an electronic device, comprising: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the steps of the neutron scattering diffraction data processing method as described in any one of the embodiments of the present invention.
[0044] The present invention also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, implements the steps of the neutron scattering diffraction data processing method as described in any one of the embodiments of the present invention.
[0045] The neutron scatter diffraction data processing method of this invention can perform key region deduction on the neutron scatter diffraction data to be processed through a first deduction mode or a second deduction mode, determine the refined coordinates of the key region, and determine the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region. This allows for visualization of the continuous spatial distribution of material properties in the key region, resulting in the visualization of the neutron scatter diffraction data to be processed. This method solves the problem that existing methods are limited by factors such as equipment accuracy, signal acquisition speed, and experimental time, resulting in a limited number of sample measurement points obtained directly from experiments. This makes it impossible to comprehensively and accurately characterize the changes in material properties in the sample measurement area, and the evolution law is difficult to express intuitively and explicitly. This method fills the measurement gap in the middle region of discrete measurement points caused by limitations in equipment accuracy and experimental time. Attached Figure Description
[0046] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present invention. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0047] Figure 1 This is a schematic diagram of a neutron scattering diffraction data processing procedure provided in an embodiment of the present invention;
[0048] Figure 2 This is a schematic diagram illustrating the operating principle of a neutron scattering diffraction data processing method provided in an embodiment of the present invention;
[0049] Figure 3 This is a three-dimensional cloud map of material properties provided in an embodiment of the present invention that does not use the original measurement points of the present invention;
[0050] Figure 4 This is a continuous three-dimensional cloud map of the material properties of key areas after processing by the present invention, provided in an embodiment of the present invention;
[0051] Figure 5 This is a schematic diagram of the structure of a neutron scattering diffraction data processing device provided in an embodiment of the present invention;
[0052] Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention. Detailed Implementation
[0053] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0054] like Figure 1 As shown, Figure 1 This is a flowchart illustrating a neutron dispersion diffraction data processing method provided in an embodiment of the present invention. The neutron dispersion diffraction data processing method includes:
[0055] 101. Obtain the neutron scattering diffraction data to be processed.
[0056] In this embodiment of the invention, the above-mentioned neutron scattering diffraction data to be processed includes the original material property spatial distribution of each original measurement point, and the original material property spatial distribution includes the original spatial position coordinates of the original measurement point and the corresponding original material property value.
[0057] It should be noted that the original spatial coordinate dimension w is three-dimensional, two-dimensional, or one-dimensional (1≤w≤3), and the original material property dimension is ≥1.
[0058] 102. Perform key region deduction on the neutron scattering diffraction data to be processed using the first or second deduction mode to determine the refined coordinates of the key region.
[0059] In this embodiment of the invention, the refined coordinates of the key region include the original spatial coordinates of the measurement points in the key region.
[0060] The aforementioned first deduction mode can be the first deduction mode for the key area contour. Its working logic is as follows: Based on the original spatial coordinates, according to the coordinate range of each of its three dimensions and the user-defined three-dimensional mesh density, a target cube that encloses all original measurement points is interpolated. Then, the original spatial coordinates are triangulated using Delaunay triangulation to form a set of connected but non-overlapping Delaunay triangles, i.e., the Delaunay triangulation network. Moreover, the circumcircle of each Delaunay triangle does not contain any other original measurement point in the region where the Delaunay triangle is located, i.e., any four points in the original measurement points cannot be concentric. The new coordinates obtained by interpolation in the target cube are judged. If the new coordinates obtained by interpolation are inside the Delaunay triangulation network, the new coordinates obtained by interpolation are added to the key area contour coordinate set; otherwise, the new coordinates obtained by interpolation are deleted. After judging each new coordinate obtained by interpolation, the key area contour coordinate set is obtained. The key area contour coordinate set should include the original measurement point spatial coordinates. Thus, the refined coordinates of the key area are obtained based on the original measurement point spatial coordinates.
[0061] The aforementioned second deduction mode can be the second deduction mode for key area contours. Its working logic is as follows: Based on the original spatial coordinates, the original spatial coordinates are layered in the X, Y, and Z directions to obtain multiple original coordinate layers. That is, coordinate points with consistent coordinate values in the same direction or within the user-defined error range are considered to be in the same layer. The user can define the layering direction. A layered coordinate filter is used to filter the coordinate points of each layer, removing layers with less than 4 coordinate points or layers where the coordinates differ only in one dimension, resulting in filtered coordinate layers. For each filtered coordinate layer, the remaining coordinates are then processed according to... Using the coordinate ranges of the remaining two dimensions and the user-defined 3D mesh density, an interpolated target rectangle is generated to enclose the filter coordinate layer. Then, Delaunay triangulation is performed on each filter coordinate layer. The new coordinates obtained by interpolation in the target rectangle are judged. If the new coordinates obtained by interpolation are inside the Delaunay triangulation, the new coordinates obtained by interpolation are added to the key region contour coordinate set; otherwise, the new coordinates obtained by interpolation are deleted. After performing the above judgment on each new coordinate obtained by interpolation in each filter coordinate layer, the key region contour coordinate set is obtained. At the same time, the key region contour coordinate set should include the original spatial position coordinates of the measurement points.
[0062] The detailed coordinates of the aforementioned key areas can be understood as the location information of the key areas, including two-dimensional or three-dimensional coordinates of the key areas, and may even include information in the time dimension.
[0063] Specifically, the key region can be simulated using the first simulation mode to determine the refined coordinates of the key region; alternatively, the key region can be simulated using the second simulation mode to determine the refined coordinates of the key region.
[0064] It should be noted that the first simulation mode has a higher simulation timeliness than the second simulation mode, but the first simulation mode has a lower simulation accuracy than the second simulation mode. Users can freely choose the simulation mode by considering both accuracy and timeliness. They can choose either the first or second simulation mode to perform simulation of key regions in the neutron scattering diffraction data to be processed, and determine the refined coordinates of the key regions.
[0065] 103. Based on the spatial distribution of the original material properties and the refined coordinates of the key regions, determine the continuous spatial distribution of material properties in the key regions.
[0066] In this embodiment of the invention, the material characteristic values can be calculated using an interpolation algorithm based on radial basis functions, based on the original spatial distribution of material properties and the refined coordinates of the key region, to obtain the continuous spatial distribution of material properties in the key region.
[0067] The radial basis function (RBF) interpolation algorithm described above is a commonly used numerical approximation method. It can be understood as fitting data points by constructing a function with a specific form. The core idea of the RBF interpolation algorithm is to use the distance between data points to calculate the function value, thereby predicting unknown data.
[0068] 104. Visualize the continuous spatial distribution of material properties in key regions to obtain the visualization results of the neutron scattering diffraction data to be processed.
[0069] In this embodiment of the invention, the above visualization processing can be understood as the process of three-dimensional cloud map visualization processing.
[0070] It can present the material properties at different locations within a key area in the form of images, allowing for intuitive observation and analysis of the changing trends and distribution of material properties within the key area.
[0071] Specifically, based on the continuous spatial distribution of material properties in key areas derived from the deduced model, and combined with user-defined color bars, each spatial coordinate point can be assigned a color corresponding to the material property value, and a three-dimensional cloud map of the key areas of the sample can be drawn in the form of scattered points or curved surfaces.
[0072] In this embodiment, the present invention can deduce the material properties corresponding to other unmeasured points in the sample measurement area from the experimental results of random and sparse sample measurement points, thereby comprehensively and intuitively characterizing the distribution of material properties in the key areas of the sample.
[0073] In this embodiment of the invention, after acquiring the neutron scatter diffraction data to be processed, the key region can be deduced through either the first or second deduction mode to determine the refined coordinates of the key region. Based on the original spatial distribution of material properties and the refined coordinates of the key region, the continuous spatial distribution of material properties in the key region is determined, thereby visualizing the continuous spatial distribution of material properties in the key region and obtaining the visualized processing result of the neutron scatter diffraction data to be processed. This solves the problem that existing methods are limited by factors such as equipment accuracy, signal acquisition speed, and experimental time, resulting in a limited number of sample measurement points obtained directly from experiments, which makes it impossible to comprehensively and accurately characterize the changes in material properties in the sample measurement area and make it difficult to express the evolution law intuitively and explicitly. This fills the measurement gap in the middle region of discrete measurement points caused by limitations in equipment accuracy and experimental time.
[0074] Optionally, the first deduction mode has a higher deduction timeliness than the second deduction mode, but the first deduction mode has a lower deduction accuracy than the second deduction mode. The steps for performing key region deduction on the neutron scatter diffraction data to be processed using either the first or second deduction mode to determine the refined coordinates of the key region include: when the user selects the first deduction mode, performing key region deduction on the neutron scatter diffraction data to be processed using the first deduction mode to determine the refined coordinates of the key region; when the user selects the second deduction mode, performing key region deduction on the neutron scatter diffraction data to be processed using the second deduction mode to determine the refined coordinates of the key region.
[0075] In this embodiment of the invention, the first deduction mode can be a key area contour deduction mode one; the second deduction mode can be a key area contour deduction mode two.
[0076] The detailed coordinates of the aforementioned key areas can be understood as the location information of the key areas, including two-dimensional or three-dimensional coordinates of the key areas, and may even include information in the time dimension. Optionally, the steps for determining the refined coordinates of the key region by performing key region deduction on the neutron scattering diffraction data to be processed using the first deduction mode include: based on the original spatial position coordinates, interpolating a target cube that encloses all original measurement points according to the coordinate range of each of its three dimensions and the user-defined three-dimensional mesh density; performing Delaunay triangulation on the original spatial position coordinates to form a set of connected but non-overlapping Delaunay triangles, i.e., a Delaunay triangulation network, and the circumcircle of each Delaunay triangle does not contain any other original measurement point in the region where the Delaunay triangle is located, i.e., any four points in the original measurement points cannot be concentric circles; judging the new coordinates obtained by interpolation in the target cube, if the new coordinates obtained by interpolation are inside the Delaunay triangulation network, then adding the new coordinates obtained by interpolation to the key region contour coordinate set, otherwise deleting the new coordinates obtained by interpolation, and obtaining the key region contour coordinate set after judging each new coordinate obtained by interpolation, the key region contour coordinate set should include the original measurement point spatial position coordinates; and obtaining the refined coordinates of the key region based on the original measurement point spatial position coordinates.
[0077] In this embodiment of the invention, the working logic of the first deduction mode is based on the original spatial coordinates. According to the coordinate range of each of its three dimensions and the user-defined three-dimensional mesh density, a target cube that encloses all the original measurement points is interpolated. Then, the original spatial coordinates are triangulated using Delaunay triangulation to form a set of connected but non-overlapping Delaunay triangles, i.e., a Delaunay triangulation network. Moreover, the circumcircle of each Delaunay triangle does not contain any other original measurement point in the region where the Delaunay triangle is located, i.e., any four points in the original measurement points cannot be concentric. The new coordinates obtained by interpolation in the target cube are judged. If the new coordinates obtained by interpolation are inside the Delaunay triangulation network, the new coordinates obtained by interpolation are added to the key region contour coordinate set; otherwise, the new coordinates obtained by interpolation are deleted. After judging each new coordinate obtained by interpolation, the key region contour coordinate set is obtained. The key region contour coordinate set should include the original measurement point spatial coordinates. Thus, the refined coordinates of the key region are obtained based on the original measurement point spatial coordinates.
[0078] The aforementioned three-dimensional grid density can be understood as the number of grids divided within a unit volume, usually represented by the symbol ρ. In three-dimensional space, an object or field is divided into several grids, and each grid has a certain volume or area. The size of this volume or area reflects the grid density.
[0079] The Delaunay triangulation described above is a method for triangulating a set of points on a plane, ensuring that no three points lie on the same straight line and that the edges of each triangle do not intersect. In Delaunay triangulation, all points in the set are first located and sorted according to a certain rule. Then, three points are selected as vertices of a triangle, the line segment between them is calculated, and it is checked whether any other points lie on this line segment. If such points exist, they are removed from the set, and the vertices and edges of the triangle are recalculated. This process is repeated until no more triangles meeting the requirements can be found.
[0080] It should be noted that, based on the working principle of the first extrapolation mode, the key regions of the neutron scattering diffraction data to be processed are extrapolated to determine the refined coordinates of the key regions.
[0081] Optionally, the steps of determining the refined coordinates of the key area by performing key area deduction on the to-be-processed neutron scattering diffraction data through the second deduction mode include: based on the original spatial position coordinates, stratifying the original spatial position coordinates in the three directions of X, Y, and Z to obtain multiple original coordinate layers. In the same direction, coordinate points with the same coordinate values in the dimension of the stratification direction or within the user-defined error range are regarded as the same layer, and each coordinate point corresponds to an original measurement point; using a stratified coordinate filter to screen the coordinate points of each layer, removing the original coordinate layers with the number of coordinate points < m after stratification and the original coordinate layers with differences only in one dimension after stratification to obtain filtered coordinate layers; for each filtered coordinate layer, respectively interpolating a target rectangle enclosing the filtered coordinate layer according to the coordinate ranges of the remaining two dimensions and the preset three-dimensional grid density; performing Delaunay triangulation on each filtered coordinate layer to form a set of a series of connected but non-overlapping Delaunay triangles, that is, a Delaunay triangulation network, and there is no other original measurement point in the circumcircle of each Delaunay triangle within the plane area where the Delaunay triangle is located, that is, any four points among the original measurement points cannot be concyclic; judging the newly interpolated coordinates in the target rectangle. If the newly interpolated coordinates are inside the Delaunay triangulation network, the newly interpolated coordinates are newly added to the key area contour coordinate set, otherwise the newly interpolated coordinates are deleted. After judging each of the newly interpolated coordinates in each filtered coordinate layer, a key area contour coordinate set is obtained, and the key area contour coordinate set should include the spatial position coordinates of the original measurement points; obtaining the refined coordinates of the key area based on the spatial position coordinates of the original measurement points.
[0082] In the embodiment of the present invention, the working logic of the above second deduction mode is: based on the original spatial position coordinates, stratifying the original spatial position coordinates in the three directions of X, Y, and Z to obtain multiple original coordinate layers. That is, in the same direction, coordinate points with the same coordinate values in the dimension of the stratification direction or within the user-defined error range are regarded as the same layer, and the user can customize the stratification direction; using a stratified coordinate filter to screen the coordinate points of each layer, removing the original coordinate layers with the number of coordinate points < 4 after stratification and the original coordinate layers with differences only in one dimension after stratification to obtain filtered coordinate layers; for each filtered coordinate layer, respectively interpolating a target rectangle enclosing the filtered coordinate layer according to the coordinate ranges of the remaining two dimensions and the user-defined three-dimensional grid density. Then, performing Delaunay triangulation on each filtered coordinate layer, judging the newly interpolated coordinates in the target rectangle. If the newly interpolated coordinates are inside the Delaunay triangulation network, the newly interpolated coordinates are newly added to the key area contour coordinate set, otherwise the newly interpolated coordinates are deleted. After judging each of the newly interpolated coordinates in each filtered coordinate layer, a key area contour coordinate set is obtained. At the same time, the key area contour coordinate set should include the spatial position coordinates of the original measurement points.
[0083] The hierarchical coordinate filter described above is a method for processing and analyzing large amounts of coordinate data. By organizing the coordinate data according to a certain hierarchical structure, it enables more efficient querying and analysis of the data. The core idea of the hierarchical coordinate filter is to group the coordinate data according to spatial relationships or certain features, forming a tree-like structure. This tree-like structure is usually called a hierarchical tree. Each node in the hierarchical tree represents a set of coordinates, and the nodes are connected together through some relationship (such as distance, similarity, etc.).
[0084] It should be noted that, through the working logic of the second extrapolation mode, the key regions of the neutron scattering diffraction data to be processed are extrapolated, and the refined coordinates of the key regions are determined.
[0085] Optionally, the step of determining the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region includes: calculating material eigenvalues using an interpolation algorithm based on radial basis functions based on the original spatial distribution of material properties and the refined coordinates of the key region to obtain the continuous spatial distribution of material properties in the key region.
[0086] In this embodiment of the invention, the radial basis function interpolation algorithm described above is a commonly used numerical approximation method, which can be understood as fitting data points by constructing a function with a specific form. The core idea of the radial basis function interpolation algorithm is to use the distance between data points to calculate function values, thereby predicting unknown data.
[0087] The above material characteristic value calculation can be understood as the process of calculating the material characteristic value of unknown spatial coordinate points in a key region based on known material property data points.
[0088] The continuous spatial distribution of material properties in the aforementioned key regions can be understood as the continuous spatial distribution of material property values at each point within the key regions.
[0089] Optionally, the step of calculating the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region, using an interpolation algorithm based on radial basis functions, includes:
[0090] The radial basis function φ takes the distance between the interpolation coordinates and the input coordinates as a parameter, and utilizes the influence coefficient λ of each input coordinate point on the eigenvalues, along with the input coordinates and their corresponding eigenvalues. i The solution is performed using the original spatial coordinates of the input points. The interpolation algorithm based on the radial basis function is shown in the following formula:
[0091]
[0092] Among them, |xxi | represents the distance between the interpolated coordinate point and the input coordinate point.
[0093] In solving λ i At that time, the original input coordinate point x i Its corresponding material property value y i Substituting into equation (1), for any point (x) in the original measurement points j ,y j Substituting into equation (1), we get:
[0094]
[0095] Substituting all n coordinate points and their corresponding material property values from the original measuring points, we obtain n equations for the n unknowns λ1, λ2, ... λ. n The influence coefficient is obtained by solving the equation (2), and the material characteristic value y corresponding to the new coordinate x in the refined coordinate of the key area is obtained.
[0096] Alternatively, the radial basis function φ is shown in the following equation:
[0097]
[0098] Where m is the average distance between the original measurement points by default; the radial basis function φ can be quantized by selecting different functions according to the actual situation.
[0099] In this embodiment of the invention, the original spatial coordinates of the original experimental measurement points and the corresponding original material property values, as well as the refined coordinates of the key region, are used as inputs. The material property values corresponding to each coordinate in the key region contour coordinate set are obtained by using an interpolation algorithm based on radial basis functions, thereby giving a continuous spatial distribution of the material properties of the key region.
[0100] Optionally, the steps for visualizing the continuous spatial distribution of material properties in the key region to obtain the visualization results of the neutron scattering diffraction data to be processed include: based on the continuous spatial distribution of material properties in the key region, combined with a preset chromaticity bar, assigning a color corresponding to the material property value to each coordinate point in the key region, and drawing a three-dimensional cloud map of the key region of the sample in the form of scatter points or surfaces, with each material property value corresponding to a color value in the chromaticity bar.
[0101] In this embodiment of the invention, the aforementioned preset chromaticity bar can be understood as a user-defined chromaticity bar style. Each material property value corresponds to a color value in the chromaticity bar.
[0102] Specifically, based on the continuous spatial distribution of material properties in the key areas, combined with the user-defined color bar style, the RGB values of the colors corresponding to each material property value are given. Thus, each spatial coordinate point in the key area contour coordinate set is assigned the color corresponding to the material property value, and a three-dimensional cloud map of the key area of the sample is drawn in the form of scatter points or curved surfaces.
[0103] In this embodiment of the invention, the invention simultaneously displays the continuous spatial distribution of material properties of the original measurement points and the continuous spatial distribution of material properties of key areas after processing by the invention, and allows users to choose whether to display the continuous spatial distribution of material properties of key areas in the overall sample component.
[0104] like Figure 2 As shown, Figure 2 This is a schematic diagram illustrating the operating principle of a neutron scattering diffraction data processing method provided in an embodiment of the present invention. The neutron scattering diffraction data processing method specifically includes: a dataset import module, a key region contour deduction module, a key region material property deduction module, and a three-dimensional cloud map visualization module.
[0105] The dataset import module loads the original experimental measurement data as input data. The input data is the neutron diffraction residual stress experimental data of the sample, and some data are shown in the table below:
[0106] X Y Z S11 S22 S33 S12 S13 S23 Mises 6.1002 0.405 35.58 -23.5 -1.735 -86.95 -5.498 28.27 4.4078 91.864 8.0248 0.927 35.58 -23.05 -1.652 -68.82 -5.474 14.59 0.963 65.343 9.9495 1.448 35.58 -21.52 -1.612 -49.49 -5.414 3.123 -1.27 43.161 11.874 1.969 35.58 -18.56 -1.386 -27.21 -5.058 -4.334 -1.52 25.8 13.798 2.491 35.58 -13.89 -0.786 0.664 -4.089 -6.209 1.0806 19.706 -2.014 -1.906 41.50 231.5 41.07 -103 101.5 75.039 24.539 372.6 0.3663 -1.142 41.506 212.80 40.487 -100.44 97.6883 74.367 23.887 354.15 2.747 -0.379 41.506 180.34 37.779 -97.830 88.202 69.679 22 318.62 -0.419 -0.338 40.02 157.04 15.195 -103.63 49.598 -100.98 -30.769 303.29
[0107] The first three columns represent the spatial coordinates of the sample in the X, Y, and Z directions, respectively, while the last seven columns represent the stress data of different crystal planes of the sample. The dataset import module is responsible for loading the original experimental measurement point data and structuring the first three columns into the original spatial position coordinates, which are then input into the key region contour deduction module and the key region material property deduction module. The last seven columns are structuring the original material properties, which are then input into the key region material property deduction module. Each column of data is indexed using the header file name of the original experimental measurement point data, i.e., each column of data is labeled with X, Y, Z, S11, S22, S33, S12, S13, S23, and Mises, respectively. Users can choose a certain type of stress data from the seven columns for subsequent three-dimensional visualization.
[0108] The aforementioned key area contour derivation module derives the refined coordinates of the key area. Users can set the refined mesh density in three directions in three-dimensional space, such as setting the X direction to nx, the Y direction to ny, and the Z direction to nz.
[0109] If layered inference is not selected, a cube enclosing the original measurement point is interpolated based on the original spatial coordinates, according to the coordinate range of each of its three dimensions and the user-defined three-dimensional grid density. That is, the coordinate range of the original measurement point in the X direction is denoted as [Xmin, Xmax]. Interpolation is performed at equal intervals within this range, forming a total of nx points in the X direction. The coordinate range of the original measurement point in the Y direction is denoted as [Ymin, Ymax]. Interpolation is performed at equal intervals within this range, forming a total of ny points in the Y direction. The coordinate range of the original measurement point in the Z direction is denoted as [Zmin, Zmax]. Interpolation is performed at equal intervals within this range, forming a total of nz points in the Z direction. The newly interpolated points in the three directions intersect to form grid points, finally resulting in a cube containing nx×ny×nz points. The points nx×ny×nz are judged sequentially. If the point is located inside the triangular unit formed by the Delaunay triangulation of the original measuring point (this triangulation is a subdivision in three-dimensional space), then the coordinate point is added to the key area contour coordinate set. Otherwise, the coordinate point is deleted. The key area contour coordinate set is obtained after judging each new coordinate point. At the same time, the key area contour coordinate set should include the spatial position coordinates of the original measuring point.
[0110] If layered derivation is selected, the original spatial coordinates are layered in the X, Y, and Z directions. That is, coordinates with the same coordinate values in the same direction or within the user-defined error range are considered to be in the same layer. Users can customize the layering direction and use the layered coordinate filter to filter the coordinates of each layer, removing coordinate layers with less than 4 coordinates after layering or coordinates that differ only in one dimension. For example, if layering is selected in the X direction, coordinates with the same X coordinate value or within the range of X±Δx belong to the same layer (Δx is the user-defined error range). If the number of coordinates in the layer is less than 4 or the y or z values of all coordinates in the layer are the same, all coordinates in the layer are filtered out. Otherwise, the layer is retained as a filtered coordinate layer and enters the next processing step. The same principle applies to layering in other directions. For the remaining coordinate layers, i.e., the filter coordinate layers, a target rectangle enclosing the filter coordinate layer is interpolated based on the coordinate range of each of the remaining two dimensions and the user-defined 3D mesh density. Then, Delaunay triangulation is performed on each filter coordinate layer. The new coordinates obtained from the interpolation within the target rectangle are judged. If the new coordinates are located inside the triangular units formed after the Delaunay triangulation of the filter coordinate layer, the coordinates are added to the key region contour coordinate set; otherwise, the coordinates are deleted. For example, if layering is selected in the X direction, assuming the range of Y-direction coordinate values for the original coordinate points in a certain filter coordinate layer (X = xx) is denoted as [Ymin, Ymax], interpolation is performed at equal intervals within this range. In the Y direction, a total of ny points are formed. The coordinate values of the original coordinate points in the Z direction are denoted as [Zmin, Zmax]. Interpolation is performed at equal intervals within this range, resulting in a total of nz points in the Z direction. The newly interpolated points in the two directions intersect to form grid points. Finally, a target rectangle containing ny×nz points is obtained at the X=xx position. At the same time, the original coordinate points contained in the filtering coordinate layer are subjected to Delaunay triangulation (this triangulation is a subdivision in two-dimensional space). Then, the ny×nz points in the target rectangle are judged sequentially. If the point is inside the triangular unit formed by the above Delaunay triangulation, the coordinate point is added to the key area contour coordinate set; otherwise, the coordinate point is deleted. After performing this judgment on each new coordinate obtained by each interpolation in each filtering coordinate layer, the key area contour coordinate set is obtained. At the same time, the key area contour coordinate set should include the spatial position coordinates of the original measurement points.
[0111] The aforementioned key region material property deduction module provides a continuous spatial distribution of key region material properties. It takes the original spatial coordinates of the original experimental measurement points and the corresponding original material property values, as well as the refined coordinates of the key region, as inputs. It uses an interpolation algorithm based on radial basis functions to obtain the material property values corresponding to each coordinate in the key region contour coordinate set, thereby providing a continuous spatial distribution of key region material properties.
[0112] The radial basis function φ takes the distance between the interpolation coordinates and the input coordinates as a parameter, and utilizes the influence coefficient λ of each input coordinate point on the eigenvalues, along with the input coordinates and their corresponding eigenvalues. i Solve the problem.
[0113] As shown in the formula:
[0114]
[0115] |xx i The values | and φ can be quantized using different functions depending on the specific situation, such as the distance between coordinate points in this example |xx. i Using the Euclidean distance method, the radial basis function φ is obtained by using a higher-order surface interpolation function, as shown in the equation:
[0116]
[0117] Where m is the average distance between the original measurement points by default.
[0118] In solving λ i At that time, the original input coordinate point x i Its corresponding material property value y i Substitute into Equation 1, for any point (x) in the original input points j ,y j Substituting into equation (4), we get:
[0119]
[0120] Substituting all n coordinate points and their corresponding material property values from the original experimental measurement points into equation (4), we obtain n equations, which can then be used to determine the n unknowns λ1, λ2, ..., λ3. n The influence coefficient is obtained by solving the equation, and thus the material property value y corresponding to the new interpolation coordinate point x is obtained.
[0121] The aforementioned 3D cloud visualization module draws a 3D cloud map of the key area of the sample. Based on the deduced continuous spatial distribution of the material properties of the key area, combined with the user-defined color bar style, it provides the RGB values of the colors corresponding to each material property value. Thus, it assigns the color of the corresponding material property value to each spatial coordinate point in the key area contour coordinate set, and draws the 3D cloud map of the key area of the sample in the form of scattered points or curved surfaces. This module will simultaneously display the continuous spatial distribution of the material properties of the original measurement points and the continuous spatial distribution of the material properties of the key area after processing by the above method, and select whether to display the continuous spatial distribution of the material properties of the key area in the overall sample component according to the user definition.
[0122] Figure 3This is a three-dimensional cloud map of material properties in an embodiment of the present invention that does not use the original measurement points of the present invention. Specifically, by combining the experimental setup, instrument and sample layout with the sample internal structure and motion information obtained from the analysis of neutron scattering diffraction experimental data, the law of material property evolution with sample sites can be obtained. However, due to limitations such as equipment accuracy and experimental time, the sample measurement points obtained directly from the experiment are limited, which makes it impossible to comprehensively and accurately characterize the changes in material properties in the sample measurement area, and the evolution law is difficult to express intuitively and explicitly. Figure 4 This invention provides a continuous three-dimensional cloud map of the material properties of key areas after processing by the present invention. Specifically, based on the deduced continuous spatial distribution of the material properties of key areas, combined with a user-defined color bar style, the RGB values of the colors corresponding to each material property value are given. Thus, each spatial coordinate point in the key area contour coordinate set is assigned the color corresponding to the material property value. The three-dimensional cloud map of the key area of the sample is drawn in the form of scatter points or curved surfaces. The present invention will simultaneously display the continuous spatial distribution of the material properties of the original measurement points and the continuous spatial distribution of the material properties of the key areas after processing by the present invention. According to the user definition, it can choose whether to display the continuous spatial distribution of the material properties of the key areas in the overall sample component. The present invention can deduce the material properties corresponding to other unmeasured points in the sample measurement area from the experimental results of the random and sparse sample measurement points, thereby comprehensively and intuitively characterizing the distribution of material properties in the key area of the sample.
[0123] In this embodiment of the invention, key regions can be deduced using either the first or second deduction mode to determine the refined coordinates of the key regions. Based on the original spatial distribution of material properties and the refined coordinates of the key regions, the continuous spatial distribution of material properties in the key regions can be determined. This allows for visualization of the continuous spatial distribution of material properties in the key regions, resulting in the visualization of the neutron diffraction data. This solves the problem that existing methods are limited by factors such as equipment precision and experimental time, resulting in a limited number of sample measurement points obtained directly from experiments. This makes it impossible to comprehensively and accurately characterize the changes in material properties in the sample measurement area, and the evolution law is difficult to express intuitively and explicitly. This fills the measurement gap in the middle region of discrete measurement points caused by limitations in equipment precision and experimental time.
[0124] In this embodiment of the invention, the invention maximizes the use of the limited experimental measurement points obtained from neutron scattering diffraction experiments, solves the problem that the original discrete data is not obvious or comprehensive in characterizing the evolution of material properties, and intuitively and clearly shows the distribution and changes of material properties in key areas in continuous space. It fills the measurement gap in the middle area of discrete measurement points caused by the limitations of equipment accuracy and experimental time, and provides strong support for basic materials research and engineering design.
[0125] like Figure 5 As shown, Figure 5 This is a schematic diagram of a neutron dispersion diffraction data processing device provided in an embodiment of the present invention. The neutron dispersion diffraction data processing device includes:
[0126] The acquisition module 501 is used to acquire neutron scattering diffraction data to be processed. The neutron scattering diffraction data to be processed includes the original material property spatial distribution of each original measurement point. The original material property spatial distribution should include the original spatial position coordinates of the original measurement point and the corresponding original material property value.
[0127] The first determining module 502 is used to perform key region deduction on the neutron scattering diffraction data to be processed through a first deduction mode or a second deduction mode, and determine the refined coordinates of the key region. The refined coordinates of the key region include the original spatial position coordinates of the measurement points in the key region.
[0128] The second determining module 503 is used to determine the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region.
[0129] The processing module 504 is used to visualize the continuous spatial distribution of material properties in the key region to obtain the visualization processing result of the neutron scattering diffraction data to be processed.
[0130] Optionally, the first determining module 502 is further configured to:
[0131] When the user selects the first simulation mode, the key region simulation is performed on the neutron scattering diffraction data to be processed through the first simulation mode to determine the refined coordinates of the key region.
[0132] When the user selects the second simulation mode, the key region simulation is performed on the neutron scattering diffraction data to be processed through the second simulation mode to determine the refined coordinates of the key region.
[0133] Optionally, the first determining module 502 is further configured to:
[0134] Based on the original spatial coordinates, and according to the coordinate range of each of its three dimensions and the user-defined three-dimensional grid density, a target cube that encloses all the original measurement points is interpolated.
[0135] The original spatial coordinates are triangulated by Delaunay triangulation to form a set of connected but non-overlapping Delaunay triangles, i.e., Delaunay triangulation network. Moreover, the circumcircle of each Delaunay triangle does not contain any other original measurement point in the region where the Delaunay triangle is located, i.e., any four points in the original measurement points cannot be on the same circle.
[0136] Judge the newly interpolated coordinates in the target cube. If the newly interpolated coordinates are inside the Delaunay triangulation, add the newly interpolated coordinates to the key area contour coordinate set. Otherwise, delete the newly interpolated coordinates. After judging each of the newly interpolated coordinates, obtain the key area contour coordinate set, and the key area contour coordinate set should include the original measurement point spatial position coordinates;
[0137] Obtain the refined coordinates of the key area based on the original measurement point spatial position coordinates.
[0138] Optionally, the first determination module 502 is further configured to:
[0139] Based on the original spatial position coordinates, layer the original spatial position coordinates in the X, Y, and Z directions to obtain multiple original coordinate layers. In the same direction, coordinate points with the same coordinate value or within the user-defined error range in the dimension of the layering direction are regarded as the same layer, and each coordinate point corresponds to an original measurement point;
[0140] Use a layer coordinate filter to screen the coordinate points of each layer, remove the original coordinate layers with the number of coordinate points <m after layering and the original coordinate layers with differences only in one dimension after layering, and obtain the filtered coordinate layers;
[0141] For each of the filtered coordinate layers, respectively interpolate a target rectangle that encloses the filtered coordinate layer according to the coordinate ranges of the remaining two dimensions and the preset three-dimensional grid density;
[0142] Perform Delaunay triangulation on each of the filtered coordinate layers to form a set of a series of connected but non-overlapping Delaunay triangles, that is, the Delaunay triangulation network, and there is no other original measurement point in the circumcircle of each Delaunay triangle, that is, any four points among the original measurement points cannot be concyclic;
[0143] Judge the newly interpolated coordinates in the target rectangle. If the newly interpolated coordinates are inside the Delaunay triangulation network, add the newly interpolated coordinates to the key area contour coordinate set. Otherwise, delete the newly interpolated coordinates. After judging each of the newly interpolated coordinates in each of the filtered coordinate layers, obtain the key area contour coordinate set, and the key area contour coordinate set should include the original measurement point spatial position coordinates;
[0144] Obtain the refined coordinates of the key area based on the original measurement point spatial position coordinates.
[0145] Optionally, the second determination module 503 is further configured to:
[0146] Based on the original spatial distribution of material properties and the refined coordinates of the key region, the material eigenvalues are calculated using an interpolation algorithm based on radial basis functions to obtain the continuous spatial distribution of material properties in the key region.
[0147] Optionally, the second determining module 503 is further configured to:
[0148] The radial basis function φ takes the distance between the interpolation coordinate point and the input coordinate point as a parameter, and utilizes the influence coefficient λ of each input coordinate point on the eigenvalues based on the input coordinate points and their corresponding eigenvalues. i The solution is performed using the original spatial position coordinates of the input coordinates. The interpolation algorithm based on the radial basis function is shown in the following formula:
[0149]
[0150] Among them, |xx i | represents the distance between the interpolated coordinate point and the input coordinate point;
[0151] In solving λ i At that time, the original input coordinate point x i Its corresponding material property value y i Substituting into equation (1), for any point (x) in the original measurement points j ,y j Substituting into equation (1), we get:
[0152]
[0153] Substituting all n coordinate points and their corresponding material property values from the original measuring points, we obtain n equations for the n unknowns λ1, λ2, ... λ. n The influence coefficient is obtained by solving the equation (2), and the material characteristic value y corresponding to the new coordinate x in the refined coordinate of the key area is obtained.
[0154] Alternatively, the radial basis function φ is shown in the following equation:
[0155]
[0156] Where m is the average distance between the original measurement points by default.
[0157] Optionally, the processing module 504 is further configured to:
[0158] Based on the continuous spatial distribution of material properties in the key area, and combined with a preset color bar, each coordinate point in the key area is assigned a color corresponding to the material property value. A three-dimensional cloud map of the key area of the sample is drawn in the form of a scatter plot or a surface, and each material property value corresponds to a color value in the color bar.
[0159] The neutron scattering diffraction data processing apparatus provided in this embodiment of the invention can implement all the processes implemented by the neutron scattering diffraction data processing method in the above-described method embodiments, and can achieve the same beneficial effects. To avoid repetition, further details are omitted here.
[0160] See Figure 6 , Figure 6 This is a schematic diagram of the structure of an electronic device provided in an embodiment of the present invention, such as... Figure 6 As shown, it includes: a memory 602, a processor 601, and a computer program for a neutron dispersion diffraction data processing method stored in the memory 602 and executable on the processor 601, wherein:
[0161] The processor 601 is used to call the computer program stored in the memory 602 and perform the following steps:
[0162] Acquire neutron scattering diffraction data to be processed, wherein the neutron scattering diffraction data to be processed includes the original material property spatial distribution of each original measurement point, wherein the original material property spatial distribution includes the original spatial position coordinates of the original measurement point and the corresponding original material property value;
[0163] The key region of the neutron scattering diffraction data to be processed is deduced by using either the first or the second deduction mode, and the refined coordinates of the key region are determined. The refined coordinates of the key region include the original spatial coordinates of the measurement points in the key region.
[0164] Based on the original spatial distribution of material properties and the refined coordinates of the key region, the continuous spatial distribution of material properties in the key region is determined;
[0165] The continuous spatial distribution of material properties in the key region is visualized to obtain the visualization results of the neutron scattering diffraction data to be processed.
[0166] Optionally, the timeliness of the first deduction mode is higher than that of the second deduction mode, and the accuracy of the first deduction mode is lower than that of the second deduction mode. The step executed by the processor 601 to perform key region deduction on the neutron scattering diffraction data to be processed through the first deduction mode or the second deduction mode to determine the refined coordinates of the key region includes:
[0167] When the user selects the first simulation mode, the key region simulation is performed on the neutron scattering diffraction data to be processed through the first simulation mode to determine the refined coordinates of the key region.
[0168] When the user selects the second deduction mode, the key area of the to-be-processed neutron diffraction data is deduced through the second deduction mode, and the refined coordinates of the key area are determined.
[0169] Optionally, the steps of the processor 601 executing the deduction of the key area of the to-be-processed neutron diffraction data through the first deduction mode to determine the refined coordinates of the key area include:
[0170] Based on the original spatial position coordinates, according to the coordinate ranges of its three dimensions and the three-dimensional grid density defined by the user, interpolate a target cube that encloses all the original measurement points;
[0171] Perform Delaunay triangulation on the original spatial position coordinates to form a set of a series of connected but non-overlapping Delaunay triangles, that is, a Delaunay triangulation network, and no other original measurement points in the plane area where each Delaunay triangle is located are included in the circumcircle of the Delaunay triangle, that is, any four points among the original measurement points cannot be concyclic;
[0172] Judge the newly interpolated coordinates in the target cube. If the newly interpolated coordinates are inside the Delaunay triangulation network, add the newly interpolated coordinates to the set of key area contour coordinates, otherwise delete the newly interpolated coordinates. After judging each newly interpolated coordinate, a set of key area contour coordinates is obtained, and the set of key area contour coordinates should include the spatial position coordinates of the original measurement points;
[0173] Obtain the refined coordinates of the key area based on the spatial position coordinates of the original measurement points.
[0174] Optionally, the steps of the processor 601 executing the deduction of the key area of the to-be-processed neutron diffraction data through the second deduction mode to determine the refined coordinates of the key area include:
[0175] Based on the original spatial position coordinates, layer the original spatial position coordinates in the X, Y, and Z directions to obtain multiple original coordinate layers. In the same direction, coordinate points with the same coordinate value or within the error range defined by the user in the dimension of the layering direction are regarded as the same layer, and each coordinate point corresponds to an original measurement point;
[0176] Use a layer coordinate filter to screen the coordinate points of each layer, remove the original coordinate layers with the number of coordinate points <m after layering and the original coordinate layers with differences only in one dimension after layering, and obtain filtered coordinate layers;
[0177] For each of the filter coordinate layers, a target rectangle that encloses the filter coordinate layer is interpolated based on the coordinate range of the remaining two dimensions and the preset three-dimensional grid density.
[0178] Each of the filtering coordinate layers is triangulated using Delaunay triangulation to form a set of connected but non-overlapping Delaunay triangles, i.e., a Delaunay triangulation network. Moreover, the circumcircle of each Delaunay triangle does not contain any other original measurement point in the region where the Delaunay triangle is located, i.e., any four points in the original measurement points cannot be on the same circle.
[0179] The new coordinates obtained by interpolation in the target rectangle are judged. If the new coordinates obtained by interpolation are inside the Deloitte triangulation, the new coordinates obtained by interpolation are added to the key area contour coordinate set; otherwise, the new coordinates obtained by interpolation are deleted. After judging each new coordinate obtained by interpolation in each of the filter coordinate layers, the key area contour coordinate set is obtained. The key area contour coordinate set should include the spatial position coordinates of the original measurement point.
[0180] The refined coordinates of the key area are obtained based on the original spatial coordinates of the measuring points.
[0181] Optionally, the step of determining the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region, performed by the processor 601, includes:
[0182] Based on the original spatial distribution of material properties and the refined coordinates of the key region, the material eigenvalues are calculated using an interpolation algorithm based on radial basis functions to obtain the continuous spatial distribution of material properties in the key region.
[0183] Optionally, the step executed by processor 601 of calculating material eigenvalues based on the original spatial distribution of material properties and the refined coordinates of the key region, using an interpolation algorithm based on radial basis functions, to obtain the continuous spatial distribution of material properties in the key region includes:
[0184] The radial basis function φ takes the distance between the interpolation coordinate point and the input coordinate point as a parameter, and utilizes the influence coefficient λ of each input coordinate point on the eigenvalues based on the input coordinate points and their corresponding eigenvalues. i The solution is performed using the original spatial position coordinates of the input coordinates. The interpolation algorithm based on the radial basis function is shown in the following formula:
[0185]
[0186] Among them, |xx i | represents the distance between the interpolated coordinate point and the input coordinate point;
[0187] In solving λ i At that time, the original input coordinate point x i Its corresponding material property value y i Substituting into equation (1), for any point (x) in the original measurement points j ,y j Substituting into equation (1), we get:
[0188]
[0189] Substituting all n coordinate points and their corresponding material property values from the original measuring points, we obtain n equations for the n unknowns λ1, λ2, ... λ. n The influence coefficient is obtained by solving the equation (2), and the material characteristic value y corresponding to the new coordinate x in the refined coordinate of the key area is obtained.
[0190] Alternatively, the radial basis function φ is shown in the following equation:
[0191]
[0192] Where m is the average distance between the original measurement points by default.
[0193] Optionally, the step of visualizing the continuous spatial distribution of material properties in the key region to obtain the visualization result of the neutron scattering diffraction data to be processed, performed by the processor 601, includes:
[0194] Based on the continuous spatial distribution of material properties in the key area, and combined with a preset color bar, each coordinate point in the key area is assigned a color corresponding to the material property value. A three-dimensional cloud map of the key area of the sample is drawn in the form of a scatter plot or a surface, and each material property value corresponds to a color value in the color bar.
[0195] The electronic device provided in this embodiment of the invention can implement all the processes implemented by the neutron dispersion diffraction data processing method in the above-described method embodiments, and can achieve the same beneficial effects. To avoid repetition, further details are omitted here. This embodiment of the invention also provides a computer-readable storage medium storing a computer program. When executed by a processor, this computer program can implement all the processes implemented by the neutron dispersion diffraction data processing method in the above-described method embodiments, and can achieve the same technical effects. To avoid repetition, further details are omitted here.
[0196] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a computer-readable storage medium, and when executed, it can implement the processes of the embodiments of the above methods. The computer-readable storage medium can be a magnetic disk, optical disk, read-only memory (ROM), or random access memory (RAM), etc.
[0197] The above description discloses only preferred embodiments of the present invention and should not be construed as limiting the scope of the present invention. Therefore, equivalent variations made in accordance with the claims of the present invention are still within the scope of the present invention.
Claims
1. A method for processing neutron scattering diffraction data, characterized in that, The neutron scattering diffraction data processing method includes: Acquire neutron scattering diffraction data to be processed, wherein the neutron scattering diffraction data to be processed includes the original material property spatial distribution of each original measurement point, wherein the original material property spatial distribution includes the original spatial position coordinates of the original measurement point and the corresponding original material property value; The key region of the neutron scattering diffraction data to be processed is deduced by using either the first or the second deduction mode, and the refined coordinates of the key region are determined. The refined coordinates of the key region include the original spatial coordinates of the measurement points in the key region. Based on the original spatial distribution of material properties and the refined coordinates of the key region, the continuous spatial distribution of material properties in the key region is determined; The continuous spatial distribution of material properties in the key region is visualized to obtain the visualization results of the neutron scattering diffraction data to be processed. The first deduction mode has a higher deduction timeliness than the second deduction mode, but the first deduction mode has a lower deduction accuracy than the second deduction mode. The step of performing key region deduction on the neutron scattering diffraction data to be processed using the first or second deduction mode to determine the refined coordinates of the key region includes: When the user selects the first simulation mode, the key region simulation is performed on the neutron scattering diffraction data to be processed through the first simulation mode to determine the refined coordinates of the key region. When the user selects the second simulation mode, the key region simulation is performed on the neutron scattering diffraction data to be processed through the second simulation mode to determine the refined coordinates of the key region.
2. The neutron scattering diffraction data processing method as described in claim 1, characterized in that, The step of performing key region extrapolation on the neutron scattering diffraction data to be processed using the first extrapolation mode to determine the refined coordinates of the key region includes: Based on the original spatial coordinates, and according to the coordinate range of each of its three dimensions and the user-defined three-dimensional grid density, a target cube that encloses all the original measurement points is interpolated. The original spatial coordinates are triangulated by Delaunay triangulation to form a set of connected but non-overlapping Delaunay triangles, i.e., Delaunay triangulation network. Moreover, the circumcircle of each Delaunay triangle does not contain any other original measurement point in the region where the Delaunay triangle is located, i.e., any four points in the original measurement points cannot be on the same circle. The new coordinates obtained by interpolation in the target cube are judged. If the new coordinates obtained by interpolation are inside the Deloitte triangulation, the new coordinates obtained by interpolation are added to the key area contour coordinate set; otherwise, the new coordinates obtained by interpolation are deleted. After judging each new coordinate obtained by interpolation, the key area contour coordinate set is obtained. The key area contour coordinate set should include the original measurement point spatial position coordinates. The refined coordinates of the key area are obtained based on the original spatial coordinates of the measuring points.
3. The neutron scattering diffraction data processing method as described in claim 2, characterized in that, The step of performing key region extrapolation on the neutron scattering diffraction data to be processed using the second extrapolation mode to determine the refined coordinates of the key region includes: Based on the original spatial position coordinates, layer the original spatial position coordinates in three directions of X, Y, and Z to obtain multiple original coordinate layers. In the same direction, coordinate points with the same coordinate values or within the user-defined error range in the dimension of the layering direction are regarded as the same layer, and each coordinate point corresponds to an original measurement point; Use a layer coordinate filter to screen the coordinate points of each layer, remove the original coordinate layers with the number of coordinate points <m after layering and the original coordinate layers with differences only in one dimension after layering, and obtain filtered coordinate layers; For each of the filtered coordinate layers, respectively interpolate a target rectangle that encloses the filtered coordinate layer according to the coordinate ranges of the remaining two dimensions and the preset three-dimensional grid density; Perform Delaunay triangulation on each of the filtered coordinate layers to form a set of a series of connected but non-overlapping Delaunay triangles, that is, a Delaunay triangulation network, and there is no other original measurement point in the circumcircle of each Delaunay triangle in the region where the Delaunay triangle is located, that is, any four points among the original measurement points cannot be concyclic; Judge the newly interpolated coordinates in the target rectangle. If the newly interpolated coordinates are inside the Delaunay triangulation network, the newly interpolated coordinates are newly added to the set of key area contour coordinates, otherwise the newly interpolated coordinates are deleted. After judging each of the newly interpolated coordinates in each of the filtered coordinate layers, a set of key area contour coordinates is obtained, and the set of key area contour coordinates should include the spatial position coordinates of the original measurement points; Obtain the refined coordinates of the key area based on the spatial position coordinates of the original measurement points.
4. The neutron scattering diffraction data processing method as described in claim 1, characterized in that, The step of determining the continuous spatial distribution of the material properties in the key area based on the spatial distribution of the original material properties and the refined coordinates of the key area includes: Based on the spatial distribution of the original material properties and the refined coordinates of the key area, use an interpolation algorithm based on radial basis functions to calculate the material characteristic values, and obtain the continuous spatial distribution of the material properties in the key area.
5. The neutron scattering diffraction data processing method as described in claim 4, characterized in that, The step of based on the spatial distribution of the original material properties and the refined coordinates of the key area, using an interpolation algorithm based on radial basis functions to calculate the material characteristic values, and obtaining the continuous spatial distribution of the material properties in the key area includes: The radial basis function φ takes the distance between the interpolation coordinate point and the input coordinate point as a parameter, and utilizes the influence coefficient λ of each input coordinate point on the eigenvalues based on the input coordinate points and their corresponding eigenvalues. i The solution is performed using the original spatial coordinates of the input coordinates. The interpolation algorithm based on the radial basis function is shown in the following formula: Among them, |xx i | represents the distance between the interpolated coordinate point and the input coordinate point; In solving λ i At that time, the original input coordinate point x i Its corresponding material property value y i Substituting into equation (1), for any point (x) in the original measurement points j ,y j Substituting into equation (1), we get: Substituting all n coordinate points and their corresponding material property values from the original measuring points, we obtain n equations for the n unknowns λ1, λ2, ... λ. n The influence coefficient is obtained by solving the equation (2), and the material characteristic value y corresponding to the new coordinate x in the refined coordinate of the key area is obtained.
6. The neutron scattering diffraction data processing method as described in claim 5, characterized in that, The radial basis function φ is shown as the following formula: where m is defaulted to the average value of the distances between the original measurement points.
7. The neutron scattering diffraction data processing method according to any one of claims 1 to 6, characterized in that, The step of performing visualization processing on the continuous spatial distribution of the material properties in the key area to obtain the visualization processing result of the to-be-processed neutron scattering diffraction data includes: According to the continuous spatial distribution of the material properties in the key area, combined with the preset chromaticity bar, assign the color corresponding to the material property value to each coordinate point in the key area, and draw a three-dimensional cloud map of the key area of the sample in the form of scatter points or surfaces, and each material property value corresponds to a color value in the chromaticity bar.
8. A neutron dispersion diffraction data processing apparatus employing the neutron dispersion diffraction data processing method according to any one of claims 1 to 7, characterized in that, The neutron scattering diffraction data processing device includes: The acquisition module is used to acquire neutron scatter diffraction data to be processed. The neutron scatter diffraction data to be processed includes the original material property spatial distribution of each original measurement point. The original material property spatial distribution includes the original spatial position coordinates of the original measurement point and the corresponding original material property value. The first determining module is used to perform key region deduction on the neutron scattering diffraction data to be processed through a first deduction mode or a second deduction mode, and determine the refined coordinates of the key region. The refined coordinates of the key region include the original spatial position coordinates of the measurement points in the key region. The second determining module is used to determine the continuous spatial distribution of material properties in the key region based on the original spatial distribution of material properties and the refined coordinates of the key region; The processing module is used to visualize the continuous spatial distribution of material properties in the key region to obtain the visualization results of the neutron scattering diffraction data to be processed.
9. An electronic device, characterized in that, include: A memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the steps of the neutron scattering diffraction data processing method as described in any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the steps of the neutron dispersion diffraction data processing method as described in any one of claims 1 to 7.