27 #include "antioch_config.h"
29 #ifdef ANTIOCH_HAVE_CPPUNIT
41 template<
typename Scalar>
54 std::vector<Scalar> temp(3);
90 const std::vector<Scalar>& exact_coeffs,
101 CPPUNIT_ASSERT_DOUBLES_EQUAL( cp, curve_fit.
cp_over_R(cache), this->
tol() );
105 const std::vector<Scalar>& exact_coeffs,
117 CPPUNIT_ASSERT_DOUBLES_EQUAL( h, curve_fit.
h_over_RT(cache), this->
tol() );
121 const std::vector<Scalar>& exact_coeffs,
133 CPPUNIT_ASSERT_DOUBLES_EQUAL( s, curve_fit.
s_over_R(cache), this->
tol() );
137 {
return std::numeric_limits<Scalar>::epsilon() * 500; }
139 Scalar
cp_exact( Scalar T, Scalar a0, Scalar a1, Scalar a2, Scalar a3, Scalar a4 )
141 return a0 + a1*T + a2*T*T + a3*T*T*T + a4*(T*T*T*T);
144 Scalar
h_exact( Scalar T, Scalar a0, Scalar a1, Scalar a2, Scalar a3, Scalar a4, Scalar a5 )
146 return a0 + a1/2.0L*T + a2/3.0L*T*T + a3/4.0L*T*T*T + a4/5.0L*(T*T*T*T) + a5/T;
149 Scalar
s_exact( Scalar T, Scalar a0, Scalar a1, Scalar a2, Scalar a3, Scalar a4, Scalar a6 )
151 return a0*std::log(T) + a1*T + a2/2.0L*T*T + a3/3.0L*T*T*T + a4/4.0L*(T*T*T*T) + a6;
198 #endif // ANTIOCH_HAVE_CPPUNIT
std::vector< Scalar > _H2_coeffs_1000_3500
CPPUNIT_TEST(test_nasa7_default_temp_intervals)
void test_h(Scalar T, const std::vector< Scalar > &exact_coeffs, const Antioch::NASA7CurveFit< Scalar > &curve_fit)
Scalar s_exact(Scalar T, Scalar a0, Scalar a1, Scalar a2, Scalar a3, Scalar a4, Scalar a6)
void test_s(Scalar T, const std::vector< Scalar > &exact_coeffs, const Antioch::NASA7CurveFit< Scalar > &curve_fit)
std::vector< Scalar > _H2_coeffs_200_1000
StateType s_over_R(const TempCache< StateType > &cache) const
Scalar cp_exact(Scalar T, Scalar a0, Scalar a1, Scalar a2, Scalar a3, Scalar a4)
void test_nasa7_default_temp_intervals()
Scalar cp(Scalar T, Scalar a0, Scalar a1, Scalar a2, Scalar a3, Scalar a4, Scalar a5, Scalar a6)
void test_nasa7_user_specified_temp_intervals()
CPPUNIT_TEST_SUITE(NASA7CurveFitTestLongDouble)
void test_cp(Scalar T, const std::vector< Scalar > &exact_coeffs, const Antioch::NASA7CurveFit< Scalar > &curve_fit)
std::vector< Scalar > _N2_coeffs_300_1000
CPPUNIT_TEST(test_nasa7_default_temp_intervals)
StateType h_over_RT(const TempCache< StateType > &cache) const
CPPUNIT_TEST_SUITE_REGISTRATION(ArrheniusRateEigenFloatTest)
Scalar h_exact(Scalar T, Scalar a0, Scalar a1, Scalar a2, Scalar a3, Scalar a4, Scalar a5)
CPPUNIT_TEST_SUITE(NASA7CurveFitTestDouble)
const StateType cp_over_R(const TempCache< StateType > &cache) const
void N2_test(const Antioch::NASA7CurveFit< Scalar > &curve_fit)
std::vector< Scalar > _all_standard_N2_coeffs
CPPUNIT_TEST_SUITE(NASA7CurveFitTestFloat)
CPPUNIT_TEST(test_nasa7_default_temp_intervals)
std::vector< Scalar > _N2_coeffs_1000_5000
std::vector< Scalar > _all_standard_H2_coeffs
void H2_test(const Antioch::NASA7CurveFit< Scalar > &curve_fit)