exoctk.limb_darkening package¶
Submodules¶
exoctk.limb_darkening.limb_darkening_fit module¶
A module to calculate limb darkening coefficients from a grid of model spectra
-
class
exoctk.limb_darkening.limb_darkening_fit.
LDC
(model_grid='ACES')[source]¶ Bases:
object
A class to hold all the LDCs you want to run
Initialize an LDC object
- Parameters
- model_grid: exoctk.modelgrid.ModelGrid
The grid of synthetic spectra from which the coefficients will be calculated
-
static
bootstrap_errors
(mu_vals, func, coeffs, errors, n_samples=1000)[source]¶ Bootstrapping LDC errors
- Parameters
- mu_vals: sequence
The mu values
- func: callable
The LD profile function
- coeffs: sequence
The coefficients
- errors: sequence
The errors on each coeff
- n_samples: int
The number of samples
- Returns
- tuple
The lower and upper errors
-
calculate
(Teff, logg, FeH, profile, mu_min=0.05, ld_min=0.01, bandpass=None, name=None, color=None, **kwargs)[source]¶ Calculates the limb darkening coefficients for a given synthetic spectrum. If the model grid does not contain a spectrum of the given parameters, the grid is interpolated to those parameters.
Reference for limb-darkening laws: http://www.astro.ex.ac.uk/people/sing/David_Sing/Limb_Darkening.html
- Parameters
- Teff: int
The effective temperature of the model
- logg: float
The logarithm of the surface gravity
- FeH: float
The logarithm of the metallicity
- profile: str
The name of the limb darkening profile function to use, including ‘uniform’, ‘linear’, ‘quadratic’, ‘square-root’, ‘logarithmic’, ‘exponential’, and ‘4-parameter’
- mu_min: float
The minimum mu value to consider
- ld_min: float
The minimum limb darkening value to consider
- bandpass: svo_filters.svo.Filter() (optional)
The photometric filter through which the limb darkening is to be calculated
- name: str (optional)
A name for the calculation
- color: str (optional)
A color for the plotted result
-
plot
(fig=None, show=False, **kwargs)[source]¶ Plot the LDCs
- Parameters
- fig: matplotlib.pyplot.figure, bokeh.plotting.figure (optional)
An existing figure to plot on
- show: bool
Show the figure
-
exoctk.limb_darkening.limb_darkening_fit.
ld_profile
(name='quadratic', latex=False)[source]¶ Define the function to fit the limb darkening profile
- Reference:
https://www.cfa.harvard.edu/~lkreidberg/batman/ tutorial.html#limb-darkening-options
- Parameters
- name: str
The name of the limb darkening profile function to use, including ‘uniform’, ‘linear’, ‘quadratic’, ‘square-root’, ‘logarithmic’, ‘exponential’, ‘3-parameter’, and ‘4-parameter’
- latex: bool
Return the function as a LaTeX formatted string
- Returns
- function, str
The corresponding function for the given profile
Module contents¶
Package to generate limb darkening coefficients from a grid of model spectra