The SKIRT project
advanced radiative transfer for astrophysics
Public Types | Public Member Functions | Protected Member Functions | Private Attributes | List of all members
Configuration Class Reference

#include <Configuration.hpp>

Inheritance diagram for Configuration:
Inheritance graph
[legend]

Public Types

enum class  LyaAccelerationScheme { None , Constant , Variable }
 

Public Member Functions

 Configuration (SimulationItem *parent)
 
double angularDiameterDistance () const
 
SpatialCellLibrarycellLibrary () const
 
double dustEmissionSourceWeight () const
 
double dustEmissionWavelengthBias () const
 
WavelengthDistributiondustEmissionWavelengthBiasDistribution () const
 
DisjointWavelengthGriddustEmissionWLG () const
 
bool emulationMode () const
 
bool explicitAbsorption () const
 
bool forceScattering () const
 
int gridDimension () const
 
bool hasConstantPerceivedWavelength () const
 
bool hasDustEmission () const
 
bool hasDynamicState () const
 
bool hasDynamicStateRecipes () const
 
bool hasGasEmission () const
 
bool hasMagneticField () const
 
bool hasMedium () const
 
bool hasMergedIterations () const
 
bool hasMovingMedia () const
 
bool hasMultipleConstantSectionMedia () const
 
bool hasNegativeExtinction () const
 
bool hasPanRadiationField () const
 
bool hasPolarization () const
 
bool hasPrimaryDynamicState () const
 
bool hasPrimaryDynamicStateMedia () const
 
bool hasPrimaryIterations () const
 
bool hasRadiationField () const
 
bool hasScatteringDispersion () const
 
bool hasSecondaryDynamicState () const
 
bool hasSecondaryDynamicStateMedia () const
 
bool hasSecondaryEmission () const
 
bool hasSecondaryIterations () const
 
bool hasSecondaryRadiationField () const
 
bool hasSingleConstantSectionMedium () const
 
bool hasSpheroidalPolarization () const
 
bool hasStochasticDustEmission () const
 
bool hasVariableMedia () const
 
double hubbleExpansionRate () const
 
bool includeHeatingByCMB () const
 
double luminosityDistance () const
 
LyaAccelerationScheme lyaAccelerationScheme () const
 
double lyaAccelerationStrength () const
 
int magneticFieldMediumIndex () const
 
double maxFractionOfPrevious () const
 
double maxFractionOfPrimary () const
 
int maxPrimaryIterations () const
 
int maxSecondaryIterations () const
 
bool mediaNeedGeneratePosition () const
 
int minPrimaryIterations () const
 
int minScattEvents () const
 
int minSecondaryIterations () const
 
double minWeightReduction () const
 
int modelDimension () const
 
int numDensitySamples () const
 
double numPrimaryIterationPackets () const
 
double numPrimaryPackets () const
 
int numPropertySamples () const
 
double numSecondaryIterationPackets () const
 
double numSecondaryPackets () const
 
bool oligochromatic () const
 
WavelengthDistributionoligoWavelengthBiasDistribution ()
 
double pathLengthBias () const
 
DisjointWavelengthGridradiationFieldWLG () const
 
double redshift () const
 
double secondarySourceBias () const
 
double secondarySpatialBias () const
 
void setEmulationMode ()
 
Range simulationWavelengthRange () const
 
vector< double > simulationWavelengths () const
 
bool snapshotsNeedGetEntities () const
 
Range sourceWavelengthRange () const
 
bool storeEmissionRadiationField () const
 
WavelengthGridwavelengthGrid (WavelengthGrid *localWavelengthGrid) const
 
- Public Member Functions inherited from SimulationItem
template<class T >
T * find (bool setup=true) const
 
template<class T >
T * interface (int levels=-999999, bool setup=true) const
 
virtual string itemName () const
 
void setup ()
 
string typeAndName () const
 
- Public Member Functions inherited from Item
 Item (const Item &)=delete
 
virtual ~Item ()
 
void addChild (Item *child)
 
const vector< Item * > & children () const
 
