ParticleLocalAccessBase¶
- class hoomd.data.ParticleLocalAccessBase(state)¶
Directly access particle data in the simulation state.
Note
Changing some attributes (such as
velocityandacceleration) may not alter the trajectory of the system as you would expect. Themd.Integratoris responsible for integrating the equations of motion and manages the values in these arrays.- typeid¶
The integer type of a particle.
- Type:
(N_particles)
HOOMDArrayorHOOMDGPUArrayoffloat
- tag¶
The particle tags. Spatial sorting and MPI domain migration reorders particles in memory. The particle tag identifies each particle in the order it existed in the initial configuration.
- Type:
(N_particles)
HOOMDArrayorHOOMDGPUArrayofint
- rtag¶
The particle reverse tags. For a given particle tag
tag,i = particles.rtag[tag]is the array index holding that particle.- Type:
(N_particles_global)
HOOMDArrayorHOOMDGPUArrayofint
- position¶
Particle positions \([\mathrm{length}]\).
- Type:
(N_particles, 3)
HOOMDArrayorHOOMDGPUArrayoffloat
- image¶
A count of how many times each particle crosses the periodic box boundaries.
- Type:
(N_particles, 3)
HOOMDArrayorHOOMDGPUArrayofint
- velocity¶
Particle velocities \([\mathrm{velocity}]\).
- Type:
(N_particles, 3)
HOOMDArrayorHOOMDGPUArrayoffloat
- acceleration¶
Particle accelerations \([\mathrm{velocity} \cdot \mathrm{time}^{-1}]\).
- Type:
(N_particles, 3)
HOOMDArrayorHOOMDGPUArrayoffloat
- mass¶
Particle masses \([\mathrm{mass}]\).
- Type:
(N_particles)
HOOMDArrayorHOOMDGPUArrayoffloat
- orientation¶
Particle orientations expressed as quaternions.
- Type:
(N_particles, 4)
HOOMDArrayorHOOMDGPUArrayoffloat
- angmom¶
Particle angular momenta expressed as quaternions \([\mathrm{mass} \cdot \mathrm{velocity} \cdot \mathrm{length}]\).
- Type:
(N_particles, 4)
HOOMDArrayorHOOMDGPUArrayoffloat
- moment_inertia¶
Particle principal moments of inertia \([\mathrm{mass} \cdot \mathrm{length}^2]\).
- Type:
(N_particles, 3)
HOOMDArrayorHOOMDGPUArrayoffloat
- charge¶
Particle electrical charges \([\mathrm{charge}]\).
- Type:
(N_particles)
HOOMDArrayorHOOMDGPUArrayoffloat
- diameter¶
Particle diameters \([\mathrm{length}]\).
- Type:
(N_particles)
HOOMDArrayorHOOMDGPUArrayoffloat
- body¶
The id of the rigid body the particle is in.
- Type:
(N_particles)
HOOMDArrayorHOOMDGPUArrayofint
- net_force¶
Net force on particle \([\mathrm{force}]\).
- Type:
(N_particles, 3)
HOOMDArrayorHOOMDGPUArrayoffloat
- net_torque¶
Net torque on particle \([\mathrm{force} \cdot \mathrm{length}]\).
- Type:
(N_particles, 3)
HOOMDArrayorHOOMDGPUArrayoffloat
- net_virial¶
Net virial on particle \([\mathrm{energy}]\).
- Type:
(N_particles, 6)
HOOMDArrayorHOOMDGPUArrayoffloat
- net_energy¶
Net energy of a particle \([\mathrm{energy}]\).
- Type:
(N_particles,)
HOOMDArrayorHOOMDGPUArrayoffloat