Ignore:
Timestamp:
Jan 25, 2011, 4:18:50 PM (15 years ago)
Author:
aslmd
Message:

LMD_MM_MARS: ancienne et nouvelle physique sur le mm coeur dynamique

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/mesoscale/LMD_MM_MARS/SRC/WRFV2/phys/module_lmd_driver.F

    r11 r28  
    1010!           - general cleaning of code and comments - October 2008
    1111!           - additions for idealized cases - January 2009
     12!           - additions for new soil model in physics - January 2010
    1213!*******************************************************************************
    1314MODULE module_lmd_driver
     
    2930        MARS_ALB,MARS_TI,MARS_CICE,MARS_EMISS, &
    3031        MARS_TSOIL, &
     32#ifdef NEWPHYS
     33        MARS_ISOIL, &
     34        MARS_DSOIL, &
     35#endif
    3136        MARS_GW, &
    3237        NUM_SOIL_LAYERS, &
     
    105110!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    106111REAL, DIMENSION( ims:ime, NUM_SOIL_LAYERS, jms:jme ), INTENT(IN   )  :: &
    107      MARS_TSOIL         
     112     MARS_TSOIL
     113#ifdef NEWPHYS
     114REAL, DIMENSION( ims:ime, NUM_SOIL_LAYERS, jms:jme ), INTENT(IN   )  :: &
     115     MARS_ISOIL, MARS_DSOIL         
     116#endif
    108117REAL, DIMENSION( ims:ime, 5, jms:jme ), INTENT(IN   )  :: &
    109118     MARS_GW
     
    147156   LOGICAL :: firstcall,lastcall,tracerdyn
    148157   REAL,DIMENSION(:),ALLOCATABLE :: q2_val, qsurf_val, tsoil_val
     158#ifdef NEWPHYS
     159   REAL,DIMENSION(:),ALLOCATABLE :: isoil_val, dsoil_val
     160#endif
    149161   REAL,DIMENSION(:),ALLOCATABLE :: aire_vec,lat_vec,lon_vec
    150162   REAL,DIMENSION(:),ALLOCATABLE :: walbedodat,winertiedat,wphisfi
     
    153165   ! v--- can they be modified ?
    154166   REAL,DIMENSION(:),ALLOCATABLE :: wtsurf,wco2ice,wemis
    155    REAL,DIMENSION(:,:),ALLOCATABLE :: wq2,wqsurf,wtsoil
     167   REAL,DIMENSION(:,:),ALLOCATABLE :: wq2,wqsurf,wtsoil
     168#ifdef NEWPHYS
     169   REAL,DIMENSION(:,:),ALLOCATABLE :: wisoil,wdsoil
     170#endif
    156171   ! ----------
    157172   REAL,DIMENSION(:,:),ALLOCATABLE :: pplev,pplay,pphi,pu,pv,pt,pw
     
    451466ALLOCATE(qsurf_val(nq))
    452467ALLOCATE(tsoil_val(nsoil))
     468#ifdef NEWPHYS
     469ALLOCATE(isoil_val(nsoil))
     470ALLOCATE(dsoil_val(nsoil))
     471#endif
    453472ALLOCATE(wq2(ngrid,nlayer+1))
    454473ALLOCATE(wqsurf(ngrid,nq))
    455474ALLOCATE(wtsoil(ngrid,nsoil))
     475#ifdef NEWPHYS
     476ALLOCATE(wisoil(ngrid,nsoil))
     477ALLOCATE(wdsoil(ngrid,nsoil))
     478#endif
    456479ALLOCATE(pplev(ngrid,nlayer+1))
    457480ALLOCATE(pplay(ngrid,nlayer))
     
    594617tsoil_val = tsoil_val*0. + tsurf_val
    595618ENDIF
     619#ifdef NEWPHYS
     620isoil_val(:)=MARS_ISOIL(i,:,j)
     621dsoil_val(:)=MARS_DSOIL(i,:,j)
     622#endif
    596623
    597624!-------------------!
     
    630657 PRINT *,'v_prof ',v_prof
    631658 PRINT *,'tsoil ',tsoil_val
     659#ifdef NEWPHYS
     660 PRINT *,'isoil ',isoil_val
     661 PRINT *,'dsoil ',dsoil_val
     662#endif
    632663ENDIF
    633664
     
    660691wqsurf(subs,:) = qsurf_val(:)
    661692wtsoil(subs,:) = tsoil_val(:)
     693#ifdef NEWPHYS
     694wisoil(subs,:) = isoil_val(:)
     695wdsoil(subs,:) = dsoil_val(:)
     696#endif
    662697wtheta(subs) = theta_val
    663698wpsi(subs) = psi_val
     
    680715pplev(subs,1:nlayer) = p8w_prof(1:nlayer)  !! NB: last level: no data
    681716pplay(subs,:) = p_prof(:)
    682 pt(subs,:) = t_prof(:)  ! temperature
     717pt(subs,:) = t_prof(:)
    683718pu(subs,:) = u_prof(:)
    684719pv(subs,:) = v_prof(:)
     
    711746DEALLOCATE(qsurf_val)
    712747DEALLOCATE(tsoil_val)
     748#ifdef NEWPHYS
     749DEALLOCATE(isoil_val)
     750DEALLOCATE(dsoil_val)
     751#endif
    713752DEALLOCATE(dz8w_prof)
    714753DEALLOCATE(z_prof)
     
    738777IF (firstcall .EQV. .true.) THEN
    739778print *, '** Mars ** LMD INITIALIZATION'
    740 include "../call_meso_inifis.inc"
     779#include "../call_meso_inifis.inc"
     780!!! le # est important pour newphys
    741781DEALLOCATE(aire_vec)
    742782DEALLOCATE(lat_vec)
     
    777817pdt(:,:)=0.
    778818pdq(:,:,:)=0.
    779 include "../call_meso_physiq.inc"
     819#include "../call_meso_physiq.inc"
     820!!! le # est important pour newphys
    780821DEALLOCATE(pplev)
    781822DEALLOCATE(pplay)
     
    792833DEALLOCATE(wqsurf)
    793834DEALLOCATE(wtsoil)
     835#ifdef NEWPHYS
     836DEALLOCATE(wisoil)
     837DEALLOCATE(wdsoil)
     838#endif
    794839
    795840
Note: See TracChangeset for help on using the changeset viewer.