virtual void clearItemListProperty (const PropertyDef *property)
 
void destroyChild (Item *child)
 
virtual bool getBoolProperty (const PropertyDef *property) const
 
virtual vector< double > getDoubleListProperty (const PropertyDef *property) const
 
virtual double getDoubleProperty (const PropertyDef *property) const
 
virtual string getEnumProperty (const PropertyDef *property) const
 
virtual int getIntProperty (const PropertyDef *property) const
 
virtual vector< Item * > getItemListProperty (const PropertyDef *property) const
 
virtual ItemgetItemProperty (const PropertyDef *property) const
 
virtual string getStringProperty (const PropertyDef *property) const
 
int getUtilityProperty (string name) const
 
virtual void insertIntoItemListProperty (const PropertyDef *property, int index, Item *item)
 
Itemoperator= (const Item &)=delete
 
Itemparent () const
 
virtual void removeFromItemListProperty (const PropertyDef *property, int index)
 
virtual void setBoolProperty (const PropertyDef *property, bool value)
 
virtual void setDoubleListProperty (const PropertyDef *property, vector< double > value)
 
virtual void setDoubleProperty (const PropertyDef *property, double value)
 
virtual void setEnumProperty (const PropertyDef *property, string value)
 
virtual void setIntProperty (const PropertyDef *property, int value)
 
virtual void setItemProperty (const PropertyDef *property, Item *item)
 
virtual void setStringProperty (const PropertyDef *property, string value)
 
void setUtilityProperty (string name, int value)
 
virtual string type () const
 

Protected Member Functions

void setupSelfAfter () override
 
void setupSelfBefore () override
 
- Protected Member Functions inherited from SimulationItem
 SimulationItem ()
 
virtual bool offersInterface (const std::type_info &interfaceTypeInfo) const
 
virtual void setupSelfAfter ()
 
virtual void setupSelfBefore ()
 
- Protected Member Functions inherited from Item
 Item ()
 

Private Attributes

double _angularDiameterDistance
 
SpatialCellLibrary_cellLibrary
 
WavelengthGrid_defaultWavelengthGrid
 
double _dustEmissionSourceWeight
 
double _dustEmissionWavelengthBias
 
WavelengthDistribution_dustEmissionWavelengthBiasDistribution
 
DisjointWavelengthGrid_dustEmissionWLG
 
bool _emulationMode
 
bool _explicitAbsorption
 
bool _forceScattering
 
int _gridDimension
 
bool _hasConstantPerceivedWavelength
 
bool _hasDustEmission
 
bool _hasDynamicStateRecipes
 
bool _hasGasEmission
 
bool _hasLymanAlpha
 
bool _hasMedium
 
bool _hasMergedIterations
 
bool _hasMovingMedia
 
bool _hasMovingSources
 
bool _hasMultipleConstantSectionMedia
 
bool _hasNegativeExtinction
 
bool _hasPanRadiationField
 
bool _hasPolarization
 
bool _hasPrimaryDynamicState
 
bool _hasPrimaryDynamicStateMedia
 
bool _hasPrimaryIterations
 
bool _hasRadiationField
 
bool _hasScatteringDispersion
 
bool _hasSecondaryDynamicState
 
bool _hasSecondaryDynamicStateMedia
 
bool _hasSecondaryEmission
 
bool _hasSecondaryIterations
 
bool _hasSecondaryRadiationField
 
bool _hasSingleConstantSectionMedium
 
bool _hasSpheroidalPolarization
 
bool _hasStochasticDustEmission
 
bool _hasVariableMedia
 
double _hubbleExpansionRate
 
bool _includeHeatingByCMB
 
double _luminosityDistance
 
LyaAccelerationScheme _lyaAccelerationScheme
 
double _lyaAccelerationStrength
 
int _magneticFieldMediumIndex
 
double _maxFractionOfPrevious
 
double _maxFractionOfPrimary
 
int _maxPrimaryIterations
 
int _maxSecondaryIterations
 
bool _mediaNeedGeneratePosition
 
int _minPrimaryIterations
 
int _minScattEvents
 
int _minSecondaryIterations
 
double _minWeightReduction
 
int _modelDimension
 
int _numDensitySamples
 
double _numPrimaryIterationPackets
 
double _numPrimaryPackets
 
int _numPropertySamples
 
double _numSecondaryIterationPackets
 
double _numSecondaryPackets
 
bool _oligochromatic
 
WavelengthDistribution_oligoWavelengthBiasDistribution
 
double _pathLengthBias
 
DisjointWavelengthGrid_radiationFieldWLG
 
double _redshift
 
double _secondarySourceBias
 
double _secondarySpatialBias
 
bool _snapshotsNeedGetEntities
 
Range _sourceWavelengthRange
 
bool _storeEmissionRadiationField
 

Detailed Description

Configuration is a helper class that serves as a central clearing house for overall simulation configuration options including the simulation mode.

Each MonteCarloSimulation holds a single Configuration object. During setup, it retrieves many properties and options from the simulation hierarchy, verifying consistency of the configuration and flagging any conflicts while doing so. Once this process has completed, the Configuration object offers getters for these retrieved properties to any of the other simulation items in the hierarchy. The setup() function of the Configuration object is invoked at the very early stages of simulation setup, so that it is safe for other simulation items to retrieve information from the Configuration object during setup.

The Configuration class is based on SimulationItem so that it can be part of a simulation item hierarchy, however it is not discoverable because it is not intended to be selected or configured by the user.

Member Enumeration Documentation

◆ LyaAccelerationScheme

This enumeration lists the supported Lyman-alpha acceleration schemes.

Constructor & Destructor Documentation

◆ Configuration()

Configuration::Configuration ( SimulationItem parent)
explicit

This constructor creates a Configuration object that is hooked up as a child to the specified parent in the simulation hierarchy, so that it will automatically be deleted. The setup() function is not called by this constructor.

Member Function Documentation

◆ angularDiameterDistance()

double Configuration::angularDiameterDistance ( ) const
inline

Returns the angular-diameter distance corresponding to the redshift at which the model resides, or zero if the model resides in the Local Universe. Refer to the Cosmology class description for more information.

◆ cellLibrary()

SpatialCellLibrary * Configuration::cellLibrary ( ) const
inline

Returns the cell library mapping to be used for calculating the dust emission spectra.

◆ dustEmissionSourceWeight()

double Configuration::dustEmissionSourceWeight ( ) const
inline

Returns the bias weight for dust emission sources.

◆ dustEmissionWavelengthBias()

double Configuration::dustEmissionWavelengthBias ( ) const
inline

Returns the fraction of dust emission photon packet wavelengths sampled from a bias distribution.

◆ dustEmissionWavelengthBiasDistribution()

WavelengthDistribution * Configuration::dustEmissionWavelengthBiasDistribution ( ) const
inline

Returns the bias distribution for sampling dust emission photon packet wavelengths.

◆ dustEmissionWLG()

DisjointWavelengthGrid * Configuration::dustEmissionWLG ( ) const
inline

Returns the wavelength grid to be used for calculating the dust emission spectra.

◆ emulationMode()

bool Configuration::emulationMode ( ) const
inline

Returns true if the simulation has been put in emulation mode.

◆ explicitAbsorption()

bool Configuration::explicitAbsorption ( ) const
inline

Returns true if explicit absorption should be used during the photon cycle, false if not.

◆ forceScattering()

bool Configuration::forceScattering ( ) const
inline

Returns true if forced scattering should be used during the photon cycle, false if not.

◆ gridDimension()

int Configuration::gridDimension ( ) const
inline

Returns the symmetry dimension of the spatial grid, if present, or 0 if there is no spatial grid (which can only happen if the simulation does not include any media). A value of 1 means spherical symmetry, 2 means axial symmetry and 3 means none of these symmetries.

◆ hasConstantPerceivedWavelength()

bool Configuration::hasConstantPerceivedWavelength ( ) const
inline

Returns true if the perceived photon packet wavelength equals the intrinsic photon packet wavelength for all spatial cells along the path of the packet. The following conditions cause this function to return false: Hubble expansion is enabled or some media may have a non-zero velocity in some cells.

