include file: COASIS 11
CLL   Comdeck COASIS : -----------------------------------------------     COASIS.2      
CLL                                                                        COASIS.3      
CLL   Common declarations and variables of the routines of the oasis       COASIS.4      
CLL   module.                                                              COASIS.5      
CLL                                                                        COASIS.6      
CLL   Tested under compiler:   cft77                                       COASIS.7      
CLL   Tested under OS version: UNICOS 9.0.4 (C90)                          COASIS.8      
CLL                                                                        COASIS.9      
CLL   Author:   JC Thil.                                                   COASIS.10     
CLL                                                                        COASIS.11     
CLL   Code version no: 1.0         Date: 18 Nov 1996                       COASIS.12     
CLL                                                                        COASIS.13     
CLL   Model            Modification history from model version 4.1:        COASIS.14     
CLL   version  date                                                        COASIS.15     
CLL                                                                        COASIS.16     
CLL                                                                        COASIS.17     
CLL                                                                        COASIS.18     
CLL                                                                        COASIS.19     
CLL  Programming standard: UM Doc Paper 3, version 2 (7/9/90)              COASIS.20     
CLL                                                                        COASIS.21     
CLL  Logical components covered:                                           COASIS.22     
CLL                                                                        COASIS.23     
CLL  Project task:                                                         COASIS.24     
CLL                                                                        COASIS.25     
CLL  External documentation:                                               COASIS.26     
CLL                                                                        COASIS.27     
*IF DEF,C99_1A                                                             COASIS.28     
*IF DEF,OCEAN                                                              COASIS.29     
                                                                           COASIS.30     
C*********************************************************************     COASIS.31     
C     This into a common deck to be included in any OASIS routine          COASIS.32     
C     which requires it.                                                   COASIS.33     
                                                                           COASIS.34     
      integer                                                              COASIS.35     
     &  G_IMT                   ! Global (ocean) row length                COASIS.36     
     &  ,G_JMT                  ! Global (ocean) p  rows                   COASIS.37     
     &  ,G_JMTM1                ! Global (ocean) uv rows                   COASIS.38     
     &  ,gather_pe              ! Processor for gathering                  COASIS.39     
                                                                           COASIS.40     
      integer nfield                                                       COASIS.41     
                                                                           COASIS.42     
      integer nulgr,nulma,nulsu ! unit no of the grid, mask, surf          COASIS.43     
                                ! files                                    COASIS.44     
      character*255 cficgr, cficma, cficsu ! filenames of the grid,        COASIS.45     
                                ! mask, surf files.                        COASIS.46     
      character*255 coasis_in   ! oasis input filename.                    COASIS.47     
                                                                           COASIS.48     
      integer                   ! items of the field locator array.        COASIS.49     
     &  istash, lon, lat, msk, srf, grd, direction, exc_frequency          COASIS.50     
     &  , exc_basis                                                        COASIS.51     
      parameter(                                                           COASIS.52     
     &  istash = 1, lon = 2, lat = 3, msk = 4, srf = 5                     COASIS.53     
     &  ,grd = 6, direction = 7, exc_frequency = 8                         COASIS.54     
     &  ,exc_basis = 9 )                                                   COASIS.55     
                                                                           COASIS.56     
! Ditto as above, but for the Zinput array :                               COASIS.57     
      integer                   ! items of the field locator array.        COASIS.58     
     &  Zistash, Zgrd, Zdirection, Zexc_frequency                          COASIS.59     
     &  ,Zexc_basis                                                        COASIS.60     
      parameter(                                                           COASIS.61     
     &  Zistash = 1                                                        COASIS.62     
     &  ,Zgrd = 2, Zdirection = 3, Zexc_frequency = 4                      COASIS.63     
     &  ,Zexc_basis = 5 )                                                  COASIS.64     
                                                                           COASIS.65     
      integer                                                              COASIS.66     
     &  MaxCouplingField        ! max number of coupling fields.           COASIS.67     
     &  , NoCouplingField       ! number of coupling fields.               COASIS.68     
     &  , NbItem                ! Nb of items of the field locator         COASIS.69     
                                ! array.                                   COASIS.70     
     &  , ZNbItem               ! Nb of items of the input file.           COASIS.71     
      parameter(  MaxCouplingField = 100 ) ! dimension of                  COASIS.72     
                                           ! FieldLocator.                 COASIS.73     
      parameter(  NbItem = 9 )                                             COASIS.74     
      parameter( ZNbItem = 5 )                                             COASIS.75     
                                                                           COASIS.76     
      character*8                                                          COASIS.77     
     &  ZInput(ZNbItem, MaxCouplingField)                                  COASIS.78     
     &  ,FieldLocator(NbItem,MaxCouplingField)                             COASIS.79     
                                                                           COASIS.80     
      integer D1_Zptr(MaxCouplingField)                                    COASIS.81     
      integer FieldSize(MaxCouplingField) ! size of each coupling          COASIS.82     
                                          !  field                         COASIS.83     
                                                                           COASIS.84     
                                                                           COASIS.85     
      integer nulou             ! unit for verbose file.                   COASIS.86     
                                                                           COASIS.87     
