espressopp.analysis.SubregionTracking

Class to compute the number of (coarse-grained) particles that belong to a specified particle list and that reside in a specified subregion of the simulation box (when specifying a list of particles that reside in a certain subregion at the beginning of the simulation, the routine can be used, for example, to track how many of these particles still stay in the same region after some simulation time).

Examples:

>>> subregiontracking_instance = espressopp.analysis.SubregionTracking(system, span=0.75, geometry=1, pidlist=tracklist, center=[Lx/2, Ly/2, Lz/2])
>>> # creates instance of the class for calculating number of particles that belong to particle id list tracklist and reside in a subregion which is centered in the simulation box and bounded within +-0.75 in x-direction from the center
>>> number_of_particles = subregiontracking_instance.compute()
>>> # computes the number of particles belonging to specified particle id list in specified subregion of the simulation box
espressopp.analysis.SubregionTracking(self, system, span, geometry, center, pidlist)

Constructs the SubregionTracking object.

Parameters:
  • system (shared_ptr<System>) – system object
  • span (real) – radius of the subregion to be considered
  • geometry (str in ['spherical', 'bounded-x', 'bounded-y', 'bounded-z']) – geometry of the subregion. Can only be in [‘spherical’, ‘bounded-x’, ‘bounded-y’, ‘bounded-z’]
  • center (list of 3 reals (x,y,z coordinates of center)) – center of the subregion
  • pidlist (list of ints) – list of particle ids of coarse-grained particles that are counted in the specified subregion
espressopp.analysis.SubregionTracking.compute():

Calculates the number of particles that are present in specified subregion and that belong to specified particle id list.

Return type:real
class espressopp.analysis.SubregionTracking.SubregionTrackingLocal(system, span, geometry, center, pidlist)

The (local) class for computing the number of particles that are present in a specified subregion of the system and that belong to a specified group of particles.