Skip to content

Custom version of fix_bond_create for LAMMPS that checks cyclisation through the periodic boundary conditions

Notifications You must be signed in to change notification settings

Confizolo/fix_bond_create_mol

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

29 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Fix bond/create/mol and bond/create/angle/mol

Overview

This project provides a modified version of both fix bond/create and bond/create/angle with additional topology reconstruction and end-to-end measurements in order to avoid finite size effect happening for dense solutions of polymers.

Difference compared to original bond/create and bond/create/angle

Differently from the regular bond/create fix, the ligation events are first collected in each processor and then filtered accordingly to the topology. Specifically, any ligation event that leads to the formation of a single molecule from two different ones (e.g. 1,2 -> 1,linear) is always accepted. This information is thus communicated to the instance of fix topocalc, that store this change in its internal lists. If one or more ligation events lead to the cyclisation of a molecule (e.g 1,linear->1,ring or 1,2->1,ring), the fix checks that the reconstructed molecule does not form through the periodic boundaries effectively becoming a long linear polymer. To do so we use the Minimum Image Convention and check whetether the two bonding atoms are closer than epsilon - if this is true then cyclisation is allowed, otherwise the event is skipped and the topology is kept as it is.

Activation of the debug flag in the fix allows to:

  • Print ligation events as they happen
  • Verify that cyclisation events are not affected by finite size effects

How to run

The current version of fix bond/create/angle requires the following arguments fix ID group-ID style Nevery itype jtype Rmin bondtype keyword values ...

The current version requires two additional arguments fix ID group-ID style Nevery itype jtype Rmin bondtype epsilon top_fix keyword values ...

  • epsilon is the tolerance we consider for the end to end distance of the polymer once reconstructed in Minimal Image Convention. If the end-to-end distance is larger than this threshold then we neglect ligation between the ends of the same polymer.

  • top_fix is the fix of the type fix_topocalc that is used to store molecule topology. This fix has to be instantiated before all the fix_bond_create and requires the following arguments: fix ID group-ID topocalc all top_file dump_flag dump_file nevery

    1. top_file is the full path of the file containing the initial topology of the system. The molecule topology has to be defined such that each row in the file contains the atom IDs in order from each of the two sides of the molecule.
    2. dump_flag boolean flag for dumping atom topology in a file
    3. dump_file file to dump the atom topologies over
    4. nevery every how many timesteps to dump the topologies in

Installation

Installation is completed by copying the codes in src into the src/MC directory of the lammps version to compile, and compiling it including the MC package.

Test

The directories tests_one_family and tests_two_families provide tests to visualise how the fix works.

Contributions

This fix was developed by:

  • Filippo Conforto (University of Edinburgh, [email protected]) - Main Source Code
  • Yair Augusto Gutierrez Fosado (University of Edinburgh, [email protected]) - Test and Debugging

About

Custom version of fix_bond_create for LAMMPS that checks cyclisation through the periodic boundary conditions

Resources

Stars

Watchers

Forks

Packages

No packages published