C     cdfile : alias filename for pipe (char string)                       COASIS.88     
C     cdpipe  : symbolic pipe name (char string)                           COASIS.89     
      character*8                                                          COASIS.90     
     &  cdfile(MaxCouplingField),                                          COASIS.91     
     &  cdpipe(MaxCouplingField)                                           COASIS.92     
                                                                           COASIS.93     
      integer                                                              COASIS.94     
     &     irt, iru,            ! no. of distinct cols.                    COASIS.95     
                                ! in ocean t/u grid                        COASIS.96     
     &  g_irt, g_iru            ! no. of distinct cols.                    COASIS.97     
                                ! in ocean t/u grid                        COASIS.98     
                                                                           COASIS.99     
      common / COM_OASIS /                                                 COASIS.100    
     &  gather_pe,                                                         COASIS.101    
     &  g_imt, g_jmt, g_jmtm1, g_irt, g_iru,                               COASIS.102    
     &  irt, iru,                                                          COASIS.103    
     &  NoCouplingField,                                                   COASIS.104    
     &  FieldLocator,D1_Zptr, FieldSize,                                   COASIS.105    
     &  nulou,                                                             COASIS.106    
     &  nfield,                                                            COASIS.107    
     &  cdfile, cdpipe                                                     COASIS.108    
                                                                           COASIS.109    
C     end of common deck                                                   COASIS.110    
C********************************************************************      COASIS.111    
C     ! The list below describes the status of the atmosphere model        COASIS.112    
C     ! Exporting and importing fields to the ocean. A symetrical list     COASIS.113    
C     ! will have to be drawn up for the Ocean part of the UM when         COASIS.114    
C     ! coupling both UM atmos and Ocean.                                  COASIS.115    
                                                                           COASIS.116    
      data  cficgr   / "grids" /                                           COASIS.123    
      data  cficma   / "masks" /                                           COASIS.124    
      data  cficsu   / "areas" /                                           COASIS.125    
      data  coasis_in / "namoasis_oce" /                                   COASIS.126    
                                                                           COASIS.127    
C     end of namelist                                                      COASIS.128    
C********************************************************************      COASIS.129    
                                                                           COASIS.130    
      integer                                                              COASIS.131    
     &  ii,j,i                  ! working indexes                          COASIS.132    
                                                                           COASIS.133    
*ENDIF                                                                     COASIS.134    
                                                                           COASIS.135    
C*********************************************************************     COASIS.136    
C declatarions for the atmosphere model :                                  COASIS.137    
*IF DEF,ATMOS                                                              COASIS.138    
C*********************************************************************     COASIS.139    
C     This into a common deck to be included in any OASIS routine          COASIS.140    
C     which requires it.                                                   COASIS.141    
                                                                           COASIS.142    
      integer                                                              COASIS.143    
     &  G_ROW_LENGTH           ! Global (atmos) row length                 COASIS.144    
     &  ,G_P_ROWS               ! Global (atmos) p  rows                   COASIS.145    
     &  ,G_U_ROWS               ! Global (atmos) uv rows                   COASIS.146    
     &  ,gather_pe              ! Processor for gathering                  COASIS.147    
                                                                           COASIS.148    
      integer nfield                                                       COASIS.149    
                                                                           COASIS.150    
      integer nulgr,nulma,nulsu ! unit no of the grid, mask, surf          COASIS.151    
                                ! files                                    COASIS.152    
      character*255 cficgr, cficma, cficsu ! filenames of the grid,        COASIS.153    
                                ! mask, surf files.                        COASIS.154    
      character*255 coasis_in   ! oasis input filename.                    COASIS.155    
                                                                           COASIS.156    
      integer                   ! items of the field locator array.        COASIS.157    
     &  istash, lon, lat, msk, srf, grd, direction, exc_frequency          COASIS.158    
     &  , exc_basis                                                        COASIS.159    
      parameter(                                                           COASIS.160    
     &  istash = 1, lon = 2, lat = 3, msk = 4, srf = 5                     COASIS.161    
     &  ,grd = 6, direction = 7, exc_frequency = 8                         COASIS.162    
     &  ,exc_basis = 9 )                                                   COASIS.163    
                                                                           COASIS.164    
