MathTL
 All Classes Functions Variables Typedefs Enumerations
Public Types | Public Member Functions
MathTL::Point< DIM, VALUE > Class Template Reference

#include <point.h>

Inheritance diagram for MathTL::Point< DIM, VALUE >:
MathTL::Tensor< 1, DIM, VALUE >

List of all members.

Public Types

typedef VALUE value_type
typedef value_typepointer
typedef const value_typeconst_pointer
typedef value_typeiterator
typedef const value_typeconst_iterator
typedef value_typereference
typedef const value_typeconst_reference
typedef size_t size_type

Public Member Functions

 Point ()
 Point (const Tensor< 1, DIM, VALUE > &)
 Point (const VALUE x)
 Point (const VALUE x, const VALUE y)
 Point (const VALUE x, const VALUE y, const VALUE z)
Point< DIM, VALUE > & operator= (const VALUE x)
const size_type size () const
const VALUE operator() (const size_type i) const
VALUE & operator() (const size_type i)

Detailed Description

template<unsigned int DIM, class VALUE = double>
class MathTL::Point< DIM, VALUE >

a class for points in the d-dimensional Euclidean space where d is a priori known


Member Typedef Documentation

template<unsigned int DIM, class VALUE = double>
typedef const value_type* MathTL::Point< DIM, VALUE >::const_iterator

const iterator type (cf. STL containers)

template<unsigned int DIM, class VALUE = double>
typedef const value_type* MathTL::Point< DIM, VALUE >::const_pointer

const pointer type (cf. STL containers)

template<unsigned int DIM, class VALUE = double>
typedef const value_type& MathTL::Point< DIM, VALUE >::const_reference

const reference type (cf. STL containers)

template<unsigned int DIM, class VALUE = double>
typedef value_type* MathTL::Point< DIM, VALUE >::iterator

iterator type (cf. STL containers)

template<unsigned int DIM, class VALUE = double>
typedef value_type* MathTL::Point< DIM, VALUE >::pointer

pointer type (cf. STL containers)

template<unsigned int DIM, class VALUE = double>
typedef value_type& MathTL::Point< DIM, VALUE >::reference

reference type (cf. STL containers)

template<unsigned int DIM, class VALUE = double>
typedef size_t MathTL::Point< DIM, VALUE >::size_type

size type (cf. STL containers)

Reimplemented from MathTL::Tensor< 1, DIM, VALUE >.

template<unsigned int DIM, class VALUE = double>
typedef VALUE MathTL::Point< DIM, VALUE >::value_type

value type of the vector (cf. STL containers)

Reimplemented from MathTL::Tensor< 1, DIM, VALUE >.


Constructor & Destructor Documentation

template<unsigned int DIM, class VALUE >
MathTL::Point< DIM, VALUE >::Point ( ) [inline]

default constructor: yields the origin (we always initialize the point with zero)

template<unsigned int DIM, class VALUE>
MathTL::Point< DIM, VALUE >::Point ( const Tensor< 1, DIM, VALUE > &  T) [inline]

copy constructor from a tensor of rank 1

template<unsigned int DIM, class VALUE>
MathTL::Point< DIM, VALUE >::Point ( const VALUE  x) [inline, explicit]

constructor from a single real number, sets all coordinates to this number

template<unsigned int DIM, class VALUE>
MathTL::Point< DIM, VALUE >::Point ( const VALUE  x,
const VALUE  y 
) [inline]

constructor from two real numbers, this is only allowed for DIM==2

template<unsigned int DIM, class VALUE>
MathTL::Point< DIM, VALUE >::Point ( const VALUE  x,
const VALUE  y,
const VALUE  z 
) [inline]

constructor from three real numbers, this is only allowed for DIM==3


Member Function Documentation

template<unsigned int DIM, class VALUE >
const VALUE MathTL::Point< DIM, VALUE >::operator() ( const size_type  i) const [inline]

Matlab-style read-only access operator (operator [] is inherited from the Tensor class)

template<unsigned int DIM, class VALUE >
VALUE & MathTL::Point< DIM, VALUE >::operator() ( const size_type  i) [inline]

Matlab-style read-write access operator (operator [] is inherited from the Tensor class)

template<unsigned int DIM, class VALUE>
Point< DIM, VALUE > & MathTL::Point< DIM, VALUE >::operator= ( const VALUE  x)

set all coordinates to a real number (also for implicit conversion)

template<unsigned int DIM, class VALUE >
const Point< DIM, VALUE >::size_type MathTL::Point< DIM, VALUE >::size ( ) const [inline]

assignment operator (for safety, Tensor class already has one)

size/dimension of the point (cf. std::vector signature)

Reimplemented from MathTL::Tensor< 1, DIM, VALUE >.


The documentation for this class was generated from the following files:
 All Classes Functions Variables Typedefs Enumerations