Chapter 10: Modifying Force Applications
In this chapter, we will write custom fixes that are able to apply non-pairwise forces on selected groups of atoms during a simulation run. Starting with existing fixes, we will make modifications that produce new fixes to exert custom forces to the atoms in the system. These forces generally represent agents that are not adequately incorporated into the MD simulation by atoms or potentials, such as self-propelling active forces.
We will cover the following topics in this chapter:
- Writing a fix to apply a 2D spring force
- Writing a fix to apply an active force in a molecular chain
- Writing a fix to apply a custom wall force
- Writing a fix to apply a bond-boost potential
By the end of this chapter, you will have learned how to write your own fix that can manipulate your MD simulation by modifying forces as programmed in the source code.