Created
June 13, 2018 21:09
-
-
Save schneiderfelipe/8e0293e0646fcaa572aa034478148dfd to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import numpy as np | |
from matplotlib import pyplot as plt | |
def dihedral_pot(phi, v_barrier=1., n=3., phase=0., divider=1.): | |
return v_barrier * (1. + np.cos(n * phi - phase)) / divider | |
phi = np.linspace(0., 2. * np.pi, num=50) | |
energy = dihedral_pot(phi) + dihedral_pot(phi, n=1.) | |
plt.plot(phi, energy, 'b--') | |
plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment