/[MITgcm]/MITgcm/model/src/ini_grid.F
ViewVC logotype

Annotation of /MITgcm/model/src/ini_grid.F

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.4 - (hide annotations) (download)
Thu Jul 2 14:16:24 1998 UTC (25 years, 10 months ago) by adcroft
Branch: MAIN
CVS Tags: checkpoint11, checkpoint13, checkpoint15, checkpoint14, checkpoint17, checkpoint12, checkpoint16, branch-point-rdot
Branch point for: branch-rdot
Changes since 1.3: +5 -2 lines
Re-arrangment of initialisation:
 o ini_grid is now called first and it sets up *only* the grid and
   coordinate system.
 o ini_depths then reads topography are can set it as a function of xC, yC.
 o ini_masks_etc then derives everything else (masks, lopping factors and
   recipricols).
This tidy-up is in preparation for the rDot transformation...(tense pause)!

1 adcroft 1.4 C $Header: /u/gcmpack/models/MITgcmUV/model/src/ini_grid.F,v 1.3 1998/04/24 02:10:20 cnh Exp $
2 cnh 1.1
3     #include "CPP_EEOPTIONS.h"
4    
5     CStartOfInterface
6     SUBROUTINE INI_GRID( myThid )
7     C /==========================================================\
8     C | SUBROUTINE INI_GRID |
9     C | o Initialise model grid |
10     C |==========================================================|
11     C | These arrays are used throughout the code in evaluating |
12     C | gradients, integrals and spatial avarages. This routine |
13     C | is called separately by each thread and initialise only |
14     C | the region of the domain it is "responsible" for. |
15     C | Notes: |
16     C | Two examples are shown in this code. One illustrates the |
17     C | initialisation of a cartesian grid. The other shows the |
18     C | inialisation of a spherical polar grid. Other orthonormal|
19     C | grids can be fitted into this design. In this case |
20     C | custom metric terms also need adding to account for the |
21     C | projections of velocity vectors onto these grids. |
22     C | The structure used here also makes it possible to |
23     C | implement less regular grid mappings. In particular |
24     C | o Schemes which leave out blocks of the domain that are |
25     C | all land could be supported. |
26     C | o Multi-level schemes such as icosohedral or cubic |
27     C | grid projectedions onto a sphere can also be fitted |
28     C | within the strategy we use. |
29     C | Both of the above also require modifying the support |
30     C | routines that map computational blocks to simulation |
31     C | domain blocks. |
32     C \==========================================================/
33    
34     C === Global variables ===
35     #include "SIZE.h"
36     #include "EEPARAMS.h"
37     #include "PARAMS.h"
38     #include "GRID.h"
39    
40     C == Routine arguments ==
41     C myThid - Number of this instance of INI_GRID
42     INTEGER myThid
43     CEndOfInterface
44    
45     C == Local variables ==
46     C msgBuf - Used for informational I/O.
47     CHARACTER*(MAX_LEN_MBUF) msgBuf
48    
49 adcroft 1.4 C-- Set up vertical grid and coordinate system
50     CALL INI_VERTICAL_GRID( myThid )
51    
52     C-- Set up horizontal grid and coordinate system
53 cnh 1.1 IF ( usingCartesianGrid ) THEN
54     CALL INI_CARTESIAN_GRID( myThid )
55     ELSEIF ( usingSphericalPolarGrid ) THEN
56     CALL INI_SPHERICAL_POLAR_GRID( myThid )
57     ELSE
58     _BEGIN_MASTER(myThid)
59     WRITE(msgBuf,'(A)')
60     & 'S/R INI_GRID: No grid coordinate system has been selected'
61     CALL PRINT_ERROR( msgBuf , myThid)
62     STOP 'ABNORMAL END: S/R INI_GRID'
63     _END_MASTER(myThid)
64     ENDIF
65     C
66     RETURN
67     END

  ViewVC Help
Powered by ViewVC 1.1.22