1 |
+ |
#define _FILE_OFFSET_BITS 64 |
2 |
+ |
|
3 |
|
#include <cstring> |
4 |
|
#include <iostream> |
5 |
|
#include <fstream> |
18 |
|
|
19 |
|
strcpy( outName, entry_plug->statusName ); |
20 |
|
|
21 |
< |
std::cerr << "Opening " << outName << " for stat\n"; |
21 |
> |
//std::cerr << "Opening " << outName << " for stat\n"; |
22 |
|
|
23 |
|
outFile.open(outName, ios::out | ios::trunc ); |
24 |
|
|
32 |
|
} |
33 |
|
|
34 |
|
//outFile.setf( ios::scientific ); |
35 |
< |
outFile << "#time(fs)\ttot_E\tpotential\tkinetic\ttemperature\tpressure\n"; |
35 |
> |
outFile << "#time(fs)\ttot_E\tpotential\tkinetic\ttemperature\tpressure\tvolume\tenthalpy\n"; |
36 |
|
|
37 |
|
|
38 |
|
|
63 |
|
|
64 |
|
void StatWriter::writeStat( double currentTime ){ |
65 |
|
|
66 |
< |
double totE, potE, kinE, temp, press; |
66 |
> |
double totE, potE, kinE, temp, press, vol, enthalpy; |
67 |
|
|
68 |
|
totE = tStats->getTotalE(); |
69 |
|
potE = tStats->getPotential(); |
70 |
|
kinE = tStats->getKinetic(); |
71 |
|
temp = tStats->getTemperature(); |
72 |
|
press = tStats->getPressure(); |
73 |
+ |
vol = tStats->getVolume(); |
74 |
+ |
enthalpy = tStats->getEnthalpy(); |
75 |
|
|
76 |
|
#ifdef IS_MPI |
77 |
|
if(worldRank == 0 ){ |
84 |
|
<< potE << "\t" |
85 |
|
<< kinE << "\t" |
86 |
|
<< temp << "\t" |
87 |
< |
<< press << "\n"; |
87 |
> |
<< press << "\t" |
88 |
> |
<< vol << "\t" |
89 |
> |
<< enthalpy << "\n"; |
90 |
> |
|
91 |
|
outFile.flush(); |
92 |
|
|
93 |
|
#ifdef IS_MPI |