35 {
"T", { 0.100, 0.180, 0.001 } },
36 {
"muB", { 0.000, 0.000, 0.01 } },
37 {
"muQ", { 0.000, 0.000, 0.01 } },
38 {
"muS", { 0.000, 0.000, 0.01 } }
46 std::ifstream fin(filename);
48 std::cerr <<
"Error: cannot open file " << filename <<
" using default parameter range" << std::endl;
53 while (std::getline(fin, line)) {
54 if (line.empty() || line[0] ==
'#') {
continue; }
55 std::istringstream iss(line);
57 if (!(iss >> param))
continue;
58 if (param[0] ==
'#') {
continue; }
59 double min, max, step;
60 if (!(iss >> min >> max >> step)) {
break; }
75int main(
int argc,
char *argv[])
90 useRG = atoi(argv[3]);
93 string param_range_file =
"";
95 param_range_file = argv[4];
101 string ModelPrefix =
"Id-HRG";
102 if (a == 0. && b == 0.) {
104 ModelPrefix =
"Id-HRG";
108 ModelPrefix =
"EV-HRG";
112 ModelPrefix =
"QvdW-HRG";
117 ModelPrefix =
"RG-HRG";
120 std::string outputfile =
"Thermodynamics-" + ModelPrefix +
"-output.dat";
122 outputfile = argv[5];
132 assert(ModelType >= 0 && ModelType <= 3);
133 if (ModelType == 0) {
135 cout <<
"Performing calculation in the Id-HRG model..." << endl;
137 else if (ModelType == 1) {
140 cout <<
"Performing calculation in the EV-HRG model..." << endl;
142 else if (ModelType == 2) {
145 cout <<
"Performing calculation in the QvdW-HRG model..." << endl;
147 else if (ModelType == 3) {
164 cout <<
"Performing calculation in the RG-HRG model..." << endl;
168 bool useWidth =
false;
174 bool useQStats =
true;
180 ofstream fout(outputfile);
181 const int tabsize = 20;
182 fout << std::setw(tabsize) <<
"T[GeV]" <<
" ";
183 fout << std::setw(tabsize) <<
"muB[GeV]" <<
" ";
184 fout << std::setw(tabsize) <<
"muQ[GeV]" <<
" ";
185 fout << std::setw(tabsize) <<
"muS[GeV]" <<
" ";
186 fout << std::setw(tabsize) <<
"P[GeV/fm3]" <<
" ";
187 fout << std::setw(tabsize) <<
"e[GeV/fm3]" <<
" ";
188 fout << std::setw(tabsize) <<
"s[fm-3]" <<
" ";
189 fout << std::setw(tabsize) <<
"(1/3-p/e)" <<
" ";
190 fout << std::setw(tabsize) <<
"rhoB[fm-3]" <<
" ";
191 fout << std::setw(tabsize) <<
"rhoQ[fm-3]" <<
" ";
192 fout << std::setw(tabsize) <<
"rhoS[fm-3]" <<
" ";
194 fout << std::setw(tabsize) <<
"P/T^4" <<
" ";
195 fout << std::setw(tabsize) <<
"e/T^4" <<
" ";
196 fout << std::setw(tabsize) <<
"s/T^3" <<
" ";
197 fout << std::setw(tabsize) <<
"(e-3p)/T^3" <<
" ";
198 fout << std::setw(tabsize) << std::endl;
208 for(
double T = Tmin; T <= Tmax + 0.1 * dT; T += dT) {
212 cout <<
"Calculating the temperature " << T <<
" GeV" << endl;
217 for(
double muB = muBmin; muB <= muBmax + 0.1 * dmuB; muB += dmuB) {
223 for(
double muQ = muQmin; muQ <= muQmax + 0.1 * dmuQ; muQ += dmuQ) {
229 for(
double muS = muSmin; muS <= muSmax + 0.1 * dmuS; muS += dmuS) {
237 double p = model->Pressure();
238 double e = model->EnergyDensity();
239 double s = model->EntropyDensity();
240 double rhoB = model->BaryonDensity();
241 double rhoQ = model->ElectricChargeDensity();
242 double rhoS = model->StrangenessDensity();
243 double trace_anomaly = (1./3. - p/e);
251 fout << setw(tabsize) << T <<
" ";
252 fout << setw(tabsize) << muB <<
" ";
253 fout << setw(tabsize) << muQ <<
" ";
254 fout << setw(tabsize) << muS <<
" ";
255 fout << setw(tabsize) << p <<
" ";
256 fout << setw(tabsize) << e <<
" ";
257 fout << setw(tabsize) << s <<
" ";
258 fout << setw(tabsize) << trace_anomaly <<
" ";
259 fout << setw(tabsize) << rhoB <<
" ";
260 fout << setw(tabsize) << rhoQ <<
" ";
261 fout << setw(tabsize) << rhoS <<
" ";
262 fout << setw(tabsize) << pT4 <<
" ";
263 fout << setw(tabsize) << eT4 <<
" ";
264 fout << setw(tabsize) << sT3 <<
" ";
265 fout << setw(tabsize) << IT4 <<
" ";
266 fout << setw(tabsize) << endl;
275 cout << setw(30) <<
"Running time: " << (wt2 - wt1) <<
" s" << endl;
276 cout << setw(30) <<
"Time per single calculation: " << (wt2 - wt1) / iters <<
" s" << endl;
@ eBWconstBR
Energy-dependent Breit-Wigner scheme (eBW) with constant branching ratios when evaluating feeddown.
Class containing the particle list.