Merger Tree Node Evolvers

Class providing evolvers for individual nodes in a merger tree—the objects responsible for integrating the ODEs that govern the physical properties of a single halo or galaxy from one timestep to the next. The node evolver advances all state variables (mass, spin, metallicity, etc.) using the relevant physics modules and handles special events such as node promotion (when a node’s time equals its parent’s) and pre-merge processing. It also checks whether node properties have converged to the required accuracy.

Default implementation: mergerTreeNodeEvolverStandard

Methods

evolvevoid

Advance the physical properties of the given node from its current time to timeEnd by integrating the relevant ODE physics, setting interrupted and functionInterrupt if the evolution must be paused for an event such as node promotion or a merger.

  • type (mergerTree ), intent(inout) :: tree

  • type (treeNode ), intent(inout), pointer :: node

  • double precision , intent(in ) :: timeEnd

  • logical , intent( out) :: interrupted

  • procedure (interruptTask ), intent( out), pointer :: functionInterrupt

  • class (galacticStructureSolverClass), intent(in ), target :: galacticStructureSolver__

  • class (ompLockClass ), intent(inout) :: treeLock

  • integer (kind_int8 ), intent(in ), optional :: systemClockMaximum

  • integer , intent( out), optional :: status

promotevoid

Promote node to its parent node, then destroy it.

  • type(treeNode), intent(inout), pointer :: node

mergevoid

Handles instances where node is about to merge with its parent node.

  • type(treeNode), intent(inout) :: node

isAccuratelogical

Return true if a tree node property is within expected accuracy of a given value.

  • double precision, intent(in ) :: valueNode, valueExpected

mergerTreeNodeEvolverStandard

The standard merger tree node evolver.

If the parameter [enforceNonNegativity] = true then properties which are marked as being non-negative (e.g. masses) are evolved in such a way to ensure that they remain non-negative. This typically requires smaller time step size and so longer run times. In some cases it may be impossible to ensure non-negativity even for arbitrarily small timestepsfootnoteThis can occur if a property as a non-zero, negative derivative as the property approaches zero. Such cases are quite likely unphysical, but are tolerated here.. In such cases, if a property remains negative with the smallest possible time step, it will be zeroed and evolution continues.

(Default implementation)

Methods

  • factors — Compute factors needed for tidal tensor calculation.

  • tidalTensorGet — Get the tidal tensor.

Parameters

  • [odeToleranceAbsolute] (real; default 0.01d0) — The absolute tolerance used in solving differential equations for node evolution.

  • [odeToleranceRelative] (real; default 1.0d-2) — The relative tolerance used in solving differential equations for node evolution.

  • [odeJacobianStepSizeRelative] (real; default 0.01d0) — The relative step size to use when perturbing properties for purposes of computing a finite difference approximation to the ODE system Jacobian.

  • [odeAlgorithm] (string; one of rungeKuttaCashKarp, rungeKuttaSecondOrder, rungeKutta, rungeKuttaFehlberg, rungeKuttaPrinceDormand, multistepAdams, bulirschStoer, bdf; default rungeKuttaCashKarp) — The algorithm to use in the ODE solver.

  • [odeAlgorithmNonJacobian] (string; one of rungeKuttaCashKarp, rungeKuttaSecondOrder, rungeKutta, rungeKuttaFehlberg, rungeKuttaPrinceDormand, multistepAdams, bulirschStoer, bdf; default rungeKuttaCashKarp) — The algorithm to use in the ODE solver.

  • [odeLatentIntegratorType] (string; one of gaussKronrod, trapezoidal; default trapezoidal) — The type of integrator to use for latent variables.

  • [odeLatentIntegratorOrder] (integer; default 15) — The order of the integrator for latent variables.

  • [odeLatentIntegratorIntervalsMaximum] (integer; default 1000) — The maximum number of intervals allowed in the integrator for latent variables.

  • [profileOdeEvolver] (boolean; default .false.) — Specifies whether or not to profile the ODE evolver.

  • [reuseODEStepSize] (boolean; default .true.) — If true, re-use the previous ODE step size when resuming the evolution of a node. Otherwise, the initial step size is not specified.

  • [enforceNonNegativity] (boolean; default .false.) — If true, properties that are marked as non-negative (e.g. masses) will be evolved in such a way as to enforce that non-negativity.