B-spline finite element analysis topological optimization method based on neural network

By combining NURBS and PINNs methods, the density field distribution is optimized, and the problem of insufficient accuracy and efficiency in complex structures is solved, and efficient and accurate topological optimization effects are achieved.

CN120600172AInactive Publication Date: 2025-09-05UNIV OF SHANGHAI FOR SCI & TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510525788.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-24
Publication Date
2025-09-05
Estimated Expiration
Not applicable · inactive patent

AI Technical Summary

Technical Problem

Traditional topological optimization methods have limitations in dealing with complex geometric shapes and multi-physics problems, making it difficult to achieve efficient and precise structural optimization.

Method used

Combining non-uniform rational B-splines (NURBS) and physical information neural networks (PINNs), sensitivity analysis is performed through built-in backpropagation, and density field distribution is optimized, and forward propagation is used to iterate continuously until the preset convergence conditions or maximum iterations are reached, and the optimized density field is obtained.

Benefits of technology

It realizes efficient topological optimization of complex structures, improves optimization accuracy and efficiency, and can flexibly deal with design problems of complex geometric shapes.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120600172A_ABST
    Figure CN120600172A_ABST
Patent Text Reader

Abstract

The invention discloses a B-spline finite element analysis topological optimization method based on a neural network, which fuses a non-uniform rational B-spline (NURBS) and a physical information neural network (PINNs), and comprises the following steps of: performing geometric region and structural density representation by using the NURBS, inputting a control point of a geometric region into an isogeometric neural network based on the PINN, and outputting a density control point; then, isogeometric analysis is used for displacement calculation, and a structural performance index is calculated as loss. And finally, performing sensitivity analysis by using a built-in back propagation mechanism so as to optimize density field distribution. The optimized density field is obtained through continuous forward propagation, performance index (such as flexibility) calculation, back propagation and weight updating until a preset convergence condition or the maximum number of iterations is reached. According to the method, the modeling capability of the neural network and the accuracy of finite element analysis based on the B-spline can be effectively combined, and efficient and accurate topological optimization is realized.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a topology optimization method for isogeometric structures, and in particular to a topology optimization method for B-spline finite element analysis based on a neural network. Background Art

[0002] In modern engineering design, structural topology optimization is a key technology used to find the optimal material distribution scheme to improve the performance and efficiency of a structure. Traditional topology optimization methods often rely on finite element analysis (FEA), but these methods have limitations when dealing with complex geometries and multi-physics problems. Recent advances in machine learning techniques, particularly the application of physical information neural networks (PINNs), have provided new approaches to addressing these issues. Therefore, further research and innovation are needed to address the accuracy and efficiency challenges of topology optimization for complex structures, in line with the times and leveraging emerging resources. Summary of the Invention

[0003] Purpose of the invention: In order to address the deficiencies in the prior art, the present invention provides a neural network-based B-spline finite element analysis topology optimization method. This method combines non-uniform rational B-splines (NURBS) and physical information neural networks (PINNs), uses NURBS for density representation and PINN-based isogeometric neural networks, and then uses built-in back propagation for sensitivity analysis to optimize the density field distribution. Through continuous forward propagation, performance index (such as flexibility) calculation, back propagation and weight update, until the preset convergence condition or the maximum number of iterations is reached, the optimized density field is obtained. This method can effectively combine the powerful modeling capabilities of neural networks and the accuracy of traditional finite element analysis to achieve efficient topology optimization of complex structures. By using NURBS and PINNs, design problems with complex geometries can be handled more flexibly, and the accuracy and efficiency of structural optimization can be improved.

[0004] Technical solution: The neural network-based B-spline finite element analysis topology optimization method of the present invention comprises the following steps:

[0005] S 1. Density representation using NURBS: The isogeometric neural network predicts the corresponding density field control point value based on the given spatial coordinates;

[0006] S2, using the control points of the density field output by the neural network, and then using isogeometric analysis to calculate the displacement, thereby calculating the loss flexibility value;

