GLAC  1.0
fieldio.h
Go to the documentation of this file.
1 
11 #ifndef FIELDIO_H
12 #define FIELDIO_H
13 
14 #include <string>
15 #include "math/matrices/su3.h"
16 #include "math/lattice.h"
17 
18 namespace IO {
19  class FieldIO
20  {
21  private:
22  // For writing to file
23  static const long long m_linkDoubles;// = 72;
24  static const long long m_linkSize;// = m_linkDoubles*sizeof(double);
25  static const long long m_SU3Doubles;
26  static const long long m_SU3Size;
27 
28  static std::vector<unsigned int> m_N;
29  static inline double reverseDouble(const double inDouble);
30  static inline bool check_file_existence (const std::string fname);
31  public:
32  FieldIO();
33  ~FieldIO();
34  static void init();
35  static void writeFieldToFile(Lattice<SU3> *lattice, unsigned int configNumber);
36  static void writeDoublesFieldToFile(Lattice<double> lattice, unsigned int configNumber, std::string observable);
37  static void loadFieldConfiguration(std::string filename, Lattice<SU3> *lattice);
38  static void loadChromaFieldConfiguration(std::string filename, Lattice<SU3> *lattice);
39  };
40 }
41 
42 #endif // FIELDIO_H
static void init()
IO::FieldIO::init updates the lattice dimensions.
Definition: fieldio.cpp:47
Definition: fieldio.h:19
static void writeFieldToFile(Lattice< SU3 > *lattice, unsigned int configNumber)
IO::FieldIO::writeFieldToFile writes a lattice of SU3 matrix objects to file.
Definition: fieldio.cpp:61
static void loadFieldConfiguration(std::string filename, Lattice< SU3 > *lattice)
IO::FieldIO::loadFieldConfiguration loads a regular configuration into memory.
Definition: fieldio.cpp:189
FieldIO()
IO::FieldIO::FieldIO initializes the FieldIO object.
Definition: fieldio.cpp:29
static void writeDoublesFieldToFile(Lattice< double > lattice, unsigned int configNumber, std::string observable)
IO::FieldIO::writeDoublesFieldToFile writes a lattice of doubles to file.
Definition: fieldio.cpp:132
static void loadChromaFieldConfiguration(std::string filename, Lattice< SU3 > *lattice)
IO::FieldIO::loadChromaFieldConfiguration loads a configuration from Chroma into memory.
Definition: fieldio.cpp:245
~FieldIO()
IO::FieldIO::~FieldIO.
Definition: fieldio.cpp:38