SLIP  1.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Types | Public Member Functions | Static Public Attributes | Friends | Related Functions | List of all members
slip::HyperVolume< T > Class Template Reference

Numerical container class This is a four-dimensional dynamic and generic container. This container satisfies the BidirectionnalContainer concepts of the STL. It is also an 4d extension of the RandomAccessContainer concept. That is to say the bracket element access is replaced by the triple bracket element access. Data are stored using a Matrix4d class. It extends the interface of Matrix4d adding image read/write operations. These operations are done using the ImageMagick library. More...

#include <HyperVolume.hpp>

Public Types

typedef T value_type
 
typedef HyperVolume< T > self
 
typedef value_typepointer
 
typedef const value_typeconst_pointer
 
typedef value_typereference
 
typedef const value_typeconst_reference
 
typedef ptrdiff_t difference_type
 
typedef std::size_t size_type
 
typedef pointer iterator
 
typedef const_pointer const_iterator
 
typedef std::reverse_iterator
< iterator
reverse_iterator
 
typedef std::reverse_iterator
< const_iterator
const_reverse_iterator
 
typedef slip::stride_iterator
< pointer
slab_iterator
 
typedef slip::stride_iterator
< const_pointer
const_slab_iterator
 
typedef slip::stride_iterator
< pointer
slice_iterator
 
typedef slip::stride_iterator
< const_pointer
const_slice_iterator
 
typedef pointer row_iterator
 
typedef const_pointer const_row_iterator
 
typedef slip::stride_iterator
< pointer
col_iterator
 
typedef slip::stride_iterator
< const_pointer
const_col_iterator
 
typedef slip::stride_iterator
< slab_iterator
slab_range_iterator
 
typedef slip::stride_iterator
< const_slab_iterator
const_slab_range_iterator
 
typedef slip::stride_iterator
< slice_iterator
slice_range_iterator
 
typedef slip::stride_iterator
< const_slice_iterator
const_slice_range_iterator
 
typedef slip::stride_iterator
< pointer
row_range_iterator
 
typedef slip::stride_iterator
< const_pointer
const_row_range_iterator
 
typedef slip::stride_iterator
< col_iterator
col_range_iterator
 
typedef slip::stride_iterator
< const_col_iterator
const_col_range_iterator
 
typedef std::reverse_iterator
< slab_iterator
reverse_slab_iterator
 
typedef std::reverse_iterator
< const_slab_iterator
const_reverse_slab_iterator
 
typedef std::reverse_iterator
< slice_iterator
reverse_slice_iterator
 
typedef std::reverse_iterator
< const_slice_iterator
const_reverse_slice_iterator
 
typedef std::reverse_iterator
< iterator
reverse_row_iterator
 
typedef std::reverse_iterator
< const_iterator
const_reverse_row_iterator
 
typedef std::reverse_iterator
< col_iterator
reverse_col_iterator
 
typedef std::reverse_iterator
< const_col_iterator
const_reverse_col_iterator
 
typedef std::reverse_iterator
< slab_range_iterator
reverse_slab_range_iterator
 
typedef std::reverse_iterator
< const_slab_range_iterator
const_reverse_slab_range_iterator
 
typedef std::reverse_iterator
< slice_range_iterator
reverse_slice_range_iterator
 
typedef std::reverse_iterator
< const_slice_range_iterator
const_reverse_slice_range_iterator
 
typedef std::reverse_iterator
< row_range_iterator
reverse_row_range_iterator
 
typedef std::reverse_iterator
< const_row_range_iterator
const_reverse_row_range_iterator
 
typedef std::reverse_iterator
< col_range_iterator
reverse_col_range_iterator
 
typedef std::reverse_iterator
< const_col_range_iterator
const_reverse_col_range_iterator
 
typedef slip::Array4d< T >
::iterator4d 
iterator4d
 
typedef slip::Array4d< T >
::const_iterator4d 
const_iterator4d
 
typedef slip::Array4d< T >
::iterator4d_range 
iterator4d_range
 
typedef slip::Array4d< T >
::const_iterator4d_range 
const_iterator4d_range
 
typedef std::reverse_iterator
< iterator4d
reverse_iterator4d
 
typedef std::reverse_iterator
< const_iterator4d
const_reverse_iterator4d
 
typedef std::reverse_iterator
< iterator4d_range
reverse_iterator4d_range
 
typedef std::reverse_iterator
< const_iterator4d_range
const_reverse_iterator4d_range
 
typedef iterator4d default_iterator
 
typedef const_iterator4d const_default_iterator
 
typedef slip::Range< int > range
 

Public Member Functions

void resize (std::size_t d1, std::size_t d2, std::size_t d3, std::size_t d4, const T &val=T())
 Resizes a HyperVolume. More...
 
std::string name () const
 Returns the name of the class. More...
 
size_type dim1 () const
 Returns the number of slabs (first dimension size) in the HyperVolume. More...
 
size_type slabs () const
 Returns the number of slabs (first dimension size) in the HyperVolume. More...
 
size_type dim2 () const
 Returns the number of slices (second dimension size) in the HyperVolume. More...
 
size_type slices () const
 Returns the number of slices (second dimension size) in the HyperVolume. More...
 
size_type dim3 () const
 Returns the number of rows (third dimension size) in the HyperVolume. More...
 
size_type rows () const
 Returns the number of rows (third dimension size) in the HyperVolume. More...
 
size_type dim4 () const
 Returns the number of columns (fourth dimension size) in the HyperVolume. More...
 
size_type cols () const
 Returns the number of columns (fourth dimension size) in the HyperVolume. More...
 
size_type columns () const
 Returns the number of columns (fourth dimension size) in the HyperVolume. More...
 
size_type size () const
 Returns the number of elements in the HyperVolume. More...
 
size_type max_size () const
 Returns the maximal size (number of elements) in the HyperVolume. More...
 
bool empty () const
 Returns true if the HyperVolume is empty. (Thus size() == 0) More...
 
void swap (HyperVolume &M)
 Swaps data with another HyperVolume. More...
 
template<typename T>
 HyperVolume (const typename HyperVolume< T >::size_type d1, const typename HyperVolume< T >::size_type d2, const typename HyperVolume< T >::size_type d3, const typename HyperVolume< T >::size_type d4)
 
template<typename T>
 HyperVolume (const typename HyperVolume< T >::size_type d1, const typename HyperVolume< T >::size_type d2, const typename HyperVolume< T >::size_type d3, const typename HyperVolume< T >::size_type d4, const T &val)
 
template<typename T>
 HyperVolume (const typename HyperVolume< T >::size_type d1, const typename HyperVolume< T >::size_type d2, const typename HyperVolume< T >::size_type d3, const typename HyperVolume< T >::size_type d4, const T *val)
 
Constructors & Destructors
 HyperVolume ()
 Constructs a HyperVolume. More...
 
 HyperVolume (const std::size_t d1, const std::size_t d2, const std::size_t d3, const std::size_t d4)
 Constructs a HyperVolume. More...
 
 HyperVolume (const std::size_t d1, const std::size_t d2, const std::size_t d3, const std::size_t d4, const T &val)
 Constructs a HyperVolume initialized by the scalar value val. More...
 
 HyperVolume (const std::size_t d1, const std::size_t d2, const std::size_t d3, const std::size_t d4, const T *val)
 Constructs a HyperVolume initialized by an array val. More...
 
template<typename InputIterator >
 HyperVolume (const size_type d1, const size_type d2, const size_type d3, const size_type d4, InputIterator first, InputIterator last)
 Contructs a HyperVolume from a range. More...
 
 HyperVolume (const HyperVolume< T > &rhs)
 Constructs a copy of the HyperVolume rhs. More...
 
 ~HyperVolume ()
 Destructor of the HyperVolume. More...
 
One dimensional global iterators
const_iterator begin () const
 Returns a read-only (constant) iterator that points to the first element in the HyperVolume. Iteration is done in ordinary element order. More...
 
iterator begin ()
 Returns a read/write iterator that points to the first element in the HyperVolume. Iteration is done in ordinary element order. More...
 
iterator end ()
 Returns a read/write iterator that points one past the last element in the HyperVolume. Iteration is done in ordinary element order. More...
 
const_iterator end () const
 Returns a read-only (constant) iterator that points one past the last element in the HyperVolume. Iteration is done in ordinary element order. More...
 
reverse_iterator rbegin ()
 Returns a read/write reverse iterator that points to the last element in the HyperVolume. Iteration is done in reverse element order. More...
 
const_reverse_iterator rbegin () const
 Returns a read-only (constant) reverse iterator that points to the last element in the HyperVolume. Iteration is done in reverse element order. More...
 
reverse_iterator rend ()
 Returns a read/write reverse iterator that points to one before the first element in the HyperVolume. Iteration is done in reverse element order. More...
 
const_reverse_iterator rend () const
 Returns a read-only (constant) reverse iterator that points to one before the first element in the HyperVolume. Iteration is done in reverse element order. More...
 
One dimensional slab iterators
slab_iterator slab_begin (const size_type slice, const size_type row, const size_type col)
 Returns a read/write iterator that points to the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number). More...
 
const_slab_iterator slab_begin (const size_type slice, const size_type row, const size_type col) const
 Returns a read-only (constant) iterator that points to the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number). More...
 
slab_iterator slab_end (const size_type slice, const size_type row, const size_type col)
 Returns a read/write iterator that points to the one past the end element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number). More...
 
const_slab_iterator slab_end (const size_type slice, const size_type row, const size_type col) const
 Returns a read-only (constant) iterator that points to the one past the end element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number). More...
 
reverse_slab_iterator slab_rbegin (const size_type slice, const size_type row, const size_type col)
 Returns a read/write iterator that points to the last element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number). More...
 
const_reverse_slab_iterator slab_rbegin (const size_type slice, const size_type row, const size_type col) const
 Returns a read-only (constant) iterator that points to the last element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number). More...
 
reverse_slab_iterator slab_rend (const size_type slice, const size_type row, const size_type col)
 Returns a read/write iterator that points to the one before the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number). More...
 
const_reverse_slab_iterator slab_rend (const size_type slice, const size_type row, const size_type col) const
 Returns a read (constant) iterator that points to the one before the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number). More...
 
