autogalaxy.profiles.mass.SersicGradient#
- class SersicGradient[source]#
Bases:
AbstractSersicSetup a Sersic mass and light profiles.
- Parameters:
centre (
Tuple[float,float]) – The (y,x) arc-second coordinates of the profile centre.ell_comps (
Tuple[float,float]) – The first and second ellipticity components of the elliptical coordinate system.intensity (
float) – Overall flux intensity normalisation in the light profiles (electrons per second).effective_radius (
float) – The circular radius containing half the light of this profile.sersic_index (
float) – Controls the concentration of the profile (lower -> less concentrated, higher -> more concentrated).mass_to_light_ratio (
float) – The mass-to-light ratio of the light profile.mass_to_light_gradient (
float) – The mass-to-light radial gradient.
Methods
angleThe position angle in degrees of the major-axis of the ellipse defined by profile, defined counter clockwise from the positive x-axis (0.0 > angle > 180.0).
angle_radiansThe position angle in radians of the major-axis of the ellipse defined by profile, defined counter clockwise from the positive x-axis (0.0 > angle > 2pi).
angle_to_profile_grid_fromThe angle between each angle theta on the grid and the profile, in radians.
axis_ratioThe ratio of the minor-axis to major-axis (b/a) of the ellipse defined by profile (0.0 > q > 1.0).
Calculate the projected convergence at a given set of arc-second gridded coordinates.
convergence_2d_via_cse_fromCalculate the projected 2D convergence from a grid of (y,x) arc second coordinates, by computing and summing the convergence of each individual cse used to decompose the mass profile.
convergence_cse_1d_fromOne dimensional function which is solved to decompose a convergence profile in cored steep ellipsoids, given by equation (14) of Oguri 2021 (https://arxiv.org/abs/2106.11464).
Returns the convergence of the mass profile as a function of the radial coordinate.
Decompose the convergence of the Sersic profile into singular isothermal elliptical (sie) profiles.
deflections_2d_via_cse_fromCalculate the projected 2D deflection angles from a grid of (y,x) arc second coordinates, by computing and summing the convergence of each individual cse used to decompose the mass profile.
deflections_2d_via_potential_2d_fromReturns the 2D deflection angles of the mass profile by numerically differentiating the lensing potential on the input grid.
deflections_via_cse_fromReturns the deflection angles of a 1d cored steep ellisoid (CSE) profile, given by equation (19) and (20) of Oguri 2021 (https://arxiv.org/abs/2106.11464).
deflections_yx_2d_fromReturns the 2D deflection angles of the mass profile from a 2D grid of Cartesian (y,x) coordinates.
density_between_circular_annuliCalculate the mass between two circular annuli and compute the density by dividing by the annuli surface area.
eccentric_radii_grid_fromConvert a grid of (y,x) coordinates to an eccentric radius: :math: axis_ratio^0.5 (x^2 + (y^2/q))^0.5
elliptical_radii_grid_fromConvert a grid of (y,x) coordinates to their elliptical radii values: :math: (x^2 + (y^2/q))^0.5
extract_attributeReturns an attribute of a class and its children profiles in the galaxy as a ValueIrregular or Grid2DIrregular object.
hasReturns True if any attribute of this profile is an instance of the input class cls, else False.
image_2d_via_radii_fromReturns the intensity of the profile at a given radius.
mass_angular_within_circle_fromIntegrate the mass profiles's convergence profile to compute the total mass within a circle of specified radius.
mass_integralIntegrand used by mass_angular_within_circle_from to compute the total projected mass within a circle.
potential_2d_fromReturns the 2D lensing potential of the mass profile from a 2D grid of Cartesian (y,x) coordinates.
potential_funcReturns the integrand of the lensing potential at a single point, used in numerical integration schemes for computing the potential from the mass profile's convergence.
radial_deflection_fromradial_grid_fromConvert a grid of (y, x) coordinates, to their radial distances from the profile centre (e.g. :math: r = sqrt(x**2 + y**2)).
rotated_grid_from_reference_frame_fromRotate a grid of (y,x) coordinates which have been transformed to the elliptical reference frame of a profile back to the original unrotated coordinate grid reference frame.
transformed_from_reference_frame_grid_fromTransform a grid of (y,x) coordinates from the reference frame of the profile to the original observer reference frame.
transformed_to_reference_frame_grid_fromTransform a grid of (y,x) coordinates to the reference frame of the profile.
vmapped_deflections_fromAttributes
average_convergence_of_1_radiusThe radius a critical curve forms for this mass profile, e.g. where the mean convergence is equal to 1.0.
elliptical_effective_radiusThe effective_radius of a Sersic light profile is defined as the circular effective radius.
ellipticity_rescaleA rescaling factor applied to account for the ellipticity of the mass profile when computing the Einstein radius from the average convergence equals unity criterion.
sersic_constantA parameter derived from Sersic index which ensures that effective radius contains 50% of the profile's total integrated light.
- convergence_2d_from(grid, xp=<module 'numpy' from '/home/docs/checkouts/readthedocs.org/user_builds/pyautogalaxy/envs/latest/lib/python3.11/site-packages/numpy/__init__.py'>, **kwargs)[source]#
Calculate the projected convergence at a given set of arc-second gridded coordinates.
- Parameters:
grid (
Union[ndarray,Grid2D,Grid2DIrregular]) – The grid of (y,x) arc-second coordinates the convergence is computed on.
- convergence_func(grid_radius, xp=<module 'numpy' from '/home/docs/checkouts/readthedocs.org/user_builds/pyautogalaxy/envs/latest/lib/python3.11/site-packages/numpy/__init__.py'>)[source]#
Returns the convergence of the mass profile as a function of the radial coordinate.
This is used to integrate the convergence profile to compute enclosed masses and the Einstein radius.
- decompose_convergence_via_cse(grid_radii)[source]#
Decompose the convergence of the Sersic profile into singular isothermal elliptical (sie) profiles.
This decomposition uses the standard 2d profile of a Sersic mass profile.
- Parameters:
func – The function representing the profile that is decomposed into CSEs.
radii_min – The minimum radius to fit
radii_max – The maximum radius to fit
total_sies – The number of SIEs used to approximate the input func.
sample_points (int (should be larger than 'total_sies')) – The number of data points to fit
- Returns:
A list of amplitudes and core radii of every singular isothernal ellipsoids (sie) the mass profile is decomposed into.
- Return type:
Tuple[List, List]