65
66
69
71# ifdef DISTRIBUTE
73# endif
74
75
76
77 integer, intent(in) :: ng, tile
78 integer, intent(in) :: LBi, UBi, LBj, UBj
79 integer, intent(in) :: IminS, ImaxS, JminS, JmaxS
80
81# ifdef ASSUMED_SHAPE
82 real(r8), intent(inout) :: ad_Zt_avg1(LBi:,LBj:)
83 real(r8), intent(inout) :: ad_zeta(LBi:,LBj:,:)
84
85 real(r8), intent(out) :: ad_zeta_sol(LBi:,LBj:)
86# else
87 real(r8), intent(inout) :: ad_Zt_avg1(LBi:UBi,LBj:UBj)
88 real(r8), intent(inout) :: ad_zeta(LBi:UBi,LBj:UBj,3)
89
90 real(r8), intent(out) :: ad_zeta_sol(LBi:UBi,LBj:UBj)
91# endif
92
93
94
95 integer :: i, j
96
97# include "set_bounds.h"
98
99
100
101
102
103
104
105# ifdef DISTRIBUTE
106
107
108
109
110
111
112
114 & lbi, ubi, lbj, ubj, &
117 & ad_zeta(:,:,1), &
118 & ad_zeta(:,:,2))
119
120# endif
121
123
124
125
126
128 & lbi, ubi, lbj, ubj, &
129 & ad_zeta(:,:,2))
130
131
132
133
135 & lbi, ubi, lbj, ubj, &
136 & ad_zeta(:,:,1))
137 END IF
138
139
140
141
142 DO j=jstrr,jendr
143 DO i=istrr,iendr
144 ad_zeta_sol(i,j)=ad_zeta(i,j,1)+ad_zeta(i,j,2)
145 END DO
146 END DO
147
148 DO j=jstrr,jendr
149 DO i=istrr,iendr
150
151
152
153 ad_zt_avg1(i,j)=ad_zt_avg1(i,j)+ &
154 & ad_zeta(i,j,1)+ad_zeta(i,j,2)
155 ad_zeta(i,j,2)=0.0_r8
156 ad_zeta(i,j,1)=0.0_r8
157 END DO
158 END DO
159
160 RETURN
subroutine ad_exchange_r2d_tile(ng, tile, lbi, ubi, lbj, ubj, ad_a)
logical, dimension(:), allocatable ewperiodic
logical, dimension(:), allocatable nsperiodic
subroutine ad_mp_exchange2d(ng, tile, model, nvar, lbi, ubi, lbj, ubj, nghost, ew_periodic, ns_periodic, ad_a, ad_b, ad_c, ad_d)