Skip to content
Projects

tree_d_3d.kernels.cart_moments_upward.cart_moments_upward_numpy

The version of the cart_moments_upward kernel for machines without Pyccel.

cart_moments_upward_pyccel.py vectorized over the cells of a level: the leaves sum the monomials of all their particles at once, the parents shift the moments of all their children at once (the rows of shift as one matrix product).

Functions

NameDescription
cart_moments_upwardMoments m_g = sum_j q_j (r_j - c)^g of every node, from the deepest level up.

cart_moments_upwardfunction#

def cart_moments_upward(pos, charge, perm, levels, node_center, node_start, node_end, node_child, mono_parent, mono_dir, shift, shift_coef, moments)

Moments m_g = sum_j q_j (r_j - c)^g of every node, from the deepest level up.

See cart_moments_upward_pyccel.