save_profile_table

deprojected_sersic_models.io.save_profile_table(table=None, path=None, filename_base='deproj_sersic_model', filename=None, overwrite=False)[source]

Save the table of Sersic profile values in a binary FITS table.

Parameters:
  • table (dict) – The dictionary of the table for a particular n, invq

  • path (str, optional) – Path to directory containing the saved Sersic profile tables. If not set, system variable DEPROJECTED_SERSIC_MODELS_DATADIR must be set. Default: system variable DEPROJECTED_SERSIC_MODELS_DATADIR, if specified.

  • filename_base (str, optional) – Base filename to use, when combined with default naming convention: <filename_base>_nX.X_invqX.XX.fits. Default: deproj_sersic_model

  • filename (str, optional) – Option to override the default filename convention and instead directly specify the file location. (FITS format)

  • overwrite (bool, optional) – Option to overwrite the FITS file, if a previous version exists. Default: False (will throw an error if the file already exists).

Notes

Saves a binary FITS table containing Sersic profile values.

The table includes:

R: array of radii [kpc]

invq: inverse intrinsic axis ratio

q: intrinsic axis ratio

n: Sersic index

Reff: Effective radius of Sersic profile (the projected 2D half-light radius)

total_mass: Total mass used for calculation

menc3D_sph: Mass enclosed within a sphere of radius R

vcirc: Circular velocity profile at R

rho: Density at m=R

dlnrho_dlnR: Derivative of ln(rho) w.r.t. ln(R) at m=R.

menc3D_sph_Reff: Mass enclosed within a sphere of radius r=Reff

vcirc_Reff: Circular velocity profile at R=Reff

ktot_Reff: Total virial coefficient at Reff

k3D_sph_Reff: Virial coefficient to convert between menc3D and vcirc at Reff

rhalf3D_sph: 3D half mass radius (defined within spherical apertures)