Space curve calculation result mapping method of multi-physics field numerical calculation software

By obtaining line points on the spatial curve in the multi-physics numerical calculation software, calculating the arc length value and result value, and performing two-dimensional mapping processing, the problem of low visualization efficiency of spatial curves in traditional technology is solved, and more efficient and accurate visualization effects are achieved.

CN119989444AActive Publication Date: 2025-05-13ELECTRIC POWER RES INST CHINA SOUTHERN POWER GRID CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202510460651.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-14
Publication Date
2025-05-13
Estimated Expiration
2045-04-14

AI Technical Summary

Technical Problem

When traditional multi-physics numerical calculation software processes spatial curves, the visualization processing time of three-dimensional model data is longer, resulting in low visualization efficiency.

Method used

By obtaining multiple line points on the spatial curve, the arc length value of each line point to the initial point of the curve is calculated, and the result value of each line point is determined according to the grid cell, and a two-dimensional mapping process is performed to obtain the target mapping result of the spatial curve.

Benefits of technology

It effectively improves the visual efficiency and accuracy of spatial curve processing results and reduces the visual processing time.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119989444A_ABST
    Figure CN119989444A_ABST
Patent Text Reader

Abstract

The invention relates to a space curve calculation result mapping method and device of multi-physics field numerical calculation software, computer equipment, a storage medium and a computer program product. The method comprises the following steps: acquiring a space curve picked up in multi-physics field numerical calculation software, and arranging a plurality of line points on the space curve; determining a curve initial point from the end points of the space curve, and obtaining an arc length value from each line point to the curve initial point; according to a target grid unit to which each line point belongs in grid units in the multi-physical field numerical calculation software, determining a result value of each line point; and performing two-dimensional mapping processing on the arc length value and the result value to obtain a target mapping result of the space curve. By adopting the method, the visualization efficiency and accuracy of the processing result of the space curve can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to a method, device, computer equipment, storage medium and computer program product for mapping spatial curve calculation results of multi-physics field numerical calculation software. Background Art

[0002] At present, multi-physics field computing technology is an effective means to improve product quality, shorten design cycle, and enhance product competitiveness. It has broad application prospects and industrial value in helping the industrial manufacturing industry achieve a higher level of intelligent transformation and optimizing the maintenance strategies of aerospace equipment.

[0003] In traditional technology, the processing results of space curves by multi-physics field numerical calculation software usually display three-dimensional model data, which requires a long visualization processing time, resulting in low visualization efficiency of the processing results of space curves. Summary of the invention

[0004] Based on this, it is necessary to provide a spatial curve calculation result mapping method, device, computer equipment, computer-readable storage medium and computer program product for multi-physics field numerical calculation software that can improve the visualization effect of spatial curve processing results in response to the above technical problems.

[0005] In a first aspect, the present application provides a method for mapping spatial curve calculation results of multi-physics field numerical calculation software. The method comprises:

[0006] Obtaining a space curve picked up in multi-physics field numerical calculation software, and arranging a plurality of line points on the space curve;

[0007] Determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve;

[0008] Determine the result value of each of the line points according to the target grid unit to which each of the line points belongs in the grid unit of the multi-physics field numerical calculation software;

[0009] A two-dimensional mapping process is performed on the arc length value and the result value to obtain a target mapping result of the space curve.

[0010] In one embodiment, obtaining a space curve picked up in a multi-physics field numerical calculation software includes:

[0011] In response to a selection operation triggered by a spatial scene in the multi-physics field numerical calculation software, obtaining position coordinates corresponding to the selection operation;

[0012] Convert the position coordinates into rays in a world coordinate system, and determine the intersection points of the rays with all curves in the space scene through ray tracing;

[0013] Filtering out the target intersection point closest to the ray from the intersection points;

[0014] The curve where the target intersection point is located is used as the picked space curve.

[0015] In one of the embodiments, in the grid unit according to the multi-physics field numerical calculation software, before determining the result value of each of the line points in the target grid unit to which each of the line points belongs, the method further comprises:

[0016] Obtaining grid information in the multi-physics field numerical calculation software; the grid information includes unit information;

[0017] According to the unit information, a grid unit in the multi-physics field numerical calculation software is obtained;

[0018] In the grid unit, a target grid unit to which each of the line points belongs is determined.

[0019] In one embodiment, determining the result value of each line point according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software comprises:

[0020] Obtaining a shape function corresponding to a target grid unit to which each of the line points belongs;

[0021] The shape function is used to interpolate the cell result value corresponding to the target grid cell to which each of the line points belongs, so as to obtain the result value of each of the line points.

