GeodynamicWorldBuilder / WorldBuilder

World Builder: An initial conditions generator for geodynamic modeling
GNU Lesser General Public License v2.1
23 stars 29 forks source link

Add velocity plugin system #528

Open MFraters opened 10 months ago

MFraters commented 10 months ago

For numerical models it can be useful to have for example velocity boundary conditions defined per tectonic feature. This would require

  1. to add an extra output interface, similar to temperature, compositions or grains. The default output should probably be zero.
  2. Add a new plugin system in the .cc files in source/world_builder/features/ (except for interface.cc)
  3. Add at least one plugin to source/world_builder/features/*/velocity/

The part which needs to be thought out is how to design the input. In Cartesian coordinates, providing a single vector and/or providing a function should work well enough. In spherical coordinates, I think the most useful representation is probably an euler pole. I don't directly see a use case for providing a single vector in spherical coordinates, but I am happy to be convinced. If this would be the case, then the plugin would interpretate the single vector in Cartesian coordinates as a Cartesian vector to apply in that feature, and in spherical coordinates as an euler pole, and compute the Cartesian velocity vector at the requested location.

It could look something like this:

{
    "velocity models":
     [
         {"model":"uniform", "vector":[1,2,3], "max depth":100e3},
         {"model":"uniform", "vector":[-1,-2,-3], "min depth":100e3}
     ]
}

Another possible plugin would be to provide an ascii-data plugin, which could be used to for example prescribe the result of a global model to a regional model.

MFraters commented 1 month ago

An other possible model would be a vertical compensating model, where a velocity is specified between certain depth ranges and the resulting "inflow" or "outflow" would be compensated by an equivalent in- or outflow, with a transition zone between the two if desired.

It would allow for easily set and modify the following boundary condition: image

It could look something like this:

{"model":"vertical compensate", "min depth": 0, "max depth":500e3, "max transition length":10e3,
  "forcings":[{"vector":[1,2,3],"min depth":0, "max depth":100e3}]}
MFraters commented 1 month ago

I have a proof of concept implementation. It is still very rudimentary, but it can output velocity (both gwb-grid and gwb-dat) using a velocity modules for each feature.

image