Object hierarchy

From Gerris

(Difference between revisions)
Jump to: navigation, search
Revision as of 02:58, 5 October 2011
Popinet (Talk | contribs)
(Variables - added VariableVOFConcentration)
← Previous diff
Current revision
Popinet (Talk | contribs)
(Particulates)
Line 56: Line 56:
*** '''[[GfsVariableFunction]]''' — Optimising function evaluations *** '''[[GfsVariableFunction]]''' — Optimising function evaluations
**** '''[[GfsVariableStreamFunction]]''' — Maintaining a velocity field defined by a stream function **** '''[[GfsVariableStreamFunction]]''' — Maintaining a velocity field defined by a stream function
 +**** '''[[GfsVariablePoisson]]''' — Maintaining a scalar field solution of a Poisson equation
 +**** '''[[GfsVariableAverage]]'''
 +**** '''[[GfsVariableLaplacian]]''' — Laplacian of a function
*** '''[[GfsVariableCurvature]]''' — Curvature of an interface *** '''[[GfsVariableCurvature]]''' — Curvature of an interface
**** '''[[GfsVariablePosition]]''' — Coordinates of a VOF interface **** '''[[GfsVariablePosition]]''' — Coordinates of a VOF interface
Line 61: Line 64:
*** '''[[GfsVariableBoolean]]''' — Boolean value consistent with adaptive refinement *** '''[[GfsVariableBoolean]]''' — Boolean value consistent with adaptive refinement
*** '''[[GfsVariableAge]]''' — How old is this cell? *** '''[[GfsVariableAge]]''' — How old is this cell?
 +*** '''[[GfsHydrostaticPressure]]''' — Hydrostatic pressure integration
** '''[[GfsConstant]]''' — Spatially-constant but time-dependent variables ** '''[[GfsConstant]]''' — Spatially-constant but time-dependent variables
***'''[[GfsDischargeElevation]]''' — Elevation for a given discharge ***'''[[GfsDischargeElevation]]''' — Elevation for a given discharge
Line 80: Line 84:
=== General orthogonal coordinates === === General orthogonal coordinates ===
 +* '''[[GfsMetric]]''' — Analytical metrics
* '''[[GfsMetricLonLat]]''' * '''[[GfsMetricLonLat]]'''
* '''[[GfsMetricCubed]]''' * '''[[GfsMetricCubed]]'''
* '''[[GfsMetricStretch]]''' — Anisotropic mesh stretching * '''[[GfsMetricStretch]]''' — Anisotropic mesh stretching
- +* '''[[GfsMetricLaplace]]''' — Numerically-defined transformation
* '''[[GfsMap]]''' — Coordinates transformations * '''[[GfsMap]]''' — Coordinates transformations
** '''[[GfsMapTransform]]''' — Isometric coordinates transformations ** '''[[GfsMapTransform]]''' — Isometric coordinates transformations
Line 132: Line 137:
*** '''[[GfsAdaptGradient]]''' — Adapting cells depending on the local gradient of a variable *** '''[[GfsAdaptGradient]]''' — Adapting cells depending on the local gradient of a variable
**** '''[[GfsAdaptError]]''' — Adapting using an a posteriori error estimate **** '''[[GfsAdaptError]]''' — Adapting using an a posteriori error estimate
-*** '''[[GfsAdaptStreamlineCurvature]]''' 
*** '''[[GfsAdaptFunction]]''' — Adapting cells depending on the value of a function *** '''[[GfsAdaptFunction]]''' — Adapting cells depending on the value of a function
*** '''[[GfsAdaptThickness]]''' — Adapting cells according to the thickness of interfacial films *** '''[[GfsAdaptThickness]]''' — Adapting cells according to the thickness of interfacial films
Line 168: Line 172:
***** '''[[GfsSourceTensionCSS]]''' ***** '''[[GfsSourceTensionCSS]]'''
**** '''[[GfsSourceHydrostatic]]''' **** '''[[GfsSourceHydrostatic]]'''
 +*** '''[[GfsSourcePipe]]''' — Pipes and culverts models for [[GfsRiver]]
=== Outputs === === Outputs ===
Line 200: Line 205:
**** '''[[GfsOutputGRD]]''' — Writing 2D ESRI raster files **** '''[[GfsOutputGRD]]''' — Writing 2D ESRI raster files
*** '''[[GfsOutputObject]]''' — Calling the write method of a given object *** '''[[GfsOutputObject]]''' — Calling the write method of a given object
 +*** '''[[GfsOutputSectionFlux]]''' — Writing the the fluxes of tracers through specified planar slices either due to advection and diffusion
== Modules == == Modules ==
Line 274: Line 280:
=== Particulates === === Particulates ===
-This is an attempt at documenting the particulates module.+The particulate module defines (active) Lagrangian particles coupled with the flow. [[GfsParticulate]]s respond to forces (typically exerted by the fluid) and can exert forces on the fluid in response.
-I think I understand how it works, that might help you to get started.+
-Please complete that section if you can.+
- +
-The aim of the particulate module is to allow to have Lagrangian particles in a Gerris simulation. Contrarily to [[GfsOutputParticle]] which only allows to simulate inert particles, a [[GfsParticulate]] can have physical properties such as a mass and a volume. Initial forces and velocity can also be specified.+
-The syntax for the use of the particulate module is completely different to the one of [[GfsOutputParticle]] and is mainly detailed in [[GfsParticleList]].+
The module is initialised in parameter files using The module is initialised in parameter files using
GModule particulates GModule particulates
- 
-and allows to create lists of Lagrangian particles using the keyword [[GfsParticleList]]. 
-Each list contains [[GfsParticle]] (inert) or [[GfsParticulates]] which are advected by the velocity field and can experience various types of forces ([[GfsForceLift]], [[GfsForceDrag]], [[GfsForceBuoy]]).\ 
The module defines the following objects (in bold): The module defines the following objects (in bold):
Line 292: Line 290:
* [[GfsEvent]] * [[GfsEvent]]
** [[GfsEventList]] ** [[GfsEventList]]
-*** [[GfsParticleList]]+*** '''[[GfsParticleList]]''' — List of [[GfsParticulate]]s acted on by forces
-**** [[GfsFeedParticle]]+**** '''[[GfsFeedParticle]]''' — Injection of particles
-**** [[GfsDropletToParticle]]+**** '''[[GfsDropletToParticle]]''' — Conversion of tracers to particles
** [[GfsParticle]] ** [[GfsParticle]]
-*** [[GfsParticulate]]+*** '''[[GfsParticulate]]''' — A [[GfsParticle]] which responds to forces
-* [[GtsSListContainee]]+* '''[[GfsParticleForce]]''' — A force acting on a [[GfsParticulate]]
-** [[GfsParticleForce]]+** '''[[GfsForceBuoy]]''' — The buoyancy force
-*** [[GfsForceCoeff]]+** '''[[GfsForceCoeff]]''' — Generic class for forces with coefficients
-**** [[GfsForceLift]]+*** '''[[GfsForceLift]]''' — The lift force
-**** [[GfsForceDrag]]+*** '''[[GfsForceDrag]]''' — The drag force
-**** [[GfsForceBuoy]]+
* [[GfsVariable]] * [[GfsVariable]]
Line 359: Line 356:
journal = {Journal of Computational Physics}, journal = {Journal of Computational Physics},
year = {2010}, year = {2010},
 + volume = {230},
 + pages = {1939-1955},
url = {http://gfs.sf.net/papers/ehd.pdf} url = {http://gfs.sf.net/papers/ehd.pdf}
} }
Line 384: Line 383:
* [[GfsOutput]] * [[GfsOutput]]
** '''[[GfsOutputSpectra]]''' — FFT output ** '''[[GfsOutputSpectra]]''' — FFT output
 +
 +=== Culvert ===
 +
 +Modelling the effect of [[w:culverts|culverts]] within the [[GfsRiver]] solver. The module is initialised in parameter files using
 +
 + GModule culvert
 +
 +The module defines the following object:
 +
 +* [[GfsSourcePipe]]
 +** '''[[GfsSourceCulvert]]''' — Culvert model based on Boyd, 1987
=== GfsView === === GfsView ===
Line 414: Line 424:
== Command-line programs == == Command-line programs ==
 +* [[gerris]] — The Gerris flow solver simulation engine
* '''[[gfsview-batch]]''' — Command-line description of GfsView (in batch and interactive mode) * '''[[gfsview-batch]]''' — Command-line description of GfsView (in batch and interactive mode)

Current revision

Contents

Introduction

This page describes all the objects which can be used in Gerris parameter files. The syntax of each object is given using a simple convention which expresses "inheritance" from the parent object. This is more simply explained using an example e.g. GfsOutputScalarSum. The syntax of this object is described as

[ GfsOutputScalar ]

which means that this object is a descendant of GfsOutputScalar. Following the link gives the syntax of GfsOutputScalar as

[ GfsOutput ] {
  v = [ GfsFunction ]
  maxlevel = 6
  min = -12.1
  max = 1e3
  box = -0.1,-0.1,0.1,0.1
}

which in turns means that this object is a descendant of GfsOutput but also takes the additional arguments described. Similarly GfsOutput is a descendent of GfsEvent and finally GfsEvent is a "root object class" which has no parent. Putting it all together, an example of use of GfsOutputScalarSum is

GfsOutputScalarSum { istep = 1 } sum { v = U }

where the red text is "inherited" from the GfsEvent great-grandparent, the blue text from the GfsOutput grandparent and the green text from the GfsOutputScalar parent.

Common objects

Note that the way the following list is indented reflects the inheritance hierarchy of each object.

Solvers

Functions and macros

Variables

Parameters

Solid boundaries

  • GfsSurfaceBc — Boundary conditions for diffusion and Poisson equations

General orthogonal coordinates

Topology

Boundary conditions

  • GfsBc — Base class for boundary conditions on individual variables

Initial mesh refinement

Initialisation of fields

