A method, apparatus and program product for constraint decomposition and mapping of engineering constraints to a directed graph

By decomposing engineering constraints into three basic constraints and identifying their special semantics, and mapping them onto a directed graph, the problem of incomplete decomposition in existing technologies is solved, improving the simplicity and scalability of constraint solving in CAD systems.

CN122490612APending Publication Date: 2026-07-31HUAZHONG UNIV OF SCI & TECH
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
HUAZHONG UNIV OF SCI & TECH
Filing Date
2026-04-22
Publication Date
2026-07-31

AI Technical Summary

Technical Problem

In existing technologies, the decomposition of some engineering constraints is not thorough enough, and it cannot effectively handle multiple constraints such as equal length, one-dimensional array of points, and two-dimensional array of points. Furthermore, the decomposition of constraints such as parallelism and perpendicularity may result in numerical solution errors.

Method used

The engineering constraints are decomposed into three basic constraints (dot product 1, dot product 2, and dot product 3), special semantics are identified, and they are mapped onto a directed graph according to graph mapping rules. Parameter volume processing and adjustment are performed for specific constraints.

Benefits of technology

It achieves a more concise expression and solution of constraints, expands the application scope of graph decomposition in CAD systems, can handle arrays and symmetric constraints with complex semantics, and improves the structural clarity and solution efficiency of graphs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122490612A_ABST
    Figure CN122490612A_ABST
Patent Text Reader

Abstract

This invention belongs to the field of computer-aided design and relates to a method, apparatus, and program product for constraint decomposition and mapping of engineering constraints to a directed graph. The method includes: S1: decomposing engineering constraints into three basic constraints: , , and , with the basic constraints being + , + , and ; S2: identifying special semantics present in the engineering constraints, wherein the special semantics include equality or proportional relationships; S3: mapping the decomposed basic constraints to a directed graph according to the identified special semantics and preset graph mapping rules. This invention decomposes engineering constraints into three basic constraints, resulting in a simpler form, easier solution, and a clearer and more concise directed graph structure, which is beneficial for subsequent graph decomposition algorithms. This invention expands the engineering constraints that existing technologies can express, has stronger extensibility, can handle engineering constraints containing complex semantics, and broadens the application scope of graph decomposition methods in CAD systems.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of computer-aided design and relates to a method, apparatus and program product for decomposing engineering constraints and mapping them to a directed graph. More specifically, it relates to a method for decomposing equivalent constraints into basic constraints. Background Technology

[0002] The emergence and development of CAD technology has brought about tremendous changes to the field of drafting and design, greatly improving drafting efficiency and tightly linking the previously separate design, simulation, and manufacturing processes, providing a digital and intelligent technological foundation for modern manufacturing. As a core component of CAD software, the geometric constraint solving engine primarily supports scenarios requiring constraint solving, such as 2D sketching, 3D assembly, direct modeling, and mechanism simulation, serving as a crucial cornerstone of parametric design. The key technologies of a geometric constraint solving engine include the expression of geometric constraint systems, redundancy analysis, and solving. The way the geometric constraint system is expressed determines the design of redundancy analysis and constraint solving methods.

[0003] The mainstream method for expressing geometric constraint systems is based on graph theory. However, the existing patent CN117574644A, entitled "A Method for Decomposing Two-Dimensional Engineering Constraints into Basic Constraints and Expressing Them in a Directed Graph," does not thoroughly decompose some engineering constraints. It cannot decompose various constraints, including equal-length constraints, one-dimensional point arrays, and two-dimensional point arrays. Furthermore, the decomposition of parallel and perpendicular constraints may contain errors due to numerical solutions, requiring adjustments. Therefore, this invention proposes a simpler and more effective constraint decomposition expression method. Summary of the Invention

[0004] In view of the above-mentioned defects or improvement needs of the prior art, the present invention provides a method for decomposing engineering constraints and mapping them to a directed graph, the purpose of which is to solve the technical problem that the decomposition of some engineering constraints in the prior art is not thorough enough.

[0005] To achieve the above objectives, according to one aspect of the present invention, a method for constraint decomposition of engineering constraints and mapping to a directed graph is provided, comprising: S1: Decompose the engineering constraints into the following three basic constraints; , , , in, , These are two unit vectors, with a dot product constraint of 1. The geometric meaning of is the cosine of the angle between two unit vectors, used to characterize the angle constraint part of the constraint. , These are the coordinates of two points. It is a unit vector. It is the vector pointing from point j to point k, with a dot product constraint. The geometric meaning of is two points j , k exist i Projected distance in the direction; , These are the coordinates of two points, with a dot product constraint of 3. The geometric meaning of is the square of the distance between two points, used to characterize the distance component in partial constraints; Based on this, basic constraints , , They are represented as follows: + , + , ; S2: Identify special semantics in engineering constraints, wherein the special semantics include equality or proportional relationships; S3: Based on the identified special semantics and the preset graph mapping rules, the decomposed basic constraints are mapped onto the directed graph.

