From 70e22dbdbc907c66ab2124ce22ebe99ed0b27731 Mon Sep 17 00:00:00 2001 From: asalmgren Date: Tue, 8 Oct 2024 22:27:04 +0000 Subject: [PATCH] Deployed from erf-model/ERF --- ERF__ComputeTurbulentViscosity_8cpp.html | 8 +- ERF__DataStruct_8H_source.html | 1225 ++++++++++---------- ERF__DiffusionSrcForState__N_8cpp.html | 8 +- ERF__DiffusionSrcForState__T_8cpp.html | 8 +- ERF__EulerianMicrophysics_8H_source.html | 51 +- ERF__Kessler_8H_source.html | 136 +-- ERF__LagrangianMicrophysics_8H_source.html | 53 +- ERF__Microphysics_8H_source.html | 4 +- ERF__NullMoist_8H_source.html | 4 +- ERF__SAM_8H_source.html | 254 ++-- ERF__make__buoyancy_8cpp.html | 10 +- ERF__make__mom__sources_8cpp.html | 42 +- ERF__make__sources_8cpp.html | 34 +- ERF__make__tau__terms_8cpp.html | 12 +- ERF__slow__rhs__post_8cpp.html | 24 +- ERF__slow__rhs__pre_8cpp.html | 28 +- classERF.html | 96 +- classEulerianMicrophysics-members.html | 2 +- classEulerianMicrophysics.html | 39 +- classEulerianMicrophysics.js | 2 +- classKessler-members.html | 2 +- classKessler.html | 76 +- classKessler.js | 2 +- classMicrophysics-members.html | 2 +- classMicrophysics.html | 18 +- classMicrophysics.js | 2 +- classNullMoist-members.html | 2 +- classNullMoist.html | 16 +- classNullMoist.js | 2 +- classSAM-members.html | 2 +- classSAM.html | 120 +- classSAM.js | 2 +- functions_func_g.html | 4 +- functions_func_q.html | 6 +- functions_g.html | 4 +- functions_q.html | 6 +- navtreeindex5.js | 2 +- navtreeindex6.js | 2 +- navtreeindex7.js | 4 +- navtreeindex9.js | 2 +- search/all_10.js | 2 +- search/all_6.js | 2 +- search/functions_6.js | 2 +- search/functions_f.js | 2 +- structSolverChoice.html | 959 ++++++++------- 45 files changed, 1665 insertions(+), 1618 deletions(-) diff --git a/ERF__ComputeTurbulentViscosity_8cpp.html b/ERF__ComputeTurbulentViscosity_8cpp.html index 677eb205e..f6a8505db 100644 --- a/ERF__ComputeTurbulentViscosity_8cpp.html +++ b/ERF__ComputeTurbulentViscosity_8cpp.html @@ -390,10 +390,10 @@

