Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.
-
date post
21-Dec-2015 -
Category
Documents
-
view
217 -
download
3
Transcript of Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.
![Page 1: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/1.jpg)
Parallel Flat Histogram Simulations
Malek O. Khan
Dept. of Physical Chemistry
Uppsala University
![Page 2: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/2.jpg)
Original motivation: DNA condensation
Fluorescence microscopy of DNA with multivalent ions
K. Yoshikawa et al, Phys. Rev. Letts., 76, 3029, 1996
Parallel Flat Histogram SimulationsMalek O. Khan
Dept. of Physical Chemistry, Uppsala University
DNA either elongated or compact not in between
![Page 3: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/3.jpg)
Original motivation: DNA condensation
Fluorescence microscopy of DNA with multivalent ions
K. Yoshikawa et al, Phys. Rev. Letts., 76, 3029, 1996
Parallel Flat Histogram SimulationsMalek O. Khan
Dept. of Physical Chemistry, Uppsala University
DNA either elongated or compact not in between
“unambiguous interpretation of experimental observations” -Kenneth Ruud
![Page 4: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/4.jpg)
Hamiltonian
Fixed bond length Electrostatics
Hard sphere particles Intrinsic stiffness
Outer spherical cell Moves - clothed pivot & translation
Polyelectrolyte model
€
U0 =Ubond +Ues +Uhc +Uangle
€
Ues =qiq je
2
4πεrε0 ri − rji< j
N +Nc
∑ Ree
€
Uangle =C cosα ii= 2
N−1
∑
i
output
![Page 5: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/5.jpg)
Polyelectrolyte conformation Stretched under normal conditions Large electrostatic interactions lead to condensation
Condensation of polyelectrolytes - MC
Flexible polyelectrolytesExperiments by R. Watson, J. Cooper-White & V. Tirtaatmadja, PFPC
NaPSS€
Ues =qiq je
2
4πεrε0 ri − rj
vv Effect of intrinsic chains stiffness???
Problem 1: Mixture of length scales - bonds and Coulomb lead to slow convergence --> parallel calculations
Problem 2: Long range Coulomb interaction - every particle interacts with every other particle
![Page 6: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/6.jpg)
Months of computer time needed for stiff polyelectrolytesProblem 1: Mixture of length scales - bonds and Coulomb lead to slow
convergence --> parallel calculations Problem 2: Long range Coulomb interaction - every particle interacts with every
other particle in the Monte Carlo Simulation
Convergence for stiff PE (N=128)
Ree
Total simulation time = 6 days Autocorrelation time ~ hours
![Page 7: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/7.jpg)
Cluster moves - clothed pivot
Parallel expended ensembles
Parallel flat histogram techniques
Solutions
![Page 8: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/8.jpg)
Our implementation is a parallel implementation of a serial algorithm introduced by Engkvist & Karlström and Wang & Landau
Instead of importance sampling create a flat distribution of the quantity of interest
Correctly done this gives the potential of mean force (POMF) as a function of the quantity of interest
Parallel flat histogram simulations
Engkvist & Karlström, Chem. Phys. 213 (1996), Wang & Landau, PRL 86 (2001)
![Page 9: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/9.jpg)
Potential of mean force, w
€
p ξ 0( ) =exp −βU(r)[ ]δ ξ −ξ 0[ ]dr∫
exp −βU(r)[ ]dr∫
€
p* ξ 0( ) =exp −βU(r) +U*(ξ 0)[ ]δ ξ −ξ 0[ ]dr∫
exp −βU(r) +U*(ξ 0)[ ]dr∫
€
p ξ( ) = p* ξ( )exp βU*(ξ )[ ]C1
Add U*
If p*() = constant
€
p ξ( ) = exp βU*(ξ )[ ]C2
€
U* ξ( ) = −w ξ( ) +C3
€
w ξ( ) = −kBT ln p(ξ )( )
New formulation of the problem: construct a “flat” p
![Page 10: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/10.jpg)
Implementation
Discretize U*() and set to zero (here is Ree) For every visited, update U*() with pen
Repeat until p*() is “flat” Decrease pen ----> pen/2 Repeat until pen is small Parameters:
Number of bins (~102-103) Initial choice of pen (0.001-1kBT) What is “flat” (max[|p*() - <p*()>|] < (0.1-0.35) Finish when pen < (10-8 - 10-5)
![Page 11: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/11.jpg)
Parallel implementation
Run copies on Ncpu processors with different random number seeds
Calculate individual U* and p* on every CPU During simulation sum U* and p* from all
processors Distribute <U*>cpu to all processors
Check averaged <p*>cpu
Each processor does not have a constant p* but the sum over Ncpu
![Page 12: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/12.jpg)
Distribution functions
Neutral polymer, N=240
8 million iterations
4 million iterations
1 million iterations
Flat histogram method at least of same quality
![Page 13: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/13.jpg)
Evolution of the potential of mean force
Polyelectrolyte, N=64, tetravalent counterionsPOMF at every update of pen shown belowThe right graph only shows the last 8
The POMF converges to a solution. There is no way of knowing if it is the correct solution. Experimental approach has to be taken.
![Page 14: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/14.jpg)
Time between updatesExperimental approach: Do it 11 times and collect statistics
Time between updates is independent of Ncpu
![Page 15: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/15.jpg)
Errors in the POMFsExperimental approach: Do it 11 times and collect statistics
Error is independent of Ncpu
NCPU=2NCPU=32
![Page 16: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/16.jpg)
Parallel efficiencyPolyelectrolyte, N=64, tetravalent counterions
Extra time for communication is small up to Ncpu=32
alpha SC Brecca Beowulf - 194 CPU Xeon 2.8 GHz with Myrinet
![Page 17: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/17.jpg)
Parallel efficiency (effect of system size)
Larger, more complex, systems scale better
![Page 18: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/18.jpg)
Individual processors
Polyelectrolyte, N=64, tetravalent counterions
Ncpu = 4 Ncpu = 32
All CPUs do not have a flat histogram - the sum has
![Page 19: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/19.jpg)
Polyelectrolyte, N=128, monovalent counterions + added tetravalent saltScales to 64 processors on edda (VPAC Power5) and APAC’s Altix Itanium2.
Case study: Polyelectrolytes with intrinsic stiffness
![Page 20: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/20.jpg)
Distribution functions - Flexible PE
Polyelectrolyte, N=128, monovalent counterions + added tetravalent salt
lp0=12 Å
f=0
f=0.25
f=0.5
f=0.75
f=1
![Page 21: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/21.jpg)
Distribution functions - stiff PE
Polyelectrolyte, N=128, monovalent counterions + added tetravalent salt
lp0=120 Å
f=0
f=0.25
f=0.5f=0.75
f=1
![Page 22: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/22.jpg)
Summary - Stiff polyelectrolytesFluorescence microscopy of DNAK. Yoshikawa et al, Phys. Rev. Letts., 76, 3029, 1996
Monte Carlo
Possible to simulate all or nothing phase transition of stiff polyelectrolytes, see double maxima for nc=38 on previous page
Simulation time for each point is 1 week on 24 processors on brecca (VPAC 2.8GHz Xeon with Myrinet interconnect) (5.6 CPU months)
![Page 23: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/23.jpg)
Gives the free energy directly
Allows exploration of areas of phase space which are difficult to reach with conventional MC - complements importance sampling
Parallelisation is easily implemented and shown to scale linearly to a large amount of CPUs on clusters• Time between updates is independent of NCPU
• Error is independent of NCPU
• Distribution is flat over all CPUs not every individual one
• CPU time does not increase with NCPU (for large systems)
Summary - Parallel flat histograms
![Page 24: Parallel Flat Histogram Simulations Malek O. Khan Dept. of Physical Chemistry Uppsala University.](https://reader030.fdocuments.in/reader030/viewer/2022032704/56649d6d5503460f94a4d1a0/html5/thumbnails/24.jpg)
AcknowledgmentsPeople Derek Chan – Big bossSimon Petris – PhD student: double layersGareth Kennedy – MSc student: computational methods Malek Ghantous – Honours student: polymer conformation
Grants & OrganisationsWenner-Gren Foundation – post doc grantARCPFPC at The University of MelbourneVPAC and APAC
Australia