[0006] Furthermore, in step S1, for the three basic constraints, when the constraint value on the right side of the equation is 0, no parameter volume is generated when mapping to a directed graph, and then the engineering constraints are decomposed into basic constraints according to the preset engineering constraint decomposition rules.

[0007] Furthermore, in step S1, the decomposition of engineering constraints is divided into two categories: The first type of engineering constraint is directly decomposed into basic constraints and mapped into a directed graph; the semantics of the first type of engineering constraint do not contain equality or proportional relationships. The second type of engineering constraint requires mapping to a directed graph through adjustments to the directed graph; the semantics of the second type of engineering constraint include equality or proportional relationships.

[0008] Further, step S2 includes extracting the equal or proportional parts of the second type of engineering constraint semantics and labeling them to the corresponding basic constraints; when the labeled basic constraints are mapped into a directed graph, the parameter volumes of the constraints corresponding to the equal or proportional parts in the semantics are mapped to the same parameter volume, and when calculating the specific constraint residuals during the solution process, the parameters in the parameter volume are multiplied by a coefficient. This coefficient is 1 when the constraint values ​​of the basic constraints obtained after the engineering constraint decomposition are equal, and is the corresponding proportional value when the constraint values ​​of the basic constraints obtained after the engineering constraint decomposition are proportional.

[0009] Further, step S3 includes: First, define the vertex types of each constraint object: Dot product 1 constraint involves two spheres, dot product 2 constraint involves two cubes and one sphere, and dot product 3 constraint involves two cubes; if the component value of a constraint is non-zero, then the vertex of the constraint is a parametric volume. Subsequently, select any vertex with degrees of freedom from the vertices of each constraint component and its constraint object, add arcs pointing from other vertices to that vertex, and ensure that all arcs correspond to the same constraint component. Then, merge the parameter volumes of the corresponding basic constraints according to semantics.

[0010] Furthermore, step S1 involves , , The three basic engineering constraints are two-point symmetry constraint, two-line-angle symmetry constraint, and two-point equal-height constraint, which are adopted... , It is expressed as follows: The basic constraint of a two-point symmetric constraint is expressed as follows: The corresponding constraint value is ;in, This represents the coordinates of the first point in the symmetry constraint. This represents the coordinates of the second point in the symmetry constraint. Represents the location point of the line. The unit vector representing the normal to the line. This represents the distance from a point to a line. The basic constraint of a two-line-angle symmetry constraint is expressed as follows: The corresponding constraint value is ;in, , , There are three unit vectors. and about Angular symmetry express and Any one with The cosine of the angle between them; The basic constraint of a two-point equal-height constraint is expressed as follows: The corresponding constraint value is ;in, Represents the coordinates of the origin of the coordinate system. This represents the coordinates of the first point in the symmetry constraint. represents the coordinates of the second point in the symmetric constraint, and h represents the unit vector corresponding to the X-axis of the coordinate system.

[0011] Furthermore, the basic constraints of the S1 decomposition include: (1) Equal length constraint Equal length constraint Decomposed into two basic constraints, denoted as follows: , : , , These are any one of the following: point-to-point distance, line-to-line distance, point-to-line distance, and point-to-point directional distance; (2) Point one-dimensional linear array

[0012] The constraint components are two: points. , and array direction The dot product 2 constraint between them is denoted as c1; , and array direction normal direction The dot product 2 constraint between them is denoted as , The constraint value is 0: , It is a one-dimensional linear array of points in the array direction The spacing; (3) Point two-dimensional linear array

[0013] Specify two directions , , , The two directions are not parallel; The constraint components are two: points. , and array direction The dot product 2 constraint between them is denoted as ;point , and another array direction The dot product 2 constraint between them is denoted as ; , in, , Representing a two-dimensional linear array of points respectively at , The distance between the two directions; (4) Dot Circular Array