[0007] S3. Use built-in backpropagation for sensitivity analysis: calculate gradient information and update PINN weights;

[0008] S4. Use the PINN-based isogeometric neural network to input the given spatial coordinates again and output the optimized density field control points and continuously iterate to optimize, and finally obtain the optimal topological result.

[0009] Using NURBS for density representation: By defining control points and weights, selecting basis functions, constructing a continuous density field model, and ensuring physical feasibility, this approach enables accurate modeling and optimization of complex geometries and material density distributions. Using PINN-based isogeometric neural networks: Constructing the PINN architecture involves designing a neural network that takes spatial coordinates as input, embedding physical information into the loss function, integrating isogeometric analysis to ensure model consistency, and accelerating convergence through appropriate initialization and pre-training, resulting in accurate and physically accurate numerical simulations. PINNs can contain multiple hidden layers, each with multiple neurons, and activation functions such as Reluctant Unit (ReLU) and Sigmoid. Using built-in backpropagation for sensitivity analysis: Automatic differentiation is used to calculate gradients, evaluate sensitivities, quantify uncertainties, and perform multi-objective sensitivity analysis to optimize network outputs and guide the improvement and design of complex systems. Optimizing density field distributions: Selecting an appropriate optimization algorithm and setting objectives and constraints, the design is continuously optimized through iterative adjustments and sensitivity analysis, ultimately undergoing rigorous verification to ensure that the design meets all specifications and performance requirements. This approach addresses design problems with complex geometries and improves the accuracy and efficiency of structural optimization.

[0010] Furthermore, NURBS (non-uniform rational B-splines) is used to describe the distribution of materials inside the structure and set the initial density field distribution. The initial density field distribution can be a simple uniform distribution or a distribution based on prior knowledge, and is mathematically represented. The smooth and continuous density distribution provided by NURBS is used as one of the inputs of the isogeometric neural network, where the geometric model and the physical model use the same mathematical representation (e.g., NURBS). The initial density field distribution can be expressed by the following formula:

[0011]

[0012] in, is the density distribution defined on the design domain X, N i is the i-th B-spline basis function, q i is the corresponding B-spline coefficient, which is used to calculate the performance indicators such as the flexibility of the structure. The initial coefficient q i It can be generated randomly or set based on existing design experience.

[0013] Furthermore, in step S2, the gradient of the loss function (here, the flexibility) with respect to the network parameters (indirectly, the density field control points) is calculated through the built-in backpropagation mechanism of the neural network. The flexibility is calculated through matrix operations on the displacement vector U and the stiffness matrix K. The flexibility is calculated based on the output density field control points. Prior to this, the update strategy proposed by Andreassen is used, that is, the updated Young's modulus is determined by the density at the unit. The Young's modulus of the i-th unit is expressed as follows:

[0014]

[0015] Among them, E max Represents the Young's modulus of the material, E min is a minimum value assigned to the empty element to avoid the singularity of the stiffness matrix, ρ i represents the density of the i-th element, and its value range is usually between 0 and 1. A density of 0 means that the element is empty, and a density of 1 means that the element is completely filled with material. p is the penalty factor, which is used to make the density value of the element approach 0 or 1. Based on the obtained Young's modulus, the stiffness matrix K is assembled, and then the linear equation is solved:

[0016] KU=F

[0017] Get the displacement vector U, and then substitute it into the calculation to get the internal force vector F internal , calculation formula:

[0018] C=U T (KU)

[0019] Among them, U T represents the transpose of the displacement vector U, from which the flexibility C can be obtained.

[0020] Furthermore, in step S4, the automatic derivation mechanism of a common deep learning framework (pytorch) is used to update variables: S-PINN maps spatial coordinates to density field control points, and indirectly updates the density distribution by updating the network weights.