void ComputeTurbulentViscosityLES(const MultiFab &Tau11, const MultiFab &Tau22, const MultiFab &Tau33, const MultiFab &Tau12, const MultiFab &Tau13, const MultiFab &Tau23, const MultiFab &cons_in, MultiFab &eddyViscosity, MultiFab &Hfx1, MultiFab &Hfx2, MultiFab &Hfx3, MultiFab &Diss, const Geometry &geom, const MultiFab &mapfac_u, const MultiFab &mapfac_v, const std::unique_ptr< MultiFab > &z_phys_nd, const TurbChoice &turbChoice, const Real const_grav, std::unique_ptr< ABLMost > &most, const bool &exp_most)
Definition: ERF_ComputeTurbulentViscosity.cpp:32
@ xvel
Definition: ERF_IndexDefines.H:122
@ yvel
Definition: ERF_IndexDefines.H:123
-
int RhoQr_comp
Definition: ERF_DataStruct.H:649
-
amrex::Real gravity
Definition: ERF_DataStruct.H:579
-
int RhoQv_comp
Definition: ERF_DataStruct.H:643
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
+
int RhoQr_comp
Definition: ERF_DataStruct.H:648
+
amrex::Real gravity
Definition: ERF_DataStruct.H:578
+
int RhoQv_comp
Definition: ERF_DataStruct.H:642
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
Definition: ERF_TurbStruct.H:29
PBLType pbl_type
Definition: ERF_TurbStruct.H:192
LESType les_type
Definition: ERF_TurbStruct.H:169
diff --git a/ERF__DataStruct_8H_source.html b/ERF__DataStruct_8H_source.html index 030d1f727..025bfc44c 100644 --- a/ERF__DataStruct_8H_source.html +++ b/ERF__DataStruct_8H_source.html @@ -208,542 +208,541 @@
122  } else if (moisture_type == MoistureType::Kessler_NoRain) {
-
123  moisture_type = MoistureType::Kessler_NoRain;
- -
125  }
-
126 
-
127  // TODO: should we set default for dry??
-
128  // Set a different default for moist vs dry
-
129  if (moisture_type != MoistureType::None) {
-
130  if (moisture_type == MoistureType::Kessler_NoRain ||
-
131  moisture_type == MoistureType::SAM ||
-
132  moisture_type == MoistureType::SAM_NoIce ||
-
133  moisture_type == MoistureType::SAM_NoPrecip_NoIce) {
-
134  buoyancy_type = 1; // asserted in make buoyancy
-
135  } else {
-
136  buoyancy_type = 2; // uses Tprime
-
137  }
-
138  }
-
139 
-
140  // Which expression (1,2 or 3) to use for buoyancy
-
141  pp.query("buoyancy_type", buoyancy_type);
-
142 
-
143  // What type of land surface model to use
-
144  lsm_type = LandSurfaceType::None; // Default
-
145  pp.query_enum_case_insensitive("land_surface_model",lsm_type);
-
146 
-
147  // Is the terrain static or moving?
-
148  terrain_type = (use_terrain) ? TerrainType::Static : TerrainType::None; // Default
-
149  if (use_terrain) {
-
150  pp.query_enum_case_insensitive("terrain_type",terrain_type);
-
151  }
-
152 
-
153  // Use lagged_delta_rt in the fast integrator?
-
154  pp.query("use_lagged_delta_rt", use_lagged_delta_rt);
-
155 
-
156  // These default to true but are used for unit testing
-
157  pp.query("use_gravity", use_gravity);
- -
159 
-
160  pp.query("c_p", c_p);
-
161  rdOcp = R_d / c_p;
-
162 
-
163  read_int_string(max_level, "anelastic", anelastic, 0);
-
164 
-
165  // *******************************************************************************
-
166  // Read substepping_type and allow for different values at each level
-
167  // *******************************************************************************
-
168  substepping_type.resize(max_level+1);
-
169 
-
170  for (int i = 0; i <= max_level; i++) {
-
171  substepping_type[i] = SubsteppingType::Implicit;
-
172  }
-
173 
-
174  int nvals = pp.countval("substepping_type");
-
175  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
-
176 
-
177  if (nvals == 1) {
-
178  pp.query_enum_case_insensitive("substepping_type",substepping_type[0]);
-
179  for (int i = 1; i <= max_level; i++) {
- -
181  }
-
182  } else if (nvals > 1) { // in this case we have asserted nvals >= max_level+1
-
183  for (int i = 0; i <= max_level; i++) {
-
184  pp.query_enum_case_insensitive("substepping_type",substepping_type[i],i);
-
185  }
-
186  }
-
187 
-
188  // *******************************************************************************
-
189  // Error check on deprecated input
-
190  // *******************************************************************************
-
191  int nvals_old = pp.countval("no_substepping");
-
192  if (nvals_old > 0) {
-
193  amrex::Abort("The no_substepping flag is deprecated -- set substepping_type instead");
-
194  }
-
195  // *******************************************************************************
-
196 
-
197  // Should we project the initial velocity field to make it divergence-free?
-
198  pp.query("project_initial_velocity", project_initial_velocity);
-
199 
-
200  // *******************************************************************************
-
201 
-
202 #ifdef ERF_USE_POISSON_SOLVE
-
203  bool any_anelastic = false;
-
204  for (int i = 0; i <= max_level; ++i) {
-
205  if (anelastic[i] == 1) any_anelastic = true;
-
206  }
-
207 
-
208  // If anelastic at all, we do not advect rho -- it is always == rho0
-
209  if (any_anelastic == 1) {
-
210  constant_density = true;
- -
212  buoyancy_type = 2; // uses Tprime
-
213  } else {
-
214  constant_density = false; // We default to false but allow the user to set it
-
215  pp.query("constant_density", constant_density);
-
216  }
-
217 
-
218  pp.query("project_every_stage", project_every_stage);
-
219  pp.query("ncorr", ncorr);
-
220  pp.query("poisson_abstol", poisson_abstol);
-
221  pp.query("poisson_reltol", poisson_reltol);
-
222 
-
223  for (int lev = 0; lev <= max_level; lev++) {
-
224  if (anelastic[lev] != 0)
-
225  {
-
226  substepping_type[lev] = SubsteppingType::None;
-
227  }
-
228  }
-
229 #else
-
230  for (int i = 0; i <= max_level; ++i) {
-
231  if (anelastic[i] != 0) amrex::Abort("To run with anelastic you must compile with USE_POISSON_SOLVE = TRUE");
-
232  }
- -
234  amrex::Abort("To project the initial velocity you must compile with USE_POISSON_SOLVE = TRUE");
-
235  }
-
236 #endif
-
237 
-
238  pp.query("force_stage1_single_substep", force_stage1_single_substep);
-
239 
-
240  // Include Coriolis forcing?
-
241  pp.query("use_coriolis", use_coriolis);
-
242 
-
243  // Include Rayleigh damping (separate flags for each variable)
-
244  pp.query("rayleigh_damp_U", rayleigh_damp_U);
-
245  pp.query("rayleigh_damp_V", rayleigh_damp_V);
-
246  pp.query("rayleigh_damp_W", rayleigh_damp_W);
-
247  pp.query("rayleigh_damp_T", rayleigh_damp_T);
-
248  pp.query("rayleigh_dampcoef", rayleigh_dampcoef);
-
249  pp.query("rayleigh_zdamp", rayleigh_zdamp);
-
250 
-
251  // Flag to do explicit MOST formulation
-
252  pp.query("use_explicit_most",use_explicit_most);
-
253 
-
254  // Flag to do MOST rotations with terrain
-
255  pp.query("use_rotate_most",use_rotate_most);
-
256  if (use_rotate_most) {
-
257  AMREX_ASSERT_WITH_MESSAGE(use_terrain,"MOST stress rotations are only valid with terrain!");
-
258  AMREX_ASSERT_WITH_MESSAGE(use_explicit_most, "MOST Stress rotations are only valid with explicit MOST!");
-
259  }
-
260 
-
261  // Which external forcings?
-
262  abl_driver_type = ABLDriverType::None; // Default: no ABL driver for simulating classical fluid dynamics problems
-
263  pp.query_enum_case_insensitive("abl_driver_type",abl_driver_type);
-
264 
-
265  // Which type of inflow turbulent generation
-
266  pert_type = PerturbationType::None; // Default
-
267  pp.query_enum_case_insensitive("perturbation_type",pert_type);
-
268 
-
269  amrex::Vector<amrex::Real> abl_pressure_grad_in = {0.0, 0.0, 0.0};
-
270  pp.queryarr("abl_pressure_grad",abl_pressure_grad_in);
-
271  for(int i = 0; i < AMREX_SPACEDIM; ++i) abl_pressure_grad[i] = abl_pressure_grad_in[i];
-
272 
-
273  amrex::Vector<amrex::Real> abl_geo_forcing_in = {0.0, 0.0, 0.0};
-
274  if(pp.queryarr("abl_geo_forcing",abl_geo_forcing_in)) {
-
275  amrex::Print() << "Specified abl_geo_forcing: (";
-
276  for (int i = 0; i < AMREX_SPACEDIM; ++i) {
-
277  abl_geo_forcing[i] = abl_geo_forcing_in[i];
-
278  amrex::Print() << abl_geo_forcing[i] << " ";
-
279  }
-
280  amrex::Print() << ")" << std::endl;
-
281  }
-
282 
-
283  if (use_coriolis)
-
284  {
- -
286  }
-
287 
-
288  pp.query("add_custom_rhotheta_forcing", custom_rhotheta_forcing);
-
289  pp.query("add_custom_moisture_forcing", custom_moisture_forcing);
-
290  pp.query("add_custom_w_subsidence", custom_w_subsidence);
-
291  pp.query("add_custom_geostrophic_profile", custom_geostrophic_profile);
-
292  pp.query("custom_forcing_uses_primitive_vars", custom_forcing_prim_vars);
-
293 
-
294  pp.query("nudging_from_input_sounding", nudging_from_input_sounding);
-
295 
- -
297  AMREX_ALWAYS_ASSERT_WITH_MESSAGE(!(!abl_geo_wind_table.empty() && custom_geostrophic_profile),
-
298  "Should not have both abl_geo_wind_table and custom_geostrophic_profile set.");
-
299 
-
300  pp.query("Ave_Plane", ave_plane);
-
301 
-
302  pp.query("mp_clouds", do_cloud);
-
303  pp.query("mp_precip", do_precip);
-
304  pp.query("use_moist_background", use_moist_background);
-
305 
-
306  // Use numerical diffusion?
-
307  pp.query("use_NumDiff",use_NumDiff);
-
308  if(use_NumDiff) {
-
309  pp.query("NumDiffCoeff",NumDiffCoeff);
-
310  AMREX_ASSERT_WITH_MESSAGE(( (NumDiffCoeff >= 0.) && (NumDiffCoeff <= 1.) ),
-
311  "Numerical diffusion coefficient must be between 0 & 1.");
-
312  NumDiffCoeff *= std::pow(2.0,-6);
-
313  }
-
314 
-
315  // Use monotonic advection?
-
316  pp.query("use_mono_adv",use_mono_adv);
-
317 
- - - -
321 
-
322  turbChoice.resize(max_level+1);
-
323  for (int lev = 0; lev <= max_level; lev++) {
-
324  turbChoice[lev].init_params(lev,max_level);
-
325  }
-
326 
-
327  // YSU PBL: use consistent coriolis frequency
-
328  for (int lev = 0; lev <= max_level; lev++) {
-
329  if (turbChoice[lev].pbl_ysu_use_consistent_coriolis) {
-
330  if (use_coriolis) {
-
331  turbChoice[lev].pbl_ysu_coriolis_freq = coriolis_factor * sinphi;
-
332  if (lev == 0) {
-
333  amrex::Print() << "YSU PBL using ERF coriolis frequency: " << turbChoice[lev].pbl_ysu_coriolis_freq << std::endl;
-
334  }
-
335  } else {
-
336  amrex::Abort("YSU cannot use ERF coriolis frequency if not using coriolis");
-
337  }
-
338  }
-
339  }
+ +
124  }
+
125 
+
126  // TODO: should we set default for dry??
+
127  // Set a different default for moist vs dry
+
128  if (moisture_type != MoistureType::None) {
+
129  if (moisture_type == MoistureType::Kessler_NoRain ||
+
130  moisture_type == MoistureType::SAM ||
+
131  moisture_type == MoistureType::SAM_NoIce ||
+
132  moisture_type == MoistureType::SAM_NoPrecip_NoIce) {
+
133  buoyancy_type = 1; // asserted in make buoyancy
+
134  } else {
+
135  buoyancy_type = 2; // uses Tprime
+
136  }
+
137  }
+
138 
+
139  // Which expression (1,2 or 3) to use for buoyancy
+
140  pp.query("buoyancy_type", buoyancy_type);
+
141 
+
142  // What type of land surface model to use
+
143  lsm_type = LandSurfaceType::None; // Default
+
144  pp.query_enum_case_insensitive("land_surface_model",lsm_type);
+
145 
+
146  // Is the terrain static or moving?
+
147  terrain_type = (use_terrain) ? TerrainType::Static : TerrainType::None; // Default
+
148  if (use_terrain) {
+
149  pp.query_enum_case_insensitive("terrain_type",terrain_type);
+
150  }
+
151 
+
152  // Use lagged_delta_rt in the fast integrator?
+
153  pp.query("use_lagged_delta_rt", use_lagged_delta_rt);
+
154 
+
155  // These default to true but are used for unit testing
+
156  pp.query("use_gravity", use_gravity);
+ +
158 
+
159  pp.query("c_p", c_p);
+
160  rdOcp = R_d / c_p;
+
161 
+
162  read_int_string(max_level, "anelastic", anelastic, 0);
+
163 
+
164  // *******************************************************************************
+
165  // Read substepping_type and allow for different values at each level
+
166  // *******************************************************************************
+
167  substepping_type.resize(max_level+1);
+
168 
+
169  for (int i = 0; i <= max_level; i++) {
+
170  substepping_type[i] = SubsteppingType::Implicit;
+
171  }
+
172 
+
173  int nvals = pp.countval("substepping_type");
+
174  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
+
175 
+
176  if (nvals == 1) {
+
177  pp.query_enum_case_insensitive("substepping_type",substepping_type[0]);
+
178  for (int i = 1; i <= max_level; i++) {
+ +
180  }
+
181  } else if (nvals > 1) { // in this case we have asserted nvals >= max_level+1
+
182  for (int i = 0; i <= max_level; i++) {
+
183  pp.query_enum_case_insensitive("substepping_type",substepping_type[i],i);
+
184  }
+
185  }
+
186 
+
187  // *******************************************************************************
+
188  // Error check on deprecated input
+
189  // *******************************************************************************
+
190  int nvals_old = pp.countval("no_substepping");
+
191  if (nvals_old > 0) {
+
192  amrex::Abort("The no_substepping flag is deprecated -- set substepping_type instead");
+
193  }
+
194  // *******************************************************************************
+
195 
+
196  // Should we project the initial velocity field to make it divergence-free?
+
197  pp.query("project_initial_velocity", project_initial_velocity);
+
198 
+
199  // *******************************************************************************
+
200 
+
201 #ifdef ERF_USE_POISSON_SOLVE
+
202  bool any_anelastic = false;
+
203  for (int i = 0; i <= max_level; ++i) {
+
204  if (anelastic[i] == 1) any_anelastic = true;
+
205  }
+
206 
+
207  // If anelastic at all, we do not advect rho -- it is always == rho0
+
208  if (any_anelastic == 1) {
+
209  constant_density = true;
+ +
211  buoyancy_type = 2; // uses Tprime
+
212  } else {
+
213  constant_density = false; // We default to false but allow the user to set it
+
214  pp.query("constant_density", constant_density);
+
215  }
+
216 
+
217  pp.query("project_every_stage", project_every_stage);
+
218  pp.query("ncorr", ncorr);
+
219  pp.query("poisson_abstol", poisson_abstol);
+
220  pp.query("poisson_reltol", poisson_reltol);
+
221 
+
222  for (int lev = 0; lev <= max_level; lev++) {
+
223  if (anelastic[lev] != 0)
+
224  {
+
225  substepping_type[lev] = SubsteppingType::None;
+
226  }
+
227  }
+
228 #else
+
229  for (int i = 0; i <= max_level; ++i) {
+
230  if (anelastic[i] != 0) amrex::Abort("To run with anelastic you must compile with USE_POISSON_SOLVE = TRUE");
+
231  }
+ +
233  amrex::Abort("To project the initial velocity you must compile with USE_POISSON_SOLVE = TRUE");
+
234  }
+
235 #endif
+
236 
+
237  pp.query("force_stage1_single_substep", force_stage1_single_substep);
+
238 
+
239  // Include Coriolis forcing?
+
240  pp.query("use_coriolis", use_coriolis);
+
241 
+
242  // Include Rayleigh damping (separate flags for each variable)
+
243  pp.query("rayleigh_damp_U", rayleigh_damp_U);
+
244  pp.query("rayleigh_damp_V", rayleigh_damp_V);
+
245  pp.query("rayleigh_damp_W", rayleigh_damp_W);
+
246  pp.query("rayleigh_damp_T", rayleigh_damp_T);
+
247  pp.query("rayleigh_dampcoef", rayleigh_dampcoef);
+
248  pp.query("rayleigh_zdamp", rayleigh_zdamp);
+
249 
+
250  // Flag to do explicit MOST formulation
+
251  pp.query("use_explicit_most",use_explicit_most);
+
252 
+
253  // Flag to do MOST rotations with terrain
+
254  pp.query("use_rotate_most",use_rotate_most);
+
255  if (use_rotate_most) {
+
256  AMREX_ASSERT_WITH_MESSAGE(use_terrain,"MOST stress rotations are only valid with terrain!");
+
257  AMREX_ASSERT_WITH_MESSAGE(use_explicit_most, "MOST Stress rotations are only valid with explicit MOST!");
+
258  }
+
259 
+
260  // Which external forcings?
+
261  abl_driver_type = ABLDriverType::None; // Default: no ABL driver for simulating classical fluid dynamics problems
+
262  pp.query_enum_case_insensitive("abl_driver_type",abl_driver_type);
+
263 
+
264  // Which type of inflow turbulent generation
+
265  pert_type = PerturbationType::None; // Default
+
266  pp.query_enum_case_insensitive("perturbation_type",pert_type);
+
267 
+
268  amrex::Vector<amrex::Real> abl_pressure_grad_in = {0.0, 0.0, 0.0};
+
269  pp.queryarr("abl_pressure_grad",abl_pressure_grad_in);
+
270  for(int i = 0; i < AMREX_SPACEDIM; ++i) abl_pressure_grad[i] = abl_pressure_grad_in[i];
+
271 
+
272  amrex::Vector<amrex::Real> abl_geo_forcing_in = {0.0, 0.0, 0.0};
+
273  if(pp.queryarr("abl_geo_forcing",abl_geo_forcing_in)) {
+
274  amrex::Print() << "Specified abl_geo_forcing: (";
+
275  for (int i = 0; i < AMREX_SPACEDIM; ++i) {
+
276  abl_geo_forcing[i] = abl_geo_forcing_in[i];
+
277  amrex::Print() << abl_geo_forcing[i] << " ";
+
278  }
+
279  amrex::Print() << ")" << std::endl;
+
280  }
+
281 
+
282  if (use_coriolis)
+
283  {
+ +
285  }
+
286 
+
287  pp.query("add_custom_rhotheta_forcing", custom_rhotheta_forcing);
+
288  pp.query("add_custom_moisture_forcing", custom_moisture_forcing);
+
289  pp.query("add_custom_w_subsidence", custom_w_subsidence);
+
290  pp.query("add_custom_geostrophic_profile", custom_geostrophic_profile);
+
291  pp.query("custom_forcing_uses_primitive_vars", custom_forcing_prim_vars);
+
292 
+
293  pp.query("nudging_from_input_sounding", nudging_from_input_sounding);
+
294 
+ +
296  AMREX_ALWAYS_ASSERT_WITH_MESSAGE(!(!abl_geo_wind_table.empty() && custom_geostrophic_profile),
+
297  "Should not have both abl_geo_wind_table and custom_geostrophic_profile set.");
+
298 
+
299  pp.query("Ave_Plane", ave_plane);
+
300 
+
301  pp.query("mp_clouds", do_cloud);
+
302  pp.query("mp_precip", do_precip);
+
303  pp.query("use_moist_background", use_moist_background);
+
304 
+
305  // Use numerical diffusion?
+
306  pp.query("use_NumDiff",use_NumDiff);
+
307  if(use_NumDiff) {
+
308  pp.query("NumDiffCoeff",NumDiffCoeff);
+
309  AMREX_ASSERT_WITH_MESSAGE(( (NumDiffCoeff >= 0.) && (NumDiffCoeff <= 1.) ),
+
310  "Numerical diffusion coefficient must be between 0 & 1.");
+
311  NumDiffCoeff *= std::pow(2.0,-6);
+
312  }
+
313 
+
314  // Use monotonic advection?
+
315  pp.query("use_mono_adv",use_mono_adv);
+
316 
+ + + +
320 
+
321  turbChoice.resize(max_level+1);
+
322  for (int lev = 0; lev <= max_level; lev++) {
+
323  turbChoice[lev].init_params(lev,max_level);
+
324  }
+
325 
+
326  // YSU PBL: use consistent coriolis frequency
+
327  for (int lev = 0; lev <= max_level; lev++) {
+
328  if (turbChoice[lev].pbl_ysu_use_consistent_coriolis) {
+
329  if (use_coriolis) {
+
330  turbChoice[lev].pbl_ysu_coriolis_freq = coriolis_factor * sinphi;
+
331  if (lev == 0) {
+
332  amrex::Print() << "YSU PBL using ERF coriolis frequency: " << turbChoice[lev].pbl_ysu_coriolis_freq << std::endl;
+
333  }
+
334  } else {
+
335  amrex::Abort("YSU cannot use ERF coriolis frequency if not using coriolis");
+
336  }
+
337  }
+
338  }
+
339 
340 
-
341 
-
342  // Which type of multilevel coupling
-
343  coupling_type = CouplingType::TwoWay; // Default
-
344  pp.query_enum_case_insensitive("coupling_type",coupling_type);
-
345 
-
346  // Which type of windfarm model
-
347  windfarm_type = WindFarmType::None; // Default
-
348  pp.query_enum_case_insensitive("windfarm_type",windfarm_type);
-
349 
-
350  static std::string windfarm_loc_type_string = "None";
-
351  windfarm_loc_type = WindFarmLocType::None;
-
352  pp.query_enum_case_insensitive("windfarm_loc_type",windfarm_loc_type);
-
353 
-
354  pp.query("windfarm_loc_table", windfarm_loc_table);
-
355  pp.query("windfarm_spec_table", windfarm_spec_table);
-
356  pp.query("windfarm_blade_table", windfarm_blade_table);
-
357  pp.query("windfarm_airofil_tables", windfarm_airfoil_tables);
-
358 
-
359  // Sampling distance upstream of the turbine to find the
-
360  // incoming free stream velocity as a factor of the diameter of the
-
361  // turbine. ie. the sampling distance will be this number multiplied
-
362  // by the diameter of the turbine
-
363  pp.query("sampling_distance_by_D", sampling_distance_by_D);
-
364  pp.query("turb_disk_angle_from_x", turb_disk_angle);
-
365 
-
366  pp.query("windfarm_x_shift",windfarm_x_shift);
-
367  pp.query("windfarm_y_shift",windfarm_y_shift);
-
368  // Test if time averaged data is to be output
-
369  pp.query("time_avg_vel",time_avg_vel);
-
370 
-
371  check_params(max_level);
-
372  }
-
373 
-
374  void check_params(int max_level)
-
375  {
-
376  // Warn for PBL models and moisture - these may not yet be compatible
-
377  for (int lev = 0; lev <= max_level; lev++) {
-
378  if ((moisture_type != MoistureType::None) && (turbChoice[lev].pbl_type != PBLType::None)) {
-
379  amrex::Warning("\n*** WARNING: Moisture may not yet be compatible with PBL models, \n proceed with caution ***");
-
380  }
-
381  }
-
382  //
-
383  // Buoyancy type check
-
384  //
-
385  if (buoyancy_type != 1 && buoyancy_type != 2 && buoyancy_type != 3 && buoyancy_type != 4) {
-
386  amrex::Abort("buoyancy_type must be 1, 2, 3 or 4");
-
387  }
-
388 
-
389  if (!use_lagged_delta_rt && !(terrain_type == TerrainType::Moving)) {
-
390  amrex::Error("Can't turn off lagged_delta_rt when terrain not moving");
-
391  }
-
392 
-
393  //
-
394  // Wind farm checks
-
395  //
-
396  if (windfarm_type==WindFarmType::SimpleActuatorDisk and sampling_distance_by_D < 0.0) {
-
397  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
-
398  " erf.sampling_distance_by_D in the inputs which specifies the upstream"
-
399  " distance as a factor of the turbine diameter at which the incoming free stream"
-
400  " velocity will be computed at.");
-
401  }
-
402  if ( (windfarm_type==WindFarmType::SimpleActuatorDisk ||
-
403  windfarm_type==WindFarmType::GeneralActuatorDisk ) && turb_disk_angle < 0.0) {
-
404  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
-
405  " erf.turb_disk_angle_from_x in the inputs which is the angle of the face of the"
-
406  " turbine disk from the x-axis. A turbine facing an oncoming flow in the x-direction"
-
407  " will have turb_disk_angle value of 90 deg.");
-
408  }
-
409  if (windfarm_loc_type == WindFarmLocType::lat_lon and (windfarm_x_shift < 0.0 or windfarm_y_shift < 0.0)) {
-
410  amrex::Abort("You are using windfarms with latitude-logitude option to position the turbines."
-
411  " For this you should provide the inputs erf.windfarm_x_shift and"
-
412  " erf.windfarm_y_shift which are the values by which the bounding box of the"
-
413  " windfarm is shifted from the x and the y axes.");
-
414  }
-
415  }
-
416 
-
417  void display(int max_level)
-
418  {
-
419  amrex::Print() << "SOLVER CHOICE: " << std::endl;
-
420  amrex::Print() << "force_stage1_single_substep : " << force_stage1_single_substep << std::endl;
-
421  for (int lev = 0; lev <= max_level; lev++) {
-
422  amrex::Print() << "anelastic at level : " << lev << " is " << anelastic[lev] << std::endl;
-
423  if (substepping_type[lev] == SubsteppingType::None) {
-
424  amrex::Print() << "No substepping at level " << lev << std::endl;
-
425  } else if (substepping_type[lev] == SubsteppingType::Explicit) {
-
426  amrex::Print() << "Explicit substepping at level " << lev << std::endl;
-
427  } else if (substepping_type[lev] == SubsteppingType::Implicit) {
-
428  amrex::Print() << "Implicit substepping at level " << lev << std::endl;
-
429  }
-
430  }
-
431  amrex::Print() << "use_coriolis : " << use_coriolis << std::endl;
-
432  amrex::Print() << "use_gravity : " << use_gravity << std::endl;
-
433 
-
434  if (coupling_type == CouplingType::TwoWay) {
-
435  amrex::Print() << "Using two-way coupling " << std::endl;
-
436  } else if (coupling_type == CouplingType::OneWay) {
-
437  amrex::Print() << "Using one-way coupling " << std::endl;
-
438  }
-
439 
-
440  if (terrain_type == TerrainType::Static) {
-
441  amrex::Print() << "Using static terrain " << std::endl;
-
442  } else if (terrain_type == TerrainType::Moving) {
-
443  amrex::Print() << "Using moving terrain " << std::endl;
-
444  } else {
-
445  amrex::Print() << "No terrain " << std::endl;
-
446  }
-
447 
-
448  if (abl_driver_type == ABLDriverType::None) {
-
449  amrex::Print() << "ABL Driver Type: " << "None" << std::endl;
-
450  amrex::Print() << "No ABL driver selected " << std::endl;
-
451  } else if (abl_driver_type == ABLDriverType::PressureGradient) {
-
452  amrex::Print() << "ABL Driver Type: " << "PressureGradient" << std::endl;
-
453  amrex::Print() << "Driving abl_pressure_grad: (";
-
454  for (int i = 0; i < AMREX_SPACEDIM; ++i)
-
455  amrex::Print() << abl_pressure_grad[i] << " ";
-
456  amrex::Print() << ")" << std::endl;
-
457  } else if (abl_driver_type == ABLDriverType::GeostrophicWind) {
-
458  amrex::Print() << "ABL Driver Type: " << "GeostrophicWind" << std::endl;
-
459  amrex::Print() << "Driving abl_geo_forcing: (";
-
460  for (int i = 0; i < AMREX_SPACEDIM; ++i)
-
461  amrex::Print() << abl_geo_forcing[i] << " ";
-
462  amrex::Print() << ")" << std::endl;
-
463  }
-
464 
-
465  amrex::Print() << "Buoyancy_type : " << buoyancy_type << std::endl;
-
466 
-
467  advChoice.display();
- - -
470 
-
471  for (int lev = 0; lev <= max_level; lev++) {
-
472  turbChoice[lev].display(lev);
-
473  }
-
474  }
-
475 
- -
477  {
-
478  amrex::ParmParse pp(pp_prefix);
-
479 
-
480  // Read the rotational time period (in seconds)
-
481  amrex::Real rot_time_period = 86400.0;
-
482  pp.query("rotational_time_period", rot_time_period);
-
483 
-
484  coriolis_factor = 2.0 * 2.0 * PI / rot_time_period;
-
485  amrex::Print() << "Coriolis factor = " << coriolis_factor << std::endl;
-
486 
-
487  amrex::Real latitude = 90.0;
-
488  pp.query("latitude", latitude);
-
489 
-
490  pp.query("coriolis_3d", coriolis_3d);
-
491 
-
492  // Convert to radians
-
493  latitude *= (PI/180.);
-
494  sinphi = std::sin(latitude);
-
495  if (coriolis_3d) {
-
496  cosphi = std::cos(latitude);
-
497  }
-
498 
-
499  amrex::Print() << "Coriolis frequency, f = " << coriolis_factor * sinphi << " 1/s" << std::endl;
-
500 
-
501  if (abl_driver_type == ABLDriverType::GeostrophicWind) {
-
502  // Read in the geostrophic wind -- we only use this to construct
-
503  // the forcing term so no need to keep it
-
504  amrex::Vector<amrex::Real> abl_geo_wind(3);
-
505  pp.queryarr("abl_geo_wind",abl_geo_wind);
-
506 
-
507  if(!pp.query("abl_geo_wind_table",abl_geo_wind_table)) {
-
508  abl_geo_forcing = {
-
509  -coriolis_factor * (abl_geo_wind[1]*sinphi - abl_geo_wind[2]*cosphi),
-
510  coriolis_factor * abl_geo_wind[0]*sinphi,
-
511  -coriolis_factor * abl_geo_wind[0]*cosphi
-
512  };
-
513  } else {
-
514  amrex::Print() << "NOTE: abl_geo_wind_table provided, ignoring input abl_geo_wind" << std::endl;
-
515  }
-
516  }
-
517  }
-
518 
-
519  void read_int_string (int max_level, const char* string_to_read,
-
520  amrex::Vector<int>& vec_to_fill, int default_int)
-
521  {
-
522  amrex::ParmParse pp("erf");
-
523  int nvals = pp.countval(string_to_read);
-
524  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
-
525  amrex::Vector<int> temp; temp.resize(nvals);
-
526  pp.queryarr(string_to_read,temp);
-
527  if (nvals == 0) {
-
528  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(default_int);
-
529  } else if (nvals == 1) {
-
530  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[0]);
-
531  } else {
-
532  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[i]);
-
533  }
-
534  }
+
341  // Which type of multilevel coupling
+
342  coupling_type = CouplingType::TwoWay; // Default
+
343  pp.query_enum_case_insensitive("coupling_type",coupling_type);
+
344 
+
345  // Which type of windfarm model
+
346  windfarm_type = WindFarmType::None; // Default
+
347  pp.query_enum_case_insensitive("windfarm_type",windfarm_type);
+
348 
+
349  static std::string windfarm_loc_type_string = "None";
+
350  windfarm_loc_type = WindFarmLocType::None;
+
351  pp.query_enum_case_insensitive("windfarm_loc_type",windfarm_loc_type);
+
352 
+
353  pp.query("windfarm_loc_table", windfarm_loc_table);
+
354  pp.query("windfarm_spec_table", windfarm_spec_table);
+
355  pp.query("windfarm_blade_table", windfarm_blade_table);
+
356  pp.query("windfarm_airofil_tables", windfarm_airfoil_tables);
+
357 
+
358  // Sampling distance upstream of the turbine to find the
+
359  // incoming free stream velocity as a factor of the diameter of the
+
360  // turbine. ie. the sampling distance will be this number multiplied
+
361  // by the diameter of the turbine
+
362  pp.query("sampling_distance_by_D", sampling_distance_by_D);
+
363  pp.query("turb_disk_angle_from_x", turb_disk_angle);
+
364 
+
365  pp.query("windfarm_x_shift",windfarm_x_shift);
+
366  pp.query("windfarm_y_shift",windfarm_y_shift);
+
367  // Test if time averaged data is to be output
+
368  pp.query("time_avg_vel",time_avg_vel);
+
369 
+
370  check_params(max_level);
+
371  }
+
372 
+
373  void check_params(int max_level)
+
374  {
+
375  // Warn for PBL models and moisture - these may not yet be compatible
+
376  for (int lev = 0; lev <= max_level; lev++) {
+
377  if ((moisture_type != MoistureType::None) && (turbChoice[lev].pbl_type != PBLType::None)) {
+
378  amrex::Warning("\n*** WARNING: Moisture may not yet be compatible with PBL models, \n proceed with caution ***");
+
379  }
+
380  }
+
381  //
+
382  // Buoyancy type check
+
383  //
+
384  if (buoyancy_type != 1 && buoyancy_type != 2 && buoyancy_type != 3 && buoyancy_type != 4) {
+
385  amrex::Abort("buoyancy_type must be 1, 2, 3 or 4");
+
386  }
+
387 
+
388  if (!use_lagged_delta_rt && !(terrain_type == TerrainType::Moving)) {
+
389  amrex::Error("Can't turn off lagged_delta_rt when terrain not moving");
+
390  }
+
391 
+
392  //
+
393  // Wind farm checks
+
394  //
+
395  if (windfarm_type==WindFarmType::SimpleActuatorDisk and sampling_distance_by_D < 0.0) {
+
396  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
+
397  " erf.sampling_distance_by_D in the inputs which specifies the upstream"
+
398  " distance as a factor of the turbine diameter at which the incoming free stream"
+
399  " velocity will be computed at.");
+
400  }
+
401  if ( (windfarm_type==WindFarmType::SimpleActuatorDisk ||
+
402  windfarm_type==WindFarmType::GeneralActuatorDisk ) && turb_disk_angle < 0.0) {
+
403  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
+
404  " erf.turb_disk_angle_from_x in the inputs which is the angle of the face of the"
+
405  " turbine disk from the x-axis. A turbine facing an oncoming flow in the x-direction"
+
406  " will have turb_disk_angle value of 90 deg.");
+
407  }
+
408  if (windfarm_loc_type == WindFarmLocType::lat_lon and (windfarm_x_shift < 0.0 or windfarm_y_shift < 0.0)) {
+
409  amrex::Abort("You are using windfarms with latitude-logitude option to position the turbines."
+
410  " For this you should provide the inputs erf.windfarm_x_shift and"
+
411  " erf.windfarm_y_shift which are the values by which the bounding box of the"
+
412  " windfarm is shifted from the x and the y axes.");
+
413  }
+
414  }
+
415 
+
416  void display(int max_level)
+
417  {
+
418  amrex::Print() << "SOLVER CHOICE: " << std::endl;
+
419  amrex::Print() << "force_stage1_single_substep : " << force_stage1_single_substep << std::endl;
+
420  for (int lev = 0; lev <= max_level; lev++) {
+
421  amrex::Print() << "anelastic at level : " << lev << " is " << anelastic[lev] << std::endl;
+
422  if (substepping_type[lev] == SubsteppingType::None) {
+
423  amrex::Print() << "No substepping at level " << lev << std::endl;
+
424  } else if (substepping_type[lev] == SubsteppingType::Explicit) {
+
425  amrex::Print() << "Explicit substepping at level " << lev << std::endl;
+
426  } else if (substepping_type[lev] == SubsteppingType::Implicit) {
+
427  amrex::Print() << "Implicit substepping at level " << lev << std::endl;
+
428  }
+
429  }
+
430  amrex::Print() << "use_coriolis : " << use_coriolis << std::endl;
+
431  amrex::Print() << "use_gravity : " << use_gravity << std::endl;
+
432 
+
433  if (coupling_type == CouplingType::TwoWay) {
+
434  amrex::Print() << "Using two-way coupling " << std::endl;
+
435  } else if (coupling_type == CouplingType::OneWay) {
+
436  amrex::Print() << "Using one-way coupling " << std::endl;
+
437  }
+
438 
+
439  if (terrain_type == TerrainType::Static) {
+
440  amrex::Print() << "Using static terrain " << std::endl;
+
441  } else if (terrain_type == TerrainType::Moving) {
+
442  amrex::Print() << "Using moving terrain " << std::endl;
+
443  } else {
+
444  amrex::Print() << "No terrain " << std::endl;
+
445  }
+
446 
+
447  if (abl_driver_type == ABLDriverType::None) {
+
448  amrex::Print() << "ABL Driver Type: " << "None" << std::endl;
+
449  amrex::Print() << "No ABL driver selected " << std::endl;
+
450  } else if (abl_driver_type == ABLDriverType::PressureGradient) {
+
451  amrex::Print() << "ABL Driver Type: " << "PressureGradient" << std::endl;
+
452  amrex::Print() << "Driving abl_pressure_grad: (";
+
453  for (int i = 0; i < AMREX_SPACEDIM; ++i)
+
454  amrex::Print() << abl_pressure_grad[i] << " ";
+
455  amrex::Print() << ")" << std::endl;
+
456  } else if (abl_driver_type == ABLDriverType::GeostrophicWind) {
+
457  amrex::Print() << "ABL Driver Type: " << "GeostrophicWind" << std::endl;
+
458  amrex::Print() << "Driving abl_geo_forcing: (";
+
459  for (int i = 0; i < AMREX_SPACEDIM; ++i)
+
460  amrex::Print() << abl_geo_forcing[i] << " ";
+
461  amrex::Print() << ")" << std::endl;
+
462  }
+
463 
+
464  amrex::Print() << "Buoyancy_type : " << buoyancy_type << std::endl;
+
465 
+
466  advChoice.display();
+ + +
469 
+
470  for (int lev = 0; lev <= max_level; lev++) {
+
471  turbChoice[lev].display(lev);
+
472  }
+
473  }
+
474 
+ +
476  {
+
477  amrex::ParmParse pp(pp_prefix);
+
478 
+
479  // Read the rotational time period (in seconds)
+
480  amrex::Real rot_time_period = 86400.0;
+
481  pp.query("rotational_time_period", rot_time_period);
+
482 
+
483  coriolis_factor = 2.0 * 2.0 * PI / rot_time_period;
+
484  amrex::Print() << "Coriolis factor = " << coriolis_factor << std::endl;
+
485 
+
486  amrex::Real latitude = 90.0;
+
487  pp.query("latitude", latitude);
+
488 
+
489  pp.query("coriolis_3d", coriolis_3d);
+
490 
+
491  // Convert to radians
+
492  latitude *= (PI/180.);
+
493  sinphi = std::sin(latitude);
+
494  if (coriolis_3d) {
+
495  cosphi = std::cos(latitude);
+
496  }
+
497 
+
498  amrex::Print() << "Coriolis frequency, f = " << coriolis_factor * sinphi << " 1/s" << std::endl;
+
499 
+
500  if (abl_driver_type == ABLDriverType::GeostrophicWind) {
+
501  // Read in the geostrophic wind -- we only use this to construct
+
502  // the forcing term so no need to keep it
+
503  amrex::Vector<amrex::Real> abl_geo_wind(3);
+
504  pp.queryarr("abl_geo_wind",abl_geo_wind);
+
505 
+
506  if(!pp.query("abl_geo_wind_table",abl_geo_wind_table)) {
+
507  abl_geo_forcing = {
+
508  -coriolis_factor * (abl_geo_wind[1]*sinphi - abl_geo_wind[2]*cosphi),
+
509  coriolis_factor * abl_geo_wind[0]*sinphi,
+
510  -coriolis_factor * abl_geo_wind[0]*cosphi
+
511  };
+
512  } else {
+
513  amrex::Print() << "NOTE: abl_geo_wind_table provided, ignoring input abl_geo_wind" << std::endl;
+
514  }
+
515  }
+
516  }
+
517 
+
518  void read_int_string (int max_level, const char* string_to_read,
+
519  amrex::Vector<int>& vec_to_fill, int default_int)
+
520  {
+
521  amrex::ParmParse pp("erf");
+
522  int nvals = pp.countval(string_to_read);
+
523  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
+
524  amrex::Vector<int> temp; temp.resize(nvals);
+
525  pp.queryarr(string_to_read,temp);
+
526  if (nvals == 0) {
+
527  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(default_int);
+
528  } else if (nvals == 1) {
+
529  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[0]);
+
530  } else {
+
531  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[i]);
+
532  }
+
533  }
+
534 
535 
-
536 
- - - -
540  amrex::Vector<TurbChoice> turbChoice;
-
541 
-
542  // Default prefix
-
543  std::string pp_prefix {"erf"};
-
544 
- -
546 
-
547  amrex::Vector<SubsteppingType> substepping_type;
-
548  amrex::Vector<int> anelastic;
-
549 
- - -
552  int ncorr = 1;
-
553  amrex::Real poisson_abstol = 1e-10;
-
554  amrex::Real poisson_reltol = 1e-10;
-
555 
-
556  bool test_mapfactor = false;
-
557 
-
558  bool use_terrain = false;
-
559 
-
560  int buoyancy_type = 1; // uses rhoprime directly
-
561 
-
562  // Specify what additional physics/forcing modules we use
-
563  bool use_gravity = false;
-
564  bool use_coriolis = false;
-
565  bool coriolis_3d = true;
-
566 
-
567  bool rayleigh_damp_U = false;
-
568  bool rayleigh_damp_V = false;
-
569  bool rayleigh_damp_W = false;
-
570  bool rayleigh_damp_T = false;
-
571  amrex::Real rayleigh_dampcoef = 0.2; // inverse time scale [1/s]
-
572  amrex::Real rayleigh_zdamp = 500.0; // damping layer depth [m]
-
573  amrex::Real rayleigh_ztop;
-
574 
-
575  // This defaults to true but can be set to false for moving terrain cases only
-
576  bool use_lagged_delta_rt = true;
-
577 
-
578  // Constants
-
579  amrex::Real gravity;
-
580  amrex::Real c_p = Cp_d; // specific heat at constant pressure for dry air [J/(kg-K)]
-
581  amrex::Real rdOcp;
-
582 
-
583  // Staggered z levels for vertical grid stretching
-
584  amrex::Real grid_stretching_ratio = 0;
-
585  amrex::Real zsurf = 0.0;
-
586  amrex::Real dz0;
-
587 
- -
589 
-
590  // Coriolis forcing
-
591  amrex::Real coriolis_factor = 0.0;
-
592  amrex::Real cosphi = 0.0;
-
593  amrex::Real sinphi = 0.0;
-
594 
-
595  // User-specified forcings in problem definition
- - -
598  bool custom_w_subsidence = false;
- - -
601 
-
602  // Do we use source terms to nudge the solution towards
-
603  // the time-varying data provided in input sounding files?
- -
605 
-
606  // User specified MOST BC type
-
607  bool use_explicit_most = false;
-
608 
-
609  // MOST stress rotations
-
610  bool use_rotate_most = false;
-
611 
-
612  // User wishes to output time averaged velocity fields
-
613  bool time_avg_vel = false;
-
614 
-
615  // Type of perturbation
-
616  PerturbationType pert_type;
-
617 
-
618  // Numerical diffusion
-
619  bool use_NumDiff{false};
-
620  amrex::Real NumDiffCoeff{0.};
-
621 
-
622  // Monotonic advection limiter
-
623  bool use_mono_adv{false};
-
624 
-
625  CouplingType coupling_type;
-
626  TerrainType terrain_type;
-
627  MoistureType moisture_type;
-
628  WindFarmType windfarm_type;
-
629  WindFarmLocType windfarm_loc_type;
-
630  LandSurfaceType lsm_type;
-
631 
-
632  ABLDriverType abl_driver_type;
-
633  amrex::GpuArray<amrex::Real, AMREX_SPACEDIM> abl_pressure_grad;
-
634  amrex::GpuArray<amrex::Real, AMREX_SPACEDIM> abl_geo_forcing;
-
635  std::string abl_geo_wind_table;
-
636  bool have_geo_wind_profile {false};
-
637 
-
638  int ave_plane {2};
-
639  // Microphysics params
-
640  bool do_cloud {true};
-
641  bool do_precip {true};
-
642  bool use_moist_background {false};
-
643  int RhoQv_comp {-1};
-
644 
-
645  // This component will be model-dependent:
-
646  // if a model with no rain, this will stay -1
-
647  // if Kessler, then it will be set to RhoQ3
-
648  // if SAM, then it will be set to RhoQ4
-
649  int RhoQr_comp {-1};
-
650 
- - -
653  amrex::Real sampling_distance_by_D = -1.0;
-
654  amrex::Real turb_disk_angle = -1.0;
-
655  amrex::Real windfarm_x_shift = -1.0;
-
656  amrex::Real windfarm_y_shift = -1.0;
-
657 };
-
658 #endif
+ + + +
539  amrex::Vector<TurbChoice> turbChoice;
+
540 
+
541  // Default prefix
+
542  std::string pp_prefix {"erf"};
+
543 
+ +
545 
+
546  amrex::Vector<SubsteppingType> substepping_type;
+
547  amrex::Vector<int> anelastic;
+
548 
+ + +
551  int ncorr = 1;
+
552  amrex::Real poisson_abstol = 1e-10;
+
553  amrex::Real poisson_reltol = 1e-10;
+
554 
+
555  bool test_mapfactor = false;
+
556 
+
557  bool use_terrain = false;
+
558 
+
559  int buoyancy_type = 1; // uses rhoprime directly
+
560 
+
561  // Specify what additional physics/forcing modules we use
+
562  bool use_gravity = false;
+
563  bool use_coriolis = false;
+
564  bool coriolis_3d = true;
+
565 
+
566  bool rayleigh_damp_U = false;
+
567  bool rayleigh_damp_V = false;
+
568  bool rayleigh_damp_W = false;
+
569  bool rayleigh_damp_T = false;
+
570  amrex::Real rayleigh_dampcoef = 0.2; // inverse time scale [1/s]
+
571  amrex::Real rayleigh_zdamp = 500.0; // damping layer depth [m]
+
572  amrex::Real rayleigh_ztop;
+
573 
+
574  // This defaults to true but can be set to false for moving terrain cases only
+
575  bool use_lagged_delta_rt = true;
+
576 
+
577  // Constants
+
578  amrex::Real gravity;
+
579  amrex::Real c_p = Cp_d; // specific heat at constant pressure for dry air [J/(kg-K)]
+
580  amrex::Real rdOcp;
+
581 
+
582  // Staggered z levels for vertical grid stretching
+
583  amrex::Real grid_stretching_ratio = 0;
+
584  amrex::Real zsurf = 0.0;
+
585  amrex::Real dz0;
+
586 
+ +
588 
+
589  // Coriolis forcing
+
590  amrex::Real coriolis_factor = 0.0;
+
591  amrex::Real cosphi = 0.0;
+
592  amrex::Real sinphi = 0.0;
+
593 
+
594  // User-specified forcings in problem definition
+ + +
597  bool custom_w_subsidence = false;
+ + +
600 
+
601  // Do we use source terms to nudge the solution towards
+
602  // the time-varying data provided in input sounding files?
+ +
604 
+
605  // User specified MOST BC type
+
606  bool use_explicit_most = false;
+
607 
+
608  // MOST stress rotations
+
609  bool use_rotate_most = false;
+
610 
+
611  // User wishes to output time averaged velocity fields
+
612  bool time_avg_vel = false;
+
613 
+
614  // Type of perturbation
+
615  PerturbationType pert_type;
+
616 
+
617  // Numerical diffusion
+
618  bool use_NumDiff{false};
+
619  amrex::Real NumDiffCoeff{0.};
+
620 
+
621  // Monotonic advection limiter
+
622  bool use_mono_adv{false};
+
623 
+
624  CouplingType coupling_type;
+
625  TerrainType terrain_type;
+
626  MoistureType moisture_type;
+
627  WindFarmType windfarm_type;
+
628  WindFarmLocType windfarm_loc_type;
+
629  LandSurfaceType lsm_type;
+
630 
+
631  ABLDriverType abl_driver_type;
+
632  amrex::GpuArray<amrex::Real, AMREX_SPACEDIM> abl_pressure_grad;
+
633  amrex::GpuArray<amrex::Real, AMREX_SPACEDIM> abl_geo_forcing;
+
634  std::string abl_geo_wind_table;
+
635  bool have_geo_wind_profile {false};
+
636 
+
637  int ave_plane {2};
+
638  // Microphysics params
+
639  bool do_cloud {true};
+
640  bool do_precip {true};
+
641  bool use_moist_background {false};
+
642  int RhoQv_comp {-1};
+
643 
+
644  // This component will be model-dependent:
+
645  // if a model with no rain, this will stay -1
+
646  // if Kessler, then it will be set to RhoQ3
+
647  // if SAM, then it will be set to RhoQ4
+
648  int RhoQr_comp {-1};
+
649 
+ + +
652  amrex::Real sampling_distance_by_D = -1.0;
+
653  amrex::Real turb_disk_angle = -1.0;
+
654  amrex::Real windfarm_x_shift = -1.0;
+
655  amrex::Real windfarm_y_shift = -1.0;
+
656 };
+
657 #endif
constexpr amrex::Real Cp_d
Definition: ERF_Constants.H:12
@@ -787,86 +786,86 @@
void init_params()
Definition: ERF_DiffStruct.H:21
void display()
Definition: ERF_DiffStruct.H:56
Definition: ERF_DataStruct.H:78
-
bool use_terrain
Definition: ERF_DataStruct.H:558
-
bool rayleigh_damp_T
Definition: ERF_DataStruct.H:570
-
amrex::Real dz0
Definition: ERF_DataStruct.H:586
-
bool use_lagged_delta_rt
Definition: ERF_DataStruct.H:576
-
amrex::Real coriolis_factor
Definition: ERF_DataStruct.H:591
-
bool use_explicit_most
Definition: ERF_DataStruct.H:607
-
amrex::Real windfarm_x_shift
Definition: ERF_DataStruct.H:655
-
bool rayleigh_damp_V
Definition: ERF_DataStruct.H:568
-
int RhoQr_comp
Definition: ERF_DataStruct.H:649
-
amrex::Real poisson_reltol
Definition: ERF_DataStruct.H:554
-
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:572
-
amrex::Real rdOcp
Definition: ERF_DataStruct.H:581
-
void read_int_string(int max_level, const char *string_to_read, amrex::Vector< int > &vec_to_fill, int default_int)
Definition: ERF_DataStruct.H:519
-
std::string windfarm_spec_table
Definition: ERF_DataStruct.H:651
-
bool use_mono_adv
Definition: ERF_DataStruct.H:623
-
DiffChoice diffChoice
Definition: ERF_DataStruct.H:538
-
bool use_gravity
Definition: ERF_DataStruct.H:563
-
void build_coriolis_forcings()
Definition: ERF_DataStruct.H:476
-
int ncorr
Definition: ERF_DataStruct.H:552
-
int force_stage1_single_substep
Definition: ERF_DataStruct.H:545
-
amrex::Real cosphi
Definition: ERF_DataStruct.H:592
-
LandSurfaceType lsm_type
Definition: ERF_DataStruct.H:630
-
amrex::Real c_p
Definition: ERF_DataStruct.H:580
-
std::string windfarm_loc_table
Definition: ERF_DataStruct.H:651
-
amrex::Real gravity
Definition: ERF_DataStruct.H:579
-
std::string pp_prefix
Definition: ERF_DataStruct.H:543
-
void check_params(int max_level)
Definition: ERF_DataStruct.H:374
-
bool custom_rhotheta_forcing
Definition: ERF_DataStruct.H:596
-
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_geo_forcing
Definition: ERF_DataStruct.H:634
-
WindFarmLocType windfarm_loc_type
Definition: ERF_DataStruct.H:629
-
bool custom_w_subsidence
Definition: ERF_DataStruct.H:598
-
bool nudging_from_input_sounding
Definition: ERF_DataStruct.H:604
-
bool rayleigh_damp_U
Definition: ERF_DataStruct.H:567
-
bool custom_geostrophic_profile
Definition: ERF_DataStruct.H:599
-
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:573
-
amrex::Real grid_stretching_ratio
Definition: ERF_DataStruct.H:584
-
amrex::Real sinphi
Definition: ERF_DataStruct.H:593
-
bool have_geo_wind_profile
Definition: ERF_DataStruct.H:636
-
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_pressure_grad
Definition: ERF_DataStruct.H:633
-
amrex::Real NumDiffCoeff
Definition: ERF_DataStruct.H:620
-
bool do_precip
Definition: ERF_DataStruct.H:641
-
amrex::Vector< SubsteppingType > substepping_type
Definition: ERF_DataStruct.H:547
-
bool coriolis_3d
Definition: ERF_DataStruct.H:565
+
bool use_terrain
Definition: ERF_DataStruct.H:557
+
bool rayleigh_damp_T
Definition: ERF_DataStruct.H:569
+
amrex::Real dz0
Definition: ERF_DataStruct.H:585
+
bool use_lagged_delta_rt
Definition: ERF_DataStruct.H:575
+
amrex::Real coriolis_factor
Definition: ERF_DataStruct.H:590
+
bool use_explicit_most
Definition: ERF_DataStruct.H:606
+
amrex::Real windfarm_x_shift
Definition: ERF_DataStruct.H:654
+
bool rayleigh_damp_V
Definition: ERF_DataStruct.H:567
+
int RhoQr_comp
Definition: ERF_DataStruct.H:648
+
amrex::Real poisson_reltol
Definition: ERF_DataStruct.H:553
+
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:571
+
amrex::Real rdOcp
Definition: ERF_DataStruct.H:580
+
void read_int_string(int max_level, const char *string_to_read, amrex::Vector< int > &vec_to_fill, int default_int)
Definition: ERF_DataStruct.H:518
+
std::string windfarm_spec_table
Definition: ERF_DataStruct.H:650
+
bool use_mono_adv
Definition: ERF_DataStruct.H:622
+
DiffChoice diffChoice
Definition: ERF_DataStruct.H:537
+
bool use_gravity
Definition: ERF_DataStruct.H:562
+
void build_coriolis_forcings()
Definition: ERF_DataStruct.H:475
+
int ncorr
Definition: ERF_DataStruct.H:551
+
int force_stage1_single_substep
Definition: ERF_DataStruct.H:544
+
amrex::Real cosphi
Definition: ERF_DataStruct.H:591
+
LandSurfaceType lsm_type
Definition: ERF_DataStruct.H:629
+
amrex::Real c_p
Definition: ERF_DataStruct.H:579
+
std::string windfarm_loc_table
Definition: ERF_DataStruct.H:650
+
amrex::Real gravity
Definition: ERF_DataStruct.H:578
+
std::string pp_prefix
Definition: ERF_DataStruct.H:542
+
void check_params(int max_level)
Definition: ERF_DataStruct.H:373
+
bool custom_rhotheta_forcing
Definition: ERF_DataStruct.H:595
+
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_geo_forcing
Definition: ERF_DataStruct.H:633
+
WindFarmLocType windfarm_loc_type
Definition: ERF_DataStruct.H:628
+
bool custom_w_subsidence
Definition: ERF_DataStruct.H:597
+
bool nudging_from_input_sounding
Definition: ERF_DataStruct.H:603
+
bool rayleigh_damp_U
Definition: ERF_DataStruct.H:566
+
bool custom_geostrophic_profile
Definition: ERF_DataStruct.H:598
+
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:572
+
amrex::Real grid_stretching_ratio
Definition: ERF_DataStruct.H:583
+
amrex::Real sinphi
Definition: ERF_DataStruct.H:592
+
bool have_geo_wind_profile
Definition: ERF_DataStruct.H:635
+
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_pressure_grad
Definition: ERF_DataStruct.H:632
+
amrex::Real NumDiffCoeff
Definition: ERF_DataStruct.H:619
+
bool do_precip
Definition: ERF_DataStruct.H:640
+
amrex::Vector< SubsteppingType > substepping_type
Definition: ERF_DataStruct.H:546
+
bool coriolis_3d
Definition: ERF_DataStruct.H:564
void init_params(int max_level)
Definition: ERF_DataStruct.H:80
-
amrex::Real sampling_distance_by_D
Definition: ERF_DataStruct.H:653
-
int RhoQv_comp
Definition: ERF_DataStruct.H:643
-
bool test_mapfactor
Definition: ERF_DataStruct.H:556
-
void display(int max_level)
Definition: ERF_DataStruct.H:417
-
bool use_coriolis
Definition: ERF_DataStruct.H:564
-
bool use_NumDiff
Definition: ERF_DataStruct.H:619
-
bool custom_moisture_forcing
Definition: ERF_DataStruct.H:597
-
std::string windfarm_blade_table
Definition: ERF_DataStruct.H:652
-
amrex::Real zsurf
Definition: ERF_DataStruct.H:585
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
-
bool project_initial_velocity
Definition: ERF_DataStruct.H:588
-
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:548
-
int constant_density
Definition: ERF_DataStruct.H:550
-
AdvChoice advChoice
Definition: ERF_DataStruct.H:537
-
bool use_moist_background
Definition: ERF_DataStruct.H:642
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
-
bool custom_forcing_prim_vars
Definition: ERF_DataStruct.H:600
-
std::string abl_geo_wind_table
Definition: ERF_DataStruct.H:635
-
TerrainType terrain_type
Definition: ERF_DataStruct.H:626
-
ABLDriverType abl_driver_type
Definition: ERF_DataStruct.H:632
-
bool rayleigh_damp_W
Definition: ERF_DataStruct.H:569
-
PerturbationType pert_type
Definition: ERF_DataStruct.H:616
-
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:539
-
WindFarmType windfarm_type
Definition: ERF_DataStruct.H:628
-
int buoyancy_type
Definition: ERF_DataStruct.H:560
-
amrex::Real poisson_abstol
Definition: ERF_DataStruct.H:553
-
amrex::Real turb_disk_angle
Definition: ERF_DataStruct.H:654
-
amrex::Real windfarm_y_shift
Definition: ERF_DataStruct.H:656
-
bool time_avg_vel
Definition: ERF_DataStruct.H:613
-
bool do_cloud
Definition: ERF_DataStruct.H:640
-
bool use_rotate_most
Definition: ERF_DataStruct.H:610
-
amrex::Real rayleigh_dampcoef
Definition: ERF_DataStruct.H:571
-
CouplingType coupling_type
Definition: ERF_DataStruct.H:625
-
std::string windfarm_airfoil_tables
Definition: ERF_DataStruct.H:652
-
int project_every_stage
Definition: ERF_DataStruct.H:551
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
amrex::Real sampling_distance_by_D
Definition: ERF_DataStruct.H:652
+
int RhoQv_comp
Definition: ERF_DataStruct.H:642
+
bool test_mapfactor
Definition: ERF_DataStruct.H:555
+
void display(int max_level)
Definition: ERF_DataStruct.H:416
+
bool use_coriolis
Definition: ERF_DataStruct.H:563
+
bool use_NumDiff
Definition: ERF_DataStruct.H:618
+
bool custom_moisture_forcing
Definition: ERF_DataStruct.H:596
+
std::string windfarm_blade_table
Definition: ERF_DataStruct.H:651
+
amrex::Real zsurf
Definition: ERF_DataStruct.H:584
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
+
bool project_initial_velocity
Definition: ERF_DataStruct.H:587
+
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:547
+
int constant_density
Definition: ERF_DataStruct.H:549
+
AdvChoice advChoice
Definition: ERF_DataStruct.H:536
+
bool use_moist_background
Definition: ERF_DataStruct.H:641
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
bool custom_forcing_prim_vars
Definition: ERF_DataStruct.H:599
+
std::string abl_geo_wind_table
Definition: ERF_DataStruct.H:634
+
TerrainType terrain_type
Definition: ERF_DataStruct.H:625
+
ABLDriverType abl_driver_type
Definition: ERF_DataStruct.H:631
+
bool rayleigh_damp_W
Definition: ERF_DataStruct.H:568
+
PerturbationType pert_type
Definition: ERF_DataStruct.H:615
+
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:538
+
WindFarmType windfarm_type
Definition: ERF_DataStruct.H:627
+
int buoyancy_type
Definition: ERF_DataStruct.H:559
+
amrex::Real poisson_abstol
Definition: ERF_DataStruct.H:552
+
amrex::Real turb_disk_angle
Definition: ERF_DataStruct.H:653
+
amrex::Real windfarm_y_shift
Definition: ERF_DataStruct.H:655
+
bool time_avg_vel
Definition: ERF_DataStruct.H:612
+
bool do_cloud
Definition: ERF_DataStruct.H:639
+
bool use_rotate_most
Definition: ERF_DataStruct.H:609
+
amrex::Real rayleigh_dampcoef
Definition: ERF_DataStruct.H:570
+
CouplingType coupling_type
Definition: ERF_DataStruct.H:624
+
std::string windfarm_airfoil_tables
Definition: ERF_DataStruct.H:651
+
int project_every_stage
Definition: ERF_DataStruct.H:550
+
int ave_plane
Definition: ERF_DataStruct.H:637
Definition: ERF_SpongeStruct.H:15
void display()
Definition: ERF_SpongeStruct.H:45
void init_params()
Definition: ERF_SpongeStruct.H:17
diff --git a/ERF__DiffusionSrcForState__N_8cpp.html b/ERF__DiffusionSrcForState__N_8cpp.html index b978a2a5e..5ce9d4260 100644 --- a/ERF__DiffusionSrcForState__N_8cpp.html +++ b/ERF__DiffusionSrcForState__N_8cpp.html @@ -1081,10 +1081,10 @@

