#2300 closed Bug (fixed)
jcat initialisation issue in icethd_do.F90
Reported by: | mathiot | Owned by: | systeam |
---|---|---|---|
Priority: | low | Milestone: | |
Component: | SI3 | Version: | v4.0 |
Severity: | minor | Keywords: | v4.0 |
Cc: |
Description
Context
Sette test AGRIF_DEMO_ST REPRO_4_8 failed to run on METO computer.
Analysis
Initialisation of jcat is possibly not complete. If zh_newice(ji) < hi_max(0) (for example) jcat is not initialised in icethd_do:
DO jl = 1, jpl DO ji = 1, npti IF( zh_newice(ji) > hi_max(jl-1) .AND. zh_newice(ji) <= hi_max(jl) ) THEN a_i_2d(ji,jl) = a_i_2d(ji,jl) + za_newice(ji) v_i_2d(ji,jl) = v_i_2d(ji,jl) + zv_newice(ji) jcat(ji) = jl ENDIF END DO END DO
Then the model failed when jcat is used as an array index:
! Heat content DO ji = 1, npti jl = jcat(ji) ! categroy in which new ice is put zswinew (ji) = MAX( 0._wp , SIGN( 1._wp , - za_b(ji,jl) ) ) ! 0 if old ice END DO
Fix
Suggested fix: make sure jcat is initialised everywhere (what default value to use for jcat in case of zh_newice negative or equal 0 (what I have for some points), I have no idea)
AGRIF_DEMO configuration with jcat = 1 by default runs and starts to diverge after 10 time steps
Commit History (2)
Changeset | Author | Time | ChangeLog |
---|---|---|---|
11229 | clem | 2019-07-09T14:22:12+02:00 | debug BDY-ice by allowing any number of categories as input. Ticket #2300 may also be solved |
11228 | clem | 2019-07-09T14:21:55+02:00 | debug BDY-ice by allowing any number of categories as input. Ticket #2300 may also be solved |
Attachments (1)
Change History (7)
Changed 5 years ago by clem
comment:1 Changed 5 years ago by clem
comment:2 Changed 5 years ago by clem
In 11228:
comment:3 Changed 5 years ago by clem
In 11229:
comment:4 Changed 5 years ago by clem
- Resolution set to fixed
- Status changed from new to closed
zh_newice(ji) is always >= 0 and hi_max(0)=0, so zh_newice(ji) cannot be lower than hi_max(0)
comment:5 Changed 5 years ago by mathiot
AGRIF_DEMO is running on our computer. Problem seems to be fix. Thank you Clem.
comment:6 Changed 3 years ago by nemo
- Keywords v4.0 added
the attached file should solve this issue by bounding the new sea ice thickness (though I do not know why it is mandatory for agrif only).
Pierre, could you try it and tell me if it works?