Modelling and extracting data file for running lammps script

I want to do molecular dynamics simulations on Perovskite materials. But for that I need data files for those materials.How can I get those data files? Where can I model them?
I used VMD for graphene and Boron Nitride. But can’t find other materials there,

If you are lucky enough, you can find already formated file. Otherwise, you have to write those files yourself based on existing publications. Depending on your system, this can be easy, or it can be a real pain.

Can you explain what you mean by “write those files” ?

Sometimes you have to write the input files yourself, based on the information given in the pdf of publication. Thats not pleasant, but thats doable.

You could create such a data file directly with LAMMPS using the lattice, create_atoms, and region commands. For that you need to look up the specific crystal structure you want to model and then translate that into a custom lattice. That may be a bit of work, since it is generally beneficial to build a conventional cell with LAMMPS, while publications or text books tend to have primitive cells.

As an alternative, you may want to write a little script program to generate those coordinates yourself and then you just need to create an output that is the correct data file format. A detailed description of the format is in the documentation for the read_data command.

Another option is to use some pre-processing tools. Atomsk seems to be particularly suitable for crystal structures, but others may be suitable as well. Please see Pre/Post Processing Tools for use with LAMMPS for a list of tools known to the LAMMPS developers.

You should not expect that there is anything conveniently ready to use for all but the most trivial geometries or that there are tools where you just have to say “I want this” and then the tool will figure out the rest for you. If you want to do simulations of a more complex material, chances are, you have to invest some more effort to get there.

1 Like

Thanks a lot!