! Ditto as above, but for the Zinput array :                               COASIS.165    
      integer                   ! items of the field locator array.        COASIS.166    
     &  Zistash, Zgrd, Zdirection, Zexc_frequency                          COASIS.167    
     &  ,Zexc_basis                                                        COASIS.168    
      parameter(                                                           COASIS.169    
     &  Zistash = 1                                                        COASIS.170    
     &  ,Zgrd = 2, Zdirection = 3, Zexc_frequency = 4                      COASIS.171    
     &  ,Zexc_basis = 5 )                                                  COASIS.172    
                                                                           COASIS.173    
      integer                                                              COASIS.174    
     &  MaxCouplingField        ! max number of coupling fields.           COASIS.175    
     &  , NoCouplingField       ! number of coupling fields.               COASIS.176    
     &  , NbItem                ! Nb of items of the field locator         COASIS.177    
                                ! array.                                   COASIS.178    
     &  , ZNbItem               ! Nb of items of the input file.           COASIS.179    
      parameter(  MaxCouplingField = 100 ) ! dimension of                  COASIS.180    
                                           ! FieldLocator.                 COASIS.181    
      parameter(  NbItem = 9 )                                             COASIS.182    
      parameter( ZNbItem = 5 )                                             COASIS.183    
                                                                           COASIS.184    
      character*8                                                          COASIS.185    
     &  ZInput(ZNbItem, MaxCouplingField)                                  COASIS.186    
     &  ,FieldLocator(NbItem,MaxCouplingField)                             COASIS.187    
                                                                           COASIS.188    
      integer D1_Zptr(MaxCouplingField)                                    COASIS.189    
      integer FieldSize(MaxCouplingField) ! size of each coupling          COASIS.190    
                                          ! field                          COASIS.191    
! Declaration of the pointers on the atmosphere D1.                        COASIS.192    
      integer   ptr_solar, ptr_blue, ptr_longwave, ptr_sensible,           COASIS.193    
     &  ptr_evap, ptr_snowls, ptr_snowconv, ptr_rainls, ptr_rainconv,      COASIS.194    
     &  ptr_ice, ptr_pminus, ptr_heat_flux,                                COASIS.195    
     &  ptr_snowfall, ptr_sublimation_accumul, ptr_sublimation_inst,       COASIS.196    
     &  ptr_slowrunoff, ptr_fastrunoff, ptr_ocentpts,                      COASIS.197    
     &  ptr_runoff                                                         COASIS.198    
                                                                           COASIS.199    
                                                                           COASIS.200    
      integer nulou             ! unit for verbose file.                   COASIS.201    
                                                                           COASIS.202    
C     cdfile : alias filename for pipe (char string)                       COASIS.203    
C     cdpipe  : symbolic pipe name (char string)                           COASIS.204    
      character*8                                                          COASIS.205    
     &  cdfile(MaxCouplingField),                                          COASIS.206    
     &  cdpipe(MaxCouplingField)                                           COASIS.207    
      common / COM_OASIS /                                                 COASIS.208    
     &  gather_pe, g_row_length, g_p_rows, g_u_rows,                       COASIS.209    
     &  ptr_solar, ptr_blue, ptr_longwave, ptr_sensible,                   COASIS.210    
     &  ptr_evap, ptr_snowls, ptr_snowconv, ptr_rainls, ptr_rainconv,      COASIS.211    
     &  ptr_ice, ptr_pminus, ptr_heat_flux,                                COASIS.212    
     &  ptr_snowfall, ptr_sublimation_accumul, ptr_sublimation_inst,       COASIS.213    
     &  ptr_slowrunoff, ptr_fastrunoff,                                    COASIS.214    
     &  ptr_runoff, ptr_ocentpts,                                          COASIS.215    
     &  NoCouplingField,                                                   COASIS.216    
     &  FieldLocator,D1_Zptr, FieldSize,                                   COASIS.217    
     &  nulou,                                                             COASIS.218    
     &  nfield,                                                            COASIS.219    
     &  cdfile, cdpipe                                                     COASIS.220    
                                                                           COASIS.221    
C     end of common deck                                                   COASIS.222    
C********************************************************************      COASIS.223    
C     ! The list below describes the status of the atmosphere model        COASIS.224    
C     ! Exporting and importing fields to the ocean. A symetrical list     COASIS.225    
C     ! will have to be drawn up for the Ocean part of the UM when         COASIS.226    
C     ! coupling both UM atmos and Ocean.                                  COASIS.227    
                                                                           COASIS.228    
                                                                           COASIS.233    
      data  cficgr   / "grids" /                                           COASIS.234    
      data  cficma   / "masks" /                                           COASIS.235    
      data  cficsu   / "areas" /                                           COASIS.236    
      data  coasis_in / "namoasis_atm" /                                   COASIS.237    
                                                                           COASIS.238    
C     end of namelist                                                      COASIS.239    
C********************************************************************      COASIS.240    
                                                                           COASIS.241    
      integer                                                              COASIS.242    
     &  ii,j,i                  ! working indexes                          COASIS.243    
                                                                           COASIS.244    
*ENDIF                                                                     COASIS.245    
*ENDIF                                                                     COASIS.246    
                                                                           COASIS.247