Skip to content
Projects

tree_d_3d.kernels.fmm_evaluate.fmm_evaluate_numpy

The version of the fmm_evaluate kernel for machines without Pyccel.

There is no vectorized form (the near field walks the leaf pairs): this is the algorithm of fmm_evaluate_pyccel.py, run by the Python interpreter.

Functions

NameDescription
fmm_evaluateFar field from leaf local expansions plus exact mutual near field.

fmm_evaluatefunction#

def fmm_evaluate(pos: float[:, :], charge: float[:], perm: int64[:], node_count: int, node_center: float[:, :], node_start: int64[:], node_end: int64[:], node_child: int64[:], local_re: float[:, :], local_im: float[:, :], pairs: int64[:, :], count: int, softening: float, with_potential: int, phi: float[:], field: float[:, :], status: int64[:]) -> None

Far field from leaf local expansions plus exact mutual near field.

Every particle is a target; self-interaction is excluded. With with_potential = 0 the near-field potential is skipped, which saves a logarithm per pair when only forces are needed. status[0] becomes 1 + a particle that met an unsoftened coincident charge.