next up previous contents
Next: Branching and bracketed L-systems Up: L-systems Previous: Turtle graphics and L-systems

FRACTINT conventions

 

For reference, here are the complete list of FRACTINT L-system symbols. This is extracted mainly from the FRACTINT online manual. We assume a unit length d and a standard angle increment tex2html_wrap_inline5530 has been established, which must be of the form tex2html_wrap_inline5532 where n is a positive integer. The standard drawing commands are:

F:
Draw forward one unit.
G:
Move forward one unit (without drawing).
+:
Increase angle by tex2html_wrap_inline5530 counterclockwise.
-:
Decrease angle by tex2html_wrap_inline5530 clockwise.
|:
Try to turn 180 degrees. (If n is odd, where tex2html_wrap_inline5646 , the turn will be the largest possible turn less than 180 degrees which is a multiple of tex2html_wrap_inline5530 .)

The above commands are especially fast because the angles are restricted to multiples of tex2html_wrap_inline5530 . However, if it is required to turn at more general angles, one may use the following commands which keep a completely separate angle pointer specified in degrees.
D:
Draw forward one unit.
M:
Move forward one unit (without drawing).
tex2html_wrap_inline5656 :
Increase angle nn degrees counterclockwise.
/nn:
Decrease angle nn degrees clockwise.

These are the commands for changing colors based on the current FRACTINT color map. The color map associates different colors to a sequence of positive integers. FRACTINT has builtin procedures for changing color maps.

Cnn:
Select color nn
<nn:
Increment color by nn
>nn:
Decrement color by nn

These are the bracketing commands for modelling branched structures. We will give some examples in the next section.

tex2html_wrap_inline5676 :
``Push:'' This stores the current position and heading on a memory stack.
tex2html_wrap_inline5678 :
``Pop:'' This causes the ``turtle'' to return to the last position and heading stored on the memory stack. It ``pops'' this position off the stack.
!:
Reverse directions (Switch meanings of +, -, / and tex2html_wrap_inline5688 )
@nnn:
Multiply line segment size d by scale factor nnn. The new size will be in effect until another @ command. nnn may be a plain number, or may be preceded by I for inverse, or Q for square root. For instance, @I2 gives a factor of 1/2, @Q2 gives tex2html_wrap_inline5710 , and @IQ2 gives tex2html_wrap_inline5714 .

The last two commands coupled with the pop and push commands can achieve very elaborate branching structures.


next up previous contents
Next: Branching and bracketed L-systems Up: L-systems Previous: Turtle graphics and L-systems

David J. Wright
Mon Aug 19 17:21:15 CDT 1996