ERF
Energy Research and Forecasting: An Atmospheric Modeling Code
ERF_AdvStruct.H
Go to the documentation of this file.
1 #ifndef ERF_ADV_STRUCT_H_
2 #define ERF_ADV_STRUCT_H_
3 
4 #include <string>
5 #include <iostream>
6 
7 #include <AMReX_ParmParse.H>
8 #include <AMReX_Print.H>
9 #include <AMReX_Gpu.H>
10 #include <AMReX_Geometry.H>
11 
12 #include <ERF_Constants.H>
13 #include <ERF_IndexDefines.H>
14 
15 /**
16  * Container holding the advection-related choices
17  */
18 
19 struct AdvChoice {
20  public:
21  /**
22  * @brief Read advection options from the input parameter database.
23  * @param pp_prefix ParmParse prefix for the ERF input namespace.
24  */
25  void init_params(std::string pp_prefix)
26  {
27  amrex::ParmParse pp(pp_prefix);
28 
29  // Order and type of spatial discretizations used in advection
30  pp.query("use_efficient_advection", use_efficient_advection);
31  std::string dycore_horiz_adv_string = "" ; std::string dycore_vert_adv_string = "";
32  std::string dryscal_horiz_adv_string = "" ; std::string dryscal_vert_adv_string = "";
33  pp.query("dycore_horiz_adv_type" , dycore_horiz_adv_string);
34  pp.query("dycore_vert_adv_type" , dycore_vert_adv_string);
35  pp.query("dryscal_horiz_adv_type" , dryscal_horiz_adv_string);
36  pp.query("dryscal_vert_adv_type" , dryscal_vert_adv_string);
37 
38  std::string moistscal_horiz_adv_string = ""; std::string moistscal_vert_adv_string = "";
39  pp.query("moistscal_horiz_adv_type", moistscal_horiz_adv_string);
40  pp.query("moistscal_vert_adv_type" , moistscal_vert_adv_string);
41 
43  amrex::Print() << "Using efficient advection scheme" << std::endl;
44  }
45 
46  if ( (dycore_horiz_adv_string == "Blended_3rd4th") ||
47  (dycore_horiz_adv_string == "Blended_5th6th") )
48  {
49  pp.query("dycore_horiz_upw_frac" , dycore_horiz_upw_frac);
51  "The dycore horizontal upwinding fraction must be between 0 and 1");
52  }
53 
54  if ( (dycore_vert_adv_string == "Blended_3rd4th") ||
55  (dycore_vert_adv_string == "Blended_5th6th") )
56  {
57  pp.query("dycore_vert_upw_frac" , dycore_vert_upw_frac);
59  "The dycore vertical upwinding fraction must be between 0 and 1");
60  }
61 
62  if ( (dryscal_horiz_adv_string == "Blended_3rd4th") ||
63  (dryscal_horiz_adv_string == "Blended_5th6th") )
64  {
65  pp.query("dryscal_horiz_upw_frac" , dryscal_horiz_upw_frac);
67  "The dry scalar horizontal upwinding fraction must be between 0 and 1");
68  }
69 
70  if ( (dryscal_vert_adv_string == "Blended_3rd4th") ||
71  (dryscal_vert_adv_string == "Blended_5th6th") )
72  {
73  pp.query("dryscal_vert_upw_frac" , dryscal_vert_upw_frac);
75  "The dry scalar vertical upwinding fraction must be between 0 and 1");
76  }
77 
78  if ( (moistscal_horiz_adv_string == "Blended_3rd4th") ||
79  (moistscal_horiz_adv_string == "Blended_5th6th") )
80  {
81  pp.query("moistscal_horiz_upw_frac" , moistscal_horiz_upw_frac);
83  "The moist scalar horizontal upwinding fraction must be between 0 and 1");
84  }
85 
86  if ( (moistscal_vert_adv_string == "Blended_3rd4th") ||
87  (moistscal_vert_adv_string == "Blended_5th6th") )
88  {
89  pp.query("moistscal_vert_upw_frac" , moistscal_vert_upw_frac);
91  "The moist scalar vertical upwinding fraction must be between 0 and 1");
92  }
93 
94  if (dycore_horiz_adv_string != "") {
95  if ( (dycore_horiz_adv_string == "Centered_2nd") ||
96  (dycore_horiz_adv_string == "Upwind_3rd" ) ||
97  (dycore_horiz_adv_string == "Blended_3rd4th") ||
98  (dycore_horiz_adv_string == "Centered_4th") ||
99  (dycore_horiz_adv_string == "Upwind_5th" ) ||
100  (dycore_horiz_adv_string == "Blended_5th6th") ||
101  (dycore_horiz_adv_string == "Centered_6th") ||
102  (dycore_horiz_adv_string == "WENO3" ) ||
103  (dycore_horiz_adv_string == "WENOZ3" ) ||
104  (dycore_horiz_adv_string == "WENO5" ) ||
105  (dycore_horiz_adv_string == "WENOZ5" ) ||
106  (dycore_horiz_adv_string == "WENO7" ) ||
107  (dycore_horiz_adv_string == "WENOZ7" ))
108  {
110  } else {
111  amrex::Error("Don't know this dycore_horiz_adv_string");
112  }
113  }
114 
115  if (dycore_vert_adv_string != "") {
116  if ( (dycore_vert_adv_string == "Centered_2nd") ||
117  (dycore_vert_adv_string == "Upwind_3rd" ) ||
118  (dycore_vert_adv_string == "Blended_3rd4th") ||
119  (dycore_vert_adv_string == "Centered_4th") ||
120  (dycore_vert_adv_string == "Upwind_5th" ) ||
121  (dycore_vert_adv_string == "Blended_5th6th") ||
122  (dycore_vert_adv_string == "Centered_6th") ||
123  (dycore_vert_adv_string == "WENO3" ) ||
124  (dycore_vert_adv_string == "WENOZ3" ) ||
125  (dycore_vert_adv_string == "WENO5" ) ||
126  (dycore_vert_adv_string == "WENOZ5" ) ||
127  (dycore_vert_adv_string == "WENO7" ) ||
128  (dycore_vert_adv_string == "WENOZ7" ))
129  {
131  } else {
132  amrex::Error("Don't know this dycore_vert_adv_string");
133  }
134  }
135 
136  if (dryscal_horiz_adv_string != "") {
137  if ( (dryscal_horiz_adv_string == "Centered_2nd") ||
138  (dryscal_horiz_adv_string == "Upwind_3rd" ) ||
139  (dryscal_horiz_adv_string == "Upwind_3rd_SL") ||
140  (dryscal_horiz_adv_string == "Blended_3rd4th") ||
141  (dryscal_horiz_adv_string == "Centered_4th") ||
142  (dryscal_horiz_adv_string == "Upwind_5th" ) ||
143  (dryscal_horiz_adv_string == "Blended_5th6th") ||
144  (dryscal_horiz_adv_string == "Centered_6th") ||
145  (dryscal_horiz_adv_string == "WENO3" ) ||
146  (dryscal_horiz_adv_string == "WENOZ3" ) ||
147  (dryscal_horiz_adv_string == "WENOMZQ3" ) ||
148  (dryscal_horiz_adv_string == "WENO5" ) ||
149  (dryscal_horiz_adv_string == "WENOZ5" ) ||
150  (dryscal_horiz_adv_string == "WENO7" ) ||
151  (dryscal_horiz_adv_string == "WENOZ7" ) )
152  {
154  } else {
155  amrex::Error("Don't know this dryscal_horiz_adv_string");
156  }
157  }
158 
159  if (dryscal_vert_adv_string != "") {
160  if ( (dryscal_vert_adv_string == "Centered_2nd") ||
161  (dryscal_vert_adv_string == "Upwind_3rd" ) ||
162  (dryscal_vert_adv_string == "Upwind_3rd_SL") ||
163  (dryscal_vert_adv_string == "Blended_3rd4th") ||
164  (dryscal_vert_adv_string == "Centered_4th") ||
165  (dryscal_vert_adv_string == "Upwind_5th" ) ||
166  (dryscal_vert_adv_string == "Blended_5th6th") ||
167  (dryscal_vert_adv_string == "Centered_6th") ||
168  (dryscal_vert_adv_string == "WENO3" ) ||
169  (dryscal_vert_adv_string == "WENOZ3" ) ||
170  (dryscal_vert_adv_string == "WENOMZQ3" ) ||
171  (dryscal_vert_adv_string == "WENO5" ) ||
172  (dryscal_vert_adv_string == "WENOZ5" ) ||
173  (dryscal_vert_adv_string == "WENO7" ) ||
174  (dryscal_vert_adv_string == "WENOZ7" ))
175  {
177  } else {
178  amrex::Error("Don't know this dryscal_vert_adv_string");
179  }
180  }
181 
182  if (moistscal_horiz_adv_string != "") {
183  if ( (moistscal_horiz_adv_string == "Centered_2nd") ||
184  (moistscal_horiz_adv_string == "Upwind_3rd" ) ||
185  (moistscal_horiz_adv_string == "Upwind_3rd_SL" ) ||
186  (moistscal_horiz_adv_string == "Blended_3rd4th") ||
187  (moistscal_horiz_adv_string == "Centered_4th") ||
188  (moistscal_horiz_adv_string == "Upwind_5th" ) ||
189  (moistscal_horiz_adv_string == "Blended_5th6th") ||
190  (moistscal_horiz_adv_string == "Centered_6th") ||
191  (moistscal_horiz_adv_string == "WENO3" ) ||
192  (moistscal_horiz_adv_string == "WENOZ3" ) ||
193  (moistscal_horiz_adv_string == "WENOMZQ3" ) ||
194  (moistscal_horiz_adv_string == "WENO5" ) ||
195  (moistscal_horiz_adv_string == "WENOZ5" ) ||
196  (moistscal_horiz_adv_string == "WENO7" ) ||
197  (moistscal_horiz_adv_string == "WENOZ7" ))
198  {
199  moistscal_horiz_adv_type = adv_type_convert_string_to_advtype(moistscal_horiz_adv_string);
200  } else {
201  amrex::Error("Don't know this moistscal_horiz_adv_string");
202  }
203  }
204 
205  if (moistscal_vert_adv_string != "") {
206  if ( (moistscal_vert_adv_string == "Centered_2nd") ||
207  (moistscal_vert_adv_string == "Upwind_3rd" ) ||
208  (moistscal_vert_adv_string == "Upwind_3rd_SL" ) ||
209  (moistscal_vert_adv_string == "Blended_3rd4th") ||
210  (moistscal_vert_adv_string == "Centered_4th") ||
211  (moistscal_vert_adv_string == "Upwind_5th" ) ||
212  (moistscal_vert_adv_string == "Blended_5th6th") ||
213  (moistscal_vert_adv_string == "Centered_6th") ||
214  (moistscal_vert_adv_string == "WENO3" ) ||
215  (moistscal_vert_adv_string == "WENOZ3" ) ||
216  (moistscal_vert_adv_string == "WENOMZQ3" ) ||
217  (moistscal_vert_adv_string == "WENO5" ) ||
218  (moistscal_vert_adv_string == "WENOZ5" ) ||
219  (moistscal_vert_adv_string == "WENO7" ) ||
220  (moistscal_vert_adv_string == "WENOZ7" ))
221  {
222  moistscal_vert_adv_type = adv_type_convert_string_to_advtype(moistscal_vert_adv_string);
223  } else {
224  amrex::Error("Don't know this moistscal_vert_adv_string");
225  }
226  }
227 
228  // We can can't use weno with Embedded Boundaries (for now)
229  std::string terrain_type;
230  pp.query("terrain_type", terrain_type);
231  validate_weno_momentum_compatibility(terrain_type == "EB");
232 
233  pp.queryarr("zero_xflux_faces", zero_xflux);
234  pp.queryarr("zero_yflux_faces", zero_yflux);
235  pp.queryarr("zero_zflux_faces", zero_zflux);
236  have_zero_flux_faces = ((zero_xflux.size() > 0) || (zero_yflux.size() > 0) || (zero_zflux.size() > 0));
237  }
238 
239  /**
240  * @brief Print the configured advection choices.
241  * @param pp_prefix ParmParse prefix used to recover input strings for display.
242  */
243  void display(std::string& pp_prefix)
244  {
245  amrex::Print() << "Advection Choices: " << std::endl;
246 
247  // We read these again here just as a convenience to avoid passing them
248  amrex::ParmParse pp(pp_prefix);
249  std::string dycore_horiz_adv_string = "" ; std::string dycore_vert_adv_string = "";
250  std::string dryscal_horiz_adv_string = "" ; std::string dryscal_vert_adv_string = "";
251  pp.query("dycore_horiz_adv_type" , dycore_horiz_adv_string);
252  pp.query("dycore_vert_adv_type" , dycore_vert_adv_string);
253  pp.query("dryscal_horiz_adv_type" , dryscal_horiz_adv_string);
254  pp.query("dryscal_vert_adv_type" , dryscal_vert_adv_string);
255  std::string moistscal_horiz_adv_string = ""; std::string moistscal_vert_adv_string = "";
256  pp.query("moistscal_horiz_adv_type", moistscal_horiz_adv_string);
257  pp.query("moistscal_vert_adv_type" , moistscal_vert_adv_string);
258 
259  if (dycore_horiz_adv_string != "") {
260  amrex::Print() << " dycore_horiz_adv_type : " << dycore_horiz_adv_string;
261  } else {
262  amrex::Print() << " dycore_horiz_adv_type : " << adv_type_convert_int_to_string(dycore_horiz_adv_type);
263  }
264  if ( (dycore_horiz_adv_string == "Blended_3rd4th") ||
265  (dycore_horiz_adv_string == "Blended_5th6th") ) {
266  amrex::Print() << " with " << 100*dycore_horiz_upw_frac << "% upwinding";
267  }
268  amrex::Print() << std::endl;
269 
270  if (dycore_vert_adv_string != "") {
271  amrex::Print() << " dycore_vert_adv_type : " << dycore_vert_adv_string;
272  } else {
273  amrex::Print() << " dycore_vert_adv_type : " << adv_type_convert_int_to_string(dycore_vert_adv_type);
274  }
275  if ( (dycore_vert_adv_string == "Blended_3rd4th") ||
276  (dycore_vert_adv_string == "Blended_5th6th") ) {
277  amrex::Print() << " with " << 100*dycore_vert_upw_frac << "% upwinding";
278  }
279  amrex::Print() << std::endl;
280 
281  if (dryscal_horiz_adv_string != "") {
282  amrex::Print() << " dryscal_horiz_adv_type : " << dryscal_horiz_adv_string;
283  } else {
284  amrex::Print() << " dryscal_horiz_adv_type : " << adv_type_convert_int_to_string(dryscal_horiz_adv_type);
285  }
286  if ( (dryscal_horiz_adv_string == "Blended_3rd4th") ||
287  (dryscal_horiz_adv_string == "Blended_5th6th") ) {
288  amrex::Print() << " with " << 100*dryscal_horiz_upw_frac << "% upwinding";
289  }
290  amrex::Print() << std::endl;
291 
292  if (dryscal_vert_adv_string != "") {
293  amrex::Print() << " dryscal_vert_adv_type : " << dryscal_vert_adv_string;
294  } else {
295  amrex::Print() << " dryscal_vert_adv_type : " << adv_type_convert_int_to_string(dryscal_vert_adv_type);
296  }
297  if ( (dryscal_vert_adv_string == "Blended_3rd4th") ||
298  (dryscal_vert_adv_string == "Blended_5th6th") ) {
299  amrex::Print() << " with " << 100*dryscal_vert_upw_frac << "% upwinding";
300  }
301  amrex::Print() << std::endl;
302 
303  if (moistscal_horiz_adv_string != "") {
304  amrex::Print() << " moistscal_horiz_adv_type : " << moistscal_horiz_adv_string;
305  } else {
306  amrex::Print() << " moistscal_horiz_adv_type : " << adv_type_convert_int_to_string(moistscal_horiz_adv_type);
307  }
308  if ( (moistscal_horiz_adv_string == "Blended_3rd4th") ||
309  (moistscal_horiz_adv_string == "Blended_5th6th") ) {
310  amrex::Print() << " with " << 100*moistscal_horiz_upw_frac << "% upwinding";
311  }
312  amrex::Print() << std::endl;
313 
314  if (moistscal_vert_adv_string != "") {
315  amrex::Print() << " moistscal_vert_adv_type : " << moistscal_vert_adv_string;
316  } else {
317  amrex::Print() << " moistscal_vert_adv_type : " << adv_type_convert_int_to_string(moistscal_vert_adv_type);
318  }
319  if ( (moistscal_vert_adv_string == "Blended_3rd4th") ||
320  (moistscal_vert_adv_string == "Blended_5th6th") ) {
321  amrex::Print() << " with " << 100*moistscal_vert_upw_frac << "% upwinding";
322  }
323  amrex::Print() << std::endl;
324  }
325 
326  /**
327  * @brief Convert an advection type enum to the corresponding input string.
328  * @param adv_int Advection type enum value.
329  * @return String representation of the advection type.
330  */
331  std::string
333  {
334  if (adv_int == AdvType::Centered_2nd) {
335  return "Centered_2nd";
336  } else if (adv_int == AdvType::Upwind_3rd) {
337  return "Upwind_3rd";
338  } else if (adv_int == AdvType::Upwind_3rd_SL) {
339  return "Upwind_3rd_SL";
340  } else if (adv_int == AdvType::Centered_4th) {
341  return "Centered_4th";
342  } else if (adv_int == AdvType::Upwind_5th) {
343  return "Upwind_5th";
344  } else if (adv_int == AdvType::Centered_6th) {
345  return "Centered_6th";
346  } else if (adv_int == AdvType::Weno_3) {
347  return "WENO3";
348  } else if (adv_int == AdvType::Weno_3Z) {
349  return "WENOZ3";
350  } else if (adv_int == AdvType::Weno_5) {
351  return "WENO5";
352  } else if (adv_int == AdvType::Weno_5Z) {
353  return "WENOZ5";
354  } else if (adv_int == AdvType::Weno_3MZQ) {
355  return "WENOMZQ3";
356  } else if (adv_int == AdvType::Weno_7) {
357  return "WENO7";
358  } else if (adv_int == AdvType::Weno_7Z) {
359  return "WENOZ7";
360  } else {
361  return "Unknown";
362  }
363  }
364 
365  /**
366  * @brief Convert an input advection string to the corresponding enum value.
367  * @param adv_string User-facing advection type string.
368  * @return Matching advection type, or AdvType::Unknown if no match is found.
369  */
371  {
372  if (adv_string == "Centered_2nd") {
373  return AdvType::Centered_2nd;
374  } else if ((adv_string == "Upwind_3rd") || (adv_string == "Blended_3rd4th")) {
375  return AdvType::Upwind_3rd;
376  } else if (adv_string == "Upwind_3rd_SL") {
377  return AdvType::Upwind_3rd_SL;
378  } else if (adv_string == "Centered_4th") {
379  return AdvType::Centered_4th;
380  } else if (adv_string == "Upwind_5th" || (adv_string == "Blended_5th6th")) {
381  return AdvType::Upwind_5th;
382  } else if (adv_string == "Centered_6th") {
383  return AdvType::Centered_6th;
384  } else if (adv_string == "WENO3") {
385  return AdvType::Weno_3;
386  } else if (adv_string == "WENOZ3") {
387  return AdvType::Weno_3Z;
388  } else if (adv_string == "WENO5") {
389  return AdvType::Weno_5;
390  } else if (adv_string == "WENOZ5") {
391  return AdvType::Weno_5Z;
392  } else if (adv_string == "WENOMZQ3") {
393  return AdvType::Weno_3MZQ;
394  } else if (adv_string == "WENO7") {
395  return AdvType::Weno_7;
396  } else if (adv_string == "WENOZ7") {
397  return AdvType::Weno_7Z;
398  } else {
399  return AdvType::Unknown;
400  }
401  }
402 
403  /**
404  * @brief Check whether the selected momentum WENO schemes are compatible with embedded boundaries.
405  * @param use_embedded_boundary Whether the run uses embedded-boundary terrain.
406  */
407  void validate_weno_momentum_compatibility(bool use_embedded_boundary)
408  {
409  // Check if any WENO momentum advection is being used
410  bool using_weno_momentum =
425 
426  // Check embedded boundary incompatibility
427  amrex::ignore_unused(use_embedded_boundary, using_weno_momentum);
428  AMREX_ASSERT_WITH_MESSAGE(!using_weno_momentum || !use_embedded_boundary,
429  "WENO momentum advection schemes are not yet implemented for embedded boundaries. "
430  "Please use traditional momentum advection schemes when using embedded boundaries:\n"
431  " - Centered_2nd\n"
432  " - Upwind_3rd\n"
433  " - Centered_4th\n"
434  " - Upwind_5th\n"
435  " - Centered_6th");
436  }
437 
438  // Order and type of spatial discretizations used in advection
439  // Defaults given below but these can be over-written at run-time
447 
448  // Blending between upwind and the next-highest order central scheme
449  // Note: This is used by both Upwind_* and Blended_* schemes -- the default
450  // is a pure upwind scheme
457 
458  // Thin immersed bodies
459  amrex::Vector<amrex::IntVect> zero_xflux;
460  amrex::Vector<amrex::IntVect> zero_yflux;
461  amrex::Vector<amrex::IntVect> zero_zflux;
462  bool have_zero_flux_faces = false;
463 };
464 
465 /**
466  * @var AdvChoice::use_efficient_advection
467  * @brief Whether to use the efficient advection implementation.
468  * @var AdvChoice::dycore_horiz_adv_type
469  * @brief Horizontal advection scheme for dynamical-core variables.
470  * @var AdvChoice::dycore_vert_adv_type
471  * @brief Vertical advection scheme for dynamical-core variables.
472  * @var AdvChoice::dryscal_horiz_adv_type
473  * @brief Horizontal advection scheme for dry scalar variables.
474  * @var AdvChoice::dryscal_vert_adv_type
475  * @brief Vertical advection scheme for dry scalar variables.
476  * @var AdvChoice::moistscal_horiz_adv_type
477  * @brief Horizontal advection scheme for moist scalar variables.
478  * @var AdvChoice::moistscal_vert_adv_type
479  * @brief Vertical advection scheme for moist scalar variables.
480  * @var AdvChoice::dycore_horiz_upw_frac
481  * @brief Upwind blending fraction for horizontal dynamical-core advection.
482  * @var AdvChoice::dycore_vert_upw_frac
483  * @brief Upwind blending fraction for vertical dynamical-core advection.
484  * @var AdvChoice::dryscal_horiz_upw_frac
485  * @brief Upwind blending fraction for horizontal dry scalar advection.
486  * @var AdvChoice::dryscal_vert_upw_frac
487  * @brief Upwind blending fraction for vertical dry scalar advection.
488  * @var AdvChoice::moistscal_horiz_upw_frac
489  * @brief Upwind blending fraction for horizontal moist scalar advection.
490  * @var AdvChoice::moistscal_vert_upw_frac
491  * @brief Upwind blending fraction for vertical moist scalar advection.
492  * @var AdvChoice::zero_xflux
493  * @brief Thin immersed-body x-face indices where fluxes are forced to zero.
494  * @var AdvChoice::zero_yflux
495  * @brief Thin immersed-body y-face indices where fluxes are forced to zero.
496  * @var AdvChoice::zero_zflux
497  * @brief Thin immersed-body z-face indices where fluxes are forced to zero.
498  * @var AdvChoice::have_zero_flux_faces
499  * @brief Whether any zero-flux thin immersed-body faces were specified.
500  */
501 #endif
constexpr amrex::Real one
Definition: ERF_Constants.H:9
constexpr amrex::Real zero
Definition: ERF_Constants.H:8
AdvType
Definition: ERF_IndexDefines.H:261
@ Upwind_3rd_SL
@ Centered_4th
@ Centered_6th
@ Centered_2nd
ParmParse pp("prob")
amrex::Real Real
Definition: ERF_ShocInterface.H:19
AMREX_ASSERT_WITH_MESSAGE(wbar_cutoff_min > wbar_cutoff_max, "ERROR: wbar_cutoff_min < wbar_cutoff_max")
Definition: ERF_AdvStruct.H:19
amrex::Real dryscal_horiz_upw_frac
Upwind blending fraction for horizontal dry scalar advection.
Definition: ERF_AdvStruct.H:453
void display(std::string &pp_prefix)
Print the configured advection choices.
Definition: ERF_AdvStruct.H:243
void init_params(std::string pp_prefix)
Read advection options from the input parameter database.
Definition: ERF_AdvStruct.H:25
bool have_zero_flux_faces
Whether any zero-flux thin immersed-body faces were specified.
Definition: ERF_AdvStruct.H:462
void validate_weno_momentum_compatibility(bool use_embedded_boundary)
Check whether the selected momentum WENO schemes are compatible with embedded boundaries.
Definition: ERF_AdvStruct.H:407
AdvType adv_type_convert_string_to_advtype(std::string adv_string)
Convert an input advection string to the corresponding enum value.
Definition: ERF_AdvStruct.H:370
AdvType dycore_vert_adv_type
Vertical advection scheme for dynamical-core variables.
Definition: ERF_AdvStruct.H:442
AdvType moistscal_vert_adv_type
Vertical advection scheme for moist scalar variables.
Definition: ERF_AdvStruct.H:446
amrex::Vector< amrex::IntVect > zero_yflux
Thin immersed-body y-face indices where fluxes are forced to zero.
Definition: ERF_AdvStruct.H:460
AdvType dryscal_horiz_adv_type
Horizontal advection scheme for dry scalar variables.
Definition: ERF_AdvStruct.H:443
amrex::Real moistscal_horiz_upw_frac
Upwind blending fraction for horizontal moist scalar advection.
Definition: ERF_AdvStruct.H:455
amrex::Vector< amrex::IntVect > zero_zflux
Thin immersed-body z-face indices where fluxes are forced to zero.
Definition: ERF_AdvStruct.H:461
bool use_efficient_advection
Whether to use the efficient advection implementation.
Definition: ERF_AdvStruct.H:440
amrex::Vector< amrex::IntVect > zero_xflux
Thin immersed-body x-face indices where fluxes are forced to zero.
Definition: ERF_AdvStruct.H:459
AdvType dycore_horiz_adv_type
Horizontal advection scheme for dynamical-core variables.
Definition: ERF_AdvStruct.H:441
AdvType moistscal_horiz_adv_type
Horizontal advection scheme for moist scalar variables.
Definition: ERF_AdvStruct.H:445
amrex::Real dycore_vert_upw_frac
Upwind blending fraction for vertical dynamical-core advection.
Definition: ERF_AdvStruct.H:452
amrex::Real moistscal_vert_upw_frac
Upwind blending fraction for vertical moist scalar advection.
Definition: ERF_AdvStruct.H:456
amrex::Real dycore_horiz_upw_frac
Upwind blending fraction for horizontal dynamical-core advection.
Definition: ERF_AdvStruct.H:451
std::string adv_type_convert_int_to_string(AdvType adv_int)
Convert an advection type enum to the corresponding input string.
Definition: ERF_AdvStruct.H:332
amrex::Real dryscal_vert_upw_frac
Upwind blending fraction for vertical dry scalar advection.
Definition: ERF_AdvStruct.H:454
AdvType dryscal_vert_adv_type
Vertical advection scheme for dry scalar variables.
Definition: ERF_AdvStruct.H:444