According to ancient legend, a beautiful maiden named Ashima drowned in a river, and turned into stone. This, it has been said for centuries, is how China's stunning Stone Forest of Shilin first took shape.

According to new research, however, there's another explanation for the phenomenon that gives stone forests their surreal and otherworldly forms, and while it might not quite match the magic and mystery of Ashima's tragic tale, it is perhaps a more convincing take in these modern, sceptical times.

In a new study, scientists investigated the formation processes behind these jagged pillars, which naturally take on their spiky shapes after mineral formations submerged in water slowly dissolve over time once they become exposed to the air.

010 stone forests 2Stone Forest of Shilin. (Westend61/Getty Images)

"This work reveals a mechanism that explains how these sharply pointed rock spires, a source of wonder for centuries, come to be," says experimental physicist Leif Ristroph from New York University.

"Through a series of simulations and experiments, we show how flowing water carves ultra-sharp spikes in landforms."

While it might take decades or centuries for a real stone forest to blossom, the same trick can be observed in just hours with a suitable analogue, the researchers found. In this case, they used candy.

010 stone forests 2False-colour photo of candy pinnacles 'forest' dissolved in water. (NYU's Applied Mathematics Lab)

Stone forests are an example of karst topographies, but the hydrological conditions that sharpen the tips of their rocky 'trees' can be mimicked in the lab – or even just the kitchen, it seems – using a recipe of table sugar, corn syrup, and water.

In the right ratios, this makes something called hard-crack candy, which is composed of about 99 percent sugar content. When a block of this candy seeded with an imprint of smooth surface shapes was immersed in water and then removed, the researchers observed it progressively dissolve into an array of sharp spikes in the space of about 2 hours.

"Needlelike pinnacles, as well as bed-of-nails-like arrays of pinnacles, emerge robustly from the dissolution of solids with smooth initial shapes," the researchers explain in their paper.

"Although the liquid is initially quiescent and no external flow is imposed, persistent flows are generated along the solid boundary as dense, solute-laden fluid descends under gravity."

In a separate experiment, the researchers simulated the process in a mathematical model, which confirmed that self-sculpting pinnacles result during dissolution, due to natural convective flows that end up enhancing dissolution rates in a feedback loop that makes the shards sharper, rather than blunter.

As to how the same process creates stone forests in the real world, the team thinks that fluid-filled pores or fissures in porous rock could act as conduits for the same kind of flows, with minor cavities expanding as their surfaces dissolve, and ultimately spawning sharp rocky columns.

"Our pinnacle arrays form via dissolutive widening of pores, whose initial arrangement set the pattern of pinnacles, and a similar progression toward stone forests is thought to be initiated by vertical columns between intersecting fissures," the authors write.

In a lab setting, with a contrived, pre-shaped block of candy, the results produce a neat and symmetrical array of spikes, but as actual stone forests show, the same order is not apparent when this process plays out in the real world – creating a myriad of shapes so striking and unexpected, they can even give rise to legends.

"These events yield a bed-of-nails morphology, here, a square lattice of spikes that reflects the initial lattice of pores," the team explains.

"More random seeding of pore locations is expected to generate disordered arrays of pinnacles of varying girth and height, which may more closely resemble natural pinnacles and stone forests."

The findings are reported in PNAS.