Code development

LAMMPS

I have been a contributing developer to LAMMPS, an open-source massively parallel Molecular Dynamics (MD) simulation package, widely used by computational chemists, physicists and materials scientists. As a postdoc at the NCCS (ORNL) I worked on optimizing LAMMPS code for supercomputers, including Titan (Cray XK7).

My contributions to LAMMPS include:

  • USER-DIELECTRIC package (to be submitted as a pull request): now on Bitbucket
    • Coupling boundary element methods with MD simulation for surface polarization effects
  • BODY package::
    • Discrete element models for rounded polygons and polyhedra based on the contact models developed by Prof. Langston (U of Nottingham)
    • GPU package -- with W. Michael Brown:
    • LAMMPS Accelerator Library (Geryon) is the core of the GPU package, available in the main LAMMPS code, which allows for acceleration on both NVIDIA and ATI graphics cards as well as many-core coprocessors (such as Intel Xeon Phi). The library can be compiled with either NVIDIA CUDA or OpenCL.
    • An unofficial guide to create a GPU-accelerated force field (i.e. pair style) for the GPU package in LAMMPS is given here.
    • GPU package supports the following force fields
      • CORESHELL pair styles for modeling polarization
      • Three-body potentials::: Tersoff potentials
      • Dissipative Particle Dynamics (DPD),
      • Embedded atom model (EAM),
      • Damped shifted-force Wolf summation, and force-switching Wolf summation
      • Yukawa potential,
      • Buckingham, hybrid Buckingham and Coulombic potentials,
      • Born-Mayer-Huggins, hybrid BMH and Coulombic potentials,
      • LJ-CHARMM and LJ-GROMACS potentials
      • Colloidal potentials,
      • Dipole potentials,
      • Gauss and LJ-Gauss potentials,
      • Tabulated potentials,
      • and more to come.
    • RIGID package
      • Rigid body integrator variants: fix rigid/nve, rigid/nvt, fix rigid/npt and fix rigid/nph -- with Anthony Sheh

Development tools: C/C++, MPI, OpenMP, NVIDIA CUDA Toolkit, Bash shell scripting, Python.

Performance/debugging tools: nvprof, gdb, ddt, vampirtrace, craypat

Version control: git

HOOMD-Blue

I have also contributed to HOOMD-Blue (prior to 2.0), an open-source MD code optimized for NVIDIA(R) GPGPUs from University of Michigan:

  • Rigid body integrators: rigid/nve, rigid/nvt and rigid/npt
  • Rigid-constraint energy minimizer (FIRE)

Development tools: C/C++, NVIDIA CUDA Toolkit, OpenMP, Python.

Version control: git, svn

VisualizerX

This is a particle visualization and analysis software I have been developing for Windows OS. The software for Windows 7 64-bit can be downloaded here.

The outstanding features of this software package include:

  • Flexible user-defined building block geometries: cylinders, polygons, polyhedra, spheres with different diameters, lines and more to be added if requested.
  • Overlay vectors (i.e. dipoles, velocities, accelerations) to individual building blocks
  • Multiple views and multiple structures at the same time.
  • Online analysis functions include:
    • Radial distribution function g(r) and structure factor S(q) for specified atom types in 2-D and 3-D
    • Bond order diagram for specified atom types
    • Diffraction pattern for visualized particles (Credits to Michael Engel's FFT Java code.)
    • Filter particles based on region (box or sphere), types and indices
  • An OpenGL interactive lab to play with:
    • Zoom, translate in and out, camera setup are customizable
    • Scale particle size interactively
    • Shift in X-, Y- and Z- direction with periodic boundary conditions
    • Replicate the particles
    • Materials color can be adjusted interactively.
    • Lighting, blending and fogging are customizable
  • Support Drag and Drop XYZ-format files directly to the application window.
  • Support Copy/Paste (Device Independent Bitmap- DIB) images into documents e.g. Word, Excel, PowerPoint and Paint. DIBs in PowerPoint can be saved as high resolution images (up to 300 dpi) with ExportBitmapResolution set in the Windows registry. Higher DPIs can be achieved by GIMP (Scale Image).
  • Support streaming from ASCII files which are produced by concatenating multiple .XYZ files for animated visualization and screen capture software.
  • Support streaming from standard input
  • Support exporting to BMP images and Encapsulated Post Script (EPS) files
  • Export to injavis .pos files

Figure: Snapshot of a honeycomb structure formed by laterally tethered nanorods. Rods can be drawn as smooth cylinders, tethers as smooth and translucent like glass. Lights can be turned on/off and changed position and orientation.

Figure: Analysis of a quasicrystalline structure formed by bumpy tetrahedra using the bond order diagram (the blue sphere in the left top corner) and radial distribution function (the window in the right top corner). Only the center of mass of the tetrahedra (yellow) is drawn; others are hidden. The bond order diagram is obtained at the first peak of the RDF where the straight line pointer locates.

Hint: Blue-Maize is the UMich color theme.

Development tools: Microsoft Visual C++ 6.0, Microsoft Foundation Class 6.0, OpenGL

Other software packages

BasicMC

A software library and test suites for Monte Carlo simulations of off-lattice particle-based systems. The source code and documentation are available on Bitbucket.

RDF

An analysis tool for pair correlation function of multimillion atom systems that supports various parallelization schemes: OpenMP (shared memory), MPI (distributed memory), CUDA (GPUs) and hybrid parallelisms: MPI/CUDA (multiple GPUs) and MPI/OpenMP. The software can be run on multiple platforms: Unix-based and Windows operating systems, multi-core processors and many-core coprocessors.

Development tools: C/C++

Performance tool: NVIDIA Visual Profiler

BalanceX

A commercial software for balancing rotating machines and device management. The software provides a user-friendly graphical interface and useful signal processing functionalities. This project is in collaboration with the Laboratory for Vibration and Noise Control at the Institute of Mechanics, Hanoi, Vietnam.

Development tools: Microsoft Visual C++, MATLAB Signal Processing Toolbox, MATLAB Compiler Toolbox