Back to home page

MITgcm

 
 

    


File indexing completed on 2018-03-02 18:41:30 UTC

view on githubraw file Latest commit add29e06 on 2018-01-31 20:35:05 UTC
cc36b35673 Jean*0001 #include "GRIDALT_OPTIONS.h"
                0002 
8aa94f3b31 Andr*0003        subroutine gridalt_initialise (myThid)
                0004 c-----------------------------------------------------------------------
be5ec7d59d Andr*0005 c  Routine to initialise the gridalt package.
cc36b35673 Jean*0006 c
8aa94f3b31 Andr*0007 c  Input: myThid       - Process number calling this routine
                0008 c
cc36b35673 Jean*0009 c  Notes:
                0010 c   When used with fizhi, this routine is the interface
8aa94f3b31 Andr*0011 c                                       to make_phys_grid
                0012 c  Calls: make_phys_grid (define the physics grid and mappings)
f13426fb9c Andr*0013 c         when diagnostics are used, call gridalt_diagnostics_init
8aa94f3b31 Andr*0014 c-----------------------------------------------------------------------
                0015        implicit none
                0016 #include "SIZE.h"
                0017 #include "EEPARAMS.h"
f1a1b411f0 Andr*0018 #include "PARAMS.h"
8aa94f3b31 Andr*0019 #include "GRID.h"
                0020 #include "fizhi_SIZE.h"
                0021 #include "gridalt_mapping.h"
                0022 #include "SURFACE.h"
                0023 
                0024        integer myThid
                0025 
                0026        integer nlph
                0027        integer bi, bj
                0028        integer im1, im2, jm1, jm2, idim1, idim2, jdim1, jdim2
                0029 
                0030        im1 = 1-OLx
                0031        im2 = sNx+OLx
                0032        jm1 = 1-OLy
                0033        jm2 = sNy+OLy
                0034        idim1 = 1
                0035        idim2 = sNx
                0036        jdim1 = 1
                0037        jdim2 = sNy
                0038 
f1a1b411f0 Andr*0039 #ifdef ALLOW_FIZHI
                0040        if(usefizhi) then
                0041         do bj = myByLo(myThid), myByHi(myThid)
                0042         do bi = myBxLo(myThid), myBxHi(myThid)
8aa94f3b31 Andr*0043 
f1a1b411f0 Andr*0044          call make_phys_grid(drF,hfacC,im1,im2,jm1,jm2,Nr,Nsx,Nsy,
8aa94f3b31 Andr*0045      .       1,sNx,1,sNy,bi,bj,Nrphys,ksurfC,dpphys0,nlph,nlperdyn)
                0046 
f1a1b411f0 Andr*0047          if( NrPhys.ne.nlph ) then
                0048           print *,' ERROR CONDITION - Model has been brought down '
                0049           print *,' Physics dimension in fizhi_size is ',Nrphys,
                0050      .                     ' New grid has ',nlph,' levels '
                0051           stop
                0052          endif
                0053 
                0054         enddo
                0055         enddo
                0056        endif
f13426fb9c Andr*0057 
                0058 #ifdef ALLOW_DIAGNOSTICS
                0059       if ( useDiagnostics ) then
                0060         call gridalt_diagnostics_init( myThid )
                0061       endif
                0062 #endif
                0063 
f1a1b411f0 Andr*0064 #endif
8aa94f3b31 Andr*0065 
                0066        return
                0067        end