667576a73d0575387c849c0e80df5256ffd73b75
[alexxy/gromacs.git] / docs / user-guide / mdp-options.rst
1 .. README
2    See the "run control" section for a working example of the
3    syntax to use when making .mdp entries, with and without detailed
4    documentation for values those entries might take. Everything can
5    be cross-referenced, see the examples there.
6
7 .. todo:: Make more cross-references.
8
9 Molecular dynamics parameters (.mdp options)
10 ============================================
11
12 .. _mdp-general:
13
14 General information
15 -------------------
16
17 Default values are given in parentheses, or listed first among
18 choices. The first option in the list is always the default
19 option. Units are given in square brackets. The difference between a
20 dash and an underscore is ignored.
21
22 A :ref:`sample mdp file <mdp>` is available. This should be
23 appropriate to start a normal simulation. Edit it to suit your
24 specific needs and desires.
25
26
27 Preprocessing
28 ^^^^^^^^^^^^^
29
30 .. mdp:: include
31
32    directories to include in your topology. Format:
33    ``-I/home/john/mylib -I../otherlib``
34
35 .. mdp:: define
36
37    defines to pass to the preprocessor, default is no defines. You can
38    use any defines to control options in your customized topology
39    files. Options that act on existing :ref:`top` file mechanisms
40    include
41
42       ``-DFLEXIBLE`` will use flexible water instead of rigid water
43       into your topology, this can be useful for normal mode analysis.
44
45       ``-DPOSRES`` will trigger the inclusion of ``posre.itp`` into
46       your topology, used for implementing position restraints.
47
48
49 Run control
50 ^^^^^^^^^^^
51
52 .. mdp:: integrator
53
54    (Despite the name, this list includes algorithms that are not
55    actually integrators over time. :mdp-value:`integrator=steep` and
56    all entries following it are in this category)
57
58    .. mdp-value:: md
59
60       A leap-frog algorithm for integrating Newton's equations of motion.
61
62    .. mdp-value:: md-vv
63
64       A velocity Verlet algorithm for integrating Newton's equations
65       of motion.  For constant NVE simulations started from
66       corresponding points in the same trajectory, the trajectories
67       are analytically, but not binary, identical to the
68       :mdp-value:`integrator=md` leap-frog integrator. The kinetic
69       energy, which is determined from the whole step velocities and
70       is therefore slightly too high. The advantage of this integrator
71       is more accurate, reversible Nose-Hoover and Parrinello-Rahman
72       coupling integration based on Trotter expansion, as well as
73       (slightly too small) full step velocity output. This all comes
74       at the cost off extra computation, especially with constraints
75       and extra communication in parallel. Note that for nearly all
76       production simulations the :mdp-value:`integrator=md` integrator
77       is accurate enough.
78
79    .. mdp-value:: md-vv-avek
80
81       A velocity Verlet algorithm identical to
82       :mdp-value:`integrator=md-vv`, except that the kinetic energy is
83       determined as the average of the two half step kinetic energies
84       as in the :mdp-value:`integrator=md` integrator, and this thus
85       more accurate.  With Nose-Hoover and/or Parrinello-Rahman
86       coupling this comes with a slight increase in computational
87       cost.
88
89    .. mdp-value:: sd
90
91       An accurate and efficient leap-frog stochastic dynamics
92       integrator. With constraints, coordinates needs to be
93       constrained twice per integration step. Depending on the
94       computational cost of the force calculation, this can take a
95       significant part of the simulation time. The temperature for one
96       or more groups of atoms (:mdp:`tc-grps`) is set with
97       :mdp:`ref-t`, the inverse friction constant for each group is
98       set with :mdp:`tau-t`.  The parameters :mdp:`tcoupl` and :mdp:`nsttcouple`
99       are ignored. The random generator is initialized with
100       :mdp:`ld-seed`. When used as a thermostat, an appropriate value
101       for :mdp:`tau-t` is 2 ps, since this results in a friction that
102       is lower than the internal friction of water, while it is high
103       enough to remove excess heat NOTE: temperature deviations decay
104       twice as fast as with a Berendsen thermostat with the same
105       :mdp:`tau-t`.
106
107    .. mdp-value:: bd
108
109       An Euler integrator for Brownian or position Langevin dynamics,
110       the velocity is the force divided by a friction coefficient
111       (:mdp:`bd-fric`) plus random thermal noise (:mdp:`ref-t`). When
112       :mdp:`bd-fric` is 0, the friction coefficient for each particle
113       is calculated as mass/ :mdp:`tau-t`, as for the integrator
114       :mdp-value:`integrator=sd`. The random generator is initialized
115       with :mdp:`ld-seed`.
116
117    .. mdp-value:: steep
118
119       A steepest descent algorithm for energy minimization. The
120       maximum step size is :mdp:`emstep`, the tolerance is
121       :mdp:`emtol`.
122
123    .. mdp-value:: cg
124
125       A conjugate gradient algorithm for energy minimization, the
126       tolerance is :mdp:`emtol`. CG is more efficient when a steepest
127       descent step is done every once in a while, this is determined
128       by :mdp:`nstcgsteep`. For a minimization prior to a normal mode
129       analysis, which requires a very high accuracy, |Gromacs| should be
130       compiled in double precision.
131
132    .. mdp-value:: l-bfgs
133
134       A quasi-Newtonian algorithm for energy minimization according to
135       the low-memory Broyden-Fletcher-Goldfarb-Shanno approach. In
136       practice this seems to converge faster than Conjugate Gradients,
137       but due to the correction steps necessary it is not (yet)
138       parallelized.
139
140    .. mdp-value:: nm
141
142       Normal mode analysis is performed on the structure in the :ref:`tpr`
143       file.  |Gromacs| should be compiled in double precision.
144
145    .. mdp-value:: tpi
146
147       Test particle insertion. The last molecule in the topology is
148       the test particle. A trajectory must be provided to ``mdrun
149       -rerun``. This trajectory should not contain the molecule to be
150       inserted. Insertions are performed :mdp:`nsteps` times in each
151       frame at random locations and with random orientiations of the
152       molecule. When :mdp:`nstlist` is larger than one,
153       :mdp:`nstlist` insertions are performed in a sphere with radius
154       :mdp:`rtpi` around a the same random location using the same
155       pair list. Since pair list construction is expensive,
156       one can perform several extra insertions with the same list
157       almost for free. The random seed is set with
158       :mdp:`ld-seed`. The temperature for the Boltzmann weighting is
159       set with :mdp:`ref-t`, this should match the temperature of the
160       simulation of the original trajectory. Dispersion correction is
161       implemented correctly for TPI. All relevant quantities are
162       written to the file specified with ``mdrun -tpi``. The
163       distribution of insertion energies is written to the file
164       specified with ``mdrun -tpid``. No trajectory or energy file is
165       written. Parallel TPI gives identical results to single-node
166       TPI. For charged molecules, using PME with a fine grid is most
167       accurate and also efficient, since the potential in the system
168       only needs to be calculated once per frame.
169
170    .. mdp-value:: tpic
171
172       Test particle insertion into a predefined cavity location. The
173       procedure is the same as for :mdp-value:`integrator=tpi`, except
174       that one coordinate extra is read from the trajectory, which is
175       used as the insertion location. The molecule to be inserted
176       should be centered at 0,0,0. |Gromacs| does not do this for you,
177       since for different situations a different way of centering
178       might be optimal. Also :mdp:`rtpi` sets the radius for the
179       sphere around this location. Neighbor searching is done only
180       once per frame, :mdp:`nstlist` is not used. Parallel
181       :mdp-value:`integrator=tpic` gives identical results to
182       single-rank :mdp-value:`integrator=tpic`.
183
184    .. mdp-value:: mimic
185
186       Enable MiMiC QM/MM coupling to run hybrid molecular dynamics.
187       Keey in mind that its required to launch CPMD compiled with MiMiC as well.
188       In this mode all options regarding integration (T-coupling, P-coupling,
189       timestep and number of steps) are ignored as CPMD will do the integration
190       instead. Options related to forces computation (cutoffs, PME parameters,
191       etc.) are working as usual. Atom selection to define QM atoms is read
192       from :mdp:`QMMM-grps`
193
194 .. mdp:: tinit
195
196         (0) [ps]
197         starting time for your run (only makes sense for time-based
198         integrators)
199
200 .. mdp:: dt
201
202         (0.001) [ps]
203         time step for integration (only makes sense for time-based
204         integrators)
205
206 .. mdp:: nsteps
207
208         (0)
209         maximum number of steps to integrate or minimize, -1 is no
210         maximum
211
212 .. mdp:: init-step
213
214         (0)
215         The starting step. The time at step i in a run is
216         calculated as: t = :mdp:`tinit` + :mdp:`dt` *
217         (:mdp:`init-step` + i). The free-energy lambda is calculated
218         as: lambda = :mdp:`init-lambda` + :mdp:`delta-lambda` *
219         (:mdp:`init-step` + i). Also non-equilibrium MD parameters can
220         depend on the step number. Thus for exact restarts or redoing
221         part of a run it might be necessary to set :mdp:`init-step` to
222         the step number of the restart frame. :ref:`gmx convert-tpr`
223         does this automatically.
224
225 .. mdp:: simulation-part
226
227          (0)
228          A simulation can consist of multiple parts, each of which has
229          a part number. This option specifies what that number will
230          be, which helps keep track of parts that are logically the
231          same simulation. This option is generally useful to set only
232          when coping with a crashed simulation where files were lost.
233
234 .. mdp:: mts
235
236    .. mdp-value:: no
237
238       Evaluate all forces at every integration step.
239
240    .. mdp-value:: yes
241
242       Use a multiple timing-stepping integrator to evaluate some forces, as specified
243       by :mdp:`mts-level2-forces` every :mdp:`mts-level2-factor` integration
244       steps. All other forces are evaluated at every step. MTS is currently
245       only supported with :mdp-value:`integrator=md`.
246
247 .. mdp:: mts-levels
248
249         (2)
250         The number of levels for the multiple time-stepping scheme.
251         Currently only 2 is supported.
252
253 .. mdp:: mts-level2-forces
254
255    (longrange-nonbonded)
256    A list of one or more force groups that will be evaluated only every
257    :mdp:`mts-level2-factor` steps. Supported entries are:
258    ``longrange-nonbonded``, ``nonbonded``, ``pair``, ``dihedral``, ``angle``,
259    ``pull`` and ``awh``. With ``pair`` the listed pair forces (such as 1-4)
260    are selected. With ``dihedral`` all dihedrals are selected, including cmap.
261    All other forces, including all restraints, are evaluated and
262    integrated every step. When PME or Ewald is used for electrostatics
263    and/or LJ interactions, ``longrange-nonbonded`` can not be omitted here.
264
265 .. mdp:: mts-level2-factor
266
267       (2) [steps]
268       Interval for computing the forces in level 2 of the multiple time-stepping
269       scheme
270
271 .. mdp:: comm-mode
272
273    .. mdp-value:: Linear
274
275       Remove center of mass translational velocity
276
277    .. mdp-value:: Angular
278
279       Remove center of mass translational and rotational velocity
280
281    .. mdp-value:: Linear-acceleration-correction
282
283       Remove center of mass translational velocity. Correct the center of
284       mass position assuming linear acceleration over :mdp:`nstcomm` steps.
285       This is useful for cases where an acceleration is expected on the
286       center of mass which is nearly constant over :mdp:`nstcomm` steps.
287       This can occur for example when pulling on a group using an absolute
288       reference.
289
290    .. mdp-value:: None
291
292       No restriction on the center of mass motion
293
294 .. mdp:: nstcomm
295
296    (100) [steps]
297    frequency for center of mass motion removal
298
299 .. mdp:: comm-grps
300
301    group(s) for center of mass motion removal, default is the whole
302    system
303
304
305 Langevin dynamics
306 ^^^^^^^^^^^^^^^^^
307
308 .. mdp:: bd-fric
309
310    (0) [amu ps\ :sup:`-1`]
311    Brownian dynamics friction coefficient. When :mdp:`bd-fric` is 0,
312    the friction coefficient for each particle is calculated as mass/
313    :mdp:`tau-t`.
314
315 .. mdp:: ld-seed
316
317    (-1) [integer]
318    used to initialize random generator for thermal noise for
319    stochastic and Brownian dynamics. When :mdp:`ld-seed` is set to -1,
320    a pseudo random seed is used. When running BD or SD on multiple
321    processors, each processor uses a seed equal to :mdp:`ld-seed` plus
322    the processor number.
323
324
325 Energy minimization
326 ^^^^^^^^^^^^^^^^^^^
327
328 .. mdp:: emtol
329
330    (10.0) [kJ mol\ :sup:`-1` nm\ :sup:`-1`]
331    the minimization is converged when the maximum force is smaller
332    than this value
333
334 .. mdp:: emstep
335
336    (0.01) [nm]
337    initial step-size
338
339 .. mdp:: nstcgsteep
340
341    (1000) [steps]
342    frequency of performing 1 steepest descent step while doing
343    conjugate gradient energy minimization.
344
345 .. mdp:: nbfgscorr
346
347    (10)
348    Number of correction steps to use for L-BFGS minimization. A higher
349    number is (at least theoretically) more accurate, but slower.
350
351
352 Shell Molecular Dynamics
353 ^^^^^^^^^^^^^^^^^^^^^^^^
354
355 When shells or flexible constraints are present in the system the
356 positions of the shells and the lengths of the flexible constraints
357 are optimized at every time step until either the RMS force on the
358 shells and constraints is less than :mdp:`emtol`, or a maximum number
359 of iterations :mdp:`niter` has been reached. Minimization is converged
360 when the maximum force is smaller than :mdp:`emtol`. For shell MD this
361 value should be 1.0 at most.
362
363 .. mdp:: niter
364
365    (20)
366    maximum number of iterations for optimizing the shell positions and
367    the flexible constraints.
368
369 .. mdp:: fcstep
370
371    (0) [ps\ :sup:`2`]
372    the step size for optimizing the flexible constraints. Should be
373    chosen as mu/(d2V/dq2) where mu is the reduced mass of two
374    particles in a flexible constraint and d2V/dq2 is the second
375    derivative of the potential in the constraint direction. Hopefully
376    this number does not differ too much between the flexible
377    constraints, as the number of iterations and thus the runtime is
378    very sensitive to fcstep. Try several values!
379
380
381 Test particle insertion
382 ^^^^^^^^^^^^^^^^^^^^^^^
383
384 .. mdp:: rtpi
385
386    (0.05) [nm]
387    the test particle insertion radius, see integrators
388    :mdp-value:`integrator=tpi` and :mdp-value:`integrator=tpic`
389
390
391 Output control
392 ^^^^^^^^^^^^^^
393
394 .. mdp:: nstxout
395
396    (0) [steps]
397    number of steps that elapse between writing coordinates to the output
398    trajectory file (:ref:`trr`), the last coordinates are always written
399    unless 0, which means coordinates are not written into the trajectory
400    file.
401
402 .. mdp:: nstvout
403
404    (0) [steps]
405    number of steps that elapse between writing velocities to the output
406    trajectory file (:ref:`trr`), the last velocities are always written
407    unless 0, which means velocities are not written into the trajectory
408    file.
409
410 .. mdp:: nstfout
411
412    (0) [steps]
413    number of steps that elapse between writing forces to the output
414    trajectory file (:ref:`trr`), the last forces are always written,
415    unless 0, which means forces are not written into the trajectory
416    file.
417
418 .. mdp:: nstlog
419
420    (1000) [steps]
421    number of steps that elapse between writing energies to the log
422    file, the last energies are always written.
423
424 .. mdp:: nstcalcenergy
425
426    (100)
427    number of steps that elapse between calculating the energies, 0 is
428    never. This option is only relevant with dynamics. This option affects the
429    performance in parallel simulations, because calculating energies
430    requires global communication between all processes which can
431    become a bottleneck at high parallelization.
432
433 .. mdp:: nstenergy
434
435    (1000) [steps]
436    number of steps that elapse between writing energies to energy file,
437    the last energies are always written, should be a multiple of
438    :mdp:`nstcalcenergy`. Note that the exact sums and fluctuations
439    over all MD steps modulo :mdp:`nstcalcenergy` are stored in the
440    energy file, so :ref:`gmx energy` can report exact energy averages
441    and fluctuations also when :mdp:`nstenergy` > 1
442
443 .. mdp:: nstxout-compressed
444
445    (0) [steps]
446    number of steps that elapse between writing position coordinates
447    using lossy compression (:ref:`xtc` file), 0 for not writing
448    compressed coordinates output.
449
450 .. mdp:: compressed-x-precision
451
452    (1000) [real]
453    precision with which to write to the compressed trajectory file
454
455 .. mdp:: compressed-x-grps
456
457    group(s) to write to the compressed trajectory file, by default the
458    whole system is written (if :mdp:`nstxout-compressed` > 0)
459
460 .. mdp:: energygrps
461
462    group(s) for which to write to write short-ranged non-bonded
463    potential energies to the energy file (not supported on GPUs)
464
465
466 Neighbor searching
467 ^^^^^^^^^^^^^^^^^^
468
469 .. mdp:: cutoff-scheme
470
471    .. mdp-value:: Verlet
472
473       Generate a pair list with buffering. The buffer size is
474       automatically set based on :mdp:`verlet-buffer-tolerance`,
475       unless this is set to -1, in which case :mdp:`rlist` will be
476       used.
477
478    .. mdp-value:: group
479
480       Generate a pair list for groups of atoms, corresponding
481       to the charge groups in the topology. This option is no longer
482       supported.
483
484 .. mdp:: nstlist
485
486    (10) [steps]
487
488    .. mdp-value:: >0
489
490       Frequency to update the neighbor list. When dynamics and
491       :mdp:`verlet-buffer-tolerance` set, :mdp:`nstlist` is actually
492       a minimum value and :ref:`gmx mdrun` might increase it, unless
493       it is set to 1. With parallel simulations and/or non-bonded
494       force calculation on the GPU, a value of 20 or 40 often gives
495       the best performance. With energy minimization this parameter
496       is not used as the pair list is updated when at least one atom
497       has moved by more than half the pair list buffer size.
498
499    .. mdp-value:: 0
500
501       The neighbor list is only constructed once and never
502       updated. This is mainly useful for vacuum simulations in which
503       all particles see each other. But vacuum simulations are
504       (temporarily) not supported.
505
506    .. mdp-value:: <0
507
508       Unused.
509
510 .. mdp:: pbc
511
512    .. mdp-value:: xyz
513
514       Use periodic boundary conditions in all directions.
515
516    .. mdp-value:: no
517
518       Use no periodic boundary conditions, ignore the box. To simulate
519       without cut-offs, set all cut-offs and :mdp:`nstlist` to 0. For
520       best performance without cut-offs on a single MPI rank, set
521       :mdp:`nstlist` to zero and :mdp-value:`ns-type=simple`.
522
523    .. mdp-value:: xy
524
525       Use periodic boundary conditions in x and y directions
526       only. This works only with :mdp-value:`ns-type=grid` and can be used
527       in combination with walls_. Without walls or with only one wall
528       the system size is infinite in the z direction. Therefore
529       pressure coupling or Ewald summation methods can not be
530       used. These disadvantages do not apply when two walls are used.
531
532 .. mdp:: periodic-molecules
533
534    .. mdp-value:: no
535
536       molecules are finite, fast molecular PBC can be used
537
538    .. mdp-value:: yes
539
540       for systems with molecules that couple to themselves through the
541       periodic boundary conditions, this requires a slower PBC
542       algorithm and molecules are not made whole in the output
543
544 .. mdp:: verlet-buffer-tolerance
545
546    (0.005) [kJ mol\ :sup:`-1` ps\ :sup:`-1`]
547
548    Used when performing a simulation with dynamics. This sets
549    the maximum allowed error for pair interactions per particle caused
550    by the Verlet buffer, which indirectly sets :mdp:`rlist`. As both
551    :mdp:`nstlist` and the Verlet buffer size are fixed (for
552    performance reasons), particle pairs not in the pair list can
553    occasionally get within the cut-off distance during
554    :mdp:`nstlist` -1 steps. This causes very small jumps in the
555    energy. In a constant-temperature ensemble, these very small energy
556    jumps can be estimated for a given cut-off and :mdp:`rlist`. The
557    estimate assumes a homogeneous particle distribution, hence the
558    errors might be slightly underestimated for multi-phase
559    systems. (See the `reference manual`_ for details). For longer
560    pair-list life-time (:mdp:`nstlist` -1) * :mdp:`dt` the buffer is
561    overestimated, because the interactions between particles are
562    ignored. Combined with cancellation of errors, the actual drift of
563    the total energy is usually one to two orders of magnitude
564    smaller. Note that the generated buffer size takes into account
565    that the |Gromacs| pair-list setup leads to a reduction in the
566    drift by a factor 10, compared to a simple particle-pair based
567    list. Without dynamics (energy minimization etc.), the buffer is 5%
568    of the cut-off. For NVE simulations the initial temperature is
569    used, unless this is zero, in which case a buffer of 10% is
570    used. For NVE simulations the tolerance usually needs to be lowered
571    to achieve proper energy conservation on the nanosecond time
572    scale. To override the automated buffer setting, use
573    :mdp:`verlet-buffer-tolerance` =-1 and set :mdp:`rlist` manually.
574
575 .. mdp:: rlist
576
577    (1) [nm]
578    Cut-off distance for the short-range neighbor list. With dynamics,
579    this is by default set by the :mdp:`verlet-buffer-tolerance` option
580    and the value of :mdp:`rlist` is ignored. Without dynamics, this
581    is by default set to the maximum cut-off plus 5% buffer, except
582    for test particle insertion, where the buffer is managed exactly
583    and automatically. For NVE simulations, where the automated
584    setting is not possible, the advised procedure is to run :ref:`gmx grompp`
585    with an NVT setup with the expected temperature and copy the resulting
586    value of :mdp:`rlist` to the NVE setup.
587
588
589 Electrostatics
590 ^^^^^^^^^^^^^^
591
592 .. mdp:: coulombtype
593
594    .. mdp-value:: Cut-off
595
596       Plain cut-off with pair list radius :mdp:`rlist` and
597       Coulomb cut-off :mdp:`rcoulomb`, where :mdp:`rlist` >=
598       :mdp:`rcoulomb`.
599
600    .. mdp-value:: Ewald
601
602       Classical Ewald sum electrostatics. The real-space cut-off
603       :mdp:`rcoulomb` should be equal to :mdp:`rlist`. Use *e.g.*
604       :mdp:`rlist` =0.9, :mdp:`rcoulomb` =0.9. The highest magnitude
605       of wave vectors used in reciprocal space is controlled by
606       :mdp:`fourierspacing`. The relative accuracy of
607       direct/reciprocal space is controlled by :mdp:`ewald-rtol`.
608
609       NOTE: Ewald scales as O(N\ :sup:`3/2`) and is thus extremely slow for
610       large systems. It is included mainly for reference - in most
611       cases PME will perform much better.
612
613    .. mdp-value:: PME
614
615       Fast smooth Particle-Mesh Ewald (SPME) electrostatics. Direct
616       space is similar to the Ewald sum, while the reciprocal part is
617       performed with FFTs. Grid dimensions are controlled with
618       :mdp:`fourierspacing` and the interpolation order with
619       :mdp:`pme-order`. With a grid spacing of 0.1 nm and cubic
620       interpolation the electrostatic forces have an accuracy of
621       2-3*10\ :sup:`-4`. Since the error from the vdw-cutoff is larger than
622       this you might try 0.15 nm. When running in parallel the
623       interpolation parallelizes better than the FFT, so try
624       decreasing grid dimensions while increasing interpolation.
625
626    .. mdp-value:: P3M-AD
627
628       Particle-Particle Particle-Mesh algorithm with analytical
629       derivative for for long range electrostatic interactions. The
630       method and code is identical to SPME, except that the influence
631       function is optimized for the grid. This gives a slight increase
632       in accuracy.
633
634    .. mdp-value:: Reaction-Field
635
636       Reaction field electrostatics with Coulomb cut-off
637       :mdp:`rcoulomb`, where :mdp:`rlist` >= :mdp:`rvdw`. The
638       dielectric constant beyond the cut-off is
639       :mdp:`epsilon-rf`. The dielectric constant can be set to
640       infinity by setting :mdp:`epsilon-rf` =0.
641
642    .. mdp-value:: User
643
644       Currently unsupported.
645       :ref:`gmx mdrun` will now expect to find a file ``table.xvg``
646       with user-defined potential functions for repulsion, dispersion
647       and Coulomb. When pair interactions are present, :ref:`gmx
648       mdrun` also expects to find a file ``tablep.xvg`` for the pair
649       interactions. When the same interactions should be used for
650       non-bonded and pair interactions the user can specify the same
651       file name for both table files. These files should contain 7
652       columns: the ``x`` value, ``f(x)``, ``-f'(x)``, ``g(x)``,
653       ``-g'(x)``, ``h(x)``, ``-h'(x)``, where ``f(x)`` is the Coulomb
654       function, ``g(x)`` the dispersion function and ``h(x)`` the
655       repulsion function. When :mdp:`vdwtype` is not set to User the
656       values for ``g``, ``-g'``, ``h`` and ``-h'`` are ignored. For
657       the non-bonded interactions ``x`` values should run from 0 to
658       the largest cut-off distance + :mdp:`table-extension` and
659       should be uniformly spaced. For the pair interactions the table
660       length in the file will be used. The optimal spacing, which is
661       used for non-user tables, is ``0.002 nm`` when you run in mixed
662       precision or ``0.0005 nm`` when you run in double precision. The
663       function value at ``x=0`` is not important. More information is
664       in the printed manual.
665
666    .. mdp-value:: PME-Switch
667
668       Currently unsupported.
669       A combination of PME and a switch function for the direct-space
670       part (see above). :mdp:`rcoulomb` is allowed to be smaller than
671       :mdp:`rlist`.
672
673    .. mdp-value:: PME-User
674
675       Currently unsupported.
676       A combination of PME and user tables (see
677       above). :mdp:`rcoulomb` is allowed to be smaller than
678       :mdp:`rlist`. The PME mesh contribution is subtracted from the
679       user table by :ref:`gmx mdrun`. Because of this subtraction the
680       user tables should contain about 10 decimal places.
681
682    .. mdp-value:: PME-User-Switch
683
684       Currently unsupported.
685       A combination of PME-User and a switching function (see
686       above). The switching function is applied to final
687       particle-particle interaction, *i.e.* both to the user supplied
688       function and the PME Mesh correction part.
689
690 .. mdp:: coulomb-modifier
691
692    .. mdp-value:: Potential-shift
693
694       Shift the Coulomb potential by a constant such that it is zero
695       at the cut-off. This makes the potential the integral of the
696       force. Note that this does not affect the forces or the
697       sampling.
698
699    .. mdp-value:: None
700
701       Use an unmodified Coulomb potential. This can be useful
702       when comparing energies with those computed with other software.
703
704 .. mdp:: rcoulomb-switch
705
706    (0) [nm]
707    where to start switching the Coulomb potential, only relevant
708    when force or potential switching is used
709
710 .. mdp:: rcoulomb
711
712    (1) [nm]
713    The distance for the Coulomb cut-off. Note that with PME this value
714    can be increased by the PME tuning in :ref:`gmx mdrun` along with
715    the PME grid spacing.
716
717 .. mdp:: epsilon-r
718
719    (1)
720    The relative dielectric constant. A value of 0 means infinity.
721
722 .. mdp:: epsilon-rf
723
724    (0)
725    The relative dielectric constant of the reaction field. This
726    is only used with reaction-field electrostatics. A value of 0
727    means infinity.
728
729
730 Van der Waals
731 ^^^^^^^^^^^^^
732
733 .. mdp:: vdwtype
734
735    .. mdp-value:: Cut-off
736
737       Plain cut-off with pair list radius :mdp:`rlist` and VdW
738       cut-off :mdp:`rvdw`, where :mdp:`rlist` >= :mdp:`rvdw`.
739
740    .. mdp-value:: PME
741
742       Fast smooth Particle-mesh Ewald (SPME) for VdW interactions. The
743       grid dimensions are controlled with :mdp:`fourierspacing` in
744       the same way as for electrostatics, and the interpolation order
745       is controlled with :mdp:`pme-order`. The relative accuracy of
746       direct/reciprocal space is controlled by :mdp:`ewald-rtol-lj`,
747       and the specific combination rules that are to be used by the
748       reciprocal routine are set using :mdp:`lj-pme-comb-rule`.
749
750    .. mdp-value:: Shift
751
752       This functionality is deprecated and replaced by using
753       :mdp-value:`vdwtype=Cut-off` with :mdp-value:`vdw-modifier=Force-switch`.
754       The LJ (not Buckingham) potential is decreased over the whole range and
755       the forces decay smoothly to zero between :mdp:`rvdw-switch` and
756       :mdp:`rvdw`.
757
758    .. mdp-value:: Switch
759
760       This functionality is deprecated and replaced by using
761       :mdp-value:`vdwtype=Cut-off` with :mdp-value:`vdw-modifier=Potential-switch`.
762       The LJ (not Buckingham) potential is normal out to :mdp:`rvdw-switch`, after
763       which it is switched off to reach zero at :mdp:`rvdw`. Both the
764       potential and force functions are continuously smooth, but be
765       aware that all switch functions will give rise to a bulge
766       (increase) in the force (since we are switching the
767       potential).
768
769    .. mdp-value:: User
770
771       Currently unsupported.
772       See user for :mdp:`coulombtype`. The function value at zero is
773       not important. When you want to use LJ correction, make sure
774       that :mdp:`rvdw` corresponds to the cut-off in the user-defined
775       function. When :mdp:`coulombtype` is not set to User the values
776       for the ``f`` and ``-f'`` columns are ignored.
777
778 .. mdp:: vdw-modifier
779
780    .. mdp-value:: Potential-shift
781
782       Shift the Van der Waals potential by a constant such that it is
783       zero at the cut-off. This makes the potential the integral of
784       the force. Note that this does not affect the forces or the
785       sampling.
786
787    .. mdp-value:: None
788
789       Use an unmodified Van der Waals potential. This can be useful
790       when comparing energies with those computed with other software.
791
792    .. mdp-value:: Force-switch
793
794       Smoothly switches the forces to zero between :mdp:`rvdw-switch`
795       and :mdp:`rvdw`. This shifts the potential shift over the whole
796       range and switches it to zero at the cut-off. Note that this is
797       more expensive to calculate than a plain cut-off and it is not
798       required for energy conservation, since Potential-shift
799       conserves energy just as well.
800
801    .. mdp-value:: Potential-switch
802
803       Smoothly switches the potential to zero between
804       :mdp:`rvdw-switch` and :mdp:`rvdw`. Note that this introduces
805       articifically large forces in the switching region and is much
806       more expensive to calculate. This option should only be used if
807       the force field you are using requires this.
808
809 .. mdp:: rvdw-switch
810
811    (0) [nm]
812    where to start switching the LJ force and possibly the potential,
813    only relevant when force or potential switching is used
814
815 .. mdp:: rvdw
816
817    (1) [nm]
818    distance for the LJ or Buckingham cut-off
819
820 .. mdp:: DispCorr
821
822    .. mdp-value:: no
823
824       don't apply any correction
825
826    .. mdp-value:: EnerPres
827
828       apply long range dispersion corrections for Energy and Pressure
829
830    .. mdp-value:: Ener
831
832       apply long range dispersion corrections for Energy only
833
834
835 Tables
836 ^^^^^^
837
838 .. mdp:: table-extension
839
840    (1) [nm]
841    Extension of the non-bonded potential lookup tables beyond the
842    largest cut-off distance. With actual non-bonded interactions
843    the tables are never accessed beyond the cut-off. But a longer
844    table length might be needed for the 1-4 interactions, which
845    are always tabulated irrespective of the use of tables for
846    the non-bonded interactions.
847
848 .. mdp:: energygrp-table
849
850    Currently unsupported.
851    When user tables are used for electrostatics and/or VdW, here one
852    can give pairs of energy groups for which seperate user tables
853    should be used. The two energy groups will be appended to the table
854    file name, in order of their definition in :mdp:`energygrps`,
855    seperated by underscores. For example, if ``energygrps = Na Cl
856    Sol`` and ``energygrp-table = Na Na Na Cl``, :ref:`gmx mdrun` will
857    read ``table_Na_Na.xvg`` and ``table_Na_Cl.xvg`` in addition to the
858    normal ``table.xvg`` which will be used for all other energy group
859    pairs.
860
861
862 Ewald
863 ^^^^^
864
865 .. mdp:: fourierspacing
866
867    (0.12) [nm]
868    For ordinary Ewald, the ratio of the box dimensions and the spacing
869    determines a lower bound for the number of wave vectors to use in
870    each (signed) direction. For PME and P3M, that ratio determines a
871    lower bound for the number of Fourier-space grid points that will
872    be used along that axis. In all cases, the number for each
873    direction can be overridden by entering a non-zero value for that
874    :mdp:`fourier-nx` direction. For optimizing the relative load of
875    the particle-particle interactions and the mesh part of PME, it is
876    useful to know that the accuracy of the electrostatics remains
877    nearly constant when the Coulomb cut-off and the PME grid spacing
878    are scaled by the same factor. Note that this spacing can be scaled
879    up along with :mdp:`rcoulomb` by the PME tuning in :ref:`gmx mdrun`.
880
881 .. mdp:: fourier-nx
882 .. mdp:: fourier-ny
883 .. mdp:: fourier-nz
884
885    (0)
886    Highest magnitude of wave vectors in reciprocal space when using Ewald.
887    Grid size when using PME or P3M. These values override
888    :mdp:`fourierspacing` per direction. The best choice is powers of
889    2, 3, 5 and 7. Avoid large primes. Note that these grid sizes can
890    be reduced along with scaling up :mdp:`rcoulomb` by the PME tuning
891    in :ref:`gmx mdrun`.
892
893 .. mdp:: pme-order
894
895    (4)
896    Interpolation order for PME. 4 equals cubic interpolation. You
897    might try 6/8/10 when running in parallel and simultaneously
898    decrease grid dimension.
899
900 .. mdp:: ewald-rtol
901
902    (10\ :sup:`-5`)
903    The relative strength of the Ewald-shifted direct potential at
904    :mdp:`rcoulomb` is given by :mdp:`ewald-rtol`. Decreasing this
905    will give a more accurate direct sum, but then you need more wave
906    vectors for the reciprocal sum.
907
908 .. mdp:: ewald-rtol-lj
909
910    (10\ :sup:`-3`)
911    When doing PME for VdW-interactions, :mdp:`ewald-rtol-lj` is used
912    to control the relative strength of the dispersion potential at
913    :mdp:`rvdw` in the same way as :mdp:`ewald-rtol` controls the
914    electrostatic potential.
915
916 .. mdp:: lj-pme-comb-rule
917
918    (Geometric)
919    The combination rules used to combine VdW-parameters in the
920    reciprocal part of LJ-PME. Geometric rules are much faster than
921    Lorentz-Berthelot and usually the recommended choice, even when the
922    rest of the force field uses the Lorentz-Berthelot rules.
923
924    .. mdp-value:: Geometric
925
926       Apply geometric combination rules
927
928    .. mdp-value:: Lorentz-Berthelot
929
930       Apply Lorentz-Berthelot combination rules
931
932 .. mdp:: ewald-geometry
933
934    .. mdp-value:: 3d
935
936       The Ewald sum is performed in all three dimensions.
937
938    .. mdp-value:: 3dc
939
940       The reciprocal sum is still performed in 3D, but a force and
941       potential correction applied in the ``z`` dimension to produce a
942       pseudo-2D summation. If your system has a slab geometry in the
943       ``x-y`` plane you can try to increase the ``z``-dimension of the box
944       (a box height of 3 times the slab height is usually ok) and use
945       this option.
946
947 .. mdp:: epsilon-surface
948
949    (0)
950    This controls the dipole correction to the Ewald summation in
951    3D. The default value of zero means it is turned off. Turn it on by
952    setting it to the value of the relative permittivity of the
953    imaginary surface around your infinite system. Be careful - you
954    shouldn't use this if you have free mobile charges in your
955    system. This value does not affect the slab 3DC variant of the long
956    range corrections.
957
958
959 Temperature coupling
960 ^^^^^^^^^^^^^^^^^^^^
961
962 .. mdp:: tcoupl
963
964    .. mdp-value:: no
965
966       No temperature coupling.
967
968    .. mdp-value:: berendsen
969
970       Temperature coupling with a Berendsen thermostat to a bath with
971       temperature :mdp:`ref-t`, with time constant
972       :mdp:`tau-t`. Several groups can be coupled separately, these
973       are specified in the :mdp:`tc-grps` field separated by spaces.
974
975    .. mdp-value:: nose-hoover
976
977       Temperature coupling using a Nose-Hoover extended ensemble. The
978       reference temperature and coupling groups are selected as above,
979       but in this case :mdp:`tau-t` controls the period of the
980       temperature fluctuations at equilibrium, which is slightly
981       different from a relaxation time. For NVT simulations the
982       conserved energy quantity is written to the energy and log files.
983
984    .. mdp-value:: andersen
985
986       Temperature coupling by randomizing a fraction of the particle velocities
987       at each timestep. Reference temperature and coupling groups are
988       selected as above. :mdp:`tau-t` is the average time between
989       randomization of each molecule. Inhibits particle dynamics
990       somewhat, but little or no ergodicity issues. Currently only
991       implemented with velocity Verlet, and not implemented with
992       constraints.
993
994    .. mdp-value:: andersen-massive
995
996       Temperature coupling by randomizing velocities of all particles at
997       infrequent timesteps. Reference temperature and coupling groups are
998       selected as above. :mdp:`tau-t` is the time between
999       randomization of all molecules. Inhibits particle dynamics
1000       somewhat, but little or no ergodicity issues. Currently only
1001       implemented with velocity Verlet.
1002
1003    .. mdp-value:: v-rescale
1004
1005       Temperature coupling using velocity rescaling with a stochastic
1006       term (JCP 126, 014101). This thermostat is similar to Berendsen
1007       coupling, with the same scaling using :mdp:`tau-t`, but the
1008       stochastic term ensures that a proper canonical ensemble is
1009       generated. The random seed is set with :mdp:`ld-seed`. This
1010       thermostat works correctly even for :mdp:`tau-t` =0. For NVT
1011       simulations the conserved energy quantity is written to the
1012       energy and log file.
1013
1014 .. mdp:: nsttcouple
1015
1016    (-1)
1017    The frequency for coupling the temperature. The default value of -1
1018    sets :mdp:`nsttcouple` equal to 10, or fewer steps if required
1019    for accurate integration. Note that the default value is not 1
1020    because additional computation and communication is required for
1021    obtaining the kinetic energy. For velocity
1022    Verlet integrators :mdp:`nsttcouple` is set to 1.
1023
1024 .. mdp:: nh-chain-length
1025
1026    (10)
1027    The number of chained Nose-Hoover thermostats for velocity Verlet
1028    integrators, the leap-frog :mdp-value:`integrator=md` integrator
1029    only supports 1. Data for the NH chain variables is not printed
1030    to the :ref:`edr` file by default, but can be turned on with the
1031    :mdp:`print-nose-hoover-chain-variables` option.
1032
1033 .. mdp:: print-nose-hoover-chain-variables
1034
1035    .. mdp-value:: no
1036
1037       Do not store Nose-Hoover chain variables in the energy file.
1038
1039    .. mdp-value:: yes
1040
1041       Store all positions and velocities of the Nose-Hoover chain
1042       in the energy file.
1043
1044 .. mdp:: tc-grps
1045
1046    groups to couple to separate temperature baths
1047
1048 .. mdp:: tau-t
1049
1050    [ps]
1051    time constant for coupling (one for each group in
1052    :mdp:`tc-grps`), -1 means no temperature coupling
1053
1054 .. mdp:: ref-t
1055
1056    [K]
1057    reference temperature for coupling (one for each group in
1058    :mdp:`tc-grps`)
1059
1060
1061 Pressure coupling
1062 ^^^^^^^^^^^^^^^^^
1063
1064 .. mdp:: pcoupl
1065
1066    .. mdp-value:: no
1067
1068       No pressure coupling. This means a fixed box size.
1069
1070    .. mdp-value:: Berendsen
1071
1072       Exponential relaxation pressure coupling with time constant
1073       :mdp:`tau-p`. The box is scaled every :mdp:`nstpcouple` steps. It has been
1074       argued that this does not yield a correct thermodynamic
1075       ensemble, but it is the most efficient way to scale a box at the
1076       beginning of a run.
1077
1078    .. mdp-value:: C-rescale
1079
1080       Exponential relaxation pressure coupling with time constant
1081       :mdp:`tau-p`, including a stochastic term to enforce correct
1082       volume fluctuations.  The box is scaled every :mdp:`nstpcouple`
1083       steps. It can be used for both equilibration and production.
1084
1085    .. mdp-value:: Parrinello-Rahman
1086
1087       Extended-ensemble pressure coupling where the box vectors are
1088       subject to an equation of motion. The equation of motion for the
1089       atoms is coupled to this. No instantaneous scaling takes
1090       place. As for Nose-Hoover temperature coupling the time constant
1091       :mdp:`tau-p` is the period of pressure fluctuations at
1092       equilibrium. This is probably a better method when you want to
1093       apply pressure scaling during data collection, but beware that
1094       you can get very large oscillations if you are starting from a
1095       different pressure. For simulations where the exact fluctations
1096       of the NPT ensemble are important, or if the pressure coupling
1097       time is very short it may not be appropriate, as the previous
1098       time step pressure is used in some steps of the |Gromacs|
1099       implementation for the current time step pressure.
1100
1101    .. mdp-value:: MTTK
1102
1103       Martyna-Tuckerman-Tobias-Klein implementation, only useable with
1104       :mdp-value:`integrator=md-vv` or :mdp-value:`integrator=md-vv-avek`, very similar to
1105       Parrinello-Rahman. As for Nose-Hoover temperature coupling the
1106       time constant :mdp:`tau-p` is the period of pressure
1107       fluctuations at equilibrium. This is probably a better method
1108       when you want to apply pressure scaling during data collection,
1109       but beware that you can get very large oscillations if you are
1110       starting from a different pressure. Currently (as of version
1111       5.1), it only supports isotropic scaling, and only works without
1112       constraints.
1113
1114 .. mdp:: pcoupltype
1115
1116    Specifies the kind of isotropy of the pressure coupling used. Each
1117    kind takes one or more values for :mdp:`compressibility` and
1118    :mdp:`ref-p`. Only a single value is permitted for :mdp:`tau-p`.
1119
1120    .. mdp-value:: isotropic
1121
1122       Isotropic pressure coupling with time constant
1123       :mdp:`tau-p`. One value each for :mdp:`compressibility` and
1124       :mdp:`ref-p` is required.
1125
1126    .. mdp-value:: semiisotropic
1127
1128       Pressure coupling which is isotropic in the ``x`` and ``y``
1129       direction, but different in the ``z`` direction. This can be
1130       useful for membrane simulations. Two values each for
1131       :mdp:`compressibility` and :mdp:`ref-p` are required, for
1132       ``x/y`` and ``z`` directions respectively.
1133
1134    .. mdp-value:: anisotropic
1135
1136       Same as before, but 6 values are needed for ``xx``, ``yy``, ``zz``,
1137       ``xy/yx``, ``xz/zx`` and ``yz/zy`` components,
1138       respectively. When the off-diagonal compressibilities are set to
1139       zero, a rectangular box will stay rectangular. Beware that
1140       anisotropic scaling can lead to extreme deformation of the
1141       simulation box.
1142
1143    .. mdp-value:: surface-tension
1144
1145       Surface tension coupling for surfaces parallel to the
1146       xy-plane. Uses normal pressure coupling for the ``z``-direction,
1147       while the surface tension is coupled to the ``x/y`` dimensions of
1148       the box. The first :mdp:`ref-p` value is the reference surface
1149       tension times the number of surfaces ``bar nm``, the second
1150       value is the reference ``z``-pressure ``bar``. The two
1151       :mdp:`compressibility` values are the compressibility in the
1152       ``x/y`` and ``z`` direction respectively. The value for the
1153       ``z``-compressibility should be reasonably accurate since it
1154       influences the convergence of the surface-tension, it can also
1155       be set to zero to have a box with constant height.
1156
1157 .. mdp:: nstpcouple
1158
1159    (-1)
1160    The frequency for coupling the pressure. The default value of -1
1161    sets :mdp:`nstpcouple` equal to 10, or fewer steps if required
1162    for accurate integration. Note that the default value is not 1
1163    because additional computation and communication is required for
1164    obtaining the virial. For velocity
1165    Verlet integrators :mdp:`nstpcouple` is set to 1.
1166
1167 .. mdp:: tau-p
1168
1169    (1) [ps]
1170    The time constant for pressure coupling (one value for all
1171    directions).
1172
1173 .. mdp:: compressibility
1174
1175    [bar\ :sup:`-1`]
1176    The compressibility (NOTE: this is now really in bar\ :sup:`-1`) For water at 1
1177    atm and 300 K the compressibility is 4.5e-5 bar\ :sup:`-1`. The number of
1178    required values is implied by :mdp:`pcoupltype`.
1179
1180 .. mdp:: ref-p
1181
1182    [bar]
1183    The reference pressure for coupling. The number of required values
1184    is implied by :mdp:`pcoupltype`.
1185
1186 .. mdp:: refcoord-scaling
1187
1188    .. mdp-value:: no
1189
1190       The reference coordinates for position restraints are not
1191       modified. Note that with this option the virial and pressure
1192       might be ill defined, see :ref:`here <reference-manual-position-restraints>`
1193       for more details.
1194
1195    .. mdp-value:: all
1196
1197       The reference coordinates are scaled with the scaling matrix of
1198       the pressure coupling.
1199
1200    .. mdp-value:: com
1201
1202       Scale the center of mass of the reference coordinates with the
1203       scaling matrix of the pressure coupling. The vectors of each
1204       reference coordinate to the center of mass are not scaled. Only
1205       one COM is used, even when there are multiple molecules with
1206       position restraints. For calculating the COM of the reference
1207       coordinates in the starting configuration, periodic boundary
1208       conditions are not taken into account. Note that with this option
1209       the virial and pressure might be ill defined, see
1210       :ref:`here <reference-manual-position-restraints>` for more details.
1211
1212
1213 Simulated annealing
1214 ^^^^^^^^^^^^^^^^^^^
1215
1216 Simulated annealing is controlled separately for each temperature
1217 group in |Gromacs|. The reference temperature is a piecewise linear
1218 function, but you can use an arbitrary number of points for each
1219 group, and choose either a single sequence or a periodic behaviour for
1220 each group. The actual annealing is performed by dynamically changing
1221 the reference temperature used in the thermostat algorithm selected,
1222 so remember that the system will usually not instantaneously reach the
1223 reference temperature!
1224
1225 .. mdp:: annealing
1226
1227    Type of annealing for each temperature group
1228
1229    .. mdp-value:: no
1230
1231        No simulated annealing - just couple to reference temperature value.
1232
1233    .. mdp-value:: single
1234
1235        A single sequence of annealing points. If your simulation is
1236        longer than the time of the last point, the temperature will be
1237        coupled to this constant value after the annealing sequence has
1238        reached the last time point.
1239
1240    .. mdp-value:: periodic
1241
1242        The annealing will start over at the first reference point once
1243        the last reference time is reached. This is repeated until the
1244        simulation ends.
1245
1246 .. mdp:: annealing-npoints
1247
1248    A list with the number of annealing reference/control points used
1249    for each temperature group. Use 0 for groups that are not
1250    annealed. The number of entries should equal the number of
1251    temperature groups.
1252
1253 .. mdp:: annealing-time
1254
1255    List of times at the annealing reference/control points for each
1256    group. If you are using periodic annealing, the times will be used
1257    modulo the last value, *i.e.* if the values are 0, 5, 10, and 15,
1258    the coupling will restart at the 0ps value after 15ps, 30ps, 45ps,
1259    etc. The number of entries should equal the sum of the numbers
1260    given in :mdp:`annealing-npoints`.
1261
1262 .. mdp:: annealing-temp
1263
1264    List of temperatures at the annealing reference/control points for
1265    each group. The number of entries should equal the sum of the
1266    numbers given in :mdp:`annealing-npoints`.
1267
1268 Confused? OK, let's use an example. Assume you have two temperature
1269 groups, set the group selections to ``annealing = single periodic``,
1270 the number of points of each group to ``annealing-npoints = 3 4``, the
1271 times to ``annealing-time = 0 3 6 0 2 4 6`` and finally temperatures
1272 to ``annealing-temp = 298 280 270 298 320 320 298``. The first group
1273 will be coupled to 298K at 0ps, but the reference temperature will
1274 drop linearly to reach 280K at 3ps, and then linearly between 280K and
1275 270K from 3ps to 6ps. After this is stays constant, at 270K. The
1276 second group is coupled to 298K at 0ps, it increases linearly to 320K
1277 at 2ps, where it stays constant until 4ps. Between 4ps and 6ps it
1278 decreases to 298K, and then it starts over with the same pattern
1279 again, *i.e.* rising linearly from 298K to 320K between 6ps and
1280 8ps. Check the summary printed by :ref:`gmx grompp` if you are unsure!
1281
1282
1283 Velocity generation
1284 ^^^^^^^^^^^^^^^^^^^
1285
1286 .. mdp:: gen-vel
1287
1288    .. mdp-value:: no
1289
1290         Do not generate velocities. The velocities are set to zero
1291         when there are no velocities in the input structure file.
1292
1293    .. mdp-value:: yes
1294
1295         Generate velocities in :ref:`gmx grompp` according to a
1296         Maxwell distribution at temperature :mdp:`gen-temp`, with
1297         random seed :mdp:`gen-seed`. This is only meaningful with
1298         :mdp-value:`integrator=md`.
1299
1300 .. mdp:: gen-temp
1301
1302    (300) [K]
1303    temperature for Maxwell distribution
1304
1305 .. mdp:: gen-seed
1306
1307    (-1) [integer]
1308    used to initialize random generator for random velocities,
1309    when :mdp:`gen-seed` is set to -1, a pseudo random seed is
1310    used.
1311
1312
1313 Bonds
1314 ^^^^^
1315
1316 .. mdp:: constraints
1317
1318    Controls which bonds in the topology will be converted to rigid
1319    holonomic constraints. Note that typical rigid water models do not
1320    have bonds, but rather a specialized ``[settles]`` directive, so
1321    are not affected by this keyword.
1322
1323    .. mdp-value:: none
1324
1325       No bonds converted to constraints.
1326
1327    .. mdp-value:: h-bonds
1328
1329       Convert the bonds with H-atoms to constraints.
1330
1331    .. mdp-value:: all-bonds
1332
1333       Convert all bonds to constraints.
1334
1335    .. mdp-value:: h-angles
1336
1337       Convert all bonds to constraints and convert the angles that
1338       involve H-atoms to bond-constraints.
1339
1340    .. mdp-value:: all-angles
1341
1342       Convert all bonds to constraints and all angles to bond-constraints.
1343
1344 .. mdp:: constraint-algorithm
1345
1346    Chooses which solver satisfies any non-SETTLE holonomic
1347    constraints.
1348
1349    .. mdp-value:: LINCS
1350
1351       LINear Constraint Solver. With domain decomposition the parallel
1352       version P-LINCS is used. The accuracy in set with
1353       :mdp:`lincs-order`, which sets the number of matrices in the
1354       expansion for the matrix inversion. After the matrix inversion
1355       correction the algorithm does an iterative correction to
1356       compensate for lengthening due to rotation. The number of such
1357       iterations can be controlled with :mdp:`lincs-iter`. The root
1358       mean square relative constraint deviation is printed to the log
1359       file every :mdp:`nstlog` steps. If a bond rotates more than
1360       :mdp:`lincs-warnangle` in one step, a warning will be printed
1361       both to the log file and to ``stderr``. LINCS should not be used
1362       with coupled angle constraints.
1363
1364    .. mdp-value:: SHAKE
1365
1366       SHAKE is slightly slower and less stable than LINCS, but does
1367       work with angle constraints. The relative tolerance is set with
1368       :mdp:`shake-tol`, 0.0001 is a good value for "normal" MD. SHAKE
1369       does not support constraints between atoms on different
1370       decomposition domains, so it can only be used with domain
1371       decomposition when so-called update-groups are used, which is
1372       usally the case when only bonds involving hydrogens are
1373       constrained. SHAKE can not be used with energy minimization.
1374
1375 .. mdp:: continuation
1376
1377    This option was formerly known as ``unconstrained-start``.
1378
1379    .. mdp-value:: no
1380
1381       apply constraints to the start configuration and reset shells
1382
1383    .. mdp-value:: yes
1384
1385       do not apply constraints to the start configuration and do not
1386       reset shells, useful for exact coninuation and reruns
1387
1388 .. mdp:: shake-tol
1389
1390    (0.0001)
1391    relative tolerance for SHAKE
1392
1393 .. mdp:: lincs-order
1394
1395    (4)
1396    Highest order in the expansion of the constraint coupling
1397    matrix. When constraints form triangles, an additional expansion of
1398    the same order is applied on top of the normal expansion only for
1399    the couplings within such triangles. For "normal" MD simulations an
1400    order of 4 usually suffices, 6 is needed for large time-steps with
1401    virtual sites or BD. For accurate energy minimization an order of 8
1402    or more might be required. With domain decomposition, the cell size
1403    is limited by the distance spanned by :mdp:`lincs-order` +1
1404    constraints. When one wants to scale further than this limit, one
1405    can decrease :mdp:`lincs-order` and increase :mdp:`lincs-iter`,
1406    since the accuracy does not deteriorate when (1+ :mdp:`lincs-iter`
1407    )* :mdp:`lincs-order` remains constant.
1408
1409 .. mdp:: lincs-iter
1410
1411    (1)
1412    Number of iterations to correct for rotational lengthening in
1413    LINCS. For normal runs a single step is sufficient, but for NVE
1414    runs where you want to conserve energy accurately or for accurate
1415    energy minimization you might want to increase it to 2.
1416
1417 .. mdp:: lincs-warnangle
1418
1419    (30) [deg]
1420    maximum angle that a bond can rotate before LINCS will complain
1421
1422 .. mdp:: morse
1423
1424    .. mdp-value:: no
1425
1426       bonds are represented by a harmonic potential
1427
1428    .. mdp-value:: yes
1429
1430       bonds are represented by a Morse potential
1431
1432
1433 Energy group exclusions
1434 ^^^^^^^^^^^^^^^^^^^^^^^
1435
1436 .. mdp:: energygrp-excl
1437
1438    Pairs of energy groups for which all non-bonded interactions are
1439    excluded. An example: if you have two energy groups ``Protein`` and
1440    ``SOL``, specifying ``energygrp-excl = Protein Protein SOL SOL``
1441    would give only the non-bonded interactions between the protein and
1442    the solvent. This is especially useful for speeding up energy
1443    calculations with ``mdrun -rerun`` and for excluding interactions
1444    within frozen groups.
1445
1446
1447 Walls
1448 ^^^^^
1449
1450 .. mdp:: nwall
1451
1452    (0)
1453    When set to 1 there is a wall at ``z=0``, when set to 2 there is
1454    also a wall at ``z=z-box``. Walls can only be used with :mdp:`pbc`
1455    ``=xy``. When set to 2, pressure coupling and Ewald summation can be
1456    used (it is usually best to use semiisotropic pressure coupling
1457    with the ``x/y`` compressibility set to 0, as otherwise the surface
1458    area will change). Walls interact wit the rest of the system
1459    through an optional :mdp:`wall-atomtype`. Energy groups ``wall0``
1460    and ``wall1`` (for :mdp:`nwall` =2) are added automatically to
1461    monitor the interaction of energy groups with each wall. The center
1462    of mass motion removal will be turned off in the ``z``-direction.
1463
1464 .. mdp:: wall-atomtype
1465
1466    the atom type name in the force field for each wall. By (for
1467    example) defining a special wall atom type in the topology with its
1468    own combination rules, this allows for independent tuning of the
1469    interaction of each atomtype with the walls.
1470
1471 .. mdp:: wall-type
1472
1473    .. mdp-value:: 9-3
1474
1475       LJ integrated over the volume behind the wall: 9-3 potential
1476
1477    .. mdp-value:: 10-4
1478
1479       LJ integrated over the wall surface: 10-4 potential
1480
1481    .. mdp-value:: 12-6
1482
1483       direct LJ potential with the ``z`` distance from the wall
1484
1485 .. mdp:: table
1486
1487    user defined potentials indexed with the ``z`` distance from the
1488    wall, the tables are read analogously to the
1489    :mdp:`energygrp-table` option, where the first name is for a
1490    "normal" energy group and the second name is ``wall0`` or
1491    ``wall1``, only the dispersion and repulsion columns are used
1492
1493 .. mdp:: wall-r-linpot
1494
1495    (-1) [nm]
1496    Below this distance from the wall the potential is continued
1497    linearly and thus the force is constant. Setting this option to a
1498    postive value is especially useful for equilibration when some
1499    atoms are beyond a wall. When the value is <=0 (<0 for
1500    :mdp:`wall-type` =table), a fatal error is generated when atoms
1501    are beyond a wall.
1502
1503 .. mdp:: wall-density
1504
1505    [nm\ :sup:`-3`] / [nm\ :sup:`-2`]
1506    the number density of the atoms for each wall for wall types 9-3
1507    and 10-4
1508
1509 .. mdp:: wall-ewald-zfac
1510
1511    (3)
1512    The scaling factor for the third box vector for Ewald summation
1513    only, the minimum is 2. Ewald summation can only be used with
1514    :mdp:`nwall` =2, where one should use :mdp:`ewald-geometry`
1515    ``=3dc``. The empty layer in the box serves to decrease the
1516    unphysical Coulomb interaction between periodic images.
1517
1518
1519 COM pulling
1520 ^^^^^^^^^^^
1521
1522 Note that where pulling coordinates are applicable, there can be more
1523 than one (set with :mdp:`pull-ncoords`) and multiple related :ref:`mdp`
1524 variables will exist accordingly. Documentation references to things
1525 like :mdp:`pull-coord1-vec` should be understood to apply to to the
1526 applicable pulling coordinate, eg. the second pull coordinate is described by
1527 pull-coord2-vec, pull-coord2-k, and so on.
1528
1529 .. mdp:: pull
1530
1531    .. mdp-value:: no
1532
1533       No center of mass pulling. All the following pull options will
1534       be ignored (and if present in the :ref:`mdp` file, they unfortunately
1535       generate warnings)
1536
1537    .. mdp-value:: yes
1538
1539        Center of mass pulling will be applied on 1 or more groups using
1540        1 or more pull coordinates.
1541
1542 .. mdp:: pull-cylinder-r
1543
1544    (1.5) [nm]
1545    the radius of the cylinder for :mdp-value:`pull-coord1-geometry=cylinder`
1546
1547 .. mdp:: pull-constr-tol
1548
1549    (10\ :sup:`-6`)
1550    the relative constraint tolerance for constraint pulling
1551
1552 .. mdp:: pull-print-com
1553
1554    .. mdp-value:: no
1555
1556       do not print the COM for any group
1557
1558    .. mdp-value:: yes
1559
1560       print the COM of all groups for all pull coordinates
1561
1562 .. mdp:: pull-print-ref-value
1563
1564    .. mdp-value:: no
1565
1566       do not print the reference value for each pull coordinate
1567
1568    .. mdp-value:: yes
1569
1570       print the reference value for each pull coordinate
1571
1572 .. mdp:: pull-print-components
1573
1574    .. mdp-value:: no
1575
1576       only print the distance for each pull coordinate
1577
1578    .. mdp-value:: yes
1579
1580       print the distance and Cartesian components selected in
1581       :mdp:`pull-coord1-dim`
1582
1583 .. mdp:: pull-nstxout
1584
1585    (50)
1586    frequency for writing out the COMs of all the pull group (0 is
1587    never)
1588
1589 .. mdp:: pull-nstfout
1590
1591    (50)
1592    frequency for writing out the force of all the pulled group
1593    (0 is never)
1594
1595 .. mdp:: pull-pbc-ref-prev-step-com
1596
1597    .. mdp-value:: no
1598
1599       Use the reference atom (:mdp:`pull-group1-pbcatom`) for the
1600       treatment of periodic boundary conditions.
1601
1602    .. mdp-value:: yes
1603
1604       Use the COM of the previous step as reference for the treatment
1605       of periodic boundary conditions. The reference is initialized
1606       using the reference atom (:mdp:`pull-group1-pbcatom`), which should
1607       be located centrally in the group. Using the COM from the
1608       previous step can be useful if one or more pull groups are large.
1609
1610 .. mdp:: pull-xout-average
1611
1612    .. mdp-value:: no
1613
1614       Write the instantaneous coordinates for all the pulled groups.
1615
1616    .. mdp-value:: yes
1617
1618       Write the average coordinates (since last output) for all the
1619       pulled groups. N.b., some analysis tools might expect instantaneous
1620       pull output.
1621
1622 .. mdp:: pull-fout-average
1623
1624    .. mdp-value:: no
1625
1626       Write the instantaneous force for all the pulled groups.
1627
1628    .. mdp-value:: yes
1629
1630       Write the average force (since last output) for all the
1631       pulled groups. N.b., some analysis tools might expect instantaneous
1632       pull output.
1633
1634 .. mdp:: pull-ngroups
1635
1636    (1)
1637    The number of pull groups, not including the absolute reference
1638    group, when used. Pull groups can be reused in multiple pull
1639    coordinates. Below only the pull options for group 1 are given,
1640    further groups simply increase the group index number.
1641
1642 .. mdp:: pull-ncoords
1643
1644    (1)
1645    The number of pull coordinates. Below only the pull options for
1646    coordinate 1 are given, further coordinates simply increase the
1647    coordinate index number.
1648
1649 .. mdp:: pull-group1-name
1650
1651    The name of the pull group, is looked up in the index file or in
1652    the default groups to obtain the atoms involved.
1653
1654 .. mdp:: pull-group1-weights
1655
1656    Optional relative weights which are multiplied with the masses of
1657    the atoms to give the total weight for the COM. The number should
1658    be 0, meaning all 1, or the number of atoms in the pull group.
1659
1660 .. mdp:: pull-group1-pbcatom
1661
1662    (0)
1663    The reference atom for the treatment of periodic boundary
1664    conditions inside the group (this has no effect on the treatment of
1665    the pbc between groups). This option is only important when the
1666    diameter of the pull group is larger than half the shortest box
1667    vector. For determining the COM, all atoms in the group are put at
1668    their periodic image which is closest to
1669    :mdp:`pull-group1-pbcatom`. A value of 0 means that the middle
1670    atom (number wise) is used, which is only safe for small groups.
1671    :ref:`gmx grompp` checks that the maximum distance from the reference
1672    atom (specifically chosen, or not) to the other atoms in the group
1673    is not too large. This parameter is not used with
1674    :mdp:`pull-coord1-geometry` cylinder. A value of -1 turns on cosine
1675    weighting, which is useful for a group of molecules in a periodic
1676    system, *e.g.* a water slab (see Engin et al. J. Chem. Phys. B
1677    2010).
1678
1679 .. mdp:: pull-coord1-type
1680
1681    .. mdp-value:: umbrella
1682
1683       Center of mass pulling using an umbrella potential between the
1684       reference group and one or more groups.
1685
1686    .. mdp-value:: constraint
1687
1688       Center of mass pulling using a constraint between the reference
1689       group and one or more groups. The setup is identical to the
1690       option umbrella, except for the fact that a rigid constraint is
1691       applied instead of a harmonic potential. Note that this type is
1692       not supported in combination with multiple time stepping.
1693
1694    .. mdp-value:: constant-force
1695
1696       Center of mass pulling using a linear potential and therefore a
1697       constant force. For this option there is no reference position
1698       and therefore the parameters :mdp:`pull-coord1-init` and
1699       :mdp:`pull-coord1-rate` are not used.
1700
1701    .. mdp-value:: flat-bottom
1702
1703       At distances above :mdp:`pull-coord1-init` a harmonic potential
1704       is applied, otherwise no potential is applied.
1705
1706    .. mdp-value:: flat-bottom-high
1707
1708       At distances below :mdp:`pull-coord1-init` a harmonic potential
1709       is applied, otherwise no potential is applied.
1710
1711    .. mdp-value:: external-potential
1712
1713       An external potential that needs to be provided by another
1714       module.
1715
1716 .. mdp:: pull-coord1-potential-provider
1717
1718       The name of the external module that provides the potential for
1719       the case where :mdp:`pull-coord1-type` is external-potential.
1720
1721 .. mdp:: pull-coord1-geometry
1722
1723    .. mdp-value:: distance
1724
1725       Pull along the vector connecting the two groups. Components can
1726       be selected with :mdp:`pull-coord1-dim`.
1727
1728    .. mdp-value:: direction
1729
1730       Pull in the direction of :mdp:`pull-coord1-vec`.
1731
1732    .. mdp-value:: direction-periodic
1733
1734       As :mdp-value:`pull-coord1-geometry=direction`, but does not apply
1735       periodic box vector corrections to keep the distance within half
1736       the box length. This is (only) useful for pushing groups apart
1737       by more than half the box length by continuously changing the reference
1738       location using a pull rate. With this geometry the box should not be
1739       dynamic (*e.g.* no pressure scaling) in the pull dimensions and
1740       the pull force is not added to the virial.
1741
1742    .. mdp-value:: direction-relative
1743
1744       As :mdp-value:`pull-coord1-geometry=direction`, but the pull vector is the vector
1745       that points from the COM of a third to the COM of a fourth pull
1746       group. This means that 4 groups need to be supplied in
1747       :mdp:`pull-coord1-groups`. Note that the pull force will give
1748       rise to a torque on the pull vector, which is turn leads to
1749       forces perpendicular to the pull vector on the two groups
1750       defining the vector. If you want a pull group to move between
1751       the two groups defining the vector, simply use the union of
1752       these two groups as the reference group.
1753
1754    .. mdp-value:: cylinder
1755
1756       Designed for pulling with respect to a layer where the reference
1757       COM is given by a local cylindrical part of the reference group.
1758       The pulling is in the direction of :mdp:`pull-coord1-vec`. From
1759       the first of the two groups in :mdp:`pull-coord1-groups` a
1760       cylinder is selected around the axis going through the COM of
1761       the second group with direction :mdp:`pull-coord1-vec` with
1762       radius :mdp:`pull-cylinder-r`. Weights of the atoms decrease
1763       continously to zero as the radial distance goes from 0 to
1764       :mdp:`pull-cylinder-r` (mass weighting is also used). The radial
1765       dependence gives rise to radial forces on both pull groups.
1766       Note that the radius should be smaller than half the box size.
1767       For tilted cylinders they should be even smaller than half the
1768       box size since the distance of an atom in the reference group
1769       from the COM of the pull group has both a radial and an axial
1770       component. This geometry is not supported with constraint
1771       pulling.
1772
1773    .. mdp-value:: angle
1774
1775       Pull along an angle defined by four groups. The angle is
1776       defined as the angle between two vectors: the vector connecting
1777       the COM of the first group to the COM of the second group and
1778       the vector connecting the COM of the third group to the COM of
1779       the fourth group.
1780
1781    .. mdp-value:: angle-axis
1782
1783       As :mdp-value:`pull-coord1-geometry=angle` but the second vector is given by :mdp:`pull-coord1-vec`.
1784       Thus, only the two groups that define the first vector need to be given.
1785
1786    .. mdp-value:: dihedral
1787
1788       Pull along a dihedral angle defined by six groups. These pairwise
1789       define three vectors: the vector connecting the COM of group 1
1790       to the COM of group 2, the COM of group 3 to the COM of group 4,
1791       and the COM of group 5 to the COM group 6. The dihedral angle is
1792       then defined as the angle between two planes: the plane spanned by the
1793       the two first vectors and the plane spanned the two last vectors.
1794
1795
1796 .. mdp:: pull-coord1-groups
1797
1798    The group indices on which this pull coordinate will operate.
1799    The number of group indices required is geometry dependent.
1800    The first index can be 0, in which case an
1801    absolute reference of :mdp:`pull-coord1-origin` is used. With an
1802    absolute reference the system is no longer translation invariant
1803    and one should think about what to do with the center of mass
1804    motion.
1805
1806 .. mdp:: pull-coord1-dim
1807
1808    (Y Y Y)
1809    Selects the dimensions that this pull coordinate acts on and that
1810    are printed to the output files when
1811    :mdp:`pull-print-components` = :mdp-value:`pull-coord1-start=yes`. With
1812    :mdp:`pull-coord1-geometry` = :mdp-value:`pull-coord1-geometry=distance`, only Cartesian
1813    components set to Y contribute to the distance. Thus setting this
1814    to Y Y N results in a distance in the x/y plane. With other
1815    geometries all dimensions with non-zero entries in
1816    :mdp:`pull-coord1-vec` should be set to Y, the values for other
1817    dimensions only affect the output.
1818
1819 .. mdp:: pull-coord1-origin
1820
1821    (0.0 0.0 0.0)
1822    The pull reference position for use with an absolute reference.
1823
1824 .. mdp:: pull-coord1-vec
1825
1826    (0.0 0.0 0.0)
1827    The pull direction. :ref:`gmx grompp` normalizes the vector.
1828
1829 .. mdp:: pull-coord1-start
1830
1831    .. mdp-value:: no
1832
1833       do not modify :mdp:`pull-coord1-init`
1834
1835    .. mdp-value:: yes
1836
1837       add the COM distance of the starting conformation to
1838       :mdp:`pull-coord1-init`
1839
1840 .. mdp:: pull-coord1-init
1841
1842    (0.0) [nm] or [deg]
1843    The reference distance or reference angle at t=0.
1844
1845 .. mdp:: pull-coord1-rate
1846
1847    (0) [nm/ps] or [deg/ps]
1848    The rate of change of the reference position or reference angle.
1849
1850 .. mdp:: pull-coord1-k
1851
1852    (0) [kJ mol\ :sup:`-1` nm\ :sup:`-2`] or [kJ mol\ :sup:`-1` nm\ :sup:`-1`] or
1853    [kJ mol\ :sup:`-1` rad\ :sup:`-2`] or [kJ mol\ :sup:`-1` rad\ :sup:`-1`]
1854    The force constant. For umbrella pulling this is the harmonic force
1855    constant in kJ mol\ :sup:`-1` nm\ :sup:`-2` (or kJ mol\ :sup:`-1` rad\ :sup:`-2`
1856    for angles). For constant force pulling this is the
1857    force constant of the linear potential, and thus the negative (!)
1858    of the constant force in kJ mol\ :sup:`-1` nm\ :sup:`-1`
1859    (or kJ mol\ :sup:`-1` rad\ :sup:`-1` for angles).
1860    Note that for angles the force constant is expressed in terms of radians
1861    (while :mdp:`pull-coord1-init` and :mdp:`pull-coord1-rate` are expressed in degrees).
1862
1863 .. mdp:: pull-coord1-kB
1864
1865    (pull-k1) [kJ mol\ :sup:`-1` nm\ :sup:`-2`] or [kJ mol\ :sup:`-1` nm\ :sup:`-1`]
1866    or [kJ mol\ :sup:`-1` rad\ :sup:`-2`] or [kJ mol\ :sup:`-1` rad\ :sup:`-1`]
1867    As :mdp:`pull-coord1-k`, but for state B. This is only used when
1868    :mdp:`free-energy` is turned on. The force constant is then (1 -
1869    lambda) * :mdp:`pull-coord1-k` + lambda * :mdp:`pull-coord1-kB`.
1870
1871 AWH adaptive biasing
1872 ^^^^^^^^^^^^^^^^^^^^
1873
1874 .. mdp:: awh
1875
1876    .. mdp-value:: no
1877
1878       No biasing.
1879
1880    .. mdp-value:: yes
1881
1882       Adaptively bias a reaction coordinate using the AWH method and estimate
1883       the corresponding PMF. The PMF and other AWH data are written to energy
1884       file at an interval set by :mdp:`awh-nstout` and can be extracted with
1885       the ``gmx awh`` tool. The AWH coordinate can be
1886       multidimensional and is defined by mapping each dimension to a pull coordinate index.
1887       This is only allowed if :mdp-value:`pull-coord1-type=external-potential` and
1888       :mdp:`pull-coord1-potential-provider` = ``awh`` for the concerned pull coordinate
1889       indices. Pull geometry 'direction-periodic' is not supported by AWH.
1890
1891 .. mdp:: awh-potential
1892
1893    .. mdp-value:: convolved
1894
1895       The applied biasing potential is the convolution of the bias function and a
1896       set of harmonic umbrella potentials (see :mdp-value:`awh-potential=umbrella` below). This results
1897       in a smooth potential function and force. The resolution of the potential is set
1898       by the force constant of each umbrella, see :mdp:`awh1-dim1-force-constant`. This option is not
1899       compatible with using the free energy lambda state as an AWH reaction coordinate.
1900
1901    .. mdp-value:: umbrella
1902
1903       The potential bias is applied by controlling the position of an harmonic potential
1904       using Monte-Carlo sampling.  The force constant is set with
1905       :mdp:`awh1-dim1-force-constant`. The umbrella location
1906       is sampled using Monte-Carlo every :mdp:`awh-nstsample` steps.
1907       This is option is required when using the free energy lambda state as an AWH reaction coordinate.
1908       Apart from that, this option is mainly for comparison
1909       and testing purposes as there are no advantages to using an umbrella.
1910
1911 .. mdp:: awh-share-multisim
1912
1913    .. mdp-value:: no
1914
1915       AWH will not share biases across simulations started with
1916       :ref:`gmx mdrun` option ``-multidir``. The biases will be independent.
1917
1918    .. mdp-value:: yes
1919
1920       With :ref:`gmx mdrun` and option ``-multidir`` the bias and PMF estimates
1921       for biases with :mdp:`awh1-share-group` >0 will be shared across simulations
1922       with the biases with the same :mdp:`awh1-share-group` value.
1923       The simulations should have the same AWH settings for sharing to make sense.
1924       :ref:`gmx mdrun` will check whether the simulations are technically
1925       compatible for sharing, but the user should check that bias sharing
1926       physically makes sense.
1927
1928 .. mdp:: awh-seed
1929
1930    (-1) Random seed for Monte-Carlo sampling the umbrella position,
1931    where -1 indicates to generate a seed. Only used with
1932    :mdp-value:`awh-potential=umbrella`.
1933
1934 .. mdp:: awh-nstout
1935
1936    (100000)
1937    Number of steps between printing AWH data to the energy file, should be
1938    a multiple of :mdp:`nstenergy`.
1939
1940 .. mdp:: awh-nstsample
1941
1942    (10)
1943    Number of steps between sampling of the coordinate value. This sampling
1944    is the basis for updating the bias and estimating the PMF and other AWH observables.
1945
1946 .. mdp:: awh-nsamples-update
1947
1948    (10)
1949    The number of coordinate samples used for each AWH update.
1950    The update interval in steps is :mdp:`awh-nstsample` times this value.
1951
1952 .. mdp:: awh-nbias
1953
1954    (1)
1955    The number of biases, each acting on its own coordinate.
1956    The following options should be specified
1957    for each bias although below only the options for bias number 1 is shown. Options for
1958    other bias indices are  obtained by replacing '1' by the bias index.
1959
1960 .. mdp:: awh1-error-init
1961
1962    (10.0) [kJ mol\ :sup:`-1`]
1963    Estimated initial average error of the PMF for this bias. This value together with the
1964    given diffusion constant(s) :mdp:`awh1-dim1-diffusion` determine the initial biasing rate.
1965    The error is obviously not known *a priori*. Only a rough estimate of :mdp:`awh1-error-init`
1966    is needed however.
1967    As a  general guideline, leave :mdp:`awh1-error-init` to its default value when starting a new
1968    simulation. On the other hand, when there is *a priori* knowledge of the PMF (e.g. when
1969    an initial PMF estimate is provided, see the :mdp:`awh1-user-data` option)
1970    then :mdp:`awh1-error-init` should reflect that knowledge.
1971
1972 .. mdp:: awh1-growth
1973
1974    .. mdp-value:: exp-linear
1975
1976    Each bias keeps a reference weight histogram for the coordinate samples.
1977    Its size sets the magnitude of the bias function and free energy estimate updates
1978    (few samples corresponds to large updates and vice versa).
1979    Thus, its growth rate sets the maximum convergence rate.
1980    By default, there is an initial stage in which the histogram grows close to exponentially (but slower than the sampling rate).
1981    In the final stage that follows, the growth rate is linear and equal to the sampling rate (set by :mdp:`awh-nstsample`).
1982    The initial stage is typically necessary for efficient convergence when starting a new simulation where
1983    high free energy barriers have not yet been flattened by the bias.
1984
1985    .. mdp-value:: linear
1986
1987    As :mdp-value:`awh1-growth=exp-linear` but skip the initial stage. This may be useful if there is *a priori*
1988    knowledge (see :mdp:`awh1-error-init`) which eliminates the need for an initial stage. This is also
1989    the setting compatible with :mdp-value:`awh1-target=local-boltzmann`.
1990
1991 .. mdp:: awh1-equilibrate-histogram
1992
1993    .. mdp-value:: no
1994
1995       Do not equilibrate histogram.
1996
1997    .. mdp-value:: yes
1998
1999       Before entering the initial stage (see :mdp-value:`awh1-growth=exp-linear`), make sure the
2000       histogram of sampled weights is following the target distribution closely enough (specifically,
2001       at least 80% of the target region needs to have a local relative error of less than 20%). This
2002       option would typically only be used when :mdp:`awh1-share-group` > 0
2003       and the initial configurations poorly represent the target
2004       distribution.
2005
2006 .. mdp:: awh1-target
2007
2008    .. mdp-value:: constant
2009
2010       The bias is tuned towards a constant (uniform) coordinate distribution
2011       in the defined sampling interval (defined by  [:mdp:`awh1-dim1-start`, :mdp:`awh1-dim1-end`]).
2012
2013    .. mdp-value:: cutoff
2014
2015       Similar to :mdp-value:`awh1-target=constant`, but the target
2016       distribution is proportional to 1/(1 + exp(F - :mdp-value:`awh1-target=cutoff`)),
2017       where F is the free energy relative to the estimated global minimum.
2018       This provides a smooth switch of a flat target distribution in
2019       regions with free energy lower than the cut-off to a Boltzmann
2020       distribution in regions with free energy higher than the cut-off.
2021
2022    .. mdp-value:: boltzmann
2023
2024       The target distribution is a Boltzmann distribtution with a scaled beta (inverse temperature)
2025       factor given by :mdp:`awh1-target-beta-scaling`. *E.g.*, a value of 0.1
2026       would give the same coordinate distribution as sampling with a simulation temperature
2027       scaled by 10.
2028
2029    .. mdp-value:: local-boltzmann
2030
2031       Same target distribution and use of :mdp:`awh1-target-beta-scaling`
2032       but the convergence towards the target distribution is inherently local *i.e.*, the rate of
2033       change of the bias only depends on the local sampling. This local convergence property is
2034       only compatible with :mdp-value:`awh1-growth=linear`, since for
2035       :mdp-value:`awh1-growth=exp-linear` histograms are globally rescaled in the initial stage.
2036
2037 .. mdp:: awh1-target-beta-scaling
2038
2039    (0)
2040    For :mdp-value:`awh1-target=boltzmann` and :mdp-value:`awh1-target=local-boltzmann`
2041    it is the unitless beta scaling factor taking values in (0,1).
2042
2043 .. mdp:: awh1-target-cutoff
2044
2045    (0) [kJ mol\ :sup:`-1`]
2046    For :mdp-value:`awh1-target=cutoff` this is the cutoff, should be > 0.
2047
2048 .. mdp:: awh1-user-data
2049
2050    .. mdp-value:: no
2051
2052       Initialize the PMF and target distribution with default values.
2053
2054    .. mdp-value:: yes
2055
2056       Initialize the PMF and target distribution with user provided data. For :mdp:`awh-nbias` = 1,
2057       :ref:`gmx mdrun` will expect a file ``awhinit.xvg`` to be present in the run directory.
2058       For multiple biases, :ref:`gmx mdrun` expects files ``awhinit1.xvg``, ``awhinit2.xvg``, etc.
2059       The file name can be changed with the ``-awh`` option.
2060       The first :mdp:`awh1-ndim` columns of
2061       each input file should contain the coordinate values, such that each row defines a point in
2062       coordinate space. Column :mdp:`awh1-ndim` + 1 should contain the PMF value (in kT) for each point.
2063       The target distribution column can either follow the PMF (column  :mdp:`awh1-ndim` + 2) or
2064       be in the same column as written by :ref:`gmx awh`.
2065
2066 .. mdp:: awh1-share-group
2067
2068    .. mdp-value:: 0
2069
2070       Do not share the bias.
2071
2072    .. mdp-value:: positive
2073
2074       Share the bias and PMF estimates within and/or between simulations.
2075       Within a simulation, the bias will be shared between biases that have the
2076       same :mdp:`awh1-share-group` index (note that the current code does not support this).
2077       With :mdp-value:`awh-share-multisim=yes` and
2078       :ref:`gmx mdrun` option ``-multidir`` the bias will also be shared across simulations.
2079       Sharing may increase convergence initially, although the starting configurations
2080       can be critical, especially when sharing between many biases.
2081       Currently, positive group values should start at 1 and increase
2082       by 1 for each subsequent bias that is shared.
2083
2084 .. mdp:: awh1-ndim
2085
2086    (1) [integer]
2087    Number of dimensions of the coordinate, each dimension maps to 1 pull coordinate.
2088    The following options should be specified for each such dimension. Below only
2089    the options for dimension number 1 is shown. Options for other dimension indices are
2090    obtained by replacing '1' by the dimension index.
2091
2092 .. mdp:: awh1-dim1-coord-provider
2093
2094    .. mdp-value:: pull
2095
2096       The pull module is providing the reaction coordinate for this dimension.
2097       With multiple time-stepping, AWH and pull should be in the same MTS level.
2098
2099    .. mdp-value:: fep-lambda
2100
2101       The free energy lambda state is the reaction coordinate for this dimension.
2102       The lambda states to use are specified by :mdp:`fep-lambdas`, :mdp:`vdw-lambdas`,
2103       :mdp:`coul-lambdas` etc. This is not compatible with delta-lambda. It also requires
2104       calc-lambda-neighbors to be -1. With multiple time-stepping, AWH should
2105       be in the slow level. This option requires :mdp-value:`awh-potential=umbrella`.
2106
2107 .. mdp:: awh1-dim1-coord-index
2108
2109    (1)
2110    Index of the pull coordinate defining this coordinate dimension.
2111
2112 .. mdp:: awh1-dim1-force-constant
2113
2114    (0) [kJ mol\ :sup:`-1` nm\ :sup:`-2`] or [kJ mol\ :sup:`-1` rad\ :sup:`-2`]
2115    Force constant for the (convolved) umbrella potential(s) along this
2116    coordinate dimension.
2117
2118 .. mdp:: awh1-dim1-start
2119
2120    (0.0) [nm] or [rad]
2121    Start value of the sampling interval along this dimension. The range of allowed
2122    values depends on the relevant pull geometry (see :mdp:`pull-coord1-geometry`).
2123    For dihedral geometries :mdp:`awh1-dim1-start` greater than :mdp:`awh1-dim1-end`
2124    is allowed. The interval will then wrap around from +period/2 to -period/2.
2125    For the direction geometry, the dimension is made periodic when
2126    the direction is along a box vector and covers more than 95%
2127    of the box length. Note that one should not apply pressure coupling
2128    along a periodic dimension.
2129
2130 .. mdp:: awh1-dim1-end
2131
2132    (0.0) [nm] or [rad]
2133    End value defining the sampling interval together with :mdp:`awh1-dim1-start`.
2134
2135 .. mdp:: awh1-dim1-diffusion
2136
2137    (10\ :sup:`-5`) [nm\ :sup:`2`/ps], [rad\ :sup:`2`/ps] or [ps\ :sup:`-1`]
2138    Estimated diffusion constant for this coordinate dimension determining the initial
2139    biasing rate. This needs only be a rough estimate and should not critically
2140    affect the results unless it is set to something very low, leading to slow convergence,
2141    or very high, forcing the system far from equilibrium. Not setting this value
2142    explicitly generates a warning.
2143
2144 .. mdp:: awh1-dim1-cover-diameter
2145
2146    (0.0) [nm] or [rad]
2147    Diameter that needs to be sampled by a single simulation around a coordinate value
2148    before the point is considered covered in the initial stage (see :mdp-value:`awh1-growth=exp-linear`).
2149    A value > 0  ensures that for each covering there is a continuous transition of this diameter
2150    across each coordinate value.
2151    This is trivially true for independent simulations but not for for multiple bias-sharing simulations
2152    (:mdp:`awh1-share-group`>0).
2153    For a diameter = 0, covering occurs as soon as the simulations have sampled the whole interval, which
2154    for many sharing simulations does not guarantee transitions across free energy barriers.
2155    On the other hand, when the diameter >= the sampling interval length, covering occurs when a single simulation
2156    has independently sampled the whole interval.
2157
2158 Enforced rotation
2159 ^^^^^^^^^^^^^^^^^
2160
2161 These :ref:`mdp` parameters can be used enforce the rotation of a group of atoms,
2162 e.g. a protein subunit. The `reference manual`_ describes in detail 13 different potentials
2163 that can be used to achieve such a rotation.
2164
2165 .. mdp:: rotation
2166
2167    .. mdp-value:: no
2168
2169       No enforced rotation will be applied. All enforced rotation options will
2170       be ignored (and if present in the :ref:`mdp` file, they unfortunately
2171       generate warnings).
2172
2173    .. mdp-value:: yes
2174
2175       Apply the rotation potential specified by :mdp:`rot-type0` to the group of atoms given
2176       under the :mdp:`rot-group0` option.
2177
2178 .. mdp:: rot-ngroups
2179
2180    (1)
2181    Number of rotation groups.
2182
2183 .. mdp:: rot-group0
2184
2185    Name of rotation group 0 in the index file.
2186
2187 .. mdp:: rot-type0
2188
2189    (iso)
2190    Type of rotation potential that is applied to rotation group 0. Can be of of the following:
2191    ``iso``, ``iso-pf``, ``pm``, ``pm-pf``, ``rm``, ``rm-pf``, ``rm2``, ``rm2-pf``,
2192    ``flex``, ``flex-t``, ``flex2``, or ``flex2-t``.
2193
2194 .. mdp:: rot-massw0
2195
2196    (no)
2197    Use mass weighted rotation group positions.
2198
2199 .. mdp:: rot-vec0
2200
2201    (1.0 0.0 0.0)
2202    Rotation vector, will get normalized.
2203
2204 .. mdp:: rot-pivot0
2205
2206    (0.0 0.0 0.0) [nm]
2207    Pivot point for the potentials ``iso``, ``pm``, ``rm``, and ``rm2``.
2208
2209 .. mdp:: rot-rate0
2210
2211    (0) [degree ps\ :sup:`-1`]
2212    Reference rotation rate of group 0.
2213
2214 .. mdp:: rot-k0
2215
2216    (0) [kJ mol\ :sup:`-1` nm\ :sup:`-2`]
2217    Force constant for group 0.
2218
2219 .. mdp:: rot-slab-dist0
2220
2221    (1.5) [nm]
2222    Slab distance, if a flexible axis rotation type was chosen.
2223
2224 .. mdp:: rot-min-gauss0
2225
2226    (0.001)
2227    Minimum value (cutoff) of Gaussian function for the force to be evaluated
2228    (for the flexible axis potentials).
2229
2230 .. mdp:: rot-eps0
2231
2232    (0.0001) [nm\ :sup:`2`]
2233    Value of additive constant epsilon for ``rm2*`` and ``flex2*`` potentials.
2234
2235 .. mdp:: rot-fit-method0
2236
2237    (rmsd)
2238    Fitting method when determining the actual angle of a rotation group
2239    (can be one of ``rmsd``, ``norm``, or ``potential``).
2240
2241 .. mdp:: rot-potfit-nsteps0
2242
2243    (21)
2244    For fit type ``potential``, the number of angular positions around the reference angle for which the
2245    rotation potential is evaluated.
2246
2247 .. mdp:: rot-potfit-step0
2248
2249    (0.25)
2250    For fit type ``potential``, the distance in degrees between two angular positions.
2251
2252 .. mdp:: rot-nstrout
2253
2254    (100)
2255    Output frequency (in steps) for the angle of the rotation group, as well as for the torque
2256    and the rotation potential energy.
2257
2258 .. mdp:: rot-nstsout
2259
2260    (1000)
2261    Output frequency for per-slab data of the flexible axis potentials, i.e. angles, torques and slab centers.
2262
2263
2264 NMR refinement
2265 ^^^^^^^^^^^^^^
2266
2267 .. mdp:: disre
2268
2269    .. mdp-value:: no
2270
2271       ignore distance restraint information in topology file
2272
2273    .. mdp-value:: simple
2274
2275       simple (per-molecule) distance restraints.
2276
2277    .. mdp-value:: ensemble
2278
2279       distance restraints over an ensemble of molecules in one
2280       simulation box. Normally, one would perform ensemble averaging
2281       over multiple simulations, using ``mdrun
2282       -multidir``. The environment
2283       variable ``GMX_DISRE_ENSEMBLE_SIZE`` sets the number of systems
2284       within each ensemble (usually equal to the number of directories
2285       supplied to ``mdrun -multidir``).
2286
2287 .. mdp:: disre-weighting
2288
2289    .. mdp-value:: equal
2290
2291       divide the restraint force equally over all atom pairs in the
2292       restraint
2293
2294    .. mdp-value:: conservative
2295
2296       the forces are the derivative of the restraint potential, this
2297       results in an weighting of the atom pairs to the reciprocal
2298       seventh power of the displacement. The forces are conservative
2299       when :mdp:`disre-tau` is zero.
2300
2301 .. mdp:: disre-mixed
2302
2303    .. mdp-value:: no
2304
2305       the violation used in the calculation of the restraint force is
2306       the time-averaged violation
2307
2308    .. mdp-value:: yes
2309
2310       the violation used in the calculation of the restraint force is
2311       the square root of the product of the time-averaged violation
2312       and the instantaneous violation
2313
2314 .. mdp:: disre-fc
2315
2316    (1000) [kJ mol\ :sup:`-1` nm\ :sup:`-2`]
2317    force constant for distance restraints, which is multiplied by a
2318    (possibly) different factor for each restraint given in the ``fac``
2319    column of the interaction in the topology file.
2320
2321 .. mdp:: disre-tau
2322
2323    (0) [ps]
2324    time constant for distance restraints running average. A value of
2325    zero turns off time averaging.
2326
2327 .. mdp:: nstdisreout
2328
2329    (100) [steps]
2330    period between steps when the running time-averaged and
2331    instantaneous distances of all atom pairs involved in restraints
2332    are written to the energy file (can make the energy file very
2333    large)
2334
2335 .. mdp:: orire
2336
2337    .. mdp-value:: no
2338
2339       ignore orientation restraint information in topology file
2340
2341    .. mdp-value:: yes
2342
2343       use orientation restraints, ensemble averaging can be performed
2344       with ``mdrun -multidir``
2345
2346 .. mdp:: orire-fc
2347
2348    (0) [kJ mol\ :sup:`-1`]
2349    force constant for orientation restraints, which is multiplied by a
2350    (possibly) different weight factor for each restraint, can be set
2351    to zero to obtain the orientations from a free simulation
2352
2353 .. mdp:: orire-tau
2354
2355    (0) [ps]
2356    time constant for orientation restraints running average. A value
2357    of zero turns off time averaging.
2358
2359 .. mdp:: orire-fitgrp
2360
2361    fit group for orientation restraining. This group of atoms is used
2362    to determine the rotation **R** of the system with respect to the
2363    reference orientation. The reference orientation is the starting
2364    conformation of the first subsystem. For a protein, backbone is a
2365    reasonable choice
2366
2367 .. mdp:: nstorireout
2368
2369    (100) [steps]
2370    period between steps when the running time-averaged and
2371    instantaneous orientations for all restraints, and the molecular
2372    order tensor are written to the energy file (can make the energy
2373    file very large)
2374
2375
2376 Free energy calculations
2377 ^^^^^^^^^^^^^^^^^^^^^^^^
2378
2379 .. mdp:: free-energy
2380
2381    .. mdp-value:: no
2382
2383       Only use topology A.
2384
2385    .. mdp-value:: yes
2386
2387       Interpolate between topology A (lambda=0) to topology B
2388       (lambda=1) and write the derivative of the Hamiltonian with
2389       respect to lambda (as specified with :mdp:`dhdl-derivatives`),
2390       or the Hamiltonian differences with respect to other lambda
2391       values (as specified with foreign lambda) to the energy file
2392       and/or to ``dhdl.xvg``, where they can be processed by, for
2393       example :ref:`gmx bar`. The potentials, bond-lengths and angles
2394       are interpolated linearly as described in the manual. When
2395       :mdp:`sc-alpha` is larger than zero, soft-core potentials are
2396       used for the LJ and Coulomb interactions.
2397
2398 .. mdp:: expanded
2399
2400    Turns on expanded ensemble simulation, where the alchemical state
2401    becomes a dynamic variable, allowing jumping between different
2402    Hamiltonians. See the expanded ensemble options for controlling how
2403    expanded ensemble simulations are performed. The different
2404    Hamiltonians used in expanded ensemble simulations are defined by
2405    the other free energy options.
2406
2407 .. mdp:: init-lambda
2408
2409    (-1)
2410    starting value for lambda (float). Generally, this should only be
2411    used with slow growth (*i.e.* nonzero :mdp:`delta-lambda`). In
2412    other cases, :mdp:`init-lambda-state` should be specified
2413    instead. Must be greater than or equal to 0.
2414
2415 .. mdp:: delta-lambda
2416
2417    (0)
2418    increment per time step for lambda
2419
2420 .. mdp:: init-lambda-state
2421
2422    (-1)
2423    starting value for the lambda state (integer). Specifies which
2424    columm of the lambda vector (:mdp:`coul-lambdas`,
2425    :mdp:`vdw-lambdas`, :mdp:`bonded-lambdas`,
2426    :mdp:`restraint-lambdas`, :mdp:`mass-lambdas`,
2427    :mdp:`temperature-lambdas`, :mdp:`fep-lambdas`) should be
2428    used. This is a zero-based index: :mdp:`init-lambda-state` 0 means
2429    the first column, and so on.
2430
2431 .. mdp:: fep-lambdas
2432
2433    [array]
2434    Zero, one or more lambda values for which Delta H values will be
2435    determined and written to dhdl.xvg every :mdp:`nstdhdl`
2436    steps. Values must be between 0 and 1. Free energy differences
2437    between different lambda values can then be determined with
2438    :ref:`gmx bar`. :mdp:`fep-lambdas` is different from the
2439    other -lambdas keywords because all components of the lambda vector
2440    that are not specified will use :mdp:`fep-lambdas` (including
2441    :mdp:`restraint-lambdas` and therefore the pull code restraints).
2442
2443 .. mdp:: coul-lambdas
2444
2445    [array]
2446    Zero, one or more lambda values for which Delta H values will be
2447    determined and written to dhdl.xvg every :mdp:`nstdhdl`
2448    steps. Values must be between 0 and 1. Only the electrostatic
2449    interactions are controlled with this component of the lambda
2450    vector (and only if the lambda=0 and lambda=1 states have differing
2451    electrostatic interactions).
2452
2453 .. mdp:: vdw-lambdas
2454
2455    [array]
2456    Zero, one or more lambda values for which Delta H values will be
2457    determined and written to dhdl.xvg every :mdp:`nstdhdl`
2458    steps. Values must be between 0 and 1. Only the van der Waals
2459    interactions are controlled with this component of the lambda
2460    vector.
2461
2462 .. mdp:: bonded-lambdas
2463
2464    [array]
2465    Zero, one or more lambda values for which Delta H values will be
2466    determined and written to dhdl.xvg every :mdp:`nstdhdl`
2467    steps. Values must be between 0 and 1. Only the bonded interactions
2468    are controlled with this component of the lambda vector.
2469
2470 .. mdp:: restraint-lambdas
2471
2472    [array]
2473    Zero, one or more lambda values for which Delta H values will be
2474    determined and written to dhdl.xvg every :mdp:`nstdhdl`
2475    steps. Values must be between 0 and 1. Only the restraint
2476    interactions: dihedral restraints, and the pull code restraints are
2477    controlled with this component of the lambda vector.
2478
2479 .. mdp:: mass-lambdas
2480
2481    [array]
2482    Zero, one or more lambda values for which Delta H values will be
2483    determined and written to dhdl.xvg every :mdp:`nstdhdl`
2484    steps. Values must be between 0 and 1. Only the particle masses are
2485    controlled with this component of the lambda vector.
2486
2487 .. mdp:: temperature-lambdas
2488
2489    [array]
2490    Zero, one or more lambda values for which Delta H values will be
2491    determined and written to dhdl.xvg every :mdp:`nstdhdl`
2492    steps. Values must be between 0 and 1. Only the temperatures
2493    controlled with this component of the lambda vector. Note that
2494    these lambdas should not be used for replica exchange, only for
2495    simulated tempering.
2496
2497 .. mdp:: calc-lambda-neighbors
2498
2499    (1)
2500    Controls the number of lambda values for which Delta H values will
2501    be calculated and written out, if :mdp:`init-lambda-state` has
2502    been set. A positive value will limit the number of lambda points
2503    calculated to only the nth neighbors of :mdp:`init-lambda-state`:
2504    for example, if :mdp:`init-lambda-state` is 5 and this parameter
2505    has a value of 2, energies for lambda points 3-7 will be calculated
2506    and writen out. A value of -1 means all lambda points will be
2507    written out. For normal BAR such as with :ref:`gmx bar`, a value of
2508    1 is sufficient, while for MBAR -1 should be used.
2509
2510 .. mdp:: sc-alpha
2511
2512    (0)
2513    the soft-core alpha parameter, a value of 0 results in linear
2514    interpolation of the LJ and Coulomb interactions
2515
2516 .. mdp:: sc-r-power
2517
2518    (6)
2519    power 6 for the radial term in the soft-core equation.
2520
2521 .. mdp:: sc-coul
2522
2523    (no)
2524    Whether to apply the soft-core free energy interaction
2525    transformation to the Columbic interaction of a molecule. Default
2526    is no, as it is generally more efficient to turn off the Coulomic
2527    interactions linearly before turning off the van der Waals
2528    interactions. Note that it is only taken into account when lambda
2529    states are used, not with :mdp:`couple-lambda0` /
2530    :mdp:`couple-lambda1`, and you can still turn off soft-core
2531    interactions by setting :mdp:`sc-alpha` to 0.
2532
2533 .. mdp:: sc-power
2534
2535    (0)
2536    the power for lambda in the soft-core function, only the values 1
2537    and 2 are supported
2538
2539 .. mdp:: sc-sigma
2540
2541    (0.3) [nm]
2542    the soft-core sigma for particles which have a C6 or C12 parameter
2543    equal to zero or a sigma smaller than :mdp:`sc-sigma`
2544
2545 .. mdp:: couple-moltype
2546
2547    Here one can supply a molecule type (as defined in the topology)
2548    for calculating solvation or coupling free energies. There is a
2549    special option ``system`` that couples all molecule types in the
2550    system. This can be useful for equilibrating a system starting from
2551    (nearly) random coordinates. :mdp:`free-energy` has to be turned
2552    on. The Van der Waals interactions and/or charges in this molecule
2553    type can be turned on or off between lambda=0 and lambda=1,
2554    depending on the settings of :mdp:`couple-lambda0` and
2555    :mdp:`couple-lambda1`. If you want to decouple one of several
2556    copies of a molecule, you need to copy and rename the molecule
2557    definition in the topology.
2558
2559 .. mdp:: couple-lambda0
2560
2561    .. mdp-value:: vdw-q
2562
2563       all interactions are on at lambda=0
2564
2565    .. mdp-value:: vdw
2566
2567       the charges are zero (no Coulomb interactions) at lambda=0
2568
2569    .. mdp-value:: q
2570
2571       the Van der Waals interactions are turned at lambda=0; soft-core
2572       interactions will be required to avoid singularities
2573
2574    .. mdp-value:: none
2575
2576       the Van der Waals interactions are turned off and the charges
2577       are zero at lambda=0; soft-core interactions will be required to
2578       avoid singularities.
2579
2580 .. mdp:: couple-lambda1
2581
2582    analogous to :mdp:`couple-lambda1`, but for lambda=1
2583
2584 .. mdp:: couple-intramol
2585
2586    .. mdp-value:: no
2587
2588       All intra-molecular non-bonded interactions for moleculetype
2589       :mdp:`couple-moltype` are replaced by exclusions and explicit
2590       pair interactions. In this manner the decoupled state of the
2591       molecule corresponds to the proper vacuum state without
2592       periodicity effects.
2593
2594    .. mdp-value:: yes
2595
2596       The intra-molecular Van der Waals and Coulomb interactions are
2597       also turned on/off. This can be useful for partitioning
2598       free-energies of relatively large molecules, where the
2599       intra-molecular non-bonded interactions might lead to
2600       kinetically trapped vacuum conformations. The 1-4 pair
2601       interactions are not turned off.
2602
2603 .. mdp:: nstdhdl
2604
2605    (100)
2606    the frequency for writing dH/dlambda and possibly Delta H to
2607    dhdl.xvg, 0 means no ouput, should be a multiple of
2608    :mdp:`nstcalcenergy`.
2609
2610 .. mdp:: dhdl-derivatives
2611
2612    (yes)
2613
2614    If yes (the default), the derivatives of the Hamiltonian with
2615    respect to lambda at each :mdp:`nstdhdl` step are written
2616    out. These values are needed for interpolation of linear energy
2617    differences with :ref:`gmx bar` (although the same can also be
2618    achieved with the right foreign lambda setting, that may not be as
2619    flexible), or with thermodynamic integration
2620
2621 .. mdp:: dhdl-print-energy
2622
2623    (no)
2624
2625    Include either the total or the potential energy in the dhdl
2626    file. Options are 'no', 'potential', or 'total'. This information
2627    is needed for later free energy analysis if the states of interest
2628    are at different temperatures. If all states are at the same
2629    temperature, this information is not needed. 'potential' is useful
2630    in case one is using ``mdrun -rerun`` to generate the ``dhdl.xvg``
2631    file. When rerunning from an existing trajectory, the kinetic
2632    energy will often not be correct, and thus one must compute the
2633    residual free energy from the potential alone, with the kinetic
2634    energy component computed analytically.
2635
2636 .. mdp:: separate-dhdl-file
2637
2638    .. mdp-value:: yes
2639
2640       The free energy values that are calculated (as specified with
2641       the foreign lambda and :mdp:`dhdl-derivatives` settings) are
2642       written out to a separate file, with the default name
2643       ``dhdl.xvg``. This file can be used directly with :ref:`gmx
2644       bar`.
2645
2646    .. mdp-value:: no
2647
2648       The free energy values are written out to the energy output file
2649       (``ener.edr``, in accumulated blocks at every :mdp:`nstenergy`
2650       steps), where they can be extracted with :ref:`gmx energy` or
2651       used directly with :ref:`gmx bar`.
2652
2653 .. mdp:: dh-hist-size
2654
2655    (0)
2656    If nonzero, specifies the size of the histogram into which the
2657    Delta H values (specified with foreign lambda) and the derivative
2658    dH/dl values are binned, and written to ener.edr. This can be used
2659    to save disk space while calculating free energy differences. One
2660    histogram gets written for each foreign lambda and two for the
2661    dH/dl, at every :mdp:`nstenergy` step. Be aware that incorrect
2662    histogram settings (too small size or too wide bins) can introduce
2663    errors. Do not use histograms unless you're certain you need it.
2664
2665 .. mdp:: dh-hist-spacing
2666
2667    (0.1)
2668    Specifies the bin width of the histograms, in energy units. Used in
2669    conjunction with :mdp:`dh-hist-size`. This size limits the
2670    accuracy with which free energies can be calculated. Do not use
2671    histograms unless you're certain you need it.
2672
2673
2674 Expanded Ensemble calculations
2675 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
2676
2677 .. mdp:: nstexpanded
2678
2679    The number of integration steps beween attempted moves changing the
2680    system Hamiltonian in expanded ensemble simulations. Must be a
2681    multiple of :mdp:`nstcalcenergy`, but can be greater or less than
2682    :mdp:`nstdhdl`.
2683
2684 .. mdp:: lmc-stats
2685
2686    .. mdp-value:: no
2687
2688       No Monte Carlo in state space is performed.
2689
2690    .. mdp-value:: metropolis-transition
2691
2692       Uses the Metropolis weights to update the expanded ensemble
2693       weight of each state. Min{1,exp(-(beta_new u_new - beta_old
2694       u_old)}
2695
2696    .. mdp-value:: barker-transition
2697
2698       Uses the Barker transition critera to update the expanded
2699       ensemble weight of each state i, defined by exp(-beta_new
2700       u_new)/(exp(-beta_new u_new)+exp(-beta_old u_old))
2701
2702    .. mdp-value:: wang-landau
2703
2704       Uses the Wang-Landau algorithm (in state space, not energy
2705       space) to update the expanded ensemble weights.
2706
2707    .. mdp-value:: min-variance
2708
2709       Uses the minimum variance updating method of Escobedo et al. to
2710       update the expanded ensemble weights. Weights will not be the
2711       free energies, but will rather emphasize states that need more
2712       sampling to give even uncertainty.
2713
2714 .. mdp:: lmc-mc-move
2715
2716    .. mdp-value:: no
2717
2718       No Monte Carlo in state space is performed.
2719
2720    .. mdp-value:: metropolis-transition
2721
2722       Randomly chooses a new state up or down, then uses the
2723       Metropolis critera to decide whether to accept or reject:
2724       Min{1,exp(-(beta_new u_new - beta_old u_old)}
2725
2726    .. mdp-value:: barker-transition
2727
2728       Randomly chooses a new state up or down, then uses the Barker
2729       transition critera to decide whether to accept or reject:
2730       exp(-beta_new u_new)/(exp(-beta_new u_new)+exp(-beta_old u_old))
2731
2732    .. mdp-value:: gibbs
2733
2734        Uses the conditional weights of the state given the coordinate
2735        (exp(-beta_i u_i) / sum_k exp(beta_i u_i) to decide which state
2736        to move to.
2737
2738    .. mdp-value:: metropolized-gibbs
2739
2740        Uses the conditional weights of the state given the coordinate
2741        (exp(-beta_i u_i) / sum_k exp(beta_i u_i) to decide which state
2742        to move to, EXCLUDING the current state, then uses a rejection
2743        step to ensure detailed balance. Always more efficient that
2744        Gibbs, though only marginally so in many situations, such as
2745        when only the nearest neighbors have decent phase space
2746        overlap.
2747
2748 .. mdp:: lmc-seed
2749
2750    (-1)
2751    random seed to use for Monte Carlo moves in state space. When
2752    :mdp:`lmc-seed` is set to -1, a pseudo random seed is us
2753
2754 .. mdp:: mc-temperature
2755
2756    Temperature used for acceptance/rejection for Monte Carlo moves. If
2757    not specified, the temperature of the simulation specified in the
2758    first group of :mdp:`ref-t` is used.
2759
2760 .. mdp:: wl-ratio
2761
2762    (0.8)
2763    The cutoff for the histogram of state occupancies to be reset, and
2764    the free energy incrementor to be changed from delta to delta *
2765    :mdp:`wl-scale`. If we define the Nratio = (number of samples at
2766    each histogram) / (average number of samples at each
2767    histogram). :mdp:`wl-ratio` of 0.8 means that means that the
2768    histogram is only considered flat if all Nratio > 0.8 AND
2769    simultaneously all 1/Nratio > 0.8.
2770
2771 .. mdp:: wl-scale
2772
2773    (0.8)
2774    Each time the histogram is considered flat, then the current value
2775    of the Wang-Landau incrementor for the free energies is multiplied
2776    by :mdp:`wl-scale`. Value must be between 0 and 1.
2777
2778 .. mdp:: init-wl-delta
2779
2780    (1.0)
2781    The initial value of the Wang-Landau incrementor in kT. Some value
2782    near 1 kT is usually most efficient, though sometimes a value of
2783    2-3 in units of kT works better if the free energy differences are
2784    large.
2785
2786 .. mdp:: wl-oneovert
2787
2788    (no)
2789    Set Wang-Landau incrementor to scale with 1/(simulation time) in
2790    the large sample limit. There is significant evidence that the
2791    standard Wang-Landau algorithms in state space presented here
2792    result in free energies getting 'burned in' to incorrect values
2793    that depend on the initial state. when :mdp:`wl-oneovert` is true,
2794    then when the incrementor becomes less than 1/N, where N is the
2795    mumber of samples collected (and thus proportional to the data
2796    collection time, hence '1 over t'), then the Wang-Lambda
2797    incrementor is set to 1/N, decreasing every step. Once this occurs,
2798    :mdp:`wl-ratio` is ignored, but the weights will still stop
2799    updating when the equilibration criteria set in
2800    :mdp:`lmc-weights-equil` is achieved.
2801
2802 .. mdp:: lmc-repeats
2803
2804    (1)
2805    Controls the number of times that each Monte Carlo swap type is
2806    performed each iteration. In the limit of large numbers of Monte
2807    Carlo repeats, then all methods converge to Gibbs sampling. The
2808    value will generally not need to be different from 1.
2809
2810 .. mdp:: lmc-gibbsdelta
2811
2812    (-1)
2813    Limit Gibbs sampling to selected numbers of neighboring states. For
2814    Gibbs sampling, it is sometimes inefficient to perform Gibbs
2815    sampling over all of the states that are defined. A positive value
2816    of :mdp:`lmc-gibbsdelta` means that only states plus or minus
2817    :mdp:`lmc-gibbsdelta` are considered in exchanges up and down. A
2818    value of -1 means that all states are considered. For less than 100
2819    states, it is probably not that expensive to include all states.
2820
2821 .. mdp:: lmc-forced-nstart
2822
2823    (0)
2824    Force initial state space sampling to generate weights. In order to
2825    come up with reasonable initial weights, this setting allows the
2826    simulation to drive from the initial to the final lambda state,
2827    with :mdp:`lmc-forced-nstart` steps at each state before moving on
2828    to the next lambda state. If :mdp:`lmc-forced-nstart` is
2829    sufficiently long (thousands of steps, perhaps), then the weights
2830    will be close to correct. However, in most cases, it is probably
2831    better to simply run the standard weight equilibration algorithms.
2832
2833 .. mdp:: nst-transition-matrix
2834
2835    (-1)
2836    Frequency of outputting the expanded ensemble transition matrix. A
2837    negative number means it will only be printed at the end of the
2838    simulation.
2839
2840 .. mdp:: symmetrized-transition-matrix
2841
2842    (no)
2843    Whether to symmetrize the empirical transition matrix. In the
2844    infinite limit the matrix will be symmetric, but will diverge with
2845    statistical noise for short timescales. Forced symmetrization, by
2846    using the matrix T_sym = 1/2 (T + transpose(T)), removes problems
2847    like the existence of (small magnitude) negative eigenvalues.
2848
2849 .. mdp:: mininum-var-min
2850
2851    (100)
2852    The min-variance strategy (option of :mdp:`lmc-stats` is only
2853    valid for larger number of samples, and can get stuck if too few
2854    samples are used at each state. :mdp:`mininum-var-min` is the
2855    minimum number of samples that each state that are allowed before
2856    the min-variance strategy is activated if selected.
2857
2858 .. mdp:: init-lambda-weights
2859
2860    The initial weights (free energies) used for the expanded ensemble
2861    states. Default is a vector of zero weights. format is similar to
2862    the lambda vector settings in :mdp:`fep-lambdas`, except the
2863    weights can be any floating point number. Units are kT. Its length
2864    must match the lambda vector lengths.
2865
2866 .. mdp:: lmc-weights-equil
2867
2868    .. mdp-value:: no
2869
2870       Expanded ensemble weights continue to be updated throughout the
2871       simulation.
2872
2873    .. mdp-value:: yes
2874
2875       The input expanded ensemble weights are treated as equilibrated,
2876       and are not updated throughout the simulation.
2877
2878    .. mdp-value:: wl-delta
2879
2880       Expanded ensemble weight updating is stopped when the
2881       Wang-Landau incrementor falls below this value.
2882
2883    .. mdp-value:: number-all-lambda
2884
2885       Expanded ensemble weight updating is stopped when the number of
2886       samples at all of the lambda states is greater than this value.
2887
2888    .. mdp-value:: number-steps
2889
2890       Expanded ensemble weight updating is stopped when the number of
2891       steps is greater than the level specified by this value.
2892
2893    .. mdp-value:: number-samples
2894
2895       Expanded ensemble weight updating is stopped when the number of
2896       total samples across all lambda states is greater than the level
2897       specified by this value.
2898
2899    .. mdp-value:: count-ratio
2900
2901       Expanded ensemble weight updating is stopped when the ratio of
2902       samples at the least sampled lambda state and most sampled
2903       lambda state greater than this value.
2904
2905 .. mdp:: simulated-tempering
2906
2907    (no)
2908    Turn simulated tempering on or off. Simulated tempering is
2909    implemented as expanded ensemble sampling with different
2910    temperatures instead of different Hamiltonians.
2911
2912 .. mdp:: sim-temp-low
2913
2914    (300) [K]
2915    Low temperature for simulated tempering.
2916
2917 .. mdp:: sim-temp-high
2918
2919    (300) [K]
2920    High temperature for simulated tempering.
2921
2922 .. mdp:: simulated-tempering-scaling
2923
2924    Controls the way that the temperatures at intermediate lambdas are
2925    calculated from the :mdp:`temperature-lambdas` part of the lambda
2926    vector.
2927
2928    .. mdp-value:: linear
2929
2930       Linearly interpolates the temperatures using the values of
2931       :mdp:`temperature-lambdas`, *i.e.* if :mdp:`sim-temp-low`
2932       =300, :mdp:`sim-temp-high` =400, then lambda=0.5 correspond to
2933       a temperature of 350. A nonlinear set of temperatures can always
2934       be implemented with uneven spacing in lambda.
2935
2936    .. mdp-value:: geometric
2937
2938       Interpolates temperatures geometrically between
2939       :mdp:`sim-temp-low` and :mdp:`sim-temp-high`. The i:th state
2940       has temperature :mdp:`sim-temp-low` * (:mdp:`sim-temp-high` /
2941       :mdp:`sim-temp-low`) raised to the power of
2942       (i/(ntemps-1)). This should give roughly equal exchange for
2943       constant heat capacity, though of course things simulations that
2944       involve protein folding have very high heat capacity peaks.
2945
2946    .. mdp-value:: exponential
2947
2948       Interpolates temperatures exponentially between
2949       :mdp:`sim-temp-low` and :mdp:`sim-temp-high`. The i:th state
2950       has temperature :mdp:`sim-temp-low` + (:mdp:`sim-temp-high` -
2951       :mdp:`sim-temp-low`)*((exp(:mdp:`temperature-lambdas`
2952       (i))-1)/(exp(1.0)-i)).
2953
2954
2955 Non-equilibrium MD
2956 ^^^^^^^^^^^^^^^^^^
2957
2958 .. mdp:: freezegrps
2959
2960    Groups that are to be frozen (*i.e.* their X, Y, and/or Z position
2961    will not be updated; *e.g.* ``Lipid SOL``). :mdp:`freezedim`
2962    specifies for which dimension(s) the freezing applies. To avoid
2963    spurious contributions to the virial and pressure due to large
2964    forces between completely frozen atoms you need to use energy group
2965    exclusions, this also saves computing time. Note that coordinates
2966    of frozen atoms are not scaled by pressure-coupling algorithms.
2967
2968 .. mdp:: freezedim
2969
2970    dimensions for which groups in :mdp:`freezegrps` should be frozen,
2971    specify ``Y`` or ``N`` for X, Y and Z and for each group (*e.g.*
2972    ``Y Y N N N N`` means that particles in the first group can move only in
2973    Z direction. The particles in the second group can move in any
2974    direction).
2975
2976 .. mdp:: cos-acceleration
2977
2978    (0) [nm ps\ :sup:`-2`]
2979    the amplitude of the acceleration profile for calculating the
2980    viscosity. The acceleration is in the X-direction and the magnitude
2981    is :mdp:`cos-acceleration` cos(2 pi z/boxheight). Two terms are
2982    added to the energy file: the amplitude of the velocity profile and
2983    1/viscosity.
2984
2985 .. mdp:: deform
2986
2987    (0 0 0 0 0 0) [nm ps\ :sup:`-1`]
2988    The velocities of deformation for the box elements: a(x) b(y) c(z)
2989    b(x) c(x) c(y). Each step the box elements for which :mdp:`deform`
2990    is non-zero are calculated as: box(ts)+(t-ts)*deform, off-diagonal
2991    elements are corrected for periodicity. The coordinates are
2992    transformed accordingly. Frozen degrees of freedom are (purposely)
2993    also transformed. The time ts is set to t at the first step and at
2994    steps at which x and v are written to trajectory to ensure exact
2995    restarts. Deformation can be used together with semiisotropic or
2996    anisotropic pressure coupling when the appropriate
2997    compressibilities are set to zero. The diagonal elements can be
2998    used to strain a solid. The off-diagonal elements can be used to
2999    shear a solid or a liquid.
3000
3001
3002 Electric fields
3003 ^^^^^^^^^^^^^^^
3004
3005 .. mdp:: electric-field-x
3006 .. mdp:: electric-field-y
3007 .. mdp:: electric-field-z
3008
3009    Here you can specify an electric field that optionally can be
3010    alternating and pulsed. The general expression for the field
3011    has the form of a gaussian laser pulse:
3012
3013    .. math:: E(t) = E_0 \exp\left[-\frac{(t-t_0)^2}{2\sigma^2}\right]\cos\left[\omega (t-t_0)\right]
3014
3015    For example, the four parameters for direction x are set in the
3016    fields of :mdp:`electric-field-x` (and similar for ``electric-field-y``
3017    and ``electric-field-z``) like
3018
3019    ``electric-field-x  = E0 omega t0 sigma``
3020
3021    with units (respectively) V nm\ :sup:`-1`, ps\ :sup:`-1`, ps, ps.
3022
3023    In the special case that ``sigma = 0``, the exponential term is omitted
3024    and only the cosine term is used. In this case, ``t0`` must be set to 0.
3025    If also ``omega = 0`` a static electric field is applied.
3026
3027    Read more at :ref:`electric fields` and in ref. \ :ref:`146 <refCaleman2008a>`.
3028
3029
3030 Mixed quantum/classical molecular dynamics
3031 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3032
3033 .. mdp:: QMMM-grps
3034
3035    groups to be descibed at the QM level for MiMiC QM/MM
3036
3037 .. MDP:: QMMM
3038
3039    .. mdp-value:: no
3040
3041       QM/MM is no longer supported via these .mdp options. For MiMic, use no here.
3042
3043 Computational Electrophysiology
3044 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3045 Use these options to switch on and control ion/water position exchanges in "Computational
3046 Electrophysiology" simulation setups. (See the `reference manual`_ for details).
3047
3048 .. mdp:: swapcoords
3049
3050    .. mdp-value:: no
3051
3052       Do not enable ion/water position exchanges.
3053
3054    .. mdp-value:: X ; Y ; Z
3055
3056       Allow for ion/water position exchanges along the chosen direction.
3057       In a typical setup with the membranes parallel to the x-y plane,
3058       ion/water pairs need to be exchanged in Z direction to sustain the
3059       requested ion concentrations in the compartments.
3060
3061 .. mdp:: swap-frequency
3062
3063    (1) The swap attempt frequency, i.e. every how many time steps the ion counts
3064    per compartment are determined and exchanges made if necessary.
3065    Normally it is not necessary to check at every time step.
3066    For typical Computational Electrophysiology setups, a value of about 100 is
3067    sufficient and yields a negligible performance impact.
3068
3069 .. mdp:: split-group0
3070
3071    Name of the index group of the membrane-embedded part of channel #0.
3072    The center of mass of these atoms defines one of the compartment boundaries
3073    and should be chosen such that it is near the center of the membrane.
3074
3075 .. mdp:: split-group1
3076
3077    Channel #1 defines the position of the other compartment boundary.
3078
3079 .. mdp:: massw-split0
3080
3081    (no) Defines whether or not mass-weighting is used to calculate the split group center.
3082
3083    .. mdp-value:: no
3084
3085       Use the geometrical center.
3086
3087    .. mdp-value:: yes
3088
3089       Use the center of mass.
3090
3091 .. mdp:: massw-split1
3092
3093    (no) As above, but for split-group #1.
3094
3095 .. mdp:: solvent-group
3096
3097    Name of the index group of solvent molecules.
3098
3099 .. mdp:: coupl-steps
3100
3101    (10) Average the number of ions per compartment over these many swap attempt steps.
3102    This can be used to prevent that ions near a compartment boundary
3103    (diffusing through a channel, e.g.) lead to unwanted back and forth swaps.
3104
3105 .. mdp:: iontypes
3106
3107    (1) The number of different ion types to be controlled. These are during the
3108    simulation exchanged with solvent molecules to reach the desired reference numbers.
3109
3110 .. mdp:: iontype0-name
3111
3112    Name of the first ion type.
3113
3114 .. mdp:: iontype0-in-A
3115
3116    (-1) Requested (=reference) number of ions of type 0 in compartment A.
3117    The default value of -1 means: use the number of ions as found in time step 0
3118    as reference value.
3119
3120 .. mdp:: iontype0-in-B
3121
3122    (-1) Reference number of ions of type 0 for compartment B.
3123
3124 .. mdp:: bulk-offsetA
3125
3126    (0.0) Offset of the first swap layer from the compartment A midplane.
3127    By default (i.e. bulk offset = 0.0), ion/water exchanges happen between layers
3128    at maximum distance (= bulk concentration) to the split group layers. However,
3129    an offset b (-1.0 < b < +1.0) can be specified to offset the bulk layer from the middle at 0.0
3130    towards one of the compartment-partitioning layers (at +/- 1.0).
3131
3132 .. mdp:: bulk-offsetB
3133
3134    (0.0) Offset of the other swap layer from the compartment B midplane.
3135
3136
3137 .. mdp:: threshold
3138
3139    (\1) Only swap ions if threshold difference to requested count is reached.
3140
3141 .. mdp:: cyl0-r
3142
3143    (2.0) [nm] Radius of the split cylinder #0.
3144    Two split cylinders (mimicking the channel pores) can optionally be defined
3145    relative to the center of the split group. With the help of these cylinders
3146    it can be counted which ions have passed which channel. The split cylinder
3147    definition has no impact on whether or not ion/water swaps are done.
3148
3149 .. mdp:: cyl0-up
3150
3151    (1.0) [nm] Upper extension of the split cylinder #0.
3152
3153 .. mdp:: cyl0-down
3154
3155    (1.0) [nm] Lower extension of the split cylinder #0.
3156
3157 .. mdp:: cyl1-r
3158
3159    (2.0) [nm] Radius of the split cylinder #1.
3160
3161 .. mdp:: cyl1-up
3162
3163    (1.0) [nm] Upper extension of the split cylinder #1.
3164
3165 .. mdp:: cyl1-down
3166
3167    (1.0) [nm] Lower extension of the split cylinder #1.
3168
3169 Density-guided simulations
3170 ^^^^^^^^^^^^^^^^^^^^^^^^^^
3171
3172 These options enable and control the calculation and application of additional
3173 forces that are derived from three-dimensional densities, e.g., from cryo
3174 electron-microscopy experiments. (See the `reference manual`_ for details)
3175
3176 .. mdp:: density-guided-simulation-active
3177
3178    (no) Activate density-guided simulations.
3179
3180 .. mdp:: density-guided-simulation-group
3181
3182    (protein) The atoms that are subject to the forces from the density-guided
3183    simulation and contribute to the simulated density.
3184
3185 .. mdp:: density-guided-simulation-similarity-measure
3186
3187    (inner-product) Similarity measure between the density that is calculated
3188    from the atom positions and the reference density.
3189
3190    .. mdp-value:: inner-product
3191
3192       Takes the sum of the product of reference density and simulated density
3193       voxel values.
3194
3195    .. mdp-value:: relative-entropy
3196
3197       Uses the negative relative entropy (or Kullback-Leibler divergence)
3198       between reference density and simulated density as similarity measure.
3199       Negative density values are ignored.
3200
3201    .. mdp-value:: cross-correlation
3202
3203       Uses the Pearson correlation coefficient between reference density and
3204       simulated density as similarity measure.
3205
3206 .. mdp:: density-guided-simulation-atom-spreading-weight
3207
3208    (unity) Determines the multiplication factor for the Gaussian kernel when
3209    spreading atoms on the grid.
3210
3211    .. mdp-value:: unity
3212
3213       Every atom in the density fitting group is assigned the same unit factor.
3214
3215    .. mdp-value:: mass
3216
3217       Atoms contribute to the simulated density proportional to their mass.
3218
3219    .. mdp-value:: charge
3220
3221       Atoms contribute to the simulated density proportional to their charge.
3222
3223 .. mdp:: density-guided-simulation-force-constant
3224
3225    (1e+09) [kJ mol\ :sup:`-1`] The scaling factor for density-guided simulation
3226    forces. May also be negative.
3227
3228 .. mdp:: density-guided-simulation-gaussian-transform-spreading-width
3229
3230    (0.2) [nm] The Gaussian RMS width for the spread kernel for the simulated
3231    density.
3232
3233 .. mdp:: density-guided-simulation-gaussian-transform-spreading-range-in-multiples-of-width
3234
3235    (4) The range after which the gaussian is cut off in multiples of the Gaussian
3236    RMS width described above.
3237
3238 .. mdp:: density-guided-simulation-reference-density-filename
3239
3240    (reference.mrc) Reference density file name using an absolute path or a path
3241    relative to the to the folder from which :ref:`gmx mdrun` is called.
3242
3243 .. mdp:: density-guided-simulation-nst
3244
3245    (1) Interval in steps at which the density fitting forces are evaluated
3246    and applied. The forces are scaled by this number when applied (See the
3247    `reference manual`_ for details).
3248
3249 .. mdp:: density-guided-simulation-normalize-densities
3250
3251    (true) Normalize the sum of density voxel values to one for the reference
3252    density as well as the simulated density.
3253
3254 .. mdp:: density-guided-simulation-adaptive-force-scaling
3255
3256    (false) Adapt the force constant to ensure a steady increase in similarity
3257    between simulated and reference density.
3258
3259    .. mdp-value: false
3260
3261       Do not use adaptive force scaling.
3262
3263    .. mdp-value:: true
3264
3265       Use adaptive force scaling.
3266
3267 .. mdp:: density-guided-simulation-adaptive-force-scaling-time-constant
3268
3269    (4) [ps] Couple force constant to increase in similarity with reference density
3270    with this time constant. Larger times result in looser coupling.
3271
3272 .. mdp:: density-guided-simulation-shift-vector
3273
3274    (0,0,0) [nm] Add this vector to all atoms in the 
3275    density-guided-simulation-group before calculating forces and energies for
3276    density-guided-simulations. Affects only the density-guided-simulation forces
3277    and energies. Corresponds to a shift of the input density in the opposite
3278    direction by (-1) * density-guided-simulation-shift-vector.
3279
3280 .. mdp:: density-guided-simulation-transformation-matrix
3281
3282    (1,0,0,0,1,0,0,0,1) Multiply all atoms with this matrix in the 
3283    density-guided-simulation-group before calculating forces and energies for
3284    density-guided-simulations. Affects only the density-guided-simulation forces
3285    and energies. Corresponds to a transformation of the input density by the
3286    inverse of this matrix. The matrix is given in row-major order.
3287    This option allows, e.g., rotation of the density-guided atom group around the
3288    z-axis by :math:`\theta` degress by using following input:
3289    :math:`(\cos \theta , -\sin \theta , 0 , \sin \theta , \cos \theta , 0 , 0 , 0 , 1)` .
3290
3291 User defined thingies
3292 ^^^^^^^^^^^^^^^^^^^^^
3293
3294 .. mdp:: user1-grps
3295 .. mdp:: user2-grps
3296 .. mdp:: userint1 (0)
3297 .. mdp:: userint2 (0)
3298 .. mdp:: userint3 (0)
3299 .. mdp:: userint4 (0)
3300 .. mdp:: userreal1 (0)
3301 .. mdp:: userreal2 (0)
3302 .. mdp:: userreal3 (0)
3303 .. mdp:: userreal4 (0)
3304
3305    These you can use if you modify code. You can pass integers and
3306    reals and groups to your subroutine. Check the inputrec definition
3307    in ``src/gromacs/mdtypes/inputrec.h``
3308
3309 Removed features
3310 ^^^^^^^^^^^^^^^^
3311
3312 These features have been removed from |Gromacs|, but so that old
3313 :ref:`mdp` and :ref:`tpr` files cannot be mistakenly misused, we still
3314 parse this option. :ref:`gmx grompp` and :ref:`gmx mdrun` will issue a
3315 fatal error if this is set.
3316
3317 .. mdp:: adress
3318
3319    (no)
3320
3321 .. mdp:: implicit-solvent
3322
3323    (no)
3324
3325 .. _reference manual: gmx-manual-parent-dir_