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

  // define the return ion internal energy field
  sf_double internal_energy(T.size(), 0.0);

  // loop through T/rho field and solve for internal energy
  for (size_t i = 0; i < T.size(); i++) {
    Check(T[i] >= 0.0);
    Check(rho[i] >= 0.0);

    internal_energy[i] = analytic_model->calculate_ion_internal_energy(T[i], rho[i]);

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

  return internal_energy;
}
//------------------------------------------------------------------------------------------------//
/*!
 *
 * \brief Return a field of ion internal energies given fields of temperature
 * and density.
 *
 * Given temperature and density fields, return an ion internal energy field.
 * The ion internal energy field is the same size as the input temperature
 * and density fields. The ion internal energy 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 ion internal energy field in kJ/g
 */
\brief Return a field of ion internal energies given fields of temperature
and density.

Given temperature and density fields, return an ion internal energy field.
The ion internal energy field is the same size as the input temperature
and density fields. The ion internal energy 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 ion internal energy field in kJ/g
\ brief Return a field of ion internal energies given fields of temperature and density . Given temperature and density fields return an ion internal energy field . The ion internal energy field is the same size as the input temperature and density fields . The ion internal energy 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 ion internal energy field in kJ / g
Analytic_EoS::sf_double Analytic_EoS::getSpecificIonInternalEnergy(const sf_double &T,
                                                                   const sf_double &rho) const {
  Require(T.size() == rho.size());
  sf_double internal_energy(T.size(), 0.0);
  for (size_t i = 0; i < T.size(); i++) {
    Check(T[i] >= 0.0);
    Check(rho[i] >= 0.0);
    internal_energy[i] = analytic_model->calculate_ion_internal_energy(T[i], rho[i]);
    Check(internal_energy[i] >= 0.0);
  }
  return internal_energy;
}
Analytic_EoS :: sf_double Analytic_EoS :: getSpecificIonInternalEnergy ( const sf_double & T , const sf_double & rho ) const { Require ( T . size ( ) == rho . size ( ) ) ; sf_double internal_energy ( T . size ( ) , 0.0 ) ; for ( size_t i = 0 ; i < T . size ( ) ; i ++ ) { Check ( T [ i ] >= 0.0 ) ; Check ( rho [ i ] >= 0.0 ) ; internal_energy [ i ] = analytic_model -> calculate_ion_internal_energy ( T [ i ] , rho [ i ] ) ; Check ( internal_energy [ i ] >= 0.0 ) ; } return internal_energy ; }
\brief Return a field of ion internal energies given fields of temperature
 and density.
\ brief Return a field of ion internal energies given fields of temperature and density .
// define the return ion internal energy field // loop through T/rho field and solve for internal energy