I have pdb/psf files that I usually use to create lammps data files with VMD/topotools. Recently, I've been considering working with the OPLSAA force field. I'm particularly interested in the possibility to use the oplsaa.prm file from TINKER. Going through the mailing list (http://lammps.sandia.gov/threads/msg50155.html) I learned that Moltemplate offers ways to do so by building molecules and chains from scratch, defining atom positions and bonds and letting the "force field" define the rest with a set of rules. But this involves using moltemplate's language and commands to build the chains.
Is it possible to work from an existing pdb/psf file already containing positions and topology? The idea being to minimize the "manual" intervention.
Off course I would also be grateful for any suggestion other than the moltemplate solution.
I contacted you back directly, but I just noticed that you also posted this question on the list. So I’m replying to that as well. Currently, the answer is (unfortunately) no. Not yet, at least.
Converting PDB files automatically requires being familiar with the nomenclature used by the PDB file (there are at least 2 popular ones), as well as being intimately familiar with the particular force-field. Moltemplate is not specific to the OPLS force field. (The goal was to set up simulations for any force-field.) As a result, moltemplate usually ends up being difficult to use for any of the force fields that t does support.
However, if you are simulating a protein, then creating a script which can automatically assign atom types from PDB files should not be too difficult case of OPLS. This is because there are numerous “biotype” comments at the end of the “oplsaa.lt” file (as well as the “oplsaa.prm” file) which indicate which atom type should be used for all of the atoms in the 20 amino acids. Such a script could build a moltemplate (.lt) file and choose the correct “@atom:” types from the “oplsaa.lt” file, and read the coordinates from the columns of the PDB file.) Incidentally, if somebody wants to write such a script, I am happy to include their name in the author list of a forthcoming paper on moltemplate I plan to submit soon. I am about to send another email on this topic…