ViennaGrid - The Vienna Grid Library  2.1.0
Data Structures | Namespaces | Functions
viennagrid/algorithm/voronoi.hpp File Reference

Computes the Voronoi information for a Delaunay triangulation. More...

#include <iostream>
#include <sstream>
#include <string>
#include <stdexcept>
#include "viennagrid/forwards.hpp"
#include "viennagrid/mesh/segmentation.hpp"
#include "viennagrid/mesh/coboundary_iteration.hpp"
#include "viennagrid/algorithm/circumcenter.hpp"
#include "viennagrid/algorithm/spanned_volume.hpp"
#include "viennagrid/algorithm/volume.hpp"
#include "viennagrid/algorithm/inner_prod.hpp"

Go to the source code of this file.

Data Structures

struct  voronoi_cell_contribution< ConstCellHandleT >
 Returns the internal type used for the individual Voronoi quantity contributions. More...

Namespaces

namespace  viennagrid
 

The main ViennaGrid namespace. Most user functionality resides directly in this namespace rather than in sub-namespaces.


namespace  viennagrid::detail
 

Namespace for implementation details. Not intended to be used directly by a library user.


namespace  viennagrid::result_of
 

The metafunction layer. Provides type generators that derive the respective type from the mesh configuration.


Functions

template<typename ElementTypeOrTagT , typename MeshT , typename InterfaceAreaAccessorT , typename InterfaceAreaCellContributionAccessorT , typename VertexBoxVolumeAccessorT , typename VertexBoxVolumeCellContributionAccessorT , typename EdgeBoxVolumeAccessorT , typename EdgeBoxVolumeCellContributionAccessorT >
void apply_voronoi (MeshT const &mesh_obj, InterfaceAreaAccessorT interface_area_accessor, InterfaceAreaCellContributionAccessorT interface_area_cell_contribution_accessor, VertexBoxVolumeAccessorT vertex_box_volume_accessor, VertexBoxVolumeCellContributionAccessorT vertex_box_volume_cell_contribution_accessor, EdgeBoxVolumeAccessorT edge_box_volume_accessor, EdgeBoxVolumeCellContributionAccessorT edge_box_volume_cell_contribution_accessor)
 Writes Voronoi information to the mesh or segment using the provided accessors.
template<typename PointType >
PointType line_intersection (PointType const &a, PointType const &b, PointType const &c, PointType const &d)
 Computes the intersection of the two lines [a,b] and [c,d].
template<typename TriangleType >
viennagrid::result_of::point
< TriangleType >::type 
point_to_local_coordinates (typename viennagrid::result_of::point< TriangleType >::type const &p, const TriangleType &triangle)
 Converts a point to local (barycentric) coordinates (lambda_1, lambda_2). lambda_3 = 1 - lambda_1 - lambda_2 is not stored explicitly.
template<typename ContainerT , typename PairT >
void voronoi_unique_quantity_update (ContainerT &container, PairT const &update_pair)
 Adds a pair [CellPtr, contribution] to the Voronoi quantities stored in the container. If data for the particular Cell are already stored, no new element is inserted, but existing 'contribution' is updated.
template<typename CellTag , typename MeshT , typename InterfaceAreaAccessorT , typename InterfaceAreaCellContributionAccessorT , typename VertexBoxVolumeAccessorT , typename VertexBoxVolumeCellContributionAccessorT , typename EdgeBoxVolumeAccessorT , typename EdgeBoxVolumeCellContributionAccessorT >
void write_voronoi_info (MeshT const &mesh_obj, InterfaceAreaAccessorT interface_area_accessor, InterfaceAreaCellContributionAccessorT interface_area_cell_contribution_accessor, VertexBoxVolumeAccessorT vertex_box_volume_accessor, VertexBoxVolumeCellContributionAccessorT vertex_box_volume_cell_contribution_accessor, EdgeBoxVolumeAccessorT edge_box_volume_accessor, EdgeBoxVolumeCellContributionAccessorT edge_box_volume_cell_contribution_accessor, viennagrid::simplex_tag< 1 >)
 Implementation of the computation of Voronoi quantities for a one-dimensional mesh (line, 1-simplex)
