I used to work with a Diameter restraint in the past using IMP version
2.2 where I specified in a XML file the *max_diameter* and *std_dev*
between pairs of particles. I would like to know how to use this
function with the latest version of IMP (2.12).
XML input implies you were using IMP.restrainer, which was removed from
the code a long long time ago. But IMP.core.DiameterRestraint is still
there:
DiameterRestraint takes an input a UnaryFunction (usually we use
IMP.core.HarmonicUpperBound) and a SingletonContainer. If you just have
a simple list of particles you want to restrain, use
IMP.container.ListSingletonContainer.
Also I would be grateful to know which is the main difference between
the DiameterRestraint and the Harmonic Upper Bound
HarmonicUpperBound scores the distance between two particles, keeping
them from exceeding a certain distance. DiameterRestraint scores the
distance between each of a set of particles and the center of mass.
and how to justify a
given k value when using the HarmonicUpperBound restraint.
The larger the value of k the less likely particles are to exceed the
diameter.