Clothing cloth dynamic simulation method and device, electronic equipment and storage medium

By constructing the target Heisen matrix of clothing fabrics and using the implicit time integral algorithm, the problems of high calculation cost and poor simulation results of clothing fabrics in the prior art are solved, and stable and efficient dynamic simulation results are achieved.

CN120032073APending Publication Date: 2025-05-23LINGDI (ZHEJIANG) TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311577230.X
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-11-23
Publication Date
2025-05-23

AI Technical Summary

Technical Problem

The prior art has high calculation cost in dynamic simulation of clothing fabrics, making it difficult to ensure stable and efficient simulation results, resulting in insufficient real-time and realistic simulation effects.

Method used

By using the cloth mesh model of the cloth to be simulated, all dihedral angle units in each grid are obtained, and the target Heisen matrix is ​​constructed in combination with the multi-motion mode matrix and dihedral angle information matrix. The implicit time integral algorithm is used to determine the vertex displacement of the grid and update the cloth mesh model.

Benefits of technology

It realizes dynamic simulation of clothing fabrics stably and efficiently, and optimizes the simulation effect to make it more realistic.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120032073A_ABST
    Figure CN120032073A_ABST
Patent Text Reader

Abstract

The embodiment of the invention provides a clothing fabric dynamic simulation method and device, electronic equipment and a storage medium, and relates to the technical field of clothing simulation. The clothing fabric dynamic simulation method comprises the following steps: acquiring all dihedral angle units in each grid based on a fabric grid model of to-be-simulated fabric; for each dihedral angle unit, combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit to construct a target Hessian matrix of the dihedral angle unit; determining vertex displacements of all the grids by adopting an implicit time integration algorithm and combining the target Hessian matrixes of all the dihedral angle units; and adjusting the cloth grid model according to the vertex displacement of all the grids to obtain an updated cloth grid model. According to the embodiment of the invention, the technical effects of stably and efficiently performing dynamic simulation on the garment fabric and optimizing the dynamic simulation effect of the garment fabric can be achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of clothing simulation, and in particular to a clothing fabric dynamic simulation method, device, electronic equipment and storage medium. Background Art

[0002] At present, in order to meet the personalized needs of users, solutions such as virtual fitting and virtual clothing making are provided. In application scenarios such as virtual fitting and virtual clothing making, physics-based methods are mainly used, such as dihedral bending models to simulate the changes in the appearance of clothing fabrics, such as ups and downs, wrinkles, and folds.

[0003] Dynamic simulation of clothing fabrics based on a dihedral bending model is usually achieved by predicting the changes in features in the dihedral bending model. However, the features in the dihedral bending model are relatively complex and difficult to understand, and the computational cost required to predict the changes in feature values ​​in the dihedral bending model is also high. This makes it impossible to ensure stable and efficient dynamic simulation of clothing fabrics and make the dynamic simulation effect of clothing fabrics more real-time and realistic. Summary of the invention

[0004] The purpose of the embodiments of the present invention is to provide a method, device, electronic device and storage medium for dynamic simulation of clothing fabrics, so as to achieve the technical effect of stably and efficiently performing dynamic simulation on clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0005] In a first aspect, an embodiment of the present invention provides a clothing fabric dynamic simulation method, comprising:

[0006] Based on the cloth mesh model of the cloth to be simulated, all dihedral angle units in each mesh are obtained;

[0007] For each of the dihedral angle units, combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit to construct a target Hessian matrix of the dihedral angle unit;

[0008] Determining the vertex displacements of all the meshes using an implicit time integration algorithm in combination with target Hessian matrices of all the dihedral elements;

[0009] The cloth mesh model is adjusted according to the vertex displacements of all the meshes to obtain an updated cloth mesh model.

[0010] In the above implementation process, based on the cloth mesh model of the cloth to be simulated, the multi-motion mode matrix and the dihedral information matrix of each dihedral angle unit are determined to construct the target Hessian matrix of each dihedral angle unit, and the implicit time integration algorithm is used to combine the target Hessian matrices of all dihedral angle units for dynamic simulation, which can stably and efficiently perform dynamic simulation of clothing fabrics and optimize the dynamic simulation effect of clothing fabrics.

[0011] Furthermore, for each of the dihedral angle units, combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit to construct a target Hessian matrix of the dihedral angle unit specifically includes:

[0012] For each of the dihedral angle units, constructing 12 motion mode displacement vectors of the dihedral angle unit according to the structural parameters of the dihedral angle unit;

[0013] Combining the 12 motion mode displacement vectors of the dihedral unit, generating a multi-motion mode matrix of the dihedral unit;

[0014] Generate a coefficient matrix of the dihedral unit according to an invariant subspace of an original Hessian matrix of the dihedral unit;

[0015] Combining the multi-motion mode matrix and the coefficient matrix of the dihedral unit to generate a dihedral information matrix of the dihedral unit;

[0016] Eliminating negative eigenvalues ​​in an eigenvalue matrix corresponding to a dihedral angle information matrix of the dihedral angle unit to obtain a target information matrix of the dihedral angle unit;

[0017] The target Hessian matrix of the dihedral unit is constructed by combining the multi-motion mode matrix and the target information matrix of the dihedral unit.

[0018] In the above implementation process, by constructing 12 motion mode displacement vectors of the dihedral angle unit according to the structural parameters of the dihedral angle unit, and constructing the target Hessian matrix of the dihedral angle unit based on the 12 motion mode displacement vectors of the dihedral angle unit, the 12 motion mode displacement vectors of all dihedral angle units can be finely analyzed in the subsequent dynamic simulation process, and the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be completely eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby more stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0019] Furthermore, the 12 motion mode displacement vectors of the dihedral unit are respectively:

[0020]

[0021]

[0022]

[0023]

[0024] Among them, v i is the i+1th motion mode displacement vector of the dihedral unit, i=(0,1,...,11), n 1 is the normal vector of a unit face of the dihedral element, n 2 is the normal vector of the other unit face of the dihedral element, m 1 is the height vector of a unit face of the dihedral element, m 2 is the normal vector of the other unit face of the dihedral unit, e is the edge vector of the unit edge of the dihedral unit, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, [·] T Represents the transpose of a matrix.

[0025] In the above implementation process, by constructing 12 motion mode displacement vectors of the dihedral angle unit according to the structural parameters of the dihedral angle unit according to the above formula, the 12 motion mode displacement vectors of all dihedral angle units can be finely analyzed in the subsequent dynamic simulation process, and the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be completely eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby more stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0026] Furthermore, the multi-motion mode matrix of the dihedral unit is:

[0027] Z=[z 0 ,z 1 ,z 2 ,z 3 ,z 4 ,z 5 ,z 6 ,z 7 ];

[0028] Wherein, Z is the multi-motion mode matrix of the dihedral unit, represents a real number, t 1 =h 1 -1 [ω 1 -1,-ω 1 ,1,0] T ,h1 is the height of a vertex on a unit face of the dihedral unit relative to the unit edge, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, t 2 =h 2 -1 [ω 2 -1,-ω 2 ,1,0] T ,h 2 is the height of the vertex on the other unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral unit relative to the unit edge, n 1 is the normal vector of a unit face of the dihedral element, m 1 is the height vector of a unit face of the dihedral unit, s=l -1 [1,-1,0,0] T , l is the length of the unit side of the dihedral unit, e is the edge vector of the unit side of the dihedral unit, [·] T Represents the transpose of a matrix.

[0029] In the above implementation process, by combining the 12 motion mode displacement vectors of the dihedral angle unit according to the above formula, a multi-motion mode matrix of the dihedral angle unit is generated, and the 12 motion mode displacement vectors of all dihedral angle units can be finely analyzed in the subsequent dynamic simulation process, and the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be completely eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby more stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0030] Furthermore, the dihedral angle information matrix of the dihedral angle unit is:

