-
Notifications
You must be signed in to change notification settings - Fork 134
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
Add ustar_prev to while loop in icepack_atmo #341
Conversation
@@ -271,6 +271,8 @@ psixh ! stability function at zlvl (heat and water) | |||
|
|||
k = 1 | |||
do while (abs(ustar - ustar_prev)/ustar > atmiter_conv .and. k <= natmiter) | |||
k = k + 1 | |||
ustar_prev = ustar |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks like a bug fix! Thanks for catching this. Why are these two lines not at the end of the loop though?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ustar_prev = ustar
can't be at the end of the loop, because it would not be ustar_prev if it was. It doesn't matter if k=k+1
is at the start or end of the loop, but I have changed this so that it is consistent with the ocean coupling routine while loop now in CIME.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are correct! Looks good. Approving.
@@ -271,6 +271,8 @@ psixh ! stability function at zlvl (heat and water) | |||
|
|||
k = 1 | |||
do while (abs(ustar - ustar_prev)/ustar > atmiter_conv .and. k <= natmiter) | |||
k = k + 1 | |||
ustar_prev = ustar |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are correct! Looks good. Approving.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for catching that, @proteanplanet
The code change seem to be mostly bit-for-bit but comprehensive test results can be seen here, |
Add floediam and hfrazilmin as CICE namelist. Requires latest version of Icepack. Update documentation. Icepack has two non bit-for-bit changes including - a fix to multiple declarations of floeshape (CICE-Consortium/Icepack#342) - a fix to the convergence scheme in icepack_atmo (CICE-Consortium/Icepack#341)
Add floediam and hfrazilmin as CICE namelist. Requires latest version of Icepack. Update documentation. Icepack has two non bit-for-bit changes including - a fix to multiple declarations of floeshape (CICE-Consortium/Icepack#342) - a fix to the convergence scheme in icepack_atmo (CICE-Consortium/Icepack#341)
For detailed information about submitting Pull Requests (PRs) to the CICE-Consortium,
please refer to: https://github.com/CICE-Consortium/About-Us/wiki/Resource-Index#information-for-developers
This adds a necessary line for checking for convergence of the ustar loop in icepack_atmo that is missing.
Developer: @proteanplanet
Suggested Reviewers: @eclare108213 @dabail10
This is a non-BFB change. There are no dependencies, and no new test cases are added. Documentation is unchanged.