[0021] Furthermore, in step S2, the average flexibility is used as the objective function of topology optimization (TO), which is equivalent to the inverse of the overall stiffness of the structure. Through this transformation, the density-based TO problem is converted into a loss minimization problem of the neural network. The loss function not only includes the flexibility calculated by the physical model but also combines the design constraints. It consists of two parts. The first part is the flexibility loss, which can be expressed as:

[0022]

[0023] Among them, C0 is the flexibility of the initial structure. Using this term as a divisor can regularize the flexibility loss and avoid excessive flexibility loss. U represents the displacement vector, which contains the displacement information of each node of the structure under the load. U represents the stiffness matrix. The product of KU is the internal force vector F. internal ;

[0024] The second part of the volume loss can be expressed as:

[0025]

[0026] Among them, V(P ρ ) represents the current volume, which is usually calculated from the density distribution, v f represents the target volume (or volume fraction);

[0027] Further, here we will combine Figure 2 Explanation: Through the built-in back-propagation mechanism of the neural network, the gradient of the loss function (such as flexibility C) with respect to the network parameters (indirectly the density field control point c) is calculated and optimized using the gradient descent method. It is necessary to calculate the sensitivity of the cost function and the volume constraint to the design variable (i.e., the B-spline coefficient c). The sensitivity of the volume constraint can be expressed as:

[0028]

[0029] Where V is the volume, c i are the B-spline coefficients, is the volume V for the i-th design variable (B-spline coefficient c i ) sensitivity, i.e. adjusting c i The volume change rate caused by e It is the design area;

[0030] Therefore, the loss function is defined, which usually includes the residual term and boundary condition term of the physical equation. For example, for structural optimization problems, the loss function can be expressed as:

[0031]

[0032] in, is the flexibility loss, is the volume loss, and λ is the volume constraint term.

[0033] Furthermore, in step S2, the finite element analysis (FEA) solver embedded in the S-PINN directly calculates the flexibility of the system in the loss function, and the gradient information calculated by backpropagation is fed back to the PINN to adjust the network weight. The network weight w updated using the gradient descent method can be expressed as:

[0034]

[0035] According to the changes in the loss function during the optimization process, the learning rate η is dynamically adjusted to accelerate the convergence speed and thus optimize the density field distribution.

[0036] Furthermore, the backpropagation step is repeated to calculate the gradient of the loss function with respect to the network parameters, and the network weights are updated using the gradient descent method. The density field distribution is optimized and it is checked whether the preset convergence condition or optimization criterion is met. Specifically, the convergence condition or optimization criterion here can set a threshold or maximum number of iterations of the loss function. If the convergence condition is met, the optimization is stopped, otherwise, the iteration continues. For the convergence condition, the change of the loss function can be limited to be less than a small threshold. One feasible expression is as follows:

[0037]

[0038] Among them, L i is the neural network loss value at the i-th iteration, L i-1 is the neural network loss value at the last iteration, τ is a predefined threshold, and once the optimization process is completed, the optimized material distribution, i.e. the optimal topology result, is output; for the maximum number of iterations, a maximum number of iterations N can be set. max , when the number of iterations reaches N max Stop optimization when

[0039] Furthermore, for the density field after S-PINN optimization, the stiffness matrix K needs to be reassembled. For the stiffness matrix K, the update strategy proposed by Andreassen is used to calculate the updated Young's modulus. According to the updated Young's modulus, the stiffness matrix K is reassembled. Based on the reorganized stiffness matrix, the geometric analysis is continued, and the loss value, including flexibility and design constraints, is recalculated. The geometric analysis is performed again, the loss is obtained again, and the iteration is continued until the maximum number of iterations is reached or the stopping condition is reached.

[0040] Furthermore, if the current iteration result does not meet the convergence condition, the iteration is continued to make the smooth and continuous density distribution provided by NURBS As one of the inputs of the isogeometric neural network, it is first normalized and its format can be the spatial coordinate x = (x, y, z) and the corresponding initial density value And ensure that the range of input data is within a reasonable range.

