Changeset 2116
- Timestamp:
- 2010-09-23T19:36:32+02:00 (14 years ago)
- Location:
- branches/dev_r2091_ZTC/NEMO
- Files:
-
- 13 edited
- 1 copied
Legend:
- Unmodified
- Added
- Removed
-
branches/dev_r2091_ZTC/NEMO/LIM_SRC_2/limthd_2.F90
r1758 r2116 241 241 242 242 ! energy needed to bring ocean surface layer until its freezing 243 qcmif (ji,jj) = rau0 * rcp * fse3t_m(ji,jj ,1) &243 qcmif (ji,jj) = rau0 * rcp * fse3t_m(ji,jj) & 244 244 & * ( tfu(ji,jj) - sst_m(ji,jj) ) * ( 1 - zinda ) 245 245 -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/DOM/dom_oce.F90
r2068 r2116 147 147 REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: e3t_b !: before - - - - T points (m) 148 148 REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: e3u_b , e3v_b !: - - - - - U--V points (m) 149 REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: e3t_d !: "diffused" - - - - T points (m)150 149 #else 151 150 LOGICAL, PUBLIC, PARAMETER :: lk_vvl = .FALSE. !: fixed grid flag -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/DOM/domzgr_substitute.h90
r2068 r2116 7 7 !! History : 1.0 ! 2005-10 (A. Beckmann, G. Madec) generalisation to all coord. 8 8 !! 3.1 ! 2009-02 (G. Madec, M. Leclair) pure z* coordinate 9 !! 3.3 ! 2010-09 (G. Madec, M. Leclair) z_tilde coordinate 9 10 !!---------------------------------------------------------------------- 10 11 #if defined key_zco … … 33 34 # define fse3vw_0(i,j,k) e3vw(i,j,k) 34 35 #endif 35 #if defined key_vvl 36 #if defined key_ztc 37 ! z_tilde coordinate 3D arrays at t,u,v points at b,n,a time steps 38 # define fsdept(i,j,k) gdept_1(i,j,k) 39 # define fsdepw(i,j,k) gdepw_1(i,j,k) 40 # define fsde3w(i,j,k) gdep3w_1(i,j,k) 41 # define fse3t(i,j,k) e3t_1(i,j,k) 42 # define fse3u(i,j,k) e3u_1(i,j,k) 43 # define fse3v(i,j,k) e3v_1(i,j,k) 44 # define fse3f(i,j,k) e3f_1(i,j,k) 45 # define fse3w(i,j,k) e3w_1(i,j,k) 46 # define fse3uw(i,j,k) e3uw_1(i,j,k) 47 # define fse3vw(i,j,k) e3vw_1(i,j,k) 48 49 # define fse3t_b(i,j,k) e3t_b(i,j,k) 50 # define fse3u_b(i,j,k) e3u_b(i,j,k) 51 # define fse3v_b(i,j,k) e3v_b(i,j,k) 52 # define fse3uw_b(i,j,k) e3uw_b(i,j,k) 53 # define fse3vw_b(i,j,k) e3vw_b(i,j,k) 54 55 # define fsdept_n(i,j,k) gdept_1(i,j,k) 56 # define fsdepw_n(i,j,k) gdepw_1(i,j,k) 57 # define fsde3w_n(i,j,k) gdep3w_1(i,j,k) 58 # define fse3t_n(i,j,k) e3t_n(i,j,k) 59 # define fse3u_n(i,j,k) e3u_n(i,j,k) 60 # define fse3v_n(i,j,k) e3v_n(i,j,k) 61 # define fse3f_n(i,j,k) e3f_1(i,j,k) 62 # define fse3w_n(i,j,k) e3w_1(i,j,k) 63 # define fse3uw_n(i,j,k) e3uw(i,j,k) 64 # define fse3vw_n(i,j,k) e3vw(i,j,k) 65 66 ! - ML - Caution: only the first level of e3t_m is used (in limthd_2.F90) 67 ! It is replaced b y a 2d array 68 # define fse3t_m(i,j) e3t_m(i,j) 69 # define fse3t_d(i,j,k) e3t_d(i,j,k) 70 71 # define fse3t_a(i,j,k) e3t_a(i,j,k) 72 # define fse3u_a(i,j,k) e3u_a(i,j,k) 73 # define fse3v_a(i,j,k) e3v_a(i,j,k) 74 75 #elif defined key_vvl 36 76 ! s* or z*-coordinate (3D + time dependency) + use of additional now arrays (..._1) 37 77 # define fsdept(i,j,k) gdept_1(i,j,k) … … 63 103 # define fse3vw_n(i,j,k) (fse3vw_0(i,j,k)*(1.+sshv_n(i,j)*muv(i,j,k))) 64 104 65 # define fse3t_m(i,j,k) (fse3t_0(i,j,k)*(1.+ssh_m(i,j)*mut(i,j,k))) 105 ! - ML - Caution: only the first level of e3t_m is used (in limthd_2.F90) 106 ! It is replaced b y a 2d array 107 # define fse3t_m(i,j) (fse3t_0(i,j,1)*(1.+ssh_m(i,j)*mut(i,j,1))) 66 108 # define fse3t_d(i,j,k) e3t_d(i,j,k) 67 109 -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/DYN/dynnxt.F90
r2068 r2116 242 242 ! ------------------------------- 243 243 DO jk = 1, jpkm1 244 fse3t_b(:,:,jk) = fse3t_n(:,:,jk) + atfp * fse3t_d(:,:,jk) 244 fse3t_b(:,:,jk) = fse3t_n(:,:,jk) & 245 & + atfp * ( fse3t_b(:,:,jk) + fse3t_a(:,:,jk) & 246 & - 2.e0 * fse3t_n(:,:,jk) ) 245 247 ENDDO 246 248 ! Add volume filter correction only at the first level of t-point scale factors -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/DYN/sshwzv.F90
r2068 r2116 1 1 2 MODULE sshwzv 2 3 !!============================================================================== … … 156 157 ! In forward Euler time stepping case, the same formulation as in the leap-frog case can be used 157 158 ! because emp_b field is initialized with the vlaues of emp field. Hence, 0.5 * ( emp + emp_b ) = emp 158 IF( neuler == 0 .AND. kt == nit000 ) THEN 159 z1_rau0 = 1.e0 / rau0 160 ssha(:,:) = ( sshb(:,:) - z2dt * ( z1_rau0 * emp(:,:) + zhdiv(:,:) ) ) * tmask(:,:,1) 161 ELSE 162 z1_rau0 = 0.5 / rau0 163 ssha(:,:) = ( sshb(:,:) - z2dt * ( z1_rau0 * ( emp_b(:,:) + emp(:,:) ) + zhdiv(:,:) ) ) * tmask(:,:,1) 164 ENDIF 159 z1_rau0 = 0.5 / rau0 160 ssha(:,:) = ( sshb(:,:) - z2dt * ( z1_rau0 * ( emp_b(:,:) + emp(:,:) ) + zhdiv(:,:) ) ) * tmask(:,:,1) 165 161 166 162 #if defined key_obc … … 186 182 CALL lbc_lnk( sshv_a, 'V', 1. ) 187 183 ENDIF 188 ! !----------------------------------------!189 ! ! vertical scale factor laplacian !190 ! !----------------------------------------!191 ! Needed for Robert-Asselin time filter and for Brown & Campana semi implicit hydrostatic presure gradient192 DO jk = 1, jpk193 fse3t_d(:,:,jk) = fse3t_b(:,:,jk) &194 & - 2.e0 * fse3t_n(:,:,jk) &195 & + fse3t_a(:,:,jk)196 ENDDO197 184 ! !------------------------------! 198 185 ! ! Now Vertical Velocity ! -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/IOM/in_out_manager.F90
r1770 r2116 78 78 INTEGER :: nn_bench = 0 !: benchmark parameter (0/1) 79 79 INTEGER :: nn_bit_cmp = 0 !: bit reproducibility (0/1) 80 LOGICAL :: ln_hsb = .FALSE. !: check the heat and salt budgets 80 81 81 82 ! !: OLD namelist names -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/SBC/sbc_oce.F90
r2091 r2116 45 45 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: wndm !: wind speed module at T-point (=|U10m-Uoce|) [m/s] 46 46 !! wndm is used only in PISCES to compute surface gases exchanges in ice-free ocean or leads 47 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: qsr , qsr_b!: sea heat flux: solar [W/m2]47 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: qsr !: sea heat flux: solar [W/m2] 48 48 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: qns , qns_b !: sea heat flux: non solar [W/m2] 49 49 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: qsr_tot !: total solar heat flux (over sea and ice) [W/m2] … … 53 53 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: emp_tot !: total E-P-R over ocean and ice [Kg/m2/s] 54 54 ! - ML - begin 55 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: sbc_hc_n !: sbc heat content trend now [K /m/s]55 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: sbc_hc_n !: sbc heat content trend now [K.m/s] 56 56 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: sbc_hc_b !: " " " " before " 57 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: sbc_sc_n !: sbc salt content trend now [psu /m/s]57 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: sbc_sc_n !: sbc salt content trend now [psu.m/s] 58 58 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: sbc_sc_b !: " " " " before " 59 REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: qsr_hc_n !: heat content trend due to qsr flux now [K /m/s]59 REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: qsr_hc_n !: heat content trend due to qsr flux now [K.m/s] 60 60 REAL(wp), PUBLIC, DIMENSION(jpi,jpj,jpk) :: qsr_hc_b !: " " " " " " " before " 61 61 ! - ML - end … … 78 78 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: sss_m !: mean (nn_fsbc time-step) surface sea salinity [psu] 79 79 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: ssh_m !: mean (nn_fsbc time-step) sea surface height [m] 80 #if defined key_ztc 81 REAL(wp), PUBLIC, DIMENSION(jpi,jpj) :: e3t_m !: mean (nn_fsbc time-step) first ocean level thickness [m] 82 #endif 80 83 81 84 !!---------------------------------------------------------------------- -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/SBC/sbcmod.F90
r2091 r2116 195 195 vtau_b(:,:) = vtau(:,:) ! (except at nit000 where before fields 196 196 qns_b (:,:) = qns (:,:) ! are set at the end of the routine) 197 qsr_b (:,:) = qsr (:,:) 197 ! The 3D heat content due to qsr forcing is treated in traqsr 198 ! qsr_b (:,:) = qsr (:,:) 198 199 emp_b (:,:) = emp (:,:) 199 200 emps_b(:,:) = emps(:,:) 200 201 ENDIF 202 201 ENDIF 203 202 ! ! ---------------------------------------- ! 204 203 ! ! forcing field computation ! … … 259 258 CALL iom_get( numror, jpdom_autoglo, 'vtau_b', vtau_b ) ! before j-stress (V-point) 260 259 CALL iom_get( numror, jpdom_autoglo, 'qns_b' , qns_b ) ! before non solar heat flux (T-point) 261 CALL iom_get( numror, jpdom_autoglo, 'qsr_b' , qsr_b ) ! before solar heat flux (T-point) 260 ! The 3D heat content due to qsr forcing is treated in traqsr 261 ! CALL iom_get( numror, jpdom_autoglo, 'qsr_b' , qsr_b ) ! before solar heat flux (T-point) 262 262 CALL iom_get( numror, jpdom_autoglo, 'emp_b' , emp_b ) ! before freshwater flux (T-point) 263 263 CALL iom_get( numror, jpdom_autoglo, 'emps_b', emps_b ) ! before C/D freshwater flux (T-point) … … 267 267 vtau_b(:,:) = vtau(:,:) 268 268 qns_b (:,:) = qns (:,:) 269 qsr_b (:,:) = qsr (:,:)269 ! qsr_b (:,:) = qsr (:,:) 270 270 emp_b (:,:) = emp (:,:) 271 271 emps_b(:,:) = emps(:,:) … … 283 283 CALL iom_rstput( kt, nitrst, numrow, 'vtau_b' , vtau ) 284 284 CALL iom_rstput( kt, nitrst, numrow, 'qns_b' , qns ) 285 CALL iom_rstput( kt, nitrst, numrow, 'qsr_b' , qsr ) 285 ! The 3D heat content due to qsr forcing is treated in traqsr 286 ! CALL iom_rstput( kt, nitrst, numrow, 'qsr_b' , qsr ) 286 287 CALL iom_rstput( kt, nitrst, numrow, 'emp_b' , emp ) 287 288 CALL iom_rstput( kt, nitrst, numrow, 'emps_b' , emps ) -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/SBC/sbcssm.F90
r1715 r2116 64 64 sss_m(:,:) = sn(:,:,1) 65 65 ssh_m(:,:) = sshn(:,:) 66 IF( lk_vvl ) fse3t_m(:,:) = fse3t_n(:,:,1) 66 67 ! 67 68 ELSE … … 79 80 CALL iom_get( numror, jpdom_autoglo, 'sss_m' , sss_m ) ! " " salinity (T-point) 80 81 CALL iom_get( numror, jpdom_autoglo, 'ssh_m' , ssh_m ) ! " " height (T-point) 82 IF( lk_vvl ) THEN 83 CALL iom_get( numror, jpdom_autoglo, 'e3t_m' , fse3t_m ) ! first ocean level thickness (T-point) 84 ENDIF 81 85 ! 82 86 IF( zf_sbc /= REAL( nn_fsbc, wp ) ) THEN ! nn_fsbc has changed between 2 runs … … 89 93 sss_m(:,:) = zcoef * sss_m(:,:) 90 94 ssh_m(:,:) = zcoef * ssh_m(:,:) 95 IF( lk_vvl ) fse3t_m(:,:) = zcoef * fse3t_m(:,:) 91 96 ELSE 92 97 IF(lwp) WRITE(numout,*) '~~~~~~~ mean fields read in the ocean restart file' … … 100 105 sss_m(:,:) = zcoef * sn(:,:,1) 101 106 ssh_m(:,:) = zcoef * sshn(:,:) 107 IF( lk_vvl ) fse3t_m(:,:) = zcoef * fse3t_n(:,:,1) 102 108 ENDIF 103 109 ! ! ---------------------------------------- ! … … 109 115 sss_m(:,:) = 0.e0 110 116 ssh_m(:,:) = 0.e0 117 IF( lk_vvl ) fse3t_m(:,:) = 0.e0 111 118 ENDIF 112 119 ! ! ---------------------------------------- ! … … 118 125 sss_m(:,:) = sss_m(:,:) + sn(:,:,1) 119 126 ssh_m(:,:) = ssh_m(:,:) + sshn(:,:) 120 127 IF( lk_vvl ) fse3t_m(:,:) = fse3t_m(:,:) + fse3t_n(:,:,1) 121 128 ! ! ---------------------------------------- ! 122 129 IF( MOD( kt - 1 , nn_fsbc ) == 0 ) THEN ! Mean value at each nn_fsbc time-step ! 123 130 ! ! ---------------------------------------- ! 131 ! - ML - In a pure rigourous implementation, the averaging of sst and sss should be weighted 132 ! by the level thickness in vvl case. We suppose here that the effect is negligible. 124 133 zcoef = 1. / REAL( nn_fsbc, wp ) 125 134 sst_m(:,:) = sst_m(:,:) * zcoef ! mean SST [Celcius] … … 128 137 ssv_m(:,:) = ssv_m(:,:) * zcoef ! 129 138 ssh_m(:,:) = ssh_m(:,:) * zcoef ! mean SSH [m] 139 IF( lk_vvl ) fse3t_m(:,:) = fse3t_m(:,:) * zcoef ! first ocean level thickness [m] 130 140 ! 131 141 ENDIF … … 144 154 CALL iom_rstput( kt, nitrst, numrow, 'sss_m' , sss_m ) 145 155 CALL iom_rstput( kt, nitrst, numrow, 'ssh_m' , ssh_m ) 156 IF( lk_vvl ) THEN 157 CALL iom_rstput( kt, nitrst, numrow, 'e3t_m' , fse3t_m ) 158 ENDIF 146 159 ! 147 160 ENDIF -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/TRA/tranxt.F90
r2091 r2116 282 282 ze3t_n = fse3t_n(ji,jj,jk) 283 283 ze3t_a = fse3t_a(ji,jj,jk) 284 ze3t_d = fse3t_d(ji,jj,jk)284 ze3t_d = ze3t_b - 2.e0 * ze3t_n + ze3t_a 285 285 ! ! tracer content at Before, now and after 286 286 ztc_b = tb(ji,jj,jk) * ze3t_b ; zsc_b = sb(ji,jj,jk) * ze3t_b -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/TRA/trasbc.F90
r2091 r2116 127 127 qns(:,:) = qns(:,:) + qsr(:,:) ! total heat flux in qns 128 128 qsr(:,:) = 0.e0 ! qsr set to zero 129 IF( kt == nit000 ) THEN ! idem on before field at nit000130 qsr_b(:,:) = 0.e0131 ENDIF129 ! IF( kt == nit000 ) THEN ! idem on before field at nit000 130 ! qsr_b(:,:) = 0.e0 131 ! ENDIF 132 132 ENDIF 133 133 ! Set before sbc tracer content fields … … 186 186 ! Write in the ocean restart file 187 187 ! ******************************* 188 IF(lwp) WRITE(numout,*) 189 IF(lwp) WRITE(numout,*) 'sbc : ocean surface tracer content forcing fields written in ocean restart file ', & 190 & 'at it= ', kt,' date= ', ndastp 191 IF(lwp) WRITE(numout,*) '~~~~' 192 CALL iom_rstput( kt, nitrst, numrow, 'sbc_hc_b', sbc_hc_n ) 193 CALL iom_rstput( kt, nitrst, numrow, 'sbc_sc_b', sbc_sc_n ) 188 IF( lrst_oce ) THEN 189 IF(lwp) WRITE(numout,*) 190 IF(lwp) WRITE(numout,*) 'sbc : ocean surface tracer content forcing fields written in ocean restart file ', & 191 & 'at it= ', kt,' date= ', ndastp 192 IF(lwp) WRITE(numout,*) '~~~~' 193 CALL iom_rstput( kt, nitrst, numrow, 'sbc_hc_b', sbc_hc_n ) 194 CALL iom_rstput( kt, nitrst, numrow, 'sbc_sc_b', sbc_sc_n ) 195 ENDIF 194 196 195 197 IF( l_trdtra ) THEN ! save the sbc trends for diagnostic -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/opa.F90
r1793 r2116 54 54 USE trdmod ! momentum/tracers trends (trd_mod_init routine) 55 55 USE diaptr ! poleward transports (dia_ptr_init routine) 56 USE diahsb ! heat, salt and volume budgets (dia_hsb_init routine) 56 57 USE step ! OPA time-stepping (stp routine) 57 58 #if defined key_oasis3 … … 180 181 !! 181 182 NAMELIST/namctl/ ln_ctl , nn_print, nn_ictls, nn_ictle, & 182 & nn_isplt, nn_jsplt, nn_jctls, nn_jctle, nn_bench, nn_bit_cmp 183 & nn_isplt, nn_jsplt, nn_jctls, nn_jctle, nn_bench, nn_bit_cmp, ln_hsb 183 184 !!---------------------------------------------------------------------- 184 185 ! … … 279 280 CALL dia_ptr_init ! Poleward TRansports initialization 280 281 CALL trd_mod_init ! Mixed-layer/Vorticity/Integral constraints trends 282 IF(ln_hsb) CALL dia_hsb_init ! heat content, salt content and volume budgets 281 283 ! 282 284 END SUBROUTINE opa_init … … 313 315 WRITE(numout,*) ' benchmark parameter (0/1) nn_bench = ', nn_bench 314 316 WRITE(numout,*) ' bit comparison mode (0/1) nn_bit_cmp = ', nn_bit_cmp 317 WRITE(numout,*) ' check the heat and salt budgets ln_hsb = ', ln_hsb 315 318 ENDIF 316 319 -
branches/dev_r2091_ZTC/NEMO/OPA_SRC/step.F90
r2068 r2116 117 117 USE prtctl ! Print control (prt_ctl routine) 118 118 ! - ML - 119 USE dia trb ! global tracer conservation (dia_trb routine)119 USE diahsb ! global tracer conservation (dia_hsb routine) 120 120 121 121 #if defined key_agrif … … 320 320 321 321 CALL ssh_nxt( kstp ) ! sea surface height at next time step 322 CALL dia_trb( kstp ) ! - ML - global conservation diagnostics322 IF( ln_hsb ) CALL dia_hsb( kstp ) ! - ML - global conservation diagnostics 323 323 324 324 !>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
Note: See TracChangeset
for help on using the changeset viewer.