[0031]

[0032] Wherein, F is the dihedral angle information matrix of the dihedral angle unit, is the bending potential energy of the dihedral angle unit, and θ is the angle between two unit faces of the dihedral angle unit.

[0033] In the above implementation process, the dihedral angle information matrix of the dihedral angle unit is generated by combining the multi-motion mode matrix and the coefficient matrix of the dihedral angle unit according to the above formula. In the subsequent process of dynamic simulation using an implicit time integration algorithm combined with the target Hessian matrix of all dihedral angle units, the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be directly eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0034] Furthermore, the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0035]

[0036] Wherein, Λ is the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit, λ 1 =g, λ 3 =-g,

[0037] The eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0038]

[0039] Wherein, E is the eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit, [·] T Represents the transpose of a matrix.

[0040] In the above implementation process, by constructing the eigenvalue matrix and eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit according to the above formula, it is possible to directly eliminate the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit in the subsequent dynamic simulation process using the implicit time integration algorithm combined with the target Hessian matrix of all dihedral angle units to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, stably and efficiently perform dynamic simulation of clothing fabrics, and optimize the dynamic simulation effect of clothing fabrics.

[0041] Furthermore, the target information matrix of the dihedral angle unit is:

[0042] F′=EΛ′E T ;

[0043] Where F′ is the target information matrix of the dihedral unit, E Tis the transposed matrix of the eigenvector matrix corresponding to the dihedral information matrix of the dihedral unit, Λ′ is the eigenvalue matrix corresponding to the target information matrix of the dihedral unit, λ 0 ′=max(λ 0 ,0),λ 1 ′=max(λ 1 ,0),λ 2 ′=max(λ 2 ,0),λ 3 ′=max(λ 3 ,0),λ 4 ′=max(λ 4 ,0),λ 5 ′=max(λ 5 ,0),λ 6 ′=max(λ 6 ,0),λ 7 ′=max(λ 7 ,0).

[0044] In the above implementation process, by constructing the target information matrix of the dihedral angle unit according to the above formula, it is possible to quickly eliminate the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit in the subsequent dynamic simulation process using the implicit time integration algorithm combined with the target Hessian matrix of all dihedral angle units to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, stably and efficiently perform dynamic simulation of clothing fabrics, and optimize the dynamic simulation effect of clothing fabrics.

[0045] Furthermore, the target Hessian matrix of the dihedral unit is:

[0046] H d =ZF′Z T ;

[0047] Among them, H d is the target Hessian matrix of the dihedral unit; Z is the multi-motion mode matrix of the dihedral unit, Z T is the transposed matrix of the multi-motion mode matrix of the dihedral unit, and F′ is the target information matrix of the dihedral unit.

[0048] In the above implementation process, by combining the multi-motion mode matrix and the target information matrix of the dihedral unit according to the above formula, a target Hessian matrix of the dihedral unit is constructed. In the subsequent dynamic simulation process using an implicit time integration algorithm combined with the target Hessian matrices of all dihedral units, the negative eigenvalues ​​in the dihedral information matrix of the dihedral unit can be directly eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral unit, thereby stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0049] Furthermore, the implicit time integration algorithm is used to determine the vertex displacements of all the meshes in combination with the target Hessian matrix of all the dihedral units, specifically including:

[0050] Traversing each of the meshes, obtaining vertex parameters and simulation parameters of the current mesh, and obtaining physical parameters of the cloth to be simulated;

[0051] Combining the target Hessian matrices of all the dihedral elements in the current grid, establishing the dynamic equation of the current grid;

[0052] An implicit time integration algorithm is adopted to solve the dynamic equation of the current mesh according to the vertex parameters and simulation parameters of the current mesh and the physical parameters of the cloth to be simulated, so as to obtain the vertex displacement of the current mesh.

[0053] In the above implementation process, the dynamic equation of each grid is established by combining the target Hessian matrix of all dihedral units in each grid respectively. The implicit time integration algorithm is used to solve the dynamic equation of each grid according to the vertex parameters and simulation parameters of each grid and the physical parameters of the fabric to be simulated. The vertex displacement of each grid is obtained, which can ensure stable and efficient dynamic simulation of clothing fabrics and optimize the dynamic simulation effect of clothing fabrics.

[0054] Furthermore, the dynamic equation of the current grid is:

[0055] H x Δx=-g x ;

[0056] Among them, H x is the target Hessian matrix of all the dihedral elements in the current grid, Δx is the vertex displacement of the current grid, g x is the optimization gradient of the current grid.

[0057] In the above implementation process, by selecting the above linear equation as the dynamic equation of the current grid, the implicit time integration algorithm is used to solve the dynamic equation of each grid according to the vertex parameters and simulation parameters of each grid, as well as the physical parameters of the cloth to be simulated, and the vertex displacement of each grid is obtained, which can ensure stable and efficient dynamic simulation of clothing fabrics and optimize the dynamic simulation effect of clothing fabrics.

[0058] In a second aspect, an embodiment of the present invention provides a clothing fabric dynamic simulation device, comprising:

[0059] An acquisition module, used for acquiring all dihedral angle units in each mesh based on a cloth mesh model of the cloth to be simulated;

[0060] A construction module, configured to construct, for each dihedral angle unit, a target Hessian matrix of the dihedral angle unit by combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit;

[0061] A calculation module, for determining the vertex displacements of all the meshes by using an implicit time integration algorithm in combination with target Hessian matrices of all the dihedral elements;

[0062] The adjustment module is used to adjust the cloth mesh model according to the vertex displacements of all the meshes to obtain an updated cloth mesh model.

[0063] In a third aspect, an embodiment of the present invention provides an electronic device, comprising a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor; the memory is coupled to the processor, and when the processor executes the computer program, the dynamic simulation method of clothing fabric as described above is implemented.

[0064] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium includes a stored computer program; wherein, when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute the clothing fabric dynamic simulation method as described above. BRIEF DESCRIPTION OF THE DRAWINGS

[0065] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for use in the embodiments of the present invention are briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without creative work.

[0066] Figure 1 A schematic flow chart of a method for dynamic simulation of clothing fabrics provided by the first embodiment of the present invention;

[0067] Figure 2 A three-dimensional diagram of a dihedral angle unit according to an alternative embodiment of the first embodiment of the present invention;

[0068] Figure 3 A side view of a dihedral angle unit according to an alternative embodiment of the first embodiment of the present invention;

[0069] Figure 4 A plan view of a unit face of a dihedral angle element according to an alternative embodiment of the first embodiment of the present invention;

[0070] Figure 5A plan view of another unit face of a dihedral angle element according to an alternative embodiment of the first embodiment of the present invention;

[0071] Figure 6 A schematic diagram of an edge vector of a unit edge of a dihedral angle unit according to an alternative embodiment of the first embodiment of the present invention;

[0072] Figure 7 A schematic diagram of a height vector of a unit face of a dihedral angle unit according to an alternative embodiment of the first embodiment of the present invention;

[0073] Figure 8 A schematic diagram of a normal vector of a unit face of a dihedral angle unit according to an alternative embodiment of the first embodiment of the present invention;

[0074] Fig. 9 The matrix F is an example of an alternative embodiment of the first embodiment of the present invention. 0 Schematic diagram of the eigenvalues ​​in ;

[0075] Fig.10 The matrix F is an example of an alternative embodiment of the first embodiment of the present invention. 1 A schematic diagram of the eigenvalues ​​in ;

[0076] Fig.11 A schematic diagram of a process of dynamically simulating a cloth to be simulated by using an implicit time integration algorithm according to an optional embodiment of the first embodiment of the present invention;

[0077] Fig.12 A schematic structural diagram of a clothing fabric dynamic simulation device provided by a second embodiment of the present invention;

[0078] Fig.13 A schematic structural diagram of an electronic device provided in the third embodiment of the present invention. DETAILED DESCRIPTION

[0079] The technical solutions in the embodiments of the present invention will be described below in conjunction with the accompanying drawings in the embodiments of the present invention.

[0080] It should be noted that in the description of the present invention, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance. At the same time, the step numbers in the text are only for the convenience of explaining the embodiments of the present invention and do not serve to limit the order of execution of the steps. The method provided in the embodiment of the present invention can be executed by a related terminal device, and the following description will be taken as an example of a processor as the execution subject.

[0081] Please see Figure 1 , Figure 1The first embodiment of the present invention provides a method for dynamic simulation of clothing fabrics, comprising steps S101 to S104:

[0082] S101, based on the cloth mesh model of the cloth to be simulated, obtaining all dihedral angle units in each mesh;

[0083] S102, for each dihedral angle unit, combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit to construct a target Hessian matrix of the dihedral angle unit;

[0084] S103, using an implicit time integration algorithm, combined with the target Hessian matrix of all dihedral units, to determine the vertex displacements of all grids;

[0085] S104. Adjust the cloth mesh model according to the vertex displacements of all meshes to obtain an updated cloth mesh model.

[0086] As an exemplary embodiment, a cloth mesh model of the cloth to be simulated is obtained, where the cloth mesh model of the cloth to be simulated is obtained by splicing a plurality of meshes, and each mesh has at least one dihedral unit.

[0087] Based on the cloth mesh model of the cloth to be simulated, all dihedral angle units in each mesh are obtained to obtain all dihedral angle units.

[0088] For each dihedral unit, a multi-motion mode matrix and a dihedral information matrix of the dihedral unit are determined, and a target Hessian matrix of the dihedral unit is constructed by combining the multi-motion mode matrix and the dihedral information matrix of the dihedral unit to obtain the target Hessian matrices of all dihedral units.

[0089] An implicit time integration algorithm is used to determine the vertex displacements of all meshes in combination with the target Hessian matrices of all dihedral elements.

[0090] The vertex positions of each mesh on the cloth mesh model are adjusted according to the vertex displacement of each mesh, that is, the vertex positions of all dihedral units in each mesh, to obtain an updated cloth mesh model, thereby completing the dynamic simulation of the cloth to be simulated.

[0091] Since the target Hessian matrix of the dihedral angle unit is constructed based on the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit, in the process of dynamic simulation using the implicit time integration algorithm combined with the target Hessian matrices of all dihedral angle units, the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be directly eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, so as to stably and efficiently perform dynamic simulation of clothing fabrics and optimize the dynamic simulation effect of clothing fabrics.

[0092] The embodiment of the present invention determines the multi-motion mode matrix and the dihedral information matrix of each dihedral unit based on the cloth mesh model of the cloth to be simulated to construct a target Hessian matrix of each dihedral unit, and uses an implicit time integration algorithm to combine the target Hessian matrices of all dihedral units for dynamic simulation. It is possible to stably and efficiently perform dynamic simulation on clothing fabrics and optimize the dynamic simulation effect of clothing fabrics.

[0093] In an optional embodiment, for each dihedral angle unit, a target Hessian matrix of the dihedral angle unit is constructed by combining a multi-motion mode matrix and a dihedral angle information matrix of the dihedral angle unit, specifically including: for each dihedral angle unit, 12 motion mode displacement vectors of the dihedral angle unit are constructed according to the structural parameters of the dihedral angle unit; a multi-motion mode matrix of the dihedral angle unit is generated by combining the 12 motion mode displacement vectors of the dihedral angle unit; a coefficient matrix of the dihedral angle unit is generated according to the invariant subspace of the original Hessian matrix of the dihedral angle unit; a dihedral angle information matrix of the dihedral angle unit is generated by combining the multi-motion mode matrix and the coefficient matrix of the dihedral angle unit; negative eigenvalues ​​in the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit are eliminated to obtain the target information matrix of the dihedral angle unit; and a target Hessian matrix of the dihedral angle unit is constructed by combining the multi-motion mode matrix and the target information matrix of the dihedral angle unit.

[0094] As an example, for each dihedral angle unit, the structural parameters of the dihedral angle unit are obtained, wherein the structural parameters of the dihedral angle unit include vertex parameters, unit face parameters and unit edge parameters of the dihedral angle unit, the vertex parameters of the dihedral angle unit include the three-dimensional positions of all vertices constituting the dihedral angle unit, the unit face parameters of the dihedral angle unit include the heights and center of gravity of the vertices on two unit faces constituting the dihedral angle unit relative to the unit edge, as well as the normal vectors and height vectors of the two unit faces, and the unit edge parameters include the length and edge vector of the unit edge constituting the dihedral angle unit.

[0095] Considering the 12 basic motion modes of the dihedral unit, the 12 motion mode displacement vectors of the dihedral unit are constructed according to the structural parameters of the dihedral unit.

[0096] The 12 motion mode displacement vectors of the dihedral unit are combined to generate a multi-motion mode matrix of the dihedral unit.

[0097] Generate a coefficient matrix for the dihedral element based on the invariant subspace of the original Hessian matrix of the dihedral element.

[0098] The multi-motion mode matrix and the coefficient matrix of the dihedral unit are combined to generate the dihedral information matrix of the dihedral unit.

[0099] According to the dihedral angle information matrix of the dihedral angle unit, the eigenvalue matrix and eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit can be constructed, and the negative eigenvalues ​​in the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit can be eliminated to obtain the target information matrix of the dihedral angle unit.

[0100] The target Hessian matrix of the dihedral unit is constructed by combining the multi-motion mode matrix and the target information matrix of the dihedral unit.

[0101] The embodiment of the present invention constructs 12 motion mode displacement vectors of the dihedral angle unit according to the structural parameters of the dihedral angle unit, and constructs the target Hessian matrix of the dihedral angle unit based on the 12 motion mode displacement vectors of the dihedral angle unit. In the subsequent dynamic simulation process, the 12 motion mode displacement vectors of all dihedral angle units can be finely analyzed, and the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be completely eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby more stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0102] In an optional embodiment, the 12 motion mode displacement vectors of the dihedral unit are:

[0103]

[0104] Among them, v i is the i+1th motion mode displacement vector of the dihedral unit, i=(0,1,...,11), n 1 is the normal vector of a unit face of the dihedral unit, n 2 is the normal vector of the other unit face of the dihedral element, m 1 is the height vector of a unit face of the dihedral unit, m 2 is the normal vector of the other unit face of the dihedral unit, e is the edge vector of the unit edge of the dihedral unit, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, [·] T Represents the transpose of a matrix.

[0105] As an example, assume that the stereogram of the dihedral unit is Figure 2 The side view of the dihedral unit is shown in Figure 3 As shown, the plan view of a unit face of a dihedral unit is Figure 4 As shown, the plan view of the other unit face of the dihedral unit is Figure 5 As shown, according to Figure 2 It can be seen that the dihedral unit consists of 4 vertices X = [X 0 ,X 1,X 2 ,X 3 ], where X 0 , X 1 , X 2 , X 3 are the three-dimensional position coordinates of the first, second, third, and fourth vertices that constitute the dihedral unit. A unit face of a dihedral unit consists of three vertices [X 0 ,X 1 ,X 2 ], the other unit face of the dihedral unit consists of three vertices [X 0 ,X 1 ,X 3 ], the unit edge of the dihedral unit consists of two vertices [X 0 ,X 1 ], the length of the unit side of the dihedral unit is l = ||X 1 -X 0 ||, where ||·|| represents the vector modulus, and the edge vector of the unit edge of the dihedral unit is e=(X 1 -X 0 ) / l, the angle between the two unit faces of the dihedral angle unit, that is, the dihedral angle is θ; according to Figure 3 It can be seen that the normal vector of a unit face of a dihedral unit is n 1 , the normal vector of the other unit face of the dihedral element is n 2 ;according to Figure 4 It can be seen that the vertex X on a unit face of the dihedral unit 2 The height relative to the unit side is h 1 , the vertex X on a unit face of the dihedral unit 2 The center of gravity relative to the unit side is ω 1 , the height vector of a unit face of the dihedral unit is m 1 ;according to Figure 5 It can be seen that the vertex X on the other unit face of the dihedral unit 3 The height relative to the unit side is h 2 , the vertex X on the other unit face of the dihedral unit 3 The center of gravity relative to the unit side is ω 2 , the height vector of the other unit face of the dihedral unit is m 2 .

[0106] The energy function of the dihedral bending model is Among them, E(X) is the bending potential energy function of the dihedral angle unit, and its independent variable is the three-dimensional position coordinates of the vertex of the dihedral angle unit, is the bending potential energy function of the dihedral unit, and its independent variable is the dihedral angle of the dihedral unit. The Hessian matrix corresponding to the dihedral bending model is H = pP + gG, where P is the projection matrix in the gradient direction, X is all the vertices of the dihedral unit, (·) T represents the transposed matrix of the matrix, G is the geometric stiffness matrix, is the bending potential energy of the dihedral unit, Specifically, the gradient of the dihedral angle θ with respect to vertex X is The geometric stiffness matrix can be expressed as G = G m +G e ,in, With G e =B 1 +B 1 T +B 2 +B 2 T There are two important components, t 1 =h 1 -1 [ω 1 -1,-ω 1 ,1,0] T , t 2 =h 2 -1 [ω 2 -1,-ω 2 ,1,0] T , s = l -1 [1,-1,0,0] T .

[0107] A dihedral unit has 12 basic motion modes, and the corresponding displacement vectors are: 3 translation vectors, 1 vector uniformly scaled along the unit edge of the dihedral unit, 2 vectors about the sliding of the vertex on the unit face of the dihedral unit relative to the center of gravity of the unit edge, 2 vectors about the height change of the vertex on the unit face of the dihedral unit relative to the unit edge, 2 vectors about the bending motion of the dihedral unit, and 2 vectors about the rotation motion of the dihedral unit. It can be understood that the schematic diagram of the edge vector of the unit edge of the dihedral unit is as follows Figure 6 As shown, the schematic diagram of the height vector of the unit face of the dihedral unit is as follows Figure 7 As shown, the schematic diagram of the normal vector of the unit face of the dihedral unit is as follows Figure 8 shown.

[0108] According to the structural parameters of the dihedral unit, 12 motion mode displacement vectors of the dihedral unit are constructed. The 12 motion mode displacement vectors of the dihedral unit are:

[0109]

[0110] In formulas (1)-(12), vi is the i+1th motion mode displacement vector of the dihedral unit, i=(0,1,...,11), n 1 is the normal vector of a unit face of the dihedral unit, n 2 is the normal vector of the other unit face of the dihedral element, m 1 is the height vector of a unit face of the dihedral unit, m 2 is the normal vector of the other unit face of the dihedral unit, e is the edge vector of the unit edge of the dihedral unit, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, [·] T Represents the transpose of a matrix.

[0111] The original Hessian matrix H of the dihedral unit is respectively combined with the 12 motion mode displacement vectors {v 0 ,v 1 ,v 2 ,v 3 ,v 4 ,v 5 ,v 6 ,v 7 ,v 8 ,v 9 ,v 10 ,v 11}interaction, we can get:

[0112] Hv 0 =0 (13); Hv 1 =0 (14); Hv 2 =0 (15);

[0113] Hv 3 =0 (16);

[0114]

[0115] In formulas (15)-(24), is the bending potential energy of the dihedral unit, is the change in the dihedral angle of the dihedral unit.

[0116] The embodiment of the present invention constructs 12 motion mode displacement vectors of the dihedral angle unit according to the structural parameters of the dihedral angle unit according to the above formula, and can finely analyze the 12 motion mode displacement vectors of all dihedral angle units in the subsequent dynamic simulation process, and completely eliminate the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby more stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0117] In an optional embodiment, the multi-motion mode matrix of the dihedral unit is:

[0118] Z=[z 0 ,z 1 ,z 2 ,z 3 ,z 4 ,z 5 ,z 6 ,z 7 ] (25);

[0119] Where Z is the multi-motion mode matrix of the dihedral unit, represents a real number, t 1 =h 1 -1 [ω 1 -1,-ω 1 ,1,0] T ,h 1 is the height of a vertex on a unit face of a dihedral unit relative to the unit edge, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, t 2 =h 2 -1 [ω 2 -1,-ω 2 ,1,0] T ,h 2 is the height of the vertex on the other unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, n 1 is the normal vector of a unit face of the dihedral unit, m 1 is the height vector of a unit face of the dihedral unit, s = l -1 [1,-1,0,0] T , l is the length of the unit side of the dihedral element, e is the edge vector of the unit side of the dihedral element, [·] T Represents the transpose of a matrix.

[0120] As an example, after obtaining the 12 motion mode displacement vectors {v 0 ,v 1 ,v 2 ,v 3 ,v 4 ,v 5 ,v 6 ,v 7 ,v 8 ,v 9 ,v 10 ,v 11}, combined with the 12 motion mode displacement vectors {v 0 ,v 1 ,v 2 ,v 3 ,v 4 ,v 5 ,v 6 ,v 7 ,v 8 ,v 9 ,v 10 ,v 11}, generate the multi-motion mode matrix of the dihedral unit, the multi-motion mode matrix of the dihedral unit is:

[0121] Z=[z 0 ,z 1 ,z 2 ,z 3 ,z 4 ,z 5 ,z 6 ,z 7 ] (25);

[0122] In formula (25), Z is the multi-motion mode matrix of the dihedral unit, represents a real number, t 1 =h 1 -1 [ω 1 -1,-ω 1 ,1,0] T ,h 1 is the height of a vertex on a unit face of a dihedral unit relative to the unit edge, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, t 2 =h 2 -1 [ω 2 -1,-ω 2 ,1,0] T ,h 2 is the height of the vertex on the other unit face of the dihedral unit relative to the unit edge, ω2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, n 1 is the normal vector of a unit face of the dihedral unit, m 1 is the height vector of a unit face of the dihedral unit, s = l -1 [1,-1,0,0] T , l is the length of the unit side of the dihedral element, e is the edge vector of the unit side of the dihedral element, [·] T Represents the transpose of a matrix.

[0123] The embodiment of the present invention generates a multi-motion mode matrix of the dihedral unit by combining the 12 motion mode displacement vectors of the dihedral unit according to the above formula, and can finely analyze the 12 motion mode displacement vectors of all dihedral units in the subsequent dynamic simulation process, and completely eliminate the negative eigenvalues ​​in the dihedral information matrix of the dihedral unit to restore the semi-positive definiteness of the target Hessian matrix of the dihedral unit, thereby more stably and efficiently performing dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0124] In an optional embodiment, the dihedral angle information matrix of the dihedral angle unit is:

[0125]

[0126] Where F is the dihedral angle information matrix of the dihedral angle unit,

[0127]

[0128] is the bending potential energy of the dihedral unit, and θ is the angle between the two unit faces of the dihedral unit.

[0129] As an example, when the multi-motion mode matrix Z of the dihedral unit is obtained, the eight column vectors {z 0 ,z 1 ,z 2 ,z 3 ,z 4 ,z 5 ,z 6 ,z 7}In Hv i Recurring in .

[0130] By interacting the original Hessian matrix H of the dihedral unit with the multi-motion mode matrix Z of the dihedral unit, HZ=ZC can be obtained, where C is the coefficient matrix of the dihedral unit, Therefore, the column vector space of the multi-motion mode matrix Z of the dihedral unit is an invariant subspace of the original Hessian matrix H of the dihedral unit.

