Exponentially-truncated NFW potential

class galpy.potential.ExpTruncNFWPotential(amp=1.0, a=1.0, rc=2.0, mass=None, normalize=False, ro=None, vo=None)[source]

Class that implements the exponentially-truncated NFW potential

\[\rho(r) = \frac{\mathrm{amp}}{4\,\pi\,a^3}\,\frac{e^{-r/r_c}}{(r/a)\,(1+r/a)^{2}}\]

i.e., the NFW profile multiplied by an exponential cutoff with truncation radius \(r_c\). All methods are closed-form: the enclosed mass and the outer-potential integral are expressible through the exponential integral \(E_1\) (scipy.special.exp1()), with a small-\(r\) Taylor expansion used to avoid catastrophic cancellation when \(r \ll a, r_c\). Has a C implementation, enabling fast orbit integration and the full 3D variational equations (Orbit.integrate_dxdv).

__init__(amp=1.0, a=1.0, rc=2.0, mass=None, normalize=False, ro=None, vo=None)[source]

Initialize an exponentially-truncated NFW potential.

Parameters:
  • amp (float or Quantity, optional) – Amplitude to be applied to the potential (default: 1); can be a Quantity with units of mass or Gxmass. This is the NFW mass-scale \(4\pi\,\rho_s\,a^3\), matching the amp convention of NFWPotential (in the \(r_c \to \infty\) limit the two potentials coincide for equal amp and a). Ignored if mass is set.

  • a (float or Quantity, optional) – Scale radius (can be Quantity).

  • rc (float or Quantity, optional) – Exponential truncation radius (can be Quantity).

  • mass (float or Quantity, optional) – Total mass of the (finite-mass) profile; if set, amp is determined from it as amp = mass / [exp(a/rc)(1+a/rc)E_1(a/rc) - 1] and the amp argument is ignored.

  • normalize (bool or float, optional) – If True, normalize such that vc(1.,0.)=1., or, if given as a number, such that the force is this fraction of the force necessary to make vc(1.,0.)=1.

  • ro (float or Quantity, optional) – Distance scale for translation into internal units (default from configuration file).

  • vo (float or Quantity, optional) – Velocity scale for translation into internal units (default from configuration file).

Notes

  • Initialize with one of: a and (amp or normalize); or a and mass.

  • The closed-form total mass becomes unevaluable in floating point for an extremely sharp truncation, a / rc \(\gtrsim 700\) (i.e., rc several hundred times smaller than a); this is far outside any physically sensible choice of rc (which should be comparable to or larger than a), so no explicit check is made for it.

  • 2026-06-16 - Written - Pfaffman + Claude Code