amrex::Real alpha_C
Definition: ERF_DiffStruct.H:80
MolecDiffType molec_diff_type
Definition: ERF_DiffStruct.H:76
amrex::Real B1
Definition: ERF_MYNNStruct.H:43
-
int RhoQr_comp
Definition: ERF_DataStruct.H:649
-
DiffChoice diffChoice
Definition: ERF_DataStruct.H:538
-
int RhoQv_comp
Definition: ERF_DataStruct.H:643
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
+
int RhoQr_comp
Definition: ERF_DataStruct.H:648
+
DiffChoice diffChoice
Definition: ERF_DataStruct.H:537
+
int RhoQv_comp
Definition: ERF_DataStruct.H:642
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
Definition: ERF_TurbStruct.H:29
MYNNLevel25 pbl_mynn
Definition: ERF_TurbStruct.H:194
PBLType pbl_type
Definition: ERF_TurbStruct.H:192
diff --git a/ERF__DiffusionSrcForState__T_8cpp.html b/ERF__DiffusionSrcForState__T_8cpp.html index 0e77ec115..c414cbb47 100644 --- a/ERF__DiffusionSrcForState__T_8cpp.html +++ b/ERF__DiffusionSrcForState__T_8cpp.html @@ -1249,10 +1249,10 @@

amrex::Real alpha_C
Definition: ERF_DiffStruct.H:80
MolecDiffType molec_diff_type
Definition: ERF_DiffStruct.H:76
amrex::Real B1
Definition: ERF_MYNNStruct.H:43
-
int RhoQr_comp
Definition: ERF_DataStruct.H:649
-
DiffChoice diffChoice
Definition: ERF_DataStruct.H:538
-
int RhoQv_comp
Definition: ERF_DataStruct.H:643
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
+
int RhoQr_comp
Definition: ERF_DataStruct.H:648
+
DiffChoice diffChoice
Definition: ERF_DataStruct.H:537
+
int RhoQv_comp
Definition: ERF_DataStruct.H:642
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
Definition: ERF_TurbStruct.H:29
MYNNLevel25 pbl_mynn
Definition: ERF_TurbStruct.H:194
PBLType pbl_type
Definition: ERF_TurbStruct.H:192
diff --git a/ERF__EulerianMicrophysics_8H_source.html b/ERF__EulerianMicrophysics_8H_source.html index 97ba9d484..57fe5aa05 100644 --- a/ERF__EulerianMicrophysics_8H_source.html +++ b/ERF__EulerianMicrophysics_8H_source.html @@ -199,44 +199,45 @@
111 
112  /*! \brief get the indices and names of moisture model variables for restart
113  at a given level */
-
114  void Get_Qmoist_Restart_Vars ( const int a_lev, /*!< level */
-
115  std::vector<int>& a_idx, /*!< indices */
-
116  std::vector<std::string>& a_names /*!< names */ ) const override
-
117  {
-
118  m_moist_model[a_lev]->Qmoist_Restart_Vars( a_idx, a_names );
-
119  }
-
120 
-
121 protected:
-
122 
-
123  /*! \brief Create and set the specified moisture model */
-
124  template<class NewMoistModel>
-
125  void SetModel ()
-
126  {
-
127  for (int lev(0); lev<m_moist_model.size(); ++lev) {
-
128  m_moist_model[lev] = std::make_unique<NewMoistModel>();
-
129  }
-
130  }
-
131 
-
132 private:
-
133  amrex::Vector<std::unique_ptr<NullMoist>> m_moist_model; /*!< moisture model */
-
134 };
-
135 #endif
+
114  void Get_Qmoist_Restart_Vars ( const int a_lev, /*!< level */
+
115  const SolverChoice& a_sc, /*!< Solver choice object */
+
116  std::vector<int>& a_idx, /*!< indices */
+
117  std::vector<std::string>& a_names /*!< names */ ) const override
+
118  {
+
119  m_moist_model[a_lev]->Qmoist_Restart_Vars( a_sc, a_idx, a_names );
+
120  }
+
121 
+
122 protected:
+
123 
+
124  /*! \brief Create and set the specified moisture model */
+
125  template<class NewMoistModel>
+
126  void SetModel ()
+
127  {
+
128  for (int lev(0); lev<m_moist_model.size(); ++lev) {
+
129  m_moist_model[lev] = std::make_unique<NewMoistModel>();
+
130  }
+
131  }
+
132 
+
133 private:
+
134  amrex::Vector<std::unique_ptr<NullMoist>> m_moist_model; /*!< moisture model */
+
135 };
+
136 #endif
Contains the base class for microphysics.
Eulerian microphysics interface.
Definition: ERF_EulerianMicrophysics.H:14
+
void Get_Qmoist_Restart_Vars(const int a_lev, const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
get the indices and names of moisture model variables for restart at a given level
Definition: ERF_EulerianMicrophysics.H:114
void Update_Micro_Vars_Lev(const int &lev, amrex::MultiFab &cons_in) override
update microphysics variables from ERF state variables
Definition: ERF_EulerianMicrophysics.H:80
-
void Get_Qmoist_Restart_Vars(const int a_lev, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
get the indices and names of moisture model variables for restart at a given level
Definition: ERF_EulerianMicrophysics.H:114
EulerianMicrophysics(const int &nlev, const MoistureType &a_model_type)
Constructor: create the moisture model.
Definition: ERF_EulerianMicrophysics.H:25
~EulerianMicrophysics()=default
default destructor
-
amrex::Vector< std::unique_ptr< NullMoist > > m_moist_model
Definition: ERF_EulerianMicrophysics.H:133
+
amrex::Vector< std::unique_ptr< NullMoist > > m_moist_model
Definition: ERF_EulerianMicrophysics.H:134
int Get_Qstate_Size() override
get the number of moisture-model-related conserved state variables
Definition: ERF_EulerianMicrophysics.H:107
amrex::MultiFab * Get_Qmoist_Ptr(const int &lev, const int &varIdx) override
get pointer to a moisture variable
Definition: ERF_EulerianMicrophysics.H:94
void Define(const int &lev, SolverChoice &sc) override
Define the moisture model.
Definition: ERF_EulerianMicrophysics.H:48
void Advance(const int &lev, const amrex::Real &dt_advance, const int &, const amrex::Real &, const SolverChoice &solverChoice, amrex::Vector< amrex::Vector< amrex::MultiFab >> &, const amrex::Vector< std::unique_ptr< amrex::MultiFab >> &) override
Advance the moisture model for one time step.
Definition: ERF_EulerianMicrophysics.H:68
void Update_State_Vars_Lev(const int &lev, amrex::MultiFab &cons_in) override
update ERF state variables from microphysics variables
Definition: ERF_EulerianMicrophysics.H:87
-
void SetModel()
Create and set the specified moisture model.
Definition: ERF_EulerianMicrophysics.H:125
+
void SetModel()
Create and set the specified moisture model.
Definition: ERF_EulerianMicrophysics.H:126
void Init(const int &lev, const amrex::MultiFab &cons_in, const amrex::BoxArray &grids, const amrex::Geometry &geom, const amrex::Real &dt_advance, std::unique_ptr< amrex::MultiFab > &z_phys_nd, std::unique_ptr< amrex::MultiFab > &detJ_cc) override
Initialize the moisture model.
Definition: ERF_EulerianMicrophysics.H:55
int Get_Qmoist_Size(const int &) override
get the number of moisture model variables
Definition: ERF_EulerianMicrophysics.H:101
EulerianMicrophysics()
Null constructor.
Definition: ERF_EulerianMicrophysics.H:19
diff --git a/ERF__Kessler_8H_source.html b/ERF__Kessler_8H_source.html index 62a29b0fb..39fb3ed15 100644 --- a/ERF__Kessler_8H_source.html +++ b/ERF__Kessler_8H_source.html @@ -213,56 +213,59 @@
125  Qstate_Size () override { return Kessler::m_qstate_size; }
126 
127  void
-
128  Qmoist_Restart_Vars ( std::vector<int>& a_idx,
-
129  std::vector<std::string>& a_names) const override
-
130  {
-
131  a_idx.clear();
-
132  a_names.clear();
-
133  a_idx.push_back(4); a_names.push_back("RainAccum");
-
134  }
-
135 
-
136 private:
-
137  // Number of qmoist variables (qt, qv, qcl, qp)
-
138  int m_qmoist_size = 5;
-
139 
-
140  // Number of qstate variables
-
141  int m_qstate_size = 3;
+ +
129  std::vector<int>& a_idx,
+
130  std::vector<std::string>& a_names) const override
+
131  {
+
132  a_idx.clear();
+
133  a_names.clear();
+
134  if (a_sc.moisture_type == MoistureType::Kessler) {
+
135  a_idx.push_back(4); a_names.push_back("RainAccum");
+
136  }
+
137  }
+
138 
+
139 private:
+
140  // Number of qmoist variables (qt, qv, qcl, qp)
+
141  int m_qmoist_size = 5;
142 
-
143  // MicVar map (Qmoist indices -> MicVar enum)
-
144  amrex::Vector<int> MicVarMap;
+
143  // Number of qstate variables
+
144  int m_qstate_size = 3;
145 
-
146  // geometry
-
147  amrex::Geometry m_geom;
+
146  // MicVar map (Qmoist indices -> MicVar enum)
+
147  amrex::Vector<int> MicVarMap;
148 
-
149  // valid boxes on which to evolve the solution
-
150  amrex::BoxArray m_gtoe;
+
149  // geometry
+
150  amrex::Geometry m_geom;
151 
-
152  // timestep
-
153  amrex::Real dt;
+
152  // valid boxes on which to evolve the solution
+
153  amrex::BoxArray m_gtoe;
154 
-
155  // number of vertical levels
-
156  int nlev, zlo, zhi;
+
155  // timestep
+
156  amrex::Real dt;
157 
-
158  // plane average axis
-
159  int m_axis;
+
158  // number of vertical levels
+
159  int nlev, zlo, zhi;
160 
-
161  // model options
- +
161  // plane average axis
+
162  int m_axis;
163 
-
164  // constants
-
165  amrex::Real m_fac_cond;
-
166  amrex::Real m_fac_fus;
-
167  amrex::Real m_fac_sub;
-
168  amrex::Real m_gOcp;
-
169 
-
170  // Pointer to terrain data
-
171  amrex::MultiFab* m_z_phys_nd;
-
172  amrex::MultiFab* m_detJ_cc;
-
173 
-
174  // independent variables
-
175  amrex::Array<FabPtr, MicVar_Kess::NumVars> mic_fab_vars;
-
176 };
-
177 #endif
+
164  // model options
+ +
166 
+
167  // constants
+
168  amrex::Real m_fac_cond;
+
169  amrex::Real m_fac_fus;
+
170  amrex::Real m_fac_sub;
+
171  amrex::Real m_gOcp;
+
172 
+
173  // Pointer to terrain data
+
174  amrex::MultiFab* m_z_phys_nd;
+
175  amrex::MultiFab* m_detJ_cc;
+
176 
+
177  // independent variables
+
178  amrex::Array<FabPtr, MicVar_Kess::NumVars> mic_fab_vars;
+
179 };
+
180 #endif
constexpr amrex::Real lfus
Definition: ERF_Constants.H:67
constexpr amrex::Real lsub
Definition: ERF_Constants.H:68
@@ -273,40 +276,40 @@
Definition: ERF_Kessler.H:46
-
int zlo
Definition: ERF_Kessler.H:156
+
int zlo
Definition: ERF_Kessler.H:159
void Update_Micro_Vars(amrex::MultiFab &cons_in) override
Definition: ERF_Kessler.H:92
amrex::MultiFab * Qmoist_Ptr(const int &varIdx) override
Definition: ERF_Kessler.H:115
-
amrex::Vector< int > MicVarMap
Definition: ERF_Kessler.H:144
+
amrex::Vector< int > MicVarMap
Definition: ERF_Kessler.H:147
void Copy_State_to_Micro(const amrex::MultiFab &cons_in) override
Definition: ERF_Init_Kessler.cpp:64
int Qstate_Size() override
Definition: ERF_Kessler.H:125
-
bool doprecip
Definition: ERF_Kessler.H:162
-
amrex::Real m_fac_sub
Definition: ERF_Kessler.H:167
+
bool doprecip
Definition: ERF_Kessler.H:165
+
amrex::Real m_fac_sub
Definition: ERF_Kessler.H:170
int Qmoist_Size() override
Definition: ERF_Kessler.H:122
virtual ~Kessler()=default
-
amrex::Geometry m_geom
Definition: ERF_Kessler.H:147
+
amrex::Geometry m_geom
Definition: ERF_Kessler.H:150
Kessler()
Definition: ERF_Kessler.H:52
-
amrex::MultiFab * m_detJ_cc
Definition: ERF_Kessler.H:172
+
amrex::MultiFab * m_detJ_cc
Definition: ERF_Kessler.H:175
void Define(SolverChoice &sc) override
Definition: ERF_Kessler.H:62
-
bool docloud
Definition: ERF_Kessler.H:162
-
amrex::Real m_fac_cond
Definition: ERF_Kessler.H:165
+
bool docloud
Definition: ERF_Kessler.H:165
+
amrex::Real m_fac_cond
Definition: ERF_Kessler.H:168
void Copy_Micro_to_State(amrex::MultiFab &cons_in) override
Definition: ERF_Update_Kessler.cpp:14
-
amrex::Real dt
Definition: ERF_Kessler.H:153
-
int zhi
Definition: ERF_Kessler.H:156
-
int nlev
Definition: ERF_Kessler.H:156
-
amrex::Array< FabPtr, MicVar_Kess::NumVars > mic_fab_vars
Definition: ERF_Kessler.H:175
-
amrex::Real m_gOcp
Definition: ERF_Kessler.H:168
-
amrex::MultiFab * m_z_phys_nd
Definition: ERF_Kessler.H:171
+
amrex::Real dt
Definition: ERF_Kessler.H:156
+
int zhi
Definition: ERF_Kessler.H:159
+
int nlev
Definition: ERF_Kessler.H:159
+
amrex::Array< FabPtr, MicVar_Kess::NumVars > mic_fab_vars
Definition: ERF_Kessler.H:178
+
amrex::Real m_gOcp
Definition: ERF_Kessler.H:171
+
amrex::MultiFab * m_z_phys_nd
Definition: ERF_Kessler.H:174
void Init(const amrex::MultiFab &cons_in, const amrex::BoxArray &grids, const amrex::Geometry &geom, const amrex::Real &dt_advance, std::unique_ptr< amrex::MultiFab > &z_phys_nd, std::unique_ptr< amrex::MultiFab > &detJ_cc) override
Definition: ERF_Init_Kessler.cpp:22
void AdvanceKessler(const SolverChoice &solverChoice)
Definition: ERF_Kessler.cpp:11
-
amrex::Real m_fac_fus
Definition: ERF_Kessler.H:166
-
int m_qstate_size
Definition: ERF_Kessler.H:141
+
amrex::Real m_fac_fus
Definition: ERF_Kessler.H:169
+
int m_qstate_size
Definition: ERF_Kessler.H:144
std::shared_ptr< amrex::MultiFab > FabPtr
Definition: ERF_Kessler.H:48
void Advance(const amrex::Real &dt_advance, const SolverChoice &solverChoice) override
Definition: ERF_Kessler.H:106
void Update_State_Vars(amrex::MultiFab &cons_in) override
Definition: ERF_Kessler.H:99
-
amrex::BoxArray m_gtoe
Definition: ERF_Kessler.H:150
-
int m_qmoist_size
Definition: ERF_Kessler.H:138
-
void Qmoist_Restart_Vars(std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
Definition: ERF_Kessler.H:128
-
int m_axis
Definition: ERF_Kessler.H:159
+
amrex::BoxArray m_gtoe
Definition: ERF_Kessler.H:153
+
int m_qmoist_size
Definition: ERF_Kessler.H:141
+
void Qmoist_Restart_Vars(const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
Definition: ERF_Kessler.H:128
+
int m_axis
Definition: ERF_Kessler.H:162
Definition: ERF_NullMoist.H:8
Definition: ERF_Kessler.H:27
@ qp
Definition: ERF_Kessler.H:39
@@ -320,10 +323,11 @@
@ NumVars
Definition: ERF_Kessler.H:42
@ qv
Definition: ERF_Kessler.H:36
Definition: ERF_DataStruct.H:78
-
amrex::Real c_p
Definition: ERF_DataStruct.H:580
-
bool do_precip
Definition: ERF_DataStruct.H:641
-
bool do_cloud
Definition: ERF_DataStruct.H:640
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
amrex::Real c_p
Definition: ERF_DataStruct.H:579
+
bool do_precip
Definition: ERF_DataStruct.H:640
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
bool do_cloud
Definition: ERF_DataStruct.H:639
+
int ave_plane
Definition: ERF_DataStruct.H:637
diff --git a/ERF__LagrangianMicrophysics_8H_source.html b/ERF__LagrangianMicrophysics_8H_source.html index ef792d1c0..850a5bbfd 100644 --- a/ERF__LagrangianMicrophysics_8H_source.html +++ b/ERF__LagrangianMicrophysics_8H_source.html @@ -225,32 +225,33 @@
137 
138  /*! \brief get the indices and names of moisture model variables for restart
139  at a given level */
-
140  void Get_Qmoist_Restart_Vars ( const int a_lev, /*!< level */
-
141  std::vector<int>& a_idx, /*!< indices */
-
142  std::vector<std::string>& a_names /*!< names */ ) const override
-
143  {
-
144  if (a_lev == 0) {
-
145  m_moist_model->Qmoist_Restart_Vars( a_idx, a_names );
-
146  } else {
-
147  a_idx.clear();
-
148  a_names.clear();
-
149  }
-
150  }
-
151 
-
152 protected:
-
153 
-
154  /*! \brief Create and set the specified moisture model */
-
155  template<class NewMoistModel>
-
156  void SetModel ()
-
157  {
-
158  m_moist_model = std::make_unique<NewMoistModel>();
-
159  }
-
160 
-
161  std::unique_ptr<NullMoistLagrangian> m_moist_model; /*!< moisture model */
-
162 };
-
163 
-
164 #endif
+
140  void Get_Qmoist_Restart_Vars ( const int a_lev, /*!< level */
+
141  const SolverChoice& a_sc, /*!< Solver choice object */
+
142  std::vector<int>& a_idx, /*!< indices */
+
143  std::vector<std::string>& a_names /*!< names */ ) const override
+
144  {
+
145  if (a_lev == 0) {
+
146  m_moist_model->Qmoist_Restart_Vars( a_sc, a_idx, a_names );
+
147  } else {
+
148  a_idx.clear();
+
149  a_names.clear();
+
150  }
+
151  }
+
152 
+
153 protected:
+
154 
+
155  /*! \brief Create and set the specified moisture model */
+
156  template<class NewMoistModel>
+
157  void SetModel ()
+
158  {
+
159  m_moist_model = std::make_unique<NewMoistModel>();
+
160  }
+
161 
+
162  std::unique_ptr<NullMoistLagrangian> m_moist_model; /*!< moisture model */
+
163 };
+
164 
165 #endif
+
166 #endif
Contains the base class for microphysics.
Contains the Lagrangian moisture model base class.
Base class for microphysics interface.
Definition: ERF_Microphysics.H:13
@@ -262,7 +263,7 @@
virtual int Get_Qstate_Size()=0
get the number of moisture-model-related conserved state variables
virtual void Advance(const int &, const amrex::Real &, const int &, const amrex::Real &, const SolverChoice &, amrex::Vector< amrex::Vector< amrex::MultiFab >> &, const amrex::Vector< std::unique_ptr< amrex::MultiFab >> &)=0
advance microphysics for one time step
virtual amrex::MultiFab * Get_Qmoist_Ptr(const int &, const int &)=0
get pointer to a moisture variable
-
virtual void Get_Qmoist_Restart_Vars(int, std::vector< int > &, std::vector< std::string > &) const =0
get the indices and names of moisture model variables for restart at a given level
+
virtual void Get_Qmoist_Restart_Vars(int, const SolverChoice &, std::vector< int > &, std::vector< std::string > &) const =0
get the indices and names of moisture model variables for restart at a given level
static MoistureModelType modelType(const MoistureType a_moisture_type)
query if a specified moisture model is Eulerian or Lagrangian
Definition: ERF_Microphysics.H:64
Definition: ERF_DataStruct.H:78
diff --git a/ERF__Microphysics_8H_source.html b/ERF__Microphysics_8H_source.html index a0d48af17..2ed27d149 100644 --- a/ERF__Microphysics_8H_source.html +++ b/ERF__Microphysics_8H_source.html @@ -146,7 +146,7 @@
58 
59  /*! \brief get the indices and names of moisture model variables for restart
60  at a given level */
-
61  virtual void Get_Qmoist_Restart_Vars ( int, std::vector<int>&, std::vector<std::string>& ) const = 0;
+
61  virtual void Get_Qmoist_Restart_Vars ( int, const SolverChoice&, std::vector<int>&, std::vector<std::string>& ) const = 0;
62 
63  /*! \brief query if a specified moisture model is Eulerian or Lagrangian */
64  static MoistureModelType modelType (const MoistureType a_moisture_type)
@@ -180,7 +180,7 @@
Microphysics()
Null constructor.
Definition: ERF_Microphysics.H:18
virtual void Advance(const int &, const amrex::Real &, const int &, const amrex::Real &, const SolverChoice &, amrex::Vector< amrex::Vector< amrex::MultiFab >> &, const amrex::Vector< std::unique_ptr< amrex::MultiFab >> &)=0
advance microphysics for one time step
virtual amrex::MultiFab * Get_Qmoist_Ptr(const int &, const int &)=0
get pointer to a moisture variable
-
virtual void Get_Qmoist_Restart_Vars(int, std::vector< int > &, std::vector< std::string > &) const =0
get the indices and names of moisture model variables for restart at a given level
+
virtual void Get_Qmoist_Restart_Vars(int, const SolverChoice &, std::vector< int > &, std::vector< std::string > &) const =0
get the indices and names of moisture model variables for restart at a given level
static MoistureModelType modelType(const MoistureType a_moisture_type)
query if a specified moisture model is Eulerian or Lagrangian
Definition: ERF_Microphysics.H:64
Definition: ERF_DataStruct.H:78
diff --git a/ERF__NullMoist_8H_source.html b/ERF__NullMoist_8H_source.html index d4d748921..d2c1f0b3d 100644 --- a/ERF__NullMoist_8H_source.html +++ b/ERF__NullMoist_8H_source.html @@ -147,7 +147,7 @@
59 
60  virtual
61  void
-
62  Qmoist_Restart_Vars ( std::vector<int>& a_idx, std::vector<std::string>& a_names) const
+
62  Qmoist_Restart_Vars ( const SolverChoice&, std::vector<int>& a_idx, std::vector<std::string>& a_names) const
63  {
64  a_idx.clear();
65  a_names.clear();
@@ -164,11 +164,11 @@
virtual void Copy_Micro_to_State(amrex::MultiFab &)
Definition: ERF_NullMoist.H:46
virtual amrex::MultiFab * Qmoist_Ptr(const int &)
Definition: ERF_NullMoist.H:50
virtual void Update_State_Vars(amrex::MultiFab &)
Definition: ERF_NullMoist.H:38
-
virtual void Qmoist_Restart_Vars(std::vector< int > &a_idx, std::vector< std::string > &a_names) const
Definition: ERF_NullMoist.H:62
int m_qstate_size
Definition: ERF_NullMoist.H:70
int m_qmoist_size
Definition: ERF_NullMoist.H:69
virtual void Init(const amrex::MultiFab &, const amrex::BoxArray &, const amrex::Geometry &, const amrex::Real &, std::unique_ptr< amrex::MultiFab > &, std::unique_ptr< amrex::MultiFab > &)
Definition: ERF_NullMoist.H:20
virtual ~NullMoist()=default
+
virtual void Qmoist_Restart_Vars(const SolverChoice &, std::vector< int > &a_idx, std::vector< std::string > &a_names) const
Definition: ERF_NullMoist.H:62
NullMoist()
Definition: ERF_NullMoist.H:11
virtual void Advance(const amrex::Real &, const SolverChoice &)
Definition: ERF_NullMoist.H:29
virtual void Define(SolverChoice &)
Definition: ERF_NullMoist.H:17
diff --git a/ERF__SAM_8H_source.html b/ERF__SAM_8H_source.html index 4da065465..3f76b0aa2 100644 --- a/ERF__SAM_8H_source.html +++ b/ERF__SAM_8H_source.html @@ -352,84 +352,89 @@
264  }
265 
266  void
-
267  Qmoist_Restart_Vars ( std::vector<int>& a_idx,
-
268  std::vector<std::string>& a_names) const override
-
269  {
-
270  a_idx.clear();
-
271  a_names.clear();
-
272  a_idx.push_back( 8); a_names.push_back("RainAccum");
-
273  a_idx.push_back( 9); a_names.push_back("SnowAccum");
-
274  a_idx.push_back(10); a_names.push_back("GraupAccum");
-
275  }
-
276 
-
277 private:
-
278  // Number of qmoist variables (qt, qv, qcl, qci, qp, qpr, qps, qpg)
-
279  int m_qmoist_size = 11;
-
280 
-
281  // Number of qmoist variables
-
282  int m_qstate_size = 6;
-
283 
-
284  // MicVar map (Qmoist indices -> MicVar enum)
-
285  amrex::Vector<int> MicVarMap;
-
286 
-
287  // geometry
-
288  amrex::Geometry m_geom;
-
289 
-
290  // valid boxes on which to evolve the solution
-
291  amrex::BoxArray m_gtoe;
-
292 
-
293  // timestep
-
294  amrex::Real dt;
-
295 
-
296  // number of vertical levels
-
297  int nlev, zlo, zhi;
-
298 
-
299  // plane average axis
-
300  int m_axis;
-
301 
-
302  // model options
- -
304 
-
305  // constants
-
306  amrex::Real m_fac_cond;
-
307  amrex::Real m_fac_fus;
-
308  amrex::Real m_fac_sub;
-
309  amrex::Real m_gOcp;
-
310  amrex::Real m_rdOcp;
-
311 
-
312  // Pointer to terrain data
-
313  amrex::MultiFab* m_z_phys_nd;
-
314  amrex::MultiFab* m_detJ_cc;
-
315 
-
316  // independent variables
-
317  amrex::Array<FabPtr, MicVar::NumVars> mic_fab_vars;
-
318 
-
319  // microphysics parameters/coefficients
-
320  amrex::TableData<amrex::Real, 1> accrrc;
-
321  amrex::TableData<amrex::Real, 1> accrsi;
-
322  amrex::TableData<amrex::Real, 1> accrsc;
-
323  amrex::TableData<amrex::Real, 1> coefice;
-
324  amrex::TableData<amrex::Real, 1> evaps1;
-
325  amrex::TableData<amrex::Real, 1> evaps2;
-
326  amrex::TableData<amrex::Real, 1> accrgi;
-
327  amrex::TableData<amrex::Real, 1> accrgc;
-
328  amrex::TableData<amrex::Real, 1> evapg1;
-
329  amrex::TableData<amrex::Real, 1> evapg2;
-
330  amrex::TableData<amrex::Real, 1> evapr1;
-
331  amrex::TableData<amrex::Real, 1> evapr2;
-
332 
-
333  // vertical plane average data
-
334  amrex::TableData<amrex::Real, 1> rho1d;
-
335  amrex::TableData<amrex::Real, 1> pres1d;
-
336  amrex::TableData<amrex::Real, 1> tabs1d;
-
337  amrex::TableData<amrex::Real, 1> qt1d;
-
338  amrex::TableData<amrex::Real, 1> qv1d;
-
339  amrex::TableData<amrex::Real, 1> qn1d;
-
340 
-
341  amrex::TableData<amrex::Real, 1> gamaz;
-
342  amrex::TableData<amrex::Real, 1> zmid; // mid value of vertical coordinate in physical domain
-
343 };
-
344 #endif
+ +
268  std::vector<int>& a_idx,
+
269  std::vector<std::string>& a_names) const override
+
270  {
+
271  a_idx.clear();
+
272  a_names.clear();
+
273  if (a_sc.moisture_type == MoistureType::SAM) {
+
274  a_idx.push_back( 8); a_names.push_back("RainAccum");
+
275  a_idx.push_back( 9); a_names.push_back("SnowAccum");
+
276  a_idx.push_back(10); a_names.push_back("GraupAccum");
+
277  } else if (a_sc.moisture_type == MoistureType::SAM_NoIce) {
+
278  a_idx.push_back( 8); a_names.push_back("RainAccum");
+
279  }
+
280  }
+
281 
+
282 private:
+
283  // Number of qmoist variables (qt, qv, qcl, qci, qp, qpr, qps, qpg)
+
284  int m_qmoist_size = 11;
+
285 
+
286  // Number of qmoist variables
+
287  int m_qstate_size = 6;
+
288 
+
289  // MicVar map (Qmoist indices -> MicVar enum)
+
290  amrex::Vector<int> MicVarMap;
+
291 
+
292  // geometry
+
293  amrex::Geometry m_geom;
+
294 
+
295  // valid boxes on which to evolve the solution
+
296  amrex::BoxArray m_gtoe;
+
297 
+
298  // timestep
+
299  amrex::Real dt;
+
300 
+
301  // number of vertical levels
+
302  int nlev, zlo, zhi;
+
303 
+
304  // plane average axis
+
305  int m_axis;
+
306 
+
307  // model options
+ +
309 
+
310  // constants
+
311  amrex::Real m_fac_cond;
+
312  amrex::Real m_fac_fus;
+
313  amrex::Real m_fac_sub;
+
314  amrex::Real m_gOcp;
+
315  amrex::Real m_rdOcp;
+
316 
+
317  // Pointer to terrain data
+
318  amrex::MultiFab* m_z_phys_nd;
+
319  amrex::MultiFab* m_detJ_cc;
+
320 
+
321  // independent variables
+
322  amrex::Array<FabPtr, MicVar::NumVars> mic_fab_vars;
+
323 
+
324  // microphysics parameters/coefficients
+
325  amrex::TableData<amrex::Real, 1> accrrc;
+
326  amrex::TableData<amrex::Real, 1> accrsi;
+
327  amrex::TableData<amrex::Real, 1> accrsc;
+
328  amrex::TableData<amrex::Real, 1> coefice;
+
329  amrex::TableData<amrex::Real, 1> evaps1;
+
330  amrex::TableData<amrex::Real, 1> evaps2;
+
331  amrex::TableData<amrex::Real, 1> accrgi;
+
332  amrex::TableData<amrex::Real, 1> accrgc;
+
333  amrex::TableData<amrex::Real, 1> evapg1;
+
334  amrex::TableData<amrex::Real, 1> evapg2;
+
335  amrex::TableData<amrex::Real, 1> evapr1;
+
336  amrex::TableData<amrex::Real, 1> evapr2;
+
337 
+
338  // vertical plane average data
+
339  amrex::TableData<amrex::Real, 1> rho1d;
+
340  amrex::TableData<amrex::Real, 1> pres1d;
+
341  amrex::TableData<amrex::Real, 1> tabs1d;
+
342  amrex::TableData<amrex::Real, 1> qt1d;
+
343  amrex::TableData<amrex::Real, 1> qv1d;
+
344  amrex::TableData<amrex::Real, 1> qn1d;
+
345 
+
346  amrex::TableData<amrex::Real, 1> gamaz;
+
347  amrex::TableData<amrex::Real, 1> zmid; // mid value of vertical coordinate in physical domain
+
348 };
+
349 #endif
constexpr amrex::Real lfus
Definition: ERF_Constants.H:67
constexpr amrex::Real tbgmax
Definition: ERF_Constants.H:32
@@ -450,63 +455,63 @@
void Copy_Micro_to_State(amrex::MultiFab &cons_in) override
Definition: ERF_Update_SAM.cpp:15
void Advance(const amrex::Real &dt_advance, const SolverChoice &sc) override
Definition: ERF_SAM.H:123
AMREX_GPU_HOST_DEVICE static AMREX_FORCE_INLINE amrex::Real NewtonIterSat(int &i, int &j, int &k, const int &SAM_moisture_type, const amrex::Real &fac_cond, const amrex::Real &fac_fus, const amrex::Real &fac_sub, const amrex::Real &an, const amrex::Real &bn, const amrex::Array4< amrex::Real > &tabs_array, const amrex::Array4< amrex::Real > &pres_array, const amrex::Array4< amrex::Real > &qv_array, const amrex::Array4< amrex::Real > &qc_array, const amrex::Array4< amrex::Real > &qi_array, const amrex::Array4< amrex::Real > &qn_array, const amrex::Array4< amrex::Real > &qt_array)
Definition: ERF_SAM.H:153
-
int zlo
Definition: ERF_SAM.H:297
+
int zlo
Definition: ERF_SAM.H:302
void Precip(const SolverChoice &sc)
Definition: ERF_Precip.cpp:10
-
amrex::TableData< amrex::Real, 1 > rho1d
Definition: ERF_SAM.H:334
-
amrex::TableData< amrex::Real, 1 > evapr2
Definition: ERF_SAM.H:331
+
amrex::TableData< amrex::Real, 1 > rho1d
Definition: ERF_SAM.H:339
+
amrex::TableData< amrex::Real, 1 > evapr2
Definition: ERF_SAM.H:336
SAM()
Definition: ERF_SAM.H:60
-
amrex::MultiFab * m_detJ_cc
Definition: ERF_SAM.H:314
+
amrex::MultiFab * m_detJ_cc
Definition: ERF_SAM.H:319
void Copy_State_to_Micro(const amrex::MultiFab &cons_in) override
Definition: ERF_Init_SAM.cpp:88
-
amrex::TableData< amrex::Real, 1 > evapg1
Definition: ERF_SAM.H:328
+
amrex::TableData< amrex::Real, 1 > evapg1
Definition: ERF_SAM.H:333
void Update_Micro_Vars(amrex::MultiFab &cons_in) override
Definition: ERF_SAM.H:109
-
amrex::TableData< amrex::Real, 1 > accrgi
Definition: ERF_SAM.H:326
+
amrex::TableData< amrex::Real, 1 > accrgi
Definition: ERF_SAM.H:331
std::shared_ptr< amrex::MultiFab > FabPtr
Definition: ERF_SAM.H:56
virtual ~SAM()=default
-
amrex::TableData< amrex::Real, 1 > evapg2
Definition: ERF_SAM.H:329
+
amrex::TableData< amrex::Real, 1 > evapg2
Definition: ERF_SAM.H:334
void IceFall(const SolverChoice &sc)
Definition: ERF_IceFall.cpp:10
-
amrex::Array< FabPtr, MicVar::NumVars > mic_fab_vars
Definition: ERF_SAM.H:317
-
int m_axis
Definition: ERF_SAM.H:300
-
amrex::Real m_gOcp
Definition: ERF_SAM.H:309
-
amrex::Real m_rdOcp
Definition: ERF_SAM.H:310
-
void Qmoist_Restart_Vars(std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
Definition: ERF_SAM.H:267
+
amrex::Array< FabPtr, MicVar::NumVars > mic_fab_vars
Definition: ERF_SAM.H:322
+
int m_axis
Definition: ERF_SAM.H:305
+
amrex::Real m_gOcp
Definition: ERF_SAM.H:314
+
amrex::Real m_rdOcp
Definition: ERF_SAM.H:315
void Cloud(const SolverChoice &sc)
Definition: ERF_Cloud_SAM.cpp:12
-
int m_qmoist_size
Definition: ERF_SAM.H:279
-
amrex::MultiFab * m_z_phys_nd
Definition: ERF_SAM.H:313
-
amrex::Real m_fac_fus
Definition: ERF_SAM.H:307
-
bool doprecip
Definition: ERF_SAM.H:303
-
amrex::TableData< amrex::Real, 1 > evaps1
Definition: ERF_SAM.H:324
-
amrex::BoxArray m_gtoe
Definition: ERF_SAM.H:291
-
amrex::TableData< amrex::Real, 1 > zmid
Definition: ERF_SAM.H:342
-
amrex::Vector< int > MicVarMap
Definition: ERF_SAM.H:285
-
amrex::TableData< amrex::Real, 1 > qv1d
Definition: ERF_SAM.H:338
-
amrex::Real m_fac_cond
Definition: ERF_SAM.H:306
-
amrex::TableData< amrex::Real, 1 > accrsi
Definition: ERF_SAM.H:321
-
amrex::TableData< amrex::Real, 1 > accrrc
Definition: ERF_SAM.H:320
-
bool docloud
Definition: ERF_SAM.H:303
+
int m_qmoist_size
Definition: ERF_SAM.H:284
+
amrex::MultiFab * m_z_phys_nd
Definition: ERF_SAM.H:318
+
amrex::Real m_fac_fus
Definition: ERF_SAM.H:312
+
bool doprecip
Definition: ERF_SAM.H:308
+
amrex::TableData< amrex::Real, 1 > evaps1
Definition: ERF_SAM.H:329
+
amrex::BoxArray m_gtoe
Definition: ERF_SAM.H:296
+
amrex::TableData< amrex::Real, 1 > zmid
Definition: ERF_SAM.H:347
+
amrex::Vector< int > MicVarMap
Definition: ERF_SAM.H:290
+
amrex::TableData< amrex::Real, 1 > qv1d
Definition: ERF_SAM.H:343
+
amrex::Real m_fac_cond
Definition: ERF_SAM.H:311
+
amrex::TableData< amrex::Real, 1 > accrsi
Definition: ERF_SAM.H:326
+
amrex::TableData< amrex::Real, 1 > accrrc
Definition: ERF_SAM.H:325
+
bool docloud
Definition: ERF_SAM.H:308
void Compute_Coefficients()
Definition: ERF_Init_SAM.cpp:140
-
amrex::TableData< amrex::Real, 1 > pres1d
Definition: ERF_SAM.H:335
-
int nlev
Definition: ERF_SAM.H:297
-
int m_qstate_size
Definition: ERF_SAM.H:282
-
amrex::Geometry m_geom
Definition: ERF_SAM.H:288
-
amrex::TableData< amrex::Real, 1 > evapr1
Definition: ERF_SAM.H:330
-
amrex::Real m_fac_sub
Definition: ERF_SAM.H:308
-
amrex::TableData< amrex::Real, 1 > evaps2
Definition: ERF_SAM.H:325
+
amrex::TableData< amrex::Real, 1 > pres1d
Definition: ERF_SAM.H:340
+
int nlev
Definition: ERF_SAM.H:302
+
int m_qstate_size
Definition: ERF_SAM.H:287
+
amrex::Geometry m_geom
Definition: ERF_SAM.H:293
+
amrex::TableData< amrex::Real, 1 > evapr1
Definition: ERF_SAM.H:335
+
amrex::Real m_fac_sub
Definition: ERF_SAM.H:313
+
amrex::TableData< amrex::Real, 1 > evaps2
Definition: ERF_SAM.H:330
void Init(const amrex::MultiFab &cons_in, const amrex::BoxArray &grids, const amrex::Geometry &geom, const amrex::Real &dt_advance, std::unique_ptr< amrex::MultiFab > &z_phys_nd, std::unique_ptr< amrex::MultiFab > &detJ_cc) override
Definition: ERF_Init_SAM.cpp:22
-
amrex::TableData< amrex::Real, 1 > qn1d
Definition: ERF_SAM.H:339
-
amrex::TableData< amrex::Real, 1 > accrgc
Definition: ERF_SAM.H:327
-
amrex::TableData< amrex::Real, 1 > accrsc
Definition: ERF_SAM.H:322
-
amrex::TableData< amrex::Real, 1 > qt1d
Definition: ERF_SAM.H:337
-
amrex::TableData< amrex::Real, 1 > coefice
Definition: ERF_SAM.H:323
-
int zhi
Definition: ERF_SAM.H:297
+
amrex::TableData< amrex::Real, 1 > qn1d
Definition: ERF_SAM.H:344
+
amrex::TableData< amrex::Real, 1 > accrgc
Definition: ERF_SAM.H:332
+
amrex::TableData< amrex::Real, 1 > accrsc
Definition: ERF_SAM.H:327
+
amrex::TableData< amrex::Real, 1 > qt1d
Definition: ERF_SAM.H:342
+
amrex::TableData< amrex::Real, 1 > coefice
Definition: ERF_SAM.H:328
+
int zhi
Definition: ERF_SAM.H:302
void Define(SolverChoice &sc) override
Definition: ERF_SAM.H:79
int Qstate_Size() override
Definition: ERF_SAM.H:148
+
void Qmoist_Restart_Vars(const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
Definition: ERF_SAM.H:267
int Qmoist_Size() override
Definition: ERF_SAM.H:145
void PrecipFall(const SolverChoice &sc)
Definition: ERF_PrecipFall.cpp:15
void Update_State_Vars(amrex::MultiFab &cons_in) override
Definition: ERF_SAM.H:116
-
amrex::TableData< amrex::Real, 1 > tabs1d
Definition: ERF_SAM.H:336
-
amrex::TableData< amrex::Real, 1 > gamaz
Definition: ERF_SAM.H:341
+
amrex::TableData< amrex::Real, 1 > tabs1d
Definition: ERF_SAM.H:341
+
amrex::TableData< amrex::Real, 1 > gamaz
Definition: ERF_SAM.H:346
amrex::MultiFab * Qmoist_Ptr(const int &varIdx) override
Definition: ERF_SAM.H:135
-
amrex::Real dt
Definition: ERF_SAM.H:294
+
amrex::Real dt
Definition: ERF_SAM.H:299
Definition: ERF_SAM.H:27
@ NumVars
Definition: ERF_SAM.H:50
@ pres
Definition: ERF_SAM.H:33
@@ -527,11 +532,12 @@
@ qps
Definition: ERF_SAM.H:43
@ qp
Definition: ERF_SAM.H:41
Definition: ERF_DataStruct.H:78
-
amrex::Real rdOcp
Definition: ERF_DataStruct.H:581
-
amrex::Real c_p
Definition: ERF_DataStruct.H:580
-
bool do_precip
Definition: ERF_DataStruct.H:641
-
bool do_cloud
Definition: ERF_DataStruct.H:640
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
amrex::Real rdOcp
Definition: ERF_DataStruct.H:580
+
amrex::Real c_p
Definition: ERF_DataStruct.H:579
+
bool do_precip
Definition: ERF_DataStruct.H:640
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
bool do_cloud
Definition: ERF_DataStruct.H:639
+
int ave_plane
Definition: ERF_DataStruct.H:637
diff --git a/ERF__make__buoyancy_8cpp.html b/ERF__make__buoyancy_8cpp.html index 480895f2f..289ee45fb 100644 --- a/ERF__make__buoyancy_8cpp.html +++ b/ERF__make__buoyancy_8cpp.html @@ -637,11 +637,11 @@

#define PrimQ3_comp
Definition: ERF_IndexDefines.H:57
Definition: ERF_PlaneAverage.H:14
@ cons
Definition: ERF_IndexDefines.H:131
-
amrex::Real rdOcp
Definition: ERF_DataStruct.H:581
-
amrex::Real gravity
Definition: ERF_DataStruct.H:579
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
-
int buoyancy_type
Definition: ERF_DataStruct.H:560
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
amrex::Real rdOcp
Definition: ERF_DataStruct.H:580
+
amrex::Real gravity
Definition: ERF_DataStruct.H:578
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
int buoyancy_type
Definition: ERF_DataStruct.H:559
+
int ave_plane
Definition: ERF_DataStruct.H:637

Referenced by make_mom_sources().

diff --git a/ERF__make__mom__sources_8cpp.html b/ERF__make__mom__sources_8cpp.html index 2e61618cc..1e10b55df 100644 --- a/ERF__make__mom__sources_8cpp.html +++ b/ERF__make__mom__sources_8cpp.html @@ -770,27 +770,27 @@

amrex::Vector< amrex::Real > input_sounding_time
Definition: ERF_InputSoundingData.H:315

amrex::Real tau_nudging
Definition: ERF_InputSoundingData.H:312
amrex::Vector< amrex::Gpu::DeviceVector< amrex::Real > > U_inp_sound_d
Definition: ERF_InputSoundingData.H:326
-
bool use_terrain
Definition: ERF_DataStruct.H:558
-
amrex::Real coriolis_factor
Definition: ERF_DataStruct.H:591
-
bool rayleigh_damp_V
Definition: ERF_DataStruct.H:568
-
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:572
-
amrex::Real cosphi
Definition: ERF_DataStruct.H:592
-
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_geo_forcing
Definition: ERF_DataStruct.H:634
-
bool custom_w_subsidence
Definition: ERF_DataStruct.H:598
-
bool nudging_from_input_sounding
Definition: ERF_DataStruct.H:604
-
bool rayleigh_damp_U
Definition: ERF_DataStruct.H:567
-
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:573
-
amrex::Real sinphi
Definition: ERF_DataStruct.H:593
-
bool have_geo_wind_profile
Definition: ERF_DataStruct.H:636
-
amrex::Real NumDiffCoeff
Definition: ERF_DataStruct.H:620
-
bool use_coriolis
Definition: ERF_DataStruct.H:564
-
bool use_NumDiff
Definition: ERF_DataStruct.H:619
-
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:548
-
bool custom_forcing_prim_vars
Definition: ERF_DataStruct.H:600
-
bool rayleigh_damp_W
Definition: ERF_DataStruct.H:569
-
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:539
-
amrex::Real rayleigh_dampcoef
Definition: ERF_DataStruct.H:571
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
bool use_terrain
Definition: ERF_DataStruct.H:557
+
amrex::Real coriolis_factor
Definition: ERF_DataStruct.H:590
+
bool rayleigh_damp_V
Definition: ERF_DataStruct.H:567
+
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:571
+
amrex::Real cosphi
Definition: ERF_DataStruct.H:591
+
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_geo_forcing
Definition: ERF_DataStruct.H:633
+
bool custom_w_subsidence
Definition: ERF_DataStruct.H:597
+
bool nudging_from_input_sounding
Definition: ERF_DataStruct.H:603
+
bool rayleigh_damp_U
Definition: ERF_DataStruct.H:566
+
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:572
+
amrex::Real sinphi
Definition: ERF_DataStruct.H:592
+
bool have_geo_wind_profile
Definition: ERF_DataStruct.H:635
+
amrex::Real NumDiffCoeff
Definition: ERF_DataStruct.H:619
+
bool use_coriolis
Definition: ERF_DataStruct.H:563
+
bool use_NumDiff
Definition: ERF_DataStruct.H:618
+
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:547
+
bool custom_forcing_prim_vars
Definition: ERF_DataStruct.H:599
+
bool rayleigh_damp_W
Definition: ERF_DataStruct.H:568
+
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:538
+
amrex::Real rayleigh_dampcoef
Definition: ERF_DataStruct.H:570
+
int ave_plane
Definition: ERF_DataStruct.H:637
std::string sponge_type
Definition: ERF_SpongeStruct.H:61
Here is the call graph for this function:
diff --git a/ERF__make__sources_8cpp.html b/ERF__make__sources_8cpp.html index 68d6a9302..73447846f 100644 --- a/ERF__make__sources_8cpp.html +++ b/ERF__make__sources_8cpp.html @@ -691,23 +691,23 @@

amrex::Vector< amrex::Gpu::DeviceVector< amrex::Real > > theta_inp_sound_d
Definition: ERF_InputSoundingData.H:326
amrex::Vector< amrex::Real > input_sounding_time
Definition: ERF_InputSoundingData.H:315
amrex::Real tau_nudging
Definition: ERF_InputSoundingData.H:312
-
bool use_terrain
Definition: ERF_DataStruct.H:558
-
bool rayleigh_damp_T
Definition: ERF_DataStruct.H:570
-
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:572
-
bool custom_rhotheta_forcing
Definition: ERF_DataStruct.H:596
-
bool custom_w_subsidence
Definition: ERF_DataStruct.H:598
-
bool nudging_from_input_sounding
Definition: ERF_DataStruct.H:604
-
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:573
-
amrex::Real NumDiffCoeff
Definition: ERF_DataStruct.H:620
-
bool use_NumDiff
Definition: ERF_DataStruct.H:619
-
bool custom_moisture_forcing
Definition: ERF_DataStruct.H:597
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
-
bool custom_forcing_prim_vars
Definition: ERF_DataStruct.H:600
-
PerturbationType pert_type
Definition: ERF_DataStruct.H:616
-
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:539
-
amrex::Real rayleigh_dampcoef
Definition: ERF_DataStruct.H:571
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
bool use_terrain
Definition: ERF_DataStruct.H:557
+
bool rayleigh_damp_T
Definition: ERF_DataStruct.H:569
+
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:571
+
bool custom_rhotheta_forcing
Definition: ERF_DataStruct.H:595
+
bool custom_w_subsidence
Definition: ERF_DataStruct.H:597
+
bool nudging_from_input_sounding
Definition: ERF_DataStruct.H:603
+
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:572
+
amrex::Real NumDiffCoeff
Definition: ERF_DataStruct.H:619
+
bool use_NumDiff
Definition: ERF_DataStruct.H:618
+
bool custom_moisture_forcing
Definition: ERF_DataStruct.H:596
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
bool custom_forcing_prim_vars
Definition: ERF_DataStruct.H:599
+
PerturbationType pert_type
Definition: ERF_DataStruct.H:615
+
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:538
+
amrex::Real rayleigh_dampcoef
Definition: ERF_DataStruct.H:570
+
int ave_plane
Definition: ERF_DataStruct.H:637
std::string sponge_type
Definition: ERF_SpongeStruct.H:61
Definition: ERF_TurbStruct.H:29
bool use_QKE
Definition: ERF_TurbStruct.H:206
diff --git a/ERF__make__tau__terms_8cpp.html b/ERF__make__tau__terms_8cpp.html index fc9ad5f41..53b568a9d 100644 --- a/ERF__make__tau__terms_8cpp.html +++ b/ERF__make__tau__terms_8cpp.html @@ -752,12 +752,12 @@

amrex::Real rho0_trans
Definition: ERF_DiffStruct.H:83
amrex::Real dynamicViscosity
Definition: ERF_DiffStruct.H:88
MolecDiffType molec_diff_type
Definition: ERF_DiffStruct.H:76
-
bool use_terrain
Definition: ERF_DataStruct.H:558
-
bool use_explicit_most
Definition: ERF_DataStruct.H:607
-
DiffChoice diffChoice
Definition: ERF_DataStruct.H:538
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
-
TerrainType terrain_type
Definition: ERF_DataStruct.H:626
-
bool use_rotate_most
Definition: ERF_DataStruct.H:610
+
bool use_terrain
Definition: ERF_DataStruct.H:557
+
bool use_explicit_most
Definition: ERF_DataStruct.H:606
+
DiffChoice diffChoice
Definition: ERF_DataStruct.H:537
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
+
TerrainType terrain_type
Definition: ERF_DataStruct.H:625
+
bool use_rotate_most
Definition: ERF_DataStruct.H:609
Definition: ERF_TurbStruct.H:29
PBLType pbl_type
Definition: ERF_TurbStruct.H:192
LESType les_type
Definition: ERF_TurbStruct.H:169
diff --git a/ERF__slow__rhs__post_8cpp.html b/ERF__slow__rhs__post_8cpp.html index 112619e18..26e84dfd4 100644 --- a/ERF__slow__rhs__post_8cpp.html +++ b/ERF__slow__rhs__post_8cpp.html @@ -939,18 +939,18 @@

amrex::Real dryscal_horiz_upw_frac
Definition: ERF_AdvStruct.H:293
Definition: ERF_DiffStruct.H:19
MolecDiffType molec_diff_type
Definition: ERF_DiffStruct.H:76
-
bool use_terrain
Definition: ERF_DataStruct.H:558
-
bool use_explicit_most
Definition: ERF_DataStruct.H:607
-
bool use_mono_adv
Definition: ERF_DataStruct.H:623
-
DiffChoice diffChoice
Definition: ERF_DataStruct.H:538
-
amrex::Real gravity
Definition: ERF_DataStruct.H:579
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
-
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:548
-
AdvChoice advChoice
Definition: ERF_DataStruct.H:537
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
-
TerrainType terrain_type
Definition: ERF_DataStruct.H:626
-
bool use_rotate_most
Definition: ERF_DataStruct.H:610
-
CouplingType coupling_type
Definition: ERF_DataStruct.H:625
+
bool use_terrain
Definition: ERF_DataStruct.H:557
+
bool use_explicit_most
Definition: ERF_DataStruct.H:606
+
bool use_mono_adv
Definition: ERF_DataStruct.H:622
+
DiffChoice diffChoice
Definition: ERF_DataStruct.H:537
+
amrex::Real gravity
Definition: ERF_DataStruct.H:578
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
+
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:547
+
AdvChoice advChoice
Definition: ERF_DataStruct.H:536
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
TerrainType terrain_type
Definition: ERF_DataStruct.H:625
+
bool use_rotate_most
Definition: ERF_DataStruct.H:609
+
CouplingType coupling_type
Definition: ERF_DataStruct.H:624
Definition: ERF_TurbStruct.H:29
bool advect_QKE
Definition: ERF_TurbStruct.H:208
PBLType pbl_type
Definition: ERF_TurbStruct.H:192
diff --git a/ERF__slow__rhs__pre_8cpp.html b/ERF__slow__rhs__pre_8cpp.html index c86c25ac1..1737e8c81 100644 --- a/ERF__slow__rhs__pre_8cpp.html +++ b/ERF__slow__rhs__pre_8cpp.html @@ -1243,20 +1243,20 @@

amrex::Real dycore_horiz_upw_frac
Definition: ERF_AdvStruct.H:291
Definition: ERF_DiffStruct.H:19
MolecDiffType molec_diff_type
Definition: ERF_DiffStruct.H:76
-
bool use_terrain
Definition: ERF_DataStruct.H:558
-
bool use_explicit_most
Definition: ERF_DataStruct.H:607
-
bool use_mono_adv
Definition: ERF_DataStruct.H:623
-
DiffChoice diffChoice
Definition: ERF_DataStruct.H:538
-
amrex::Real gravity
Definition: ERF_DataStruct.H:579
-
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_pressure_grad
Definition: ERF_DataStruct.H:633
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
-
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:548
-
int constant_density
Definition: ERF_DataStruct.H:550
-
AdvChoice advChoice
Definition: ERF_DataStruct.H:537
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
-
TerrainType terrain_type
Definition: ERF_DataStruct.H:626
-
bool use_rotate_most
Definition: ERF_DataStruct.H:610
-
CouplingType coupling_type
Definition: ERF_DataStruct.H:625
+
bool use_terrain
Definition: ERF_DataStruct.H:557
+
bool use_explicit_most
Definition: ERF_DataStruct.H:606
+
bool use_mono_adv
Definition: ERF_DataStruct.H:622
+
DiffChoice diffChoice
Definition: ERF_DataStruct.H:537
+
amrex::Real gravity
Definition: ERF_DataStruct.H:578
+
amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_pressure_grad
Definition: ERF_DataStruct.H:632
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
+
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:547
+
int constant_density
Definition: ERF_DataStruct.H:549
+
AdvChoice advChoice
Definition: ERF_DataStruct.H:536
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
TerrainType terrain_type
Definition: ERF_DataStruct.H:625
+
bool use_rotate_most
Definition: ERF_DataStruct.H:609
+
CouplingType coupling_type
Definition: ERF_DataStruct.H:624
Definition: ERF_TurbStruct.H:29
PBLType pbl_type
Definition: ERF_TurbStruct.H:192
LESType les_type
Definition: ERF_TurbStruct.H:169
diff --git a/classERF.html b/classERF.html index dcc295675..4230cea60 100644 --- a/classERF.html +++ b/classERF.html @@ -1294,12 +1294,12 @@

@ cons
Definition: ERF_IndexDefines.H:121
@ zvel
Definition: ERF_IndexDefines.H:124
@ yvel
Definition: ERF_IndexDefines.H:123
-
int RhoQr_comp
Definition: ERF_DataStruct.H:649
-
int RhoQv_comp
Definition: ERF_DataStruct.H:643
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
-
PerturbationType pert_type
Definition: ERF_DataStruct.H:616
-
WindFarmType windfarm_type
Definition: ERF_DataStruct.H:628
-
bool time_avg_vel
Definition: ERF_DataStruct.H:613
+
int RhoQr_comp
Definition: ERF_DataStruct.H:648
+
int RhoQv_comp
Definition: ERF_DataStruct.H:642
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626
+
PerturbationType pert_type
Definition: ERF_DataStruct.H:615
+
WindFarmType windfarm_type
Definition: ERF_DataStruct.H:627
+
bool time_avg_vel
Definition: ERF_DataStruct.H:612
void calc_tpi_update(const int lev, const amrex::Real dt, amrex::MultiFab &mf_xvel, amrex::MultiFab &mf_yvel, amrex::MultiFab &mf_cons)
Definition: ERF_TurbPertStruct.H:184
amrex::MultiFab pb_cell
Definition: ERF_TurbPertStruct.H:536
void apply_tpi(const int &lev, const amrex::Box &vbx, const int &comp, const amrex::IndexType &m_ixtype, const amrex::Array4< amrex::Real > &src_arr, const amrex::Array4< amrex::Real const > &pert_cell)
Definition: ERF_TurbPertStruct.H:245
@@ -1783,21 +1783,21 @@

void set_slow_rhs_post(std::function< void(T &, T &, T &, T &, T &, const amrex::Real, const amrex::Real, const amrex::Real, const int)> F)
Definition: ERF_MRI.H:145
Definition: ERF_DiffStruct.H:19
MolecDiffType molec_diff_type
Definition: ERF_DiffStruct.H:76
-
bool use_terrain
Definition: ERF_DataStruct.H:558
-
bool rayleigh_damp_T
Definition: ERF_DataStruct.H:570
-
bool use_explicit_most
Definition: ERF_DataStruct.H:607
-
bool rayleigh_damp_V
Definition: ERF_DataStruct.H:568
-
DiffChoice diffChoice
Definition: ERF_DataStruct.H:538
-
bool custom_rhotheta_forcing
Definition: ERF_DataStruct.H:596
-
bool custom_w_subsidence
Definition: ERF_DataStruct.H:598
-
bool rayleigh_damp_U
Definition: ERF_DataStruct.H:567
-
bool custom_geostrophic_profile
Definition: ERF_DataStruct.H:599
-
bool use_NumDiff
Definition: ERF_DataStruct.H:619
-
bool custom_moisture_forcing
Definition: ERF_DataStruct.H:597
-
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:540
-
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:548
-
bool rayleigh_damp_W
Definition: ERF_DataStruct.H:569
-
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:539
+
bool use_terrain
Definition: ERF_DataStruct.H:557
+
bool rayleigh_damp_T
Definition: ERF_DataStruct.H:569
+
bool use_explicit_most
Definition: ERF_DataStruct.H:606
+
bool rayleigh_damp_V
Definition: ERF_DataStruct.H:567
+
DiffChoice diffChoice
Definition: ERF_DataStruct.H:537
+
bool custom_rhotheta_forcing
Definition: ERF_DataStruct.H:595
+
bool custom_w_subsidence
Definition: ERF_DataStruct.H:597
+
bool rayleigh_damp_U
Definition: ERF_DataStruct.H:566
+
bool custom_geostrophic_profile
Definition: ERF_DataStruct.H:598
+
bool use_NumDiff
Definition: ERF_DataStruct.H:618
+
bool custom_moisture_forcing
Definition: ERF_DataStruct.H:596
+
amrex::Vector< TurbChoice > turbChoice
Definition: ERF_DataStruct.H:539
+
amrex::Vector< int > anelastic
Definition: ERF_DataStruct.H:547
+
bool rayleigh_damp_W
Definition: ERF_DataStruct.H:568
+
SpongeChoice spongeChoice
Definition: ERF_DataStruct.H:538
Definition: ERF_SpongeStruct.H:15
std::string sponge_type
Definition: ERF_SpongeStruct.H:61
Definition: ERF_TurbStruct.H:29
@@ -1885,7 +1885,7 @@

12 }
LandSurface lsm
Definition: ERF.H:716
void Advance(const int &lev, const amrex::Real &dt_advance)
Definition: ERF_LandSurface.H:47
-
LandSurfaceType lsm_type
Definition: ERF_DataStruct.H:630
+
LandSurfaceType lsm_type
Definition: ERF_DataStruct.H:629
@@ -2066,7 +2066,7 @@

1831  }
1832 }
void AverageDownTo(int crse_lev, int scomp, int ncomp)
Definition: ERF.cpp:1836
-
CouplingType coupling_type
Definition: ERF_DataStruct.H:625
+
CouplingType coupling_type
Definition: ERF_DataStruct.H:624
@@ -4391,8 +4391,8 @@

