CICE-Consortium / CICE

Development repository for the CICE sea-ice model
Other
59 stars 132 forks source link

Possible problem in ice_restoring if hbar=hin_min or hin_max then restoring to zero #972

Open JFLemieux73 opened 2 months ago

JFLemieux73 commented 2 months ago

The code is currently like this:

!----------------------------------------------------------------- ! initial area and thickness in ice-occupied restoring cells !-----------------------------------------------------------------

  hbar = c2  ! initial ice thickness
  hsno_init = 0.20_dbl_kind ! initial snow thickness (m)
  do n = 1, ncat
     hinit(n) = c0
     ainit(n) = c0
     if (hbar > hin_max(n-1) .and. hbar < hin_max(n)) then
        hinit(n) = hbar
        ainit(n) = 0.95_dbl_kind ! initial ice concentration
     endif
  enddo

We should have instead:

  if (hbar >= hin_max(n-1) .and. hbar < hin_max(n)) then
apcraig commented 1 month ago

FYI, this is in /cicecore/cicedyn/infrastructure/ice_restoring.F90.

phil-blain commented 4 days ago

The problem is that if hbar falls directly on the lower limit of a category, we do not enter the if and hinit, ainit are then left to zero.