Changeset 13370
- Timestamp:
- 2020-07-31T11:00:33+02:00 (4 years ago)
- Location:
- vendors/AGRIF/dev_r12970_AGRIF_CMEMS/AGRIF_FILES
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
vendors/AGRIF/dev_r12970_AGRIF_CMEMS/AGRIF_FILES/modarrays.F90
r13027 r13370 133 133 ! 134 134 !=================================================================================================== 135 subroutine Agrif_get_var_global_bounds( var, lubglob, nbdim ) 136 !--------------------------------------------------------------------------------------------------- 137 type(Agrif_Variable), intent(in) :: var 135 subroutine Agrif_get_var_global_bounds( var, lubglob, nbdim, pvar ) 136 !--------------------------------------------------------------------------------------------------- 137 type(Agrif_Variable), intent(in) :: var 138 type(Agrif_Variable),optional, intent(in) :: pvar 138 139 integer, dimension(nbdim,2), intent(out) :: lubglob 139 140 integer, intent(in) :: nbdim … … 147 148 ! 148 149 #if !defined AGRIF_MPI 149 call Agrif_get_var_bounds_array(var, lubglob(:,1), lubglob(:,2), nbdim) 150 if (present(pvar)) then 151 call Agrif_get_var_bounds_array(var, lubglob(:,1), lubglob(:,2), nbdim, pvar) 152 else 153 call Agrif_get_var_bounds_array(var, lubglob(:,1), lubglob(:,2), nbdim) 154 endif 150 155 #else 151 call Agrif_get_var_bounds_array(var, lb, ub, nbdim) 156 if (present(pvar)) then 157 call Agrif_get_var_bounds_array(var, lb, ub, nbdim, pvar) 158 else 159 call Agrif_get_var_bounds_array(var, lb, ub, nbdim) 160 endif 152 161 153 162 do i = 1,nbdim … … 171 180 !> Gets the lower and the upper boundaries of a variable, for one particular direction. 172 181 !--------------------------------------------------------------------------------------------------- 173 subroutine Agrif_get_var_bounds ( variable, lower, upper, index ) 174 !--------------------------------------------------------------------------------------------------- 175 type(Agrif_Variable), intent(in) :: variable !< Variable for which we want to extract boundaries 182 ! subroutine Agrif_get_var_bounds 183 ! 184 !> Gets the lower and the upper boundaries of a variable, for one particular direction. 185 !--------------------------------------------------------------------------------------------------- 186 subroutine Agrif_get_var_bounds ( variable, lower, upper, index, pvariable ) 187 !--------------------------------------------------------------------------------------------------- 188 type(Agrif_Variable), intent(in) :: variable !< Variable for which we want to extract boundaries 189 type(Agrif_Variable), optional, intent(in) :: pvariable !< parent Variable for which we want to extract boundaries 176 190 integer, intent(out) :: lower !< Lower bound 177 191 integer, intent(out) :: upper !< Upper bound 178 192 integer, intent(in) :: index !< Direction for wich we want to know the boundaries 179 193 ! 180 lower = variable % lb(index) 181 upper = variable % ub(index) 194 195 196 if (present(pvariable)) then 197 if (variable%root_var%interptab(index) == 'N') then 198 lower = pvariable%lb(index) 199 upper = pvariable%ub(index) 200 endif 201 else 202 lower = variable % lb(index) 203 upper = variable % ub(index) 204 endif 205 182 206 !--------------------------------------------------------------------------------------------------- 183 207 end subroutine Agrif_get_var_bounds … … 189 213 !> Gets the lower and the upper boundaries of a table. 190 214 !--------------------------------------------------------------------------------------------------- 191 subroutine Agrif_get_var_bounds_array ( variable, lower, upper, nbdim ) 192 !--------------------------------------------------------------------------------------------------- 193 type(Agrif_Variable), intent(in) :: variable !< Variable for which we want to extract boundaries 215 subroutine Agrif_get_var_bounds_array ( variable, lower, upper, nbdim, pvariable ) 216 !--------------------------------------------------------------------------------------------------- 217 type(Agrif_Variable), intent(in) :: variable !< Variable for which we want to extract boundaries 218 type(Agrif_Variable), optional, intent(in) :: pvariable !< Parent Variable for which we want to extract boundaries 194 219 integer, dimension(nbdim), intent(out) :: lower !< Lower bounds array 195 220 integer, dimension(nbdim), intent(out) :: upper !< Upper bounds array 196 221 integer, intent(in) :: nbdim !< Numer of dimensions of the variable 197 222 ! 223 integer :: nb 224 198 225 lower = variable % lb(1:nbdim) 199 226 upper = variable % ub(1:nbdim) 227 228 if (present(pvariable)) then 229 do nb=1,nbdim 230 if (variable%root_var%interptab(nb) == 'N') then 231 lower(nb) = pvariable%lb(nb) 232 upper(nb) = pvariable%ub(nb) 233 endif 234 enddo 235 endif 200 236 !--------------------------------------------------------------------------------------------------- 201 237 end subroutine Agrif_get_var_bounds_array -
vendors/AGRIF/dev_r12970_AGRIF_CMEMS/AGRIF_FILES/modbc.F90
r13027 r13370 188 188 END WHERE 189 189 ! 190 call Agrif_get_var_global_bounds(child,lubglob,nbdim )190 call Agrif_get_var_global_bounds(child,lubglob,nbdim,parent) 191 191 ! 192 192 indtruetab(1:nbdim,1,1) = max(indtab(1:nbdim,1,1), lubglob(1:nbdim,1)) … … 229 229 ! 230 230 #if defined AGRIF_MPI 231 call Agrif_get_var_bounds_array(child,lower,upper,nbdim )231 call Agrif_get_var_bounds_array(child,lower,upper,nbdim,parent) 232 232 233 233 do i = 1,nbdim -
vendors/AGRIF/dev_r12970_AGRIF_CMEMS/AGRIF_FILES/modinterp.F90
r13144 r13370 199 199 if (.not.find_list_interp) then 200 200 ! 201 call Agrif_get_var_bounds_array(child, lowerbound, upperbound, nbdim )201 call Agrif_get_var_bounds_array(child, lowerbound, upperbound, nbdim, parent) 202 202 call Agrif_Childbounds(nbdim, lowerbound, upperbound, & 203 203 pttab, petab, Agrif_Procrank, coords, & … … 968 968 end select 969 969 ! 970 call Agrif_get_var_bounds_array(child,lowerbound,upperbound,nbdim )970 call Agrif_get_var_bounds_array(child,lowerbound,upperbound,nbdim,parent) 971 971 972 972 #if defined AGRIF_MPI
Note: See TracChangeset
for help on using the changeset viewer.