A planar pattern design method based on graph grammar

CN116432262BActive Publication Date: 2026-09-22NANJING UNIV OF FINANCE & ECONOMICS
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202310414875.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-04-18
Publication Date
2026-09-22
Estimated Expiration
2043-04-18

AI Technical Summary

Technical Problem

然而,大多数图文法只关注抽象图的规范,而忽略了图的物理布局的规范

Benefits of technology

[0046]1)形状文法在设计领域具有出色的表现,但是形状文法执行的是基于推导操作的单方向工作流,本身不支持规约操作,所以,形状文法在复杂形状结构的分析方面存在着不足。而本发明是将图文法和形状文法的优点相结合,图文法具有推导和归约双向工作流,所以通过图文法和结点转换规则生成的复杂图案具有归约能力,即可以对该图案进行结构上的分析。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116432262B_ABST
    Figure CN116432262B_ABST
Patent Text Reader

Abstract

The application discloses a planar pattern design method based on graph grammar, which comprises the following steps: formulating rules, including constructing a set of graph grammar productions for generating and analyzing related abstract point-edge graph, and setting a set of node conversion rules according to specific pattern generation requirements; generating a point-edge graph based on the formulated productions; drawing a pattern based on the point-edge graph through the node conversion rules; and adjusting the position of the pattern based on the attributes of edges in the point-edge graph. The application combines the advantages of graph grammar and shape grammar, and the graph grammar has bidirectional workflow of deduction and reduction, so that the complex pattern generated through the graph grammar and the node conversion rules has reduction capacity, that is, the pattern can be analyzed in structure.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of product design technology, particularly generative product design, and especially relates to a planar pattern design method based on graphic and textual methods. Background Technology

[0002] Design is a complex problem-solving process, a product of professional knowledge, innovation, aesthetic appreciation, and technological integration. With the rapid development and widespread adoption of technologies such as artificial intelligence, machine learning, and cloud computing, the field of product design is constantly expanding. Various industries have demonstrated fruitful research results in the digitization and intelligentization of design systems, leading to a new "design turn"—a paradigm shift in design. A design paradigm is a design strategy distinct from conventional design, where designers do not directly interact with materials and products but rather through a generative system. This generative system is a computer-aided system, a virtual space that mimics the natural evolutionary process, creating and defining new shapes through a series of complex mathematical transformations to meet diverse design needs. Generative design is the concrete manifestation of this paradigm. Generative design can be defined as a new design paradigm where designers encode design goals into rules or constraints, form corresponding digital models using knowledge and experience within their professional domain, and solve and optimize them using computer algorithms, thereby generating a class of design methods to produce a solution.

[0003] Generative design primarily includes shape grammar-based design, CAD parametric design, and evolutionary computation-based design. In 1971, Professors Tiny G of MIT and Gips J of Boston College proposed shape grammar as a generative system oriented towards design, elaborating on its concept and application process. Shape grammar is a design reasoning method based on rules, using shapes as fundamental elements, and analyzing syntactic structures to generate new shapes. The rules are based on spatial transformations, namely translation, scaling, rotation, and mirroring, allowing one shape to become part of another. With a limited number of rules, an infinite number of designs can be generated using shape grammar. According to predefined rules, shape grammar can iteratively generate various patterns using shape substitution operations. However, shape grammar can only generate simple shapes, such as lines, points, and rectangles. Therefore, shape grammar is not yet widely used in current Computer-Aided Architectural Design (CAAD) applications. Most designers still design buildings manually or semi-automatically on CAD platforms. Furthermore, because shape grammar only supports unidirectional workflows, it mainly focuses on generating different types of shapes, lacking structural analysis and processing capabilities. Therefore, shape grammars provide insights into the application scope of graph grammars, and the inherent advantages of graph grammars precisely compensate for the shortcomings of shape grammars. Graph grammars initially evolved from string-based formal languages; they are two-dimensional formal methods used to generate and parse graphs through derivation and simplification. Graph grammars have been used in many applications, such as web schema specification and floor plan verification. However, most graph grammars focus only on the specification of abstract graphs, neglecting the specification of the physical layout of the graphs. Consequently, few researchers have applied graph grammars to the fields of graphic drawing or design. Summary of the Invention

