From af19dbf3a7706ad248cc1ca5968dc0d2e8c328c4 Mon Sep 17 00:00:00 2001 From: bennibolm Date: Mon, 20 Nov 2023 12:34:53 +0100 Subject: [PATCH] Fix typo --- src/solvers/dgsem_tree/subcell_limiters.jl | 6 +++--- src/solvers/dgsem_tree/subcell_limiters_2d.jl | 19 ++++++++++++++----- 2 files changed, 17 insertions(+), 8 deletions(-) diff --git a/src/solvers/dgsem_tree/subcell_limiters.jl b/src/solvers/dgsem_tree/subcell_limiters.jl index a967cc035e9..dc1bf137729 100644 --- a/src/solvers/dgsem_tree/subcell_limiters.jl +++ b/src/solvers/dgsem_tree/subcell_limiters.jl @@ -37,16 +37,16 @@ end Subcell invariant domain preserving (IDP) limiting used with [`VolumeIntegralSubcellLimiting`](@ref) including: - Local maximum/minimum Zalesak-type limiting for conservative variables (`local_minmax_variables_cons`) -- Positivity limiting for conservative (`positivity_variables_cons`) and non-linear variables (`positivity_variables_nonlinear`) +- Positivity limiting for conservative (`positivity_variables_cons`) and nonlinear variables (`positivity_variables_nonlinear`) - One-sided limiting for specific and mathematical entropy (`spec_entropy`, `math_entropy`) Conservative variables to be limited are passed as a vector of strings, e.g. `local_minmax_variables_cons = ["rho"]` -and `positivity_variables_cons = ["rho"]`. For non-linear variables the specific functions are +and `positivity_variables_cons = ["rho"]`. For nonlinear variables the specific functions are passed in a vector, e.g. `positivity_variables_nonlinear = [pressure]`. The bounds can be calculated using the `bar_states` or the low-order FV solution. The positivity limiter uses `positivity_correction_factor` such that `u^new >= positivity_correction_factor * u^FV`. -The Newton-bisection method for the limiting of non-linear variables uses maximal `max_iterations_newton` +The Newton-bisection method for the limiting of nonlinear variables uses maximal `max_iterations_newton` iterations, tolerances `newton_tolerances` and the gamma constant `gamma_constant_newton` (gamma_constant_newton>=2*d, where d=#dimensions). diff --git a/src/solvers/dgsem_tree/subcell_limiters_2d.jl b/src/solvers/dgsem_tree/subcell_limiters_2d.jl index 01764a3996b..c37276c5802 100644 --- a/src/solvers/dgsem_tree/subcell_limiters_2d.jl +++ b/src/solvers/dgsem_tree/subcell_limiters_2d.jl @@ -555,13 +555,22 @@ end mesh, _, _, _ = mesh_equations_solver_cache(semi) # Conservative variables - @trixi_timeit timer() "conservative variables" for variable in limiter.positivity_variables_cons - idp_positivity!(alpha, limiter, u, dt, semi, mesh, elements, variable) + for variable in limiter.positivity_variables_cons + @trixi_timeit timer() "conservative variables" idp_positivity!(alpha, limiter, + u, dt, semi, + mesh, elements, + variable) end # Nonlinear variables - @trixi_timeit timer() "non-linear variables" for variable in limiter.positivity_variables_nonlinear - idp_positivity_nonlinear!(alpha, limiter, u, dt, semi, mesh, elements, variable) + for variable in limiter.positivity_variables_nonlinear + @trixi_timeit timer() "nonlinear variables" idp_positivity_nonlinear!(alpha, + limiter, + u, dt, + semi, + mesh, + elements, + variable) end return nothing @@ -661,7 +670,7 @@ end end ############################################################################### -# Global positivity limiting of non-linear variables +# Global positivity limiting of nonlinear variables @inline function idp_positivity_nonlinear!(alpha, limiter, u, dt, semi, mesh::TreeMesh{2}, elements, variable)