/[MITgcm]/MITgcm/pkg/fizhi/step_fizhi_corr.F
ViewVC logotype

Diff of /MITgcm/pkg/fizhi/step_fizhi_corr.F

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

revision 1.2 by molod, Mon Feb 23 20:34:38 2004 UTC revision 1.3 by molod, Tue Mar 30 18:28:44 2004 UTC
# Line 55  c pe on dynamics and physics grid refers Line 55  c pe on dynamics and physics grid refers
55         jdim2 = sNy         jdim2 = sNy
56         dt = 1.         dt = 1.
57    
58           CALL TIMER_START('SETUP FIZHI CORR  [STEP_FIZHI_CORR]',mythid)
59         do bj = myByLo(myThid), myByHi(myThid)         do bj = myByLo(myThid), myByHi(myThid)
60         do bi = myBxLo(myThid), myBxHi(myThid)         do bi = myBxLo(myThid), myBxHi(myThid)
61    
# Line 107  c Create a wind magnitude field on the p Line 108  c Create a wind magnitude field on the p
108          enddo          enddo
109          enddo          enddo
110          enddo          enddo
111           enddo
112           enddo
113           CALL TIMER_STOP('SETUP FIZHI CORR  [STEP_FIZHI_CORR]',mythid)
114    
115           CALL TIMER_START('PHYS2DYN          [STEP_FIZHI_CORR]',mythid)
116           do bj = myByLo(myThid), myByHi(myThid)
117           do bi = myBxLo(myThid), myBxHi(myThid)
118    
119  c Compute correction term (new dyn state-phys state to dyn) on physics grid:  c Compute correction term (new dyn state-phys state to dyn) on physics grid:
120  c    First: interp physics state to dynamics grid  c    First: interp physics state to dynamics grid
# Line 121  c    First: interp physics state to dyna Line 129  c    First: interp physics state to dyna
129    
130         enddo         enddo
131         enddo         enddo
132           CALL TIMER_STOP('PHYS2DYN          [STEP_FIZHI_CORR]',mythid)
133    
134  c    Second: Convert physics state on dynamics grid to C-Grid  c    Second: Convert physics state on dynamics grid to C-Grid
135    
136           CALL TIMER_START('ATOC              [STEP_FIZHI_CORR]',mythid)
137         call AtoC(myThid,udyntemp,vdyntemp,maskC,im1,im2,jm1,jm2,Nr,         call AtoC(myThid,udyntemp,vdyntemp,maskC,im1,im2,jm1,jm2,Nr,
138       .                     Nsx,Nsy,1,sNx,1,sNy,udyntemp,vdyntemp)       .                     Nsx,Nsy,1,sNx,1,sNy,udyntemp,vdyntemp)
139           CALL TIMER_STOP('ATOC              [STEP_FIZHI_CORR]',mythid)
140    
141  c    Third: Subtract Phys state on dyn. grid from new dynamics state  c    Third: Subtract Phys state on dyn. grid from new dynamics state
142         do bj = myByLo(myThid), myByHi(myThid)         do bj = myByLo(myThid), myByHi(myThid)
# Line 146  c    Third: Subtract Phys state on dyn. Line 157  c    Third: Subtract Phys state on dyn.
157         enddo         enddo
158    
159  c    Fourth: Convert correction terms to A-Grid  c    Fourth: Convert correction terms to A-Grid
160           CALL TIMER_START('CTOA              [STEP_FIZHI_CORR]',mythid)
161          call CtoA(myThid,udyntemp,vdyntemp,maskW,maskS,im1,im2,jm1,jm2,          call CtoA(myThid,udyntemp,vdyntemp,maskW,maskS,im1,im2,jm1,jm2,
162       .     Nr,Nsx,Nsy,1,sNx,1,sNy,udyntemp,vdyntemp)       .     Nr,Nsx,Nsy,1,sNx,1,sNy,udyntemp,vdyntemp)
163           CALL TIMER_STOP('CTOA              [STEP_FIZHI_CORR]',mythid)
164    
165  c    Fifth: Interpolate correction terms to physics grid  c    Fifth: Interpolate correction terms to physics grid
166           CALL TIMER_START('DYN2PHYS          [STEP_FIZHI_CORR]',mythid)
167         do bj = myByLo(myThid), myByHi(myThid)         do bj = myByLo(myThid), myByHi(myThid)
168         do bi = myBxLo(myThid), myBxHi(myThid)         do bi = myBxLo(myThid), myBxHi(myThid)
169    
# Line 161  c    Fifth: Interpolate correction terms Line 175  c    Fifth: Interpolate correction terms
175       .     1,sNy,bi,bj,windphy,pephy,ksurfC,Nrphys,nlperdyn,0,thphytemp)       .     1,sNy,bi,bj,windphy,pephy,ksurfC,Nrphys,nlperdyn,0,thphytemp)
176          call dyn2phys(sdyntemp,pedyn,im1,im2,jm1,jm2,Nr,Nsx,Nsy,1,sNx,          call dyn2phys(sdyntemp,pedyn,im1,im2,jm1,jm2,Nr,Nsx,Nsy,1,sNx,
177       .      1,sNy,bi,bj,windphy,pephy,ksurfC,Nrphys,nlperdyn,0,sphytemp)       .      1,sNy,bi,bj,windphy,pephy,ksurfC,Nrphys,nlperdyn,0,sphytemp)
178           enddo
179           enddo
180           CALL TIMER_STOP('DYN2PHYS          [STEP_FIZHI_CORR]',mythid)
181    
182  c    Last: Increment physics state by the correction term  c    Last: Increment physics state by the correction term
183           CALL TIMER_START('STEP_PHYSICS      [STEP_FIZHI_CORR]',mythid)
184           do bj = myByLo(myThid), myByHi(myThid)
185           do bi = myBxLo(myThid), myBxHi(myThid)
186          call step_physics(uphy,vphy,thphy,sphy,dt,im1,im2,jm1,jm2,          call step_physics(uphy,vphy,thphy,sphy,dt,im1,im2,jm1,jm2,
187       .   Nrphys,Nsx,Nsy,1,sNx,1,sNy,bi,bj,       .   Nrphys,Nsx,Nsy,1,sNx,1,sNy,bi,bj,
188       .                            uphytemp,vphytemp,thphytemp,sphytemp)       .                            uphytemp,vphytemp,thphytemp,sphytemp)
189    
190         enddo         enddo
191         enddo         enddo
192           CALL TIMER_STOP('STEP_PHYSICS      [STEP_FIZHI_CORR]',mythid)
193    
194         return         return
195         end         end

Legend:
Removed from v.1.2  
changed lines
  Added in v.1.3

  ViewVC Help
Powered by ViewVC 1.1.22