[Mdarray_module]

`#include <Array.hpp>`

class phdmesh::Array< Scalar, array_order, Tag1, Tag2, Tag3, Tag4, Tag5, Tag6, Tag7, Tag8 >

**Parameters:**-
*Scalar*The "plain old data" type of the array's member data. *array_order*An **ArrayOrder**value that specifies whether to use Natural (a.k.a. C-language) or Fortran ordering for the multi-dimensions and multi-indices.*Tag::*The **Tag#**template parameters document the user-defiend purpose of each dimension ordinate. The**Rank**of the array (i.e. the number of dimensions) is the number of user-defined dimension tags, up to eight. A user-defined dimension**Tag#**must be derived from the**ArrayDimTag**template class.

**See also:**- ArrayDimTag ArrayOrder

Definition at line 235 of file Array.hpp.

## Array Attributes | |

typedef Scalar | value_type |

Type of member data. | |

typedef unsigned | size_type |

Type for sizes. | |

typedef const ArrayDimTag * | tag_type |

Type of runtime dimension tags. | |

enum | { Rank = md_type::Rank
} |

Rank of the array is the number of non-void dimension tags. | |

enum | { Natural = NaturalOrder == array_order
} |

If the multidimension follows the natural ordering. | |

enum | { Reverse = FortranOrder == array_order
} |

If the multidimension follows the reverse (Fortran) ordering. | |

enum | { Contiguous = true
} |

If the member data storage is contiguous. | |

unsigned | rank () const |

Rank of the array is the number of non-void dimension tags. | |

bool | natural () const |

If the multidimension follows the natural ordering. | |

bool | reverse () const |

If the multidimension follows the reverse (Fortran) ordering. | |

bool | contiguous () const |

If the member data storage is contiguous. | |

tag_type | tag (const unsigned ordinate) const |

Access the dimension tag-singleton for a given ordinate. | |

template<unsigned ordinate> | |

unsigned | dimension () const |

Dimension of the given ordinate. | |

unsigned | dimension (const unsigned ordinate) const |

Dimension of the given ordinate. | |

void | dimensions (std::vector< unsigned > &n) |

Dimensions of all ordinates. | |

size_type | size () const |

Total number of member data items. | |

## Member data access operators | |

typedef ArrayTruncate< Array >::type | TruncateType |

Subarray type that removes the slowest striding dimension (first natural or last fortran ordinate). | |

TruncateType | truncate (const unsigned i) const |

Generate a subarray view of the array with the slowest striding ordinate offset by i and removed. | |

value_type * | contiguous_data () const |

Pointer to contiguous block of member data. | |

value_type & | operator[] (size_type i) const |

Access member via offset into contiguous block. | |

value_type & | operator() (const unsigned i1, const unsigned i2, const unsigned i3, const unsigned i4, const unsigned i5, const unsigned i6, const unsigned i7, const unsigned i8) const |

Access member of a Rank 8 array. | |

value_type & | operator() (const unsigned i1, const unsigned i2, const unsigned i3, const unsigned i4, const unsigned i5, const unsigned i6, const unsigned i7) const |

Access member of a Rank 7 array. | |

value_type & | operator() (const unsigned i1, const unsigned i2, const unsigned i3, const unsigned i4, const unsigned i5, const unsigned i6) const |

Access member of a Rank 6 array. | |

value_type & | operator() (const unsigned i1, const unsigned i2, const unsigned i3, const unsigned i4, const unsigned i5) const |

Access member of a Rank 5 array. | |

value_type & | operator() (const unsigned i1, const unsigned i2, const unsigned i3, const unsigned i4) const |

Access member of a Rank 4 array. | |

value_type & | operator() (const unsigned i1, const unsigned i2, const unsigned i3) const |

Access member of a Rank 3 array. | |

value_type & | operator() (const unsigned i1, const unsigned i2) const |

Access member of a Rank 2 array. | |

value_type & | operator() (const unsigned i1) const |

Access member of a Rank 1 array. | |

## Constructors and Assignment Operators | |

typedef ArrayReverse< Array >::type | ReverseType |

The compatible multidimensional array with reversed multi-index ordering and dimension tags. | |

Array () | |

Default constructor. | |

Array (const Array &rhs) | |

Copy constructor. | |

Array & | operator= (const Array &rhs) |

Assignment operator. | |

Array (const ReverseType &rhs) | |

Copy constructor for compatible reverse type. | |

Array & | operator= (const ReverseType &rhs) |

Assignment operator for compatible reverse type. | |

Array (value_type *arg_ptr, const unsigned *const dims) | |

Construct with array of dimensions. | |

Array (value_type *arg_ptr, const unsigned n1, const unsigned n2, const unsigned n3, const unsigned n4, const unsigned n5, const unsigned n6, const unsigned n7, const unsigned n8) | |

Construct a Rank 8 array. | |

Array (value_type *arg_ptr, const unsigned n1, const unsigned n2, const unsigned n3, const unsigned n4, const unsigned n5, const unsigned n6, const unsigned n7) | |

Construct a Rank 7..8 array; use Tag#Size for defaults. The input dimensions are the 7 slowest strides. | |

Array (value_type *arg_ptr, const unsigned n1, const unsigned n2, const unsigned n3, const unsigned n4, const unsigned n5, const unsigned n6) | |

Construct a Rank 6..8 array; use Tag#Size for defaults. The input dimensions are the 6 slowest strides. | |

Array (value_type *arg_ptr, const unsigned n1, const unsigned n2, const unsigned n3, const unsigned n4, const unsigned n5) | |

Construct a Rank 5..8 array; use Tag#Size for defaults. The input dimensions are the 5 slowest strides. | |

Array (value_type *arg_ptr, const unsigned n1, const unsigned n2, const unsigned n3, const unsigned n4) | |

Construct a Rank 4..8 array; use Tag#Size for defaults. The input dimensions are the 4 slowest strides. | |

Array (value_type *arg_ptr, const unsigned n1, const unsigned n2, const unsigned n3) | |

Construct a Rank 3..8 array; use Tag#Size for defaults. The input dimensions are the 3 slowest strides. | |

Array (value_type *arg_ptr, const unsigned n1, const unsigned n2) | |

Construct a Rank 2..8 array; use Tag#Size for defaults. The input dimensions are the 2 slowest strides. | |

Array (value_type *arg_ptr, const unsigned n1) | |

Construct a Rank 1..8 array; use Tag#Size for defaults. The input dimension is the slowest stride. | |

Array (value_type *arg_ptr) | |

Construct a Rank 1..8 array; use Tag#Size for defaults. | |

## Protected Attributes | |

value_type * | m_ptr |

Pointer to contiguous block of members. | |

size_type | m_stride [Rank] |

Array of strides, smallest to largest. | |

## Friends | |

class | phdmesh::Array |

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

Generated on Tue Jul 13 09:22:43 2010 for phdMesh by 1.4.7