Bridge++  Ver. 2.0.2
HMC_Leapfrog Class Reference

HMC with single level leapfrog intetgrator. More...

#include <hmc_Leapfrog.h>

Public Member Functions

 HMC_Leapfrog (std::vector< Action * > action, RandomNumbers *rand)
 constructor: with array of actions More...
 
 HMC_Leapfrog (std::vector< Action * > action, std::vector< Director * > director, RandomNumbers *rand)
 constructor: with array of actions and directors More...
 
 HMC_Leapfrog (const ActionList &action_list, RandomNumbers *rand)
 constructor: with action_list More...
 
 HMC_Leapfrog (const ActionList &action_list, std::vector< Director * > director, RandomNumbers *rand)
 constructor: with action_list and array of directors More...
 
 HMC_Leapfrog (std::vector< Action * > action, RandomNumbers *rand, const Parameters &params)
 constructor: with array of actions More...
 
 HMC_Leapfrog (std::vector< Action * > action, std::vector< Director * > director, RandomNumbers *rand, const Parameters &params)
 constructor: with array of actions and directors More...
 
 HMC_Leapfrog (const ActionList &action_list, RandomNumbers *rand, const Parameters &params)
 constructor: with action_list More...
 
 HMC_Leapfrog (const ActionList &action_list, std::vector< Director * > director, RandomNumbers *rand, const Parameters &params)
 constructor: with action_list and array of directors More...
 
 ~HMC_Leapfrog ()
 destructor More...
 
void set_parameters (const Parameters &params)
 
DEPRECATED void set_parameters (const double Estep, const int Nmdc, const int Nprec, const int Metropolis_test)
 
void set_parameters (const double Estep, const int Nmdc, const int Nprec, const bool Metropolis_test)
 
void set_parameter_verboselevel (const Bridge::VerboseLevel vl)
 
void get_parameters (Parameters &params) const
 
double update (Field_G &)
 
double langevin (Field_G &iP, const Field_G &U)
 
double calc_Hamiltonian (const Field_G &iP, const Field_G &U)
 
double calcH_P (const Field_G &iP)
 
void integrate (Field_G &iP, Field_G &U)
 
void update_U (const double estep, const Field_G &iP, Field_G &U)
 
void update_P (const double estep, Field_G &iP, const Field_G &U)
 

Static Public Attributes

static const std::string class_name = "HMC_Leapfrog"
 

Private Member Functions

 HMC_Leapfrog (const HMC_Leapfrog &)
 
HMC_Leapfrogoperator= (const HMC_Leapfrog &)
 

Private Attributes

int m_Nmdc
 
int m_Nprec
 
bool m_Metropolis_test
 
double m_Estep
 
Langevin_Momentumm_Langevin_P
 
Staple_lexm_staple
 
std::vector< Action * > m_action
 
std::vector< Director * > m_director
 
RandomNumbersm_rand
 
Bridge::VerboseLevel m_vl
 

Detailed Description

HMC with single level leapfrog intetgrator.

This class implements standartd HMC with a simple leapfrog molecular dynamics integrator. While more general integrator is now available, this class is easy to understand and convenient for a first test, and thus kept as it is. 28 Dec 2011 H.Matsufuru YAML is implemented. [03 Mar 2013 Y.Namekawa] Langevin step was moved to separate class. [07 May 2014 H.Matsufuru] unique_ptr is introduced to avoid memory leaks [21 Mar 2015 Y.Namekawa]

Definition at line 44 of file hmc_Leapfrog.h.

Constructor & Destructor Documentation

◆ HMC_Leapfrog() [1/9]

HMC_Leapfrog::HMC_Leapfrog ( std::vector< Action * >  action,
RandomNumbers rand 
)

constructor: with array of actions

Definition at line 20 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [2/9]

HMC_Leapfrog::HMC_Leapfrog ( std::vector< Action * >  action,
std::vector< Director * >  director,
RandomNumbers rand 
)

constructor: with array of actions and directors

Definition at line 40 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [3/9]

HMC_Leapfrog::HMC_Leapfrog ( const ActionList action_list,
RandomNumbers rand 
)

constructor: with action_list

Definition at line 65 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [4/9]

HMC_Leapfrog::HMC_Leapfrog ( const ActionList action_list,
std::vector< Director * >  director,
RandomNumbers rand 
)

constructor: with action_list and array of directors

Definition at line 87 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [5/9]

HMC_Leapfrog::HMC_Leapfrog ( std::vector< Action * >  action,
RandomNumbers rand,
const Parameters params 
)

constructor: with array of actions

constructor: with array of actions and parameters

Definition at line 114 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [6/9]

HMC_Leapfrog::HMC_Leapfrog ( std::vector< Action * >  action,
std::vector< Director * >  director,
RandomNumbers rand,
const Parameters params 
)

constructor: with array of actions and directors

constructor: with array of actions and directors and parameters

Definition at line 137 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [7/9]

