src/cdi_analytic/Analytic_EoS.cc
Analytic_EoS::sf_double Analytic_EoS::getNumFreeElectronsPerIon(const sf_double &T,
                                                                const sf_double &rho) const {
  Require(T.size() == rho.size());

  // define the return ion heat capacity field
  sf_double number(T.size(), 0.0);

  // loop through T/rho field and solve for the number of free electrons
  // per ion
  for (size_t i = 0; i < T.size(); i++) {
    Check(T[i] >= 0.0);
    Check(rho[i] >= 0.0);

    number[i] = analytic_model->calculate_num_free_elec_per_ion(T[i], rho[i]);

    Check(number[i] >= 0.0);
  }

  return number;
}
//------------------------------------------------------------------------------------------------//
/*!
 *
 * \brief Return a field of numbers of free electrons per ion given fields of
 * temperature and density.
 *
 * Given temperature and density fields, return a number of free electrons
 * per ion field.  The number of free electrons per ion field is the same
 * size as the input temperature and density fields. The number of free
 * electrons per ion is defined by the analytic model given to the
 * constructor (Analytic_EoS()).
 *
 * \param T material temperature field in keV
 * \param rho density field in g/cm^3
 * \return number of free electrons per ion
 */
\brief Return a field of numbers of free electrons per ion given fields of
temperature and density.

Given temperature and density fields, return a number of free electrons
per ion field.  The number of free electrons per ion field is the same
size as the input temperature and density fields. The number of free
electrons per ion is defined by the analytic model given to the
constructor (Analytic_EoS()).

\param T material temperature field in keV
\param rho density field in g/cm^3
\return number of free electrons per ion
\ brief Return a field of numbers of free electrons per ion given fields of temperature and density . Given temperature and density fields return a number of free electrons per ion field . The number of free electrons per ion field is the same size as the input temperature and density fields . The number of free electrons per ion is defined by the analytic model given to the constructor ( Analytic_EoS () ) . \ param T material temperature field in keV \ param rho density field in g / cm^3 \ return number of free electrons per ion
Analytic_EoS::sf_double Analytic_EoS::getNumFreeElectronsPerIon(const sf_double &T,
                                                                const sf_double &rho) const {
  Require(T.size() == rho.size());
  sf_double number(T.size(), 0.0);
  for (size_t i = 0; i < T.size(); i++) {
    Check(T[i] >= 0.0);
    Check(rho[i] >= 0.0);
    number[i] = analytic_model->calculate_num_free_elec_per_ion(T[i], rho[i]);
    Check(number[i] >= 0.0);
  }
  return number;
}
Analytic_EoS :: sf_double Analytic_EoS :: getNumFreeElectronsPerIon ( const sf_double & T , const sf_double & rho ) const { Require ( T . size ( ) == rho . size ( ) ) ; sf_double number ( T . size ( ) , 0.0 ) ; for ( size_t i = 0 ; i < T . size ( ) ; i ++ ) { Check ( T [ i ] >= 0.0 ) ; Check ( rho [ i ] >= 0.0 ) ; number [ i ] = analytic_model -> calculate_num_free_elec_per_ion ( T [ i ] , rho [ i ] ) ; Check ( number [ i ] >= 0.0 ) ; } return number ; }
\brief Return a field of numbers of free electrons per ion given fields of
 temperature and density.
\ brief Return a field of numbers of free electrons per ion given fields of temperature and density .
// define the return ion heat capacity field // loop through T/rho field and solve for the number of free electrons // per ion