Changeset 7282 for branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC
- Timestamp:
- 2016-11-21T12:13:57+01:00 (8 years ago)
- Location:
- branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC
- Files:
-
- 12 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/DIA/diadct.F90
- Property svn:executable deleted
-
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/DOM/domain.F90
r7277 r7282 153 153 ! 154 154 ! before ! now ! after ! 155 ;gdept_b = gdept_0 ; gdept_n = gdept_0 ! --- ! depth of grid-points156 ;gdepw_b = gdepw_0 ; gdepw_n = gdepw_0 ! --- !157 ; ;gde3w_n = gde3w_0 ! --- !155 gdept_b = gdept_0 ; gdept_n = gdept_0 ! --- ! depth of grid-points 156 gdepw_b = gdepw_0 ; gdepw_n = gdepw_0 ! --- ! 157 gde3w_n = gde3w_0 ! --- ! 158 158 ! 159 ;e3t_b = e3t_0 ; e3t_n = e3t_0 ; e3t_a = e3t_0 ! scale factors160 ;e3u_b = e3u_0 ; e3u_n = e3u_0 ; e3u_a = e3u_0 !161 ;e3v_b = e3v_0 ; e3v_n = e3v_0 ; e3v_a = e3v_0 !162 ; ;e3f_n = e3f_0 ! --- !163 ;e3w_b = e3w_0 ; e3w_n = e3w_0 ! --- !164 ;e3uw_b = e3uw_0 ; e3uw_n = e3uw_0 ! --- !165 ;e3vw_b = e3vw_0 ; e3vw_n = e3vw_0 ! --- !159 e3t_b = e3t_0 ; e3t_n = e3t_0 ; e3t_a = e3t_0 ! scale factors 160 e3u_b = e3u_0 ; e3u_n = e3u_0 ; e3u_a = e3u_0 ! 161 e3v_b = e3v_0 ; e3v_n = e3v_0 ; e3v_a = e3v_0 ! 162 e3f_n = e3f_0 ! --- ! 163 e3w_b = e3w_0 ; e3w_n = e3w_0 ! --- ! 164 e3uw_b = e3uw_0 ; e3uw_n = e3uw_0 ! --- ! 165 e3vw_b = e3vw_0 ; e3vw_n = e3vw_0 ! --- ! 166 166 ! 167 167 z1_hu_0(:,:) = ssumask(:,:) / ( hu_0(:,:) + 1._wp - ssumask(:,:) ) ! _i mask due to ISF … … 169 169 ! 170 170 ! before ! now ! after ! 171 ; ;ht_n = ht_0 ! ! water column thickness172 ;hu_b = hu_0 ; hu_n = hu_0 ; hu_a = hu_0 !173 ;hv_b = hv_0 ; hv_n = hv_0 ; hv_a = hv_0 !174 ;r1_hu_b = z1_hu_0 ; r1_hu_n = z1_hu_0 ; r1_hu_a = z1_hu_0 ! inverse of water column thickness175 ;r1_hv_b = z1_hv_0 ; r1_hv_n = z1_hv_0 ; r1_hv_a = z1_hv_0 !171 ht_n = ht_0 ! ! water column thickness 172 hu_b = hu_0 ; hu_n = hu_0 ; hu_a = hu_0 ! 173 hv_b = hv_0 ; hv_n = hv_0 ; hv_a = hv_0 ! 174 r1_hu_b = z1_hu_0 ; r1_hu_n = z1_hu_0 ; r1_hu_a = z1_hu_0 ! inverse of water column thickness 175 r1_hv_b = z1_hv_0 ; r1_hv_n = z1_hv_0 ; r1_hv_a = z1_hv_0 ! 176 176 ! 177 177 ! -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/DYN/dynadv_cen2.F90
r6140 r7282 118 118 ENDIF 119 119 DO jk = 2, jpkm1 ! interior advective fluxes 120 DO jj = 2, jpj m1! 1/4 * Vertical transport121 DO ji = fs_2, fs_jpim1120 DO jj = 2, jpj ! 1/4 * Vertical transport 121 DO ji = 2, jpi 122 122 zfw(ji,jj,jk) = 0.25_wp * e1e2t(ji,jj) * wn(ji,jj,jk) 123 123 END DO -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/DYN/dynadv_ubs.F90
r6140 r7282 211 211 ENDIF 212 212 DO jk = 2, jpkm1 ! interior fluxes 213 DO jj = 2, jpj m1214 DO ji = fs_2, fs_jpim1213 DO jj = 2, jpj 214 DO ji = 2, jpi 215 215 zfw(ji,jj,jk) = 0.25_wp * e1e2t(ji,jj) * wn(ji,jj,jk) 216 216 END DO -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/DYN/dynspg.F90
r7280 r7282 205 205 ENDIF 206 206 ! ! Control of surface pressure gradient scheme options 207 ;nspg = np_NO ; ioptio = 0207 nspg = np_NO ; ioptio = 0 208 208 IF( ln_dynspg_exp ) THEN ; nspg = np_EXP ; ioptio = ioptio + 1 ; ENDIF 209 209 IF( ln_dynspg_ts ) THEN ; nspg = np_TS ; ioptio = ioptio + 1 ; ENDIF -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/DYN/dynzdf_imp.F90
r6140 r7282 294 294 ze3va = ( 1._wp - r_vvl ) * e3v_n(ji,jj,1) + r_vvl * e3v_a(ji,jj,1) 295 295 va(ji,jj,1) = va(ji,jj,1) + p2dt * 0.5_wp * ( vtau_b(ji,jj) + vtau(ji,jj) ) & 296 & / ( ze3va * rau0 ) 296 & / ( ze3va * rau0 ) * vmask(ji,jj,1) 297 297 END DO 298 298 END DO -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/ICB/icbini.F90
r7280 r7282 120 120 ! first entry with narea for this processor is left hand interior index 121 121 ! last entry is right hand interior index 122 jj = jpj/2122 jj = nlcj/2 123 123 nicbdi = -1 124 124 nicbei = -1 … … 136 136 ! 137 137 ! repeat for j direction 138 ji = jpi/2138 ji = nlci/2 139 139 nicbdj = -1 140 140 nicbej = -1 … … 153 153 ! special for east-west boundary exchange we save the destination index 154 154 i1 = MAX( nicbdi-1, 1) 155 i3 = INT( src_calving(i1, jpj/2) )155 i3 = INT( src_calving(i1,nlcj/2) ) 156 156 jj = INT( i3/nicbpack ) 157 157 ricb_left = REAL( i3 - nicbpack*jj, wp ) 158 158 i1 = MIN( nicbei+1, jpi ) 159 i3 = INT( src_calving(i1, jpj/2) )159 i3 = INT( src_calving(i1,nlcj/2) ) 160 160 jj = INT( i3/nicbpack ) 161 161 ricb_right = REAL( i3 - nicbpack*jj, wp ) … … 196 196 WRITE(numicb,*) 'berg left ', ricb_left 197 197 WRITE(numicb,*) 'berg right ', ricb_right 198 jj = jpj/2198 jj = nlcj/2 199 199 WRITE(numicb,*) "central j line:" 200 200 WRITE(numicb,*) "i processor" … … 202 202 WRITE(numicb,*) "i point" 203 203 WRITE(numicb,*) (INT(src_calving(ji,jj)), ji=1,jpi) 204 ji = jpi/2204 ji = nlci/2 205 205 WRITE(numicb,*) "central i line:" 206 206 WRITE(numicb,*) "j processor" -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/LBC/lib_mpp.F90
r7280 r7282 2983 2983 !!---------------------------------------------------------------------- 2984 2984 ! 2985 ALLOCATE( ztab(jpiglo,4,num_fields), znorthloc(jpi,4,num_fields), zfoldwk(jpi,4,num_fields), znorthgloio(jpi,4,num_fields,jpni) ) ! expanded to 3 dimensions 2985 ALLOCATE( ztab(jpiglo,4,num_fields), znorthloc(jpi,4,num_fields), zfoldwk(jpi,4,num_fields), & 2986 & znorthgloio(jpi,4,num_fields,jpni) ) ! expanded to 3 dimensions 2986 2987 ALLOCATE( ztabl(jpi,4,num_fields), ztabr(jpi*jpmaxngh, 4,num_fields) ) 2987 2988 ! -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/SBC/sbcblk.F90
r7280 r7282 281 281 IF( MOD( kt - 1, nn_fsbc ) == 0 ) THEN 282 282 qlw_ice(:,:,1) = sf(jp_qlw )%fnow(:,:,1) 283 qsr_ice(:,:,1) = sf(jp_qsr )%fnow(:,:,1) 283 IF( ln_dm2dc ) THEN ; qsr_ice(:,:,1) = sbc_dcy( sf(jp_qsr)%fnow(:,:,1) ) 284 ELSE ; qsr_ice(:,:,1) = sf(jp_qsr)%fnow(:,:,1) 285 ENDIF 284 286 tatm_ice(:,:) = sf(jp_tair)%fnow(:,:,1) 285 287 qatm_ice(:,:) = sf(jp_humi)%fnow(:,:,1) -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/SBC/sbccpl.F90
r7278 r7282 1327 1327 !! *** ROUTINE sbc_cpl_ice_flx *** 1328 1328 !! 1329 !! ** Purpose : provide the heat and freshwater fluxes of the 1330 !! ocean-ice system. 1329 !! ** Purpose : provide the heat and freshwater fluxes of the ocean-ice system 1331 1330 !! 1332 1331 !! ** Method : transform the fields received from the atmosphere into 1333 1332 !! surface heat and fresh water boundary condition for the 1334 1333 !! ice-ocean system. The following fields are provided: 1335 !! * total non solar, solar and freshwater fluxes (qns_tot,1334 !! * total non solar, solar and freshwater fluxes (qns_tot, 1336 1335 !! qsr_tot and emp_tot) (total means weighted ice-ocean flux) 1337 1336 !! NB: emp_tot include runoffs and calving. 1338 !! * fluxes over ice (qns_ice, qsr_ice, emp_ice) where1337 !! * fluxes over ice (qns_ice, qsr_ice, emp_ice) where 1339 1338 !! emp_ice = sublimation - solid precipitation as liquid 1340 1339 !! precipitation are re-routed directly to the ocean and 1341 !! runoffs and calving directly enter the ocean.1342 !! * solid precipitation (sprecip), used to add to qns_tot1340 !! calving directly enter the ocean (runoffs are read but included in trasbc.F90) 1341 !! * solid precipitation (sprecip), used to add to qns_tot 1343 1342 !! the heat lost associated to melting solid precipitation 1344 1343 !! over the ocean fraction. 1345 !! ===>> CAUTION here this changes the net heat flux received from 1346 !! the atmosphere 1347 !! 1348 !! - the fluxes have been separated from the stress as 1349 !! (a) they are updated at each ice time step compare to 1350 !! an update at each coupled time step for the stress, and 1351 !! (b) the conservative computation of the fluxes over the 1352 !! sea-ice area requires the knowledge of the ice fraction 1353 !! after the ice advection and before the ice thermodynamics, 1354 !! so that the stress is updated before the ice dynamics 1355 !! while the fluxes are updated after it. 1344 !! * heat content of rain, snow and evap can also be provided, 1345 !! otherwise heat flux associated with these mass flux are 1346 !! guessed (qemp_oce, qemp_ice) 1347 !! 1348 !! - the fluxes have been separated from the stress as 1349 !! (a) they are updated at each ice time step compare to 1350 !! an update at each coupled time step for the stress, and 1351 !! (b) the conservative computation of the fluxes over the 1352 !! sea-ice area requires the knowledge of the ice fraction 1353 !! after the ice advection and before the ice thermodynamics, 1354 !! so that the stress is updated before the ice dynamics 1355 !! while the fluxes are updated after it. 1356 !! 1357 !! ** Details 1358 !! qns_tot = pfrld * qns_oce + ( 1 - pfrld ) * qns_ice => provided 1359 !! + qemp_oce + qemp_ice => recalculated and added up to qns 1360 !! 1361 !! qsr_tot = pfrld * qsr_oce + ( 1 - pfrld ) * qsr_ice => provided 1362 !! 1363 !! emp_tot = emp_oce + emp_ice => calving is provided and added to emp_tot (and emp_oce) 1364 !! river runoff (rnf) is provided but not included here 1356 1365 !! 1357 1366 !! ** Action : update at each nf_ice time step: 1358 1367 !! qns_tot, qsr_tot non-solar and solar total heat fluxes 1359 1368 !! qns_ice, qsr_ice non-solar and solar heat fluxes over the ice 1360 !! emp_tot total evaporation - precipitation(liquid and solid) (-runoff)(-calving)1361 !! emp_ice 1362 !! dqns_ice 1363 !! sprecip 1369 !! emp_tot total evaporation - precipitation(liquid and solid) (-calving) 1370 !! emp_ice ice sublimation - solid precipitation over the ice 1371 !! dqns_ice d(non-solar heat flux)/d(Temperature) over the ice 1372 !! sprecip solid precipitation over the ocean 1364 1373 !!---------------------------------------------------------------------- 1365 REAL(wp), INTENT(in ), DIMENSION(:,:) :: p_frld ! lead fraction[0 to 1]1374 REAL(wp), INTENT(in ), DIMENSION(:,:) :: p_frld ! lead fraction [0 to 1] 1366 1375 ! optional arguments, used only in 'mixed oce-ice' case 1367 REAL(wp), INTENT(in ), DIMENSION(:,:,:), OPTIONAL :: palbi ! all skies ice albedo1368 REAL(wp), INTENT(in ), DIMENSION(:,: ), OPTIONAL :: psst ! sea surface temperature[Celsius]1369 REAL(wp), INTENT(in ), DIMENSION(:,:,:), OPTIONAL :: pist ! ice surface temperature[Kelvin]1370 ! 1371 INTEGER :: jl ! dummy loop index1376 REAL(wp), INTENT(in ), DIMENSION(:,:,:), OPTIONAL :: palbi ! all skies ice albedo 1377 REAL(wp), INTENT(in ), DIMENSION(:,: ), OPTIONAL :: psst ! sea surface temperature [Celsius] 1378 REAL(wp), INTENT(in ), DIMENSION(:,:,:), OPTIONAL :: pist ! ice surface temperature [Kelvin] 1379 ! 1380 INTEGER :: jl ! dummy loop index 1372 1381 REAL(wp), POINTER, DIMENSION(:,: ) :: zcptn, ztmp, zicefr, zmsk, zsnw 1373 REAL(wp), POINTER, DIMENSION(:,: ) :: zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap , zevap_ice, zdevap_ice1382 REAL(wp), POINTER, DIMENSION(:,: ) :: zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap_oce, zevap_ice, zdevap_ice 1374 1383 REAL(wp), POINTER, DIMENSION(:,: ) :: zqns_tot, zqns_oce, zqsr_tot, zqsr_oce, zqprec_ice, zqemp_oce, zqemp_ice 1375 1384 REAL(wp), POINTER, DIMENSION(:,:,:) :: zqns_ice, zqsr_ice, zdqns_ice, zqevap_ice 1376 1385 !!---------------------------------------------------------------------- 1377 1386 ! 1378 IF( nn_timing == 1 ) 1387 IF( nn_timing == 1 ) CALL timing_start('sbc_cpl_ice_flx') 1379 1388 ! 1380 1389 CALL wrk_alloc( jpi,jpj, zcptn, ztmp, zicefr, zmsk, zsnw ) 1381 CALL wrk_alloc( jpi,jpj, zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap , zevap_ice, zdevap_ice )1390 CALL wrk_alloc( jpi,jpj, zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap_oce, zevap_ice, zdevap_ice ) 1382 1391 CALL wrk_alloc( jpi,jpj, zqns_tot, zqns_oce, zqsr_tot, zqsr_oce, zqprec_ice, zqemp_oce, zqemp_ice ) 1383 1392 CALL wrk_alloc( jpi,jpj,jpl, zqns_ice, zqsr_ice, zdqns_ice, zqevap_ice ) … … 1388 1397 ! 1389 1398 ! ! ========================= ! 1390 ! ! freshwater budget ! (emp )1399 ! ! freshwater budget ! (emp_tot) 1391 1400 ! ! ========================= ! 1392 1401 ! 1393 ! ! total Precipitation - total Evaporation (emp_tot)1394 ! ! solid precipitation - sublimation (emp_ice)1395 ! ! solid Precipitation (sprecip)1396 ! ! liquid + solid Precipitation (tprecip)1402 ! ! solid Precipitation (sprecip) 1403 ! ! liquid + solid Precipitation (tprecip) 1404 ! ! total Evaporation - total Precipitation (emp_tot) 1405 ! ! sublimation - solid precipitation (cell average) (emp_ice) 1397 1406 SELECT CASE( TRIM( sn_rcv_emp%cldes ) ) 1398 CASE( 'conservative' 1399 zsprecip(:,:) = frcv(jpr_snow)%z3(:,:,1) ! May need to ensure positive here1400 ztprecip(:,:) = frcv(jpr_rain)%z3(:,:,1) + zsprecip(:,:) ! May need to ensure positive here1401 zemp_tot(:,:) = frcv(jpr_tevp)%z3(:,:,1) - ztprecip(:,:)1402 zemp_ice(:,:) = frcv(jpr_ievp)%z3(:,:,1) - frcv(jpr_snow)%z3(:,:,1)1403 CALL iom_put( 'rain' , frcv(jpr_rain)%z3(:,:,1) )! liquid precipitation1407 CASE( 'conservative' ) ! received fields: jpr_rain, jpr_snow, jpr_ievp, jpr_tevp 1408 zsprecip(:,:) = frcv(jpr_snow)%z3(:,:,1) ! May need to ensure positive here 1409 ztprecip(:,:) = frcv(jpr_rain)%z3(:,:,1) + zsprecip(:,:) ! May need to ensure positive here 1410 zemp_tot(:,:) = frcv(jpr_tevp)%z3(:,:,1) - ztprecip(:,:) 1411 zemp_ice(:,:) = ( frcv(jpr_ievp)%z3(:,:,1) - frcv(jpr_snow)%z3(:,:,1) ) * zicefr(:,:) 1412 CALL iom_put( 'rain' , frcv(jpr_rain)%z3(:,:,1) ) ! liquid precipitation 1404 1413 IF( iom_use('hflx_rain_cea') ) & 1405 CALL iom_put( 'hflx_rain_cea', frcv(jpr_rain)%z3(:,:,1) * zcptn(:,:) ) ! heat flux from liq. precip. 1406 IF( iom_use('evap_ao_cea') .OR. iom_use('hflx_evap_cea') ) & 1407 ztmp(:,:) = frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) 1414 & CALL iom_put( 'hflx_rain_cea', frcv(jpr_rain)%z3(:,:,1) * zcptn(:,:) ) ! heat flux from liq. precip. 1408 1415 IF( iom_use('evap_ao_cea' ) ) & 1409 CALL iom_put( 'evap_ao_cea' , ztmp )! ice-free oce evap (cell average)1416 & CALL iom_put( 'evap_ao_cea' , frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) ) ! ice-free oce evap (cell average) 1410 1417 IF( iom_use('hflx_evap_cea') ) & 1411 CALL iom_put( 'hflx_evap_cea', ztmp(:,:) * zcptn(:,:) )! heat flux from from evap (cell average)1412 CASE( 'oce and ice' 1418 & CALL iom_put( 'hflx_evap_cea', ( frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) ) * zcptn(:,:) ) ! heat flux from from evap (cell average) 1419 CASE( 'oce and ice' ) ! received fields: jpr_sbpr, jpr_semp, jpr_oemp, jpr_ievp 1413 1420 zemp_tot(:,:) = p_frld(:,:) * frcv(jpr_oemp)%z3(:,:,1) + zicefr(:,:) * frcv(jpr_sbpr)%z3(:,:,1) 1414 zemp_ice(:,:) = frcv(jpr_semp)%z3(:,:,1) 1421 zemp_ice(:,:) = frcv(jpr_semp)%z3(:,:,1) * zicefr(:,:) 1415 1422 zsprecip(:,:) = frcv(jpr_ievp)%z3(:,:,1) - frcv(jpr_semp)%z3(:,:,1) 1416 1423 ztprecip(:,:) = frcv(jpr_semp)%z3(:,:,1) - frcv(jpr_sbpr)%z3(:,:,1) + zsprecip(:,:) 1417 1424 END SELECT 1425 1418 1426 #if defined key_lim3 1419 ! zsnw = snow percentage over ice after wind blowing 1420 zsnw(:,:) = 0._wp 1421 CALL lim_thd_snwblow( p_frld, zsnw ) 1427 ! zsnw = snow fraction over ice after wind blowing 1428 zsnw(:,:) = 0._wp ; CALL lim_thd_snwblow( p_frld, zsnw ) 1422 1429 1423 ! --- evaporation (used later in sbccpl) --- ! 1424 zevap(:,:) = zemp_tot(:,:) + ztprecip(:,:) 1430 ! --- evaporation minus precipitation corrected (because of wind blowing on snow) --- ! 1431 zemp_ice(:,:) = zemp_ice(:,:) + zsprecip(:,:) * ( zicefr(:,:) - zsnw(:,:) ) ! emp_ice = A * sublimation - zsnw * sprecip 1432 zemp_oce(:,:) = zemp_tot(:,:) - zemp_ice(:,:) ! emp_oce = emp_tot - emp_ice 1433 1434 ! --- evaporation over ocean (used later for qemp) --- ! 1435 zevap_oce(:,:) = frcv(jpr_tevp)%z3(:,:,1) - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) 1425 1436 1426 1437 ! --- evaporation over ice (kg/m2/s) --- ! … … 1430 1441 zdevap_ice(:,:) = 0._wp 1431 1442 1432 ! --- evaporation minus precipitation corrected for the effect of wind blowing on snow --- !1433 zemp_oce(:,:) = zemp_tot(:,:) - zemp_ice(:,:) - zsprecip * (1._wp - zsnw)1434 zemp_ice(:,:) = zemp_ice(:,:) + zsprecip * (1._wp - zsnw)1435 1436 1443 ! --- runoffs (included in emp later on) --- ! 1437 1444 IF( srcv(jpr_rnf)%laction ) rnf(:,:) = frcv(jpr_rnf)%z3(:,:,1) … … 1443 1450 CALL iom_put( 'calving_cea', frcv(jpr_cal)%z3(:,:,1) ) 1444 1451 ENDIF 1445 1452 1446 1453 IF( ln_mixcpl ) THEN 1447 1454 emp_tot(:,:) = emp_tot(:,:) * xcplmask(:,:,0) + zemp_tot(:,:) * zmsk(:,:) … … 1465 1472 ENDDO 1466 1473 ENDIF 1467 1468 IF( iom_use('subl_ai_cea') ) CALL iom_put( 'subl_ai_cea', zevap_ice(:,:) * zicefr(:,:) ) ! Sublimation over sea-ice (cell average)1469 CALL iom_put( 'snowpre' , sprecip ) ! Snow1470 IF( iom_use('snow_ao_cea') ) CALL iom_put( 'snow_ao_cea', sprecip(:,:) * ( 1._wp - zsnw ) ) ! Snow over ice-free ocean (cell average)1471 IF( iom_use('snow_ai_cea') ) CALL iom_put( 'snow_ai_cea', sprecip(:,:) * zsnw ) ! Snow over sea-ice (cell average)1474 1475 IF( iom_use('subl_ai_cea') ) CALL iom_put( 'subl_ai_cea', zevap_ice(:,:) * zicefr(:,:) ) ! Sublimation over sea-ice (cell average) 1476 CALL iom_put( 'snowpre' , sprecip(:,:) ) ! Snow 1477 IF( iom_use('snow_ao_cea') ) CALL iom_put( 'snow_ao_cea', sprecip(:,:) * ( 1._wp - zsnw(:,:) ) ) ! Snow over ice-free ocean (cell average) 1478 IF( iom_use('snow_ai_cea') ) CALL iom_put( 'snow_ai_cea', sprecip(:,:) * zsnw(:,:) ) ! Snow over sea-ice (cell average) 1472 1479 #else 1473 ! Sublimation over sea-ice (cell average)1474 IF( iom_use('subl_ai_cea') ) CALL iom_put( 'subl_ai_cea', frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) )1475 1480 ! runoffs and calving (put in emp_tot) 1476 1481 IF( srcv(jpr_rnf)%laction ) rnf(:,:) = frcv(jpr_rnf)%z3(:,:,1) … … 1492 1497 ENDIF 1493 1498 1494 CALL iom_put( 'snowpre' , sprecip ) ! Snow 1495 IF( iom_use('snow_ao_cea') ) & 1496 CALL iom_put( 'snow_ao_cea', sprecip(:,:) * p_frld(:,:) ) ! Snow over ice-free ocean (cell average) 1497 IF( iom_use('snow_ai_cea') ) & 1498 CALL iom_put( 'snow_ai_cea', sprecip(:,:) * zicefr(:,:) ) ! Snow over sea-ice (cell average) 1499 IF( iom_use('subl_ai_cea') ) CALL iom_put( 'subl_ai_cea', frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) ) ! Sublimation over sea-ice (cell average) 1500 CALL iom_put( 'snowpre' , sprecip(:,:) ) ! Snow 1501 IF( iom_use('snow_ao_cea') ) CALL iom_put( 'snow_ao_cea', sprecip(:,:) * p_frld(:,:) ) ! Snow over ice-free ocean (cell average) 1502 IF( iom_use('snow_ai_cea') ) CALL iom_put( 'snow_ai_cea', sprecip(:,:) * zicefr(:,:) ) ! Snow over sea-ice (cell average) 1499 1503 #endif 1500 1504 … … 1502 1506 SELECT CASE( TRIM( sn_rcv_qns%cldes ) ) ! non solar heat fluxes ! (qns) 1503 1507 ! ! ========================= ! 1504 CASE( 'oce only' ) 1505 zqns_tot(:,: 1506 CASE( 'conservative' ) 1507 zqns_tot(:,: 1508 CASE( 'oce only' ) ! the required field is directly provided 1509 zqns_tot(:,:) = frcv(jpr_qnsoce)%z3(:,:,1) 1510 CASE( 'conservative' ) ! the required fields are directly provided 1511 zqns_tot(:,:) = frcv(jpr_qnsmix)%z3(:,:,1) 1508 1512 IF ( TRIM(sn_rcv_qns%clcat) == 'yes' ) THEN 1509 1513 zqns_ice(:,:,1:jpl) = frcv(jpr_qnsice)%z3(:,:,1:jpl) 1510 1514 ELSE 1511 ! Set all category values equal for the moment1512 1515 DO jl=1,jpl 1513 zqns_ice(:,:,jl) = frcv(jpr_qnsice)%z3(:,:,1) 1516 zqns_ice(:,:,jl) = frcv(jpr_qnsice)%z3(:,:,1) ! Set all category values equal 1514 1517 ENDDO 1515 1518 ENDIF 1516 CASE( 'oce and ice' ) 1517 zqns_tot(:,: 1519 CASE( 'oce and ice' ) ! the total flux is computed from ocean and ice fluxes 1520 zqns_tot(:,:) = p_frld(:,:) * frcv(jpr_qnsoce)%z3(:,:,1) 1518 1521 IF ( TRIM(sn_rcv_qns%clcat) == 'yes' ) THEN 1519 1522 DO jl=1,jpl … … 1522 1525 ENDDO 1523 1526 ELSE 1524 qns_tot(:,: 1527 qns_tot(:,:) = qns_tot(:,:) + zicefr(:,:) * frcv(jpr_qnsice)%z3(:,:,1) 1525 1528 DO jl=1,jpl 1526 1529 zqns_tot(:,: ) = zqns_tot(:,:) + zicefr(:,:) * frcv(jpr_qnsice)%z3(:,:,1) … … 1528 1531 ENDDO 1529 1532 ENDIF 1530 CASE( 'mixed oce-ice' ) 1533 CASE( 'mixed oce-ice' ) ! the ice flux is cumputed from the total flux, the SST and ice informations 1531 1534 ! ** NEED TO SORT OUT HOW THIS SHOULD WORK IN THE MULTI-CATEGORY CASE - CURRENTLY NOT ALLOWED WHEN INTERFACE INITIALISED ** 1532 1535 zqns_tot(:,: ) = frcv(jpr_qnsmix)%z3(:,:,1) 1533 1536 zqns_ice(:,:,1) = frcv(jpr_qnsmix)%z3(:,:,1) & 1534 1537 & + frcv(jpr_dqnsdt)%z3(:,:,1) * ( pist(:,:,1) - ( (rt0 + psst(:,: ) ) * p_frld(:,:) & 1535 & + pist(:,:,1)* zicefr(:,:) ) )1538 & + pist(:,:,1) * zicefr(:,:) ) ) 1536 1539 END SELECT 1537 1540 !!gm … … 1543 1546 !! similar job should be done for snow and precipitation temperature 1544 1547 ! 1545 IF( srcv(jpr_cal)%laction ) THEN ! Iceberg melting 1546 ztmp(:,:) = frcv(jpr_cal)%z3(:,:,1) * lfus ! add the latent heat of iceberg melting 1547 zqns_tot(:,:) = zqns_tot(:,:) - ztmp(:,:) 1548 IF( iom_use('hflx_cal_cea') ) & 1549 CALL iom_put( 'hflx_cal_cea', ztmp + frcv(jpr_cal)%z3(:,:,1) * zcptn(:,:) ) ! heat flux from calving 1550 ENDIF 1551 1552 ztmp(:,:) = p_frld(:,:) * zsprecip(:,:) * lfus 1553 IF( iom_use('hflx_snow_cea') ) CALL iom_put( 'hflx_snow_cea', ztmp + sprecip(:,:) * zcptn(:,:) ) ! heat flux from snow (cell average) 1548 IF( srcv(jpr_cal)%laction ) THEN ! Iceberg melting 1549 zqns_tot(:,:) = zqns_tot(:,:) - frcv(jpr_cal)%z3(:,:,1) * lfus ! add the latent heat of iceberg melting 1550 ! we suppose it melts at 0deg, though it should be temp. of surrounding ocean 1551 IF( iom_use('hflx_cal_cea') ) CALL iom_put( 'hflx_cal_cea', - frcv(jpr_cal)%z3(:,:,1) * lfus ) ! heat flux from calving 1552 ENDIF 1554 1553 1555 1554 #if defined key_lim3 … … 1560 1559 1561 1560 ! --- heat flux associated with emp (W/m2) --- ! 1562 zqemp_oce(:,:) = - zevap(:,:) * p_frld(:,:) * zcptn(:,:) &! evap1563 & + ( ztprecip(:,:) - zsprecip(:,:) ) * zcptn(:,:) & ! liquid precip1564 & + zsprecip(:,:) * ( 1._wp - zsnw ) * ( zcptn(:,:) - lfus ) ! solid precip over ocean1561 zqemp_oce(:,:) = - zevap_oce(:,:) * zcptn(:,:) & ! evap 1562 & + ( ztprecip(:,:) - zsprecip(:,:) ) * zcptn(:,:) & ! liquid precip 1563 & + zsprecip(:,:) * ( 1._wp - zsnw ) * ( zcptn(:,:) - lfus ) ! solid precip over ocean + snow melting 1565 1564 ! zqemp_ice(:,:) = - frcv(jpr_ievp)%z3(:,:,1) * zicefr(:,:) * zcptn(:,:) & ! ice evap 1566 1565 ! & + zsprecip(:,:) * zsnw * ( zcptn(:,:) - lfus ) ! solid precip over ice 1567 1566 zqemp_ice(:,:) = zsprecip(:,:) * zsnw * ( zcptn(:,:) - lfus ) ! solid precip over ice (only) 1568 ! qevap_ice=0 since we consider Tice=0 °C1567 ! qevap_ice=0 since we consider Tice=0degC 1569 1568 1570 ! --- heat content ofprecip over ice in J/m3 (to be used in 1D-thermo) --- !1569 ! --- enthalpy of snow precip over ice in J/m3 (to be used in 1D-thermo) --- ! 1571 1570 zqprec_ice(:,:) = rhosn * ( zcptn(:,:) - lfus ) 1572 1571 1573 1572 ! --- heat content of evap over ice in W/m2 (to be used in 1D-thermo) --- ! 1574 1573 DO jl = 1, jpl 1575 zqevap_ice(:,:,jl) = 0._wp ! should be -evap * ( ( Tice - rt0 ) * cpic ) but we do not have Tice, so we consider Tice=0 °C1574 zqevap_ice(:,:,jl) = 0._wp ! should be -evap * ( ( Tice - rt0 ) * cpic ) but we do not have Tice, so we consider Tice=0degC 1576 1575 END DO 1577 1576 … … 1599 1598 qemp_ice (:,: ) = zqemp_ice (:,: ) 1600 1599 ENDIF 1600 1601 !! clem: we should output qemp_oce and qemp_ice (at least) 1602 IF( iom_use('hflx_snow_cea') ) CALL iom_put( 'hflx_snow_cea', sprecip(:,:) * ( zcptn(:,:) - Lfus ) ) ! heat flux from snow (cell average) 1603 !! these diags are not outputed yet 1604 !! IF( iom_use('hflx_rain_cea') ) CALL iom_put( 'hflx_rain_cea', ( tprecip(:,:) - sprecip(:,:) ) * zcptn(:,:) ) ! heat flux from rain (cell average) 1605 !! IF( iom_use('hflx_snow_ao_cea') ) CALL iom_put( 'hflx_snow_ao_cea', sprecip(:,:) * ( zcptn(:,:) - Lfus ) * (1._wp - zsnw(:,:)) ) ! heat flux from snow (cell average) 1606 !! IF( iom_use('hflx_snow_ai_cea') ) CALL iom_put( 'hflx_snow_ai_cea', sprecip(:,:) * ( zcptn(:,:) - Lfus ) * zsnw(:,:) ) ! heat flux from snow (cell average) 1607 1601 1608 #else 1602 ! clem: this formulation is certainly wrong... but better than it was before...1609 ! clem: this formulation is certainly wrong... but better than it was... 1603 1610 zqns_tot(:,:) = zqns_tot(:,:) & ! zqns_tot update over free ocean with: 1604 1611 & - ztmp(:,:) & ! remove the latent heat flux of solid precip. melting 1605 1612 & - ( zemp_tot(:,:) & ! remove the heat content of mass flux (assumed to be at SST) 1606 & - zemp_ice(:,:) * zicefr(:,:)) * zcptn(:,:)1613 & - zemp_ice(:,:) ) * zcptn(:,:) 1607 1614 1608 1615 IF( ln_mixcpl ) THEN … … 1616 1623 qns_ice(:,:,:) = zqns_ice(:,:,:) 1617 1624 ENDIF 1618 !1619 1625 #endif 1626 1620 1627 ! ! ========================= ! 1621 1628 SELECT CASE( TRIM( sn_rcv_qsr%cldes ) ) ! solar heat fluxes ! (qsr) … … 1724 1731 1725 1732 CALL wrk_dealloc( jpi,jpj, zcptn, ztmp, zicefr, zmsk, zsnw ) 1726 CALL wrk_dealloc( jpi,jpj, zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap , zevap_ice, zdevap_ice )1733 CALL wrk_dealloc( jpi,jpj, zemp_tot, zemp_ice, zemp_oce, ztprecip, zsprecip, zevap_oce, zevap_ice, zdevap_ice ) 1727 1734 CALL wrk_dealloc( jpi,jpj, zqns_tot, zqns_oce, zqsr_tot, zqsr_oce, zqprec_ice, zqemp_oce, zqemp_ice ) 1728 1735 CALL wrk_dealloc( jpi,jpj,jpl, zqns_ice, zqsr_ice, zdqns_ice, zqevap_ice ) -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/ZDF/zdfric.F90
r7278 r7282 162 162 & + avmv(ji,jj,jk) + avmv(ji,jj-1,jk) ) & 163 163 & + avtb(jk) * tmask(ji,jj,jk) 164 ! ! Add the background coefficient on eddy viscosity 164 END DO 165 END DO 166 DO jj = 2, jpjm1 ! Add the background coefficient on eddy viscosity 167 DO ji = fs_2, fs_jpim1 165 168 avmu(ji,jj,jk) = avmu(ji,jj,jk) + avmb(jk) * umask(ji,jj,jk) 166 169 avmv(ji,jj,jk) = avmv(ji,jj,jk) + avmb(jk) * vmask(ji,jj,jk) -
branches/2016/dev_CNRS_2016/NEMOGCM/NEMO/OPA_SRC/timing.F90
- Property svn:executable deleted
Note: See TracChangeset
for help on using the changeset viewer.