Saturday, February 2, 2013

Geologeez Nutz

Not done anything lately on tectonics simulations, but I realized that there was a bunch of crap I'd done last fall that I had never posted about, so thought I'd describe it, to remind myself where I left everything if for no other reason.

The main change was making tiles have layers of rock instead of just single elevation values, and different rock types for each layer.

The first continent is a hunk of igneous extrusive rock of varying composition, and the planet begins with no atmosphere or life:

Initial supercontinent with no life

When the atmosphere kicks in then you get erosion, which varies based on climate and grinds layers from the top down to create sedimentary rock of progressively smaller grain sizes.

When life shows up there is an additional organic component to sediments, which makes limestone and chalk in the right environment that can in turn make marble, though probably too rarely. Life marks tiles as having peat bogs where it makes sense as well, so there's the potential to figure out where fossil fuels end up.

Crustal thickness leads to regional metamorphism, and subduction causes igneous intrusions with associated contact metamorphism. Erosion affects rocks based on how tough they are, so fresh mountains should grind down to craggy hornfels and granite shields should eventually emerge.

The merging of tiles due to the constraints of math on a sphere tries to preserve uniqueness, so peak elevations and metamorphic layers don't get averaged away. Not scientifically justifiable, really.

I added the ability to click on a tile (in the Mercator and Sinusoidal projections) and see the layers of that tile, with a tooltip showing the full composition of a given layer. I also added the crappy "color" display mode that mostly just suddenly turns green when life shows up and then shows you where mountains are:

Layer information with composition tooltip

I also did some profiling that led to some optimizations, mainly around the bogus climate model but also caching various calculations that were repeated all over the place. This got things moving quick enough that I could start thinking about supercontinent cycles again, but none of the various forays I made into getting any of that to work out nicely panned out.

Planet with a couple continents showing different climates

The other improvement in the offing is figuring out metals, basically banded iron formations and the veins of stuff that go along with igneous intrusions and create placer deposits when they erode.

Also found a dude on Reddit who has a similarly-conceived project, pyTectonics. He's taken a more scientifically rigorous approach and does things on a Fibonacci grid, which looks pretty awesome. I'm not exactly sure, but it also sounds like he creates and destroys new grid points as needed, which is a cool idea.

Edit: Forgot to link to the source.