Prepare for multigroup radiation (starting with jaybenne) in artemis. - #135
Prepare for multigroup radiation (starting with jaybenne) in artemis.#135RyanWollaeger wants to merge 8 commits into
Conversation
+ Move gas opacity initialization inside radiation initialization. + Update jaybenne, singularity submodules. + Add scattering powerlaw to artemis opacity variants.
+ Add frequency_type to radiation/imc input nodes.
cd28d9c to
0fc437c
Compare
+ Bump singularity-opac. + Use AbsorptionCoefficient and ScatteringCoefficient indexed at 0. + Hard-code frequency bounds for gray singularity-opac models.
e9f8b4c to
fa909c3
Compare
+ Scale opacity bounds. + Bump jaybenne.
| cutoff = 1.0e-6 # default is 1.0e-6 | ||
| emit_temp_threshold = 1.2e4 # from ryan, 1.1e4 is background | ||
| #min_swarm_occupancy = 0.5 | ||
| frequency_type = gray No newline at end of file |
| e = eos_d.InternalEnergyFromDensityTemperature(dens, T) * dens; | ||
| const Real Cv = dens * eos_d.SpecificHeatFromDensityTemperature(dens, T); | ||
| const Real a = chat * dt * opac_d.PlanckMeanAbsorptionCoefficient(dens, T); | ||
| const Real a = chat * dt * opac_d.PlanckGroupAbsorptionCoefficient(dens, T, 0); |
There was a problem hiding this comment.
I thought we provided an overload in singularity-opac to onlly pass rho, T and it does this identical thing under the hood, but with a PARTHENON_REQUIRE that ngroups==1 (i.e., gray).
There was a problem hiding this comment.
Will double-check this - might've over-applied the addition of the group index - think for AbsorptionCoefficient it was required (or the overload might've not been there - but could be wrong).
| Real a = chat * dt * | ||
| (opac_d.RosselandMeanAbsorptionCoefficient(dens, T) + | ||
| scat_d.RosselandMeanTotalScatteringCoefficient(dens, T)); | ||
| (opac_d.AbsorptionCoefficient(dens, T, 0) + |
| @@ -0,0 +1,163 @@ | |||
| //======================================================================================== | |||
There was a problem hiding this comment.
Curious as to the why the move outside of the gas package? If we eventually add dust opacity, I also would think that belongs in dust package. But I could be convinced otherwise 😸
There was a problem hiding this comment.
It's a fair question - originally moved this here so that frequency grid information under either radiation package input node would be able to affect the construction of the opacity models. Also, figured it might be worth avoiding opacity construction altogether (e.g. in gas) if radiation is not getting used. All in all, guessing there is a better (parthenon-ic) way to design this notion of "opacity" being dependent on the existance of two other packages (e.g. radiation+dust or radiation+gas)...
Background
Description of Changes
frequency_type.frequency_type == multigroup.Checklist
// This file was created in part or in whole by generative AI