[0131] According to the invariant subspace of the original Hessian matrix H of the dihedral unit, the coefficient matrix of the dihedral unit is generated. The coefficient matrix of the dihedral unit is C = FZ T Z.

[0132] Since C = FZ T Z, combined with the multi-motion mode matrix Z and coefficient matrix C of the dihedral unit, generates the dihedral information matrix of the dihedral unit. The dihedral information matrix of the dihedral unit contains the basic bending information of the dihedral unit and is a matrix consisting of two The block diagonal matrix of the matrix, the dihedral information matrix of the dihedral unit is:

[0133]

[0134] In formula (26), F is the dihedral angle information matrix of the dihedral angle unit,

[0135] is the bending potential energy of the dihedral unit, and θ is the angle between the two unit faces of the dihedral unit.

[0136] The embodiment of the present invention generates a dihedral angle information matrix of a dihedral angle unit by combining the multi-motion mode matrix and the coefficient matrix of the dihedral angle unit according to the above formula. In the subsequent process of dynamic simulation using an implicit time integration algorithm combined with the target Hessian matrix of all dihedral angle units, the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be directly eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby stably and efficiently performing dynamic simulation on clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0137] In an optional embodiment, the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0138]

[0139] Where Λ is the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit, λ 1 =g, λ 3 =-g,

[0140] The eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0141]

[0142] Where E is the eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit,

[0143]

[0144] [·] T Represents the transpose of a matrix.

[0145] As an exemplary embodiment, when the dihedral angle information matrix F of the dihedral angle unit is obtained, the eigenvalue matrix and the eigenvector matrix corresponding to the dihedral angle information matrix F of the dihedral angle unit are constructed.

[0146] Since the dihedral angle information matrix F of the dihedral angle unit is a block diagonal matrix, constructing the eigenvalue matrix and eigenvector matrix corresponding to the dihedral angle information matrix F of the dihedral angle unit can be simplified to solving two two The eigenvalue matrix and eigenvector matrix corresponding to the matrix.

[0147] By symbolic calculation, we can get the matrix F 0 The eigenvalues ​​of are: λ 1 =g, λ 3 = -g; Matrix F 0 The eigenvectors in are: The corresponding eigenvector general solution expression is:

[0148]

[0149] Similarly, through symbolic calculation, we can get the matrix F 1 The eigenvalues ​​of are: Matrix F 1 The eigenvectors in are: The corresponding eigenvector general solution expression is:

[0150]

[0151] So far, we get the matrix F 0 and the matrix F 1 The eigenvalues ​​in and the matrix F 0 and the matrix F 1 The eigenvectors in . Among them, the matrix F 0 The eigenvalues ​​in Fig. 9 As shown, the matrix F 1 The eigenvalues ​​in Fig.10 shown.

[0152] Combination matrix F 0 and the matrix F 1The eigenvalues ​​in construct the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit. The eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0153]

[0154] In formula (27), Λ is the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit, λ 1 =g, λ 3 =-g,

[0155] Combination matrix F 0 and the matrix F 1 The eigenvectors in construct the eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit. The eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0156]

[0157] In formula (28), E is the eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit,

[0158]

[0159] [·] T Represents the transpose of a matrix.

[0160] The embodiment of the present invention constructs the eigenvalue matrix and eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit according to the above formula, and can directly eliminate the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit in the subsequent process of dynamic simulation using an implicit time integration algorithm combined with the target Hessian matrix of all dihedral angle units to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, stably and efficiently perform dynamic simulation on clothing fabrics, and optimize the dynamic simulation effect of clothing fabrics.

[0161] In an optional embodiment, the target information matrix of the dihedral unit is:

[0162] F′=EΛ′E T (31);

[0163] Among them, F′ is the target information matrix of the dihedral unit, E T is the transposed matrix of the eigenvector matrix corresponding to the dihedral information matrix of the dihedral unit, Λ′ is the eigenvalue matrix corresponding to the target information matrix of the dihedral unit, λ 0 ′=max(λ 0 ,0),λ1 ′=max(λ 1 ,0),λ 2 ′=max(λ 2 ,0),λ 3 ′=max(λ 3 ,0),λ 4 ′=max(λ 4 ,0),λ 5 ′=max(λ 5 ,0),λ 6 ′=max(λ 6 ,0),λ 7 ′=max(λ 7 ,0).

[0164] As an example, the original Hessian matrix H of the dihedral unit can be expressed as H = ZFZ T , since the multi-motion mode matrix Z of the dihedral unit is a column full rank matrix, based on Sylvester's law of inertia, it can be known that the original Hessian matrix H of the dihedral unit and the dihedral information matrix F have the same number of positive and negative eigenvalues, so the negative eigenvalues ​​in the original Hessian matrix H of the dihedral unit can be eliminated by eliminating the negative eigenvalues ​​in the dihedral information matrix F of the dihedral unit, thereby restoring the target Hessian matrix H of the dihedral unit d The positive semidefiniteness of .

[0165] When the eigenvalue matrix Λ and the eigenvector matrix E corresponding to the dihedral angle information matrix F of the dihedral angle unit are obtained, it can be determined that the eigenvalues ​​in the eigenvalue matrix Λ corresponding to the dihedral angle information matrix F of the dihedral angle unit are: 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 , and 0 , 1 , 2 , 3 , 4 , 5 , 6 , 7 The negative eigenvalues ​​in are updated to 0, and the new eigenvalues ​​are: 0 ′=max(λ 0 ,0),λ 1 ′=max(λ 1 ,0),λ 2 ′=max(λ 2 ,0),λ3 ′=max(λ 3 ,0),λ 4 ′=max(λ 4 ,0),λ 5 ′=max(λ 5 ,0),λ 6 ′=max(λ 6 ,0),λ 7 ′=max(λ 7 ,0), combined with all new eigenvalues, construct the eigenvalue matrix corresponding to the target information matrix F′ of the dihedral angle unit

[0166]

[0167] Combining the eigenvector matrix E corresponding to the dihedral angle information matrix F of the dihedral angle unit and the eigenvalue matrix Λ′ corresponding to the target information matrix of the dihedral angle unit, the target information matrix F′=EΛ′E of the dihedral angle unit is obtained. T .

[0168] The embodiment of the present invention constructs a target information matrix of a dihedral angle unit according to the above formula, and can quickly eliminate the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit in the subsequent process of dynamic simulation using an implicit time integration algorithm combined with the target Hessian matrix of all dihedral angle units to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, stably and efficiently perform dynamic simulation on clothing fabrics, and optimize the dynamic simulation effect of clothing fabrics.

[0169] In an optional embodiment, the target Hessian matrix of the dihedral unit is:

[0170] H d =ZF′Z T (32);

[0171] Among them, H d is the target Hessian matrix of the dihedral unit; Z is the multi-motion mode matrix of the dihedral unit, Z T is the transposed matrix of the multi-motion mode matrix of the dihedral unit, and F′ is the target information matrix of the dihedral unit.

[0172] As an example, when the multi-motion mode matrix Z and the target information matrix F′ of the dihedral unit are obtained, the target Hessian matrix H of the dihedral unit is constructed by combining the multi-motion mode matrix Z and the target information matrix F′ of the dihedral unit. d =ZF′Z T .

