Neighborhood Search

The neighborhood search is one of the most performance-critical components. We provide several implementations in the package PointNeighbors.jl. See the PointNeighbors.jl documentation for an overview and a comparison of the different implementations.

Usage

To run a simulation with a neighborhood search implementation, pass a neighborhood search template to the constructor of the Semidiscretization. A template is just an empty neighborhood search with search radius 0.0. See copy_neighborhood_search and the examples below for more details.

semi = Semidiscretization(system1, system2,
                          neighborhood_search=PrecomputedNeighborhoodSearch{2}())

The keyword argument periodic_box in the neighborhood search constructors can be used to define a periodic domain. See the PointNeighbors.jl docs for more details.

periodic_box = PeriodicBox(min_corner=[0.0, -0.25], max_corner=[1.0, 0.75])
semi = Semidiscretization(system1, system2,
                          neighborhood_search=GridNeighborhoodSearch{2}(; periodic_box))