User Tools

Site Tools


groimp-platform:xl-rules

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
groimp-platform:xl-rules [2025/01/10 12:46] – created gaetangroimp-platform:xl-rules [2025/01/20 18:06] (current) wkurth
Line 1: Line 1:
-GroIMP includes three rules: +GroIMP includes four sorts of rules. 
-==> + 
-Rule in Lindenmayer-form. Simple replacement rule, where one subgraph +| Rule symbol | What it does | 
-(often only one object) is replaced by another graph. The relationships +| %%==>%% | Rule in Lindenmayer-form. Graph replacement rule, where one subgraph (often only one object) is replaced by another graph. The connections between the host graph and the newly-inserted graph are recovered. That means that if, e.g., in a one-dimensional graph [ A B C D ] the node B is replaced by a node G, then G will be inserted into the graph with the original connecting edges to the neighbourhood of the node B: [ A G C D ]. The blank space indicates here a successor edge in XL. Axiom %%==>%% A B C D; B %%==>%% G;| 
-are recovered. That means that if in a one-dimensional graph [ A B C D ] the +| |**Note:** This is a different type of rule than the instantiation rules (which also use %%==>%%)| 
-node B is replaced by a node G, then G will be inserted into the graph with +| %%==>>%% | Rule in SPO-form. Graph replacement rule, where one subgraph is replaced by another graph. The connections between the host graph and the newly-inserted graph need to be specified by the programmer. That means that if, e.g., in a one-dimensional graph [ A B C D ] the node B is replaced by the node G, then the original connections (in- and outgoing edges) of B to the host graph will not be maintained. If an edge going from A to is not explicitly stated, then there will be no connection between the nodes A and G in the rewritten graph. This entails that the nodes G (formerly B), C and D will be no more visible, which means they are effectively deleted. Only the (unconnected) node remains. Axiom %%==>%% A B C D; B %%==>>%% G; In order to achieve the same result as in the example above (Lindenmayer-form), it is necessary to explicitly list the connecting edges from to G and from G to C on the right-hand side of the rule: Axiom %%==>%% A B C D; a:A B c:C %%==>>%% a G c; This rule type is frequently used to delete subgraphs. Axiom %%==>%% A A [ B A A A ] A A [ C A A ] A%%==>>%% ; The resulting graph reads as follows: ''A A A A [ C A A ] A''| 
-the original relationship of the node B: [ A G C D ]. The blank space always +| %%::>%% | Update rule. This rule type does not change the structure of the graph. It is used to change the attributes of the objects (nodes) of the graph. c:C ::> {c[length] = c[length] * 20; } 
-indicates a successor edge in XL. +| %%==>%% | Instantiation rule. It is NOT used after a query, but after a class / module declaration. It adds geometric (or other sort of) information to all nodes of the declared type. | 
-Axiom ==> A B C D; + 
-B ==> G; + 
-==>> + 
-Rule in SPO-form. Complex replacement rule, where one subgraph is + 
-replaced by another graph. The relationships need to be recovered by the +
-programmer. That means that if in a one-dimensional graph [ A B C D ] +
-the node B is replaced by the node G, then the original relationships of B in +
-the graph will not be maintained. If the relationship to is not explicitly +
-stated, then there will be no connection of the nodes C D to the graph. +
-This entails that the nodes are no more visible, which means they are +
-effectively deleted. Only the (unconnected) nodes and G remain. +
-Axiom ==> A B C D; +
-B ==>> G;In order to achieve the same result as in the example above (Lindenmayer- +
-form), it is necessary to explicitly list the relationships to A and C on the +
-right-hand side of the rule: +
-Axiom ==> A B C D; +
-a:A B c:C ==>> a G c; +
-This rule type is frequently used to delete subgraphs. +
-Axiom ==> A A [ B A A A ] A A [ C A A ] A +
-B ==>> ; +
-The resulting graph reads as follows A A A A [ C A A ] A+
-::> +
-Update rule. This rule type does not change the structure of the graph. It is +
-used to change the attributes of the objects (nodes) of the graph. +
-c:C ::> {c[length] = c[length] * 20; }+
groimp-platform/xl-rules.1736509571.txt.gz · Last modified: 2025/01/10 12:46 by gaetan