dune-grid
2.2.0
|
00001 #ifndef DUNE_ALU2DGRID_CAPABILITIES_HH 00002 #define DUNE_ALU2DGRID_CAPABILITIES_HH 00003 00004 // only include this code, if ENABLE_ALUGRID is defined 00005 #ifdef ENABLE_ALUGRID 00006 00007 #include <dune/geometry/genericgeometry/topologytypes.hh> 00008 00009 #include <dune/grid/alugrid/common/declaration.hh> 00010 #include <dune/grid/alugrid/2d/alu2dinclude.hh> 00011 #include <dune/grid/common/capabilities.hh> 00012 00013 00019 namespace Dune 00020 { 00021 00022 template< int dim, int dimworld > 00023 class ALUSimplexGrid; 00024 00025 template< int dim, int dimw > 00026 class ALUCubeGrid; 00027 00028 template< int dim, int dimworld > 00029 class ALUConformGrid; 00030 00031 00032 00033 namespace Capabilities 00034 { 00035 00036 00037 // Capabilities for ALUSimplexGrid 00038 // ------------------------------- 00039 00043 template< int dimworld > 00044 struct hasSingleGeometryType< ALUSimplexGrid< 2, dimworld > > 00045 { 00046 static const bool v = true; 00047 static const unsigned int topologyId = GenericGeometry :: SimplexTopology< 2 > :: type :: id ; 00048 }; 00049 00050 00054 template< int dimworld, int cdim > 00055 struct hasEntity< ALUSimplexGrid< 2, dimworld >, cdim > 00056 { 00057 static const bool v = true; 00058 }; 00059 00060 #if ALU2DGRID_PARALLEL 00061 00064 //- default is false 00065 template< int dimworld > 00066 struct isParallel< ALUSimplexGrid< 2, dimworld > > 00067 { 00068 static const bool v = true; 00069 }; 00070 #endif // #if ALU2DGRID_PARALLEL 00071 00072 #if ALU2DGRID_PARALLEL 00073 00076 //- default is false 00077 template< int dimworld > 00078 struct canCommunicate< ALUSimplexGrid< 2, dimworld >, 0 > 00079 { 00080 static const bool v = true; 00081 }; 00082 #endif // #if ALU2DGRID_PARALLEL 00083 00087 template< int dimworld > 00088 struct isLevelwiseConforming< ALUSimplexGrid< 2, dimworld > > 00089 { 00090 static const bool v = true; 00091 }; 00092 00096 template< int dimworld > 00097 struct hasBackupRestoreFacilities< ALUSimplexGrid< 2, dimworld > > 00098 { 00099 static const bool v = true; 00100 }; 00101 00102 00103 00104 // Capabilities for ALUCubeGrid 00105 // ---------------------------- 00106 00110 template< int wdim > 00111 struct hasSingleGeometryType< ALUCubeGrid< 2, wdim > > 00112 { 00113 static const bool v = true; 00114 static const unsigned int topologyId = GenericGeometry :: CubeTopology< 2 > :: type :: id ; 00115 }; 00116 00120 template< int wdim, int cdim > 00121 struct hasEntity< Dune::ALUCubeGrid< 2, wdim >, cdim > 00122 { 00123 static const bool v = true; 00124 }; 00125 00126 #if ALU2DGRID_PARALLEL 00127 00130 //- default is false 00131 template< int dimworld > 00132 struct isParallel< ALUCubeGrid< 2, dimworld > > 00133 { 00134 static const bool v = true; 00135 }; 00136 #endif // #if ALU2DGRID_PARALLEL 00137 00138 #if ALU2DGRID_PARALLEL 00139 00142 //- default is false 00143 template< int dimworld > 00144 struct canCommunicate< ALUCubeGrid< 2, dimworld >, 0 > 00145 { 00146 static const bool v = true; 00147 }; 00148 #endif // #if ALU2DGRID_PARALLEL 00149 00153 template<int wdim> 00154 struct isLevelwiseConforming< Dune::ALUCubeGrid< 2, wdim > > 00155 { 00156 static const bool v = true; 00157 }; 00158 00162 template<int wdim> 00163 struct hasBackupRestoreFacilities< Dune::ALUCubeGrid< 2, wdim > > 00164 { 00165 static const bool v = true; 00166 }; 00167 00168 00169 00170 // Capabilities for ALUConformGrid 00171 // ------------------------------- 00172 00176 template< int dimworld > 00177 struct hasSingleGeometryType< ALUConformGrid< 2, dimworld > > 00178 { 00179 static const bool v = true; 00180 static const unsigned int topologyId = GenericGeometry :: SimplexTopology< 2 > :: type :: id ; 00181 }; 00182 00186 template< int dimworld, int cdim > 00187 struct hasEntity< ALUConformGrid< 2, dimworld >, cdim > 00188 { 00189 static const bool v = true; 00190 }; 00191 00192 #if ALU2DGRID_PARALLEL 00193 00196 //- default is false 00197 template< int dimworld > 00198 struct isParallel< ALUConformGrid< 2, dimworld > > 00199 { 00200 static const bool v = true; 00201 }; 00202 #endif // #if ALU2DGRID_PARALLEL 00203 00204 #if ALU2DGRID_PARALLEL 00205 00208 //- default is false 00209 template< int dimworld > 00210 struct canCommunicate< ALUConformGrid< 2, dimworld >, 0 > 00211 { 00212 static const bool v = true; 00213 }; 00214 #endif // #if ALU2DGRID_PARALLEL 00215 00219 template< int dimworld > 00220 struct isLeafwiseConforming< ALUConformGrid< 2, dimworld > > 00221 { 00222 static const bool v = true; 00223 }; 00224 00228 template< int dimworld > 00229 struct hasBackupRestoreFacilities< ALUConformGrid< 2, dimworld > > 00230 { 00231 static const bool v = true; 00232 }; 00233 00234 } // namespace Capabilities 00235 00236 } // namespace Dune 00237 00238 #endif // #ifdef ENABLE_ALUGRID 00239 00240 #endif // #ifndef DUNE_ALU2DGRID_CAPABILITIES_HH