L-Systems used to create visualizations from language
By Ralph Kok, Hanco Hogenbirk and Rick Companje.
Supervised by Crit Cremers, Leiden University
Abstract
In this paper we present a concept for using language characteristics in generating artistic visualizations. It describes how the recursive nature of L-Systems can be used to create visual representations of sentences created by the language generating and parsing computer program Delilah.
Keywords: L-Systems, Delilah, Language, Visualizations, Language and Text, Media Technology
Download PDF
L-Systems and the Delilah System
L-Systems (Lindenmayer-systems) have been developed by the biologist A. Lindenmayer [to describe the growth and development of algae and other botanic organisms. An L-System is basically a string-rewriting system, consisting of a starting value and a set of rules defining how it changes. The beauty of L-Systems is that they can be (and are) used to describe complex plantlike and fractal-like structures in a simple way. More on L-Systems can be found at Wikipedia [1].
“Delilah parses and generates complex Dutch sentences over a dedicated lexicon by applying a combinatory categorical grammar under graph unification.†[2]. The Delilah application is able to analyze given sentences to extract semantic and grammatical information, as well as to generate grammatically correct sentences when given a concept or subject.
A linguistic application of L-systems
Our concept is as follows: Delilah is given a concept and outputs a sentence along with all the information that describes this sentence, such as its grammatical structure. The grammatical information is used to generate visual output from, which will be interpreted by human viewers. Their reaction in turn will serve as input for Delilah, closing the loop and restarting the process.
The way we apply the grammatical information to L-Systems is to generate rules according to the structure of the sentence. Practically, this means our system reads word categories and translates them to symbols that compose the string-rewriting rule that will be used in generating the L-System structure. In this manner, every grammatically different sentence will lead to a different rule and will yield a new shape.
The shape is output visually and presented to the viewer as a kind of abstract ‘ink blob’, inviting the viewer to interpret the shape. The viewer is asked to enter his or her interpretation into the system again which serves as a new concept for Delilah to generate a new sentence from, which results again in a new visual shape.
Results
For example, the Dutch sentence “verwijder een aanpassingsproces en bestrijd dramatisch werk!” is a combined sentence of two Delilah clauses. When you replace the words by symbols using the following rules: verb = ‘+’, noun = ‘-‘, adjective = ‘|’, article = ‘[‘, conjunction = ‘]’, space = ‘F’; you will get the sequence: +F[F-F]F+F|F-. This sequence can be used as the string-rewriting rule that defines the L-System. This rule will be applied every iteration, resulting in complex visual shapes.


There are some personal choices involved in building these rules, as the translation is based on a personal selection of symbols. These choices are influenced by our knowledge of what works and what doesn’t. For example, only the ‘F’ symbol yields visible output, so we need many ‘F’ symbols to see any interesting shape at all. Therefore, we chose to translate the space character to an ‘F’. However, this choice will result in every word being followed by a drawing command, and so each word will influence the actual shape directly and therefore this seems to be a logical choice.
One very important other occurrence of personal choice influencing the system is in how to treat the symbols to draw a shape on the screen. Different actions, colors, shapes and angles can be selected for this, which can also have its effect on which translations of words to rules work well. In short, the output depends very much on personal choices, but this does not make it less interesting.
Future work
An issue when using L-systems in this manner is of course that sentences with the same structure will yield the same results, as the translation to a L-system is not based on meaning or specific words, but on word types. This problem can be solved by using semantic structure instead of the grammatical structure of a text.
Furthermore, punctuation such as comma’s or exclamation marks could be used to effect the visualization.
Also, different variations can be thought of for different applications, such as tonal input to generate trees, so that people with speech impediments can try to “reach†a certain shape and thus learn to speak properly.
Finally, L-systems can be animated by already drawing a part of the visual shape during the iteration process. In this way, the system ‘grows’ during the generation of the L-system string. A finished visualization can also be animated by changing the way in which symbols are presented visually in real-time, for instance changing the angles of rotation or the length of the lines.
References
[1] Wikipedia about L-systems: http://en.wikipedia.org/wiki/L-system
[2] C. Cremers, The Linguistics of Delilah - Delilah demo cd-rom