Debian Codegraph @

dune/uggrid/domain/std_domain.h

raw
1 // -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
2 // vi: set et ts=4 sw=2 sts=2:
3 // SPDX-FileCopyrightInfo: Copyright © DUNE Project contributors, see file LICENSE.md in module root
4 // SPDX-License-Identifier: LGPL-2.1-or-later
5 /** \defgroup std The Standard Domain
6 * \ingroup dom
7 */
8 /*! \file std_domain.h
9 * \ingroup std
10 */
11
12 /** \addtogroup std
13 *
14 * @{
15 */
16
17 /****************************************************************************/
18 /* */
19 /* File: std_domain.h */
20 /* */
21 /* Purpose: standard domain declaration */
22 /* */
23 /* Author: Peter Bastian/Klaus Johannsen */
24 /* Institut fuer Computeranwendungen III */
25 /* Universitaet Stuttgart */
26 /* Pfaffenwaldring 27 */
27 /* 70550 Stuttgart */
28 /* email: [email protected] */
29 /* */
30 /* History: 29.01.92 begin, ug version 2.0 */
31 /* */
32 /* Remarks: */
33 /* */
34 /****************************************************************************/
35
36
37 /****************************************************************************/
38 /* */
39 /* auto include mechanism and other include files */
40 /* */
41 /****************************************************************************/
42
43 #ifndef __STD_DOMAIN__
44 #define __STD_DOMAIN__
45
46 #include <array>
47 #include <memory>
48
49 #include <dune/uggrid/low/dimension.h>
50 #include <dune/uggrid/low/namespace.h>
51
52 #ifdef ModelP
53 # include <dune/uggrid/parallel/ddd/dddtypes.hh>
54 #endif
55
56 #include <dune/common/fvector.hh>
57
58 #include <dune/uggrid/low/dimension.h>
59 #include <dune/uggrid/low/heaps.h>
60 #include <dune/uggrid/low/namespace.h>
61 #include <dune/uggrid/low/ugenv.h>
62 #include <dune/uggrid/low/ugtypes.h>
63
64 START_UGDIM_NAMESPACE
65
66 /** \brief Status for mesh */
67 enum MeshStatus {MESHSTAT_NOTINIT,
68 MESHSTAT_EMPTY,
69 MESHSTAT_CNODES,
70 MESHSTAT_SURFMESH,
71 MESHSTAT_MESH};
72
73 typedef void *BNDS; /*!< Structure handled by domain module */
74 typedef void *BNDP; /*!< Structure handled by domain module */
75
76 #undef CORNERS_OF_BND_SEG
77 #define CORNERS_OF_BND_SEG 2*DIM_OF_BND
78
79
80 /** \brief Data type of the functions mapping parameter space to world space
81 *
82 * The first argument of type void * is the user data pointer from
83 * the corresponding BOUNDARY_SEGMENT. The second parameter of type DOUBLE *
84 * provides an array containing the parameters where the boundary segment
85 * function should be evaluated (one number in 2D, two numbers in 3D). The
86 * third parameter of type DOUBLE * provides an array where the result can be placed
87 * (x,y values in 2D, x,y,z values in 3D).
88 */
89 typedef INT (*BndSegFuncPtr)(void *,DOUBLE *, FieldVector<DOUBLE,DIM>&);
90
91
92 /** \brief Data structure defining part of the boundary of a domain
93
94 A domain for UG is described as a set of boundary segments defined
95 by the \ref boundary_segment structure. Each boundary segment is a mapping
96 from `d`-1 dimensional parameter space to `d` dimensional Euclidean space.
97 The parameter space is an interval [0,1] in two dimensions or a square
98 [0,1]x[0,1] in three-dimensional applications.
99
100 For all boundary segments the points in `d` dimensional space corresponding to the parameters
101 0 and 1 in two dimensions ((0,0),(0,1),(1,0),(1,1) in three dimensions)
102 are called `corners` of the domain. Locally for each boundary segment the
103 corners are numbered like shown in the figures above.
104 The corners are numbered `globally` in a consecutive way beginning with 0.
105 \warning boundary segments must be defined in such a way that no two
106 corners are identical!
107 */
108 struct boundary_segment
109 {
110 /** \brief Create a new BOUNDARY_SEGMENT
111 *
112 * @param id - id of this boundary segment
113 * @param point - the endpoints of the boundary segment
114 * @param BndSegFunc - function mapping parameters
115 * @param data - user defined space
116 */
117 boundary_segment(INT id,
118 const INT* point,
119 BndSegFuncPtr BndSegFunc,
120 void *data);
121
122 /** \brief Number of the boundary segment beginning with zero */
123 INT id;
124
125 /** \brief Numbers of the vertices (ID)
126 *
127 * Mapping of local numbers of corners to global numbers. Remember, all
128 * global numbers of corners must be different.
129 */
130 INT points[CORNERS_OF_BND_SEG];
131
132 /** \brief Pointer to a function describing the mapping from parameter space to world space
133 */
134 BndSegFuncPtr BndSegFunc;
135
136 /** \brief User defined pointer
137 *
138 * This pointer is passed as the first argument to the BndSegFunc of the segment.
139 * This pointer can be used to construct an interface to geometry data files,
140 * e.g. from a CAD system.
141 */
142 void *data;
143 };
144
145
146 /** \brief Boundary segment with a (multi-)linear geometry
147 */
148 struct linear_segment
149 {
150 /** \brief Constructor
151 *
152 * @param idA id of this boundary segment
153 * @param nA Number of corners
154 * @param point The ids of the vertices that make up the boundary segment
155 * @param xA Coordinates of the vertices
156 */
157 linear_segment(INT idA,
158 INT nA,
159 const INT * point,
160 const std::array<FieldVector<DOUBLE,DIM>, CORNERS_OF_BND_SEG>& xA);
161
162 /** \brief Unique id of that segment */
163 INT id;
164
165 /** \brief Number of corners */
166 INT n;
167
168 /** \brief Numbers of the vertices (ID) */
169 INT points[CORNERS_OF_BND_SEG];
170
171 /** \brief Coordinates */
172 std::array<FieldVector<DOUBLE,DIM>, CORNERS_OF_BND_SEG> x;
173 };
174
175 /** \brief Data type describing a domain
176
177 The \ref domain structure describes a two- or three-dimensional domain (boundary). This geometry
178 information is used by UG when it refines a grid, i.e., complex geometries are approximated
179 better when the grid is refined.
180
181 A domain is made up of one or several `boundary segments` which are defined by the
182 \ref boundary_segment structure. The points where boundary segments join are
183 called corners of the domain. For each corner a \ref node is automatically created.
184 */
185 struct domain
186 {
187 /** \brief Number of boundary segments */
188 INT numOfSegments;
189
190 /** \brief The boundary segments with a parametrization */
191 std::vector<boundary_segment> boundarySegments;
192
193 /** \brief The boundary segments without a parametrization */
194 std::vector<linear_segment> linearSegments;
195
196 /** \brief Number of corner points */
197 INT numOfCorners;
198 };
199
200 /*********************************************/
201 /* Code that was formerly in std_internal.hh */
202 /*********************************************/
203
204 typedef DOUBLE COORD_BND_VECTOR[DIM_OF_BND];
205
206 enum PatchType {POINT_PATCH_TYPE,
207 #ifdef UG_DIM_3
208 LINE_PATCH_TYPE,
209 #endif
210 LINEAR_PATCH_TYPE,
211 PARAMETRIC_PATCH_TYPE};
212
213 /** @name Macros for DOMAIN */
214 /*@{*/
215 #define DOMAIN_NSEGMENT(p) ((p)->numOfSegments)
216 #define DOMAIN_NCORNER(p) ((p)->numOfCorners)
217 /*@}*/
218
219 /** @name Macros for STD_BVP */
220 /*@{*/
221 #define STD_BVP_DOMAIN(p) ((p)->Domain)
222
223 #define STD_BVP_NSIDES(p) ((p)->nsides)
224 #define STD_BVP_SIDEOFFSET(p) ((p)->sideoffset)
225 #define STD_BVP_PATCH(p,i) ((p)->patches[i])
226
227 #define GetSTD_BVP(p) ((STD_BVP *)(p))
228 /*@}*/
229
230 /****************************************************************************/
231 /* */
232 /* macros for patches */
233 /* */
234 /****************************************************************************/
235
236 /** @name Macros for patches */
237 /*@{*/
238 #define PATCH_TYPE(p) (p)->ge.type
239 #define PATCH_ID(p) (p)->ge.id
240 #define POINT_PATCH_N(p) (p)->po.npatches
241 #define POINT_PATCH_PID(p,i) (p)->po.pop[i].patch_id
242 #define POINT_PATCH_CID(p,i) (p)->po.pop[i].corner_id
243 #define LINE_PATCH_C0(p) ((p)->li.c0)
244 #define LINE_PATCH_C1(p) ((p)->li.c1)
245 #define LINE_PATCH_N(p) (p)->li.npatches
246 #define LINE_PATCH_PID(p,i) (p)->li.lop[i].patch_id
247 #define LINE_PATCH_CID0(p,i) (p)->li.lop[i].corner_id[0]
248 #define LINE_PATCH_CID1(p,i) (p)->li.lop[i].corner_id[1]
249 #define PARAM_PATCH_LEFT(p) (p)->pa.left
250 #define PARAM_PATCH_RIGHT(p) (p)->pa.right
251 #define PARAM_PATCH_POINTS(p,i) (p)->pa.points[i]
252 #define PARAM_PATCH_RANGE(p) (p)->pa.range
253 #define PARAM_PATCH_BS(p) (p)->pa.BndSegFunc
254 #define PARAM_PATCH_BSD(p) (p)->pa.bs_data
255 #define LINEAR_PATCH_LEFT(p) (p)->lp.left
256 #define LINEAR_PATCH_RIGHT(p) (p)->lp.right
257 #define LINEAR_PATCH_N(p) (p)->lp.corners
258 #define LINEAR_PATCH_POINTS(p,i) (p)->lp.points[i]
259 #define LINEAR_PATCH_POS(p,i) (p)->lp.pos[i]
260
261 #define BND_PATCH_ID(p) (((BND_PS *)p)->patch_id)
262 #define BND_DATA(p) (((BND_PS *)p)->data)
263 #define BND_N(p) (((BND_PS *)p)->n)
264 #define BND_LOCAL(p,i) (((BND_PS *)p)->local[i])
265 #define BND_SIZE(p) ((((BND_PS *)p)->n-1)*sizeof(COORD_BND_VECTOR)+sizeof(BND_PS))
266 #define M_BNDS_NSIZE(n) (((n)-1)*sizeof(M_BNDP)+sizeof(M_BNDS))
267 #define M_BNDS_SIZE(p) M_BNDS_NSIZE(((M_BNDS *)(p))->n)
268
269 /*@}*/
270
271 /****************************************************************************/
272 /* */
273 /* BoundaryValueProblem data structure */
274 /* */
275 /****************************************************************************/
276 /** \brief ???
277 *
278 * \todo Please doc me!
279 */
280 struct std_BoundaryValueProblem
281 {
282 ~std_BoundaryValueProblem();
283
284 /** \brief Domain pointer */
285 std::unique_ptr<domain> Domain;
286
287 /** \brief File name for boundary infos */
288 char bnd_file[NS_PREFIX NAMESIZE];
289
290 /** \brief File name for meshinfos */
291 char mesh_file[NS_PREFIX NAMESIZE];
292
293 /** @name Boundary description */
294 /*@{*/
295 INT ncorners;
296 INT nsides;
297 INT sideoffset;
298
299 /** \brief list of patches */
300 std::vector<union patch*> patches;
301 /*@}*/
302 };
303
304 /****************************************************************************/
305 /* */
306 /* Patch data structure */
307 /* */
308 /****************************************************************************/
309 /** \brief ???
310 *
311 * \todo Please doc me!
312 */
313 struct generic_patch {
314
315
316 /** \brief Patch type */
317 enum PatchType type;
318
319 /** \brief Unique id used for load/store */
320 INT id;
321 };
322
323 /** \brief ???
324 *
325 * \todo Please doc me!
326 */
327 struct point_on_patch {
328
329 INT patch_id;
330 INT corner_id;
331 };
332 /** \brief ???
333 *
334 * \todo Please doc me!
335 */
336 struct point_patch {
337
338 /** \brief Patch type */
339 enum PatchType type;
340
341 /** \brief Unique id used for load/store */
342 INT id;
343
344 /** \brief Number of patches */
345 INT npatches;
346
347 /** \brief Reference to surface */
348 struct point_on_patch pop[1];
349 };
350
351 #ifdef UG_DIM_3
352 /** \brief ???
353 *
354 * \todo Please doc me!
355 */
356 struct line_on_patch {
357
358 INT patch_id;
359 INT corner_id[2];
360 };
361 /** \brief ???
362 *
363 * \todo Please doc me!
364 */
365 struct line_patch {
366
367 /** \brief Patch type */
368 enum PatchType type;
369
370 /** \brief Unique id used for load/store */
371 INT id;
372
373 /** \brief Number of patches */
374 INT npatches;
375
376 /** \brief Corner 0 of line */
377 INT c0;
378
379 /** \brief Corner 1 of line */
380 INT c1;
381
382 /** \brief Reference to surface */
383 struct line_on_patch lop[1];
384 };
385 #endif
386 /** \brief ???
387 *
388 * \todo Please doc me!
389 */
390 struct linear_patch {
391
392 /** \brief Patch type */
393 enum PatchType type;
394
395 /** \brief Unique id used for load/store */
396 INT id;
397
398 /** \brief Id of left and right subdomain */
399 INT left,right;
400
401 /** \brief Number of corners */
402 INT corners;
403
404 /** \brief Ids of points */
405 INT points[CORNERS_OF_BND_SEG];
406
407 /** \brief Position */
408 DOUBLE pos[CORNERS_OF_BND_SEG][DIM];
409 };
410 /** \brief ???
411 *
412 * \todo Please doc me!
413 */
414 struct parameter_patch {
415
416 /** \brief Patch type */
417 enum PatchType type;
418
419 /** \brief Unique id used for load/store */
420 INT id;
421
422 /** \brief Id of left and right subdomain */
423 INT left,right;
424
425 /** \brief Ids of points */
426 INT points[CORNERS_OF_BND_SEG];
427
428 /** \brief Parameter range
429 *
430 * The range is an axis-aligned rectangle, described by two points
431 * in DIM_OF_BND-dimensional space.
432 */
433 DOUBLE range[2][DIM_OF_BND];
434
435 /** \brief Pointer to definition function */
436 BndSegFuncPtr BndSegFunc;
437
438 /** \brief Can be used by applic to find data */
439 void *bs_data;
440
441 /*@}*/
442 };
443
444 /** \brief ???
445 *
446 * \todo Please doc me!
447 */
448 union patch {
449 struct generic_patch ge;
450 struct point_patch po;
451 struct linear_patch lp;
452 struct parameter_patch pa;
453 #ifdef UG_DIM_3
454 struct line_patch li;
455 #endif
456 } ;
457
458 /** \brief ???
459 *
460 * \todo Please doc me!
461 */
462 struct bnd_ps {
463
464 /** \brief Associated patch */
465 INT patch_id;
466
467 /** \brief E.g. global coordinates, pointers... */
468 void *data;
469
470 /** \brief Number of arguments */
471 INT n;
472
473 /** \brief Parameter range */
474 COORD_BND_VECTOR local[1];
475 };
476
477 /*----------- typedef for structs ------------------------------------------*/
478
479 /* typedefs */
480 #undef DOMAIN
481 typedef struct domain DOMAIN;
482 typedef struct linear_segment LINEAR_SEGMENT;
483 typedef struct boundary_segment BOUNDARY_SEGMENT;
484
485 typedef struct std_BoundaryValueProblem STD_BVP;
486 typedef union patch PATCH;
487 typedef struct point_patch POINT_PATCH;
488 typedef struct line_patch LINE_PATCH;
489 typedef struct linear_patch LINEAR_PATCH;
490 typedef struct parameter_patch PARAMETER_PATCH;
491 typedef struct bnd_ps BND_PS;
492
493
494 /* --- public functions --- */
495
496 /** \brief Access the id of the segment (used by DUNE) */
497 UINT GetBoundarySegmentId(BNDS* boundarySegment);
498
499 /** \todo Please doc me! */
500 struct mesh
501 {
502 /** \brief Status */
503 enum MeshStatus mesh_status;
504
505 /** \brief Number of boundary points */
506 INT nBndP;
507
508 /** \brief List of boundary points */
509 BNDP **theBndPs;
510
511 /** \brief Number of inner nodes */
512 INT nInnP;
513
514 /** \brief Positions of inner nodes */
515 DOUBLE **Position;
516
517 /** \brief Number of boundary sides per subdomain */
518 INT *nSides;
519
520 /** \brief Number of side corners */
521 INT **Side_corners;
522
523 /** \brief Triangle_id for prism */
524 INT **xy_Side;
525
526 /** \brief Corner ids */
527 INT ***Side_corner_ids;
528
529 /** \brief Number of elements per subdomain */
530 INT *nElements;
531
532 /** \brief Number of element corners */
533 INT **Element_corners;
534
535 /** \brief Number of side corners */
536 INT ***Element_corner_ids;
537
538 /** \brief Number of side corners */
539 INT ***nbElements;
540
541 /** \brief Used bitwise: sides on bnd for elem */
542 INT **ElemSideOnBnd;
543
544 /** @name Parallel part */
545 /*@}*/
546 /** \brief Level of vertex NULL if all vertex on level 0 */
547 unsigned char *VertexLevel;
548
549 /** \brief Priority of vertex NULL if all vertex are master */
550 char *VertexPrio;
551
552 /** \brief Level of element in subdomain NULL if all elements on level 0 */
553 char **ElementLevel;
554
555 /** \brief Priority of element in subdomain NULL if all elements are master */
556 char **ElementPrio;
557 /*@}*/
558 };
559 typedef struct mesh MESH;
560
561
562 void Set_Current_BVP(STD_BVP *theBVP);
563
564 /****************************************************************************/
565 /** \brief Initialize a BVP and return a mesh
566 *
567 * @param theHeap - heap
568 * @param MarkKey - use key for temporary memory allocation (do not Mark/Release)
569
570 Function initialize a BVP and returns a mesh.
571 */
572 /****************************************************************************/
573 void BVP_Init (STD_BVP *theBVP, NS_PREFIX HEAP *theHeap, MESH *Mesh, INT MarkKey);
574
575 /****************************************************************************/
576 /** \brief Write command to insert this BNDP
577 *
578 * @param theBndP - BNDP structure
579 * @param data - string to store command
580 * @param max_data_size - maximal datasize to use
581
582 This function writes a command to string which inserts the BNDP.
583
584 * @return <ul>
585 * <li> 0 if ok
586 * <li> 1 if error.
587 * </ul> */
588 /****************************************************************************/
589 INT BNDP_SaveInsertedBndP (BNDP *theBndP, char *data, INT max_data_size);
590
591 /****************************************************************************/
592 /** \brief Return global coordinates of BNDP
593 *
594 * @param theBndP - BNDP structure
595 * @param global - global coordinates
596
597 This function returns global coordinates of BNDP
598
599 * @return <ul>
600 * <li> 0 if ok </li>
601 * <li> 1 if error. </li>
602 * </ul> */
603 /****************************************************************************/
604 INT BNDP_Global (const BNDP *theBndP, Dune::FieldVector<DOUBLE,DIM>& global);
605
606 /****************************************************************************/
607 /** \brief Sets descriptor for BNDP
608 *
609 * @param theBndP - BNDP structure
610 * @param move - movable flag (0: no, 1:yes)
611
612 This function sets the descriptor for a BNDP.
613
614 * @return <ul>
615 * <li> 0 if ok </li>
616 * <li> 1 if error. </li>
617 * </ul> */
618 /****************************************************************************/
619 INT BNDP_BndPDesc (BNDP *theBndP, INT *move);
620
621 /****************************************************************************/
622 /** \brief Sets descriptor for BNDE (boundary edge)
623 *
624 * @param theBndP0 - first BNDP
625 * @param theBndP1 - second BNDP
626
627 This function sets the descriptor for a BNDE.
628
629 * @return <ul>
630 * <li> 0 if ok
631 * <li> 1 if error.
632 * </ul> */
633 /****************************************************************************/
634 INT BNDP_BndEDesc (BNDP *theBndP0, BNDP *theBndP1);
635
636 /****************************************************************************/
637 /** \brief Creates a BNDS from a nb of BNDPs
638 *
639 * @param Heap - heap to allocate from
640 * @param theBndP - Pointer to list of BNDP structures
641 * @param n - Number of BNDPs
642
643 This function creates a BNDS from n BNDPs
644
645 * @return <ul>
646 * <li> pointer </li>
647 * <li> NULL if the points describe an inner side </li>
648 * </ul> */
649 /****************************************************************************/
650 BNDS* BNDP_CreateBndS (NS_PREFIX HEAP *Heap, BNDP **theBndP, INT n);
651
652 /****************************************************************************/
653 /** \brief Sets BNDP from a two of BNDPs
654 *
655 * @param theBndP0 - first BNDP
656 * @param theBndP1 - second BNDP
657 * @param lcoord - local coordinate between P0 and P1 where the BNDP will be created
658
659 This function sets a BNDP from two BNDPs
660
661 * @return <ul>
662 * <li> pointer </li>
663 * <li> NULL if the points describe an inner point </li>
664 * </ul> */
665 /****************************************************************************/
666 BNDP* BNDP_CreateBndP (NS_PREFIX HEAP *Heap, BNDP *theBndP0, BNDP *theBndP1, DOUBLE lcoord);
667
668 /****************************************************************************/
669 /** \brief Dispose a BNDP
670 *
671 * @param Heap - heap
672 * @param theBndP - BNDP
673
674 This function disposes a BNDP
675
676 * @return <ul>
677 * <li> 0 if ok </li>
678 * <li> 1 if error. </li>
679 * </ul> */
680 /****************************************************************************/
681 INT BNDP_Dispose (NS_PREFIX HEAP *Heap, BNDP *theBndP);
682
683 /****************************************************************************/
684 /** \brief Save a BNDP
685 *
686 * @param theBndP - BNDP
687 * @param stream - file
688
689 This function saves a BNDP on a file.
690
691 * @return <ul>
692 * <li> 0 if ok </li>
693 * <li> 1 if error. </li>
694 * </ul> */
695 /****************************************************************************/
696 INT BNDP_SaveBndP (BNDP *theBndP);
697 INT BNDP_SaveBndP_Ext (BNDP *theBndP);
698
699 /****************************************************************************/
700 /** \brief Load a BNDP
701 *
702 * @param theBVP - BVP structure
703 * @param Heap - heap to allocate from
704 * @param stream - file
705
706 This function loads a BNDP with the format given by BVP_SaveBndP and
707 allocates it from the given heap.
708
709 * @return <ul>
710 * <li> 0 if ok </li>
711 * <li> 1 if error. </li>
712 * </ul> */
713 /****************************************************************************/
714 BNDP *BNDP_LoadBndP (STD_BVP *theBVP, NS_PREFIX HEAP *Heap);
715 BNDP *BNDP_LoadBndP_Ext (void);
716
717 /****************************************************************************/
718 /** \brief Sets descriptor for BNDS
719 *
720 * @param theBndS - BNDS structure
721 * @param id - subdomain ID of the element with aBndS
722 * @param nbid - subdomain ID of the neighbour element (across the boundary)
723
724 This function sets the descriptor for a BNDS.
725
726 * @return <ul>
727 * <li> 0 if ok </li>
728 * <li> 1 if error. </li>
729 * </ul>
730 */
731 /****************************************************************************/
732 INT BNDS_BndSDesc (BNDS *theBndS, INT *id, INT *nbid);
733
734 /****************************************************************************/
735 /** \brief Create BNDP on BNDS
736 *
737 * @param Heap - heap to allocate from
738 * @param theBndS - BNDS structure
739 * @param local - local coordinate on BNDS
740
741 This function creates a boundary point (BNDP) on a BNDS
742
743 * @return <ul>
744 * <li> 0 if ok </li>
745 * <li> 1 if error. </li>
746 * </ul> */
747 /****************************************************************************/
748 BNDP* BNDS_CreateBndP (NS_PREFIX HEAP *Heap, BNDS *theBndS, const FieldVector<DOUBLE,DIM_OF_BND>& local);
749
750 /****************************************************************************/
751 /** \brief Dispose BNDS
752 *
753 * @param Heap - heap
754 * @param theBndS - BNDS struct
755
756 This function disposes a BNDS
757
758 * @return <ul>
759 * <li> 0 if ok </li>
760 * <li> 1 if error. </li>
761 * </ul> */
762 /****************************************************************************/
763 INT BNDS_Dispose (NS_PREFIX HEAP *Heap, BNDS *theBndS);
764
765 /****************************************************************************/
766 /** \brief Gets surface ids for a BNDP
767 *
768 * @param aBndP - BNDP structure
769 * @param i - evaluate on patch i
770 * @param n - number of BNDS
771
772 This function returns surface ids of the n surfaces on which
773 the BNDP resides
774
775 * @return surface id
776 */
777 /****************************************************************************/
778 INT BNDP_SurfaceId (BNDP *aBndP, INT *n, INT i);
779
780
781 #ifdef ModelP
782
783 void DomInitParallel (INT TypeBndP, INT TypeBndS);
784 void DomHandlerInit (INT handlerSet);
785
786 void BElementXferBndS (DDD::DDDContext& context, BNDS **bnds, int n, int proc, int prio);
787 void BElementGatherBndS (BNDS **bnds, int n, int cnt, char *data);
788 void BElementScatterBndS (const DDD::DDDContext& context, BNDS **bnds, int n, int cnt, char *data);
789
790 void BVertexXferBndP (DDD::DDDContext& context, BNDP *bndp, int proc, int prio);
791 void BVertexGatherBndP (BNDP *bndp, int cnt, char *data);
792 void BVertexScatterBndP (const DDD::DDDContext& context, BNDP **bndp, int cnt, char *data);
793
794 #endif
795
796 END_UGDIM_NAMESPACE
797
798 /** @} */
799
800 #endif