rgg:rgg-manual
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
rgg:rgg-manual [2024/04/29 18:06] – [Table of Contents] gaetan | rgg:rgg-manual [2024/10/11 13:00] (current) – [XL and Java extension] gaetan | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== Table of Contents ====== | ====== Table of Contents ====== | ||
- | * [[: | + | * [[: |
* [[: | * [[: | ||
* [[: | * [[: | ||
* [[: | * [[: | ||
- | ==== List of Figures ==== | ||
- | - [[: | ||
- | ====== | + | ====== |
- | ==== Overview ==== | + | The programming language XL is defined as an extension of the Java programming language. Thus the XL programming language benefits from the well-grounded concepts of structured, modular and object-oriented programming on which the Java programming is based. Being an extension not only at the level of the language specification, |
+ | Within a XL (or RGG) file, it is possible to write both XL code and Java code. XL sections are defined with '' | ||
- | //Growth grammars// are a rule-based approach to the modelling of dynamic systems. In contrast to conventional imperative programming languages, rule-based approaches provide a natural and concise way of modelling: Most systems to be modeled behave according to a set of rules, and our perception works this way and not imperatively using a list of operations which have to be processed step by step. | + | It is highly recommended to learn a basic usage of [[https://docs.oracle.com/en/java/ |
- | Relational growths grammars (RGG) are part of the current research at the [[http:// | + | See more: |
+ | * [[http:// | ||
+ | * [[: | ||
+ | * [[: | ||
+ | * [[: | ||
+ | * [[: | ||
+ | * [[: | ||
- | ==== Opening a RGG file ==== | ||
- | GroIMP | + | ====== |
- | <code java> | ||
- | import de.grogra.rgg.*; | ||
- | import de.grogra.lsystem.*; | ||
- | public class Koch extends RGG { | + | //Growth grammars// are a rule-based approach to the modelling of dynamic systems. In contrast to conventional imperative programming languages, rule-based approaches provide a natural and concise way of modelling: Most systems to be modeled behave according to a set of rules, and our perception works this way and not imperatively using a list of operations which have to be processed step by step. |
- | public void derivation() [ | + | |
- | Axiom ==> F(10) RU(120) F(10) RU(120) F(10); | + | |
- | F(x) ==> F(x/3) RU(-60) F(x/3) RU(120) F(x/3) RU(-60) F(x/3); | + | |
- | ] | + | |
- | } | + | |
- | </ | + | |
- | You can open an XL file like the one shown file via the menu item File/Open, this creates a new project containing | + | Relational growths grammars (RGG) are part of the current research at the [[http:// |
- | **Figure 1.1. Panels in the RGG Layout** | + | See more: |
+ | | ||
- | {{: | ||
- | |||
- | The meta object browser displays objects which have an influence on the scene, but which are not part of the material scene. The RGG object is an example of such an object, and if you open an XL file containing an RGG class, an instance of this class will be created automatically (if the file can be compiled successfully) and inserted into the list of meta objects. By a double click on the RGG object, its editable attributes (the public fields which are declared in its class and are annotated by '' | ||
- | |||
- | ==== Working with a Relational Growth Grammar ==== | ||
- | |||
- | |||
- | After an RGG object has been loaded successfully from an XL file, its public methods are made available in the RGG toolbar. Each method appears twice: In the list prefixed with Apply, a click invokes the method once, in the list prefixed with Run, a click starts the repeated invocation of the method. To stop this loop, click the Stop button in the toolbar. Initially, buttons for the first method are accessible immediately; | ||
- | |||
- | Normally, RGG methods cause the application of graph grammar rules to the scene. This is the case for the examples provided at GroIMP' | ||
- | |||
- | The XL source code of a relational growth grammar can be edited in GroIMP' | ||
- | |||
- | If the filename ends in '' | ||
====== Graph Manipulations ====== | ====== Graph Manipulations ====== | ||
- | You can find more information | + | To manipulate the Graph in RGG so called rewriting rules are used. |
- | + | These rules consist of three elements: | |
- | The list of graph operations can be found [[:groimp-platform: | + | * a pattern |
- | + | | |
- | An example | + | |
- | + | ||
- | The graph support queries following [[:groimp-platform: | + | |
- | An example with basic queries can be found [[:Tutorials:common_graph_queries|here]]. | + | See more: |
+ | * [[: | ||
+ | * [[: | ||
+ | * [[: | ||
+ | * [[:groimp-platform:xl-operators|List of XL operators]] | ||
+ | Tutorials: | ||
+ | * [[: | ||
+ | * [[: | ||
+ | * [[: | ||
====== Additional formats ====== | ====== Additional formats ====== |
rgg/rgg-manual.1714406801.txt.gz · Last modified: 2024/04/29 18:06 by gaetan