47 char parName[255], parValue[255];
48 ifstream fin(parFile);
50 cout <<
"cannot open parameters file " << parFile << endl;
56 istringstream sline(line);
57 sline >> parName >> parValue;
58 if (strcmp(parName,
"outputDir") == 0)
60 else if (strcmp(parName,
"eosType") == 0)
62 else if (strcmp(parName,
"icInputFile") == 0)
64 else if (strcmp(parName,
"nx") == 0)
66 else if (strcmp(parName,
"ny") == 0)
68 else if (strcmp(parName,
"nz") == 0)
70 else if (strcmp(parName,
"icModel") == 0)
72 else if (strcmp(parName,
"glauberVar") == 0)
74 else if (strcmp(parName,
"xmin") == 0)
75 xmin = atof(parValue);
76 else if (strcmp(parName,
"xmax") == 0)
77 xmax = atof(parValue);
78 else if (strcmp(parName,
"ymin") == 0)
79 ymin = atof(parValue);
80 else if (strcmp(parName,
"ymax") == 0)
81 ymax = atof(parValue);
82 else if (strcmp(parName,
"etamin") == 0)
84 else if (strcmp(parName,
"etamax") == 0)
86 else if (strcmp(parName,
"tau0") == 0)
87 tau0 = atof(parValue);
88 else if (strcmp(parName,
"tauMax") == 0)
90 else if (strcmp(parName,
"dtau") == 0)
91 dtau = atof(parValue);
92 else if (strcmp(parName,
"e_crit") == 0)
93 eCrit = atof(parValue);
94 else if (strcmp(parName,
"etaS") == 0)
95 etaS = atof(parValue);
96 else if (strcmp(parName,
"zetaS") == 0)
97 zetaS = atof(parValue);
98 else if (strcmp(parName,
"epsilon0") == 0)
100 else if (strcmp(parName,
"alpha") == 0)
101 alpha = atof(parValue);
102 else if (strcmp(parName,
"impactPar") == 0)
104 else if (strcmp(parName,
"s0ScaleFactor") == 0)
106 else if (parName[0] ==
'!')
107 cout <<
"CCC " << sline.str() << endl;
109 cout <<
"UUU " << sline.str() << endl;
114 cout <<
"====== parameters ======\n";
115 cout <<
"outputDir = " <<
outputDir << endl;
116 cout <<
"eosType = " <<
eosType << endl;
117 cout <<
"nx = " <<
nx << endl;
118 cout <<
"ny = " <<
ny << endl;
119 cout <<
"nz = " <<
nz << endl;
120 cout <<
"icModel = " <<
icModel << endl;
123 cout <<
"xmin = " <<
xmin << endl;
124 cout <<
"xmax = " <<
xmax << endl;
125 cout <<
"ymin = " <<
ymin << endl;
126 cout <<
"ymax = " <<
ymax << endl;
127 cout <<
"etamin = " <<
etamin << endl;
128 cout <<
"etamax = " <<
etamax << endl;
129 cout <<
"tau0 = " <<
tau0 << endl;
130 cout <<
"tauMax = " <<
tauMax << endl;
131 cout <<
"dtau = " <<
dtau << endl;
132 cout <<
"e_crit = " <<
eCrit << endl;
133 cout <<
"eta/s = " <<
etaS << endl;
134 cout <<
"zeta/s = " <<
zetaS << endl;
135 cout <<
"epsilon0 = " <<
epsilon0 << endl;
136 cout <<
"alpha = " <<
alpha << endl;
137 cout <<
"impactPar = " <<
impactPar << endl;
139 cout <<
"======= end parameters =======\n";
151 int main(
int argc,
char **argv) {
164 cout <<
"NO PARAMETERS, exiting\n";
173 char eosfile[] =
"eos/Laine_nf3.dat";
175 eos =
new EoSs(eosfile, ncols);
180 f =
new Fluid(eos, eos, trcoeff,
nx,
ny,
nz,
xmin,
xmax,
ymin,
ymax,
etamin,
182 cout <<
"fluid allocation done\n";
198 cout <<
"icModel = " <<
icModel <<
" not implemented\n";
204 float diff = difftime(tinit, start);
205 cout <<
"Init time = " << diff <<
" [sec]" << endl;
217 for (
int istep = 0; istep <
maxstep; istep++) {
223 for (
int j = 0;
j < nSubSteps;
j++) {
226 cout <<
"step= " << istep <<
" dtau= " <<
dtau / nSubSteps <<
"\n"
234 float diff2 = difftime(
end, start);
235 cout <<
"Execution time = " << diff2 <<
" [sec]" << endl;