Skip to main content

1D relaxation Parker wind model with metal and X-ray physics based on Murray-Clay et al. (2009)

Project description

Wind-AE (BETA)

Read the Docs

Wind-AE (pronounced /windy/) stands for "wind atmospheric escape" and is a relatively fast 1D, steady-state, hydrodynamic, non-isothermal, Parker wind relaxation code for modeling atmospheric escape based on Murray-Clay et al. (2009). Wind-AE is a forward model that solves the energy conservation, momentum conservation, and ionization equilibrium equations at the substellar point using the "Numerical Recipes in C" relaxation method. This allows Wind-AE to quickly compute the atmosphere mass loss rate as well as upper atmosphere (<~100 microbar) velocity, temperature, density, and ionization structure as a function of altitude.

Wind-AE updates Murray-Clay et al. (2009) to allow for the modeling of atomic metals and multifrequency XUV stellar spectra (Broome et al. submitted). If you use Wind-AE, please consider citing Broome et al. (submitted).

We appreciate your patience while the docs are developed. In the meantime, take advantage of Notebooks/Quickstart.ipynb to get a quick orientation to Wind-AE and please report any bugs via Github or via email to mabroome@ucsc.edu.

Build Status Coverage Status PyPI - Version Read the Docs (version) License A rectangular badge, half black half purple containing the text made at Code Astro

Is Wind-AE the right tool for me?

Wind-AE is well-suited for users interested in quickly estimating mass loss rates or outflow structure. Outflow structure includes bulk temperature and per-species ionization fractions as a function of radius, so can be easily translated into approximating and predicting observables and transits, including metastable helium (He 10830$\AA$) transits, though a He transit module is not yet included. Precise modeling of lower atmosphere ($\lssim 100 \mu$bar) is considered necessary for highly accurate transit models, but Wind-AE can be easily coupled to lower atmosphere photochemistry models whose outputs can (e.g., radius, temperature, abundances, ionization fractions, etc. at 1 $\mu$bar) can be fed into Wind-AE as inputs.

If you are interested in outflow structure: Past the Coriolis turning radius (a few planetary radii) 3D physics dominates, so Wind-AE does not integrate past that point. Wind-AE also makes simplifying assumptions about the region below the region below the wind-launch radius (~10 nanobars).

Because Wind-AE runs on the order of seconds to minutes, it can be (and has been) used to model planet evolution.

Wind-AE can model:

  • Multiple atomic species
  • X-ray physics (secondary ionizations and K-shell ionization cross-sections for relevant metals)
  • Both low and high stellar XUV flux
  • Heating & Cooling: Ionization heating, bolometric heating & cooling (negligible in wind), PdV cooling (work done due to expansion of gas), radiative / atomic line cooling (Lyman-$\alpha$, OI, OII, OIII, CI, CII), recombination cooling

Wind-AE does not (currently) include:

  • Magnetic fields

  • Time dependence

  • Diffusion/drag - the atomic species set by the user are assumed to be entrained in the outflow and in thermal equilibrium. This is an appropriate assumption for species below the crossover mass and a warning will be raised.

  • Heating & Cooling: Conduction (warning raised if relevant, planned), H3+ line cooling (not planned), Fe & Ca line cooling (relevant at high Z only, planned), free-free cooling (warning raised if relevant, not planned)

  • Multiple ionization states of the same species (planned) See Broome et al. (submitted) for more details.

  • Want a rapid H/He model with power-law approximated XUV spectra? Check out ATES (Caldiroli et al. 2021)

  • Do you want to set the mass loss rate ($\dot{M}$) yourself or want an EUV isothermal Parker wind outflow model that runs in nanoseconds? Check out p-winds (Dos Santos et al. 2022).

  • Do you want to use p-winds and get transit models for metals via Cloudy? Check out Sunbather (Linssen et al. 2024)

  • Want to leverage Cloudy and the hydrodynamic code PLUTO for more thorough XUV-irradiated, but slightly more expensive calculations? Check out TPCI (Salz et al. 2015)

  • That sound great, but you prefer to code in Python over C/C++? Check out pyTPCI. (Riley, Zhang, & Bean 2025)

  • Do you care about diffusion throughout the wind? Check out AIOLIS (Schulik & Booth, 2022).

  • Want to model the lower atmosphere in more detail? Check out CETIMB (Koskinen et al. 2022)

  • Just want a grid of mass loss rates for pure-Hydrogen, low-flux-EUV-irradiated planets? See Kubyshkina & Fossati

  • Want a grid of mass loss rates for pure-Hydrogen, high-flux-XUV-irradiated planets? See Owen & Jackson (2012)

Want your model added to this list or to update the short bio? Email mabroome@ucsc.edu

Requirements

Wind-AE requires the following packages and will pip install them automatically by following the Installation guide below.

  • python>3.13
  • numpy
  • scipy
  • astropy
  • pandas>=2.2.3
  • matplotlib
  • datetime
  • pyarrow
  • fastparquet
  • requests
  • ChiantiPy

Installation

Until Wind-AE is dockerized, it is recommended to use a Python environment to avoid dependency issues. However, if your system meets the above requirements, there is no need to create an environment and you can skip to the compilation step.

To create an environment use either

python3 -m venv venv_name.venv
source venv_name.venv/bin/activate

or using conda

conda create -n venv_name
conda activate venv_name
conda install pip

Pip install

Recommended:

pip install --upgrade pip

Then

pip install wind_ae

OR Compile from source (BETA)

Clone the repository using

git clone https://github.com/mibroome/wind-ae/

or navigate to github.com/mibroome/wind-ae/ and download and unzip the zip file.

To compile from the source,

pip install -r requirements.txt
pip install -e .

Confirming the import was successful

Run tests (optional). Estimated time: 4 minutes.

cd wind-ae && pytest

Otherwise, you can test the install by running

python -c "import wind_ae"

Now you can run Wind-AE from anywhere! As seen in the tutorial (Notebooks/Quickstart.ipynb), the following imports are helpful for most purposes.

from wind_ae.wrapper.relax_wrapper import wind_simulation as wind_sim
from wind_ae.wrapper.wrapper_utils.plots import energy_plot six_panel_plot quick_plot 
from wind_ae.wrapper.wrapper_utils import constants as const
from wind_ae.wrapper.wrapper_utils.system import system
from wind_ae.wrapper.wrapper_utils.spectrum import spectrum

Note: If you ever need to interface directly with the C code, it lives in wind_ae/src/ and can be excecuted from within the wind_ae/ folder via ./bin/relaxed_ae. The solution generated will be for a planet with the parameters detailed in the input files in the Inputs/ folder. There is generally no need to interface with the C code and most standard tasks can be accomplished by using the Python wrapper.

Future features and known problems:

  • Computation of the complementary error function that governs the drop-off of bolometric heating/cooling is not truly self-consistent (converge_mol_atomic_transition(polish=True, width=)) and may require visual confirmation via energy_plot() (checking whether bolometric heating/cooling impede too far into photoionization heating or fall too short) and manual adjustment of the width parameter or:
sim.load_planet('path/to/planet/file')
bcs = np.copy(sim.windsoln.bcs_tuple)
# erf_loc - normalized velocity value at radius where you want the erf to drop
# erf_rate - how quickly the erf drops off in units of Hsc at erf_loc
# To get initial estimate, run sim.erf_velocity(polish=True)
bcs[-1] = np.array([erf_loc, erf_rate])
sim.inputs.write_bcs(*bcs)
sim.run_wind()
  • Knudsen number calculations currently only contain H-H collisions.
  • Converting spectrum kind from 'full' to 'mono' occasionally has issues.

Check out the open issues.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

wind_ae-0.5.7.tar.gz (1.5 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

wind_ae-0.5.7-py3-none-any.whl (1.6 MB view details)

Uploaded Python 3

File details

Details for the file wind_ae-0.5.7.tar.gz.

File metadata

  • Download URL: wind_ae-0.5.7.tar.gz
  • Upload date:
  • Size: 1.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.12

File hashes

Hashes for wind_ae-0.5.7.tar.gz
Algorithm Hash digest
SHA256 642c352bb38c6557bf8cc68a2b81fbd0bea48940be11213d480fa25f37cbf45c
MD5 46cf782e33c0bf3b37d6ea8e98334f24
BLAKE2b-256 e1c04807815a3139445da3a48858ee5b08b53e340242974956405d348ee755d4

See more details on using hashes here.

File details

Details for the file wind_ae-0.5.7-py3-none-any.whl.

File metadata

  • Download URL: wind_ae-0.5.7-py3-none-any.whl
  • Upload date:
  • Size: 1.6 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.12

File hashes

Hashes for wind_ae-0.5.7-py3-none-any.whl
Algorithm Hash digest
SHA256 7bf949f960d128093593f3b0b4e677f4d4baca283b0f6b0a6779190497e52be1
MD5 96f0094402978ea8f78f30f83ecceba9
BLAKE2b-256 5ce0d7972c6847c4ec54ab6a4a8fac6b8c1143c9a098b01eaf701582c67a975a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page