Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Warn users when projection is inappropriate for GWD_OPT=1 (merged) #213

Merged
merged 8 commits into from
Mar 31, 2017
Merged

Warn users when projection is inappropriate for GWD_OPT=1 (merged) #213

merged 8 commits into from
Mar 31, 2017

Conversation

davegill
Copy link
Contributor

@davegill davegill commented Mar 26, 2017

TYPE: new feature

KEYWORDS: gwd_opt, projection

SOURCE: internal

DESCRIPTION OF CHANGES:

This PR supersedes PR #208, which was closed.

Assume that the user is trying to use gravity wave drag (GWD), gwd_opt=1, in the ARW model. For domain 1, if the projection has a large rotation angle anywhere within the domain ("rotation" is directly from the sina variable in the WRF input and output, and "large" means greater than a default value of 22.5o), notify the user and stop. The original GWD data has information at four directions, each separated by 45o angles. Therefore anything larger than a 22.5o projection rotation (usually only violated in parts of the domain) means that the wind components are using the wrong topographic directional information.

For the determined user, the namelist variable max_rot_angle_gwd = 100 (really, anything greater than 90o) will always permit GWD to be used, regardless of the projection.

How to estimate that the domain will or will not work within the 22.5o restriction:

  1. Only be concerned with d01
  2. If the pole is in the domain AND this is not a global projection - the domain will not work
  3. Look at the SINALPHA field from metgrid (SINA field from wrfinput). SIN(22.5o) = 0.38. If the SINALPHA (or SINA) field has values greater than 0.38, the WRF model will gracefully stop. Internal to the code, if the projection angle > 22.5o, the model stops.
  4. A regular lat/lon or a Mercator projection will always work

LIST OF MODIFIED FILES:

M dyn_em/start_em.F
M Registry/Registry.EM_COMMON

TESTS CONDUCTED:

  • Reggie 3.07, passed
  • Test GSD RAP domain - it does not allow gwd_opt=1
Max projection rotation angle for domain 1 = 90.00
This projection may not be appropriate for using the gravity wave drag option.
In namelist.input make one of the two following changes:
 1) gwd_opt = 0
 2) max_rot_angle_gwd > 90.00
-------------- FATAL CALLED ---------------
FATAL CALLED FROM FILE:  <stdin>  LINE:     196
--- ERROR: gwd_opt does not work with this domain
-------------------------------------------

For a domain above the pole, to use gwd_opt=1 NO MATTER WHAT:

&dynamics
 gwd_opt                             = 1
 max_rot_angle_gwd                   = 100
/

TYPE: new feature

KEYWORDS: gwd_opt, projection

SOURCE: internal

DESCRIPTION OF CHANGES:
In the WRF model for domain 1, if the projection has a large sinalpha (where it is larger than a default value), notify the user and stop.

LIST OF MODIFIED FILES: list of changed files (use `git diff --name-status master` to get formatted list)
M       dyn_em/start_em.F

TESTS CONDUCTED:
- [ ] Reggie 3.07, checked means that is has been run
Set value to 22.5 degrees as max (half of 45 degrees), original data at 45 degree directions
@davegill davegill changed the title Gwd merged update Warn users when projection is inappropriate for GWD_OPT=1 (merged) Mar 26, 2017
@davegill davegill changed the title Warn users when projection is inappropriate for GWD_OPT=1 (merged) Warn users when projection is inappropriate for GWD_OPT=1 (merged) #213 Mar 26, 2017
@davegill davegill changed the title Warn users when projection is inappropriate for GWD_OPT=1 (merged) #213 Warn users when projection is inappropriate for GWD_OPT=1 (merged) Mar 27, 2017
Copy link
Contributor

@mkavulich mkavulich left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved by wrf-dev committee

@davegill davegill merged commit 22ee10a into wrf-model:master Mar 31, 2017
@davegill davegill deleted the GWD_MERGED_UPDATE branch March 31, 2017 17:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants