Changeset 2826 for trunk/LMDZ.MARS/libf/phymars/phyetat0_mod.F90
- Timestamp:
- Nov 23, 2022, 11:11:26 AM (2 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LMDZ.MARS/libf/phymars/phyetat0_mod.F90
r2740 r2826 9 9 10 10 subroutine phyetat0 (fichnom,tab0,Lmodif,nsoil,ngrid,nlay,nq, & 11 day_ini,time0,tsurf,tsoil,albedo,emis,q2,qsurf, co2ice,&11 day_ini,time0,tsurf,tsoil,albedo,emis,q2,qsurf, & 12 12 tauscaling,totcloudfrac,wstar,watercap) 13 13 … … 63 63 real,intent(out) :: q2(ngrid,nlay+1) ! 64 64 real,intent(out) :: qsurf(ngrid,nq) ! tracers on surface 65 real,intent(out) :: co2ice(ngrid) ! co2 ice cover66 65 real,intent(out) :: tauscaling(ngrid) ! dust conversion factor 67 66 real,intent(out) :: totcloudfrac(ngrid) ! total cloud fraction … … 348 347 endif ! if (startphy_file) 349 348 350 ! CO2 ice cover351 if (startphy_file) then352 call get_field("co2ice",co2ice,found,indextime)353 if (.not.found) then354 call abort_physic(modname, &355 "phyetat0: Failed loading <co2ice>",1)356 endif357 else358 co2ice(:)=0.359 endif !if (startphy_file)360 write(*,*) "phyetat0: CO2 ice cover <co2ice> range:", &361 minval(co2ice), maxval(co2ice)362 363 349 ! Dust conversion factor 364 350 if (startphy_file) then … … 561 547 562 548 if (startphy_file) then 563 call get_field(txt,qsurf(:,iq),found,indextime) 564 if (.not.found) then 565 write(*,*) "phyetat0: Failed loading <",trim(txt),">" 566 write(*,*) " ",trim(txt)," is set to zero" 567 qsurf(:,iq)=0. 568 endif 569 else 549 if (txt.eq."co2") then 550 ! We first check if co2ice exist in the startfi file (old way) 551 ! CO2 ice cover 552 call get_field("co2ice",qsurf(:,iq),found,indextime) 553 ! If not, we load the corresponding tracer in qsurf 554 if (.not.found) then 555 call get_field(txt,qsurf(:,iq),found,indextime) 556 if (.not.found) then 557 call abort_physic(modname, & 558 "phyetat0: Failed loading co2ice. there is neither the variable co2ice nor qsurf",1) 559 endif 560 endif 561 else ! (not the co2 tracer) 562 call get_field(txt,qsurf(:,iq),found,indextime) 563 if (.not.found) then 564 write(*,*) "phyetat0: Failed loading <",trim(txt),">" 565 write(*,*) " ",trim(txt)," is set to zero" 566 qsurf(:,iq)=0. 567 endif 568 endif !endif co2 569 else !(not startphy_file) 570 570 qsurf(:,iq)=0. 571 571 endif ! of if (startphy_file) … … 573 573 minval(qsurf(:,iq)), maxval(qsurf(:,iq)) 574 574 enddo ! of do iq=1,nq 575 576 if (txt.eq."co2") then 577 ! We first check if co2ice exist in the startfi file (old way) 578 ! CO2 ice cover 579 if (startphy_file) then 580 call get_field("co2ice",qsurf(:,iq),found,indextime) 581 ! If not, we load the corresponding tracer in qsurf 582 if (.not.found) then 583 call get_field(txt,qsurf(:,iq),found,indextime) 584 if (.not.found) then 585 call abort_physic(modname, & 586 "phyetat0: Failed loading co2ice",1) 587 endif 588 endif 589 else 590 ! If we run without startfile, co2ice is set to 0 591 qsurf(:,iq)=0. 592 endif !if (startphy_file) 593 write(*,*) "phyetat0: CO2 ice cover <co2ice> range:", & 594 minval(qsurf(:,iq)), maxval(qsurf(:,iq)) 595 endif 596 575 597 endif ! of if (nq.ge.1) 576 598
Note: See TracChangeset
for help on using the changeset viewer.