Skip to content

Commit ef1f5d8

Browse files
committed
small tweaks and improve figure placement and layout in tutorial 1
1 parent 7df0a12 commit ef1f5d8

1 file changed

Lines changed: 31 additions & 27 deletions

File tree

lammps-tutorials.tex

Lines changed: 31 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -752,13 +752,14 @@ \subsubsection{My first input}
752752
local minimum rather than the global minimum.
753753

754754
Run the minimization and observe that \lammpsgui{} captures the output
755-
and update the chart in real time (see Fig.~\ref{fig:chart-log}). This run executes quickly (depending
756-
on your computer's capabilities), but \lammpsgui{} may fail to capture some
757-
of the thermodynamic data. In that
758-
case, use the \guicmd{Preferences} dialog to reduce the data update
759-
interval and switch to single-threaded, unaccelerated execution in the
760-
\guicmd{Accelerators} tab. You can repeat the run; each new attempt will start
761-
fresh, resetting the system and re-executing the script from the beginning.
755+
and update the chart in real time (see Fig.~\ref{fig:chart-log}). This
756+
run executes quickly (depending on your computer's capabilities)
757+
{\color{blue}and thus} \lammpsgui{} may fail to capture some of the
758+
thermodynamic data. In that case, use the \guicmd{Preferences} dialog
759+
to reduce the data update interval and switch to single-threaded,
760+
unaccelerated execution in the \guicmd{Accelerators} tab. You can
761+
repeat the run; each new attempt will start fresh, resetting the system
762+
and re-executing the script from the beginning.
762763

763764
\begin{figure}
764765
\centering
@@ -782,18 +783,18 @@ \subsubsection{My first input}
782783
negative value. This indicates that the atoms have moved to reasonable
783784
distances from one another.
784785

785-
Create and save a snapshot image of the simulation state after the
786-
minimization, and compare it to the initial image. You should observe
787-
that the atoms are ``clumping together'' as they move toward positions
788-
of lower potential energy.
789-
790786
\begin{note}
791787
Since the \lmpcmd{thermo\_style} command also includes the \lmpcmd{press}
792788
keyword, you can switch from plotting the total energy to
793789
displaying the pressure by selecting \guicmd{Press} in the \guicmd{Select data}
794790
drop-down menu of the \guicmd{Charts} window.
795791
\end{note}
796792

793+
Create and save a snapshot image of the simulation state after the
794+
minimization, and compare it to the initial image. You should observe
795+
that the atoms are ``clumping together'' as they move toward positions
796+
of lower potential energy.
797+
797798
\paragraph{Molecular dynamics}
798799

799800
\begin{figure}
@@ -826,7 +827,7 @@ \subsubsection{My first input}
826827
update the output frequency from 10 to 50 as soon as \lmpcmd{PART B} of
827828
the simulation starts. In addition, a new \lmpcmd{thermo\_style}
828829
command is introduced to specify the thermodynamic information LAMMPS should
829-
print during during \lmpcmd{PART B}. This adjustment is made because, during
830+
print during during \lmpcmd{PART B.} This adjustment is made because, during
830831
molecular dynamics, the system exhibits a non-zero temperature $T$ (and
831832
consequently a non-zero kinetic energy $K$, keyword \lmpcmd{ke}), which are useful to monitor.
832833
The \lmpcmd{pe} keyword represents the potential energy of the system, $U$, such that
@@ -841,19 +842,21 @@ \subsubsection{My first input}
841842
run 50000
842843
\end{lstlisting}
843844
The \lmpcmd{fix nve} command updates the positions and velocities of the
844-
atoms in the group \lmpcmd{all} at every step. {\color{blue}More specifically,
845-
this command integrates Newton's equations of motion using the velocity-Verlet algorithm.}
846-
The group \lmpcmd{all} is a default group that contains all atoms. The last two lines specify
847-
the value of the \lmpcmd{timestep} and the number of steps for the
845+
atoms in the group \lmpcmd{all} at every step. {\color{blue}More
846+
specifically, this command integrates Newton's equations of motion
847+
using the velocity-Verlet algorithm.} The group \lmpcmd{all} is a
848+
default group that contains all atoms. The last two lines specify the
849+
value of the \lmpcmd{timestep} and the number of steps for the
848850
\lmpcmd{run}, respectively, for a total duration of 250 time units.
849851

850852
\begin{note}
851-
{\color{blue}Since the only command affecting forces and velocities in the
852-
present script is \lmpcmd{fix nve}, and periodic boundary conditions are applied
853-
in all directions,} the MD simulation will be performed in the microcanonical (NVE) ensemble, which
854-
maintains a constant number of particles and a fixed box volume. In
855-
this ensemble, the system does not exchange energy with anything
856-
outside the simulation box.
853+
{\color{blue}Since the \emph{only} command affecting forces
854+
and velocities in the present script is \lmpcmd{fix nve}, \emph{and}
855+
periodic boundary conditions are applied in all directions,} the MD
856+
simulation will be performed in the microcanonical (NVE) {\color{blue}
857+
statistical mechanical} ensemble, which maintains a constant number
858+
of particles and a fixed box volume. In this ensemble, the system does
859+
not exchange energy with anything outside the simulation box.
857860
\end{note}
858861

859862
Run the simulation using LAMMPS. Initially, there is no equilibrium
@@ -930,10 +933,11 @@ \subsubsection{My first input}
930933
dump_modify viz pad 9 boxcolor royalblue &
931934
backcolor white adiam 1 1.6 adiam 2 4.8
932935
\end{lstlisting}
933-
{\color{blue}The `$\&$' is used to continue the commands on a new line.
934-
These commands tell} LAMMPS to generate NetPBM format images every 100
936+
{\color{blue}The `$\&$' characters at the end are used to extend the
937+
commands across multiple lines. These two commands tell} LAMMPS to
938+
generate NetPBM format images every 100
935939
steps. The two \lmpcmd{type} keywords are for \lmpcmd{color} and
936-
\lmpcmd{diameter}, respectively. Run the \flecmd{initial.lmp} using
940+
\lmpcmd{diameter,} respectively. Run the \flecmd{initial.lmp} using
937941
LAMMPS again, and a new window named \guicmd{Slide Show} will pop up.
938942
It will show each image created by the \lmpcmd{dump image} as it is
939943
created. After the simulation is finished (or stopped), the slideshow
@@ -1035,7 +1039,7 @@ \subsubsection{Improving the script}
10351039

10361040
\begin{figure}
10371041
\centering
1038-
\includegraphics[width=0.55\linewidth]{LJ-cylinder}
1042+
\includegraphics[width=0.75\linewidth]{LJ-cylinder}
10391043
\caption{Visualization of the improved binary mixture input after minimization
10401044
during \hyperref[lennard-jones-label]{Tutorial 1}. Colors are the same as in
10411045
Fig.~\ref{fig:LJ}.}

0 commit comments

Comments
 (0)