Changeset 6515 for branches/2016/dev_v3_6_STABLE_r6506_AGRIF_LIM3/NEMOGCM/NEMO/LIM_SRC_3/limthd_dh.F90
- Timestamp:
- 2016-05-09T16:42:28+02:00 (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2016/dev_v3_6_STABLE_r6506_AGRIF_LIM3/NEMOGCM/NEMO/LIM_SRC_3/limthd_dh.F90
r6469 r6515 76 76 REAL(wp) :: zdum 77 77 REAL(wp) :: zfracs ! fractionation coefficient for bottom salt entrapment 78 REAL(wp) :: zs_snic ! snow-ice salinity79 78 REAL(wp) :: zswi1 ! switch for computation of bottom salinity 80 79 REAL(wp) :: zswi12 ! switch for computation of bottom salinity … … 126 125 CALL wrk_alloc( jpij, nlay_i, icount ) 127 126 128 dh_i_surf (:) = 0._wp ; dh_i_bott (:) = 0._wp ; dh_snowice(:) = 0._wp ; dh_i_sub(:) = 0._wp129 dsm_i_se_1d(:) = 0._wp ; dsm_i_si_1d(:) = 0._wp130 131 127 zqprec (:) = 0._wp ; zq_su (:) = 0._wp ; zq_bo (:) = 0._wp ; zf_tt(:) = 0._wp 132 128 zq_rema (:) = 0._wp ; zsnw (:) = 0._wp ; zevap_rema(:) = 0._wp ; … … 135 131 zdeltah(:,:) = 0._wp ; zh_i(:,:) = 0._wp 136 132 icount (:,:) = 0 137 138 133 139 134 ! Initialize enthalpy at nlay_i+1 … … 634 629 ht_s_1d(ji) = ht_s_1d(ji) - dh_snowice(ji) 635 630 636 ! Salinity of snow ice631 ! Contribution to energy flux to the ocean [J/m2], >0 (if sst<0) 637 632 ii = MOD( npb(ji) - 1, jpi ) + 1 ; ij = ( npb(ji) - 1 ) / jpi + 1 638 zs_snic = zswitch_sal * sss_m(ii,ij) * ( rhoic - rhosn ) * r1_rhoic + ( 1. - zswitch_sal ) * sm_i_1d(ji) 639 640 ! entrapment during snow ice formation 641 ! new salinity difference stored (to be used in limthd_sal.F90) 642 IF ( nn_icesal == 2 ) THEN 643 rswitch = MAX( 0._wp , SIGN( 1._wp , ht_i_1d(ji) - epsi20 ) ) 644 ! salinity dif due to snow-ice formation 645 dsm_i_si_1d(ji) = ( zs_snic - sm_i_1d(ji) ) * dh_snowice(ji) / MAX( ht_i_1d(ji), epsi20 ) * rswitch 646 ! salinity dif due to bottom growth 647 IF ( zf_tt(ji) < 0._wp ) THEN 648 dsm_i_se_1d(ji) = ( s_i_new(ji) - sm_i_1d(ji) ) * dh_i_bott(ji) / MAX( ht_i_1d(ji), epsi20 ) * rswitch 649 ENDIF 650 ENDIF 651 652 ! Contribution to energy flux to the ocean [J/m2], >0 (if sst<0) 653 zfmdt = ( rhosn - rhoic ) * MAX( dh_snowice(ji), 0._wp ) ! <0 633 zfmdt = ( rhosn - rhoic ) * dh_snowice(ji) ! <0 654 634 zsstK = sst_m(ii,ij) + rt0 655 635 zEw = rcp * ( zsstK - rt0 ) … … 664 644 ! virtual salt flux to keep salinity constant 665 645 IF( nn_icesal == 1 .OR. nn_icesal == 3 ) THEN 666 sfx_bri_1d(ji) = sfx_bri_1d(ji) - sss_m(ii,ij) * a_i_1d(ji) * zfmdt * r1_rdtice & ! put back sss_m into the ocean667 & - sm_i_1d(ji) * a_i_1d(ji) * dh_snowice(ji) * rhoic * r1_rdtice ! and get sm_ifrom the ocean646 sfx_bri_1d(ji) = sfx_bri_1d(ji) - sss_m(ii,ij) * a_i_1d(ji) * zfmdt * r1_rdtice & ! put back sss_m into the ocean 647 & - sm_i_1d(ji) * a_i_1d(ji) * dh_snowice(ji) * rhoic * r1_rdtice ! and get rn_icesal from the ocean 668 648 ENDIF 669 649 670 650 ! Contribution to mass flux 671 651 ! All snow is thrown in the ocean, and seawater is taken to replace the volume
Note: See TracChangeset
for help on using the changeset viewer.