constexpr amrex::Real p_0
Definition: ERF_Constants.H:18
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real getExnergivenP(const amrex::Real P, const amrex::Real rdOcp)
Definition: ERF_EOS.H:117
@ pres
Definition: ERF_Kessler.H:33
-
amrex::Real rdOcp
Definition: ERF_DataStruct.H:581
-
amrex::Real gravity
Definition: ERF_DataStruct.H:579
+
amrex::Real rdOcp
Definition: ERF_DataStruct.H:580
+
amrex::Real gravity
Definition: ERF_DataStruct.H:578
Here is the call graph for this function:
@@ -4710,9 +4710,9 @@

void initializeMicrophysics(const int &)
Definition: ERF.cpp:1211

void ReSize(const int &nlev)
Definition: ERF_LandSurface.H:19
const char * buildInfoGetGitHash(int i)
-
amrex::Real dz0
Definition: ERF_DataStruct.H:586
-
amrex::Real grid_stretching_ratio
Definition: ERF_DataStruct.H:584
-
amrex::Real zsurf
Definition: ERF_DataStruct.H:585
+
amrex::Real dz0
Definition: ERF_DataStruct.H:585
+
amrex::Real grid_stretching_ratio
Definition: ERF_DataStruct.H:583
+
amrex::Real zsurf
Definition: ERF_DataStruct.H:584
Here is the call graph for this function:
@@ -5104,8 +5104,8 @@

amrex::Vector< amrex::Real > fixed_fast_dt
Definition: ERF.H:851

static amrex::Real cfl
Definition: ERF.H:845
@ rho
Definition: ERF_Kessler.H:30
-
int force_stage1_single_substep
Definition: ERF_DataStruct.H:545
-
amrex::Vector< SubsteppingType > substepping_type
Definition: ERF_DataStruct.H:547
+
int force_stage1_single_substep
Definition: ERF_DataStruct.H:544
+
amrex::Vector< SubsteppingType > substepping_type
Definition: ERF_DataStruct.H:546
Here is the call graph for this function:
@@ -8006,7 +8006,7 @@

amrex::Vector< amrex::IntVect > zero_yflux
Definition: ERF_AdvStruct.H:300

amrex::Vector< amrex::IntVect > zero_xflux
Definition: ERF_AdvStruct.H:299
amrex::Vector< amrex::IntVect > zero_zflux
Definition: ERF_AdvStruct.H:301
-
AdvChoice advChoice
Definition: ERF_DataStruct.H:537
+
AdvChoice advChoice
Definition: ERF_DataStruct.H:536
@@ -8150,7 +8150,7 @@

void init_uniform(int lev)
Definition: ERF_init_uniform.cpp:17
static std::string init_type
Definition: ERF.H:958
void turbPert_amplitude(const int lev)
Definition: ERF_init_TurbPert.cpp:44
-
bool use_gravity
Definition: ERF_DataStruct.H:563
+
bool use_gravity
Definition: ERF_DataStruct.H:562
@@ -8541,8 +8541,8 @@

348 }
#define NDRY
Definition: ERF_IndexDefines.H:13
static AMREX_FORCE_INLINE int ComputeGhostCells(const AdvChoice &advChoice, bool use_num_diff)
Definition: ERF.H:1069
-
bool test_mapfactor
Definition: ERF_DataStruct.H:556
-
TerrainType terrain_type
Definition: ERF_DataStruct.H:626
+
bool test_mapfactor
Definition: ERF_DataStruct.H:555
+
TerrainType terrain_type
Definition: ERF_DataStruct.H:625
void init_tpi(const int lev, const amrex::IntVect &nx, const amrex::GpuArray< amrex::Real, 3 > dx, const amrex::BoxArray &ba, const amrex::DistributionMapping &dm, const int ngrow_state)
Definition: ERF_TurbPertStruct.H:29
@@ -9350,10 +9350,10 @@

amrex::Vector< amrex::IntVect > samplepoint
Definition: ERF.H:1260
void setRecordSamplePointInfo(int i, int lev, amrex::IntVect &cell, const std::string &filename)
Definition: ERF.H:1221
static MoistureModelType modelType(const MoistureType a_moisture_type)
query if a specified moisture model is Eulerian or Lagrangian
Definition: ERF_Microphysics.H:64
-
bool have_geo_wind_profile
Definition: ERF_DataStruct.H:636
-
bool project_initial_velocity
Definition: ERF_DataStruct.H:588
-
std::string abl_geo_wind_table
Definition: ERF_DataStruct.H:635
-
bool use_rotate_most
Definition: ERF_DataStruct.H:610
+
bool have_geo_wind_profile
Definition: ERF_DataStruct.H:635
+
bool project_initial_velocity
Definition: ERF_DataStruct.H:587
+
std::string abl_geo_wind_table
Definition: ERF_DataStruct.H:634
+
bool use_rotate_most
Definition: ERF_DataStruct.H:609
void debug(amrex::Real)
Definition: ERF_TurbPertStruct.H:508
Here is the call graph for this function:
@@ -9593,7 +9593,7 @@

void ChopGrids2D(BoxArray &ba, const Box &domain, int target_size)
Definition: ERF_ChopGrids.cpp:21
void erf_enforce_hse(int lev, amrex::MultiFab &dens, amrex::MultiFab &pres, amrex::MultiFab &pi, std::unique_ptr< amrex::MultiFab > &z_cc)
Definition: ERF_init1d.cpp:149
@ base_bc
Definition: ERF_IndexDefines.H:79
-
bool use_moist_background
Definition: ERF_DataStruct.H:642
+
bool use_moist_background
Definition: ERF_DataStruct.H:641
Here is the call graph for this function:
@@ -9850,8 +9850,8 @@

44  }

45 }
amrex::Vector< amrex::Vector< amrex::Vector< amrex::Real > > > h_rayleigh_ptrs
Definition: ERF.H:1025
-
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:572
-
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:573
+
amrex::Real rayleigh_zdamp
Definition: ERF_DataStruct.H:571
+
amrex::Real rayleigh_ztop
Definition: ERF_DataStruct.H:572
@@ -11793,8 +11793,8 @@

static bool use_heffte
Definition: ERF.H:947
amrex::Real volWgtSumMF(int lev, const amrex::MultiFab &mf, int comp, const amrex::MultiFab &mapfac, bool local, bool finemask)
Definition: ERF_WriteScalarProfiles.cpp:378
void solve_with_heffte(int lev, amrex::MultiFab &rhs, amrex::MultiFab &soln, amrex::Array< amrex::MultiFab, AMREX_SPACEDIM > &fluxes)
-
amrex::Real poisson_reltol
Definition: ERF_DataStruct.H:554
-
amrex::Real poisson_abstol
Definition: ERF_DataStruct.H:553
+
amrex::Real poisson_reltol
Definition: ERF_DataStruct.H:553
+
amrex::Real poisson_abstol
Definition: ERF_DataStruct.H:552
Here is the call graph for this function:
@@ -12090,7 +12090,7 @@

258 #endif

259 }
AMREX_GPU_HOST AMREX_FORCE_INLINE void ApplyInvertedMask(amrex::MultiFab &dst, const amrex::iMultiFab &imask, const int nghost=0)
Definition: ERF_Utils.H:384
-
int ncorr
Definition: ERF_DataStruct.H:552
+
int ncorr
Definition: ERF_DataStruct.H:551
Here is the call graph for this function:
@@ -12287,7 +12287,7 @@

397  // Read in the moisture model restart variables

398  std::vector<int> qmoist_indices(0);
399  std::vector<std::string> qmoist_names(0);
-
400  micro->Get_Qmoist_Restart_Vars(lev, qmoist_indices, qmoist_names);
+
400  micro->Get_Qmoist_Restart_Vars(lev, solverChoice, qmoist_indices, qmoist_names);
401  int qmoist_nvar = qmoist_indices.size();
402  for (int var = 0; var < qmoist_nvar; var++) {
403  ng = qmoist[lev][qmoist_indices[var]]->nGrowVect();
@@ -12744,9 +12744,9 @@

Definition: ERF_MM5.H:26
Definition: ERF_NullSurf.H:8
Definition: ERF_SLM.H:26
-
std::string pp_prefix
Definition: ERF_DataStruct.H:543
+
std::string pp_prefix
Definition: ERF_DataStruct.H:542
void init_params(int max_level)
Definition: ERF_DataStruct.H:80
-
void display(int max_level)
Definition: ERF_DataStruct.H:417
+
void display(int max_level)
Definition: ERF_DataStruct.H:416
Here is the call graph for this function:
@@ -15726,7 +15726,7 @@

148  // Write the moisture model restart variables

149  std::vector<int> qmoist_indices(0);
150  std::vector<std::string> qmoist_names(0);
-
151  micro->Get_Qmoist_Restart_Vars(lev, qmoist_indices, qmoist_names);
+
151  micro->Get_Qmoist_Restart_Vars(lev, solverChoice, qmoist_indices, qmoist_names);
152  int qmoist_nvar = qmoist_indices.size();
153  for (int var = 0; var < qmoist_nvar; var++) {
154  ng = qmoist[lev][qmoist_indices[var]]->nGrowVect();
diff --git a/classEulerianMicrophysics-members.html b/classEulerianMicrophysics-members.html index 43ea66a1c..207978a93 100644 --- a/classEulerianMicrophysics-members.html +++ b/classEulerianMicrophysics-members.html @@ -94,7 +94,7 @@ EulerianMicrophysics()EulerianMicrophysicsinline EulerianMicrophysics(const int &nlev, const MoistureType &a_model_type)EulerianMicrophysicsinline Get_Qmoist_Ptr(const int &lev, const int &varIdx) overrideEulerianMicrophysicsinlinevirtual - Get_Qmoist_Restart_Vars(const int a_lev, std::vector< int > &a_idx, std::vector< std::string > &a_names) const overrideEulerianMicrophysicsinlinevirtual + Get_Qmoist_Restart_Vars(const int a_lev, const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const overrideEulerianMicrophysicsinlinevirtual Get_Qmoist_Size(const int &) overrideEulerianMicrophysicsinlinevirtual Get_Qstate_Size() overrideEulerianMicrophysicsinlinevirtual Init(const int &lev, const amrex::MultiFab &cons_in, const amrex::BoxArray &grids, const amrex::Geometry &geom, const amrex::Real &dt_advance, std::unique_ptr< amrex::MultiFab > &z_phys_nd, std::unique_ptr< amrex::MultiFab > &detJ_cc) overrideEulerianMicrophysicsinlinevirtual diff --git a/classEulerianMicrophysics.html b/classEulerianMicrophysics.html index 933fbee7d..0ce2f6fad 100644 --- a/classEulerianMicrophysics.html +++ b/classEulerianMicrophysics.html @@ -151,9 +151,9 @@ int Get_Qstate_Size () override  get the number of moisture-model-related conserved state variables More...
  -void Get_Qmoist_Restart_Vars (const int a_lev, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override - get the indices and names of moisture model variables for restart at a given level More...
-  +void Get_Qmoist_Restart_Vars (const int a_lev, const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override + get the indices and names of moisture model variables for restart at a given level More...
- Public Member Functions inherited from Microphysics  Microphysics ()  Null constructor. More...
@@ -300,7 +300,7 @@

43  amrex::Abort("EulerianMicrophysics: Dont know this moisture_type!") ;
44  }
45  }
-
amrex::Vector< std::unique_ptr< NullMoist > > m_moist_model
Definition: ERF_EulerianMicrophysics.H:133
+
amrex::Vector< std::unique_ptr< NullMoist > > m_moist_model
Definition: ERF_EulerianMicrophysics.H:134
static MoistureModelType modelType(const MoistureType a_moisture_type)
query if a specified moisture model is Eulerian or Lagrangian
Definition: ERF_Microphysics.H:64
Here is the call graph for this function:
@@ -496,8 +496,8 @@

-

◆ Get_Qmoist_Restart_Vars()

+ +

◆ Get_Qmoist_Restart_Vars()

@@ -511,6 +511,12 @@

const int  a_lev, + + + + const SolverChoice &  + a_sc, + @@ -540,16 +546,17 @@

Parameters
+
a_levlevel
a_scSolver choice object
a_idxindices
a_namesnames
-

Implements Microphysics.

-
117  {
-
118  m_moist_model[a_lev]->Qmoist_Restart_Vars( a_idx, a_names );
-
119  }
+

Implements Microphysics.

+
118  {
+
119  m_moist_model[a_lev]->Qmoist_Restart_Vars( a_sc, a_idx, a_names );
+
120  }

@@ -728,11 +735,11 @@

Create and set the specified moisture model.

-
126  {
-
127  for (int lev(0); lev<m_moist_model.size(); ++lev) {
-
128  m_moist_model[lev] = std::make_unique<NewMoistModel>();
-
129  }
-
130  }
+
127  {
+
128  for (int lev(0); lev<m_moist_model.size(); ++lev) {
+
129  m_moist_model[lev] = std::make_unique<NewMoistModel>();
+
130  }
+
131  }

@@ -857,7 +864,7 @@

moisture model

-

Referenced by Advance(), Define(), EulerianMicrophysics(), Get_Qmoist_Ptr(), Get_Qmoist_Restart_Vars(), Get_Qmoist_Size(), Get_Qstate_Size(), Init(), SetModel(), Update_Micro_Vars_Lev(), and Update_State_Vars_Lev().

+

Referenced by Advance(), Define(), EulerianMicrophysics(), Get_Qmoist_Ptr(), Get_Qmoist_Restart_Vars(), Get_Qmoist_Size(), Get_Qstate_Size(), Init(), SetModel(), Update_Micro_Vars_Lev(), and Update_State_Vars_Lev().

diff --git a/classEulerianMicrophysics.js b/classEulerianMicrophysics.js index 315ce1923..b5e9611cf 100644 --- a/classEulerianMicrophysics.js +++ b/classEulerianMicrophysics.js @@ -6,7 +6,7 @@ var classEulerianMicrophysics = [ "Advance", "classEulerianMicrophysics.html#a6cc7efaa2f4f27f8a7f485fd96e5635b", null ], [ "Define", "classEulerianMicrophysics.html#a444c916c5bb1167ea1efc9f2b9595436", null ], [ "Get_Qmoist_Ptr", "classEulerianMicrophysics.html#a416981f230a126387b9a664a5a241e9c", null ], - [ "Get_Qmoist_Restart_Vars", "classEulerianMicrophysics.html#a23d6676d025a0129cf4ed73d887605bf", null ], + [ "Get_Qmoist_Restart_Vars", "classEulerianMicrophysics.html#a0bf4ba2dccc3aa4f2c462162ad54d1fc", null ], [ "Get_Qmoist_Size", "classEulerianMicrophysics.html#ad4983e19f621a55ad7d942c881215c72", null ], [ "Get_Qstate_Size", "classEulerianMicrophysics.html#a3e973738b4e0bbaa7269ab2395322929", null ], [ "Init", "classEulerianMicrophysics.html#ac68028f2920ccb380c605099adb7d604", null ], diff --git a/classKessler-members.html b/classKessler-members.html index ef9806efc..07c8d18c4 100644 --- a/classKessler-members.html +++ b/classKessler-members.html @@ -116,7 +116,7 @@ nlevKesslerprivate NullMoist()NullMoistinline Qmoist_Ptr(const int &varIdx) overrideKesslerinlinevirtual - Qmoist_Restart_Vars(std::vector< int > &a_idx, std::vector< std::string > &a_names) const overrideKesslerinlinevirtual + Qmoist_Restart_Vars(const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const overrideKesslerinlinevirtual Qmoist_Size() overrideKesslerinlinevirtual Qstate_Size() overrideKesslerinlinevirtual Update_Micro_Vars(amrex::MultiFab &cons_in) overrideKesslerinlinevirtual diff --git a/classKessler.html b/classKessler.html index 7f9ae26d6..1c7d6fd06 100644 --- a/classKessler.html +++ b/classKessler.html @@ -148,8 +148,8 @@   int Qstate_Size () override   -void Qmoist_Restart_Vars (std::vector< int > &a_idx, std::vector< std::string > &a_names) const override -  +void Qmoist_Restart_Vars (const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override +  - Public Member Functions inherited from NullMoist  NullMoist ()   @@ -318,7 +318,7 @@

110 
111  this->AdvanceKessler(solverChoice);
112  }
-
amrex::Real dt
Definition: ERF_Kessler.H:153
+
amrex::Real dt
Definition: ERF_Kessler.H:156
void AdvanceKessler(const SolverChoice &solverChoice)
Definition: ERF_Kessler.cpp:11
Here is the call graph for this function:
@@ -597,10 +597,10 @@

constexpr amrex::Real L_v
Definition: ERF_Constants.H:16
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void erf_dtqsatw(amrex::Real t, amrex::Real p, amrex::Real &dtqsatw)
Definition: ERF_Microphysics_Utils.H:139
AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void erf_qsatw(amrex::Real t, amrex::Real p, amrex::Real &qsatw)
Definition: ERF_Microphysics_Utils.H:127
-
amrex::Geometry m_geom
Definition: ERF_Kessler.H:147
-
amrex::MultiFab * m_detJ_cc
Definition: ERF_Kessler.H:172
-
amrex::Real m_fac_cond
Definition: ERF_Kessler.H:165
-
amrex::Array< FabPtr, MicVar_Kess::NumVars > mic_fab_vars
Definition: ERF_Kessler.H:175
+
amrex::Geometry m_geom
Definition: ERF_Kessler.H:150
+
amrex::MultiFab * m_detJ_cc
Definition: ERF_Kessler.H:175
+
amrex::Real m_fac_cond
Definition: ERF_Kessler.H:168
+
amrex::Array< FabPtr, MicVar_Kess::NumVars > mic_fab_vars
Definition: ERF_Kessler.H:178
@ qp
Definition: ERF_Kessler.H:39
@ qcl
Definition: ERF_Kessler.H:37
@ tabs
Definition: ERF_Kessler.H:32
@@ -610,7 +610,7 @@

@ qt
Definition: ERF_Kessler.H:35
@ rain_accum
Definition: ERF_Kessler.H:41
@ qv
Definition: ERF_Kessler.H:36
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626

Referenced by Advance().

@@ -847,16 +847,16 @@

constexpr amrex::Real lsub
Definition: ERF_Constants.H:68

constexpr amrex::Real lcond
Definition: ERF_Constants.H:66
constexpr amrex::Real CONST_GRAV
Definition: ERF_Constants.H:21
-
bool doprecip
Definition: ERF_Kessler.H:162
-
amrex::Real m_fac_sub
Definition: ERF_Kessler.H:167
-
bool docloud
Definition: ERF_Kessler.H:162
-
amrex::Real m_gOcp
Definition: ERF_Kessler.H:168
-
amrex::Real m_fac_fus
Definition: ERF_Kessler.H:166
-
int m_axis
Definition: ERF_Kessler.H:159
-
amrex::Real c_p
Definition: ERF_DataStruct.H:580
-
bool do_precip
Definition: ERF_DataStruct.H:641
-
bool do_cloud
Definition: ERF_DataStruct.H:640
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
bool doprecip
Definition: ERF_Kessler.H:165
+
amrex::Real m_fac_sub
Definition: ERF_Kessler.H:170
+
bool docloud
Definition: ERF_Kessler.H:165
+
amrex::Real m_gOcp
Definition: ERF_Kessler.H:171
+
amrex::Real m_fac_fus
Definition: ERF_Kessler.H:169
+
int m_axis
Definition: ERF_Kessler.H:162
+
amrex::Real c_p
Definition: ERF_DataStruct.H:579
+
bool do_precip
Definition: ERF_DataStruct.H:640
+
bool do_cloud
Definition: ERF_DataStruct.H:639
+
int ave_plane
Definition: ERF_DataStruct.H:637
@@ -963,13 +963,13 @@

56  }
57 }
AMREX_FORCE_INLINE amrex::IntVect TileNoZ()
Definition: ERF_TileNoZ.H:11
-
int zlo
Definition: ERF_Kessler.H:156
-
amrex::Vector< int > MicVarMap
Definition: ERF_Kessler.H:144
-
int zhi
Definition: ERF_Kessler.H:156
-
int nlev
Definition: ERF_Kessler.H:156
-
amrex::MultiFab * m_z_phys_nd
Definition: ERF_Kessler.H:171
-
amrex::BoxArray m_gtoe
Definition: ERF_Kessler.H:150
-
int m_qmoist_size
Definition: ERF_Kessler.H:138
+
int zlo
Definition: ERF_Kessler.H:159
+
amrex::Vector< int > MicVarMap
Definition: ERF_Kessler.H:147
+
int zhi
Definition: ERF_Kessler.H:159
+
int nlev
Definition: ERF_Kessler.H:159
+
amrex::MultiFab * m_z_phys_nd
Definition: ERF_Kessler.H:174
+
amrex::BoxArray m_gtoe
Definition: ERF_Kessler.H:153
+
int m_qmoist_size
Definition: ERF_Kessler.H:141
@ NumVars
Definition: ERF_Kessler.H:42
Here is the call graph for this function:
@@ -1015,8 +1015,8 @@

-

◆ Qmoist_Restart_Vars()

+ +

◆ Qmoist_Restart_Vars()

@@ -1027,6 +1027,12 @@

void Kessler::Qmoist_Restart_Vars ( + const SolverChoice &  + a_sc, + + + + std::vector< int > &  a_idx, @@ -1049,12 +1055,14 @@

-

Reimplemented from NullMoist.

-
130  {
-
131  a_idx.clear();
-
132  a_names.clear();
-
133  a_idx.push_back(4); a_names.push_back("RainAccum");
-
134  }
+

Reimplemented from NullMoist.

+
131  {
+
132  a_idx.clear();
+
133  a_names.clear();
+
134  if (a_sc.moisture_type == MoistureType::Kessler) {
+
135  a_idx.push_back(4); a_names.push_back("RainAccum");
+
136  }
+
137  }

@@ -1111,7 +1119,7 @@

NullMoist.

125 { return Kessler::m_qstate_size; }
-
int m_qstate_size
Definition: ERF_Kessler.H:141
+
int m_qstate_size
Definition: ERF_Kessler.H:144

diff --git a/classKessler.js b/classKessler.js index 886f00037..2f48c3366 100644 --- a/classKessler.js +++ b/classKessler.js @@ -10,7 +10,7 @@ var classKessler = [ "Define", "classKessler.html#a5e989e5755fb57a853e2f1f0ec4c49e8", null ], [ "Init", "classKessler.html#ab1eaffdd038f2eda89f44f150036a405", null ], [ "Qmoist_Ptr", "classKessler.html#a0a84c629a080e71ed93a5f349ad7724a", null ], - [ "Qmoist_Restart_Vars", "classKessler.html#af5909874026a86cf12523779a3761fb3", null ], + [ "Qmoist_Restart_Vars", "classKessler.html#af35573a87c89def1be544055625a7f8b", null ], [ "Qmoist_Size", "classKessler.html#a3925ff722ac968e306dbcc233718030a", null ], [ "Qstate_Size", "classKessler.html#a25a6c3f8cda023e5ea70f1ddd983626c", null ], [ "Update_Micro_Vars", "classKessler.html#a05b9426e9fd6af90ea40aa77ed0cbe66", null ], diff --git a/classMicrophysics-members.html b/classMicrophysics-members.html index de0b3b7a1..73243c892 100644 --- a/classMicrophysics-members.html +++ b/classMicrophysics-members.html @@ -92,7 +92,7 @@ Advance(const int &, const amrex::Real &, const int &, const amrex::Real &, const SolverChoice &, amrex::Vector< amrex::Vector< amrex::MultiFab >> &, const amrex::Vector< std::unique_ptr< amrex::MultiFab >> &)=0Microphysicspure virtual Define(const int &, SolverChoice &)=0Microphysicspure virtual Get_Qmoist_Ptr(const int &, const int &)=0Microphysicspure virtual - Get_Qmoist_Restart_Vars(int, std::vector< int > &, std::vector< std::string > &) const =0Microphysicspure virtual + Get_Qmoist_Restart_Vars(int, const SolverChoice &, std::vector< int > &, std::vector< std::string > &) const =0Microphysicspure virtual Get_Qmoist_Size(const int &)=0Microphysicspure virtual Get_Qstate_Size()=0Microphysicspure virtual Init(const int &, const amrex::MultiFab &, const amrex::BoxArray &, const amrex::Geometry &, const amrex::Real &, std::unique_ptr< amrex::MultiFab > &, std::unique_ptr< amrex::MultiFab > &)=0Microphysicspure virtual diff --git a/classMicrophysics.html b/classMicrophysics.html index be9b2cdac..acaf6a724 100644 --- a/classMicrophysics.html +++ b/classMicrophysics.html @@ -137,9 +137,9 @@ virtual int Get_Qstate_Size ()=0  get the number of moisture-model-related conserved state variables More...
  -virtual void Get_Qmoist_Restart_Vars (int, std::vector< int > &, std::vector< std::string > &) const =0 - get the indices and names of moisture model variables for restart at a given level More...
-  +virtual void Get_Qmoist_Restart_Vars (int, const SolverChoice &, std::vector< int > &, std::vector< std::string > &) const =0 + get the indices and names of moisture model variables for restart at a given level More...
+  @@ -356,8 +356,8 @@

-

◆ Get_Qmoist_Restart_Vars()

+ +

◆ Get_Qmoist_Restart_Vars()

@@ -371,6 +371,12 @@

int 

+ + + + + + @@ -398,7 +404,7 @@

EulerianMicrophysics.

+

Implemented in EulerianMicrophysics.

diff --git a/classMicrophysics.js b/classMicrophysics.js index 7cf7d4836..aa691e5f0 100644 --- a/classMicrophysics.js +++ b/classMicrophysics.js @@ -5,7 +5,7 @@ var classMicrophysics = [ "Advance", "classMicrophysics.html#a88b5020f081efbf8805cffff5cde298c", null ], [ "Define", "classMicrophysics.html#a380240aa9ec93af02a9b27ba1be4172a", null ], [ "Get_Qmoist_Ptr", "classMicrophysics.html#a8edecc53bfdfd0d916d37e3584ebb9ff", null ], - [ "Get_Qmoist_Restart_Vars", "classMicrophysics.html#a9ef955e7ab8b4c969935786af922d4ea", null ], + [ "Get_Qmoist_Restart_Vars", "classMicrophysics.html#a96e15433c5277151700438dc2f6fba6f", null ], [ "Get_Qmoist_Size", "classMicrophysics.html#a069e6013efb78d268394868d0cfc6382", null ], [ "Get_Qstate_Size", "classMicrophysics.html#a72f6091687c014c5be34275b0975d194", null ], [ "Init", "classMicrophysics.html#a4e781e2a953a088477cfc5a1e3691f2e", null ], diff --git a/classNullMoist-members.html b/classNullMoist-members.html index a2963e146..1aaf5d1ad 100644 --- a/classNullMoist-members.html +++ b/classNullMoist-members.html @@ -98,7 +98,7 @@

- + diff --git a/classNullMoist.html b/classNullMoist.html index 713222716..083f3ee84 100644 --- a/classNullMoist.html +++ b/classNullMoist.html @@ -138,8 +138,8 @@ - - + +

Static Public Member Functions

,
const SolverChoice,
m_qstate_sizeNullMoistprivate
NullMoist()NullMoistinline
Qmoist_Ptr(const int &)NullMoistinlinevirtual
Qmoist_Restart_Vars(std::vector< int > &a_idx, std::vector< std::string > &a_names) constNullMoistinlinevirtual
Qmoist_Restart_Vars(const SolverChoice &, std::vector< int > &a_idx, std::vector< std::string > &a_names) constNullMoistinlinevirtual
Qmoist_Size()NullMoistinlinevirtual
Qstate_Size()NullMoistinlinevirtual
Update_Micro_Vars(amrex::MultiFab &)NullMoistinlinevirtual
 
virtual int Qstate_Size ()
 
virtual void Qmoist_Restart_Vars (std::vector< int > &a_idx, std::vector< std::string > &a_names) const
 
virtual void Qmoist_Restart_Vars (const SolverChoice &, std::vector< int > &a_idx, std::vector< std::string > &a_names) const
 
@@ -419,8 +419,8 @@

-

◆ Qmoist_Restart_Vars()

+ +

◆ Qmoist_Restart_Vars()

+ + + + + + @@ -453,7 +459,7 @@

-

Reimplemented in SAM, and Kessler.

+

Reimplemented in SAM, and Kessler.

63  {
64  a_idx.clear();
65  a_names.clear();
diff --git a/classNullMoist.js b/classNullMoist.js index 2919c5f97..4201f2a0a 100644 --- a/classNullMoist.js +++ b/classNullMoist.js @@ -8,7 +8,7 @@ var classNullMoist = [ "Define", "classNullMoist.html#aab112947c592c330b45a2d7e5529ec07", null ], [ "Init", "classNullMoist.html#a6f526044328db858069e4b6a70fdbdf7", null ], [ "Qmoist_Ptr", "classNullMoist.html#a1b6a72d67d9b2642e99a5b768315476c", null ], - [ "Qmoist_Restart_Vars", "classNullMoist.html#a37d2e492b3e5d1927f79e680d257422c", null ], + [ "Qmoist_Restart_Vars", "classNullMoist.html#a77d6c9875f6a3a7242b090e6fece5c0f", null ], [ "Qmoist_Size", "classNullMoist.html#abdf706f193bbb09c62e41734570f3cd1", null ], [ "Qstate_Size", "classNullMoist.html#afaa201a3a1dc21c18888d9c6a068f956", null ], [ "Update_Micro_Vars", "classNullMoist.html#aece7a50f16bf40e3e9d536cc030458f7", null ], diff --git a/classSAM-members.html b/classSAM-members.html index 8c1c04abe..1e3ba574d 100644 --- a/classSAM-members.html +++ b/classSAM-members.html @@ -135,7 +135,7 @@

- + diff --git a/classSAM.html b/classSAM.html index 8cdd6e0cd..c3ac0c112 100644 --- a/classSAM.html +++ b/classSAM.html @@ -158,8 +158,8 @@ - - + + @@ -382,7 +382,7 @@

void IceFall(const SolverChoice &sc)
Definition: ERF_IceFall.cpp:10
void Cloud(const SolverChoice &sc)
Definition: ERF_Cloud_SAM.cpp:12
void PrecipFall(const SolverChoice &sc)
Definition: ERF_PrecipFall.cpp:15
-
amrex::Real dt
Definition: ERF_SAM.H:294
+
amrex::Real dt
Definition: ERF_SAM.H:299
Here is the call graph for this function:
@@ -596,11 +596,11 @@

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void erf_qsatw(amrex::Real t, amrex::Real p, amrex::Real &qsatw)
Definition: ERF_Microphysics_Utils.H:127

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE void erf_qsati(amrex::Real t, amrex::Real p, amrex::Real &qsati)
Definition: ERF_Microphysics_Utils.H:120
AMREX_GPU_HOST_DEVICE static AMREX_FORCE_INLINE amrex::Real NewtonIterSat(int &i, int &j, int &k, const int &SAM_moisture_type, const amrex::Real &fac_cond, const amrex::Real &fac_fus, const amrex::Real &fac_sub, const amrex::Real &an, const amrex::Real &bn, const amrex::Array4< amrex::Real > &tabs_array, const amrex::Array4< amrex::Real > &pres_array, const amrex::Array4< amrex::Real > &qv_array, const amrex::Array4< amrex::Real > &qc_array, const amrex::Array4< amrex::Real > &qi_array, const amrex::Array4< amrex::Real > &qn_array, const amrex::Array4< amrex::Real > &qt_array)
Definition: ERF_SAM.H:153
-
amrex::Array< FabPtr, MicVar::NumVars > mic_fab_vars
Definition: ERF_SAM.H:317
-
amrex::Real m_rdOcp
Definition: ERF_SAM.H:310
-
amrex::Real m_fac_fus
Definition: ERF_SAM.H:307
-
amrex::Real m_fac_cond
Definition: ERF_SAM.H:306
-
amrex::Real m_fac_sub
Definition: ERF_SAM.H:308
+
amrex::Array< FabPtr, MicVar::NumVars > mic_fab_vars
Definition: ERF_SAM.H:322
+
amrex::Real m_rdOcp
Definition: ERF_SAM.H:315
+
amrex::Real m_fac_fus
Definition: ERF_SAM.H:312
+
amrex::Real m_fac_cond
Definition: ERF_SAM.H:311
+
amrex::Real m_fac_sub
Definition: ERF_SAM.H:313
@ pres
Definition: ERF_SAM.H:33
@ qci
Definition: ERF_SAM.H:39
@ qv
Definition: ERF_SAM.H:37
@@ -610,7 +610,7 @@

@ theta
Definition: ERF_SAM.H:31
@ qcl
Definition: ERF_SAM.H:38
@ tabs
Definition: ERF_SAM.H:32
-
MoistureType moisture_type
Definition: ERF_DataStruct.H:627
+
MoistureType moisture_type
Definition: ERF_DataStruct.H:626

Referenced by Advance().

@@ -811,27 +811,27 @@

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real erf_esati(amrex::Real t)
Definition: ERF_Microphysics_Utils.H:24

AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real erf_gammafff(amrex::Real x)
Definition: ERF_Microphysics_Utils.H:15
Definition: ERF_PlaneAverage.H:14
-
amrex::TableData< amrex::Real, 1 > rho1d
Definition: ERF_SAM.H:334
-
amrex::TableData< amrex::Real, 1 > evapr2
Definition: ERF_SAM.H:331
-
amrex::TableData< amrex::Real, 1 > evapg1
Definition: ERF_SAM.H:328
-
amrex::TableData< amrex::Real, 1 > accrgi
Definition: ERF_SAM.H:326
-
amrex::TableData< amrex::Real, 1 > evapg2
Definition: ERF_SAM.H:329
-
int m_axis
Definition: ERF_SAM.H:300
-
amrex::Real m_gOcp
Definition: ERF_SAM.H:309
-
amrex::TableData< amrex::Real, 1 > evaps1
Definition: ERF_SAM.H:324
-
amrex::TableData< amrex::Real, 1 > zmid
Definition: ERF_SAM.H:342
-
amrex::TableData< amrex::Real, 1 > accrsi
Definition: ERF_SAM.H:321
-
amrex::TableData< amrex::Real, 1 > accrrc
Definition: ERF_SAM.H:320
-
amrex::TableData< amrex::Real, 1 > pres1d
Definition: ERF_SAM.H:335
-
int nlev
Definition: ERF_SAM.H:297
-
amrex::Geometry m_geom
Definition: ERF_SAM.H:288
-
amrex::TableData< amrex::Real, 1 > evapr1
Definition: ERF_SAM.H:330
-
amrex::TableData< amrex::Real, 1 > evaps2
Definition: ERF_SAM.H:325
-
amrex::TableData< amrex::Real, 1 > accrgc
Definition: ERF_SAM.H:327
-
amrex::TableData< amrex::Real, 1 > accrsc
Definition: ERF_SAM.H:322
-
amrex::TableData< amrex::Real, 1 > coefice
Definition: ERF_SAM.H:323
-
amrex::TableData< amrex::Real, 1 > tabs1d
Definition: ERF_SAM.H:336
-
amrex::TableData< amrex::Real, 1 > gamaz
Definition: ERF_SAM.H:341
+
amrex::TableData< amrex::Real, 1 > rho1d
Definition: ERF_SAM.H:339
+
amrex::TableData< amrex::Real, 1 > evapr2
Definition: ERF_SAM.H:336
+
amrex::TableData< amrex::Real, 1 > evapg1
Definition: ERF_SAM.H:333
+
amrex::TableData< amrex::Real, 1 > accrgi
Definition: ERF_SAM.H:331
+
amrex::TableData< amrex::Real, 1 > evapg2
Definition: ERF_SAM.H:334
+
int m_axis
Definition: ERF_SAM.H:305
+
amrex::Real m_gOcp
Definition: ERF_SAM.H:314
+
amrex::TableData< amrex::Real, 1 > evaps1
Definition: ERF_SAM.H:329
+
amrex::TableData< amrex::Real, 1 > zmid
Definition: ERF_SAM.H:347
+
amrex::TableData< amrex::Real, 1 > accrsi
Definition: ERF_SAM.H:326
+
amrex::TableData< amrex::Real, 1 > accrrc
Definition: ERF_SAM.H:325
+
amrex::TableData< amrex::Real, 1 > pres1d
Definition: ERF_SAM.H:340
+
int nlev
Definition: ERF_SAM.H:302
+
amrex::Geometry m_geom
Definition: ERF_SAM.H:293
+
amrex::TableData< amrex::Real, 1 > evapr1
Definition: ERF_SAM.H:335
+
amrex::TableData< amrex::Real, 1 > evaps2
Definition: ERF_SAM.H:330
+
amrex::TableData< amrex::Real, 1 > accrgc
Definition: ERF_SAM.H:332
+
amrex::TableData< amrex::Real, 1 > accrsc
Definition: ERF_SAM.H:327
+
amrex::TableData< amrex::Real, 1 > coefice
Definition: ERF_SAM.H:328
+
amrex::TableData< amrex::Real, 1 > tabs1d
Definition: ERF_SAM.H:341
+
amrex::TableData< amrex::Real, 1 > gamaz
Definition: ERF_SAM.H:346

Referenced by Update_Micro_Vars().

@@ -1101,13 +1101,13 @@

89  }

constexpr amrex::Real lfus
Definition: ERF_Constants.H:67
constexpr amrex::Real CONST_GRAV
Definition: ERF_Constants.H:21
-
bool doprecip
Definition: ERF_SAM.H:303
-
bool docloud
Definition: ERF_SAM.H:303
-
amrex::Real rdOcp
Definition: ERF_DataStruct.H:581
-
amrex::Real c_p
Definition: ERF_DataStruct.H:580
-
bool do_precip
Definition: ERF_DataStruct.H:641
-
bool do_cloud
Definition: ERF_DataStruct.H:640
-
int ave_plane
Definition: ERF_DataStruct.H:638
+
bool doprecip
Definition: ERF_SAM.H:308
+
bool docloud
Definition: ERF_SAM.H:308
+
amrex::Real rdOcp
Definition: ERF_DataStruct.H:580
+
amrex::Real c_p
Definition: ERF_DataStruct.H:579
+
bool do_precip
Definition: ERF_DataStruct.H:640
+
bool do_cloud
Definition: ERF_DataStruct.H:639
+
int ave_plane
Definition: ERF_DataStruct.H:637
@@ -1221,7 +1221,7 @@

101  }
102 }
AMREX_FORCE_INLINE amrex::IntVect TileNoZ()
Definition: ERF_TileNoZ.H:11
-
amrex::MultiFab * m_detJ_cc
Definition: ERF_SAM.H:314
+
amrex::MultiFab * m_detJ_cc
Definition: ERF_SAM.H:319
@ qcl
Definition: ERF_Kessler.H:37
@ tabs
Definition: ERF_Kessler.H:32
@ rho
Definition: ERF_Kessler.H:30
@@ -1373,12 +1373,12 @@

77  zmid.resize({zlo}, {zhi});
78  }
79 }
-
int zlo
Definition: ERF_SAM.H:297
-
int m_qmoist_size
Definition: ERF_SAM.H:279
-
amrex::MultiFab * m_z_phys_nd
Definition: ERF_SAM.H:313
-
amrex::BoxArray m_gtoe
Definition: ERF_SAM.H:291
-
amrex::Vector< int > MicVarMap
Definition: ERF_SAM.H:285
-
int zhi
Definition: ERF_SAM.H:297
+
int zlo
Definition: ERF_SAM.H:302
+
int m_qmoist_size
Definition: ERF_SAM.H:284
+
amrex::MultiFab * m_z_phys_nd
Definition: ERF_SAM.H:318
+
amrex::BoxArray m_gtoe
Definition: ERF_SAM.H:296
+
amrex::Vector< int > MicVarMap
Definition: ERF_SAM.H:290
+
int zhi
Definition: ERF_SAM.H:302
@ NumVars
Definition: ERF_SAM.H:50
@ snow_accum
Definition: ERF_SAM.H:47
@ rain_accum
Definition: ERF_SAM.H:46
@@ -2155,8 +2155,8 @@

-

◆ Qmoist_Restart_Vars()

+ +

◆ Qmoist_Restart_Vars()

@@ -2167,6 +2167,12 @@

void SAM::Qmoist_Restart_Vars

+ + + + + + @@ -2189,14 +2195,18 @@

-

Reimplemented from NullMoist.

-
269  {
-
270  a_idx.clear();
-
271  a_names.clear();
-
272  a_idx.push_back( 8); a_names.push_back("RainAccum");
-
273  a_idx.push_back( 9); a_names.push_back("SnowAccum");
-
274  a_idx.push_back(10); a_names.push_back("GraupAccum");
-
275  }
+

Reimplemented from NullMoist.

+
270  {
+
271  a_idx.clear();
+
272  a_names.clear();
+
273  if (a_sc.moisture_type == MoistureType::SAM) {
+
274  a_idx.push_back( 8); a_names.push_back("RainAccum");
+
275  a_idx.push_back( 9); a_names.push_back("SnowAccum");
+
276  a_idx.push_back(10); a_names.push_back("GraupAccum");
+
277  } else if (a_sc.moisture_type == MoistureType::SAM_NoIce) {
+
278  a_idx.push_back( 8); a_names.push_back("RainAccum");
+
279  }
+
280  }
@@ -2253,7 +2263,7 @@

NullMoist.

148 { return SAM::m_qstate_size; }
-
int m_qstate_size
Definition: ERF_SAM.H:282
+
int m_qstate_size
Definition: ERF_SAM.H:287
diff --git a/classSAM.js b/classSAM.js index 4ed53d5d6..d2ebfce5d 100644 --- a/classSAM.js +++ b/classSAM.js @@ -15,7 +15,7 @@ var classSAM = [ "Precip", "classSAM.html#a05218bdc2187b79e456ade5b6f5bdb3c", null ], [ "PrecipFall", "classSAM.html#ae870dc821f7cd01ffc3bfd7925b1d18b", null ], [ "Qmoist_Ptr", "classSAM.html#af6652cb6f7b93a1e418da98b5a8b57b7", null ], - [ "Qmoist_Restart_Vars", "classSAM.html#a431ab0e206069e43d7b2915f083344c3", null ], + [ "Qmoist_Restart_Vars", "classSAM.html#ac7854fbde48bad0aadc203adcb1508a5", null ], [ "Qmoist_Size", "classSAM.html#ae27c1d50525a70f838fa9ba73e61ef46", null ], [ "Qstate_Size", "classSAM.html#aba750ad815594f21255d26d24810d3fe", null ], [ "Update_Micro_Vars", "classSAM.html#a2e6ff95cf827306bbcf3661c954a692e", null ], diff --git a/functions_func_g.html b/functions_func_g.html index f3a393f54..d7dca71fa 100644 --- a/functions_func_g.html +++ b/functions_func_g.html @@ -364,8 +364,8 @@