[0004] The purpose of this invention is to address the problems existing in the prior art by adding node transformation rules to the graphic method, and proposing a planar pattern design method based on the graphic method. For a target pattern, the structure of the target pattern is first generated using the graphic method, then the points generated by the graphic method are converted into patterns using node transformation rules, and finally the positions of the patterns are adjusted using the edges between the points to finally generate the target pattern.

[0005] The technical solution for achieving the objective of this invention is: a planar pattern design method based on graphic and textual methods, the method comprising the following steps:

[0006] The rules are defined, including constructing a set of graph-textual production rules for generating and analyzing related abstract point-edge graphs, and setting a set of node transformation rules for specific pattern generation requirements;

[0007] Generate a point-edge graph based on the above-defined production rules;

[0008] A pattern is drawn based on the node transformation rules of the point-edge graph;

[0009] Adjust the position of the pattern based on the properties of the edges in the point-edge graph.

[0010] Furthermore, the set of graph-text production rules is specifically a set of vcCGG production rules. Each production rule in the set of vcCGG production rules consists of two point-edge graphs as the left and right ends, forming L→R. Each node in the point-edge graph has a coordinate value as a spatial semantic attribute and a node transformation rule attribute.

[0011] Furthermore, the node transformation rules are defined as follows:

[0012] A node transformation rule consists of a quadruple (cset, mpoint, operation, parameter), where cset is the set of coordinates describing the pattern contour, mpoint is the mean point of cset, operation is the operation that the pattern itself can perform, and parameter is the parameter of the operation.

[0013] Furthermore, the generation of the vertex-edge graph based on the above-defined production rules specifically includes:

[0014] The derivation operation is performed using vcCGG production rules, which means selecting the right side of a production rule to replace the subgraph in the main graph that matches the left side.

[0015] Repeat the previous step until all nodes in the main graph are terminal nodes. This graph is the generated abstract vertex-edge graph.

[0016] Furthermore, the derivation operation using vcCGG production rules, i.e., selecting the right-hand side of a production rule to replace the subgraph in the main graph that matches the left-hand side, specifically includes the following process:

[0017] Choose a production rule GL := GR, and search in the main graph G for a subgraph that is isomorphic to the production rule graph GL and whose corresponding node coordinate differences are equal, as the graph handle;

[0018] The aforementioned difference is added to the coordinates of all nodes on the production graph GR;

[0019] Remove all edges from the handle in the main graph G, as well as nodes that match real nodes in GL;

[0020] Based on the mapping relationship between virtual nodes and graph handle nodes in GL, the virtual nodes of GR are glued together with the corresponding nodes in the graph handle, and the labels of the virtual nodes are removed in the main graph.

[0021] Furthermore, the derivation operation using vcCGG production rules, i.e., selecting the right-hand side of a production rule to replace the subgraph in the main graph that matches the left-hand side, specifically includes the following steps:

[0022] The validity of the generated graph's syntax and semantic model is checked: a reduction operation is performed using the same group of vcCGG production rules, which is the reverse operation of derivation. The validity of the generated graph is determined by whether it can be reduced to the initial graph. If it can be reduced to the initial graph, it means that it meets the constraints of the grammar.

[0023] Furthermore, the specific process of drawing the pattern based on the point-edge graph using the node transformation rules includes:

[0024] 1) Draw a pattern based on the contour described by cset, and make mpoint coincide with the node;

[0025] 2) Deform the pattern according to the operation and parameter;

[0026] 3) Render the pattern from the user's perspective based on the outline described by the cset through its own operations.

[0027] Furthermore, the specific methods of deformation include:

[0028] a) Translation: For pattern A, A can be moved horizontally and vertically.

[0029] Right now a and b are the distances that pattern A moves along the x-axis and y-axis, respectively; (x, y) are the coordinates of any point in pattern A; and (x', y') are the coordinates of (x, y) after translation.

[0030] b) Scaling: For pattern A, A itself can be enlarged or reduced according to a preset ratio.