[0041] Furthermore, the coordinate x in the spatial domain is input into a physical information neural network (PINN) compatible with the isogeometric analysis framework to output the optimized density field control point c.

[0042] Furthermore, PINN outputs the optimized density field control point c again.

[0043] The control points are used for secondary calculation of performance indicators such as the flexibility of the structure. The optimized density field ρ(x) can be expressed as:

[0044]

[0045] Among them, R i (x) is the i-th B-spline basis function, c i are the optimized B-spline coefficients.

[0046] Furthermore, the forward propagation step is repeated, and based on the new density field ρ(x), the displacement U of the structure is calculated again and the stiffness matrix K is reassembled. The geometric analysis is continued, the loss value is recalculated, and the iteration is continued until the maximum number of iterations is reached or the stopping condition is reached.

[0047] Furthermore, when the difference between two adjacent loss values ​​is less than a predetermined value, that is, the condition is met, it is considered that the optimal topology result is obtained, the optimization process is completed, and the optimized material distribution, that is, the optimal topology result, is output.

[0048] Compared with the prior art, the present invention has the following beneficial effects:

[0049] 1. This method can effectively combine the powerful modeling capabilities of neural networks and the accuracy of traditional finite element analysis to achieve efficient topology optimization of complex structures.

[0050] 2. This method not only improves the accuracy and efficiency of optimization, but also performs well in dealing with complex geometries and multi-physics problems.

[0051] 3. Using NURBS and PINNs, design problems with complex geometries can be handled more flexibly. BRIEF DESCRIPTION OF THE DRAWINGS

[0052] Figure 1 Flow chart of the method of the present invention;

[0053] Figure 2 is the specific process of the back propagation mechanism built into the neural network, where θ is the parameter of the neural network; α is the learning rate used for parameter update; λ is the weight coefficient used to balance the flexibility loss and volume fraction loss; ρ is the density field; ρ0 is the target density; C is the flexibility; L C is the flexibility loss; L vf is the volume fraction loss; FEA(ρ) is the finite element analysis function, the input is the density field ρ, and the output is the flexibility C;

[0054] Figure 3 This is the optimized design domain output by the embodiment. DETAILED DESCRIPTION

[0055] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be further described below.

[0056] Referring to the accompanying drawings, the neural network-based B-spline finite element analysis topology optimization of the present invention includes the following steps:

[0057] S1. Density representation using NURBS: The isogeometric neural network predicts the corresponding density field control point value based on the given spatial coordinates;

[0058] S2, using the PINN-based isogeometric neural network to input the given spatial coordinates again and output the optimized density field control points;

[0059] S3. Use built-in backpropagation for sensitivity analysis: calculate gradient information and feed it back to PINN;

[0060] S4. The neural network outputs the control points of the density field, and then uses isogeometric analysis to calculate the displacement, thereby calculating the loss flexibility value, and continuously iterating for optimization.

[0061] In this embodiment, the detailed implementation steps of step S1 include:

[0062] S11. Define the basic parameters and grid structure of the computational domain:

[0063] The network parameters are used to define the geometric structure and discretization method of the computational domain. By setting parameters such as the number of nodes and the total number of degrees of freedom, the network division method of the computational domain in the finite element analysis is determined, thereby providing a basis for subsequent numerical calculations. Here, the network parameters are set to n elx =40,n nely =20, the number of nodes is n nodes =(n elx +1)×(n nely +1), the total number of degrees of freedom is ndof=2×n nodes , providing the basis for NURBS density representation.

[0064] S12. Set boundary conditions and fixed nodes:

[0065] Define the degree of freedom of each node (degree of freedom index) dofs = {0, 1, ..., ndof-1}, and build an accurate finite element model. Through the degree of freedom index, the degree of freedom of some nodes can be specified as fixed fixed = {0, 1, ..., 2×(n nely +1)-1}, determine the free nodes to participate in the operation free=dofs / fixed to provide the necessary conditions for finite element analysis.

[0066] S13. Initialize the solution vector and external load:

