- Timestamp:
- 2017-09-26T15:24:17+02:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2017/dev_r8183_ICEMODEL/NEMOGCM/NEMO/LIM_SRC_3/icethd.F90
r8534 r8563 302 302 303 303 ! mask temperature 304 rswitch = 1._wp - MAX( 0._wp , SIGN( 1._wp , - h t_i_1d(ji) ) )304 rswitch = 1._wp - MAX( 0._wp , SIGN( 1._wp , - h_i_1d(ji) ) ) 305 305 t_i_1d(ji,jk) = rswitch * t_i_1d(ji,jk) + ( 1._wp - rswitch ) * rt0 306 306 END DO … … 326 326 zdh_mel = MIN( 0._wp, dh_i_surf(ji) + dh_i_bott(ji) + dh_snowice(ji) + dh_i_sub(ji) ) 327 327 IF( zdh_mel < 0._wp .AND. a_i_1d(ji) > 0._wp ) THEN 328 zvi = a_i_1d(ji) * h t_i_1d(ji)329 zvs = a_i_1d(ji) * h t_s_1d(ji)328 zvi = a_i_1d(ji) * h_i_1d(ji) 329 zvs = a_i_1d(ji) * h_s_1d(ji) 330 330 ! lateral melting = concentration change 331 zhi_bef = h t_i_1d(ji) - zdh_mel331 zhi_bef = h_i_1d(ji) - zdh_mel 332 332 rswitch = MAX( 0._wp , SIGN( 1._wp , zhi_bef - epsi20 ) ) 333 333 zda_mel = rswitch * a_i_1d(ji) * zdh_mel / ( 2._wp * MAX( zhi_bef, epsi20 ) ) 334 334 a_i_1d(ji) = MAX( epsi20, a_i_1d(ji) + zda_mel ) 335 335 ! adjust thickness 336 h t_i_1d(ji) = zvi / a_i_1d(ji)337 h t_s_1d(ji) = zvs / a_i_1d(ji)336 h_i_1d(ji) = zvi / a_i_1d(ji) 337 h_s_1d(ji) = zvs / a_i_1d(ji) 338 338 ! retrieve total concentration 339 339 at_i_1d(ji) = a_i_1d(ji) … … 362 362 CALL tab_2d_1d( nidx, idxice(1:nidx), at_i_1d(1:nidx), at_i ) 363 363 CALL tab_2d_1d( nidx, idxice(1:nidx), a_i_1d (1:nidx), a_i (:,:,kl) ) 364 CALL tab_2d_1d( nidx, idxice(1:nidx), h t_i_1d(1:nidx), ht_i(:,:,kl) )365 CALL tab_2d_1d( nidx, idxice(1:nidx), h t_s_1d(1:nidx), ht_s(:,:,kl) )364 CALL tab_2d_1d( nidx, idxice(1:nidx), h_i_1d(1:nidx), h_i(:,:,kl) ) 365 CALL tab_2d_1d( nidx, idxice(1:nidx), h_s_1d(1:nidx), h_s(:,:,kl) ) 366 366 CALL tab_2d_1d( nidx, idxice(1:nidx), t_su_1d(1:nidx), t_su(:,:,kl) ) 367 367 CALL tab_2d_1d( nidx, idxice(1:nidx), sm_i_1d(1:nidx), sm_i(:,:,kl) ) … … 436 436 ! --- Change units of e_i, e_s from J/m2 to J/m3 --- ! 437 437 DO jk = 1, nlay_i 438 WHERE( h t_i_1d(1:nidx)>0._wp ) e_i_1d(1:nidx,jk) = e_i_1d(1:nidx,jk) / (ht_i_1d(1:nidx) * a_i_1d(1:nidx)) * nlay_i438 WHERE( h_i_1d(1:nidx)>0._wp ) e_i_1d(1:nidx,jk) = e_i_1d(1:nidx,jk) / (h_i_1d(1:nidx) * a_i_1d(1:nidx)) * nlay_i 439 439 END DO 440 440 DO jk = 1, nlay_s 441 WHERE( h t_s_1d(1:nidx)>0._wp ) e_s_1d(1:nidx,jk) = e_s_1d(1:nidx,jk) / (ht_s_1d(1:nidx) * a_i_1d(1:nidx)) * nlay_s441 WHERE( h_s_1d(1:nidx)>0._wp ) e_s_1d(1:nidx,jk) = e_s_1d(1:nidx,jk) / (h_s_1d(1:nidx) * a_i_1d(1:nidx)) * nlay_s 442 442 END DO 443 443 ! … … 447 447 ! --- Change units of e_i, e_s from J/m3 to J/m2 --- ! 448 448 DO jk = 1, nlay_i 449 e_i_1d(1:nidx,jk) = e_i_1d(1:nidx,jk) * h t_i_1d(1:nidx) * a_i_1d(1:nidx) * r1_nlay_i449 e_i_1d(1:nidx,jk) = e_i_1d(1:nidx,jk) * h_i_1d(1:nidx) * a_i_1d(1:nidx) * r1_nlay_i 450 450 END DO 451 451 DO jk = 1, nlay_s 452 e_s_1d(1:nidx,jk) = e_s_1d(1:nidx,jk) * h t_s_1d(1:nidx) * a_i_1d(1:nidx) * r1_nlay_s452 e_s_1d(1:nidx,jk) = e_s_1d(1:nidx,jk) * h_s_1d(1:nidx) * a_i_1d(1:nidx) * r1_nlay_s 453 453 END DO 454 454 ! 455 455 ! Change thickness to volume (replaces routine ice_var_eqv2glo) 456 v_i_1d(1:nidx) = h t_i_1d(1:nidx) * a_i_1d(1:nidx)457 v_s_1d(1:nidx) = h t_s_1d(1:nidx) * a_i_1d(1:nidx)456 v_i_1d(1:nidx) = h_i_1d(1:nidx) * a_i_1d(1:nidx) 457 v_s_1d(1:nidx) = h_s_1d(1:nidx) * a_i_1d(1:nidx) 458 458 smv_i_1d(1:nidx) = sm_i_1d(1:nidx) * v_i_1d(1:nidx) 459 459 460 460 CALL tab_1d_2d( nidx, idxice(1:nidx), at_i_1d(1:nidx), at_i ) 461 461 CALL tab_1d_2d( nidx, idxice(1:nidx), a_i_1d (1:nidx), a_i (:,:,kl) ) 462 CALL tab_1d_2d( nidx, idxice(1:nidx), h t_i_1d(1:nidx), ht_i(:,:,kl) )463 CALL tab_1d_2d( nidx, idxice(1:nidx), h t_s_1d(1:nidx), ht_s(:,:,kl) )462 CALL tab_1d_2d( nidx, idxice(1:nidx), h_i_1d(1:nidx), h_i(:,:,kl) ) 463 CALL tab_1d_2d( nidx, idxice(1:nidx), h_s_1d(1:nidx), h_s(:,:,kl) ) 464 464 CALL tab_1d_2d( nidx, idxice(1:nidx), t_su_1d(1:nidx), t_su(:,:,kl) ) 465 465 CALL tab_1d_2d( nidx, idxice(1:nidx), sm_i_1d(1:nidx), sm_i(:,:,kl) )
Note: See TracChangeset
for help on using the changeset viewer.