Skip to content

Commit

Permalink
Merge branch 'pgrete/donut' into forrestglines/agn_reductions
Browse files Browse the repository at this point in the history
  • Loading branch information
Forrest Wolfgang Glines committed Aug 24, 2023
2 parents 1408069 + a3c2855 commit 80e8ccd
Show file tree
Hide file tree
Showing 2 changed files with 15 additions and 7 deletions.
2 changes: 1 addition & 1 deletion external/parthenon
20 changes: 14 additions & 6 deletions src/hydro/hydro.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,6 +143,14 @@ TaskStatus AddUnsplitSources(MeshData<Real> *md, const SimTime &tm, const Real b
if (hydro_pkg->Param<Fluid>("fluid") == Fluid::glmmhd) {
hydro_pkg->Param<GLMMHD::SourceFun_t>("glmmhd_source")(md, beta_dt);
}
const auto &enable_cooling = hydro_pkg->Param<Cooling>("enable_cooling");

if (enable_cooling == Cooling::tabular) {
const TabularCooling &tabular_cooling =
hydro_pkg->Param<TabularCooling>("tabular_cooling");

tabular_cooling.SrcTerm(md, beta_dt);
}
if (ProblemSourceUnsplit != nullptr) {
ProblemSourceUnsplit(md, tm, beta_dt);
}
Expand All @@ -153,14 +161,14 @@ TaskStatus AddUnsplitSources(MeshData<Real> *md, const SimTime &tm, const Real b
TaskStatus AddSplitSourcesFirstOrder(MeshData<Real> *md, const SimTime &tm) {
auto hydro_pkg = md->GetBlockData(0)->GetBlockPointer()->packages.Get("Hydro");

const auto &enable_cooling = hydro_pkg->Param<Cooling>("enable_cooling");
// const auto &enable_cooling = hydro_pkg->Param<Cooling>("enable_cooling");

if (enable_cooling == Cooling::tabular) {
const TabularCooling &tabular_cooling =
hydro_pkg->Param<TabularCooling>("tabular_cooling");
// if (enable_cooling == Cooling::tabular) {
// const TabularCooling &tabular_cooling =
// hydro_pkg->Param<TabularCooling>("tabular_cooling");

tabular_cooling.SrcTerm(md, tm.dt);
}
// tabular_cooling.SrcTerm(md, tm.dt);
// }
if (ProblemSourceFirstOrder != nullptr) {
ProblemSourceFirstOrder(md, tm, tm.dt);
}
Expand Down

0 comments on commit 80e8ccd

Please sign in to comment.