HMC_Leapfrog::HMC_Leapfrog ( const ActionList action_list,
RandomNumbers rand,
const Parameters params 
)

constructor: with action_list

constructor: with action_list and parameters

Definition at line 165 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [8/9]

HMC_Leapfrog::HMC_Leapfrog ( const ActionList action_list,
std::vector< Director * >  director,
RandomNumbers rand,
const Parameters params 
)

constructor: with action_list and array of directors

constructor: with action_list and array of directors and parameters

Definition at line 190 of file hmc_Leapfrog.cpp.

◆ ~HMC_Leapfrog()

HMC_Leapfrog::~HMC_Leapfrog ( )

destructor

Definition at line 220 of file hmc_Leapfrog.cpp.

◆ HMC_Leapfrog() [9/9]

HMC_Leapfrog::HMC_Leapfrog ( const HMC_Leapfrog )
private

Member Function Documentation

◆ calc_Hamiltonian()

double HMC_Leapfrog::calc_Hamiltonian ( const Field_G iP,
const Field_G U 
)

Definition at line 429 of file hmc_Leapfrog.cpp.

◆ calcH_P()

double HMC_Leapfrog::calcH_P ( const Field_G iP)

Definition at line 460 of file hmc_Leapfrog.cpp.

◆ get_parameters()

void HMC_Leapfrog::get_parameters ( Parameters params) const

Definition at line 278 of file hmc_Leapfrog.cpp.

◆ integrate()

void HMC_Leapfrog::integrate ( Field_G iP,
Field_G U 
)

Definition at line 471 of file hmc_Leapfrog.cpp.

◆ langevin()

double HMC_Leapfrog::langevin ( Field_G iP,
const Field_G U 
)

Definition at line 394 of file hmc_Leapfrog.cpp.

◆ operator=()

HMC_Leapfrog& HMC_Leapfrog::operator= ( const HMC_Leapfrog )
private

◆ set_parameter_verboselevel()

void HMC_Leapfrog::set_parameter_verboselevel ( const Bridge::VerboseLevel  vl)
inline

Definition at line 120 of file hmc_Leapfrog.h.

◆ set_parameters() [1/3]

void HMC_Leapfrog::set_parameters ( const double  Estep,
const int  Nmdc,
const int  Nprec,
const bool  Metropolis_test 
)

Definition at line 301 of file hmc_Leapfrog.cpp.

◆ set_parameters() [2/3]

void HMC_Leapfrog::set_parameters ( const double  Estep,
const int  Nmdc,
const int  Nprec,
const int  Metropolis_test 
)

Definition at line 292 of file hmc_Leapfrog.cpp.

◆ set_parameters() [3/3]

void HMC_Leapfrog::set_parameters ( const Parameters params)

Definition at line 228 of file hmc_Leapfrog.cpp.

◆ update()

double HMC_Leapfrog::update ( Field_G Uorg)

Definition at line 323 of file hmc_Leapfrog.cpp.

◆ update_P()

void HMC_Leapfrog::update_P ( const double  estep,
Field_G iP,
const Field_G U 
)

Definition at line 501 of file hmc_Leapfrog.cpp.

◆ update_U()

void HMC_Leapfrog::update_U ( const double  estep,
const Field_G iP,
Field_G U 
)

Definition at line 525 of file hmc_Leapfrog.cpp.

Member Data Documentation

◆ class_name

const std::string HMC_Leapfrog::class_name = "HMC_Leapfrog"
static

Definition at line 47 of file hmc_Leapfrog.h.

◆ m_action

std::vector<Action *> HMC_Leapfrog::m_action
private

Definition at line 58 of file hmc_Leapfrog.h.

◆ m_director

std::vector<Director *> HMC_Leapfrog::m_director
private

Definition at line 59 of file hmc_Leapfrog.h.

◆ m_Estep

double HMC_Leapfrog::m_Estep
private

Definition at line 53 of file hmc_Leapfrog.h.

◆ m_Langevin_P

Langevin_Momentum* HMC_Leapfrog::m_Langevin_P
private

Definition at line 55 of file hmc_Leapfrog.h.

◆ m_Metropolis_test

bool HMC_Leapfrog::m_Metropolis_test
private

Definition at line 52 of file hmc_Leapfrog.h.

◆ m_Nmdc

int HMC_Leapfrog::m_Nmdc
private

Definition at line 50 of file hmc_Leapfrog.h.

◆ m_Nprec

int HMC_Leapfrog::m_Nprec
private

Definition at line 51 of file hmc_Leapfrog.h.

◆ m_rand

RandomNumbers* HMC_Leapfrog::m_rand
private

Definition at line 60 of file hmc_Leapfrog.h.

◆ m_staple

Staple_lex* HMC_Leapfrog::m_staple
private

Definition at line 56 of file hmc_Leapfrog.h.

◆ m_vl

Bridge::VerboseLevel HMC_Leapfrog::m_vl
private

Definition at line 61 of file hmc_Leapfrog.h.


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