Skip to content

Dims

class Dims

@brief A class describing array dimensions

Functions

Name Description
rank Return the rank of the dimensions Return :
size Return the total number of elements in the array Return :
extentIn Return the extend of the array in the dimension identified by idx idx, : needs to be >= 0 and , rank Return :
toVector Return a std::vector holding the dimension sizes Return :
fromVector Create a dimension object from a vector vec :
x1 Return size of first dimension Return :
x2 Return size of second dimension Return :
x3 Return size of third dimension Return :
x4 Return size of fourth dimension Return :
reverse Reverse dimension sizes
calculate calculate rank and number of elements in array.

Function Details

calculate

void calculate()

calculate rank and number of elements in array.

extentIn

ull64 extentIn(size_t idx) const

Return the extend of the array in the dimension identified by idx

idx, : needs to be >= 0 and , rank

Return :

fromVector

void fromVector(const std::vector<ull64>& vec)

Create a dimension object from a vector

vec :

rank

std::size_t rank() const

Return the rank of the dimensions

Return :

reverse

void reverse()

Reverse dimension sizes

size

ull64 size() const

Return the total number of elements in the array

Return :

toVector

const std::vector<ull64>& toVector() const

Return a std::vector holding the dimension sizes

Return :

x1

ull64 x1() const

Return size of first dimension

Return :

x2

ull64 x2() const

Return size of second dimension

Return :

x3

ull64 x3() const

Return size of third dimension

Return :

x4

ull64 x4() const

Return size of fourth dimension

Return :