1 |
heimbach |
1.2 |
C $Header: /u/gcmpack/MITgcm/model/src/diags_phi_hyd.F,v 1.1 2003/02/18 15:25:09 jmc Exp $ |
2 |
jmc |
1.1 |
C $Name: $ |
3 |
|
|
|
4 |
|
|
#include "CPP_OPTIONS.h" |
5 |
|
|
|
6 |
|
|
CBOP |
7 |
|
|
C !ROUTINE: DIAGS_PHI_HYD |
8 |
|
|
C !INTERFACE: |
9 |
|
|
SUBROUTINE DIAGS_PHI_HYD( |
10 |
|
|
I k, bi, bj, iMin,iMax, jMin,jMax, |
11 |
|
|
I phiHydC, |
12 |
|
|
I myTime, myIter, myThid) |
13 |
|
|
C !DESCRIPTION: \bv |
14 |
|
|
C *==========================================================* |
15 |
|
|
C | S/R DIAGS_PHI_HYD |
16 |
|
|
C | o Diagnose full hydrostatic Potential at cell center ; |
17 |
|
|
C | used for output & with EOS funct. of P |
18 |
|
|
C *==========================================================* |
19 |
|
|
C | NOTE: For now, only contains the (total) Potential anomaly |
20 |
|
|
C | since phiRef (for Atmos) is not available (not in common) |
21 |
|
|
C *==========================================================* |
22 |
|
|
C \ev |
23 |
|
|
|
24 |
|
|
C !USES: |
25 |
|
|
IMPLICIT NONE |
26 |
|
|
C == Global variables == |
27 |
|
|
#include "SIZE.h" |
28 |
|
|
#include "EEPARAMS.h" |
29 |
|
|
#include "PARAMS.h" |
30 |
|
|
#include "GRID.h" |
31 |
|
|
#include "SURFACE.h" |
32 |
|
|
#include "DYNVARS.h" |
33 |
|
|
|
34 |
|
|
C !INPUT/OUTPUT PARAMETERS: |
35 |
|
|
C == Routine Arguments == |
36 |
|
|
C k, bi,bj :: level & tile indices |
37 |
|
|
C iMin,iMax,jMin,jMax :: Loop counters |
38 |
|
|
C phiHydC :: hydrostatic potential anomaly at cell center |
39 |
|
|
C (atmos: =Geopotential ; ocean-z: =Pressure/rho) |
40 |
|
|
C myTime :: Current time |
41 |
|
|
C myIter :: Current iteration number |
42 |
|
|
C myThid :: Instance number for this call of the routine. |
43 |
|
|
INTEGER k, bi,bj, iMin,iMax, jMin,jMax |
44 |
|
|
_RL phiHydC(1-OLx:sNx+OLx,1-OLy:sNy+OLy) |
45 |
|
|
_RL myTime |
46 |
|
|
INTEGER myIter, myThid |
47 |
|
|
|
48 |
|
|
#ifdef INCLUDE_PHIHYD_CALCULATION_CODE |
49 |
|
|
|
50 |
|
|
C !LOCAL VARIABLES: |
51 |
|
|
C == Local variables == |
52 |
|
|
C i,j :: Loop counters |
53 |
|
|
INTEGER i,j |
54 |
|
|
CEOP |
55 |
|
|
DO j=jMin,jMax |
56 |
|
|
DO i=iMin,iMax |
57 |
|
|
totPhiHyd(i,j,k,bi,bj) = phiHydC(i,j) |
58 |
|
|
& + Bo_surf(i,j,bi,bj)*etaN(i,j,bi,bj) |
59 |
|
|
& + phi0surf(i,j,bi,bj) |
60 |
|
|
ENDDO |
61 |
|
|
ENDDO |
62 |
|
|
|
63 |
|
|
#endif /* INCLUDE_PHIHYD_CALCULATION_CODE */ |
64 |
|
|
|
65 |
|
|
RETURN |
66 |
|
|
END |