Skip to content
Projects

tree_d_3d.kernels.fmm_downward.fmm_downward_pyccel

The Pyccel version (CPU) of the fmm_downward kernel of the Barnes-Hut and FMM solvers.

fmm_downward_cuda.cu next to this file is the CUDA version (GPU) and fmm_downward_numpy.py the version for machines without Pyccel, all with the same arguments; the folder’s __init__.py declares the kernel (see :mod:tree_d_3d.kernels). The flat quadtree is described in :mod:tree_d_3d.flat_tree.

Functions

NameDescription
fmm_downwardShift the local expansions of nodes first_node:last_node into their children.

fmm_downwardfunction#

def fmm_downward(first_node: int, last_node: int, node_center: float[:, :], node_child: int64[:], binomial: float[:, :], power_re: float[:], power_im: float[:], local_re: float[:, :], local_im: float[:, :]) -> None

Shift the local expansions of nodes first_node:last_node into their children.

Call it level by level from the root: a node’s expansion is complete only after its parent’s was shifted into it (the nodes of a level are contiguous).