TBTK
TBTK::FileWriter Class Reference

#include <FileWriter.h>

Static Public Member Functions

static void writeModel (const Model &model, std::string name="Model", std::string path="/")
 
static void writeHoppingAmplitudeSet (const HoppingAmplitudeSet &hoppingAmplitudeSet, std::string name="HoppingAmplitudeSet", std::string path="/")
 
static void writeGeometry (const Geometry &geometry, std::string name="Geometry", std::string path="/")
 
static void writeIndexTree (const IndexTree &indexTree, std::string name="IndexTree", std::string path="/")
 
static void writeEigenValues (const Property::EigenValues &ev, std::string name="EigenValues", std::string path="/")
 
static void writeWaveFunctions (const Property::WaveFunctions &waveFunctions, std::string name="WaveFunctions", std::string path="/")
 
static void writeDOS (const Property::DOS &dos, std::string name="DOS", std::string path="/")
 
static void writeDensity (const Property::Density &density, std::string name="Density", std::string path="/")
 
static void writeMagnetization (const Property::Magnetization &magnetization, std::string name="Magnetization", std::string path="/")
 
static void writeLDOS (const Property::LDOS &ldos, std::string name="LDOS", std::string path="/")
 
static void writeSpectralFunction (const Property::SpectralFunction &spectralFunction, std::string name="SpectralFunction", std::string path="/")
 
static void writeSpinPolarizedLDOS (const Property::SpinPolarizedLDOS &spinPolarizedLDOS, std::string name="SpinPolarizedLDOS", std::string path="/")
 
static void write (const int *data, int rank, const int *dims, std::string name, std::string path="/")
 
static void write (const double *data, int rank, const int *dims, std::string name, std::string path="/")
 
static void write (const std::complex< double > *data, int rank, const int *dims, std::string name, std::string path="/")
 
static void writeAttributes (const int *attributes, const std::string *attribute_names, int num, std::string name, std::string path="/")
 
static void writeAttributes (const double *attributes, const std::string *attribute_names, int num, std::string name, std::string path="/")
 
static void writeParameterSet (const ParameterSet *parameterSet, std::string name="ParameterSet", std::string path="/")
 
static void setFileName (std::string filename)
 
static void clear ()
 
static bool exists ()
 

Detailed Description

Writes data to a .hdf5-file. The default file name is TBTKResults.h5. Can be used to write custom n-dimensional arrays of data and parameters to datasets with custom names. It can also be used to write data such as eigenvalues, DOS, Density etc. extracted by the PropertyExtractor. In the later case the data can immediately be plotted using the bundled python plotting scripts.

Member Function Documentation

void TBTK::FileWriter::clear ( )
inlinestatic

Remove any file from the current folder with the file name set by FileWriter::setFileName

static bool TBTK::FileWriter::exists ( )
static

Returns true if current input file exists.

void TBTK::FileWriter::setFileName ( std::string  filename)
inlinestatic

Set output file name. Default is TBTKResults.h5.

static void TBTK::FileWriter::write ( const int *  data,
int  rank,
const int *  dims,
std::string  name,
std::string  path = "/" 
)
static

Write custom n-dimensional arrays to file of type int.

static void TBTK::FileWriter::write ( const double *  data,
int  rank,
const int *  dims,
std::string  name,
std::string  path = "/" 
)
static

Write custom n-dimensional arrays to file of type double.

static void TBTK::FileWriter::write ( const std::complex< double > *  data,
int  rank,
const int *  dims,
std::string  name,
std::string  path = "/" 
)
static

Write custom n-dimensional arrays to file of type complex<double>.

static void TBTK::FileWriter::writeAttributes ( const int *  attributes,
const std::string *  attribute_names,
int  num,
std::string  name,
std::string  path = "/" 
)
static

Write custom attributes to file of type int.

static void TBTK::FileWriter::writeAttributes ( const double *  attributes,
const std::string *  attribute_names,
int  num,
std::string  name,
std::string  path = "/" 
)
static

Write custom attributes to file of type double.

static void TBTK::FileWriter::writeDensity ( const Property::Density density,
std::string  name = "Density",
std::string  path = "/" 
)
static

Write density to file.

static void TBTK::FileWriter::writeDOS ( const Property::DOS dos,
std::string  name = "DOS",
std::string  path = "/" 
)
static

Write density of states to file.

static void TBTK::FileWriter::writeEigenValues ( const Property::EigenValues ev,
std::string  name = "EigenValues",
std::string  path = "/" 
)
static

Write eigenvalues to file.

static void TBTK::FileWriter::writeHoppingAmplitudeSet ( const HoppingAmplitudeSet hoppingAmplitudeSet,
std::string  name = "HoppingAmplitudeSet",
std::string  path = "/" 
)
static

Experimental. Write HoppingAmplitudeSet to file.

static void TBTK::FileWriter::writeLDOS ( const Property::LDOS ldos,
std::string  name = "LDOS",
std::string  path = "/" 
)
static

Write local density of states to file.

static void TBTK::FileWriter::writeMagnetization ( const Property::Magnetization magnetization,
std::string  name = "Magnetization",
std::string  path = "/" 
)
static

Write magnetization to file.

static void TBTK::FileWriter::writeModel ( const Model model,
std::string  name = "Model",
std::string  path = "/" 
)
static

Write model to file.

static void TBTK::FileWriter::writeParameterSet ( const ParameterSet parameterSet,
std::string  name = "ParameterSet",
std::string  path = "/" 
)
static

Write ParamterSet to file.

void TBTK::FileWriter::writeSpectralFunction ( const Property::SpectralFunction spectralFunction,
std::string  name = "SpectralFunction",
std::string  path = "/" 
)
inlinestatic

Write spectral function to file.

static void TBTK::FileWriter::writeSpinPolarizedLDOS ( const Property::SpinPolarizedLDOS spinPolarizedLDOS,
std::string  name = "SpinPolarizedLDOS",
std::string  path = "/" 
)
static

Write spin-polarized local density of states to file.

static void TBTK::FileWriter::writeWaveFunctions ( const Property::WaveFunctions waveFunctions,
std::string  name = "WaveFunctions",
std::string  path = "/" 
)
static

Write wave function to file.


The documentation for this class was generated from the following file: