1
0
mirror of https://github.com/paboyle/Grid.git synced 2025-06-17 07:17:06 +01:00

Skeleton of HMC/Integrators

This commit is contained in:
neo
2015-07-03 16:51:41 +09:00
parent 4deffd1ccb
commit ab3ad78ece
13 changed files with 263 additions and 15 deletions

50
lib/qcd/hmc/HMC.h Normal file
View File

@ -0,0 +1,50 @@
//--------------------------------------------------------------------
/*! @file HMC.h
* @brief Declaration of classes for HybridMonteCarlo update
*
* @author Guido Cossu
*/
//--------------------------------------------------------------------
#ifndef HMC_INCLUDED
#define HMC_INCLUDED
#include <string>
#include <memory>
namespace Grid{
namespace QCD{
struct HMCparameters{
Integer Nsweeps; /* @brief Number of sweeps in this run */
Integer TotalSweeps; /* @brief If provided, the total number of sweeps */
Integer ThermalizationSteps;
Integer StartingConfig;
Integer SaveInterval; //Setting to 0 does not save configurations
std::string Filename_prefix; // To save configurations
HMCparameters();
};
class HybridMonteCarlo{
const HMCparameters Params;
GridSerialRNG& RNG;
// FIXME need the integrator
bool metropolis_test(const RealD DeltaH)const;
RealD evolve_step(LatticeColourMatrix&)const;
public:
HybridMonteCarlo(GridSerialRNG&);
~HybridMonteCarlo(){};
void evolve(LatticeColourMatrix& Uin)const;
};
}// QCD
}// Grid
#endif