hoomd.hpmc.nec.integrate¶
Overview
HPMC integration for convex polyhedra (3D) with nec. |
|
HPMC Chain Integrator base class. |
|
HPMC chain integration for spheres (2D/3D). |
Details
Newtonain Event-Chain Integrators for Hard Particle Monte Carlo.
- class hoomd.hpmc.nec.integrate.ConvexPolyhedron(default_d=0.1, default_a=0.1, chain_probability=0.5, chain_time=0.5, update_fraction=0.5, nselect=1)¶
Bases:
HPMCNECIntegratorHPMC integration for convex polyhedra (3D) with nec.
- Parameters
default_d (
float, optional) – Default colission search distance \([\mathrm{length}]\), defaults to 0.1.default_a (
float, optional) – Default maximum size of rotation trial moves \([\mathrm{dimensionless}]\), defaults to 0.1.chain_probability (
float, optional) – Probability of making a chain move instead of a rotation move, defaults to 0.5.chain_time (
float, optional) – Length of a chain \([\mathrm{time}]\), defaults to 0.5.update_fraction (
float, optional) – Number of chains to be done as fraction of N, defaults to 0.5.nselect (
int, optional) – Number of repeated updates for the cell/system, defaults to 1.
Perform Newtonian event chain Monte Carlo integration of convex polyhedra.
Wall support.
ConvexPolyhedronsupports nohoomd.wallgeometries.Potential support.
ConvexPolyhedrondoes not supportpair_potentialorexternal_potential.Attention
ConvexPolyhedrondoes not support execution on GPUs.Attention
ConvexPolyhedrondoes not support MPI parallel simulations.Example:
mc = hoomd.hpmc.nec.integrate.ConvexPolyhedron(d=1.0, a=0.05, chain_probability=0.1, nselect=10) mc.shape['A'] = dict(vertices=[[1,1,1], [1,1,-1], [1,-1,1], [1,-1,-1], [-1,1,1], [-1,1,-1], [-1,-1,1], [-1,-1,-1]])
- shape¶
The shape parameters for each particle type. The dictionary has the following keys.
vertices(list[tuple[float,float,float]], required) - vertices of the polyhedron \([\mathrm{length}]\).The origin MUST be contained within the polyhedron.
The origin centered sphere that encloses all vertices should be of minimal size for optimal performance.
ignore_statistics(bool, default:False) - set toTrueto ignore tracked statistics.sweep_radius(float, default: 0.0) - Ignored, but present becauseConvexPolyhedronshares data structures withConvexSpheropolyhedron\([\mathrm{length}]\).
Warning
HPMC does not check that all vertex requirements are met. Undefined behavior will result when they are violated.
- Type
TypeParameter[particle type,dict]
- class hoomd.hpmc.nec.integrate.HPMCNECIntegrator(default_d=0.1, default_a=0.1, chain_probability=0.5, chain_time=0.5, update_fraction=0.5, nselect=1)¶
Bases:
HPMCIntegratorHPMC Chain Integrator base class.
HPMCNECIntegratoris the base class for all HPMC Newtonian event chain integrators. The attributes documented here are available to all HPMC integrators.Warning
This class should not be instantiated by users. The class can be used for
isinstanceorissubclasschecks.- property chains_in_space¶
rate of chain events that did neither collide nor end.
Note
The statistics are reset at every
hoomd.Simulation.run.(
Loggable: category=”scalar”)- Type
- property nec_counters¶
Trial move counters.
The counter object has the following attributes:
chain_start_count:intNumber of chainschain_at_collision_count:intNumber of collisionschain_no_collision_count:intNumber of chain events that are no collision (i.e. no collision partner found or end of chain)distance_queries:intNumber of sweep distances calculatedoverlap_errors:intNumber of errors during sweep calculations
Note
The counts are reset to 0 at the start of each
hoomd.Simulation.run.
- property particles_per_chain¶
particles per chain.
Note
The statistics are reset at every
hoomd.Simulation.run.(
Loggable: category=”scalar”)- Type
- class hoomd.hpmc.nec.integrate.Sphere(default_d=0.1, chain_time=0.5, update_fraction=0.5, nselect=1)¶
Bases:
HPMCNECIntegratorHPMC chain integration for spheres (2D/3D).
- Parameters
default_d (
float, optional) – Default colission search distance \([\mathrm{length}]\), defaults to 0.1.chain_time (
float, optional) – Length of a chain \([\mathrm{time}]\), defaults to 0.5.update_fraction (
float, optional) – Number of chains to be done as fraction of N, defaults to 0.5.nselect (
int, optional) – The number of repeated updates to perform in each cell, defaults to 1.
Perform Newtonian event chain Monte Carlo integration of spheres.
Wall support.
Spheresupports nohoomd.wallgeometries.Potential support.
Spheredoes not supportpair_potentialorexternal_potential.Attention
Spheredoes not support execution on GPUs.Attention
Spheredoes not support MPI parallel simulations.Example:
mc = hoomd.hpmc.integrate.nec.Sphere(d=0.05, update_fraction=0.05) mc.chain_time = 0.05
- shape¶
The shape parameters for each particle type. The dictionary has the following keys:
diameter(float, required) - Sphere diameter \([\mathrm{length}]\).ignore_statistics(bool, default:False) - set toTrueto ignore tracked statistics.orientable(bool, default:False) - set toTrueto allow rotation moves on this particle type.
- Type
TypeParameter[particle type,dict]