sunbather.tools
Tools for sunbather
Functions
|
Takes an atmospheric quantity as a function of altitude/radius, and returns it as a 2D array of that same quantity as a function of distance from the top of the atmosphere. |
|
Calculates the mean particle mass of an atomic/ionic gas mixture, but neglecting molecules (and the negligible mass contributed by electrons). |
|
Makes a copy of a Cloudy input file and appends commands. |
|
Finds the column name of the .den file that corresponds to the ground state of the given line. |
|
Reads in an SED file and returns the normalization in monochromatic flux (i.e., nu*F_nu or lambda*F_lambda) and Ryd units. |
|
Returns a dictionary of the fractional abundances of each element (sums to 1). |
|
|
|
Returns the mass of an atomic or positive ion. |
|
Returns a list of atomic and ionic species names. |
|
|
|
Returns a dictionary of the scale factors of each element relative to solar. |
|
Converts a hydrogen number density in units of cm-3 to a mass density in units of g cm-3, for a given chemical composition. |
|
Takes a Cloudy .in input file and adds extra species to the 'save species densities' command. |
|
Reads a .con file from the 'save continuum units angstrom' command. |
|
Reads a .cool file from the 'save cooling' command. |
|
Reads a .coolH2 file from the 'save H2 cooling' command, which keeps track of cooling and heating processes unique to the H2 molecule, when using the 'database H2' command. |
|
Reads a .den file from the 'save species densities' command. |
|
Reads a '.en' file from the 'save species energies' command. |
|
Reads a .heat file from the 'save heating' command. |
|
Reads in a '.ovr' file from the 'save overview' command. |
|
Reads an isothermal Parker wind profile as generated by the construct_parker.py module. |
|
|
|
Takes a Cloudy law (e.g., dlaw or tlaw) and a formatter, and removes duplicate rows from the law. |
|
Converts a mass density in units of g cm-3 to a hydrogen number density in units of cm-3, for a given chemical composition. |
|
Returns the Hill/Roche radius. |
|
Run a Cloudy simulation from within Python. |
|
Sets the xscale of a figure to represent altitude/radius in units of planetary radius. |
|
Set project path and ensure it has a planets.txt file |
|
Smooth an array using a Gaussian filter, but smooth the start and end of the array with a Savitzky-Golay filter. |
|
Takes a list of species names and returns a long string with those species |
|
Prints the provided string only if verbose is True. |
|
Writes a Cloudy input file for simulating an exoplanet atmosphere. |
Classes
|
Class that stores a Parker wind profile and its parameters. |
|
Class that stores planet/star parameters. |
|
Loads the output of a Cloudy simulation. |