Skip to content
Projects

tree_d_3d.kernels.direct_log_sum.direct_log_sum_numpy

The NumPy version of the direct_log_sum kernel, for machines without Pyccel.

Vectorized over blocks of targets and all sources; the same arguments and results as direct_log_sum_pyccel.py.

Attributes

NameDescription
CHUNKNo description.

Functions

NameDescription
direct_log_sumAll-pairs line-charge potential and field; same conventions.

CHUNKattributemodule attribute#

CHUNK = 256

direct_log_sumfunction#

def direct_log_sum(targets: np.ndarray, exclude: np.ndarray, pos: np.ndarray, charge: np.ndarray, softening: float, phi: np.ndarray, field: np.ndarray, status: np.ndarray) -> None

All-pairs line-charge potential and field; same conventions.

status[0] becomes 1 + a target that met an unsoftened coincident charge.