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

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

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


Revision 1.2 - (hide annotations) (download)
Tue Oct 19 02:39:58 2004 UTC (19 years, 7 months ago) by jmc
Branch: MAIN
CVS Tags: checkpoint57m_post, checkpoint57g_pre, checkpoint57s_post, checkpoint58b_post, checkpoint57b_post, checkpoint57g_post, checkpoint56b_post, checkpoint57y_post, checkpoint57r_post, checkpoint57d_post, checkpoint57i_post, checkpoint59, checkpoint58, checkpoint57, checkpoint56, checkpoint58f_post, checkpoint57n_post, checkpoint58d_post, checkpoint58a_post, checkpoint57z_post, checkpoint58y_post, checkpoint58t_post, checkpoint55i_post, checkpoint58m_post, checkpoint57l_post, checkpoint57t_post, checkpoint57v_post, checkpoint57f_post, checkpoint60, checkpoint61, checkpoint57a_post, checkpoint57h_pre, checkpoint58w_post, checkpoint57h_post, checkpoint57y_pre, checkpoint58o_post, checkpoint57c_post, checkpoint58p_post, checkpoint58q_post, checkpoint58e_post, mitgcm_mapl_00, checkpoint57c_pre, checkpoint58r_post, checkpoint55j_post, checkpoint55h_post, checkpoint58n_post, checkpoint57e_post, checkpoint59q, checkpoint59p, checkpoint59r, checkpoint59e, checkpoint59d, checkpoint59g, checkpoint59f, checkpoint59a, checkpoint59c, checkpoint59b, checkpoint59m, checkpoint59l, checkpoint59o, checkpoint59n, checkpoint59i, checkpoint59h, checkpoint59k, checkpoint57p_post, checkpint57u_post, checkpoint57q_post, eckpoint57e_pre, checkpoint58k_post, checkpoint58v_post, checkpoint56a_post, checkpoint58l_post, checkpoint57h_done, checkpoint57j_post, checkpoint57f_pre, checkpoint58g_post, checkpoint58x_post, checkpoint59j, checkpoint58h_post, checkpoint56c_post, checkpoint58j_post, checkpoint57a_pre, checkpoint57o_post, checkpoint57k_post, checkpoint57w_post, checkpoint58i_post, checkpoint57x_post, checkpoint58c_post, checkpoint58u_post, checkpoint58s_post, checkpoint61b, checkpoint61a
Changes since 1.1: +3 -4 lines
use flags: fluidIsAir/Water, usingP/ZCoords instead of buoyancyRelation

1 jmc 1.2 C $Header: /u/gcmpack/MITgcm/model/src/pressure_for_eos.F,v 1.1 2003/02/18 15:25:09 jmc Exp $
2 jmc 1.1 C $Name: $
3     #include "CPP_OPTIONS.h"
4    
5     CBOP
6     C !ROUTINE: PRESSURE_FOR_EOS
7     C !INTERFACE:
8     SUBROUTINE PRESSURE_FOR_EOS(
9     I bi, bj, iMin, iMax, jMin, jMax, k,
10     O locPres,
11     I myThid )
12     C !DESCRIPTION: \bv
13     C *==========================================================*
14     C | SUBROUTINE PRESSURE_FOR_EOS
15     C | o Provide a local copy of the total pressure
16     C | at cell center (level k) for use in EOS funct. of P
17     C *==========================================================*
18     C \ev
19    
20     C !USES:
21    
22     IMPLICIT NONE
23     C == Global variables ==
24     #include "SIZE.h"
25     #include "EEPARAMS.h"
26     #include "PARAMS.h"
27     #include "GRID.h"
28     #include "DYNVARS.h"
29     #include "SURFACE.h"
30    
31     C !INPUT/OUTPUT PARAMETERS:
32     C == Routine arguments ==
33     C bi,bj, k :: tile and level indices
34     C iMin,iMax,jMin,jMax :: computational domain
35     C myThid - Thread number for this instance of the routine.
36     INTEGER bi, bj, k
37     INTEGER iMin,iMax,jMin,jMax
38     _RL locPres(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
39     INTEGER myThid
40    
41     C !LOCAL VARIABLES:
42     C == Local variables ==
43     C i,j :: loop index
44     INTEGER i,j
45     CEOP
46    
47     C
48     C provide the pressure for use in the equation of state
49     C
50 jmc 1.2 IF ( usingZCoords ) THEN
51 jmc 1.1 C in Z coordinates the pressure is rho0 * (hydrostatic) Potential
52     IF ( useDynP_inEos_Zc ) THEN
53     C----------
54     C NOTE: For now, totPhiHyd only contains the Potential anomaly
55     C since PhiRef is not available for Atmos and has not (yet)
56     C been added in S/R DIAGS_PHI_HYD
57     C----------
58     DO j=1-Oly,sNy+Oly
59     DO i=1-Olx,sNx+Olx
60     locPres(i,j) = rhoConst*(
61     & totPhiHyd(i,j,k,bi,bj)
62     & -rC(k)*gravity
63     & )*maskC(i,j,k,bi,bj)
64     ENDDO
65     ENDDO
66     ELSE
67     DO j=1-Oly,sNy+Oly
68     DO i=1-Olx,sNx+Olx
69     locPres(i,j) = -rhoConst*rC(k)*gravity
70     & *maskC(i,j,k,bi,bj)
71     ENDDO
72     ENDDO
73     ENDIF
74 jmc 1.2 ELSEIF ( usingPCoords ) THEN
75 jmc 1.1 C in P coordinates the pressure is just the coordinate of
76     C the tracer point
77     DO j=1-Oly,sNy+Oly
78     DO i=1-Olx,sNx+Olx
79     locPres(i,j) = rC(k)
80     & * maskC(i,j,k,bi,bj)
81     ENDDO
82     ENDDO
83     ENDIF
84    
85     RETURN
86     END

  ViewVC Help
Powered by ViewVC 1.1.22