Manticore  Version 1.5.3
Physics of Molecular Clouds
Public Member Functions | Static Public Attributes | Private Member Functions | Private Attributes | List of all members
manticore::Fcost_gray< NB, NP > Class Template Reference

Ceres solver graybody cost model. More...

Inheritance diagram for manticore::Fcost_gray< NB, NP >:
Inheritance graph
[legend]
Collaboration diagram for manticore::Fcost_gray< NB, NP >:
Collaboration graph
[legend]

Public Member Functions

 Fcost_gray (const GrayData &gd)
 Constructor. More...
 
virtual bool Evaluate (double const *const *parameters, double *residuals, double **jacobians) const final
 Evaluate the fitting function and its Jacobian. More...
 

Static Public Attributes

static constexpr double scale = 128.0
 Surface density scaling factor. More...
 

Private Member Functions

void clearCache () const
 Clear result cache. More...
 

Private Attributes

const GrayDatagd_
 
double jcache_ [NB *NP]
 Jacobian cache. More...
 
double pcache_ [NP]
 Parameter cache. More...
 
double rcache_ [NB]
 Residual cache. More...
 

Detailed Description

template<unsigned NB, unsigned NP>
class manticore::Fcost_gray< NB, NP >

Ceres solver graybody cost model.

The model consists of up to four parameters (two gas components, core and halo, each with a temperature \(T\) and mass surface density \(S\)), with the halo temperature sometimes held fixed as shown below.

NP Active parameters Fixed parameters
1 Sh Th
2 Th, Sh -
3 Sh, Tc, Sc Th
4 Th, Sh, Tc, Sc -
Note
This function assumes surface densities have been scaled by scale for fitting (to help normalize their magnitude relative to temperature).
Template Parameters
NBNumber of bands.
NPNumber of parameters.

Definition at line 94 of file solve.cc.

Constructor & Destructor Documentation

◆ Fcost_gray()

template<unsigned NB, unsigned NP>
manticore::Fcost_gray< NB, NP >::Fcost_gray ( const GrayData gd)
inline

Constructor.

Definition at line 100 of file solve.cc.

References manticore::Fcost_gray< NB, NP >::clearCache().

Member Function Documentation

◆ clearCache()

template<unsigned NB, unsigned NP>
void manticore::Fcost_gray< NB, NP >::clearCache ( ) const
inlineprivate

◆ Evaluate()

template<unsigned NB, unsigned NP>
virtual bool manticore::Fcost_gray< NB, NP >::Evaluate ( double const *const *  parameters,
double *  residuals,
double **  jacobians 
) const
inlinefinalvirtual

Member Data Documentation

◆ gd_

template<unsigned NB, unsigned NP>
const GrayData& manticore::Fcost_gray< NB, NP >::gd_
private

Definition at line 167 of file solve.cc.

Referenced by manticore::Fcost_gray< NB, NP >::Evaluate().

◆ jcache_

template<unsigned NB, unsigned NP>
double manticore::Fcost_gray< NB, NP >::jcache_[NB *NP]
mutableprivate

Jacobian cache.

Definition at line 172 of file solve.cc.

Referenced by manticore::Fcost_gray< NB, NP >::Evaluate().

◆ pcache_

template<unsigned NB, unsigned NP>
double manticore::Fcost_gray< NB, NP >::pcache_[NP]
mutableprivate

Parameter cache.

Definition at line 172 of file solve.cc.

Referenced by manticore::Fcost_gray< NB, NP >::clearCache(), and manticore::Fcost_gray< NB, NP >::Evaluate().

◆ rcache_

template<unsigned NB, unsigned NP>
double manticore::Fcost_gray< NB, NP >::rcache_[NB]
mutableprivate

Residual cache.

Definition at line 172 of file solve.cc.

Referenced by manticore::Fcost_gray< NB, NP >::Evaluate().

◆ scale

template<unsigned NB, unsigned NP>
constexpr double manticore::Fcost_gray< NB, NP >::scale = 128.0
static

Surface density scaling factor.

Definition at line 97 of file solve.cc.

Referenced by manticore::Fcost_gray< NB, NP >::Evaluate().


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