[0067] The right-hand side vector usually represents the influence of external forces or boundary conditions on the structure. In finite element analysis, it forms a linear equation system together with the stiffness matrix to solve the response of the structure (such as displacement). Here it is set to f = O ndof×1 , the displacement vector represents the deformation of the structure under load. By solving the linear equations to obtain the displacement vector, we can further calculate mechanical indicators such as stress and strain, which is set here as u fea =O ndof×1 , apply external load to simulate the stress situation under actual working conditions, which is set to f in this embodiment. last node,0 =-1.

[0068] S14. Predict the corresponding density field control point value:

[0069]

[0070] in, is the density distribution defined on the design domain X, N i is the i-th B-spline basis function, q i is the corresponding B-spline coefficient, which is used to calculate performance indicators such as the flexibility of the structure.

[0071] In this embodiment, the detailed implementation steps of step S2 include:

[0072] S21. Establish the relationship between element degrees of freedom and global degrees of freedom:

[0073] Global degree of freedom mapping edofMat[e,:]=[2n1+2,2n1+3,2n2+2,2n2+3,2n2,2n2+1,2n1,2n1+1] where n1 and n2 are the numbers of the two diagonal nodes of the unit to facilitate subsequent matrix operations;

[0074] S22. Construct an index pointer for constructing a sparse matrix: determine the row and column indices: i K =kron(edofMat,1 8×1 ).flatten(),j K =kron(edofMat,1 8×1 ).flatten() improves the efficiency of the stiffness matrix calculation process

[0075] Among them, i K Represents the row index array, j K Represents the column index array. It is worth noting that the array here is the row and column corresponding to the sparse matrix, and edofMat is the unit degree of freedom matrix;

[0076] S23. Evaluate the current design through finite element analysis and update the design variables based on the sensitivity information:

[0077] Set the number of iterations:

[0078] interactions = 500

[0079] Borrowing Andreassen's strategy to find Young's modulus:

[0080]

[0081] Among them, E max Represents the Young's modulus of the material, E min is a minimum value assigned to the empty element to avoid the singularity of the stiffness matrix, ρ i represents the density of the i-th unit, and its value range is usually between 0 and 1. A density of 0 means that the unit is empty, and a density of 1 means that the unit is completely filled with material. p is the penalty factor, which is used to make the unit density value approach 0 or 1.

[0082] The effective elastic modulus is given by s K =(E min +(x Phys ) p (E max -E min )) indicates that the sparse stiffness matrix is ​​represented by the code K = coo_matrix((s K ,(i K ,j K )), shape = (ndof, ndof)).tocsc() means, where E min is the minimum elastic modulus of the material, E max is the maximum elastic modulus of the material, x Phys is the physical density variable, p is the penalty index, i K is the row index array, j K is the column index array. It is worth noting that the array here is the rows and columns corresponding to the sparse matrix.

[0083] According to the obtained Young's modulus, assemble the stiffness matrix K and solve the linear equation:

[0084] KU=F

[0085] Where U is the displacement vector, F is the internal force vector,

[0086] Here is the code u fea[free,0]=spsolve(K,f[free,0]) means that the objective function K=K[free,:][:,free], where u fea [free,0] represents the displacement vector of the degree of freedom node, spsolve is a sparse matrix solver, K is the stiffness matrix, f[free,0] is the external force vector, and the unit energy density It represents the energy stored in each unit during deformation and is used to evaluate the stress state of the unit and the performance of the overall structure, where B e is the strain matrix, D is the material stiffness matrix, u fea,e is the displacement vector of the unit,

[0087] Calculate the flexibility value:

[0088] C=U T (KU)

[0089] Among them, U T represents the transpose of the displacement vector U, from which the flexibility C is obtained.