[0031] Right now S is the factor by which pattern A is enlarged or reduced;

[0032] c) Stretching: For pattern A, A can be stretched or shortened along the horizontal and vertical directions; in particular, if the multiples of stretching or shortening along the horizontal and vertical directions are equal, then A is considered to be scaled.

[0033] Right now Sx and Sy are the multiples by which pattern A is stretched or shortened along the x-axis and y-axis, respectively;

[0034] d) Rotation: For pattern A, A can rotate counterclockwise around its center point MA(X). A ,Y A Rotate by θ, 0 < θ < 2π, that is

[0035] e) Mirror Image: For pattern A, given an arbitrary straight line, the new pattern A' and A are mirror images of this straight line; for any given straight line A1X+B1Y+C1=0, A1 2 +B1 2 >0

[0036] Right now

[0037] Furthermore, adjusting the pattern position based on the attributes of the edges in the point-edge graph specifically includes:

[0038] For patterns A and B, A and B must be in a state of separation, that is, there exists a straight line such that the two patterns are located on opposite sides of the straight line; M A M B These are the center points of A and B, respectively, and A and B are connected by a directed edge E. AB Connection, M A Let M be the starting point of the edge. B The endpoint of the edge;

[0039] 1) Contact: For two patterns, find the closest point in the direction of their connecting edge. The distance between the two points is denoted as d1, which is the distance the starting point moves in the contact state.

[0040] 2) Concentric: The center points of the two patterns coincide, and the distance the starting point moves is denoted as d2;

[0041] 3) Approach: Move towards the destination, where the movable distance L from the starting point is greater than or equal to 0. <d2。

[0042] Furthermore, the movement order for points with an out-degree greater than or equal to 2 is defined as follows:

[0043] 1) When the X-coordinates of the endpoints are different, the starting point moves towards the endpoint with the smaller X-coordinate first;

[0044] 2) When the X coordinates of the endpoints are the same, the starting point moves towards the endpoint with the smaller Y coordinate first.

[0045] Compared with the prior art, the significant advantages of this invention are:

[0046] 1) Shape grammars perform excellently in the design field; however, they execute a unidirectional workflow based on derivation operations and do not inherently support reduction operations. Therefore, shape grammars have limitations in analyzing complex shape structures. This invention combines the advantages of graph grammars and shape grammars. Graph grammars have a bidirectional workflow of derivation and reduction, so complex patterns generated using graph grammars and node transformation rules have reduction capabilities, meaning that structural analysis of the pattern can be performed.

[0047] 2) While graph-based methods can be used to derive and reduce point-edge graphs, they cannot be used to draw patterns. In other words, the grammatical operations of graph-based methods do not involve the visual layout, thus limiting their application in design. This invention adds node transformation rules to the framework of graph-based methods, enabling the point-edge graphs generated by these methods to be converted into specific patterns. Furthermore, the spatial dependencies of the edges are used to adjust the patterns, resulting in the final design pattern.

[0048] The present invention will now be described in further detail with reference to the accompanying drawings. Attached Figure Description

[0049] Figure 1 This is a flowchart illustrating the pattern design based on the graphic method of this invention.

[0050] Figure 2 This is a schematic diagram of production rules and node transformation rules in one embodiment.

[0051] Figure 3 This is a simulated generation result of an illustration of Emma Talbot in one embodiment. Detailed Implementation

[0052] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application.

[0053] It should be noted that if the embodiments of the present invention involve directional indicators (such as up, down, left, right, front, back, etc.), the directional indicators are only used to explain the relative positional relationship and movement of the components in a certain specific posture (as shown in the figure). If the specific posture changes, the directional indicators will also change accordingly.

[0054] Furthermore, if the embodiments of this invention involve descriptions such as "first" or "second," these descriptions are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of those features. Additionally, the technical solutions of the various embodiments can be combined with each other, but this must be based on the ability of those skilled in the art to implement them. If the combination of technical solutions is contradictory or impossible to implement, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection claimed by this invention.

[0055] In generative design, shape grammars only relate different shapes in terms of position, without any structural connection, and lack a fixed paradigm for generating patterns. Therefore, automatically analyzing the generated target pattern presents significant challenges. This invention combines the advantages of graph grammars and shape grammars, improving upon traditional graph grammars by merging derivation reduction workflows and node transformation rules, and proposing a pattern design method with a bidirectional workflow.

[0056] The graph defined by graph grammars is, strictly speaking, a vertex-edge graph in graph theory. The focus of grammatical operations is on generating and analyzing the abstract structure of the graph model, with less direct involvement in its appearance and layout, which to some extent limits its application scope. This invention adds node transformation rules to graph grammars and defines spatial semantic dependencies for edges, enhancing the expressive power of the graph grammar framework.

[0057] Based on the above analysis, in one embodiment, combined with Figure 1 This paper provides a planar pattern design method based on graphic and textual methods, the method comprising the following steps:

[0058] Step 1: Formulate rules, including constructing a set of graph-text production rules for generating and analyzing related abstract point-edge graphs, and setting a set of node transformation rules for specific pattern generation requirements;

[0059] Step 2: Generate a point-edge graph based on the production rules established above;

[0060] Step 3: Draw a pattern based on the point-edge graph using the node transformation rules;

[0061] Step 4: Adjust the position of the pattern based on the properties of the edges in the point-edge graph.

[0062] Furthermore, in one embodiment, taking the Virtual Node Continuous Coordinate Graph (vcCGG) as an example, the set of graph production rules mentioned in step 1 is specifically a set of vcCGG production rules. Each production rule in the set of vcCGG production rules consists of two point-edge graphs as the left and right ends forming L→R. Each node in the point-edge graph has a coordinate value as a spatial semantic attribute and a node transformation rule attribute.

[0063] Furthermore, in one embodiment, the node transformation rule in step 1 is defined as follows:

[0064] A node transformation rule consists of a quadruple (cset, mpoint, operation, parameter), where cset is the set of coordinates describing the pattern outline, mpoint is the mean point of cset, operation is the operation that the pattern itself can perform, such as translation, rotation, scaling, etc., and parameter is the parameter of the operation, such as the direction and magnitude of translation, the degree of rotation, the scaling factor, etc.

[0065] Furthermore, in one embodiment, combined with Figure 2 Step 2, which involves generating a point-edge graph based on the aforementioned production rule, specifically includes:

[0066] Step 2-1: Use vcCGG production rules to perform derivation operations, that is, select the right side of a production rule to replace the subgraph in the main graph that matches the left side.

[0067] Step 2-2: Repeat step 2-1 until all nodes in the main graph are terminal nodes. This graph is the generated abstract vertex-edge graph.

[0068] Furthermore, in one embodiment, combined with Figure 2 The specific process of step 2-1 includes:

[0069] Step 2-1-1: Select a production rule GL:=GR, and search in the main graph G for a subgraph that is isomorphic to the production rule graph GL and whose corresponding node coordinate differences are equal, as the graph handle;

[0070] Step 2-1-2: Add the difference value to the coordinates of all nodes on the production graph GR;

[0071] Step 2-1-3: Delete all edges in the handle and nodes that match real nodes in GL from the main graph G;

[0072] Step 2-1-4: According to the mapping relationship between the virtual nodes of GL and the nodes of the graph handle, glue the virtual nodes of GR to the corresponding nodes in the graph handle, and remove the label of the virtual node in the main graph.

[0073] Furthermore, in one embodiment, combined with Figure 2 Step 2 also includes:

[0074] If it is necessary to perform grammatical structure and semantic model validity checks on the generated graph: use the same group of vcCGG production rules to perform a reduction operation, that is, the reverse operation of derivation. Determine whether the generated graph conforms to the constraints of the grammar based on whether it can be reduced to the initial graph. If it can be reduced to the initial graph, it indicates that it conforms to the constraints of the grammar.

[0075] Furthermore, in one embodiment, step 3, drawing the pattern based on the point-edge graph using the node transformation rules, specifically includes:

[0076] 1) Draw a pattern based on the contour described by cset, and make mpoint coincide with the node;

[0077] 2) Deform the pattern according to the operation and parameter;

