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

Diff of /MITgcm/model/src/calc_phi_hyd.F

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

revision 1.4 by cnh, Wed Sep 9 15:04:44 1998 UTC revision 1.5 by cnh, Wed Sep 9 15:19:07 1998 UTC
# Line 25  C     == Routine arguments == Line 25  C     == Routine arguments ==
25  C     == Local variables ==  C     == Local variables ==
26        INTEGER i,j,Km1        INTEGER i,j,Km1
27        _RL halfLayer        _RL halfLayer
28          _RL gamma
29    
30        if (K.eq.1) then        if (K.eq.1) then
31         Km1=1         Km1=1
# Line 34  C     == Local variables == Line 35  C     == Local variables ==
35         halfLayer=1.0 _d 0         halfLayer=1.0 _d 0
36        endif        endif
37    
38    C--   Scale factor for hydrostatic relation except for ocean in pressure coords.
39          gamma = 1. _d 0
40    C--   Scale factor for hydrostatic relation for ocean in pressure coords.
41          IF ( buoyancyRelation .EQ. 'OCEANIC' .AND. usingPCoords ) THEN
42           gamma = recip_Gravity*recip_rhoConst
43          ENDIF
44    
45  C--   Contribution to phiHyd(:,:,K) from buoy(:,:,K-1) + buoy(:,:,K)  C--   Contribution to phiHyd(:,:,K) from buoy(:,:,K-1) + buoy(:,:,K)
46  C     (This is now the actual hydrostatic pressure|height at the T/S points)  C     (This is now the actual hydrostatic pressure|height at the T/S points)
47        DO j=jMin,jMax        DO j=jMin,jMax
48         DO i=iMin,iMax         DO i=iMin,iMax
49          phiHyd(i,j,K)=phiHyd(i,j,Km1)-rhoConst*halfLayer          phiHyd(i,j,K)=phiHyd(i,j,Km1)-rhoConst*halfLayer
50       &  *0.5 _d 0*( drF(Km1)+drF(K) )*recip_HoriVertRatio       &  *0.5 _d 0*( drF(Km1)+drF(K) )*gamma
51       &  *0.5 _d 0*( buoyKM1(i,j)+buoyKP1(i,j) )       &  *0.5 _d 0*( buoyKM1(i,j)+buoyKP1(i,j) )
 C    &  *rkFac  
52         ENDDO         ENDDO
53        ENDDO        ENDDO
54    

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

  ViewVC Help
Powered by ViewVC 1.1.22