1 |
subroutine gridalt_initialise (myThid) |
2 |
c----------------------------------------------------------------------- |
3 |
c Routine to initialise the gridalt package. |
4 |
c |
5 |
c Input: myThid - Process number calling this routine |
6 |
c |
7 |
c Notes: |
8 |
c When used with fizhi, this routine is the interface |
9 |
c to make_phys_grid |
10 |
c Calls: make_phys_grid (define the physics grid and mappings) |
11 |
c----------------------------------------------------------------------- |
12 |
implicit none |
13 |
#include "PACKAGES_CONFIG.h" |
14 |
#include "CPP_OPTIONS.h" |
15 |
#include "SIZE.h" |
16 |
#include "EEPARAMS.h" |
17 |
#include "PARAMS.h" |
18 |
#include "GRID.h" |
19 |
#include "fizhi_SIZE.h" |
20 |
#include "gridalt_mapping.h" |
21 |
#include "SURFACE.h" |
22 |
|
23 |
integer myThid |
24 |
|
25 |
integer nlph |
26 |
integer bi, bj |
27 |
integer im1, im2, jm1, jm2, idim1, idim2, jdim1, jdim2 |
28 |
|
29 |
im1 = 1-OLx |
30 |
im2 = sNx+OLx |
31 |
jm1 = 1-OLy |
32 |
jm2 = sNy+OLy |
33 |
idim1 = 1 |
34 |
idim2 = sNx |
35 |
jdim1 = 1 |
36 |
jdim2 = sNy |
37 |
|
38 |
#ifdef ALLOW_FIZHI |
39 |
if(usefizhi) then |
40 |
do bj = myByLo(myThid), myByHi(myThid) |
41 |
do bi = myBxLo(myThid), myBxHi(myThid) |
42 |
|
43 |
call make_phys_grid(drF,hfacC,im1,im2,jm1,jm2,Nr,Nsx,Nsy, |
44 |
. 1,sNx,1,sNy,bi,bj,Nrphys,ksurfC,dpphys0,nlph,nlperdyn) |
45 |
|
46 |
if( NrPhys.ne.nlph ) then |
47 |
print *,' ERROR CONDITION - Model has been brought down ' |
48 |
print *,' Physics dimension in fizhi_size is ',Nrphys, |
49 |
. ' New grid has ',nlph,' levels ' |
50 |
stop |
51 |
endif |
52 |
|
53 |
enddo |
54 |
enddo |
55 |
endif |
56 |
#endif |
57 |
|
58 |
return |
59 |
end |