[0014] Specify the array center cent; There are five constraint components, points , cent and the new directions The dot product 2 constraint between them is denoted as ;point , cent and normal direction The dot product 2 constraint between them is denoted as ;point , cent and the new directions The dot product 2 constraint between them is denoted as ;point , cent and normal direction The dot product 2 constraint between them is denoted as ; , The dot product 1 constraint between them is denoted as ; , The constraint value is 0; , in, This represents the radius of the circular array of points. Indicates the angular interval of the circular array; (5) One-dimensional linear array of lines Two-dimensional linear array Circular array

[0015] These three arrays of straight lines are divided into two parts. One part is the array of the positioning points of the straight lines, which are the same as the three corresponding arrays of points. The other part is the direction of the straight lines in the one-dimensional linear array of the straight lines. , In a directed graph, a vertex of a sphere represents the direction of a line in a two-dimensional linear array. , In a directed graph, given a sphere as the vertex, there is a linear circular array. , Add a dot product constraint of 1 between them, denoted as : , , , in, Represents the radius of a linear circular array. Indicates the angle of the circular array; (6) One-dimensional linear array of circles Two-dimensional linear array Circular array

[0016] The three arrays of a circle are divided into two parts: one part is the array of the center of the circle, which is the same as the three corresponding arrays of a point; the other part is the array of the radius of the circle. equal: , , .

[0017] Furthermore, step S2 requires identifying constraint components or engineering constraints that are specially processed when mapped onto the graph: (1) Equal length constraint Basic constraints , When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (2) Point one-dimensional linear array constraint components of all mode constraints of a one-dimensional linear array of points When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (3) Point two-dimensional linear array constraint components of all mode constraints of a point-based two-dimensional linear array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. constraint components of all mode constraints of a point-based two-dimensional linear array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (4) Dot Circular Array constraint components of all pattern constraints of a point circular array , When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. constraint components of all pattern constraints of a point circular array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (5) Linear one-dimensional array, two-dimensional linear array, circular array Special semantic recognition of linear one-dimensional arrays, two-dimensional linear arrays, and circular arrays, excluding constraint components. The corresponding arrays of the outer points are the same; Constraint components of a linear circular array When mapped onto a graph, the corresponding parameter body is always a single parameter body; (6) Circular one-dimensional linear array, two-dimensional linear array, circular array The special semantic recognition of one-dimensional linear arrays, two-dimensional linear arrays, and circular arrays is the same as that of the corresponding arrays of points. When the radius of a circle is mapped onto a graph, the corresponding parameter volume is always a single parameter volume; (7) Parallel lines When two straight lines are mapped onto a graph, the corresponding sphere is always a single sphere. (8) The straight line is perpendicular When the sphere of a straight line is mapped onto a graph, the corresponding sphere is the sphere of the normal vector of another straight line. That is, all straight lines perpendicular to the same straight line are the same sphere. (9) Point overlap When the cubes at two points are mapped onto the graph, the corresponding cubes are both cubes.

[0018] According to another aspect of the present invention, a program product for constraint decomposition and mapping of engineering constraints to a directed graph is provided, wherein when the computer program is executed by a processor, it implements the method for constraint decomposition and mapping of engineering constraints to a directed graph as described in any of the preceding claims.

[0019] According to another aspect of the invention, a computer device is provided, including a memory, a processor, and a computer program stored in the memory, the processor executing the computer program to implement a method for constraint decomposition and mapping of engineering constraints to a directed graph as described in any of the preceding claims.

[0020] In summary, the technical solutions conceived in this invention, compared with the prior art, can achieve the following beneficial effects: 1. Decomposing engineering constraints into three basic constraints makes the form simpler, the solution easier, and the directed graph structure clearer and more concise, which is beneficial for subsequent graph algorithm decomposition.

[0021] 2. The graph mapping modification proposed in this invention after engineering constraint decomposition expands the engineering constraints that existing technologies can express, making it more extensible and capable of handling engineering constraints containing complex semantics such as arrays and symmetry, thus expanding the application scope of the graph decomposition method in CAD systems. Attached Figure Description

