diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ff9879fb3..792679e4b 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -22,9 +22,9 @@ jobs: runs-on: ${{matrix.os}} strategy: matrix: - os: [ubuntu-latest] + os: [ubuntu-22.04] include: - - os: ubuntu-latest + - os: ubuntu-22.04 install_deps: sudo apt-get install mpich libmpich-dev comp: gnu procs: $(nproc) diff --git a/CMake/BuildERFExe.cmake b/CMake/BuildERFExe.cmake index dc4888ff7..113125f33 100644 --- a/CMake/BuildERFExe.cmake +++ b/CMake/BuildERFExe.cmake @@ -190,6 +190,7 @@ function(build_erf_lib erf_lib_name) ${SRC_DIR}/Utils/ERF_MomentumToVelocity.cpp ${SRC_DIR}/LinearSolvers/ERF_PoissonSolve.cpp ${SRC_DIR}/LinearSolvers/ERF_PoissonSolve_tb.cpp + ${SRC_DIR}/LinearSolvers/ERF_PoissonWallDist.cpp ${SRC_DIR}/LinearSolvers/ERF_ComputeDivergence.cpp ${SRC_DIR}/LinearSolvers/ERF_SolveWithGMRES.cpp ${SRC_DIR}/LinearSolvers/ERF_SolveWithMLMG.cpp diff --git a/CMake/SetAmrexOptions.cmake b/CMake/SetAmrexOptions.cmake index 038e3f0ab..ad1c504dc 100644 --- a/CMake/SetAmrexOptions.cmake +++ b/CMake/SetAmrexOptions.cmake @@ -29,7 +29,7 @@ set(AMReX_FORTRAN OFF) set(AMReX_LINEAR_SOLVERS ON) set(AMReX_LINEAR_SOLVERS_EM OFF) -set(AMReX_LINEAR_SOLVERS_INCFLO OFF) +set(AMReX_LINEAR_SOLVERS_INCFLO ON) set(AMReX_PARTICLES OFF) if(ERF_ENABLE_PARTICLES) diff --git a/Docs/sphinx_doc/BestPractices.rst b/Docs/sphinx_doc/BestPractices.rst index 8c80505e4..ce487b5a6 100644 --- a/Docs/sphinx_doc/BestPractices.rst +++ b/Docs/sphinx_doc/BestPractices.rst @@ -45,41 +45,61 @@ Large-Eddy Simulations * Time Integration - Split timestepping offers some computational cost savings but still does - not allow you to run with an incompressible/anelastic time-step size. - - The acoustic CFL should be less than 0.5, with 4--6 fast timesteps - (substeps) according to WRF best practices. + not allow you to run with an incompressible/anelastic time-step size in + general. + - The acoustic CFL should conservatively be less than or equal to 0.5, with + 4--6 fast timesteps (substeps) according to WRF best practices. If not + explicitly specified (through ``erf.fixed_mri_dt_ratio`` or + ``erf.fixed_fast_dt``, the number of substeps in ERF is chosen based on the + same algorithm as WRF. If the user follows the recommendation that + dt [s] ~ 6 dx [km], + then 4 substeps will be used, giving an effective CFL of approximately 0.5. + This meets the stability criteria from Wicker & Skamarock 2002 that, for a + 5th-order scheme, the CFL be less than 1.42/sqrt(3) = 0.820. .. code-block:: python erf.fixed_dt = 0.06 # slow timestep # These are equivalent and result in a fixed fast timestep size - # if dx=10, speed of sound ~ 350 m/s - erf.fixed_fast_dt = 0.01 # ==> CFL~0.35 - #erf.fixed_mri_dt_ratio = 6 - - # Alternatively, let ERF chose the fast timestep - #erf.cfl = 0.5 - - - We note that ERF LESs with up to 10 fast timesteps have successfully been + # if dx=10, speed of sound ~ 300 m/s + erf.fixed_mri_dt_ratio = 4 + # or + #erf.fixed_fast_dt = 0.015 # ==> CFL~0.45 + # or, let ERF chose the fast timestep + #erf.substepping_cfl = 0.5 + + - Following the WRF guidelines for dt is conservative. More aggressive time + integration--i.e., larger time steps with more substeps--is possible. We + note that ERF LESs with 10 or more fast timesteps have successfully been run but your mileage may vary. Single-Column Model ------------------- -* Currently, ERF does not have the ability to run a true single-column model - (SCM). The grid size in the lateral directions must have a minimum number of - cells. This will give comparable results, e.g.: +* An SCM is set up with a single cell in the lateral directions: .. code-block:: python geometry.prob_extent = 400 400 400 - amr.n_cell = 2 2 64 + amr.n_cell = 1 1 64 geometry.is_periodic = 1 1 0 - When set up this way, the solution is not sensitive to horizontal problem - extent. - * An SCM was successfully run with third-order advection in the horizontal and vertical. + + +2-D Cases +--------- + +* A 2-D planar domain can be configured as follows: + + .. code-block:: python + + geometry.prob_extent = 10000 100 1000 + amr.n_cell = 100 1 20 + geometry.is_periodic = 0 0 0 + + ylo.type = "SlipWall" + yhi.type = "SlipWall" diff --git a/Docs/sphinx_doc/CouplingToNoahMP.rst b/Docs/sphinx_doc/CouplingToNoahMP.rst new file mode 100644 index 000000000..4e86dd997 --- /dev/null +++ b/Docs/sphinx_doc/CouplingToNoahMP.rst @@ -0,0 +1,99 @@ + .. role:: cpp(code) + :language: c++ + +Coupling to Noah-MP +=================== + +Overview +-------- + +The NOAH Land Surface Model (LSM) is integrated with ERF to facilitate +interaction with the Noah-MP (Multi-Physics) land surface processes. + +This documentation covers key components of this interface and its +associated data structures and routines, which are implemented in C++ +and Fortran, and provides details on initialization and management of +data structures necessary for these processes. + +Files Overview +-------------- + +- **Source/LandSurfaceModel/NOAH/ERF_NOAH.H**: Contains the declaration + of the NOAH class, which extends the NullSurf. + +- **Source/LandSurfaceModel/NOAH/ERF_NOAH.cpp**: Implements the + initialization routine for the NOAH class. + +- **Submodules/NOAH-MP/drivers/hrldas/NoahmpIO.H**: Defines the C++ + `NoahmpIO_type` that is used to interface with Noah-MP implementations + following similar structure as the underlying Fortran interface + (https://dx.doi.org/10.5065/ew8g-yr95). + +- **Submodules/NOAH-MP/drivers/hrldas/NoahmpIO.cpp**: Contains the + implementation of C++ routines interfacing with Fortran. + +- **Submodules/NOAH-MP/drivers/hrldas/NoahmpIO_fi.F90**: Fortran module + responsible for managing mapping data between C++ and Fortran. + +NOAH Class +---------- + +The NOAH class serves as the handler for initializing and managing the +data structures required for NOAH-MP operations. It inherits from the +`NullSurf` class. This class declares private variable `NoahmpIO_type +noahmpio`, that is passed to NoahMP routines similar to the Fortran +interface in the Noah-MP documentation +(https://dx.doi.org/10.5065/ew8g-yr95) + +NoahmpIO_type Structure +----------------------- + +This structure is key for handling the input and output operations for +NOAH-MP through C++ and Fortran interoperation. Contains various +variables for domain, memory, and tile configuration. Also, contains +arrays for geographic variables. At present this type exposes only a +select set of variables. More variables should be exposed as needed by +applications in ERF. The process of adding new variables is as follows: + +#. In **Submodules/NOAH-MP/drivers/hrldas/NoahmpIO.H** add pointers to + the desired variable and set their initialization for + `NoahmpIO_type_fi` similar to implementation of `WSLAKEXY` and + `XLAT`. + +#. In **Submodules/NOAH-MP/drivers/hrldas/NoahmpIO.H** declare objects + for Fortran-style multidimensional arrays for the same variables in + `NoahmpIO_type` similar to implemnation of `NoahArray2D XLAT` + and `NoahArray2D WSLAKEXY`. + +#. In **Submodules/NOAH-MP/drivers/hrldas/NoahmpIO.cpp** cast the + pointers from `NoahmpIO_type_fi` to multidimensional arrays in + `NoahmpIO_type` within the implementation of `void + NoahmpIOVarInitDefault(NoahmpIO_type* noahmpio)`. + +Fortran Interoperability +------------------------ + +The connection between C++ and Fortran is managed through `NoahmpIO_fi`. +This module contains a mirroring of the C++ structure for NOAH-MP +input-output operations. + +The following functions are used to operate on the `NoahmpIO_type` and +interface with their respective Fortran implementations: + +- `void NoahmpIOVarInitDefault(NoahmpIO_type* noahmpio)`: Initializes + default variables of `NoahmpIO_type`. Create C pointer for Fortran + data. + +- `void NoahmpInitMain(NoahmpIO_type* noahmpio)`: Main initialization + function for the NOAH-MP operations in C++. + +Usage +----- + +To use the NOAH class and associated functions, ensure the correct +initialization sequence is followed within the simulation setup. The +interplay between C++ and Fortran necessitates careful memory and data +handling, which is crucial for ensuring performance and correctness in +simulations. The interface is designed to mimic the Fortran interface +from documentation(https://dx.doi.org/10.5065/ew8g-yr95), therefore +similar practices should be followed. diff --git a/Docs/sphinx_doc/Inputs.rst b/Docs/sphinx_doc/Inputs.rst index abf362ad9..1755bf6ce 100644 --- a/Docs/sphinx_doc/Inputs.rst +++ b/Docs/sphinx_doc/Inputs.rst @@ -906,7 +906,7 @@ List of Parameters | | viscosity and | "Constant", or | | | | diffusivity? | "ConstantAlpha" | | +----------------------------------+--------------------+---------------------+--------------+ -| **erf.dynamicViscosity** | Viscous coeff. if | Real | 0.0 | +| **erf.dynamic_viscosity** | Viscous coeff. if | Real | 0.0 | | | DNS | | | +----------------------------------+--------------------+---------------------+--------------+ | **erf.Cs** | Constant | Real | 0.0 | @@ -918,13 +918,11 @@ List of Parameters | **erf.Sc_t** | Turbulent Schmidt | Real | 1.0 | | | Number | | | +----------------------------------+--------------------+---------------------+--------------+ -| **erf.use_NumDiff** | Use 6th order | "true", | "false" | -| | numerical diffusion| "false" | | -| | | | | -+----------------------------------+--------------------+---------------------+--------------+ -| **erf.NumDiffCoeff** | Coefficient for | Real | 0.0 | -| | 6th order | [0.0, 1.0] | | -| | numerical diffusion| | | +| **erf.num_diff_coeff** | Coefficient for | Real | 0.0 | +| | 6th-order | [0.0, 1.0] | | +| | numerical | | | +| | diffusion, set to 0| | | +| | to disable | | | +----------------------------------+--------------------+---------------------+--------------+ Note: in the equations for the evolution of momentum, potential temperature and advected scalars, the @@ -1089,11 +1087,32 @@ List of Parameters | **erf.coriolis_3d** | Include z component in | true / false | true | | | the Coriolis forcing | | | +-------------------------------------+------------------------+-------------------+---------------------+ -| **erf.use_rayleigh_damping** | Include explicit | true / false | false | -| | Rayleigh damping | | | +| **erf.rayleigh_damp_U** | Include explicit | true / false | false | +| | Rayleigh damping in | | | +| | the x-momentum equation| | | ++-------------------------------------+------------------------+-------------------+---------------------+ +| **erf.rayleigh_damp_V** | Include explicit | true / false | false | +| | Rayleigh damping in | | | +| | the y-momentum equation| | | ++-------------------------------------+------------------------+-------------------+---------------------+ +| **erf.rayleigh_damp_W** | Include explicit | true / false | false | +| | Rayleigh damping in | | | +| | the z-momentum equation| | | +-------------------------------------+------------------------+-------------------+---------------------+ -| **erf.nudging_from_input_sounding** | Include explicit | true / false | false | -| | Rayleigh damping | | | +| **erf.rayleigh_damp_T** | Include explicit | true / false | false | +| | Rayleigh damping in | | | +| | the potential | | | +| | temperature equation | | | ++-------------------------------------+------------------------+-------------------+---------------------+ +| **erf.rayleigh_dampcoef** | Rayleigh damping | Real | 0.2 | +| | coefficient, an inverse| | | +| | timescale | | | ++-------------------------------------+------------------------+-------------------+---------------------+ +| **erf.nudging_from_input_sounding** | Add momentum source | true / false | false | +| | terms to nudge the | | | +| | solution towards the | | | +| | initial sounding | | | +| | profile | | | +-------------------------------------+------------------------+-------------------+---------------------+ | **erf.input_sounding_file** | Name(s) of the | String(s) | input_sounding_file | | | input sounding file(s) | | | diff --git a/Docs/sphinx_doc/Plotfiles.rst b/Docs/sphinx_doc/Plotfiles.rst index 322e813a9..8ed70f2af 100644 --- a/Docs/sphinx_doc/Plotfiles.rst +++ b/Docs/sphinx_doc/Plotfiles.rst @@ -187,19 +187,13 @@ Output Options | | | | | | +-----------------------------+------------------+ -| **KE** | Kinetic energy | -| | | -| | | -+-----------------------------+------------------+ -| **QKE** | Turbulent | +| **KE** | SGS turbulent | | | kinetic energy | -| | * 2 | -+-----------------------------+------------------+ -| **rhoKE** | Density * KE | -| | | +| | (from Deardorff | +| | or MYNN) | | | | +-----------------------------+------------------+ -| **rhoQKE** | Density * QKE | +| **rhoKE** | Density * KE | | | | | | | +-----------------------------+------------------+ @@ -263,6 +257,9 @@ Output Options | | mass points | | | | +-----------------------------+------------------+ +| **nut** | Eddy viscosity, | +| | nu_t | ++-----------------------------+------------------+ | **Kmv** | Vertical | | | Eddy Diffusivity | | | of Momentum | @@ -270,6 +267,12 @@ Output Options | **Kmh** | Horizontal | | | Eddy Diffusivity | | | of Momentum | +| | (Note: For LES, | +| | this is the | +| | _dynamic_ eddy | +| | viscosity, mu_t | +| | = rho * nu_t | +| | and Kmh==Kmv) | +-----------------------------+------------------+ | **Khv** | Vertical | | | Eddy Diffusivity | diff --git a/Docs/sphinx_doc/index.rst b/Docs/sphinx_doc/index.rst index 2bf6db61d..58da0f419 100644 --- a/Docs/sphinx_doc/index.rst +++ b/Docs/sphinx_doc/index.rst @@ -88,6 +88,7 @@ In addition to this documentation, there is API documentation for ERF generated CouplingToAMRWind.rst CouplingToWW3.rst + CouplingToNoahMP.rst .. toctree:: :caption: ERF vs WRF diff --git a/Exec/ABL/ERF_Prob.H b/Exec/ABL/ERF_Prob.H index 30d904589..4e005f280 100644 --- a/Exec/ABL/ERF_Prob.H +++ b/Exec/ABL/ERF_Prob.H @@ -11,7 +11,8 @@ struct ProbParm : ProbParmDefaults { amrex::Real rho_0 = 0.0; amrex::Real T_0 = 0.0; amrex::Real A_0 = 1.0; - amrex::Real KE_0 = 0.1; + amrex::Real KE_0 = 0.1; // initialize to calculated rho_hse times input KE + amrex::Real rhoKE_0 = -1; // alternatively, initialize to specified (rho*KE) amrex::Real KE_decay_height = -1; amrex::Real KE_decay_order = 1; diff --git a/Exec/ABL/ERF_Prob.cpp b/Exec/ABL/ERF_Prob.cpp index d55164d73..5b6bc94f9 100644 --- a/Exec/ABL/ERF_Prob.cpp +++ b/Exec/ABL/ERF_Prob.cpp @@ -17,6 +17,7 @@ Problem::Problem(const amrex::Real* problo, const amrex::Real* probhi) pp.query("T_0", parms.T_0); pp.query("A_0", parms.A_0); pp.query("KE_0", parms.KE_0); + pp.query("rhoKE_0", parms.rhoKE_0); pp.query("KE_decay_height", parms.KE_decay_height); pp.query("KE_decay_order", parms.KE_decay_order); @@ -126,7 +127,11 @@ Problem::init_custom_pert( // Set an initial value for SGS KE if (state_pert.nComp() > RhoKE_comp) { // Deardorff - state_pert(i, j, k, RhoKE_comp) = r_hse(i,j,k) * parms_d.KE_0; + if (parms_d.rhoKE_0 > 0) { + state_pert(i, j, k, RhoKE_comp) = parms_d.rhoKE_0; + } else { + state_pert(i, j, k, RhoKE_comp) = r_hse(i,j,k) * parms_d.KE_0; + } if (parms_d.KE_decay_height > 0) { // scale initial SGS kinetic energy with height state_pert(i, j, k, RhoKE_comp) *= max( diff --git a/Exec/ABL/inputs.read b/Exec/ABL/inputs.read index f56b3157d..8e00b9380 100644 --- a/Exec/ABL/inputs.read +++ b/Exec/ABL/inputs.read @@ -45,8 +45,6 @@ erf.plot_int_1 = 100 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs.write b/Exec/ABL/inputs.write index a449e3aa6..e70f5bf38 100644 --- a/Exec/ABL/inputs.write +++ b/Exec/ABL/inputs.write @@ -38,8 +38,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_DataSampler b/Exec/ABL/inputs_DataSampler index ac46484c4..86d2b129b 100644 --- a/Exec/ABL/inputs_DataSampler +++ b/Exec/ABL/inputs_DataSampler @@ -48,8 +48,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_GABLS1_deardorff b/Exec/ABL/inputs_GABLS1_deardorff index 31ab03dad..3e32c1aec 100644 --- a/Exec/ABL/inputs_GABLS1_deardorff +++ b/Exec/ABL/inputs_GABLS1_deardorff @@ -76,12 +76,11 @@ erf.les_type = "Deardorff" erf.Ck = 0.1 # Coefficient in Moeng1984, Eqn. 19 erf.Ce = 0.7 # Note: Ce_lcoeff = C_e - 1.9*C_k erf.Ce_wall = 3.9 # To account for "wall effects" -erf.sigma_k = 0.5 # TKE diffusion coeff = 2*Km = Km * inv_sigma_k, Moeng1984, Eqn. 15 -erf.rayleigh_damp_U = true -erf.rayleigh_damp_V = true +erf.rayleigh_damp_U = false +erf.rayleigh_damp_V = false erf.rayleigh_damp_W = true -erf.rayleigh_damp_T = true +erf.rayleigh_damp_T = false erf.rayleigh_dampcoef = 0.2 # [1/s] following FastEddy erf.rayleigh_zdamp = 100. # from Beare et al. 2006, "most models applied gravity wave damping above 300 m" diff --git a/Exec/ABL/inputs_canopy b/Exec/ABL/inputs_canopy index 01bf340c8..a339f35cf 100644 --- a/Exec/ABL/inputs_canopy +++ b/Exec/ABL/inputs_canopy @@ -36,8 +36,6 @@ erf.plot_int_1 = 50 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_deardorff b/Exec/ABL/inputs_deardorff index 233f76208..23d37f3fc 100644 --- a/Exec/ABL/inputs_deardorff +++ b/Exec/ABL/inputs_deardorff @@ -35,30 +35,27 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoKE rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" erf.les_type = "Deardorff" -erf.Ck = 0.1 -erf.sigma_k = 1.0 -erf.Ce = 0.1 +erf.Ck = 0.1 # Coefficient in Moeng1984, Eqn. 19 +erf.Ce = 0.7 # Note: Ce_lcoeff = C_e - 1.9*C_k +erf.Ce_wall = 3.9 # To account for "wall effects" erf.init_type = "uniform" -erf.KE_0 = 0.1 # for Deardorff -# PROBLEM PARAMETERS +# PROBLEM PARAMETERS -- set these for uniform init only prob.rho_0 = 1.0 -prob.A_0 = 1.0 - -prob.U_0 = 10.0 -prob.V_0 = 0.0 -prob.W_0 = 0.0 -prob.T_0 = 300.0 +prob.A_0 = 1.0 # advected scalar +prob.U_0 = 10.0 +prob.V_0 = 0.0 +prob.W_0 = 0.0 +prob.T_0 = 300.0 +prob.KE_0 = 0.1 # Higher values of perturbations lead to instability # Instability seems to be coming from BC prob.U_0_Pert_Mag = 0.08 -prob.V_0_Pert_Mag = 0.08 # +prob.V_0_Pert_Mag = 0.08 prob.W_0_Pert_Mag = 0.0 diff --git a/Exec/ABL/inputs_deardorff_msf b/Exec/ABL/inputs_deardorff_msf index 45c41b2fd..1ec1196f4 100644 --- a/Exec/ABL/inputs_deardorff_msf +++ b/Exec/ABL/inputs_deardorff_msf @@ -38,31 +38,27 @@ erf.plot_int_1 = 1 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoKE rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta scalar # SOLVER CHOICE -erf.alpha_T = 1.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "Constant" +erf.molec_diff_type = "None" erf.les_type = "Deardorff" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 75.0 -erf.Ck = 0.1 -erf.sigma_k = 1.0 -erf.Ce = 0.1 +erf.Ck = 0.1 # Coefficient in Moeng1984, Eqn. 19 +erf.Ce = 0.7 # Note: Ce_lcoeff = C_e - 1.9*C_k +erf.Ce_wall = 3.9 # To account for "wall effects" erf.init_type = "uniform" -erf.KE_0 = 0.1 # for Deardorff -# PROBLEM PARAMETERS +# PROBLEM PARAMETERS -- set these for uniform init only prob.rho_0 = 1.0 -prob.A_0 = 1.0 - -prob.U_0 = 10.0 -prob.V_0 = 0.0 -prob.W_0 = 0.0 +prob.A_0 = 1.0 # advected scalar +prob.U_0 = 10.0 +prob.V_0 = 0.0 +prob.W_0 = 0.0 +prob.T_0 = 300.0 +prob.KE_0 = 0.1 # Higher values of perturbations lead to instability # Instability seems to be coming from BC prob.U_0_Pert_Mag = 0.08 -prob.V_0_Pert_Mag = 0.08 # +prob.V_0_Pert_Mag = 0.08 prob.W_0_Pert_Mag = 0.0 diff --git a/Exec/ABL/inputs_deardorff_no_msf b/Exec/ABL/inputs_deardorff_no_msf index 1df07410c..456182744 100644 --- a/Exec/ABL/inputs_deardorff_no_msf +++ b/Exec/ABL/inputs_deardorff_no_msf @@ -37,31 +37,27 @@ erf.plot_int_1 = 1 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoKE rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta scalar # SOLVER CHOICE -erf.alpha_T = 1.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "Constant" +erf.molec_diff_type = "None" erf.les_type = "Deardorff" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 75.0 -erf.Ck = 0.1 -erf.sigma_k = 1.0 -erf.Ce = 0.1 +erf.Ck = 0.1 # Coefficient in Moeng1984, Eqn. 19 +erf.Ce = 0.7 # Note: Ce_lcoeff = C_e - 1.9*C_k +erf.Ce_wall = 3.9 # To account for "wall effects" erf.init_type = "uniform" -erf.KE_0 = 0.1 # for Deardorff -# PROBLEM PARAMETERS +# PROBLEM PARAMETERS -- set these for uniform init only prob.rho_0 = 1.0 -prob.A_0 = 1.0 - -prob.U_0 = 10.0 -prob.V_0 = 0.0 -prob.W_0 = 0.0 +prob.A_0 = 1.0 # advected scalar +prob.U_0 = 10.0 +prob.V_0 = 0.0 +prob.W_0 = 0.0 +prob.T_0 = 300.0 +prob.KE_0 = 0.1 # Higher values of perturbations lead to instability # Instability seems to be coming from BC prob.U_0_Pert_Mag = 0.08 -prob.V_0_Pert_Mag = 0.08 # +prob.V_0_Pert_Mag = 0.08 prob.W_0_Pert_Mag = 0.0 diff --git a/Exec/ABL/inputs_most b/Exec/ABL/inputs_most index 930c35411..5a25428df 100644 --- a/Exec/ABL/inputs_most +++ b/Exec/ABL/inputs_most @@ -39,8 +39,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_most_bomex b/Exec/ABL/inputs_most_bomex index 7fac147d8..57a0cff9f 100644 --- a/Exec/ABL/inputs_most_bomex +++ b/Exec/ABL/inputs_most_bomex @@ -43,8 +43,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta qv qc qp # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_most_pbl b/Exec/ABL/inputs_most_pbl index 151c1e8fe..c46ef5854 100644 --- a/Exec/ABL/inputs_most_pbl +++ b/Exec/ABL/inputs_most_pbl @@ -42,8 +42,6 @@ erf.plot_int_1 = 100 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_numdiff b/Exec/ABL/inputs_numdiff index 157ba78f2..e59b0ac37 100644 --- a/Exec/ABL/inputs_numdiff +++ b/Exec/ABL/inputs_numdiff @@ -35,33 +35,29 @@ erf.plot_int_1 = 1 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoKE rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" erf.les_type = "Deardorff" -erf.Ck = 0.1 -erf.sigma_k = 1.0 -erf.Ce = 0.1 +erf.Ck = 0.1 # Coefficient in Moeng1984, Eqn. 19 +erf.Ce = 0.7 # Note: Ce_lcoeff = C_e - 1.9*C_k +erf.Ce_wall = 3.9 # To account for "wall effects" -erf.use_NumDiff = true -erf.NumDiffCoeff = 0.5 +erf.num_diff_coeff = 0.5 erf.init_type = "uniform" -erf.KE_0 = 0.1 # for Deardorff -# PROBLEM PARAMETERS +# PROBLEM PARAMETERS -- set these for uniform init only prob.rho_0 = 1.0 -prob.A_0 = 1.0 - -prob.U_0 = 10.0 -prob.V_0 = 0.0 -prob.W_0 = 0.0 -prob.T_0 = 300.0 +prob.A_0 = 1.0 # advected scalar +prob.U_0 = 10.0 +prob.V_0 = 0.0 +prob.W_0 = 0.0 +prob.T_0 = 300.0 +prob.KE_0 = 0.1 # Higher values of perturbations lead to instability # Instability seems to be coming from BC prob.U_0_Pert_Mag = 0.08 -prob.V_0_Pert_Mag = 0.08 +prob.V_0_Pert_Mag = 0.08 prob.W_0_Pert_Mag = 0.0 diff --git a/Exec/ABL/inputs_omp b/Exec/ABL/inputs_omp index 99b1c8a04..7fb3cfe1d 100644 --- a/Exec/ABL/inputs_omp +++ b/Exec/ABL/inputs_omp @@ -43,13 +43,10 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 - erf.les_type = "None" -erf.Ck = 0.1 -erf.sigma_k = 1.0 -erf.Ce = 0.1 + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 erf.init_type = "uniform" diff --git a/Exec/ABL/inputs_sample b/Exec/ABL/inputs_sample index bc5659681..b3d05eae5 100644 --- a/Exec/ABL/inputs_sample +++ b/Exec/ABL/inputs_sample @@ -43,8 +43,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_smagorinsky b/Exec/ABL/inputs_smagorinsky index e9d8122ba..ca5d96661 100644 --- a/Exec/ABL/inputs_smagorinsky +++ b/Exec/ABL/inputs_smagorinsky @@ -35,8 +35,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/ABL/inputs_smagorinsky_msf b/Exec/ABL/inputs_smagorinsky_msf index 28064400d..5ac87fa36 100644 --- a/Exec/ABL/inputs_smagorinsky_msf +++ b/Exec/ABL/inputs_smagorinsky_msf @@ -42,11 +42,12 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 erf.les_type = "Smagorinsky" erf.Cs = 0.1 +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 + erf.init_type = "uniform" # PROBLEM PARAMETERS diff --git a/Exec/ABL/inputs_smagorinsky_no_msf b/Exec/ABL/inputs_smagorinsky_no_msf index fffe9717b..db272e42d 100644 --- a/Exec/ABL/inputs_smagorinsky_no_msf +++ b/Exec/ABL/inputs_smagorinsky_no_msf @@ -41,11 +41,12 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 erf.les_type = "Smagorinsky" erf.Cs = 0.1 +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 + erf.init_type = "uniform" # PROBLEM PARAMETERS diff --git a/Exec/ABL/inputs_vel_avg b/Exec/ABL/inputs_vel_avg index 9b114b86d..39ab85970 100644 --- a/Exec/ABL/inputs_vel_avg +++ b/Exec/ABL/inputs_vel_avg @@ -36,30 +36,27 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoKE rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta u_t_avg v_t_avg w_t_avg umag_t_avg # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" erf.les_type = "Deardorff" -erf.Ck = 0.1 -erf.sigma_k = 1.0 -erf.Ce = 0.1 +erf.Ck = 0.1 # Coefficient in Moeng1984, Eqn. 19 +erf.Ce = 0.7 # Note: Ce_lcoeff = C_e - 1.9*C_k +erf.Ce_wall = 3.9 # To account for "wall effects" erf.init_type = "uniform" -erf.KE_0 = 0.1 # for Deardorff -# PROBLEM PARAMETERS +# PROBLEM PARAMETERS -- set these for uniform init only prob.rho_0 = 1.0 -prob.A_0 = 1.0 - -prob.U_0 = 10.0 -prob.V_0 = 0.0 -prob.W_0 = 0.0 -prob.T_0 = 300.0 +prob.A_0 = 1.0 # advected scalar +prob.U_0 = 10.0 +prob.V_0 = 0.0 +prob.W_0 = 0.0 +prob.T_0 = 300.0 +prob.KE_0 = 0.1 # Higher values of perturbations lead to instability # Instability seems to be coming from BC prob.U_0_Pert_Mag = 0.08 -prob.V_0_Pert_Mag = 0.08 # +prob.V_0_Pert_Mag = 0.08 prob.W_0_Pert_Mag = 0.0 diff --git a/Exec/DevTests/ABL_with_WW3/inputs_mpmd b/Exec/DevTests/ABL_with_WW3/inputs_mpmd index 78e6e6650..26c3c7b46 100644 --- a/Exec/DevTests/ABL_with_WW3/inputs_mpmd +++ b/Exec/DevTests/ABL_with_WW3/inputs_mpmd @@ -35,8 +35,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false erf.molec_diff_type = "None" diff --git a/Exec/DevTests/EB_Test/inputs b/Exec/DevTests/EB_Test/inputs index 75e3e23f7..99ed8fa5e 100644 --- a/Exec/DevTests/EB_Test/inputs +++ b/Exec/DevTests/EB_Test/inputs @@ -61,7 +61,6 @@ erf.les_type = "None" erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.alpha_T = 0.0 erf.alpha_C = 0.0 diff --git a/Exec/DevTests/LandSurfaceModel/inputs b/Exec/DevTests/LandSurfaceModel/inputs index 0f0edb4c8..3071486a9 100644 --- a/Exec/DevTests/LandSurfaceModel/inputs +++ b/Exec/DevTests/LandSurfaceModel/inputs @@ -47,15 +47,12 @@ erf.plot_vars_1 = density rhotheta rhoadv_0 x_velocity y_velocity z_velocity erf.plot_lsm = true # SOLVER CHOICE -erf.alpha_T = 1.0 -erf.alpha_C = 1.0 erf.use_gravity = true erf.molec_diff_type = "None" erf.les_type = "Smagorinsky" erf.Cs = 0.1 #erf.pbl_type = "MYNN2.5" -#erf.KE_0 = 0.5 erf.terrain_type = Static erf.terrain_smoothing = 2 diff --git a/Exec/DevTests/MetGrid/inputs b/Exec/DevTests/MetGrid/inputs index e9ceff45d..c0e1ebc86 100644 --- a/Exec/DevTests/MetGrid/inputs +++ b/Exec/DevTests/MetGrid/inputs @@ -47,8 +47,6 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density dens_hse rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta z_phys mapfac pres_hse pert_pres # SOLVER CHOICE -erf.alpha_T = 1.0 -erf.alpha_C = 1.0 erf.use_gravity = true erf.molec_diff_type = "None" diff --git a/Exec/DevTests/MetGrid/inputs_flowmas_metgrid b/Exec/DevTests/MetGrid/inputs_flowmas_metgrid index cfef82545..ffbb9f27e 100644 --- a/Exec/DevTests/MetGrid/inputs_flowmas_metgrid +++ b/Exec/DevTests/MetGrid/inputs_flowmas_metgrid @@ -43,8 +43,6 @@ erf.plot_int_1 = 25 # number of timesteps between plotfiles erf.plot_vars_1 = density dens_hse rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta z_phys mapfac pres_hse dens_hse pert_pres pert_dens rhoQ1 rhoQ2 rhoQ3 qv qc # SOLVER CHOICE -erf.alpha_T = 1.0 -erf.alpha_C = 1.0 erf.use_gravity = true erf.molec_diff_type = "None" diff --git a/Exec/DevTests/MetGrid/inputs_flowmas_metgrid_NoZlev b/Exec/DevTests/MetGrid/inputs_flowmas_metgrid_NoZlev index 0e0f6ed8a..9fc1aa4e7 100644 --- a/Exec/DevTests/MetGrid/inputs_flowmas_metgrid_NoZlev +++ b/Exec/DevTests/MetGrid/inputs_flowmas_metgrid_NoZlev @@ -39,8 +39,6 @@ erf.plot_int_1 = 25 # number of timesteps between plotfiles erf.plot_vars_1 = density dens_hse rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta z_phys mapfac pres_hse dens_hse pert_pres pert_dens rhoQ1 rhoQ2 rhoQ3 qv qc # SOLVER CHOICE -erf.alpha_T = 1.0 -erf.alpha_C = 1.0 erf.use_gravity = true erf.molec_diff_type = "None" diff --git a/Exec/DevTests/MetGrid/inputs_flowmas_wrfinput b/Exec/DevTests/MetGrid/inputs_flowmas_wrfinput index 597c4a240..1ed9e17ce 100644 --- a/Exec/DevTests/MetGrid/inputs_flowmas_wrfinput +++ b/Exec/DevTests/MetGrid/inputs_flowmas_wrfinput @@ -43,8 +43,6 @@ erf.plot_int_1 = 25 # number of timesteps between plotfiles erf.plot_vars_1 = density dens_hse rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta z_phys mapfac pres_hse dens_hse pert_pres pert_dens rhoQ1 rhoQ2 rhoQ3 qv qc # SOLVER CHOICE -erf.alpha_T = 1.0 -erf.alpha_C = 1.0 erf.use_gravity = true erf.molec_diff_type = None diff --git a/Exec/DevTests/MultiBlock/inputs_crse_periodic b/Exec/DevTests/MultiBlock/inputs_crse_periodic index 163966991..60ea1a086 100644 --- a/Exec/DevTests/MultiBlock/inputs_crse_periodic +++ b/Exec/DevTests/MultiBlock/inputs_crse_periodic @@ -11,7 +11,7 @@ geometry.prob_lo = -25600. 0. 0. geometry.prob_hi = 25600. 400. 6400. amr.n_cell = 2048 4 256 # dx=dy=dz=25 m, Straka et al 1993 / Xue et al 2000 -amr.n_cell = 512 4 64 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 512 4 64 # dx=dy=dz=100 m # periodic in x to match WRF setup # - as an alternative, could use symmetry at x=0 and outflow at x=25600 @@ -20,8 +20,8 @@ zlo.type = "SlipWall" zhi.type = "SlipWall" # TIME STEP CONTROL -erf.fixed_dt = 1.0 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.25 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 1.0 # fixed time step [s] +erf.fixed_fast_dt = 0.25 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -45,13 +45,13 @@ erf.use_gravity = true erf.use_coriolis = false erf.les_type = "None" + # # diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] # PROBLEM PARAMETERS (optional) prob.T_0 = 300.0 diff --git a/Exec/DevTests/MultiBlock/inputs_erf1 b/Exec/DevTests/MultiBlock/inputs_erf1 index 0c6d6cf85..f442b6cd5 100644 --- a/Exec/DevTests/MultiBlock/inputs_erf1 +++ b/Exec/DevTests/MultiBlock/inputs_erf1 @@ -41,10 +41,9 @@ erf1.use_coriolis = false erf1.les_type = "None" # DIFFUSION COEFF -erf1.molec_diff_type = "ConstantAlpha" -erf1.rho0_trans = 1.0 -erf1.dynamicViscosity = 75.0 -erf1.alpha_T = 75.0 +erf1.molec_diff_type = "ConstantAlpha" +erf1.dynamic_viscosity = 75.0 +erf1.alpha_T = 75.0 # PROBLEM PARAMETERS (optional) prob.T_0 = 300.0 diff --git a/Exec/DevTests/MultiBlock/inputs_erf2 b/Exec/DevTests/MultiBlock/inputs_erf2 index 8646032b0..61cc692ac 100644 --- a/Exec/DevTests/MultiBlock/inputs_erf2 +++ b/Exec/DevTests/MultiBlock/inputs_erf2 @@ -41,10 +41,9 @@ erf2.use_coriolis = false erf2.les_type = "None" # DIFFUSION COEFF -erf2.molec_diff_type = "ConstantAlpha" -erf2.rho0_trans = 1.0 -erf2.dynamicViscosity = 75.0 -erf2.alpha_T = 75.0 +erf2.molec_diff_type = "ConstantAlpha" +erf2.dynamic_viscosity = 75.0 +erf2.alpha_T = 75.0 # PROBLEM PARAMETERS (optional) prob.T_0 = 300.0 diff --git a/Exec/DevTests/Radiation/inputs_radiation b/Exec/DevTests/Radiation/inputs_radiation index 12fcd8e87..3683db5d0 100644 --- a/Exec/DevTests/Radiation/inputs_radiation +++ b/Exec/DevTests/Radiation/inputs_radiation @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 2048 1024 2048 # PROBLEM SIZE & GEOMETRY geometry.prob_lo = -25600. 0. 0. geometry.prob_hi = 25600. 400. 12800. -amr.n_cell = 128 4 32 # dx=dy=dz=100 m +amr.n_cell = 128 4 32 # periodic in x to match WRF setup # - as an alternative, could use symmetry at x=0 and outflow at x=25600 @@ -18,8 +18,8 @@ zlo.type = "SlipWall" zhi.type = "SlipWall" # TIME STEP CONTROL -erf.fixed_dt = 1.0 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.25 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 1.0 # fixed time step [s] +erf.fixed_fast_dt = 0.25 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -47,18 +47,15 @@ erf.use_coriolis = false erf.moisture_model = "SAM" erf.les_type = "Deardorff" -erf.KE_0 = 0.1 # for Deardorff -#erf.les_type = "None" -# -# diffusion coefficient from Straka, K = 75 m^2/s -# + #erf.molec_diff_type = "ConstantAlpha" erf.molec_diff_type = "None" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +#erf.dynamic_viscosity = 75.0 # [kg/(m-s)] +#erf.alpha_T = 75.0 # [m^2/s] # PROBLEM PARAMETERS (optional) prob.T_0 = 300.0 prob.U_0 = 0 +prob.KE_0 = 0.1 + prob.T_pert = 3 diff --git a/Exec/DevTests/TropicalCyclone/inputs b/Exec/DevTests/TropicalCyclone/inputs index 7373205bc..68020847a 100644 --- a/Exec/DevTests/TropicalCyclone/inputs +++ b/Exec/DevTests/TropicalCyclone/inputs @@ -65,9 +65,8 @@ erf.pbl_type = "MYNN2.5" erf.advect_KE = false erf.les_type = "None" erf.molec_diff_type = "None" -#erf.molec_diff_type = "Constant" -#erf.dynamicViscosity = 0.0 # 5.0 -#erf.Cs = 0.16 +#erf.molec_diff_type = "Constant" +#erf.dynamic_viscosity = 0.0 #5.0 erf.dycore_horiz_adv_type = "Upwind_5th" erf.dycore_vert_adv_type = "Upwind_3rd" diff --git a/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_x b/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_x index a2e7b7604..9ef36f83a 100644 --- a/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_x +++ b/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_x @@ -42,9 +42,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 0.1 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_y b/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_y index 5af596575..bcc372641 100644 --- a/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_y +++ b/Exec/DryRegTests/Couette_Poiseuille/inputs_couette_y @@ -42,9 +42,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 0.1 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_x b/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_x index 2e20c2a29..21db47fcb 100644 --- a/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_x +++ b/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_x @@ -42,10 +42,9 @@ erf.use_gravity = false erf.alpha_T = 0.0 erf.alpha_C = 0.0 -erf.les_type = "None" -erf.rho0_trans = 1.0 -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 0.1 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 erf.use_coriolis = false erf.abl_driver_type = "PressureGradient" diff --git a/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_y b/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_y index 21f190d3d..a4ad895c7 100644 --- a/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_y +++ b/Exec/DryRegTests/Couette_Poiseuille/inputs_poiseuille_y @@ -42,10 +42,9 @@ erf.use_gravity = false erf.alpha_T = 0.0 erf.alpha_C = 0.0 -erf.les_type = "None" -erf.rho0_trans = 1.0 -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 0.1 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 erf.use_coriolis = false erf.abl_driver_type = "PressureGradient" diff --git a/Exec/DryRegTests/DensityCurrent/inputs_amr b/Exec/DryRegTests/DensityCurrent/inputs_amr index df18c6b85..51d56c83b 100644 --- a/Exec/DryRegTests/DensityCurrent/inputs_amr +++ b/Exec/DryRegTests/DensityCurrent/inputs_amr @@ -58,10 +58,9 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] erf.c_p = 1004.0 diff --git a/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain b/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain index 20d90cdd8..7c35c2608 100644 --- a/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain +++ b/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain @@ -70,10 +70,9 @@ erf.les_type = None # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] erf.c_p = 1004.0 diff --git a/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain_zlev b/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain_zlev index 1a339c5b6..cbbbfa0f2 100644 --- a/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain_zlev +++ b/Exec/DryRegTests/DensityCurrent/inputs_crse_halfdomain_zlev @@ -52,10 +52,9 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] erf.c_p = 1004.0 diff --git a/Exec/DryRegTests/DensityCurrent/inputs_refsoln b/Exec/DryRegTests/DensityCurrent/inputs_refsoln index a2d56078e..f0b341064 100644 --- a/Exec/DryRegTests/DensityCurrent/inputs_refsoln +++ b/Exec/DryRegTests/DensityCurrent/inputs_refsoln @@ -50,10 +50,9 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] erf.c_p = 1004.0 diff --git a/Exec/DryRegTests/DensityCurrent/inputs_wrf_baseline b/Exec/DryRegTests/DensityCurrent/inputs_wrf_baseline index e9c6ae9ad..2fd64ff93 100644 --- a/Exec/DryRegTests/DensityCurrent/inputs_wrf_baseline +++ b/Exec/DryRegTests/DensityCurrent/inputs_wrf_baseline @@ -46,10 +46,9 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] erf.c_p = 1004.0 diff --git a/Exec/DryRegTests/EkmanSpiral/ERF_Prob.cpp b/Exec/DryRegTests/EkmanSpiral/ERF_Prob.cpp index ed6f108ae..c0c4fde83 100644 --- a/Exec/DryRegTests/EkmanSpiral/ERF_Prob.cpp +++ b/Exec/DryRegTests/EkmanSpiral/ERF_Prob.cpp @@ -72,7 +72,7 @@ Problem::init_custom_pert( Real coriolis_factor = 4.0 * PI / rot_time_period; Real Az; - pp.get("dynamicViscosity", Az); // dynamic viscosity [kg-m/s] + pp.get("dynamic_viscosity", Az); // dynamic viscosity [kg-m/s] Az = Az / parms.rho_0; // kinematic viscosity [m^2/s] Vector abl_geo_wind(3); diff --git a/Exec/DryRegTests/EkmanSpiral/inputs_custom b/Exec/DryRegTests/EkmanSpiral/inputs_custom index 2bf92fc18..c3411a8a5 100644 --- a/Exec/DryRegTests/EkmanSpiral/inputs_custom +++ b/Exec/DryRegTests/EkmanSpiral/inputs_custom @@ -41,9 +41,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 5.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 5.0 erf.use_coriolis = true erf.abl_driver_type = "GeostrophicWind" diff --git a/Exec/DryRegTests/EkmanSpiral/inputs_ideal b/Exec/DryRegTests/EkmanSpiral/inputs_ideal index a2d90e5fb..5f26bdd18 100644 --- a/Exec/DryRegTests/EkmanSpiral/inputs_ideal +++ b/Exec/DryRegTests/EkmanSpiral/inputs_ideal @@ -41,9 +41,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = true -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 5.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 5.0 erf.use_coriolis = true erf.abl_driver_type = "GeostrophicWind" diff --git a/Exec/DryRegTests/EkmanSpiral/inputs_input_sounding b/Exec/DryRegTests/EkmanSpiral/inputs_input_sounding index c7b8822ea..025b6600f 100644 --- a/Exec/DryRegTests/EkmanSpiral/inputs_input_sounding +++ b/Exec/DryRegTests/EkmanSpiral/inputs_input_sounding @@ -41,9 +41,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = true -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 5.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 5.0 erf.use_coriolis = true erf.abl_driver_type = "GeostrophicWind" diff --git a/Exec/DryRegTests/IsentropicVortex/inputs_advecting b/Exec/DryRegTests/IsentropicVortex/inputs_advecting index f4ea247a8..0d70bb845 100644 --- a/Exec/DryRegTests/IsentropicVortex/inputs_advecting +++ b/Exec/DryRegTests/IsentropicVortex/inputs_advecting @@ -46,7 +46,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Exec/DryRegTests/IsentropicVortex/inputs_advecting_ml b/Exec/DryRegTests/IsentropicVortex/inputs_advecting_ml index b4cf1c1f6..4fbd6c820 100644 --- a/Exec/DryRegTests/IsentropicVortex/inputs_advecting_ml +++ b/Exec/DryRegTests/IsentropicVortex/inputs_advecting_ml @@ -62,7 +62,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Exec/DryRegTests/IsentropicVortex/inputs_advecting_msf b/Exec/DryRegTests/IsentropicVortex/inputs_advecting_msf index 1e8a1ee93..bbd798d64 100644 --- a/Exec/DryRegTests/IsentropicVortex/inputs_advecting_msf +++ b/Exec/DryRegTests/IsentropicVortex/inputs_advecting_msf @@ -43,9 +43,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Exec/DryRegTests/IsentropicVortex/inputs_advecting_no_msf b/Exec/DryRegTests/IsentropicVortex/inputs_advecting_no_msf index bb53d1641..e663c3295 100644 --- a/Exec/DryRegTests/IsentropicVortex/inputs_advecting_no_msf +++ b/Exec/DryRegTests/IsentropicVortex/inputs_advecting_no_msf @@ -41,9 +41,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Exec/DryRegTests/IsentropicVortex/inputs_stationary b/Exec/DryRegTests/IsentropicVortex/inputs_stationary index 4aff9cba7..39663dc1e 100644 --- a/Exec/DryRegTests/IsentropicVortex/inputs_stationary +++ b/Exec/DryRegTests/IsentropicVortex/inputs_stationary @@ -42,7 +42,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Exec/DryRegTests/IsentropicVortex/inputs_stationary_msf b/Exec/DryRegTests/IsentropicVortex/inputs_stationary_msf index 8dc959944..7186b6ab5 100644 --- a/Exec/DryRegTests/IsentropicVortex/inputs_stationary_msf +++ b/Exec/DryRegTests/IsentropicVortex/inputs_stationary_msf @@ -43,9 +43,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Exec/DryRegTests/IsentropicVortex/inputs_stationary_no_msf b/Exec/DryRegTests/IsentropicVortex/inputs_stationary_no_msf index a1f7432fd..0c4ba2a32 100644 --- a/Exec/DryRegTests/IsentropicVortex/inputs_stationary_no_msf +++ b/Exec/DryRegTests/IsentropicVortex/inputs_stationary_no_msf @@ -41,9 +41,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Exec/DryRegTests/ParticlesOverWoA/inputs b/Exec/DryRegTests/ParticlesOverWoA/inputs index e6bca805e..51c1e70e8 100644 --- a/Exec/DryRegTests/ParticlesOverWoA/inputs +++ b/Exec/DryRegTests/ParticlesOverWoA/inputs @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0. 0. 0. geometry.prob_hi = 10. 1. 2. -amr.n_cell = 256 8 64 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 256 8 64 geometry.is_periodic = 0 1 0 @@ -74,11 +74,10 @@ erf.dycore_vert_adv_type = Centered_2nd erf.dryscal_horiz_adv_type = Centered_2nd erf.dryscal_vert_adv_type = Centered_2nd -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO b/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO index 8bd32f343..d3d8fcd61 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO @@ -48,7 +48,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO_Z b/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO_Z index 774bb4e00..536078c02 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO_Z +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_WENO_Z @@ -49,7 +49,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_adv_diff_uniformU b/Exec/DryRegTests/ScalarAdvDiff/inputs_adv_diff_uniformU index c0458e886..f3d0240e5 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_adv_diff_uniformU +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_adv_diff_uniformU @@ -40,10 +40,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_advdiffinflowoutflow b/Exec/DryRegTests/ScalarAdvDiff/inputs_advdiffinflowoutflow index ded2cc687..5e594cf05 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_advdiffinflowoutflow +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_advdiffinflowoutflow @@ -48,10 +48,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU index 7c90ce2e0..cb6047c1d 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU @@ -41,7 +41,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_msf b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_msf index 9bf80175f..a54fbbe55 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_msf +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_msf @@ -46,7 +46,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_no_msf b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_no_msf index 7ec1a8fdd..3de792c5a 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_no_msf +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_shearU_no_msf @@ -45,7 +45,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU index e37e9bebe..120a5e600 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU @@ -41,7 +41,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_msf b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_msf index 118895ae3..dbd9e530d 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_msf +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_msf @@ -45,7 +45,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_no_msf b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_no_msf index 7b074a262..71813013c 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_no_msf +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_advect_uniformU_no_msf @@ -43,7 +43,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_gaussian b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_gaussian index 3646000d4..9c67e953b 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_gaussian +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_gaussian @@ -40,10 +40,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_msf b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_msf index 66b8e6ef7..ae78475be 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_msf +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_msf @@ -42,10 +42,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 1.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_no_msf b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_no_msf index 73e717f4f..6e26f9bad 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_no_msf +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_no_msf @@ -40,10 +40,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 1.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_sine b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_sine index 92b4ba54b..1f0bbe280 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_sine +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_diffuse_sine @@ -42,10 +42,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_ml b/Exec/DryRegTests/ScalarAdvDiff/inputs_ml index e26c3a1c9..60d6e3f85 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_ml +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_ml @@ -39,8 +39,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 erf.dycore_horiz_adv_type = "Centered_2nd" erf.dycore_vert_adv_type = "Centered_2nd" diff --git a/Exec/DryRegTests/ScalarAdvDiff/inputs_test_rayleigh b/Exec/DryRegTests/ScalarAdvDiff/inputs_test_rayleigh index 54dd4bbfe..4eed42cda 100644 --- a/Exec/DryRegTests/ScalarAdvDiff/inputs_test_rayleigh +++ b/Exec/DryRegTests/ScalarAdvDiff/inputs_test_rayleigh @@ -48,7 +48,6 @@ erf.rayleigh_damp_T = true erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Exec/DryRegTests/StokesSecondProblem/inputs b/Exec/DryRegTests/StokesSecondProblem/inputs index 1433dc9f2..0200a51bc 100644 --- a/Exec/DryRegTests/StokesSecondProblem/inputs +++ b/Exec/DryRegTests/StokesSecondProblem/inputs @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0 0. 0. geometry.prob_hi = 1.0 1. 0.5 -amr.n_cell = 8 4 256 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 8 4 256 geometry.is_periodic = 0 1 0 @@ -73,11 +73,10 @@ erf.specify_terrain_velocity = true #erf.all_use_WENO = true #erf.spatial_order_WENO = 5 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 4.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 4.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/StokesSecondProblem/inputs_stretched_z_levels b/Exec/DryRegTests/StokesSecondProblem/inputs_stretched_z_levels index 102691ed5..a2e5b38f6 100644 --- a/Exec/DryRegTests/StokesSecondProblem/inputs_stretched_z_levels +++ b/Exec/DryRegTests/StokesSecondProblem/inputs_stretched_z_levels @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0 0. 0. geometry.prob_hi = 1.0 1. 1.0 -amr.n_cell = 8 4 128 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 8 4 128 geometry.is_periodic = 0 1 0 @@ -72,11 +72,10 @@ erf.terrain_z_levels = 0 0.000237889 0.000487134 0.000748273 0.00102187 0.001308 #erf.all_use_WENO = true #erf.spatial_order_WENO = 5 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 2.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 2.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/TaylorGreenVortex/inputs_advdiff b/Exec/DryRegTests/TaylorGreenVortex/inputs_advdiff index c244dd427..26e468085 100644 --- a/Exec/DryRegTests/TaylorGreenVortex/inputs_advdiff +++ b/Exec/DryRegTests/TaylorGreenVortex/inputs_advdiff @@ -40,9 +40,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 6.25e-4 # 1.5e-5 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 6.25e-4 #1.5e-5 # PROBLEM PARAMETERS prob.rho_0 = 1.0 diff --git a/Exec/DryRegTests/TaylorGreenVortex/inputs_advonly b/Exec/DryRegTests/TaylorGreenVortex/inputs_advonly index d74df1bd4..bcc38075c 100644 --- a/Exec/DryRegTests/TaylorGreenVortex/inputs_advonly +++ b/Exec/DryRegTests/TaylorGreenVortex/inputs_advonly @@ -42,7 +42,6 @@ erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.rho_0 = 1.0 diff --git a/Exec/DryRegTests/TaylorGreenVortex/inputs_multilevel b/Exec/DryRegTests/TaylorGreenVortex/inputs_multilevel index e53115628..da89f2fb3 100644 --- a/Exec/DryRegTests/TaylorGreenVortex/inputs_multilevel +++ b/Exec/DryRegTests/TaylorGreenVortex/inputs_multilevel @@ -40,9 +40,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 6.25e-4 # 1.5e-5 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 6.25e-4 #1.5e-5 # PROBLEM PARAMETERS prob.rho_0 = 1.0 diff --git a/Exec/DryRegTests/Terrain2d_Cylinder/inputs b/Exec/DryRegTests/Terrain2d_Cylinder/inputs index 409940b1b..e7a6ce956 100644 --- a/Exec/DryRegTests/Terrain2d_Cylinder/inputs +++ b/Exec/DryRegTests/Terrain2d_Cylinder/inputs @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0 0. 0. geometry.prob_hi = 30.0 1. 10.0 -amr.n_cell = 512 4 256 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 512 4 256 geometry.is_periodic = 0 1 0 @@ -86,11 +86,10 @@ erf.terrain_smoothing = 0 #erf.all_use_WENO = true #erf.spatial_order_WENO = 5 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/Terrain2d_Cylinder/inputs.amr b/Exec/DryRegTests/Terrain2d_Cylinder/inputs.amr index 6a92750ea..fe6384a36 100644 --- a/Exec/DryRegTests/Terrain2d_Cylinder/inputs.amr +++ b/Exec/DryRegTests/Terrain2d_Cylinder/inputs.amr @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0 0. 0. geometry.prob_hi = 30.0 1. 10.0 -amr.n_cell = 256 12 128 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 256 12 128 geometry.is_periodic = 0 1 0 @@ -86,11 +86,10 @@ erf.terrain_smoothing = 0 #erf.all_use_WENO = true #erf.spatial_order_WENO = 5 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/Terrain2d_Cylinder/inputs_most_test b/Exec/DryRegTests/Terrain2d_Cylinder/inputs_most_test index 61a45c409..9e009243f 100644 --- a/Exec/DryRegTests/Terrain2d_Cylinder/inputs_most_test +++ b/Exec/DryRegTests/Terrain2d_Cylinder/inputs_most_test @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0. 0. 0. geometry.prob_hi = 10. 1. 2. -amr.n_cell = 256 8 64 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 256 8 64 geometry.is_periodic = 1 1 0 @@ -73,11 +73,9 @@ erf.Cs = 0.1 erf.terrain_type = Static erf.terrain_smoothing = 0 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/Terrain2d_Cylinder/inputs_stretched_z_levels b/Exec/DryRegTests/Terrain2d_Cylinder/inputs_stretched_z_levels index 3808972fd..a47dd5c8a 100644 --- a/Exec/DryRegTests/Terrain2d_Cylinder/inputs_stretched_z_levels +++ b/Exec/DryRegTests/Terrain2d_Cylinder/inputs_stretched_z_levels @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0 0. 0. geometry.prob_hi = 30.0 1. 10.0 -amr.n_cell = 512 4 64 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 512 4 64 geometry.is_periodic = 0 1 0 @@ -86,11 +86,10 @@ erf.terrain_z_levels = 0 0.0236057 0.0486738 0.0752909 0.103548 0.133541 0.16537 #erf.all_use_WENO = true #erf.spatial_order_WENO = 5 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.01 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.01 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/Terrain2d_Cylinder/inputs_verification_final b/Exec/DryRegTests/Terrain2d_Cylinder/inputs_verification_final index 6bdaa5966..dee63df1c 100644 --- a/Exec/DryRegTests/Terrain2d_Cylinder/inputs_verification_final +++ b/Exec/DryRegTests/Terrain2d_Cylinder/inputs_verification_final @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0 0. 0. geometry.prob_hi = 30.0 1. 10.0 -amr.n_cell = 512 4 256 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 512 4 256 geometry.is_periodic = 0 1 0 @@ -81,11 +81,10 @@ erf.terrain_smoothing = 0 #erf.all_use_WENO = true #erf.spatial_order_WENO = 5 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/Terrain3d_Hemisphere/inputs b/Exec/DryRegTests/Terrain3d_Hemisphere/inputs index 46d6ee113..9b2f6e5cf 100644 --- a/Exec/DryRegTests/Terrain3d_Hemisphere/inputs +++ b/Exec/DryRegTests/Terrain3d_Hemisphere/inputs @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0. 0. 0. geometry.prob_hi = 10 10 10 -amr.n_cell = 128 128 128 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 128 128 128 geometry.is_periodic = 0 1 0 @@ -82,11 +82,10 @@ erf.box1.in_box_hi = 8. 0.75 erf.terrain_type = Static erf.terrain_smoothing = 0 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.1 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.1 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/Terrain3d_Hemisphere/inputs.amr b/Exec/DryRegTests/Terrain3d_Hemisphere/inputs.amr index 7bd3f8ea6..43a51d1ce 100644 --- a/Exec/DryRegTests/Terrain3d_Hemisphere/inputs.amr +++ b/Exec/DryRegTests/Terrain3d_Hemisphere/inputs.amr @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0. 0. 0. geometry.prob_hi = 10 10 10 -amr.n_cell = 100 100 100 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 100 100 100 geometry.is_periodic = 0 1 0 @@ -81,11 +81,10 @@ erf.les_type = "None" erf.terrain_type = Static erf.terrain_smoothing = 0 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.1 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.1 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] # PROBLEM PARAMETERS (optional) prob.T_0 = 300.0 diff --git a/Exec/DryRegTests/Terrain3d_Hemisphere/inputs_most_test b/Exec/DryRegTests/Terrain3d_Hemisphere/inputs_most_test index 0afdbce08..c0b2765e6 100644 --- a/Exec/DryRegTests/Terrain3d_Hemisphere/inputs_most_test +++ b/Exec/DryRegTests/Terrain3d_Hemisphere/inputs_most_test @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0. 0. 0. geometry.prob_hi = 10. 1. 2. -amr.n_cell = 256 8 64 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 256 8 64 geometry.is_periodic = 1 1 0 @@ -67,11 +67,9 @@ erf.Cs = 0.1 erf.terrain_type = Static erf.terrain_smoothing = 0 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/TurbulentInflow/compressible_direct_inputs b/Exec/DryRegTests/TurbulentInflow/compressible_direct_inputs index 2799c7a3d..f0499a9d7 100644 --- a/Exec/DryRegTests/TurbulentInflow/compressible_direct_inputs +++ b/Exec/DryRegTests/TurbulentInflow/compressible_direct_inputs @@ -35,7 +35,6 @@ xlo.dirichlet_file = "input_ReTau395Ana_inflow.txt" # TIME STEP CONTROL erf.fixed_dt = 0.0002 erf.fixed_mri_dt_ratio = 4 -erf.dynamicViscosity = 0.001 # DIAGNOSTICS & VERBOSITY erf.sum_interval = 100 # timesteps between computing mass @@ -57,8 +56,6 @@ erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure #erf.check_per = 1.0 # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.molec_diff_type = "None" erf.les_type = "Smagorinsky" erf.Cs = 0.1 diff --git a/Exec/DryRegTests/TurbulentInflow/compressible_source_inputs b/Exec/DryRegTests/TurbulentInflow/compressible_source_inputs index 450a0d2a5..a8e510f10 100644 --- a/Exec/DryRegTests/TurbulentInflow/compressible_source_inputs +++ b/Exec/DryRegTests/TurbulentInflow/compressible_source_inputs @@ -35,7 +35,7 @@ xlo.dirichlet_file = "input_ReTau395Ana_inflow.txt" # TIME STEP CONTROL erf.fixed_dt = 0.0002 erf.fixed_mri_dt_ratio = 4 -erf.dynamicViscosity = 0.001 + erf.fix_random_seed = 1 # DIAGNOSTICS & VERBOSITY @@ -57,8 +57,6 @@ erf.check_file = chk # root name of checkpoint file erf.check_per = 1.0 # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.molec_diff_type = "None" erf.les_type = "Smagorinsky" erf.Cs = 0.1 diff --git a/Exec/DryRegTests/TurbulentInflow/incompressible_direct_inputs b/Exec/DryRegTests/TurbulentInflow/incompressible_direct_inputs index c8344a463..dfd0e6437 100644 --- a/Exec/DryRegTests/TurbulentInflow/incompressible_direct_inputs +++ b/Exec/DryRegTests/TurbulentInflow/incompressible_direct_inputs @@ -37,7 +37,6 @@ xlo.theta = 300.0 # TIME STEP CONTROL erf.cfl = 0.5 -erf.dynamicViscosity = 0.001 # DIAGNOSTICS & VERBOSITY erf.sum_interval = 0 # timesteps between computing mass @@ -59,8 +58,6 @@ erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure #erf.check_per = 1.0 # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.molec_diff_type = "None" erf.les_type = "Smagorinsky" erf.Cs = 0.1 diff --git a/Exec/DryRegTests/TurbulentInflow/incompressible_source_inputs b/Exec/DryRegTests/TurbulentInflow/incompressible_source_inputs index 8e87e102e..1205eec4a 100644 --- a/Exec/DryRegTests/TurbulentInflow/incompressible_source_inputs +++ b/Exec/DryRegTests/TurbulentInflow/incompressible_source_inputs @@ -37,7 +37,7 @@ xlo.theta = 300.0 # TIME STEP CONTROL erf.cfl = 0.5 -erf.dynamicViscosity = 0.001 + erf.fix_random_seed = 1 # DIAGNOSTICS & VERBOSITY @@ -60,8 +60,6 @@ erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure #erf.check_per = 1.0 # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.molec_diff_type = "None" erf.les_type = "Smagorinsky" erf.Cs = 0.1 diff --git a/Exec/DryRegTests/WPS_Test/inputs_real_ChisholmView b/Exec/DryRegTests/WPS_Test/inputs_real_ChisholmView index c1c362c10..f22842eb3 100644 --- a/Exec/DryRegTests/WPS_Test/inputs_real_ChisholmView +++ b/Exec/DryRegTests/WPS_Test/inputs_real_ChisholmView @@ -50,9 +50,9 @@ erf.terrain_type = Static erf.moisture_model = "Kessler" -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 5.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 5.0 erf.use_coriolis = true erf.abl_driver_type = "GeostrophicWind" diff --git a/Exec/DryRegTests/WitchOfAgnesi/inputs b/Exec/DryRegTests/WitchOfAgnesi/inputs index c7a20f346..fbe3db8e3 100644 --- a/Exec/DryRegTests/WitchOfAgnesi/inputs +++ b/Exec/DryRegTests/WitchOfAgnesi/inputs @@ -62,7 +62,6 @@ erf.use_coriolis = false erf.les_type = "None" erf.molec_diff_type = "None" -#erf.dynamicViscosity = 1e-5 # [kg/(m-s)] erf.rayleigh_damp_W = true erf.rayleigh_zdamp = 5000.0 diff --git a/Exec/DryRegTests/WitchOfAgnesi/inputs_most_test b/Exec/DryRegTests/WitchOfAgnesi/inputs_most_test index 6d8e05809..57f19a477 100644 --- a/Exec/DryRegTests/WitchOfAgnesi/inputs_most_test +++ b/Exec/DryRegTests/WitchOfAgnesi/inputs_most_test @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0. 0. 0. geometry.prob_hi = 10. 1. 2. -amr.n_cell = 256 8 64 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 256 8 64 geometry.is_periodic = 1 1 0 @@ -73,11 +73,9 @@ erf.Cs = 0.1 erf.terrain_type = Static erf.terrain_smoothing = 0 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/WitchOfAgnesi/inputs_static_twolevel b/Exec/DryRegTests/WitchOfAgnesi/inputs_static_twolevel index 90d061d00..5c0373f4d 100644 --- a/Exec/DryRegTests/WitchOfAgnesi/inputs_static_twolevel +++ b/Exec/DryRegTests/WitchOfAgnesi/inputs_static_twolevel @@ -54,11 +54,9 @@ erf.les_type = "None" erf.terrain_type = Static erf.terrain_smoothing = 0 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 1.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] erf.abl_driver_type = "PressureGradient" erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/DryRegTests/WitchOfAgnesi/inputs_zlevels b/Exec/DryRegTests/WitchOfAgnesi/inputs_zlevels index 17bdada4b..0b315f01d 100644 --- a/Exec/DryRegTests/WitchOfAgnesi/inputs_zlevels +++ b/Exec/DryRegTests/WitchOfAgnesi/inputs_zlevels @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0. 0. 0. geometry.prob_hi = 10000. 100. 3200. -amr.n_cell = 256 8 32 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 256 8 32 geometry.is_periodic = 0 1 0 @@ -63,11 +63,9 @@ erf.terrain_z_levels = 0. 200. 300. 400. 450. 500. 600. 700. 800. 900. 1000. 110 # TERRRAIN GRID TYPE erf.terrain_smoothing = 1 -# Diffusion coefficient from Straka, K = 75 m^2/s -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" #erf.abl_pressure_grad = -0.2 0. 0. diff --git a/Exec/LLJ/inputs b/Exec/LLJ/inputs index c7a85de2d..bce8927b5 100644 --- a/Exec/LLJ/inputs +++ b/Exec/LLJ/inputs @@ -48,9 +48,9 @@ erf.alpha_T = 0.0 erf.alpha_C = 0.0 erf.use_gravity = true -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 5.0 +erf.les_type = "None" +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 5.0 # PROBLEM PARAMETERS (optional) prob.rho_0 = 1.0 diff --git a/Exec/Make.ERF b/Exec/Make.ERF index d25135f68..32a208695 100644 --- a/Exec/Make.ERF +++ b/Exec/Make.ERF @@ -117,7 +117,7 @@ ifeq ($(USE_EB),TRUE) AMReXdirs += EB endif -USE_LINEAR_SOLVERS_INCFLO = FALSE +USE_LINEAR_SOLVERS_INCFLO = TRUE USE_LINEAR_SOLVERS_EM = FALSE AMReXdirs += LinearSolvers diff --git a/Exec/MoistRegTests/Bomex/ERF_Prob.cpp b/Exec/MoistRegTests/Bomex/ERF_Prob.cpp index 3d2839741..38a874e78 100644 --- a/Exec/MoistRegTests/Bomex/ERF_Prob.cpp +++ b/Exec/MoistRegTests/Bomex/ERF_Prob.cpp @@ -293,7 +293,7 @@ Problem::update_rhoqt_sources (const Real& /*time*/, reduce_to_max_per_height(zlevels, z_phys_cc); } - // Only apply temperature source below nominal inversion height + // Only apply moisture source below nominal inversion height for (int k = 0; k <= khi; k++) { const Real z_cc = (z_phys_cc) ? zlevels[k] : prob_lo[2] + (k+0.5)* dx[2]; if (z_cc < parms.moisture_cutoff) { @@ -386,7 +386,7 @@ Problem::update_geostrophic_profile (const Real& /*time*/, // const Real coriolis = 2.0 * 2.0 * PI / 86400.0; // 0.376E-4; - // Only apply temperature source below nominal inversion height + // Only apply momentum source below nominal inversion height for (int k = 0; k <= khi; k++) { const Real z_cc = (z_phys_cc) ? zlevels[k] : prob_lo[2] + (k+0.5)* dx[2]; const Real u_geo_wind = -10.0 + z_cc * 0.0018; diff --git a/Exec/MoistRegTests/Bomex/input_Kessler b/Exec/MoistRegTests/Bomex/input_Kessler index 3a90a93bf..69ec90388 100644 --- a/Exec/MoistRegTests/Bomex/input_Kessler +++ b/Exec/MoistRegTests/Bomex/input_Kessler @@ -9,8 +9,8 @@ amrex.fpe_trap_invalid = 1 fabarray.mfiter_tile_size = 1024 1024 1024 # PROBLEM SIZE & GEOMETRY -geometry.prob_extent = 3200 3200 4000 -amr.n_cell = 32 32 100 +geometry.prob_extent = 6400 6400 4000 +amr.n_cell = 64 64 100 geometry.is_periodic = 1 1 0 @@ -64,8 +64,8 @@ erf.dycore_horiz_adv_type = Upwind_3rd erf.dycore_vert_adv_type = Upwind_3rd erf.dryscal_horiz_adv_type = Upwind_3rd erf.dryscal_vert_adv_type = Upwind_3rd -erf.moistscal_horiz_adv_type = WENO5 -erf.moistscal_vert_adv_type = WENO5 +erf.moistscal_horiz_adv_type = Upwind_3rd +erf.moistscal_vert_adv_type = Upwind_3rd erf.moisture_model = "Kessler_NoRain" erf.buoyancy_type = 1 diff --git a/Exec/MoistRegTests/Bomex/input_SAM b/Exec/MoistRegTests/Bomex/input_SAM index 03dfa5e80..92f33955c 100644 --- a/Exec/MoistRegTests/Bomex/input_SAM +++ b/Exec/MoistRegTests/Bomex/input_SAM @@ -9,8 +9,8 @@ amrex.fpe_trap_invalid = 1 fabarray.mfiter_tile_size = 1024 1024 1024 # PROBLEM SIZE & GEOMETRY -geometry.prob_extent = 3200 3200 4000 -amr.n_cell = 32 32 100 +geometry.prob_extent = 6400 6400 4000 +amr.n_cell = 64 64 100 geometry.is_periodic = 1 1 0 @@ -64,8 +64,8 @@ erf.dycore_horiz_adv_type = Upwind_3rd erf.dycore_vert_adv_type = Upwind_3rd erf.dryscal_horiz_adv_type = Upwind_3rd erf.dryscal_vert_adv_type = Upwind_3rd -erf.moistscal_horiz_adv_type = WENO5 -erf.moistscal_vert_adv_type = WENO5 +erf.moistscal_horiz_adv_type = Upwind_3rd +erf.moistscal_vert_adv_type = Upwind_3rd erf.moisture_model = "SAM" erf.buoyancy_type = 1 diff --git a/Exec/MoistRegTests/Bubble/inputs_BF02_dry_bubble b/Exec/MoistRegTests/Bubble/inputs_BF02_dry_bubble index 9992208e5..98919ed8a 100644 --- a/Exec/MoistRegTests/Bubble/inputs_BF02_dry_bubble +++ b/Exec/MoistRegTests/Bubble/inputs_BF02_dry_bubble @@ -54,11 +54,10 @@ erf.moisture_model = "None" erf.buoyancy_type = 1 erf.use_moist_background = false -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # PROBLEM PARAMETERS (optional) # warm bubble input diff --git a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble index e86a8c4e0..4dcb7cc37 100644 --- a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble +++ b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble @@ -56,11 +56,10 @@ erf.moisture_model = "Kessler_NoRain" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # INITIAL CONDITIONS #erf.init_type = "input_sounding" diff --git a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_Kessler b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_Kessler index 58bb41670..34da626ac 100644 --- a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_Kessler +++ b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_Kessler @@ -56,11 +56,10 @@ erf.moisture_model = "Kessler" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # INITIAL CONDITIONS #erf.init_type = "input_sounding" diff --git a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_OpenBC b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_OpenBC index ea27762c6..7be25f59a 100644 --- a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_OpenBC +++ b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_OpenBC @@ -56,11 +56,10 @@ erf.moisture_model = "Kessler_NoRain" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # INITIAL CONDITIONS #erf.init_type = "input_sounding" diff --git a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM index 5600feeca..2da4360d9 100644 --- a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM +++ b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM @@ -54,11 +54,10 @@ erf.moisture_model = "SAM" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # PROBLEM PARAMETERS (optional) # warm bubble input diff --git a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoIce b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoIce index fbf21a978..5ff7c8643 100644 --- a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoIce +++ b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoIce @@ -56,11 +56,10 @@ erf.moisture_model = "SAM_NoIce" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # INITIAL CONDITIONS #erf.init_type = "input_sounding" diff --git a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoPrecip_NoIce b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoPrecip_NoIce index d9732baa0..2e041de11 100644 --- a/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoPrecip_NoIce +++ b/Exec/MoistRegTests/Bubble/inputs_BF02_moist_bubble_SAM_NoPrecip_NoIce @@ -56,11 +56,10 @@ erf.moisture_model = "SAM_NoPrecip_NoIce" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # INITIAL CONDITIONS #erf.init_type = "input_sounding" diff --git a/Exec/MoistRegTests/Bubble/inputs_grav2d_x b/Exec/MoistRegTests/Bubble/inputs_grav2d_x index 19cfc8c01..0cd1ac8aa 100644 --- a/Exec/MoistRegTests/Bubble/inputs_grav2d_x +++ b/Exec/MoistRegTests/Bubble/inputs_grav2d_x @@ -20,8 +20,8 @@ zlo.type = "SlipWall" zhi.type = "SlipWall" # TIME STEP CONTROL -erf.fixed_dt = 1.0 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.25 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 1.0 # fixed time step [s] +erf.fixed_fast_dt = 0.25 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -53,10 +53,9 @@ erf.pbl_type = "None" erf.c_p = 1004.0 -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity= 75.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s == diffusion coefficient from Straka -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s == diffusion coefficient from Straka +erf.alpha_T = 75.0 # [m^2/s] # INITIAL CONDITIONS erf.init_type = "" diff --git a/Exec/MoistRegTests/Bubble/inputs_squall2d_x b/Exec/MoistRegTests/Bubble/inputs_squall2d_x index b801480d3..831ba74b2 100644 --- a/Exec/MoistRegTests/Bubble/inputs_squall2d_x +++ b/Exec/MoistRegTests/Bubble/inputs_squall2d_x @@ -16,8 +16,8 @@ zlo.type = "SlipWall" zhi.type = "SlipWall" # TIME STEP CONTROL -erf.fixed_dt = 3.0 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.75 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 3.0 # fixed time step [s] +erf.fixed_fast_dt = 0.75 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -48,16 +48,14 @@ erf.pbl_type = "None" erf.moisture_model = "SAM" erf.buoyancy_type = 1 -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity= 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] # INITIAL CONDITIONS erf.init_type = "input_sounding" erf.input_sounding_file = "input_sounding_squall2d" erf.init_sounding_ideal = 1 -erf.KE_0 = 0.1 # for Deardorff # PROBLEM PARAMETERS (optional) # warm bubble input @@ -67,3 +65,4 @@ prob.z_c = 1500.0 prob.x_r = 4000.0 prob.z_r = 1500.0 prob.T_0 = 0.0 +prob.KE_0 = 0.1 diff --git a/Exec/MoistRegTests/Bubble/inputs_test_outflow b/Exec/MoistRegTests/Bubble/inputs_test_outflow index 09a11d7f9..6fb7e0101 100644 --- a/Exec/MoistRegTests/Bubble/inputs_test_outflow +++ b/Exec/MoistRegTests/Bubble/inputs_test_outflow @@ -62,11 +62,10 @@ erf.moisture_model = "Kessler" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # INITIAL CONDITIONS #erf.init_type = "input_sounding" diff --git a/Exec/MoistRegTests/SquallLine_2D/inputs_ml b/Exec/MoistRegTests/SquallLine_2D/inputs_ml index 4a4f50617..22c12099f 100644 --- a/Exec/MoistRegTests/SquallLine_2D/inputs_ml +++ b/Exec/MoistRegTests/SquallLine_2D/inputs_ml @@ -20,8 +20,8 @@ zlo.type = "SlipWall" zhi.type = "SlipWall" # TIME STEP CONTROL -erf.fixed_dt = 1.0 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.5 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 1.0 # fixed time step [s] +erf.fixed_fast_dt = 0.5 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -61,14 +61,11 @@ erf.use_gravity = true erf.buoyancy_type = 1 erf.use_coriolis = false -# -# diffusion coefficient from Straka, K = 75 m^2/s -# -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 100.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 100.0 # [m^2/s] -erf.alpha_C = 100.0 +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 100.0 # [kg/(m-s)] +erf.alpha_T = 100.0 # [m^2/s] +erf.alpha_C = 100.0 erf.moisture_model = "Kessler" erf.use_moist_background = true diff --git a/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_Gabersek b/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_Gabersek index 46484d4ad..4b13516a1 100644 --- a/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_Gabersek +++ b/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_Gabersek @@ -19,8 +19,8 @@ zlo.type = "SlipWall" zhi.type = "HO_Outflow" # TIME STEP CONTROL -erf.fixed_dt = 0.25 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.125 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 0.25 # fixed time step [s] +erf.fixed_fast_dt = 0.125 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -46,18 +46,14 @@ erf.buoyancy_type = 1 erf.use_coriolis = false #erf.les_type = "Smagorinsky" -erf.Cs = 0.25 +#erf.Cs = 0.25 erf.les_type = "None" -# -# diffusion coefficient from Straka, K = 75 m^2/s -# -erf.molec_diff_type = "ConstantAlpha" -#erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 200.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 200.0 # [m^2/s] -erf.alpha_C = 200.0 +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 200.0 # [kg/(m-s)] +erf.alpha_T = 200.0 # [m^2/s] +erf.alpha_C = 200.0 erf.moisture_model = "Kessler" erf.use_moist_background = true diff --git a/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_SAM b/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_SAM index 3f7ea21b1..b3108af07 100644 --- a/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_SAM +++ b/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_SAM @@ -19,8 +19,8 @@ zlo.type = "SlipWall" zhi.type = "Outflow" # TIME STEP CONTROL -erf.fixed_dt = 1.0 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.5 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 1.0 # fixed time step [s] +erf.fixed_fast_dt = 0.5 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -45,14 +45,11 @@ erf.use_gravity = true erf.buoyancy_type = 1 erf.use_coriolis = false -# -# diffusion coefficient from Straka, K = 75 m^2/s -# -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 100.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 100.0 # [m^2/s] -erf.alpha_C = 100.0 +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 100.0 # [kg/(m-s)] +erf.alpha_T = 100.0 # [m^2/s] +erf.alpha_C = 100.0 erf.moisture_model = "SAM" erf.use_moist_background = true diff --git a/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_WRF b/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_WRF index b1fea7fdb..996356788 100644 --- a/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_WRF +++ b/Exec/MoistRegTests/SquallLine_2D/inputs_moisture_WRF @@ -19,8 +19,8 @@ zlo.type = "SlipWall" zhi.type = "HO_Outflow" # TIME STEP CONTROL -erf.fixed_dt = 1.0 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.5 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 1.0 # fixed time step [s] +erf.fixed_fast_dt = 0.5 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -44,14 +44,11 @@ erf.use_gravity = true erf.buoyancy_type = 1 erf.use_coriolis = false -# -# diffusion coefficient from Straka, K = 75 m^2/s -# -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 100.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 100.0 # [m^2/s] -erf.alpha_C = 100.0 +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 100.0 # [kg/(m-s)] +erf.alpha_T = 100.0 # [m^2/s] +erf.alpha_C = 100.0 erf.moisture_model = "Kessler" erf.use_moist_background = true diff --git a/Exec/MoistRegTests/SuperCell_3D/inputs_moisture_Tissaoui b/Exec/MoistRegTests/SuperCell_3D/inputs_moisture_Tissaoui index 4f19730c9..a006473c4 100644 --- a/Exec/MoistRegTests/SuperCell_3D/inputs_moisture_Tissaoui +++ b/Exec/MoistRegTests/SuperCell_3D/inputs_moisture_Tissaoui @@ -22,8 +22,8 @@ zlo.type = "SlipWall" zhi.type = "HO_Outflow" # TIME STEP CONTROL -erf.fixed_dt = 0.5 # fixed time step [s] -- Straka et al 1993 -erf.fixed_fast_dt = 0.25 # fixed time step [s] -- Straka et al 1993 +erf.fixed_dt = 0.5 # fixed time step [s] +erf.fixed_fast_dt = 0.25 # fixed time step [s] # DIAGNOSTICS & VERBOSITY erf.sum_interval = 1 # timesteps between computing mass @@ -47,21 +47,16 @@ erf.plot_vars_1 = density rhotheta rhoQ1 rhoQ2 rhoQ3 x_velocity y_veloci erf.use_gravity = true erf.buoyancy_type = 1 erf.use_coriolis = false -erf.use_rayleigh_damping = false #erf.les_type = "Smagorinsky" erf.Cs = 0.25 erf.les_type = "None" -# -# diffusion coefficient from Straka, K = 75 m^2/s -# -erf.molec_diff_type = "ConstantAlpha" -#erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 33.33 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 33.33 # [m^2/s] -erf.alpha_C = 33.33 +# Constant diffusion coefficient +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 33.33 # [kg/(m-s)] +erf.alpha_T = 33.33 # [m^2/s] +erf.alpha_C = 33.33 erf.moisture_model = "Kessler" erf.use_moist_background = true diff --git a/Exec/SpongeTest/inputs_sponge_test b/Exec/SpongeTest/inputs_sponge_test index 091ff6406..19b6ffc35 100644 --- a/Exec/SpongeTest/inputs_sponge_test +++ b/Exec/SpongeTest/inputs_sponge_test @@ -9,7 +9,7 @@ fabarray.mfiter_tile_size = 1024 1024 1024 geometry.prob_lo = 0 0. 0. geometry.prob_hi = 30.0 1. 10.0 -amr.n_cell = 256 4 128 # dx=dy=dz=100 m, Straka et al 1993 / Xue et al 2000 +amr.n_cell = 256 4 128 geometry.is_periodic = 0 1 0 @@ -84,10 +84,9 @@ erf.terrain_smoothing = 0 #erf.all_use_WENO = true #erf.spatial_order_WENO = 5 -# Diffusion coefficient from Straka, K = 75 m^2/s +# Constant diffusion coefficient erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] erf.alpha_T = 0.0 # [m^2/s] #erf.abl_driver_type = "PressureGradient" diff --git a/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/NoTerrain/inputs_1WT_x_y b/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/NoTerrain/inputs_1WT_x_y index 56be43a86..20f8e24d0 100644 --- a/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/NoTerrain/inputs_1WT_x_y +++ b/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/NoTerrain/inputs_1WT_x_y @@ -79,14 +79,13 @@ erf.moistscal_horiz_adv_type = "Centered_2nd" erf.moistscal_vert_adv_type = "Centered_2nd" # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "ConstantAlpha" -erf.les_type = "None" -erf.Cs = 1.5 -erf.dynamicViscosity = 10.0 +erf.les_type = "None" +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 10.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.pbl_type = "None" diff --git a/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/WithTerrain/inputs_1WT_x_y b/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/WithTerrain/inputs_1WT_x_y index 588acff90..42df5a1dc 100644 --- a/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/WithTerrain/inputs_1WT_x_y +++ b/Exec/WindFarmTests/SingleTurbine/SimpleActuatorDisk/WithTerrain/inputs_1WT_x_y @@ -87,14 +87,13 @@ erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure #erf.moistscal_vert_adv_type = "Centered_2nd" # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "ConstantAlpha" -erf.les_type = "None" -erf.Cs = 1.5 -erf.dynamicViscosity = 10.0 +erf.les_type = "None" +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 10.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.pbl_type = "None" diff --git a/Exec/WindFarmTests/WindFarm/EWP/inputs_AWAKEN_EWP_KingPlains b/Exec/WindFarmTests/WindFarm/EWP/inputs_AWAKEN_EWP_KingPlains index 940a06430..c35b52966 100644 --- a/Exec/WindFarmTests/WindFarm/EWP/inputs_AWAKEN_EWP_KingPlains +++ b/Exec/WindFarmTests/WindFarm/EWP/inputs_AWAKEN_EWP_KingPlains @@ -62,14 +62,13 @@ erf.plot_int_1 = 1000 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta QKE vorticity SMark0 SMark1 # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "ConstantAlpha" -erf.les_type = "None" -erf.Cs = 1.5 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.pbl_type = "None" diff --git a/Exec/WindFarmTests/WindFarm/Fitch/inputs_AWAKEN_Fitch_KingPlains b/Exec/WindFarmTests/WindFarm/Fitch/inputs_AWAKEN_Fitch_KingPlains index caec06c0e..bd045978a 100644 --- a/Exec/WindFarmTests/WindFarm/Fitch/inputs_AWAKEN_Fitch_KingPlains +++ b/Exec/WindFarmTests/WindFarm/Fitch/inputs_AWAKEN_Fitch_KingPlains @@ -62,14 +62,13 @@ erf.plot_int_1 = 1000 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta QKE vorticity SMark0 SMark1 # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "ConstantAlpha" -erf.les_type = "None" -erf.Cs = 1.5 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.pbl_type = "None" diff --git a/Exec/WindFarmTests/WindFarm/GeneralActuatorDisk/inputs_AWAKEN_GeneralAD_KingPlains b/Exec/WindFarmTests/WindFarm/GeneralActuatorDisk/inputs_AWAKEN_GeneralAD_KingPlains index 02cf8e49f..c0126da8d 100644 --- a/Exec/WindFarmTests/WindFarm/GeneralActuatorDisk/inputs_AWAKEN_GeneralAD_KingPlains +++ b/Exec/WindFarmTests/WindFarm/GeneralActuatorDisk/inputs_AWAKEN_GeneralAD_KingPlains @@ -67,14 +67,13 @@ erf.plot_int_1 = 1000 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta QKE vorticity SMark0 SMark1 # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.molec_diff_type = "ConstantAlpha" -erf.les_type = "None" -erf.Cs = 1.5 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.pbl_type = "None" diff --git a/Exec/WindFarmTests/WindFarm/SimpleActuatorDisk/ReadTerrainUSGS.py b/Exec/WindFarmTests/WindFarm/SimpleActuatorDisk/ReadTerrainUSGS.py new file mode 100644 index 000000000..379727aea --- /dev/null +++ b/Exec/WindFarmTests/WindFarm/SimpleActuatorDisk/ReadTerrainUSGS.py @@ -0,0 +1,208 @@ +import math +import numpy as np +import sys +import os +import rasterio +from rasterio.transform import xy +from rasterio.warp import transform_bounds +from rasterio.transform import rowcol + +# Check if two filename arguments are provided +if len(sys.argv) != 3: + print("Usage: python3 ") + sys.exit(1) + +# Get the filenames from the command-line arguments +filename1 = sys.argv[1] +filename2 = sys.argv[2] + +# Check if both files exist, throw an error if not +if not os.path.isfile(filename1): + raise FileNotFoundError(f"Error: The file '{filename1}' does not exist.") +if not os.path.isfile(filename2): + raise FileNotFoundError(f"Error: The file '{filename2}' does not exist.") + + +# Path to the GeoTIFF file +geotiff_file = filename1 + +domain_bounds = np.loadtxt(filename2) + +# Define domain bounds +domain_lon_min = domain_bounds[0] +domain_lon_max = domain_bounds[1] +domain_lat_min = domain_bounds[2] +domain_lat_max = domain_bounds[3] + +# Constants +rad_earth = 6371000.0 # Radius of Earth in meters +M_PI = math.pi +dist_per_deg_lat = 6371000.0*2.0*M_PI/(2.0*180.0) + +row = -1 +col = -1 + +domain_row_min = 0 +domain_row_max = 0 +domain_col_min = 0 +domain_col_max = 0 + +# Open the GeoTIFF file +with rasterio.open(geotiff_file) as src: + # Get the affine transform of the raster + transform = src.transform + + # Calculate the row corresponding to the given latitude + domain_row_min = int((src.bounds.top - domain_lat_max) / abs(transform[4])) # transform[4] is the pixel height (negative) + domain_row_max = int((src.bounds.top - domain_lat_min) / abs(transform[4])) # transform[4] is the pixel height (negative) + domain_col_min = int((domain_lon_min - transform[2]) / transform[0]) # transform[2] is the x-coordinate of the top-left corner + domain_col_max = int((domain_lon_max - transform[2]) / transform[0]) # transform[2] is the x-coordinate of the top-left corner + + print("src.bounds_top are %0.15g %0.15g\n"%(src.bounds.top, transform[4])); + print("The row and cols are %d, %d, %d, %d"%(domain_row_min, domain_row_max, domain_col_min, domain_col_max)); + + # Convert row and column back to latitude and longitude + lon_min = transform[2] + domain_col_min * transform[0] + lon_max = transform[2] + domain_col_max * transform[0] + + lat_min = src.bounds.top + domain_row_max * transform[4] + lat_max = src.bounds.top + domain_row_min * transform[4] + + print("The lon min and max are %0.15g, %0.15g"%(lon_min, lon_max)); + print("The lat min and max are %0.15g, %0.15g"%(lat_min, lat_max)); + + + print("Values are %.15g, %0.15g, %0.15g, %0.15g\n"%(src.bounds.top,domain_row_max,transform[4], lat_min)); +# Open the GeoTIFF file +with rasterio.open(geotiff_file) as src: + + # Read the raster shape (rows, columns) + rows, cols = src.shape + transform = src.transform + + # Print CRS and file bounds for context + print(f"CRS: {src.crs}") + print(f"Bounds: {src.bounds}") + print(f"Raster Shape (rows, cols): {rows}, {cols}\n") + + if(domain_bounds[0] <= src.bounds.left or domain_bounds[0] >= src.bounds.right): + print("The longitude min (the first entry) specified in %s is %0.15g," + " which is not within the data longitude bounds (%0.15g, %0.15g). Exiting....\n"% + (filename2, domain_bounds[0], src.bounds.left,src.bounds.right)); + sys.exit(); + + if(domain_bounds[1] <= src.bounds.left or domain_bounds[1] >= src.bounds.right): + print("The longitude max (the second entry) specified in %s is %0.15g," + " which is not within the data longitude bounds (%0.15g, %0.15g). Exiting....\n"% + (filename2, domain_bounds[1], src.bounds.left,src.bounds.right)); + sys.exit(); + + if(domain_bounds[2] <= src.bounds.bottom or domain_bounds[2] >= src.bounds.top): + print("The latitude min (the third entry) specified in %s is %0.15g," + " which is not within the data longitude bounds (%0.15g, %0.15g). Exiting....\n"% + (filename2, domain_bounds[2], src.bounds.bottom,src.bounds.top)); + sys.exit(); + + if(domain_bounds[3] <= src.bounds.bottom or domain_bounds[3] >= src.bounds.top): + print("The latitude max (the fourth entry) specified in %s is %0.15g," + " which is not within the data longitude bounds (%0.15g, %0.15g). Exiting....\n"% + (filename2, domain_bounds[3], src.bounds.bottom,src.bounds.top)); + sys.exit(); + + # Get the bounds in the source CRS + bounds = src.bounds + + # Transform bounds to latitude and longitude (EPSG:4326) + lat_lon_bounds = transform_bounds(src.crs, "EPSG:4326", bounds.left, bounds.bottom, bounds.right, bounds.top) + + print("Data lat min %0.15g\n"%bounds.bottom); + print("Data lat max %0.15g\n"%bounds.top); + print("Data lon min %0.15g\n"%bounds.left); + print("Data lon max %0.15g\n"%bounds.right); + + lat_min = lat_min*M_PI / 180.0 + lon_min = lon_min*M_PI / 180.0 + + # Read the first band of elevation data + elevation_data = src.read(1) + + xloc = 0; + yloc = [] # To store y-coordinates + + vtk_file = open("terrain_mesh.vtk",'w') + + vtk_file.write("# vtk DataFile Version 2.0\n") + vtk_file.write("Structured Grid Example\n") + vtk_file.write("ASCII\n\n") + + # Write the structured grid header + vtk_file.write(f"DATASET STRUCTURED_GRID\n") + nskip = 1 + rows_in_output = int((domain_row_max-domain_row_min)/nskip); + cols_in_output = int((domain_col_max-domain_col_min)/nskip); + vtk_file.write(f"DIMENSIONS {cols_in_output} {rows_in_output} 1\n") # Adjust for structured grid dimensions + vtk_file.write(f"POINTS {rows_in_output*cols_in_output} float\n") # Adjust for structured grid dimensions + + file_for_erf = open("ERF_terrain_file.txt",'w') + file_for_erf.write("%0.15g %0.15g\n"%(lon_min*180/M_PI,lat_min*180/M_PI)) + file_for_erf.write("%d %d\n"%(domain_col_max-domain_col_min,domain_row_max-domain_row_min)); + + for row in range(domain_row_max, domain_row_min, -1): # Sample every 10% of rows + print("Doing %d of %d"%(row-domain_row_min, domain_row_max-domain_row_min)) + for col in range(domain_col_min, domain_col_max, nskip): # Sample every 10% of columns + + # Read the value at this pixel location + value = elevation_data[row, col] + + # Convert row and column back to latitude and longitude + lon = transform[2] + col * transform[0] # lon at the given column + lat = src.bounds.top + row * transform[4] # lat at the given row + + # Get the elevation value + elevation = elevation_data[row, col] + + if(elevation==0.0): + print("Elevation is zero...cannot be\n"); + sys.exit() + + # Conversion and calculations + lat = lat * M_PI / 180.0 + lon = lon * M_PI / 180.0 + delta_lat = lat - lat_min + delta_lon = lon - lon_min + + term1 = math.pow(math.sin(delta_lat / 2.0), 2) + term2 = math.cos(lat) * math.cos(lat_min) * math.pow(math.sin(delta_lon / 2.0), 2) + dist = 2.0 * rad_earth * math.asin(math.sqrt(term1 + term2)) + dy = (lat - lat_min) * dist_per_deg_lat * 180.0 / M_PI + fac = math.pow(dist, 2) - math.pow(dy, 2) + if(dist < dy): + if(abs(dist-dy) > 1e-10): + print("Error in calculation dist cannot be less than dy %0.15g, %0.15g"%(dist, dy)) + sys.exit() + + if(abs(dist-dy) < 1e-10): + fac = 0.0 + + dx = math.sqrt(fac) + + xloc = dx + file_for_erf.write("%0.15g %0.15g %0.15g\n"%(xloc,dy,elevation)); + + vtk_file.write(f"{xloc} {dy} {elevation}\n") + if(col==domain_col_min): + yloc.append(dy) + + file_for_erf.close() + +# Write the elevation as a scalar field + vtk_file.write(f"\nPOINT_DATA {rows_in_output * cols_in_output}\n") + vtk_file.write("SCALARS Elevation float 1\n") + vtk_file.write("LOOKUP_TABLE default\n") + for row in range(domain_row_max, domain_row_min, -1): + for col in range(domain_col_min, domain_col_max, nskip): + elevation_value = elevation_data[row, col] # Elevation for the current point + vtk_file.write(f"{elevation_value}\n") + +file_for_erf.close() + diff --git a/Exec/WindFarmTests/WindFarm/SimpleActuatorDisk/domain_bounds.txt b/Exec/WindFarmTests/WindFarm/SimpleActuatorDisk/domain_bounds.txt new file mode 100644 index 000000000..2c2f2954e --- /dev/null +++ b/Exec/WindFarmTests/WindFarm/SimpleActuatorDisk/domain_bounds.txt @@ -0,0 +1,5 @@ +-97.57 +-97.34 +36.35 +36.45 + diff --git a/Source/BoundaryConditions/ERF_ABLMost.H b/Source/BoundaryConditions/ERF_ABLMost.H index f652b3d69..a5a98ec11 100644 --- a/Source/BoundaryConditions/ERF_ABLMost.H +++ b/Source/BoundaryConditions/ERF_ABLMost.H @@ -151,16 +151,22 @@ public: pp.query("most.charnock_constant",cnk_a); pp.query("most.charnock_viscosity",cnk_visc); if (cnk_a > 0) { - amrex::Print() << "Using Charnock relation with C_a=" << cnk_a + amrex::Print() << "If there is water, Charnock relation with C_a=" << cnk_a << (cnk_visc? " and viscosity" : "") + << " will be used" << std::endl; } else { - amrex::Print() << "Using Charnock relation with variable Charnock parameter (COARE3.0)" + amrex::Print() << "If there is water, Charnock relation with variable Charnock parameter (COARE3.0)" << (cnk_visc? " and viscosity" : "") + << " will be used" << std::endl; } } else if (rough_sea_string == "coare3.0") { rough_type_sea = RoughCalcType::CHARNOCK; + amrex::Print() << "If there is water, Charnock relation with variable Charnock parameter (COARE3.0)" + << (cnk_visc? " and viscosity" : "") + << " will be used" + << std::endl; cnk_a = -1; } else if (rough_sea_string == "donelan") { rough_type_sea = RoughCalcType::DONELAN; diff --git a/Source/BoundaryConditions/ERF_FillIntermediatePatch.cpp b/Source/BoundaryConditions/ERF_FillIntermediatePatch.cpp index 982040c74..7be2320e3 100644 --- a/Source/BoundaryConditions/ERF_FillIntermediatePatch.cpp +++ b/Source/BoundaryConditions/ERF_FillIntermediatePatch.cpp @@ -345,9 +345,9 @@ ERF::FillIntermediatePatch (int lev, Real time, // how velocity from fine-fine copies (as well as physical and interpolated bcs) will be filled if (!cons_only) { - IntVect ngu = (!solverChoice.use_NumDiff) ? IntVect(1,1,1) : mfs_vel[Vars::xvel]->nGrowVect(); - IntVect ngv = (!solverChoice.use_NumDiff) ? IntVect(1,1,1) : mfs_vel[Vars::yvel]->nGrowVect(); - IntVect ngw = (!solverChoice.use_NumDiff) ? IntVect(1,1,0) : mfs_vel[Vars::zvel]->nGrowVect(); + IntVect ngu = (!solverChoice.use_num_diff) ? IntVect(1,1,1) : mfs_vel[Vars::xvel]->nGrowVect(); + IntVect ngv = (!solverChoice.use_num_diff) ? IntVect(1,1,1) : mfs_vel[Vars::yvel]->nGrowVect(); + IntVect ngw = (!solverChoice.use_num_diff) ? IntVect(1,1,0) : mfs_vel[Vars::zvel]->nGrowVect(); VelocityToMomentum(*mfs_vel[Vars::xvel], ngu, *mfs_vel[Vars::yvel], ngv, diff --git a/Source/DataStructs/ERF_AdvStruct.H b/Source/DataStructs/ERF_AdvStruct.H index 5ce564338..9293cbc40 100644 --- a/Source/DataStructs/ERF_AdvStruct.H +++ b/Source/DataStructs/ERF_AdvStruct.H @@ -184,6 +184,7 @@ struct AdvChoice { pp.queryarr("zero_xflux_faces", zero_xflux); pp.queryarr("zero_yflux_faces", zero_yflux); pp.queryarr("zero_zflux_faces", zero_zflux); + have_zero_flux_faces = ((zero_xflux.size() > 0) || (zero_yflux.size() > 0) || (zero_zflux.size() > 0)); } void display() @@ -295,9 +296,10 @@ struct AdvChoice { amrex::Real moistscal_horiz_upw_frac = 1.0; amrex::Real moistscal_vert_upw_frac = 1.0; - // Thin immersed body + // Thin immersed bodies amrex::Vector zero_xflux; amrex::Vector zero_yflux; amrex::Vector zero_zflux; + bool have_zero_flux_faces = false; }; #endif diff --git a/Source/DataStructs/ERF_DataStruct.H b/Source/DataStructs/ERF_DataStruct.H index c7e9e6b32..13270cdd0 100644 --- a/Source/DataStructs/ERF_DataStruct.H +++ b/Source/DataStructs/ERF_DataStruct.H @@ -318,12 +318,14 @@ struct SolverChoice { pp.query("use_moist_background", use_moist_background); // Use numerical diffusion? - pp.query("use_NumDiff",use_NumDiff); - if(use_NumDiff) { - pp.query("NumDiffCoeff",NumDiffCoeff); - AMREX_ASSERT_WITH_MESSAGE(( (NumDiffCoeff >= 0.) && (NumDiffCoeff <= 1.) ), - "Numerical diffusion coefficient must be between 0 & 1."); - NumDiffCoeff *= std::pow(2.0,-6); + pp.query("num_diff_coeff",num_diff_coeff); + AMREX_ASSERT_WITH_MESSAGE(( (num_diff_coeff >= 0.) && (num_diff_coeff <= 1.) ), + "Numerical diffusion coefficient must be between 0 & 1."); + use_num_diff = (num_diff_coeff > 0); + if (use_num_diff) { + amrex::Print() << "6th-order numerical diffusion turned on with coefficient = " + << num_diff_coeff << std::endl; + num_diff_coeff *= std::pow(2.0,-6); } // Use monotonic advection? @@ -508,7 +510,6 @@ struct SolverChoice { pp.query("rotational_time_period", rot_time_period); coriolis_factor = 2.0 * 2.0 * PI / rot_time_period; - amrex::Print() << "Coriolis factor = " << coriolis_factor << std::endl; amrex::Real latitude = 90.0; pp.query("latitude", latitude); @@ -653,8 +654,8 @@ struct SolverChoice { PerturbationType pert_type; // Numerical diffusion - bool use_NumDiff{false}; - amrex::Real NumDiffCoeff{0.}; + bool use_num_diff{false}; + amrex::Real num_diff_coeff{0.}; // Monotonic advection limiter bool use_mono_adv{false}; diff --git a/Source/DataStructs/ERF_DiffStruct.H b/Source/DataStructs/ERF_DiffStruct.H index 3d5fdc60d..53098065d 100644 --- a/Source/DataStructs/ERF_DiffStruct.H +++ b/Source/DataStructs/ERF_DiffStruct.H @@ -22,12 +22,6 @@ struct DiffChoice { { amrex::ParmParse pp(pp_prefix); - // Diffusive constants... - pp.query("alpha_T", alpha_T); - pp.query("alpha_C", alpha_C); - pp.query("dynamicViscosity", dynamicViscosity); - pp.query("rho0_trans", rho0_trans); - static std::string molec_diff_type_string = "None"; pp.query("molec_diff_type",molec_diff_type_string); @@ -41,16 +35,30 @@ struct DiffChoice { amrex::Error("Don't know this molec_diff_type"); } + if (molec_diff_type != MolecDiffType::None) { + pp.query("alpha_T", alpha_T); + pp.query("alpha_C", alpha_C); + pp.query("dynamic_viscosity", dynamic_viscosity); + pp.query("rho0_trans", rho0_trans); + } + + // Compute relevant forms of diffusion parameters + rhoAlpha_T = rho0_trans * alpha_T; + rhoAlpha_C = rho0_trans * alpha_C; + if (molec_diff_type == MolecDiffType::ConstantAlpha) { amrex::Print() << "Using constant kinematic diffusion coefficients" << std::endl; - amrex::Print() << " momentum : " << dynamicViscosity/rho0_trans << " m^2/s" << std::endl; + amrex::Print() << " momentum : " << dynamic_viscosity/rho0_trans << " m^2/s" << std::endl; amrex::Print() << " temperature : " << alpha_T << " m^2/s" << std::endl; amrex::Print() << " scalar : " << alpha_C << " m^2/s" << std::endl; } + else if (molec_diff_type == MolecDiffType::Constant) { + amrex::Print() << "Using constant dynamic diffusion coefficients" << std::endl; + amrex::Print() << " momentum : " << dynamic_viscosity << " kg/(m-s)" << std::endl; + amrex::Print() << " temperature : " << rhoAlpha_T << " kg/(m-s)" << std::endl; + amrex::Print() << " scalar : " << rhoAlpha_C << " kg/(m-s)" << std::endl; + } - // Compute relevant forms of diffusion parameters - rhoAlpha_T = rho0_trans * alpha_T; - rhoAlpha_C = rho0_trans * alpha_C; } void display() @@ -59,7 +67,7 @@ struct DiffChoice { amrex::Print() << " rho0_trans : " << rho0_trans << std::endl; amrex::Print() << " alpha_T : " << alpha_T << std::endl; amrex::Print() << " alpha_C : " << alpha_C << std::endl; - amrex::Print() << " dynamicViscosity : " << dynamicViscosity << std::endl; + amrex::Print() << " dynamic_viscosity : " << dynamic_viscosity << std::endl; if (molec_diff_type == MolecDiffType::Constant) { amrex::Print() << "Using constant molecular diffusivity (relevant for DNS)" << std::endl; @@ -85,6 +93,6 @@ struct DiffChoice { // Dynamic diffusion coefficients [kg/(m-s)] amrex::Real rhoAlpha_T = 0.0; amrex::Real rhoAlpha_C = 0.0; - amrex::Real dynamicViscosity = 0.0; + amrex::Real dynamic_viscosity = 0.0; }; #endif diff --git a/Source/DataStructs/ERF_TurbStruct.H b/Source/DataStructs/ERF_TurbStruct.H index d649d61e7..dc9def089 100644 --- a/Source/DataStructs/ERF_TurbStruct.H +++ b/Source/DataStructs/ERF_TurbStruct.H @@ -5,6 +5,8 @@ AMREX_ENUM(LESType, None, Smagorinsky, Deardorff); +AMREX_ENUM(RANSType, None, kEqn); + AMREX_ENUM(PBLType, None, MYNN25, YSU); template @@ -36,6 +38,10 @@ struct TurbChoice { std::string les_type_string = "None"; query_one_or_per_level(pp, "les_type", les_type, lev, max_level); + // Which RANS closure? + std::string rans_type_string = "None"; + query_one_or_per_level(pp, "rans_type", rans_type, lev, max_level); + // Which PBL Closure static std::string pbl_type_string = "None"; query_one_or_per_level(pp, "pbl_type", pbl_type, lev, max_level); @@ -188,6 +194,9 @@ struct TurbChoice { amrex::Real theta_ref = 300.0; + // RANS type + RANSType rans_type; + // PBL model PBLType pbl_type; diff --git a/Source/ERF.H b/Source/ERF.H index aee84357e..4a6d87af4 100644 --- a/Source/ERF.H +++ b/Source/ERF.H @@ -177,6 +177,9 @@ public: void project_velocities_tb (int lev, amrex::Real dt, amrex::Vector& vars, amrex::MultiFab& p); + // Calculate wall distance by solving a Poisson equation + void poisson_wall_dist (int lev); + #ifdef ERF_USE_FFT void solve_with_fft (int lev, amrex::MultiFab& rhs, amrex::MultiFab& p, amrex::Array& fluxes); @@ -404,7 +407,7 @@ public: void init_from_hse (int lev); - void init_immersed_body (int lev, const amrex::BoxArray& ba, const amrex::DistributionMapping& dm); + void init_thin_body (int lev, const amrex::BoxArray& ba, const amrex::DistributionMapping& dm); #ifdef ERF_USE_MULTIBLOCK // constructor used when ERF is created by a multiblock driver @@ -853,6 +856,9 @@ private: amrex::Vector> z_t_rk; + // Wall distance function + amrex::Vector> walldist; + // Map scale factors amrex::Vector> mapfac_m; amrex::Vector> mapfac_u; @@ -975,11 +981,15 @@ private: // Time averaged velocity "u_t_avg", "v_t_avg", "w_t_avg", "umag_t_avg", // eddy viscosity + "nut", + // eddy diffusivity of momentum "Kmv","Kmh", // eddy diffusivity of heat "Khv","Khh", - // mynn pbl lengthscale + // turbulence lengthscale "Lturb", + // wall distance + "walldist", // moisture vars "qt", "qv", "qc", "qi", "qp", "qrain", "qsnow", "qgraup", "qsat", "rain_accum", "snow_accum", "graup_accum", diff --git a/Source/ERF.cpp b/Source/ERF.cpp index 3759ede46..f7a5acb4c 100644 --- a/Source/ERF.cpp +++ b/Source/ERF.cpp @@ -288,6 +288,9 @@ ERF::ERF_shared () z_t_rk.resize(nlevs_max); + // Wall distance + walldist.resize(nlevs_max); + // Mapfactors mapfac_m.resize(nlevs_max); mapfac_u.resize(nlevs_max); @@ -665,58 +668,11 @@ ERF::InitData_post () } } - // If using the Deardoff LES model, - // we initialize rho_KE to be nonzero (and positive) so that we end up - // with reasonable values for the eddy diffusivity and the MOST fluxes - // (~ 1/diffusivity) do not blow up - Real RhoKE_0; - ParmParse pp(pp_prefix); - if (pp.query("RhoKE_0", RhoKE_0)) { - // Uniform initial rho*e field - for (int lev = 0; lev <= finest_level; lev++) { - if (solverChoice.turbChoice[lev].les_type == LESType::Deardorff) { - Print() << "Initializing uniform rhoKE=" << RhoKE_0 - << " on level " << lev - << std::endl; - vars_new[lev][Vars::cons].setVal(RhoKE_0,RhoKE_comp,1,0); - } else { - vars_new[lev][Vars::cons].setVal(0.0,RhoKE_comp,1,0); - } - } - } - - Real KE_0; - if (pp.query("KE_0", KE_0)) { - // Uniform initial e field - for (int lev = 0; lev <= finest_level; lev++) { - auto& lev_new = vars_new[lev]; - if (solverChoice.turbChoice[lev].les_type == LESType::Deardorff) { - Print() << "Initializing uniform KE=" << KE_0 - << " on level " << lev - << std::endl; - for (MFIter mfi(lev_new[Vars::cons], TilingIfNotGPU()); mfi.isValid(); ++mfi) { - const Box &bx = mfi.tilebox(); - const auto &cons_arr = lev_new[Vars::cons].array(mfi); - // We want to set the lateral BC values, too - Box gbx = bx; // Copy constructor - gbx.grow(0,1); gbx.grow(1,1); // Grow by one in the lateral directions - ParallelFor(gbx, [=] AMREX_GPU_DEVICE (int i, int j, int k) noexcept { - cons_arr(i,j,k,RhoKE_comp) = cons_arr(i,j,k,Rho_comp) * KE_0; - }); - } // mfi - } else { - lev_new[Vars::cons].setVal(0.0,RhoKE_comp,1,0); - } - } // lev - } - if (solverChoice.coupling_type == CouplingType::TwoWay) { AverageDown(); } - if ((solverChoice.advChoice.zero_xflux.size() > 0) || - (solverChoice.advChoice.zero_yflux.size() > 0) || - (solverChoice.advChoice.zero_zflux.size() > 0)) + if (solverChoice.advChoice.have_zero_flux_faces) { AMREX_ALWAYS_ASSERT_WITH_MESSAGE(finest_level == 0, "Thin immersed body with refinement not currently supported."); diff --git a/Source/ERF_MakeNewArrays.cpp b/Source/ERF_MakeNewArrays.cpp index 40a67bbb5..5c3d91ad8 100644 --- a/Source/ERF_MakeNewArrays.cpp +++ b/Source/ERF_MakeNewArrays.cpp @@ -66,7 +66,7 @@ ERF::init_stuff (int lev, const BoxArray& ba, const DistributionMapping& dm, ba_nd.surroundingNodes(); // We need this to be one greater than the ghost cells to handle levels > 0 - int ngrow = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_NumDiff) + 2; + int ngrow = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_num_diff) + 2; tmp_zphys_nd = std::make_unique(ba_nd,dm,1,IntVect(ngrow,ngrow,ngrow)); if (solverChoice.terrain_type == TerrainType::Moving) { @@ -87,16 +87,26 @@ ERF::init_stuff (int lev, const BoxArray& ba, const DistributionMapping& dm, z_t_rk[lev] = nullptr; } - // We use these area arrays regardless of terrain, EB or none of the above - detJ_cc[lev] = std::make_unique(ba,dm,1,1); - ax[lev] = std::make_unique(convert(ba,IntVect(1,0,0)),dm,1,1); - ay[lev] = std::make_unique(convert(ba,IntVect(0,1,0)),dm,1,1); - az[lev] = std::make_unique(convert(ba,IntVect(0,0,1)),dm,1,1); + // We use these area arrays regardless of terrain, EB or none of the above + detJ_cc[lev] = std::make_unique(ba,dm,1,1); + ax[lev] = std::make_unique(convert(ba,IntVect(1,0,0)),dm,1,1); + ay[lev] = std::make_unique(convert(ba,IntVect(0,1,0)),dm,1,1); + az[lev] = std::make_unique(convert(ba,IntVect(0,0,1)),dm,1,1); - detJ_cc[lev]->setVal(1.0); - ax[lev]->setVal(1.0); - ay[lev]->setVal(1.0); - az[lev]->setVal(1.0); + detJ_cc[lev]->setVal(1.0); + ax[lev]->setVal(1.0); + ay[lev]->setVal(1.0); + az[lev]->setVal(1.0); + + // ******************************************************************************************** + // Create wall distance array for RANS modeling + // ******************************************************************************************** + if (solverChoice.turbChoice[lev].rans_type != RANSType::None) { + walldist[lev] = std::make_unique(ba,dm,1,1); + walldist[lev]->setVal(1e23); + } else { + walldist[lev] = nullptr; + } // ******************************************************************************************** // These are the persistent containers for the old and new data @@ -113,8 +123,8 @@ ERF::init_stuff (int lev, const BoxArray& ba, const DistributionMapping& dm, // The number of ghost cells for density must be 1 greater than that for velocity // so that we can go back in forth between velocity and momentum on all faces // ******************************************************************************************** - int ngrow_state = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_NumDiff) + 1; - int ngrow_vels = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_NumDiff); + int ngrow_state = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_num_diff) + 1; + int ngrow_vels = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_num_diff); // ******************************************************************************************** // New solution data containers @@ -237,7 +247,7 @@ ERF::init_stuff (int lev, const BoxArray& ba, const DistributionMapping& dm, #if defined(ERF_USE_WINDFARM) //********************************************************* - // Variables for Ftich model for windfarm parametrization + // Variables for Fitch model for windfarm parametrization //********************************************************* if (solverChoice.windfarm_type == WindFarmType::Fitch){ vars_windfarm[lev].define(ba, dm, 5, ngrow_state); // V, dVabsdt, dudt, dvdt, dTKEdt diff --git a/Source/ERF_MakeNewLevel.cpp b/Source/ERF_MakeNewLevel.cpp index 51ceac884..addc31964 100644 --- a/Source/ERF_MakeNewLevel.cpp +++ b/Source/ERF_MakeNewLevel.cpp @@ -101,7 +101,7 @@ void ERF::MakeNewLevelFromScratch (int lev, Real time, const BoxArray& ba_in, // ******************************************************************************************** // Thin immersed body // ******************************************************************************************* - init_immersed_body(lev, ba, dm); + init_thin_body(lev, ba, dm); // ******************************************************************************************** // Initialize the integrator class @@ -144,6 +144,14 @@ void ERF::MakeNewLevelFromScratch (int lev, Real time, const BoxArray& ba_in, if (solverChoice.do_forest_drag) { m_forest_drag[lev]->define_drag_field(ba, dm, geom[lev], z_phys_nd[lev].get()); } if (solverChoice.do_terrain_drag) { m_terrain_drag[lev]->define_terrain_blank_field(ba, dm, geom[lev], z_phys_nd[lev].get()); } + + //******************************************************************************************** + // Create wall distance field for RANS model (depends upon z_phys) + // ******************************************************************************************* + if (solverChoice.turbChoice[lev].rans_type != RANSType::None) { + poisson_wall_dist(lev); + } + //******************************************************************************************** // Microphysics // ******************************************************************************************* @@ -318,7 +326,7 @@ ERF::RemakeLevel (int lev, Real time, const BoxArray& ba, const DistributionMapp int ncomp_cons = vars_new[lev][Vars::cons].nComp(); IntVect ngrow_state = vars_new[lev][Vars::cons].nGrowVect(); - int ngrow_vels = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_NumDiff); + int ngrow_vels = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_num_diff); Vector temp_lev_new(Vars::NumTypes); Vector temp_lev_old(Vars::NumTypes); @@ -496,7 +504,7 @@ ERF::ClearLevel (int lev) } void -ERF::init_immersed_body (int lev, const BoxArray& ba, const DistributionMapping& dm) +ERF::init_thin_body (int lev, const BoxArray& ba, const DistributionMapping& dm) { //******************************************************************************************** // Thin immersed body @@ -544,7 +552,7 @@ ERF::init_immersed_body (int lev, const BoxArray& ba, const DistributionMapping& } if (solverChoice.advChoice.zero_yflux.size() > 0) { - amrex::Print() << "Setting up thin interface boundary for " + amrex::Print() << "Setting up thin immersed body for " << solverChoice.advChoice.zero_yflux.size() << " yfaces" << std::endl; BoxArray ba_yf(ba); ba_yf.surroundingNodes(1); @@ -576,7 +584,7 @@ ERF::init_immersed_body (int lev, const BoxArray& ba, const DistributionMapping& } if (solverChoice.advChoice.zero_zflux.size() > 0) { - amrex::Print() << "Setting up thin interface boundary for " + amrex::Print() << "Setting up thin immersed body for " << solverChoice.advChoice.zero_zflux.size() << " zfaces" << std::endl; BoxArray ba_zf(ba); ba_zf.surroundingNodes(2); diff --git a/Source/ERF_ProbCommon.H b/Source/ERF_ProbCommon.H index 75c4464a4..6211fe02c 100644 --- a/Source/ERF_ProbCommon.H +++ b/Source/ERF_ProbCommon.H @@ -274,11 +274,14 @@ public: const amrex::Real& time) { // Check if a valid text file exists for the terrain - std::string fname; + std::string fname, fname_usgs, ftype; amrex::ParmParse pp("erf"); auto valid_fname = pp.query("terrain_file_name",fname); + auto valid_fname_USGS = pp.query("terrain_file_name_USGS",fname_usgs); if (valid_fname) { this->read_custom_terrain(fname,geom,z_phys_nd,time); + } else if(valid_fname_USGS) { + this->read_custom_terrain_USGS(fname_usgs,geom,z_phys_nd,time); } else { // Note that this only sets the terrain value at the ground IF k=0 is in the box amrex::Print() << "Initializing flat terrain at z=0" << std::endl; @@ -308,6 +311,7 @@ public: } } + /** * Function to perform custom initialization of terrain * @@ -423,6 +427,187 @@ public: } } + virtual void + read_custom_terrain_USGS (const std::string& fname_usgs, + const amrex::Geometry& geom, + amrex::MultiFab& z_phys_nd, + const amrex::Real& /*time*/) + { + // Read terrain file on the host + amrex::Print()<<"Reading terrain file: "<< fname_usgs << std::endl; + std::ifstream file(fname_usgs); + + if (!file.is_open()) { + amrex::Abort("Error: Could not open the file " + fname_usgs + "\n"); + } + + // Check if file is empty + if (file.peek() == std::ifstream::traits_type::eof()) { + amrex::Abort("Error: The file " + fname_usgs + " is empty.\n"); + } + + amrex::Gpu::HostVector m_xterrain,m_yterrain,m_zterrain; + amrex::Real value1,value2,value3; + amrex::Real lat_min, lon_min; + int nlons, nlats; + + file >> lon_min >> lat_min; + if(std::fabs(lon_min) > 180.0) { + amrex::Error("The value of longitude for entry in the first line in " + fname_usgs + + " should not exceed 180. It is " + std::to_string(lon_min)); + } + if(std::fabs(lat_min) > 90.0) { + amrex::Error("The value of latitude for entry in the first line in " + fname_usgs + + " should not exceed 90. It is " + std::to_string(lat_min)); + } + + file >> nlons >> nlats; + + int counter = 0; + while(file >> value1 >> value2 >> value3){ + m_xterrain.push_back(value1); + if(counter%nlons==0) { + m_yterrain.push_back(value2); + } + m_zterrain.push_back(value3); + counter += 1; + } + file.close(); + + AMREX_ASSERT(m_xterrain.size() == static_cast(nlons*nlats)); + AMREX_ASSERT(m_yterrain.size() == static_cast(nlats)); + AMREX_ASSERT(m_zterrain.size() == static_cast(nlons*nlats)); + + // Shift the terrain so that there is some flat region for the + // inflow to come in + + amrex::ParmParse pp("erf"); + amrex::Real x_shift, y_shift; + pp.query("windfarm_x_shift",x_shift); + pp.query("windfarm_x_shift",y_shift); + + + for(auto& v : m_xterrain){ + v += x_shift; + } + for(auto& v : m_yterrain){ + v += y_shift; + } + + if (m_xterrain.empty()) { + amrex::Abort("Error: m_xterrain is empty!\n"); + } + + auto index = std::max_element(m_xterrain.begin(), m_xterrain.end()); + amrex::Real xmax_terrain = *index; + index = std::max_element(m_yterrain.begin(), m_yterrain.end()); + amrex::Real ymax_terrain = *index; + + index = std::min_element(m_zterrain.begin(), m_zterrain.end()); + amrex::Real zmin_terrain = *index; + + for(auto& v : m_zterrain){ + v -= zmin_terrain; + } + + // Copy data to the GPU + int nnode = nlons*nlats; + amrex::Gpu::DeviceVector d_xterrain(nnode),d_yterrain(nlats),d_zterrain(nnode); + amrex::Gpu::copy(amrex::Gpu::hostToDevice, m_xterrain.begin(), m_xterrain.end(), d_xterrain.begin()); + amrex::Gpu::copy(amrex::Gpu::hostToDevice, m_yterrain.begin(), m_yterrain.end(), d_yterrain.begin()); + amrex::Gpu::copy(amrex::Gpu::hostToDevice, m_zterrain.begin(), m_zterrain.end(), d_zterrain.begin()); + amrex::Real* d_xt = d_xterrain.data(); + amrex::Real* d_yt = d_yterrain.data(); + amrex::Real* d_zt = d_zterrain.data(); + + // Populate z_phys data + int ngrow = z_phys_nd.nGrow(); + auto dx = geom.CellSizeArray(); + auto ProbLoArr = geom.ProbLoArray(); + int ilo = geom.Domain().smallEnd(0); + int jlo = geom.Domain().smallEnd(1); + int klo = geom.Domain().smallEnd(2); + int ihi = geom.Domain().bigEnd(0) + 1; + int jhi = geom.Domain().bigEnd(1) + 1; + + for (amrex::MFIter mfi(z_phys_nd,amrex::TilingIfNotGPU()); mfi.isValid(); ++mfi ) + { + // Grown box with no z range + amrex::Box xybx = mfi.growntilebox(ngrow); + xybx.setRange(2,0); + + amrex::Array4 const& z_arr = z_phys_nd.array(mfi); + amrex::ParallelFor(xybx, [=] AMREX_GPU_DEVICE (int i, int j, int /*k*/) + { + // Clip indices for ghost-cells + int ii = amrex::min(amrex::max(i,ilo),ihi); + int jj = amrex::min(amrex::max(j,jlo),jhi); + + // Location of nodes + amrex::Real x = ProbLoArr[0] + ii * dx[0] + 1e-3; + amrex::Real y = ProbLoArr[1] + jj * dx[1] + 1e-3; + + if(x < x_shift or x > xmax_terrain or + y < y_shift or y > ymax_terrain) { + z_arr(i,j,klo) = 0.0; + } else { + int jindex_terrain = -1; + for (int it = 0; it < nlats && jindex_terrain == -1; it++) { + if (d_yt[it] > y) { + jindex_terrain = it-1; + } + } + //if(jindex_terrain == -1){ + // printf("Could not find the jindex for a y value of %0.15g\n",y); + //} + // Now the index to check for x goes from jindex_terrain*nlons to + // (jindex_terrain+1)*nlons-1 + int iindex_terrain=-1; + int gstart = jindex_terrain*nlons; + int gend = (jindex_terrain+1)*nlons-1; + for (int it = gstart; it <= gend && iindex_terrain == -1; it++) { + if (d_xt[it] > x) { + iindex_terrain = it-gstart; + } + } + //if(iindex_terrain == -1){ + // printf("Could not find the iindex for a x value of %0.15g for a y index of %d and y value of %0.15g\n",x, jindex_terrain,y); + //} + + // Now do an averaging + int ind11, ind12, ind21, ind22; + ind11 = jindex_terrain*nlons + iindex_terrain; + ind12 = ind11+nlons; + ind21 = ind11+1; + ind22 = ind12+1; + amrex::Real x1 = d_xt[ind11]; + amrex::Real x2 = d_xt[ind21]; + amrex::Real y1 = d_yt[jindex_terrain]; + amrex::Real y2 = d_yt[jindex_terrain+1]; + // Do bilinear interpolation + amrex::Real denom = (x2-x1)*(y2-y1); + amrex::Real w_11 = (x2-x)*(y2-y)/denom; + amrex::Real w_12 = (x2-x)*(y-y1)/denom; + amrex::Real w_21 = (x-x1)*(y2-y)/denom; + amrex::Real w_22 = (x-x1)*(y-y1)/denom; + + z_arr(i,j,klo) = w_11*d_zt[ind11] + w_12*d_zt[ind12] + w_21*d_zt[ind21] + w_22*d_zt[ind22]; + + //z_arr(i,j,klo) = 0.25*(d_zt[ind1] + d_zt[ind2] + d_zt[ind3] + d_zt[ind4]); + // Smoothen out the edges using Gaussian + /*amrex::Real sigma = 600.0; + amrex::Real fac = 2.0*sigma*sigma; + z_arr(i,j,klo) = z_arr(i,j,klo)*(1.0-exp(-(x-x_shift)*(x-x_shift)/fac))* + (1.0-exp(-(x-xmax_terrain)*(x-xmax_terrain)/fac))* + (1.0-exp(-(y-y_shift)*(y-y_shift)/fac))* + (1.0-exp(-(y-ymax_terrain)*(y-ymax_terrain)/fac)); */ + //std::cout << "Values of z is " << d_zt[ind1] << " " << d_zt[ind2] << " " << d_zt[ind3] << " " << d_zt[ind4] << "\n"; + } + }); + } + } + + #ifdef ERF_USE_TERRAIN_VELOCITY virtual amrex::Real compute_terrain_velocity(const amrex::Real /*time*/) { diff --git a/Source/IO/ERF_NCCheckpoint.cpp b/Source/IO/ERF_NCCheckpoint.cpp index 3ff06b215..b1b7a40d6 100644 --- a/Source/IO/ERF_NCCheckpoint.cpp +++ b/Source/IO/ERF_NCCheckpoint.cpp @@ -156,8 +156,8 @@ ERF::ReadNCCheckpointFile () ncf.var("dt") .get(dt.data(), {0}, {static_cast(ndt)}); ncf.var("t_new").get(t_new.data(), {0}, {static_cast(ntime)}); - int ngrow_state = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_NumDiff) + 1; - int ngrow_vels = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_NumDiff); + int ngrow_state = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_num_diff) + 1; + int ngrow_vels = ComputeGhostCells(solverChoice.advChoice, solverChoice.use_num_diff); for (int lev = 0; lev <= finest_level; ++lev) { diff --git a/Source/IO/ERF_Plotfile.cpp b/Source/IO/ERF_Plotfile.cpp index 26ed76e16..5ce963f46 100644 --- a/Source/IO/ERF_Plotfile.cpp +++ b/Source/IO/ERF_Plotfile.cpp @@ -1002,6 +1002,29 @@ ERF::WritePlotFile (int which, PlotFileType plotfile_type, Vector p } } + if (containerHasElement(plot_var_names, "nut")) { + MultiFab dmf(mf[lev], make_alias, mf_comp, 1); + MultiFab cmf(vars_new[lev][Vars::cons], make_alias, 0, 1); // to provide rho only +#ifdef _OPENMP +#pragma omp parallel if (amrex::Gpu::notInLaunchRegion()) +#endif + for (MFIter mfi(dmf, TilingIfNotGPU()); mfi.isValid(); ++mfi) + { + const Box& bx = mfi.tilebox(); + auto prim = dmf[mfi].array(); + auto const cons = cmf[mfi].const_array(); + auto const diff = (*eddyDiffs_lev[lev])[mfi].const_array(); + ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) noexcept + { + const Real rho = cons(i, j, k, Rho_comp); + const Real Kmv = diff(i, j, k, EddyDiff::Mom_v); + prim(i,j,k) = Kmv / rho; + }); + } + + mf_comp++; + } + if (containerHasElement(plot_var_names, "Kmv")) { MultiFab::Copy(mf[lev],*eddyDiffs_lev[lev],EddyDiff::Mom_v,mf_comp,1,0); mf_comp ++; @@ -1022,6 +1045,10 @@ ERF::WritePlotFile (int which, PlotFileType plotfile_type, Vector p MultiFab::Copy(mf[lev],*eddyDiffs_lev[lev],EddyDiff::Turb_lengthscale,mf_comp,1,0); mf_comp ++; } + if (containerHasElement(plot_var_names, "walldist")) { + MultiFab::Copy(mf[lev],*walldist[lev],0,mf_comp,1,0); + mf_comp ++; + } // TODO: The size of the q variables can vary with different // moisture models. Therefore, certain components may diff --git a/Source/Initialization/Make.package b/Source/Initialization/Make.package index 114b59052..3cc1d623d 100644 --- a/Source/Initialization/Make.package +++ b/Source/Initialization/Make.package @@ -10,7 +10,7 @@ CEXE_sources += ERF_Init1D.cpp CEXE_sources += ERF_InitTurbPert.cpp ifeq ($(USE_WINDFARM),TRUE) -CEXE_sources += ERFInitWindFarm.cpp +CEXE_sources += ERF_InitWindFarm.cpp endif ifeq ($(USE_NETCDF),TRUE) diff --git a/Source/LandSurfaceModel/NOAH/ERF_NOAH.H b/Source/LandSurfaceModel/NOAH/ERF_NOAH.H index 962c2dd2b..f88bcf5ae 100644 --- a/Source/LandSurfaceModel/NOAH/ERF_NOAH.H +++ b/Source/LandSurfaceModel/NOAH/ERF_NOAH.H @@ -31,11 +31,10 @@ public: const amrex::Geometry& geom, const amrex::Real& dt) override; - private: - // C++ variable for NoahmpIO struct - NoahmpIO_struct noahmpio; + // C++ variable for NoahmpIO type + NoahmpIO_type noahmpio; }; #endif diff --git a/Source/LandSurfaceModel/NOAH/ERF_NOAH.cpp b/Source/LandSurfaceModel/NOAH/ERF_NOAH.cpp index 3e4acf206..2d85d323e 100644 --- a/Source/LandSurfaceModel/NOAH/ERF_NOAH.cpp +++ b/Source/LandSurfaceModel/NOAH/ERF_NOAH.cpp @@ -20,7 +20,29 @@ NOAH::Init (const MultiFab& cons_in, * noahmpio.xend = 4; * noahmpio.ystart = 1; * noahmpio.yend = 2; + * noahmpio.nsoil = 1; + * noahmpio.nsnow = 3; * + * noahmpio.ids = 1; + * noahmpio.ide = 1; + * noahmpio.ims = 1; + * noahmpio.ime = 1; + * noahmpio.its = 1; + * noahmpio.ite = 1; + * + * noahmpio.jds = 1; + * noahmpio.jde = 1; + * noahmpio.jms = 1; + * noahmpio.jme = 1; + * noahmpio.jts = 1; + * noahmpio.jte = 1; + * + * noahmpio.kds = 1; + * noahmpio.kde = 1; + * noahmpio.kms = 1; + * noahmpio.kme = 1; + * noahmpio.kts = 1; + * noahmpio.kte = 1; */ NoahmpIOVarInitDefault(&noahmpio); diff --git a/Source/LinearSolvers/ERF_PoissonWallDist.cpp b/Source/LinearSolvers/ERF_PoissonWallDist.cpp new file mode 100644 index 000000000..2555e9204 --- /dev/null +++ b/Source/LinearSolvers/ERF_PoissonWallDist.cpp @@ -0,0 +1,310 @@ +#include "ERF.H" +#include "ERF_Utils.H" + +#include +#include + +using namespace amrex; + +/** + * Calculate wall distances using the Poisson equation + * + * See Tucker, P. G. (2003). Differential equation-based wall distance + * computation for DES and RANS. Journal of Computational Physics, + * 190(1), 229–248. https://doi.org/10.1016/S0021-9991(03)00272-9 + */ +void ERF::poisson_wall_dist (int lev) +{ + BL_PROFILE("ERF::poisson_wall_dist()"); + + auto const& geomdata = geom[lev]; + + if (solverChoice.mesh_type == MeshType::ConstantDz) { +// Comment this out to test the wall dist calc in the trivial case: +//#if 0 + Print() << "Directly calculating direct wall distance for constant dz" << std::endl; + const Real* prob_lo = geomdata.ProbLo(); + const Real* dx = geomdata.CellSize(); + for (MFIter mfi(*walldist[lev]); mfi.isValid(); ++mfi) { + const Box& bx = mfi.validbox(); + auto dist_arr = walldist[lev]->array(mfi); + ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) { + dist_arr(i, j, k) = prob_lo[2] + (k + 0.5) * dx[2]; + }); + } + return; +//#endif + } else if (solverChoice.mesh_type == MeshType::StretchedDz) { + // TODO: Handle this trivial case + Error("Wall dist calc not implemented with grid stretching yet"); + } else { + // TODO + Error("Wall dist calc not implemented over terrain yet"); + } + + Print() << "Calculating Poisson wall distance" << std::endl; + + // Make sure the solver only sees the levels over which we are solving + BoxArray nba = walldist[lev]->boxArray(); + nba.surroundingNodes(); + Vector geom_tmp; geom_tmp.push_back(geom[lev]); + Vector ba_tmp; ba_tmp.push_back(nba); + Vector dm_tmp; dm_tmp.push_back(walldist[lev]->DistributionMap()); + + Vector rhs; + Vector phi; + +#ifdef ERF_USE_EB + Error("Wall dist calc not implemented for EB"; +#else + rhs.resize(1); rhs[0].define(ba_tmp[0], dm_tmp[0], 1, 0); + phi.resize(1); phi[0].define(ba_tmp[0], dm_tmp[0], 1, 1); +#endif + + rhs[0].setVal(-1.0); + + // Define an overset mask to set dirichlet nodes on walls + iMultiFab mask(ba_tmp[0], dm_tmp[0], 1, 0); + Vector overset_mask = {&mask}; + + auto const dom_lo = lbound(geom[lev].Domain()); + auto const dom_hi = ubound(geom[lev].Domain()); + + // **************************************************************************** + // Initialize phi + // (It is essential that we do this in order to fill the corners; this is + // used if we include blanking.) + // **************************************************************************** + phi[0].setVal(0.0); + + // **************************************************************************** + // Interior boundaries are marked with phi=0 + // **************************************************************************** + // Overset mask is 0/1: 1 means the node is an unknown. 0 means it's known. + mask.setVal(1); + if (solverChoice.advChoice.have_zero_flux_faces) { + Warning("Poisson distance is inaccurate for bodies in open domains that are small compared to the domain size, skipping..."); + walldist[lev]->setVal(1e34); + return; +#if 0 + Gpu::DeviceVector xfacelist, yfacelist, zfacelist; + + xfacelist.resize(solverChoice.advChoice.zero_xflux.size()); + yfacelist.resize(solverChoice.advChoice.zero_yflux.size()); + zfacelist.resize(solverChoice.advChoice.zero_zflux.size()); + + if (xfacelist.size() > 0) { + Gpu::copy(amrex::Gpu::hostToDevice, + solverChoice.advChoice.zero_xflux.begin(), + solverChoice.advChoice.zero_xflux.end(), + xfacelist.begin()); + Print() << " masking interior xfaces" << std::endl; + } + if (yfacelist.size() > 0) { + Gpu::copy(amrex::Gpu::hostToDevice, + solverChoice.advChoice.zero_yflux.begin(), + solverChoice.advChoice.zero_yflux.end(), + yfacelist.begin()); + Print() << " masking interior yfaces" << std::endl; + } + if (zfacelist.size() > 0) { + Gpu::copy(amrex::Gpu::hostToDevice, + solverChoice.advChoice.zero_zflux.begin(), + solverChoice.advChoice.zero_zflux.end(), + zfacelist.begin()); + Print() << " masking interior zfaces" << std::endl; + } + + for (MFIter mfi(phi[0]); mfi.isValid(); ++mfi) { + const Box& bx = mfi.validbox(); + + auto phi_arr = phi[0].array(mfi); + auto mask_arr = mask.array(mfi); + + if (xfacelist.size() > 0) { + ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) { + for (int iface=0; iface < xfacelist.size(); ++iface) { + if ((i == xfacelist[iface][0]) && + (j == xfacelist[iface][1]) && + (k == xfacelist[iface][2])) + { + mask_arr(i, j , k ) = 0; + mask_arr(i, j , k+1) = 0; + mask_arr(i, j+1, k ) = 0; + mask_arr(i, j+1, k+1) = 0; + } + } + }); + } + + if (yfacelist.size() > 0) { + ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) { + for (int iface=0; iface < yfacelist.size(); ++iface) { + if ((i == yfacelist[iface][0]) && + (j == yfacelist[iface][1]) && + (k == yfacelist[iface][2])) + { + mask_arr(i , j, k ) = 0; + mask_arr(i , j, k+1) = 0; + mask_arr(i+1, j, k ) = 0; + mask_arr(i+1, j, k+1) = 0; + } + } + }); + } + + if (zfacelist.size() > 0) { + ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) { + for (int iface=0; iface < zfacelist.size(); ++iface) { + if ((i == xfacelist[iface][0]) && + (j == xfacelist[iface][1]) && + (k == xfacelist[iface][2])) + { + mask_arr(i , j , k) = 0; + mask_arr(i , j+1, k) = 0; + mask_arr(i+1, j , k) = 0; + mask_arr(i+1, j+1, k) = 0; + } + } + }); + } + } +#endif + } + + // **************************************************************************** + // Setup BCs, with solid domain boundaries being dirichlet + // We assume that the zlo boundary corresponds to the land surface + // **************************************************************************** + amrex::Array bc3d_lo, bc3d_hi; + Orientation zlo(Direction::z, Orientation::low); + bool havewall{false}; + for (int dir = 0; dir < AMREX_SPACEDIM; ++dir) { + if (geom[0].isPeriodic(dir)) { + bc3d_lo[dir] = LinOpBCType::Periodic; + bc3d_hi[dir] = LinOpBCType::Periodic; + } else { + bc3d_lo[dir] = LinOpBCType::Neumann; + bc3d_hi[dir] = LinOpBCType::Neumann; + } + } + if ( ( phys_bc_type[zlo] == ERF_BC::MOST ) || + ( phys_bc_type[zlo] == ERF_BC::no_slip_wall ) )/*|| + ((phys_bc_type[zlo] == ERF_BC::slip_wall) && (dom_hi.z > dom_lo.z)) )*/ + { + Print() << " Poisson zlo BC is dirichlet" << std::endl; + bc3d_lo[2] = LinOpBCType::Dirichlet; + havewall = true; + } + Print() << " bc lo : " << bc3d_lo << std::endl; + Print() << " bc hi : " << bc3d_hi << std::endl; + + if (!solverChoice.advChoice.have_zero_flux_faces && !havewall) { + Error("No solid boundaries in the computational domain"); + } + + LPInfo info; +/* Nodal solver cannot have hidden dimensions */ +#if 0 + // Allow a hidden direction if the domain is one cell wide + if (dom_lo.x == dom_hi.x) { + info.setHiddenDirection(0); + Print() << " domain is 2D in yz" << std::endl; + } else if (dom_lo.y == dom_hi.y) { + info.setHiddenDirection(1); + Print() << " domain is 2D in xz" << std::endl; + } else if (dom_lo.z == dom_hi.z) { + info.setHiddenDirection(2); + Print() << " domain is 2D in xy" << std::endl; + } +#endif + + // **************************************************************************** + // Solve nodal masked Poisson problem with MLMG + // TODO: different solver for terrain? + // **************************************************************************** + const Real reltol = solverChoice.poisson_reltol; + const Real abstol = solverChoice.poisson_abstol; + + Real sigma = 1.0; + MLNodeLaplacian mlpoisson(geom_tmp, ba_tmp, dm_tmp, info, {}, sigma); + + mlpoisson.setDomainBC(bc3d_lo, bc3d_hi); + + if (lev > 0) { + mlpoisson.setCoarseFineBC(nullptr, ref_ratio[lev-1], LinOpBCType::Neumann); + } + + mlpoisson.setLevelBC(0, nullptr); + + mlpoisson.setOversetMask(0, mask); + + // Solve + MLMG mlmg(mlpoisson); + int max_iter = 100; + mlmg.setMaxIter(max_iter); + + mlmg.setVerbose(mg_verbose); + mlmg.setBottomVerbose(0); + + mlmg.solve(GetVecOfPtrs(phi), + GetVecOfConstPtrs(rhs), + reltol, abstol); + + // Now overwrite with periodic fill outside domain and fine-fine fill inside + phi[0].FillBoundary(geom[lev].periodicity()); + + // **************************************************************************** + // Compute grad(phi) to get distances + // - Note that phi is nodal and walldist is cell-centered + // - TODO: include terrain metrics for dphi/dz + // **************************************************************************** + for (MFIter mfi(*walldist[lev]); mfi.isValid(); ++mfi) { + const Box& bx = mfi.validbox(); + + const auto invCellSize = geomdata.InvCellSizeArray(); + + auto const& phi_arr = phi[0].const_array(mfi); + auto dist_arr = walldist[lev]->array(mfi); + + ParallelFor(bx, [=] AMREX_GPU_DEVICE(int i, int j, int k) { + Real dpdx{0}, dpdy{0}, dpdz{0}; + + // dphi/dx + if (dom_lo.x != dom_hi.x) { + dpdx = 0.25 * invCellSize[0] * ( + (phi_arr(i+1, j , k ) - phi_arr(i, j , k )) + + (phi_arr(i+1, j , k+1) - phi_arr(i, j , k+1)) + + (phi_arr(i+1, j+1, k ) - phi_arr(i, j+1, k )) + + (phi_arr(i+1, j+1, k+1) - phi_arr(i, j+1, k+1)) ); + } + + // dphi/dy + if (dom_lo.y != dom_hi.y) { + dpdy = 0.25 * invCellSize[1] * ( + (phi_arr(i , j+1, k ) - phi_arr(i , j, k )) + + (phi_arr(i , j+1, k+1) - phi_arr(i , j, k+1)) + + (phi_arr(i+1, j+1, k ) - phi_arr(i+1, j, k )) + + (phi_arr(i+1, j+1, k+1) - phi_arr(i+1, j, k+1)) ); + } + + // dphi/dz + if (dom_lo.z != dom_hi.z) { + dpdz = 0.25 * invCellSize[2] * ( + (phi_arr(i , j , k+1) - phi_arr(i , j , k)) + + (phi_arr(i , j+1, k+1) - phi_arr(i , j+1, k)) + + (phi_arr(i+1, j , k+1) - phi_arr(i+1, j , k)) + + (phi_arr(i+1, j+1, k+1) - phi_arr(i+1, j+1, k)) ); + } + + Real dp_dot_dp = dpdx*dpdx + dpdy*dpdy + dpdz*dpdz; + Real phi_avg = 0.125 * ( + phi_arr(i , j , k ) + phi_arr(i , j , k+1) + phi_arr(i , j+1, k ) + phi_arr(i , j+1, k+1) + + phi_arr(i+1, j , k ) + phi_arr(i+1, j , k+1) + phi_arr(i+1, j+1, k ) + phi_arr(i+1, j+1, k+1) ); + dist_arr(i, j, k) = -std::sqrt(dp_dot_dp) + std::sqrt(dp_dot_dp + 2*phi_avg); + + // DEBUG: output phi instead + //dist_arr(i, j, k) = phi_arr(i, j, k); + }); + } +} diff --git a/Source/LinearSolvers/Make.package b/Source/LinearSolvers/Make.package index e966146b8..a499733e3 100644 --- a/Source/LinearSolvers/Make.package +++ b/Source/LinearSolvers/Make.package @@ -5,6 +5,7 @@ CEXE_sources += ERF_TerrainPoisson.cpp CEXE_sources += ERF_ComputeDivergence.cpp CEXE_sources += ERF_PoissonSolve.cpp CEXE_sources += ERF_PoissonSolve_tb.cpp +CEXE_sources += ERF_PoissonWallDist.cpp CEXE_sources += ERF_SolveWithGMRES.cpp CEXE_sources += ERF_SolveWithMLMG.cpp diff --git a/Source/Microphysics/ERF_EulerianMicrophysics.H b/Source/Microphysics/ERF_EulerianMicrophysics.H index edf9c34cd..38d561b71 100644 --- a/Source/Microphysics/ERF_EulerianMicrophysics.H +++ b/Source/Microphysics/ERF_EulerianMicrophysics.H @@ -71,7 +71,8 @@ public: const amrex::Real&, /*!< current time */ const SolverChoice &solverChoice, /*!< Solver choice object */ amrex::Vector>&, /*!< Dycore state variables */ - const amrex::Vector>& /*!< terrain */) override + const amrex::Vector>&, /*!< terrain */ + const amrex::GpuArray& ) override { m_moist_model[lev]->Advance(dt_advance, solverChoice); } diff --git a/Source/Microphysics/ERF_LagrangianMicrophysics.H b/Source/Microphysics/ERF_LagrangianMicrophysics.H index 8ee581abe..e6cabb332 100644 --- a/Source/Microphysics/ERF_LagrangianMicrophysics.H +++ b/Source/Microphysics/ERF_LagrangianMicrophysics.H @@ -70,10 +70,11 @@ public: const amrex::Real& time, /*!< current time */ const SolverChoice& /*solverChoice*/, /*!< Solver choice object */ amrex::Vector>& a_vars, /*!< Dycore state variables */ - const amrex::Vector>& a_z/*!< terrain */) override + const amrex::Vector>& a_z/*!< terrain */, + const amrex::GpuArray& a_phys_bc_types ) override { if (lev > 0) return; - m_moist_model->Advance(dt_advance, iter, time, a_vars, a_z); + m_moist_model->Advance(dt_advance, iter, time, a_vars, a_z, a_phys_bc_types); } /*! \brief update microphysics variables from ERF state variables */ diff --git a/Source/Microphysics/ERF_Microphysics.H b/Source/Microphysics/ERF_Microphysics.H index 084572e0f..cfca27cae 100644 --- a/Source/Microphysics/ERF_Microphysics.H +++ b/Source/Microphysics/ERF_Microphysics.H @@ -8,6 +8,7 @@ #include #include #include "ERF_DataStruct.H" +#include "ERF_IndexDefines.H" /*! \brief Base class for microphysics interface */ class Microphysics { @@ -39,7 +40,8 @@ public: const amrex::Real&, const SolverChoice&, amrex::Vector>&, - const amrex::Vector>& ) = 0; + const amrex::Vector>&, + const amrex::GpuArray& ) = 0; /*! \brief update microphysics variables from ERF state variables */ virtual void Update_Micro_Vars_Lev (const int&, amrex::MultiFab&) = 0; diff --git a/Source/Microphysics/Null/ERF_NullMoistLagrangian.H b/Source/Microphysics/Null/ERF_NullMoistLagrangian.H index f05e93006..981e02652 100644 --- a/Source/Microphysics/Null/ERF_NullMoistLagrangian.H +++ b/Source/Microphysics/Null/ERF_NullMoistLagrangian.H @@ -7,6 +7,7 @@ #ifdef ERF_USE_PARTICLES #include +#include "ERF_IndexDefines.H" #include "ERF_NullMoist.H" /* forward declaration */ @@ -53,7 +54,8 @@ public: const int&, /* iter */ const amrex::Real&, /* time */ amrex::Vector>&, /* state variables */ - const amrex::Vector>& /* terrain */) { } + const amrex::Vector>&, /* terrain */ + const amrex::GpuArray& ) { } protected: diff --git a/Source/SourceTerms/ERF_MakeMomSources.cpp b/Source/SourceTerms/ERF_MakeMomSources.cpp index a6c05c654..b0981c485 100644 --- a/Source/SourceTerms/ERF_MakeMomSources.cpp +++ b/Source/SourceTerms/ERF_MakeMomSources.cpp @@ -90,7 +90,7 @@ void make_mom_sources (int level, // 9. Forest canopy // 10. Immersed Forcing // ***************************************************************************** - const bool l_use_ndiff = solverChoice.use_NumDiff; + //const bool l_use_ndiff = solverChoice.use_num_diff; const bool l_use_zphys = (solverChoice.mesh_type != MeshType::ConstantDz); const bool l_do_forest_drag = solverChoice.do_forest_drag; const bool l_do_terrain_drag = solverChoice.do_terrain_drag; @@ -479,14 +479,16 @@ void make_mom_sources (int level, // ***************************************************************************** // 7. Add NUMERICAL DIFFUSION terms // ***************************************************************************** +#if 0 if (l_use_ndiff) { - /* - NumericalDiffusion_Xmom(tbx, dt, solverChoice.NumDiffCoeff, + const Array4& mf_u = mapfac_u->const_array(mfi); + const Array4& mf_v = mapfac_v->const_array(mfi); + NumericalDiffusion_Xmom(tbx, dt, solverChoice.num_diff_coeff, u, cell_data, xmom_src_arr, mf_u); - NumericalDiffusion_Ymom(tby, dt, solverChoice.NumDiffCoeff, + NumericalDiffusion_Ymom(tby, dt, solverChoice.num_diff_coeff, v, cell_data, ymom_src_arr, mf_v); - */ } +#endif // ***************************************************************************** // 8. Add SPONGING diff --git a/Source/SourceTerms/ERF_MakeSources.cpp b/Source/SourceTerms/ERF_MakeSources.cpp index c770badfa..c4524b4ab 100644 --- a/Source/SourceTerms/ERF_MakeSources.cpp +++ b/Source/SourceTerms/ERF_MakeSources.cpp @@ -57,7 +57,7 @@ void make_sources (int level, // ***************************************************************************** source.setVal(0.0); - const bool l_use_ndiff = solverChoice.use_NumDiff; + const bool l_use_ndiff = solverChoice.use_num_diff; const bool use_terrain = solverChoice.terrain_type != TerrainType::None; TurbChoice tc = solverChoice.turbChoice[level]; @@ -335,20 +335,20 @@ void make_sources (int level, const Array4& mf_m = mapfac_m->const_array(mfi); // Rho is a special case - NumericalDiffusion_Scal(bx, sc=0, nc=1, dt, solverChoice.NumDiffCoeff, + NumericalDiffusion_Scal(bx, sc=0, nc=1, dt, solverChoice.num_diff_coeff, cell_data, cell_data, cell_src, mf_m); // Other scalars proceed as normal - NumericalDiffusion_Scal(bx, sc=1, nc=1, dt, solverChoice.NumDiffCoeff, + NumericalDiffusion_Scal(bx, sc=1, nc=1, dt, solverChoice.num_diff_coeff, cell_prim, cell_data, cell_src, mf_m); if (l_use_KE && l_diff_KE) { - NumericalDiffusion_Scal(bx, sc=RhoKE_comp, nc=1, dt, solverChoice.NumDiffCoeff, + NumericalDiffusion_Scal(bx, sc=RhoKE_comp, nc=1, dt, solverChoice.num_diff_coeff, cell_prim, cell_data, cell_src, mf_m); } - NumericalDiffusion_Scal(bx, sc=RhoScalar_comp, nc=NSCALARS, dt, solverChoice.NumDiffCoeff, + NumericalDiffusion_Scal(bx, sc=RhoScalar_comp, nc=NSCALARS, dt, solverChoice.num_diff_coeff, cell_prim, cell_data, cell_src, mf_m); } diff --git a/Source/TimeIntegration/ERF_AdvanceDycore.cpp b/Source/TimeIntegration/ERF_AdvanceDycore.cpp index e736528ee..89b28be58 100644 --- a/Source/TimeIntegration/ERF_AdvanceDycore.cpp +++ b/Source/TimeIntegration/ERF_AdvanceDycore.cpp @@ -249,11 +249,11 @@ void ERF::advance_dycore(int level, // // This is an optimization since we won't need more than one ghost - // cell of momentum in the integrator if not using NumDiff + // cell of momentum in the integrator if not using numerical diffusion // - IntVect ngu = (!solverChoice.use_NumDiff) ? IntVect(1,1,1) : xvel_old.nGrowVect(); - IntVect ngv = (!solverChoice.use_NumDiff) ? IntVect(1,1,1) : yvel_old.nGrowVect(); - IntVect ngw = (!solverChoice.use_NumDiff) ? IntVect(1,1,0) : zvel_old.nGrowVect(); + IntVect ngu = (!solverChoice.use_num_diff) ? IntVect(1,1,1) : xvel_old.nGrowVect(); + IntVect ngv = (!solverChoice.use_num_diff) ? IntVect(1,1,1) : yvel_old.nGrowVect(); + IntVect ngw = (!solverChoice.use_num_diff) ? IntVect(1,1,0) : zvel_old.nGrowVect(); VelocityToMomentum(xvel_old, ngu, yvel_old, ngv, zvel_old, ngw, density, state_old[IntVars::xmom], diff --git a/Source/TimeIntegration/ERF_AdvanceMicrophysics.cpp b/Source/TimeIntegration/ERF_AdvanceMicrophysics.cpp index 93b37ff3d..e764b7f43 100644 --- a/Source/TimeIntegration/ERF_AdvanceMicrophysics.cpp +++ b/Source/TimeIntegration/ERF_AdvanceMicrophysics.cpp @@ -10,7 +10,7 @@ void ERF::advance_microphysics (int lev, { if (solverChoice.moisture_type != MoistureType::None) { micro->Update_Micro_Vars_Lev(lev, cons); - micro->Advance(lev, dt_advance, iteration, time, solverChoice, vars_new, z_phys_nd); + micro->Advance(lev, dt_advance, iteration, time, solverChoice, vars_new, z_phys_nd, phys_bc_type); micro->Update_State_Vars_Lev(lev, cons); } } diff --git a/Source/TimeIntegration/ERF_ComputeTimestep.cpp b/Source/TimeIntegration/ERF_ComputeTimestep.cpp index 5c79fb85a..bd43780be 100644 --- a/Source/TimeIntegration/ERF_ComputeTimestep.cpp +++ b/Source/TimeIntegration/ERF_ComputeTimestep.cpp @@ -204,7 +204,6 @@ ERF::estTimeStep (int level, long& dt_fast_ratio) const } else if (fixed_dt[level] > 0.) { // Max CFL_c = 1.0 for substeps by default, but we enforce a min of 4 substeps auto dt_sub_max = (estdt_comp/cfl * sub_cfl); - Print() << "fixed_dt="<> lon_ref >> lat_ref; + file_usgs.close(); + lon_ref = lon_ref*M_PI/180.0; + lat_ref = lat_ref*M_PI/180.0; + } else { + Real lat_min = *std::min_element(lat.begin(), lat.end()); + Real lon_min = *std::min_element(lon.begin(), lon.end()); - Real lat_min = *std::min_element(lat.begin(), lat.end()); - Real lat_max = *std::max_element(lat.begin(), lat.end()); - Real lon_min = *std::min_element(lon.begin(), lon.end()); - Real lon_max = *std::max_element(lon.begin(), lon.end()); - - Real lat_cen = 0.5*(lat_min+lat_max)*M_PI/180.0; - Real lon_cen = 0.5*(lon_min+lon_max)*M_PI/180.0; - - // (lat_lo, lon_lo) is mapped to (0,0) + lon_ref = lon_min*M_PI/180.0; + lat_ref = lat_min*M_PI/180.0; + } for(int it=0;it= 0.0) { xloc.push_back(dx_turb); } @@ -119,12 +144,9 @@ WindFarm::init_windfarm_lat_lon (const std::string windfarm_loc_table, yloc.push_back(dy_turb); } - Real xloc_min = *std::min_element(xloc.begin(),xloc.end()); - Real yloc_min = *std::min_element(yloc.begin(),yloc.end()); - for(int it = 0;it ProbLoArr[0] and + xloc[it] < ProbHiArr[0] and + yloc[it] > ProbLoArr[1] and + yloc[it] < ProbHiArr[1] ) { + if(is_counted[it] != 1) { + Abort("Wind turbine " + std::to_string(it) + "has been counted " + std::to_string(is_counted[it]) + " times" + + " It should have been counted only once. Aborting...."); + } } } diff --git a/Source/WindFarmParametrization/Make.package b/Source/WindFarmParametrization/Make.package index 10f6ffb07..78c13af5d 100644 --- a/Source/WindFarmParametrization/Make.package +++ b/Source/WindFarmParametrization/Make.package @@ -1,2 +1,2 @@ CEXE_headers += ERF_WindFarm.H -CEXE_sources += ERF_InitWindFarm.cpp +CEXE_sources += ERF_WindFarm.cpp diff --git a/Submodules/NOAH-MP b/Submodules/NOAH-MP index 482646ac5..d549c42eb 160000 --- a/Submodules/NOAH-MP +++ b/Submodules/NOAH-MP @@ -1 +1 @@ -Subproject commit 482646ac5641492048973f7706db57145a3db11a +Subproject commit d549c42ebfbf8c64a5fdc66921018c69f28bab1e diff --git a/Tests/CTestList.cmake b/Tests/CTestList.cmake index eb3c85732..ba86ee5c9 100644 --- a/Tests/CTestList.cmake +++ b/Tests/CTestList.cmake @@ -28,7 +28,7 @@ macro(setup_test) endmacro(setup_test) # Standard regression test -function(add_test_r TEST_NAME TEST_EXE PLTFILE) +function(add_test_r TEST_NAME TEST_DIR TEST_EXE PLTFILE) set(options ) set(oneValueArgs "INPUT_SOUNDING" "RUNTIME_OPTIONS") set(multiValueArgs ) @@ -42,7 +42,12 @@ function(add_test_r TEST_NAME TEST_EXE PLTFILE) string(APPEND RUNTIME_OPTIONS "erf.input_sounding_file=${CURRENT_TEST_BINARY_DIR}/${ADD_TEST_R_INPUT_SOUNDING}") endif() - set(TEST_EXE ${CMAKE_BINARY_DIR}/Exec/${TEST_EXE}) + if(WIN32) + set(TEST_EXE "${CMAKE_BINARY_DIR}/Exec/${TEST_DIR}/*/${TEST_EXE}.exe") + else() + set(TEST_EXE "${CMAKE_BINARY_DIR}/Exec/${TEST_DIR}/${TEST_EXE}") + endif() + set(FCOMPARE_TOLERANCE "-r ${ERF_TEST_FCOMPARE_RTOL} --abs_tol ${ERF_TEST_FCOMPARE_ATOL}") set(FCOMPARE_FLAGS "--abort_if_not_all_found -a ${FCOMPARE_TOLERANCE}") set(test_command sh -c "${MPI_COMMANDS} ${TEST_EXE} ${CURRENT_TEST_BINARY_DIR}/${TEST_NAME}.i ${RUNTIME_OPTIONS} > ${TEST_NAME}.log && ${MPI_FCOMP_COMMANDS} ${FCOMPARE_EXE} ${FCOMPARE_FLAGS} ${PLOT_GOLD} ${CURRENT_TEST_BINARY_DIR}/${PLTFILE}") @@ -59,10 +64,14 @@ function(add_test_r TEST_NAME TEST_EXE PLTFILE) endfunction(add_test_r) # Debug regression test with lower tolerance -function(add_test_d TEST_NAME TEST_EXE PLTFILE) +function(add_test_d TEST_NAME TEST_DIR TEST_EXE PLTFILE) setup_test() - set(TEST_EXE ${CMAKE_BINARY_DIR}/Exec/${TEST_EXE}) + if(WIN32) + set(TEST_EXE "${CMAKE_BINARY_DIR}/Exec/${TEST_DIR}/*/${TEST_EXE}.exe") + else() + set(TEST_EXE "${CMAKE_BINARY_DIR}/Exec/${TEST_DIR}/${TEST_EXE}") + endif() set(FCOMPARE_TOLERANCE "-r 3.0e-9 --abs_tol 3.0e-9") set(FCOMPARE_FLAGS "--abort_if_not_all_found -a ${FCOMPARE_TOLERANCE}") set(test_command sh -c "${MPI_COMMANDS} ${TEST_EXE} ${CURRENT_TEST_BINARY_DIR}/${TEST_NAME}.i > ${TEST_NAME}.log && ${MPI_FCOMP_COMMANDS} ${FCOMPARE_EXE} ${FCOMPARE_FLAGS} ${PLOT_GOLD} ${CURRENT_TEST_BINARY_DIR}/${PLTFILE}") @@ -79,10 +88,14 @@ function(add_test_d TEST_NAME TEST_EXE PLTFILE) endfunction(add_test_d) # Stationary test -- compare with time 0 -function(add_test_0 TEST_NAME TEST_EXE PLTFILE) +function(add_test_0 TEST_NAME TEST_DIR TEST_EXE PLTFILE) setup_test() - set(TEST_EXE ${CMAKE_BINARY_DIR}/Exec/${TEST_EXE}) + if(WIN32) + set(TEST_EXE "${CMAKE_BINARY_DIR}/Exec/${TEST_DIR}/*/${TEST_EXE}.exe") + else() + set(TEST_EXE "${CMAKE_BINARY_DIR}/Exec/${TEST_DIR}/${TEST_EXE}") + endif() set(FCOMPARE_TOLERANCE "-r 1e-14 --abs_tol 1.0e-14") set(FCOMPARE_FLAGS "-a ${FCOMPARE_TOLERANCE}") set(test_command sh -c "${MPI_COMMANDS} ${TEST_EXE} ${CURRENT_TEST_BINARY_DIR}/${TEST_NAME}.i erf.input_sounding_file=${CURRENT_TEST_BINARY_DIR}/input_sounding > ${TEST_NAME}.log && ${MPI_FCOMP_COMMANDS} ${FCOMPARE_EXE} ${FCOMPARE_FLAGS} ${CURRENT_TEST_BINARY_DIR}/plt00000 ${CURRENT_TEST_BINARY_DIR}/${PLTFILE}") @@ -101,95 +114,51 @@ endfunction(add_test_0) #============================================================================= # Regression tests #============================================================================= -if(WIN32) -add_test_r(CouetteFlow_x "DryRegTests/Couette_Poiseuille/*/erf_couette_poiseuille.exe" "plt00050") -add_test_r(CouetteFlow_y "DryRegTests/Couette_Poiseuille/*/erf_couette_poiseuille.exe" "plt00050") -add_test_r(DensityCurrent "DryRegTests/DensityCurrent/*/erf_density_current.exe" "plt00010") -add_test_r(DensityCurrent_anelastic "DryRegTests/DensityCurrent/*/erf_density_current.exe" "plt00010") -add_test_r(DensityCurrent_detJ2 "DryRegTests/DensityCurrent/*/erf_density_current.exe" "plt00010") -add_test_r(DensityCurrent_detJ2_nosub "DryRegTests/DensityCurrent/*/erf_density_current.exe" "plt00020") -add_test_r(DensityCurrent_detJ2_MT "DryRegTests/DensityCurrent/*/erf_density_current.exe" "plt00010") -add_test_r(EkmanSpiral "DryRegTests/EkmanSpiral/*/erf_ekman_spiral.exe" "plt00010") -add_test_r(IsentropicVortexStationary "DryRegTests/IsentropicVortex/*/erf_isentropic_vortex.exe" "plt00010") -add_test_r(IsentropicVortexAdvecting "DryRegTests/IsentropicVortex/*/erf_isentropic_vortex.exe" "plt00010") -add_test_r(IVA_NumDiff "DryRegTests/IsentropicVortex/*/erf_isentropic_vortex.exe" "plt00010") -add_test_r(MovingTerrain_nosub "DevTests/MovingTerrain/*/erf_moving_terrain.exe" "plt00020") -add_test_r(MovingTerrain_sub "DevTests/MovingTerrain/*/erf_moving_terrain.exe" "plt00010") -add_test_r(PoiseuilleFlow_x "DryRegTests/Couette_Poiseuille/*/erf_couette_poiseuille.exe" "plt00010") -add_test_r(PoiseuilleFlow_y "DryRegTests/Couette_Poiseuille/*/erf_couette_poiseuille.exe" "plt00010") -add_test_r(RayleighDamping "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00100") -add_test_r(ScalarAdvectionUniformU "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvectionShearedU "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00080") -add_test_r(ScalarAdvDiff_order2 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvDiff_order3 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvDiff_order4 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvDiff_order5 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvDiff_order6 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvDiff_weno3 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_d(ScalarAdvDiff_weno3z "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvDiff_weno5 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_d(ScalarAdvDiff_weno5z "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarAdvDiff_wenomzq3 "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarDiffusionGaussian "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(ScalarDiffusionSine "DryRegTests/ScalarAdvDiff/*/erf_scalar_advdiff.exe" "plt00020") -add_test_r(TaylorGreenAdvecting "DryRegTests/TaylorGreenVortex/*/erf_taylor_green.exe" "plt00010") -add_test_r(TaylorGreenAdvectingDiffusing "DryRegTests/TaylorGreenVortex/*/erf_taylor_green.exe" "plt00010") -add_test_r(MSF_NoSub_IsentropicVortexAdv "DryRegTests/IsentropicVortex/*/erf_isentropic_vortex.exe" "plt00010") -add_test_r(MSF_Sub_IsentropicVortexAdv "DryRegTests/IsentropicVortex/*/erf_isentropic_vortex.exe" "plt00010") -add_test_r(ABL_MOST "ABL/*/erf_abl.exe" "plt00010") -add_test_r(ABL_MYNN_PBL "ABL/*/erf_abl.exe" "plt00100" INPUT_SOUNDING "input_sounding_GABLS1") -add_test_r(ABL_InflowFile "ABL/*/erf_abl.exe" "plt00010") -add_test_r(MoistBubble "MoistRegTests/Bubble/*/erf_bubble.exe" "plt00010") -add_test_r(SquallLine_2D "MoistRegTests/SquallLine_2D/*/erf_squallline.exe" "plt00010") -add_test_r(SuperCell_3D "MoistRegTests/SuperCell_3D/*/erf_supercell.exe" "plt00010") - -add_test_0(Deardorff_stationary "ABL/*/erf_abl.exe" "plt00010") - -else() -add_test_r(CouetteFlow_x "DryRegTests/Couette_Poiseuille/erf_couette_poiseuille" "plt00050") -add_test_r(CouetteFlow_y "DryRegTests/Couette_Poiseuille/erf_couette_poiseuille" "plt00050") -add_test_r(DensityCurrent "DryRegTests/DensityCurrent/erf_density_current" "plt00010") -add_test_r(DensityCurrent_anelastic "DryRegTests/DensityCurrent/erf_density_current" "plt00010") -add_test_r(DensityCurrent_detJ2 "DryRegTests/DensityCurrent/erf_density_current" "plt00010") -add_test_r(DensityCurrent_detJ2_nosub "DryRegTests/DensityCurrent/erf_density_current" "plt00020") -add_test_r(DensityCurrent_detJ2_MT "DryRegTests/DensityCurrent/erf_density_current" "plt00010") -add_test_r(EkmanSpiral "DryRegTests/EkmanSpiral/erf_ekman_spiral" "plt00010") -add_test_r(IsentropicVortexStationary "DryRegTests/IsentropicVortex/erf_isentropic_vortex" "plt00010") -add_test_r(IsentropicVortexAdvecting "DryRegTests/IsentropicVortex/erf_isentropic_vortex" "plt00010") -add_test_r(IVA_NumDiff "DryRegTests/IsentropicVortex/erf_isentropic_vortex" "plt00010") -add_test_r(MovingTerrain_nosub "DevTests/MovingTerrain/erf_moving_terrain" "plt00020") -add_test_r(MovingTerrain_sub "DevTests/MovingTerrain/erf_moving_terrain" "plt00010") -add_test_r(PoiseuilleFlow_x "DryRegTests/Couette_Poiseuille/erf_couette_poiseuille" "plt00010") -add_test_r(PoiseuilleFlow_y "DryRegTests/Couette_Poiseuille/erf_couette_poiseuille" "plt00010") -add_test_r(RayleighDamping "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00100") -add_test_r(ScalarAdvectionUniformU "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvectionShearedU "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00080") -add_test_r(ScalarAdvDiff_order2 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvDiff_order3 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvDiff_order4 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvDiff_order5 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvDiff_order6 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvDiff_weno3 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_d(ScalarAdvDiff_weno3z "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvDiff_weno5 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_d(ScalarAdvDiff_weno5z "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarAdvDiff_wenomzq3 "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarDiffusionGaussian "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(ScalarDiffusionSine "DryRegTests/ScalarAdvDiff/erf_scalar_advdiff" "plt00020") -add_test_r(TaylorGreenAdvecting "DryRegTests/TaylorGreenVortex/erf_taylor_green" "plt00010") -add_test_r(TaylorGreenAdvectingDiffusing "DryRegTests/TaylorGreenVortex/erf_taylor_green" "plt00010") -add_test_r(MSF_NoSub_IsentropicVortexAdv "DryRegTests/IsentropicVortex/erf_isentropic_vortex" "plt00010") -add_test_r(MSF_Sub_IsentropicVortexAdv "DryRegTests/IsentropicVortex/erf_isentropic_vortex" "plt00010") -add_test_r(ABL_MOST "ABL/erf_abl" "plt00010") -add_test_r(ABL_MYNN_PBL "ABL/erf_abl" "plt00100" INPUT_SOUNDING "input_sounding_GABLS1") -add_test_r(ABL_InflowFile "ABL/erf_abl" "plt00010") -add_test_r(MoistBubble "MoistRegTests/Bubble/erf_bubble" "plt00010") -add_test_r(SquallLine_2D "MoistRegTests/SquallLine_2D/erf_squallline" "plt00010") -add_test_r(SuperCell_3D "MoistRegTests/SuperCell_3D/erf_supercell" "plt00010") - -add_test_0(InitSoundingIdeal_stationary "ABL/erf_abl" "plt00010") -add_test_0(Deardorff_stationary "ABL/erf_abl" "plt00010") -endif() + +add_test_r(CouetteFlow_x "DryRegTests/Couette_Poiseuille" "erf_couette_poiseuille" "plt00050") +add_test_r(CouetteFlow_y "DryRegTests/Couette_Poiseuille" "erf_couette_poiseuille" "plt00050") +add_test_r(DensityCurrent "DryRegTests/DensityCurrent" "erf_density_current" "plt00010") +add_test_r(DensityCurrent_anelastic "DryRegTests/DensityCurrent" "erf_density_current" "plt00010") +add_test_r(DensityCurrent_detJ2 "DryRegTests/DensityCurrent" "erf_density_current" "plt00010") +add_test_r(DensityCurrent_detJ2_nosub "DryRegTests/DensityCurrent" "erf_density_current" "plt00020") +add_test_r(DensityCurrent_detJ2_MT "DryRegTests/DensityCurrent" "erf_density_current" "plt00010") +add_test_r(EkmanSpiral "DryRegTests/EkmanSpiral" "erf_ekman_spiral" "plt00010") +add_test_r(IsentropicVortexStationary "DryRegTests/IsentropicVortex" "erf_isentropic_vortex" "plt00010") +add_test_r(IsentropicVortexAdvecting "DryRegTests/IsentropicVortex" "erf_isentropic_vortex" "plt00010") +add_test_r(IVA_NumDiff "DryRegTests/IsentropicVortex" "erf_isentropic_vortex" "plt00010") +add_test_r(MovingTerrain_nosub "DevTests/MovingTerrain" "erf_moving_terrain" "plt00020") +add_test_r(MovingTerrain_sub "DevTests/MovingTerrain" "erf_moving_terrain" "plt00010") +add_test_r(PoiseuilleFlow_x "DryRegTests/Couette_Poiseuille" "erf_couette_poiseuille" "plt00010") +add_test_r(PoiseuilleFlow_y "DryRegTests/Couette_Poiseuille" "erf_couette_poiseuille" "plt00010") +add_test_r(RayleighDamping "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00100") +add_test_r(ScalarAdvectionUniformU "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvectionShearedU "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00080") +add_test_r(ScalarAdvDiff_order2 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvDiff_order3 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvDiff_order4 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvDiff_order5 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvDiff_order6 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvDiff_weno3 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_d(ScalarAdvDiff_weno3z "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvDiff_weno5 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_d(ScalarAdvDiff_weno5z "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarAdvDiff_wenomzq3 "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarDiffusionGaussian "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(ScalarDiffusionSine "DryRegTests/ScalarAdvDiff" "erf_scalar_advdiff" "plt00020") +add_test_r(TaylorGreenAdvecting "DryRegTests/TaylorGreenVortex" "erf_taylor_green" "plt00010") +add_test_r(TaylorGreenAdvectingDiffusing "DryRegTests/TaylorGreenVortex" "erf_taylor_green" "plt00010") +add_test_r(MSF_NoSub_IsentropicVortexAdv "DryRegTests/IsentropicVortex" "erf_isentropic_vortex" "plt00010") +add_test_r(MSF_Sub_IsentropicVortexAdv "DryRegTests/IsentropicVortex" "erf_isentropic_vortex" "plt00010") +add_test_r(ABL_MOST "ABL" "erf_abl" "plt00010") +add_test_r(ABL_MYNN_PBL "ABL" "erf_abl" "plt00100" INPUT_SOUNDING "input_sounding_GABLS1") +add_test_r(ABL_InflowFile "ABL" "erf_abl" "plt00010") +add_test_r(MoistBubble "MoistRegTests/Bubble" "erf_bubble" "plt00010") +add_test_r(SquallLine_2D "MoistRegTests/SquallLine_2D" "erf_squallline" "plt00010") +add_test_r(SuperCell_3D "MoistRegTests/SuperCell_3D" "erf_supercell" "plt00010") + +add_test_0(InitSoundingIdeal_stationary "ABL" "erf_abl" "plt00010") +add_test_0(Deardorff_stationary "ABL" "erf_abl" "plt00010") + #============================================================================= # Performance tests #============================================================================= diff --git a/Tests/test_files/Bubble_DensityCurrent/Bubble_DensityCurrent.i b/Tests/test_files/Bubble_DensityCurrent/Bubble_DensityCurrent.i index c907d06d2..ec2d241b8 100644 --- a/Tests/test_files/Bubble_DensityCurrent/Bubble_DensityCurrent.i +++ b/Tests/test_files/Bubble_DensityCurrent/Bubble_DensityCurrent.i @@ -41,15 +41,16 @@ erf.plot_int_1 = 3840 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta pres_hse dens_hse # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = true erf.use_coriolis = false -erf.les_type = "None" -erf.molec_diff_type = "ConstantAlpha" +erf.les_type = "None" + # diffusion = 75 m^2/s, rho_0 = 1e5/(287*300) = 1.1614401858 -erf.dynamicViscosity = 87.108013935 # kg/(m-s) +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 87.108013935 # kg/(m-s) +erf.alpha_T = 0.0 +erf.alpha_C = 0.0 erf.init_type = "" diff --git a/Tests/test_files/CouetteFlow_x/CouetteFlow_x.i b/Tests/test_files/CouetteFlow_x/CouetteFlow_x.i index 534472bf7..2a5537007 100644 --- a/Tests/test_files/CouetteFlow_x/CouetteFlow_x.i +++ b/Tests/test_files/CouetteFlow_x/CouetteFlow_x.i @@ -36,16 +36,17 @@ erf.check_int = 1000 # number of timesteps between checkpoints # PLOTFILES erf.plot_file_1 = plt # prefix of plotfile name erf.plot_int_1 = 50 # number of timesteps between plotfiles -erf.plot_vars_1 = density x_velocity y_velocity z_velocity +erf.plot_vars_1 = density x_velocity y_velocity z_velocity # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 0.1 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 +erf.alpha_T = 0.0 +erf.alpha_C = 0.0 # PROBLEM PARAMETERS prob.prob_type = 1 diff --git a/Tests/test_files/CouetteFlow_y/CouetteFlow_y.i b/Tests/test_files/CouetteFlow_y/CouetteFlow_y.i index 5af596575..7a9a40faf 100644 --- a/Tests/test_files/CouetteFlow_y/CouetteFlow_y.i +++ b/Tests/test_files/CouetteFlow_y/CouetteFlow_y.i @@ -38,13 +38,14 @@ erf.plot_int_1 = 50 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 0.1 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 +erf.alpha_T = 0.0 +erf.alpha_C = 0.0 erf.init_type = "uniform" diff --git a/Tests/test_files/Deardorff_stationary/Deardorff_stationary.i b/Tests/test_files/Deardorff_stationary/Deardorff_stationary.i index cbed7182a..163df8926 100644 --- a/Tests/test_files/Deardorff_stationary/Deardorff_stationary.i +++ b/Tests/test_files/Deardorff_stationary/Deardorff_stationary.i @@ -55,13 +55,18 @@ erf.abl_driver_type = "GeostrophicWind" erf.abl_geo_wind = 0. 0. 0. # no background pressure gradient erf.molec_diff_type = "None" + erf.les_type = "Deardorff" erf.Ck = 0.1 erf.Ce = 0.93 erf.Pr_t = 0.3333 erf.theta_ref = 290.0 # used in buoyancy term -erf.KE_0 = 0.000656292002688172 # exact soln in uniform density field, e = Ck/Ce*(dUdz*delta)**2 # INITIAL PROFILES erf.init_type = "input_sounding" erf.input_sounding_file = "input_sounding" # with linear wind profile + +# exact soln in uniform density field +# e = Ck/Ce*(dUdz*delta)**2, +# with dU/dz=0.01 and dx=dy=dz=delta=7.8125 +prob.rhoKE_0 = 0.000656292002688172 diff --git a/Tests/test_files/DensityCurrent/DensityCurrent.i b/Tests/test_files/DensityCurrent/DensityCurrent.i index d476b95cc..aca1b2bd9 100644 --- a/Tests/test_files/DensityCurrent/DensityCurrent.i +++ b/Tests/test_files/DensityCurrent/DensityCurrent.i @@ -43,7 +43,6 @@ erf.plot_int_1 = 3840 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta pres_hse dens_hse # SOLVER CHOICE -erf.alpha_C = 0.0 erf.use_gravity = true erf.use_coriolis = false @@ -52,10 +51,10 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] +erf.alpha_C = 0.0 erf.c_p = 1004.0 diff --git a/Tests/test_files/DensityCurrent_anelastic/DensityCurrent_anelastic.i b/Tests/test_files/DensityCurrent_anelastic/DensityCurrent_anelastic.i index 0e42dcc13..b8827451b 100644 --- a/Tests/test_files/DensityCurrent_anelastic/DensityCurrent_anelastic.i +++ b/Tests/test_files/DensityCurrent_anelastic/DensityCurrent_anelastic.i @@ -52,10 +52,9 @@ erf.les_type = None # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = ConstantAlpha # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = ConstantAlpha # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] erf.c_p = 1004.0 diff --git a/Tests/test_files/DensityCurrent_detJ2/DensityCurrent_detJ2.i b/Tests/test_files/DensityCurrent_detJ2/DensityCurrent_detJ2.i index 811af37e6..e07a18051 100644 --- a/Tests/test_files/DensityCurrent_detJ2/DensityCurrent_detJ2.i +++ b/Tests/test_files/DensityCurrent_detJ2/DensityCurrent_detJ2.i @@ -43,7 +43,6 @@ erf.plot_int_1 = 3840 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta pres_hse dens_hse # SOLVER CHOICE -erf.alpha_C = 0.0 erf.use_gravity = true erf.use_coriolis = false @@ -51,10 +50,10 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] +erf.alpha_C = 0.0 erf.c_p = 1004.0 diff --git a/Tests/test_files/DensityCurrent_detJ2_MT/DensityCurrent_detJ2_MT.i b/Tests/test_files/DensityCurrent_detJ2_MT/DensityCurrent_detJ2_MT.i index a21c6c43f..47e075c53 100644 --- a/Tests/test_files/DensityCurrent_detJ2_MT/DensityCurrent_detJ2_MT.i +++ b/Tests/test_files/DensityCurrent_detJ2_MT/DensityCurrent_detJ2_MT.i @@ -43,7 +43,6 @@ erf.plot_int_1 = 3840 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta pres_hse dens_hse # SOLVER CHOICE -erf.alpha_C = 0.0 erf.use_gravity = true erf.use_coriolis = false @@ -51,10 +50,10 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] +erf.alpha_C = 0.0 erf.dycore_horiz_adv_type = Centered_2nd erf.dycore_vert_adv_type = Centered_2nd diff --git a/Tests/test_files/DensityCurrent_detJ2_nosub/DensityCurrent_detJ2_nosub.i b/Tests/test_files/DensityCurrent_detJ2_nosub/DensityCurrent_detJ2_nosub.i index e13a22994..264a39d54 100644 --- a/Tests/test_files/DensityCurrent_detJ2_nosub/DensityCurrent_detJ2_nosub.i +++ b/Tests/test_files/DensityCurrent_detJ2_nosub/DensityCurrent_detJ2_nosub.i @@ -42,7 +42,6 @@ erf.plot_int_1 = 3840 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta pres_hse dens_hse # SOLVER CHOICE -erf.alpha_C = 0.0 erf.use_gravity = true erf.use_coriolis = false @@ -50,10 +49,10 @@ erf.les_type = "None" # # Diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s -erf.alpha_T = 75.0 # [m^2/s] +erf.molec_diff_type = "ConstantAlpha" # where alpha == "K" in Straka et al 1993 +erf.dynamic_viscosity = 75.0 # [kg/(m-s)] ==> alpha = 75.0 m^2/s +erf.alpha_T = 75.0 # [m^2/s] +erf.alpha_C = 0.0 erf.c_p = 1004.0 diff --git a/Tests/test_files/EkmanSpiral/EkmanSpiral.i b/Tests/test_files/EkmanSpiral/EkmanSpiral.i index a21f4ac8b..5d7ef721d 100644 --- a/Tests/test_files/EkmanSpiral/EkmanSpiral.i +++ b/Tests/test_files/EkmanSpiral/EkmanSpiral.i @@ -39,13 +39,14 @@ erf.plot_int_1 = 100 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 5.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 5.0 +erf.alpha_T = 0.0 +erf.alpha_C = 0.0 erf.use_coriolis = true erf.abl_driver_type = "GeostrophicWind" diff --git a/Tests/test_files/IVA_NumDiff/IVA_NumDiff.i b/Tests/test_files/IVA_NumDiff/IVA_NumDiff.i index 308499ff0..425f454cd 100644 --- a/Tests/test_files/IVA_NumDiff/IVA_NumDiff.i +++ b/Tests/test_files/IVA_NumDiff/IVA_NumDiff.i @@ -37,16 +37,12 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta temp # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false -erf.use_NumDiff = true -erf.NumDiffCoeff = 0.001 +erf.num_diff_coeff = 0.001 erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Tests/test_files/IsentropicVortexAdvecting/IsentropicVortexAdvecting.i b/Tests/test_files/IsentropicVortexAdvecting/IsentropicVortexAdvecting.i index cb3a4175a..f81268f77 100644 --- a/Tests/test_files/IsentropicVortexAdvecting/IsentropicVortexAdvecting.i +++ b/Tests/test_files/IsentropicVortexAdvecting/IsentropicVortexAdvecting.i @@ -37,13 +37,10 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta temp vorticity_x vorticity_y vorticity_z # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Tests/test_files/IsentropicVortexStationary/IsentropicVortexStationary.i b/Tests/test_files/IsentropicVortexStationary/IsentropicVortexStationary.i index f43aa5a10..7c8398250 100644 --- a/Tests/test_files/IsentropicVortexStationary/IsentropicVortexStationary.i +++ b/Tests/test_files/IsentropicVortexStationary/IsentropicVortexStationary.i @@ -37,13 +37,10 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure theta temp # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Tests/test_files/MSF_NoSub_IsentropicVortexAdv/MSF_NoSub_IsentropicVortexAdv.i b/Tests/test_files/MSF_NoSub_IsentropicVortexAdv/MSF_NoSub_IsentropicVortexAdv.i index 816623a08..16893801a 100644 --- a/Tests/test_files/MSF_NoSub_IsentropicVortexAdv/MSF_NoSub_IsentropicVortexAdv.i +++ b/Tests/test_files/MSF_NoSub_IsentropicVortexAdv/MSF_NoSub_IsentropicVortexAdv.i @@ -43,9 +43,10 @@ erf.alpha_T = 0.1 erf.alpha_C = 0.1 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Tests/test_files/MSF_Sub_IsentropicVortexAdv/MSF_Sub_IsentropicVortexAdv.i b/Tests/test_files/MSF_Sub_IsentropicVortexAdv/MSF_Sub_IsentropicVortexAdv.i index 46763bf72..adb3f4468 100644 --- a/Tests/test_files/MSF_Sub_IsentropicVortexAdv/MSF_Sub_IsentropicVortexAdv.i +++ b/Tests/test_files/MSF_Sub_IsentropicVortexAdv/MSF_Sub_IsentropicVortexAdv.i @@ -44,9 +44,10 @@ erf.alpha_T = 0.1 erf.alpha_C = 0.1 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 1.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 1.0 # PROBLEM PARAMETERS prob.p_inf = 1e5 # reference pressure [Pa] diff --git a/Tests/test_files/MoistBubble/MoistBubble.i b/Tests/test_files/MoistBubble/MoistBubble.i index 35b646113..9da44897d 100644 --- a/Tests/test_files/MoistBubble/MoistBubble.i +++ b/Tests/test_files/MoistBubble/MoistBubble.i @@ -56,11 +56,10 @@ erf.moisture_model = "Kessler_NoRain" erf.buoyancy_type = 1 erf.use_moist_background = true -erf.molec_diff_type = "ConstantAlpha" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 0.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 0.0 # [m^2/s] -erf.alpha_C = 0.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 0.0 # [kg/(m-s)] +erf.alpha_T = 0.0 # [m^2/s] +erf.alpha_C = 0.0 # INITIAL CONDITIONS #erf.init_type = "input_sounding" diff --git a/Tests/test_files/PoiseuilleFlow_x/PoiseuilleFlow_x.i b/Tests/test_files/PoiseuilleFlow_x/PoiseuilleFlow_x.i index 97d3ebed8..5c767b13f 100644 --- a/Tests/test_files/PoiseuilleFlow_x/PoiseuilleFlow_x.i +++ b/Tests/test_files/PoiseuilleFlow_x/PoiseuilleFlow_x.i @@ -36,17 +36,17 @@ erf.check_int = 1000 # number of timesteps between checkpoints # PLOTFILES erf.plot_file_1 = plt # prefix of plotfile name erf.plot_int_1 = 100 # number of timesteps between plotfiles -erf.plot_vars_1 = density x_velocity y_velocity z_velocity +erf.plot_vars_1 = density x_velocity y_velocity z_velocity # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.1 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 +erf.alpha_T = 0.0 +erf.alpha_C = 0.0 erf.use_coriolis = false erf.abl_driver_type = "PressureGradient" diff --git a/Tests/test_files/PoiseuilleFlow_y/PoiseuilleFlow_y.i b/Tests/test_files/PoiseuilleFlow_y/PoiseuilleFlow_y.i index 21f190d3d..ca708e8b7 100644 --- a/Tests/test_files/PoiseuilleFlow_y/PoiseuilleFlow_y.i +++ b/Tests/test_files/PoiseuilleFlow_y/PoiseuilleFlow_y.i @@ -39,13 +39,12 @@ erf.plot_vars_1 = density x_velocity y_velocity z_velocity # SOLVER CHOICE erf.use_gravity = false -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 +erf.les_type = "None" -erf.les_type = "None" -erf.rho0_trans = 1.0 -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 0.1 +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.1 +erf.alpha_T = 0.0 +erf.alpha_C = 0.0 erf.use_coriolis = false erf.abl_driver_type = "PressureGradient" diff --git a/Tests/test_files/RayleighDamping/RayleighDamping.i b/Tests/test_files/RayleighDamping/RayleighDamping.i index 37e6d8c35..692d51aff 100644 --- a/Tests/test_files/RayleighDamping/RayleighDamping.i +++ b/Tests/test_files/RayleighDamping/RayleighDamping.i @@ -37,9 +37,6 @@ erf.plot_int_1 = 100 # number of timesteps between plotfiles erf.plot_vars_1 = x_velocity y_velocity z_velocity theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 - erf.use_gravity = false erf.use_coriolis = false @@ -52,7 +49,6 @@ erf.rayleigh_dampcoef = 1.0 # tau==1 erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Tests/test_files/ScalarAdvDiff_order2/ScalarAdvDiff_order2.i b/Tests/test_files/ScalarAdvDiff_order2/ScalarAdvDiff_order2.i index bd7207741..58add10b4 100644 --- a/Tests/test_files/ScalarAdvDiff_order2/ScalarAdvDiff_order2.i +++ b/Tests/test_files/ScalarAdvDiff_order2/ScalarAdvDiff_order2.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Centered_2nd erf.dycore_vert_adv_type = Centered_2nd diff --git a/Tests/test_files/ScalarAdvDiff_order3/ScalarAdvDiff_order3.i b/Tests/test_files/ScalarAdvDiff_order3/ScalarAdvDiff_order3.i index 8ec30ff7c..1bc67e8ba 100644 --- a/Tests/test_files/ScalarAdvDiff_order3/ScalarAdvDiff_order3.i +++ b/Tests/test_files/ScalarAdvDiff_order3/ScalarAdvDiff_order3.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Upwind_3rd erf.dycore_vert_adv_type = Upwind_3rd diff --git a/Tests/test_files/ScalarAdvDiff_order4/ScalarAdvDiff_order4.i b/Tests/test_files/ScalarAdvDiff_order4/ScalarAdvDiff_order4.i index 1ec9d9d96..efc724898 100644 --- a/Tests/test_files/ScalarAdvDiff_order4/ScalarAdvDiff_order4.i +++ b/Tests/test_files/ScalarAdvDiff_order4/ScalarAdvDiff_order4.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Centered_4th erf.dycore_vert_adv_type = Centered_4th diff --git a/Tests/test_files/ScalarAdvDiff_order5/ScalarAdvDiff_order5.i b/Tests/test_files/ScalarAdvDiff_order5/ScalarAdvDiff_order5.i index a0ce73ef7..4b937d986 100644 --- a/Tests/test_files/ScalarAdvDiff_order5/ScalarAdvDiff_order5.i +++ b/Tests/test_files/ScalarAdvDiff_order5/ScalarAdvDiff_order5.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Upwind_5th erf.dycore_vert_adv_type = Upwind_5th diff --git a/Tests/test_files/ScalarAdvDiff_order6/ScalarAdvDiff_order6.i b/Tests/test_files/ScalarAdvDiff_order6/ScalarAdvDiff_order6.i index 1270ff551..cd5ef86f7 100644 --- a/Tests/test_files/ScalarAdvDiff_order6/ScalarAdvDiff_order6.i +++ b/Tests/test_files/ScalarAdvDiff_order6/ScalarAdvDiff_order6.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Centered_6th erf.dycore_vert_adv_type = Centered_6th diff --git a/Tests/test_files/ScalarAdvDiff_weno3/ScalarAdvDiff_weno3.i b/Tests/test_files/ScalarAdvDiff_weno3/ScalarAdvDiff_weno3.i index 399dce738..54033551c 100644 --- a/Tests/test_files/ScalarAdvDiff_weno3/ScalarAdvDiff_weno3.i +++ b/Tests/test_files/ScalarAdvDiff_weno3/ScalarAdvDiff_weno3.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Centered_2nd erf.dycore_vert_adv_type = Centered_2nd diff --git a/Tests/test_files/ScalarAdvDiff_weno3z/ScalarAdvDiff_weno3z.i b/Tests/test_files/ScalarAdvDiff_weno3z/ScalarAdvDiff_weno3z.i index 23c3cb6f2..57a266ca9 100644 --- a/Tests/test_files/ScalarAdvDiff_weno3z/ScalarAdvDiff_weno3z.i +++ b/Tests/test_files/ScalarAdvDiff_weno3z/ScalarAdvDiff_weno3z.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dryscal_horiz_adv_type = WENOZ3 erf.dryscal_vert_adv_type = WENOZ3 diff --git a/Tests/test_files/ScalarAdvDiff_weno5/ScalarAdvDiff_weno5.i b/Tests/test_files/ScalarAdvDiff_weno5/ScalarAdvDiff_weno5.i index 86d5dee58..a0ca9fe70 100644 --- a/Tests/test_files/ScalarAdvDiff_weno5/ScalarAdvDiff_weno5.i +++ b/Tests/test_files/ScalarAdvDiff_weno5/ScalarAdvDiff_weno5.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Centered_2nd erf.dycore_vert_adv_type = Centered_2nd diff --git a/Tests/test_files/ScalarAdvDiff_weno5z/ScalarAdvDiff_weno5z.i b/Tests/test_files/ScalarAdvDiff_weno5z/ScalarAdvDiff_weno5z.i index f1e3a76f1..d31b32ec4 100644 --- a/Tests/test_files/ScalarAdvDiff_weno5z/ScalarAdvDiff_weno5z.i +++ b/Tests/test_files/ScalarAdvDiff_weno5z/ScalarAdvDiff_weno5z.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dryscal_horiz_adv_type = WENOZ5 erf.dryscal_vert_adv_type = WENOZ5 diff --git a/Tests/test_files/ScalarAdvDiff_wenomzq3/ScalarAdvDiff_wenomzq3.i b/Tests/test_files/ScalarAdvDiff_wenomzq3/ScalarAdvDiff_wenomzq3.i index ec49b8caf..285e05ab2 100644 --- a/Tests/test_files/ScalarAdvDiff_wenomzq3/ScalarAdvDiff_wenomzq3.i +++ b/Tests/test_files/ScalarAdvDiff_wenomzq3/ScalarAdvDiff_wenomzq3.i @@ -43,14 +43,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.dycore_horiz_adv_type = Centered_2nd erf.dycore_vert_adv_type = Centered_2nd diff --git a/Tests/test_files/ScalarAdvectionShearedU/ScalarAdvectionShearedU.i b/Tests/test_files/ScalarAdvectionShearedU/ScalarAdvectionShearedU.i index 10c746152..4b825a220 100644 --- a/Tests/test_files/ScalarAdvectionShearedU/ScalarAdvectionShearedU.i +++ b/Tests/test_files/ScalarAdvectionShearedU/ScalarAdvectionShearedU.i @@ -36,13 +36,10 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Tests/test_files/ScalarAdvectionUniformU/ScalarAdvectionUniformU.i b/Tests/test_files/ScalarAdvectionUniformU/ScalarAdvectionUniformU.i index 68f4ab676..a93e8b84d 100644 --- a/Tests/test_files/ScalarAdvectionUniformU/ScalarAdvectionUniformU.i +++ b/Tests/test_files/ScalarAdvectionUniformU/ScalarAdvectionUniformU.i @@ -36,8 +36,6 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false erf.dryscal_horiz_adv_type = "Centered_2nd" @@ -47,7 +45,6 @@ erf.moistscal_vert_adv_type = "Centered_2nd" erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 erf.init_type = "uniform" diff --git a/Tests/test_files/ScalarDiffusionGaussian/ScalarDiffusionGaussian.i b/Tests/test_files/ScalarDiffusionGaussian/ScalarDiffusionGaussian.i index 6c05b2d6a..bbeded275 100644 --- a/Tests/test_files/ScalarDiffusionGaussian/ScalarDiffusionGaussian.i +++ b/Tests/test_files/ScalarDiffusionGaussian/ScalarDiffusionGaussian.i @@ -36,14 +36,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.init_type = "uniform" diff --git a/Tests/test_files/ScalarDiffusionSine/ScalarDiffusionSine.i b/Tests/test_files/ScalarDiffusionSine/ScalarDiffusionSine.i index 70b00e324..44408081e 100644 --- a/Tests/test_files/ScalarDiffusionSine/ScalarDiffusionSine.i +++ b/Tests/test_files/ScalarDiffusionSine/ScalarDiffusionSine.i @@ -36,14 +36,14 @@ erf.plot_int_1 = 20 # number of timesteps between plotfiles erf.plot_vars_1 = density rhoadv_0 x_velocity y_velocity z_velocity pressure temp theta # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 1.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 -erf.dynamicViscosity = 0.0 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 0.0 +erf.alpha_T = 0.0 +erf.alpha_C = 1.0 erf.init_type = "uniform" diff --git a/Tests/test_files/SquallLine_2D/SquallLine_2D.i b/Tests/test_files/SquallLine_2D/SquallLine_2D.i index eed22d9c0..997493812 100644 --- a/Tests/test_files/SquallLine_2D/SquallLine_2D.i +++ b/Tests/test_files/SquallLine_2D/SquallLine_2D.i @@ -45,18 +45,16 @@ erf.buoyancy_type = 1 erf.use_coriolis = false #erf.les_type = "Smagorinsky" -erf.Cs = 0.25 +#erf.Cs = 0.25 erf.les_type = "None" # # diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" -#erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 200.0 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 200.0 # [m^2/s] -erf.alpha_C = 200.0 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 200.0 # [kg/(m-s)] +erf.alpha_T = 200.0 # [m^2/s] +erf.alpha_C = 200.0 erf.moisture_model = "Kessler" erf.use_moist_background = true diff --git a/Tests/test_files/SuperCell_3D/SuperCell_3D.i b/Tests/test_files/SuperCell_3D/SuperCell_3D.i index 9f829de79..86fe706d4 100644 --- a/Tests/test_files/SuperCell_3D/SuperCell_3D.i +++ b/Tests/test_files/SuperCell_3D/SuperCell_3D.i @@ -49,18 +49,16 @@ erf.use_coriolis = false erf.use_rayleigh_damping = false #erf.les_type = "Smagorinsky" -erf.Cs = 0.25 +#erf.Cs = 0.25 erf.les_type = "None" # # diffusion coefficient from Straka, K = 75 m^2/s # -erf.molec_diff_type = "ConstantAlpha" -#erf.molec_diff_type = "Constant" -erf.rho0_trans = 1.0 # [kg/m^3], used to convert input diffusivities -erf.dynamicViscosity = 33.33 # [kg/(m-s)] ==> nu = 75.0 m^2/s -erf.alpha_T = 33.33 # [m^2/s] -erf.alpha_C = 33.33 +erf.molec_diff_type = "ConstantAlpha" +erf.dynamic_viscosity = 33.33 # [kg/(m-s)] +erf.alpha_T = 33.33 # [m^2/s] +erf.alpha_C = 33.33 erf.moisture_model = "Kessler" erf.use_moist_background = true diff --git a/Tests/test_files/TaylorGreenAdvecting/TaylorGreenAdvecting.i b/Tests/test_files/TaylorGreenAdvecting/TaylorGreenAdvecting.i index c9e553a21..06d540e3b 100644 --- a/Tests/test_files/TaylorGreenAdvecting/TaylorGreenAdvecting.i +++ b/Tests/test_files/TaylorGreenAdvecting/TaylorGreenAdvecting.i @@ -36,13 +36,10 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure temp theta scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false erf.les_type = "None" erf.molec_diff_type = "None" -erf.dynamicViscosity = 0.0 # PROBLEM PARAMETERS prob.rho_0 = 1.0 diff --git a/Tests/test_files/TaylorGreenAdvectingDiffusing/TaylorGreenAdvectingDiffusing.i b/Tests/test_files/TaylorGreenAdvectingDiffusing/TaylorGreenAdvectingDiffusing.i index 81f64b4b7..65473a61e 100644 --- a/Tests/test_files/TaylorGreenAdvectingDiffusing/TaylorGreenAdvectingDiffusing.i +++ b/Tests/test_files/TaylorGreenAdvectingDiffusing/TaylorGreenAdvectingDiffusing.i @@ -35,13 +35,14 @@ erf.plot_int_1 = 10 # number of timesteps between plotfiles erf.plot_vars_1 = density x_velocity y_velocity z_velocity pressure temp theta scalar # SOLVER CHOICE -erf.alpha_T = 0.0 -erf.alpha_C = 0.0 erf.use_gravity = false -erf.les_type = "None" -erf.molec_diff_type = "Constant" -erf.dynamicViscosity = 6.25e-4 # 1.5e-5 +erf.les_type = "None" + +erf.molec_diff_type = "Constant" +erf.dynamic_viscosity = 6.25e-4 # 1.5e-5 +erf.alpha_T = 0.0 +erf.alpha_C = 0.0 # PROBLEM PARAMETERS prob.rho_0 = 1.0