Reviewing the source code hierarchy
The topmost-level class in the source code hierarchy is lammps.cpp
(and lammps.h
), which initiates LAMMPS by accommodating an instance of LAMMPS. In doing so, lammps.cpp
allocates fundamental classes that are accessible throughout the code, as shown in the following screenshot:
This instantiation is invoked by the main.cpp
file, which also conveys the input script to this instance of LAMMPS for subsequent execution, as shown in the following screenshot:
The rest of the simulation setup is performed by several other top-level classes, some of which are described here in brief:
memory.cpp
: Creates and destroys multi-dimensional arrayserror.cpp
: Prints errors and warning messages and aborts simulationuniverse.cpp
: Creates and initializes partitions to divide and assign simulation domains...