From 83bc16fdb3f55283afc096ae26a82252bc4dfe14 Mon Sep 17 00:00:00 2001 From: Zhaoyi Shen <11598433+szy21@users.noreply.github.com> Date: Wed, 1 Nov 2023 20:08:20 -0700 Subject: [PATCH] change prognostic edmf precompute quantities order --- src/cache/precomputed_quantities.jl | 2 +- src/cache/prognostic_edmf_precomputed_quantities.jl | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/src/cache/precomputed_quantities.jl b/src/cache/precomputed_quantities.jl index 3624298c3b4..8adb9105dc8 100644 --- a/src/cache/precomputed_quantities.jl +++ b/src/cache/precomputed_quantities.jl @@ -344,8 +344,8 @@ NVTX.@annotate function set_precomputed_quantities!(Y, p, t) end if turbconv_model isa PrognosticEDMFX - set_prognostic_edmf_precomputed_quantities_environment!(Y, p, ᶠuₕ³, t) set_prognostic_edmf_precomputed_quantities_draft_and_bc!(Y, p, ᶠuₕ³, t) + set_prognostic_edmf_precomputed_quantities_environment!(Y, p, ᶠuₕ³, t) set_prognostic_edmf_precomputed_quantities_closures!(Y, p, t) end diff --git a/src/cache/prognostic_edmf_precomputed_quantities.jl b/src/cache/prognostic_edmf_precomputed_quantities.jl index 7ff7b6895fb..d294cb23350 100644 --- a/src/cache/prognostic_edmf_precomputed_quantities.jl +++ b/src/cache/prognostic_edmf_precomputed_quantities.jl @@ -148,6 +148,7 @@ function set_prognostic_edmf_precomputed_quantities_draft_and_bc!(Y, p, ᶠuₕ Fields.field_values(Fields.level(Y.c.sgsʲs.:($j).ρa, 1)) turbconv_params = CAP.turbconv_params(params) + @. sgsʲs_ρ_int_val = TD.air_density(thermo_params, ᶜtsʲ_int_val) @. sgsʲs_ρa_int_val = $(FT(turbconv_params.surface_area)) * TD.air_density(thermo_params, ᶜtsʲ_int_val)