ViennaGrid - The Vienna Grid Library
2.1.0
|
00001 #ifndef VIENNAGRID_MESH_DEFAULT_CONFIGS_HPP 00002 #define VIENNAGRID_MESH_DEFAULT_CONFIGS_HPP 00003 00004 /* ======================================================================= 00005 Copyright (c) 2011-2014, Institute for Microelectronics, 00006 Institute for Analysis and Scientific Computing, 00007 TU Wien. 00008 00009 ----------------- 00010 ViennaGrid - The Vienna Grid Library 00011 ----------------- 00012 00013 License: MIT (X11), see file LICENSE in the base directory 00014 ======================================================================= */ 00015 00016 00017 #include "viennagrid/mesh/segmentation.hpp" 00018 #include "viennagrid/mesh/mesh.hpp" 00019 #include "viennagrid/topology/simplex.hpp" 00020 #include "viennagrid/topology/quadrilateral.hpp" 00021 #include "viennagrid/topology/polygon.hpp" 00022 #include "viennagrid/topology/hexahedron.hpp" 00023 #include "viennagrid/topology/plc.hpp" 00024 00029 namespace viennagrid 00030 { 00032 00033 namespace config 00034 { 00036 typedef viennagrid::spatial_point<double, viennagrid::cartesian_cs<1> > point_type_1d; 00038 typedef viennagrid::spatial_point<double, viennagrid::cartesian_cs<2> > point_type_2d; 00040 typedef viennagrid::spatial_point<double, viennagrid::cartesian_cs<3> > point_type_3d; 00041 } 00042 00043 00044 namespace config 00045 { 00047 struct vertex_1d 00048 { 00049 typedef result_of::full_mesh_config< viennagrid::vertex_tag, point_type_1d, viennagrid::pointer_handle_tag >::type type; 00050 }; 00051 00053 struct vertex_2d 00054 { 00055 typedef result_of::full_mesh_config< viennagrid::vertex_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00056 }; 00057 00059 struct vertex_3d 00060 { 00061 typedef result_of::full_mesh_config< viennagrid::vertex_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00062 }; 00063 } 00064 00065 00067 typedef viennagrid::mesh< config::vertex_1d > vertex_1d_mesh; 00069 typedef viennagrid::result_of::segmentation< vertex_1d_mesh >::type vertex_1d_segmentation; 00071 typedef viennagrid::result_of::segment_handle< vertex_1d_segmentation >::type vertex_1d_segment_handle; 00073 typedef viennagrid::result_of::mesh_view< vertex_1d_mesh >::type vertex_1d_view; 00075 typedef viennagrid::result_of::cell<vertex_1d_mesh>::type vertex_1d_cell; 00076 00078 typedef viennagrid::mesh< config::vertex_2d > vertex_2d_mesh; 00080 typedef viennagrid::result_of::segmentation< vertex_2d_mesh >::type vertex_2d_segmentation; 00082 typedef viennagrid::result_of::segment_handle< vertex_2d_segmentation >::type vertex_2d_segment_handle; 00084 typedef viennagrid::result_of::mesh_view< vertex_2d_mesh >::type vertex_2d_view; 00086 typedef viennagrid::result_of::cell<vertex_2d_mesh>::type vertex_2d_cell; 00087 00089 typedef viennagrid::mesh< config::vertex_3d > vertex_3d_mesh; 00091 typedef viennagrid::result_of::segmentation< vertex_3d_mesh >::type vertex_3d_segmentation; 00093 typedef viennagrid::result_of::segment_handle< vertex_3d_segmentation >::type vertex_3d_segment_handle; 00095 typedef viennagrid::result_of::mesh_view< vertex_3d_mesh >::type vertex_3d_view; 00097 typedef viennagrid::result_of::cell<vertex_3d_mesh>::type vertex_3d_cell; 00098 00099 00100 namespace config 00101 { 00102 // topologically 1d meshs (cell type is line) 00103 00105 struct line_1d 00106 { 00107 typedef result_of::full_mesh_config< viennagrid::line_tag, point_type_1d, viennagrid::pointer_handle_tag >::type type; 00108 }; 00109 00111 struct line_2d 00112 { 00113 typedef result_of::full_mesh_config< viennagrid::line_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00114 }; 00115 00117 struct line_3d 00118 { 00119 typedef result_of::full_mesh_config< viennagrid::line_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00120 }; 00121 } 00122 00124 typedef viennagrid::mesh< config::line_1d > line_1d_mesh; 00126 typedef viennagrid::result_of::segmentation< line_1d_mesh >::type line_1d_segmentation; 00128 typedef viennagrid::result_of::segment_handle< line_1d_segmentation >::type line_1d_segment_handle; 00130 typedef viennagrid::result_of::mesh_view< line_1d_mesh >::type line_1d_view; 00132 typedef viennagrid::result_of::cell<line_1d_mesh>::type line_1d_cell; 00133 00135 typedef viennagrid::result_of::cell_only_segmentation< line_1d_mesh >::type cell_only_line_1d_segmentation; 00137 typedef viennagrid::result_of::segment_handle< cell_only_line_1d_segmentation >::type cell_only_line_1d_segment_handle; 00138 00139 00141 typedef viennagrid::mesh< config::line_2d > line_2d_mesh; 00143 typedef viennagrid::result_of::segmentation< line_2d_mesh >::type line_2d_segmentation; 00145 typedef viennagrid::result_of::segment_handle< line_2d_segmentation >::type line_2d_segment_handle; 00147 typedef viennagrid::result_of::mesh_view< line_2d_mesh >::type line_2d_view; 00149 typedef viennagrid::result_of::cell<line_2d_mesh>::type line_2d_cell; 00150 00152 typedef viennagrid::result_of::cell_only_segmentation< line_2d_mesh >::type cell_only_line_2d_segmentation; 00154 typedef viennagrid::result_of::segment_handle< cell_only_line_2d_segmentation >::type cell_only_line_2d_segment_handle; 00155 00156 00158 typedef viennagrid::mesh< config::line_3d > line_3d_mesh; 00160 typedef viennagrid::result_of::segmentation< line_3d_mesh >::type line_3d_segmentation; 00162 typedef viennagrid::result_of::segment_handle< line_3d_segmentation >::type line_3d_segment_handle; 00164 typedef viennagrid::result_of::mesh_view< line_3d_mesh >::type line_3d_view; 00166 typedef viennagrid::result_of::cell<line_3d_mesh>::type line_3d_cell; 00167 00169 typedef viennagrid::result_of::cell_only_segmentation< line_3d_mesh >::type cell_only_line_3d_segmentation; 00171 typedef viennagrid::result_of::segment_handle< cell_only_line_3d_segmentation >::type cell_only_line_3d_segment_handle; 00172 00173 00175 00176 namespace config 00177 { 00178 00180 struct triangular_2d 00181 { 00182 typedef result_of::full_mesh_config< viennagrid::triangle_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00183 }; 00184 00186 struct thin_triangular_2d 00187 { 00188 typedef result_of::thin_mesh_config< viennagrid::triangle_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00189 }; 00190 00191 00193 struct triangular_3d 00194 { 00195 typedef result_of::full_mesh_config< viennagrid::triangle_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00196 }; 00197 00199 struct thin_triangular_3d 00200 { 00201 typedef result_of::thin_mesh_config< viennagrid::triangle_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00202 }; 00203 00205 struct quadrilateral_2d 00206 { 00207 typedef result_of::full_mesh_config< viennagrid::quadrilateral_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00208 }; 00209 00211 struct thin_quadrilateral_2d 00212 { 00213 typedef result_of::thin_mesh_config< viennagrid::quadrilateral_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00214 }; 00215 00217 struct quadrilateral_3d 00218 { 00219 typedef result_of::full_mesh_config< viennagrid::quadrilateral_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00220 }; 00221 00223 struct thin_quadrilateral_3d 00224 { 00225 typedef result_of::thin_mesh_config< viennagrid::quadrilateral_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00226 }; 00227 00229 struct polygonal_2d 00230 { 00231 typedef result_of::full_mesh_config< viennagrid::polygon_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00232 }; 00233 00235 struct polygonal_3d 00236 { 00237 typedef result_of::full_mesh_config< viennagrid::polygon_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00238 }; 00239 00240 // /** @brief A default config for PLCs in 2d, pointer handles are used */ 00241 // struct plc_2d 00242 // { 00243 // typedef result_of::full_mesh_config< viennagrid::plc_tag, point_type_2d, viennagrid::pointer_handle_tag >::type type; 00244 // }; 00245 00247 struct plc_3d 00248 { 00249 typedef result_of::full_mesh_config< viennagrid::plc_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00250 }; 00251 } 00252 00253 00255 typedef viennagrid::mesh< config::triangular_2d > triangular_2d_mesh; 00257 typedef viennagrid::result_of::segmentation< triangular_2d_mesh >::type triangular_2d_segmentation; 00259 typedef viennagrid::result_of::segment_handle< triangular_2d_segmentation >::type triangular_2d_segment_handle; 00261 typedef viennagrid::result_of::mesh_view< triangular_2d_mesh >::type triangular_2d_view; 00263 typedef viennagrid::result_of::cell<triangular_2d_mesh>::type triangular_2d_cell; 00264 00266 typedef viennagrid::mesh< config::thin_triangular_2d > thin_triangular_2d_mesh; 00268 typedef viennagrid::result_of::segmentation< thin_triangular_2d_mesh >::type thin_triangular_2d_segmentation; 00270 typedef viennagrid::result_of::segment_handle< thin_triangular_2d_segmentation >::type thin_triangular_2d_segment_handle; 00272 typedef viennagrid::result_of::mesh_view< thin_triangular_2d_mesh >::type thin_triangular_2d_view; 00274 typedef viennagrid::result_of::cell<thin_triangular_2d_mesh>::type thin_triangular_2d_cell; 00275 00277 typedef viennagrid::result_of::cell_only_segmentation< thin_triangular_2d_mesh >::type thin_cell_only_triangular_2d_segmentation; 00279 typedef viennagrid::result_of::segment_handle< thin_cell_only_triangular_2d_segmentation >::type thin_cell_only_triangular_2d_segment_handle; 00280 00281 00282 00283 00284 00286 typedef viennagrid::mesh< config::triangular_3d > triangular_3d_mesh; 00288 typedef viennagrid::result_of::segmentation< triangular_3d_mesh >::type triangular_3d_segmentation; 00290 typedef viennagrid::result_of::segment_handle< triangular_3d_segmentation >::type triangular_3d_segment_handle; 00292 typedef viennagrid::result_of::oriented_3d_hull_segmentation< triangular_3d_mesh >::type triangular_hull_3d_segmentation; 00294 typedef viennagrid::result_of::segment_handle< triangular_hull_3d_segmentation >::type triangular_hull_3d_segment_handle; 00296 typedef viennagrid::result_of::mesh_view< triangular_3d_mesh >::type triangular_3d_view; 00298 typedef viennagrid::result_of::cell<triangular_3d_mesh>::type triangular_3d_cell; 00299 00300 00301 00303 typedef viennagrid::mesh< config::thin_triangular_3d > thin_triangular_3d_mesh; 00305 typedef viennagrid::result_of::segmentation< thin_triangular_3d_mesh >::type thin_triangular_3d_segmentation; 00307 typedef viennagrid::result_of::segment_handle< thin_triangular_3d_segmentation >::type thin_triangular_3d_segment_handle; 00309 typedef viennagrid::result_of::oriented_3d_hull_segmentation< thin_triangular_3d_mesh >::type thin_triangular_hull_3d_segmentation; 00311 typedef viennagrid::result_of::segment_handle< thin_triangular_hull_3d_segmentation >::type thin_triangular_hull_3d_segment_handle; 00313 typedef viennagrid::result_of::mesh_view< thin_triangular_3d_mesh >::type thin_triangular_3d_view; 00315 typedef viennagrid::result_of::cell<thin_triangular_3d_mesh>::type thin_triangular_3d_cell; 00316 00318 typedef viennagrid::result_of::cell_only_segmentation< thin_triangular_3d_mesh >::type thin_cell_only_triangular_3d_segmentation; 00320 typedef viennagrid::result_of::segment_handle< thin_cell_only_triangular_3d_segmentation >::type thin_cell_only_triangular_3d_segment_handle; 00321 00322 00323 00324 00325 00327 typedef viennagrid::mesh< config::quadrilateral_2d > quadrilateral_2d_mesh; 00329 typedef viennagrid::result_of::segmentation< quadrilateral_2d_mesh >::type quadrilateral_2d_segmentation; 00331 typedef viennagrid::result_of::segment_handle< quadrilateral_2d_segmentation >::type quadrilateral_2d_segment_handle; 00333 typedef viennagrid::result_of::mesh_view< quadrilateral_2d_mesh >::type quadrilateral_2d_view; 00335 typedef viennagrid::result_of::cell<quadrilateral_2d_mesh>::type quadrilateral_2d_cell; 00336 00338 typedef viennagrid::mesh< config::quadrilateral_3d > quadrilateral_3d_mesh; 00340 typedef viennagrid::result_of::segmentation< quadrilateral_3d_mesh >::type quadrilateral_3d_segmentation; 00342 typedef viennagrid::result_of::segment_handle< quadrilateral_3d_segmentation >::type quadrilateral_3d_segment_handle; 00344 typedef viennagrid::result_of::mesh_view< quadrilateral_3d_mesh >::type quadrilateral_3d_view; 00346 typedef viennagrid::result_of::cell<quadrilateral_3d_mesh>::type quadrilateral_3d_cell; 00347 00348 00350 typedef viennagrid::mesh< config::polygonal_2d > polygonal_2d_mesh; 00352 typedef viennagrid::result_of::segmentation< polygonal_2d_mesh >::type polygonal_2d_segmentation; 00354 typedef viennagrid::result_of::segment_handle< polygonal_2d_segmentation >::type polygonal_2d_segment_handle; 00356 typedef viennagrid::result_of::mesh_view< polygonal_2d_mesh >::type polygonal_2d_view; 00358 typedef viennagrid::result_of::cell<polygonal_2d_mesh>::type polygonal_2d_cell; 00359 00361 typedef viennagrid::mesh< config::polygonal_3d > polygonal_3d_mesh; 00363 typedef viennagrid::result_of::segmentation< polygonal_3d_mesh >::type polygonal_3d_segmentation; 00365 typedef viennagrid::result_of::segment_handle< polygonal_3d_segmentation >::type polygonal_3d_segment_handle; 00367 typedef viennagrid::result_of::mesh_view< polygonal_3d_mesh >::type polygonal_3d_view; 00369 typedef viennagrid::result_of::cell<polygonal_3d_mesh>::type polygonal_3d_cell; 00370 00372 typedef viennagrid::mesh< config::plc_3d > plc_3d_mesh; 00374 typedef viennagrid::result_of::segmentation< plc_3d_mesh >::type plc_3d_segmentation; 00376 typedef viennagrid::result_of::segment_handle< plc_3d_segmentation >::type plc_3d_segment_handle; 00378 typedef viennagrid::result_of::mesh_view< plc_3d_mesh >::type plc_3d_view; 00380 typedef viennagrid::result_of::cell<plc_3d_mesh>::type plc_3d_cell; 00381 00382 00383 00385 00386 namespace config 00387 { 00389 struct tetrahedral_3d 00390 { 00391 typedef result_of::full_mesh_config< viennagrid::tetrahedron_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00392 }; 00393 00395 struct thin_tetrahedral_3d 00396 { 00397 typedef result_of::thin_mesh_config< viennagrid::tetrahedron_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00398 }; 00399 00401 struct hexahedral_3d 00402 { 00403 typedef result_of::full_mesh_config< viennagrid::hexahedron_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00404 }; 00405 00407 struct thin_hexahedral_3d 00408 { 00409 typedef result_of::thin_mesh_config< viennagrid::hexahedron_tag, point_type_3d, viennagrid::pointer_handle_tag >::type type; 00410 }; 00411 } 00412 00414 typedef viennagrid::mesh< config::tetrahedral_3d > tetrahedral_3d_mesh; 00416 typedef viennagrid::result_of::segmentation< tetrahedral_3d_mesh >::type tetrahedral_3d_segmentation; 00418 typedef viennagrid::result_of::segment_handle< tetrahedral_3d_segmentation >::type tetrahedral_3d_segment_handle; 00420 typedef viennagrid::result_of::mesh_view< tetrahedral_3d_mesh >::type tetrahedral_3d_view; 00422 typedef viennagrid::result_of::cell<tetrahedral_3d_mesh>::type tetrahedral_3d_cell; 00423 00424 00426 typedef viennagrid::mesh< config::thin_tetrahedral_3d > thin_tetrahedral_3d_mesh; 00428 typedef viennagrid::result_of::segmentation< thin_tetrahedral_3d_mesh >::type thin_tetrahedral_3d_segmentation; 00430 typedef viennagrid::result_of::segment_handle< thin_tetrahedral_3d_segmentation >::type thin_tetrahedral_3d_segment_handle; 00432 typedef viennagrid::result_of::mesh_view< thin_tetrahedral_3d_mesh >::type thin_tetrahedral_3d_view; 00434 typedef viennagrid::result_of::cell<thin_tetrahedral_3d_mesh>::type thin_tetrahedral_3d_cell; 00435 00437 typedef viennagrid::result_of::cell_only_segmentation< thin_tetrahedral_3d_mesh >::type thin_cell_only_tetrahedral_3d_segmentation; 00439 typedef viennagrid::result_of::segment_handle< thin_cell_only_tetrahedral_3d_segmentation >::type thin_cell_only_tetrahedral_3d_segment_handle; 00440 00441 00443 typedef viennagrid::mesh< config::hexahedral_3d > hexahedral_3d_mesh; 00445 typedef viennagrid::result_of::segmentation< hexahedral_3d_mesh >::type hexahedral_3d_segmentation; 00447 typedef viennagrid::result_of::segment_handle< hexahedral_3d_segmentation >::type hexahedral_3d_segment_handle; 00449 typedef viennagrid::result_of::mesh_view< hexahedral_3d_mesh >::type hexahedral_3d_view; 00451 typedef viennagrid::result_of::cell<hexahedral_3d_mesh>::type hexahedral_3d_cell; 00452 00453 00454 00455 00456 00458 typedef vertex_1d_mesh brep_1d_mesh; 00460 typedef vertex_1d_segmentation brep_1d_segmentation; 00462 typedef vertex_1d_segment_handle brep_1d_segment_handle; 00464 typedef vertex_1d_view brep_1d_view; 00466 typedef vertex_1d_cell brep_1d_cell; 00467 00469 typedef line_2d_mesh brep_2d_mesh; 00471 typedef line_2d_segmentation brep_2d_segmentation; 00473 typedef line_2d_segment_handle brep_2d_segment_handle; 00475 typedef line_2d_view brep_2d_view; 00477 typedef line_2d_cell brep_2d_cell; 00478 00480 typedef plc_3d_mesh brep_3d_mesh; 00482 typedef plc_3d_segmentation brep_3d_segmentation; 00484 typedef plc_3d_segment_handle brep_3d_segment_handle; 00486 typedef plc_3d_view brep_3d_view; 00488 typedef plc_3d_cell brep_3d_cell; 00489 } 00490 00491 00492 #endif