[0090] Calculate the gradient to determine how to adjust the design variables to minimize the objective function, which can be calculated using the chain rule and is coded as d c =-p(x Phys ) p-1 (E max -E min )c e , construct sensitivity filter To reduce the checkerboard patterns that may appear during the optimization process, that is, to smooth the sensitivity information, avoid numerical instability and non-physical phenomena, and update the design variables x according to the sensitivity information and design constraints Phys =oc(n elx , n ely , x Phys ,volfrac,d c , d v , g), gradually approaching the optimal solution, where x Phys is the physical density variable, p is the penalty index, E max is the maximum elastic modulus, E min is the minimum elastic modulus, c e is the unit sensitivity coefficient, H is the filter matrix, H s is the filter normalization factor, n elx is the number of elements in the design area in the x direction, n ely is the number of elements in the design area in the y direction, volfrac is the target volume fraction, d cis the filtered sensitivity information, dv is the sensitivity information of the volume constraint, g is the optimization objective function, and oc is the optimization constraint function. This method ensures that the optimization process complies with physical laws and design requirements by iteratively adjusting the design variables:

[0091]

[0092] Among them, is the loss function, w is the network weight updated by the gradient descent method, and η is the learning rate.

[0093] To minimize the loss function, the weights are continuously adjusted based on the gradient of the loss function with respect to the weights. During each update, the product of the learning rate eta and the gradient is subtracted from the current weight w, adjusting the weights in a direction that minimizes the loss function. After multiple iterations, the optimal weight values ​​that minimize the loss function are gradually found, optimizing the performance of the neural network.

[0094] S24. Calculate the loss flexibility value:

[0095] Again calculate the compliance contribution of each element:

[0096] C=U T (KU)

[0097] Among them, U T represents the transpose of the displacement vector U;

[0098] Again, we get the displacement solution obtained by finite element analysis:

[0099] KU=F

[0100] Where U is the displacement vector, F is the internal force vector,

[0101] Get the volume constraint:

[0102]

[0103] Where V is the volume, c i are the B-spline coefficients, is the volume V for the i-th design variable (B-spline coefficient c i ) sensitivity, i.e. adjusting c i The volume change rate caused by e It is the design area;

[0104] Calculate the sensitivity of the flexibility value: dc = -ce*penal*(xPhys**(penal-1)), where ce is the element flexibility coefficient, penal(p) is the penalty index, and xPhys(xP hys ) is the physical density variable,

[0105] Calculate the compliance loss again:

[0106]

[0107] Among them, C0 is the flexibility of the initial structure. Using this term as a divisor can regularize the flexibility loss and avoid excessive flexibility loss. U represents the displacement vector, which contains the displacement information of each node of the structure under the load. U represents the stiffness matrix. The product of KU is the internal force vector F. internal ;

[0108] Calculate the second part of the volume loss:

[0109]

[0110] Among them, V(P ρ ) represents the current volume, which is usually calculated from the density distribution, v f represents the target volume (or volume fraction);

[0111] Therefore, the loss compliance value is:

[0112]

[0113] in, is the flexibility loss, is the volume loss, and λ is the volume constraint term.

[0114] In this embodiment, the detailed implementation steps of step S3 include:

[0115] S31. Build a sensitivity filter to reduce the checkerboard effect:

[0116] Set the filter radius r min =3 to define the influence range of the filter and calculate the influence weight of each unit on the surrounding units Construct a sparse filter matrix to represent the filter weight H = coo_matrix((s H ,(i H ,j H )), shape = (n elx ×n ely , n elx ×n ely )).tocsc(), calculate the sum of each row of the filter matrix to ensure its normalization Hs = H.sum(1), where r min is the filter radius, s H is the filter weight value array, i H is the row index array, j H Column index array, different from i K and j K , here i Hand j H Refers to the rows and columns corresponding to each non-zero weight, n elx and n ely are the number of elements in the design area in the x and y directions, respectively;

[0117] S32, gradient calculation: based on the total loss in, is the flexibility loss, is the volume loss, λ is the volume constraint term, and the Calculate the loss function through automatic differentiation Gradient with respect to control point c;