◆ hasDustEmission()

bool Configuration::hasDustEmission ( ) const
inline

Returns true if thermal dust emission must be calculated, and false otherwise.

◆ hasDynamicState()

bool Configuration::hasDynamicState ( ) const
inline

Returns true if the simulation has primary or merged iterations and includes one or more recipes or media that perform primary or secondary dynamic medium state (DMS) updates, and false otherwise.

◆ hasDynamicStateRecipes()

bool Configuration::hasDynamicStateRecipes ( ) const
inline

Returns true if the simulation has primary or merged iterations and includes one or more dynamic medium state recipes (instances of a DynamicStateRecipe subclass), and false otherwise. In the current implementation, these recipes by definition perform primary dynamic medium state (PDMS) updates.

◆ hasGasEmission()

bool Configuration::hasGasEmission ( ) const
inline

Returns true if gas emission must be calculated, and false otherwise.

◆ hasMagneticField()

bool Configuration::hasMagneticField ( ) const
inline

Returns true if one of the medium components in the simulation defines a spatial magnetic field distribution that may have nonzero strength for some positions, or false if none of the media define a magnetic field. It is not allowed for multiple medium components to define a magnetic field (a fatal error is raised during setup when this happens).

◆ hasMedium()

bool Configuration::hasMedium ( ) const
inline

Returns true if there is at least one medium component in the simulation, and false otherwise.

◆ hasMergedIterations()

bool Configuration::hasMergedIterations ( ) const
inline

Returns true if the simulation iterates over both primary and secondary emission and the iterations over secondary emission should include primary emission, and false otherwise.

◆ hasMovingMedia()

bool Configuration::hasMovingMedia ( ) const
inline

Returns true if one or more medium components in the simulation may have a nonzero velocity for some positions. If the function returns false, none of the media has a velocity.

◆ hasMultipleConstantSectionMedia()

bool Configuration::hasMultipleConstantSectionMedia ( ) const
inline

Returns true if the simulation has two or more medium components and the absorption and scattering cross sections for a photon packet traversing those medium components are spatially constant, so that the opacity in each crossed cell can be calculated by multiplying these constant cross sections by the corresponding number densities in the cell. Otherwise the function returns false.

The following conditions cause this function to return false: Hubble expansion is enabled, some media may have a non-zero velocity in some cells, so that the perceived wavelength changes between cells; some media have a variable material mix; the cross sections for some material mixes depend on extra medium state variables such as temperature or fragment weight factors.

◆ hasNegativeExtinction()

bool Configuration::hasNegativeExtinction ( ) const
inline

Returns true if the extinction cross section (the sum of the absorption and scattering cross section) for one or more material mixes in the simulation can be negative, and false if not.

◆ hasPanRadiationField()

bool Configuration::hasPanRadiationField ( ) const
inline

Returns true if a panchromatic radiation field (from which a temperature can be calculated) is being stored during the photon cycle, and false otherwise.

◆ hasPolarization()

bool Configuration::hasPolarization ( ) const
inline

Returns true if all media in the simulation support polarization, and false if none of the media do. A mixture of support and no support for polarization is not allowed and will cause a fatal error during setup.

◆ hasPrimaryDynamicState()

bool Configuration::hasPrimaryDynamicState ( ) const
inline

Returns true if the simulation has primary or merged iterations and includes one or more recipes or media that perform primary dynamic medium state (PDMS) updates, and false otherwise.

◆ hasPrimaryDynamicStateMedia()

bool Configuration::hasPrimaryDynamicStateMedia ( ) const
inline

Returns true if the simulation has primary or merged iterations and includes one or more media with an associated MaterialMix that performs primary dynamic medium state (PDMS) updates, and false otherwise.

◆ hasPrimaryIterations()

bool Configuration::hasPrimaryIterations ( ) const
inline

Returns true if the simulation iterates over primary emission, and false otherwise.

◆ hasRadiationField()

bool Configuration::hasRadiationField ( ) const
inline

