dune-alugrid 3.0.0
capabilities.hh
Go to the documentation of this file.
1#ifndef DUNE_ALUGRID_CAPABILITIES_HH
2#define DUNE_ALUGRID_CAPABILITIES_HH
3
4#include <dune/common/version.hh>
5#include <dune/grid/common/capabilities.hh>
7#include <dune/geometry/genericgeometry/topologytypes.hh>
8
14namespace Dune
15{
16
17 namespace Capabilities
18 {
19
20 // Capabilities for ALUGrid
21 // ------------------------
22
26 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype, class Comm >
27 struct hasSingleGeometryType< ALUGrid< dim, dimworld, eltype, refinementtype, Comm > >
28 {
29 static const bool v = true;
30 static const unsigned int topologyId = (eltype == cube) ?
31 GenericGeometry :: CubeTopology< dim > :: type :: id :
32 GenericGeometry :: SimplexTopology< dim > :: type :: id ;
33 };
34
38 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype, class Comm, int cdim >
39 struct hasEntity< ALUGrid< dim, dimworld, eltype, refinementtype, Comm >, cdim >
40 {
41 static const bool v = true;
42 };
43
44#if !DUNE_VERSION_NEWER(DUNE_GRID,3,0)
48 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype >
49 struct isParallel< ALUGrid< dim, dimworld, eltype, refinementtype, ALUGridNoComm > >
50 {
51 static const bool v = false;
52 };
53
57 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype >
58 struct isParallel< ALUGrid< dim, dimworld, eltype, refinementtype, ALUGridMPIComm > >
59 {
60 static const bool v = true;
61 };
62#endif //#if !DUNE_VERSION_NEWER(DUNE_GRID,3,0)
63
67 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype, int codim >
68 struct canCommunicate< ALUGrid< dim, dimworld, eltype, refinementtype, ALUGridNoComm >, codim >
69 {
70 static const bool v = false;
71 };
72
76 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype, int codim >
77 struct canCommunicate< ALUGrid< dim, dimworld, eltype, refinementtype, ALUGridMPIComm >, codim >
78 {
79 static const bool v = true;
80 };
81
85 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype, class Comm >
86 struct isLevelwiseConforming< ALUGrid< dim, dimworld, eltype, refinementtype, Comm > >
87 {
88 static const bool v = refinementtype == nonconforming;
89 };
90
94 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype, class Comm >
95 struct isLeafwiseConforming< ALUGrid< dim, dimworld, eltype, refinementtype, Comm > >
96 {
97 static const bool v = refinementtype == conforming ;
98 };
99
103 template< int dim, int dimworld, ALUGridElementType eltype, ALUGridRefinementType refinementtype, class Comm >
104 struct hasBackupRestoreFacilities< ALUGrid< dim, dimworld, eltype, refinementtype, Comm > >
105 {
106 static const bool v = true;
107 };
108
109 } // end namespace Capabilities
110
111} //end namespace Dune
112
113#endif // #ifdef DUNE_ALUGRID_CAPABILITIES_HH
Definition alu3dinclude.hh:50
Definition alu3dinclude.hh:80
@ cube
use only cube elements (i.e., quadrilaterals or hexahedra)
Definition declaration.hh:19
@ nonconforming
use non-conforming (red) refinement
Definition declaration.hh:26
@ conforming
use conforming bisection refinement
Definition declaration.hh:25
type of class for specialization of serial ALUGrid (No_Comm as communicator)
Definition declaration.hh:31
type of class for specialization of parallel ALUGrid (MPI_Comm as communicator)
Definition declaration.hh:39