One dimensional slice iterators
slice_iterator slice_begin (const size_type slab, const size_type row, const size_type col)
 Returns a read/write iterator that points to the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number). More...
 
const_slice_iterator slice_begin (const size_type slab, const size_type row, const size_type col) const
 Returns a read-only (constant) iterator that points to the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number). More...
 
slice_iterator slice_end (const size_type slab, const size_type row, const size_type col)
 Returns a read/write iterator that points to the one past the end element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number). More...
 
const_slice_iterator slice_end (const size_type slab, const size_type row, const size_type col) const
 Returns a read-only (constant) iterator that points to the one past the end element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number). More...
 
reverse_slice_iterator slice_rbegin (const size_type slab, const size_type row, const size_type col)
 Returns a read/write iterator that points to the last element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number). More...
 
const_reverse_slice_iterator slice_rbegin (const size_type slab, const size_type row, const size_type col) const
 Returns a read-only (constant) iterator that points to the last element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number). More...
 
reverse_slice_iterator slice_rend (const size_type slab, const size_type row, const size_type col)
 Returns a read/write iterator that points to the one before the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number). More...
 
const_reverse_slice_iterator slice_rend (const size_type slab, const size_type row, const size_type col) const
 Returns a read (constant) iterator that points to the one before the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number). More...
 
One dimensional row iterators
row_iterator row_begin (const size_type slab, const size_type slice, const size_type row)
 Returns a read/write iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order. More...
 
const_row_iterator row_begin (const size_type slab, const size_type slice, const size_type row) const
 Returns a read_only iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order. More...
 
row_iterator row_end (const size_type slab, const size_type slice, const size_type row)
 Returns a read/write iterator that points to the past-the-end element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order. More...
 
const_row_iterator row_end (const size_type slab, const size_type slice, const size_type row) const
 Returns a read_only iterator that points to the past-the-end element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order. More...
 
reverse_row_iterator row_rbegin (const size_type slab, const size_type slice, const size_type row)
 Returns a read/write reverse iterator that points to the last element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order. More...
 
const_reverse_row_iterator row_rbegin (const size_type slab, const size_type slice, const size_type row) const
 Returns a read_only reverse iterator that points to the last element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order. More...
 
reverse_row_iterator row_rend (const size_type slab, const size_type slice, const size_type row)
 Returns a read/write reverse iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order. More...
 
const_reverse_row_iterator row_rend (const size_type slab, const size_type slice, const size_type row) const
 Returns a read_only reverse iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order. More...
 
One dimensional col iterators
col_iterator col_begin (const size_type slab, const size_type slice, const size_type col)
 Returns a read/write iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
const_col_iterator col_begin (const size_type slab, const size_type slice, const size_type col) const
 Returns a read_only iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
col_iterator col_end (const size_type slab, const size_type slice, const size_type col)
 Returns a read/write iterator that points to the past-the-end element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
const_col_iterator col_end (const size_type slab, const size_type slice, const size_type col) const
 Returns a read_only iterator that points to the past-the-end element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
reverse_col_iterator col_rbegin (const size_type slab, const size_type slice, const size_type col)
 Returns a read/write reverse iterator that points to the last element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
const_reverse_col_iterator col_rbegin (const size_type slab, const size_type slice, const size_type col) const
 Returns a read_only reverse iterator that points to the last element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
reverse_col_iterator col_rend (const size_type slab, const size_type slice, const size_type col)
 Returns a read/write reverse iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
const_reverse_col_iterator col_rend (const size_type slab, const size_type slice, const size_type col) const
 Returns a read_only reverse iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns. More...
 
