CoMD
A Mini-app for Co-Design of Classical Molecular Dynamics.
All
Data Structures
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
constants.h
Go to the documentation of this file.
1
/// \file
2
/// Contains constants for unit conversions.
3
///
4
/// The units for this code are:
5
/// - Time in femtoseconds (fs)
6
/// - Length in Angstroms (Angs)
7
/// - Energy in electron Volts (eV)
8
/// - Mass read in as Atomic Mass Units (amu) and then converted for
9
/// consistency (energy*time^2/length^2)
10
/// Values are taken from NIST, http://physics.nist.gov/cuu/Constants/
11
12
#ifndef _CONSTANTS_H_
13
#define _CONSTANTS_H_
14
15
/// 1 amu in kilograms
16
#define amuInKilograms 1.660538921e-27
17
18
/// 1 fs in seconds
19
#define fsInSeconds 1.0e-15
20
21
/// 1 Ang in meters
22
#define AngsInMeters 1.0e-10
23
24
/// 1 eV in Joules
25
#define eVInJoules 1.602176565e-19
26
27
/// Internal mass units are eV * fs^2 / Ang^2
28
static
const
double
amuToInternalMass
=
29
amuInKilograms
*
AngsInMeters
*
AngsInMeters
30
/ (
fsInSeconds
*
fsInSeconds
*
eVInJoules
);
31
32
/// Boltmann constant in eV's
33
static
const
double
kB_eV
= 8.6173324e-5;
// eV/K
34
35
/// Hartrees to eVs
36
static
const
double
hartreeToEv
= 27.21138505;
37
38
/// Bohrs to Angstroms
39
static
const
double
bohrToAngs
= 0.52917721092;
40
41
#endif
constants.h
Generated on Wed Jun 5 2013 11:08:31 for CoMD by
1.8.3.1