-
Notifications
You must be signed in to change notification settings - Fork 132
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
Update the calculation of uvel and vvel in evp dynamics #953
Conversation
ice_dyn_evp.F90. Do an unmasked grid_average_X2Y when averaging from uvelE to uvel and from vvelN to vvel instead of a masked average. The masking is handled separately. This change is bit-for-bit and saves a few flops. Closes CICE-Consortium#952. Update the documentation to add the hemispheric sign dependence in the water stress terms in the dynamics equations. Closes CICE-Consortium#951.
I'm doing a full test suite to make sure answers haven't changed. @JFLemieux73 @eclare108213 Please review code changes and documentation, let me know if I've done something wrong. |
@@ -35,11 +35,11 @@ For clarity, the two components of Equation :eq:`vpmom` are | |||
\begin{aligned} | |||
m{\partial u\over\partial t} &= {\partial\sigma_{1j}\over\partial x_j} + \tau_{ax} + | |||
a_i c_w \rho_w | |||
\left|{\bf U}_w - {\bf u}\right| \left[\left(U_w-u\right)\cos\theta - \left(V_w-v\right)\sin\theta\right] | |||
\left|{\bf U}_w - {\bf u}\right| \left[ + \left(U_w-u\right)\cos\theta \mp \left(V_w-v\right)\sin\theta\right] |
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.
not sure I would add the + sign before \left(U_w...
:label: vmom | ||
|
||
where :math:`{\tt vrel}\ \cdot\ {\tt waterx(y)}= {\tt taux(y)}` and the definitions of :math:`u^{l}` and :math:`v^{l}` vary depending on the grid. | ||
|
||
As :math:`u` and :math:`v` are collocated on the B grid, :math:`u^{l}` and :math:`v^{l}` are respectively :math:`u^{k+1}` and :math:`v^{k+1}` such that this system of equations can be solved as follows. Define | ||
|
||
.. math:: | ||
\hat{u} = F_u + \tau_{ax} - mg{\partial H_\circ\over\partial x} + {\tt vrel} \left(U_w\cos\theta - V_w\sin\theta\right) + {m\over\Delta t_e}u^k | ||
\hat{u} = F_u + \tau_{ax} - mg{\partial H_\circ\over\partial x} + {\tt vrel} \left(+ U_w\cos\theta \mp V_w\sin\theta\right) + {m\over\Delta t_e}u^k |
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.
same comment here not sure I would add the + sign before U_w
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.
This was done just to keep the equations aligned a bit in the text. I'll remove them again, wasn't sure what was better.
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.
The extra plus signs are out, feel free to have another look. Can revert if you prefer the prior version. If I don't hear anything, will merge later today.
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 good!
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
PR checklist
Update the calculation of uvel and vvel in evp to reduce flops, bit-for-bit.
apcraig, jflemiuex, eclare
Full test suites run on derecho with intel, gnu, cray. All testing passes as expected, https://github.com/CICE-Consortium/Test-Results/wiki/cice_by_hash_forks#c5b390ec0507633c319e6c7d1cb2a6850924dc59
Update the calculation of uvel and vvel in subroutine evp in file ice_dyn_evp.F90. Do an unmasked grid_average_X2Y when averaging from uvelE to uvel and from vvelN to vvel instead of a masked average. The masking is handled separately. This change is bit-for-bit and saves a few flops. Closes #952.
Update the documentation to add the hemispheric sign dependence in the water stress terms in the dynamics equations. Closes #951.