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

User/bgr/kvisc fix #267

Merged
merged 2 commits into from
Apr 21, 2016
Merged

Conversation

breichl
Copy link
Collaborator

@breichl breichl commented Apr 20, 2016

In ALE mode MOM_diabatic_aux should not advect momentum via diffusion between layers, since momentum is already mixed by MOM_vert_friction. We found that when viscosity is disabled, momentum is still mixed due to diffusivity in this part of the code. Therefore, a flag has been added to disable these lines of codes when in ALE mode.

A simple test case was prepared with constant wind stress forcing and constant viscosity. When the constant viscosity is set into variable Kv, which is accessed by subroutine find_coupling_coef (in MOM_vertical_friction.F90), the resulting current profile matches the analytical solution. However, if the constant viscosity is instead set into variable Kv_turb (accessed in the same subroutine), then the resulting current profile is under mixed. I notice that parameter 'a' (output from find_coupling_coef) is set to 2x Kv and 2x Kvbbl, but for Kv_turb, 'a' is set to (1x) Kv_turb . I believe that this 2 comes from a reorganization of the factor of 2 in the h_shear calculation, since h_shear is equal to twice the level thickness (but shears are computed over one level difference). Since this factor of 2 is missing in setting 'a' from Kv_turb, but it is there when setting from Kv, this explains why using Kv gives the correct solution but using Kv_turb does not. Therefore, a factor of 2 has been introduced when setting 'a' from Kv_turb, and the result now agrees with the analytical solution. The current profile has also been compared using GOTM for redundancy, which agrees with the profile from the analytical solution, using Kv, and using the Kv_turb with the additional factor of 2.

- Diabatic_driver was advecting momentum with Kdiffusivity as it should do in layer mode, but resulted in double counting viscosity in ALE mode.
- Mixing momentum with viscosity in KV_turb gave different results from equal viscosity in Kv due to missing factor of 2.  Confirmed against analytical solution for simple test case.
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