.. _initialization: Initial conditions =================================== This chapter describes options for initialization of the flow solution. Initial liquid distribution ------------------------------ There are several methods for specifying the initial liquid distribution: * No initialization (all cells are empty). * Initialization by the built-in wave model as specified in the section ``waves/``. This option is enabled when ``waves/model/@model`` is set to anything but ``"none"``. The attribute ``@start_with_still_water`` can be set to ``"true"`` or ``"false"`` to start with still water or a fully developed wave field. The attributes ``@initialize_fs`` must be set to ``"true"``. * Initialization by a plug-in as specified in the section ``coupling/external_solution/``. This option is only applied when the attribute ``external_solution/@specialbc_initialize`` is set to ``"true"``. The above methods cannot be combined in one simulation. However, it is possible to add additional liquid sections by means of the options described in sections :numref:`%s `, :numref:`%s ` and :numref:`%s `. * basic geometric shapes by means of the ``liquid/box/`` construct, * detailed configurations by means of the ``liquid/object/`` construct, which contains geometrical building blocks, similar to those used for the geometry definition (this option was formerly implemented by means of the program LIQDEF), * a dedicated option for greenwater simulations, located in the section ``liquid/greenwater/``. .. _initial_conditions/liquid_boxes: Liquid boxes .............. In many situations only a simple initial liquid configuration is required. Using the ``box/`` construct one or more bounding boxes can be filled with liquid. A frequently encountered example is the "still water" box which defines the half-space :math:`z\leq0`: .. code-block:: xml -Inf Inf -Inf Inf -Inf 0. .. _initial_conditions/liquid_objects: Liquid building blocks ........................... In the following example the simulation is initialized with still water and a spherical droplet of water with a radius of 5 cm is included at the location (0,0,1) using a spherical building block, which is documented in :numref:`Chapter %s `: .. code-block:: xml -Inf Inf -Inf Inf -Inf 0. 0. 0. 1. 0.05 0.05 0.05 In the following example the initial liquid configuration is stored in an external file using the ``file_reader/`` construct as explained in :numref:`Chapter %s `: .. code-block:: xml -Inf Inf -Inf Inf -Inf 0. The file ``${INPUT}/liquid.in`` contains the same information as would be read by the pre-processing program LIQDEF, which was included in previous ComFLOW. In versions 4.0 and later pre-processing is no longer necessary. .. _initial_conditions/greenwater: Green water box ............................... *This option is currently not officially supported.* .. .. code-block:: none ------------------------------------------------------------------------ -- green water parameters ---------------------------------------------- grnwtr 1 ------------------------------------------------------------------------ high low length 12.0 -5.0 30.0 ------------------------------------------------------------------------ width a b 47.0 -0.056 6.0 ------------------------------------------------------------------------ * ``grnwtr``: this variable is an integer with value 0 or 1. When ``grnwtr`` equals 1, the initial liquid configuration is a dam of water described by the parameters ``high``, ``low`` and ``length`` and the form of the deck. Remark: in versions 3.1.2 and earlier, the XZ-walls of the domain were made free slip automatically if ``grnwtr=1``. In later versions this is no longer the case and any free-slip boundaries need to be specified manually (see \cref {section:comflowin:inoutflow} as well as the example ``greenfixedbow`` in the examples directory).} Outflow boundaries can be defined using the input lines below (\cref{section:comflowin:inoutflow}). When ``grnwtr`` equals 0, the initial liquid configuration is given at the line of the 'definition initial liquid configuration' (\cref{section:comflowin:liquid}) or by the parameter ``wave`` (see next lines of ``comflow.in``, \cref{section:comflowin:waves}). The geometry of the ship should be defined using the pre-processor GEODEF. * ``high``, ``low`` and ``length``: the initial water distribution (the wall of water) is described by these parameters; ``high`` is the maximum height of the wall at the front of the bow, ``low`` is the minimum height of the wall achieved at ``length`` meter behind the bow. Between ``low`` and ``high`` a linear interpolation is used. The situation achieved by setting ``high=12.0``, ``low=-5.0`` and \param{length}{30.0} is given in \cref{fluiddistr} (side-view in XZ-plane and top view). * ``width``: this variable stands for the width of the deck. * ``a`` and ``b``: the form of the bow shape in the dam of water is given by a parabola of the form $x = \verb|a| y^2 + \verb|b|$. The values for the default water dam configuration are: ``a=0.056}, ``b=-6.0`` (see \cref{fluiddistr}). Initial velocity field ------------------------------ The velocity field is initialized to zero, unless one of the following holds: * a wave model is active, * a plug-in is used. .. ..rubric:: Footnotes .. ..rubric:: References .. ..bibliography:: references.bib