-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Radiative torus #104
Radiative torus #104
Conversation
…d_torus Conflicts: src/radiation/moments.cpp
src/radiation/moments.cpp
Outdated
|
||
const Real ug1 = rho_ * eos_.InternalEnergyFromDensityTemperature(rho_, T, lambda); | ||
|
||
return ((ug1 - ug0_) + (dJ_tot)) / (ug0_ + J0_tot); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@lroberts36 Here is the implicit-in-fluid-temperature residual. I solve ug(T^n+1) - ug(T^n) = ur^n+1 - ur^n
in the fluid frame. Then after I get T^n+1
, I use LinearSourceUpdate
to get dE
and dF
and update the conserved radiation and fluid variables as usual.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I like this, it is a good solution.
src/radiation/moments.cpp
Outdated
} | ||
} // for ispec | ||
|
||
/* for (int ispec = 0; ispec < num_species; ++ispec) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll go back and make the source update algorithm a runtime option, probably a templated FluidSourceImpl
function like we do elsewhere.
OK if tests pass I think this is ready to merge if you are happy with it @Yurlungur |
I am happy with it |
Also great work. Awesome to have GRRMHD working. |
Thanks for your detailed review @Yurlungur! Much appreciated. |
PR Summary
Add radiation as an option to the torus problem. Either zero initial radiation or equipartition of Fishbone solution pressure between fluid and radiation inside the initial torus.
PR Checklist
scripts/bash/format.sh
.GetFlatIdx
to return default values when variable not included in packmain
nspec
for radiation sourcesnspec
duringFixFluxes
plot_snap2d.py
torus_rad.pin
scattering_fraction
with separate scattering opacity callkappa_max
to radiation ceilings, propagate through radiation fluid source codeNumRadiationTypes
withMaxNumRadiationTypes
nvcc
in this PR