[0118] S33, weight update: The gradient information calculated by back propagation is fed back to PINN to help adjust the network weights, thereby optimizing the density field distribution, and ultimately achieving the goal of reducing structural flexibility. The network weight w updated using the gradient descent method is expressed as:

[0119]

[0120] According to the changes in the loss function during the optimization process, the learning rate η is dynamically adjusted to accelerate the convergence speed and thus optimize the density field distribution.

[0121] In this embodiment, the detailed implementation steps of step S4 include:

[0122] S41. Define the relevant parameters for topology optimization:

[0123] Set the volume fraction target volfrac = 0.7, the elastic modulus range E min =1×10 -9 , E max =10, penalty index p=3.0, initial value of variable Where volfrac is the volume fraction target, E min is the minimum elastic modulus of the material, E max is the maximum elastic modulus of the material, p is the penalty index, x Phys is the physical density variable, n elx and n ely are the number of elements in the design area in the x and y directions, respectively. For the density field after S-PINN optimization, the stiffness matrix K needs to be reassembled to perform geometric analysis again, re-obtain the loss, and continue to iterate until the maximum number of iterations is reached or the stopping condition is met; repeat the above steps until the maximum number of iterations is reached or the stopping condition is met; the termination condition of topology optimization is determined by the loss of the neural network and the given conditions. When the difference between two adjacent loss values ​​is less than the predetermined value, it is considered that the optimal topology result has been obtained, as shown below:

[0124] |Li -L i-1 |≤τ

[0125] Among them, L i is the neural network loss value at the i-th iteration, L i-1 is the neural network loss value at the last iteration, and τ is a predefined threshold used to determine whether the loss value tends to be stable. Once the optimization process is completed, the optimized material distribution, that is, the optimal topology result, is output.

[0126] S42, output the design domain after visualization optimization, such as Figure 3 shown

[0127] S43. Output the optimal flexibility value after iteration:

[0128] C=U T (KU)

[0129] Among them, U T represents the transpose of the displacement vector U, K represents the stiffness matrix, U represents the displacement vector,

[0130] In this embodiment, the final compliance value is 1.5.

[0131] The test results show that this neural network-based B-spline finite element analysis significantly improves the efficiency and accuracy of topology optimization.

[0132] The above description is merely a preferred embodiment of the present invention and does not limit the present invention in any way. Any person skilled in the art who, without departing from the scope of the present invention, makes any equivalent substitution, modification, or other changes to the technical solution and technical content disclosed in the present invention shall be deemed to be within the scope of the present invention and still fall within the scope of protection of the present invention.

Claims

1. A B-spline finite element analysis topology optimization method based on neural network, characterized in that: The steps include: S1. Density representation using NURBS: The isogeometric neural network predicts the corresponding density field control point value based on the given spatial coordinates; S2, using the control points of the density field output by the neural network, and then using isogeometric analysis to calculate the displacement, thereby calculating the loss flexibility value; S3. Use built-in backpropagation for sensitivity analysis: calculate gradient information and update PINN weights; S4. Use the PINN-based isogeometric neural network to input the given spatial coordinates again and output the optimized density field control points and continuously iterate to optimize, and finally obtain the optimal topological result.

2. The neural network-based B-spline finite element analysis topology optimization method according to claim 1, characterized in that: In step S1, the PINN-based isogeometric neural network receives the coordinates in the spatial domain as input and outputs the control points of the density field, namely: in, is the density distribution defined on the design domain X, N i is the i-th B-spline basis function, q i is the corresponding B-spline coefficient, which is used to calculate performance indicators such as the flexibility of the structure.