[0078] 3) Render the pattern from the user's perspective based on the outline described by the cset through its own operations.

[0079] Furthermore, in one embodiment, the deformation specifically includes:

[0080] a) Translation: For pattern A, A can be moved horizontally and vertically.

[0081] Right now a and b are the distances that pattern A moves along the x-axis and y-axis, respectively; (x, y) are the coordinates of any point in pattern A; and (x', y') are the coordinates of (x, y) after translation.

[0082] b) Scaling: For pattern A, A itself can be enlarged or reduced according to a preset ratio.

[0083] Right now S is the factor by which pattern A is enlarged or reduced;

[0084] c) Stretching: For pattern A, A can be stretched or shortened along the horizontal and vertical directions; in particular, if the multiples of stretching or shortening along the horizontal and vertical directions are equal, then A is considered to be scaled.

[0085] Right now Sx and Sy are the multiples by which pattern A is stretched or shortened along the x-axis and y-axis, respectively;

[0086] d) Rotation: For pattern A, A can rotate counterclockwise around its center point MA(X). A ,Y A Rotate by θ, 0 < θ < 2π.

[0087] Right now

[0088] e) Mirror Image: For pattern A, given an arbitrary straight line, the new pattern A' and A are mirror images of this straight line; for any given straight line A1X+B1Y+C1=0, A1 2 +B1 2 >0

[0089] Right now

[0090] Furthermore, in one embodiment, adjusting the pattern position based on the attributes of the edges in the point-edge graph specifically includes:

[0091] For patterns A and B, A and B must be in a state of separation, that is, there exists a straight line such that the two patterns are located on opposite sides of the straight line; M A M B These are the center points of A and B, respectively, and A and B are connected by a directed edge E. AB Connection, M A Let M be the starting point of the edge. B The endpoint of the edge. After the nodes generate a pattern, the lines connecting the points also evolve into lines connecting the center points of the patterns. This edge is also the trajectory of the starting point. The starting point can move towards the endpoint (closer) or move away from the endpoint (farther). Since the patterns are inherently separated, there is no limit to the distance moved away; no matter how far away, they remain separated. When A moves closer to B, there are two critical values: one is the distance A moves when it contacts B, and the other is M. A With M B The overlapping distances between A and B are said to indicate that A and B are concentric.

[0092] 1) Contact: For two patterns, find the closest point in the direction of their connecting edge. The distance between the two points is denoted as d1, which is the distance the starting point moves in the contact state.

[0093] 2) Concentric: The center points of the two patterns coincide, and the distance the starting point moves is denoted as d2;

[0094] 3) Approach: Move towards the destination, where the movable distance L from the starting point is greater than or equal to 0. <d2。

[0095] Specifically, when the out-degree of a point is greater than or equal to 1, it means that the pattern needs to be moved at least twice. Different movement sequences will lead to different positions, so the movement sequence of points with an out-degree greater than or equal to 2 needs to be defined as follows:

[0096] 1) When the X-coordinates of the endpoints are different, the starting point moves towards the endpoint with the smaller X-coordinate first;

[0097] 2) When the X coordinates of the endpoints are the same, the starting point moves towards the endpoint with the smaller Y coordinate first.

[0098] In one embodiment, a graphic design system based on graphic methods is provided, the system comprising:

[0099] The first module is used to formulate rules, including constructing a set of graph-text production rules for generating and analyzing related abstract point-edge graphs, and setting a set of node transformation rules for specific pattern generation requirements;

[0100] The second module is used to generate a point-edge graph based on the production rules established above.

[0101] The third module is used to draw patterns based on the point-edge graph using the node transformation rules;

[0102] The fourth module is used to adjust the position of the pattern based on the properties of the edges in the point-edge graph.

[0103] Specific limitations regarding the graphic-based planar pattern design system can be found in the limitations of the graphic-based planar pattern design method described above, and will not be repeated here. Each module in the aforementioned graphic-based planar pattern design system can be implemented entirely or partially through software, hardware, or a combination thereof. These modules can be embedded in or independent of the processor in a computer device, or stored in the memory of a computer device as software, so that the processor can call and execute the corresponding operations of each module.

