views:

348

answers:

6

I am searching for a python package that I can use to simulate molecular dynamics in non-equilibrium situations. I need a setup that can handle a fairly large number of molecules in a primarily kinetic theory manner, and that can handle having solid surfaces present. With regards to the surfaces, I would need to be able to create arbitrary shapes and monitor pressure and other variables resulting from the molecular action. Alternatively, I could add the surface parts myself if I had molecules that could handle it.

Does anyone know of any packages that might be suitable?

+2  A: 

Have you considered SimPy? SimPy is a rather generic Discrete Event Simulation package, but could feasibly meet your needs.

Better yet the Molecular Modelling ToolKit (MMTK) seems more specialized...

I have used neither, but this sounds like fun. Python, as a language, seems to be in privileged position for use in simulation software, whereby people can script the specific details of their model while relying on the framework for all the common logic, such as scheduling, visualization, monitoring etc. The unknown is how well such toolkits scale when fed with agent counts commensurate with biology models (BTW, how "big" is that?)

mjv
@mjv: biological agent counts tend to be in the millions at best, but large-scale chemical engineering problems can be _much_ bigger.
Chinmay Kanchi
A: 

I don't know if that programs does all the features you need but there is avogadro in the kde programs, i think it is extendable and since it is open source you could do anything with it. http://www.kde-apps.org/content/show.php/Avogadro?content=59521

It is really advanced and programmed by a friend of mine

pastjean
A: 

Lampps and gromacs are two well known molecular dynamics codes. These codes both have some python based wrapper stuff, but I am not sure how much functionality the wrappers expose. They may not give you enough control over the simulation.

Google for "GromacsWrapper" or google for "lammps" and "pizza.py"

Digital material and ASE are two molecular dynamics codes that expose a lot of functionality, but last time I looked, they were both fairly specialized. They may not allow you to use the force potentials that you want

Google for "digital material" and "cornell" or google for "ase" and dtu

Note to MJV: Normal MD-codes take one time step at a time, and they move all particles in each time step. Most of the time is spend calculating the total force on each atom. This involves iterating over a list of pairs of neighboring atoms. I think the best idea is to do the force calculation and a few more basics in c++ or fortran and then wrap that functionality in python. (But it could be fun to see how far one can get by using numpy matrices)

niels
A: 

I second MMTK, but take a look at VMD, which is the best MD software I'm aware of, and is Python-scriptable (in addition to Tk). See this for examples and tutorials.

piobyz
VMD is more for biological systems. I've clarified what I'm looking for a bit.
Elliot
+1  A: 

Another generic simulations framework is my own GarlicSim. You can try that. I could help you get a simpack up if you're serious about it.

cool-RR
A: 

this could help you

http://pyode.sourceforge.net/

Werner