You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: include/output.hpp
+13-7Lines changed: 13 additions & 7 deletions
Original file line number
Diff line number
Diff line change
@@ -19,13 +19,19 @@ class Output{
19
19
int output_frequency; /* Output frequency in time domain: write output at every <num> time step. */
20
20
std::vector<std::vector<std::string> > outputstr; // List of outputs for each oscillator
21
21
22
-
boolwritefullstate; /* Flag to determin if full state vector should be written to file */
22
+
boolwriteFullState; /* Flag to determine if full state vector should be written to file */
23
23
FILE *ufile; /* File for writing real part of solution vector */
24
24
FILE *vfile; /* File for writing imaginary part of solution vector */
25
-
std::vector<FILE *>expectedfile; /* Files for writing the evolution of the expected energy levels per oscillator */
26
-
FILE *expectedfile_comp; /* File for writing the evolution of the expected energy level of the composite system */
27
-
FILE *populationfile_comp; /* File for writing the evolution of the population of the composite system */
25
+
26
+
std::vector<bool> writeExpectedEnergy; ///< Flag to determine if the evolution of the expected energy per oscillator should be written to files.
27
+
bool writeExpectedEnergy_comp; ///< Flag to determine if the evolution of the expected energy of the full composite system should be written to file
28
+
std::vector<FILE *>expectedfile; /* Files for writing the evolution of the expected energy per oscillator */
29
+
FILE *expectedfile_comp; /* File for writing the evolution of the expected energy level of the full composite system */
30
+
31
+
std::vector<bool> writePopulation; ///< Flag to determine if the evolution of the energy level occupations per oscillator should be written to files.
32
+
bool writePopulation_comp; ///< Flag to determine if the evolution of the energy level occupations of the full composite system should be written to file
28
33
std::vector<FILE *>populationfile; /* Files for writing population over time */
34
+
FILE *populationfile_comp; /* File for writing the evolution of the population of the composite system */
29
35
30
36
// VecScatter scat; /* Petsc's scatter context to communicate a state across petsc's cores */
31
37
// Vec xseq; /* A sequential vector for IO. */
@@ -49,8 +55,8 @@ class Output{
49
55
voidwriteGradient(Vec grad);
50
56
51
57
/* Open, write and close files for fullstate and expected energy levels over time */
52
-
voidopenDataFiles(std::string prefix, int initid);
53
-
voidwriteDataFiles(int timestep, double time, const Vec state, MasterEq* mastereq);
54
-
voidcloseDataFiles();
58
+
voidopenTrajectoryDataFiles(std::string prefix, int initid);
59
+
voidwriteTrajectoryDataFiles(int timestep, double time, const Vec state, MasterEq* mastereq);
0 commit comments