[MMTK] question on printing out all non-bonded interactions
fox at cs.umass.edu
Wed Feb 1 20:43:17 UTC 2012
I would like to efficiently print out each non-bonded atom pair interaction
and its associated LJ and coulombic potentials.
I have used the example the MMTK file
'Examples/Miscellaneous/force_field_parameters.py' as a template.
I am able to get the set in an O(n^2) fashion as so:
nonbondedparams = parameters['nonbonded']
allatoms = universe.atomCollection()
notexcludedlj = 
for i in range(0, universe.numberOfAtoms()):
for j in range(i+1, universe.numberOfAtoms() ):
energyterms = universe.energyTerms(allatoms[i], allatoms[j])
if (i,j) in nonbondedparams['excluded_pairs'] or (i,j) in
print i, j, "excluded or one_four_pair"
print i, j, energyterms['Lennard-Jones']
How do I get all the atom pairs with a distance below some cutoff?
Do the forcefields, for example Amber99, maintain some internal list of
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the mmtk