Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

qcdio.h File Reference

Prototypes of gauge configuration IO functions. More...

#include <config.h>
#include <stdio.h>
#include <stdarg.h>
#include <util/data_types.h>
#include <util/lattice.h>
#include <util/qcdio_qprintf.h>
#include <util/ReadLatticePar.h>
#include <util/WriteLatticePar.h>

Go to the source code of this file.

Namespaces

namespace  cps

Defines

#define GAUGE_CONF_PREC   (sizeof(Float))
#define SWAP_BYTE_ORDER   0
#define TRANSPOSE_THE_MATRICES   1

Enumerations

enum  FileIoType { ZERO_ONLY, ADD_ID, ALL_NODES }
 Type of IO. More...

Functions

void qcdio_set_normalize (int)
 Routine to define whether the loaded data should be normalized.
void qload_gauge (char *fprefix, Lattice &lat, int prec=GAUGE_CONF_PREC, int swap=SWAP_BYTE_ORDER, int transp=TRANSPOSE_THE_MATRICES)
 Routine for loading a gauge configuration.
void qsave_gauge (char *fprefix, Lattice &lat, int prec=GAUGE_CONF_PREC, int swap=SWAP_BYTE_ORDER, int transp=TRANSPOSE_THE_MATRICES)
 Routine for saving the current gauge configuration.
FILE * Fopen (FileIoType type, const char *filename, const char *mode)
 Opens a file.
int Fclose (FileIoType type, FILE *stream)
 Closes a file.
size_t Fwrite (const void *ptr, size_t size, size_t n, FILE *stream)
 Prints to a file.
size_t Fread (void *ptr, size_t size, size_t n, FILE *stream)
int Fprintf (FileIoType type, FILE *stream, const char *format,...)
 Read & Write from a file.
int Vfprintf (FileIoType type, FILE *stream, const char *format, va_list ap)
 Prints a variable-length argument list to a file.
FILE * Fopen (const char *filename, const char *mode)
 Opens a file.
int Fclose (FILE *stream)
 Closes a file.
int Fprintf (FILE *stream, const char *format,...)
 Prints to a file.
int Vfprintf (FILE *stream, const char *format, va_list ap)
 Prints a variable-length argument list to a file.


Detailed Description

Prototypes of gauge configuration IO functions.

Id
qcdio.h,v 1.10 2008/06/18 16:07:10 chulwoo Exp

Definition in file qcdio.h.


Define Documentation

#define GAUGE_CONF_PREC   (sizeof(Float))
 

The default precision at which gauge configurations are stored in files.

Definition at line 40 of file qcdio.h.

#define SWAP_BYTE_ORDER   0
 

When loading gauge configurations, should the byte order be swapped before putting the results into memory? To swap the bytes by default, set this to 1, or set it to 0 to leave the byte order alone by default.

Definition at line 47 of file qcdio.h.

#define TRANSPOSE_THE_MATRICES   1
 

When the SU(3) matrices have been loaded, the row vs. column convention must be the same as for the code which generated the configuration. To transpose the matrix by default, set this to be 1, otherwise use 0.

Definition at line 54 of file qcdio.h.


Function Documentation

void cps::qcdio_set_normalize int  newval  ) 
 

Routine to define whether the loaded data should be normalized.

Parameters:
newval Set to 1 if the gauge field is to be normalized, or any other value if it is not.

Definition at line 205 of file qcdio.C.

void cps::qload_gauge char *  fprefix,
Lattice &  lat,
int  prec,
int  swap,
int  transp
 

Routine for loading a gauge configuration.

Loads the gauge configuration from a set of UKQCD format files.

Parameters:
fprefix The prefix of the gauge configuration filenames
lat The Lattice object into which to load the gauge configuration
prec The precision at which the gauge configuration is stored in the file, either sizeof(float) or sizeof(double)
swap 1 if the data need to be byte-swapped when they are read in, 0 otherwise,
transp 1 if the gauge field matrices need to be transposed when they are read in,

Definition at line 774 of file qcdio.C.

References cps::qloadsave_gauge().

void cps::qsave_gauge char *  fprefix,
Lattice &  lat,
int  prec,
int  swap,
int  transp
 

Routine for saving the current gauge configuration.

Saves the gauge configuration into a set of UKQCD format files. Lattice object lat

Parameters:
fprefix The prefix of the gauge configuration filenames
lat The Lattice object from which to write the gauge configuration
prec The precision at which the gauge configuration is stored in the file, either sizeof(float) or sizeof(double)
swap 1 if the data need to be byte-swapped when they are written out, 0 otherwise,
transp 1 if the gauge field matrices need to be transposed when they are written out,

Definition at line 794 of file qcdio.C.

References cps::qloadsave_gauge().


Generated on Sat Oct 10 14:11:41 2009 for Columbia Physics System by  doxygen 1.3.9.1