distribution_brute
Functions for creating distributions of atomic indices using bruteforce approaches.
Index

Brute force approach to creating uniform or clustered distributions. 
API
 CAT.attachment.distribution_brute.brute_uniform_idx(mol, idx, n=2, operation='min', weight=<function <lambda>>)[source]
Brute force approach to creating uniform or clustered distributions.
Explores, and evaluates, all valid combinations of size \(n\) constructed from the \(k\) atoms in neighbor closest to each atom in center.
The combination where the \(n\) atoms are closest (
operation = 'max'
) or furthest removed from each other (operation = 'min'
) is returned. Parameters
mol (arraylike [
float
], shape \((m,3)\)) – An arraylike object with Cartesian coordinate representing a collection of central atoms.idx (arraylike [
int
], shape \((l,p)\)) – An arraylike object with indices in mol. Combinations will be explored and evaluated along axis1
of the passed array.n (
int
) – The number of tobe returned opposing atoms. Should be larger than or equal to 1.operation (
str
) – Whether to evaluate the weighted distance usingargmin()
orargmax()
. Accepted values are"min"
and"max"
.weight (
Callable
) – A callable for applying weights to the distance; default: \(e^{x}\). The callable should take an array as argument and return a new array, e.g.numpy.exp()
.
 Returns
An array with indices of opposing atoms.
 Return type
numpy.ndarray
[int
], shape \((m, n)\)
See also
uniform_idx()
Yield the columnindices of dist which yield a uniform or clustered distribution.