/[MITgcm]/MITgcm/pkg/dic/tracer_meanarea.F
ViewVC logotype

Annotation of /MITgcm/pkg/dic/tracer_meanarea.F

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


Revision 1.2 - (hide annotations) (download)
Mon Oct 6 20:11:10 2003 UTC (20 years, 11 months ago) by stephd
Branch: MAIN
CVS Tags: checkpoint51j_post, checkpoint51h_pre, checkpoint51i_pre
Changes since 1.1: +2 -6 lines
changes to keep current with gchem pkg, and to be adjointable

1 stephd 1.1 #include "CPP_OPTIONS.h"
2     #include "GCHEM_OPTIONS.h"
3    
4     C !INTERFACE: ==========================================================
5 stephd 1.2 SUBROUTINE TRACER_MEANAREA(myThid,tracer, kLev,
6 stephd 1.1 & gsm_tracer)
7     IMPLICIT NONE
8     #include "SIZE.h"
9     #include "GRID.h"
10     #include "DYNVARS.h"
11     #include "EEPARAMS.h"
12     #include "PARAMS.h"
13     C !INPUT PARAMETERS: ===================================================
14     C myThid :: thread number
15 stephd 1.2 INTEGER myThid
16 stephd 1.1 INTEGER kLev
17     _RL tracer (1-OLx:sNx+OLx,1-OLy:sNy+OLy,nR,nSx,nSy)
18     _RL gsm_tracer
19    
20     c local variables
21     INTEGER i,j,bi,bj
22     _RL sumarea
23    
24     _BEGIN_MASTER(myThid)
25    
26     sumarea= 0. _d 0
27     gsm_tracer= 0. _d 0
28    
29     DO bj=myByLo(myThid),myByHi(myThid)
30     DO bi=myBxLo(myThid),myBxHi(myThid)
31     DO i=1,sNx
32     DO j=1,sNy
33     sumarea=sumarea+
34     & rA(i,j,bi,bj)*maskC(i,j,kLev,bi,bj)
35     gsm_tracer=gsm_tracer+
36     & tracer(i,j,kLev,bi,bj)*rA(i,j,bi,bj)*
37     & maskC(i,j,kLev,bi,bj)
38     ENDDO
39     ENDDO
40     ENDDO
41     ENDDO
42     gsm_tracer=gsm_tracer/sumarea
43    
44     _END_MASTER(myThid)
45    
46     C-- Everyone else must wait
47     _BARRIER
48    
49    
50     RETURN
51     END
52    

  ViewVC Help
Powered by ViewVC 1.1.22