NeighborList Interface

public interface NeighborList

Initialize a NeighborList.

The cutoff and full options are mandatory, the other are optional and default to .false.


Module Procedures

private function vesin_construct_c_float(cutoff, full, sorted, algorithm, skin, n_threads, return_shifts, return_distances, return_vectors) result(self)

Arguments

Type IntentOptional Attributes Name
real(kind=c_float), intent(in) :: cutoff

Spherical cutoff, only pairs below this cutoff will be included

logical, intent(in) :: full

Should the returned neighbor list be a full list (include both i -> j and j -> i pairs) or a half list (include only i -> j)?

logical, intent(in), optional :: sorted

Should the neighbor list be sorted? If .true., the returned pairs will be sorted by the first point index (i). The order of the second point index (j) and shifts in the list of pairs is unspecified.

integer(kind=c_int32_t), intent(in), optional :: algorithm

Algorithm to use for the neighbor list calculation (one of VesinAutoAlgorithm, ! VesinBruteForceAlgorithm, or VesinCellListAlgorithm)

real(kind=c_float), intent(in), optional :: skin

Skin size for Verlet caching. A positive value enables caching the neighbor list until any atom moves farther than skin/2 from its reference coordinates.

integer(kind=c_int32_t), intent(in), optional :: n_threads

Number of CPU threads to use. Must be zero or positive. If zero, Vesin uses OMP_NUM_THREADS when set to a positive integer, and otherwise defaults to the number of available CPU cores.

logical, intent(in), optional :: return_shifts

Should the returned VesinNeighborList contain shifts?

logical, intent(in), optional :: return_distances

Should the returned VesinNeighborList contain distances?

logical, intent(in), optional :: return_vectors

Should the returned VesinNeighborList contain vector?

Return Value type(NeighborList)

private function vesin_construct_c_double(cutoff, full, sorted, algorithm, skin, n_threads, return_shifts, return_distances, return_vectors) result(self)

Arguments

Type IntentOptional Attributes Name
real(kind=c_double), intent(in) :: cutoff

Spherical cutoff, only pairs below this cutoff will be included

logical, intent(in) :: full

Should the returned neighbor list be a full list (include both i -> j and j -> i pairs) or a half list (include only i -> j)?

logical, intent(in), optional :: sorted

Should the neighbor list be sorted? If .true., the returned pairs will be sorted by the first index (i). The order of the second index (j) and shifts in the list of pairs is unspecified.

integer(kind=c_int32_t), intent(in), optional :: algorithm

Algorithm to use for the neighbor list calculation (one of VesinAutoAlgorithm, ! VesinBruteForceAlgorithm, or VesinCellListAlgorithm)

real(kind=c_double), intent(in), optional :: skin

Skin size for Verlet caching. A positive value enables caching the neighbor list until any atom moves farther than skin/2 from its reference coordinates.

integer(kind=c_int32_t), intent(in), optional :: n_threads

Number of CPU threads to use. Must be zero or positive. If zero, Vesin uses OMP_NUM_THREADS when set to a positive integer, and otherwise defaults to the number of available CPU cores.

logical, intent(in), optional :: return_shifts

Should the returned VesinNeighborList contain shifts?

logical, intent(in), optional :: return_distances

Should the returned VesinNeighborList contain distances?

logical, intent(in), optional :: return_vectors

Should the returned VesinNeighborList contain vector?

Return Value type(NeighborList)