[0173] The embodiment of the present invention constructs a target Hessian matrix of a dihedral angle unit by combining the multi-motion mode matrix and the target information matrix of the dihedral angle unit according to the above formula. In the subsequent process of dynamic simulation using an implicit time integration algorithm in combination with the target Hessian matrices of all dihedral angle units, the negative eigenvalues ​​in the dihedral angle information matrix of the dihedral angle unit can be directly eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral angle unit, thereby stably and efficiently performing dynamic simulation on clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0174] In an optional embodiment, the implicit time integration algorithm is used in combination with the target Hessian matrix of all dihedral units to determine the vertex displacement of all meshes, specifically including: traversing each mesh to obtain the vertex parameters and simulation parameters of the current mesh, and obtaining the physical parameters of the cloth to be simulated; combining the target Hessian matrix of all dihedral units in the current mesh to establish the dynamic equation of the current mesh; using the implicit time integration algorithm, according to the vertex parameters and simulation parameters of the current mesh, and the physical parameters of the cloth to be simulated, solve the dynamic equation of the current mesh to obtain the vertex displacement of the current mesh.

[0175] As an example, in the process of performing dynamic simulation on the cloth to be simulated, an implicit time integration algorithm can be used to solve the dynamic equations of the cloth to be simulated.

[0176] Based on the cloth simulation model of the cloth to be simulated, traverse each mesh, obtain the vertex parameters and simulation parameters of the current mesh, and obtain the physical parameters of the cloth to be simulated. Among them, the vertex parameters of the current mesh include the vertex parameters of all dihedral units in the current mesh, and the vertex parameters of the current mesh include the three-dimensional position, force, velocity, acceleration, and mass of all vertices constituting each dihedral unit in the current mesh. The simulation parameters of the current mesh include the time step, strain potential energy, and bending potential energy of the current mesh. The physical parameters of the cloth to be simulated include the strain strength and bending strength of the cloth to be simulated.

[0177] Assume that there are n vertices in the current grid x=[x 0 ,x 1 ,...,x n ], x 0 、x 1 , ..., x n are the three-dimensional position coordinates of the 1st, 2nd, ..., nth vertices in the current grid, The force on all vertices is f = [f 0 ,f 1 ,...,f n ], f 0 、f 1 , ..., f nare the forces on the 1st, 2nd, ..., nth vertices in the current grid respectively; the velocity of all vertices is v = [v 0 ,v 1 ,...,v n ],v 0 、v 1 ,...,v n are the velocities of the 1st, 2nd, ..., nth vertices in the current grid, The acceleration of all vertices is a = [a 0 ,a 1 ,...,a n ], a 0 、a 1 , ..., a n are the accelerations of the 1st, 2nd, ..., nth vertices in the current grid, The mass matrix of all vertices is m 0 、m 1 ,...,m n are the velocity masses of the 1st, 2nd, ..., nth vertices in the current grid. Assume that the time step of the current grid is Δt and the strain potential energy is E s , bending potential energy is E b Assume that the strain strength of the cloth to be simulated is k s , bending strength is k b .

[0178] According to Newton's second law of motion, the motion equation Ma = f can be obtained. Since there is strain potential energy E inside the current grid s and bending potential energy E b , so the force is a function of the three-dimensional positions of all vertices in the current mesh, that is, f=f(x).

[0179] It is known that at time t, the three-dimensional positions x of all vertices in the current mesh are t With speed v t The goal of implicit time integration is to calculate the position x of all vertices in the current mesh at the next time t+1. t+1 With speed v t+1 At time t+1, the acceleration of all vertices in the current mesh can be equivalently expressed as a t+1 =(x t+1 -x t -v t Δt) / (Δt) 2 , so the equation of motion Ma=f can be equivalently expressed as an optimization problem, that is, the objective function Where E(x) is the potential energy stored in the current grid, including the strain potential energy E s(x) and bending potential energy E b (x), that is, E(x)=E s (x)+E b (x). Since the potential energy stored in the current grid is a nonlinear function of the three-dimensional positions of all vertices in the current grid, it is necessary to use Newton's method to solve the above optimization problem and calculate the optimization gradient and target Hessian matrix of the objective function, which are as follows:

[0180]

[0181] In formula (33), g x is the optimization gradient of the objective function, f s With f b are strain force and bending force respectively.

[0182]

[0183] In formula (34), H x is the target Hessian matrix of the objective function, and are the strain Hessian matrix and the bending Hessian matrix, k s With k b They are the strain resistance and bending strength of the fabric to be simulated.

[0184] In summary, the vertex displacement of the current mesh can be obtained by solving a dynamic equation H x Δx=-g x The specific process of using implicit time integration algorithm to perform dynamic simulation of simulated cloth is as follows: Fig.11 shown.

[0185] It is understandable that in the implicit time integration framework, the original Hessian matrix of the dihedral bending model is needed To maintain the numerical stability of implicit time integration. However, since the dihedral angle on the unit edge is highly nonlinear and non-convex relative to the three-dimensional position coordinates of the vertices on its adjacent unit face, the characteristics of the eigenvalues ​​and eigenvectors in the original Hessian matrix H of the dihedral bending model are difficult to understand.

[0186] Taking into account that the negative eigenvalues ​​in the original Hessian matrix H of the dihedral bending model are not conducive to the numerical stability of implicit time integration, the multi-motion mode matrix and dihedral information matrix of the dihedral bending model are introduced to construct the target Hessian matrix of the dihedral unit. In the process of dynamic simulation using the implicit time integration algorithm combined with the target Hessian matrices of all dihedral units, the negative eigenvalues ​​in the dihedral information matrix of the dihedral unit can be directly eliminated to restore the semi-positive definiteness of the target Hessian matrix of the dihedral unit, so as to perform dynamic simulation of clothing fabrics stably and efficiently and optimize the dynamic simulation effect of clothing fabrics.

[0187] The embodiment of the present invention establishes the dynamic equation of each grid by combining the target Hessian matrix of all dihedral units in each grid respectively, adopts the implicit time integration algorithm, solves the dynamic equation of each grid according to the vertex parameters and simulation parameters of each grid, and the physical parameters of the cloth to be simulated, and obtains the vertex displacement of each grid, which can ensure stable and efficient dynamic simulation of clothing fabrics and optimize the dynamic simulation effect of clothing fabrics.

[0188] In an optional embodiment, the dynamic equation of the current grid is:

[0189] H x Δx=-g x (35);

[0190] Among them, H x is the target Hessian matrix of all dihedral elements in the current grid, Δx is the vertex displacement of the current grid, and g x The optimized gradient of the current grid.

[0191] As an example, the dynamic equation of the current grid is the following linear equation:

[0192] H x Δx=-g x (35);

[0193] In formula (35), H x is the target Hessian matrix of all dihedral elements in the current grid, Δx is the vertex displacement of the current grid, and g x The optimized gradient of the current grid.

[0194] The embodiment of the present invention selects the above linear equation as the dynamic equation of the current grid, adopts an implicit time integration algorithm, and solves the dynamic equation of each grid according to the vertex parameters and simulation parameters of each grid and the physical parameters of the cloth to be simulated, thereby obtaining the vertex displacement of each grid, thereby ensuring stable and efficient dynamic simulation of clothing fabrics and optimizing the dynamic simulation effect of clothing fabrics.

[0195] Please see Fig.12 , Fig.12 A schematic diagram of the structure of a clothing fabric dynamic simulation device provided for the second embodiment of the present invention. The second embodiment of the present invention provides a clothing fabric dynamic simulation device, comprising: an acquisition module 201, used to acquire all dihedral angle units in each grid based on the cloth grid model of the cloth to be simulated; a construction module 202, used to construct the target Hessian matrix of each dihedral angle unit in combination with the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit; a calculation module 203, used to determine the vertex displacement of all the grids by using an implicit time integration algorithm in combination with the target Hessian matrices of all the dihedral angle units; an adjustment module 204, used to adjust the cloth grid model according to the vertex displacement of all the grids to obtain an updated cloth grid model.

