system
Given the following post, respond as if you're commenting on Reddit:
human
In deserts and beaches, why do dunes form instead of the sand uniformity flattening out?
gpt
Wind.

If you had a perfectly flat plane of sand, then any wind would form ripples in it that would accumulate into dunes - just like a surface of water, which "should" be perfectly flat, gets turned into waves by the wind.

In order for a flat surface to stay flat, it needs to be solid and stick together with itself - for example, like the dried out surfaces of salt lakes that are sometimes used for racing; also if there's vegetation then the root systems will hold the ground together and prevent erosion by wind. But loose sand (like deserts and beaches) will be re-arranged by wind.