The SKIRT project
advanced radiative transfer for astrophysics
RangeGrainSizeDistribution Class Reference

#include <RangeGrainSizeDistribution.hpp>

Inheritance diagram for RangeGrainSizeDistribution:

Public Member Functions

double amax () const override
double amin () const override
double maxSize () const
double minSize () const
Public Member Functions inherited from GrainSizeDistribution
virtual double dnda (double a) const =0
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

 RangeGrainSizeDistribution ()
 RangeGrainSizeDistribution (double minSize, double maxSize)
void setupSelfBefore () override
Protected Member Functions inherited from GrainSizeDistribution
 GrainSizeDistribution ()
Protected Member Functions inherited from SimulationItem
 SimulationItem ()
virtual bool offersInterface (const std::type_info &interfaceTypeInfo) const
virtual void setupSelfAfter ()
Protected Member Functions inherited from Item
 Item ()

Private Types

using BaseType
using ItemType

Private Attributes

double _maxSize
double _minSize

Friends

class ItemRegistry

Detailed Description

RangeGrainSizeDistribution is an abstract class that represents a grain size distribution with a configurable grain size range. Specifically, it manages the attributes \(a_\text{min}\) and \(a_\text{max}\), which determine the range of the distribution. The RangeGrainSizeDistribution class consequently implements the functions amin() and amax(), while it still expects each subclass to provide the actual distribution function by implementing the dnda() function.

Constructor & Destructor Documentation

◆ RangeGrainSizeDistribution() [1/2]

RangeGrainSizeDistribution::RangeGrainSizeDistribution ( )
inlineprotected

Default constructor for abstract Item subclass RangeGrainSizeDistribution: "a dust grain size distribution with a configurable size range".

◆ RangeGrainSizeDistribution() [2/2]

RangeGrainSizeDistribution::RangeGrainSizeDistribution ( double minSize,
double maxSize )
explicitprotected

This constructor simply initializes \(a_\text{min}\) and \(a_\text{max}\) with the specified values. It can be invoked from subclass constructors to set the values of these properties programmatically.

Member Function Documentation

◆ amax()

double RangeGrainSizeDistribution::amax ( ) const
overridevirtual

This function returns the configured maximum grain size \(a_\text{max}\).

Implements GrainSizeDistribution.

◆ amin()

double RangeGrainSizeDistribution::amin ( ) const
overridevirtual

This function returns the configured minimum grain size \(a_\text{min}\).

Implements GrainSizeDistribution.

◆ maxSize()

double RangeGrainSizeDistribution::maxSize ( ) const
inline

This function returns the value of the discoverable double property maxSize: "the maximum grain size for this distribution".

This property represents a physical quantity of type "grainsize".

The minimum value for this property is "[1 Angstrom".

The maximum value for this property is "1 mm]".

◆ minSize()

double RangeGrainSizeDistribution::minSize ( ) const
inline

This function returns the value of the discoverable double property minSize: "the minimum grain size for this distribution".

This property represents a physical quantity of type "grainsize".

The minimum value for this property is "[1 Angstrom".

The maximum value for this property is "1 mm]".

◆ setupSelfBefore()

void RangeGrainSizeDistribution::setupSelfBefore ( )
overrideprotectedvirtual

This function verifies the property values.

Reimplemented from SimulationItem.


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