quokka-astro / quokka

Two-moment AMR radiation hydrodynamics (with self-gravity, particles, and chemistry) on CPUs/GPUs for astrophysics
https://quokka-astro.github.io/quokka/
MIT License
46 stars 12 forks source link

add cosmological expansion terms #699

Open BenWibking opened 2 months ago

BenWibking commented 2 months ago

Describe the proposal Add cosmological expansion (i.e., Hubble flow) terms to the equations of motion.

The easiest way to do this may be to adopt supercomoving coordinates (Martel & Shapiro 1997), although it's unclear whether this generalizes to beyond a gamma-law EOS.

We can also adopt the trick used by FLASH to integrate the Friedmann equation exactly (https://flash.rochester.edu/site/flashcode/user_support/flash4_ug_4p71/node137.html), although the documentation does not reflect what the code actually does for this.

Describe alternatives you've considered Don't do cosmology.

Additional context This is needed for cosmological PopIII stars.

cc @psharda

BenWibking commented 2 months ago

Nyx reference: https://amrex-astro.github.io/Nyx/docs_html/NyxEquations.html

BenWibking commented 2 months ago

Zel'dovich Pancake test problem from FLASH: https://flash.rochester.edu/site/flashcode/user_support/flash4_ug_4p71/node190.html#SECTION010142000000000000000