Changeset 4171 for LMDZ6/branches/LMDZ-ECRAD/libf/phylmd/phyetat0.F90
- Timestamp:
- Jun 17, 2022, 4:24:49 PM (2 years ago)
- Location:
- LMDZ6/branches/LMDZ-ECRAD
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
LMDZ6/branches/LMDZ-ECRAD
- Property svn:mergeinfo changed
-
LMDZ6/branches/LMDZ-ECRAD/libf/phylmd/phyetat0.F90
r3756 r4171 13 13 du_gwd_rando, du_gwd_front, entr_therm, f0, fm_therm, & 14 14 falb_dir, falb_dif, prw_ancien, prlw_ancien, prsw_ancien, & 15 ftsol, pbl_tke, pctsrf, q_ancien, ql_ancien, qs_ancien, r adpas, radsol, rain_fall, ratqs, &15 ftsol, pbl_tke, pctsrf, q_ancien, ql_ancien, qs_ancien, rneb_ancien, radpas, radsol, rain_fall, ratqs, & 16 16 rnebcon, rugoro, sig1, snow_fall, solaire_etat0, sollw, sollwdown, & 17 17 solsw, solswfdiff, t_ancien, u_ancien, v_ancien, w01, wake_cstar, wake_deltaq, & 18 wake_deltat, wake_delta_pbl_TKE, delta_tsurf, wake_fip, wake_pe, &19 wake_s, wake_dens, zgam, zmax0, zmea, zpic, zsig, &18 wake_deltat, wake_delta_pbl_TKE, delta_tsurf, beta_aridity, wake_fip, wake_pe, & 19 wake_s, wake_dens, awake_dens, cv_gen, 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 21 ale_wake, ale_bl_stat, ds_ns, dt_ns, delta_sst, delta_sal, ratqs_inter 22 22 !FC 23 USE geometry_mod, ONLY: longitude_deg, latitude_deg24 USE iostart, ONLY: close_startphy, get_field, get_var, open_startphy25 USE infotrac_phy, only: nbtr, nqo, type_trac, tname, niadv26 USE traclmdz_mod, ONLY: traclmdz_from_restart27 USE carbon_cycle_mod, ONLY 28 USE indice_sol_mod, only: nbsrf, is_ter, epsfra, is_lic, is_oce, is_sic29 USE ocean_slab_mod, ONLY: nslay, tslab, seaice, tice, ocean_slab_init23 USE geometry_mod, ONLY: longitude_deg, latitude_deg 24 USE iostart, ONLY: close_startphy, get_field, get_var, open_startphy 25 USE infotrac_phy, ONLY: nqtot, nbtr, types_trac, tracers 26 USE traclmdz_mod, ONLY: traclmdz_from_restart 27 USE carbon_cycle_mod, ONLY: carbon_cycle_tr, carbon_cycle_cpl, co2_send 28 USE indice_sol_mod, ONLY: nbsrf, is_ter, epsfra, is_lic, is_oce, is_sic 29 USE ocean_slab_mod, ONLY: nslay, tslab, seaice, tice, ocean_slab_init 30 30 USE time_phylmdz_mod, ONLY: init_iteration, pdtphys, itau_phy 31 #ifdef CPP_XIOS 32 USE wxios, ONLY: missing_val 33 #else 34 use netcdf, only: missing_val => nf90_fill_real 35 #endif 36 use config_ocean_skin_m, only: activate_ocean_skin 31 37 32 38 IMPLICIT none … … 35 41 ! Objet: Lecture de l'etat initial pour la physique 36 42 !====================================================================== 37 include "netcdf.inc"38 43 include "dimsoil.h" 39 44 include "clesphys.h" 40 include " thermcell.h"45 include "alpale.h" 41 46 include "compbl.h" 42 47 include "YOMCST.h" … … 70 75 INTEGER length 71 76 PARAMETER (length=100) 72 INTEGER it, i iq, isw77 INTEGER it, iq, isw 73 78 REAL tab_cntrl(length), tabcntr0(length) 74 79 CHARACTER*7 str7 … … 356 361 ancien_ok=ancien_ok.AND.phyetat0_get(klev,ql_ancien,"QLANCIEN","QLANCIEN",0.) 357 362 ancien_ok=ancien_ok.AND.phyetat0_get(klev,qs_ancien,"QSANCIEN","QSANCIEN",0.) 363 ancien_ok=ancien_ok.AND.phyetat0_get(klev,rneb_ancien,"RNEBANCIEN","RNEBANCIEN",0.) 358 364 ancien_ok=ancien_ok.AND.phyetat0_get(klev,u_ancien,"UANCIEN","UANCIEN",0.) 359 365 ancien_ok=ancien_ok.AND.phyetat0_get(klev,v_ancien,"VANCIEN","VANCIEN",0.) … … 368 374 (maxval(ql_ancien).EQ.minval(ql_ancien)) .OR. & 369 375 (maxval(qs_ancien).EQ.minval(qs_ancien)) .OR. & 376 (maxval(rneb_ancien).EQ.minval(rneb_ancien)) .OR. & 370 377 (maxval(prw_ancien).EQ.minval(prw_ancien)) .OR. & 371 378 (maxval(prlw_ancien).EQ.minval(prlw_ancien)) .OR. & … … 391 398 IF (iflag_pbl>1 .AND. iflag_wake>=1 .AND. iflag_pbl_split >=1 ) then 392 399 found=phyetat0_srf(klev+1,wake_delta_pbl_tke,"DELTATKE","Del TKE wk/env",0.) 393 found=phyetat0_srf(1,delta_tsurf,"DELTA_TSURF","Delta Ts wk/env ",0.) 400 !! found=phyetat0_srf(1,delta_tsurf,"DELTA_TSURF","Delta Ts wk/env ",0.) 401 found=phyetat0_srf(1,delta_tsurf,"DELTATS","Delta Ts wk/env ",0.) 402 !! found=phyetat0_srf(1,beta_aridity,"BETA_S","Aridity factor ",1.) 403 found=phyetat0_srf(1,beta_aridity,"BETAS","Aridity factor ",1.) 394 404 ENDIF !(iflag_pbl>1 .AND. iflag_wake>=1 .AND. iflag_pbl_split >=1 ) 395 405 … … 411 421 !! found=phyetat0_get(1,wake_dens,"WAKE_DENS","Wake num. /unit area",0.) 412 422 found=phyetat0_get(1,wake_dens,"WAKE_DENS","Wake num. /unit area",-1000.) 423 found=phyetat0_get(1,awake_dens,"AWAKE_DENS","Active Wake num. /unit area",0.) 424 found=phyetat0_get(1,cv_gen,"CV_GEN","CB birth rate",0.) 413 425 !>jyg 414 426 found=phyetat0_get(1,wake_cstar,"WAKE_CSTAR","WAKE_CSTAR",0.) … … 430 442 found=phyetat0_get(1,ale_bl_stat,"ALE_BL_STAT","ALE_BL_STAT",0.) 431 443 444 ! fisrtilp/Clouds 0.002 could be ratqsbas. But can stay like this as well 445 found=phyetat0_get(klev,ratqs_inter,"RATQS_INTER","Relative width of the lsc sugrid scale water",0.002) 446 432 447 !=========================================== 433 448 ! Read and send field trs to traclmdz 434 449 !=========================================== 435 450 436 IF (type_trac == 'lmdz') THEN 437 DO it=1, nbtr 438 !! iiq=niadv(it+2) ! jyg 439 iiq=niadv(it+nqo) ! jyg 440 found=phyetat0_get(1,trs(:,it),"trs_"//tname(iiq), & 441 "Surf trac"//tname(iiq),0.) 442 ENDDO 443 CALL traclmdz_from_restart(trs) 444 ENDIF 445 446 !--OB now this is for co2i 447 IF (type_trac == 'co2i') THEN 451 !--OB now this is for co2i - ThL: and therefore also for inco 452 IF (ANY(types_trac == 'co2i') .OR. ANY(types_trac == 'inco')) THEN 448 453 IF (carbon_cycle_cpl) THEN 449 454 ALLOCATE(co2_send(klon), stat=ierr) … … 451 456 found=phyetat0_get(1,co2_send,"co2_send","co2 send",co2_ppm) 452 457 ENDIF 453 ENDIF 458 ELSE IF (ANY(types_trac == 'lmdz')) THEN 459 it = 0 460 DO iq = 1, nqtot 461 IF(.NOT.(tracers(iq)%isAdvected .AND. tracers(iq)%isInPhysics)) CYCLE 462 it = it+1 463 found=phyetat0_get(1,trs(:,it),"trs_"//TRIM(tracers(iq)%name), & 464 "Surf trac"//TRIM(tracers(iq)%name),0.) 465 END DO 466 CALL traclmdz_from_restart(trs) 467 ENDIF 468 454 469 455 470 !=========================================== … … 519 534 ENDIF ! Slab 520 535 536 if (activate_ocean_skin >= 1) then 537 if (activate_ocean_skin == 2 .and. type_ocean == 'couple') then 538 found = phyetat0_get(1, delta_sal, "delta_sal", & 539 "ocean-air interface salinity minus bulk salinity", 0.) 540 found = phyetat0_get(1, delta_sst, "delta_SST", & 541 "ocean-air interface temperature minus bulk SST", 0.) 542 end if 543 544 found = phyetat0_get(1, ds_ns, "dS_ns", "delta salinity near surface", 0.) 545 found = phyetat0_get(1, dt_ns, "dT_ns", "delta temperature near surface", & 546 0.) 547 548 where (pctsrf(:, is_oce) == 0.) 549 ds_ns = missing_val 550 dt_ns = missing_val 551 delta_sst = missing_val 552 delta_sal = missing_val 553 end where 554 end if 555 521 556 ! on ferme le fichier 522 557 CALL close_startphy … … 566 601 CALL get_field(name, field, found) 567 602 IF (.NOT. found) THEN 568 WRITE(lunout,*) "phyetat0: Le champ <", name,"> est absent"603 WRITE(lunout,*) "phyetat0: Le champ <",TRIM(name),"> est absent" 569 604 WRITE(lunout,*) "Depart legerement fausse. Mais je continue" 570 605 field(:,:)=default
Note: See TracChangeset
for help on using the changeset viewer.