[0022] Figure 1This is a schematic diagram of the engineering constraint decomposition and mapping process in a preferred embodiment of the present invention; Figure 2 This is a schematic diagram of the dot product 2 basic constraint mapping to a directed graph in a preferred embodiment of the present invention; Figure 3 This is a schematic diagram of the dot product 2 basic constraint mapping to a directed graph in a preferred embodiment of the present invention; Figure 4 This is a schematic diagram of the dot product 2 basic constraint mapping to a directed graph in a preferred embodiment of the present invention; Figure 5 This is a schematic diagram of the decomposition and mapping of equal-length constraints into a directed graph in a preferred embodiment of the present invention; Figure 6 This is a schematic diagram illustrating the decomposition and mapping of a one-dimensional linear array of points into a directed graph in a preferred embodiment of the present invention. Figure 7 This is a schematic diagram illustrating the constraint decomposition and mapping of a two-dimensional linear array of points into a directed graph in a preferred embodiment of the present invention. Figure 8 This is a schematic diagram of the point circular array constraint decomposition and mapping into a directed graph in a preferred embodiment of the present invention; Figure 9 This is a schematic diagram illustrating the decomposition and mapping of a one-dimensional linear array of lines into a directed graph in a preferred embodiment of the present invention. Figure 10 This is a schematic diagram illustrating the constraint decomposition and mapping of a linear two-dimensional linear array into a directed graph in a preferred embodiment of the present invention. Figure 11 This is a schematic diagram of the constraint decomposition and mapping of a linear circular array into a directed graph in a preferred embodiment of the present invention; Figure 12 This is a schematic diagram illustrating the decomposition and mapping of a circular one-dimensional linear array into a directed graph in a preferred embodiment of the present invention; Figure 13 This is a schematic diagram illustrating the constraint decomposition and mapping of a circular two-dimensional linear array into a directed graph in a preferred embodiment of the present invention. Figure 14 This is a schematic diagram of the constraint decomposition and mapping of a circular array into a directed graph in a preferred embodiment of the present invention. Detailed Implementation

[0023] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention. Furthermore, the technical features involved in the various embodiments of this invention described below can be combined with each other as long as they do not conflict with each other.

[0024] A method for constraint decomposition and mapping of engineering constraints to a directed graph is proposed, aiming to improve the existing constraint decomposition method for CAD engineering, making the decomposed geometric constraint system simpler, and resulting in a smaller graph with a clearer structure during subsequent solution.

[0025] This method mainly includes three steps, namely: S1: Decompose engineering constraints into basic constraints; S2: Identify special semantics; S3: Map the basic constraints to a directed graph.

[0026] S1 decomposes most common constraints into three basic constraints, simplifying and organizing the geometric constraint system in terms of equation form and structure; S2 identifies the special semantics of some engineering constraints to guide the graph mapping in S3; S3 maps the decomposed constraints onto a directed graph based on the identified special semantics and graph mapping rules.

[0027] S1: Decompose engineering constraints into basic constraints It is mainly divided into the definition of basic constraints and the specific decomposition of engineering constraints into three types of basic constraints.

[0028] The first type of basic constraint is the dot product 1 constraint, defined as: , in, , These are two unit vectors, with a dot product constraint of 1. The geometric meaning of is the cosine value of the angle between two unit vectors, used to characterize the angular constraint part of the constraint.

[0029] The second type of basic constraint is the dot product 2 constraint, defined as: , in, , These are the coordinates of two points. It is a unit vector. It is the vector pointing from point j to point k, with a dot product constraint. The geometric meaning of is two points j , k exist i Projected distance in the direction.

[0030] The third type of basic constraint is the dot product 3 constraint, defined as follows: , in , These are the coordinates of two points, with a dot product constraint of 3. The geometric meaning of is the square of the distance between two points, used to characterize the distance component in partial constraints.

[0031] To further simplify the directed graph, special handling is done for the case where the constraint value is 0, i.e., when mapping to a directed graph, no parameter volume is generated.

[0032] Then, the engineering constraints will be decomposed into basic constraints according to fixed engineering constraint decomposition rules.

[0033] S2: Identify special semantics Since the expression of partial constraints lies not only in the decomposition of the constraints in that part but also in the subsequent modifications and adjustments on the directed graph, the decomposition of engineering constraints is divided into two categories. The first type of constraint can be easily and directly decomposed into basic constraints and mapped to a directed graph. The second type of constraint requires that the mapping to the directed graph be completed through adjustments to the directed graph.

[0034] The first type of constraint is one whose semantics do not include equality or proportionality. Specifically, in engineering practice, common constraints of this type include: point-to-point distance, point-to-line distance, line-to-line distance, line-to-line angle, point-to-point directional distance, point-to-line distance, extreme distance constraint, and its variants, such as the vertical variation of point-to-point directional distance.

[0035] The second type of constraint contains semantic relationships of equality or proportionality. Specifically, in engineering practice, common constraints of this type include: parallel lines, perpendicular lines, coincident lines, coincident points, coincident lines, equal radii, equal lengths, tangent lines to circles, tangent circles, midpoint, mirror image, one-dimensional linear arrays, two-dimensional linear arrays, circular arrays, and variations thereof, such as the variation of coincident points where the centers of two circles coincide.

