Skip to main content

Temperature

Trait Temperature 

Source
pub trait Temperature {
    // Required methods
    fn temperature(&self) -> &f64;
    fn temperature_mut(&mut self) -> &mut f64;
}
Expand description

Set the thermodynamic temperature of a system.

Macrostates with the Temperature trait set the temperature of the simulation. In hoomd-rs, temperature is given in units of $[\mathrm{energy}]$: $\mathrm{temperature} = kT$.

§Example

use hoomd_simulation::macrostate::Isothermal;

let macrostate = Isothermal { temperature: 1.2 };

Required Methods§

Source

fn temperature(&self) -> &f64

The system’s temperature $([\mathrm{energy}])$.

Source

fn temperature_mut(&mut self) -> &mut f64

The system’s temperature $([\mathrm{energy}])$.

Implementors§