[0022] In one embodiment, performing two-dimensional mapping processing on the arc length value and the result value to obtain a target mapping result of the space curve includes:

[0023] Using the arc length value from each line point to the initial point of the curve as the abscissa, and using the result value of each line point as the ordinate, a two-dimensional scatter plot of the arc length value and the result value is drawn;

[0024] According to the two-dimensional scatter plot, a target mapping result of the space curve is obtained.

[0025] In one of the embodiments, arranging a plurality of line points on the space curve comprises:

[0026] Determine the first line point and the last line point on the space curve;

[0027] A plurality of line points on the space curve are obtained according to the first line point, the last line point and a preset number of line points.

[0028] In a second aspect, the present application also provides a spatial curve calculation result mapping device of a multi-physics field numerical calculation software. The device comprises:

[0029] A line point acquisition module is used to acquire a space curve picked up in the multi-physics field numerical calculation software, and arrange a plurality of line points on the space curve;

[0030] An arc length value acquisition module, used to determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve;

[0031] A result value acquisition module, used for determining the result value of each line point according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software;

[0032] A mapping processing module is used to perform two-dimensional mapping processing on the arc length value and the result value to obtain a target mapping result of the space curve.

[0033] In a third aspect, the present application further provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:

[0034] Obtaining a space curve picked up in multi-physics field numerical calculation software, and arranging a plurality of line points on the space curve;

[0035] Determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve;

[0036] Determine the result value of each of the line points according to the target grid unit to which each of the line points belongs in the grid unit of the multi-physics field numerical calculation software;

[0037] A two-dimensional mapping process is performed on the arc length value and the result value to obtain a target mapping result of the space curve.

[0038] In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the following steps are implemented:

[0039] Obtaining a space curve picked up in multi-physics field numerical calculation software, and arranging a plurality of line points on the space curve;

[0040] Determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve;

[0041] Determine the result value of each of the line points according to the target grid unit to which each of the line points belongs in the grid unit of the multi-physics field numerical calculation software;

[0042] A two-dimensional mapping process is performed on the arc length value and the result value to obtain a target mapping result of the space curve.

[0043] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:

[0044] Obtaining a space curve picked up in multi-physics field numerical calculation software, and arranging a plurality of line points on the space curve;

[0045] Determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve;

[0046] Determine the result value of each of the line points according to the target grid unit to which each of the line points belongs in the grid unit of the multi-physics field numerical calculation software;

[0047] A two-dimensional mapping process is performed on the arc length value and the result value to obtain a target mapping result of the space curve.

[0048] The spatial curve calculation result mapping method, device, computer equipment, storage medium and computer program product of the multi-physics field numerical calculation software obtain the spatial curve picked up in the multi-physics field numerical calculation software, arrange multiple line points on the spatial curve; determine the initial point of the curve from the endpoint of the spatial curve, and obtain the arc length value from each line point to the initial point of the curve; determine the result value of each line point according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software; perform two-dimensional mapping processing on the arc length value and the result value to obtain the target mapping result of the spatial curve. This method is used to realize the mapping of the processing results of any spatial curve picked up in the multi-physics field numerical calculation software, effectively improving the visualization efficiency and accuracy of the processing results of the spatial curve. BRIEF DESCRIPTION OF THE DRAWINGS

[0049] Figure 1 A schematic flow chart of a method for mapping spatial curve calculation results of multi-physics field numerical calculation software in one embodiment;

[0050] Figure 2 A schematic diagram of a flow chart of a step of determining a target grid unit to which each line point belongs in an embodiment;

[0051] Figure 3 A schematic diagram of the coordinate representation of the triangle area of ​​the midline point in one embodiment;

[0052] Figure 4 A schematic diagram of a two-dimensional scatter plot drawn according to arc length values ​​and result values ​​in one embodiment;

[0053] Figure 5 is a schematic diagram of a connected two-dimensional scatter plot in one embodiment;

[0054] Figure 6 A schematic flow chart of a method for mapping spatial curve calculation results of multi-physics field numerical calculation software in another embodiment;

[0055] Figure 7 A schematic flow chart of a method for mapping spatial curve calculation results of multi-physics field numerical calculation software in yet another embodiment;

[0056] Figure 8 It is a structural block diagram of a spatial curve calculation result mapping device of multi-physics field numerical calculation software in one embodiment;

[0057] Fig. 9 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION

[0058] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.

[0059] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.

[0060] In one embodiment, Figure 1 As shown, a method for mapping the spatial curve calculation results of multi-physics field numerical calculation software is provided. This embodiment uses the method applied to a terminal as an example. It can be understood that the method can also be applied to a server, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:

[0061] Step S101, obtaining a space curve picked up in multi-physics field numerical calculation software, and arranging a plurality of line points on the space curve.

[0062] Among them, the multi-physics field numerical calculation software can be finite element simulation software. Finite element simulation software (FEA, Finite Element Analysis) is a computer-aided engineering (CAE) software based on the finite element method, which is used to simulate and analyze various engineering problems. Finite element simulation discretizes complex physical systems into multiple small units (i.e., finite elements), and each unit is approximately solved through a mathematical model, thereby realizing the analysis and prediction of the entire system.

[0063] Picking a space curve means selecting and defining a curve that moves continuously in three-dimensional space in multi-physics numerical calculation software. This curve can be of any shape as long as it changes continuously in three-dimensional space.

[0064] Among them, a line point refers to a specific point on a space curve (or space point).

[0065] Specifically, in software development, picking up space curves usually involves graphical user interfaces (GUIs) and three-dimensional graphics processing technology. In multi-physics numerical computing software, the geometry engine can save and render space curves in the form of parametric equations, such as Bezier curves, B-spline curves, etc.; graphics rendering generally uses graphics APIs such as OpenGL, DirectX, and Vulkan to render three-dimensional graphics. In a multi-physics numerical computing software that includes a geometry engine, users can select space curves by clicking the mouse, and the terminal uses the space curve selected by the user in the multi-physics numerical computing software as the picked space curve.

[0066] Furthermore, it is generally known that a line is composed of countless points. When analyzing the distribution of result values ​​on a space curve, the result value analysis on the space curve is generally simplified to the result value analysis of several points. Therefore, it is necessary to arrange points on the space curve. Multiple line points can be arranged on the space curve through the parameter equation of the space curve.

[0067] Step S102, determining the initial point of the curve from the endpoints of the space curve, and obtaining the arc length value from each line point to the initial point of the curve.

[0068] The initial point of the curve refers to the point where the space curve starts in three-dimensional space. The initial point of the curve is usually an important reference point for determining the shape and direction of the space curve. The arc length value refers to the length of the curve from the initial point of the space curve to the specified line point along the space curve.

[0069] Specifically, the terminal can specify one of the endpoints of the space curve as the initial point of the curve, or obtain the initial point of the curve specified by the user for the picked space curve. For example, the coordinate at t=a can be defined as the initial point of the space curve, then the initial point of the curve The calculation method of is as follows:

[0070]

[0071] The arc length l from the i-th line point to the initial point of the curve can be calculated by integration: i , such as the integral formula shown below:

[0072]

[0073] In addition to the above integral formula, the common numerical integration method can also be used to calculate the arc length l from the i-th line point to the initial point of the curve i , such as trapezoidal method, Simpson's rule, Boolean rule, Gauss-Legendre formula, etc. Taking Gauss-Legendre method as an example, the four-point Gauss-Legendre formula is used to calculate the arc length l i The process is as follows:

[0074]

[0075] In the formula, j represents the index variable in the summation; the value range of j is 1 to 4, that is, j=1,2,3,4.

[0076] in:

[0077]

[0078]

[0079]

[0080]

[0081]

[0082]

[0083]

[0084] The terminal calculates the arc length from each line point to the initial point of the curve in turn.

[0085] Step S103, determining the result value of each line point according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software.

[0086] The result value of a line point refers to the numerical result of a physical quantity obtained through multi-physics field calculation at a specific position (i.e., line point). For example, the result value can be the numerical result of a physical quantity such as displacement, velocity, stress, or temperature.

[0087] Here, a line point belonging to a certain target grid unit means that the line point is within the target grid unit.

[0088] Specifically, the terminal can first read the grid data in the multi-physics field numerical calculation software to determine which grid cells there are; then determine which grid cell each line point is in, and obtain the target grid cell to which each line point belongs; finally, calculate the result value of each line point based on the cell result value corresponding to the target grid cell.

[0089] Step S104, performing two-dimensional mapping processing on the arc length value and the result value to obtain a target mapping result of the space curve.

[0090] The target mapping result refers to the visualization result of converting the arc length value and the result value into a two-dimensional image.

[0091] Specifically, the terminal maps the arc length value and the result value into a two-dimensional distribution map to characterize the target mapping result of the space curve through the distribution map. By analyzing the distribution map corresponding to the target mapping result, the distribution of the result value of the line point along the space curve can be accurately and clearly analyzed.

[0092] In the spatial curve calculation result mapping method of the above multi-physics field numerical calculation software, the spatial curve picked up in the multi-physics field numerical calculation software is obtained, and multiple line points are arranged on the spatial curve; the initial point of the curve is determined from the endpoints of the spatial curve, and the arc length value from each line point to the initial point of the curve is obtained; the result value of each line point is determined according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software; the arc length value and the result value are subjected to two-dimensional mapping processing to obtain the target mapping result of the spatial curve. This method realizes the mapping of the processing results of any spatial curve picked up in the multi-physics field numerical calculation software, and effectively improves the visualization efficiency and accuracy of the processing results of the spatial curve.

[0093] In one embodiment, the above step S101, obtaining the spatial curve picked up in the multi-physics field numerical calculation software, specifically includes the following contents: in response to a selection operation triggered by a spatial scene in the multi-physics field numerical calculation software, obtaining the position coordinates corresponding to the selection operation; converting the position coordinates into rays in the world coordinate system, and determining the intersection points of the rays with all the curves in the spatial scene through ray tracing processing; from the intersection points, filtering out the target intersection points closest to the rays; and using the curve where the target intersection point is located as the picked spatial curve.

[0094] Specifically, the terminal responds to the selection operation triggered by the user in the spatial scene in the multi-physics field numerical calculation software. For example, the user can trigger the selection operation for the spatial scene by clicking the mouse, and then the terminal captures the mouse click event and obtains the position coordinates of the click position. The terminal converts the position coordinates into rays in the world coordinate system, and then uses ray tracing technology to calculate the intersection of the ray and all the curves in the spatial scene; finally, the terminal can select the target intersection closest to the ray and obtain the curve where the target intersection is located, which is the spatial curve to be picked.

[0095] In this embodiment, through the selection operation between the user and the spatial scene in the multi-physics field numerical calculation software, the position coordinates corresponding to the selection operation can be accurately captured, so as to accurately process the spatial curve of the position coordinates corresponding to the selection operation, and then effectively obtain the spatial curve to be picked up, so that the subsequent steps can perform calculation processing on the spatial curve selected by the user and visualize the processing results.

[0096] In one embodiment, Figure 2 As shown, in the above step S103, according to the target grid unit to which each line point belongs in the grid unit in the multi-physics field numerical calculation software, before determining the result value of each line point, it also includes:

[0097] Step S201, obtaining grid information in multi-physics field numerical calculation software; the grid information includes unit information.

[0098] Specifically, in multi-physics calculation and analysis, mesh information includes node information and unit information. Node information includes node coordinates and node numbers; unit information includes unit type (two-node line unit, three-node line unit, three-node triangle unit, etc.) and node connection information (which nodes each unit is composed of, usually expressed in the form of a list of node numbers). Multi-physics calculation software usually uses specific file formats to store mesh data. Common formats include:

[0099] (1) ABAQUS INP format: widely used in ABAQUS software, text format;

[0100] (2) ANSYS CDB format: a binary mesh file format supported by ANSYS software;

[0101] (3) NASTRAN BDF / DAT format: File format supported by NASTRAN software, text format;

[0102] (4) VTK format: a format used for visualization that supports a variety of multi-physics field computing software.

[0103] The terminal can then parse and read the corresponding grid information in the multi-physics field numerical calculation software through the file format.

[0104] Step S202, obtaining the grid cells in the multi-physics field numerical calculation software according to the cell information.

[0105] Specifically, by analyzing the unit information, the terminal can know which grid units are included in the spatial scene of the multi-physics field numerical calculation software.

[0106] Step S203: determining, in the grid units, the target grid unit to which each line point belongs.

[0107] Specifically, there are many types of grid cells in multi-physics numerical calculation software. For example, the type of grid cell can be a triangle. Taking the triangular grid cell as an example, the area method, the internal angle method, the same side method and / or the centroid method can be used to determine whether the line point is inside the triangular grid cell, thereby obtaining the target grid cell to which each line point belongs:

[0108] (1) Area method: Calculate the sum of the areas of the three small triangles formed by the line point P and the three vertices A, B, and C of triangle ABC. If this sum is equal to the area of ​​the large triangle ABC, then the line point P is inside the triangle; otherwise, the line point P is outside the triangle. Figure 3 The triangle and any line point P shown, record For triangle If the area , then the line point P is outside the triangle; otherwise it is inside the triangle. The area can be calculated using Heron's formula or vector method.

[0109] (2) Interior angle method: Construct three line segments PA, PB, and PC from line point P to the three vertices of triangle ABC. If the sum of the angles between these three line segments and the sides of triangle ABC is equal to 180°, then line point P is inside the triangle; otherwise, line point P is outside. The angle can be calculated by the dot product of vectors.

