Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Dragon Curve #15

Open
trebeljahr opened this issue Sep 29, 2022 · 0 comments
Open

Add Dragon Curve #15

trebeljahr opened this issue Sep 29, 2022 · 0 comments
Labels
new-fractal Add a new fractal to the garden.

Comments

@trebeljahr
Copy link
Owner

Description

Implement the L-System version of the Dragon Curve. Ideally there would be L-Systems for the Dragon, Twindragon and Terdragon! Wikipedia has instructions for each :)

Inspiration

Wikipedia - Dragon Curve

Type

L-System

Difficulties

Centering the L-System is a little bit difficult, since with each iteration it rotates some more.
L-System configuration is easy though:

const dragonCurve = {
  maxIterations: 18,
  axiom: "F",
  replace: {
    F: "F+G",
    G: "F-G",
  },
  angle: 90,
};
@trebeljahr trebeljahr added the new-fractal Add a new fractal to the garden. label Sep 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
new-fractal Add a new fractal to the garden.
Projects
None yet
Development

No branches or pull requests

1 participant