Assigning atom type to each layer of multilayer structure

Dear All,

Does anyone know how can I assign the atom type in structure data file in a fast way?

I am building a structure with N layers of graphene sheets and to consider the interlayer interactions and using hybrid pair_style I have to assign type 1,2 ,…N to each sheet but I have lots of atoms and doing it manually is taking much time.

Thanks.

Best regards,

Nima Pirouzmand

Dear All,
Does anyone know how can I assign the atom type in structure data file in
a fast way?
I am building a structure with N layers of graphene sheets and to consider
the interlayer interactions and using hybrid pair_style I have to assign
type 1,2 ,...N to each sheet but I have lots of atoms and doing it manually
is taking much time.

​you can use a programmable editor (e.g. emacs) or and editor with advanced
regexp based editing/repl​acing capabilities (e.g. vim or emacs).

​you can write a script to process or even generate your data file. some
people do this in python or perl. there also is the topotools plugin in
VMD, that can be used with Tcl scripting to customize topology/atom data.

you can use LAMMPS commands to assign (and delete) a region so it
encompasses a layer and then change the type of the atoms in that region.

axel.