[0110] (3) Same-side method: Determine whether the line point P is on the same side as the three sides AB, BC, and CA of triangle ABC. If the direction of the line point P relative to the three sides is consistent, then the line point P is inside the triangle; otherwise, the line point P is outside. The cross product of the vectors can be used to determine whether the line point P is in the same direction as the three sides of the triangle.

[0111] (4) Centroid method: Use the vectors of any two sides as basis vectors to represent the coordinates of the line point P, and use the value of the coefficient to determine whether the line point P is inside the triangle. Figure 2 The triangle Take the line point P as an example, and take the vector A 1P is expressed as follows:

[0112]

[0113] Point A 1 , A 2 , A 3 Substituting the coordinates of the line point P into the above formula, we can find the values ​​of u and v. If the coefficients u and v satisfy:

[0114]

[0115] Then the line point P is inside the triangle; otherwise, the line point P is outside the triangle.

[0116] For any line point, one of the above methods is used to judge all grid cells one by one to obtain the target grid cell where the line point is located.

[0117] In this embodiment, the grid cells in the multi-physics field numerical calculation software are first obtained, and then the target grid cells to which each line point belongs are determined from the grid cells, which lays the foundation for analyzing the result values ​​of the line points in the subsequent steps and is conducive to improving the accuracy of the processing results of the spatial curve.

[0118] In one embodiment, the above step S103 determines the result value of each line point according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software, and specifically includes the following contents: obtaining the shape function corresponding to the target grid unit to which each line point belongs; interpolating the unit result value corresponding to the target grid unit to which each line point belongs through the shape function to obtain the result value of each line point.

[0119] The result value refers to the data generated after the multi-physics field calculation and analysis is completed, which contains the response information of the model under different analysis conditions. These data are usually used to evaluate the performance of the structure, verify the design, optimize the model, etc.

[0120] Among them, the result values ​​can be divided into two categories: node result values ​​and unit result values. Node result values ​​represent that there is a result value at each node, such as node displacement, node stress, etc.; unit result values ​​represent that there is a result value at each unit, such as unit strain energy, etc. In practical applications, multi-physics field calculation software usually generates specific result file formats, such as:

[0121] (1) ABAQUS ODB file: result file format of ABAQUS software;

[0122] (2) ANSYS RST file: result file format of ANSYS software;

[0123] (3) NASTRAN OP2 / PCH file: result file format of NASTRAN software;

[0124] (4) And some customized result data file formats.

[0125] Specifically, after determining the target grid unit to which each line point belongs, the terminal may parse and read the result data file corresponding to the target grid unit through the file format specification corresponding to the target grid unit, and then extract the unit result value from the result data file.

[0126] For each line point, obtain the shape function corresponding to the target grid unit where it is located, combine the result values ​​on all grid nodes in the target grid unit where it is located, and interpolate the result value on the line point through the shape function. Among them, the shape functions of different unit types can be learned by referring to relevant books. There are many types of multi-physics field grids. Here, the plane triangle unit is used as an example to explain the calculation method of the result value of the line point.

[0127] Figure 3 Schematic diagram of the triangle area coordinate representation of line points, assuming Figure 3 The plane triangle in The node coordinates are A 1 (x 1 ,y 1 ), A 2 (x 2 ,y 2 ), A 3 (x 3 ,y 3 ), the shape function of any point P(x,y) in a three-node triangle element As shown below:

[0128]

[0129] In the formula, a n , b n , c n Represents the coefficient, which can be represented by the node coordinates Calculated; Δ represents the area of ​​the triangular unit. Among them, a n , b n , c n The calculations of and Δ are as follows:

[0130]

[0131]

[0132]

[0133]

[0134]

[0135]

[0136] Assume three nodes A 1 , A 2 , A 3 The result values ​​at are F 1 、F 2 、F 3 , then the result value F at any point P (x, y) in the three-node triangle element can be calculated by the following formula:

[0137]

[0138] The result value at the line point can be calculated through the above terminal.

[0139] In this embodiment, the unit result value corresponding to the target grid unit to which each line point belongs is interpolated through the shape function corresponding to the target grid unit to which each line point belongs, and the result value of each line point is calculated, thereby achieving accurate calculation of the result value of each line point and providing a reliable data basis for subsequent result analysis of the spatial curve.

[0140] In one embodiment, the above step S104 performs two-dimensional mapping processing on the arc length value and the result value to obtain the target mapping result of the spatial curve, which specifically includes the following contents: using the arc length value from each line point to the initial point of the curve as the horizontal coordinate, and using the result value of each line point as the vertical coordinate, to draw a two-dimensional scatter plot of the arc length value and the result value; connecting adjacent scatter points in the two-dimensional scatter plot to obtain a connected two-dimensional scatter plot; according to the two-dimensional scatter plot and the connected two-dimensional scatter plot, obtaining the target mapping result of the spatial curve.

