MSpin-JCoupling  2.1
thermo.h
1 /***************************************************************************
2  thermo.h - description
3  -------------------
4  author : Armando Navarro-Vazquez
5  email : armando.deus@gmail.com
6  ***************************************************************************/
7 
8 /***************************************************************************
9  * *
10  * This program is free software; you can redistribute it and/or modify *
11  * it under the terms of the GNU General Public License as published by *
12  * the Free Software Foundation; either version 2 of the License, or *
13  * (at your option) any later version. *
14  * *
15  ***************************************************************************/
16 
17 #ifndef MAGNES_THERMO_H
18 #define MAGNES_THERMO_H
19 
20 #include <vector>
21 #include "coreexport.h"
22 
24 namespace magnes {
25 
26 class Molecule;
27 
28 MAGNES_CORE_API enum ensemble { NVE=0, NVT };
29 
34 class MAGNES_CORE_API Thermostat {
35 public:
36  Thermostat();
37  virtual ~Thermostat ();
39  virtual void SetTemperature(double t) { m_temperature=t; }
41  double Temperature() const { return m_temperature; }
42  // void SetMolecule(Molecule* mol) { m_molecule=mol; }
44  virtual void SetEnsemble(ensemble e) { m_ensemble=e; }
46  ensemble Ensemble() const { return m_ensemble; }
48  virtual void SetPopulations(Molecule& molecule);
50  virtual void SetPopulations(Molecule& molecule, const std::vector<double>& pops);
51 private: //private methods
53  void SetBoltzmannPopulations(Molecule& molecule) const;
54 private:
55  ensemble m_ensemble;
56  double m_temperature;
57 };
58 
59 }
60 
61 #endif //MAGNES_THERMO_H
ensemble Ensemble() const
Definition: thermo.h:46
the global magnes namespace
Definition: ccchequation.h:38
virtual void SetEnsemble(ensemble e)
Definition: thermo.h:44
virtual void SetTemperature(double t)
Definition: thermo.h:39
double Temperature() const
Definition: thermo.h:41
A class to manage thermodynamics.
Definition: thermo.h:34
Definition: molecule.h:44