Ignore:
Timestamp:
Feb 23, 2010, 10:29:54 PM (15 years ago)
Author:
Laurent Fairhead
Message:
  • Modifications to the start and limit creation routines to account for different

calendars

  • Modification to phyetat0 to force the mask read in the start files to match the

surface fractions read in the limit file

  • Force readaerosol.F90 to read in aerosols file with 12 timesteps

  • Modifications aux routines de créations des fichiers start et limit pour prendre

en compte différents calendriers

  • Modification à phyetat0 pour forcer le masque lu dans le fichier start à être

compatible avec les fractions de surface lu dans le fichier limit

  • Forcer readaerosol à ne lire que des fichiers à 12 pas de temps
File:
1 moved

Legend:

Unmodified
Added
Removed
  • LMDZ4/trunk/libf/dyn3d/ce0l.F90

    r1318 r1319  
    22! $Id$
    33!
    4        PROGRAM create_etat0_limit
     4!-------------------------------------------------------------------------------
     5!
     6PROGRAM ce0l
     7!
     8!-------------------------------------------------------------------------------
     9! Purpose: Calls etat0, creates initial states and limit_netcdf
     10!
     11!     interbar=.T. for barycentric interpolation inter_barxy
     12!     extrap  =.T. for data extrapolation, like for the SSTs when file does not
     13!                  contain ocean points only.
     14!     oldice  =.T. for old-style ice, obtained using grille_m (grid_atob).
     15!     masque is created in etat0, passed to limit to ensure consistancy.
     16!-------------------------------------------------------------------------------
    517#ifdef CPP_EARTH
    618! This prog. is designed to work for Earth
    7        USE dimphy
    8        USE comgeomphy
    9        USE infotrac
     19  USE dimphy
     20  USE comgeomphy
     21  USE infotrac
     22
    1023#ifdef CPP_IOIPSL
    11        use ioipsl, only: ioconf_calendar
     24  USE ioipsl, ONLY: ioconf_calendar
    1225#endif
    13        IMPLICIT NONE
    14 c
    15 c
    16 c     Programme d'appel a etat0, creation des etats initiaux et limit_netcdf
    17 c   
    18 c
    19 c     interbar = .T . si appel a  interpol. barycentrique inter_barxy
    20 c
    21 c     extrap   = .T . si on fait une extrapolation de donnees , comme pour
    22 c       les  SST  lorsque  le fichier ne contient pas uniquement  des points
    23 c     oceaniques .
    24 c
    25 c     oldice   = .T. si l'on veut garder les anciennes glaces , obtenues
    26 c     par  grille_m  ( grid_atob ) .
    27 c
    28 c     on cree le masque dans etat0 que l'on passe ensuite dans limit pour
    29 c     garder les coherences
    3026
    31       LOGICAL interbar, extrap , oldice
    32       PARAMETER ( interbar = .true. , extrap = .FALSE. , oldice=.false.)
     27#endif
     28  IMPLICIT NONE
     29#ifndef CPP_EARTH
     30  WRITE(lunout,*)'limit_netcdf: Earth-specific routine, needs Earth physics'
     31#else
     32!-------------------------------------------------------------------------------
     33! Local variables:
     34  LOGICAL, PARAMETER :: interbar=.TRUE., extrap=.FALSE., oldice=.FALSE.
    3335#include "dimensions.h"
    3436#include "paramet.h"
    3537#include "indicesol.h"
    36 #include  "control.h"
    37       REAL :: masque(iip1,jjp1)
    38 !      REAL :: pctsrf(iim*(jjm-1)+2, nbsrf)
     38#include "iniprint.h"
     39#include "control.h"
     40#include "temps.h"
     41#include "logic.h"
     42  INTEGER, PARAMETER            :: longcles=20
     43  REAL,    DIMENSION(longcles)  :: clesphy0
     44  REAL,    DIMENSION(iip1,jjp1) :: masque
     45  CHARACTER(LEN=15)             :: calnd
     46!-------------------------------------------------------------------------------
     47  CALL conf_gcm( 99, .TRUE. , clesphy0 )
    3948
    40       IF (config_inca /= 'none') THEN
    41 #ifdef INCA
    42          call init_const_lmdz(
    43      $        nbtr,anneeref,dayref,
    44      $        iphysiq, day_step,nday)
    45 #endif
    46          print *, 'nbtr =' , nbtr
    47       END IF
    48 
    49       CALL Init_Phys_lmdz(iim,jjp1,llm,1,(/(jjm-1)*iim+2/))
    50       PRINT *,'---> klon=',klon
    51       call InitComgeomphy
     49  CALL Init_Phys_lmdz(iim,jjp1,llm,1,(/(jjm-1)*iim+2/))
     50  WRITE(lunout,*)'---> klon=',klon
     51  CALL InitComgeomphy
    5252
    5353#ifdef CPP_IOIPSL
    54       call ioconf_calendar('360d')
     54  SELECT CASE(calend)
     55    CASE('earth_360d');CALL ioconf_calendar('360d');      calnd='a 360 jours/an'
     56    CASE('earth_365d');CALL ioconf_calendar('noleap');    calnd='a 365 jours/an'
     57    CASE('earth_366d');CALL ioconf_calendar('366d');      calnd='bissextile'
     58    CASE('gregorian'); CALL ioconf_calendar('gregorian'); calnd='gregorien'
     59    CASE('standard');  CALL ioconf_calendar('gregorian'); calnd='gregorien'
     60    CASE('julian');    CALL ioconf_calendar('julian');    calnd='julien'
     61    CASE('proleptic_gregorian'); CALL ioconf_calendar('gregorian')
     62  !--- DC Bof...  => IOIPSL a mettre a jour: proleptic_gregorian /= gregorian
     63    CASE DEFAULT
     64      CALL abort_gcm('ce0l','Mauvais choix de calendrier',1)
     65  END SELECT
     66  WRITE(lunout,*)'CALENDRIER CHOISI: Terrestre '//TRIM(calnd)
    5567#endif
    5668
    57       WRITE(6,*) '  *********************  '
    58       WRITE(6,*) ' interbar = ',interbar
    59       CALL etat0_netcdf ( interbar, masque )
    60 c
    61       WRITE(6,1)
    62       WRITE(6,*) '  *********************  '
    63       WRITE(6,*) '  ***  Limit_netcdf ***  '
    64       WRITE(6,*) '  *********************  '
    65       WRITE(6,1)
    66      
    67 c     
    68       CALL  limit_netcdf ( interbar, extrap , oldice, masque)
     69  IF (config_inca /= 'none') THEN
     70#ifdef INCA
     71    CALL init_const_lmdz(nbtr,anneeref,dayref,iphysiq,day_step,nday)
     72    CALL init_inca_para(iim,jjm+1,klon,1,klon_mpi_para_nb,0)
     73    WRITE(lunout,*)'nbtr =' , nbtr
     74#endif
     75  END IF
    6976
    70 1     FORMAT(//)
     77  WRITE(lunout,'(//)')
     78  WRITE(lunout,*) '  *********************  '
     79  WRITE(lunout,*) '  ***  etat0_netcdf ***  '
     80  WRITE(lunout,*) '  *********************  '
     81  WRITE(lunout,'(//)')
     82  WRITE(lunout,*) ' interbar = ',interbar
     83  CALL etat0_netcdf(interbar,masque,ok_etat0)
     84
     85  IF(ok_limit) THEN
     86  WRITE(lunout,'(//)')
     87  WRITE(lunout,*) '  *********************  '
     88  WRITE(lunout,*) '  ***  Limit_netcdf ***  '
     89  WRITE(lunout,*) '  *********************  '
     90  WRITE(lunout,'(//)')
     91  CALL limit_netcdf(interbar,extrap,oldice,masque)
     92  END IF
    7193
    7294#endif
    73 ! of #ifdef CPP_EARTH
    74       STOP
    75       END
     95! of #ifndef CPP_EARTH #else
     96  STOP
     97
     98END PROGRAM ce0l
     99!
     100!-------------------------------------------------------------------------------
Note: See TracChangeset for help on using the changeset viewer.