SersicProfile#
- class profiles.density.SersicProfile(**kwargs)[source]#
Sérsic Surface Density Profile.
Describes the surface brightness or surface mass density distribution of galaxies, particularly elliptical galaxies and bulges. The profile is defined as:
\[\Sigma(R) = \Sigma_0 \, \exp\left( -b_n \left[ \left( \frac{R}{R_e} \right)^{1/n} - 1 \right] \right)\]where:
\(\Sigma_0\) is the central surface density.
\(R_e\) is the effective radius enclosing half the total projected mass.
\(n\) is the Sérsic index controlling the shape (with \(n=1\) being exponential, and \(n=4\) the de Vaucouleurs profile).
\(b_n\) is a normalization constant dependent on \(n\).
Note
The constant \(b_n\) is approximately given by:
\[b_n \approx 2n - \frac{1}{3} + \frac{4}{405n} + \frac{46}{25515n^2}\]which ensures that \(R_e\) encloses half the total projected mass.
Parameters
Name
Symbol
Description
Sigma_0
\(\Sigma_0\)
Central surface density
R_e
\(R_e\)
Effective (half-light) radius
n
\(n\)
Sérsic index (controls profile shape)
Example
>>> from pisces.profiles.density import SersicProfile >>> import matplotlib.pyplot as plt >>> R = np.linspace(0.01, 10, 200) >>> profile = SersicProfile( ... Sigma_0=1.0, R_e=2.0, n=4.0 ... ) >>> Sigma = profile(R) >>> plt.semilogy(R, Sigma) >>> plt.xlabel("Radius (R)") >>> plt.ylabel("Surface Density (Sigma)") >>> plt.title("Sérsic Surface Profile (n=4)") >>> plt.grid(True) >>> plt.show()
(
Source code
,png
,hires.png
,pdf
)See also
Methods
__init__
(**kwargs)Initialize a profile instance with specific parameter values.
from_dict
(data)Reconstruct a profile instance from a dictionary.
from_hdf5
(h5obj[, name])Reconstruct a profile from HDF5 attributes.
from_json
(filepath)Reconstruct a profile from a JSON file.
from_yaml
(filepath)Reconstruct a profile from a YAML file.
get_derived_profile
(profile_name, **kwargs)Access and instantiate a derived profile by name.
get_expression_latex
([substitute])Return the LaTeX representation of the profile's symbolic expression.
get_output_units
(*argu)Determine the output units of the operation given some set of input units.
Return a LaTeX table of the profile parameters.
lambdify_expression
(expression)Convert a symbolic expression into a callable function.
List all available derived profiles for this instance.
substitute_expression
(expression)Replace symbolic parameters with numerical values in an expression.
to_dict
()Serialize this profile to a minimal dictionary representation.
to_hdf5
(h5obj[, name])Store profile metadata into an HDF5 object as attributes.
to_json
(filepath, **kwargs)Serialize the profile to a JSON file.
to_yaml
(filepath, **kwargs)Serialize the profile to a YAML file.
Attributes
Get the available derived profile classes for this instance.
Get the symbolic representations of the coordinate system parameters.
The parameters of this coordinate system.
The symbols representing each of the coordinate axes in this coordinate system.
The axes names present in this coordinate system.