3. The neural network-based B-spline finite element analysis topology optimization method according to claim 2, characterized in that: The flexibility calculation in step S2 is performed by outputting the control points of the density field through the neural network, and then calculating the displacement by isogeometric analysis to calculate the loss flexibility value. The flexibility calculation is achieved by matrix operation of the displacement vector U and the stiffness matrix K, which is also an isogeometric analysis process. Based on the output density field control points, the update strategy proposed by Andreassen is used, that is, the updated Young's modulus is determined by the density at the unit, and the Young's modulus is calculated. The expression of the Young's modulus of the i-th unit is as follows: Among them, E max Represents the Young's modulus of the material, E min is a minimum value assigned to the empty element to avoid the singularity of the stiffness matrix, ρ i represents the density of the oth element, and its value range is usually between 0 and 1. A density of 0 indicates that the element is empty, and a density of 1 indicates that the element is completely filled with material. p is the penalty factor, which is used to make the density value of the element approach 0 or 1. Based on the obtained Young's modulus, the stiffness matrix K is assembled, and then the linear equation is solved: KU=F Get the displacement vector U, and then substitute it into the calculation to get the internal force vector F internal , calculation formula: C=U T (UK) Among them, U T represents the transpose of the displacement vector U, from which the flexibility C can be obtained.

4. The neural network-based B-spline finite element analysis topology optimization method according to claim 3, characterized in that: The calculation process of the loss flexibility value is to use the average flexibility as the objective function of topology optimization (TO), which is equivalent to the inverse of the overall stiffness of the structure. Through this transformation, the density-based TO problem is converted into a loss minimization problem of the neural network. The loss function not only includes the flexibility calculated by the physical model, but also combines the design constraints. It consists of two parts. The first part is the flexibility loss, which can be expressed as: Among them, C0 is the flexibility of the initial structure. Using this term as a divisor can regularize the flexibility loss and avoid excessive flexibility loss. U represents the displacement vector, which contains the displacement information of each node of the structure under the load. U represents the stiffness matrix. The product of KU is the internal force vector F. internal ; The second part of the volume loss can be expressed as: Among them, V(P ρ ) represents the current volume, which is usually calculated from the density distribution, v f represents the target volume (or volume fraction); Therefore, the total loss can be expressed as: in, is the flexibility loss, is the volume loss, and λ is the volume constraint term.

5. The neural network-based B-spline finite element analysis topology optimization method according to claim 4, characterized in that: The back propagation mechanism in step S3 is implemented by using the automatic differentiation mechanism of the common deep learning framework pytorch to update variables: S-PINN maps spatial coordinates to density field control points and indirectly updates the density distribution by updating the network weights.

6. The neural network-based B-spline finite element analysis topology optimization method according to claim 5, characterized in that: Gradient calculation to update weights is done by directly calculating the flexibility of the system in the loss function through the finite element analysis (FEA) solver embedded in S-PINN. The gradient information calculated by backpropagation is fed back to PINN to adjust the network weights to optimize the density field distribution.

7. The neural network-based B-spline finite element analysis topology optimization method according to claim 6, characterized in that: In the iterative process of step S4, for the density field after S-PINN optimization, it is necessary to reassemble the stiffness matrix K, perform geometric analysis again, re-obtain the loss, and continue to iterate until the maximum number of iterations is reached or the stopping condition is met; for the stiffness matrix K, the update strategy proposed by Andreassen is still used to calculate the updated Young's modulus, and according to the updated Young's modulus, the stiffness matrix K is reassembled, and based on the reorganized stiffness matrix, geometric analysis is continued, and the loss value, including flexibility and design constraints, is recalculated, and the above steps are repeated until the maximum number of iterations is reached or the stopping condition is met.

8. The neural network-based B-spline finite element analysis topology optimization method according to claim 7, characterized in that: The termination condition of the iteration, in addition to reaching the maximum number of iterations, is also determined by the loss of the neural network. When the difference between two adjacent loss values ​​is less than a predetermined value, it is considered that the optimal topology result is obtained, as shown below: |L i -L i-1 |≤τ Among them, L i is the neural network loss value at the i-th iteration, L i-1 is the neural network loss value at the last iteration, and τ is a predefined threshold used to determine whether the loss value is stable; When the iteration result meets the stopping condition, the optimization process is completed and the optimized material distribution, that is, the optimal topology result, is output.