Planets#

Planets as point sources: each goes through the coronagraph with its exact PSF.

class toycoronagraph.sources.planets.Planet(**settings)[source]#

Bases: Source

One planet, an unresolved source (point_sources(); no image is rendered).

family is “physical” (brightness in Jy) or “relative” (a contrast), set by brightness_unit.

Check and store the module’s own parameters.

Parameters:

**settings – {param name: value}; each is converted with toycoronagraph.params.convert (units in text, “auto”, choices…); parameters not given take their default.

Raises:

ParamError – unknown parameter names (with a suggestion) or invalid values, all listed.

family_of()[source]#

The family given by brightness_unit.

Returns:

“relative” for “contrast”, else “physical”.

Return type:

str

position()[source]#

The planet’s position from the star.

mode “cartesian”: pos = [x, y] in arcsec; “polar”: pos = [r arcsec, angle deg]; “moving”: pos = [a arcsec, e, PA deg, inc deg, t] for planet.planet_position (t: the fraction of the orbital period, its integer part dropped).

Returns:

(radius in arcsec, angle in rad from +x towards +y).

Return type:

tuple

point_sources(grid, star)[source]#

The planet as one point source.

Parameters:
Returns:

[((radius arcsec, angle rad), flux)]: flux in Jy, or the fraction of the star’s flux (brightness_unit “contrast”).

Return type:

list