- g -

    , Microphysics
  • Get_Qmoist_Restart_Vars() -: EulerianMicrophysics -, Microphysics +: EulerianMicrophysics +, Microphysics
  • Get_Qmoist_Size() : EulerianMicrophysics diff --git a/functions_func_q.html b/functions_func_q.html index 1dde620d9..ccb1aee39 100644 --- a/functions_func_q.html +++ b/functions_func_q.html @@ -91,9 +91,9 @@

    - q -

      , SAM
    • Qmoist_Restart_Vars() -: Kessler -, NullMoist -, SAM +: Kessler +, NullMoist +, SAM
    • Qmoist_Size() : Kessler diff --git a/functions_g.html b/functions_g.html index 689013faf..5d8097637 100644 --- a/functions_g.html +++ b/functions_g.html @@ -462,8 +462,8 @@

      - g -

        , Microphysics
      • Get_Qmoist_Restart_Vars() -: EulerianMicrophysics -, Microphysics +: EulerianMicrophysics +, Microphysics
      • Get_Qmoist_Size() : EulerianMicrophysics diff --git a/functions_q.html b/functions_q.html index d72ae5a41..2311457df 100644 --- a/functions_q.html +++ b/functions_q.html @@ -106,9 +106,9 @@

        - q -

          , SAM
        • Qmoist_Restart_Vars() -: Kessler -, NullMoist -, SAM +: Kessler +, NullMoist +, SAM
        • Qmoist_Size() : Kessler diff --git a/navtreeindex5.js b/navtreeindex5.js index 12495084a..0db1c4fc7 100644 --- a/navtreeindex5.js +++ b/navtreeindex5.js @@ -184,8 +184,8 @@ var NAVTREEINDEX5 = "classEbertCurry.html#ae258a04b9aaba9ca0052793a2d57f05e":[2,0,21,0], "classEbertCurry.html#aed435ba6c3e2c62f6ba2d8111c7c2f08":[2,0,21,1], "classEulerianMicrophysics.html":[2,0,29], +"classEulerianMicrophysics.html#a0bf4ba2dccc3aa4f2c462162ad54d1fc":[2,0,29,6], "classEulerianMicrophysics.html#a0f8fc766c44f4331bfc86337eb43f6cc":[2,0,29,11], -"classEulerianMicrophysics.html#a23d6676d025a0129cf4ed73d887605bf":[2,0,29,6], "classEulerianMicrophysics.html#a26a985c76efcd1dd68b5c853bbd264f6":[2,0,29,2], "classEulerianMicrophysics.html#a2eb29d168749af2ea18fc7d67dc5259c":[2,0,29,1], "classEulerianMicrophysics.html#a3d8916fc5900c54728d7549c68b21048":[2,0,29,13], diff --git a/navtreeindex6.js b/navtreeindex6.js index f5913bad0..be095eeef 100644 --- a/navtreeindex6.js +++ b/navtreeindex6.js @@ -39,7 +39,7 @@ var NAVTREEINDEX6 = "classKessler.html#add7ed88ab0086ee53aa15e87cc8686ef":[2,0,38,14], "classKessler.html#ae8749011028be638e3fb8051e22f83f1":[2,0,38,25], "classKessler.html#ae94091e97ccba54c040030c98e52aa7c":[2,0,38,26], -"classKessler.html#af5909874026a86cf12523779a3761fb3":[2,0,38,10], +"classKessler.html#af35573a87c89def1be544055625a7f8b":[2,0,38,10], "classKessler.html#afea161a2b985d4c0eb4aa9390a808ab4":[2,0,38,18], "classLandSurface.html":[2,0,39], "classLandSurface.html#a06a0bb4f12e604dbbd844bd4d2b0903f":[2,0,39,16], diff --git a/navtreeindex7.js b/navtreeindex7.js index f8d7018f0..f258f1aca 100644 --- a/navtreeindex7.js +++ b/navtreeindex7.js @@ -71,7 +71,7 @@ var NAVTREEINDEX7 = "classMicrophysics.html#a79bf043906abc7e4d738318ec8e7aa2e":[2,0,43,0], "classMicrophysics.html#a88b5020f081efbf8805cffff5cde298c":[2,0,43,2], "classMicrophysics.html#a8edecc53bfdfd0d916d37e3584ebb9ff":[2,0,43,4], -"classMicrophysics.html#a9ef955e7ab8b4c969935786af922d4ea":[2,0,43,5], +"classMicrophysics.html#a96e15433c5277151700438dc2f6fba6f":[2,0,43,5], "classMicrophysics.html#ac10e6fce2e6cb49373d56ca0e1a5b366":[2,0,43,9], "classModalAeroWateruptake.html":[2,0,45], "classModalAeroWateruptake.html#a134cf0f1fd68266a37a7683e362553c4":[2,0,45,0], @@ -101,11 +101,11 @@ var NAVTREEINDEX7 = "classNullMoist.html#a11a25944d4ddb955f74e355838b9d8b0":[2,0,55,3], "classNullMoist.html#a1b6a72d67d9b2642e99a5b768315476c":[2,0,55,7], "classNullMoist.html#a24f0528f7d31b89f36a3c225c7e53010":[2,0,55,12], -"classNullMoist.html#a37d2e492b3e5d1927f79e680d257422c":[2,0,55,8], "classNullMoist.html#a3cb016aa9c0f1ee7534ad678723d1c59":[2,0,55,14], "classNullMoist.html#a645f66b91b08d84aa7451a9da0c11a72":[2,0,55,13], "classNullMoist.html#a6f526044328db858069e4b6a70fdbdf7":[2,0,55,6], "classNullMoist.html#a75e2d77cb28efa62759818d066b53bb9":[2,0,55,1], +"classNullMoist.html#a77d6c9875f6a3a7242b090e6fece5c0f":[2,0,55,8], "classNullMoist.html#a987746c147545a1a7d0efd21e5e34a12":[2,0,55,0], "classNullMoist.html#aa2f97dcd622bc4ef212421d496ee2297":[2,0,55,2], "classNullMoist.html#aab112947c592c330b45a2d7e5529ec07":[2,0,55,5], diff --git a/navtreeindex9.js b/navtreeindex9.js index a8c13b40c..b72931764 100644 --- a/navtreeindex9.js +++ b/navtreeindex9.js @@ -50,7 +50,6 @@ var NAVTREEINDEX9 = "classSAM.html#a37854ec84283a4229cf86b54cfcfc72b":[2,0,68,36], "classSAM.html#a3a76b3fc76d33c147dcaab81a738f41c":[2,0,68,42], "classSAM.html#a3b461d5620f6b9a08a1e62b60a463af7":[2,0,68,46], -"classSAM.html#a431ab0e206069e43d7b2915f083344c3":[2,0,68,15], "classSAM.html#a48d25f57da2ba1d7ddb503ede0b8d998":[2,0,68,4], "classSAM.html#a4bf36ad050daafdcfea1aa83ad75f9cf":[2,0,68,44], "classSAM.html#a51af1452ad89711f8ddaa554cdc49ee6":[2,0,68,47], @@ -82,6 +81,7 @@ var NAVTREEINDEX9 = "classSAM.html#aaf2fc082e80f1c5cc9de339ff25ca27b":[2,0,68,57], "classSAM.html#aba6460f2d34882d6b512574106e44531":[2,0,68,8], "classSAM.html#aba750ad815594f21255d26d24810d3fe":[2,0,68,17], +"classSAM.html#ac7854fbde48bad0aadc203adcb1508a5":[2,0,68,15], "classSAM.html#ae27c1d50525a70f838fa9ba73e61ef46":[2,0,68,16], "classSAM.html#ae870dc821f7cd01ffc3bfd7925b1d18b":[2,0,68,13], "classSAM.html#aea5fdd520cbb1bc936a0f11d55400029":[2,0,68,19], diff --git a/search/all_10.js b/search/all_10.js index 54ff5896a..0dc7d73a9 100644 --- a/search/all_10.js +++ b/search/all_10.js @@ -14,7 +14,7 @@ var searchData= ['qke_5fv_1799',['QKE_v',['../namespaceEddyDiff.html#a7e7e94a6b49fe20d106a1ea7317d149eab74402005c035d247402e5f247827dcc',1,'EddyDiff']]], ['qmoist_1800',['qmoist',['../classERF.html#ae00126a9c2738bf6a6cbbe77321c9cfc',1,'ERF']]], ['qmoist_5fptr_1801',['Qmoist_Ptr',['../classKessler.html#a0a84c629a080e71ed93a5f349ad7724a',1,'Kessler::Qmoist_Ptr()'],['../classSAM.html#af6652cb6f7b93a1e418da98b5a8b57b7',1,'SAM::Qmoist_Ptr()'],['../classNullMoist.html#a1b6a72d67d9b2642e99a5b768315476c',1,'NullMoist::Qmoist_Ptr()']]], - ['qmoist_5frestart_5fvars_1802',['Qmoist_Restart_Vars',['../classSAM.html#a431ab0e206069e43d7b2915f083344c3',1,'SAM::Qmoist_Restart_Vars()'],['../classNullMoist.html#a37d2e492b3e5d1927f79e680d257422c',1,'NullMoist::Qmoist_Restart_Vars()'],['../classKessler.html#af5909874026a86cf12523779a3761fb3',1,'Kessler::Qmoist_Restart_Vars()']]], + ['qmoist_5frestart_5fvars_1802',['Qmoist_Restart_Vars',['../classSAM.html#ac7854fbde48bad0aadc203adcb1508a5',1,'SAM::Qmoist_Restart_Vars()'],['../classNullMoist.html#a77d6c9875f6a3a7242b090e6fece5c0f',1,'NullMoist::Qmoist_Restart_Vars()'],['../classKessler.html#af35573a87c89def1be544055625a7f8b',1,'Kessler::Qmoist_Restart_Vars()']]], ['qmoist_5fsize_1803',['Qmoist_Size',['../classSAM.html#ae27c1d50525a70f838fa9ba73e61ef46',1,'SAM::Qmoist_Size()'],['../classNullMoist.html#abdf706f193bbb09c62e41734570f3cd1',1,'NullMoist::Qmoist_Size()'],['../classKessler.html#a3925ff722ac968e306dbcc233718030a',1,'Kessler::Qmoist_Size()']]], ['qn_1804',['qn',['../classRadiation.html#a913e1b4a5c5ddf093f81c6a6c7051035',1,'Radiation::qn()'],['../namespaceMicVar.html#a1609c4386a90fb1c27791fa3cd511fa8a62db2b95f840b974246d431152593fb8',1,'MicVar::qn()']]], ['qn1d_1805',['qn1d',['../classSAM.html#a9fafcc2e5b063f7ccb94e2cc78324d35',1,'SAM']]], diff --git a/search/all_6.js b/search/all_6.js index 5af561323..febbfc8d6 100644 --- a/search/all_6.js +++ b/search/all_6.js @@ -116,7 +116,7 @@ var searchData= ['get_5fprojection_5fbc_959',['get_projection_bc',['../classERF.html#a57580311d47c9fd5e27ba156d287c169',1,'ERF']]], ['get_5fq_5fstar_960',['get_q_star',['../classABLMost.html#a5468d40c9751664279c940369c8040dd',1,'ABLMost']]], ['get_5fqmoist_5fptr_961',['Get_Qmoist_Ptr',['../classEulerianMicrophysics.html#a416981f230a126387b9a664a5a241e9c',1,'EulerianMicrophysics::Get_Qmoist_Ptr()'],['../classMicrophysics.html#a8edecc53bfdfd0d916d37e3584ebb9ff',1,'Microphysics::Get_Qmoist_Ptr()']]], - ['get_5fqmoist_5frestart_5fvars_962',['Get_Qmoist_Restart_Vars',['../classEulerianMicrophysics.html#a23d6676d025a0129cf4ed73d887605bf',1,'EulerianMicrophysics::Get_Qmoist_Restart_Vars()'],['../classMicrophysics.html#a9ef955e7ab8b4c969935786af922d4ea',1,'Microphysics::Get_Qmoist_Restart_Vars()']]], + ['get_5fqmoist_5frestart_5fvars_962',['Get_Qmoist_Restart_Vars',['../classEulerianMicrophysics.html#a0bf4ba2dccc3aa4f2c462162ad54d1fc',1,'EulerianMicrophysics::Get_Qmoist_Restart_Vars()'],['../classMicrophysics.html#a96e15433c5277151700438dc2f6fba6f',1,'Microphysics::Get_Qmoist_Restart_Vars()']]], ['get_5fqmoist_5fsize_963',['Get_Qmoist_Size',['../classEulerianMicrophysics.html#ad4983e19f621a55ad7d942c881215c72',1,'EulerianMicrophysics::Get_Qmoist_Size()'],['../classMicrophysics.html#a069e6013efb78d268394868d0cfc6382',1,'Microphysics::Get_Qmoist_Size()']]], ['get_5fqstate_5fsize_964',['Get_Qstate_Size',['../classEulerianMicrophysics.html#a3e973738b4e0bbaa7269ab2395322929',1,'EulerianMicrophysics::Get_Qstate_Size()'],['../classMicrophysics.html#a72f6091687c014c5be34275b0975d194',1,'Microphysics::Get_Qstate_Size()']]], ['get_5fr_5flw_5fabs_965',['get_r_lw_abs',['../classPhysProp.html#a4021cec87565fb8d2f83d246764b207c',1,'PhysProp']]], diff --git a/search/functions_6.js b/search/functions_6.js index 54895df27..35a4c484a 100644 --- a/search/functions_6.js +++ b/search/functions_6.js @@ -90,7 +90,7 @@ var searchData= ['get_5fprojection_5fbc_3246',['get_projection_bc',['../classERF.html#a57580311d47c9fd5e27ba156d287c169',1,'ERF']]], ['get_5fq_5fstar_3247',['get_q_star',['../classABLMost.html#a5468d40c9751664279c940369c8040dd',1,'ABLMost']]], ['get_5fqmoist_5fptr_3248',['Get_Qmoist_Ptr',['../classEulerianMicrophysics.html#a416981f230a126387b9a664a5a241e9c',1,'EulerianMicrophysics::Get_Qmoist_Ptr()'],['../classMicrophysics.html#a8edecc53bfdfd0d916d37e3584ebb9ff',1,'Microphysics::Get_Qmoist_Ptr()']]], - ['get_5fqmoist_5frestart_5fvars_3249',['Get_Qmoist_Restart_Vars',['../classEulerianMicrophysics.html#a23d6676d025a0129cf4ed73d887605bf',1,'EulerianMicrophysics::Get_Qmoist_Restart_Vars()'],['../classMicrophysics.html#a9ef955e7ab8b4c969935786af922d4ea',1,'Microphysics::Get_Qmoist_Restart_Vars()']]], + ['get_5fqmoist_5frestart_5fvars_3249',['Get_Qmoist_Restart_Vars',['../classEulerianMicrophysics.html#a0bf4ba2dccc3aa4f2c462162ad54d1fc',1,'EulerianMicrophysics::Get_Qmoist_Restart_Vars()'],['../classMicrophysics.html#a96e15433c5277151700438dc2f6fba6f',1,'Microphysics::Get_Qmoist_Restart_Vars()']]], ['get_5fqmoist_5fsize_3250',['Get_Qmoist_Size',['../classEulerianMicrophysics.html#ad4983e19f621a55ad7d942c881215c72',1,'EulerianMicrophysics::Get_Qmoist_Size()'],['../classMicrophysics.html#a069e6013efb78d268394868d0cfc6382',1,'Microphysics::Get_Qmoist_Size()']]], ['get_5fqstate_5fsize_3251',['Get_Qstate_Size',['../classEulerianMicrophysics.html#a3e973738b4e0bbaa7269ab2395322929',1,'EulerianMicrophysics::Get_Qstate_Size()'],['../classMicrophysics.html#a72f6091687c014c5be34275b0975d194',1,'Microphysics::Get_Qstate_Size()']]], ['get_5fr_5flw_5fabs_3252',['get_r_lw_abs',['../classPhysProp.html#a4021cec87565fb8d2f83d246764b207c',1,'PhysProp']]], diff --git a/search/functions_f.js b/search/functions_f.js index 0140aae92..118d5f79d 100644 --- a/search/functions_f.js +++ b/search/functions_f.js @@ -1,7 +1,7 @@ var searchData= [ ['qmoist_5fptr_3543',['Qmoist_Ptr',['../classKessler.html#a0a84c629a080e71ed93a5f349ad7724a',1,'Kessler::Qmoist_Ptr()'],['../classNullMoist.html#a1b6a72d67d9b2642e99a5b768315476c',1,'NullMoist::Qmoist_Ptr()'],['../classSAM.html#af6652cb6f7b93a1e418da98b5a8b57b7',1,'SAM::Qmoist_Ptr()']]], - ['qmoist_5frestart_5fvars_3544',['Qmoist_Restart_Vars',['../classKessler.html#af5909874026a86cf12523779a3761fb3',1,'Kessler::Qmoist_Restart_Vars()'],['../classNullMoist.html#a37d2e492b3e5d1927f79e680d257422c',1,'NullMoist::Qmoist_Restart_Vars()'],['../classSAM.html#a431ab0e206069e43d7b2915f083344c3',1,'SAM::Qmoist_Restart_Vars()']]], + ['qmoist_5frestart_5fvars_3544',['Qmoist_Restart_Vars',['../classKessler.html#af35573a87c89def1be544055625a7f8b',1,'Kessler::Qmoist_Restart_Vars()'],['../classNullMoist.html#a77d6c9875f6a3a7242b090e6fece5c0f',1,'NullMoist::Qmoist_Restart_Vars()'],['../classSAM.html#ac7854fbde48bad0aadc203adcb1508a5',1,'SAM::Qmoist_Restart_Vars()']]], ['qmoist_5fsize_3545',['Qmoist_Size',['../classKessler.html#a3925ff722ac968e306dbcc233718030a',1,'Kessler::Qmoist_Size()'],['../classNullMoist.html#abdf706f193bbb09c62e41734570f3cd1',1,'NullMoist::Qmoist_Size()'],['../classSAM.html#ae27c1d50525a70f838fa9ba73e61ef46',1,'SAM::Qmoist_Size()']]], ['qsat_3546',['qsat',['../classWaterVaporSat.html#a964d1dd8ddaba9c5a482480fc51d7eba',1,'WaterVaporSat']]], ['qsat_5fice_3547',['qsat_ice',['../classWaterVaporSat.html#a55f00a8a0a629c85e6a477d11a4f14e5',1,'WaterVaporSat']]], diff --git a/structSolverChoice.html b/structSolverChoice.html index 531d59de3..15f242f2f 100644 --- a/structSolverChoice.html +++ b/structSolverChoice.html @@ -315,57 +315,57 @@

          -
          477  {
          -
          478  amrex::ParmParse pp(pp_prefix);
          -
          479 
          -
          480  // Read the rotational time period (in seconds)
          -
          481  amrex::Real rot_time_period = 86400.0;
          -
          482  pp.query("rotational_time_period", rot_time_period);
          -
          483 
          -
          484  coriolis_factor = 2.0 * 2.0 * PI / rot_time_period;
          -
          485  amrex::Print() << "Coriolis factor = " << coriolis_factor << std::endl;
          -
          486 
          -
          487  amrex::Real latitude = 90.0;
          -
          488  pp.query("latitude", latitude);
          -
          489 
          -
          490  pp.query("coriolis_3d", coriolis_3d);
          -
          491 
          -
          492  // Convert to radians
          -
          493  latitude *= (PI/180.);
          -
          494  sinphi = std::sin(latitude);
          -
          495  if (coriolis_3d) {
          -
          496  cosphi = std::cos(latitude);
          -
          497  }
          -
          498 
          -
          499  amrex::Print() << "Coriolis frequency, f = " << coriolis_factor * sinphi << " 1/s" << std::endl;
          -
          500 
          -
          501  if (abl_driver_type == ABLDriverType::GeostrophicWind) {
          -
          502  // Read in the geostrophic wind -- we only use this to construct
          -
          503  // the forcing term so no need to keep it
          -
          504  amrex::Vector<amrex::Real> abl_geo_wind(3);
          -
          505  pp.queryarr("abl_geo_wind",abl_geo_wind);
          -
          506 
          -
          507  if(!pp.query("abl_geo_wind_table",abl_geo_wind_table)) {
          -
          508  abl_geo_forcing = {
          -
          509  -coriolis_factor * (abl_geo_wind[1]*sinphi - abl_geo_wind[2]*cosphi),
          -
          510  coriolis_factor * abl_geo_wind[0]*sinphi,
          -
          511  -coriolis_factor * abl_geo_wind[0]*cosphi
          -
          512  };
          -
          513  } else {
          -
          514  amrex::Print() << "NOTE: abl_geo_wind_table provided, ignoring input abl_geo_wind" << std::endl;
          -
          515  }
          -
          516  }
          -
          517  }
          +
          476  {
          +
          477  amrex::ParmParse pp(pp_prefix);
          +
          478 
          +
          479  // Read the rotational time period (in seconds)
          +
          480  amrex::Real rot_time_period = 86400.0;
          +
          481  pp.query("rotational_time_period", rot_time_period);
          +
          482 
          +
          483  coriolis_factor = 2.0 * 2.0 * PI / rot_time_period;
          +
          484  amrex::Print() << "Coriolis factor = " << coriolis_factor << std::endl;
          +
          485 
          +
          486  amrex::Real latitude = 90.0;
          +
          487  pp.query("latitude", latitude);
          +
          488 
          +
          489  pp.query("coriolis_3d", coriolis_3d);
          +
          490 
          +
          491  // Convert to radians
          +
          492  latitude *= (PI/180.);
          +
          493  sinphi = std::sin(latitude);
          +
          494  if (coriolis_3d) {
          +
          495  cosphi = std::cos(latitude);
          +
          496  }
          +
          497 
          +
          498  amrex::Print() << "Coriolis frequency, f = " << coriolis_factor * sinphi << " 1/s" << std::endl;
          +
          499 
          +
          500  if (abl_driver_type == ABLDriverType::GeostrophicWind) {
          +
          501  // Read in the geostrophic wind -- we only use this to construct
          +
          502  // the forcing term so no need to keep it
          +
          503  amrex::Vector<amrex::Real> abl_geo_wind(3);
          +
          504  pp.queryarr("abl_geo_wind",abl_geo_wind);
          +
          505 
          +
          506  if(!pp.query("abl_geo_wind_table",abl_geo_wind_table)) {
          +
          507  abl_geo_forcing = {
          +
          508  -coriolis_factor * (abl_geo_wind[1]*sinphi - abl_geo_wind[2]*cosphi),
          +
          509  coriolis_factor * abl_geo_wind[0]*sinphi,
          +
          510  -coriolis_factor * abl_geo_wind[0]*cosphi
          +
          511  };
          +
          512  } else {
          +
          513  amrex::Print() << "NOTE: abl_geo_wind_table provided, ignoring input abl_geo_wind" << std::endl;
          +
          514  }
          +
          515  }
          +
          516  }
          constexpr amrex::Real PI
          Definition: ERF_Constants.H:6
          AMREX_GPU_HOST_DEVICE AMREX_FORCE_INLINE amrex::Real pp(amrex::Real y)
          Definition: ERF_Microphysics_Utils.H:188
          -
          amrex::Real coriolis_factor
          Definition: ERF_DataStruct.H:591
          -
          amrex::Real cosphi
          Definition: ERF_DataStruct.H:592
          -
          std::string pp_prefix
          Definition: ERF_DataStruct.H:543
          -
          amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_geo_forcing
          Definition: ERF_DataStruct.H:634
          -
          amrex::Real sinphi
          Definition: ERF_DataStruct.H:593
          -
          bool coriolis_3d
          Definition: ERF_DataStruct.H:565
          -
          std::string abl_geo_wind_table
          Definition: ERF_DataStruct.H:635
          -
          ABLDriverType abl_driver_type
          Definition: ERF_DataStruct.H:632
          +
          amrex::Real coriolis_factor
          Definition: ERF_DataStruct.H:590
          +
          amrex::Real cosphi
          Definition: ERF_DataStruct.H:591
          +
          std::string pp_prefix
          Definition: ERF_DataStruct.H:542
          +
          amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_geo_forcing
          Definition: ERF_DataStruct.H:633
          +
          amrex::Real sinphi
          Definition: ERF_DataStruct.H:592
          +
          bool coriolis_3d
          Definition: ERF_DataStruct.H:564
          +
          std::string abl_geo_wind_table
          Definition: ERF_DataStruct.H:634
          +
          ABLDriverType abl_driver_type
          Definition: ERF_DataStruct.H:631

          Referenced by init_params().

          @@ -412,58 +412,58 @@

          -
          375  {
          -
          376  // Warn for PBL models and moisture - these may not yet be compatible
          -
          377  for (int lev = 0; lev <= max_level; lev++) {
          -
          378  if ((moisture_type != MoistureType::None) && (turbChoice[lev].pbl_type != PBLType::None)) {
          -
          379  amrex::Warning("\n*** WARNING: Moisture may not yet be compatible with PBL models, \n proceed with caution ***");
          -
          380  }
          -
          381  }
          -
          382  //
          -
          383  // Buoyancy type check
          -
          384  //
          -
          385  if (buoyancy_type != 1 && buoyancy_type != 2 && buoyancy_type != 3 && buoyancy_type != 4) {
          -
          386  amrex::Abort("buoyancy_type must be 1, 2, 3 or 4");
          -
          387  }
          -
          388 
          -
          389  if (!use_lagged_delta_rt && !(terrain_type == TerrainType::Moving)) {
          -
          390  amrex::Error("Can't turn off lagged_delta_rt when terrain not moving");
          -
          391  }
          -
          392 
          -
          393  //
          -
          394  // Wind farm checks
          -
          395  //
          -
          396  if (windfarm_type==WindFarmType::SimpleActuatorDisk and sampling_distance_by_D < 0.0) {
          -
          397  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
          -
          398  " erf.sampling_distance_by_D in the inputs which specifies the upstream"
          -
          399  " distance as a factor of the turbine diameter at which the incoming free stream"
          -
          400  " velocity will be computed at.");
          -
          401  }
          -
          402  if ( (windfarm_type==WindFarmType::SimpleActuatorDisk ||
          -
          403  windfarm_type==WindFarmType::GeneralActuatorDisk ) && turb_disk_angle < 0.0) {
          -
          404  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
          -
          405  " erf.turb_disk_angle_from_x in the inputs which is the angle of the face of the"
          -
          406  " turbine disk from the x-axis. A turbine facing an oncoming flow in the x-direction"
          -
          407  " will have turb_disk_angle value of 90 deg.");
          -
          408  }
          -
          409  if (windfarm_loc_type == WindFarmLocType::lat_lon and (windfarm_x_shift < 0.0 or windfarm_y_shift < 0.0)) {
          -
          410  amrex::Abort("You are using windfarms with latitude-logitude option to position the turbines."
          -
          411  " For this you should provide the inputs erf.windfarm_x_shift and"
          -
          412  " erf.windfarm_y_shift which are the values by which the bounding box of the"
          -
          413  " windfarm is shifted from the x and the y axes.");
          -
          414  }
          -
          415  }
          -
          bool use_lagged_delta_rt
          Definition: ERF_DataStruct.H:576
          -
          amrex::Real windfarm_x_shift
          Definition: ERF_DataStruct.H:655
          -
          WindFarmLocType windfarm_loc_type
          Definition: ERF_DataStruct.H:629
          -
          amrex::Real sampling_distance_by_D
          Definition: ERF_DataStruct.H:653
          -
          amrex::Vector< TurbChoice > turbChoice
          Definition: ERF_DataStruct.H:540
          -
          MoistureType moisture_type
          Definition: ERF_DataStruct.H:627
          -
          TerrainType terrain_type
          Definition: ERF_DataStruct.H:626
          -
          WindFarmType windfarm_type
          Definition: ERF_DataStruct.H:628
          -
          int buoyancy_type
          Definition: ERF_DataStruct.H:560
          -
          amrex::Real turb_disk_angle
          Definition: ERF_DataStruct.H:654
          -
          amrex::Real windfarm_y_shift
          Definition: ERF_DataStruct.H:656
          +
          374  {
          +
          375  // Warn for PBL models and moisture - these may not yet be compatible
          +
          376  for (int lev = 0; lev <= max_level; lev++) {
          +
          377  if ((moisture_type != MoistureType::None) && (turbChoice[lev].pbl_type != PBLType::None)) {
          +
          378  amrex::Warning("\n*** WARNING: Moisture may not yet be compatible with PBL models, \n proceed with caution ***");
          +
          379  }
          +
          380  }
          +
          381  //
          +
          382  // Buoyancy type check
          +
          383  //
          +
          384  if (buoyancy_type != 1 && buoyancy_type != 2 && buoyancy_type != 3 && buoyancy_type != 4) {
          +
          385  amrex::Abort("buoyancy_type must be 1, 2, 3 or 4");
          +
          386  }
          +
          387 
          +
          388  if (!use_lagged_delta_rt && !(terrain_type == TerrainType::Moving)) {
          +
          389  amrex::Error("Can't turn off lagged_delta_rt when terrain not moving");
          +
          390  }
          +
          391 
          +
          392  //
          +
          393  // Wind farm checks
          +
          394  //
          +
          395  if (windfarm_type==WindFarmType::SimpleActuatorDisk and sampling_distance_by_D < 0.0) {
          +
          396  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
          +
          397  " erf.sampling_distance_by_D in the inputs which specifies the upstream"
          +
          398  " distance as a factor of the turbine diameter at which the incoming free stream"
          +
          399  " velocity will be computed at.");
          +
          400  }
          +
          401  if ( (windfarm_type==WindFarmType::SimpleActuatorDisk ||
          +
          402  windfarm_type==WindFarmType::GeneralActuatorDisk ) && turb_disk_angle < 0.0) {
          +
          403  amrex::Abort("To use simplified actuator disks, you need to provide a variable"
          +
          404  " erf.turb_disk_angle_from_x in the inputs which is the angle of the face of the"
          +
          405  " turbine disk from the x-axis. A turbine facing an oncoming flow in the x-direction"
          +
          406  " will have turb_disk_angle value of 90 deg.");
          +
          407  }
          +
          408  if (windfarm_loc_type == WindFarmLocType::lat_lon and (windfarm_x_shift < 0.0 or windfarm_y_shift < 0.0)) {
          +
          409  amrex::Abort("You are using windfarms with latitude-logitude option to position the turbines."
          +
          410  " For this you should provide the inputs erf.windfarm_x_shift and"
          +
          411  " erf.windfarm_y_shift which are the values by which the bounding box of the"
          +
          412  " windfarm is shifted from the x and the y axes.");
          +
          413  }
          +
          414  }
          +
          bool use_lagged_delta_rt
          Definition: ERF_DataStruct.H:575
          +
          amrex::Real windfarm_x_shift
          Definition: ERF_DataStruct.H:654
          +
          WindFarmLocType windfarm_loc_type
          Definition: ERF_DataStruct.H:628
          +
          amrex::Real sampling_distance_by_D
          Definition: ERF_DataStruct.H:652
          +
          amrex::Vector< TurbChoice > turbChoice
          Definition: ERF_DataStruct.H:539
          +
          MoistureType moisture_type
          Definition: ERF_DataStruct.H:626
          +
          TerrainType terrain_type
          Definition: ERF_DataStruct.H:625
          +
          WindFarmType windfarm_type
          Definition: ERF_DataStruct.H:627
          +
          int buoyancy_type
          Definition: ERF_DataStruct.H:559
          +
          amrex::Real turb_disk_angle
          Definition: ERF_DataStruct.H:653
          +
          amrex::Real windfarm_y_shift
          Definition: ERF_DataStruct.H:655

          Referenced by init_params().

          @@ -501,75 +501,75 @@

          -
          418  {
          -
          419  amrex::Print() << "SOLVER CHOICE: " << std::endl;
          -
          420  amrex::Print() << "force_stage1_single_substep : " << force_stage1_single_substep << std::endl;
          -
          421  for (int lev = 0; lev <= max_level; lev++) {
          -
          422  amrex::Print() << "anelastic at level : " << lev << " is " << anelastic[lev] << std::endl;
          -
          423  if (substepping_type[lev] == SubsteppingType::None) {
          -
          424  amrex::Print() << "No substepping at level " << lev << std::endl;
          -
          425  } else if (substepping_type[lev] == SubsteppingType::Explicit) {
          -
          426  amrex::Print() << "Explicit substepping at level " << lev << std::endl;
          -
          427  } else if (substepping_type[lev] == SubsteppingType::Implicit) {
          -
          428  amrex::Print() << "Implicit substepping at level " << lev << std::endl;
          -
          429  }
          -
          430  }
          -
          431  amrex::Print() << "use_coriolis : " << use_coriolis << std::endl;
          -
          432  amrex::Print() << "use_gravity : " << use_gravity << std::endl;
          -
          433 
          -
          434  if (coupling_type == CouplingType::TwoWay) {
          -
          435  amrex::Print() << "Using two-way coupling " << std::endl;
          -
          436  } else if (coupling_type == CouplingType::OneWay) {
          -
          437  amrex::Print() << "Using one-way coupling " << std::endl;
          -
          438  }
          -
          439 
          -
          440  if (terrain_type == TerrainType::Static) {
          -
          441  amrex::Print() << "Using static terrain " << std::endl;
          -
          442  } else if (terrain_type == TerrainType::Moving) {
          -
          443  amrex::Print() << "Using moving terrain " << std::endl;
          -
          444  } else {
          -
          445  amrex::Print() << "No terrain " << std::endl;
          -
          446  }
          -
          447 
          -
          448  if (abl_driver_type == ABLDriverType::None) {
          -
          449  amrex::Print() << "ABL Driver Type: " << "None" << std::endl;
          -
          450  amrex::Print() << "No ABL driver selected " << std::endl;
          -
          451  } else if (abl_driver_type == ABLDriverType::PressureGradient) {
          -
          452  amrex::Print() << "ABL Driver Type: " << "PressureGradient" << std::endl;
          -
          453  amrex::Print() << "Driving abl_pressure_grad: (";
          -
          454  for (int i = 0; i < AMREX_SPACEDIM; ++i)
          -
          455  amrex::Print() << abl_pressure_grad[i] << " ";
          -
          456  amrex::Print() << ")" << std::endl;
          -
          457  } else if (abl_driver_type == ABLDriverType::GeostrophicWind) {
          -
          458  amrex::Print() << "ABL Driver Type: " << "GeostrophicWind" << std::endl;
          -
          459  amrex::Print() << "Driving abl_geo_forcing: (";
          -
          460  for (int i = 0; i < AMREX_SPACEDIM; ++i)
          -
          461  amrex::Print() << abl_geo_forcing[i] << " ";
          -
          462  amrex::Print() << ")" << std::endl;
          -
          463  }
          -
          464 
          -
          465  amrex::Print() << "Buoyancy_type : " << buoyancy_type << std::endl;
          -
          466 
          -
          467  advChoice.display();
          - - -
          470 
          -
          471  for (int lev = 0; lev <= max_level; lev++) {
          -
          472  turbChoice[lev].display(lev);
          -
          473  }
          -
          474  }
          +
          417  {
          +
          418  amrex::Print() << "SOLVER CHOICE: " << std::endl;
          +
          419  amrex::Print() << "force_stage1_single_substep : " << force_stage1_single_substep << std::endl;
          +
          420  for (int lev = 0; lev <= max_level; lev++) {
          +
          421  amrex::Print() << "anelastic at level : " << lev << " is " << anelastic[lev] << std::endl;
          +
          422  if (substepping_type[lev] == SubsteppingType::None) {
          +
          423  amrex::Print() << "No substepping at level " << lev << std::endl;
          +
          424  } else if (substepping_type[lev] == SubsteppingType::Explicit) {
          +
          425  amrex::Print() << "Explicit substepping at level " << lev << std::endl;
          +
          426  } else if (substepping_type[lev] == SubsteppingType::Implicit) {
          +
          427  amrex::Print() << "Implicit substepping at level " << lev << std::endl;
          +
          428  }
          +
          429  }
          +
          430  amrex::Print() << "use_coriolis : " << use_coriolis << std::endl;
          +
          431  amrex::Print() << "use_gravity : " << use_gravity << std::endl;
          +
          432 
          +
          433  if (coupling_type == CouplingType::TwoWay) {
          +
          434  amrex::Print() << "Using two-way coupling " << std::endl;
          +
          435  } else if (coupling_type == CouplingType::OneWay) {
          +
          436  amrex::Print() << "Using one-way coupling " << std::endl;
          +
          437  }
          +
          438 
          +
          439  if (terrain_type == TerrainType::Static) {
          +
          440  amrex::Print() << "Using static terrain " << std::endl;
          +
          441  } else if (terrain_type == TerrainType::Moving) {
          +
          442  amrex::Print() << "Using moving terrain " << std::endl;
          +
          443  } else {
          +
          444  amrex::Print() << "No terrain " << std::endl;
          +
          445  }
          +
          446 
          +
          447  if (abl_driver_type == ABLDriverType::None) {
          +
          448  amrex::Print() << "ABL Driver Type: " << "None" << std::endl;
          +
          449  amrex::Print() << "No ABL driver selected " << std::endl;
          +
          450  } else if (abl_driver_type == ABLDriverType::PressureGradient) {
          +
          451  amrex::Print() << "ABL Driver Type: " << "PressureGradient" << std::endl;
          +
          452  amrex::Print() << "Driving abl_pressure_grad: (";
          +
          453  for (int i = 0; i < AMREX_SPACEDIM; ++i)
          +
          454  amrex::Print() << abl_pressure_grad[i] << " ";
          +
          455  amrex::Print() << ")" << std::endl;
          +
          456  } else if (abl_driver_type == ABLDriverType::GeostrophicWind) {
          +
          457  amrex::Print() << "ABL Driver Type: " << "GeostrophicWind" << std::endl;
          +
          458  amrex::Print() << "Driving abl_geo_forcing: (";
          +
          459  for (int i = 0; i < AMREX_SPACEDIM; ++i)
          +
          460  amrex::Print() << abl_geo_forcing[i] << " ";
          +
          461  amrex::Print() << ")" << std::endl;
          +
          462  }
          +
          463 
          +
          464  amrex::Print() << "Buoyancy_type : " << buoyancy_type << std::endl;
          +
          465 
          +
          466  advChoice.display();
          + + +
          469 
          +
          470  for (int lev = 0; lev <= max_level; lev++) {
          +
          471  turbChoice[lev].display(lev);
          +
          472  }
          +
          473  }
          void display()
          Definition: ERF_AdvStruct.H:189
          void display()
          Definition: ERF_DiffStruct.H:56
          -
          DiffChoice diffChoice
          Definition: ERF_DataStruct.H:538
          -
          bool use_gravity
          Definition: ERF_DataStruct.H:563
          -
          int force_stage1_single_substep
          Definition: ERF_DataStruct.H:545
          -
          amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_pressure_grad
          Definition: ERF_DataStruct.H:633
          -
          amrex::Vector< SubsteppingType > substepping_type
          Definition: ERF_DataStruct.H:547
          -
          bool use_coriolis
          Definition: ERF_DataStruct.H:564
          -
          amrex::Vector< int > anelastic
          Definition: ERF_DataStruct.H:548
          -
          AdvChoice advChoice
          Definition: ERF_DataStruct.H:537
          -
          SpongeChoice spongeChoice
          Definition: ERF_DataStruct.H:539
          -
          CouplingType coupling_type
          Definition: ERF_DataStruct.H:625
          +
          DiffChoice diffChoice
          Definition: ERF_DataStruct.H:537
          +
          bool use_gravity
          Definition: ERF_DataStruct.H:562
          +
          int force_stage1_single_substep
          Definition: ERF_DataStruct.H:544
          +
          amrex::GpuArray< amrex::Real, AMREX_SPACEDIM > abl_pressure_grad
          Definition: ERF_DataStruct.H:632
          +
          amrex::Vector< SubsteppingType > substepping_type
          Definition: ERF_DataStruct.H:546
          +
          bool use_coriolis
          Definition: ERF_DataStruct.H:563
          +
          amrex::Vector< int > anelastic
          Definition: ERF_DataStruct.H:547
          +
          AdvChoice advChoice
          Definition: ERF_DataStruct.H:536
          +
          SpongeChoice spongeChoice
          Definition: ERF_DataStruct.H:538
          +
          CouplingType coupling_type
          Definition: ERF_DataStruct.H:624
          void display()
          Definition: ERF_SpongeStruct.H:45
          Here is the call graph for this function:
          @@ -651,256 +651,255 @@

          120  RhoQv_comp = RhoQ1_comp;

          122  } else if (moisture_type == MoistureType::Kessler_NoRain) {
          -
          123  moisture_type = MoistureType::Kessler_NoRain;
          - -
          125  }
          -
          126 
          -
          127  // TODO: should we set default for dry??
          -
          128  // Set a different default for moist vs dry
          -
          129  if (moisture_type != MoistureType::None) {
          -
          130  if (moisture_type == MoistureType::Kessler_NoRain ||
          -
          131  moisture_type == MoistureType::SAM ||
          -
          132  moisture_type == MoistureType::SAM_NoIce ||
          -
          133  moisture_type == MoistureType::SAM_NoPrecip_NoIce) {
          -
          134  buoyancy_type = 1; // asserted in make buoyancy
          -
          135  } else {
          -
          136  buoyancy_type = 2; // uses Tprime
          -
          137  }
          -
          138  }
          -
          139 
          -
          140  // Which expression (1,2 or 3) to use for buoyancy
          -
          141  pp.query("buoyancy_type", buoyancy_type);
          -
          142 
          -
          143  // What type of land surface model to use
          -
          144  lsm_type = LandSurfaceType::None; // Default
          -
          145  pp.query_enum_case_insensitive("land_surface_model",lsm_type);
          -
          146 
          -
          147  // Is the terrain static or moving?
          -
          148  terrain_type = (use_terrain) ? TerrainType::Static : TerrainType::None; // Default
          -
          149  if (use_terrain) {
          -
          150  pp.query_enum_case_insensitive("terrain_type",terrain_type);
          -
          151  }
          -
          152 
          -
          153  // Use lagged_delta_rt in the fast integrator?
          -
          154  pp.query("use_lagged_delta_rt", use_lagged_delta_rt);
          -
          155 
          -
          156  // These default to true but are used for unit testing
          -
          157  pp.query("use_gravity", use_gravity);
          - -
          159 
          -
          160  pp.query("c_p", c_p);
          -
          161  rdOcp = R_d / c_p;
          -
          162 
          -
          163  read_int_string(max_level, "anelastic", anelastic, 0);
          -
          164 
          -
          165  // *******************************************************************************
          -
          166  // Read substepping_type and allow for different values at each level
          -
          167  // *******************************************************************************
          -
          168  substepping_type.resize(max_level+1);
          -
          169 
          -
          170  for (int i = 0; i <= max_level; i++) {
          -
          171  substepping_type[i] = SubsteppingType::Implicit;
          -
          172  }
          -
          173 
          -
          174  int nvals = pp.countval("substepping_type");
          -
          175  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
          -
          176 
          -
          177  if (nvals == 1) {
          -
          178  pp.query_enum_case_insensitive("substepping_type",substepping_type[0]);
          -
          179  for (int i = 1; i <= max_level; i++) {
          - -
          181  }
          -
          182  } else if (nvals > 1) { // in this case we have asserted nvals >= max_level+1
          -
          183  for (int i = 0; i <= max_level; i++) {
          -
          184  pp.query_enum_case_insensitive("substepping_type",substepping_type[i],i);
          -
          185  }
          -
          186  }
          -
          187 
          -
          188  // *******************************************************************************
          -
          189  // Error check on deprecated input
          -
          190  // *******************************************************************************
          -
          191  int nvals_old = pp.countval("no_substepping");
          -
          192  if (nvals_old > 0) {
          -
          193  amrex::Abort("The no_substepping flag is deprecated -- set substepping_type instead");
          -
          194  }
          -
          195  // *******************************************************************************
          -
          196 
          -
          197  // Should we project the initial velocity field to make it divergence-free?
          -
          198  pp.query("project_initial_velocity", project_initial_velocity);
          -
          199 
          -
          200  // *******************************************************************************
          -
          201 
          -
          202 #ifdef ERF_USE_POISSON_SOLVE
          -
          203  bool any_anelastic = false;
          -
          204  for (int i = 0; i <= max_level; ++i) {
          -
          205  if (anelastic[i] == 1) any_anelastic = true;
          -
          206  }
          -
          207 
          -
          208  // If anelastic at all, we do not advect rho -- it is always == rho0
          -
          209  if (any_anelastic == 1) {
          -
          210  constant_density = true;
          - -
          212  buoyancy_type = 2; // uses Tprime
          -
          213  } else {
          -
          214  constant_density = false; // We default to false but allow the user to set it
          -
          215  pp.query("constant_density", constant_density);
          -
          216  }
          -
          217 
          -
          218  pp.query("project_every_stage", project_every_stage);
          -
          219  pp.query("ncorr", ncorr);
          -
          220  pp.query("poisson_abstol", poisson_abstol);
          -
          221  pp.query("poisson_reltol", poisson_reltol);
          -
          222 
          -
          223  for (int lev = 0; lev <= max_level; lev++) {
          -
          224  if (anelastic[lev] != 0)
          -
          225  {
          -
          226  substepping_type[lev] = SubsteppingType::None;
          -
          227  }
          -
          228  }
          -
          229 #else
          -
          230  for (int i = 0; i <= max_level; ++i) {
          -
          231  if (anelastic[i] != 0) amrex::Abort("To run with anelastic you must compile with USE_POISSON_SOLVE = TRUE");
          -
          232  }
          - -
          234  amrex::Abort("To project the initial velocity you must compile with USE_POISSON_SOLVE = TRUE");
          -
          235  }
          -
          236 #endif
          -
          237 
          -
          238  pp.query("force_stage1_single_substep", force_stage1_single_substep);
          -
          239 
          -
          240  // Include Coriolis forcing?
          -
          241  pp.query("use_coriolis", use_coriolis);
          -
          242 
          -
          243  // Include Rayleigh damping (separate flags for each variable)
          -
          244  pp.query("rayleigh_damp_U", rayleigh_damp_U);
          -
          245  pp.query("rayleigh_damp_V", rayleigh_damp_V);
          -
          246  pp.query("rayleigh_damp_W", rayleigh_damp_W);
          -
          247  pp.query("rayleigh_damp_T", rayleigh_damp_T);
          -
          248  pp.query("rayleigh_dampcoef", rayleigh_dampcoef);
          -
          249  pp.query("rayleigh_zdamp", rayleigh_zdamp);
          -
          250 
          -
          251  // Flag to do explicit MOST formulation
          -
          252  pp.query("use_explicit_most",use_explicit_most);
          -
          253 
          -
          254  // Flag to do MOST rotations with terrain
          -
          255  pp.query("use_rotate_most",use_rotate_most);
          -
          256  if (use_rotate_most) {
          -
          257  AMREX_ASSERT_WITH_MESSAGE(use_terrain,"MOST stress rotations are only valid with terrain!");
          -
          258  AMREX_ASSERT_WITH_MESSAGE(use_explicit_most, "MOST Stress rotations are only valid with explicit MOST!");
          -
          259  }
          -
          260 
          -
          261  // Which external forcings?
          -
          262  abl_driver_type = ABLDriverType::None; // Default: no ABL driver for simulating classical fluid dynamics problems
          -
          263  pp.query_enum_case_insensitive("abl_driver_type",abl_driver_type);
          -
          264 
          -
          265  // Which type of inflow turbulent generation
          -
          266  pert_type = PerturbationType::None; // Default
          -
          267  pp.query_enum_case_insensitive("perturbation_type",pert_type);
          -
          268 
          -
          269  amrex::Vector<amrex::Real> abl_pressure_grad_in = {0.0, 0.0, 0.0};
          -
          270  pp.queryarr("abl_pressure_grad",abl_pressure_grad_in);
          -
          271  for(int i = 0; i < AMREX_SPACEDIM; ++i) abl_pressure_grad[i] = abl_pressure_grad_in[i];
          -
          272 
          -
          273  amrex::Vector<amrex::Real> abl_geo_forcing_in = {0.0, 0.0, 0.0};
          -
          274  if(pp.queryarr("abl_geo_forcing",abl_geo_forcing_in)) {
          -
          275  amrex::Print() << "Specified abl_geo_forcing: (";
          -
          276  for (int i = 0; i < AMREX_SPACEDIM; ++i) {
          -
          277  abl_geo_forcing[i] = abl_geo_forcing_in[i];
          -
          278  amrex::Print() << abl_geo_forcing[i] << " ";
          -
          279  }
          -
          280  amrex::Print() << ")" << std::endl;
          -
          281  }
          -
          282 
          -
          283  if (use_coriolis)
          -
          284  {
          - -
          286  }
          -
          287 
          -
          288  pp.query("add_custom_rhotheta_forcing", custom_rhotheta_forcing);
          -
          289  pp.query("add_custom_moisture_forcing", custom_moisture_forcing);
          -
          290  pp.query("add_custom_w_subsidence", custom_w_subsidence);
          -
          291  pp.query("add_custom_geostrophic_profile", custom_geostrophic_profile);
          -
          292  pp.query("custom_forcing_uses_primitive_vars", custom_forcing_prim_vars);
          -
          293 
          -
          294  pp.query("nudging_from_input_sounding", nudging_from_input_sounding);
          -
          295 
          - -
          297  AMREX_ALWAYS_ASSERT_WITH_MESSAGE(!(!abl_geo_wind_table.empty() && custom_geostrophic_profile),
          -
          298  "Should not have both abl_geo_wind_table and custom_geostrophic_profile set.");
          -
          299 
          -
          300  pp.query("Ave_Plane", ave_plane);
          -
          301 
          -
          302  pp.query("mp_clouds", do_cloud);
          -
          303  pp.query("mp_precip", do_precip);
          -
          304  pp.query("use_moist_background", use_moist_background);
          -
          305 
          -
          306  // Use numerical diffusion?
          -
          307  pp.query("use_NumDiff",use_NumDiff);
          -
          308  if(use_NumDiff) {
          -
          309  pp.query("NumDiffCoeff",NumDiffCoeff);
          -
          310  AMREX_ASSERT_WITH_MESSAGE(( (NumDiffCoeff >= 0.) && (NumDiffCoeff <= 1.) ),
          -
          311  "Numerical diffusion coefficient must be between 0 & 1.");
          -
          312  NumDiffCoeff *= std::pow(2.0,-6);
          -
          313  }
          -
          314 
          -
          315  // Use monotonic advection?
          -
          316  pp.query("use_mono_adv",use_mono_adv);
          -
          317 
          - - - -
          321 
          -
          322  turbChoice.resize(max_level+1);
          -
          323  for (int lev = 0; lev <= max_level; lev++) {
          -
          324  turbChoice[lev].init_params(lev,max_level);
          -
          325  }
          -
          326 
          -
          327  // YSU PBL: use consistent coriolis frequency
          -
          328  for (int lev = 0; lev <= max_level; lev++) {
          -
          329  if (turbChoice[lev].pbl_ysu_use_consistent_coriolis) {
          -
          330  if (use_coriolis) {
          -
          331  turbChoice[lev].pbl_ysu_coriolis_freq = coriolis_factor * sinphi;
          -
          332  if (lev == 0) {
          -
          333  amrex::Print() << "YSU PBL using ERF coriolis frequency: " << turbChoice[lev].pbl_ysu_coriolis_freq << std::endl;
          -
          334  }
          -
          335  } else {
          -
          336  amrex::Abort("YSU cannot use ERF coriolis frequency if not using coriolis");
          -
          337  }
          -
          338  }
          -
          339  }
          + +
          124  }
          +
          125 
          +
          126  // TODO: should we set default for dry??
          +
          127  // Set a different default for moist vs dry
          +
          128  if (moisture_type != MoistureType::None) {
          +
          129  if (moisture_type == MoistureType::Kessler_NoRain ||
          +
          130  moisture_type == MoistureType::SAM ||
          +
          131  moisture_type == MoistureType::SAM_NoIce ||
          +
          132  moisture_type == MoistureType::SAM_NoPrecip_NoIce) {
          +
          133  buoyancy_type = 1; // asserted in make buoyancy
          +
          134  } else {
          +
          135  buoyancy_type = 2; // uses Tprime
          +
          136  }
          +
          137  }
          +
          138 
          +
          139  // Which expression (1,2 or 3) to use for buoyancy
          +
          140  pp.query("buoyancy_type", buoyancy_type);
          +
          141 
          +
          142  // What type of land surface model to use
          +
          143  lsm_type = LandSurfaceType::None; // Default
          +
          144  pp.query_enum_case_insensitive("land_surface_model",lsm_type);
          +
          145 
          +
          146  // Is the terrain static or moving?
          +
          147  terrain_type = (use_terrain) ? TerrainType::Static : TerrainType::None; // Default
          +
          148  if (use_terrain) {
          +
          149  pp.query_enum_case_insensitive("terrain_type",terrain_type);
          +
          150  }
          +
          151 
          +
          152  // Use lagged_delta_rt in the fast integrator?
          +
          153  pp.query("use_lagged_delta_rt", use_lagged_delta_rt);
          +
          154 
          +
          155  // These default to true but are used for unit testing
          +
          156  pp.query("use_gravity", use_gravity);
          + +
          158 
          +
          159  pp.query("c_p", c_p);
          +
          160  rdOcp = R_d / c_p;
          +
          161 
          +
          162  read_int_string(max_level, "anelastic", anelastic, 0);
          +
          163 
          +
          164  // *******************************************************************************
          +
          165  // Read substepping_type and allow for different values at each level
          +
          166  // *******************************************************************************
          +
          167  substepping_type.resize(max_level+1);
          +
          168 
          +
          169  for (int i = 0; i <= max_level; i++) {
          +
          170  substepping_type[i] = SubsteppingType::Implicit;
          +
          171  }
          +
          172 
          +
          173  int nvals = pp.countval("substepping_type");
          +
          174  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
          +
          175 
          +
          176  if (nvals == 1) {
          +
          177  pp.query_enum_case_insensitive("substepping_type",substepping_type[0]);
          +
          178  for (int i = 1; i <= max_level; i++) {
          + +
          180  }
          +
          181  } else if (nvals > 1) { // in this case we have asserted nvals >= max_level+1
          +
          182  for (int i = 0; i <= max_level; i++) {
          +
          183  pp.query_enum_case_insensitive("substepping_type",substepping_type[i],i);
          +
          184  }
          +
          185  }
          +
          186 
          +
          187  // *******************************************************************************
          +
          188  // Error check on deprecated input
          +
          189  // *******************************************************************************
          +
          190  int nvals_old = pp.countval("no_substepping");
          +
          191  if (nvals_old > 0) {
          +
          192  amrex::Abort("The no_substepping flag is deprecated -- set substepping_type instead");
          +
          193  }
          +
          194  // *******************************************************************************
          +
          195 
          +
          196  // Should we project the initial velocity field to make it divergence-free?
          +
          197  pp.query("project_initial_velocity", project_initial_velocity);
          +
          198 
          +
          199  // *******************************************************************************
          +
          200 
          +
          201 #ifdef ERF_USE_POISSON_SOLVE
          +
          202  bool any_anelastic = false;
          +
          203  for (int i = 0; i <= max_level; ++i) {
          +
          204  if (anelastic[i] == 1) any_anelastic = true;
          +
          205  }
          +
          206 
          +
          207  // If anelastic at all, we do not advect rho -- it is always == rho0
          +
          208  if (any_anelastic == 1) {
          +
          209  constant_density = true;
          + +
          211  buoyancy_type = 2; // uses Tprime
          +
          212  } else {
          +
          213  constant_density = false; // We default to false but allow the user to set it
          +
          214  pp.query("constant_density", constant_density);
          +
          215  }
          +
          216 
          +
          217  pp.query("project_every_stage", project_every_stage);
          +
          218  pp.query("ncorr", ncorr);
          +
          219  pp.query("poisson_abstol", poisson_abstol);
          +
          220  pp.query("poisson_reltol", poisson_reltol);
          +
          221 
          +
          222  for (int lev = 0; lev <= max_level; lev++) {
          +
          223  if (anelastic[lev] != 0)
          +
          224  {
          +
          225  substepping_type[lev] = SubsteppingType::None;
          +
          226  }
          +
          227  }
          +
          228 #else
          +
          229  for (int i = 0; i <= max_level; ++i) {
          +
          230  if (anelastic[i] != 0) amrex::Abort("To run with anelastic you must compile with USE_POISSON_SOLVE = TRUE");
          +
          231  }
          + +
          233  amrex::Abort("To project the initial velocity you must compile with USE_POISSON_SOLVE = TRUE");
          +
          234  }
          +
          235 #endif
          +
          236 
          +
          237  pp.query("force_stage1_single_substep", force_stage1_single_substep);
          +
          238 
          +
          239  // Include Coriolis forcing?
          +
          240  pp.query("use_coriolis", use_coriolis);
          +
          241 
          +
          242  // Include Rayleigh damping (separate flags for each variable)
          +
          243  pp.query("rayleigh_damp_U", rayleigh_damp_U);
          +
          244  pp.query("rayleigh_damp_V", rayleigh_damp_V);
          +
          245  pp.query("rayleigh_damp_W", rayleigh_damp_W);
          +
          246  pp.query("rayleigh_damp_T", rayleigh_damp_T);
          +
          247  pp.query("rayleigh_dampcoef", rayleigh_dampcoef);
          +
          248  pp.query("rayleigh_zdamp", rayleigh_zdamp);
          +
          249 
          +
          250  // Flag to do explicit MOST formulation
          +
          251  pp.query("use_explicit_most",use_explicit_most);
          +
          252 
          +
          253  // Flag to do MOST rotations with terrain
          +
          254  pp.query("use_rotate_most",use_rotate_most);
          +
          255  if (use_rotate_most) {
          +
          256  AMREX_ASSERT_WITH_MESSAGE(use_terrain,"MOST stress rotations are only valid with terrain!");
          +
          257  AMREX_ASSERT_WITH_MESSAGE(use_explicit_most, "MOST Stress rotations are only valid with explicit MOST!");
          +
          258  }
          +
          259 
          +
          260  // Which external forcings?
          +
          261  abl_driver_type = ABLDriverType::None; // Default: no ABL driver for simulating classical fluid dynamics problems
          +
          262  pp.query_enum_case_insensitive("abl_driver_type",abl_driver_type);
          +
          263 
          +
          264  // Which type of inflow turbulent generation
          +
          265  pert_type = PerturbationType::None; // Default
          +
          266  pp.query_enum_case_insensitive("perturbation_type",pert_type);
          +
          267 
          +
          268  amrex::Vector<amrex::Real> abl_pressure_grad_in = {0.0, 0.0, 0.0};
          +
          269  pp.queryarr("abl_pressure_grad",abl_pressure_grad_in);
          +
          270  for(int i = 0; i < AMREX_SPACEDIM; ++i) abl_pressure_grad[i] = abl_pressure_grad_in[i];
          +
          271 
          +
          272  amrex::Vector<amrex::Real> abl_geo_forcing_in = {0.0, 0.0, 0.0};
          +
          273  if(pp.queryarr("abl_geo_forcing",abl_geo_forcing_in)) {
          +
          274  amrex::Print() << "Specified abl_geo_forcing: (";
          +
          275  for (int i = 0; i < AMREX_SPACEDIM; ++i) {
          +
          276  abl_geo_forcing[i] = abl_geo_forcing_in[i];
          +
          277  amrex::Print() << abl_geo_forcing[i] << " ";
          +
          278  }
          +
          279  amrex::Print() << ")" << std::endl;
          +
          280  }
          +
          281 
          +
          282  if (use_coriolis)
          +
          283  {
          + +
          285  }
          +
          286 
          +
          287  pp.query("add_custom_rhotheta_forcing", custom_rhotheta_forcing);
          +
          288  pp.query("add_custom_moisture_forcing", custom_moisture_forcing);
          +
          289  pp.query("add_custom_w_subsidence", custom_w_subsidence);
          +
          290  pp.query("add_custom_geostrophic_profile", custom_geostrophic_profile);
          +
          291  pp.query("custom_forcing_uses_primitive_vars", custom_forcing_prim_vars);
          +
          292 
          +
          293  pp.query("nudging_from_input_sounding", nudging_from_input_sounding);
          +
          294 
          + +
          296  AMREX_ALWAYS_ASSERT_WITH_MESSAGE(!(!abl_geo_wind_table.empty() && custom_geostrophic_profile),
          +
          297  "Should not have both abl_geo_wind_table and custom_geostrophic_profile set.");
          +
          298 
          +
          299  pp.query("Ave_Plane", ave_plane);
          +
          300 
          +
          301  pp.query("mp_clouds", do_cloud);
          +
          302  pp.query("mp_precip", do_precip);
          +
          303  pp.query("use_moist_background", use_moist_background);
          +
          304 
          +
          305  // Use numerical diffusion?
          +
          306  pp.query("use_NumDiff",use_NumDiff);
          +
          307  if(use_NumDiff) {
          +
          308  pp.query("NumDiffCoeff",NumDiffCoeff);
          +
          309  AMREX_ASSERT_WITH_MESSAGE(( (NumDiffCoeff >= 0.) && (NumDiffCoeff <= 1.) ),
          +
          310  "Numerical diffusion coefficient must be between 0 & 1.");
          +
          311  NumDiffCoeff *= std::pow(2.0,-6);
          +
          312  }
          +
          313 
          +
          314  // Use monotonic advection?
          +
          315  pp.query("use_mono_adv",use_mono_adv);
          +
          316 
          + + + +
          320 
          +
          321  turbChoice.resize(max_level+1);
          +
          322  for (int lev = 0; lev <= max_level; lev++) {
          +
          323  turbChoice[lev].init_params(lev,max_level);
          +
          324  }
          +
          325 
          +
          326  // YSU PBL: use consistent coriolis frequency
          +
          327  for (int lev = 0; lev <= max_level; lev++) {
          +
          328  if (turbChoice[lev].pbl_ysu_use_consistent_coriolis) {
          +
          329  if (use_coriolis) {
          +
          330  turbChoice[lev].pbl_ysu_coriolis_freq = coriolis_factor * sinphi;
          +
          331  if (lev == 0) {
          +
          332  amrex::Print() << "YSU PBL using ERF coriolis frequency: " << turbChoice[lev].pbl_ysu_coriolis_freq << std::endl;
          +
          333  }
          +
          334  } else {
          +
          335  amrex::Abort("YSU cannot use ERF coriolis frequency if not using coriolis");
          +
          336  }
          +
          337  }
          +
          338  }
          +
          339 
          340 
          -
          341 
          -
          342  // Which type of multilevel coupling
          -
          343  coupling_type = CouplingType::TwoWay; // Default
          -
          344  pp.query_enum_case_insensitive("coupling_type",coupling_type);
          -
          345 
          -
          346  // Which type of windfarm model
          -
          347  windfarm_type = WindFarmType::None; // Default
          -
          348  pp.query_enum_case_insensitive("windfarm_type",windfarm_type);
          -
          349 
          -
          350  static std::string windfarm_loc_type_string = "None";
          -
          351  windfarm_loc_type = WindFarmLocType::None;
          -
          352  pp.query_enum_case_insensitive("windfarm_loc_type",windfarm_loc_type);
          -
          353 
          -
          354  pp.query("windfarm_loc_table", windfarm_loc_table);
          -
          355  pp.query("windfarm_spec_table", windfarm_spec_table);
          -
          356  pp.query("windfarm_blade_table", windfarm_blade_table);
          -
          357  pp.query("windfarm_airofil_tables", windfarm_airfoil_tables);
          -
          358 
          -
          359  // Sampling distance upstream of the turbine to find the
          -
          360  // incoming free stream velocity as a factor of the diameter of the
          -
          361  // turbine. ie. the sampling distance will be this number multiplied
          -
          362  // by the diameter of the turbine
          -
          363  pp.query("sampling_distance_by_D", sampling_distance_by_D);
          -
          364  pp.query("turb_disk_angle_from_x", turb_disk_angle);
          -
          365 
          -
          366  pp.query("windfarm_x_shift",windfarm_x_shift);
          -
          367  pp.query("windfarm_y_shift",windfarm_y_shift);
          -
          368  // Test if time averaged data is to be output
          -
          369  pp.query("time_avg_vel",time_avg_vel);
          -
          370 
          -
          371  check_params(max_level);
          -
          372  }
          +
          341  // Which type of multilevel coupling
          +
          342  coupling_type = CouplingType::TwoWay; // Default
          +
          343  pp.query_enum_case_insensitive("coupling_type",coupling_type);
          +
          344 
          +
          345  // Which type of windfarm model
          +
          346  windfarm_type = WindFarmType::None; // Default
          +
          347  pp.query_enum_case_insensitive("windfarm_type",windfarm_type);
          +
          348 
          +
          349  static std::string windfarm_loc_type_string = "None";
          +
          350  windfarm_loc_type = WindFarmLocType::None;
          +
          351  pp.query_enum_case_insensitive("windfarm_loc_type",windfarm_loc_type);
          +
          352 
          +
          353  pp.query("windfarm_loc_table", windfarm_loc_table);
          +
          354  pp.query("windfarm_spec_table", windfarm_spec_table);
          +
          355  pp.query("windfarm_blade_table", windfarm_blade_table);
          +
          356  pp.query("windfarm_airofil_tables", windfarm_airfoil_tables);
          +
          357 
          +
          358  // Sampling distance upstream of the turbine to find the
          +
          359  // incoming free stream velocity as a factor of the diameter of the
          +
          360  // turbine. ie. the sampling distance will be this number multiplied
          +
          361  // by the diameter of the turbine
          +
          362  pp.query("sampling_distance_by_D", sampling_distance_by_D);
          +
          363  pp.query("turb_disk_angle_from_x", turb_disk_angle);
          +
          364 
          +
          365  pp.query("windfarm_x_shift",windfarm_x_shift);
          +
          366  pp.query("windfarm_y_shift",windfarm_y_shift);
          +
          367  // Test if time averaged data is to be output
          +
          368  pp.query("time_avg_vel",time_avg_vel);
          +
          369 
          +
          370  check_params(max_level);
          +
          371  }
          constexpr amrex::Real CONST_GRAV
          Definition: ERF_Constants.H:21
          constexpr amrex::Real R_d
          Definition: ERF_Constants.H:10
          #define RhoQ4_comp
          Definition: ERF_IndexDefines.H:46
          @@ -908,54 +907,54 @@

          #define RhoQ1_comp
          Definition: ERF_IndexDefines.H:43

          void init_params()
          Definition: ERF_AdvStruct.H:21
          void init_params()
          Definition: ERF_DiffStruct.H:21
          -
          bool use_terrain
          Definition: ERF_DataStruct.H:558
          -
          bool rayleigh_damp_T
          Definition: ERF_DataStruct.H:570
          -
          amrex::Real dz0
          Definition: ERF_DataStruct.H:586
          -
          bool use_explicit_most
          Definition: ERF_DataStruct.H:607
          -
          bool rayleigh_damp_V
          Definition: ERF_DataStruct.H:568
          -
          int RhoQr_comp
          Definition: ERF_DataStruct.H:649
          -
          amrex::Real poisson_reltol
          Definition: ERF_DataStruct.H:554
          -
          amrex::Real rayleigh_zdamp
          Definition: ERF_DataStruct.H:572
          -
          amrex::Real rdOcp
          Definition: ERF_DataStruct.H:581
          -
          void read_int_string(int max_level, const char *string_to_read, amrex::Vector< int > &vec_to_fill, int default_int)
          Definition: ERF_DataStruct.H:519
          -
          std::string windfarm_spec_table
          Definition: ERF_DataStruct.H:651
          -
          bool use_mono_adv
          Definition: ERF_DataStruct.H:623
          -
          void build_coriolis_forcings()
          Definition: ERF_DataStruct.H:476
          -
          int ncorr
          Definition: ERF_DataStruct.H:552
          -
          LandSurfaceType lsm_type
          Definition: ERF_DataStruct.H:630
          -
          amrex::Real c_p
          Definition: ERF_DataStruct.H:580
          -
          std::string windfarm_loc_table
          Definition: ERF_DataStruct.H:651
          -
          amrex::Real gravity
          Definition: ERF_DataStruct.H:579
          -
          void check_params(int max_level)
          Definition: ERF_DataStruct.H:374
          -
          bool custom_rhotheta_forcing
          Definition: ERF_DataStruct.H:596
          -
          bool custom_w_subsidence
          Definition: ERF_DataStruct.H:598
          -
          bool nudging_from_input_sounding
          Definition: ERF_DataStruct.H:604
          -
          bool rayleigh_damp_U
          Definition: ERF_DataStruct.H:567
          -
          bool custom_geostrophic_profile
          Definition: ERF_DataStruct.H:599
          -
          amrex::Real grid_stretching_ratio
          Definition: ERF_DataStruct.H:584
          -
          bool have_geo_wind_profile
          Definition: ERF_DataStruct.H:636
          -
          amrex::Real NumDiffCoeff
          Definition: ERF_DataStruct.H:620
          -
          bool do_precip
          Definition: ERF_DataStruct.H:641
          -
          int RhoQv_comp
          Definition: ERF_DataStruct.H:643
          -
          bool test_mapfactor
          Definition: ERF_DataStruct.H:556
          -
          bool use_NumDiff
          Definition: ERF_DataStruct.H:619
          -
          bool custom_moisture_forcing
          Definition: ERF_DataStruct.H:597
          -
          std::string windfarm_blade_table
          Definition: ERF_DataStruct.H:652
          -
          amrex::Real zsurf
          Definition: ERF_DataStruct.H:585
          -
          bool project_initial_velocity
          Definition: ERF_DataStruct.H:588
          -
          int constant_density
          Definition: ERF_DataStruct.H:550
          -
          bool use_moist_background
          Definition: ERF_DataStruct.H:642
          -
          bool custom_forcing_prim_vars
          Definition: ERF_DataStruct.H:600
          -
          bool rayleigh_damp_W
          Definition: ERF_DataStruct.H:569
          -
          PerturbationType pert_type
          Definition: ERF_DataStruct.H:616
          -
          amrex::Real poisson_abstol
          Definition: ERF_DataStruct.H:553
          -
          bool time_avg_vel
          Definition: ERF_DataStruct.H:613
          -
          bool do_cloud
          Definition: ERF_DataStruct.H:640
          -
          bool use_rotate_most
          Definition: ERF_DataStruct.H:610
          -
          amrex::Real rayleigh_dampcoef
          Definition: ERF_DataStruct.H:571
          -
          std::string windfarm_airfoil_tables
          Definition: ERF_DataStruct.H:652
          -
          int project_every_stage
          Definition: ERF_DataStruct.H:551
          -
          int ave_plane
          Definition: ERF_DataStruct.H:638
          +
          bool use_terrain
          Definition: ERF_DataStruct.H:557
          +
          bool rayleigh_damp_T
          Definition: ERF_DataStruct.H:569
          +
          amrex::Real dz0
          Definition: ERF_DataStruct.H:585
          +
          bool use_explicit_most
          Definition: ERF_DataStruct.H:606
          +
          bool rayleigh_damp_V
          Definition: ERF_DataStruct.H:567
          +
          int RhoQr_comp
          Definition: ERF_DataStruct.H:648
          +
          amrex::Real poisson_reltol
          Definition: ERF_DataStruct.H:553
          +
          amrex::Real rayleigh_zdamp
          Definition: ERF_DataStruct.H:571
          +
          amrex::Real rdOcp
          Definition: ERF_DataStruct.H:580
          +
          void read_int_string(int max_level, const char *string_to_read, amrex::Vector< int > &vec_to_fill, int default_int)
          Definition: ERF_DataStruct.H:518
          +
          std::string windfarm_spec_table
          Definition: ERF_DataStruct.H:650
          +
          bool use_mono_adv
          Definition: ERF_DataStruct.H:622
          +
          void build_coriolis_forcings()
          Definition: ERF_DataStruct.H:475
          +
          int ncorr
          Definition: ERF_DataStruct.H:551
          +
          LandSurfaceType lsm_type
          Definition: ERF_DataStruct.H:629
          +
          amrex::Real c_p
          Definition: ERF_DataStruct.H:579
          +
          std::string windfarm_loc_table
          Definition: ERF_DataStruct.H:650
          +
          amrex::Real gravity
          Definition: ERF_DataStruct.H:578
          +
          void check_params(int max_level)
          Definition: ERF_DataStruct.H:373
          +
          bool custom_rhotheta_forcing
          Definition: ERF_DataStruct.H:595
          +
          bool custom_w_subsidence
          Definition: ERF_DataStruct.H:597
          +
          bool nudging_from_input_sounding
          Definition: ERF_DataStruct.H:603
          +
          bool rayleigh_damp_U
          Definition: ERF_DataStruct.H:566
          +
          bool custom_geostrophic_profile
          Definition: ERF_DataStruct.H:598
          +
          amrex::Real grid_stretching_ratio
          Definition: ERF_DataStruct.H:583
          +
          bool have_geo_wind_profile
          Definition: ERF_DataStruct.H:635
          +
          amrex::Real NumDiffCoeff
          Definition: ERF_DataStruct.H:619
          +
          bool do_precip
          Definition: ERF_DataStruct.H:640
          +
          int RhoQv_comp
          Definition: ERF_DataStruct.H:642
          +
          bool test_mapfactor
          Definition: ERF_DataStruct.H:555
          +
          bool use_NumDiff
          Definition: ERF_DataStruct.H:618
          +
          bool custom_moisture_forcing
          Definition: ERF_DataStruct.H:596
          +
          std::string windfarm_blade_table
          Definition: ERF_DataStruct.H:651
          +
          amrex::Real zsurf
          Definition: ERF_DataStruct.H:584
          +
          bool project_initial_velocity
          Definition: ERF_DataStruct.H:587
          +
          int constant_density
          Definition: ERF_DataStruct.H:549
          +
          bool use_moist_background
          Definition: ERF_DataStruct.H:641
          +
          bool custom_forcing_prim_vars
          Definition: ERF_DataStruct.H:599
          +
          bool rayleigh_damp_W
          Definition: ERF_DataStruct.H:568
          +
          PerturbationType pert_type
          Definition: ERF_DataStruct.H:615
          +
          amrex::Real poisson_abstol
          Definition: ERF_DataStruct.H:552
          +
          bool time_avg_vel
          Definition: ERF_DataStruct.H:612
          +
          bool do_cloud
          Definition: ERF_DataStruct.H:639
          +
          bool use_rotate_most
          Definition: ERF_DataStruct.H:609
          +
          amrex::Real rayleigh_dampcoef
          Definition: ERF_DataStruct.H:570
          +
          std::string windfarm_airfoil_tables
          Definition: ERF_DataStruct.H:651
          +
          int project_every_stage
          Definition: ERF_DataStruct.H:550
          +
          int ave_plane
          Definition: ERF_DataStruct.H:637
          void init_params()
          Definition: ERF_SpongeStruct.H:17
          Here is the call graph for this function:
          @@ -1021,20 +1020,20 @@

          -
          521  {
          -
          522  amrex::ParmParse pp("erf");
          -
          523  int nvals = pp.countval(string_to_read);
          -
          524  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
          -
          525  amrex::Vector<int> temp; temp.resize(nvals);
          -
          526  pp.queryarr(string_to_read,temp);
          -
          527  if (nvals == 0) {
          -
          528  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(default_int);
          -
          529  } else if (nvals == 1) {
          -
          530  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[0]);
          -
          531  } else {
          -
          532  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[i]);
          -
          533  }
          -
          534  }
          +
          520  {
          +
          521  amrex::ParmParse pp("erf");
          +
          522  int nvals = pp.countval(string_to_read);
          +
          523  AMREX_ALWAYS_ASSERT(nvals == 0 || nvals == 1 || nvals >= max_level+1);
          +
          524  amrex::Vector<int> temp; temp.resize(nvals);
          +
          525  pp.queryarr(string_to_read,temp);
          +
          526  if (nvals == 0) {
          +
          527  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(default_int);
          +
          528  } else if (nvals == 1) {
          +
          529  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[0]);
          +
          530  } else {
          +
          531  for (int i = 0; i <= max_level; ++i) vec_to_fill.push_back(temp[i]);
          +
          532  }
          +
          533  }

          Referenced by init_params().

Private Attributes

(const SolverChoice,
std::vector< int > &  a_idx,
PrecipFall(const SolverChoice &sc)SAM
pres1dSAMprivate
Qmoist_Ptr(const int &varIdx) overrideSAMinlinevirtual
Qmoist_Restart_Vars(std::vector< int > &a_idx, std::vector< std::string > &a_names) const overrideSAMinlinevirtual
Qmoist_Restart_Vars(const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const overrideSAMinlinevirtual
Qmoist_Size() overrideSAMinlinevirtual
qn1dSAMprivate
Qstate_Size() overrideSAMinlinevirtual
 
int Qstate_Size () override
 
void Qmoist_Restart_Vars (std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
 
void Qmoist_Restart_Vars (const SolverChoice &a_sc, std::vector< int > &a_idx, std::vector< std::string > &a_names) const override
 
- Public Member Functions inherited from NullMoist
 NullMoist ()
 
(const SolverChoicea_sc,
std::vector< int > &  a_idx,