[gmx-users] Energy conservation in NVE simulations

张正财 zhangzhengc at mail.iggcas.ac.cn
Wed Nov 4 14:56:50 CET 2015


Dear All,
       I am having difficulties getting gromacs to conserve energy . I searched the maillist, I found the same question asked 5 years ago, but there is no good answers.
       I want to simulate Methane-Propane-water system (box size 5*5*10 nm) in the  NVE ensemble. However, the total energy cannot be conservated, the attachment is my mdp file. Using the same mdp file, I can keep total energy constant during CH4-Water system. I have tested the timestep, It makes no strong influence on energy drift between 1 to 2 fs.  Could anyone give me some advice? 
/**********************************************************/
; RUN CONTROL PARAMETERS
integrator               = md
; Start time and timestep in ps
tinit                    = 0
dt                       = 0.002
nsteps                   = 100000
; For exact run continuation or redoing part of a run
init_step                = 0
; mode for center of mass motion removal
comm-mode                = Linear
; number of steps for center of mass motion removal
nstcomm                  = 1
; group(s) for center of mass motion removal
comm-grps                = 

; LANGEVIN DYNAMICS OPTIONS
; Temperature, friction coefficient (amu/ps) and random seed
bd-fric                  = 0
ld-seed                  = 24652

; ENERGY MINIMIZATION OPTIONS
; Force tolerance and initial step-size
emtol                    = 100
emstep                   = 0.001
; Max number of iterations in relax_shells
niter                    = 20
; Step size (1/ps^2) for minimization of flexible constraints
fcstep                   = 0
; Frequency of steepest descents steps when doing CG
nstcgsteep               = 1000
nbfgscorr                = 10

; OUTPUT CONTROL OPTIONS
; Output frequency for coords (x), velocities (v) and forces (f)
nstxout                  = 1000000
nstvout                  = 1000000
nstfout                  = 1000000
; Checkpointing helps you continue after crashes
nstcheckpoint            = 1000
; Output frequency for energies to log file and energy file
nstlog                   = 5000
nstcalcenergy            = 5
nstenergy                = 5000
; Output frequency and precision for xtc file
nstxtcout                = 10000
xtc-precision            = 10000
; This selects the subset of atoms for the xtc file. You can
; select multiple groups. By default all atoms will be written.
xtc-grps                 = 
; Selection of energy groups
energygrps               = 

; NEIGHBORSEARCHING PARAMETERS
; nblist update frequency
nstlist                  = 5
; ns algorithm (simple or grid)
ns_type                  = grid
; Periodic boundary conditions: xyz (default), no (vacuum)
; or full (infinite systems only)
pbc                      = xyz
; nblist cut-off        
rlist                    = 1.6
rlist_long               = 1.65
domain-decomposition     = no

; OPTIONS FOR ELECTROSTATICS AND VDW
; Method for doing electrostatics
coulombtype              = PME-Switch
rcoulomb-switch          = 1.2
rcoulomb                 = 1.4
; Dielectric constant (DC) for cut-off or DC of reaction field
epsilon-r                = 1
; Method for doing Van der Waals
vdw-type                 = Shift
; cut-off lengths        
rvdw-switch              = 1.2
rvdw                     = 1.3
; Apply long range dispersion corrections for Energy and Pressure
DispCorr                 = EnerPres
; Extension of the potential lookup tables beyond the cut-off
table-extension          = 1
; Spacing for the PME/PPPM FFT grid
fourierspacing           = 0.12
; FFT grid size, when a value is 0 fourierspacing will be used
fourier_nx               = 0
fourier_ny               = 0
fourier_nz               = 0
; EWALD/PME/PPPM parameters
pme_order                = 6
ewald_rtol               = 1e-05
ewald_geometry           = 3d
epsilon_surface          = 0
optimize_fft             = yes

; GENERALIZED BORN ELECTROSTATICS
; Algorithm for calculating Born radii
gb_algorithm             = Still
; Frequency of calculating the Born radii inside rlist
nstgbradii               = 1
; Cutoff for Born radii calculation; the contribution from atoms
; between rlist and rgbradii is updated every nstlist steps
rgbradii                 = 2
; Salt concentration in M for Generalized Born models
gb_saltconc              = 0

; IMPLICIT SOLVENT (for use with Generalized Born electrostatics)
implicit_solvent         = No

; OPTIONS FOR WEAK COUPLING ALGORITHMS
; Temperature coupling  
Tcoupl                   = NO                   ;  nose-hoover
Pcoupl                   = NO                   ;   Parrinello-Rahman


; SIMULATED ANNEALING  
; Type of annealing for each temperature group (no/single/periodic)
annealing                = no
; Number of time points to use for specifying annealing in each group
annealing_npoints        = 
; List of times at the annealing points for each group
annealing_time           = 
; Temp. at each annealing point, for each group.
annealing_temp           = 

; GENERATE VELOCITIES FOR STARTUP RUN
gen_vel                  = no
gen_temp                 = 300
gen_seed                 = 24652

; OPTIONS FOR BONDS    
constraints              = all-angles
; Type of constraint algorithm
constraint-algorithm     = shake
; Do not constrain the start configuration
unconstrained-start      = no
; Use successive overrelaxation to reduce the number of shake iterations
Shake-SOR                = no
; Relative tolerance of shake
shake-tol                = 1e-04
; Highest order in the expansion of the constraint coupling matrix
lincs-order              = 4
; Number of iterations in the final step of LINCS. 1 is fine for
; normal simulations, but use 2 to conserve energy in NVE runs.
; For energy minimization with constraints it should be 4 to 8.
lincs-iter               = 1
; Lincs will write a warning to the stderr if in one step a bond
; rotates over more degrees than
lincs-warnangle          = 30
; Convert harmonic bonds to morse potentials
morse                    = no

; ENERGY GROUP EXCLUSIONS
; Pairs of energy groups for which all non-bonded interactions are excluded
energygrp_excl           = 

; NMR refinement stuff 
; Distance restraints type: No, Simple or Ensemble
disre                    = No
; Force weighting of pairs in one distance restraint: Conservative or Equal
disre-weighting          = Conservative
; Use sqrt of the time averaged times the instantaneous violation
disre-mixed              = no
disre-fc                 = 1000
disre-tau                = 0
; Output frequency for pair distances to energy file
nstdisreout              = 100
; Orientation restraints: No or Yes
orire                    = no
; Orientation restraints force constant and tau for time averaging
orire-fc                 = 0
orire-tau                = 0
orire-fitgrp             = 
; Output frequency for trace(SD) to energy file
nstorireout              = 100
; Dihedral angle restraints: No, Simple or Ensemble
dihre                    = No
dihre-fc                 = 1000
dihre-tau                = 0
; Output frequency for dihedral values to energy file
nstdihreout              = 100
/**********************************************************/
Sincerely yours,
Zhengcai,




More information about the gromacs.org_gmx-users mailing list