Data Structures | Namespaces | Functions

/export/development/ViennaGrid/release/ViennaGrid-1.0.0/viennagrid/point.hpp File Reference

Defines and implements the geometric point type and coordinate systems. More...

#include <cmath>
#include <assert.h>
#include <stdexcept>
#include <cstddef>
#include <sstream>
#include "viennagrid/forwards.h"
#include "viennagrid/traits/point.hpp"

Go to the source code of this file.

Data Structures

class  coordinate_converter< FromPointType, ToPointType, FromCoordinateSystem, ToCoordinateSystem >
 A conversion facility for transformations between coordinate systems. More...
class  coordinate_converter< FromPointType, ToPointType, cartesian_cs< 2 >, polar_cs >
 A functor for the transformation from two-dimensional Cartesian coordinates to polar coodinates. More...
class  coordinate_converter< FromPointType, ToPointType, cartesian_cs< 3 >, spherical_cs >
 A functor for the transformation from three-dimensional Cartesian coordinates to spherical coodinates. More...
class  coordinate_converter< FromPointType, ToPointType, cartesian_cs< 3 >, cylindrical_cs >
 A functor for the transformation from three-dimensional Cartesian coordinates to cylindrical coodinates. More...
struct  cartesian_point< PointType >
 Convenience metafunction for the conversion to Cartesian coordinates. More...
class  coordinate_converter< FromPointType, ToPointType, polar_cs, cartesian_cs< 2 > >
 A functor for the transformation from polar coordinates to two-dimensional Cartesian coordinates. More...
class  coordinate_converter< FromPointType, ToPointType, spherical_cs, cartesian_cs< 3 > >
 A functor for the transformation from spherical coodinates to three-dimensional Cartesian coordinates. More...
class  coordinate_converter< FromPointType, ToPointType, spherical_cs, cylindrical_cs >
 A functor for the transformation from spherical coodinates to cylindrical coordinates. More...
class  coordinate_converter< FromPointType, ToPointType, cylindrical_cs, cartesian_cs< 3 > >
 A functor for the transformation from cylindrical coodinates to three-dimensional Cartesian coordinates. More...
class  coordinate_converter< FromPointType, ToPointType, cylindrical_cs, spherical_cs >
 A functor for the transformation from cylindrical coordinates to spherical coodinates. More...
struct  cartesian_cs< d >
 Provides the basic operations in a cartesian coordinate system. More...
struct  cs_base< CSystem >
 Common base for all non-cartesian coordinate systems. More...
struct  polar_cs
 Provides the basic operations in a polar coordinate system (r, phi). More...
struct  spherical_cs
 Provides the basic operations in a spherical coordinate system (r, theta, phi) with theta denoting the elevation angle. More...
struct  cylindrical_cs
 Provides the basic operations in a cylindrical coordinate system (rho, theta, z). More...
class  point_index_out_of_bounds_exception
 An exception class for invalid point indices. More...
struct  point_filler< CoordType, d >
 A helper class for filling point coordinates with values. More...
struct  point_filler< CoordType, 1 >
 A helper class for filling point coordinates with values. Specialization for one dimension. More...
struct  point_filler< CoordType, 2 >
 A helper class for filling point coordinates with values. Specialization for two dimensions. More...
struct  point_filler< CoordType, 3 >
 A helper class for filling point coordinates with values. Specialization for three dimensions. More...
class  point_t< CoordType, CoordinateSystem >
 Represents an arbitrary point in the underlying coordinate system. More...
struct  point_less
 This class provides a less-than comparison for points. Entries are checked for inequality, starting from the first and continuing only in the case of equality. More...

Namespaces

namespace  viennagrid
 

The main ViennaGrid namespace. Most functionality resides in this namespace.


namespace  viennagrid::result_of
 

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


Functions

template<typename PointType , typename CoordinateSystem >
result_of::cartesian_point
< PointType >::type 
to_cartesian_impl (PointType const &p, CoordinateSystem const &)
 Helper function for the conversion to Cartesian coordinates. Should not be called directly. Use to_cartesian() instead.
template<typename PointType >
result_of::cartesian_point
< PointType >::type 
to_cartesian (PointType const &p)
 Convenience function for converting a point to Cartesian coordinates.
template<typename PointType , long d>
PointType const & to_cartesian_impl (PointType const &p, cartesian_cs< d >)
 Helper function for the transformation of any point to Cartesian coordinates. Should not be called directly - use to_cartesian() instead.
template<typename PointType , long d>
PointType & to_cartesian_impl (PointType &p, cartesian_cs< d >)
 Helper function for the transformation of any point to Cartesian coordinates. Should not be called directly - use to_cartesian() instead.
template<typename CoordType , typename CoordinateSystem >
point_t< CoordType,
CoordinateSystem > 
operator* (double val, point_t< CoordType, CoordinateSystem > const &p)
 Overload for stretching a vector from the left.
template<typename CoordType , typename CoordinateSystem >
std::ostream & operator<< (std::ostream &os, point_t< CoordType, CoordinateSystem > const &p)
 Overload of the output stream operator. Allows simple printing to screen or streaming to file.

Detailed Description

Defines and implements the geometric point type and coordinate systems.