#include <EquilibriumDustEmissionCalculator.hpp>
Public Member Functions | |
size_t | allocatedBytes () const |
Array | emissivity (const Array &Jv) const |
double | equilibriumTemperature (int b, const Array &Jv) const |
int | numBins () const |
void | precalculate (SimulationItem *item, const Array &lambdav, const Array &sigmaabsv) |
Private Attributes | |
Array | _Bcmbv |
Array | _emlambdav |
vector< Array > | _emsigmaabsvv |
vector< Array > | _planckabsvv |
Array | _rfdlambdav |
Array | _rflambdav |
vector< Array > | _rfsigmaabsvv |
Array | _Tv |
EquilibriumDustEmissionCalculator is a helper class to calculate the equilibrium temperature
The class is equipped to handle multiple (in principle independent) representative grains. These are called bins because the calculator is typically used to handle the various grain size bins in a dust mix. Indeed, the equilibrium temperature and the emissivity spectrum are nonlinear functions of the grain properties, and thus a single representative grain cannot usually accurately represent a dust mix.
A client of the class must first call the precalculate() function for each bin (in order of bin index
The equilibrium temperature
where
where
The equilibrium emissivity spectrum of all bins combined embedded in a radiation field
with
size_t EquilibriumDustEmissionCalculator::allocatedBytes | ( | ) | const |
This function returns the size of the memory, in bytes, allocated by the precalculate() function so far. This information can be used for logging purposes.
This function returns the emissivity spectrum per hydrogen atom
double EquilibriumDustEmissionCalculator::equilibriumTemperature | ( | int | b, |
const Array & | Jv | ||
) | const |
This function returns the equilibrium temperature
int EquilibriumDustEmissionCalculator::numBins | ( | ) | const |
This function returns the number of bins (i.e. representative grains) added by the precalculate() function so far.
void EquilibriumDustEmissionCalculator::precalculate | ( | SimulationItem * | item, |
const Array & | lambdav, | ||
const Array & | sigmaabsv | ||
) |
This function precalculates and stores information used to calculate the equilibrium temperature and emissivity spectrum for a particular bin (i.e. representative grain) to be handled by the calculator. It must be called once for each bin; the order of the calls establishes the order of the bin index
When it is first called, the function uses its first argument to obtain the simulation's radiation field and dust emission wavelength grids, and it builds a temperature grid for use in the calculator.
The second and third function arguments specify the absorption cross sections