19 |
#ifdef ALLOW_EBM |
#ifdef ALLOW_EBM |
20 |
# include "EBM.h" |
# include "EBM.h" |
21 |
#endif |
#endif |
22 |
|
#ifdef ALLOW_AUTODIFF_TAMC |
23 |
|
# include "tamc.h" |
24 |
|
# include "tamc_keys.h" |
25 |
|
#endif |
26 |
|
|
27 |
C === Routine arguments === |
C === Routine arguments === |
28 |
C myThid - Instance number for this innvocation |
C myThid - Instance number for this innvocation |
66 |
CountX_tile(j,bi,bj) = CountX_tile(j,bi,bj) + |
CountX_tile(j,bi,bj) = CountX_tile(j,bi,bj) + |
67 |
& maskC(i,j,k,bi,bj) |
& maskC(i,j,k,bi,bj) |
68 |
ENDDO |
ENDDO |
69 |
|
ZonalMeanSST(j,bj) = ZonalMeanSST(j,bj) + |
70 |
|
& ZonalMean_tile(j,bi,bj) |
71 |
|
CountX(j,bj) = CountX(j,bj) + CountX_tile(j,bi,bj) |
72 |
ENDDO |
ENDDO |
|
ZonalMeanSST(j,bj) = ZonalMeanSST(j,bj) + |
|
|
& ZonalMean_tile(j,bi,bj) |
|
|
CountX(j,bj) = CountX(j,bj) + CountX_tile(j,bi,bj) |
|
73 |
ENDDO |
ENDDO |
74 |
ENDDO |
ENDDO |
75 |
|
|
77 |
DO j=1-OLy,sNy+OLy |
DO j=1-OLy,sNy+OLy |
78 |
_GLOBAL_SUM_R8( CountX(j,bj), myThid ) |
_GLOBAL_SUM_R8( CountX(j,bj), myThid ) |
79 |
_GLOBAL_SUM_R8( ZonalMeanSST(j,bj), myThid ) |
_GLOBAL_SUM_R8( ZonalMeanSST(j,bj), myThid ) |
80 |
|
ENDDO |
81 |
|
ENDDO |
82 |
|
|
83 |
|
#ifdef ALLOW_AUTODIFF_TAMC |
84 |
|
CADJ STORE CountX = comlev1, key = ikey_dynamics |
85 |
|
#endif |
86 |
|
DO bj=myByLo(myThid),myByHi(myThid) |
87 |
|
DO j=1-OLy,sNy+OLy |
88 |
IF ( CountX(j,bj) .GT. 0.0) THEN |
IF ( CountX(j,bj) .GT. 0.0) THEN |
89 |
ZonalMeanSST(j,bj) = ZonalMeanSST(j,bj)/CountX(j,bj) |
ZonalMeanSST(j,bj) = ZonalMeanSST(j,bj)/CountX(j,bj) |
90 |
ENDIF |
ENDIF |