Class part_calibrate_class_tl (o2scl)¶
-
template<class fp_t = double>
class o2scl::part_calibrate_class_tl¶ Object to organize calibration of particle classes to results stored in a table.
Subclassed by o2scl::part_deriv_calibrate_class
Public Functions
-
template<class part_t>
inline void set_mass_flags(part_t &p, fp_t mot, fp_t T, size_t k)¶ Set mass and flags from mot, T, and the index k.
-
template<class part_t>
inline void set_chem_pot(part_t &p, fp_t psi, fp_t T, size_t k, bool nr_mode)¶ Set chemical potential from psi, T, the index k, and the flag nr_mode.
-
template<class part1_t, class part2_t, class part3_t>
inline void check_density(part1_t &p, part2_t &exact, part3_t &bad, size_t k, fp_t T, fp_t mot, fp_t psi, fp_t &mu_bad, fp_t &m_bad, fp_t &T_bad, fp_t &mot_bad, fp_t &psi_bad, fp_t &ret_local)¶ Check the density against the exact result and update.
-
template<class part1_t, class part2_t, class part3_t>
inline void check_chem_pot(part1_t &p, part2_t &exact, part3_t &bad, size_t k, fp_t T, fp_t mot, fp_t psi, fp_t &mu_bad, fp_t &m_bad, fp_t &T_bad, fp_t &mot_bad, fp_t &psi_bad, fp_t &ret_local)¶ Check the chemical potential against the exact result and update.
-
template<class part1_t, class part2_t, class part3_t>
inline void check_eps(part1_t &p, part2_t &exact, part3_t &bad, size_t k, fp_t T, fp_t mot, fp_t psi, fp_t &mu_bad, fp_t &m_bad, fp_t &T_bad, fp_t &mot_bad, fp_t &psi_bad, fp_t &ret_local)¶ Check the energy density, pressure, and entropy against the exact result and update.
-
template<class part1_t, class part2_t, class part3_t>
inline void check_derivs(part1_t &p, part2_t &exact, part3_t &bad, size_t k, fp_t T, fp_t mot, fp_t psi, fp_t &mu_bad, fp_t &m_bad, fp_t &T_bad, fp_t &mot_bad, fp_t &psi_bad, fp_t &ret_local)¶ Check the three derivatives against the exact result and update.
-
template<class part_t, class thermo_t>
inline fp_t part_calibrate(part_t &p, thermo_t &th, bool test_pair, std::string file, bool nr_mode = false, int verbose = 0, bool external = false)¶ Calibrate a particle thermodynamics class with results stored in a table.
This compares the approximation to the exact results using calc_density(), calc_mu(), pair_density() and pair_mu(). It tries each function twelve times. It tries three different temperatures, setting both
inc_rest_mass
andnon_interacting
equal totrue
andfalse
.The
verbose
parameter controls the amount of output.\verbatim embed:rst .. todo:: In function pair_calibrate() - Future: Also calibrate massless fermions?
-
template<class part_t>