exosim.tasks.sed.prepareSed#

Classes#

PrepareSed

Returns a source SED.

Module Contents#

class PrepareSed[source]#

Bases: exosim.tasks.task.Task

Returns a source SED. The SED depends on the source type selected. This Task analyse the inputs and return the desired SED.

Returns:

Star Sed

Return type:

Sed

Examples

We first define all the inputs and then we show how to produce the star sed:

>>> from exosim.tasks.sed import LoadPhoenix
>>> wavelength = np.linspace(0.5, 7.8, 10000) * u.um
>>> T = 5778 * u.K
>>> R = 1 * u.R_sun
>>> D = 1 * u.au
>>> M = 1 * u.Msun
>>> z = 0.0
>>> g = (cc.G * M.si / R.si ** 2).to(u.cm / u.s ** 2)
>>> logg = np.log10(g.value)

To produce a planck star:

>>> prepareSed = LoadPhoenix()
>>> sed = PrepareSed(source_type='planck', wavelength=wavelength, T=T, R=R, D=D)

To load a Phoenix star: >>> sed_l = prepareSed(source_type=’phoenix’, path=phoenix_stellar_model, T=T, R=R, D=D, logg=logg, z=z)

execute()[source]#

Class execution. It runs on call and executes all the task actions returning the outputs. It requires the input with correct keywords