Interaction lists needed for a fast-multipole-like linear-time gather of particle interactions.
Carrier, J., Greengard, L. and Rokhlin, V. “A Fast Adaptive Multipole Algorithm for Particle Simulations.” SIAM Journal on Scientific and Statistical Computing 9, no. 4 (July 1988): 669-686. DOI: 10.1137/0909044.
Number of boxe in the tree.
The distance (measured in target box diameters in the \(l^\infty\) norm) from the edge of the target box at which the ‘well-separated’ (i.e. M2L-handled) ‘far-field’ starts.
List of boxes having sources.
List of boxes having targets. If boxtree.Tree.sources_are_targets, then target_boxes is source_boxes.
List of boxes that are (directly or indirectly) a parent of one of the source_boxes. These boxes may have sources of their own.
Indices into source_boxes indicating where each level starts and ends.
Indices into source_parent_boxes indicating where each level starts and ends.
List of boxes that are one of the target_boxes or their (direct or indirect) parents.
Indices into target_boxes indicating where each level starts and ends.
Indices into target_or_target_parent_boxes indicating where each level starts and ends.
To obtain the overall, non-adaptive box extent, use Tree.box_centers along with Tree.box_levels.
If they are not available, the corresponding attributes will be None.
Boxes considered to be within the ‘non-well-separated area’ according to well_sep_is_n_away that are on the same level as their reference box. See CSR-like interaction list storage.
This is a generalization of the “colleagues” concept from the Carrier paper to the case in which well_sep_is_n_away is not 1.
Well-separated boxes on the same level. Indexed like target_or_target_parent_boxes. See CSR-like interaction list storage.
Smaller source boxes separated from the target box by their own size.
If boxtree.Tree.targets_have_extent, then from_sep_close_smaller_starts will be non-None. It records interactions between boxes that would ordinarily be handled through “List 3”, but must be evaluated specially/directly because of Sources and targets with extent.
A list of arrays of global box numbers, one array per level, indicating which boxes are used with the interaction list entries of from_sep_smaller_by_level. target_boxes_sep_smaller_by_source_level[i] has length from_sep_smaller_by_level[i].num_nonempty_lists.
A list of boxtree.Tree.nlevels (corresponding to the levels on which each listed source box resides) objects, each of which has attributes count, starts, lists, num_nonempty_lists, and nonempty_indices, which form a CSR list of List 3 source boxes.
Note starts are indexed by target_boxes_sep_smaller_by_source_level . For example, for level i, lists[starts[j]:starts[j+1]] represents “List 3” source boxes of target_boxes_sep_smaller_by_source_level[i][j] on level i.
Indexed like target_boxes. See CSR-like interaction list storage.
If boxtree.Tree.sources_have_extent or boxtree.Tree.targets_have_extent, then from_sep_close_bigger_starts will be non-None. It records interactions between boxes that would ordinarily be handled through “List 4”, but must be evaluated specially/directly because of Sources and targets with extent.
from_sep_bigger_starts is indexed like target_or_target_parent_boxes. Similar to the other “close” lists, from_sep_close_bigger_starts is indexed like target_boxes. See CSR-like interaction list storage.
Changed in version 2018.2: Changed index style of from_sep_close_bigger_starts from target_or_target_parent_boxes to target_boxes.
Return a new FMMTraversalInfo instance with the contents of from_sep_close_smaller_starts and from_sep_close_bigger_starts merged into neighbor_source_boxes_starts and these two attributes set to None.
well_sep_is_n_away – Either An integer 1 or greater. (Only 1 and 2 are tested.) The spacing between boxes that is considered “well-separated” for from_sep_siblings (List 2).
from_sep_smaller_crit – The criterion used to determine separation box dimensions and separation for from_sep_smaller_by_level (List 3). May be one of "static_linf" (use the box square, possibly enlarged by Tree.stick_out_factor), "precise_linf"` (use the precise extent of targets in the box, including their radii), or ``"static_l2" (use the circumcircle of the box, possibly enlarged by Tree.stick_out_factor).
queue – A pyopencl.CommandQueue instance.
tree – A boxtree.Tree instance.
A tuple (trav, event), where trav is a new instance of FMMTraversalInfo and event is a pyopencl.Event for dependency management.