How to generate a OPLS Lammps input?

Hello everyone, I would like to start simulations involving OPLS force field, could anyone help me on how I should create an input Lammps to perform this type of simulation?

First step is to read the publications of the OPLS force field(s) and understanding the “rules” how parameters are selected and assigned and atom types determined. This is crucial. There are ways to automate part of the process, but without a good understanding of these basics, it is going to be impossible to debug and verify any output from such tools. Depending on the complexity of the system, (small) errors from (semi-)automated tools are likely.

You need to figure out ways to build geometries and then assign atom types and charges. There are different approaches to this. LAMMPS can be used to build systems from small molecule “templates”, but also external tools like Packmol or moltemplate can be used. As part of the project atom types and (partial) charges need to be determined and assigned and then usually you will assemble this into a data file. Again, moltemplate can help with this but also the TopoTools plugin for VMD. Depending on your own programming skills, you may also consider writing your own tools to build custom data files specific for your needs.

Of course, you want to start with simple systems for which the results are known and thus you can verify your workflow and then gradually add complexity and improve your skills. This is a learning process not just a simple A, then B, then C procedure with simple “rules”.

Check out https://www.lammps.org/prepost.html

To add to what Axel already said. In #moltemplate, you have a folder with the standard parameters of many force fields, including OPLS. Assuming you know what you need to do, the steps will be to define the topology of every single molecular species (e.g. one LT file describing a water molecule, one for methanol, and so on), an input system (created directly in moltemplate or with an external molecular modelling program and then imported as PDB or XYZ), and finally a good understanding of the mixing rules, cutoff radii and stuff required by OPLS. Have fun!

Thank You @akohlmey

Thank You @hothello