Returns true if the radiation field must be stored during the photon cycle, and false otherwise.

◆ hasScatteringDispersion()

bool Configuration::hasScatteringDispersion ( ) const
inline

Returns true if a scattering interaction for one or more media may adjust the wavelength of the interacting photon packet, and false otherwise.

◆ hasSecondaryDynamicState()

bool Configuration::hasSecondaryDynamicState ( ) const
inline

Returns true if the simulation has primary or merged iterations and includes one or more recipes or media that perform secondary dynamic medium state (SDMS) updates, and false otherwise.

◆ hasSecondaryDynamicStateMedia()

bool Configuration::hasSecondaryDynamicStateMedia ( ) const
inline

Returns true if the simulation has secondary emission and includes one or more media with an associated MaterialMix that performs secondary dynamic medium state (SDMS) updates, and false otherwise.

◆ hasSecondaryEmission()

bool Configuration::hasSecondaryEmission ( ) const
inline

Returns true if secondary emission must be calculated for any media type, and false otherwise.

◆ hasSecondaryIterations()

bool Configuration::hasSecondaryIterations ( ) const
inline

Returns true if the simulation iterates over secondary emission, and false otherwise.

◆ hasSecondaryRadiationField()

bool Configuration::hasSecondaryRadiationField ( ) const
inline

Returns true if the radiation field for emission from secondary sources must be stored in a separate data structure, and false otherwise.

◆ hasSingleConstantSectionMedium()

bool Configuration::hasSingleConstantSectionMedium ( ) const
inline

Returns true if the simulation has a exactly one medium component and the absorption and scattering cross sections for a photon packet traversing that medium component are spatially constant, so that the opacity in each crossed cell can be calculated by multiplying this constant cross section by the number density in the cell. Otherwise the function returns false.

The following conditions cause this function to return false: Hubble expansion is enabled, there is more than one medium component, the medium may have a non-zero velocity in some cells, the medium has a variable material mix; the cross sections for some material mixes depend on extra medium state variables such as temperature or fragment weight factors.

◆ hasSpheroidalPolarization()

bool Configuration::hasSpheroidalPolarization ( ) const
inline

Returns true if some of the media in the simulation represent spheroidal (i.e. non-spherical) particles and require the corresponding treatment of polarization for scattering, absorption and emission, or false otherwise. If this function returns true, the hasPolarization() and hasMagneticField() functions return true as well.

◆ hasStochasticDustEmission()

bool Configuration::hasStochasticDustEmission ( ) const
inline

Returns true if thermal dust emission must be calculated by taking stochastically heated grains into account, and false otherwise.

◆ hasVariableMedia()

bool Configuration::hasVariableMedia ( ) const
inline

Returns true if the material mix for at least one medium component in the simulation may vary depending on spatial position. If the function returns false, the material mixes and thus the material properties for all media are constant throughout the complete spatial domain of the simulation.

◆ hubbleExpansionRate()

double Configuration::hubbleExpansionRate ( ) const
inline

If inclusion of the Hubble flow is enabled, this function returns the relative expansion rate of the universe in which the model resides. If inclusion of the Hubble flow is disabled, or if the simulation does not include Lyman-alpha treatment, this function returns zero.

◆ includeHeatingByCMB()

bool Configuration::includeHeatingByCMB ( ) const
inline

Returns true if the cosmic microwave background (CMB) must be added as a source term for dust heating, and false otherwise.

◆ luminosityDistance()

double Configuration::luminosityDistance ( ) const
inline

Returns the luminosity distance corresponding to the redshift at which the model resides, or zero if the model resides in the Local Universe. Refer to the Cosmology class description for more information.

◆ lyaAccelerationScheme()

LyaAccelerationScheme Configuration::lyaAccelerationScheme ( ) const
inline

Returns the enumeration value determining the acceleration scheme to be used for Lyman-alpha line scattering. The value is relevant only if Lyman-alpha line treatment is enabled in the simulation.

◆ lyaAccelerationStrength()

double Configuration::lyaAccelerationStrength ( ) const
inline