[0141] Specifically, the arc length value from each line point to the initial point of the curve is used as the horizontal coordinate, and the result value of each line point is used as the vertical coordinate to draw a two-dimensional scatter plot of arc length value-result value. This two-dimensional scatter plot is the distribution diagram of the multi-physics field calculation results along the specified space curve. That is, through the calculation method described above, the arc length value of the i-th line point on the space curve L from the initial point of the curve is l i , the result value at the i-th line point is F i , then the scatter value of the distribution diagram of the multi-physics field calculation results along the specified space curve is (l i , F i ), the two-dimensional scatter plot drawn based on the arc length value and the result value is as follows Figure 4 shown.

[0142] Furthermore, adjacent scattered points in the two-dimensional scatter plot are connected with straight lines to obtain a connected two-dimensional scatter plot. Figure 5 is a schematic diagram of a two-dimensional scatter plot after connection. Connecting adjacent scattered points with straight lines also means that the result values ​​at the spatial points between the line points are obtained by linear interpolation using the result values ​​at the adjacent line points, and their accuracy is often not as good as the result values ​​obtained by interpolation using shape functions. Therefore, the more line points are arranged on the curve L, the more accurate the distribution diagram of the result values ​​along the curve will be.

[0143] In this embodiment, by analyzing the distribution graph corresponding to the target mapping result, the distribution of the result value of the line point along the space curve can be accurately and clearly analyzed, which effectively improves the visualization efficiency and accuracy of the processing result of the space curve.

[0144] In one embodiment, the above step S101, arranging multiple line points on the space curve, specifically includes the following contents: determining the first line point and the last line point on the space curve; and obtaining multiple line points on the space curve according to the first line point, the last line point and a preset number of line points.

[0145] Specifically, it is assumed that the parametric equation form of the picked space curve L saved in the file is as follows:

[0146]

[0147] When N (i.e., the preset number of line points) line points are evenly arranged in the space curve L, t=a is taken as the first line point and t=b is taken as the last line point, then the coordinates of the i-th line point are calculated as follows:

[0148]

[0149] in:

[0150]

[0151] Based on this, the terminal can calculate multiple line points on the space curve. In addition, it should be noted that the number of line points on the space curve will directly affect the accuracy of the processing result of the space curve. The more line points are arranged on the space curve L, the more accurate the distribution diagram of the result value along the space curve will be.

[0152] In this embodiment, multiple line points on the space curve are calculated through the first line point, the last line point and the preset number of line points on the space curve, which lays a foundation for analyzing the processing results of the space curve based on the line points in the subsequent steps.

[0153] In one embodiment, Figure 6As shown, another spatial curve calculation result mapping method of multi-physics field numerical calculation software is provided, and the method is applied to a terminal as an example for explanation, including the following steps:

[0154] Step S601, in response to a selection operation triggered by a space scene in a multi-physics field numerical calculation software, obtaining position coordinates corresponding to the selection operation.

[0155] Step S602, converting the position coordinates into rays in the world coordinate system, determining the intersections of the rays with all curves in the space scene through ray tracing processing; and selecting the target intersections closest to the rays from the intersections.

[0156] Step S603: taking the curve where the target intersection point is located as the picked-up space curve.

[0157] Step S604: Arrange multiple line points on the space curve.

[0158] Step S605, determining the initial point of the curve from the endpoints of the space curve, and obtaining the arc length value from each line point to the initial point of the curve.

[0159] Step S606, obtaining the shape function corresponding to the target grid unit to which each line point belongs; interpolating the unit result value corresponding to the target grid unit to which each line point belongs through the shape function to obtain the result value of each line point.

[0160] Step S607 , using the arc length value from each line point to the initial point of the curve as the horizontal coordinate and the result value of each line point as the vertical coordinate, to draw a two-dimensional scatter plot of the arc length value and the result value.

[0161] Step S608, connecting adjacent scatter points in the two-dimensional scatter plot to obtain a connected two-dimensional scatter plot.

[0162] Step S609, obtaining a target mapping result of the space curve according to the two-dimensional scatter plot and the connected two-dimensional scatter plot.

[0163] The spatial curve calculation result mapping method of the above-mentioned multi-physics field numerical calculation software can achieve the following beneficial effects: it realizes the mapping of the processing results of any spatial curve picked up in the multi-physics field numerical calculation software, and effectively improves the visualization efficiency and accuracy of the processing results of the spatial curve.

