Expand description
Spatial data structures.
Use a spatial data structure to efficiently find points near a position in space.
Microstate maintains a spatial data structure internally for use with
pair potential computations. Specifically, Microstate interoperates with:
VecCellis the highest performance spatial data structure. Use it in typical simulations where points remain inside a fixed boundary and have a roughly uniform density throughout.HashCellis only slightly slower thanVecCell.HashCellwill use less memory in simulations with open boundaries and/or when there are large regions of space with no points.AllPairsis very slow. Use it only when necessary.
You can also utilize any of these data structures directly. They operate by
mapping keys (of a generic type) to points in space. Add points to a spatial
data structure with PointUpdate::insert, which also updates the position of
already added points. Remove points with PointUpdate::remove.
PointsNearBall::points_near_ball takes a position and a radius
and returns an iterator that will yield all of the inserted points within
the given ball. It may yield additional points that you need to filter out.
§Complete documentation
hoomd-spatial is is a part of hoomd-rs. Read the complete documentation
for more information.
Structs§
- AllPairs
- Check all pairs.
- Hash
Cell - Bucket sort points into cubes with
HashMap-backed storage - Hash
Cell Builder - Construct a
HashCellwith given parameters. - VecCell
- Bucket sort points into cubes with
Vec-backed storage - VecCell
Builder - Construct a
VecCellwith given parameters.
Traits§
- Index
From Position - Locate the index of a given point.
- Point
Update - Allow incremental updates to points in the spatial data.
- Points
Near Ball - Find all points in the given ball.
- With
Search Radius - Construct a spatial data structure capable of searching up to the given radius.