We are going to start with the simplified example of isolated $\text{Na}^+$ and $\text{Cl}^-$ in the gas phase, where we can directly compare the results of our computer simulation against the analytical formulae used to describe the interaction potential.
We have provided an input file NaCl_pot.in
and a script potential_energy.sh
that uses this input file to calculate the potential energy as a function of Na-Cl distance.
NaCl_pot.in
and write down the formula used for the potential energy of the interaction between $\text{Na}^+$ and $\text{Cl}^-$ in Hartree atomic units. (2P)./potential_energy.sh
to calculate the potential energy as a function of Na-Cl distance. Create a plot of the resulting potential energy profile in pot_profile
and the mathematical formula.For the next task, we remain with our simple system, but now perform molecular dynamics at $T=1\,\text{K}$.
We have prepared a script free_energy.sh
, which runs MD simulations with constrained Na-Cl distance at $1\,\text{K}$.
It then integrates the average value of the Shake Lagrange multiplier to calculate the (low-temperature) free energy profile.
fe_profile
with the potential energy profile. Do the two profiles agree? Note: The profiles are shifted with respect to each other. What would be a reasonable reference point for both profiles? (2P)Now, we are ready to move to a more realistic system – NaCl in water. We have performed constrained MD of NaCl in water and saved the trajectory of the corresponding Lagrange multipliers (ask your teaching assistant).
The script ./integrate.sh
computes the average values of the Shake Lagrange multipliers and uses them to perform the free energy integration.
Another way to gain access to the free energy is through the radial distribution function (rdf) of the unconstrained system. The rdf $g(r)$ is related to the free energy $F(r)$ through the following set of equations $$\begin{eqnarray} g(r)4\pi r^2 &\propto& \int \delta(r-r') \exp(-\beta H(r'))\,dr \\ P(r) &\propto& \int \delta(r-r') \exp(-\beta H(r'))\,dr \\ F(r) &=& -k_BT \ln\,P(r) \end{eqnarray}$$
We have performed a trajectory spanning 50 ns of unconstrained molecular dynamics of NaCl in water (ask your teaching assistant). The individual frames are spaced by 1 ps in order to reduce correlation between subsequent frames.