Derivative of Dihedral potential in molecular simulation

23 Views Asked by At

I am working on a problem in the context of molecular simulation. I consider various potentials and compute the resulting forces on each of the atoms in my simulation. I managed to do this for the bond potential and the angle potential. I am stuck however on the dihedral potential.

I have the dihedral potential given as, $$V(\psi)=\frac{1}{2}\left(C_{1}(1+\cos(\psi))+C_{2}(1-\cos(2\psi))+C_{3}(1+\cos(3\psi))+C_{4}(1-\cos(4\psi))\right).$$ The force on atom is given by $F_{i}=-\frac{\partial V(\psi)}{\partial r_{i}}$, where $r_{i}$ is the position vector of atom $i$, and note that $\psi=\theta_{ijkl}-180^{°}$, where $\theta_{ijkl}$ is the dihedral angle between the planes spanned by $i,j,k$ and $j,k,l$.

My approach is now to use that $\frac{\partial V(\psi)}{\partial r_{i}}=\frac{\partial V(\psi)}{\partial \psi}\cdot\frac{\partial \psi}{\partial r_{i}}$. The first partial derivative I can compute simply as, $$\frac{\partial V(\psi)}{\partial \psi}=\frac{1}{2}(-C_{1}\sin(\psi)+2C_{2}\sin(2\psi)-3C_{3}\sin(3\psi)+4C_{4}\sin(4\psi)).$$

Now to compute $\frac{\partial \psi}{\partial r_{i}}$ I first define $\theta_{ijkl}$, this I believe is defined by, $$\theta_{ijkl}=\arccos\left(\frac{(r_{ij}\times r_{jk})\cdot (r_{jk}\times r_{kl})}{\|r_{ij}\times r_{jk}\|\|r_{jk}\times r_{kl}\|}\right),$$ where $r_{ij}=r_{j}-r_{i}$. Now similairly as before I use that $\frac{\partial \psi}{\partial r_{i}}=\frac{\partial \psi}{\partial r_{ij}}\cdot\frac{\partial r_{ij}}{\partial r_{i}}$, where $\frac{\partial r_{ij}}{\partial r_{i}}=-1$. Now this is the part where I get stuck. I am unsure how to compute the partial derivative $\frac{\partial \psi}{\partial r_{ij}}$.

Is my work so far the correct approach? If so, how should I proceed?