Changeset 3628 for LMDZ6/branches
- Timestamp:
- Feb 4, 2020, 10:36:32 PM (5 years ago)
- Location:
- LMDZ6/branches/Ocean_skin/libf/phylmd
- Files:
-
- 10 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/branches/Ocean_skin/libf/phylmd/cpl_mod.F90
r3627 r3628 49 49 !$OMP THREADPRIVATE(cpl_snow,cpl_evap,cpl_tsol) 50 50 51 REAL, ALLOCATABLE, SAVE:: cpl_t_int(:) 52 !$OMP THREADPRIVATE(cpl_t_int )51 REAL, ALLOCATABLE, SAVE:: cpl_t_int(:), cpl_s_int(:) 52 !$OMP THREADPRIVATE(cpl_t_int, cpl_s_int) 53 53 54 54 REAL, ALLOCATABLE, DIMENSION(:,:), SAVE :: cpl_fder, cpl_albe, cpl_taux, cpl_tauy … … 94 94 !$OMP THREADPRIVATE(cpl_snow2D, cpl_evap2D, cpl_tsol2D) 95 95 96 REAL, ALLOCATABLE, SAVE:: cpl_t_int_2D(:,:) 97 !$OMP THREADPRIVATE(cpl_t_int_2D )96 REAL, ALLOCATABLE, SAVE:: cpl_t_int_2D(:,:), cpl_s_int_2D(:,:) 97 !$OMP THREADPRIVATE(cpl_t_int_2D, cpl_s_int_2D) 98 98 99 99 REAL, ALLOCATABLE, DIMENSION(:,:,:), SAVE :: cpl_fder2D, cpl_albe2D … … 237 237 238 238 if (activate_ocean_skin == 2) then 239 ALLOCATE(cpl_t_int(klon), stat = error)239 ALLOCATE(cpl_t_int(klon), cpl_s_int(klon), stat = error) 240 240 sum_error = sum_error + error 241 241 end if … … 645 645 swdown, lwdown, fluxlat, fluxsens, & 646 646 precip_rain, precip_snow, evap, tsurf, fder, albsol, taux, tauy, windsp,& 647 sens_prec_liq, sens_prec_sol, lat_prec_liq, lat_prec_sol, t_int )647 sens_prec_liq, sens_prec_sol, lat_prec_liq, lat_prec_sol, t_int, s_int) 648 648 649 649 ! This subroutine cumulates some fields for each time-step during … … 672 672 REAL, DIMENSION(klon), INTENT(IN) :: lat_prec_liq, lat_prec_sol 673 673 real, intent(in):: t_int(:) ! (klon) ocean-air interface temperature, in K 674 real, intent(in):: s_int(:) ! (knon) ocean-air interface salinity, in ppt 674 675 675 676 ! Local variables … … 707 708 cpl_taumod(1:knon,cpl_index) = 0.0 708 709 IF (carbon_cycle_cpl) cpl_atm_co2(1:knon,cpl_index) = 0.0 709 if (activate_ocean_skin == 2) cpl_t_int(:knon) = 0. 710 711 if (activate_ocean_skin == 2) then 712 cpl_t_int(:knon) = 0. 713 cpl_s_int = 0. 714 end if 710 715 ENDIF 711 716 … … 750 755 ENDIF 751 756 752 if (activate_ocean_skin == 2) & 753 cpl_t_int(ig) = cpl_t_int(ig) + t_int(ig) / REAL(nexca) 757 if (activate_ocean_skin == 2) then 758 cpl_t_int(ig) = cpl_t_int(ig) + t_int(ig) / REAL(nexca) 759 cpl_s_int(ig) = cpl_s_int(ig) + s_int(ig) / REAL(nexca) 760 end if 754 761 ENDDO 755 762 … … 799 806 800 807 if (activate_ocean_skin == 2) then 801 ALLOCATE(cpl_t_int_2D(nbp_lon, jj_nb), stat = error) 808 ALLOCATE(cpl_t_int_2D(nbp_lon, jj_nb), & 809 cpl_s_int_2D(nbp_lon, jj_nb), stat = error) 802 810 sum_error = sum_error + error 803 811 end if … … 857 865 IF (carbon_cycle_cpl) & 858 866 CALL gath2cpl(cpl_atm_co2(:,cpl_index), cpl_atm_co22D(:,:), knon, knindex) 859 if (activate_ocean_skin == 2) & 860 CALL gath2cpl(cpl_t_int, cpl_t_int_2D, knon, knindex) 867 if (activate_ocean_skin == 2) then 868 CALL gath2cpl(cpl_t_int, cpl_t_int_2D, knon, knindex) 869 CALL gath2cpl(cpl_s_int, cpl_s_int_2D, knon, knindex) 870 end if 861 871 ENDIF 862 872 … … 1252 1262 tab_flds(:,:,ids_qraiic) = cpl_sens_rain2D(:,:,2) 1253 1263 tab_flds(:,:,ids_qsnoic) = cpl_sens_snow2D(:,:,2) 1254 if (activate_ocean_skin == 2) tab_flds(:, :, ids_t_int) = cpl_t_int_2D 1264 1265 if (activate_ocean_skin == 2) then 1266 tab_flds(:, :, ids_t_int) = cpl_t_int_2D 1267 tab_flds(:, :, ids_s_int) = cpl_s_int_2D 1268 end if 1255 1269 1256 1270 IF (version_ocean=='nemo') THEN … … 1489 1503 ENDIF 1490 1504 1491 if (activate_ocean_skin == 2) deallocate(cpl_t_int_2d )1505 if (activate_ocean_skin == 2) deallocate(cpl_t_int_2d, cpl_s_int_2d) 1492 1506 1493 1507 IF (sum_error /= 0) THEN -
LMDZ6/branches/Ocean_skin/libf/phylmd/oasis.F90
r3627 r3628 59 59 INTEGER, PARAMETER :: ids_qraiic = 28 60 60 INTEGER, PARAMETER :: ids_qsnoic = 29 61 INTEGER, PARAMETER :: ids_t_int = 30 62 63 INTEGER, PARAMETER :: maxsend = 3 0! Maximum number of fields to send61 INTEGER, PARAMETER :: ids_t_int = 30, ids_s_int = 31 62 63 INTEGER, PARAMETER :: maxsend = 31 ! Maximum number of fields to send 64 64 65 65 ! Id for fields received from ocean … … 193 193 infosend(ids_t_int)%action = .TRUE. 194 194 infosend(ids_t_int)%name = 'T_int' 195 infosend(ids_s_int)%action = .TRUE. 196 infosend(ids_s_int)%name = 'S_int' 195 197 end if 196 198 -
LMDZ6/branches/Ocean_skin/libf/phylmd/ocean_cpl_mod.F90
r3627 r3628 55 55 radsol, snow, agesno, & 56 56 qsurf, evap, fluxsens, fluxlat, flux_u1, flux_v1, & 57 tsurf_new, dflux_s, dflux_l, sss )57 tsurf_new, dflux_s, dflux_l, sss, s_int) 58 58 59 59 ! … … 92 92 REAL, DIMENSION(klon), INTENT(IN) :: u1, v1, gustiness 93 93 REAL, DIMENSION(klon), INTENT(IN) :: tsurf_in 94 real, intent(in):: s_int(:) ! (knon) ocean-air interface salinity, in ppt 94 95 95 96 ! In/Output arguments … … 205 206 !**************************************************************************************** 206 207 207 CALL cpl_send_ocean_fields(itime, knon, knindex, & 208 swnet, lwnet, fluxlat, fluxsens, & 209 precip_rain, precip_snow, evap, tsurf_new, fder_new, alb1, flux_u1, flux_v1, windsp,& 210 sens_prec_liq, sens_prec_sol, lat_prec_liq, lat_prec_sol, tsurf_in) 211 208 CALL cpl_send_ocean_fields(itime, knon, knindex, swnet, lwnet, fluxlat, & 209 fluxsens, precip_rain, precip_snow, evap, tsurf_new, fder_new, alb1, & 210 flux_u1, flux_v1, windsp, sens_prec_liq, sens_prec_sol, lat_prec_liq, & 211 lat_prec_sol, tsurf_in, s_int) 212 212 213 213 END SUBROUTINE ocean_cpl_noice -
LMDZ6/branches/Ocean_skin/libf/phylmd/pbl_surface_mod.F90
r3626 r3628 292 292 USE print_control_mod, ONLY : prt_level,lunout 293 293 USE ioipsl_getin_p_mod, ONLY : getin_p 294 use phys_state_var_mod, only: ds_ns, dt_ns295 use phys_output_var_mod, only: t_int, s_int,dter, dser, tkt, tks, rf, taur294 use phys_state_var_mod, only: s_int, ds_ns, dt_ns 295 use phys_output_var_mod, only: t_int, dter, dser, tkt, tks, rf, taur 296 296 #ifdef CPP_XIOS 297 297 USE wxios, ONLY: missing_val … … 969 969 rh2m_x(:) = 0. ; qsat2m_x(:) = 0. ; rh2m_w(:) = 0. ; qsat2m_w(:) = 0. 970 970 971 if (activate_ocean_skin >= 1) then972 t_int = missing_val973 s_int = missing_val974 dter = missing_val975 dser = missing_val976 tkt = missing_val977 tks = missing_val978 rf = missing_val979 taur = missing_val980 end if981 982 971 ! 2b) Initialization of all local variables that will be compressed later 983 972 !**************************************************************************************** … … 1440 1429 1441 1430 if (nsrf == is_oce .and. activate_ocean_skin >= 1) then 1431 if (activate_ocean_skin == 2 .and. type_ocean == "couple") & 1432 ys_int(:knon) = s_int(ni(:knon)) 1442 1433 yds_ns(:knon) = ds_ns(ni(:knon)) 1443 1434 ydt_ns(:knon) = dt_ns(ni(:knon)) … … 2570 2561 2571 2562 if (nsrf == is_oce .and. activate_ocean_skin >= 1) then 2563 s_int = missing_val 2564 ds_ns = missing_val 2572 2565 dt_ns = missing_val 2573 ds_ns = missing_val 2566 t_int = missing_val 2567 dter = missing_val 2568 dser = missing_val 2569 tkt = missing_val 2570 tks = missing_val 2571 rf = missing_val 2572 taur = missing_val 2573 2574 s_int(ni(:knon)) = ys_int(:knon) 2574 2575 ds_ns(ni(:knon)) = yds_ns(:knon) 2575 2576 dt_ns(ni(:knon)) = ydt_ns(:knon) 2576 2577 2577 t_int(ni(:knon)) = yt_int(:knon) 2578 s_int(ni(:knon)) = ys_int(:knon)2579 2578 dter(ni(:knon)) = ydter(:knon) 2580 2579 dser(ni(:knon)) = ydser(:knon) … … 3195 3194 3196 3195 USE indice_sol_mod 3197 use phys_state_var_mod, only: ds_ns, dt_ns3196 use phys_state_var_mod, only: s_int, ds_ns, dt_ns 3198 3197 use config_ocean_skin_m, only: activate_ocean_skin 3199 3198 … … 3284 3283 ENDDO 3285 3284 if (activate_ocean_skin >= 1) then 3285 if (activate_ocean_skin == 2 & 3286 .and. type_ocean == "couple") s_int(i) = 35. 3286 3287 ds_ns(i) = 0. 3287 3288 dt_ns(i) = 0. -
LMDZ6/branches/Ocean_skin/libf/phylmd/phyetat0.F90
r3626 r3628 19 19 wake_s, wake_dens, zgam, zmax0, zmea, zpic, zsig, & 20 20 zstd, zthe, zval, ale_bl, ale_bl_trig, alp_bl, u10m, v10m, treedrg, & 21 ale_wake, ale_bl_stat, ds_ns, dt_ns21 ale_wake, ale_bl_stat, s_int, ds_ns, dt_ns 22 22 !FC 23 23 USE geometry_mod, ONLY : longitude_deg, latitude_deg … … 541 541 542 542 if (activate_ocean_skin >= 1) then 543 found = phyetat0_get(1, ds_ns, "ds_ns", "delta salinity near surface", 0.) 543 if (activate_ocean_skin == 2 .and. type_ocean == 'couple') found & 544 = phyetat0_get(1, s_int, "S_int", "salinity at air-ocean interface", & 545 35.) 546 found = phyetat0_get(1, ds_ns, "dS_ns", "delta salinity near surface", 0.) 544 547 found = phyetat0_get(1, dt_ns, "dT_ns", "delta temperature near surface", & 545 548 0.) 546 549 547 550 where (pctsrf(:, is_oce) == 0.) 551 s_int = missing_val 548 552 ds_ns = missing_val 549 553 dt_ns = missing_val -
LMDZ6/branches/Ocean_skin/libf/phylmd/phyredem.F90
r3605 r3628 27 27 ale_wake, ale_bl_stat, & 28 28 du_gwd_rando, du_gwd_front, u10m, v10m, & 29 treedrg, ds_ns, dt_ns29 treedrg, s_int, ds_ns, dt_ns 30 30 USE geometry_mod, ONLY : longitude_deg, latitude_deg 31 31 USE iostart, ONLY: open_restartphy, close_restartphy, enddef_restartphy, put_field, put_var … … 342 342 343 343 if (activate_ocean_skin >= 1) then 344 CALL put_field(pass, "ds_ns", "delta salinity near surface", ds_ns) 344 if (activate_ocean_skin == 2 .and. type_ocean == 'couple') & 345 CALL put_field(pass, "S_int", "salinity at air-ocean interface", & 346 s_int) 347 CALL put_field(pass, "dS_ns", "delta salinity near surface", ds_ns) 345 348 CALL put_field(pass, "dT_ns", "delta temperature near surface", dT_ns) 346 349 end if -
LMDZ6/branches/Ocean_skin/libf/phylmd/phys_output_var_mod.F90
r3601 r3628 136 136 137 137 REAL, ALLOCATABLE, SAVE:: t_int(:) ! interface temperature, in K 138 REAL, ALLOCATABLE, SAVE:: s_int(:) ! interface salinity, in ppt139 138 140 139 REAL, ALLOCATABLE, SAVE:: dter(:) … … 160 159 ! momentum flux due to rain, in Pa 161 160 162 !$OMP THREADPRIVATE(t_int, s_int,dter, dser, tkt, tks, rf, taur)161 !$OMP THREADPRIVATE(t_int, dter, dser, tkt, tks, rf, taur) 163 162 164 163 CONTAINS … … 221 220 IF (ok_gwd_rando) allocate(zustr_gwd_rando(klon), zvstr_gwd_rando(klon)) 222 221 223 if (activate_ocean_skin >= 1) allocate(t_int(klon), s_int(klon), &224 d ter(klon), dser(klon), tkt(klon), tks(klon), rf(klon), taur(klon))222 if (activate_ocean_skin >= 1) allocate(t_int(klon), dter(klon), & 223 dser(klon), tkt(klon), tks(klon), rf(klon), taur(klon)) 225 224 226 225 END SUBROUTINE phys_output_var_init -
LMDZ6/branches/Ocean_skin/libf/phylmd/phys_output_write_mod.F90
r3605 r3628 248 248 T2sumSTD, nlevSTD, du_gwd_rando, du_gwd_front, & 249 249 ulevSTD, vlevSTD, wlevSTD, philevSTD, qlevSTD, tlevSTD, & 250 rhlevSTD, O3STD, O3daySTD, uvSTD, vqSTD, vTSTD, wqSTD, &251 vphiSTD, wTSTD, u2STD, v2STD, T2STD, missing_val_nf90, ds_ns, dt_ns250 rhlevSTD, O3STD, O3daySTD, uvSTD, vqSTD, vTSTD, wqSTD, vphiSTD, & 251 wTSTD, u2STD, v2STD, T2STD, missing_val_nf90, s_int, ds_ns, dt_ns 252 252 253 253 USE phys_local_var_mod, ONLY: zxfluxlat, slp, ptstar, pt0, zxtsol, zt2m, & … … 360 360 alt_tropo, & 361 361 !Ionela 362 ok_4xCO2atm, t_int, s_int,dter, dser, tkt, tks, rf, taur362 ok_4xCO2atm, t_int, dter, dser, tkt, tks, rf, taur 363 363 364 364 USE ocean_slab_mod, ONLY: nslay, tslab, slab_bilg, tice, seaice, & -
LMDZ6/branches/Ocean_skin/libf/phylmd/phys_state_var_mod.F90
r3605 r3628 431 431 432 432 ! Ocean-atmosphere interface, subskin ocean and near-surface ocean: 433 434 REAL, ALLOCATABLE, SAVE:: s_int(:) ! interface salinity, in ppt 433 435 434 436 REAL, ALLOCATABLE, SAVE:: ds_ns(:) … … 442 444 ! minus foundation temperature. (Can be negative.) In K. 443 445 444 !$OMP THREADPRIVATE( ds_ns, dt_ns)446 !$OMP THREADPRIVATE(s_int, ds_ns, dt_ns) 445 447 446 448 CONTAINS … … 650 652 du_gwd_front(:,:) = 0 !ym missing init 651 653 ENDIF 652 if (activate_ocean_skin >= 1) ALLOCATE(ds_ns(klon), dt_ns(klon)) 654 if (activate_ocean_skin >= 1) ALLOCATE(s_int(klon), ds_ns(klon), & 655 dt_ns(klon)) 653 656 654 657 END SUBROUTINE phys_state_var_init … … 788 791 !!! fin nrlmd le 10/04/2012 789 792 790 if (activate_ocean_skin >= 1) deALLOCATE( ds_ns, dt_ns)793 if (activate_ocean_skin >= 1) deALLOCATE(s_int, ds_ns, dt_ns) 791 794 792 795 is_initialized=.FALSE. -
LMDZ6/branches/Ocean_skin/libf/phylmd/surf_ocean_mod.F90
r3627 r3628 77 77 REAL, DIMENSION(klon), INTENT(inOUT):: z0h 78 78 79 real, intent(inout):: s_int(:) ! (knon) ocean-air interface salinity, in ppt 80 79 81 REAL, intent(inout):: ds_ns(:) ! (knon) 80 82 ! "delta salinity near surface". Salinity variation in the … … 103 105 104 106 REAL, intent(out):: t_int(:) ! (knon) ocean-air interface temperature, in K 105 real, intent(out):: s_int(:) ! (knon) ocean-air interface salinity, in ppt106 107 107 108 REAL, intent(out):: dter(:) ! (knon) … … 190 191 radsol, snow, agesno, & 191 192 qsurf, evap, fluxsens, fluxlat, flux_u1, flux_v1, & 192 tsurf_new, dflux_s, dflux_l, sss )193 tsurf_new, dflux_s, dflux_l, sss, s_int) 193 194 194 195 CASE('slab')
Note: See TracChangeset
for help on using the changeset viewer.