What comes to mind when you hear the word chaos? Perhaps you think of a noisy
stock exchange, or your kitchen in the morning—everything confused and jumbled.
When you think of the word order, perhaps you think of an empty room, serene and
calm. For scientists, though, chaos is characterized by homogeneity (sameness), and
order by complexity (difference).
For example, a well-tended garden is a highly ordered system. Gardeners define
boundaries with paths and fences, and they mark out flower beds or vegetable
patches. Over time, the garden evolves, growing richer and thicker; but without
deliberate effort, the garden will run wild. Weeds and grasses will choke out other
plants, covering over the paths, until eventually every part looks the same again—
wild and unmanaged.
Software systems, too, tend toward chaos. When we first start building a new system,
we have grand ideas that our code will be clean and well ordered, but over time we
find that it gathers cruft and edge cases and ends up a confusing morass of manager
classes and util modules. We find that our sensibly layered architecture has collapsed
into itself like an oversoggy trifle. Chaotic software systems are characterized by a
sameness of function: API handlers that have domain knowledge and send email and
perform logging; “business logic” classes that perform no calculations but do perform
I/O; and everything coupled to everything else so that changing any part of the sys?
tem becomes fraught with danger