Skip to content
Snippets Groups Projects
Commit dc1efac4 authored by s1309877's avatar s1309877
Browse files

Update README for tutorial 1

parent 5234edd2
No related branches found
No related tags found
No related merge requests found
# Tutorial 1 - simulating a simple polymer chain
In this second tutorial, we use LAMMPS to simulate the dynamics of a simple
polymer (a chain of beads) within a solvent (modelled implicitly by simulating
the system using Langevin/Brownian dynamics). As in the previous tutorial,
beads interact with one another via the truncated Lennard-Jones (LJ)
potential, with the default parameters setting the interactions to be purely
repulsive.
beads interact with one another via a truncated and shifted Lennard-Jones
(LJ) potential, with the default parameters setting the interactions to be
purely repulsive.
To link consecutive beads of the polymer together, we add finite extensible
nonlinear elastic (FENE) springs/bonds between them. In formula, the FENE
potential is given by
U(r) = -K_f*R_0^2*ln(1-(r/R_0)^2),
U(r) = -0.5*K_f*R_0^2*ln(1-(r/R_0)^2) if r < R_0
where r is the distance between two consecutive beads, and K_f is the spring
constant. The FENE bond differs from the harmonic bond in that it can only
extend to a finite limit (R_0), and this can help reduce the chance of the
polymer getting entangled.
and infty otherwise. Here, r is the distance between two consecutive beads and
K_f is the spring constant. The FENE bond differs from the harmonic bond in
that it can only extend to a finite limit (R_0), and this can help reduce the
chance of the polymer getting entangled.
We also model the polymer to be semi-flexible by adding angle bonds - bonds
which act between three consecutive beads. Here we use the cosine potential
......@@ -27,68 +29,90 @@ persistence length l_p (K_b ~ k_B*T*l_p/sigma), the characteristic length over
which the polymer loses memory of its direction. This kind of semi-flexible
polymer models is also known as a Kratky-Porod model.
###############################################################################
What to do:
0. Plot the bond and angle potentials
0. Familarise yourself with the bond and angle potentials
Using your favourite plotting package, plot both the FENE and cosine
potentials. Make sure you are happy with how these potentials do what they
are meant to do in the simulations. Explore different parameter values and
see how that changes the shape of the potential.
are meant to do in the simulations! Explore different parameter values and
see how that changes the shape of the potential as well as th structural
and dynamical properties of the system.
1. Run the simulation with the default parameters
a. Generate the required input scripts/files
As before, this is done by running the provided bash script
bash init.sh
As in the first tutorial, this generates two files that are necessary
for running LAMMPS:
- run.lam file - a 'driver' script that is read by LAMMPS
- init.in file - a trajectory file containing the initial configuration
of the system (i.e., the atoms' positions, bonds, etc)
Have a look at these files individually and make sure you understand
what each command and each section does! In particular:
which creates two files (run.lam and init.in) that are needed for
running LAMMPS. Like before, have a look at these files individually
and make sure you understand what each command and each section does!
In particular:
- What are some new commands added in the run.lam file?
- What is the initial configuration of the polymer? And how did we
equilibrate the system?
- What additional info have we provided in the init.in file?
As always, if in doubt, check out LAMMPS documentation on
If in doubt, check out LAMMPS documentation on
docs.lammps.org/Manual.html
b. Run the simulation
This can be done using LAMMPS installed on the school computer
This can be done using the LAMMPS installed on the school computer. We
start the simulation using the same command as before
lmp -in run.lam
pos*.lammpstrj files will be generated, storing the beads' positions
and velocities
The simulated trajectory of the polymer is stored in the
pos*.lammpstrj files.
c. Visualise the trajectory of the polymer
This can be done using VMD as in the first tutorial. Note that because
LAMMPS does not output the bead positions in order (i.e., by the
bead index) while VMD thinks that is the case, beads are linked together
wrongly in the visualisation. We can fix this by typing the following
set of commands in the terminal after loading the molecule:
topo clearbonds
set N {nbeads}
for {set i 0} {$i < [expr $N-1]} {incr i} {
set j [expr $i+1]
topo addbond $i $j
}
[You will need to replace the variable nbeads with the actual number of
beads in the polymer]
This can be done using VMD as in the first tutorial.
2. Explore the effect of changing the
3.
2. Explore the effect of changing different system parameters
a. Change the interaction between polymer beads
Modify the pairwise interaction between beads so that they become
attractive to one another (i.e., change the cutoff r_c to 1.8 and vary
epsilon).
- Can you pinpoint the critical value for epsilon where the polymer
changes from having an extended/open structure to a compact/
globule-like one? This transition is also known as the
'coil-to-globule' transition in polymer physics, and can be seen in
experiment, for example, by modifying the salt concentration
of the solvent.
- Can you come up with an observable that allows you to quantify the
'size' of the polymer?
b. Change the stiffness/flexibility of the polymer
- How does changing the persistence length parameter in init.sh affect
the overall structure of the polymer?
- In the case where the attraction between beads is strong enough such
that the polymer collapses, how does changing the flexibility of the
fibre affect the way how it is folded?
3. (More advanced) Model a heteropolymer chain
The provided script simulates a polymer chain where all beads are identical
(e.g., they interact the same with one another), and this type of chain is
known as a homopolymer. A heteropolymer is one where beads/monomers with
different properties are chained together. Try modifying the code to
simulate a chain with two types of beads (type A and B, and say they are
randomly ordered along the polymer, e.g., ABAAABBAB). Set the interaction
strength to be different between the two kinds of beads (i.e.,
epsilon_AA != epsilon_AB != epsilon_BB).
- At what parameter regime does the polymer form a single globule with
A and B type beads mixed together?
- At what parameter regime does the polymer 'phase separate' and form
distinct globules, where A beads are demixed with B beads?
- How is the dynamics here different from the case of the LJ fluid,
where the beads/colloid particles are not connected together?
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment