47 std::cerr <<
"Error: Must specify input file." << std::endl;
51 GetPot input( argv[1] );
53 std::vector<std::string> species(5);
54 species[0] = input(
"Materials/TestMaterial/GasMixture/species",
"DIE!", 0 );
55 species[1] = input(
"Materials/TestMaterial/GasMixture/species",
"DIE!", 1 );
56 species[2] = input(
"Materials/TestMaterial/GasMixture/species",
"DIE!", 2 );
57 species[3] = input(
"Materials/TestMaterial/GasMixture/species",
"DIE!", 3 );
58 species[4] = input(
"Materials/TestMaterial/GasMixture/species",
"DIE!", 4 );
68 std::vector<double> Y(5,0.2);
70 double rho = P/T/cantera_mixture.R_mix(Y);
78 std::vector<double> Tqp(1,T);
79 std::vector<double> Pqp(1,P);
80 std::vector<std::vector<double> > Yqp(1,Y);
87 std::vector<libMesh::Real> D(5,0.0);
91 cantera_trans.mu_and_k_and_D( T, rho, dummy, Y, mu, k, D );
95 const double tol = 6.0e-15;
97 const double mu_reg = 4.2134235819759682e-05;
98 const double k_reg = 5.7138665373733508e-02;
99 std::vector<libMesh::Real> D_reg(5,0.0);
100 D_reg[0] = 1.7611544183904180e-04;
101 D_reg[1] = 1.7169898621123060e-04;
102 D_reg[2] = 1.7379080956310527e-04;
103 D_reg[3] = 2.6991049091576078e-04;
104 D_reg[4] = 2.6488528311729070e-04;
106 if( std::fabs( (mu_reg - mu)/mu ) > tol )
108 std::cerr <<
"Error: Mismatch in viscosity." << std::endl
109 << std::setprecision(16) << std::scientific
110 <<
"mu = " << mu << std::endl
111 <<
"mu_reg = " << mu_reg << std::endl;
115 if( std::fabs( (k_reg - k)/k ) > tol )
117 std::cerr <<
"Error: Mismatch in thermal conductivity." << std::endl
118 << std::setprecision(16) << std::scientific
119 <<
"k = " << k << std::endl
120 <<
"k_reg = " << k_reg << std::endl;
124 for(
unsigned int i = 0; i < 5; i++ )
126 if( std::fabs( (D_reg[i] - D[i])/D[i] ) > tol )
128 std::cerr <<
"Error: Mismatch in diffusion coefficient." << std::endl
129 << std::setprecision(16) << std::scientific
130 <<
"i = " << i << std::endl
131 <<
"D = " << D[i] << std::endl
132 <<
"D_reg = " << D_reg[i] << std::endl;
void set_values(unsigned int quantity, std::vector< libMesh::Number > &values)
Wrapper class for storing state for computing thermochemistry and transport properties using Cantera...
void add_quantity(unsigned int quantity)
Wrapper class for evaluating transport properties using Cantera.
void set_vector_values(unsigned int quantity, std::vector< std::vector< libMesh::Number > > &values)