oILAB
Loading...
Searching...
No Matches
Ensemble.h
Go to the documentation of this file.
1
//
2
// Created by Nikhil Chandra Admal on 8/5/24.
3
//
4
5
#ifndef OILAB_ENSEMBLE_H
6
#define OILAB_ENSEMBLE_H
7
8
#include <iostream>
9
10
namespace
gbLAB
{
11
template
<
typename
StateType,
typename
SystemType,
typename
Derived>
12
class
Ensemble
{
13
public
:
14
const
Derived &
derived
;
15
16
Ensemble
() :
derived
(static_cast<const Derived &>(*this)) {}
17
18
SystemType
constructSystem
(
const
StateType &state)
const
19
{
20
return
derived
.constructSystem(state);
21
}
22
23
std::pair<StateType, SystemType>
sampleNewState
(
const
StateType ¤tState)
24
{
25
return
derived
.sampleNewState(currentState);
26
}
27
};
28
}
29
30
#endif
//OILAB_ENSEMBLE_H
gbLAB::Ensemble
Definition
Ensemble.h:12
gbLAB::Ensemble::derived
const Derived & derived
Definition
Ensemble.h:14
gbLAB::Ensemble::constructSystem
SystemType constructSystem(const StateType &state) const
Definition
Ensemble.h:18
gbLAB::Ensemble::Ensemble
Ensemble()
Definition
Ensemble.h:16
gbLAB::Ensemble::sampleNewState
std::pair< StateType, SystemType > sampleNewState(const StateType ¤tState)
Definition
Ensemble.h:23
gbLAB
Definition
BiCrystal.cpp:13
include
MonteCarlo
Ensemble.h
Generated on Wed Aug 6 2025 23:06:44 for oILAB by
1.9.8