PyPot: base class used by potential terms written in Python. to write a potential term in Python, define a class which derives from pyPot.PyPot, and make sure to call the base class' constructor. Then, the new class should define two methods: calcEnergy, and calcEnergyAndDerivs(DerivList). Here is a trivial example: from pyPot import PyPot class ConstEnergy(PyPot): def __init__(s,instanceName,constVal): PyPot.__init__(s,instanceName,s) s.val = constVal return def calcEnergy(s): return s.val def calcEnergyAndDerivs(s,derivs): return s.val