One dimensional slab range iterators
slab_range_iterator slab_begin (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points to the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
slab_range_iterator slab_end (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points one past the end element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_slab_range_iterator slab_begin (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read only (constant) iterator that points to the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_slab_range_iterator slab_end (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read_only iterator that points one past the last element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
reverse_slab_range_iterator slab_rbegin (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points to the last element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
reverse_slab_range_iterator slab_rend (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points to the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order according to the Range. More...
 
const_reverse_slab_range_iterator slab_rbegin (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read only (constant) iterator that points to the last element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order according to the Range. More...
 
const_reverse_slab_range_iterator slab_rend (const size_type slice, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read_only iterator that points one past the lastto the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order according to the Range. More...
 
One dimensional slice range iterators
slice_range_iterator slice_begin (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points to the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
slice_range_iterator slice_end (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points one past the end element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_slice_range_iterator slice_begin (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read only (constant) iterator that points to the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_slice_range_iterator slice_end (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read_only iterator that points one past the last element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
reverse_slice_range_iterator slice_rbegin (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points to the last element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
reverse_slice_range_iterator slice_rend (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range)
 Returns a read/write iterator that points to the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order according to the Range. More...
 
const_reverse_slice_range_iterator slice_rbegin (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read only (constant) iterator that points to the last element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order according to the Range. More...
 
const_reverse_slice_range_iterator slice_rend (const size_type slab, const size_type row, const size_type col, const slip::Range< int > &range) const
 Returns a read_only iterator that points one past the lastto the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order according to the Range. More...
 
One dimensional row range iterators
row_range_iterator row_begin (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range)
 Returns a read/write iterator that points to the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
row_range_iterator row_end (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range)
 Returns a read/write iterator that points one past the end element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_row_range_iterator row_begin (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range) const
 Returns a read-only iterator that points to the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_row_range_iterator row_end (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range) const
 Returns a read_only iterator that points one past the last element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
reverse_row_range_iterator row_rbegin (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range)
 Returns a read-write iterator that points to the last element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
reverse_row_range_iterator row_rend (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range)
 Returns a read-write iterator that points one before the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
const_reverse_row_range_iterator row_rbegin (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range) const
 Returns a read-only iterator that points to the last element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
const_reverse_row_range_iterator row_rend (const size_type slab, const size_type slice, const size_type row, const slip::Range< int > &range) const
 Returns a read-only iterator that points one before the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
One dimensional col range iterators
col_range_iterator col_begin (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range)
 Returns a read-write iterator that points to the first element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
col_range_iterator col_end (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range)
 Returns a read-write iterator that points to the past the end element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_col_range_iterator col_begin (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range) const
 Returns a read-only iterator that points to the first element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range. More...
 
const_col_range_iterator col_end (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range) const
 Returns a read-only iterator that points to the past the end element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume. More...
 
reverse_col_range_iterator col_rbegin (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range)
 Returns a read-write iterator that points to the last element of the Range range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
reverse_col_range_iterator col_rend (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range)
 Returns a read-write iterator that points to one before the first element of the Range range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
const_reverse_col_range_iterator col_rbegin (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range) const
 Returns a read_only iterator that points to the last element of the Range & range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
const_reverse_col_range_iterator col_rend (const size_type slab, const size_type slice, const size_type col, const slip::Range< int > &range) const
 Returns a read-only iterator that points to the first element of the Range range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range. More...
 
four dimensional iterators : Global iterators
iterator4d first_front_upper_left ()
 Returns a read/write iterator4d that points to the first element of the HyperVolume. It points to the first front upper left element of the HyperVolume. More...
 
iterator4d last_back_bottom_right ()
 Returns a read/write iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the last back bottom right element of the HyperVolume. More...
 
const_iterator4d first_front_upper_left () const
 Returns a read-only iterator4d that points to the first element of the HyperVolume. It points to the fist front upper left element of the HyperVolume. More...
 
const_iterator4d last_back_bottom_right () const
 Returns a read-only iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the last back bottom right element of the HyperVolume. More...
 
reverse_iterator4d rfirst_front_upper_left ()
 Returns a read/write reverse iterator4d. It points to the last back bottom right element of the HyperVolume. Iteration is done within the HyperVolume in the reverse order. More...
 
reverse_iterator4d rlast_back_bottom_right ()
 Returns a read/write reverse iterator4d. It points to past the first front upper left element of the HyperVolume. Iteration is done in the reverse order. More...
 
const_reverse_iterator4d rfirst_front_upper_left () const
 Returns a read only reverse iterator4d that points. It points to the last back bottom right element of the HyperVolume. Iteration is done within the HyperVolume in the reverse order. More...
 
const_reverse_iterator4d rlast_back_bottom_right () const
 Returns a read only reverse iterator4d. It points to past the first front upper left element of the HyperVolume. Iteration is done in the reverse order. More...
 
four dimensional iterators : Box iterators
iterator4d first_front_upper_left (const Box4d< int > &box)
 Returns a read/write iterator4d that points to the first element of the HyperVolume. It points to the first front upper left element of the Box4d associated to the HyperVolume. More...
 
iterator4d last_back_bottom_right (const Box4d< int > &box)
 Returns a read/write iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the last back bottom right element of the Box4d associated to the HyperVolume. More...
 
const_iterator4d first_front_upper_left (const Box4d< int > &box) const
 Returns a read only iterator4d that points to the first element of the HyperVolume. It points to the front upper left element of the Box4d associated to the HyperVolume. More...
 
const_iterator4d last_back_bottom_right (const Box4d< int > &box) const
 Returns a read only iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the back bottom right element of the Box4d associated to the HyperVolume. More...
 
reverse_iterator4d rfirst_front_upper_left (const Box4d< int > &box)
 Returns a read/write reverse iterator4d. It points to the back bottom right element of the Box4d associated to the HyperVolume. Iteration is done in the reverse order. More...
 
reverse_iterator4d rlast_back_bottom_right (const Box4d< int > &box)
 Returns a read/write reverse iterator4d. It points to one before the front upper left element of the Box4d box associated to the HyperVolume. More...
 
const_reverse_iterator4d rfirst_front_upper_left (const Box4d< int > &box) const
 Returns a read only reverse iterator4d. It points to the back bottom right element of the Box4d box associated to the HyperVolume. Iteration is done in the reverse order. More...
 
const_reverse_iterator4d rlast_back_bottom_right (const Box4d< int > &box) const
 Returns a read-only reverse iterator4d. It points to one before the front element of the bottom right element of the Box4d box associated to the HyperVolume. More...
 
four dimensional iterators : Range iterators
iterator4d_range first_front_upper_left (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range)
 Returns a read/write iterator4d_range that points to the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. More...
 
iterator4d_range last_back_bottom_right (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range)
 Returns a read/write iterator4d_range that points to the past the end last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. More...
 
const_iterator4d_range first_front_upper_left (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range) const
 Returns a read-only iterator4d_range that points to the to the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. More...
 
const_iterator4d_range last_back_bottom_right (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range) const
 Returns a read-only iterator4d_range that points to the past the end last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. More...
 
reverse_iterator4d_range rfirst_front_upper_left (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range)
 Returns a read/write reverse_iterator4d_range that points to the past the last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order. More...
 
reverse_iterator4d_range rlast_back_bottom_right (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range)
 Returns a read/write reverse_iterator4d_range that points to one before the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order. More...
 
const_reverse_iterator4d_range rfirst_front_upper_left (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range) const
 Returns a read-only reverse_iterator4d_range that points to the past the last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order. More...
 
const_reverse_iterator4d_range rlast_back_bottom_right (const range &slab_range, const range &slice_range, const range &row_range, const range &col_range) const
 Returns a read-only reverse_iterator4d_range that points to one before the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order. More...
 
Assignment operators and methods
selfoperator= (const HyperVolume< T > &rhs)
 Assign a HyperVolume. More...
 
selfoperator= (const T &value)
 Assign all the elments of the HyperVolume by value. More...
 
void fill (const T &value)
 Fills the container range [begin(),begin()+size()) with copies of value. More...
 
void fill (const T *value)
 Fills the container range [begin(),begin()+size()) with a copy of the value array. More...
 
template<typename InputIterator >
void fill (InputIterator first, InputIterator last)
 Fills the container range [begin(),begin()+size()) with a copy of the range [first,last) More...
 
Element access operators
T *** operator[] (const size_type l)
 
const T **const * operator[] (const size_type l) const
 
reference operator() (const size_type l, const size_type k, const size_type i, const size_type j)
 Subscript access to the data contained in the HyperVolume. More...
 
const_reference operator() (const size_type l, const size_type k, const size_type i, const size_type j) const
 Subscript access to the data contained in the HyperVolume. More...
 
Arithmetic operators
selfoperator+= (const T &val)
 Add val to each element of the HyperVolume. More...
 
selfoperator-= (const T &val)
 
selfoperator*= (const T &val)
 
selfoperator/= (const T &val)
 
self operator- () const
 
selfoperator+= (const self &rhs)
 
selfoperator-= (const self &rhs)
 
selfoperator*= (const self &rhs)
 
selfoperator/= (const self &rhs)
 
Mathematic operators
T & min () const
 Returns the min element of the HyperVolume according to the operator <. More...
 
T & max () const
 Returns the max element of the HyperVolume according to the operator <. More...
 
sum () const
 Returns the sum of the elements of the HyperVolume. More...
 
HyperVolume< T > & apply (T(*fun)(T))
 Applys the one-parameter C-function fun to each element of the HyperVolume. More...
 
HyperVolume< T > & apply (T(*fun)(const T &))
 Applys the one-parameter C-function fun to each element of the HyperVolume. More...
 

Static Public Attributes

static const std::size_t DIM = 4
 

Friends

class boost::serialization::access
 
i/o operators
std::ostream & operator<< (std::ostream &out, const HyperVolume< T > &a)
 Write the HyperVolume to the ouput stream. More...
 
Comparison operators
bool operator== (const HyperVolume< T > &x, const HyperVolume< T > &y)
 HyperVolume equality comparison More...
 
bool operator!= (const HyperVolume< T > &x, const HyperVolume< T > &y)
 HyperVolume inequality comparison More...
 
bool operator< (const HyperVolume< T > &x, const HyperVolume< T > &y)
 Less than comparison operator (HyperVolume ordering relation) More...
 
bool operator> (const HyperVolume< T > &x, const HyperVolume< T > &y)
 More than comparison operator. More...
 
bool operator<= (const HyperVolume< T > &x, const HyperVolume< T > &y)
 Less than equal comparison operator. More...
 
bool operator>= (const HyperVolume< T > &x, const HyperVolume< T > &y)
 More than equal comparison operator. More...
 

Related Functions

(Note that these are not member functions.)

template<typename T >
T & min (const HyperVolume< T > &M1)
 Returns the min element of a HyperVolume. More...
 
template<typename T >
T & max (const HyperVolume< T > &M1)
 Returns the max element of a HyperVolume. More...
 
template<typename T >
HyperVolume< T > abs (const HyperVolume< T > &V)
 Returns the abs value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > sqrt (const HyperVolume< T > &V)
 Returns the sqrt value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > cos (const HyperVolume< T > &V)
 Returns the cos value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > acos (const HyperVolume< T > &V)
 Returns the acos value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > sin (const HyperVolume< T > &V)
 Returns the sin value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > asin (const HyperVolume< T > &V)
 Returns the sin value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > tan (const HyperVolume< T > &V)
 Returns the tan value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > atan (const HyperVolume< T > &V)
 Returns the atan value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > exp (const HyperVolume< T > &V)
 Returns the exp value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > log (const HyperVolume< T > &V)
 Returns the log value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > cosh (const HyperVolume< T > &V)
 Returns the cosh value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > sinh (const HyperVolume< T > &V)
 Returns the sinh value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > tanh (const HyperVolume< T > &V)
 Returns the tanh value of each element of the HyperVolume. More...
 
template<typename T >
HyperVolume< T > log10 (const HyperVolume< T > &V)
 Returns the log10 value of each element of the HyperVolume. More...
 

Detailed Description

template<typename T>
class slip::HyperVolume< T >

Numerical container class This is a four-dimensional dynamic and generic container. This container satisfies the BidirectionnalContainer concepts of the STL. It is also an 4d extension of the RandomAccessContainer concept. That is to say the bracket element access is replaced by the triple bracket element access. Data are stored using a Matrix4d class. It extends the interface of Matrix4d adding image read/write operations. These operations are done using the ImageMagick library.

Version
Fluex 1.0
Date
2013/07/12
Since
1.4.0
Version
0.0.2
Date
2014/04/05
Author
Denis Arrivault <denis.arrivault_AT_inria.fr>
Parameters
TType of object in the HyperVolume
iterator4d_conventions.jpg
axis and notation conventions

Definition at line 104 of file HyperVolume.hpp.

Member Typedef Documentation

template<typename T>
typedef slip::stride_iterator<pointer> slip::HyperVolume< T >::col_iterator

Definition at line 191 of file HyperVolume.hpp.

Definition at line 200 of file HyperVolume.hpp.

Definition at line 192 of file HyperVolume.hpp.

Definition at line 201 of file HyperVolume.hpp.

template<typename T>
typedef const_iterator4d slip::HyperVolume< T >::const_default_iterator

Definition at line 234 of file HyperVolume.hpp.

template<typename T>
typedef const_pointer slip::HyperVolume< T >::const_iterator

Definition at line 178 of file HyperVolume.hpp.

template<typename T>
typedef slip::Array4d<T>::const_iterator4d slip::HyperVolume< T >::const_iterator4d

Definition at line 223 of file HyperVolume.hpp.

Definition at line 225 of file HyperVolume.hpp.

template<typename T>
typedef const value_type* slip::HyperVolume< T >::const_pointer

Definition at line 170 of file HyperVolume.hpp.

template<typename T>
typedef const value_type& slip::HyperVolume< T >::const_reference

Definition at line 172 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_col_iterator> slip::HyperVolume< T >::const_reverse_col_iterator

Definition at line 210 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_col_range_iterator> slip::HyperVolume< T >::const_reverse_col_range_iterator

Definition at line 219 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_iterator> slip::HyperVolume< T >::const_reverse_iterator

Definition at line 181 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_iterator4d> slip::HyperVolume< T >::const_reverse_iterator4d

Definition at line 228 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_iterator4d_range> slip::HyperVolume< T >::const_reverse_iterator4d_range

Definition at line 230 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_iterator> slip::HyperVolume< T >::const_reverse_row_iterator

Definition at line 208 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_row_range_iterator> slip::HyperVolume< T >::const_reverse_row_range_iterator

Definition at line 217 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_slab_iterator> slip::HyperVolume< T >::const_reverse_slab_iterator

Definition at line 204 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_slab_range_iterator> slip::HyperVolume< T >::const_reverse_slab_range_iterator

Definition at line 213 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_slice_iterator> slip::HyperVolume< T >::const_reverse_slice_iterator

Definition at line 206 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<const_slice_range_iterator> slip::HyperVolume< T >::const_reverse_slice_range_iterator

Definition at line 215 of file HyperVolume.hpp.

template<typename T>
typedef const_pointer slip::HyperVolume< T >::const_row_iterator

Definition at line 190 of file HyperVolume.hpp.

Definition at line 199 of file HyperVolume.hpp.

Definition at line 186 of file HyperVolume.hpp.

Definition at line 195 of file HyperVolume.hpp.

Definition at line 188 of file HyperVolume.hpp.

Definition at line 197 of file HyperVolume.hpp.

template<typename T>
typedef iterator4d slip::HyperVolume< T >::default_iterator

Definition at line 233 of file HyperVolume.hpp.

template<typename T>
typedef ptrdiff_t slip::HyperVolume< T >::difference_type

Definition at line 174 of file HyperVolume.hpp.

template<typename T>
typedef pointer slip::HyperVolume< T >::iterator

Definition at line 177 of file HyperVolume.hpp.

template<typename T>
typedef slip::Array4d<T>::iterator4d slip::HyperVolume< T >::iterator4d

Definition at line 222 of file HyperVolume.hpp.

template<typename T>
typedef slip::Array4d<T>::iterator4d_range slip::HyperVolume< T >::iterator4d_range

Definition at line 224 of file HyperVolume.hpp.

template<typename T>
typedef value_type* slip::HyperVolume< T >::pointer

Definition at line 169 of file HyperVolume.hpp.

template<typename T>
typedef slip::Range<int> slip::HyperVolume< T >::range

Definition at line 237 of file HyperVolume.hpp.

template<typename T>
typedef value_type& slip::HyperVolume< T >::reference

Definition at line 171 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<col_iterator> slip::HyperVolume< T >::reverse_col_iterator

Definition at line 209 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<col_range_iterator> slip::HyperVolume< T >::reverse_col_range_iterator

Definition at line 218 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<iterator> slip::HyperVolume< T >::reverse_iterator

Definition at line 180 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<iterator4d> slip::HyperVolume< T >::reverse_iterator4d

Definition at line 227 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<iterator4d_range> slip::HyperVolume< T >::reverse_iterator4d_range

Definition at line 229 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<iterator> slip::HyperVolume< T >::reverse_row_iterator

Definition at line 207 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<row_range_iterator> slip::HyperVolume< T >::reverse_row_range_iterator

Definition at line 216 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<slab_iterator> slip::HyperVolume< T >::reverse_slab_iterator

Definition at line 203 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<slab_range_iterator> slip::HyperVolume< T >::reverse_slab_range_iterator

Definition at line 212 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<slice_iterator> slip::HyperVolume< T >::reverse_slice_iterator

Definition at line 205 of file HyperVolume.hpp.

template<typename T>
typedef std::reverse_iterator<slice_range_iterator> slip::HyperVolume< T >::reverse_slice_range_iterator

Definition at line 214 of file HyperVolume.hpp.

template<typename T>
typedef pointer slip::HyperVolume< T >::row_iterator

Definition at line 189 of file HyperVolume.hpp.

Definition at line 198 of file HyperVolume.hpp.

template<typename T>
typedef HyperVolume<T> slip::HyperVolume< T >::self

Definition at line 167 of file HyperVolume.hpp.

template<typename T>
typedef std::size_t slip::HyperVolume< T >::size_type

Definition at line 175 of file HyperVolume.hpp.

template<typename T>
typedef slip::stride_iterator<pointer> slip::HyperVolume< T >::slab_iterator

Definition at line 185 of file HyperVolume.hpp.

Definition at line 194 of file HyperVolume.hpp.

template<typename T>
typedef slip::stride_iterator<pointer> slip::HyperVolume< T >::slice_iterator

Definition at line 187 of file HyperVolume.hpp.

Definition at line 196 of file HyperVolume.hpp.

template<typename T>
typedef T slip::HyperVolume< T >::value_type

Definition at line 166 of file HyperVolume.hpp.

Constructor & Destructor Documentation

template<typename T >
slip::HyperVolume< T >::HyperVolume ( )
inline

Constructs a HyperVolume.

Definition at line 3560 of file HyperVolume.hpp.

template<typename T>
slip::HyperVolume< T >::HyperVolume ( const std::size_t  d1,
const std::size_t  d2,
const std::size_t  d3,
const std::size_t  d4 
)

Constructs a HyperVolume.

Parameters
d1first dimension of the HyperVolume
d2second dimension of the HyperVolume
d3third dimension of the HyperVolume
d4fourth dimension of the HyperVolume
The HyperVolume is initialized by the default value of T.
template<typename T>
slip::HyperVolume< T >::HyperVolume ( const std::size_t  d1,
const std::size_t  d2,
const std::size_t  d3,
const std::size_t  d4,
const T &  val 
)

Constructs a HyperVolume initialized by the scalar value val.

Parameters
d1first dimension of the HyperVolume
d2second dimension of the HyperVolume
d3third dimension of the HyperVolume
d4fourth dimension of the HyperVolume
valinitialization value of the elements
template<typename T>
slip::HyperVolume< T >::HyperVolume ( const std::size_t  d1,
const std::size_t  d2,
const std::size_t  d3,
const std::size_t  d4,
const T *  val 
)

Constructs a HyperVolume initialized by an array val.

Parameters
d1first dimension of the HyperVolume
d2second dimension of the HyperVolume
d3third dimension of the HyperVolume
d4fourth dimension of the HyperVolume
valinitialization array value of the elements
template<typename T>
template<typename InputIterator >
slip::HyperVolume< T >::HyperVolume ( const size_type  d1,
const size_type  d2,
const size_type  d3,
const size_type  d4,
InputIterator  first,
InputIterator  last 
)
inline

Contructs a HyperVolume from a range.

Parameters
d1first dimension of the HyperVolume
d2second dimension of the HyperVolume
d3third dimension of the HyperVolume
d4fourth dimension of the HyperVolume
firstAn input iterator.
lastAn input iterator.

Create a HyperVolume consisting of copies of the elements from [first,last).

Definition at line 305 of file HyperVolume.hpp.

template<typename T>
slip::HyperVolume< T >::HyperVolume ( const HyperVolume< T > &  rhs)
inline

Constructs a copy of the HyperVolume rhs.

Definition at line 3596 of file HyperVolume.hpp.

template<typename T >
slip::HyperVolume< T >::~HyperVolume ( )
inline

Destructor of the HyperVolume.

Definition at line 3602 of file HyperVolume.hpp.

template<typename T>
template<typename T>
slip::HyperVolume< T >::HyperVolume ( const typename HyperVolume< T >::size_type  d1,
const typename HyperVolume< T >::size_type  d2,
const typename HyperVolume< T >::size_type  d3,
const typename HyperVolume< T >::size_type  d4 
)
inline

Definition at line 3566 of file HyperVolume.hpp.

template<typename T>
template<typename T>
slip::HyperVolume< T >::HyperVolume ( const typename HyperVolume< T >::size_type  d1,
const typename HyperVolume< T >::size_type  d2,
const typename HyperVolume< T >::size_type  d3,
const typename HyperVolume< T >::size_type  d4,
const T &  val 
)
inline

Definition at line 3575 of file HyperVolume.hpp.

template<typename T>
template<typename T>
slip::HyperVolume< T >::HyperVolume ( const typename HyperVolume< T >::size_type  d1,
const typename HyperVolume< T >::size_type  d2,
const typename HyperVolume< T >::size_type  d3,
const typename HyperVolume< T >::size_type  d4,
const T *  val 
)
inline

Definition at line 3585 of file HyperVolume.hpp.

Member Function Documentation

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::apply ( T(*)(T)  fun)
inline

Applys the one-parameter C-function fun to each element of the HyperVolume.

Parameters
funThe one-parameter C function
Returns
the resulting HyperVolume

Definition at line 4905 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::apply ( T(*)(const T &)  fun)
inline

Applys the one-parameter C-function fun to each element of the HyperVolume.

Parameters
funThe one-const-parameter C function
Returns
the resulting HyperVolume

Definition at line 4913 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_iterator slip::HyperVolume< T >::begin ( ) const
inline

Returns a read-only (constant) iterator that points to the first element in the HyperVolume. Iteration is done in ordinary element order.

Returns
const begin iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
slip::HyperVolume<double> const A1(10,9,5,2);
slip::HyperVolume<double> const A2(10,9,5,2);
//copy the sum of A1 and A2 in S
std::transform(A1.begin(),A1.end(),
A2.begin(),S.begin(),
std::plus<double>());

Definition at line 3673 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::iterator slip::HyperVolume< T >::begin ( )
inline

Returns a read/write iterator that points to the first element in the HyperVolume. Iteration is done in ordinary element order.

Returns
begin iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//copy the sum of A1 and A2 in S
std::transform(A1.begin(),A1.end(),
A2.begin(),S.begin(),
std::plus<double>());

Definition at line 3659 of file HyperVolume.hpp.

template<typename T>
col_iterator slip::HyperVolume< T >::col_begin ( const size_type  slab,
const size_type  slice,
const size_type  col 
)

Returns a read/write iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
begin col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_col_iterator slip::HyperVolume< T >::col_begin ( const size_type  slab,
const size_type  slice,
const size_type  col 
) const

Returns a read_only iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
begin const_col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
col_range_iterator slip::HyperVolume< T >::col_begin ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read-write iterator that points to the first element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate
Returns
begin col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated according to the
//range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_begin(0,0,0,range),A1.col_end(0,0,0,range),A2.col_begin(1,1,1));
template<typename T>
const_col_range_iterator slip::HyperVolume< T >::col_begin ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read-only iterator that points to the first element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate.
Returns
begin const_col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated according to the
//range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_begin(0,0,0,range),A1.col_end(0,0,0,range),A2.col_begin(1,1,1));
template<typename T>
col_iterator slip::HyperVolume< T >::col_end ( const size_type  slab,
const size_type  slice,
const size_type  col 
)

Returns a read/write iterator that points to the past-the-end element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
end col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_col_iterator slip::HyperVolume< T >::col_end ( const size_type  slab,
const size_type  slice,
const size_type  col 
) const

Returns a read_only iterator that points to the past-the-end element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
end const_col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
col_range_iterator slip::HyperVolume< T >::col_end ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read-write iterator that points to the past the end element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate.
Returns
begin col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated according to the
//range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_begin(0,0,0,range),A1.col_end(0,0,0,range),A2.col_begin(1,1,1));
template<typename T>
const_col_range_iterator slip::HyperVolume< T >::col_end ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read-only iterator that points to the past the end element of the Range range of the col col in the slab slab and the slice slice in the HyperVolume.

Parameters
slabslab coordinate of the line Iteration is done in ordinary element order according to the Range.
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate
Returns
begin const_col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated according to the
//range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_begin(0,0,0,range),A1.col_end(0,0,0,range),A2.col_begin(1,1,1));
template<typename T>
reverse_col_iterator slip::HyperVolume< T >::col_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  col 
)

Returns a read/write reverse iterator that points to the last element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
begin reverse_col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_reverse_col_iterator slip::HyperVolume< T >::col_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  col 
) const

Returns a read_only reverse iterator that points to the last element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
begin const_reverse_col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
reverse_col_range_iterator slip::HyperVolume< T >::col_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read-write iterator that points to the last element of the Range range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate.
Returns
begin reverse_col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated
//in reverse order according to the range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_rbegin(0,0,0,range),A1.col_rend(0,0,0,range),A2.col_begin(1,1,1));
template<typename T>
const_reverse_col_range_iterator slip::HyperVolume< T >::col_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read_only iterator that points to the last element of the Range & range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate.
Returns
begin const_reverse_col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated
//in reverse order according to the range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_rbegin(0,0,0,range),A1.col_rend(0,0,0,range),A2.col_begin(1,1,1));
template<typename T>
reverse_col_iterator slip::HyperVolume< T >::col_rend ( const size_type  slab,
const size_type  slice,
const size_type  col 
)

Returns a read/write reverse iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
end reverse_col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_reverse_col_iterator slip::HyperVolume< T >::col_rend ( const size_type  slab,
const size_type  slice,
const size_type  col 
) const

Returns a read_only reverse iterator that points to the first element of the column column of a given slab slab and a given slice slice in the HyperVolume. Iteration is done modulo the number of columns.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
colThe index of the column
Returns
end const_reverse_col_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
reverse_col_range_iterator slip::HyperVolume< T >::col_rend ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read-write iterator that points to one before the first element of the Range range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate.
Returns
reverse_col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated
//in reverse order according to the range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_rbegin(0,0,0,range),A1.col_rend(0,0,0,range),A2.col_begin(1,1,1));
template<typename T>
const_reverse_col_range_iterator slip::HyperVolume< T >::col_rend ( const size_type  slab,
const size_type  slice,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read-only iterator that points to the first element of the Range range of the col of a slice col in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
colThe index of the column to iterate.
rangeRange of the column to iterate.
Returns
const_reverse_col_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
col must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim4()-1,2);
//copy the the elements of the column 0 in the slab 0 and the slice 0 of A1 iterated
//in reverse order according to the range in the column 1 in the slab 1 and the slice 1 of A2
std::copy(A1.col_rbegin(0,0,0,range),A1.col_rend(0,0,0,range),A2.col_begin(1,1,1));
template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::cols ( ) const
inline

Returns the number of columns (fourth dimension size) in the HyperVolume.

Definition at line 4696 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::columns ( ) const
inline

Returns the number of columns (fourth dimension size) in the HyperVolume.

Definition at line 4701 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::dim1 ( ) const
inline

Returns the number of slabs (first dimension size) in the HyperVolume.

Definition at line 4661 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::dim2 ( ) const
inline

Returns the number of slices (second dimension size) in the HyperVolume.

Definition at line 4671 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::dim3 ( ) const
inline

Returns the number of rows (third dimension size) in the HyperVolume.

Definition at line 4681 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::dim4 ( ) const
inline

Returns the number of columns (fourth dimension size) in the HyperVolume.

Definition at line 4691 of file HyperVolume.hpp.

template<typename T >
bool slip::HyperVolume< T >::empty ( ) const
inline

Returns true if the HyperVolume is empty. (Thus size() == 0)

Definition at line 4716 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::iterator slip::HyperVolume< T >::end ( )
inline

Returns a read/write iterator that points one past the last element in the HyperVolume. Iteration is done in ordinary element order.

Returns
end iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//copy the sum of A1 and A2 in S
std::transform(A1.begin(),A1.end(),
A2.begin(),S.begin(),
std::plus<double>());

Definition at line 3666 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_iterator slip::HyperVolume< T >::end ( ) const
inline

Returns a read-only (constant) iterator that points one past the last element in the HyperVolume. Iteration is done in ordinary element order.

Returns
const end iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//copy the sum of A1 and A2 in S
std::transform(A1.begin(),A1.end(),
A2.begin(),S.begin(),
std::plus<double>());

Definition at line 3681 of file HyperVolume.hpp.

template<typename T>
void slip::HyperVolume< T >::fill ( const T &  value)
inline

Fills the container range [begin(),begin()+size()) with copies of value.

Parameters
valueA reference-to-const of arbitrary type.

Definition at line 2923 of file HyperVolume.hpp.

template<typename T>
void slip::HyperVolume< T >::fill ( const T *  value)
inline

Fills the container range [begin(),begin()+size()) with a copy of the value array.

Parameters
valueA pointer of arbitrary type.

Definition at line 2934 of file HyperVolume.hpp.

template<typename T>
template<typename InputIterator >
void slip::HyperVolume< T >::fill ( InputIterator  first,
InputIterator  last 
)
inline

Fills the container range [begin(),begin()+size()) with a copy of the range [first,last)

Parameters
firstAn input iterator.
lastAn input iterator.

Definition at line 2948 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::iterator4d slip::HyperVolume< T >::first_front_upper_left ( )
inline

Returns a read/write iterator4d that points to the first element of the HyperVolume. It points to the first front upper left element of the HyperVolume.

Returns
iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M
std::copy(M.first_front_upper_left(),M.last_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4365 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_iterator4d slip::HyperVolume< T >::first_front_upper_left ( ) const
inline

Returns a read-only iterator4d that points to the first element of the HyperVolume. It points to the fist front upper left element of the HyperVolume.

Returns
const iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M
std::copy(M.first_front_upper_left(),M.last_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4372 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::iterator4d slip::HyperVolume< T >::first_front_upper_left ( const Box4d< int > &  box)
inline

Returns a read/write iterator4d that points to the first element of the HyperVolume. It points to the first front upper left element of the Box4d associated to the HyperVolume.

Parameters
boxA Box4d defining the range of indices to iterate within the HyperVolume.
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Returns
iterator4d value
Precondition
The box indices must be inside the range of the HyperVolume ones.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box
std::copy(M.first_front_upper_left(b),M.last_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4432 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_iterator4d slip::HyperVolume< T >::first_front_upper_left ( const Box4d< int > &  box) const
inline

Returns a read only iterator4d that points to the first element of the HyperVolume. It points to the front upper left element of the Box4d associated to the HyperVolume.

Parameters
boxa Box4d defining the range of indices to iterate within the HyperVolume.
Returns
end const iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Precondition
The box indices must be inside the range of the HyperVolume ones.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box
std::copy(M.first_front_upper_left(b),M.last_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4439 of file HyperVolume.hpp.

template<typename T>
iterator4d_range slip::HyperVolume< T >::first_front_upper_left ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
)

Returns a read/write iterator4d_range that points to the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range
std::copy(M.first_front_upper_left(slar,slir,rr,cr),M.last_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_iterator4d_range slip::HyperVolume< T >::first_front_upper_left ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
) const

Returns a read-only iterator4d_range that points to the to the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
const_iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range
std::copy(M.first_front_upper_left(slar,slir,rr,cr),M.last_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T >
HyperVolume< T >::iterator4d slip::HyperVolume< T >::last_back_bottom_right ( )
inline

Returns a read/write iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the last back bottom right element of the HyperVolume.

Returns
iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M
std::copy(M.first_front_upper_left(),M.last_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4381 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_iterator4d slip::HyperVolume< T >::last_back_bottom_right ( ) const
inline

Returns a read-only iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the last back bottom right element of the HyperVolume.

Returns
const iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M
std::copy(M.first_front_upper_left(),M.last_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4388 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::iterator4d slip::HyperVolume< T >::last_back_bottom_right ( const Box4d< int > &  box)
inline

Returns a read/write iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the last back bottom right element of the Box4d associated to the HyperVolume.

Parameters
boxa Box4d defining the range of indices to iterate within the HyperVolume.
Returns
iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Precondition
The box indices must be inside the range of the HyperVolume ones.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box
std::copy(M.first_front_upper_left(b),M.last_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4449 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_iterator4d slip::HyperVolume< T >::last_back_bottom_right ( const Box4d< int > &  box) const
inline

Returns a read only iterator4d that points to the past the end element of the HyperVolume. It points to past the end element of the back bottom right element of the Box4d associated to the HyperVolume.

Parameters
boxa Box4d defining the range of indices to iterate within the HyperVolume.
Returns
end const iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Precondition
The box indices must be inside the range of the HyperVolume ones.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box
std::copy(M.first_front_upper_left(b),M.last_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4457 of file HyperVolume.hpp.

template<typename T>
iterator4d_range slip::HyperVolume< T >::last_back_bottom_right ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
)

Returns a read/write iterator4d_range that points to the past the end last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range
std::copy(M.first_front_upper_left(slar,slir,rr,cr),M.last_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_iterator4d_range slip::HyperVolume< T >::last_back_bottom_right ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
) const

Returns a read-only iterator4d_range that points to the past the end last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
const_iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range
std::copy(M.first_front_upper_left(slar,slir,rr,cr),M.last_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T >
T & slip::HyperVolume< T >::max ( ) const
inline

Returns the max element of the HyperVolume according to the operator <.

Precondition
size() != 0

Definition at line 4888 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::max_size ( ) const
inline

Returns the maximal size (number of elements) in the HyperVolume.

Definition at line 4712 of file HyperVolume.hpp.

template<typename T >
T & slip::HyperVolume< T >::min ( ) const
inline

Returns the min element of the HyperVolume according to the operator <.

Precondition
size() != 0

Definition at line 4880 of file HyperVolume.hpp.

template<typename T >
std::string slip::HyperVolume< T >::name ( ) const
inline

Returns the name of the class.

Definition at line 4656 of file HyperVolume.hpp.

template<typename T>
reference slip::HyperVolume< T >::operator() ( const size_type  l,
const size_type  k,
const size_type  i,
const size_type  j 
)

Subscript access to the data contained in the HyperVolume.

Parameters
lThe index of the slab for which the data should be accessed.
kThe index of the slice for which the data should be accessed.
iThe index of the row for which the data should be accessed.
jThe index of the column for which the data should be accessed.
Returns
Read/Write reference to data.
Precondition
l < slabs()
k < slices()
i < rows()
j < cols() This operator allows for easy, 4d array-style, data access. Note that data access with this operator is unchecked and out_of_range lookups are not defined.
template<typename T>
const_reference slip::HyperVolume< T >::operator() ( const size_type  l,
const size_type  k,
const size_type  i,
const size_type  j 
) const

Subscript access to the data contained in the HyperVolume.

Parameters
lThe index of the slab for which the data should be accessed.
kThe index of the slice for which the data should be accessed.
iThe index of the row for which the data should be accessed.
jThe index of the column for which the data should be accessed.
Returns
Read_only (constant) reference to data.
Precondition
l < slabs()
k < slices()
i < rows()
j < cols() This operator allows for easy, 4d array-style, data access. Note that data access with this operator is unchecked and out_of_range lookups are not defined.
template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator*= ( const T &  val)
inline

Definition at line 4807 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator*= ( const self rhs)
inline

Definition at line 4857 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator+= ( const T &  val)
inline

Add val to each element of the HyperVolume.

Parameters
valvalue
Returns
reference to the resulting HyperVolume

Definition at line 4791 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator+= ( const self rhs)
inline

Definition at line 4832 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > slip::HyperVolume< T >::operator- ( ) const
inline

Definition at line 4823 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator-= ( const T &  val)
inline

Definition at line 4799 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator-= ( const self rhs)
inline

Definition at line 4845 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator/= ( const T &  val)
inline

Definition at line 4815 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator/= ( const self rhs)
inline

Definition at line 4869 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator= ( const HyperVolume< T > &  rhs)
inline

Assign a HyperVolume.

Assign elements of HyperVolume in rhs

Parameters
rhsHyperVolume to get the values from.
Returns

Definition at line 3615 of file HyperVolume.hpp.

template<typename T>
HyperVolume< T > & slip::HyperVolume< T >::operator= ( const T &  value)
inline

Assign all the elments of the HyperVolume by value.

Parameters
valueA reference-to-const of arbitrary type.
Returns

Definition at line 3626 of file HyperVolume.hpp.

template<typename T>
T*** slip::HyperVolume< T >::operator[] ( const size_type  l)
template<typename T>
const T** const* slip::HyperVolume< T >::operator[] ( const size_type  l) const
template<typename T >
HyperVolume< T >::reverse_iterator slip::HyperVolume< T >::rbegin ( )
inline

Returns a read/write reverse iterator that points to the last element in the HyperVolume. Iteration is done in reverse element order.

Returns
reverse begin iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//copy the sum of A1 and A2 in S
std::transform(A1.rbegin(),A1.rend(),
A2.rbegin(),S.rbegin(),
std::plus<double>());

Definition at line 3690 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_reverse_iterator slip::HyperVolume< T >::rbegin ( ) const
inline

Returns a read-only (constant) reverse iterator that points to the last element in the HyperVolume. Iteration is done in reverse element order.

Returns
const reverse begin iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//copy the sum of A1 and A2 in S
std::transform(A1.rbegin(),A1.rend(),
A2.rbegin(),S.rbegin(),
std::plus<double>());

Definition at line 3704 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::reverse_iterator slip::HyperVolume< T >::rend ( )
inline

Returns a read/write reverse iterator that points to one before the first element in the HyperVolume. Iteration is done in reverse element order.

Returns
reverse end iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//copy the sum of A1 and A2 in S
std::transform(A1.rbegin(),A1.rend(),
A2.rbegin(),S.rbegin(),
std::plus<double>());

Definition at line 3697 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_reverse_iterator slip::HyperVolume< T >::rend ( ) const
inline

Returns a read-only (constant) reverse iterator that points to one before the first element in the HyperVolume. Iteration is done in reverse element order.

Returns
const reverse end iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//copy the sum of A1 and A2 in S
std::transform(A1.rbegin(),A1.rend(),
A2.rbegin(),S.rbegin(),
std::plus<double>());

Definition at line 3711 of file HyperVolume.hpp.

template<typename T>
void slip::HyperVolume< T >::resize ( std::size_t  d1,
std::size_t  d2,
std::size_t  d3,
std::size_t  d4,
const T &  val = T() 
)
inline

Resizes a HyperVolume.

Parameters
d1new first dimension
d2new second dimension
d3new third dimension
d4new fourth dimension
valnew value for all the elements

Definition at line 3634 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::reverse_iterator4d slip::HyperVolume< T >::rfirst_front_upper_left ( )
inline

Returns a read/write reverse iterator4d. It points to the last back bottom right element of the HyperVolume. Iteration is done within the HyperVolume in the reverse order.

Returns
reverse_iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M in a reverse order
std::copy(M.rfirst_front_upper_left(),M.rlast_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4414 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_reverse_iterator4d slip::HyperVolume< T >::rfirst_front_upper_left ( ) const
inline

Returns a read only reverse iterator4d that points. It points to the last back bottom right element of the HyperVolume. Iteration is done within the HyperVolume in the reverse order.

Returns
const_reverse_iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M in a reverse order
std::copy(M.rfirst_front_upper_left(),M.rlast_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4422 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::reverse_iterator4d slip::HyperVolume< T >::rfirst_front_upper_left ( const Box4d< int > &  box)
inline

Returns a read/write reverse iterator4d. It points to the back bottom right element of the Box4d associated to the HyperVolume. Iteration is done in the reverse order.

Parameters
boxa Box4d defining the range of indices to iterate within the HyperVolume.
Precondition
The box indices must be inside the range of the HyperVolume ones.
Returns
reverse iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box in reverse order.
std::copy(M.rfirst_front_upper_left(b),M.rlast_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4483 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_reverse_iterator4d slip::HyperVolume< T >::rfirst_front_upper_left ( const Box4d< int > &  box) const
inline

Returns a read only reverse iterator4d. It points to the back bottom right element of the Box4d box associated to the HyperVolume. Iteration is done in the reverse order.

Parameters
boxA Box4d defining the range of indices to iterate within the HyperVolume.
Precondition
The box indices must be inside the range of the HyperVolume ones.
Returns
const reverse iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box in reverse order.
std::copy(M.rfirst_front_upper_left(b),M.rlast_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4491 of file HyperVolume.hpp.

template<typename T>
reverse_iterator4d_range slip::HyperVolume< T >::rfirst_front_upper_left ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
)

Returns a read/write reverse_iterator4d_range that points to the past the last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
reverse_iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range in reverse order
std::copy(M.rfirst_front_upper_left(slar,slir,rr,cr),M.rlast_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_reverse_iterator4d_range slip::HyperVolume< T >::rfirst_front_upper_left ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
) const

Returns a read-only reverse_iterator4d_range that points to the past the last back bottom right element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
const_reverse_iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range in reverse order
std::copy(M.rfirst_front_upper_left(slar,slir,rr,cr),M.rlast_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T >
HyperVolume< T >::reverse_iterator4d slip::HyperVolume< T >::rlast_back_bottom_right ( )
inline

Returns a read/write reverse iterator4d. It points to past the first front upper left element of the HyperVolume. Iteration is done in the reverse order.

Returns
reverse iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M in a reverse order
std::copy(M.rfirst_front_upper_left(),M.rlast_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4397 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_reverse_iterator4d slip::HyperVolume< T >::rlast_back_bottom_right ( ) const
inline

Returns a read only reverse iterator4d. It points to past the first front upper left element of the HyperVolume. Iteration is done in the reverse order.

Returns
const reverse iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
//Print M in a reverse order
std::copy(M.rfirst_front_upper_left(),M.rlast_back_bottom_right(),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4405 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::reverse_iterator4d slip::HyperVolume< T >::rlast_back_bottom_right ( const Box4d< int > &  box)
inline

Returns a read/write reverse iterator4d. It points to one before the front upper left element of the Box4d box associated to the HyperVolume.

Parameters
boxA Box4d defining the range of indices to iterate within the HyperVolume.
Precondition
The box indices must be inside the range of the HyperVolume ones.
Returns
reverse iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box in reverse order.
std::copy(M.rfirst_front_upper_left(b),M.rlast_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4466 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::const_reverse_iterator4d slip::HyperVolume< T >::rlast_back_bottom_right ( const Box4d< int > &  box) const
inline

Returns a read-only reverse iterator4d. It points to one before the front element of the bottom right element of the Box4d box associated to the HyperVolume.

Parameters
boxA Box4d defining the range of indices to iterate within the HyperVolume.
Precondition
The box indices must be inside the range of the HyperVolume ones.
Returns
const reverse iterator4d value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Box4d<int> b(1,1,1,1,2,2,3,3);
//Print M values within the box in reverse order.
std::copy(M.rfirst_front_upper_left(b),M.rlast_back_bottom_right(b),
std::ostream_iterator<double>(std::cout," "));

Definition at line 4474 of file HyperVolume.hpp.

template<typename T>
reverse_iterator4d_range slip::HyperVolume< T >::rlast_back_bottom_right ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
)

Returns a read/write reverse_iterator4d_range that points to one before the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
reverse_iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range in reverse order
std::copy(M.rfirst_front_upper_left(slar,slir,rr,cr),M.rlast_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_reverse_iterator4d_range slip::HyperVolume< T >::rlast_back_bottom_right ( const range slab_range,
const range slice_range,
const range row_range,
const range col_range 
) const

Returns a read-only reverse_iterator4d_range that points to one before the first front upper left element of the ranges slab_range, slice_range, row_range and col_range associated to the HyperVolume. Iteration is done in the reverse order.

Parameters
slab_rangeThe range of the slices.
slice_rangeThe range of the slices.
row_rangeThe range of the rows.
col_rangeThe range of the columns.
Precondition
slab_range, slice_range, row_range and col_range must be valid.
The ranges indices must be inside the ranges of the HyperVolume ones.
Returns
const_reverse_iterator4d_range value
Remarks
This iterator is compatible with BidirectionalIterator algorithms.
Example
slip::Range<int> slar(0,2,2);
slip::Range<int> slir(0,2,2);
slip::Range<int> rr(0,3,2);
slip::Range<int> cr(0,4,2);
//Print M within a range in reverse order
std::copy(M.rfirst_front_upper_left(slar,slir,rr,cr),M.rlast_back_bottom_right(slar,slir,rr,cr),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
row_iterator slip::HyperVolume< T >::row_begin ( const size_type  slab,
const size_type  slice,
const size_type  row 
)

Returns a read/write iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
begin row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_row_iterator slip::HyperVolume< T >::row_begin ( const size_type  slab,
const size_type  slice,
const size_type  row 
) const

Returns a read_only iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
begin const_row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
row_range_iterator slip::HyperVolume< T >::row_begin ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points to the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowThe index of the row to iterate.
rangeRange of the row to iterate.
Returns
begin row_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated according to the
//range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_begin(0,0,0,range),A1.row_end(0,0,0,range),A2.row_begin(1,1,1));
template<typename T>
const_row_range_iterator slip::HyperVolume< T >::row_begin ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
) const

Returns a read-only iterator that points to the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowThe index of the row to iterate.
rangeRange of the row to iterate.
Returns
begin const_row_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated according to the
//range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_begin(0,0,0,range),A1.row_end(0,0,0,range),A2.row_begin(1,1,1));
template<typename T>
row_iterator slip::HyperVolume< T >::row_end ( const size_type  slab,
const size_type  slice,
const size_type  row 
)

Returns a read/write iterator that points to the past-the-end element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
end row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_row_iterator slip::HyperVolume< T >::row_end ( const size_type  slab,
const size_type  slice,
const size_type  row 
) const

Returns a read_only iterator that points to the past-the-end element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in ordinary element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
end const_row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
row_range_iterator slip::HyperVolume< T >::row_end ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points one past the end element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowThe index of the row to iterate.
rangeRange of the row to iterate.
Returns
end row_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated according to the
//range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_begin(0,0,0,range),A1.row_end(0,0,0,range),A2.row_begin(1,1,1));
template<typename T>
const_row_range_iterator slip::HyperVolume< T >::row_end ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
) const

Returns a read_only iterator that points one past the last element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowRow to iterate.
rangeRange of the row to iterate
Returns
begin const_row_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated according to the
//range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_begin(0,0,0,range),A1.row_end(0,0,0,range),A2.row_begin(1,1,1));
template<typename T>
reverse_row_iterator slip::HyperVolume< T >::row_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  row 
)

Returns a read/write reverse iterator that points to the last element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
begin reverse_row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_reverse_row_iterator slip::HyperVolume< T >::row_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  row 
) const

Returns a read_only reverse iterator that points to the last element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
begin const_reverse_row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
reverse_row_range_iterator slip::HyperVolume< T >::row_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
)

Returns a read-write iterator that points to the last element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowThe index of the row to iterate.
rangeRange of the row to iterate.
Returns
reverse_row_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated
in reverse order according to the range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_rbegin(0,0,0,range),A1.row_rend(0,0,0,range),A2.row_begin(1,1,1));
template<typename T>
const_reverse_row_range_iterator slip::HyperVolume< T >::row_rbegin ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
) const

Returns a read-only iterator that points to the last element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowThe index of the row to iterate.
rangeRange of the row to iterate
Returns
begin const_reverse_row_range_iterator value
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated
in reverse order according to the range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_rbegin(0,0,0,range),A1.row_rend(0,0,0,range),A2.row_begin(1,1,1));
template<typename T>
reverse_row_iterator slip::HyperVolume< T >::row_rend ( const size_type  slab,
const size_type  slice,
const size_type  row 
)

Returns a read/write reverse iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
end reverse_row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
const_reverse_row_iterator slip::HyperVolume< T >::row_rend ( const size_type  slab,
const size_type  slice,
const size_type  row 
) const

Returns a read_only reverse iterator that points to the first element of the row row of a given slab slab and a given slice slice in the HyperVolume. Iteration is done in reverse element order.

Parameters
slabThe index of the slab.
sliceThe index of the slice.
rowThe index of the row.
Returns
end const_reverse_row_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Note
The row and col iterators iterate in the rows and columns respectively. There are different from slab and slice iterators that cross the slabs and slices respectively.
template<typename T>
reverse_row_range_iterator slip::HyperVolume< T >::row_rend ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
)

Returns a read-write iterator that points one before the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowThe index of the row to iterate.
rangeRange of the row to iterate.
Returns
reverse_row_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated
in reverse order according to the range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_rbegin(0,0,0,range),A1.row_rend(0,0,0,range),A2.row_begin(1,1,1));
template<typename T>
const_reverse_row_range_iterator slip::HyperVolume< T >::row_rend ( const size_type  slab,
const size_type  slice,
const size_type  row,
const slip::Range< int > &  range 
) const

Returns a read-only iterator that points one before the first element of the Range range of the row row in the slab slab and the slice slice in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
sliceThe index of the slice.
rowThe index of the row to iterate.
rangeRange of the row to iterate
Returns
const_reverse_row_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
row must be compatible with the range of the HyperVolume.
The range must be inside the whole range of the HyperVolume.
Example:
slip::Range<int> range(0,A1.dim3()-1,2);
//copy the the elements of the row 0 of the slab 0 and the slice 0 of A1 iterated
in reverse order according to the range in the row 1 of the slab 1 and slice 1 of A2
std::copy(A1.row_rbegin(0,0,0,range),A1.row_rend(0,0,0,range),A2.row_begin(1,1,1));
template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::rows ( ) const
inline

Returns the number of rows (third dimension size) in the HyperVolume.

Definition at line 4686 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::size ( ) const
inline

Returns the number of elements in the HyperVolume.

Definition at line 4707 of file HyperVolume.hpp.

template<typename T>
slab_iterator slip::HyperVolume< T >::slab_begin ( const size_type  slice,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slabs through the first slice,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slab_begin(0,1,2),A1.slab_end(0,1,2),
A2.slab_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_slab_iterator slip::HyperVolume< T >::slab_begin ( const size_type  slice,
const size_type  row,
const size_type  col 
) const

Returns a read-only (constant) iterator that points to the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slabs through the first slice,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slab_begin(0,1,2),A1.slab_end(0,1,2),
A2.slab_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
slab_range_iterator slip::HyperVolume< T >::slab_begin ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points to the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
//copy the the elements of the line (0,0,0) of A1 iterated according to the
//range in the line (1,1,1) of A2
std::copy(A1.slab_begin(0,0,0,range),A1.slab_end(0,0,0,range),A2.slab_begin(1,1,1));
template<typename T>
const_slab_range_iterator slip::HyperVolume< T >::slab_begin ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read only (constant) iterator that points to the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin const_slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated according to the range
std::copy(A1.slab_begin(0,0,0,range),A1.slab_end(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
slab_iterator slip::HyperVolume< T >::slab_end ( const size_type  slice,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the one past the end element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slabs through the first slice,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slab_begin(0,1,2),A1.slab_end(0,1,2),
A2.slab_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_slab_iterator slip::HyperVolume< T >::slab_end ( const size_type  slice,
const size_type  row,
const size_type  col 
) const

Returns a read-only (constant) iterator that points to the one past the end element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order (increasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slabs through the first slice,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slab_begin(0,1,2),A1.slab_end(0,1,2),
A2.slab_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
slab_range_iterator slip::HyperVolume< T >::slab_end ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points one past the end element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
//copy the the elements of the line (0,0,0) of A1 iterated according to the
//range in the line (1,1,1) of A2
std::copy(A1.slab_begin(0,0,0,range),A1.slab_end(0,0,0,range),A2.slab_begin(1,1,1));
template<typename T>
const_slab_range_iterator slip::HyperVolume< T >::slab_end ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read_only iterator that points one past the last element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end const_slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated according to the range
std::copy(A1.slab_begin(0,0,0,range),A1.slab_end(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
reverse_slab_iterator slip::HyperVolume< T >::slab_rbegin ( const size_type  slice,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the last element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
reverse_slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slabs through the first slice, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slab_rbegin(0,1,2),A1.slab_rend(0,1,2),
A2.slab_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_reverse_slab_iterator slip::HyperVolume< T >::slab_rbegin ( const size_type  slice,
const size_type  row,
const size_type  col 
) const

Returns a read-only (constant) iterator that points to the last element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_reverse_slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slabs through the first slice, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slab_rbegin(0,1,2),A1.slab_rend(0,1,2),
A2.slab_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
reverse_slab_range_iterator slip::HyperVolume< T >::slab_rbegin ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points to the last element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin reverse_slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slab_rbegin(0,0,0,range),A1.slab_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_reverse_slab_range_iterator slip::HyperVolume< T >::slab_rbegin ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read only (constant) iterator that points to the last element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin const_reverse_slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slab_rbegin(0,0,0,range),A1.slab_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
reverse_slab_iterator slip::HyperVolume< T >::slab_rend ( const size_type  slice,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the one before the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
reverse_slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slabs through the first slice, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slab_rbegin(0,1,2),A1.slab_rend(0,1,2),
A2.slab_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_reverse_slab_iterator slip::HyperVolume< T >::slab_rend ( const size_type  slice,
const size_type  row,
const size_type  col 
) const

Returns a read (constant) iterator that points to the one before the first element of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order (decreasing slab number).

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_reverse_slab_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slabs through the first slice, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slab_rbegin(0,1,2),A1.slab_rend(0,1,2),
A2.slab_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
reverse_slab_range_iterator slip::HyperVolume< T >::slab_rend ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points to the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end reverse_slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slab_rbegin(0,0,0,range),A1.slab_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_reverse_slab_range_iterator slip::HyperVolume< T >::slab_rend ( const size_type  slice,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read_only iterator that points one past the lastto the first element of the Range range of the of the line (slice,row,col) through the slabs in the HyperVolume. Iteration is done in reverse element order according to the Range.

Parameters
sliceslice coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end const_reverse_slab_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slab dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slab_rbegin(0,0,0,range),A1.slab_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::slabs ( ) const
inline

Returns the number of slabs (first dimension size) in the HyperVolume.

Definition at line 4666 of file HyperVolume.hpp.

template<typename T>
slice_iterator slip::HyperVolume< T >::slice_begin ( const size_type  slab,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slices through the first slab,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slice_begin(0,1,2),A1.slice_end(0,1,2),
A2.slice_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_slice_iterator slip::HyperVolume< T >::slice_begin ( const size_type  slab,
const size_type  row,
const size_type  col 
) const

Returns a read-only (constant) iterator that points to the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slices through the first slab,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slice_begin(0,1,2),A1.slice_end(0,1,2),
A2.slice_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
slice_range_iterator slip::HyperVolume< T >::slice_begin ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points to the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
//copy the the elements of the line (0,0,0) of A1 iterated according to the
//range in the line (1,1,1) of A2
std::copy(A1.slice_begin(0,0,0,range),A1.slice_end(0,0,0,range),A2.slice_begin(1,1,1));
template<typename T>
const_slice_range_iterator slip::HyperVolume< T >::slice_begin ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read only (constant) iterator that points to the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin const_slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated according to the range
std::copy(A1.slice_begin(0,0,0,range),A1.slice_end(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
slice_iterator slip::HyperVolume< T >::slice_end ( const size_type  slab,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the one past the end element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slices through the first slab,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slice_begin(0,1,2),A1.slice_end(0,1,2),
A2.slice_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_slice_iterator slip::HyperVolume< T >::slice_end ( const size_type  slab,
const size_type  row,
const size_type  col 
) const

Returns a read-only (constant) iterator that points to the one past the end element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order (increasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate the sums of the A1 and A2 elements pairwise for the line crossing the slices through the first slab,
the second row and the third column. Put the calculated sums in the S array.
std::transform(A1.slice_begin(0,1,2),A1.slice_end(0,1,2),
A2.slice_begin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
slice_range_iterator slip::HyperVolume< T >::slice_end ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points one past the end element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
//copy the the elements of the line (0,0,0) of A1 iterated according to the
//range in the line (1,1,1) of A2
std::copy(A1.slice_begin(0,0,0,range),A1.slice_end(0,0,0,range),A2.slice_begin(1,1,1));
template<typename T>
const_slice_range_iterator slip::HyperVolume< T >::slice_end ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read_only iterator that points one past the last element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in ordinary element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end const_slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated according to the range
std::copy(A1.slice_begin(0,0,0,range),A1.slice_end(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
reverse_slice_iterator slip::HyperVolume< T >::slice_rbegin ( const size_type  slab,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the last element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
reverse_slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slices through the first slab, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slice_rbegin(0,1,2),A1.slice_rend(0,1,2),
A2.slice_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_reverse_slice_iterator slip::HyperVolume< T >::slice_rbegin ( const size_type  slab,
const size_type  row,
const size_type  col 
) const

Returns a read-only (constant) iterator that points to the last element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_reverse_slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slices through the first slab, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slice_rbegin(0,1,2),A1.slice_rend(0,1,2),
A2.slice_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
reverse_slice_range_iterator slip::HyperVolume< T >::slice_rbegin ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points to the last element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in the reverse element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin reverse_slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slice_rbegin(0,0,0,range),A1.slice_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_reverse_slice_range_iterator slip::HyperVolume< T >::slice_rbegin ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read only (constant) iterator that points to the last element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
begin const_reverse_slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slice_rbegin(0,0,0,range),A1.slice_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
reverse_slice_iterator slip::HyperVolume< T >::slice_rend ( const size_type  slab,
const size_type  row,
const size_type  col 
)

Returns a read/write iterator that points to the one before the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
reverse_slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slices through the first slab, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slice_rbegin(0,1,2),A1.slice_rend(0,1,2),
A2.slice_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
const_reverse_slice_iterator slip::HyperVolume< T >::slice_rend ( const size_type  slab,
const size_type  row,
const size_type  col 
) const

Returns a read (constant) iterator that points to the one before the first element of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order (decreasing slice number).

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
Returns
const_reverse_slice_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Example:
//calculate, in reverse order, the sums of the A1 and A2 elements pairwise for the line crossing
the slices through the first slab, the second row and the third column.
Put the calculated sums in the S array.
std::transform(A1.slice_rbegin(0,1,2),A1.slice_rend(0,1,2),
A2.slice_rbegin(0,1,2),S.begin(),
std::plus<double>());
template<typename T>
reverse_slice_range_iterator slip::HyperVolume< T >::slice_rend ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
)

Returns a read/write iterator that points to the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end reverse_slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slice_rbegin(0,0,0,range),A1.slice_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T>
const_reverse_slice_range_iterator slip::HyperVolume< T >::slice_rend ( const size_type  slab,
const size_type  row,
const size_type  col,
const slip::Range< int > &  range 
) const

Returns a read_only iterator that points one past the lastto the first element of the Range range of the of the line (slab,row,col) through the slices in the HyperVolume. Iteration is done in reverse element order according to the Range.

Parameters
slabslab coordinate of the line
rowrow coordinate of the line
colcol coordinate of the line
rangeRange of the line to iterate.
Returns
end const_reverse_slice_range_iterator value
Remarks
This iterator is compatible with RandomAccessIterator algorithms.
Precondition
the range must be compatible with the slice dimensions
The range must be inside the whole range of the HyperVolume.
Example:
slip::HyperVolume<double> const A1(M); //M is an already existing %HyperVolume
//display the elements of the line (0,0,0) of A1 iterated in reverse order
//according to the range
std::copy(A1.slice_rbegin(0,0,0,range),A1.slice_rend(0,0,0,range),
std::ostream_iterator<double>(std::cout," "));
template<typename T >
HyperVolume< T >::size_type slip::HyperVolume< T >::slices ( ) const
inline

Returns the number of slices (second dimension size) in the HyperVolume.

Definition at line 4676 of file HyperVolume.hpp.

template<typename T >
T slip::HyperVolume< T >::sum ( ) const
inline

Returns the sum of the elements of the HyperVolume.

Precondition
size() != 0

Definition at line 4896 of file HyperVolume.hpp.

template<typename T >
void slip::HyperVolume< T >::swap ( HyperVolume< T > &  M)
inline

Swaps data with another HyperVolume.

Parameters
MA HyperVolume of the same element type
Precondition
dim1() == M.dim1()
dim2() == M.dim2()
dim3() == M.dim3()
dim4() == M.dim4()

Definition at line 4720 of file HyperVolume.hpp.

Friends And Related Function Documentation

template<typename T >
HyperVolume< T > abs ( const HyperVolume< T > &  V)
related

Returns the abs value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5064 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > acos ( const HyperVolume< T > &  V)
related

Returns the acos value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume

Definition at line 5092 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > asin ( const HyperVolume< T > &  V)
related

Returns the sin value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume

Definition at line 5110 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > atan ( const HyperVolume< T > &  V)
related

Returns the atan value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp.

Definition at line 5128 of file HyperVolume.hpp.

template<typename T>
friend class boost::serialization::access
friend

Definition at line 3237 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > cos ( const HyperVolume< T > &  V)
related

Returns the cos value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5083 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > cosh ( const HyperVolume< T > &  V)
related

Returns the cosh value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5155 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > exp ( const HyperVolume< T > &  V)
related

Returns the exp value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5137 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > log ( const HyperVolume< T > &  V)
related

Returns the log value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, and test_complex.cpp.

Definition at line 5146 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > log10 ( const HyperVolume< T > &  V)
related

Returns the log10 value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, and test_complex.cpp.

Definition at line 5182 of file HyperVolume.hpp.

template<typename T >
T & max ( const HyperVolume< T > &  M1)
related

Returns the max element of a HyperVolume.

Parameters
M1the HyperVolume
Returns
the min element

Definition at line 5057 of file HyperVolume.hpp.

template<typename T >
T & min ( const HyperVolume< T > &  M1)
related

Returns the min element of a HyperVolume.

Parameters
M1the HyperVolume
Returns
the min element

Definition at line 5050 of file HyperVolume.hpp.

template<typename T>
bool operator!= ( const HyperVolume< T > &  x,
const HyperVolume< T > &  y 
)
friend

HyperVolume inequality comparison

Parameters
xA HyperVolume
yA HyperVolume of the same type of x
Returns
true if !(x == y)

Definition at line 4739 of file HyperVolume.hpp.

template<typename T>
bool operator< ( const HyperVolume< T > &  x,
const HyperVolume< T > &  y 
)
friend

Less than comparison operator (HyperVolume ordering relation)

Parameters
xA HyperVolume
yA HyperVolume of the same type of x
Returns
true iff x is lexicographically less than y

Definition at line 4751 of file HyperVolume.hpp.

template<typename T>
std::ostream& operator<< ( std::ostream &  out,
const HyperVolume< T > &  a 
)
friend

Write the HyperVolume to the ouput stream.

Parameters
outoutput std::ostream
aHyperVolume to write to the output stream

Definition at line 4599 of file HyperVolume.hpp.

template<typename T>
bool operator<= ( const HyperVolume< T > &  x,
const HyperVolume< T > &  y 
)
friend

Less than equal comparison operator.

Parameters
xA HyperVolume
yA HyperVolume of the same type of x
Returns
true iff !(y > x)

Definition at line 4769 of file HyperVolume.hpp.

template<typename T>
bool operator== ( const HyperVolume< T > &  x,
const HyperVolume< T > &  y 
)
friend

HyperVolume equality comparison

Parameters
xA HyperVolume
yA HyperVolume of the same type of x
Returns
true iff the size and the elements of the Arrays are equal

Definition at line 4730 of file HyperVolume.hpp.

template<typename T>
bool operator> ( const HyperVolume< T > &  x,
const HyperVolume< T > &  y 
)
friend

More than comparison operator.

Parameters
xA HyperVolume
yA HyperVolume of the same type of x
Returns
true iff y > x

Definition at line 4761 of file HyperVolume.hpp.

template<typename T>
bool operator>= ( const HyperVolume< T > &  x,
const HyperVolume< T > &  y 
)
friend

More than equal comparison operator.

Parameters
xA HyperVolume
yA HyperVolume of the same type of x
Returns
true iff !(x < y)

Definition at line 4777 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > sin ( const HyperVolume< T > &  V)
related

Returns the sin value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5101 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > sinh ( const HyperVolume< T > &  V)
related

Returns the sinh value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5164 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > sqrt ( const HyperVolume< T > &  V)
related

Returns the sqrt value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, and test_complex.cpp.

Definition at line 5074 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > tan ( const HyperVolume< T > &  V)
related

Returns the tan value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5119 of file HyperVolume.hpp.

template<typename T >
HyperVolume< T > tanh ( const HyperVolume< T > &  V)
related

Returns the tanh value of each element of the HyperVolume.

Parameters
VThe HyperVolume
Returns
the resulting HyperVolume
Examples:
matrix_math_op.cpp, test_complex.cpp, and test_quaternion.cpp.

Definition at line 5173 of file HyperVolume.hpp.

Member Data Documentation

template<typename T>
const std::size_t slip::HyperVolume< T >::DIM = 4
static

Definition at line 239 of file HyperVolume.hpp.


The documentation for this class was generated from the following file: