IMP  2.3.1
The Integrative Modeling Platform
container/bipartite_nonbonded_interactions.py

This example shows how set up excluded volume interactions between two sets of particles.

1 ## \example container/bipartite_nonbonded_interactions.py
2 # This example shows how set up excluded volume interactions between two
3 # sets of particles.
4 
5 import IMP
6 import IMP.core
7 import IMP.container
8 
9 # This example addes a restraint on bipartite nonbonded interactions
10 # after excluding a set of bonded interactions.
11 
12 m = IMP.kernel.Model()
13 # The set of particles
18 
19 # Set up the nonbonded list
21 
22 # Set up excluded volume
24 evr = IMP.container.PairsRestraint(ps, nbl)
25 m.add_restraint(evr)
26 
27 # Set up optimizer
29 
30 o.optimize(1000)