CHROMA
simple_fermbc.cc
Go to the documentation of this file.
1  // $Id: simple_fermbc.cc,v 3.1 2007-08-31 03:33:46 edwards Exp $
2 /*! \file
3  * \brief Simple fermionic BC
4  */
5 
7 
8 namespace Chroma
9 {
10  //! Name
11  namespace SimpleFermBCEnv
12  {
13  const std::string name = "SIMPLE_FERMBC";
14  }
15 
16  //! Read parameters
18  {
19  XMLReader paramtop(xml, path);
20 
21  read(paramtop, "boundary", boundary);
22 
23  if (boundary.size() != Nd)
24  {
25  QDPIO::cerr << __func__ << ": boundary not the expected length = Nd" << std::endl;
26  QDP_abort(1);
27  }
28  }
29 
30 
31  //! Read parameters
32  void read(XMLReader& xml, const std::string& path, SimpleFermBCParams& param)
33  {
34  SimpleFermBCParams tmp(xml, path);
35  param = tmp;
36  }
37 
38  //! Write parameters
39  void write(XMLWriter& xml_out, const std::string& path, const SimpleFermBCParams& param)
40  {
41  if ( path != "." )
42  push(xml_out, path);
43 
44  write(xml_out, "FermBC", SimpleFermBCEnv::name);
45  write(xml_out, "boundary", param.boundary);
46 
47  if( path != "." )
48  pop(xml_out);
49  }
50 
51 }
void read(XMLReader &xml, const std::string &path, AsqtadFermActParams &param)
Read parameters.
void write(XMLWriter &xml, const std::string &path, const AsqtadFermActParams &param)
Writer parameters.
Nd
Definition: meslate.cc:74
const std::string name
Asqtad Staggered-Dirac operator.
Definition: klein_gord.cc:10
LatticeFermion tmp
Definition: mespbg5p_w.cc:36
push(xml_out,"Condensates")
pop(xml_out)
::std::string string
Definition: gtest.h:1979
Simple fermionic BC.
Params for simple fermbc.
Definition: simple_fermbc.h:20