QM/MM Thermodynamic Integration
QM/MM Thermodynamic Integration
The average of the difference in energy between the MM and QM/MM representations sampled at a particular value of λ is actually equal to the gradient of the free energy with respect to λ at that value of λ. You can see this here;
Equation 1 uses λ to combine the QM/MM and MM models together into a single expression that gives an energy that depends on λ. This is the expression you were using in step 4. Simply differentiating this with respect to λ gives us equation 2, which shows that the gradient of the energy with respect to λ is just the difference between the MM and QM/MM energies.
Equation 3 is the standard equation of thermodynamic integration. It says that the gradient of the free energy (dG/dλ) at a particular value of λ is equal to the average of the gradient of the energy with respect to λ, sampled at that value of λ. The angle brackets with subscript λ mean “average collected from a simulation at λ”, where the simulation could be Monte Carlo or Molecular Dynamics (or anything that samples from the Boltzmann distribution).
Simply substituting equation 2 into equation 3 gives us equation 4, which says that the gradient of the free energy with respect to λ at a particular value of λ is the average of the difference in energy between the MM and QM/MM models collected from a simulation at that λ value.
So, now that we have the free energy gradients, how can we use them? The answer is to simply calculate the gradients at different values of λ and then integrate them from λ = 0 to λ = 1. This is shown in equation 5 below.
Substituting equation 4 into equation 5 gives us equation 6. This tells us that we can calculate the difference in free energy to move from the QM/MM to MM model by running multiscale Monte Carlo (or QM/MM Molecular Dynamics) simulations at different values of λ and collecting the average difference in energy between the MM and QM/MM models at those values of λ. Integrating these averages from λ = 0 to λ = 1 (e.g. via quadrature, trapezium rule or other gradient fitting and integration schemes) gives the free energy we desire.