diff --git a/api_docs/_adv_op___godunov_8_h_source.html b/api_docs/_adv_op___godunov_8_h_source.html
index 677346b7c6..44b4382b96 100644
--- a/api_docs/_adv_op___godunov_8_h_source.html
+++ b/api_docs/_adv_op___godunov_8_h_source.html
@@ -129,197 +129,200 @@
53 }
else if (amrex::toLower(godunov_type) ==
"ppm_nolim") {
- 55 }
else if (amrex::toLower(godunov_type) ==
"bds") {
-
- 57 advection_type =
"BDS";
-
- 59 amrex::toLower(godunov_type) ==
"weno" ||
- 60 amrex::toLower(godunov_type) ==
"weno_js") {
-
- 62 }
else if (amrex::toLower(godunov_type) ==
"weno_z") {
-
-
-
- 66 <<
"For godunov_type select between plm, ppm, "
- 67 "ppm_nolim, bds, weno_js, and weno_z: it defaults to ppm"
-
-
-
-
- 72 iconserv.resize(PDE::ndim, 1);
-
-
-
-
-
-
-
-
-
-
-
- 84 PDE::ndim == 1,
"Invalid number of components for scalar");
- 85 auto& repo = fields.repo;
- 86 const auto& geom = repo.mesh().Geom();
-
- 88 const auto& src_term = fields.src_term;
-
- 90 auto& conv_term = fields.conv_term;
- 91 const auto& dof_field = fields.field.state(fstate);
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 107 const auto& den = density.state(fstate);
+ 55 amrex::Print() <<
"WARNING: Using advection type ppm_nolim is not "
+ 56 "recommended. Prefer using wenoz."
+
+ 58 }
else if (amrex::toLower(godunov_type) ==
"bds") {
+
+ 60 advection_type =
"BDS";
+
+ 62 amrex::toLower(godunov_type) ==
"weno" ||
+ 63 amrex::toLower(godunov_type) ==
"weno_js") {
+
+ 65 }
else if (amrex::toLower(godunov_type) ==
"weno_z") {
+
+
+
+ 69 <<
"For godunov_type select between plm, ppm, "
+ 70 "ppm_nolim, bds, weno_js, and weno_z: it defaults to ppm"
+
+
+
+
+ 75 iconserv.resize(PDE::ndim, 1);
+
+
+
+
+
+
+
+
+
+
+
+ 87 PDE::ndim == 1,
"Invalid number of components for scalar");
+ 88 auto& repo = fields.repo;
+ 89 const auto& geom = repo.mesh().Geom();
+
+ 91 const auto& src_term = fields.src_term;
+
+ 93 auto& conv_term = fields.conv_term;
+ 94 const auto& dof_field = fields.field.state(fstate);
+
+
+
+
+
+
+
+
+
+
+
+
+
- 109 for (
int lev = 0; lev < repo.num_active_levels(); ++lev) {
- 110 amrex::MFItInfo mfi_info;
- 111 if (amrex::Gpu::notInLaunchRegion()) {
- 112 mfi_info.EnableTiling(amrex::IntVect(1024, 1024, 1024))
-
-
-
- 116 #pragma omp parallel if (amrex::Gpu::notInLaunchRegion())
-
- 118 for (amrex::MFIter mfi(dof_field(lev), mfi_info); mfi.isValid();
-
- 120 const auto& bx = mfi.tilebox();
- 121 auto rho_arr = den(lev).array(mfi);
- 122 auto tra_arr = dof_field(lev).array(mfi);
- 123 amrex::FArrayBox rhotracfab;
- 124 amrex::Array4<amrex::Real> rhotrac;
-
- 126 if (PDE::multiply_rho) {
-
-
- 129 rhotracfab.resize(rhotrac_box, PDE::ndim);
- 130 rhotrac = rhotracfab.array();
-
-
- 133 rhotrac_box, PDE::ndim,
- 134 [=] AMREX_GPU_DEVICE(
- 135 int i,
int j,
int k,
int n) noexcept {
- 136 rhotrac(i, j, k, n) =
- 137 rho_arr(i, j, k) * tra_arr(i, j, k, n);
-
-
-
-
-
- 143 amrex::FArrayBox tmpfab(amrex::grow(bx, 1), PDE::ndim * 14);
-
-
- 146 lev, bx, PDE::ndim, (*flux_x)(lev).array(mfi),
- 147 (*flux_y)(lev).array(mfi), (*flux_z)(lev).array(mfi),
- 148 (PDE::multiply_rho ? rhotrac : tra_arr),
- 149 u_mac(lev).const_array(mfi),
- 150 v_mac(lev).const_array(mfi),
- 151 w_mac(lev).const_array(mfi),
- 152 src_term(lev).const_array(mfi),
- 153 dof_field.bcrec_device().data(), iconserv.data(),
- 154 tmpfab.dataPtr(), geom, dt, godunov_scheme,
- 155 godunov_use_forces_in_trans);
-
-
-
-
-
- 161 amrex::FArrayBox tmpfab(amrex::grow(bx, 1), 1);
- 162 tmpfab.setVal<amrex::RunOn::Device>(0.0);
- 163 const auto& divu = tmpfab.array();
- 164 const bool is_velocity =
false;
- 165 const bool known_edge_state =
false;
- 166 const bool godunov_use_ppm =
-
-
- 169 const int limiter_type =
-
-
- 172 : PPM::default_limiter;
- 173 HydroUtils::ComputeFluxesOnBoxFromState(
-
- 175 (PDE::multiply_rho ? rhotrac : tra_arr),
- 176 (*flux_x)(lev).array(mfi), (*flux_y)(lev).array(mfi),
- 177 (*flux_z)(lev).array(mfi), (*face_x)(lev).array(mfi),
- 178 (*face_y)(lev).array(mfi), (*face_z)(lev).array(mfi),
- 179 known_edge_state, u_mac(lev).const_array(mfi),
- 180 v_mac(lev).const_array(mfi),
- 181 w_mac(lev).const_array(mfi), divu,
- 182 src_term(lev).const_array(mfi), geom[lev], dt,
- 183 dof_field.bcrec(), dof_field.bcrec_device().data(),
- 184 iconserv.data(), godunov_use_ppm,
- 185 godunov_use_forces_in_trans, is_velocity,
- 186 fluxes_are_area_weighted, advection_type, limiter_type);
-
- 188 amrex::Abort(
"Invalid godunov scheme");
-
- 190 amrex::Gpu::streamSynchronize();
-
-
-
- 194 amrex::Vector<amrex::Array<amrex::MultiFab*, AMREX_SPACEDIM>> fluxes(
- 195 repo.num_active_levels());
- 196 for (
int lev = 0; lev < repo.num_active_levels(); ++lev) {
- 197 fluxes[lev][0] = &(*flux_x)(lev);
- 198 fluxes[lev][1] = &(*flux_y)(lev);
- 199 fluxes[lev][2] = &(*flux_z)(lev);
-
-
-
-
- 204 for (
int lev = repo.num_active_levels() - 1; lev > 0; --lev) {
-
- 206 geom[lev].Domain().size() / geom[lev - 1].Domain().size();
- 207 amrex::average_down_faces(
- 208 GetArrOfConstPtrs(fluxes[lev]), fluxes[lev - 1], rr,
-
-
-
- 212 for (
int lev = 0; lev < repo.num_active_levels(); ++lev) {
-
- 214 #pragma omp parallel if (amrex::Gpu::notInLaunchRegion())
-
- 216 for (amrex::MFIter mfi(dof_field(lev), amrex::TilingIfNotGPU());
- 217 mfi.isValid(); ++mfi) {
- 218 const auto& bx = mfi.tilebox();
-
- 220 HydroUtils::ComputeDivergence(
- 221 bx, conv_term(lev).array(mfi), (*flux_x)(lev).array(mfi),
- 222 (*flux_y)(lev).array(mfi), (*flux_z)(lev).array(mfi),
- 223 PDE::ndim, geom[lev], amrex::Real(-1.0),
- 224 fluxes_are_area_weighted);
-
-
-
-
-
-
-
-
-
-
-
-
-
- 238 const bool fluxes_are_area_weighted{
false};
- 239 bool godunov_use_forces_in_trans{
false};
- 240 std::string advection_type{
"Godunov"};
-
-
-
-
-
+
+ 110 const auto& den = density.state(fstate);
+
+ 112 for (
int lev = 0; lev < repo.num_active_levels(); ++lev) {
+ 113 amrex::MFItInfo mfi_info;
+ 114 if (amrex::Gpu::notInLaunchRegion()) {
+ 115 mfi_info.EnableTiling(amrex::IntVect(1024, 1024, 1024))
+
+
+
+ 119 #pragma omp parallel if (amrex::Gpu::notInLaunchRegion())
+
+ 121 for (amrex::MFIter mfi(dof_field(lev), mfi_info); mfi.isValid();
+
+ 123 const auto& bx = mfi.tilebox();
+ 124 auto rho_arr = den(lev).array(mfi);
+ 125 auto tra_arr = dof_field(lev).array(mfi);
+ 126 amrex::FArrayBox rhotracfab;
+ 127 amrex::Array4<amrex::Real> rhotrac;
+
+ 129 if (PDE::multiply_rho) {
+
+
+ 132 rhotracfab.resize(rhotrac_box, PDE::ndim);
+ 133 rhotrac = rhotracfab.array();
+
+
+ 136 rhotrac_box, PDE::ndim,
+ 137 [=] AMREX_GPU_DEVICE(
+ 138 int i,
int j,
int k,
int n) noexcept {
+ 139 rhotrac(i, j, k, n) =
+ 140 rho_arr(i, j, k) * tra_arr(i, j, k, n);
+
+
+
+
+
+ 146 amrex::FArrayBox tmpfab(amrex::grow(bx, 1), PDE::ndim * 14);
+
+
+ 149 lev, bx, PDE::ndim, (*flux_x)(lev).array(mfi),
+ 150 (*flux_y)(lev).array(mfi), (*flux_z)(lev).array(mfi),
+ 151 (PDE::multiply_rho ? rhotrac : tra_arr),
+ 152 u_mac(lev).const_array(mfi),
+ 153 v_mac(lev).const_array(mfi),
+ 154 w_mac(lev).const_array(mfi),
+ 155 src_term(lev).const_array(mfi),
+ 156 dof_field.bcrec_device().data(), iconserv.data(),
+ 157 tmpfab.dataPtr(), geom, dt, godunov_scheme,
+ 158 godunov_use_forces_in_trans);
+
+
+
+
+
+ 164 amrex::FArrayBox tmpfab(amrex::grow(bx, 1), 1);
+ 165 tmpfab.setVal<amrex::RunOn::Device>(0.0);
+ 166 const auto& divu = tmpfab.array();
+ 167 const bool is_velocity =
false;
+ 168 const bool known_edge_state =
false;
+ 169 const bool godunov_use_ppm =
+
+
+ 172 const int limiter_type =
+
+
+ 175 : PPM::default_limiter;
+ 176 HydroUtils::ComputeFluxesOnBoxFromState(
+
+ 178 (PDE::multiply_rho ? rhotrac : tra_arr),
+ 179 (*flux_x)(lev).array(mfi), (*flux_y)(lev).array(mfi),
+ 180 (*flux_z)(lev).array(mfi), (*face_x)(lev).array(mfi),
+ 181 (*face_y)(lev).array(mfi), (*face_z)(lev).array(mfi),
+ 182 known_edge_state, u_mac(lev).const_array(mfi),
+ 183 v_mac(lev).const_array(mfi),
+ 184 w_mac(lev).const_array(mfi), divu,
+ 185 src_term(lev).const_array(mfi), geom[lev], dt,
+ 186 dof_field.bcrec(), dof_field.bcrec_device().data(),
+ 187 iconserv.data(), godunov_use_ppm,
+ 188 godunov_use_forces_in_trans, is_velocity,
+ 189 fluxes_are_area_weighted, advection_type, limiter_type);
+
+ 191 amrex::Abort(
"Invalid godunov scheme");
+
+ 193 amrex::Gpu::streamSynchronize();
+
+
+
+ 197 amrex::Vector<amrex::Array<amrex::MultiFab*, AMREX_SPACEDIM>> fluxes(
+ 198 repo.num_active_levels());
+ 199 for (
int lev = 0; lev < repo.num_active_levels(); ++lev) {
+ 200 fluxes[lev][0] = &(*flux_x)(lev);
+ 201 fluxes[lev][1] = &(*flux_y)(lev);
+ 202 fluxes[lev][2] = &(*flux_z)(lev);
+
+
+
+
+ 207 for (
int lev = repo.num_active_levels() - 1; lev > 0; --lev) {
+
+ 209 geom[lev].Domain().size() / geom[lev - 1].Domain().size();
+ 210 amrex::average_down_faces(
+ 211 GetArrOfConstPtrs(fluxes[lev]), fluxes[lev - 1], rr,
+
+
+
+ 215 for (
int lev = 0; lev < repo.num_active_levels(); ++lev) {
+
+ 217 #pragma omp parallel if (amrex::Gpu::notInLaunchRegion())
+
+ 219 for (amrex::MFIter mfi(dof_field(lev), amrex::TilingIfNotGPU());
+ 220 mfi.isValid(); ++mfi) {
+ 221 const auto& bx = mfi.tilebox();
+
+ 223 HydroUtils::ComputeDivergence(
+ 224 bx, conv_term(lev).array(mfi), (*flux_x)(lev).array(mfi),
+ 225 (*flux_y)(lev).array(mfi), (*flux_z)(lev).array(mfi),
+ 226 PDE::ndim, geom[lev], amrex::Real(-1.0),
+ 227 fluxes_are_area_weighted);
+
+
+
+
+
+
+
+
+
+
+
+
+
+ 241 const bool fluxes_are_area_weighted{
false};
+ 242 bool godunov_use_forces_in_trans{
false};
+ 243 std::string advection_type{
"Godunov"};
+
+
+
+
+
@@ -340,16 +343,16 @@
void compute_fluxes(int lev, amrex::Box const &bx, int ncomp, amrex::Array4< amrex::Real > const &fx, amrex::Array4< amrex::Real > const &fy, amrex::Array4< amrex::Real > const &fz, amrex::Array4< amrex::Real const > const &q, amrex::Array4< amrex::Real const > const &umac, amrex::Array4< amrex::Real const > const &vmac, amrex::Array4< amrex::Real const > const &wmac, amrex::Array4< amrex::Real const > const &fq, amrex::BCRec const *pbc, int const *iconserv, amrex::Real *p, amrex::Vector< amrex::Geometry > geom, amrex::Real dt, godunov::scheme godunov_scheme, bool godunov_use_forces_in_trans)
static constexpr int nghost_state
Number of ghost in the state variable.
Definition: SchemeTraits.H:19
-void operator()(const FieldState fstate, const amrex::Real dt)
Definition: AdvOp_Godunov.H:81
-Field & density
Definition: AdvOp_Godunov.H:230
-Field & u_mac
Definition: AdvOp_Godunov.H:231
-std::string godunov_type
Definition: AdvOp_Godunov.H:237
+void operator()(const FieldState fstate, const amrex::Real dt)
Definition: AdvOp_Godunov.H:84
+Field & density
Definition: AdvOp_Godunov.H:233
+Field & u_mac
Definition: AdvOp_Godunov.H:234
+std::string godunov_type
Definition: AdvOp_Godunov.H:240
AdvectionOp(CFDSim &, PDEFields &fields_in, bool, bool, bool, bool)
Definition: AdvOp_Godunov.H:27
-void preadvect(const FieldState, const amrex::Real, const amrex::Real)
Definition: AdvOp_Godunov.H:75
-PDEFields & fields
Definition: AdvOp_Godunov.H:229
-amrex::Gpu::DeviceVector< int > iconserv
Definition: AdvOp_Godunov.H:234
-Field & v_mac
Definition: AdvOp_Godunov.H:232
-Field & w_mac
Definition: AdvOp_Godunov.H:233
+void preadvect(const FieldState, const amrex::Real, const amrex::Real)
Definition: AdvOp_Godunov.H:78
+PDEFields & fields
Definition: AdvOp_Godunov.H:232
+amrex::Gpu::DeviceVector< int > iconserv
Definition: AdvOp_Godunov.H:237
+Field & v_mac
Definition: AdvOp_Godunov.H:235
+Field & w_mac
Definition: AdvOp_Godunov.H:236
Collection of fields related to a PDE.
Definition: PDEFields.H:27