Skip to content
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions columnphysics/icepack_therm_vertical.F90
Original file line number Diff line number Diff line change
Expand Up @@ -375,12 +375,11 @@ subroutine thermo_vertical (dt, aicen, &
einter = einter + hilyr * zqin(k)
enddo ! k

Tsnice = c0
if ((hslyr+hilyr) > puny) then
if (hilyr > puny) then
if (hslyr > puny) then
Tsnice = (hslyr*zTsn(nslyr) + hilyr*zTin(1)) / (hslyr+hilyr)
Tsnice = Tsnice + aicen*((hslyr*zTsn(nslyr) + hilyr*zTin(1)) / (hslyr+hilyr))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can I check that I understand? Does this aicen factor get "canceled" in ice_history in:

! Only average for timesteps when ice present
if (avail_hist_fields(n)%avg_ice_present) then
   do j = jlo, jhi
   do i = ilo, ihi
      if (tmask(i,j,iblk)) then
            a2D(i,j,n,iblk) = &
            a2D(i,j,n,iblk)*avgct(ns)*ravgip(i,j)
      endif

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, this is aggregating the category Tsnice into the grid cell Tsnice. The time averaging in ice_history.F90 will come in a CICE PR!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! Then isn't a Tsnice = Tsnice/sum(aicen) factor missing? For example, for single category aicen almost puny

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry this is so confusing. I should really call this:

Tsnice = sum(aicen(n)*Tsnicen(n)) for n=1,5

this is done for every point in space within icepack. The history averaging in CICE is then:

sum(aice(t)*Tsnice(t)) / sum(aice(t)), for t over the averaging period. The CICE changes are coming in a future PR!

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm also confused :)

Tsnice = sum(aicen(n)*Tsnicen(n)) for n=1,5

sum(aicen(n)) is not 1, so Tsnice ends up weighted by aice here right ?

... The history averaging in CICE is then:

sum(aice(t)*Tsnice(t)) / sum(aice(t)), for t over the averaging period. The CICE changes are coming in a future PR!

Doesn't this mean its weighted by aice twice ?

Copy link
Contributor

@anton-seaice anton-seaice Sep 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh - maybe this line would be correct now:

worka(i,j) = aice(i,j,iblk)*(Tsnice(i,j,iblk)/aice_init(i,j,iblk)+Tffresh)

https://github.com/CICE-Consortium/CICE/blob/b01032506d71d86ca51cef8c3c28c1ab87532833/cicecore/cicedyn/analysis/ice_history.F90#L2768

the divide by aice_init corrects it for the aice weighting applied during thermo vertical

Copy link
Contributor

@eclare108213 eclare108213 Sep 24, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, this is aggregating the category Tsnice into the grid cell Tsnice.

This is true only if Tsnice=0 for the open water area. Assuming that, then the grid cell average Tavg = sum(aicen(n)*Tsnice(n))/sum(aicen(n)) =sum(aicen(n)*Tsnice(n))/1 where the sums are for n=0,ncat mathematically but only need to be taken for n=1,ncat in the code. Confusing, yes, but possibly okay here. (Explicit code comments to this effect would be helpful.) A better assumption for Tsnice for open water might be the ocean temperature. On the other hand, if the data request is for Tsnice only over the ice-covered area, then it had better be
sum(aicen(n)*Tsnice(n))/sum(aicen(n)) for n=1,ncat, where aicen might actually be aicen_init at this point in the code.

I'm generally suspicious of any 'mixed' ice area scaling using both aice and aice_init. Those will need to be considered on a case-by-case basis, in my opinion.

else
Tsnice = Tsf
Tsnice = Tsnice + aicen*Tsf
endif
endif

Expand Down
1 change: 1 addition & 0 deletions configuration/driver/icedrv_flux.F90
Original file line number Diff line number Diff line change
Expand Up @@ -688,6 +688,7 @@ subroutine init_history_therm
congel (:) = c0
frazil (:) = c0
snoice (:) = c0
Tsnice (:) = c0
dsnow (:) = c0
meltt (:) = c0
melts (:) = c0
Expand Down