galpy.potential.Potential.mass¶
-
Potential.
mass
(R, z=None, t=0.0, forceint=False)¶ NAME:
massPURPOSE:
evaluate the mass enclosedINPUT:
R - Cylindrical Galactocentric radius (can be Quantity)
z= (None) vertical height (can be Quantity)
t - time (optional; can be Quantity)
KEYWORDS:
forceint= if True, calculate the mass through integration of the density, even if an explicit expression for the mass existsOUTPUT:
- for spherical potentials: M(<R) [or if z is None], when the mass is implemented explicitly, the mass enclosed within r = sqrt(R^2+z^2) is returned when not z is None; forceint will integrate between -z and z, so the two are inconsistent (If you care to have this changed, raise an issue on github)
- for axisymmetric potentials: M(<R,<fabs(Z))
HISTORY:
2014-01-29 - Written - Bovy (IAS)
2019-08-15 - Added spherical warning - Bovy (UofT)