- Timestamp:
- Jan 11, 2017, 3:33:51 PM (8 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.TITAN/libf/dynphy_lonlat/phytitan/start2archive.F
r1644 r1647 25 25 ! use control_mod 26 26 ! use comgeomphy, only: initcomgeomphy 27 use slab_ice_h, only: noceanmx28 27 ! to use 'getin' 29 28 USE ioipsl_getincom … … 31 30 USE mod_const_mpi, ONLY: COMM_LMDZ 32 31 USE control_mod, only: planet_type 33 USE callkeys_mod, ONLY: ok_slab_ocean34 32 use filtreg_mod, only: inifilr 35 33 USE comvert_mod, ONLY: ap,bp … … 72 70 REAL tsurf(ngridmx) ! Surface temperature 73 71 REAL,ALLOCATABLE :: tsoil(:,:) ! Soil temperature 74 REAL co2ice(ngridmx) ! CO2 ice layer75 72 REAL q2(ngridmx,llm+1) 76 73 REAL,ALLOCATABLE :: qsurf(:,:) … … 82 79 INTEGER*4 day_ini_fi 83 80 84 ! added by FF for cloud fraction setup85 REAL hice(ngridmx)86 REAL cloudfrac(ngridmx,llm),totalcloudfrac(ngridmx)87 88 ! added by BC for slab ocean89 REAL rnat(ngridmx),pctsrf_sic(ngridmx),sea_ice(ngridmx)90 REAL tslab(ngridmx,noceanmx),tsea_ice(ngridmx)91 92 81 93 82 c Variable naturelle / grille scalaire … … 97 86 REAL,ALLOCATABLE :: tsoilS(:,:) 98 87 REAL,ALLOCATABLE :: ithS(:,:) ! Soil Thermal Inertia 99 REAL co2iceS(ip1jmp1)100 88 REAL q2S(ip1jmp1,llm+1) 101 89 REAL,ALLOCATABLE :: qsurfS(:,:) 102 90 REAL emisS(ip1jmp1) 103 104 ! added by FF for cloud fraction setup105 REAL hiceS(ip1jmp1)106 REAL cloudfracS(ip1jmp1,llm),totalcloudfracS(ip1jmp1)107 108 ! added by BC for slab ocean109 REAL rnatS(ip1jmp1),pctsrf_sicS(ip1jmp1),sea_iceS(ip1jmp1)110 REAL tslabS(ip1jmp1,noceanmx),tsea_iceS(ip1jmp1)111 91 112 92 … … 120 100 INTEGER Lmodif 121 101 122 REAL ptotal , co2icetotal102 REAL ptotal 123 103 REAL timedyn,timefi !fraction du jour dans start, startfi 124 104 REAL date … … 236 216 CALL phyetat0 (ngridmx,llm,fichnom,0,Lmodif,nsoilmx,nqtot, 237 217 . day_ini_fi,timefi, 238 . tsurf,tsoil,emis,q2,qsurf, 239 ! change FF 05/2011 240 . cloudfrac,totalcloudfrac,hice, 241 ! change BC 05/2014 242 . rnat,pctsrf_sic,tslab,tsea_ice,sea_ice) 243 218 . tsurf,tsoil,emis,q2,qsurf) 244 219 245 220 … … 328 303 c 329 304 c tsurf --> tsurfS 330 c co2ice --> co2iceS331 305 c tsoil --> tsoilS 332 306 c emis --> emisS … … 337 311 338 312 call gr_fi_dyn(1,ngridmx,iip1,jjp1,tsurf,tsurfS) 339 ! call gr_fi_dyn(1,ngridmx,iip1,jjp1,co2ice,co2iceS)340 313 call gr_fi_dyn(nsoilmx,ngridmx,iip1,jjp1,tsoil,tsoilS) 341 314 ! Note: thermal inertia "inertiedat" is in comsoil.h … … 344 317 call gr_fi_dyn(llm+1,ngridmx,iip1,jjp1,q2,q2S) 345 318 call gr_fi_dyn(nqtot,ngridmx,iip1,jjp1,qsurf,qsurfS) 346 call gr_fi_dyn(llm,ngridmx,iip1,jjp1,cloudfrac,cloudfracS)347 call gr_fi_dyn(1,ngridmx,iip1,jjp1,hice,hiceS)348 call gr_fi_dyn(1,ngridmx,iip1,jjp1,totalcloudfrac,totalcloudfracS)349 350 call gr_fi_dyn(1,ngridmx,iip1,jjp1,rnat,rnatS)351 call gr_fi_dyn(1,ngridmx,iip1,jjp1,pctsrf_sic,pctsrf_sicS)352 call gr_fi_dyn(1,ngridmx,iip1,jjp1,tsea_ice,tsea_iceS)353 call gr_fi_dyn(1,ngridmx,iip1,jjp1,sea_ice,sea_iceS)354 call gr_fi_dyn(noceanmx,ngridmx,iip1,jjp1,tslab,tslabS)355 319 356 320 c======================================================================= … … 359 323 360 324 ptotal = 0. 361 co2icetotal = 0.362 325 DO j=1,jjp1 363 326 DO i=1,iim 364 327 ptotal=ptotal+aire(i+(iim+1)*(j-1))*ps(i+(iim+1)*(j-1))/g 365 ! co2icetotal = co2icetotal +366 ! & co2iceS(i+(iim+1)*(j-1))*aire(i+(iim+1)*(j-1))367 328 ENDDO 368 329 ENDDO 369 330 write(*,*)'Ancienne grille : masse de l''atm :',ptotal 370 ! write(*,*)'Ancienne grille : masse de la glace CO2 :',co2icetotal 371 372 c----------------------------------------------------------------------- 373 c Passage de "ptotal" et "co2icetotal" par tab_cntrl_fi 331 332 c----------------------------------------------------------------------- 333 c Passage de "ptotal" par tab_cntrl_fi 374 334 c----------------------------------------------------------------------- 375 335 376 336 tab_cntrl_fi(49) = ptotal 377 tab_cntrl_fi(50) = co2icetotal337 tab_cntrl_fi(50) = 0. 378 338 379 339 c======================================================================= … … 430 390 431 391 c----------------------------------------------------------------------- 432 c Ecriture des champs ( co2ice,emis,ps,Tsurf,T,u,v,q2,q,qsurf)392 c Ecriture des champs (emis,ps,Tsurf,T,u,v,q2,q,qsurf) 433 393 c----------------------------------------------------------------------- 434 394 c ATTENTION: q2 a une couche de plus!!!! … … 439 399 c----------------------------------------------------------------------- 440 400 441 ! call write_archive(nid,ntime,'co2ice','couche de glace co2',442 ! & 'kg/m2',2,co2iceS)443 401 call write_archive(nid,ntime,'emis','grd emis',' ',2,emisS) 444 402 call write_archive(nid,ntime,'ps','Psurf','Pa',2,ps) … … 497 455 ! Note: no need to write volcapa, it is stored in "controle" table 498 456 499 c----------------------------------------------------------------------- 500 c Ecriture du champs cloudfrac,hice,totalcloudfrac 501 c----------------------------------------------------------------------- 502 call write_archive(nid,ntime,'hice', 503 & 'Height of oceanic ice','m',2,hiceS) 504 call write_archive(nid,ntime,'totalcloudfrac', 505 & 'Total cloud Fraction','',2,totalcloudfracS) 506 call write_archive(nid,ntime,'cloudfrac' 507 & ,'Cloud fraction','',3,cloudfracS) 508 509 c----------------------------------------------------------------------- 510 c Slab ocean 511 c----------------------------------------------------------------------- 512 OPEN(99,file='callphys.def',status='old',form='formatted' 513 & ,iostat=ierr) 514 CLOSE(99) 515 516 IF(ierr.EQ.0) THEN 517 518 519 write(*,*) "Use slab-ocean ?" 520 ok_slab_ocean=.false. ! default value 521 call getin("ok_slab_ocean",ok_slab_ocean) 522 write(*,*) "ok_slab_ocean = ",ok_slab_ocean 523 524 if(ok_slab_ocean) then 525 call write_archive(nid,ntime,'rnat' 526 & ,'rnat','',2,rnatS) 527 call write_archive(nid,ntime,'pctsrf_sic' 528 & ,'pctsrf_sic','',2,pctsrf_sicS) 529 call write_archive(nid,ntime,'sea_ice' 530 & ,'sea_ice','',2,sea_iceS) 531 call write_archive(nid,ntime,'tslab' 532 & ,'tslab','',-2,tslabS) 533 call write_archive(nid,ntime,'tsea_ice' 534 & ,'tsea_ice','',2,tsea_iceS) 535 endif !ok_slab_ocean 536 ENDIF 537 c----------------------------------------------------------------------- 457 538 458 c Fin 539 459 c-----------------------------------------------------------------------
Note: See TracChangeset
for help on using the changeset viewer.