Changeset 13472 for NEMO/trunk/src/ICE/icerst.F90
- Timestamp:
- 2020-09-16T15:05:19+02:00 (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
NEMO/trunk/src/ICE/icerst.F90
r13286 r13472 18 18 USE phycst , ONLY : rt0 19 19 USE sbc_oce , ONLY : nn_fsbc, ln_cpl 20 USE sbc_oce , ONLY : nn_components, jp_iam_sas ! SAS ss[st]_m init 21 USE sbc_oce , ONLY : sst_m, sss_m ! SAS ss[st]_m init 22 USE oce , ONLY : ts ! SAS ss[st]_m init 23 USE eosbn2 , ONLY : l_useCT, eos_pt_from_ct ! SAS ss[st]_m init 20 24 USE iceistate ! sea-ice: initial state 21 25 USE icectl ! sea-ice: control … … 132 136 CALL iom_rstput( iter, nitrst, numriw, 'a_ip' , a_ip ) 133 137 CALL iom_rstput( iter, nitrst, numriw, 'v_ip' , v_ip ) 138 CALL iom_rstput( iter, nitrst, numriw, 'v_il' , v_il ) 134 139 ! Snow enthalpy 135 140 DO jk = 1, nlay_s … … 172 177 INTEGER :: jk 173 178 LOGICAL :: llok 174 INTEGER :: id0, id1, id2, id3, id4 ! local integer179 INTEGER :: id0, id1, id2, id3, id4, id5 ! local integer 175 180 CHARACTER(len=25) :: znam 176 181 CHARACTER(len=2) :: zchar, zchar1 … … 251 256 v_ip(:,:,:) = 0._wp 252 257 ENDIF 258 ! melt pond lids 259 id3 = iom_varid( numrir, 'v_il' , ldstop = .FALSE. ) 260 IF( id3 > 0 ) THEN 261 CALL iom_get( numrir, jpdom_auto, 'v_il', v_il) 262 ELSE 263 IF(lwp) WRITE(numout,*) ' ==>> previous run without melt ponds lids output then set it to zero' 264 v_il(:,:,:) = 0._wp 265 ENDIF 253 266 ! fields needed for Met Office (Jules) coupling 254 267 IF( ln_cpl ) THEN 255 id 3= iom_varid( numrir, 'cnd_ice' , ldstop = .FALSE. )256 id 4= iom_varid( numrir, 't1_ice' , ldstop = .FALSE. )257 IF( id 3 > 0 .AND. id4> 0 ) THEN ! fields exist268 id4 = iom_varid( numrir, 'cnd_ice' , ldstop = .FALSE. ) 269 id5 = iom_varid( numrir, 't1_ice' , ldstop = .FALSE. ) 270 IF( id4 > 0 .AND. id5 > 0 ) THEN ! fields exist 258 271 CALL iom_get( numrir, jpdom_auto, 'cnd_ice', cnd_ice ) 259 272 CALL iom_get( numrir, jpdom_auto, 't1_ice' , t1_ice ) … … 270 283 ELSE ! == case of a simplified restart == ! 271 284 ! ! ---------------------------------- ! 272 CALL ctl_warn('ice_rst_read: you are using a simplifiedice restart')285 CALL ctl_warn('ice_rst_read: you are attempting to use an unsuitable ice restart') 273 286 ! 274 CALL ice_istate_init 287 IF( .NOT. ln_iceini .OR. nn_iceini_file == 2 ) THEN 288 CALL ctl_stop('STOP', 'ice_rst_read: you need ln_ice_ini=T and nn_iceini_file=0 or 1') 289 ELSE 290 CALL ctl_warn('ice_rst_read: using ice_istate to set initial conditions instead') 291 ENDIF 292 ! 293 IF( nn_components == jp_iam_sas ) THEN ! SAS case: ss[st]_m were not initialized by sbc_ssm_init 294 ! 295 IF(lwp) WRITE(numout,*) ' SAS: default initialisation of ss[st]_m arrays used in ice_istate' 296 IF( l_useCT ) THEN ; sst_m(:,:) = eos_pt_from_ct( ts(:,:,1,jp_tem, Kmm), ts(:,:,1,jp_sal, Kmm) ) 297 ELSE ; sst_m(:,:) = ts(:,:,1,jp_tem, Kmm) 298 ENDIF 299 sss_m(:,:) = ts(:,:,1,jp_sal, Kmm) 300 ENDIF 301 ! 275 302 CALL ice_istate( nit000, Kbb, Kmm, Kaa ) 276 303 ! 277 IF( .NOT.ln_iceini .OR. .NOT.ln_iceini_file ) &278 & CALL ctl_stop('STOP', 'ice_rst_read: you need ln_ice_ini=T and ln_iceini_file=T')279 !280 304 ENDIF 281 305
Note: See TracChangeset
for help on using the changeset viewer.