Gosper curve
The Gosper curve is a fractal and space-filling curve . It is named after Bill Gosper . Similar to the Dragon Curve and Hilbert Curve , it is created by substitution.
Algorithms
Lindenmayer system
The Gosper curve can be described by a Lindenmayer system with the following properties:
- Angle: 60 °
- Start string:
- Derivation rules:
logo
A program for generating the Gosper curve in Logo :
to rg :st :ln
make "st :st - 1
make "ln :ln / 2.6457
if :st > 0 [rg :st :ln rt 60 gl :st :ln rt 120 gl :st :ln lt 60 rg :st :ln lt 120 rg :st :ln rg :st :ln lt 60 gl :st :ln rt 60]
if :st = 0 [fd :ln rt 60 fd :ln rt 120 fd :ln lt 60 fd :ln lt 120 fd :ln fd :ln lt 60 fd :ln rt 60]
end
to gl :st :ln
make "st :st - 1
make "ln :ln / 2.6457
if :st > 0 [lt 60 rg :st :ln rt 60 gl :st :ln gl :st :ln rt 120 gl :st :ln rt 60 rg :st :ln lt 120 rg :st :ln lt 60 gl :st :ln]
if :st = 0 [lt 60 fd :ln rt 60 fd :ln fd :ln rt 120 fd :ln rt 60 fd :ln lt 120 fd :ln lt 60 fd :ln]
end
The program can be rg 4 300
called with, for example . Alternatively also with gl 4 300
.
Gosper Island
The area enclosed by the Gosper curve is called Gosper Island and is a variant of Koch's snowflake . The area is suitable for parquet floors .
Web links
- Eric W. Weisstein : Gosper Island . In: MathWorld (English).
- About the Gosper curve (PDF)
- mathcurve.com