Rocstar  1.0
Rocstar multiphysics simulation application
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
RFLO_ExchangeDnodeSend.F90
Go to the documentation of this file.
1 ! *********************************************************************
2 ! * Rocstar Simulation Suite *
3 ! * Copyright@2015, Illinois Rocstar LLC. All rights reserved. *
4 ! * *
5 ! * Illinois Rocstar LLC *
6 ! * Champaign, IL *
7 ! * www.illinoisrocstar.com *
8 ! * sales@illinoisrocstar.com *
9 ! * *
10 ! * License: See LICENSE file in top level of distribution package or *
11 ! * http://opensource.org/licenses/NCSA *
12 ! *********************************************************************
13 ! *********************************************************************
14 ! * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, *
15 ! * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES *
16 ! * OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND *
17 ! * NONINFRINGEMENT. IN NO EVENT SHALL THE CONTRIBUTORS OR *
18 ! * COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER *
19 ! * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, *
20 ! * Arising FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE *
21 ! * USE OR OTHER DEALINGS WITH THE SOFTWARE. *
22 ! *********************************************************************
23 !******************************************************************************
24 !
25 ! Purpose: send node movement of an interface to the adjacent region
26 ! which is on another processor.
27 !
28 ! Description: none.
29 !
30 ! Input: region = current region
31 ! regionSrc = region to send data to
32 ! patch = current patch of region
33 ! dNode = node movement of current region.
34 !
35 ! Output: patch%mixt%sendBuff = send buffer.
36 !
37 ! Notes: operation carried out for the finest grid only. Intended for
38 ! conforming grid boundaries (also periodic) only.
39 !
40 !******************************************************************************
41 !
42 ! $Id: RFLO_ExchangeDnodeSend.F90,v 1.4 2008/12/06 08:44:06 mtcampbe Exp $
43 !
44 ! Copyright: (c) 2003 by the University of Illinois
45 !
46 !******************************************************************************
47 
48 SUBROUTINE rflo_exchangednodesend( region,regionSrc,patch,dNode )
49 
50  USE moddatatypes
51  USE modbndpatch, ONLY : t_patch
52  USE moddatastruct, ONLY : t_region
53  USE modglobal, ONLY : t_global
55  USE moderror
56  USE modmpi
57  USE modparameters
58  IMPLICIT NONE
59 
60 #include "Indexing.h"
61 
62 ! ... parameters
63  REAL(RFREAL), POINTER :: dnode(:,:)
64 
65  TYPE(t_region) :: region, regionsrc
66  TYPE(t_patch) :: patch
67 
68 ! ... loop variables
69  INTEGER :: i, j, k, ijkbuff
70 
71 ! ... local variables
72  INTEGER :: bctype, ibeg, iend, jbeg, jend, kbeg, kend, inoff, ijnoff, ijkn, &
73  ijknb, n1, n2, ndim, dest, tag, request, ibnd, jbnd, kbnd
74  INTEGER :: lb, l1srcdir, l2srcdir, l1beg, l1end, l1step, l2beg, l2end, l2step
75 
76  LOGICAL :: align
77 
78  REAL(RFREAL) :: v1(3), v2(3)
79  REAL(RFREAL), POINTER :: xyz(:,:)
80 
81  TYPE(t_global), POINTER :: global
82 
83 !******************************************************************************
84 
85  global => region%global
86 
87  CALL registerfunction( global,'RFLO_ExchangeDnodeSend',&
88  'RFLO_ExchangeDnodeSend.F90' )
89 
90 ! check if the source region is active
91 
92  IF (regionsrc%active == off) THEN
93  CALL errorstop( global,err_srcregion_off,&
94  __line__ )
95  ENDIF
96 
97 ! get dimensions and pointers
98 
99  CALL rflo_getpatchindicesnodes( region,patch,1,ibeg,iend, &
100  jbeg,jend,kbeg,kend )
101  CALL rflo_getnodeoffset( region,1,inoff,ijnoff )
102 
103  xyz => region%levels(1)%gridOld%xyz
104 
105  n1 = abs(patch%l1end-patch%l1beg) + 2 ! here, dimensions of current
106  n2 = abs(patch%l2end-patch%l2beg) + 2 ! and source patch are identical
107  ndim = n1*n2
108 
109  lb = patch%lbound
110  align = patch%align
111  bctype = patch%bcType
112 
113 ! mapping between patches
114 
115  l1srcdir = 1
116  IF (patch%srcL1beg > patch%srcL1end) THEN
117  l1srcdir = -1
118  ELSE IF (patch%srcL1beg == patch%srcL1end) THEN
119  IF (lb==1 .OR. lb==2) THEN
120  IF (align) THEN
121  v2(:) = xyz(:,indijk(ibeg,jend,kbeg,inoff,ijnoff)) - &
122  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
123  ELSE
124  v2(:) = xyz(:,indijk(ibeg,jbeg,kend,inoff,ijnoff)) - &
125  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
126  ENDIF
127  ELSE IF (lb==3 .OR. lb==4) THEN
128  IF (align) THEN
129  v2(:) = xyz(:,indijk(ibeg,jbeg,kend,inoff,ijnoff)) - &
130  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
131  ELSE
132  v2(:) = xyz(:,indijk(iend,jbeg,kbeg,inoff,ijnoff)) - &
133  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
134  ENDIF
135  ELSE IF (lb==5 .OR. lb==6) THEN
136  IF (align) THEN
137  v2(:) = xyz(:,indijk(iend,jbeg,kbeg,inoff,ijnoff)) - &
138  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
139  ELSE
140  v2(:) = xyz(:,indijk(ibeg,jend,kbeg,inoff,ijnoff)) - &
141  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
142  ENDIF
143  ENDIF
144  v1(:) = patch%l1VecSrc(:)
145  IF (dot_product(v1,v2) < 0._rfreal) l1srcdir = -1
146  ENDIF
147 
148  l2srcdir = 1
149  IF (patch%srcL2beg > patch%srcL2end) THEN
150  l2srcdir = -1
151  ELSE IF (patch%srcL2beg == patch%srcL2end) THEN
152  IF (lb==1 .OR. lb==2) THEN
153  IF (align) THEN
154  v2(:) = xyz(:,indijk(ibeg,jbeg,kend,inoff,ijnoff)) - &
155  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
156  ELSE
157  v2(:) = xyz(:,indijk(ibeg,jend,kbeg,inoff,ijnoff)) - &
158  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
159  ENDIF
160  ELSE IF (lb==3 .OR. lb==4) THEN
161  IF (align) THEN
162  v2(:) = xyz(:,indijk(iend,jbeg,kbeg,inoff,ijnoff)) - &
163  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
164  ELSE
165  v2(:) = xyz(:,indijk(ibeg,jbeg,kend,inoff,ijnoff)) - &
166  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
167  ENDIF
168  ELSE IF (lb==5 .OR. lb==6) THEN
169  IF (align) THEN
170  v2(:) = xyz(:,indijk(ibeg,jend,kbeg,inoff,ijnoff)) - &
171  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
172  ELSE
173  v2(:) = xyz(:,indijk(iend,jbeg,kbeg,inoff,ijnoff)) - &
174  xyz(:,indijk(ibeg,jbeg,kbeg,inoff,ijnoff))
175  ENDIF
176  ENDIF
177  v1(:) = patch%l2VecSrc(:)
178  IF (dot_product(v1,v2) < 0._rfreal) l2srcdir = -1
179  ENDIF
180 
181 ! loop over interior nodes of current patch -----------------------------------
182 
183  ijkbuff = 0
184 
185 ! face i=const.
186 
187  IF (lb==1 .OR. lb==2) THEN
188 
189  IF (lb == 1) THEN
190  i = ibeg
191  ibnd = ibeg
192  ELSE IF (lb == 2) THEN
193  i = iend
194  ibnd = iend
195  ENDIF
196 
197  IF (align) THEN
198  IF (l1srcdir > 0) THEN
199  l1beg = jbeg
200  l1end = jend
201  ELSE
202  l1beg = jend
203  l1end = jbeg
204  ENDIF
205  l1step = l1srcdir
206  IF (l2srcdir > 0) THEN
207  l2beg = kbeg
208  l2end = kend
209  ELSE
210  l2beg = kend
211  l2end = kbeg
212  ENDIF
213  l2step = l2srcdir
214  IF ((bctype>=bc_regionconf .AND. bctype<=bc_regionconf+bc_range) .OR. &
215  (bctype>=bc_rot_peri .AND. bctype<=bc_rot_peri +bc_range) .OR. &
216  (bctype>=bc_tra_peri .AND. bctype<=bc_tra_peri +bc_range)) THEN
217  DO k=l2beg,l2end,l2step
218  DO j=l1beg,l1end,l1step
219  ijkn = indijk(i,j,k,inoff,ijnoff)
220  ijkbuff = ijkbuff + 1
221  patch%mixt%sendBuff(ijkbuff ) = dnode(xcoord,ijkn)
222  patch%mixt%sendBuff(ijkbuff+ ndim) = dnode(ycoord,ijkn)
223  patch%mixt%sendBuff(ijkbuff+2*ndim) = dnode(zcoord,ijkn)
224  ENDDO
225  ENDDO
226  ENDIF
227  ELSE ! not aligned
228  IF (l1srcdir > 0) THEN
229  l1beg = kbeg
230  l1end = kend
231  ELSE
232  l1beg = kend
233  l1end = kbeg
234  ENDIF
235  l1step = l1srcdir
236  IF (l2srcdir > 0) THEN
237  l2beg = jbeg
238  l2end = jend
239  ELSE
240  l2beg = jend
241  l2end = jbeg
242  ENDIF
243  l2step = l2srcdir
244  IF ((bctype>=bc_regionconf .AND. bctype<=bc_regionconf+bc_range) .OR. &
245  (bctype>=bc_rot_peri .AND. bctype<=bc_rot_peri +bc_range) .OR. &
246  (bctype>=bc_tra_peri .AND. bctype<=bc_tra_peri +bc_range)) THEN
247  DO j=l2beg,l2end,l2step
248  DO k=l1beg,l1end,l1step
249  ijkn = indijk(i,j,k,inoff,ijnoff)
250  ijkbuff = ijkbuff + 1
251  patch%mixt%sendBuff(ijkbuff ) = dnode(xcoord,ijkn)
252  patch%mixt%sendBuff(ijkbuff+ ndim) = dnode(ycoord,ijkn)
253  patch%mixt%sendBuff(ijkbuff+2*ndim) = dnode(zcoord,ijkn)
254  ENDDO
255  ENDDO
256  ENDIF
257  ENDIF ! align
258 
259 ! face j=const.
260 
261  ELSE IF (lb==3 .OR. lb==4) THEN
262 
263  IF (lb == 3) THEN
264  j = jbeg
265  jbnd = jbeg
266  ELSE IF (lb == 4) THEN
267  j = jend
268  jbnd = jend
269  ENDIF
270 
271  IF (align) THEN
272  IF (l1srcdir > 0) THEN
273  l1beg = kbeg
274  l1end = kend
275  ELSE
276  l1beg = kend
277  l1end = kbeg
278  ENDIF
279  l1step = l1srcdir
280  IF (l2srcdir > 0) THEN
281  l2beg = ibeg
282  l2end = iend
283  ELSE
284  l2beg = iend
285  l2end = ibeg
286  ENDIF
287  l2step = l2srcdir
288  IF ((bctype>=bc_regionconf .AND. bctype<=bc_regionconf+bc_range) .OR. &
289  (bctype>=bc_rot_peri .AND. bctype<=bc_rot_peri +bc_range) .OR. &
290  (bctype>=bc_tra_peri .AND. bctype<=bc_tra_peri +bc_range)) THEN
291  DO i=l2beg,l2end,l2step
292  DO k=l1beg,l1end,l1step
293  ijkn = indijk(i,j,k,inoff,ijnoff)
294  ijkbuff = ijkbuff + 1
295  patch%mixt%sendBuff(ijkbuff ) = dnode(xcoord,ijkn)
296  patch%mixt%sendBuff(ijkbuff+ ndim) = dnode(ycoord,ijkn)
297  patch%mixt%sendBuff(ijkbuff+2*ndim) = dnode(zcoord,ijkn)
298  ENDDO
299  ENDDO
300  ENDIF
301  ELSE ! not aligned
302  IF (l1srcdir > 0) THEN
303  l1beg = ibeg
304  l1end = iend
305  ELSE
306  l1beg = iend
307  l1end = ibeg
308  ENDIF
309  l1step = l1srcdir
310  IF (l2srcdir > 0) THEN
311  l2beg = kbeg
312  l2end = kend
313  ELSE
314  l2beg = kend
315  l2end = kbeg
316  ENDIF
317  l2step = l2srcdir
318  IF ((bctype>=bc_regionconf .AND. bctype<=bc_regionconf+bc_range) .OR. &
319  (bctype>=bc_rot_peri .AND. bctype<=bc_rot_peri +bc_range) .OR. &
320  (bctype>=bc_tra_peri .AND. bctype<=bc_tra_peri +bc_range)) THEN
321  DO k=l2beg,l2end,l2step
322  DO i=l1beg,l1end,l1step
323  ijkn = indijk(i,j,k,inoff,ijnoff)
324  ijkbuff = ijkbuff + 1
325  patch%mixt%sendBuff(ijkbuff ) = dnode(xcoord,ijkn)
326  patch%mixt%sendBuff(ijkbuff+ ndim) = dnode(ycoord,ijkn)
327  patch%mixt%sendBuff(ijkbuff+2*ndim) = dnode(zcoord,ijkn)
328  ENDDO
329  ENDDO
330  ENDIF
331  ENDIF ! align
332 
333 ! face k=const.
334 
335  ELSE IF (lb==5 .OR. lb==6) THEN
336 
337  IF (lb == 5) THEN
338  k = kbeg
339  kbnd = kbeg
340  ELSE IF (lb == 6) THEN
341  k = kend
342  kbnd = kend
343  ENDIF
344 
345  IF (align) THEN
346  IF (l1srcdir > 0) THEN
347  l1beg = ibeg
348  l1end = iend
349  ELSE
350  l1beg = iend
351  l1end = ibeg
352  ENDIF
353  l1step = l1srcdir
354  IF (l2srcdir > 0) THEN
355  l2beg = jbeg
356  l2end = jend
357  ELSE
358  l2beg = jend
359  l2end = jbeg
360  ENDIF
361  l2step = l2srcdir
362  IF ((bctype>=bc_regionconf .AND. bctype<=bc_regionconf+bc_range) .OR. &
363  (bctype>=bc_rot_peri .AND. bctype<=bc_rot_peri +bc_range) .OR. &
364  (bctype>=bc_tra_peri .AND. bctype<=bc_tra_peri +bc_range)) THEN
365  DO j=l2beg,l2end,l2step
366  DO i=l1beg,l1end,l1step
367  ijkn = indijk(i,j,k,inoff,ijnoff)
368  ijkbuff = ijkbuff + 1
369  patch%mixt%sendBuff(ijkbuff ) = dnode(xcoord,ijkn)
370  patch%mixt%sendBuff(ijkbuff+ ndim) = dnode(ycoord,ijkn)
371  patch%mixt%sendBuff(ijkbuff+2*ndim) = dnode(zcoord,ijkn)
372  ENDDO
373  ENDDO
374  ENDIF
375  ELSE ! not aligned
376  IF (l1srcdir > 0) THEN
377  l1beg = jbeg
378  l1end = jend
379  ELSE
380  l1beg = jend
381  l1end = jbeg
382  ENDIF
383  l1step = l1srcdir
384  IF (l2srcdir > 0) THEN
385  l2beg = ibeg
386  l2end = iend
387  ELSE
388  l2beg = iend
389  l2end = ibeg
390  ENDIF
391  l2step = l2srcdir
392  IF ((bctype>=bc_regionconf .AND. bctype<=bc_regionconf+bc_range) .OR. &
393  (bctype>=bc_rot_peri .AND. bctype<=bc_rot_peri +bc_range) .OR. &
394  (bctype>=bc_tra_peri .AND. bctype<=bc_tra_peri +bc_range)) THEN
395  DO i=l2beg,l2end,l2step
396  DO j=l1beg,l1end,l1step
397  ijkn = indijk(i,j,k,inoff,ijnoff)
398  ijkbuff = ijkbuff + 1
399  patch%mixt%sendBuff(ijkbuff ) = dnode(xcoord,ijkn)
400  patch%mixt%sendBuff(ijkbuff+ ndim) = dnode(ycoord,ijkn)
401  patch%mixt%sendBuff(ijkbuff+2*ndim) = dnode(zcoord,ijkn)
402  ENDDO
403  ENDDO
404  ENDIF
405  ENDIF ! align
406 
407  ENDIF ! lb
408 
409 ! send data -------------------------------------------------------------------
410 
411 #ifdef MPI
412  dest = regionsrc%procid
413  tag = regionsrc%localNumber + mpi_patchoff*patch%srcPatch
414  CALL mpi_isend( patch%mixt%sendBuff,3*ndim,mpi_rfreal,dest,tag, &
415  global%mpiComm,global%requests(patch%mixt%iRequest), &
416  global%mpierr )
417  IF (global%mpierr /= 0) CALL errorstop( global,err_mpi_trouble,&
418  __line__ )
419 #endif
420 
421 ! finalize --------------------------------------------------------------------
422 
423  CALL deregisterfunction( global )
424 
425 END SUBROUTINE rflo_exchangednodesend
426 
427 !******************************************************************************
428 !
429 ! RCS Revision history:
430 !
431 ! $Log: RFLO_ExchangeDnodeSend.F90,v $
432 ! Revision 1.4 2008/12/06 08:44:06 mtcampbe
433 ! Updated license.
434 !
435 ! Revision 1.3 2008/11/19 22:17:20 mtcampbe
436 ! Added Illinois Open Source License/Copyright
437 !
438 ! Revision 1.2 2006/08/19 15:38:04 mparmar
439 ! Renamed patch variables
440 !
441 ! Revision 1.1 2004/11/29 21:25:16 wasistho
442 ! lower to upper case
443 !
444 ! Revision 1.5 2003/11/20 16:40:34 mdbrandy
445 ! Backing out RocfluidMP changes from 11-17-03
446 !
447 ! Revision 1.2 2003/05/15 02:57:01 jblazek
448 ! Inlined index function.
449 !
450 ! Revision 1.1 2003/03/14 22:05:10 jblazek
451 ! Improved mesh motion algorithm - node movement exchaged between blocks.
452 !
453 !******************************************************************************
454 
455 
456 
457 
458 
459 
460 
**********************************************************************Rocstar Simulation Suite Illinois Rocstar LLC All rights reserved ****Illinois Rocstar LLC IL **www illinoisrocstar com **sales illinoisrocstar com WITHOUT WARRANTY OF ANY **EXPRESS OR INCLUDING BUT NOT LIMITED TO THE WARRANTIES **OF FITNESS FOR A PARTICULAR PURPOSE AND **NONINFRINGEMENT IN NO EVENT SHALL THE CONTRIBUTORS OR **COPYRIGHT HOLDERS BE LIABLE FOR ANY DAMAGES OR OTHER WHETHER IN AN ACTION OF TORT OR **Arising OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE **USE OR OTHER DEALINGS WITH THE SOFTWARE **********************************************************************INTERFACE SUBROUTINE ibeg
j indices k indices k
Definition: Indexing.h:6
subroutine registerfunction(global, funName, fileName)
Definition: ModError.F90:449
subroutine rflo_getnodeoffset(region, iLev, iNodeOffset, ijNodeOffset)
Definition: patch.h:74
**********************************************************************Rocstar Simulation Suite Illinois Rocstar LLC All rights reserved ****Illinois Rocstar LLC IL **www illinoisrocstar com **sales illinoisrocstar com WITHOUT WARRANTY OF ANY **EXPRESS OR INCLUDING BUT NOT LIMITED TO THE WARRANTIES **OF FITNESS FOR A PARTICULAR PURPOSE AND **NONINFRINGEMENT IN NO EVENT SHALL THE CONTRIBUTORS OR **COPYRIGHT HOLDERS BE LIABLE FOR ANY DAMAGES OR OTHER WHETHER IN AN ACTION OF TORT OR **Arising OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE **USE OR OTHER DEALINGS WITH THE SOFTWARE **********************************************************************INTERFACE SUBROUTINE knode iend
subroutine rflo_getpatchindicesnodes(region, patch, iLev, ibeg, iend, jbeg, jend, kbeg, kend)
blockLoc i
Definition: read.cpp:79
j indices j
Definition: Indexing.h:6
**********************************************************************Rocstar Simulation Suite Illinois Rocstar LLC All rights reserved ****Illinois Rocstar LLC IL **www illinoisrocstar com **sales illinoisrocstar com WITHOUT WARRANTY OF ANY **EXPRESS OR INCLUDING BUT NOT LIMITED TO THE WARRANTIES **OF FITNESS FOR A PARTICULAR PURPOSE AND **NONINFRINGEMENT IN NO EVENT SHALL THE CONTRIBUTORS OR **COPYRIGHT HOLDERS BE LIABLE FOR ANY DAMAGES OR OTHER WHETHER IN AN ACTION OF TORT OR **Arising OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE **USE OR OTHER DEALINGS WITH THE SOFTWARE **********************************************************************INTERFACE SUBROUTINE knode jend
subroutine errorstop(global, errorCode, errorLine, addMessage)
Definition: ModError.F90:483
**********************************************************************Rocstar Simulation Suite Illinois Rocstar LLC All rights reserved ****Illinois Rocstar LLC IL **www illinoisrocstar com **sales illinoisrocstar com WITHOUT WARRANTY OF ANY **EXPRESS OR INCLUDING BUT NOT LIMITED TO THE WARRANTIES **OF FITNESS FOR A PARTICULAR PURPOSE AND **NONINFRINGEMENT IN NO EVENT SHALL THE CONTRIBUTORS OR **COPYRIGHT HOLDERS BE LIABLE FOR ANY DAMAGES OR OTHER WHETHER IN AN ACTION OF TORT OR **Arising OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE **USE OR OTHER DEALINGS WITH THE SOFTWARE **********************************************************************INTERFACE SUBROUTINE knode jbeg
long double dot_product(pnt vec1, pnt vec2)
**********************************************************************Rocstar Simulation Suite Illinois Rocstar LLC All rights reserved ****Illinois Rocstar LLC IL **www illinoisrocstar com **sales illinoisrocstar com WITHOUT WARRANTY OF ANY **EXPRESS OR INCLUDING BUT NOT LIMITED TO THE WARRANTIES **OF FITNESS FOR A PARTICULAR PURPOSE AND **NONINFRINGEMENT IN NO EVENT SHALL THE CONTRIBUTORS OR **COPYRIGHT HOLDERS BE LIABLE FOR ANY DAMAGES OR OTHER WHETHER IN AN ACTION OF TORT OR **Arising OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE **USE OR OTHER DEALINGS WITH THE SOFTWARE **********************************************************************INTERFACE SUBROUTINE knode kbeg
subroutine deregisterfunction(global)
Definition: ModError.F90:469
subroutine rflo_exchangednodesend(region, regionSrc, patch, dNode)