-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add the filter for GABLS, set the configs
- Loading branch information
1 parent
6a495ed
commit 0473937
Showing
6 changed files
with
37 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
### | ||
### tmp sgs u3 filter | ||
### | ||
function filter_sgs_u3_tendency!(Yₜ, Y, p, t, colidx) | ||
# set the sgs momentum tendency to the grid mean momentum tendency | ||
# if updraft area <= 0 | ||
if p.atmos.turbconv_model isa EDMFX | ||
FT = eltype(Y) | ||
n = n_mass_flux_subdomains(p.atmos.turbconv_model) | ||
for j in 1:n | ||
@. Yₜ.f.sgsʲs.:($$j).u₃[colidx] = ifelse( | ||
ᶠinterp(Y.c.sgsʲs.:($$j).ρa[colidx] / p.ᶜρʲs.:($$j)[colidx]) <= FT(0), | ||
Yₜ.f.u₃[colidx], | ||
Yₜ.f.sgsʲs.:($$j).u₃[colidx], | ||
) | ||
end | ||
end | ||
return nothing | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters