The following note describes a number of VMD-related tasks which are quite useful for conducting graphene computational research using LAMMPS.
Creation of a structure file for regular graphene
- Open VMD and choose Extensions < Modeling < Nanotube Builder.
- Set the desired values in Graphene Sheet Building Options, for instance,
10,10,1to create a graphene monolayer of size 10 nm by 10 nm. - Select Save coordinates… > Set file type as XYZ.
Creation of a structure file for multi-layered graphene with defects
- Use the trajectory file generated in the previous task to serve as input to a custom Python script which should produce several other trajectory files corresponding to graphene sheets with varying levels of topological defects.
- In a text editor, modify the z-axis values of each file to some preferred value.
- Merge the atom coordinates into a single file:
cat file1.xyz file2.xyz file3.xyz >> combined.xyzCreation of a structure file for folded graphene
For this task, one must consider the chirality and symmetry of the carbon nanotube, since folded graphene is conceptually regular graphene stitched to half a CNT. Run the following commands from within the Tcl console of VMD:
nanotube -l 0.3 -n 0 -m 4 -cc 0.1418 -ma C-Cgraphene -lx 0.368 -ly 0.1228 -type zigzag -cc 0.1418 -ma C-Cset sheet [atomselect all]measure minmax $sheet $sheet moveby {1 0 0} $sheet move [transaxis y -90]
For reference purposes, these are the atomic distances of the two forms of regular graphene:
where n represents the number of 4-carbon fragments
Creation of a LAMMPS data file
- Load a trajectory file in VMD.
- From within the Tcl console, run:
[atomselect top "all"] set type Ctopo writelammpsdata /path/to/file.data atomicSetting the atomic flag ensures that any bond information is excluded from the generated data file so as not to interfere with the bond interactions which would be dynamically created by the AEREBO potential during a LAMMPS simulation. This, however, may be undesirable if a different potential were to be used, hence it is advisable to consult the LAMMPS manual beforehand to ascertain that manual bond assignment is actually not required.
Visualisation of a LAMMPS simulation output
- From within the Tcl console, load the
.datafile generated in the previous task:cd /path/to/working/dirtopo readlammpsdata <output>.data molecular - To display the simulation box, run:
pbc box
- Set the number of images to show and check the relevant axes by choosing Graphic > Representations > Periodic tab…