Adaptive mesh refinement

Various events

Source terms

Outputs

Modules

Map

The Map module defines the objects used to perform cartographic projections within Gerris. As all modules, it is optional and depends on the availability of the PROJ.4 cartographic projections library on your system. The module is initialised in parameter files using

GModule map

and defines the GfsMapProjection object with the following inheritance hierarchy

Terrain

The Terrain module contains a set of objects which can be used to define solid boundaries using large Digital Terrain Model (DTM) databases. The databases are only limited in size by the amount of disk space available and include an Kd-tree spatial index for efficient retrieval of subsets of the original data. The module is initialised in parameter files using

GModule terrain

and defines the GfsRefineTerrain, GfsTerrain and GfsVariableTerrain objects with the following inheritance hierarchy

Real terrains are often defined in a geographic coordinate system (e.g. longitude, latitude and height) and in practice this module is often combined with the Map module.

The terrain databases used by GfsRefineTerrain and GfsVariableTerrain need to be created in a pre-processing step using the xyz2kdt command-line utility.

Wavewatch

The Wavewatch module can be used only in GfsWave simulations. When this module is included, the GfsWave simulation will call the source terms routines (wind, wave breaking etc...) of the WaveWatch III spectral wave model. The module is initialised in parameter files using

GModule wavewatch

The wind field is defined by the U10 and V10 variables: the coordinates of the local wind vector (in m/sec and at a reference height of 10 m).

If the AS field is defined an "atmospheric stability correction" is applied to the wind field (see Section 2.3.5 of WaveWatch manual version 3.12). The AS field must be initialised with the air/sea temperature difference in degree Celsius.

Note that due to the license of recent versions of WaveWatch III, the wavewatch module is not provided in pre-compiled binaries of Gerris. It needs to be installed from source first.

Okada

The Okada module defines objects computing displacement solutions for the Okada fault model. The module is initialised in parameter files using

GModule okada

and defines the GfsInitOkada object with the following inheritance hierarchy

  • GfsInit
    • GfsInitOkada — Initialises a field with the vertical displacement of an Okada fault model

Tide

DF3

The DF3 module allows to create a POV-Ray DF3 file mapping values of a variable from a simulation to a cube. Such output can be used to visualize a variable in 3D using POV-Ray. The module is initialised in parameter files using

GModule df3

and defines the GfsOutputPovrayDF3 object with the following inheritance hierarchy.

Particulates

The particulate module defines (active) Lagrangian particles coupled with the flow. GfsParticulates respond to forces (typically exerted by the fluid) and can exert forces on the fluid in response.

The module is initialised in parameter files using

GModule particulates

The module defines the following objects (in bold):

Bubbles

The module is initialised in parameter files using

GModule particulates
GModule bubbles

The module defines the following objects (in bold):

Ode

The Open Dynamics Engine module.

Hypre

This module uses the Hypre library (the algebraic multigrid (AMG) solver in particular) instead of Gerris' native multigrid solver to solve Poisson equations. The module is initialised in parameter files using

GModule hypre

This will use default settings which can be changed using an optional parameter block.

Electrohydro

This module can be used to solve 2D/3D electrohydrodynamics problems. The module is initialised in parameter files using

GModule electrohydro

The module defines the following objects:

See also

J. M. Lopez-Herrera, S. Popinet, M. A. Herrada - A charge-conservative approach for simulating electrohydrodynamic two-phase flows using Volume-Of-Fluid

Journal of Computational Physics 230:1939-1955, 2010
Bibtex

Skewsymmetric

This module can be used to solve 2D/3D problems using the skew-symmetric formulation proposed by Verstappen (JCP, 2007). The module is initialised in parameter files using

GModule skewsymmetric

The module defines the following object:

FFT

This module computes FFTs of given variables

GModule fft

The module defines the following object:

Culvert

Modelling the effect of culverts within the GfsRiver solver. The module is initialised in parameter files using

GModule culvert

The module defines the following object:

GfsView

This module can be used to create GfsView visualisations from within Gerris. This eliminates the need to couple Gerris with GfsView through pipes and more importantly this means that the simulation does not need to be copied from Gerris into GfsView, thus saving CPU and memory. This can also be used to efficiently create visualisations of large-scale parallel computations: the visualisation itself is created in parallel for individual subdomains. The module is initialised in parameter files using

GModule gfsview

The module defines the following objects:

Topics

This module implements initial conditions for the simulation of landslide generated tsunamis. It is a directly inspired from the software TOPICS developped by Dr. P. Watts. The sources are that used in the version 1.2 of TOPICS, last modified in August 2009 by Dr. P. Watts and published under the GPL license.

GModule topics

The module defines the following objects:

  • GfsOutput
    • GfsOutputInterfaceGrid — Outputs function that can be used to transport the characteristics of an interface generated in GfsSimulation 3D to GfsRiver.

Command-line programs

  • gerris — The Gerris flow solver simulation engine
  • gfsview-batch — Command-line description of GfsView (in batch and interactive mode)
Personal tools
communication