You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Search for cdn_atm and cdn_ocn, which are (neutral) drag coefficients calculated in icepack_atmo.F90, called from step_therm1. Basically, all of the thermodynamic calculations that use them should be done at cell centers, and they (or variables derived from them) only need to be shifted for the momentum equation. E.g. cdn_atm is used for the atmo turbulent boundary layer calculations, from which we get atmo surface stress. I think the stress calculations are done in T cells then shifted to the velocity points before being used for solving the dynamics equations, so they should be okay as-is (but check). cdn_atm also appears in init_coupler_flux, for RASM -- I'm not sure what's needed there. This github issue is probably mainly about cdn_ocn in the ice_dyn_*.F90 modules, for which an equivalent shifting procedure should be done as for the atmo stresses. It is more complicated, though, because the ocean stress term is split up in the code, which will require a some care to get right.
I had a look thru the code and think the above assessment is correct. It looks like all the cdn variables are defined on the T-grid. They are computed in icepack_atmo, including the cdn_ocn terms. And all the air/ice stresses are also computed in icepack on the T grid. Those are mapped to the U, E, and N grid as needed.
Only cdn_ocn is used directly in the dynamics in dyn_finish, stepu and similar. It is passed into subroutines with related variables already on the U, E, or N grid. So I think we need to create cdn_ocn[U,E,N] at the start of the dynamics and then instead of using cdn_ocn, use cdn_ocn[U,E,N]. I assume an appropriate mapping would be "S" which is a masked area-weighted average. The ocean stress terms are computed separately on the U, E, or N grid, I think there is no complication with passing in the appropriate cdn_ocn and using it.
Unless there is any disagreement, I'll make the modifications and create a PR. @JFLemieux73. This will also changes answers for the B grid.
No description provided.
The text was updated successfully, but these errors were encountered: