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

Contents of /MITgcm/model/src/correction_step.F

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


Revision 1.19 - (show annotations) (download)
Wed Sep 26 18:09:14 2001 UTC (22 years, 7 months ago) by cnh
Branch: MAIN
CVS Tags: checkpoint46n_post, checkpoint47e_post, checkpoint44e_post, checkpoint46l_post, checkpoint46g_pre, checkpoint47c_post, release1_p13_pre, checkpoint46f_post, checkpoint48e_post, checkpoint44f_post, checkpoint46b_post, checkpoint43a-release1mods, ecco_c50_e32, ecco_c50_e33, ecco_c50_e30, ecco_c50_e31, release1_p13, checkpoint48i_post, checkpoint46l_pre, chkpt44d_post, checkpoint50, release1_p8, release1_p9, release1_p1, release1_p2, release1_p3, release1_p4, release1_p5, release1_p6, release1_p7, checkpoint50b_pre, checkpoint44e_pre, release1_b1, checkpoint48b_post, checkpoint43, checkpoint48c_pre, checkpoint47d_pre, release1_chkpt44d_post, checkpoint47a_post, checkpoint48d_pre, checkpoint47i_post, release1_p11, checkpoint47d_post, icebear5, icebear4, icebear3, icebear2, checkpoint46d_pre, checkpoint48d_post, release1-branch_tutorials, checkpoint48f_post, checkpoint45d_post, checkpoint46j_pre, chkpt44a_post, checkpoint44h_pre, checkpoint48h_post, ecco_c50_e29, checkpoint46a_post, checkpoint47g_post, checkpoint46j_post, checkpoint46k_post, ecco_c50_e28, chkpt44c_pre, checkpoint48a_post, checkpoint45a_post, checkpoint50a_post, ecco_c44_e19, ecco_c44_e18, ecco_c44_e17, ecco_c44_e16, release1_p12, release1_p10, release1_p16, release1_p17, release1_p14, release1_p15, checkpoint47j_post, ecco_c50_e33a, branch-exfmods-tag, checkpoint44g_post, checkpoint46e_pre, checkpoint48c_post, checkpoint45b_post, checkpoint46b_pre, release1-branch-end, release1_final_v1, checkpoint46c_pre, checkpoint46, checkpoint47b_post, checkpoint44b_post, checkpoint46h_pre, checkpoint46m_post, checkpoint46a_pre, checkpoint45c_post, ecco_ice2, ecco_ice1, checkpoint44h_post, checkpoint46g_post, release1_p12_pre, ecco_c44_e22, ecco_c44_e25, checkpoint47f_post, chkpt44a_pre, checkpoint46i_post, ecco_c44_e23, ecco_c44_e20, ecco_c44_e21, ecco_c44_e26, ecco_c44_e27, ecco_c44_e24, checkpoint46c_post, ecco-branch-mod1, ecco-branch-mod2, ecco-branch-mod3, ecco-branch-mod4, ecco-branch-mod5, checkpoint46e_post, release1_beta1, checkpoint44b_pre, checkpoint42, checkpoint41, checkpoint47, checkpoint44, checkpoint45, checkpoint48, checkpoint49, checkpoint46h_post, chkpt44c_post, checkpoint48g_post, checkpoint47h_post, checkpoint44f_pre, checkpoint46d_post, release1-branch_branchpoint
Branch point for: c24_e25_ice, branch-exfmods-curt, release1_final, release1-branch, release1, ecco-branch, release1_50yr, icebear, release1_coupled
Changes since 1.18: +20 -7 lines
Bringing comments up to data and formatting for document extraction.

1 C $Header: /u/gcmpack/models/MITgcmUV/model/src/correction_step.F,v 1.18 2001/06/29 17:14:49 adcroft Exp $
2 C $Name: $
3
4 #include "CPP_OPTIONS.h"
5
6 CBOP
7 C !ROUTINE: CORRECTION_STEP
8 C !INTERFACE:
9 SUBROUTINE CORRECTION_STEP( bi, bj, iMin, iMax, jMin, jMax,
10 I K, phiSurfX, phiSurfY,
11 I myCurrentTime, myThid )
12 C !DESCRIPTION: \bv
13 C *==========================================================*
14 C | S/R CORRECTION_STEP
15 C | o Corrects the horizontal flow fields with the surface
16 C | slope.
17 C *==========================================================*
18 C \ev
19
20 C !USES:
21 IMPLICIT NONE
22 C == Global variables ==
23 #include "SIZE.h"
24 #include "DYNVARS.h"
25 #include "EEPARAMS.h"
26 #include "PARAMS.h"
27 #include "GRID.h"
28 #ifdef ALLOW_NONHYDROSTATIC
29 #include "SOLVE_FOR_PRESSURE3D.h"
30 #endif
31
32 C !INPUT/OUTPUT PARAMETERS:
33 C == Routine Arguments ==
34 C phiSurfX, phiSurfY - Surface Potential gradient
35 C bi,bj,iMin,iMax,jMin,jMax, K - Loop counters
36 C myThid - Instance number for
37 C this call to S/R CORRECTION_STEP
38 C myCurrentTime - Current simulation time for this instance.
39 _RL phiSurfX(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
40 _RL phiSurfY(1-OLx:sNx+OLx,1-OLy:sNy+OLy)
41 INTEGER bi,bj,iMin,iMax,jMin,jMax
42 INTEGER K
43 INTEGER myThid
44 _RL myCurrentTime
45
46 C !LOCAL VARIABLES:
47 C == Local variables ==
48 C i,j :: Loop counters
49 C hxFac, hyFac :: Tracer parameters for supressing gradients
50 C hx3dFac,hy3dFac
51 INTEGER i,j
52 _RL hxFac,hyFac
53 _RL hx3dFac,hy3dFac
54 CEOP
55
56 C On/off scaling paramters
57 hxFac = pfFacMom
58 hyFac = pfFacMom
59 IF ( nonHydrostatic ) THEN
60 hx3dFac = pfFacMom
61 hy3dFac = pfFacMom
62 ELSE
63 hx3dFac = 0.
64 hy3dFac = 0.
65 ENDIF
66
67 C Step forward zonal velocity
68 DO j=jMin,jMax
69 DO i=iMin,iMax
70 uVel(i,j,k,bi,bj)=( gUNm1(i,j,k,bi,bj)
71 & -deltaTmom*hxFac*implicSurfPress*phiSurfX(i,j)
72 #ifdef ALLOW_NONHYDROSTATIC
73 & -deltaTmom*hx3dFac*_recip_dxC(i,j,bi,bj)*
74 & (phi_nh(i,j,k,bi,bj)-phi_nh(i-1,j,k,bi,bj))
75 #endif
76 & )*_maskW(i,j,k,bi,bj)
77 gUNm1(i,j,k,bi,bj)=gU(i,j,k,bi,bj)
78 ENDDO
79 ENDDO
80
81 C Step forward meridional velocity
82 DO j=jMin,jMax
83 DO i=iMin,iMax
84 vVel(i,j,k,bi,bj)=( gVNm1(i,j,k,bi,bj)
85 & -deltaTmom*hyFac*implicSurfPress*phiSurfY(i,j)
86 #ifdef ALLOW_NONHYDROSTATIC
87 & -deltaTmom*hy3dFac*_recip_dyC(i,j,bi,bj)*
88 & (phi_nh(i,j,k,bi,bj)-phi_nh(i,j-1,k,bi,bj))
89 #endif
90 & )*_maskS(i,j,k,bi,bj)
91 gVNm1(i,j,k,bi,bj)=gV(i,j,k,bi,bj)
92 ENDDO
93 ENDDO
94
95 RETURN
96 END

  ViewVC Help
Powered by ViewVC 1.1.22