FastchemWrapper#
- class shone.chemistry.fastchem.FastchemWrapper(temperature, pressure, metallicity=1, c_to_o_ratio=0.5888, elemental_abundances_path=None, fit_coefficients_path=None, fit_coefficients_condensates_path=None, rainout_condensation=False, equilibrium_condensation=False, quiet=False)[source]#
Bases:
objectWrapper around pyfastchem.
FastChem computes mixing ratios for atmospheric species assuming equilibrium chemistry [1], [2], [3], [4].
References
[1]Stock, J. W., Kitzmann, D., Patzer, A. B. C., et al. 2018, Monthly Notices of the Royal Astronomical Society, 479, 865. doi:10.1093/mnras/sty1531
[2]Stock, J. W., Kitzmann, D., & Patzer, A. B. C. 2022, Monthly Notices of the Royal Astronomical Society, 517, 4070. doi:10.1093/mnras/stac2623
[3]Kitzmann, D., Stock, J. W., & Patzer, A. B. C. 2024, Monthly Notices of the Royal Astronomical Society, 527, 7263. doi:10.1093/mnras/stad3515
- Parameters:
temperature (array-like) – Temperature grid [K].
pressure (array-like) – Pressure grid [bar].
metallicity (float, optional) – M/H expressed as a linear factor (not log).
c_to_o_ratio (float, optional) – Carbon to oxygen ratio expressed as a linear factor (not log). Default is the C/O ratio of the solar abundances from Asplund et al. (2020):
0.5888.elemental_abundances_path (str (path-like), optional) – Path to elemental abundances for FastChem.
fit_coefficients_path (str (path-like), optional) – Path to fit coefficients for FastChem.
fit_coefficients_condensates_path (str (path-like), optional)
rainout_condensation (bool, optional)
equilibrium_condensation (bool, optional)
quiet (bool, optional) – Raise warnings for machine configurations that may produce inaccurate results. Default is False.
Methods Summary
get_column_index([fastchem_name, species_name])Return the column of the FastChem result corresponding to a given species or list of species.
Return an astropy table with names, symbols, weights and indices for each species in this FastChem instance.
Get weights for each species [AMU].
mmr_mmw()Mass mixing ratio (MMR) multiplied by the mean molecular weight (MMW).
vmr()Volume mixing ratio.
Methods Documentation
- get_column_index(fastchem_name=None, species_name=None)[source]#
Return the column of the FastChem result corresponding to a given species or list of species.
- Parameters:
- Returns:
idx – Column index.
- Return type:
- get_species()[source]#
Return an astropy table with names, symbols, weights and indices for each species in this FastChem instance.
- Returns:
species_table – Table of FastChem species.
- Return type: