pysimm.apps.random_walk module

pysimm.apps.random_walk.copolymer(m, nmon, s_=None, **kwargs)[source]

Builds copolymer using random walk methodology using pattern

Parameters:
  • m – list of reference monomer :class:`~pysimm.system.System`s
  • nmon – total number of monomers to add to chain
  • sSystem in which to build polymer chain (None)
  • settings – dictionary of simulation settings
  • density – density at which to build polymer (0.3)
  • forcefieldForcefield object to acquire new force field parameters
  • capped – True/False if monomers are capped
  • unwrap – True to unwrap final system
  • traj – True to build xyz trajectory of polymer growth (True)
  • pattern – list of pattern for monomer repeat units, should match length of m ([1 for _ in range(len(m))])
  • limit – during MD, limit atomic displacement by this max value (LAMMPS ONLY)
  • simSimulation object for relaxation between polymer growth
Returns:

new copolymer System

pysimm.apps.random_walk.find_last_backbone_vector(s, m)[source]

Finds vector between backbone atoms in terminal monomer. Requires current system s, and reference monomer m.

Parameters:
Returns:

list of vector components

pysimm.apps.random_walk.random_walk(m, nmon, s_=None, **kwargs)[source]

Builds homopolymer using random walk methodology

Parameters:
  • m – reference monomer System
  • nmon – total number of monomers to add to chain
  • sSystem in which to build polymer chain (None)
  • extra_bonds – EXPERMINTAL, True if making ladder backbone polymer
  • settings – dictionary of simulation settings
  • density – density at which to build polymer (0.3)
  • forcefieldForcefield object to acquire new force field parameters
  • capped – True/False if monomers are capped
  • unwrap – True to unwrap final system
  • traj – True to build xyz trajectory of polymer growth (True)
  • limit – during MD, limit atomic displacement by this max value (LAMMPS ONLY)
  • simSimulation object for relaxation between polymer growth
Returns:

new polymer System