|
RASPA3 3.0.13
A molecular simulation code for computing adsorption and diffusion in nanoporous materials
|
Represents a Nose-Hoover thermostat for molecular dynamics simulations. More...

Public Member Functions | |
| Thermostat () | |
| Default constructor for the Thermostat struct. | |
| Thermostat (double temperature, std::size_t thermostatChainLength, std::size_t numberOfYoshidaSuzukiSteps, double deltaT, std::size_t translationalDegreesOfFreedom, std::size_t rotationalDgreesOfFreedom) | |
| Constructs a Thermostat with specified parameters. | |
| void | initialize (RandomNumber &random) |
| Initializes the thermostat with random velocities. | |
| std::pair< double, double > | NoseHooverNVT (double UKineticTranslation, double UKineticRotation) |
| Performs a Nose-Hoover NVT integration step. | |
| double | getEnergy () |
| Computes the total energy of the thermostat. | |
Friends | |
| Archive< std::ofstream > & | operator<< (Archive< std::ofstream > &archive, const Thermostat &s) |
| Archive< std::ifstream > & | operator>> (Archive< std::ifstream > &archive, Thermostat &s) |
Represents a Nose-Hoover thermostat for molecular dynamics simulations.
The Thermostat struct encapsulates the properties and methods required to implement a Nose-Hoover thermostat for temperature control in molecular dynamics simulations. It includes parameters for temperature, thermostat chain length, Yoshida-Suzuki steps, and degrees of freedom. The struct provides methods to initialize the thermostat, perform Nose-Hoover NVT integration steps, and compute the thermostat's energy contribution.
|
inline |
Default constructor for the Thermostat struct.
Initializes a Thermostat object with default values.
| Thermostat::Thermostat | ( | double | temperature, |
| std::size_t | thermostatChainLength, | ||
| std::size_t | numberOfYoshidaSuzukiSteps, | ||
| double | deltaT, | ||
| std::size_t | translationalDegreesOfFreedom, | ||
| std::size_t | rotationalDgreesOfFreedom | ||
| ) |
Constructs a Thermostat with specified parameters.
Initializes a Thermostat with the provided temperature, thermostat chain length, number of Yoshida-Suzuki steps, time step deltaT, and degrees of freedom for translation and rotation.
| temperature | The target temperature for the thermostat. |
| thermostatChainLength | The length of the thermostat chain. |
| numberOfYoshidaSuzukiSteps | The number of Yoshida-Suzuki steps for integration. |
| deltaT | The simulation time step. |
| translationalDegreesOfFreedom | The number of translational degrees of freedom. |
| rotationalDgreesOfFreedom | The number of rotational degrees of freedom. |
| double Thermostat::getEnergy | ( | ) |
Computes the total energy of the thermostat.
Calculates the energy contribution from both translational and rotational thermostat chains.
| void Thermostat::initialize | ( | RandomNumber & | random | ) |
Initializes the thermostat with random velocities.
Sets up the thermostat chain by initializing velocities using a random number generator.
| random | A reference to a RandomNumber generator. |
| std::pair< double, double > Thermostat::NoseHooverNVT | ( | double | UKineticTranslation, |
| double | UKineticRotation | ||
| ) |
Performs a Nose-Hoover NVT integration step.
Updates the thermostat variables and computes scaling factors for translational and rotational degrees of freedom based on the provided kinetic energies.
| UKineticTranslation | The kinetic energy of translation. |
| UKineticRotation | The kinetic energy of rotation. |