/[MITgcm]/MITgcm/pkg/exf/exf_mapfields.F
ViewVC logotype

Diff of /MITgcm/pkg/exf/exf_mapfields.F

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

revision 1.12 by heimbach, Wed Jun 29 07:11:18 2005 UTC revision 1.19 by heimbach, Wed Apr 18 19:55:34 2007 UTC
# Line 1  Line 1 
1  c $Header$  C $Header$
2    C $Name$
3    
4  #include "EXF_OPTIONS.h"  #include "EXF_OPTIONS.h"
5    
6        subroutine exf_mapfields( mythid )        subroutine exf_mapfields( mytime, myiter, mythid )
7    
8  c     ==================================================================  c     ==================================================================
9  c     SUBROUTINE exf_mapfields  c     SUBROUTINE exf_mapfields
# Line 15  c       This routine is included to sepa Line 16  c       This routine is included to sepa
16  c       tool as much as possible from the ocean model.  Unit and sign  c       tool as much as possible from the ocean model.  Unit and sign
17  c       conventions can be customized using variables exf_outscal_*,  c       conventions can be customized using variables exf_outscal_*,
18  c       which are set in exf_readparms.F.  See the header files  c       which are set in exf_readparms.F.  See the header files
19  c       exf_fields.h and FFIELDS.h for definitions of the various input  c       EXF_FIELDS.h and FFIELDS.h for definitions of the various input
20  c       and output fields and for default unit and sign convetions.  c       and output fields and for default unit and sign convetions.
21  c  c
22  c     started: Christian Eckert eckert@mit.edu  09-Aug-1999  c     started: Christian Eckert eckert@mit.edu  09-Aug-1999
# Line 47  c     == global variables == Line 48  c     == global variables ==
48    
49  #include "EEPARAMS.h"  #include "EEPARAMS.h"
50  #include "SIZE.h"  #include "SIZE.h"
51    #include "PARAMS.h"
52  #include "FFIELDS.h"  #include "FFIELDS.h"
53  #include "GRID.h"  #include "GRID.h"
54    
55  #include "exf_param.h"  #include "EXF_PARAM.h"
56  #include "exf_constants.h"  #include "EXF_CONSTANTS.h"
57  #include "exf_fields.h"  #include "EXF_FIELDS.h"
 #include "exf_clim_fields.h"  
58  #ifdef ALLOW_AUTODIFF_TAMC  #ifdef ALLOW_AUTODIFF_TAMC
59  # include "tamc.h"  # include "tamc.h"
60  # include "tamc_keys.h"  # include "tamc_keys.h"
# Line 63  c     == routine arguments == Line 64  c     == routine arguments ==
64  c     mythid - thread number for this instance of the routine.  c     mythid - thread number for this instance of the routine.
65    
66        integer mythid        integer mythid
67          integer myiter
68          _RL     mytime
69    
70  c     == local variables ==  c     == local variables ==
71    
72        integer bi,bj        integer bi,bj
73        integer i,j        integer i,j,k
74        integer jtlo        integer jtlo
75        integer jthi        integer jthi
76        integer itlo        integer itlo
# Line 108  c     == end of interface == Line 111  c     == end of interface ==
111              do i = imin,imax              do i = imin,imax
112  c            Heat flux.  c            Heat flux.
113               qnet(i,j,bi,bj) = exf_outscal_hflux*hflux(i,j,bi,bj)               qnet(i,j,bi,bj) = exf_outscal_hflux*hflux(i,j,bi,bj)
114                 if ( hfluxfile .EQ. ' ' )
115         &            qnet(i,j,bi,bj) = qnet(i,j,bi,bj) -
116         &            exf_outscal_hflux * ( hflux_exfremo_intercept +
117         &            hflux_exfremo_slope*(mytime-starttime) )
118              enddo              enddo
119            enddo            enddo
120    
# Line 116  c            Heat flux. Line 123  c            Heat flux.
123              do i = imin,imax              do i = imin,imax
124  c            Salt flux.  c            Salt flux.
125               empmr(i,j,bi,bj)= exf_outscal_sflux*sflux(i,j,bi,bj)               empmr(i,j,bi,bj)= exf_outscal_sflux*sflux(i,j,bi,bj)
126                 if ( sfluxfile .EQ. ' ' )
127         &            empmr(i,j,bi,bj) = empmr(i,j,bi,bj) -
128         &            exf_outscal_sflux * ( sflux_exfremo_intercept +
129         &            sflux_exfremo_slope*(mytime-starttime) )
130              enddo              enddo
131            enddo            enddo
132    
# Line 142  CADJ STORE ustress(:,:,bi,bj) = comlev1_ Line 153  CADJ STORE ustress(:,:,bi,bj) = comlev1_
153            enddo            enddo
154            do j = jmin,jmax            do j = jmin,jmax
155              do i = imin+1,imax              do i = imin+1,imax
156  #if (defined (ALLOW_BULKFORMULAE) || defined (USE_EXF_INTERPOLATION))  #if ( ( defined (ALLOW_BULKFORMULAE) && defined (ALLOW_ATM_WIND) ) \
157         || defined (USE_EXF_INTERPOLATION) )
158  c     Shift wind stresses calculated at C-points to W/S points  c     Shift wind stresses calculated at C-points to W/S points
159                fu(i,j,bi,bj) = exf_outscal_ustress*                fu(i,j,bi,bj) = exf_outscal_ustress*
160       &              (ustress(i,j,bi,bj)+ustress(i-1,j,bi,bj))/2.*       &              (ustress(i,j,bi,bj)+ustress(i-1,j,bi,bj))/2.*
# Line 176  CADJ STORE vstress(:,:,bi,bj) = comlev1_ Line 188  CADJ STORE vstress(:,:,bi,bj) = comlev1_
188            enddo            enddo
189            do j = jmin+1,jmax            do j = jmin+1,jmax
190              do i = imin,imax              do i = imin,imax
191  #if (defined (ALLOW_BULKFORMULAE) || defined (USE_EXF_INTERPOLATION))  #if ( ( defined (ALLOW_BULKFORMULAE) && defined (ALLOW_ATM_WIND) ) \
192         || defined (USE_EXF_INTERPOLATION) )
193  c     Shift wind stresses calculated at C-points to W/S points  c     Shift wind stresses calculated at C-points to W/S points
194                fv(i,j,bi,bj) = exf_outscal_vstress*                fv(i,j,bi,bj) = exf_outscal_vstress*
195       &              (vstress(i,j,bi,bj)+vstress(i,j-1,bi,bj))/2.*       &              (vstress(i,j,bi,bj)+vstress(i,j-1,bi,bj))/2.*

Legend:
Removed from v.1.12  
changed lines
  Added in v.1.19

  ViewVC Help
Powered by ViewVC 1.1.22