Ignore:
Timestamp:
Apr 17, 2016, 10:23:21 PM (9 years ago)
Author:
emillour
Message:

Mars GCM:

  • fix for 1D in writediagfi to enable writing at "ecritphy" rate.
  • removed iniprint.h from phymars/dyn1d since it is in "misc"
  • Some code cleanup in anticipation of future updates:
    • changed variable names in comgeomphy.F90: give them more explicit names: rlond => longitude , rlatd => latitude, airephy => cell_area, cuphy => dx , cvphy => dy
    • removed long(), lati() and area() from comgeomfi_h.F90, use longitude(), latitude() and cell_are() from comgeomphy.F90 instead

EM

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/LMDZ.MARS/libf/phymars/comgeomfi_h.F90

    r1233 r1541  
    55
    66       ! These arrays are allocated in phys_state_var_init
    7        REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: long ! longitudes (rad)
    8        REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: lati ! latitudes (rad)
    9        REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: area ! mesh area (m2)
    10        REAL,SAVE :: totarea
     7!       REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: long ! longitudes (rad)
     8!       REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: lati ! latitudes (rad)
     9!       REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: area ! mesh area (m2)
     10!       REAL,SAVE :: totarea
    1111       REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: sinlon
    1212       REAL,ALLOCATABLE,SAVE,DIMENSION(:) :: coslon
     
    2121         integer,intent(in) :: ngrid ! number of atmospheric columns
    2222
    23          allocate(lati(ngrid))
    24          allocate(long(ngrid))
    25          allocate(area(ngrid))
     23!        allocate(lati(ngrid))
     24!         allocate(long(ngrid))
     25!         allocate(area(ngrid))
    2626         allocate(sinlat(ngrid))
    2727         allocate(coslat(ngrid))
     
    4141
    4242         ! fill "comgeomfi_h" data
    43          call SCOPY(ngrid,plon,1,long,1)
    44          call SCOPY(ngrid,plat,1,lati,1)
    45          call SCOPY(ngrid,parea,1,area,1)
    46          totarea=SSUM(ngrid,area,1)
     43!         call SCOPY(ngrid,plon,1,long,1)
     44!         call SCOPY(ngrid,plat,1,lati,1)
     45!         call SCOPY(ngrid,parea,1,area,1)
     46!         totarea=SSUM(ngrid,area,1)
    4747         DO ig=1,ngrid
    48             sinlat(ig)=sin(lati(ig))
    49             coslat(ig)=cos(lati(ig))
    50             sinlon(ig)=sin(long(ig))
    51             coslon(ig)=cos(long(ig))
     48            sinlat(ig)=sin(plat(ig))
     49            coslat(ig)=cos(plat(ig))
     50            sinlon(ig)=sin(plon(ig))
     51            coslon(ig)=cos(plon(ig))
    5252         ENDDO
    5353
Note: See TracChangeset for help on using the changeset viewer.