[0164] In order to more clearly illustrate the spatial curve calculation result mapping method of the multi-physics field numerical calculation software provided by the embodiment of the present disclosure, the spatial curve calculation result mapping method of the multi-physics field numerical calculation software is specifically described below with a specific embodiment. Figure 7As shown, another spatial curve calculation result mapping method of multi-physics field numerical calculation software is provided, which can be applied to the terminal, specifically including the following contents:

[0165] 1. Pick up space curves, including:

[0166] 1. Capture mouse click events and obtain the screen coordinates of the click position.

[0167] 2. Convert the screen coordinates to a ray in the world coordinate system.

[0168] 3. Using ray tracing technology, calculate the intersection points of the ray with all curves in the scene.

[0169] 4. Select the intersection point closest to the ray and obtain the curve where the intersection point is located, which is the curve to be picked.

[0170] 2. Curve point arrangement: According to the parametric equation of the curve, several line points can be arranged on the curve.

[0171] 3. Calculation of arc length of line points. Specify one of the endpoints of the curve as the initial point, and calculate the arc length from each line point to the initial point of the curve.

[0172] 4. Read the grid data. Then the terminal can parse and read the corresponding grid information in the multi-physics field numerical calculation software through the file format.

[0173] 5. Determine which grid cell each line point is in. The terminal can determine whether a line point is inside a grid cell by using methods such as area method, interior angle method, same side method, and centroid method.

[0174] 6. Reading result data: After determining the target grid unit to which each line point belongs, the terminal can parse and read the result data file corresponding to the target grid unit through the file format specification corresponding to the target grid unit, and then extract its unit result value from the result data file.

[0175] 7. Calculation of result values ​​at line points: For each line point, obtain the shape function corresponding to the target grid unit where it is located, combine the result values ​​of all grid nodes in the target grid unit where it is located, and obtain the result value at the line point through shape function interpolation.

[0176] 8. Use the arc length value from each line point to the initial point of the curve as the horizontal coordinate and the result value of each line point as the vertical coordinate to draw a two-dimensional scatter plot of arc length value-result value, which is the distribution diagram of the multi-physics field calculation results along the specified space curve.

[0177] In this embodiment, accurate, efficient, grid-based result analysis of arbitrary spatial curves of multi-physics field calculation results in the result space is achieved.

[0178] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.

[0179] Based on the same inventive concept, the embodiment of the present application also provides a spatial curve calculation result mapping device for multi-physics field numerical calculation software for implementing the spatial curve calculation result mapping method for multi-physics field numerical calculation software involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in the embodiments of the spatial curve calculation result mapping device for one or more multi-physics field numerical calculation software provided below can be referred to the limitations of the spatial curve calculation result mapping method for multi-physics field numerical calculation software above, and will not be repeated here.

[0180] In one embodiment, Figure 8 As shown, a space curve calculation result mapping device 800 of multi-physics field numerical calculation software is provided, comprising: a line point acquisition module 801, an arc length value acquisition module 802, a result value acquisition module 803 and a mapping processing module 804, wherein:

[0181] The line point acquisition module 801 is used to acquire a space curve picked up in the multi-physics field numerical calculation software and arrange a plurality of line points on the space curve.

[0182] The arc length value acquisition module 802 is used to determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve.

[0183] The result value acquisition module 803 is used to determine the result value of each line point according to the target grid unit to which each line point belongs in the grid unit in the multi-physics field numerical calculation software.

[0184] The mapping processing module 804 is used to perform two-dimensional mapping processing on the arc length value and the result value to obtain a target mapping result of the space curve.

[0185] In one embodiment, the line point acquisition module 801 is also used to respond to a selection operation triggered by a spatial scene in a multi-physics field numerical calculation software, obtain the position coordinates corresponding to the selection operation; convert the position coordinates into rays in the world coordinate system, and determine the intersection of the rays with all curves in the spatial scene through ray tracing processing; from the intersection points, filter out the target intersection point closest to the ray; and use the curve where the target intersection point is located as the picked spatial curve.

[0186] In one embodiment, the spatial curve calculation result mapping device 800 of the multi-physics field numerical calculation software also includes a unit judgment module, which is used to obtain grid information in the multi-physics field numerical calculation software; the grid information includes unit information; according to the unit information, the grid unit in the multi-physics field numerical calculation software is obtained; in the grid unit, the target grid unit to which each line point belongs is determined.

[0187] In one embodiment, the result value acquisition module 803 is also used to obtain the shape function corresponding to the target grid unit to which each line point belongs; through the shape function, the unit result value corresponding to the target grid unit to which each line point belongs is interpolated to obtain the result value of each line point.

[0188] In one embodiment, the mapping processing module 804 is also used to use the arc length value from each line point to the initial point of the curve as the horizontal coordinate, and the result value of each line point as the vertical coordinate to draw a two-dimensional scatter plot of the arc length value and the result value; based on the two-dimensional scatter plot, the target mapping result of the spatial curve is obtained.

[0189] In one embodiment, the line point acquisition module 801 is further used to determine the first line point and the last line point on the space curve; and obtain multiple line points on the space curve according to the first line point, the last line point and a preset number of line points.

[0190] Each module in the spatial curve calculation result mapping device of the multi-physics field numerical calculation software can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory of the computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.

[0191] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Fig. 9As shown. The computer device includes a processor, a memory, an input / output interface, a communication interface, a display unit and an input device. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface, the display unit and the input device are connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and the external device. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be realized through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a spatial curve calculation result mapping method of a multi-physics field numerical calculation software is realized. The display unit of the computer device is used to form a visually visible picture, which can be a display screen, a projection device or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device shell, or an external keyboard, touchpad or mouse.

[0192] Those skilled in the art will understand that Fig. 9 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.

[0193] In one embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above method embodiments when executing the computer program.

[0194] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.

[0195] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.

[0196] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.

[0197] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.

[0198] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.

Claims

1. A method for mapping spatial curve calculation results of multi-physics field numerical calculation software, characterized in that: The method comprises: Obtaining a space curve picked up in multi-physics field numerical calculation software, and arranging a plurality of line points on the space curve; Determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve; Determine the result value of each of the line points according to the target grid unit to which each of the line points belongs in the grid unit of the multi-physics field numerical calculation software; A two-dimensional mapping process is performed on the arc length value and the result value to obtain a target mapping result of the space curve.

2. The method according to claim 1, characterized in that The step of obtaining the space curve picked up in the multi-physics field numerical calculation software comprises: In response to a selection operation triggered by a spatial scene in the multi-physics field numerical calculation software, obtaining position coordinates corresponding to the selection operation; Convert the position coordinates into rays in a world coordinate system, and determine the intersection points of the rays with all curves in the space scene through ray tracing; From the intersection points, select the target intersection point closest to the ray; The curve where the target intersection point is located is used as the picked space curve.

3. The method according to claim 1, characterized in that In the grid unit according to the multi-physics field numerical calculation software, before determining the result value of each line point in the target grid unit to which each line point belongs, the method further comprises: Obtaining grid information in the multi-physics field numerical calculation software; the grid information includes unit information; According to the unit information, a grid unit in the multi-physics field numerical calculation software is obtained; In the grid unit, a target grid unit to which each of the line points belongs is determined.

4. The method according to claim 3, characterized in that The determining of the result value of each line point according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software comprises: Obtaining a shape function corresponding to a target grid unit to which each of the line points belongs; The shape function is used to interpolate the cell result value corresponding to the target grid cell to which each of the line points belongs, so as to obtain the result value of each of the line points.

5. The method according to claim 1, characterized in that The performing two-dimensional mapping processing on the arc length value and the result value to obtain the target mapping result of the space curve includes: Using the arc length value from each line point to the initial point of the curve as the abscissa, and using the result value of each line point as the ordinate, a two-dimensional scatter plot of the arc length value and the result value is drawn; According to the two-dimensional scatter plot, a target mapping result of the space curve is obtained.

6. The method according to claim 1, characterized in that The step of arranging a plurality of line points on the space curve comprises: Determine the first line point and the last line point on the space curve; A plurality of line points on the space curve are obtained according to the first line point, the last line point and a preset number of line points.

7. A spatial curve calculation result mapping device for multi-physics field numerical calculation software, characterized in that: The device comprises: A line point acquisition module is used to acquire a space curve picked up in the multi-physics field numerical calculation software, and arrange a plurality of line points on the space curve; An arc length value acquisition module, used to determine the initial point of the curve from the endpoints of the space curve, and obtain the arc length value from each line point to the initial point of the curve; A result value acquisition module, used for determining the result value of each line point according to the target grid unit to which each line point belongs in the grid unit of the multi-physics field numerical calculation software; A mapping processing module is used to perform two-dimensional mapping processing on the arc length value and the result value to obtain a target mapping result of the space curve.

8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.

9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.

10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.

Citation Information

Patent Citations

  • Irregular mesh mapping method used in electromagnetic field-flow field-temperature field coupling calculation

    CN103617367A

  • Thermal insulation material design system based on multi-physics field coupling simulation

    CN118378493A

  • Swept surface high-precision reconstruction method and pipeline part curved surface reconstruction method

    CN118762145A

  • Grid mapping method and device for multi-physics field coupling of reactor core

    CN119378422A

  • System and method for image warp correction for magnetic resonance imaging

    US20160313434A1