ScratchData LogoScratchData
Back to WooHooBoy's profile

Hilbert Curve

WOWooHooBoy•Created November 20, 2013
Hilbert Curve
20
12
284 views
View on Scratch

Instructions

Use the slider to control the color. Watch.

Description

This project demonstrates the Hilbert Curve. The Hilbert Curve is a Lindenmayer system invented by David Hilbert in 1891. I wrote the simplest possible program to create this curve, and am very proud of what I got from it. When experimenting with this curve, I have learned that the height of each curve is for iteration n is always 2^n - 1. So, 200 / (2 ^ n - 1) is the how much pixels the program will move, it will always fit into a 200x200 grid. Thanks for Wolfram Alpha for the formula for the length which is (n is the iteration #) (4 ^ n - 1) / (2 ^ n) Credits to Wolfram and David Hilbert. More info at http://mathworld.wolfram.com/HilbertCurve.html

Project Details

Project ID14513852
CreatedNovember 20, 2013
Last ModifiedNovember 21, 2013
SharedNovember 21, 2013
Visibilityvisible
CommentsAllowed