[0196] In an optional embodiment, for each dihedral unit, a multi-motion mode matrix and a dihedral information matrix of the dihedral unit are combined to construct a target Hessian matrix of the dihedral unit, specifically including: for each dihedral unit, 12 motion mode displacement vectors of the dihedral unit are constructed according to the structural parameters of the dihedral unit; a multi-motion mode matrix of the dihedral unit is generated by combining the 12 motion mode displacement vectors of the dihedral unit; a coefficient matrix of the dihedral unit is generated according to the invariant subspace of the original Hessian matrix of the dihedral unit; a dihedral information matrix of the dihedral unit is generated by combining the multi-motion mode matrix and the coefficient matrix of the dihedral unit; and a target Hessian matrix of the dihedral unit is constructed by combining the multi-motion mode matrix and the dihedral information matrix of the dihedral unit.

[0197] In an optional embodiment, the 12 motion mode displacement vectors of the dihedral unit are:

[0198]

[0199] Among them, v i is the i+1th motion mode displacement vector of the dihedral unit, i=(0,1,...,11), n 1 is the normal vector of a unit face of the dihedral unit, n 2 is the normal vector of the other unit face of the dihedral element, m 1 is the height vector of a unit face of the dihedral unit, m 2 is the normal vector of the other unit face of the dihedral unit, e is the edge vector of the unit edge of the dihedral unit, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, [·] T Represents the transpose of a matrix.

[0200] In an optional embodiment, the multi-motion mode matrix of the dihedral unit is:

[0201] Z=[z 0 ,z 1 ,z 2 ,z 3 ,z 4 ,z 5 ,z 6 ,z 7 ] (49);

[0202] Where Z is the multi-motion mode matrix of the dihedral unit, represents a real number, t 1 =h 1 -1 [ω 1 -1,-ω 1 ,1,0] T ,h 1 is the height of a vertex on a unit face of a dihedral unit relative to the unit edge, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, t 2 =h 2 -1 [ω 2 -1,-ω 2 ,1,0] T ,h 2 is the height of the vertex on the other unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, n 1 is the normal vector of a unit face of the dihedral unit, m 1 is the height vector of a unit face of the dihedral unit, s = l -1 [1,-1,0,0] T , l is the length of the unit side of the dihedral element, e is the edge vector of the unit side of the dihedral element, [·] T Represents the transpose of a matrix.

[0203] In an optional embodiment, the dihedral angle information matrix of the dihedral angle unit is:

[0204]

[0205] Where F is the dihedral angle information matrix of the dihedral angle unit,

[0206]

[0207] is the bending potential energy of the dihedral unit, and θ is the angle between the two unit faces of the dihedral unit.

[0208] In an optional embodiment, the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0209]

[0210] Where Λ is the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit, λ 1 =g, λ 3 =-g,

[0211] The eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is:

[0212]

[0213] Where E is the eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit,

[0214] [·] T Represents the transpose of a matrix.

[0215] In an optional embodiment, the target information matrix of the dihedral unit is:

[0216] F′=EΛ′E T (53);

[0217] Where F′ is the target information matrix of the dihedral unit, E T is the transposed matrix of the eigenvector matrix corresponding to the dihedral information matrix of the dihedral unit, Λ′ is the eigenvalue matrix corresponding to the target information matrix of the dihedral unit, λ 0 ′=max(λ 0 ,0),λ 1 ′=max(λ 1 ,0),λ 2 ′=max(λ 2 ,0),λ 3 ′=max(λ 3 ,0),λ 4 ′=max(λ 4 ,0),λ 5 ′=max(λ 5 ,0),λ 6 ′=max(λ 6,0),λ 7 ′=max(λ 7 ,0).

[0218] In an optional embodiment, the target Hessian matrix of the dihedral unit is:

[0219] H d =ZF′Z T (54);

[0220] Among them, H d is the target Hessian matrix of the dihedral unit; Z is the multi-motion mode matrix of the dihedral unit, Z T is the transposed matrix of the multi-motion mode matrix of the dihedral unit, and F′ is the target information matrix of the dihedral unit.

[0221] In an optional embodiment, the implicit time integration algorithm is used in combination with the target Hessian matrix of all dihedral units to determine the vertex displacement of all meshes, specifically including: traversing each mesh to obtain the vertex parameters and simulation parameters of the current mesh, and obtaining the physical parameters of the cloth to be simulated; combining the target Hessian matrix of all dihedral units in the current mesh to establish the dynamic equation of the current mesh; using the implicit time integration algorithm, according to the vertex parameters and simulation parameters of the current mesh, and the physical parameters of the cloth to be simulated, solve the dynamic equation of the current mesh to obtain the vertex displacement of the current mesh.

[0222] In an optional embodiment, the dynamic equation of the current grid is:

[0223] H x Δx=-g x (55);

[0224] Among them, H x is the target Hessian matrix of all dihedral elements in the current grid, Δx is the vertex displacement of the current grid, and g x The optimized gradient of the current grid.

[0225] Please see Fig.13 , Fig.13 The third embodiment of the present invention provides an electronic device 30, comprising a processor 301, a memory 302, and a computer program stored in the memory 302 and configured to be executed by the processor 301; the memory 302 is coupled to the processor 301, and when the processor 301 executes the computer program, the clothing fabric dynamic simulation method as described in the first embodiment of the present invention is implemented, and the same beneficial effects can be achieved.

[0226] The processor 301 reads the computer program from the memory 302 through the bus 303 and executes the computer program to implement any of the embodiments of the method for dynamic simulation of clothing fabrics as described in the first embodiment of the present invention.

[0227] Processor 301 can process digital signals and can include various computing structures, such as complex instruction set computer structure, reduced instruction set computer structure, or a structure that implements a combination of multiple instruction sets. In some examples, processor 301 can be a microprocessor.

[0228] The memory 302 can be used to store instructions executed by the processor 301 or data related to the execution of instructions. These instructions and / or data may include codes for implementing some functions or all functions of one or more modules described in the embodiments of the present invention. The processor 301 of the disclosed embodiment can be used to execute the instructions in the memory 302 to implement the clothing fabric dynamic simulation method as described in the first embodiment of the present invention. The memory 302 includes a dynamic random access memory, a static random access memory, a flash memory, an optical memory, or other memories known to those skilled in the art.

[0229] The fourth embodiment of the present invention provides a computer-readable storage medium, which includes a stored computer program; wherein, when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute the clothing fabric dynamic simulation method as described in the first embodiment of the present invention, and can achieve the same beneficial effects as the first embodiment.

[0230] In summary, the embodiments of the present invention provide a method, device, electronic device and storage medium for dynamic simulation of clothing fabrics, wherein the method comprises: based on the cloth mesh model of the cloth to be simulated, obtaining all dihedral angle units in each mesh; for each dihedral angle unit, combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit, constructing the target Hessian matrix of the dihedral angle unit; using an implicit time integration algorithm, combining the target Hessian matrices of all dihedral angle units, determining the vertex displacements of all meshes; adjusting the cloth mesh model according to the vertex displacements of all meshes, and obtaining an updated cloth mesh model. The embodiments of the present invention determine the multi-motion mode matrix and the dihedral angle information matrix of each dihedral angle unit based on the cloth mesh model of the cloth to be simulated to construct the target Hessian matrix of each dihedral angle unit, and using the implicit time integration algorithm to combine the target Hessian matrices of all dihedral angle units for dynamic simulation, so as to stably and efficiently perform dynamic simulation on clothing fabrics and optimize the dynamic simulation effect of clothing fabrics.

[0231] In several embodiments provided by the present invention, it should be understood that the disclosed devices and methods can also be implemented in other ways. The device embodiments described above are merely schematic. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the devices, methods and computer program products according to multiple embodiments of the present invention. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, program segment or a part of the code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flowchart, and the combination of boxes in the block diagram and / or flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.

[0232] In addition, the functional modules in the various embodiments of the present invention may be integrated together to form an independent part, or each module may exist independently, or two or more modules may be integrated to form an independent part.