[0036] S2 involves extracting and labeling the equal or proportional parts of the second type of engineering constraint semantics. After decomposition into basic constraints, when the labeled basic constraints are mapped into a directed graph, the parameter volumes of the constraints corresponding to the equal or proportional parts in the semantics are mapped to the same parameter volume. During the solution process, when calculating the specific constraint residuals, a coefficient is multiplied by a factor. This coefficient is 1 in the case of equality and the corresponding proportional value in the case of proportionality.

[0037] S3: Map the basic constraints to a directed graph First, define the vertex types for each constraint object: Dot product 1 involves two spheres, dot product 2 involves two cubes and one sphere, and dot product 3 involves two cubes. If a constraint component value is non-zero, the vertex of that constraint is a parametric volume. Then, select any vertex with degrees of freedom from the vertices of each constraint component and its constraint object, and add arcs pointing from other vertices to that vertex, with all arcs corresponding to the same constraint component. See the attached diagram for the specific mapping method. Figures 2-4 The parameter volumes of the corresponding basic constraints are merged according to semantics. The invention will be described in more detail below with an example. In the following, graph mapping refers to the process of mapping geometric elements or constraints into a directed graph; constraint components refer to the basic constraints after decomposing engineering constraints.

[0038] 1. Comparison with the six basic constraints in existing technology CN117574644A

[0039] 2. Decomposition of engineering constraints and graph mapping CN117574644A - The method of decomposing two-dimensional engineering constraints into basic constraints and expressing them in a directed graph. Existing engineering constraint decomposition methods will not be elaborated upon here; they involve... , , The decomposition of the three basic constraints into engineering constraints can be intuitively derived by comparing the specific implementation method (1) of this patent with the six basic constraints in the prior art. , , There are three basic engineering constraints: two-point symmetry constraint, two-line-angle symmetry constraint, and two-point equal-height constraint. These are the basic constraints. , The breakdown is shown in the table below:

[0040] Since the decomposition and graph mapping of engineering constraints in this invention require the use of directed graphs, for details of directed graphs and mapping methods, please refer to CN117556485A - A method and system for modeling and expressing a two-dimensional CAD geometric constraint system. Based on this, this invention adds a parameter body, which includes value constraints and geometric parameter elements such as the radius of a circle.

[0041] The process of decomposing engineering constraints and finally mapping them to a directed graph is as follows: Figure 1 As shown.

[0042] S1 decomposes engineering constraints into basic constraints. The specific decomposition implementation scheme for this step, excluding the methods already existing in CN117556485A—Decomposing Two-Dimensional Engineering Constraints into Basic Constraints in Directed Graph Expression—is as follows: (1) Equal length constraint The constraint has four objects, denoted as g1, g2, g3, and g4. g2 and g3 can be the same geometric element, divided into two groups: {g1, g2} and {g3, g4}. These groups should be able to annotate distance-type constraints. The geometric element type combinations in both groups are the same. Specifically, feasible combinations are point-to-point, point-to-line, point-to-circle, circle-to-circle, line-to-circle, and line-to-line. The order of geometric element types does not affect the addition of constraints. The basic constraints decomposed from point-to-point, point-to-line, point-to-circle, circle-to-circle, line-to-circle, and line-to-line are the same as the basic constraints generated by annotating distance constraints between these geometric elements. Finally, the equal-length constraint is decomposed into two basic constraints, denoted as... , (el is) (First letter).

[0043]

[0044] (2) Point one-dimensional linear array Treating a one-dimensional linear array of points directly as an engineering constraint would be too complex. Therefore, a pattern constraint is added between each pair of points in the array to achieve a one-dimensional linear array of points. All engineering constraints for the array types described below follow this method, and will not be elaborated further. Furthermore, the pattern constraint under each array type engineering constraint defaults to the corresponding pattern constraint.

[0045] The pattern constraint has two constraint components. One is a point. , and array direction The dot product 2 constraint between them is denoted as (p1lp is) (First letter). Two dots. , and array direction normal direction The dot product 2 constraint between them is denoted as .

[0046] Mode constraint components The constraint value is 0.

[0047] and There should be a dot product constraint between them to make them perpendicular, but this will be recorded. and The normal relationship between them can be found through a simple lookup, without the need to add constraints repeatedly, and therefore is not included in the constraint components of the schema constraint. All constraints involving normals described below are implemented using this method.

[0048] (3) Point two-dimensional linear array Two-dimensional linear arrays require specifying two directions. , ,Require , The two directions are not parallel.

[0049] The pattern constraint has two constraint components. One is a point. , and array direction The dot product 2 constraint between them is denoted as (p2lp is) (First letter). Two dots. , and another array direction The dot product 2 constraint between them is denoted as .

[0050]

[0051] , The points are in the directions respectively , The array spacing on.

[0052] (4) Dot Circular Array For circular arrays, the array center cent must be specified.

[0053] The pattern constraint has five constraint components, one of which is a point. , cent and the new directions The dot product constraint between 1 and 2 is denoted as (pcp is) (first letter); two is a dot) , cent and normal direction The dot product 2 constraint between them is denoted as The three points are p2, cent, and the newly added direction. The dot product 2 constraint between them is denoted as The four points are p2, cent, and... normal direction The dot product 2 constraint between them is denoted as Five is , The dot product 1 constraint between them is denoted as .

[0054] , The constraint value is 0.

[0055]

[0056] It is the radius of the circular array. It is the angular spacing of the circular array.

[0057] (5) Linear one-dimensional array, two-dimensional linear array, circular array These three arrays of straight lines are divided into two parts: one part is the array of the positioning points of the straight line, which is the same as the corresponding array of points; the other part is the direction of the straight lines in the one-dimensional linear array of the straight lines. , In a directed graph, a vertex of a sphere represents the direction of a line in a two-dimensional linear array. , In a directed graph, given a sphere as the vertex, there is a linear circular array. , Add a dot product constraint of 1 between them, denoted as : .

[0058] , , , (6) Circular one-dimensional linear array, two-dimensional linear array, circular array The three arrays of the circle are divided into two parts: one part is the array of the center of the circle, which is the same as the corresponding array of the point, and the other part is the array of the radius of the circle.

[0059] , , .

[0060] S2 identifies special semantics. This step requires identifying constraint components or engineering constraints that require special processing of the parameter body when mapped onto the graph. Steps (1)-(6) correspond one-to-one with (1)-(6) in S1. The following are constraints that do not require constraint components but require special graph mapping; (7)~(9) are other special semantic identifications that do not require decomposition.

[0061] (1) Equal length constraint Basic constraints , When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom.

[0062] (2) Point one-dimensional linear array constraint components of all mode constraints of a one-dimensional linear array of points When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom.

[0063] (3) Point two-dimensional linear array constraint components of all mode constraints of a point-based two-dimensional linear array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom.

[0064] constraint components of all mode constraints of a point-based two-dimensional linear array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom.

[0065] (4) Dot Circular Array constraint components of all pattern constraints of a point circular array , When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom.

[0066] constraint components of all pattern constraints of a point circular array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom.

[0067] (5) Linear one-dimensional array, two-dimensional linear array, circular array Special semantic recognition of linear one-dimensional arrays, two-dimensional linear arrays, and circular arrays, excluding constraint components. The corresponding arrays of the outer points are the same.

[0068] Constraint components of a linear circular array When mapped onto a graph, the corresponding parameter body is always a single parameter body.

[0069] (6) Circular one-dimensional linear array, two-dimensional linear array, circular array The special semantic recognition of one-dimensional linear arrays, two-dimensional linear arrays, and circular arrays is the same as that of the corresponding arrays of points.

[0070] When the radius of a circle is mapped onto a graph, the corresponding parameter volume is always a single parameter volume.

[0071] (7) Parallel lines When two straight lines are mapped onto a graph, the corresponding sphere is always a single sphere.

[0072] (8) The straight line is perpendicular When the sphere of a straight line is mapped onto a graph, the corresponding sphere is the sphere of the normal vector of another straight line. That is, all straight lines perpendicular to the same straight line are the same sphere.

[0073] (9) Point overlap When the cubes at two points are mapped onto the graph, the corresponding cubes are both cubes.

[0074] S3 maps basic constraints to a directed graph.

[0075] The vertices of the constraint object with dot product 1 are two spheres, the vertices of the constraint object with dot product 2 are two cubes and one sphere, and the vertices of the constraint object with dot product 3 are two cubes. If the constraint component value is not 0, then the vertex of the constraint value is a parametric volume.

[0076] Choose any vertex with a degree of freedom from the constraint component and its constraint object, and add an arc that is pointed to by other vertices, all of which correspond to the same constraint component.

[0077] The above process ultimately maps to directed graphs of equal-length constraints, one-dimensional linear arrays of points, two-dimensional linear arrays of points, circular arrays of points, one-dimensional linear arrays of lines, two-dimensional linear arrays of lines, circular arrays of lines, one-dimensional linear arrays of circles, two-dimensional linear arrays of circles, and circular arrays of circles, as shown below. Figures 5 to 14 As shown.

[0078] Those skilled in the art will readily understand that the above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.

Claims

1. A method for constraint decomposition of engineering constraints and mapping to a directed graph, characterized in that, include: S1: Decompose the engineering constraints into the following three basic constraints; , , , in, , These are two unit vectors, with a dot product constraint of 1. The geometric meaning of is the cosine of the angle between two unit vectors, used to characterize the angle constraint part of the constraint. , These are the coordinates of two points. It is a unit vector. It is the vector pointing from point j to point k, with a dot product constraint. The geometric meaning of is two points j , k exist i Projected distance in the direction; , These are the coordinates of two points, with a dot product constraint of 3. The geometric meaning of is the square of the distance between two points, used to characterize the distance component in partial constraints; Based on this, basic constraints , , They are represented as follows: + , + , ; S2: Identify special semantics in engineering constraints, wherein the special semantics include equality or proportional relationships; S3: Based on the identified special semantics and the preset graph mapping rules, the decomposed basic constraints are mapped onto the directed graph.

2. The method for constraint decomposition and mapping of engineering constraints to a directed graph according to claim 1, characterized in that, In step S1, for the three basic constraints, when the constraint value on the right side of the equation is 0, no parameter volume is generated when mapping to a directed graph. Then, the engineering constraints are decomposed into basic constraints according to the preset engineering constraint decomposition rules.

3. The method for constraint decomposition and mapping of engineering constraints to a directed graph according to claim 1, characterized in that, In step S1, the decomposition of engineering constraints is further divided into two categories: The first type of engineering constraint is directly decomposed into basic constraints and mapped into a directed graph; the semantics of the first type of engineering constraint do not contain equality or proportional relationships. The second type of engineering constraint requires mapping to a directed graph through adjustments to the directed graph; the semantics of the second type of engineering constraint include equality or proportional relationships.

4. The method for constraint decomposition and mapping of engineering constraints to a directed graph according to claim 3, characterized in that, Step S2 includes extracting the equal or proportional parts of the second type of engineering constraint semantics and labeling them to the corresponding basic constraints; when the labeled basic constraints are mapped into a directed graph, the parameter volumes of the constraints corresponding to the equal or proportional parts in the semantics are mapped to the same parameter volume, and when calculating the specific constraint residuals during the solution process, the parameters in the parameter volume are multiplied by a coefficient. This coefficient is 1 when the constraint values ​​of the basic constraints obtained after the engineering constraint decomposition are equal, and is the corresponding proportional value when the constraint values ​​of the basic constraints obtained after the engineering constraint decomposition are proportional.

5. The method for constraint decomposition and mapping of engineering constraints to a directed graph according to claim 1, characterized in that, Step S3 includes: First, define the vertex types of each constraint object: Dot product 1 constraint involves two spheres, dot product 2 constraint involves two cubes and one sphere, and dot product 3 constraint involves two cubes; if the component value of a constraint is non-zero, then the vertex of the constraint is a parametric volume. Subsequently, select any vertex with degrees of freedom from the vertices of each constraint component and its constraint object, add arcs pointing from other vertices to that vertex, and ensure that all arcs correspond to the same constraint component. Then, merge the parameter volumes of the corresponding basic constraints according to semantics.

6. The method for constraint decomposition and mapping of engineering constraints to a directed graph according to claim 1, characterized in that, Step S1 involves , , The three basic engineering constraints are two-point symmetry constraint, two-line-angle symmetry constraint, and two-point equal-height constraint, which are adopted... , It is expressed as follows: The basic constraint of a two-point symmetric constraint is expressed as follows: The corresponding constraint value is ;in, This represents the coordinates of the first point in the symmetry constraint. This represents the coordinates of the second point in the symmetry constraint. Represents the location point of the line. The unit vector representing the normal to the line. It represents the distance from a point to a line; The basic constraint of a two-line-angle symmetry constraint is expressed as follows: The corresponding constraint value is ;in, , , There are three unit vectors. and about Angular symmetry express and Any one with The cosine of the angle between them; The basic constraint of a two-point equal-height constraint is expressed as follows: The corresponding constraint value is ;in, Represents the coordinates of the origin of the coordinate system. This represents the coordinates of the first point in the symmetry constraint. The coordinates of the second point in the symmetric constraint are represented by , and h represents the unit vector corresponding to the X-axis of the coordinate system.

7. The method for constraint decomposition and mapping of engineering constraints to a directed graph according to claim 1, characterized in that, The basic constraints of S1 decomposition include: (1) Equal length constraint Equal length constraint Decomposed into two basic constraints, denoted as follows: , : , , These are any one of the following: point-to-point distance, line-to-line distance, point-to-line distance, and point-to-point directional distance; (2) Point one-dimensional linear array The constraint components are two: points. , and array direction The dot product 2 constraint between them is denoted as c1; , and array direction normal direction The dot product 2 constraint between them is denoted as , The constraint value is 0: , It is a one-dimensional linear array of points in the array direction The spacing; (3) Point two-dimensional linear array Specify two directions , , , The two directions are not parallel; The constraint components are two: points. , and array direction The dot product 2 constraint between them is denoted as ;point , and another array direction The dot product 2 constraint between them is denoted as ; , in, , Representing a two-dimensional linear array of points respectively in , The distance between the two directions; (4) Dot Circular Array Specify the array center cent; There are five constraint components, points , cent and the new directions The dot product 2 constraint between them is denoted as ;point , cent and normal direction The dot product 2 constraint between them is denoted as ;point , cent and the new directions The dot product 2 constraint between them is denoted as ;point , cent and normal direction The dot product 2 constraint between them is denoted as ; , The dot product 1 constraint between them is denoted as ; , The constraint value is 0; , in, This represents the radius of the circular array of points. Indicates the angular interval of the circular array; (5) One-dimensional linear array of lines Two-dimensional linear array Circular array These three arrays of straight lines are divided into two parts. One part is the array of the positioning points of the straight lines, which are the same as the three corresponding arrays of points. The other part is the direction of the straight lines in the one-dimensional linear array of the straight lines. , In a directed graph, a vertex of a sphere represents the direction of a line in a two-dimensional linear array. , In a directed graph, given a sphere as the vertex, there is a linear circular array. , Add a dot product constraint of 1 between them, denoted as : , , , in, Represents the radius of a linear circular array. Indicates the angle of the circular array; (6) One-dimensional linear array of circles Two-dimensional linear array Circular array The three arrays of a circle are divided into two parts: one part is the array of the center of the circle, which is the same as the three corresponding arrays of a point; the other part is the array of the radius of the circle. equal: , , 。 8. A method for constraint decomposition and mapping of engineering constraints to a directed graph according to claim 7, characterized in that, Step S2 requires identifying constraint components or engineering constraints that require special processing of the parameter volume when mapped onto the graph: (1) Equal length constraint Basic constraints , When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (2) Point one-dimensional linear array constraint components of all mode constraints of a one-dimensional linear array of points When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (3) Point two-dimensional linear array constraint components of all mode constraints of a point-based two-dimensional linear array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. constraint components of all mode constraints of a point-based two-dimensional linear array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (4) Dot Circular Array constraint components of all pattern constraints of a point circular array , When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. constraint components of all pattern constraints of a point circular array When mapped onto a graph, the corresponding parameter volume is a single parameter volume with 1 degree of freedom. (5) Linear one-dimensional array, two-dimensional linear array, circular array Special semantic recognition of linear one-dimensional arrays, two-dimensional linear arrays, and circular arrays, excluding constraint components. The corresponding arrays of the outer points are the same; Constraint components of a linear circular array When mapped onto a graph, the corresponding parameter body is always a single parameter body; (6) Circular one-dimensional linear array, two-dimensional linear array, circular array The special semantic recognition of one-dimensional linear arrays, two-dimensional linear arrays, and circular arrays is the same as that of the corresponding arrays of points. When the radius of a circle is mapped onto a graph, the corresponding parameter volume is always a single parameter volume; (7) Parallel lines When two straight lines are mapped onto a graph, the corresponding sphere is always a single sphere. (8) The straight line is perpendicular When the sphere of a straight line is mapped onto a graph, the corresponding sphere is the sphere of the normal vector of another straight line. That is, all straight lines perpendicular to the same straight line are the same sphere. (9) Point overlap When the cubes at two points are mapped onto the graph, the corresponding cubes are both cubes.

9. A program product for the constraint decomposition of engineering constraints and mapping to a directed graph, characterized in that, When executed by a processor, the computer program implements the method for constraint decomposition and mapping of engineering constraints to a directed graph as described in any one of claims 1 to 8.

10. A computer device comprising a memory, a processor, and a computer program stored in the memory, characterized in that, The processor executes the computer program to implement the method for constraint decomposition and mapping of engineering constraints to a directed graph as described in any one of claims 1 to 8.