[0104] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to perform the following steps:

[0105] Step 1: Formulate rules, including constructing a set of graph-text production rules for generating and analyzing related abstract point-edge graphs, and setting a set of node transformation rules for specific pattern generation requirements;

[0106] Step 2: Generate a point-edge graph based on the production rules established above;

[0107] Step 3: Draw a pattern based on the point-edge graph using the node transformation rules;

[0108] Step 4: Adjust the position of the pattern based on the properties of the edges in the point-edge graph.

[0109] For specific limitations on each step, please refer to the limitations on the graphic design method based on the graphic method mentioned above, which will not be repeated here.

[0110] In one embodiment, a computer-readable storage medium is provided having a computer program stored thereon, the computer program performing the following steps when executed by a processor:

[0111] Step 1: Formulate rules, including constructing a set of graph-text production rules for generating and analyzing related abstract point-edge graphs, and setting a set of node transformation rules for specific pattern generation requirements;

[0112] Step 2: Generate a point-edge graph based on the production rules established above;

[0113] Step 3: Draw a pattern based on the point-edge graph using the node transformation rules;

[0114] Step 4: Adjust the position of the pattern based on the properties of the edges in the point-edge graph.

[0115] For specific limitations on each step, please refer to the limitations on the graphic design method based on the graphic method mentioned above, which will not be repeated here.

[0116] As a specific example, in one embodiment, the invention is further verified and illustrated as follows:

[0117] Figure 2 This refers to a set of vcCGG production rules and a set of node transformation rules defined in the embodiment. p1, p2, ... p6 is a set of vcCGG production rules, where 'λ' is the initial graph. Nodes labeled '1', '2', '3' with dashed borders are dummy nodes, and nodes labeled '①', '②', '③', etc., are real nodes. 'Point transformation' is a set of node transformation rules. The left side of the rule represents the nodes in the graph grammar, and the right side represents several sets of patterns. Each pattern has a corresponding symbol, such as a rectangle corresponding to '③'.

[0118] Figure 3 This is the derivation process of the embodiment. Starting from the initial graph 'λ', the derivation operation ultimately generates the structure of the pattern. During each derivation step, each generated edge is assigned an attribute, namely, proximity distance or distance from the edge. After generating the pattern structure, a pattern corresponding to a label is generated for each node according to 'point transformation'. Then, the position of the pattern is moved according to the attribute of each edge, ultimately generating a simulation of an illustration by Emma Talbot.

[0119] This invention combines the advantages of graphical and shape grammars. Graphical methods have a two-way workflow of derivation and reduction, so complex patterns generated by graphical methods and node transformation rules have reduction capabilities, that is, structural analysis can be performed on the pattern.

[0120] The foregoing has shown and described the basic principles, main features, and advantages of the present invention. Those skilled in the art should understand that the present invention is not limited to the above embodiments. The embodiments and descriptions in the specification are merely illustrative of the principles of the invention. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention without departing from its spirit and scope should be included within the protection scope of the present invention.

Claims

1. A planar pattern design method based on graphic and textual methods, characterized in that, The method includes the following steps: The rules are defined, including constructing a set of graph-textual production rules for generating and analyzing related abstract point-edge graphs, and setting a set of node transformation rules for specific pattern generation requirements; Generate a point-edge graph based on the above-defined production rules; A pattern is drawn based on the node transformation rules of the point-edge graph; Adjust the position of the pattern based on the properties of the edges in the point-edge graph; The set of graph-text production rules is specifically a set of vcCGG production rules. Each production rule in the set of vcCGG production rules consists of two point-edge graphs as the left and right ends, forming L→R. Each node in the point-edge graph has a coordinate value as a spatial semantic attribute and a node transformation rule attribute. Adjusting the position of the pattern based on the attributes of the edges in the point-edge graph specifically includes: For patterns A and B, A and B must be in a state of separation, that is, there exists a straight line such that the two patterns are located on opposite sides of the straight line; M A M B These are the center points of A and B, respectively, and A and B are connected by a directed edge E. AB Connection, M A Let M be the starting point of the edge. B The endpoint of the edge; 1) Contact: For two patterns, find the closest point in the direction of their connecting edge. The distance between the two points is denoted as d1, which is the distance the starting point moves in the contact state. 2) Concentric: The center points of the two patterns coincide, and the distance the starting point moves is denoted as d2; 3) Approach: Move towards the destination, where the movable distance L from the starting point is greater than or equal to 0. <d2; The movement order for points with an out-degree greater than or equal to 2 is defined as follows: 1) When the X-coordinates of the endpoints are different, the starting point moves towards the endpoint with the smaller X-coordinate first; 2) When the X coordinates of the endpoints are the same, the starting point moves towards the endpoint with the smaller Y coordinate first; The node transformation rules are defined as follows: A node transformation rule consists of a quadruple (cset, mpoint, operation, parameter), where cset is the set of coordinates describing the pattern contour, mpoint is the mean point of cset, operation is the operation that the pattern itself can perform, and parameter is the parameter of the operation.

2. The planar pattern design method based on graphic and textual methods according to claim 1, characterized in that, The generation of the vertex-edge graph based on the above-defined production rules specifically includes: The derivation operation is performed using vcCGG production rules, which means selecting the right side of a production rule to replace the subgraph in the main graph that matches the left side. Repeat the previous step until all nodes in the main graph are terminal nodes. This graph is the generated abstract vertex-edge graph.

3. The planar pattern design method based on graphic and textual methods according to claim 2, characterized in that, The derivation operation using vcCGG production rules, which involves selecting the right-hand side of a production rule to replace the subgraph in the main graph that matches the left-hand side, specifically includes the following steps: Choose a production GL:=GR, and search in the main graph G for a subgraph that is isomorphic to the production graph GL and whose corresponding node coordinate differences are equal, as the graph handle; The aforementioned difference is added to the coordinates of all nodes on the production graph GR; Remove all edges from the handle in the main graph G, as well as nodes that match real nodes in GL; Based on the mapping relationship between virtual nodes and graph handle nodes in GL, the virtual nodes of GR are glued together with the corresponding nodes in the graph handle, and the labels of the virtual nodes are removed in the main graph.

4. The planar pattern design method based on graphic and textual methods according to claim 2, characterized in that, The derivation operation using vcCGG production rules, which involves selecting the right-hand side of a production rule to replace the subgraph in the main graph that matches the left-hand side, further includes the following steps: The validity of the generated graph's syntax and semantic model is checked: a reduction operation is performed using the same group of vcCGG production rules, which is the reverse operation of derivation. The validity of the generated graph is determined by whether it can be reduced to the initial graph. If it can be reduced to the initial graph, it means that it meets the constraints of the grammar.

5. The planar pattern design method based on graphic and textual methods according to claim 1, characterized in that, The process of drawing a pattern based on a point-edge graph using the node transformation rules includes: 1) Draw a pattern based on the outline described by cset, and make mpoint coincide with the node; 2) Deform the pattern according to the operation and parameter; 3) Render the pattern from the user's perspective based on the outline described by the cset through its own operations.

6. The planar pattern design method based on graphic and textual methods according to claim 5, characterized in that, The specific methods of deformation include: a) Translation: For pattern A, A can be moved horizontally and vertically. Right now , and For pattern A in shaft and The distance the axis moves. Let be the coordinates of any point in pattern A. for The coordinates after translation; b) Scaling: For pattern A, A itself can be enlarged or reduced according to a preset ratio. Right now , The factor by which pattern A is enlarged or reduced; c) Stretching: For pattern A, A can be stretched or shortened along the horizontal and vertical directions; if the factors of stretching or shortening along the horizontal and vertical directions are equal, then A is considered to be scaled. Right now Pattern A along shaft and The multiple by which the axis is stretched or shortened; d) Rotation: For pattern A, A can rotate counterclockwise around its center point MA ( , Rotation Right now ; e) Mirroring: For pattern A, given an arbitrary straight line, the new pattern A... A and B are mirror images of this line; for any given line... Right now .

Citation Information

Patent Citations

  • Logic type graph generation method based on graph-text method

    CN114677459A