template<typename CellTag , typename MeshT , typename InterfaceAreaAccessorT , typename InterfaceAreaCellContributionAccessorT , typename VertexBoxVolumeAccessorT , typename VertexBoxVolumeCellContributionAccessorT , typename EdgeBoxVolumeAccessorT , typename EdgeBoxVolumeCellContributionAccessorT >
void write_voronoi_info (MeshT const &mesh_obj, InterfaceAreaAccessorT interface_area_accessor, InterfaceAreaCellContributionAccessorT interface_area_cell_contribution_accessor, VertexBoxVolumeAccessorT vertex_box_volume_accessor, VertexBoxVolumeCellContributionAccessorT vertex_box_volume_cell_contribution_accessor, EdgeBoxVolumeAccessorT edge_box_volume_accessor, EdgeBoxVolumeCellContributionAccessorT edge_box_volume_cell_contribution_accessor, viennagrid::hypercube_tag< 1 >)
 Implementation of the computation of Voronoi quantities for a one-dimensional mesh (line, 1-hypercube)
template<typename CellTag , typename MeshT , typename InterfaceAreaAccessorT , typename InterfaceAreaCellContributionAccessorT , typename VertexBoxVolumeAccessorT , typename VertexBoxVolumeCellContributionAccessorT , typename EdgeBoxVolumeAccessorT , typename EdgeBoxVolumeCellContributionAccessorT >
void write_voronoi_info (MeshT const &mesh_obj, InterfaceAreaAccessorT interface_area_accessor, InterfaceAreaCellContributionAccessorT interface_area_cell_contribution_accessor, VertexBoxVolumeAccessorT vertex_box_volume_accessor, VertexBoxVolumeCellContributionAccessorT vertex_box_volume_cell_contribution_accessor, EdgeBoxVolumeAccessorT edge_box_volume_accessor, EdgeBoxVolumeCellContributionAccessorT edge_box_volume_cell_contribution_accessor, viennagrid::quadrilateral_tag)
 Implementation of the computation of Voronoi quantities for a quadrilateral mesh.
template<typename CellTag , typename MeshT , typename InterfaceAreaAccessorT , typename InterfaceAreaCellContributionAccessorT , typename VertexBoxVolumeAccessorT , typename VertexBoxVolumeCellContributionAccessorT , typename EdgeBoxVolumeAccessorT , typename EdgeBoxVolumeCellContributionAccessorT >
void write_voronoi_info (MeshT const &mesh_obj, InterfaceAreaAccessorT interface_area_accessor, InterfaceAreaCellContributionAccessorT interface_area_cell_contribution_accessor, VertexBoxVolumeAccessorT vertex_box_volume_accessor, VertexBoxVolumeCellContributionAccessorT vertex_box_volume_cell_contribution_accessor, EdgeBoxVolumeAccessorT edge_box_volume_accessor, EdgeBoxVolumeCellContributionAccessorT edge_box_volume_cell_contribution_accessor, viennagrid::triangle_tag)
 Implementation of the computation of Voronoi quantities for a triangular mesh.
template<typename CellTag , typename MeshT , typename InterfaceAreaAccessorT , typename InterfaceAreaCellContributionAccessorT , typename VertexBoxVolumeAccessorT , typename VertexBoxVolumeCellContributionAccessorT , typename EdgeBoxVolumeAccessorT , typename EdgeBoxVolumeCellContributionAccessorT >
void write_voronoi_info (MeshT const &mesh_obj, InterfaceAreaAccessorT interface_area_accessor, InterfaceAreaCellContributionAccessorT interface_area_cell_contribution_accessor, VertexBoxVolumeAccessorT vertex_box_volume_accessor, VertexBoxVolumeCellContributionAccessorT vertex_box_volume_cell_contribution_accessor, EdgeBoxVolumeAccessorT edge_box_volume_accessor, EdgeBoxVolumeCellContributionAccessorT edge_box_volume_cell_contribution_accessor, viennagrid::hexahedron_tag)
 Implementation of the computation of Voronoi quantities for a hexahedral mesh.

Detailed Description

Computes the Voronoi information for a Delaunay triangulation.