Returns the strength of the Lyman-alpha acceleration scheme to be applied. The value is relevant only if Lyman-alpha line treatment is enabled in the simulation and lyaAccelerationScheme() returns Constant or Variable.

◆ magneticFieldMediumIndex()

int Configuration::magneticFieldMediumIndex ( ) const
inline

Returns the index of the medium component defining the magnetic field, or a negative value if none of the media define a magnetic field.

◆ maxFractionOfPrevious()

double Configuration::maxFractionOfPrevious ( ) const
inline

Returns the dust self-absorption iteration convergence criterion described as follows: convergence is reached when the total absorbed dust luminosity has changed by less than this fraction compared to the previous iteration.

◆ maxFractionOfPrimary()

double Configuration::maxFractionOfPrimary ( ) const
inline

Returns the dust self-absorption iteration convergence criterion described as follows: convergence is reached when the total absorbed dust luminosity is less than this fraction of the total absorbed primary luminosity.

◆ maxPrimaryIterations()

int Configuration::maxPrimaryIterations ( ) const
inline

Returns the maximum number of iterations in the primary emission phase.

◆ maxSecondaryIterations()

int Configuration::maxSecondaryIterations ( ) const
inline

Returns the maximum number of iterations in the secondary emission phase.

◆ mediaNeedGeneratePosition()

bool Configuration::mediaNeedGeneratePosition ( ) const
inline

Returns true if the Medium::generatePosition() function may be called for the media in the simulation. In the current implementation, this happens only if the simulation uses a VoronoiMeshSpatialGrid instance to discretize the spatial domain. If there are no media or the Medium::generatePosition() will never be called during this simulation, this function returns false.

◆ minPrimaryIterations()

int Configuration::minPrimaryIterations ( ) const
inline

Returns the minimum number of iterations in the primary emission phase.

◆ minScattEvents()

int Configuration::minScattEvents ( ) const
inline

Returns the minimum number of forced scattering events before a photon packet is terminated.

◆ minSecondaryIterations()

int Configuration::minSecondaryIterations ( ) const
inline

Returns the minimum number of iterations in the secondary emission phase.

◆ minWeightReduction()

double Configuration::minWeightReduction ( ) const
inline

Returns the minimum weight reduction factor before a photon packet is terminated.

◆ modelDimension()

int Configuration::modelDimension ( ) const
inline

Returns the symmetry dimension of the input model, including sources and media, if present. A value of 1 means spherical symmetry, 2 means axial symmetry and 3 means none of these symmetries.

◆ numDensitySamples()

int Configuration::numDensitySamples ( ) const
inline

Returns the number of random spatial samples for determining density (or mass).

◆ numPrimaryIterationPackets()

double Configuration::numPrimaryIterationPackets ( ) const
inline

Returns the number of photon packets launched per iteration segment during primary emission.

◆ numPrimaryPackets()

double Configuration::numPrimaryPackets ( ) const
inline

Returns the number of photon packets launched per regular primary emission simulation segment.

◆ numPropertySamples()

int Configuration::numPropertySamples ( ) const
inline

Returns the number of random spatial samples for determining other properties.

◆ numSecondaryIterationPackets()

double Configuration::numSecondaryIterationPackets ( ) const
inline

Returns the number of photon packets launched per iteration segment during secondary emission.

◆ numSecondaryPackets()

double Configuration::numSecondaryPackets ( ) const
inline

Returns the number of photon packets launched per regular secondary emission simulation segment.

◆ oligochromatic()

bool Configuration::oligochromatic ( ) const
inline

Returns true if the wavelength regime of the simulation is oligochromatic.

◆ oligoWavelengthBiasDistribution()

WavelengthDistribution * Configuration::oligoWavelengthBiasDistribution ( )
inline

For oligochromatic simulations, this function returns the wavelength bias distribution to be used by all primary sources. For panchromatic simulations, the function returns the null pointer.

◆ pathLengthBias()

double Configuration::pathLengthBias ( ) const
inline

Returns the fraction of path lengths sampled from a linear rather than an exponential distribution.

