Changeset 1112


Ignore:
Timestamp:
Nov 20, 2013, 10:26:12 AM (11 years ago)
Author:
aslmd
Message:

LMDZ.MARS. a few remaining ngridmx in comments. MESOSCALE. prep work for no-longer-fixed ngridmx. for mesoscale+newphys runs please use r1045 of LMDZ.MARS because more recent versions will require adaptations.

Location:
trunk/LMDZ.MARS/libf/phymars
Files:
10 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.MARS/libf/phymars/dimphys.h

    r1047 r1112  
    22!   INCLUDE 'dimphys.h'
    33
    4 ! ngridmx : number of horizontal grid points
    5 ! note: the -1/jjm term will be 0; unless jj=1
    6 !      integer, parameter :: ngridmx = (2+(jjm-1)*iim - 1/jjm)   
     4!!! -- no longer used. just kept for reference
     5!!! ngridmx : number of horizontal grid points
     6!!! note: the -1/jjm term will be 0; unless jj=1
     7!!!      integer, parameter :: ngridmx = (2+(jjm-1)*iim - 1/jjm)   
    78! nlayermx : number of atmospheric layers
    89      integer, parameter :: nlayermx = llm
  • trunk/LMDZ.MARS/libf/phymars/dimradmars_mod.F90

    r1047 r1112  
    77  ! Splitting of horizontal grid
    88  ! NDLO2 and ndomainsz for the splitting in the physics call
    9   ! WARNING:  One must have  1 < ndomainsz =< ngridmx
     9  ! WARNING:  One must have  1 < ndomainsz =< ngrid
    1010  integer,save :: NFLEV !=nlayermx   ! with splitting
    11   integer,save :: ndomainsz !=(ngridmx-1)/20 + 1
     11  integer,save :: ndomainsz !=(ngrid-1)/20 + 1
    1212  integer,save :: NDLON !=ndomainsz  ! with splitting
    1313  integer,save :: NDLO2 !=NDLON
  • trunk/LMDZ.MARS/libf/phymars/inifis.F

    r1106 r1112  
    4949      use tracer_mod, only : nqmx, nuice_sed, ccn_factor
    5050      use comsoil_h, only: ini_comsoil_h
    51 #ifdef MESOSCALE
    52       use comsoil_h, only: volcapa !!MESOSCALE -- needed to fill volcapa
    53 #endif     
    5451      use comgeomfi_h, only: long, lati, area, totarea
    5552      use comdiurn_h, only: sinlat, coslat, sinlon, coslon
     
    6259      use yomlw_h, only: ini_yomlw_h
    6360      use conc_mod, only: ini_conc_mod
     61
     62#ifdef MESOSCALE
     63      !! see meso_inc_inifisini.F
     64      use surfdat_h, only: emissiv,albedice,iceradius,
     65     &                     emisice,dtemisice,
     66     &                     z0_default,z0,
     67     &                     albedodat,phisfi,
     68     &                     zmea,zstd,zsig,zgam,zthe
     69      use slope_mod, only: theta_sl,psi_sl
     70      use comsoil_h, only: volcapa !!MESOSCALE -- needed to fill volcapa
     71#endif
     72
     73
    6474      IMPLICIT NONE
    6575#include "dimensions.h"
     
    8090! naerkind is set in scatterers.h (built when compiling with makegcm -s #)
    8191#include"scatterers.h"
     92
    8293#ifdef MESOSCALE
    83 !#include "comsoil.h"     !!MESOSCALE -- needed to fill volcapa
    8494#include "meso_inc/meso_inc_inifisvar.F"
    8595#endif
     
    115125      nqmx=nq
    116126
    117 #ifdef MESOSCALE
    118 #include "meso_inc/meso_inc_inifisini.F"
    119 #endif
    120 
    121127! --------------------------------------------------------
    122128!     The usual Tests
     
    127133!         PRINT*,'nlayer     = ',nlayer
    128134!         PRINT*,'nlayermx   = ',nlayermx
    129 !         STOP
    130 !      ENDIF
    131 
    132 !      IF (ngrid.NE.ngridmx) THEN
    133 !         PRINT*,'STOP in inifis'
    134 !         PRINT*,'Probleme de dimensions :'
    135 !         PRINT*,'ngrid     = ',ngrid
    136 !         PRINT*,'ngridmx   = ',ngridmx
    137135!         STOP
    138136!      ENDIF
     
    848846      ! allocate arrays in "conc_mod"
    849847      call ini_conc_mod(ngrid,nlayer)
    850      
     848   
     849!! MESOSCALE INITIALIZATIONS
     850#ifdef MESOSCALE
     851#include "meso_inc/meso_inc_inifisini.F"
     852#endif
     853 
    851854      END
  • trunk/LMDZ.MARS/libf/phymars/meso_inc/meso_dimphys.h_ref

    r226 r1112  
    22!   INCLUDE 'dimphys.h'
    33
    4 
    5          INTEGER, parameter :: wiim=--xsize--
    6          INTEGER, parameter :: wjjm=--ysize--
    7          INTEGER, PARAMETER :: ngridmx=--physize--
    84         INTEGER, parameter :: nlayermx=--zsize--
    9          INTEGER, PARAMETER :: nsoilmx=--soilsize--
    105       
    116!-----------------------------------------------------------------------
  • trunk/LMDZ.MARS/libf/phymars/meso_inc/meso_inc_caps.F

    r285 r1112  
    2424          !! Perennial H20 north cap defined by watercaptag=true (allows surface to be
    2525          !! hollowed by sublimation in vdifc).
    26           do ig=1,ngridmx
     26          do ig=1,ngrid
    2727            qsurf(ig,igcm_h2o_ice)=0.  !! on jette les inputs GCM
    2828            if ( ( lati(ig)*180./pi .gt. 70. ) .and.
     
    3434                    dryness(ig)      = 1.
    3535            endif  ! (lati, albedodat)
    36           end do ! (ngridmx)
     36          end do ! (ngrid)
    3737      ELSE  ! (caps)
    3838          print *,'Blork !!!'
  • trunk/LMDZ.MARS/libf/phymars/meso_inc/meso_inc_ini.F

    r1038 r1112  
    1414c
    1515      tsurf(:)=wtsurf(:)
    16       PRINT*,'check: tsurf ',tsurf(1),tsurf(ngridmx)
     16      PRINT*,'check: tsurf ',tsurf(1),tsurf(ngrid)
    1717      tsoil(:,:)=wtsoil(:,:)
    18       PRINT*,'check: tsoil ',tsoil(1,1),tsoil(ngridmx,nsoilmx)
     18      PRINT*,'check: tsoil ',tsoil(1,1),tsoil(ngrid,nsoilmx)
    1919c     !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    2020c     !!!new physics
     
    2323c      PRINT*, 'check z0 ', z0(1)
    2424      inertiedat(:,:)=wisoil(:,:)
    25       PRINT*,'check: inert ',inertiedat(1,1),inertiedat(ngridmx,nsoilmx)
     25      PRINT*,'check: inert ',inertiedat(1,1),inertiedat(ngrid,nsoilmx)
    2626      mlayer(0:nsoilmx-1)=wdsoil(1,:)
    2727      PRINT*,'check: midlayer ', mlayer(:)
     
    4646     !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
    4747      emis(:)=wemis(:)
    48       PRINT*,'check: emis ',emis(1),emis(ngridmx)
     48      PRINT*,'check: emis ',emis(1),emis(ngrid)
    4949      q2(:,:)=wq2(:,:)
    50       PRINT*,'check: q2 ',q2(1,1),q2(ngridmx,nlayermx+1)
     50      PRINT*,'check: q2 ',q2(1,1),q2(ngrid,nlayermx+1)
    5151      qsurf(:,:)=wqsurf(:,:)
    52       PRINT*,'check: qsurf ',qsurf(1,1),qsurf(ngridmx,nq)
     52      PRINT*,'check: qsurf ',qsurf(1,1),qsurf(ngrid,nq)
    5353      co2ice(:)=wco2ice(:)
    54       PRINT*,'check: co2 ',co2ice(1),co2ice(ngridmx)
     54      PRINT*,'check: co2 ',co2ice(1),co2ice(ngrid)
    5555      day_ini=wday_ini
    5656
     
    7979      !!!!
    8080      !IF ( caps .and. water ) THEN
    81       !    do ig=1,ngridmx
     81      !    do ig=1,ngrid
    8282      !      if ( lati(ig)*180./pi .gt. lat_lim ) then
    8383      !         if ( albedodat(ig) .ge. alb_lim ) then
     
    8989      !         endif
    9090      !      endif  ! (lati, albedodat)
    91       !    end do ! (ngridmx)
     91      !    end do ! (ngrid)
    9292      !ENDIF ! (caps)
  • trunk/LMDZ.MARS/libf/phymars/meso_inc/meso_inc_var.F

    r1038 r1112  
    11      INTEGER wday_ini
    2       REAL wtsurf(ngridmx)  ! input only ay firstcall - output
    3       REAL wtsoil(ngridmx,nsoilmx)
    4       REAL wisoil(ngridmx,nsoilmx)  !! new soil scheme
    5       REAL wdsoil(ngridmx,nsoilmx)   !! new soil scheme
    6       REAL wco2ice(ngridmx)
    7       REAL wemis(ngridmx)
    8       REAL wqsurf(ngridmx,nq)
    9       REAL wq2(ngridmx,nlayermx+1)
    10       REAL wwstar(ngridmx)
    11       REAL wfluxrad(ngridmx)
    12       REAL output_tab2d(ngridmx,n2d)
    13       REAL output_tab3d(ngridmx,nlayer,n3d)
    14       REAL sensheat(ngridmx)    !! pour LES avec isfflx!=0
    15       !REAL ustar(ngridmx)    !! pour LES avec isfflx!=0 !! already defined
     2      REAL wtsurf(ngrid)  ! input only ay firstcall - output
     3      REAL wtsoil(ngrid,nsoilmx)
     4      REAL wisoil(ngrid,nsoilmx)  !! new soil scheme
     5      REAL wdsoil(ngrid,nsoilmx)   !! new soil scheme
     6      REAL wco2ice(ngrid)
     7      REAL wemis(ngrid)
     8      REAL wqsurf(ngrid,nq)
     9      REAL wq2(ngrid,nlayermx+1)
     10      REAL wwstar(ngrid)
     11      REAL wfluxrad(ngrid)
     12      REAL output_tab2d(ngrid,n2d)
     13      REAL output_tab3d(ngrid,nlayer,n3d)
     14      REAL sensheat(ngrid)    !! pour LES avec isfflx!=0
     15      !REAL ustar(ngrid)    !! pour LES avec isfflx!=0 !! already defined
    1616      LOGICAL flag_LES     !! pour LES avec isfflx!=0
    17       REAL qsurfice(ngridmx) !! pour diagnostics
     17      REAL qsurfice(ngrid) !! pour diagnostics
    1818      real alpha,lay1 ! coefficients for building layers
    1919      integer iloop
     
    2222
    2323      !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! JF
    24       REAL qsurfdust(ngridmx)         ! useful for dust diagnostics
    25       REAL TAU_lay(ngridmx)           ! true opacity (it's not e reference life tauref)
    26       REAL dsodust(ngridmx,nlayermx)
    27       REAL zdqsdif_diag(ngridmx)      ! useful for lifting diagnostics                               
    28       REAL zdqssed_diag(ngridmx)      ! useful for sedimentation diagnostics                         
    29       REAL pdq_diag(ngridmx)          ! useful for dust perturbation diagnostics   
    30       REAL dustot(ngridmx)            ! Total mass of dust integrated along vertical axe (kg/m2)
    31       REAL zdqnorm(ngridmx,nlayermx,2)
     24      REAL qsurfdust(ngrid)         ! useful for dust diagnostics
     25      REAL TAU_lay(ngrid)           ! true opacity (it's not e reference life tauref)
     26      REAL dsodust(ngrid,nlayermx)
     27      REAL zdqsdif_diag(ngrid)      ! useful for lifting diagnostics                               
     28      REAL zdqssed_diag(ngrid)      ! useful for sedimentation diagnostics                         
     29      REAL pdq_diag(ngrid)          ! useful for dust perturbation diagnostics   
     30      REAL dustot(ngrid)            ! Total mass of dust integrated along vertical axe (kg/m2)
     31      REAL zdqnorm(ngrid,nlayermx,2)
    3232      !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! JF
  • trunk/LMDZ.MARS/libf/phymars/physiq.F

    r1047 r1112  
    2828      use slope_mod, only: theta_sl, psi_sl
    2929      use conc_mod, only: rnew, cpnew, mmean
     30
     31#ifdef MESOSCALE
     32      use comsoil_h, only: mlayer,layer
     33      use surfdat_h, only: z0_default
     34#endif
     35
    3036      IMPLICIT NONE
    3137c=======================================================================
  • trunk/LMDZ.MARS/libf/phymars/tabfi.F

    r1047 r1112  
    229229      write(*,*) 'Reading tab_cntrl when calling tabfi before changes'
    230230      write(*,*) '*****************************************************'
    231       write(*,5) '(1)      = ngridmx?',tab_cntrl(tab0+1)!,real(ngridmx)
     231      write(*,5) '(1)        = ngrid?',tab_cntrl(tab0+1)
    232232      write(*,5) '(2)            lmax',tab_cntrl(tab0+2),real(lmax)
    233233      write(*,5) '(3)         day_ini',tab_cntrl(tab0+3),real(day_ini)
     
    495495      write(*,*) 'Reading tab_cntrl when calling tabfi AFTER changes'
    496496      write(*,*) '*****************************************************'
    497       write(*,5) '(1)      = ngridmx?',tab_cntrl(tab0+1)!,real(ngridmx)
     497      write(*,5) '(1)        = ngrid?',tab_cntrl(tab0+1)
    498498      write(*,5) '(2)            lmax',tab_cntrl(tab0+2),real(lmax)
    499499      write(*,5) '(3)         day_ini',tab_cntrl(tab0+3),real(day_ini)
  • trunk/LMDZ.MARS/libf/phymars/testphys1d.F

    r1047 r1112  
    663663c  It is needed to transfert physics variables to "physiq"...
    664664
    665       call physdem0("startfi.nc",long,lati,nsoilmx,ngridmx,llm,nq,
     665      call physdem0("startfi.nc",long,lati,nsoilmx,ngrid,llm,nq,
    666666     .              dtphys,float(day0),time,area,
    667667     .              albedodat,inertiedat,zmea,zstd,zsig,zgam,zthe)
    668       call physdem1("startfi.nc",nsoilmx,ngridmx,llm,nq,
     668      call physdem1("startfi.nc",nsoilmx,ngrid,llm,nq,
    669669     .              dtphys,time,
    670670     .              tsurf,tsoil,co2ice,emis,q2,qsurf)
Note: See TracChangeset for help on using the changeset viewer.