Encyclopedia of fractals · Curve

Hilbert curve

A continuous curve that passes through every point of a square. Each stage is a single path that visits all cells of a finer grid; in the limit the curve fills the whole square, so a one-dimensional line ends up two-dimensional.

How it is built

Stage 1 is a U shape through the four quarters of a square. To go from stage n to n + 1, place four copies of stage n in the four quarters, rotate the first and the last so that the path enters and leaves at the right corners, and connect them. As an L-system: A → +BF−AFA−FB+, B → −AF+BFB+FA−, angle 90°.

Properties

Where you meet it

Hilbert ordering is used to store maps and images in databases so that nearby places stay close in memory, to schedule work on processors, to dither images and to sort points for faster searches.

Related fractals

Cite this page
APA

Fractalist. (2026). Hilbert curve: Encyclopedia of fractals. ForeFractal. https://forefractal.com/fractals/hilbert-curve/

MLA

Fractalist. “Hilbert curve: Encyclopedia of fractals.” ForeFractal, 2026, https://forefractal.com/fractals/hilbert-curve/. Accessed .

BibTeX
@misc{forefractal-fractals-hilbert-curve,
  author = {Fractalist},
  title = {Hilbert curve: Encyclopedia of fractals},
  year = {2026},
  howpublished = {\url{https://forefractal.com/fractals/hilbert-curve/}},
  note = {ForeFractal}
}