[0233] If the functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, or the part that contributes to the prior art or the part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium, including several instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the methods described in each embodiment of the present invention. The aforementioned storage medium includes: various media that can store program codes, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk or an optical disk.

[0234] The above is only a specific embodiment of the present invention, but the protection scope of the present invention is not limited thereto. Any person skilled in the art can easily think of changes or substitutions within the technical scope disclosed by the present invention, which should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention should be based on the protection scope of the claims.

Claims

1. A dynamic simulation method for clothing fabrics, It is characterized in that include: Based on the cloth mesh model of the cloth to be simulated, all dihedral angle units in each mesh are obtained; For each of the dihedral angle units, combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit to construct a target Hessian matrix of the dihedral angle unit; Determining the vertex displacements of all the meshes using an implicit time integration algorithm in combination with target Hessian matrices of all the dihedral elements; The cloth mesh model is adjusted according to the vertex displacements of all the meshes to obtain an updated cloth mesh model.

2. The clothing fabric dynamic simulation method according to claim 1, It is characterized in that For each of the dihedral angle units, combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit to construct a target Hessian matrix of the dihedral angle unit specifically includes: For each of the dihedral angle units, constructing 12 motion mode displacement vectors of the dihedral angle unit according to the structural parameters of the dihedral angle unit; Combining the 12 motion mode displacement vectors of the dihedral unit, generating a multi-motion mode matrix of the dihedral unit; Generate a coefficient matrix of the dihedral unit according to an invariant subspace of an original Hessian matrix of the dihedral unit; Combining the multi-motion mode matrix and the coefficient matrix of the dihedral unit to generate a dihedral information matrix of the dihedral unit; Eliminating negative eigenvalues ​​in an eigenvalue matrix corresponding to a dihedral angle information matrix of the dihedral angle unit to obtain a target information matrix of the dihedral angle unit; The target Hessian matrix of the dihedral unit is constructed by combining the multi-motion mode matrix and the target information matrix of the dihedral unit.

3. The clothing fabric dynamic simulation method according to claim 2, It is characterized in that The 12 motion mode displacement vectors of the dihedral unit are: Among them, v i is the i+1th motion mode displacement vector of the dihedral unit, i=(0,1,...,11), n 1 is the normal vector of a unit face of the dihedral element, n 2 is the normal vector of the other unit face of the dihedral element, m 1 is the height vector of a unit face of the dihedral element, m 2 is the normal vector of the other unit face of the dihedral unit, e is the edge vector of the unit edge of the dihedral unit, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral element relative to the unit edge, [·] T Represents the transpose of a matrix.

4. The clothing fabric dynamic simulation method according to claim 2, It is characterized in that The multi-motion mode matrix of the dihedral unit is: From=[from 0 ,With 1 ,With 2 ,With 3 ,With 4 ,With 5 ,With 6 ,With 7 ]; Wherein, Z is the multi-motion mode matrix of the dihedral unit, represents a real number, t 1 =h 1 -1 [ω 1 -1,-ω 1 ,1,0] T ,h 1 is the height of a vertex on a unit face of the dihedral unit relative to the unit edge, ω 1 is the centroid of the vertex on a unit face of the dihedral unit relative to the unit edge, t 2 =h 2 -1 [ω 2 -1,-ω 2 ,1,0] T ,h 2 is the height of the vertex on the other unit face of the dihedral unit relative to the unit edge, ω 2 is the centroid of the vertex on the other unit face of the dihedral unit relative to the unit edge, n 1 is the normal vector of a unit face of the dihedral element, m 1 is the height vector of a unit face of the dihedral unit, s=l -1 [1,-1,0,0] T , l is the length of the unit side of the dihedral unit, e is the edge vector of the unit side of the dihedral unit, [·] T Represents the transpose of a matrix.

5. The clothing fabric dynamic simulation method according to claim 2, It is characterized in that The dihedral angle information matrix of the dihedral angle unit is: Wherein, F is the dihedral angle information matrix of the dihedral angle unit, is the bending potential energy of the dihedral angle unit, and θ is the angle between two unit faces of the dihedral angle unit.

6. The clothing fabric dynamic simulation method according to claim 5, It is characterized in that The eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is: Wherein, Λ is the eigenvalue matrix corresponding to the dihedral angle information matrix of the dihedral angle unit, λ 1 =g, λ 3 =-g, The eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit is: Wherein, E is the eigenvector matrix corresponding to the dihedral angle information matrix of the dihedral angle unit, [·] T Represents the transpose of a matrix.

7. The clothing fabric dynamic simulation method according to claim 6, It is characterized in that The target information matrix of the dihedral unit is: F′=EΛ′E T ; Where F′ is the target information matrix of the dihedral unit, E T is the transposed matrix of the eigenvector matrix corresponding to the dihedral information matrix of the dihedral unit, Λ′ is the eigenvalue matrix corresponding to the target information matrix of the dihedral unit, λ 0 ′=max(λ 0 ,0),λ 1 ′=max(λ 1 ,0),λ 2 ′=max(λ 2 ,0),λ 3 ′=max(λ 3 ,0),λ 4 ′=max(λ 4 ,0),λ 5 ′=max(λ 5 ,0),λ 6 ′=max(λ 6 ,0),λ 7 ′=max(λ 7 ,0).

8. The clothing fabric dynamic simulation method according to claim 2, It is characterized in that The target Hessian matrix of the dihedral unit is: H d =ZF′Z T ; Among them, H d is the target Hessian matrix of the dihedral unit; Z is the multi-motion mode matrix of the dihedral unit, Z T is the transposed matrix of the multi-motion mode matrix of the dihedral unit, and F′ is the target information matrix of the dihedral unit.

9. The clothing fabric dynamic simulation method according to claim 1, It is characterized in that The implicit time integration algorithm is used to determine the vertex displacements of all the grids in combination with the target Hessian matrix of all the dihedral units, specifically including: Traversing each of the meshes, obtaining vertex parameters and simulation parameters of the current mesh, and obtaining physical parameters of the cloth to be simulated; Combining the target Hessian matrices of all the dihedral elements in the current grid, establishing the dynamic equation of the current grid; An implicit time integration algorithm is adopted to solve the dynamic equation of the current mesh according to the vertex parameters and simulation parameters of the current mesh and the physical parameters of the cloth to be simulated, so as to obtain the vertex displacement of the current mesh.

10. The clothing fabric dynamic simulation method according to claim 9, It is characterized in that The dynamic equation of the current grid is: H x Δx=-g x ; Among them, H x is the target Hessian matrix of all the dihedral elements in the current grid, Δx is the vertex displacement of the current grid, g x is the optimization gradient of the current grid.

11. A dynamic simulation device for clothing fabrics, It is characterized in that include: An acquisition module, used for acquiring all dihedral angle units in each mesh based on a cloth mesh model of the cloth to be simulated; A construction module, configured to construct, for each dihedral angle unit, a target Hessian matrix of the dihedral angle unit by combining the multi-motion mode matrix and the dihedral angle information matrix of the dihedral angle unit; A calculation module, for determining the vertex displacements of all the meshes by using an implicit time integration algorithm in combination with target Hessian matrices of all the dihedral elements; The adjustment module is used to adjust the cloth mesh model according to the vertex displacements of all the meshes to obtain an updated cloth mesh model.

12. An electronic device, It is characterized in that The invention comprises a processor, a memory and a computer program stored in the memory and configured to be executed by the processor; the memory is coupled to the processor, and the processor implements the clothing fabric dynamic simulation method according to any one of claims 1 to 10 when executing the computer program.

13. A computer-readable storage medium, It is characterized in that The computer-readable storage medium includes a stored computer program; wherein, when the computer program is running, the device where the computer-readable storage medium is located is controlled to execute the clothing fabric dynamic simulation method according to any one of claims 1 to 10.