◆ radiationFieldWLG()

DisjointWavelengthGrid * Configuration::radiationFieldWLG ( ) const
inline

Returns the wavelength grid to be used for storing the radiation field, or the null pointer if hasRadiationField() returns false.

◆ redshift()

double Configuration::redshift ( ) const
inline

Returns the redshift at which the model resides, or zero if the model resides in the Local Universe.

◆ secondarySourceBias()

double Configuration::secondarySourceBias ( ) const
inline

Returns the fraction of secondary photon packets distributed uniformly across secondary sources.

◆ secondarySpatialBias()

double Configuration::secondarySpatialBias ( ) const
inline

Returns the fraction of secondary photon packets distributed uniformly across spatial cells.

◆ setEmulationMode()

void Configuration::setEmulationMode ( )

This function puts the simulation in emulation mode. Specifically, it sets a flag that can be queried by other simulation items, it sets the number of photon packets to zero, and disables iteration over primary and/or secondary emisson.

◆ setupSelfAfter()

void Configuration::setupSelfAfter ( )
overrideprotectedvirtual

This function logs some aspects of the configuration as information to the user.

Reimplemented from SimulationItem.

◆ setupSelfBefore()

void Configuration::setupSelfBefore ( )
overrideprotectedvirtual

This function retrieves properties and options from the simulation hierarchy and stores the resulting values internally so that they can be returned by any of the getters with minimal overhead. During this process, the function also verifies the consistency of the simulation configuration, for example checking the configuration against the requirements of the selected simulation mode. If any conflicts are found, the function throws a fatal error.

Reimplemented from SimulationItem.

◆ simulationWavelengthRange()

Range Configuration::simulationWavelengthRange ( ) const

Returns a wavelength range that covers all wavelengths possibly used in the simulation for photon transport or for otherwise probing material properties (e.g. optical depth). This range includes the primary and secondary source wavelength ranges extended on both sides to accommodate a redshift or blueshift caused by kinematics corresponding to \(v/c=1/3\). It also includes the range of the instrument wavelength grids and the wavelengths used for material normalization and material property probes.

◆ simulationWavelengths()

vector< double > Configuration::simulationWavelengths ( ) const

Returns a list of wavelengths that are explicitly or indirectly mentioned by the simulation configuration. This includes the characteristic wavelengths of all configured wavelength grids (for instruments, probes, radiation field or dust emission) and specific wavelengths used for normalization or probing.

◆ snapshotsNeedGetEntities()

bool Configuration::snapshotsNeedGetEntities ( ) const
inline

Returns true if one of the Snapshot::getEntities() functions may be called for any of the snapshots associated with the imported sources and media in the simulation, implying that the snapshot must prebuild the required search data structures. In the current implementation, this happens only if the simulation includes one or more input model probes, i.e. instances of an InputModelProbe subclass.

◆ sourceWavelengthRange()

Range Configuration::sourceWavelengthRange ( ) const
inline

Returns the total wavelength range of the primary sources in the simulation. For panchromatic simulations, this range is configured by the user in the source system. For oligochromatic simulations, the range includes the discrete source wavelengths used in the simulation, which are also user-configured in the source system.

◆ storeEmissionRadiationField()

bool Configuration::storeEmissionRadiationField ( ) const
inline

Returns true if the radiation field must be stored during emission (for probing), and false otherwise.

◆ wavelengthGrid()

WavelengthGrid * Configuration::wavelengthGrid ( WavelengthGrid localWavelengthGrid) const

Returns the wavelength grid to be used for an instrument or probe, given the wavelength grid configured locally for the calling instrument or probe (which may the null pointer to indicate that no local grid was configured). For oligochromatic simulations, the function always returns a wavelength grid with disjoint bins centered around the discrete source wavelengths used in the simulation. For panchromatic simulations, the function returns the provided local wavelength grid if it is non-null, and otherwise it returns the default instrument wavelength grid obtained from the instrument system. If both the provided local wavelength grid and the default instrument wavelength grid are the null pointer, the function throws a fatal error.


The documentation for this class was generated from the following file: