The logger is a particle based output (e.g. snapshot) that takes into account the large difference of timescale.
If you have any question, a slack channel is available for it in SWIFT's slack.
To run it, you will need to use the configuration option ``--enable-logger``.
Currently the logger is implemented only for Gadget2 and the default gravity / stars, but can be easily extended to the other schemes by adding the logger structure to the particles (see ``src/hydro/Gadget2/hydro_part.h``).
The main parameters of the logger are ``Logger:delta_step`` and ``Logger:index_mem_frac`` that define the time accuracy of the logger and the number of index files.
The first parameter defines the number of active steps that a particle is doing before writing and the second defines the total storage size of the index files as function of the dump file.
Unfortunately, the API is not really developed yet. Therefore if you wish to dump another field, you will need to trick the logger by replacing a field in the ``logger_log_part`` function.
For reading, the python wrapper is available through the configuration option ``--with-python``. Once compiled, you will be able to use the file ``logger/examples/reader_example.py``.
The first argument is the basename of the index file and the second one is the time requested.
During the first reading, the library is manipulating the dump file and therefore it should not be killed and may take a bit more time than usual.
@@ -222,8 +222,12 @@ The accuracy of the gravity calculation is governed by the following two paramet
* The time-step size pre-factor :math:`\eta`: ``eta``,
The time-step of a given particle is given by :math:`\Delta t =
\sqrt{\frac{2\eta\epsilon}{|\overrightarrow{a}|}}`, where
:math:`\overrightarrow{a}` is the particle's acceleration. `Power et al. (2003) <http://adsabs.harvard.edu/abs/2003MNRAS.338...14P>`_ recommend using :math:`\eta=0.025`.
\sqrt{2\eta\epsilon_i/|\overrightarrow{a}_i|}`, where
:math:`\overrightarrow{a}_i` is the particle's acceleration and
:math:`\epsilon_i` its (spline) softening length. `Power et al. (2003)
<http://adsabs.harvard.edu/abs/2003MNRAS.338...14P>`_ recommend using
:math:`\eta=0.025`.
The last tree-related parameter is
* The tree rebuild frequency: ``rebuild_frequency``.
...
...
@@ -233,7 +237,7 @@ The tree rebuild frequency is an optional parameter defaulting to
fraction of the particles have been integrated (kicked) forward in time.
Simulations using periodic boundary conditions use additional parameters for the
Particle-Mesh part of the calculation. The last three are optional:
Particle-Mesh part of the calculation. The last five are optional:
* The number cells along each axis of the mesh :math:`N`: ``mesh_side_length``,
* The mesh smoothing scale in units of the mesh cell-size :math:`a_{\rm
...
...
@@ -244,9 +248,17 @@ Particle-Mesh part of the calculation. The last three are optional:
* The scale below which the short-range forces are assumed to be exactly Newtonian (in units of
the mesh cell-size multiplied by :math:`a_{\rm smooth}`) :math:`r_{\rm
cut,min}`: ``r_cut_min`` (default: ``0.1``),
* Whether or not to dither the particles randomly at each tree rebuild:
``dithering`` (default: ``1``),
* The magnitude of each component of the dithering vector to use in units of the