pynbody.gravity.calc

pynbody.gravity.calc#

Gravity calculations

Functions

all_direct(f[, eps])

Calculate the potential and acceleration for all particles in the snapshot using a direct summation algorithm.

all_pm(f[, ngrid])

Calculate the potential and acceleration for all particles in the snapshot using a Particle-Mesh algorithm.

midplane_potential(f, rxy_points[, eps])

Calculate the potential of a disk galaxy in the x-y midplane (with z=0)

midplane_rot_curve(f, rxy_points[, eps])

Calculate the rotation curve of a disk galaxy in the x-y midplane (with z=0)

pm(f, ipos[, ngrid, x0, x1])

Calculate the potential and acceleration for a set of particles using a Particle-Mesh algorithm.